diff --git a/pro-test/src/services/checkout.ts b/pro-test/src/services/checkout.ts index 3bc75ddab..9702cde9c 100644 --- a/pro-test/src/services/checkout.ts +++ b/pro-test/src/services/checkout.ts @@ -136,20 +136,41 @@ export function initOverlay(onSuccess?: () => void): void { // payment_id) depending on event type, and anything logged here // lands in Sentry breadcrumbs via the console integration. const data = event.data as Record | undefined; - const status = data?.status - ?? (data?.message as Record | undefined)?.status; + const msg = data?.message as Record | undefined; + const status = msg?.status as string | undefined; console.info('[checkout] dodo event', event.event_type, status !== undefined ? { status } : undefined); + + // Dodo's documented `manualRedirect: true` flow emits TWO events + // on terminal success: `checkout.status` for UI updates, and + // `checkout.redirect_requested` carrying the URL WE must navigate + // to. The SDK explicitly hands navigation to the merchant in this + // mode — ignoring `checkout.redirect_requested` is what stranded + // users after paying (docs: overlay-checkout.mdx, inline-checkout.mdx). + // + // Status shape is ONLY `event.data.message.status` per docs — the + // legacy top-level `event.data.status` read was a guess against + // an older SDK version and most likely never matched. if (event.event_type === 'checkout.status' && status === 'succeeded') { - // Best-effort: with `manualRedirect: false` the SDK performs - // `window.location.href = redirect_to` on a sibling - // `checkout.redirect` event, and that navigation can race - // with this callback. Callers should treat any side effects - // here as a bonus, not a guarantee. The authoritative success - // path is the `?wm_checkout=success` bridge on - // worldmonitor.app that the SDK's redirect lands on. onSuccess?.(); } + if (event.event_type === 'checkout.redirect_requested') { + const redirectTo = msg?.redirect_to as string | undefined; + // Dodo builds redirect_to from the return_url we sent, appending + // payment_id/subscription_id/status/license_key/email per + // changelog v1.84.0. Our return_url carries `?wm_checkout=success` + // so the dashboard bridge (src/services/checkout-return.ts) fires + // regardless of Dodo's appended params. + window.location.href = redirectTo || 'https://worldmonitor.app/?wm_checkout=success'; + } + if (event.event_type === 'checkout.link_expired') { + // Not user-blocking — log-only for now; follow-up if Sentry + // shows volume. + Sentry.captureMessage('Dodo checkout link expired', { + level: 'info', + tags: { surface: 'pro-marketing', code: 'link_expired' }, + }); + } }, }); }).catch((err) => { @@ -320,15 +341,16 @@ async function doCheckout( DodoPayments.Checkout.open({ checkoutUrl: result.checkout_url, options: { - // manualRedirect: false — Dodo performs the parent-window - // redirect on success, landing at the `returnUrl` we sent to - // /api/create-checkout (which carries ?wm_checkout=success). - // Relying on the SDK's own redirect avoids a class of bugs - // where `checkout.status=succeeded` never reaches our onEvent - // (iframe internally navigates to wallet-return, postMessage - // gets lost) and the user is stuck on /pro#pricing with the - // overlay open. - manualRedirect: false, + // manualRedirect: true — Dodo emits `checkout.redirect_requested` + // with the final redirect URL and the MERCHANT performs the + // navigation. Reverting PR #3298's `false`: that mode disables + // both `checkout.status` and `checkout.redirect_requested` events + // (docs: "only when manualRedirect is enabled") and depends on + // the SDK's internal redirect, which fails for Safari users + // (stuck on a spinner with an orphaned about:blank tab). The + // correct flow per docs is manualRedirect:true + a + // checkout.redirect_requested handler — see onEvent above. + manualRedirect: true, themeConfig: { dark: { bgPrimary: '#0d0d0d', diff --git a/public/pro/assets/index-B7bmlZIg.js b/public/pro/assets/index-CiMZEtgt.js similarity index 90% rename from public/pro/assets/index-B7bmlZIg.js rename to public/pro/assets/index-CiMZEtgt.js index 62307e249..891cb8aa8 100644 --- a/public/pro/assets/index-B7bmlZIg.js +++ b/public/pro/assets/index-CiMZEtgt.js @@ -6,21 +6,21 @@ * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Hy;function c_(){if(Hy)return ar;Hy=1;var n=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function a(r,l,c){var f=null;if(c!==void 0&&(f=""+c),l.key!==void 0&&(f=""+l.key),"key"in l){c={};for(var h in l)h!=="key"&&(c[h]=l[h])}else c=l;return l=c.ref,{$$typeof:n,type:r,key:f,ref:l!==void 0?l:null,props:c}}return ar.Fragment=t,ar.jsx=a,ar.jsxs=a,ar}var Iy;function u_(){return Iy||(Iy=1,_f.exports=c_()),_f.exports}var g=u_();const ce=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Oe=globalThis,$i="10.49.0";function Il(){return ql(Oe),Oe}function ql(n){const t=n.__SENTRY__=n.__SENTRY__||{};return t.version=t.version||$i,t[$i]=t[$i]||{}}function as(n,t,a=Oe){const r=a.__SENTRY__=a.__SENTRY__||{},l=r[$i]=r[$i]||{};return l[n]||(l[n]=t())}const f_=["debug","info","warn","error","log","assert","trace"],d_="Sentry Logger ",wl={};function ss(n){if(!("console"in Oe))return n();const t=Oe.console,a={},r=Object.keys(wl);r.forEach(l=>{const c=wl[l];a[l]=t[l],t[l]=c});try{return n()}finally{r.forEach(l=>{t[l]=a[l]})}}function h_(){Zd().enabled=!0}function m_(){Zd().enabled=!1}function Rx(){return Zd().enabled}function p_(...n){$d("log",...n)}function g_(...n){$d("warn",...n)}function y_(...n){$d("error",...n)}function $d(n,...t){ce&&Rx()&&ss(()=>{Oe.console[n](`${d_}[${n}]:`,...t)})}function Zd(){return ce?as("loggerSettings",()=>({enabled:!1})):{enabled:!1}}const ae={enable:h_,disable:m_,isEnabled:Rx,log:p_,warn:g_,error:y_},kx=50,Wi="?",qy=/\(error: (.*)\)/,Fy=/captureMessage|captureException/;function Lx(...n){const t=n.sort((a,r)=>a[0]-r[0]).map(a=>a[1]);return(a,r=0,l=0)=>{const c=[],f=a.split(` -`);for(let h=r;h1024&&(m=m.slice(0,1024));const p=qy.test(m)?m.replace(qy,"$1"):m;if(!p.includes("Error: ")){for(const v of t){const x=v(p);if(x){c.push(x);break}}if(c.length>=kx+l)break}}return x_(c.slice(l))}}function v_(n){return Array.isArray(n)?Lx(...n):n}function x_(n){if(!n.length)return[];const t=Array.from(n);return/sentryWrapped/.test(el(t).function||"")&&t.pop(),t.reverse(),Fy.test(el(t).function||"")&&(t.pop(),Fy.test(el(t).function||"")&&t.pop()),t.slice(0,kx).map(a=>({...a,filename:a.filename||el(t).filename,function:a.function||Wi}))}function el(n){return n[n.length-1]||{}}const Tf="";function yi(n){try{return!n||typeof n!="function"?Tf:n.name||Tf}catch{return Tf}}function Gy(n){const t=n.exception;if(t){const a=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&a.push(...r.stacktrace.frames)}),a}catch{return}}}function zx(n){return"__v_isVNode"in n&&n.__v_isVNode?"[VueVNode]":"[VueViewModel]"}const ll={},Yy={};function na(n,t){ll[n]=ll[n]||[],ll[n].push(t)}function ia(n,t){if(!Yy[n]){Yy[n]=!0;try{t()}catch(a){ce&&ae.error(`Error while instrumenting ${n}`,a)}}}function rn(n,t){const a=n&&ll[n];if(a)for(const r of a)try{r(t)}catch(l){ce&&ae.error(`Error while triggering instrumentation handler. + */var Hy;function u_(){if(Hy)return ar;Hy=1;var n=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function a(r,l,c){var f=null;if(c!==void 0&&(f=""+c),l.key!==void 0&&(f=""+l.key),"key"in l){c={};for(var h in l)h!=="key"&&(c[h]=l[h])}else c=l;return l=c.ref,{$$typeof:n,type:r,key:f,ref:l!==void 0?l:null,props:c}}return ar.Fragment=t,ar.jsx=a,ar.jsxs=a,ar}var Iy;function f_(){return Iy||(Iy=1,_f.exports=u_()),_f.exports}var g=f_();const ce=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Oe=globalThis,$i="10.49.0";function Il(){return ql(Oe),Oe}function ql(n){const t=n.__SENTRY__=n.__SENTRY__||{};return t.version=t.version||$i,t[$i]=t[$i]||{}}function as(n,t,a=Oe){const r=a.__SENTRY__=a.__SENTRY__||{},l=r[$i]=r[$i]||{};return l[n]||(l[n]=t())}const d_=["debug","info","warn","error","log","assert","trace"],h_="Sentry Logger ",wl={};function ss(n){if(!("console"in Oe))return n();const t=Oe.console,a={},r=Object.keys(wl);r.forEach(l=>{const c=wl[l];a[l]=t[l],t[l]=c});try{return n()}finally{r.forEach(l=>{t[l]=a[l]})}}function m_(){Zd().enabled=!0}function p_(){Zd().enabled=!1}function Rx(){return Zd().enabled}function g_(...n){$d("log",...n)}function y_(...n){$d("warn",...n)}function v_(...n){$d("error",...n)}function $d(n,...t){ce&&Rx()&&ss(()=>{Oe.console[n](`${h_}[${n}]:`,...t)})}function Zd(){return ce?as("loggerSettings",()=>({enabled:!1})):{enabled:!1}}const ae={enable:m_,disable:p_,isEnabled:Rx,log:g_,warn:y_,error:v_},kx=50,Wi="?",qy=/\(error: (.*)\)/,Fy=/captureMessage|captureException/;function Lx(...n){const t=n.sort((a,r)=>a[0]-r[0]).map(a=>a[1]);return(a,r=0,l=0)=>{const c=[],f=a.split(` +`);for(let h=r;h1024&&(m=m.slice(0,1024));const p=qy.test(m)?m.replace(qy,"$1"):m;if(!p.includes("Error: ")){for(const v of t){const x=v(p);if(x){c.push(x);break}}if(c.length>=kx+l)break}}return b_(c.slice(l))}}function x_(n){return Array.isArray(n)?Lx(...n):n}function b_(n){if(!n.length)return[];const t=Array.from(n);return/sentryWrapped/.test(el(t).function||"")&&t.pop(),t.reverse(),Fy.test(el(t).function||"")&&(t.pop(),Fy.test(el(t).function||"")&&t.pop()),t.slice(0,kx).map(a=>({...a,filename:a.filename||el(t).filename,function:a.function||Wi}))}function el(n){return n[n.length-1]||{}}const Tf="";function yi(n){try{return!n||typeof n!="function"?Tf:n.name||Tf}catch{return Tf}}function Gy(n){const t=n.exception;if(t){const a=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&a.push(...r.stacktrace.frames)}),a}catch{return}}}function zx(n){return"__v_isVNode"in n&&n.__v_isVNode?"[VueVNode]":"[VueViewModel]"}const ll={},Yy={};function na(n,t){ll[n]=ll[n]||[],ll[n].push(t)}function ia(n,t){if(!Yy[n]){Yy[n]=!0;try{t()}catch(a){ce&&ae.error(`Error while instrumenting ${n}`,a)}}}function rn(n,t){const a=n&&ll[n];if(a)for(const r of a)try{r(t)}catch(l){ce&&ae.error(`Error while triggering instrumentation handler. Type: ${n} Name: ${yi(r)} -Error:`,l)}}let Ef=null;function b_(n){const t="error";na(t,n),ia(t,S_)}function S_(){Ef=Oe.onerror,Oe.onerror=function(n,t,a,r,l){return rn("error",{column:r,error:l,line:a,msg:n,url:t}),Ef?Ef.apply(this,arguments):!1},Oe.onerror.__SENTRY_INSTRUMENTED__=!0}let Af=null;function w_(n){const t="unhandledrejection";na(t,n),ia(t,__)}function __(){Af=Oe.onunhandledrejection,Oe.onunhandledrejection=function(n){return rn("unhandledrejection",n),Af?Af.apply(this,arguments):!0},Oe.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const Vx=Object.prototype.toString;function Fl(n){switch(Vx.call(n)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return vi(n,Error)}}function rs(n,t){return Vx.call(n)===`[object ${t}]`}function Bx(n){return rs(n,"ErrorEvent")}function Ky(n){return rs(n,"DOMError")}function T_(n){return rs(n,"DOMException")}function Un(n){return rs(n,"String")}function Qd(n){return typeof n=="object"&&n!==null&&"__sentry_template_string__"in n&&"__sentry_template_values__"in n}function Gl(n){return n===null||Qd(n)||typeof n!="object"&&typeof n!="function"}function vr(n){return rs(n,"Object")}function Yl(n){return typeof Event<"u"&&vi(n,Event)}function E_(n){return typeof Element<"u"&&vi(n,Element)}function A_(n){return rs(n,"RegExp")}function Ar(n){return!!(n!=null&&n.then&&typeof n.then=="function")}function N_(n){return vr(n)&&"nativeEvent"in n&&"preventDefault"in n&&"stopPropagation"in n}function vi(n,t){try{return n instanceof t}catch{return!1}}function Ux(n){return!!(typeof n=="object"&&n!==null&&(n.__isVue||n._isVue||n.__v_isVNode))}function Px(n){return typeof Request<"u"&&vi(n,Request)}const Wd=Oe,D_=80;function Hx(n,t={}){if(!n)return"";try{let a=n;const r=5,l=[];let c=0,f=0;const h=" > ",m=h.length;let p;const v=Array.isArray(t)?t:t.keyAttrs,x=!Array.isArray(t)&&t.maxStringLength||D_;for(;a&&c++1&&f+l.length*m+p.length>=x));)l.push(p),f+=p.length,a=a.parentNode;return l.reverse().join(h)}catch{return""}}function C_(n,t){const a=n,r=[];if(!(a!=null&&a.tagName))return"";if(Wd.HTMLElement&&a instanceof HTMLElement&&a.dataset){if(a.dataset.sentryComponent)return a.dataset.sentryComponent;if(a.dataset.sentryElement)return a.dataset.sentryElement}r.push(a.tagName.toLowerCase());const l=t!=null&&t.length?t.filter(c=>a.getAttribute(c)).map(c=>[c,a.getAttribute(c)]):null;if(l!=null&&l.length)l.forEach(c=>{r.push(`[${c[0]}="${c[1]}"]`)});else{a.id&&r.push(`#${a.id}`);const c=a.className;if(c&&Un(c)){const f=c.split(/\s+/);for(const h of f)r.push(`.${h}`)}}for(const c of["aria-label","type","name","title","alt"]){const f=a.getAttribute(c);f&&r.push(`[${c}="${f}"]`)}return r.join("")}function Jd(){try{return Wd.document.location.href}catch{return""}}function j_(n,t=5){if(!Wd.HTMLElement)return null;let a=n;for(let r=0;r"}}function $y(n){return typeof n=="object"&&n!==null?Object.fromEntries(Object.entries(n)):{}}function M_(n){const t=Object.keys(qx(n));return t.sort(),t[0]?t.join(", "):"[object has no keys]"}let Ia;function Kl(n){if(Ia!==void 0)return Ia?Ia(n):n();const t=Symbol.for("__SENTRY_SAFE_RANDOM_ID_WRAPPER__"),a=Oe;return t in a&&typeof a[t]=="function"?(Ia=a[t],Ia(n)):(Ia=null,n())}function _l(){return Kl(()=>Math.random())}function Xl(){return Kl(()=>Date.now())}function ad(n,t=0){return typeof n!="string"||t===0||n.length<=t?n:`${n.slice(0,t)}...`}function Zy(n,t){if(!Array.isArray(n))return"";const a=[];for(let r=0;rcl(n,r,a))}function O_(){const n=Oe;return n.crypto||n.msCrypto}let Nf;function R_(){return _l()*16}function Wt(n=O_()){try{if(n!=null&&n.randomUUID)return Kl(()=>n.randomUUID()).replace(/-/g,"")}catch{}return Nf||(Nf="10000000100040008000"+1e11),Nf.replace(/[018]/g,t=>(t^(R_()&15)>>t/4).toString(16))}function Fx(n){var t,a;return(a=(t=n.exception)==null?void 0:t.values)==null?void 0:a[0]}function Yi(n){const{message:t,event_id:a}=n;if(t)return t;const r=Fx(n);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||a||"":a||""}function sd(n,t,a){const r=n.exception=n.exception||{},l=r.values=r.values||[],c=l[0]=l[0]||{};c.value||(c.value=t||""),c.type||(c.type="Error")}function Wa(n,t){const a=Fx(n);if(!a)return;const r={type:"generic",handled:!0},l=a.mechanism;if(a.mechanism={...r,...l,...t},t&&"data"in t){const c={...l==null?void 0:l.data,...t.data};a.mechanism.data=c}}function Qy(n){if(k_(n))return!0;try{xi(n,"__sentry_captured__",!0)}catch{}return!1}function k_(n){try{return n.__sentry_captured__}catch{}}const Gx=1e3;function Nr(){return Xl()/Gx}function L_(){const{performance:n}=Oe;if(!(n!=null&&n.now)||!n.timeOrigin)return Nr;const t=n.timeOrigin;return()=>(t+Kl(()=>n.now()))/Gx}let Wy;function Pn(){return(Wy??(Wy=L_()))()}function z_(n){const t=Pn(),a={sid:Wt(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>B_(a)};return n&&Ja(a,n),a}function Ja(n,t={}){if(t.user&&(!n.ipAddress&&t.user.ip_address&&(n.ipAddress=t.user.ip_address),!n.did&&!t.did&&(n.did=t.user.id||t.user.email||t.user.username)),n.timestamp=t.timestamp||Pn(),t.abnormal_mechanism&&(n.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(n.ignoreDuration=t.ignoreDuration),t.sid&&(n.sid=t.sid.length===32?t.sid:Wt()),t.init!==void 0&&(n.init=t.init),!n.did&&t.did&&(n.did=`${t.did}`),typeof t.started=="number"&&(n.started=t.started),n.ignoreDuration)n.duration=void 0;else if(typeof t.duration=="number")n.duration=t.duration;else{const a=n.timestamp-n.started;n.duration=a>=0?a:0}t.release&&(n.release=t.release),t.environment&&(n.environment=t.environment),!n.ipAddress&&t.ipAddress&&(n.ipAddress=t.ipAddress),!n.userAgent&&t.userAgent&&(n.userAgent=t.userAgent),typeof t.errors=="number"&&(n.errors=t.errors),t.status&&(n.status=t.status)}function V_(n,t){let a={};n.status==="ok"&&(a={status:"exited"}),Ja(n,a)}function B_(n){return{sid:`${n.sid}`,init:n.init,started:new Date(n.started*1e3).toISOString(),timestamp:new Date(n.timestamp*1e3).toISOString(),status:n.status,errors:n.errors,did:typeof n.did=="number"||typeof n.did=="string"?`${n.did}`:void 0,duration:n.duration,abnormal_mechanism:n.abnormal_mechanism,attrs:{release:n.release,environment:n.environment,ip_address:n.ipAddress,user_agent:n.userAgent}}}function Dr(n,t,a=2){if(!t||typeof t!="object"||a<=0)return t;if(n&&Object.keys(t).length===0)return n;const r={...n};for(const l in t)Object.prototype.hasOwnProperty.call(t,l)&&(r[l]=Dr(r[l],t[l],a-1));return r}function Jy(){return Wt()}function Yx(){return Wt().substring(16)}const rd="_sentrySpan";function e0(n,t){t?xi(n,rd,t):delete n[rd]}function t0(n){return n[rd]}const U_=100;class gn{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:Jy(),sampleRand:_l()}}clone(){const t=new gn;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,t._conversationId=this._conversationId,e0(t,t0(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&Ja(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}setConversationId(t){return this._conversationId=t||void 0,this._notifyScopeListeners(),this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,a){return this.setTags({[t]:a})}setAttributes(t){return this._attributes={...this._attributes,...t},this._notifyScopeListeners(),this}setAttribute(t,a){return this.setAttributes({[t]:a})}removeAttribute(t){return t in this._attributes&&(delete this._attributes[t],this._notifyScopeListeners()),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,a){return this._extra={...this._extra,[t]:a},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,a){return a===null?delete this._contexts[t]:this._contexts[t]=a,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const a=typeof t=="function"?t(this):t,r=a instanceof gn?a.getScopeData():vr(a)?t:void 0,{tags:l,attributes:c,extra:f,user:h,contexts:m,level:p,fingerprint:v=[],propagationContext:x,conversationId:S}=r||{};return this._tags={...this._tags,...l},this._attributes={...this._attributes,...c},this._extra={...this._extra,...f},this._contexts={...this._contexts,...m},h&&Object.keys(h).length&&(this._user=h),p&&(this._level=p),v.length&&(this._fingerprint=v),x&&(this._propagationContext=x),S&&(this._conversationId=S),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,this._conversationId=void 0,e0(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Jy(),sampleRand:_l()}),this._notifyScopeListeners(),this}addBreadcrumb(t,a){var c;const r=typeof a=="number"?a:U_;if(r<=0)return this;const l={timestamp:Nr(),...t,message:t.message?ad(t.message,2048):t.message};return this._breadcrumbs.push(l),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),(c=this._client)==null||c.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:t0(this),conversationId:this._conversationId}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Dr(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,a){const r=(a==null?void 0:a.event_id)||Wt();if(!this._client)return ce&&ae.warn("No client configured on scope - will not capture exception!"),r;const l=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:l,...a,event_id:r},this),r}captureMessage(t,a,r){const l=(r==null?void 0:r.event_id)||Wt();if(!this._client)return ce&&ae.warn("No client configured on scope - will not capture message!"),l;const c=(r==null?void 0:r.syntheticException)??new Error(t);return this._client.captureMessage(t,a,{originalException:t,syntheticException:c,...r,event_id:l},this),l}captureEvent(t,a){const r=t.event_id||(a==null?void 0:a.event_id)||Wt();return this._client?(this._client.captureEvent(t,{...a,event_id:r},this),r):(ce&&ae.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}function P_(){return as("defaultCurrentScope",()=>new gn)}function H_(){return as("defaultIsolationScope",()=>new gn)}const n0=n=>n instanceof Promise&&!n[Kx],Kx=Symbol("chained PromiseLike"),I_=(n,t,a)=>{const r=n.then(l=>(t(l),l),l=>{throw a(l),l});return n0(r)&&n0(n)?r:q_(n,r)},q_=(n,t)=>{let a=!1;for(const r in n){if(r in t)continue;a=!0;const l=n[r];typeof l=="function"?Object.defineProperty(t,r,{value:(...c)=>l.apply(n,c),enumerable:!0,configurable:!0,writable:!0}):t[r]=l}return a&&Object.assign(t,{[Kx]:!0}),t};class F_{constructor(t,a){let r;t?r=t:r=new gn;let l;a?l=a:l=new gn,this._stack=[{scope:r}],this._isolationScope=l}withScope(t){const a=this._pushScope();let r;try{r=t(a)}catch(l){throw this._popScope(),l}return Ar(r)?I_(r,()=>this._popScope(),()=>this._popScope()):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function es(){const n=Il(),t=ql(n);return t.stack=t.stack||new F_(P_(),H_())}function G_(n){return es().withScope(n)}function Y_(n,t){const a=es();return a.withScope(()=>(a.getStackTop().scope=n,t(n)))}function i0(n){return es().withScope(()=>n(es().getIsolationScope()))}function K_(){return{withIsolationScope:i0,withScope:G_,withSetScope:Y_,withSetIsolationScope:(n,t)=>i0(t),getCurrentScope:()=>es().getScope(),getIsolationScope:()=>es().getIsolationScope()}}function th(n){const t=ql(n);return t.acs?t.acs:K_()}function vn(){const n=Il();return th(n).getCurrentScope()}function wi(){const n=Il();return th(n).getIsolationScope()}function X_(){return as("globalScope",()=>new gn)}function $_(...n){const t=Il(),a=th(t);if(n.length===2){const[r,l]=n;return r?a.withSetScope(r,l):a.withScope(l)}return a.withScope(n[0])}function gt(){return vn().getClient()}function Z_(n){const t=n.getPropagationContext(),{traceId:a,parentSpanId:r,propagationSpanId:l}=t,c={trace_id:a,span_id:l||Yx()};return r&&(c.parent_span_id=r),c}const Q_="sentry.source",W_="sentry.sample_rate",J_="sentry.previous_trace_sample_rate",eT="sentry.op",tT="sentry.origin",Xx="sentry.profile_id",$x="sentry.exclusive_time",nT="gen_ai.conversation.id",iT=0,aT=1;function sT(n){if(n){if(typeof n=="object"&&"deref"in n&&typeof n.deref=="function")try{return n.deref()}catch{return}return n}}const rT="_sentryScope",oT="_sentryIsolationScope";function Zx(n){const t=n;return{scope:t[rT],isolationScope:sT(t[oT])}}const a0="sentry-";function lT(n){const t=cT(n);if(!t)return;const a=Object.entries(t).reduce((r,[l,c])=>{if(l.startsWith(a0)){const f=l.slice(a0.length);r[f]=c}return r},{});if(Object.keys(a).length>0)return a}function cT(n){if(!(!n||!Un(n)&&!Array.isArray(n)))return Array.isArray(n)?n.reduce((t,a)=>{const r=s0(a);return Object.entries(r).forEach(([l,c])=>{t[l]=c}),t},{}):s0(n)}function s0(n){return n.split(",").map(t=>{const a=t.indexOf("=");if(a===-1)return[];const r=t.slice(0,a),l=t.slice(a+1);return[r,l].map(c=>{try{return decodeURIComponent(c.trim())}catch{return}})}).reduce((t,[a,r])=>(a&&r&&(t[a]=r),t),{})}const uT=/^o(\d+)\./,fT=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)((?:\[[:.%\w]+\]|[\w.-]+))(?::(\d+))?\/(.+)/;function dT(n){return n==="http"||n==="https"}function Cr(n,t=!1){const{host:a,path:r,pass:l,port:c,projectId:f,protocol:h,publicKey:m}=n;return`${h}://${m}${t&&l?`:${l}`:""}@${a}${c?`:${c}`:""}/${r&&`${r}/`}${f}`}function hT(n){const t=fT.exec(n);if(!t){ss(()=>{console.error(`Invalid Sentry Dsn: ${n}`)});return}const[a,r,l="",c="",f="",h=""]=t.slice(1);let m="",p=h;const v=p.split("/");if(v.length>1&&(m=v.slice(0,-1).join("/"),p=v.pop()),p){const x=p.match(/^\d+/);x&&(p=x[0])}return Qx({host:c,pass:l,path:m,projectId:p,port:f,protocol:a,publicKey:r})}function Qx(n){return{protocol:n.protocol,publicKey:n.publicKey||"",pass:n.pass||"",host:n.host,port:n.port||"",path:n.path||"",projectId:n.projectId}}function mT(n){if(!ce)return!0;const{port:t,projectId:a,protocol:r}=n;return["protocol","publicKey","host","projectId"].find(f=>n[f]?!1:(ae.error(`Invalid Sentry Dsn: ${f} missing`),!0))?!1:a.match(/^\d+$/)?dT(r)?t&&isNaN(parseInt(t,10))?(ae.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(ae.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(ae.error(`Invalid Sentry Dsn: Invalid projectId ${a}`),!1)}function pT(n){const t=n.match(uT);return t==null?void 0:t[1]}function gT(n){const t=n.getOptions(),{host:a}=n.getDsn()||{};let r;return t.orgId?r=String(t.orgId):a&&(r=pT(a)),r}function yT(n){const t=typeof n=="string"?hT(n):Qx(n);if(!(!t||!mT(t)))return t}function vT(n){if(typeof n=="boolean")return Number(n);const t=typeof n=="string"?parseFloat(n):n;if(!(typeof t!="number"||isNaN(t)||t<0||t>1))return t}const Wx=1;let r0=!1;function xT(n){const{spanId:t,traceId:a,isRemote:r}=n.spanContext(),l=r?t:Zl(n).parent_span_id,c=Zx(n).scope,f=r?(c==null?void 0:c.getPropagationContext().propagationSpanId)||Yx():t;return{parent_span_id:l,span_id:f,trace_id:a}}function bT(n){if(n&&n.length>0)return n.map(({context:{spanId:t,traceId:a,traceFlags:r,...l},attributes:c})=>({span_id:t,trace_id:a,sampled:r===Wx,attributes:c,...l}))}function o0(n){return typeof n=="number"?l0(n):Array.isArray(n)?n[0]+n[1]/1e9:n instanceof Date?l0(n.getTime()):Pn()}function l0(n){return n>9999999999?n/1e3:n}function Zl(n){if(_T(n))return n.getSpanJSON();const{spanId:t,traceId:a}=n.spanContext();if(wT(n)){const{attributes:r,startTime:l,name:c,endTime:f,status:h,links:m}=n;return{span_id:t,trace_id:a,data:r,description:c,parent_span_id:ST(n),start_timestamp:o0(l),timestamp:o0(f)||void 0,status:ET(h),op:r[eT],origin:r[tT],links:bT(m)}}return{span_id:t,trace_id:a,start_timestamp:0,data:{}}}function ST(n){var t;return"parentSpanId"in n?n.parentSpanId:"parentSpanContext"in n?(t=n.parentSpanContext)==null?void 0:t.spanId:void 0}function wT(n){const t=n;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function _T(n){return typeof n.getSpanJSON=="function"}function TT(n){const{traceFlags:t}=n.spanContext();return t===Wx}function ET(n){if(!(!n||n.code===iT))return n.code===aT?"ok":n.message||"internal_error"}const AT="_sentryRootSpan",Jx=NT;function NT(n){return n[AT]||n}function c0(){r0||(ss(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly or use `ignoreSpans`.")}),r0=!0)}function DT(n){var a;if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=(a=gt())==null?void 0:a.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}function u0(n){ae.log(`Ignoring span ${n.op} - ${n.description} because it matches \`ignoreSpans\`.`)}function f0(n,t){if(!(t!=null&&t.length)||!n.description)return!1;for(const a of t){if(jT(a)){if(cl(n.description,a))return ce&&u0(n),!0;continue}if(!a.name&&!a.op)continue;const r=a.name?cl(n.description,a.name):!0,l=a.op?n.op&&cl(n.op,a.op):!0;if(r&&l)return ce&&u0(n),!0}return!1}function CT(n,t){const a=t.parent_span_id,r=t.span_id;if(a)for(const l of n)l.parent_span_id===r&&(l.parent_span_id=a)}function jT(n){return typeof n=="string"||n instanceof RegExp}const nh="production",MT="_frozenDsc";function eb(n,t){const a=t.getOptions(),{publicKey:r}=t.getDsn()||{},l={environment:a.environment||nh,release:a.release,public_key:r,trace_id:n,org_id:gT(t)};return t.emit("createDsc",l),l}function OT(n,t){const a=t.getPropagationContext();return a.dsc||eb(a.traceId,n)}function RT(n){var T;const t=gt();if(!t)return{};const a=Jx(n),r=Zl(a),l=r.data,c=a.spanContext().traceState,f=(c==null?void 0:c.get("sentry.sample_rate"))??l[W_]??l[J_];function h(k){return(typeof f=="number"||typeof f=="string")&&(k.sample_rate=`${f}`),k}const m=a[MT];if(m)return h(m);const p=c==null?void 0:c.get("sentry.dsc"),v=p&&lT(p);if(v)return h(v);const x=eb(n.spanContext().traceId,t),S=l[Q_]??l["sentry.span.source"],w=r.description;return S!=="url"&&w&&(x.transaction=w),DT()&&(x.sampled=String(TT(a)),x.sample_rand=(c==null?void 0:c.get("sentry.sample_rand"))??((T=Zx(a).scope)==null?void 0:T.getPropagationContext().sampleRand.toString())),h(x),t.emit("createDsc",x,a),x}function kT(n){return!!n&&typeof n=="function"&&"_streamed"in n&&!!n._streamed}function Bn(n,t=100,a=1/0){try{return od("",n,t,a)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function tb(n,t=3,a=100*1024){const r=Bn(n,t);return BT(r)>a?tb(n,t-1,a):r}function od(n,t,a=1/0,r=1/0,l=UT()){const[c,f]=l;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const h=LT(n,t);if(!h.startsWith("[object "))return h;if(t.__sentry_skip_normalization__)return t;const m=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:a;if(m===0)return h.replace("object ","");if(c(t))return"[Circular ~]";const p=t;if(p&&typeof p.toJSON=="function")try{const w=p.toJSON();return od("",w,m-1,r,l)}catch{}const v=Array.isArray(t)?[]:{};let x=0;const S=qx(t);for(const w in S){if(!Object.prototype.hasOwnProperty.call(S,w))continue;if(x>=r){v[w]="[MaxProperties ~]";break}const T=S[w];v[w]=od(w,T,m-1,r,l),x++}return f(t),v}function LT(n,t){try{if(n==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(n==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Ux(t))return zx(t);if(N_(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${yi(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const a=zT(t);return/^HTML(\w*)Element$/.test(a)?`[HTMLElement: ${a}]`:`[object ${a}]`}catch(a){return`**non-serializable** (${a})`}}function zT(n){const t=Object.getPrototypeOf(n);return t!=null&&t.constructor?t.constructor.name:"null prototype"}function VT(n){return~-encodeURI(n).split(/%..|./).length}function BT(n){return VT(JSON.stringify(n))}function UT(){const n=new WeakSet;function t(r){return n.has(r)?!0:(n.add(r),!1)}function a(r){n.delete(r)}return[t,a]}function os(n,t=[]){return[n,t]}function PT(n,t){const[a,r]=n;return[a,[...r,t]]}function ld(n,t){const a=n[1];for(const r of a){const l=r[0].type;if(t(r,l))return!0}return!1}function HT(n,t){return ld(n,(a,r)=>t.includes(r))}function cd(n){const t=ql(Oe);return t.encodePolyfill?t.encodePolyfill(n):new TextEncoder().encode(n)}function IT(n){const[t,a]=n;let r=JSON.stringify(t);function l(c){typeof r=="string"?r=typeof c=="string"?r+c:[cd(r),c]:r.push(typeof c=="string"?cd(c):c)}for(const c of a){const[f,h]=c;if(l(` +Error:`,l)}}let Ef=null;function S_(n){const t="error";na(t,n),ia(t,w_)}function w_(){Ef=Oe.onerror,Oe.onerror=function(n,t,a,r,l){return rn("error",{column:r,error:l,line:a,msg:n,url:t}),Ef?Ef.apply(this,arguments):!1},Oe.onerror.__SENTRY_INSTRUMENTED__=!0}let Af=null;function __(n){const t="unhandledrejection";na(t,n),ia(t,T_)}function T_(){Af=Oe.onunhandledrejection,Oe.onunhandledrejection=function(n){return rn("unhandledrejection",n),Af?Af.apply(this,arguments):!0},Oe.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const Vx=Object.prototype.toString;function Fl(n){switch(Vx.call(n)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return vi(n,Error)}}function rs(n,t){return Vx.call(n)===`[object ${t}]`}function Bx(n){return rs(n,"ErrorEvent")}function Ky(n){return rs(n,"DOMError")}function E_(n){return rs(n,"DOMException")}function Un(n){return rs(n,"String")}function Qd(n){return typeof n=="object"&&n!==null&&"__sentry_template_string__"in n&&"__sentry_template_values__"in n}function Gl(n){return n===null||Qd(n)||typeof n!="object"&&typeof n!="function"}function vr(n){return rs(n,"Object")}function Yl(n){return typeof Event<"u"&&vi(n,Event)}function A_(n){return typeof Element<"u"&&vi(n,Element)}function N_(n){return rs(n,"RegExp")}function Ar(n){return!!(n!=null&&n.then&&typeof n.then=="function")}function D_(n){return vr(n)&&"nativeEvent"in n&&"preventDefault"in n&&"stopPropagation"in n}function vi(n,t){try{return n instanceof t}catch{return!1}}function Ux(n){return!!(typeof n=="object"&&n!==null&&(n.__isVue||n._isVue||n.__v_isVNode))}function Px(n){return typeof Request<"u"&&vi(n,Request)}const Wd=Oe,C_=80;function Hx(n,t={}){if(!n)return"";try{let a=n;const r=5,l=[];let c=0,f=0;const h=" > ",m=h.length;let p;const v=Array.isArray(t)?t:t.keyAttrs,x=!Array.isArray(t)&&t.maxStringLength||C_;for(;a&&c++1&&f+l.length*m+p.length>=x));)l.push(p),f+=p.length,a=a.parentNode;return l.reverse().join(h)}catch{return""}}function j_(n,t){const a=n,r=[];if(!(a!=null&&a.tagName))return"";if(Wd.HTMLElement&&a instanceof HTMLElement&&a.dataset){if(a.dataset.sentryComponent)return a.dataset.sentryComponent;if(a.dataset.sentryElement)return a.dataset.sentryElement}r.push(a.tagName.toLowerCase());const l=t!=null&&t.length?t.filter(c=>a.getAttribute(c)).map(c=>[c,a.getAttribute(c)]):null;if(l!=null&&l.length)l.forEach(c=>{r.push(`[${c[0]}="${c[1]}"]`)});else{a.id&&r.push(`#${a.id}`);const c=a.className;if(c&&Un(c)){const f=c.split(/\s+/);for(const h of f)r.push(`.${h}`)}}for(const c of["aria-label","type","name","title","alt"]){const f=a.getAttribute(c);f&&r.push(`[${c}="${f}"]`)}return r.join("")}function Jd(){try{return Wd.document.location.href}catch{return""}}function M_(n,t=5){if(!Wd.HTMLElement)return null;let a=n;for(let r=0;r"}}function $y(n){return typeof n=="object"&&n!==null?Object.fromEntries(Object.entries(n)):{}}function O_(n){const t=Object.keys(qx(n));return t.sort(),t[0]?t.join(", "):"[object has no keys]"}let Ia;function Kl(n){if(Ia!==void 0)return Ia?Ia(n):n();const t=Symbol.for("__SENTRY_SAFE_RANDOM_ID_WRAPPER__"),a=Oe;return t in a&&typeof a[t]=="function"?(Ia=a[t],Ia(n)):(Ia=null,n())}function _l(){return Kl(()=>Math.random())}function Xl(){return Kl(()=>Date.now())}function ad(n,t=0){return typeof n!="string"||t===0||n.length<=t?n:`${n.slice(0,t)}...`}function Zy(n,t){if(!Array.isArray(n))return"";const a=[];for(let r=0;rcl(n,r,a))}function R_(){const n=Oe;return n.crypto||n.msCrypto}let Nf;function k_(){return _l()*16}function Wt(n=R_()){try{if(n!=null&&n.randomUUID)return Kl(()=>n.randomUUID()).replace(/-/g,"")}catch{}return Nf||(Nf="10000000100040008000"+1e11),Nf.replace(/[018]/g,t=>(t^(k_()&15)>>t/4).toString(16))}function Fx(n){var t,a;return(a=(t=n.exception)==null?void 0:t.values)==null?void 0:a[0]}function Yi(n){const{message:t,event_id:a}=n;if(t)return t;const r=Fx(n);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||a||"":a||""}function sd(n,t,a){const r=n.exception=n.exception||{},l=r.values=r.values||[],c=l[0]=l[0]||{};c.value||(c.value=t||""),c.type||(c.type="Error")}function Wa(n,t){const a=Fx(n);if(!a)return;const r={type:"generic",handled:!0},l=a.mechanism;if(a.mechanism={...r,...l,...t},t&&"data"in t){const c={...l==null?void 0:l.data,...t.data};a.mechanism.data=c}}function Qy(n){if(L_(n))return!0;try{xi(n,"__sentry_captured__",!0)}catch{}return!1}function L_(n){try{return n.__sentry_captured__}catch{}}const Gx=1e3;function Nr(){return Xl()/Gx}function z_(){const{performance:n}=Oe;if(!(n!=null&&n.now)||!n.timeOrigin)return Nr;const t=n.timeOrigin;return()=>(t+Kl(()=>n.now()))/Gx}let Wy;function Pn(){return(Wy??(Wy=z_()))()}function V_(n){const t=Pn(),a={sid:Wt(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>U_(a)};return n&&Ja(a,n),a}function Ja(n,t={}){if(t.user&&(!n.ipAddress&&t.user.ip_address&&(n.ipAddress=t.user.ip_address),!n.did&&!t.did&&(n.did=t.user.id||t.user.email||t.user.username)),n.timestamp=t.timestamp||Pn(),t.abnormal_mechanism&&(n.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(n.ignoreDuration=t.ignoreDuration),t.sid&&(n.sid=t.sid.length===32?t.sid:Wt()),t.init!==void 0&&(n.init=t.init),!n.did&&t.did&&(n.did=`${t.did}`),typeof t.started=="number"&&(n.started=t.started),n.ignoreDuration)n.duration=void 0;else if(typeof t.duration=="number")n.duration=t.duration;else{const a=n.timestamp-n.started;n.duration=a>=0?a:0}t.release&&(n.release=t.release),t.environment&&(n.environment=t.environment),!n.ipAddress&&t.ipAddress&&(n.ipAddress=t.ipAddress),!n.userAgent&&t.userAgent&&(n.userAgent=t.userAgent),typeof t.errors=="number"&&(n.errors=t.errors),t.status&&(n.status=t.status)}function B_(n,t){let a={};n.status==="ok"&&(a={status:"exited"}),Ja(n,a)}function U_(n){return{sid:`${n.sid}`,init:n.init,started:new Date(n.started*1e3).toISOString(),timestamp:new Date(n.timestamp*1e3).toISOString(),status:n.status,errors:n.errors,did:typeof n.did=="number"||typeof n.did=="string"?`${n.did}`:void 0,duration:n.duration,abnormal_mechanism:n.abnormal_mechanism,attrs:{release:n.release,environment:n.environment,ip_address:n.ipAddress,user_agent:n.userAgent}}}function Dr(n,t,a=2){if(!t||typeof t!="object"||a<=0)return t;if(n&&Object.keys(t).length===0)return n;const r={...n};for(const l in t)Object.prototype.hasOwnProperty.call(t,l)&&(r[l]=Dr(r[l],t[l],a-1));return r}function Jy(){return Wt()}function Yx(){return Wt().substring(16)}const rd="_sentrySpan";function e0(n,t){t?xi(n,rd,t):delete n[rd]}function t0(n){return n[rd]}const P_=100;class gn{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:Jy(),sampleRand:_l()}}clone(){const t=new gn;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,t._conversationId=this._conversationId,e0(t,t0(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&Ja(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}setConversationId(t){return this._conversationId=t||void 0,this._notifyScopeListeners(),this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,a){return this.setTags({[t]:a})}setAttributes(t){return this._attributes={...this._attributes,...t},this._notifyScopeListeners(),this}setAttribute(t,a){return this.setAttributes({[t]:a})}removeAttribute(t){return t in this._attributes&&(delete this._attributes[t],this._notifyScopeListeners()),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,a){return this._extra={...this._extra,[t]:a},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,a){return a===null?delete this._contexts[t]:this._contexts[t]=a,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const a=typeof t=="function"?t(this):t,r=a instanceof gn?a.getScopeData():vr(a)?t:void 0,{tags:l,attributes:c,extra:f,user:h,contexts:m,level:p,fingerprint:v=[],propagationContext:x,conversationId:S}=r||{};return this._tags={...this._tags,...l},this._attributes={...this._attributes,...c},this._extra={...this._extra,...f},this._contexts={...this._contexts,...m},h&&Object.keys(h).length&&(this._user=h),p&&(this._level=p),v.length&&(this._fingerprint=v),x&&(this._propagationContext=x),S&&(this._conversationId=S),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,this._conversationId=void 0,e0(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Jy(),sampleRand:_l()}),this._notifyScopeListeners(),this}addBreadcrumb(t,a){var c;const r=typeof a=="number"?a:P_;if(r<=0)return this;const l={timestamp:Nr(),...t,message:t.message?ad(t.message,2048):t.message};return this._breadcrumbs.push(l),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),(c=this._client)==null||c.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:t0(this),conversationId:this._conversationId}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Dr(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,a){const r=(a==null?void 0:a.event_id)||Wt();if(!this._client)return ce&&ae.warn("No client configured on scope - will not capture exception!"),r;const l=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:l,...a,event_id:r},this),r}captureMessage(t,a,r){const l=(r==null?void 0:r.event_id)||Wt();if(!this._client)return ce&&ae.warn("No client configured on scope - will not capture message!"),l;const c=(r==null?void 0:r.syntheticException)??new Error(t);return this._client.captureMessage(t,a,{originalException:t,syntheticException:c,...r,event_id:l},this),l}captureEvent(t,a){const r=t.event_id||(a==null?void 0:a.event_id)||Wt();return this._client?(this._client.captureEvent(t,{...a,event_id:r},this),r):(ce&&ae.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}function H_(){return as("defaultCurrentScope",()=>new gn)}function I_(){return as("defaultIsolationScope",()=>new gn)}const n0=n=>n instanceof Promise&&!n[Kx],Kx=Symbol("chained PromiseLike"),q_=(n,t,a)=>{const r=n.then(l=>(t(l),l),l=>{throw a(l),l});return n0(r)&&n0(n)?r:F_(n,r)},F_=(n,t)=>{let a=!1;for(const r in n){if(r in t)continue;a=!0;const l=n[r];typeof l=="function"?Object.defineProperty(t,r,{value:(...c)=>l.apply(n,c),enumerable:!0,configurable:!0,writable:!0}):t[r]=l}return a&&Object.assign(t,{[Kx]:!0}),t};class G_{constructor(t,a){let r;t?r=t:r=new gn;let l;a?l=a:l=new gn,this._stack=[{scope:r}],this._isolationScope=l}withScope(t){const a=this._pushScope();let r;try{r=t(a)}catch(l){throw this._popScope(),l}return Ar(r)?q_(r,()=>this._popScope(),()=>this._popScope()):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function es(){const n=Il(),t=ql(n);return t.stack=t.stack||new G_(H_(),I_())}function Y_(n){return es().withScope(n)}function K_(n,t){const a=es();return a.withScope(()=>(a.getStackTop().scope=n,t(n)))}function i0(n){return es().withScope(()=>n(es().getIsolationScope()))}function X_(){return{withIsolationScope:i0,withScope:Y_,withSetScope:K_,withSetIsolationScope:(n,t)=>i0(t),getCurrentScope:()=>es().getScope(),getIsolationScope:()=>es().getIsolationScope()}}function th(n){const t=ql(n);return t.acs?t.acs:X_()}function vn(){const n=Il();return th(n).getCurrentScope()}function wi(){const n=Il();return th(n).getIsolationScope()}function $_(){return as("globalScope",()=>new gn)}function Z_(...n){const t=Il(),a=th(t);if(n.length===2){const[r,l]=n;return r?a.withSetScope(r,l):a.withScope(l)}return a.withScope(n[0])}function gt(){return vn().getClient()}function Q_(n){const t=n.getPropagationContext(),{traceId:a,parentSpanId:r,propagationSpanId:l}=t,c={trace_id:a,span_id:l||Yx()};return r&&(c.parent_span_id=r),c}const W_="sentry.source",J_="sentry.sample_rate",eT="sentry.previous_trace_sample_rate",tT="sentry.op",nT="sentry.origin",Xx="sentry.profile_id",$x="sentry.exclusive_time",iT="gen_ai.conversation.id",aT=0,sT=1;function rT(n){if(n){if(typeof n=="object"&&"deref"in n&&typeof n.deref=="function")try{return n.deref()}catch{return}return n}}const oT="_sentryScope",lT="_sentryIsolationScope";function Zx(n){const t=n;return{scope:t[oT],isolationScope:rT(t[lT])}}const a0="sentry-";function cT(n){const t=uT(n);if(!t)return;const a=Object.entries(t).reduce((r,[l,c])=>{if(l.startsWith(a0)){const f=l.slice(a0.length);r[f]=c}return r},{});if(Object.keys(a).length>0)return a}function uT(n){if(!(!n||!Un(n)&&!Array.isArray(n)))return Array.isArray(n)?n.reduce((t,a)=>{const r=s0(a);return Object.entries(r).forEach(([l,c])=>{t[l]=c}),t},{}):s0(n)}function s0(n){return n.split(",").map(t=>{const a=t.indexOf("=");if(a===-1)return[];const r=t.slice(0,a),l=t.slice(a+1);return[r,l].map(c=>{try{return decodeURIComponent(c.trim())}catch{return}})}).reduce((t,[a,r])=>(a&&r&&(t[a]=r),t),{})}const fT=/^o(\d+)\./,dT=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)((?:\[[:.%\w]+\]|[\w.-]+))(?::(\d+))?\/(.+)/;function hT(n){return n==="http"||n==="https"}function Cr(n,t=!1){const{host:a,path:r,pass:l,port:c,projectId:f,protocol:h,publicKey:m}=n;return`${h}://${m}${t&&l?`:${l}`:""}@${a}${c?`:${c}`:""}/${r&&`${r}/`}${f}`}function mT(n){const t=dT.exec(n);if(!t){ss(()=>{console.error(`Invalid Sentry Dsn: ${n}`)});return}const[a,r,l="",c="",f="",h=""]=t.slice(1);let m="",p=h;const v=p.split("/");if(v.length>1&&(m=v.slice(0,-1).join("/"),p=v.pop()),p){const x=p.match(/^\d+/);x&&(p=x[0])}return Qx({host:c,pass:l,path:m,projectId:p,port:f,protocol:a,publicKey:r})}function Qx(n){return{protocol:n.protocol,publicKey:n.publicKey||"",pass:n.pass||"",host:n.host,port:n.port||"",path:n.path||"",projectId:n.projectId}}function pT(n){if(!ce)return!0;const{port:t,projectId:a,protocol:r}=n;return["protocol","publicKey","host","projectId"].find(f=>n[f]?!1:(ae.error(`Invalid Sentry Dsn: ${f} missing`),!0))?!1:a.match(/^\d+$/)?hT(r)?t&&isNaN(parseInt(t,10))?(ae.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(ae.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(ae.error(`Invalid Sentry Dsn: Invalid projectId ${a}`),!1)}function gT(n){const t=n.match(fT);return t==null?void 0:t[1]}function yT(n){const t=n.getOptions(),{host:a}=n.getDsn()||{};let r;return t.orgId?r=String(t.orgId):a&&(r=gT(a)),r}function vT(n){const t=typeof n=="string"?mT(n):Qx(n);if(!(!t||!pT(t)))return t}function xT(n){if(typeof n=="boolean")return Number(n);const t=typeof n=="string"?parseFloat(n):n;if(!(typeof t!="number"||isNaN(t)||t<0||t>1))return t}const Wx=1;let r0=!1;function bT(n){const{spanId:t,traceId:a,isRemote:r}=n.spanContext(),l=r?t:Zl(n).parent_span_id,c=Zx(n).scope,f=r?(c==null?void 0:c.getPropagationContext().propagationSpanId)||Yx():t;return{parent_span_id:l,span_id:f,trace_id:a}}function ST(n){if(n&&n.length>0)return n.map(({context:{spanId:t,traceId:a,traceFlags:r,...l},attributes:c})=>({span_id:t,trace_id:a,sampled:r===Wx,attributes:c,...l}))}function o0(n){return typeof n=="number"?l0(n):Array.isArray(n)?n[0]+n[1]/1e9:n instanceof Date?l0(n.getTime()):Pn()}function l0(n){return n>9999999999?n/1e3:n}function Zl(n){if(TT(n))return n.getSpanJSON();const{spanId:t,traceId:a}=n.spanContext();if(_T(n)){const{attributes:r,startTime:l,name:c,endTime:f,status:h,links:m}=n;return{span_id:t,trace_id:a,data:r,description:c,parent_span_id:wT(n),start_timestamp:o0(l),timestamp:o0(f)||void 0,status:AT(h),op:r[tT],origin:r[nT],links:ST(m)}}return{span_id:t,trace_id:a,start_timestamp:0,data:{}}}function wT(n){var t;return"parentSpanId"in n?n.parentSpanId:"parentSpanContext"in n?(t=n.parentSpanContext)==null?void 0:t.spanId:void 0}function _T(n){const t=n;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function TT(n){return typeof n.getSpanJSON=="function"}function ET(n){const{traceFlags:t}=n.spanContext();return t===Wx}function AT(n){if(!(!n||n.code===aT))return n.code===sT?"ok":n.message||"internal_error"}const NT="_sentryRootSpan",Jx=DT;function DT(n){return n[NT]||n}function c0(){r0||(ss(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly or use `ignoreSpans`.")}),r0=!0)}function CT(n){var a;if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=(a=gt())==null?void 0:a.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}function u0(n){ae.log(`Ignoring span ${n.op} - ${n.description} because it matches \`ignoreSpans\`.`)}function f0(n,t){if(!(t!=null&&t.length)||!n.description)return!1;for(const a of t){if(MT(a)){if(cl(n.description,a))return ce&&u0(n),!0;continue}if(!a.name&&!a.op)continue;const r=a.name?cl(n.description,a.name):!0,l=a.op?n.op&&cl(n.op,a.op):!0;if(r&&l)return ce&&u0(n),!0}return!1}function jT(n,t){const a=t.parent_span_id,r=t.span_id;if(a)for(const l of n)l.parent_span_id===r&&(l.parent_span_id=a)}function MT(n){return typeof n=="string"||n instanceof RegExp}const nh="production",OT="_frozenDsc";function eb(n,t){const a=t.getOptions(),{publicKey:r}=t.getDsn()||{},l={environment:a.environment||nh,release:a.release,public_key:r,trace_id:n,org_id:yT(t)};return t.emit("createDsc",l),l}function RT(n,t){const a=t.getPropagationContext();return a.dsc||eb(a.traceId,n)}function kT(n){var T;const t=gt();if(!t)return{};const a=Jx(n),r=Zl(a),l=r.data,c=a.spanContext().traceState,f=(c==null?void 0:c.get("sentry.sample_rate"))??l[J_]??l[eT];function h(k){return(typeof f=="number"||typeof f=="string")&&(k.sample_rate=`${f}`),k}const m=a[OT];if(m)return h(m);const p=c==null?void 0:c.get("sentry.dsc"),v=p&&cT(p);if(v)return h(v);const x=eb(n.spanContext().traceId,t),S=l[W_]??l["sentry.span.source"],w=r.description;return S!=="url"&&w&&(x.transaction=w),CT()&&(x.sampled=String(ET(a)),x.sample_rand=(c==null?void 0:c.get("sentry.sample_rand"))??((T=Zx(a).scope)==null?void 0:T.getPropagationContext().sampleRand.toString())),h(x),t.emit("createDsc",x,a),x}function LT(n){return!!n&&typeof n=="function"&&"_streamed"in n&&!!n._streamed}function Bn(n,t=100,a=1/0){try{return od("",n,t,a)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function tb(n,t=3,a=100*1024){const r=Bn(n,t);return UT(r)>a?tb(n,t-1,a):r}function od(n,t,a=1/0,r=1/0,l=PT()){const[c,f]=l;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const h=zT(n,t);if(!h.startsWith("[object "))return h;if(t.__sentry_skip_normalization__)return t;const m=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:a;if(m===0)return h.replace("object ","");if(c(t))return"[Circular ~]";const p=t;if(p&&typeof p.toJSON=="function")try{const w=p.toJSON();return od("",w,m-1,r,l)}catch{}const v=Array.isArray(t)?[]:{};let x=0;const S=qx(t);for(const w in S){if(!Object.prototype.hasOwnProperty.call(S,w))continue;if(x>=r){v[w]="[MaxProperties ~]";break}const T=S[w];v[w]=od(w,T,m-1,r,l),x++}return f(t),v}function zT(n,t){try{if(n==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(n==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Ux(t))return zx(t);if(D_(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${yi(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const a=VT(t);return/^HTML(\w*)Element$/.test(a)?`[HTMLElement: ${a}]`:`[object ${a}]`}catch(a){return`**non-serializable** (${a})`}}function VT(n){const t=Object.getPrototypeOf(n);return t!=null&&t.constructor?t.constructor.name:"null prototype"}function BT(n){return~-encodeURI(n).split(/%..|./).length}function UT(n){return BT(JSON.stringify(n))}function PT(){const n=new WeakSet;function t(r){return n.has(r)?!0:(n.add(r),!1)}function a(r){n.delete(r)}return[t,a]}function os(n,t=[]){return[n,t]}function HT(n,t){const[a,r]=n;return[a,[...r,t]]}function ld(n,t){const a=n[1];for(const r of a){const l=r[0].type;if(t(r,l))return!0}return!1}function IT(n,t){return ld(n,(a,r)=>t.includes(r))}function cd(n){const t=ql(Oe);return t.encodePolyfill?t.encodePolyfill(n):new TextEncoder().encode(n)}function qT(n){const[t,a]=n;let r=JSON.stringify(t);function l(c){typeof r=="string"?r=typeof c=="string"?r+c:[cd(r),c]:r.push(typeof c=="string"?cd(c):c)}for(const c of a){const[f,h]=c;if(l(` ${JSON.stringify(f)} -`),typeof h=="string"||h instanceof Uint8Array)l(h);else{let m;try{m=JSON.stringify(h)}catch{m=JSON.stringify(Bn(h))}l(m)}}return typeof r=="string"?r:qT(r)}function qT(n){const t=n.reduce((l,c)=>l+c.length,0),a=new Uint8Array(t);let r=0;for(const l of n)a.set(l,r),r+=l.length;return a}function FT(n){const t=typeof n.data=="string"?cd(n.data):n.data;return[{type:"attachment",length:t.length,filename:n.filename,content_type:n.contentType,attachment_type:n.attachmentType},t]}const nb={sessions:"session",event:"error",client_report:"internal",user_report:"default",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",raw_security:"security",log:"log_item",trace_metric:"metric"};function GT(n){return n in nb}function d0(n){return GT(n)?nb[n]:n}function ib(n){if(!(n!=null&&n.sdk))return;const{name:t,version:a}=n.sdk;return{name:t,version:a}}function YT(n,t,a,r){var c;const l=(c=n.sdkProcessingMetadata)==null?void 0:c.dynamicSamplingContext;return{event_id:n.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!a&&r&&{dsn:Cr(r)},...l&&{trace:l}}}function KT(n,t){var r,l,c,f;if(!t)return n;const a=n.sdk||{};return n.sdk={...a,name:a.name||t.name,version:a.version||t.version,integrations:[...((r=n.sdk)==null?void 0:r.integrations)||[],...t.integrations||[]],packages:[...((l=n.sdk)==null?void 0:l.packages)||[],...t.packages||[]],settings:(c=n.sdk)!=null&&c.settings||t.settings?{...(f=n.sdk)==null?void 0:f.settings,...t.settings}:void 0},n}function XT(n,t,a,r){const l=ib(a),c={sent_at:new Date().toISOString(),...l&&{sdk:l},...!!r&&t&&{dsn:Cr(t)}},f="aggregates"in n?[{type:"sessions"},n]:[{type:"session"},n.toJSON()];return os(c,[f])}function $T(n,t,a,r){const l=ib(a),c=n.type&&n.type!=="replay_event"?n.type:"event";KT(n,a==null?void 0:a.sdk);const f=YT(n,l,r,t);return delete n.sdkProcessingMetadata,os(f,[[{type:c},n]])}function ZT(n,t){const{fingerprint:a,span:r,breadcrumbs:l,sdkProcessingMetadata:c}=t;QT(n,t),r&&eE(n,r),tE(n,a),WT(n,l),JT(n,c)}function h0(n,t){const{extra:a,tags:r,attributes:l,user:c,contexts:f,level:h,sdkProcessingMetadata:m,breadcrumbs:p,fingerprint:v,eventProcessors:x,attachments:S,propagationContext:w,transactionName:T,span:k}=t;sr(n,"extra",a),sr(n,"tags",r),sr(n,"attributes",l),sr(n,"user",c),sr(n,"contexts",f),n.sdkProcessingMetadata=Dr(n.sdkProcessingMetadata,m,2),h&&(n.level=h),T&&(n.transactionName=T),k&&(n.span=k),p.length&&(n.breadcrumbs=[...n.breadcrumbs,...p]),v.length&&(n.fingerprint=[...n.fingerprint,...v]),x.length&&(n.eventProcessors=[...n.eventProcessors,...x]),S.length&&(n.attachments=[...n.attachments,...S]),n.propagationContext={...n.propagationContext,...w}}function sr(n,t,a){n[t]=Dr(n[t],a,1)}function ab(n,t){const a=X_().getScopeData();return n&&h0(a,n.getScopeData()),t&&h0(a,t.getScopeData()),a}function QT(n,t){const{extra:a,tags:r,user:l,contexts:c,level:f,transactionName:h}=t;Object.keys(a).length&&(n.extra={...a,...n.extra}),Object.keys(r).length&&(n.tags={...r,...n.tags}),Object.keys(l).length&&(n.user={...l,...n.user}),Object.keys(c).length&&(n.contexts={...c,...n.contexts}),f&&(n.level=f),h&&n.type!=="transaction"&&(n.transaction=h)}function WT(n,t){const a=[...n.breadcrumbs||[],...t];n.breadcrumbs=a.length?a:void 0}function JT(n,t){n.sdkProcessingMetadata={...n.sdkProcessingMetadata,...t}}function eE(n,t){n.contexts={trace:xT(t),...n.contexts},n.sdkProcessingMetadata={dynamicSamplingContext:RT(t),...n.sdkProcessingMetadata};const a=Jx(t),r=Zl(a).description;r&&!n.transaction&&n.type==="transaction"&&(n.transaction=r)}function tE(n,t){n.fingerprint=n.fingerprint?Array.isArray(n.fingerprint)?n.fingerprint:[n.fingerprint]:[],t&&(n.fingerprint=n.fingerprint.concat(t)),n.fingerprint.length||delete n.fingerprint}const Df=0,m0=1,p0=2;function jr(n){return new xr(t=>{t(n)})}function ih(n){return new xr((t,a)=>{a(n)})}class xr{constructor(t){this._state=Df,this._handlers=[],this._runExecutor(t)}then(t,a){return new xr((r,l)=>{this._handlers.push([!1,c=>{if(!t)r(c);else try{r(t(c))}catch(f){l(f)}},c=>{if(!a)l(c);else try{r(a(c))}catch(f){l(f)}}]),this._executeHandlers()})}catch(t){return this.then(a=>a,t)}finally(t){return new xr((a,r)=>{let l,c;return this.then(f=>{c=!1,l=f,t&&t()},f=>{c=!0,l=f,t&&t()}).then(()=>{if(c){r(l);return}a(l)})})}_executeHandlers(){if(this._state===Df)return;const t=this._handlers.slice();this._handlers=[],t.forEach(a=>{a[0]||(this._state===m0&&a[1](this._value),this._state===p0&&a[2](this._value),a[0]=!0)})}_runExecutor(t){const a=(c,f)=>{if(this._state===Df){if(Ar(f)){f.then(r,l);return}this._state=c,this._value=f,this._executeHandlers()}},r=c=>{a(m0,c)},l=c=>{a(p0,c)};try{t(r,l)}catch(c){l(c)}}}function nE(n,t,a,r=0){try{const l=ud(t,a,n,r);return Ar(l)?l:jr(l)}catch(l){return ih(l)}}function ud(n,t,a,r){const l=a[r];if(!n||!l)return n;const c=l({...n},t);return ce&&c===null&&ae.log(`Event processor "${l.id||"?"}" dropped event`),Ar(c)?c.then(f=>ud(f,t,a,r+1)):ud(c,t,a,r+1)}let Vn,g0,y0,hi;function iE(n){const t=Oe._sentryDebugIds,a=Oe._debugIds;if(!t&&!a)return{};const r=t?Object.keys(t):[],l=a?Object.keys(a):[];if(hi&&r.length===g0&&l.length===y0)return hi;g0=r.length,y0=l.length,hi={},Vn||(Vn={});const c=(f,h)=>{for(const m of f){const p=h[m],v=Vn==null?void 0:Vn[m];if(v&&hi&&p)hi[v[0]]=p,Vn&&(Vn[m]=[v[0],p]);else if(p){const x=n(m);for(let S=x.length-1;S>=0;S--){const w=x[S],T=w==null?void 0:w.filename;if(T&&hi&&Vn){hi[T]=p,Vn[m]=[T,p];break}}}}};return t&&c(r,t),a&&c(l,a),hi}function aE(n,t,a,r,l,c){const{normalizeDepth:f=3,normalizeMaxBreadth:h=1e3}=n,m={...t,event_id:t.event_id||a.event_id||Wt(),timestamp:t.timestamp||Nr()},p=a.integrations||n.integrations.map(B=>B.name);sE(m,n),lE(m,p),l&&l.emit("applyFrameMetadata",t),t.type===void 0&&rE(m,n.stackParser);const v=uE(r,a.captureContext);a.mechanism&&Wa(m,a.mechanism);const x=l?l.getEventProcessors():[],S=ab(c,v),w=[...a.attachments||[],...S.attachments];w.length&&(a.attachments=w),ZT(m,S);const T=[...x,...S.eventProcessors];return(a.data&&a.data.__sentry__===!0?jr(m):nE(T,m,a)).then(B=>(B&&oE(B),typeof f=="number"&&f>0?cE(B,f,h):B))}function sE(n,t){var h,m;const{environment:a,release:r,dist:l,maxValueLength:c}=t;n.environment=n.environment||a||nh,!n.release&&r&&(n.release=r),!n.dist&&l&&(n.dist=l);const f=n.request;f!=null&&f.url&&c&&(f.url=ad(f.url,c)),c&&((m=(h=n.exception)==null?void 0:h.values)==null||m.forEach(p=>{p.value&&(p.value=ad(p.value,c))}))}function rE(n,t){var r,l;const a=iE(t);(l=(r=n.exception)==null?void 0:r.values)==null||l.forEach(c=>{var f,h;(h=(f=c.stacktrace)==null?void 0:f.frames)==null||h.forEach(m=>{m.filename&&(m.debug_id=a[m.filename])})})}function oE(n){var r,l;const t={};if((l=(r=n.exception)==null?void 0:r.values)==null||l.forEach(c=>{var f,h;(h=(f=c.stacktrace)==null?void 0:f.frames)==null||h.forEach(m=>{m.debug_id&&(m.abs_path?t[m.abs_path]=m.debug_id:m.filename&&(t[m.filename]=m.debug_id),delete m.debug_id)})}),Object.keys(t).length===0)return;n.debug_meta=n.debug_meta||{},n.debug_meta.images=n.debug_meta.images||[];const a=n.debug_meta.images;Object.entries(t).forEach(([c,f])=>{a.push({type:"sourcemap",code_file:c,debug_id:f})})}function lE(n,t){t.length>0&&(n.sdk=n.sdk||{},n.sdk.integrations=[...n.sdk.integrations||[],...t])}function cE(n,t,a){var l,c;if(!n)return null;const r={...n,...n.breadcrumbs&&{breadcrumbs:n.breadcrumbs.map(f=>({...f,...f.data&&{data:Bn(f.data,t,a)}}))},...n.user&&{user:Bn(n.user,t,a)},...n.contexts&&{contexts:Bn(n.contexts,t,a)},...n.extra&&{extra:Bn(n.extra,t,a)}};return(l=n.contexts)!=null&&l.trace&&r.contexts&&(r.contexts.trace=n.contexts.trace,n.contexts.trace.data&&(r.contexts.trace.data=Bn(n.contexts.trace.data,t,a))),n.spans&&(r.spans=n.spans.map(f=>({...f,...f.data&&{data:Bn(f.data,t,a)}}))),(c=n.contexts)!=null&&c.flags&&r.contexts&&(r.contexts.flags=Bn(n.contexts.flags,3,a)),r}function uE(n,t){if(!t)return n;const a=n?n.clone():new gn;return a.update(t),a}function fE(n){if(n)return dE(n)?{captureContext:n}:mE(n)?{captureContext:n}:n}function dE(n){return n instanceof gn||typeof n=="function"}const hE=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function mE(n){return Object.keys(n).some(t=>hE.includes(t))}function Ji(n,t){return vn().captureException(n,fE(t))}function pE(n,t){const a=typeof t=="string"?t:void 0,r=typeof t!="string"?{captureContext:t}:void 0;return vn().captureMessage(n,a,r)}function sb(n,t){return vn().captureEvent(n,t)}function gE(n,t){wi().setContext(n,t)}function v0(n){const t=wi(),{user:a}=ab(t,vn()),{userAgent:r}=Oe.navigator||{},l=z_({user:a,...r&&{userAgent:r},...n}),c=t.getSession();return(c==null?void 0:c.status)==="ok"&&Ja(c,{status:"exited"}),rb(),t.setSession(l),l}function rb(){const n=wi(),a=vn().getSession()||n.getSession();a&&V_(a),ob(),n.setSession()}function ob(){const n=wi(),t=gt(),a=n.getSession();a&&t&&t.captureSession(a)}function Cf(n=!1){if(n){rb();return}ob()}const yE="7";function vE(n){const t=n.protocol?`${n.protocol}:`:"",a=n.port?`:${n.port}`:"";return`${t}//${n.host}${a}${n.path?`/${n.path}`:""}/api/`}function xE(n){return`${vE(n)}${n.projectId}/envelope/`}function bE(n,t){const a={sentry_version:yE};return n.publicKey&&(a.sentry_key=n.publicKey),t&&(a.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(a).toString()}function SE(n,t,a){return t||`${xE(n)}?${bE(n,a)}`}const x0=[];function wE(n){const t={};return n.forEach(a=>{const{name:r}=a,l=t[r];l&&!l.isDefaultInstance&&a.isDefaultInstance||(t[r]=a)}),Object.values(t)}function _E(n){const t=n.defaultIntegrations||[],a=n.integrations;t.forEach(l=>{l.isDefaultInstance=!0});let r;if(Array.isArray(a))r=[...t,...a];else if(typeof a=="function"){const l=a(t);r=Array.isArray(l)?l:[l]}else r=t;return wE(r)}function TE(n,t){const a={};return t.forEach(r=>{r!=null&&r.beforeSetup&&r.beforeSetup(n)}),t.forEach(r=>{r&&lb(n,r,a)}),a}function b0(n,t){for(const a of t)a!=null&&a.afterAllSetup&&a.afterAllSetup(n)}function lb(n,t,a){if(a[t.name]){ce&&ae.log(`Integration skipped because it was already installed: ${t.name}`);return}if(a[t.name]=t,!x0.includes(t.name)&&typeof t.setupOnce=="function"&&(t.setupOnce(),x0.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(n),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);n.on("preprocessEvent",(l,c)=>r(l,c,n))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),l=Object.assign((c,f)=>r(c,f,n),{id:t.name});n.addEventProcessor(l)}ce&&ae.log(`Integration installed: ${t.name}`)}function EE(n){return[{type:"log",item_count:n.length,content_type:"application/vnd.sentry.items.log+json"},{items:n}]}function AE(n,t,a,r){const l={};return t!=null&&t.sdk&&(l.sdk={name:t.sdk.name,version:t.sdk.version}),a&&r&&(l.dsn=Cr(r)),os(l,[EE(n)])}function fd(n,t){const a=t??NE(n)??[];if(a.length===0)return;const r=n.getOptions(),l=AE(a,r._metadata,r.tunnel,n.getDsn());cb().set(n,[]),n.emit("flushLogs"),n.sendEnvelope(l)}function NE(n){return cb().get(n)}function cb(){return as("clientToLogBufferMap",()=>new WeakMap)}function DE(n){return[{type:"trace_metric",item_count:n.length,content_type:"application/vnd.sentry.items.trace-metric+json"},{items:n}]}function CE(n,t,a,r){const l={};return t!=null&&t.sdk&&(l.sdk={name:t.sdk.name,version:t.sdk.version}),a&&r&&(l.dsn=Cr(r)),os(l,[DE(n)])}function ub(n,t){const a=t??jE(n)??[];if(a.length===0)return;const r=n.getOptions(),l=CE(a,r._metadata,r.tunnel,n.getDsn());fb().set(n,[]),n.emit("flushMetrics"),n.sendEnvelope(l)}function jE(n){return fb().get(n)}function fb(){return as("clientToMetricBufferMap",()=>new WeakMap)}function db(n){return typeof n=="object"&&typeof n.unref=="function"&&n.unref(),n}const ah=Symbol.for("SentryBufferFullError");function sh(n=100){const t=new Set;function a(){return t.sizer(h),()=>r(h)),h}function c(f){if(!t.size)return jr(!0);const h=Promise.allSettled(Array.from(t)).then(()=>!0);if(!f)return h;const m=[h,new Promise(p=>db(setTimeout(()=>p(!1),f)))];return Promise.race(m)}return{get $(){return Array.from(t)},add:l,drain:c}}const ME=60*1e3;function OE(n,t=Xl()){const a=parseInt(`${n}`,10);if(!isNaN(a))return a*1e3;const r=Date.parse(`${n}`);return isNaN(r)?ME:r-t}function RE(n,t){return n[t]||n.all||0}function kE(n,t,a=Xl()){return RE(n,t)>a}function LE(n,{statusCode:t,headers:a},r=Xl()){const l={...n},c=a==null?void 0:a["x-sentry-rate-limits"],f=a==null?void 0:a["retry-after"];if(c)for(const h of c.trim().split(",")){const[m,p,,,v]=h.split(":",5),x=parseInt(m,10),S=(isNaN(x)?60:x)*1e3;if(!p)l.all=r+S;else for(const w of p.split(";"))w==="metric_bucket"?(!v||v.split(";").includes("custom"))&&(l[w]=r+S):l[w]=r+S}else f?l.all=r+OE(f,r):t===429&&(l.all=r+60*1e3);return l}const hb=64;function zE(n,t,a=sh(n.bufferSize||hb)){let r={};const l=f=>a.drain(f);function c(f){const h=[];if(ld(f,(x,S)=>{const w=d0(S);kE(r,w)?n.recordDroppedEvent("ratelimit_backoff",w):h.push(x)}),h.length===0)return Promise.resolve({});const m=os(f[0],h),p=x=>{if(HT(m,["client_report"])){ce&&ae.warn(`Dropping client report. Will not send outcomes (reason: ${x}).`);return}ld(m,(S,w)=>{n.recordDroppedEvent(x,d0(w))})},v=()=>t({body:IT(m)}).then(x=>x.statusCode===413?(ce&&ae.error("Sentry responded with status code 413. Envelope was discarded due to exceeding size limits."),p("send_error"),x):(ce&&x.statusCode!==void 0&&(x.statusCode<200||x.statusCode>=300)&&ae.warn(`Sentry responded with status code ${x.statusCode} to sent event.`),r=LE(r,x),x),x=>{throw p("network_error"),ce&&ae.error("Encountered error running transport request:",x),x});return a.add(v).then(x=>x,x=>{if(x===ah)return ce&&ae.error("Skipped sending event because buffer is full."),p("queue_overflow"),Promise.resolve({});throw x})}return{send:c,flush:l}}function VE(n,t,a){const r=[{type:"client_report"},{timestamp:Nr(),discarded_events:n}];return os(t?{dsn:t}:{},[r])}function mb(n){const t=[];n.message&&t.push(n.message);try{const a=n.exception.values[n.exception.values.length-1];a!=null&&a.value&&(t.push(a.value),a.type&&t.push(`${a.type}: ${a.value}`))}catch{}return t}function BE(n){var m;const{trace_id:t,parent_span_id:a,span_id:r,status:l,origin:c,data:f,op:h}=((m=n.contexts)==null?void 0:m.trace)??{};return{data:f??{},description:n.transaction,op:h,parent_span_id:a,span_id:r??"",start_timestamp:n.start_timestamp??0,status:l,timestamp:n.timestamp,trace_id:t??"",origin:c,profile_id:f==null?void 0:f[Xx],exclusive_time:f==null?void 0:f[$x],measurements:n.measurements,is_segment:!0}}function UE(n){return{type:"transaction",timestamp:n.timestamp,start_timestamp:n.start_timestamp,transaction:n.description,contexts:{trace:{trace_id:n.trace_id,span_id:n.span_id,parent_span_id:n.parent_span_id,op:n.op,status:n.status,origin:n.origin,data:{...n.data,...n.profile_id&&{[Xx]:n.profile_id},...n.exclusive_time&&{[$x]:n.exclusive_time}}}},measurements:n.measurements}}const S0="Not capturing exception because it's already been captured.",w0="Discarded session because of missing or non-string release",pb=Symbol.for("SentryInternalError"),gb=Symbol.for("SentryDoNotSendEventError"),PE=5e3;function ul(n){return{message:n,[pb]:!0}}function jf(n){return{message:n,[gb]:!0}}function _0(n){return!!n&&typeof n=="object"&&pb in n}function T0(n){return!!n&&typeof n=="object"&&gb in n}function E0(n,t,a,r,l){let c=0,f,h=!1;n.on(a,()=>{c=0,clearTimeout(f),h=!1}),n.on(t,m=>{c+=r(m),c>=8e5?l(n):h||(h=!0,f=db(setTimeout(()=>{l(n)},PE)))}),n.on("flush",()=>{l(n)})}class HE{constructor(t){var r,l,c;if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],this._promiseBuffer=sh(((r=t.transportOptions)==null?void 0:r.bufferSize)??hb),t.dsn?this._dsn=yT(t.dsn):ce&&ae.warn("No DSN provided, client will not send events."),this._dsn){const f=SE(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:f})}this._options.enableLogs=this._options.enableLogs??((l=this._options._experiments)==null?void 0:l.enableLogs),this._options.enableLogs&&E0(this,"afterCaptureLog","flushLogs",GE,fd),(this._options.enableMetrics??((c=this._options._experiments)==null?void 0:c.enableMetrics)??!0)&&E0(this,"afterCaptureMetric","flushMetrics",FE,ub)}captureException(t,a,r){const l=Wt();if(Qy(t))return ce&&ae.log(S0),l;const c={event_id:l,...a};return this._process(()=>this.eventFromException(t,c).then(f=>this._captureEvent(f,c,r)).then(f=>f),"error"),c.event_id}captureMessage(t,a,r,l){const c={event_id:Wt(),...r},f=Qd(t)?t:String(t),h=Gl(t),m=h?this.eventFromMessage(f,a,c):this.eventFromException(t,c);return this._process(()=>m.then(p=>this._captureEvent(p,c,l)),h?"unknown":"error"),c.event_id}captureEvent(t,a,r){const l=Wt();if(a!=null&&a.originalException&&Qy(a.originalException))return ce&&ae.log(S0),l;const c={event_id:l,...a},f=t.sdkProcessingMetadata||{},h=f.capturedSpanScope,m=f.capturedSpanIsolationScope,p=A0(t.type);return this._process(()=>this._captureEvent(t,c,h||r,m),p),c.event_id}captureSession(t){this.sendSession(t),Ja(t,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}async flush(t){const a=this._transport;if(!a)return!0;this.emit("flush");const r=await this._isClientDoneProcessing(t),l=await a.flush(t);return r&&l}async close(t){fd(this);const a=await this.flush(t);return this.getOptions().enabled=!1,this.emit("close"),a}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const a=this._integrations[t.name];!a&&t.beforeSetup&&t.beforeSetup(this),lb(this,t,this._integrations),a||b0(this,[t])}sendEvent(t,a={}){this.emit("beforeSendEvent",t,a);let r=$T(t,this._dsn,this._options._metadata,this._options.tunnel);for(const l of a.attachments||[])r=PT(r,FT(l));this.sendEnvelope(r).then(l=>this.emit("afterSendEvent",t,l))}sendSession(t){const{release:a,environment:r=nh}=this._options;if("aggregates"in t){const c=t.attrs||{};if(!c.release&&!a){ce&&ae.warn(w0);return}c.release=c.release||a,c.environment=c.environment||r,t.attrs=c}else{if(!t.release&&!a){ce&&ae.warn(w0);return}t.release=t.release||a,t.environment=t.environment||r}this.emit("beforeSendSession",t);const l=XT(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(l)}recordDroppedEvent(t,a,r=1){if(this._options.sendClientReports){const l=`${t}:${a}`;ce&&ae.log(`Recording outcome: "${l}"${r>1?` (${r} times)`:""}`),this._outcomes[l]=(this._outcomes[l]||0)+r}}on(t,a){const r=this._hooks[t]=this._hooks[t]||new Set,l=(...c)=>a(...c);return r.add(l),()=>{r.delete(l)}}emit(t,...a){const r=this._hooks[t];r&&r.forEach(l=>l(...a))}async sendEnvelope(t){if(this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport)try{return await this._transport.send(t)}catch(a){return ce&&ae.error("Error while sending envelope:",a),{}}return ce&&ae.error("Transport disabled"),{}}dispose(){}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=TE(this,t),b0(this,t)}_updateSessionFromEvent(t,a){var m,p;let r=a.level==="fatal",l=!1;const c=(m=a.exception)==null?void 0:m.values;if(c){l=!0,r=!1;for(const v of c)if(((p=v.mechanism)==null?void 0:p.handled)===!1){r=!0;break}}const f=t.status==="ok";(f&&t.errors===0||f&&r)&&(Ja(t,{...r&&{status:"crashed"},errors:t.errors||Number(l||r)}),this.captureSession(t))}async _isClientDoneProcessing(t){let a=0;for(;!t||asetTimeout(r,1)),!this._numProcessing)return!0;a++}return!1}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,a,r,l){const c=this.getOptions(),f=Object.keys(this._integrations);return!a.integrations&&(f!=null&&f.length)&&(a.integrations=f),this.emit("preprocessEvent",t,a),t.type||l.setLastEventId(t.event_id||a.event_id),aE(c,t,a,r,this,l).then(h=>{var p;if(h===null)return h;this.emit("postprocessEvent",h,a),h.contexts={trace:{...(p=h.contexts)==null?void 0:p.trace,...Z_(r)},...h.contexts};const m=OT(this,r);return h.sdkProcessingMetadata={dynamicSamplingContext:m,...h.sdkProcessingMetadata},h})}_captureEvent(t,a={},r=vn(),l=wi()){return ce&&dd(t)&&ae.log(`Captured error event \`${mb(t)[0]||""}\``),this._processEvent(t,a,r,l).then(c=>c.event_id,c=>{ce&&(T0(c)?ae.log(c.message):_0(c)?ae.warn(c.message):ae.warn(c))})}_processEvent(t,a,r,l){const c=this.getOptions(),{sampleRate:f}=c,h=yb(t),m=dd(t),v=`before send for type \`${t.type||"error"}\``,x=typeof f>"u"?void 0:vT(f);if(m&&typeof x=="number"&&_l()>x)return this.recordDroppedEvent("sample_rate","error"),ih(jf(`Discarding event because it's not included in the random sample (sampling rate = ${f})`));const S=A0(t.type);return this._prepareEvent(t,a,r,l).then(w=>{var z;if(w===null)throw this.recordDroppedEvent("event_processor",S),jf("An event processor returned `null`, will not send event.");if(((z=a.data)==null?void 0:z.__sentry__)===!0)return w;const k=qE(this,c,w,a);return IE(k,v)}).then(w=>{var z;if(w===null){if(this.recordDroppedEvent("before_send",S),h){const I=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",I)}throw jf(`${v} returned \`null\`, will not send event.`)}const T=r.getSession()||l.getSession();if(m&&T&&this._updateSessionFromEvent(T,w),h){const B=((z=w.sdkProcessingMetadata)==null?void 0:z.spanCountBeforeProcessing)||0,I=w.spans?w.spans.length:0,H=B-I;H>0&&this.recordDroppedEvent("before_send","span",H)}const k=w.transaction_info;if(h&&k&&w.transaction!==t.transaction){const B="custom";w.transaction_info={...k,source:B}}return this.sendEvent(w,a),w}).then(null,w=>{throw T0(w)||_0(w)?w:(this.captureException(w,{mechanism:{handled:!1,type:"internal"},data:{__sentry__:!0},originalException:w}),ul(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. -Reason: ${w}`))})}_process(t,a){this._numProcessing++,this._promiseBuffer.add(t).then(r=>(this._numProcessing--,r),r=>(this._numProcessing--,r===ah&&this.recordDroppedEvent("queue_overflow",a),r))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([a,r])=>{const[l,c]=a.split(":");return{reason:l,category:c,quantity:r}})}_flushOutcomes(){ce&&ae.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){ce&&ae.log("No outcomes to send");return}if(!this._dsn){ce&&ae.log("No dsn provided, will not send outcomes");return}ce&&ae.log("Sending outcomes:",t);const a=VE(t,this._options.tunnel&&Cr(this._dsn));this.sendEnvelope(a)}}function A0(n){return n==="replay_event"?"replay":n||"error"}function IE(n,t){const a=`${t} must return \`null\` or a valid event.`;if(Ar(n))return n.then(r=>{if(!vr(r)&&r!==null)throw ul(a);return r},r=>{throw ul(`${t} rejected with ${r}`)});if(!vr(n)&&n!==null)throw ul(a);return n}function qE(n,t,a,r){const{beforeSend:l,beforeSendTransaction:c,ignoreSpans:f}=t,h=!kT(t.beforeSendSpan)&&t.beforeSendSpan;let m=a;if(dd(m)&&l)return l(m,r);if(yb(m)){if(h||f){const p=BE(m);if(f!=null&&f.length&&f0(p,f))return null;if(h){const v=h(p);v?m=Dr(a,UE(v)):c0()}if(m.spans){const v=[],x=m.spans;for(const w of x){if(f!=null&&f.length&&f0(w,f)){CT(x,w);continue}if(h){const T=h(w);T?v.push(T):(c0(),v.push(w))}else v.push(w)}const S=m.spans.length-v.length;S&&n.recordDroppedEvent("before_send","span",S),m.spans=v}}if(c){if(m.spans){const p=m.spans.length;m.sdkProcessingMetadata={...a.sdkProcessingMetadata,spanCountBeforeProcessing:p}}return c(m,r)}}return m}function dd(n){return n.type===void 0}function yb(n){return n.type==="transaction"}function FE(n){let t=0;return n.name&&(t+=n.name.length*2),t+=8,t+vb(n.attributes)}function GE(n){let t=0;return n.message&&(t+=n.message.length*2),t+vb(n.attributes)}function vb(n){if(!n)return 0;let t=0;return Object.values(n).forEach(a=>{Array.isArray(a)?t+=a.length*N0(a[0]):Gl(a)?t+=N0(a):t+=100}),t}function N0(n){return typeof n=="string"?n.length*2:typeof n=="number"?8:typeof n=="boolean"?4:0}function YE(n){return Fl(n)&&"__sentry_fetch_url_host__"in n&&typeof n.__sentry_fetch_url_host__=="string"}function D0(n){return YE(n)?`${n.message} (${n.__sentry_fetch_url_host__})`:n.message}function KE(n,t){t.debug===!0&&(ce?ae.enable():ss(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),vn().update(t.initialScope);const r=new n(t);return XE(r),r.init(),r}function XE(n){vn().setClient(n)}function Mf(n){if(!n)return{};const t=n.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const a=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:a,hash:r,relative:t[5]+a+r}}function $E(n,t=!0){if(n.startsWith("data:")){const a=n.match(/^data:([^;,]+)/),r=a?a[1]:"text/plain",l=n.includes(";base64,"),c=n.indexOf(",");let f="";if(t&&c!==-1){const h=n.slice(c+1);f=h.length>10?`${h.slice(0,10)}... [truncated]`:h}return`data:${r}${l?",base64":""}${f?`,${f}`:""}`}return n}function ZE(n){var t;"aggregates"in n?((t=n.attrs)==null?void 0:t.ip_address)===void 0&&(n.attrs={...n.attrs,ip_address:"{{auto}}"}):n.ipAddress===void 0&&(n.ipAddress="{{auto}}")}function xb(n,t,a=[t],r="npm"){const l=(n._metadata=n._metadata||{}).sdk=n._metadata.sdk||{};l.name||(l.name=`sentry.javascript.${t}`,l.packages=a.map(c=>({name:`${r}:@sentry/${c}`,version:$i})),l.version=$i)}const QE=100;function ea(n,t){const a=gt(),r=wi();if(!a)return;const{beforeBreadcrumb:l=null,maxBreadcrumbs:c=QE}=a.getOptions();if(c<=0)return;const h={timestamp:Nr(),...n},m=l?ss(()=>l(h,t)):h;m!==null&&(a.emit&&a.emit("beforeAddBreadcrumb",m,t),r.addBreadcrumb(m,c))}let C0;const WE="FunctionToString",j0=new WeakMap,JE=(()=>({name:WE,setupOnce(){C0=Function.prototype.toString;try{Function.prototype.toString=function(...n){const t=eh(this),a=j0.has(gt())&&t!==void 0?t:this;return C0.apply(a,n)}}catch{}},setup(n){j0.set(n,!0)}})),eA=JE,tA=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,/can't redefine non-configurable property "solana"/,/vv\(\)\.getRestrictions is not a function/,/Can't find variable: _AutofillCallbackHandler/,/Object Not Found Matching Id:\d+, MethodName:simulateEvent/,/^Java exception was raised during method invocation$/],nA="EventFilters",iA=(n={})=>{let t;return{name:nA,setup(a){const r=a.getOptions();t=M0(n,r)},processEvent(a,r,l){if(!t){const c=l.getOptions();t=M0(n,c)}return sA(a,t)?null:a}}},aA=((n={})=>({...iA(n),name:"InboundFilters"}));function M0(n={},t={}){return{allowUrls:[...n.allowUrls||[],...t.allowUrls||[]],denyUrls:[...n.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...n.ignoreErrors||[],...t.ignoreErrors||[],...n.disableErrorDefaults?[]:tA],ignoreTransactions:[...n.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function sA(n,t){if(n.type){if(n.type==="transaction"&&oA(n,t.ignoreTransactions))return ce&&ae.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. +`),typeof h=="string"||h instanceof Uint8Array)l(h);else{let m;try{m=JSON.stringify(h)}catch{m=JSON.stringify(Bn(h))}l(m)}}return typeof r=="string"?r:FT(r)}function FT(n){const t=n.reduce((l,c)=>l+c.length,0),a=new Uint8Array(t);let r=0;for(const l of n)a.set(l,r),r+=l.length;return a}function GT(n){const t=typeof n.data=="string"?cd(n.data):n.data;return[{type:"attachment",length:t.length,filename:n.filename,content_type:n.contentType,attachment_type:n.attachmentType},t]}const nb={sessions:"session",event:"error",client_report:"internal",user_report:"default",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",raw_security:"security",log:"log_item",trace_metric:"metric"};function YT(n){return n in nb}function d0(n){return YT(n)?nb[n]:n}function ib(n){if(!(n!=null&&n.sdk))return;const{name:t,version:a}=n.sdk;return{name:t,version:a}}function KT(n,t,a,r){var c;const l=(c=n.sdkProcessingMetadata)==null?void 0:c.dynamicSamplingContext;return{event_id:n.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!a&&r&&{dsn:Cr(r)},...l&&{trace:l}}}function XT(n,t){var r,l,c,f;if(!t)return n;const a=n.sdk||{};return n.sdk={...a,name:a.name||t.name,version:a.version||t.version,integrations:[...((r=n.sdk)==null?void 0:r.integrations)||[],...t.integrations||[]],packages:[...((l=n.sdk)==null?void 0:l.packages)||[],...t.packages||[]],settings:(c=n.sdk)!=null&&c.settings||t.settings?{...(f=n.sdk)==null?void 0:f.settings,...t.settings}:void 0},n}function $T(n,t,a,r){const l=ib(a),c={sent_at:new Date().toISOString(),...l&&{sdk:l},...!!r&&t&&{dsn:Cr(t)}},f="aggregates"in n?[{type:"sessions"},n]:[{type:"session"},n.toJSON()];return os(c,[f])}function ZT(n,t,a,r){const l=ib(a),c=n.type&&n.type!=="replay_event"?n.type:"event";XT(n,a==null?void 0:a.sdk);const f=KT(n,l,r,t);return delete n.sdkProcessingMetadata,os(f,[[{type:c},n]])}function QT(n,t){const{fingerprint:a,span:r,breadcrumbs:l,sdkProcessingMetadata:c}=t;WT(n,t),r&&tE(n,r),nE(n,a),JT(n,l),eE(n,c)}function h0(n,t){const{extra:a,tags:r,attributes:l,user:c,contexts:f,level:h,sdkProcessingMetadata:m,breadcrumbs:p,fingerprint:v,eventProcessors:x,attachments:S,propagationContext:w,transactionName:T,span:k}=t;sr(n,"extra",a),sr(n,"tags",r),sr(n,"attributes",l),sr(n,"user",c),sr(n,"contexts",f),n.sdkProcessingMetadata=Dr(n.sdkProcessingMetadata,m,2),h&&(n.level=h),T&&(n.transactionName=T),k&&(n.span=k),p.length&&(n.breadcrumbs=[...n.breadcrumbs,...p]),v.length&&(n.fingerprint=[...n.fingerprint,...v]),x.length&&(n.eventProcessors=[...n.eventProcessors,...x]),S.length&&(n.attachments=[...n.attachments,...S]),n.propagationContext={...n.propagationContext,...w}}function sr(n,t,a){n[t]=Dr(n[t],a,1)}function ab(n,t){const a=$_().getScopeData();return n&&h0(a,n.getScopeData()),t&&h0(a,t.getScopeData()),a}function WT(n,t){const{extra:a,tags:r,user:l,contexts:c,level:f,transactionName:h}=t;Object.keys(a).length&&(n.extra={...a,...n.extra}),Object.keys(r).length&&(n.tags={...r,...n.tags}),Object.keys(l).length&&(n.user={...l,...n.user}),Object.keys(c).length&&(n.contexts={...c,...n.contexts}),f&&(n.level=f),h&&n.type!=="transaction"&&(n.transaction=h)}function JT(n,t){const a=[...n.breadcrumbs||[],...t];n.breadcrumbs=a.length?a:void 0}function eE(n,t){n.sdkProcessingMetadata={...n.sdkProcessingMetadata,...t}}function tE(n,t){n.contexts={trace:bT(t),...n.contexts},n.sdkProcessingMetadata={dynamicSamplingContext:kT(t),...n.sdkProcessingMetadata};const a=Jx(t),r=Zl(a).description;r&&!n.transaction&&n.type==="transaction"&&(n.transaction=r)}function nE(n,t){n.fingerprint=n.fingerprint?Array.isArray(n.fingerprint)?n.fingerprint:[n.fingerprint]:[],t&&(n.fingerprint=n.fingerprint.concat(t)),n.fingerprint.length||delete n.fingerprint}const Df=0,m0=1,p0=2;function jr(n){return new xr(t=>{t(n)})}function ih(n){return new xr((t,a)=>{a(n)})}class xr{constructor(t){this._state=Df,this._handlers=[],this._runExecutor(t)}then(t,a){return new xr((r,l)=>{this._handlers.push([!1,c=>{if(!t)r(c);else try{r(t(c))}catch(f){l(f)}},c=>{if(!a)l(c);else try{r(a(c))}catch(f){l(f)}}]),this._executeHandlers()})}catch(t){return this.then(a=>a,t)}finally(t){return new xr((a,r)=>{let l,c;return this.then(f=>{c=!1,l=f,t&&t()},f=>{c=!0,l=f,t&&t()}).then(()=>{if(c){r(l);return}a(l)})})}_executeHandlers(){if(this._state===Df)return;const t=this._handlers.slice();this._handlers=[],t.forEach(a=>{a[0]||(this._state===m0&&a[1](this._value),this._state===p0&&a[2](this._value),a[0]=!0)})}_runExecutor(t){const a=(c,f)=>{if(this._state===Df){if(Ar(f)){f.then(r,l);return}this._state=c,this._value=f,this._executeHandlers()}},r=c=>{a(m0,c)},l=c=>{a(p0,c)};try{t(r,l)}catch(c){l(c)}}}function iE(n,t,a,r=0){try{const l=ud(t,a,n,r);return Ar(l)?l:jr(l)}catch(l){return ih(l)}}function ud(n,t,a,r){const l=a[r];if(!n||!l)return n;const c=l({...n},t);return ce&&c===null&&ae.log(`Event processor "${l.id||"?"}" dropped event`),Ar(c)?c.then(f=>ud(f,t,a,r+1)):ud(c,t,a,r+1)}let Vn,g0,y0,hi;function aE(n){const t=Oe._sentryDebugIds,a=Oe._debugIds;if(!t&&!a)return{};const r=t?Object.keys(t):[],l=a?Object.keys(a):[];if(hi&&r.length===g0&&l.length===y0)return hi;g0=r.length,y0=l.length,hi={},Vn||(Vn={});const c=(f,h)=>{for(const m of f){const p=h[m],v=Vn==null?void 0:Vn[m];if(v&&hi&&p)hi[v[0]]=p,Vn&&(Vn[m]=[v[0],p]);else if(p){const x=n(m);for(let S=x.length-1;S>=0;S--){const w=x[S],T=w==null?void 0:w.filename;if(T&&hi&&Vn){hi[T]=p,Vn[m]=[T,p];break}}}}};return t&&c(r,t),a&&c(l,a),hi}function sE(n,t,a,r,l,c){const{normalizeDepth:f=3,normalizeMaxBreadth:h=1e3}=n,m={...t,event_id:t.event_id||a.event_id||Wt(),timestamp:t.timestamp||Nr()},p=a.integrations||n.integrations.map(B=>B.name);rE(m,n),cE(m,p),l&&l.emit("applyFrameMetadata",t),t.type===void 0&&oE(m,n.stackParser);const v=fE(r,a.captureContext);a.mechanism&&Wa(m,a.mechanism);const x=l?l.getEventProcessors():[],S=ab(c,v),w=[...a.attachments||[],...S.attachments];w.length&&(a.attachments=w),QT(m,S);const T=[...x,...S.eventProcessors];return(a.data&&a.data.__sentry__===!0?jr(m):iE(T,m,a)).then(B=>(B&&lE(B),typeof f=="number"&&f>0?uE(B,f,h):B))}function rE(n,t){var h,m;const{environment:a,release:r,dist:l,maxValueLength:c}=t;n.environment=n.environment||a||nh,!n.release&&r&&(n.release=r),!n.dist&&l&&(n.dist=l);const f=n.request;f!=null&&f.url&&c&&(f.url=ad(f.url,c)),c&&((m=(h=n.exception)==null?void 0:h.values)==null||m.forEach(p=>{p.value&&(p.value=ad(p.value,c))}))}function oE(n,t){var r,l;const a=aE(t);(l=(r=n.exception)==null?void 0:r.values)==null||l.forEach(c=>{var f,h;(h=(f=c.stacktrace)==null?void 0:f.frames)==null||h.forEach(m=>{m.filename&&(m.debug_id=a[m.filename])})})}function lE(n){var r,l;const t={};if((l=(r=n.exception)==null?void 0:r.values)==null||l.forEach(c=>{var f,h;(h=(f=c.stacktrace)==null?void 0:f.frames)==null||h.forEach(m=>{m.debug_id&&(m.abs_path?t[m.abs_path]=m.debug_id:m.filename&&(t[m.filename]=m.debug_id),delete m.debug_id)})}),Object.keys(t).length===0)return;n.debug_meta=n.debug_meta||{},n.debug_meta.images=n.debug_meta.images||[];const a=n.debug_meta.images;Object.entries(t).forEach(([c,f])=>{a.push({type:"sourcemap",code_file:c,debug_id:f})})}function cE(n,t){t.length>0&&(n.sdk=n.sdk||{},n.sdk.integrations=[...n.sdk.integrations||[],...t])}function uE(n,t,a){var l,c;if(!n)return null;const r={...n,...n.breadcrumbs&&{breadcrumbs:n.breadcrumbs.map(f=>({...f,...f.data&&{data:Bn(f.data,t,a)}}))},...n.user&&{user:Bn(n.user,t,a)},...n.contexts&&{contexts:Bn(n.contexts,t,a)},...n.extra&&{extra:Bn(n.extra,t,a)}};return(l=n.contexts)!=null&&l.trace&&r.contexts&&(r.contexts.trace=n.contexts.trace,n.contexts.trace.data&&(r.contexts.trace.data=Bn(n.contexts.trace.data,t,a))),n.spans&&(r.spans=n.spans.map(f=>({...f,...f.data&&{data:Bn(f.data,t,a)}}))),(c=n.contexts)!=null&&c.flags&&r.contexts&&(r.contexts.flags=Bn(n.contexts.flags,3,a)),r}function fE(n,t){if(!t)return n;const a=n?n.clone():new gn;return a.update(t),a}function dE(n){if(n)return hE(n)?{captureContext:n}:pE(n)?{captureContext:n}:n}function hE(n){return n instanceof gn||typeof n=="function"}const mE=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function pE(n){return Object.keys(n).some(t=>mE.includes(t))}function Ji(n,t){return vn().captureException(n,dE(t))}function sb(n,t){const a=typeof t=="string"?t:void 0,r=typeof t!="string"?{captureContext:t}:void 0;return vn().captureMessage(n,a,r)}function rb(n,t){return vn().captureEvent(n,t)}function gE(n,t){wi().setContext(n,t)}function v0(n){const t=wi(),{user:a}=ab(t,vn()),{userAgent:r}=Oe.navigator||{},l=V_({user:a,...r&&{userAgent:r},...n}),c=t.getSession();return(c==null?void 0:c.status)==="ok"&&Ja(c,{status:"exited"}),ob(),t.setSession(l),l}function ob(){const n=wi(),a=vn().getSession()||n.getSession();a&&B_(a),lb(),n.setSession()}function lb(){const n=wi(),t=gt(),a=n.getSession();a&&t&&t.captureSession(a)}function Cf(n=!1){if(n){ob();return}lb()}const yE="7";function vE(n){const t=n.protocol?`${n.protocol}:`:"",a=n.port?`:${n.port}`:"";return`${t}//${n.host}${a}${n.path?`/${n.path}`:""}/api/`}function xE(n){return`${vE(n)}${n.projectId}/envelope/`}function bE(n,t){const a={sentry_version:yE};return n.publicKey&&(a.sentry_key=n.publicKey),t&&(a.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(a).toString()}function SE(n,t,a){return t||`${xE(n)}?${bE(n,a)}`}const x0=[];function wE(n){const t={};return n.forEach(a=>{const{name:r}=a,l=t[r];l&&!l.isDefaultInstance&&a.isDefaultInstance||(t[r]=a)}),Object.values(t)}function _E(n){const t=n.defaultIntegrations||[],a=n.integrations;t.forEach(l=>{l.isDefaultInstance=!0});let r;if(Array.isArray(a))r=[...t,...a];else if(typeof a=="function"){const l=a(t);r=Array.isArray(l)?l:[l]}else r=t;return wE(r)}function TE(n,t){const a={};return t.forEach(r=>{r!=null&&r.beforeSetup&&r.beforeSetup(n)}),t.forEach(r=>{r&&cb(n,r,a)}),a}function b0(n,t){for(const a of t)a!=null&&a.afterAllSetup&&a.afterAllSetup(n)}function cb(n,t,a){if(a[t.name]){ce&&ae.log(`Integration skipped because it was already installed: ${t.name}`);return}if(a[t.name]=t,!x0.includes(t.name)&&typeof t.setupOnce=="function"&&(t.setupOnce(),x0.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(n),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);n.on("preprocessEvent",(l,c)=>r(l,c,n))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),l=Object.assign((c,f)=>r(c,f,n),{id:t.name});n.addEventProcessor(l)}ce&&ae.log(`Integration installed: ${t.name}`)}function EE(n){return[{type:"log",item_count:n.length,content_type:"application/vnd.sentry.items.log+json"},{items:n}]}function AE(n,t,a,r){const l={};return t!=null&&t.sdk&&(l.sdk={name:t.sdk.name,version:t.sdk.version}),a&&r&&(l.dsn=Cr(r)),os(l,[EE(n)])}function fd(n,t){const a=t??NE(n)??[];if(a.length===0)return;const r=n.getOptions(),l=AE(a,r._metadata,r.tunnel,n.getDsn());ub().set(n,[]),n.emit("flushLogs"),n.sendEnvelope(l)}function NE(n){return ub().get(n)}function ub(){return as("clientToLogBufferMap",()=>new WeakMap)}function DE(n){return[{type:"trace_metric",item_count:n.length,content_type:"application/vnd.sentry.items.trace-metric+json"},{items:n}]}function CE(n,t,a,r){const l={};return t!=null&&t.sdk&&(l.sdk={name:t.sdk.name,version:t.sdk.version}),a&&r&&(l.dsn=Cr(r)),os(l,[DE(n)])}function fb(n,t){const a=t??jE(n)??[];if(a.length===0)return;const r=n.getOptions(),l=CE(a,r._metadata,r.tunnel,n.getDsn());db().set(n,[]),n.emit("flushMetrics"),n.sendEnvelope(l)}function jE(n){return db().get(n)}function db(){return as("clientToMetricBufferMap",()=>new WeakMap)}function hb(n){return typeof n=="object"&&typeof n.unref=="function"&&n.unref(),n}const ah=Symbol.for("SentryBufferFullError");function sh(n=100){const t=new Set;function a(){return t.sizer(h),()=>r(h)),h}function c(f){if(!t.size)return jr(!0);const h=Promise.allSettled(Array.from(t)).then(()=>!0);if(!f)return h;const m=[h,new Promise(p=>hb(setTimeout(()=>p(!1),f)))];return Promise.race(m)}return{get $(){return Array.from(t)},add:l,drain:c}}const ME=60*1e3;function OE(n,t=Xl()){const a=parseInt(`${n}`,10);if(!isNaN(a))return a*1e3;const r=Date.parse(`${n}`);return isNaN(r)?ME:r-t}function RE(n,t){return n[t]||n.all||0}function kE(n,t,a=Xl()){return RE(n,t)>a}function LE(n,{statusCode:t,headers:a},r=Xl()){const l={...n},c=a==null?void 0:a["x-sentry-rate-limits"],f=a==null?void 0:a["retry-after"];if(c)for(const h of c.trim().split(",")){const[m,p,,,v]=h.split(":",5),x=parseInt(m,10),S=(isNaN(x)?60:x)*1e3;if(!p)l.all=r+S;else for(const w of p.split(";"))w==="metric_bucket"?(!v||v.split(";").includes("custom"))&&(l[w]=r+S):l[w]=r+S}else f?l.all=r+OE(f,r):t===429&&(l.all=r+60*1e3);return l}const mb=64;function zE(n,t,a=sh(n.bufferSize||mb)){let r={};const l=f=>a.drain(f);function c(f){const h=[];if(ld(f,(x,S)=>{const w=d0(S);kE(r,w)?n.recordDroppedEvent("ratelimit_backoff",w):h.push(x)}),h.length===0)return Promise.resolve({});const m=os(f[0],h),p=x=>{if(IT(m,["client_report"])){ce&&ae.warn(`Dropping client report. Will not send outcomes (reason: ${x}).`);return}ld(m,(S,w)=>{n.recordDroppedEvent(x,d0(w))})},v=()=>t({body:qT(m)}).then(x=>x.statusCode===413?(ce&&ae.error("Sentry responded with status code 413. Envelope was discarded due to exceeding size limits."),p("send_error"),x):(ce&&x.statusCode!==void 0&&(x.statusCode<200||x.statusCode>=300)&&ae.warn(`Sentry responded with status code ${x.statusCode} to sent event.`),r=LE(r,x),x),x=>{throw p("network_error"),ce&&ae.error("Encountered error running transport request:",x),x});return a.add(v).then(x=>x,x=>{if(x===ah)return ce&&ae.error("Skipped sending event because buffer is full."),p("queue_overflow"),Promise.resolve({});throw x})}return{send:c,flush:l}}function VE(n,t,a){const r=[{type:"client_report"},{timestamp:Nr(),discarded_events:n}];return os(t?{dsn:t}:{},[r])}function pb(n){const t=[];n.message&&t.push(n.message);try{const a=n.exception.values[n.exception.values.length-1];a!=null&&a.value&&(t.push(a.value),a.type&&t.push(`${a.type}: ${a.value}`))}catch{}return t}function BE(n){var m;const{trace_id:t,parent_span_id:a,span_id:r,status:l,origin:c,data:f,op:h}=((m=n.contexts)==null?void 0:m.trace)??{};return{data:f??{},description:n.transaction,op:h,parent_span_id:a,span_id:r??"",start_timestamp:n.start_timestamp??0,status:l,timestamp:n.timestamp,trace_id:t??"",origin:c,profile_id:f==null?void 0:f[Xx],exclusive_time:f==null?void 0:f[$x],measurements:n.measurements,is_segment:!0}}function UE(n){return{type:"transaction",timestamp:n.timestamp,start_timestamp:n.start_timestamp,transaction:n.description,contexts:{trace:{trace_id:n.trace_id,span_id:n.span_id,parent_span_id:n.parent_span_id,op:n.op,status:n.status,origin:n.origin,data:{...n.data,...n.profile_id&&{[Xx]:n.profile_id},...n.exclusive_time&&{[$x]:n.exclusive_time}}}},measurements:n.measurements}}const S0="Not capturing exception because it's already been captured.",w0="Discarded session because of missing or non-string release",gb=Symbol.for("SentryInternalError"),yb=Symbol.for("SentryDoNotSendEventError"),PE=5e3;function ul(n){return{message:n,[gb]:!0}}function jf(n){return{message:n,[yb]:!0}}function _0(n){return!!n&&typeof n=="object"&&gb in n}function T0(n){return!!n&&typeof n=="object"&&yb in n}function E0(n,t,a,r,l){let c=0,f,h=!1;n.on(a,()=>{c=0,clearTimeout(f),h=!1}),n.on(t,m=>{c+=r(m),c>=8e5?l(n):h||(h=!0,f=hb(setTimeout(()=>{l(n)},PE)))}),n.on("flush",()=>{l(n)})}class HE{constructor(t){var r,l,c;if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],this._promiseBuffer=sh(((r=t.transportOptions)==null?void 0:r.bufferSize)??mb),t.dsn?this._dsn=vT(t.dsn):ce&&ae.warn("No DSN provided, client will not send events."),this._dsn){const f=SE(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:f})}this._options.enableLogs=this._options.enableLogs??((l=this._options._experiments)==null?void 0:l.enableLogs),this._options.enableLogs&&E0(this,"afterCaptureLog","flushLogs",GE,fd),(this._options.enableMetrics??((c=this._options._experiments)==null?void 0:c.enableMetrics)??!0)&&E0(this,"afterCaptureMetric","flushMetrics",FE,fb)}captureException(t,a,r){const l=Wt();if(Qy(t))return ce&&ae.log(S0),l;const c={event_id:l,...a};return this._process(()=>this.eventFromException(t,c).then(f=>this._captureEvent(f,c,r)).then(f=>f),"error"),c.event_id}captureMessage(t,a,r,l){const c={event_id:Wt(),...r},f=Qd(t)?t:String(t),h=Gl(t),m=h?this.eventFromMessage(f,a,c):this.eventFromException(t,c);return this._process(()=>m.then(p=>this._captureEvent(p,c,l)),h?"unknown":"error"),c.event_id}captureEvent(t,a,r){const l=Wt();if(a!=null&&a.originalException&&Qy(a.originalException))return ce&&ae.log(S0),l;const c={event_id:l,...a},f=t.sdkProcessingMetadata||{},h=f.capturedSpanScope,m=f.capturedSpanIsolationScope,p=A0(t.type);return this._process(()=>this._captureEvent(t,c,h||r,m),p),c.event_id}captureSession(t){this.sendSession(t),Ja(t,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}async flush(t){const a=this._transport;if(!a)return!0;this.emit("flush");const r=await this._isClientDoneProcessing(t),l=await a.flush(t);return r&&l}async close(t){fd(this);const a=await this.flush(t);return this.getOptions().enabled=!1,this.emit("close"),a}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const a=this._integrations[t.name];!a&&t.beforeSetup&&t.beforeSetup(this),cb(this,t,this._integrations),a||b0(this,[t])}sendEvent(t,a={}){this.emit("beforeSendEvent",t,a);let r=ZT(t,this._dsn,this._options._metadata,this._options.tunnel);for(const l of a.attachments||[])r=HT(r,GT(l));this.sendEnvelope(r).then(l=>this.emit("afterSendEvent",t,l))}sendSession(t){const{release:a,environment:r=nh}=this._options;if("aggregates"in t){const c=t.attrs||{};if(!c.release&&!a){ce&&ae.warn(w0);return}c.release=c.release||a,c.environment=c.environment||r,t.attrs=c}else{if(!t.release&&!a){ce&&ae.warn(w0);return}t.release=t.release||a,t.environment=t.environment||r}this.emit("beforeSendSession",t);const l=$T(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(l)}recordDroppedEvent(t,a,r=1){if(this._options.sendClientReports){const l=`${t}:${a}`;ce&&ae.log(`Recording outcome: "${l}"${r>1?` (${r} times)`:""}`),this._outcomes[l]=(this._outcomes[l]||0)+r}}on(t,a){const r=this._hooks[t]=this._hooks[t]||new Set,l=(...c)=>a(...c);return r.add(l),()=>{r.delete(l)}}emit(t,...a){const r=this._hooks[t];r&&r.forEach(l=>l(...a))}async sendEnvelope(t){if(this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport)try{return await this._transport.send(t)}catch(a){return ce&&ae.error("Error while sending envelope:",a),{}}return ce&&ae.error("Transport disabled"),{}}dispose(){}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=TE(this,t),b0(this,t)}_updateSessionFromEvent(t,a){var m,p;let r=a.level==="fatal",l=!1;const c=(m=a.exception)==null?void 0:m.values;if(c){l=!0,r=!1;for(const v of c)if(((p=v.mechanism)==null?void 0:p.handled)===!1){r=!0;break}}const f=t.status==="ok";(f&&t.errors===0||f&&r)&&(Ja(t,{...r&&{status:"crashed"},errors:t.errors||Number(l||r)}),this.captureSession(t))}async _isClientDoneProcessing(t){let a=0;for(;!t||asetTimeout(r,1)),!this._numProcessing)return!0;a++}return!1}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,a,r,l){const c=this.getOptions(),f=Object.keys(this._integrations);return!a.integrations&&(f!=null&&f.length)&&(a.integrations=f),this.emit("preprocessEvent",t,a),t.type||l.setLastEventId(t.event_id||a.event_id),sE(c,t,a,r,this,l).then(h=>{var p;if(h===null)return h;this.emit("postprocessEvent",h,a),h.contexts={trace:{...(p=h.contexts)==null?void 0:p.trace,...Q_(r)},...h.contexts};const m=RT(this,r);return h.sdkProcessingMetadata={dynamicSamplingContext:m,...h.sdkProcessingMetadata},h})}_captureEvent(t,a={},r=vn(),l=wi()){return ce&&dd(t)&&ae.log(`Captured error event \`${pb(t)[0]||""}\``),this._processEvent(t,a,r,l).then(c=>c.event_id,c=>{ce&&(T0(c)?ae.log(c.message):_0(c)?ae.warn(c.message):ae.warn(c))})}_processEvent(t,a,r,l){const c=this.getOptions(),{sampleRate:f}=c,h=vb(t),m=dd(t),v=`before send for type \`${t.type||"error"}\``,x=typeof f>"u"?void 0:xT(f);if(m&&typeof x=="number"&&_l()>x)return this.recordDroppedEvent("sample_rate","error"),ih(jf(`Discarding event because it's not included in the random sample (sampling rate = ${f})`));const S=A0(t.type);return this._prepareEvent(t,a,r,l).then(w=>{var z;if(w===null)throw this.recordDroppedEvent("event_processor",S),jf("An event processor returned `null`, will not send event.");if(((z=a.data)==null?void 0:z.__sentry__)===!0)return w;const k=qE(this,c,w,a);return IE(k,v)}).then(w=>{var z;if(w===null){if(this.recordDroppedEvent("before_send",S),h){const I=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",I)}throw jf(`${v} returned \`null\`, will not send event.`)}const T=r.getSession()||l.getSession();if(m&&T&&this._updateSessionFromEvent(T,w),h){const B=((z=w.sdkProcessingMetadata)==null?void 0:z.spanCountBeforeProcessing)||0,I=w.spans?w.spans.length:0,H=B-I;H>0&&this.recordDroppedEvent("before_send","span",H)}const k=w.transaction_info;if(h&&k&&w.transaction!==t.transaction){const B="custom";w.transaction_info={...k,source:B}}return this.sendEvent(w,a),w}).then(null,w=>{throw T0(w)||_0(w)?w:(this.captureException(w,{mechanism:{handled:!1,type:"internal"},data:{__sentry__:!0},originalException:w}),ul(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. +Reason: ${w}`))})}_process(t,a){this._numProcessing++,this._promiseBuffer.add(t).then(r=>(this._numProcessing--,r),r=>(this._numProcessing--,r===ah&&this.recordDroppedEvent("queue_overflow",a),r))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([a,r])=>{const[l,c]=a.split(":");return{reason:l,category:c,quantity:r}})}_flushOutcomes(){ce&&ae.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){ce&&ae.log("No outcomes to send");return}if(!this._dsn){ce&&ae.log("No dsn provided, will not send outcomes");return}ce&&ae.log("Sending outcomes:",t);const a=VE(t,this._options.tunnel&&Cr(this._dsn));this.sendEnvelope(a)}}function A0(n){return n==="replay_event"?"replay":n||"error"}function IE(n,t){const a=`${t} must return \`null\` or a valid event.`;if(Ar(n))return n.then(r=>{if(!vr(r)&&r!==null)throw ul(a);return r},r=>{throw ul(`${t} rejected with ${r}`)});if(!vr(n)&&n!==null)throw ul(a);return n}function qE(n,t,a,r){const{beforeSend:l,beforeSendTransaction:c,ignoreSpans:f}=t,h=!LT(t.beforeSendSpan)&&t.beforeSendSpan;let m=a;if(dd(m)&&l)return l(m,r);if(vb(m)){if(h||f){const p=BE(m);if(f!=null&&f.length&&f0(p,f))return null;if(h){const v=h(p);v?m=Dr(a,UE(v)):c0()}if(m.spans){const v=[],x=m.spans;for(const w of x){if(f!=null&&f.length&&f0(w,f)){jT(x,w);continue}if(h){const T=h(w);T?v.push(T):(c0(),v.push(w))}else v.push(w)}const S=m.spans.length-v.length;S&&n.recordDroppedEvent("before_send","span",S),m.spans=v}}if(c){if(m.spans){const p=m.spans.length;m.sdkProcessingMetadata={...a.sdkProcessingMetadata,spanCountBeforeProcessing:p}}return c(m,r)}}return m}function dd(n){return n.type===void 0}function vb(n){return n.type==="transaction"}function FE(n){let t=0;return n.name&&(t+=n.name.length*2),t+=8,t+xb(n.attributes)}function GE(n){let t=0;return n.message&&(t+=n.message.length*2),t+xb(n.attributes)}function xb(n){if(!n)return 0;let t=0;return Object.values(n).forEach(a=>{Array.isArray(a)?t+=a.length*N0(a[0]):Gl(a)?t+=N0(a):t+=100}),t}function N0(n){return typeof n=="string"?n.length*2:typeof n=="number"?8:typeof n=="boolean"?4:0}function YE(n){return Fl(n)&&"__sentry_fetch_url_host__"in n&&typeof n.__sentry_fetch_url_host__=="string"}function D0(n){return YE(n)?`${n.message} (${n.__sentry_fetch_url_host__})`:n.message}function KE(n,t){t.debug===!0&&(ce?ae.enable():ss(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),vn().update(t.initialScope);const r=new n(t);return XE(r),r.init(),r}function XE(n){vn().setClient(n)}function Mf(n){if(!n)return{};const t=n.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const a=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:a,hash:r,relative:t[5]+a+r}}function $E(n,t=!0){if(n.startsWith("data:")){const a=n.match(/^data:([^;,]+)/),r=a?a[1]:"text/plain",l=n.includes(";base64,"),c=n.indexOf(",");let f="";if(t&&c!==-1){const h=n.slice(c+1);f=h.length>10?`${h.slice(0,10)}... [truncated]`:h}return`data:${r}${l?",base64":""}${f?`,${f}`:""}`}return n}function ZE(n){var t;"aggregates"in n?((t=n.attrs)==null?void 0:t.ip_address)===void 0&&(n.attrs={...n.attrs,ip_address:"{{auto}}"}):n.ipAddress===void 0&&(n.ipAddress="{{auto}}")}function bb(n,t,a=[t],r="npm"){const l=(n._metadata=n._metadata||{}).sdk=n._metadata.sdk||{};l.name||(l.name=`sentry.javascript.${t}`,l.packages=a.map(c=>({name:`${r}:@sentry/${c}`,version:$i})),l.version=$i)}const QE=100;function ea(n,t){const a=gt(),r=wi();if(!a)return;const{beforeBreadcrumb:l=null,maxBreadcrumbs:c=QE}=a.getOptions();if(c<=0)return;const h={timestamp:Nr(),...n},m=l?ss(()=>l(h,t)):h;m!==null&&(a.emit&&a.emit("beforeAddBreadcrumb",m,t),r.addBreadcrumb(m,c))}let C0;const WE="FunctionToString",j0=new WeakMap,JE=(()=>({name:WE,setupOnce(){C0=Function.prototype.toString;try{Function.prototype.toString=function(...n){const t=eh(this),a=j0.has(gt())&&t!==void 0?t:this;return C0.apply(a,n)}}catch{}},setup(n){j0.set(n,!0)}})),eA=JE,tA=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,/can't redefine non-configurable property "solana"/,/vv\(\)\.getRestrictions is not a function/,/Can't find variable: _AutofillCallbackHandler/,/Object Not Found Matching Id:\d+, MethodName:simulateEvent/,/^Java exception was raised during method invocation$/],nA="EventFilters",iA=(n={})=>{let t;return{name:nA,setup(a){const r=a.getOptions();t=M0(n,r)},processEvent(a,r,l){if(!t){const c=l.getOptions();t=M0(n,c)}return sA(a,t)?null:a}}},aA=((n={})=>({...iA(n),name:"InboundFilters"}));function M0(n={},t={}){return{allowUrls:[...n.allowUrls||[],...t.allowUrls||[]],denyUrls:[...n.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...n.ignoreErrors||[],...t.ignoreErrors||[],...n.disableErrorDefaults?[]:tA],ignoreTransactions:[...n.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function sA(n,t){if(n.type){if(n.type==="transaction"&&oA(n,t.ignoreTransactions))return ce&&ae.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. Event: ${Yi(n)}`),!0}else{if(rA(n,t.ignoreErrors))return ce&&ae.warn(`Event dropped due to being matched by \`ignoreErrors\` option. Event: ${Yi(n)}`),!0;if(fA(n))return ce&&ae.warn(`Event dropped due to not having an error message, error type or stacktrace. Event: ${Yi(n)}`),!0;if(lA(n,t.denyUrls))return ce&&ae.warn(`Event dropped due to being matched by \`denyUrls\` option. Event: ${Yi(n)}. Url: ${Tl(n)}`),!0;if(!cA(n,t.allowUrls))return ce&&ae.warn(`Event dropped due to not being matched by \`allowUrls\` option. Event: ${Yi(n)}. -Url: ${Tl(n)}`),!0}return!1}function rA(n,t){return t!=null&&t.length?mb(n).some(a=>$l(a,t)):!1}function oA(n,t){if(!(t!=null&&t.length))return!1;const a=n.transaction;return a?$l(a,t):!1}function lA(n,t){if(!(t!=null&&t.length))return!1;const a=Tl(n);return a?$l(a,t):!1}function cA(n,t){if(!(t!=null&&t.length))return!0;const a=Tl(n);return a?$l(a,t):!0}function uA(n=[]){for(let t=n.length-1;t>=0;t--){const a=n[t];if(a&&a.filename!==""&&a.filename!=="[native code]")return a.filename||null}return null}function Tl(n){var t,a;try{const r=[...((t=n.exception)==null?void 0:t.values)??[]].reverse().find(c=>{var f,h,m;return((f=c.mechanism)==null?void 0:f.parent_id)===void 0&&((m=(h=c.stacktrace)==null?void 0:h.frames)==null?void 0:m.length)}),l=(a=r==null?void 0:r.stacktrace)==null?void 0:a.frames;return l?uA(l):null}catch{return ce&&ae.error(`Cannot extract url for event ${Yi(n)}`),null}}function fA(n){var t,a;return(a=(t=n.exception)==null?void 0:t.values)!=null&&a.length?!n.message&&!n.exception.values.some(r=>r.stacktrace||r.type&&r.type!=="Error"||r.value):!1}function dA(n,t,a,r,l,c){var h;if(!((h=l.exception)!=null&&h.values)||!c||!vi(c.originalException,Error))return;const f=l.exception.values.length>0?l.exception.values[l.exception.values.length-1]:void 0;f&&(l.exception.values=hd(n,t,r,c.originalException,a,l.exception.values,f,0))}function hd(n,t,a,r,l,c,f,h){if(c.length>=a+1)return c;let m=[...c];if(vi(r[l],Error)){O0(f,h,r);const p=n(t,r[l]),v=m.length;R0(p,l,v,h),m=hd(n,t,a,r[l],l,[p,...m],p,v)}return bb(r)&&r.errors.forEach((p,v)=>{if(vi(p,Error)){O0(f,h,r);const x=n(t,p),S=m.length;R0(x,`errors[${v}]`,S,h),m=hd(n,t,a,p,l,[x,...m],x,S)}}),m}function bb(n){return Array.isArray(n.errors)}function O0(n,t,a){n.mechanism={handled:!0,type:"auto.core.linked_errors",...bb(a)&&{is_exception_group:!0},...n.mechanism,exception_id:t}}function R0(n,t,a,r){n.mechanism={handled:!0,...n.mechanism,type:"chained",source:t,exception_id:a,parent_id:r}}function hA(n){const t="console";na(t,n),ia(t,mA)}function mA(){"console"in Oe&&f_.forEach(function(n){n in Oe.console&&Ut(Oe.console,n,function(t){return wl[n]=t,function(...a){rn("console",{args:a,level:n});const l=wl[n];l==null||l.apply(Oe.console,a)}})})}function pA(n){return n==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(n)?n:"log"}const gA="Dedupe",yA=(()=>{let n;return{name:gA,processEvent(t){if(t.type)return t;try{if(xA(t,n))return ce&&ae.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return n=t}}}),vA=yA;function xA(n,t){return t?!!(bA(n,t)||SA(n,t)):!1}function bA(n,t){const a=n.message,r=t.message;return!(!a&&!r||a&&!r||!a&&r||a!==r||!wb(n,t)||!Sb(n,t))}function SA(n,t){const a=k0(t),r=k0(n);return!(!a||!r||a.type!==r.type||a.value!==r.value||!wb(n,t)||!Sb(n,t))}function Sb(n,t){let a=Gy(n),r=Gy(t);if(!a&&!r)return!0;if(a&&!r||!a&&r||(a=a,r=r,r.length!==a.length))return!1;for(let l=0;l({name:wA,setup(n){n.on("spanStart",t=>{const a=vn().getScopeData(),r=wi().getScopeData(),l=a.conversationId||r.conversationId;if(l){const{op:c,data:f,description:h}=Zl(t);if(!(c!=null&&c.startsWith("gen_ai."))&&!f["ai.operationId"]&&!(h!=null&&h.startsWith("ai.")))return;t.setAttribute(nT,l)}})}})),TA=_A;function _b(n){if(n!==void 0)return n>=400&&n<500?"warning":n>=500?"error":void 0}const br=Oe;function EA(){return"history"in br&&!!br.history}function AA(){if(!("fetch"in br))return!1;try{return new Headers,new Request("data:,"),new Response,!0}catch{return!1}}function md(n){return n&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(n.toString())}function NA(){var a;if(typeof EdgeRuntime=="string")return!0;if(!AA())return!1;if(md(br.fetch))return!0;let n=!1;const t=br.document;if(t&&typeof t.createElement=="function")try{const r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),(a=r.contentWindow)!=null&&a.fetch&&(n=md(r.contentWindow.fetch)),t.head.removeChild(r)}catch(r){ce&&ae.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return n}function DA(n,t){const a="fetch";na(a,n),ia(a,()=>CA(void 0,t))}function CA(n,t=!1){t&&!NA()||Ut(Oe,"fetch",function(a){return function(...r){const l=new Error,{method:c,url:f}=jA(r),h={args:r,fetchData:{method:c,url:f},startTimestamp:Pn()*1e3,virtualError:l,headers:MA(r)};return rn("fetch",{...h}),a.apply(Oe,r).then(async m=>(rn("fetch",{...h,endTimestamp:Pn()*1e3,response:m}),m),m=>{rn("fetch",{...h,endTimestamp:Pn()*1e3,error:m}),Fl(m)&&m.stack===void 0&&(m.stack=l.stack,xi(m,"framesToPop",1));const p=gt(),v=(p==null?void 0:p.getOptions().enhanceFetchErrorMessages)??"always";if(v!==!1&&m instanceof TypeError&&(m.message==="Failed to fetch"||m.message==="Load failed"||m.message==="NetworkError when attempting to fetch resource."))try{const w=new URL(h.fetchData.url).host;v==="always"?m.message=`${m.message} (${w})`:xi(m,"__sentry_fetch_url_host__",w)}catch{}throw m})}})}function fl(n,t){return!!n&&typeof n=="object"&&!!n[t]}function L0(n){return typeof n=="string"?n:n?fl(n,"url")?n.url:n.toString?n.toString():"":""}function jA(n){if(n.length===0)return{method:"GET",url:""};if(n.length===2){const[a,r]=n;return{url:L0(a),method:fl(r,"method")?String(r.method).toUpperCase():Px(a)&&fl(a,"method")?String(a.method).toUpperCase():"GET"}}const t=n[0];return{url:L0(t),method:fl(t,"method")?String(t.method).toUpperCase():"GET"}}function MA(n){const[t,a]=n;try{if(typeof a=="object"&&a!==null&&"headers"in a&&a.headers)return new Headers(a.headers);if(Px(t))return new Headers(t.headers)}catch{}}function OA(){return"npm"}const Ke=Oe;let pd=0;function Tb(){return pd>0}function RA(){pd++,setTimeout(()=>{pd--})}function ts(n,t={}){function a(l){return typeof l=="function"}if(!a(n))return n;try{const l=n.__sentry_wrapped__;if(l)return typeof l=="function"?l:n;if(eh(n))return n}catch{return n}const r=function(...l){try{const c=l.map(f=>ts(f,t));return n.apply(this,c)}catch(c){throw RA(),$_(f=>{f.addEventProcessor(h=>(t.mechanism&&(sd(h,void 0),Wa(h,t.mechanism)),h.extra={...h.extra,arguments:l},h)),Ji(c)}),c}};try{for(const l in n)Object.prototype.hasOwnProperty.call(n,l)&&(r[l]=n[l])}catch{}Ix(r,n),xi(n,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return n.name}})}catch{}return r}function kA(){const n=Jd(),{referrer:t}=Ke.document||{},{userAgent:a}=Ke.navigator||{},r={...t&&{Referer:t},...a&&{"User-Agent":a}};return{url:n,headers:r}}function rh(n,t){const a=oh(n,t),r={type:UA(t),value:PA(t)};return a.length&&(r.stacktrace={frames:a}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function LA(n,t,a,r){const l=gt(),c=l==null?void 0:l.getOptions().normalizeDepth,f=GA(t),h={__serialized__:tb(t,c)};if(f)return{exception:{values:[rh(n,f)]},extra:h};const m={exception:{values:[{type:Yl(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:qA(t,{isUnhandledRejection:r})}]},extra:h};if(a){const p=oh(n,a);p.length&&(m.exception.values[0].stacktrace={frames:p})}return m}function Of(n,t){return{exception:{values:[rh(n,t)]}}}function oh(n,t){const a=t.stacktrace||t.stack||"",r=VA(t),l=BA(t);try{return n(a,r,l)}catch{}return[]}const zA=/Minified React error #\d+;/i;function VA(n){return n&&zA.test(n.message)?1:0}function BA(n){return typeof n.framesToPop=="number"?n.framesToPop:0}function Eb(n){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?n instanceof WebAssembly.Exception:!1}function UA(n){const t=n==null?void 0:n.name;return!t&&Eb(n)?n.message&&Array.isArray(n.message)&&n.message.length==2?n.message[0]:"WebAssembly.Exception":t}function PA(n){const t=n==null?void 0:n.message;return Eb(n)?Array.isArray(n.message)&&n.message.length==2?n.message[1]:"wasm exception":t?t.error&&typeof t.error.message=="string"?D0(t.error):D0(n):"No error message"}function HA(n,t,a,r){const l=(a==null?void 0:a.syntheticException)||void 0,c=lh(n,t,l,r);return Wa(c),c.level="error",a!=null&&a.event_id&&(c.event_id=a.event_id),jr(c)}function IA(n,t,a="info",r,l){const c=(r==null?void 0:r.syntheticException)||void 0,f=gd(n,t,c,l);return f.level=a,r!=null&&r.event_id&&(f.event_id=r.event_id),jr(f)}function lh(n,t,a,r,l){let c;if(Bx(t)&&t.error)return Of(n,t.error);if(Ky(t)||T_(t)){const f=t;if("stack"in t)c=Of(n,t);else{const h=f.name||(Ky(f)?"DOMError":"DOMException"),m=f.message?`${h}: ${f.message}`:h;c=gd(n,m,a,r),sd(c,m)}return"code"in f&&(c.tags={...c.tags,"DOMException.code":`${f.code}`}),c}return Fl(t)?Of(n,t):vr(t)||Yl(t)?(c=LA(n,t,a,l),Wa(c,{synthetic:!0}),c):(c=gd(n,t,a,r),sd(c,`${t}`),Wa(c,{synthetic:!0}),c)}function gd(n,t,a,r){const l={};if(r&&a){const c=oh(n,a);c.length&&(l.exception={values:[{value:t,stacktrace:{frames:c}}]}),Wa(l,{synthetic:!0})}if(Qd(t)){const{__sentry_template_string__:c,__sentry_template_values__:f}=t;return l.logentry={message:c,params:f},l}return l.message=t,l}function qA(n,{isUnhandledRejection:t}){const a=M_(n),r=t?"promise rejection":"exception";return Bx(n)?`Event \`ErrorEvent\` captured as ${r} with message \`${n.message}\``:Yl(n)?`Event \`${FA(n)}\` (type=${n.type}) captured as ${r}`:`Object captured as ${r} with keys: ${a}`}function FA(n){try{const t=Object.getPrototypeOf(n);return t?t.constructor.name:void 0}catch{}}function GA(n){return Object.values(n).find(t=>t instanceof Error)}class YA extends HE{constructor(t){var v;const a=KA(t),r=Ke.SENTRY_SDK_SOURCE||OA();xb(a,"browser",["browser"],r),(v=a._metadata)!=null&&v.sdk&&(a._metadata.sdk.settings={infer_ip:a.sendDefaultPii?"auto":"never",...a._metadata.sdk.settings}),super(a);const{sendDefaultPii:l,sendClientReports:c,enableLogs:f,_experiments:h,enableMetrics:m}=this._options,p=m??(h==null?void 0:h.enableMetrics)??!0;Ke.document&&(c||f||p)&&Ke.document.addEventListener("visibilitychange",()=>{Ke.document.visibilityState==="hidden"&&(c&&this._flushOutcomes(),f&&fd(this),p&&ub(this))}),l&&this.on("beforeSendSession",ZE)}eventFromException(t,a){return HA(this._options.stackParser,t,a,this._options.attachStacktrace)}eventFromMessage(t,a="info",r){return IA(this._options.stackParser,t,a,r,this._options.attachStacktrace)}_prepareEvent(t,a,r,l){return t.platform=t.platform||"javascript",super._prepareEvent(t,a,r,l)}}function KA(n){var t;return{release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:(t=Ke.SENTRY_RELEASE)==null?void 0:t.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...n}}const XA=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,xt=Oe,$A=1e3;let z0,yd,vd;function ZA(n){na("dom",n),ia("dom",QA)}function QA(){if(!xt.document)return;const n=rn.bind(null,"dom"),t=V0(n,!0);xt.document.addEventListener("click",t,!1),xt.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(a=>{var c,f;const l=(c=xt[a])==null?void 0:c.prototype;(f=l==null?void 0:l.hasOwnProperty)!=null&&f.call(l,"addEventListener")&&(Ut(l,"addEventListener",function(h){return function(m,p,v){if(m==="click"||m=="keypress")try{const x=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},S=x[m]=x[m]||{refCount:0};if(!S.handler){const w=V0(n);S.handler=w,h.call(this,m,w,v)}S.refCount++}catch{}return h.call(this,m,p,v)}}),Ut(l,"removeEventListener",function(h){return function(m,p,v){if(m==="click"||m=="keypress")try{const x=this.__sentry_instrumentation_handlers__||{},S=x[m];S&&(S.refCount--,S.refCount<=0&&(h.call(this,m,S.handler,v),S.handler=void 0,delete x[m]),Object.keys(x).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return h.call(this,m,p,v)}}))})}function WA(n){if(n.type!==yd)return!1;try{if(!n.target||n.target._sentryId!==vd)return!1}catch{}return!0}function JA(n,t){return n!=="keypress"?!1:t!=null&&t.tagName?!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable):!0}function V0(n,t=!1){return a=>{if(!a||a._sentryCaptured)return;const r=eN(a);if(JA(a.type,r))return;xi(a,"_sentryCaptured",!0),r&&!r._sentryId&&xi(r,"_sentryId",Wt());const l=a.type==="keypress"?"input":a.type;WA(a)||(n({event:a,name:l,global:t}),yd=a.type,vd=r?r._sentryId:void 0),clearTimeout(z0),z0=xt.setTimeout(()=>{vd=void 0,yd=void 0},$A)}}function eN(n){try{return n.target}catch{return null}}let tl;function Ab(n){const t="history";na(t,n),ia(t,tN)}function tN(){if(xt.addEventListener("popstate",()=>{const t=xt.location.href,a=tl;if(tl=t,a===t)return;rn("history",{from:a,to:t})}),!EA())return;function n(t){return function(...a){const r=a.length>2?a[2]:void 0;if(r){const l=tl,c=nN(String(r));if(tl=c,l===c)return t.apply(this,a);rn("history",{from:l,to:c})}return t.apply(this,a)}}Ut(xt.history,"pushState",n),Ut(xt.history,"replaceState",n)}function nN(n){try{return new URL(n,xt.location.origin).toString()}catch{return n}}const dl={};function iN(n){const t=dl[n];if(t)return t;let a=xt[n];if(md(a))return dl[n]=a.bind(xt);const r=xt.document;if(r&&typeof r.createElement=="function")try{const l=r.createElement("iframe");l.hidden=!0,r.head.appendChild(l);const c=l.contentWindow;c!=null&&c[n]&&(a=c[n]),r.head.removeChild(l)}catch(l){XA&&ae.warn(`Could not create sandbox iframe for ${n} check, bailing to window.${n}: `,l)}return a&&(dl[n]=a.bind(xt))}function aN(n){dl[n]=void 0}const ur="__sentry_xhr_v3__";function sN(n){na("xhr",n),ia("xhr",rN)}function rN(){if(!xt.XMLHttpRequest)return;const n=XMLHttpRequest.prototype;n.open=new Proxy(n.open,{apply(t,a,r){const l=new Error,c=Pn()*1e3,f=Un(r[0])?r[0].toUpperCase():void 0,h=oN(r[1]);if(!f||!h)return t.apply(a,r);a[ur]={method:f,url:h,request_headers:{}},f==="POST"&&h.match(/sentry_key/)&&(a.__sentry_own_request__=!0);const m=()=>{const p=a[ur];if(p&&a.readyState===4){try{p.status_code=a.status}catch{}const v={endTimestamp:Pn()*1e3,startTimestamp:c,xhr:a,virtualError:l};rn("xhr",v)}};return"onreadystatechange"in a&&typeof a.onreadystatechange=="function"?a.onreadystatechange=new Proxy(a.onreadystatechange,{apply(p,v,x){return m(),p.apply(v,x)}}):a.addEventListener("readystatechange",m),a.setRequestHeader=new Proxy(a.setRequestHeader,{apply(p,v,x){const[S,w]=x,T=v[ur];return T&&Un(S)&&Un(w)&&(T.request_headers[S.toLowerCase()]=w),p.apply(v,x)}}),t.apply(a,r)}}),n.send=new Proxy(n.send,{apply(t,a,r){const l=a[ur];if(!l)return t.apply(a,r);r[0]!==void 0&&(l.body=r[0]);const c={startTimestamp:Pn()*1e3,xhr:a};return rn("xhr",c),t.apply(a,r)}})}function oN(n){if(Un(n))return n;try{return n.toString()}catch{}}const lN=40;function cN(n,t=iN("fetch")){let a=0,r=0;async function l(c){const f=c.body.length;a+=f,r++;const h={body:c.body,method:"POST",referrerPolicy:"strict-origin",headers:n.headers,keepalive:a<=6e4&&r<15,...n.fetchOptions};try{const m=await t(n.url,h);return{statusCode:m.status,headers:{"x-sentry-rate-limits":m.headers.get("X-Sentry-Rate-Limits"),"retry-after":m.headers.get("Retry-After")}}}catch(m){throw aN("fetch"),m}finally{a-=f,r--}}return zE(n,l,sh(n.bufferSize||lN))}const Ql=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,uN=30,fN=50;function xd(n,t,a,r){const l={filename:n,function:t===""?Wi:t,in_app:!0};return a!==void 0&&(l.lineno=a),r!==void 0&&(l.colno=r),l}const dN=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,hN=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,mN=/\((\S*)(?::(\d+))(?::(\d+))\)/,pN=/at (.+?) ?\(data:(.+?),/,gN=n=>{var l;const t=n.match(pN);if(t)return{filename:``,function:t[1]};const a=dN.exec(n);if(a){const[,c,f,h]=a;return xd(c,Wi,+f,+h)}const r=hN.exec(n);if(r){if(((l=r[2])==null?void 0:l.indexOf("eval"))===0){const m=mN.exec(r[2]);m&&(r[2]=m[1],r[3]=m[2],r[4]=m[3])}const[f,h]=Nb(r[1]||Wi,r[2]);return xd(h,f,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}},yN=[uN,gN],vN=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,xN=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,bN=n=>{const t=vN.exec(n);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const c=xN.exec(t[3]);c&&(t[1]=t[1]||"eval",t[3]=c[1],t[4]=c[2],t[5]="")}let r=t[3],l=t[1]||Wi;return[l,r]=Nb(l,r),xd(r,l,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},SN=[fN,bN],wN=[yN,SN],_N=Lx(...wN),Nb=(n,t)=>{const a=n.indexOf("safari-extension")!==-1,r=n.indexOf("safari-web-extension")!==-1;return a||r?[n.indexOf("@")!==-1?n.split("@")[0]:Wi,a?`safari-extension:${t}`:`safari-web-extension:${t}`]:[n,t]},nl=1024,TN="Breadcrumbs",EN=((n={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...n};return{name:TN,setup(a){t.console&&hA(CN(a)),t.dom&&ZA(DN(a,t.dom)),t.xhr&&sN(jN(a)),t.fetch&&DA(MN(a)),t.history&&Ab(ON(a)),t.sentry&&a.on("beforeSendEvent",NN(a))}}}),AN=EN;function NN(n){return function(a){gt()===n&&ea({category:`sentry.${a.type==="transaction"?"transaction":"event"}`,event_id:a.event_id,level:a.level,message:Yi(a)},{event:a})}}function DN(n,t){return function(r){if(gt()!==n)return;let l,c,f=typeof t=="object"?t.serializeAttribute:void 0,h=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;h&&h>nl&&(Ql&&ae.warn(`\`dom.maxStringLength\` cannot exceed ${nl}, but a value of ${h} was configured. Sentry will use ${nl} instead.`),h=nl),typeof f=="string"&&(f=[f]);try{const p=r.event,v=RN(p)?p.target:p;l=Hx(v,{keyAttrs:f,maxStringLength:h}),c=j_(v)}catch{l=""}if(l.length===0)return;const m={category:`ui.${r.name}`,message:l};c&&(m.data={"ui.component_name":c}),ea(m,{event:r.event,name:r.name,global:r.global})}}function CN(n){return function(a){if(gt()!==n)return;const r={category:"console",data:{arguments:a.args,logger:"console"},level:pA(a.level),message:Zy(a.args," ")};if(a.level==="assert")if(a.args[0]===!1)r.message=`Assertion failed: ${Zy(a.args.slice(1)," ")||"console.assert"}`,r.data.arguments=a.args.slice(1);else return;ea(r,{input:a.args,level:a.level})}}function jN(n){return function(a){if(gt()!==n)return;const{startTimestamp:r,endTimestamp:l}=a,c=a.xhr[ur];if(!r||!l||!c)return;const{method:f,url:h,status_code:m,body:p}=c,v={method:f,url:h,status_code:m},x={xhr:a.xhr,input:p,startTimestamp:r,endTimestamp:l},S={category:"xhr",data:v,type:"http",level:_b(m)};n.emit("beforeOutgoingRequestBreadcrumb",S,x),ea(S,x)}}function MN(n){return function(a){if(gt()!==n)return;const{startTimestamp:r,endTimestamp:l}=a;if(l&&!(a.fetchData.url.match(/sentry_key/)&&a.fetchData.method==="POST"))if(a.error){const c={data:a.error,input:a.args,startTimestamp:r,endTimestamp:l},f={category:"fetch",data:a.fetchData,level:"error",type:"http"};n.emit("beforeOutgoingRequestBreadcrumb",f,c),ea(f,c)}else{const c=a.response,f={...a.fetchData,status_code:c==null?void 0:c.status},h={input:a.args,response:c,startTimestamp:r,endTimestamp:l},m={category:"fetch",data:f,type:"http",level:_b(f.status_code)};n.emit("beforeOutgoingRequestBreadcrumb",m,h),ea(m,h)}}}function ON(n){return function(a){if(gt()!==n)return;let r=a.from,l=a.to;const c=Mf(Ke.location.href);let f=r?Mf(r):void 0;const h=Mf(l);f!=null&&f.path||(f=c),c.protocol===h.protocol&&c.host===h.host&&(l=h.relative),c.protocol===f.protocol&&c.host===f.host&&(r=f.relative),ea({category:"navigation",data:{from:r,to:l}})}}function RN(n){return!!n&&!!n.target}const kN="EventTarget,Window,Node,ApplicationCache,AudioTrackList,BroadcastChannel,ChannelMergerNode,CryptoOperation,EventSource,FileReader,HTMLUnknownElement,IDBDatabase,IDBRequest,IDBTransaction,KeyOperation,MediaController,MessagePort,ModalWindow,Notification,SVGElementInstance,Screen,SharedWorker,TextTrack,TextTrackCue,TextTrackList,WebSocket,WebSocketWorker,Worker,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload".split(","),LN="BrowserApiErrors",zN=((n={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...n};return{name:LN,setupOnce(){t.setTimeout&&Ut(Ke,"setTimeout",B0),t.setInterval&&Ut(Ke,"setInterval",B0),t.requestAnimationFrame&&Ut(Ke,"requestAnimationFrame",BN),t.XMLHttpRequest&&"XMLHttpRequest"in Ke&&Ut(XMLHttpRequest.prototype,"send",UN);const a=t.eventTarget;a&&(Array.isArray(a)?a:kN).forEach(l=>PN(l,t))}}}),VN=zN;function B0(n){return function(...t){const a=t[0];return t[0]=ts(a,{mechanism:{handled:!1,type:`auto.browser.browserapierrors.${yi(n)}`}}),n.apply(this,t)}}function BN(n){return function(t){return n.apply(this,[ts(t,{mechanism:{data:{handler:yi(n)},handled:!1,type:"auto.browser.browserapierrors.requestAnimationFrame"}})])}}function UN(n){return function(...t){const a=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(l=>{l in a&&typeof a[l]=="function"&&Ut(a,l,function(c){const f={mechanism:{data:{handler:yi(c)},handled:!1,type:`auto.browser.browserapierrors.xhr.${l}`}},h=eh(c);return h&&(f.mechanism.data.handler=yi(h)),ts(c,f)})}),n.apply(this,t)}}function PN(n,t){var l,c;const r=(l=Ke[n])==null?void 0:l.prototype;(c=r==null?void 0:r.hasOwnProperty)!=null&&c.call(r,"addEventListener")&&(Ut(r,"addEventListener",function(f){return function(h,m,p){try{HN(m)&&(m.handleEvent=ts(m.handleEvent,{mechanism:{data:{handler:yi(m),target:n},handled:!1,type:"auto.browser.browserapierrors.handleEvent"}}))}catch{}return t.unregisterOriginalCallbacks&&IN(this,h,m),f.apply(this,[h,ts(m,{mechanism:{data:{handler:yi(m),target:n},handled:!1,type:"auto.browser.browserapierrors.addEventListener"}}),p])}}),Ut(r,"removeEventListener",function(f){return function(h,m,p){try{const v=m.__sentry_wrapped__;v&&f.call(this,h,v,p)}catch{}return f.call(this,h,m,p)}}))}function HN(n){return typeof n.handleEvent=="function"}function IN(n,t,a){n&&typeof n=="object"&&"removeEventListener"in n&&typeof n.removeEventListener=="function"&&n.removeEventListener(t,a)}const qN=(n={})=>{const t=n.lifecycle??"route";return{name:"BrowserSession",setupOnce(){if(typeof Ke.document>"u"){Ql&&ae.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}v0({ignoreDuration:!0}),Cf();const a=wi();let r=a.getUser();a.addScopeListener(l=>{const c=l.getUser();((r==null?void 0:r.id)!==(c==null?void 0:c.id)||(r==null?void 0:r.ip_address)!==(c==null?void 0:c.ip_address))&&(Cf(),r=c)}),t==="route"&&Ab(({from:l,to:c})=>{l!==c&&(v0({ignoreDuration:!0}),Cf())})}}},FN="CultureContext",GN=(()=>({name:FN,preprocessEvent(n){var a;const t=KN();t&&(n.contexts={...n.contexts,culture:{...t,...(a=n.contexts)==null?void 0:a.culture}})}})),YN=GN;function KN(){try{const n=Ke.Intl;if(!n)return;const t=n.DateTimeFormat().resolvedOptions();return{locale:t.locale,timezone:t.timeZone,calendar:t.calendar}}catch{return}}const XN="GlobalHandlers",$N=((n={})=>{const t={onerror:!0,onunhandledrejection:!0,...n};return{name:XN,setupOnce(){Error.stackTraceLimit=50},setup(a){t.onerror&&(QN(a),U0("onerror")),t.onunhandledrejection&&(WN(a),U0("onunhandledrejection"))}}}),ZN=$N;function QN(n){b_(t=>{const{stackParser:a,attachStacktrace:r}=Db();if(gt()!==n||Tb())return;const{msg:l,url:c,line:f,column:h,error:m}=t,p=tD(lh(a,m||l,void 0,r,!1),c,f,h);p.level="error",sb(p,{originalException:m,mechanism:{handled:!1,type:"auto.browser.global_handlers.onerror"}})})}function WN(n){w_(t=>{const{stackParser:a,attachStacktrace:r}=Db();if(gt()!==n||Tb())return;const l=JN(t),c=Gl(l)?eD(l):lh(a,l,void 0,r,!0);c.level="error",sb(c,{originalException:l,mechanism:{handled:!1,type:"auto.browser.global_handlers.onunhandledrejection"}})})}function JN(n){if(Gl(n))return n;try{if("reason"in n)return n.reason;if("detail"in n&&"reason"in n.detail)return n.detail.reason}catch{}return n}function eD(n){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(n)}`}]}}}function tD(n,t,a,r){const l=n.exception=n.exception||{},c=l.values=l.values||[],f=c[0]=c[0]||{},h=f.stacktrace=f.stacktrace||{},m=h.frames=h.frames||[];return m.length===0&&m.push({colno:r,lineno:a,filename:nD(t)??Jd(),function:Wi,in_app:!0}),n}function U0(n){Ql&&ae.log(`Global Handler attached: ${n}`)}function Db(){const n=gt();return(n==null?void 0:n.getOptions())||{stackParser:()=>[],attachStacktrace:!1}}function nD(n){if(!(!Un(n)||n.length===0))return n.startsWith("data:")?`<${$E(n,!1)}>`:n}const iD=()=>({name:"HttpContext",preprocessEvent(n){var r;if(!Ke.navigator&&!Ke.location&&!Ke.document)return;const t=kA(),a={...t.headers,...(r=n.request)==null?void 0:r.headers};n.request={...t,...n.request,headers:a}}}),aD="cause",sD=5,rD="LinkedErrors",oD=((n={})=>{const t=n.limit||sD,a=n.key||aD;return{name:rD,preprocessEvent(r,l,c){const f=c.getOptions();dA(rh,f.stackParser,a,t,r,l)}}}),lD=oD;function cD(){return uD()?(Ql&&ss(()=>{console.error("[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}),!0):!1}function uD(){var l;if(typeof Ke.window>"u")return!1;const n=Ke;if(n.nw)return!1;const t=n.chrome||n.browser;if(!((l=t==null?void 0:t.runtime)!=null&&l.id))return!1;const a=Jd();return!(Ke===Ke.top&&/^(?:chrome-extension|moz-extension|ms-browser-extension|safari-web-extension):\/\//.test(a))}function fD(n){return[aA(),eA(),TA(),VN(),AN(),ZN(),lD(),vA(),iD(),YN(),qN()]}function dD(n={}){const t=!n.skipBrowserExtensionCheck&&cD();let a=n.defaultIntegrations==null?fD():n.defaultIntegrations;const r={...n,enabled:t?!1:n.enabled,stackParser:v_(n.stackParser||_N),integrations:_E({integrations:n.integrations,defaultIntegrations:a}),transport:n.transport||cN};return KE(YA,r)}var Rf={exports:{}},le={};/** +Url: ${Tl(n)}`),!0}return!1}function rA(n,t){return t!=null&&t.length?pb(n).some(a=>$l(a,t)):!1}function oA(n,t){if(!(t!=null&&t.length))return!1;const a=n.transaction;return a?$l(a,t):!1}function lA(n,t){if(!(t!=null&&t.length))return!1;const a=Tl(n);return a?$l(a,t):!1}function cA(n,t){if(!(t!=null&&t.length))return!0;const a=Tl(n);return a?$l(a,t):!0}function uA(n=[]){for(let t=n.length-1;t>=0;t--){const a=n[t];if(a&&a.filename!==""&&a.filename!=="[native code]")return a.filename||null}return null}function Tl(n){var t,a;try{const r=[...((t=n.exception)==null?void 0:t.values)??[]].reverse().find(c=>{var f,h,m;return((f=c.mechanism)==null?void 0:f.parent_id)===void 0&&((m=(h=c.stacktrace)==null?void 0:h.frames)==null?void 0:m.length)}),l=(a=r==null?void 0:r.stacktrace)==null?void 0:a.frames;return l?uA(l):null}catch{return ce&&ae.error(`Cannot extract url for event ${Yi(n)}`),null}}function fA(n){var t,a;return(a=(t=n.exception)==null?void 0:t.values)!=null&&a.length?!n.message&&!n.exception.values.some(r=>r.stacktrace||r.type&&r.type!=="Error"||r.value):!1}function dA(n,t,a,r,l,c){var h;if(!((h=l.exception)!=null&&h.values)||!c||!vi(c.originalException,Error))return;const f=l.exception.values.length>0?l.exception.values[l.exception.values.length-1]:void 0;f&&(l.exception.values=hd(n,t,r,c.originalException,a,l.exception.values,f,0))}function hd(n,t,a,r,l,c,f,h){if(c.length>=a+1)return c;let m=[...c];if(vi(r[l],Error)){O0(f,h,r);const p=n(t,r[l]),v=m.length;R0(p,l,v,h),m=hd(n,t,a,r[l],l,[p,...m],p,v)}return Sb(r)&&r.errors.forEach((p,v)=>{if(vi(p,Error)){O0(f,h,r);const x=n(t,p),S=m.length;R0(x,`errors[${v}]`,S,h),m=hd(n,t,a,p,l,[x,...m],x,S)}}),m}function Sb(n){return Array.isArray(n.errors)}function O0(n,t,a){n.mechanism={handled:!0,type:"auto.core.linked_errors",...Sb(a)&&{is_exception_group:!0},...n.mechanism,exception_id:t}}function R0(n,t,a,r){n.mechanism={handled:!0,...n.mechanism,type:"chained",source:t,exception_id:a,parent_id:r}}function hA(n){const t="console";na(t,n),ia(t,mA)}function mA(){"console"in Oe&&d_.forEach(function(n){n in Oe.console&&Ut(Oe.console,n,function(t){return wl[n]=t,function(...a){rn("console",{args:a,level:n});const l=wl[n];l==null||l.apply(Oe.console,a)}})})}function pA(n){return n==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(n)?n:"log"}const gA="Dedupe",yA=(()=>{let n;return{name:gA,processEvent(t){if(t.type)return t;try{if(xA(t,n))return ce&&ae.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return n=t}}}),vA=yA;function xA(n,t){return t?!!(bA(n,t)||SA(n,t)):!1}function bA(n,t){const a=n.message,r=t.message;return!(!a&&!r||a&&!r||!a&&r||a!==r||!_b(n,t)||!wb(n,t))}function SA(n,t){const a=k0(t),r=k0(n);return!(!a||!r||a.type!==r.type||a.value!==r.value||!_b(n,t)||!wb(n,t))}function wb(n,t){let a=Gy(n),r=Gy(t);if(!a&&!r)return!0;if(a&&!r||!a&&r||(a=a,r=r,r.length!==a.length))return!1;for(let l=0;l({name:wA,setup(n){n.on("spanStart",t=>{const a=vn().getScopeData(),r=wi().getScopeData(),l=a.conversationId||r.conversationId;if(l){const{op:c,data:f,description:h}=Zl(t);if(!(c!=null&&c.startsWith("gen_ai."))&&!f["ai.operationId"]&&!(h!=null&&h.startsWith("ai.")))return;t.setAttribute(iT,l)}})}})),TA=_A;function Tb(n){if(n!==void 0)return n>=400&&n<500?"warning":n>=500?"error":void 0}const br=Oe;function EA(){return"history"in br&&!!br.history}function AA(){if(!("fetch"in br))return!1;try{return new Headers,new Request("data:,"),new Response,!0}catch{return!1}}function md(n){return n&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(n.toString())}function NA(){var a;if(typeof EdgeRuntime=="string")return!0;if(!AA())return!1;if(md(br.fetch))return!0;let n=!1;const t=br.document;if(t&&typeof t.createElement=="function")try{const r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),(a=r.contentWindow)!=null&&a.fetch&&(n=md(r.contentWindow.fetch)),t.head.removeChild(r)}catch(r){ce&&ae.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return n}function DA(n,t){const a="fetch";na(a,n),ia(a,()=>CA(void 0,t))}function CA(n,t=!1){t&&!NA()||Ut(Oe,"fetch",function(a){return function(...r){const l=new Error,{method:c,url:f}=jA(r),h={args:r,fetchData:{method:c,url:f},startTimestamp:Pn()*1e3,virtualError:l,headers:MA(r)};return rn("fetch",{...h}),a.apply(Oe,r).then(async m=>(rn("fetch",{...h,endTimestamp:Pn()*1e3,response:m}),m),m=>{rn("fetch",{...h,endTimestamp:Pn()*1e3,error:m}),Fl(m)&&m.stack===void 0&&(m.stack=l.stack,xi(m,"framesToPop",1));const p=gt(),v=(p==null?void 0:p.getOptions().enhanceFetchErrorMessages)??"always";if(v!==!1&&m instanceof TypeError&&(m.message==="Failed to fetch"||m.message==="Load failed"||m.message==="NetworkError when attempting to fetch resource."))try{const w=new URL(h.fetchData.url).host;v==="always"?m.message=`${m.message} (${w})`:xi(m,"__sentry_fetch_url_host__",w)}catch{}throw m})}})}function fl(n,t){return!!n&&typeof n=="object"&&!!n[t]}function L0(n){return typeof n=="string"?n:n?fl(n,"url")?n.url:n.toString?n.toString():"":""}function jA(n){if(n.length===0)return{method:"GET",url:""};if(n.length===2){const[a,r]=n;return{url:L0(a),method:fl(r,"method")?String(r.method).toUpperCase():Px(a)&&fl(a,"method")?String(a.method).toUpperCase():"GET"}}const t=n[0];return{url:L0(t),method:fl(t,"method")?String(t.method).toUpperCase():"GET"}}function MA(n){const[t,a]=n;try{if(typeof a=="object"&&a!==null&&"headers"in a&&a.headers)return new Headers(a.headers);if(Px(t))return new Headers(t.headers)}catch{}}function OA(){return"npm"}const Ke=Oe;let pd=0;function Eb(){return pd>0}function RA(){pd++,setTimeout(()=>{pd--})}function ts(n,t={}){function a(l){return typeof l=="function"}if(!a(n))return n;try{const l=n.__sentry_wrapped__;if(l)return typeof l=="function"?l:n;if(eh(n))return n}catch{return n}const r=function(...l){try{const c=l.map(f=>ts(f,t));return n.apply(this,c)}catch(c){throw RA(),Z_(f=>{f.addEventProcessor(h=>(t.mechanism&&(sd(h,void 0),Wa(h,t.mechanism)),h.extra={...h.extra,arguments:l},h)),Ji(c)}),c}};try{for(const l in n)Object.prototype.hasOwnProperty.call(n,l)&&(r[l]=n[l])}catch{}Ix(r,n),xi(n,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return n.name}})}catch{}return r}function kA(){const n=Jd(),{referrer:t}=Ke.document||{},{userAgent:a}=Ke.navigator||{},r={...t&&{Referer:t},...a&&{"User-Agent":a}};return{url:n,headers:r}}function rh(n,t){const a=oh(n,t),r={type:UA(t),value:PA(t)};return a.length&&(r.stacktrace={frames:a}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function LA(n,t,a,r){const l=gt(),c=l==null?void 0:l.getOptions().normalizeDepth,f=GA(t),h={__serialized__:tb(t,c)};if(f)return{exception:{values:[rh(n,f)]},extra:h};const m={exception:{values:[{type:Yl(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:qA(t,{isUnhandledRejection:r})}]},extra:h};if(a){const p=oh(n,a);p.length&&(m.exception.values[0].stacktrace={frames:p})}return m}function Of(n,t){return{exception:{values:[rh(n,t)]}}}function oh(n,t){const a=t.stacktrace||t.stack||"",r=VA(t),l=BA(t);try{return n(a,r,l)}catch{}return[]}const zA=/Minified React error #\d+;/i;function VA(n){return n&&zA.test(n.message)?1:0}function BA(n){return typeof n.framesToPop=="number"?n.framesToPop:0}function Ab(n){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?n instanceof WebAssembly.Exception:!1}function UA(n){const t=n==null?void 0:n.name;return!t&&Ab(n)?n.message&&Array.isArray(n.message)&&n.message.length==2?n.message[0]:"WebAssembly.Exception":t}function PA(n){const t=n==null?void 0:n.message;return Ab(n)?Array.isArray(n.message)&&n.message.length==2?n.message[1]:"wasm exception":t?t.error&&typeof t.error.message=="string"?D0(t.error):D0(n):"No error message"}function HA(n,t,a,r){const l=(a==null?void 0:a.syntheticException)||void 0,c=lh(n,t,l,r);return Wa(c),c.level="error",a!=null&&a.event_id&&(c.event_id=a.event_id),jr(c)}function IA(n,t,a="info",r,l){const c=(r==null?void 0:r.syntheticException)||void 0,f=gd(n,t,c,l);return f.level=a,r!=null&&r.event_id&&(f.event_id=r.event_id),jr(f)}function lh(n,t,a,r,l){let c;if(Bx(t)&&t.error)return Of(n,t.error);if(Ky(t)||E_(t)){const f=t;if("stack"in t)c=Of(n,t);else{const h=f.name||(Ky(f)?"DOMError":"DOMException"),m=f.message?`${h}: ${f.message}`:h;c=gd(n,m,a,r),sd(c,m)}return"code"in f&&(c.tags={...c.tags,"DOMException.code":`${f.code}`}),c}return Fl(t)?Of(n,t):vr(t)||Yl(t)?(c=LA(n,t,a,l),Wa(c,{synthetic:!0}),c):(c=gd(n,t,a,r),sd(c,`${t}`),Wa(c,{synthetic:!0}),c)}function gd(n,t,a,r){const l={};if(r&&a){const c=oh(n,a);c.length&&(l.exception={values:[{value:t,stacktrace:{frames:c}}]}),Wa(l,{synthetic:!0})}if(Qd(t)){const{__sentry_template_string__:c,__sentry_template_values__:f}=t;return l.logentry={message:c,params:f},l}return l.message=t,l}function qA(n,{isUnhandledRejection:t}){const a=O_(n),r=t?"promise rejection":"exception";return Bx(n)?`Event \`ErrorEvent\` captured as ${r} with message \`${n.message}\``:Yl(n)?`Event \`${FA(n)}\` (type=${n.type}) captured as ${r}`:`Object captured as ${r} with keys: ${a}`}function FA(n){try{const t=Object.getPrototypeOf(n);return t?t.constructor.name:void 0}catch{}}function GA(n){return Object.values(n).find(t=>t instanceof Error)}class YA extends HE{constructor(t){var v;const a=KA(t),r=Ke.SENTRY_SDK_SOURCE||OA();bb(a,"browser",["browser"],r),(v=a._metadata)!=null&&v.sdk&&(a._metadata.sdk.settings={infer_ip:a.sendDefaultPii?"auto":"never",...a._metadata.sdk.settings}),super(a);const{sendDefaultPii:l,sendClientReports:c,enableLogs:f,_experiments:h,enableMetrics:m}=this._options,p=m??(h==null?void 0:h.enableMetrics)??!0;Ke.document&&(c||f||p)&&Ke.document.addEventListener("visibilitychange",()=>{Ke.document.visibilityState==="hidden"&&(c&&this._flushOutcomes(),f&&fd(this),p&&fb(this))}),l&&this.on("beforeSendSession",ZE)}eventFromException(t,a){return HA(this._options.stackParser,t,a,this._options.attachStacktrace)}eventFromMessage(t,a="info",r){return IA(this._options.stackParser,t,a,r,this._options.attachStacktrace)}_prepareEvent(t,a,r,l){return t.platform=t.platform||"javascript",super._prepareEvent(t,a,r,l)}}function KA(n){var t;return{release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:(t=Ke.SENTRY_RELEASE)==null?void 0:t.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...n}}const XA=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,xt=Oe,$A=1e3;let z0,yd,vd;function ZA(n){na("dom",n),ia("dom",QA)}function QA(){if(!xt.document)return;const n=rn.bind(null,"dom"),t=V0(n,!0);xt.document.addEventListener("click",t,!1),xt.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(a=>{var c,f;const l=(c=xt[a])==null?void 0:c.prototype;(f=l==null?void 0:l.hasOwnProperty)!=null&&f.call(l,"addEventListener")&&(Ut(l,"addEventListener",function(h){return function(m,p,v){if(m==="click"||m=="keypress")try{const x=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},S=x[m]=x[m]||{refCount:0};if(!S.handler){const w=V0(n);S.handler=w,h.call(this,m,w,v)}S.refCount++}catch{}return h.call(this,m,p,v)}}),Ut(l,"removeEventListener",function(h){return function(m,p,v){if(m==="click"||m=="keypress")try{const x=this.__sentry_instrumentation_handlers__||{},S=x[m];S&&(S.refCount--,S.refCount<=0&&(h.call(this,m,S.handler,v),S.handler=void 0,delete x[m]),Object.keys(x).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return h.call(this,m,p,v)}}))})}function WA(n){if(n.type!==yd)return!1;try{if(!n.target||n.target._sentryId!==vd)return!1}catch{}return!0}function JA(n,t){return n!=="keypress"?!1:t!=null&&t.tagName?!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable):!0}function V0(n,t=!1){return a=>{if(!a||a._sentryCaptured)return;const r=eN(a);if(JA(a.type,r))return;xi(a,"_sentryCaptured",!0),r&&!r._sentryId&&xi(r,"_sentryId",Wt());const l=a.type==="keypress"?"input":a.type;WA(a)||(n({event:a,name:l,global:t}),yd=a.type,vd=r?r._sentryId:void 0),clearTimeout(z0),z0=xt.setTimeout(()=>{vd=void 0,yd=void 0},$A)}}function eN(n){try{return n.target}catch{return null}}let tl;function Nb(n){const t="history";na(t,n),ia(t,tN)}function tN(){if(xt.addEventListener("popstate",()=>{const t=xt.location.href,a=tl;if(tl=t,a===t)return;rn("history",{from:a,to:t})}),!EA())return;function n(t){return function(...a){const r=a.length>2?a[2]:void 0;if(r){const l=tl,c=nN(String(r));if(tl=c,l===c)return t.apply(this,a);rn("history",{from:l,to:c})}return t.apply(this,a)}}Ut(xt.history,"pushState",n),Ut(xt.history,"replaceState",n)}function nN(n){try{return new URL(n,xt.location.origin).toString()}catch{return n}}const dl={};function iN(n){const t=dl[n];if(t)return t;let a=xt[n];if(md(a))return dl[n]=a.bind(xt);const r=xt.document;if(r&&typeof r.createElement=="function")try{const l=r.createElement("iframe");l.hidden=!0,r.head.appendChild(l);const c=l.contentWindow;c!=null&&c[n]&&(a=c[n]),r.head.removeChild(l)}catch(l){XA&&ae.warn(`Could not create sandbox iframe for ${n} check, bailing to window.${n}: `,l)}return a&&(dl[n]=a.bind(xt))}function aN(n){dl[n]=void 0}const ur="__sentry_xhr_v3__";function sN(n){na("xhr",n),ia("xhr",rN)}function rN(){if(!xt.XMLHttpRequest)return;const n=XMLHttpRequest.prototype;n.open=new Proxy(n.open,{apply(t,a,r){const l=new Error,c=Pn()*1e3,f=Un(r[0])?r[0].toUpperCase():void 0,h=oN(r[1]);if(!f||!h)return t.apply(a,r);a[ur]={method:f,url:h,request_headers:{}},f==="POST"&&h.match(/sentry_key/)&&(a.__sentry_own_request__=!0);const m=()=>{const p=a[ur];if(p&&a.readyState===4){try{p.status_code=a.status}catch{}const v={endTimestamp:Pn()*1e3,startTimestamp:c,xhr:a,virtualError:l};rn("xhr",v)}};return"onreadystatechange"in a&&typeof a.onreadystatechange=="function"?a.onreadystatechange=new Proxy(a.onreadystatechange,{apply(p,v,x){return m(),p.apply(v,x)}}):a.addEventListener("readystatechange",m),a.setRequestHeader=new Proxy(a.setRequestHeader,{apply(p,v,x){const[S,w]=x,T=v[ur];return T&&Un(S)&&Un(w)&&(T.request_headers[S.toLowerCase()]=w),p.apply(v,x)}}),t.apply(a,r)}}),n.send=new Proxy(n.send,{apply(t,a,r){const l=a[ur];if(!l)return t.apply(a,r);r[0]!==void 0&&(l.body=r[0]);const c={startTimestamp:Pn()*1e3,xhr:a};return rn("xhr",c),t.apply(a,r)}})}function oN(n){if(Un(n))return n;try{return n.toString()}catch{}}const lN=40;function cN(n,t=iN("fetch")){let a=0,r=0;async function l(c){const f=c.body.length;a+=f,r++;const h={body:c.body,method:"POST",referrerPolicy:"strict-origin",headers:n.headers,keepalive:a<=6e4&&r<15,...n.fetchOptions};try{const m=await t(n.url,h);return{statusCode:m.status,headers:{"x-sentry-rate-limits":m.headers.get("X-Sentry-Rate-Limits"),"retry-after":m.headers.get("Retry-After")}}}catch(m){throw aN("fetch"),m}finally{a-=f,r--}}return zE(n,l,sh(n.bufferSize||lN))}const Ql=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,uN=30,fN=50;function xd(n,t,a,r){const l={filename:n,function:t===""?Wi:t,in_app:!0};return a!==void 0&&(l.lineno=a),r!==void 0&&(l.colno=r),l}const dN=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,hN=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,mN=/\((\S*)(?::(\d+))(?::(\d+))\)/,pN=/at (.+?) ?\(data:(.+?),/,gN=n=>{var l;const t=n.match(pN);if(t)return{filename:``,function:t[1]};const a=dN.exec(n);if(a){const[,c,f,h]=a;return xd(c,Wi,+f,+h)}const r=hN.exec(n);if(r){if(((l=r[2])==null?void 0:l.indexOf("eval"))===0){const m=mN.exec(r[2]);m&&(r[2]=m[1],r[3]=m[2],r[4]=m[3])}const[f,h]=Db(r[1]||Wi,r[2]);return xd(h,f,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}},yN=[uN,gN],vN=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,xN=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,bN=n=>{const t=vN.exec(n);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const c=xN.exec(t[3]);c&&(t[1]=t[1]||"eval",t[3]=c[1],t[4]=c[2],t[5]="")}let r=t[3],l=t[1]||Wi;return[l,r]=Db(l,r),xd(r,l,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},SN=[fN,bN],wN=[yN,SN],_N=Lx(...wN),Db=(n,t)=>{const a=n.indexOf("safari-extension")!==-1,r=n.indexOf("safari-web-extension")!==-1;return a||r?[n.indexOf("@")!==-1?n.split("@")[0]:Wi,a?`safari-extension:${t}`:`safari-web-extension:${t}`]:[n,t]},nl=1024,TN="Breadcrumbs",EN=((n={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...n};return{name:TN,setup(a){t.console&&hA(CN(a)),t.dom&&ZA(DN(a,t.dom)),t.xhr&&sN(jN(a)),t.fetch&&DA(MN(a)),t.history&&Nb(ON(a)),t.sentry&&a.on("beforeSendEvent",NN(a))}}}),AN=EN;function NN(n){return function(a){gt()===n&&ea({category:`sentry.${a.type==="transaction"?"transaction":"event"}`,event_id:a.event_id,level:a.level,message:Yi(a)},{event:a})}}function DN(n,t){return function(r){if(gt()!==n)return;let l,c,f=typeof t=="object"?t.serializeAttribute:void 0,h=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;h&&h>nl&&(Ql&&ae.warn(`\`dom.maxStringLength\` cannot exceed ${nl}, but a value of ${h} was configured. Sentry will use ${nl} instead.`),h=nl),typeof f=="string"&&(f=[f]);try{const p=r.event,v=RN(p)?p.target:p;l=Hx(v,{keyAttrs:f,maxStringLength:h}),c=M_(v)}catch{l=""}if(l.length===0)return;const m={category:`ui.${r.name}`,message:l};c&&(m.data={"ui.component_name":c}),ea(m,{event:r.event,name:r.name,global:r.global})}}function CN(n){return function(a){if(gt()!==n)return;const r={category:"console",data:{arguments:a.args,logger:"console"},level:pA(a.level),message:Zy(a.args," ")};if(a.level==="assert")if(a.args[0]===!1)r.message=`Assertion failed: ${Zy(a.args.slice(1)," ")||"console.assert"}`,r.data.arguments=a.args.slice(1);else return;ea(r,{input:a.args,level:a.level})}}function jN(n){return function(a){if(gt()!==n)return;const{startTimestamp:r,endTimestamp:l}=a,c=a.xhr[ur];if(!r||!l||!c)return;const{method:f,url:h,status_code:m,body:p}=c,v={method:f,url:h,status_code:m},x={xhr:a.xhr,input:p,startTimestamp:r,endTimestamp:l},S={category:"xhr",data:v,type:"http",level:Tb(m)};n.emit("beforeOutgoingRequestBreadcrumb",S,x),ea(S,x)}}function MN(n){return function(a){if(gt()!==n)return;const{startTimestamp:r,endTimestamp:l}=a;if(l&&!(a.fetchData.url.match(/sentry_key/)&&a.fetchData.method==="POST"))if(a.error){const c={data:a.error,input:a.args,startTimestamp:r,endTimestamp:l},f={category:"fetch",data:a.fetchData,level:"error",type:"http"};n.emit("beforeOutgoingRequestBreadcrumb",f,c),ea(f,c)}else{const c=a.response,f={...a.fetchData,status_code:c==null?void 0:c.status},h={input:a.args,response:c,startTimestamp:r,endTimestamp:l},m={category:"fetch",data:f,type:"http",level:Tb(f.status_code)};n.emit("beforeOutgoingRequestBreadcrumb",m,h),ea(m,h)}}}function ON(n){return function(a){if(gt()!==n)return;let r=a.from,l=a.to;const c=Mf(Ke.location.href);let f=r?Mf(r):void 0;const h=Mf(l);f!=null&&f.path||(f=c),c.protocol===h.protocol&&c.host===h.host&&(l=h.relative),c.protocol===f.protocol&&c.host===f.host&&(r=f.relative),ea({category:"navigation",data:{from:r,to:l}})}}function RN(n){return!!n&&!!n.target}const kN="EventTarget,Window,Node,ApplicationCache,AudioTrackList,BroadcastChannel,ChannelMergerNode,CryptoOperation,EventSource,FileReader,HTMLUnknownElement,IDBDatabase,IDBRequest,IDBTransaction,KeyOperation,MediaController,MessagePort,ModalWindow,Notification,SVGElementInstance,Screen,SharedWorker,TextTrack,TextTrackCue,TextTrackList,WebSocket,WebSocketWorker,Worker,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload".split(","),LN="BrowserApiErrors",zN=((n={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...n};return{name:LN,setupOnce(){t.setTimeout&&Ut(Ke,"setTimeout",B0),t.setInterval&&Ut(Ke,"setInterval",B0),t.requestAnimationFrame&&Ut(Ke,"requestAnimationFrame",BN),t.XMLHttpRequest&&"XMLHttpRequest"in Ke&&Ut(XMLHttpRequest.prototype,"send",UN);const a=t.eventTarget;a&&(Array.isArray(a)?a:kN).forEach(l=>PN(l,t))}}}),VN=zN;function B0(n){return function(...t){const a=t[0];return t[0]=ts(a,{mechanism:{handled:!1,type:`auto.browser.browserapierrors.${yi(n)}`}}),n.apply(this,t)}}function BN(n){return function(t){return n.apply(this,[ts(t,{mechanism:{data:{handler:yi(n)},handled:!1,type:"auto.browser.browserapierrors.requestAnimationFrame"}})])}}function UN(n){return function(...t){const a=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(l=>{l in a&&typeof a[l]=="function"&&Ut(a,l,function(c){const f={mechanism:{data:{handler:yi(c)},handled:!1,type:`auto.browser.browserapierrors.xhr.${l}`}},h=eh(c);return h&&(f.mechanism.data.handler=yi(h)),ts(c,f)})}),n.apply(this,t)}}function PN(n,t){var l,c;const r=(l=Ke[n])==null?void 0:l.prototype;(c=r==null?void 0:r.hasOwnProperty)!=null&&c.call(r,"addEventListener")&&(Ut(r,"addEventListener",function(f){return function(h,m,p){try{HN(m)&&(m.handleEvent=ts(m.handleEvent,{mechanism:{data:{handler:yi(m),target:n},handled:!1,type:"auto.browser.browserapierrors.handleEvent"}}))}catch{}return t.unregisterOriginalCallbacks&&IN(this,h,m),f.apply(this,[h,ts(m,{mechanism:{data:{handler:yi(m),target:n},handled:!1,type:"auto.browser.browserapierrors.addEventListener"}}),p])}}),Ut(r,"removeEventListener",function(f){return function(h,m,p){try{const v=m.__sentry_wrapped__;v&&f.call(this,h,v,p)}catch{}return f.call(this,h,m,p)}}))}function HN(n){return typeof n.handleEvent=="function"}function IN(n,t,a){n&&typeof n=="object"&&"removeEventListener"in n&&typeof n.removeEventListener=="function"&&n.removeEventListener(t,a)}const qN=(n={})=>{const t=n.lifecycle??"route";return{name:"BrowserSession",setupOnce(){if(typeof Ke.document>"u"){Ql&&ae.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}v0({ignoreDuration:!0}),Cf();const a=wi();let r=a.getUser();a.addScopeListener(l=>{const c=l.getUser();((r==null?void 0:r.id)!==(c==null?void 0:c.id)||(r==null?void 0:r.ip_address)!==(c==null?void 0:c.ip_address))&&(Cf(),r=c)}),t==="route"&&Nb(({from:l,to:c})=>{l!==c&&(v0({ignoreDuration:!0}),Cf())})}}},FN="CultureContext",GN=(()=>({name:FN,preprocessEvent(n){var a;const t=KN();t&&(n.contexts={...n.contexts,culture:{...t,...(a=n.contexts)==null?void 0:a.culture}})}})),YN=GN;function KN(){try{const n=Ke.Intl;if(!n)return;const t=n.DateTimeFormat().resolvedOptions();return{locale:t.locale,timezone:t.timeZone,calendar:t.calendar}}catch{return}}const XN="GlobalHandlers",$N=((n={})=>{const t={onerror:!0,onunhandledrejection:!0,...n};return{name:XN,setupOnce(){Error.stackTraceLimit=50},setup(a){t.onerror&&(QN(a),U0("onerror")),t.onunhandledrejection&&(WN(a),U0("onunhandledrejection"))}}}),ZN=$N;function QN(n){S_(t=>{const{stackParser:a,attachStacktrace:r}=Cb();if(gt()!==n||Eb())return;const{msg:l,url:c,line:f,column:h,error:m}=t,p=tD(lh(a,m||l,void 0,r,!1),c,f,h);p.level="error",rb(p,{originalException:m,mechanism:{handled:!1,type:"auto.browser.global_handlers.onerror"}})})}function WN(n){__(t=>{const{stackParser:a,attachStacktrace:r}=Cb();if(gt()!==n||Eb())return;const l=JN(t),c=Gl(l)?eD(l):lh(a,l,void 0,r,!0);c.level="error",rb(c,{originalException:l,mechanism:{handled:!1,type:"auto.browser.global_handlers.onunhandledrejection"}})})}function JN(n){if(Gl(n))return n;try{if("reason"in n)return n.reason;if("detail"in n&&"reason"in n.detail)return n.detail.reason}catch{}return n}function eD(n){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(n)}`}]}}}function tD(n,t,a,r){const l=n.exception=n.exception||{},c=l.values=l.values||[],f=c[0]=c[0]||{},h=f.stacktrace=f.stacktrace||{},m=h.frames=h.frames||[];return m.length===0&&m.push({colno:r,lineno:a,filename:nD(t)??Jd(),function:Wi,in_app:!0}),n}function U0(n){Ql&&ae.log(`Global Handler attached: ${n}`)}function Cb(){const n=gt();return(n==null?void 0:n.getOptions())||{stackParser:()=>[],attachStacktrace:!1}}function nD(n){if(!(!Un(n)||n.length===0))return n.startsWith("data:")?`<${$E(n,!1)}>`:n}const iD=()=>({name:"HttpContext",preprocessEvent(n){var r;if(!Ke.navigator&&!Ke.location&&!Ke.document)return;const t=kA(),a={...t.headers,...(r=n.request)==null?void 0:r.headers};n.request={...t,...n.request,headers:a}}}),aD="cause",sD=5,rD="LinkedErrors",oD=((n={})=>{const t=n.limit||sD,a=n.key||aD;return{name:rD,preprocessEvent(r,l,c){const f=c.getOptions();dA(rh,f.stackParser,a,t,r,l)}}}),lD=oD;function cD(){return uD()?(Ql&&ss(()=>{console.error("[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}),!0):!1}function uD(){var l;if(typeof Ke.window>"u")return!1;const n=Ke;if(n.nw)return!1;const t=n.chrome||n.browser;if(!((l=t==null?void 0:t.runtime)!=null&&l.id))return!1;const a=Jd();return!(Ke===Ke.top&&/^(?:chrome-extension|moz-extension|ms-browser-extension|safari-web-extension):\/\//.test(a))}function fD(n){return[aA(),eA(),TA(),VN(),AN(),ZN(),lD(),vA(),iD(),YN(),qN()]}function dD(n={}){const t=!n.skipBrowserExtensionCheck&&cD();let a=n.defaultIntegrations==null?fD():n.defaultIntegrations;const r={...n,enabled:t?!1:n.enabled,stackParser:x_(n.stackParser||_N),integrations:_E({integrations:n.integrations,defaultIntegrations:a}),transport:n.transport||cN};return KE(YA,r)}var Rf={exports:{}},le={};/** * @license React * react.production.js * @@ -28,7 +28,7 @@ Url: ${Tl(n)}`),!0}return!1}function rA(n,t){return t!=null&&t.length?mb(n).some * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var P0;function hD(){if(P0)return le;P0=1;var n=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),l=Symbol.for("react.profiler"),c=Symbol.for("react.consumer"),f=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),v=Symbol.for("react.lazy"),x=Symbol.for("react.activity"),S=Symbol.iterator;function w(A){return A===null||typeof A!="object"?null:(A=S&&A[S]||A["@@iterator"],typeof A=="function"?A:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},k=Object.assign,z={};function B(A,V,G){this.props=A,this.context=V,this.refs=z,this.updater=G||T}B.prototype.isReactComponent={},B.prototype.setState=function(A,V){if(typeof A!="object"&&typeof A!="function"&&A!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,A,V,"setState")},B.prototype.forceUpdate=function(A){this.updater.enqueueForceUpdate(this,A,"forceUpdate")};function I(){}I.prototype=B.prototype;function H(A,V,G){this.props=A,this.context=V,this.refs=z,this.updater=G||T}var F=H.prototype=new I;F.constructor=H,k(F,B.prototype),F.isPureReactComponent=!0;var $=Array.isArray;function he(){}var J={H:null,A:null,T:null,S:null},te=Object.prototype.hasOwnProperty;function ue(A,V,G){var Z=G.ref;return{$$typeof:n,type:A,key:V,ref:Z!==void 0?Z:null,props:G}}function X(A,V){return ue(A.type,V,A.props)}function we(A){return typeof A=="object"&&A!==null&&A.$$typeof===n}function Ae(A){var V={"=":"=0",":":"=2"};return"$"+A.replace(/[=:]/g,function(G){return V[G]})}var De=/\/+/g;function _e(A,V){return typeof A=="object"&&A!==null&&A.key!=null?Ae(""+A.key):V.toString(36)}function He(A){switch(A.status){case"fulfilled":return A.value;case"rejected":throw A.reason;default:switch(typeof A.status=="string"?A.then(he,he):(A.status="pending",A.then(function(V){A.status==="pending"&&(A.status="fulfilled",A.value=V)},function(V){A.status==="pending"&&(A.status="rejected",A.reason=V)})),A.status){case"fulfilled":return A.value;case"rejected":throw A.reason}}throw A}function O(A,V,G,Z,oe){var pe=typeof A;(pe==="undefined"||pe==="boolean")&&(A=null);var Ce=!1;if(A===null)Ce=!0;else switch(pe){case"bigint":case"string":case"number":Ce=!0;break;case"object":switch(A.$$typeof){case n:case t:Ce=!0;break;case v:return Ce=A._init,O(Ce(A._payload),V,G,Z,oe)}}if(Ce)return oe=oe(A),Ce=Z===""?"."+_e(A,0):Z,$(oe)?(G="",Ce!=null&&(G=Ce.replace(De,"$&/")+"/"),O(oe,V,G,"",function(fs){return fs})):oe!=null&&(we(oe)&&(oe=X(oe,G+(oe.key==null||A&&A.key===oe.key?"":(""+oe.key).replace(De,"$&/")+"/")+Ce)),V.push(oe)),1;Ce=0;var yt=Z===""?".":Z+":";if($(A))for(var Xe=0;Xeu||E[o]!==j[u]){var L=` -`+E[o].replace(" at new "," at ");return e.displayName&&L.includes("")&&(L=L.replace("",e.displayName)),L}while(1<=o&&0<=u);break}}}finally{sc=!1,Error.prepareStackTrace=s}return(s=e?e.displayName||e.name:"")?Ti(s):""}function PS(e,i){switch(e.tag){case 26:case 27:case 5:return Ti(e.type);case 16:return Ti("Lazy");case 13:return e.child!==i&&i!==null?Ti("Suspense Fallback"):Ti("Suspense");case 19:return Ti("SuspenseList");case 0:case 15:return rc(e.type,!1);case 11:return rc(e.type.render,!1);case 1:return rc(e.type,!0);case 31:return Ti("Activity");default:return""}}function Hh(e){try{var i="",s=null;do i+=PS(e,s),s=e,e=e.return;while(e);return i}catch(o){return` +`+E[o].replace(" at new "," at ");return e.displayName&&L.includes("")&&(L=L.replace("",e.displayName)),L}while(1<=o&&0<=u);break}}}finally{sc=!1,Error.prepareStackTrace=s}return(s=e?e.displayName||e.name:"")?Ti(s):""}function HS(e,i){switch(e.tag){case 26:case 27:case 5:return Ti(e.type);case 16:return Ti("Lazy");case 13:return e.child!==i&&i!==null?Ti("Suspense Fallback"):Ti("Suspense");case 19:return Ti("SuspenseList");case 0:case 15:return rc(e.type,!1);case 11:return rc(e.type.render,!1);case 1:return rc(e.type,!0);case 31:return Ti("Activity");default:return""}}function Hh(e){try{var i="",s=null;do i+=HS(e,s),s=e,e=e.return;while(e);return i}catch(o){return` Error generating stack: `+o.message+` -`+o.stack}}var oc=Object.prototype.hasOwnProperty,lc=n.unstable_scheduleCallback,cc=n.unstable_cancelCallback,HS=n.unstable_shouldYield,IS=n.unstable_requestPaint,Ct=n.unstable_now,qS=n.unstable_getCurrentPriorityLevel,Ih=n.unstable_ImmediatePriority,qh=n.unstable_UserBlockingPriority,zr=n.unstable_NormalPriority,FS=n.unstable_LowPriority,Fh=n.unstable_IdlePriority,GS=n.log,YS=n.unstable_setDisableYieldValue,ds=null,jt=null;function In(e){if(typeof GS=="function"&&YS(e),jt&&typeof jt.setStrictMode=="function")try{jt.setStrictMode(ds,e)}catch{}}var Mt=Math.clz32?Math.clz32:$S,KS=Math.log,XS=Math.LN2;function $S(e){return e>>>=0,e===0?32:31-(KS(e)/XS|0)|0}var Vr=256,Br=262144,Ur=4194304;function Ei(e){var i=e&42;if(i!==0)return i;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Pr(e,i,s){var o=e.pendingLanes;if(o===0)return 0;var u=0,d=e.suspendedLanes,y=e.pingedLanes;e=e.warmLanes;var b=o&134217727;return b!==0?(o=b&~d,o!==0?u=Ei(o):(y&=b,y!==0?u=Ei(y):s||(s=b&~e,s!==0&&(u=Ei(s))))):(b=o&~d,b!==0?u=Ei(b):y!==0?u=Ei(y):s||(s=o&~e,s!==0&&(u=Ei(s)))),u===0?0:i!==0&&i!==u&&(i&d)===0&&(d=u&-u,s=i&-i,d>=s||d===32&&(s&4194048)!==0)?i:u}function hs(e,i){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&i)===0}function ZS(e,i){switch(e){case 1:case 2:case 4:case 8:case 64:return i+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return i+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Gh(){var e=Ur;return Ur<<=1,(Ur&62914560)===0&&(Ur=4194304),e}function uc(e){for(var i=[],s=0;31>s;s++)i.push(e);return i}function ms(e,i){e.pendingLanes|=i,i!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function QS(e,i,s,o,u,d){var y=e.pendingLanes;e.pendingLanes=s,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=s,e.entangledLanes&=s,e.errorRecoveryDisabledLanes&=s,e.shellSuspendCounter=0;var b=e.entanglements,E=e.expirationTimes,j=e.hiddenUpdates;for(s=y&~s;0"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var i2=/[\n"\\]/g;function It(e){return e.replace(i2,function(i){return"\\"+i.charCodeAt(0).toString(16)+" "})}function gc(e,i,s,o,u,d,y,b){e.name="",y!=null&&typeof y!="function"&&typeof y!="symbol"&&typeof y!="boolean"?e.type=y:e.removeAttribute("type"),i!=null?y==="number"?(i===0&&e.value===""||e.value!=i)&&(e.value=""+Ht(i)):e.value!==""+Ht(i)&&(e.value=""+Ht(i)):y!=="submit"&&y!=="reset"||e.removeAttribute("value"),i!=null?yc(e,y,Ht(i)):s!=null?yc(e,y,Ht(s)):o!=null&&e.removeAttribute("value"),u==null&&d!=null&&(e.defaultChecked=!!d),u!=null&&(e.checked=u&&typeof u!="function"&&typeof u!="symbol"),b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.name=""+Ht(b):e.removeAttribute("name")}function am(e,i,s,o,u,d,y,b){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),i!=null||s!=null){if(!(d!=="submit"&&d!=="reset"||i!=null)){pc(e);return}s=s!=null?""+Ht(s):"",i=i!=null?""+Ht(i):s,b||i===e.value||(e.value=i),e.defaultValue=i}o=o??u,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=b?e.checked:!!o,e.defaultChecked=!!o,y!=null&&typeof y!="function"&&typeof y!="symbol"&&typeof y!="boolean"&&(e.name=y),pc(e)}function yc(e,i,s){i==="number"&&qr(e.ownerDocument)===e||e.defaultValue===""+s||(e.defaultValue=""+s)}function ca(e,i,s,o){if(e=e.options,i){i={};for(var u=0;u"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),wc=!1;if(Sn)try{var vs={};Object.defineProperty(vs,"passive",{get:function(){wc=!0}}),window.addEventListener("test",vs,vs),window.removeEventListener("test",vs,vs)}catch{wc=!1}var Fn=null,_c=null,Gr=null;function fm(){if(Gr)return Gr;var e,i=_c,s=i.length,o,u="value"in Fn?Fn.value:Fn.textContent,d=u.length;for(e=0;e=Ss),ym=" ",vm=!1;function xm(e,i){switch(e){case"keyup":return M2.indexOf(i.keyCode)!==-1;case"keydown":return i.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function bm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ha=!1;function R2(e,i){switch(e){case"compositionend":return bm(i);case"keypress":return i.which!==32?null:(vm=!0,ym);case"textInput":return e=i.data,e===ym&&vm?null:e;default:return null}}function k2(e,i){if(ha)return e==="compositionend"||!Dc&&xm(e,i)?(e=fm(),Gr=_c=Fn=null,ha=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(i.ctrlKey||i.altKey||i.metaKey)||i.ctrlKey&&i.altKey){if(i.char&&1=i)return{node:s,offset:i-e};e=o}e:{for(;s;){if(s.nextSibling){s=s.nextSibling;break e}s=s.parentNode}s=void 0}s=Dm(s)}}function jm(e,i){return e&&i?e===i?!0:e&&e.nodeType===3?!1:i&&i.nodeType===3?jm(e,i.parentNode):"contains"in e?e.contains(i):e.compareDocumentPosition?!!(e.compareDocumentPosition(i)&16):!1:!1}function Mm(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var i=qr(e.document);i instanceof e.HTMLIFrameElement;){try{var s=typeof i.contentWindow.location.href=="string"}catch{s=!1}if(s)e=i.contentWindow;else break;i=qr(e.document)}return i}function Mc(e){var i=e&&e.nodeName&&e.nodeName.toLowerCase();return i&&(i==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||i==="textarea"||e.contentEditable==="true")}var I2=Sn&&"documentMode"in document&&11>=document.documentMode,ma=null,Oc=null,Es=null,Rc=!1;function Om(e,i,s){var o=s.window===s?s.document:s.nodeType===9?s:s.ownerDocument;Rc||ma==null||ma!==qr(o)||(o=ma,"selectionStart"in o&&Mc(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),Es&&Ts(Es,o)||(Es=o,o=Uo(Oc,"onSelect"),0>=y,u-=y,ln=1<<32-Mt(i)+u|s<de?(xe=ee,ee=null):xe=ee.sibling;var Ee=M(D,ee,C[de],U);if(Ee===null){ee===null&&(ee=xe);break}e&&ee&&Ee.alternate===null&&i(D,ee),N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee,ee=xe}if(de===C.length)return s(D,ee),be&&_n(D,de),ne;if(ee===null){for(;dede?(xe=ee,ee=null):xe=ee.sibling;var di=M(D,ee,Ee.value,U);if(di===null){ee===null&&(ee=xe);break}e&&ee&&di.alternate===null&&i(D,ee),N=d(di,N,de),Te===null?ne=di:Te.sibling=di,Te=di,ee=xe}if(Ee.done)return s(D,ee),be&&_n(D,de),ne;if(ee===null){for(;!Ee.done;de++,Ee=C.next())Ee=P(D,Ee.value,U),Ee!==null&&(N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee);return be&&_n(D,de),ne}for(ee=o(ee);!Ee.done;de++,Ee=C.next())Ee=R(ee,D,de,Ee.value,U),Ee!==null&&(e&&Ee.alternate!==null&&ee.delete(Ee.key===null?de:Ee.key),N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee);return e&&ee.forEach(function(l_){return i(D,l_)}),be&&_n(D,de),ne}function Le(D,N,C,U){if(typeof C=="object"&&C!==null&&C.type===k&&C.key===null&&(C=C.props.children),typeof C=="object"&&C!==null){switch(C.$$typeof){case w:e:{for(var ne=C.key;N!==null;){if(N.key===ne){if(ne=C.type,ne===k){if(N.tag===7){s(D,N.sibling),U=u(N,C.props.children),U.return=D,D=U;break e}}else if(N.elementType===ne||typeof ne=="object"&&ne!==null&&ne.$$typeof===te&&zi(ne)===N.type){s(D,N.sibling),U=u(N,C.props),Ms(U,C),U.return=D,D=U;break e}s(D,N);break}else i(D,N);N=N.sibling}C.type===k?(U=Mi(C.props.children,D.mode,U,C.key),U.return=D,D=U):(U=to(C.type,C.key,C.props,null,D.mode,U),Ms(U,C),U.return=D,D=U)}return y(D);case T:e:{for(ne=C.key;N!==null;){if(N.key===ne)if(N.tag===4&&N.stateNode.containerInfo===C.containerInfo&&N.stateNode.implementation===C.implementation){s(D,N.sibling),U=u(N,C.children||[]),U.return=D,D=U;break e}else{s(D,N);break}else i(D,N);N=N.sibling}U=Pc(C,D.mode,U),U.return=D,D=U}return y(D);case te:return C=zi(C),Le(D,N,C,U)}if(He(C))return Q(D,N,C,U);if(Ae(C)){if(ne=Ae(C),typeof ne!="function")throw Error(r(150));return C=ne.call(C),ie(D,N,C,U)}if(typeof C.then=="function")return Le(D,N,lo(C),U);if(C.$$typeof===H)return Le(D,N,ao(D,C),U);co(D,C)}return typeof C=="string"&&C!==""||typeof C=="number"||typeof C=="bigint"?(C=""+C,N!==null&&N.tag===6?(s(D,N.sibling),U=u(N,C),U.return=D,D=U):(s(D,N),U=Uc(C,D.mode,U),U.return=D,D=U),y(D)):s(D,N)}return function(D,N,C,U){try{js=0;var ne=Le(D,N,C,U);return Ea=null,ne}catch(ee){if(ee===Ta||ee===ro)throw ee;var Te=Rt(29,ee,null,D.mode);return Te.lanes=U,Te.return=D,Te}finally{}}}var Bi=tp(!0),np=tp(!1),$n=!1;function Wc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Jc(e,i){e=e.updateQueue,i.updateQueue===e&&(i.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Zn(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Qn(e,i,s){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(Ne&2)!==0){var u=o.pending;return u===null?i.next=i:(i.next=u.next,u.next=i),o.pending=i,i=eo(e),Um(e,null,s),i}return Jr(e,o,i,s),eo(e)}function Os(e,i,s){if(i=i.updateQueue,i!==null&&(i=i.shared,(s&4194048)!==0)){var o=i.lanes;o&=e.pendingLanes,s|=o,i.lanes=s,Kh(e,s)}}function eu(e,i){var s=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,s===o)){var u=null,d=null;if(s=s.firstBaseUpdate,s!==null){do{var y={lane:s.lane,tag:s.tag,payload:s.payload,callback:null,next:null};d===null?u=d=y:d=d.next=y,s=s.next}while(s!==null);d===null?u=d=i:d=d.next=i}else u=d=i;s={baseState:o.baseState,firstBaseUpdate:u,lastBaseUpdate:d,shared:o.shared,callbacks:o.callbacks},e.updateQueue=s;return}e=s.lastBaseUpdate,e===null?s.firstBaseUpdate=i:e.next=i,s.lastBaseUpdate=i}var tu=!1;function Rs(){if(tu){var e=_a;if(e!==null)throw e}}function ks(e,i,s,o){tu=!1;var u=e.updateQueue;$n=!1;var d=u.firstBaseUpdate,y=u.lastBaseUpdate,b=u.shared.pending;if(b!==null){u.shared.pending=null;var E=b,j=E.next;E.next=null,y===null?d=j:y.next=j,y=E;var L=e.alternate;L!==null&&(L=L.updateQueue,b=L.lastBaseUpdate,b!==y&&(b===null?L.firstBaseUpdate=j:b.next=j,L.lastBaseUpdate=E))}if(d!==null){var P=u.baseState;y=0,L=j=E=null,b=d;do{var M=b.lane&-536870913,R=M!==b.lane;if(R?(ve&M)===M:(o&M)===M){M!==0&&M===wa&&(tu=!0),L!==null&&(L=L.next={lane:0,tag:b.tag,payload:b.payload,callback:null,next:null});e:{var Q=e,ie=b;M=i;var Le=s;switch(ie.tag){case 1:if(Q=ie.payload,typeof Q=="function"){P=Q.call(Le,P,M);break e}P=Q;break e;case 3:Q.flags=Q.flags&-65537|128;case 0:if(Q=ie.payload,M=typeof Q=="function"?Q.call(Le,P,M):Q,M==null)break e;P=x({},P,M);break e;case 2:$n=!0}}M=b.callback,M!==null&&(e.flags|=64,R&&(e.flags|=8192),R=u.callbacks,R===null?u.callbacks=[M]:R.push(M))}else R={lane:M,tag:b.tag,payload:b.payload,callback:b.callback,next:null},L===null?(j=L=R,E=P):L=L.next=R,y|=M;if(b=b.next,b===null){if(b=u.shared.pending,b===null)break;R=b,b=R.next,R.next=null,u.lastBaseUpdate=R,u.shared.pending=null}}while(!0);L===null&&(E=P),u.baseState=E,u.firstBaseUpdate=j,u.lastBaseUpdate=L,d===null&&(u.shared.lanes=0),ni|=y,e.lanes=y,e.memoizedState=P}}function ip(e,i){if(typeof e!="function")throw Error(r(191,e));e.call(i)}function ap(e,i){var s=e.callbacks;if(s!==null)for(e.callbacks=null,e=0;ed?d:8;var y=O.T,b={};O.T=b,bu(e,!1,i,s);try{var E=u(),j=O.S;if(j!==null&&j(b,E),E!==null&&typeof E=="object"&&typeof E.then=="function"){var L=Q2(E,o);Vs(e,i,L,Bt(e))}else Vs(e,i,o,Bt(e))}catch(P){Vs(e,i,{then:function(){},status:"rejected",reason:P},Bt())}finally{q.p=d,y!==null&&b.types!==null&&(y.types=b.types),O.T=y}}function iw(){}function vu(e,i,s,o){if(e.tag!==5)throw Error(r(476));var u=zp(e).queue;Lp(e,u,i,Y,s===null?iw:function(){return Vp(e),s(o)})}function zp(e){var i=e.memoizedState;if(i!==null)return i;i={memoizedState:Y,baseState:Y,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Nn,lastRenderedState:Y},next:null};var s={};return i.next={memoizedState:s,baseState:s,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Nn,lastRenderedState:s},next:null},e.memoizedState=i,e=e.alternate,e!==null&&(e.memoizedState=i),i}function Vp(e){var i=zp(e);i.next===null&&(i=e.alternate.memoizedState),Vs(e,i.next.queue,{},Bt())}function xu(){return ct(er)}function Bp(){return Ze().memoizedState}function Up(){return Ze().memoizedState}function aw(e){for(var i=e.return;i!==null;){switch(i.tag){case 24:case 3:var s=Bt();e=Zn(s);var o=Qn(i,e,s);o!==null&&(Dt(o,i,s),Os(o,i,s)),i={cache:Xc()},e.payload=i;return}i=i.return}}function sw(e,i,s){var o=Bt();s={lane:o,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null},bo(e)?Hp(i,s):(s=Vc(e,i,s,o),s!==null&&(Dt(s,e,o),Ip(s,i,o)))}function Pp(e,i,s){var o=Bt();Vs(e,i,s,o)}function Vs(e,i,s,o){var u={lane:o,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null};if(bo(e))Hp(i,u);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=i.lastRenderedReducer,d!==null))try{var y=i.lastRenderedState,b=d(y,s);if(u.hasEagerState=!0,u.eagerState=b,Ot(b,y))return Jr(e,i,u,0),ze===null&&Wr(),!1}catch{}finally{}if(s=Vc(e,i,u,o),s!==null)return Dt(s,e,o),Ip(s,i,o),!0}return!1}function bu(e,i,s,o){if(o={lane:2,revertLane:Wu(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},bo(e)){if(i)throw Error(r(479))}else i=Vc(e,s,o,2),i!==null&&Dt(i,e,2)}function bo(e){var i=e.alternate;return e===fe||i!==null&&i===fe}function Hp(e,i){Na=ho=!0;var s=e.pending;s===null?i.next=i:(i.next=s.next,s.next=i),e.pending=i}function Ip(e,i,s){if((s&4194048)!==0){var o=i.lanes;o&=e.pendingLanes,s|=o,i.lanes=s,Kh(e,s)}}var Bs={readContext:ct,use:go,useCallback:Fe,useContext:Fe,useEffect:Fe,useImperativeHandle:Fe,useLayoutEffect:Fe,useInsertionEffect:Fe,useMemo:Fe,useReducer:Fe,useRef:Fe,useState:Fe,useDebugValue:Fe,useDeferredValue:Fe,useTransition:Fe,useSyncExternalStore:Fe,useId:Fe,useHostTransitionStatus:Fe,useFormState:Fe,useActionState:Fe,useOptimistic:Fe,useMemoCache:Fe,useCacheRefresh:Fe};Bs.useEffectEvent=Fe;var qp={readContext:ct,use:go,useCallback:function(e,i){return vt().memoizedState=[e,i===void 0?null:i],e},useContext:ct,useEffect:Ap,useImperativeHandle:function(e,i,s){s=s!=null?s.concat([e]):null,vo(4194308,4,jp.bind(null,i,e),s)},useLayoutEffect:function(e,i){return vo(4194308,4,e,i)},useInsertionEffect:function(e,i){vo(4,2,e,i)},useMemo:function(e,i){var s=vt();i=i===void 0?null:i;var o=e();if(Ui){In(!0);try{e()}finally{In(!1)}}return s.memoizedState=[o,i],o},useReducer:function(e,i,s){var o=vt();if(s!==void 0){var u=s(i);if(Ui){In(!0);try{s(i)}finally{In(!1)}}}else u=i;return o.memoizedState=o.baseState=u,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:u},o.queue=e,e=e.dispatch=sw.bind(null,fe,e),[o.memoizedState,e]},useRef:function(e){var i=vt();return e={current:e},i.memoizedState=e},useState:function(e){e=hu(e);var i=e.queue,s=Pp.bind(null,fe,i);return i.dispatch=s,[e.memoizedState,s]},useDebugValue:gu,useDeferredValue:function(e,i){var s=vt();return yu(s,e,i)},useTransition:function(){var e=hu(!1);return e=Lp.bind(null,fe,e.queue,!0,!1),vt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,i,s){var o=fe,u=vt();if(be){if(s===void 0)throw Error(r(407));s=s()}else{if(s=i(),ze===null)throw Error(r(349));(ve&127)!==0||up(o,i,s)}u.memoizedState=s;var d={value:s,getSnapshot:i};return u.queue=d,Ap(dp.bind(null,o,d,e),[e]),o.flags|=2048,Ca(9,{destroy:void 0},fp.bind(null,o,d,s,i),null),s},useId:function(){var e=vt(),i=ze.identifierPrefix;if(be){var s=cn,o=ln;s=(o&~(1<<32-Mt(o)-1)).toString(32)+s,i="_"+i+"R_"+s,s=mo++,0<\/script>",d=d.removeChild(d.firstChild);break;case"select":d=typeof o.is=="string"?y.createElement("select",{is:o.is}):y.createElement("select"),o.multiple?d.multiple=!0:o.size&&(d.size=o.size);break;default:d=typeof o.is=="string"?y.createElement(u,{is:o.is}):y.createElement(u)}}d[ot]=i,d[wt]=o;e:for(y=i.child;y!==null;){if(y.tag===5||y.tag===6)d.appendChild(y.stateNode);else if(y.tag!==4&&y.tag!==27&&y.child!==null){y.child.return=y,y=y.child;continue}if(y===i)break e;for(;y.sibling===null;){if(y.return===null||y.return===i)break e;y=y.return}y.sibling.return=y.return,y=y.sibling}i.stateNode=d;e:switch(ft(d,u,o),u){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break e;case"img":o=!0;break e;default:o=!1}o&&Cn(i)}}return Ue(i),ku(i,i.type,e===null?null:e.memoizedProps,i.pendingProps,s),null;case 6:if(e&&i.stateNode!=null)e.memoizedProps!==o&&Cn(i);else{if(typeof o!="string"&&i.stateNode===null)throw Error(r(166));if(e=pe.current,ba(i)){if(e=i.stateNode,s=i.memoizedProps,o=null,u=lt,u!==null)switch(u.tag){case 27:case 5:o=u.memoizedProps}e[ot]=i,e=!!(e.nodeValue===s||o!==null&&o.suppressHydrationWarning===!0||ly(e.nodeValue,s)),e||Kn(i,!0)}else e=Po(e).createTextNode(o),e[ot]=i,i.stateNode=e}return Ue(i),null;case 31:if(s=i.memoizedState,e===null||e.memoizedState!==null){if(o=ba(i),s!==null){if(e===null){if(!o)throw Error(r(318));if(e=i.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(r(557));e[ot]=i}else Oi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;Ue(i),e=!1}else s=Fc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=s),e=!0;if(!e)return i.flags&256?(Lt(i),i):(Lt(i),null);if((i.flags&128)!==0)throw Error(r(558))}return Ue(i),null;case 13:if(o=i.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(u=ba(i),o!==null&&o.dehydrated!==null){if(e===null){if(!u)throw Error(r(318));if(u=i.memoizedState,u=u!==null?u.dehydrated:null,!u)throw Error(r(317));u[ot]=i}else Oi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;Ue(i),u=!1}else u=Fc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=u),u=!0;if(!u)return i.flags&256?(Lt(i),i):(Lt(i),null)}return Lt(i),(i.flags&128)!==0?(i.lanes=s,i):(s=o!==null,e=e!==null&&e.memoizedState!==null,s&&(o=i.child,u=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(u=o.alternate.memoizedState.cachePool.pool),d=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(d=o.memoizedState.cachePool.pool),d!==u&&(o.flags|=2048)),s!==e&&s&&(i.child.flags|=8192),Eo(i,i.updateQueue),Ue(i),null);case 4:return Xe(),e===null&&nf(i.stateNode.containerInfo),Ue(i),null;case 10:return En(i.type),Ue(i),null;case 19:if(V($e),o=i.memoizedState,o===null)return Ue(i),null;if(u=(i.flags&128)!==0,d=o.rendering,d===null)if(u)Ps(o,!1);else{if(Ge!==0||e!==null&&(e.flags&128)!==0)for(e=i.child;e!==null;){if(d=fo(e),d!==null){for(i.flags|=128,Ps(o,!1),e=d.updateQueue,i.updateQueue=e,Eo(i,e),i.subtreeFlags=0,e=s,s=i.child;s!==null;)Pm(s,e),s=s.sibling;return G($e,$e.current&1|2),be&&_n(i,o.treeForkCount),i.child}e=e.sibling}o.tail!==null&&Ct()>jo&&(i.flags|=128,u=!0,Ps(o,!1),i.lanes=4194304)}else{if(!u)if(e=fo(d),e!==null){if(i.flags|=128,u=!0,e=e.updateQueue,i.updateQueue=e,Eo(i,e),Ps(o,!0),o.tail===null&&o.tailMode==="hidden"&&!d.alternate&&!be)return Ue(i),null}else 2*Ct()-o.renderingStartTime>jo&&s!==536870912&&(i.flags|=128,u=!0,Ps(o,!1),i.lanes=4194304);o.isBackwards?(d.sibling=i.child,i.child=d):(e=o.last,e!==null?e.sibling=d:i.child=d,o.last=d)}return o.tail!==null?(e=o.tail,o.rendering=e,o.tail=e.sibling,o.renderingStartTime=Ct(),e.sibling=null,s=$e.current,G($e,u?s&1|2:s&1),be&&_n(i,o.treeForkCount),e):(Ue(i),null);case 22:case 23:return Lt(i),iu(),o=i.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(i.flags|=8192):o&&(i.flags|=8192),o?(s&536870912)!==0&&(i.flags&128)===0&&(Ue(i),i.subtreeFlags&6&&(i.flags|=8192)):Ue(i),s=i.updateQueue,s!==null&&Eo(i,s.retryQueue),s=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(s=e.memoizedState.cachePool.pool),o=null,i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(o=i.memoizedState.cachePool.pool),o!==s&&(i.flags|=2048),e!==null&&V(Li),null;case 24:return s=null,e!==null&&(s=e.memoizedState.cache),i.memoizedState.cache!==s&&(i.flags|=2048),En(We),Ue(i),null;case 25:return null;case 30:return null}throw Error(r(156,i.tag))}function uw(e,i){switch(Ic(i),i.tag){case 1:return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 3:return En(We),Xe(),e=i.flags,(e&65536)!==0&&(e&128)===0?(i.flags=e&-65537|128,i):null;case 26:case 27:case 5:return Lr(i),null;case 31:if(i.memoizedState!==null){if(Lt(i),i.alternate===null)throw Error(r(340));Oi()}return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 13:if(Lt(i),e=i.memoizedState,e!==null&&e.dehydrated!==null){if(i.alternate===null)throw Error(r(340));Oi()}return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 19:return V($e),null;case 4:return Xe(),null;case 10:return En(i.type),null;case 22:case 23:return Lt(i),iu(),e!==null&&V(Li),e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 24:return En(We),null;case 25:return null;default:return null}}function hg(e,i){switch(Ic(i),i.tag){case 3:En(We),Xe();break;case 26:case 27:case 5:Lr(i);break;case 4:Xe();break;case 31:i.memoizedState!==null&&Lt(i);break;case 13:Lt(i);break;case 19:V($e);break;case 10:En(i.type);break;case 22:case 23:Lt(i),iu(),e!==null&&V(Li);break;case 24:En(We)}}function Hs(e,i){try{var s=i.updateQueue,o=s!==null?s.lastEffect:null;if(o!==null){var u=o.next;s=u;do{if((s.tag&e)===e){o=void 0;var d=s.create,y=s.inst;o=d(),y.destroy=o}s=s.next}while(s!==u)}}catch(b){Me(i,i.return,b)}}function ei(e,i,s){try{var o=i.updateQueue,u=o!==null?o.lastEffect:null;if(u!==null){var d=u.next;o=d;do{if((o.tag&e)===e){var y=o.inst,b=y.destroy;if(b!==void 0){y.destroy=void 0,u=i;var E=s,j=b;try{j()}catch(L){Me(u,E,L)}}}o=o.next}while(o!==d)}}catch(L){Me(i,i.return,L)}}function mg(e){var i=e.updateQueue;if(i!==null){var s=e.stateNode;try{ap(i,s)}catch(o){Me(e,e.return,o)}}}function pg(e,i,s){s.props=Pi(e.type,e.memoizedProps),s.state=e.memoizedState;try{s.componentWillUnmount()}catch(o){Me(e,i,o)}}function Is(e,i){try{var s=e.ref;if(s!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:o=e.stateNode;break;default:o=e.stateNode}typeof s=="function"?e.refCleanup=s(o):s.current=o}}catch(u){Me(e,i,u)}}function un(e,i){var s=e.ref,o=e.refCleanup;if(s!==null)if(typeof o=="function")try{o()}catch(u){Me(e,i,u)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof s=="function")try{s(null)}catch(u){Me(e,i,u)}else s.current=null}function gg(e){var i=e.type,s=e.memoizedProps,o=e.stateNode;try{e:switch(i){case"button":case"input":case"select":case"textarea":s.autoFocus&&o.focus();break e;case"img":s.src?o.src=s.src:s.srcSet&&(o.srcset=s.srcSet)}}catch(u){Me(e,e.return,u)}}function Lu(e,i,s){try{var o=e.stateNode;Ow(o,e.type,s,i),o[wt]=i}catch(u){Me(e,e.return,u)}}function yg(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&oi(e.type)||e.tag===4}function zu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||yg(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&oi(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Vu(e,i,s){var o=e.tag;if(o===5||o===6)e=e.stateNode,i?(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s).insertBefore(e,i):(i=s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,i.appendChild(e),s=s._reactRootContainer,s!=null||i.onclick!==null||(i.onclick=bn));else if(o!==4&&(o===27&&oi(e.type)&&(s=e.stateNode,i=null),e=e.child,e!==null))for(Vu(e,i,s),e=e.sibling;e!==null;)Vu(e,i,s),e=e.sibling}function Ao(e,i,s){var o=e.tag;if(o===5||o===6)e=e.stateNode,i?s.insertBefore(e,i):s.appendChild(e);else if(o!==4&&(o===27&&oi(e.type)&&(s=e.stateNode),e=e.child,e!==null))for(Ao(e,i,s),e=e.sibling;e!==null;)Ao(e,i,s),e=e.sibling}function vg(e){var i=e.stateNode,s=e.memoizedProps;try{for(var o=e.type,u=i.attributes;u.length;)i.removeAttributeNode(u[0]);ft(i,o,s),i[ot]=e,i[wt]=s}catch(d){Me(e,e.return,d)}}var jn=!1,tt=!1,Bu=!1,xg=typeof WeakSet=="function"?WeakSet:Set,rt=null;function fw(e,i){if(e=e.containerInfo,rf=Ko,e=Mm(e),Mc(e)){if("selectionStart"in e)var s={start:e.selectionStart,end:e.selectionEnd};else e:{s=(s=e.ownerDocument)&&s.defaultView||window;var o=s.getSelection&&s.getSelection();if(o&&o.rangeCount!==0){s=o.anchorNode;var u=o.anchorOffset,d=o.focusNode;o=o.focusOffset;try{s.nodeType,d.nodeType}catch{s=null;break e}var y=0,b=-1,E=-1,j=0,L=0,P=e,M=null;t:for(;;){for(var R;P!==s||u!==0&&P.nodeType!==3||(b=y+u),P!==d||o!==0&&P.nodeType!==3||(E=y+o),P.nodeType===3&&(y+=P.nodeValue.length),(R=P.firstChild)!==null;)M=P,P=R;for(;;){if(P===e)break t;if(M===s&&++j===u&&(b=y),M===d&&++L===o&&(E=y),(R=P.nextSibling)!==null)break;P=M,M=P.parentNode}P=R}s=b===-1||E===-1?null:{start:b,end:E}}else s=null}s=s||{start:0,end:0}}else s=null;for(of={focusedElem:e,selectionRange:s},Ko=!1,rt=i;rt!==null;)if(i=rt,e=i.child,(i.subtreeFlags&1028)!==0&&e!==null)e.return=i,rt=e;else for(;rt!==null;){switch(i=rt,d=i.alternate,e=i.flags,i.tag){case 0:if((e&4)!==0&&(e=i.updateQueue,e=e!==null?e.events:null,e!==null))for(s=0;s title"))),ft(d,o,s),d[ot]=e,st(d),o=d;break e;case"link":var y=Ey("link","href",u).get(o+(s.href||""));if(y){for(var b=0;bLe&&(y=Le,Le=ie,ie=y);var D=Cm(b,ie),N=Cm(b,Le);if(D&&N&&(R.rangeCount!==1||R.anchorNode!==D.node||R.anchorOffset!==D.offset||R.focusNode!==N.node||R.focusOffset!==N.offset)){var C=P.createRange();C.setStart(D.node,D.offset),R.removeAllRanges(),ie>Le?(R.addRange(C),R.extend(N.node,N.offset)):(C.setEnd(N.node,N.offset),R.addRange(C))}}}}for(P=[],R=b;R=R.parentNode;)R.nodeType===1&&P.push({element:R,left:R.scrollLeft,top:R.scrollTop});for(typeof b.focus=="function"&&b.focus(),b=0;bs?32:s,O.T=null,s=Gu,Gu=null;var d=ai,y=Ln;if(it=0,ka=ai=null,Ln=0,(Ne&6)!==0)throw Error(r(331));var b=Ne;if(Ne|=4,jg(d.current),Ng(d,d.current,y,s),Ne=b,Xs(0,!1),jt&&typeof jt.onPostCommitFiberRoot=="function")try{jt.onPostCommitFiberRoot(ds,d)}catch{}return!0}finally{q.p=u,O.T=o,Xg(e,i)}}function Zg(e,i,s){i=Ft(s,i),i=Tu(e.stateNode,i,2),e=Qn(e,i,2),e!==null&&(ms(e,2),fn(e))}function Me(e,i,s){if(e.tag===3)Zg(e,e,s);else for(;i!==null;){if(i.tag===3){Zg(i,e,s);break}else if(i.tag===1){var o=i.stateNode;if(typeof i.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(ii===null||!ii.has(o))){e=Ft(s,e),s=Qp(2),o=Qn(i,s,2),o!==null&&(Wp(s,o,i,e),ms(o,2),fn(o));break}}i=i.return}}function $u(e,i,s){var o=e.pingCache;if(o===null){o=e.pingCache=new mw;var u=new Set;o.set(i,u)}else u=o.get(i),u===void 0&&(u=new Set,o.set(i,u));u.has(s)||(Hu=!0,u.add(s),e=xw.bind(null,e,i,s),i.then(e,e))}function xw(e,i,s){var o=e.pingCache;o!==null&&o.delete(i),e.pingedLanes|=e.suspendedLanes&s,e.warmLanes&=~s,ze===e&&(ve&s)===s&&(Ge===4||Ge===3&&(ve&62914560)===ve&&300>Ct()-Co?(Ne&2)===0&&La(e,0):Iu|=s,Ra===ve&&(Ra=0)),fn(e)}function Qg(e,i){i===0&&(i=Gh()),e=ji(e,i),e!==null&&(ms(e,i),fn(e))}function bw(e){var i=e.memoizedState,s=0;i!==null&&(s=i.retryLane),Qg(e,s)}function Sw(e,i){var s=0;switch(e.tag){case 31:case 13:var o=e.stateNode,u=e.memoizedState;u!==null&&(s=u.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(r(314))}o!==null&&o.delete(i),Qg(e,s)}function ww(e,i){return lc(e,i)}var zo=null,Va=null,Zu=!1,Vo=!1,Qu=!1,ri=0;function fn(e){e!==Va&&e.next===null&&(Va===null?zo=Va=e:Va=Va.next=e),Vo=!0,Zu||(Zu=!0,Tw())}function Xs(e,i){if(!Qu&&Vo){Qu=!0;do for(var s=!1,o=zo;o!==null;){if(e!==0){var u=o.pendingLanes;if(u===0)var d=0;else{var y=o.suspendedLanes,b=o.pingedLanes;d=(1<<31-Mt(42|e)+1)-1,d&=u&~(y&~b),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(s=!0,ty(o,d))}else d=ve,d=Pr(o,o===ze?d:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(d&3)===0||hs(o,d)||(s=!0,ty(o,d));o=o.next}while(s);Qu=!1}}function _w(){Wg()}function Wg(){Vo=Zu=!1;var e=0;ri!==0&&kw()&&(e=ri);for(var i=Ct(),s=null,o=zo;o!==null;){var u=o.next,d=Jg(o,i);d===0?(o.next=null,s===null?zo=u:s.next=u,u===null&&(Va=s)):(s=o,(e!==0||(d&3)!==0)&&(Vo=!0)),o=u}it!==0&&it!==5||Xs(e),ri!==0&&(ri=0)}function Jg(e,i){for(var s=e.suspendedLanes,o=e.pingedLanes,u=e.expirationTimes,d=e.pendingLanes&-62914561;0b)break;var L=E.transferSize,P=E.initiatorType;L&&cy(P)&&(E=E.responseEnd,y+=L*(E"u"?null:document;function Sy(e,i,s){var o=Ba;if(o&&typeof i=="string"&&i){var u=It(i);u='link[rel="'+e+'"][href="'+u+'"]',typeof s=="string"&&(u+='[crossorigin="'+s+'"]'),by.has(u)||(by.add(u),e={rel:e,crossOrigin:s,href:i},o.querySelector(u)===null&&(i=o.createElement("link"),ft(i,"link",e),st(i),o.head.appendChild(i)))}}function qw(e){zn.D(e),Sy("dns-prefetch",e,null)}function Fw(e,i){zn.C(e,i),Sy("preconnect",e,i)}function Gw(e,i,s){zn.L(e,i,s);var o=Ba;if(o&&e&&i){var u='link[rel="preload"][as="'+It(i)+'"]';i==="image"&&s&&s.imageSrcSet?(u+='[imagesrcset="'+It(s.imageSrcSet)+'"]',typeof s.imageSizes=="string"&&(u+='[imagesizes="'+It(s.imageSizes)+'"]')):u+='[href="'+It(e)+'"]';var d=u;switch(i){case"style":d=Ua(e);break;case"script":d=Pa(e)}Zt.has(d)||(e=x({rel:"preload",href:i==="image"&&s&&s.imageSrcSet?void 0:e,as:i},s),Zt.set(d,e),o.querySelector(u)!==null||i==="style"&&o.querySelector(Ws(d))||i==="script"&&o.querySelector(Js(d))||(i=o.createElement("link"),ft(i,"link",e),st(i),o.head.appendChild(i)))}}function Yw(e,i){zn.m(e,i);var s=Ba;if(s&&e){var o=i&&typeof i.as=="string"?i.as:"script",u='link[rel="modulepreload"][as="'+It(o)+'"][href="'+It(e)+'"]',d=u;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Pa(e)}if(!Zt.has(d)&&(e=x({rel:"modulepreload",href:e},i),Zt.set(d,e),s.querySelector(u)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(s.querySelector(Js(d)))return}o=s.createElement("link"),ft(o,"link",e),st(o),s.head.appendChild(o)}}}function Kw(e,i,s){zn.S(e,i,s);var o=Ba;if(o&&e){var u=oa(o).hoistableStyles,d=Ua(e);i=i||"default";var y=u.get(d);if(!y){var b={loading:0,preload:null};if(y=o.querySelector(Ws(d)))b.loading=5;else{e=x({rel:"stylesheet",href:e,"data-precedence":i},s),(s=Zt.get(d))&&mf(e,s);var E=y=o.createElement("link");st(E),ft(E,"link",e),E._p=new Promise(function(j,L){E.onload=j,E.onerror=L}),E.addEventListener("load",function(){b.loading|=1}),E.addEventListener("error",function(){b.loading|=2}),b.loading|=4,Io(y,i,o)}y={type:"stylesheet",instance:y,count:1,state:b},u.set(d,y)}}}function Xw(e,i){zn.X(e,i);var s=Ba;if(s&&e){var o=oa(s).hoistableScripts,u=Pa(e),d=o.get(u);d||(d=s.querySelector(Js(u)),d||(e=x({src:e,async:!0},i),(i=Zt.get(u))&&pf(e,i),d=s.createElement("script"),st(d),ft(d,"link",e),s.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(u,d))}}function $w(e,i){zn.M(e,i);var s=Ba;if(s&&e){var o=oa(s).hoistableScripts,u=Pa(e),d=o.get(u);d||(d=s.querySelector(Js(u)),d||(e=x({src:e,async:!0,type:"module"},i),(i=Zt.get(u))&&pf(e,i),d=s.createElement("script"),st(d),ft(d,"link",e),s.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(u,d))}}function wy(e,i,s,o){var u=(u=pe.current)?Ho(u):null;if(!u)throw Error(r(446));switch(e){case"meta":case"title":return null;case"style":return typeof s.precedence=="string"&&typeof s.href=="string"?(i=Ua(s.href),s=oa(u).hoistableStyles,o=s.get(i),o||(o={type:"style",instance:null,count:0,state:null},s.set(i,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(s.rel==="stylesheet"&&typeof s.href=="string"&&typeof s.precedence=="string"){e=Ua(s.href);var d=oa(u).hoistableStyles,y=d.get(e);if(y||(u=u.ownerDocument||u,y={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,y),(d=u.querySelector(Ws(e)))&&!d._p&&(y.instance=d,y.state.loading=5),Zt.has(e)||(s={rel:"preload",as:"style",href:s.href,crossOrigin:s.crossOrigin,integrity:s.integrity,media:s.media,hrefLang:s.hrefLang,referrerPolicy:s.referrerPolicy},Zt.set(e,s),d||Zw(u,e,s,y.state))),i&&o===null)throw Error(r(528,""));return y}if(i&&o!==null)throw Error(r(529,""));return null;case"script":return i=s.async,s=s.src,typeof s=="string"&&i&&typeof i!="function"&&typeof i!="symbol"?(i=Pa(s),s=oa(u).hoistableScripts,o=s.get(i),o||(o={type:"script",instance:null,count:0,state:null},s.set(i,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,e))}}function Ua(e){return'href="'+It(e)+'"'}function Ws(e){return'link[rel="stylesheet"]['+e+"]"}function _y(e){return x({},e,{"data-precedence":e.precedence,precedence:null})}function Zw(e,i,s,o){e.querySelector('link[rel="preload"][as="style"]['+i+"]")?o.loading=1:(i=e.createElement("link"),o.preload=i,i.addEventListener("load",function(){return o.loading|=1}),i.addEventListener("error",function(){return o.loading|=2}),ft(i,"link",s),st(i),e.head.appendChild(i))}function Pa(e){return'[src="'+It(e)+'"]'}function Js(e){return"script[async]"+e}function Ty(e,i,s){if(i.count++,i.instance===null)switch(i.type){case"style":var o=e.querySelector('style[data-href~="'+It(s.href)+'"]');if(o)return i.instance=o,st(o),o;var u=x({},s,{"data-href":s.href,"data-precedence":s.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),st(o),ft(o,"style",u),Io(o,s.precedence,e),i.instance=o;case"stylesheet":u=Ua(s.href);var d=e.querySelector(Ws(u));if(d)return i.state.loading|=4,i.instance=d,st(d),d;o=_y(s),(u=Zt.get(u))&&mf(o,u),d=(e.ownerDocument||e).createElement("link"),st(d);var y=d;return y._p=new Promise(function(b,E){y.onload=b,y.onerror=E}),ft(d,"link",o),i.state.loading|=4,Io(d,s.precedence,e),i.instance=d;case"script":return d=Pa(s.src),(u=e.querySelector(Js(d)))?(i.instance=u,st(u),u):(o=s,(u=Zt.get(d))&&(o=x({},s),pf(o,u)),e=e.ownerDocument||e,u=e.createElement("script"),st(u),ft(u,"link",o),e.head.appendChild(u),i.instance=u);case"void":return null;default:throw Error(r(443,i.type))}else i.type==="stylesheet"&&(i.state.loading&4)===0&&(o=i.instance,i.state.loading|=4,Io(o,s.precedence,e));return i.instance}function Io(e,i,s){for(var o=s.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),u=o.length?o[o.length-1]:null,d=u,y=0;y title"):null)}function Qw(e,i,s){if(s===1||i.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof i.precedence!="string"||typeof i.href!="string"||i.href==="")break;return!0;case"link":if(typeof i.rel!="string"||typeof i.href!="string"||i.href===""||i.onLoad||i.onError)break;switch(i.rel){case"stylesheet":return e=i.disabled,typeof i.precedence=="string"&&e==null;default:return!0}case"script":if(i.async&&typeof i.async!="function"&&typeof i.async!="symbol"&&!i.onLoad&&!i.onError&&i.src&&typeof i.src=="string")return!0}return!1}function Ny(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Ww(e,i,s,o){if(s.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(s.state.loading&4)===0){if(s.instance===null){var u=Ua(o.href),d=i.querySelector(Ws(u));if(d){i=d._p,i!==null&&typeof i=="object"&&typeof i.then=="function"&&(e.count++,e=Fo.bind(e),i.then(e,e)),s.state.loading|=4,s.instance=d,st(d);return}d=i.ownerDocument||i,o=_y(o),(u=Zt.get(u))&&mf(o,u),d=d.createElement("link"),st(d);var y=d;y._p=new Promise(function(b,E){y.onload=b,y.onerror=E}),ft(d,"link",o),s.instance=d}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(s,i),(i=s.state.preload)&&(s.state.loading&3)===0&&(e.count++,s=Fo.bind(e),i.addEventListener("load",s),i.addEventListener("error",s))}}var gf=0;function Jw(e,i){return e.stylesheets&&e.count===0&&Yo(e,e.stylesheets),0gf?50:800)+i);return e.unsuspend=s,function(){e.unsuspend=null,clearTimeout(o),clearTimeout(u)}}:null}function Fo(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Yo(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Go=null;function Yo(e,i){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Go=new Map,i.forEach(e_,e),Go=null,Fo.call(e))}function e_(e,i){if(!(i.state.loading&4)){var s=Go.get(e);if(s)var o=s.get(null);else{s=new Map,Go.set(e,s);for(var u=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(t){console.error(t)}}return n(),kf.exports=xD(),kf.exports}var SD=bD();const Cb=K.createContext({});function wD(n){const t=K.useRef(null);return t.current===null&&(t.current=n()),t.current}const _D=typeof window<"u",TD=_D?K.useLayoutEffect:K.useEffect,uh=K.createContext(null);function fh(n,t){n.indexOf(t)===-1&&n.push(t)}function El(n,t){const a=n.indexOf(t);a>-1&&n.splice(a,1)}const yn=(n,t,a)=>a>t?t:a{};const bi={},jb=n=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(n);function Mb(n){return typeof n=="object"&&n!==null}const Ob=n=>/^0[^.\s]+$/u.test(n);function Rb(n){let t;return()=>(t===void 0&&(t=n()),t)}const Jt=n=>n,ED=(n,t)=>a=>t(n(a)),Mr=(...n)=>n.reduce(ED),Sr=(n,t,a)=>{const r=t-n;return r===0?1:(a-n)/r};class hh{constructor(){this.subscriptions=[]}add(t){return fh(this.subscriptions,t),()=>El(this.subscriptions,t)}notify(t,a,r){const l=this.subscriptions.length;if(l)if(l===1)this.subscriptions[0](t,a,r);else for(let c=0;cn*1e3,Qt=n=>n/1e3;function kb(n,t){return t?n*(1e3/t):0}const Lb=(n,t,a)=>(((1-3*a+3*t)*n+(3*a-6*t))*n+3*t)*n,AD=1e-7,ND=12;function DD(n,t,a,r,l){let c,f,h=0;do f=t+(a-t)/2,c=Lb(f,r,l)-n,c>0?a=f:t=f;while(Math.abs(c)>AD&&++hDD(c,0,1,n,a);return c=>c===0||c===1?c:Lb(l(c),t,r)}const zb=n=>t=>t<=.5?n(2*t)/2:(2-n(2*(1-t)))/2,Vb=n=>t=>1-n(1-t),Bb=Or(.33,1.53,.69,.99),mh=Vb(Bb),Ub=zb(mh),Pb=n=>n>=1?1:(n*=2)<1?.5*mh(n):.5*(2-Math.pow(2,-10*(n-1))),ph=n=>1-Math.sin(Math.acos(n)),Hb=Vb(ph),Ib=zb(ph),CD=Or(.42,0,1,1),jD=Or(0,0,.58,1),qb=Or(.42,0,.58,1),MD=n=>Array.isArray(n)&&typeof n[0]!="number",Fb=n=>Array.isArray(n)&&typeof n[0]=="number",OD={linear:Jt,easeIn:CD,easeInOut:qb,easeOut:jD,circIn:ph,circInOut:Ib,circOut:Hb,backIn:mh,backInOut:Ub,backOut:Bb,anticipate:Pb},RD=n=>typeof n=="string",X0=n=>{if(Fb(n)){dh(n.length===4);const[t,a,r,l]=n;return Or(t,a,r,l)}else if(RD(n))return OD[n];return n},il=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function kD(n,t){let a=new Set,r=new Set,l=!1,c=!1;const f=new WeakSet;let h={delta:0,timestamp:0,isProcessing:!1};function m(v){f.has(v)&&(p.schedule(v),n()),v(h)}const p={schedule:(v,x=!1,S=!1)=>{const T=S&&l?a:r;return x&&f.add(v),T.add(v),v},cancel:v=>{r.delete(v),f.delete(v)},process:v=>{if(h=v,l){c=!0;return}l=!0;const x=a;a=r,r=x,a.forEach(m),a.clear(),l=!1,c&&(c=!1,p.process(v))}};return p}const LD=40;function Gb(n,t){let a=!1,r=!0;const l={delta:0,timestamp:0,isProcessing:!1},c=()=>a=!0,f=il.reduce((H,F)=>(H[F]=kD(c),H),{}),{setup:h,read:m,resolveKeyframes:p,preUpdate:v,update:x,preRender:S,render:w,postRender:T}=f,k=()=>{const H=bi.useManualTiming,F=H?l.timestamp:performance.now();a=!1,H||(l.delta=r?1e3/60:Math.max(Math.min(F-l.timestamp,LD),1)),l.timestamp=F,l.isProcessing=!0,h.process(l),m.process(l),p.process(l),v.process(l),x.process(l),S.process(l),w.process(l),T.process(l),l.isProcessing=!1,a&&t&&(r=!1,n(k))},z=()=>{a=!0,r=!0,l.isProcessing||n(k)};return{schedule:il.reduce((H,F)=>{const $=f[F];return H[F]=(he,J=!1,te=!1)=>(a||z(),$.schedule(he,J,te)),H},{}),cancel:H=>{for(let F=0;F(hl===void 0&&bt.set(dt.isProcessing||bi.useManualTiming?dt.timestamp:performance.now()),hl),set:n=>{hl=n,queueMicrotask(zD)}},Yb=n=>t=>typeof t=="string"&&t.startsWith(n),Kb=Yb("--"),VD=Yb("var(--"),gh=n=>VD(n)?BD.test(n.split("/*")[0].trim()):!1,BD=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function $0(n){return typeof n!="string"?!1:n.split("/*")[0].includes("var(--")}const ls={test:n=>typeof n=="number",parse:parseFloat,transform:n=>n},wr={...ls,transform:n=>yn(0,1,n)},al={...ls,default:1},dr=n=>Math.round(n*1e5)/1e5,yh=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function UD(n){return n==null}const PD=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,vh=(n,t)=>a=>!!(typeof a=="string"&&PD.test(a)&&a.startsWith(n)||t&&!UD(a)&&Object.prototype.hasOwnProperty.call(a,t)),Xb=(n,t,a)=>r=>{if(typeof r!="string")return r;const[l,c,f,h]=r.match(yh);return{[n]:parseFloat(l),[t]:parseFloat(c),[a]:parseFloat(f),alpha:h!==void 0?parseFloat(h):1}},HD=n=>yn(0,255,n),Uf={...ls,transform:n=>Math.round(HD(n))},Ki={test:vh("rgb","red"),parse:Xb("red","green","blue"),transform:({red:n,green:t,blue:a,alpha:r=1})=>"rgba("+Uf.transform(n)+", "+Uf.transform(t)+", "+Uf.transform(a)+", "+dr(wr.transform(r))+")"};function ID(n){let t="",a="",r="",l="";return n.length>5?(t=n.substring(1,3),a=n.substring(3,5),r=n.substring(5,7),l=n.substring(7,9)):(t=n.substring(1,2),a=n.substring(2,3),r=n.substring(3,4),l=n.substring(4,5),t+=t,a+=a,r+=r,l+=l),{red:parseInt(t,16),green:parseInt(a,16),blue:parseInt(r,16),alpha:l?parseInt(l,16)/255:1}}const bd={test:vh("#"),parse:ID,transform:Ki.transform},Rr=n=>({test:t=>typeof t=="string"&&t.endsWith(n)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${n}`}),mi=Rr("deg"),pn=Rr("%"),W=Rr("px"),qD=Rr("vh"),FD=Rr("vw"),Z0={...pn,parse:n=>pn.parse(n)/100,transform:n=>pn.transform(n*100)},Ka={test:vh("hsl","hue"),parse:Xb("hue","saturation","lightness"),transform:({hue:n,saturation:t,lightness:a,alpha:r=1})=>"hsla("+Math.round(n)+", "+pn.transform(dr(t))+", "+pn.transform(dr(a))+", "+dr(wr.transform(r))+")"},nt={test:n=>Ki.test(n)||bd.test(n)||Ka.test(n),parse:n=>Ki.test(n)?Ki.parse(n):Ka.test(n)?Ka.parse(n):bd.parse(n),transform:n=>typeof n=="string"?n:n.hasOwnProperty("red")?Ki.transform(n):Ka.transform(n),getAnimatableNone:n=>{const t=nt.parse(n);return t.alpha=0,nt.transform(t)}},GD=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function YD(n){var t,a;return isNaN(n)&&typeof n=="string"&&(((t=n.match(yh))==null?void 0:t.length)||0)+(((a=n.match(GD))==null?void 0:a.length)||0)>0}const $b="number",Zb="color",KD="var",XD="var(",Q0="${}",$D=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ns(n){const t=n.toString(),a=[],r={color:[],number:[],var:[]},l=[];let c=0;const h=t.replace($D,m=>(nt.test(m)?(r.color.push(c),l.push(Zb),a.push(nt.parse(m))):m.startsWith(XD)?(r.var.push(c),l.push(KD),a.push(m)):(r.number.push(c),l.push($b),a.push(parseFloat(m))),++c,Q0)).split(Q0);return{values:a,split:h,indexes:r,types:l}}function ZD(n){return ns(n).values}function Qb({split:n,types:t}){const a=n.length;return r=>{let l="";for(let c=0;ctypeof n=="number"?0:nt.test(n)?nt.getAnimatableNone(n):n,JD=(n,t)=>typeof n=="number"?t!=null&&t.trim().endsWith("/")?n:0:WD(n);function eC(n){const t=ns(n);return Qb(t)(t.values.map((r,l)=>JD(r,t.split[l])))}const on={test:YD,parse:ZD,createTransformer:QD,getAnimatableNone:eC};function Pf(n,t,a){return a<0&&(a+=1),a>1&&(a-=1),a<1/6?n+(t-n)*6*a:a<1/2?t:a<2/3?n+(t-n)*(2/3-a)*6:n}function tC({hue:n,saturation:t,lightness:a,alpha:r}){n/=360,t/=100,a/=100;let l=0,c=0,f=0;if(!t)l=c=f=a;else{const h=a<.5?a*(1+t):a+t-a*t,m=2*a-h;l=Pf(m,h,n+1/3),c=Pf(m,h,n),f=Pf(m,h,n-1/3)}return{red:Math.round(l*255),green:Math.round(c*255),blue:Math.round(f*255),alpha:r}}function Al(n,t){return a=>a>0?t:n}const Pe=(n,t,a)=>n+(t-n)*a,Hf=(n,t,a)=>{const r=n*n,l=a*(t*t-r)+r;return l<0?0:Math.sqrt(l)},nC=[bd,Ki,Ka],iC=n=>nC.find(t=>t.test(n));function W0(n){const t=iC(n);if(!t)return!1;let a=t.parse(n);return t===Ka&&(a=tC(a)),a}const J0=(n,t)=>{const a=W0(n),r=W0(t);if(!a||!r)return Al(n,t);const l={...a};return c=>(l.red=Hf(a.red,r.red,c),l.green=Hf(a.green,r.green,c),l.blue=Hf(a.blue,r.blue,c),l.alpha=Pe(a.alpha,r.alpha,c),Ki.transform(l))},Sd=new Set(["none","hidden"]);function aC(n,t){return Sd.has(n)?a=>a<=0?n:t:a=>a>=1?t:n}function sC(n,t){return a=>Pe(n,t,a)}function xh(n){return typeof n=="number"?sC:typeof n=="string"?gh(n)?Al:nt.test(n)?J0:lC:Array.isArray(n)?Wb:typeof n=="object"?nt.test(n)?J0:rC:Al}function Wb(n,t){const a=[...n],r=a.length,l=n.map((c,f)=>xh(c)(c,t[f]));return c=>{for(let f=0;f{for(const c in r)a[c]=r[c](l);return a}}function oC(n,t){const a=[],r={color:0,var:0,number:0};for(let l=0;l{const a=on.createTransformer(t),r=ns(n),l=ns(t);return r.indexes.var.length===l.indexes.var.length&&r.indexes.color.length===l.indexes.color.length&&r.indexes.number.length>=l.indexes.number.length?Sd.has(n)&&!l.values.length||Sd.has(t)&&!r.values.length?aC(n,t):Mr(Wb(oC(r,l),l.values),a):Al(n,t)};function Jb(n,t,a){return typeof n=="number"&&typeof t=="number"&&typeof a=="number"?Pe(n,t,a):xh(n)(n,t)}const cC=n=>{const t=({timestamp:a})=>n(a);return{start:(a=!0)=>Ve.update(t,a),stop:()=>Si(t),now:()=>dt.isProcessing?dt.timestamp:bt.now()}},e1=(n,t,a=10)=>{let r="";const l=Math.max(Math.round(t/a),2);for(let c=0;c=Nl?1/0:t}function uC(n,t=100,a){const r=a({...n,keyframes:[0,t]}),l=Math.min(bh(r),Nl);return{type:"keyframes",ease:c=>r.next(l*c).value/t,duration:Qt(l)}}const Ye={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function wd(n,t){return n*Math.sqrt(1-t*t)}const fC=12;function dC(n,t,a){let r=a;for(let l=1;l{const v=p*f,x=v*n,S=v-a,w=wd(p,f),T=Math.exp(-x);return If-S/w*T},c=p=>{const x=p*f*n,S=x*a+a,w=Math.pow(f,2)*Math.pow(p,2)*n,T=Math.exp(-x),k=wd(Math.pow(p,2),f);return(-l(p)+If>0?-1:1)*((S-w)*T)/k}):(l=p=>{const v=Math.exp(-p*n),x=(p-a)*n+1;return-If+v*x},c=p=>{const v=Math.exp(-p*n),x=(a-p)*(n*n);return v*x});const h=5/n,m=dC(l,c,h);if(n=Pt(n),isNaN(m))return{stiffness:Ye.stiffness,damping:Ye.damping,duration:n};{const p=Math.pow(m,2)*r;return{stiffness:p,damping:f*2*Math.sqrt(r*p),duration:n}}}const mC=["duration","bounce"],pC=["stiffness","damping","mass"];function ev(n,t){return t.some(a=>n[a]!==void 0)}function gC(n){let t={velocity:Ye.velocity,stiffness:Ye.stiffness,damping:Ye.damping,mass:Ye.mass,isResolvedFromDuration:!1,...n};if(!ev(n,pC)&&ev(n,mC))if(t.velocity=0,n.visualDuration){const a=n.visualDuration,r=2*Math.PI/(a*1.2),l=r*r,c=2*yn(.05,1,1-(n.bounce||0))*Math.sqrt(l);t={...t,mass:Ye.mass,stiffness:l,damping:c}}else{const a=hC({...n,velocity:0});t={...t,...a,mass:Ye.mass},t.isResolvedFromDuration=!0}return t}function Dl(n=Ye.visualDuration,t=Ye.bounce){const a=typeof n!="object"?{visualDuration:n,keyframes:[0,1],bounce:t}:n;let{restSpeed:r,restDelta:l}=a;const c=a.keyframes[0],f=a.keyframes[a.keyframes.length-1],h={done:!1,value:c},{stiffness:m,damping:p,mass:v,duration:x,velocity:S,isResolvedFromDuration:w}=gC({...a,velocity:-Qt(a.velocity||0)}),T=S||0,k=p/(2*Math.sqrt(m*v)),z=f-c,B=Qt(Math.sqrt(m/v)),I=Math.abs(z)<5;r||(r=I?Ye.restSpeed.granular:Ye.restSpeed.default),l||(l=I?Ye.restDelta.granular:Ye.restDelta.default);let H,F,$,he,J,te;if(k<1)$=wd(B,k),he=(T+k*B*z)/$,H=X=>{const we=Math.exp(-k*B*X);return f-we*(he*Math.sin($*X)+z*Math.cos($*X))},J=k*B*he+z*$,te=k*B*z-he*$,F=X=>Math.exp(-k*B*X)*(J*Math.sin($*X)+te*Math.cos($*X));else if(k===1){H=we=>f-Math.exp(-B*we)*(z+(T+B*z)*we);const X=T+B*z;F=we=>Math.exp(-B*we)*(B*X*we-T)}else{const X=B*Math.sqrt(k*k-1);H=_e=>{const He=Math.exp(-k*B*_e),O=Math.min(X*_e,300);return f-He*((T+k*B*z)*Math.sinh(O)+X*z*Math.cosh(O))/X};const we=(T+k*B*z)/X,Ae=k*B*we-z*X,De=k*B*z-we*X;F=_e=>{const He=Math.exp(-k*B*_e),O=Math.min(X*_e,300);return He*(Ae*Math.sinh(O)+De*Math.cosh(O))}}const ue={calculatedDuration:w&&x||null,velocity:X=>Pt(F(X)),next:X=>{if(!w&&k<1){const Ae=Math.exp(-k*B*X),De=Math.sin($*X),_e=Math.cos($*X),He=f-Ae*(he*De+z*_e),O=Pt(Ae*(J*De+te*_e));return h.done=Math.abs(O)<=r&&Math.abs(f-He)<=l,h.value=h.done?f:He,h}const we=H(X);if(w)h.done=X>=x;else{const Ae=Pt(F(X));h.done=Math.abs(Ae)<=r&&Math.abs(f-we)<=l}return h.value=h.done?f:we,h},toString:()=>{const X=Math.min(bh(ue),Nl),we=e1(Ae=>ue.next(X*Ae).value,X,30);return X+"ms "+we},toTransition:()=>{}};return ue}Dl.applyToOptions=n=>{const t=uC(n,100,Dl);return n.ease=t.ease,n.duration=Pt(t.duration),n.type="keyframes",n};const yC=5;function t1(n,t,a){const r=Math.max(t-yC,0);return kb(a-n(r),t-r)}function _d({keyframes:n,velocity:t=0,power:a=.8,timeConstant:r=325,bounceDamping:l=10,bounceStiffness:c=500,modifyTarget:f,min:h,max:m,restDelta:p=.5,restSpeed:v}){const x=n[0],S={done:!1,value:x},w=te=>h!==void 0&&tem,T=te=>h===void 0?m:m===void 0||Math.abs(h-te)-k*Math.exp(-te/r),H=te=>B+I(te),F=te=>{const ue=I(te),X=H(te);S.done=Math.abs(ue)<=p,S.value=S.done?B:X};let $,he;const J=te=>{w(S.value)&&($=te,he=Dl({keyframes:[S.value,T(S.value)],velocity:t1(H,te,S.value),damping:l,stiffness:c,restDelta:p,restSpeed:v}))};return J(0),{calculatedDuration:null,next:te=>{let ue=!1;return!he&&$===void 0&&(ue=!0,F(te),J(te)),$!==void 0&&te>=$?he.next(te-$):(!ue&&F(te),S)}}}function vC(n,t,a){const r=[],l=a||bi.mix||Jb,c=n.length-1;for(let f=0;ft[0];if(c===2&&t[0]===t[1])return()=>t[1];const f=n[0]===n[1];n[0]>n[c-1]&&(n=[...n].reverse(),t=[...t].reverse());const h=vC(t,r,l),m=h.length,p=v=>{if(f&&v1)for(;xp(yn(n[0],n[c-1],v)):p}function bC(n,t){const a=n[n.length-1];for(let r=1;r<=t;r++){const l=Sr(0,t,r);n.push(Pe(a,1,l))}}function SC(n){const t=[0];return bC(t,n.length-1),t}function wC(n,t){return n.map(a=>a*t)}function _C(n,t){return n.map(()=>t||qb).splice(0,n.length-1)}function hr({duration:n=300,keyframes:t,times:a,ease:r="easeInOut"}){const l=MD(r)?r.map(X0):X0(r),c={done:!1,value:t[0]},f=wC(a&&a.length===t.length?a:SC(t),n),h=xC(f,t,{ease:Array.isArray(l)?l:_C(t,l)});return{calculatedDuration:n,next:m=>(c.value=h(m),c.done=m>=n,c)}}const TC=n=>n!==null;function Wl(n,{repeat:t,repeatType:a="loop"},r,l=1){const c=n.filter(TC),h=l<0||t&&a!=="loop"&&t%2===1?0:c.length-1;return!h||r===void 0?c[h]:r}const EC={decay:_d,inertia:_d,tween:hr,keyframes:hr,spring:Dl};function n1(n){typeof n.type=="string"&&(n.type=EC[n.type])}class Sh{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,a){return this.finished.then(t,a)}}const AC=n=>n/100;class Cl extends Sh{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,l;const{motionValue:a}=this.options;a&&a.updatedAt!==bt.now()&&this.tick(bt.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(l=(r=this.options).onStop)==null||l.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;n1(t);const{type:a=hr,repeat:r=0,repeatDelay:l=0,repeatType:c,velocity:f=0}=t;let{keyframes:h}=t;const m=a||hr;m!==hr&&typeof h[0]!="number"&&(this.mixKeyframes=Mr(AC,Jb(h[0],h[1])),h=[0,100]);const p=m({...t,keyframes:h});c==="mirror"&&(this.mirroredGenerator=m({...t,keyframes:[...h].reverse(),velocity:-f})),p.calculatedDuration===null&&(p.calculatedDuration=bh(p));const{calculatedDuration:v}=p;this.calculatedDuration=v,this.resolvedDuration=v+l,this.totalDuration=this.resolvedDuration*(r+1)-l,this.generator=p}updateTime(t){const a=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=a}tick(t,a=!1){const{generator:r,totalDuration:l,mixKeyframes:c,mirroredGenerator:f,resolvedDuration:h,calculatedDuration:m}=this;if(this.startTime===null)return r.next(0);const{delay:p=0,keyframes:v,repeat:x,repeatType:S,repeatDelay:w,type:T,onUpdate:k,finalKeyframe:z}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-l/this.speed,this.startTime)),a?this.currentTime=t:this.updateTime(t);const B=this.currentTime-p*(this.playbackSpeed>=0?1:-1),I=this.playbackSpeed>=0?B<0:B>l;this.currentTime=Math.max(B,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=l);let H=this.currentTime,F=r;if(x){const te=Math.min(this.currentTime,l)/h;let ue=Math.floor(te),X=te%1;!X&&te>=1&&(X=1),X===1&&ue--,ue=Math.min(ue,x+1),!!(ue%2)&&(S==="reverse"?(X=1-X,w&&(X-=w/h)):S==="mirror"&&(F=f)),H=yn(0,1,X)*h}let $;I?(this.delayState.value=v[0],$=this.delayState):$=F.next(H),c&&!I&&($.value=c($.value));let{done:he}=$;!I&&m!==null&&(he=this.playbackSpeed>=0?this.currentTime>=l:this.currentTime<=0);const J=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&he);return J&&T!==_d&&($.value=Wl(v,this.options,z,this.speed)),k&&k($.value),J&&this.finish(),$}then(t,a){return this.finished.then(t,a)}get duration(){return Qt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Qt(t)}get time(){return Qt(this.currentTime)}set time(t){t=Pt(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const a=this.generator.next(t).value;return t1(r=>this.generator.next(r).value,t,a)}get speed(){return this.playbackSpeed}set speed(t){const a=this.playbackSpeed!==t;a&&this.driver&&this.updateTime(bt.now()),this.playbackSpeed=t,a&&this.driver&&(this.time=Qt(this.currentTime))}play(){var l,c;if(this.isStopped)return;const{driver:t=cC,startTime:a}=this.options;this.driver||(this.driver=t(f=>this.tick(f))),(c=(l=this.options).onPlay)==null||c.call(l);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=a??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(bt.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,a;this.notifyFinished(),this.teardown(),this.state="finished",(a=(t=this.options).onComplete)==null||a.call(t)}cancel(){var t,a;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(a=(t=this.options).onCancel)==null||a.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var a;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(a=this.driver)==null||a.stop(),t.observe(this)}}function NC(n){for(let t=1;tn*180/Math.PI,Td=n=>{const t=Xi(Math.atan2(n[1],n[0]));return Ed(t)},DC={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:n=>(Math.abs(n[0])+Math.abs(n[3]))/2,rotate:Td,rotateZ:Td,skewX:n=>Xi(Math.atan(n[1])),skewY:n=>Xi(Math.atan(n[2])),skew:n=>(Math.abs(n[1])+Math.abs(n[2]))/2},Ed=n=>(n=n%360,n<0&&(n+=360),n),tv=Td,nv=n=>Math.sqrt(n[0]*n[0]+n[1]*n[1]),iv=n=>Math.sqrt(n[4]*n[4]+n[5]*n[5]),CC={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:nv,scaleY:iv,scale:n=>(nv(n)+iv(n))/2,rotateX:n=>Ed(Xi(Math.atan2(n[6],n[5]))),rotateY:n=>Ed(Xi(Math.atan2(-n[2],n[0]))),rotateZ:tv,rotate:tv,skewX:n=>Xi(Math.atan(n[4])),skewY:n=>Xi(Math.atan(n[1])),skew:n=>(Math.abs(n[1])+Math.abs(n[4]))/2};function Ad(n){return n.includes("scale")?1:0}function Nd(n,t){if(!n||n==="none")return Ad(t);const a=n.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,l;if(a)r=CC,l=a;else{const h=n.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=DC,l=h}if(!l)return Ad(t);const c=r[t],f=l[1].split(",").map(MC);return typeof c=="function"?c(f):f[c]}const jC=(n,t)=>{const{transform:a="none"}=getComputedStyle(n);return Nd(a,t)};function MC(n){return parseFloat(n.trim())}const cs=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],us=new Set(cs),av=n=>n===ls||n===W,OC=new Set(["x","y","z"]),RC=cs.filter(n=>!OC.has(n));function kC(n){const t=[];return RC.forEach(a=>{const r=n.getValue(a);r!==void 0&&(t.push([a,r.get()]),r.set(a.startsWith("scale")?1:0))}),t}const gi={width:({x:n},{paddingLeft:t="0",paddingRight:a="0",boxSizing:r})=>{const l=n.max-n.min;return r==="border-box"?l:l-parseFloat(t)-parseFloat(a)},height:({y:n},{paddingTop:t="0",paddingBottom:a="0",boxSizing:r})=>{const l=n.max-n.min;return r==="border-box"?l:l-parseFloat(t)-parseFloat(a)},top:(n,{top:t})=>parseFloat(t),left:(n,{left:t})=>parseFloat(t),bottom:({y:n},{top:t})=>parseFloat(t)+(n.max-n.min),right:({x:n},{left:t})=>parseFloat(t)+(n.max-n.min),x:(n,{transform:t})=>Nd(t,"x"),y:(n,{transform:t})=>Nd(t,"y")};gi.translateX=gi.x;gi.translateY=gi.y;const Zi=new Set;let Dd=!1,Cd=!1,jd=!1;function i1(){if(Cd){const n=Array.from(Zi).filter(r=>r.needsMeasurement),t=new Set(n.map(r=>r.element)),a=new Map;t.forEach(r=>{const l=kC(r);l.length&&(a.set(r,l),r.render())}),n.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const l=a.get(r);l&&l.forEach(([c,f])=>{var h;(h=r.getValue(c))==null||h.set(f)})}),n.forEach(r=>r.measureEndState()),n.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Cd=!1,Dd=!1,Zi.forEach(n=>n.complete(jd)),Zi.clear()}function a1(){Zi.forEach(n=>{n.readKeyframes(),n.needsMeasurement&&(Cd=!0)})}function LC(){jd=!0,a1(),i1(),jd=!1}class wh{constructor(t,a,r,l,c,f=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=a,this.name=r,this.motionValue=l,this.element=c,this.isAsync=f}scheduleResolve(){this.state="scheduled",this.isAsync?(Zi.add(this),Dd||(Dd=!0,Ve.read(a1),Ve.resolveKeyframes(i1))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:a,element:r,motionValue:l}=this;if(t[0]===null){const c=l==null?void 0:l.get(),f=t[t.length-1];if(c!==void 0)t[0]=c;else if(r&&a){const h=r.readValue(a,f);h!=null&&(t[0]=h)}t[0]===void 0&&(t[0]=f),l&&c===void 0&&l.set(t[0])}NC(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Zi.delete(this)}cancel(){this.state==="scheduled"&&(Zi.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const zC=n=>n.startsWith("--");function s1(n,t,a){zC(t)?n.style.setProperty(t,a):n.style[t]=a}const VC={};function r1(n,t){const a=Rb(n);return()=>VC[t]??a()}const BC=r1(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),o1=r1(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),fr=([n,t,a,r])=>`cubic-bezier(${n}, ${t}, ${a}, ${r})`,sv={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:fr([0,.65,.55,1]),circOut:fr([.55,0,1,.45]),backIn:fr([.31,.01,.66,-.59]),backOut:fr([.33,1.53,.69,.99])};function l1(n,t){if(n)return typeof n=="function"?o1()?e1(n,t):"ease-out":Fb(n)?fr(n):Array.isArray(n)?n.map(a=>l1(a,t)||sv.easeOut):sv[n]}function UC(n,t,a,{delay:r=0,duration:l=300,repeat:c=0,repeatType:f="loop",ease:h="easeOut",times:m}={},p=void 0){const v={[t]:a};m&&(v.offset=m);const x=l1(h,l);Array.isArray(x)&&(v.easing=x);const S={delay:r,duration:l,easing:Array.isArray(x)?"linear":x,fill:"both",iterations:c+1,direction:f==="reverse"?"alternate":"normal"};return p&&(S.pseudoElement=p),n.animate(v,S)}function c1(n){return typeof n=="function"&&"applyToOptions"in n}function PC({type:n,...t}){return c1(n)&&o1()?n.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class u1 extends Sh{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:a,name:r,keyframes:l,pseudoElement:c,allowFlatten:f=!1,finalKeyframe:h,onComplete:m}=t;this.isPseudoElement=!!c,this.allowFlatten=f,this.options=t,dh(typeof t.type!="string");const p=PC(t);this.animation=UC(a,r,l,p,c),p.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!c){const v=Wl(l,this.options,h,this.speed);this.updateMotionValue&&this.updateMotionValue(v),s1(a,r,v),this.animation.cancel()}m==null||m(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,a;(a=(t=this.animation).finish)==null||a.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var a,r,l;const t=(a=this.options)==null?void 0:a.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((l=(r=this.animation).commitStyles)==null||l.call(r))}get duration(){var a,r;const t=((r=(a=this.animation.effect)==null?void 0:a.getComputedTiming)==null?void 0:r.call(a).duration)||0;return Qt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Qt(t)}get time(){return Qt(Number(this.animation.currentTime)||0)}set time(t){const a=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pt(t),a&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:a,rangeEnd:r,observe:l}){var c;return this.allowFlatten&&((c=this.animation.effect)==null||c.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&BC()?(this.animation.timeline=t,a&&(this.animation.rangeStart=a),r&&(this.animation.rangeEnd=r),Jt):l(this)}}const f1={anticipate:Pb,backInOut:Ub,circInOut:Ib};function HC(n){return n in f1}function IC(n){typeof n.ease=="string"&&HC(n.ease)&&(n.ease=f1[n.ease])}const qf=10;class qC extends u1{constructor(t){IC(t),n1(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:a,onUpdate:r,onComplete:l,element:c,...f}=this.options;if(!a)return;if(t!==void 0){a.set(t);return}const h=new Cl({...f,autoplay:!1}),m=Math.max(qf,bt.now()-this.startTime),p=yn(0,qf,m-qf),v=h.sample(m).value,{name:x}=this.options;c&&x&&s1(c,x,v),a.setWithVelocity(h.sample(Math.max(0,m-p)).value,v,p),h.stop()}}const rv=(n,t)=>t==="zIndex"?!1:!!(typeof n=="number"||Array.isArray(n)||typeof n=="string"&&(on.test(n)||n==="0")&&!n.startsWith("url("));function FC(n){const t=n[0];if(n.length===1)return!0;for(let a=0;aObject.hasOwnProperty.call(Element.prototype,"animate"));function ZC(n){var x;const{motionValue:t,name:a,repeatDelay:r,repeatType:l,damping:c,type:f,keyframes:h}=n;if(!(((x=t==null?void 0:t.owner)==null?void 0:x.current)instanceof HTMLElement))return!1;const{onUpdate:p,transformTemplate:v}=t.owner.getProps();return $C()&&a&&(d1.has(a)||XC.has(a)&&KC(h))&&(a!=="transform"||!v)&&!p&&!r&&l!=="mirror"&&c!==0&&f!=="inertia"}const QC=40;class WC extends Sh{constructor({autoplay:t=!0,delay:a=0,type:r="keyframes",repeat:l=0,repeatDelay:c=0,repeatType:f="loop",keyframes:h,name:m,motionValue:p,element:v,...x}){var T;super(),this.stop=()=>{var k,z;this._animation&&(this._animation.stop(),(k=this.stopTimeline)==null||k.call(this)),(z=this.keyframeResolver)==null||z.cancel()},this.createdAt=bt.now();const S={autoplay:t,delay:a,type:r,repeat:l,repeatDelay:c,repeatType:f,name:m,motionValue:p,element:v,...x},w=(v==null?void 0:v.KeyframeResolver)||wh;this.keyframeResolver=new w(h,(k,z,B)=>this.onKeyframesResolved(k,z,S,!B),m,p,v),(T=this.keyframeResolver)==null||T.scheduleResolve()}onKeyframesResolved(t,a,r,l){var B,I;this.keyframeResolver=void 0;const{name:c,type:f,velocity:h,delay:m,isHandoff:p,onUpdate:v}=r;this.resolvedAt=bt.now();let x=!0;GC(t,c,f,h)||(x=!1,(bi.instantAnimations||!m)&&(v==null||v(Wl(t,r,a))),t[0]=t[t.length-1],Md(r),r.repeat=0);const w={startTime:l?this.resolvedAt?this.resolvedAt-this.createdAt>QC?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:a,...r,keyframes:t},T=x&&!p&&ZC(w),k=(I=(B=w.motionValue)==null?void 0:B.owner)==null?void 0:I.current;let z;if(T)try{z=new qC({...w,element:k})}catch{z=new Cl(w)}else z=new Cl(w);z.finished.then(()=>{this.notifyFinished()}).catch(Jt),this.pendingTimeline&&(this.stopTimeline=z.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=z}get finished(){return this._animation?this.animation.finished:this._finished}then(t,a){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),LC()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function h1(n,t,a,r=0,l=1){const c=Array.from(n).sort((p,v)=>p.sortNodePosition(v)).indexOf(t),f=n.size,h=(f-1)*r;return typeof a=="function"?a(c,f):l===1?c*r:h-c*r}const JC=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ej(n){const t=JC.exec(n);if(!t)return[,];const[,a,r,l]=t;return[`--${a??r}`,l]}function m1(n,t,a=1){const[r,l]=ej(n);if(!r)return;const c=window.getComputedStyle(t).getPropertyValue(r);if(c){const f=c.trim();return jb(f)?parseFloat(f):f}return gh(l)?m1(l,t,a+1):l}const tj={type:"spring",stiffness:500,damping:25,restSpeed:10},nj=n=>({type:"spring",stiffness:550,damping:n===0?2*Math.sqrt(550):30,restSpeed:10}),ij={type:"keyframes",duration:.8},aj={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},sj=(n,{keyframes:t})=>t.length>2?ij:us.has(n)?n.startsWith("scale")?nj(t[1]):tj:aj;function p1(n,t){if(n!=null&&n.inherit&&t){const{inherit:a,...r}=n;return{...t,...r}}return n}function _h(n,t){const a=(n==null?void 0:n[t])??(n==null?void 0:n.default)??n;return a!==n?p1(a,n):a}const rj=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function oj(n){for(const t in n)if(!rj.has(t))return!0;return!1}const Th=(n,t,a,r={},l,c)=>f=>{const h=_h(r,n)||{},m=h.delay||r.delay||0;let{elapsed:p=0}=r;p=p-Pt(m);const v={keyframes:Array.isArray(a)?a:[null,a],ease:"easeOut",velocity:t.getVelocity(),...h,delay:-p,onUpdate:S=>{t.set(S),h.onUpdate&&h.onUpdate(S)},onComplete:()=>{f(),h.onComplete&&h.onComplete()},name:n,motionValue:t,element:c?void 0:l};oj(h)||Object.assign(v,sj(n,v)),v.duration&&(v.duration=Pt(v.duration)),v.repeatDelay&&(v.repeatDelay=Pt(v.repeatDelay)),v.from!==void 0&&(v.keyframes[0]=v.from);let x=!1;if((v.type===!1||v.duration===0&&!v.repeatDelay)&&(Md(v),v.delay===0&&(x=!0)),(bi.instantAnimations||bi.skipAnimations||l!=null&&l.shouldSkipAnimations)&&(x=!0,Md(v),v.delay=0),v.allowFlatten=!h.type&&!h.ease,x&&!c&&t.get()!==void 0){const S=Wl(v.keyframes,h);if(S!==void 0){Ve.update(()=>{v.onUpdate(S),v.onComplete()});return}}return h.isSync?new Cl(v):new WC(v)};function ov(n){const t=[{},{}];return n==null||n.values.forEach((a,r)=>{t[0][r]=a.get(),t[1][r]=a.getVelocity()}),t}function Eh(n,t,a,r){if(typeof t=="function"){const[l,c]=ov(r);t=t(a!==void 0?a:n.custom,l,c)}if(typeof t=="string"&&(t=n.variants&&n.variants[t]),typeof t=="function"){const[l,c]=ov(r);t=t(a!==void 0?a:n.custom,l,c)}return t}function Qi(n,t,a){const r=n.getProps();return Eh(r,t,a!==void 0?a:r.custom,n)}const g1=new Set(["width","height","top","left","right","bottom",...cs]),lv=30,lj=n=>!isNaN(parseFloat(n));class cj{constructor(t,a={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var c;const l=bt.now();if(this.updatedAt!==l&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((c=this.events.change)==null||c.notify(this.current),this.dependents))for(const f of this.dependents)f.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=a.owner}setCurrent(t){this.current=t,this.updatedAt=bt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=lj(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,a){this.events[t]||(this.events[t]=new hh);const r=this.events[t].add(a);return t==="change"?()=>{r(),Ve.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,a){this.passiveEffect=t,this.stopPassiveEffect=a}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,a,r){this.set(a),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,a=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,a&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=bt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>lv)return 0;const a=Math.min(this.updatedAt-this.prevUpdatedAt,lv);return kb(parseFloat(this.current)-parseFloat(this.prevFrameValue),a)}start(t){return this.stop(),new Promise(a=>{this.hasAnimated=!0,this.animation=t(a),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,a;(t=this.dependents)==null||t.clear(),(a=this.events.destroy)==null||a.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function is(n,t){return new cj(n,t)}const Od=n=>Array.isArray(n);function uj(n,t,a){n.hasValue(t)?n.getValue(t).set(a):n.addValue(t,is(a))}function fj(n){return Od(n)?n[n.length-1]||0:n}function dj(n,t){const a=Qi(n,t);let{transitionEnd:r={},transition:l={},...c}=a||{};c={...c,...r};for(const f in c){const h=fj(c[f]);uj(n,f,h)}}const ht=n=>!!(n&&n.getVelocity);function hj(n){return!!(ht(n)&&n.add)}function Rd(n,t){const a=n.getValue("willChange");if(hj(a))return a.add(t);if(!a&&bi.WillChange){const r=new bi.WillChange("auto");n.addValue("willChange",r),r.add(t)}}function Ah(n){return n.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const mj="framerAppearId",y1="data-"+Ah(mj);function v1(n){return n.props[y1]}function pj({protectedKeys:n,needsAnimating:t},a){const r=n.hasOwnProperty(a)&&t[a]!==!0;return t[a]=!1,r}function x1(n,t,{delay:a=0,transitionOverride:r,type:l}={}){let{transition:c,transitionEnd:f,...h}=t;const m=n.getDefaultTransition();c=c?p1(c,m):m;const p=c==null?void 0:c.reduceMotion;r&&(c=r);const v=[],x=l&&n.animationState&&n.animationState.getState()[l];for(const S in h){const w=n.getValue(S,n.latestValues[S]??null),T=h[S];if(T===void 0||x&&pj(x,S))continue;const k={delay:a,..._h(c||{},S)},z=w.get();if(z!==void 0&&!w.isAnimating()&&!Array.isArray(T)&&T===z&&!k.velocity){Ve.update(()=>w.set(T));continue}let B=!1;if(window.MotionHandoffAnimation){const F=v1(n);if(F){const $=window.MotionHandoffAnimation(F,S,Ve);$!==null&&(k.startTime=$,B=!0)}}Rd(n,S);const I=p??n.shouldReduceMotion;w.start(Th(S,w,T,I&&g1.has(S)?{type:!1}:k,n,B));const H=w.animation;H&&v.push(H)}if(f){const S=()=>Ve.update(()=>{f&&dj(n,f)});v.length?Promise.all(v).then(S):S()}return v}function kd(n,t,a={}){var m;const r=Qi(n,t,a.type==="exit"?(m=n.presenceContext)==null?void 0:m.custom:void 0);let{transition:l=n.getDefaultTransition()||{}}=r||{};a.transitionOverride&&(l=a.transitionOverride);const c=r?()=>Promise.all(x1(n,r,a)):()=>Promise.resolve(),f=n.variantChildren&&n.variantChildren.size?(p=0)=>{const{delayChildren:v=0,staggerChildren:x,staggerDirection:S}=l;return gj(n,t,p,v,x,S,a)}:()=>Promise.resolve(),{when:h}=l;if(h){const[p,v]=h==="beforeChildren"?[c,f]:[f,c];return p().then(()=>v())}else return Promise.all([c(),f(a.delay)])}function gj(n,t,a=0,r=0,l=0,c=1,f){const h=[];for(const m of n.variantChildren)m.notify("AnimationStart",t),h.push(kd(m,t,{...f,delay:a+(typeof r=="function"?0:r)+h1(n.variantChildren,m,r,l,c)}).then(()=>m.notify("AnimationComplete",t)));return Promise.all(h)}function yj(n,t,a={}){n.notify("AnimationStart",t);let r;if(Array.isArray(t)){const l=t.map(c=>kd(n,c,a));r=Promise.all(l)}else if(typeof t=="string")r=kd(n,t,a);else{const l=typeof t=="function"?Qi(n,t,a.custom):t;r=Promise.all(x1(n,l,a))}return r.then(()=>{n.notify("AnimationComplete",t)})}const vj={test:n=>n==="auto",parse:n=>n},b1=n=>t=>t.test(n),S1=[ls,W,pn,mi,FD,qD,vj],cv=n=>S1.find(b1(n));function xj(n){return typeof n=="number"?n===0:n!==null?n==="none"||n==="0"||Ob(n):!0}const bj=new Set(["brightness","contrast","saturate","opacity"]);function Sj(n){const[t,a]=n.slice(0,-1).split("(");if(t==="drop-shadow")return n;const[r]=a.match(yh)||[];if(!r)return n;const l=a.replace(r,"");let c=bj.has(t)?1:0;return r!==a&&(c*=100),t+"("+c+l+")"}const wj=/\b([a-z-]*)\(.*?\)/gu,Ld={...on,getAnimatableNone:n=>{const t=n.match(wj);return t?t.map(Sj).join(" "):n}},zd={...on,getAnimatableNone:n=>{const t=on.parse(n);return on.createTransformer(n)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},uv={...ls,transform:Math.round},_j={rotate:mi,rotateX:mi,rotateY:mi,rotateZ:mi,scale:al,scaleX:al,scaleY:al,scaleZ:al,skew:mi,skewX:mi,skewY:mi,distance:W,translateX:W,translateY:W,translateZ:W,x:W,y:W,z:W,perspective:W,transformPerspective:W,opacity:wr,originX:Z0,originY:Z0,originZ:W},Nh={borderWidth:W,borderTopWidth:W,borderRightWidth:W,borderBottomWidth:W,borderLeftWidth:W,borderRadius:W,borderTopLeftRadius:W,borderTopRightRadius:W,borderBottomRightRadius:W,borderBottomLeftRadius:W,width:W,maxWidth:W,height:W,maxHeight:W,top:W,right:W,bottom:W,left:W,inset:W,insetBlock:W,insetBlockStart:W,insetBlockEnd:W,insetInline:W,insetInlineStart:W,insetInlineEnd:W,padding:W,paddingTop:W,paddingRight:W,paddingBottom:W,paddingLeft:W,paddingBlock:W,paddingBlockStart:W,paddingBlockEnd:W,paddingInline:W,paddingInlineStart:W,paddingInlineEnd:W,margin:W,marginTop:W,marginRight:W,marginBottom:W,marginLeft:W,marginBlock:W,marginBlockStart:W,marginBlockEnd:W,marginInline:W,marginInlineStart:W,marginInlineEnd:W,fontSize:W,backgroundPositionX:W,backgroundPositionY:W,..._j,zIndex:uv,fillOpacity:wr,strokeOpacity:wr,numOctaves:uv},Tj={...Nh,color:nt,backgroundColor:nt,outlineColor:nt,fill:nt,stroke:nt,borderColor:nt,borderTopColor:nt,borderRightColor:nt,borderBottomColor:nt,borderLeftColor:nt,filter:Ld,WebkitFilter:Ld,mask:zd,WebkitMask:zd},w1=n=>Tj[n],Ej=new Set([Ld,zd]);function _1(n,t){let a=w1(n);return Ej.has(a)||(a=on),a.getAnimatableNone?a.getAnimatableNone(t):void 0}const Aj=new Set(["auto","none","0"]);function Nj(n,t,a){let r=0,l;for(;r{t.getValue(m).set(p)}),this.resolveNoneKeyframes()}}function T1(n,t,a){if(n==null)return[];if(n instanceof EventTarget)return[n];if(typeof n=="string"){let r=document;const l=(a==null?void 0:a[n])??r.querySelectorAll(n);return l?Array.from(l):[]}return Array.from(n).filter(r=>r!=null)}const E1=(n,t)=>t&&typeof n=="number"?t.transform(n):n;function Cj(n){return Mb(n)&&"offsetHeight"in n&&!("ownerSVGElement"in n)}const{schedule:Dh}=Gb(queueMicrotask,!1),sn={x:!1,y:!1};function A1(){return sn.x||sn.y}function jj(n){return n==="x"||n==="y"?sn[n]?null:(sn[n]=!0,()=>{sn[n]=!1}):sn.x||sn.y?null:(sn.x=sn.y=!0,()=>{sn.x=sn.y=!1})}function N1(n,t){const a=T1(n),r=new AbortController,l={passive:!0,...t,signal:r.signal};return[a,l,()=>r.abort()]}function Mj(n){return!(n.pointerType==="touch"||A1())}function Oj(n,t,a={}){const[r,l,c]=N1(n,a);return r.forEach(f=>{let h=!1,m=!1,p;const v=()=>{f.removeEventListener("pointerleave",T)},x=z=>{p&&(p(z),p=void 0),v()},S=z=>{h=!1,window.removeEventListener("pointerup",S),window.removeEventListener("pointercancel",S),m&&(m=!1,x(z))},w=()=>{h=!0,window.addEventListener("pointerup",S,l),window.addEventListener("pointercancel",S,l)},T=z=>{if(z.pointerType!=="touch"){if(h){m=!0;return}x(z)}},k=z=>{if(!Mj(z))return;m=!1;const B=t(f,z);typeof B=="function"&&(p=B,f.addEventListener("pointerleave",T,l))};f.addEventListener("pointerenter",k,l),f.addEventListener("pointerdown",w,l)}),c}const D1=(n,t)=>t?n===t?!0:D1(n,t.parentElement):!1,Ch=n=>n.pointerType==="mouse"?typeof n.button!="number"||n.button<=0:n.isPrimary!==!1,Rj=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function kj(n){return Rj.has(n.tagName)||n.isContentEditable===!0}const Lj=new Set(["INPUT","SELECT","TEXTAREA"]);function zj(n){return Lj.has(n.tagName)||n.isContentEditable===!0}const ml=new WeakSet;function fv(n){return t=>{t.key==="Enter"&&n(t)}}function Ff(n,t){n.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Vj=(n,t)=>{const a=n.currentTarget;if(!a)return;const r=fv(()=>{if(ml.has(a))return;Ff(a,"down");const l=fv(()=>{Ff(a,"up")}),c=()=>Ff(a,"cancel");a.addEventListener("keyup",l,t),a.addEventListener("blur",c,t)});a.addEventListener("keydown",r,t),a.addEventListener("blur",()=>a.removeEventListener("keydown",r),t)};function dv(n){return Ch(n)&&!A1()}const hv=new WeakSet;function Bj(n,t,a={}){const[r,l,c]=N1(n,a),f=h=>{const m=h.currentTarget;if(!dv(h)||hv.has(h))return;ml.add(m),a.stopPropagation&&hv.add(h);const p=t(m,h),v=(w,T)=>{window.removeEventListener("pointerup",x),window.removeEventListener("pointercancel",S),ml.has(m)&&ml.delete(m),dv(w)&&typeof p=="function"&&p(w,{success:T})},x=w=>{v(w,m===window||m===document||a.useGlobalTarget||D1(m,w.target))},S=w=>{v(w,!1)};window.addEventListener("pointerup",x,l),window.addEventListener("pointercancel",S,l)};return r.forEach(h=>{(a.useGlobalTarget?window:h).addEventListener("pointerdown",f,l),Cj(h)&&(h.addEventListener("focus",p=>Vj(p,l)),!kj(h)&&!h.hasAttribute("tabindex")&&(h.tabIndex=0))}),c}function jh(n){return Mb(n)&&"ownerSVGElement"in n}const pl=new WeakMap;let pi;const C1=(n,t,a)=>(r,l)=>l&&l[0]?l[0][n+"Size"]:jh(r)&&"getBBox"in r?r.getBBox()[t]:r[a],Uj=C1("inline","width","offsetWidth"),Pj=C1("block","height","offsetHeight");function Hj({target:n,borderBoxSize:t}){var a;(a=pl.get(n))==null||a.forEach(r=>{r(n,{get width(){return Uj(n,t)},get height(){return Pj(n,t)}})})}function Ij(n){n.forEach(Hj)}function qj(){typeof ResizeObserver>"u"||(pi=new ResizeObserver(Ij))}function Fj(n,t){pi||qj();const a=T1(n);return a.forEach(r=>{let l=pl.get(r);l||(l=new Set,pl.set(r,l)),l.add(t),pi==null||pi.observe(r)}),()=>{a.forEach(r=>{const l=pl.get(r);l==null||l.delete(t),l!=null&&l.size||pi==null||pi.unobserve(r)})}}const gl=new Set;let Xa;function Gj(){Xa=()=>{const n={get width(){return window.innerWidth},get height(){return window.innerHeight}};gl.forEach(t=>t(n))},window.addEventListener("resize",Xa)}function Yj(n){return gl.add(n),Xa||Gj(),()=>{gl.delete(n),!gl.size&&typeof Xa=="function"&&(window.removeEventListener("resize",Xa),Xa=void 0)}}function mv(n,t){return typeof n=="function"?Yj(n):Fj(n,t)}function Kj(n){return jh(n)&&n.tagName==="svg"}const Xj=[...S1,nt,on],$j=n=>Xj.find(b1(n)),pv=()=>({translate:0,scale:1,origin:0,originPoint:0}),$a=()=>({x:pv(),y:pv()}),gv=()=>({min:0,max:0}),at=()=>({x:gv(),y:gv()}),Zj=new WeakMap;function Jl(n){return n!==null&&typeof n=="object"&&typeof n.start=="function"}function _r(n){return typeof n=="string"||Array.isArray(n)}const Mh=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Oh=["initial",...Mh];function ec(n){return Jl(n.animate)||Oh.some(t=>_r(n[t]))}function j1(n){return!!(ec(n)||n.variants)}function Qj(n,t,a){for(const r in t){const l=t[r],c=a[r];if(ht(l))n.addValue(r,l);else if(ht(c))n.addValue(r,is(l,{owner:n}));else if(c!==l)if(n.hasValue(r)){const f=n.getValue(r);f.liveStyle===!0?f.jump(l):f.hasAnimated||f.set(l)}else{const f=n.getStaticValue(r);n.addValue(r,is(f!==void 0?f:l,{owner:n}))}}for(const r in a)t[r]===void 0&&n.removeValue(r);return t}const Vd={current:null},M1={current:!1},Wj=typeof window<"u";function Jj(){if(M1.current=!0,!!Wj)if(window.matchMedia){const n=window.matchMedia("(prefers-reduced-motion)"),t=()=>Vd.current=n.matches;n.addEventListener("change",t),t()}else Vd.current=!1}const yv=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let jl={};function O1(n){jl=n}function e5(){return jl}class t5{scrapeMotionValuesFromProps(t,a,r){return{}}constructor({parent:t,props:a,presenceContext:r,reducedMotionConfig:l,skipAnimations:c,blockInitialAnimation:f,visualState:h},m={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=wh,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const w=bt.now();this.renderScheduledAtthis.bindToMotionValue(c,l)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(M1.current||Jj(),this.shouldReduceMotion=Vd.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Si(this.notifyUpdate),Si(this.render),this.valueSubscriptions.forEach(a=>a()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const a in this.events)this.events[a].clear();for(const a in this.features){const r=this.features[a];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,a){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),a.accelerate&&d1.has(t)&&this.current instanceof HTMLElement){const{factory:f,keyframes:h,times:m,ease:p,duration:v}=a.accelerate,x=new u1({element:this.current,name:t,keyframes:h,times:m,ease:p,duration:Pt(v)}),S=f(x);this.valueSubscriptions.set(t,()=>{S(),x.cancel()});return}const r=us.has(t);r&&this.onBindTransform&&this.onBindTransform();const l=a.on("change",f=>{this.latestValues[t]=f,this.props.onUpdate&&Ve.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let c;typeof window<"u"&&window.MotionCheckAppearSync&&(c=window.MotionCheckAppearSync(this,t,a)),this.valueSubscriptions.set(t,()=>{l(),c&&c(),a.owner&&a.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in jl){const a=jl[t];if(!a)continue;const{isEnabled:r,Feature:l}=a;if(!this.features[t]&&l&&r(this.props)&&(this.features[t]=new l(this)),this.features[t]){const c=this.features[t];c.isMounted?c.update():(c.mount(),c.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):at()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,a){this.latestValues[t]=a}update(t,a){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=a;for(let r=0;ra.variantChildren.delete(t)}addValue(t,a){const r=this.values.get(t);a!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,a),this.values.set(t,a),this.latestValues[t]=a.get())}removeValue(t){this.values.delete(t);const a=this.valueSubscriptions.get(t);a&&(a(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,a){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&a!==void 0&&(r=is(a===null?void 0:a,{owner:this}),this.addValue(t,r)),r}readValue(t,a){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(jb(r)||Ob(r))?r=parseFloat(r):!$j(r)&&on.test(a)&&(r=_1(t,a)),this.setBaseTarget(t,ht(r)?r.get():r)),ht(r)?r.get():r}setBaseTarget(t,a){this.baseTarget[t]=a}getBaseTarget(t){var c;const{initial:a}=this.props;let r;if(typeof a=="string"||typeof a=="object"){const f=Eh(this.props,a,(c=this.presenceContext)==null?void 0:c.custom);f&&(r=f[t])}if(a&&r!==void 0)return r;const l=this.getBaseTargetFromProps(this.props,t);return l!==void 0&&!ht(l)?l:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,a){return this.events[t]||(this.events[t]=new hh),this.events[t].add(a)}notify(t,...a){this.events[t]&&this.events[t].notify(...a)}scheduleRenderMicrotask(){Dh.render(this.render)}}class R1 extends t5{constructor(){super(...arguments),this.KeyframeResolver=Dj}sortInstanceNodePosition(t,a){return t.compareDocumentPosition(a)&2?1:-1}getBaseTargetFromProps(t,a){const r=t.style;return r?r[a]:void 0}removeValueFromRenderState(t,{vars:a,style:r}){delete a[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ht(t)&&(this.childSubscription=t.on("change",a=>{this.current&&(this.current.textContent=`${a}`)}))}}class _i{constructor(t){this.isMounted=!1,this.node=t}update(){}}function k1({top:n,left:t,right:a,bottom:r}){return{x:{min:t,max:a},y:{min:n,max:r}}}function n5({x:n,y:t}){return{top:t.min,right:n.max,bottom:t.max,left:n.min}}function i5(n,t){if(!t)return n;const a=t({x:n.left,y:n.top}),r=t({x:n.right,y:n.bottom});return{top:a.y,left:a.x,bottom:r.y,right:r.x}}function Gf(n){return n===void 0||n===1}function Bd({scale:n,scaleX:t,scaleY:a}){return!Gf(n)||!Gf(t)||!Gf(a)}function Gi(n){return Bd(n)||L1(n)||n.z||n.rotate||n.rotateX||n.rotateY||n.skewX||n.skewY}function L1(n){return vv(n.x)||vv(n.y)}function vv(n){return n&&n!=="0%"}function Ml(n,t,a){const r=n-a,l=t*r;return a+l}function xv(n,t,a,r,l){return l!==void 0&&(n=Ml(n,l,r)),Ml(n,a,r)+t}function Ud(n,t=0,a=1,r,l){n.min=xv(n.min,t,a,r,l),n.max=xv(n.max,t,a,r,l)}function z1(n,{x:t,y:a}){Ud(n.x,t.translate,t.scale,t.originPoint),Ud(n.y,a.translate,a.scale,a.originPoint)}const bv=.999999999999,Sv=1.0000000000001;function a5(n,t,a,r=!1){var h;const l=a.length;if(!l)return;t.x=t.y=1;let c,f;for(let m=0;mbv&&(t.x=1),t.ybv&&(t.y=1)}function hn(n,t){n.min+=t,n.max+=t}function wv(n,t,a,r,l=.5){const c=Pe(n.min,n.max,l);Ud(n,t,a,c,r)}function _v(n,t){return typeof n=="string"?parseFloat(n)/100*(t.max-t.min):n}function yl(n,t,a){const r=a??n;wv(n.x,_v(t.x,r.x),t.scaleX,t.scale,t.originX),wv(n.y,_v(t.y,r.y),t.scaleY,t.scale,t.originY)}function V1(n,t){return k1(i5(n.getBoundingClientRect(),t))}function s5(n,t,a){const r=V1(n,a),{scroll:l}=t;return l&&(hn(r.x,l.offset.x),hn(r.y,l.offset.y)),r}const r5={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},o5=cs.length;function l5(n,t,a){let r="",l=!0;for(let c=0;c{if(!t.target)return n;if(typeof n=="string")if(W.test(n))n=parseFloat(n);else return n;const a=Tv(n,t.target.x),r=Tv(n,t.target.y);return`${a}% ${r}%`}},c5={correct:(n,{treeScale:t,projectionDelta:a})=>{const r=n,l=on.parse(n);if(l.length>5)return r;const c=on.createTransformer(n),f=typeof l[0]!="number"?1:0,h=a.x.scale*t.x,m=a.y.scale*t.y;l[0+f]/=h,l[1+f]/=m;const p=Pe(h,m,.5);return typeof l[2+f]=="number"&&(l[2+f]/=p),typeof l[3+f]=="number"&&(l[3+f]/=p),c(l)}},Pd={borderRadius:{...or,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:or,borderTopRightRadius:or,borderBottomLeftRadius:or,borderBottomRightRadius:or,boxShadow:c5};function U1(n,{layout:t,layoutId:a}){return us.has(n)||n.startsWith("origin")||(t||a!==void 0)&&(!!Pd[n]||n==="opacity")}function kh(n,t,a){var f;const r=n.style,l=t==null?void 0:t.style,c={};if(!r)return c;for(const h in r)(ht(r[h])||l&&ht(l[h])||U1(h,n)||((f=a==null?void 0:a.getValue(h))==null?void 0:f.liveStyle)!==void 0)&&(c[h]=r[h]);return c}function u5(n){return window.getComputedStyle(n)}class f5 extends R1{constructor(){super(...arguments),this.type="html",this.renderInstance=B1}readValueFromInstance(t,a){var r;if(us.has(a))return(r=this.projection)!=null&&r.isProjecting?Ad(a):jC(t,a);{const l=u5(t),c=(Kb(a)?l.getPropertyValue(a):l[a])||0;return typeof c=="string"?c.trim():c}}measureInstanceViewportBox(t,{transformPagePoint:a}){return V1(t,a)}build(t,a,r){Rh(t,a,r.transformTemplate)}scrapeMotionValuesFromProps(t,a,r){return kh(t,a,r)}}const d5={offset:"stroke-dashoffset",array:"stroke-dasharray"},h5={offset:"strokeDashoffset",array:"strokeDasharray"};function m5(n,t,a=1,r=0,l=!0){n.pathLength=1;const c=l?d5:h5;n[c.offset]=`${-r}`,n[c.array]=`${t} ${a}`}const p5=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function P1(n,{attrX:t,attrY:a,attrScale:r,pathLength:l,pathSpacing:c=1,pathOffset:f=0,...h},m,p,v){if(Rh(n,h,p),m){n.style.viewBox&&(n.attrs.viewBox=n.style.viewBox);return}n.attrs=n.style,n.style={};const{attrs:x,style:S}=n;x.transform&&(S.transform=x.transform,delete x.transform),(S.transform||x.transformOrigin)&&(S.transformOrigin=x.transformOrigin??"50% 50%",delete x.transformOrigin),S.transform&&(S.transformBox=(v==null?void 0:v.transformBox)??"fill-box",delete x.transformBox);for(const w of p5)x[w]!==void 0&&(S[w]=x[w],delete x[w]);t!==void 0&&(x.x=t),a!==void 0&&(x.y=a),r!==void 0&&(x.scale=r),l!==void 0&&m5(x,l,c,f,!1)}const H1=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),I1=n=>typeof n=="string"&&n.toLowerCase()==="svg";function g5(n,t,a,r){B1(n,t,void 0,r);for(const l in t.attrs)n.setAttribute(H1.has(l)?l:Ah(l),t.attrs[l])}function q1(n,t,a){const r=kh(n,t,a);for(const l in n)if(ht(n[l])||ht(t[l])){const c=cs.indexOf(l)!==-1?"attr"+l.charAt(0).toUpperCase()+l.substring(1):l;r[c]=n[l]}return r}class y5 extends R1{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=at}getBaseTargetFromProps(t,a){return t[a]}readValueFromInstance(t,a){if(us.has(a)){const r=w1(a);return r&&r.default||0}return a=H1.has(a)?a:Ah(a),t.getAttribute(a)}scrapeMotionValuesFromProps(t,a,r){return q1(t,a,r)}build(t,a,r){P1(t,a,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,a,r,l){g5(t,a,r,l)}mount(t){this.isSVGTag=I1(t.tagName),super.mount(t)}}const v5=Oh.length;function F1(n){if(!n)return;if(!n.isControllingVariants){const a=n.parent?F1(n.parent)||{}:{};return n.props.initial!==void 0&&(a.initial=n.props.initial),a}const t={};for(let a=0;aPromise.all(t.map(({animation:a,options:r})=>yj(n,a,r)))}function w5(n){let t=S5(n),a=Ev(),r=!0,l=!1;const c=p=>(v,x)=>{var w;const S=Qi(n,x,p==="exit"?(w=n.presenceContext)==null?void 0:w.custom:void 0);if(S){const{transition:T,transitionEnd:k,...z}=S;v={...v,...z,...k}}return v};function f(p){t=p(n)}function h(p){const{props:v}=n,x=F1(n.parent)||{},S=[],w=new Set;let T={},k=1/0;for(let B=0;Bk&&$,X=!1;const we=Array.isArray(F)?F:[F];let Ae=we.reduce(c(I),{});he===!1&&(Ae={});const{prevResolvedValues:De={}}=H,_e={...De,...Ae},He=Y=>{ue=!0,w.has(Y)&&(X=!0,w.delete(Y)),H.needsAnimating[Y]=!0;const se=n.getValue(Y);se&&(se.liveStyle=!1)};for(const Y in _e){const se=Ae[Y],me=De[Y];if(T.hasOwnProperty(Y))continue;let A=!1;Od(se)&&Od(me)?A=!G1(se,me):A=se!==me,A?se!=null?He(Y):w.add(Y):se!==void 0&&w.has(Y)?He(Y):H.protectedKeys[Y]=!0}H.prevProp=F,H.prevResolvedValues=Ae,H.isActive&&(T={...T,...Ae}),(r||l)&&n.blockInitialAnimation&&(ue=!1);const O=J&&te;ue&&(!O||X)&&S.push(...we.map(Y=>{const se={type:I};if(typeof Y=="string"&&(r||l)&&!O&&n.manuallyAnimateOnMount&&n.parent){const{parent:me}=n,A=Qi(me,Y);if(me.enteringChildren&&A){const{delayChildren:V}=A.transition||{};se.delay=h1(me.enteringChildren,n,V)}}return{animation:Y,options:se}}))}if(w.size){const B={};if(typeof v.initial!="boolean"){const I=Qi(n,Array.isArray(v.initial)?v.initial[0]:v.initial);I&&I.transition&&(B.transition=I.transition)}w.forEach(I=>{const H=n.getBaseTarget(I),F=n.getValue(I);F&&(F.liveStyle=!0),B[I]=H??null}),S.push({animation:B})}let z=!!S.length;return r&&(v.initial===!1||v.initial===v.animate)&&!n.manuallyAnimateOnMount&&(z=!1),r=!1,l=!1,z?t(S):Promise.resolve()}function m(p,v){var S;if(a[p].isActive===v)return Promise.resolve();(S=n.variantChildren)==null||S.forEach(w=>{var T;return(T=w.animationState)==null?void 0:T.setActive(p,v)}),a[p].isActive=v;const x=h(p);for(const w in a)a[w].protectedKeys={};return x}return{animateChanges:h,setActive:m,setAnimateFunction:f,getState:()=>a,reset:()=>{a=Ev(),l=!0}}}function _5(n,t){return typeof t=="string"?t!==n:Array.isArray(t)?!G1(t,n):!1}function qi(n=!1){return{isActive:n,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ev(){return{animate:qi(!0),whileInView:qi(),whileHover:qi(),whileTap:qi(),whileDrag:qi(),whileFocus:qi(),exit:qi()}}function Hd(n,t){n.min=t.min,n.max=t.max}function an(n,t){Hd(n.x,t.x),Hd(n.y,t.y)}function Av(n,t){n.translate=t.translate,n.scale=t.scale,n.originPoint=t.originPoint,n.origin=t.origin}const Y1=1e-4,T5=1-Y1,E5=1+Y1,K1=.01,A5=0-K1,N5=0+K1;function St(n){return n.max-n.min}function D5(n,t,a){return Math.abs(n-t)<=a}function Nv(n,t,a,r=.5){n.origin=r,n.originPoint=Pe(t.min,t.max,n.origin),n.scale=St(a)/St(t),n.translate=Pe(a.min,a.max,n.origin)-n.originPoint,(n.scale>=T5&&n.scale<=E5||isNaN(n.scale))&&(n.scale=1),(n.translate>=A5&&n.translate<=N5||isNaN(n.translate))&&(n.translate=0)}function mr(n,t,a,r){Nv(n.x,t.x,a.x,r?r.originX:void 0),Nv(n.y,t.y,a.y,r?r.originY:void 0)}function Dv(n,t,a,r=0){const l=r?Pe(a.min,a.max,r):a.min;n.min=l+t.min,n.max=n.min+St(t)}function C5(n,t,a,r){Dv(n.x,t.x,a.x,r==null?void 0:r.x),Dv(n.y,t.y,a.y,r==null?void 0:r.y)}function Cv(n,t,a,r=0){const l=r?Pe(a.min,a.max,r):a.min;n.min=t.min-l,n.max=n.min+St(t)}function Ol(n,t,a,r){Cv(n.x,t.x,a.x,r==null?void 0:r.x),Cv(n.y,t.y,a.y,r==null?void 0:r.y)}function jv(n,t,a,r,l){return n-=t,n=Ml(n,1/a,r),l!==void 0&&(n=Ml(n,1/l,r)),n}function j5(n,t=0,a=1,r=.5,l,c=n,f=n){if(pn.test(t)&&(t=parseFloat(t),t=Pe(f.min,f.max,t/100)-f.min),typeof t!="number")return;let h=Pe(c.min,c.max,r);n===c&&(h-=t),n.min=jv(n.min,t,a,h,l),n.max=jv(n.max,t,a,h,l)}function Mv(n,t,[a,r,l],c,f){j5(n,t[a],t[r],t[l],t.scale,c,f)}const M5=["x","scaleX","originX"],O5=["y","scaleY","originY"];function Ov(n,t,a,r){Mv(n.x,t,M5,a?a.x:void 0,r?r.x:void 0),Mv(n.y,t,O5,a?a.y:void 0,r?r.y:void 0)}function Rv(n){return n.translate===0&&n.scale===1}function X1(n){return Rv(n.x)&&Rv(n.y)}function kv(n,t){return n.min===t.min&&n.max===t.max}function R5(n,t){return kv(n.x,t.x)&&kv(n.y,t.y)}function Lv(n,t){return Math.round(n.min)===Math.round(t.min)&&Math.round(n.max)===Math.round(t.max)}function $1(n,t){return Lv(n.x,t.x)&&Lv(n.y,t.y)}function zv(n){return St(n.x)/St(n.y)}function Vv(n,t){return n.translate===t.translate&&n.scale===t.scale&&n.originPoint===t.originPoint}function dn(n){return[n("x"),n("y")]}function k5(n,t,a){let r="";const l=n.x.translate/t.x,c=n.y.translate/t.y,f=(a==null?void 0:a.z)||0;if((l||c||f)&&(r=`translate3d(${l}px, ${c}px, ${f}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),a){const{transformPerspective:p,rotate:v,rotateX:x,rotateY:S,skewX:w,skewY:T}=a;p&&(r=`perspective(${p}px) ${r}`),v&&(r+=`rotate(${v}deg) `),x&&(r+=`rotateX(${x}deg) `),S&&(r+=`rotateY(${S}deg) `),w&&(r+=`skewX(${w}deg) `),T&&(r+=`skewY(${T}deg) `)}const h=n.x.scale*t.x,m=n.y.scale*t.y;return(h!==1||m!==1)&&(r+=`scale(${h}, ${m})`),r||"none"}const Z1=["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"],L5=Z1.length,Bv=n=>typeof n=="string"?parseFloat(n):n,Uv=n=>typeof n=="number"||W.test(n);function z5(n,t,a,r,l,c){l?(n.opacity=Pe(0,a.opacity??1,V5(r)),n.opacityExit=Pe(t.opacity??1,0,B5(r))):c&&(n.opacity=Pe(t.opacity??1,a.opacity??1,r));for(let f=0;frt?1:a(Sr(n,t,r))}function U5(n,t,a){const r=ht(n)?n:is(n);return r.start(Th("",r,t,a)),r.animation}function Tr(n,t,a,r={passive:!0}){return n.addEventListener(t,a,r),()=>n.removeEventListener(t,a)}const P5=(n,t)=>n.depth-t.depth;class H5{constructor(){this.children=[],this.isDirty=!1}add(t){fh(this.children,t),this.isDirty=!0}remove(t){El(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(P5),this.isDirty=!1,this.children.forEach(t)}}function I5(n,t){const a=bt.now(),r=({timestamp:l})=>{const c=l-a;c>=t&&(Si(r),n(c-t))};return Ve.setup(r,!0),()=>Si(r)}function vl(n){return ht(n)?n.get():n}class q5{constructor(){this.members=[]}add(t){fh(this.members,t);for(let a=this.members.length-1;a>=0;a--){const r=this.members[a];if(r===t||r===this.lead||r===this.prevLead)continue;const l=r.instance;(!l||l.isConnected===!1)&&!r.snapshot&&(El(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(El(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const a=this.members[this.members.length-1];a&&this.promote(a)}}relegate(t){var a;for(let r=this.members.indexOf(t)-1;r>=0;r--){const l=this.members[r];if(l.isPresent!==!1&&((a=l.instance)==null?void 0:a.isConnected)!==!1)return this.promote(l),!0}return!1}promote(t,a){var l;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:c}=r.options,{layoutDependency:f}=t.options;(c===void 0||c!==f)&&(t.resumeFrom=r,a&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(l=t.root)!=null&&l.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var a,r,l,c,f;(r=(a=t.options).onExitComplete)==null||r.call(a),(f=(l=t.resumingFrom)==null?void 0:(c=l.options).onExitComplete)==null||f.call(c)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const xl={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Yf=["","X","Y","Z"],F5=1e3;let G5=0;function Kf(n,t,a,r){const{latestValues:l}=t;l[n]&&(a[n]=l[n],t.setStaticValue(n,0),r&&(r[n]=0))}function W1(n){if(n.hasCheckedOptimisedAppear=!0,n.root===n)return;const{visualElement:t}=n.options;if(!t)return;const a=v1(t);if(window.MotionHasOptimisedAnimation(a,"transform")){const{layout:l,layoutId:c}=n.options;window.MotionCancelOptimisedAnimation(a,"transform",Ve,!(l||c))}const{parent:r}=n;r&&!r.hasCheckedOptimisedAppear&&W1(r)}function J1({attachResizeListener:n,defaultParent:t,measureScroll:a,checkIsScrollRoot:r,resetTransform:l}){return class{constructor(f={},h=t==null?void 0:t()){this.id=G5++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(X5),this.nodes.forEach(eM),this.nodes.forEach(tM),this.nodes.forEach($5)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=f,this.root=h?h.root||h:this,this.path=h?[...h.path,h]:[],this.parent=h,this.depth=h?h.depth+1:0;for(let m=0;mthis.root.updateBlockedByResize=!1;Ve.read(()=>{x=window.innerWidth}),n(f,()=>{const w=window.innerWidth;w!==x&&(x=w,this.root.updateBlockedByResize=!0,v&&v(),v=I5(S,250),xl.hasAnimatedSinceResize&&(xl.hasAnimatedSinceResize=!1,this.nodes.forEach(qv)))})}h&&this.root.registerSharedNode(h,this),this.options.animate!==!1&&p&&(h||m)&&this.addEventListener("didUpdate",({delta:v,hasLayoutChanged:x,hasRelativeLayoutChanged:S,layout:w})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const T=this.options.transition||p.getDefaultTransition()||rM,{onLayoutAnimationStart:k,onLayoutAnimationComplete:z}=p.getProps(),B=!this.targetLayout||!$1(this.targetLayout,w),I=!x&&S;if(this.options.layoutRoot||this.resumeFrom||I||x&&(B||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const H={..._h(T,"layout"),onPlay:k,onComplete:z};(p.shouldReduceMotion||this.options.layoutRoot)&&(H.delay=0,H.type=!1),this.startAnimation(H),this.setAnimationOrigin(v,I)}else x||qv(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=w})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const f=this.getStack();f&&f.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Si(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(nM),this.animationId++)}getTransformTemplate(){const{visualElement:f}=this.options;return f&&f.getProps().transformTemplate}willUpdate(f=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&W1(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let v=0;v{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!St(this.snapshot.measuredBox.x)&&!St(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let m=0;m{const $=F/1e3;Fv(x.x,f.x,$),Fv(x.y,f.y,$),this.setTargetDelta(x),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ol(S,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),aM(this.relativeTarget,this.relativeTargetOrigin,S,$),H&&R5(this.relativeTarget,H)&&(this.isProjectionDirty=!1),H||(H=at()),an(H,this.relativeTarget)),k&&(this.animationValues=v,z5(v,p,this.latestValues,$,I,B)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=$},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(f){var h,m,p;this.notifyListeners("animationStart"),(h=this.currentAnimation)==null||h.stop(),(p=(m=this.resumingFrom)==null?void 0:m.currentAnimation)==null||p.stop(),this.pendingAnimation&&(Si(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Ve.update(()=>{xl.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=is(0)),this.motionValue.jump(0,!1),this.currentAnimation=U5(this.motionValue,[0,1e3],{...f,velocity:0,isSync:!0,onUpdate:v=>{this.mixTargetDelta(v),f.onUpdate&&f.onUpdate(v)},onStop:()=>{},onComplete:()=>{f.onComplete&&f.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const f=this.getStack();f&&f.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(F5),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const f=this.getLead();let{targetWithTransforms:h,target:m,layout:p,latestValues:v}=f;if(!(!h||!m||!p)){if(this!==f&&this.layout&&p&&eS(this.options.animationType,this.layout.layoutBox,p.layoutBox)){m=this.target||at();const x=St(this.layout.layoutBox.x);m.x.min=f.target.x.min,m.x.max=m.x.min+x;const S=St(this.layout.layoutBox.y);m.y.min=f.target.y.min,m.y.max=m.y.min+S}an(h,m),yl(h,v),mr(this.projectionDeltaWithTransform,this.layoutCorrected,h,v)}}registerSharedNode(f,h){this.sharedNodes.has(f)||this.sharedNodes.set(f,new q5),this.sharedNodes.get(f).add(h);const p=h.options.initialPromotionConfig;h.promote({transition:p?p.transition:void 0,preserveFollowOpacity:p&&p.shouldPreserveFollowOpacity?p.shouldPreserveFollowOpacity(h):void 0})}isLead(){const f=this.getStack();return f?f.lead===this:!0}getLead(){var h;const{layoutId:f}=this.options;return f?((h=this.getStack())==null?void 0:h.lead)||this:this}getPrevLead(){var h;const{layoutId:f}=this.options;return f?(h=this.getStack())==null?void 0:h.prevLead:void 0}getStack(){const{layoutId:f}=this.options;if(f)return this.root.sharedNodes.get(f)}promote({needsReset:f,transition:h,preserveFollowOpacity:m}={}){const p=this.getStack();p&&p.promote(this,m),f&&(this.projectionDelta=void 0,this.needsReset=!0),h&&this.setOptions({transition:h})}relegate(){const f=this.getStack();return f?f.relegate(this):!1}resetSkewAndRotation(){const{visualElement:f}=this.options;if(!f)return;let h=!1;const{latestValues:m}=f;if((m.z||m.rotate||m.rotateX||m.rotateY||m.rotateZ||m.skewX||m.skewY)&&(h=!0),!h)return;const p={};m.z&&Kf("z",f,p,this.animationValues);for(let v=0;v{var h;return(h=f.currentAnimation)==null?void 0:h.stop()}),this.root.nodes.forEach(Hv),this.root.sharedNodes.clear()}}}function Y5(n){n.updateLayout()}function K5(n){var a;const t=((a=n.resumeFrom)==null?void 0:a.snapshot)||n.snapshot;if(n.isLead()&&n.layout&&t&&n.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:l}=n.layout,{animationType:c}=n.options,f=t.source!==n.layout.source;if(c==="size")dn(x=>{const S=f?t.measuredBox[x]:t.layoutBox[x],w=St(S);S.min=r[x].min,S.max=S.min+w});else if(c==="x"||c==="y"){const x=c==="x"?"y":"x";Hd(f?t.measuredBox[x]:t.layoutBox[x],r[x])}else eS(c,t.layoutBox,r)&&dn(x=>{const S=f?t.measuredBox[x]:t.layoutBox[x],w=St(r[x]);S.max=S.min+w,n.relativeTarget&&!n.currentAnimation&&(n.isProjectionDirty=!0,n.relativeTarget[x].max=n.relativeTarget[x].min+w)});const h=$a();mr(h,r,t.layoutBox);const m=$a();f?mr(m,n.applyTransform(l,!0),t.measuredBox):mr(m,r,t.layoutBox);const p=!X1(h);let v=!1;if(!n.resumeFrom){const x=n.getClosestProjectingParent();if(x&&!x.resumeFrom){const{snapshot:S,layout:w}=x;if(S&&w){const T=n.options.layoutAnchor||void 0,k=at();Ol(k,t.layoutBox,S.layoutBox,T);const z=at();Ol(z,r,w.layoutBox,T),$1(k,z)||(v=!0),x.options.layoutRoot&&(n.relativeTarget=z,n.relativeTargetOrigin=k,n.relativeParent=x)}}}n.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:m,layoutDelta:h,hasLayoutChanged:p,hasRelativeLayoutChanged:v})}else if(n.isLead()){const{onExitComplete:r}=n.options;r&&r()}n.options.transition=void 0}function X5(n){n.parent&&(n.isProjecting()||(n.isProjectionDirty=n.parent.isProjectionDirty),n.isSharedProjectionDirty||(n.isSharedProjectionDirty=!!(n.isProjectionDirty||n.parent.isProjectionDirty||n.parent.isSharedProjectionDirty)),n.isTransformDirty||(n.isTransformDirty=n.parent.isTransformDirty))}function $5(n){n.isProjectionDirty=n.isSharedProjectionDirty=n.isTransformDirty=!1}function Z5(n){n.clearSnapshot()}function Hv(n){n.clearMeasurements()}function Q5(n){n.isLayoutDirty=!0,n.updateLayout()}function Iv(n){n.isLayoutDirty=!1}function W5(n){n.isAnimationBlocked&&n.layout&&!n.isLayoutDirty&&(n.snapshot=n.layout,n.isLayoutDirty=!0)}function J5(n){const{visualElement:t}=n.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),n.resetTransform()}function qv(n){n.finishAnimation(),n.targetDelta=n.relativeTarget=n.target=void 0,n.isProjectionDirty=!0}function eM(n){n.resolveTargetDelta()}function tM(n){n.calcProjection()}function nM(n){n.resetSkewAndRotation()}function iM(n){n.removeLeadSnapshot()}function Fv(n,t,a){n.translate=Pe(t.translate,0,a),n.scale=Pe(t.scale,1,a),n.origin=t.origin,n.originPoint=t.originPoint}function Gv(n,t,a,r){n.min=Pe(t.min,a.min,r),n.max=Pe(t.max,a.max,r)}function aM(n,t,a,r){Gv(n.x,t.x,a.x,r),Gv(n.y,t.y,a.y,r)}function sM(n){return n.animationValues&&n.animationValues.opacityExit!==void 0}const rM={duration:.45,ease:[.4,0,.1,1]},Yv=n=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(n),Kv=Yv("applewebkit/")&&!Yv("chrome/")?Math.round:Jt;function Xv(n){n.min=Kv(n.min),n.max=Kv(n.max)}function oM(n){Xv(n.x),Xv(n.y)}function eS(n,t,a){return n==="position"||n==="preserve-aspect"&&!D5(zv(t),zv(a),.2)}function lM(n){var t;return n!==n.root&&((t=n.scroll)==null?void 0:t.wasRoot)}const cM=J1({attachResizeListener:(n,t)=>Tr(n,"resize",t),measureScroll:()=>{var n,t;return{x:document.documentElement.scrollLeft||((n=document.body)==null?void 0:n.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Xf={current:void 0},tS=J1({measureScroll:n=>({x:n.scrollLeft,y:n.scrollTop}),defaultParent:()=>{if(!Xf.current){const n=new cM({});n.mount(window),n.setOptions({layoutScroll:!0}),Xf.current=n}return Xf.current},resetTransform:(n,t)=>{n.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:n=>window.getComputedStyle(n).position==="fixed"}),nS=K.createContext({transformPagePoint:n=>n,isStatic:!1,reducedMotion:"never"});function uM(n=!0){const t=K.useContext(uh);if(t===null)return[!0,null];const{isPresent:a,onExitComplete:r,register:l}=t,c=K.useId();K.useEffect(()=>{if(n)return l(c)},[n]);const f=K.useCallback(()=>n&&r&&r(c),[c,r,n]);return!a&&r?[!1,f]:[!0]}const iS=K.createContext({strict:!1}),$v={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Zv=!1;function fM(){if(Zv)return;const n={};for(const t in $v)n[t]={isEnabled:a=>$v[t].some(r=>!!a[r])};O1(n),Zv=!0}function aS(){return fM(),e5()}function dM(n){const t=aS();for(const a in n)t[a]={...t[a],...n[a]};O1(t)}const hM=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Rl(n){return n.startsWith("while")||n.startsWith("drag")&&n!=="draggable"||n.startsWith("layout")||n.startsWith("onTap")||n.startsWith("onPan")||n.startsWith("onLayout")||hM.has(n)}let sS=n=>!Rl(n);function mM(n){typeof n=="function"&&(sS=t=>t.startsWith("on")?!Rl(t):n(t))}try{mM(require("@emotion/is-prop-valid").default)}catch{}function pM(n,t,a){const r={};for(const l in n)l==="values"&&typeof n.values=="object"||ht(n[l])||(sS(l)||a===!0&&Rl(l)||!t&&!Rl(l)||n.draggable&&l.startsWith("onDrag"))&&(r[l]=n[l]);return r}const tc=K.createContext({});function gM(n,t){if(ec(n)){const{initial:a,animate:r}=n;return{initial:a===!1||_r(a)?a:void 0,animate:_r(r)?r:void 0}}return n.inherit!==!1?t:{}}function yM(n){const{initial:t,animate:a}=gM(n,K.useContext(tc));return K.useMemo(()=>({initial:t,animate:a}),[Qv(t),Qv(a)])}function Qv(n){return Array.isArray(n)?n.join(" "):n}const Lh=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function rS(n,t,a){for(const r in t)!ht(t[r])&&!U1(r,a)&&(n[r]=t[r])}function vM({transformTemplate:n},t){return K.useMemo(()=>{const a=Lh();return Rh(a,t,n),Object.assign({},a.vars,a.style)},[t])}function xM(n,t){const a=n.style||{},r={};return rS(r,a,n),Object.assign(r,vM(n,t)),r}function bM(n,t){const a={},r=xM(n,t);return n.drag&&n.dragListener!==!1&&(a.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=n.drag===!0?"none":`pan-${n.drag==="x"?"y":"x"}`),n.tabIndex===void 0&&(n.onTap||n.onTapStart||n.whileTap)&&(a.tabIndex=0),a.style=r,a}const oS=()=>({...Lh(),attrs:{}});function SM(n,t,a,r){const l=K.useMemo(()=>{const c=oS();return P1(c,t,I1(r),n.transformTemplate,n.style),{...c.attrs,style:{...c.style}}},[t]);if(n.style){const c={};rS(c,n.style,n),l.style={...c,...l.style}}return l}const wM=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function zh(n){return typeof n!="string"||n.includes("-")?!1:!!(wM.indexOf(n)>-1||/[A-Z]/u.test(n))}function _M(n,t,a,{latestValues:r},l,c=!1,f){const m=(f??zh(n)?SM:bM)(t,r,l,n),p=pM(t,typeof n=="string",c),v=n!==K.Fragment?{...p,...m,ref:a}:{},{children:x}=t,S=K.useMemo(()=>ht(x)?x.get():x,[x]);return K.createElement(n,{...v,children:S})}function TM({scrapeMotionValuesFromProps:n,createRenderState:t},a,r,l){return{latestValues:EM(a,r,l,n),renderState:t()}}function EM(n,t,a,r){const l={},c=r(n,{});for(const S in c)l[S]=vl(c[S]);let{initial:f,animate:h}=n;const m=ec(n),p=j1(n);t&&p&&!m&&n.inherit!==!1&&(f===void 0&&(f=t.initial),h===void 0&&(h=t.animate));let v=a?a.initial===!1:!1;v=v||f===!1;const x=v?h:f;if(x&&typeof x!="boolean"&&!Jl(x)){const S=Array.isArray(x)?x:[x];for(let w=0;w(t,a)=>{const r=K.useContext(tc),l=K.useContext(uh),c=()=>TM(n,t,r,l);return a?c():wD(c)},AM=lS({scrapeMotionValuesFromProps:kh,createRenderState:Lh}),NM=lS({scrapeMotionValuesFromProps:q1,createRenderState:oS}),DM=Symbol.for("motionComponentSymbol");function CM(n,t,a){const r=K.useRef(a);K.useInsertionEffect(()=>{r.current=a});const l=K.useRef(null);return K.useCallback(c=>{var h;c&&((h=n.onMount)==null||h.call(n,c));const f=r.current;if(typeof f=="function")if(c){const m=f(c);typeof m=="function"&&(l.current=m)}else l.current?(l.current(),l.current=null):f(c);else f&&(f.current=c);t&&(c?t.mount(c):t.unmount())},[t])}const cS=K.createContext({});function Ya(n){return n&&typeof n=="object"&&Object.prototype.hasOwnProperty.call(n,"current")}function jM(n,t,a,r,l,c){var H,F;const{visualElement:f}=K.useContext(tc),h=K.useContext(iS),m=K.useContext(uh),p=K.useContext(nS),v=p.reducedMotion,x=p.skipAnimations,S=K.useRef(null),w=K.useRef(!1);r=r||h.renderer,!S.current&&r&&(S.current=r(n,{visualState:t,parent:f,props:a,presenceContext:m,blockInitialAnimation:m?m.initial===!1:!1,reducedMotionConfig:v,skipAnimations:x,isSVG:c}),w.current&&S.current&&(S.current.manuallyAnimateOnMount=!0));const T=S.current,k=K.useContext(cS);T&&!T.projection&&l&&(T.type==="html"||T.type==="svg")&&MM(S.current,a,l,k);const z=K.useRef(!1);K.useInsertionEffect(()=>{T&&z.current&&T.update(a,m)});const B=a[y1],I=K.useRef(!!B&&typeof window<"u"&&!((H=window.MotionHandoffIsComplete)!=null&&H.call(window,B))&&((F=window.MotionHasOptimisedAnimation)==null?void 0:F.call(window,B)));return TD(()=>{w.current=!0,T&&(z.current=!0,window.MotionIsMounted=!0,T.updateFeatures(),T.scheduleRenderMicrotask(),I.current&&T.animationState&&T.animationState.animateChanges())}),K.useEffect(()=>{T&&(!I.current&&T.animationState&&T.animationState.animateChanges(),I.current&&(queueMicrotask(()=>{var $;($=window.MotionHandoffMarkAsComplete)==null||$.call(window,B)}),I.current=!1),T.enteringChildren=void 0)}),T}function MM(n,t,a,r){const{layoutId:l,layout:c,drag:f,dragConstraints:h,layoutScroll:m,layoutRoot:p,layoutAnchor:v,layoutCrossfade:x}=t;n.projection=new a(n.latestValues,t["data-framer-portal-id"]?void 0:uS(n.parent)),n.projection.setOptions({layoutId:l,layout:c,alwaysMeasureLayout:!!f||h&&Ya(h),visualElement:n,animationType:typeof c=="string"?c:"both",initialPromotionConfig:r,crossfade:x,layoutScroll:m,layoutRoot:p,layoutAnchor:v})}function uS(n){if(n)return n.options.allowProjection!==!1?n.projection:uS(n.parent)}function $f(n,{forwardMotionProps:t=!1,type:a}={},r,l){r&&dM(r);const c=a?a==="svg":zh(n),f=c?NM:AM;function h(p,v){let x;const S={...K.useContext(nS),...p,layoutId:OM(p)},{isStatic:w}=S,T=yM(p),k=f(p,w);if(!w&&typeof window<"u"){RM();const z=kM(S);x=z.MeasureLayout,T.visualElement=jM(n,k,S,l,z.ProjectionNode,c)}return g.jsxs(tc.Provider,{value:T,children:[x&&T.visualElement?g.jsx(x,{visualElement:T.visualElement,...S}):null,_M(n,p,CM(k,T.visualElement,v),k,w,t,c)]})}h.displayName=`motion.${typeof n=="string"?n:`create(${n.displayName??n.name??""})`}`;const m=K.forwardRef(h);return m[DM]=n,m}function OM({layoutId:n}){const t=K.useContext(Cb).id;return t&&n!==void 0?t+"-"+n:n}function RM(n,t){K.useContext(iS).strict}function kM(n){const t=aS(),{drag:a,layout:r}=t;if(!a&&!r)return{};const l={...a,...r};return{MeasureLayout:a!=null&&a.isEnabled(n)||r!=null&&r.isEnabled(n)?l.MeasureLayout:void 0,ProjectionNode:l.ProjectionNode}}function LM(n,t){if(typeof Proxy>"u")return $f;const a=new Map,r=(c,f)=>$f(c,f,n,t),l=(c,f)=>r(c,f);return new Proxy(l,{get:(c,f)=>f==="create"?r:(a.has(f)||a.set(f,$f(f,void 0,n,t)),a.get(f))})}const zM=(n,t)=>t.isSVG??zh(n)?new y5(t):new f5(t,{allowProjection:n!==K.Fragment});class VM extends _i{constructor(t){super(t),t.animationState||(t.animationState=w5(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Jl(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:a}=this.node.prevProps||{};t!==a&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let BM=0;class UM extends _i{constructor(){super(...arguments),this.id=BM++,this.isExitComplete=!1}update(){var c;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:a}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:f,custom:h}=this.node.getProps();if(typeof f=="string"){const m=Qi(this.node,f,h);if(m){const{transition:p,transitionEnd:v,...x}=m;for(const S in x)(c=this.node.getValue(S))==null||c.jump(x[S])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const l=this.node.animationState.setActive("exit",!t);a&&!t&&l.then(()=>{this.isExitComplete=!0,a(this.id)})}mount(){const{register:t,onExitComplete:a}=this.node.presenceContext||{};a&&a(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const PM={animation:{Feature:VM},exit:{Feature:UM}};function kr(n){return{point:{x:n.pageX,y:n.pageY}}}const HM=n=>t=>Ch(t)&&n(t,kr(t));function pr(n,t,a,r){return Tr(n,t,HM(a),r)}const fS=({current:n})=>n?n.ownerDocument.defaultView:null,Wv=(n,t)=>Math.abs(n-t);function IM(n,t){const a=Wv(n.x,t.x),r=Wv(n.y,t.y);return Math.sqrt(a**2+r**2)}const Jv=new Set(["auto","scroll"]);class dS{constructor(t,a,{transformPagePoint:r,contextWindow:l=window,dragSnapToOrigin:c=!1,distanceThreshold:f=3,element:h}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=w=>{this.handleScroll(w.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=sl(this.lastRawMoveEventInfo,this.transformPagePoint));const w=Zf(this.lastMoveEventInfo,this.history),T=this.startEvent!==null,k=IM(w.offset,{x:0,y:0})>=this.distanceThreshold;if(!T&&!k)return;const{point:z}=w,{timestamp:B}=dt;this.history.push({...z,timestamp:B});const{onStart:I,onMove:H}=this.handlers;T||(I&&I(this.lastMoveEvent,w),this.startEvent=this.lastMoveEvent),H&&H(this.lastMoveEvent,w)},this.handlePointerMove=(w,T)=>{this.lastMoveEvent=w,this.lastRawMoveEventInfo=T,this.lastMoveEventInfo=sl(T,this.transformPagePoint),Ve.update(this.updatePoint,!0)},this.handlePointerUp=(w,T)=>{this.end();const{onEnd:k,onSessionEnd:z,resumeAnimation:B}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&B&&B(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const I=Zf(w.type==="pointercancel"?this.lastMoveEventInfo:sl(T,this.transformPagePoint),this.history);this.startEvent&&k&&k(w,I),z&&z(w,I)},!Ch(t))return;this.dragSnapToOrigin=c,this.handlers=a,this.transformPagePoint=r,this.distanceThreshold=f,this.contextWindow=l||window;const m=kr(t),p=sl(m,this.transformPagePoint),{point:v}=p,{timestamp:x}=dt;this.history=[{...v,timestamp:x}];const{onSessionStart:S}=a;S&&S(t,Zf(p,this.history)),this.removeListeners=Mr(pr(this.contextWindow,"pointermove",this.handlePointerMove),pr(this.contextWindow,"pointerup",this.handlePointerUp),pr(this.contextWindow,"pointercancel",this.handlePointerUp)),h&&this.startScrollTracking(h)}startScrollTracking(t){let a=t.parentElement;for(;a;){const r=getComputedStyle(a);(Jv.has(r.overflowX)||Jv.has(r.overflowY))&&this.scrollPositions.set(a,{x:a.scrollLeft,y:a.scrollTop}),a=a.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const a=this.scrollPositions.get(t);if(!a)return;const r=t===window,l=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},c={x:l.x-a.x,y:l.y-a.y};c.x===0&&c.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=c.x,this.lastMoveEventInfo.point.y+=c.y):this.history.length>0&&(this.history[0].x-=c.x,this.history[0].y-=c.y),this.scrollPositions.set(t,l),Ve.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Si(this.updatePoint)}}function sl(n,t){return t?{point:t(n.point)}:n}function ex(n,t){return{x:n.x-t.x,y:n.y-t.y}}function Zf({point:n},t){return{point:n,delta:ex(n,hS(t)),offset:ex(n,qM(t)),velocity:FM(t,.1)}}function qM(n){return n[0]}function hS(n){return n[n.length-1]}function FM(n,t){if(n.length<2)return{x:0,y:0};let a=n.length-1,r=null;const l=hS(n);for(;a>=0&&(r=n[a],!(l.timestamp-r.timestamp>Pt(t)));)a--;if(!r)return{x:0,y:0};r===n[0]&&n.length>2&&l.timestamp-r.timestamp>Pt(t)*2&&(r=n[1]);const c=Qt(l.timestamp-r.timestamp);if(c===0)return{x:0,y:0};const f={x:(l.x-r.x)/c,y:(l.y-r.y)/c};return f.x===1/0&&(f.x=0),f.y===1/0&&(f.y=0),f}function GM(n,{min:t,max:a},r){return t!==void 0&&na&&(n=r?Pe(a,n,r.max):Math.min(n,a)),n}function tx(n,t,a){return{min:t!==void 0?n.min+t:void 0,max:a!==void 0?n.max+a-(n.max-n.min):void 0}}function YM(n,{top:t,left:a,bottom:r,right:l}){return{x:tx(n.x,a,l),y:tx(n.y,t,r)}}function nx(n,t){let a=t.min-n.min,r=t.max-n.max;return t.max-t.minr?a=Sr(t.min,t.max-r,n.min):r>l&&(a=Sr(n.min,n.max-l,t.min)),yn(0,1,a)}function $M(n,t){const a={};return t.min!==void 0&&(a.min=t.min-n.min),t.max!==void 0&&(a.max=t.max-n.min),a}const Id=.35;function ZM(n=Id){return n===!1?n=0:n===!0&&(n=Id),{x:ix(n,"left","right"),y:ix(n,"top","bottom")}}function ix(n,t,a){return{min:ax(n,t),max:ax(n,a)}}function ax(n,t){return typeof n=="number"?n:n[t]||0}const QM=new WeakMap;class WM{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=at(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:a=!1,distanceThreshold:r}={}){const{presenceContext:l}=this.visualElement;if(l&&l.isPresent===!1)return;const c=x=>{a&&this.snapToCursor(kr(x).point),this.stopAnimation()},f=(x,S)=>{const{drag:w,dragPropagation:T,onDragStart:k}=this.getProps();if(w&&!T&&(this.openDragLock&&this.openDragLock(),this.openDragLock=jj(w),!this.openDragLock))return;this.latestPointerEvent=x,this.latestPanInfo=S,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),dn(B=>{let I=this.getAxisMotionValue(B).get()||0;if(pn.test(I)){const{projection:H}=this.visualElement;if(H&&H.layout){const F=H.layout.layoutBox[B];F&&(I=St(F)*(parseFloat(I)/100))}}this.originPoint[B]=I}),k&&Ve.update(()=>k(x,S),!1,!0),Rd(this.visualElement,"transform");const{animationState:z}=this.visualElement;z&&z.setActive("whileDrag",!0)},h=(x,S)=>{this.latestPointerEvent=x,this.latestPanInfo=S;const{dragPropagation:w,dragDirectionLock:T,onDirectionLock:k,onDrag:z}=this.getProps();if(!w&&!this.openDragLock)return;const{offset:B}=S;if(T&&this.currentDirection===null){this.currentDirection=e3(B),this.currentDirection!==null&&k&&k(this.currentDirection);return}this.updateAxis("x",S.point,B),this.updateAxis("y",S.point,B),this.visualElement.render(),z&&Ve.update(()=>z(x,S),!1,!0)},m=(x,S)=>{this.latestPointerEvent=x,this.latestPanInfo=S,this.stop(x,S),this.latestPointerEvent=null,this.latestPanInfo=null},p=()=>{const{dragSnapToOrigin:x}=this.getProps();(x||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:v}=this.getProps();this.panSession=new dS(t,{onSessionStart:c,onStart:f,onMove:h,onSessionEnd:m,resumeAnimation:p},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:v,distanceThreshold:r,contextWindow:fS(this.visualElement),element:this.visualElement.current})}stop(t,a){const r=t||this.latestPointerEvent,l=a||this.latestPanInfo,c=this.isDragging;if(this.cancel(),!c||!l||!r)return;const{velocity:f}=l;this.startAnimation(f);const{onDragEnd:h}=this.getProps();h&&Ve.postRender(()=>h(r,l))}cancel(){this.isDragging=!1;const{projection:t,animationState:a}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),a&&a.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,a,r){const{drag:l}=this.getProps();if(!r||!rl(t,l,this.currentDirection))return;const c=this.getAxisMotionValue(t);let f=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(f=GM(f,this.constraints[t],this.elastic[t])),c.set(f)}resolveConstraints(){var c;const{dragConstraints:t,dragElastic:a}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(c=this.visualElement.projection)==null?void 0:c.layout,l=this.constraints;t&&Ya(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=YM(r.layoutBox,t):this.constraints=!1,this.elastic=ZM(a),l!==this.constraints&&!Ya(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&dn(f=>{this.constraints!==!1&&this.getAxisMotionValue(f)&&(this.constraints[f]=$M(r.layoutBox[f],this.constraints[f]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:a}=this.getProps();if(!t||!Ya(t))return!1;const r=t.current,{projection:l}=this.visualElement;if(!l||!l.layout)return!1;const c=s5(r,l.root,this.visualElement.getTransformPagePoint());let f=KM(l.layout.layoutBox,c);if(a){const h=a(n5(f));this.hasMutatedConstraints=!!h,h&&(f=k1(h))}return f}startAnimation(t){const{drag:a,dragMomentum:r,dragElastic:l,dragTransition:c,dragSnapToOrigin:f,onDragTransitionEnd:h}=this.getProps(),m=this.constraints||{},p=dn(v=>{if(!rl(v,a,this.currentDirection))return;let x=m&&m[v]||{};(f===!0||f===v)&&(x={min:0,max:0});const S=l?200:1e6,w=l?40:1e7,T={type:"inertia",velocity:r?t[v]:0,bounceStiffness:S,bounceDamping:w,timeConstant:750,restDelta:1,restSpeed:10,...c,...x};return this.startAxisValueAnimation(v,T)});return Promise.all(p).then(h)}startAxisValueAnimation(t,a){const r=this.getAxisMotionValue(t);return Rd(this.visualElement,t),r.start(Th(t,r,0,a,this.visualElement,!1))}stopAnimation(){dn(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const a=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),l=r[a];return l||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){dn(a=>{const{drag:r}=this.getProps();if(!rl(a,r,this.currentDirection))return;const{projection:l}=this.visualElement,c=this.getAxisMotionValue(a);if(l&&l.layout){const{min:f,max:h}=l.layout.layoutBox[a],m=c.get()||0;c.set(t[a]-Pe(f,h,.5)+m)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:a}=this.getProps(),{projection:r}=this.visualElement;if(!Ya(a)||!r||!this.constraints)return;this.stopAnimation();const l={x:0,y:0};dn(f=>{const h=this.getAxisMotionValue(f);if(h&&this.constraints!==!1){const m=h.get();l[f]=XM({min:m,max:m},this.constraints[f])}});const{transformTemplate:c}=this.visualElement.getProps();this.visualElement.current.style.transform=c?c({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),dn(f=>{if(!rl(f,t,null))return;const h=this.getAxisMotionValue(f),{min:m,max:p}=this.constraints[f];h.set(Pe(m,p,l[f]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;QM.set(this.visualElement,this);const t=this.visualElement.current,a=pr(t,"pointerdown",p=>{const{drag:v,dragListener:x=!0}=this.getProps(),S=p.target,w=S!==t&&zj(S);v&&x&&!w&&this.start(p)});let r;const l=()=>{const{dragConstraints:p}=this.getProps();Ya(p)&&p.current&&(this.constraints=this.resolveRefConstraints(),r||(r=JM(t,p.current,()=>this.scalePositionWithinConstraints())))},{projection:c}=this.visualElement,f=c.addEventListener("measure",l);c&&!c.layout&&(c.root&&c.root.updateScroll(),c.updateLayout()),Ve.read(l);const h=Tr(window,"resize",()=>this.scalePositionWithinConstraints()),m=c.addEventListener("didUpdate",(({delta:p,hasLayoutChanged:v})=>{this.isDragging&&v&&(dn(x=>{const S=this.getAxisMotionValue(x);S&&(this.originPoint[x]+=p[x].translate,S.set(S.get()+p[x].translate))}),this.visualElement.render())}));return()=>{h(),a(),f(),m&&m(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:a=!1,dragDirectionLock:r=!1,dragPropagation:l=!1,dragConstraints:c=!1,dragElastic:f=Id,dragMomentum:h=!0}=t;return{...t,drag:a,dragDirectionLock:r,dragPropagation:l,dragConstraints:c,dragElastic:f,dragMomentum:h}}}function sx(n){let t=!0;return()=>{if(t){t=!1;return}n()}}function JM(n,t,a){const r=mv(n,sx(a)),l=mv(t,sx(a));return()=>{r(),l()}}function rl(n,t,a){return(t===!0||t===n)&&(a===null||a===n)}function e3(n,t=10){let a=null;return Math.abs(n.y)>t?a="y":Math.abs(n.x)>t&&(a="x"),a}class t3 extends _i{constructor(t){super(t),this.removeGroupControls=Jt,this.removeListeners=Jt,this.controls=new WM(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Jt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:a}=this.node.prevProps||{};t!==a&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Qf=n=>(t,a)=>{n&&Ve.update(()=>n(t,a),!1,!0)};class n3 extends _i{constructor(){super(...arguments),this.removePointerDownListener=Jt}onPointerDown(t){this.session=new dS(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:fS(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:a,onPan:r,onPanEnd:l}=this.node.getProps();return{onSessionStart:Qf(t),onStart:Qf(a),onMove:Qf(r),onEnd:(c,f)=>{delete this.session,l&&Ve.postRender(()=>l(c,f))}}}mount(){this.removePointerDownListener=pr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Wf=!1;class i3 extends K.Component{componentDidMount(){const{visualElement:t,layoutGroup:a,switchLayoutGroup:r,layoutId:l}=this.props,{projection:c}=t;c&&(a.group&&a.group.add(c),r&&r.register&&l&&r.register(c),Wf&&c.root.didUpdate(),c.addEventListener("animationComplete",()=>{this.safeToRemove()}),c.setOptions({...c.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),xl.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:a,visualElement:r,drag:l,isPresent:c}=this.props,{projection:f}=r;return f&&(f.isPresent=c,t.layoutDependency!==a&&f.setOptions({...f.options,layoutDependency:a}),Wf=!0,l||t.layoutDependency!==a||a===void 0||t.isPresent!==c?f.willUpdate():this.safeToRemove(),t.isPresent!==c&&(c?f.promote():f.relegate()||Ve.postRender(()=>{const h=f.getStack();(!h||!h.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:a}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=a,r.root.didUpdate(),Dh.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:a,switchLayoutGroup:r}=this.props,{projection:l}=t;Wf=!0,l&&(l.scheduleCheckAfterUnmount(),a&&a.group&&a.group.remove(l),r&&r.deregister&&r.deregister(l))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function mS(n){const[t,a]=uM(),r=K.useContext(Cb);return g.jsx(i3,{...n,layoutGroup:r,switchLayoutGroup:K.useContext(cS),isPresent:t,safeToRemove:a})}const a3={pan:{Feature:n3},drag:{Feature:t3,ProjectionNode:tS,MeasureLayout:mS}};function rx(n,t,a){const{props:r}=n;n.animationState&&r.whileHover&&n.animationState.setActive("whileHover",a==="Start");const l="onHover"+a,c=r[l];c&&Ve.postRender(()=>c(t,kr(t)))}class s3 extends _i{mount(){const{current:t}=this.node;t&&(this.unmount=Oj(t,(a,r)=>(rx(this.node,r,"Start"),l=>rx(this.node,l,"End"))))}unmount(){}}class r3 extends _i{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Mr(Tr(this.node.current,"focus",()=>this.onFocus()),Tr(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function ox(n,t,a){const{props:r}=n;if(n.current instanceof HTMLButtonElement&&n.current.disabled)return;n.animationState&&r.whileTap&&n.animationState.setActive("whileTap",a==="Start");const l="onTap"+(a==="End"?"":a),c=r[l];c&&Ve.postRender(()=>c(t,kr(t)))}class o3 extends _i{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:a,propagate:r}=this.node.props;this.unmount=Bj(t,(l,c)=>(ox(this.node,c,"Start"),(f,{success:h})=>ox(this.node,f,h?"End":"Cancel")),{useGlobalTarget:a,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const qd=new WeakMap,Jf=new WeakMap,l3=n=>{const t=qd.get(n.target);t&&t(n)},c3=n=>{n.forEach(l3)};function u3({root:n,...t}){const a=n||document;Jf.has(a)||Jf.set(a,{});const r=Jf.get(a),l=JSON.stringify(t);return r[l]||(r[l]=new IntersectionObserver(c3,{root:n,...t})),r[l]}function f3(n,t,a){const r=u3(t);return qd.set(n,a),r.observe(n),()=>{qd.delete(n),r.unobserve(n)}}const d3={some:0,all:1};class h3 extends _i{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var m;(m=this.stopObserver)==null||m.call(this);const{viewport:t={}}=this.node.getProps(),{root:a,margin:r,amount:l="some",once:c}=t,f={root:a?a.current:void 0,rootMargin:r,threshold:typeof l=="number"?l:d3[l]},h=p=>{const{isIntersecting:v}=p;if(this.isInView===v||(this.isInView=v,c&&!v&&this.hasEnteredView))return;v&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",v);const{onViewportEnter:x,onViewportLeave:S}=this.node.getProps(),w=v?x:S;w&&w(p)};this.stopObserver=f3(this.node.current,f,h)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:a}=this.node;["amount","margin","root"].some(m3(t,a))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function m3({viewport:n={}},{viewport:t={}}={}){return a=>n[a]!==t[a]}const p3={inView:{Feature:h3},tap:{Feature:o3},focus:{Feature:r3},hover:{Feature:s3}},g3={layout:{ProjectionNode:tS,MeasureLayout:mS}},y3={...PM,...p3,...a3,...g3},Za=LM(y3,zM);/** +`+o.stack}}var oc=Object.prototype.hasOwnProperty,lc=n.unstable_scheduleCallback,cc=n.unstable_cancelCallback,IS=n.unstable_shouldYield,qS=n.unstable_requestPaint,Ct=n.unstable_now,FS=n.unstable_getCurrentPriorityLevel,Ih=n.unstable_ImmediatePriority,qh=n.unstable_UserBlockingPriority,zr=n.unstable_NormalPriority,GS=n.unstable_LowPriority,Fh=n.unstable_IdlePriority,YS=n.log,KS=n.unstable_setDisableYieldValue,ds=null,jt=null;function In(e){if(typeof YS=="function"&&KS(e),jt&&typeof jt.setStrictMode=="function")try{jt.setStrictMode(ds,e)}catch{}}var Mt=Math.clz32?Math.clz32:ZS,XS=Math.log,$S=Math.LN2;function ZS(e){return e>>>=0,e===0?32:31-(XS(e)/$S|0)|0}var Vr=256,Br=262144,Ur=4194304;function Ei(e){var i=e&42;if(i!==0)return i;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Pr(e,i,s){var o=e.pendingLanes;if(o===0)return 0;var u=0,d=e.suspendedLanes,y=e.pingedLanes;e=e.warmLanes;var b=o&134217727;return b!==0?(o=b&~d,o!==0?u=Ei(o):(y&=b,y!==0?u=Ei(y):s||(s=b&~e,s!==0&&(u=Ei(s))))):(b=o&~d,b!==0?u=Ei(b):y!==0?u=Ei(y):s||(s=o&~e,s!==0&&(u=Ei(s)))),u===0?0:i!==0&&i!==u&&(i&d)===0&&(d=u&-u,s=i&-i,d>=s||d===32&&(s&4194048)!==0)?i:u}function hs(e,i){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&i)===0}function QS(e,i){switch(e){case 1:case 2:case 4:case 8:case 64:return i+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return i+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Gh(){var e=Ur;return Ur<<=1,(Ur&62914560)===0&&(Ur=4194304),e}function uc(e){for(var i=[],s=0;31>s;s++)i.push(e);return i}function ms(e,i){e.pendingLanes|=i,i!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function WS(e,i,s,o,u,d){var y=e.pendingLanes;e.pendingLanes=s,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=s,e.entangledLanes&=s,e.errorRecoveryDisabledLanes&=s,e.shellSuspendCounter=0;var b=e.entanglements,E=e.expirationTimes,j=e.hiddenUpdates;for(s=y&~s;0"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var a2=/[\n"\\]/g;function It(e){return e.replace(a2,function(i){return"\\"+i.charCodeAt(0).toString(16)+" "})}function gc(e,i,s,o,u,d,y,b){e.name="",y!=null&&typeof y!="function"&&typeof y!="symbol"&&typeof y!="boolean"?e.type=y:e.removeAttribute("type"),i!=null?y==="number"?(i===0&&e.value===""||e.value!=i)&&(e.value=""+Ht(i)):e.value!==""+Ht(i)&&(e.value=""+Ht(i)):y!=="submit"&&y!=="reset"||e.removeAttribute("value"),i!=null?yc(e,y,Ht(i)):s!=null?yc(e,y,Ht(s)):o!=null&&e.removeAttribute("value"),u==null&&d!=null&&(e.defaultChecked=!!d),u!=null&&(e.checked=u&&typeof u!="function"&&typeof u!="symbol"),b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.name=""+Ht(b):e.removeAttribute("name")}function am(e,i,s,o,u,d,y,b){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),i!=null||s!=null){if(!(d!=="submit"&&d!=="reset"||i!=null)){pc(e);return}s=s!=null?""+Ht(s):"",i=i!=null?""+Ht(i):s,b||i===e.value||(e.value=i),e.defaultValue=i}o=o??u,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=b?e.checked:!!o,e.defaultChecked=!!o,y!=null&&typeof y!="function"&&typeof y!="symbol"&&typeof y!="boolean"&&(e.name=y),pc(e)}function yc(e,i,s){i==="number"&&qr(e.ownerDocument)===e||e.defaultValue===""+s||(e.defaultValue=""+s)}function ca(e,i,s,o){if(e=e.options,i){i={};for(var u=0;u"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),wc=!1;if(Sn)try{var vs={};Object.defineProperty(vs,"passive",{get:function(){wc=!0}}),window.addEventListener("test",vs,vs),window.removeEventListener("test",vs,vs)}catch{wc=!1}var Fn=null,_c=null,Gr=null;function fm(){if(Gr)return Gr;var e,i=_c,s=i.length,o,u="value"in Fn?Fn.value:Fn.textContent,d=u.length;for(e=0;e=Ss),ym=" ",vm=!1;function xm(e,i){switch(e){case"keyup":return O2.indexOf(i.keyCode)!==-1;case"keydown":return i.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function bm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ha=!1;function k2(e,i){switch(e){case"compositionend":return bm(i);case"keypress":return i.which!==32?null:(vm=!0,ym);case"textInput":return e=i.data,e===ym&&vm?null:e;default:return null}}function L2(e,i){if(ha)return e==="compositionend"||!Dc&&xm(e,i)?(e=fm(),Gr=_c=Fn=null,ha=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(i.ctrlKey||i.altKey||i.metaKey)||i.ctrlKey&&i.altKey){if(i.char&&1=i)return{node:s,offset:i-e};e=o}e:{for(;s;){if(s.nextSibling){s=s.nextSibling;break e}s=s.parentNode}s=void 0}s=Dm(s)}}function jm(e,i){return e&&i?e===i?!0:e&&e.nodeType===3?!1:i&&i.nodeType===3?jm(e,i.parentNode):"contains"in e?e.contains(i):e.compareDocumentPosition?!!(e.compareDocumentPosition(i)&16):!1:!1}function Mm(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var i=qr(e.document);i instanceof e.HTMLIFrameElement;){try{var s=typeof i.contentWindow.location.href=="string"}catch{s=!1}if(s)e=i.contentWindow;else break;i=qr(e.document)}return i}function Mc(e){var i=e&&e.nodeName&&e.nodeName.toLowerCase();return i&&(i==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||i==="textarea"||e.contentEditable==="true")}var q2=Sn&&"documentMode"in document&&11>=document.documentMode,ma=null,Oc=null,Es=null,Rc=!1;function Om(e,i,s){var o=s.window===s?s.document:s.nodeType===9?s:s.ownerDocument;Rc||ma==null||ma!==qr(o)||(o=ma,"selectionStart"in o&&Mc(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),Es&&Ts(Es,o)||(Es=o,o=Uo(Oc,"onSelect"),0>=y,u-=y,ln=1<<32-Mt(i)+u|s<de?(xe=ee,ee=null):xe=ee.sibling;var Ee=M(D,ee,C[de],U);if(Ee===null){ee===null&&(ee=xe);break}e&&ee&&Ee.alternate===null&&i(D,ee),N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee,ee=xe}if(de===C.length)return s(D,ee),be&&_n(D,de),ne;if(ee===null){for(;dede?(xe=ee,ee=null):xe=ee.sibling;var di=M(D,ee,Ee.value,U);if(di===null){ee===null&&(ee=xe);break}e&&ee&&di.alternate===null&&i(D,ee),N=d(di,N,de),Te===null?ne=di:Te.sibling=di,Te=di,ee=xe}if(Ee.done)return s(D,ee),be&&_n(D,de),ne;if(ee===null){for(;!Ee.done;de++,Ee=C.next())Ee=P(D,Ee.value,U),Ee!==null&&(N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee);return be&&_n(D,de),ne}for(ee=o(ee);!Ee.done;de++,Ee=C.next())Ee=R(ee,D,de,Ee.value,U),Ee!==null&&(e&&Ee.alternate!==null&&ee.delete(Ee.key===null?de:Ee.key),N=d(Ee,N,de),Te===null?ne=Ee:Te.sibling=Ee,Te=Ee);return e&&ee.forEach(function(c_){return i(D,c_)}),be&&_n(D,de),ne}function Le(D,N,C,U){if(typeof C=="object"&&C!==null&&C.type===k&&C.key===null&&(C=C.props.children),typeof C=="object"&&C!==null){switch(C.$$typeof){case w:e:{for(var ne=C.key;N!==null;){if(N.key===ne){if(ne=C.type,ne===k){if(N.tag===7){s(D,N.sibling),U=u(N,C.props.children),U.return=D,D=U;break e}}else if(N.elementType===ne||typeof ne=="object"&&ne!==null&&ne.$$typeof===te&&zi(ne)===N.type){s(D,N.sibling),U=u(N,C.props),Ms(U,C),U.return=D,D=U;break e}s(D,N);break}else i(D,N);N=N.sibling}C.type===k?(U=Mi(C.props.children,D.mode,U,C.key),U.return=D,D=U):(U=to(C.type,C.key,C.props,null,D.mode,U),Ms(U,C),U.return=D,D=U)}return y(D);case T:e:{for(ne=C.key;N!==null;){if(N.key===ne)if(N.tag===4&&N.stateNode.containerInfo===C.containerInfo&&N.stateNode.implementation===C.implementation){s(D,N.sibling),U=u(N,C.children||[]),U.return=D,D=U;break e}else{s(D,N);break}else i(D,N);N=N.sibling}U=Pc(C,D.mode,U),U.return=D,D=U}return y(D);case te:return C=zi(C),Le(D,N,C,U)}if(He(C))return Q(D,N,C,U);if(Ae(C)){if(ne=Ae(C),typeof ne!="function")throw Error(r(150));return C=ne.call(C),ie(D,N,C,U)}if(typeof C.then=="function")return Le(D,N,lo(C),U);if(C.$$typeof===H)return Le(D,N,ao(D,C),U);co(D,C)}return typeof C=="string"&&C!==""||typeof C=="number"||typeof C=="bigint"?(C=""+C,N!==null&&N.tag===6?(s(D,N.sibling),U=u(N,C),U.return=D,D=U):(s(D,N),U=Uc(C,D.mode,U),U.return=D,D=U),y(D)):s(D,N)}return function(D,N,C,U){try{js=0;var ne=Le(D,N,C,U);return Ea=null,ne}catch(ee){if(ee===Ta||ee===ro)throw ee;var Te=Rt(29,ee,null,D.mode);return Te.lanes=U,Te.return=D,Te}finally{}}}var Bi=tp(!0),np=tp(!1),$n=!1;function Wc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Jc(e,i){e=e.updateQueue,i.updateQueue===e&&(i.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Zn(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Qn(e,i,s){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(Ne&2)!==0){var u=o.pending;return u===null?i.next=i:(i.next=u.next,u.next=i),o.pending=i,i=eo(e),Um(e,null,s),i}return Jr(e,o,i,s),eo(e)}function Os(e,i,s){if(i=i.updateQueue,i!==null&&(i=i.shared,(s&4194048)!==0)){var o=i.lanes;o&=e.pendingLanes,s|=o,i.lanes=s,Kh(e,s)}}function eu(e,i){var s=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,s===o)){var u=null,d=null;if(s=s.firstBaseUpdate,s!==null){do{var y={lane:s.lane,tag:s.tag,payload:s.payload,callback:null,next:null};d===null?u=d=y:d=d.next=y,s=s.next}while(s!==null);d===null?u=d=i:d=d.next=i}else u=d=i;s={baseState:o.baseState,firstBaseUpdate:u,lastBaseUpdate:d,shared:o.shared,callbacks:o.callbacks},e.updateQueue=s;return}e=s.lastBaseUpdate,e===null?s.firstBaseUpdate=i:e.next=i,s.lastBaseUpdate=i}var tu=!1;function Rs(){if(tu){var e=_a;if(e!==null)throw e}}function ks(e,i,s,o){tu=!1;var u=e.updateQueue;$n=!1;var d=u.firstBaseUpdate,y=u.lastBaseUpdate,b=u.shared.pending;if(b!==null){u.shared.pending=null;var E=b,j=E.next;E.next=null,y===null?d=j:y.next=j,y=E;var L=e.alternate;L!==null&&(L=L.updateQueue,b=L.lastBaseUpdate,b!==y&&(b===null?L.firstBaseUpdate=j:b.next=j,L.lastBaseUpdate=E))}if(d!==null){var P=u.baseState;y=0,L=j=E=null,b=d;do{var M=b.lane&-536870913,R=M!==b.lane;if(R?(ve&M)===M:(o&M)===M){M!==0&&M===wa&&(tu=!0),L!==null&&(L=L.next={lane:0,tag:b.tag,payload:b.payload,callback:null,next:null});e:{var Q=e,ie=b;M=i;var Le=s;switch(ie.tag){case 1:if(Q=ie.payload,typeof Q=="function"){P=Q.call(Le,P,M);break e}P=Q;break e;case 3:Q.flags=Q.flags&-65537|128;case 0:if(Q=ie.payload,M=typeof Q=="function"?Q.call(Le,P,M):Q,M==null)break e;P=x({},P,M);break e;case 2:$n=!0}}M=b.callback,M!==null&&(e.flags|=64,R&&(e.flags|=8192),R=u.callbacks,R===null?u.callbacks=[M]:R.push(M))}else R={lane:M,tag:b.tag,payload:b.payload,callback:b.callback,next:null},L===null?(j=L=R,E=P):L=L.next=R,y|=M;if(b=b.next,b===null){if(b=u.shared.pending,b===null)break;R=b,b=R.next,R.next=null,u.lastBaseUpdate=R,u.shared.pending=null}}while(!0);L===null&&(E=P),u.baseState=E,u.firstBaseUpdate=j,u.lastBaseUpdate=L,d===null&&(u.shared.lanes=0),ni|=y,e.lanes=y,e.memoizedState=P}}function ip(e,i){if(typeof e!="function")throw Error(r(191,e));e.call(i)}function ap(e,i){var s=e.callbacks;if(s!==null)for(e.callbacks=null,e=0;ed?d:8;var y=O.T,b={};O.T=b,bu(e,!1,i,s);try{var E=u(),j=O.S;if(j!==null&&j(b,E),E!==null&&typeof E=="object"&&typeof E.then=="function"){var L=W2(E,o);Vs(e,i,L,Bt(e))}else Vs(e,i,o,Bt(e))}catch(P){Vs(e,i,{then:function(){},status:"rejected",reason:P},Bt())}finally{q.p=d,y!==null&&b.types!==null&&(y.types=b.types),O.T=y}}function aw(){}function vu(e,i,s,o){if(e.tag!==5)throw Error(r(476));var u=zp(e).queue;Lp(e,u,i,Y,s===null?aw:function(){return Vp(e),s(o)})}function zp(e){var i=e.memoizedState;if(i!==null)return i;i={memoizedState:Y,baseState:Y,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Nn,lastRenderedState:Y},next:null};var s={};return i.next={memoizedState:s,baseState:s,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Nn,lastRenderedState:s},next:null},e.memoizedState=i,e=e.alternate,e!==null&&(e.memoizedState=i),i}function Vp(e){var i=zp(e);i.next===null&&(i=e.alternate.memoizedState),Vs(e,i.next.queue,{},Bt())}function xu(){return ct(er)}function Bp(){return Ze().memoizedState}function Up(){return Ze().memoizedState}function sw(e){for(var i=e.return;i!==null;){switch(i.tag){case 24:case 3:var s=Bt();e=Zn(s);var o=Qn(i,e,s);o!==null&&(Dt(o,i,s),Os(o,i,s)),i={cache:Xc()},e.payload=i;return}i=i.return}}function rw(e,i,s){var o=Bt();s={lane:o,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null},bo(e)?Hp(i,s):(s=Vc(e,i,s,o),s!==null&&(Dt(s,e,o),Ip(s,i,o)))}function Pp(e,i,s){var o=Bt();Vs(e,i,s,o)}function Vs(e,i,s,o){var u={lane:o,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null};if(bo(e))Hp(i,u);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=i.lastRenderedReducer,d!==null))try{var y=i.lastRenderedState,b=d(y,s);if(u.hasEagerState=!0,u.eagerState=b,Ot(b,y))return Jr(e,i,u,0),ze===null&&Wr(),!1}catch{}finally{}if(s=Vc(e,i,u,o),s!==null)return Dt(s,e,o),Ip(s,i,o),!0}return!1}function bu(e,i,s,o){if(o={lane:2,revertLane:Wu(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},bo(e)){if(i)throw Error(r(479))}else i=Vc(e,s,o,2),i!==null&&Dt(i,e,2)}function bo(e){var i=e.alternate;return e===fe||i!==null&&i===fe}function Hp(e,i){Na=ho=!0;var s=e.pending;s===null?i.next=i:(i.next=s.next,s.next=i),e.pending=i}function Ip(e,i,s){if((s&4194048)!==0){var o=i.lanes;o&=e.pendingLanes,s|=o,i.lanes=s,Kh(e,s)}}var Bs={readContext:ct,use:go,useCallback:Fe,useContext:Fe,useEffect:Fe,useImperativeHandle:Fe,useLayoutEffect:Fe,useInsertionEffect:Fe,useMemo:Fe,useReducer:Fe,useRef:Fe,useState:Fe,useDebugValue:Fe,useDeferredValue:Fe,useTransition:Fe,useSyncExternalStore:Fe,useId:Fe,useHostTransitionStatus:Fe,useFormState:Fe,useActionState:Fe,useOptimistic:Fe,useMemoCache:Fe,useCacheRefresh:Fe};Bs.useEffectEvent=Fe;var qp={readContext:ct,use:go,useCallback:function(e,i){return vt().memoizedState=[e,i===void 0?null:i],e},useContext:ct,useEffect:Ap,useImperativeHandle:function(e,i,s){s=s!=null?s.concat([e]):null,vo(4194308,4,jp.bind(null,i,e),s)},useLayoutEffect:function(e,i){return vo(4194308,4,e,i)},useInsertionEffect:function(e,i){vo(4,2,e,i)},useMemo:function(e,i){var s=vt();i=i===void 0?null:i;var o=e();if(Ui){In(!0);try{e()}finally{In(!1)}}return s.memoizedState=[o,i],o},useReducer:function(e,i,s){var o=vt();if(s!==void 0){var u=s(i);if(Ui){In(!0);try{s(i)}finally{In(!1)}}}else u=i;return o.memoizedState=o.baseState=u,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:u},o.queue=e,e=e.dispatch=rw.bind(null,fe,e),[o.memoizedState,e]},useRef:function(e){var i=vt();return e={current:e},i.memoizedState=e},useState:function(e){e=hu(e);var i=e.queue,s=Pp.bind(null,fe,i);return i.dispatch=s,[e.memoizedState,s]},useDebugValue:gu,useDeferredValue:function(e,i){var s=vt();return yu(s,e,i)},useTransition:function(){var e=hu(!1);return e=Lp.bind(null,fe,e.queue,!0,!1),vt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,i,s){var o=fe,u=vt();if(be){if(s===void 0)throw Error(r(407));s=s()}else{if(s=i(),ze===null)throw Error(r(349));(ve&127)!==0||up(o,i,s)}u.memoizedState=s;var d={value:s,getSnapshot:i};return u.queue=d,Ap(dp.bind(null,o,d,e),[e]),o.flags|=2048,Ca(9,{destroy:void 0},fp.bind(null,o,d,s,i),null),s},useId:function(){var e=vt(),i=ze.identifierPrefix;if(be){var s=cn,o=ln;s=(o&~(1<<32-Mt(o)-1)).toString(32)+s,i="_"+i+"R_"+s,s=mo++,0<\/script>",d=d.removeChild(d.firstChild);break;case"select":d=typeof o.is=="string"?y.createElement("select",{is:o.is}):y.createElement("select"),o.multiple?d.multiple=!0:o.size&&(d.size=o.size);break;default:d=typeof o.is=="string"?y.createElement(u,{is:o.is}):y.createElement(u)}}d[ot]=i,d[wt]=o;e:for(y=i.child;y!==null;){if(y.tag===5||y.tag===6)d.appendChild(y.stateNode);else if(y.tag!==4&&y.tag!==27&&y.child!==null){y.child.return=y,y=y.child;continue}if(y===i)break e;for(;y.sibling===null;){if(y.return===null||y.return===i)break e;y=y.return}y.sibling.return=y.return,y=y.sibling}i.stateNode=d;e:switch(ft(d,u,o),u){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break e;case"img":o=!0;break e;default:o=!1}o&&Cn(i)}}return Ue(i),ku(i,i.type,e===null?null:e.memoizedProps,i.pendingProps,s),null;case 6:if(e&&i.stateNode!=null)e.memoizedProps!==o&&Cn(i);else{if(typeof o!="string"&&i.stateNode===null)throw Error(r(166));if(e=pe.current,ba(i)){if(e=i.stateNode,s=i.memoizedProps,o=null,u=lt,u!==null)switch(u.tag){case 27:case 5:o=u.memoizedProps}e[ot]=i,e=!!(e.nodeValue===s||o!==null&&o.suppressHydrationWarning===!0||ly(e.nodeValue,s)),e||Kn(i,!0)}else e=Po(e).createTextNode(o),e[ot]=i,i.stateNode=e}return Ue(i),null;case 31:if(s=i.memoizedState,e===null||e.memoizedState!==null){if(o=ba(i),s!==null){if(e===null){if(!o)throw Error(r(318));if(e=i.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(r(557));e[ot]=i}else Oi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;Ue(i),e=!1}else s=Fc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=s),e=!0;if(!e)return i.flags&256?(Lt(i),i):(Lt(i),null);if((i.flags&128)!==0)throw Error(r(558))}return Ue(i),null;case 13:if(o=i.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(u=ba(i),o!==null&&o.dehydrated!==null){if(e===null){if(!u)throw Error(r(318));if(u=i.memoizedState,u=u!==null?u.dehydrated:null,!u)throw Error(r(317));u[ot]=i}else Oi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;Ue(i),u=!1}else u=Fc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=u),u=!0;if(!u)return i.flags&256?(Lt(i),i):(Lt(i),null)}return Lt(i),(i.flags&128)!==0?(i.lanes=s,i):(s=o!==null,e=e!==null&&e.memoizedState!==null,s&&(o=i.child,u=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(u=o.alternate.memoizedState.cachePool.pool),d=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(d=o.memoizedState.cachePool.pool),d!==u&&(o.flags|=2048)),s!==e&&s&&(i.child.flags|=8192),Eo(i,i.updateQueue),Ue(i),null);case 4:return Xe(),e===null&&nf(i.stateNode.containerInfo),Ue(i),null;case 10:return En(i.type),Ue(i),null;case 19:if(V($e),o=i.memoizedState,o===null)return Ue(i),null;if(u=(i.flags&128)!==0,d=o.rendering,d===null)if(u)Ps(o,!1);else{if(Ge!==0||e!==null&&(e.flags&128)!==0)for(e=i.child;e!==null;){if(d=fo(e),d!==null){for(i.flags|=128,Ps(o,!1),e=d.updateQueue,i.updateQueue=e,Eo(i,e),i.subtreeFlags=0,e=s,s=i.child;s!==null;)Pm(s,e),s=s.sibling;return G($e,$e.current&1|2),be&&_n(i,o.treeForkCount),i.child}e=e.sibling}o.tail!==null&&Ct()>jo&&(i.flags|=128,u=!0,Ps(o,!1),i.lanes=4194304)}else{if(!u)if(e=fo(d),e!==null){if(i.flags|=128,u=!0,e=e.updateQueue,i.updateQueue=e,Eo(i,e),Ps(o,!0),o.tail===null&&o.tailMode==="hidden"&&!d.alternate&&!be)return Ue(i),null}else 2*Ct()-o.renderingStartTime>jo&&s!==536870912&&(i.flags|=128,u=!0,Ps(o,!1),i.lanes=4194304);o.isBackwards?(d.sibling=i.child,i.child=d):(e=o.last,e!==null?e.sibling=d:i.child=d,o.last=d)}return o.tail!==null?(e=o.tail,o.rendering=e,o.tail=e.sibling,o.renderingStartTime=Ct(),e.sibling=null,s=$e.current,G($e,u?s&1|2:s&1),be&&_n(i,o.treeForkCount),e):(Ue(i),null);case 22:case 23:return Lt(i),iu(),o=i.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(i.flags|=8192):o&&(i.flags|=8192),o?(s&536870912)!==0&&(i.flags&128)===0&&(Ue(i),i.subtreeFlags&6&&(i.flags|=8192)):Ue(i),s=i.updateQueue,s!==null&&Eo(i,s.retryQueue),s=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(s=e.memoizedState.cachePool.pool),o=null,i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(o=i.memoizedState.cachePool.pool),o!==s&&(i.flags|=2048),e!==null&&V(Li),null;case 24:return s=null,e!==null&&(s=e.memoizedState.cache),i.memoizedState.cache!==s&&(i.flags|=2048),En(We),Ue(i),null;case 25:return null;case 30:return null}throw Error(r(156,i.tag))}function fw(e,i){switch(Ic(i),i.tag){case 1:return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 3:return En(We),Xe(),e=i.flags,(e&65536)!==0&&(e&128)===0?(i.flags=e&-65537|128,i):null;case 26:case 27:case 5:return Lr(i),null;case 31:if(i.memoizedState!==null){if(Lt(i),i.alternate===null)throw Error(r(340));Oi()}return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 13:if(Lt(i),e=i.memoizedState,e!==null&&e.dehydrated!==null){if(i.alternate===null)throw Error(r(340));Oi()}return e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 19:return V($e),null;case 4:return Xe(),null;case 10:return En(i.type),null;case 22:case 23:return Lt(i),iu(),e!==null&&V(Li),e=i.flags,e&65536?(i.flags=e&-65537|128,i):null;case 24:return En(We),null;case 25:return null;default:return null}}function hg(e,i){switch(Ic(i),i.tag){case 3:En(We),Xe();break;case 26:case 27:case 5:Lr(i);break;case 4:Xe();break;case 31:i.memoizedState!==null&&Lt(i);break;case 13:Lt(i);break;case 19:V($e);break;case 10:En(i.type);break;case 22:case 23:Lt(i),iu(),e!==null&&V(Li);break;case 24:En(We)}}function Hs(e,i){try{var s=i.updateQueue,o=s!==null?s.lastEffect:null;if(o!==null){var u=o.next;s=u;do{if((s.tag&e)===e){o=void 0;var d=s.create,y=s.inst;o=d(),y.destroy=o}s=s.next}while(s!==u)}}catch(b){Me(i,i.return,b)}}function ei(e,i,s){try{var o=i.updateQueue,u=o!==null?o.lastEffect:null;if(u!==null){var d=u.next;o=d;do{if((o.tag&e)===e){var y=o.inst,b=y.destroy;if(b!==void 0){y.destroy=void 0,u=i;var E=s,j=b;try{j()}catch(L){Me(u,E,L)}}}o=o.next}while(o!==d)}}catch(L){Me(i,i.return,L)}}function mg(e){var i=e.updateQueue;if(i!==null){var s=e.stateNode;try{ap(i,s)}catch(o){Me(e,e.return,o)}}}function pg(e,i,s){s.props=Pi(e.type,e.memoizedProps),s.state=e.memoizedState;try{s.componentWillUnmount()}catch(o){Me(e,i,o)}}function Is(e,i){try{var s=e.ref;if(s!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:o=e.stateNode;break;default:o=e.stateNode}typeof s=="function"?e.refCleanup=s(o):s.current=o}}catch(u){Me(e,i,u)}}function un(e,i){var s=e.ref,o=e.refCleanup;if(s!==null)if(typeof o=="function")try{o()}catch(u){Me(e,i,u)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof s=="function")try{s(null)}catch(u){Me(e,i,u)}else s.current=null}function gg(e){var i=e.type,s=e.memoizedProps,o=e.stateNode;try{e:switch(i){case"button":case"input":case"select":case"textarea":s.autoFocus&&o.focus();break e;case"img":s.src?o.src=s.src:s.srcSet&&(o.srcset=s.srcSet)}}catch(u){Me(e,e.return,u)}}function Lu(e,i,s){try{var o=e.stateNode;Rw(o,e.type,s,i),o[wt]=i}catch(u){Me(e,e.return,u)}}function yg(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&oi(e.type)||e.tag===4}function zu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||yg(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&oi(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Vu(e,i,s){var o=e.tag;if(o===5||o===6)e=e.stateNode,i?(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s).insertBefore(e,i):(i=s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,i.appendChild(e),s=s._reactRootContainer,s!=null||i.onclick!==null||(i.onclick=bn));else if(o!==4&&(o===27&&oi(e.type)&&(s=e.stateNode,i=null),e=e.child,e!==null))for(Vu(e,i,s),e=e.sibling;e!==null;)Vu(e,i,s),e=e.sibling}function Ao(e,i,s){var o=e.tag;if(o===5||o===6)e=e.stateNode,i?s.insertBefore(e,i):s.appendChild(e);else if(o!==4&&(o===27&&oi(e.type)&&(s=e.stateNode),e=e.child,e!==null))for(Ao(e,i,s),e=e.sibling;e!==null;)Ao(e,i,s),e=e.sibling}function vg(e){var i=e.stateNode,s=e.memoizedProps;try{for(var o=e.type,u=i.attributes;u.length;)i.removeAttributeNode(u[0]);ft(i,o,s),i[ot]=e,i[wt]=s}catch(d){Me(e,e.return,d)}}var jn=!1,tt=!1,Bu=!1,xg=typeof WeakSet=="function"?WeakSet:Set,rt=null;function dw(e,i){if(e=e.containerInfo,rf=Ko,e=Mm(e),Mc(e)){if("selectionStart"in e)var s={start:e.selectionStart,end:e.selectionEnd};else e:{s=(s=e.ownerDocument)&&s.defaultView||window;var o=s.getSelection&&s.getSelection();if(o&&o.rangeCount!==0){s=o.anchorNode;var u=o.anchorOffset,d=o.focusNode;o=o.focusOffset;try{s.nodeType,d.nodeType}catch{s=null;break e}var y=0,b=-1,E=-1,j=0,L=0,P=e,M=null;t:for(;;){for(var R;P!==s||u!==0&&P.nodeType!==3||(b=y+u),P!==d||o!==0&&P.nodeType!==3||(E=y+o),P.nodeType===3&&(y+=P.nodeValue.length),(R=P.firstChild)!==null;)M=P,P=R;for(;;){if(P===e)break t;if(M===s&&++j===u&&(b=y),M===d&&++L===o&&(E=y),(R=P.nextSibling)!==null)break;P=M,M=P.parentNode}P=R}s=b===-1||E===-1?null:{start:b,end:E}}else s=null}s=s||{start:0,end:0}}else s=null;for(of={focusedElem:e,selectionRange:s},Ko=!1,rt=i;rt!==null;)if(i=rt,e=i.child,(i.subtreeFlags&1028)!==0&&e!==null)e.return=i,rt=e;else for(;rt!==null;){switch(i=rt,d=i.alternate,e=i.flags,i.tag){case 0:if((e&4)!==0&&(e=i.updateQueue,e=e!==null?e.events:null,e!==null))for(s=0;s title"))),ft(d,o,s),d[ot]=e,st(d),o=d;break e;case"link":var y=Ey("link","href",u).get(o+(s.href||""));if(y){for(var b=0;bLe&&(y=Le,Le=ie,ie=y);var D=Cm(b,ie),N=Cm(b,Le);if(D&&N&&(R.rangeCount!==1||R.anchorNode!==D.node||R.anchorOffset!==D.offset||R.focusNode!==N.node||R.focusOffset!==N.offset)){var C=P.createRange();C.setStart(D.node,D.offset),R.removeAllRanges(),ie>Le?(R.addRange(C),R.extend(N.node,N.offset)):(C.setEnd(N.node,N.offset),R.addRange(C))}}}}for(P=[],R=b;R=R.parentNode;)R.nodeType===1&&P.push({element:R,left:R.scrollLeft,top:R.scrollTop});for(typeof b.focus=="function"&&b.focus(),b=0;bs?32:s,O.T=null,s=Gu,Gu=null;var d=ai,y=Ln;if(it=0,ka=ai=null,Ln=0,(Ne&6)!==0)throw Error(r(331));var b=Ne;if(Ne|=4,jg(d.current),Ng(d,d.current,y,s),Ne=b,Xs(0,!1),jt&&typeof jt.onPostCommitFiberRoot=="function")try{jt.onPostCommitFiberRoot(ds,d)}catch{}return!0}finally{q.p=u,O.T=o,Xg(e,i)}}function Zg(e,i,s){i=Ft(s,i),i=Tu(e.stateNode,i,2),e=Qn(e,i,2),e!==null&&(ms(e,2),fn(e))}function Me(e,i,s){if(e.tag===3)Zg(e,e,s);else for(;i!==null;){if(i.tag===3){Zg(i,e,s);break}else if(i.tag===1){var o=i.stateNode;if(typeof i.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(ii===null||!ii.has(o))){e=Ft(s,e),s=Qp(2),o=Qn(i,s,2),o!==null&&(Wp(s,o,i,e),ms(o,2),fn(o));break}}i=i.return}}function $u(e,i,s){var o=e.pingCache;if(o===null){o=e.pingCache=new pw;var u=new Set;o.set(i,u)}else u=o.get(i),u===void 0&&(u=new Set,o.set(i,u));u.has(s)||(Hu=!0,u.add(s),e=bw.bind(null,e,i,s),i.then(e,e))}function bw(e,i,s){var o=e.pingCache;o!==null&&o.delete(i),e.pingedLanes|=e.suspendedLanes&s,e.warmLanes&=~s,ze===e&&(ve&s)===s&&(Ge===4||Ge===3&&(ve&62914560)===ve&&300>Ct()-Co?(Ne&2)===0&&La(e,0):Iu|=s,Ra===ve&&(Ra=0)),fn(e)}function Qg(e,i){i===0&&(i=Gh()),e=ji(e,i),e!==null&&(ms(e,i),fn(e))}function Sw(e){var i=e.memoizedState,s=0;i!==null&&(s=i.retryLane),Qg(e,s)}function ww(e,i){var s=0;switch(e.tag){case 31:case 13:var o=e.stateNode,u=e.memoizedState;u!==null&&(s=u.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(r(314))}o!==null&&o.delete(i),Qg(e,s)}function _w(e,i){return lc(e,i)}var zo=null,Va=null,Zu=!1,Vo=!1,Qu=!1,ri=0;function fn(e){e!==Va&&e.next===null&&(Va===null?zo=Va=e:Va=Va.next=e),Vo=!0,Zu||(Zu=!0,Ew())}function Xs(e,i){if(!Qu&&Vo){Qu=!0;do for(var s=!1,o=zo;o!==null;){if(e!==0){var u=o.pendingLanes;if(u===0)var d=0;else{var y=o.suspendedLanes,b=o.pingedLanes;d=(1<<31-Mt(42|e)+1)-1,d&=u&~(y&~b),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(s=!0,ty(o,d))}else d=ve,d=Pr(o,o===ze?d:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(d&3)===0||hs(o,d)||(s=!0,ty(o,d));o=o.next}while(s);Qu=!1}}function Tw(){Wg()}function Wg(){Vo=Zu=!1;var e=0;ri!==0&&Lw()&&(e=ri);for(var i=Ct(),s=null,o=zo;o!==null;){var u=o.next,d=Jg(o,i);d===0?(o.next=null,s===null?zo=u:s.next=u,u===null&&(Va=s)):(s=o,(e!==0||(d&3)!==0)&&(Vo=!0)),o=u}it!==0&&it!==5||Xs(e),ri!==0&&(ri=0)}function Jg(e,i){for(var s=e.suspendedLanes,o=e.pingedLanes,u=e.expirationTimes,d=e.pendingLanes&-62914561;0b)break;var L=E.transferSize,P=E.initiatorType;L&&cy(P)&&(E=E.responseEnd,y+=L*(E"u"?null:document;function Sy(e,i,s){var o=Ba;if(o&&typeof i=="string"&&i){var u=It(i);u='link[rel="'+e+'"][href="'+u+'"]',typeof s=="string"&&(u+='[crossorigin="'+s+'"]'),by.has(u)||(by.add(u),e={rel:e,crossOrigin:s,href:i},o.querySelector(u)===null&&(i=o.createElement("link"),ft(i,"link",e),st(i),o.head.appendChild(i)))}}function Fw(e){zn.D(e),Sy("dns-prefetch",e,null)}function Gw(e,i){zn.C(e,i),Sy("preconnect",e,i)}function Yw(e,i,s){zn.L(e,i,s);var o=Ba;if(o&&e&&i){var u='link[rel="preload"][as="'+It(i)+'"]';i==="image"&&s&&s.imageSrcSet?(u+='[imagesrcset="'+It(s.imageSrcSet)+'"]',typeof s.imageSizes=="string"&&(u+='[imagesizes="'+It(s.imageSizes)+'"]')):u+='[href="'+It(e)+'"]';var d=u;switch(i){case"style":d=Ua(e);break;case"script":d=Pa(e)}Zt.has(d)||(e=x({rel:"preload",href:i==="image"&&s&&s.imageSrcSet?void 0:e,as:i},s),Zt.set(d,e),o.querySelector(u)!==null||i==="style"&&o.querySelector(Ws(d))||i==="script"&&o.querySelector(Js(d))||(i=o.createElement("link"),ft(i,"link",e),st(i),o.head.appendChild(i)))}}function Kw(e,i){zn.m(e,i);var s=Ba;if(s&&e){var o=i&&typeof i.as=="string"?i.as:"script",u='link[rel="modulepreload"][as="'+It(o)+'"][href="'+It(e)+'"]',d=u;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Pa(e)}if(!Zt.has(d)&&(e=x({rel:"modulepreload",href:e},i),Zt.set(d,e),s.querySelector(u)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(s.querySelector(Js(d)))return}o=s.createElement("link"),ft(o,"link",e),st(o),s.head.appendChild(o)}}}function Xw(e,i,s){zn.S(e,i,s);var o=Ba;if(o&&e){var u=oa(o).hoistableStyles,d=Ua(e);i=i||"default";var y=u.get(d);if(!y){var b={loading:0,preload:null};if(y=o.querySelector(Ws(d)))b.loading=5;else{e=x({rel:"stylesheet",href:e,"data-precedence":i},s),(s=Zt.get(d))&&mf(e,s);var E=y=o.createElement("link");st(E),ft(E,"link",e),E._p=new Promise(function(j,L){E.onload=j,E.onerror=L}),E.addEventListener("load",function(){b.loading|=1}),E.addEventListener("error",function(){b.loading|=2}),b.loading|=4,Io(y,i,o)}y={type:"stylesheet",instance:y,count:1,state:b},u.set(d,y)}}}function $w(e,i){zn.X(e,i);var s=Ba;if(s&&e){var o=oa(s).hoistableScripts,u=Pa(e),d=o.get(u);d||(d=s.querySelector(Js(u)),d||(e=x({src:e,async:!0},i),(i=Zt.get(u))&&pf(e,i),d=s.createElement("script"),st(d),ft(d,"link",e),s.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(u,d))}}function Zw(e,i){zn.M(e,i);var s=Ba;if(s&&e){var o=oa(s).hoistableScripts,u=Pa(e),d=o.get(u);d||(d=s.querySelector(Js(u)),d||(e=x({src:e,async:!0,type:"module"},i),(i=Zt.get(u))&&pf(e,i),d=s.createElement("script"),st(d),ft(d,"link",e),s.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(u,d))}}function wy(e,i,s,o){var u=(u=pe.current)?Ho(u):null;if(!u)throw Error(r(446));switch(e){case"meta":case"title":return null;case"style":return typeof s.precedence=="string"&&typeof s.href=="string"?(i=Ua(s.href),s=oa(u).hoistableStyles,o=s.get(i),o||(o={type:"style",instance:null,count:0,state:null},s.set(i,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(s.rel==="stylesheet"&&typeof s.href=="string"&&typeof s.precedence=="string"){e=Ua(s.href);var d=oa(u).hoistableStyles,y=d.get(e);if(y||(u=u.ownerDocument||u,y={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,y),(d=u.querySelector(Ws(e)))&&!d._p&&(y.instance=d,y.state.loading=5),Zt.has(e)||(s={rel:"preload",as:"style",href:s.href,crossOrigin:s.crossOrigin,integrity:s.integrity,media:s.media,hrefLang:s.hrefLang,referrerPolicy:s.referrerPolicy},Zt.set(e,s),d||Qw(u,e,s,y.state))),i&&o===null)throw Error(r(528,""));return y}if(i&&o!==null)throw Error(r(529,""));return null;case"script":return i=s.async,s=s.src,typeof s=="string"&&i&&typeof i!="function"&&typeof i!="symbol"?(i=Pa(s),s=oa(u).hoistableScripts,o=s.get(i),o||(o={type:"script",instance:null,count:0,state:null},s.set(i,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,e))}}function Ua(e){return'href="'+It(e)+'"'}function Ws(e){return'link[rel="stylesheet"]['+e+"]"}function _y(e){return x({},e,{"data-precedence":e.precedence,precedence:null})}function Qw(e,i,s,o){e.querySelector('link[rel="preload"][as="style"]['+i+"]")?o.loading=1:(i=e.createElement("link"),o.preload=i,i.addEventListener("load",function(){return o.loading|=1}),i.addEventListener("error",function(){return o.loading|=2}),ft(i,"link",s),st(i),e.head.appendChild(i))}function Pa(e){return'[src="'+It(e)+'"]'}function Js(e){return"script[async]"+e}function Ty(e,i,s){if(i.count++,i.instance===null)switch(i.type){case"style":var o=e.querySelector('style[data-href~="'+It(s.href)+'"]');if(o)return i.instance=o,st(o),o;var u=x({},s,{"data-href":s.href,"data-precedence":s.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),st(o),ft(o,"style",u),Io(o,s.precedence,e),i.instance=o;case"stylesheet":u=Ua(s.href);var d=e.querySelector(Ws(u));if(d)return i.state.loading|=4,i.instance=d,st(d),d;o=_y(s),(u=Zt.get(u))&&mf(o,u),d=(e.ownerDocument||e).createElement("link"),st(d);var y=d;return y._p=new Promise(function(b,E){y.onload=b,y.onerror=E}),ft(d,"link",o),i.state.loading|=4,Io(d,s.precedence,e),i.instance=d;case"script":return d=Pa(s.src),(u=e.querySelector(Js(d)))?(i.instance=u,st(u),u):(o=s,(u=Zt.get(d))&&(o=x({},s),pf(o,u)),e=e.ownerDocument||e,u=e.createElement("script"),st(u),ft(u,"link",o),e.head.appendChild(u),i.instance=u);case"void":return null;default:throw Error(r(443,i.type))}else i.type==="stylesheet"&&(i.state.loading&4)===0&&(o=i.instance,i.state.loading|=4,Io(o,s.precedence,e));return i.instance}function Io(e,i,s){for(var o=s.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),u=o.length?o[o.length-1]:null,d=u,y=0;y title"):null)}function Ww(e,i,s){if(s===1||i.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof i.precedence!="string"||typeof i.href!="string"||i.href==="")break;return!0;case"link":if(typeof i.rel!="string"||typeof i.href!="string"||i.href===""||i.onLoad||i.onError)break;switch(i.rel){case"stylesheet":return e=i.disabled,typeof i.precedence=="string"&&e==null;default:return!0}case"script":if(i.async&&typeof i.async!="function"&&typeof i.async!="symbol"&&!i.onLoad&&!i.onError&&i.src&&typeof i.src=="string")return!0}return!1}function Ny(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Jw(e,i,s,o){if(s.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(s.state.loading&4)===0){if(s.instance===null){var u=Ua(o.href),d=i.querySelector(Ws(u));if(d){i=d._p,i!==null&&typeof i=="object"&&typeof i.then=="function"&&(e.count++,e=Fo.bind(e),i.then(e,e)),s.state.loading|=4,s.instance=d,st(d);return}d=i.ownerDocument||i,o=_y(o),(u=Zt.get(u))&&mf(o,u),d=d.createElement("link"),st(d);var y=d;y._p=new Promise(function(b,E){y.onload=b,y.onerror=E}),ft(d,"link",o),s.instance=d}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(s,i),(i=s.state.preload)&&(s.state.loading&3)===0&&(e.count++,s=Fo.bind(e),i.addEventListener("load",s),i.addEventListener("error",s))}}var gf=0;function e_(e,i){return e.stylesheets&&e.count===0&&Yo(e,e.stylesheets),0gf?50:800)+i);return e.unsuspend=s,function(){e.unsuspend=null,clearTimeout(o),clearTimeout(u)}}:null}function Fo(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Yo(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Go=null;function Yo(e,i){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Go=new Map,i.forEach(t_,e),Go=null,Fo.call(e))}function t_(e,i){if(!(i.state.loading&4)){var s=Go.get(e);if(s)var o=s.get(null);else{s=new Map,Go.set(e,s);for(var u=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(t){console.error(t)}}return n(),kf.exports=xD(),kf.exports}var SD=bD();const jb=K.createContext({});function wD(n){const t=K.useRef(null);return t.current===null&&(t.current=n()),t.current}const _D=typeof window<"u",TD=_D?K.useLayoutEffect:K.useEffect,uh=K.createContext(null);function fh(n,t){n.indexOf(t)===-1&&n.push(t)}function El(n,t){const a=n.indexOf(t);a>-1&&n.splice(a,1)}const yn=(n,t,a)=>a>t?t:a{};const bi={},Mb=n=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(n);function Ob(n){return typeof n=="object"&&n!==null}const Rb=n=>/^0[^.\s]+$/u.test(n);function kb(n){let t;return()=>(t===void 0&&(t=n()),t)}const Jt=n=>n,ED=(n,t)=>a=>t(n(a)),Mr=(...n)=>n.reduce(ED),Sr=(n,t,a)=>{const r=t-n;return r===0?1:(a-n)/r};class hh{constructor(){this.subscriptions=[]}add(t){return fh(this.subscriptions,t),()=>El(this.subscriptions,t)}notify(t,a,r){const l=this.subscriptions.length;if(l)if(l===1)this.subscriptions[0](t,a,r);else for(let c=0;cn*1e3,Qt=n=>n/1e3;function Lb(n,t){return t?n*(1e3/t):0}const zb=(n,t,a)=>(((1-3*a+3*t)*n+(3*a-6*t))*n+3*t)*n,AD=1e-7,ND=12;function DD(n,t,a,r,l){let c,f,h=0;do f=t+(a-t)/2,c=zb(f,r,l)-n,c>0?a=f:t=f;while(Math.abs(c)>AD&&++hDD(c,0,1,n,a);return c=>c===0||c===1?c:zb(l(c),t,r)}const Vb=n=>t=>t<=.5?n(2*t)/2:(2-n(2*(1-t)))/2,Bb=n=>t=>1-n(1-t),Ub=Or(.33,1.53,.69,.99),mh=Bb(Ub),Pb=Vb(mh),Hb=n=>n>=1?1:(n*=2)<1?.5*mh(n):.5*(2-Math.pow(2,-10*(n-1))),ph=n=>1-Math.sin(Math.acos(n)),Ib=Bb(ph),qb=Vb(ph),CD=Or(.42,0,1,1),jD=Or(0,0,.58,1),Fb=Or(.42,0,.58,1),MD=n=>Array.isArray(n)&&typeof n[0]!="number",Gb=n=>Array.isArray(n)&&typeof n[0]=="number",OD={linear:Jt,easeIn:CD,easeInOut:Fb,easeOut:jD,circIn:ph,circInOut:qb,circOut:Ib,backIn:mh,backInOut:Pb,backOut:Ub,anticipate:Hb},RD=n=>typeof n=="string",X0=n=>{if(Gb(n)){dh(n.length===4);const[t,a,r,l]=n;return Or(t,a,r,l)}else if(RD(n))return OD[n];return n},il=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function kD(n,t){let a=new Set,r=new Set,l=!1,c=!1;const f=new WeakSet;let h={delta:0,timestamp:0,isProcessing:!1};function m(v){f.has(v)&&(p.schedule(v),n()),v(h)}const p={schedule:(v,x=!1,S=!1)=>{const T=S&&l?a:r;return x&&f.add(v),T.add(v),v},cancel:v=>{r.delete(v),f.delete(v)},process:v=>{if(h=v,l){c=!0;return}l=!0;const x=a;a=r,r=x,a.forEach(m),a.clear(),l=!1,c&&(c=!1,p.process(v))}};return p}const LD=40;function Yb(n,t){let a=!1,r=!0;const l={delta:0,timestamp:0,isProcessing:!1},c=()=>a=!0,f=il.reduce((H,F)=>(H[F]=kD(c),H),{}),{setup:h,read:m,resolveKeyframes:p,preUpdate:v,update:x,preRender:S,render:w,postRender:T}=f,k=()=>{const H=bi.useManualTiming,F=H?l.timestamp:performance.now();a=!1,H||(l.delta=r?1e3/60:Math.max(Math.min(F-l.timestamp,LD),1)),l.timestamp=F,l.isProcessing=!0,h.process(l),m.process(l),p.process(l),v.process(l),x.process(l),S.process(l),w.process(l),T.process(l),l.isProcessing=!1,a&&t&&(r=!1,n(k))},z=()=>{a=!0,r=!0,l.isProcessing||n(k)};return{schedule:il.reduce((H,F)=>{const $=f[F];return H[F]=(he,J=!1,te=!1)=>(a||z(),$.schedule(he,J,te)),H},{}),cancel:H=>{for(let F=0;F(hl===void 0&&bt.set(dt.isProcessing||bi.useManualTiming?dt.timestamp:performance.now()),hl),set:n=>{hl=n,queueMicrotask(zD)}},Kb=n=>t=>typeof t=="string"&&t.startsWith(n),Xb=Kb("--"),VD=Kb("var(--"),gh=n=>VD(n)?BD.test(n.split("/*")[0].trim()):!1,BD=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function $0(n){return typeof n!="string"?!1:n.split("/*")[0].includes("var(--")}const ls={test:n=>typeof n=="number",parse:parseFloat,transform:n=>n},wr={...ls,transform:n=>yn(0,1,n)},al={...ls,default:1},dr=n=>Math.round(n*1e5)/1e5,yh=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function UD(n){return n==null}const PD=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,vh=(n,t)=>a=>!!(typeof a=="string"&&PD.test(a)&&a.startsWith(n)||t&&!UD(a)&&Object.prototype.hasOwnProperty.call(a,t)),$b=(n,t,a)=>r=>{if(typeof r!="string")return r;const[l,c,f,h]=r.match(yh);return{[n]:parseFloat(l),[t]:parseFloat(c),[a]:parseFloat(f),alpha:h!==void 0?parseFloat(h):1}},HD=n=>yn(0,255,n),Uf={...ls,transform:n=>Math.round(HD(n))},Ki={test:vh("rgb","red"),parse:$b("red","green","blue"),transform:({red:n,green:t,blue:a,alpha:r=1})=>"rgba("+Uf.transform(n)+", "+Uf.transform(t)+", "+Uf.transform(a)+", "+dr(wr.transform(r))+")"};function ID(n){let t="",a="",r="",l="";return n.length>5?(t=n.substring(1,3),a=n.substring(3,5),r=n.substring(5,7),l=n.substring(7,9)):(t=n.substring(1,2),a=n.substring(2,3),r=n.substring(3,4),l=n.substring(4,5),t+=t,a+=a,r+=r,l+=l),{red:parseInt(t,16),green:parseInt(a,16),blue:parseInt(r,16),alpha:l?parseInt(l,16)/255:1}}const bd={test:vh("#"),parse:ID,transform:Ki.transform},Rr=n=>({test:t=>typeof t=="string"&&t.endsWith(n)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${n}`}),mi=Rr("deg"),pn=Rr("%"),W=Rr("px"),qD=Rr("vh"),FD=Rr("vw"),Z0={...pn,parse:n=>pn.parse(n)/100,transform:n=>pn.transform(n*100)},Ka={test:vh("hsl","hue"),parse:$b("hue","saturation","lightness"),transform:({hue:n,saturation:t,lightness:a,alpha:r=1})=>"hsla("+Math.round(n)+", "+pn.transform(dr(t))+", "+pn.transform(dr(a))+", "+dr(wr.transform(r))+")"},nt={test:n=>Ki.test(n)||bd.test(n)||Ka.test(n),parse:n=>Ki.test(n)?Ki.parse(n):Ka.test(n)?Ka.parse(n):bd.parse(n),transform:n=>typeof n=="string"?n:n.hasOwnProperty("red")?Ki.transform(n):Ka.transform(n),getAnimatableNone:n=>{const t=nt.parse(n);return t.alpha=0,nt.transform(t)}},GD=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function YD(n){var t,a;return isNaN(n)&&typeof n=="string"&&(((t=n.match(yh))==null?void 0:t.length)||0)+(((a=n.match(GD))==null?void 0:a.length)||0)>0}const Zb="number",Qb="color",KD="var",XD="var(",Q0="${}",$D=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ns(n){const t=n.toString(),a=[],r={color:[],number:[],var:[]},l=[];let c=0;const h=t.replace($D,m=>(nt.test(m)?(r.color.push(c),l.push(Qb),a.push(nt.parse(m))):m.startsWith(XD)?(r.var.push(c),l.push(KD),a.push(m)):(r.number.push(c),l.push(Zb),a.push(parseFloat(m))),++c,Q0)).split(Q0);return{values:a,split:h,indexes:r,types:l}}function ZD(n){return ns(n).values}function Wb({split:n,types:t}){const a=n.length;return r=>{let l="";for(let c=0;ctypeof n=="number"?0:nt.test(n)?nt.getAnimatableNone(n):n,JD=(n,t)=>typeof n=="number"?t!=null&&t.trim().endsWith("/")?n:0:WD(n);function eC(n){const t=ns(n);return Wb(t)(t.values.map((r,l)=>JD(r,t.split[l])))}const on={test:YD,parse:ZD,createTransformer:QD,getAnimatableNone:eC};function Pf(n,t,a){return a<0&&(a+=1),a>1&&(a-=1),a<1/6?n+(t-n)*6*a:a<1/2?t:a<2/3?n+(t-n)*(2/3-a)*6:n}function tC({hue:n,saturation:t,lightness:a,alpha:r}){n/=360,t/=100,a/=100;let l=0,c=0,f=0;if(!t)l=c=f=a;else{const h=a<.5?a*(1+t):a+t-a*t,m=2*a-h;l=Pf(m,h,n+1/3),c=Pf(m,h,n),f=Pf(m,h,n-1/3)}return{red:Math.round(l*255),green:Math.round(c*255),blue:Math.round(f*255),alpha:r}}function Al(n,t){return a=>a>0?t:n}const Pe=(n,t,a)=>n+(t-n)*a,Hf=(n,t,a)=>{const r=n*n,l=a*(t*t-r)+r;return l<0?0:Math.sqrt(l)},nC=[bd,Ki,Ka],iC=n=>nC.find(t=>t.test(n));function W0(n){const t=iC(n);if(!t)return!1;let a=t.parse(n);return t===Ka&&(a=tC(a)),a}const J0=(n,t)=>{const a=W0(n),r=W0(t);if(!a||!r)return Al(n,t);const l={...a};return c=>(l.red=Hf(a.red,r.red,c),l.green=Hf(a.green,r.green,c),l.blue=Hf(a.blue,r.blue,c),l.alpha=Pe(a.alpha,r.alpha,c),Ki.transform(l))},Sd=new Set(["none","hidden"]);function aC(n,t){return Sd.has(n)?a=>a<=0?n:t:a=>a>=1?t:n}function sC(n,t){return a=>Pe(n,t,a)}function xh(n){return typeof n=="number"?sC:typeof n=="string"?gh(n)?Al:nt.test(n)?J0:lC:Array.isArray(n)?Jb:typeof n=="object"?nt.test(n)?J0:rC:Al}function Jb(n,t){const a=[...n],r=a.length,l=n.map((c,f)=>xh(c)(c,t[f]));return c=>{for(let f=0;f{for(const c in r)a[c]=r[c](l);return a}}function oC(n,t){const a=[],r={color:0,var:0,number:0};for(let l=0;l{const a=on.createTransformer(t),r=ns(n),l=ns(t);return r.indexes.var.length===l.indexes.var.length&&r.indexes.color.length===l.indexes.color.length&&r.indexes.number.length>=l.indexes.number.length?Sd.has(n)&&!l.values.length||Sd.has(t)&&!r.values.length?aC(n,t):Mr(Jb(oC(r,l),l.values),a):Al(n,t)};function e1(n,t,a){return typeof n=="number"&&typeof t=="number"&&typeof a=="number"?Pe(n,t,a):xh(n)(n,t)}const cC=n=>{const t=({timestamp:a})=>n(a);return{start:(a=!0)=>Ve.update(t,a),stop:()=>Si(t),now:()=>dt.isProcessing?dt.timestamp:bt.now()}},t1=(n,t,a=10)=>{let r="";const l=Math.max(Math.round(t/a),2);for(let c=0;c=Nl?1/0:t}function uC(n,t=100,a){const r=a({...n,keyframes:[0,t]}),l=Math.min(bh(r),Nl);return{type:"keyframes",ease:c=>r.next(l*c).value/t,duration:Qt(l)}}const Ye={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function wd(n,t){return n*Math.sqrt(1-t*t)}const fC=12;function dC(n,t,a){let r=a;for(let l=1;l{const v=p*f,x=v*n,S=v-a,w=wd(p,f),T=Math.exp(-x);return If-S/w*T},c=p=>{const x=p*f*n,S=x*a+a,w=Math.pow(f,2)*Math.pow(p,2)*n,T=Math.exp(-x),k=wd(Math.pow(p,2),f);return(-l(p)+If>0?-1:1)*((S-w)*T)/k}):(l=p=>{const v=Math.exp(-p*n),x=(p-a)*n+1;return-If+v*x},c=p=>{const v=Math.exp(-p*n),x=(a-p)*(n*n);return v*x});const h=5/n,m=dC(l,c,h);if(n=Pt(n),isNaN(m))return{stiffness:Ye.stiffness,damping:Ye.damping,duration:n};{const p=Math.pow(m,2)*r;return{stiffness:p,damping:f*2*Math.sqrt(r*p),duration:n}}}const mC=["duration","bounce"],pC=["stiffness","damping","mass"];function ev(n,t){return t.some(a=>n[a]!==void 0)}function gC(n){let t={velocity:Ye.velocity,stiffness:Ye.stiffness,damping:Ye.damping,mass:Ye.mass,isResolvedFromDuration:!1,...n};if(!ev(n,pC)&&ev(n,mC))if(t.velocity=0,n.visualDuration){const a=n.visualDuration,r=2*Math.PI/(a*1.2),l=r*r,c=2*yn(.05,1,1-(n.bounce||0))*Math.sqrt(l);t={...t,mass:Ye.mass,stiffness:l,damping:c}}else{const a=hC({...n,velocity:0});t={...t,...a,mass:Ye.mass},t.isResolvedFromDuration=!0}return t}function Dl(n=Ye.visualDuration,t=Ye.bounce){const a=typeof n!="object"?{visualDuration:n,keyframes:[0,1],bounce:t}:n;let{restSpeed:r,restDelta:l}=a;const c=a.keyframes[0],f=a.keyframes[a.keyframes.length-1],h={done:!1,value:c},{stiffness:m,damping:p,mass:v,duration:x,velocity:S,isResolvedFromDuration:w}=gC({...a,velocity:-Qt(a.velocity||0)}),T=S||0,k=p/(2*Math.sqrt(m*v)),z=f-c,B=Qt(Math.sqrt(m/v)),I=Math.abs(z)<5;r||(r=I?Ye.restSpeed.granular:Ye.restSpeed.default),l||(l=I?Ye.restDelta.granular:Ye.restDelta.default);let H,F,$,he,J,te;if(k<1)$=wd(B,k),he=(T+k*B*z)/$,H=X=>{const we=Math.exp(-k*B*X);return f-we*(he*Math.sin($*X)+z*Math.cos($*X))},J=k*B*he+z*$,te=k*B*z-he*$,F=X=>Math.exp(-k*B*X)*(J*Math.sin($*X)+te*Math.cos($*X));else if(k===1){H=we=>f-Math.exp(-B*we)*(z+(T+B*z)*we);const X=T+B*z;F=we=>Math.exp(-B*we)*(B*X*we-T)}else{const X=B*Math.sqrt(k*k-1);H=_e=>{const He=Math.exp(-k*B*_e),O=Math.min(X*_e,300);return f-He*((T+k*B*z)*Math.sinh(O)+X*z*Math.cosh(O))/X};const we=(T+k*B*z)/X,Ae=k*B*we-z*X,De=k*B*z-we*X;F=_e=>{const He=Math.exp(-k*B*_e),O=Math.min(X*_e,300);return He*(Ae*Math.sinh(O)+De*Math.cosh(O))}}const ue={calculatedDuration:w&&x||null,velocity:X=>Pt(F(X)),next:X=>{if(!w&&k<1){const Ae=Math.exp(-k*B*X),De=Math.sin($*X),_e=Math.cos($*X),He=f-Ae*(he*De+z*_e),O=Pt(Ae*(J*De+te*_e));return h.done=Math.abs(O)<=r&&Math.abs(f-He)<=l,h.value=h.done?f:He,h}const we=H(X);if(w)h.done=X>=x;else{const Ae=Pt(F(X));h.done=Math.abs(Ae)<=r&&Math.abs(f-we)<=l}return h.value=h.done?f:we,h},toString:()=>{const X=Math.min(bh(ue),Nl),we=t1(Ae=>ue.next(X*Ae).value,X,30);return X+"ms "+we},toTransition:()=>{}};return ue}Dl.applyToOptions=n=>{const t=uC(n,100,Dl);return n.ease=t.ease,n.duration=Pt(t.duration),n.type="keyframes",n};const yC=5;function n1(n,t,a){const r=Math.max(t-yC,0);return Lb(a-n(r),t-r)}function _d({keyframes:n,velocity:t=0,power:a=.8,timeConstant:r=325,bounceDamping:l=10,bounceStiffness:c=500,modifyTarget:f,min:h,max:m,restDelta:p=.5,restSpeed:v}){const x=n[0],S={done:!1,value:x},w=te=>h!==void 0&&tem,T=te=>h===void 0?m:m===void 0||Math.abs(h-te)-k*Math.exp(-te/r),H=te=>B+I(te),F=te=>{const ue=I(te),X=H(te);S.done=Math.abs(ue)<=p,S.value=S.done?B:X};let $,he;const J=te=>{w(S.value)&&($=te,he=Dl({keyframes:[S.value,T(S.value)],velocity:n1(H,te,S.value),damping:l,stiffness:c,restDelta:p,restSpeed:v}))};return J(0),{calculatedDuration:null,next:te=>{let ue=!1;return!he&&$===void 0&&(ue=!0,F(te),J(te)),$!==void 0&&te>=$?he.next(te-$):(!ue&&F(te),S)}}}function vC(n,t,a){const r=[],l=a||bi.mix||e1,c=n.length-1;for(let f=0;ft[0];if(c===2&&t[0]===t[1])return()=>t[1];const f=n[0]===n[1];n[0]>n[c-1]&&(n=[...n].reverse(),t=[...t].reverse());const h=vC(t,r,l),m=h.length,p=v=>{if(f&&v1)for(;xp(yn(n[0],n[c-1],v)):p}function bC(n,t){const a=n[n.length-1];for(let r=1;r<=t;r++){const l=Sr(0,t,r);n.push(Pe(a,1,l))}}function SC(n){const t=[0];return bC(t,n.length-1),t}function wC(n,t){return n.map(a=>a*t)}function _C(n,t){return n.map(()=>t||Fb).splice(0,n.length-1)}function hr({duration:n=300,keyframes:t,times:a,ease:r="easeInOut"}){const l=MD(r)?r.map(X0):X0(r),c={done:!1,value:t[0]},f=wC(a&&a.length===t.length?a:SC(t),n),h=xC(f,t,{ease:Array.isArray(l)?l:_C(t,l)});return{calculatedDuration:n,next:m=>(c.value=h(m),c.done=m>=n,c)}}const TC=n=>n!==null;function Wl(n,{repeat:t,repeatType:a="loop"},r,l=1){const c=n.filter(TC),h=l<0||t&&a!=="loop"&&t%2===1?0:c.length-1;return!h||r===void 0?c[h]:r}const EC={decay:_d,inertia:_d,tween:hr,keyframes:hr,spring:Dl};function i1(n){typeof n.type=="string"&&(n.type=EC[n.type])}class Sh{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,a){return this.finished.then(t,a)}}const AC=n=>n/100;class Cl extends Sh{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,l;const{motionValue:a}=this.options;a&&a.updatedAt!==bt.now()&&this.tick(bt.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(l=(r=this.options).onStop)==null||l.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;i1(t);const{type:a=hr,repeat:r=0,repeatDelay:l=0,repeatType:c,velocity:f=0}=t;let{keyframes:h}=t;const m=a||hr;m!==hr&&typeof h[0]!="number"&&(this.mixKeyframes=Mr(AC,e1(h[0],h[1])),h=[0,100]);const p=m({...t,keyframes:h});c==="mirror"&&(this.mirroredGenerator=m({...t,keyframes:[...h].reverse(),velocity:-f})),p.calculatedDuration===null&&(p.calculatedDuration=bh(p));const{calculatedDuration:v}=p;this.calculatedDuration=v,this.resolvedDuration=v+l,this.totalDuration=this.resolvedDuration*(r+1)-l,this.generator=p}updateTime(t){const a=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=a}tick(t,a=!1){const{generator:r,totalDuration:l,mixKeyframes:c,mirroredGenerator:f,resolvedDuration:h,calculatedDuration:m}=this;if(this.startTime===null)return r.next(0);const{delay:p=0,keyframes:v,repeat:x,repeatType:S,repeatDelay:w,type:T,onUpdate:k,finalKeyframe:z}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-l/this.speed,this.startTime)),a?this.currentTime=t:this.updateTime(t);const B=this.currentTime-p*(this.playbackSpeed>=0?1:-1),I=this.playbackSpeed>=0?B<0:B>l;this.currentTime=Math.max(B,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=l);let H=this.currentTime,F=r;if(x){const te=Math.min(this.currentTime,l)/h;let ue=Math.floor(te),X=te%1;!X&&te>=1&&(X=1),X===1&&ue--,ue=Math.min(ue,x+1),!!(ue%2)&&(S==="reverse"?(X=1-X,w&&(X-=w/h)):S==="mirror"&&(F=f)),H=yn(0,1,X)*h}let $;I?(this.delayState.value=v[0],$=this.delayState):$=F.next(H),c&&!I&&($.value=c($.value));let{done:he}=$;!I&&m!==null&&(he=this.playbackSpeed>=0?this.currentTime>=l:this.currentTime<=0);const J=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&he);return J&&T!==_d&&($.value=Wl(v,this.options,z,this.speed)),k&&k($.value),J&&this.finish(),$}then(t,a){return this.finished.then(t,a)}get duration(){return Qt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Qt(t)}get time(){return Qt(this.currentTime)}set time(t){t=Pt(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const a=this.generator.next(t).value;return n1(r=>this.generator.next(r).value,t,a)}get speed(){return this.playbackSpeed}set speed(t){const a=this.playbackSpeed!==t;a&&this.driver&&this.updateTime(bt.now()),this.playbackSpeed=t,a&&this.driver&&(this.time=Qt(this.currentTime))}play(){var l,c;if(this.isStopped)return;const{driver:t=cC,startTime:a}=this.options;this.driver||(this.driver=t(f=>this.tick(f))),(c=(l=this.options).onPlay)==null||c.call(l);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=a??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(bt.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,a;this.notifyFinished(),this.teardown(),this.state="finished",(a=(t=this.options).onComplete)==null||a.call(t)}cancel(){var t,a;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(a=(t=this.options).onCancel)==null||a.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var a;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(a=this.driver)==null||a.stop(),t.observe(this)}}function NC(n){for(let t=1;tn*180/Math.PI,Td=n=>{const t=Xi(Math.atan2(n[1],n[0]));return Ed(t)},DC={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:n=>(Math.abs(n[0])+Math.abs(n[3]))/2,rotate:Td,rotateZ:Td,skewX:n=>Xi(Math.atan(n[1])),skewY:n=>Xi(Math.atan(n[2])),skew:n=>(Math.abs(n[1])+Math.abs(n[2]))/2},Ed=n=>(n=n%360,n<0&&(n+=360),n),tv=Td,nv=n=>Math.sqrt(n[0]*n[0]+n[1]*n[1]),iv=n=>Math.sqrt(n[4]*n[4]+n[5]*n[5]),CC={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:nv,scaleY:iv,scale:n=>(nv(n)+iv(n))/2,rotateX:n=>Ed(Xi(Math.atan2(n[6],n[5]))),rotateY:n=>Ed(Xi(Math.atan2(-n[2],n[0]))),rotateZ:tv,rotate:tv,skewX:n=>Xi(Math.atan(n[4])),skewY:n=>Xi(Math.atan(n[1])),skew:n=>(Math.abs(n[1])+Math.abs(n[4]))/2};function Ad(n){return n.includes("scale")?1:0}function Nd(n,t){if(!n||n==="none")return Ad(t);const a=n.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,l;if(a)r=CC,l=a;else{const h=n.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=DC,l=h}if(!l)return Ad(t);const c=r[t],f=l[1].split(",").map(MC);return typeof c=="function"?c(f):f[c]}const jC=(n,t)=>{const{transform:a="none"}=getComputedStyle(n);return Nd(a,t)};function MC(n){return parseFloat(n.trim())}const cs=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],us=new Set(cs),av=n=>n===ls||n===W,OC=new Set(["x","y","z"]),RC=cs.filter(n=>!OC.has(n));function kC(n){const t=[];return RC.forEach(a=>{const r=n.getValue(a);r!==void 0&&(t.push([a,r.get()]),r.set(a.startsWith("scale")?1:0))}),t}const gi={width:({x:n},{paddingLeft:t="0",paddingRight:a="0",boxSizing:r})=>{const l=n.max-n.min;return r==="border-box"?l:l-parseFloat(t)-parseFloat(a)},height:({y:n},{paddingTop:t="0",paddingBottom:a="0",boxSizing:r})=>{const l=n.max-n.min;return r==="border-box"?l:l-parseFloat(t)-parseFloat(a)},top:(n,{top:t})=>parseFloat(t),left:(n,{left:t})=>parseFloat(t),bottom:({y:n},{top:t})=>parseFloat(t)+(n.max-n.min),right:({x:n},{left:t})=>parseFloat(t)+(n.max-n.min),x:(n,{transform:t})=>Nd(t,"x"),y:(n,{transform:t})=>Nd(t,"y")};gi.translateX=gi.x;gi.translateY=gi.y;const Zi=new Set;let Dd=!1,Cd=!1,jd=!1;function a1(){if(Cd){const n=Array.from(Zi).filter(r=>r.needsMeasurement),t=new Set(n.map(r=>r.element)),a=new Map;t.forEach(r=>{const l=kC(r);l.length&&(a.set(r,l),r.render())}),n.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const l=a.get(r);l&&l.forEach(([c,f])=>{var h;(h=r.getValue(c))==null||h.set(f)})}),n.forEach(r=>r.measureEndState()),n.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Cd=!1,Dd=!1,Zi.forEach(n=>n.complete(jd)),Zi.clear()}function s1(){Zi.forEach(n=>{n.readKeyframes(),n.needsMeasurement&&(Cd=!0)})}function LC(){jd=!0,s1(),a1(),jd=!1}class wh{constructor(t,a,r,l,c,f=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=a,this.name=r,this.motionValue=l,this.element=c,this.isAsync=f}scheduleResolve(){this.state="scheduled",this.isAsync?(Zi.add(this),Dd||(Dd=!0,Ve.read(s1),Ve.resolveKeyframes(a1))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:a,element:r,motionValue:l}=this;if(t[0]===null){const c=l==null?void 0:l.get(),f=t[t.length-1];if(c!==void 0)t[0]=c;else if(r&&a){const h=r.readValue(a,f);h!=null&&(t[0]=h)}t[0]===void 0&&(t[0]=f),l&&c===void 0&&l.set(t[0])}NC(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Zi.delete(this)}cancel(){this.state==="scheduled"&&(Zi.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const zC=n=>n.startsWith("--");function r1(n,t,a){zC(t)?n.style.setProperty(t,a):n.style[t]=a}const VC={};function o1(n,t){const a=kb(n);return()=>VC[t]??a()}const BC=o1(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),l1=o1(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),fr=([n,t,a,r])=>`cubic-bezier(${n}, ${t}, ${a}, ${r})`,sv={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:fr([0,.65,.55,1]),circOut:fr([.55,0,1,.45]),backIn:fr([.31,.01,.66,-.59]),backOut:fr([.33,1.53,.69,.99])};function c1(n,t){if(n)return typeof n=="function"?l1()?t1(n,t):"ease-out":Gb(n)?fr(n):Array.isArray(n)?n.map(a=>c1(a,t)||sv.easeOut):sv[n]}function UC(n,t,a,{delay:r=0,duration:l=300,repeat:c=0,repeatType:f="loop",ease:h="easeOut",times:m}={},p=void 0){const v={[t]:a};m&&(v.offset=m);const x=c1(h,l);Array.isArray(x)&&(v.easing=x);const S={delay:r,duration:l,easing:Array.isArray(x)?"linear":x,fill:"both",iterations:c+1,direction:f==="reverse"?"alternate":"normal"};return p&&(S.pseudoElement=p),n.animate(v,S)}function u1(n){return typeof n=="function"&&"applyToOptions"in n}function PC({type:n,...t}){return u1(n)&&l1()?n.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class f1 extends Sh{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:a,name:r,keyframes:l,pseudoElement:c,allowFlatten:f=!1,finalKeyframe:h,onComplete:m}=t;this.isPseudoElement=!!c,this.allowFlatten=f,this.options=t,dh(typeof t.type!="string");const p=PC(t);this.animation=UC(a,r,l,p,c),p.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!c){const v=Wl(l,this.options,h,this.speed);this.updateMotionValue&&this.updateMotionValue(v),r1(a,r,v),this.animation.cancel()}m==null||m(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,a;(a=(t=this.animation).finish)==null||a.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var a,r,l;const t=(a=this.options)==null?void 0:a.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((l=(r=this.animation).commitStyles)==null||l.call(r))}get duration(){var a,r;const t=((r=(a=this.animation.effect)==null?void 0:a.getComputedTiming)==null?void 0:r.call(a).duration)||0;return Qt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Qt(t)}get time(){return Qt(Number(this.animation.currentTime)||0)}set time(t){const a=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pt(t),a&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:a,rangeEnd:r,observe:l}){var c;return this.allowFlatten&&((c=this.animation.effect)==null||c.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&BC()?(this.animation.timeline=t,a&&(this.animation.rangeStart=a),r&&(this.animation.rangeEnd=r),Jt):l(this)}}const d1={anticipate:Hb,backInOut:Pb,circInOut:qb};function HC(n){return n in d1}function IC(n){typeof n.ease=="string"&&HC(n.ease)&&(n.ease=d1[n.ease])}const qf=10;class qC extends f1{constructor(t){IC(t),i1(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:a,onUpdate:r,onComplete:l,element:c,...f}=this.options;if(!a)return;if(t!==void 0){a.set(t);return}const h=new Cl({...f,autoplay:!1}),m=Math.max(qf,bt.now()-this.startTime),p=yn(0,qf,m-qf),v=h.sample(m).value,{name:x}=this.options;c&&x&&r1(c,x,v),a.setWithVelocity(h.sample(Math.max(0,m-p)).value,v,p),h.stop()}}const rv=(n,t)=>t==="zIndex"?!1:!!(typeof n=="number"||Array.isArray(n)||typeof n=="string"&&(on.test(n)||n==="0")&&!n.startsWith("url("));function FC(n){const t=n[0];if(n.length===1)return!0;for(let a=0;aObject.hasOwnProperty.call(Element.prototype,"animate"));function ZC(n){var x;const{motionValue:t,name:a,repeatDelay:r,repeatType:l,damping:c,type:f,keyframes:h}=n;if(!(((x=t==null?void 0:t.owner)==null?void 0:x.current)instanceof HTMLElement))return!1;const{onUpdate:p,transformTemplate:v}=t.owner.getProps();return $C()&&a&&(h1.has(a)||XC.has(a)&&KC(h))&&(a!=="transform"||!v)&&!p&&!r&&l!=="mirror"&&c!==0&&f!=="inertia"}const QC=40;class WC extends Sh{constructor({autoplay:t=!0,delay:a=0,type:r="keyframes",repeat:l=0,repeatDelay:c=0,repeatType:f="loop",keyframes:h,name:m,motionValue:p,element:v,...x}){var T;super(),this.stop=()=>{var k,z;this._animation&&(this._animation.stop(),(k=this.stopTimeline)==null||k.call(this)),(z=this.keyframeResolver)==null||z.cancel()},this.createdAt=bt.now();const S={autoplay:t,delay:a,type:r,repeat:l,repeatDelay:c,repeatType:f,name:m,motionValue:p,element:v,...x},w=(v==null?void 0:v.KeyframeResolver)||wh;this.keyframeResolver=new w(h,(k,z,B)=>this.onKeyframesResolved(k,z,S,!B),m,p,v),(T=this.keyframeResolver)==null||T.scheduleResolve()}onKeyframesResolved(t,a,r,l){var B,I;this.keyframeResolver=void 0;const{name:c,type:f,velocity:h,delay:m,isHandoff:p,onUpdate:v}=r;this.resolvedAt=bt.now();let x=!0;GC(t,c,f,h)||(x=!1,(bi.instantAnimations||!m)&&(v==null||v(Wl(t,r,a))),t[0]=t[t.length-1],Md(r),r.repeat=0);const w={startTime:l?this.resolvedAt?this.resolvedAt-this.createdAt>QC?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:a,...r,keyframes:t},T=x&&!p&&ZC(w),k=(I=(B=w.motionValue)==null?void 0:B.owner)==null?void 0:I.current;let z;if(T)try{z=new qC({...w,element:k})}catch{z=new Cl(w)}else z=new Cl(w);z.finished.then(()=>{this.notifyFinished()}).catch(Jt),this.pendingTimeline&&(this.stopTimeline=z.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=z}get finished(){return this._animation?this.animation.finished:this._finished}then(t,a){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),LC()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function m1(n,t,a,r=0,l=1){const c=Array.from(n).sort((p,v)=>p.sortNodePosition(v)).indexOf(t),f=n.size,h=(f-1)*r;return typeof a=="function"?a(c,f):l===1?c*r:h-c*r}const JC=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ej(n){const t=JC.exec(n);if(!t)return[,];const[,a,r,l]=t;return[`--${a??r}`,l]}function p1(n,t,a=1){const[r,l]=ej(n);if(!r)return;const c=window.getComputedStyle(t).getPropertyValue(r);if(c){const f=c.trim();return Mb(f)?parseFloat(f):f}return gh(l)?p1(l,t,a+1):l}const tj={type:"spring",stiffness:500,damping:25,restSpeed:10},nj=n=>({type:"spring",stiffness:550,damping:n===0?2*Math.sqrt(550):30,restSpeed:10}),ij={type:"keyframes",duration:.8},aj={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},sj=(n,{keyframes:t})=>t.length>2?ij:us.has(n)?n.startsWith("scale")?nj(t[1]):tj:aj;function g1(n,t){if(n!=null&&n.inherit&&t){const{inherit:a,...r}=n;return{...t,...r}}return n}function _h(n,t){const a=(n==null?void 0:n[t])??(n==null?void 0:n.default)??n;return a!==n?g1(a,n):a}const rj=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function oj(n){for(const t in n)if(!rj.has(t))return!0;return!1}const Th=(n,t,a,r={},l,c)=>f=>{const h=_h(r,n)||{},m=h.delay||r.delay||0;let{elapsed:p=0}=r;p=p-Pt(m);const v={keyframes:Array.isArray(a)?a:[null,a],ease:"easeOut",velocity:t.getVelocity(),...h,delay:-p,onUpdate:S=>{t.set(S),h.onUpdate&&h.onUpdate(S)},onComplete:()=>{f(),h.onComplete&&h.onComplete()},name:n,motionValue:t,element:c?void 0:l};oj(h)||Object.assign(v,sj(n,v)),v.duration&&(v.duration=Pt(v.duration)),v.repeatDelay&&(v.repeatDelay=Pt(v.repeatDelay)),v.from!==void 0&&(v.keyframes[0]=v.from);let x=!1;if((v.type===!1||v.duration===0&&!v.repeatDelay)&&(Md(v),v.delay===0&&(x=!0)),(bi.instantAnimations||bi.skipAnimations||l!=null&&l.shouldSkipAnimations)&&(x=!0,Md(v),v.delay=0),v.allowFlatten=!h.type&&!h.ease,x&&!c&&t.get()!==void 0){const S=Wl(v.keyframes,h);if(S!==void 0){Ve.update(()=>{v.onUpdate(S),v.onComplete()});return}}return h.isSync?new Cl(v):new WC(v)};function ov(n){const t=[{},{}];return n==null||n.values.forEach((a,r)=>{t[0][r]=a.get(),t[1][r]=a.getVelocity()}),t}function Eh(n,t,a,r){if(typeof t=="function"){const[l,c]=ov(r);t=t(a!==void 0?a:n.custom,l,c)}if(typeof t=="string"&&(t=n.variants&&n.variants[t]),typeof t=="function"){const[l,c]=ov(r);t=t(a!==void 0?a:n.custom,l,c)}return t}function Qi(n,t,a){const r=n.getProps();return Eh(r,t,a!==void 0?a:r.custom,n)}const y1=new Set(["width","height","top","left","right","bottom",...cs]),lv=30,lj=n=>!isNaN(parseFloat(n));class cj{constructor(t,a={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var c;const l=bt.now();if(this.updatedAt!==l&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((c=this.events.change)==null||c.notify(this.current),this.dependents))for(const f of this.dependents)f.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=a.owner}setCurrent(t){this.current=t,this.updatedAt=bt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=lj(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,a){this.events[t]||(this.events[t]=new hh);const r=this.events[t].add(a);return t==="change"?()=>{r(),Ve.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,a){this.passiveEffect=t,this.stopPassiveEffect=a}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,a,r){this.set(a),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,a=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,a&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=bt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>lv)return 0;const a=Math.min(this.updatedAt-this.prevUpdatedAt,lv);return Lb(parseFloat(this.current)-parseFloat(this.prevFrameValue),a)}start(t){return this.stop(),new Promise(a=>{this.hasAnimated=!0,this.animation=t(a),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,a;(t=this.dependents)==null||t.clear(),(a=this.events.destroy)==null||a.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function is(n,t){return new cj(n,t)}const Od=n=>Array.isArray(n);function uj(n,t,a){n.hasValue(t)?n.getValue(t).set(a):n.addValue(t,is(a))}function fj(n){return Od(n)?n[n.length-1]||0:n}function dj(n,t){const a=Qi(n,t);let{transitionEnd:r={},transition:l={},...c}=a||{};c={...c,...r};for(const f in c){const h=fj(c[f]);uj(n,f,h)}}const ht=n=>!!(n&&n.getVelocity);function hj(n){return!!(ht(n)&&n.add)}function Rd(n,t){const a=n.getValue("willChange");if(hj(a))return a.add(t);if(!a&&bi.WillChange){const r=new bi.WillChange("auto");n.addValue("willChange",r),r.add(t)}}function Ah(n){return n.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const mj="framerAppearId",v1="data-"+Ah(mj);function x1(n){return n.props[v1]}function pj({protectedKeys:n,needsAnimating:t},a){const r=n.hasOwnProperty(a)&&t[a]!==!0;return t[a]=!1,r}function b1(n,t,{delay:a=0,transitionOverride:r,type:l}={}){let{transition:c,transitionEnd:f,...h}=t;const m=n.getDefaultTransition();c=c?g1(c,m):m;const p=c==null?void 0:c.reduceMotion;r&&(c=r);const v=[],x=l&&n.animationState&&n.animationState.getState()[l];for(const S in h){const w=n.getValue(S,n.latestValues[S]??null),T=h[S];if(T===void 0||x&&pj(x,S))continue;const k={delay:a,..._h(c||{},S)},z=w.get();if(z!==void 0&&!w.isAnimating()&&!Array.isArray(T)&&T===z&&!k.velocity){Ve.update(()=>w.set(T));continue}let B=!1;if(window.MotionHandoffAnimation){const F=x1(n);if(F){const $=window.MotionHandoffAnimation(F,S,Ve);$!==null&&(k.startTime=$,B=!0)}}Rd(n,S);const I=p??n.shouldReduceMotion;w.start(Th(S,w,T,I&&y1.has(S)?{type:!1}:k,n,B));const H=w.animation;H&&v.push(H)}if(f){const S=()=>Ve.update(()=>{f&&dj(n,f)});v.length?Promise.all(v).then(S):S()}return v}function kd(n,t,a={}){var m;const r=Qi(n,t,a.type==="exit"?(m=n.presenceContext)==null?void 0:m.custom:void 0);let{transition:l=n.getDefaultTransition()||{}}=r||{};a.transitionOverride&&(l=a.transitionOverride);const c=r?()=>Promise.all(b1(n,r,a)):()=>Promise.resolve(),f=n.variantChildren&&n.variantChildren.size?(p=0)=>{const{delayChildren:v=0,staggerChildren:x,staggerDirection:S}=l;return gj(n,t,p,v,x,S,a)}:()=>Promise.resolve(),{when:h}=l;if(h){const[p,v]=h==="beforeChildren"?[c,f]:[f,c];return p().then(()=>v())}else return Promise.all([c(),f(a.delay)])}function gj(n,t,a=0,r=0,l=0,c=1,f){const h=[];for(const m of n.variantChildren)m.notify("AnimationStart",t),h.push(kd(m,t,{...f,delay:a+(typeof r=="function"?0:r)+m1(n.variantChildren,m,r,l,c)}).then(()=>m.notify("AnimationComplete",t)));return Promise.all(h)}function yj(n,t,a={}){n.notify("AnimationStart",t);let r;if(Array.isArray(t)){const l=t.map(c=>kd(n,c,a));r=Promise.all(l)}else if(typeof t=="string")r=kd(n,t,a);else{const l=typeof t=="function"?Qi(n,t,a.custom):t;r=Promise.all(b1(n,l,a))}return r.then(()=>{n.notify("AnimationComplete",t)})}const vj={test:n=>n==="auto",parse:n=>n},S1=n=>t=>t.test(n),w1=[ls,W,pn,mi,FD,qD,vj],cv=n=>w1.find(S1(n));function xj(n){return typeof n=="number"?n===0:n!==null?n==="none"||n==="0"||Rb(n):!0}const bj=new Set(["brightness","contrast","saturate","opacity"]);function Sj(n){const[t,a]=n.slice(0,-1).split("(");if(t==="drop-shadow")return n;const[r]=a.match(yh)||[];if(!r)return n;const l=a.replace(r,"");let c=bj.has(t)?1:0;return r!==a&&(c*=100),t+"("+c+l+")"}const wj=/\b([a-z-]*)\(.*?\)/gu,Ld={...on,getAnimatableNone:n=>{const t=n.match(wj);return t?t.map(Sj).join(" "):n}},zd={...on,getAnimatableNone:n=>{const t=on.parse(n);return on.createTransformer(n)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},uv={...ls,transform:Math.round},_j={rotate:mi,rotateX:mi,rotateY:mi,rotateZ:mi,scale:al,scaleX:al,scaleY:al,scaleZ:al,skew:mi,skewX:mi,skewY:mi,distance:W,translateX:W,translateY:W,translateZ:W,x:W,y:W,z:W,perspective:W,transformPerspective:W,opacity:wr,originX:Z0,originY:Z0,originZ:W},Nh={borderWidth:W,borderTopWidth:W,borderRightWidth:W,borderBottomWidth:W,borderLeftWidth:W,borderRadius:W,borderTopLeftRadius:W,borderTopRightRadius:W,borderBottomRightRadius:W,borderBottomLeftRadius:W,width:W,maxWidth:W,height:W,maxHeight:W,top:W,right:W,bottom:W,left:W,inset:W,insetBlock:W,insetBlockStart:W,insetBlockEnd:W,insetInline:W,insetInlineStart:W,insetInlineEnd:W,padding:W,paddingTop:W,paddingRight:W,paddingBottom:W,paddingLeft:W,paddingBlock:W,paddingBlockStart:W,paddingBlockEnd:W,paddingInline:W,paddingInlineStart:W,paddingInlineEnd:W,margin:W,marginTop:W,marginRight:W,marginBottom:W,marginLeft:W,marginBlock:W,marginBlockStart:W,marginBlockEnd:W,marginInline:W,marginInlineStart:W,marginInlineEnd:W,fontSize:W,backgroundPositionX:W,backgroundPositionY:W,..._j,zIndex:uv,fillOpacity:wr,strokeOpacity:wr,numOctaves:uv},Tj={...Nh,color:nt,backgroundColor:nt,outlineColor:nt,fill:nt,stroke:nt,borderColor:nt,borderTopColor:nt,borderRightColor:nt,borderBottomColor:nt,borderLeftColor:nt,filter:Ld,WebkitFilter:Ld,mask:zd,WebkitMask:zd},_1=n=>Tj[n],Ej=new Set([Ld,zd]);function T1(n,t){let a=_1(n);return Ej.has(a)||(a=on),a.getAnimatableNone?a.getAnimatableNone(t):void 0}const Aj=new Set(["auto","none","0"]);function Nj(n,t,a){let r=0,l;for(;r{t.getValue(m).set(p)}),this.resolveNoneKeyframes()}}function E1(n,t,a){if(n==null)return[];if(n instanceof EventTarget)return[n];if(typeof n=="string"){let r=document;const l=(a==null?void 0:a[n])??r.querySelectorAll(n);return l?Array.from(l):[]}return Array.from(n).filter(r=>r!=null)}const A1=(n,t)=>t&&typeof n=="number"?t.transform(n):n;function Cj(n){return Ob(n)&&"offsetHeight"in n&&!("ownerSVGElement"in n)}const{schedule:Dh}=Yb(queueMicrotask,!1),sn={x:!1,y:!1};function N1(){return sn.x||sn.y}function jj(n){return n==="x"||n==="y"?sn[n]?null:(sn[n]=!0,()=>{sn[n]=!1}):sn.x||sn.y?null:(sn.x=sn.y=!0,()=>{sn.x=sn.y=!1})}function D1(n,t){const a=E1(n),r=new AbortController,l={passive:!0,...t,signal:r.signal};return[a,l,()=>r.abort()]}function Mj(n){return!(n.pointerType==="touch"||N1())}function Oj(n,t,a={}){const[r,l,c]=D1(n,a);return r.forEach(f=>{let h=!1,m=!1,p;const v=()=>{f.removeEventListener("pointerleave",T)},x=z=>{p&&(p(z),p=void 0),v()},S=z=>{h=!1,window.removeEventListener("pointerup",S),window.removeEventListener("pointercancel",S),m&&(m=!1,x(z))},w=()=>{h=!0,window.addEventListener("pointerup",S,l),window.addEventListener("pointercancel",S,l)},T=z=>{if(z.pointerType!=="touch"){if(h){m=!0;return}x(z)}},k=z=>{if(!Mj(z))return;m=!1;const B=t(f,z);typeof B=="function"&&(p=B,f.addEventListener("pointerleave",T,l))};f.addEventListener("pointerenter",k,l),f.addEventListener("pointerdown",w,l)}),c}const C1=(n,t)=>t?n===t?!0:C1(n,t.parentElement):!1,Ch=n=>n.pointerType==="mouse"?typeof n.button!="number"||n.button<=0:n.isPrimary!==!1,Rj=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function kj(n){return Rj.has(n.tagName)||n.isContentEditable===!0}const Lj=new Set(["INPUT","SELECT","TEXTAREA"]);function zj(n){return Lj.has(n.tagName)||n.isContentEditable===!0}const ml=new WeakSet;function fv(n){return t=>{t.key==="Enter"&&n(t)}}function Ff(n,t){n.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Vj=(n,t)=>{const a=n.currentTarget;if(!a)return;const r=fv(()=>{if(ml.has(a))return;Ff(a,"down");const l=fv(()=>{Ff(a,"up")}),c=()=>Ff(a,"cancel");a.addEventListener("keyup",l,t),a.addEventListener("blur",c,t)});a.addEventListener("keydown",r,t),a.addEventListener("blur",()=>a.removeEventListener("keydown",r),t)};function dv(n){return Ch(n)&&!N1()}const hv=new WeakSet;function Bj(n,t,a={}){const[r,l,c]=D1(n,a),f=h=>{const m=h.currentTarget;if(!dv(h)||hv.has(h))return;ml.add(m),a.stopPropagation&&hv.add(h);const p=t(m,h),v=(w,T)=>{window.removeEventListener("pointerup",x),window.removeEventListener("pointercancel",S),ml.has(m)&&ml.delete(m),dv(w)&&typeof p=="function"&&p(w,{success:T})},x=w=>{v(w,m===window||m===document||a.useGlobalTarget||C1(m,w.target))},S=w=>{v(w,!1)};window.addEventListener("pointerup",x,l),window.addEventListener("pointercancel",S,l)};return r.forEach(h=>{(a.useGlobalTarget?window:h).addEventListener("pointerdown",f,l),Cj(h)&&(h.addEventListener("focus",p=>Vj(p,l)),!kj(h)&&!h.hasAttribute("tabindex")&&(h.tabIndex=0))}),c}function jh(n){return Ob(n)&&"ownerSVGElement"in n}const pl=new WeakMap;let pi;const j1=(n,t,a)=>(r,l)=>l&&l[0]?l[0][n+"Size"]:jh(r)&&"getBBox"in r?r.getBBox()[t]:r[a],Uj=j1("inline","width","offsetWidth"),Pj=j1("block","height","offsetHeight");function Hj({target:n,borderBoxSize:t}){var a;(a=pl.get(n))==null||a.forEach(r=>{r(n,{get width(){return Uj(n,t)},get height(){return Pj(n,t)}})})}function Ij(n){n.forEach(Hj)}function qj(){typeof ResizeObserver>"u"||(pi=new ResizeObserver(Ij))}function Fj(n,t){pi||qj();const a=E1(n);return a.forEach(r=>{let l=pl.get(r);l||(l=new Set,pl.set(r,l)),l.add(t),pi==null||pi.observe(r)}),()=>{a.forEach(r=>{const l=pl.get(r);l==null||l.delete(t),l!=null&&l.size||pi==null||pi.unobserve(r)})}}const gl=new Set;let Xa;function Gj(){Xa=()=>{const n={get width(){return window.innerWidth},get height(){return window.innerHeight}};gl.forEach(t=>t(n))},window.addEventListener("resize",Xa)}function Yj(n){return gl.add(n),Xa||Gj(),()=>{gl.delete(n),!gl.size&&typeof Xa=="function"&&(window.removeEventListener("resize",Xa),Xa=void 0)}}function mv(n,t){return typeof n=="function"?Yj(n):Fj(n,t)}function Kj(n){return jh(n)&&n.tagName==="svg"}const Xj=[...w1,nt,on],$j=n=>Xj.find(S1(n)),pv=()=>({translate:0,scale:1,origin:0,originPoint:0}),$a=()=>({x:pv(),y:pv()}),gv=()=>({min:0,max:0}),at=()=>({x:gv(),y:gv()}),Zj=new WeakMap;function Jl(n){return n!==null&&typeof n=="object"&&typeof n.start=="function"}function _r(n){return typeof n=="string"||Array.isArray(n)}const Mh=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Oh=["initial",...Mh];function ec(n){return Jl(n.animate)||Oh.some(t=>_r(n[t]))}function M1(n){return!!(ec(n)||n.variants)}function Qj(n,t,a){for(const r in t){const l=t[r],c=a[r];if(ht(l))n.addValue(r,l);else if(ht(c))n.addValue(r,is(l,{owner:n}));else if(c!==l)if(n.hasValue(r)){const f=n.getValue(r);f.liveStyle===!0?f.jump(l):f.hasAnimated||f.set(l)}else{const f=n.getStaticValue(r);n.addValue(r,is(f!==void 0?f:l,{owner:n}))}}for(const r in a)t[r]===void 0&&n.removeValue(r);return t}const Vd={current:null},O1={current:!1},Wj=typeof window<"u";function Jj(){if(O1.current=!0,!!Wj)if(window.matchMedia){const n=window.matchMedia("(prefers-reduced-motion)"),t=()=>Vd.current=n.matches;n.addEventListener("change",t),t()}else Vd.current=!1}const yv=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let jl={};function R1(n){jl=n}function e5(){return jl}class t5{scrapeMotionValuesFromProps(t,a,r){return{}}constructor({parent:t,props:a,presenceContext:r,reducedMotionConfig:l,skipAnimations:c,blockInitialAnimation:f,visualState:h},m={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=wh,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const w=bt.now();this.renderScheduledAtthis.bindToMotionValue(c,l)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(O1.current||Jj(),this.shouldReduceMotion=Vd.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Si(this.notifyUpdate),Si(this.render),this.valueSubscriptions.forEach(a=>a()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const a in this.events)this.events[a].clear();for(const a in this.features){const r=this.features[a];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,a){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),a.accelerate&&h1.has(t)&&this.current instanceof HTMLElement){const{factory:f,keyframes:h,times:m,ease:p,duration:v}=a.accelerate,x=new f1({element:this.current,name:t,keyframes:h,times:m,ease:p,duration:Pt(v)}),S=f(x);this.valueSubscriptions.set(t,()=>{S(),x.cancel()});return}const r=us.has(t);r&&this.onBindTransform&&this.onBindTransform();const l=a.on("change",f=>{this.latestValues[t]=f,this.props.onUpdate&&Ve.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let c;typeof window<"u"&&window.MotionCheckAppearSync&&(c=window.MotionCheckAppearSync(this,t,a)),this.valueSubscriptions.set(t,()=>{l(),c&&c(),a.owner&&a.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in jl){const a=jl[t];if(!a)continue;const{isEnabled:r,Feature:l}=a;if(!this.features[t]&&l&&r(this.props)&&(this.features[t]=new l(this)),this.features[t]){const c=this.features[t];c.isMounted?c.update():(c.mount(),c.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):at()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,a){this.latestValues[t]=a}update(t,a){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=a;for(let r=0;ra.variantChildren.delete(t)}addValue(t,a){const r=this.values.get(t);a!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,a),this.values.set(t,a),this.latestValues[t]=a.get())}removeValue(t){this.values.delete(t);const a=this.valueSubscriptions.get(t);a&&(a(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,a){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&a!==void 0&&(r=is(a===null?void 0:a,{owner:this}),this.addValue(t,r)),r}readValue(t,a){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(Mb(r)||Rb(r))?r=parseFloat(r):!$j(r)&&on.test(a)&&(r=T1(t,a)),this.setBaseTarget(t,ht(r)?r.get():r)),ht(r)?r.get():r}setBaseTarget(t,a){this.baseTarget[t]=a}getBaseTarget(t){var c;const{initial:a}=this.props;let r;if(typeof a=="string"||typeof a=="object"){const f=Eh(this.props,a,(c=this.presenceContext)==null?void 0:c.custom);f&&(r=f[t])}if(a&&r!==void 0)return r;const l=this.getBaseTargetFromProps(this.props,t);return l!==void 0&&!ht(l)?l:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,a){return this.events[t]||(this.events[t]=new hh),this.events[t].add(a)}notify(t,...a){this.events[t]&&this.events[t].notify(...a)}scheduleRenderMicrotask(){Dh.render(this.render)}}class k1 extends t5{constructor(){super(...arguments),this.KeyframeResolver=Dj}sortInstanceNodePosition(t,a){return t.compareDocumentPosition(a)&2?1:-1}getBaseTargetFromProps(t,a){const r=t.style;return r?r[a]:void 0}removeValueFromRenderState(t,{vars:a,style:r}){delete a[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ht(t)&&(this.childSubscription=t.on("change",a=>{this.current&&(this.current.textContent=`${a}`)}))}}class _i{constructor(t){this.isMounted=!1,this.node=t}update(){}}function L1({top:n,left:t,right:a,bottom:r}){return{x:{min:t,max:a},y:{min:n,max:r}}}function n5({x:n,y:t}){return{top:t.min,right:n.max,bottom:t.max,left:n.min}}function i5(n,t){if(!t)return n;const a=t({x:n.left,y:n.top}),r=t({x:n.right,y:n.bottom});return{top:a.y,left:a.x,bottom:r.y,right:r.x}}function Gf(n){return n===void 0||n===1}function Bd({scale:n,scaleX:t,scaleY:a}){return!Gf(n)||!Gf(t)||!Gf(a)}function Gi(n){return Bd(n)||z1(n)||n.z||n.rotate||n.rotateX||n.rotateY||n.skewX||n.skewY}function z1(n){return vv(n.x)||vv(n.y)}function vv(n){return n&&n!=="0%"}function Ml(n,t,a){const r=n-a,l=t*r;return a+l}function xv(n,t,a,r,l){return l!==void 0&&(n=Ml(n,l,r)),Ml(n,a,r)+t}function Ud(n,t=0,a=1,r,l){n.min=xv(n.min,t,a,r,l),n.max=xv(n.max,t,a,r,l)}function V1(n,{x:t,y:a}){Ud(n.x,t.translate,t.scale,t.originPoint),Ud(n.y,a.translate,a.scale,a.originPoint)}const bv=.999999999999,Sv=1.0000000000001;function a5(n,t,a,r=!1){var h;const l=a.length;if(!l)return;t.x=t.y=1;let c,f;for(let m=0;mbv&&(t.x=1),t.ybv&&(t.y=1)}function hn(n,t){n.min+=t,n.max+=t}function wv(n,t,a,r,l=.5){const c=Pe(n.min,n.max,l);Ud(n,t,a,c,r)}function _v(n,t){return typeof n=="string"?parseFloat(n)/100*(t.max-t.min):n}function yl(n,t,a){const r=a??n;wv(n.x,_v(t.x,r.x),t.scaleX,t.scale,t.originX),wv(n.y,_v(t.y,r.y),t.scaleY,t.scale,t.originY)}function B1(n,t){return L1(i5(n.getBoundingClientRect(),t))}function s5(n,t,a){const r=B1(n,a),{scroll:l}=t;return l&&(hn(r.x,l.offset.x),hn(r.y,l.offset.y)),r}const r5={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},o5=cs.length;function l5(n,t,a){let r="",l=!0;for(let c=0;c{if(!t.target)return n;if(typeof n=="string")if(W.test(n))n=parseFloat(n);else return n;const a=Tv(n,t.target.x),r=Tv(n,t.target.y);return`${a}% ${r}%`}},c5={correct:(n,{treeScale:t,projectionDelta:a})=>{const r=n,l=on.parse(n);if(l.length>5)return r;const c=on.createTransformer(n),f=typeof l[0]!="number"?1:0,h=a.x.scale*t.x,m=a.y.scale*t.y;l[0+f]/=h,l[1+f]/=m;const p=Pe(h,m,.5);return typeof l[2+f]=="number"&&(l[2+f]/=p),typeof l[3+f]=="number"&&(l[3+f]/=p),c(l)}},Pd={borderRadius:{...or,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:or,borderTopRightRadius:or,borderBottomLeftRadius:or,borderBottomRightRadius:or,boxShadow:c5};function P1(n,{layout:t,layoutId:a}){return us.has(n)||n.startsWith("origin")||(t||a!==void 0)&&(!!Pd[n]||n==="opacity")}function kh(n,t,a){var f;const r=n.style,l=t==null?void 0:t.style,c={};if(!r)return c;for(const h in r)(ht(r[h])||l&&ht(l[h])||P1(h,n)||((f=a==null?void 0:a.getValue(h))==null?void 0:f.liveStyle)!==void 0)&&(c[h]=r[h]);return c}function u5(n){return window.getComputedStyle(n)}class f5 extends k1{constructor(){super(...arguments),this.type="html",this.renderInstance=U1}readValueFromInstance(t,a){var r;if(us.has(a))return(r=this.projection)!=null&&r.isProjecting?Ad(a):jC(t,a);{const l=u5(t),c=(Xb(a)?l.getPropertyValue(a):l[a])||0;return typeof c=="string"?c.trim():c}}measureInstanceViewportBox(t,{transformPagePoint:a}){return B1(t,a)}build(t,a,r){Rh(t,a,r.transformTemplate)}scrapeMotionValuesFromProps(t,a,r){return kh(t,a,r)}}const d5={offset:"stroke-dashoffset",array:"stroke-dasharray"},h5={offset:"strokeDashoffset",array:"strokeDasharray"};function m5(n,t,a=1,r=0,l=!0){n.pathLength=1;const c=l?d5:h5;n[c.offset]=`${-r}`,n[c.array]=`${t} ${a}`}const p5=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function H1(n,{attrX:t,attrY:a,attrScale:r,pathLength:l,pathSpacing:c=1,pathOffset:f=0,...h},m,p,v){if(Rh(n,h,p),m){n.style.viewBox&&(n.attrs.viewBox=n.style.viewBox);return}n.attrs=n.style,n.style={};const{attrs:x,style:S}=n;x.transform&&(S.transform=x.transform,delete x.transform),(S.transform||x.transformOrigin)&&(S.transformOrigin=x.transformOrigin??"50% 50%",delete x.transformOrigin),S.transform&&(S.transformBox=(v==null?void 0:v.transformBox)??"fill-box",delete x.transformBox);for(const w of p5)x[w]!==void 0&&(S[w]=x[w],delete x[w]);t!==void 0&&(x.x=t),a!==void 0&&(x.y=a),r!==void 0&&(x.scale=r),l!==void 0&&m5(x,l,c,f,!1)}const I1=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),q1=n=>typeof n=="string"&&n.toLowerCase()==="svg";function g5(n,t,a,r){U1(n,t,void 0,r);for(const l in t.attrs)n.setAttribute(I1.has(l)?l:Ah(l),t.attrs[l])}function F1(n,t,a){const r=kh(n,t,a);for(const l in n)if(ht(n[l])||ht(t[l])){const c=cs.indexOf(l)!==-1?"attr"+l.charAt(0).toUpperCase()+l.substring(1):l;r[c]=n[l]}return r}class y5 extends k1{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=at}getBaseTargetFromProps(t,a){return t[a]}readValueFromInstance(t,a){if(us.has(a)){const r=_1(a);return r&&r.default||0}return a=I1.has(a)?a:Ah(a),t.getAttribute(a)}scrapeMotionValuesFromProps(t,a,r){return F1(t,a,r)}build(t,a,r){H1(t,a,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,a,r,l){g5(t,a,r,l)}mount(t){this.isSVGTag=q1(t.tagName),super.mount(t)}}const v5=Oh.length;function G1(n){if(!n)return;if(!n.isControllingVariants){const a=n.parent?G1(n.parent)||{}:{};return n.props.initial!==void 0&&(a.initial=n.props.initial),a}const t={};for(let a=0;aPromise.all(t.map(({animation:a,options:r})=>yj(n,a,r)))}function w5(n){let t=S5(n),a=Ev(),r=!0,l=!1;const c=p=>(v,x)=>{var w;const S=Qi(n,x,p==="exit"?(w=n.presenceContext)==null?void 0:w.custom:void 0);if(S){const{transition:T,transitionEnd:k,...z}=S;v={...v,...z,...k}}return v};function f(p){t=p(n)}function h(p){const{props:v}=n,x=G1(n.parent)||{},S=[],w=new Set;let T={},k=1/0;for(let B=0;Bk&&$,X=!1;const we=Array.isArray(F)?F:[F];let Ae=we.reduce(c(I),{});he===!1&&(Ae={});const{prevResolvedValues:De={}}=H,_e={...De,...Ae},He=Y=>{ue=!0,w.has(Y)&&(X=!0,w.delete(Y)),H.needsAnimating[Y]=!0;const se=n.getValue(Y);se&&(se.liveStyle=!1)};for(const Y in _e){const se=Ae[Y],me=De[Y];if(T.hasOwnProperty(Y))continue;let A=!1;Od(se)&&Od(me)?A=!Y1(se,me):A=se!==me,A?se!=null?He(Y):w.add(Y):se!==void 0&&w.has(Y)?He(Y):H.protectedKeys[Y]=!0}H.prevProp=F,H.prevResolvedValues=Ae,H.isActive&&(T={...T,...Ae}),(r||l)&&n.blockInitialAnimation&&(ue=!1);const O=J&&te;ue&&(!O||X)&&S.push(...we.map(Y=>{const se={type:I};if(typeof Y=="string"&&(r||l)&&!O&&n.manuallyAnimateOnMount&&n.parent){const{parent:me}=n,A=Qi(me,Y);if(me.enteringChildren&&A){const{delayChildren:V}=A.transition||{};se.delay=m1(me.enteringChildren,n,V)}}return{animation:Y,options:se}}))}if(w.size){const B={};if(typeof v.initial!="boolean"){const I=Qi(n,Array.isArray(v.initial)?v.initial[0]:v.initial);I&&I.transition&&(B.transition=I.transition)}w.forEach(I=>{const H=n.getBaseTarget(I),F=n.getValue(I);F&&(F.liveStyle=!0),B[I]=H??null}),S.push({animation:B})}let z=!!S.length;return r&&(v.initial===!1||v.initial===v.animate)&&!n.manuallyAnimateOnMount&&(z=!1),r=!1,l=!1,z?t(S):Promise.resolve()}function m(p,v){var S;if(a[p].isActive===v)return Promise.resolve();(S=n.variantChildren)==null||S.forEach(w=>{var T;return(T=w.animationState)==null?void 0:T.setActive(p,v)}),a[p].isActive=v;const x=h(p);for(const w in a)a[w].protectedKeys={};return x}return{animateChanges:h,setActive:m,setAnimateFunction:f,getState:()=>a,reset:()=>{a=Ev(),l=!0}}}function _5(n,t){return typeof t=="string"?t!==n:Array.isArray(t)?!Y1(t,n):!1}function qi(n=!1){return{isActive:n,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ev(){return{animate:qi(!0),whileInView:qi(),whileHover:qi(),whileTap:qi(),whileDrag:qi(),whileFocus:qi(),exit:qi()}}function Hd(n,t){n.min=t.min,n.max=t.max}function an(n,t){Hd(n.x,t.x),Hd(n.y,t.y)}function Av(n,t){n.translate=t.translate,n.scale=t.scale,n.originPoint=t.originPoint,n.origin=t.origin}const K1=1e-4,T5=1-K1,E5=1+K1,X1=.01,A5=0-X1,N5=0+X1;function St(n){return n.max-n.min}function D5(n,t,a){return Math.abs(n-t)<=a}function Nv(n,t,a,r=.5){n.origin=r,n.originPoint=Pe(t.min,t.max,n.origin),n.scale=St(a)/St(t),n.translate=Pe(a.min,a.max,n.origin)-n.originPoint,(n.scale>=T5&&n.scale<=E5||isNaN(n.scale))&&(n.scale=1),(n.translate>=A5&&n.translate<=N5||isNaN(n.translate))&&(n.translate=0)}function mr(n,t,a,r){Nv(n.x,t.x,a.x,r?r.originX:void 0),Nv(n.y,t.y,a.y,r?r.originY:void 0)}function Dv(n,t,a,r=0){const l=r?Pe(a.min,a.max,r):a.min;n.min=l+t.min,n.max=n.min+St(t)}function C5(n,t,a,r){Dv(n.x,t.x,a.x,r==null?void 0:r.x),Dv(n.y,t.y,a.y,r==null?void 0:r.y)}function Cv(n,t,a,r=0){const l=r?Pe(a.min,a.max,r):a.min;n.min=t.min-l,n.max=n.min+St(t)}function Ol(n,t,a,r){Cv(n.x,t.x,a.x,r==null?void 0:r.x),Cv(n.y,t.y,a.y,r==null?void 0:r.y)}function jv(n,t,a,r,l){return n-=t,n=Ml(n,1/a,r),l!==void 0&&(n=Ml(n,1/l,r)),n}function j5(n,t=0,a=1,r=.5,l,c=n,f=n){if(pn.test(t)&&(t=parseFloat(t),t=Pe(f.min,f.max,t/100)-f.min),typeof t!="number")return;let h=Pe(c.min,c.max,r);n===c&&(h-=t),n.min=jv(n.min,t,a,h,l),n.max=jv(n.max,t,a,h,l)}function Mv(n,t,[a,r,l],c,f){j5(n,t[a],t[r],t[l],t.scale,c,f)}const M5=["x","scaleX","originX"],O5=["y","scaleY","originY"];function Ov(n,t,a,r){Mv(n.x,t,M5,a?a.x:void 0,r?r.x:void 0),Mv(n.y,t,O5,a?a.y:void 0,r?r.y:void 0)}function Rv(n){return n.translate===0&&n.scale===1}function $1(n){return Rv(n.x)&&Rv(n.y)}function kv(n,t){return n.min===t.min&&n.max===t.max}function R5(n,t){return kv(n.x,t.x)&&kv(n.y,t.y)}function Lv(n,t){return Math.round(n.min)===Math.round(t.min)&&Math.round(n.max)===Math.round(t.max)}function Z1(n,t){return Lv(n.x,t.x)&&Lv(n.y,t.y)}function zv(n){return St(n.x)/St(n.y)}function Vv(n,t){return n.translate===t.translate&&n.scale===t.scale&&n.originPoint===t.originPoint}function dn(n){return[n("x"),n("y")]}function k5(n,t,a){let r="";const l=n.x.translate/t.x,c=n.y.translate/t.y,f=(a==null?void 0:a.z)||0;if((l||c||f)&&(r=`translate3d(${l}px, ${c}px, ${f}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),a){const{transformPerspective:p,rotate:v,rotateX:x,rotateY:S,skewX:w,skewY:T}=a;p&&(r=`perspective(${p}px) ${r}`),v&&(r+=`rotate(${v}deg) `),x&&(r+=`rotateX(${x}deg) `),S&&(r+=`rotateY(${S}deg) `),w&&(r+=`skewX(${w}deg) `),T&&(r+=`skewY(${T}deg) `)}const h=n.x.scale*t.x,m=n.y.scale*t.y;return(h!==1||m!==1)&&(r+=`scale(${h}, ${m})`),r||"none"}const Q1=["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"],L5=Q1.length,Bv=n=>typeof n=="string"?parseFloat(n):n,Uv=n=>typeof n=="number"||W.test(n);function z5(n,t,a,r,l,c){l?(n.opacity=Pe(0,a.opacity??1,V5(r)),n.opacityExit=Pe(t.opacity??1,0,B5(r))):c&&(n.opacity=Pe(t.opacity??1,a.opacity??1,r));for(let f=0;frt?1:a(Sr(n,t,r))}function U5(n,t,a){const r=ht(n)?n:is(n);return r.start(Th("",r,t,a)),r.animation}function Tr(n,t,a,r={passive:!0}){return n.addEventListener(t,a,r),()=>n.removeEventListener(t,a)}const P5=(n,t)=>n.depth-t.depth;class H5{constructor(){this.children=[],this.isDirty=!1}add(t){fh(this.children,t),this.isDirty=!0}remove(t){El(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(P5),this.isDirty=!1,this.children.forEach(t)}}function I5(n,t){const a=bt.now(),r=({timestamp:l})=>{const c=l-a;c>=t&&(Si(r),n(c-t))};return Ve.setup(r,!0),()=>Si(r)}function vl(n){return ht(n)?n.get():n}class q5{constructor(){this.members=[]}add(t){fh(this.members,t);for(let a=this.members.length-1;a>=0;a--){const r=this.members[a];if(r===t||r===this.lead||r===this.prevLead)continue;const l=r.instance;(!l||l.isConnected===!1)&&!r.snapshot&&(El(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(El(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const a=this.members[this.members.length-1];a&&this.promote(a)}}relegate(t){var a;for(let r=this.members.indexOf(t)-1;r>=0;r--){const l=this.members[r];if(l.isPresent!==!1&&((a=l.instance)==null?void 0:a.isConnected)!==!1)return this.promote(l),!0}return!1}promote(t,a){var l;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:c}=r.options,{layoutDependency:f}=t.options;(c===void 0||c!==f)&&(t.resumeFrom=r,a&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(l=t.root)!=null&&l.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var a,r,l,c,f;(r=(a=t.options).onExitComplete)==null||r.call(a),(f=(l=t.resumingFrom)==null?void 0:(c=l.options).onExitComplete)==null||f.call(c)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const xl={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Yf=["","X","Y","Z"],F5=1e3;let G5=0;function Kf(n,t,a,r){const{latestValues:l}=t;l[n]&&(a[n]=l[n],t.setStaticValue(n,0),r&&(r[n]=0))}function J1(n){if(n.hasCheckedOptimisedAppear=!0,n.root===n)return;const{visualElement:t}=n.options;if(!t)return;const a=x1(t);if(window.MotionHasOptimisedAnimation(a,"transform")){const{layout:l,layoutId:c}=n.options;window.MotionCancelOptimisedAnimation(a,"transform",Ve,!(l||c))}const{parent:r}=n;r&&!r.hasCheckedOptimisedAppear&&J1(r)}function eS({attachResizeListener:n,defaultParent:t,measureScroll:a,checkIsScrollRoot:r,resetTransform:l}){return class{constructor(f={},h=t==null?void 0:t()){this.id=G5++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(X5),this.nodes.forEach(eM),this.nodes.forEach(tM),this.nodes.forEach($5)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=f,this.root=h?h.root||h:this,this.path=h?[...h.path,h]:[],this.parent=h,this.depth=h?h.depth+1:0;for(let m=0;mthis.root.updateBlockedByResize=!1;Ve.read(()=>{x=window.innerWidth}),n(f,()=>{const w=window.innerWidth;w!==x&&(x=w,this.root.updateBlockedByResize=!0,v&&v(),v=I5(S,250),xl.hasAnimatedSinceResize&&(xl.hasAnimatedSinceResize=!1,this.nodes.forEach(qv)))})}h&&this.root.registerSharedNode(h,this),this.options.animate!==!1&&p&&(h||m)&&this.addEventListener("didUpdate",({delta:v,hasLayoutChanged:x,hasRelativeLayoutChanged:S,layout:w})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const T=this.options.transition||p.getDefaultTransition()||rM,{onLayoutAnimationStart:k,onLayoutAnimationComplete:z}=p.getProps(),B=!this.targetLayout||!Z1(this.targetLayout,w),I=!x&&S;if(this.options.layoutRoot||this.resumeFrom||I||x&&(B||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const H={..._h(T,"layout"),onPlay:k,onComplete:z};(p.shouldReduceMotion||this.options.layoutRoot)&&(H.delay=0,H.type=!1),this.startAnimation(H),this.setAnimationOrigin(v,I)}else x||qv(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=w})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const f=this.getStack();f&&f.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Si(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(nM),this.animationId++)}getTransformTemplate(){const{visualElement:f}=this.options;return f&&f.getProps().transformTemplate}willUpdate(f=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&J1(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let v=0;v{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!St(this.snapshot.measuredBox.x)&&!St(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let m=0;m{const $=F/1e3;Fv(x.x,f.x,$),Fv(x.y,f.y,$),this.setTargetDelta(x),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ol(S,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),aM(this.relativeTarget,this.relativeTargetOrigin,S,$),H&&R5(this.relativeTarget,H)&&(this.isProjectionDirty=!1),H||(H=at()),an(H,this.relativeTarget)),k&&(this.animationValues=v,z5(v,p,this.latestValues,$,I,B)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=$},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(f){var h,m,p;this.notifyListeners("animationStart"),(h=this.currentAnimation)==null||h.stop(),(p=(m=this.resumingFrom)==null?void 0:m.currentAnimation)==null||p.stop(),this.pendingAnimation&&(Si(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Ve.update(()=>{xl.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=is(0)),this.motionValue.jump(0,!1),this.currentAnimation=U5(this.motionValue,[0,1e3],{...f,velocity:0,isSync:!0,onUpdate:v=>{this.mixTargetDelta(v),f.onUpdate&&f.onUpdate(v)},onStop:()=>{},onComplete:()=>{f.onComplete&&f.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const f=this.getStack();f&&f.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(F5),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const f=this.getLead();let{targetWithTransforms:h,target:m,layout:p,latestValues:v}=f;if(!(!h||!m||!p)){if(this!==f&&this.layout&&p&&tS(this.options.animationType,this.layout.layoutBox,p.layoutBox)){m=this.target||at();const x=St(this.layout.layoutBox.x);m.x.min=f.target.x.min,m.x.max=m.x.min+x;const S=St(this.layout.layoutBox.y);m.y.min=f.target.y.min,m.y.max=m.y.min+S}an(h,m),yl(h,v),mr(this.projectionDeltaWithTransform,this.layoutCorrected,h,v)}}registerSharedNode(f,h){this.sharedNodes.has(f)||this.sharedNodes.set(f,new q5),this.sharedNodes.get(f).add(h);const p=h.options.initialPromotionConfig;h.promote({transition:p?p.transition:void 0,preserveFollowOpacity:p&&p.shouldPreserveFollowOpacity?p.shouldPreserveFollowOpacity(h):void 0})}isLead(){const f=this.getStack();return f?f.lead===this:!0}getLead(){var h;const{layoutId:f}=this.options;return f?((h=this.getStack())==null?void 0:h.lead)||this:this}getPrevLead(){var h;const{layoutId:f}=this.options;return f?(h=this.getStack())==null?void 0:h.prevLead:void 0}getStack(){const{layoutId:f}=this.options;if(f)return this.root.sharedNodes.get(f)}promote({needsReset:f,transition:h,preserveFollowOpacity:m}={}){const p=this.getStack();p&&p.promote(this,m),f&&(this.projectionDelta=void 0,this.needsReset=!0),h&&this.setOptions({transition:h})}relegate(){const f=this.getStack();return f?f.relegate(this):!1}resetSkewAndRotation(){const{visualElement:f}=this.options;if(!f)return;let h=!1;const{latestValues:m}=f;if((m.z||m.rotate||m.rotateX||m.rotateY||m.rotateZ||m.skewX||m.skewY)&&(h=!0),!h)return;const p={};m.z&&Kf("z",f,p,this.animationValues);for(let v=0;v{var h;return(h=f.currentAnimation)==null?void 0:h.stop()}),this.root.nodes.forEach(Hv),this.root.sharedNodes.clear()}}}function Y5(n){n.updateLayout()}function K5(n){var a;const t=((a=n.resumeFrom)==null?void 0:a.snapshot)||n.snapshot;if(n.isLead()&&n.layout&&t&&n.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:l}=n.layout,{animationType:c}=n.options,f=t.source!==n.layout.source;if(c==="size")dn(x=>{const S=f?t.measuredBox[x]:t.layoutBox[x],w=St(S);S.min=r[x].min,S.max=S.min+w});else if(c==="x"||c==="y"){const x=c==="x"?"y":"x";Hd(f?t.measuredBox[x]:t.layoutBox[x],r[x])}else tS(c,t.layoutBox,r)&&dn(x=>{const S=f?t.measuredBox[x]:t.layoutBox[x],w=St(r[x]);S.max=S.min+w,n.relativeTarget&&!n.currentAnimation&&(n.isProjectionDirty=!0,n.relativeTarget[x].max=n.relativeTarget[x].min+w)});const h=$a();mr(h,r,t.layoutBox);const m=$a();f?mr(m,n.applyTransform(l,!0),t.measuredBox):mr(m,r,t.layoutBox);const p=!$1(h);let v=!1;if(!n.resumeFrom){const x=n.getClosestProjectingParent();if(x&&!x.resumeFrom){const{snapshot:S,layout:w}=x;if(S&&w){const T=n.options.layoutAnchor||void 0,k=at();Ol(k,t.layoutBox,S.layoutBox,T);const z=at();Ol(z,r,w.layoutBox,T),Z1(k,z)||(v=!0),x.options.layoutRoot&&(n.relativeTarget=z,n.relativeTargetOrigin=k,n.relativeParent=x)}}}n.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:m,layoutDelta:h,hasLayoutChanged:p,hasRelativeLayoutChanged:v})}else if(n.isLead()){const{onExitComplete:r}=n.options;r&&r()}n.options.transition=void 0}function X5(n){n.parent&&(n.isProjecting()||(n.isProjectionDirty=n.parent.isProjectionDirty),n.isSharedProjectionDirty||(n.isSharedProjectionDirty=!!(n.isProjectionDirty||n.parent.isProjectionDirty||n.parent.isSharedProjectionDirty)),n.isTransformDirty||(n.isTransformDirty=n.parent.isTransformDirty))}function $5(n){n.isProjectionDirty=n.isSharedProjectionDirty=n.isTransformDirty=!1}function Z5(n){n.clearSnapshot()}function Hv(n){n.clearMeasurements()}function Q5(n){n.isLayoutDirty=!0,n.updateLayout()}function Iv(n){n.isLayoutDirty=!1}function W5(n){n.isAnimationBlocked&&n.layout&&!n.isLayoutDirty&&(n.snapshot=n.layout,n.isLayoutDirty=!0)}function J5(n){const{visualElement:t}=n.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),n.resetTransform()}function qv(n){n.finishAnimation(),n.targetDelta=n.relativeTarget=n.target=void 0,n.isProjectionDirty=!0}function eM(n){n.resolveTargetDelta()}function tM(n){n.calcProjection()}function nM(n){n.resetSkewAndRotation()}function iM(n){n.removeLeadSnapshot()}function Fv(n,t,a){n.translate=Pe(t.translate,0,a),n.scale=Pe(t.scale,1,a),n.origin=t.origin,n.originPoint=t.originPoint}function Gv(n,t,a,r){n.min=Pe(t.min,a.min,r),n.max=Pe(t.max,a.max,r)}function aM(n,t,a,r){Gv(n.x,t.x,a.x,r),Gv(n.y,t.y,a.y,r)}function sM(n){return n.animationValues&&n.animationValues.opacityExit!==void 0}const rM={duration:.45,ease:[.4,0,.1,1]},Yv=n=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(n),Kv=Yv("applewebkit/")&&!Yv("chrome/")?Math.round:Jt;function Xv(n){n.min=Kv(n.min),n.max=Kv(n.max)}function oM(n){Xv(n.x),Xv(n.y)}function tS(n,t,a){return n==="position"||n==="preserve-aspect"&&!D5(zv(t),zv(a),.2)}function lM(n){var t;return n!==n.root&&((t=n.scroll)==null?void 0:t.wasRoot)}const cM=eS({attachResizeListener:(n,t)=>Tr(n,"resize",t),measureScroll:()=>{var n,t;return{x:document.documentElement.scrollLeft||((n=document.body)==null?void 0:n.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Xf={current:void 0},nS=eS({measureScroll:n=>({x:n.scrollLeft,y:n.scrollTop}),defaultParent:()=>{if(!Xf.current){const n=new cM({});n.mount(window),n.setOptions({layoutScroll:!0}),Xf.current=n}return Xf.current},resetTransform:(n,t)=>{n.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:n=>window.getComputedStyle(n).position==="fixed"}),iS=K.createContext({transformPagePoint:n=>n,isStatic:!1,reducedMotion:"never"});function uM(n=!0){const t=K.useContext(uh);if(t===null)return[!0,null];const{isPresent:a,onExitComplete:r,register:l}=t,c=K.useId();K.useEffect(()=>{if(n)return l(c)},[n]);const f=K.useCallback(()=>n&&r&&r(c),[c,r,n]);return!a&&r?[!1,f]:[!0]}const aS=K.createContext({strict:!1}),$v={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Zv=!1;function fM(){if(Zv)return;const n={};for(const t in $v)n[t]={isEnabled:a=>$v[t].some(r=>!!a[r])};R1(n),Zv=!0}function sS(){return fM(),e5()}function dM(n){const t=sS();for(const a in n)t[a]={...t[a],...n[a]};R1(t)}const hM=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Rl(n){return n.startsWith("while")||n.startsWith("drag")&&n!=="draggable"||n.startsWith("layout")||n.startsWith("onTap")||n.startsWith("onPan")||n.startsWith("onLayout")||hM.has(n)}let rS=n=>!Rl(n);function mM(n){typeof n=="function"&&(rS=t=>t.startsWith("on")?!Rl(t):n(t))}try{mM(require("@emotion/is-prop-valid").default)}catch{}function pM(n,t,a){const r={};for(const l in n)l==="values"&&typeof n.values=="object"||ht(n[l])||(rS(l)||a===!0&&Rl(l)||!t&&!Rl(l)||n.draggable&&l.startsWith("onDrag"))&&(r[l]=n[l]);return r}const tc=K.createContext({});function gM(n,t){if(ec(n)){const{initial:a,animate:r}=n;return{initial:a===!1||_r(a)?a:void 0,animate:_r(r)?r:void 0}}return n.inherit!==!1?t:{}}function yM(n){const{initial:t,animate:a}=gM(n,K.useContext(tc));return K.useMemo(()=>({initial:t,animate:a}),[Qv(t),Qv(a)])}function Qv(n){return Array.isArray(n)?n.join(" "):n}const Lh=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function oS(n,t,a){for(const r in t)!ht(t[r])&&!P1(r,a)&&(n[r]=t[r])}function vM({transformTemplate:n},t){return K.useMemo(()=>{const a=Lh();return Rh(a,t,n),Object.assign({},a.vars,a.style)},[t])}function xM(n,t){const a=n.style||{},r={};return oS(r,a,n),Object.assign(r,vM(n,t)),r}function bM(n,t){const a={},r=xM(n,t);return n.drag&&n.dragListener!==!1&&(a.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=n.drag===!0?"none":`pan-${n.drag==="x"?"y":"x"}`),n.tabIndex===void 0&&(n.onTap||n.onTapStart||n.whileTap)&&(a.tabIndex=0),a.style=r,a}const lS=()=>({...Lh(),attrs:{}});function SM(n,t,a,r){const l=K.useMemo(()=>{const c=lS();return H1(c,t,q1(r),n.transformTemplate,n.style),{...c.attrs,style:{...c.style}}},[t]);if(n.style){const c={};oS(c,n.style,n),l.style={...c,...l.style}}return l}const wM=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function zh(n){return typeof n!="string"||n.includes("-")?!1:!!(wM.indexOf(n)>-1||/[A-Z]/u.test(n))}function _M(n,t,a,{latestValues:r},l,c=!1,f){const m=(f??zh(n)?SM:bM)(t,r,l,n),p=pM(t,typeof n=="string",c),v=n!==K.Fragment?{...p,...m,ref:a}:{},{children:x}=t,S=K.useMemo(()=>ht(x)?x.get():x,[x]);return K.createElement(n,{...v,children:S})}function TM({scrapeMotionValuesFromProps:n,createRenderState:t},a,r,l){return{latestValues:EM(a,r,l,n),renderState:t()}}function EM(n,t,a,r){const l={},c=r(n,{});for(const S in c)l[S]=vl(c[S]);let{initial:f,animate:h}=n;const m=ec(n),p=M1(n);t&&p&&!m&&n.inherit!==!1&&(f===void 0&&(f=t.initial),h===void 0&&(h=t.animate));let v=a?a.initial===!1:!1;v=v||f===!1;const x=v?h:f;if(x&&typeof x!="boolean"&&!Jl(x)){const S=Array.isArray(x)?x:[x];for(let w=0;w(t,a)=>{const r=K.useContext(tc),l=K.useContext(uh),c=()=>TM(n,t,r,l);return a?c():wD(c)},AM=cS({scrapeMotionValuesFromProps:kh,createRenderState:Lh}),NM=cS({scrapeMotionValuesFromProps:F1,createRenderState:lS}),DM=Symbol.for("motionComponentSymbol");function CM(n,t,a){const r=K.useRef(a);K.useInsertionEffect(()=>{r.current=a});const l=K.useRef(null);return K.useCallback(c=>{var h;c&&((h=n.onMount)==null||h.call(n,c));const f=r.current;if(typeof f=="function")if(c){const m=f(c);typeof m=="function"&&(l.current=m)}else l.current?(l.current(),l.current=null):f(c);else f&&(f.current=c);t&&(c?t.mount(c):t.unmount())},[t])}const uS=K.createContext({});function Ya(n){return n&&typeof n=="object"&&Object.prototype.hasOwnProperty.call(n,"current")}function jM(n,t,a,r,l,c){var H,F;const{visualElement:f}=K.useContext(tc),h=K.useContext(aS),m=K.useContext(uh),p=K.useContext(iS),v=p.reducedMotion,x=p.skipAnimations,S=K.useRef(null),w=K.useRef(!1);r=r||h.renderer,!S.current&&r&&(S.current=r(n,{visualState:t,parent:f,props:a,presenceContext:m,blockInitialAnimation:m?m.initial===!1:!1,reducedMotionConfig:v,skipAnimations:x,isSVG:c}),w.current&&S.current&&(S.current.manuallyAnimateOnMount=!0));const T=S.current,k=K.useContext(uS);T&&!T.projection&&l&&(T.type==="html"||T.type==="svg")&&MM(S.current,a,l,k);const z=K.useRef(!1);K.useInsertionEffect(()=>{T&&z.current&&T.update(a,m)});const B=a[v1],I=K.useRef(!!B&&typeof window<"u"&&!((H=window.MotionHandoffIsComplete)!=null&&H.call(window,B))&&((F=window.MotionHasOptimisedAnimation)==null?void 0:F.call(window,B)));return TD(()=>{w.current=!0,T&&(z.current=!0,window.MotionIsMounted=!0,T.updateFeatures(),T.scheduleRenderMicrotask(),I.current&&T.animationState&&T.animationState.animateChanges())}),K.useEffect(()=>{T&&(!I.current&&T.animationState&&T.animationState.animateChanges(),I.current&&(queueMicrotask(()=>{var $;($=window.MotionHandoffMarkAsComplete)==null||$.call(window,B)}),I.current=!1),T.enteringChildren=void 0)}),T}function MM(n,t,a,r){const{layoutId:l,layout:c,drag:f,dragConstraints:h,layoutScroll:m,layoutRoot:p,layoutAnchor:v,layoutCrossfade:x}=t;n.projection=new a(n.latestValues,t["data-framer-portal-id"]?void 0:fS(n.parent)),n.projection.setOptions({layoutId:l,layout:c,alwaysMeasureLayout:!!f||h&&Ya(h),visualElement:n,animationType:typeof c=="string"?c:"both",initialPromotionConfig:r,crossfade:x,layoutScroll:m,layoutRoot:p,layoutAnchor:v})}function fS(n){if(n)return n.options.allowProjection!==!1?n.projection:fS(n.parent)}function $f(n,{forwardMotionProps:t=!1,type:a}={},r,l){r&&dM(r);const c=a?a==="svg":zh(n),f=c?NM:AM;function h(p,v){let x;const S={...K.useContext(iS),...p,layoutId:OM(p)},{isStatic:w}=S,T=yM(p),k=f(p,w);if(!w&&typeof window<"u"){RM();const z=kM(S);x=z.MeasureLayout,T.visualElement=jM(n,k,S,l,z.ProjectionNode,c)}return g.jsxs(tc.Provider,{value:T,children:[x&&T.visualElement?g.jsx(x,{visualElement:T.visualElement,...S}):null,_M(n,p,CM(k,T.visualElement,v),k,w,t,c)]})}h.displayName=`motion.${typeof n=="string"?n:`create(${n.displayName??n.name??""})`}`;const m=K.forwardRef(h);return m[DM]=n,m}function OM({layoutId:n}){const t=K.useContext(jb).id;return t&&n!==void 0?t+"-"+n:n}function RM(n,t){K.useContext(aS).strict}function kM(n){const t=sS(),{drag:a,layout:r}=t;if(!a&&!r)return{};const l={...a,...r};return{MeasureLayout:a!=null&&a.isEnabled(n)||r!=null&&r.isEnabled(n)?l.MeasureLayout:void 0,ProjectionNode:l.ProjectionNode}}function LM(n,t){if(typeof Proxy>"u")return $f;const a=new Map,r=(c,f)=>$f(c,f,n,t),l=(c,f)=>r(c,f);return new Proxy(l,{get:(c,f)=>f==="create"?r:(a.has(f)||a.set(f,$f(f,void 0,n,t)),a.get(f))})}const zM=(n,t)=>t.isSVG??zh(n)?new y5(t):new f5(t,{allowProjection:n!==K.Fragment});class VM extends _i{constructor(t){super(t),t.animationState||(t.animationState=w5(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Jl(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:a}=this.node.prevProps||{};t!==a&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let BM=0;class UM extends _i{constructor(){super(...arguments),this.id=BM++,this.isExitComplete=!1}update(){var c;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:a}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:f,custom:h}=this.node.getProps();if(typeof f=="string"){const m=Qi(this.node,f,h);if(m){const{transition:p,transitionEnd:v,...x}=m;for(const S in x)(c=this.node.getValue(S))==null||c.jump(x[S])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const l=this.node.animationState.setActive("exit",!t);a&&!t&&l.then(()=>{this.isExitComplete=!0,a(this.id)})}mount(){const{register:t,onExitComplete:a}=this.node.presenceContext||{};a&&a(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const PM={animation:{Feature:VM},exit:{Feature:UM}};function kr(n){return{point:{x:n.pageX,y:n.pageY}}}const HM=n=>t=>Ch(t)&&n(t,kr(t));function pr(n,t,a,r){return Tr(n,t,HM(a),r)}const dS=({current:n})=>n?n.ownerDocument.defaultView:null,Wv=(n,t)=>Math.abs(n-t);function IM(n,t){const a=Wv(n.x,t.x),r=Wv(n.y,t.y);return Math.sqrt(a**2+r**2)}const Jv=new Set(["auto","scroll"]);class hS{constructor(t,a,{transformPagePoint:r,contextWindow:l=window,dragSnapToOrigin:c=!1,distanceThreshold:f=3,element:h}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=w=>{this.handleScroll(w.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=sl(this.lastRawMoveEventInfo,this.transformPagePoint));const w=Zf(this.lastMoveEventInfo,this.history),T=this.startEvent!==null,k=IM(w.offset,{x:0,y:0})>=this.distanceThreshold;if(!T&&!k)return;const{point:z}=w,{timestamp:B}=dt;this.history.push({...z,timestamp:B});const{onStart:I,onMove:H}=this.handlers;T||(I&&I(this.lastMoveEvent,w),this.startEvent=this.lastMoveEvent),H&&H(this.lastMoveEvent,w)},this.handlePointerMove=(w,T)=>{this.lastMoveEvent=w,this.lastRawMoveEventInfo=T,this.lastMoveEventInfo=sl(T,this.transformPagePoint),Ve.update(this.updatePoint,!0)},this.handlePointerUp=(w,T)=>{this.end();const{onEnd:k,onSessionEnd:z,resumeAnimation:B}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&B&&B(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const I=Zf(w.type==="pointercancel"?this.lastMoveEventInfo:sl(T,this.transformPagePoint),this.history);this.startEvent&&k&&k(w,I),z&&z(w,I)},!Ch(t))return;this.dragSnapToOrigin=c,this.handlers=a,this.transformPagePoint=r,this.distanceThreshold=f,this.contextWindow=l||window;const m=kr(t),p=sl(m,this.transformPagePoint),{point:v}=p,{timestamp:x}=dt;this.history=[{...v,timestamp:x}];const{onSessionStart:S}=a;S&&S(t,Zf(p,this.history)),this.removeListeners=Mr(pr(this.contextWindow,"pointermove",this.handlePointerMove),pr(this.contextWindow,"pointerup",this.handlePointerUp),pr(this.contextWindow,"pointercancel",this.handlePointerUp)),h&&this.startScrollTracking(h)}startScrollTracking(t){let a=t.parentElement;for(;a;){const r=getComputedStyle(a);(Jv.has(r.overflowX)||Jv.has(r.overflowY))&&this.scrollPositions.set(a,{x:a.scrollLeft,y:a.scrollTop}),a=a.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const a=this.scrollPositions.get(t);if(!a)return;const r=t===window,l=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},c={x:l.x-a.x,y:l.y-a.y};c.x===0&&c.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=c.x,this.lastMoveEventInfo.point.y+=c.y):this.history.length>0&&(this.history[0].x-=c.x,this.history[0].y-=c.y),this.scrollPositions.set(t,l),Ve.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Si(this.updatePoint)}}function sl(n,t){return t?{point:t(n.point)}:n}function ex(n,t){return{x:n.x-t.x,y:n.y-t.y}}function Zf({point:n},t){return{point:n,delta:ex(n,mS(t)),offset:ex(n,qM(t)),velocity:FM(t,.1)}}function qM(n){return n[0]}function mS(n){return n[n.length-1]}function FM(n,t){if(n.length<2)return{x:0,y:0};let a=n.length-1,r=null;const l=mS(n);for(;a>=0&&(r=n[a],!(l.timestamp-r.timestamp>Pt(t)));)a--;if(!r)return{x:0,y:0};r===n[0]&&n.length>2&&l.timestamp-r.timestamp>Pt(t)*2&&(r=n[1]);const c=Qt(l.timestamp-r.timestamp);if(c===0)return{x:0,y:0};const f={x:(l.x-r.x)/c,y:(l.y-r.y)/c};return f.x===1/0&&(f.x=0),f.y===1/0&&(f.y=0),f}function GM(n,{min:t,max:a},r){return t!==void 0&&na&&(n=r?Pe(a,n,r.max):Math.min(n,a)),n}function tx(n,t,a){return{min:t!==void 0?n.min+t:void 0,max:a!==void 0?n.max+a-(n.max-n.min):void 0}}function YM(n,{top:t,left:a,bottom:r,right:l}){return{x:tx(n.x,a,l),y:tx(n.y,t,r)}}function nx(n,t){let a=t.min-n.min,r=t.max-n.max;return t.max-t.minr?a=Sr(t.min,t.max-r,n.min):r>l&&(a=Sr(n.min,n.max-l,t.min)),yn(0,1,a)}function $M(n,t){const a={};return t.min!==void 0&&(a.min=t.min-n.min),t.max!==void 0&&(a.max=t.max-n.min),a}const Id=.35;function ZM(n=Id){return n===!1?n=0:n===!0&&(n=Id),{x:ix(n,"left","right"),y:ix(n,"top","bottom")}}function ix(n,t,a){return{min:ax(n,t),max:ax(n,a)}}function ax(n,t){return typeof n=="number"?n:n[t]||0}const QM=new WeakMap;class WM{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=at(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:a=!1,distanceThreshold:r}={}){const{presenceContext:l}=this.visualElement;if(l&&l.isPresent===!1)return;const c=x=>{a&&this.snapToCursor(kr(x).point),this.stopAnimation()},f=(x,S)=>{const{drag:w,dragPropagation:T,onDragStart:k}=this.getProps();if(w&&!T&&(this.openDragLock&&this.openDragLock(),this.openDragLock=jj(w),!this.openDragLock))return;this.latestPointerEvent=x,this.latestPanInfo=S,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),dn(B=>{let I=this.getAxisMotionValue(B).get()||0;if(pn.test(I)){const{projection:H}=this.visualElement;if(H&&H.layout){const F=H.layout.layoutBox[B];F&&(I=St(F)*(parseFloat(I)/100))}}this.originPoint[B]=I}),k&&Ve.update(()=>k(x,S),!1,!0),Rd(this.visualElement,"transform");const{animationState:z}=this.visualElement;z&&z.setActive("whileDrag",!0)},h=(x,S)=>{this.latestPointerEvent=x,this.latestPanInfo=S;const{dragPropagation:w,dragDirectionLock:T,onDirectionLock:k,onDrag:z}=this.getProps();if(!w&&!this.openDragLock)return;const{offset:B}=S;if(T&&this.currentDirection===null){this.currentDirection=e3(B),this.currentDirection!==null&&k&&k(this.currentDirection);return}this.updateAxis("x",S.point,B),this.updateAxis("y",S.point,B),this.visualElement.render(),z&&Ve.update(()=>z(x,S),!1,!0)},m=(x,S)=>{this.latestPointerEvent=x,this.latestPanInfo=S,this.stop(x,S),this.latestPointerEvent=null,this.latestPanInfo=null},p=()=>{const{dragSnapToOrigin:x}=this.getProps();(x||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:v}=this.getProps();this.panSession=new hS(t,{onSessionStart:c,onStart:f,onMove:h,onSessionEnd:m,resumeAnimation:p},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:v,distanceThreshold:r,contextWindow:dS(this.visualElement),element:this.visualElement.current})}stop(t,a){const r=t||this.latestPointerEvent,l=a||this.latestPanInfo,c=this.isDragging;if(this.cancel(),!c||!l||!r)return;const{velocity:f}=l;this.startAnimation(f);const{onDragEnd:h}=this.getProps();h&&Ve.postRender(()=>h(r,l))}cancel(){this.isDragging=!1;const{projection:t,animationState:a}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),a&&a.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,a,r){const{drag:l}=this.getProps();if(!r||!rl(t,l,this.currentDirection))return;const c=this.getAxisMotionValue(t);let f=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(f=GM(f,this.constraints[t],this.elastic[t])),c.set(f)}resolveConstraints(){var c;const{dragConstraints:t,dragElastic:a}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(c=this.visualElement.projection)==null?void 0:c.layout,l=this.constraints;t&&Ya(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=YM(r.layoutBox,t):this.constraints=!1,this.elastic=ZM(a),l!==this.constraints&&!Ya(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&dn(f=>{this.constraints!==!1&&this.getAxisMotionValue(f)&&(this.constraints[f]=$M(r.layoutBox[f],this.constraints[f]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:a}=this.getProps();if(!t||!Ya(t))return!1;const r=t.current,{projection:l}=this.visualElement;if(!l||!l.layout)return!1;const c=s5(r,l.root,this.visualElement.getTransformPagePoint());let f=KM(l.layout.layoutBox,c);if(a){const h=a(n5(f));this.hasMutatedConstraints=!!h,h&&(f=L1(h))}return f}startAnimation(t){const{drag:a,dragMomentum:r,dragElastic:l,dragTransition:c,dragSnapToOrigin:f,onDragTransitionEnd:h}=this.getProps(),m=this.constraints||{},p=dn(v=>{if(!rl(v,a,this.currentDirection))return;let x=m&&m[v]||{};(f===!0||f===v)&&(x={min:0,max:0});const S=l?200:1e6,w=l?40:1e7,T={type:"inertia",velocity:r?t[v]:0,bounceStiffness:S,bounceDamping:w,timeConstant:750,restDelta:1,restSpeed:10,...c,...x};return this.startAxisValueAnimation(v,T)});return Promise.all(p).then(h)}startAxisValueAnimation(t,a){const r=this.getAxisMotionValue(t);return Rd(this.visualElement,t),r.start(Th(t,r,0,a,this.visualElement,!1))}stopAnimation(){dn(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const a=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),l=r[a];return l||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){dn(a=>{const{drag:r}=this.getProps();if(!rl(a,r,this.currentDirection))return;const{projection:l}=this.visualElement,c=this.getAxisMotionValue(a);if(l&&l.layout){const{min:f,max:h}=l.layout.layoutBox[a],m=c.get()||0;c.set(t[a]-Pe(f,h,.5)+m)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:a}=this.getProps(),{projection:r}=this.visualElement;if(!Ya(a)||!r||!this.constraints)return;this.stopAnimation();const l={x:0,y:0};dn(f=>{const h=this.getAxisMotionValue(f);if(h&&this.constraints!==!1){const m=h.get();l[f]=XM({min:m,max:m},this.constraints[f])}});const{transformTemplate:c}=this.visualElement.getProps();this.visualElement.current.style.transform=c?c({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),dn(f=>{if(!rl(f,t,null))return;const h=this.getAxisMotionValue(f),{min:m,max:p}=this.constraints[f];h.set(Pe(m,p,l[f]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;QM.set(this.visualElement,this);const t=this.visualElement.current,a=pr(t,"pointerdown",p=>{const{drag:v,dragListener:x=!0}=this.getProps(),S=p.target,w=S!==t&&zj(S);v&&x&&!w&&this.start(p)});let r;const l=()=>{const{dragConstraints:p}=this.getProps();Ya(p)&&p.current&&(this.constraints=this.resolveRefConstraints(),r||(r=JM(t,p.current,()=>this.scalePositionWithinConstraints())))},{projection:c}=this.visualElement,f=c.addEventListener("measure",l);c&&!c.layout&&(c.root&&c.root.updateScroll(),c.updateLayout()),Ve.read(l);const h=Tr(window,"resize",()=>this.scalePositionWithinConstraints()),m=c.addEventListener("didUpdate",(({delta:p,hasLayoutChanged:v})=>{this.isDragging&&v&&(dn(x=>{const S=this.getAxisMotionValue(x);S&&(this.originPoint[x]+=p[x].translate,S.set(S.get()+p[x].translate))}),this.visualElement.render())}));return()=>{h(),a(),f(),m&&m(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:a=!1,dragDirectionLock:r=!1,dragPropagation:l=!1,dragConstraints:c=!1,dragElastic:f=Id,dragMomentum:h=!0}=t;return{...t,drag:a,dragDirectionLock:r,dragPropagation:l,dragConstraints:c,dragElastic:f,dragMomentum:h}}}function sx(n){let t=!0;return()=>{if(t){t=!1;return}n()}}function JM(n,t,a){const r=mv(n,sx(a)),l=mv(t,sx(a));return()=>{r(),l()}}function rl(n,t,a){return(t===!0||t===n)&&(a===null||a===n)}function e3(n,t=10){let a=null;return Math.abs(n.y)>t?a="y":Math.abs(n.x)>t&&(a="x"),a}class t3 extends _i{constructor(t){super(t),this.removeGroupControls=Jt,this.removeListeners=Jt,this.controls=new WM(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Jt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:a}=this.node.prevProps||{};t!==a&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Qf=n=>(t,a)=>{n&&Ve.update(()=>n(t,a),!1,!0)};class n3 extends _i{constructor(){super(...arguments),this.removePointerDownListener=Jt}onPointerDown(t){this.session=new hS(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:dS(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:a,onPan:r,onPanEnd:l}=this.node.getProps();return{onSessionStart:Qf(t),onStart:Qf(a),onMove:Qf(r),onEnd:(c,f)=>{delete this.session,l&&Ve.postRender(()=>l(c,f))}}}mount(){this.removePointerDownListener=pr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Wf=!1;class i3 extends K.Component{componentDidMount(){const{visualElement:t,layoutGroup:a,switchLayoutGroup:r,layoutId:l}=this.props,{projection:c}=t;c&&(a.group&&a.group.add(c),r&&r.register&&l&&r.register(c),Wf&&c.root.didUpdate(),c.addEventListener("animationComplete",()=>{this.safeToRemove()}),c.setOptions({...c.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),xl.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:a,visualElement:r,drag:l,isPresent:c}=this.props,{projection:f}=r;return f&&(f.isPresent=c,t.layoutDependency!==a&&f.setOptions({...f.options,layoutDependency:a}),Wf=!0,l||t.layoutDependency!==a||a===void 0||t.isPresent!==c?f.willUpdate():this.safeToRemove(),t.isPresent!==c&&(c?f.promote():f.relegate()||Ve.postRender(()=>{const h=f.getStack();(!h||!h.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:a}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=a,r.root.didUpdate(),Dh.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:a,switchLayoutGroup:r}=this.props,{projection:l}=t;Wf=!0,l&&(l.scheduleCheckAfterUnmount(),a&&a.group&&a.group.remove(l),r&&r.deregister&&r.deregister(l))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function pS(n){const[t,a]=uM(),r=K.useContext(jb);return g.jsx(i3,{...n,layoutGroup:r,switchLayoutGroup:K.useContext(uS),isPresent:t,safeToRemove:a})}const a3={pan:{Feature:n3},drag:{Feature:t3,ProjectionNode:nS,MeasureLayout:pS}};function rx(n,t,a){const{props:r}=n;n.animationState&&r.whileHover&&n.animationState.setActive("whileHover",a==="Start");const l="onHover"+a,c=r[l];c&&Ve.postRender(()=>c(t,kr(t)))}class s3 extends _i{mount(){const{current:t}=this.node;t&&(this.unmount=Oj(t,(a,r)=>(rx(this.node,r,"Start"),l=>rx(this.node,l,"End"))))}unmount(){}}class r3 extends _i{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Mr(Tr(this.node.current,"focus",()=>this.onFocus()),Tr(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function ox(n,t,a){const{props:r}=n;if(n.current instanceof HTMLButtonElement&&n.current.disabled)return;n.animationState&&r.whileTap&&n.animationState.setActive("whileTap",a==="Start");const l="onTap"+(a==="End"?"":a),c=r[l];c&&Ve.postRender(()=>c(t,kr(t)))}class o3 extends _i{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:a,propagate:r}=this.node.props;this.unmount=Bj(t,(l,c)=>(ox(this.node,c,"Start"),(f,{success:h})=>ox(this.node,f,h?"End":"Cancel")),{useGlobalTarget:a,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const qd=new WeakMap,Jf=new WeakMap,l3=n=>{const t=qd.get(n.target);t&&t(n)},c3=n=>{n.forEach(l3)};function u3({root:n,...t}){const a=n||document;Jf.has(a)||Jf.set(a,{});const r=Jf.get(a),l=JSON.stringify(t);return r[l]||(r[l]=new IntersectionObserver(c3,{root:n,...t})),r[l]}function f3(n,t,a){const r=u3(t);return qd.set(n,a),r.observe(n),()=>{qd.delete(n),r.unobserve(n)}}const d3={some:0,all:1};class h3 extends _i{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var m;(m=this.stopObserver)==null||m.call(this);const{viewport:t={}}=this.node.getProps(),{root:a,margin:r,amount:l="some",once:c}=t,f={root:a?a.current:void 0,rootMargin:r,threshold:typeof l=="number"?l:d3[l]},h=p=>{const{isIntersecting:v}=p;if(this.isInView===v||(this.isInView=v,c&&!v&&this.hasEnteredView))return;v&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",v);const{onViewportEnter:x,onViewportLeave:S}=this.node.getProps(),w=v?x:S;w&&w(p)};this.stopObserver=f3(this.node.current,f,h)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:a}=this.node;["amount","margin","root"].some(m3(t,a))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function m3({viewport:n={}},{viewport:t={}}={}){return a=>n[a]!==t[a]}const p3={inView:{Feature:h3},tap:{Feature:o3},focus:{Feature:r3},hover:{Feature:s3}},g3={layout:{ProjectionNode:nS,MeasureLayout:pS}},y3={...PM,...p3,...a3,...g3},Za=LM(y3,zM);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const v3=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),x3=n=>n.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,a,r)=>r?r.toUpperCase():a.toLowerCase()),lx=n=>{const t=x3(n);return t.charAt(0).toUpperCase()+t.slice(1)},pS=(...n)=>n.filter((t,a,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===a).join(" ").trim(),b3=n=>{for(const t in n)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/** + */const v3=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),x3=n=>n.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,a,r)=>r?r.toUpperCase():a.toLowerCase()),lx=n=>{const t=x3(n);return t.charAt(0).toUpperCase()+t.slice(1)},gS=(...n)=>n.filter((t,a,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===a).join(" ").trim(),b3=n=>{for(const t in n)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -75,12 +75,12 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const w3=K.forwardRef(({color:n="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:r,className:l="",children:c,iconNode:f,...h},m)=>K.createElement("svg",{ref:m,...S3,width:t,height:t,stroke:n,strokeWidth:r?Number(a)*24/Number(t):a,className:pS("lucide",l),...!c&&!b3(h)&&{"aria-hidden":"true"},...h},[...f.map(([p,v])=>K.createElement(p,v)),...Array.isArray(c)?c:[c]]));/** + */const w3=K.forwardRef(({color:n="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:r,className:l="",children:c,iconNode:f,...h},m)=>K.createElement("svg",{ref:m,...S3,width:t,height:t,stroke:n,strokeWidth:r?Number(a)*24/Number(t):a,className:gS("lucide",l),...!c&&!b3(h)&&{"aria-hidden":"true"},...h},[...f.map(([p,v])=>K.createElement(p,v)),...Array.isArray(c)?c:[c]]));/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const Se=(n,t)=>{const a=K.forwardRef(({className:r,...l},c)=>K.createElement(w3,{ref:c,iconNode:t,className:pS(`lucide-${v3(lx(n))}`,`lucide-${n}`,r),...l}));return a.displayName=lx(n),a};/** + */const Se=(n,t)=>{const a=K.forwardRef(({className:r,...l},c)=>K.createElement(w3,{ref:c,iconNode:t,className:gS(`lucide-${v3(lx(n))}`,`lucide-${n}`,r),...l}));return a.displayName=lx(n),a};/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -135,7 +135,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const P3=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],gS=Se("cpu",P3);/** + */const P3=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],yS=Se("cpu",P3);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -145,7 +145,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const q3=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],yS=Se("external-link",q3);/** + */const q3=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],vS=Se("external-link",q3);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -175,7 +175,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const J3=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],vS=Se("layers",J3);/** + */const J3=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],xS=Se("layers",J3);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -200,7 +200,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const lO=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}]],xS=Se("panel-top",lO);/** + */const lO=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}]],bS=Se("panel-top",lO);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -235,7 +235,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const xO=[["path",{d:"m10.065 12.493-6.18 1.318a.934.934 0 0 1-1.108-.702l-.537-2.15a1.07 1.07 0 0 1 .691-1.265l13.504-4.44",key:"k4qptu"}],["path",{d:"m13.56 11.747 4.332-.924",key:"19l80z"}],["path",{d:"m16 21-3.105-6.21",key:"7oh9d"}],["path",{d:"M16.485 5.94a2 2 0 0 1 1.455-2.425l1.09-.272a1 1 0 0 1 1.212.727l1.515 6.06a1 1 0 0 1-.727 1.213l-1.09.272a2 2 0 0 1-2.425-1.455z",key:"m7xp4m"}],["path",{d:"m6.158 8.633 1.114 4.456",key:"74o979"}],["path",{d:"m8 21 3.105-6.21",key:"1fvxut"}],["circle",{cx:"12",cy:"13",r:"2",key:"1c1ljs"}]],bS=Se("telescope",xO);/** + */const xO=[["path",{d:"m10.065 12.493-6.18 1.318a.934.934 0 0 1-1.108-.702l-.537-2.15a1.07 1.07 0 0 1 .691-1.265l13.504-4.44",key:"k4qptu"}],["path",{d:"m13.56 11.747 4.332-.924",key:"19l80z"}],["path",{d:"m16 21-3.105-6.21",key:"7oh9d"}],["path",{d:"M16.485 5.94a2 2 0 0 1 1.455-2.425l1.09-.272a1 1 0 0 1 1.212.727l1.515 6.06a1 1 0 0 1-.727 1.213l-1.09.272a2 2 0 0 1-2.425-1.455z",key:"m7xp4m"}],["path",{d:"m6.158 8.633 1.114 4.456",key:"74o979"}],["path",{d:"m8 21 3.105-6.21",key:"1fvxut"}],["circle",{cx:"12",cy:"13",r:"2",key:"1c1ljs"}]],SS=Se("telescope",xO);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. @@ -245,22 +245,22 @@ Error generating stack: `+o.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const wO=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],SS=Se("trending-up",wO);/** + */const wO=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],wS=Se("trending-up",wO);/** * @license lucide-react v0.546.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const _O=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],TO=Se("zap",_O),EO="modulepreload",AO=function(n){return"/pro/"+n},cx={},qe=function(t,a,r){let l=Promise.resolve();if(a&&a.length>0){let f=function(p){return Promise.all(p.map(v=>Promise.resolve(v).then(x=>({status:"fulfilled",value:x}),x=>({status:"rejected",reason:x}))))};document.getElementsByTagName("link");const h=document.querySelector("meta[property=csp-nonce]"),m=(h==null?void 0:h.nonce)||(h==null?void 0:h.getAttribute("nonce"));l=f(a.map(p=>{if(p=AO(p),p in cx)return;cx[p]=!0;const v=p.endsWith(".css"),x=v?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${x}`))return;const S=document.createElement("link");if(S.rel=v?"stylesheet":EO,v||(S.as="script"),S.crossOrigin="",S.href=p,m&&S.setAttribute("nonce",m),document.head.appendChild(S),v)return new Promise((w,T)=>{S.addEventListener("load",w),S.addEventListener("error",()=>T(new Error(`Unable to preload CSS for ${p}`)))})}))}function c(f){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=f,window.dispatchEvent(h),!h.defaultPrevented)throw f}return l.then(f=>{for(const h of f||[])h.status==="rejected"&&c(h.reason);return t().catch(c)})};var ed={};const re=n=>typeof n=="string",lr=()=>{let n,t;const a=new Promise((r,l)=>{n=r,t=l});return a.resolve=n,a.reject=t,a},ux=n=>n==null?"":""+n,NO=(n,t,a)=>{n.forEach(r=>{t[r]&&(a[r]=t[r])})},DO=/###/g,fx=n=>n&&n.indexOf("###")>-1?n.replace(DO,"."):n,dx=n=>!n||re(n),gr=(n,t,a)=>{const r=re(t)?t.split("."):t;let l=0;for(;l{const{obj:r,k:l}=gr(n,t,Object);if(r!==void 0||t.length===1){r[l]=a;return}let c=t[t.length-1],f=t.slice(0,t.length-1),h=gr(n,f,Object);for(;h.obj===void 0&&f.length;)c=`${f[f.length-1]}.${c}`,f=f.slice(0,f.length-1),h=gr(n,f,Object),h!=null&&h.obj&&typeof h.obj[`${h.k}.${c}`]<"u"&&(h.obj=void 0);h.obj[`${h.k}.${c}`]=a},CO=(n,t,a,r)=>{const{obj:l,k:c}=gr(n,t,Object);l[c]=l[c]||[],l[c].push(a)},Ll=(n,t)=>{const{obj:a,k:r}=gr(n,t);if(a&&Object.prototype.hasOwnProperty.call(a,r))return a[r]},jO=(n,t,a)=>{const r=Ll(n,a);return r!==void 0?r:Ll(t,a)},wS=(n,t,a)=>{for(const r in t)r!=="__proto__"&&r!=="constructor"&&(r in n?re(n[r])||n[r]instanceof String||re(t[r])||t[r]instanceof String?a&&(n[r]=t[r]):wS(n[r],t[r],a):n[r]=t[r]);return n},Fi=n=>n.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var MO={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const OO=n=>re(n)?n.replace(/[&<>"'\/]/g,t=>MO[t]):n;class RO{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const a=this.regExpMap.get(t);if(a!==void 0)return a;const r=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,r),this.regExpQueue.push(t),r}}const kO=[" ",",","?","!",";"],LO=new RO(20),zO=(n,t,a)=>{t=t||"",a=a||"";const r=kO.filter(f=>t.indexOf(f)<0&&a.indexOf(f)<0);if(r.length===0)return!0;const l=LO.getRegExp(`(${r.map(f=>f==="?"?"\\?":f).join("|")})`);let c=!l.test(n);if(!c){const f=n.indexOf(a);f>0&&!l.test(n.substring(0,f))&&(c=!0)}return c},Gd=(n,t,a=".")=>{if(!n)return;if(n[t])return Object.prototype.hasOwnProperty.call(n,t)?n[t]:void 0;const r=t.split(a);let l=n;for(let c=0;c-1&&mn==null?void 0:n.replace(/_/g,"-"),VO={type:"logger",log(n){this.output("log",n)},warn(n){this.output("warn",n)},error(n){this.output("error",n)},output(n,t){var a,r;(r=(a=console==null?void 0:console[n])==null?void 0:a.apply)==null||r.call(a,console,t)}};class zl{constructor(t,a={}){this.init(t,a)}init(t,a={}){this.prefix=a.prefix||"i18next:",this.logger=t||VO,this.options=a,this.debug=a.debug}log(...t){return this.forward(t,"log","",!0)}warn(...t){return this.forward(t,"warn","",!0)}error(...t){return this.forward(t,"error","")}deprecate(...t){return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(t,a,r,l){return l&&!this.debug?null:(re(t[0])&&(t[0]=`${r}${this.prefix} ${t[0]}`),this.logger[a](t))}create(t){return new zl(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new zl(this.logger,t)}}var mn=new zl;class ic{constructor(){this.observers={}}on(t,a){return t.split(" ").forEach(r=>{this.observers[r]||(this.observers[r]=new Map);const l=this.observers[r].get(a)||0;this.observers[r].set(a,l+1)}),this}off(t,a){if(this.observers[t]){if(!a){delete this.observers[t];return}this.observers[t].delete(a)}}emit(t,...a){this.observers[t]&&Array.from(this.observers[t].entries()).forEach(([l,c])=>{for(let f=0;f{for(let f=0;f-1&&this.options.ns.splice(a,1)}getResource(t,a,r,l={}){var p,v;const c=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,f=l.ignoreJSONStructure!==void 0?l.ignoreJSONStructure:this.options.ignoreJSONStructure;let h;t.indexOf(".")>-1?h=t.split("."):(h=[t,a],r&&(Array.isArray(r)?h.push(...r):re(r)&&c?h.push(...r.split(c)):h.push(r)));const m=Ll(this.data,h);return!m&&!a&&!r&&t.indexOf(".")>-1&&(t=h[0],a=h[1],r=h.slice(2).join(".")),m||!f||!re(r)?m:Gd((v=(p=this.data)==null?void 0:p[t])==null?void 0:v[a],r,c)}addResource(t,a,r,l,c={silent:!1}){const f=c.keySeparator!==void 0?c.keySeparator:this.options.keySeparator;let h=[t,a];r&&(h=h.concat(f?r.split(f):r)),t.indexOf(".")>-1&&(h=t.split("."),l=a,a=h[1]),this.addNamespaces(a),hx(this.data,h,l),c.silent||this.emit("added",t,a,r,l)}addResources(t,a,r,l={silent:!1}){for(const c in r)(re(r[c])||Array.isArray(r[c]))&&this.addResource(t,a,c,r[c],{silent:!0});l.silent||this.emit("added",t,a,r)}addResourceBundle(t,a,r,l,c,f={silent:!1,skipCopy:!1}){let h=[t,a];t.indexOf(".")>-1&&(h=t.split("."),l=r,r=a,a=h[1]),this.addNamespaces(a);let m=Ll(this.data,h)||{};f.skipCopy||(r=JSON.parse(JSON.stringify(r))),l?wS(m,r,c):m={...m,...r},hx(this.data,h,m),f.silent||this.emit("added",t,a,r)}removeResourceBundle(t,a){this.hasResourceBundle(t,a)&&delete this.data[t][a],this.removeNamespaces(a),this.emit("removed",t,a)}hasResourceBundle(t,a){return this.getResource(t,a)!==void 0}getResourceBundle(t,a){return a||(a=this.options.defaultNS),this.getResource(t,a)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const a=this.getDataByLanguage(t);return!!(a&&Object.keys(a)||[]).find(l=>a[l]&&Object.keys(a[l]).length>0)}toJSON(){return this.data}}var _S={processors:{},addPostProcessor(n){this.processors[n.name]=n},handle(n,t,a,r,l){return n.forEach(c=>{var f;t=((f=this.processors[c])==null?void 0:f.process(t,a,r,l))??t}),t}};const TS=Symbol("i18next/PATH_KEY");function BO(){const n=[],t=Object.create(null);let a;return t.get=(r,l)=>{var c;return(c=a==null?void 0:a.revoke)==null||c.call(a),l===TS?n:(n.push(l),a=Proxy.revocable(r,t),a.proxy)},Proxy.revocable(Object.create(null),t).proxy}function Qa(n,t){const{[TS]:a}=n(BO()),r=(t==null?void 0:t.keySeparator)??".",l=(t==null?void 0:t.nsSeparator)??":";if(a.length>1&&l){const c=t==null?void 0:t.ns,f=Array.isArray(c)?c:null;if(f&&f.length>1&&f.slice(1).includes(a[0]))return`${a[0]}${l}${a.slice(1).join(r)}`}return a.join(r)}const px={},td=n=>!re(n)&&typeof n!="boolean"&&typeof n!="number";class Vl extends ic{constructor(t,a={}){super(),NO(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=a,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=mn.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t,a={interpolation:{}}){const r={...a};if(t==null)return!1;const l=this.resolve(t,r);if((l==null?void 0:l.res)===void 0)return!1;const c=td(l.res);return!(r.returnObjects===!1&&c)}extractFromKey(t,a){let r=a.nsSeparator!==void 0?a.nsSeparator:this.options.nsSeparator;r===void 0&&(r=":");const l=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator;let c=a.ns||this.options.defaultNS||[];const f=r&&t.indexOf(r)>-1,h=!this.options.userDefinedKeySeparator&&!a.keySeparator&&!this.options.userDefinedNsSeparator&&!a.nsSeparator&&!zO(t,r,l);if(f&&!h){const m=t.match(this.interpolator.nestingRegexp);if(m&&m.length>0)return{key:t,namespaces:re(c)?[c]:c};const p=t.split(r);(r!==l||r===l&&this.options.ns.indexOf(p[0])>-1)&&(c=p.shift()),t=p.join(l)}return{key:t,namespaces:re(c)?[c]:c}}translate(t,a,r){let l=typeof a=="object"?{...a}:a;if(typeof l!="object"&&this.options.overloadTranslationOptionHandler&&(l=this.options.overloadTranslationOptionHandler(arguments)),typeof l=="object"&&(l={...l}),l||(l={}),t==null)return"";typeof t=="function"&&(t=Qa(t,{...this.options,...l})),Array.isArray(t)||(t=[String(t)]),t=t.map(De=>typeof De=="function"?Qa(De,{...this.options,...l}):String(De));const c=l.returnDetails!==void 0?l.returnDetails:this.options.returnDetails,f=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,{key:h,namespaces:m}=this.extractFromKey(t[t.length-1],l),p=m[m.length-1];let v=l.nsSeparator!==void 0?l.nsSeparator:this.options.nsSeparator;v===void 0&&(v=":");const x=l.lng||this.language,S=l.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((x==null?void 0:x.toLowerCase())==="cimode")return S?c?{res:`${p}${v}${h}`,usedKey:h,exactUsedKey:h,usedLng:x,usedNS:p,usedParams:this.getUsedParamsDetails(l)}:`${p}${v}${h}`:c?{res:h,usedKey:h,exactUsedKey:h,usedLng:x,usedNS:p,usedParams:this.getUsedParamsDetails(l)}:h;const w=this.resolve(t,l);let T=w==null?void 0:w.res;const k=(w==null?void 0:w.usedKey)||h,z=(w==null?void 0:w.exactUsedKey)||h,B=["[object Number]","[object Function]","[object RegExp]"],I=l.joinArrays!==void 0?l.joinArrays:this.options.joinArrays,H=!this.i18nFormat||this.i18nFormat.handleAsObject,F=l.count!==void 0&&!re(l.count),$=Vl.hasDefaultValue(l),he=F?this.pluralResolver.getSuffix(x,l.count,l):"",J=l.ordinal&&F?this.pluralResolver.getSuffix(x,l.count,{ordinal:!1}):"",te=F&&!l.ordinal&&l.count===0,ue=te&&l[`defaultValue${this.options.pluralSeparator}zero`]||l[`defaultValue${he}`]||l[`defaultValue${J}`]||l.defaultValue;let X=T;H&&!T&&$&&(X=ue);const we=td(X),Ae=Object.prototype.toString.apply(X);if(H&&X&&we&&B.indexOf(Ae)<0&&!(re(I)&&Array.isArray(X))){if(!l.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const De=this.options.returnedObjectHandler?this.options.returnedObjectHandler(k,X,{...l,ns:m}):`key '${h} (${this.language})' returned an object instead of string.`;return c?(w.res=De,w.usedParams=this.getUsedParamsDetails(l),w):De}if(f){const De=Array.isArray(X),_e=De?[]:{},He=De?z:k;for(const O in X)if(Object.prototype.hasOwnProperty.call(X,O)){const q=`${He}${f}${O}`;$&&!T?_e[O]=this.translate(q,{...l,defaultValue:td(ue)?ue[O]:void 0,joinArrays:!1,ns:m}):_e[O]=this.translate(q,{...l,joinArrays:!1,ns:m}),_e[O]===q&&(_e[O]=X[O])}T=_e}}else if(H&&re(I)&&Array.isArray(T))T=T.join(I),T&&(T=this.extendTranslation(T,t,l,r));else{let De=!1,_e=!1;!this.isValidLookup(T)&&$&&(De=!0,T=ue),this.isValidLookup(T)||(_e=!0,T=h);const O=(l.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&_e?void 0:T,q=$&&ue!==T&&this.options.updateMissing;if(_e||De||q){if(this.logger.log(q?"updateKey":"missingKey",x,p,h,q?ue:T),f){const A=this.resolve(h,{...l,keySeparator:!1});A&&A.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let Y=[];const se=this.languageUtils.getFallbackCodes(this.options.fallbackLng,l.lng||this.language);if(this.options.saveMissingTo==="fallback"&&se&&se[0])for(let A=0;A{var oe;const Z=$&&G!==T?G:O;this.options.missingKeyHandler?this.options.missingKeyHandler(A,p,V,Z,q,l):(oe=this.backendConnector)!=null&&oe.saveMissing&&this.backendConnector.saveMissing(A,p,V,Z,q,l),this.emit("missingKey",A,p,V,T)};this.options.saveMissing&&(this.options.saveMissingPlurals&&F?Y.forEach(A=>{const V=this.pluralResolver.getSuffixes(A,l);te&&l[`defaultValue${this.options.pluralSeparator}zero`]&&V.indexOf(`${this.options.pluralSeparator}zero`)<0&&V.push(`${this.options.pluralSeparator}zero`),V.forEach(G=>{me([A],h+G,l[`defaultValue${G}`]||ue)})}):me(Y,h,ue))}T=this.extendTranslation(T,t,l,w,r),_e&&T===h&&this.options.appendNamespaceToMissingKey&&(T=`${p}${v}${h}`),(_e||De)&&this.options.parseMissingKeyHandler&&(T=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${p}${v}${h}`:h,De?T:void 0,l))}return c?(w.res=T,w.usedParams=this.getUsedParamsDetails(l),w):T}extendTranslation(t,a,r,l,c){var m,p;if((m=this.i18nFormat)!=null&&m.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...r},r.lng||this.language||l.usedLng,l.usedNS,l.usedKey,{resolved:l});else if(!r.skipInterpolation){r.interpolation&&this.interpolator.init({...r,interpolation:{...this.options.interpolation,...r.interpolation}});const v=re(t)&&(((p=r==null?void 0:r.interpolation)==null?void 0:p.skipOnVariables)!==void 0?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let x;if(v){const w=t.match(this.interpolator.nestingRegexp);x=w&&w.length}let S=r.replace&&!re(r.replace)?r.replace:r;if(this.options.interpolation.defaultVariables&&(S={...this.options.interpolation.defaultVariables,...S}),t=this.interpolator.interpolate(t,S,r.lng||this.language||l.usedLng,r),v){const w=t.match(this.interpolator.nestingRegexp),T=w&&w.length;x(c==null?void 0:c[0])===w[0]&&!r.context?(this.logger.warn(`It seems you are nesting recursively key: ${w[0]} in key: ${a[0]}`),null):this.translate(...w,a),r)),r.interpolation&&this.interpolator.reset()}const f=r.postProcess||this.options.postProcess,h=re(f)?[f]:f;return t!=null&&(h!=null&&h.length)&&r.applyPostProcessor!==!1&&(t=_S.handle(h,t,a,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...l,usedParams:this.getUsedParamsDetails(r)},...r}:r,this)),t}resolve(t,a={}){let r,l,c,f,h;return re(t)&&(t=[t]),Array.isArray(t)&&(t=t.map(m=>typeof m=="function"?Qa(m,{...this.options,...a}):m)),t.forEach(m=>{if(this.isValidLookup(r))return;const p=this.extractFromKey(m,a),v=p.key;l=v;let x=p.namespaces;this.options.fallbackNS&&(x=x.concat(this.options.fallbackNS));const S=a.count!==void 0&&!re(a.count),w=S&&!a.ordinal&&a.count===0,T=a.context!==void 0&&(re(a.context)||typeof a.context=="number")&&a.context!=="",k=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);x.forEach(z=>{var B,I;this.isValidLookup(r)||(h=z,!px[`${k[0]}-${z}`]&&((B=this.utils)!=null&&B.hasLoadedNamespace)&&!((I=this.utils)!=null&&I.hasLoadedNamespace(h))&&(px[`${k[0]}-${z}`]=!0,this.logger.warn(`key "${l}" for languages "${k.join(", ")}" won't get resolved as namespace "${h}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),k.forEach(H=>{var he;if(this.isValidLookup(r))return;f=H;const F=[v];if((he=this.i18nFormat)!=null&&he.addLookupKeys)this.i18nFormat.addLookupKeys(F,v,H,z,a);else{let J;S&&(J=this.pluralResolver.getSuffix(H,a.count,a));const te=`${this.options.pluralSeparator}zero`,ue=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(S&&(a.ordinal&&J.indexOf(ue)===0&&F.push(v+J.replace(ue,this.options.pluralSeparator)),F.push(v+J),w&&F.push(v+te)),T){const X=`${v}${this.options.contextSeparator||"_"}${a.context}`;F.push(X),S&&(a.ordinal&&J.indexOf(ue)===0&&F.push(X+J.replace(ue,this.options.pluralSeparator)),F.push(X+J),w&&F.push(X+te))}}let $;for(;$=F.pop();)this.isValidLookup(r)||(c=$,r=this.getResource(H,z,$,a))}))})}),{res:r,usedKey:l,exactUsedKey:c,usedLng:f,usedNS:h}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,a,r,l={}){var c;return(c=this.i18nFormat)!=null&&c.getResource?this.i18nFormat.getResource(t,a,r,l):this.resourceStore.getResource(t,a,r,l)}getUsedParamsDetails(t={}){const a=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=t.replace&&!re(t.replace);let l=r?t.replace:t;if(r&&typeof t.count<"u"&&(l.count=t.count),this.options.interpolation.defaultVariables&&(l={...this.options.interpolation.defaultVariables,...l}),!r){l={...l};for(const c of a)delete l[c]}return l}static hasDefaultValue(t){const a="defaultValue";for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&a===r.substring(0,a.length)&&t[r]!==void 0)return!0;return!1}}class gx{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=mn.create("languageUtils")}getScriptPartFromCode(t){if(t=Er(t),!t||t.indexOf("-")<0)return null;const a=t.split("-");return a.length===2||(a.pop(),a[a.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(a.join("-"))}getLanguagePartFromCode(t){if(t=Er(t),!t||t.indexOf("-")<0)return t;const a=t.split("-");return this.formatLanguageCode(a[0])}formatLanguageCode(t){if(re(t)&&t.indexOf("-")>-1){let a;try{a=Intl.getCanonicalLocales(t)[0]}catch{}return a&&this.options.lowerCaseLng&&(a=a.toLowerCase()),a||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let a;return t.forEach(r=>{if(a)return;const l=this.formatLanguageCode(r);(!this.options.supportedLngs||this.isSupportedCode(l))&&(a=l)}),!a&&this.options.supportedLngs&&t.forEach(r=>{if(a)return;const l=this.getScriptPartFromCode(r);if(this.isSupportedCode(l))return a=l;const c=this.getLanguagePartFromCode(r);if(this.isSupportedCode(c))return a=c;a=this.options.supportedLngs.find(f=>{if(f===c)return f;if(!(f.indexOf("-")<0&&c.indexOf("-")<0)&&(f.indexOf("-")>0&&c.indexOf("-")<0&&f.substring(0,f.indexOf("-"))===c||f.indexOf(c)===0&&c.length>1))return f})}),a||(a=this.getFallbackCodes(this.options.fallbackLng)[0]),a}getFallbackCodes(t,a){if(!t)return[];if(typeof t=="function"&&(t=t(a)),re(t)&&(t=[t]),Array.isArray(t))return t;if(!a)return t.default||[];let r=t[a];return r||(r=t[this.getScriptPartFromCode(a)]),r||(r=t[this.formatLanguageCode(a)]),r||(r=t[this.getLanguagePartFromCode(a)]),r||(r=t.default),r||[]}toResolveHierarchy(t,a){const r=this.getFallbackCodes((a===!1?[]:a)||this.options.fallbackLng||[],t),l=[],c=f=>{f&&(this.isSupportedCode(f)?l.push(f):this.logger.warn(`rejecting language code not found in supportedLngs: ${f}`))};return re(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&c(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&c(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&c(this.getLanguagePartFromCode(t))):re(t)&&c(this.formatLanguageCode(t)),r.forEach(f=>{l.indexOf(f)<0&&c(this.formatLanguageCode(f))}),l}}const yx={zero:0,one:1,two:2,few:3,many:4,other:5},vx={select:n=>n===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class UO{constructor(t,a={}){this.languageUtils=t,this.options=a,this.logger=mn.create("pluralResolver"),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(t,a={}){const r=Er(t==="dev"?"en":t),l=a.ordinal?"ordinal":"cardinal",c=JSON.stringify({cleanedCode:r,type:l});if(c in this.pluralRulesCache)return this.pluralRulesCache[c];let f;try{f=new Intl.PluralRules(r,{type:l})}catch{if(typeof Intl>"u")return this.logger.error("No Intl support, please use an Intl polyfill!"),vx;if(!t.match(/-|_/))return vx;const m=this.languageUtils.getLanguagePartFromCode(t);f=this.getRule(m,a)}return this.pluralRulesCache[c]=f,f}needsPlural(t,a={}){let r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),(r==null?void 0:r.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,a,r={}){return this.getSuffixes(t,r).map(l=>`${a}${l}`)}getSuffixes(t,a={}){let r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),r?r.resolvedOptions().pluralCategories.sort((l,c)=>yx[l]-yx[c]).map(l=>`${this.options.prepend}${a.ordinal?`ordinal${this.options.prepend}`:""}${l}`):[]}getSuffix(t,a,r={}){const l=this.getRule(t,r);return l?`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${l.select(a)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",a,r))}}const xx=(n,t,a,r=".",l=!0)=>{let c=jO(n,t,a);return!c&&l&&re(a)&&(c=Gd(n,a,r),c===void 0&&(c=Gd(t,a,r))),c},nd=n=>n.replace(/\$/g,"$$$$");class bx{constructor(t={}){var a;this.logger=mn.create("interpolator"),this.options=t,this.format=((a=t==null?void 0:t.interpolation)==null?void 0:a.format)||(r=>r),this.init(t)}init(t={}){t.interpolation||(t.interpolation={escapeValue:!0});const{escape:a,escapeValue:r,useRawValueToEscape:l,prefix:c,prefixEscaped:f,suffix:h,suffixEscaped:m,formatSeparator:p,unescapeSuffix:v,unescapePrefix:x,nestingPrefix:S,nestingPrefixEscaped:w,nestingSuffix:T,nestingSuffixEscaped:k,nestingOptionsSeparator:z,maxReplaces:B,alwaysFormat:I}=t.interpolation;this.escape=a!==void 0?a:OO,this.escapeValue=r!==void 0?r:!0,this.useRawValueToEscape=l!==void 0?l:!1,this.prefix=c?Fi(c):f||"{{",this.suffix=h?Fi(h):m||"}}",this.formatSeparator=p||",",this.unescapePrefix=v?"":x||"-",this.unescapeSuffix=this.unescapePrefix?"":v||"",this.nestingPrefix=S?Fi(S):w||Fi("$t("),this.nestingSuffix=T?Fi(T):k||Fi(")"),this.nestingOptionsSeparator=z||",",this.maxReplaces=B||1e3,this.alwaysFormat=I!==void 0?I:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(a,r)=>(a==null?void 0:a.source)===r?(a.lastIndex=0,a):new RegExp(r,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(t,a,r,l){var w;let c,f,h;const m=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},p=T=>{if(T.indexOf(this.formatSeparator)<0){const I=xx(a,m,T,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(I,void 0,r,{...l,...a,interpolationkey:T}):I}const k=T.split(this.formatSeparator),z=k.shift().trim(),B=k.join(this.formatSeparator).trim();return this.format(xx(a,m,z,this.options.keySeparator,this.options.ignoreJSONStructure),B,r,{...l,...a,interpolationkey:z})};this.resetRegExp();const v=(l==null?void 0:l.missingInterpolationHandler)||this.options.missingInterpolationHandler,x=((w=l==null?void 0:l.interpolation)==null?void 0:w.skipOnVariables)!==void 0?l.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:T=>nd(T)},{regex:this.regexp,safeValue:T=>this.escapeValue?nd(this.escape(T)):nd(T)}].forEach(T=>{for(h=0;c=T.regex.exec(t);){const k=c[1].trim();if(f=p(k),f===void 0)if(typeof v=="function"){const B=v(t,c,l);f=re(B)?B:""}else if(l&&Object.prototype.hasOwnProperty.call(l,k))f="";else if(x){f=c[0];continue}else this.logger.warn(`missed to pass in variable ${k} for interpolating ${t}`),f="";else!re(f)&&!this.useRawValueToEscape&&(f=ux(f));const z=T.safeValue(f);if(t=t.replace(c[0],z),x?(T.regex.lastIndex+=f.length,T.regex.lastIndex-=c[0].length):T.regex.lastIndex=0,h++,h>=this.maxReplaces)break}}),t}nest(t,a,r={}){let l,c,f;const h=(m,p)=>{const v=this.nestingOptionsSeparator;if(m.indexOf(v)<0)return m;const x=m.split(new RegExp(`${Fi(v)}[ ]*{`));let S=`{${x[1]}`;m=x[0],S=this.interpolate(S,f);const w=S.match(/'/g),T=S.match(/"/g);(((w==null?void 0:w.length)??0)%2===0&&!T||((T==null?void 0:T.length)??0)%2!==0)&&(S=S.replace(/'/g,'"'));try{f=JSON.parse(S),p&&(f={...p,...f})}catch(k){return this.logger.warn(`failed parsing options string in nesting for key ${m}`,k),`${m}${v}${S}`}return f.defaultValue&&f.defaultValue.indexOf(this.prefix)>-1&&delete f.defaultValue,m};for(;l=this.nestingRegexp.exec(t);){let m=[];f={...r},f=f.replace&&!re(f.replace)?f.replace:f,f.applyPostProcessor=!1,delete f.defaultValue;const p=/{.*}/.test(l[1])?l[1].lastIndexOf("}")+1:l[1].indexOf(this.formatSeparator);if(p!==-1&&(m=l[1].slice(p).split(this.formatSeparator).map(v=>v.trim()).filter(Boolean),l[1]=l[1].slice(0,p)),c=a(h.call(this,l[1].trim(),f),f),c&&l[0]===t&&!re(c))return c;re(c)||(c=ux(c)),c||(this.logger.warn(`missed to resolve ${l[1]} for nesting ${t}`),c=""),m.length&&(c=m.reduce((v,x)=>this.format(v,x,r.lng,{...r,interpolationkey:l[1].trim()}),c.trim())),t=t.replace(l[0],c),this.regexp.lastIndex=0}return t}}const PO=n=>{let t=n.toLowerCase().trim();const a={};if(n.indexOf("(")>-1){const r=n.split("(");t=r[0].toLowerCase().trim();const l=r[1].substring(0,r[1].length-1);t==="currency"&&l.indexOf(":")<0?a.currency||(a.currency=l.trim()):t==="relativetime"&&l.indexOf(":")<0?a.range||(a.range=l.trim()):l.split(";").forEach(f=>{if(f){const[h,...m]=f.split(":"),p=m.join(":").trim().replace(/^'+|'+$/g,""),v=h.trim();a[v]||(a[v]=p),p==="false"&&(a[v]=!1),p==="true"&&(a[v]=!0),isNaN(p)||(a[v]=parseInt(p,10))}})}return{formatName:t,formatOptions:a}},Sx=n=>{const t={};return(a,r,l)=>{let c=l;l&&l.interpolationkey&&l.formatParams&&l.formatParams[l.interpolationkey]&&l[l.interpolationkey]&&(c={...c,[l.interpolationkey]:void 0});const f=r+JSON.stringify(c);let h=t[f];return h||(h=n(Er(r),l),t[f]=h),h(a)}},HO=n=>(t,a,r)=>n(Er(a),r)(t);class IO{constructor(t={}){this.logger=mn.create("formatter"),this.options=t,this.init(t)}init(t,a={interpolation:{}}){this.formatSeparator=a.interpolation.formatSeparator||",";const r=a.cacheInBuiltFormats?Sx:HO;this.formats={number:r((l,c)=>{const f=new Intl.NumberFormat(l,{...c});return h=>f.format(h)}),currency:r((l,c)=>{const f=new Intl.NumberFormat(l,{...c,style:"currency"});return h=>f.format(h)}),datetime:r((l,c)=>{const f=new Intl.DateTimeFormat(l,{...c});return h=>f.format(h)}),relativetime:r((l,c)=>{const f=new Intl.RelativeTimeFormat(l,{...c});return h=>f.format(h,c.range||"day")}),list:r((l,c)=>{const f=new Intl.ListFormat(l,{...c});return h=>f.format(h)})}}add(t,a){this.formats[t.toLowerCase().trim()]=a}addCached(t,a){this.formats[t.toLowerCase().trim()]=Sx(a)}format(t,a,r,l={}){const c=a.split(this.formatSeparator);if(c.length>1&&c[0].indexOf("(")>1&&c[0].indexOf(")")<0&&c.find(h=>h.indexOf(")")>-1)){const h=c.findIndex(m=>m.indexOf(")")>-1);c[0]=[c[0],...c.splice(1,h)].join(this.formatSeparator)}return c.reduce((h,m)=>{var x;const{formatName:p,formatOptions:v}=PO(m);if(this.formats[p]){let S=h;try{const w=((x=l==null?void 0:l.formatParams)==null?void 0:x[l.interpolationkey])||{},T=w.locale||w.lng||l.locale||l.lng||r;S=this.formats[p](h,T,{...v,...l,...w})}catch(w){this.logger.warn(w)}return S}else this.logger.warn(`there was no format function for ${p}`);return h},t)}}const qO=(n,t)=>{n.pending[t]!==void 0&&(delete n.pending[t],n.pendingCount--)};class FO extends ic{constructor(t,a,r,l={}){var c,f;super(),this.backend=t,this.store=a,this.services=r,this.languageUtils=r.languageUtils,this.options=l,this.logger=mn.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=l.maxParallelReads||10,this.readingCalls=0,this.maxRetries=l.maxRetries>=0?l.maxRetries:5,this.retryTimeout=l.retryTimeout>=1?l.retryTimeout:350,this.state={},this.queue=[],(f=(c=this.backend)==null?void 0:c.init)==null||f.call(c,r,l.backend,l)}queueLoad(t,a,r,l){const c={},f={},h={},m={};return t.forEach(p=>{let v=!0;a.forEach(x=>{const S=`${p}|${x}`;!r.reload&&this.store.hasResourceBundle(p,x)?this.state[S]=2:this.state[S]<0||(this.state[S]===1?f[S]===void 0&&(f[S]=!0):(this.state[S]=1,v=!1,f[S]===void 0&&(f[S]=!0),c[S]===void 0&&(c[S]=!0),m[x]===void 0&&(m[x]=!0)))}),v||(h[p]=!0)}),(Object.keys(c).length||Object.keys(f).length)&&this.queue.push({pending:f,pendingCount:Object.keys(f).length,loaded:{},errors:[],callback:l}),{toLoad:Object.keys(c),pending:Object.keys(f),toLoadLanguages:Object.keys(h),toLoadNamespaces:Object.keys(m)}}loaded(t,a,r){const l=t.split("|"),c=l[0],f=l[1];a&&this.emit("failedLoading",c,f,a),!a&&r&&this.store.addResourceBundle(c,f,r,void 0,void 0,{skipCopy:!0}),this.state[t]=a?-1:2,a&&r&&(this.state[t]=0);const h={};this.queue.forEach(m=>{CO(m.loaded,[c],f),qO(m,t),a&&m.errors.push(a),m.pendingCount===0&&!m.done&&(Object.keys(m.loaded).forEach(p=>{h[p]||(h[p]={});const v=m.loaded[p];v.length&&v.forEach(x=>{h[p][x]===void 0&&(h[p][x]=!0)})}),m.done=!0,m.errors.length?m.callback(m.errors):m.callback())}),this.emit("loaded",h),this.queue=this.queue.filter(m=>!m.done)}read(t,a,r,l=0,c=this.retryTimeout,f){if(!t.length)return f(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:a,fcName:r,tried:l,wait:c,callback:f});return}this.readingCalls++;const h=(p,v)=>{if(this.readingCalls--,this.waitingReads.length>0){const x=this.waitingReads.shift();this.read(x.lng,x.ns,x.fcName,x.tried,x.wait,x.callback)}if(p&&v&&l{this.read.call(this,t,a,r,l+1,c*2,f)},c);return}f(p,v)},m=this.backend[r].bind(this.backend);if(m.length===2){try{const p=m(t,a);p&&typeof p.then=="function"?p.then(v=>h(null,v)).catch(h):h(null,p)}catch(p){h(p)}return}return m(t,a,h)}prepareLoading(t,a,r={},l){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),l&&l();re(t)&&(t=this.languageUtils.toResolveHierarchy(t)),re(a)&&(a=[a]);const c=this.queueLoad(t,a,r,l);if(!c.toLoad.length)return c.pending.length||l(),null;c.toLoad.forEach(f=>{this.loadOne(f)})}load(t,a,r){this.prepareLoading(t,a,{},r)}reload(t,a,r){this.prepareLoading(t,a,{reload:!0},r)}loadOne(t,a=""){const r=t.split("|"),l=r[0],c=r[1];this.read(l,c,"read",void 0,void 0,(f,h)=>{f&&this.logger.warn(`${a}loading namespace ${c} for language ${l} failed`,f),!f&&h&&this.logger.log(`${a}loaded namespace ${c} for language ${l}`,h),this.loaded(t,f,h)})}saveMissing(t,a,r,l,c,f={},h=()=>{}){var m,p,v,x,S;if((p=(m=this.services)==null?void 0:m.utils)!=null&&p.hasLoadedNamespace&&!((x=(v=this.services)==null?void 0:v.utils)!=null&&x.hasLoadedNamespace(a))){this.logger.warn(`did not save key "${r}" as the namespace "${a}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(r==null||r==="")){if((S=this.backend)!=null&&S.create){const w={...f,isUpdate:c},T=this.backend.create.bind(this.backend);if(T.length<6)try{let k;T.length===5?k=T(t,a,r,l,w):k=T(t,a,r,l),k&&typeof k.then=="function"?k.then(z=>h(null,z)).catch(h):h(null,k)}catch(k){h(k)}else T(t,a,r,l,h,w)}!t||!t[0]||this.store.addResource(t[0],a,r,l)}}}const id=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:n=>{let t={};if(typeof n[1]=="object"&&(t=n[1]),re(n[1])&&(t.defaultValue=n[1]),re(n[2])&&(t.tDescription=n[2]),typeof n[2]=="object"||typeof n[3]=="object"){const a=n[3]||n[2];Object.keys(a).forEach(r=>{t[r]=a[r]})}return t},interpolation:{escapeValue:!0,format:n=>n,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),wx=n=>{var t,a;return re(n.ns)&&(n.ns=[n.ns]),re(n.fallbackLng)&&(n.fallbackLng=[n.fallbackLng]),re(n.fallbackNS)&&(n.fallbackNS=[n.fallbackNS]),((a=(t=n.supportedLngs)==null?void 0:t.indexOf)==null?void 0:a.call(t,"cimode"))<0&&(n.supportedLngs=n.supportedLngs.concat(["cimode"])),typeof n.initImmediate=="boolean"&&(n.initAsync=n.initImmediate),n},ol=()=>{},GO=n=>{Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(a=>{typeof n[a]=="function"&&(n[a]=n[a].bind(n))})},ES="__i18next_supportNoticeShown",YO=()=>!!(typeof globalThis<"u"&&globalThis[ES]||typeof process<"u"&&ed&&ed.I18NEXT_NO_SUPPORT_NOTICE||typeof process<"u"&&ed),KO=()=>{typeof globalThis<"u"&&(globalThis[ES]=!0)},XO=n=>{var t,a,r,l,c,f,h,m,p,v,x,S,w;return!!(((r=(a=(t=n==null?void 0:n.modules)==null?void 0:t.backend)==null?void 0:a.name)==null?void 0:r.indexOf("Locize"))>0||((h=(f=(c=(l=n==null?void 0:n.modules)==null?void 0:l.backend)==null?void 0:c.constructor)==null?void 0:f.name)==null?void 0:h.indexOf("Locize"))>0||(p=(m=n==null?void 0:n.options)==null?void 0:m.backend)!=null&&p.backends&&n.options.backend.backends.some(T=>{var k,z,B;return((k=T==null?void 0:T.name)==null?void 0:k.indexOf("Locize"))>0||((B=(z=T==null?void 0:T.constructor)==null?void 0:z.name)==null?void 0:B.indexOf("Locize"))>0})||(x=(v=n==null?void 0:n.options)==null?void 0:v.backend)!=null&&x.projectId||(w=(S=n==null?void 0:n.options)==null?void 0:S.backend)!=null&&w.backendOptions&&n.options.backend.backendOptions.some(T=>T==null?void 0:T.projectId))};class yr extends ic{constructor(t={},a){if(super(),this.options=wx(t),this.services={},this.logger=mn,this.modules={external:[]},GO(this),a&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,a),this;setTimeout(()=>{this.init(t,a)},0)}}init(t={},a){this.isInitializing=!0,typeof t=="function"&&(a=t,t={}),t.defaultNS==null&&t.ns&&(re(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=id();this.options={...r,...this.options,...wx(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},t.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=t.keySeparator),t.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=t.nsSeparator),typeof this.options.overloadTranslationOptionHandler!="function"&&(this.options.overloadTranslationOptionHandler=r.overloadTranslationOptionHandler),this.options.showSupportNotice!==!1&&!XO(this)&&!YO()&&(typeof console<"u"&&typeof console.info<"u"&&console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"),KO());const l=p=>p?typeof p=="function"?new p:p:null;if(!this.options.isClone){this.modules.logger?mn.init(l(this.modules.logger),this.options):mn.init(null,this.options);let p;this.modules.formatter?p=this.modules.formatter:p=IO;const v=new gx(this.options);this.store=new mx(this.options.resources,this.options);const x=this.services;x.logger=mn,x.resourceStore=this.store,x.languageUtils=v,x.pluralResolver=new UO(v,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),p&&(!this.options.interpolation.format||this.options.interpolation.format===r.interpolation.format)&&(x.formatter=l(p),x.formatter.init&&x.formatter.init(x,this.options),this.options.interpolation.format=x.formatter.format.bind(x.formatter)),x.interpolator=new bx(this.options),x.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},x.backendConnector=new FO(l(this.modules.backend),x.resourceStore,x,this.options),x.backendConnector.on("*",(w,...T)=>{this.emit(w,...T)}),this.modules.languageDetector&&(x.languageDetector=l(this.modules.languageDetector),x.languageDetector.init&&x.languageDetector.init(x,this.options.detection,this.options)),this.modules.i18nFormat&&(x.i18nFormat=l(this.modules.i18nFormat),x.i18nFormat.init&&x.i18nFormat.init(this)),this.translator=new Vl(this.services,this.options),this.translator.on("*",(w,...T)=>{this.emit(w,...T)}),this.modules.external.forEach(w=>{w.init&&w.init(this)})}if(this.format=this.options.interpolation.format,a||(a=ol),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const p=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);p.length>0&&p[0]!=="dev"&&(this.options.lng=p[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(p=>{this[p]=(...v)=>this.store[p](...v)}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(p=>{this[p]=(...v)=>(this.store[p](...v),this)});const h=lr(),m=()=>{const p=(v,x)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),h.resolve(x),a(v,x)};if(this.languages&&!this.isInitialized)return p(null,this.t.bind(this));this.changeLanguage(this.options.lng,p)};return this.options.resources||!this.options.initAsync?m():setTimeout(m,0),h}loadResources(t,a=ol){var c,f;let r=a;const l=re(t)?t:this.language;if(typeof t=="function"&&(r=t),!this.options.resources||this.options.partialBundledLanguages){if((l==null?void 0:l.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return r();const h=[],m=p=>{if(!p||p==="cimode")return;this.services.languageUtils.toResolveHierarchy(p).forEach(x=>{x!=="cimode"&&h.indexOf(x)<0&&h.push(x)})};l?m(l):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(v=>m(v)),(f=(c=this.options.preload)==null?void 0:c.forEach)==null||f.call(c,p=>m(p)),this.services.backendConnector.load(h,this.options.ns,p=>{!p&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),r(p)})}else r(null)}reloadResources(t,a,r){const l=lr();return typeof t=="function"&&(r=t,t=void 0),typeof a=="function"&&(r=a,a=void 0),t||(t=this.languages),a||(a=this.options.ns),r||(r=ol),this.services.backendConnector.reload(t,a,c=>{l.resolve(),r(c)}),l}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&_S.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1)){for(let a=0;a-1)&&this.store.hasLanguageSomeTranslations(r)){this.resolvedLanguage=r;break}}!this.resolvedLanguage&&this.languages.indexOf(t)<0&&this.store.hasLanguageSomeTranslations(t)&&(this.resolvedLanguage=t,this.languages.unshift(t))}}changeLanguage(t,a){this.isLanguageChangingTo=t;const r=lr();this.emit("languageChanging",t);const l=h=>{this.language=h,this.languages=this.services.languageUtils.toResolveHierarchy(h),this.resolvedLanguage=void 0,this.setResolvedLanguage(h)},c=(h,m)=>{m?this.isLanguageChangingTo===t&&(l(m),this.translator.changeLanguage(m),this.isLanguageChangingTo=void 0,this.emit("languageChanged",m),this.logger.log("languageChanged",m)):this.isLanguageChangingTo=void 0,r.resolve((...p)=>this.t(...p)),a&&a(h,(...p)=>this.t(...p))},f=h=>{var v,x;!t&&!h&&this.services.languageDetector&&(h=[]);const m=re(h)?h:h&&h[0],p=this.store.hasLanguageSomeTranslations(m)?m:this.services.languageUtils.getBestMatchFromCodes(re(h)?[h]:h);p&&(this.language||l(p),this.translator.language||this.translator.changeLanguage(p),(x=(v=this.services.languageDetector)==null?void 0:v.cacheUserLanguage)==null||x.call(v,p)),this.loadResources(p,S=>{c(S,p)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?f(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(f):this.services.languageDetector.detect(f):f(t),r}getFixedT(t,a,r){const l=(c,f,...h)=>{let m;typeof f!="object"?m=this.options.overloadTranslationOptionHandler([c,f].concat(h)):m={...f},m.lng=m.lng||l.lng,m.lngs=m.lngs||l.lngs,m.ns=m.ns||l.ns,m.keyPrefix!==""&&(m.keyPrefix=m.keyPrefix||r||l.keyPrefix);const p={...this.options,...m};typeof m.keyPrefix=="function"&&(m.keyPrefix=Qa(m.keyPrefix,p));const v=this.options.keySeparator||".";let x;return m.keyPrefix&&Array.isArray(c)?x=c.map(S=>(typeof S=="function"&&(S=Qa(S,p)),`${m.keyPrefix}${v}${S}`)):(typeof c=="function"&&(c=Qa(c,p)),x=m.keyPrefix?`${m.keyPrefix}${v}${c}`:c),this.t(x,m)};return re(t)?l.lng=t:l.lngs=t,l.ns=a,l.keyPrefix=r,l}t(...t){var a;return(a=this.translator)==null?void 0:a.translate(...t)}exists(...t){var a;return(a=this.translator)==null?void 0:a.exists(...t)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t,a={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const r=a.lng||this.resolvedLanguage||this.languages[0],l=this.options?this.options.fallbackLng:!1,c=this.languages[this.languages.length-1];if(r.toLowerCase()==="cimode")return!0;const f=(h,m)=>{const p=this.services.backendConnector.state[`${h}|${m}`];return p===-1||p===0||p===2};if(a.precheck){const h=a.precheck(this,f);if(h!==void 0)return h}return!!(this.hasResourceBundle(r,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||f(r,t)&&(!l||f(c,t)))}loadNamespaces(t,a){const r=lr();return this.options.ns?(re(t)&&(t=[t]),t.forEach(l=>{this.options.ns.indexOf(l)<0&&this.options.ns.push(l)}),this.loadResources(l=>{r.resolve(),a&&a(l)}),r):(a&&a(),Promise.resolve())}loadLanguages(t,a){const r=lr();re(t)&&(t=[t]);const l=this.options.preload||[],c=t.filter(f=>l.indexOf(f)<0&&this.services.languageUtils.isSupportedCode(f));return c.length?(this.options.preload=l.concat(c),this.loadResources(f=>{r.resolve(),a&&a(f)}),r):(a&&a(),Promise.resolve())}dir(t){var l,c;if(t||(t=this.resolvedLanguage||(((l=this.languages)==null?void 0:l.length)>0?this.languages[0]:this.language)),!t)return"rtl";try{const f=new Intl.Locale(t);if(f&&f.getTextInfo){const h=f.getTextInfo();if(h&&h.direction)return h.direction}}catch{}const a=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],r=((c=this.services)==null?void 0:c.languageUtils)||new gx(id());return t.toLowerCase().indexOf("-latn")>1?"ltr":a.indexOf(r.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(t={},a){const r=new yr(t,a);return r.createInstance=yr.createInstance,r}cloneInstance(t={},a=ol){const r=t.forkResourceStore;r&&delete t.forkResourceStore;const l={...this.options,...t,isClone:!0},c=new yr(l);if((t.debug!==void 0||t.prefix!==void 0)&&(c.logger=c.logger.clone(t)),["store","services","language"].forEach(h=>{c[h]=this[h]}),c.services={...this.services},c.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},r){const h=Object.keys(this.store.data).reduce((m,p)=>(m[p]={...this.store.data[p]},m[p]=Object.keys(m[p]).reduce((v,x)=>(v[x]={...m[p][x]},v),m[p]),m),{});c.store=new mx(h,l),c.services.resourceStore=c.store}if(t.interpolation){const m={...id().interpolation,...this.options.interpolation,...t.interpolation},p={...l,interpolation:m};c.services.interpolator=new bx(p)}return c.translator=new Vl(c.services,l),c.translator.on("*",(h,...m)=>{c.emit(h,...m)}),c.init(l,a),c.translator.options=l,c.translator.backendConnector.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Qe=yr.createInstance();Qe.createInstance;Qe.dir;Qe.init;Qe.loadResources;Qe.reloadResources;Qe.use;Qe.changeLanguage;Qe.getFixedT;Qe.t;Qe.exists;Qe.setDefaultNamespace;Qe.hasLoadedNamespace;Qe.loadNamespaces;Qe.loadLanguages;const{slice:$O,forEach:ZO}=[];function QO(n){return ZO.call($O.call(arguments,1),t=>{if(t)for(const a in t)n[a]===void 0&&(n[a]=t[a])}),n}function WO(n){return typeof n!="string"?!1:[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(a=>a.test(n))}const _x=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,JO=function(n,t){const r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:"/"},l=encodeURIComponent(t);let c=`${n}=${l}`;if(r.maxAge>0){const f=r.maxAge-0;if(Number.isNaN(f))throw new Error("maxAge should be a Number");c+=`; Max-Age=${Math.floor(f)}`}if(r.domain){if(!_x.test(r.domain))throw new TypeError("option domain is invalid");c+=`; Domain=${r.domain}`}if(r.path){if(!_x.test(r.path))throw new TypeError("option path is invalid");c+=`; Path=${r.path}`}if(r.expires){if(typeof r.expires.toUTCString!="function")throw new TypeError("option expires is invalid");c+=`; Expires=${r.expires.toUTCString()}`}if(r.httpOnly&&(c+="; HttpOnly"),r.secure&&(c+="; Secure"),r.sameSite)switch(typeof r.sameSite=="string"?r.sameSite.toLowerCase():r.sameSite){case!0:c+="; SameSite=Strict";break;case"lax":c+="; SameSite=Lax";break;case"strict":c+="; SameSite=Strict";break;case"none":c+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return r.partitioned&&(c+="; Partitioned"),c},Tx={create(n,t,a,r){let l=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};a&&(l.expires=new Date,l.expires.setTime(l.expires.getTime()+a*60*1e3)),r&&(l.domain=r),document.cookie=JO(n,t,l)},read(n){const t=`${n}=`,a=document.cookie.split(";");for(let r=0;r-1&&(l=window.location.hash.substring(window.location.hash.indexOf("?")));const f=l.substring(1).split("&");for(let h=0;h0&&f[h].substring(0,m)===t&&(a=f[h].substring(m+1))}}return a}},nR={name:"hash",lookup(n){var l;let{lookupHash:t,lookupFromHashIndex:a}=n,r;if(typeof window<"u"){const{hash:c}=window.location;if(c&&c.length>2){const f=c.substring(1);if(t){const h=f.split("&");for(let m=0;m0&&h[m].substring(0,p)===t&&(r=h[m].substring(p+1))}}if(r)return r;if(!r&&a>-1){const h=c.match(/\/([a-zA-Z-]*)/g);return Array.isArray(h)?(l=h[typeof a=="number"?a:0])==null?void 0:l.replace("/",""):void 0}}}return r}};let qa=null;const Ex=()=>{if(qa!==null)return qa;try{if(qa=typeof window<"u"&&window.localStorage!==null,!qa)return!1;const n="i18next.translate.boo";window.localStorage.setItem(n,"foo"),window.localStorage.removeItem(n)}catch{qa=!1}return qa};var iR={name:"localStorage",lookup(n){let{lookupLocalStorage:t}=n;if(t&&Ex())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(n,t){let{lookupLocalStorage:a}=t;a&&Ex()&&window.localStorage.setItem(a,n)}};let Fa=null;const Ax=()=>{if(Fa!==null)return Fa;try{if(Fa=typeof window<"u"&&window.sessionStorage!==null,!Fa)return!1;const n="i18next.translate.boo";window.sessionStorage.setItem(n,"foo"),window.sessionStorage.removeItem(n)}catch{Fa=!1}return Fa};var aR={name:"sessionStorage",lookup(n){let{lookupSessionStorage:t}=n;if(t&&Ax())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(n,t){let{lookupSessionStorage:a}=t;a&&Ax()&&window.sessionStorage.setItem(a,n)}},sR={name:"navigator",lookup(n){const t=[];if(typeof navigator<"u"){const{languages:a,userLanguage:r,language:l}=navigator;if(a)for(let c=0;c0?t:void 0}},rR={name:"htmlTag",lookup(n){let{htmlTag:t}=n,a;const r=t||(typeof document<"u"?document.documentElement:null);return r&&typeof r.getAttribute=="function"&&(a=r.getAttribute("lang")),a}},oR={name:"path",lookup(n){var l;let{lookupFromPathIndex:t}=n;if(typeof window>"u")return;const a=window.location.pathname.match(/\/([a-zA-Z-]*)/g);return Array.isArray(a)?(l=a[typeof t=="number"?t:0])==null?void 0:l.replace("/",""):void 0}},lR={name:"subdomain",lookup(n){var l,c;let{lookupFromSubdomainIndex:t}=n;const a=typeof t=="number"?t+1:1,r=typeof window<"u"&&((c=(l=window.location)==null?void 0:l.hostname)==null?void 0:c.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i));if(r)return r[a]}};let AS=!1;try{document.cookie,AS=!0}catch{}const NS=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];AS||NS.splice(1,1);const cR=()=>({order:NS,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:n=>n});class DS{constructor(t){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(t,a)}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t,this.options=QO(a,this.options||{},cR()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=l=>l.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=r,this.addDetector(eR),this.addDetector(tR),this.addDetector(iR),this.addDetector(aR),this.addDetector(sR),this.addDetector(rR),this.addDetector(oR),this.addDetector(lR),this.addDetector(nR)}addDetector(t){return this.detectors[t.name]=t,this}detect(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,a=[];return t.forEach(r=>{if(this.detectors[r]){let l=this.detectors[r].lookup(this.options);l&&typeof l=="string"&&(l=[l]),l&&(a=a.concat(l))}}),a=a.filter(r=>r!=null&&!WO(r)).map(r=>this.options.convertDetectedLanguage(r)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?a:a.length>0?a[0]:null}cacheUserLanguage(t){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;a&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(t)>-1||a.forEach(r=>{this.detectors[r]&&this.detectors[r].cacheUserLanguage(t,this.options)}))}}DS.type="languageDetector";const uR={free:"Free",pro:"Pro",api:"API",enterprise:"Enterprise",reserveAccess:"Reserve Your Early Access",signIn:"Sign In",upgradeToPro:"Upgrade to Pro",goToDashboard:"Go to Dashboard"},fR={noiseWord:"Noise",signalWord:"Signal",valueProps:"The intelligence geopolitical AI layer — ask it, subscribe to it, build on it.",reserveEarlyAccess:"Reserve Your Early Access",launchingDate:"Live now",tryFreeDashboard:"Try the free dashboard",emailPlaceholder:"Enter your email",emailAriaLabel:"Email address for waitlist",choosePlan:"Choose Your Plan",goToDashboard:"Go to Dashboard",signIn:"Sign In"},dR={asFeaturedIn:"As featured in"},hR={proTitle:"World Monitor Pro",proDesc:"Your AI analyst. A personal intelligence desk. A platform you can build on. One key across 30+ live services.",proF1:"WM Analyst chat — query all 30+ services conversationally",proF2:"AI digest — daily, twice-daily, or weekly — to Slack, Discord, Telegram, Email, or webhook",proF3:"Custom Widget Builder — HTML/CSS/JS with AI-assisted modification",proF4:"MCP connectors — plug WorldMonitor into Claude, GPT, custom LLMs",proF5:"Equity research, stock analysis & backtesting",proF6:"Flight search & price comparison",proF7:"Alert rules engine — custom triggers, quiet hours, AES-256 encrypted channels",proF8:"Market watchlist, macro & central bank tracking",proF9:"AI Market Implications & Regional Intelligence (Soon: orbital surveillance, premium map layers, longer history)",proCta:"Reserve Your Early Access",choosePlan:"Choose Your Plan",entTitle:"World Monitor Enterprise",entDesc:"For teams that need shared monitoring, API access, deployment options, TV apps, and direct support.",entF1:"Everything in Pro, plus:",entF2:"Live-edge + satellite imagery & SAR",entF3:"AI agents with investor personas & MCP",entF4:"50,000+ infrastructure assets mapped",entF5:"100+ data connectors (Splunk, Snowflake, Sentinel...)",entF6:"REST API + webhooks + bulk export",entF7:"Team workspaces with SSO/MFA/RBAC",entF8:"White-label & embeddable panels",entF9:"Android TV app for SOC walls & trading floors",entF10:"Cloud, on-prem, or air-gapped deployment",entF11:"Dedicated onboarding & support",entCta:"Talk to Sales"},mR={title:"Why upgrade",noiseTitle:"Know first",noiseDesc:"AIS anomaly → Brent spike → your Slack in under a minute. Signal, not headlines.",fasterTitle:"Ask anything",fasterDesc:"Chat the same 30+ services your dashboard sees. WM Analyst, always on.",controlTitle:"Build anything",controlDesc:"Custom widget builder (HTML/CSS/JS + AI) plus MCP for your own AI workflows.",deeperTitle:"Wake up informed",deeperDesc:"30-item AI digest ranked by your alert rules. Critical, High, Medium — with Assessment and Signals to watch."},pR={askIt:"Ask it",askItDesc:"WM Analyst chat. All 30+ services queryable in plain English.",subscribeIt:"Subscribe to it",subscribeItDesc:"AI digest on your schedule — daily, twice-daily, or weekly. Slack, Discord, Telegram, Email, webhook.",buildOnIt:"Build on it",buildOnItDesc:"Custom Widget Builder (HTML/CSS/JS + AI) and MCP for Claude, GPT, custom LLMs."},gR={eyebrow:"DELIVERY DESK",title:"Your personal intelligence desk",body:"Up to 30 ranked items per send, deduped across 500+ sources, scored against your watchlist. Choose your cadence — daily, twice-daily, or weekly — with an AI Assessment and Signals to watch delivered to Slack, Discord, Telegram, Email, or webhook.",closer:"Not a newsletter. An analyst.",channels:"Slack · Discord · Telegram · Email · Webhook · AES-256 encrypted · Quiet hours"},yR={windowTitle:"worldmonitor.app — Live Dashboard",openFullScreen:"Open full screen",tryLiveDashboard:"Try the Live Dashboard",iframeTitle:"World Monitor — Live Intelligence Dashboard",description:"3D WebGL globe · 45+ interactive map layers · Real-time market, macro, geopolitical, energy, and infrastructure data"},vR={uniqueVisitors:"Unique visitors",peakDailyUsers:"Peak daily users",countriesReached:"Countries reached",liveDataSources:"Live data sources",quote:"Markets, monetary policy, geopolitics, energy — everything moves together now. I needed something that showed me how these forces connect in real time, not just the headlines but the underlying drivers.",ceo:"CEO of",asToldTo:"as told to"},xR={title:"Built for people who need signal fast",investorsTitle:"Investors & portfolio managers",investorsDesc:"Track global equities, analyst targets, valuation metrics, and macro indicators alongside geopolitical risk signals.",tradersTitle:"Energy & commodities traders",tradersDesc:"Track vessel movements, cargo inference, supply chain disruptions, and market-moving geopolitical signals.",researchersTitle:"Researchers & analysts",researchersDesc:"Equity research, economy analytics, and geopolitical frameworks for deeper analysis and reporting.",journalistsTitle:"Journalists & media",journalistsDesc:"Follow fast-moving developments across markets and regions without stitching sources together manually.",govTitle:"Government & institutions",govDesc:"Macro policy tracking, central bank monitoring, and situational awareness across geopolitical and infrastructure signals.",teamsTitle:"Teams & organizations",teamsDesc:"Move from individual use to shared workflows, API access, TV apps, and managed deployments."},bR={title:"What World Monitor Tracks",subtitle:"30+ service domains ingested simultaneously. Markets, macro, geopolitics, energy, infrastructure — everything normalized and rendered on a WebGL globe.",markets:"Financial Markets & Equities",marketsDesc:"Global stock analysis, commodities, crypto, ETF flows, analyst targets, and FRED macro data",economy:"Economy & Central Banks",economyDesc:"GDP, inflation, interest rates, growth cycles, and monetary policy tracking across major economies",geopolitical:"Geopolitical Analysis",geopoliticalDesc:"ACLED & UCDP events with escalation scoring, risk frameworks, and trend analysis",maritime:"Maritime & Trade",maritimeDesc:"Ship movements, vessel detection, port activity, and cargo inference",aviation:"Aviation Tracking",aviationDesc:"ADS-B transponder tracking of global flight patterns",infra:"Critical Infrastructure",infraDesc:"Nuclear sites, power grids, pipelines, refineries — 50K+ mapped assets",fire:"Satellite Fire Detection",fireDesc:"NASA FIRMS near-real-time fire and hotspot data",cables:"Submarine Cables",cablesDesc:"Undersea cable routes and landing stations",internet:"Internet & GPS",internetDesc:"Outage detection, BGP anomalies, GPS jamming zones",cyber:"Cyber Threats",cyberDesc:"Ransomware feeds, BGP hijacks, DDoS detection",gdelt:"GDELT & News",gdeltDesc:"500+ RSS feeds, AI-scored GDELT events, live broadcasts",seismology:"Seismology & Natural",seismologyDesc:"USGS earthquakes, volcanic activity, severe weather"},SR={free:"Free",freeTagline:"See everything",freeDesc:"The open-source dashboard",freeF1:"5-15 min refresh",freeF2:"500+ feeds, 45 map layers",freeF3:"BYOK for AI",freeF4:"Free forever",openDashboard:"Open Dashboard",pro:"Pro",proTagline:"Markets, macro & geopolitics",proDesc:"Your AI analyst",proF1:"Equity research & stock analysis",proF2:"+ daily briefs, economy analytics",proF3:"AI included, 1 key",proF4:"Priority data refresh (Soon)",priceMonthly:"$39.99 / month",priceAnnual:"$399.99 / year",annualSavingsNote:"2 months free",enterprise:"Enterprise",enterpriseTagline:"Act before anyone else",enterpriseDesc:"The intelligence platform",entF1:"Live-edge + satellite imagery",entF2:"+ AI agents, 50K+ infra, SAR",entF3:"Custom AI, investor personas",entF4:"Contact us",contactSales:"Contact Sales"},wR={proTier:"PRO TIER",title:"Your AI Analyst That Never Sleeps",subtitle:"The free dashboard shows you the world. Pro gives you an analyst to ask, a digest you subscribe to, and primitives to build on. Stocks, macro, geopolitical risk — and the connections between them.",equityResearch:"Equity Research",equityResearchDesc:"Global stock analysis with financials visualization, analyst price targets, and valuation metrics. Track what moves markets.",geopoliticalAnalysis:"Geopolitical Analysis",geopoliticalAnalysisDesc:"Grand Chessboard strategic framework, Prisoners of Geography models, and central bank & monetary policy tracking.",economyAnalytics:"Economy Analytics",economyAnalyticsDesc:"GDP, inflation, interest rates, and growth cycles. Macro data correlated with market signals and geopolitical events.",riskMonitoring:"Risk Monitoring & Scenarios",riskMonitoringDesc:"Global risk scoring, scenario analysis, and geopolitical risk assessment. Convergence detection across market and political signals.",orbitalSurveillance:"Orbital Surveillance",orbitalSurveillanceDesc:"(Soon) Overhead pass predictions, revisit frequency analysis, and imaging window alerts. Know when intelligence satellites are watching your areas of interest.",morningBriefs:"Personal Intelligence Desk",morningBriefsDesc:"Up to 30 ranked stories per digest, deduped across 500+ sources. Pick daily, twice-daily, or weekly cadence — or real-time alerts for critical events. AI Assessment and Signals to watch delivered to Slack, Discord, Telegram, Email, or webhook. Not a newsletter — an analyst.",oneKey:"30+ Services, 1 Key",oneKeyDesc:"Finnhub, FRED, ACLED, UCDP, NASA FIRMS, AISStream, OpenSky, and more — all active, no separate registrations.",deliveryLabel:"Choose how intelligence finds you"},_R={morningBrief:"Morning Brief",markets:"Markets",marketsText:"S&P 500 futures -1.2% pre-market. Fed Chair testimony at 10am EST — rate-sensitive sectors under pressure. Analyst consensus shifting on Q2 earnings.",elevated:"Macro",elevatedText:"ECB holds rates at 3.75%. Euro area GDP revised up to 1.1%. Central bank divergence widening — USD/EUR at 3-month high.",watch:"Geopolitical",watchText:"Brent +2.3% on Hormuz AIS anomaly. 4 dark ships in 6h. Commodity supply chain risk elevated — energy sector correlations spiking."},TR={apiTier:"API TIER",title:"Programmatic Intelligence",subtitle:"For developers, analysts, and teams building on World Monitor data. Separate from Pro — use both or either.",restApi:"REST API across all 30+ service domains",authenticated:"Authenticated per-key, rate-limited per tier",structured:"Structured JSON with cache headers and OpenAPI 3.1 docs",starter:"Starter",starterReqs:"1,000 req/day",starterWebhooks:"5 webhook rules",business:"Business",businessReqs:"50,000 req/day",businessWebhooks:"Unlimited webhooks + SLA",feedData:"Feed data into your dashboards, automate alerting via Zapier/n8n/Make, build custom scoring models on CII/risk data."},ER={enterpriseTier:"ENTERPRISE TIER",title:"Intelligence Infrastructure",subtitle:"For governments, institutions, trading desks, and organizations that need the full platform with maximum security, AI agents, TV apps, and data depth.",security:"Government-Grade Security",securityDesc:"Air-gapped deployment, on-premises Docker, dedicated cloud tenant, SOC 2 Type II path, SSO/MFA, and full audit trail.",aiAgents:"AI Agents & MCP",aiAgentsDesc:"Autonomous intelligence agents with investor personas. Connect World Monitor as a tool to Claude, GPT, or custom LLMs via MCP.",dataLayers:"Expanded Data Layers",dataLayersDesc:"Tens of thousands of infrastructure assets mapped globally. Satellite imagery integration with change detection and SAR.",connectors:"100+ Data Connectors",connectorsDesc:"PostgreSQL, Snowflake, Splunk, Sentinel, Jira, Slack, Teams, and more. Export to PDF, PowerPoint, CSV, GeoJSON.",whiteLabel:"White-Label, TV & Embeddable",whiteLabelDesc:"Your brand, your domain, your desktop app. Android TV app for SOC walls and trading floors. Embeddable iframe panels.",financial:"Financial Intelligence",financialDesc:"Earnings calendar, energy grid data, enhanced commodity tracking with cargo inference, sanctions screening with AIS correlation.",commodity:"Commodity Trading",commodityDesc:"Vessel tracking + cargo inference + supply chain graph. Know before the market moves.",government:"Government & Institutions",governmentDesc:"Air-gapped, AI agents, full situational awareness, MCP. No data leaves your network.",risk:"Risk Consultancies",riskDesc:"Scenario simulation, investor personas, branded PDF/PowerPoint reports on demand.",soc:"SOCs & CERT",socDesc:"Cyber threat layer, SIEM integration, BGP anomaly monitoring, ransomware feeds.",talkToSales:"Talk to Sales",contactFormTitle:"Talk to our team",contactFormSubtitle:"Tell us about your organization and we'll get back to you within one business day.",namePlaceholder:"Your name",emailPlaceholder:"Work email",orgPlaceholder:"Company *",phonePlaceholder:"Phone number *",messagePlaceholder:"What are you looking for?",workEmailRequired:"Please use your work email address",submitContact:"Send Message",contactSending:"Sending...",contactSent:"Message sent. We'll be in touch.",contactFailed:"Failed to send. Please email enterprise@worldmonitor.app"},AR={title:"Compare Tiers",feature:"Feature",freeHeader:"Free ($0)",proHeader:"Pro ($39.99)",apiHeader:"API ($99.99)",entHeader:"Enterprise (Contact)",dataRefresh:"Data refresh",dashboard:"Dashboard",ai:"AI",briefsAlerts:"Briefs & alerts",delivery:"Delivery",apiRow:"API",infraLayers:"Infrastructure layers",satellite:"Orbital Surveillance",connectorsRow:"Connectors",deployment:"Deployment",securityRow:"Security",f5_15min:"5-15 min",fLt60s:"<60 seconds",fPerRequest:"Per-request",fLiveEdge:"Live-edge",f50panels:"50+ panels",fWhiteLabel:"White-label",fBYOK:"BYOK",fIncluded:"Included",fAgentsPersonas:"Agents + personas",fDailyFlash:"Daily + flash",fTeamDist:"Team distribution",fSlackTgWa:"Slack/Discord/TG/Email/Webhook",fWebhook:"Webhook",fSiemMcp:"+ SIEM/MCP",fRestWebhook:"REST + webhook",fMcpBulk:"+ MCP + bulk",f45:"45",fTensOfThousands:"+ tens of thousands",fLiveTracking:"Live tracking",fPassAlerts:"Pass alerts + analysis",fImagerySar:"Imagery + SAR",f100plus:"100+",fCloud:"Cloud",fCloudOnPrem:"Cloud/on-prem/air-gap",fStandard:"Standard",fKeyAuth:"Key auth",fSsoMfa:"SSO/MFA/RBAC/audit",noteBelow:"The core platform remains free. Paid plans unlock equity research, macro analytics, AI briefings, and organizational use."},NR={title:"Frequently Asked Questions",q1:"Is World Monitor still free?",a1:"Yes. The core platform remains free. Pro adds equity research, macro analytics, and AI briefings. Enterprise adds team deployments and TV apps.",q2:"Why pay for Pro?",a2:"Pro is for investors, analysts, and professionals who want stock monitoring, geopolitical analysis, economy analytics, and AI-powered daily briefings — all under one key.",q3:"Who is Enterprise for?",a3:"Enterprise is for teams that need shared use, APIs, integrations, deployment options, and direct support.",q4:"Can I start with Pro and upgrade later?",a4:"Yes. Pro works for serious individuals. Enterprise is there when team and deployment needs grow.",q5:"Is this only for conflict monitoring?",a5:"No. World Monitor is primarily a global intelligence platform covering stock markets, macroeconomics, geopolitical analysis, energy, infrastructure, and more. Conflict tracking is one of many capabilities — not the focus.",q6:"Why keep the core platform free?",a6:"Because public access matters. Paid plans fund deeper workflows for serious users and organizations.",q7:"Can I still use my own API keys?",a7:"Yes. Bring-your-own-keys always works. Pro simply means you don't have to register for 20+ separate services.",q8:"What's MCP?",a8:"MCP lets AI agents — Claude, GPT, custom LLMs — use WorldMonitor as a tool, querying all 30+ services. Included in Pro. Enterprise adds private MCP servers and custom deployments.",q9:"Can I build my own panels?",a9:"Yes. Pro includes the Custom Widget Builder — build panels from HTML, CSS, and JavaScript, with AI-assisted modification.",q10:"Can I connect Claude or GPT to WorldMonitor?",a10:"Yes. MCP is included in Pro — plug WorldMonitor into Claude, GPT, or any MCP-compatible LLM as a live tool.",q11:"How personalized is the digest?",a11:"Pick your cadence — daily, twice-daily, or weekly. We re-score every tracked story against your alert rules and watchlist, dedupe across 500+ sources, and send up to 30 ranked items with an AI Assessment and Signals to watch written to your context. Real-time alerts are also available for critical events.",q12:"What's the refresh rate?",a12:"Near real time for Pro. 5–15 minutes on Free.",q13:"Where does my data go?",a13:"Notification channels are AES-256 encrypted at rest. Digests never leave our pipeline unredacted."},DR={title:"Start with Pro. Scale to Enterprise.",subtitle:"Keep using World Monitor for free, or upgrade for equity research, macro analytics, and AI briefings. If your organization needs team access, TV apps, or API support, talk to us.",getPro:"Reserve Your Early Access",talkToSales:"Talk to Sales"},CR={beFirstInLine:"Be first in line.",lookingForEnterprise:"Looking for Enterprise?",contactUs:"Contact us",wiredArticle:"WIRED Article"},jR={submitting:"Submitting...",joinWaitlist:"Reserve Your Early Access",tooManyRequests:"Too many requests",failedTryAgain:"Failed — try again"},MR={alreadyOnList:"You're already on the list.",shareHint:"Share your link to move up the line. Each friend who joins bumps you closer to the front.",copied:"Copied!",shareOnX:"Share on X",linkedin:"LinkedIn",whatsapp:"WhatsApp",telegram:"Telegram",shareText:"I just joined the World Monitor Pro waitlist — stock monitoring, geopolitical analysis, and AI daily briefings in one platform. Join me:",joinWaitlistShare:"Join the World Monitor Pro waitlist:",youreIn:"You're in!",invitedBanner:"You've been invited — join the waitlist"},OR="Soon",CS={nav:uR,hero:fR,wired:dR,twoPath:hR,whyUpgrade:mR,pillars:pR,deliveryDesk:gR,livePreview:yR,socialProof:vR,audience:xR,dataCoverage:bR,tiers:SR,proShowcase:wR,slackMock:_R,apiSection:TR,enterpriseShowcase:ER,pricingTable:AR,faq:NR,finalCta:DR,footer:CR,form:jR,referral:MR,soonBadge:OR},jS=["en","ar","bg","cs","de","el","es","fr","it","ja","ko","nl","pl","pt","ro","ru","sv","th","tr","vi","zh"],RR=new Set(jS),Nx=new Set(["en"]),kR=new Set(["ar"]),LR=Object.assign({"./locales/ar.json":()=>qe(()=>import("./ar-Cm8L16fJ.js"),[]).then(n=>n.default),"./locales/bg.json":()=>qe(()=>import("./bg-meSd4JsJ.js"),[]).then(n=>n.default),"./locales/cs.json":()=>qe(()=>import("./cs-ptRTyzJj.js"),[]).then(n=>n.default),"./locales/de.json":()=>qe(()=>import("./de-C3_MVNE9.js"),[]).then(n=>n.default),"./locales/el.json":()=>qe(()=>import("./el-B9-X35aF.js"),[]).then(n=>n.default),"./locales/es.json":()=>qe(()=>import("./es-DKuPMUhm.js"),[]).then(n=>n.default),"./locales/fr.json":()=>qe(()=>import("./fr-CqZfnoPg.js"),[]).then(n=>n.default),"./locales/it.json":()=>qe(()=>import("./it-xRd9wXeo.js"),[]).then(n=>n.default),"./locales/ja.json":()=>qe(()=>import("./ja-BvG2yjL7.js"),[]).then(n=>n.default),"./locales/ko.json":()=>qe(()=>import("./ko-Bp1BAWvm.js"),[]).then(n=>n.default),"./locales/nl.json":()=>qe(()=>import("./nl-CIy0NOIy.js"),[]).then(n=>n.default),"./locales/pl.json":()=>qe(()=>import("./pl-P7FWM5y7.js"),[]).then(n=>n.default),"./locales/pt.json":()=>qe(()=>import("./pt-RlnECMQU.js"),[]).then(n=>n.default),"./locales/ro.json":()=>qe(()=>import("./ro-OfGDlDfm.js"),[]).then(n=>n.default),"./locales/ru.json":()=>qe(()=>import("./ru-BgqyPHlN.js"),[]).then(n=>n.default),"./locales/sv.json":()=>qe(()=>import("./sv-DuX3Lsqd.js"),[]).then(n=>n.default),"./locales/th.json":()=>qe(()=>import("./th-CD3FOyKH.js"),[]).then(n=>n.default),"./locales/tr.json":()=>qe(()=>import("./tr-F4p4sScu.js"),[]).then(n=>n.default),"./locales/vi.json":()=>qe(()=>import("./vi-D1texoPw.js"),[]).then(n=>n.default),"./locales/zh.json":()=>qe(()=>import("./zh-BxyDCIra.js"),[]).then(n=>n.default)});function zR(n){var a;const t=((a=(n||"en").split("-")[0])==null?void 0:a.toLowerCase())||"en";return RR.has(t)?t:"en"}async function VR(n){const t=zR(n);if(Nx.has(t))return t;const a=LR[`./locales/${t}.json`],r=a?await a():CS;return Qe.addResourceBundle(t,"translation",r,!0,!0),Nx.add(t),t}async function BR(){if(Qe.isInitialized)return;await Qe.use(DS).init({resources:{en:{translation:CS}},supportedLngs:[...jS],nonExplicitSupportedLngs:!0,fallbackLng:"en",interpolation:{escapeValue:!1},detection:{order:["querystring","localStorage","navigator"],lookupQuerystring:"lang",caches:["localStorage"]}});const n=await VR(Qe.language||"en");n!=="en"&&await Qe.changeLanguage(n);const t=(Qe.language||n).split("-")[0]||"en";document.documentElement.setAttribute("lang",t==="zh"?"zh-CN":t),kR.has(t)&&document.documentElement.setAttribute("dir","rtl")}function _(n,t){return Qe.t(n,t)}const Bl="wm_checkout_product",Ul="wm_checkout_ref",Pl="wm_checkout_discount";function UR(n){const t=new URLSearchParams(n),a=t.get(Bl);return a?{productId:a,referralCode:t.get(Ul)??void 0,discountCode:t.get(Pl)??void 0}:null}function PR(n){const t=new URLSearchParams(n);t.delete(Bl),t.delete(Ul),t.delete(Pl);const a=t.toString();return a?`?${a}`:""}function HR(n,t,a){const r=new URL(n);return r.searchParams.delete(Bl),r.searchParams.delete(Ul),r.searchParams.delete(Pl),r.searchParams.set(Bl,t),a!=null&&a.referralCode&&r.searchParams.set(Ul,a.referralCode),a!=null&&a.discountCode&&r.searchParams.set(Pl,a.discountCode),r.toString()}const MS="https://api.worldmonitor.app/api",Dx="https://customer.dodopayments.com",IR="ACTIVE_SUBSCRIPTION_EXISTS",Cx="'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace";let pt=null,bl=!1,cr=null,OS={kind:"idle"};const Yd=new Set;function jx(n){OS=n;for(const t of Yd)try{t(n)}catch(a){console.error("[checkout] phase subscriber threw:",a)}}function qR(n){return Yd.add(n),n(OS),()=>{Yd.delete(n)}}async function ta(){return pt||cr||(cr=FR().catch(n=>{throw cr=null,n}),cr)}async function FR(){const{Clerk:n}=await qe(async()=>{const{Clerk:r}=await import("./clerk-PNSFEZs8.js");return{Clerk:r}},[]),t="pk_live_Y2xlcmsud29ybGRtb25pdG9yLmFwcCQ",a=new n(t);return await a.load({appearance:{variables:{colorBackground:"#0f0f0f",colorInputBackground:"#141414",colorInputText:"#e8e8e8",colorText:"#e8e8e8",colorTextSecondary:"#aaaaaa",colorPrimary:"#44ff88",colorNeutral:"#e8e8e8",colorDanger:"#ff4444",borderRadius:"4px",fontFamily:Cx,fontFamilyButtons:Cx},elements:{card:{backgroundColor:"#111111",border:"1px solid #2a2a2a",boxShadow:"0 8px 32px rgba(0,0,0,0.6)"},formButtonPrimary:{color:"#000000",fontWeight:"600"},footerActionLink:{color:"#44ff88"},socialButtonsBlockButton:{borderColor:"#2a2a2a",color:"#e8e8e8",backgroundColor:"#141414"}}}}),pt=a,pt}function GR(n){qe(async()=>{const{DodoPayments:t}=await import("./index.esm-BiNDwt_v.js");return{DodoPayments:t}},[]).then(({DodoPayments:t})=>{t.Initialize({mode:"test",displayType:"overlay",onEvent:a=>{var c;const r=a.data,l=(r==null?void 0:r.status)??((c=r==null?void 0:r.message)==null?void 0:c.status);console.info("[checkout] dodo event",a.event_type,l!==void 0?{status:l}:void 0),a.event_type==="checkout.status"&&l==="succeeded"&&(n==null||n())}})}).catch(t=>{console.error("[checkout] Failed to load Dodo overlay SDK:",t)})}async function YR(n,t){if(bl)return!1;let a;try{a=await ta()}catch(r){return console.error("[checkout] Failed to load Clerk:",r),Ji(r,{tags:{surface:"pro-marketing",action:"load-clerk"}}),!1}if(!a.user){const r=HR(window.location.href,n,t);try{a.openSignIn({afterSignInUrl:r,afterSignUpUrl:r})}catch(l){console.error("[checkout] Failed to open sign in:",l),Ji(l,{tags:{surface:"pro-marketing",action:"checkout-sign-in"}})}return!1}return RS(n,t??{})}async function KR(){const n=UR(window.location.search);if(!n)return!1;const t=PR(window.location.search),a=window.location.pathname+t+window.location.hash;window.history.replaceState({},"",a);let r;try{r=await ta()}catch{return!1}if(!r.user)return!1;const{productId:l,referralCode:c,discountCode:f}=n;return RS(l,{referralCode:c,discountCode:f})}async function RS(n,t){var a;if(bl)return!1;bl=!0,jx({kind:"creating_checkout",productId:n});try{$R();const r=await Mx();if(!r)return console.error("[checkout] No auth token after retry"),!1;const l=await fetch(`${MS}/create-checkout`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${r}`},body:JSON.stringify({productId:n,returnUrl:"https://worldmonitor.app/?wm_checkout=success",discountCode:t.discountCode,referralCode:t.referralCode}),signal:AbortSignal.timeout(15e3)});if(!l.ok){const h=await l.json().catch(()=>({}));if(console.error("[checkout] Edge error:",l.status,h),l.status===409&&(h==null?void 0:h.error)===IR){const m=(a=h==null?void 0:h.subscription)==null?void 0:a.planKey;t4({planDisplayName:e4(m),onConfirm:async()=>{const p=QR(),v=await Mx();if(!v){console.error("[checkout] No token available for billing portal"),p&&!p.closed&&p.close();return}WR(v,p)},onDismiss:()=>{}}),pE("Duplicate subscription checkout attempt",{level:"info",tags:{surface:"pro-marketing",code:"duplicate_subscription"},extra:{serverMessage:h==null?void 0:h.message}})}return!1}const c=await l.json();if(!(c!=null&&c.checkout_url))return console.error("[checkout] No checkout_url in response"),!1;const{DodoPayments:f}=await qe(async()=>{const{DodoPayments:h}=await import("./index.esm-BiNDwt_v.js");return{DodoPayments:h}},[]);return f.Checkout.open({checkoutUrl:c.checkout_url,options:{manualRedirect:!1,themeConfig:{dark:{bgPrimary:"#0d0d0d",bgSecondary:"#1a1a1a",borderPrimary:"#323232",textPrimary:"#ffffff",textSecondary:"#909090",buttonPrimary:"#22c55e",buttonPrimaryHover:"#16a34a",buttonTextPrimary:"#0d0d0d"},light:{bgPrimary:"#ffffff",bgSecondary:"#f8f9fa",borderPrimary:"#d4d4d4",textPrimary:"#1a1a1a",textSecondary:"#555555",buttonPrimary:"#16a34a",buttonPrimaryHover:"#15803d",buttonTextPrimary:"#ffffff"},radius:"4px"}}}),!0}catch(r){return console.error("[checkout] Failed:",r),!1}finally{bl=!1,kS(),jx({kind:"idle"})}}const Kd="wm-checkout-interstitial",XR=1e4;let Sl=null;function $R(){if(document.getElementById(Kd))return;const n=document.createElement("div");n.id=Kd,n.setAttribute("role","status"),n.setAttribute("aria-live","polite"),Object.assign(n.style,{position:"fixed",inset:"0",zIndex:"99990",background:"rgba(10, 10, 10, 0.82)",backdropFilter:"blur(4px)",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:"16px",color:"#e8e8e8",fontSize:"14px",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",transition:"opacity 0.2s ease",opacity:"0"}),n.innerHTML=` + */const _O=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],TO=Se("zap",_O),EO="modulepreload",AO=function(n){return"/pro/"+n},cx={},qe=function(t,a,r){let l=Promise.resolve();if(a&&a.length>0){let f=function(p){return Promise.all(p.map(v=>Promise.resolve(v).then(x=>({status:"fulfilled",value:x}),x=>({status:"rejected",reason:x}))))};document.getElementsByTagName("link");const h=document.querySelector("meta[property=csp-nonce]"),m=(h==null?void 0:h.nonce)||(h==null?void 0:h.getAttribute("nonce"));l=f(a.map(p=>{if(p=AO(p),p in cx)return;cx[p]=!0;const v=p.endsWith(".css"),x=v?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${x}`))return;const S=document.createElement("link");if(S.rel=v?"stylesheet":EO,v||(S.as="script"),S.crossOrigin="",S.href=p,m&&S.setAttribute("nonce",m),document.head.appendChild(S),v)return new Promise((w,T)=>{S.addEventListener("load",w),S.addEventListener("error",()=>T(new Error(`Unable to preload CSS for ${p}`)))})}))}function c(f){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=f,window.dispatchEvent(h),!h.defaultPrevented)throw f}return l.then(f=>{for(const h of f||[])h.status==="rejected"&&c(h.reason);return t().catch(c)})};var ed={};const re=n=>typeof n=="string",lr=()=>{let n,t;const a=new Promise((r,l)=>{n=r,t=l});return a.resolve=n,a.reject=t,a},ux=n=>n==null?"":""+n,NO=(n,t,a)=>{n.forEach(r=>{t[r]&&(a[r]=t[r])})},DO=/###/g,fx=n=>n&&n.indexOf("###")>-1?n.replace(DO,"."):n,dx=n=>!n||re(n),gr=(n,t,a)=>{const r=re(t)?t.split("."):t;let l=0;for(;l{const{obj:r,k:l}=gr(n,t,Object);if(r!==void 0||t.length===1){r[l]=a;return}let c=t[t.length-1],f=t.slice(0,t.length-1),h=gr(n,f,Object);for(;h.obj===void 0&&f.length;)c=`${f[f.length-1]}.${c}`,f=f.slice(0,f.length-1),h=gr(n,f,Object),h!=null&&h.obj&&typeof h.obj[`${h.k}.${c}`]<"u"&&(h.obj=void 0);h.obj[`${h.k}.${c}`]=a},CO=(n,t,a,r)=>{const{obj:l,k:c}=gr(n,t,Object);l[c]=l[c]||[],l[c].push(a)},Ll=(n,t)=>{const{obj:a,k:r}=gr(n,t);if(a&&Object.prototype.hasOwnProperty.call(a,r))return a[r]},jO=(n,t,a)=>{const r=Ll(n,a);return r!==void 0?r:Ll(t,a)},_S=(n,t,a)=>{for(const r in t)r!=="__proto__"&&r!=="constructor"&&(r in n?re(n[r])||n[r]instanceof String||re(t[r])||t[r]instanceof String?a&&(n[r]=t[r]):_S(n[r],t[r],a):n[r]=t[r]);return n},Fi=n=>n.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var MO={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const OO=n=>re(n)?n.replace(/[&<>"'\/]/g,t=>MO[t]):n;class RO{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const a=this.regExpMap.get(t);if(a!==void 0)return a;const r=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,r),this.regExpQueue.push(t),r}}const kO=[" ",",","?","!",";"],LO=new RO(20),zO=(n,t,a)=>{t=t||"",a=a||"";const r=kO.filter(f=>t.indexOf(f)<0&&a.indexOf(f)<0);if(r.length===0)return!0;const l=LO.getRegExp(`(${r.map(f=>f==="?"?"\\?":f).join("|")})`);let c=!l.test(n);if(!c){const f=n.indexOf(a);f>0&&!l.test(n.substring(0,f))&&(c=!0)}return c},Gd=(n,t,a=".")=>{if(!n)return;if(n[t])return Object.prototype.hasOwnProperty.call(n,t)?n[t]:void 0;const r=t.split(a);let l=n;for(let c=0;c-1&&mn==null?void 0:n.replace(/_/g,"-"),VO={type:"logger",log(n){this.output("log",n)},warn(n){this.output("warn",n)},error(n){this.output("error",n)},output(n,t){var a,r;(r=(a=console==null?void 0:console[n])==null?void 0:a.apply)==null||r.call(a,console,t)}};class zl{constructor(t,a={}){this.init(t,a)}init(t,a={}){this.prefix=a.prefix||"i18next:",this.logger=t||VO,this.options=a,this.debug=a.debug}log(...t){return this.forward(t,"log","",!0)}warn(...t){return this.forward(t,"warn","",!0)}error(...t){return this.forward(t,"error","")}deprecate(...t){return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(t,a,r,l){return l&&!this.debug?null:(re(t[0])&&(t[0]=`${r}${this.prefix} ${t[0]}`),this.logger[a](t))}create(t){return new zl(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new zl(this.logger,t)}}var mn=new zl;class ic{constructor(){this.observers={}}on(t,a){return t.split(" ").forEach(r=>{this.observers[r]||(this.observers[r]=new Map);const l=this.observers[r].get(a)||0;this.observers[r].set(a,l+1)}),this}off(t,a){if(this.observers[t]){if(!a){delete this.observers[t];return}this.observers[t].delete(a)}}emit(t,...a){this.observers[t]&&Array.from(this.observers[t].entries()).forEach(([l,c])=>{for(let f=0;f{for(let f=0;f-1&&this.options.ns.splice(a,1)}getResource(t,a,r,l={}){var p,v;const c=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,f=l.ignoreJSONStructure!==void 0?l.ignoreJSONStructure:this.options.ignoreJSONStructure;let h;t.indexOf(".")>-1?h=t.split("."):(h=[t,a],r&&(Array.isArray(r)?h.push(...r):re(r)&&c?h.push(...r.split(c)):h.push(r)));const m=Ll(this.data,h);return!m&&!a&&!r&&t.indexOf(".")>-1&&(t=h[0],a=h[1],r=h.slice(2).join(".")),m||!f||!re(r)?m:Gd((v=(p=this.data)==null?void 0:p[t])==null?void 0:v[a],r,c)}addResource(t,a,r,l,c={silent:!1}){const f=c.keySeparator!==void 0?c.keySeparator:this.options.keySeparator;let h=[t,a];r&&(h=h.concat(f?r.split(f):r)),t.indexOf(".")>-1&&(h=t.split("."),l=a,a=h[1]),this.addNamespaces(a),hx(this.data,h,l),c.silent||this.emit("added",t,a,r,l)}addResources(t,a,r,l={silent:!1}){for(const c in r)(re(r[c])||Array.isArray(r[c]))&&this.addResource(t,a,c,r[c],{silent:!0});l.silent||this.emit("added",t,a,r)}addResourceBundle(t,a,r,l,c,f={silent:!1,skipCopy:!1}){let h=[t,a];t.indexOf(".")>-1&&(h=t.split("."),l=r,r=a,a=h[1]),this.addNamespaces(a);let m=Ll(this.data,h)||{};f.skipCopy||(r=JSON.parse(JSON.stringify(r))),l?_S(m,r,c):m={...m,...r},hx(this.data,h,m),f.silent||this.emit("added",t,a,r)}removeResourceBundle(t,a){this.hasResourceBundle(t,a)&&delete this.data[t][a],this.removeNamespaces(a),this.emit("removed",t,a)}hasResourceBundle(t,a){return this.getResource(t,a)!==void 0}getResourceBundle(t,a){return a||(a=this.options.defaultNS),this.getResource(t,a)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const a=this.getDataByLanguage(t);return!!(a&&Object.keys(a)||[]).find(l=>a[l]&&Object.keys(a[l]).length>0)}toJSON(){return this.data}}var TS={processors:{},addPostProcessor(n){this.processors[n.name]=n},handle(n,t,a,r,l){return n.forEach(c=>{var f;t=((f=this.processors[c])==null?void 0:f.process(t,a,r,l))??t}),t}};const ES=Symbol("i18next/PATH_KEY");function BO(){const n=[],t=Object.create(null);let a;return t.get=(r,l)=>{var c;return(c=a==null?void 0:a.revoke)==null||c.call(a),l===ES?n:(n.push(l),a=Proxy.revocable(r,t),a.proxy)},Proxy.revocable(Object.create(null),t).proxy}function Qa(n,t){const{[ES]:a}=n(BO()),r=(t==null?void 0:t.keySeparator)??".",l=(t==null?void 0:t.nsSeparator)??":";if(a.length>1&&l){const c=t==null?void 0:t.ns,f=Array.isArray(c)?c:null;if(f&&f.length>1&&f.slice(1).includes(a[0]))return`${a[0]}${l}${a.slice(1).join(r)}`}return a.join(r)}const px={},td=n=>!re(n)&&typeof n!="boolean"&&typeof n!="number";class Vl extends ic{constructor(t,a={}){super(),NO(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=a,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=mn.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t,a={interpolation:{}}){const r={...a};if(t==null)return!1;const l=this.resolve(t,r);if((l==null?void 0:l.res)===void 0)return!1;const c=td(l.res);return!(r.returnObjects===!1&&c)}extractFromKey(t,a){let r=a.nsSeparator!==void 0?a.nsSeparator:this.options.nsSeparator;r===void 0&&(r=":");const l=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator;let c=a.ns||this.options.defaultNS||[];const f=r&&t.indexOf(r)>-1,h=!this.options.userDefinedKeySeparator&&!a.keySeparator&&!this.options.userDefinedNsSeparator&&!a.nsSeparator&&!zO(t,r,l);if(f&&!h){const m=t.match(this.interpolator.nestingRegexp);if(m&&m.length>0)return{key:t,namespaces:re(c)?[c]:c};const p=t.split(r);(r!==l||r===l&&this.options.ns.indexOf(p[0])>-1)&&(c=p.shift()),t=p.join(l)}return{key:t,namespaces:re(c)?[c]:c}}translate(t,a,r){let l=typeof a=="object"?{...a}:a;if(typeof l!="object"&&this.options.overloadTranslationOptionHandler&&(l=this.options.overloadTranslationOptionHandler(arguments)),typeof l=="object"&&(l={...l}),l||(l={}),t==null)return"";typeof t=="function"&&(t=Qa(t,{...this.options,...l})),Array.isArray(t)||(t=[String(t)]),t=t.map(De=>typeof De=="function"?Qa(De,{...this.options,...l}):String(De));const c=l.returnDetails!==void 0?l.returnDetails:this.options.returnDetails,f=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,{key:h,namespaces:m}=this.extractFromKey(t[t.length-1],l),p=m[m.length-1];let v=l.nsSeparator!==void 0?l.nsSeparator:this.options.nsSeparator;v===void 0&&(v=":");const x=l.lng||this.language,S=l.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((x==null?void 0:x.toLowerCase())==="cimode")return S?c?{res:`${p}${v}${h}`,usedKey:h,exactUsedKey:h,usedLng:x,usedNS:p,usedParams:this.getUsedParamsDetails(l)}:`${p}${v}${h}`:c?{res:h,usedKey:h,exactUsedKey:h,usedLng:x,usedNS:p,usedParams:this.getUsedParamsDetails(l)}:h;const w=this.resolve(t,l);let T=w==null?void 0:w.res;const k=(w==null?void 0:w.usedKey)||h,z=(w==null?void 0:w.exactUsedKey)||h,B=["[object Number]","[object Function]","[object RegExp]"],I=l.joinArrays!==void 0?l.joinArrays:this.options.joinArrays,H=!this.i18nFormat||this.i18nFormat.handleAsObject,F=l.count!==void 0&&!re(l.count),$=Vl.hasDefaultValue(l),he=F?this.pluralResolver.getSuffix(x,l.count,l):"",J=l.ordinal&&F?this.pluralResolver.getSuffix(x,l.count,{ordinal:!1}):"",te=F&&!l.ordinal&&l.count===0,ue=te&&l[`defaultValue${this.options.pluralSeparator}zero`]||l[`defaultValue${he}`]||l[`defaultValue${J}`]||l.defaultValue;let X=T;H&&!T&&$&&(X=ue);const we=td(X),Ae=Object.prototype.toString.apply(X);if(H&&X&&we&&B.indexOf(Ae)<0&&!(re(I)&&Array.isArray(X))){if(!l.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const De=this.options.returnedObjectHandler?this.options.returnedObjectHandler(k,X,{...l,ns:m}):`key '${h} (${this.language})' returned an object instead of string.`;return c?(w.res=De,w.usedParams=this.getUsedParamsDetails(l),w):De}if(f){const De=Array.isArray(X),_e=De?[]:{},He=De?z:k;for(const O in X)if(Object.prototype.hasOwnProperty.call(X,O)){const q=`${He}${f}${O}`;$&&!T?_e[O]=this.translate(q,{...l,defaultValue:td(ue)?ue[O]:void 0,joinArrays:!1,ns:m}):_e[O]=this.translate(q,{...l,joinArrays:!1,ns:m}),_e[O]===q&&(_e[O]=X[O])}T=_e}}else if(H&&re(I)&&Array.isArray(T))T=T.join(I),T&&(T=this.extendTranslation(T,t,l,r));else{let De=!1,_e=!1;!this.isValidLookup(T)&&$&&(De=!0,T=ue),this.isValidLookup(T)||(_e=!0,T=h);const O=(l.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&_e?void 0:T,q=$&&ue!==T&&this.options.updateMissing;if(_e||De||q){if(this.logger.log(q?"updateKey":"missingKey",x,p,h,q?ue:T),f){const A=this.resolve(h,{...l,keySeparator:!1});A&&A.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let Y=[];const se=this.languageUtils.getFallbackCodes(this.options.fallbackLng,l.lng||this.language);if(this.options.saveMissingTo==="fallback"&&se&&se[0])for(let A=0;A{var oe;const Z=$&&G!==T?G:O;this.options.missingKeyHandler?this.options.missingKeyHandler(A,p,V,Z,q,l):(oe=this.backendConnector)!=null&&oe.saveMissing&&this.backendConnector.saveMissing(A,p,V,Z,q,l),this.emit("missingKey",A,p,V,T)};this.options.saveMissing&&(this.options.saveMissingPlurals&&F?Y.forEach(A=>{const V=this.pluralResolver.getSuffixes(A,l);te&&l[`defaultValue${this.options.pluralSeparator}zero`]&&V.indexOf(`${this.options.pluralSeparator}zero`)<0&&V.push(`${this.options.pluralSeparator}zero`),V.forEach(G=>{me([A],h+G,l[`defaultValue${G}`]||ue)})}):me(Y,h,ue))}T=this.extendTranslation(T,t,l,w,r),_e&&T===h&&this.options.appendNamespaceToMissingKey&&(T=`${p}${v}${h}`),(_e||De)&&this.options.parseMissingKeyHandler&&(T=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${p}${v}${h}`:h,De?T:void 0,l))}return c?(w.res=T,w.usedParams=this.getUsedParamsDetails(l),w):T}extendTranslation(t,a,r,l,c){var m,p;if((m=this.i18nFormat)!=null&&m.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...r},r.lng||this.language||l.usedLng,l.usedNS,l.usedKey,{resolved:l});else if(!r.skipInterpolation){r.interpolation&&this.interpolator.init({...r,interpolation:{...this.options.interpolation,...r.interpolation}});const v=re(t)&&(((p=r==null?void 0:r.interpolation)==null?void 0:p.skipOnVariables)!==void 0?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let x;if(v){const w=t.match(this.interpolator.nestingRegexp);x=w&&w.length}let S=r.replace&&!re(r.replace)?r.replace:r;if(this.options.interpolation.defaultVariables&&(S={...this.options.interpolation.defaultVariables,...S}),t=this.interpolator.interpolate(t,S,r.lng||this.language||l.usedLng,r),v){const w=t.match(this.interpolator.nestingRegexp),T=w&&w.length;x(c==null?void 0:c[0])===w[0]&&!r.context?(this.logger.warn(`It seems you are nesting recursively key: ${w[0]} in key: ${a[0]}`),null):this.translate(...w,a),r)),r.interpolation&&this.interpolator.reset()}const f=r.postProcess||this.options.postProcess,h=re(f)?[f]:f;return t!=null&&(h!=null&&h.length)&&r.applyPostProcessor!==!1&&(t=TS.handle(h,t,a,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...l,usedParams:this.getUsedParamsDetails(r)},...r}:r,this)),t}resolve(t,a={}){let r,l,c,f,h;return re(t)&&(t=[t]),Array.isArray(t)&&(t=t.map(m=>typeof m=="function"?Qa(m,{...this.options,...a}):m)),t.forEach(m=>{if(this.isValidLookup(r))return;const p=this.extractFromKey(m,a),v=p.key;l=v;let x=p.namespaces;this.options.fallbackNS&&(x=x.concat(this.options.fallbackNS));const S=a.count!==void 0&&!re(a.count),w=S&&!a.ordinal&&a.count===0,T=a.context!==void 0&&(re(a.context)||typeof a.context=="number")&&a.context!=="",k=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);x.forEach(z=>{var B,I;this.isValidLookup(r)||(h=z,!px[`${k[0]}-${z}`]&&((B=this.utils)!=null&&B.hasLoadedNamespace)&&!((I=this.utils)!=null&&I.hasLoadedNamespace(h))&&(px[`${k[0]}-${z}`]=!0,this.logger.warn(`key "${l}" for languages "${k.join(", ")}" won't get resolved as namespace "${h}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),k.forEach(H=>{var he;if(this.isValidLookup(r))return;f=H;const F=[v];if((he=this.i18nFormat)!=null&&he.addLookupKeys)this.i18nFormat.addLookupKeys(F,v,H,z,a);else{let J;S&&(J=this.pluralResolver.getSuffix(H,a.count,a));const te=`${this.options.pluralSeparator}zero`,ue=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(S&&(a.ordinal&&J.indexOf(ue)===0&&F.push(v+J.replace(ue,this.options.pluralSeparator)),F.push(v+J),w&&F.push(v+te)),T){const X=`${v}${this.options.contextSeparator||"_"}${a.context}`;F.push(X),S&&(a.ordinal&&J.indexOf(ue)===0&&F.push(X+J.replace(ue,this.options.pluralSeparator)),F.push(X+J),w&&F.push(X+te))}}let $;for(;$=F.pop();)this.isValidLookup(r)||(c=$,r=this.getResource(H,z,$,a))}))})}),{res:r,usedKey:l,exactUsedKey:c,usedLng:f,usedNS:h}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,a,r,l={}){var c;return(c=this.i18nFormat)!=null&&c.getResource?this.i18nFormat.getResource(t,a,r,l):this.resourceStore.getResource(t,a,r,l)}getUsedParamsDetails(t={}){const a=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=t.replace&&!re(t.replace);let l=r?t.replace:t;if(r&&typeof t.count<"u"&&(l.count=t.count),this.options.interpolation.defaultVariables&&(l={...this.options.interpolation.defaultVariables,...l}),!r){l={...l};for(const c of a)delete l[c]}return l}static hasDefaultValue(t){const a="defaultValue";for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&a===r.substring(0,a.length)&&t[r]!==void 0)return!0;return!1}}class gx{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=mn.create("languageUtils")}getScriptPartFromCode(t){if(t=Er(t),!t||t.indexOf("-")<0)return null;const a=t.split("-");return a.length===2||(a.pop(),a[a.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(a.join("-"))}getLanguagePartFromCode(t){if(t=Er(t),!t||t.indexOf("-")<0)return t;const a=t.split("-");return this.formatLanguageCode(a[0])}formatLanguageCode(t){if(re(t)&&t.indexOf("-")>-1){let a;try{a=Intl.getCanonicalLocales(t)[0]}catch{}return a&&this.options.lowerCaseLng&&(a=a.toLowerCase()),a||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let a;return t.forEach(r=>{if(a)return;const l=this.formatLanguageCode(r);(!this.options.supportedLngs||this.isSupportedCode(l))&&(a=l)}),!a&&this.options.supportedLngs&&t.forEach(r=>{if(a)return;const l=this.getScriptPartFromCode(r);if(this.isSupportedCode(l))return a=l;const c=this.getLanguagePartFromCode(r);if(this.isSupportedCode(c))return a=c;a=this.options.supportedLngs.find(f=>{if(f===c)return f;if(!(f.indexOf("-")<0&&c.indexOf("-")<0)&&(f.indexOf("-")>0&&c.indexOf("-")<0&&f.substring(0,f.indexOf("-"))===c||f.indexOf(c)===0&&c.length>1))return f})}),a||(a=this.getFallbackCodes(this.options.fallbackLng)[0]),a}getFallbackCodes(t,a){if(!t)return[];if(typeof t=="function"&&(t=t(a)),re(t)&&(t=[t]),Array.isArray(t))return t;if(!a)return t.default||[];let r=t[a];return r||(r=t[this.getScriptPartFromCode(a)]),r||(r=t[this.formatLanguageCode(a)]),r||(r=t[this.getLanguagePartFromCode(a)]),r||(r=t.default),r||[]}toResolveHierarchy(t,a){const r=this.getFallbackCodes((a===!1?[]:a)||this.options.fallbackLng||[],t),l=[],c=f=>{f&&(this.isSupportedCode(f)?l.push(f):this.logger.warn(`rejecting language code not found in supportedLngs: ${f}`))};return re(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&c(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&c(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&c(this.getLanguagePartFromCode(t))):re(t)&&c(this.formatLanguageCode(t)),r.forEach(f=>{l.indexOf(f)<0&&c(this.formatLanguageCode(f))}),l}}const yx={zero:0,one:1,two:2,few:3,many:4,other:5},vx={select:n=>n===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class UO{constructor(t,a={}){this.languageUtils=t,this.options=a,this.logger=mn.create("pluralResolver"),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(t,a={}){const r=Er(t==="dev"?"en":t),l=a.ordinal?"ordinal":"cardinal",c=JSON.stringify({cleanedCode:r,type:l});if(c in this.pluralRulesCache)return this.pluralRulesCache[c];let f;try{f=new Intl.PluralRules(r,{type:l})}catch{if(typeof Intl>"u")return this.logger.error("No Intl support, please use an Intl polyfill!"),vx;if(!t.match(/-|_/))return vx;const m=this.languageUtils.getLanguagePartFromCode(t);f=this.getRule(m,a)}return this.pluralRulesCache[c]=f,f}needsPlural(t,a={}){let r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),(r==null?void 0:r.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,a,r={}){return this.getSuffixes(t,r).map(l=>`${a}${l}`)}getSuffixes(t,a={}){let r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),r?r.resolvedOptions().pluralCategories.sort((l,c)=>yx[l]-yx[c]).map(l=>`${this.options.prepend}${a.ordinal?`ordinal${this.options.prepend}`:""}${l}`):[]}getSuffix(t,a,r={}){const l=this.getRule(t,r);return l?`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${l.select(a)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",a,r))}}const xx=(n,t,a,r=".",l=!0)=>{let c=jO(n,t,a);return!c&&l&&re(a)&&(c=Gd(n,a,r),c===void 0&&(c=Gd(t,a,r))),c},nd=n=>n.replace(/\$/g,"$$$$");class bx{constructor(t={}){var a;this.logger=mn.create("interpolator"),this.options=t,this.format=((a=t==null?void 0:t.interpolation)==null?void 0:a.format)||(r=>r),this.init(t)}init(t={}){t.interpolation||(t.interpolation={escapeValue:!0});const{escape:a,escapeValue:r,useRawValueToEscape:l,prefix:c,prefixEscaped:f,suffix:h,suffixEscaped:m,formatSeparator:p,unescapeSuffix:v,unescapePrefix:x,nestingPrefix:S,nestingPrefixEscaped:w,nestingSuffix:T,nestingSuffixEscaped:k,nestingOptionsSeparator:z,maxReplaces:B,alwaysFormat:I}=t.interpolation;this.escape=a!==void 0?a:OO,this.escapeValue=r!==void 0?r:!0,this.useRawValueToEscape=l!==void 0?l:!1,this.prefix=c?Fi(c):f||"{{",this.suffix=h?Fi(h):m||"}}",this.formatSeparator=p||",",this.unescapePrefix=v?"":x||"-",this.unescapeSuffix=this.unescapePrefix?"":v||"",this.nestingPrefix=S?Fi(S):w||Fi("$t("),this.nestingSuffix=T?Fi(T):k||Fi(")"),this.nestingOptionsSeparator=z||",",this.maxReplaces=B||1e3,this.alwaysFormat=I!==void 0?I:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(a,r)=>(a==null?void 0:a.source)===r?(a.lastIndex=0,a):new RegExp(r,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(t,a,r,l){var w;let c,f,h;const m=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},p=T=>{if(T.indexOf(this.formatSeparator)<0){const I=xx(a,m,T,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(I,void 0,r,{...l,...a,interpolationkey:T}):I}const k=T.split(this.formatSeparator),z=k.shift().trim(),B=k.join(this.formatSeparator).trim();return this.format(xx(a,m,z,this.options.keySeparator,this.options.ignoreJSONStructure),B,r,{...l,...a,interpolationkey:z})};this.resetRegExp();const v=(l==null?void 0:l.missingInterpolationHandler)||this.options.missingInterpolationHandler,x=((w=l==null?void 0:l.interpolation)==null?void 0:w.skipOnVariables)!==void 0?l.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:T=>nd(T)},{regex:this.regexp,safeValue:T=>this.escapeValue?nd(this.escape(T)):nd(T)}].forEach(T=>{for(h=0;c=T.regex.exec(t);){const k=c[1].trim();if(f=p(k),f===void 0)if(typeof v=="function"){const B=v(t,c,l);f=re(B)?B:""}else if(l&&Object.prototype.hasOwnProperty.call(l,k))f="";else if(x){f=c[0];continue}else this.logger.warn(`missed to pass in variable ${k} for interpolating ${t}`),f="";else!re(f)&&!this.useRawValueToEscape&&(f=ux(f));const z=T.safeValue(f);if(t=t.replace(c[0],z),x?(T.regex.lastIndex+=f.length,T.regex.lastIndex-=c[0].length):T.regex.lastIndex=0,h++,h>=this.maxReplaces)break}}),t}nest(t,a,r={}){let l,c,f;const h=(m,p)=>{const v=this.nestingOptionsSeparator;if(m.indexOf(v)<0)return m;const x=m.split(new RegExp(`${Fi(v)}[ ]*{`));let S=`{${x[1]}`;m=x[0],S=this.interpolate(S,f);const w=S.match(/'/g),T=S.match(/"/g);(((w==null?void 0:w.length)??0)%2===0&&!T||((T==null?void 0:T.length)??0)%2!==0)&&(S=S.replace(/'/g,'"'));try{f=JSON.parse(S),p&&(f={...p,...f})}catch(k){return this.logger.warn(`failed parsing options string in nesting for key ${m}`,k),`${m}${v}${S}`}return f.defaultValue&&f.defaultValue.indexOf(this.prefix)>-1&&delete f.defaultValue,m};for(;l=this.nestingRegexp.exec(t);){let m=[];f={...r},f=f.replace&&!re(f.replace)?f.replace:f,f.applyPostProcessor=!1,delete f.defaultValue;const p=/{.*}/.test(l[1])?l[1].lastIndexOf("}")+1:l[1].indexOf(this.formatSeparator);if(p!==-1&&(m=l[1].slice(p).split(this.formatSeparator).map(v=>v.trim()).filter(Boolean),l[1]=l[1].slice(0,p)),c=a(h.call(this,l[1].trim(),f),f),c&&l[0]===t&&!re(c))return c;re(c)||(c=ux(c)),c||(this.logger.warn(`missed to resolve ${l[1]} for nesting ${t}`),c=""),m.length&&(c=m.reduce((v,x)=>this.format(v,x,r.lng,{...r,interpolationkey:l[1].trim()}),c.trim())),t=t.replace(l[0],c),this.regexp.lastIndex=0}return t}}const PO=n=>{let t=n.toLowerCase().trim();const a={};if(n.indexOf("(")>-1){const r=n.split("(");t=r[0].toLowerCase().trim();const l=r[1].substring(0,r[1].length-1);t==="currency"&&l.indexOf(":")<0?a.currency||(a.currency=l.trim()):t==="relativetime"&&l.indexOf(":")<0?a.range||(a.range=l.trim()):l.split(";").forEach(f=>{if(f){const[h,...m]=f.split(":"),p=m.join(":").trim().replace(/^'+|'+$/g,""),v=h.trim();a[v]||(a[v]=p),p==="false"&&(a[v]=!1),p==="true"&&(a[v]=!0),isNaN(p)||(a[v]=parseInt(p,10))}})}return{formatName:t,formatOptions:a}},Sx=n=>{const t={};return(a,r,l)=>{let c=l;l&&l.interpolationkey&&l.formatParams&&l.formatParams[l.interpolationkey]&&l[l.interpolationkey]&&(c={...c,[l.interpolationkey]:void 0});const f=r+JSON.stringify(c);let h=t[f];return h||(h=n(Er(r),l),t[f]=h),h(a)}},HO=n=>(t,a,r)=>n(Er(a),r)(t);class IO{constructor(t={}){this.logger=mn.create("formatter"),this.options=t,this.init(t)}init(t,a={interpolation:{}}){this.formatSeparator=a.interpolation.formatSeparator||",";const r=a.cacheInBuiltFormats?Sx:HO;this.formats={number:r((l,c)=>{const f=new Intl.NumberFormat(l,{...c});return h=>f.format(h)}),currency:r((l,c)=>{const f=new Intl.NumberFormat(l,{...c,style:"currency"});return h=>f.format(h)}),datetime:r((l,c)=>{const f=new Intl.DateTimeFormat(l,{...c});return h=>f.format(h)}),relativetime:r((l,c)=>{const f=new Intl.RelativeTimeFormat(l,{...c});return h=>f.format(h,c.range||"day")}),list:r((l,c)=>{const f=new Intl.ListFormat(l,{...c});return h=>f.format(h)})}}add(t,a){this.formats[t.toLowerCase().trim()]=a}addCached(t,a){this.formats[t.toLowerCase().trim()]=Sx(a)}format(t,a,r,l={}){const c=a.split(this.formatSeparator);if(c.length>1&&c[0].indexOf("(")>1&&c[0].indexOf(")")<0&&c.find(h=>h.indexOf(")")>-1)){const h=c.findIndex(m=>m.indexOf(")")>-1);c[0]=[c[0],...c.splice(1,h)].join(this.formatSeparator)}return c.reduce((h,m)=>{var x;const{formatName:p,formatOptions:v}=PO(m);if(this.formats[p]){let S=h;try{const w=((x=l==null?void 0:l.formatParams)==null?void 0:x[l.interpolationkey])||{},T=w.locale||w.lng||l.locale||l.lng||r;S=this.formats[p](h,T,{...v,...l,...w})}catch(w){this.logger.warn(w)}return S}else this.logger.warn(`there was no format function for ${p}`);return h},t)}}const qO=(n,t)=>{n.pending[t]!==void 0&&(delete n.pending[t],n.pendingCount--)};class FO extends ic{constructor(t,a,r,l={}){var c,f;super(),this.backend=t,this.store=a,this.services=r,this.languageUtils=r.languageUtils,this.options=l,this.logger=mn.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=l.maxParallelReads||10,this.readingCalls=0,this.maxRetries=l.maxRetries>=0?l.maxRetries:5,this.retryTimeout=l.retryTimeout>=1?l.retryTimeout:350,this.state={},this.queue=[],(f=(c=this.backend)==null?void 0:c.init)==null||f.call(c,r,l.backend,l)}queueLoad(t,a,r,l){const c={},f={},h={},m={};return t.forEach(p=>{let v=!0;a.forEach(x=>{const S=`${p}|${x}`;!r.reload&&this.store.hasResourceBundle(p,x)?this.state[S]=2:this.state[S]<0||(this.state[S]===1?f[S]===void 0&&(f[S]=!0):(this.state[S]=1,v=!1,f[S]===void 0&&(f[S]=!0),c[S]===void 0&&(c[S]=!0),m[x]===void 0&&(m[x]=!0)))}),v||(h[p]=!0)}),(Object.keys(c).length||Object.keys(f).length)&&this.queue.push({pending:f,pendingCount:Object.keys(f).length,loaded:{},errors:[],callback:l}),{toLoad:Object.keys(c),pending:Object.keys(f),toLoadLanguages:Object.keys(h),toLoadNamespaces:Object.keys(m)}}loaded(t,a,r){const l=t.split("|"),c=l[0],f=l[1];a&&this.emit("failedLoading",c,f,a),!a&&r&&this.store.addResourceBundle(c,f,r,void 0,void 0,{skipCopy:!0}),this.state[t]=a?-1:2,a&&r&&(this.state[t]=0);const h={};this.queue.forEach(m=>{CO(m.loaded,[c],f),qO(m,t),a&&m.errors.push(a),m.pendingCount===0&&!m.done&&(Object.keys(m.loaded).forEach(p=>{h[p]||(h[p]={});const v=m.loaded[p];v.length&&v.forEach(x=>{h[p][x]===void 0&&(h[p][x]=!0)})}),m.done=!0,m.errors.length?m.callback(m.errors):m.callback())}),this.emit("loaded",h),this.queue=this.queue.filter(m=>!m.done)}read(t,a,r,l=0,c=this.retryTimeout,f){if(!t.length)return f(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:a,fcName:r,tried:l,wait:c,callback:f});return}this.readingCalls++;const h=(p,v)=>{if(this.readingCalls--,this.waitingReads.length>0){const x=this.waitingReads.shift();this.read(x.lng,x.ns,x.fcName,x.tried,x.wait,x.callback)}if(p&&v&&l{this.read.call(this,t,a,r,l+1,c*2,f)},c);return}f(p,v)},m=this.backend[r].bind(this.backend);if(m.length===2){try{const p=m(t,a);p&&typeof p.then=="function"?p.then(v=>h(null,v)).catch(h):h(null,p)}catch(p){h(p)}return}return m(t,a,h)}prepareLoading(t,a,r={},l){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),l&&l();re(t)&&(t=this.languageUtils.toResolveHierarchy(t)),re(a)&&(a=[a]);const c=this.queueLoad(t,a,r,l);if(!c.toLoad.length)return c.pending.length||l(),null;c.toLoad.forEach(f=>{this.loadOne(f)})}load(t,a,r){this.prepareLoading(t,a,{},r)}reload(t,a,r){this.prepareLoading(t,a,{reload:!0},r)}loadOne(t,a=""){const r=t.split("|"),l=r[0],c=r[1];this.read(l,c,"read",void 0,void 0,(f,h)=>{f&&this.logger.warn(`${a}loading namespace ${c} for language ${l} failed`,f),!f&&h&&this.logger.log(`${a}loaded namespace ${c} for language ${l}`,h),this.loaded(t,f,h)})}saveMissing(t,a,r,l,c,f={},h=()=>{}){var m,p,v,x,S;if((p=(m=this.services)==null?void 0:m.utils)!=null&&p.hasLoadedNamespace&&!((x=(v=this.services)==null?void 0:v.utils)!=null&&x.hasLoadedNamespace(a))){this.logger.warn(`did not save key "${r}" as the namespace "${a}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(r==null||r==="")){if((S=this.backend)!=null&&S.create){const w={...f,isUpdate:c},T=this.backend.create.bind(this.backend);if(T.length<6)try{let k;T.length===5?k=T(t,a,r,l,w):k=T(t,a,r,l),k&&typeof k.then=="function"?k.then(z=>h(null,z)).catch(h):h(null,k)}catch(k){h(k)}else T(t,a,r,l,h,w)}!t||!t[0]||this.store.addResource(t[0],a,r,l)}}}const id=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:n=>{let t={};if(typeof n[1]=="object"&&(t=n[1]),re(n[1])&&(t.defaultValue=n[1]),re(n[2])&&(t.tDescription=n[2]),typeof n[2]=="object"||typeof n[3]=="object"){const a=n[3]||n[2];Object.keys(a).forEach(r=>{t[r]=a[r]})}return t},interpolation:{escapeValue:!0,format:n=>n,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),wx=n=>{var t,a;return re(n.ns)&&(n.ns=[n.ns]),re(n.fallbackLng)&&(n.fallbackLng=[n.fallbackLng]),re(n.fallbackNS)&&(n.fallbackNS=[n.fallbackNS]),((a=(t=n.supportedLngs)==null?void 0:t.indexOf)==null?void 0:a.call(t,"cimode"))<0&&(n.supportedLngs=n.supportedLngs.concat(["cimode"])),typeof n.initImmediate=="boolean"&&(n.initAsync=n.initImmediate),n},ol=()=>{},GO=n=>{Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(a=>{typeof n[a]=="function"&&(n[a]=n[a].bind(n))})},AS="__i18next_supportNoticeShown",YO=()=>!!(typeof globalThis<"u"&&globalThis[AS]||typeof process<"u"&&ed&&ed.I18NEXT_NO_SUPPORT_NOTICE||typeof process<"u"&&ed),KO=()=>{typeof globalThis<"u"&&(globalThis[AS]=!0)},XO=n=>{var t,a,r,l,c,f,h,m,p,v,x,S,w;return!!(((r=(a=(t=n==null?void 0:n.modules)==null?void 0:t.backend)==null?void 0:a.name)==null?void 0:r.indexOf("Locize"))>0||((h=(f=(c=(l=n==null?void 0:n.modules)==null?void 0:l.backend)==null?void 0:c.constructor)==null?void 0:f.name)==null?void 0:h.indexOf("Locize"))>0||(p=(m=n==null?void 0:n.options)==null?void 0:m.backend)!=null&&p.backends&&n.options.backend.backends.some(T=>{var k,z,B;return((k=T==null?void 0:T.name)==null?void 0:k.indexOf("Locize"))>0||((B=(z=T==null?void 0:T.constructor)==null?void 0:z.name)==null?void 0:B.indexOf("Locize"))>0})||(x=(v=n==null?void 0:n.options)==null?void 0:v.backend)!=null&&x.projectId||(w=(S=n==null?void 0:n.options)==null?void 0:S.backend)!=null&&w.backendOptions&&n.options.backend.backendOptions.some(T=>T==null?void 0:T.projectId))};class yr extends ic{constructor(t={},a){if(super(),this.options=wx(t),this.services={},this.logger=mn,this.modules={external:[]},GO(this),a&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,a),this;setTimeout(()=>{this.init(t,a)},0)}}init(t={},a){this.isInitializing=!0,typeof t=="function"&&(a=t,t={}),t.defaultNS==null&&t.ns&&(re(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=id();this.options={...r,...this.options,...wx(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},t.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=t.keySeparator),t.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=t.nsSeparator),typeof this.options.overloadTranslationOptionHandler!="function"&&(this.options.overloadTranslationOptionHandler=r.overloadTranslationOptionHandler),this.options.showSupportNotice!==!1&&!XO(this)&&!YO()&&(typeof console<"u"&&typeof console.info<"u"&&console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"),KO());const l=p=>p?typeof p=="function"?new p:p:null;if(!this.options.isClone){this.modules.logger?mn.init(l(this.modules.logger),this.options):mn.init(null,this.options);let p;this.modules.formatter?p=this.modules.formatter:p=IO;const v=new gx(this.options);this.store=new mx(this.options.resources,this.options);const x=this.services;x.logger=mn,x.resourceStore=this.store,x.languageUtils=v,x.pluralResolver=new UO(v,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),p&&(!this.options.interpolation.format||this.options.interpolation.format===r.interpolation.format)&&(x.formatter=l(p),x.formatter.init&&x.formatter.init(x,this.options),this.options.interpolation.format=x.formatter.format.bind(x.formatter)),x.interpolator=new bx(this.options),x.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},x.backendConnector=new FO(l(this.modules.backend),x.resourceStore,x,this.options),x.backendConnector.on("*",(w,...T)=>{this.emit(w,...T)}),this.modules.languageDetector&&(x.languageDetector=l(this.modules.languageDetector),x.languageDetector.init&&x.languageDetector.init(x,this.options.detection,this.options)),this.modules.i18nFormat&&(x.i18nFormat=l(this.modules.i18nFormat),x.i18nFormat.init&&x.i18nFormat.init(this)),this.translator=new Vl(this.services,this.options),this.translator.on("*",(w,...T)=>{this.emit(w,...T)}),this.modules.external.forEach(w=>{w.init&&w.init(this)})}if(this.format=this.options.interpolation.format,a||(a=ol),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const p=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);p.length>0&&p[0]!=="dev"&&(this.options.lng=p[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(p=>{this[p]=(...v)=>this.store[p](...v)}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(p=>{this[p]=(...v)=>(this.store[p](...v),this)});const h=lr(),m=()=>{const p=(v,x)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),h.resolve(x),a(v,x)};if(this.languages&&!this.isInitialized)return p(null,this.t.bind(this));this.changeLanguage(this.options.lng,p)};return this.options.resources||!this.options.initAsync?m():setTimeout(m,0),h}loadResources(t,a=ol){var c,f;let r=a;const l=re(t)?t:this.language;if(typeof t=="function"&&(r=t),!this.options.resources||this.options.partialBundledLanguages){if((l==null?void 0:l.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return r();const h=[],m=p=>{if(!p||p==="cimode")return;this.services.languageUtils.toResolveHierarchy(p).forEach(x=>{x!=="cimode"&&h.indexOf(x)<0&&h.push(x)})};l?m(l):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(v=>m(v)),(f=(c=this.options.preload)==null?void 0:c.forEach)==null||f.call(c,p=>m(p)),this.services.backendConnector.load(h,this.options.ns,p=>{!p&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),r(p)})}else r(null)}reloadResources(t,a,r){const l=lr();return typeof t=="function"&&(r=t,t=void 0),typeof a=="function"&&(r=a,a=void 0),t||(t=this.languages),a||(a=this.options.ns),r||(r=ol),this.services.backendConnector.reload(t,a,c=>{l.resolve(),r(c)}),l}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&TS.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1)){for(let a=0;a-1)&&this.store.hasLanguageSomeTranslations(r)){this.resolvedLanguage=r;break}}!this.resolvedLanguage&&this.languages.indexOf(t)<0&&this.store.hasLanguageSomeTranslations(t)&&(this.resolvedLanguage=t,this.languages.unshift(t))}}changeLanguage(t,a){this.isLanguageChangingTo=t;const r=lr();this.emit("languageChanging",t);const l=h=>{this.language=h,this.languages=this.services.languageUtils.toResolveHierarchy(h),this.resolvedLanguage=void 0,this.setResolvedLanguage(h)},c=(h,m)=>{m?this.isLanguageChangingTo===t&&(l(m),this.translator.changeLanguage(m),this.isLanguageChangingTo=void 0,this.emit("languageChanged",m),this.logger.log("languageChanged",m)):this.isLanguageChangingTo=void 0,r.resolve((...p)=>this.t(...p)),a&&a(h,(...p)=>this.t(...p))},f=h=>{var v,x;!t&&!h&&this.services.languageDetector&&(h=[]);const m=re(h)?h:h&&h[0],p=this.store.hasLanguageSomeTranslations(m)?m:this.services.languageUtils.getBestMatchFromCodes(re(h)?[h]:h);p&&(this.language||l(p),this.translator.language||this.translator.changeLanguage(p),(x=(v=this.services.languageDetector)==null?void 0:v.cacheUserLanguage)==null||x.call(v,p)),this.loadResources(p,S=>{c(S,p)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?f(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(f):this.services.languageDetector.detect(f):f(t),r}getFixedT(t,a,r){const l=(c,f,...h)=>{let m;typeof f!="object"?m=this.options.overloadTranslationOptionHandler([c,f].concat(h)):m={...f},m.lng=m.lng||l.lng,m.lngs=m.lngs||l.lngs,m.ns=m.ns||l.ns,m.keyPrefix!==""&&(m.keyPrefix=m.keyPrefix||r||l.keyPrefix);const p={...this.options,...m};typeof m.keyPrefix=="function"&&(m.keyPrefix=Qa(m.keyPrefix,p));const v=this.options.keySeparator||".";let x;return m.keyPrefix&&Array.isArray(c)?x=c.map(S=>(typeof S=="function"&&(S=Qa(S,p)),`${m.keyPrefix}${v}${S}`)):(typeof c=="function"&&(c=Qa(c,p)),x=m.keyPrefix?`${m.keyPrefix}${v}${c}`:c),this.t(x,m)};return re(t)?l.lng=t:l.lngs=t,l.ns=a,l.keyPrefix=r,l}t(...t){var a;return(a=this.translator)==null?void 0:a.translate(...t)}exists(...t){var a;return(a=this.translator)==null?void 0:a.exists(...t)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t,a={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const r=a.lng||this.resolvedLanguage||this.languages[0],l=this.options?this.options.fallbackLng:!1,c=this.languages[this.languages.length-1];if(r.toLowerCase()==="cimode")return!0;const f=(h,m)=>{const p=this.services.backendConnector.state[`${h}|${m}`];return p===-1||p===0||p===2};if(a.precheck){const h=a.precheck(this,f);if(h!==void 0)return h}return!!(this.hasResourceBundle(r,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||f(r,t)&&(!l||f(c,t)))}loadNamespaces(t,a){const r=lr();return this.options.ns?(re(t)&&(t=[t]),t.forEach(l=>{this.options.ns.indexOf(l)<0&&this.options.ns.push(l)}),this.loadResources(l=>{r.resolve(),a&&a(l)}),r):(a&&a(),Promise.resolve())}loadLanguages(t,a){const r=lr();re(t)&&(t=[t]);const l=this.options.preload||[],c=t.filter(f=>l.indexOf(f)<0&&this.services.languageUtils.isSupportedCode(f));return c.length?(this.options.preload=l.concat(c),this.loadResources(f=>{r.resolve(),a&&a(f)}),r):(a&&a(),Promise.resolve())}dir(t){var l,c;if(t||(t=this.resolvedLanguage||(((l=this.languages)==null?void 0:l.length)>0?this.languages[0]:this.language)),!t)return"rtl";try{const f=new Intl.Locale(t);if(f&&f.getTextInfo){const h=f.getTextInfo();if(h&&h.direction)return h.direction}}catch{}const a=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],r=((c=this.services)==null?void 0:c.languageUtils)||new gx(id());return t.toLowerCase().indexOf("-latn")>1?"ltr":a.indexOf(r.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(t={},a){const r=new yr(t,a);return r.createInstance=yr.createInstance,r}cloneInstance(t={},a=ol){const r=t.forkResourceStore;r&&delete t.forkResourceStore;const l={...this.options,...t,isClone:!0},c=new yr(l);if((t.debug!==void 0||t.prefix!==void 0)&&(c.logger=c.logger.clone(t)),["store","services","language"].forEach(h=>{c[h]=this[h]}),c.services={...this.services},c.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},r){const h=Object.keys(this.store.data).reduce((m,p)=>(m[p]={...this.store.data[p]},m[p]=Object.keys(m[p]).reduce((v,x)=>(v[x]={...m[p][x]},v),m[p]),m),{});c.store=new mx(h,l),c.services.resourceStore=c.store}if(t.interpolation){const m={...id().interpolation,...this.options.interpolation,...t.interpolation},p={...l,interpolation:m};c.services.interpolator=new bx(p)}return c.translator=new Vl(c.services,l),c.translator.on("*",(h,...m)=>{c.emit(h,...m)}),c.init(l,a),c.translator.options=l,c.translator.backendConnector.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Qe=yr.createInstance();Qe.createInstance;Qe.dir;Qe.init;Qe.loadResources;Qe.reloadResources;Qe.use;Qe.changeLanguage;Qe.getFixedT;Qe.t;Qe.exists;Qe.setDefaultNamespace;Qe.hasLoadedNamespace;Qe.loadNamespaces;Qe.loadLanguages;const{slice:$O,forEach:ZO}=[];function QO(n){return ZO.call($O.call(arguments,1),t=>{if(t)for(const a in t)n[a]===void 0&&(n[a]=t[a])}),n}function WO(n){return typeof n!="string"?!1:[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(a=>a.test(n))}const _x=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,JO=function(n,t){const r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:"/"},l=encodeURIComponent(t);let c=`${n}=${l}`;if(r.maxAge>0){const f=r.maxAge-0;if(Number.isNaN(f))throw new Error("maxAge should be a Number");c+=`; Max-Age=${Math.floor(f)}`}if(r.domain){if(!_x.test(r.domain))throw new TypeError("option domain is invalid");c+=`; Domain=${r.domain}`}if(r.path){if(!_x.test(r.path))throw new TypeError("option path is invalid");c+=`; Path=${r.path}`}if(r.expires){if(typeof r.expires.toUTCString!="function")throw new TypeError("option expires is invalid");c+=`; Expires=${r.expires.toUTCString()}`}if(r.httpOnly&&(c+="; HttpOnly"),r.secure&&(c+="; Secure"),r.sameSite)switch(typeof r.sameSite=="string"?r.sameSite.toLowerCase():r.sameSite){case!0:c+="; SameSite=Strict";break;case"lax":c+="; SameSite=Lax";break;case"strict":c+="; SameSite=Strict";break;case"none":c+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return r.partitioned&&(c+="; Partitioned"),c},Tx={create(n,t,a,r){let l=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};a&&(l.expires=new Date,l.expires.setTime(l.expires.getTime()+a*60*1e3)),r&&(l.domain=r),document.cookie=JO(n,t,l)},read(n){const t=`${n}=`,a=document.cookie.split(";");for(let r=0;r-1&&(l=window.location.hash.substring(window.location.hash.indexOf("?")));const f=l.substring(1).split("&");for(let h=0;h0&&f[h].substring(0,m)===t&&(a=f[h].substring(m+1))}}return a}},nR={name:"hash",lookup(n){var l;let{lookupHash:t,lookupFromHashIndex:a}=n,r;if(typeof window<"u"){const{hash:c}=window.location;if(c&&c.length>2){const f=c.substring(1);if(t){const h=f.split("&");for(let m=0;m0&&h[m].substring(0,p)===t&&(r=h[m].substring(p+1))}}if(r)return r;if(!r&&a>-1){const h=c.match(/\/([a-zA-Z-]*)/g);return Array.isArray(h)?(l=h[typeof a=="number"?a:0])==null?void 0:l.replace("/",""):void 0}}}return r}};let qa=null;const Ex=()=>{if(qa!==null)return qa;try{if(qa=typeof window<"u"&&window.localStorage!==null,!qa)return!1;const n="i18next.translate.boo";window.localStorage.setItem(n,"foo"),window.localStorage.removeItem(n)}catch{qa=!1}return qa};var iR={name:"localStorage",lookup(n){let{lookupLocalStorage:t}=n;if(t&&Ex())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(n,t){let{lookupLocalStorage:a}=t;a&&Ex()&&window.localStorage.setItem(a,n)}};let Fa=null;const Ax=()=>{if(Fa!==null)return Fa;try{if(Fa=typeof window<"u"&&window.sessionStorage!==null,!Fa)return!1;const n="i18next.translate.boo";window.sessionStorage.setItem(n,"foo"),window.sessionStorage.removeItem(n)}catch{Fa=!1}return Fa};var aR={name:"sessionStorage",lookup(n){let{lookupSessionStorage:t}=n;if(t&&Ax())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(n,t){let{lookupSessionStorage:a}=t;a&&Ax()&&window.sessionStorage.setItem(a,n)}},sR={name:"navigator",lookup(n){const t=[];if(typeof navigator<"u"){const{languages:a,userLanguage:r,language:l}=navigator;if(a)for(let c=0;c0?t:void 0}},rR={name:"htmlTag",lookup(n){let{htmlTag:t}=n,a;const r=t||(typeof document<"u"?document.documentElement:null);return r&&typeof r.getAttribute=="function"&&(a=r.getAttribute("lang")),a}},oR={name:"path",lookup(n){var l;let{lookupFromPathIndex:t}=n;if(typeof window>"u")return;const a=window.location.pathname.match(/\/([a-zA-Z-]*)/g);return Array.isArray(a)?(l=a[typeof t=="number"?t:0])==null?void 0:l.replace("/",""):void 0}},lR={name:"subdomain",lookup(n){var l,c;let{lookupFromSubdomainIndex:t}=n;const a=typeof t=="number"?t+1:1,r=typeof window<"u"&&((c=(l=window.location)==null?void 0:l.hostname)==null?void 0:c.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i));if(r)return r[a]}};let NS=!1;try{document.cookie,NS=!0}catch{}const DS=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];NS||DS.splice(1,1);const cR=()=>({order:DS,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:n=>n});class CS{constructor(t){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(t,a)}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t,this.options=QO(a,this.options||{},cR()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=l=>l.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=r,this.addDetector(eR),this.addDetector(tR),this.addDetector(iR),this.addDetector(aR),this.addDetector(sR),this.addDetector(rR),this.addDetector(oR),this.addDetector(lR),this.addDetector(nR)}addDetector(t){return this.detectors[t.name]=t,this}detect(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,a=[];return t.forEach(r=>{if(this.detectors[r]){let l=this.detectors[r].lookup(this.options);l&&typeof l=="string"&&(l=[l]),l&&(a=a.concat(l))}}),a=a.filter(r=>r!=null&&!WO(r)).map(r=>this.options.convertDetectedLanguage(r)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?a:a.length>0?a[0]:null}cacheUserLanguage(t){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;a&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(t)>-1||a.forEach(r=>{this.detectors[r]&&this.detectors[r].cacheUserLanguage(t,this.options)}))}}CS.type="languageDetector";const uR={free:"Free",pro:"Pro",api:"API",enterprise:"Enterprise",reserveAccess:"Reserve Your Early Access",signIn:"Sign In",upgradeToPro:"Upgrade to Pro",goToDashboard:"Go to Dashboard"},fR={noiseWord:"Noise",signalWord:"Signal",valueProps:"The intelligence geopolitical AI layer — ask it, subscribe to it, build on it.",reserveEarlyAccess:"Reserve Your Early Access",launchingDate:"Live now",tryFreeDashboard:"Try the free dashboard",emailPlaceholder:"Enter your email",emailAriaLabel:"Email address for waitlist",choosePlan:"Choose Your Plan",goToDashboard:"Go to Dashboard",signIn:"Sign In"},dR={asFeaturedIn:"As featured in"},hR={proTitle:"World Monitor Pro",proDesc:"Your AI analyst. A personal intelligence desk. A platform you can build on. One key across 30+ live services.",proF1:"WM Analyst chat — query all 30+ services conversationally",proF2:"AI digest — daily, twice-daily, or weekly — to Slack, Discord, Telegram, Email, or webhook",proF3:"Custom Widget Builder — HTML/CSS/JS with AI-assisted modification",proF4:"MCP connectors — plug WorldMonitor into Claude, GPT, custom LLMs",proF5:"Equity research, stock analysis & backtesting",proF6:"Flight search & price comparison",proF7:"Alert rules engine — custom triggers, quiet hours, AES-256 encrypted channels",proF8:"Market watchlist, macro & central bank tracking",proF9:"AI Market Implications & Regional Intelligence (Soon: orbital surveillance, premium map layers, longer history)",proCta:"Reserve Your Early Access",choosePlan:"Choose Your Plan",entTitle:"World Monitor Enterprise",entDesc:"For teams that need shared monitoring, API access, deployment options, TV apps, and direct support.",entF1:"Everything in Pro, plus:",entF2:"Live-edge + satellite imagery & SAR",entF3:"AI agents with investor personas & MCP",entF4:"50,000+ infrastructure assets mapped",entF5:"100+ data connectors (Splunk, Snowflake, Sentinel...)",entF6:"REST API + webhooks + bulk export",entF7:"Team workspaces with SSO/MFA/RBAC",entF8:"White-label & embeddable panels",entF9:"Android TV app for SOC walls & trading floors",entF10:"Cloud, on-prem, or air-gapped deployment",entF11:"Dedicated onboarding & support",entCta:"Talk to Sales"},mR={title:"Why upgrade",noiseTitle:"Know first",noiseDesc:"AIS anomaly → Brent spike → your Slack in under a minute. Signal, not headlines.",fasterTitle:"Ask anything",fasterDesc:"Chat the same 30+ services your dashboard sees. WM Analyst, always on.",controlTitle:"Build anything",controlDesc:"Custom widget builder (HTML/CSS/JS + AI) plus MCP for your own AI workflows.",deeperTitle:"Wake up informed",deeperDesc:"30-item AI digest ranked by your alert rules. Critical, High, Medium — with Assessment and Signals to watch."},pR={askIt:"Ask it",askItDesc:"WM Analyst chat. All 30+ services queryable in plain English.",subscribeIt:"Subscribe to it",subscribeItDesc:"AI digest on your schedule — daily, twice-daily, or weekly. Slack, Discord, Telegram, Email, webhook.",buildOnIt:"Build on it",buildOnItDesc:"Custom Widget Builder (HTML/CSS/JS + AI) and MCP for Claude, GPT, custom LLMs."},gR={eyebrow:"DELIVERY DESK",title:"Your personal intelligence desk",body:"Up to 30 ranked items per send, deduped across 500+ sources, scored against your watchlist. Choose your cadence — daily, twice-daily, or weekly — with an AI Assessment and Signals to watch delivered to Slack, Discord, Telegram, Email, or webhook.",closer:"Not a newsletter. An analyst.",channels:"Slack · Discord · Telegram · Email · Webhook · AES-256 encrypted · Quiet hours"},yR={windowTitle:"worldmonitor.app — Live Dashboard",openFullScreen:"Open full screen",tryLiveDashboard:"Try the Live Dashboard",iframeTitle:"World Monitor — Live Intelligence Dashboard",description:"3D WebGL globe · 45+ interactive map layers · Real-time market, macro, geopolitical, energy, and infrastructure data"},vR={uniqueVisitors:"Unique visitors",peakDailyUsers:"Peak daily users",countriesReached:"Countries reached",liveDataSources:"Live data sources",quote:"Markets, monetary policy, geopolitics, energy — everything moves together now. I needed something that showed me how these forces connect in real time, not just the headlines but the underlying drivers.",ceo:"CEO of",asToldTo:"as told to"},xR={title:"Built for people who need signal fast",investorsTitle:"Investors & portfolio managers",investorsDesc:"Track global equities, analyst targets, valuation metrics, and macro indicators alongside geopolitical risk signals.",tradersTitle:"Energy & commodities traders",tradersDesc:"Track vessel movements, cargo inference, supply chain disruptions, and market-moving geopolitical signals.",researchersTitle:"Researchers & analysts",researchersDesc:"Equity research, economy analytics, and geopolitical frameworks for deeper analysis and reporting.",journalistsTitle:"Journalists & media",journalistsDesc:"Follow fast-moving developments across markets and regions without stitching sources together manually.",govTitle:"Government & institutions",govDesc:"Macro policy tracking, central bank monitoring, and situational awareness across geopolitical and infrastructure signals.",teamsTitle:"Teams & organizations",teamsDesc:"Move from individual use to shared workflows, API access, TV apps, and managed deployments."},bR={title:"What World Monitor Tracks",subtitle:"30+ service domains ingested simultaneously. Markets, macro, geopolitics, energy, infrastructure — everything normalized and rendered on a WebGL globe.",markets:"Financial Markets & Equities",marketsDesc:"Global stock analysis, commodities, crypto, ETF flows, analyst targets, and FRED macro data",economy:"Economy & Central Banks",economyDesc:"GDP, inflation, interest rates, growth cycles, and monetary policy tracking across major economies",geopolitical:"Geopolitical Analysis",geopoliticalDesc:"ACLED & UCDP events with escalation scoring, risk frameworks, and trend analysis",maritime:"Maritime & Trade",maritimeDesc:"Ship movements, vessel detection, port activity, and cargo inference",aviation:"Aviation Tracking",aviationDesc:"ADS-B transponder tracking of global flight patterns",infra:"Critical Infrastructure",infraDesc:"Nuclear sites, power grids, pipelines, refineries — 50K+ mapped assets",fire:"Satellite Fire Detection",fireDesc:"NASA FIRMS near-real-time fire and hotspot data",cables:"Submarine Cables",cablesDesc:"Undersea cable routes and landing stations",internet:"Internet & GPS",internetDesc:"Outage detection, BGP anomalies, GPS jamming zones",cyber:"Cyber Threats",cyberDesc:"Ransomware feeds, BGP hijacks, DDoS detection",gdelt:"GDELT & News",gdeltDesc:"500+ RSS feeds, AI-scored GDELT events, live broadcasts",seismology:"Seismology & Natural",seismologyDesc:"USGS earthquakes, volcanic activity, severe weather"},SR={free:"Free",freeTagline:"See everything",freeDesc:"The open-source dashboard",freeF1:"5-15 min refresh",freeF2:"500+ feeds, 45 map layers",freeF3:"BYOK for AI",freeF4:"Free forever",openDashboard:"Open Dashboard",pro:"Pro",proTagline:"Markets, macro & geopolitics",proDesc:"Your AI analyst",proF1:"Equity research & stock analysis",proF2:"+ daily briefs, economy analytics",proF3:"AI included, 1 key",proF4:"Priority data refresh (Soon)",priceMonthly:"$39.99 / month",priceAnnual:"$399.99 / year",annualSavingsNote:"2 months free",enterprise:"Enterprise",enterpriseTagline:"Act before anyone else",enterpriseDesc:"The intelligence platform",entF1:"Live-edge + satellite imagery",entF2:"+ AI agents, 50K+ infra, SAR",entF3:"Custom AI, investor personas",entF4:"Contact us",contactSales:"Contact Sales"},wR={proTier:"PRO TIER",title:"Your AI Analyst That Never Sleeps",subtitle:"The free dashboard shows you the world. Pro gives you an analyst to ask, a digest you subscribe to, and primitives to build on. Stocks, macro, geopolitical risk — and the connections between them.",equityResearch:"Equity Research",equityResearchDesc:"Global stock analysis with financials visualization, analyst price targets, and valuation metrics. Track what moves markets.",geopoliticalAnalysis:"Geopolitical Analysis",geopoliticalAnalysisDesc:"Grand Chessboard strategic framework, Prisoners of Geography models, and central bank & monetary policy tracking.",economyAnalytics:"Economy Analytics",economyAnalyticsDesc:"GDP, inflation, interest rates, and growth cycles. Macro data correlated with market signals and geopolitical events.",riskMonitoring:"Risk Monitoring & Scenarios",riskMonitoringDesc:"Global risk scoring, scenario analysis, and geopolitical risk assessment. Convergence detection across market and political signals.",orbitalSurveillance:"Orbital Surveillance",orbitalSurveillanceDesc:"(Soon) Overhead pass predictions, revisit frequency analysis, and imaging window alerts. Know when intelligence satellites are watching your areas of interest.",morningBriefs:"Personal Intelligence Desk",morningBriefsDesc:"Up to 30 ranked stories per digest, deduped across 500+ sources. Pick daily, twice-daily, or weekly cadence — or real-time alerts for critical events. AI Assessment and Signals to watch delivered to Slack, Discord, Telegram, Email, or webhook. Not a newsletter — an analyst.",oneKey:"30+ Services, 1 Key",oneKeyDesc:"Finnhub, FRED, ACLED, UCDP, NASA FIRMS, AISStream, OpenSky, and more — all active, no separate registrations.",deliveryLabel:"Choose how intelligence finds you"},_R={morningBrief:"Morning Brief",markets:"Markets",marketsText:"S&P 500 futures -1.2% pre-market. Fed Chair testimony at 10am EST — rate-sensitive sectors under pressure. Analyst consensus shifting on Q2 earnings.",elevated:"Macro",elevatedText:"ECB holds rates at 3.75%. Euro area GDP revised up to 1.1%. Central bank divergence widening — USD/EUR at 3-month high.",watch:"Geopolitical",watchText:"Brent +2.3% on Hormuz AIS anomaly. 4 dark ships in 6h. Commodity supply chain risk elevated — energy sector correlations spiking."},TR={apiTier:"API TIER",title:"Programmatic Intelligence",subtitle:"For developers, analysts, and teams building on World Monitor data. Separate from Pro — use both or either.",restApi:"REST API across all 30+ service domains",authenticated:"Authenticated per-key, rate-limited per tier",structured:"Structured JSON with cache headers and OpenAPI 3.1 docs",starter:"Starter",starterReqs:"1,000 req/day",starterWebhooks:"5 webhook rules",business:"Business",businessReqs:"50,000 req/day",businessWebhooks:"Unlimited webhooks + SLA",feedData:"Feed data into your dashboards, automate alerting via Zapier/n8n/Make, build custom scoring models on CII/risk data."},ER={enterpriseTier:"ENTERPRISE TIER",title:"Intelligence Infrastructure",subtitle:"For governments, institutions, trading desks, and organizations that need the full platform with maximum security, AI agents, TV apps, and data depth.",security:"Government-Grade Security",securityDesc:"Air-gapped deployment, on-premises Docker, dedicated cloud tenant, SOC 2 Type II path, SSO/MFA, and full audit trail.",aiAgents:"AI Agents & MCP",aiAgentsDesc:"Autonomous intelligence agents with investor personas. Connect World Monitor as a tool to Claude, GPT, or custom LLMs via MCP.",dataLayers:"Expanded Data Layers",dataLayersDesc:"Tens of thousands of infrastructure assets mapped globally. Satellite imagery integration with change detection and SAR.",connectors:"100+ Data Connectors",connectorsDesc:"PostgreSQL, Snowflake, Splunk, Sentinel, Jira, Slack, Teams, and more. Export to PDF, PowerPoint, CSV, GeoJSON.",whiteLabel:"White-Label, TV & Embeddable",whiteLabelDesc:"Your brand, your domain, your desktop app. Android TV app for SOC walls and trading floors. Embeddable iframe panels.",financial:"Financial Intelligence",financialDesc:"Earnings calendar, energy grid data, enhanced commodity tracking with cargo inference, sanctions screening with AIS correlation.",commodity:"Commodity Trading",commodityDesc:"Vessel tracking + cargo inference + supply chain graph. Know before the market moves.",government:"Government & Institutions",governmentDesc:"Air-gapped, AI agents, full situational awareness, MCP. No data leaves your network.",risk:"Risk Consultancies",riskDesc:"Scenario simulation, investor personas, branded PDF/PowerPoint reports on demand.",soc:"SOCs & CERT",socDesc:"Cyber threat layer, SIEM integration, BGP anomaly monitoring, ransomware feeds.",talkToSales:"Talk to Sales",contactFormTitle:"Talk to our team",contactFormSubtitle:"Tell us about your organization and we'll get back to you within one business day.",namePlaceholder:"Your name",emailPlaceholder:"Work email",orgPlaceholder:"Company *",phonePlaceholder:"Phone number *",messagePlaceholder:"What are you looking for?",workEmailRequired:"Please use your work email address",submitContact:"Send Message",contactSending:"Sending...",contactSent:"Message sent. We'll be in touch.",contactFailed:"Failed to send. Please email enterprise@worldmonitor.app"},AR={title:"Compare Tiers",feature:"Feature",freeHeader:"Free ($0)",proHeader:"Pro ($39.99)",apiHeader:"API ($99.99)",entHeader:"Enterprise (Contact)",dataRefresh:"Data refresh",dashboard:"Dashboard",ai:"AI",briefsAlerts:"Briefs & alerts",delivery:"Delivery",apiRow:"API",infraLayers:"Infrastructure layers",satellite:"Orbital Surveillance",connectorsRow:"Connectors",deployment:"Deployment",securityRow:"Security",f5_15min:"5-15 min",fLt60s:"<60 seconds",fPerRequest:"Per-request",fLiveEdge:"Live-edge",f50panels:"50+ panels",fWhiteLabel:"White-label",fBYOK:"BYOK",fIncluded:"Included",fAgentsPersonas:"Agents + personas",fDailyFlash:"Daily + flash",fTeamDist:"Team distribution",fSlackTgWa:"Slack/Discord/TG/Email/Webhook",fWebhook:"Webhook",fSiemMcp:"+ SIEM/MCP",fRestWebhook:"REST + webhook",fMcpBulk:"+ MCP + bulk",f45:"45",fTensOfThousands:"+ tens of thousands",fLiveTracking:"Live tracking",fPassAlerts:"Pass alerts + analysis",fImagerySar:"Imagery + SAR",f100plus:"100+",fCloud:"Cloud",fCloudOnPrem:"Cloud/on-prem/air-gap",fStandard:"Standard",fKeyAuth:"Key auth",fSsoMfa:"SSO/MFA/RBAC/audit",noteBelow:"The core platform remains free. Paid plans unlock equity research, macro analytics, AI briefings, and organizational use."},NR={title:"Frequently Asked Questions",q1:"Is World Monitor still free?",a1:"Yes. The core platform remains free. Pro adds equity research, macro analytics, and AI briefings. Enterprise adds team deployments and TV apps.",q2:"Why pay for Pro?",a2:"Pro is for investors, analysts, and professionals who want stock monitoring, geopolitical analysis, economy analytics, and AI-powered daily briefings — all under one key.",q3:"Who is Enterprise for?",a3:"Enterprise is for teams that need shared use, APIs, integrations, deployment options, and direct support.",q4:"Can I start with Pro and upgrade later?",a4:"Yes. Pro works for serious individuals. Enterprise is there when team and deployment needs grow.",q5:"Is this only for conflict monitoring?",a5:"No. World Monitor is primarily a global intelligence platform covering stock markets, macroeconomics, geopolitical analysis, energy, infrastructure, and more. Conflict tracking is one of many capabilities — not the focus.",q6:"Why keep the core platform free?",a6:"Because public access matters. Paid plans fund deeper workflows for serious users and organizations.",q7:"Can I still use my own API keys?",a7:"Yes. Bring-your-own-keys always works. Pro simply means you don't have to register for 20+ separate services.",q8:"What's MCP?",a8:"MCP lets AI agents — Claude, GPT, custom LLMs — use WorldMonitor as a tool, querying all 30+ services. Included in Pro. Enterprise adds private MCP servers and custom deployments.",q9:"Can I build my own panels?",a9:"Yes. Pro includes the Custom Widget Builder — build panels from HTML, CSS, and JavaScript, with AI-assisted modification.",q10:"Can I connect Claude or GPT to WorldMonitor?",a10:"Yes. MCP is included in Pro — plug WorldMonitor into Claude, GPT, or any MCP-compatible LLM as a live tool.",q11:"How personalized is the digest?",a11:"Pick your cadence — daily, twice-daily, or weekly. We re-score every tracked story against your alert rules and watchlist, dedupe across 500+ sources, and send up to 30 ranked items with an AI Assessment and Signals to watch written to your context. Real-time alerts are also available for critical events.",q12:"What's the refresh rate?",a12:"Near real time for Pro. 5–15 minutes on Free.",q13:"Where does my data go?",a13:"Notification channels are AES-256 encrypted at rest. Digests never leave our pipeline unredacted."},DR={title:"Start with Pro. Scale to Enterprise.",subtitle:"Keep using World Monitor for free, or upgrade for equity research, macro analytics, and AI briefings. If your organization needs team access, TV apps, or API support, talk to us.",getPro:"Reserve Your Early Access",talkToSales:"Talk to Sales"},CR={beFirstInLine:"Be first in line.",lookingForEnterprise:"Looking for Enterprise?",contactUs:"Contact us",wiredArticle:"WIRED Article"},jR={submitting:"Submitting...",joinWaitlist:"Reserve Your Early Access",tooManyRequests:"Too many requests",failedTryAgain:"Failed — try again"},MR={alreadyOnList:"You're already on the list.",shareHint:"Share your link to move up the line. Each friend who joins bumps you closer to the front.",copied:"Copied!",shareOnX:"Share on X",linkedin:"LinkedIn",whatsapp:"WhatsApp",telegram:"Telegram",shareText:"I just joined the World Monitor Pro waitlist — stock monitoring, geopolitical analysis, and AI daily briefings in one platform. Join me:",joinWaitlistShare:"Join the World Monitor Pro waitlist:",youreIn:"You're in!",invitedBanner:"You've been invited — join the waitlist"},OR="Soon",jS={nav:uR,hero:fR,wired:dR,twoPath:hR,whyUpgrade:mR,pillars:pR,deliveryDesk:gR,livePreview:yR,socialProof:vR,audience:xR,dataCoverage:bR,tiers:SR,proShowcase:wR,slackMock:_R,apiSection:TR,enterpriseShowcase:ER,pricingTable:AR,faq:NR,finalCta:DR,footer:CR,form:jR,referral:MR,soonBadge:OR},MS=["en","ar","bg","cs","de","el","es","fr","it","ja","ko","nl","pl","pt","ro","ru","sv","th","tr","vi","zh"],RR=new Set(MS),Nx=new Set(["en"]),kR=new Set(["ar"]),LR=Object.assign({"./locales/ar.json":()=>qe(()=>import("./ar-Cm8L16fJ.js"),[]).then(n=>n.default),"./locales/bg.json":()=>qe(()=>import("./bg-meSd4JsJ.js"),[]).then(n=>n.default),"./locales/cs.json":()=>qe(()=>import("./cs-ptRTyzJj.js"),[]).then(n=>n.default),"./locales/de.json":()=>qe(()=>import("./de-C3_MVNE9.js"),[]).then(n=>n.default),"./locales/el.json":()=>qe(()=>import("./el-B9-X35aF.js"),[]).then(n=>n.default),"./locales/es.json":()=>qe(()=>import("./es-DKuPMUhm.js"),[]).then(n=>n.default),"./locales/fr.json":()=>qe(()=>import("./fr-CqZfnoPg.js"),[]).then(n=>n.default),"./locales/it.json":()=>qe(()=>import("./it-xRd9wXeo.js"),[]).then(n=>n.default),"./locales/ja.json":()=>qe(()=>import("./ja-BvG2yjL7.js"),[]).then(n=>n.default),"./locales/ko.json":()=>qe(()=>import("./ko-Bp1BAWvm.js"),[]).then(n=>n.default),"./locales/nl.json":()=>qe(()=>import("./nl-CIy0NOIy.js"),[]).then(n=>n.default),"./locales/pl.json":()=>qe(()=>import("./pl-P7FWM5y7.js"),[]).then(n=>n.default),"./locales/pt.json":()=>qe(()=>import("./pt-RlnECMQU.js"),[]).then(n=>n.default),"./locales/ro.json":()=>qe(()=>import("./ro-OfGDlDfm.js"),[]).then(n=>n.default),"./locales/ru.json":()=>qe(()=>import("./ru-BgqyPHlN.js"),[]).then(n=>n.default),"./locales/sv.json":()=>qe(()=>import("./sv-DuX3Lsqd.js"),[]).then(n=>n.default),"./locales/th.json":()=>qe(()=>import("./th-CD3FOyKH.js"),[]).then(n=>n.default),"./locales/tr.json":()=>qe(()=>import("./tr-F4p4sScu.js"),[]).then(n=>n.default),"./locales/vi.json":()=>qe(()=>import("./vi-D1texoPw.js"),[]).then(n=>n.default),"./locales/zh.json":()=>qe(()=>import("./zh-BxyDCIra.js"),[]).then(n=>n.default)});function zR(n){var a;const t=((a=(n||"en").split("-")[0])==null?void 0:a.toLowerCase())||"en";return RR.has(t)?t:"en"}async function VR(n){const t=zR(n);if(Nx.has(t))return t;const a=LR[`./locales/${t}.json`],r=a?await a():jS;return Qe.addResourceBundle(t,"translation",r,!0,!0),Nx.add(t),t}async function BR(){if(Qe.isInitialized)return;await Qe.use(CS).init({resources:{en:{translation:jS}},supportedLngs:[...MS],nonExplicitSupportedLngs:!0,fallbackLng:"en",interpolation:{escapeValue:!1},detection:{order:["querystring","localStorage","navigator"],lookupQuerystring:"lang",caches:["localStorage"]}});const n=await VR(Qe.language||"en");n!=="en"&&await Qe.changeLanguage(n);const t=(Qe.language||n).split("-")[0]||"en";document.documentElement.setAttribute("lang",t==="zh"?"zh-CN":t),kR.has(t)&&document.documentElement.setAttribute("dir","rtl")}function _(n,t){return Qe.t(n,t)}const Bl="wm_checkout_product",Ul="wm_checkout_ref",Pl="wm_checkout_discount";function UR(n){const t=new URLSearchParams(n),a=t.get(Bl);return a?{productId:a,referralCode:t.get(Ul)??void 0,discountCode:t.get(Pl)??void 0}:null}function PR(n){const t=new URLSearchParams(n);t.delete(Bl),t.delete(Ul),t.delete(Pl);const a=t.toString();return a?`?${a}`:""}function HR(n,t,a){const r=new URL(n);return r.searchParams.delete(Bl),r.searchParams.delete(Ul),r.searchParams.delete(Pl),r.searchParams.set(Bl,t),a!=null&&a.referralCode&&r.searchParams.set(Ul,a.referralCode),a!=null&&a.discountCode&&r.searchParams.set(Pl,a.discountCode),r.toString()}const OS="https://api.worldmonitor.app/api",Dx="https://customer.dodopayments.com",IR="ACTIVE_SUBSCRIPTION_EXISTS",Cx="'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace";let pt=null,bl=!1,cr=null,RS={kind:"idle"};const Yd=new Set;function jx(n){RS=n;for(const t of Yd)try{t(n)}catch(a){console.error("[checkout] phase subscriber threw:",a)}}function qR(n){return Yd.add(n),n(RS),()=>{Yd.delete(n)}}async function ta(){return pt||cr||(cr=FR().catch(n=>{throw cr=null,n}),cr)}async function FR(){const{Clerk:n}=await qe(async()=>{const{Clerk:r}=await import("./clerk-PNSFEZs8.js");return{Clerk:r}},[]),t="pk_live_Y2xlcmsud29ybGRtb25pdG9yLmFwcCQ",a=new n(t);return await a.load({appearance:{variables:{colorBackground:"#0f0f0f",colorInputBackground:"#141414",colorInputText:"#e8e8e8",colorText:"#e8e8e8",colorTextSecondary:"#aaaaaa",colorPrimary:"#44ff88",colorNeutral:"#e8e8e8",colorDanger:"#ff4444",borderRadius:"4px",fontFamily:Cx,fontFamilyButtons:Cx},elements:{card:{backgroundColor:"#111111",border:"1px solid #2a2a2a",boxShadow:"0 8px 32px rgba(0,0,0,0.6)"},formButtonPrimary:{color:"#000000",fontWeight:"600"},footerActionLink:{color:"#44ff88"},socialButtonsBlockButton:{borderColor:"#2a2a2a",color:"#e8e8e8",backgroundColor:"#141414"}}}}),pt=a,pt}function GR(n){qe(async()=>{const{DodoPayments:t}=await import("./index.esm-BiNDwt_v.js");return{DodoPayments:t}},[]).then(({DodoPayments:t})=>{t.Initialize({mode:"test",displayType:"overlay",onEvent:a=>{const r=a.data,l=r==null?void 0:r.message,c=l==null?void 0:l.status;if(console.info("[checkout] dodo event",a.event_type,c!==void 0?{status:c}:void 0),a.event_type==="checkout.status"&&c==="succeeded"&&(n==null||n()),a.event_type==="checkout.redirect_requested"){const f=l==null?void 0:l.redirect_to;window.location.href=f||"https://worldmonitor.app/?wm_checkout=success"}a.event_type==="checkout.link_expired"&&sb("Dodo checkout link expired",{level:"info",tags:{surface:"pro-marketing",code:"link_expired"}})}})}).catch(t=>{console.error("[checkout] Failed to load Dodo overlay SDK:",t)})}async function YR(n,t){if(bl)return!1;let a;try{a=await ta()}catch(r){return console.error("[checkout] Failed to load Clerk:",r),Ji(r,{tags:{surface:"pro-marketing",action:"load-clerk"}}),!1}if(!a.user){const r=HR(window.location.href,n,t);try{a.openSignIn({afterSignInUrl:r,afterSignUpUrl:r})}catch(l){console.error("[checkout] Failed to open sign in:",l),Ji(l,{tags:{surface:"pro-marketing",action:"checkout-sign-in"}})}return!1}return kS(n,t??{})}async function KR(){const n=UR(window.location.search);if(!n)return!1;const t=PR(window.location.search),a=window.location.pathname+t+window.location.hash;window.history.replaceState({},"",a);let r;try{r=await ta()}catch{return!1}if(!r.user)return!1;const{productId:l,referralCode:c,discountCode:f}=n;return kS(l,{referralCode:c,discountCode:f})}async function kS(n,t){var a;if(bl)return!1;bl=!0,jx({kind:"creating_checkout",productId:n});try{$R();const r=await Mx();if(!r)return console.error("[checkout] No auth token after retry"),!1;const l=await fetch(`${OS}/create-checkout`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${r}`},body:JSON.stringify({productId:n,returnUrl:"https://worldmonitor.app/?wm_checkout=success",discountCode:t.discountCode,referralCode:t.referralCode}),signal:AbortSignal.timeout(15e3)});if(!l.ok){const h=await l.json().catch(()=>({}));if(console.error("[checkout] Edge error:",l.status,h),l.status===409&&(h==null?void 0:h.error)===IR){const m=(a=h==null?void 0:h.subscription)==null?void 0:a.planKey;tk({planDisplayName:ek(m),onConfirm:async()=>{const p=QR(),v=await Mx();if(!v){console.error("[checkout] No token available for billing portal"),p&&!p.closed&&p.close();return}WR(v,p)},onDismiss:()=>{}}),sb("Duplicate subscription checkout attempt",{level:"info",tags:{surface:"pro-marketing",code:"duplicate_subscription"},extra:{serverMessage:h==null?void 0:h.message}})}return!1}const c=await l.json();if(!(c!=null&&c.checkout_url))return console.error("[checkout] No checkout_url in response"),!1;const{DodoPayments:f}=await qe(async()=>{const{DodoPayments:h}=await import("./index.esm-BiNDwt_v.js");return{DodoPayments:h}},[]);return f.Checkout.open({checkoutUrl:c.checkout_url,options:{manualRedirect:!0,themeConfig:{dark:{bgPrimary:"#0d0d0d",bgSecondary:"#1a1a1a",borderPrimary:"#323232",textPrimary:"#ffffff",textSecondary:"#909090",buttonPrimary:"#22c55e",buttonPrimaryHover:"#16a34a",buttonTextPrimary:"#0d0d0d"},light:{bgPrimary:"#ffffff",bgSecondary:"#f8f9fa",borderPrimary:"#d4d4d4",textPrimary:"#1a1a1a",textSecondary:"#555555",buttonPrimary:"#16a34a",buttonPrimaryHover:"#15803d",buttonTextPrimary:"#ffffff"},radius:"4px"}}}),!0}catch(r){return console.error("[checkout] Failed:",r),!1}finally{bl=!1,LS(),jx({kind:"idle"})}}const Kd="wm-checkout-interstitial",XR=1e4;let Sl=null;function $R(){if(document.getElementById(Kd))return;const n=document.createElement("div");n.id=Kd,n.setAttribute("role","status"),n.setAttribute("aria-live","polite"),Object.assign(n.style,{position:"fixed",inset:"0",zIndex:"99990",background:"rgba(10, 10, 10, 0.82)",backdropFilter:"blur(4px)",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:"16px",color:"#e8e8e8",fontSize:"14px",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",transition:"opacity 0.2s ease",opacity:"0"}),n.innerHTML=`
Opening checkout…
- `,document.body.appendChild(n),requestAnimationFrame(()=>{n.style.opacity="1"}),Sl=setTimeout(()=>{kS(),ZR()},XR)}function kS(){Sl&&(clearTimeout(Sl),Sl=null);const n=document.getElementById("wm-checkout-loading-toast");n&&n.remove();const t=document.getElementById(Kd);t&&(t.style.opacity="0",setTimeout(()=>t.remove(),200))}function ZR(){const n="wm-checkout-loading-toast";if(document.getElementById(n))return;const t=document.createElement("div");t.id=n,t.setAttribute("role","alert"),Object.assign(t.style,{position:"fixed",top:"20px",left:"50%",transform:"translateX(-50%)",zIndex:"99995",background:"rgba(20, 20, 20, 0.95)",color:"#e8e8e8",padding:"10px 18px",borderRadius:"6px",border:"1px solid #2a2a2a",fontSize:"13px",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",boxShadow:"0 4px 16px rgba(0,0,0,0.4)"}),t.textContent="Still loading, please wait…",document.body.appendChild(t),setTimeout(()=>t.remove(),5e3)}async function Mx(){var t,a,r,l;let n=await((t=pt==null?void 0:pt.session)==null?void 0:t.getToken({template:"convex"}).catch(()=>null))??await((a=pt==null?void 0:pt.session)==null?void 0:a.getToken().catch(()=>null));return n||(await new Promise(c=>setTimeout(c,2e3)),n=await((r=pt==null?void 0:pt.session)==null?void 0:r.getToken({template:"convex"}).catch(()=>null))??await((l=pt==null?void 0:pt.session)==null?void 0:l.getToken().catch(()=>null))),n}function QR(){return window.open("","_blank","noopener,noreferrer")}async function WR(n,t){const a=t??null,r=l=>{a&&!a.closed?a.location.href=l:window.open(l,"_blank","noopener,noreferrer")||window.location.assign(l)};try{const l=await fetch(`${MS}/customer-portal`,{method:"POST",headers:{Authorization:`Bearer ${n}`},signal:AbortSignal.timeout(15e3)}),c=await l.json().catch(()=>({})),f=typeof(c==null?void 0:c.portal_url)=="string"?c.portal_url:Dx;l.ok||console.error("[checkout] Customer portal error:",l.status,c),r(f)}catch(l){console.error("[checkout] Failed to open billing portal:",l),r(Dx)}}const JR={pro_monthly:"Pro Monthly",pro_annual:"Pro Annual",api_starter:"API Starter",api_business:"API Business"};function e4(n){return typeof n!="string"||n.length===0?"Pro":JR[n]??"Pro"}const Ga="wm-pro-duplicate-subscription-dialog";function t4(n){var h,m;if(document.getElementById(Ga))return;const t=document.createElement("div");t.id=Ga,t.setAttribute("role","dialog"),t.setAttribute("aria-modal","true"),Object.assign(t.style,{position:"fixed",inset:"0",zIndex:"99990",background:"rgba(10, 10, 10, 0.72)",backdropFilter:"blur(4px)",display:"flex",alignItems:"center",justifyContent:"center",padding:"24px"});const a=document.createElement("div");Object.assign(a.style,{background:"#141414",border:"1px solid #2a2a2a",borderRadius:"8px",padding:"20px 22px",maxWidth:"440px",width:"100%",color:"#e8e8e8",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",boxShadow:"0 12px 40px rgba(0,0,0,0.5)"}),a.innerHTML=` + `,document.body.appendChild(n),requestAnimationFrame(()=>{n.style.opacity="1"}),Sl=setTimeout(()=>{LS(),ZR()},XR)}function LS(){Sl&&(clearTimeout(Sl),Sl=null);const n=document.getElementById("wm-checkout-loading-toast");n&&n.remove();const t=document.getElementById(Kd);t&&(t.style.opacity="0",setTimeout(()=>t.remove(),200))}function ZR(){const n="wm-checkout-loading-toast";if(document.getElementById(n))return;const t=document.createElement("div");t.id=n,t.setAttribute("role","alert"),Object.assign(t.style,{position:"fixed",top:"20px",left:"50%",transform:"translateX(-50%)",zIndex:"99995",background:"rgba(20, 20, 20, 0.95)",color:"#e8e8e8",padding:"10px 18px",borderRadius:"6px",border:"1px solid #2a2a2a",fontSize:"13px",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",boxShadow:"0 4px 16px rgba(0,0,0,0.4)"}),t.textContent="Still loading, please wait…",document.body.appendChild(t),setTimeout(()=>t.remove(),5e3)}async function Mx(){var t,a,r,l;let n=await((t=pt==null?void 0:pt.session)==null?void 0:t.getToken({template:"convex"}).catch(()=>null))??await((a=pt==null?void 0:pt.session)==null?void 0:a.getToken().catch(()=>null));return n||(await new Promise(c=>setTimeout(c,2e3)),n=await((r=pt==null?void 0:pt.session)==null?void 0:r.getToken({template:"convex"}).catch(()=>null))??await((l=pt==null?void 0:pt.session)==null?void 0:l.getToken().catch(()=>null))),n}function QR(){return window.open("","_blank","noopener,noreferrer")}async function WR(n,t){const a=t??null,r=l=>{a&&!a.closed?a.location.href=l:window.open(l,"_blank","noopener,noreferrer")||window.location.assign(l)};try{const l=await fetch(`${OS}/customer-portal`,{method:"POST",headers:{Authorization:`Bearer ${n}`},signal:AbortSignal.timeout(15e3)}),c=await l.json().catch(()=>({})),f=typeof(c==null?void 0:c.portal_url)=="string"?c.portal_url:Dx;l.ok||console.error("[checkout] Customer portal error:",l.status,c),r(f)}catch(l){console.error("[checkout] Failed to open billing portal:",l),r(Dx)}}const JR={pro_monthly:"Pro Monthly",pro_annual:"Pro Annual",api_starter:"API Starter",api_business:"API Business"};function ek(n){return typeof n!="string"||n.length===0?"Pro":JR[n]??"Pro"}const Ga="wm-pro-duplicate-subscription-dialog";function tk(n){var h,m;if(document.getElementById(Ga))return;const t=document.createElement("div");t.id=Ga,t.setAttribute("role","dialog"),t.setAttribute("aria-modal","true"),Object.assign(t.style,{position:"fixed",inset:"0",zIndex:"99990",background:"rgba(10, 10, 10, 0.72)",backdropFilter:"blur(4px)",display:"flex",alignItems:"center",justifyContent:"center",padding:"24px"});const a=document.createElement("div");Object.assign(a.style,{background:"#141414",border:"1px solid #2a2a2a",borderRadius:"8px",padding:"20px 22px",maxWidth:"440px",width:"100%",color:"#e8e8e8",fontFamily:"'SF Mono', Monaco, 'Cascadia Code', 'Fira Code', monospace",boxShadow:"0 12px 40px rgba(0,0,0,0.5)"}),a.innerHTML=`

Subscription already active

- Your account already has an active ${n4(n.planDisplayName)} subscription. Open the billing portal to manage it — you won't be charged twice. + Your account already has an active ${nk(n.planDisplayName)} subscription. Open the billing portal to manage it — you won't be charged twice.

- `,t.appendChild(a),document.body.appendChild(t);let r=!1;const l=p=>{p.key==="Escape"&&f()},c=()=>{document.removeEventListener("keydown",l,!0),t.remove()},f=()=>{r||(r=!0,c())};(h=document.getElementById(`${Ga}-confirm`))==null||h.addEventListener("click",()=>{r||(r=!0,c(),n.onConfirm())}),(m=document.getElementById(`${Ga}-dismiss`))==null||m.addEventListener("click",f),t.addEventListener("click",p=>{p.target===t&&f()}),document.addEventListener("keydown",l,!0)}function n4(n){return n.replace(/[&<>"']/g,t=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[t]??t)}const i4=[{name:"Free",price:0,period:"forever",description:"Get started with the essentials",features:["Core dashboard panels","Global news feed","Earthquake & weather alerts","Basic map view"],cta:"Get Started",href:"https://worldmonitor.app",highlighted:!1},{name:"Pro",monthlyPrice:39.99,annualPrice:399.99,description:"Full intelligence dashboard",features:["Everything in Free","AI stock analysis & backtesting","Daily market briefs","Military & geopolitical tracking","Custom widget builder","MCP data connectors","Priority data refresh"],monthlyProductId:"pdt_0Nbtt71uObulf7fGXhQup",annualProductId:"pdt_0NbttMIfjLWC10jHQWYgJ",highlighted:!0},{name:"API",monthlyPrice:99.99,annualPrice:999,description:"Programmatic access to intelligence data",features:["REST API access","Real-time data streams","1,000 requests/day","Webhook notifications","Custom data exports"],monthlyProductId:"pdt_0NbttVmG1SERrxhygbbUq",annualProductId:"pdt_0Nbu2lawHYE3dv2THgSEV",highlighted:!1},{name:"Enterprise",price:null,description:"Custom solutions for organizations",features:["Everything in Pro + API","Unlimited API requests","Dedicated support","Custom integrations","SLA guarantee","On-premise option"],cta:"Contact Sales",href:"mailto:enterprise@worldmonitor.app",highlighted:!1}],a4="https://api.worldmonitor.app/api/product-catalog";function s4(){const[n,t]=K.useState(i4);return K.useEffect(()=>{let a=!1;return fetch(a4,{signal:AbortSignal.timeout(5e3)}).then(r=>r.ok?r.json():null).then(r=>{var l;!a&&((l=r==null?void 0:r.tiers)!=null&&l.length)&&t(r.tiers)}).catch(()=>{}),()=>{a=!0}},[]),n}function r4(n,t){return n.price===0?{amount:"$0",suffix:"forever"}:n.price===null&&n.monthlyPrice===void 0?{amount:"Custom",suffix:"tailored to you"}:n.annualPrice===null&&n.monthlyPrice!==void 0?{amount:`$${n.monthlyPrice}`,suffix:"/mo"}:t==="annual"&&n.annualPrice!=null?{amount:`$${n.annualPrice}`,suffix:"/yr"}:{amount:`$${n.monthlyPrice}`,suffix:"/mo"}}function Ox(n){if(!n||n==="#"||n.startsWith("#")||n.startsWith("/")&&!n.startsWith("//"))return!0;const t=!/^[a-z][a-z0-9+.-]*:/i.test(n)&&!n.startsWith("//");try{const a=typeof window<"u"?window.location.href:"https://worldmonitor.app/",r=new URL(n,t?a:void 0);return r.protocol!=="http:"&&r.protocol!=="https:"?!1:r.hostname==="worldmonitor.app"||r.hostname.endsWith(".worldmonitor.app")||r.hostname==="localhost"||r.hostname==="127.0.0.1"}catch{return!1}}function o4(n,t){if(n.cta&&n.href&&n.price===0)return{type:"link",label:n.cta,href:n.href,external:!Ox(n.href)};if(n.cta&&n.href&&n.price===null)return{type:"link",label:n.cta,href:n.href,external:!Ox(n.href)};if(n.monthlyProductId){const a=t==="annual"&&n.annualProductId?n.annualProductId:n.monthlyProductId;return{type:"checkout",label:n.cta??"Get Started",productId:a}}return{type:"link",label:"Learn More",href:"#",external:!1}}function l4({refCode:n}){const[t,a]=K.useState("monthly"),[r,l]=K.useState({kind:"idle"}),c=r.kind==="creating_checkout"?r.productId:null,f=s4();K.useEffect(()=>qR(l),[]);const h=K.useCallback(m=>{YR(m,{referralCode:n})},[n]);return g.jsx("section",{id:"pricing",className:"py-24 px-6 border-t border-wm-border bg-[#060606]",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsxs("div",{className:"text-center mb-16",children:[g.jsx(Za.h2,{className:"text-3xl md:text-5xl font-display font-bold mb-4",initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5},children:"Choose Your Plan"}),g.jsx(Za.p,{className:"text-wm-muted max-w-xl mx-auto mb-8",initial:{opacity:0,y:10},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:.1},children:"From real-time monitoring to full intelligence infrastructure. Pick the tier that fits your mission."}),g.jsxs(Za.div,{className:"inline-flex items-center gap-3 bg-wm-card border border-wm-border rounded-sm p-1",initial:{opacity:0,y:10},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:.2},children:[g.jsx("button",{onClick:()=>a("monthly"),disabled:c!==null,className:`px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider transition-colors disabled:cursor-not-allowed disabled:opacity-60 ${t==="monthly"?"bg-wm-green text-wm-bg font-bold":"text-wm-muted hover:text-wm-text"}`,children:"Monthly"}),g.jsxs("button",{onClick:()=>a("annual"),disabled:c!==null,className:`px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider transition-colors flex items-center gap-2 disabled:cursor-not-allowed disabled:opacity-60 ${t==="annual"?"bg-wm-green text-wm-bg font-bold":"text-wm-muted hover:text-wm-text"}`,children:["Annual",g.jsx("span",{className:`text-[10px] px-1.5 py-0.5 rounded-sm ${t==="annual"?"bg-wm-bg/20 text-wm-bg":"bg-wm-green/10 text-wm-green"}`,children:"Save 17%"})]})]})]}),g.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6",children:f.map((m,p)=>{const v=r4(m,t),x=o4(m,t);return g.jsxs(Za.div,{className:`relative bg-zinc-900 rounded-lg p-6 flex flex-col ${m.highlighted?"border-2 border-wm-green shadow-lg shadow-wm-green/10":"border border-wm-border"}`,initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:p*.1},children:[m.highlighted&&g.jsxs("div",{className:"absolute -top-3 left-1/2 -translate-x-1/2 inline-flex items-center gap-1 bg-wm-green text-wm-bg px-3 py-1 rounded-full text-xs font-mono font-bold uppercase tracking-wider",children:[g.jsx(TO,{className:"w-3 h-3","aria-hidden":"true"}),"Most Popular"]}),g.jsx("h3",{className:`font-display text-lg font-bold mb-1 ${m.highlighted?"text-wm-green":"text-wm-text"}`,children:m.name}),g.jsx("p",{className:"text-xs text-wm-muted mb-4",children:m.description}),g.jsxs("div",{className:"mb-6",children:[g.jsx("span",{className:"text-4xl font-display font-bold",children:v.amount}),g.jsxs("span",{className:"text-sm text-wm-muted ml-1",children:["/",v.suffix]})]}),g.jsx("ul",{className:"space-y-3 mb-8 flex-1",children:m.features.map((S,w)=>g.jsxs("li",{className:"flex items-start gap-2 text-sm",children:[g.jsx(Fd,{className:`w-4 h-4 shrink-0 mt-0.5 ${m.highlighted?"text-wm-green":"text-wm-muted"}`,"aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:S})]},w))}),x.type==="link"?g.jsxs("a",{href:x.href,target:x.external?"_blank":void 0,rel:x.external?"noreferrer":void 0,className:`block text-center py-3 rounded-sm font-mono text-xs uppercase tracking-wider font-bold transition-colors ${m.highlighted?"bg-wm-green text-wm-bg hover:bg-green-400":"border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text"}`,children:[x.label," ",g.jsx(Hn,{className:"w-3.5 h-3.5 inline-block ml-1","aria-hidden":"true"})]}):(()=>{const S=c===x.productId;return g.jsx("button",{onClick:()=>h(x.productId),disabled:S,"aria-busy":S||void 0,className:`block w-full text-center py-3 rounded-sm font-mono text-xs uppercase tracking-wider font-bold transition-colors ${S?"cursor-wait opacity-70":"cursor-pointer"} ${m.highlighted?"bg-wm-green text-wm-bg hover:bg-green-400":"border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text"}`,children:S?g.jsxs(g.Fragment,{children:[g.jsx(tO,{className:"w-3.5 h-3.5 inline-block mr-2 animate-spin","aria-hidden":"true"}),g.jsx("span",{children:"Opening…"})]}):g.jsxs(g.Fragment,{children:[x.label," ",g.jsx(Hn,{className:"w-3.5 h-3.5 inline-block ml-1","aria-hidden":"true"})]})})})()]},m.name)})}),g.jsx("p",{className:"text-center text-xs text-wm-muted font-mono mt-8",children:"Have a promo code? Enter it during checkout."})]})})}function c4(){return g.jsx("span",{style:{display:"inline-block",padding:"2px 8px",marginLeft:"6px",fontSize:"10px",fontWeight:600,letterSpacing:"0.04em",textTransform:"uppercase",color:"#fbbf24",background:"rgba(251,191,36,0.12)",border:"1px solid rgba(251,191,36,0.3)",borderRadius:"4px",verticalAlign:"middle"},children:_("soonBadge")})}const u4="/pro/assets/worldmonitor-7-mar-2026-CtI5YvxO.jpg",f4="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0.11%2010.99%20124.78%2024.98'%3e%3cpath%20d='M105.375%2014.875v17.25h8.5c2.375%200%203.75-.375%204.75-1.25%201.25-1.125%201.875-3.125%201.875-7.375s-.625-6.25-1.875-7.375c-1-.875-2.375-1.25-4.75-1.25zM117%2023.5c0%203.75-.25%204.625-1%205.125-.5.375-1.125.5-2.375.5h-4.75V17.75h4.75c1.25%200%201.875%200%202.375.5.75.625%201%201.5%201%205.25zm7.875%2012.438H99.937V11h24.938zM79.563%2017.75v-2.875h14.75v5.5h-3.126V17.75h-6v4.125h4.75v2.75h-4.75v4.625h6.126v-3h3.124v5.875H79.564V29.25h2.374v-11.5zM66.188%2027.625c0%201.875.124%203.25.374%204.375h3.376c-.126-.875-.25-2.5-.25-4.625-.126-2.5-.876-2.875-2.626-3.25%202-.375%202.876-1.25%202.876-4.375%200-2.5-.376-3.5-1.126-4.125-.5-.5-1.374-.75-2.75-.75h-10.5v17.25h3.5v-6.75h4.876c1%200%201.374.125%201.75.375s.5.625.5%201.875zm-7.126-5v-4.75h5.626c.75%200%201%20.125%201.124.25.25.25.5.625.5%202.125s-.25%202-.5%202.25c-.124.125-.374.25-1.124.25zm15.876%2013.313h-25V11h24.937v24.938zM43.438%2029.25v2.875H31.562V29.25h4.25v-11.5h-4.25v-2.875h11.875v2.875h-4.25v11.5zM23.375%2014.875h-3.25L17.75%2028.5%2015%2015.875c-.125-.875-.5-1-1.25-1H12c-.75%200-1.125.25-1.25%201L8%2028.5%205.625%2014.875h-3.5L5.5%2031.25c.125.75.375.875%201.25.875h2.375c.75%200%201-.125%201.25-.875L13%2019.375l2.625%2011.875c.125.75.375.875%201.25.875h2.25c.75%200%201.125-.125%201.25-.875zm1.75%2021.063h-25V11h24.938v24.938z'%3e%3c/path%3e%3c/svg%3e",LS="https://api.worldmonitor.app/api",d4="0x4AAAAAACnaYgHIyxclu8Tj";function h4(){if(!window.turnstile)return 0;let n=0;return document.querySelectorAll(".cf-turnstile:not([data-rendered])").forEach(t=>{const a=window.turnstile.render(t,{sitekey:d4,size:"flexible",callback:r=>{t.dataset.token=r},"expired-callback":()=>{delete t.dataset.token},"error-callback":()=>{delete t.dataset.token}});t.dataset.rendered="true",t.dataset.widgetId=String(a),n++}),n}function Hl(){return new URLSearchParams(window.location.search).get("ref")||void 0}const m4=/^[a-zA-Z0-9_-]+$/;function p4(n){return n.length>0&&n.length<=64&&m4.test(n)}function Xd(n,t){if(!t||!p4(t))return n;const a=n.includes("?")?"&":"?";return`${n}${a}wm_referral=${encodeURIComponent(t)}`}function zS(){ta().then(n=>n.openSignIn()).catch(n=>{console.error("[auth] Failed to open sign in:",n),Ji(n,{tags:{surface:"pro-marketing",action:"open-sign-in"}})})}function Uh(){const[n,t]=K.useState(null),[a,r]=K.useState(!1);return K.useEffect(()=>{let l=!0,c;return ta().then(f=>{l&&(t(f.user??null),r(!0),c=f.addListener(()=>{l&&t(f.user??null)}))}).catch(f=>{console.error("[auth] Failed to load Clerk for nav auth state:",f),Ji(f,{tags:{surface:"pro-marketing",action:"load-clerk-for-nav"}}),l&&r(!0)}),()=>{l=!1,c==null||c()}},[]),{user:n,isLoaded:a}}const VS=K.createContext({isPro:!1,isChecked:!1});function g4({children:n}){const{user:t}=Uh(),a=!!t,[r,l]=K.useState({isPro:!1,isChecked:!1});return K.useEffect(()=>{if(!a){l({isPro:!1,isChecked:!0});return}let c=!1;return(async()=>{var f,h;try{const m=await ta();let p=await((f=m.session)==null?void 0:f.getToken().catch(()=>null));if(p||(await new Promise(S=>setTimeout(S,2e3)),p=await((h=m.session)==null?void 0:h.getToken().catch(()=>null))),!p){c||l({isPro:!1,isChecked:!0});return}const v=await fetch(`${LS}/me/entitlement`,{headers:{Authorization:`Bearer ${p}`},signal:AbortSignal.timeout(8e3)});if(!v.ok){c||l({isPro:!1,isChecked:!0});return}const x=await v.json();c||l({isPro:x.isPro===!0,isChecked:!0})}catch(m){console.error("[auth] Failed to check pro entitlement:",m),Ji(m,{tags:{surface:"pro-marketing",action:"check-entitlement"}}),c||l({isPro:!1,isChecked:!0})}})(),()=>{c=!0}},[a]),g.jsx(VS.Provider,{value:r,children:n})}function BS(){return K.useContext(VS)}function y4(){const n=K.useRef(null);return K.useEffect(()=>{if(!n.current)return;const t=n.current;let a=!1;return ta().then(r=>{a||!t||r.mountUserButton(t,{afterSignOutUrl:"https://www.worldmonitor.app/pro"})}).catch(r=>{console.error("[auth] Failed to mount user button:",r),Ji(r,{tags:{surface:"pro-marketing",action:"mount-user-button"}})}),()=>{a=!0,ta().then(r=>{t&&r.unmountUserButton(t)}).catch(()=>{})}},[]),g.jsx("div",{ref:n,className:"flex items-center"})}const v4=()=>g.jsx("svg",{viewBox:"0 0 24 24",className:"w-5 h-5",fill:"currentColor","aria-hidden":"true",children:g.jsx("path",{d:"M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zM6.313 15.165a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313zM8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zM8.834 6.313a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312zM18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zM17.688 8.834a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.165 0a2.528 2.528 0 0 1 2.523 2.522v6.312zM15.165 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.165 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zM15.165 17.688a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.313A2.527 2.527 0 0 1 24 15.165a2.528 2.528 0 0 1-2.522 2.523h-6.313z"})}),US=()=>g.jsxs("a",{href:"https://worldmonitor.app",className:"flex items-center gap-2 hover:opacity-80 transition-opacity","aria-label":"World Monitor — Home",children:[g.jsxs("div",{className:"relative w-8 h-8 rounded-full bg-wm-card border border-wm-border flex items-center justify-center overflow-hidden",children:[g.jsx(kl,{className:"w-5 h-5 text-wm-blue opacity-50 absolute","aria-hidden":"true"}),g.jsx(T3,{className:"w-6 h-6 text-wm-green absolute z-10","aria-hidden":"true"})]}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] text-wm-muted font-mono uppercase tracking-widest leading-none mt-1",children:"by Someone.ceo"})]})]}),x4=()=>{const{user:n,isLoaded:t}=Uh(),{isPro:a,isChecked:r}=BS(),l=t&&!!n&&r&&a;return g.jsx("nav",{className:"fixed top-0 left-0 right-0 z-50 glass-panel border-b-0 border-x-0 rounded-none","aria-label":"Main navigation",children:g.jsxs("div",{className:"max-w-7xl mx-auto px-6 h-16 flex items-center justify-between",children:[g.jsx(US,{}),g.jsxs("div",{className:"hidden md:flex items-center gap-8 text-sm font-mono text-wm-muted",children:[g.jsx("a",{href:"#tiers",className:"hover:text-wm-text transition-colors",children:_("nav.free")}),g.jsx("a",{href:"#pro",className:"hover:text-wm-green transition-colors",children:_("nav.pro")}),g.jsx("a",{href:"#api",className:"hover:text-wm-text transition-colors",children:_("nav.api")}),g.jsx("a",{href:"#enterprise",className:"hover:text-wm-text transition-colors",children:_("nav.enterprise")})]}),g.jsxs("div",{className:"flex items-center gap-2",children:[t&&(n?g.jsx(y4,{}):g.jsx("button",{type:"button",onClick:zS,className:"border border-wm-border text-wm-text px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:border-wm-text transition-colors",children:_("nav.signIn")})),l?g.jsxs("a",{href:"https://worldmonitor.app",className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors inline-flex items-center gap-1.5",children:[_("nav.goToDashboard")," ",g.jsx(Hn,{className:"w-3 h-3","aria-hidden":"true"})]}):g.jsx("a",{href:"#pricing",className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("nav.upgradeToPro")})]})]})})},b4=()=>g.jsxs("a",{href:"https://www.wired.me/story/the-music-streaming-ceo-who-built-a-global-war-map",target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 px-3 py-1.5 rounded-full border border-wm-border bg-wm-card/50 text-wm-muted text-xs font-mono hover:border-wm-green/30 hover:text-wm-text transition-colors",children:[_("wired.asFeaturedIn")," ",g.jsx("span",{className:"text-wm-text font-bold",children:"WIRED"})," ",g.jsx(yS,{className:"w-3 h-3","aria-hidden":"true"})]}),S4=()=>g.jsxs("div",{className:"relative my-4 md:my-8 -mx-6",children:[g.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:g.jsx("div",{className:"w-64 h-40 md:w-96 md:h-56 bg-wm-green/8 rounded-full blur-[80px]"})}),g.jsx("div",{className:"flex items-end justify-center gap-[3px] md:gap-1 h-28 md:h-44 relative px-4","aria-hidden":"true",children:Array.from({length:60}).map((r,l)=>{const c=Math.abs(l-30),f=c<=8,h=f?1-c/8:0,m=60+h*110,p=Math.max(8,35-c*.8);return g.jsx(Za.div,{className:`flex-1 max-w-2 md:max-w-3 rounded-sm ${f?"bg-wm-green":"bg-wm-muted/20"}`,style:f?{boxShadow:`0 0 ${6+h*12}px rgba(74,222,128,${h*.5})`}:void 0,initial:{height:f?m*.3:p*.5,opacity:f?.4:.08},animate:f?{height:[m*.5,m,m*.65,m*.9],opacity:[.6+h*.3,1,.75+h*.2,.95]}:{height:[p,p*.3,p*.7,p*.15,p*.5],opacity:[.2,.06,.15,.04,.12]},transition:{duration:f?2.5+h*.5:1+Math.random()*.6,repeat:1/0,repeatType:"reverse",delay:f?c*.07:Math.random()*.6,ease:"easeInOut"}},l)})})]}),w4=()=>{const{user:n,isLoaded:t}=Uh(),{isPro:a,isChecked:r}=BS(),l=t&&!n,c=t&&!!n&&r&&a;return g.jsxs("section",{className:"pt-28 pb-12 px-6 relative overflow-hidden",children:[g.jsx("div",{className:"absolute inset-0 bg-[radial-gradient(circle_at_50%_20%,rgba(74,222,128,0.08)_0%,transparent_50%)] pointer-events-none"}),g.jsx("div",{className:"max-w-4xl mx-auto text-center relative z-10",children:g.jsxs(Za.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.6},children:[g.jsx("div",{className:"mb-4",children:g.jsx(b4,{})}),g.jsxs("h1",{className:"text-6xl md:text-8xl font-display font-bold tracking-tighter leading-[0.95]",children:[g.jsx("span",{className:"text-wm-muted/40",children:_("hero.noiseWord")}),g.jsx("span",{className:"mx-3 md:mx-5 text-wm-border/50",children:"→"}),g.jsx("span",{className:"text-transparent bg-clip-text bg-gradient-to-r from-wm-green to-emerald-300 text-glow",children:_("hero.signalWord")})]}),g.jsx(S4,{}),g.jsx("p",{className:"text-lg md:text-xl text-wm-muted max-w-xl mx-auto font-light leading-relaxed",children:_("hero.valueProps")}),g.jsxs("div",{className:"flex flex-col sm:flex-row gap-3 justify-center mt-8",children:[c?g.jsxs("a",{href:"https://worldmonitor.app",className:"bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors flex items-center justify-center gap-2",children:[_("hero.goToDashboard")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]}):g.jsxs("a",{href:"#pricing",className:"bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors flex items-center justify-center gap-2",children:[_("hero.choosePlan")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]}),l&&g.jsx("button",{type:"button",onClick:zS,className:"border border-wm-border text-wm-text px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:border-wm-text transition-colors",children:_("hero.signIn")})]}),g.jsx("div",{className:"flex items-center justify-center mt-4",children:g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),className:"text-xs text-wm-green font-mono hover:text-green-300 transition-colors flex items-center gap-1",children:[_("hero.tryFreeDashboard")," ",g.jsx(Hn,{className:"w-3 h-3","aria-hidden":"true"})]})})]})})]})},_4=()=>g.jsx("section",{className:"border-y border-wm-border bg-wm-card/30 py-16 px-6",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-8 text-center mb-12",children:[{value:"2M+",label:_("socialProof.uniqueVisitors")},{value:"421K",label:_("socialProof.peakDailyUsers")},{value:"190+",label:_("socialProof.countriesReached")},{value:"500+",label:_("socialProof.liveDataSources")}].map((n,t)=>g.jsxs("div",{children:[g.jsx("p",{className:"text-3xl md:text-4xl font-display font-bold text-wm-green",children:n.value}),g.jsx("p",{className:"text-xs font-mono text-wm-muted uppercase tracking-widest mt-1",children:n.label})]},t))}),g.jsxs("blockquote",{className:"max-w-3xl mx-auto text-center",children:[g.jsxs("p",{className:"text-lg md:text-xl text-wm-muted italic leading-relaxed",children:['"',_("socialProof.quote"),'"']}),g.jsx("footer",{className:"mt-6 flex items-center justify-center gap-3",children:g.jsx("a",{href:"https://www.wired.me/story/the-music-streaming-ceo-who-built-a-global-war-map",target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 text-wm-muted hover:text-wm-text transition-colors",children:g.jsx("img",{src:f4,alt:"WIRED",className:"h-5 brightness-0 invert opacity-60 hover:opacity-100 transition-opacity"})})})]})]})}),T4=()=>g.jsxs("section",{className:"py-24 px-6 max-w-5xl mx-auto",id:"tiers",children:[g.jsx("h2",{className:"sr-only",children:"Plans"}),g.jsxs("div",{className:"grid md:grid-cols-2 gap-8",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-green p-8 relative border-glow",children:[g.jsx("div",{className:"absolute top-0 left-0 w-full h-1 bg-wm-green"}),g.jsx("h3",{className:"font-display text-2xl font-bold mb-2",children:_("twoPath.proTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-6",children:_("twoPath.proDesc")}),g.jsx("ul",{className:"space-y-3 mb-8",children:[_("twoPath.proF1"),_("twoPath.proF2"),_("twoPath.proF3"),_("twoPath.proF4"),_("twoPath.proF5"),_("twoPath.proF6"),_("twoPath.proF7"),_("twoPath.proF8"),_("twoPath.proF9")].map((n,t)=>g.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[g.jsx(Fd,{className:"w-4 h-4 shrink-0 mt-0.5 text-wm-green","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:n})]},t))}),g.jsx("a",{href:"#pricing",className:"block text-center py-2.5 rounded-sm font-mono text-xs uppercase tracking-wider font-bold bg-wm-green text-wm-bg hover:bg-green-400 transition-colors",children:_("twoPath.choosePlan")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-8",children:[g.jsx("h3",{className:"font-display text-2xl font-bold mb-2",children:_("twoPath.entTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-6",children:_("twoPath.entDesc")}),g.jsxs("ul",{className:"space-y-3 mb-8",children:[g.jsx("li",{className:"text-xs font-mono text-wm-green uppercase tracking-wider mb-1",children:_("twoPath.entF1")}),[_("twoPath.entF2"),_("twoPath.entF3"),_("twoPath.entF4"),_("twoPath.entF5"),_("twoPath.entF6"),_("twoPath.entF7"),_("twoPath.entF8"),_("twoPath.entF9"),_("twoPath.entF10"),_("twoPath.entF11")].map((n,t)=>g.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[g.jsx(Fd,{className:"w-4 h-4 shrink-0 mt-0.5 text-wm-muted","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:n})]},t))]}),g.jsx("a",{href:"#enterprise",className:"block text-center py-2.5 rounded-sm font-mono text-xs uppercase tracking-wider font-bold border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text transition-colors",children:_("twoPath.entCta")})]})]})]}),E4=()=>{const n=[{icon:g.jsx(K3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.noiseTitle"),desc:_("whyUpgrade.noiseDesc")},{icon:g.jsx(SS,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.fasterTitle"),desc:_("whyUpgrade.fasterDesc")},{icon:g.jsx(vO,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.controlTitle"),desc:_("whyUpgrade.controlDesc")},{icon:g.jsx(bS,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.deeperTitle"),desc:_("whyUpgrade.deeperDesc")}];return g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/20",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-16 text-center",children:_("whyUpgrade.title")}),g.jsx("div",{className:"grid md:grid-cols-2 gap-8",children:n.map((t,a)=>g.jsxs("div",{className:"flex gap-5",children:[g.jsx("div",{className:"text-wm-green shrink-0 mt-1",children:t.icon}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold text-lg mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted leading-relaxed",children:t.desc})]})]},a))})]})})},A4=()=>{const n=[{icon:g.jsx(C3,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.askIt"),desc:_("pillars.askItDesc")},{icon:g.jsx(N3,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.subscribeIt"),desc:_("pillars.subscribeItDesc")},{icon:g.jsx(nc,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.buildOnIt"),desc:_("pillars.buildOnItDesc")}];return g.jsx("section",{className:"py-20 px-6 border-t border-wm-border",children:g.jsx("div",{className:"max-w-5xl mx-auto",children:g.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6 hover:border-wm-green/30 transition-colors",children:[g.jsx("div",{className:"text-wm-green mb-4",children:t.icon}),g.jsx("h3",{className:"font-display text-xl font-bold mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted leading-relaxed",children:t.desc})]},a))})})})},N4=()=>g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/20",children:g.jsxs("div",{className:"max-w-4xl mx-auto text-center",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-green/30 bg-wm-green/10 text-wm-green text-xs font-mono mb-6",children:_("deliveryDesk.eyebrow")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("deliveryDesk.title")}),g.jsx("p",{className:"text-lg text-wm-muted leading-relaxed mb-6",children:_("deliveryDesk.body")}),g.jsx("p",{className:"text-xl md:text-2xl font-display font-bold text-wm-green mb-8",children:_("deliveryDesk.closer")}),g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest",children:_("deliveryDesk.channels")})]})}),D4=()=>g.jsx("section",{className:"px-6 py-16",children:g.jsxs("div",{className:"max-w-6xl mx-auto",children:[g.jsxs("div",{className:"relative rounded-lg overflow-hidden border border-wm-border shadow-2xl shadow-wm-green/5",children:[g.jsxs("div",{className:"bg-wm-card px-4 py-2 border-b border-wm-border flex items-center gap-3",children:[g.jsxs("div",{className:"flex gap-1.5",children:[g.jsx("div",{className:"w-3 h-3 rounded-full bg-red-500/70"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-yellow-500/70"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-green-500/70"})]}),g.jsx("span",{className:"font-mono text-xs text-wm-muted ml-2",children:_("livePreview.windowTitle")}),g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),target:"_blank",rel:"noreferrer",className:"ml-auto text-xs text-wm-green font-mono hover:text-green-300 transition-colors flex items-center gap-1",children:[_("livePreview.openFullScreen")," ",g.jsx(yS,{className:"w-3 h-3","aria-hidden":"true"})]})]}),g.jsxs("div",{className:"relative aspect-[16/9] bg-black",children:[g.jsx("img",{src:u4,alt:"World Monitor Dashboard",className:"absolute inset-0 w-full h-full object-cover"}),g.jsx("iframe",{src:"https://worldmonitor.app?embed=pro-preview",title:_("livePreview.iframeTitle"),className:"relative w-full h-full border-0",loading:"lazy",sandbox:"allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"}),g.jsx("div",{className:"absolute inset-0 pointer-events-none bg-gradient-to-t from-wm-bg/80 via-transparent to-transparent"}),g.jsx("div",{className:"absolute bottom-4 left-0 right-0 text-center pointer-events-auto",children:g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("livePreview.tryLiveDashboard")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})})]})]}),g.jsx("p",{className:"text-center text-xs text-wm-muted font-mono mt-4",children:_("livePreview.description")})]})}),C4=()=>{const t=["Finnhub","FRED","Bloomberg","CNBC","Nikkei","CoinGecko","Polymarket","Reuters","ACLED","UCDP","GDELT","NASA FIRMS","USGS","OpenSky","AISStream","Cloudflare Radar","BGPStream","GPSJam","NOAA","Copernicus","IAEA","Al Jazeera","Sky News","Euronews","DW News","France 24","OilPrice","Rigzone","Maritime Executive","Hellenic Shipping News","Defense One","Jane's","The War Zone","TechCrunch","Ars Technica","The Verge","Wired","Krebs on Security","BleepingComputer","The Record"].join(" · ");return g.jsx("section",{className:"border-y border-wm-border bg-wm-card/20 overflow-hidden py-4","aria-label":"Data sources",children:g.jsxs("div",{className:"marquee-track whitespace-nowrap font-mono text-xs text-wm-muted uppercase tracking-widest",children:[g.jsxs("span",{className:"inline-block px-4",children:[t," · "]}),g.jsxs("span",{className:"inline-block px-4",children:[t," · "]})]})})},j4=()=>g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/30",id:"pro",children:g.jsxs("div",{className:"max-w-7xl mx-auto grid lg:grid-cols-2 gap-16 items-start",children:[g.jsxs("div",{children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-green/30 bg-wm-green/10 text-wm-green text-xs font-mono mb-6",children:_("proShowcase.proTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("proShowcase.title")}),g.jsx("p",{className:"text-wm-muted mb-8",children:_("proShowcase.subtitle")}),g.jsxs("div",{className:"space-y-6",children:[g.jsxs("div",{className:"flex gap-4",children:[g.jsx(SS,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.equityResearch")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.equityResearchDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(kl,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.geopoliticalAnalysis")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.geopoliticalAnalysisDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Vh,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.economyAnalytics")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.economyAnalyticsDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Bh,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.riskMonitoring")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.riskMonitoringDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(bS,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsxs("h4",{className:"font-bold mb-1",children:[_("proShowcase.orbitalSurveillance"),g.jsx(c4,{})]}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.orbitalSurveillanceDesc").replace(/^\(Soon\)\s*/,"")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(U3,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.morningBriefs")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.morningBriefsDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Z3,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.oneKey")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.oneKeyDesc")})]})]})]}),g.jsxs("div",{className:"mt-10 pt-8 border-t border-wm-border",children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-4",children:_("proShowcase.deliveryLabel")}),g.jsx("div",{className:"flex gap-6",children:[{icon:g.jsx(v4,{}),label:"Slack"},{icon:g.jsx(oO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Discord"},{icon:g.jsx(hO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Telegram"},{icon:g.jsx(sO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Email"},{icon:g.jsx(nc,{className:"w-5 h-5","aria-hidden":"true"}),label:"Webhook"}].map((n,t)=>g.jsxs("div",{className:"flex flex-col items-center gap-1.5 text-wm-muted hover:text-wm-text transition-colors cursor-pointer",children:[n.icon,g.jsx("span",{className:"text-[10px] font-mono",children:n.label})]},t))})]})]}),g.jsxs("div",{className:"bg-[#1a1d21] rounded-lg border border-[#35373b] overflow-hidden shadow-2xl sticky top-24",children:[g.jsxs("div",{className:"bg-[#222529] px-4 py-3 border-b border-[#35373b] flex items-center gap-3",children:[g.jsx("div",{className:"w-3 h-3 rounded-full bg-red-500"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-yellow-500"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-green-500"}),g.jsx("span",{className:"ml-2 font-mono text-xs text-gray-400",children:"#world-monitor-alerts"})]}),g.jsx("div",{className:"p-6 space-y-6 font-sans text-sm",children:g.jsxs("div",{className:"flex gap-4",children:[g.jsx("div",{className:"w-10 h-10 rounded bg-wm-green/20 flex items-center justify-center shrink-0",children:g.jsx(kl,{className:"w-6 h-6 text-wm-green","aria-hidden":"true"})}),g.jsxs("div",{children:[g.jsxs("div",{className:"flex items-baseline gap-2 mb-1",children:[g.jsx("span",{className:"font-bold text-gray-200",children:"World Monitor"}),g.jsx("span",{className:"text-xs text-gray-500 bg-gray-800 px-1 rounded",children:"APP"}),g.jsx("span",{className:"text-xs text-gray-500",children:"8:00 AM"})]}),g.jsxs("p",{className:"text-gray-300 font-bold mb-3",children:[_("slackMock.morningBrief")," · Mar 6"]}),g.jsxs("div",{className:"space-y-3",children:[g.jsxs("div",{className:"pl-3 border-l-2 border-blue-500",children:[g.jsx("span",{className:"text-blue-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.markets")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.marketsText")})]}),g.jsxs("div",{className:"pl-3 border-l-2 border-orange-500",children:[g.jsx("span",{className:"text-orange-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.elevated")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.elevatedText")})]}),g.jsxs("div",{className:"pl-3 border-l-2 border-yellow-500",children:[g.jsx("span",{className:"text-yellow-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.watch")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.watchText")})]})]})]})]})})]})]})}),M4=()=>{const n=[{icon:g.jsx(k3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.investorsTitle"),desc:_("audience.investorsDesc")},{icon:g.jsx(G3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.tradersTitle"),desc:_("audience.tradersDesc")},{icon:g.jsx(fO,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.researchersTitle"),desc:_("audience.researchersDesc")},{icon:g.jsx(kl,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.journalistsTitle"),desc:_("audience.journalistsDesc")},{icon:g.jsx(W3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.govTitle"),desc:_("audience.govDesc")},{icon:g.jsx(M3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.teamsTitle"),desc:_("audience.teamsDesc")}];return g.jsx("section",{className:"py-24 px-6",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-16 text-center",children:_("audience.title")}),g.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6 hover:border-wm-green/30 transition-colors",children:[g.jsx("div",{className:"text-wm-green mb-4",children:t.icon}),g.jsx("h3",{className:"font-bold mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted",children:t.desc})]},a))})]})})},O4=()=>g.jsx("section",{className:"py-24 px-6 border-y border-wm-border bg-[#0a0a0a]",id:"api",children:g.jsxs("div",{className:"max-w-7xl mx-auto grid lg:grid-cols-2 gap-16 items-center",children:[g.jsx("div",{className:"order-2 lg:order-1",children:g.jsxs("div",{className:"bg-black border border-wm-border rounded-lg overflow-hidden font-mono text-sm",children:[g.jsxs("div",{className:"bg-wm-card px-4 py-2 border-b border-wm-border flex items-center gap-2",children:[g.jsx(SO,{className:"w-4 h-4 text-wm-muted","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted text-xs",children:"api.worldmonitor.app"})]}),g.jsx("div",{className:"p-6 text-gray-300 overflow-x-auto",children:g.jsx("pre",{children:g.jsxs("code",{children:[g.jsx("span",{className:"text-wm-blue",children:"curl"})," \\",g.jsx("br",{}),g.jsx("span",{className:"text-wm-green",children:'"https://api.worldmonitor.app/v1/intelligence/convergence?region=MENA&time_window=6h"'})," \\",g.jsx("br",{}),"-H ",g.jsx("span",{className:"text-wm-green",children:'"Authorization: Bearer wm_live_xxx"'}),g.jsx("br",{}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"{"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"status"'}),": ",g.jsx("span",{className:"text-wm-green",children:'"success"'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"data"'}),": ",g.jsx("span",{className:"text-wm-muted",children:"["}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"{"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"type"'}),": ",g.jsx("span",{className:"text-wm-green",children:'"multi_signal_convergence"'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"signals"'}),": ",g.jsx("span",{className:"text-wm-muted",children:'["military_flights", "ais_dark_ships", "oref_sirens"]'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"confidence"'}),": ",g.jsx("span",{className:"text-orange-400",children:"0.92"}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"location"'}),": ",g.jsx("span",{className:"text-wm-muted",children:"{"})," ",g.jsx("span",{className:"text-wm-blue",children:'"lat"'}),": ",g.jsx("span",{className:"text-orange-400",children:"34.05"}),", ",g.jsx("span",{className:"text-wm-blue",children:'"lng"'}),": ",g.jsx("span",{className:"text-orange-400",children:"35.12"})," ",g.jsx("span",{className:"text-wm-muted",children:"}"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"}"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"]"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"}"})]})})})]})}),g.jsxs("div",{className:"order-1 lg:order-2",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("apiSection.apiTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("apiSection.title")}),g.jsx("p",{className:"text-wm-muted mb-8",children:_("apiSection.subtitle")}),g.jsxs("ul",{className:"space-y-4 mb-8",children:[g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(pO,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.restApi")})]}),g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(iO,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.authenticated")})]}),g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(I3,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.structured")})]})]}),g.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-8 p-4 bg-wm-card border border-wm-border rounded-sm",children:[g.jsxs("div",{children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("apiSection.starter")}),g.jsx("p",{className:"text-sm font-bold",children:_("apiSection.starterReqs")}),g.jsx("p",{className:"text-xs text-wm-muted",children:_("apiSection.starterWebhooks")})]}),g.jsxs("div",{children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("apiSection.business")}),g.jsx("p",{className:"text-sm font-bold",children:_("apiSection.businessReqs")}),g.jsx("p",{className:"text-xs text-wm-muted",children:_("apiSection.businessWebhooks")})]})]}),g.jsx("p",{className:"text-sm text-wm-muted border-l-2 border-wm-border pl-4",children:_("apiSection.feedData")})]})]})}),R4=()=>g.jsx("section",{className:"py-24 px-6",id:"enterprise",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsxs("div",{className:"text-center mb-16",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("enterpriseShowcase.enterpriseTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("enterpriseShowcase.title")}),g.jsx("p",{className:"text-wm-muted max-w-2xl mx-auto",children:_("enterpriseShowcase.subtitle")})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-6",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Bh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.security")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.securityDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(gS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.aiAgents")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.aiAgentsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(vS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.dataLayers")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.dataLayersDesc")})]})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-12",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(nc,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.connectors")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.connectorsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(xS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.whiteLabel")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.whiteLabelDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Vh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.financial")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.financialDesc")})]})]}),g.jsxs("div",{className:"data-grid mb-12",children:[g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.commodity")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.commodityDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.government")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.governmentDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.risk")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.riskDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.soc")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.socDesc")})]})]}),g.jsx("div",{className:"text-center mt-12",children:g.jsxs("a",{href:"#enterprise-contact","aria-label":"Talk to sales about Enterprise plans",className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-8 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("enterpriseShowcase.talkToSales")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})})]})}),k4=()=>{const n=[{feature:_("pricingTable.dataRefresh"),free:_("pricingTable.f5_15min"),pro:_("pricingTable.fLt60s"),api:_("pricingTable.fPerRequest"),ent:_("pricingTable.fLiveEdge")},{feature:_("pricingTable.dashboard"),free:_("pricingTable.f50panels"),pro:_("pricingTable.f50panels"),api:"—",ent:_("pricingTable.fWhiteLabel")},{feature:_("pricingTable.ai"),free:_("pricingTable.fBYOK"),pro:_("pricingTable.fIncluded"),api:"—",ent:_("pricingTable.fAgentsPersonas")},{feature:_("pricingTable.briefsAlerts"),free:"—",pro:_("pricingTable.fDailyFlash"),api:"—",ent:_("pricingTable.fTeamDist")},{feature:_("pricingTable.delivery"),free:"—",pro:_("pricingTable.fSlackTgWa"),api:_("pricingTable.fWebhook"),ent:_("pricingTable.fSiemMcp")},{feature:_("pricingTable.apiRow"),free:"—",pro:"—",api:_("pricingTable.fRestWebhook"),ent:_("pricingTable.fMcpBulk")},{feature:_("pricingTable.infraLayers"),free:_("pricingTable.f45"),pro:_("pricingTable.f45"),api:"—",ent:_("pricingTable.fTensOfThousands")},{feature:_("pricingTable.satellite"),free:_("pricingTable.fLiveTracking"),pro:_("pricingTable.fPassAlerts"),api:"—",ent:_("pricingTable.fImagerySar")},{feature:_("pricingTable.connectorsRow"),free:"—",pro:"—",api:"—",ent:_("pricingTable.f100plus")},{feature:_("pricingTable.deployment"),free:_("pricingTable.fCloud"),pro:_("pricingTable.fCloud"),api:_("pricingTable.fCloud"),ent:_("pricingTable.fCloudOnPrem")},{feature:_("pricingTable.securityRow"),free:_("pricingTable.fStandard"),pro:_("pricingTable.fStandard"),api:_("pricingTable.fKeyAuth"),ent:_("pricingTable.fSsoMfa")}];return g.jsxs("section",{className:"py-24 px-6 max-w-7xl mx-auto",children:[g.jsx("div",{className:"text-center mb-16",children:g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("pricingTable.title")})}),g.jsxs("div",{className:"hidden md:block",children:[g.jsxs("div",{className:"grid grid-cols-5 gap-4 mb-4 pb-4 border-b border-wm-border font-mono text-xs uppercase tracking-widest text-wm-muted",children:[g.jsx("div",{children:_("pricingTable.feature")}),g.jsx("div",{children:_("pricingTable.freeHeader")}),g.jsx("div",{className:"text-wm-green",children:_("pricingTable.proHeader")}),g.jsx("div",{children:_("pricingTable.apiHeader")}),g.jsx("div",{children:_("pricingTable.entHeader")})]}),n.map((t,a)=>g.jsxs("div",{className:"grid grid-cols-5 gap-4 py-4 border-b border-wm-border/50 text-sm hover:bg-wm-card/50 transition-colors",children:[g.jsx("div",{className:"font-medium",children:t.feature}),g.jsx("div",{className:"text-wm-muted",children:t.free}),g.jsx("div",{className:"text-wm-green",children:t.pro}),g.jsx("div",{className:"text-wm-muted",children:t.api}),g.jsx("div",{className:"text-wm-muted",children:t.ent})]},a))]}),g.jsx("div",{className:"md:hidden space-y-4",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-4 rounded-sm",children:[g.jsx("p",{className:"font-medium text-sm mb-3",children:t.feature}),g.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs",children:[g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("tiers.free"),":"]})," ",t.free]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-green",children:[_("tiers.pro"),":"]})," ",g.jsx("span",{className:"text-wm-green",children:t.pro})]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("nav.api"),":"]})," ",t.api]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("tiers.enterprise"),":"]})," ",t.ent]})]})]},a))}),g.jsx("p",{className:"text-center text-sm text-wm-muted mt-8",children:_("pricingTable.noteBelow")})]})},L4=()=>{const n=[{q:_("faq.q1"),a:_("faq.a1"),open:!0},{q:_("faq.q2"),a:_("faq.a2")},{q:_("faq.q3"),a:_("faq.a3")},{q:_("faq.q4"),a:_("faq.a4")},{q:_("faq.q5"),a:_("faq.a5")},{q:_("faq.q6"),a:_("faq.a6")},{q:_("faq.q7"),a:_("faq.a7")},{q:_("faq.q8"),a:_("faq.a8")},{q:_("faq.q9"),a:_("faq.a9")},{q:_("faq.q10"),a:_("faq.a10")},{q:_("faq.q11"),a:_("faq.a11")},{q:_("faq.q12"),a:_("faq.a12")},{q:_("faq.q13"),a:_("faq.a13")}];return g.jsxs("section",{className:"py-24 px-6 max-w-3xl mx-auto",children:[g.jsx("h2",{className:"text-3xl font-display font-bold mb-12 text-center",children:_("faq.title")}),g.jsx("div",{className:"space-y-4",children:n.map((t,a)=>g.jsxs("details",{open:t.open,className:"group bg-wm-card border border-wm-border rounded-sm [&_summary::-webkit-details-marker]:hidden",children:[g.jsxs("summary",{className:"flex items-center justify-between p-6 cursor-pointer font-medium",children:[t.q,g.jsx(V3,{className:"w-5 h-5 text-wm-muted group-open:rotate-180 transition-transform","aria-hidden":"true"})]}),g.jsx("div",{className:"px-6 pb-6 text-wm-muted text-sm border-t border-wm-border pt-4 mt-2",children:t.a})]},a))})]})},z4=()=>g.jsx("footer",{className:"border-t border-wm-border bg-[#020202] pt-8 pb-12 px-6 text-center",children:g.jsxs("div",{className:"flex flex-col md:flex-row items-center justify-between max-w-7xl mx-auto text-xs text-wm-muted font-mono",children:[g.jsxs("div",{className:"flex items-center gap-3 mb-4 md:mb-0",children:[g.jsx("img",{src:"/favico/favicon-32x32.png",alt:"",width:"28",height:"28",className:"rounded-full"}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight text-wm-text",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] uppercase tracking-[2px] opacity-60 mt-0.5",children:"by Someone.ceo"})]})]}),g.jsxs("div",{className:"flex items-center gap-6",children:[g.jsx("a",{href:"/",className:"hover:text-wm-text transition-colors",children:"Dashboard"}),g.jsx("a",{href:"https://www.worldmonitor.app/blog/",className:"hover:text-wm-text transition-colors",children:"Blog"}),g.jsx("a",{href:"https://www.worldmonitor.app/docs",className:"hover:text-wm-text transition-colors",children:"Docs"}),g.jsx("a",{href:"https://status.worldmonitor.app/",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Status"}),g.jsx("a",{href:"https://github.com/koala73/worldmonitor",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"GitHub"}),g.jsx("a",{href:"https://discord.gg/re63kWKxaz",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Discord"}),g.jsx("a",{href:"https://x.com/worldmonitorai",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"X"})]}),g.jsxs("span",{className:"text-[10px] opacity-40 mt-4 md:mt-0",children:["© ",new Date().getFullYear()," WorldMonitor"]})]})}),V4=()=>g.jsxs("div",{className:"min-h-screen selection:bg-wm-green/30 selection:text-wm-green",children:[g.jsx("nav",{className:"fixed top-0 left-0 right-0 z-50 glass-panel border-b-0 border-x-0 rounded-none","aria-label":"Main navigation",children:g.jsxs("div",{className:"max-w-7xl mx-auto px-6 h-16 flex items-center justify-between",children:[g.jsx("a",{href:"#",onClick:n=>{n.preventDefault(),window.location.hash=""},children:g.jsx(US,{})}),g.jsxs("div",{className:"hidden md:flex items-center gap-8 text-sm font-mono text-wm-muted",children:[g.jsx("a",{href:"#",onClick:n=>{n.preventDefault(),window.location.hash=""},className:"hover:text-wm-text transition-colors",children:_("nav.pro")}),g.jsx("a",{href:"#enterprise",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("features"))==null||t.scrollIntoView({behavior:"smooth"})},className:"hover:text-wm-text transition-colors",children:_("nav.enterprise")}),g.jsx("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"hover:text-wm-green transition-colors",children:_("enterpriseShowcase.talkToSales")})]}),g.jsx("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("enterpriseShowcase.talkToSales")})]})}),g.jsxs("main",{className:"pt-24",children:[g.jsx("section",{className:"py-24 px-6 text-center",children:g.jsxs("div",{className:"max-w-4xl mx-auto",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("enterpriseShowcase.enterpriseTier")}),g.jsx("h2",{className:"text-4xl md:text-6xl font-display font-bold mb-6",children:_("enterpriseShowcase.title")}),g.jsx("p",{className:"text-lg text-wm-muted max-w-2xl mx-auto mb-10",children:_("enterpriseShowcase.subtitle")}),g.jsxs("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-8 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("enterpriseShowcase.talkToSales")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})]})}),g.jsx("section",{className:"py-24 px-6",id:"features",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsx("h2",{className:"sr-only",children:"Enterprise Features"}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-6",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Bh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.security")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.securityDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(gS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.aiAgents")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.aiAgentsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(vS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.dataLayers")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.dataLayersDesc")})]})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-12",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(nc,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.connectors")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.connectorsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(xS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.whiteLabel")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.whiteLabelDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Vh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.financial")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.financialDesc")})]})]})]})}),g.jsx("section",{className:"py-24 px-6 border-t border-wm-border",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsx("h2",{className:"text-3xl font-display font-bold mb-12 text-center",children:_("enterpriseShowcase.title")}),g.jsxs("div",{className:"data-grid",children:[g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.commodity")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.commodityDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.government")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.governmentDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.risk")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.riskDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.soc")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.socDesc")})]})]})]})}),g.jsx("section",{className:"py-24 px-6 border-t border-wm-border",id:"contact",children:g.jsxs("div",{className:"max-w-xl mx-auto",children:[g.jsx("h2",{className:"font-display text-3xl font-bold mb-2 text-center",children:_("enterpriseShowcase.contactFormTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-10 text-center",children:_("enterpriseShowcase.contactFormSubtitle")}),g.jsxs("form",{className:"space-y-4",onSubmit:async n=>{var m;n.preventDefault();const t=n.currentTarget,a=t.querySelector('button[type="submit"]'),r=a.textContent;a.disabled=!0,a.textContent=_("enterpriseShowcase.contactSending");const l=new FormData(t),c=((m=t.querySelector('input[name="website"]'))==null?void 0:m.value)||"",f=t.querySelector(".cf-turnstile"),h=(f==null?void 0:f.dataset.token)||"";try{const p=await fetch(`${LS}/leads/v1/submit-contact`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:l.get("email"),name:l.get("name"),organization:l.get("organization"),phone:l.get("phone"),message:l.get("message"),source:"enterprise-contact",website:c,turnstileToken:h})}),v=t.querySelector("[data-form-error]");if(!p.ok){const x=await p.json().catch(()=>({}));if(p.status===422&&v){v.textContent=x.message||x.error||_("enterpriseShowcase.workEmailRequired"),v.classList.remove("hidden"),a.textContent=r,a.disabled=!1;return}throw new Error}v&&v.classList.add("hidden"),a.textContent=_("enterpriseShowcase.contactSent"),a.className=a.className.replace("bg-wm-green","bg-wm-card border border-wm-green text-wm-green")}catch{a.textContent=_("enterpriseShowcase.contactFailed"),a.disabled=!1,f!=null&&f.dataset.widgetId&&window.turnstile&&(window.turnstile.reset(f.dataset.widgetId),delete f.dataset.token),setTimeout(()=>{a.textContent=r},4e3)}},children:[g.jsx("input",{type:"text",name:"website",autoComplete:"off",tabIndex:-1,"aria-hidden":"true",className:"absolute opacity-0 h-0 w-0 pointer-events-none"}),g.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[g.jsx("input",{type:"text",name:"name",placeholder:_("enterpriseShowcase.namePlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"}),g.jsx("input",{type:"email",name:"email",placeholder:_("enterpriseShowcase.emailPlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"})]}),g.jsx("span",{"data-form-error":!0,className:"hidden text-red-400 text-xs font-mono block"}),g.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[g.jsx("input",{type:"text",name:"organization",placeholder:_("enterpriseShowcase.orgPlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"}),g.jsx("input",{type:"tel",name:"phone",placeholder:_("enterpriseShowcase.phonePlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"})]}),g.jsx("textarea",{name:"message",placeholder:_("enterpriseShowcase.messagePlaceholder"),rows:4,className:"w-full bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono resize-none"}),g.jsx("div",{className:"cf-turnstile mx-auto"}),g.jsx("button",{type:"submit",className:"w-full bg-wm-green text-wm-bg py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("enterpriseShowcase.submitContact")})]})]})})]}),g.jsx("footer",{className:"border-t border-wm-border bg-[#020202] py-8 px-6 text-center",children:g.jsxs("div",{className:"flex flex-col md:flex-row items-center justify-between max-w-7xl mx-auto text-xs text-wm-muted font-mono",children:[g.jsxs("div",{className:"flex items-center gap-3 mb-4 md:mb-0",children:[g.jsx("img",{src:"/favico/favicon-32x32.png",alt:"",width:"28",height:"28",className:"rounded-full"}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight text-wm-text",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] uppercase tracking-[2px] opacity-60 mt-0.5",children:"by Someone.ceo"})]})]}),g.jsxs("div",{className:"flex items-center gap-6",children:[g.jsx("a",{href:"/",className:"hover:text-wm-text transition-colors",children:"Dashboard"}),g.jsx("a",{href:"https://www.worldmonitor.app/blog/",className:"hover:text-wm-text transition-colors",children:"Blog"}),g.jsx("a",{href:"https://www.worldmonitor.app/docs",className:"hover:text-wm-text transition-colors",children:"Docs"}),g.jsx("a",{href:"https://status.worldmonitor.app/",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Status"}),g.jsx("a",{href:"https://github.com/koala73/worldmonitor",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"GitHub"}),g.jsx("a",{href:"https://discord.gg/re63kWKxaz",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Discord"}),g.jsx("a",{href:"https://x.com/worldmonitorai",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"X"})]}),g.jsxs("span",{className:"text-[10px] opacity-40 mt-4 md:mt-0",children:["© ",new Date().getFullYear()," WorldMonitor"]})]})})]});function B4(){const[n,t]=K.useState(()=>window.location.hash.startsWith("#enterprise")?"enterprise":"home");return K.useEffect(()=>{GR(()=>{const a=document.createElement("div");Object.assign(a.style,{position:"fixed",top:"0",left:"0",right:"0",zIndex:"99999",padding:"14px 20px",background:"linear-gradient(135deg, #16a34a, #22c55e)",color:"#fff",fontWeight:"600",fontSize:"14px",textAlign:"center",boxShadow:"0 2px 12px rgba(0,0,0,0.3)",transition:"opacity 0.4s ease, transform 0.4s ease",transform:"translateY(-100%)",opacity:"0",display:"flex",alignItems:"center",justifyContent:"center",gap:"14px"});const r="https://worldmonitor.app/?wm_checkout=success";let l=!1;const c=()=>{l||(l=!0,window.location.href=r)},f=document.createElement("span");f.textContent="Payment received! Unlocking your premium features…";const h=document.createElement("button");h.type="button",h.textContent="Go to dashboard now →",Object.assign(h.style,{background:"#ffffff",color:"#16a34a",border:"none",borderRadius:"4px",padding:"6px 12px",fontSize:"12px",fontWeight:"700",cursor:"pointer",whiteSpace:"nowrap"}),h.addEventListener("click",c),a.appendChild(f),a.appendChild(h),document.body.appendChild(a),requestAnimationFrame(()=>{a.style.transform="translateY(0)",a.style.opacity="1"}),setTimeout(c,1500)}),KR()},[]),K.useEffect(()=>{const a=()=>{const r=window.location.hash,l=r.startsWith("#enterprise")?"enterprise":"home",c=n==="enterprise";t(l),l==="enterprise"&&!c&&window.scrollTo(0,0),r==="#enterprise-contact"&&setTimeout(()=>{var f;(f=document.getElementById("contact"))==null||f.scrollIntoView({behavior:"smooth"})},c?0:100)};return window.addEventListener("hashchange",a),()=>window.removeEventListener("hashchange",a)},[n]),K.useEffect(()=>{n==="enterprise"&&window.location.hash==="#enterprise-contact"&&setTimeout(()=>{var a;(a=document.getElementById("contact"))==null||a.scrollIntoView({behavior:"smooth"})},100)},[]),n==="enterprise"?g.jsx(V4,{}):g.jsx(g4,{children:g.jsxs("div",{className:"min-h-screen selection:bg-wm-green/30 selection:text-wm-green",children:[g.jsx(x4,{}),g.jsxs("main",{children:[g.jsx(w4,{}),g.jsx(C4,{}),g.jsx(A4,{}),g.jsx(E4,{}),g.jsx(T4,{}),g.jsx(j4,{}),g.jsx(N4,{}),g.jsx(M4,{}),g.jsx(_4,{}),g.jsx(D4,{}),g.jsx(l4,{refCode:Hl()}),g.jsx(k4,{}),g.jsx(O4,{}),g.jsx(R4,{}),g.jsx(L4,{})]}),g.jsx(z4,{})]})})}const U4=void 0;mD({dsn:void 0,environment:location.hostname==="worldmonitor.app"||location.hostname.endsWith(".worldmonitor.app")?"production":location.hostname.includes("vercel.app")?"preview":"development",enabled:!!U4&&!location.hostname.startsWith("localhost"),allowUrls:[/https?:\/\/(www\.|tech\.|finance\.|commodity\.|happy\.)?worldmonitor\.app/,/https?:\/\/.*\.vercel\.app/],tracesSampleRate:.1,ignoreErrors:[/ResizeObserver loop/,/^TypeError: Load failed/,/^TypeError: Failed to fetch/,/^TypeError: NetworkError/,/Non-Error promise rejection captured with value:/]});const P4='script[src^="https://challenges.cloudflare.com/turnstile/v0/api.js"]';BR().then(()=>{SD.createRoot(document.getElementById("root")).render(g.jsx(K.StrictMode,{children:g.jsx(B4,{})}));const n=()=>window.turnstile?h4()>0:!1,t=document.querySelector(P4);if(t==null||t.addEventListener("load",()=>{n()},{once:!0}),!n()){let a=0;const r=window.setInterval(()=>{(n()||++a>=20)&&window.clearInterval(r)},500)}window.addEventListener("hashchange",()=>{let a=0;const r=()=>{n()||++a>=10||setTimeout(r,200)};setTimeout(r,100)})}); + `,t.appendChild(a),document.body.appendChild(t);let r=!1;const l=p=>{p.key==="Escape"&&f()},c=()=>{document.removeEventListener("keydown",l,!0),t.remove()},f=()=>{r||(r=!0,c())};(h=document.getElementById(`${Ga}-confirm`))==null||h.addEventListener("click",()=>{r||(r=!0,c(),n.onConfirm())}),(m=document.getElementById(`${Ga}-dismiss`))==null||m.addEventListener("click",f),t.addEventListener("click",p=>{p.target===t&&f()}),document.addEventListener("keydown",l,!0)}function nk(n){return n.replace(/[&<>"']/g,t=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[t]??t)}const ik=[{name:"Free",price:0,period:"forever",description:"Get started with the essentials",features:["Core dashboard panels","Global news feed","Earthquake & weather alerts","Basic map view"],cta:"Get Started",href:"https://worldmonitor.app",highlighted:!1},{name:"Pro",monthlyPrice:39.99,annualPrice:399.99,description:"Full intelligence dashboard",features:["Everything in Free","AI stock analysis & backtesting","Daily market briefs","Military & geopolitical tracking","Custom widget builder","MCP data connectors","Priority data refresh"],monthlyProductId:"pdt_0Nbtt71uObulf7fGXhQup",annualProductId:"pdt_0NbttMIfjLWC10jHQWYgJ",highlighted:!0},{name:"API",monthlyPrice:99.99,annualPrice:999,description:"Programmatic access to intelligence data",features:["REST API access","Real-time data streams","1,000 requests/day","Webhook notifications","Custom data exports"],monthlyProductId:"pdt_0NbttVmG1SERrxhygbbUq",annualProductId:"pdt_0Nbu2lawHYE3dv2THgSEV",highlighted:!1},{name:"Enterprise",price:null,description:"Custom solutions for organizations",features:["Everything in Pro + API","Unlimited API requests","Dedicated support","Custom integrations","SLA guarantee","On-premise option"],cta:"Contact Sales",href:"mailto:enterprise@worldmonitor.app",highlighted:!1}],ak="https://api.worldmonitor.app/api/product-catalog";function sk(){const[n,t]=K.useState(ik);return K.useEffect(()=>{let a=!1;return fetch(ak,{signal:AbortSignal.timeout(5e3)}).then(r=>r.ok?r.json():null).then(r=>{var l;!a&&((l=r==null?void 0:r.tiers)!=null&&l.length)&&t(r.tiers)}).catch(()=>{}),()=>{a=!0}},[]),n}function rk(n,t){return n.price===0?{amount:"$0",suffix:"forever"}:n.price===null&&n.monthlyPrice===void 0?{amount:"Custom",suffix:"tailored to you"}:n.annualPrice===null&&n.monthlyPrice!==void 0?{amount:`$${n.monthlyPrice}`,suffix:"/mo"}:t==="annual"&&n.annualPrice!=null?{amount:`$${n.annualPrice}`,suffix:"/yr"}:{amount:`$${n.monthlyPrice}`,suffix:"/mo"}}function Ox(n){if(!n||n==="#"||n.startsWith("#")||n.startsWith("/")&&!n.startsWith("//"))return!0;const t=!/^[a-z][a-z0-9+.-]*:/i.test(n)&&!n.startsWith("//");try{const a=typeof window<"u"?window.location.href:"https://worldmonitor.app/",r=new URL(n,t?a:void 0);return r.protocol!=="http:"&&r.protocol!=="https:"?!1:r.hostname==="worldmonitor.app"||r.hostname.endsWith(".worldmonitor.app")||r.hostname==="localhost"||r.hostname==="127.0.0.1"}catch{return!1}}function ok(n,t){if(n.cta&&n.href&&n.price===0)return{type:"link",label:n.cta,href:n.href,external:!Ox(n.href)};if(n.cta&&n.href&&n.price===null)return{type:"link",label:n.cta,href:n.href,external:!Ox(n.href)};if(n.monthlyProductId){const a=t==="annual"&&n.annualProductId?n.annualProductId:n.monthlyProductId;return{type:"checkout",label:n.cta??"Get Started",productId:a}}return{type:"link",label:"Learn More",href:"#",external:!1}}function lk({refCode:n}){const[t,a]=K.useState("monthly"),[r,l]=K.useState({kind:"idle"}),c=r.kind==="creating_checkout"?r.productId:null,f=sk();K.useEffect(()=>qR(l),[]);const h=K.useCallback(m=>{YR(m,{referralCode:n})},[n]);return g.jsx("section",{id:"pricing",className:"py-24 px-6 border-t border-wm-border bg-[#060606]",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsxs("div",{className:"text-center mb-16",children:[g.jsx(Za.h2,{className:"text-3xl md:text-5xl font-display font-bold mb-4",initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5},children:"Choose Your Plan"}),g.jsx(Za.p,{className:"text-wm-muted max-w-xl mx-auto mb-8",initial:{opacity:0,y:10},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:.1},children:"From real-time monitoring to full intelligence infrastructure. Pick the tier that fits your mission."}),g.jsxs(Za.div,{className:"inline-flex items-center gap-3 bg-wm-card border border-wm-border rounded-sm p-1",initial:{opacity:0,y:10},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:.2},children:[g.jsx("button",{onClick:()=>a("monthly"),disabled:c!==null,className:`px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider transition-colors disabled:cursor-not-allowed disabled:opacity-60 ${t==="monthly"?"bg-wm-green text-wm-bg font-bold":"text-wm-muted hover:text-wm-text"}`,children:"Monthly"}),g.jsxs("button",{onClick:()=>a("annual"),disabled:c!==null,className:`px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider transition-colors flex items-center gap-2 disabled:cursor-not-allowed disabled:opacity-60 ${t==="annual"?"bg-wm-green text-wm-bg font-bold":"text-wm-muted hover:text-wm-text"}`,children:["Annual",g.jsx("span",{className:`text-[10px] px-1.5 py-0.5 rounded-sm ${t==="annual"?"bg-wm-bg/20 text-wm-bg":"bg-wm-green/10 text-wm-green"}`,children:"Save 17%"})]})]})]}),g.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6",children:f.map((m,p)=>{const v=rk(m,t),x=ok(m,t);return g.jsxs(Za.div,{className:`relative bg-zinc-900 rounded-lg p-6 flex flex-col ${m.highlighted?"border-2 border-wm-green shadow-lg shadow-wm-green/10":"border border-wm-border"}`,initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:p*.1},children:[m.highlighted&&g.jsxs("div",{className:"absolute -top-3 left-1/2 -translate-x-1/2 inline-flex items-center gap-1 bg-wm-green text-wm-bg px-3 py-1 rounded-full text-xs font-mono font-bold uppercase tracking-wider",children:[g.jsx(TO,{className:"w-3 h-3","aria-hidden":"true"}),"Most Popular"]}),g.jsx("h3",{className:`font-display text-lg font-bold mb-1 ${m.highlighted?"text-wm-green":"text-wm-text"}`,children:m.name}),g.jsx("p",{className:"text-xs text-wm-muted mb-4",children:m.description}),g.jsxs("div",{className:"mb-6",children:[g.jsx("span",{className:"text-4xl font-display font-bold",children:v.amount}),g.jsxs("span",{className:"text-sm text-wm-muted ml-1",children:["/",v.suffix]})]}),g.jsx("ul",{className:"space-y-3 mb-8 flex-1",children:m.features.map((S,w)=>g.jsxs("li",{className:"flex items-start gap-2 text-sm",children:[g.jsx(Fd,{className:`w-4 h-4 shrink-0 mt-0.5 ${m.highlighted?"text-wm-green":"text-wm-muted"}`,"aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:S})]},w))}),x.type==="link"?g.jsxs("a",{href:x.href,target:x.external?"_blank":void 0,rel:x.external?"noreferrer":void 0,className:`block text-center py-3 rounded-sm font-mono text-xs uppercase tracking-wider font-bold transition-colors ${m.highlighted?"bg-wm-green text-wm-bg hover:bg-green-400":"border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text"}`,children:[x.label," ",g.jsx(Hn,{className:"w-3.5 h-3.5 inline-block ml-1","aria-hidden":"true"})]}):(()=>{const S=c===x.productId;return g.jsx("button",{onClick:()=>h(x.productId),disabled:S,"aria-busy":S||void 0,className:`block w-full text-center py-3 rounded-sm font-mono text-xs uppercase tracking-wider font-bold transition-colors ${S?"cursor-wait opacity-70":"cursor-pointer"} ${m.highlighted?"bg-wm-green text-wm-bg hover:bg-green-400":"border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text"}`,children:S?g.jsxs(g.Fragment,{children:[g.jsx(tO,{className:"w-3.5 h-3.5 inline-block mr-2 animate-spin","aria-hidden":"true"}),g.jsx("span",{children:"Opening…"})]}):g.jsxs(g.Fragment,{children:[x.label," ",g.jsx(Hn,{className:"w-3.5 h-3.5 inline-block ml-1","aria-hidden":"true"})]})})})()]},m.name)})}),g.jsx("p",{className:"text-center text-xs text-wm-muted font-mono mt-8",children:"Have a promo code? Enter it during checkout."})]})})}function ck(){return g.jsx("span",{style:{display:"inline-block",padding:"2px 8px",marginLeft:"6px",fontSize:"10px",fontWeight:600,letterSpacing:"0.04em",textTransform:"uppercase",color:"#fbbf24",background:"rgba(251,191,36,0.12)",border:"1px solid rgba(251,191,36,0.3)",borderRadius:"4px",verticalAlign:"middle"},children:_("soonBadge")})}const uk="/pro/assets/worldmonitor-7-mar-2026-CtI5YvxO.jpg",fk="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0.11%2010.99%20124.78%2024.98'%3e%3cpath%20d='M105.375%2014.875v17.25h8.5c2.375%200%203.75-.375%204.75-1.25%201.25-1.125%201.875-3.125%201.875-7.375s-.625-6.25-1.875-7.375c-1-.875-2.375-1.25-4.75-1.25zM117%2023.5c0%203.75-.25%204.625-1%205.125-.5.375-1.125.5-2.375.5h-4.75V17.75h4.75c1.25%200%201.875%200%202.375.5.75.625%201%201.5%201%205.25zm7.875%2012.438H99.937V11h24.938zM79.563%2017.75v-2.875h14.75v5.5h-3.126V17.75h-6v4.125h4.75v2.75h-4.75v4.625h6.126v-3h3.124v5.875H79.564V29.25h2.374v-11.5zM66.188%2027.625c0%201.875.124%203.25.374%204.375h3.376c-.126-.875-.25-2.5-.25-4.625-.126-2.5-.876-2.875-2.626-3.25%202-.375%202.876-1.25%202.876-4.375%200-2.5-.376-3.5-1.126-4.125-.5-.5-1.374-.75-2.75-.75h-10.5v17.25h3.5v-6.75h4.876c1%200%201.374.125%201.75.375s.5.625.5%201.875zm-7.126-5v-4.75h5.626c.75%200%201%20.125%201.124.25.25.25.5.625.5%202.125s-.25%202-.5%202.25c-.124.125-.374.25-1.124.25zm15.876%2013.313h-25V11h24.937v24.938zM43.438%2029.25v2.875H31.562V29.25h4.25v-11.5h-4.25v-2.875h11.875v2.875h-4.25v11.5zM23.375%2014.875h-3.25L17.75%2028.5%2015%2015.875c-.125-.875-.5-1-1.25-1H12c-.75%200-1.125.25-1.25%201L8%2028.5%205.625%2014.875h-3.5L5.5%2031.25c.125.75.375.875%201.25.875h2.375c.75%200%201-.125%201.25-.875L13%2019.375l2.625%2011.875c.125.75.375.875%201.25.875h2.25c.75%200%201.125-.125%201.25-.875zm1.75%2021.063h-25V11h24.938v24.938z'%3e%3c/path%3e%3c/svg%3e",zS="https://api.worldmonitor.app/api",dk="0x4AAAAAACnaYgHIyxclu8Tj";function hk(){if(!window.turnstile)return 0;let n=0;return document.querySelectorAll(".cf-turnstile:not([data-rendered])").forEach(t=>{const a=window.turnstile.render(t,{sitekey:dk,size:"flexible",callback:r=>{t.dataset.token=r},"expired-callback":()=>{delete t.dataset.token},"error-callback":()=>{delete t.dataset.token}});t.dataset.rendered="true",t.dataset.widgetId=String(a),n++}),n}function Hl(){return new URLSearchParams(window.location.search).get("ref")||void 0}const mk=/^[a-zA-Z0-9_-]+$/;function pk(n){return n.length>0&&n.length<=64&&mk.test(n)}function Xd(n,t){if(!t||!pk(t))return n;const a=n.includes("?")?"&":"?";return`${n}${a}wm_referral=${encodeURIComponent(t)}`}function VS(){ta().then(n=>n.openSignIn()).catch(n=>{console.error("[auth] Failed to open sign in:",n),Ji(n,{tags:{surface:"pro-marketing",action:"open-sign-in"}})})}function Uh(){const[n,t]=K.useState(null),[a,r]=K.useState(!1);return K.useEffect(()=>{let l=!0,c;return ta().then(f=>{l&&(t(f.user??null),r(!0),c=f.addListener(()=>{l&&t(f.user??null)}))}).catch(f=>{console.error("[auth] Failed to load Clerk for nav auth state:",f),Ji(f,{tags:{surface:"pro-marketing",action:"load-clerk-for-nav"}}),l&&r(!0)}),()=>{l=!1,c==null||c()}},[]),{user:n,isLoaded:a}}const BS=K.createContext({isPro:!1,isChecked:!1});function gk({children:n}){const{user:t}=Uh(),a=!!t,[r,l]=K.useState({isPro:!1,isChecked:!1});return K.useEffect(()=>{if(!a){l({isPro:!1,isChecked:!0});return}let c=!1;return(async()=>{var f,h;try{const m=await ta();let p=await((f=m.session)==null?void 0:f.getToken().catch(()=>null));if(p||(await new Promise(S=>setTimeout(S,2e3)),p=await((h=m.session)==null?void 0:h.getToken().catch(()=>null))),!p){c||l({isPro:!1,isChecked:!0});return}const v=await fetch(`${zS}/me/entitlement`,{headers:{Authorization:`Bearer ${p}`},signal:AbortSignal.timeout(8e3)});if(!v.ok){c||l({isPro:!1,isChecked:!0});return}const x=await v.json();c||l({isPro:x.isPro===!0,isChecked:!0})}catch(m){console.error("[auth] Failed to check pro entitlement:",m),Ji(m,{tags:{surface:"pro-marketing",action:"check-entitlement"}}),c||l({isPro:!1,isChecked:!0})}})(),()=>{c=!0}},[a]),g.jsx(BS.Provider,{value:r,children:n})}function US(){return K.useContext(BS)}function yk(){const n=K.useRef(null);return K.useEffect(()=>{if(!n.current)return;const t=n.current;let a=!1;return ta().then(r=>{a||!t||r.mountUserButton(t,{afterSignOutUrl:"https://www.worldmonitor.app/pro"})}).catch(r=>{console.error("[auth] Failed to mount user button:",r),Ji(r,{tags:{surface:"pro-marketing",action:"mount-user-button"}})}),()=>{a=!0,ta().then(r=>{t&&r.unmountUserButton(t)}).catch(()=>{})}},[]),g.jsx("div",{ref:n,className:"flex items-center"})}const vk=()=>g.jsx("svg",{viewBox:"0 0 24 24",className:"w-5 h-5",fill:"currentColor","aria-hidden":"true",children:g.jsx("path",{d:"M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zM6.313 15.165a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313zM8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zM8.834 6.313a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312zM18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zM17.688 8.834a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.165 0a2.528 2.528 0 0 1 2.523 2.522v6.312zM15.165 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.165 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zM15.165 17.688a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.313A2.527 2.527 0 0 1 24 15.165a2.528 2.528 0 0 1-2.522 2.523h-6.313z"})}),PS=()=>g.jsxs("a",{href:"https://worldmonitor.app",className:"flex items-center gap-2 hover:opacity-80 transition-opacity","aria-label":"World Monitor — Home",children:[g.jsxs("div",{className:"relative w-8 h-8 rounded-full bg-wm-card border border-wm-border flex items-center justify-center overflow-hidden",children:[g.jsx(kl,{className:"w-5 h-5 text-wm-blue opacity-50 absolute","aria-hidden":"true"}),g.jsx(T3,{className:"w-6 h-6 text-wm-green absolute z-10","aria-hidden":"true"})]}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] text-wm-muted font-mono uppercase tracking-widest leading-none mt-1",children:"by Someone.ceo"})]})]}),xk=()=>{const{user:n,isLoaded:t}=Uh(),{isPro:a,isChecked:r}=US(),l=t&&!!n&&r&&a;return g.jsx("nav",{className:"fixed top-0 left-0 right-0 z-50 glass-panel border-b-0 border-x-0 rounded-none","aria-label":"Main navigation",children:g.jsxs("div",{className:"max-w-7xl mx-auto px-6 h-16 flex items-center justify-between",children:[g.jsx(PS,{}),g.jsxs("div",{className:"hidden md:flex items-center gap-8 text-sm font-mono text-wm-muted",children:[g.jsx("a",{href:"#tiers",className:"hover:text-wm-text transition-colors",children:_("nav.free")}),g.jsx("a",{href:"#pro",className:"hover:text-wm-green transition-colors",children:_("nav.pro")}),g.jsx("a",{href:"#api",className:"hover:text-wm-text transition-colors",children:_("nav.api")}),g.jsx("a",{href:"#enterprise",className:"hover:text-wm-text transition-colors",children:_("nav.enterprise")})]}),g.jsxs("div",{className:"flex items-center gap-2",children:[t&&(n?g.jsx(yk,{}):g.jsx("button",{type:"button",onClick:VS,className:"border border-wm-border text-wm-text px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:border-wm-text transition-colors",children:_("nav.signIn")})),l?g.jsxs("a",{href:"https://worldmonitor.app",className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors inline-flex items-center gap-1.5",children:[_("nav.goToDashboard")," ",g.jsx(Hn,{className:"w-3 h-3","aria-hidden":"true"})]}):g.jsx("a",{href:"#pricing",className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("nav.upgradeToPro")})]})]})})},bk=()=>g.jsxs("a",{href:"https://www.wired.me/story/the-music-streaming-ceo-who-built-a-global-war-map",target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 px-3 py-1.5 rounded-full border border-wm-border bg-wm-card/50 text-wm-muted text-xs font-mono hover:border-wm-green/30 hover:text-wm-text transition-colors",children:[_("wired.asFeaturedIn")," ",g.jsx("span",{className:"text-wm-text font-bold",children:"WIRED"})," ",g.jsx(vS,{className:"w-3 h-3","aria-hidden":"true"})]}),Sk=()=>g.jsxs("div",{className:"relative my-4 md:my-8 -mx-6",children:[g.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:g.jsx("div",{className:"w-64 h-40 md:w-96 md:h-56 bg-wm-green/8 rounded-full blur-[80px]"})}),g.jsx("div",{className:"flex items-end justify-center gap-[3px] md:gap-1 h-28 md:h-44 relative px-4","aria-hidden":"true",children:Array.from({length:60}).map((r,l)=>{const c=Math.abs(l-30),f=c<=8,h=f?1-c/8:0,m=60+h*110,p=Math.max(8,35-c*.8);return g.jsx(Za.div,{className:`flex-1 max-w-2 md:max-w-3 rounded-sm ${f?"bg-wm-green":"bg-wm-muted/20"}`,style:f?{boxShadow:`0 0 ${6+h*12}px rgba(74,222,128,${h*.5})`}:void 0,initial:{height:f?m*.3:p*.5,opacity:f?.4:.08},animate:f?{height:[m*.5,m,m*.65,m*.9],opacity:[.6+h*.3,1,.75+h*.2,.95]}:{height:[p,p*.3,p*.7,p*.15,p*.5],opacity:[.2,.06,.15,.04,.12]},transition:{duration:f?2.5+h*.5:1+Math.random()*.6,repeat:1/0,repeatType:"reverse",delay:f?c*.07:Math.random()*.6,ease:"easeInOut"}},l)})})]}),wk=()=>{const{user:n,isLoaded:t}=Uh(),{isPro:a,isChecked:r}=US(),l=t&&!n,c=t&&!!n&&r&&a;return g.jsxs("section",{className:"pt-28 pb-12 px-6 relative overflow-hidden",children:[g.jsx("div",{className:"absolute inset-0 bg-[radial-gradient(circle_at_50%_20%,rgba(74,222,128,0.08)_0%,transparent_50%)] pointer-events-none"}),g.jsx("div",{className:"max-w-4xl mx-auto text-center relative z-10",children:g.jsxs(Za.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.6},children:[g.jsx("div",{className:"mb-4",children:g.jsx(bk,{})}),g.jsxs("h1",{className:"text-6xl md:text-8xl font-display font-bold tracking-tighter leading-[0.95]",children:[g.jsx("span",{className:"text-wm-muted/40",children:_("hero.noiseWord")}),g.jsx("span",{className:"mx-3 md:mx-5 text-wm-border/50",children:"→"}),g.jsx("span",{className:"text-transparent bg-clip-text bg-gradient-to-r from-wm-green to-emerald-300 text-glow",children:_("hero.signalWord")})]}),g.jsx(Sk,{}),g.jsx("p",{className:"text-lg md:text-xl text-wm-muted max-w-xl mx-auto font-light leading-relaxed",children:_("hero.valueProps")}),g.jsxs("div",{className:"flex flex-col sm:flex-row gap-3 justify-center mt-8",children:[c?g.jsxs("a",{href:"https://worldmonitor.app",className:"bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors flex items-center justify-center gap-2",children:[_("hero.goToDashboard")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]}):g.jsxs("a",{href:"#pricing",className:"bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors flex items-center justify-center gap-2",children:[_("hero.choosePlan")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]}),l&&g.jsx("button",{type:"button",onClick:VS,className:"border border-wm-border text-wm-text px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:border-wm-text transition-colors",children:_("hero.signIn")})]}),g.jsx("div",{className:"flex items-center justify-center mt-4",children:g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),className:"text-xs text-wm-green font-mono hover:text-green-300 transition-colors flex items-center gap-1",children:[_("hero.tryFreeDashboard")," ",g.jsx(Hn,{className:"w-3 h-3","aria-hidden":"true"})]})})]})})]})},_k=()=>g.jsx("section",{className:"border-y border-wm-border bg-wm-card/30 py-16 px-6",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-8 text-center mb-12",children:[{value:"2M+",label:_("socialProof.uniqueVisitors")},{value:"421K",label:_("socialProof.peakDailyUsers")},{value:"190+",label:_("socialProof.countriesReached")},{value:"500+",label:_("socialProof.liveDataSources")}].map((n,t)=>g.jsxs("div",{children:[g.jsx("p",{className:"text-3xl md:text-4xl font-display font-bold text-wm-green",children:n.value}),g.jsx("p",{className:"text-xs font-mono text-wm-muted uppercase tracking-widest mt-1",children:n.label})]},t))}),g.jsxs("blockquote",{className:"max-w-3xl mx-auto text-center",children:[g.jsxs("p",{className:"text-lg md:text-xl text-wm-muted italic leading-relaxed",children:['"',_("socialProof.quote"),'"']}),g.jsx("footer",{className:"mt-6 flex items-center justify-center gap-3",children:g.jsx("a",{href:"https://www.wired.me/story/the-music-streaming-ceo-who-built-a-global-war-map",target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 text-wm-muted hover:text-wm-text transition-colors",children:g.jsx("img",{src:fk,alt:"WIRED",className:"h-5 brightness-0 invert opacity-60 hover:opacity-100 transition-opacity"})})})]})]})}),Tk=()=>g.jsxs("section",{className:"py-24 px-6 max-w-5xl mx-auto",id:"tiers",children:[g.jsx("h2",{className:"sr-only",children:"Plans"}),g.jsxs("div",{className:"grid md:grid-cols-2 gap-8",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-green p-8 relative border-glow",children:[g.jsx("div",{className:"absolute top-0 left-0 w-full h-1 bg-wm-green"}),g.jsx("h3",{className:"font-display text-2xl font-bold mb-2",children:_("twoPath.proTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-6",children:_("twoPath.proDesc")}),g.jsx("ul",{className:"space-y-3 mb-8",children:[_("twoPath.proF1"),_("twoPath.proF2"),_("twoPath.proF3"),_("twoPath.proF4"),_("twoPath.proF5"),_("twoPath.proF6"),_("twoPath.proF7"),_("twoPath.proF8"),_("twoPath.proF9")].map((n,t)=>g.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[g.jsx(Fd,{className:"w-4 h-4 shrink-0 mt-0.5 text-wm-green","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:n})]},t))}),g.jsx("a",{href:"#pricing",className:"block text-center py-2.5 rounded-sm font-mono text-xs uppercase tracking-wider font-bold bg-wm-green text-wm-bg hover:bg-green-400 transition-colors",children:_("twoPath.choosePlan")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-8",children:[g.jsx("h3",{className:"font-display text-2xl font-bold mb-2",children:_("twoPath.entTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-6",children:_("twoPath.entDesc")}),g.jsxs("ul",{className:"space-y-3 mb-8",children:[g.jsx("li",{className:"text-xs font-mono text-wm-green uppercase tracking-wider mb-1",children:_("twoPath.entF1")}),[_("twoPath.entF2"),_("twoPath.entF3"),_("twoPath.entF4"),_("twoPath.entF5"),_("twoPath.entF6"),_("twoPath.entF7"),_("twoPath.entF8"),_("twoPath.entF9"),_("twoPath.entF10"),_("twoPath.entF11")].map((n,t)=>g.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[g.jsx(Fd,{className:"w-4 h-4 shrink-0 mt-0.5 text-wm-muted","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted",children:n})]},t))]}),g.jsx("a",{href:"#enterprise",className:"block text-center py-2.5 rounded-sm font-mono text-xs uppercase tracking-wider font-bold border border-wm-border text-wm-muted hover:text-wm-text hover:border-wm-text transition-colors",children:_("twoPath.entCta")})]})]})]}),Ek=()=>{const n=[{icon:g.jsx(K3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.noiseTitle"),desc:_("whyUpgrade.noiseDesc")},{icon:g.jsx(wS,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.fasterTitle"),desc:_("whyUpgrade.fasterDesc")},{icon:g.jsx(vO,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.controlTitle"),desc:_("whyUpgrade.controlDesc")},{icon:g.jsx(SS,{className:"w-6 h-6","aria-hidden":"true"}),title:_("whyUpgrade.deeperTitle"),desc:_("whyUpgrade.deeperDesc")}];return g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/20",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-16 text-center",children:_("whyUpgrade.title")}),g.jsx("div",{className:"grid md:grid-cols-2 gap-8",children:n.map((t,a)=>g.jsxs("div",{className:"flex gap-5",children:[g.jsx("div",{className:"text-wm-green shrink-0 mt-1",children:t.icon}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold text-lg mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted leading-relaxed",children:t.desc})]})]},a))})]})})},Ak=()=>{const n=[{icon:g.jsx(C3,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.askIt"),desc:_("pillars.askItDesc")},{icon:g.jsx(N3,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.subscribeIt"),desc:_("pillars.subscribeItDesc")},{icon:g.jsx(nc,{className:"w-7 h-7","aria-hidden":"true"}),title:_("pillars.buildOnIt"),desc:_("pillars.buildOnItDesc")}];return g.jsx("section",{className:"py-20 px-6 border-t border-wm-border",children:g.jsx("div",{className:"max-w-5xl mx-auto",children:g.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6 hover:border-wm-green/30 transition-colors",children:[g.jsx("div",{className:"text-wm-green mb-4",children:t.icon}),g.jsx("h3",{className:"font-display text-xl font-bold mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted leading-relaxed",children:t.desc})]},a))})})})},Nk=()=>g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/20",children:g.jsxs("div",{className:"max-w-4xl mx-auto text-center",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-green/30 bg-wm-green/10 text-wm-green text-xs font-mono mb-6",children:_("deliveryDesk.eyebrow")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("deliveryDesk.title")}),g.jsx("p",{className:"text-lg text-wm-muted leading-relaxed mb-6",children:_("deliveryDesk.body")}),g.jsx("p",{className:"text-xl md:text-2xl font-display font-bold text-wm-green mb-8",children:_("deliveryDesk.closer")}),g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest",children:_("deliveryDesk.channels")})]})}),Dk=()=>g.jsx("section",{className:"px-6 py-16",children:g.jsxs("div",{className:"max-w-6xl mx-auto",children:[g.jsxs("div",{className:"relative rounded-lg overflow-hidden border border-wm-border shadow-2xl shadow-wm-green/5",children:[g.jsxs("div",{className:"bg-wm-card px-4 py-2 border-b border-wm-border flex items-center gap-3",children:[g.jsxs("div",{className:"flex gap-1.5",children:[g.jsx("div",{className:"w-3 h-3 rounded-full bg-red-500/70"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-yellow-500/70"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-green-500/70"})]}),g.jsx("span",{className:"font-mono text-xs text-wm-muted ml-2",children:_("livePreview.windowTitle")}),g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),target:"_blank",rel:"noreferrer",className:"ml-auto text-xs text-wm-green font-mono hover:text-green-300 transition-colors flex items-center gap-1",children:[_("livePreview.openFullScreen")," ",g.jsx(vS,{className:"w-3 h-3","aria-hidden":"true"})]})]}),g.jsxs("div",{className:"relative aspect-[16/9] bg-black",children:[g.jsx("img",{src:uk,alt:"World Monitor Dashboard",className:"absolute inset-0 w-full h-full object-cover"}),g.jsx("iframe",{src:"https://worldmonitor.app?embed=pro-preview",title:_("livePreview.iframeTitle"),className:"relative w-full h-full border-0",loading:"lazy",sandbox:"allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"}),g.jsx("div",{className:"absolute inset-0 pointer-events-none bg-gradient-to-t from-wm-bg/80 via-transparent to-transparent"}),g.jsx("div",{className:"absolute bottom-4 left-0 right-0 text-center pointer-events-auto",children:g.jsxs("a",{href:Xd("https://worldmonitor.app",Hl()),target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-6 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("livePreview.tryLiveDashboard")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})})]})]}),g.jsx("p",{className:"text-center text-xs text-wm-muted font-mono mt-4",children:_("livePreview.description")})]})}),Ck=()=>{const t=["Finnhub","FRED","Bloomberg","CNBC","Nikkei","CoinGecko","Polymarket","Reuters","ACLED","UCDP","GDELT","NASA FIRMS","USGS","OpenSky","AISStream","Cloudflare Radar","BGPStream","GPSJam","NOAA","Copernicus","IAEA","Al Jazeera","Sky News","Euronews","DW News","France 24","OilPrice","Rigzone","Maritime Executive","Hellenic Shipping News","Defense One","Jane's","The War Zone","TechCrunch","Ars Technica","The Verge","Wired","Krebs on Security","BleepingComputer","The Record"].join(" · ");return g.jsx("section",{className:"border-y border-wm-border bg-wm-card/20 overflow-hidden py-4","aria-label":"Data sources",children:g.jsxs("div",{className:"marquee-track whitespace-nowrap font-mono text-xs text-wm-muted uppercase tracking-widest",children:[g.jsxs("span",{className:"inline-block px-4",children:[t," · "]}),g.jsxs("span",{className:"inline-block px-4",children:[t," · "]})]})})},jk=()=>g.jsx("section",{className:"py-24 px-6 border-t border-wm-border bg-wm-card/30",id:"pro",children:g.jsxs("div",{className:"max-w-7xl mx-auto grid lg:grid-cols-2 gap-16 items-start",children:[g.jsxs("div",{children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-green/30 bg-wm-green/10 text-wm-green text-xs font-mono mb-6",children:_("proShowcase.proTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("proShowcase.title")}),g.jsx("p",{className:"text-wm-muted mb-8",children:_("proShowcase.subtitle")}),g.jsxs("div",{className:"space-y-6",children:[g.jsxs("div",{className:"flex gap-4",children:[g.jsx(wS,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.equityResearch")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.equityResearchDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(kl,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.geopoliticalAnalysis")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.geopoliticalAnalysisDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Vh,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.economyAnalytics")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.economyAnalyticsDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Bh,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.riskMonitoring")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.riskMonitoringDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(SS,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsxs("h4",{className:"font-bold mb-1",children:[_("proShowcase.orbitalSurveillance"),g.jsx(ck,{})]}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.orbitalSurveillanceDesc").replace(/^\(Soon\)\s*/,"")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(U3,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.morningBriefs")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.morningBriefsDesc")})]})]}),g.jsxs("div",{className:"flex gap-4",children:[g.jsx(Z3,{className:"w-6 h-6 text-wm-green shrink-0","aria-hidden":"true"}),g.jsxs("div",{children:[g.jsx("h3",{className:"font-bold mb-1",children:_("proShowcase.oneKey")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("proShowcase.oneKeyDesc")})]})]})]}),g.jsxs("div",{className:"mt-10 pt-8 border-t border-wm-border",children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-4",children:_("proShowcase.deliveryLabel")}),g.jsx("div",{className:"flex gap-6",children:[{icon:g.jsx(vk,{}),label:"Slack"},{icon:g.jsx(oO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Discord"},{icon:g.jsx(hO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Telegram"},{icon:g.jsx(sO,{className:"w-5 h-5","aria-hidden":"true"}),label:"Email"},{icon:g.jsx(nc,{className:"w-5 h-5","aria-hidden":"true"}),label:"Webhook"}].map((n,t)=>g.jsxs("div",{className:"flex flex-col items-center gap-1.5 text-wm-muted hover:text-wm-text transition-colors cursor-pointer",children:[n.icon,g.jsx("span",{className:"text-[10px] font-mono",children:n.label})]},t))})]})]}),g.jsxs("div",{className:"bg-[#1a1d21] rounded-lg border border-[#35373b] overflow-hidden shadow-2xl sticky top-24",children:[g.jsxs("div",{className:"bg-[#222529] px-4 py-3 border-b border-[#35373b] flex items-center gap-3",children:[g.jsx("div",{className:"w-3 h-3 rounded-full bg-red-500"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-yellow-500"}),g.jsx("div",{className:"w-3 h-3 rounded-full bg-green-500"}),g.jsx("span",{className:"ml-2 font-mono text-xs text-gray-400",children:"#world-monitor-alerts"})]}),g.jsx("div",{className:"p-6 space-y-6 font-sans text-sm",children:g.jsxs("div",{className:"flex gap-4",children:[g.jsx("div",{className:"w-10 h-10 rounded bg-wm-green/20 flex items-center justify-center shrink-0",children:g.jsx(kl,{className:"w-6 h-6 text-wm-green","aria-hidden":"true"})}),g.jsxs("div",{children:[g.jsxs("div",{className:"flex items-baseline gap-2 mb-1",children:[g.jsx("span",{className:"font-bold text-gray-200",children:"World Monitor"}),g.jsx("span",{className:"text-xs text-gray-500 bg-gray-800 px-1 rounded",children:"APP"}),g.jsx("span",{className:"text-xs text-gray-500",children:"8:00 AM"})]}),g.jsxs("p",{className:"text-gray-300 font-bold mb-3",children:[_("slackMock.morningBrief")," · Mar 6"]}),g.jsxs("div",{className:"space-y-3",children:[g.jsxs("div",{className:"pl-3 border-l-2 border-blue-500",children:[g.jsx("span",{className:"text-blue-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.markets")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.marketsText")})]}),g.jsxs("div",{className:"pl-3 border-l-2 border-orange-500",children:[g.jsx("span",{className:"text-orange-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.elevated")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.elevatedText")})]}),g.jsxs("div",{className:"pl-3 border-l-2 border-yellow-500",children:[g.jsx("span",{className:"text-yellow-400 font-bold text-xs uppercase tracking-wider",children:_("slackMock.watch")}),g.jsx("p",{className:"text-gray-300 mt-1",children:_("slackMock.watchText")})]})]})]})]})})]})]})}),Mk=()=>{const n=[{icon:g.jsx(k3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.investorsTitle"),desc:_("audience.investorsDesc")},{icon:g.jsx(G3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.tradersTitle"),desc:_("audience.tradersDesc")},{icon:g.jsx(fO,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.researchersTitle"),desc:_("audience.researchersDesc")},{icon:g.jsx(kl,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.journalistsTitle"),desc:_("audience.journalistsDesc")},{icon:g.jsx(W3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.govTitle"),desc:_("audience.govDesc")},{icon:g.jsx(M3,{className:"w-6 h-6","aria-hidden":"true"}),title:_("audience.teamsTitle"),desc:_("audience.teamsDesc")}];return g.jsx("section",{className:"py-24 px-6",children:g.jsxs("div",{className:"max-w-5xl mx-auto",children:[g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-16 text-center",children:_("audience.title")}),g.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6 hover:border-wm-green/30 transition-colors",children:[g.jsx("div",{className:"text-wm-green mb-4",children:t.icon}),g.jsx("h3",{className:"font-bold mb-2",children:t.title}),g.jsx("p",{className:"text-sm text-wm-muted",children:t.desc})]},a))})]})})},Ok=()=>g.jsx("section",{className:"py-24 px-6 border-y border-wm-border bg-[#0a0a0a]",id:"api",children:g.jsxs("div",{className:"max-w-7xl mx-auto grid lg:grid-cols-2 gap-16 items-center",children:[g.jsx("div",{className:"order-2 lg:order-1",children:g.jsxs("div",{className:"bg-black border border-wm-border rounded-lg overflow-hidden font-mono text-sm",children:[g.jsxs("div",{className:"bg-wm-card px-4 py-2 border-b border-wm-border flex items-center gap-2",children:[g.jsx(SO,{className:"w-4 h-4 text-wm-muted","aria-hidden":"true"}),g.jsx("span",{className:"text-wm-muted text-xs",children:"api.worldmonitor.app"})]}),g.jsx("div",{className:"p-6 text-gray-300 overflow-x-auto",children:g.jsx("pre",{children:g.jsxs("code",{children:[g.jsx("span",{className:"text-wm-blue",children:"curl"})," \\",g.jsx("br",{}),g.jsx("span",{className:"text-wm-green",children:'"https://api.worldmonitor.app/v1/intelligence/convergence?region=MENA&time_window=6h"'})," \\",g.jsx("br",{}),"-H ",g.jsx("span",{className:"text-wm-green",children:'"Authorization: Bearer wm_live_xxx"'}),g.jsx("br",{}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"{"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"status"'}),": ",g.jsx("span",{className:"text-wm-green",children:'"success"'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"data"'}),": ",g.jsx("span",{className:"text-wm-muted",children:"["}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"{"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"type"'}),": ",g.jsx("span",{className:"text-wm-green",children:'"multi_signal_convergence"'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"signals"'}),": ",g.jsx("span",{className:"text-wm-muted",children:'["military_flights", "ais_dark_ships", "oref_sirens"]'}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"confidence"'}),": ",g.jsx("span",{className:"text-orange-400",children:"0.92"}),",",g.jsx("br",{}),g.jsx("span",{className:"text-wm-blue",children:'"location"'}),": ",g.jsx("span",{className:"text-wm-muted",children:"{"})," ",g.jsx("span",{className:"text-wm-blue",children:'"lat"'}),": ",g.jsx("span",{className:"text-orange-400",children:"34.05"}),", ",g.jsx("span",{className:"text-wm-blue",children:'"lng"'}),": ",g.jsx("span",{className:"text-orange-400",children:"35.12"})," ",g.jsx("span",{className:"text-wm-muted",children:"}"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"}"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"]"}),g.jsx("br",{}),g.jsx("span",{className:"text-wm-muted",children:"}"})]})})})]})}),g.jsxs("div",{className:"order-1 lg:order-2",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("apiSection.apiTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("apiSection.title")}),g.jsx("p",{className:"text-wm-muted mb-8",children:_("apiSection.subtitle")}),g.jsxs("ul",{className:"space-y-4 mb-8",children:[g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(pO,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.restApi")})]}),g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(iO,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.authenticated")})]}),g.jsxs("li",{className:"flex items-start gap-3",children:[g.jsx(I3,{className:"w-5 h-5 text-wm-muted shrink-0","aria-hidden":"true"}),g.jsx("span",{className:"text-sm",children:_("apiSection.structured")})]})]}),g.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-8 p-4 bg-wm-card border border-wm-border rounded-sm",children:[g.jsxs("div",{children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("apiSection.starter")}),g.jsx("p",{className:"text-sm font-bold",children:_("apiSection.starterReqs")}),g.jsx("p",{className:"text-xs text-wm-muted",children:_("apiSection.starterWebhooks")})]}),g.jsxs("div",{children:[g.jsx("p",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("apiSection.business")}),g.jsx("p",{className:"text-sm font-bold",children:_("apiSection.businessReqs")}),g.jsx("p",{className:"text-xs text-wm-muted",children:_("apiSection.businessWebhooks")})]})]}),g.jsx("p",{className:"text-sm text-wm-muted border-l-2 border-wm-border pl-4",children:_("apiSection.feedData")})]})]})}),Rk=()=>g.jsx("section",{className:"py-24 px-6",id:"enterprise",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsxs("div",{className:"text-center mb-16",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("enterpriseShowcase.enterpriseTier")}),g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("enterpriseShowcase.title")}),g.jsx("p",{className:"text-wm-muted max-w-2xl mx-auto",children:_("enterpriseShowcase.subtitle")})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-6",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Bh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.security")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.securityDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(yS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.aiAgents")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.aiAgentsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(xS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.dataLayers")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.dataLayersDesc")})]})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-12",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(nc,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.connectors")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.connectorsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(bS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.whiteLabel")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.whiteLabelDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Vh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.financial")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.financialDesc")})]})]}),g.jsxs("div",{className:"data-grid mb-12",children:[g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.commodity")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.commodityDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.government")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.governmentDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.risk")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.riskDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h4",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.soc")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.socDesc")})]})]}),g.jsx("div",{className:"text-center mt-12",children:g.jsxs("a",{href:"#enterprise-contact","aria-label":"Talk to sales about Enterprise plans",className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-8 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("enterpriseShowcase.talkToSales")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})})]})}),kk=()=>{const n=[{feature:_("pricingTable.dataRefresh"),free:_("pricingTable.f5_15min"),pro:_("pricingTable.fLt60s"),api:_("pricingTable.fPerRequest"),ent:_("pricingTable.fLiveEdge")},{feature:_("pricingTable.dashboard"),free:_("pricingTable.f50panels"),pro:_("pricingTable.f50panels"),api:"—",ent:_("pricingTable.fWhiteLabel")},{feature:_("pricingTable.ai"),free:_("pricingTable.fBYOK"),pro:_("pricingTable.fIncluded"),api:"—",ent:_("pricingTable.fAgentsPersonas")},{feature:_("pricingTable.briefsAlerts"),free:"—",pro:_("pricingTable.fDailyFlash"),api:"—",ent:_("pricingTable.fTeamDist")},{feature:_("pricingTable.delivery"),free:"—",pro:_("pricingTable.fSlackTgWa"),api:_("pricingTable.fWebhook"),ent:_("pricingTable.fSiemMcp")},{feature:_("pricingTable.apiRow"),free:"—",pro:"—",api:_("pricingTable.fRestWebhook"),ent:_("pricingTable.fMcpBulk")},{feature:_("pricingTable.infraLayers"),free:_("pricingTable.f45"),pro:_("pricingTable.f45"),api:"—",ent:_("pricingTable.fTensOfThousands")},{feature:_("pricingTable.satellite"),free:_("pricingTable.fLiveTracking"),pro:_("pricingTable.fPassAlerts"),api:"—",ent:_("pricingTable.fImagerySar")},{feature:_("pricingTable.connectorsRow"),free:"—",pro:"—",api:"—",ent:_("pricingTable.f100plus")},{feature:_("pricingTable.deployment"),free:_("pricingTable.fCloud"),pro:_("pricingTable.fCloud"),api:_("pricingTable.fCloud"),ent:_("pricingTable.fCloudOnPrem")},{feature:_("pricingTable.securityRow"),free:_("pricingTable.fStandard"),pro:_("pricingTable.fStandard"),api:_("pricingTable.fKeyAuth"),ent:_("pricingTable.fSsoMfa")}];return g.jsxs("section",{className:"py-24 px-6 max-w-7xl mx-auto",children:[g.jsx("div",{className:"text-center mb-16",children:g.jsx("h2",{className:"text-3xl md:text-5xl font-display font-bold mb-6",children:_("pricingTable.title")})}),g.jsxs("div",{className:"hidden md:block",children:[g.jsxs("div",{className:"grid grid-cols-5 gap-4 mb-4 pb-4 border-b border-wm-border font-mono text-xs uppercase tracking-widest text-wm-muted",children:[g.jsx("div",{children:_("pricingTable.feature")}),g.jsx("div",{children:_("pricingTable.freeHeader")}),g.jsx("div",{className:"text-wm-green",children:_("pricingTable.proHeader")}),g.jsx("div",{children:_("pricingTable.apiHeader")}),g.jsx("div",{children:_("pricingTable.entHeader")})]}),n.map((t,a)=>g.jsxs("div",{className:"grid grid-cols-5 gap-4 py-4 border-b border-wm-border/50 text-sm hover:bg-wm-card/50 transition-colors",children:[g.jsx("div",{className:"font-medium",children:t.feature}),g.jsx("div",{className:"text-wm-muted",children:t.free}),g.jsx("div",{className:"text-wm-green",children:t.pro}),g.jsx("div",{className:"text-wm-muted",children:t.api}),g.jsx("div",{className:"text-wm-muted",children:t.ent})]},a))]}),g.jsx("div",{className:"md:hidden space-y-4",children:n.map((t,a)=>g.jsxs("div",{className:"bg-wm-card border border-wm-border p-4 rounded-sm",children:[g.jsx("p",{className:"font-medium text-sm mb-3",children:t.feature}),g.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs",children:[g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("tiers.free"),":"]})," ",t.free]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-green",children:[_("tiers.pro"),":"]})," ",g.jsx("span",{className:"text-wm-green",children:t.pro})]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("nav.api"),":"]})," ",t.api]}),g.jsxs("div",{children:[g.jsxs("span",{className:"text-wm-muted",children:[_("tiers.enterprise"),":"]})," ",t.ent]})]})]},a))}),g.jsx("p",{className:"text-center text-sm text-wm-muted mt-8",children:_("pricingTable.noteBelow")})]})},Lk=()=>{const n=[{q:_("faq.q1"),a:_("faq.a1"),open:!0},{q:_("faq.q2"),a:_("faq.a2")},{q:_("faq.q3"),a:_("faq.a3")},{q:_("faq.q4"),a:_("faq.a4")},{q:_("faq.q5"),a:_("faq.a5")},{q:_("faq.q6"),a:_("faq.a6")},{q:_("faq.q7"),a:_("faq.a7")},{q:_("faq.q8"),a:_("faq.a8")},{q:_("faq.q9"),a:_("faq.a9")},{q:_("faq.q10"),a:_("faq.a10")},{q:_("faq.q11"),a:_("faq.a11")},{q:_("faq.q12"),a:_("faq.a12")},{q:_("faq.q13"),a:_("faq.a13")}];return g.jsxs("section",{className:"py-24 px-6 max-w-3xl mx-auto",children:[g.jsx("h2",{className:"text-3xl font-display font-bold mb-12 text-center",children:_("faq.title")}),g.jsx("div",{className:"space-y-4",children:n.map((t,a)=>g.jsxs("details",{open:t.open,className:"group bg-wm-card border border-wm-border rounded-sm [&_summary::-webkit-details-marker]:hidden",children:[g.jsxs("summary",{className:"flex items-center justify-between p-6 cursor-pointer font-medium",children:[t.q,g.jsx(V3,{className:"w-5 h-5 text-wm-muted group-open:rotate-180 transition-transform","aria-hidden":"true"})]}),g.jsx("div",{className:"px-6 pb-6 text-wm-muted text-sm border-t border-wm-border pt-4 mt-2",children:t.a})]},a))})]})},zk=()=>g.jsx("footer",{className:"border-t border-wm-border bg-[#020202] pt-8 pb-12 px-6 text-center",children:g.jsxs("div",{className:"flex flex-col md:flex-row items-center justify-between max-w-7xl mx-auto text-xs text-wm-muted font-mono",children:[g.jsxs("div",{className:"flex items-center gap-3 mb-4 md:mb-0",children:[g.jsx("img",{src:"/favico/favicon-32x32.png",alt:"",width:"28",height:"28",className:"rounded-full"}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight text-wm-text",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] uppercase tracking-[2px] opacity-60 mt-0.5",children:"by Someone.ceo"})]})]}),g.jsxs("div",{className:"flex items-center gap-6",children:[g.jsx("a",{href:"/",className:"hover:text-wm-text transition-colors",children:"Dashboard"}),g.jsx("a",{href:"https://www.worldmonitor.app/blog/",className:"hover:text-wm-text transition-colors",children:"Blog"}),g.jsx("a",{href:"https://www.worldmonitor.app/docs",className:"hover:text-wm-text transition-colors",children:"Docs"}),g.jsx("a",{href:"https://status.worldmonitor.app/",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Status"}),g.jsx("a",{href:"https://github.com/koala73/worldmonitor",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"GitHub"}),g.jsx("a",{href:"https://discord.gg/re63kWKxaz",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Discord"}),g.jsx("a",{href:"https://x.com/worldmonitorai",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"X"})]}),g.jsxs("span",{className:"text-[10px] opacity-40 mt-4 md:mt-0",children:["© ",new Date().getFullYear()," WorldMonitor"]})]})}),Vk=()=>g.jsxs("div",{className:"min-h-screen selection:bg-wm-green/30 selection:text-wm-green",children:[g.jsx("nav",{className:"fixed top-0 left-0 right-0 z-50 glass-panel border-b-0 border-x-0 rounded-none","aria-label":"Main navigation",children:g.jsxs("div",{className:"max-w-7xl mx-auto px-6 h-16 flex items-center justify-between",children:[g.jsx("a",{href:"#",onClick:n=>{n.preventDefault(),window.location.hash=""},children:g.jsx(PS,{})}),g.jsxs("div",{className:"hidden md:flex items-center gap-8 text-sm font-mono text-wm-muted",children:[g.jsx("a",{href:"#",onClick:n=>{n.preventDefault(),window.location.hash=""},className:"hover:text-wm-text transition-colors",children:_("nav.pro")}),g.jsx("a",{href:"#enterprise",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("features"))==null||t.scrollIntoView({behavior:"smooth"})},className:"hover:text-wm-text transition-colors",children:_("nav.enterprise")}),g.jsx("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"hover:text-wm-green transition-colors",children:_("enterpriseShowcase.talkToSales")})]}),g.jsx("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"bg-wm-green text-wm-bg px-4 py-2 rounded-sm font-mono text-xs uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("enterpriseShowcase.talkToSales")})]})}),g.jsxs("main",{className:"pt-24",children:[g.jsx("section",{className:"py-24 px-6 text-center",children:g.jsxs("div",{className:"max-w-4xl mx-auto",children:[g.jsx("div",{className:"inline-flex items-center gap-2 px-3 py-1 rounded-full border border-wm-border bg-wm-card text-wm-muted text-xs font-mono mb-6",children:_("enterpriseShowcase.enterpriseTier")}),g.jsx("h2",{className:"text-4xl md:text-6xl font-display font-bold mb-6",children:_("enterpriseShowcase.title")}),g.jsx("p",{className:"text-lg text-wm-muted max-w-2xl mx-auto mb-10",children:_("enterpriseShowcase.subtitle")}),g.jsxs("a",{href:"#enterprise-contact",onClick:n=>{var t;n.preventDefault(),(t=document.getElementById("contact"))==null||t.scrollIntoView({behavior:"smooth"})},className:"inline-flex items-center gap-2 bg-wm-green text-wm-bg px-8 py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:[_("enterpriseShowcase.talkToSales")," ",g.jsx(Hn,{className:"w-4 h-4","aria-hidden":"true"})]})]})}),g.jsx("section",{className:"py-24 px-6",id:"features",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsx("h2",{className:"sr-only",children:"Enterprise Features"}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-6",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Bh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.security")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.securityDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(yS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.aiAgents")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.aiAgentsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(xS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.dataLayers")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.dataLayersDesc")})]})]}),g.jsxs("div",{className:"grid md:grid-cols-3 gap-6 mb-12",children:[g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(nc,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.connectors")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.connectorsDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(bS,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.whiteLabel")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.whiteLabelDesc")})]}),g.jsxs("div",{className:"bg-wm-card border border-wm-border p-6",children:[g.jsx(Vh,{className:"w-8 h-8 text-wm-muted mb-4","aria-hidden":"true"}),g.jsx("h3",{className:"font-bold mb-2",children:_("enterpriseShowcase.financial")}),g.jsx("p",{className:"text-sm text-wm-muted",children:_("enterpriseShowcase.financialDesc")})]})]})]})}),g.jsx("section",{className:"py-24 px-6 border-t border-wm-border",children:g.jsxs("div",{className:"max-w-7xl mx-auto",children:[g.jsx("h2",{className:"text-3xl font-display font-bold mb-12 text-center",children:_("enterpriseShowcase.title")}),g.jsxs("div",{className:"data-grid",children:[g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.commodity")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.commodityDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.government")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.governmentDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.risk")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.riskDesc")})]}),g.jsxs("div",{className:"data-cell",children:[g.jsx("h3",{className:"font-mono text-xs text-wm-muted uppercase tracking-widest mb-2",children:_("enterpriseShowcase.soc")}),g.jsx("p",{className:"text-sm",children:_("enterpriseShowcase.socDesc")})]})]})]})}),g.jsx("section",{className:"py-24 px-6 border-t border-wm-border",id:"contact",children:g.jsxs("div",{className:"max-w-xl mx-auto",children:[g.jsx("h2",{className:"font-display text-3xl font-bold mb-2 text-center",children:_("enterpriseShowcase.contactFormTitle")}),g.jsx("p",{className:"text-sm text-wm-muted mb-10 text-center",children:_("enterpriseShowcase.contactFormSubtitle")}),g.jsxs("form",{className:"space-y-4",onSubmit:async n=>{var m;n.preventDefault();const t=n.currentTarget,a=t.querySelector('button[type="submit"]'),r=a.textContent;a.disabled=!0,a.textContent=_("enterpriseShowcase.contactSending");const l=new FormData(t),c=((m=t.querySelector('input[name="website"]'))==null?void 0:m.value)||"",f=t.querySelector(".cf-turnstile"),h=(f==null?void 0:f.dataset.token)||"";try{const p=await fetch(`${zS}/leads/v1/submit-contact`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:l.get("email"),name:l.get("name"),organization:l.get("organization"),phone:l.get("phone"),message:l.get("message"),source:"enterprise-contact",website:c,turnstileToken:h})}),v=t.querySelector("[data-form-error]");if(!p.ok){const x=await p.json().catch(()=>({}));if(p.status===422&&v){v.textContent=x.message||x.error||_("enterpriseShowcase.workEmailRequired"),v.classList.remove("hidden"),a.textContent=r,a.disabled=!1;return}throw new Error}v&&v.classList.add("hidden"),a.textContent=_("enterpriseShowcase.contactSent"),a.className=a.className.replace("bg-wm-green","bg-wm-card border border-wm-green text-wm-green")}catch{a.textContent=_("enterpriseShowcase.contactFailed"),a.disabled=!1,f!=null&&f.dataset.widgetId&&window.turnstile&&(window.turnstile.reset(f.dataset.widgetId),delete f.dataset.token),setTimeout(()=>{a.textContent=r},4e3)}},children:[g.jsx("input",{type:"text",name:"website",autoComplete:"off",tabIndex:-1,"aria-hidden":"true",className:"absolute opacity-0 h-0 w-0 pointer-events-none"}),g.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[g.jsx("input",{type:"text",name:"name",placeholder:_("enterpriseShowcase.namePlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"}),g.jsx("input",{type:"email",name:"email",placeholder:_("enterpriseShowcase.emailPlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"})]}),g.jsx("span",{"data-form-error":!0,className:"hidden text-red-400 text-xs font-mono block"}),g.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[g.jsx("input",{type:"text",name:"organization",placeholder:_("enterpriseShowcase.orgPlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"}),g.jsx("input",{type:"tel",name:"phone",placeholder:_("enterpriseShowcase.phonePlaceholder"),required:!0,className:"bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono"})]}),g.jsx("textarea",{name:"message",placeholder:_("enterpriseShowcase.messagePlaceholder"),rows:4,className:"w-full bg-wm-bg border border-wm-border rounded-sm px-4 py-3 text-sm focus:outline-none focus:border-wm-green transition-colors font-mono resize-none"}),g.jsx("div",{className:"cf-turnstile mx-auto"}),g.jsx("button",{type:"submit",className:"w-full bg-wm-green text-wm-bg py-3 rounded-sm font-mono text-sm uppercase tracking-wider font-bold hover:bg-green-400 transition-colors",children:_("enterpriseShowcase.submitContact")})]})]})})]}),g.jsx("footer",{className:"border-t border-wm-border bg-[#020202] py-8 px-6 text-center",children:g.jsxs("div",{className:"flex flex-col md:flex-row items-center justify-between max-w-7xl mx-auto text-xs text-wm-muted font-mono",children:[g.jsxs("div",{className:"flex items-center gap-3 mb-4 md:mb-0",children:[g.jsx("img",{src:"/favico/favicon-32x32.png",alt:"",width:"28",height:"28",className:"rounded-full"}),g.jsxs("div",{className:"flex flex-col",children:[g.jsx("span",{className:"font-display font-bold text-sm leading-none tracking-tight text-wm-text",children:"WORLD MONITOR"}),g.jsx("span",{className:"text-[9px] uppercase tracking-[2px] opacity-60 mt-0.5",children:"by Someone.ceo"})]})]}),g.jsxs("div",{className:"flex items-center gap-6",children:[g.jsx("a",{href:"/",className:"hover:text-wm-text transition-colors",children:"Dashboard"}),g.jsx("a",{href:"https://www.worldmonitor.app/blog/",className:"hover:text-wm-text transition-colors",children:"Blog"}),g.jsx("a",{href:"https://www.worldmonitor.app/docs",className:"hover:text-wm-text transition-colors",children:"Docs"}),g.jsx("a",{href:"https://status.worldmonitor.app/",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Status"}),g.jsx("a",{href:"https://github.com/koala73/worldmonitor",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"GitHub"}),g.jsx("a",{href:"https://discord.gg/re63kWKxaz",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"Discord"}),g.jsx("a",{href:"https://x.com/worldmonitorai",target:"_blank",rel:"noreferrer",className:"hover:text-wm-text transition-colors",children:"X"})]}),g.jsxs("span",{className:"text-[10px] opacity-40 mt-4 md:mt-0",children:["© ",new Date().getFullYear()," WorldMonitor"]})]})})]});function Bk(){const[n,t]=K.useState(()=>window.location.hash.startsWith("#enterprise")?"enterprise":"home");return K.useEffect(()=>{GR(()=>{const a=document.createElement("div");Object.assign(a.style,{position:"fixed",top:"0",left:"0",right:"0",zIndex:"99999",padding:"14px 20px",background:"linear-gradient(135deg, #16a34a, #22c55e)",color:"#fff",fontWeight:"600",fontSize:"14px",textAlign:"center",boxShadow:"0 2px 12px rgba(0,0,0,0.3)",transition:"opacity 0.4s ease, transform 0.4s ease",transform:"translateY(-100%)",opacity:"0",display:"flex",alignItems:"center",justifyContent:"center",gap:"14px"});const r="https://worldmonitor.app/?wm_checkout=success";let l=!1;const c=()=>{l||(l=!0,window.location.href=r)},f=document.createElement("span");f.textContent="Payment received! Unlocking your premium features…";const h=document.createElement("button");h.type="button",h.textContent="Go to dashboard now →",Object.assign(h.style,{background:"#ffffff",color:"#16a34a",border:"none",borderRadius:"4px",padding:"6px 12px",fontSize:"12px",fontWeight:"700",cursor:"pointer",whiteSpace:"nowrap"}),h.addEventListener("click",c),a.appendChild(f),a.appendChild(h),document.body.appendChild(a),requestAnimationFrame(()=>{a.style.transform="translateY(0)",a.style.opacity="1"}),setTimeout(c,1500)}),KR()},[]),K.useEffect(()=>{const a=()=>{const r=window.location.hash,l=r.startsWith("#enterprise")?"enterprise":"home",c=n==="enterprise";t(l),l==="enterprise"&&!c&&window.scrollTo(0,0),r==="#enterprise-contact"&&setTimeout(()=>{var f;(f=document.getElementById("contact"))==null||f.scrollIntoView({behavior:"smooth"})},c?0:100)};return window.addEventListener("hashchange",a),()=>window.removeEventListener("hashchange",a)},[n]),K.useEffect(()=>{n==="enterprise"&&window.location.hash==="#enterprise-contact"&&setTimeout(()=>{var a;(a=document.getElementById("contact"))==null||a.scrollIntoView({behavior:"smooth"})},100)},[]),n==="enterprise"?g.jsx(Vk,{}):g.jsx(gk,{children:g.jsxs("div",{className:"min-h-screen selection:bg-wm-green/30 selection:text-wm-green",children:[g.jsx(xk,{}),g.jsxs("main",{children:[g.jsx(wk,{}),g.jsx(Ck,{}),g.jsx(Ak,{}),g.jsx(Ek,{}),g.jsx(Tk,{}),g.jsx(jk,{}),g.jsx(Nk,{}),g.jsx(Mk,{}),g.jsx(_k,{}),g.jsx(Dk,{}),g.jsx(lk,{refCode:Hl()}),g.jsx(kk,{}),g.jsx(Ok,{}),g.jsx(Rk,{}),g.jsx(Lk,{})]}),g.jsx(zk,{})]})})}const Uk=void 0;mD({dsn:void 0,environment:location.hostname==="worldmonitor.app"||location.hostname.endsWith(".worldmonitor.app")?"production":location.hostname.includes("vercel.app")?"preview":"development",enabled:!!Uk&&!location.hostname.startsWith("localhost"),allowUrls:[/https?:\/\/(www\.|tech\.|finance\.|commodity\.|happy\.)?worldmonitor\.app/,/https?:\/\/.*\.vercel\.app/],tracesSampleRate:.1,ignoreErrors:[/ResizeObserver loop/,/^TypeError: Load failed/,/^TypeError: Failed to fetch/,/^TypeError: NetworkError/,/Non-Error promise rejection captured with value:/]});const Pk='script[src^="https://challenges.cloudflare.com/turnstile/v0/api.js"]';BR().then(()=>{SD.createRoot(document.getElementById("root")).render(g.jsx(K.StrictMode,{children:g.jsx(Bk,{})}));const n=()=>window.turnstile?hk()>0:!1,t=document.querySelector(Pk);if(t==null||t.addEventListener("load",()=>{n()},{once:!0}),!n()){let a=0;const r=window.setInterval(()=>{(n()||++a>=20)&&window.clearInterval(r)},500)}window.addEventListener("hashchange",()=>{let a=0;const r=()=>{n()||++a>=10||setTimeout(r,200)};setTimeout(r,100)})}); diff --git a/public/pro/index.html b/public/pro/index.html index bdf36661b..430b734e6 100644 --- a/public/pro/index.html +++ b/public/pro/index.html @@ -144,7 +144,7 @@ } - + diff --git a/src/services/checkout.ts b/src/services/checkout.ts index 3b0c9601b..c505df523 100644 --- a/src/services/checkout.ts +++ b/src/services/checkout.ts @@ -164,14 +164,12 @@ export function initCheckoutOverlay(onSuccess?: () => void): void { onEvent: (event: CheckoutEvent) => { switch (event.event_type) { case 'checkout.status': { - // Dodo SDK has emitted `event.data.status` in some versions and - // `event.data.message.status` in others (the /pro build reads both - // already; main app was only reading the first, so successes went - // unnoticed whenever the SDK used the nested shape). Read both. + // Docs-documented shape is ONLY `event.data.message.status` — + // the prior top-level `event.data.status` read was a guess + // against an older SDK version and most likely never matched. + // (overlay-checkout.mdx / inline-checkout.mdx, SDK >= 0.109.2). const rawData = event.data as Record | undefined; - const status = typeof rawData?.status === 'string' - ? rawData.status - : (rawData?.message as Record | undefined)?.status; + const status = (rawData?.message as Record | undefined)?.status; if (status === 'succeeded') { successFired = true; onSuccessCallback?.(); @@ -215,6 +213,19 @@ export function initCheckoutOverlay(onSuccess?: () => void): void { clearPendingCheckoutIntent(); } break; + case 'checkout.redirect_requested': { + // With `manualRedirect: true` (below), Dodo's SDK hands the + // final navigation to the merchant via this event. Dodo's own + // redirect path (manualRedirect:false) has been observed to + // fail on Safari with an orphaned about:blank tab; we follow + // the docs-prescribed handler instead. + // (overlay-checkout.mdx: "Redirect the customer manually".) + const redirectTo = (event.data?.message as Record | undefined)?.redirect_to as string | undefined; + if (redirectTo) { + window.location.href = redirectTo; + } + break; + } case 'checkout.error': console.error('[checkout] Overlay error:', event.data?.message); Sentry.captureMessage(`Dodo checkout overlay error: ${event.data?.message || 'unknown'}`, { level: 'error', tags: { component: 'dodo-checkout' } });