@visio-io/design-system 1.5.2 → 1.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs.js CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Y=require("@mui/material/styles"),x=require("react"),_=require("@mui/material"),Ve=require("@mui/icons-material"),wd=require("@emotion/styled"),xn=require("@emotion/react"),Cd=require("react-dom");function _d(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Fe=_d(x),pe={primary:"#006399",onPrimary:"#ffffff",primaryContainer:"#cfe5ff",onPrimaryContainer:"#001d33",secondary:"#526070",onSecondary:"#ffffff",secondaryContainer:"#d5e4f7",onSecondaryContainer:"#0f1d2a",tertiary:"#68587a",onTertiary:"#ffffff",tertiaryContainer:"#eedcff",onTertiaryContainer:"#231533",error:"#ba1a1a",onError:"#ffffff",errorContainer:"#ffdad6",onErrorContainer:"#410002",surface:"#fdfcff",onSurface:"#1a1c1e",surfaceVariant:"#dee3eb",onSurfaceVariant:"#42474e",outline:"#72787e",inverseSurface:"#2f3033",inverseOnSurface:"#f1f0f4",inversePrimary:"#98cbff"},me={primary:"#98cbff",onPrimary:"#003354",primaryContainer:"#004a78",onPrimaryContainer:"#cfe5ff",secondary:"#b9c8da",onSecondary:"#233241",secondaryContainer:"#3a4a58",onSecondaryContainer:"#d5e4f7",tertiary:"#d3bee5",onTertiary:"#382a4a",tertiaryContainer:"#4f4062",onTertiaryContainer:"#eedcff",error:"#ffb4ab",onError:"#690005",errorContainer:"#93000a",onErrorContainer:"#ffdad6",surface:"#1a1c1e",onSurface:"#e2e2e6",surfaceVariant:"#42474e",onSurfaceVariant:"#c2c7cf",outline:"#8c9198",inverseSurface:"#e2e2e6",inverseOnSurface:"#2f3033",inversePrimary:"#006399"},Pe={fontFamily:'"Inter", "Helvetica", "Arial", sans-serif',fontSize:{xs:12,sm:14,md:16,lg:18,xl:20,xxl:24},fontWeight:{regular:400,medium:500,semibold:600,bold:700},lineHeight:{tight:1.2,normal:1.5,relaxed:1.7}},pc={xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,xxl:32,xxxl:64},rr={sm:4,md:8,lg:12,xl:16,pill:999},mc={shape:{borderRadius:rr.md,borderRadiusSm:rr.sm},spacing:8,components:{MuiButton:{styleOverrides:{root:{borderRadius:rr.md,fontWeight:Pe.fontWeight.medium,letterSpacing:"0.2px",textTransform:"none","&:focus-visible":{outline:"2px solid currentColor",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6}}},variants:[{props:{variant:"contained",color:"primary"},style:{boxShadow:"none"}}]}},typography:{fontFamily:Pe.fontFamily,fontWeightRegular:Pe.fontWeight.regular,fontWeightMedium:Pe.fontWeight.medium,fontWeightBold:Pe.fontWeight.bold,h1:{fontSize:Pe.fontSize.xxl,fontWeight:Pe.fontWeight.bold,lineHeight:Pe.lineHeight.tight},h2:{fontSize:Pe.fontSize.xl,fontWeight:Pe.fontWeight.bold,lineHeight:Pe.lineHeight.tight},body1:{fontSize:Pe.fontSize.md,lineHeight:Pe.lineHeight.normal},body2:{fontSize:Pe.fontSize.sm,lineHeight:Pe.lineHeight.normal},button:{fontWeight:Pe.fontWeight.semibold,textTransform:"none"}}},gc=Y.createTheme({...mc,palette:{mode:"light",primary:{main:pe.primary,contrastText:pe.onPrimary},secondary:{main:pe.secondary,contrastText:pe.onSecondary},error:{main:pe.error,contrastText:pe.onError},background:{default:pe.surface,paper:pe.surface},text:{primary:pe.onSurface,secondary:pe.onSurfaceVariant},divider:pe.outline},visio:{surfaceVariant:pe.surfaceVariant,onSurfaceVariant:pe.onSurfaceVariant,inverseSurface:pe.inverseSurface,inverseOnSurface:pe.inverseOnSurface,inversePrimary:pe.inversePrimary,outline:pe.outline,tertiary:{main:pe.tertiary,contrastText:pe.onTertiary,container:pe.tertiaryContainer,onContainer:pe.onTertiaryContainer}}}),yc=Y.createTheme({...mc,palette:{mode:"dark",primary:{main:me.primary,contrastText:me.onPrimary},secondary:{main:me.secondary,contrastText:me.onSecondary},error:{main:me.error,contrastText:me.onError},background:{default:me.surface,paper:me.surface},text:{primary:me.onSurface,secondary:me.onSurfaceVariant},divider:me.outline},visio:{surfaceVariant:me.surfaceVariant,onSurfaceVariant:me.onSurfaceVariant,inverseSurface:me.inverseSurface,inverseOnSurface:me.inverseOnSurface,inversePrimary:me.inversePrimary,outline:me.outline,tertiary:{main:me.tertiary,contrastText:me.onTertiary,container:me.tertiaryContainer,onContainer:me.onTertiaryContainer}}}),Ed=pc;function vc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xt(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Mo={exports:{}},cn={};/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const X=require("@mui/material/styles"),x=require("react"),A=require("@mui/material"),Oe=require("@mui/icons-material"),as=require("@mui/system"),cd=require("@emotion/styled");require("@emotion/react");const ld=require("react-dom");function ud(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ve=ud(x),pe={primary:"#006399",onPrimary:"#ffffff",primaryContainer:"#cfe5ff",onPrimaryContainer:"#001d33",secondary:"#526070",onSecondary:"#ffffff",secondaryContainer:"#d5e4f7",onSecondaryContainer:"#0f1d2a",tertiary:"#68587a",onTertiary:"#ffffff",tertiaryContainer:"#eedcff",onTertiaryContainer:"#231533",error:"#ba1a1a",onError:"#ffffff",errorContainer:"#ffdad6",onErrorContainer:"#410002",surface:"#fdfcff",onSurface:"#1a1c1e",surfaceVariant:"#dee3eb",onSurfaceVariant:"#42474e",outline:"#72787e",inverseSurface:"#2f3033",inverseOnSurface:"#f1f0f4",inversePrimary:"#98cbff"},ge={primary:"#98cbff",onPrimary:"#003354",primaryContainer:"#004a78",onPrimaryContainer:"#cfe5ff",secondary:"#b9c8da",onSecondary:"#233241",secondaryContainer:"#3a4a58",onSecondaryContainer:"#d5e4f7",tertiary:"#d3bee5",onTertiary:"#382a4a",tertiaryContainer:"#4f4062",onTertiaryContainer:"#eedcff",error:"#ffb4ab",onError:"#690005",errorContainer:"#93000a",onErrorContainer:"#ffdad6",surface:"#1a1c1e",onSurface:"#e2e2e6",surfaceVariant:"#42474e",onSurfaceVariant:"#c2c7cf",outline:"#8c9198",inverseSurface:"#e2e2e6",inverseOnSurface:"#2f3033",inversePrimary:"#006399"},Ee={fontFamily:'"Inter", "Helvetica", "Arial", sans-serif',fontSize:{xs:12,sm:14,md:16,lg:18,xl:20,xxl:24},fontWeight:{regular:400,medium:500,semibold:600,bold:700},lineHeight:{tight:1.2,normal:1.5,relaxed:1.7}},sc={xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,xxl:32,xxxl:64},Yn={sm:4,md:8,lg:12,xl:16,pill:999},ic={shape:{borderRadius:Yn.md,borderRadiusSm:Yn.sm},spacing:8,components:{MuiButton:{styleOverrides:{root:{borderRadius:Yn.md,fontWeight:Ee.fontWeight.medium,letterSpacing:"0.2px",textTransform:"none","&:focus-visible":{outline:"2px solid currentColor",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6}}},variants:[{props:{variant:"contained",color:"primary"},style:{boxShadow:"none"}}]}},typography:{fontFamily:Ee.fontFamily,fontWeightRegular:Ee.fontWeight.regular,fontWeightMedium:Ee.fontWeight.medium,fontWeightBold:Ee.fontWeight.bold,h1:{fontSize:Ee.fontSize.xxl,fontWeight:Ee.fontWeight.bold,lineHeight:Ee.lineHeight.tight},h2:{fontSize:Ee.fontSize.xl,fontWeight:Ee.fontWeight.bold,lineHeight:Ee.lineHeight.tight},body1:{fontSize:Ee.fontSize.md,lineHeight:Ee.lineHeight.normal},body2:{fontSize:Ee.fontSize.sm,lineHeight:Ee.lineHeight.normal},button:{fontWeight:Ee.fontWeight.semibold,textTransform:"none"}}},ac=X.createTheme({...ic,palette:{mode:"light",primary:{main:pe.primary,contrastText:pe.onPrimary},secondary:{main:pe.secondary,contrastText:pe.onSecondary},error:{main:pe.error,contrastText:pe.onError},background:{default:pe.surface,paper:pe.surface},text:{primary:pe.onSurface,secondary:pe.onSurfaceVariant},divider:pe.outline},visio:{surfaceVariant:pe.surfaceVariant,onSurfaceVariant:pe.onSurfaceVariant,inverseSurface:pe.inverseSurface,inverseOnSurface:pe.inverseOnSurface,inversePrimary:pe.inversePrimary,outline:pe.outline,tertiary:{main:pe.tertiary,contrastText:pe.onTertiary,container:pe.tertiaryContainer,onContainer:pe.onTertiaryContainer}}}),cc=X.createTheme({...ic,palette:{mode:"dark",primary:{main:ge.primary,contrastText:ge.onPrimary},secondary:{main:ge.secondary,contrastText:ge.onSecondary},error:{main:ge.error,contrastText:ge.onError},background:{default:ge.surface,paper:ge.surface},text:{primary:ge.onSurface,secondary:ge.onSurfaceVariant},divider:ge.outline},visio:{surfaceVariant:ge.surfaceVariant,onSurfaceVariant:ge.onSurfaceVariant,inverseSurface:ge.inverseSurface,inverseOnSurface:ge.inverseOnSurface,inversePrimary:ge.inversePrimary,outline:ge.outline,tertiary:{main:ge.tertiary,contrastText:ge.onTertiary,container:ge.tertiaryContainer,onContainer:ge.onTertiaryContainer}}}),dd=sc;function lc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var To={exports:{}},nn={};/**
2
2
  * @license React
3
3
  * react-jsx-runtime.production.js
4
4
  *
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var ci;function Pd(){if(ci)return cn;ci=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,s){var i=null;if(s!==void 0&&(i=""+s),o.key!==void 0&&(i=""+o.key),"key"in o){s={};for(var a in o)a!=="key"&&(s[a]=o[a])}else s=o;return o=s.ref,{$$typeof:e,type:r,key:i,ref:o!==void 0?o:null,props:s}}return cn.Fragment=t,cn.jsx=n,cn.jsxs=n,cn}var ln={};/**
9
+ */var ti;function fd(){if(ti)return nn;ti=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,s){var i=null;if(s!==void 0&&(i=""+s),o.key!==void 0&&(i=""+o.key),"key"in o){s={};for(var a in o)a!=="key"&&(s[a]=o[a])}else s=o;return o=s.ref,{$$typeof:e,type:r,key:i,ref:o!==void 0?o:null,props:s}}return nn.Fragment=t,nn.jsx=n,nn.jsxs=n,nn}var rn={};/**
10
10
  * @license React
11
11
  * react-jsx-runtime.development.js
12
12
  *
@@ -14,31 +14,31 @@
14
14
  *
15
15
  * This source code is licensed under the MIT license found in the
16
16
  * LICENSE file in the root directory of this source tree.
17
- */var li;function Ad(){return li||(li=1,process.env.NODE_ENV!=="production"&&function(){function e(w){if(w==null)return null;if(typeof w=="function")return w.$$typeof===$?null:w.displayName||w.name||null;if(typeof w=="string")return w;switch(w){case v:return"Fragment";case S:return"Profiler";case b:return"StrictMode";case E:return"Suspense";case P:return"SuspenseList";case L:return"Activity"}if(typeof w=="object")switch(typeof w.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),w.$$typeof){case h:return"Portal";case C:return w.displayName||"Context";case y:return(w._context.displayName||"Context")+".Consumer";case T:var j=w.render;return w=w.displayName,w||(w=j.displayName||j.name||"",w=w!==""?"ForwardRef("+w+")":"ForwardRef"),w;case A:return j=w.displayName||null,j!==null?j:e(w.type)||"Memo";case M:j=w._payload,w=w._init;try{return e(w(j))}catch{}}return null}function t(w){return""+w}function n(w){try{t(w);var j=!1}catch{j=!0}if(j){j=console;var k=j.error,O=typeof Symbol=="function"&&Symbol.toStringTag&&w[Symbol.toStringTag]||w.constructor.name||"Object";return k.call(j,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",O),t(w)}}function r(w){if(w===v)return"<>";if(typeof w=="object"&&w!==null&&w.$$typeof===M)return"<...>";try{var j=e(w);return j?"<"+j+">":"<...>"}catch{return"<...>"}}function o(){var w=W.A;return w===null?null:w.getOwner()}function s(){return Error("react-stack-top-frame")}function i(w){if(H.call(w,"key")){var j=Object.getOwnPropertyDescriptor(w,"key").get;if(j&&j.isReactWarning)return!1}return w.key!==void 0}function a(w,j){function k(){Q||(Q=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",j))}k.isReactWarning=!0,Object.defineProperty(w,"key",{get:k,configurable:!0})}function c(){var w=e(this.type);return U[w]||(U[w]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),w=this.props.ref,w!==void 0?w:null}function u(w,j,k,O,F,N){var V=k.ref;return w={$$typeof:m,type:w,key:j,props:k,_owner:O},(V!==void 0?V:null)!==null?Object.defineProperty(w,"ref",{enumerable:!1,get:c}):Object.defineProperty(w,"ref",{enumerable:!1,value:null}),w._store={},Object.defineProperty(w._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(w,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(w,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:F}),Object.defineProperty(w,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:N}),Object.freeze&&(Object.freeze(w.props),Object.freeze(w)),w}function l(w,j,k,O,F,N){var V=j.children;if(V!==void 0)if(O)if(q(V)){for(O=0;O<V.length;O++)d(V[O]);Object.freeze&&Object.freeze(V)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else d(V);if(H.call(j,"key")){V=e(w);var z=Object.keys(j).filter(function(K){return K!=="key"});O=0<z.length?"{key: someKey, "+z.join(": ..., ")+": ...}":"{key: someKey}",R[V+O]||(z=0<z.length?"{"+z.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
17
+ */var ni;function hd(){return ni||(ni=1,process.env.NODE_ENV!=="production"&&function(){function e(_){if(_==null)return null;if(typeof _=="function")return _.$$typeof===D?null:_.displayName||_.name||null;if(typeof _=="string")return _;switch(_){case v:return"Fragment";case T:return"Profiler";case S:return"StrictMode";case E:return"Suspense";case P:return"SuspenseList";case V:return"Activity"}if(typeof _=="object")switch(typeof _.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),_.$$typeof){case m:return"Portal";case w:return _.displayName||"Context";case b:return(_._context.displayName||"Context")+".Consumer";case C:var N=_.render;return _=_.displayName,_||(_=N.displayName||N.name||"",_=_!==""?"ForwardRef("+_+")":"ForwardRef"),_;case M:return N=_.displayName||null,N!==null?N:e(_.type)||"Memo";case I:N=_._payload,_=_._init;try{return e(_(N))}catch{}}return null}function t(_){return""+_}function n(_){try{t(_);var N=!1}catch{N=!0}if(N){N=console;var O=N.error,B=typeof Symbol=="function"&&Symbol.toStringTag&&_[Symbol.toStringTag]||_.constructor.name||"Object";return O.call(N,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",B),t(_)}}function r(_){if(_===v)return"<>";if(typeof _=="object"&&_!==null&&_.$$typeof===I)return"<...>";try{var N=e(_);return N?"<"+N+">":"<...>"}catch{return"<...>"}}function o(){var _=g.A;return _===null?null:_.getOwner()}function s(){return Error("react-stack-top-frame")}function i(_){if($.call(_,"key")){var N=Object.getOwnPropertyDescriptor(_,"key").get;if(N&&N.isReactWarning)return!1}return _.key!==void 0}function a(_,N){function O(){K||(K=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",N))}O.isReactWarning=!0,Object.defineProperty(_,"key",{get:O,configurable:!0})}function c(){var _=e(this.type);return G[_]||(G[_]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),_=this.props.ref,_!==void 0?_:null}function u(_,N,O,B,Y,U){var z=O.ref;return _={$$typeof:p,type:_,key:N,props:O,_owner:B},(z!==void 0?z:null)!==null?Object.defineProperty(_,"ref",{enumerable:!1,get:c}):Object.defineProperty(_,"ref",{enumerable:!1,value:null}),_._store={},Object.defineProperty(_._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(_,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(_,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:Y}),Object.defineProperty(_,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:U}),Object.freeze&&(Object.freeze(_.props),Object.freeze(_)),_}function l(_,N,O,B,Y,U){var z=N.children;if(z!==void 0)if(B)if(R(z)){for(B=0;B<z.length;B++)d(z[B]);Object.freeze&&Object.freeze(z)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else d(z);if($.call(N,"key")){z=e(_);var Z=Object.keys(N).filter(function(J){return J!=="key"});B=0<Z.length?"{key: someKey, "+Z.join(": ..., ")+": ...}":"{key: someKey}",L[z+B]||(Z=0<Z.length?"{"+Z.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
18
18
  let props = %s;
19
19
  <%s {...props} />
20
20
  React keys must be passed directly to JSX without using spread:
21
21
  let props = %s;
22
- <%s key={someKey} {...props} />`,O,V,z,V),R[V+O]=!0)}if(V=null,k!==void 0&&(n(k),V=""+k),i(j)&&(n(j.key),V=""+j.key),"key"in j){k={};for(var G in j)G!=="key"&&(k[G]=j[G])}else k=j;return V&&a(k,typeof w=="function"?w.displayName||w.name||"Unknown":w),u(w,V,k,o(),F,N)}function d(w){f(w)?w._store&&(w._store.validated=1):typeof w=="object"&&w!==null&&w.$$typeof===M&&(w._payload.status==="fulfilled"?f(w._payload.value)&&w._payload.value._store&&(w._payload.value._store.validated=1):w._store&&(w._store.validated=1))}function f(w){return typeof w=="object"&&w!==null&&w.$$typeof===m}var p=x,m=Symbol.for("react.transitional.element"),h=Symbol.for("react.portal"),v=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),y=Symbol.for("react.consumer"),C=Symbol.for("react.context"),T=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),P=Symbol.for("react.suspense_list"),A=Symbol.for("react.memo"),M=Symbol.for("react.lazy"),L=Symbol.for("react.activity"),$=Symbol.for("react.client.reference"),W=p.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H=Object.prototype.hasOwnProperty,q=Array.isArray,oe=console.createTask?console.createTask:function(){return null};p={react_stack_bottom_frame:function(w){return w()}};var Q,U={},I=p.react_stack_bottom_frame.bind(p,s)(),X=oe(r(s)),R={};ln.Fragment=v,ln.jsx=function(w,j,k){var O=1e4>W.recentlyCreatedOwnerStacks++;return l(w,j,k,!1,O?Error("react-stack-top-frame"):I,O?oe(r(w)):X)},ln.jsxs=function(w,j,k){var O=1e4>W.recentlyCreatedOwnerStacks++;return l(w,j,k,!0,O?Error("react-stack-top-frame"):I,O?oe(r(w)):X)}}()),ln}process.env.NODE_ENV==="production"?Mo.exports=Pd():Mo.exports=Ad();var g=Mo.exports;const bc=x.createContext(null),Md=({children:e,defaultMode:t="light",mode:n,onModeChange:r,enableCssBaseline:o=!0})=>{const[s,i]=x.useState(n??t),a=n??s;x.useEffect(()=>{n&&i(n)},[n]);const c=x.useCallback(f=>{n||i(f),r==null||r(f)},[n,r]),u=x.useCallback(()=>{c(a==="light"?"dark":"light")},[a,c]),l=x.useMemo(()=>a==="dark"?yc:gc,[a]),d=x.useMemo(()=>({mode:a,setMode:c,toggleMode:u,theme:l}),[a,c,u,l]);return g.jsx(bc.Provider,{value:d,children:g.jsxs(_.ThemeProvider,{theme:l,children:[o?g.jsx(_.CssBaseline,{}):null,e]})})},kd=()=>{const e=x.useContext(bc);if(!e)throw new Error("useVisioTheme must be used within VisioThemeProvider.");return e},Rd="_button_1x96v_1",Od="_borderRadiusNone_1x96v_8",Id="_borderRadiusSmall_1x96v_12",jd="_borderRadiusMedium_1x96v_16",Ld="_borderRadiusLarge_1x96v_20",Dd="_borderRadiusRound_1x96v_24",Pt={button:Rd,borderRadiusNone:Od,borderRadiusSmall:Id,borderRadiusMedium:jd,borderRadiusLarge:Ld,borderRadiusRound:Dd},$d=(e,t="medium")=>{const n=e??t;if(typeof n=="number")return"";switch(n){case"none":return Pt.borderRadiusNone;case"small":return Pt.borderRadiusSmall;case"medium":return Pt.borderRadiusMedium;case"large":return Pt.borderRadiusLarge;case"round":return Pt.borderRadiusRound;default:return Pt.borderRadiusMedium}},Vd=e=>{if(typeof e=="number")return`${e}px`},Nd=(e,t,n)=>{const r=n||t;if(r)return o=>{if(e){o.preventDefault();return}r(o)}},hs=x.forwardRef(({children:e,loading:t=!1,loadingText:n,startIcon:r,endIcon:o,variant:s="contained",size:i="medium",color:a="primary",borderRadius:c="medium",fullWidth:u=!1,disabled:l=!1,type:d="button",className:f,onClick:p,onAction:m,...h},v)=>{const b=l||t,S=$d(c),y=Vd(c),C=Nd(b,p,m),T=`${Pt.button} ${S} ${f||""}`.trim();return g.jsx(_.Button,{ref:v,variant:s,size:i,color:a,fullWidth:u,disabled:b,type:d,onClick:C,startIcon:t?g.jsx(_.CircularProgress,{size:i==="small"?16:i==="medium"?20:24,color:"inherit"}):r,endIcon:t?void 0:o,className:T,style:y?{borderRadius:y}:void 0,...h,children:t&&n?n:e})});hs.displayName="Button";const Bd=e=>{if(e)return t=>{e(t)}},Fd="_filterButton_8fgad_1",zd={filterButton:Fd},xc=x.forwardRef(({children:e="Filtros",onClick:t,className:n,...r},o)=>{const i=_.useTheme().palette.mode==="dark",a=Bd(t);return g.jsx(_.Button,{ref:o,variant:"outlined",onClick:a,className:`${zd.filterButton} ${n||""}`,"data-theme":i?"dark":"light",...r,children:e})});xc.displayName="FilterButton";const Wd=(e,t)=>n=>{n.stopPropagation(),t==null||t(n),e()},Ud="_filterChip_1ty7d_1",Hd="_icon_1ty7d_60",Gd="_label_1ty7d_76",Kd="_overlay_1ty7d_88",Yd="_deleteIcon_1ty7d_102",un={filterChip:Ud,icon:Hd,label:Gd,overlay:Kd,deleteIcon:Yd},Sc=({label:e,icon:t,onRemove:n,className:r,onClick:o,ref:s,...i})=>{const c=_.useTheme().palette.mode==="dark",u=Wd(n,o);return g.jsxs(_.Box,{ref:s,className:`${un.filterChip} ${r||""}`.trim(),"data-theme":c?"dark":"light",onClick:u,role:"button",tabIndex:0,onKeyDown:l=>{(l.key==="Enter"||l.key===" ")&&(l.preventDefault(),n())},"aria-label":`Remover filtro ${e}`,component:"div",...i,children:[t&&g.jsx(_.Box,{className:un.icon,component:"div",children:t}),g.jsx(_.Box,{className:un.label,component:"span",children:e}),g.jsx(_.Box,{className:un.overlay,component:"div",children:g.jsx(Ve.Delete,{className:un.deleteIcon})})]})};Sc.displayName="FilterChip";function ce(){return ce=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ce.apply(null,arguments)}function pt(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Tc(e){if(Fe.isValidElement(e)||!pt(e))return e;const t={};return Object.keys(e).forEach(n=>{t[n]=Tc(e[n])}),t}function tt(e,t,n={clone:!0}){const r=n.clone?ce({},e):e;return pt(e)&&pt(t)&&Object.keys(t).forEach(o=>{Fe.isValidElement(t[o])?r[o]=t[o]:pt(t[o])&&Object.prototype.hasOwnProperty.call(e,o)&&pt(e[o])?r[o]=tt(e[o],t[o],n):n.clone?r[o]=pt(t[o])?Tc(t[o]):t[o]:r[o]=t[o]}),r}const qd=Object.freeze(Object.defineProperty({__proto__:null,default:tt,isPlainObject:pt},Symbol.toStringTag,{value:"Module"}));var ko={exports:{}},Gn={exports:{}},ne={};/** @license React v16.13.1
22
+ <%s key={someKey} {...props} />`,B,z,Z,z),L[z+B]=!0)}if(z=null,O!==void 0&&(n(O),z=""+O),i(N)&&(n(N.key),z=""+N.key),"key"in N){O={};for(var q in N)q!=="key"&&(O[q]=N[q])}else O=N;return z&&a(O,typeof _=="function"?_.displayName||_.name||"Unknown":_),u(_,z,O,o(),Y,U)}function d(_){f(_)?_._store&&(_._store.validated=1):typeof _=="object"&&_!==null&&_.$$typeof===I&&(_._payload.status==="fulfilled"?f(_._payload.value)&&_._payload.value._store&&(_._payload.value._store.validated=1):_._store&&(_._store.validated=1))}function f(_){return typeof _=="object"&&_!==null&&_.$$typeof===p}var h=x,p=Symbol.for("react.transitional.element"),m=Symbol.for("react.portal"),v=Symbol.for("react.fragment"),S=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),b=Symbol.for("react.consumer"),w=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),P=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),I=Symbol.for("react.lazy"),V=Symbol.for("react.activity"),D=Symbol.for("react.client.reference"),g=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,$=Object.prototype.hasOwnProperty,R=Array.isArray,W=console.createTask?console.createTask:function(){return null};h={react_stack_bottom_frame:function(_){return _()}};var K,G={},j=h.react_stack_bottom_frame.bind(h,s)(),Q=W(r(s)),L={};rn.Fragment=v,rn.jsx=function(_,N,O){var B=1e4>g.recentlyCreatedOwnerStacks++;return l(_,N,O,!1,B?Error("react-stack-top-frame"):j,B?W(r(_)):Q)},rn.jsxs=function(_,N,O){var B=1e4>g.recentlyCreatedOwnerStacks++;return l(_,N,O,!0,B?Error("react-stack-top-frame"):j,B?W(r(_)):Q)}}()),rn}process.env.NODE_ENV==="production"?To.exports=fd():To.exports=hd();var y=To.exports;const uc=x.createContext(null),md=({children:e,defaultMode:t="light",mode:n,onModeChange:r,enableCssBaseline:o=!0})=>{const[s,i]=x.useState(n??t),a=n??s;x.useEffect(()=>{n&&i(n)},[n]);const c=x.useCallback(f=>{n||i(f),r==null||r(f)},[n,r]),u=x.useCallback(()=>{c(a==="light"?"dark":"light")},[a,c]),l=x.useMemo(()=>a==="dark"?cc:ac,[a]),d=x.useMemo(()=>({mode:a,setMode:c,toggleMode:u,theme:l}),[a,c,u,l]);return y.jsx(uc.Provider,{value:d,children:y.jsxs(A.ThemeProvider,{theme:l,children:[o?y.jsx(A.CssBaseline,{}):null,e]})})},pd=()=>{const e=x.useContext(uc);if(!e)throw new Error("useVisioTheme must be used within VisioThemeProvider.");return e},gd="_button_1x96v_1",yd="_borderRadiusNone_1x96v_8",vd="_borderRadiusSmall_1x96v_12",bd="_borderRadiusMedium_1x96v_16",xd="_borderRadiusLarge_1x96v_20",Sd="_borderRadiusRound_1x96v_24",wt={button:gd,borderRadiusNone:yd,borderRadiusSmall:vd,borderRadiusMedium:bd,borderRadiusLarge:xd,borderRadiusRound:Sd},Td=(e,t="medium")=>{const n=e??t;if(typeof n=="number")return"";switch(n){case"none":return wt.borderRadiusNone;case"small":return wt.borderRadiusSmall;case"medium":return wt.borderRadiusMedium;case"large":return wt.borderRadiusLarge;case"round":return wt.borderRadiusRound;default:return wt.borderRadiusMedium}},Cd=e=>{if(typeof e=="number")return`${e}px`},wd=(e,t,n)=>{const r=n||t;if(r)return o=>{if(e){o.preventDefault();return}r(o)}},cs=x.forwardRef(({children:e,loading:t=!1,loadingText:n,startIcon:r,endIcon:o,variant:s="contained",size:i="medium",color:a="primary",borderRadius:c="medium",fullWidth:u=!1,disabled:l=!1,type:d="button",className:f,onClick:h,onAction:p,...m},v)=>{const S=l||t,T=Td(c),b=Cd(c),w=wd(S,h,p),C=`${wt.button} ${T} ${f||""}`.trim();return y.jsx(A.Button,{ref:v,variant:s,size:i,color:a,fullWidth:u,disabled:S,type:d,onClick:w,startIcon:t?y.jsx(A.CircularProgress,{size:i==="small"?16:i==="medium"?20:24,color:"inherit"}):r,endIcon:t?void 0:o,className:C,style:b?{borderRadius:b}:void 0,...m,children:t&&n?n:e})});cs.displayName="Button";const _d=e=>{if(e)return t=>{e(t)}},Ed="_filterButton_8fgad_1",Ad={filterButton:Ed},dc=x.forwardRef(({children:e="Filtros",onClick:t,className:n,...r},o)=>{const i=A.useTheme().palette.mode==="dark",a=_d(t);return y.jsx(A.Button,{ref:o,variant:"outlined",onClick:a,className:`${Ad.filterButton} ${n||""}`,"data-theme":i?"dark":"light",...r,children:e})});dc.displayName="FilterButton";const Md=(e,t)=>n=>{n.stopPropagation(),t==null||t(n),e()},Pd="_filterChip_1ty7d_1",kd="_icon_1ty7d_60",Id="_label_1ty7d_76",Rd="_overlay_1ty7d_88",Od="_deleteIcon_1ty7d_102",on={filterChip:Pd,icon:kd,label:Id,overlay:Rd,deleteIcon:Od},fc=({label:e,icon:t,onRemove:n,className:r,onClick:o,ref:s,...i})=>{const c=A.useTheme().palette.mode==="dark",u=Md(n,o);return y.jsxs(A.Box,{ref:s,className:`${on.filterChip} ${r||""}`.trim(),"data-theme":c?"dark":"light",onClick:u,role:"button",tabIndex:0,onKeyDown:l=>{(l.key==="Enter"||l.key===" ")&&(l.preventDefault(),n())},"aria-label":`Remover filtro ${e}`,component:"div",...i,children:[t&&y.jsx(A.Box,{className:on.icon,component:"div",children:t}),y.jsx(A.Box,{className:on.label,component:"span",children:e}),y.jsx(A.Box,{className:on.overlay,component:"div",children:y.jsx(Oe.Delete,{className:on.deleteIcon})})]})};fc.displayName="FilterChip";const ri=e=>e,Ld=()=>{let e=ri;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ri}}},Dd=Ld();function ht(e,...t){const n=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(r=>n.searchParams.append("args[]",r)),`Minified MUI error #${e}; visit ${n} for the full message.`}function It(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":ht(7));return e.charAt(0).toUpperCase()+e.slice(1)}var Co={exports:{}},jn={exports:{}},ne={};/** @license React v16.13.1
23
23
  * react-is.production.min.js
24
24
  *
25
25
  * Copyright (c) Facebook, Inc. and its affiliates.
26
26
  *
27
27
  * This source code is licensed under the MIT license found in the
28
28
  * LICENSE file in the root directory of this source tree.
29
- */var ui;function Zd(){if(ui)return ne;ui=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,l=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,h=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,b=e?Symbol.for("react.responder"):60118,S=e?Symbol.for("react.scope"):60119;function y(T){if(typeof T=="object"&&T!==null){var E=T.$$typeof;switch(E){case t:switch(T=T.type,T){case c:case u:case r:case s:case o:case d:return T;default:switch(T=T&&T.$$typeof,T){case a:case l:case m:case p:case i:return T;default:return E}}case n:return E}}}function C(T){return y(T)===u}return ne.AsyncMode=c,ne.ConcurrentMode=u,ne.ContextConsumer=a,ne.ContextProvider=i,ne.Element=t,ne.ForwardRef=l,ne.Fragment=r,ne.Lazy=m,ne.Memo=p,ne.Portal=n,ne.Profiler=s,ne.StrictMode=o,ne.Suspense=d,ne.isAsyncMode=function(T){return C(T)||y(T)===c},ne.isConcurrentMode=C,ne.isContextConsumer=function(T){return y(T)===a},ne.isContextProvider=function(T){return y(T)===i},ne.isElement=function(T){return typeof T=="object"&&T!==null&&T.$$typeof===t},ne.isForwardRef=function(T){return y(T)===l},ne.isFragment=function(T){return y(T)===r},ne.isLazy=function(T){return y(T)===m},ne.isMemo=function(T){return y(T)===p},ne.isPortal=function(T){return y(T)===n},ne.isProfiler=function(T){return y(T)===s},ne.isStrictMode=function(T){return y(T)===o},ne.isSuspense=function(T){return y(T)===d},ne.isValidElementType=function(T){return typeof T=="string"||typeof T=="function"||T===r||T===u||T===s||T===o||T===d||T===f||typeof T=="object"&&T!==null&&(T.$$typeof===m||T.$$typeof===p||T.$$typeof===i||T.$$typeof===a||T.$$typeof===l||T.$$typeof===v||T.$$typeof===b||T.$$typeof===S||T.$$typeof===h)},ne.typeOf=y,ne}var re={};/** @license React v16.13.1
29
+ */var oi;function jd(){if(oi)return ne;oi=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,l=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,T=e?Symbol.for("react.scope"):60119;function b(C){if(typeof C=="object"&&C!==null){var E=C.$$typeof;switch(E){case t:switch(C=C.type,C){case c:case u:case r:case s:case o:case d:return C;default:switch(C=C&&C.$$typeof,C){case a:case l:case p:case h:case i:return C;default:return E}}case n:return E}}}function w(C){return b(C)===u}return ne.AsyncMode=c,ne.ConcurrentMode=u,ne.ContextConsumer=a,ne.ContextProvider=i,ne.Element=t,ne.ForwardRef=l,ne.Fragment=r,ne.Lazy=p,ne.Memo=h,ne.Portal=n,ne.Profiler=s,ne.StrictMode=o,ne.Suspense=d,ne.isAsyncMode=function(C){return w(C)||b(C)===c},ne.isConcurrentMode=w,ne.isContextConsumer=function(C){return b(C)===a},ne.isContextProvider=function(C){return b(C)===i},ne.isElement=function(C){return typeof C=="object"&&C!==null&&C.$$typeof===t},ne.isForwardRef=function(C){return b(C)===l},ne.isFragment=function(C){return b(C)===r},ne.isLazy=function(C){return b(C)===p},ne.isMemo=function(C){return b(C)===h},ne.isPortal=function(C){return b(C)===n},ne.isProfiler=function(C){return b(C)===s},ne.isStrictMode=function(C){return b(C)===o},ne.isSuspense=function(C){return b(C)===d},ne.isValidElementType=function(C){return typeof C=="string"||typeof C=="function"||C===r||C===u||C===s||C===o||C===d||C===f||typeof C=="object"&&C!==null&&(C.$$typeof===p||C.$$typeof===h||C.$$typeof===i||C.$$typeof===a||C.$$typeof===l||C.$$typeof===v||C.$$typeof===S||C.$$typeof===T||C.$$typeof===m)},ne.typeOf=b,ne}var re={};/** @license React v16.13.1
30
30
  * react-is.development.js
31
31
  *
32
32
  * Copyright (c) Facebook, Inc. and its affiliates.
33
33
  *
34
34
  * This source code is licensed under the MIT license found in the
35
35
  * LICENSE file in the root directory of this source tree.
36
- */var di;function Xd(){return di||(di=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,l=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,h=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,b=e?Symbol.for("react.responder"):60118,S=e?Symbol.for("react.scope"):60119;function y(D){return typeof D=="string"||typeof D=="function"||D===r||D===u||D===s||D===o||D===d||D===f||typeof D=="object"&&D!==null&&(D.$$typeof===m||D.$$typeof===p||D.$$typeof===i||D.$$typeof===a||D.$$typeof===l||D.$$typeof===v||D.$$typeof===b||D.$$typeof===S||D.$$typeof===h)}function C(D){if(typeof D=="object"&&D!==null){var Ee=D.$$typeof;switch(Ee){case t:var Xe=D.type;switch(Xe){case c:case u:case r:case s:case o:case d:return Xe;default:var ft=Xe&&Xe.$$typeof;switch(ft){case a:case l:case m:case p:case i:return ft;default:return Ee}}case n:return Ee}}}var T=c,E=u,P=a,A=i,M=t,L=l,$=r,W=m,H=p,q=n,oe=s,Q=o,U=d,I=!1;function X(D){return I||(I=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),R(D)||C(D)===c}function R(D){return C(D)===u}function w(D){return C(D)===a}function j(D){return C(D)===i}function k(D){return typeof D=="object"&&D!==null&&D.$$typeof===t}function O(D){return C(D)===l}function F(D){return C(D)===r}function N(D){return C(D)===m}function V(D){return C(D)===p}function z(D){return C(D)===n}function G(D){return C(D)===s}function K(D){return C(D)===o}function he(D){return C(D)===d}re.AsyncMode=T,re.ConcurrentMode=E,re.ContextConsumer=P,re.ContextProvider=A,re.Element=M,re.ForwardRef=L,re.Fragment=$,re.Lazy=W,re.Memo=H,re.Portal=q,re.Profiler=oe,re.StrictMode=Q,re.Suspense=U,re.isAsyncMode=X,re.isConcurrentMode=R,re.isContextConsumer=w,re.isContextProvider=j,re.isElement=k,re.isForwardRef=O,re.isFragment=F,re.isLazy=N,re.isMemo=V,re.isPortal=z,re.isProfiler=G,re.isStrictMode=K,re.isSuspense=he,re.isValidElementType=y,re.typeOf=C}()),re}var fi;function wc(){return fi||(fi=1,process.env.NODE_ENV==="production"?Gn.exports=Zd():Gn.exports=Xd()),Gn.exports}/*
36
+ */var si;function Bd(){return si||(si=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,l=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,T=e?Symbol.for("react.scope"):60119;function b(F){return typeof F=="string"||typeof F=="function"||F===r||F===u||F===s||F===o||F===d||F===f||typeof F=="object"&&F!==null&&(F.$$typeof===p||F.$$typeof===h||F.$$typeof===i||F.$$typeof===a||F.$$typeof===l||F.$$typeof===v||F.$$typeof===S||F.$$typeof===T||F.$$typeof===m)}function w(F){if(typeof F=="object"&&F!==null){var _e=F.$$typeof;switch(_e){case t:var Ue=F.type;switch(Ue){case c:case u:case r:case s:case o:case d:return Ue;default:var it=Ue&&Ue.$$typeof;switch(it){case a:case l:case p:case h:case i:return it;default:return _e}}case n:return _e}}}var C=c,E=u,P=a,M=i,I=t,V=l,D=r,g=p,$=h,R=n,W=s,K=o,G=d,j=!1;function Q(F){return j||(j=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),L(F)||w(F)===c}function L(F){return w(F)===u}function _(F){return w(F)===a}function N(F){return w(F)===i}function O(F){return typeof F=="object"&&F!==null&&F.$$typeof===t}function B(F){return w(F)===l}function Y(F){return w(F)===r}function U(F){return w(F)===p}function z(F){return w(F)===h}function Z(F){return w(F)===n}function q(F){return w(F)===s}function J(F){return w(F)===o}function me(F){return w(F)===d}re.AsyncMode=C,re.ConcurrentMode=E,re.ContextConsumer=P,re.ContextProvider=M,re.Element=I,re.ForwardRef=V,re.Fragment=D,re.Lazy=g,re.Memo=$,re.Portal=R,re.Profiler=W,re.StrictMode=K,re.Suspense=G,re.isAsyncMode=Q,re.isConcurrentMode=L,re.isContextConsumer=_,re.isContextProvider=N,re.isElement=O,re.isForwardRef=B,re.isFragment=Y,re.isLazy=U,re.isMemo=z,re.isPortal=Z,re.isProfiler=q,re.isStrictMode=J,re.isSuspense=me,re.isValidElementType=b,re.typeOf=w}()),re}var ii;function hc(){return ii||(ii=1,process.env.NODE_ENV==="production"?jn.exports=jd():jn.exports=Bd()),jn.exports}/*
37
37
  object-assign
38
38
  (c) Sindre Sorhus
39
39
  @license MIT
40
- */var Xr,hi;function Jd(){if(hi)return Xr;hi=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},a=0;a<10;a++)i["_"+String.fromCharCode(a)]=a;var c=Object.getOwnPropertyNames(i).map(function(l){return i[l]});if(c.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(l){u[l]=l}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Xr=o()?Object.assign:function(s,i){for(var a,c=r(s),u,l=1;l<arguments.length;l++){a=Object(arguments[l]);for(var d in a)t.call(a,d)&&(c[d]=a[d]);if(e){u=e(a);for(var f=0;f<u.length;f++)n.call(a,u[f])&&(c[u[f]]=a[u[f]])}}return c},Xr}var Jr,pi;function ps(){if(pi)return Jr;pi=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Jr=e,Jr}var Qr,mi;function Cc(){return mi||(mi=1,Qr=Function.call.bind(Object.prototype.hasOwnProperty)),Qr}var eo,gi;function Qd(){if(gi)return eo;gi=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=ps(),n={},r=Cc();e=function(s){var i="Warning: "+s;typeof console<"u"&&console.error(i);try{throw new Error(i)}catch{}}}function o(s,i,a,c,u){if(process.env.NODE_ENV!=="production"){for(var l in s)if(r(s,l)){var d;try{if(typeof s[l]!="function"){var f=Error((c||"React class")+": "+a+" type `"+l+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof s[l]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=s[l](i,l,c,a,null,t)}catch(m){d=m}if(d&&!(d instanceof Error)&&e((c||"React class")+": type specification of "+a+" `"+l+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in n)){n[d.message]=!0;var p=u?u():"";e("Failed "+a+" type: "+d.message+(p??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},eo=o,eo}var to,yi;function ef(){if(yi)return to;yi=1;var e=wc(),t=Jd(),n=ps(),r=Cc(),o=Qd(),s=function(){};process.env.NODE_ENV!=="production"&&(s=function(a){var c="Warning: "+a;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function i(){return null}return to=function(a,c){var u=typeof Symbol=="function"&&Symbol.iterator,l="@@iterator";function d(R){var w=R&&(u&&R[u]||R[l]);if(typeof w=="function")return w}var f="<<anonymous>>",p={array:b("array"),bigint:b("bigint"),bool:b("boolean"),func:b("function"),number:b("number"),object:b("object"),string:b("string"),symbol:b("symbol"),any:S(),arrayOf:y,element:C(),elementType:T(),instanceOf:E,node:L(),objectOf:A,oneOf:P,oneOfType:M,shape:W,exact:H};function m(R,w){return R===w?R!==0||1/R===1/w:R!==R&&w!==w}function h(R,w){this.message=R,this.data=w&&typeof w=="object"?w:{},this.stack=""}h.prototype=Error.prototype;function v(R){if(process.env.NODE_ENV!=="production")var w={},j=0;function k(F,N,V,z,G,K,he){if(z=z||f,K=K||V,he!==n){if(c){var D=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw D.name="Invariant Violation",D}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Ee=z+":"+V;!w[Ee]&&j<3&&(s("You are manually calling a React.PropTypes validation function for the `"+K+"` prop on `"+z+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),w[Ee]=!0,j++)}}return N[V]==null?F?N[V]===null?new h("The "+G+" `"+K+"` is marked as required "+("in `"+z+"`, but its value is `null`.")):new h("The "+G+" `"+K+"` is marked as required in "+("`"+z+"`, but its value is `undefined`.")):null:R(N,V,z,G,K)}var O=k.bind(null,!1);return O.isRequired=k.bind(null,!0),O}function b(R){function w(j,k,O,F,N,V){var z=j[k],G=Q(z);if(G!==R){var K=U(z);return new h("Invalid "+F+" `"+N+"` of type "+("`"+K+"` supplied to `"+O+"`, expected ")+("`"+R+"`."),{expectedType:R})}return null}return v(w)}function S(){return v(i)}function y(R){function w(j,k,O,F,N){if(typeof R!="function")return new h("Property `"+N+"` of component `"+O+"` has invalid PropType notation inside arrayOf.");var V=j[k];if(!Array.isArray(V)){var z=Q(V);return new h("Invalid "+F+" `"+N+"` of type "+("`"+z+"` supplied to `"+O+"`, expected an array."))}for(var G=0;G<V.length;G++){var K=R(V,G,O,F,N+"["+G+"]",n);if(K instanceof Error)return K}return null}return v(w)}function C(){function R(w,j,k,O,F){var N=w[j];if(!a(N)){var V=Q(N);return new h("Invalid "+O+" `"+F+"` of type "+("`"+V+"` supplied to `"+k+"`, expected a single ReactElement."))}return null}return v(R)}function T(){function R(w,j,k,O,F){var N=w[j];if(!e.isValidElementType(N)){var V=Q(N);return new h("Invalid "+O+" `"+F+"` of type "+("`"+V+"` supplied to `"+k+"`, expected a single ReactElement type."))}return null}return v(R)}function E(R){function w(j,k,O,F,N){if(!(j[k]instanceof R)){var V=R.name||f,z=X(j[k]);return new h("Invalid "+F+" `"+N+"` of type "+("`"+z+"` supplied to `"+O+"`, expected ")+("instance of `"+V+"`."))}return null}return v(w)}function P(R){if(!Array.isArray(R))return process.env.NODE_ENV!=="production"&&(arguments.length>1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function w(j,k,O,F,N){for(var V=j[k],z=0;z<R.length;z++)if(m(V,R[z]))return null;var G=JSON.stringify(R,function(he,D){var Ee=U(D);return Ee==="symbol"?String(D):D});return new h("Invalid "+F+" `"+N+"` of value `"+String(V)+"` "+("supplied to `"+O+"`, expected one of "+G+"."))}return v(w)}function A(R){function w(j,k,O,F,N){if(typeof R!="function")return new h("Property `"+N+"` of component `"+O+"` has invalid PropType notation inside objectOf.");var V=j[k],z=Q(V);if(z!=="object")return new h("Invalid "+F+" `"+N+"` of type "+("`"+z+"` supplied to `"+O+"`, expected an object."));for(var G in V)if(r(V,G)){var K=R(V,G,O,F,N+"."+G,n);if(K instanceof Error)return K}return null}return v(w)}function M(R){if(!Array.isArray(R))return process.env.NODE_ENV!=="production"&&s("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var w=0;w<R.length;w++){var j=R[w];if(typeof j!="function")return s("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+I(j)+" at index "+w+"."),i}function k(O,F,N,V,z){for(var G=[],K=0;K<R.length;K++){var he=R[K],D=he(O,F,N,V,z,n);if(D==null)return null;D.data&&r(D.data,"expectedType")&&G.push(D.data.expectedType)}var Ee=G.length>0?", expected one of type ["+G.join(", ")+"]":"";return new h("Invalid "+V+" `"+z+"` supplied to "+("`"+N+"`"+Ee+"."))}return v(k)}function L(){function R(w,j,k,O,F){return q(w[j])?null:new h("Invalid "+O+" `"+F+"` supplied to "+("`"+k+"`, expected a ReactNode."))}return v(R)}function $(R,w,j,k,O){return new h((R||"React class")+": "+w+" type `"+j+"."+k+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+O+"`.")}function W(R){function w(j,k,O,F,N){var V=j[k],z=Q(V);if(z!=="object")return new h("Invalid "+F+" `"+N+"` of type `"+z+"` "+("supplied to `"+O+"`, expected `object`."));for(var G in R){var K=R[G];if(typeof K!="function")return $(O,F,N,G,U(K));var he=K(V,G,O,F,N+"."+G,n);if(he)return he}return null}return v(w)}function H(R){function w(j,k,O,F,N){var V=j[k],z=Q(V);if(z!=="object")return new h("Invalid "+F+" `"+N+"` of type `"+z+"` "+("supplied to `"+O+"`, expected `object`."));var G=t({},j[k],R);for(var K in G){var he=R[K];if(r(R,K)&&typeof he!="function")return $(O,F,N,K,U(he));if(!he)return new h("Invalid "+F+" `"+N+"` key `"+K+"` supplied to `"+O+"`.\nBad object: "+JSON.stringify(j[k],null," ")+`
41
- Valid keys: `+JSON.stringify(Object.keys(R),null," "));var D=he(V,K,O,F,N+"."+K,n);if(D)return D}return null}return v(w)}function q(R){switch(typeof R){case"number":case"string":case"undefined":return!0;case"boolean":return!R;case"object":if(Array.isArray(R))return R.every(q);if(R===null||a(R))return!0;var w=d(R);if(w){var j=w.call(R),k;if(w!==R.entries){for(;!(k=j.next()).done;)if(!q(k.value))return!1}else for(;!(k=j.next()).done;){var O=k.value;if(O&&!q(O[1]))return!1}}else return!1;return!0;default:return!1}}function oe(R,w){return R==="symbol"?!0:w?w["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&w instanceof Symbol:!1}function Q(R){var w=typeof R;return Array.isArray(R)?"array":R instanceof RegExp?"object":oe(w,R)?"symbol":w}function U(R){if(typeof R>"u"||R===null)return""+R;var w=Q(R);if(w==="object"){if(R instanceof Date)return"date";if(R instanceof RegExp)return"regexp"}return w}function I(R){var w=U(R);switch(w){case"array":case"object":return"an "+w;case"boolean":case"date":case"regexp":return"a "+w;default:return w}}function X(R){return!R.constructor||!R.constructor.name?f:R.constructor.name}return p.checkPropTypes=o,p.resetWarningCache=o.resetWarningCache,p.PropTypes=p,p},to}var no,vi;function tf(){if(vi)return no;vi=1;var e=ps();function t(){}function n(){}return n.resetWarningCache=t,no=function(){function r(i,a,c,u,l,d){if(d!==e){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},no}if(process.env.NODE_ENV!=="production"){var nf=wc(),rf=!0;ko.exports=ef()(nf.isElement,rf)}else ko.exports=tf()();var of=ko.exports;const Z=vc(of);function _n(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n<arguments.length;n+=1)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified MUI error #"+e+"; visit "+t+" for the full message."}const sf=Object.freeze(Object.defineProperty({__proto__:null,default:_n},Symbol.toStringTag,{value:"Module"}));var Ro={exports:{}},se={};/**
40
+ */var Vr,ai;function $d(){if(ai)return Vr;ai=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},a=0;a<10;a++)i["_"+String.fromCharCode(a)]=a;var c=Object.getOwnPropertyNames(i).map(function(l){return i[l]});if(c.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(l){u[l]=l}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Vr=o()?Object.assign:function(s,i){for(var a,c=r(s),u,l=1;l<arguments.length;l++){a=Object(arguments[l]);for(var d in a)t.call(a,d)&&(c[d]=a[d]);if(e){u=e(a);for(var f=0;f<u.length;f++)n.call(a,u[f])&&(c[u[f]]=a[u[f]])}}return c},Vr}var Fr,ci;function ls(){if(ci)return Fr;ci=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Fr=e,Fr}var zr,li;function mc(){return li||(li=1,zr=Function.call.bind(Object.prototype.hasOwnProperty)),zr}var Wr,ui;function Nd(){if(ui)return Wr;ui=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=ls(),n={},r=mc();e=function(s){var i="Warning: "+s;typeof console<"u"&&console.error(i);try{throw new Error(i)}catch{}}}function o(s,i,a,c,u){if(process.env.NODE_ENV!=="production"){for(var l in s)if(r(s,l)){var d;try{if(typeof s[l]!="function"){var f=Error((c||"React class")+": "+a+" type `"+l+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof s[l]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=s[l](i,l,c,a,null,t)}catch(p){d=p}if(d&&!(d instanceof Error)&&e((c||"React class")+": type specification of "+a+" `"+l+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in n)){n[d.message]=!0;var h=u?u():"";e("Failed "+a+" type: "+d.message+(h??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},Wr=o,Wr}var Ur,di;function Vd(){if(di)return Ur;di=1;var e=hc(),t=$d(),n=ls(),r=mc(),o=Nd(),s=function(){};process.env.NODE_ENV!=="production"&&(s=function(a){var c="Warning: "+a;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function i(){return null}return Ur=function(a,c){var u=typeof Symbol=="function"&&Symbol.iterator,l="@@iterator";function d(L){var _=L&&(u&&L[u]||L[l]);if(typeof _=="function")return _}var f="<<anonymous>>",h={array:S("array"),bigint:S("bigint"),bool:S("boolean"),func:S("function"),number:S("number"),object:S("object"),string:S("string"),symbol:S("symbol"),any:T(),arrayOf:b,element:w(),elementType:C(),instanceOf:E,node:V(),objectOf:M,oneOf:P,oneOfType:I,shape:g,exact:$};function p(L,_){return L===_?L!==0||1/L===1/_:L!==L&&_!==_}function m(L,_){this.message=L,this.data=_&&typeof _=="object"?_:{},this.stack=""}m.prototype=Error.prototype;function v(L){if(process.env.NODE_ENV!=="production")var _={},N=0;function O(Y,U,z,Z,q,J,me){if(Z=Z||f,J=J||z,me!==n){if(c){var F=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw F.name="Invariant Violation",F}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var _e=Z+":"+z;!_[_e]&&N<3&&(s("You are manually calling a React.PropTypes validation function for the `"+J+"` prop on `"+Z+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),_[_e]=!0,N++)}}return U[z]==null?Y?U[z]===null?new m("The "+q+" `"+J+"` is marked as required "+("in `"+Z+"`, but its value is `null`.")):new m("The "+q+" `"+J+"` is marked as required in "+("`"+Z+"`, but its value is `undefined`.")):null:L(U,z,Z,q,J)}var B=O.bind(null,!1);return B.isRequired=O.bind(null,!0),B}function S(L){function _(N,O,B,Y,U,z){var Z=N[O],q=K(Z);if(q!==L){var J=G(Z);return new m("Invalid "+Y+" `"+U+"` of type "+("`"+J+"` supplied to `"+B+"`, expected ")+("`"+L+"`."),{expectedType:L})}return null}return v(_)}function T(){return v(i)}function b(L){function _(N,O,B,Y,U){if(typeof L!="function")return new m("Property `"+U+"` of component `"+B+"` has invalid PropType notation inside arrayOf.");var z=N[O];if(!Array.isArray(z)){var Z=K(z);return new m("Invalid "+Y+" `"+U+"` of type "+("`"+Z+"` supplied to `"+B+"`, expected an array."))}for(var q=0;q<z.length;q++){var J=L(z,q,B,Y,U+"["+q+"]",n);if(J instanceof Error)return J}return null}return v(_)}function w(){function L(_,N,O,B,Y){var U=_[N];if(!a(U)){var z=K(U);return new m("Invalid "+B+" `"+Y+"` of type "+("`"+z+"` supplied to `"+O+"`, expected a single ReactElement."))}return null}return v(L)}function C(){function L(_,N,O,B,Y){var U=_[N];if(!e.isValidElementType(U)){var z=K(U);return new m("Invalid "+B+" `"+Y+"` of type "+("`"+z+"` supplied to `"+O+"`, expected a single ReactElement type."))}return null}return v(L)}function E(L){function _(N,O,B,Y,U){if(!(N[O]instanceof L)){var z=L.name||f,Z=Q(N[O]);return new m("Invalid "+Y+" `"+U+"` of type "+("`"+Z+"` supplied to `"+B+"`, expected ")+("instance of `"+z+"`."))}return null}return v(_)}function P(L){if(!Array.isArray(L))return process.env.NODE_ENV!=="production"&&(arguments.length>1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function _(N,O,B,Y,U){for(var z=N[O],Z=0;Z<L.length;Z++)if(p(z,L[Z]))return null;var q=JSON.stringify(L,function(me,F){var _e=G(F);return _e==="symbol"?String(F):F});return new m("Invalid "+Y+" `"+U+"` of value `"+String(z)+"` "+("supplied to `"+B+"`, expected one of "+q+"."))}return v(_)}function M(L){function _(N,O,B,Y,U){if(typeof L!="function")return new m("Property `"+U+"` of component `"+B+"` has invalid PropType notation inside objectOf.");var z=N[O],Z=K(z);if(Z!=="object")return new m("Invalid "+Y+" `"+U+"` of type "+("`"+Z+"` supplied to `"+B+"`, expected an object."));for(var q in z)if(r(z,q)){var J=L(z,q,B,Y,U+"."+q,n);if(J instanceof Error)return J}return null}return v(_)}function I(L){if(!Array.isArray(L))return process.env.NODE_ENV!=="production"&&s("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var _=0;_<L.length;_++){var N=L[_];if(typeof N!="function")return s("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+j(N)+" at index "+_+"."),i}function O(B,Y,U,z,Z){for(var q=[],J=0;J<L.length;J++){var me=L[J],F=me(B,Y,U,z,Z,n);if(F==null)return null;F.data&&r(F.data,"expectedType")&&q.push(F.data.expectedType)}var _e=q.length>0?", expected one of type ["+q.join(", ")+"]":"";return new m("Invalid "+z+" `"+Z+"` supplied to "+("`"+U+"`"+_e+"."))}return v(O)}function V(){function L(_,N,O,B,Y){return R(_[N])?null:new m("Invalid "+B+" `"+Y+"` supplied to "+("`"+O+"`, expected a ReactNode."))}return v(L)}function D(L,_,N,O,B){return new m((L||"React class")+": "+_+" type `"+N+"."+O+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function g(L){function _(N,O,B,Y,U){var z=N[O],Z=K(z);if(Z!=="object")return new m("Invalid "+Y+" `"+U+"` of type `"+Z+"` "+("supplied to `"+B+"`, expected `object`."));for(var q in L){var J=L[q];if(typeof J!="function")return D(B,Y,U,q,G(J));var me=J(z,q,B,Y,U+"."+q,n);if(me)return me}return null}return v(_)}function $(L){function _(N,O,B,Y,U){var z=N[O],Z=K(z);if(Z!=="object")return new m("Invalid "+Y+" `"+U+"` of type `"+Z+"` "+("supplied to `"+B+"`, expected `object`."));var q=t({},N[O],L);for(var J in q){var me=L[J];if(r(L,J)&&typeof me!="function")return D(B,Y,U,J,G(me));if(!me)return new m("Invalid "+Y+" `"+U+"` key `"+J+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(N[O],null," ")+`
41
+ Valid keys: `+JSON.stringify(Object.keys(L),null," "));var F=me(z,J,B,Y,U+"."+J,n);if(F)return F}return null}return v(_)}function R(L){switch(typeof L){case"number":case"string":case"undefined":return!0;case"boolean":return!L;case"object":if(Array.isArray(L))return L.every(R);if(L===null||a(L))return!0;var _=d(L);if(_){var N=_.call(L),O;if(_!==L.entries){for(;!(O=N.next()).done;)if(!R(O.value))return!1}else for(;!(O=N.next()).done;){var B=O.value;if(B&&!R(B[1]))return!1}}else return!1;return!0;default:return!1}}function W(L,_){return L==="symbol"?!0:_?_["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&_ instanceof Symbol:!1}function K(L){var _=typeof L;return Array.isArray(L)?"array":L instanceof RegExp?"object":W(_,L)?"symbol":_}function G(L){if(typeof L>"u"||L===null)return""+L;var _=K(L);if(_==="object"){if(L instanceof Date)return"date";if(L instanceof RegExp)return"regexp"}return _}function j(L){var _=G(L);switch(_){case"array":case"object":return"an "+_;case"boolean":case"date":case"regexp":return"a "+_;default:return _}}function Q(L){return!L.constructor||!L.constructor.name?f:L.constructor.name}return h.checkPropTypes=o,h.resetWarningCache=o.resetWarningCache,h.PropTypes=h,h},Ur}var Hr,fi;function Fd(){if(fi)return Hr;fi=1;var e=ls();function t(){}function n(){}return n.resetWarningCache=t,Hr=function(){function r(i,a,c,u,l,d){if(d!==e){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Hr}if(process.env.NODE_ENV!=="production"){var zd=hc(),Wd=!0;Co.exports=Vd()(zd.isElement,Wd)}else Co.exports=Fd()();var Ud=Co.exports;const te=lc(Ud);function pc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=pc(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function gc(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=pc(e))&&(r&&(r+=" "),r+=t);return r}function Hd(e,t,n=void 0){const r={};for(const o in e){const s=e[o];let i="",a=!0;for(let c=0;c<s.length;c+=1){const u=s[c];u&&(i+=(a===!0?"":" ")+t(u),a=!1,n&&n[u]&&(i+=" "+n[u]))}r[o]=i}return r}var wo={exports:{}},ie={};/**
42
42
  * @license React
43
43
  * react-is.production.js
44
44
  *
@@ -46,7 +46,7 @@ Valid keys: `+JSON.stringify(Object.keys(R),null," "));var D=he(V,K,O,F,N+"."+K
46
46
  *
47
47
  * This source code is licensed under the MIT license found in the
48
48
  * LICENSE file in the root directory of this source tree.
49
- */var bi;function af(){if(bi)return se;bi=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),i=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.for("react.view_transition"),p=Symbol.for("react.client.reference");function m(h){if(typeof h=="object"&&h!==null){var v=h.$$typeof;switch(v){case e:switch(h=h.type,h){case n:case o:case r:case c:case u:case f:return h;default:switch(h=h&&h.$$typeof,h){case i:case a:case d:case l:return h;case s:return h;default:return v}}case t:return v}}}return se.ContextConsumer=s,se.ContextProvider=i,se.Element=e,se.ForwardRef=a,se.Fragment=n,se.Lazy=d,se.Memo=l,se.Portal=t,se.Profiler=o,se.StrictMode=r,se.Suspense=c,se.SuspenseList=u,se.isContextConsumer=function(h){return m(h)===s},se.isContextProvider=function(h){return m(h)===i},se.isElement=function(h){return typeof h=="object"&&h!==null&&h.$$typeof===e},se.isForwardRef=function(h){return m(h)===a},se.isFragment=function(h){return m(h)===n},se.isLazy=function(h){return m(h)===d},se.isMemo=function(h){return m(h)===l},se.isPortal=function(h){return m(h)===t},se.isProfiler=function(h){return m(h)===o},se.isStrictMode=function(h){return m(h)===r},se.isSuspense=function(h){return m(h)===c},se.isSuspenseList=function(h){return m(h)===u},se.isValidElementType=function(h){return typeof h=="string"||typeof h=="function"||h===n||h===o||h===r||h===c||h===u||typeof h=="object"&&h!==null&&(h.$$typeof===d||h.$$typeof===l||h.$$typeof===i||h.$$typeof===s||h.$$typeof===a||h.$$typeof===p||h.getModuleId!==void 0)},se.typeOf=m,se}var ie={};/**
49
+ */var hi;function Gd(){if(hi)return ie;hi=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),i=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.for("react.view_transition"),h=Symbol.for("react.client.reference");function p(m){if(typeof m=="object"&&m!==null){var v=m.$$typeof;switch(v){case e:switch(m=m.type,m){case n:case o:case r:case c:case u:case f:return m;default:switch(m=m&&m.$$typeof,m){case i:case a:case d:case l:return m;case s:return m;default:return v}}case t:return v}}}return ie.ContextConsumer=s,ie.ContextProvider=i,ie.Element=e,ie.ForwardRef=a,ie.Fragment=n,ie.Lazy=d,ie.Memo=l,ie.Portal=t,ie.Profiler=o,ie.StrictMode=r,ie.Suspense=c,ie.SuspenseList=u,ie.isContextConsumer=function(m){return p(m)===s},ie.isContextProvider=function(m){return p(m)===i},ie.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},ie.isForwardRef=function(m){return p(m)===a},ie.isFragment=function(m){return p(m)===n},ie.isLazy=function(m){return p(m)===d},ie.isMemo=function(m){return p(m)===l},ie.isPortal=function(m){return p(m)===t},ie.isProfiler=function(m){return p(m)===o},ie.isStrictMode=function(m){return p(m)===r},ie.isSuspense=function(m){return p(m)===c},ie.isSuspenseList=function(m){return p(m)===u},ie.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===n||m===o||m===r||m===c||m===u||typeof m=="object"&&m!==null&&(m.$$typeof===d||m.$$typeof===l||m.$$typeof===i||m.$$typeof===s||m.$$typeof===a||m.$$typeof===h||m.getModuleId!==void 0)},ie.typeOf=p,ie}var ae={};/**
50
50
  * @license React
51
51
  * react-is.development.js
52
52
  *
@@ -54,22 +54,16 @@ Valid keys: `+JSON.stringify(Object.keys(R),null," "));var D=he(V,K,O,F,N+"."+K
54
54
  *
55
55
  * This source code is licensed under the MIT license found in the
56
56
  * LICENSE file in the root directory of this source tree.
57
- */var xi;function cf(){return xi||(xi=1,process.env.NODE_ENV!=="production"&&function(){function e(h){if(typeof h=="object"&&h!==null){var v=h.$$typeof;switch(v){case t:switch(h=h.type,h){case r:case s:case o:case u:case l:case p:return h;default:switch(h=h&&h.$$typeof,h){case a:case c:case f:case d:return h;case i:return h;default:return v}}case n:return v}}}var t=Symbol.for("react.transitional.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.view_transition"),m=Symbol.for("react.client.reference");ie.ContextConsumer=i,ie.ContextProvider=a,ie.Element=t,ie.ForwardRef=c,ie.Fragment=r,ie.Lazy=f,ie.Memo=d,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=u,ie.SuspenseList=l,ie.isContextConsumer=function(h){return e(h)===i},ie.isContextProvider=function(h){return e(h)===a},ie.isElement=function(h){return typeof h=="object"&&h!==null&&h.$$typeof===t},ie.isForwardRef=function(h){return e(h)===c},ie.isFragment=function(h){return e(h)===r},ie.isLazy=function(h){return e(h)===f},ie.isMemo=function(h){return e(h)===d},ie.isPortal=function(h){return e(h)===n},ie.isProfiler=function(h){return e(h)===s},ie.isStrictMode=function(h){return e(h)===o},ie.isSuspense=function(h){return e(h)===u},ie.isSuspenseList=function(h){return e(h)===l},ie.isValidElementType=function(h){return typeof h=="string"||typeof h=="function"||h===r||h===s||h===o||h===u||h===l||typeof h=="object"&&h!==null&&(h.$$typeof===f||h.$$typeof===d||h.$$typeof===a||h.$$typeof===i||h.$$typeof===c||h.$$typeof===m||h.getModuleId!==void 0)},ie.typeOf=e}()),ie}process.env.NODE_ENV==="production"?Ro.exports=af():Ro.exports=cf();var Si=Ro.exports;const lf=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function _c(e){const t=`${e}`.match(lf);return t&&t[1]||""}function Ec(e,t=""){return e.displayName||e.name||_c(e)||t}function Ti(e,t,n){const r=Ec(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function uf(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Ec(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Si.ForwardRef:return Ti(e,e.render,"ForwardRef");case Si.Memo:return Ti(e,e.type,"memo");default:return}}}const df=Object.freeze(Object.defineProperty({__proto__:null,default:uf,getFunctionName:_c},Symbol.toStringTag,{value:"Module"}));function Ot(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":_n(7));return e.charAt(0).toUpperCase()+e.slice(1)}const ff=Object.freeze(Object.defineProperty({__proto__:null,default:Ot},Symbol.toStringTag,{value:"Module"}));function Oo(e,t){const n=ce({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=ce({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=ce({},s),Object.keys(o).forEach(i=>{n[r][i]=Oo(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function hf(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const a=t(i);a!==""&&s.push(a),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const wi=e=>e,pf=()=>{let e=wi;return{configure(t){e=t},generate(t){return e(t)},reset(){e=wi}}},mf=pf(),gf={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ms(e,t,n="Mui"){const r=gf[t];return r?`${n}-${r}`:`${mf.generate(e)}-${t}`}function yf(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ms(e,o,n)}),r}function vf(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}const bf=Object.freeze(Object.defineProperty({__proto__:null,default:vf},Symbol.toStringTag,{value:"Module"}));function St(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Pc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Pc(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function xf(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Pc(e))&&(r&&(r+=" "),r+=t);return r}const Sf=Fe.createContext(void 0);process.env.NODE_ENV!=="production"&&(Z.node,Z.object);function Tf(e){const{theme:t,name:n,props:r}=e;if(!t||!t.components||!t.components[n])return r;const o=t.components[n];return o.defaultProps?Oo(o.defaultProps,r):!o.styleOverrides&&!o.variants?Oo(o,r):r}function wf({props:e,name:t}){const n=Fe.useContext(Sf);return Tf({props:e,name:t,theme:{components:n}})}process.env.NODE_ENV!=="production"&&(Z.node,Z.object.isRequired);function Cf(e){return wf(e)}var jn={},Ac={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ac);var Mc=Ac.exports,ro={exports:{}},Ci;function _f(){return Ci||(Ci=1,function(e){function t(){return e.exports=t=Object.assign?Object.assign.bind():function(n){for(var r=1;r<arguments.length;r++){var o=arguments[r];for(var s in o)({}).hasOwnProperty.call(o,s)&&(n[s]=o[s])}return n},e.exports.__esModule=!0,e.exports.default=e.exports,t.apply(null,arguments)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(ro)),ro.exports}var oo={exports:{}},_i;function Ef(){return _i||(_i=1,function(e){function t(n,r){if(n==null)return{};var o={};for(var s in n)if({}.hasOwnProperty.call(n,s)){if(r.indexOf(s)!==-1)continue;o[s]=n[s]}return o}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(oo)),oo.exports}function Pf(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Af={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Mf(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var kf=/[A-Z]|^ms/g,Rf=/_EMO_([^_]+?)_([^]*?)_EMO_/g,kc=function(t){return t.charCodeAt(1)===45},Ei=function(t){return t!=null&&typeof t!="boolean"},so=Mf(function(e){return kc(e)?e:e.replace(kf,"-$&").toLowerCase()}),Pi=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Rf,function(r,o,s){return mt={name:o,styles:s,next:mt},o})}return Af[t]!==1&&!kc(t)&&typeof n=="number"&&n!==0?n+"px":n};function pr(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return mt={name:o.name,styles:o.styles,next:mt},o.name;var s=n;if(s.styles!==void 0){var i=s.next;if(i!==void 0)for(;i!==void 0;)mt={name:i.name,styles:i.styles,next:mt},i=i.next;var a=s.styles+";";return a}return Of(e,t,n)}}var c=n;return c}function Of(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=pr(e,t,n[o])+";";else for(var s in n){var i=n[s];if(typeof i!="object"){var a=i;Ei(a)&&(r+=so(s)+":"+Pi(s,a)+";")}else if(Array.isArray(i)&&typeof i[0]=="string"&&t==null)for(var c=0;c<i.length;c++)Ei(i[c])&&(r+=so(s)+":"+Pi(s,i[c])+";");else{var u=pr(e,t,i);switch(s){case"animation":case"animationName":{r+=so(s)+":"+u+";";break}default:r+=s+"{"+u+"}"}}}return r}var Ai=/label:\s*([^\s;{]+)\s*(;|$)/g,mt;function If(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,o="";mt=void 0;var s=e[0];if(s==null||s.raw===void 0)r=!1,o+=pr(n,t,s);else{var i=s;o+=i[0]}for(var a=1;a<e.length;a++)if(o+=pr(n,t,e[a]),r){var c=s;o+=c[a]}Ai.lastIndex=0;for(var u="",l;(l=Ai.exec(o))!==null;)u+="-"+l[1];var d=Pf(o)+u;return{name:d,styles:o,next:mt}}function jf(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function Lf(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var Df=function(){function e(n){var r=this;this._insertTag=function(o){var s;r.tags.length===0?r.insertionPoint?s=r.insertionPoint.nextSibling:r.prepend?s=r.container.firstChild:s=r.before:s=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(o,s),r.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(r){r.forEach(this._insertTag)},t.insert=function(r){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(Lf(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var s=jf(o);try{s.insertRule(r,s.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(r));this.ctr++},t.flush=function(){this.tags.forEach(function(r){var o;return(o=r.parentNode)==null?void 0:o.removeChild(r)}),this.tags=[],this.ctr=0},e}(),Re="-ms-",mr="-moz-",ee="-webkit-",Rc="comm",gs="rule",ys="decl",$f="@import",Oc="@keyframes",Vf="@layer",Nf=Math.abs,Or=String.fromCharCode,Bf=Object.assign;function Ff(e,t){return ke(e,0)^45?(((t<<2^ke(e,0))<<2^ke(e,1))<<2^ke(e,2))<<2^ke(e,3):0}function Ic(e){return e.trim()}function zf(e,t){return(e=t.exec(e))?e[0]:e}function te(e,t,n){return e.replace(t,n)}function Io(e,t){return e.indexOf(t)}function ke(e,t){return e.charCodeAt(t)|0}function En(e,t,n){return e.slice(t,n)}function et(e){return e.length}function vs(e){return e.length}function Kn(e,t){return t.push(e),e}function Wf(e,t){return e.map(t).join("")}var Ir=1,Kt=1,jc=0,$e=0,Te=0,Zt="";function jr(e,t,n,r,o,s,i){return{value:e,root:t,parent:n,type:r,props:o,children:s,line:Ir,column:Kt,length:i,return:""}}function dn(e,t){return Bf(jr("",null,null,"",null,null,0),e,{length:-e.length},t)}function Uf(){return Te}function Hf(){return Te=$e>0?ke(Zt,--$e):0,Kt--,Te===10&&(Kt=1,Ir--),Te}function Be(){return Te=$e<jc?ke(Zt,$e++):0,Kt++,Te===10&&(Kt=1,Ir++),Te}function nt(){return ke(Zt,$e)}function or(){return $e}function Ln(e,t){return En(Zt,e,t)}function Pn(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Lc(e){return Ir=Kt=1,jc=et(Zt=e),$e=0,[]}function Dc(e){return Zt="",e}function sr(e){return Ic(Ln($e-1,jo(e===91?e+2:e===40?e+1:e)))}function Gf(e){for(;(Te=nt())&&Te<33;)Be();return Pn(e)>2||Pn(Te)>3?"":" "}function Kf(e,t){for(;--t&&Be()&&!(Te<48||Te>102||Te>57&&Te<65||Te>70&&Te<97););return Ln(e,or()+(t<6&&nt()==32&&Be()==32))}function jo(e){for(;Be();)switch(Te){case e:return $e;case 34:case 39:e!==34&&e!==39&&jo(Te);break;case 40:e===41&&jo(e);break;case 92:Be();break}return $e}function Yf(e,t){for(;Be()&&e+Te!==57;)if(e+Te===84&&nt()===47)break;return"/*"+Ln(t,$e-1)+"*"+Or(e===47?e:Be())}function qf(e){for(;!Pn(nt());)Be();return Ln(e,$e)}function Zf(e){return Dc(ir("",null,null,null,[""],e=Lc(e),0,[0],e))}function ir(e,t,n,r,o,s,i,a,c){for(var u=0,l=0,d=i,f=0,p=0,m=0,h=1,v=1,b=1,S=0,y="",C=o,T=s,E=r,P=y;v;)switch(m=S,S=Be()){case 40:if(m!=108&&ke(P,d-1)==58){Io(P+=te(sr(S),"&","&\f"),"&\f")!=-1&&(b=-1);break}case 34:case 39:case 91:P+=sr(S);break;case 9:case 10:case 13:case 32:P+=Gf(m);break;case 92:P+=Kf(or()-1,7);continue;case 47:switch(nt()){case 42:case 47:Kn(Xf(Yf(Be(),or()),t,n),c);break;default:P+="/"}break;case 123*h:a[u++]=et(P)*b;case 125*h:case 59:case 0:switch(S){case 0:case 125:v=0;case 59+l:b==-1&&(P=te(P,/\f/g,"")),p>0&&et(P)-d&&Kn(p>32?ki(P+";",r,n,d-1):ki(te(P," ","")+";",r,n,d-2),c);break;case 59:P+=";";default:if(Kn(E=Mi(P,t,n,u,l,o,a,y,C=[],T=[],d),s),S===123)if(l===0)ir(P,t,E,E,C,s,d,a,T);else switch(f===99&&ke(P,3)===110?100:f){case 100:case 108:case 109:case 115:ir(e,E,E,r&&Kn(Mi(e,E,E,0,0,o,a,y,o,C=[],d),T),o,T,d,a,r?C:T);break;default:ir(P,E,E,E,[""],T,0,a,T)}}u=l=p=0,h=b=1,y=P="",d=i;break;case 58:d=1+et(P),p=m;default:if(h<1){if(S==123)--h;else if(S==125&&h++==0&&Hf()==125)continue}switch(P+=Or(S),S*h){case 38:b=l>0?1:(P+="\f",-1);break;case 44:a[u++]=(et(P)-1)*b,b=1;break;case 64:nt()===45&&(P+=sr(Be())),f=nt(),l=d=et(y=P+=qf(or())),S++;break;case 45:m===45&&et(P)==2&&(h=0)}}return s}function Mi(e,t,n,r,o,s,i,a,c,u,l){for(var d=o-1,f=o===0?s:[""],p=vs(f),m=0,h=0,v=0;m<r;++m)for(var b=0,S=En(e,d+1,d=Nf(h=i[m])),y=e;b<p;++b)(y=Ic(h>0?f[b]+" "+S:te(S,/&\f/g,f[b])))&&(c[v++]=y);return jr(e,t,n,o===0?gs:a,c,u,l)}function Xf(e,t,n){return jr(e,t,n,Rc,Or(Uf()),En(e,2,-2),0)}function ki(e,t,n,r){return jr(e,t,n,ys,En(e,0,r),En(e,r+1,-1),r)}function Ut(e,t){for(var n="",r=vs(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function Jf(e,t,n,r){switch(e.type){case Vf:if(e.children.length)break;case $f:case ys:return e.return=e.return||e.value;case Rc:return"";case Oc:return e.return=e.value+"{"+Ut(e.children,r)+"}";case gs:e.value=e.props.join(",")}return et(n=Ut(e.children,r))?e.return=e.value+"{"+n+"}":""}function Qf(e){var t=vs(e);return function(n,r,o,s){for(var i="",a=0;a<t;a++)i+=e[a](n,r,o,s)||"";return i}}function eh(e){return function(t){t.root||(t=t.return)&&e(t)}}var th=function(t,n,r){for(var o=0,s=0;o=s,s=nt(),o===38&&s===12&&(n[r]=1),!Pn(s);)Be();return Ln(t,$e)},nh=function(t,n){var r=-1,o=44;do switch(Pn(o)){case 0:o===38&&nt()===12&&(n[r]=1),t[r]+=th($e-1,n,r);break;case 2:t[r]+=sr(o);break;case 4:if(o===44){t[++r]=nt()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=Or(o)}while(o=Be());return t},rh=function(t,n){return Dc(nh(Lc(t),n))},Ri=new WeakMap,oh=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!Ri.get(r))&&!o){Ri.set(t,!0);for(var s=[],i=rh(n,s),a=r.props,c=0,u=0;c<i.length;c++)for(var l=0;l<a.length;l++,u++)t.props[u]=s[c]?i[c].replace(/&\f/g,a[l]):a[l]+" "+i[c]}}},sh=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function $c(e,t){switch(Ff(e,t)){case 5103:return ee+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ee+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return ee+e+mr+e+Re+e+e;case 6828:case 4268:return ee+e+Re+e+e;case 6165:return ee+e+Re+"flex-"+e+e;case 5187:return ee+e+te(e,/(\w+).+(:[^]+)/,ee+"box-$1$2"+Re+"flex-$1$2")+e;case 5443:return ee+e+Re+"flex-item-"+te(e,/flex-|-self/,"")+e;case 4675:return ee+e+Re+"flex-line-pack"+te(e,/align-content|flex-|-self/,"")+e;case 5548:return ee+e+Re+te(e,"shrink","negative")+e;case 5292:return ee+e+Re+te(e,"basis","preferred-size")+e;case 6060:return ee+"box-"+te(e,"-grow","")+ee+e+Re+te(e,"grow","positive")+e;case 4554:return ee+te(e,/([^-])(transform)/g,"$1"+ee+"$2")+e;case 6187:return te(te(te(e,/(zoom-|grab)/,ee+"$1"),/(image-set)/,ee+"$1"),e,"")+e;case 5495:case 3959:return te(e,/(image-set\([^]*)/,ee+"$1$`$1");case 4968:return te(te(e,/(.+:)(flex-)?(.*)/,ee+"box-pack:$3"+Re+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ee+e+e;case 4095:case 3583:case 4068:case 2532:return te(e,/(.+)-inline(.+)/,ee+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(et(e)-1-t>6)switch(ke(e,t+1)){case 109:if(ke(e,t+4)!==45)break;case 102:return te(e,/(.+:)(.+)-([^]+)/,"$1"+ee+"$2-$3$1"+mr+(ke(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Io(e,"stretch")?$c(te(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(ke(e,t+1)!==115)break;case 6444:switch(ke(e,et(e)-3-(~Io(e,"!important")&&10))){case 107:return te(e,":",":"+ee)+e;case 101:return te(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ee+(ke(e,14)===45?"inline-":"")+"box$3$1"+ee+"$2$3$1"+Re+"$2box$3")+e}break;case 5936:switch(ke(e,t+11)){case 114:return ee+e+Re+te(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ee+e+Re+te(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ee+e+Re+te(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ee+e+Re+e+e}return e}var ih=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case ys:t.return=$c(t.value,t.length);break;case Oc:return Ut([dn(t,{value:te(t.value,"@","@"+ee)})],o);case gs:if(t.length)return Wf(t.props,function(s){switch(zf(s,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ut([dn(t,{props:[te(s,/:(read-\w+)/,":"+mr+"$1")]})],o);case"::placeholder":return Ut([dn(t,{props:[te(s,/:(plac\w+)/,":"+ee+"input-$1")]}),dn(t,{props:[te(s,/:(plac\w+)/,":"+mr+"$1")]}),dn(t,{props:[te(s,/:(plac\w+)/,Re+"input-$1")]})],o)}return""})}},ah=[ih],ch=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(h){var v=h.getAttribute("data-emotion");v.indexOf(" ")!==-1&&(document.head.appendChild(h),h.setAttribute("data-s",""))})}var o=t.stylisPlugins||ah,s={},i,a=[];i=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(h){for(var v=h.getAttribute("data-emotion").split(" "),b=1;b<v.length;b++)s[v[b]]=!0;a.push(h)});var c,u=[oh,sh];{var l,d=[Jf,eh(function(h){l.insert(h)})],f=Qf(u.concat(o,d)),p=function(v){return Ut(Zf(v),f)};c=function(v,b,S,y){l=S,p(v?v+"{"+b.styles+"}":b.styles),y&&(m.inserted[b.name]=!0)}}var m={key:n,sheet:new Df({key:n,container:i,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:s,registered:{},insert:c};return m.sheet.hydrate(a),m};function lh(e,t){const n=ch({key:"css",prepend:e});if(t){const r=n.insert;n.insert=(...o)=>(o[1].styles.match(/^@layer\s+[^{]*$/)||(o[1].styles=`@layer mui {${o[1].styles}}`),r(...o))}return n}const io=new Map;function Vc(e){const{injectFirst:t,enableCssLayer:n,children:r}=e,o=Fe.useMemo(()=>{const s=`${t}-${n}`;if(typeof document=="object"&&io.has(s))return io.get(s);const i=lh(t,n);return io.set(s,i),i},[t,n]);return t||n?g.jsx(xn.CacheProvider,{value:o,children:r}):r}process.env.NODE_ENV!=="production"&&(Vc.propTypes={children:Z.node,enableCssLayer:Z.bool,injectFirst:Z.bool});function uh(e){return e==null||Object.keys(e).length===0}function Nc(e){const{styles:t,defaultTheme:n={}}=e,r=typeof t=="function"?o=>t(uh(o)?n:o):t;return g.jsx(xn.Global,{styles:r})}process.env.NODE_ENV!=="production"&&(Nc.propTypes={defaultTheme:Z.object,styles:Z.oneOfType([Z.array,Z.string,Z.object,Z.func])});/**
58
- * @mui/styled-engine v5.18.0
59
- *
60
- * @license MIT
61
- * This source code is licensed under the MIT license found in the
62
- * LICENSE file in the root directory of this source tree.
63
- */function dh(e,t){const n=wd(e,t);return process.env.NODE_ENV!=="production"?(...r)=>{const o=typeof e=="string"?`"${e}"`:"component";return r.length===0?console.error([`MUI: Seems like you called \`styled(${o})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
64
- `)):r.some(s=>s===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}const fh=(e,t)=>{Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))},Oi=[];function hh(e){return Oi[0]=e,If(Oi)}const ph=Object.freeze(Object.defineProperty({__proto__:null,GlobalStyles:Nc,StyledEngineProvider:Vc,ThemeContext:xn.ThemeContext,css:xn.css,default:dh,internal_processStyles:fh,internal_serializeStyles:hh,keyframes:xn.keyframes},Symbol.toStringTag,{value:"Module"})),mh=xt(ph),gh=xt(qd),yh=xt(ff),vh=xt(df),bh=["values","unit","step"],xh=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>ce({},n,{[r.key]:r.val}),{})};function Bc(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=St(e,bh),s=xh(t),i=Object.keys(s);function a(f){return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${n})`}function c(f){return`@media (max-width:${(typeof t[f]=="number"?t[f]:f)-r/100}${n})`}function u(f,p){const m=i.indexOf(p);return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${n}) and (max-width:${(m!==-1&&typeof t[i[m]]=="number"?t[i[m]]:p)-r/100}${n})`}function l(f){return i.indexOf(f)+1<i.length?u(f,i[i.indexOf(f)+1]):a(f)}function d(f){const p=i.indexOf(f);return p===0?a(i[1]):p===i.length-1?c(i[p]):u(f,i[i.indexOf(f)+1]).replace("@media","@media not all and")}return ce({keys:i,values:s,up:a,down:c,between:u,only:l,not:d,unit:n},o)}const Sh={borderRadius:4},Tt=process.env.NODE_ENV!=="production"?Z.oneOfType([Z.number,Z.string,Z.object,Z.array]):{};function Sn(e,t){return t?tt(e,t,{clone:!1}):e}const bs={xs:0,sm:600,md:900,lg:1200,xl:1536},Ii={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${bs[e]}px)`};function ct(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ii;return t.reduce((i,a,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ii;return Object.keys(t).reduce((i,a)=>{if(Object.keys(s.values||bs).indexOf(a)!==-1){const c=s.up(a);i[c]=n(t[a],a)}else{const c=a;i[c]=t[c]}return i},{})}return n(t)}function Th(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function ji(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function Lr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function gr(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=Lr(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const a=i[t],c=i.theme,u=Lr(c,r)||{};return ct(i,a,d=>{let f=gr(u,o,d);return d===f&&typeof d=="string"&&(f=gr(u,o,`${t}${d==="default"?"":Ot(d)}`,d)),n===!1?f:{[n]:f}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:Tt}:{},s.filterProps=[t],s}function wh(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const Ch={m:"margin",p:"padding"},_h={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Li={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Eh=wh(e=>{if(e.length>2)if(Li[e])e=Li[e];else return[e];const[t,n]=e.split(""),r=Ch[t],o=_h[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),Dr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],$r=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ph=[...Dr,...$r];function Dn(e,t,n,r){var o;const s=(o=Lr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(`
57
+ */var mi;function Kd(){return mi||(mi=1,process.env.NODE_ENV!=="production"&&function(){function e(m){if(typeof m=="object"&&m!==null){var v=m.$$typeof;switch(v){case t:switch(m=m.type,m){case r:case s:case o:case u:case l:case h:return m;default:switch(m=m&&m.$$typeof,m){case a:case c:case f:case d:return m;case i:return m;default:return v}}case n:return v}}}var t=Symbol.for("react.transitional.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.for("react.view_transition"),p=Symbol.for("react.client.reference");ae.ContextConsumer=i,ae.ContextProvider=a,ae.Element=t,ae.ForwardRef=c,ae.Fragment=r,ae.Lazy=f,ae.Memo=d,ae.Portal=n,ae.Profiler=s,ae.StrictMode=o,ae.Suspense=u,ae.SuspenseList=l,ae.isContextConsumer=function(m){return e(m)===i},ae.isContextProvider=function(m){return e(m)===a},ae.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===t},ae.isForwardRef=function(m){return e(m)===c},ae.isFragment=function(m){return e(m)===r},ae.isLazy=function(m){return e(m)===f},ae.isMemo=function(m){return e(m)===d},ae.isPortal=function(m){return e(m)===n},ae.isProfiler=function(m){return e(m)===s},ae.isStrictMode=function(m){return e(m)===o},ae.isSuspense=function(m){return e(m)===u},ae.isSuspenseList=function(m){return e(m)===l},ae.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===s||m===o||m===u||m===l||typeof m=="object"&&m!==null&&(m.$$typeof===f||m.$$typeof===d||m.$$typeof===a||m.$$typeof===i||m.$$typeof===c||m.$$typeof===p||m.getModuleId!==void 0)},ae.typeOf=e}()),ae}process.env.NODE_ENV==="production"?wo.exports=Gd():wo.exports=Kd();var nr=wo.exports;function Qe(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function yc(e){if(Ve.isValidElement(e)||nr.isValidElementType(e)||!Qe(e))return e;const t={};return Object.keys(e).forEach(n=>{t[n]=yc(e[n])}),t}function De(e,t,n={clone:!0}){const r=n.clone?{...e}:e;return Qe(e)&&Qe(t)&&Object.keys(t).forEach(o=>{Ve.isValidElement(t[o])||nr.isValidElementType(t[o])?r[o]=t[o]:Qe(t[o])&&Object.prototype.hasOwnProperty.call(e,o)&&Qe(e[o])?r[o]=De(e[o],t[o],n):n.clone?r[o]=Qe(t[o])?yc(t[o]):t[o]:r[o]=t[o]}),r}function yn(e,t){return t?De(e,t,{clone:!1}):e}const yt=process.env.NODE_ENV!=="production"?te.oneOfType([te.number,te.string,te.object,te.array]):{};function pi(e,t){if(!e.containerQueries)return t;const n=Object.keys(t).filter(r=>r.startsWith("@container")).sort((r,o)=>{var i,a;const s=/min-width:\s*([0-9.]+)/;return+(((i=r.match(s))==null?void 0:i[1])||0)-+(((a=o.match(s))==null?void 0:a[1])||0)});return n.length?n.reduce((r,o)=>{const s=t[o];return delete r[o],r[o]=s,r},{...t}):t}function Yd(e,t){return t==="@"||t.startsWith("@")&&(e.some(n=>t.startsWith(`@${n}`))||!!t.match(/^@\d/))}function Zd(e,t){const n=t.match(/^@([^/]+)?\/?(.+)?$/);if(!n){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
58
+ For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:ht(18,`(${t})`));return null}const[,r,o]=n,s=Number.isNaN(+r)?r||0:+r;return e.containerQueries(o).up(s)}function qd(e){const t=(s,i)=>s.replace("@media",i?`@container ${i}`:"@container");function n(s,i){s.up=(...a)=>t(e.breakpoints.up(...a),i),s.down=(...a)=>t(e.breakpoints.down(...a),i),s.between=(...a)=>t(e.breakpoints.between(...a),i),s.only=(...a)=>t(e.breakpoints.only(...a),i),s.not=(...a)=>{const c=t(e.breakpoints.not(...a),i);return c.includes("not all and")?c.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):c}}const r={},o=s=>(n(r,s),r);return n(o),{...e,containerQueries:o}}const vr={xs:0,sm:600,md:900,lg:1200,xl:1536},gi={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${vr[e]}px)`},Xd={containerQueries:e=>({up:t=>{let n=typeof t=="number"?t:vr[t]||t;return typeof n=="number"&&(n=`${n}px`),e?`@container ${e} (min-width:${n})`:`@container (min-width:${n})`}})};function nt(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||gi;return t.reduce((i,a,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||gi;return Object.keys(t).reduce((i,a)=>{if(Yd(s.keys,a)){const c=Zd(r.containerQueries?r:Xd,a);c&&(i[c]=n(t[a],a))}else if(Object.keys(s.values||vr).includes(a)){const c=s.up(a);i[c]=n(t[a],a)}else{const c=a;i[c]=t[c]}return i},{})}return n(t)}function Jd(e={}){var n;return((n=e.keys)==null?void 0:n.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function yi(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function br(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function rr(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=br(e,n)||r,t&&(o=t(o,r,e)),o}function xe(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const a=i[t],c=i.theme,u=br(c,r)||{};return nt(i,a,d=>{let f=rr(u,o,d);return d===f&&typeof d=="string"&&(f=rr(u,o,`${t}${d==="default"?"":It(d)}`,d)),n===!1?f:{[n]:f}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:yt}:{},s.filterProps=[t],s}function Qd(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const ef={m:"margin",p:"padding"},tf={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},vi={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},nf=Qd(e=>{if(e.length>2)if(vi[e])e=vi[e];else return[e];const[t,n]=e.split(""),r=ef[t],o=tf[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),xr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Sr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],rf=[...xr,...Sr];function An(e,t,n,r){const o=br(e,t,!0)??n;return typeof o=="number"||typeof o=="string"?s=>typeof s=="string"?s:(process.env.NODE_ENV!=="production"&&typeof s!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${s}.`),typeof o=="string"?o.startsWith("var(")&&s===0?0:o.startsWith("var(")&&s===1?o:`calc(${s} * ${o})`:o*s):Array.isArray(o)?s=>{if(typeof s=="string")return s;const i=Math.abs(s);process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>o.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(o)}.`,`${i} > ${o.length-1}, you need to add the missing values.`].join(`
65
59
  `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(`
66
- `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(`
67
- `)),()=>{})}function Fc(e){return Dn(e,"spacing",8,"spacing")}function $n(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Ah(e,t){return n=>e.reduce((r,o)=>(r[o]=$n(t,n),r),{})}function Mh(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=Eh(n),s=Ah(o,r),i=e[n];return ct(e,i,s)}function zc(e,t){const n=Fc(e.theme);return Object.keys(e).map(r=>Mh(e,t,r,n)).reduce(Sn,{})}function ge(e){return zc(e,Dr)}ge.propTypes=process.env.NODE_ENV!=="production"?Dr.reduce((e,t)=>(e[t]=Tt,e),{}):{};ge.filterProps=Dr;function ye(e){return zc(e,$r)}ye.propTypes=process.env.NODE_ENV!=="production"?$r.reduce((e,t)=>(e[t]=Tt,e),{}):{};ye.filterProps=$r;process.env.NODE_ENV!=="production"&&Ph.reduce((e,t)=>(e[t]=Tt,e),{});function kh(e=8){if(e.mui)return e;const t=Fc({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function Vr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?Sn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Ue(e){return typeof e!="number"?e:`${e}px solid`}function Ye(e,t){return be({prop:e,themeKey:"borders",transform:t})}const Rh=Ye("border",Ue),Oh=Ye("borderTop",Ue),Ih=Ye("borderRight",Ue),jh=Ye("borderBottom",Ue),Lh=Ye("borderLeft",Ue),Dh=Ye("borderColor"),$h=Ye("borderTopColor"),Vh=Ye("borderRightColor"),Nh=Ye("borderBottomColor"),Bh=Ye("borderLeftColor"),Fh=Ye("outline",Ue),zh=Ye("outlineColor"),Nr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Dn(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:$n(t,r)});return ct(e,e.borderRadius,n)}return null};Nr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Tt}:{};Nr.filterProps=["borderRadius"];Vr(Rh,Oh,Ih,jh,Lh,Dh,$h,Vh,Nh,Bh,Nr,Fh,zh);const Br=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Dn(e.theme,"spacing",8,"gap"),n=r=>({gap:$n(t,r)});return ct(e,e.gap,n)}return null};Br.propTypes=process.env.NODE_ENV!=="production"?{gap:Tt}:{};Br.filterProps=["gap"];const Fr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Dn(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:$n(t,r)});return ct(e,e.columnGap,n)}return null};Fr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Tt}:{};Fr.filterProps=["columnGap"];const zr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Dn(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:$n(t,r)});return ct(e,e.rowGap,n)}return null};zr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Tt}:{};zr.filterProps=["rowGap"];const Wh=be({prop:"gridColumn"}),Uh=be({prop:"gridRow"}),Hh=be({prop:"gridAutoFlow"}),Gh=be({prop:"gridAutoColumns"}),Kh=be({prop:"gridAutoRows"}),Yh=be({prop:"gridTemplateColumns"}),qh=be({prop:"gridTemplateRows"}),Zh=be({prop:"gridTemplateAreas"}),Xh=be({prop:"gridArea"});Vr(Br,Fr,zr,Wh,Uh,Hh,Gh,Kh,Yh,qh,Zh,Xh);function Ht(e,t){return t==="grey"?t:e}const Jh=be({prop:"color",themeKey:"palette",transform:Ht}),Qh=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Ht}),ep=be({prop:"backgroundColor",themeKey:"palette",transform:Ht});Vr(Jh,Qh,ep);function Ne(e){return e<=1&&e!==0?`${e*100}%`:e}const tp=be({prop:"width",transform:Ne}),xs=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||bs[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ne(n)}};return ct(e,e.maxWidth,t)}return null};xs.filterProps=["maxWidth"];const np=be({prop:"minWidth",transform:Ne}),rp=be({prop:"height",transform:Ne}),op=be({prop:"maxHeight",transform:Ne}),sp=be({prop:"minHeight",transform:Ne});be({prop:"size",cssProperty:"width",transform:Ne});be({prop:"size",cssProperty:"height",transform:Ne});const ip=be({prop:"boxSizing"});Vr(tp,xs,np,rp,op,sp,ip);const Vn={border:{themeKey:"borders",transform:Ue},borderTop:{themeKey:"borders",transform:Ue},borderRight:{themeKey:"borders",transform:Ue},borderBottom:{themeKey:"borders",transform:Ue},borderLeft:{themeKey:"borders",transform:Ue},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Ue},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Nr},color:{themeKey:"palette",transform:Ht},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Ht},backgroundColor:{themeKey:"palette",transform:Ht},p:{style:ye},pt:{style:ye},pr:{style:ye},pb:{style:ye},pl:{style:ye},px:{style:ye},py:{style:ye},padding:{style:ye},paddingTop:{style:ye},paddingRight:{style:ye},paddingBottom:{style:ye},paddingLeft:{style:ye},paddingX:{style:ye},paddingY:{style:ye},paddingInline:{style:ye},paddingInlineStart:{style:ye},paddingInlineEnd:{style:ye},paddingBlock:{style:ye},paddingBlockStart:{style:ye},paddingBlockEnd:{style:ye},m:{style:ge},mt:{style:ge},mr:{style:ge},mb:{style:ge},ml:{style:ge},mx:{style:ge},my:{style:ge},margin:{style:ge},marginTop:{style:ge},marginRight:{style:ge},marginBottom:{style:ge},marginLeft:{style:ge},marginX:{style:ge},marginY:{style:ge},marginInline:{style:ge},marginInlineStart:{style:ge},marginInlineEnd:{style:ge},marginBlock:{style:ge},marginBlockStart:{style:ge},marginBlockEnd:{style:ge},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:Br},rowGap:{style:zr},columnGap:{style:Fr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ne},maxWidth:{style:xs},minWidth:{transform:Ne},height:{transform:Ne},maxHeight:{transform:Ne},minHeight:{transform:Ne},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function ap(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function cp(e,t){return typeof e=="function"?e(t):e}function Wc(){function e(n,r,o,s){const i={[n]:r,theme:o},a=s[n];if(!a)return{[n]:r};const{cssProperty:c=n,themeKey:u,transform:l,style:d}=a;if(r==null)return null;if(u==="typography"&&r==="inherit")return{[n]:r};const f=Lr(o,u)||{};return d?d(i):ct(i,r,m=>{let h=gr(f,l,m);return m===h&&typeof m=="string"&&(h=gr(f,l,`${n}${m==="default"?"":Ot(m)}`,m)),c===!1?h:{[c]:h}})}function t(n){var r;const{sx:o,theme:s={},nested:i}=n||{};if(!o)return null;const a=(r=s.unstable_sxConfig)!=null?r:Vn;function c(u){let l=u;if(typeof u=="function")l=u(s);else if(typeof u!="object")return u;if(!l)return null;const d=Th(s.breakpoints),f=Object.keys(d);let p=d;return Object.keys(l).forEach(m=>{const h=cp(l[m],s);if(h!=null)if(typeof h=="object")if(a[m])p=Sn(p,e(m,h,s,a));else{const v=ct({theme:s},h,b=>({[m]:b}));ap(v,h)?p[m]=t({sx:h,theme:s,nested:!0}):p=Sn(p,v)}else p=Sn(p,e(m,h,s,a))}),!i&&s.modularCssLayers?{"@layer sx":ji(f,p)}:ji(f,p)}return Array.isArray(o)?o.map(c):c(o)}return t}const Wr=Wc();Wr.filterProps=["sx"];function Uc(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const lp=["breakpoints","palette","spacing","shape"];function Hc(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=St(e,lp),a=Bc(n),c=kh(o);let u=tt({breakpoints:a,direction:"ltr",components:{},palette:ce({mode:"light"},r),spacing:c,shape:ce({},Sh,s)},i);return u.applyStyles=Uc,u=t.reduce((l,d)=>tt(l,d),u),u.unstable_sxConfig=ce({},Vn,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(d){return Wr({sx:d,theme:this})},u}const up=Object.freeze(Object.defineProperty({__proto__:null,default:Hc,private_createBreakpoints:Bc,unstable_applyStyles:Uc},Symbol.toStringTag,{value:"Module"})),dp=xt(up),fp=["sx"],hp=e=>{var t,n;const r={systemProps:{},otherProps:{}},o=(t=e==null||(n=e.theme)==null?void 0:n.unstable_sxConfig)!=null?t:Vn;return Object.keys(e).forEach(s=>{o[s]?r.systemProps[s]=e[s]:r.otherProps[s]=e[s]}),r};function pp(e){const{sx:t}=e,n=St(e,fp),{systemProps:r,otherProps:o}=hp(n);let s;return Array.isArray(t)?s=[r,...t]:typeof t=="function"?s=(...i)=>{const a=t(...i);return pt(a)?ce({},r,a):r}:s=ce({},r,t),ce({},o,{sx:s})}const mp=Object.freeze(Object.defineProperty({__proto__:null,default:Wr,extendSxProp:pp,unstable_createStyleFunctionSx:Wc,unstable_defaultSxConfig:Vn},Symbol.toStringTag,{value:"Module"})),gp=xt(mp);var Xt=Mc;Object.defineProperty(jn,"__esModule",{value:!0});var yp=jn.default=Rp;jn.shouldForwardProp=ar;jn.systemDefaultTheme=void 0;var We=Xt(_f()),Lo=Xt(Ef()),yr=Ep(mh),vp=gh,bp=Xt(yh),xp=Xt(vh),Sp=Xt(dp),Tp=Xt(gp);const wp=["ownerState"],Cp=["variants"],_p=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Gc(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,n=new WeakMap;return(Gc=function(r){return r?n:t})(e)}function Ep(e,t){if(e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var n=Gc(t);if(n&&n.has(e))return n.get(e);var r={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(s!=="default"&&Object.prototype.hasOwnProperty.call(e,s)){var i=o?Object.getOwnPropertyDescriptor(e,s):null;i&&(i.get||i.set)?Object.defineProperty(r,s,i):r[s]=e[s]}return r.default=e,n&&n.set(e,r),r}function Pp(e){return Object.keys(e).length===0}function Ap(e){return typeof e=="string"&&e.charCodeAt(0)>96}function ar(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Di(e,t){return t&&e&&typeof e=="object"&&e.styles&&!e.styles.startsWith("@layer")&&(e.styles=`@layer ${t}{${String(e.styles)}}`),e}const Mp=jn.systemDefaultTheme=(0,Sp.default)(),$i=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Yn({defaultTheme:e,theme:t,themeId:n}){return Pp(t)?e:t[n]||t}function kp(e){return e?(t,n)=>n[e]:null}function cr(e,t,n){let{ownerState:r}=t,o=(0,Lo.default)(t,wp);const s=typeof e=="function"?e((0,We.default)({ownerState:r},o)):e;if(Array.isArray(s))return s.flatMap(i=>cr(i,(0,We.default)({ownerState:r},o),n));if(s&&typeof s=="object"&&Array.isArray(s.variants)){const{variants:i=[]}=s;let c=(0,Lo.default)(s,Cp);return i.forEach(u=>{let l=!0;if(typeof u.props=="function"?l=u.props((0,We.default)({ownerState:r},o,r)):Object.keys(u.props).forEach(d=>{(r==null?void 0:r[d])!==u.props[d]&&o[d]!==u.props[d]&&(l=!1)}),l){Array.isArray(c)||(c=[c]);const d=typeof u.style=="function"?u.style((0,We.default)({ownerState:r},o,r)):u.style;c.push(n?Di((0,yr.internal_serializeStyles)(d),n):d)}}),c}return n?Di((0,yr.internal_serializeStyles)(s),n):s}function Rp(e={}){const{themeId:t,defaultTheme:n=Mp,rootShouldForwardProp:r=ar,slotShouldForwardProp:o=ar}=e,s=i=>(0,Tp.default)((0,We.default)({},i,{theme:Yn((0,We.default)({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,a={})=>{(0,yr.internal_processStyles)(i,E=>E.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:u,skipVariantsResolver:l,skipSx:d,overridesResolver:f=kp($i(u))}=a,p=(0,Lo.default)(a,_p),m=c&&c.startsWith("Mui")||u?"components":"custom",h=l!==void 0?l:u&&u!=="Root"&&u!=="root"||!1,v=d||!1;let b;process.env.NODE_ENV!=="production"&&c&&(b=`${c}-${$i(u||"Root")}`);let S=ar;u==="Root"||u==="root"?S=r:u?S=o:Ap(i)&&(S=void 0);const y=(0,yr.default)(i,(0,We.default)({shouldForwardProp:S,label:b},p)),C=E=>typeof E=="function"&&E.__emotion_real!==E||(0,vp.isPlainObject)(E)?P=>{const A=Yn({theme:P.theme,defaultTheme:n,themeId:t});return cr(E,(0,We.default)({},P,{theme:A}),A.modularCssLayers?m:void 0)}:E,T=(E,...P)=>{let A=C(E);const M=P?P.map(C):[];c&&f&&M.push(W=>{const H=Yn((0,We.default)({},W,{defaultTheme:n,themeId:t}));if(!H.components||!H.components[c]||!H.components[c].styleOverrides)return null;const q=H.components[c].styleOverrides,oe={};return Object.entries(q).forEach(([Q,U])=>{oe[Q]=cr(U,(0,We.default)({},W,{theme:H}),H.modularCssLayers?"theme":void 0)}),f(W,oe)}),c&&!h&&M.push(W=>{var H;const q=Yn((0,We.default)({},W,{defaultTheme:n,themeId:t})),oe=q==null||(H=q.components)==null||(H=H[c])==null?void 0:H.variants;return cr({variants:oe},(0,We.default)({},W,{theme:q}),q.modularCssLayers?"theme":void 0)}),v||M.push(s);const L=M.length-P.length;if(Array.isArray(E)&&L>0){const W=new Array(L).fill("");A=[...E,...W],A.raw=[...E.raw,...W]}const $=y(A,...M);if(process.env.NODE_ENV!=="production"){let W;c&&(W=`${c}${(0,bp.default)(u||"")}`),W===void 0&&(W=`Styled(${(0,xp.default)(i)})`),$.displayName=W}return i.muiName&&($.muiName=i.muiName),$};return y.withConfig&&(T.withConfig=y.withConfig),T}}function Op(e,t){return ce({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}var xe={};const Ip=xt(sf),jp=xt(bf);var Kc=Mc;Object.defineProperty(xe,"__esModule",{value:!0});xe.alpha=Xc;xe.blend=Gp;xe.colorChannel=void 0;var Lp=xe.darken=Ts;xe.decomposeColor=Ke;xe.emphasize=Jc;var Vi=xe.getContrastRatio=Fp;xe.getLuminance=vr;xe.hexToRgb=Yc;xe.hslToRgb=Zc;var Dp=xe.lighten=ws;xe.private_safeAlpha=zp;xe.private_safeColorChannel=void 0;xe.private_safeDarken=Wp;xe.private_safeEmphasize=Hp;xe.private_safeLighten=Up;xe.recomposeColor=Jt;xe.rgbToHex=Bp;var Ni=Kc(Ip),$p=Kc(jp);function Ss(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(e<t||e>n)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),(0,$p.default)(e,t,n)}function Yc(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Vp(e){const t=e.toString(16);return t.length===1?`0${t}`:t}function Ke(e){if(e.type)return e;if(e.charAt(0)==="#")return Ke(Yc(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
68
- The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:(0,Ni.default)(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space.
69
- The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:(0,Ni.default)(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}const qc=e=>{const t=Ke(e);return t.values.slice(0,3).map((n,r)=>t.type.indexOf("hsl")!==-1&&r!==0?`${n}%`:n).join(" ")};xe.colorChannel=qc;const Np=(e,t)=>{try{return qc(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};xe.private_safeColorChannel=Np;function Jt(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function Bp(e){if(e.indexOf("#")===0)return e;const{values:t}=Ke(e);return`#${t.map((n,r)=>Vp(r===3?Math.round(255*n):n)).join("")}`}function Zc(e){e=Ke(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(u,l=(u+n/30)%12)=>o-s*Math.max(Math.min(l-3,9-l,1),-1);let a="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(a+="a",c.push(t[3])),Jt({type:a,values:c})}function vr(e){e=Ke(e);let t=e.type==="hsl"||e.type==="hsla"?Ke(Zc(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Fp(e,t){const n=vr(e),r=vr(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Xc(e,t){return e=Ke(e),t=Ss(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Jt(e)}function zp(e,t,n){try{return Xc(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function Ts(e,t){if(e=Ke(e),t=Ss(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return Jt(e)}function Wp(e,t,n){try{return Ts(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function ws(e,t){if(e=Ke(e),t=Ss(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return Jt(e)}function Up(e,t,n){try{return ws(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function Jc(e,t=.15){return vr(e)>.5?Ts(e,t):ws(e,t)}function Hp(e,t,n){try{return Jc(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function Gp(e,t,n,r=1){const o=(c,u)=>Math.round((c**(1/r)*(1-n)+u**(1/r)*n)**r),s=Ke(e),i=Ke(t),a=[o(s.values[0],i.values[0]),o(s.values[1],i.values[1]),o(s.values[2],i.values[2])];return Jt({type:"rgb",values:a})}const An={black:"#000",white:"#fff"},Kp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},It={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},jt={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},fn={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Lt={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Dt={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},$t={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"},Yp=["mode","contrastThreshold","tonalOffset"],Bi={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:An.white,default:An.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},ao={text:{primary:An.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:An.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Fi(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Dp(e.main,o):t==="dark"&&(e.dark=Lp(e.main,s)))}function qp(e="light"){return e==="dark"?{main:Lt[200],light:Lt[50],dark:Lt[400]}:{main:Lt[700],light:Lt[400],dark:Lt[800]}}function Zp(e="light"){return e==="dark"?{main:It[200],light:It[50],dark:It[400]}:{main:It[500],light:It[300],dark:It[700]}}function Xp(e="light"){return e==="dark"?{main:jt[500],light:jt[300],dark:jt[700]}:{main:jt[700],light:jt[400],dark:jt[800]}}function Jp(e="light"){return e==="dark"?{main:Dt[400],light:Dt[300],dark:Dt[700]}:{main:Dt[700],light:Dt[500],dark:Dt[900]}}function Qp(e="light"){return e==="dark"?{main:$t[400],light:$t[300],dark:$t[700]}:{main:$t[800],light:$t[500],dark:$t[900]}}function em(e="light"){return e==="dark"?{main:fn[400],light:fn[300],dark:fn[700]}:{main:"#ed6c02",light:fn[500],dark:fn[900]}}function tm(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=St(e,Yp),s=e.primary||qp(t),i=e.secondary||Zp(t),a=e.error||Xp(t),c=e.info||Jp(t),u=e.success||Qp(t),l=e.warning||em(t);function d(h){const v=Vi(h,ao.text.primary)>=n?ao.text.primary:Bi.text.primary;if(process.env.NODE_ENV!=="production"){const b=Vi(h,v);b<3&&console.error([`MUI: The contrast ratio of ${b}:1 for ${v} on ${h}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
70
- `))}return v}const f=({color:h,name:v,mainShade:b=500,lightShade:S=300,darkShade:y=700})=>{if(h=ce({},h),!h.main&&h[b]&&(h.main=h[b]),!h.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${v?` (${v})`:""} provided to augmentColor(color) is invalid.
71
- The color object needs to have a \`main\` property or a \`${b}\` property.`:_n(11,v?` (${v})`:"",b));if(typeof h.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${v?` (${v})`:""} provided to augmentColor(color) is invalid.
72
- \`color.main\` should be a string, but \`${JSON.stringify(h.main)}\` was provided instead.
60
+ `)));const a=o[i];return s>=0?a:typeof a=="number"?-a:typeof a=="string"&&a.startsWith("var(")?`calc(-1 * ${a})`:`-${a}`}:typeof o=="function"?o:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${o}) is invalid.`,"It should be a number, an array or a function."].join(`
61
+ `)),()=>{})}function us(e){return An(e,"spacing",8,"spacing")}function Mn(e,t){return typeof t=="string"||t==null?t:e(t)}function of(e,t){return n=>e.reduce((r,o)=>(r[o]=Mn(t,n),r),{})}function sf(e,t,n,r){if(!t.includes(n))return null;const o=nf(n),s=of(o,r),i=e[n];return nt(e,i,s)}function vc(e,t){const n=us(e.theme);return Object.keys(e).map(r=>sf(e,t,r,n)).reduce(yn,{})}function ye(e){return vc(e,xr)}ye.propTypes=process.env.NODE_ENV!=="production"?xr.reduce((e,t)=>(e[t]=yt,e),{}):{};ye.filterProps=xr;function ve(e){return vc(e,Sr)}ve.propTypes=process.env.NODE_ENV!=="production"?Sr.reduce((e,t)=>(e[t]=yt,e),{}):{};ve.filterProps=Sr;process.env.NODE_ENV!=="production"&&rf.reduce((e,t)=>(e[t]=yt,e),{});function Tr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?yn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return xe({prop:e,themeKey:"borders",transform:t})}const af=Fe("border",Be),cf=Fe("borderTop",Be),lf=Fe("borderRight",Be),uf=Fe("borderBottom",Be),df=Fe("borderLeft",Be),ff=Fe("borderColor"),hf=Fe("borderTopColor"),mf=Fe("borderRightColor"),pf=Fe("borderBottomColor"),gf=Fe("borderLeftColor"),yf=Fe("outline",Be),vf=Fe("outlineColor"),Cr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=An(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Mn(t,r)});return nt(e,e.borderRadius,n)}return null};Cr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:yt}:{};Cr.filterProps=["borderRadius"];Tr(af,cf,lf,uf,df,ff,hf,mf,pf,gf,Cr,yf,vf);const wr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=An(e.theme,"spacing",8,"gap"),n=r=>({gap:Mn(t,r)});return nt(e,e.gap,n)}return null};wr.propTypes=process.env.NODE_ENV!=="production"?{gap:yt}:{};wr.filterProps=["gap"];const _r=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=An(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Mn(t,r)});return nt(e,e.columnGap,n)}return null};_r.propTypes=process.env.NODE_ENV!=="production"?{columnGap:yt}:{};_r.filterProps=["columnGap"];const Er=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=An(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Mn(t,r)});return nt(e,e.rowGap,n)}return null};Er.propTypes=process.env.NODE_ENV!=="production"?{rowGap:yt}:{};Er.filterProps=["rowGap"];const bf=xe({prop:"gridColumn"}),xf=xe({prop:"gridRow"}),Sf=xe({prop:"gridAutoFlow"}),Tf=xe({prop:"gridAutoColumns"}),Cf=xe({prop:"gridAutoRows"}),wf=xe({prop:"gridTemplateColumns"}),_f=xe({prop:"gridTemplateRows"}),Ef=xe({prop:"gridTemplateAreas"}),Af=xe({prop:"gridArea"});Tr(wr,_r,Er,bf,xf,Sf,Tf,Cf,wf,_f,Ef,Af);function Wt(e,t){return t==="grey"?t:e}const Mf=xe({prop:"color",themeKey:"palette",transform:Wt}),Pf=xe({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Wt}),kf=xe({prop:"backgroundColor",themeKey:"palette",transform:Wt});Tr(Mf,Pf,kf);function Le(e){return e<=1&&e!==0?`${e*100}%`:e}const If=xe({prop:"width",transform:Le}),ds=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var o,s,i,a,c;const r=((i=(s=(o=e.theme)==null?void 0:o.breakpoints)==null?void 0:s.values)==null?void 0:i[n])||vr[n];return r?((c=(a=e.theme)==null?void 0:a.breakpoints)==null?void 0:c.unit)!=="px"?{maxWidth:`${r}${e.theme.breakpoints.unit}`}:{maxWidth:r}:{maxWidth:Le(n)}};return nt(e,e.maxWidth,t)}return null};ds.filterProps=["maxWidth"];const Rf=xe({prop:"minWidth",transform:Le}),Of=xe({prop:"height",transform:Le}),Lf=xe({prop:"maxHeight",transform:Le}),Df=xe({prop:"minHeight",transform:Le});xe({prop:"size",cssProperty:"width",transform:Le});xe({prop:"size",cssProperty:"height",transform:Le});const jf=xe({prop:"boxSizing"});Tr(If,ds,Rf,Of,Lf,Df,jf);const Ar={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Cr},color:{themeKey:"palette",transform:Wt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Wt},backgroundColor:{themeKey:"palette",transform:Wt},p:{style:ve},pt:{style:ve},pr:{style:ve},pb:{style:ve},pl:{style:ve},px:{style:ve},py:{style:ve},padding:{style:ve},paddingTop:{style:ve},paddingRight:{style:ve},paddingBottom:{style:ve},paddingLeft:{style:ve},paddingX:{style:ve},paddingY:{style:ve},paddingInline:{style:ve},paddingInlineStart:{style:ve},paddingInlineEnd:{style:ve},paddingBlock:{style:ve},paddingBlockStart:{style:ve},paddingBlockEnd:{style:ve},m:{style:ye},mt:{style:ye},mr:{style:ye},mb:{style:ye},ml:{style:ye},mx:{style:ye},my:{style:ye},margin:{style:ye},marginTop:{style:ye},marginRight:{style:ye},marginBottom:{style:ye},marginLeft:{style:ye},marginX:{style:ye},marginY:{style:ye},marginInline:{style:ye},marginInlineStart:{style:ye},marginInlineEnd:{style:ye},marginBlock:{style:ye},marginBlockStart:{style:ye},marginBlockEnd:{style:ye},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:wr},rowGap:{style:Er},columnGap:{style:_r},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Le},maxWidth:{style:ds},minWidth:{transform:Le},height:{transform:Le},maxHeight:{transform:Le},minHeight:{transform:Le},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function Bf(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function $f(e,t){return typeof e=="function"?e(t):e}function Nf(){function e(n,r,o,s){const i={[n]:r,theme:o},a=s[n];if(!a)return{[n]:r};const{cssProperty:c=n,themeKey:u,transform:l,style:d}=a;if(r==null)return null;if(u==="typography"&&r==="inherit")return{[n]:r};const f=br(o,u)||{};return d?d(i):nt(i,r,p=>{let m=rr(f,l,p);return p===m&&typeof p=="string"&&(m=rr(f,l,`${n}${p==="default"?"":It(p)}`,p)),c===!1?m:{[c]:m}})}function t(n){const{sx:r,theme:o={},nested:s}=n||{};if(!r)return null;const i=o.unstable_sxConfig??Ar;function a(c){let u=c;if(typeof c=="function")u=c(o);else if(typeof c!="object")return c;if(!u)return null;const l=Jd(o.breakpoints),d=Object.keys(l);let f=l;return Object.keys(u).forEach(h=>{const p=$f(u[h],o);if(p!=null)if(typeof p=="object")if(i[h])f=yn(f,e(h,p,o,i));else{const m=nt({theme:o},p,v=>({[h]:v}));Bf(m,p)?f[h]=t({sx:p,theme:o,nested:!0}):f=yn(f,m)}else f=yn(f,e(h,p,o,i))}),!s&&o.modularCssLayers?{"@layer sx":pi(o,yi(d,f))}:pi(o,yi(d,f))}return Array.isArray(r)?r.map(a):a(r)}return t}const Ht=Nf();Ht.filterProps=["sx"];function Vf(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function fs(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(e<t||e>n)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Vf(e,t,n)}function Ff(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function mt(e){if(e.type)return e;if(e.charAt(0)==="#")return mt(Ff(e));const t=e.indexOf("("),n=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(n))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
62
+ The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:ht(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(o))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space.
63
+ The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:ht(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}const zf=e=>{const t=mt(e);return t.values.slice(0,3).map((n,r)=>t.type.includes("hsl")&&r!==0?`${n}%`:n).join(" ")},fn=(e,t)=>{try{return zf(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function Mr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.includes("rgb")?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.includes("hsl")&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.includes("color")?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function bc(e){e=mt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(u,l=(u+n/30)%12)=>o-s*Math.max(Math.min(l-3,9-l,1),-1);let a="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(a+="a",c.push(t[3])),Mr({type:a,values:c})}function _o(e){e=mt(e);let t=e.type==="hsl"||e.type==="hsla"?mt(bc(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function bi(e,t){const n=_o(e),r=_o(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function xc(e,t){return e=mt(e),t=fs(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Mr(e)}function bt(e,t,n){try{return xc(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function Pr(e,t){if(e=mt(e),t=fs(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let n=0;n<3;n+=1)e.values[n]*=1-t;return Mr(e)}function oe(e,t,n){try{return Pr(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function kr(e,t){if(e=mt(e),t=fs(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.includes("color"))for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return Mr(e)}function se(e,t,n){try{return kr(e,t)}catch{return n&&process.env.NODE_ENV!=="production"&&console.warn(n),e}}function Wf(e,t=.15){return _o(e)>.5?Pr(e,t):kr(e,t)}function Bn(e,t,n){try{return Wf(e,t)}catch{return e}}const Sn={black:"#000",white:"#fff"},Uf={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Rt={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Ot={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},sn={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Lt={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Dt={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},jt={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function Sc(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:Sn.white,default:Sn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const Tc=Sc();function Cc(){return{text:{primary:Sn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:Sn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const Eo=Cc();function xi(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=kr(e.main,o):t==="dark"&&(e.dark=Pr(e.main,s)))}function Si(e,t,n,r,o){const s=o.light||o,i=o.dark||o*1.5;t[n]||(t.hasOwnProperty(r)?t[n]=t[r]:n==="light"?t.light=`color-mix(in ${e}, ${t.main}, #fff ${(s*100).toFixed(0)}%)`:n==="dark"&&(t.dark=`color-mix(in ${e}, ${t.main}, #000 ${(i*100).toFixed(0)}%)`))}function Hf(e="light"){return e==="dark"?{main:Lt[200],light:Lt[50],dark:Lt[400]}:{main:Lt[700],light:Lt[400],dark:Lt[800]}}function Gf(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Kf(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Yf(e="light"){return e==="dark"?{main:Dt[400],light:Dt[300],dark:Dt[700]}:{main:Dt[700],light:Dt[500],dark:Dt[900]}}function Zf(e="light"){return e==="dark"?{main:jt[400],light:jt[300],dark:jt[700]}:{main:jt[800],light:jt[500],dark:jt[900]}}function qf(e="light"){return e==="dark"?{main:sn[400],light:sn[300],dark:sn[700]}:{main:"#ed6c02",light:sn[500],dark:sn[900]}}function Xf(e){return`oklch(from ${e} var(--__l) 0 h / var(--__a))`}function hs(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2,colorSpace:o,...s}=e,i=e.primary||Hf(t),a=e.secondary||Gf(t),c=e.error||Kf(t),u=e.info||Yf(t),l=e.success||Zf(t),d=e.warning||qf(t);function f(v){if(o)return Xf(v);const S=bi(v,Eo.text.primary)>=n?Eo.text.primary:Tc.text.primary;if(process.env.NODE_ENV!=="production"){const T=bi(v,S);T<3&&console.error([`MUI: The contrast ratio of ${T}:1 for ${S} on ${v}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
64
+ `))}return S}const h=({color:v,name:S,mainShade:T=500,lightShade:b=300,darkShade:w=700})=>{if(v={...v},!v.main&&v[T]&&(v.main=v[T]),!v.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${S?` (${S})`:""} provided to augmentColor(color) is invalid.
65
+ The color object needs to have a \`main\` property or a \`${T}\` property.`:ht(11,S?` (${S})`:"",T));if(typeof v.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${S?` (${S})`:""} provided to augmentColor(color) is invalid.
66
+ \`color.main\` should be a string, but \`${JSON.stringify(v.main)}\` was provided instead.
73
67
 
74
68
  Did you intend to use one of the following approaches?
75
69
 
@@ -81,19 +75,34 @@ const theme1 = createTheme({ palette: {
81
75
 
82
76
  const theme2 = createTheme({ palette: {
83
77
  primary: { main: green[500] },
84
- } });`:_n(12,v?` (${v})`:"",JSON.stringify(h.main)));return Fi(h,"light",S,r),Fi(h,"dark",y,r),h.contrastText||(h.contrastText=d(h.main)),h},p={dark:ao,light:Bi};return process.env.NODE_ENV!=="production"&&(p[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),tt(ce({common:ce({},An),mode:t,primary:f({color:s,name:"primary"}),secondary:f({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:f({color:a,name:"error"}),warning:f({color:l,name:"warning"}),info:f({color:c,name:"info"}),success:f({color:u,name:"success"}),grey:Kp,contrastThreshold:n,getContrastText:d,augmentColor:f,tonalOffset:r},p[t]),o)}const nm=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function rm(e){return Math.round(e*1e5)/1e5}const zi={textTransform:"uppercase"},Wi='"Roboto", "Helvetica", "Arial", sans-serif';function om(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Wi,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:a=500,fontWeightBold:c=700,htmlFontSize:u=16,allVariants:l,pxToRem:d}=n,f=St(n,nm);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof u!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const p=o/14,m=d||(b=>`${b/u*p}rem`),h=(b,S,y,C,T)=>ce({fontFamily:r,fontWeight:b,fontSize:m(S),lineHeight:y},r===Wi?{letterSpacing:`${rm(C/S)}em`}:{},T,l),v={h1:h(s,96,1.167,-1.5),h2:h(s,60,1.2,-.5),h3:h(i,48,1.167,0),h4:h(i,34,1.235,.25),h5:h(i,24,1.334,0),h6:h(a,20,1.6,.15),subtitle1:h(i,16,1.75,.15),subtitle2:h(a,14,1.57,.1),body1:h(i,16,1.5,.15),body2:h(i,14,1.43,.15),button:h(a,14,1.75,.4,zi),caption:h(i,12,1.66,.4),overline:h(i,12,2.66,1,zi),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return tt(ce({htmlFontSize:u,pxToRem:m,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:a,fontWeightBold:c},v),f,{clone:!1})}const sm=.2,im=.14,am=.12;function ue(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${sm})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${im})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${am})`].join(",")}const cm=["none",ue(0,2,1,-1,0,1,1,0,0,1,3,0),ue(0,3,1,-2,0,2,2,0,0,1,5,0),ue(0,3,3,-2,0,3,4,0,0,1,8,0),ue(0,2,4,-1,0,4,5,0,0,1,10,0),ue(0,3,5,-1,0,5,8,0,0,1,14,0),ue(0,3,5,-1,0,6,10,0,0,1,18,0),ue(0,4,5,-2,0,7,10,1,0,2,16,1),ue(0,5,5,-3,0,8,10,1,0,3,14,2),ue(0,5,6,-3,0,9,12,1,0,3,16,2),ue(0,6,6,-3,0,10,14,1,0,4,18,3),ue(0,6,7,-4,0,11,15,1,0,4,20,3),ue(0,7,8,-4,0,12,17,2,0,5,22,4),ue(0,7,8,-4,0,13,19,2,0,5,24,4),ue(0,7,9,-4,0,14,21,2,0,5,26,4),ue(0,8,9,-5,0,15,22,2,0,6,28,5),ue(0,8,10,-5,0,16,24,2,0,6,30,5),ue(0,8,11,-5,0,17,26,2,0,6,32,5),ue(0,9,11,-5,0,18,28,2,0,7,34,6),ue(0,9,12,-6,0,19,29,2,0,7,36,6),ue(0,10,13,-6,0,20,31,3,0,8,38,7),ue(0,10,13,-6,0,21,33,3,0,8,40,7),ue(0,10,14,-6,0,22,35,3,0,8,42,7),ue(0,11,14,-7,0,23,36,3,0,9,44,8),ue(0,11,15,-7,0,24,38,3,0,9,46,8)],lm=["duration","easing","delay"],um={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},dm={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ui(e){return`${Math.round(e)}ms`}function fm(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function hm(e){const t=ce({},um,e.easing),n=ce({},dm,e.duration);return ce({getAutoHeightDuration:fm,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:a=t.easeInOut,delay:c=0}=s,u=St(s,lm);if(process.env.NODE_ENV!=="production"){const l=f=>typeof f=="string",d=f=>!isNaN(parseFloat(f));!l(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!d(i)&&!l(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),l(a)||console.error('MUI: Argument "easing" must be a string.'),!d(c)&&!l(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
85
- `)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(l=>`${l} ${typeof i=="string"?i:Ui(i)} ${a} ${typeof c=="string"?c:Ui(c)}`).join(",")}},e,{easing:t,duration:n})}const pm={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},mm=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function gm(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=St(e,mm);if(e.vars&&e.generateCssVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":_n(18));const a=tm(r),c=Hc(e);let u=tt(c,{mixins:Op(c.breakpoints,n),palette:a,shadows:cm.slice(),typography:om(a,s),transitions:hm(o),zIndex:ce({},pm)});if(u=tt(u,i),u=t.reduce((l,d)=>tt(l,d),u),process.env.NODE_ENV!=="production"){const l=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],d=(f,p)=>{let m;for(m in f){const h=f[m];if(l.indexOf(m)!==-1&&Object.keys(h).length>0){if(process.env.NODE_ENV!=="production"){const v=ms("",m);console.error([`MUI: The \`${p}\` component increases the CSS specificity of the \`${m}\` internal state.`,"You can not override it like this: ",JSON.stringify(f,null,2),"",`Instead, you need to use the '&.${v}' syntax:`,JSON.stringify({root:{[`&.${v}`]:h}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
86
- `))}f[m]={}}}};Object.keys(u.components).forEach(f=>{const p=u.components[f].styleOverrides;p&&f.indexOf("Mui")===0&&d(p,f)})}return u.unstable_sxConfig=ce({},Vn,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(d){return Wr({sx:d,theme:this})},u}const ym=gm(),vm="$$material";function bm(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const xm=e=>bm(e)&&e!=="classes",Sm=yp({themeId:vm,defaultTheme:ym,rootShouldForwardProp:xm});function Tm(e){return ms("MuiSvgIcon",e)}yf("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const wm=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Cm=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ot(t)}`,`fontSize${Ot(n)}`]};return hf(o,Tm,r)},_m=Sm("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ot(n.color)}`],t[`fontSize${Ot(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,a,c,u,l,d,f,p,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((a=e.typography)==null||(c=a.pxToRem)==null?void 0:c.call(a,24))||"1.5rem",large:((u=e.typography)==null||(l=u.pxToRem)==null?void 0:l.call(u,35))||"2.1875rem"}[t.fontSize],color:(d=(f=(e.vars||e).palette)==null||(f=f[t.color])==null?void 0:f.main)!=null?d:{action:(p=(e.vars||e).palette)==null||(p=p.action)==null?void 0:p.active,disabled:(m=(e.vars||e).palette)==null||(m=m.action)==null?void 0:m.disabled,inherit:void 0}[t.color]}}),br=Fe.forwardRef(function(t,n){const r=Cf({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:a="svg",fontSize:c="medium",htmlColor:u,inheritViewBox:l=!1,titleAccess:d,viewBox:f="0 0 24 24"}=r,p=St(r,wm),m=Fe.isValidElement(o)&&o.type==="svg",h=ce({},r,{color:i,component:a,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:l,viewBox:f,hasSvgAsChild:m}),v={};l||(v.viewBox=f);const b=Cm(h);return g.jsxs(_m,ce({as:a,className:xf(b.root,s),focusable:"false",color:u,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:n},v,p,m&&o.props,{ownerState:h,children:[m?o.props.children:o,d?g.jsx("title",{children:d}):null]}))});process.env.NODE_ENV!=="production"&&(br.propTypes={children:Z.node,classes:Z.object,className:Z.string,color:Z.oneOfType([Z.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),Z.string]),component:Z.elementType,fontSize:Z.oneOfType([Z.oneOf(["inherit","large","medium","small"]),Z.string]),htmlColor:Z.string,inheritViewBox:Z.bool,shapeRendering:Z.string,sx:Z.oneOfType([Z.arrayOf(Z.oneOfType([Z.func,Z.object,Z.bool])),Z.func,Z.object]),titleAccess:Z.string,viewBox:Z.string});br.muiName="SvgIcon";function dt(e,t){function n(r,o){return g.jsx(br,ce({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=br.muiName,Fe.memo(Fe.forwardRef(n))}const Em=dt(g.jsx("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"}),"ExpandMore"),Pm=dt(g.jsx("path",{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"}),"ExpandLess"),Am=dt(g.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),Mm=(e,t)=>()=>{if(!t)return;const n={};e.forEach(r=>{r.items.forEach(o=>{o.value!==void 0&&o.value!==null&&o.value!==""&&(n[o.id]=o.value)})}),console.log("Filtros ativos:",n),t(n)},km=(e,t,n)=>()=>{const r=e.map(o=>({...o,items:o.items.map(s=>({...s,value:void 0}))}));n&&n(r),t&&t()},Rm=(e,t,n)=>()=>{const r=t.map(o=>o.id===e?{...o,expanded:!o.expanded}:o);n(r)},Om=(e,t,n,r)=>o=>{const s=n.map(i=>i.id===e?{...i,items:i.items.map(a=>a.id===t?{...a,value:o}:a)}:i);r(s)},Im="_modal_1v49l_1",jm="_content_1v49l_60",Lm="_contentWrapper_1v49l_67",Dm="_closeButton_1v49l_74",$m="_header_1v49l_86",Vm="_title_1v49l_93",Nm="_description_1v49l_102",Bm="_filtersContent_1v49l_111",Fm="_filterGroup_1v49l_121",zm="_expandableHeader_1v49l_128",Wm="_expandableLabel_1v49l_138",Um="_chevronIcon_1v49l_146",Hm="_chevron_1v49l_146",Gm="_filterItems_1v49l_159",Km="_filterItem_1v49l_159",Ym="_filterItemSize1_1v49l_171",qm="_filterItemSize2_1v49l_175",Zm="_filterItemSize3_1v49l_179",Xm="_filterItemSize4_1v49l_183",Jm="_filterItemSize5_1v49l_187",Qm="_filterItemSize6_1v49l_191",eg="_filterInput_1v49l_195",tg="_inputLabel_1v49l_199",ng="_select_1v49l_203",rg="_placeholder_1v49l_220",og="_helperText_1v49l_224",sg="_footer_1v49l_231",ig="_clearButton_1v49l_238",ag="_applyButton_1v49l_260",ae={modal:Im,content:jm,contentWrapper:Lm,closeButton:Dm,header:$m,title:Vm,description:Nm,filtersContent:Bm,filterGroup:Fm,expandableHeader:zm,expandableLabel:Wm,chevronIcon:Um,chevron:Hm,filterItems:Gm,filterItem:Km,filterItemSize1:Ym,filterItemSize2:qm,filterItemSize3:Zm,filterItemSize4:Xm,filterItemSize5:Jm,filterItemSize6:Qm,filterInput:eg,inputLabel:tg,select:ng,"Mui-focused":"_Mui-focused_1v49l_212",placeholder:rg,helperText:og,footer:sg,clearButton:ig,applyButton:ag},Qc=({open:e,onClose:t,title:n="Filtros",description:r="Use os filtros abaixo para encontrar câmeras e pontos de interesse.",groups:o,onApply:s,onClear:i,clearButtonText:a="Limpar filtros",applyButtonText:c="Filtrar",className:u,...l})=>{const f=_.useTheme().palette.mode==="dark",[p,m]=x.useState(o);x.useEffect(()=>{m(o)},[o]);const h=Mm(p,s),v=km(p,i,m),b=(S,y)=>{var P;const C=Om(y,S.id,p,m),T=S.size||6,E=ae[`filterItemSize${T}`];if(S.render)return g.jsx(_.Box,{className:`${ae.filterItem} ${E}`,children:S.render(S,C)},S.id);switch(S.type){case"select":case"multi-select":const A=S.type==="multi-select";let M;A?S.value!==void 0&&S.value!==null?M=Array.isArray(S.value)?S.value:[S.value]:M=[]:M=S.value!==void 0&&S.value!==null?S.value:"";const L=A?Array.isArray(M)&&M.length>0:M!==""&&M!==null&&M!==void 0;return g.jsx(_.Box,{className:`${ae.filterItem} ${E}`,children:g.jsxs(_.FormControl,{fullWidth:!0,className:ae.filterInput,children:[g.jsx(_.InputLabel,{id:`${S.id}-label`,className:ae.inputLabel,shrink:L,children:S.label}),g.jsx(_.Select,{labelId:`${S.id}-label`,value:M,onChange:$=>C($.target.value),multiple:A,label:S.label,className:ae.select,displayEmpty:!0,renderValue:$=>{var H;if(A){const q=Array.isArray($)?$:[];return q.length===0?g.jsx(_.Box,{component:"span",style:{opacity:0},children:S.label}):q.map(Q=>{var U,I;return((I=(U=S.options)==null?void 0:U.find(X=>X.value===Q))==null?void 0:I.label)||Q}).join(", ")}if(!$||$==="")return g.jsx(_.Box,{component:"span",style:{opacity:0},children:S.label});const W=(H=S.options)==null?void 0:H.find(q=>q.value===$);return(W==null?void 0:W.label)||$},notched:L,children:(P=S.options)==null?void 0:P.map($=>g.jsx(_.MenuItem,{value:$.value,children:$.label},$.value))}),S.helperText&&g.jsx(_.Box,{className:ae.helperText,children:S.helperText})]})},S.id);case"text":return g.jsx(_.Box,{className:`${ae.filterItem} ${E}`,children:g.jsx(_.TextField,{fullWidth:!0,label:S.label,placeholder:S.placeholder,value:S.value||"",onChange:$=>C($.target.value),className:ae.filterInput,helperText:S.helperText,FormHelperTextProps:{className:ae.helperText}})},S.id);default:return null}};return g.jsx(_.Dialog,{open:e,onClose:t,maxWidth:"md",fullWidth:!0,PaperProps:{className:`${ae.modal} ${u||""}`,"data-theme":f?"dark":"light"},...l,children:g.jsx(_.DialogContent,{className:ae.content,children:g.jsxs(_.Box,{className:ae.contentWrapper,children:[g.jsx(_.IconButton,{className:ae.closeButton,onClick:t,"aria-label":"Fechar",size:"small",children:g.jsx(Am,{})}),g.jsxs(_.Box,{className:ae.header,children:[g.jsx(_.Box,{className:ae.title,children:n}),g.jsx(_.Box,{className:ae.description,children:r})]}),g.jsx(_.Box,{className:ae.filtersContent,children:p.map(S=>{const y=Rm(S.id,p,m),C=S.expanded!==!1;return g.jsxs(_.Box,{className:ae.filterGroup,children:[g.jsxs(_.Box,{className:ae.expandableHeader,onClick:y,children:[g.jsx(_.Box,{className:ae.expandableLabel,children:S.label}),g.jsx(_.Box,{className:ae.chevronIcon,children:C?g.jsx(Pm,{className:ae.chevron}):g.jsx(Em,{className:ae.chevron})})]}),C&&g.jsx(_.Box,{className:ae.filterItems,children:S.items.map(T=>b(T,S.id))})]},S.id)})}),g.jsxs(_.Box,{className:ae.footer,children:[g.jsx(_.Button,{onClick:v,className:ae.clearButton,"data-theme":f?"dark":"light",children:a}),g.jsx(_.Button,{onClick:h,className:ae.applyButton,"data-theme":f?"dark":"light",children:c})]})]})})})};Qc.displayName="FilterModal";const cg="_container_1hyey_1",lg="_card_1hyey_7",ug="_icon_1hyey_18",dg="_text_1hyey_32",qn={container:cg,card:lg,icon:ug,text:dg},fg=({items:e,className:t,sx:n})=>{const r=_.useTheme(),o={backgroundColor:r.palette.background.paper,borderColor:r.palette.divider},s={color:r.palette.text.primary,"& svg":{fill:r.palette.text.primary}},i={color:r.palette.text.secondary,fontFamily:r.typography.fontFamily,fontSize:r.typography.body2.fontSize,fontWeight:r.typography.fontWeightMedium,lineHeight:r.typography.body2.lineHeight};return g.jsx(_.Box,{className:`${qn.container} ${t||""}`,sx:n,children:e.map((a,c)=>g.jsxs(_.Box,{className:qn.card,sx:o,children:[a.icon&&g.jsx(_.Box,{className:qn.icon,sx:s,children:a.icon}),g.jsxs(_.Typography,{component:"span",className:qn.text,sx:i,children:[a.count," ",a.label]})]},c))})},hg=(e,t=1,n=13)=>()=>{if(!e)return;const r=e.getZoom()??n;e.setZoom(r+t)},pg=(e,t=1,n=1,r=13)=>()=>{if(!e)return;const o=e.getZoom()??r;e.setZoom(Math.max(n,o-t))},mg="_container_1whpg_2",gg="_zoomButton_1whpg_10",yg="_stateLayer_1whpg_43",vg="_icon_1whpg_59",Qe={container:mg,zoomButton:gg,stateLayer:yg,icon:vg},bg=({map:e,className:t,sx:n,zoomIncrement:r=1,minZoom:o=1,fallbackZoom:s=13,onFullscreen:i})=>{const c=_.useTheme().palette.mode==="dark",u=hg(e,r,s),l=pg(e,r,o,s),d={backgroundColor:c?"#DEDDDD":"#101111","&:hover":{backgroundColor:c?"#DEDDDD":"#101111",opacity:.9}},f={fill:c?"#101111":"#FDFCFC",color:c?"#101111":"#FDFCFC"};return g.jsxs(_.Box,{className:`${Qe.container} ${t||""}`,sx:n,children:[g.jsx(_.IconButton,{className:Qe.zoomButton,onClick:u,"aria-label":"Zoom in",sx:d,children:g.jsx(_.Box,{className:Qe.stateLayer,children:g.jsx(Ve.Add,{className:Qe.icon,sx:f})})}),g.jsx(_.IconButton,{className:Qe.zoomButton,onClick:l,"aria-label":"Zoom out",sx:d,children:g.jsx(_.Box,{className:Qe.stateLayer,children:g.jsx(Ve.Remove,{className:Qe.icon,sx:f})})}),g.jsx(_.IconButton,{className:Qe.zoomButton,onClick:i,"aria-label":"Fullscreen",sx:d,children:g.jsx(_.Box,{className:Qe.stateLayer,children:g.jsx(Ve.ZoomOutMap,{className:Qe.icon,sx:f})})})]})};var xg=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,o,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(o=r;o--!==0;)if(!e(t[o],n[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(o=r;o--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[o]))return!1;for(o=r;o--!==0;){var i=s[o];if(!e(t[i],n[i]))return!1}return!0}return t!==t&&n!==n};const Sg=vc(xg),Tg="1.7.1";function Yt(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Do(e,t,n,r){function o(s){return s instanceof n?s:new n(function(i){i(s)})}return new(n||(n=Promise))(function(s,i){function a(l){try{u(r.next(l))}catch(d){i(d)}}function c(l){try{u(r.throw(l))}catch(d){i(d)}}function u(l){l.done?s(l.value):o(l.value).then(a,c)}u((r=r.apply(e,[])).next())})}const it={NOT_LOADED:"NOT_LOADED",LOADING:"LOADING",LOADED:"LOADED",FAILED:"FAILED",AUTH_FAILURE:"AUTH_FAILURE"},wg="https://maps.googleapis.com/maps/api/js";class xr{static load(t,n){return Do(this,void 0,void 0,function*(){var r,o;const s=t.libraries?t.libraries.split(","):[],i=this.serializeParams(t);this.listeners.push(n),!((o=(r=window.google)===null||r===void 0?void 0:r.maps)===null||o===void 0)&&o.importLibrary?(this.serializedApiParams||(this.loadingStatus=it.LOADED),this.notifyLoadingStatusListeners()):(this.serializedApiParams=i,this.initImportLibrary(t)),this.serializedApiParams&&this.serializedApiParams!==i&&console.warn("[google-maps-api-loader] The maps API has already been loaded with different parameters and will not be loaded again. Refresh the page for new values to have effect.");const a=["maps",...s];yield Promise.all(a.map(c=>google.maps.importLibrary(c)))})}static serializeParams(t){return[t.v,t.key,t.language,t.region,t.authReferrerPolicy,t.solutionChannel].join("/")}static initImportLibrary(t){if(window.google||(window.google={}),window.google.maps||(window.google.maps={}),window.google.maps.importLibrary){console.error("[google-maps-api-loader-internal]: initImportLibrary must only be called once");return}let n=null;const r=()=>n||(n=new Promise((o,s)=>{var i;const a=document.createElement("script"),c=new URLSearchParams;for(const[u,l]of Object.entries(t)){const d=u.replace(/[A-Z]/g,f=>"_"+f[0].toLowerCase());c.set(d,String(l))}c.set("loading","async"),c.set("callback","__googleMapsCallback__"),a.async=!0,a.src=wg+"?"+c.toString(),a.nonce=((i=document.querySelector("script[nonce]"))===null||i===void 0?void 0:i.nonce)||"",a.onerror=()=>{this.loadingStatus=it.FAILED,this.notifyLoadingStatusListeners(),s(new Error("The Google Maps JavaScript API could not load."))},window.__googleMapsCallback__=()=>{this.loadingStatus=it.LOADED,this.notifyLoadingStatusListeners(),o()},window.gm_authFailure=()=>{this.loadingStatus=it.AUTH_FAILURE,this.notifyLoadingStatusListeners()},this.loadingStatus=it.LOADING,this.notifyLoadingStatusListeners(),document.head.append(a)}),n);google.maps.importLibrary=o=>r().then(()=>google.maps.importLibrary(o))}static notifyLoadingStatusListeners(){for(const t of this.listeners)t(this.loadingStatus)}}xr.loadingStatus=it.NOT_LOADED;xr.listeners=[];const Cg="GMP_visgl_rgmlibrary_v1_default",_g=[`gmp_visgl_reactgooglemaps_v${Tg}`],Nn=x.createContext(null);function Eg(){const[e,t]=x.useState({});return{mapInstances:e,addMapInstance:(s,i="default")=>{t(a=>Object.assign(Object.assign({},a),{[i]:s}))},removeMapInstance:(s="default")=>{t(i=>{var a=s;i[a];var c=Yt(i,[typeof a=="symbol"?a:a+""]);return c})},clearMapInstances:()=>{t({})}}}function Pg(e){const{onLoad:t,onError:n,apiKey:r,version:o,libraries:s=[]}=e,i=Yt(e,["onLoad","onError","apiKey","version","libraries"]),[a,c]=x.useState(xr.loadingStatus),[u,l]=x.useReducer((m,h)=>m[h.name]?m:Object.assign(Object.assign({},m),{[h.name]:h.value}),{}),d=x.useMemo(()=>s==null?void 0:s.join(","),[s]),f=x.useMemo(()=>JSON.stringify(Object.assign({apiKey:r,version:o},i)),[r,o,i]),p=x.useCallback(m=>Do(this,void 0,void 0,function*(){var h;if(u[m])return u[m];if(!(!((h=google==null?void 0:google.maps)===null||h===void 0)&&h.importLibrary))throw new Error("[api-provider-internal] importLibrary was called before google.maps.importLibrary was defined.");const v=yield window.google.maps.importLibrary(m);return l({name:m,value:v}),v}),[u]);return x.useEffect(()=>{Do(this,void 0,void 0,function*(){try{const m=Object.assign({key:r},i);o&&(m.v=o),(d==null?void 0:d.length)>0&&(m.libraries=d),(m.channel===void 0||m.channel<0||m.channel>999)&&delete m.channel,m.solutionChannel===void 0?m.solutionChannel=Cg:m.solutionChannel===""&&delete m.solutionChannel,yield xr.load(m,h=>c(h));for(const h of["core","maps",...s])yield p(h);t&&t()}catch(m){n?n(m):console.error("<ApiProvider> failed to load the Google Maps JavaScript API",m)}})},[r,d,f]),{status:a,loadedLibraries:u,importLibrary:p}}function Ag(e){return x.useMemo(()=>e.disableUsageAttribution?null:_g,[e.disableUsageAttribution])}const Mg=e=>{const{children:t}=e,n=Yt(e,["children"]),{mapInstances:r,addMapInstance:o,removeMapInstance:s,clearMapInstances:i}=Eg(),{status:a,loadedLibraries:c,importLibrary:u}=Pg(n),l=Ag(n),d=x.useMemo(()=>({mapInstances:r,addMapInstance:o,removeMapInstance:s,clearMapInstances:i,status:a,loadedLibraries:c,importLibrary:u,internalUsageAttributionIds:l}),[r,o,s,i,a,c,u,l]);return x.createElement(Nn.Provider,{value:d},t)};function kg(e,t){for(const n of jg){const r=t[n],o=el[n];x.useEffect(()=>{if(!e||!r)return;const s=google.maps.event.addListener(e,o,i=>{r(Rg(o,e,i))});return()=>s.remove()},[e,o,r])}}function Rg(e,t,n){var r;const o={type:e,map:t,detail:{},stoppable:!1,stop:()=>{}};if(Og.includes(e)){const s=o,i=t.getCenter(),a=t.getZoom(),c=t.getHeading()||0,u=t.getTilt()||0,l=t.getBounds();return(!i||!l||!Number.isFinite(a))&&console.warn("[createEvent] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),s.detail={center:(i==null?void 0:i.toJSON())||{lat:0,lng:0},zoom:a||0,heading:c,tilt:u,bounds:(l==null?void 0:l.toJSON())||{north:90,east:180,south:-90,west:-180}},s}else if(Ig.includes(e)){if(!n)throw new Error("[createEvent] mouse events must provide a srcEvent");const s=o;return s.domEvent=n.domEvent,s.stoppable=!0,s.stop=()=>n.stop(),s.detail={latLng:((r=n.latLng)===null||r===void 0?void 0:r.toJSON())||null,placeId:n.placeId},s}return o}const el={onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onContextmenu:"contextmenu",onDblclick:"dblclick",onDrag:"drag",onDragend:"dragend",onDragstart:"dragstart",onHeadingChanged:"heading_changed",onIdle:"idle",onIsFractionalZoomEnabledChanged:"isfractionalzoomenabled_changed",onMapCapabilitiesChanged:"mapcapabilities_changed",onMapTypeIdChanged:"maptypeid_changed",onMousemove:"mousemove",onMouseout:"mouseout",onMouseover:"mouseover",onProjectionChanged:"projection_changed",onRenderingTypeChanged:"renderingtype_changed",onTilesLoaded:"tilesloaded",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed",onCameraChanged:"bounds_changed"},Og=["bounds_changed","center_changed","heading_changed","tilt_changed","zoom_changed"],Ig=["click","contextmenu","dblclick","mousemove","mouseout","mouseover"],jg=Object.keys(el);function Lg(e){const t=x.useRef(void 0);return x.useEffect(()=>{t.current=e}),t.current}function Dg(e,t){const n=Lg(e);return x.useMemo(()=>n&&t(n,e)?n:e,[e,n,t])}function $g(e,t,n){x.useEffect(e,[Dg(t,n)])}function Vg(e,t){$g(e,t,Sg)}const Ng=new Set(["backgroundColor","clickableIcons","controlSize","disableDefaultUI","disableDoubleClickZoom","draggable","draggableCursor","draggingCursor","fullscreenControl","fullscreenControlOptions","gestureHandling","headingInteractionEnabled","isFractionalZoomEnabled","keyboardShortcuts","mapTypeControl","mapTypeControlOptions","mapTypeId","maxZoom","minZoom","noClear","panControl","panControlOptions","restriction","rotateControl","rotateControlOptions","scaleControl","scaleControlOptions","scrollwheel","streetView","streetViewControl","streetViewControlOptions","styles","tiltInteractionEnabled","zoomControl","zoomControlOptions"]);function Bg(e,t){const n={},r=Object.keys(t);for(const o of r)Ng.has(o)&&(n[o]=t[o]);Vg(()=>{e&&e.setOptions(n)},[n])}function tl(){var e;return((e=x.useContext(Nn))===null||e===void 0?void 0:e.status)||it.NOT_LOADED}function Fg(e,t){const{viewport:n,viewState:r}=t,o=!!n;return x.useLayoutEffect(()=>{if(!e||!r)return;const{latitude:s,longitude:i,bearing:a,pitch:c,zoom:u}=r;e.moveCamera({center:{lat:s,lng:i},heading:a,tilt:c,zoom:u+1})},[e,r]),o}function zg(e){return!e||typeof e!="object"||!("lat"in e&&"lng"in e)?!1:Number.isFinite(e.lat)&&Number.isFinite(e.lng)}function nl(e){return zg(e)?e:e.toJSON()}function Wg(e,t,n){const r=n.center?nl(n.center):null;let o=null,s=null;r&&Number.isFinite(r.lat)&&Number.isFinite(r.lng)&&(o=r.lat,s=r.lng);const i=Number.isFinite(n.zoom)?n.zoom:null,a=Number.isFinite(n.heading)?n.heading:null,c=Number.isFinite(n.tilt)?n.tilt:null;x.useLayoutEffect(()=>{if(!e)return;const u={};let l=!1;o!==null&&s!==null&&(t.current.center.lat!==o||t.current.center.lng!==s)&&(u.center={lat:o,lng:s},l=!0),i!==null&&t.current.zoom!==i&&(u.zoom=i,l=!0),a!==null&&t.current.heading!==a&&(u.heading=a,l=!0),c!==null&&t.current.tilt!==c&&(u.tilt=c,l=!0),l&&e.moveCamera(u)})}const Ug=()=>{const e={position:"absolute",top:0,left:0,bottom:0,right:0,zIndex:999,display:"flex",flexFlow:"column nowrap",textAlign:"center",justifyContent:"center",fontSize:".8rem",color:"rgba(0,0,0,0.6)",background:"#dddddd",padding:"1rem 1.5rem"};return x.createElement("div",{style:e},x.createElement("h2",null,"Error: AuthFailure"),x.createElement("p",null,"A problem with your API key prevents the map from rendering correctly. Please make sure the value of the ",x.createElement("code",null,"APIProvider.apiKey")," prop is correct. Check the error-message in the console for further details."))};function Hg(){const[e,t]=x.useState(null),n=x.useCallback(r=>t(r),[t]);return[e,n]}function rl(){return tl()===it.LOADED}function Gg(){const[,e]=x.useReducer(t=>t+1,0);return e}function Kg(e,t){const n=e.getCenter(),r=e.getZoom(),o=e.getHeading()||0,s=e.getTilt()||0,i=e.getBounds();(!n||!i||!Number.isFinite(r))&&console.warn("[useTrackedCameraState] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),Object.assign(t.current,{center:(n==null?void 0:n.toJSON())||{lat:0,lng:0},zoom:r||0,heading:o,tilt:s})}function Yg(e){const t=Gg(),n=x.useRef({center:{lat:0,lng:0},heading:0,tilt:0,zoom:0});return x.useEffect(()=>{if(!e)return;const r=google.maps.event.addListener(e,"bounds_changed",()=>{Kg(e,n),t()});return()=>r.remove()},[e,t]),n}class lr{static has(t){return this.entries[t]&&this.entries[t].length>0}static pop(t){return this.entries[t]&&this.entries[t].pop()||null}static push(t,n){this.entries[t]||(this.entries[t]=[]),this.entries[t].push(n)}}lr.entries={};function qg(e,t){const n=rl(),[r,o]=x.useState(null),[s,i]=Hg(),a=Yg(r),{id:c,defaultBounds:u,defaultCenter:l,defaultZoom:d,defaultHeading:f,defaultTilt:p,reuseMaps:m,renderingType:h,colorScheme:v}=e,b=Yt(e,["id","defaultBounds","defaultCenter","defaultZoom","defaultHeading","defaultTilt","reuseMaps","renderingType","colorScheme"]),S=e.zoom!==void 0||e.defaultZoom!==void 0,y=e.center!==void 0||e.defaultCenter!==void 0;!u&&(!S||!y)&&console.warn("<Map> component is missing configuration. You have to provide zoom and center (via the `zoom`/`defaultZoom` and `center`/`defaultCenter` props) or specify the region to show using `defaultBounds`. See https://visgl.github.io/react-google-maps/docs/api-reference/components/map#required"),!b.center&&l&&(b.center=l),!b.zoom&&Number.isFinite(d)&&(b.zoom=d),!b.heading&&Number.isFinite(f)&&(b.heading=f),!b.tilt&&Number.isFinite(p)&&(b.tilt=p);const C=b.internalUsageAttributionIds;C==null?b.internalUsageAttributionIds=t.internalUsageAttributionIds:b.internalUsageAttributionIds=[...t.internalUsageAttributionIds||[],...C];for(const E of Object.keys(b))b[E]===void 0&&delete b[E];const T=x.useRef(void 0);return x.useEffect(()=>{if(!s||!n)return;const{addMapInstance:E,removeMapInstance:P}=t,{mapId:A}=e,M=`${A||"default"}:${h||"default"}:${v||"LIGHT"}`;let L,$;if(m&&lr.has(M)?($=lr.pop(M),L=$.getDiv(),s.appendChild(L),$.setOptions(b),setTimeout(()=>$.setCenter($.getCenter()),0)):(L=document.createElement("div"),L.style.height="100%",s.appendChild(L),$=new google.maps.Map(L,Object.assign(Object.assign(Object.assign({},b),h?{renderingType:h}:{}),v?{colorScheme:v}:{}))),o($),E($,c),u){const{padding:W}=u,H=Yt(u,["padding"]);$.fitBounds(H,W)}else(!S||!y)&&$.fitBounds({east:180,west:-180,south:-90,north:90});if(T.current){const{mapId:W,cameraState:H}=T.current;W!==A&&$.setOptions(H)}return()=>{T.current={mapId:A,cameraState:a.current},L.remove(),m?lr.push(M,$):google.maps.event.clearInstanceListeners($),o(null),P(c)}},[s,n,c,e.mapId,e.renderingType,e.colorScheme]),[r,i,a]}const ol=x.createContext(null),sl=e=>{const{children:t,id:n,className:r,style:o}=e,s=x.useContext(Nn),i=tl();if(!s)throw new Error("<Map> can only be used inside an <ApiProvider> component.");const[a,c,u]=qg(e,s);Wg(a,u,e),kg(a,e),Bg(a,e);const l=Fg(a,e),d=!!e.controlled;x.useEffect(()=>{if(a)return l&&a.setOptions({disableDefaultUI:!0}),(l||d)&&a.setOptions({gestureHandling:"none",keyboardShortcuts:!1}),()=>{a.setOptions({gestureHandling:e.gestureHandling,keyboardShortcuts:e.keyboardShortcuts})}},[a,l,d,e.gestureHandling,e.keyboardShortcuts]);const f=e.center?nl(e.center):null;let p=null,m=null;f&&Number.isFinite(f.lat)&&Number.isFinite(f.lng)&&(p=f.lat,m=f.lng);const h=x.useMemo(()=>{var S,y,C;return{center:{lat:p??0,lng:m??0},zoom:(S=e.zoom)!==null&&S!==void 0?S:0,heading:(y=e.heading)!==null&&y!==void 0?y:0,tilt:(C=e.tilt)!==null&&C!==void 0?C:0}},[p,m,e.zoom,e.heading,e.tilt]);x.useLayoutEffect(()=>{if(!a||!d)return;a.moveCamera(h);const S=a.addListener("bounds_changed",()=>{a.moveCamera(h)});return()=>S.remove()},[a,d,h]);const v=x.useMemo(()=>Object.assign({width:"100%",height:"100%",position:"relative",zIndex:l?-1:0},o),[o,l]),b=x.useMemo(()=>({map:a}),[a]);return i===it.AUTH_FAILURE?x.createElement("div",{style:Object.assign({position:"relative"},r?{}:v),className:r},x.createElement(Ug,null)):x.createElement("div",Object.assign({ref:c,"data-testid":"map",style:r?void 0:v,className:r},n?{id:n}:{}),a?x.createElement(ol.Provider,{value:b},t):null)};sl.deckGLViewProps=!0;const Hi=new Set;function Zg(...e){const t=JSON.stringify(e);Hi.has(t)||(Hi.add(t),console.error(...e))}const Ur=(e=null)=>{const t=x.useContext(Nn),{map:n}=x.useContext(ol)||{};if(t===null)return Zg("useMap(): failed to retrieve APIProviderContext. Make sure that the <APIProvider> component exists and that the component you are calling `useMap()` from is a sibling of the <APIProvider>."),null;const{mapInstances:r}=t;return e!==null?r[e]||null:n||r.default||null};function Xg(e){const t=rl(),n=x.useContext(Nn);return x.useEffect(()=>{!t||!n||n.importLibrary(e)},[t,n,e]),(n==null?void 0:n.loadedLibraries[e])||null}function Zn(e,t,n){x.useEffect(()=>{if(!e||!t||!n)return;const r=google.maps.event.addListener(e,t,n);return()=>r.remove()},[e,t,n])}function Xn(e,t,n){x.useEffect(()=>{e&&(e[t]=n)},[e,t,n])}function Gi(e,t,n){x.useEffect(()=>{if(!(!e||!t||!n))return e.addEventListener(t,n),()=>e.removeEventListener(t,n)},[e,t,n])}class Jg{constructor(){this.renderedStyles=new Set,this.styleElement=null}getStyleElement(){return this.styleElement||(this.styleElement=document.createElement("style"),this.styleElement.setAttribute("data-rgm-anchor-styles",""),document.head.appendChild(this.styleElement)),this.styleElement}addAdvancedMarkerPointerEventsOverwrite(){if(this.renderedStyles.has("marker-pointer-events"))return;const t=this.getStyleElement();t.textContent+=`
87
- gmp-advanced-marker[data-origin='rgm'] {
88
- pointer-events: none !important;
89
- }
90
- `,this.renderedStyles.add("marker-pointer-events")}cleanup(){this.styleElement&&(this.styleElement.remove(),this.styleElement=null,this.renderedStyles.clear())}}const Qg=new Jg;function e0(e,t){var n;if(!(!((n=google==null?void 0:google.maps)===null||n===void 0)&&n.version))return;const r=google.maps.version.split("."),o=parseInt(r[0],10),s=parseInt(r[1],10);return o>e||o===e&&s>=t}const t0=x.createContext(null),n0={BOTTOM:["50%","100%"]},il=x.forwardRef((e,t)=>{const{children:n,style:r,className:o,anchorPoint:s}=e,[i,a]=o0(e),c=x.useMemo(()=>i?{marker:i}:null,[i]);return x.useImperativeHandle(t,()=>i,[i]),a?x.createElement(t0.Provider,{value:c},Cd.createPortal(x.createElement(r0,{anchorPoint:s,styles:r,className:o},n),a)):null});il.displayName="AdvancedMarker";function $o(e){return e.nodeType===Node.ELEMENT_NODE}const r0=({children:e,styles:t,className:n})=>x.createElement("div",{className:n,style:t},e);function o0(e){const[t,n]=x.useState(null),[r,o]=x.useState(null),s=Ur(),i=Xg("marker"),{children:a,onClick:c,className:u,onMouseEnter:l,onMouseLeave:d,onDrag:f,onDragStart:p,onDragEnd:m,collisionBehavior:h,clickable:v,draggable:b,position:S,title:y,zIndex:C,anchorPoint:T,anchorLeft:E,anchorTop:P}=e,A=x.Children.count(a);return x.useEffect(()=>{if(!s||!i)return;const M=new i.AdvancedMarkerElement;M.map=s,n(M);let L=null;return A>0&&(L=document.createElement("div"),M.content=L,o(L)),()=>{M.map=null,L==null||L.remove(),n(null),o(null)}},[s,i,A]),x.useEffect(()=>{!(t!=null&&t.content)||!$o(t.content)||A>0||(t.content.className=u??"")},[t,u,A]),s0(t,T,E,P,A>0),Xn(t,"position",S),Xn(t,"title",y??""),Xn(t,"zIndex",C),Xn(t,"collisionBehavior",h),x.useEffect(()=>{t&&(b!==void 0?t.gmpDraggable=b:f||p||m?t.gmpDraggable=!0:t.gmpDraggable=!1)},[t,b,f,m,p]),x.useEffect(()=>{if(!t)return;const M=v!==void 0||!!c||!!l||!!d;t.gmpClickable=M,M&&(t!=null&&t.content)&&$o(t.content)&&(t.content.style.pointerEvents="all",c&&(t.content.style.cursor="pointer"))},[t,v,c,l,d]),Zn(t,"click",c),Zn(t,"drag",f),Zn(t,"dragstart",p),Zn(t,"dragend",m),Gi(t==null?void 0:t.element,"mouseenter",l),Gi(t==null?void 0:t.element,"mouseleave",d),[t,r]}function s0(e,t,n,r,o){x.useEffect(()=>{if(!e||!o)return;const s=e0(3,62),i=e.content;if(!(!i||!$o(i))){if(n!==void 0||r!==void 0){s||console.warn(`AdvancedMarker: The anchorLeft and anchorTop props are only supported in Google Maps API version 3.62 and above. The current version is ${google.maps.version}.`),e.anchorLeft=n,e.anchorTop=r,t!==void 0&&console.warn("AdvancedMarker: the anchorPoint prop is ignored when anchorLeft and/or anchorTop are set.");return}if(t!==void 0){const[a,c]=t??n0.BOTTOM,u=`calc(-1 * ${a})`,l=`calc(-1 * ${c})`;s?(e.anchorLeft=u,e.anchorTop=l,i.style.transform=""):(i.style.transform=`translate(50%, 100%) translate(${u}, ${l})`,e.dataset.origin="rgm",Qg.addAdvancedMarkerPointerEventsOverwrite())}}},[e,t,n,r,o])}function i0(e){const[t,n]=x.useState(null),r=Ur(),{onClick:o,onDrag:s,onDragStart:i,onDragEnd:a,onMouseOver:c,onMouseOut:u}=e,l=Yt(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut"]),{position:d,draggable:f}=l;return x.useEffect(()=>{if(!r){r===void 0&&console.error("<Marker> has to be inside a Map component.");return}const p=new google.maps.Marker(l);return p.setMap(r),n(p),()=>{p.setMap(null),n(null)}},[r]),x.useEffect(()=>{if(!t)return;const p=t,m=google.maps.event;return o&&m.addListener(p,"click",o),s&&m.addListener(p,"drag",s),i&&m.addListener(p,"dragstart",i),a&&m.addListener(p,"dragend",a),c&&m.addListener(p,"mouseover",c),u&&m.addListener(p,"mouseout",u),t.setDraggable(!!f),()=>{m.clearInstanceListeners(p)}},[t,f,o,s,i,a,c,u]),x.useEffect(()=>{t&&l&&t.setOptions(l)},[t,l]),x.useEffect(()=>{f||!d||!t||t.setPosition(d)},[f,d,t]),t}const a0=x.forwardRef((e,t)=>{const n=i0(e);return x.useImperativeHandle(t,()=>n,[n]),x.createElement(x.Fragment,null)});a0.displayName="Marker";const al=x.createContext(void 0),cl=()=>{const e=x.useContext(al);if(!e)throw new Error("useGoogleMapContext must be used within GoogleMap component");return e},Cs=({children:e})=>{const t=Ur(),n=(r,o=16)=>{t&&(t.setCenter(r),t.setZoom(o))};return t?g.jsx(al.Provider,{value:{isLoaded:!0,map:t,zoomToPosition:n},children:e}):null};Cs.displayName="MapContent";const c0="_googleMap_j4y4m_1",l0="_container_j4y4m_10",u0="_errorContainer_j4y4m_21",Jn={googleMap:c0,container:l0,errorContainer:u0},d0={lat:-26.3044,lng:-48.8487},f0=13,h0={disableDefaultUI:!0,zoomControl:!1,streetViewControl:!1,mapTypeControl:!1,fullscreenControl:!1,rotateControl:!1,scaleControl:!1,panControl:!1,clickableIcons:!1,keyboardShortcuts:!1},p0=({colorScheme:e,options:t,onLoad:n,children:r})=>{const o=Ur();return x.useEffect(()=>{o&&(o.setOptions(h0),t&&o.setOptions(t),n&&n(o))},[o,t,n]),g.jsx(g.Fragment,{children:r})},ll=({center:e=d0,zoom:t=f0,className:n,children:r,apiKey:o,mapId:s,themeMode:i="light",options:a,onLoad:c,onError:u})=>{if(!o||!s)return g.jsx("div",{className:`${Jn.container} ${Jn.errorContainer} ${n||""}`,children:g.jsxs("div",{children:[g.jsx("p",{children:"Google Maps não configurado"}),g.jsx("p",{style:{fontSize:"14px",marginTop:"8px",opacity:.7},children:"As props apiKey e mapId são obrigatórias"})]})});const l=i==="dark"?"DARK":"LIGHT",d={defaultCenter:e,defaultZoom:t,mapId:s,className:Jn.googleMap,colorScheme:l},f=`${s}-${l}`;return g.jsx(Mg,{apiKey:o,onLoad:()=>{console.log("Google Maps API carregada com sucesso")},onError:p=>{console.error("Erro ao carregar Google Maps API:",p),u&&p instanceof Error&&u(p)},children:g.jsx("div",{className:`${Jn.container} ${n||""}`,style:{width:"100%",height:"400px",minHeight:"400px",position:"relative"},children:g.jsx(sl,{...d,style:{width:"100%",height:"100%"},children:g.jsx(p0,{colorScheme:l,options:a,onLoad:c,children:g.jsx(Cs,{children:r})})},f)})})};ll.displayName="GoogleMap";const _s=x.createContext({});function Es(e){const t=x.useRef(null);return t.current===null&&(t.current=e()),t.current}const ul=typeof window<"u",dl=ul?x.useLayoutEffect:x.useEffect,Hr=x.createContext(null);function Ps(e,t){e.indexOf(t)===-1&&e.push(t)}function As(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const st=(e,t,n)=>n>t?t:n<e?e:n;function Vo(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let Qt=()=>{},lt=()=>{};var hc;typeof process<"u"&&((hc=process.env)==null?void 0:hc.NODE_ENV)!=="production"&&(Qt=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(Vo(t,n))},lt=(e,t,n)=>{if(!e)throw new Error(Vo(t,n))});const ut={},fl=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function hl(e){return typeof e=="object"&&e!==null}const pl=e=>/^0[^.\s]+$/u.test(e);function Ms(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ge=e=>e,m0=(e,t)=>n=>t(e(n)),Bn=(...e)=>e.reduce(m0),Mn=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class ks{constructor(){this.subscriptions=[]}add(t){return Ps(this.subscriptions,t),()=>As(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let s=0;s<o;s++){const i=this.subscriptions[s];i&&i(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const rt=e=>e*1e3,He=e=>e/1e3;function ml(e,t){return t?e*(1e3/t):0}const Ki=new Set;function Rs(e,t,n){e||Ki.has(t)||(console.warn(Vo(t,n)),Ki.add(t))}const gl=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,g0=1e-7,y0=12;function v0(e,t,n,r,o){let s,i,a=0;do i=t+(n-t)/2,s=gl(i,r,o)-e,s>0?n=i:t=i;while(Math.abs(s)>g0&&++a<y0);return i}function Fn(e,t,n,r){if(e===t&&n===r)return Ge;const o=s=>v0(s,0,1,e,n);return s=>s===0||s===1?s:gl(o(s),t,r)}const yl=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,vl=e=>t=>1-e(1-t),bl=Fn(.33,1.53,.69,.99),Os=vl(bl),xl=yl(Os),Sl=e=>(e*=2)<1?.5*Os(e):.5*(2-Math.pow(2,-10*(e-1))),Is=e=>1-Math.sin(Math.acos(e)),Tl=vl(Is),wl=yl(Is),b0=Fn(.42,0,1,1),x0=Fn(0,0,.58,1),Cl=Fn(.42,0,.58,1),S0=e=>Array.isArray(e)&&typeof e[0]!="number",_l=e=>Array.isArray(e)&&typeof e[0]=="number",Yi={linear:Ge,easeIn:b0,easeInOut:Cl,easeOut:x0,circIn:Is,circInOut:wl,circOut:Tl,backIn:Os,backInOut:xl,backOut:bl,anticipate:Sl},T0=e=>typeof e=="string",qi=e=>{if(_l(e)){lt(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,o]=e;return Fn(t,n,r,o)}else if(T0(e))return lt(Yi[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),Yi[e];return e},Qn=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function w0(e,t){let n=new Set,r=new Set,o=!1,s=!1;const i=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function c(l){i.has(l)&&(u.schedule(l),e()),l(a)}const u={schedule:(l,d=!1,f=!1)=>{const m=f&&o?n:r;return d&&i.add(l),m.has(l)||m.add(l),l},cancel:l=>{r.delete(l),i.delete(l)},process:l=>{if(a=l,o){s=!0;return}o=!0,[n,r]=[r,n],n.forEach(c),n.clear(),o=!1,s&&(s=!1,u.process(l))}};return u}const C0=40;function El(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,i=Qn.reduce((y,C)=>(y[C]=w0(s),y),{}),{setup:a,read:c,resolveKeyframes:u,preUpdate:l,update:d,preRender:f,render:p,postRender:m}=i,h=()=>{const y=ut.useManualTiming?o.timestamp:performance.now();n=!1,ut.useManualTiming||(o.delta=r?1e3/60:Math.max(Math.min(y-o.timestamp,C0),1)),o.timestamp=y,o.isProcessing=!0,a.process(o),c.process(o),u.process(o),l.process(o),d.process(o),f.process(o),p.process(o),m.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(h))},v=()=>{n=!0,r=!0,o.isProcessing||e(h)};return{schedule:Qn.reduce((y,C)=>{const T=i[C];return y[C]=(E,P=!1,A=!1)=>(n||v(),T.schedule(E,P,A)),y},{}),cancel:y=>{for(let C=0;C<Qn.length;C++)i[Qn[C]].cancel(y)},state:o,steps:i}}const{schedule:le,cancel:vt,state:Me,steps:co}=El(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ge,!0);let ur;function _0(){ur=void 0}const Le={now:()=>(ur===void 0&&Le.set(Me.isProcessing||ut.useManualTiming?Me.timestamp:performance.now()),ur),set:e=>{ur=e,queueMicrotask(_0)}},Pl=e=>t=>typeof t=="string"&&t.startsWith(e),Al=Pl("--"),E0=Pl("var(--"),js=e=>E0(e)?P0.test(e.split("/*")[0].trim()):!1,P0=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Zi(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const en={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},kn={...en,transform:e=>st(0,1,e)},er={...en,default:1},Tn=e=>Math.round(e*1e5)/1e5,Ls=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function A0(e){return e==null}const M0=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Ds=(e,t)=>n=>!!(typeof n=="string"&&M0.test(n)&&n.startsWith(e)||t&&!A0(n)&&Object.prototype.hasOwnProperty.call(n,t)),Ml=(e,t,n)=>r=>{if(typeof r!="string")return r;const[o,s,i,a]=r.match(Ls);return{[e]:parseFloat(o),[t]:parseFloat(s),[n]:parseFloat(i),alpha:a!==void 0?parseFloat(a):1}},k0=e=>st(0,255,e),lo={...en,transform:e=>Math.round(k0(e))},Mt={test:Ds("rgb","red"),parse:Ml("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+lo.transform(e)+", "+lo.transform(t)+", "+lo.transform(n)+", "+Tn(kn.transform(r))+")"};function R0(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const No={test:Ds("#"),parse:R0,transform:Mt.transform},zn=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),ht=zn("deg"),ot=zn("%"),B=zn("px"),O0=zn("vh"),I0=zn("vw"),Xi={...ot,parse:e=>ot.parse(e)/100,transform:e=>ot.transform(e*100)},Vt={test:Ds("hsl","hue"),parse:Ml("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ot.transform(Tn(t))+", "+ot.transform(Tn(n))+", "+Tn(kn.transform(r))+")"},Se={test:e=>Mt.test(e)||No.test(e)||Vt.test(e),parse:e=>Mt.test(e)?Mt.parse(e):Vt.test(e)?Vt.parse(e):No.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Mt.transform(e):Vt.transform(e),getAnimatableNone:e=>{const t=Se.parse(e);return t.alpha=0,Se.transform(t)}},j0=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function L0(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Ls))==null?void 0:t.length)||0)+(((n=e.match(j0))==null?void 0:n.length)||0)>0}const kl="number",Rl="color",D0="var",$0="var(",Ji="${}",V0=/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 Rn(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let s=0;const a=t.replace(V0,c=>(Se.test(c)?(r.color.push(s),o.push(Rl),n.push(Se.parse(c))):c.startsWith($0)?(r.var.push(s),o.push(D0),n.push(c)):(r.number.push(s),o.push(kl),n.push(parseFloat(c))),++s,Ji)).split(Ji);return{values:n,split:a,indexes:r,types:o}}function Ol(e){return Rn(e).values}function Il(e){const{split:t,types:n}=Rn(e),r=t.length;return o=>{let s="";for(let i=0;i<r;i++)if(s+=t[i],o[i]!==void 0){const a=n[i];a===kl?s+=Tn(o[i]):a===Rl?s+=Se.transform(o[i]):s+=o[i]}return s}}const N0=e=>typeof e=="number"?0:Se.test(e)?Se.getAnimatableNone(e):e;function B0(e){const t=Ol(e);return Il(e)(t.map(N0))}const bt={test:L0,parse:Ol,createTransformer:Il,getAnimatableNone:B0};function uo(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function F0({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,s=0,i=0;if(!t)o=s=i=n;else{const a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;o=uo(c,a,e+1/3),s=uo(c,a,e),i=uo(c,a,e-1/3)}return{red:Math.round(o*255),green:Math.round(s*255),blue:Math.round(i*255),alpha:r}}function Sr(e,t){return n=>n>0?t:e}const fe=(e,t,n)=>e+(t-e)*n,fo=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},z0=[No,Mt,Vt],W0=e=>z0.find(t=>t.test(e));function Qi(e){const t=W0(e);if(Qt(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===Vt&&(n=F0(n)),n}const ea=(e,t)=>{const n=Qi(e),r=Qi(t);if(!n||!r)return Sr(e,t);const o={...n};return s=>(o.red=fo(n.red,r.red,s),o.green=fo(n.green,r.green,s),o.blue=fo(n.blue,r.blue,s),o.alpha=fe(n.alpha,r.alpha,s),Mt.transform(o))},Bo=new Set(["none","hidden"]);function U0(e,t){return Bo.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function H0(e,t){return n=>fe(e,t,n)}function $s(e){return typeof e=="number"?H0:typeof e=="string"?js(e)?Sr:Se.test(e)?ea:Y0:Array.isArray(e)?jl:typeof e=="object"?Se.test(e)?ea:G0:Sr}function jl(e,t){const n=[...e],r=n.length,o=e.map((s,i)=>$s(s)(s,t[i]));return s=>{for(let i=0;i<r;i++)n[i]=o[i](s);return n}}function G0(e,t){const n={...e,...t},r={};for(const o in n)e[o]!==void 0&&t[o]!==void 0&&(r[o]=$s(e[o])(e[o],t[o]));return o=>{for(const s in r)n[s]=r[s](o);return n}}function K0(e,t){const n=[],r={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){const s=t.types[o],i=e.indexes[s][r[s]],a=e.values[i]??0;n[o]=a,r[s]++}return n}const Y0=(e,t)=>{const n=bt.createTransformer(t),r=Rn(e),o=Rn(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?Bo.has(e)&&!o.values.length||Bo.has(t)&&!r.values.length?U0(e,t):Bn(jl(K0(r,o),o.values),n):(Qt(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Sr(e,t))};function Ll(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?fe(e,t,n):$s(e)(e,t)}const q0=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>le.update(t,n),stop:()=>vt(t),now:()=>Me.isProcessing?Me.timestamp:Le.now()}},Dl=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let s=0;s<o;s++)r+=Math.round(e(s/(o-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},Tr=2e4;function Vs(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Tr;)t+=n,r=e.next(t);return t>=Tr?1/0:t}function Z0(e,t=100,n){const r=n({...e,keyframes:[0,t]}),o=Math.min(Vs(r),Tr);return{type:"keyframes",ease:s=>r.next(o*s).value/t,duration:He(o)}}const X0=5;function $l(e,t,n){const r=Math.max(t-X0,0);return ml(n-e(r),t-r)}const de={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},ho=.001;function J0({duration:e=de.duration,bounce:t=de.bounce,velocity:n=de.velocity,mass:r=de.mass}){let o,s;Qt(e<=rt(de.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let i=1-t;i=st(de.minDamping,de.maxDamping,i),e=st(de.minDuration,de.maxDuration,He(e)),i<1?(o=u=>{const l=u*i,d=l*e,f=l-n,p=Fo(u,i),m=Math.exp(-d);return ho-f/p*m},s=u=>{const d=u*i*e,f=d*n+n,p=Math.pow(i,2)*Math.pow(u,2)*e,m=Math.exp(-d),h=Fo(Math.pow(u,2),i);return(-o(u)+ho>0?-1:1)*((f-p)*m)/h}):(o=u=>{const l=Math.exp(-u*e),d=(u-n)*e+1;return-ho+l*d},s=u=>{const l=Math.exp(-u*e),d=(n-u)*(e*e);return l*d});const a=5/e,c=ey(o,s,a);if(e=rt(e),isNaN(c))return{stiffness:de.stiffness,damping:de.damping,duration:e};{const u=Math.pow(c,2)*r;return{stiffness:u,damping:i*2*Math.sqrt(r*u),duration:e}}}const Q0=12;function ey(e,t,n){let r=n;for(let o=1;o<Q0;o++)r=r-e(r)/t(r);return r}function Fo(e,t){return e*Math.sqrt(1-t*t)}const ty=["duration","bounce"],ny=["stiffness","damping","mass"];function ta(e,t){return t.some(n=>e[n]!==void 0)}function ry(e){let t={velocity:de.velocity,stiffness:de.stiffness,damping:de.damping,mass:de.mass,isResolvedFromDuration:!1,...e};if(!ta(e,ny)&&ta(e,ty))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),o=r*r,s=2*st(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:de.mass,stiffness:o,damping:s}}else{const n=J0(e);t={...t,...n,mass:de.mass},t.isResolvedFromDuration=!0}return t}function wr(e=de.visualDuration,t=de.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const s=n.keyframes[0],i=n.keyframes[n.keyframes.length-1],a={done:!1,value:s},{stiffness:c,damping:u,mass:l,duration:d,velocity:f,isResolvedFromDuration:p}=ry({...n,velocity:-He(n.velocity||0)}),m=f||0,h=u/(2*Math.sqrt(c*l)),v=i-s,b=He(Math.sqrt(c/l)),S=Math.abs(v)<5;r||(r=S?de.restSpeed.granular:de.restSpeed.default),o||(o=S?de.restDelta.granular:de.restDelta.default);let y;if(h<1){const T=Fo(b,h);y=E=>{const P=Math.exp(-h*b*E);return i-P*((m+h*b*v)/T*Math.sin(T*E)+v*Math.cos(T*E))}}else if(h===1)y=T=>i-Math.exp(-b*T)*(v+(m+b*v)*T);else{const T=b*Math.sqrt(h*h-1);y=E=>{const P=Math.exp(-h*b*E),A=Math.min(T*E,300);return i-P*((m+h*b*v)*Math.sinh(A)+T*v*Math.cosh(A))/T}}const C={calculatedDuration:p&&d||null,next:T=>{const E=y(T);if(p)a.done=T>=d;else{let P=T===0?m:0;h<1&&(P=T===0?rt(m):$l(y,T,E));const A=Math.abs(P)<=r,M=Math.abs(i-E)<=o;a.done=A&&M}return a.value=a.done?i:E,a},toString:()=>{const T=Math.min(Vs(C),Tr),E=Dl(P=>C.next(T*P).value,T,30);return T+"ms "+E},toTransition:()=>{}};return C}wr.applyToOptions=e=>{const t=Z0(e,100,wr);return e.ease=t.ease,e.duration=rt(t.duration),e.type="keyframes",e};function zo({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:s=500,modifyTarget:i,min:a,max:c,restDelta:u=.5,restSpeed:l}){const d=e[0],f={done:!1,value:d},p=A=>a!==void 0&&A<a||c!==void 0&&A>c,m=A=>a===void 0?c:c===void 0||Math.abs(a-A)<Math.abs(c-A)?a:c;let h=n*t;const v=d+h,b=i===void 0?v:i(v);b!==v&&(h=b-d);const S=A=>-h*Math.exp(-A/r),y=A=>b+S(A),C=A=>{const M=S(A),L=y(A);f.done=Math.abs(M)<=u,f.value=f.done?b:L};let T,E;const P=A=>{p(f.value)&&(T=A,E=wr({keyframes:[f.value,m(f.value)],velocity:$l(y,A,f.value),damping:o,stiffness:s,restDelta:u,restSpeed:l}))};return P(0),{calculatedDuration:null,next:A=>{let M=!1;return!E&&T===void 0&&(M=!0,C(A),P(A)),T!==void 0&&A>=T?E.next(A-T):(!M&&C(A),f)}}}function oy(e,t,n){const r=[],o=n||ut.mix||Ll,s=e.length-1;for(let i=0;i<s;i++){let a=o(e[i],e[i+1]);if(t){const c=Array.isArray(t)?t[i]||Ge:t;a=Bn(c,a)}r.push(a)}return r}function sy(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const s=e.length;if(lt(s===t.length,"Both input and output ranges must be the same length","range-length"),s===1)return()=>t[0];if(s===2&&t[0]===t[1])return()=>t[1];const i=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=oy(t,r,o),c=a.length,u=l=>{if(i&&l<e[0])return t[0];let d=0;if(c>1)for(;d<e.length-2&&!(l<e[d+1]);d++);const f=Mn(e[d],e[d+1],l);return a[d](f)};return n?l=>u(st(e[0],e[s-1],l)):u}function iy(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=Mn(0,t,r);e.push(fe(n,1,o))}}function ay(e){const t=[0];return iy(t,e.length-1),t}function cy(e,t){return e.map(n=>n*t)}function ly(e,t){return e.map(()=>t||Cl).splice(0,e.length-1)}function Nt({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=S0(r)?r.map(qi):qi(r),s={done:!1,value:t[0]},i=cy(n&&n.length===t.length?n:ay(t),e),a=sy(i,t,{ease:Array.isArray(o)?o:ly(t,o)});return{calculatedDuration:e,next:c=>(s.value=a(c),s.done=c>=e,s)}}const uy=e=>e!==null;function Ns(e,{repeat:t,repeatType:n="loop"},r,o=1){const s=e.filter(uy),a=o<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!a||r===void 0?s[a]:r}const dy={decay:zo,inertia:zo,tween:Nt,keyframes:Nt,spring:wr};function Vl(e){typeof e.type=="string"&&(e.type=dy[e.type])}class Bs{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const fy=e=>e/100;class Fs extends Bs{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,o;const{motionValue:n}=this.options;n&&n.updatedAt!==Le.now()&&this.tick(Le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(o=(r=this.options).onStop)==null||o.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Vl(t);const{type:n=Nt,repeat:r=0,repeatDelay:o=0,repeatType:s,velocity:i=0}=t;let{keyframes:a}=t;const c=n||Nt;process.env.NODE_ENV!=="production"&&c!==Nt&&lt(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),c!==Nt&&typeof a[0]!="number"&&(this.mixKeyframes=Bn(fy,Ll(a[0],a[1])),a=[0,100]);const u=c({...t,keyframes:a});s==="mirror"&&(this.mirroredGenerator=c({...t,keyframes:[...a].reverse(),velocity:-i})),u.calculatedDuration===null&&(u.calculatedDuration=Vs(u));const{calculatedDuration:l}=u;this.calculatedDuration=l,this.resolvedDuration=l+o,this.totalDuration=this.resolvedDuration*(r+1)-o,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:o,mixKeyframes:s,mirroredGenerator:i,resolvedDuration:a,calculatedDuration:c}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:l,repeat:d,repeatType:f,repeatDelay:p,type:m,onUpdate:h,finalKeyframe:v}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-o/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const b=this.currentTime-u*(this.playbackSpeed>=0?1:-1),S=this.playbackSpeed>=0?b<0:b>o;this.currentTime=Math.max(b,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let y=this.currentTime,C=r;if(d){const A=Math.min(this.currentTime,o)/a;let M=Math.floor(A),L=A%1;!L&&A>=1&&(L=1),L===1&&M--,M=Math.min(M,d+1),!!(M%2)&&(f==="reverse"?(L=1-L,p&&(L-=p/a)):f==="mirror"&&(C=i)),y=st(0,1,L)*a}const T=S?{done:!1,value:l[0]}:C.next(y);s&&(T.value=s(T.value));let{done:E}=T;!S&&c!==null&&(E=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);const P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&E);return P&&m!==zo&&(T.value=Ns(l,this.options,v,this.speed)),h&&h(T.value),P&&this.finish(),T}then(t,n){return this.finished.then(t,n)}get duration(){return He(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+He(t)}get time(){return He(this.currentTime)}set time(t){var n;t=rt(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),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=He(this.currentTime))}play(){var o,s;if(this.isStopped)return;const{driver:t=q0,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),(s=(o=this.options).onPlay)==null||s.call(o);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=n??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(Le.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.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 n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function hy(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const kt=e=>e*180/Math.PI,Wo=e=>{const t=kt(Math.atan2(e[1],e[0]));return Uo(t)},py={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Wo,rotateZ:Wo,skewX:e=>kt(Math.atan(e[1])),skewY:e=>kt(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Uo=e=>(e=e%360,e<0&&(e+=360),e),na=Wo,ra=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),oa=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),my={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:ra,scaleY:oa,scale:e=>(ra(e)+oa(e))/2,rotateX:e=>Uo(kt(Math.atan2(e[6],e[5]))),rotateY:e=>Uo(kt(Math.atan2(-e[2],e[0]))),rotateZ:na,rotate:na,skewX:e=>kt(Math.atan(e[4])),skewY:e=>kt(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Ho(e){return e.includes("scale")?1:0}function Go(e,t){if(!e||e==="none")return Ho(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,o;if(n)r=my,o=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=py,o=a}if(!o)return Ho(t);const s=r[t],i=o[1].split(",").map(yy);return typeof s=="function"?s(i):i[s]}const gy=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return Go(n,t)};function yy(e){return parseFloat(e.trim())}const tn=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],nn=new Set(tn),sa=e=>e===en||e===B,vy=new Set(["x","y","z"]),by=tn.filter(e=>!vy.has(e));function xy(e){const t=[];return by.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const gt={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>Go(t,"x"),y:(e,{transform:t})=>Go(t,"y")};gt.translateX=gt.x;gt.translateY=gt.y;const Rt=new Set;let Ko=!1,Yo=!1,qo=!1;function Nl(){if(Yo){const e=Array.from(Rt).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const o=xy(r);o.length&&(n.set(r,o),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const o=n.get(r);o&&o.forEach(([s,i])=>{var a;(a=r.getValue(s))==null||a.set(i)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Yo=!1,Ko=!1,Rt.forEach(e=>e.complete(qo)),Rt.clear()}function Bl(){Rt.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Yo=!0)})}function Sy(){qo=!0,Bl(),Nl(),qo=!1}class zs{constructor(t,n,r,o,s,i=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=o,this.element=s,this.isAsync=i}scheduleResolve(){this.state="scheduled",this.isAsync?(Rt.add(this),Ko||(Ko=!0,le.read(Bl),le.resolveKeyframes(Nl))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:o}=this;if(t[0]===null){const s=o==null?void 0:o.get(),i=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const a=r.readValue(n,i);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=i),o&&s===void 0&&o.set(t[0])}hy(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Rt.delete(this)}cancel(){this.state==="scheduled"&&(Rt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Ty=e=>e.startsWith("--");function wy(e,t,n){Ty(t)?e.style.setProperty(t,n):e.style[t]=n}const Cy=Ms(()=>window.ScrollTimeline!==void 0),_y={};function Ey(e,t){const n=Ms(e);return()=>_y[t]??n()}const Fl=Ey(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),gn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,ia={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:gn([0,.65,.55,1]),circOut:gn([.55,0,1,.45]),backIn:gn([.31,.01,.66,-.59]),backOut:gn([.33,1.53,.69,.99])};function zl(e,t){if(e)return typeof e=="function"?Fl()?Dl(e,t):"ease-out":_l(e)?gn(e):Array.isArray(e)?e.map(n=>zl(n,t)||ia.easeOut):ia[e]}function Py(e,t,n,{delay:r=0,duration:o=300,repeat:s=0,repeatType:i="loop",ease:a="easeOut",times:c}={},u=void 0){const l={[t]:n};c&&(l.offset=c);const d=zl(a,o);Array.isArray(d)&&(l.easing=d);const f={delay:r,duration:o,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:s+1,direction:i==="reverse"?"alternate":"normal"};return u&&(f.pseudoElement=u),e.animate(l,f)}function Wl(e){return typeof e=="function"&&"applyToOptions"in e}function Ay({type:e,...t}){return Wl(e)&&Fl()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class My extends Bs{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:o,pseudoElement:s,allowFlatten:i=!1,finalKeyframe:a,onComplete:c}=t;this.isPseudoElement=!!s,this.allowFlatten=i,this.options=t,lt(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const u=Ay(t);this.animation=Py(n,r,o,u,s),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const l=Ns(o,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(l):wy(n,r,l),this.animation.cancel()}c==null||c(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.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 t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return He(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+He(t)}get time(){return He(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=rt(t)}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,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&Cy()?(this.animation.timeline=t,Ge):n(this)}}const Ul={anticipate:Sl,backInOut:xl,circInOut:wl};function ky(e){return e in Ul}function Ry(e){typeof e.ease=="string"&&ky(e.ease)&&(e.ease=Ul[e.ease])}const po=10;class Oy extends My{constructor(t){Ry(t),Vl(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:o,element:s,...i}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new Fs({...i,autoplay:!1}),c=Math.max(po,Le.now()-this.startTime),u=st(0,po,c-po);n.setWithVelocity(a.sample(Math.max(0,c-u)).value,a.sample(c).value,u),a.stop()}}const aa=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(bt.test(e)||e==="0")&&!e.startsWith("url("));function Iy(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function jy(e,t,n,r){const o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;const s=e[e.length-1],i=aa(o,t),a=aa(s,t);return Qt(i===a,`You are trying to animate ${t} from "${o}" to "${s}". "${i?s:o}" is not an animatable value.`,"value-not-animatable"),!i||!a?!1:Iy(e)||(n==="spring"||Wl(n))&&r}function Zo(e){e.duration=0,e.type="keyframes"}const Ly=new Set(["opacity","clipPath","filter","transform"]),Dy=Ms(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function $y(e){var l;const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:s,type:i}=e;if(!(((l=t==null?void 0:t.owner)==null?void 0:l.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:u}=t.owner.getProps();return Dy()&&n&&Ly.has(n)&&(n!=="transform"||!u)&&!c&&!r&&o!=="mirror"&&s!==0&&i!=="inertia"}const Vy=40;class Ny extends Bs{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:i="loop",keyframes:a,name:c,motionValue:u,element:l,...d}){var m;super(),this.stop=()=>{var h,v;this._animation&&(this._animation.stop(),(h=this.stopTimeline)==null||h.call(this)),(v=this.keyframeResolver)==null||v.cancel()},this.createdAt=Le.now();const f={autoplay:t,delay:n,type:r,repeat:o,repeatDelay:s,repeatType:i,name:c,motionValue:u,element:l,...d},p=(l==null?void 0:l.KeyframeResolver)||zs;this.keyframeResolver=new p(a,(h,v,b)=>this.onKeyframesResolved(h,v,f,!b),c,u,l),(m=this.keyframeResolver)==null||m.scheduleResolve()}onKeyframesResolved(t,n,r,o){var v,b;this.keyframeResolver=void 0;const{name:s,type:i,velocity:a,delay:c,isHandoff:u,onUpdate:l}=r;this.resolvedAt=Le.now(),jy(t,s,i,a)||((ut.instantAnimations||!c)&&(l==null||l(Ns(t,r,n))),t[0]=t[t.length-1],Zo(r),r.repeat=0);const f={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>Vy?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},p=!u&&$y(f),m=(b=(v=f.motionValue)==null?void 0:v.owner)==null?void 0:b.current,h=p?new Oy({...f,element:m}):new Fs(f);h.finished.then(()=>{this.notifyFinished()}).catch(Ge),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),Sy()),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 Hl(e,t,n,r=0,o=1){const s=Array.from(e).sort((u,l)=>u.sortNodePosition(l)).indexOf(t),i=e.size,a=(i-1)*r;return typeof n=="function"?n(s,i):o===1?s*r:a-s*r}const By=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Fy(e){const t=By.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${n??r}`,o]}const zy=4;function Gl(e,t,n=1){lt(n<=zy,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,o]=Fy(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const i=s.trim();return fl(i)?parseFloat(i):i}return js(o)?Gl(o,t,n+1):o}const Wy={type:"spring",stiffness:500,damping:25,restSpeed:10},Uy=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Hy={type:"keyframes",duration:.8},Gy={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Ky=(e,{keyframes:t})=>t.length>2?Hy:nn.has(e)?e.startsWith("scale")?Uy(t[1]):Wy:Gy,Yy=e=>e!==null;function qy(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(Yy),s=t&&n!=="loop"&&t%2===1?0:o.length-1;return o[s]}function Ws(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}function Zy({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:s,repeatType:i,repeatDelay:a,from:c,elapsed:u,...l}){return!!Object.keys(l).length}const Us=(e,t,n,r={},o,s)=>i=>{const a=Ws(r,e)||{},c=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-rt(c);const l={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{i(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:s?void 0:o};Zy(a)||Object.assign(l,Ky(e,l)),l.duration&&(l.duration=rt(l.duration)),l.repeatDelay&&(l.repeatDelay=rt(l.repeatDelay)),l.from!==void 0&&(l.keyframes[0]=l.from);let d=!1;if((l.type===!1||l.duration===0&&!l.repeatDelay)&&(Zo(l),l.delay===0&&(d=!0)),(ut.instantAnimations||ut.skipAnimations)&&(d=!0,Zo(l),l.delay=0),l.allowFlatten=!a.type&&!a.ease,d&&!s&&t.get()!==void 0){const f=qy(l.keyframes,a);if(f!==void 0){le.update(()=>{l.onUpdate(f),l.onComplete()});return}}return a.isSync?new Fs(l):new Ny(l)};function ca(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Hs(e,t,n,r){if(typeof t=="function"){const[o,s]=ca(r);t=t(n!==void 0?n:e.custom,o,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[o,s]=ca(r);t=t(n!==void 0?n:e.custom,o,s)}return t}function Gt(e,t,n){const r=e.getProps();return Hs(r,t,n!==void 0?n:r.custom,e)}const Kl=new Set(["width","height","top","left","right","bottom",...tn]),la=30,Xy=e=>!isNaN(parseFloat(e));class Jy{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var s;const o=Le.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((s=this.events.change)==null||s.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=Xy(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&Rs(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new ks);const r=this.events[t].add(n);return t==="change"?()=>{r(),le.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&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=Le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>la)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,la);return ml(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),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,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function qt(e,t){return new Jy(e,t)}const Xo=e=>Array.isArray(e);function Qy(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,qt(n))}function ev(e){return Xo(e)?e[e.length-1]||0:e}function tv(e,t){const n=Gt(e,t);let{transitionEnd:r={},transition:o={},...s}=n||{};s={...s,...r};for(const i in s){const a=ev(s[i]);Qy(e,i,a)}}const Oe=e=>!!(e&&e.getVelocity);function nv(e){return!!(Oe(e)&&e.add)}function Jo(e,t){const n=e.getValue("willChange");if(nv(n))return n.add(t);if(!n&&ut.WillChange){const r=new ut.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function Gs(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const rv="framerAppearId",Yl="data-"+Gs(rv);function ql(e){return e.props[Yl]}function ov({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function Zl(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:i,...a}=t;const c=s==null?void 0:s.reduceMotion;r&&(s=r);const u=[],l=o&&e.animationState&&e.animationState.getState()[o];for(const d in a){const f=e.getValue(d,e.latestValues[d]??null),p=a[d];if(p===void 0||l&&ov(l,d))continue;const m={delay:n,...Ws(s||{},d)},h=f.get();if(h!==void 0&&!f.isAnimating&&!Array.isArray(p)&&p===h&&!m.velocity)continue;let v=!1;if(window.MotionHandoffAnimation){const y=ql(e);if(y){const C=window.MotionHandoffAnimation(y,d,le);C!==null&&(m.startTime=C,v=!0)}}Jo(e,d);const b=c??e.shouldReduceMotion;f.start(Us(d,f,p,b&&Kl.has(d)?{type:!1}:m,e,v));const S=f.animation;S&&u.push(S)}return i&&Promise.all(u).then(()=>{le.update(()=>{i&&tv(e,i)})}),u}function Qo(e,t,n={}){var c;const r=Gt(e,t,n.type==="exit"?(c=e.presenceContext)==null?void 0:c.custom:void 0);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const s=r?()=>Promise.all(Zl(e,r,n)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:l=0,staggerChildren:d,staggerDirection:f}=o;return sv(e,t,u,l,d,f,n)}:()=>Promise.resolve(),{when:a}=o;if(a){const[u,l]=a==="beforeChildren"?[s,i]:[i,s];return u().then(()=>l())}else return Promise.all([s(),i(n.delay)])}function sv(e,t,n=0,r=0,o=0,s=1,i){const a=[];for(const c of e.variantChildren)c.notify("AnimationStart",t),a.push(Qo(c,t,{...i,delay:n+(typeof r=="function"?0:r)+Hl(e.variantChildren,c,r,o,s)}).then(()=>c.notify("AnimationComplete",t)));return Promise.all(a)}function iv(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(s=>Qo(e,s,n));r=Promise.all(o)}else if(typeof t=="string")r=Qo(e,t,n);else{const o=typeof t=="function"?Gt(e,t,n.custom):t;r=Promise.all(Zl(e,o,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const av={test:e=>e==="auto",parse:e=>e},Xl=e=>t=>t.test(e),Jl=[en,B,ot,ht,I0,O0,av],ua=e=>Jl.find(Xl(e));function cv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||pl(e):!0}const lv=new Set(["brightness","contrast","saturate","opacity"]);function uv(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Ls)||[];if(!r)return e;const o=n.replace(r,"");let s=lv.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+o+")"}const dv=/\b([a-z-]*)\(.*?\)/gu,es={...bt,getAnimatableNone:e=>{const t=e.match(dv);return t?t.map(uv).join(" "):e}},da={...en,transform:Math.round},fv={rotate:ht,rotateX:ht,rotateY:ht,rotateZ:ht,scale:er,scaleX:er,scaleY:er,scaleZ:er,skew:ht,skewX:ht,skewY:ht,distance:B,translateX:B,translateY:B,translateZ:B,x:B,y:B,z:B,perspective:B,transformPerspective:B,opacity:kn,originX:Xi,originY:Xi,originZ:B},Ks={borderWidth:B,borderTopWidth:B,borderRightWidth:B,borderBottomWidth:B,borderLeftWidth:B,borderRadius:B,borderTopLeftRadius:B,borderTopRightRadius:B,borderBottomRightRadius:B,borderBottomLeftRadius:B,width:B,maxWidth:B,height:B,maxHeight:B,top:B,right:B,bottom:B,left:B,inset:B,insetBlock:B,insetBlockStart:B,insetBlockEnd:B,insetInline:B,insetInlineStart:B,insetInlineEnd:B,padding:B,paddingTop:B,paddingRight:B,paddingBottom:B,paddingLeft:B,paddingBlock:B,paddingBlockStart:B,paddingBlockEnd:B,paddingInline:B,paddingInlineStart:B,paddingInlineEnd:B,margin:B,marginTop:B,marginRight:B,marginBottom:B,marginLeft:B,marginBlock:B,marginBlockStart:B,marginBlockEnd:B,marginInline:B,marginInlineStart:B,marginInlineEnd:B,fontSize:B,backgroundPositionX:B,backgroundPositionY:B,...fv,zIndex:da,fillOpacity:kn,strokeOpacity:kn,numOctaves:da},hv={...Ks,color:Se,backgroundColor:Se,outlineColor:Se,fill:Se,stroke:Se,borderColor:Se,borderTopColor:Se,borderRightColor:Se,borderBottomColor:Se,borderLeftColor:Se,filter:es,WebkitFilter:es},Ql=e=>hv[e];function eu(e,t){let n=Ql(e);return n!==es&&(n=bt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const pv=new Set(["auto","none","0"]);function mv(e,t,n){let r=0,o;for(;r<e.length&&!o;){const s=e[r];typeof s=="string"&&!pv.has(s)&&Rn(s).values.length&&(o=e[r]),r++}if(o&&n)for(const s of t)e[s]=eu(n,o)}class gv extends zs{constructor(t,n,r,o,s){super(t,n,r,o,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let d=t[l];if(typeof d=="string"&&(d=d.trim(),js(d))){const f=Gl(d,n.current);f!==void 0&&(t[l]=f),l===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!Kl.has(r)||t.length!==2)return;const[o,s]=t,i=ua(o),a=ua(s),c=Zi(o),u=Zi(s);if(c!==u&&gt[r]){this.needsMeasurement=!0;return}if(i!==a)if(sa(i)&&sa(a))for(let l=0;l<t.length;l++){const d=t[l];typeof d=="string"&&(t[l]=parseFloat(d))}else gt[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let o=0;o<t.length;o++)(t[o]===null||cv(t[o]))&&r.push(o);r.length&&mv(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=gt[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const o=n[n.length-1];o!==void 0&&t.getValue(r,o).jump(o,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const o=t.getValue(n);o&&o.jump(this.measuredOrigin,!1);const s=r.length-1,i=r[s];r[s]=gt[n](t.measureViewportBox(),window.getComputedStyle(t.current)),i!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=i),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([c,u])=>{t.getValue(c).set(u)}),this.resolveNoneKeyframes()}}function yv(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const o=(n==null?void 0:n[e])??r.querySelectorAll(e);return o?Array.from(o):[]}return Array.from(e).filter(r=>r!=null)}const tu=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function ts(e){return hl(e)&&"offsetHeight"in e}const{schedule:Ys}=El(queueMicrotask,!1),Ze={x:!1,y:!1};function nu(){return Ze.x||Ze.y}function vv(e){return e==="x"||e==="y"?Ze[e]?null:(Ze[e]=!0,()=>{Ze[e]=!1}):Ze.x||Ze.y?null:(Ze.x=Ze.y=!0,()=>{Ze.x=Ze.y=!1})}function ru(e,t){const n=yv(e),r=new AbortController,o={passive:!0,...t,signal:r.signal};return[n,o,()=>r.abort()]}function fa(e){return!(e.pointerType==="touch"||nu())}function bv(e,t,n={}){const[r,o,s]=ru(e,n),i=a=>{if(!fa(a))return;const{target:c}=a,u=t(c,a);if(typeof u!="function"||!c)return;const l=d=>{fa(d)&&(u(d),c.removeEventListener("pointerleave",l))};c.addEventListener("pointerleave",l,o)};return r.forEach(a=>{a.addEventListener("pointerenter",i,o)}),s}const ou=(e,t)=>t?e===t?!0:ou(e,t.parentElement):!1,qs=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,xv=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function su(e){return xv.has(e.tagName)||e.isContentEditable===!0}const dr=new WeakSet;function ha(e){return t=>{t.key==="Enter"&&e(t)}}function mo(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Sv=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=ha(()=>{if(dr.has(n))return;mo(n,"down");const o=ha(()=>{mo(n,"up")}),s=()=>mo(n,"cancel");n.addEventListener("keyup",o,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function pa(e){return qs(e)&&!nu()}function Tv(e,t,n={}){const[r,o,s]=ru(e,n),i=a=>{const c=a.currentTarget;if(!pa(a))return;dr.add(c);const u=t(c,a),l=(p,m)=>{window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",f),dr.has(c)&&dr.delete(c),pa(p)&&typeof u=="function"&&u(p,{success:m})},d=p=>{l(p,c===window||c===document||n.useGlobalTarget||ou(c,p.target))},f=p=>{l(p,!1)};window.addEventListener("pointerup",d,o),window.addEventListener("pointercancel",f,o)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",i,o),ts(a)&&(a.addEventListener("focus",u=>Sv(u,o)),!su(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),s}function iu(e){return hl(e)&&"ownerSVGElement"in e}function wv(e){return iu(e)&&e.tagName==="svg"}const Cv=[...Jl,Se,bt],_v=e=>Cv.find(Xl(e)),ma=()=>({translate:0,scale:1,origin:0,originPoint:0}),Bt=()=>({x:ma(),y:ma()}),ga=()=>({min:0,max:0}),Ce=()=>({x:ga(),y:ga()}),ns={current:null},au={current:!1},Ev=typeof window<"u";function Pv(){if(au.current=!0,!!Ev)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>ns.current=e.matches;e.addEventListener("change",t),t()}else ns.current=!1}const Av=new WeakMap;function Gr(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function On(e){return typeof e=="string"||Array.isArray(e)}const Zs=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Xs=["initial",...Zs];function Kr(e){return Gr(e.animate)||Xs.some(t=>On(e[t]))}function cu(e){return!!(Kr(e)||e.variants)}function Mv(e,t,n){for(const r in t){const o=t[r],s=n[r];if(Oe(o))e.addValue(r,o);else if(Oe(s))e.addValue(r,qt(o,{owner:e}));else if(s!==o)if(e.hasValue(r)){const i=e.getValue(r);i.liveStyle===!0?i.jump(o):i.hasAnimated||i.set(o)}else{const i=e.getStaticValue(r);e.addValue(r,qt(i!==void 0?i:o,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const ya=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let Cr={};function lu(e){Cr=e}function kv(){return Cr}class Rv{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,blockInitialAnimation:s,visualState:i},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=zs,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},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 f=Le.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,le.render(this.render,!1,!0))};const{latestValues:c,renderState:u}=i;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.blockInitialAnimation=!!s,this.isControllingVariants=Kr(n),this.isVariantNode=cu(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in d){const p=d[f];c[f]!==void 0&&Oe(p)&&p.set(c[f])}}mount(t){var n;this.current=t,Av.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,o)=>this.bindToMotionValue(o,r)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(au.current||Pv(),this.shouldReduceMotion=ns.current),process.env.NODE_ENV!=="production"&&Rs(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),vt(this.notifyUpdate),vt(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];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,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=nn.has(t);r&&this.onBindTransform&&this.onBindTransform();const o=n.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&le.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;typeof window<"u"&&window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{o(),s&&s(),n.owner&&n.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 Cr){const n=Cr[t];if(!n)continue;const{isEnabled:r,Feature:o}=n;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ce()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<ya.length;r++){const o=ya[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const s="on"+o,i=t[s];i&&(this.propEventSubscriptions[o]=this.on(o,i))}this.prevMotionValues=Mv(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=qt(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){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"&&(fl(r)||pl(r))?r=parseFloat(r):!_v(r)&&bt.test(n)&&(r=eu(t,n)),this.setBaseTarget(t,Oe(r)?r.get():r)),Oe(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var s;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const i=Hs(this.props,n,(s=this.presenceContext)==null?void 0:s.custom);i&&(r=i[t])}if(n&&r!==void 0)return r;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Oe(o)?o:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new ks),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Ys.render(this.render)}}class uu extends Rv{constructor(){super(...arguments),this.KeyframeResolver=gv}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Oe(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class wt{constructor(t){this.isMounted=!1,this.node=t}update(){}}function du({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function Ov({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function Iv(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function go(e){return e===void 0||e===1}function rs({scale:e,scaleX:t,scaleY:n}){return!go(e)||!go(t)||!go(n)}function At(e){return rs(e)||fu(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function fu(e){return va(e.x)||va(e.y)}function va(e){return e&&e!=="0%"}function _r(e,t,n){const r=e-n,o=t*r;return n+o}function ba(e,t,n,r,o){return o!==void 0&&(e=_r(e,o,r)),_r(e,n,r)+t}function os(e,t=0,n=1,r,o){e.min=ba(e.min,t,n,r,o),e.max=ba(e.max,t,n,r,o)}function hu(e,{x:t,y:n}){os(e.x,t.translate,t.scale,t.originPoint),os(e.y,n.translate,n.scale,n.originPoint)}const xa=.999999999999,Sa=1.0000000000001;function jv(e,t,n,r=!1){const o=n.length;if(!o)return;t.x=t.y=1;let s,i;for(let a=0;a<o;a++){s=n[a],i=s.projectionDelta;const{visualElement:c}=s.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&zt(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),i&&(t.x*=i.x.scale,t.y*=i.y.scale,hu(e,i)),r&&At(s.latestValues)&&zt(e,s.latestValues))}t.x<Sa&&t.x>xa&&(t.x=1),t.y<Sa&&t.y>xa&&(t.y=1)}function Ft(e,t){e.min=e.min+t,e.max=e.max+t}function Ta(e,t,n,r,o=.5){const s=fe(e.min,e.max,o);os(e,t,n,s,r)}function zt(e,t){Ta(e.x,t.x,t.scaleX,t.scale,t.originX),Ta(e.y,t.y,t.scaleY,t.scale,t.originY)}function pu(e,t){return du(Iv(e.getBoundingClientRect(),t))}function Lv(e,t,n){const r=pu(e,n),{scroll:o}=t;return o&&(Ft(r.x,o.offset.x),Ft(r.y,o.offset.y)),r}const Dv={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},$v=tn.length;function Vv(e,t,n){let r="",o=!0;for(let s=0;s<$v;s++){const i=tn[s],a=e[i];if(a===void 0)continue;let c=!0;if(typeof a=="number")c=a===(i.startsWith("scale")?1:0);else{const u=parseFloat(a);c=i.startsWith("scale")?u===1:u===0}if(!c||n){const u=tu(a,Ks[i]);if(!c){o=!1;const l=Dv[i]||i;r+=`${l}(${u}) `}n&&(t[i]=u)}}return r=r.trim(),n?r=n(t,o?"":r):o&&(r="none"),r}function Js(e,t,n){const{style:r,vars:o,transformOrigin:s}=e;let i=!1,a=!1;for(const c in t){const u=t[c];if(nn.has(c)){i=!0;continue}else if(Al(c)){o[c]=u;continue}else{const l=tu(u,Ks[c]);c.startsWith("origin")?(a=!0,s[c]=l):r[c]=l}}if(t.transform||(i||n?r.transform=Vv(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:c="50%",originY:u="50%",originZ:l=0}=s;r.transformOrigin=`${c} ${u} ${l}`}}function mu(e,{style:t,vars:n},r,o){const s=e.style;let i;for(i in t)s[i]=t[i];o==null||o.applyProjectionStyles(s,r);for(i in n)s.setProperty(i,n[i])}function wa(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const hn={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(B.test(e))e=parseFloat(e);else return e;const n=wa(e,t.target.x),r=wa(e,t.target.y);return`${n}% ${r}%`}},Nv={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=bt.parse(e);if(o.length>5)return r;const s=bt.createTransformer(e),i=typeof o[0]!="number"?1:0,a=n.x.scale*t.x,c=n.y.scale*t.y;o[0+i]/=a,o[1+i]/=c;const u=fe(a,c,.5);return typeof o[2+i]=="number"&&(o[2+i]/=u),typeof o[3+i]=="number"&&(o[3+i]/=u),s(o)}},ss={borderRadius:{...hn,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:hn,borderTopRightRadius:hn,borderBottomLeftRadius:hn,borderBottomRightRadius:hn,boxShadow:Nv};function gu(e,{layout:t,layoutId:n}){return nn.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ss[e]||e==="opacity")}function Qs(e,t,n){var i;const r=e.style,o=t==null?void 0:t.style,s={};if(!r)return s;for(const a in r)(Oe(r[a])||o&&Oe(o[a])||gu(a,e)||((i=n==null?void 0:n.getValue(a))==null?void 0:i.liveStyle)!==void 0)&&(s[a]=r[a]);return s}function Bv(e){return window.getComputedStyle(e)}class Fv extends uu{constructor(){super(...arguments),this.type="html",this.renderInstance=mu}readValueFromInstance(t,n){var r;if(nn.has(n))return(r=this.projection)!=null&&r.isProjecting?Ho(n):gy(t,n);{const o=Bv(t),s=(Al(n)?o.getPropertyValue(n):o[n])||0;return typeof s=="string"?s.trim():s}}measureInstanceViewportBox(t,{transformPagePoint:n}){return pu(t,n)}build(t,n,r){Js(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Qs(t,n,r)}}const zv={offset:"stroke-dashoffset",array:"stroke-dasharray"},Wv={offset:"strokeDashoffset",array:"strokeDasharray"};function Uv(e,t,n=1,r=0,o=!0){e.pathLength=1;const s=o?zv:Wv;e[s.offset]=`${-r}`,e[s.array]=`${t} ${n}`}const Hv=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function yu(e,{attrX:t,attrY:n,attrScale:r,pathLength:o,pathSpacing:s=1,pathOffset:i=0,...a},c,u,l){if(Js(e,a,u),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:d,style:f}=e;d.transform&&(f.transform=d.transform,delete d.transform),(f.transform||d.transformOrigin)&&(f.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),f.transform&&(f.transformBox=(l==null?void 0:l.transformBox)??"fill-box",delete d.transformBox);for(const p of Hv)d[p]!==void 0&&(f[p]=d[p],delete d[p]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),o!==void 0&&Uv(d,o,s,i,!1)}const vu=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"]),bu=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Gv(e,t,n,r){mu(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(vu.has(o)?o:Gs(o),t.attrs[o])}function xu(e,t,n){const r=Qs(e,t,n);for(const o in e)if(Oe(e[o])||Oe(t[o])){const s=tn.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[s]=e[o]}return r}class Kv extends uu{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ce}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(nn.has(n)){const r=Ql(n);return r&&r.default||0}return n=vu.has(n)?n:Gs(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return xu(t,n,r)}build(t,n,r){yu(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,o){Gv(t,n,r,o)}mount(t){this.isSVGTag=bu(t.tagName),super.mount(t)}}const Yv=Xs.length;function Su(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Su(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<Yv;n++){const r=Xs[n],o=e.props[r];(On(o)||o===!1)&&(t[r]=o)}return t}function Tu(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const qv=[...Zs].reverse(),Zv=Zs.length;function Xv(e){return t=>Promise.all(t.map(({animation:n,options:r})=>iv(e,n,r)))}function Jv(e){let t=Xv(e),n=Ca(),r=!0;const o=c=>(u,l)=>{var f;const d=Gt(e,l,c==="exit"?(f=e.presenceContext)==null?void 0:f.custom:void 0);if(d){const{transition:p,transitionEnd:m,...h}=d;u={...u,...h,...m}}return u};function s(c){t=c(e)}function i(c){const{props:u}=e,l=Su(e.parent)||{},d=[],f=new Set;let p={},m=1/0;for(let v=0;v<Zv;v++){const b=qv[v],S=n[b],y=u[b]!==void 0?u[b]:l[b],C=On(y),T=b===c?S.isActive:null;T===!1&&(m=v);let E=y===l[b]&&y!==u[b]&&C;if(E&&r&&e.manuallyAnimateOnMount&&(E=!1),S.protectedKeys={...p},!S.isActive&&T===null||!y&&!S.prevProp||Gr(y)||typeof y=="boolean")continue;const P=Qv(S.prevProp,y);let A=P||b===c&&S.isActive&&!E&&C||v>m&&C,M=!1;const L=Array.isArray(y)?y:[y];let $=L.reduce(o(b),{});T===!1&&($={});const{prevResolvedValues:W={}}=S,H={...W,...$},q=U=>{A=!0,f.has(U)&&(M=!0,f.delete(U)),S.needsAnimating[U]=!0;const I=e.getValue(U);I&&(I.liveStyle=!1)};for(const U in H){const I=$[U],X=W[U];if(p.hasOwnProperty(U))continue;let R=!1;Xo(I)&&Xo(X)?R=!Tu(I,X):R=I!==X,R?I!=null?q(U):f.add(U):I!==void 0&&f.has(U)?q(U):S.protectedKeys[U]=!0}S.prevProp=y,S.prevResolvedValues=$,S.isActive&&(p={...p,...$}),r&&e.blockInitialAnimation&&(A=!1);const oe=E&&P;A&&(!oe||M)&&d.push(...L.map(U=>{const I={type:b};if(typeof U=="string"&&r&&!oe&&e.manuallyAnimateOnMount&&e.parent){const{parent:X}=e,R=Gt(X,U);if(X.enteringChildren&&R){const{delayChildren:w}=R.transition||{};I.delay=Hl(X.enteringChildren,e,w)}}return{animation:U,options:I}}))}if(f.size){const v={};if(typeof u.initial!="boolean"){const b=Gt(e,Array.isArray(u.initial)?u.initial[0]:u.initial);b&&b.transition&&(v.transition=b.transition)}f.forEach(b=>{const S=e.getBaseTarget(b),y=e.getValue(b);y&&(y.liveStyle=!0),v[b]=S??null}),d.push({animation:v})}let h=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(h=!1),r=!1,h?t(d):Promise.resolve()}function a(c,u){var d;if(n[c].isActive===u)return Promise.resolve();(d=e.variantChildren)==null||d.forEach(f=>{var p;return(p=f.animationState)==null?void 0:p.setActive(c,u)}),n[c].isActive=u;const l=i(c);for(const f in n)n[f].protectedKeys={};return l}return{animateChanges:i,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=Ca()}}}function Qv(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Tu(t,e):!1}function Ct(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ca(){return{animate:Ct(!0),whileInView:Ct(),whileHover:Ct(),whileTap:Ct(),whileDrag:Ct(),whileFocus:Ct(),exit:Ct()}}function _a(e,t){e.min=t.min,e.max=t.max}function qe(e,t){_a(e.x,t.x),_a(e.y,t.y)}function Ea(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const wu=1e-4,e1=1-wu,t1=1+wu,Cu=.01,n1=0-Cu,r1=0+Cu;function De(e){return e.max-e.min}function o1(e,t,n){return Math.abs(e-t)<=n}function Pa(e,t,n,r=.5){e.origin=r,e.originPoint=fe(t.min,t.max,e.origin),e.scale=De(n)/De(t),e.translate=fe(n.min,n.max,e.origin)-e.originPoint,(e.scale>=e1&&e.scale<=t1||isNaN(e.scale))&&(e.scale=1),(e.translate>=n1&&e.translate<=r1||isNaN(e.translate))&&(e.translate=0)}function wn(e,t,n,r){Pa(e.x,t.x,n.x,r?r.originX:void 0),Pa(e.y,t.y,n.y,r?r.originY:void 0)}function Aa(e,t,n){e.min=n.min+t.min,e.max=e.min+De(t)}function s1(e,t,n){Aa(e.x,t.x,n.x),Aa(e.y,t.y,n.y)}function Ma(e,t,n){e.min=t.min-n.min,e.max=e.min+De(t)}function Er(e,t,n){Ma(e.x,t.x,n.x),Ma(e.y,t.y,n.y)}function ka(e,t,n,r,o){return e-=t,e=_r(e,1/n,r),o!==void 0&&(e=_r(e,1/o,r)),e}function i1(e,t=0,n=1,r=.5,o,s=e,i=e){if(ot.test(t)&&(t=parseFloat(t),t=fe(i.min,i.max,t/100)-i.min),typeof t!="number")return;let a=fe(s.min,s.max,r);e===s&&(a-=t),e.min=ka(e.min,t,n,a,o),e.max=ka(e.max,t,n,a,o)}function Ra(e,t,[n,r,o],s,i){i1(e,t[n],t[r],t[o],t.scale,s,i)}const a1=["x","scaleX","originX"],c1=["y","scaleY","originY"];function Oa(e,t,n,r){Ra(e.x,t,a1,n?n.x:void 0,r?r.x:void 0),Ra(e.y,t,c1,n?n.y:void 0,r?r.y:void 0)}function Ia(e){return e.translate===0&&e.scale===1}function _u(e){return Ia(e.x)&&Ia(e.y)}function ja(e,t){return e.min===t.min&&e.max===t.max}function l1(e,t){return ja(e.x,t.x)&&ja(e.y,t.y)}function La(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Eu(e,t){return La(e.x,t.x)&&La(e.y,t.y)}function Da(e){return De(e.x)/De(e.y)}function $a(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function ze(e){return[e("x"),e("y")]}function u1(e,t,n){let r="";const o=e.x.translate/t.x,s=e.y.translate/t.y,i=(n==null?void 0:n.z)||0;if((o||s||i)&&(r=`translate3d(${o}px, ${s}px, ${i}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:l,rotateX:d,rotateY:f,skewX:p,skewY:m}=n;u&&(r=`perspective(${u}px) ${r}`),l&&(r+=`rotate(${l}deg) `),d&&(r+=`rotateX(${d}deg) `),f&&(r+=`rotateY(${f}deg) `),p&&(r+=`skewX(${p}deg) `),m&&(r+=`skewY(${m}deg) `)}const a=e.x.scale*t.x,c=e.y.scale*t.y;return(a!==1||c!==1)&&(r+=`scale(${a}, ${c})`),r||"none"}const Pu=["TopLeft","TopRight","BottomLeft","BottomRight"],d1=Pu.length,Va=e=>typeof e=="string"?parseFloat(e):e,Na=e=>typeof e=="number"||B.test(e);function f1(e,t,n,r,o,s){o?(e.opacity=fe(0,n.opacity??1,h1(r)),e.opacityExit=fe(t.opacity??1,0,p1(r))):s&&(e.opacity=fe(t.opacity??1,n.opacity??1,r));for(let i=0;i<d1;i++){const a=`border${Pu[i]}Radius`;let c=Ba(t,a),u=Ba(n,a);if(c===void 0&&u===void 0)continue;c||(c=0),u||(u=0),c===0||u===0||Na(c)===Na(u)?(e[a]=Math.max(fe(Va(c),Va(u),r),0),(ot.test(u)||ot.test(c))&&(e[a]+="%")):e[a]=u}(t.rotate||n.rotate)&&(e.rotate=fe(t.rotate||0,n.rotate||0,r))}function Ba(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const h1=Au(0,.5,Tl),p1=Au(.5,.95,Ge);function Au(e,t,n){return r=>r<e?0:r>t?1:n(Mn(e,t,r))}function m1(e,t,n){const r=Oe(e)?e:qt(e);return r.start(Us("",r,t,n)),r.animation}function In(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const g1=(e,t)=>e.depth-t.depth;class y1{constructor(){this.children=[],this.isDirty=!1}add(t){Ps(this.children,t),this.isDirty=!0}remove(t){As(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(g1),this.isDirty=!1,this.children.forEach(t)}}function v1(e,t){const n=Le.now(),r=({timestamp:o})=>{const s=o-n;s>=t&&(vt(r),e(s-t))};return le.setup(r,!0),()=>vt(r)}function fr(e){return Oe(e)?e.get():e}class b1{constructor(){this.members=[]}add(t){Ps(this.members,t),t.scheduleRender()}remove(t){if(As(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return!1;let r;for(let o=n;o>=0;o--){const s=this.members[o];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender();const o=r.options.layoutDependency,s=t.options.layoutDependency;o!==void 0&&s!==void 0&&o===s||(t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0));const{crossfade:a}=t.options;a===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const hr={hasAnimatedSinceResize:!0,hasEverUpdated:!1},yo=["","X","Y","Z"],x1=1e3;let S1=0;function vo(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Mu(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ql(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:o,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",le,!(o||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Mu(r)}function ku({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(i={},a=t==null?void 0:t()){this.id=S1++,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(C1),this.nodes.forEach(A1),this.nodes.forEach(M1),this.nodes.forEach(_1)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=i,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new y1)}addEventListener(i,a){return this.eventHandlers.has(i)||this.eventHandlers.set(i,new ks),this.eventHandlers.get(i).add(a)}notifyListeners(i,...a){const c=this.eventHandlers.get(i);c&&c.notify(...a)}hasListeners(i){return this.eventHandlers.has(i)}mount(i){if(this.instance)return;this.isSVG=iu(i)&&!wv(i),this.instance=i;const{layoutId:a,layout:c,visualElement:u}=this.options;if(u&&!u.current&&u.mount(i),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(c||a)&&(this.isLayoutDirty=!0),e){let l,d=0;const f=()=>this.root.updateBlockedByResize=!1;le.read(()=>{d=window.innerWidth}),e(i,()=>{const p=window.innerWidth;p!==d&&(d=p,this.root.updateBlockedByResize=!0,l&&l(),l=v1(f,250),hr.hasAnimatedSinceResize&&(hr.hasAnimatedSinceResize=!1,this.nodes.forEach(Wa)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||c)&&this.addEventListener("didUpdate",({delta:l,hasLayoutChanged:d,hasRelativeLayoutChanged:f,layout:p})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||u.getDefaultTransition()||j1,{onLayoutAnimationStart:h,onLayoutAnimationComplete:v}=u.getProps(),b=!this.targetLayout||!Eu(this.targetLayout,p),S=!d&&f;if(this.options.layoutRoot||this.resumeFrom||S||d&&(b||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const y={...Ws(m,"layout"),onPlay:h,onComplete:v};(u.shouldReduceMotion||this.options.layoutRoot)&&(y.delay=0,y.type=!1),this.startAnimation(y),this.setAnimationOrigin(l,S)}else d||Wa(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=p})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const i=this.getStack();i&&i.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),vt(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(k1),this.animationId++)}getTransformTemplate(){const{visualElement:i}=this.options;return i&&i.getProps().transformTemplate}willUpdate(i=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Mu(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let l=0;l<this.path.length;l++){const d=this.path[l];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:a,layout:c}=this.options;if(a===void 0&&!c)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),i&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Fa);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(za);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(P1),this.nodes.forEach(T1),this.nodes.forEach(w1)):this.nodes.forEach(za),this.clearAllSnapshots();const a=Le.now();Me.delta=st(0,1e3/60,a-Me.timestamp),Me.timestamp=a,Me.isProcessing=!0,co.update.process(Me),co.preRender.process(Me),co.render.process(Me),Me.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Ys.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(E1),this.sharedNodes.forEach(R1)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,le.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){le.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!De(this.snapshot.measuredBox.x)&&!De(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 c=0;c<this.path.length;c++)this.path[c].updateScroll();const i=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=Ce(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,i?i.layoutBox:void 0)}updateScroll(i="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===i&&(a=!1),a&&this.instance){const c=r(this.instance);this.scroll={animationId:this.root.animationId,phase:i,isRoot:c,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:c}}}resetTransform(){if(!o)return;const i=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!_u(this.projectionDelta),c=this.getTransformTemplate(),u=c?c(this.latestValues,""):void 0,l=u!==this.prevTransformTemplateValue;i&&this.instance&&(a||At(this.latestValues)||l)&&(o(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(i=!0){const a=this.measurePageBox();let c=this.removeElementScroll(a);return i&&(c=this.removeTransform(c)),L1(c),{animationId:this.root.animationId,measuredBox:a,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:i}=this.options;if(!i)return Ce();const a=i.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(D1))){const{scroll:l}=this.root;l&&(Ft(a.x,l.offset.x),Ft(a.y,l.offset.y))}return a}removeElementScroll(i){var c;const a=Ce();if(qe(a,i),(c=this.scroll)!=null&&c.wasRoot)return a;for(let u=0;u<this.path.length;u++){const l=this.path[u],{scroll:d,options:f}=l;l!==this.root&&d&&f.layoutScroll&&(d.wasRoot&&qe(a,i),Ft(a.x,d.offset.x),Ft(a.y,d.offset.y))}return a}applyTransform(i,a=!1){const c=Ce();qe(c,i);for(let u=0;u<this.path.length;u++){const l=this.path[u];!a&&l.options.layoutScroll&&l.scroll&&l!==l.root&&zt(c,{x:-l.scroll.offset.x,y:-l.scroll.offset.y}),At(l.latestValues)&&zt(c,l.latestValues)}return At(this.latestValues)&&zt(c,this.latestValues),c}removeTransform(i){const a=Ce();qe(a,i);for(let c=0;c<this.path.length;c++){const u=this.path[c];if(!u.instance||!At(u.latestValues))continue;rs(u.latestValues)&&u.updateSnapshot();const l=Ce(),d=u.measurePageBox();qe(l,d),Oa(a,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,l)}return At(this.latestValues)&&Oa(a,this.latestValues),a}setTargetDelta(i){this.targetDelta=i,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(i){this.options={...this.options,...i,crossfade:i.crossfade!==void 0?i.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Me.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(i=!1){var p;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const c=!!this.resumingFrom||this!==a;if(!(i||c&&this.isSharedProjectionDirty||this.isProjectionDirty||(p=this.parent)!=null&&p.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:l,layoutId:d}=this.options;if(!this.layout||!(l||d))return;this.resolvedRelativeTargetAt=Me.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Ce(),this.targetWithTransforms=Ce()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),s1(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):qe(this.target,this.layout.layoutBox),hu(this.target,this.targetDelta)):qe(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||rs(this.parent.latestValues)||fu(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(i,a,c){this.relativeParent=i,this.linkedParentVersion=i.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ce(),this.relativeTargetOrigin=Ce(),Er(this.relativeTargetOrigin,a,c),qe(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var m;const i=this.getLead(),a=!!this.resumingFrom||this!==i;let c=!0;if((this.isProjectionDirty||(m=this.parent)!=null&&m.isProjectionDirty)&&(c=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===Me.timestamp&&(c=!1),c)return;const{layout:u,layoutId:l}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||l))return;qe(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,f=this.treeScale.y;jv(this.layoutCorrected,this.treeScale,this.path,a),i.layout&&!i.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(i.target=i.layout.layoutBox,i.targetWithTransforms=Ce());const{target:p}=i;if(!p){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Ea(this.prevProjectionDelta.x,this.projectionDelta.x),Ea(this.prevProjectionDelta.y,this.projectionDelta.y)),wn(this.projectionDelta,this.layoutCorrected,p,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==f||!$a(this.projectionDelta.x,this.prevProjectionDelta.x)||!$a(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",p))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(i=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),i){const c=this.getStack();c&&c.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Bt(),this.projectionDelta=Bt(),this.projectionDeltaWithTransform=Bt()}setAnimationOrigin(i,a=!1){const c=this.snapshot,u=c?c.latestValues:{},l={...this.latestValues},d=Bt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const f=Ce(),p=c?c.source:void 0,m=this.layout?this.layout.source:void 0,h=p!==m,v=this.getStack(),b=!v||v.members.length<=1,S=!!(h&&!b&&this.options.crossfade===!0&&!this.path.some(I1));this.animationProgress=0;let y;this.mixTargetDelta=C=>{const T=C/1e3;Ua(d.x,i.x,T),Ua(d.y,i.y,T),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Er(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),O1(this.relativeTarget,this.relativeTargetOrigin,f,T),y&&l1(this.relativeTarget,y)&&(this.isProjectionDirty=!1),y||(y=Ce()),qe(y,this.relativeTarget)),h&&(this.animationValues=l,f1(l,u,this.latestValues,T,S,b)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(i){var a,c,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(c=this.resumingFrom)==null?void 0:c.currentAnimation)==null||u.stop(),this.pendingAnimation&&(vt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=le.update(()=>{hr.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=qt(0)),this.currentAnimation=m1(this.motionValue,[0,1e3],{...i,velocity:0,isSync:!0,onUpdate:l=>{this.mixTargetDelta(l),i.onUpdate&&i.onUpdate(l)},onStop:()=>{},onComplete:()=>{i.onComplete&&i.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 i=this.getStack();i&&i.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(x1),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const i=this.getLead();let{targetWithTransforms:a,target:c,layout:u,latestValues:l}=i;if(!(!a||!c||!u)){if(this!==i&&this.layout&&u&&Ru(this.options.animationType,this.layout.layoutBox,u.layoutBox)){c=this.target||Ce();const d=De(this.layout.layoutBox.x);c.x.min=i.target.x.min,c.x.max=c.x.min+d;const f=De(this.layout.layoutBox.y);c.y.min=i.target.y.min,c.y.max=c.y.min+f}qe(a,c),zt(a,l),wn(this.projectionDeltaWithTransform,this.layoutCorrected,a,l)}}registerSharedNode(i,a){this.sharedNodes.has(i)||this.sharedNodes.set(i,new b1),this.sharedNodes.get(i).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const i=this.getStack();return i?i.lead===this:!0}getLead(){var a;const{layoutId:i}=this.options;return i?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:i}=this.options;return i?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:i}=this.options;if(i)return this.root.sharedNodes.get(i)}promote({needsReset:i,transition:a,preserveFollowOpacity:c}={}){const u=this.getStack();u&&u.promote(this,c),i&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const i=this.getStack();return i?i.relegate(this):!1}resetSkewAndRotation(){const{visualElement:i}=this.options;if(!i)return;let a=!1;const{latestValues:c}=i;if((c.z||c.rotate||c.rotateX||c.rotateY||c.rotateZ||c.skewX||c.skewY)&&(a=!0),!a)return;const u={};c.z&&vo("z",i,u,this.animationValues);for(let l=0;l<yo.length;l++)vo(`rotate${yo[l]}`,i,u,this.animationValues),vo(`skew${yo[l]}`,i,u,this.animationValues);i.render();for(const l in u)i.setStaticValue(l,u[l]),this.animationValues&&(this.animationValues[l]=u[l]);i.scheduleRender()}applyProjectionStyles(i,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){i.visibility="hidden";return}const c=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,i.visibility="",i.opacity="",i.pointerEvents=fr(a==null?void 0:a.pointerEvents)||"",i.transform=c?c(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(i.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,i.pointerEvents=fr(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!At(this.latestValues)&&(i.transform=c?c({},""):"none",this.hasProjected=!1);return}i.visibility="";const l=u.animationValues||u.latestValues;this.applyTransformsToTarget();let d=u1(this.projectionDeltaWithTransform,this.treeScale,l);c&&(d=c(l,d)),i.transform=d;const{x:f,y:p}=this.projectionDelta;i.transformOrigin=`${f.origin*100}% ${p.origin*100}% 0`,u.animationValues?i.opacity=u===this?l.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:i.opacity=u===this?l.opacity!==void 0?l.opacity:"":l.opacityExit!==void 0?l.opacityExit:0;for(const m in ss){if(l[m]===void 0)continue;const{correct:h,applyTo:v,isCSSVariable:b}=ss[m],S=d==="none"?l[m]:h(l[m],u);if(v){const y=v.length;for(let C=0;C<y;C++)i[v[C]]=S}else b?this.options.visualElement.renderState.vars[m]=S:i[m]=S}this.options.layoutId&&(i.pointerEvents=u===this?fr(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(i=>{var a;return(a=i.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Fa),this.root.sharedNodes.clear()}}}function T1(e){e.updateLayout()}function w1(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=e.layout,{animationType:s}=e.options,i=t.source!==e.layout.source;s==="size"?ze(d=>{const f=i?t.measuredBox[d]:t.layoutBox[d],p=De(f);f.min=r[d].min,f.max=f.min+p}):Ru(s,t.layoutBox,r)&&ze(d=>{const f=i?t.measuredBox[d]:t.layoutBox[d],p=De(r[d]);f.max=f.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+p)});const a=Bt();wn(a,r,t.layoutBox);const c=Bt();i?wn(c,e.applyTransform(o,!0),t.measuredBox):wn(c,r,t.layoutBox);const u=!_u(a);let l=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:p}=d;if(f&&p){const m=Ce();Er(m,t.layoutBox,f.layoutBox);const h=Ce();Er(h,r,p.layoutBox),Eu(m,h)||(l=!0),d.options.layoutRoot&&(e.relativeTarget=h,e.relativeTargetOrigin=m,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:c,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:l})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function C1(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function _1(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function E1(e){e.clearSnapshot()}function Fa(e){e.clearMeasurements()}function za(e){e.isLayoutDirty=!1}function P1(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Wa(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function A1(e){e.resolveTargetDelta()}function M1(e){e.calcProjection()}function k1(e){e.resetSkewAndRotation()}function R1(e){e.removeLeadSnapshot()}function Ua(e,t,n){e.translate=fe(t.translate,0,n),e.scale=fe(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Ha(e,t,n,r){e.min=fe(t.min,n.min,r),e.max=fe(t.max,n.max,r)}function O1(e,t,n,r){Ha(e.x,t.x,n.x,r),Ha(e.y,t.y,n.y,r)}function I1(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const j1={duration:.45,ease:[.4,0,.1,1]},Ga=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Ka=Ga("applewebkit/")&&!Ga("chrome/")?Math.round:Ge;function Ya(e){e.min=Ka(e.min),e.max=Ka(e.max)}function L1(e){Ya(e.x),Ya(e.y)}function Ru(e,t,n){return e==="position"||e==="preserve-aspect"&&!o1(Da(t),Da(n),.2)}function D1(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const $1=ku({attachResizeListener:(e,t)=>In(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),bo={current:void 0},Ou=ku({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!bo.current){const e=new $1({});e.mount(window),e.setOptions({layoutScroll:!0}),bo.current=e}return bo.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),ei=x.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function qa(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function V1(...e){return t=>{let n=!1;const r=e.map(o=>{const s=qa(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():qa(e[o],null)}}}}function N1(...e){return Fe.useCallback(V1(...e),e)}class B1 extends Fe.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,o=ts(r)&&r.offsetWidth||0,s=ts(r)&&r.offsetHeight||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=o-i.width-i.left,i.bottom=s-i.height-i.top}return null}componentDidUpdate(){}render(){return this.props.children}}function F1({children:e,isPresent:t,anchorX:n,anchorY:r,root:o}){var d;const s=x.useId(),i=x.useRef(null),a=x.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:c}=x.useContext(ei),u=((d=e.props)==null?void 0:d.ref)??(e==null?void 0:e.ref),l=N1(i,u);return x.useInsertionEffect(()=>{const{width:f,height:p,top:m,left:h,right:v,bottom:b}=a.current;if(t||!i.current||!f||!p)return;const S=n==="left"?`left: ${h}`:`right: ${v}`,y=r==="bottom"?`bottom: ${b}`:`top: ${m}`;i.current.dataset.motionPopId=s;const C=document.createElement("style");c&&(C.nonce=c);const T=o??document.head;return T.appendChild(C),C.sheet&&C.sheet.insertRule(`
78
+ } });`:ht(12,S?` (${S})`:"",JSON.stringify(v.main)));return o?(Si(o,v,"light",b,r),Si(o,v,"dark",w,r)):(xi(v,"light",b,r),xi(v,"dark",w,r)),v.contrastText||(v.contrastText=f(v.main)),v};let p;return t==="light"?p=Sc():t==="dark"&&(p=Cc()),process.env.NODE_ENV!=="production"&&(p||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),De({common:{...Sn},mode:t,primary:h({color:i,name:"primary"}),secondary:h({color:a,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:h({color:c,name:"error"}),warning:h({color:d,name:"warning"}),info:h({color:u,name:"info"}),success:h({color:l,name:"success"}),grey:Uf,contrastThreshold:n,getContrastText:f,augmentColor:h,tonalOffset:r,...p},s)}function Jf(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Qf={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function eh(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var th=/[A-Z]|^ms/g,nh=/_EMO_([^_]+?)_([^]*?)_EMO_/g,wc=function(t){return t.charCodeAt(1)===45},Ti=function(t){return t!=null&&typeof t!="boolean"},Gr=eh(function(e){return wc(e)?e:e.replace(th,"-$&").toLowerCase()}),Ci=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(nh,function(r,o,s){return ut={name:o,styles:s,next:ut},o})}return Qf[t]!==1&&!wc(t)&&typeof n=="number"&&n!==0?n+"px":n};function or(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return ut={name:o.name,styles:o.styles,next:ut},o.name;var s=n;if(s.styles!==void 0){var i=s.next;if(i!==void 0)for(;i!==void 0;)ut={name:i.name,styles:i.styles,next:ut},i=i.next;var a=s.styles+";";return a}return rh(e,t,n)}}var c=n;return c}function rh(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=or(e,t,n[o])+";";else for(var s in n){var i=n[s];if(typeof i!="object"){var a=i;Ti(a)&&(r+=Gr(s)+":"+Ci(s,a)+";")}else if(Array.isArray(i)&&typeof i[0]=="string"&&t==null)for(var c=0;c<i.length;c++)Ti(i[c])&&(r+=Gr(s)+":"+Ci(s,i[c])+";");else{var u=or(e,t,i);switch(s){case"animation":case"animationName":{r+=Gr(s)+":"+u+";";break}default:r+=s+"{"+u+"}"}}}return r}var wi=/label:\s*([^\s;{]+)\s*(;|$)/g,ut;function oh(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,o="";ut=void 0;var s=e[0];if(s==null||s.raw===void 0)r=!1,o+=or(n,t,s);else{var i=s;o+=i[0]}for(var a=1;a<e.length;a++)if(o+=or(n,t,e[a]),r){var c=s;o+=c[a]}wi.lastIndex=0;for(var u="",l;(l=wi.exec(o))!==null;)u+="-"+l[1];var d=Jf(o)+u;return{name:d,styles:o,next:ut}}/**
79
+ * @mui/styled-engine v7.3.7
80
+ *
81
+ * @license MIT
82
+ * This source code is licensed under the MIT license found in the
83
+ * LICENSE file in the root directory of this source tree.
84
+ */function sh(e,t){const n=cd(e,t);return process.env.NODE_ENV!=="production"?(...r)=>{const o=typeof e=="string"?`"${e}"`:"component";return r.length===0?console.error([`MUI: Seems like you called \`styled(${o})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
85
+ `)):r.some(s=>s===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}function ih(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const _i=[];function Pt(e){return _i[0]=e,oh(_i)}function Ao(e,t,n=!1){const r={...t};for(const o in e)if(Object.prototype.hasOwnProperty.call(e,o)){const s=o;if(s==="components"||s==="slots")r[s]={...e[s],...r[s]};else if(s==="componentsProps"||s==="slotProps"){const i=e[s],a=t[s];if(!a)r[s]=i||{};else if(!i)r[s]=a;else{r[s]={...a};for(const c in i)if(Object.prototype.hasOwnProperty.call(i,c)){const u=c;r[s][u]=Ao(i[u],a[u],n)}}}else s==="className"&&n&&t.className?r.className=gc(e==null?void 0:e.className,t==null?void 0:t.className):s==="style"&&n&&t.style?r.style={...e==null?void 0:e.style,...t==null?void 0:t.style}:r[s]===void 0&&(r[s]=e[s])}return r}const ah=Ve.createContext(void 0);process.env.NODE_ENV!=="production"&&(te.node,te.object);function ch(e){const{theme:t,name:n,props:r}=e;if(!t||!t.components||!t.components[n])return r;const o=t.components[n];return o.defaultProps?Ao(o.defaultProps,r,t.components.mergeClassNameAndStyle):!o.styleOverrides&&!o.variants?Ao(o,r,t.components.mergeClassNameAndStyle):r}function lh({props:e,name:t}){const n=Ve.useContext(ah);return ch({props:e,name:t,theme:{components:n}})}const uh=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>({...n,[r.key]:r.val}),{})};function dh(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5,...o}=e,s=uh(t),i=Object.keys(s);function a(f){return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${n})`}function c(f){return`@media (max-width:${(typeof t[f]=="number"?t[f]:f)-r/100}${n})`}function u(f,h){const p=i.indexOf(h);return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${n}) and (max-width:${(p!==-1&&typeof t[i[p]]=="number"?t[i[p]]:h)-r/100}${n})`}function l(f){return i.indexOf(f)+1<i.length?u(f,i[i.indexOf(f)+1]):a(f)}function d(f){const h=i.indexOf(f);return h===0?a(i[1]):h===i.length-1?c(i[h]):u(f,i[i.indexOf(f)+1]).replace("@media","@media not all and")}return{keys:i,values:s,up:a,down:c,between:u,only:l,not:d,unit:n,...o}}const fh={borderRadius:4};function hh(e=8,t=us({spacing:e})){if(e.mui)return e;const n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mh(e,t){var r;const n=this;if(n.vars){if(!((r=n.colorSchemes)!=null&&r[e])||typeof n.getColorSchemeSelector!="function")return{};let o=n.getColorSchemeSelector(e);return o==="&"?t:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:t})}return n.palette.mode===e?t:{}}function _c(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={},...i}=e,a=dh(n),c=hh(o);let u=De({breakpoints:a,direction:"ltr",components:{},palette:{mode:"light",...r},spacing:c,shape:{...fh,...s}},i);return u=qd(u),u.applyStyles=mh,u=t.reduce((l,d)=>De(l,d),u),u.unstable_sxConfig={...Ar,...i==null?void 0:i.unstable_sxConfig},u.unstable_sx=function(d){return Ht({sx:d,theme:this})},u}const Ei=(e,t,n,r=[])=>{let o=e;t.forEach((s,i)=>{i===t.length-1?Array.isArray(o)?o[Number(s)]=n:o&&typeof o=="object"&&(o[s]=n):o&&typeof o=="object"&&(o[s]||(o[s]=r.includes(s)?[]:{}),o=o[s])})},ph=(e,t,n)=>{function r(o,s=[],i=[]){Object.entries(o).forEach(([a,c])=>{(!n||n&&!n([...s,a]))&&c!=null&&(typeof c=="object"&&Object.keys(c).length>0?r(c,[...s,a],Array.isArray(c)?[...i,a]:i):t([...s,a],c,i))})}r(e)},gh=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(r=>e.includes(r))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function Kr(e,t){const{prefix:n,shouldSkipGeneratingVar:r}=t||{},o={},s={},i={};return ph(e,(a,c,u)=>{if((typeof c=="string"||typeof c=="number")&&(!r||!r(a,c))){const l=`--${n?`${n}-`:""}${a.join("-")}`,d=gh(a,c);Object.assign(o,{[l]:d}),Ei(s,a,`var(${l})`,u),Ei(i,a,`var(${l}, ${d})`,u)}},a=>a[0]==="vars"),{css:o,vars:s,varsWithDefaults:i}}function yh(e,t={}){const{getSelector:n=S,disableCssColorScheme:r,colorSchemeSelector:o,enableContrastVars:s}=t,{colorSchemes:i={},components:a,defaultColorScheme:c="light",...u}=e,{vars:l,css:d,varsWithDefaults:f}=Kr(u,t);let h=f;const p={},{[c]:m,...v}=i;if(Object.entries(v||{}).forEach(([w,C])=>{const{vars:E,css:P,varsWithDefaults:M}=Kr(C,t);h=De(h,M),p[w]={css:P,vars:E}}),m){const{css:w,vars:C,varsWithDefaults:E}=Kr(m,t);h=De(h,E),p[c]={css:w,vars:C}}function S(w,C){var P,M;let E=o;if(o==="class"&&(E=".%s"),o==="data"&&(E="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(E=`[${o}="%s"]`),w){if(E==="media")return e.defaultColorScheme===w?":root":{[`@media (prefers-color-scheme: ${((M=(P=i[w])==null?void 0:P.palette)==null?void 0:M.mode)||w})`]:{":root":C}};if(E)return e.defaultColorScheme===w?`:root, ${E.replace("%s",String(w))}`:E.replace("%s",String(w))}return":root"}return{vars:h,generateThemeVars:()=>{let w={...l};return Object.entries(p).forEach(([,{vars:C}])=>{w=De(w,C)}),w},generateStyleSheets:()=>{var I,V;const w=[],C=e.defaultColorScheme||"light";function E(D,g){Object.keys(g).length&&w.push(typeof D=="string"?{[D]:{...g}}:D)}E(n(void 0,{...d}),d);const{[C]:P,...M}=p;if(P){const{css:D}=P,g=(V=(I=i[C])==null?void 0:I.palette)==null?void 0:V.mode,$=!r&&g?{colorScheme:g,...D}:{...D};E(n(C,{...$}),$)}return Object.entries(M).forEach(([D,{css:g}])=>{var W,K;const $=(K=(W=i[D])==null?void 0:W.palette)==null?void 0:K.mode,R=!r&&$?{colorScheme:$,...g}:{...g};E(n(D,{...R}),R)}),s&&w.push({":root":{"--__l-threshold":"0.7","--__l":"clamp(0, (l / var(--__l-threshold) - 1) * -infinity, 1)","--__a":"clamp(0.87, (l / var(--__l-threshold) - 1) * -infinity, 1)"}}),w}}}function vh(e){const t={};return Object.entries(e).forEach(r=>{const[o,s]=r;typeof s=="object"&&(t[o]=`${s.fontStyle?`${s.fontStyle} `:""}${s.fontVariant?`${s.fontVariant} `:""}${s.fontWeight?`${s.fontWeight} `:""}${s.fontStretch?`${s.fontStretch} `:""}${s.fontSize||""}${s.lineHeight?`/${s.lineHeight} `:""}${s.fontFamily||""}`)}),t}function bh(e){return function(n){return e==="media"?(process.env.NODE_ENV!=="production"&&n!=="light"&&n!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${n}'.`),`@media (prefers-color-scheme: ${n})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${n}"] &`:e==="class"?`.${n} &`:e==="data"?`[data-${n}] &`:`${e.replace("%s",n)} &`:"&"}}const xh={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ms(e,t,n="Mui"){const r=xh[t];return r?`${n}-${r}`:`${Dd.generate(e)}-${t}`}function Sh(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function Th(e){return Math.round(e*1e5)/1e5}const Ai={textTransform:"uppercase"},Mi='"Roboto", "Helvetica", "Arial", sans-serif';function Ch(e,t){const{fontFamily:n=Mi,fontSize:r=14,fontWeightLight:o=300,fontWeightRegular:s=400,fontWeightMedium:i=500,fontWeightBold:a=700,htmlFontSize:c=16,allVariants:u,pxToRem:l,...d}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof r!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof c!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const f=r/14,h=l||(v=>`${v/c*f}rem`),p=(v,S,T,b,w)=>({fontFamily:n,fontWeight:v,fontSize:h(S),lineHeight:T,...n===Mi?{letterSpacing:`${Th(b/S)}em`}:{},...w,...u}),m={h1:p(o,96,1.167,-1.5),h2:p(o,60,1.2,-.5),h3:p(s,48,1.167,0),h4:p(s,34,1.235,.25),h5:p(s,24,1.334,0),h6:p(i,20,1.6,.15),subtitle1:p(s,16,1.75,.15),subtitle2:p(i,14,1.57,.1),body1:p(s,16,1.5,.15),body2:p(s,14,1.43,.15),button:p(i,14,1.75,.4,Ai),caption:p(s,12,1.66,.4),overline:p(s,12,2.66,1,Ai),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return De({htmlFontSize:c,pxToRem:h,fontFamily:n,fontSize:r,fontWeightLight:o,fontWeightRegular:s,fontWeightMedium:i,fontWeightBold:a,...m},d,{clone:!1})}const wh=.2,_h=.14,Eh=.12;function ue(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${wh})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${_h})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Eh})`].join(",")}const Ah=["none",ue(0,2,1,-1,0,1,1,0,0,1,3,0),ue(0,3,1,-2,0,2,2,0,0,1,5,0),ue(0,3,3,-2,0,3,4,0,0,1,8,0),ue(0,2,4,-1,0,4,5,0,0,1,10,0),ue(0,3,5,-1,0,5,8,0,0,1,14,0),ue(0,3,5,-1,0,6,10,0,0,1,18,0),ue(0,4,5,-2,0,7,10,1,0,2,16,1),ue(0,5,5,-3,0,8,10,1,0,3,14,2),ue(0,5,6,-3,0,9,12,1,0,3,16,2),ue(0,6,6,-3,0,10,14,1,0,4,18,3),ue(0,6,7,-4,0,11,15,1,0,4,20,3),ue(0,7,8,-4,0,12,17,2,0,5,22,4),ue(0,7,8,-4,0,13,19,2,0,5,24,4),ue(0,7,9,-4,0,14,21,2,0,5,26,4),ue(0,8,9,-5,0,15,22,2,0,6,28,5),ue(0,8,10,-5,0,16,24,2,0,6,30,5),ue(0,8,11,-5,0,17,26,2,0,6,32,5),ue(0,9,11,-5,0,18,28,2,0,7,34,6),ue(0,9,12,-6,0,19,29,2,0,7,36,6),ue(0,10,13,-6,0,20,31,3,0,8,38,7),ue(0,10,13,-6,0,21,33,3,0,8,40,7),ue(0,10,14,-6,0,22,35,3,0,8,42,7),ue(0,11,14,-7,0,23,36,3,0,9,44,8),ue(0,11,15,-7,0,24,38,3,0,9,46,8)],Mh={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Ph={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Pi(e){return`${Math.round(e)}ms`}function kh(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function Ih(e){const t={...Mh,...e.easing},n={...Ph,...e.duration};return{getAutoHeightDuration:kh,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:a=t.easeInOut,delay:c=0,...u}=s;if(process.env.NODE_ENV!=="production"){const l=f=>typeof f=="string",d=f=>!Number.isNaN(parseFloat(f));!l(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!d(i)&&!l(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),l(a)||console.error('MUI: Argument "easing" must be a string.'),!d(c)&&!l(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
86
+ `)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(l=>`${l} ${typeof i=="string"?i:Pi(i)} ${a} ${typeof c=="string"?c:Pi(c)}`).join(",")},...e,easing:t,duration:n}}const Rh={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function Oh(e){return Qe(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function Ec(e={}){const t={...e};function n(r){const o=Object.entries(r);for(let s=0;s<o.length;s++){const[i,a]=o[s];!Oh(a)||i.startsWith("unstable_")?delete r[i]:Qe(a)&&(r[i]={...a},n(r[i]))}}return n(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
87
+
88
+ const theme = ${JSON.stringify(t,null,2)};
89
+
90
+ theme.breakpoints = createBreakpoints(theme.breakpoints || {});
91
+ theme.transitions = createTransitions(theme.transitions || {});
92
+
93
+ export default theme;`}function ki(e){return typeof e=="number"?`${(e*100).toFixed(0)}%`:`calc((${e}) * 100%)`}const Lh=e=>{if(!Number.isNaN(+e))return+e;const t=e.match(/\d*\.?\d+/g);if(!t)return 0;let n=0;for(let r=0;r<t.length;r+=1)n+=+t[r];return n};function Dh(e){Object.assign(e,{alpha(t,n){const r=this||e;return r.colorSpace?`oklch(from ${t} l c h / ${typeof n=="string"?`calc(${n})`:n})`:r.vars?`rgba(${t.replace(/var\(--([^,\s)]+)(?:,[^)]+)?\)+/g,"var(--$1Channel)")} / ${typeof n=="string"?`calc(${n})`:n})`:xc(t,Lh(n))},lighten(t,n){const r=this||e;return r.colorSpace?`color-mix(in ${r.colorSpace}, ${t}, #fff ${ki(n)})`:kr(t,n)},darken(t,n){const r=this||e;return r.colorSpace?`color-mix(in ${r.colorSpace}, ${t}, #000 ${ki(n)})`:Pr(t,n)}})}function Mo(e={},...t){const{breakpoints:n,mixins:r={},spacing:o,palette:s={},transitions:i={},typography:a={},shape:c,colorSpace:u,...l}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":ht(20));const d=hs({...s,colorSpace:u}),f=_c(e);let h=De(f,{mixins:Sh(f.breakpoints,r),palette:d,shadows:Ah.slice(),typography:Ch(d,a),transitions:Ih(i),zIndex:{...Rh}});if(h=De(h,l),h=t.reduce((p,m)=>De(p,m),h),process.env.NODE_ENV!=="production"){const p=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(v,S)=>{let T;for(T in v){const b=v[T];if(p.includes(T)&&Object.keys(b).length>0){if(process.env.NODE_ENV!=="production"){const w=ms("",T);console.error([`MUI: The \`${S}\` component increases the CSS specificity of the \`${T}\` internal state.`,"You can not override it like this: ",JSON.stringify(v,null,2),"",`Instead, you need to use the '&.${w}' syntax:`,JSON.stringify({root:{[`&.${w}`]:b}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
94
+ `))}v[T]={}}}};Object.keys(h.components).forEach(v=>{const S=h.components[v].styleOverrides;S&&v.startsWith("Mui")&&m(S,v)})}return h.unstable_sxConfig={...Ar,...l==null?void 0:l.unstable_sxConfig},h.unstable_sx=function(m){return Ht({sx:m,theme:this})},h.toRuntimeSource=Ec,Dh(h),h}function jh(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const Bh=[...Array(25)].map((e,t)=>{if(t===0)return"none";const n=jh(t);return`linear-gradient(rgba(255 255 255 / ${n}), rgba(255 255 255 / ${n}))`});function Ac(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Mc(e){return e==="dark"?Bh:[]}function $h(e){const{palette:t={mode:"light"},opacity:n,overlays:r,colorSpace:o,...s}=e,i=hs({...t,colorSpace:o});return{palette:i,opacity:{...Ac(i.mode),...n},overlays:r||Mc(i.mode),...s}}function Nh(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const Vh=e=>[...[...Array(25)].map((t,n)=>`--${e?`${e}-`:""}overlays-${n}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],Fh=e=>(t,n)=>{const r=e.rootSelector||":root",o=e.colorSchemeSelector;let s=o;if(o==="class"&&(s=".%s"),o==="data"&&(s="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(s=`[${o}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const i={};return Vh(e.cssVarPrefix).forEach(a=>{i[a]=n[a],delete n[a]}),s==="media"?{[r]:n,"@media (prefers-color-scheme: dark)":{[r]:i}}:s?{[s.replace("%s",t)]:i,[`${r}, ${s.replace("%s",t)}`]:n}:{[r]:{...n,...i}}}if(s&&s!=="media")return`${r}, ${s.replace("%s",String(t))}`}else if(t){if(s==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[r]:n}};if(s)return s.replace("%s",String(t))}return r};function zh(e,t){t.forEach(n=>{e[n]||(e[n]={})})}function k(e,t,n){!e[t]&&n&&(e[t]=n)}function hn(e){return typeof e!="string"||!e.startsWith("hsl")?e:bc(e)}function Xe(e,t){`${t}Channel`in e||(e[`${t}Channel`]=fn(hn(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
95
+ To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function Wh(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const Ge=e=>{try{return e()}catch{}},Uh=(e="mui")=>as.unstable_createGetCssVar(e);function Yr(e,t,n,r,o){if(!n)return;n=n===!0?{}:n;const s=o==="dark"?"dark":"light";if(!r){t[o]=$h({...n,palette:{mode:s,...n==null?void 0:n.palette},colorSpace:e});return}const{palette:i,...a}=Mo({...r,palette:{mode:s,...n==null?void 0:n.palette},colorSpace:e});return t[o]={...n,palette:i,opacity:{...Ac(s),...n==null?void 0:n.opacity},overlays:(n==null?void 0:n.overlays)||Mc(s)},a}function Hh(e={},...t){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:o=!1,cssVarPrefix:s="mui",nativeColor:i=!1,shouldSkipGeneratingVar:a=Nh,colorSchemeSelector:c=n.light&&n.dark?"media":void 0,rootSelector:u=":root",...l}=e,d=Object.keys(n)[0],f=r||(n.light&&d!=="light"?"light":d),h=Uh(s),{[f]:p,light:m,dark:v,...S}=n,T={...S};let b=p;if((f==="dark"&&!("dark"in n)||f==="light"&&!("light"in n))&&(b=!0),!b)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${f}\` option is either missing or invalid.`:ht(21,f));let w;i&&(w="oklch");const C=Yr(w,T,b,l,f);m&&!T.light&&Yr(w,T,m,void 0,"light"),v&&!T.dark&&Yr(w,T,v,void 0,"dark");let E={defaultColorScheme:f,...C,cssVarPrefix:s,colorSchemeSelector:c,rootSelector:u,getCssVar:h,colorSchemes:T,font:{...vh(C.typography),...C.font},spacing:Wh(l.spacing)};Object.keys(E.colorSchemes).forEach(D=>{const g=E.colorSchemes[D].palette,$=W=>{const K=W.split("-"),G=K[1],j=K[2];return h(W,g[G][j])};g.mode==="light"&&(k(g.common,"background","#fff"),k(g.common,"onBackground","#000")),g.mode==="dark"&&(k(g.common,"background","#000"),k(g.common,"onBackground","#fff"));function R(W,K,G){if(w){let j;return W===bt&&(j=`transparent ${((1-G)*100).toFixed(0)}%`),W===oe&&(j=`#000 ${(G*100).toFixed(0)}%`),W===se&&(j=`#fff ${(G*100).toFixed(0)}%`),`color-mix(in ${w}, ${K}, ${j})`}return W(K,G)}if(zh(g,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),g.mode==="light"){k(g.Alert,"errorColor",R(oe,g.error.light,.6)),k(g.Alert,"infoColor",R(oe,g.info.light,.6)),k(g.Alert,"successColor",R(oe,g.success.light,.6)),k(g.Alert,"warningColor",R(oe,g.warning.light,.6)),k(g.Alert,"errorFilledBg",$("palette-error-main")),k(g.Alert,"infoFilledBg",$("palette-info-main")),k(g.Alert,"successFilledBg",$("palette-success-main")),k(g.Alert,"warningFilledBg",$("palette-warning-main")),k(g.Alert,"errorFilledColor",Ge(()=>g.getContrastText(g.error.main))),k(g.Alert,"infoFilledColor",Ge(()=>g.getContrastText(g.info.main))),k(g.Alert,"successFilledColor",Ge(()=>g.getContrastText(g.success.main))),k(g.Alert,"warningFilledColor",Ge(()=>g.getContrastText(g.warning.main))),k(g.Alert,"errorStandardBg",R(se,g.error.light,.9)),k(g.Alert,"infoStandardBg",R(se,g.info.light,.9)),k(g.Alert,"successStandardBg",R(se,g.success.light,.9)),k(g.Alert,"warningStandardBg",R(se,g.warning.light,.9)),k(g.Alert,"errorIconColor",$("palette-error-main")),k(g.Alert,"infoIconColor",$("palette-info-main")),k(g.Alert,"successIconColor",$("palette-success-main")),k(g.Alert,"warningIconColor",$("palette-warning-main")),k(g.AppBar,"defaultBg",$("palette-grey-100")),k(g.Avatar,"defaultBg",$("palette-grey-400")),k(g.Button,"inheritContainedBg",$("palette-grey-300")),k(g.Button,"inheritContainedHoverBg",$("palette-grey-A100")),k(g.Chip,"defaultBorder",$("palette-grey-400")),k(g.Chip,"defaultAvatarColor",$("palette-grey-700")),k(g.Chip,"defaultIconColor",$("palette-grey-700")),k(g.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),k(g.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),k(g.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),k(g.LinearProgress,"primaryBg",R(se,g.primary.main,.62)),k(g.LinearProgress,"secondaryBg",R(se,g.secondary.main,.62)),k(g.LinearProgress,"errorBg",R(se,g.error.main,.62)),k(g.LinearProgress,"infoBg",R(se,g.info.main,.62)),k(g.LinearProgress,"successBg",R(se,g.success.main,.62)),k(g.LinearProgress,"warningBg",R(se,g.warning.main,.62)),k(g.Skeleton,"bg",w?R(bt,g.text.primary,.11):`rgba(${$("palette-text-primaryChannel")} / 0.11)`),k(g.Slider,"primaryTrack",R(se,g.primary.main,.62)),k(g.Slider,"secondaryTrack",R(se,g.secondary.main,.62)),k(g.Slider,"errorTrack",R(se,g.error.main,.62)),k(g.Slider,"infoTrack",R(se,g.info.main,.62)),k(g.Slider,"successTrack",R(se,g.success.main,.62)),k(g.Slider,"warningTrack",R(se,g.warning.main,.62));const W=w?R(oe,g.background.default,.6825):Bn(g.background.default,.8);k(g.SnackbarContent,"bg",W),k(g.SnackbarContent,"color",Ge(()=>w?Eo.text.primary:g.getContrastText(W))),k(g.SpeedDialAction,"fabHoverBg",Bn(g.background.paper,.15)),k(g.StepConnector,"border",$("palette-grey-400")),k(g.StepContent,"border",$("palette-grey-400")),k(g.Switch,"defaultColor",$("palette-common-white")),k(g.Switch,"defaultDisabledColor",$("palette-grey-100")),k(g.Switch,"primaryDisabledColor",R(se,g.primary.main,.62)),k(g.Switch,"secondaryDisabledColor",R(se,g.secondary.main,.62)),k(g.Switch,"errorDisabledColor",R(se,g.error.main,.62)),k(g.Switch,"infoDisabledColor",R(se,g.info.main,.62)),k(g.Switch,"successDisabledColor",R(se,g.success.main,.62)),k(g.Switch,"warningDisabledColor",R(se,g.warning.main,.62)),k(g.TableCell,"border",R(se,R(bt,g.divider,1),.88)),k(g.Tooltip,"bg",R(bt,g.grey[700],.92))}if(g.mode==="dark"){k(g.Alert,"errorColor",R(se,g.error.light,.6)),k(g.Alert,"infoColor",R(se,g.info.light,.6)),k(g.Alert,"successColor",R(se,g.success.light,.6)),k(g.Alert,"warningColor",R(se,g.warning.light,.6)),k(g.Alert,"errorFilledBg",$("palette-error-dark")),k(g.Alert,"infoFilledBg",$("palette-info-dark")),k(g.Alert,"successFilledBg",$("palette-success-dark")),k(g.Alert,"warningFilledBg",$("palette-warning-dark")),k(g.Alert,"errorFilledColor",Ge(()=>g.getContrastText(g.error.dark))),k(g.Alert,"infoFilledColor",Ge(()=>g.getContrastText(g.info.dark))),k(g.Alert,"successFilledColor",Ge(()=>g.getContrastText(g.success.dark))),k(g.Alert,"warningFilledColor",Ge(()=>g.getContrastText(g.warning.dark))),k(g.Alert,"errorStandardBg",R(oe,g.error.light,.9)),k(g.Alert,"infoStandardBg",R(oe,g.info.light,.9)),k(g.Alert,"successStandardBg",R(oe,g.success.light,.9)),k(g.Alert,"warningStandardBg",R(oe,g.warning.light,.9)),k(g.Alert,"errorIconColor",$("palette-error-main")),k(g.Alert,"infoIconColor",$("palette-info-main")),k(g.Alert,"successIconColor",$("palette-success-main")),k(g.Alert,"warningIconColor",$("palette-warning-main")),k(g.AppBar,"defaultBg",$("palette-grey-900")),k(g.AppBar,"darkBg",$("palette-background-paper")),k(g.AppBar,"darkColor",$("palette-text-primary")),k(g.Avatar,"defaultBg",$("palette-grey-600")),k(g.Button,"inheritContainedBg",$("palette-grey-800")),k(g.Button,"inheritContainedHoverBg",$("palette-grey-700")),k(g.Chip,"defaultBorder",$("palette-grey-700")),k(g.Chip,"defaultAvatarColor",$("palette-grey-300")),k(g.Chip,"defaultIconColor",$("palette-grey-300")),k(g.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),k(g.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),k(g.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),k(g.LinearProgress,"primaryBg",R(oe,g.primary.main,.5)),k(g.LinearProgress,"secondaryBg",R(oe,g.secondary.main,.5)),k(g.LinearProgress,"errorBg",R(oe,g.error.main,.5)),k(g.LinearProgress,"infoBg",R(oe,g.info.main,.5)),k(g.LinearProgress,"successBg",R(oe,g.success.main,.5)),k(g.LinearProgress,"warningBg",R(oe,g.warning.main,.5)),k(g.Skeleton,"bg",w?R(bt,g.text.primary,.13):`rgba(${$("palette-text-primaryChannel")} / 0.13)`),k(g.Slider,"primaryTrack",R(oe,g.primary.main,.5)),k(g.Slider,"secondaryTrack",R(oe,g.secondary.main,.5)),k(g.Slider,"errorTrack",R(oe,g.error.main,.5)),k(g.Slider,"infoTrack",R(oe,g.info.main,.5)),k(g.Slider,"successTrack",R(oe,g.success.main,.5)),k(g.Slider,"warningTrack",R(oe,g.warning.main,.5));const W=w?R(se,g.background.default,.985):Bn(g.background.default,.98);k(g.SnackbarContent,"bg",W),k(g.SnackbarContent,"color",Ge(()=>w?Tc.text.primary:g.getContrastText(W))),k(g.SpeedDialAction,"fabHoverBg",Bn(g.background.paper,.15)),k(g.StepConnector,"border",$("palette-grey-600")),k(g.StepContent,"border",$("palette-grey-600")),k(g.Switch,"defaultColor",$("palette-grey-300")),k(g.Switch,"defaultDisabledColor",$("palette-grey-600")),k(g.Switch,"primaryDisabledColor",R(oe,g.primary.main,.55)),k(g.Switch,"secondaryDisabledColor",R(oe,g.secondary.main,.55)),k(g.Switch,"errorDisabledColor",R(oe,g.error.main,.55)),k(g.Switch,"infoDisabledColor",R(oe,g.info.main,.55)),k(g.Switch,"successDisabledColor",R(oe,g.success.main,.55)),k(g.Switch,"warningDisabledColor",R(oe,g.warning.main,.55)),k(g.TableCell,"border",R(oe,R(bt,g.divider,1),.68)),k(g.Tooltip,"bg",R(bt,g.grey[700],.92))}Xe(g.background,"default"),Xe(g.background,"paper"),Xe(g.common,"background"),Xe(g.common,"onBackground"),Xe(g,"divider"),Object.keys(g).forEach(W=>{const K=g[W];W!=="tonalOffset"&&K&&typeof K=="object"&&(K.main&&k(g[W],"mainChannel",fn(hn(K.main))),K.light&&k(g[W],"lightChannel",fn(hn(K.light))),K.dark&&k(g[W],"darkChannel",fn(hn(K.dark))),K.contrastText&&k(g[W],"contrastTextChannel",fn(hn(K.contrastText))),W==="text"&&(Xe(g[W],"primary"),Xe(g[W],"secondary")),W==="action"&&(K.active&&Xe(g[W],"active"),K.selected&&Xe(g[W],"selected")))})}),E=t.reduce((D,g)=>De(D,g),E);const P={prefix:s,disableCssColorScheme:o,shouldSkipGeneratingVar:a,getSelector:Fh(E),enableContrastVars:i},{vars:M,generateThemeVars:I,generateStyleSheets:V}=yh(E,P);return E.vars=M,Object.entries(E.colorSchemes[E.defaultColorScheme]).forEach(([D,g])=>{E[D]=g}),E.generateThemeVars=I,E.generateStyleSheets=V,E.generateSpacing=function(){return as.createSpacing(l.spacing,us(this))},E.getColorSchemeSelector=bh(c),E.spacing=E.generateSpacing(),E.shouldSkipGeneratingVar=a,E.unstable_sxConfig={...Ar,...l==null?void 0:l.unstable_sxConfig},E.unstable_sx=function(g){return Ht({sx:g,theme:this})},E.toRuntimeSource=Ec,E}function Ii(e,t,n){e.colorSchemes&&n&&(e.colorSchemes[t]={...n!==!0&&n,palette:hs({...n===!0?{}:n.palette,mode:t})})}function Gh(e={},...t){const{palette:n,cssVariables:r=!1,colorSchemes:o=n?void 0:{light:!0},defaultColorScheme:s=n==null?void 0:n.mode,...i}=e,a=s||"light",c=o==null?void 0:o[a],u={...o,...n?{[a]:{...typeof c!="boolean"&&c,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in e))return Mo(e,...t);let l=n;"palette"in e||u[a]&&(u[a]!==!0?l=u[a].palette:a==="dark"&&(l={mode:"dark"}));const d=Mo({...e,palette:l},...t);return d.defaultColorScheme=a,d.colorSchemes=u,d.palette.mode==="light"&&(d.colorSchemes.light={...u.light!==!0&&u.light,palette:d.palette},Ii(d,"dark",u.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...u.dark!==!0&&u.dark,palette:d.palette},Ii(d,"light",u.light)),d}return!n&&!("light"in u)&&a==="light"&&(u.light=!0),Hh({...i,colorSchemes:u,defaultColorScheme:a,...typeof r!="boolean"&&r},...t)}const Kh=Gh(),Yh="$$material";function Pc(e,t=""){return e.displayName||e.name||t}function Ri(e,t,n){const r=Pc(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Zh(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Pc(e,"Component");if(typeof e=="object")switch(e.$$typeof){case nr.ForwardRef:return Ri(e,e.render,"ForwardRef");case nr.Memo:return Ri(e,e.type,"memo");default:return}}}function qh(e){const{variants:t,...n}=e,r={variants:t,style:Pt(n),isProcessed:!0};return r.style===n||t&&t.forEach(o=>{typeof o.style!="function"&&(o.style=Pt(o.style))}),r}const Xh=_c();function Zr(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Et(e,t){return t&&e&&typeof e=="object"&&e.styles&&!e.styles.startsWith("@layer")&&(e.styles=`@layer ${t}{${String(e.styles)}}`),e}function Jh(e){return e?(t,n)=>n[e]:null}function Qh(e,t,n){e.theme=rm(e.theme)?n:e.theme[t]||e.theme}function Zn(e,t,n){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(o=>Zn(e,o,n));if(Array.isArray(r==null?void 0:r.variants)){let o;if(r.isProcessed)o=n?Et(r.style,n):r.style;else{const{variants:s,...i}=r;o=n?Et(Pt(i),n):i}return kc(e,r.variants,[o],n)}return r!=null&&r.isProcessed?n?Et(Pt(r.style),n):r.style:n?Et(Pt(r),n):r}function kc(e,t,n=[],r=void 0){var s;let o;e:for(let i=0;i<t.length;i+=1){const a=t[i];if(typeof a.props=="function"){if(o??(o={...e,...e.ownerState,ownerState:e.ownerState}),!a.props(o))continue}else for(const c in a.props)if(e[c]!==a.props[c]&&((s=e.ownerState)==null?void 0:s[c])!==a.props[c])continue e;typeof a.style=="function"?(o??(o={...e,...e.ownerState,ownerState:e.ownerState}),n.push(r?Et(Pt(a.style(o)),r):a.style(o))):n.push(r?Et(Pt(a.style),r):a.style)}return n}function em(e={}){const{themeId:t,defaultTheme:n=Xh,rootShouldForwardProp:r=Zr,slotShouldForwardProp:o=Zr}=e;function s(a){Qh(a,t,n)}return(a,c={})=>{ih(a,E=>E.filter(P=>P!==Ht));const{name:u,slot:l,skipVariantsResolver:d,skipSx:f,overridesResolver:h=Jh(Ic(l)),...p}=c,m=u&&u.startsWith("Mui")||l?"components":"custom",v=d!==void 0?d:l&&l!=="Root"&&l!=="root"||!1,S=f||!1;let T=Zr;l==="Root"||l==="root"?T=r:l?T=o:om(a)&&(T=void 0);const b=sh(a,{shouldForwardProp:T,label:nm(u,l),...p}),w=E=>{if(E.__emotion_real===E)return E;if(typeof E=="function")return function(M){return Zn(M,E,M.theme.modularCssLayers?m:void 0)};if(Qe(E)){const P=qh(E);return function(I){return P.variants?Zn(I,P,I.theme.modularCssLayers?m:void 0):I.theme.modularCssLayers?Et(P.style,m):P.style}}return E},C=(...E)=>{const P=[],M=E.map(w),I=[];if(P.push(s),u&&h&&I.push(function($){var G,j;const W=(j=(G=$.theme.components)==null?void 0:G[u])==null?void 0:j.styleOverrides;if(!W)return null;const K={};for(const Q in W)K[Q]=Zn($,W[Q],$.theme.modularCssLayers?"theme":void 0);return h($,K)}),u&&!v&&I.push(function($){var K,G;const R=$.theme,W=(G=(K=R==null?void 0:R.components)==null?void 0:K[u])==null?void 0:G.variants;return W?kc($,W,[],$.theme.modularCssLayers?"theme":void 0):null}),S||I.push(Ht),Array.isArray(M[0])){const g=M.shift(),$=new Array(P.length).fill(""),R=new Array(I.length).fill("");let W;W=[...$,...g,...R],W.raw=[...$,...g.raw,...R],P.unshift(W)}const V=[...P,...M,...I],D=b(...V);return a.muiName&&(D.muiName=a.muiName),process.env.NODE_ENV!=="production"&&(D.displayName=tm(u,l,a)),D};return b.withConfig&&(C.withConfig=b.withConfig),C}}function tm(e,t,n){return e?`${e}${It(t||"")}`:`Styled(${Zh(n)})`}function nm(e,t){let n;return process.env.NODE_ENV!=="production"&&e&&(n=`${e}-${Ic(t||"Root")}`),n}function rm(e){for(const t in e)return!1;return!0}function om(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Ic(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function sm(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const im=e=>sm(e)&&e!=="classes",am=em({themeId:Yh,defaultTheme:Kh,rootShouldForwardProp:im}),cm=as.unstable_memoTheme;process.env.NODE_ENV!=="production"&&(te.node,te.object.isRequired);function lm(e){return lh(e)}function um(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ms(e,o,n)}),r}function dm(e){return ms("MuiSvgIcon",e)}um("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const fm=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${It(t)}`,`fontSize${It(n)}`]};return Hd(o,dm,r)},hm=am("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${It(n.color)}`],t[`fontSize${It(n.fontSize)}`]]}})(cm(({theme:e})=>{var t,n,r,o,s,i,a,c,u,l,d,f,h,p;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(o=(t=e.transitions)==null?void 0:t.create)==null?void 0:o.call(t,"fill",{duration:(r=(n=(e.vars??e).transitions)==null?void 0:n.duration)==null?void 0:r.shorter}),variants:[{props:m=>!m.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((i=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((c=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:c.call(a,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((l=(u=e.typography)==null?void 0:u.pxToRem)==null?void 0:l.call(u,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,m])=>m&&m.main).map(([m])=>{var v,S;return{props:{color:m},style:{color:(S=(v=(e.vars??e).palette)==null?void 0:v[m])==null?void 0:S.main}}}),{props:{color:"action"},style:{color:(f=(d=(e.vars??e).palette)==null?void 0:d.action)==null?void 0:f.active}},{props:{color:"disabled"},style:{color:(p=(h=(e.vars??e).palette)==null?void 0:h.action)==null?void 0:p.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),sr=Ve.forwardRef(function(t,n){const r=lm({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:a="svg",fontSize:c="medium",htmlColor:u,inheritViewBox:l=!1,titleAccess:d,viewBox:f="0 0 24 24",...h}=r,p=Ve.isValidElement(o)&&o.type==="svg",m={...r,color:i,component:a,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:l,viewBox:f,hasSvgAsChild:p},v={};l||(v.viewBox=f);const S=fm(m);return y.jsxs(hm,{as:a,className:gc(S.root,s),focusable:"false",color:u,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:n,...v,...h,...p&&o.props,ownerState:m,children:[p?o.props.children:o,d?y.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(sr.propTypes={children:te.node,classes:te.object,className:te.string,color:te.oneOfType([te.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),te.string]),component:te.elementType,fontSize:te.oneOfType([te.oneOf(["inherit","large","medium","small"]),te.string]),htmlColor:te.string,inheritViewBox:te.bool,shapeRendering:te.string,sx:te.oneOfType([te.arrayOf(te.oneOfType([te.func,te.object,te.bool])),te.func,te.object]),titleAccess:te.string,viewBox:te.string});sr.muiName="SvgIcon";function st(e,t){function n(r,o){return y.jsx(sr,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:o,...r,children:e})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=sr.muiName,Ve.memo(Ve.forwardRef(n))}const mm=st(y.jsx("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"}),"ExpandMore"),pm=st(y.jsx("path",{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"}),"ExpandLess"),gm=st(y.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),ym=(e,t)=>()=>{if(!t)return;const n={};e.forEach(r=>{r.items.forEach(o=>{o.value!==void 0&&o.value!==null&&o.value!==""&&(n[o.id]=o.value)})}),console.log("Filtros ativos:",n),t(n)},vm=(e,t,n)=>()=>{const r=e.map(o=>({...o,items:o.items.map(s=>({...s,value:void 0}))}));n&&n(r),t&&t()},bm=(e,t,n)=>()=>{const r=t.map(o=>o.id===e?{...o,expanded:!o.expanded}:o);n(r)},xm=(e,t,n,r)=>o=>{const s=n.map(i=>i.id===e?{...i,items:i.items.map(a=>a.id===t?{...a,value:o}:a)}:i);r(s)},Sm="_modal_1v49l_1",Tm="_content_1v49l_60",Cm="_contentWrapper_1v49l_67",wm="_closeButton_1v49l_74",_m="_header_1v49l_86",Em="_title_1v49l_93",Am="_description_1v49l_102",Mm="_filtersContent_1v49l_111",Pm="_filterGroup_1v49l_121",km="_expandableHeader_1v49l_128",Im="_expandableLabel_1v49l_138",Rm="_chevronIcon_1v49l_146",Om="_chevron_1v49l_146",Lm="_filterItems_1v49l_159",Dm="_filterItem_1v49l_159",jm="_filterItemSize1_1v49l_171",Bm="_filterItemSize2_1v49l_175",$m="_filterItemSize3_1v49l_179",Nm="_filterItemSize4_1v49l_183",Vm="_filterItemSize5_1v49l_187",Fm="_filterItemSize6_1v49l_191",zm="_filterInput_1v49l_195",Wm="_inputLabel_1v49l_199",Um="_select_1v49l_203",Hm="_placeholder_1v49l_220",Gm="_helperText_1v49l_224",Km="_footer_1v49l_231",Ym="_clearButton_1v49l_238",Zm="_applyButton_1v49l_260",ce={modal:Sm,content:Tm,contentWrapper:Cm,closeButton:wm,header:_m,title:Em,description:Am,filtersContent:Mm,filterGroup:Pm,expandableHeader:km,expandableLabel:Im,chevronIcon:Rm,chevron:Om,filterItems:Lm,filterItem:Dm,filterItemSize1:jm,filterItemSize2:Bm,filterItemSize3:$m,filterItemSize4:Nm,filterItemSize5:Vm,filterItemSize6:Fm,filterInput:zm,inputLabel:Wm,select:Um,"Mui-focused":"_Mui-focused_1v49l_212",placeholder:Hm,helperText:Gm,footer:Km,clearButton:Ym,applyButton:Zm},Rc=({open:e,onClose:t,title:n="Filtros",description:r="Use os filtros abaixo para encontrar câmeras e pontos de interesse.",groups:o,onApply:s,onClear:i,clearButtonText:a="Limpar filtros",applyButtonText:c="Filtrar",className:u,...l})=>{const f=A.useTheme().palette.mode==="dark",[h,p]=x.useState(o);x.useEffect(()=>{p(o)},[o]);const m=ym(h,s),v=vm(h,i,p),S=(T,b)=>{var P;const w=xm(b,T.id,h,p),C=T.size||6,E=ce[`filterItemSize${C}`];if(T.render)return y.jsx(A.Box,{className:`${ce.filterItem} ${E}`,children:T.render(T,w)},T.id);switch(T.type){case"select":case"multi-select":const M=T.type==="multi-select";let I;M?T.value!==void 0&&T.value!==null?I=Array.isArray(T.value)?T.value:[T.value]:I=[]:I=T.value!==void 0&&T.value!==null?T.value:"";const V=M?Array.isArray(I)&&I.length>0:I!==""&&I!==null&&I!==void 0;return y.jsx(A.Box,{className:`${ce.filterItem} ${E}`,children:y.jsxs(A.FormControl,{fullWidth:!0,className:ce.filterInput,children:[y.jsx(A.InputLabel,{id:`${T.id}-label`,className:ce.inputLabel,shrink:V,children:T.label}),y.jsx(A.Select,{labelId:`${T.id}-label`,value:I,onChange:D=>w(D.target.value),multiple:M,label:T.label,className:ce.select,displayEmpty:!0,renderValue:D=>{var $;if(M){const R=Array.isArray(D)?D:[];return R.length===0?y.jsx(A.Box,{component:"span",style:{opacity:0},children:T.label}):R.map(K=>{var G,j;return((j=(G=T.options)==null?void 0:G.find(Q=>Q.value===K))==null?void 0:j.label)||K}).join(", ")}if(!D||D==="")return y.jsx(A.Box,{component:"span",style:{opacity:0},children:T.label});const g=($=T.options)==null?void 0:$.find(R=>R.value===D);return(g==null?void 0:g.label)||D},notched:V,children:(P=T.options)==null?void 0:P.map(D=>y.jsx(A.MenuItem,{value:D.value,children:D.label},D.value))}),T.helperText&&y.jsx(A.Box,{className:ce.helperText,children:T.helperText})]})},T.id);case"text":return y.jsx(A.Box,{className:`${ce.filterItem} ${E}`,children:y.jsx(A.TextField,{fullWidth:!0,label:T.label,placeholder:T.placeholder,value:T.value||"",onChange:D=>w(D.target.value),className:ce.filterInput,helperText:T.helperText,FormHelperTextProps:{className:ce.helperText}})},T.id);default:return null}};return y.jsx(A.Dialog,{open:e,onClose:t,maxWidth:"md",fullWidth:!0,PaperProps:{className:`${ce.modal} ${u||""}`,"data-theme":f?"dark":"light"},...l,children:y.jsx(A.DialogContent,{className:ce.content,children:y.jsxs(A.Box,{className:ce.contentWrapper,children:[y.jsx(A.IconButton,{className:ce.closeButton,onClick:t,"aria-label":"Fechar",size:"small",children:y.jsx(gm,{})}),y.jsxs(A.Box,{className:ce.header,children:[y.jsx(A.Box,{className:ce.title,children:n}),y.jsx(A.Box,{className:ce.description,children:r})]}),y.jsx(A.Box,{className:ce.filtersContent,children:h.map(T=>{const b=bm(T.id,h,p),w=T.expanded!==!1;return y.jsxs(A.Box,{className:ce.filterGroup,children:[y.jsxs(A.Box,{className:ce.expandableHeader,onClick:b,children:[y.jsx(A.Box,{className:ce.expandableLabel,children:T.label}),y.jsx(A.Box,{className:ce.chevronIcon,children:w?y.jsx(pm,{className:ce.chevron}):y.jsx(mm,{className:ce.chevron})})]}),w&&y.jsx(A.Box,{className:ce.filterItems,children:T.items.map(C=>S(C,T.id))})]},T.id)})}),y.jsxs(A.Box,{className:ce.footer,children:[y.jsx(A.Button,{onClick:v,className:ce.clearButton,"data-theme":f?"dark":"light",children:a}),y.jsx(A.Button,{onClick:m,className:ce.applyButton,"data-theme":f?"dark":"light",children:c})]})]})})})};Rc.displayName="FilterModal";const qm="_container_1hyey_1",Xm="_card_1hyey_7",Jm="_icon_1hyey_18",Qm="_text_1hyey_32",$n={container:qm,card:Xm,icon:Jm,text:Qm},ep=({items:e,className:t,sx:n})=>{const r=A.useTheme(),o={backgroundColor:r.palette.background.paper,borderColor:r.palette.divider},s={color:r.palette.text.primary,"& svg":{fill:r.palette.text.primary}},i={color:r.palette.text.secondary,fontFamily:r.typography.fontFamily,fontSize:r.typography.body2.fontSize,fontWeight:r.typography.fontWeightMedium,lineHeight:r.typography.body2.lineHeight};return y.jsx(A.Box,{className:`${$n.container} ${t||""}`,sx:n,children:e.map((a,c)=>y.jsxs(A.Box,{className:$n.card,sx:o,children:[a.icon&&y.jsx(A.Box,{className:$n.icon,sx:s,children:a.icon}),y.jsxs(A.Typography,{component:"span",className:$n.text,sx:i,children:[a.count," ",a.label]})]},c))})},ps=x.createContext({});function gs(e){const t=x.useRef(null);return t.current===null&&(t.current=e()),t.current}const Oc=typeof window<"u",Lc=Oc?x.useLayoutEffect:x.useEffect,Ir=x.createContext(null);function ys(e,t){e.indexOf(t)===-1&&e.push(t)}function vs(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const qe=(e,t,n)=>n>t?t:n<e?e:n;function Po(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let Yt=()=>{},rt=()=>{};var oc;typeof process<"u"&&((oc=process.env)==null?void 0:oc.NODE_ENV)!=="production"&&(Yt=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(Po(t,n))},rt=(e,t,n)=>{if(!e)throw new Error(Po(t,n))});const ot={},Dc=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function jc(e){return typeof e=="object"&&e!==null}const Bc=e=>/^0[^.\s]+$/u.test(e);function bs(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ne=e=>e,tp=(e,t)=>n=>t(e(n)),Pn=(...e)=>e.reduce(tp),Tn=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class xs{constructor(){this.subscriptions=[]}add(t){return ys(this.subscriptions,t),()=>vs(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let s=0;s<o;s++){const i=this.subscriptions[s];i&&i(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Ye=e=>e*1e3,$e=e=>e/1e3;function $c(e,t){return t?e*(1e3/t):0}const Oi=new Set;function Ss(e,t,n){e||Oi.has(t)||(console.warn(Po(t,n)),Oi.add(t))}const Nc=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,np=1e-7,rp=12;function op(e,t,n,r,o){let s,i,a=0;do i=t+(n-t)/2,s=Nc(i,r,o)-e,s>0?n=i:t=i;while(Math.abs(s)>np&&++a<rp);return i}function kn(e,t,n,r){if(e===t&&n===r)return Ne;const o=s=>op(s,0,1,e,n);return s=>s===0||s===1?s:Nc(o(s),t,r)}const Vc=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Fc=e=>t=>1-e(1-t),zc=kn(.33,1.53,.69,.99),Ts=Fc(zc),Wc=Vc(Ts),Uc=e=>(e*=2)<1?.5*Ts(e):.5*(2-Math.pow(2,-10*(e-1))),Cs=e=>1-Math.sin(Math.acos(e)),Hc=Fc(Cs),Gc=Vc(Cs),sp=kn(.42,0,1,1),ip=kn(0,0,.58,1),Kc=kn(.42,0,.58,1),ap=e=>Array.isArray(e)&&typeof e[0]!="number",Yc=e=>Array.isArray(e)&&typeof e[0]=="number",Li={linear:Ne,easeIn:sp,easeInOut:Kc,easeOut:ip,circIn:Cs,circInOut:Gc,circOut:Hc,backIn:Ts,backInOut:Wc,backOut:zc,anticipate:Uc},cp=e=>typeof e=="string",Di=e=>{if(Yc(e)){rt(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,o]=e;return kn(t,n,r,o)}else if(cp(e))return rt(Li[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),Li[e];return e},Nn=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function lp(e,t){let n=new Set,r=new Set,o=!1,s=!1;const i=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function c(l){i.has(l)&&(u.schedule(l),e()),l(a)}const u={schedule:(l,d=!1,f=!1)=>{const p=f&&o?n:r;return d&&i.add(l),p.has(l)||p.add(l),l},cancel:l=>{r.delete(l),i.delete(l)},process:l=>{if(a=l,o){s=!0;return}o=!0,[n,r]=[r,n],n.forEach(c),n.clear(),o=!1,s&&(s=!1,u.process(l))}};return u}const up=40;function Zc(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,i=Nn.reduce((b,w)=>(b[w]=lp(s),b),{}),{setup:a,read:c,resolveKeyframes:u,preUpdate:l,update:d,preRender:f,render:h,postRender:p}=i,m=()=>{const b=ot.useManualTiming?o.timestamp:performance.now();n=!1,ot.useManualTiming||(o.delta=r?1e3/60:Math.max(Math.min(b-o.timestamp,up),1)),o.timestamp=b,o.isProcessing=!0,a.process(o),c.process(o),u.process(o),l.process(o),d.process(o),f.process(o),h.process(o),p.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(m))},v=()=>{n=!0,r=!0,o.isProcessing||e(m)};return{schedule:Nn.reduce((b,w)=>{const C=i[w];return b[w]=(E,P=!1,M=!1)=>(n||v(),C.schedule(E,P,M)),b},{}),cancel:b=>{for(let w=0;w<Nn.length;w++)i[Nn[w]].cancel(b)},state:o,steps:i}}const{schedule:le,cancel:pt,state:Me,steps:qr}=Zc(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ne,!0);let qn;function dp(){qn=void 0}const Ie={now:()=>(qn===void 0&&Ie.set(Me.isProcessing||ot.useManualTiming?Me.timestamp:performance.now()),qn),set:e=>{qn=e,queueMicrotask(dp)}},qc=e=>t=>typeof t=="string"&&t.startsWith(e),Xc=qc("--"),fp=qc("var(--"),ws=e=>fp(e)?hp.test(e.split("/*")[0].trim()):!1,hp=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function ji(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const Zt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Cn={...Zt,transform:e=>qe(0,1,e)},Vn={...Zt,default:1},vn=e=>Math.round(e*1e5)/1e5,_s=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function mp(e){return e==null}const pp=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Es=(e,t)=>n=>!!(typeof n=="string"&&pp.test(n)&&n.startsWith(e)||t&&!mp(n)&&Object.prototype.hasOwnProperty.call(n,t)),Jc=(e,t,n)=>r=>{if(typeof r!="string")return r;const[o,s,i,a]=r.match(_s);return{[e]:parseFloat(o),[t]:parseFloat(s),[n]:parseFloat(i),alpha:a!==void 0?parseFloat(a):1}},gp=e=>qe(0,255,e),Xr={...Zt,transform:e=>Math.round(gp(e))},At={test:Es("rgb","red"),parse:Jc("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Xr.transform(e)+", "+Xr.transform(t)+", "+Xr.transform(n)+", "+vn(Cn.transform(r))+")"};function yp(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const ko={test:Es("#"),parse:yp,transform:At.transform},In=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),at=In("deg"),Ze=In("%"),H=In("px"),vp=In("vh"),bp=In("vw"),Bi={...Ze,parse:e=>Ze.parse(e)/100,transform:e=>Ze.transform(e*100)},Bt={test:Es("hsl","hue"),parse:Jc("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Ze.transform(vn(t))+", "+Ze.transform(vn(n))+", "+vn(Cn.transform(r))+")"},Se={test:e=>At.test(e)||ko.test(e)||Bt.test(e),parse:e=>At.test(e)?At.parse(e):Bt.test(e)?Bt.parse(e):ko.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?At.transform(e):Bt.transform(e),getAnimatableNone:e=>{const t=Se.parse(e);return t.alpha=0,Se.transform(t)}},xp=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Sp(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(_s))==null?void 0:t.length)||0)+(((n=e.match(xp))==null?void 0:n.length)||0)>0}const Qc="number",el="color",Tp="var",Cp="var(",$i="${}",wp=/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 wn(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let s=0;const a=t.replace(wp,c=>(Se.test(c)?(r.color.push(s),o.push(el),n.push(Se.parse(c))):c.startsWith(Cp)?(r.var.push(s),o.push(Tp),n.push(c)):(r.number.push(s),o.push(Qc),n.push(parseFloat(c))),++s,$i)).split($i);return{values:n,split:a,indexes:r,types:o}}function tl(e){return wn(e).values}function nl(e){const{split:t,types:n}=wn(e),r=t.length;return o=>{let s="";for(let i=0;i<r;i++)if(s+=t[i],o[i]!==void 0){const a=n[i];a===Qc?s+=vn(o[i]):a===el?s+=Se.transform(o[i]):s+=o[i]}return s}}const _p=e=>typeof e=="number"?0:Se.test(e)?Se.getAnimatableNone(e):e;function Ep(e){const t=tl(e);return nl(e)(t.map(_p))}const gt={test:Sp,parse:tl,createTransformer:nl,getAnimatableNone:Ep};function Jr(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Ap({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,s=0,i=0;if(!t)o=s=i=n;else{const a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;o=Jr(c,a,e+1/3),s=Jr(c,a,e),i=Jr(c,a,e-1/3)}return{red:Math.round(o*255),green:Math.round(s*255),blue:Math.round(i*255),alpha:r}}function ir(e,t){return n=>n>0?t:e}const he=(e,t,n)=>e+(t-e)*n,Qr=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},Mp=[ko,At,Bt],Pp=e=>Mp.find(t=>t.test(e));function Ni(e){const t=Pp(e);if(Yt(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===Bt&&(n=Ap(n)),n}const Vi=(e,t)=>{const n=Ni(e),r=Ni(t);if(!n||!r)return ir(e,t);const o={...n};return s=>(o.red=Qr(n.red,r.red,s),o.green=Qr(n.green,r.green,s),o.blue=Qr(n.blue,r.blue,s),o.alpha=he(n.alpha,r.alpha,s),At.transform(o))},Io=new Set(["none","hidden"]);function kp(e,t){return Io.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Ip(e,t){return n=>he(e,t,n)}function As(e){return typeof e=="number"?Ip:typeof e=="string"?ws(e)?ir:Se.test(e)?Vi:Lp:Array.isArray(e)?rl:typeof e=="object"?Se.test(e)?Vi:Rp:ir}function rl(e,t){const n=[...e],r=n.length,o=e.map((s,i)=>As(s)(s,t[i]));return s=>{for(let i=0;i<r;i++)n[i]=o[i](s);return n}}function Rp(e,t){const n={...e,...t},r={};for(const o in n)e[o]!==void 0&&t[o]!==void 0&&(r[o]=As(e[o])(e[o],t[o]));return o=>{for(const s in r)n[s]=r[s](o);return n}}function Op(e,t){const n=[],r={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){const s=t.types[o],i=e.indexes[s][r[s]],a=e.values[i]??0;n[o]=a,r[s]++}return n}const Lp=(e,t)=>{const n=gt.createTransformer(t),r=wn(e),o=wn(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?Io.has(e)&&!o.values.length||Io.has(t)&&!r.values.length?kp(e,t):Pn(rl(Op(r,o),o.values),n):(Yt(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),ir(e,t))};function ol(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?he(e,t,n):As(e)(e,t)}const Dp=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>le.update(t,n),stop:()=>pt(t),now:()=>Me.isProcessing?Me.timestamp:Ie.now()}},sl=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let s=0;s<o;s++)r+=Math.round(e(s/(o-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},ar=2e4;function Ms(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<ar;)t+=n,r=e.next(t);return t>=ar?1/0:t}function jp(e,t=100,n){const r=n({...e,keyframes:[0,t]}),o=Math.min(Ms(r),ar);return{type:"keyframes",ease:s=>r.next(o*s).value/t,duration:$e(o)}}const Bp=5;function il(e,t,n){const r=Math.max(t-Bp,0);return $c(n-e(r),t-r)}const fe={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},eo=.001;function $p({duration:e=fe.duration,bounce:t=fe.bounce,velocity:n=fe.velocity,mass:r=fe.mass}){let o,s;Yt(e<=Ye(fe.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let i=1-t;i=qe(fe.minDamping,fe.maxDamping,i),e=qe(fe.minDuration,fe.maxDuration,$e(e)),i<1?(o=u=>{const l=u*i,d=l*e,f=l-n,h=Ro(u,i),p=Math.exp(-d);return eo-f/h*p},s=u=>{const d=u*i*e,f=d*n+n,h=Math.pow(i,2)*Math.pow(u,2)*e,p=Math.exp(-d),m=Ro(Math.pow(u,2),i);return(-o(u)+eo>0?-1:1)*((f-h)*p)/m}):(o=u=>{const l=Math.exp(-u*e),d=(u-n)*e+1;return-eo+l*d},s=u=>{const l=Math.exp(-u*e),d=(n-u)*(e*e);return l*d});const a=5/e,c=Vp(o,s,a);if(e=Ye(e),isNaN(c))return{stiffness:fe.stiffness,damping:fe.damping,duration:e};{const u=Math.pow(c,2)*r;return{stiffness:u,damping:i*2*Math.sqrt(r*u),duration:e}}}const Np=12;function Vp(e,t,n){let r=n;for(let o=1;o<Np;o++)r=r-e(r)/t(r);return r}function Ro(e,t){return e*Math.sqrt(1-t*t)}const Fp=["duration","bounce"],zp=["stiffness","damping","mass"];function Fi(e,t){return t.some(n=>e[n]!==void 0)}function Wp(e){let t={velocity:fe.velocity,stiffness:fe.stiffness,damping:fe.damping,mass:fe.mass,isResolvedFromDuration:!1,...e};if(!Fi(e,zp)&&Fi(e,Fp))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),o=r*r,s=2*qe(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:fe.mass,stiffness:o,damping:s}}else{const n=$p(e);t={...t,...n,mass:fe.mass},t.isResolvedFromDuration=!0}return t}function cr(e=fe.visualDuration,t=fe.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const s=n.keyframes[0],i=n.keyframes[n.keyframes.length-1],a={done:!1,value:s},{stiffness:c,damping:u,mass:l,duration:d,velocity:f,isResolvedFromDuration:h}=Wp({...n,velocity:-$e(n.velocity||0)}),p=f||0,m=u/(2*Math.sqrt(c*l)),v=i-s,S=$e(Math.sqrt(c/l)),T=Math.abs(v)<5;r||(r=T?fe.restSpeed.granular:fe.restSpeed.default),o||(o=T?fe.restDelta.granular:fe.restDelta.default);let b;if(m<1){const C=Ro(S,m);b=E=>{const P=Math.exp(-m*S*E);return i-P*((p+m*S*v)/C*Math.sin(C*E)+v*Math.cos(C*E))}}else if(m===1)b=C=>i-Math.exp(-S*C)*(v+(p+S*v)*C);else{const C=S*Math.sqrt(m*m-1);b=E=>{const P=Math.exp(-m*S*E),M=Math.min(C*E,300);return i-P*((p+m*S*v)*Math.sinh(M)+C*v*Math.cosh(M))/C}}const w={calculatedDuration:h&&d||null,next:C=>{const E=b(C);if(h)a.done=C>=d;else{let P=C===0?p:0;m<1&&(P=C===0?Ye(p):il(b,C,E));const M=Math.abs(P)<=r,I=Math.abs(i-E)<=o;a.done=M&&I}return a.value=a.done?i:E,a},toString:()=>{const C=Math.min(Ms(w),ar),E=sl(P=>w.next(C*P).value,C,30);return C+"ms "+E},toTransition:()=>{}};return w}cr.applyToOptions=e=>{const t=jp(e,100,cr);return e.ease=t.ease,e.duration=Ye(t.duration),e.type="keyframes",e};function Oo({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:s=500,modifyTarget:i,min:a,max:c,restDelta:u=.5,restSpeed:l}){const d=e[0],f={done:!1,value:d},h=M=>a!==void 0&&M<a||c!==void 0&&M>c,p=M=>a===void 0?c:c===void 0||Math.abs(a-M)<Math.abs(c-M)?a:c;let m=n*t;const v=d+m,S=i===void 0?v:i(v);S!==v&&(m=S-d);const T=M=>-m*Math.exp(-M/r),b=M=>S+T(M),w=M=>{const I=T(M),V=b(M);f.done=Math.abs(I)<=u,f.value=f.done?S:V};let C,E;const P=M=>{h(f.value)&&(C=M,E=cr({keyframes:[f.value,p(f.value)],velocity:il(b,M,f.value),damping:o,stiffness:s,restDelta:u,restSpeed:l}))};return P(0),{calculatedDuration:null,next:M=>{let I=!1;return!E&&C===void 0&&(I=!0,w(M),P(M)),C!==void 0&&M>=C?E.next(M-C):(!I&&w(M),f)}}}function Up(e,t,n){const r=[],o=n||ot.mix||ol,s=e.length-1;for(let i=0;i<s;i++){let a=o(e[i],e[i+1]);if(t){const c=Array.isArray(t)?t[i]||Ne:t;a=Pn(c,a)}r.push(a)}return r}function Hp(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const s=e.length;if(rt(s===t.length,"Both input and output ranges must be the same length","range-length"),s===1)return()=>t[0];if(s===2&&t[0]===t[1])return()=>t[1];const i=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=Up(t,r,o),c=a.length,u=l=>{if(i&&l<e[0])return t[0];let d=0;if(c>1)for(;d<e.length-2&&!(l<e[d+1]);d++);const f=Tn(e[d],e[d+1],l);return a[d](f)};return n?l=>u(qe(e[0],e[s-1],l)):u}function Gp(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=Tn(0,t,r);e.push(he(n,1,o))}}function Kp(e){const t=[0];return Gp(t,e.length-1),t}function Yp(e,t){return e.map(n=>n*t)}function Zp(e,t){return e.map(()=>t||Kc).splice(0,e.length-1)}function $t({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=ap(r)?r.map(Di):Di(r),s={done:!1,value:t[0]},i=Yp(n&&n.length===t.length?n:Kp(t),e),a=Hp(i,t,{ease:Array.isArray(o)?o:Zp(t,o)});return{calculatedDuration:e,next:c=>(s.value=a(c),s.done=c>=e,s)}}const qp=e=>e!==null;function Ps(e,{repeat:t,repeatType:n="loop"},r,o=1){const s=e.filter(qp),a=o<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!a||r===void 0?s[a]:r}const Xp={decay:Oo,inertia:Oo,tween:$t,keyframes:$t,spring:cr};function al(e){typeof e.type=="string"&&(e.type=Xp[e.type])}class ks{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Jp=e=>e/100;class Is extends ks{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,o;const{motionValue:n}=this.options;n&&n.updatedAt!==Ie.now()&&this.tick(Ie.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(o=(r=this.options).onStop)==null||o.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;al(t);const{type:n=$t,repeat:r=0,repeatDelay:o=0,repeatType:s,velocity:i=0}=t;let{keyframes:a}=t;const c=n||$t;process.env.NODE_ENV!=="production"&&c!==$t&&rt(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),c!==$t&&typeof a[0]!="number"&&(this.mixKeyframes=Pn(Jp,ol(a[0],a[1])),a=[0,100]);const u=c({...t,keyframes:a});s==="mirror"&&(this.mirroredGenerator=c({...t,keyframes:[...a].reverse(),velocity:-i})),u.calculatedDuration===null&&(u.calculatedDuration=Ms(u));const{calculatedDuration:l}=u;this.calculatedDuration=l,this.resolvedDuration=l+o,this.totalDuration=this.resolvedDuration*(r+1)-o,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:o,mixKeyframes:s,mirroredGenerator:i,resolvedDuration:a,calculatedDuration:c}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:l,repeat:d,repeatType:f,repeatDelay:h,type:p,onUpdate:m,finalKeyframe:v}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-o/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const S=this.currentTime-u*(this.playbackSpeed>=0?1:-1),T=this.playbackSpeed>=0?S<0:S>o;this.currentTime=Math.max(S,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let b=this.currentTime,w=r;if(d){const M=Math.min(this.currentTime,o)/a;let I=Math.floor(M),V=M%1;!V&&M>=1&&(V=1),V===1&&I--,I=Math.min(I,d+1),!!(I%2)&&(f==="reverse"?(V=1-V,h&&(V-=h/a)):f==="mirror"&&(w=i)),b=qe(0,1,V)*a}const C=T?{done:!1,value:l[0]}:w.next(b);s&&(C.value=s(C.value));let{done:E}=C;!T&&c!==null&&(E=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);const P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&E);return P&&p!==Oo&&(C.value=Ps(l,this.options,v,this.speed)),m&&m(C.value),P&&this.finish(),C}then(t,n){return this.finished.then(t,n)}get duration(){return $e(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+$e(t)}get time(){return $e(this.currentTime)}set time(t){var n;t=Ye(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),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Ie.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=$e(this.currentTime))}play(){var o,s;if(this.isStopped)return;const{driver:t=Dp,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),(s=(o=this.options).onPlay)==null||s.call(o);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=n??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(Ie.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.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 n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function Qp(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Mt=e=>e*180/Math.PI,Lo=e=>{const t=Mt(Math.atan2(e[1],e[0]));return Do(t)},eg={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Lo,rotateZ:Lo,skewX:e=>Mt(Math.atan(e[1])),skewY:e=>Mt(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Do=e=>(e=e%360,e<0&&(e+=360),e),zi=Lo,Wi=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Ui=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),tg={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Wi,scaleY:Ui,scale:e=>(Wi(e)+Ui(e))/2,rotateX:e=>Do(Mt(Math.atan2(e[6],e[5]))),rotateY:e=>Do(Mt(Math.atan2(-e[2],e[0]))),rotateZ:zi,rotate:zi,skewX:e=>Mt(Math.atan(e[4])),skewY:e=>Mt(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function jo(e){return e.includes("scale")?1:0}function Bo(e,t){if(!e||e==="none")return jo(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,o;if(n)r=tg,o=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=eg,o=a}if(!o)return jo(t);const s=r[t],i=o[1].split(",").map(rg);return typeof s=="function"?s(i):i[s]}const ng=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return Bo(n,t)};function rg(e){return parseFloat(e.trim())}const qt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Xt=new Set(qt),Hi=e=>e===Zt||e===H,og=new Set(["x","y","z"]),sg=qt.filter(e=>!og.has(e));function ig(e){const t=[];return sg.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const dt={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>Bo(t,"x"),y:(e,{transform:t})=>Bo(t,"y")};dt.translateX=dt.x;dt.translateY=dt.y;const kt=new Set;let $o=!1,No=!1,Vo=!1;function cl(){if(No){const e=Array.from(kt).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const o=ig(r);o.length&&(n.set(r,o),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const o=n.get(r);o&&o.forEach(([s,i])=>{var a;(a=r.getValue(s))==null||a.set(i)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}No=!1,$o=!1,kt.forEach(e=>e.complete(Vo)),kt.clear()}function ll(){kt.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(No=!0)})}function ag(){Vo=!0,ll(),cl(),Vo=!1}class Rs{constructor(t,n,r,o,s,i=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=o,this.element=s,this.isAsync=i}scheduleResolve(){this.state="scheduled",this.isAsync?(kt.add(this),$o||($o=!0,le.read(ll),le.resolveKeyframes(cl))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:o}=this;if(t[0]===null){const s=o==null?void 0:o.get(),i=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const a=r.readValue(n,i);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=i),o&&s===void 0&&o.set(t[0])}Qp(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),kt.delete(this)}cancel(){this.state==="scheduled"&&(kt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const cg=e=>e.startsWith("--");function lg(e,t,n){cg(t)?e.style.setProperty(t,n):e.style[t]=n}const ug=bs(()=>window.ScrollTimeline!==void 0),dg={};function fg(e,t){const n=bs(e);return()=>dg[t]??n()}const ul=fg(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),mn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Gi={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:mn([0,.65,.55,1]),circOut:mn([.55,0,1,.45]),backIn:mn([.31,.01,.66,-.59]),backOut:mn([.33,1.53,.69,.99])};function dl(e,t){if(e)return typeof e=="function"?ul()?sl(e,t):"ease-out":Yc(e)?mn(e):Array.isArray(e)?e.map(n=>dl(n,t)||Gi.easeOut):Gi[e]}function hg(e,t,n,{delay:r=0,duration:o=300,repeat:s=0,repeatType:i="loop",ease:a="easeOut",times:c}={},u=void 0){const l={[t]:n};c&&(l.offset=c);const d=dl(a,o);Array.isArray(d)&&(l.easing=d);const f={delay:r,duration:o,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:s+1,direction:i==="reverse"?"alternate":"normal"};return u&&(f.pseudoElement=u),e.animate(l,f)}function fl(e){return typeof e=="function"&&"applyToOptions"in e}function mg({type:e,...t}){return fl(e)&&ul()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class pg extends ks{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:o,pseudoElement:s,allowFlatten:i=!1,finalKeyframe:a,onComplete:c}=t;this.isPseudoElement=!!s,this.allowFlatten=i,this.options=t,rt(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const u=mg(t);this.animation=hg(n,r,o,u,s),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const l=Ps(o,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(l):lg(n,r,l),this.animation.cancel()}c==null||c(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.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 t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return $e(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+$e(t)}get time(){return $e(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Ye(t)}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,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&ug()?(this.animation.timeline=t,Ne):n(this)}}const hl={anticipate:Uc,backInOut:Wc,circInOut:Gc};function gg(e){return e in hl}function yg(e){typeof e.ease=="string"&&gg(e.ease)&&(e.ease=hl[e.ease])}const to=10;class vg extends pg{constructor(t){yg(t),al(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:o,element:s,...i}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new Is({...i,autoplay:!1}),c=Math.max(to,Ie.now()-this.startTime),u=qe(0,to,c-to);n.setWithVelocity(a.sample(Math.max(0,c-u)).value,a.sample(c).value,u),a.stop()}}const Ki=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(gt.test(e)||e==="0")&&!e.startsWith("url("));function bg(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function xg(e,t,n,r){const o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;const s=e[e.length-1],i=Ki(o,t),a=Ki(s,t);return Yt(i===a,`You are trying to animate ${t} from "${o}" to "${s}". "${i?s:o}" is not an animatable value.`,"value-not-animatable"),!i||!a?!1:bg(e)||(n==="spring"||fl(n))&&r}function Fo(e){e.duration=0,e.type="keyframes"}const Sg=new Set(["opacity","clipPath","filter","transform"]),Tg=bs(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Cg(e){var l;const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:s,type:i}=e;if(!(((l=t==null?void 0:t.owner)==null?void 0:l.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:u}=t.owner.getProps();return Tg()&&n&&Sg.has(n)&&(n!=="transform"||!u)&&!c&&!r&&o!=="mirror"&&s!==0&&i!=="inertia"}const wg=40;class _g extends ks{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:i="loop",keyframes:a,name:c,motionValue:u,element:l,...d}){var p;super(),this.stop=()=>{var m,v;this._animation&&(this._animation.stop(),(m=this.stopTimeline)==null||m.call(this)),(v=this.keyframeResolver)==null||v.cancel()},this.createdAt=Ie.now();const f={autoplay:t,delay:n,type:r,repeat:o,repeatDelay:s,repeatType:i,name:c,motionValue:u,element:l,...d},h=(l==null?void 0:l.KeyframeResolver)||Rs;this.keyframeResolver=new h(a,(m,v,S)=>this.onKeyframesResolved(m,v,f,!S),c,u,l),(p=this.keyframeResolver)==null||p.scheduleResolve()}onKeyframesResolved(t,n,r,o){var v,S;this.keyframeResolver=void 0;const{name:s,type:i,velocity:a,delay:c,isHandoff:u,onUpdate:l}=r;this.resolvedAt=Ie.now(),xg(t,s,i,a)||((ot.instantAnimations||!c)&&(l==null||l(Ps(t,r,n))),t[0]=t[t.length-1],Fo(r),r.repeat=0);const f={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>wg?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},h=!u&&Cg(f),p=(S=(v=f.motionValue)==null?void 0:v.owner)==null?void 0:S.current,m=h?new vg({...f,element:p}):new Is(f);m.finished.then(()=>{this.notifyFinished()}).catch(Ne),this.pendingTimeline&&(this.stopTimeline=m.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=m}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),ag()),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 ml(e,t,n,r=0,o=1){const s=Array.from(e).sort((u,l)=>u.sortNodePosition(l)).indexOf(t),i=e.size,a=(i-1)*r;return typeof n=="function"?n(s,i):o===1?s*r:a-s*r}const Eg=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Ag(e){const t=Eg.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${n??r}`,o]}const Mg=4;function pl(e,t,n=1){rt(n<=Mg,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,o]=Ag(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const i=s.trim();return Dc(i)?parseFloat(i):i}return ws(o)?pl(o,t,n+1):o}const Pg={type:"spring",stiffness:500,damping:25,restSpeed:10},kg=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Ig={type:"keyframes",duration:.8},Rg={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Og=(e,{keyframes:t})=>t.length>2?Ig:Xt.has(e)?e.startsWith("scale")?kg(t[1]):Pg:Rg,Lg=e=>e!==null;function Dg(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(Lg),s=t&&n!=="loop"&&t%2===1?0:o.length-1;return o[s]}function Os(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}function jg({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:s,repeatType:i,repeatDelay:a,from:c,elapsed:u,...l}){return!!Object.keys(l).length}const Ls=(e,t,n,r={},o,s)=>i=>{const a=Os(r,e)||{},c=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-Ye(c);const l={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{i(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:s?void 0:o};jg(a)||Object.assign(l,Og(e,l)),l.duration&&(l.duration=Ye(l.duration)),l.repeatDelay&&(l.repeatDelay=Ye(l.repeatDelay)),l.from!==void 0&&(l.keyframes[0]=l.from);let d=!1;if((l.type===!1||l.duration===0&&!l.repeatDelay)&&(Fo(l),l.delay===0&&(d=!0)),(ot.instantAnimations||ot.skipAnimations)&&(d=!0,Fo(l),l.delay=0),l.allowFlatten=!a.type&&!a.ease,d&&!s&&t.get()!==void 0){const f=Dg(l.keyframes,a);if(f!==void 0){le.update(()=>{l.onUpdate(f),l.onComplete()});return}}return a.isSync?new Is(l):new _g(l)};function Yi(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Ds(e,t,n,r){if(typeof t=="function"){const[o,s]=Yi(r);t=t(n!==void 0?n:e.custom,o,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[o,s]=Yi(r);t=t(n!==void 0?n:e.custom,o,s)}return t}function Ut(e,t,n){const r=e.getProps();return Ds(r,t,n!==void 0?n:r.custom,e)}const gl=new Set(["width","height","top","left","right","bottom",...qt]),Zi=30,Bg=e=>!isNaN(parseFloat(e));class $g{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var s;const o=Ie.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((s=this.events.change)==null||s.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ie.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=Bg(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&Ss(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new xs);const r=this.events[t].add(n);return t==="change"?()=>{r(),le.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&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=Ie.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Zi)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Zi);return $c(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),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,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Gt(e,t){return new $g(e,t)}const zo=e=>Array.isArray(e);function Ng(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Gt(n))}function Vg(e){return zo(e)?e[e.length-1]||0:e}function Fg(e,t){const n=Ut(e,t);let{transitionEnd:r={},transition:o={},...s}=n||{};s={...s,...r};for(const i in s){const a=Vg(s[i]);Ng(e,i,a)}}const Pe=e=>!!(e&&e.getVelocity);function zg(e){return!!(Pe(e)&&e.add)}function Wo(e,t){const n=e.getValue("willChange");if(zg(n))return n.add(t);if(!n&&ot.WillChange){const r=new ot.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function js(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const Wg="framerAppearId",yl="data-"+js(Wg);function vl(e){return e.props[yl]}function Ug({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function bl(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:i,...a}=t;const c=s==null?void 0:s.reduceMotion;r&&(s=r);const u=[],l=o&&e.animationState&&e.animationState.getState()[o];for(const d in a){const f=e.getValue(d,e.latestValues[d]??null),h=a[d];if(h===void 0||l&&Ug(l,d))continue;const p={delay:n,...Os(s||{},d)},m=f.get();if(m!==void 0&&!f.isAnimating&&!Array.isArray(h)&&h===m&&!p.velocity)continue;let v=!1;if(window.MotionHandoffAnimation){const b=vl(e);if(b){const w=window.MotionHandoffAnimation(b,d,le);w!==null&&(p.startTime=w,v=!0)}}Wo(e,d);const S=c??e.shouldReduceMotion;f.start(Ls(d,f,h,S&&gl.has(d)?{type:!1}:p,e,v));const T=f.animation;T&&u.push(T)}return i&&Promise.all(u).then(()=>{le.update(()=>{i&&Fg(e,i)})}),u}function Uo(e,t,n={}){var c;const r=Ut(e,t,n.type==="exit"?(c=e.presenceContext)==null?void 0:c.custom:void 0);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const s=r?()=>Promise.all(bl(e,r,n)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:l=0,staggerChildren:d,staggerDirection:f}=o;return Hg(e,t,u,l,d,f,n)}:()=>Promise.resolve(),{when:a}=o;if(a){const[u,l]=a==="beforeChildren"?[s,i]:[i,s];return u().then(()=>l())}else return Promise.all([s(),i(n.delay)])}function Hg(e,t,n=0,r=0,o=0,s=1,i){const a=[];for(const c of e.variantChildren)c.notify("AnimationStart",t),a.push(Uo(c,t,{...i,delay:n+(typeof r=="function"?0:r)+ml(e.variantChildren,c,r,o,s)}).then(()=>c.notify("AnimationComplete",t)));return Promise.all(a)}function Gg(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(s=>Uo(e,s,n));r=Promise.all(o)}else if(typeof t=="string")r=Uo(e,t,n);else{const o=typeof t=="function"?Ut(e,t,n.custom):t;r=Promise.all(bl(e,o,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const Kg={test:e=>e==="auto",parse:e=>e},xl=e=>t=>t.test(e),Sl=[Zt,H,Ze,at,bp,vp,Kg],qi=e=>Sl.find(xl(e));function Yg(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Bc(e):!0}const Zg=new Set(["brightness","contrast","saturate","opacity"]);function qg(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(_s)||[];if(!r)return e;const o=n.replace(r,"");let s=Zg.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+o+")"}const Xg=/\b([a-z-]*)\(.*?\)/gu,Ho={...gt,getAnimatableNone:e=>{const t=e.match(Xg);return t?t.map(qg).join(" "):e}},Xi={...Zt,transform:Math.round},Jg={rotate:at,rotateX:at,rotateY:at,rotateZ:at,scale:Vn,scaleX:Vn,scaleY:Vn,scaleZ:Vn,skew:at,skewX:at,skewY:at,distance:H,translateX:H,translateY:H,translateZ:H,x:H,y:H,z:H,perspective:H,transformPerspective:H,opacity:Cn,originX:Bi,originY:Bi,originZ:H},Bs={borderWidth:H,borderTopWidth:H,borderRightWidth:H,borderBottomWidth:H,borderLeftWidth:H,borderRadius:H,borderTopLeftRadius:H,borderTopRightRadius:H,borderBottomRightRadius:H,borderBottomLeftRadius:H,width:H,maxWidth:H,height:H,maxHeight:H,top:H,right:H,bottom:H,left:H,inset:H,insetBlock:H,insetBlockStart:H,insetBlockEnd:H,insetInline:H,insetInlineStart:H,insetInlineEnd:H,padding:H,paddingTop:H,paddingRight:H,paddingBottom:H,paddingLeft:H,paddingBlock:H,paddingBlockStart:H,paddingBlockEnd:H,paddingInline:H,paddingInlineStart:H,paddingInlineEnd:H,margin:H,marginTop:H,marginRight:H,marginBottom:H,marginLeft:H,marginBlock:H,marginBlockStart:H,marginBlockEnd:H,marginInline:H,marginInlineStart:H,marginInlineEnd:H,fontSize:H,backgroundPositionX:H,backgroundPositionY:H,...Jg,zIndex:Xi,fillOpacity:Cn,strokeOpacity:Cn,numOctaves:Xi},Qg={...Bs,color:Se,backgroundColor:Se,outlineColor:Se,fill:Se,stroke:Se,borderColor:Se,borderTopColor:Se,borderRightColor:Se,borderBottomColor:Se,borderLeftColor:Se,filter:Ho,WebkitFilter:Ho},Tl=e=>Qg[e];function Cl(e,t){let n=Tl(e);return n!==Ho&&(n=gt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const e0=new Set(["auto","none","0"]);function t0(e,t,n){let r=0,o;for(;r<e.length&&!o;){const s=e[r];typeof s=="string"&&!e0.has(s)&&wn(s).values.length&&(o=e[r]),r++}if(o&&n)for(const s of t)e[s]=Cl(n,o)}class n0 extends Rs{constructor(t,n,r,o,s){super(t,n,r,o,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let d=t[l];if(typeof d=="string"&&(d=d.trim(),ws(d))){const f=pl(d,n.current);f!==void 0&&(t[l]=f),l===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!gl.has(r)||t.length!==2)return;const[o,s]=t,i=qi(o),a=qi(s),c=ji(o),u=ji(s);if(c!==u&&dt[r]){this.needsMeasurement=!0;return}if(i!==a)if(Hi(i)&&Hi(a))for(let l=0;l<t.length;l++){const d=t[l];typeof d=="string"&&(t[l]=parseFloat(d))}else dt[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let o=0;o<t.length;o++)(t[o]===null||Yg(t[o]))&&r.push(o);r.length&&t0(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=dt[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const o=n[n.length-1];o!==void 0&&t.getValue(r,o).jump(o,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const o=t.getValue(n);o&&o.jump(this.measuredOrigin,!1);const s=r.length-1,i=r[s];r[s]=dt[n](t.measureViewportBox(),window.getComputedStyle(t.current)),i!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=i),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([c,u])=>{t.getValue(c).set(u)}),this.resolveNoneKeyframes()}}function r0(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const o=(n==null?void 0:n[e])??r.querySelectorAll(e);return o?Array.from(o):[]}return Array.from(e).filter(r=>r!=null)}const wl=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Go(e){return jc(e)&&"offsetHeight"in e}const{schedule:$s}=Zc(queueMicrotask,!1),We={x:!1,y:!1};function _l(){return We.x||We.y}function o0(e){return e==="x"||e==="y"?We[e]?null:(We[e]=!0,()=>{We[e]=!1}):We.x||We.y?null:(We.x=We.y=!0,()=>{We.x=We.y=!1})}function El(e,t){const n=r0(e),r=new AbortController,o={passive:!0,...t,signal:r.signal};return[n,o,()=>r.abort()]}function Ji(e){return!(e.pointerType==="touch"||_l())}function s0(e,t,n={}){const[r,o,s]=El(e,n),i=a=>{if(!Ji(a))return;const{target:c}=a,u=t(c,a);if(typeof u!="function"||!c)return;const l=d=>{Ji(d)&&(u(d),c.removeEventListener("pointerleave",l))};c.addEventListener("pointerleave",l,o)};return r.forEach(a=>{a.addEventListener("pointerenter",i,o)}),s}const Al=(e,t)=>t?e===t?!0:Al(e,t.parentElement):!1,Ns=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,i0=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Ml(e){return i0.has(e.tagName)||e.isContentEditable===!0}const Xn=new WeakSet;function Qi(e){return t=>{t.key==="Enter"&&e(t)}}function no(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const a0=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Qi(()=>{if(Xn.has(n))return;no(n,"down");const o=Qi(()=>{no(n,"up")}),s=()=>no(n,"cancel");n.addEventListener("keyup",o,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function ea(e){return Ns(e)&&!_l()}function c0(e,t,n={}){const[r,o,s]=El(e,n),i=a=>{const c=a.currentTarget;if(!ea(a))return;Xn.add(c);const u=t(c,a),l=(h,p)=>{window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",f),Xn.has(c)&&Xn.delete(c),ea(h)&&typeof u=="function"&&u(h,{success:p})},d=h=>{l(h,c===window||c===document||n.useGlobalTarget||Al(c,h.target))},f=h=>{l(h,!1)};window.addEventListener("pointerup",d,o),window.addEventListener("pointercancel",f,o)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",i,o),Go(a)&&(a.addEventListener("focus",u=>a0(u,o)),!Ml(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),s}function Pl(e){return jc(e)&&"ownerSVGElement"in e}function l0(e){return Pl(e)&&e.tagName==="svg"}const u0=[...Sl,Se,gt],d0=e=>u0.find(xl(e)),ta=()=>({translate:0,scale:1,origin:0,originPoint:0}),Nt=()=>({x:ta(),y:ta()}),na=()=>({min:0,max:0}),Ce=()=>({x:na(),y:na()}),Ko={current:null},kl={current:!1},f0=typeof window<"u";function h0(){if(kl.current=!0,!!f0)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ko.current=e.matches;e.addEventListener("change",t),t()}else Ko.current=!1}const m0=new WeakMap;function Rr(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function _n(e){return typeof e=="string"||Array.isArray(e)}const Vs=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Fs=["initial",...Vs];function Or(e){return Rr(e.animate)||Fs.some(t=>_n(e[t]))}function Il(e){return!!(Or(e)||e.variants)}function p0(e,t,n){for(const r in t){const o=t[r],s=n[r];if(Pe(o))e.addValue(r,o);else if(Pe(s))e.addValue(r,Gt(o,{owner:e}));else if(s!==o)if(e.hasValue(r)){const i=e.getValue(r);i.liveStyle===!0?i.jump(o):i.hasAnimated||i.set(o)}else{const i=e.getStaticValue(r);e.addValue(r,Gt(i!==void 0?i:o,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const ra=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let lr={};function Rl(e){lr=e}function g0(){return lr}class y0{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,blockInitialAnimation:s,visualState:i},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Rs,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},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 f=Ie.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,le.render(this.render,!1,!0))};const{latestValues:c,renderState:u}=i;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.blockInitialAnimation=!!s,this.isControllingVariants=Or(n),this.isVariantNode=Il(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in d){const h=d[f];c[f]!==void 0&&Pe(h)&&h.set(c[f])}}mount(t){var n;this.current=t,m0.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,o)=>this.bindToMotionValue(o,r)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(kl.current||h0(),this.shouldReduceMotion=Ko.current),process.env.NODE_ENV!=="production"&&Ss(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),pt(this.notifyUpdate),pt(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];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,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Xt.has(t);r&&this.onBindTransform&&this.onBindTransform();const o=n.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&le.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;typeof window<"u"&&window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{o(),s&&s(),n.owner&&n.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 lr){const n=lr[t];if(!n)continue;const{isEnabled:r,Feature:o}=n;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ce()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<ra.length;r++){const o=ra[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const s="on"+o,i=t[s];i&&(this.propEventSubscriptions[o]=this.on(o,i))}this.prevMotionValues=p0(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Gt(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){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"&&(Dc(r)||Bc(r))?r=parseFloat(r):!d0(r)&&gt.test(n)&&(r=Cl(t,n)),this.setBaseTarget(t,Pe(r)?r.get():r)),Pe(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var s;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const i=Ds(this.props,n,(s=this.presenceContext)==null?void 0:s.custom);i&&(r=i[t])}if(n&&r!==void 0)return r;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Pe(o)?o:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new xs),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){$s.render(this.render)}}class Ol extends y0{constructor(){super(...arguments),this.KeyframeResolver=n0}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Pe(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class vt{constructor(t){this.isMounted=!1,this.node=t}update(){}}function Ll({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function v0({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function b0(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function ro(e){return e===void 0||e===1}function Yo({scale:e,scaleX:t,scaleY:n}){return!ro(e)||!ro(t)||!ro(n)}function _t(e){return Yo(e)||Dl(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Dl(e){return oa(e.x)||oa(e.y)}function oa(e){return e&&e!=="0%"}function ur(e,t,n){const r=e-n,o=t*r;return n+o}function sa(e,t,n,r,o){return o!==void 0&&(e=ur(e,o,r)),ur(e,n,r)+t}function Zo(e,t=0,n=1,r,o){e.min=sa(e.min,t,n,r,o),e.max=sa(e.max,t,n,r,o)}function jl(e,{x:t,y:n}){Zo(e.x,t.translate,t.scale,t.originPoint),Zo(e.y,n.translate,n.scale,n.originPoint)}const ia=.999999999999,aa=1.0000000000001;function x0(e,t,n,r=!1){const o=n.length;if(!o)return;t.x=t.y=1;let s,i;for(let a=0;a<o;a++){s=n[a],i=s.projectionDelta;const{visualElement:c}=s.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Ft(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),i&&(t.x*=i.x.scale,t.y*=i.y.scale,jl(e,i)),r&&_t(s.latestValues)&&Ft(e,s.latestValues))}t.x<aa&&t.x>ia&&(t.x=1),t.y<aa&&t.y>ia&&(t.y=1)}function Vt(e,t){e.min=e.min+t,e.max=e.max+t}function ca(e,t,n,r,o=.5){const s=he(e.min,e.max,o);Zo(e,t,n,s,r)}function Ft(e,t){ca(e.x,t.x,t.scaleX,t.scale,t.originX),ca(e.y,t.y,t.scaleY,t.scale,t.originY)}function Bl(e,t){return Ll(b0(e.getBoundingClientRect(),t))}function S0(e,t,n){const r=Bl(e,n),{scroll:o}=t;return o&&(Vt(r.x,o.offset.x),Vt(r.y,o.offset.y)),r}const T0={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},C0=qt.length;function w0(e,t,n){let r="",o=!0;for(let s=0;s<C0;s++){const i=qt[s],a=e[i];if(a===void 0)continue;let c=!0;if(typeof a=="number")c=a===(i.startsWith("scale")?1:0);else{const u=parseFloat(a);c=i.startsWith("scale")?u===1:u===0}if(!c||n){const u=wl(a,Bs[i]);if(!c){o=!1;const l=T0[i]||i;r+=`${l}(${u}) `}n&&(t[i]=u)}}return r=r.trim(),n?r=n(t,o?"":r):o&&(r="none"),r}function zs(e,t,n){const{style:r,vars:o,transformOrigin:s}=e;let i=!1,a=!1;for(const c in t){const u=t[c];if(Xt.has(c)){i=!0;continue}else if(Xc(c)){o[c]=u;continue}else{const l=wl(u,Bs[c]);c.startsWith("origin")?(a=!0,s[c]=l):r[c]=l}}if(t.transform||(i||n?r.transform=w0(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:c="50%",originY:u="50%",originZ:l=0}=s;r.transformOrigin=`${c} ${u} ${l}`}}function $l(e,{style:t,vars:n},r,o){const s=e.style;let i;for(i in t)s[i]=t[i];o==null||o.applyProjectionStyles(s,r);for(i in n)s.setProperty(i,n[i])}function la(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const an={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(H.test(e))e=parseFloat(e);else return e;const n=la(e,t.target.x),r=la(e,t.target.y);return`${n}% ${r}%`}},_0={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=gt.parse(e);if(o.length>5)return r;const s=gt.createTransformer(e),i=typeof o[0]!="number"?1:0,a=n.x.scale*t.x,c=n.y.scale*t.y;o[0+i]/=a,o[1+i]/=c;const u=he(a,c,.5);return typeof o[2+i]=="number"&&(o[2+i]/=u),typeof o[3+i]=="number"&&(o[3+i]/=u),s(o)}},qo={borderRadius:{...an,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:an,borderTopRightRadius:an,borderBottomLeftRadius:an,borderBottomRightRadius:an,boxShadow:_0};function Nl(e,{layout:t,layoutId:n}){return Xt.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!qo[e]||e==="opacity")}function Ws(e,t,n){var i;const r=e.style,o=t==null?void 0:t.style,s={};if(!r)return s;for(const a in r)(Pe(r[a])||o&&Pe(o[a])||Nl(a,e)||((i=n==null?void 0:n.getValue(a))==null?void 0:i.liveStyle)!==void 0)&&(s[a]=r[a]);return s}function E0(e){return window.getComputedStyle(e)}class A0 extends Ol{constructor(){super(...arguments),this.type="html",this.renderInstance=$l}readValueFromInstance(t,n){var r;if(Xt.has(n))return(r=this.projection)!=null&&r.isProjecting?jo(n):ng(t,n);{const o=E0(t),s=(Xc(n)?o.getPropertyValue(n):o[n])||0;return typeof s=="string"?s.trim():s}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Bl(t,n)}build(t,n,r){zs(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Ws(t,n,r)}}const M0={offset:"stroke-dashoffset",array:"stroke-dasharray"},P0={offset:"strokeDashoffset",array:"strokeDasharray"};function k0(e,t,n=1,r=0,o=!0){e.pathLength=1;const s=o?M0:P0;e[s.offset]=`${-r}`,e[s.array]=`${t} ${n}`}const I0=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Vl(e,{attrX:t,attrY:n,attrScale:r,pathLength:o,pathSpacing:s=1,pathOffset:i=0,...a},c,u,l){if(zs(e,a,u),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:d,style:f}=e;d.transform&&(f.transform=d.transform,delete d.transform),(f.transform||d.transformOrigin)&&(f.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),f.transform&&(f.transformBox=(l==null?void 0:l.transformBox)??"fill-box",delete d.transformBox);for(const h of I0)d[h]!==void 0&&(f[h]=d[h],delete d[h]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),o!==void 0&&k0(d,o,s,i,!1)}const Fl=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"]),zl=e=>typeof e=="string"&&e.toLowerCase()==="svg";function R0(e,t,n,r){$l(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(Fl.has(o)?o:js(o),t.attrs[o])}function Wl(e,t,n){const r=Ws(e,t,n);for(const o in e)if(Pe(e[o])||Pe(t[o])){const s=qt.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[s]=e[o]}return r}class O0 extends Ol{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ce}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Xt.has(n)){const r=Tl(n);return r&&r.default||0}return n=Fl.has(n)?n:js(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Wl(t,n,r)}build(t,n,r){Vl(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,o){R0(t,n,r,o)}mount(t){this.isSVGTag=zl(t.tagName),super.mount(t)}}const L0=Fs.length;function Ul(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Ul(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<L0;n++){const r=Fs[n],o=e.props[r];(_n(o)||o===!1)&&(t[r]=o)}return t}function Hl(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const D0=[...Vs].reverse(),j0=Vs.length;function B0(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Gg(e,n,r)))}function $0(e){let t=B0(e),n=ua(),r=!0;const o=c=>(u,l)=>{var f;const d=Ut(e,l,c==="exit"?(f=e.presenceContext)==null?void 0:f.custom:void 0);if(d){const{transition:h,transitionEnd:p,...m}=d;u={...u,...m,...p}}return u};function s(c){t=c(e)}function i(c){const{props:u}=e,l=Ul(e.parent)||{},d=[],f=new Set;let h={},p=1/0;for(let v=0;v<j0;v++){const S=D0[v],T=n[S],b=u[S]!==void 0?u[S]:l[S],w=_n(b),C=S===c?T.isActive:null;C===!1&&(p=v);let E=b===l[S]&&b!==u[S]&&w;if(E&&r&&e.manuallyAnimateOnMount&&(E=!1),T.protectedKeys={...h},!T.isActive&&C===null||!b&&!T.prevProp||Rr(b)||typeof b=="boolean")continue;const P=N0(T.prevProp,b);let M=P||S===c&&T.isActive&&!E&&w||v>p&&w,I=!1;const V=Array.isArray(b)?b:[b];let D=V.reduce(o(S),{});C===!1&&(D={});const{prevResolvedValues:g={}}=T,$={...g,...D},R=G=>{M=!0,f.has(G)&&(I=!0,f.delete(G)),T.needsAnimating[G]=!0;const j=e.getValue(G);j&&(j.liveStyle=!1)};for(const G in $){const j=D[G],Q=g[G];if(h.hasOwnProperty(G))continue;let L=!1;zo(j)&&zo(Q)?L=!Hl(j,Q):L=j!==Q,L?j!=null?R(G):f.add(G):j!==void 0&&f.has(G)?R(G):T.protectedKeys[G]=!0}T.prevProp=b,T.prevResolvedValues=D,T.isActive&&(h={...h,...D}),r&&e.blockInitialAnimation&&(M=!1);const W=E&&P;M&&(!W||I)&&d.push(...V.map(G=>{const j={type:S};if(typeof G=="string"&&r&&!W&&e.manuallyAnimateOnMount&&e.parent){const{parent:Q}=e,L=Ut(Q,G);if(Q.enteringChildren&&L){const{delayChildren:_}=L.transition||{};j.delay=ml(Q.enteringChildren,e,_)}}return{animation:G,options:j}}))}if(f.size){const v={};if(typeof u.initial!="boolean"){const S=Ut(e,Array.isArray(u.initial)?u.initial[0]:u.initial);S&&S.transition&&(v.transition=S.transition)}f.forEach(S=>{const T=e.getBaseTarget(S),b=e.getValue(S);b&&(b.liveStyle=!0),v[S]=T??null}),d.push({animation:v})}let m=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(m=!1),r=!1,m?t(d):Promise.resolve()}function a(c,u){var d;if(n[c].isActive===u)return Promise.resolve();(d=e.variantChildren)==null||d.forEach(f=>{var h;return(h=f.animationState)==null?void 0:h.setActive(c,u)}),n[c].isActive=u;const l=i(c);for(const f in n)n[f].protectedKeys={};return l}return{animateChanges:i,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=ua()}}}function N0(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Hl(t,e):!1}function xt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function ua(){return{animate:xt(!0),whileInView:xt(),whileHover:xt(),whileTap:xt(),whileDrag:xt(),whileFocus:xt(),exit:xt()}}function da(e,t){e.min=t.min,e.max=t.max}function ze(e,t){da(e.x,t.x),da(e.y,t.y)}function fa(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const Gl=1e-4,V0=1-Gl,F0=1+Gl,Kl=.01,z0=0-Kl,W0=0+Kl;function Re(e){return e.max-e.min}function U0(e,t,n){return Math.abs(e-t)<=n}function ha(e,t,n,r=.5){e.origin=r,e.originPoint=he(t.min,t.max,e.origin),e.scale=Re(n)/Re(t),e.translate=he(n.min,n.max,e.origin)-e.originPoint,(e.scale>=V0&&e.scale<=F0||isNaN(e.scale))&&(e.scale=1),(e.translate>=z0&&e.translate<=W0||isNaN(e.translate))&&(e.translate=0)}function bn(e,t,n,r){ha(e.x,t.x,n.x,r?r.originX:void 0),ha(e.y,t.y,n.y,r?r.originY:void 0)}function ma(e,t,n){e.min=n.min+t.min,e.max=e.min+Re(t)}function H0(e,t,n){ma(e.x,t.x,n.x),ma(e.y,t.y,n.y)}function pa(e,t,n){e.min=t.min-n.min,e.max=e.min+Re(t)}function dr(e,t,n){pa(e.x,t.x,n.x),pa(e.y,t.y,n.y)}function ga(e,t,n,r,o){return e-=t,e=ur(e,1/n,r),o!==void 0&&(e=ur(e,1/o,r)),e}function G0(e,t=0,n=1,r=.5,o,s=e,i=e){if(Ze.test(t)&&(t=parseFloat(t),t=he(i.min,i.max,t/100)-i.min),typeof t!="number")return;let a=he(s.min,s.max,r);e===s&&(a-=t),e.min=ga(e.min,t,n,a,o),e.max=ga(e.max,t,n,a,o)}function ya(e,t,[n,r,o],s,i){G0(e,t[n],t[r],t[o],t.scale,s,i)}const K0=["x","scaleX","originX"],Y0=["y","scaleY","originY"];function va(e,t,n,r){ya(e.x,t,K0,n?n.x:void 0,r?r.x:void 0),ya(e.y,t,Y0,n?n.y:void 0,r?r.y:void 0)}function ba(e){return e.translate===0&&e.scale===1}function Yl(e){return ba(e.x)&&ba(e.y)}function xa(e,t){return e.min===t.min&&e.max===t.max}function Z0(e,t){return xa(e.x,t.x)&&xa(e.y,t.y)}function Sa(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Zl(e,t){return Sa(e.x,t.x)&&Sa(e.y,t.y)}function Ta(e){return Re(e.x)/Re(e.y)}function Ca(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function je(e){return[e("x"),e("y")]}function q0(e,t,n){let r="";const o=e.x.translate/t.x,s=e.y.translate/t.y,i=(n==null?void 0:n.z)||0;if((o||s||i)&&(r=`translate3d(${o}px, ${s}px, ${i}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:l,rotateX:d,rotateY:f,skewX:h,skewY:p}=n;u&&(r=`perspective(${u}px) ${r}`),l&&(r+=`rotate(${l}deg) `),d&&(r+=`rotateX(${d}deg) `),f&&(r+=`rotateY(${f}deg) `),h&&(r+=`skewX(${h}deg) `),p&&(r+=`skewY(${p}deg) `)}const a=e.x.scale*t.x,c=e.y.scale*t.y;return(a!==1||c!==1)&&(r+=`scale(${a}, ${c})`),r||"none"}const ql=["TopLeft","TopRight","BottomLeft","BottomRight"],X0=ql.length,wa=e=>typeof e=="string"?parseFloat(e):e,_a=e=>typeof e=="number"||H.test(e);function J0(e,t,n,r,o,s){o?(e.opacity=he(0,n.opacity??1,Q0(r)),e.opacityExit=he(t.opacity??1,0,ey(r))):s&&(e.opacity=he(t.opacity??1,n.opacity??1,r));for(let i=0;i<X0;i++){const a=`border${ql[i]}Radius`;let c=Ea(t,a),u=Ea(n,a);if(c===void 0&&u===void 0)continue;c||(c=0),u||(u=0),c===0||u===0||_a(c)===_a(u)?(e[a]=Math.max(he(wa(c),wa(u),r),0),(Ze.test(u)||Ze.test(c))&&(e[a]+="%")):e[a]=u}(t.rotate||n.rotate)&&(e.rotate=he(t.rotate||0,n.rotate||0,r))}function Ea(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Q0=Xl(0,.5,Hc),ey=Xl(.5,.95,Ne);function Xl(e,t,n){return r=>r<e?0:r>t?1:n(Tn(e,t,r))}function ty(e,t,n){const r=Pe(e)?e:Gt(e);return r.start(Ls("",r,t,n)),r.animation}function En(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const ny=(e,t)=>e.depth-t.depth;class ry{constructor(){this.children=[],this.isDirty=!1}add(t){ys(this.children,t),this.isDirty=!0}remove(t){vs(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(ny),this.isDirty=!1,this.children.forEach(t)}}function oy(e,t){const n=Ie.now(),r=({timestamp:o})=>{const s=o-n;s>=t&&(pt(r),e(s-t))};return le.setup(r,!0),()=>pt(r)}function Jn(e){return Pe(e)?e.get():e}class sy{constructor(){this.members=[]}add(t){ys(this.members,t),t.scheduleRender()}remove(t){if(vs(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return!1;let r;for(let o=n;o>=0;o--){const s=this.members[o];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender();const o=r.options.layoutDependency,s=t.options.layoutDependency;o!==void 0&&s!==void 0&&o===s||(t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0));const{crossfade:a}=t.options;a===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const Qn={hasAnimatedSinceResize:!0,hasEverUpdated:!1},oo=["","X","Y","Z"],iy=1e3;let ay=0;function so(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Jl(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=vl(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:o,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",le,!(o||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Jl(r)}function Ql({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(i={},a=t==null?void 0:t()){this.id=ay++,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(uy),this.nodes.forEach(my),this.nodes.forEach(py),this.nodes.forEach(dy)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=i,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new ry)}addEventListener(i,a){return this.eventHandlers.has(i)||this.eventHandlers.set(i,new xs),this.eventHandlers.get(i).add(a)}notifyListeners(i,...a){const c=this.eventHandlers.get(i);c&&c.notify(...a)}hasListeners(i){return this.eventHandlers.has(i)}mount(i){if(this.instance)return;this.isSVG=Pl(i)&&!l0(i),this.instance=i;const{layoutId:a,layout:c,visualElement:u}=this.options;if(u&&!u.current&&u.mount(i),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(c||a)&&(this.isLayoutDirty=!0),e){let l,d=0;const f=()=>this.root.updateBlockedByResize=!1;le.read(()=>{d=window.innerWidth}),e(i,()=>{const h=window.innerWidth;h!==d&&(d=h,this.root.updateBlockedByResize=!0,l&&l(),l=oy(f,250),Qn.hasAnimatedSinceResize&&(Qn.hasAnimatedSinceResize=!1,this.nodes.forEach(Pa)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||c)&&this.addEventListener("didUpdate",({delta:l,hasLayoutChanged:d,hasRelativeLayoutChanged:f,layout:h})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const p=this.options.transition||u.getDefaultTransition()||xy,{onLayoutAnimationStart:m,onLayoutAnimationComplete:v}=u.getProps(),S=!this.targetLayout||!Zl(this.targetLayout,h),T=!d&&f;if(this.options.layoutRoot||this.resumeFrom||T||d&&(S||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const b={...Os(p,"layout"),onPlay:m,onComplete:v};(u.shouldReduceMotion||this.options.layoutRoot)&&(b.delay=0,b.type=!1),this.startAnimation(b),this.setAnimationOrigin(l,T)}else d||Pa(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const i=this.getStack();i&&i.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),pt(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(gy),this.animationId++)}getTransformTemplate(){const{visualElement:i}=this.options;return i&&i.getProps().transformTemplate}willUpdate(i=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Jl(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let l=0;l<this.path.length;l++){const d=this.path[l];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:a,layout:c}=this.options;if(a===void 0&&!c)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),i&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Aa);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Ma);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(hy),this.nodes.forEach(cy),this.nodes.forEach(ly)):this.nodes.forEach(Ma),this.clearAllSnapshots();const a=Ie.now();Me.delta=qe(0,1e3/60,a-Me.timestamp),Me.timestamp=a,Me.isProcessing=!0,qr.update.process(Me),qr.preRender.process(Me),qr.render.process(Me),Me.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,$s.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(fy),this.sharedNodes.forEach(yy)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,le.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){le.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Re(this.snapshot.measuredBox.x)&&!Re(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 c=0;c<this.path.length;c++)this.path[c].updateScroll();const i=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=Ce(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,i?i.layoutBox:void 0)}updateScroll(i="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===i&&(a=!1),a&&this.instance){const c=r(this.instance);this.scroll={animationId:this.root.animationId,phase:i,isRoot:c,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:c}}}resetTransform(){if(!o)return;const i=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!Yl(this.projectionDelta),c=this.getTransformTemplate(),u=c?c(this.latestValues,""):void 0,l=u!==this.prevTransformTemplateValue;i&&this.instance&&(a||_t(this.latestValues)||l)&&(o(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(i=!0){const a=this.measurePageBox();let c=this.removeElementScroll(a);return i&&(c=this.removeTransform(c)),Sy(c),{animationId:this.root.animationId,measuredBox:a,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:i}=this.options;if(!i)return Ce();const a=i.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(Ty))){const{scroll:l}=this.root;l&&(Vt(a.x,l.offset.x),Vt(a.y,l.offset.y))}return a}removeElementScroll(i){var c;const a=Ce();if(ze(a,i),(c=this.scroll)!=null&&c.wasRoot)return a;for(let u=0;u<this.path.length;u++){const l=this.path[u],{scroll:d,options:f}=l;l!==this.root&&d&&f.layoutScroll&&(d.wasRoot&&ze(a,i),Vt(a.x,d.offset.x),Vt(a.y,d.offset.y))}return a}applyTransform(i,a=!1){const c=Ce();ze(c,i);for(let u=0;u<this.path.length;u++){const l=this.path[u];!a&&l.options.layoutScroll&&l.scroll&&l!==l.root&&Ft(c,{x:-l.scroll.offset.x,y:-l.scroll.offset.y}),_t(l.latestValues)&&Ft(c,l.latestValues)}return _t(this.latestValues)&&Ft(c,this.latestValues),c}removeTransform(i){const a=Ce();ze(a,i);for(let c=0;c<this.path.length;c++){const u=this.path[c];if(!u.instance||!_t(u.latestValues))continue;Yo(u.latestValues)&&u.updateSnapshot();const l=Ce(),d=u.measurePageBox();ze(l,d),va(a,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,l)}return _t(this.latestValues)&&va(a,this.latestValues),a}setTargetDelta(i){this.targetDelta=i,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(i){this.options={...this.options,...i,crossfade:i.crossfade!==void 0?i.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Me.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(i=!1){var h;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const c=!!this.resumingFrom||this!==a;if(!(i||c&&this.isSharedProjectionDirty||this.isProjectionDirty||(h=this.parent)!=null&&h.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:l,layoutId:d}=this.options;if(!this.layout||!(l||d))return;this.resolvedRelativeTargetAt=Me.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Ce(),this.targetWithTransforms=Ce()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),H0(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):ze(this.target,this.layout.layoutBox),jl(this.target,this.targetDelta)):ze(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Yo(this.parent.latestValues)||Dl(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(i,a,c){this.relativeParent=i,this.linkedParentVersion=i.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ce(),this.relativeTargetOrigin=Ce(),dr(this.relativeTargetOrigin,a,c),ze(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var p;const i=this.getLead(),a=!!this.resumingFrom||this!==i;let c=!0;if((this.isProjectionDirty||(p=this.parent)!=null&&p.isProjectionDirty)&&(c=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===Me.timestamp&&(c=!1),c)return;const{layout:u,layoutId:l}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||l))return;ze(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,f=this.treeScale.y;x0(this.layoutCorrected,this.treeScale,this.path,a),i.layout&&!i.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(i.target=i.layout.layoutBox,i.targetWithTransforms=Ce());const{target:h}=i;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(fa(this.prevProjectionDelta.x,this.projectionDelta.x),fa(this.prevProjectionDelta.y,this.projectionDelta.y)),bn(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==f||!Ca(this.projectionDelta.x,this.prevProjectionDelta.x)||!Ca(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(i=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),i){const c=this.getStack();c&&c.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Nt(),this.projectionDelta=Nt(),this.projectionDeltaWithTransform=Nt()}setAnimationOrigin(i,a=!1){const c=this.snapshot,u=c?c.latestValues:{},l={...this.latestValues},d=Nt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const f=Ce(),h=c?c.source:void 0,p=this.layout?this.layout.source:void 0,m=h!==p,v=this.getStack(),S=!v||v.members.length<=1,T=!!(m&&!S&&this.options.crossfade===!0&&!this.path.some(by));this.animationProgress=0;let b;this.mixTargetDelta=w=>{const C=w/1e3;ka(d.x,i.x,C),ka(d.y,i.y,C),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(dr(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),vy(this.relativeTarget,this.relativeTargetOrigin,f,C),b&&Z0(this.relativeTarget,b)&&(this.isProjectionDirty=!1),b||(b=Ce()),ze(b,this.relativeTarget)),m&&(this.animationValues=l,J0(l,u,this.latestValues,C,T,S)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=C},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(i){var a,c,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(c=this.resumingFrom)==null?void 0:c.currentAnimation)==null||u.stop(),this.pendingAnimation&&(pt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=le.update(()=>{Qn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Gt(0)),this.currentAnimation=ty(this.motionValue,[0,1e3],{...i,velocity:0,isSync:!0,onUpdate:l=>{this.mixTargetDelta(l),i.onUpdate&&i.onUpdate(l)},onStop:()=>{},onComplete:()=>{i.onComplete&&i.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 i=this.getStack();i&&i.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(iy),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const i=this.getLead();let{targetWithTransforms:a,target:c,layout:u,latestValues:l}=i;if(!(!a||!c||!u)){if(this!==i&&this.layout&&u&&eu(this.options.animationType,this.layout.layoutBox,u.layoutBox)){c=this.target||Ce();const d=Re(this.layout.layoutBox.x);c.x.min=i.target.x.min,c.x.max=c.x.min+d;const f=Re(this.layout.layoutBox.y);c.y.min=i.target.y.min,c.y.max=c.y.min+f}ze(a,c),Ft(a,l),bn(this.projectionDeltaWithTransform,this.layoutCorrected,a,l)}}registerSharedNode(i,a){this.sharedNodes.has(i)||this.sharedNodes.set(i,new sy),this.sharedNodes.get(i).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const i=this.getStack();return i?i.lead===this:!0}getLead(){var a;const{layoutId:i}=this.options;return i?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:i}=this.options;return i?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:i}=this.options;if(i)return this.root.sharedNodes.get(i)}promote({needsReset:i,transition:a,preserveFollowOpacity:c}={}){const u=this.getStack();u&&u.promote(this,c),i&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const i=this.getStack();return i?i.relegate(this):!1}resetSkewAndRotation(){const{visualElement:i}=this.options;if(!i)return;let a=!1;const{latestValues:c}=i;if((c.z||c.rotate||c.rotateX||c.rotateY||c.rotateZ||c.skewX||c.skewY)&&(a=!0),!a)return;const u={};c.z&&so("z",i,u,this.animationValues);for(let l=0;l<oo.length;l++)so(`rotate${oo[l]}`,i,u,this.animationValues),so(`skew${oo[l]}`,i,u,this.animationValues);i.render();for(const l in u)i.setStaticValue(l,u[l]),this.animationValues&&(this.animationValues[l]=u[l]);i.scheduleRender()}applyProjectionStyles(i,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){i.visibility="hidden";return}const c=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,i.visibility="",i.opacity="",i.pointerEvents=Jn(a==null?void 0:a.pointerEvents)||"",i.transform=c?c(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(i.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,i.pointerEvents=Jn(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!_t(this.latestValues)&&(i.transform=c?c({},""):"none",this.hasProjected=!1);return}i.visibility="";const l=u.animationValues||u.latestValues;this.applyTransformsToTarget();let d=q0(this.projectionDeltaWithTransform,this.treeScale,l);c&&(d=c(l,d)),i.transform=d;const{x:f,y:h}=this.projectionDelta;i.transformOrigin=`${f.origin*100}% ${h.origin*100}% 0`,u.animationValues?i.opacity=u===this?l.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:i.opacity=u===this?l.opacity!==void 0?l.opacity:"":l.opacityExit!==void 0?l.opacityExit:0;for(const p in qo){if(l[p]===void 0)continue;const{correct:m,applyTo:v,isCSSVariable:S}=qo[p],T=d==="none"?l[p]:m(l[p],u);if(v){const b=v.length;for(let w=0;w<b;w++)i[v[w]]=T}else S?this.options.visualElement.renderState.vars[p]=T:i[p]=T}this.options.layoutId&&(i.pointerEvents=u===this?Jn(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(i=>{var a;return(a=i.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Aa),this.root.sharedNodes.clear()}}}function cy(e){e.updateLayout()}function ly(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=e.layout,{animationType:s}=e.options,i=t.source!==e.layout.source;s==="size"?je(d=>{const f=i?t.measuredBox[d]:t.layoutBox[d],h=Re(f);f.min=r[d].min,f.max=f.min+h}):eu(s,t.layoutBox,r)&&je(d=>{const f=i?t.measuredBox[d]:t.layoutBox[d],h=Re(r[d]);f.max=f.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+h)});const a=Nt();bn(a,r,t.layoutBox);const c=Nt();i?bn(c,e.applyTransform(o,!0),t.measuredBox):bn(c,r,t.layoutBox);const u=!Yl(a);let l=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:h}=d;if(f&&h){const p=Ce();dr(p,t.layoutBox,f.layoutBox);const m=Ce();dr(m,r,h.layoutBox),Zl(p,m)||(l=!0),d.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=p,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:c,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:l})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function uy(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function dy(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function fy(e){e.clearSnapshot()}function Aa(e){e.clearMeasurements()}function Ma(e){e.isLayoutDirty=!1}function hy(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Pa(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function my(e){e.resolveTargetDelta()}function py(e){e.calcProjection()}function gy(e){e.resetSkewAndRotation()}function yy(e){e.removeLeadSnapshot()}function ka(e,t,n){e.translate=he(t.translate,0,n),e.scale=he(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Ia(e,t,n,r){e.min=he(t.min,n.min,r),e.max=he(t.max,n.max,r)}function vy(e,t,n,r){Ia(e.x,t.x,n.x,r),Ia(e.y,t.y,n.y,r)}function by(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const xy={duration:.45,ease:[.4,0,.1,1]},Ra=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Oa=Ra("applewebkit/")&&!Ra("chrome/")?Math.round:Ne;function La(e){e.min=Oa(e.min),e.max=Oa(e.max)}function Sy(e){La(e.x),La(e.y)}function eu(e,t,n){return e==="position"||e==="preserve-aspect"&&!U0(Ta(t),Ta(n),.2)}function Ty(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const Cy=Ql({attachResizeListener:(e,t)=>En(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),io={current:void 0},tu=Ql({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!io.current){const e=new Cy({});e.mount(window),e.setOptions({layoutScroll:!0}),io.current=e}return io.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Us=x.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Da(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function wy(...e){return t=>{let n=!1;const r=e.map(o=>{const s=Da(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():Da(e[o],null)}}}}function _y(...e){return Ve.useCallback(wy(...e),e)}class Ey extends Ve.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,o=Go(r)&&r.offsetWidth||0,s=Go(r)&&r.offsetHeight||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=o-i.width-i.left,i.bottom=s-i.height-i.top}return null}componentDidUpdate(){}render(){return this.props.children}}function Ay({children:e,isPresent:t,anchorX:n,anchorY:r,root:o}){var d;const s=x.useId(),i=x.useRef(null),a=x.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:c}=x.useContext(Us),u=((d=e.props)==null?void 0:d.ref)??(e==null?void 0:e.ref),l=_y(i,u);return x.useInsertionEffect(()=>{const{width:f,height:h,top:p,left:m,right:v,bottom:S}=a.current;if(t||!i.current||!f||!h)return;const T=n==="left"?`left: ${m}`:`right: ${v}`,b=r==="bottom"?`bottom: ${S}`:`top: ${p}`;i.current.dataset.motionPopId=s;const w=document.createElement("style");c&&(w.nonce=c);const C=o??document.head;return C.appendChild(w),w.sheet&&w.sheet.insertRule(`
91
96
  [data-motion-pop-id="${s}"] {
92
97
  position: absolute !important;
93
98
  width: ${f}px !important;
94
- height: ${p}px !important;
95
- ${S}px !important;
96
- ${y}px !important;
99
+ height: ${h}px !important;
100
+ ${T}px !important;
101
+ ${b}px !important;
97
102
  }
98
- `),()=>{T.contains(C)&&T.removeChild(C)}},[t]),g.jsx(B1,{isPresent:t,childRef:i,sizeRef:a,children:Fe.cloneElement(e,{ref:l})})}const z1=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:o,presenceAffectsLayout:s,mode:i,anchorX:a,anchorY:c,root:u})=>{const l=Es(W1),d=x.useId();let f=!0,p=x.useMemo(()=>(f=!1,{id:d,initial:t,isPresent:n,custom:o,onExitComplete:m=>{l.set(m,!0);for(const h of l.values())if(!h)return;r&&r()},register:m=>(l.set(m,!1),()=>l.delete(m))}),[n,l,r]);return s&&f&&(p={...p}),x.useMemo(()=>{l.forEach((m,h)=>l.set(h,!1))},[n]),Fe.useEffect(()=>{!n&&!l.size&&r&&r()},[n]),i==="popLayout"&&(e=g.jsx(F1,{isPresent:n,anchorX:a,anchorY:c,root:u,children:e})),g.jsx(Hr.Provider,{value:p,children:e})};function W1(){return new Map}function Iu(e=!0){const t=x.useContext(Hr);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=t,s=x.useId();x.useEffect(()=>{if(e)return o(s)},[e]);const i=x.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,i]:[!0]}const tr=e=>e.key||"";function Za(e){const t=[];return x.Children.forEach(e,n=>{x.isValidElement(n)&&t.push(n)}),t}const U1=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:s="sync",propagate:i=!1,anchorX:a="left",anchorY:c="top",root:u})=>{const[l,d]=Iu(i),f=x.useMemo(()=>Za(e),[e]),p=i&&!l?[]:f.map(tr),m=x.useRef(!0),h=x.useRef(f),v=Es(()=>new Map),b=x.useRef(new Set),[S,y]=x.useState(f),[C,T]=x.useState(f);dl(()=>{m.current=!1,h.current=f;for(let A=0;A<C.length;A++){const M=tr(C[A]);p.includes(M)?(v.delete(M),b.current.delete(M)):v.get(M)!==!0&&v.set(M,!1)}},[C,p.length,p.join("-")]);const E=[];if(f!==S){let A=[...f];for(let M=0;M<C.length;M++){const L=C[M],$=tr(L);p.includes($)||(A.splice(M,0,L),E.push(L))}return s==="wait"&&E.length&&(A=E),T(Za(A)),y(f),null}process.env.NODE_ENV!=="production"&&s==="wait"&&C.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=x.useContext(_s);return g.jsx(g.Fragment,{children:C.map(A=>{const M=tr(A),L=i&&!l?!1:f===C||p.includes(M),$=()=>{if(b.current.has(M))return;if(b.current.add(M),v.has(M))v.set(M,!0);else return;let W=!0;v.forEach(H=>{H||(W=!1)}),W&&(P==null||P(),T(h.current),i&&(d==null||d()),r&&r())};return g.jsx(z1,{isPresent:L,initial:!m.current||n?void 0:!1,custom:t,presenceAffectsLayout:o,mode:s,root:u,onExitComplete:L?void 0:$,anchorX:a,anchorY:c,children:A},M)})})},ju=x.createContext({strict:!1}),Xa={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 Ja=!1;function H1(){if(Ja)return;const e={};for(const t in Xa)e[t]={isEnabled:n=>Xa[t].some(r=>!!n[r])};lu(e),Ja=!0}function Lu(){return H1(),kv()}function G1(e){const t=Lu();for(const n in e)t[n]={...t[n],...e[n]};lu(t)}const K1=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","ignoreStrict","viewport"]);function Pr(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||K1.has(e)}let Du=e=>!Pr(e);function Y1(e){typeof e=="function"&&(Du=t=>t.startsWith("on")?!Pr(t):e(t))}try{Y1(require("@emotion/is-prop-valid").default)}catch{}function q1(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(Du(o)||n===!0&&Pr(o)||!t&&!Pr(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}const Yr=x.createContext({});function Z1(e,t){if(Kr(e)){const{initial:n,animate:r}=e;return{initial:n===!1||On(n)?n:void 0,animate:On(r)?r:void 0}}return e.inherit!==!1?t:{}}function X1(e){const{initial:t,animate:n}=Z1(e,x.useContext(Yr));return x.useMemo(()=>({initial:t,animate:n}),[Qa(t),Qa(n)])}function Qa(e){return Array.isArray(e)?e.join(" "):e}const ti=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function $u(e,t,n){for(const r in t)!Oe(t[r])&&!gu(r,n)&&(e[r]=t[r])}function J1({transformTemplate:e},t){return x.useMemo(()=>{const n=ti();return Js(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Q1(e,t){const n=e.style||{},r={};return $u(r,n,e),Object.assign(r,J1(e,t)),r}function eb(e,t){const n={},r=Q1(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Vu=()=>({...ti(),attrs:{}});function tb(e,t,n,r){const o=x.useMemo(()=>{const s=Vu();return yu(s,t,bu(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};$u(s,e.style,e),o.style={...s,...o.style}}return o}const nb=["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 ni(e){return typeof e!="string"||e.includes("-")?!1:!!(nb.indexOf(e)>-1||/[A-Z]/u.test(e))}function rb(e,t,n,{latestValues:r},o,s=!1,i){const c=(i??ni(e)?tb:eb)(t,r,o,e),u=q1(t,typeof e=="string",s),l=e!==x.Fragment?{...u,...c,ref:n}:{},{children:d}=t,f=x.useMemo(()=>Oe(d)?d.get():d,[d]);return x.createElement(e,{...l,children:f})}function ob({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,o){return{latestValues:sb(n,r,o,e),renderState:t()}}function sb(e,t,n,r){const o={},s=r(e,{});for(const f in s)o[f]=fr(s[f]);let{initial:i,animate:a}=e;const c=Kr(e),u=cu(e);t&&u&&!c&&e.inherit!==!1&&(i===void 0&&(i=t.initial),a===void 0&&(a=t.animate));let l=n?n.initial===!1:!1;l=l||i===!1;const d=l?a:i;if(d&&typeof d!="boolean"&&!Gr(d)){const f=Array.isArray(d)?d:[d];for(let p=0;p<f.length;p++){const m=Hs(e,f[p]);if(m){const{transitionEnd:h,transition:v,...b}=m;for(const S in b){let y=b[S];if(Array.isArray(y)){const C=l?y.length-1:0;y=y[C]}y!==null&&(o[S]=y)}for(const S in h)o[S]=h[S]}}}return o}const Nu=e=>(t,n)=>{const r=x.useContext(Yr),o=x.useContext(Hr),s=()=>ob(e,t,r,o);return n?s():Es(s)},ib=Nu({scrapeMotionValuesFromProps:Qs,createRenderState:ti}),ab=Nu({scrapeMotionValuesFromProps:xu,createRenderState:Vu}),cb=Symbol.for("motionComponentSymbol");function lb(e,t,n){const r=x.useRef(n);x.useInsertionEffect(()=>{r.current=n});const o=x.useRef(null);return x.useCallback(s=>{var a;s&&((a=e.onMount)==null||a.call(e,s)),t&&(s?t.mount(s):t.unmount());const i=r.current;if(typeof i=="function")if(s){const c=i(s);typeof c=="function"&&(o.current=c)}else o.current?(o.current(),o.current=null):i(s);else i&&(i.current=s)},[t])}const Bu=x.createContext({});function yn(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function ub(e,t,n,r,o,s){var b,S;const{visualElement:i}=x.useContext(Yr),a=x.useContext(ju),c=x.useContext(Hr),u=x.useContext(ei).reducedMotion,l=x.useRef(null),d=x.useRef(!1);r=r||a.renderer,!l.current&&r&&(l.current=r(e,{visualState:t,parent:i,props:n,presenceContext:c,blockInitialAnimation:c?c.initial===!1:!1,reducedMotionConfig:u,isSVG:s}),d.current&&l.current&&(l.current.manuallyAnimateOnMount=!0));const f=l.current,p=x.useContext(Bu);f&&!f.projection&&o&&(f.type==="html"||f.type==="svg")&&db(l.current,n,o,p);const m=x.useRef(!1);x.useInsertionEffect(()=>{f&&m.current&&f.update(n,c)});const h=n[Yl],v=x.useRef(!!h&&!((b=window.MotionHandoffIsComplete)!=null&&b.call(window,h))&&((S=window.MotionHasOptimisedAnimation)==null?void 0:S.call(window,h)));return dl(()=>{d.current=!0,f&&(m.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),f.scheduleRenderMicrotask(),v.current&&f.animationState&&f.animationState.animateChanges())}),x.useEffect(()=>{f&&(!v.current&&f.animationState&&f.animationState.animateChanges(),v.current&&(queueMicrotask(()=>{var y;(y=window.MotionHandoffMarkAsComplete)==null||y.call(window,h)}),v.current=!1),f.enteringChildren=void 0)}),f}function db(e,t,n,r){const{layoutId:o,layout:s,drag:i,dragConstraints:a,layoutScroll:c,layoutRoot:u,layoutCrossfade:l}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Fu(e.parent)),e.projection.setOptions({layoutId:o,layout:s,alwaysMeasureLayout:!!i||a&&yn(a),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:l,layoutScroll:c,layoutRoot:u})}function Fu(e){if(e)return e.options.allowProjection!==!1?e.projection:Fu(e.parent)}function xo(e,{forwardMotionProps:t=!1,type:n}={},r,o){r&&G1(r);const s=n?n==="svg":ni(e),i=s?ab:ib;function a(u,l){let d;const f={...x.useContext(ei),...u,layoutId:fb(u)},{isStatic:p}=f,m=X1(u),h=i(u,p);if(!p&&ul){hb(f,r);const v=pb(f);d=v.MeasureLayout,m.visualElement=ub(e,h,f,o,v.ProjectionNode,s)}return g.jsxs(Yr.Provider,{value:m,children:[d&&m.visualElement?g.jsx(d,{visualElement:m.visualElement,...f}):null,rb(e,u,lb(h,m.visualElement,l),h,p,t,s)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const c=x.forwardRef(a);return c[cb]=e,c}function fb({layoutId:e}){const t=x.useContext(_s).id;return t&&e!==void 0?t+"-"+e:e}function hb(e,t){const n=x.useContext(ju).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const r="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?Qt(!1,r,"lazy-strict-mode"):lt(!1,r,"lazy-strict-mode")}}function pb(e){const t=Lu(),{drag:n,layout:r}=t;if(!n&&!r)return{};const o={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function mb(e,t){if(typeof Proxy>"u")return xo;const n=new Map,r=(s,i)=>xo(s,i,e,t),o=(s,i)=>(process.env.NODE_ENV!=="production"&&Rs(!1,"motion() is deprecated. Use motion.create() instead."),r(s,i));return new Proxy(o,{get:(s,i)=>i==="create"?r:(n.has(i)||n.set(i,xo(i,void 0,e,t)),n.get(i))})}const gb=(e,t)=>t.isSVG??ni(e)?new Kv(t):new Fv(t,{allowProjection:e!==x.Fragment});class yb extends wt{constructor(t){super(t),t.animationState||(t.animationState=Jv(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Gr(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let vb=0;class bb extends wt{constructor(){super(...arguments),this.id=vb++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const o=this.node.animationState.setActive("exit",!t);n&&!t&&o.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const xb={animation:{Feature:yb},exit:{Feature:bb}};function Wn(e){return{point:{x:e.pageX,y:e.pageY}}}const Sb=e=>t=>qs(t)&&e(t,Wn(t));function Cn(e,t,n,r){return In(e,t,Sb(n),r)}const zu=({current:e})=>e?e.ownerDocument.defaultView:null,ec=(e,t)=>Math.abs(e-t);function Tb(e,t){const n=ec(e.x,t.x),r=ec(e.y,t.y);return Math.sqrt(n**2+r**2)}const tc=new Set(["auto","scroll"]);class Wu{constructor(t,n,{transformPagePoint:r,contextWindow:o=window,dragSnapToOrigin:s=!1,distanceThreshold:i=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=p=>{this.handleScroll(p.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const p=To(this.lastMoveEventInfo,this.history),m=this.startEvent!==null,h=Tb(p.offset,{x:0,y:0})>=this.distanceThreshold;if(!m&&!h)return;const{point:v}=p,{timestamp:b}=Me;this.history.push({...v,timestamp:b});const{onStart:S,onMove:y}=this.handlers;m||(S&&S(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),y&&y(this.lastMoveEvent,p)},this.handlePointerMove=(p,m)=>{this.lastMoveEvent=p,this.lastMoveEventInfo=So(m,this.transformPagePoint),le.update(this.updatePoint,!0)},this.handlePointerUp=(p,m)=>{this.end();const{onEnd:h,onSessionEnd:v,resumeAnimation:b}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&b&&b(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const S=To(p.type==="pointercancel"?this.lastMoveEventInfo:So(m,this.transformPagePoint),this.history);this.startEvent&&h&&h(p,S),v&&v(p,S)},!qs(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=i,this.contextWindow=o||window;const c=Wn(t),u=So(c,this.transformPagePoint),{point:l}=u,{timestamp:d}=Me;this.history=[{...l,timestamp:d}];const{onSessionStart:f}=n;f&&f(t,To(u,this.history)),this.removeListeners=Bn(Cn(this.contextWindow,"pointermove",this.handlePointerMove),Cn(this.contextWindow,"pointerup",this.handlePointerUp),Cn(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(tc.has(r.overflowX)||tc.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,o=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},s={x:o.x-n.x,y:o.y-n.y};s.x===0&&s.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=s.x,this.lastMoveEventInfo.point.y+=s.y):this.history.length>0&&(this.history[0].x-=s.x,this.history[0].y-=s.y),this.scrollPositions.set(t,o),le.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),vt(this.updatePoint)}}function So(e,t){return t?{point:t(e.point)}:e}function nc(e,t){return{x:e.x-t.x,y:e.y-t.y}}function To({point:e},t){return{point:e,delta:nc(e,Uu(t)),offset:nc(e,wb(t)),velocity:Cb(t,.1)}}function wb(e){return e[0]}function Uu(e){return e[e.length-1]}function Cb(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=Uu(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>rt(t)));)n--;if(!r)return{x:0,y:0};const s=He(o.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const i={x:(o.x-r.x)/s,y:(o.y-r.y)/s};return i.x===1/0&&(i.x=0),i.y===1/0&&(i.y=0),i}function _b(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?fe(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?fe(n,e,r.max):Math.min(e,n)),e}function rc(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Eb(e,{top:t,left:n,bottom:r,right:o}){return{x:rc(e.x,n,o),y:rc(e.y,t,r)}}function oc(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function Pb(e,t){return{x:oc(e.x,t.x),y:oc(e.y,t.y)}}function Ab(e,t){let n=.5;const r=De(e),o=De(t);return o>r?n=Mn(t.min,t.max-r,e.min):r>o&&(n=Mn(e.min,e.max-o,t.min)),st(0,1,n)}function Mb(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const is=.35;function kb(e=is){return e===!1?e=0:e===!0&&(e=is),{x:sc(e,"left","right"),y:sc(e,"top","bottom")}}function sc(e,t,n){return{min:ic(e,t),max:ic(e,n)}}function ic(e,t){return typeof e=="number"?e:e[t]||0}const Rb=new WeakMap;class Ob{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=Ce(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:o}=this.visualElement;if(o&&o.isPresent===!1)return;const s=d=>{n?(this.stopAnimation(),this.snapToCursor(Wn(d).point)):this.pauseAnimation()},i=(d,f)=>{this.stopAnimation();const{drag:p,dragPropagation:m,onDragStart:h}=this.getProps();if(p&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=vv(p),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ze(b=>{let S=this.getAxisMotionValue(b).get()||0;if(ot.test(S)){const{projection:y}=this.visualElement;if(y&&y.layout){const C=y.layout.layoutBox[b];C&&(S=De(C)*(parseFloat(S)/100))}}this.originPoint[b]=S}),h&&le.postRender(()=>h(d,f)),Jo(this.visualElement,"transform");const{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},a=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f;const{dragPropagation:p,dragDirectionLock:m,onDirectionLock:h,onDrag:v}=this.getProps();if(!p&&!this.openDragLock)return;const{offset:b}=f;if(m&&this.currentDirection===null){this.currentDirection=Ib(b),this.currentDirection!==null&&h&&h(this.currentDirection);return}this.updateAxis("x",f.point,b),this.updateAxis("y",f.point,b),this.visualElement.render(),v&&v(d,f)},c=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f,this.stop(d,f),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>ze(d=>{var f;return this.getAnimationState(d)==="paused"&&((f=this.getAxisMotionValue(d).animation)==null?void 0:f.play())}),{dragSnapToOrigin:l}=this.getProps();this.panSession=new Wu(t,{onSessionStart:s,onStart:i,onMove:a,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:r,contextWindow:zu(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,o=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!o||!r)return;const{velocity:i}=o;this.startAnimation(i);const{onDragEnd:a}=this.getProps();a&&le.postRender(()=>a(r,o))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!nr(t,o,this.currentDirection))return;const s=this.getAxisMotionValue(t);let i=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(i=_b(i,this.constraints[t],this.elastic[t])),s.set(i)}resolveConstraints(){var s;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(s=this.visualElement.projection)==null?void 0:s.layout,o=this.constraints;t&&yn(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=Eb(r.layoutBox,t):this.constraints=!1,this.elastic=kb(n),o!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&ze(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=Mb(r.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!yn(t))return!1;const r=t.current;lt(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const s=Lv(r,o.root,this.visualElement.getTransformPagePoint());let i=Pb(o.layout.layoutBox,s);if(n){const a=n(Ov(i));this.hasMutatedConstraints=!!a,a&&(i=du(a))}return i}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:s,dragSnapToOrigin:i,onDragTransitionEnd:a}=this.getProps(),c=this.constraints||{},u=ze(l=>{if(!nr(l,n,this.currentDirection))return;let d=c&&c[l]||{};i&&(d={min:0,max:0});const f=o?200:1e6,p=o?40:1e7,m={type:"inertia",velocity:r?t[l]:0,bounceStiffness:f,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...s,...d};return this.startAxisValueAnimation(l,m)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Jo(this.visualElement,t),r.start(Us(t,r,0,n,this.visualElement,!1))}stopAnimation(){ze(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ze(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){ze(n=>{const{drag:r}=this.getProps();if(!nr(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,s=this.getAxisMotionValue(n);if(o&&o.layout){const{min:i,max:a}=o.layout.layoutBox[n],c=s.get()||0;s.set(t[n]-fe(i,a,.5)+c)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!yn(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};ze(i=>{const a=this.getAxisMotionValue(i);if(a&&this.constraints!==!1){const c=a.get();o[i]=Ab({min:c,max:c},this.constraints[i])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),ze(i=>{if(!nr(i,t,null))return;const a=this.getAxisMotionValue(i),{min:c,max:u}=this.constraints[i];a.set(fe(c,u,o[i]))})}addListeners(){if(!this.visualElement.current)return;Rb.set(this.visualElement,this);const t=this.visualElement.current,n=Cn(t,"pointerdown",c=>{const{drag:u,dragListener:l=!0}=this.getProps(),d=c.target,f=d!==t&&su(d);u&&l&&!f&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();yn(c)&&c.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,s=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),le.read(r);const i=In(window,"resize",()=>this.scalePositionWithinConstraints()),a=o.addEventListener("didUpdate",({delta:c,hasLayoutChanged:u})=>{this.isDragging&&u&&(ze(l=>{const d=this.getAxisMotionValue(l);d&&(this.originPoint[l]+=c[l].translate,d.set(d.get()+c[l].translate))}),this.visualElement.render())});return()=>{i(),n(),s(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:s=!1,dragElastic:i=is,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:s,dragElastic:i,dragMomentum:a}}}function nr(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function Ib(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class jb extends wt{constructor(t){super(t),this.removeGroupControls=Ge,this.removeListeners=Ge,this.controls=new Ob(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ge}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const ac=e=>(t,n)=>{e&&le.postRender(()=>e(t,n))};class Lb extends wt{constructor(){super(...arguments),this.removePointerDownListener=Ge}onPointerDown(t){this.session=new Wu(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:zu(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:ac(t),onStart:ac(n),onMove:r,onEnd:(s,i)=>{delete this.session,o&&le.postRender(()=>o(s,i))}}}mount(){this.removePointerDownListener=Cn(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 wo=!1;class Db extends x.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:s}=t;s&&(n.group&&n.group.add(s),r&&r.register&&o&&r.register(s),wo&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),hr.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:s}=this.props,{projection:i}=r;return i&&(i.isPresent=s,t.layoutDependency!==n&&i.setOptions({...i.options,layoutDependency:n}),wo=!0,o||t.layoutDependency!==n||n===void 0||t.isPresent!==s?i.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?i.promote():i.relegate()||le.postRender(()=>{const a=i.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Ys.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;wo=!0,o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Hu(e){const[t,n]=Iu(),r=x.useContext(_s);return g.jsx(Db,{...e,layoutGroup:r,switchLayoutGroup:x.useContext(Bu),isPresent:t,safeToRemove:n})}const $b={pan:{Feature:Lb},drag:{Feature:jb,ProjectionNode:Ou,MeasureLayout:Hu}};function cc(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const o="onHover"+n,s=r[o];s&&le.postRender(()=>s(t,Wn(t)))}class Vb extends wt{mount(){const{current:t}=this.node;t&&(this.unmount=bv(t,(n,r)=>(cc(this.node,r,"Start"),o=>cc(this.node,o,"End"))))}unmount(){}}class Nb extends wt{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=Bn(In(this.node.current,"focus",()=>this.onFocus()),In(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function lc(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const o="onTap"+(n==="End"?"":n),s=r[o];s&&le.postRender(()=>s(t,Wn(t)))}class Bb extends wt{mount(){const{current:t}=this.node;t&&(this.unmount=Tv(t,(n,r)=>(lc(this.node,r,"Start"),(o,{success:s})=>lc(this.node,o,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const as=new WeakMap,Co=new WeakMap,Fb=e=>{const t=as.get(e.target);t&&t(e)},zb=e=>{e.forEach(Fb)};function Wb({root:e,...t}){const n=e||document;Co.has(n)||Co.set(n,{});const r=Co.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(zb,{root:e,...t})),r[o]}function Ub(e,t,n){const r=Wb(t);return as.set(e,n),r.observe(e),()=>{as.delete(e),r.unobserve(e)}}const Hb={some:0,all:1};class Gb extends wt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:s}=t,i={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:Hb[o]},a=c=>{const{isIntersecting:u}=c;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:l,onViewportLeave:d}=this.node.getProps(),f=u?l:d;f&&f(c)};return Ub(this.node.current,i,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(Kb(t,n))&&this.startObserver()}unmount(){}}function Kb({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const Yb={inView:{Feature:Gb},tap:{Feature:Bb},focus:{Feature:Nb},hover:{Feature:Vb}},qb={layout:{ProjectionNode:Ou,MeasureLayout:Hu}},Zb={...xb,...Yb,...$b,...qb},vn=mb(Zb,gb),Gu="data:image/svg+xml,%3csvg%20width='18'%20height='18'%20viewBox='0%200%2018%2018'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M0.75%203.1875C0.75%201.84104%201.84104%200.75%203.1875%200.75L5.625%200.75V2.25H3.1875C2.66946%202.25%202.25%202.66946%202.25%203.1875V5.625H0.75L0.75%203.1875Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M0.75%2014.8125L0.75%2012.375H2.25V14.8125C2.25%2015.3305%202.66946%2015.75%203.1875%2015.75H5.625V17.25H3.1875C1.84104%2017.25%200.75%2016.159%200.75%2014.8125Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M15.75%2014.8125V12.375H17.25V14.8125C17.25%2016.159%2016.159%2017.25%2014.8125%2017.25H12.375V15.75H14.8125C15.3305%2015.75%2015.75%2015.3305%2015.75%2014.8125Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M15.75%203.1875C15.75%202.66946%2015.3305%202.25%2014.8125%202.25H12.375V0.75L14.8125%200.75C16.159%200.75%2017.25%201.84104%2017.25%203.1875V5.625H15.75V3.1875Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M10.8889%2010.5C11.6372%2010.5%2012.3895%2010.6845%2012.991%2011.053L12.9902%2011.0537C13.3468%2011.2719%2013.6565%2011.5584%2013.8684%2011.9092L14.5298%2013.0049L13.2451%2013.7798L12.5845%2012.6841C12.5191%2012.576%2012.3992%2012.4499%2012.2073%2012.3325C11.8787%2012.1312%2011.4076%2012%2010.8889%2012H7.11108C6.59216%2012%206.1214%2012.1305%205.79199%2012.3318L5.79272%2012.3325C5.64854%2012.4207%205.54509%2012.5138%205.47485%2012.6006L5.41553%2012.6841L4.75488%2013.7798L3.47021%2013.0049L4.13086%2011.9092C4.34281%2011.5583%204.6531%2011.2712%205.00977%2011.053C5.6104%2010.6859%206.36112%2010.5%207.11108%2010.5H10.8889Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M10.5%206.75C10.5%205.92157%209.82843%205.25%209%205.25C8.17157%205.25%207.5%205.92157%207.5%206.75C7.5%207.57843%208.17157%208.25%209%208.25C9.82843%208.25%2010.5%207.57843%2010.5%206.75ZM12%206.75C12%208.40685%2010.6569%209.75%209%209.75C7.34315%209.75%206%208.40685%206%206.75C6%205.09315%207.34315%203.75%209%203.75C10.6569%203.75%2012%205.09315%2012%206.75Z'%20fill='%23FDFCFC'/%3e%3c/svg%3e",Ku="data:image/svg+xml,%3csvg%20width='18'%20height='18'%20viewBox='0%200%2018%2018'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M2.25%2014.8125C2.25%2015.3305%202.66946%2015.75%203.1875%2015.75H5.625V17.25H3.1875C1.84104%2017.25%200.75%2016.159%200.75%2014.8125L0.75%2012.375H2.25V14.8125ZM17.25%2014.8125C17.25%2016.159%2016.159%2017.25%2014.8125%2017.25H12.375L12.375%2015.75H14.8125C15.3305%2015.75%2015.75%2015.3305%2015.75%2014.8125V12.375L17.25%2012.375V14.8125ZM14.135%206.35229C14.2958%206.19142%2014.5379%206.14314%2014.748%206.22998C14.9583%206.31702%2015.0959%206.52245%2015.0959%206.75V10.5015C15.0959%2010.812%2014.8439%2011.0638%2014.5334%2011.064C14.2228%2011.0639%2013.9709%2010.8121%2013.9709%2010.5015V8.10571C13.7502%208.30415%2013.4107%208.29824%2013.1982%208.08594C12.9785%207.86637%2012.9787%207.51027%2013.1982%207.29053L14.135%206.35229ZM11.3298%206.19336C11.5137%206.21969%2011.6748%206.33566%2011.7568%206.5061C11.8505%206.70099%2011.8245%206.93272%2011.6895%207.10156L9.42041%209.9375H11.25C11.5607%209.9375%2011.8125%2010.1893%2011.8125%2010.5C11.8125%2010.8107%2011.5607%2011.0625%2011.25%2011.0625H8.25C8.03386%2011.0625%207.83688%2010.9386%207.74316%2010.7439C7.6495%2010.549%207.67547%2010.3173%207.81055%2010.1484L10.0796%207.3125L8.25%207.3125C7.93934%207.3125%207.6875%207.06066%207.6875%206.75C7.6875%206.43934%207.93934%206.1875%208.25%206.1875L11.25%206.1875L11.3298%206.19336ZM5.25%206.19482C5.45567%206.22809%205.62952%206.37352%205.69531%206.57642L6.9104%2010.3264C7.00614%2010.6219%206.84405%2010.9396%206.54858%2011.0354C6.25308%2011.1311%205.93539%2010.9691%205.8396%2010.6736L5.72241%2010.3125H3.65259L3.5354%2010.6736C3.43961%2010.9691%203.12192%2011.1311%202.82642%2011.0354C2.53095%2010.9396%202.36886%2010.6219%202.4646%2010.3264L2.68579%209.6416C2.69424%209.59828%202.7083%209.55696%202.72607%209.51782L3.67969%206.57642L3.71411%206.49365C3.80908%206.30792%204.00155%206.1875%204.21509%206.1875H5.15991L5.25%206.19482ZM4.0166%209.1875H5.3584L4.75122%207.3125H4.62378L4.0166%209.1875ZM5.625%202.25H3.1875C2.66946%202.25%202.25%202.66946%202.25%203.1875V5.625H0.75L0.75%203.1875C0.75%201.84104%201.84104%200.75%203.1875%200.75L5.625%200.75V2.25ZM14.8125%200.75C16.159%200.75%2017.25%201.84104%2017.25%203.1875V5.625H15.75V3.1875C15.75%202.66946%2015.3305%202.25%2014.8125%202.25H12.375V0.75L14.8125%200.75Z'%20fill='%23FDFCFC'/%3e%3c/svg%3e";function Xb(e){return e==="Facial"?g.jsx("img",{src:Gu,alt:"Facial",width:16,height:16,style:{display:"block"}}):e==="LPR"?g.jsx("img",{src:Ku,alt:"LPR",width:16,height:16,style:{display:"block"}}):g.jsx(Ve.VideocamOutlined,{sx:{fontSize:16}})}function Jb(e){return e==="Facial"?g.jsx("img",{src:Gu,alt:"Facial",width:18,height:18,style:{display:"block"}}):e==="LPR"?g.jsx("img",{src:Ku,alt:"LPR",width:18,height:18,style:{display:"block"}}):g.jsx(Ve.VideocamOutlined,{sx:{fontSize:18,color:"#fff"}})}function Qb(e){if(!e||!Array.isArray(e)||e.length===0)return;const t={};return e.forEach(n=>{const r=n.algorithm||"Outros";t[r]=(t[r]||0)+1}),Object.entries(t).map(([n,r])=>({count:r,icon:Xb(n)}))}const ex="_spotWrapper_dvp29_1",tx="_mapSpot_dvp29_8",nx="_selected_dvp29_27",rx="_count_dvp29_31",ox="_countSelected_dvp29_39",sx="_cameraTypesContainer_dvp29_43",ix="_cameraTypeItem_dvp29_50",ax="_cameraTypeCount_dvp29_57",cx="_cameraTypeIcon_dvp29_64",lx="_selectionEffect_dvp29_72",ux="_arrowSvg_dvp29_81",dx="_cameraButtonWrapper_dvp29_86",fx="_cone_dvp29_91",hx="_cameraButton_dvp29_86",je={spotWrapper:ex,mapSpot:tx,selected:nx,count:rx,countSelected:ox,cameraTypesContainer:sx,cameraTypeItem:ix,cameraTypeCount:ax,cameraTypeIcon:cx,selectionEffect:lx,arrowSvg:ux,cameraButtonWrapper:dx,cone:fx,cameraButton:hx},px=vn(_.Box),uc=60,mx=34,ri=({count:e,addressText:t,cameras:n,isSelected:r,animateOnClick:o=!0,disableClick:s=!1,className:i,onClick:a,sx:c})=>{const[u,l]=x.useState(!1),d=x.useMemo(()=>Qb(n),[n]),f=d&&d.length>0,p=(v,b)=>{const S=(v-90)*(Math.PI/180);return{x:Math.cos(S)*b,y:Math.sin(S)*b}},m=(v,b)=>{const S=v.orientation??b*90,y=p(S,uc);return g.jsxs("svg",{className:je.arrowSvg,style:{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%)",overflow:"visible",pointerEvents:"none"},width:"1",height:"1",children:[g.jsx("defs",{children:g.jsx("marker",{id:`arrowhead-${v.id}`,markerWidth:"6",markerHeight:"6",refX:"3",refY:"3",orient:"auto",children:g.jsx("polygon",{points:"0 0, 6 3, 0 6",fill:"var(--Tertiary-On-Tertiary, #ffffff)"})})}),g.jsx("line",{x1:"0",y1:"0",x2:y.x,y2:y.y,stroke:"var(--Tertiary-On-Tertiary, #ffffff)",strokeWidth:"2",markerEnd:`url(#arrowhead-${v.id})`})]},`arrow-${v.id}`)},h=(v,b)=>{const S=v.orientation??b*90,y=p(S,uc+mx/2+10),C=Jb(v.algorithm);return g.jsxs("div",{className:je.cameraButtonWrapper,style:{position:"absolute",left:"50%",top:"50%",transform:`translate(calc(-50% + ${y.x}px), calc(-50% + ${y.y}px))`},children:[g.jsx("div",{className:je.cone,style:{transform:`rotate(${S+180}deg)`}}),g.jsx("div",{className:je.cameraButton,children:C})]},`camera-${v.id}`)};return g.jsxs("div",{className:je.spotWrapper,children:[r&&n&&n.length>0&&(o?g.jsxs(vn.div,{className:je.selectionEffect,initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.3,ease:"easeOut"},children:[n.map((v,b)=>m(v,b)),n.map((v,b)=>h(v,b))]}):g.jsxs("div",{className:je.selectionEffect,children:[n.map((v,b)=>m(v,b)),n.map((v,b)=>h(v,b))]})),g.jsx(px,{className:`${je.mapSpot} ${r?je.selected:""} ${i||""}`,onClick:s?void 0:a,onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1),sx:{...c},animate:{width:u&&f&&!r?"auto":30,height:u&&f&&!r?"auto":30,borderRadius:"100px",backgroundColor:r?"var(--Tertiary-Tertiary, #7FCFCF)":u&&f?"var(--Surface-Surface-Tint, #5E5E5E)":"var(--Surface-Inverse-Surface, #3B3B3C)",padding:u&&f&&!r?"4px 8px":0,borderWidth:r?1:0,borderStyle:"solid",borderColor:r?"var(--Tertiary-On-Tertiary, #ffffff)":"transparent"},transition:{duration:.2,ease:"easeInOut"},children:g.jsx(U1,{mode:"wait",children:u&&f&&!r?g.jsx(vn.div,{className:je.cameraTypesContainer,initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2,ease:"easeInOut"},children:d.map((v,b)=>g.jsxs(vn.div,{className:je.cameraTypeItem,initial:{opacity:0,x:-10},animate:{opacity:1,x:0},transition:{duration:.2,delay:b*.05},children:[g.jsx(_.Typography,{className:je.cameraTypeCount,children:v.count}),v.icon&&g.jsx(_.Box,{className:je.cameraTypeIcon,children:v.icon})]},b))},"expanded"):g.jsx(vn.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2,ease:"easeInOut"},children:g.jsx(_.Typography,{className:`${je.count} ${r?je.countSelected:""}`,children:e})},"collapsed")})})]})};ri.displayName="MapSpot";const gx=16,Yu=({spots:e,onSpotClick:t,zoomLevel:n=gx,selectedSpotId:r,animateOnClick:o,disableClick:s})=>{const{isLoaded:i,zoomToPosition:a}=cl(),c=u=>{a({lat:u.lat,lng:u.lng},n),s||t==null||t(u)};return i?g.jsx(g.Fragment,{children:e.map((u,l)=>g.jsx(il,{position:{lat:u.lat,lng:u.lng},onClick:()=>c(u),children:g.jsx(ri,{count:u.count,addressText:u.addressText,cameras:u.cameras,isSelected:!s&&r===u.id,animateOnClick:o,disableClick:s})},u.id??l))}):null};Yu.displayName="MapMarkers";const yx="_searchBar_15mix_1",vx="_startIconContainer_15mix_106",bx="_endIconContainer_15mix_117",xx="_endIconContainerClickable_15mix_153",Sx="_defaultIcon_15mix_157",bn={searchBar:yx,startIconContainer:vx,endIconContainer:bx,endIconContainerClickable:xx,defaultIcon:Sx},Tx=e=>()=>{e&&e()},wx=e=>t=>{e&&e(t)},Cx=()=>g.jsx(Ve.Search,{className:bn.defaultIcon}),_x=e=>e||Cx(),qu=x.forwardRef(({startIcon:e,endIcon:t,onEndIconClick:n,placeholder:r,value:o,onChange:s,className:i,...a},c)=>{const l=_.useTheme().palette.mode==="dark",d=_x(t),f=Tx(n),p=wx(s);return g.jsx(_.TextField,{ref:c,value:o,onChange:p,placeholder:r,variant:"outlined",autoComplete:"off",className:`${bn.searchBar} ${i||""}`,"data-theme":l?"dark":"light",InputProps:{startAdornment:e?g.jsx(_.InputAdornment,{position:"start",className:bn.startIconContainer,children:e}):null,endAdornment:g.jsx(_.InputAdornment,{position:"end",className:`${bn.endIconContainer} ${n?bn.endIconContainerClickable:""}`,onClick:f,disablePointerEvents:!n,children:d})},inputProps:{autoComplete:"off","data-form-type":"other"},...a})});qu.displayName="SearchBar";const Ex=dt(g.jsx("path",{d:"M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"}),"Home"),Px=dt([g.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3 6.08 3 3.28 5.64 3.03 9h2.02C5.3 6.75 7.18 5 9.5 5 11.99 5 14 7.01 14 9.5S11.99 14 9.5 14c-.17 0-.33-.03-.5-.05v2.02c.17.02.33.03.5.03 1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19z"},"0"),g.jsx("path",{d:"M6.47 10.82 4 13.29l-2.47-2.47-.71.71L3.29 14 .82 16.47l.71.71L4 14.71l2.47 2.47.71-.71L4.71 14l2.47-2.47z"},"1")],"SearchOff"),Ax="_container_1mb8b_1",Mx="_iconWrapper_1mb8b_11",kx="_icon_1mb8b_11",Rx="_title_1mb8b_21",Ox="_subtitle_1mb8b_30",Ix="_description_1mb8b_34",jx="_button_1mb8b_38",_t={container:Ax,iconWrapper:Mx,icon:kx,title:Rx,subtitle:Ox,description:Ix,button:jx},Zu=({onGoHome:e,buttonText:t="Voltar para o início",title:n="Página não encontrada",description:r="Desculpe, a página que você está procurando não existe ou foi movida para outro endereço.",errorCode:o="404",className:s})=>g.jsx(_.Container,{maxWidth:"sm",children:g.jsxs(_.Box,{className:`${_t.container} ${s||""}`,children:[g.jsx(_.Box,{className:_t.iconWrapper,children:g.jsx(Px,{className:_t.icon,color:"primary"})}),g.jsx(_.Typography,{variant:"h1",className:_t.title,sx:{fontSize:{xs:"6rem",md:"8rem"}},children:o}),g.jsx(_.Typography,{variant:"h4",component:"h2",className:_t.subtitle,color:"text.primary",children:n}),g.jsx(_.Typography,{variant:"body1",className:_t.description,color:"text.secondary",children:r}),e&&g.jsx(hs,{variant:"contained",size:"large",startIcon:g.jsx(Ex,{}),onClick:e,className:_t.button,children:t})]})});Zu.displayName="NotFoundContent";const Lx=e=>{const t=e.find(r=>r.active),n=e.flatMap(r=>{var o;return((o=r.submenu)==null?void 0:o.map(s=>({item:r,subItem:s})))??[]}).find(({subItem:r})=>r.active);return{itemId:(n==null?void 0:n.item.id)??(t==null?void 0:t.id)??null,subItemId:(n==null?void 0:n.subItem.id)??null,expandedItemId:(n==null?void 0:n.item.id)??null}},Dx=({items:e,isExpanded:t=!0,onClick:n})=>{const r=x.useMemo(()=>Lx(e),[e]),[o,s]=x.useState(r.itemId),[i,a]=x.useState(r.subItemId),[c,u]=x.useState(r.expandedItemId),[l,d]=x.useState(null),[f,p]=x.useState(null);x.useEffect(()=>{s(r.itemId),a(r.subItemId),u(r.expandedItemId)},[r.itemId,r.subItemId,r.expandedItemId]);const m=f?e.find(E=>E.id===f):void 0,h=(m==null?void 0:m.submenu)??[];return{selectedItemId:o,selectedSubItemId:i,expandedItemId:c,submenuAnchorEl:l,submenuItem:m,submenuItems:h,getIsItemActive:E=>{var A;const P=i?!!((A=E.submenu)!=null&&A.some(M=>M.id===i)):!1;return o?E.id===o:!!(E.active||P)},getIsSubItemActive:E=>i?E.id===i:!!E.active,shouldShowSubmenu:E=>{var P;return!!(t&&((P=E.submenu)!=null&&P.length)&&c===E.id)},handleItemClick:(E,P)=>{var A,M;s(E.id),a(null),(A=E.submenu)!=null&&A.length?t?u(L=>L===E.id?null:E.id):(d(P.currentTarget),p(E.id)):(u(null),d(null),p(null)),(M=E.onClick)==null||M.call(E,P),n==null||n({item:E})},handleSubItemClick:(E,P,A,M)=>{var L;s(E.id),a(P.id),M!=null&&M.closeMenu&&(d(null),p(null)),(L=P.onClick)==null||L.call(P,A),n==null||n({item:E,subItem:P})},closeSubmenu:()=>{d(null),p(null)}}},Xu=e=>typeof e=="number"?`${e*4}px`:e,$x=({item:e,onClick:t,isActive:n})=>{const r=Y.useTheme();return g.jsx(_.ButtonBase,{onClick:t,"aria-label":e.label,"aria-pressed":n||void 0,sx:{width:"100%",borderRadius:Xu(r.shape.borderRadius),px:2,py:1.25,justifyContent:"flex-start",textAlign:"left",color:r.palette.text.primary,backgroundColor:n?r.palette.action.selected:"transparent","&:hover":{backgroundColor:r.palette.action.hover}},children:g.jsx(_.Typography,{variant:"body2",sx:{fontWeight:500},children:e.label})})},Ju=({items:e,isExpanded:t=!0,className:n,onClick:r})=>{const o=Y.useTheme(),s=Xu(o.shape.borderRadius),{submenuAnchorEl:i,submenuItem:a,submenuItems:c,getIsItemActive:u,getIsSubItemActive:l,shouldShowSubmenu:d,handleItemClick:f,handleSubItemClick:p,closeSubmenu:m}=Dx({items:e,isExpanded:t,onClick:r});return g.jsxs(_.Stack,{className:n,direction:"column",spacing:2,sx:{width:"100%"},children:[e.map(h=>{var E,P;const v=u(h),b=d(h),S=t?o.spacing(2):o.spacing(4),y=t?v?o.palette.primary.main:o.palette.action.hover:"transparent",C=t?"transparent":v?o.palette.primary.main:o.palette.action.hover,T=!t&&v?o.palette.primary.contrastText:o.palette.text.primary;return g.jsxs(_.Stack,{direction:"column",spacing:1,sx:{width:"100%"},children:[g.jsx(_.ButtonBase,{onClick:A=>f(h,A),"aria-label":h.label,"aria-pressed":v||void 0,"aria-haspopup":(E=h.submenu)!=null&&E.length?"menu":void 0,sx:{width:"100%",borderRadius:s,px:t?2:1,py:t?1.5:1,justifyContent:t?"flex-start":"center",textAlign:"left",color:o.palette.text.primary,backgroundColor:y,boxShadow:t&&v?o.shadows[1]:"none","&:hover":{backgroundColor:t?o.palette.action.hover:"transparent"}},children:g.jsxs(_.Stack,{direction:t?"row":"column",alignItems:"center",spacing:t?1.5:1,sx:{width:"100%"},children:[g.jsx(_.Box,{sx:{width:64,height:S,borderRadius:s,display:"inline-flex",alignItems:"center",justifyContent:"center",backgroundColor:C,color:T,transition:o.transitions.create(["background-color","box-shadow"],{duration:o.transitions.duration.shortest}),...t?{}:{boxShadow:v?o.shadows[1]:"none","&:hover":{backgroundColor:v?Y.alpha(o.palette.primary.main,.9):o.palette.action.selected}}},children:h.icon}),g.jsx(_.Typography,{variant:"body2",sx:{width:"100%",textAlign:t?"left":"center",fontWeight:v?600:500},children:h.label}),t&&h.trailingIcon?g.jsx(_.Box,{sx:{ml:"auto",display:"inline-flex",alignItems:"center"},children:h.trailingIcon}):null]})}),b?g.jsx(_.Collapse,{in:b,timeout:"auto",unmountOnExit:!0,children:g.jsx(_.Stack,{direction:"column",spacing:1,sx:{pl:4},children:(P=h.submenu)==null?void 0:P.map(A=>{const M=l(A);return g.jsx($x,{item:A,isActive:M,onClick:L=>p(h,A,L)},A.id)})})}):null]},h.id)}),g.jsx(_.Menu,{anchorEl:i,open:!!(i&&c.length),onClose:m,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},MenuListProps:{dense:!0,"aria-label":(a==null?void 0:a.label)??"submenu"},PaperProps:{sx:{borderRadius:s,minWidth:o.spacing(22),px:1,py:.5,boxShadow:o.shadows[3]}},children:c.map(h=>{const v=l(h);return g.jsx(_.MenuItem,{selected:v,onClick:b=>{a&&p(a,h,b,{closeMenu:!0})},sx:{borderRadius:s,fontWeight:v?600:500},children:h.label},h.id)})})]})};Ju.displayName="SidebarMenu";const Vx=e=>{const t=e.find(n=>n.active);return(t==null?void 0:t.id)??null},Nx=({items:e,onSelect:t,isExpanded:n=!0})=>{const r=x.useMemo(()=>Vx(e),[e]),[o,s]=x.useState(r),[i,a]=x.useState(null);x.useEffect(()=>{s(r)},[r]);const c=o?e.find(p=>p.id===o):void 0;return{selectedItemId:o,selectedItem:c,menuAnchorEl:i,getIsItemActive:p=>o?p.id===o:!!p.active,openMenu:p=>{n||a(p.currentTarget)},closeMenu:()=>{n||a(null)},handleItemClick:(p,m)=>{var h;s(p.id),(h=p.onClick)==null||h.call(p,m),t==null||t(p),a(null)}}},Bx=e=>typeof e=="number"?`${e*4}px`:e,Qu=({items:e,currentLabel:t,headerLabel:n,headerIcon:r,headerTrailingIcon:o,listTitle:s,action:i,isExpanded:a=!0,className:c,onSelect:u})=>{var Q,U;const l=Y.useTheme(),d=x.useRef(null),f=Bx(l.shape.borderRadius),[p,m]=x.useState(!1),h=x.useMemo(()=>Number.parseFloat(l.spacing(2).toString()),[l]),{selectedItem:v,menuAnchorEl:b,getIsItemActive:S,openMenu:y,closeMenu:C,handleItemClick:T}=Nx({items:e,onSelect:u,isExpanded:a}),E=t??(v==null?void 0:v.label)??((Q=e[0])==null?void 0:Q.label)??"",P=r??(v==null?void 0:v.icon)??((U=e[0])==null?void 0:U.icon)??null,A=a||!P,M=I=>{if(a){m(X=>!X);return}y(I)},L=(I,X)=>{T(I,X),m(!1)},$=g.jsx(_.Stack,{direction:"column",spacing:.5,children:e.map(I=>{const X=S(I);return g.jsxs(_.MenuItem,{selected:X,onClick:R=>L(I,R),sx:{borderRadius:f,gap:1.5,px:2,py:1.25,color:l.palette.text.primary,"&:hover":{backgroundColor:l.palette.action.hover}},children:[I.icon?g.jsx(_.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:I.icon}):null,g.jsx(_.Typography,{variant:"body1",sx:{fontWeight:X?600:500},children:I.label})]},I.id)})}),W=g.jsxs(_.Box,{sx:{borderRadius:f,backgroundColor:l.palette.background.paper,boxShadow:l.shadows[3],display:"flex",flexDirection:"column",maxHeight:l.spacing(50)},children:[s?g.jsx(_.Box,{sx:{px:2,pt:2,pb:1},children:g.jsx(_.Typography,{variant:"subtitle2",sx:{color:l.palette.text.primary},children:s})}):null,g.jsx(_.Box,{sx:{px:2,pb:2,overflowY:"auto",flex:1,minHeight:0},children:$})]}),H=i?g.jsxs(_.MenuItem,{onClick:i.onClick,sx:{borderRadius:f,gap:1.5,px:2,py:1.25,color:l.palette.text.primary,"&:hover":{backgroundColor:l.palette.action.hover}},children:[i.icon?g.jsx(_.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:i.icon}):null,g.jsx(_.Typography,{variant:"body1",sx:{fontWeight:600},children:i.label})]}):null,q=H?g.jsx(_.Box,{sx:{borderRadius:f,backgroundColor:l.palette.background.paper,boxShadow:l.shadows[3]},children:H}):null,oe=g.jsxs(_.Stack,{direction:"column",spacing:1,sx:{minWidth:l.spacing(32)},children:[W,q]});return g.jsxs(_.Stack,{className:c,direction:a?"row":"column",spacing:a?2:1,sx:{width:"100%",alignItems:a?"flex-start":"stretch"},children:[g.jsx(_.ButtonBase,{onClick:M,"aria-label":E,ref:d,sx:{width:a?l.spacing(28):"64px",height:a?"auto":"64px",borderRadius:f,px:a?2:0,py:a?1.25:0,display:"flex",alignItems:"center",justifyContent:"center",textAlign:"left",backgroundColor:l.palette.action.hover,"&:hover":{backgroundColor:l.palette.action.selected}},children:g.jsxs(_.Stack,{direction:"row",alignItems:"center",spacing:a?1:0,sx:{width:a?"100%":"auto",justifyContent:a?"space-between":"center",px:0},children:[P?g.jsx(_.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:P}):null,A?g.jsxs(_.Box,{sx:{minWidth:0,flex:1},children:[n?g.jsx(_.Typography,{variant:"caption",sx:{color:l.palette.text.secondary},children:n}):null,g.jsx(_.Typography,{variant:"body2",sx:{fontWeight:600},noWrap:!0,children:E})]}):null,a&&o?g.jsx(_.Box,{sx:{ml:"auto",display:"inline-flex",alignItems:"center"},children:o}):null]})}),a?p?g.jsx(_.ClickAwayListener,{onClickAway:()=>m(!1),children:g.jsx(_.Popper,{open:p,anchorEl:d.current,placement:"right-start",modifiers:[{name:"offset",options:{offset:[0,h]}}],sx:{zIndex:l.zIndex.modal},children:oe})}):null:g.jsx(_.Menu,{anchorEl:b,open:!!b,onClose:C,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},disableAutoFocusItem:!0,slotProps:{paper:{sx:{borderRadius:f,p:0,ml:2,backgroundColor:"transparent",boxShadow:"none",overflow:"visible"}}},MenuListProps:{"aria-label":E?`menu-${E}`:"menu",sx:{p:0}},children:oe})]})};Qu.displayName="ModuleMenu";const oi=e=>e.seekable&&e.seekable.length>0?e.seekable.end(e.seekable.length-1):Number.isFinite(e.duration)&&e.duration>0?e.duration:e.currentTime,Fx=(e,t,n)=>({...e&&{"--player-width":typeof e=="number"?`${e}px`:e},...t&&{"--player-height":typeof t=="number"?`${t}px`:t},...n&&{"--player-aspect-ratio":n}}),zx=({stream:e,availableQualities:t,initialQuality:n,autoPlay:r,liveThresholdSeconds:o,allowPlaybackRateForStream:s})=>{const i=x.useRef(null),a=x.useRef(null),c=x.useMemo(()=>{if(!t||!t.length)return null;if(n){const I=t.find(X=>X.value===n);if(I)return I}return t[0]},[t,n]),[u,l]=x.useState(c),[d,f]=x.useState(!1),[p,m]=x.useState(!0),[h,v]=x.useState(!1),[b,S]=x.useState(0),[y,C]=x.useState(0),[T,E]=x.useState(1),[P,A]=x.useState(1),[M,L]=x.useState(!1),[$,W]=x.useState(!0),H=(u==null?void 0:u.stream)??e??null,q=(u==null?void 0:u.src)??null,Q=!!!H||s;x.useEffect(()=>{l(c)},[c]);const U=x.useCallback(()=>{const I=a.current;if(!I)return;if(!I.seekable||I.seekable.length===0){m(!0),v(!1);return}const X=oi(I),R=Math.max(0,X-I.currentTime);C(X),S(I.currentTime),v(X>0),m(R<=(o??2))},[o]);return x.useEffect(()=>{const I=a.current;if(!I)return;const X=()=>f(!0),R=()=>f(!1),w=()=>W(!0),j=()=>W(!0),k=()=>W(!1),O=()=>W(!1);return I.addEventListener("play",X),I.addEventListener("pause",R),I.addEventListener("waiting",w),I.addEventListener("loadstart",j),I.addEventListener("canplay",k),I.addEventListener("playing",O),I.addEventListener("timeupdate",U),I.addEventListener("durationchange",U),I.addEventListener("loadedmetadata",U),I.addEventListener("progress",U),()=>{I.removeEventListener("play",X),I.removeEventListener("pause",R),I.removeEventListener("waiting",w),I.removeEventListener("loadstart",j),I.removeEventListener("canplay",k),I.removeEventListener("playing",O),I.removeEventListener("timeupdate",U),I.removeEventListener("durationchange",U),I.removeEventListener("loadedmetadata",U),I.removeEventListener("progress",U)}},[U]),x.useEffect(()=>{const I=a.current;I&&(W(!0),H?(I.srcObject!==H&&(I.srcObject=H),I.getAttribute("src")&&I.removeAttribute("src")):q?(I.srcObject&&(I.srcObject=null),I.src!==q&&(I.src=q,I.load())):(I.srcObject&&(I.srcObject=null),I.getAttribute("src")&&I.removeAttribute("src")),r&&I.play().then(()=>{}).catch(()=>{}))},[H,q,r]),x.useEffect(()=>{const I=a.current;I&&(Q?I.playbackRate=T:(I.playbackRate=1,E(1)))},[T,Q]),x.useEffect(()=>{const I=()=>{L(!!document.fullscreenElement)};return document.addEventListener("fullscreenchange",I),()=>{document.removeEventListener("fullscreenchange",I)}},[]),{containerRef:i,videoRef:a,selectedQuality:u,setSelectedQuality:l,isPlaying:d,isLive:p,canSeek:h,currentTime:b,setCurrentTime:S,seekableEnd:y,playbackRate:T,setPlaybackRate:E,zoom:P,setZoom:A,isFullscreen:M,isLoading:$,canAdjustPlaybackRate:Q,updateLiveStatus:U}},Wx="_container_zv1tx_1",Ux="_loader_zv1tx_19",Hx="_video_zv1tx_29",Gx="_controlsOverlay_zv1tx_37",Kx="_timeline_zv1tx_58",Yx="_controlsRow_zv1tx_65",qx="_controlGroup_zv1tx_83",Zx="_iconButton_zv1tx_100",Xx="_seekButton_zv1tx_113",Jx="_menuButton_zv1tx_133",Qx="_liveBadge_zv1tx_149",Ae={container:Wx,loader:Ux,video:Hx,controlsOverlay:Gx,timeline:Kx,controlsRow:Yx,controlGroup:qx,iconButton:Zx,seekButton:Xx,menuButton:Jx,liveBadge:Qx},_o=({label:e,valueLabel:t,selectedValue:n,options:r,onChange:o,disabled:s,ariaLabel:i})=>{const[a,c]=x.useState(null),u=!!a;return g.jsxs(g.Fragment,{children:[g.jsx(_.ButtonBase,{disabled:s,className:Ae.menuButton,"aria-label":i,onClick:l=>c(l.currentTarget),children:e?`${e}: ${t}`:t}),g.jsx(_.Menu,{anchorEl:a,open:u,onClose:()=>c(null),children:r.map(l=>g.jsx(_.MenuItem,{selected:l.value===n,disabled:l.disabled,onClick:()=>{o(l.value),c(null)},children:l.label},`${e}-${String(l.value)}`))})]})},eS=e=>()=>{const t=e.current;t&&(t.paused?t.play().catch(()=>{}):t.pause())},tS=(e,t,n)=>r=>{const o=e.current;if(!o||!t)return;const s=oi(o),i=Math.min(Math.max(o.currentTime+r,0),s);o.currentTime=i,n()},nS=e=>()=>{e.current&&(document.fullscreenElement?document.exitFullscreen().catch(()=>{}):e.current.requestFullscreen().catch(()=>{}))},rS=(e,t,n)=>r=>{const o=e.find(s=>s.value===r)??null;t(o),n==null||n(o)},oS=(e,t)=>(n,r)=>{if(!e)return;const o=Array.isArray(r)?r[0]:r;t(o)},sS=(e,t,n)=>(r,o)=>{const s=e.current;if(!s||!t)return;const i=Array.isArray(o)?o[0]:o,a=oi(s);s.currentTime=Math.min(Math.max(i,0),a),n()},ed=({stream:e=null,availableQualities:t=[],initialQuality:n,onQualityChange:r,autoPlay:o=!0,playsInline:s=!0,muted:i=!0,poster:a,className:c,sx:u,liveThresholdSeconds:l=2,allowPlaybackRateForStream:d=!1,playbackRates:f=[.5,1,1.5,2],zoomLevels:p=[1,1.2,1.5],width:m,height:h,aspectRatio:v="16 / 9",showTimestamp:b=!0,showTimeline:S=!0})=>{const y=Y.useTheme(),[C,T]=x.useState(""),[E,P]=x.useState(!0),A=x.useRef(null);x.useEffect(()=>{if(!b)return;const we=()=>{const Je=new Date,Hn=String(Je.getDate()).padStart(2,"0"),yd=String(Je.getMonth()+1).padStart(2,"0"),vd=Je.getFullYear(),bd=["Dom","Seg","Ter","Qua","Qui","Sex","Sab"][Je.getDay()],xd=String(Je.getHours()).padStart(2,"0"),Sd=String(Je.getMinutes()).padStart(2,"0"),Td=String(Je.getSeconds()).padStart(2,"0");T(`${Hn}-${yd}-${vd}, ${bd} ${xd}:${Sd}:${Td}`)};we();const Un=setInterval(we,1e3);return()=>clearInterval(Un)},[b]),x.useEffect(()=>{const we=M.current;if(!we)return;const Un=()=>{A.current&&(clearTimeout(A.current),A.current=null),P(!0)},Je=()=>{A.current=setTimeout(()=>{P(!1)},1e4)},Hn=()=>{E||P(!0),A.current&&clearTimeout(A.current),A.current=setTimeout(()=>{P(!1)},1e4)};return we.addEventListener("mouseenter",Un),we.addEventListener("mouseleave",Je),we.addEventListener("mousemove",Hn),()=>{we.removeEventListener("mouseenter",Un),we.removeEventListener("mouseleave",Je),we.removeEventListener("mousemove",Hn),A.current&&clearTimeout(A.current)}},[E]);const{containerRef:M,videoRef:L,selectedQuality:$,setSelectedQuality:W,isPlaying:H,isLive:q,canSeek:oe,currentTime:Q,setCurrentTime:U,seekableEnd:I,playbackRate:X,setPlaybackRate:R,zoom:w,setZoom:j,isFullscreen:k,isLoading:O,canAdjustPlaybackRate:F,updateLiveStatus:N}=zx({stream:e,availableQualities:t,initialQuality:n,autoPlay:o,liveThresholdSeconds:l,allowPlaybackRateForStream:d}),V=eS(L),z=tS(L,oe,N),G=nS(M),K=rS(t,W,r),he=oS(oe,U),D=sS(L,oe,N),Ee=p.map(we=>({value:we,label:`${Math.round(we*100)}%`})),Xe=f.map(we=>({value:we,label:`${we}x`})),ft=t.map(we=>({value:we.value,label:we.label})),qr=($==null?void 0:$.label)??"Auto",on=`${Math.round(w*100)}%`,sn=`${X}x`,an=oe&&I>0,Zr=Fx(m,h,v);return g.jsxs(_.Box,{ref:M,className:`${Ae.container} ${c||""}`.trim(),style:Zr,sx:{borderRadius:0,backgroundColor:y.palette.common.black,...u},children:[O&&g.jsx(_.Box,{className:Ae.loader,sx:{backgroundColor:y.palette.common.black},children:g.jsx(_.CircularProgress,{size:60,sx:{color:y.palette.primary.contrastText,width:{xs:"48px",sm:"60px"},height:{xs:"48px",sm:"60px"}}})}),g.jsx("video",{ref:L,className:Ae.video,autoPlay:o,playsInline:s,muted:i,poster:a,style:{transform:`scale(${w})`}}),b&&C&&g.jsx(_.Box,{sx:{position:"absolute",top:0,left:0,right:0,padding:{xs:"10px 12px",sm:"12px 16px"}},children:g.jsx(_.Typography,{variant:"body2",sx:{color:y.palette.common.white,fontWeight:500,fontSize:{xs:"12px",sm:"14px"},textShadow:"0 2px 8px rgba(0,0,0,0.8)"},children:C})}),q&&!E&&g.jsx(_.Box,{sx:{position:"absolute",bottom:16,left:20,zIndex:10},children:g.jsx(_.Box,{className:Ae.liveBadge,sx:{backgroundColor:Y.alpha(y.palette.common.white,.9),color:y.palette.common.black},component:"span","aria-live":"polite",children:"ao vivo"})}),g.jsxs(_.Box,{className:Ae.controlsOverlay,sx:{opacity:E?1:0,visibility:E?"visible":"hidden",transition:"opacity 0.3s ease, visibility 0.3s ease"},children:[S&&g.jsx(_.Box,{className:Ae.timeline,children:g.jsx(_.Slider,{size:"small",min:0,max:an?I:1,step:1,value:an?Q:0,disabled:!an,onChange:he,onChangeCommitted:D,"aria-label":"Linha do tempo do video",sx:{color:y.palette.common.white,"& .MuiSlider-thumb":{width:12,height:12,backgroundColor:y.palette.common.white},"& .MuiSlider-track":{border:"none",backgroundColor:y.palette.common.white},"& .MuiSlider-rail":{backgroundColor:Y.alpha(y.palette.common.white,.3),opacity:1}}})}),g.jsxs(_.Box,{className:Ae.controlsRow,children:[g.jsxs(_.Box,{className:Ae.controlGroup,children:[g.jsx(_.Box,{className:Ae.liveBadge,sx:{backgroundColor:q?Y.alpha(y.palette.common.white,.9):Y.alpha(y.palette.common.white,.15),color:q?y.palette.common.black:Y.alpha(y.palette.common.white,.7)},component:"span","aria-live":"polite",children:"ao vivo"}),g.jsx(_.Box,{className:Ae.seekButton,component:"button",onClick:()=>z(-15),"aria-label":"Voltar 15 segundos",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,border:"none",cursor:"pointer","&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:"15s"}),g.jsx(_.IconButton,{className:Ae.iconButton,onClick:()=>z(-15),"aria-label":"Recuar 15 segundos",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:g.jsx(Ve.FastRewind,{fontSize:"small"})}),g.jsx(_.IconButton,{className:Ae.iconButton,onClick:V,"aria-label":"Play/Pause",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:H?g.jsx(Ve.Pause,{fontSize:"small"}):g.jsx(Ve.PlayArrow,{fontSize:"small"})}),g.jsx(_.IconButton,{className:Ae.iconButton,onClick:()=>z(15),"aria-label":"Avançar 15 segundos",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:g.jsx(Ve.FastForward,{fontSize:"small"})}),g.jsx(_.Box,{className:Ae.seekButton,component:"button",onClick:()=>z(15),"aria-label":"Avançar 15 segundos",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,border:"none",cursor:"pointer","&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:"15s"})]}),g.jsxs(_.Box,{className:Ae.controlGroup,children:[g.jsx(_.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}}},children:g.jsx(_o,{label:"",valueLabel:sn,selectedValue:X,options:Xe,ariaLabel:"Selecionar velocidade de reprodução",onChange:R,disabled:!F})}),ft.length>0?g.jsx(_.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}}},children:g.jsx(_o,{label:"",valueLabel:qr,selectedValue:($==null?void 0:$.value)??"auto",options:ft,ariaLabel:"Selecionar qualidade do vídeo",onChange:K})}):null,g.jsx(_.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}}},children:g.jsx(_o,{label:"",valueLabel:on,selectedValue:w,options:Ee,ariaLabel:"Selecionar zoom do vídeo",onChange:j})}),g.jsx(_.IconButton,{className:Ae.iconButton,onClick:G,"aria-label":"Fullscreen",sx:{backgroundColor:Y.alpha(y.palette.common.white,.15),color:y.palette.common.white,"&:hover":{backgroundColor:Y.alpha(y.palette.common.white,.25)}},children:k?g.jsx(Ve.FullscreenExit,{fontSize:"small"}):g.jsx(Ve.Fullscreen,{fontSize:"small"})})]})]})]})]})};ed.displayName="VideoPlayer";const iS=dt(g.jsx("path",{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8"}),"UndoOutlined"),aS=dt(g.jsx("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6z"}),"Add"),cS=dt(g.jsx("path",{d:"M19 13H5v-2h14z"}),"Remove"),lS="_root_1gj5n_1",uS="_container_1gj5n_6",dS="_header_1gj5n_13",fS="_headerText_1gj5n_21",hS="_controls_1gj5n_27",pS="_iconButton_1gj5n_34",mS="_zoomGroup_1gj5n_43",gS="_zoomTrack_1gj5n_52",yS="_zoomTrackFill_1gj5n_59",vS="_layers_1gj5n_67",bS="_timeScale_1gj5n_78",xS="_videoTrack_1gj5n_82",SS="_eventsTrack_1gj5n_86",TS="_trackBox_1gj5n_90",wS="_trackLabelRow_1gj5n_95",CS="_label_1gj5n_103",_S="_trackArea_1gj5n_112",ES="_tick_1gj5n_118",PS="_tickMajor_1gj5n_126",AS="_tickMinor_1gj5n_131",MS="_tickLabel_1gj5n_135",kS="_segment_1gj5n_146",RS="_event_1gj5n_86",OS="_eventDot_1gj5n_166",IS="_selectionOverlay_1gj5n_172",jS="_playhead_1gj5n_180",LS="_playheadLine_1gj5n_190",DS="_playheadHandle_1gj5n_199",J={root:lS,container:uS,header:dS,headerText:fS,controls:hS,iconButton:pS,zoomGroup:mS,zoomTrack:gS,zoomTrackFill:yS,layers:vS,timeScale:bS,videoTrack:xS,eventsTrack:SS,trackBox:TS,trackLabelRow:wS,label:CS,trackArea:_S,tick:ES,tickMajor:PS,tickMinor:AS,tickLabel:MS,segment:kS,event:RS,eventDot:OS,selectionOverlay:IS,playhead:jS,playheadLine:LS,playheadHandle:DS},at={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1};function td(e){return"init"in e}function cs(e){return!!e.write}function dc(e){return"v"in e||"e"in e}function Ar(e){if("e"in e)throw e.e;if((at?"production":void 0)!=="production"&&!("v"in e))throw new Error("[Bug] atom state is not initialized");return e.v}const Mr=new WeakMap;function nd(e){var t;return kr(e)&&!!((t=Mr.get(e))!=null&&t[0])}function $S(e){const t=Mr.get(e);t!=null&&t[0]&&(t[0]=!1,t[1].forEach(n=>n()))}function ls(e,t){let n=Mr.get(e);if(!n){n=[!0,new Set],Mr.set(e,n);const r=()=>{n[0]=!1};e.then(r,r)}n[1].add(t)}function kr(e){return typeof(e==null?void 0:e.then)=="function"}function rd(e,t,n){if(!n.p.has(e)){n.p.add(e);const r=()=>n.p.delete(e);t.then(r,r)}}function od(e,t,n){var r;const o=new Set;for(const s of((r=n.get(e))==null?void 0:r.t)||[])o.add(s);for(const s of t.p)o.add(s);return o}const VS=(e,t,...n)=>t.read(...n),NS=(e,t,...n)=>t.write(...n),BS=(e,t)=>{if(t.INTERNAL_onInit)return t.INTERNAL_onInit(e);if(t.unstable_onInit)return console.warn("[DEPRECATED] atom.unstable_onInit is renamed to atom.INTERNAL_onInit."),t.unstable_onInit(e)},FS=(e,t,n)=>{var r;return(r=t.onMount)==null?void 0:r.call(t,n)},zS=(e,t)=>{var n;const r=Ie(e),o=r[0],s=r[6],i=r[9];if((at?"production":void 0)!=="production"&&!t)throw new Error("Atom is undefined or null");let a=o.get(t);return a||(a={d:new Map,p:new Set,n:0},o.set(t,a),(n=s.i)==null||n.call(s,t),i==null||i(e,t)),a},WS=e=>{const t=Ie(e),n=t[1],r=t[3],o=t[4],s=t[5],i=t[6],a=t[13],c=[],u=l=>{try{l()}catch(d){c.push(d)}};do{i.f&&u(i.f);const l=new Set,d=l.add.bind(l);r.forEach(f=>{var p;return(p=n.get(f))==null?void 0:p.l.forEach(d)}),r.clear(),s.forEach(d),s.clear(),o.forEach(d),o.clear(),l.forEach(u),r.size&&a(e)}while(r.size||s.size||o.size);if(c.length)throw new AggregateError(c)},US=e=>{const t=Ie(e),n=t[1],r=t[2],o=t[3],s=t[11],i=t[14],a=t[17],c=[],u=new WeakSet,l=new WeakSet,d=Array.from(o);for(;d.length;){const f=d[d.length-1],p=s(e,f);if(l.has(f)){d.pop();continue}if(u.has(f)){if(r.get(f)===p.n)c.push([f,p]);else if((at?"production":void 0)!=="production"&&r.has(f))throw new Error("[Bug] invalidated atom exists");l.add(f),d.pop();continue}u.add(f);for(const m of od(f,p,n))u.has(m)||d.push(m)}for(let f=c.length-1;f>=0;--f){const[p,m]=c[f];let h=!1;for(const v of m.d.keys())if(v!==p&&o.has(v)){h=!0;break}h&&(i(e,p),a(e,p)),r.delete(p)}},us=new WeakSet,HS=(e,t)=>{var n,r;const o=Ie(e),s=o[1],i=o[2],a=o[3],c=o[6],u=o[7],l=o[11],d=o[12],f=o[13],p=o[14],m=o[16],h=o[17],v=o[20],b=l(e,t);if(dc(b)){if(s.has(t)&&i.get(t)!==b.n)return b;let M=!1;for(const[L,$]of b.d)if(p(e,L).n!==$){M=!0;break}if(!M)return b}b.d.clear();let S=!0;function y(){s.has(t)&&(h(e,t),f(e),d(e))}function C(M){var L;if(M===t){const W=l(e,M);if(!dc(W))if(td(M))v(e,M,M.init);else throw new Error("no atom init");return Ar(W)}const $=p(e,M);try{return Ar($)}finally{b.d.set(M,$.n),nd(b.v)&&rd(t,b.v,$),s.has(t)&&((L=s.get(M))==null||L.t.add(t)),S||y()}}let T,E;const P={get signal(){return T||(T=new AbortController),T.signal},get setSelf(){return(at?"production":void 0)!=="production"&&!cs(t)&&console.warn("setSelf function cannot be used with read-only atom"),!E&&cs(t)&&(E=(...M)=>{if((at?"production":void 0)!=="production"&&S&&console.warn("setSelf function cannot be called in sync"),!S)try{return m(e,t,...M)}finally{f(e),d(e)}}),E}},A=b.n;try{(at?"production":void 0)!=="production"&&us.delete(e);const M=u(e,t,C,P);return(at?"production":void 0)!=="production"&&us.has(e)&&console.warn("Detected store mutation during atom read. This is not supported."),v(e,t,M),kr(M)&&(ls(M,()=>T==null?void 0:T.abort()),M.then(y,y)),(n=c.r)==null||n.call(c,t),b}catch(M){return delete b.v,b.e=M,++b.n,b}finally{S=!1,A!==b.n&&i.get(t)===A&&(i.set(t,b.n),a.add(t),(r=c.c)==null||r.call(c,t))}},GS=(e,t)=>{const n=Ie(e),r=n[1],o=n[2],s=n[11],i=[t];for(;i.length;){const a=i.pop(),c=s(e,a);for(const u of od(a,c,r)){const l=s(e,u);o.set(u,l.n),i.push(u)}}},KS=(e,t,...n)=>{const r=Ie(e),o=r[3],s=r[6],i=r[8],a=r[11],c=r[12],u=r[13],l=r[14],d=r[15],f=r[16],p=r[17],m=r[20];let h=!0;const v=S=>Ar(l(e,S)),b=(S,...y)=>{var C;const T=a(e,S);try{if(S===t){if(!td(S))throw new Error("atom not writable");(at?"production":void 0)!=="production"&&us.add(e);const E=T.n,P=y[0];m(e,S,P),p(e,S),E!==T.n&&(o.add(S),d(e,S),(C=s.c)==null||C.call(s,S));return}else return f(e,S,...y)}finally{h||(u(e),c(e))}};try{return i(e,t,v,b,...n)}finally{h=!1}},YS=(e,t)=>{var n;const r=Ie(e),o=r[1],s=r[3],i=r[6],a=r[11],c=r[15],u=r[18],l=r[19],d=a(e,t),f=o.get(t);if(f&&!nd(d.v)){for(const[p,m]of d.d)if(!f.d.has(p)){const h=a(e,p);u(e,p).t.add(t),f.d.add(p),m!==h.n&&(s.add(p),c(e,p),(n=i.c)==null||n.call(i,p))}for(const p of f.d)if(!d.d.has(p)){f.d.delete(p);const m=l(e,p);m==null||m.t.delete(t)}}},qS=(e,t)=>{var n;const r=Ie(e),o=r[1],s=r[4],i=r[6],a=r[10],c=r[11],u=r[12],l=r[13],d=r[14],f=r[16],p=r[18],m=c(e,t);let h=o.get(t);if(!h){d(e,t);for(const v of m.d.keys())p(e,v).t.add(t);if(h={l:new Set,d:new Set(m.d.keys()),t:new Set},o.set(t,h),cs(t)){const v=()=>{let b=!0;const S=(...y)=>{try{return f(e,t,...y)}finally{b||(l(e),u(e))}};try{const y=a(e,t,S);y&&(h.u=()=>{b=!0;try{y()}finally{b=!1}})}finally{b=!1}};s.add(v)}(n=i.m)==null||n.call(i,t)}return h},ZS=(e,t)=>{var n,r;const o=Ie(e),s=o[1],i=o[5],a=o[6],c=o[11],u=o[19],l=c(e,t);let d=s.get(t);if(!d||d.l.size)return d;let f=!1;for(const p of d.t)if((n=s.get(p))!=null&&n.d.has(t)){f=!0;break}if(!f){d.u&&i.add(d.u),d=void 0,s.delete(t);for(const p of l.d.keys()){const m=u(e,p);m==null||m.t.delete(t)}(r=a.u)==null||r.call(a,t);return}return d},XS=(e,t,n)=>{const r=Ie(e)[11],o=r(e,t),s="v"in o,i=o.v;if(kr(n))for(const a of o.d.keys())rd(t,n,r(e,a));o.v=n,delete o.e,(!s||!Object.is(i,o.v))&&(++o.n,kr(i)&&$S(i))},JS=(e,t)=>{const n=Ie(e)[14];return Ar(n(e,t))},QS=(e,t,...n)=>{const r=Ie(e),o=r[12],s=r[13],i=r[16];try{return i(e,t,...n)}finally{s(e),o(e)}},e2=(e,t,n)=>{const r=Ie(e),o=r[12],s=r[18],i=r[19],c=s(e,t).l;return c.add(n),o(e),()=>{c.delete(n),i(e,t),o(e)}},sd=new WeakMap,Ie=e=>{const t=sd.get(e);if((at?"production":void 0)!=="production"&&!t)throw new Error("Store must be created by buildStore to read its building blocks");return t};function t2(...e){const t={get(r){const o=Ie(t)[21];return o(t,r)},set(r,...o){const s=Ie(t)[22];return s(t,r,...o)},sub(r,o){const s=Ie(t)[23];return s(t,r,o)}},n=[new WeakMap,new WeakMap,new WeakMap,new Set,new Set,new Set,{},VS,NS,BS,FS,zS,WS,US,HS,GS,KS,YS,qS,ZS,XS,JS,QS,e2,void 0].map((r,o)=>e[o]||r);return sd.set(t,Object.freeze(n)),t}const id={};let n2=0;function rn(e,t){const n=`atom${++n2}`,r={toString(){return(id?"production":void 0)!=="production"&&this.debugLabel?n+":"+this.debugLabel:n}};return typeof e=="function"?r.read=e:(r.init=e,r.read=r2,r.write=o2),r}function r2(e){return e(this)}function o2(e,t,n){return t(this,typeof n=="function"?n(e(this)):n)}function s2(){return t2()}let pn;function i2(){return pn||(pn=s2(),(id?"production":void 0)!=="production"&&(globalThis.__JOTAI_DEFAULT_STORE__||(globalThis.__JOTAI_DEFAULT_STORE__=pn),globalThis.__JOTAI_DEFAULT_STORE__!==pn&&console.warn("Detected multiple Jotai instances. It may cause unexpected behavior with the default store. https://github.com/pmndrs/jotai/discussions/2044"))),pn}const a2={},c2=x.createContext(void 0);function ad(e){return x.useContext(c2)||i2()}const ds=e=>typeof(e==null?void 0:e.then)=="function",fs=e=>{e.status||(e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}))},l2=x.use||(e=>{if(e.status==="pending")throw e;if(e.status==="fulfilled")return e.value;throw e.status==="rejected"?e.reason:(fs(e),e)}),Eo=new WeakMap,fc=(e,t)=>{let n=Eo.get(e);return n||(n=new Promise((r,o)=>{let s=e;const i=u=>l=>{s===u&&r(l)},a=u=>l=>{s===u&&o(l)},c=()=>{try{const u=t();ds(u)?(Eo.set(u,n),s=u,u.then(i(u),a(u)),ls(u,c)):r(u)}catch(u){o(u)}};e.then(i(e),a(e)),ls(e,c)}),Eo.set(e,n)),n};function Rr(e,t){const{delay:n,unstable_promiseStatus:r=!x.use}={},o=ad(),[[s,i,a],c]=x.useReducer(l=>{const d=o.get(e);return Object.is(l[0],d)&&l[1]===o&&l[2]===e?l:[d,o,e]},void 0,()=>[o.get(e),o,e]);let u=s;if((i!==o||a!==e)&&(c(),u=o.get(e)),x.useEffect(()=>{const l=o.sub(e,()=>{if(r)try{const d=o.get(e);ds(d)&&fs(fc(d,()=>o.get(e)))}catch{}if(typeof n=="number"){setTimeout(c,n);return}c()});return c(),l},[o,e,n,r]),x.useDebugValue(u),ds(u)){const l=fc(u,()=>o.get(e));return r&&fs(l),l2(l)}return u}function u2(e,t){const n=ad();return x.useCallback((...o)=>{if((a2?"production":void 0)!=="production"&&!("write"in e))throw new Error("not writable atom");return n.set(e,...o)},[n,e])}function Wt(e,t){return[Rr(e),u2(e)]}const si=rn(0),ii=rn(!0),ai=rn(null),cd=rn({windowSeconds:24*60*60,fps:30}),ld=rn([]),ud=rn([]);function ve(e,t,n){return Math.min(n,Math.max(t,e))}function yt(e){const{time:t,windowStart:n,windowSeconds:r,width:o}=e;return o<=0||r<=0?0:(t-n)/r*o}function mn(e){const{px:t,windowStart:n,windowSeconds:r,width:o}=e;return o<=0||r<=0?n:n+t/o*r}function _e(e){return String(Math.floor(e)).padStart(2,"0")}function d2(e=Date.now()){const t=new Date(e);return t.getHours()*3600+t.getMinutes()*60+t.getSeconds()+t.getMilliseconds()/1e3}function Po(e){const t=Math.max(0,e),n=Math.floor(t/3600)%24,r=Math.floor(t%3600/60),o=Math.floor(t%60);return`${_e(n)}:${_e(r)}:${_e(o)}`}function f2(e,t){const n=Math.max(0,e),r=Math.floor(n/3600)%24,o=Math.floor(n%3600/60),s=Math.floor(n%60),i=n-Math.floor(n),a=Math.floor(i*t);return`${_e(r)}:${_e(o)}:${_e(s)}:${_e(a)}`}function Ao(e){const t=Math.max(0,e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),o=Math.floor(t%60);return n>0?`${_e(n)}:${_e(r)}:${_e(o)}`:`${_e(r)}:${_e(o)}`}function h2(e,t){const n=Math.max(0,e),r=Math.floor(n/3600),o=Math.floor(n%3600/60),s=Math.floor(n%60),i=n-Math.floor(n),a=Math.floor(i*t);return r>0?`${_e(r)}:${_e(o)}:${_e(s)}:${_e(a)}`:`${_e(o)}:${_e(s)}:${_e(a)}`}function p2(e){const{width:t,windowSeconds:n,fps:r}=e,o=t>0?t/n:0,s=1/Math.max(1,r),i=[s,2*s,5*s,.25,.5,1,2,5,10,15,30,60,2*60,5*60,10*60,15*60,30*60,60*60,2*60*60,3*60*60,6*60*60],a=90,c=45;let u=i[i.length-1];for(const f of i)if(f*o>=a){u=f;break}const l=[u/2,u/5,u/10].filter(f=>f>0);let d=l[0]??u;for(const f of l)if(f*o>=c){d=f;break}return{majorStep:u,minorStep:d}}const m2=(e,t,n)=>t>=3600?Po(e).slice(0,2)+":00:00":t>=60?Po(e).slice(0,5):t>=1?Po(e):f2(e,n),g2=(e,t,n)=>t>=3600||t>=60||t>=1?Ao(e):h2(e,n);function y2(){const e=x.useRef(null),[t,n]=x.useState(0);return x.useLayoutEffect(()=>{const r=e.current;if(!r)return;const o=new ResizeObserver(()=>{n(r.getBoundingClientRect().width)});return o.observe(r),n(r.getBoundingClientRect().width),()=>o.disconnect()},[]),{ref:e,width:t}}function v2(e){const{totalSeconds:t,enableWheelZoom:n,autoZoomOnSelection:r,tickLabelFormatter:o,clearSelectionOnEventClick:s}=e,[i,a]=Wt(si),[c,u]=Wt(ii),[l,d]=Wt(ai),f=Rr(ld),p=Rr(ud),[m,h]=Wt(cd),{ref:v,width:b}=y2(),S=102,C=Math.max(0,b-S-10),[T,E]=x.useState(0),P=x.useMemo(()=>{const k=Math.max(1/Math.max(1,m.fps),.05);return ve(m.windowSeconds,k,t)},[m.windowSeconds,m.fps,t]);x.useEffect(()=>{if(!c||b<=0)return;const k=ve(i-P*.9,0,Math.max(0,t-P));E(k)},[i,c,b,P,t]);const A=x.useMemo(()=>{const k=ve(T,0,Math.max(0,t-P)),O=k+P;return{start:k,end:O,seconds:P}},[T,t,P]),M=x.useMemo(()=>{if(C<=0)return[];const{majorStep:k,minorStep:O}=p2({width:C,windowSeconds:A.seconds,fps:m.fps}),F=Math.floor(A.start/O)*O,N=A.end,V=[],z=O*1e-6;for(let G=F;G<=N+z;G+=O){const K=yt({time:G,windowStart:A.start,windowSeconds:A.seconds,width:C});if(K<-1||K>C+1)continue;const he=Math.abs(G/k-Math.round(G/k))<1e-6;V.push({time:G,px:K,kind:he?"major":"minor",label:he?o(G,k,m.fps):void 0})}return V},[C,o,A.end,A.seconds,A.start,m.fps]),L=x.useRef(null),$=x.useRef(null),W=k=>{$.current=k,L.current==null&&(L.current=requestAnimationFrame(()=>{L.current=null;const O=$.current;$.current=null,O==null||O()}))};x.useEffect(()=>()=>{L.current!=null&&cancelAnimationFrame(L.current)},[]);const H=x.useRef(null),q=k=>{const O=v.current;if(!O)return 0;const F=O.getBoundingClientRect();return ve(k-F.left-S,0,C)};return{viewportRef:v,width:b,axisLeft:S,axisWidth:C,totalSeconds:t,zoom:m,setZoom:h,isLive:c,setIsLive:u,currentTime:i,selectedRange:l,setSelectedRange:d,videoSegments:f,events:p,view:A,ticks:M,onWheel:k=>{if(!n||b<=0)return;k.preventDefault(),u(!1);const O=q(k.clientX),F=ve(mn({px:O,windowStart:A.start,windowSeconds:A.seconds,width:C}),0,t),V=k.deltaY<0?.8:1.25,z=ve(A.seconds*V,Math.max(1/Math.max(1,m.fps),.05),t),G=ve(F-O/Math.max(1,C)*z,0,Math.max(0,t-z));h(K=>({...K,windowSeconds:z})),E(G)},onPointerDownScrub:k=>{if(k.button!==0)return;const O=v.current;if(!O)return;O.setPointerCapture(k.pointerId);const F=q(k.clientX),N=ve(mn({px:F,windowStart:A.start,windowSeconds:A.seconds,width:C}),0,t);u(!1),H.current={mode:"playhead",pointerId:k.pointerId,startPx:F,startTime:N},a(N)},onPointerDownSelect:k=>{if(k.button!==0)return;const O=v.current;if(!O)return;O.setPointerCapture(k.pointerId);const F=q(k.clientX),N=ve(mn({px:F,windowStart:A.start,windowSeconds:A.seconds,width:C}),0,t);u(!1),H.current={mode:"select",pointerId:k.pointerId,startPx:F,startTime:N},d({start:N,end:N})},onPointerDownPlayhead:k=>{if(k.button!==0)return;const O=v.current;if(!O)return;O.setPointerCapture(k.pointerId);const F=q(k.clientX),N=ve(mn({px:F,windowStart:A.start,windowSeconds:A.seconds,width:C}),0,t);u(!1),H.current={mode:"playhead",pointerId:k.pointerId,startPx:F,startTime:N},a(N)},onPointerMove:k=>{const O=H.current;if(!O||O.pointerId!==k.pointerId)return;const F=q(k.clientX);W(()=>{const N=ve(mn({px:F,windowStart:A.start,windowSeconds:A.seconds,width:C}),0,t);if(O.mode==="playhead")a(N);else{const V=Math.min(O.startTime,N),z=Math.max(O.startTime,N);d({start:V,end:z})}})},onPointerUp:k=>{const O=H.current;if(!(!O||O.pointerId!==k.pointerId)&&(H.current=null,O.mode==="select"&&l)){const F=Math.abs(l.end-l.start);if(F<Math.max(1/Math.max(1,m.fps),.1))d(null);else if(r){const N=ve(F*1.05,Math.max(1/Math.max(1,m.fps),.05),t),V=ve(l.start,0,Math.max(0,t-N));h(z=>({...z,windowSeconds:N})),E(V)}}},onClickEvent:k=>{s&&d(null),u(!1),a(ve(k,0,t)),E(ve(k-A.seconds/2,0,Math.max(0,t-A.seconds)))},resetView:()=>{u(!1),h(k=>({...k,windowSeconds:t})),E(0)}}}const dd=({ticks:e,tickColor:t,labelColor:n})=>g.jsx("div",{className:J.trackArea,children:e.map(r=>g.jsxs("div",{children:[g.jsx("div",{className:`${J.tick} ${r.kind==="minor"?J.tickMinor:J.tickMajor}`.trim(),style:{left:`${r.px}px`,backgroundColor:t}}),r.kind==="major"&&r.label?g.jsx("div",{className:J.tickLabel,style:{left:`${r.px}px`,color:n},children:r.label}):null]},`${r.time}-${r.kind}`))});dd.displayName="TimeScale";const fd=({segments:e,viewStart:t,viewSeconds:n,width:r,totalSeconds:o,segmentColor:s,segmentColorHover:i})=>{const a=e.map(c=>({start:ve(c.start,0,o),end:ve(c.end,0,o)})).filter(c=>c.end>c.start).map(c=>{const u=Math.max(c.start,t),l=Math.min(c.end,t+n);return{start:u,end:l}}).filter(c=>c.end>c.start);return g.jsx("div",{className:J.trackArea,children:a.map((c,u)=>{const l=yt({time:c.start,windowStart:t,windowSeconds:n,width:r}),d=yt({time:c.end,windowStart:t,windowSeconds:n,width:r}),f=Math.max(0,d-l);return g.jsx("div",{className:J.segment,style:{left:`${l}px`,width:`${f}px`,background:s},onMouseEnter:p=>{p.currentTarget.style.background=i},onMouseLeave:p=>{p.currentTarget.style.background=s},"aria-hidden":!0},`${c.start}-${c.end}-${u}`)})})};fd.displayName="VideoTrack";const hd=({events:e,viewStart:t,viewSeconds:n,width:r,totalSeconds:o,onClickEvent:s,eventBg:i,eventBgHover:a,eventDot:c})=>{const u=e.map(l=>({...l,time:ve(l.time,0,o)})).filter(l=>l.time>=t&&l.time<=t+n);return g.jsx("div",{className:J.trackArea,children:u.map(l=>{const d=yt({time:l.time,windowStart:t,windowSeconds:n,width:r});return g.jsx("button",{type:"button",className:J.event,onPointerDown:f=>{f.stopPropagation()},onClick:()=>s(l.time),style:{left:`${d}px`,backgroundColor:i,border:"none",padding:0},onMouseEnter:f=>{f.currentTarget.style.backgroundColor=a},onMouseLeave:f=>{f.currentTarget.style.backgroundColor=i},"aria-label":`Evento em ${l.time.toFixed(2)}s`,children:l.icon?l.icon:g.jsx("span",{className:J.eventDot,style:{backgroundColor:c}})},l.id)})})};hd.displayName="EventsTrack";const pd=({className:e,title:t="Timeline",subtitle:n="Arraste para selecionar e aplicar zoom no período desejado",showHeader:r=!0,timeScaleMode:o="day24h",tickLabelFormatter:s,totalSeconds:i=24*60*60,enableWheelZoom:a=!0,height:c=190,autoZoomOnSelection:u=!0,showZoomControls:l=!0,enableScrubOnTracks:d=!1,clearSelectionOnEventClick:f=!0})=>{const p=Y.useTheme(),m=s??(o==="duration"?g2:m2),{viewportRef:h,axisLeft:v,axisWidth:b,zoom:S,currentTime:y,selectedRange:C,videoSegments:T,events:E,view:P,ticks:A,onWheel:M,onPointerDownScrub:L,onPointerDownSelect:$,onPointerDownPlayhead:W,onPointerMove:H,onPointerUp:q,onClickEvent:oe,resetView:Q,setZoom:U}=v2({totalSeconds:i,enableWheelZoom:a,autoZoomOnSelection:u,tickLabelFormatter:m,clearSelectionOnEventClick:f}),I=b?v+yt({time:y,windowStart:P.start,windowSeconds:P.seconds,width:b}):v,X=p.palette.common.white,R=Y.alpha(p.palette.common.black,.16),w="0px 4px 5.3px 0px rgba(0,0,0,0.16)",j=p.palette.mode==="dark"?Y.alpha(p.palette.common.white,.7):"#79747e",k=Y.alpha(p.palette.common.black,.16),O="#2c2c2c",F=Y.alpha(p.palette.primary.main,.15),N=Y.alpha(p.palette.primary.main,.22),V=Y.alpha(p.palette.common.white,1),z=Y.alpha(p.palette.common.white,1),G=Y.alpha(p.palette.common.black,.55),K=Y.alpha(p.palette.primary.main,.12),he=p.palette.primary.main,D=Math.max(1/Math.max(1,S.fps),.5),Ee=D/i,Xe=(()=>{const on=ve(P.seconds,D,i);if(Ee<=0||Ee>=1)return 0;const sn=Math.log(on/i)/Math.log(Ee)*100;return ve(sn,0,100)})(),ft=on=>{const sn=ve(on,0,100),an=i*Math.pow(Ee,sn/100);U(Zr=>({...Zr,windowSeconds:ve(an,D,i)}))},qr=`${Math.round(Xe)}%`;return g.jsxs(_.Box,{className:`${J.root} ${J.container} ${e??""}`.trim(),sx:{backgroundColor:X,border:`1px solid ${R}`,boxShadow:w,px:1,py:2},children:[r?g.jsxs("div",{className:J.header,children:[g.jsxs("div",{className:J.headerText,children:[g.jsx(_.Typography,{variant:"subtitle1",sx:{color:j,fontWeight:500},children:t}),g.jsx(_.Typography,{variant:"body2",sx:{color:j},children:n})]}),l?g.jsxs("div",{className:J.controls,children:[g.jsx(_.Box,{className:J.iconButton,sx:{border:`1px solid ${Y.alpha(p.palette.common.black,.22)}`},children:g.jsx(_.IconButton,{size:"small",onClick:Q,"aria-label":"Reset zoom",sx:{width:32,height:32},children:g.jsx(iS,{fontSize:"small"})})}),g.jsxs(_.Box,{className:J.zoomGroup,sx:{backgroundColor:p.palette.common.white,border:`1px solid ${Y.alpha(p.palette.common.black,.22)}`},"aria-label":"Zoom controls",children:[g.jsx(_.IconButton,{size:"small","aria-label":"Zoom out",onClick:()=>ft(Xe-10),children:g.jsx(cS,{fontSize:"small"})}),g.jsxs("div",{className:J.zoomTrack,"aria-hidden":!0,children:[g.jsx("div",{style:{position:"absolute",inset:0,backgroundColor:Y.alpha("#f5f5f5",.3),borderRadius:1,boxShadow:"1px 1px 1px rgba(10,10,10,0.04)"}}),g.jsx("div",{className:J.zoomTrackFill,style:{width:qr,backgroundColor:"#f5f5f5",boxShadow:"1px 1px 1px rgba(10,10,10,0.04)"}})]}),g.jsx(_.IconButton,{size:"small","aria-label":"Zoom in",onClick:()=>ft(Xe+10),children:g.jsx(aS,{fontSize:"small"})})]})]}):null]}):null,g.jsx(_.Box,{sx:{mt:r?2:0,height:c},children:g.jsxs("div",{ref:h,className:J.layers,onWheel:M,onPointerMove:H,onPointerUp:q,children:[g.jsxs("div",{className:J.playhead,style:{left:`${I}px`},onPointerDown:W,role:"slider","aria-label":"Playhead","aria-valuemin":0,"aria-valuemax":i,"aria-valuenow":y,tabIndex:0,children:[g.jsx("div",{className:J.playheadHandle,style:{borderBottomColor:he}}),g.jsx("div",{className:J.playheadLine,style:{backgroundColor:he}})]}),g.jsxs("div",{className:`${J.trackLabelRow} ${J.timeScale}`.trim(),children:[g.jsx("div",{}),g.jsx("div",{onPointerDown:L,style:{height:"100%",cursor:"ew-resize"},"aria-label":"Régua do tempo",children:g.jsx(dd,{ticks:A,tickColor:k,labelColor:O})})]}),g.jsxs(_.Box,{className:J.trackBox,sx:{mt:1,border:`1px solid ${Y.alpha(p.palette.common.black,.1)}`,borderRadius:"12px",height:106,position:"relative"},children:[C?g.jsx("div",{className:J.selectionOverlay,style:{left:`${v+yt({time:C.start,windowStart:P.start,windowSeconds:P.seconds,width:b})}px`,width:`${Math.max(0,yt({time:C.end,windowStart:P.start,windowSeconds:P.seconds,width:b})-yt({time:C.start,windowStart:P.start,windowSeconds:P.seconds,width:b}))}px`,backgroundColor:K}}):null,g.jsxs("div",{className:`${J.trackLabelRow} ${J.videoTrack}`.trim(),children:[g.jsx("div",{className:J.label,style:{color:j},children:"Video"}),g.jsx("div",{onPointerDown:d?L:void 0,style:{height:"100%"},children:g.jsx(fd,{segments:T,viewStart:P.start,viewSeconds:P.seconds,width:b,totalSeconds:i,segmentColor:F,segmentColorHover:N})})]}),g.jsxs("div",{className:`${J.trackLabelRow} ${J.eventsTrack}`.trim(),children:[g.jsx("div",{className:J.label,style:{color:j},children:"Eventos"}),g.jsx("div",{onPointerDown:d?L:void 0,style:{height:"100%"},children:g.jsx(hd,{events:E,viewStart:P.start,viewSeconds:P.seconds,width:b,totalSeconds:i,onClickEvent:oe,eventBg:V,eventBgHover:z,eventDot:G})})]}),g.jsx("div",{onPointerDown:$,style:{position:"absolute",left:v,right:10,top:0,bottom:0,cursor:"crosshair"},"aria-label":"Arraste para selecionar"})]})]})})]})};pd.displayName="VideoTimeline";const md=({stream:e=null,src:t,autoPlay:n=!0,muted:r=!0,playsInline:o=!0,className:s,liveEdgeThresholdSeconds:i=2,updateTimeForLiveStream:a=!0,constrainToSelectedRange:c=!0,loopSelection:u=!1})=>{const l=x.useRef(null),[d,f]=Wt(si),[p,m]=Wt(ii),h=Rr(ai),v=!!e;x.useEffect(()=>{const y=l.current;if(y){if(e){y.srcObject=e;return}y.srcObject=null,t&&(y.src=t)}},[e,t]),x.useEffect(()=>{const y=l.current;if(!y||v)return;const C=()=>{if(c&&h){const P=Math.max(0,h.start),A=Math.max(P,h.end);y.currentTime<P?y.currentTime=P:y.currentTime>A&&(u?y.currentTime=P:(y.pause(),y.currentTime=A))}if(f(y.currentTime),Number.isFinite(y.duration)&&y.duration>0){const P=y.duration-y.currentTime<=i;m(P)}},T=()=>{if(!c||!h)return;const P=Math.max(0,h.start),A=Math.max(P,h.end);(y.currentTime<P||y.currentTime>A)&&(y.currentTime=P)},E=()=>{p&&Number.isFinite(y.duration)&&y.duration>0&&(y.currentTime=y.duration)};return y.addEventListener("timeupdate",C),y.addEventListener("play",T),y.addEventListener("loadedmetadata",E),()=>{y.removeEventListener("timeupdate",C),y.removeEventListener("play",T),y.removeEventListener("loadedmetadata",E)}},[c,v,p,i,u,h,f,m]);const b=x.useRef(-1);x.useEffect(()=>{const y=l.current;if(!y||v||!t)return;if(p){if(Number.isFinite(y.duration)&&y.duration>0){const T=y.duration;Math.abs(y.currentTime-T)>.25&&(y.currentTime=T,b.current=T)}return}if(Math.abs(b.current-d)<.05)return;let C=d;if(c&&h){const T=Math.max(0,h.start),E=Math.max(T,h.end);C=Math.min(E,Math.max(T,C))}Math.abs(y.currentTime-C)>.25&&(y.currentTime=C,b.current=d)},[c,d,p,v,h,t]),x.useEffect(()=>{const y=l.current;if(!y||v||!t||!c||!h)return;const C=Math.max(0,h.start),T=!y.paused;y.currentTime=C,b.current=C,m(!1),f(C),T&&y.play().catch(()=>{})},[c,v,h,f,m,t]),x.useEffect(()=>{if(!v||(m(!0),!a))return;let y=null,C=!0;const T=()=>{C&&(f(d2()),y=requestAnimationFrame(T))};return y=requestAnimationFrame(T),()=>{C=!1,y!=null&&cancelAnimationFrame(y)}},[v,f,m,a]);const S=x.useMemo(()=>({width:"100%",maxWidth:920,background:"black",aspectRatio:"16 / 9",display:"block"}),[]);return g.jsx("video",{ref:l,className:s,style:S,autoPlay:n,muted:r,playsInline:o,controls:!0})};md.displayName="VideoPlayerWebRTC";const b2=dt(g.jsx("path",{d:"M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"}),"Done"),x2="_container_1vjy6_1",S2="_segment_1vjy6_7",T2="_selected_1vjy6_20",w2="_label_1vjy6_28",C2="_icon_1vjy6_37",_2="_checkIcon_1vjy6_47",E2="_unselected_1vjy6_53",Et={container:x2,segment:S2,selected:T2,label:w2,icon:C2,checkIcon:_2,unselected:E2},gd=({items:e,className:t,sx:n,...r})=>{const s=_.useTheme().palette.mode==="dark",i=(a,c)=>{a.onClick?a.onClick(c):console.log(`Item "${a.label}" clicado`)};return g.jsx(_.Box,{className:`${Et.container} ${t||""}`,sx:n,"data-theme":s?"dark":"light",...r,children:e.map((a,c)=>g.jsxs(_.Box,{className:`${Et.segment} ${a.selected?Et.selected:Et.unselected}`,onClick:u=>i(a,u),children:[a.selected&&g.jsx(_.Box,{className:Et.icon,children:g.jsx(b2,{className:Et.checkIcon})}),g.jsx(_.Box,{className:Et.label,children:a.label})]},c))})};gd.displayName="DisplayTypes";exports.Button=hs;exports.CountCard=fg;exports.DisplayTypes=gd;exports.FilterButton=xc;exports.FilterChip=Sc;exports.FilterModal=Qc;exports.GoogleMap=ll;exports.MapContent=Cs;exports.MapMarkers=Yu;exports.MapSpot=ri;exports.ModuleMenu=Qu;exports.NotFoundContent=Zu;exports.SearchBar=qu;exports.SidebarMenu=Ju;exports.VideoPlayer=ed;exports.VideoPlayerWebRTC=md;exports.VideoTimeline=pd;exports.VisioThemeProvider=Md;exports.ZoomControls=bg;exports.currentTimeAtom=si;exports.darkColors=me;exports.darkTheme=yc;exports.eventsAtom=ud;exports.isLiveAtom=ii;exports.lightColors=pe;exports.lightTheme=gc;exports.radiiTokens=rr;exports.selectedRangeAtom=ai;exports.spacingScale=Ed;exports.spacingTokens=pc;exports.typographyTokens=Pe;exports.useGoogleMapContext=cl;exports.useVisioTheme=kd;exports.videoSegmentsAtom=ld;exports.zoomAtom=cd;
103
+ `),()=>{C.contains(w)&&C.removeChild(w)}},[t]),y.jsx(Ey,{isPresent:t,childRef:i,sizeRef:a,children:Ve.cloneElement(e,{ref:l})})}const My=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:o,presenceAffectsLayout:s,mode:i,anchorX:a,anchorY:c,root:u})=>{const l=gs(Py),d=x.useId();let f=!0,h=x.useMemo(()=>(f=!1,{id:d,initial:t,isPresent:n,custom:o,onExitComplete:p=>{l.set(p,!0);for(const m of l.values())if(!m)return;r&&r()},register:p=>(l.set(p,!1),()=>l.delete(p))}),[n,l,r]);return s&&f&&(h={...h}),x.useMemo(()=>{l.forEach((p,m)=>l.set(m,!1))},[n]),Ve.useEffect(()=>{!n&&!l.size&&r&&r()},[n]),i==="popLayout"&&(e=y.jsx(Ay,{isPresent:n,anchorX:a,anchorY:c,root:u,children:e})),y.jsx(Ir.Provider,{value:h,children:e})};function Py(){return new Map}function nu(e=!0){const t=x.useContext(Ir);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=t,s=x.useId();x.useEffect(()=>{if(e)return o(s)},[e]);const i=x.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,i]:[!0]}const Fn=e=>e.key||"";function ja(e){const t=[];return x.Children.forEach(e,n=>{x.isValidElement(n)&&t.push(n)}),t}const ky=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:s="sync",propagate:i=!1,anchorX:a="left",anchorY:c="top",root:u})=>{const[l,d]=nu(i),f=x.useMemo(()=>ja(e),[e]),h=i&&!l?[]:f.map(Fn),p=x.useRef(!0),m=x.useRef(f),v=gs(()=>new Map),S=x.useRef(new Set),[T,b]=x.useState(f),[w,C]=x.useState(f);Lc(()=>{p.current=!1,m.current=f;for(let M=0;M<w.length;M++){const I=Fn(w[M]);h.includes(I)?(v.delete(I),S.current.delete(I)):v.get(I)!==!0&&v.set(I,!1)}},[w,h.length,h.join("-")]);const E=[];if(f!==T){let M=[...f];for(let I=0;I<w.length;I++){const V=w[I],D=Fn(V);h.includes(D)||(M.splice(I,0,V),E.push(V))}return s==="wait"&&E.length&&(M=E),C(ja(M)),b(f),null}process.env.NODE_ENV!=="production"&&s==="wait"&&w.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=x.useContext(ps);return y.jsx(y.Fragment,{children:w.map(M=>{const I=Fn(M),V=i&&!l?!1:f===w||h.includes(I),D=()=>{if(S.current.has(I))return;if(S.current.add(I),v.has(I))v.set(I,!0);else return;let g=!0;v.forEach($=>{$||(g=!1)}),g&&(P==null||P(),C(m.current),i&&(d==null||d()),r&&r())};return y.jsx(My,{isPresent:V,initial:!p.current||n?void 0:!1,custom:t,presenceAffectsLayout:o,mode:s,root:u,onExitComplete:V?void 0:D,anchorX:a,anchorY:c,children:M},I)})})},ru=x.createContext({strict:!1}),Ba={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 $a=!1;function Iy(){if($a)return;const e={};for(const t in Ba)e[t]={isEnabled:n=>Ba[t].some(r=>!!n[r])};Rl(e),$a=!0}function ou(){return Iy(),g0()}function Ry(e){const t=ou();for(const n in e)t[n]={...t[n],...e[n]};Rl(t)}const Oy=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","ignoreStrict","viewport"]);function fr(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Oy.has(e)}let su=e=>!fr(e);function Ly(e){typeof e=="function"&&(su=t=>t.startsWith("on")?!fr(t):e(t))}try{Ly(require("@emotion/is-prop-valid").default)}catch{}function Dy(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(su(o)||n===!0&&fr(o)||!t&&!fr(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}const Lr=x.createContext({});function jy(e,t){if(Or(e)){const{initial:n,animate:r}=e;return{initial:n===!1||_n(n)?n:void 0,animate:_n(r)?r:void 0}}return e.inherit!==!1?t:{}}function By(e){const{initial:t,animate:n}=jy(e,x.useContext(Lr));return x.useMemo(()=>({initial:t,animate:n}),[Na(t),Na(n)])}function Na(e){return Array.isArray(e)?e.join(" "):e}const Hs=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function iu(e,t,n){for(const r in t)!Pe(t[r])&&!Nl(r,n)&&(e[r]=t[r])}function $y({transformTemplate:e},t){return x.useMemo(()=>{const n=Hs();return zs(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Ny(e,t){const n=e.style||{},r={};return iu(r,n,e),Object.assign(r,$y(e,t)),r}function Vy(e,t){const n={},r=Ny(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const au=()=>({...Hs(),attrs:{}});function Fy(e,t,n,r){const o=x.useMemo(()=>{const s=au();return Vl(s,t,zl(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};iu(s,e.style,e),o.style={...s,...o.style}}return o}const zy=["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 Gs(e){return typeof e!="string"||e.includes("-")?!1:!!(zy.indexOf(e)>-1||/[A-Z]/u.test(e))}function Wy(e,t,n,{latestValues:r},o,s=!1,i){const c=(i??Gs(e)?Fy:Vy)(t,r,o,e),u=Dy(t,typeof e=="string",s),l=e!==x.Fragment?{...u,...c,ref:n}:{},{children:d}=t,f=x.useMemo(()=>Pe(d)?d.get():d,[d]);return x.createElement(e,{...l,children:f})}function Uy({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,o){return{latestValues:Hy(n,r,o,e),renderState:t()}}function Hy(e,t,n,r){const o={},s=r(e,{});for(const f in s)o[f]=Jn(s[f]);let{initial:i,animate:a}=e;const c=Or(e),u=Il(e);t&&u&&!c&&e.inherit!==!1&&(i===void 0&&(i=t.initial),a===void 0&&(a=t.animate));let l=n?n.initial===!1:!1;l=l||i===!1;const d=l?a:i;if(d&&typeof d!="boolean"&&!Rr(d)){const f=Array.isArray(d)?d:[d];for(let h=0;h<f.length;h++){const p=Ds(e,f[h]);if(p){const{transitionEnd:m,transition:v,...S}=p;for(const T in S){let b=S[T];if(Array.isArray(b)){const w=l?b.length-1:0;b=b[w]}b!==null&&(o[T]=b)}for(const T in m)o[T]=m[T]}}}return o}const cu=e=>(t,n)=>{const r=x.useContext(Lr),o=x.useContext(Ir),s=()=>Uy(e,t,r,o);return n?s():gs(s)},Gy=cu({scrapeMotionValuesFromProps:Ws,createRenderState:Hs}),Ky=cu({scrapeMotionValuesFromProps:Wl,createRenderState:au}),Yy=Symbol.for("motionComponentSymbol");function Zy(e,t,n){const r=x.useRef(n);x.useInsertionEffect(()=>{r.current=n});const o=x.useRef(null);return x.useCallback(s=>{var a;s&&((a=e.onMount)==null||a.call(e,s)),t&&(s?t.mount(s):t.unmount());const i=r.current;if(typeof i=="function")if(s){const c=i(s);typeof c=="function"&&(o.current=c)}else o.current?(o.current(),o.current=null):i(s);else i&&(i.current=s)},[t])}const lu=x.createContext({});function pn(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function qy(e,t,n,r,o,s){var S,T;const{visualElement:i}=x.useContext(Lr),a=x.useContext(ru),c=x.useContext(Ir),u=x.useContext(Us).reducedMotion,l=x.useRef(null),d=x.useRef(!1);r=r||a.renderer,!l.current&&r&&(l.current=r(e,{visualState:t,parent:i,props:n,presenceContext:c,blockInitialAnimation:c?c.initial===!1:!1,reducedMotionConfig:u,isSVG:s}),d.current&&l.current&&(l.current.manuallyAnimateOnMount=!0));const f=l.current,h=x.useContext(lu);f&&!f.projection&&o&&(f.type==="html"||f.type==="svg")&&Xy(l.current,n,o,h);const p=x.useRef(!1);x.useInsertionEffect(()=>{f&&p.current&&f.update(n,c)});const m=n[yl],v=x.useRef(!!m&&!((S=window.MotionHandoffIsComplete)!=null&&S.call(window,m))&&((T=window.MotionHasOptimisedAnimation)==null?void 0:T.call(window,m)));return Lc(()=>{d.current=!0,f&&(p.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),f.scheduleRenderMicrotask(),v.current&&f.animationState&&f.animationState.animateChanges())}),x.useEffect(()=>{f&&(!v.current&&f.animationState&&f.animationState.animateChanges(),v.current&&(queueMicrotask(()=>{var b;(b=window.MotionHandoffMarkAsComplete)==null||b.call(window,m)}),v.current=!1),f.enteringChildren=void 0)}),f}function Xy(e,t,n,r){const{layoutId:o,layout:s,drag:i,dragConstraints:a,layoutScroll:c,layoutRoot:u,layoutCrossfade:l}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:uu(e.parent)),e.projection.setOptions({layoutId:o,layout:s,alwaysMeasureLayout:!!i||a&&pn(a),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:l,layoutScroll:c,layoutRoot:u})}function uu(e){if(e)return e.options.allowProjection!==!1?e.projection:uu(e.parent)}function ao(e,{forwardMotionProps:t=!1,type:n}={},r,o){r&&Ry(r);const s=n?n==="svg":Gs(e),i=s?Ky:Gy;function a(u,l){let d;const f={...x.useContext(Us),...u,layoutId:Jy(u)},{isStatic:h}=f,p=By(u),m=i(u,h);if(!h&&Oc){Qy(f,r);const v=ev(f);d=v.MeasureLayout,p.visualElement=qy(e,m,f,o,v.ProjectionNode,s)}return y.jsxs(Lr.Provider,{value:p,children:[d&&p.visualElement?y.jsx(d,{visualElement:p.visualElement,...f}):null,Wy(e,u,Zy(m,p.visualElement,l),m,h,t,s)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const c=x.forwardRef(a);return c[Yy]=e,c}function Jy({layoutId:e}){const t=x.useContext(ps).id;return t&&e!==void 0?t+"-"+e:e}function Qy(e,t){const n=x.useContext(ru).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const r="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?Yt(!1,r,"lazy-strict-mode"):rt(!1,r,"lazy-strict-mode")}}function ev(e){const t=ou(),{drag:n,layout:r}=t;if(!n&&!r)return{};const o={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function tv(e,t){if(typeof Proxy>"u")return ao;const n=new Map,r=(s,i)=>ao(s,i,e,t),o=(s,i)=>(process.env.NODE_ENV!=="production"&&Ss(!1,"motion() is deprecated. Use motion.create() instead."),r(s,i));return new Proxy(o,{get:(s,i)=>i==="create"?r:(n.has(i)||n.set(i,ao(i,void 0,e,t)),n.get(i))})}const nv=(e,t)=>t.isSVG??Gs(e)?new O0(t):new A0(t,{allowProjection:e!==x.Fragment});class rv extends vt{constructor(t){super(t),t.animationState||(t.animationState=$0(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Rr(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let ov=0;class sv extends vt{constructor(){super(...arguments),this.id=ov++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const o=this.node.animationState.setActive("exit",!t);n&&!t&&o.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const iv={animation:{Feature:rv},exit:{Feature:sv}};function Rn(e){return{point:{x:e.pageX,y:e.pageY}}}const av=e=>t=>Ns(t)&&e(t,Rn(t));function xn(e,t,n,r){return En(e,t,av(n),r)}const du=({current:e})=>e?e.ownerDocument.defaultView:null,Va=(e,t)=>Math.abs(e-t);function cv(e,t){const n=Va(e.x,t.x),r=Va(e.y,t.y);return Math.sqrt(n**2+r**2)}const Fa=new Set(["auto","scroll"]);class fu{constructor(t,n,{transformPagePoint:r,contextWindow:o=window,dragSnapToOrigin:s=!1,distanceThreshold:i=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=h=>{this.handleScroll(h.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=lo(this.lastMoveEventInfo,this.history),p=this.startEvent!==null,m=cv(h.offset,{x:0,y:0})>=this.distanceThreshold;if(!p&&!m)return;const{point:v}=h,{timestamp:S}=Me;this.history.push({...v,timestamp:S});const{onStart:T,onMove:b}=this.handlers;p||(T&&T(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),b&&b(this.lastMoveEvent,h)},this.handlePointerMove=(h,p)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=co(p,this.transformPagePoint),le.update(this.updatePoint,!0)},this.handlePointerUp=(h,p)=>{this.end();const{onEnd:m,onSessionEnd:v,resumeAnimation:S}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&S&&S(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const T=lo(h.type==="pointercancel"?this.lastMoveEventInfo:co(p,this.transformPagePoint),this.history);this.startEvent&&m&&m(h,T),v&&v(h,T)},!Ns(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=i,this.contextWindow=o||window;const c=Rn(t),u=co(c,this.transformPagePoint),{point:l}=u,{timestamp:d}=Me;this.history=[{...l,timestamp:d}];const{onSessionStart:f}=n;f&&f(t,lo(u,this.history)),this.removeListeners=Pn(xn(this.contextWindow,"pointermove",this.handlePointerMove),xn(this.contextWindow,"pointerup",this.handlePointerUp),xn(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(Fa.has(r.overflowX)||Fa.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,o=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},s={x:o.x-n.x,y:o.y-n.y};s.x===0&&s.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=s.x,this.lastMoveEventInfo.point.y+=s.y):this.history.length>0&&(this.history[0].x-=s.x,this.history[0].y-=s.y),this.scrollPositions.set(t,o),le.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),pt(this.updatePoint)}}function co(e,t){return t?{point:t(e.point)}:e}function za(e,t){return{x:e.x-t.x,y:e.y-t.y}}function lo({point:e},t){return{point:e,delta:za(e,hu(t)),offset:za(e,lv(t)),velocity:uv(t,.1)}}function lv(e){return e[0]}function hu(e){return e[e.length-1]}function uv(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=hu(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>Ye(t)));)n--;if(!r)return{x:0,y:0};const s=$e(o.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const i={x:(o.x-r.x)/s,y:(o.y-r.y)/s};return i.x===1/0&&(i.x=0),i.y===1/0&&(i.y=0),i}function dv(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?he(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?he(n,e,r.max):Math.min(e,n)),e}function Wa(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function fv(e,{top:t,left:n,bottom:r,right:o}){return{x:Wa(e.x,n,o),y:Wa(e.y,t,r)}}function Ua(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function hv(e,t){return{x:Ua(e.x,t.x),y:Ua(e.y,t.y)}}function mv(e,t){let n=.5;const r=Re(e),o=Re(t);return o>r?n=Tn(t.min,t.max-r,e.min):r>o&&(n=Tn(e.min,e.max-o,t.min)),qe(0,1,n)}function pv(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Xo=.35;function gv(e=Xo){return e===!1?e=0:e===!0&&(e=Xo),{x:Ha(e,"left","right"),y:Ha(e,"top","bottom")}}function Ha(e,t,n){return{min:Ga(e,t),max:Ga(e,n)}}function Ga(e,t){return typeof e=="number"?e:e[t]||0}const yv=new WeakMap;class vv{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=Ce(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:o}=this.visualElement;if(o&&o.isPresent===!1)return;const s=d=>{n?(this.stopAnimation(),this.snapToCursor(Rn(d).point)):this.pauseAnimation()},i=(d,f)=>{this.stopAnimation();const{drag:h,dragPropagation:p,onDragStart:m}=this.getProps();if(h&&!p&&(this.openDragLock&&this.openDragLock(),this.openDragLock=o0(h),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),je(S=>{let T=this.getAxisMotionValue(S).get()||0;if(Ze.test(T)){const{projection:b}=this.visualElement;if(b&&b.layout){const w=b.layout.layoutBox[S];w&&(T=Re(w)*(parseFloat(T)/100))}}this.originPoint[S]=T}),m&&le.postRender(()=>m(d,f)),Wo(this.visualElement,"transform");const{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},a=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:p,onDirectionLock:m,onDrag:v}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:S}=f;if(p&&this.currentDirection===null){this.currentDirection=bv(S),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",f.point,S),this.updateAxis("y",f.point,S),this.visualElement.render(),v&&v(d,f)},c=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f,this.stop(d,f),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>je(d=>{var f;return this.getAnimationState(d)==="paused"&&((f=this.getAxisMotionValue(d).animation)==null?void 0:f.play())}),{dragSnapToOrigin:l}=this.getProps();this.panSession=new fu(t,{onSessionStart:s,onStart:i,onMove:a,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:r,contextWindow:du(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,o=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!o||!r)return;const{velocity:i}=o;this.startAnimation(i);const{onDragEnd:a}=this.getProps();a&&le.postRender(()=>a(r,o))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!zn(t,o,this.currentDirection))return;const s=this.getAxisMotionValue(t);let i=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(i=dv(i,this.constraints[t],this.elastic[t])),s.set(i)}resolveConstraints(){var s;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(s=this.visualElement.projection)==null?void 0:s.layout,o=this.constraints;t&&pn(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=fv(r.layoutBox,t):this.constraints=!1,this.elastic=gv(n),o!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&je(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=pv(r.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!pn(t))return!1;const r=t.current;rt(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const s=S0(r,o.root,this.visualElement.getTransformPagePoint());let i=hv(o.layout.layoutBox,s);if(n){const a=n(v0(i));this.hasMutatedConstraints=!!a,a&&(i=Ll(a))}return i}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:s,dragSnapToOrigin:i,onDragTransitionEnd:a}=this.getProps(),c=this.constraints||{},u=je(l=>{if(!zn(l,n,this.currentDirection))return;let d=c&&c[l]||{};i&&(d={min:0,max:0});const f=o?200:1e6,h=o?40:1e7,p={type:"inertia",velocity:r?t[l]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...s,...d};return this.startAxisValueAnimation(l,p)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Wo(this.visualElement,t),r.start(Ls(t,r,0,n,this.visualElement,!1))}stopAnimation(){je(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){je(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){je(n=>{const{drag:r}=this.getProps();if(!zn(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,s=this.getAxisMotionValue(n);if(o&&o.layout){const{min:i,max:a}=o.layout.layoutBox[n],c=s.get()||0;s.set(t[n]-he(i,a,.5)+c)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!pn(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};je(i=>{const a=this.getAxisMotionValue(i);if(a&&this.constraints!==!1){const c=a.get();o[i]=mv({min:c,max:c},this.constraints[i])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),je(i=>{if(!zn(i,t,null))return;const a=this.getAxisMotionValue(i),{min:c,max:u}=this.constraints[i];a.set(he(c,u,o[i]))})}addListeners(){if(!this.visualElement.current)return;yv.set(this.visualElement,this);const t=this.visualElement.current,n=xn(t,"pointerdown",c=>{const{drag:u,dragListener:l=!0}=this.getProps(),d=c.target,f=d!==t&&Ml(d);u&&l&&!f&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();pn(c)&&c.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,s=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),le.read(r);const i=En(window,"resize",()=>this.scalePositionWithinConstraints()),a=o.addEventListener("didUpdate",({delta:c,hasLayoutChanged:u})=>{this.isDragging&&u&&(je(l=>{const d=this.getAxisMotionValue(l);d&&(this.originPoint[l]+=c[l].translate,d.set(d.get()+c[l].translate))}),this.visualElement.render())});return()=>{i(),n(),s(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:s=!1,dragElastic:i=Xo,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:s,dragElastic:i,dragMomentum:a}}}function zn(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function bv(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class xv extends vt{constructor(t){super(t),this.removeGroupControls=Ne,this.removeListeners=Ne,this.controls=new vv(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ne}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Ka=e=>(t,n)=>{e&&le.postRender(()=>e(t,n))};class Sv extends vt{constructor(){super(...arguments),this.removePointerDownListener=Ne}onPointerDown(t){this.session=new fu(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:du(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:Ka(t),onStart:Ka(n),onMove:r,onEnd:(s,i)=>{delete this.session,o&&le.postRender(()=>o(s,i))}}}mount(){this.removePointerDownListener=xn(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 uo=!1;class Tv extends x.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:s}=t;s&&(n.group&&n.group.add(s),r&&r.register&&o&&r.register(s),uo&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Qn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:s}=this.props,{projection:i}=r;return i&&(i.isPresent=s,t.layoutDependency!==n&&i.setOptions({...i.options,layoutDependency:n}),uo=!0,o||t.layoutDependency!==n||n===void 0||t.isPresent!==s?i.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?i.promote():i.relegate()||le.postRender(()=>{const a=i.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),$s.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;uo=!0,o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function mu(e){const[t,n]=nu(),r=x.useContext(ps);return y.jsx(Tv,{...e,layoutGroup:r,switchLayoutGroup:x.useContext(lu),isPresent:t,safeToRemove:n})}const Cv={pan:{Feature:Sv},drag:{Feature:xv,ProjectionNode:tu,MeasureLayout:mu}};function Ya(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const o="onHover"+n,s=r[o];s&&le.postRender(()=>s(t,Rn(t)))}class wv extends vt{mount(){const{current:t}=this.node;t&&(this.unmount=s0(t,(n,r)=>(Ya(this.node,r,"Start"),o=>Ya(this.node,o,"End"))))}unmount(){}}class _v extends vt{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=Pn(En(this.node.current,"focus",()=>this.onFocus()),En(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Za(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const o="onTap"+(n==="End"?"":n),s=r[o];s&&le.postRender(()=>s(t,Rn(t)))}class Ev extends vt{mount(){const{current:t}=this.node;t&&(this.unmount=c0(t,(n,r)=>(Za(this.node,r,"Start"),(o,{success:s})=>Za(this.node,o,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Jo=new WeakMap,fo=new WeakMap,Av=e=>{const t=Jo.get(e.target);t&&t(e)},Mv=e=>{e.forEach(Av)};function Pv({root:e,...t}){const n=e||document;fo.has(n)||fo.set(n,{});const r=fo.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(Mv,{root:e,...t})),r[o]}function kv(e,t,n){const r=Pv(t);return Jo.set(e,n),r.observe(e),()=>{Jo.delete(e),r.unobserve(e)}}const Iv={some:0,all:1};class Rv extends vt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:s}=t,i={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:Iv[o]},a=c=>{const{isIntersecting:u}=c;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:l,onViewportLeave:d}=this.node.getProps(),f=u?l:d;f&&f(c)};return kv(this.node.current,i,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(Ov(t,n))&&this.startObserver()}unmount(){}}function Ov({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const Lv={inView:{Feature:Rv},tap:{Feature:Ev},focus:{Feature:_v},hover:{Feature:wv}},Dv={layout:{ProjectionNode:tu,MeasureLayout:mu}},jv={...iv,...Lv,...Cv,...Dv},er=tv(jv,nv),pu="data:image/svg+xml,%3csvg%20width='18'%20height='18'%20viewBox='0%200%2018%2018'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M0.75%203.1875C0.75%201.84104%201.84104%200.75%203.1875%200.75L5.625%200.75V2.25H3.1875C2.66946%202.25%202.25%202.66946%202.25%203.1875V5.625H0.75L0.75%203.1875Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M0.75%2014.8125L0.75%2012.375H2.25V14.8125C2.25%2015.3305%202.66946%2015.75%203.1875%2015.75H5.625V17.25H3.1875C1.84104%2017.25%200.75%2016.159%200.75%2014.8125Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M15.75%2014.8125V12.375H17.25V14.8125C17.25%2016.159%2016.159%2017.25%2014.8125%2017.25H12.375V15.75H14.8125C15.3305%2015.75%2015.75%2015.3305%2015.75%2014.8125Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M15.75%203.1875C15.75%202.66946%2015.3305%202.25%2014.8125%202.25H12.375V0.75L14.8125%200.75C16.159%200.75%2017.25%201.84104%2017.25%203.1875V5.625H15.75V3.1875Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M10.8889%2010.5C11.6372%2010.5%2012.3895%2010.6845%2012.991%2011.053L12.9902%2011.0537C13.3468%2011.2719%2013.6565%2011.5584%2013.8684%2011.9092L14.5298%2013.0049L13.2451%2013.7798L12.5845%2012.6841C12.5191%2012.576%2012.3992%2012.4499%2012.2073%2012.3325C11.8787%2012.1312%2011.4076%2012%2010.8889%2012H7.11108C6.59216%2012%206.1214%2012.1305%205.79199%2012.3318L5.79272%2012.3325C5.64854%2012.4207%205.54509%2012.5138%205.47485%2012.6006L5.41553%2012.6841L4.75488%2013.7798L3.47021%2013.0049L4.13086%2011.9092C4.34281%2011.5583%204.6531%2011.2712%205.00977%2011.053C5.6104%2010.6859%206.36112%2010.5%207.11108%2010.5H10.8889Z'%20fill='%23FDFCFC'/%3e%3cpath%20d='M10.5%206.75C10.5%205.92157%209.82843%205.25%209%205.25C8.17157%205.25%207.5%205.92157%207.5%206.75C7.5%207.57843%208.17157%208.25%209%208.25C9.82843%208.25%2010.5%207.57843%2010.5%206.75ZM12%206.75C12%208.40685%2010.6569%209.75%209%209.75C7.34315%209.75%206%208.40685%206%206.75C6%205.09315%207.34315%203.75%209%203.75C10.6569%203.75%2012%205.09315%2012%206.75Z'%20fill='%23FDFCFC'/%3e%3c/svg%3e",gu="data:image/svg+xml,%3csvg%20width='18'%20height='18'%20viewBox='0%200%2018%2018'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M2.25%2014.8125C2.25%2015.3305%202.66946%2015.75%203.1875%2015.75H5.625V17.25H3.1875C1.84104%2017.25%200.75%2016.159%200.75%2014.8125L0.75%2012.375H2.25V14.8125ZM17.25%2014.8125C17.25%2016.159%2016.159%2017.25%2014.8125%2017.25H12.375L12.375%2015.75H14.8125C15.3305%2015.75%2015.75%2015.3305%2015.75%2014.8125V12.375L17.25%2012.375V14.8125ZM14.135%206.35229C14.2958%206.19142%2014.5379%206.14314%2014.748%206.22998C14.9583%206.31702%2015.0959%206.52245%2015.0959%206.75V10.5015C15.0959%2010.812%2014.8439%2011.0638%2014.5334%2011.064C14.2228%2011.0639%2013.9709%2010.8121%2013.9709%2010.5015V8.10571C13.7502%208.30415%2013.4107%208.29824%2013.1982%208.08594C12.9785%207.86637%2012.9787%207.51027%2013.1982%207.29053L14.135%206.35229ZM11.3298%206.19336C11.5137%206.21969%2011.6748%206.33566%2011.7568%206.5061C11.8505%206.70099%2011.8245%206.93272%2011.6895%207.10156L9.42041%209.9375H11.25C11.5607%209.9375%2011.8125%2010.1893%2011.8125%2010.5C11.8125%2010.8107%2011.5607%2011.0625%2011.25%2011.0625H8.25C8.03386%2011.0625%207.83688%2010.9386%207.74316%2010.7439C7.6495%2010.549%207.67547%2010.3173%207.81055%2010.1484L10.0796%207.3125L8.25%207.3125C7.93934%207.3125%207.6875%207.06066%207.6875%206.75C7.6875%206.43934%207.93934%206.1875%208.25%206.1875L11.25%206.1875L11.3298%206.19336ZM5.25%206.19482C5.45567%206.22809%205.62952%206.37352%205.69531%206.57642L6.9104%2010.3264C7.00614%2010.6219%206.84405%2010.9396%206.54858%2011.0354C6.25308%2011.1311%205.93539%2010.9691%205.8396%2010.6736L5.72241%2010.3125H3.65259L3.5354%2010.6736C3.43961%2010.9691%203.12192%2011.1311%202.82642%2011.0354C2.53095%2010.9396%202.36886%2010.6219%202.4646%2010.3264L2.68579%209.6416C2.69424%209.59828%202.7083%209.55696%202.72607%209.51782L3.67969%206.57642L3.71411%206.49365C3.80908%206.30792%204.00155%206.1875%204.21509%206.1875H5.15991L5.25%206.19482ZM4.0166%209.1875H5.3584L4.75122%207.3125H4.62378L4.0166%209.1875ZM5.625%202.25H3.1875C2.66946%202.25%202.25%202.66946%202.25%203.1875V5.625H0.75L0.75%203.1875C0.75%201.84104%201.84104%200.75%203.1875%200.75L5.625%200.75V2.25ZM14.8125%200.75C16.159%200.75%2017.25%201.84104%2017.25%203.1875V5.625H15.75V3.1875C15.75%202.66946%2015.3305%202.25%2014.8125%202.25H12.375V0.75L14.8125%200.75Z'%20fill='%23FDFCFC'/%3e%3c/svg%3e",Dr="Facial",jr="LPR",Bv=[Dr,jr];function $v(e){return e===Dr?y.jsx("img",{src:pu,alt:"Facial",width:16,height:16,style:{display:"block"}}):e===jr?y.jsx("img",{src:gu,alt:"LPR",width:16,height:16,style:{display:"block"}}):null}function Nv(e){if(!e||!Array.isArray(e)||e.length===0)return;const t={};return e.forEach(n=>{const r=n.algorithm;r&&Bv.includes(r)&&(t[r]=(t[r]||0)+1)}),Object.entries(t).map(([n,r])=>({count:r,icon:$v(n)}))}const Vv="_spotWrapper_dvp29_1",Fv="_mapSpot_dvp29_8",zv="_selected_dvp29_27",Wv="_count_dvp29_31",Uv="_countSelected_dvp29_39",Hv="_cameraTypesContainer_dvp29_43",Gv="_cameraTypeItem_dvp29_50",Kv="_cameraTypeCount_dvp29_57",Yv="_cameraTypeIcon_dvp29_64",Je={spotWrapper:Vv,mapSpot:Fv,selected:zv,count:Wv,countSelected:Uv,cameraTypesContainer:Hv,cameraTypeItem:Gv,cameraTypeCount:Kv,cameraTypeIcon:Yv},Zv=er(A.Box),qv=16,Ks=({count:e,addressText:t,cameras:n,currentZoom:r=13,isSelected:o,disableClick:s=!1,className:i,onClick:a,sx:c})=>{const u=x.useMemo(()=>Nv(n),[n]),d=u&&u.length>0&&r>=qv;return y.jsx("div",{className:Je.spotWrapper,children:y.jsx(Zv,{className:`${Je.mapSpot} ${o?Je.selected:""} ${i||""}`,onClick:s?void 0:a,sx:{...c},animate:{width:d?"auto":30,height:d?"auto":30,borderRadius:"100px",backgroundColor:o?"var(--Tertiary-Tertiary, #7FCFCF)":d?"var(--Surface-Surface-Tint, #5E5E5E)":"var(--Surface-Inverse-Surface, #3B3B3C)",padding:d?"4px 8px":0,borderWidth:o?1:0,borderStyle:"solid",borderColor:o?"var(--Tertiary-On-Tertiary, #ffffff)":"transparent"},transition:{duration:.2,ease:"easeInOut"},children:y.jsx(ky,{mode:"wait",children:d?y.jsx(er.div,{className:Je.cameraTypesContainer,initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2,ease:"easeInOut"},children:u.map((f,h)=>y.jsxs(er.div,{className:Je.cameraTypeItem,initial:{opacity:0,x:-10},animate:{opacity:1,x:0},transition:{duration:.2,delay:h*.05},children:[y.jsx(A.Typography,{className:Je.cameraTypeCount,children:f.count}),f.icon&&y.jsx(A.Box,{className:Je.cameraTypeIcon,children:f.icon})]},h))},"expanded"):y.jsx(er.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2,ease:"easeInOut"},children:y.jsx(A.Typography,{className:`${Je.count} ${o?Je.countSelected:""}`,children:e})},"collapsed")})})})};Ks.displayName="MapSpot";const Xv="_cameraCard_1hvrf_2",Jv="_topContainer_1hvrf_52",Qv="_mediaImage_1hvrf_66",e1="_mediaPlaceholder_1hvrf_73",t1="_menuButton_1hvrf_79",n1="_menuButtonIcon_1hvrf_98",r1="_bottomContainer_1hvrf_104",o1="_infoRow_1hvrf_116",s1="_iconWrapper_1hvrf_123",i1="_cameraIcon_1hvrf_131",a1="_cameraTypeImage_1hvrf_138",c1="_textColumn_1hvrf_146",l1="_headerText_1hvrf_155",u1="_subheadText_1hvrf_165",d1="_streetText_1hvrf_175",f1="_supportText_1hvrf_176",h1="_tagsContainer_1hvrf_186",m1="_tag_1hvrf_186",p1="_tagOverflow_1hvrf_199",g1="_cameraCardMenuPaper_1hvrf_220",y1="_cameraCardMenuList_1hvrf_244",v1="_cameraCardMenuItem_1hvrf_252",b1="_cameraCardMenuItemText_1hvrf_291",de={cameraCard:Xv,topContainer:Jv,mediaImage:Qv,mediaPlaceholder:e1,menuButton:t1,menuButtonIcon:n1,bottomContainer:r1,infoRow:o1,iconWrapper:s1,cameraIcon:i1,cameraTypeImage:a1,textColumn:c1,headerText:l1,subheadText:u1,streetText:d1,supportText:f1,tagsContainer:h1,tag:m1,tagOverflow:p1,cameraCardMenuPaper:g1,cameraCardMenuList:y1,cameraCardMenuItem:v1,cameraCardMenuItemText:b1};function x1(e){return e===Dr?y.jsx("img",{src:pu,alt:"Facial",width:20,height:20,className:de.cameraTypeImage}):e===jr?y.jsx("img",{src:gu,alt:"LPR",width:20,height:20,className:de.cameraTypeImage}):y.jsx(Oe.VideocamOutlined,{className:de.cameraIcon})}const S1=({cameraName:e,streetName:t,pointName:n,neighborhoodAndCity:r,tags:o=[],imageUrl:s,algorithm:i,menuItems:a,onMenuClick:c,className:u})=>{const d=X.useTheme().palette.mode==="dark",f=r??"",h=n??"",p=x.useRef(null),m=x.useRef(null),[v,S]=x.useState(o.length),[T,b]=x.useState(!1),w=x.useRef(!1),C=((a==null?void 0:a.length)??0)>0||c,E=((a==null?void 0:a.length)??0)>0;x.useLayoutEffect(()=>{o.length!==0&&(S(o.length),w.current=!1)},[o.length]),x.useLayoutEffect(()=>{const D=p.current;if(!D||o.length===0)return;const g=()=>{if(!D)return;const{scrollWidth:R,clientWidth:W}=D;R>W?(w.current=!0,S(K=>Math.max(0,K-1))):!w.current&&v<o.length?S(K=>Math.min(o.length,K+1)):w.current=!1};g();const $=new ResizeObserver(g);return $.observe(D),()=>$.disconnect()},[o.length,v]);const P=v<o.length,M=P?o.slice(0,v):o,I=P?o.length-v:0,V=o.length>0?o.join(", "):"";return y.jsxs(A.Box,{className:`${de.cameraCard} ${u||""}`.trim(),"data-theme":d?"dark":"light",children:[y.jsxs(A.Box,{className:de.topContainer,children:[s?y.jsx("img",{src:s,alt:"",className:de.mediaImage}):y.jsx(A.Box,{className:de.mediaPlaceholder,"aria-hidden":!0}),C&&y.jsx(A.IconButton,{ref:m,onClick:()=>{E?b(!0):c==null||c()},className:de.menuButton,"aria-label":"Opções","aria-haspopup":E?"menu":void 0,"aria-expanded":T,size:"small",children:y.jsx(Oe.MoreHoriz,{className:de.menuButtonIcon})})]}),E&&y.jsx(A.Popover,{open:T,anchorEl:m.current,onClose:()=>b(!1),anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},slotProps:{paper:{elevation:0,sx:{padding:0,background:"transparent",marginLeft:2}}},children:y.jsx(A.Box,{className:de.cameraCardMenuPaper,"data-theme":d?"dark":"light",children:y.jsx(A.Box,{className:de.cameraCardMenuList,role:"menu",children:a.map(D=>y.jsx("button",{type:"button",className:de.cameraCardMenuItem,role:"menuitem",onClick:()=>{var g;(g=D.onClick)==null||g.call(D),b(!1)},children:y.jsx("span",{className:de.cameraCardMenuItemText,children:D.label})},D.label))})})}),y.jsxs(A.Box,{className:de.bottomContainer,children:[y.jsxs(A.Box,{className:de.infoRow,children:[y.jsx(A.Box,{className:de.iconWrapper,children:x1(i)}),y.jsxs(A.Box,{className:de.textColumn,children:[y.jsx("span",{className:de.headerText,children:e}),h&&y.jsx("span",{className:de.subheadText,children:h}),y.jsx("span",{className:de.streetText,children:t}),f&&y.jsx("span",{className:de.supportText,children:f})]})]}),o.length>0&&y.jsx(A.Tooltip,{title:V,placement:"top",enterDelay:300,children:y.jsxs(A.Box,{ref:p,className:de.tagsContainer,component:"span",tabIndex:0,role:"group","aria-label":"Tags da câmera",children:[M.map(D=>y.jsx("span",{className:de.tag,children:D},D)),P&&y.jsxs("span",{className:de.tagOverflow,children:["+",I]})]})})]})]})},T1=(e,t=1,n=13)=>()=>{if(!e)return;const r=e.getZoom()??n;e.setZoom(r+t)},C1=(e,t=1,n=1,r=13)=>()=>{if(!e)return;const o=e.getZoom()??r;e.setZoom(Math.max(n,o-t))},w1="_container_1whpg_2",_1="_zoomButton_1whpg_10",E1="_stateLayer_1whpg_43",A1="_icon_1whpg_59",Ke={container:w1,zoomButton:_1,stateLayer:E1,icon:A1},M1=({map:e,className:t,sx:n,zoomIncrement:r=1,minZoom:o=1,fallbackZoom:s=13,onFullscreen:i})=>{const c=A.useTheme().palette.mode==="dark",u=T1(e,r,s),l=C1(e,r,o,s),d={backgroundColor:c?"#DEDDDD":"#101111","&:hover":{backgroundColor:c?"#DEDDDD":"#101111",opacity:.9}},f={fill:c?"#101111":"#FDFCFC",color:c?"#101111":"#FDFCFC"};return y.jsxs(A.Box,{className:`${Ke.container} ${t||""}`,sx:n,children:[y.jsx(A.IconButton,{className:Ke.zoomButton,onClick:u,"aria-label":"Zoom in",sx:d,children:y.jsx(A.Box,{className:Ke.stateLayer,children:y.jsx(Oe.Add,{className:Ke.icon,sx:f})})}),y.jsx(A.IconButton,{className:Ke.zoomButton,onClick:l,"aria-label":"Zoom out",sx:d,children:y.jsx(A.Box,{className:Ke.stateLayer,children:y.jsx(Oe.Remove,{className:Ke.icon,sx:f})})}),y.jsx(A.IconButton,{className:Ke.zoomButton,onClick:i,"aria-label":"Fullscreen",sx:d,children:y.jsx(A.Box,{className:Ke.stateLayer,children:y.jsx(Oe.ZoomOutMap,{className:Ke.icon,sx:f})})})]})};var P1=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,o,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(o=r;o--!==0;)if(!e(t[o],n[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(o=r;o--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[o]))return!1;for(o=r;o--!==0;){var i=s[o];if(!e(t[i],n[i]))return!1}return!0}return t!==t&&n!==n};const k1=lc(P1),I1="1.7.1";function Kt(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Qo(e,t,n,r){function o(s){return s instanceof n?s:new n(function(i){i(s)})}return new(n||(n=Promise))(function(s,i){function a(l){try{u(r.next(l))}catch(d){i(d)}}function c(l){try{u(r.throw(l))}catch(d){i(d)}}function u(l){l.done?s(l.value):o(l.value).then(a,c)}u((r=r.apply(e,[])).next())})}const et={NOT_LOADED:"NOT_LOADED",LOADING:"LOADING",LOADED:"LOADED",FAILED:"FAILED",AUTH_FAILURE:"AUTH_FAILURE"},R1="https://maps.googleapis.com/maps/api/js";class hr{static load(t,n){return Qo(this,void 0,void 0,function*(){var r,o;const s=t.libraries?t.libraries.split(","):[],i=this.serializeParams(t);this.listeners.push(n),!((o=(r=window.google)===null||r===void 0?void 0:r.maps)===null||o===void 0)&&o.importLibrary?(this.serializedApiParams||(this.loadingStatus=et.LOADED),this.notifyLoadingStatusListeners()):(this.serializedApiParams=i,this.initImportLibrary(t)),this.serializedApiParams&&this.serializedApiParams!==i&&console.warn("[google-maps-api-loader] The maps API has already been loaded with different parameters and will not be loaded again. Refresh the page for new values to have effect.");const a=["maps",...s];yield Promise.all(a.map(c=>google.maps.importLibrary(c)))})}static serializeParams(t){return[t.v,t.key,t.language,t.region,t.authReferrerPolicy,t.solutionChannel].join("/")}static initImportLibrary(t){if(window.google||(window.google={}),window.google.maps||(window.google.maps={}),window.google.maps.importLibrary){console.error("[google-maps-api-loader-internal]: initImportLibrary must only be called once");return}let n=null;const r=()=>n||(n=new Promise((o,s)=>{var i;const a=document.createElement("script"),c=new URLSearchParams;for(const[u,l]of Object.entries(t)){const d=u.replace(/[A-Z]/g,f=>"_"+f[0].toLowerCase());c.set(d,String(l))}c.set("loading","async"),c.set("callback","__googleMapsCallback__"),a.async=!0,a.src=R1+"?"+c.toString(),a.nonce=((i=document.querySelector("script[nonce]"))===null||i===void 0?void 0:i.nonce)||"",a.onerror=()=>{this.loadingStatus=et.FAILED,this.notifyLoadingStatusListeners(),s(new Error("The Google Maps JavaScript API could not load."))},window.__googleMapsCallback__=()=>{this.loadingStatus=et.LOADED,this.notifyLoadingStatusListeners(),o()},window.gm_authFailure=()=>{this.loadingStatus=et.AUTH_FAILURE,this.notifyLoadingStatusListeners()},this.loadingStatus=et.LOADING,this.notifyLoadingStatusListeners(),document.head.append(a)}),n);google.maps.importLibrary=o=>r().then(()=>google.maps.importLibrary(o))}static notifyLoadingStatusListeners(){for(const t of this.listeners)t(this.loadingStatus)}}hr.loadingStatus=et.NOT_LOADED;hr.listeners=[];const O1="GMP_visgl_rgmlibrary_v1_default",L1=[`gmp_visgl_reactgooglemaps_v${I1}`],On=x.createContext(null);function D1(){const[e,t]=x.useState({});return{mapInstances:e,addMapInstance:(s,i="default")=>{t(a=>Object.assign(Object.assign({},a),{[i]:s}))},removeMapInstance:(s="default")=>{t(i=>{var a=s;i[a];var c=Kt(i,[typeof a=="symbol"?a:a+""]);return c})},clearMapInstances:()=>{t({})}}}function j1(e){const{onLoad:t,onError:n,apiKey:r,version:o,libraries:s=[]}=e,i=Kt(e,["onLoad","onError","apiKey","version","libraries"]),[a,c]=x.useState(hr.loadingStatus),[u,l]=x.useReducer((p,m)=>p[m.name]?p:Object.assign(Object.assign({},p),{[m.name]:m.value}),{}),d=x.useMemo(()=>s==null?void 0:s.join(","),[s]),f=x.useMemo(()=>JSON.stringify(Object.assign({apiKey:r,version:o},i)),[r,o,i]),h=x.useCallback(p=>Qo(this,void 0,void 0,function*(){var m;if(u[p])return u[p];if(!(!((m=google==null?void 0:google.maps)===null||m===void 0)&&m.importLibrary))throw new Error("[api-provider-internal] importLibrary was called before google.maps.importLibrary was defined.");const v=yield window.google.maps.importLibrary(p);return l({name:p,value:v}),v}),[u]);return x.useEffect(()=>{Qo(this,void 0,void 0,function*(){try{const p=Object.assign({key:r},i);o&&(p.v=o),(d==null?void 0:d.length)>0&&(p.libraries=d),(p.channel===void 0||p.channel<0||p.channel>999)&&delete p.channel,p.solutionChannel===void 0?p.solutionChannel=O1:p.solutionChannel===""&&delete p.solutionChannel,yield hr.load(p,m=>c(m));for(const m of["core","maps",...s])yield h(m);t&&t()}catch(p){n?n(p):console.error("<ApiProvider> failed to load the Google Maps JavaScript API",p)}})},[r,d,f]),{status:a,loadedLibraries:u,importLibrary:h}}function B1(e){return x.useMemo(()=>e.disableUsageAttribution?null:L1,[e.disableUsageAttribution])}const $1=e=>{const{children:t}=e,n=Kt(e,["children"]),{mapInstances:r,addMapInstance:o,removeMapInstance:s,clearMapInstances:i}=D1(),{status:a,loadedLibraries:c,importLibrary:u}=j1(n),l=B1(n),d=x.useMemo(()=>({mapInstances:r,addMapInstance:o,removeMapInstance:s,clearMapInstances:i,status:a,loadedLibraries:c,importLibrary:u,internalUsageAttributionIds:l}),[r,o,s,i,a,c,u,l]);return x.createElement(On.Provider,{value:d},t)};function N1(e,t){for(const n of W1){const r=t[n],o=yu[n];x.useEffect(()=>{if(!e||!r)return;const s=google.maps.event.addListener(e,o,i=>{r(V1(o,e,i))});return()=>s.remove()},[e,o,r])}}function V1(e,t,n){var r;const o={type:e,map:t,detail:{},stoppable:!1,stop:()=>{}};if(F1.includes(e)){const s=o,i=t.getCenter(),a=t.getZoom(),c=t.getHeading()||0,u=t.getTilt()||0,l=t.getBounds();return(!i||!l||!Number.isFinite(a))&&console.warn("[createEvent] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),s.detail={center:(i==null?void 0:i.toJSON())||{lat:0,lng:0},zoom:a||0,heading:c,tilt:u,bounds:(l==null?void 0:l.toJSON())||{north:90,east:180,south:-90,west:-180}},s}else if(z1.includes(e)){if(!n)throw new Error("[createEvent] mouse events must provide a srcEvent");const s=o;return s.domEvent=n.domEvent,s.stoppable=!0,s.stop=()=>n.stop(),s.detail={latLng:((r=n.latLng)===null||r===void 0?void 0:r.toJSON())||null,placeId:n.placeId},s}return o}const yu={onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onContextmenu:"contextmenu",onDblclick:"dblclick",onDrag:"drag",onDragend:"dragend",onDragstart:"dragstart",onHeadingChanged:"heading_changed",onIdle:"idle",onIsFractionalZoomEnabledChanged:"isfractionalzoomenabled_changed",onMapCapabilitiesChanged:"mapcapabilities_changed",onMapTypeIdChanged:"maptypeid_changed",onMousemove:"mousemove",onMouseout:"mouseout",onMouseover:"mouseover",onProjectionChanged:"projection_changed",onRenderingTypeChanged:"renderingtype_changed",onTilesLoaded:"tilesloaded",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed",onCameraChanged:"bounds_changed"},F1=["bounds_changed","center_changed","heading_changed","tilt_changed","zoom_changed"],z1=["click","contextmenu","dblclick","mousemove","mouseout","mouseover"],W1=Object.keys(yu);function U1(e){const t=x.useRef(void 0);return x.useEffect(()=>{t.current=e}),t.current}function H1(e,t){const n=U1(e);return x.useMemo(()=>n&&t(n,e)?n:e,[e,n,t])}function G1(e,t,n){x.useEffect(e,[H1(t,n)])}function K1(e,t){G1(e,t,k1)}const Y1=new Set(["backgroundColor","clickableIcons","controlSize","disableDefaultUI","disableDoubleClickZoom","draggable","draggableCursor","draggingCursor","fullscreenControl","fullscreenControlOptions","gestureHandling","headingInteractionEnabled","isFractionalZoomEnabled","keyboardShortcuts","mapTypeControl","mapTypeControlOptions","mapTypeId","maxZoom","minZoom","noClear","panControl","panControlOptions","restriction","rotateControl","rotateControlOptions","scaleControl","scaleControlOptions","scrollwheel","streetView","streetViewControl","streetViewControlOptions","styles","tiltInteractionEnabled","zoomControl","zoomControlOptions"]);function Z1(e,t){const n={},r=Object.keys(t);for(const o of r)Y1.has(o)&&(n[o]=t[o]);K1(()=>{e&&e.setOptions(n)},[n])}function vu(){var e;return((e=x.useContext(On))===null||e===void 0?void 0:e.status)||et.NOT_LOADED}function q1(e,t){const{viewport:n,viewState:r}=t,o=!!n;return x.useLayoutEffect(()=>{if(!e||!r)return;const{latitude:s,longitude:i,bearing:a,pitch:c,zoom:u}=r;e.moveCamera({center:{lat:s,lng:i},heading:a,tilt:c,zoom:u+1})},[e,r]),o}function X1(e){return!e||typeof e!="object"||!("lat"in e&&"lng"in e)?!1:Number.isFinite(e.lat)&&Number.isFinite(e.lng)}function bu(e){return X1(e)?e:e.toJSON()}function J1(e,t,n){const r=n.center?bu(n.center):null;let o=null,s=null;r&&Number.isFinite(r.lat)&&Number.isFinite(r.lng)&&(o=r.lat,s=r.lng);const i=Number.isFinite(n.zoom)?n.zoom:null,a=Number.isFinite(n.heading)?n.heading:null,c=Number.isFinite(n.tilt)?n.tilt:null;x.useLayoutEffect(()=>{if(!e)return;const u={};let l=!1;o!==null&&s!==null&&(t.current.center.lat!==o||t.current.center.lng!==s)&&(u.center={lat:o,lng:s},l=!0),i!==null&&t.current.zoom!==i&&(u.zoom=i,l=!0),a!==null&&t.current.heading!==a&&(u.heading=a,l=!0),c!==null&&t.current.tilt!==c&&(u.tilt=c,l=!0),l&&e.moveCamera(u)})}const Q1=()=>{const e={position:"absolute",top:0,left:0,bottom:0,right:0,zIndex:999,display:"flex",flexFlow:"column nowrap",textAlign:"center",justifyContent:"center",fontSize:".8rem",color:"rgba(0,0,0,0.6)",background:"#dddddd",padding:"1rem 1.5rem"};return x.createElement("div",{style:e},x.createElement("h2",null,"Error: AuthFailure"),x.createElement("p",null,"A problem with your API key prevents the map from rendering correctly. Please make sure the value of the ",x.createElement("code",null,"APIProvider.apiKey")," prop is correct. Check the error-message in the console for further details."))};function eb(){const[e,t]=x.useState(null),n=x.useCallback(r=>t(r),[t]);return[e,n]}function xu(){return vu()===et.LOADED}function tb(){const[,e]=x.useReducer(t=>t+1,0);return e}function nb(e,t){const n=e.getCenter(),r=e.getZoom(),o=e.getHeading()||0,s=e.getTilt()||0,i=e.getBounds();(!n||!i||!Number.isFinite(r))&&console.warn("[useTrackedCameraState] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),Object.assign(t.current,{center:(n==null?void 0:n.toJSON())||{lat:0,lng:0},zoom:r||0,heading:o,tilt:s})}function rb(e){const t=tb(),n=x.useRef({center:{lat:0,lng:0},heading:0,tilt:0,zoom:0});return x.useEffect(()=>{if(!e)return;const r=google.maps.event.addListener(e,"bounds_changed",()=>{nb(e,n),t()});return()=>r.remove()},[e,t]),n}class tr{static has(t){return this.entries[t]&&this.entries[t].length>0}static pop(t){return this.entries[t]&&this.entries[t].pop()||null}static push(t,n){this.entries[t]||(this.entries[t]=[]),this.entries[t].push(n)}}tr.entries={};function ob(e,t){const n=xu(),[r,o]=x.useState(null),[s,i]=eb(),a=rb(r),{id:c,defaultBounds:u,defaultCenter:l,defaultZoom:d,defaultHeading:f,defaultTilt:h,reuseMaps:p,renderingType:m,colorScheme:v}=e,S=Kt(e,["id","defaultBounds","defaultCenter","defaultZoom","defaultHeading","defaultTilt","reuseMaps","renderingType","colorScheme"]),T=e.zoom!==void 0||e.defaultZoom!==void 0,b=e.center!==void 0||e.defaultCenter!==void 0;!u&&(!T||!b)&&console.warn("<Map> component is missing configuration. You have to provide zoom and center (via the `zoom`/`defaultZoom` and `center`/`defaultCenter` props) or specify the region to show using `defaultBounds`. See https://visgl.github.io/react-google-maps/docs/api-reference/components/map#required"),!S.center&&l&&(S.center=l),!S.zoom&&Number.isFinite(d)&&(S.zoom=d),!S.heading&&Number.isFinite(f)&&(S.heading=f),!S.tilt&&Number.isFinite(h)&&(S.tilt=h);const w=S.internalUsageAttributionIds;w==null?S.internalUsageAttributionIds=t.internalUsageAttributionIds:S.internalUsageAttributionIds=[...t.internalUsageAttributionIds||[],...w];for(const E of Object.keys(S))S[E]===void 0&&delete S[E];const C=x.useRef(void 0);return x.useEffect(()=>{if(!s||!n)return;const{addMapInstance:E,removeMapInstance:P}=t,{mapId:M}=e,I=`${M||"default"}:${m||"default"}:${v||"LIGHT"}`;let V,D;if(p&&tr.has(I)?(D=tr.pop(I),V=D.getDiv(),s.appendChild(V),D.setOptions(S),setTimeout(()=>D.setCenter(D.getCenter()),0)):(V=document.createElement("div"),V.style.height="100%",s.appendChild(V),D=new google.maps.Map(V,Object.assign(Object.assign(Object.assign({},S),m?{renderingType:m}:{}),v?{colorScheme:v}:{}))),o(D),E(D,c),u){const{padding:g}=u,$=Kt(u,["padding"]);D.fitBounds($,g)}else(!T||!b)&&D.fitBounds({east:180,west:-180,south:-90,north:90});if(C.current){const{mapId:g,cameraState:$}=C.current;g!==M&&D.setOptions($)}return()=>{C.current={mapId:M,cameraState:a.current},V.remove(),p?tr.push(I,D):google.maps.event.clearInstanceListeners(D),o(null),P(c)}},[s,n,c,e.mapId,e.renderingType,e.colorScheme]),[r,i,a]}const Su=x.createContext(null),Tu=e=>{const{children:t,id:n,className:r,style:o}=e,s=x.useContext(On),i=vu();if(!s)throw new Error("<Map> can only be used inside an <ApiProvider> component.");const[a,c,u]=ob(e,s);J1(a,u,e),N1(a,e),Z1(a,e);const l=q1(a,e),d=!!e.controlled;x.useEffect(()=>{if(a)return l&&a.setOptions({disableDefaultUI:!0}),(l||d)&&a.setOptions({gestureHandling:"none",keyboardShortcuts:!1}),()=>{a.setOptions({gestureHandling:e.gestureHandling,keyboardShortcuts:e.keyboardShortcuts})}},[a,l,d,e.gestureHandling,e.keyboardShortcuts]);const f=e.center?bu(e.center):null;let h=null,p=null;f&&Number.isFinite(f.lat)&&Number.isFinite(f.lng)&&(h=f.lat,p=f.lng);const m=x.useMemo(()=>{var T,b,w;return{center:{lat:h??0,lng:p??0},zoom:(T=e.zoom)!==null&&T!==void 0?T:0,heading:(b=e.heading)!==null&&b!==void 0?b:0,tilt:(w=e.tilt)!==null&&w!==void 0?w:0}},[h,p,e.zoom,e.heading,e.tilt]);x.useLayoutEffect(()=>{if(!a||!d)return;a.moveCamera(m);const T=a.addListener("bounds_changed",()=>{a.moveCamera(m)});return()=>T.remove()},[a,d,m]);const v=x.useMemo(()=>Object.assign({width:"100%",height:"100%",position:"relative",zIndex:l?-1:0},o),[o,l]),S=x.useMemo(()=>({map:a}),[a]);return i===et.AUTH_FAILURE?x.createElement("div",{style:Object.assign({position:"relative"},r?{}:v),className:r},x.createElement(Q1,null)):x.createElement("div",Object.assign({ref:c,"data-testid":"map",style:r?void 0:v,className:r},n?{id:n}:{}),a?x.createElement(Su.Provider,{value:S},t):null)};Tu.deckGLViewProps=!0;const qa=new Set;function sb(...e){const t=JSON.stringify(e);qa.has(t)||(qa.add(t),console.error(...e))}const Br=(e=null)=>{const t=x.useContext(On),{map:n}=x.useContext(Su)||{};if(t===null)return sb("useMap(): failed to retrieve APIProviderContext. Make sure that the <APIProvider> component exists and that the component you are calling `useMap()` from is a sibling of the <APIProvider>."),null;const{mapInstances:r}=t;return e!==null?r[e]||null:n||r.default||null};function ib(e){const t=xu(),n=x.useContext(On);return x.useEffect(()=>{!t||!n||n.importLibrary(e)},[t,n,e]),(n==null?void 0:n.loadedLibraries[e])||null}function Wn(e,t,n){x.useEffect(()=>{if(!e||!t||!n)return;const r=google.maps.event.addListener(e,t,n);return()=>r.remove()},[e,t,n])}function Un(e,t,n){x.useEffect(()=>{e&&(e[t]=n)},[e,t,n])}function Xa(e,t,n){x.useEffect(()=>{if(!(!e||!t||!n))return e.addEventListener(t,n),()=>e.removeEventListener(t,n)},[e,t,n])}class ab{constructor(){this.renderedStyles=new Set,this.styleElement=null}getStyleElement(){return this.styleElement||(this.styleElement=document.createElement("style"),this.styleElement.setAttribute("data-rgm-anchor-styles",""),document.head.appendChild(this.styleElement)),this.styleElement}addAdvancedMarkerPointerEventsOverwrite(){if(this.renderedStyles.has("marker-pointer-events"))return;const t=this.getStyleElement();t.textContent+=`
104
+ gmp-advanced-marker[data-origin='rgm'] {
105
+ pointer-events: none !important;
106
+ }
107
+ `,this.renderedStyles.add("marker-pointer-events")}cleanup(){this.styleElement&&(this.styleElement.remove(),this.styleElement=null,this.renderedStyles.clear())}}const cb=new ab;function lb(e,t){var n;if(!(!((n=google==null?void 0:google.maps)===null||n===void 0)&&n.version))return;const r=google.maps.version.split("."),o=parseInt(r[0],10),s=parseInt(r[1],10);return o>e||o===e&&s>=t}const ub=x.createContext(null),db={BOTTOM:["50%","100%"]},Cu=x.forwardRef((e,t)=>{const{children:n,style:r,className:o,anchorPoint:s}=e,[i,a]=hb(e),c=x.useMemo(()=>i?{marker:i}:null,[i]);return x.useImperativeHandle(t,()=>i,[i]),a?x.createElement(ub.Provider,{value:c},ld.createPortal(x.createElement(fb,{anchorPoint:s,styles:r,className:o},n),a)):null});Cu.displayName="AdvancedMarker";function es(e){return e.nodeType===Node.ELEMENT_NODE}const fb=({children:e,styles:t,className:n})=>x.createElement("div",{className:n,style:t},e);function hb(e){const[t,n]=x.useState(null),[r,o]=x.useState(null),s=Br(),i=ib("marker"),{children:a,onClick:c,className:u,onMouseEnter:l,onMouseLeave:d,onDrag:f,onDragStart:h,onDragEnd:p,collisionBehavior:m,clickable:v,draggable:S,position:T,title:b,zIndex:w,anchorPoint:C,anchorLeft:E,anchorTop:P}=e,M=x.Children.count(a);return x.useEffect(()=>{if(!s||!i)return;const I=new i.AdvancedMarkerElement;I.map=s,n(I);let V=null;return M>0&&(V=document.createElement("div"),I.content=V,o(V)),()=>{I.map=null,V==null||V.remove(),n(null),o(null)}},[s,i,M]),x.useEffect(()=>{!(t!=null&&t.content)||!es(t.content)||M>0||(t.content.className=u??"")},[t,u,M]),mb(t,C,E,P,M>0),Un(t,"position",T),Un(t,"title",b??""),Un(t,"zIndex",w),Un(t,"collisionBehavior",m),x.useEffect(()=>{t&&(S!==void 0?t.gmpDraggable=S:f||h||p?t.gmpDraggable=!0:t.gmpDraggable=!1)},[t,S,f,p,h]),x.useEffect(()=>{if(!t)return;const I=v!==void 0||!!c||!!l||!!d;t.gmpClickable=I,I&&(t!=null&&t.content)&&es(t.content)&&(t.content.style.pointerEvents="all",c&&(t.content.style.cursor="pointer"))},[t,v,c,l,d]),Wn(t,"click",c),Wn(t,"drag",f),Wn(t,"dragstart",h),Wn(t,"dragend",p),Xa(t==null?void 0:t.element,"mouseenter",l),Xa(t==null?void 0:t.element,"mouseleave",d),[t,r]}function mb(e,t,n,r,o){x.useEffect(()=>{if(!e||!o)return;const s=lb(3,62),i=e.content;if(!(!i||!es(i))){if(n!==void 0||r!==void 0){s||console.warn(`AdvancedMarker: The anchorLeft and anchorTop props are only supported in Google Maps API version 3.62 and above. The current version is ${google.maps.version}.`),e.anchorLeft=n,e.anchorTop=r,t!==void 0&&console.warn("AdvancedMarker: the anchorPoint prop is ignored when anchorLeft and/or anchorTop are set.");return}if(t!==void 0){const[a,c]=t??db.BOTTOM,u=`calc(-1 * ${a})`,l=`calc(-1 * ${c})`;s?(e.anchorLeft=u,e.anchorTop=l,i.style.transform=""):(i.style.transform=`translate(50%, 100%) translate(${u}, ${l})`,e.dataset.origin="rgm",cb.addAdvancedMarkerPointerEventsOverwrite())}}},[e,t,n,r,o])}function pb(e){const[t,n]=x.useState(null),r=Br(),{onClick:o,onDrag:s,onDragStart:i,onDragEnd:a,onMouseOver:c,onMouseOut:u}=e,l=Kt(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut"]),{position:d,draggable:f}=l;return x.useEffect(()=>{if(!r){r===void 0&&console.error("<Marker> has to be inside a Map component.");return}const h=new google.maps.Marker(l);return h.setMap(r),n(h),()=>{h.setMap(null),n(null)}},[r]),x.useEffect(()=>{if(!t)return;const h=t,p=google.maps.event;return o&&p.addListener(h,"click",o),s&&p.addListener(h,"drag",s),i&&p.addListener(h,"dragstart",i),a&&p.addListener(h,"dragend",a),c&&p.addListener(h,"mouseover",c),u&&p.addListener(h,"mouseout",u),t.setDraggable(!!f),()=>{p.clearInstanceListeners(h)}},[t,f,o,s,i,a,c,u]),x.useEffect(()=>{t&&l&&t.setOptions(l)},[t,l]),x.useEffect(()=>{f||!d||!t||t.setPosition(d)},[f,d,t]),t}const gb=x.forwardRef((e,t)=>{const n=pb(e);return x.useImperativeHandle(t,()=>n,[n]),x.createElement(x.Fragment,null)});gb.displayName="Marker";const wu=x.createContext(void 0),Ys=()=>{const e=x.useContext(wu);if(!e)throw new Error("useGoogleMapContext must be used within GoogleMap component");return e},Zs=({children:e})=>{const t=Br(),[n,r]=x.useState(13),[o,s]=x.useState(null);x.useEffect(()=>{if(!t)return;const a=t.getZoom();a!==void 0&&r(a);const c=t.getBounds();if(c){const d=c.getNorthEast(),f=c.getSouthWest();s([f.lng(),f.lat(),d.lng(),d.lat()])}const u=t.addListener("zoom_changed",()=>{const d=t.getZoom();d!==void 0&&(console.log("[MapContent] Zoom changed:",d),r(d))}),l=t.addListener("bounds_changed",()=>{const d=t.getBounds();if(d){const f=d.getNorthEast(),h=d.getSouthWest();s([h.lng(),h.lat(),f.lng(),f.lat()])}});return()=>{u&&google.maps.event.removeListener(u),l&&google.maps.event.removeListener(l)}},[t]);const i=(a,c=16)=>{t&&(t.setCenter(a),t.setZoom(c))};return t?y.jsx(wu.Provider,{value:{isLoaded:!0,map:t,currentZoom:n,bounds:o,zoomToPosition:i},children:e}):null};Zs.displayName="MapContent";const yb=180,_u=()=>{const{map:e}=Ys(),t=x.useRef(null),n=x.useRef(null);return x.useEffect(()=>{if(!e||!t.current)return;const r=new ResizeObserver(()=>{n.current&&clearTimeout(n.current),n.current=setTimeout(()=>{try{google.maps.event.trigger(e,"resize")}finally{n.current=null}},yb)});return r.observe(t.current),()=>{n.current&&clearTimeout(n.current),r.disconnect()}},[e]),y.jsx("div",{ref:t,"aria-hidden":!0,style:{position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",visibility:"hidden"}})};_u.displayName="MapResizeHandler";const vb="_googleMap_j4y4m_1",bb="_container_j4y4m_10",xb="_errorContainer_j4y4m_21",Hn={googleMap:vb,container:bb,errorContainer:xb},Sb={lat:-26.3044,lng:-48.8487},Tb=13,Cb={disableDefaultUI:!0,zoomControl:!1,streetViewControl:!1,mapTypeControl:!1,fullscreenControl:!1,rotateControl:!1,scaleControl:!1,panControl:!1,clickableIcons:!1,keyboardShortcuts:!1},wb=({colorScheme:e,options:t,onLoad:n,children:r})=>{const o=Br();return x.useEffect(()=>{o&&(o.setOptions(Cb),t&&o.setOptions(t),n&&n(o))},[o,t,n]),y.jsx(y.Fragment,{children:r})},Eu=({center:e=Sb,zoom:t=Tb,className:n,children:r,apiKey:o,mapId:s,themeMode:i="light",options:a,onLoad:c,onError:u})=>{if(!o||!s)return y.jsx("div",{className:`${Hn.container} ${Hn.errorContainer} ${n||""}`,children:y.jsxs("div",{children:[y.jsx("p",{children:"Google Maps não configurado"}),y.jsx("p",{style:{fontSize:"14px",marginTop:"8px",opacity:.7},children:"As props apiKey e mapId são obrigatórias"})]})});const l=i==="dark"?"DARK":"LIGHT",d={defaultCenter:e,defaultZoom:t,mapId:s,className:Hn.googleMap,colorScheme:l},f=`${s}-${l}`;return y.jsx($1,{apiKey:o,onLoad:()=>{console.log("Google Maps API carregada com sucesso")},onError:h=>{console.error("Erro ao carregar Google Maps API:",h),u&&h instanceof Error&&u(h)},children:y.jsx("div",{className:`${Hn.container} ${n||""}`,style:{width:"100%",height:"400px",minHeight:"400px",position:"relative"},children:y.jsx(Tu,{...d,style:{width:"100%",height:"100%"},children:y.jsx(wb,{colorScheme:l,options:a,onLoad:c,children:y.jsxs(Zs,{children:[y.jsx(_u,{}),r]})})},f)})})};Eu.displayName="GoogleMap";const Ja=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],ho=1,cn=8;class qs{static from(t){if(!(t instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");const[n,r]=new Uint8Array(t,0,2);if(n!==219)throw new Error("Data does not appear to be in a KDBush format.");const o=r>>4;if(o!==ho)throw new Error(`Got v${o} data when expected v${ho}.`);const s=Ja[r&15];if(!s)throw new Error("Unrecognized array type.");const[i]=new Uint16Array(t,2,1),[a]=new Uint32Array(t,4,1);return new qs(a,i,s,t)}constructor(t,n=64,r=Float64Array,o){if(isNaN(t)||t<0)throw new Error(`Unpexpected numItems value: ${t}.`);this.numItems=+t,this.nodeSize=Math.min(Math.max(+n,2),65535),this.ArrayType=r,this.IndexArrayType=t<65536?Uint16Array:Uint32Array;const s=Ja.indexOf(this.ArrayType),i=t*2*this.ArrayType.BYTES_PER_ELEMENT,a=t*this.IndexArrayType.BYTES_PER_ELEMENT,c=(8-a%8)%8;if(s<0)throw new Error(`Unexpected typed array class: ${r}.`);o&&o instanceof ArrayBuffer?(this.data=o,this.ids=new this.IndexArrayType(this.data,cn,t),this.coords=new this.ArrayType(this.data,cn+a+c,t*2),this._pos=t*2,this._finished=!0):(this.data=new ArrayBuffer(cn+i+a+c),this.ids=new this.IndexArrayType(this.data,cn,t),this.coords=new this.ArrayType(this.data,cn+a+c,t*2),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,(ho<<4)+s]),new Uint16Array(this.data,2,1)[0]=n,new Uint32Array(this.data,4,1)[0]=t)}add(t,n){const r=this._pos>>1;return this.ids[r]=r,this.coords[this._pos++]=t,this.coords[this._pos++]=n,r}finish(){const t=this._pos>>1;if(t!==this.numItems)throw new Error(`Added ${t} items when expected ${this.numItems}.`);return ts(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(t,n,r,o){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:s,coords:i,nodeSize:a}=this,c=[0,s.length-1,0],u=[];for(;c.length;){const l=c.pop()||0,d=c.pop()||0,f=c.pop()||0;if(d-f<=a){for(let v=f;v<=d;v++){const S=i[2*v],T=i[2*v+1];S>=t&&S<=r&&T>=n&&T<=o&&u.push(s[v])}continue}const h=f+d>>1,p=i[2*h],m=i[2*h+1];p>=t&&p<=r&&m>=n&&m<=o&&u.push(s[h]),(l===0?t<=p:n<=m)&&(c.push(f),c.push(h-1),c.push(1-l)),(l===0?r>=p:o>=m)&&(c.push(h+1),c.push(d),c.push(1-l))}return u}within(t,n,r){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:o,coords:s,nodeSize:i}=this,a=[0,o.length-1,0],c=[],u=r*r;for(;a.length;){const l=a.pop()||0,d=a.pop()||0,f=a.pop()||0;if(d-f<=i){for(let v=f;v<=d;v++)Qa(s[2*v],s[2*v+1],t,n)<=u&&c.push(o[v]);continue}const h=f+d>>1,p=s[2*h],m=s[2*h+1];Qa(p,m,t,n)<=u&&c.push(o[h]),(l===0?t-r<=p:n-r<=m)&&(a.push(f),a.push(h-1),a.push(1-l)),(l===0?t+r>=p:n+r>=m)&&(a.push(h+1),a.push(d),a.push(1-l))}return c}}function ts(e,t,n,r,o,s){if(o-r<=n)return;const i=r+o>>1;Au(e,t,i,r,o,s),ts(e,t,n,r,i-1,1-s),ts(e,t,n,i+1,o,1-s)}function Au(e,t,n,r,o,s){for(;o>r;){if(o-r>600){const u=o-r+1,l=n-r+1,d=Math.log(u),f=.5*Math.exp(2*d/3),h=.5*Math.sqrt(d*f*(u-f)/u)*(l-u/2<0?-1:1),p=Math.max(r,Math.floor(n-l*f/u+h)),m=Math.min(o,Math.floor(n+(u-l)*f/u+h));Au(e,t,n,p,m,s)}const i=t[2*n+s];let a=r,c=o;for(ln(e,t,r,n),t[2*o+s]>i&&ln(e,t,r,o);a<c;){for(ln(e,t,a,c),a++,c--;t[2*a+s]<i;)a++;for(;t[2*c+s]>i;)c--}t[2*r+s]===i?ln(e,t,r,c):(c++,ln(e,t,c,o)),c<=n&&(r=c+1),n<=c&&(o=c-1)}}function ln(e,t,n,r){mo(e,n,r),mo(t,2*n,2*r),mo(t,2*n+1,2*r+1)}function mo(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function Qa(e,t,n,r){const o=e-n,s=t-r;return o*o+s*s}const _b={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:e=>e},ec=Math.fround||(e=>t=>(e[0]=+t,e[0]))(new Float32Array(1)),St=2,lt=3,po=4,ct=5,Mu=6;class Pu{constructor(t){this.options=Object.assign(Object.create(_b),t),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(t){const{log:n,minZoom:r,maxZoom:o}=this.options;n&&console.time("total time");const s=`prepare ${t.length} points`;n&&console.time(s),this.points=t;const i=[];for(let c=0;c<t.length;c++){const u=t[c];if(!u.geometry)continue;const[l,d]=u.geometry.coordinates,f=ec(Gn(l)),h=ec(Kn(d));i.push(f,h,1/0,c,-1,1),this.options.reduce&&i.push(0)}let a=this.trees[o+1]=this._createTree(i);n&&console.timeEnd(s);for(let c=o;c>=r;c--){const u=+Date.now();a=this.trees[c]=this._createTree(this._cluster(a,c)),n&&console.log("z%d: %d clusters in %dms",c,a.numItems,+Date.now()-u)}return n&&console.timeEnd("total time"),this}getClusters(t,n){let r=((t[0]+180)%360+360)%360-180;const o=Math.max(-90,Math.min(90,t[1]));let s=t[2]===180?180:((t[2]+180)%360+360)%360-180;const i=Math.max(-90,Math.min(90,t[3]));if(t[2]-t[0]>=360)r=-180,s=180;else if(r>s){const d=this.getClusters([r,o,180,i],n),f=this.getClusters([-180,o,s,i],n);return d.concat(f)}const a=this.trees[this._limitZoom(n)],c=a.range(Gn(r),Kn(i),Gn(s),Kn(o)),u=a.data,l=[];for(const d of c){const f=this.stride*d;l.push(u[f+ct]>1?tc(u,f,this.clusterProps):this.points[u[f+lt]])}return l}getChildren(t){const n=this._getOriginId(t),r=this._getOriginZoom(t),o="No cluster with the specified id.",s=this.trees[r];if(!s)throw new Error(o);const i=s.data;if(n*this.stride>=i.length)throw new Error(o);const a=this.options.radius/(this.options.extent*Math.pow(2,r-1)),c=i[n*this.stride],u=i[n*this.stride+1],l=s.within(c,u,a),d=[];for(const f of l){const h=f*this.stride;i[h+po]===t&&d.push(i[h+ct]>1?tc(i,h,this.clusterProps):this.points[i[h+lt]])}if(d.length===0)throw new Error(o);return d}getLeaves(t,n,r){n=n||10,r=r||0;const o=[];return this._appendLeaves(o,t,n,r,0),o}getTile(t,n,r){const o=this.trees[this._limitZoom(t)],s=Math.pow(2,t),{extent:i,radius:a}=this.options,c=a/i,u=(r-c)/s,l=(r+1+c)/s,d={features:[]};return this._addTileFeatures(o.range((n-c)/s,u,(n+1+c)/s,l),o.data,n,r,s,d),n===0&&this._addTileFeatures(o.range(1-c/s,u,1,l),o.data,s,r,s,d),n===s-1&&this._addTileFeatures(o.range(0,u,c/s,l),o.data,-1,r,s,d),d.features.length?d:null}getClusterExpansionZoom(t){let n=this._getOriginZoom(t)-1;for(;n<=this.options.maxZoom;){const r=this.getChildren(t);if(n++,r.length!==1)break;t=r[0].properties.cluster_id}return n}_appendLeaves(t,n,r,o,s){const i=this.getChildren(n);for(const a of i){const c=a.properties;if(c&&c.cluster?s+c.point_count<=o?s+=c.point_count:s=this._appendLeaves(t,c.cluster_id,r,o,s):s<o?s++:t.push(a),t.length===r)break}return s}_createTree(t){const n=new qs(t.length/this.stride|0,this.options.nodeSize,Float32Array);for(let r=0;r<t.length;r+=this.stride)n.add(t[r],t[r+1]);return n.finish(),n.data=t,n}_addTileFeatures(t,n,r,o,s,i){for(const a of t){const c=a*this.stride,u=n[c+ct]>1;let l,d,f;if(u)l=ku(n,c,this.clusterProps),d=n[c],f=n[c+1];else{const m=this.points[n[c+lt]];l=m.properties;const[v,S]=m.geometry.coordinates;d=Gn(v),f=Kn(S)}const h={type:1,geometry:[[Math.round(this.options.extent*(d*s-r)),Math.round(this.options.extent*(f*s-o))]],tags:l};let p;u||this.options.generateId?p=n[c+lt]:p=this.points[n[c+lt]].id,p!==void 0&&(h.id=p),i.features.push(h)}}_limitZoom(t){return Math.max(this.options.minZoom,Math.min(Math.floor(+t),this.options.maxZoom+1))}_cluster(t,n){const{radius:r,extent:o,reduce:s,minPoints:i}=this.options,a=r/(o*Math.pow(2,n)),c=t.data,u=[],l=this.stride;for(let d=0;d<c.length;d+=l){if(c[d+St]<=n)continue;c[d+St]=n;const f=c[d],h=c[d+1],p=t.within(c[d],c[d+1],a),m=c[d+ct];let v=m;for(const S of p){const T=S*l;c[T+St]>n&&(v+=c[T+ct])}if(v>m&&v>=i){let S=f*m,T=h*m,b,w=-1;const C=((d/l|0)<<5)+(n+1)+this.points.length;for(const E of p){const P=E*l;if(c[P+St]<=n)continue;c[P+St]=n;const M=c[P+ct];S+=c[P]*M,T+=c[P+1]*M,c[P+po]=C,s&&(b||(b=this._map(c,d,!0),w=this.clusterProps.length,this.clusterProps.push(b)),s(b,this._map(c,P)))}c[d+po]=C,u.push(S/v,T/v,1/0,C,-1,v),s&&u.push(w)}else{for(let S=0;S<l;S++)u.push(c[d+S]);if(v>1)for(const S of p){const T=S*l;if(!(c[T+St]<=n)){c[T+St]=n;for(let b=0;b<l;b++)u.push(c[T+b])}}}}return u}_getOriginId(t){return t-this.points.length>>5}_getOriginZoom(t){return(t-this.points.length)%32}_map(t,n,r){if(t[n+ct]>1){const i=this.clusterProps[t[n+Mu]];return r?Object.assign({},i):i}const o=this.points[t[n+lt]].properties,s=this.options.map(o);return r&&s===o?Object.assign({},s):s}}function tc(e,t,n){return{type:"Feature",id:e[t+lt],properties:ku(e,t,n),geometry:{type:"Point",coordinates:[Eb(e[t]),Ab(e[t+1])]}}}function ku(e,t,n){const r=e[t+ct],o=r>=1e4?`${Math.round(r/1e3)}k`:r>=1e3?`${Math.round(r/100)/10}k`:r,s=e[t+Mu],i=s===-1?{}:Object.assign({},n[s]);return Object.assign(i,{cluster:!0,cluster_id:e[t+lt],point_count:r,point_count_abbreviated:o})}function Gn(e){return e/360+.5}function Kn(e){const t=Math.sin(e*Math.PI/180),n=.5-.25*Math.log((1+t)/(1-t))/Math.PI;return n<0?0:n>1?1:n}function Eb(e){return(e-.5)*360}function Ab(e){const t=(180-e*360)*Math.PI/180;return 360*Math.atan(Math.exp(t))/Math.PI-90}const Mb={radius:30,maxZoom:13,minZoom:0,minPoints:2};function Pb(e,t,n,r={}){const o=x.useRef(null),[s,i]=x.useState([]),a={...Mb,...r};return x.useEffect(()=>{if(!e||e.length===0){i([]);return}const c=e.map(u=>({type:"Feature",properties:u,geometry:{type:"Point",coordinates:[u.lng,u.lat]}}));o.current=new Pu({radius:a.radius,maxZoom:a.maxZoom,minZoom:a.minZoom,minPoints:a.minPoints}),o.current.load(c)},[e,a.radius,a.maxZoom,a.minZoom,a.minPoints]),x.useEffect(()=>{if(!o.current||!n){i(e);return}const u=o.current.getClusters(n,Math.floor(t)).map(l=>{const[d,f]=l.geometry.coordinates,h=l.properties;if(h.cluster){const p=h.cluster_id,m=o.current.getLeaves(p,1/0),v=m.flatMap(T=>T.properties.cameras||[]),S=m.reduce((T,b)=>T+b.properties.count,0);return{id:`cluster-${p}`,lat:f,lng:d,count:S,cameras:v,isCluster:!0,pointCount:h.point_count,clusterId:p}}else{const p=h;return{id:p.id,lat:f,lng:d,count:p.count,addressText:p.addressText,cameras:p.cameras}}});i(u)},[e,t,n]),s}const kb=16,Iu=({spots:e,onSpotClick:t,zoomLevel:n=kb,selectedSpotId:r,animateOnClick:o,disableClick:s})=>{const{isLoaded:i,currentZoom:a,bounds:c,zoomToPosition:u}=Ys(),l=x.useRef(null),d=Pb(e,a,c);if(d.length>0&&c){const h=e.map(p=>({type:"Feature",properties:p,geometry:{type:"Point",coordinates:[p.lng,p.lat]}}));l.current||(l.current=new Pu({radius:30,maxZoom:13,minZoom:0,minPoints:2})),l.current.load(h)}const f=h=>{if(h.isCluster&&h.clusterId&&l.current)try{const p=l.current.getClusterExpansionZoom(h.clusterId);u({lat:h.lat,lng:h.lng},p)}catch(p){console.error("Error getting cluster expansion zoom:",p),u({lat:h.lat,lng:h.lng},n)}else u({lat:h.lat,lng:h.lng},n),s||t==null||t(h)};return i?y.jsx(y.Fragment,{children:d.map((h,p)=>y.jsx(Cu,{position:{lat:h.lat,lng:h.lng},onClick:()=>f(h),children:y.jsx(Ks,{count:h.count,addressText:h.addressText,cameras:h.cameras,currentZoom:a,isSelected:!s&&!h.isCluster&&r===h.id,animateOnClick:o,disableClick:s})},h.id??p))}):null};Iu.displayName="MapMarkers";const Ib="_searchBar_15mix_1",Rb="_startIconContainer_15mix_106",Ob="_endIconContainer_15mix_117",Lb="_endIconContainerClickable_15mix_153",Db="_defaultIcon_15mix_157",gn={searchBar:Ib,startIconContainer:Rb,endIconContainer:Ob,endIconContainerClickable:Lb,defaultIcon:Db},jb=e=>()=>{e&&e()},Bb=e=>t=>{e&&e(t)},$b=()=>y.jsx(Oe.Search,{className:gn.defaultIcon}),Nb=e=>e||$b(),Ru=x.forwardRef(({startIcon:e,endIcon:t,onEndIconClick:n,placeholder:r,value:o,onChange:s,className:i,...a},c)=>{const l=A.useTheme().palette.mode==="dark",d=Nb(t),f=jb(n),h=Bb(s);return y.jsx(A.TextField,{ref:c,value:o,onChange:h,placeholder:r,variant:"outlined",autoComplete:"off",className:`${gn.searchBar} ${i||""}`,"data-theme":l?"dark":"light",InputProps:{startAdornment:e?y.jsx(A.InputAdornment,{position:"start",className:gn.startIconContainer,children:e}):null,endAdornment:y.jsx(A.InputAdornment,{position:"end",className:`${gn.endIconContainer} ${n?gn.endIconContainerClickable:""}`,onClick:f,disablePointerEvents:!n,children:d})},inputProps:{autoComplete:"off","data-form-type":"other"},...a})});Ru.displayName="SearchBar";const Vb=st(y.jsx("path",{d:"M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"}),"Home"),Fb=st([y.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3 6.08 3 3.28 5.64 3.03 9h2.02C5.3 6.75 7.18 5 9.5 5 11.99 5 14 7.01 14 9.5S11.99 14 9.5 14c-.17 0-.33-.03-.5-.05v2.02c.17.02.33.03.5.03 1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19z"},"0"),y.jsx("path",{d:"M6.47 10.82 4 13.29l-2.47-2.47-.71.71L3.29 14 .82 16.47l.71.71L4 14.71l2.47 2.47.71-.71L4.71 14l2.47-2.47z"},"1")],"SearchOff"),zb="_container_1mb8b_1",Wb="_iconWrapper_1mb8b_11",Ub="_icon_1mb8b_11",Hb="_title_1mb8b_21",Gb="_subtitle_1mb8b_30",Kb="_description_1mb8b_34",Yb="_button_1mb8b_38",Tt={container:zb,iconWrapper:Wb,icon:Ub,title:Hb,subtitle:Gb,description:Kb,button:Yb},Ou=({onGoHome:e,buttonText:t="Voltar para o início",title:n="Página não encontrada",description:r="Desculpe, a página que você está procurando não existe ou foi movida para outro endereço.",errorCode:o="404",className:s})=>y.jsx(A.Container,{maxWidth:"sm",children:y.jsxs(A.Box,{className:`${Tt.container} ${s||""}`,children:[y.jsx(A.Box,{className:Tt.iconWrapper,children:y.jsx(Fb,{className:Tt.icon,color:"primary"})}),y.jsx(A.Typography,{variant:"h1",className:Tt.title,sx:{fontSize:{xs:"6rem",md:"8rem"}},children:o}),y.jsx(A.Typography,{variant:"h4",component:"h2",className:Tt.subtitle,color:"text.primary",children:n}),y.jsx(A.Typography,{variant:"body1",className:Tt.description,color:"text.secondary",children:r}),e&&y.jsx(cs,{variant:"contained",size:"large",startIcon:y.jsx(Vb,{}),onClick:e,className:Tt.button,children:t})]})});Ou.displayName="NotFoundContent";const Zb=e=>{const t=e.find(r=>r.active),n=e.flatMap(r=>{var o;return((o=r.submenu)==null?void 0:o.map(s=>({item:r,subItem:s})))??[]}).find(({subItem:r})=>r.active);return{itemId:(n==null?void 0:n.item.id)??(t==null?void 0:t.id)??null,subItemId:(n==null?void 0:n.subItem.id)??null,expandedItemId:(n==null?void 0:n.item.id)??null}},qb=({items:e,isExpanded:t=!0,onClick:n})=>{const r=x.useMemo(()=>Zb(e),[e]),[o,s]=x.useState(r.itemId),[i,a]=x.useState(r.subItemId),[c,u]=x.useState(r.expandedItemId),[l,d]=x.useState(null),[f,h]=x.useState(null);x.useEffect(()=>{s(r.itemId),a(r.subItemId),u(r.expandedItemId)},[r.itemId,r.subItemId,r.expandedItemId]);const p=f?e.find(E=>E.id===f):void 0,m=(p==null?void 0:p.submenu)??[];return{selectedItemId:o,selectedSubItemId:i,expandedItemId:c,submenuAnchorEl:l,submenuItem:p,submenuItems:m,getIsItemActive:E=>{var M;const P=i?!!((M=E.submenu)!=null&&M.some(I=>I.id===i)):!1;return o?E.id===o:!!(E.active||P)},getIsSubItemActive:E=>i?E.id===i:!!E.active,shouldShowSubmenu:E=>{var P;return!!(t&&((P=E.submenu)!=null&&P.length)&&c===E.id)},handleItemClick:(E,P)=>{var M,I;s(E.id),a(null),(M=E.submenu)!=null&&M.length?t?u(V=>V===E.id?null:E.id):(d(P.currentTarget),h(E.id)):(u(null),d(null),h(null)),(I=E.onClick)==null||I.call(E,P),n==null||n({item:E})},handleSubItemClick:(E,P,M,I)=>{var V;s(E.id),a(P.id),I!=null&&I.closeMenu&&(d(null),h(null)),(V=P.onClick)==null||V.call(P,M),n==null||n({item:E,subItem:P})},closeSubmenu:()=>{d(null),h(null)}}},Lu=e=>typeof e=="number"?`${e*4}px`:e,Xb=({item:e,onClick:t,isActive:n})=>{const r=X.useTheme();return y.jsx(A.ButtonBase,{onClick:t,"aria-label":e.label,"aria-pressed":n||void 0,sx:{width:"100%",borderRadius:Lu(r.shape.borderRadius),px:2,py:1.25,justifyContent:"flex-start",textAlign:"left",color:r.palette.text.primary,backgroundColor:n?r.palette.action.selected:"transparent","&:hover":{backgroundColor:r.palette.action.hover}},children:y.jsx(A.Typography,{variant:"body2",sx:{fontWeight:500},children:e.label})})},Du=({items:e,isExpanded:t=!0,className:n,onClick:r})=>{const o=X.useTheme(),s=Lu(o.shape.borderRadius),{submenuAnchorEl:i,submenuItem:a,submenuItems:c,getIsItemActive:u,getIsSubItemActive:l,shouldShowSubmenu:d,handleItemClick:f,handleSubItemClick:h,closeSubmenu:p}=qb({items:e,isExpanded:t,onClick:r});return y.jsxs(A.Stack,{className:n,direction:"column",spacing:2,sx:{width:"100%"},children:[e.map(m=>{var E,P;const v=u(m),S=d(m),T=t?o.spacing(2):o.spacing(4),b=t?v?o.palette.primary.main:o.palette.action.hover:"transparent",w=t?"transparent":v?o.palette.primary.main:o.palette.action.hover,C=!t&&v?o.palette.primary.contrastText:o.palette.text.primary;return y.jsxs(A.Stack,{direction:"column",spacing:1,sx:{width:"100%"},children:[y.jsx(A.ButtonBase,{onClick:M=>f(m,M),"aria-label":m.label,"aria-pressed":v||void 0,"aria-haspopup":(E=m.submenu)!=null&&E.length?"menu":void 0,sx:{width:"100%",borderRadius:s,px:t?2:1,py:t?1.5:1,justifyContent:t?"flex-start":"center",textAlign:"left",color:o.palette.text.primary,backgroundColor:b,boxShadow:t&&v?o.shadows[1]:"none","&:hover":{backgroundColor:t?o.palette.action.hover:"transparent"}},children:y.jsxs(A.Stack,{direction:t?"row":"column",alignItems:"center",spacing:t?1.5:1,sx:{width:"100%"},children:[y.jsx(A.Box,{sx:{width:64,height:T,borderRadius:s,display:"inline-flex",alignItems:"center",justifyContent:"center",backgroundColor:w,color:C,transition:o.transitions.create(["background-color","box-shadow"],{duration:o.transitions.duration.shortest}),...t?{}:{boxShadow:v?o.shadows[1]:"none","&:hover":{backgroundColor:v?X.alpha(o.palette.primary.main,.9):o.palette.action.selected}}},children:m.icon}),y.jsx(A.Typography,{variant:"body2",sx:{width:"100%",textAlign:t?"left":"center",fontWeight:v?600:500},children:m.label}),t&&m.trailingIcon?y.jsx(A.Box,{sx:{ml:"auto",display:"inline-flex",alignItems:"center"},children:m.trailingIcon}):null]})}),S?y.jsx(A.Collapse,{in:S,timeout:"auto",unmountOnExit:!0,children:y.jsx(A.Stack,{direction:"column",spacing:1,sx:{pl:4},children:(P=m.submenu)==null?void 0:P.map(M=>{const I=l(M);return y.jsx(Xb,{item:M,isActive:I,onClick:V=>h(m,M,V)},M.id)})})}):null]},m.id)}),y.jsx(A.Menu,{anchorEl:i,open:!!(i&&c.length),onClose:p,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},MenuListProps:{dense:!0,"aria-label":(a==null?void 0:a.label)??"submenu"},PaperProps:{sx:{borderRadius:s,minWidth:o.spacing(22),px:1,py:.5,boxShadow:o.shadows[3]}},children:c.map(m=>{const v=l(m);return y.jsx(A.MenuItem,{selected:v,onClick:S=>{a&&h(a,m,S,{closeMenu:!0})},sx:{borderRadius:s,fontWeight:v?600:500},children:m.label},m.id)})})]})};Du.displayName="SidebarMenu";const Jb=e=>{const t=e.find(n=>n.active);return(t==null?void 0:t.id)??null},Qb=({items:e,onSelect:t,isExpanded:n=!0})=>{const r=x.useMemo(()=>Jb(e),[e]),[o,s]=x.useState(r),[i,a]=x.useState(null);x.useEffect(()=>{s(r)},[r]);const c=o?e.find(h=>h.id===o):void 0;return{selectedItemId:o,selectedItem:c,menuAnchorEl:i,getIsItemActive:h=>o?h.id===o:!!h.active,openMenu:h=>{n||a(h.currentTarget)},closeMenu:()=>{n||a(null)},handleItemClick:(h,p)=>{var m;s(h.id),(m=h.onClick)==null||m.call(h,p),t==null||t(h),a(null)}}},ex=e=>typeof e=="number"?`${e*4}px`:e,ju=({items:e,currentLabel:t,headerLabel:n,headerIcon:r,headerTrailingIcon:o,listTitle:s,action:i,isExpanded:a=!0,className:c,onSelect:u})=>{var K,G;const l=X.useTheme(),d=x.useRef(null),f=ex(l.shape.borderRadius),[h,p]=x.useState(!1),m=x.useMemo(()=>Number.parseFloat(l.spacing(2).toString()),[l]),{selectedItem:v,menuAnchorEl:S,getIsItemActive:T,openMenu:b,closeMenu:w,handleItemClick:C}=Qb({items:e,onSelect:u,isExpanded:a}),E=t??(v==null?void 0:v.label)??((K=e[0])==null?void 0:K.label)??"",P=r??(v==null?void 0:v.icon)??((G=e[0])==null?void 0:G.icon)??null,M=a||!P,I=j=>{if(a){p(Q=>!Q);return}b(j)},V=(j,Q)=>{C(j,Q),p(!1)},D=y.jsx(A.Stack,{direction:"column",spacing:.5,children:e.map(j=>{const Q=T(j);return y.jsxs(A.MenuItem,{selected:Q,onClick:L=>V(j,L),sx:{borderRadius:f,gap:1.5,px:2,py:1.25,color:l.palette.text.primary,"&:hover":{backgroundColor:l.palette.action.hover}},children:[j.icon?y.jsx(A.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:j.icon}):null,y.jsx(A.Typography,{variant:"body1",sx:{fontWeight:Q?600:500},children:j.label})]},j.id)})}),g=y.jsxs(A.Box,{sx:{borderRadius:f,backgroundColor:l.palette.background.paper,boxShadow:l.shadows[3],display:"flex",flexDirection:"column",maxHeight:l.spacing(50)},children:[s?y.jsx(A.Box,{sx:{px:2,pt:2,pb:1},children:y.jsx(A.Typography,{variant:"subtitle2",sx:{color:l.palette.text.primary},children:s})}):null,y.jsx(A.Box,{sx:{px:2,pb:2,overflowY:"auto",flex:1,minHeight:0},children:D})]}),$=i?y.jsxs(A.MenuItem,{onClick:i.onClick,sx:{borderRadius:f,gap:1.5,px:2,py:1.25,color:l.palette.text.primary,"&:hover":{backgroundColor:l.palette.action.hover}},children:[i.icon?y.jsx(A.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:i.icon}):null,y.jsx(A.Typography,{variant:"body1",sx:{fontWeight:600},children:i.label})]}):null,R=$?y.jsx(A.Box,{sx:{borderRadius:f,backgroundColor:l.palette.background.paper,boxShadow:l.shadows[3]},children:$}):null,W=y.jsxs(A.Stack,{direction:"column",spacing:1,sx:{minWidth:l.spacing(32)},children:[g,R]});return y.jsxs(A.Stack,{className:c,direction:a?"row":"column",spacing:a?2:1,sx:{width:"100%",alignItems:a?"flex-start":"stretch"},children:[y.jsx(A.ButtonBase,{onClick:I,"aria-label":E,ref:d,sx:{width:a?l.spacing(28):"64px",height:a?"auto":"64px",borderRadius:f,px:a?2:0,py:a?1.25:0,display:"flex",alignItems:"center",justifyContent:"center",textAlign:"left",backgroundColor:l.palette.action.hover,"&:hover":{backgroundColor:l.palette.action.selected}},children:y.jsxs(A.Stack,{direction:"row",alignItems:"center",spacing:a?1:0,sx:{width:a?"100%":"auto",justifyContent:a?"space-between":"center",px:0},children:[P?y.jsx(A.Box,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:P}):null,M?y.jsxs(A.Box,{sx:{minWidth:0,flex:1},children:[n?y.jsx(A.Typography,{variant:"caption",sx:{color:l.palette.text.secondary},children:n}):null,y.jsx(A.Typography,{variant:"body2",sx:{fontWeight:600},noWrap:!0,children:E})]}):null,a&&o?y.jsx(A.Box,{sx:{ml:"auto",display:"inline-flex",alignItems:"center"},children:o}):null]})}),a?h?y.jsx(A.ClickAwayListener,{onClickAway:()=>p(!1),children:y.jsx(A.Popper,{open:h,anchorEl:d.current,placement:"right-start",modifiers:[{name:"offset",options:{offset:[0,m]}}],sx:{zIndex:l.zIndex.modal},children:W})}):null:y.jsx(A.Menu,{anchorEl:S,open:!!S,onClose:w,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},disableAutoFocusItem:!0,slotProps:{paper:{sx:{borderRadius:f,p:0,ml:2,backgroundColor:"transparent",boxShadow:"none",overflow:"visible"}}},MenuListProps:{"aria-label":E?`menu-${E}`:"menu",sx:{p:0}},children:W})]})};ju.displayName="ModuleMenu";const Xs=e=>e.seekable&&e.seekable.length>0?e.seekable.end(e.seekable.length-1):Number.isFinite(e.duration)&&e.duration>0?e.duration:e.currentTime,tx=(e,t,n)=>({...e&&{"--player-width":typeof e=="number"?`${e}px`:e},...t&&{"--player-height":typeof t=="number"?`${t}px`:t},...n&&{"--player-aspect-ratio":n}}),nx=({stream:e,availableQualities:t,initialQuality:n,autoPlay:r,liveThresholdSeconds:o,allowPlaybackRateForStream:s})=>{const i=x.useRef(null),a=x.useRef(null),c=x.useMemo(()=>{if(!t||!t.length)return null;if(n){const j=t.find(Q=>Q.value===n);if(j)return j}return t[0]},[t,n]),[u,l]=x.useState(c),[d,f]=x.useState(!1),[h,p]=x.useState(!0),[m,v]=x.useState(!1),[S,T]=x.useState(0),[b,w]=x.useState(0),[C,E]=x.useState(1),[P,M]=x.useState(1),[I,V]=x.useState(!1),[D,g]=x.useState(!0),$=(u==null?void 0:u.stream)??e??null,R=(u==null?void 0:u.src)??null,K=!!!$||s;x.useEffect(()=>{l(c)},[c]);const G=x.useCallback(()=>{const j=a.current;if(!j)return;if(!j.seekable||j.seekable.length===0){p(!0),v(!1);return}const Q=Xs(j),L=Math.max(0,Q-j.currentTime);w(Q),T(j.currentTime),v(Q>0),p(L<=(o??2))},[o]);return x.useEffect(()=>{const j=a.current;if(!j)return;const Q=()=>f(!0),L=()=>f(!1),_=()=>g(!0),N=()=>g(!0),O=()=>g(!1),B=()=>g(!1);return j.addEventListener("play",Q),j.addEventListener("pause",L),j.addEventListener("waiting",_),j.addEventListener("loadstart",N),j.addEventListener("canplay",O),j.addEventListener("playing",B),j.addEventListener("timeupdate",G),j.addEventListener("durationchange",G),j.addEventListener("loadedmetadata",G),j.addEventListener("progress",G),()=>{j.removeEventListener("play",Q),j.removeEventListener("pause",L),j.removeEventListener("waiting",_),j.removeEventListener("loadstart",N),j.removeEventListener("canplay",O),j.removeEventListener("playing",B),j.removeEventListener("timeupdate",G),j.removeEventListener("durationchange",G),j.removeEventListener("loadedmetadata",G),j.removeEventListener("progress",G)}},[G]),x.useEffect(()=>{const j=a.current;j&&(g(!0),$?(j.srcObject!==$&&(j.srcObject=$),j.getAttribute("src")&&j.removeAttribute("src")):R?(j.srcObject&&(j.srcObject=null),j.src!==R&&(j.src=R,j.load())):(j.srcObject&&(j.srcObject=null),j.getAttribute("src")&&j.removeAttribute("src")),r&&j.play().then(()=>{}).catch(()=>{}))},[$,R,r]),x.useEffect(()=>{const j=a.current;j&&(K?j.playbackRate=C:(j.playbackRate=1,E(1)))},[C,K]),x.useEffect(()=>{const j=()=>{V(!!document.fullscreenElement)};return document.addEventListener("fullscreenchange",j),()=>{document.removeEventListener("fullscreenchange",j)}},[]),{containerRef:i,videoRef:a,selectedQuality:u,setSelectedQuality:l,isPlaying:d,isLive:h,canSeek:m,currentTime:S,setCurrentTime:T,seekableEnd:b,playbackRate:C,setPlaybackRate:E,zoom:P,setZoom:M,isFullscreen:I,isLoading:D,canAdjustPlaybackRate:K,updateLiveStatus:G}},rx="_container_zv1tx_1",ox="_loader_zv1tx_19",sx="_video_zv1tx_29",ix="_controlsOverlay_zv1tx_37",ax="_timeline_zv1tx_58",cx="_controlsRow_zv1tx_65",lx="_controlGroup_zv1tx_83",ux="_iconButton_zv1tx_100",dx="_seekButton_zv1tx_113",fx="_menuButton_zv1tx_133",hx="_liveBadge_zv1tx_149",Ae={container:rx,loader:ox,video:sx,controlsOverlay:ix,timeline:ax,controlsRow:cx,controlGroup:lx,iconButton:ux,seekButton:dx,menuButton:fx,liveBadge:hx},go=({label:e,valueLabel:t,selectedValue:n,options:r,onChange:o,disabled:s,ariaLabel:i})=>{const[a,c]=x.useState(null),u=!!a;return y.jsxs(y.Fragment,{children:[y.jsx(A.ButtonBase,{disabled:s,className:Ae.menuButton,"aria-label":i,onClick:l=>c(l.currentTarget),children:e?`${e}: ${t}`:t}),y.jsx(A.Menu,{anchorEl:a,open:u,onClose:()=>c(null),children:r.map(l=>y.jsx(A.MenuItem,{selected:l.value===n,disabled:l.disabled,onClick:()=>{o(l.value),c(null)},children:l.label},`${e}-${String(l.value)}`))})]})},mx=e=>()=>{const t=e.current;t&&(t.paused?t.play().catch(()=>{}):t.pause())},px=(e,t,n)=>r=>{const o=e.current;if(!o||!t)return;const s=Xs(o),i=Math.min(Math.max(o.currentTime+r,0),s);o.currentTime=i,n()},gx=e=>()=>{e.current&&(document.fullscreenElement?document.exitFullscreen().catch(()=>{}):e.current.requestFullscreen().catch(()=>{}))},yx=(e,t,n)=>r=>{const o=e.find(s=>s.value===r)??null;t(o),n==null||n(o)},vx=(e,t)=>(n,r)=>{if(!e)return;const o=Array.isArray(r)?r[0]:r;t(o)},bx=(e,t,n)=>(r,o)=>{const s=e.current;if(!s||!t)return;const i=Array.isArray(o)?o[0]:o,a=Xs(s);s.currentTime=Math.min(Math.max(i,0),a),n()},Bu=({stream:e=null,availableQualities:t=[],initialQuality:n,onQualityChange:r,autoPlay:o=!0,playsInline:s=!0,muted:i=!0,poster:a,className:c,sx:u,liveThresholdSeconds:l=2,allowPlaybackRateForStream:d=!1,playbackRates:f=[.5,1,1.5,2],zoomLevels:h=[1,1.2,1.5],width:p,height:m,aspectRatio:v="16 / 9",showTimestamp:S=!0,showTimeline:T=!0})=>{const b=X.useTheme(),[w,C]=x.useState(""),[E,P]=x.useState(!0),M=x.useRef(null);x.useEffect(()=>{if(!S)return;const Te=()=>{const He=new Date,Dn=String(He.getDate()).padStart(2,"0"),nd=String(He.getMonth()+1).padStart(2,"0"),rd=He.getFullYear(),od=["Dom","Seg","Ter","Qua","Qui","Sex","Sab"][He.getDay()],sd=String(He.getHours()).padStart(2,"0"),id=String(He.getMinutes()).padStart(2,"0"),ad=String(He.getSeconds()).padStart(2,"0");C(`${Dn}-${nd}-${rd}, ${od} ${sd}:${id}:${ad}`)};Te();const Ln=setInterval(Te,1e3);return()=>clearInterval(Ln)},[S]),x.useEffect(()=>{const Te=I.current;if(!Te)return;const Ln=()=>{M.current&&(clearTimeout(M.current),M.current=null),P(!0)},He=()=>{M.current=setTimeout(()=>{P(!1)},1e4)},Dn=()=>{E||P(!0),M.current&&clearTimeout(M.current),M.current=setTimeout(()=>{P(!1)},1e4)};return Te.addEventListener("mouseenter",Ln),Te.addEventListener("mouseleave",He),Te.addEventListener("mousemove",Dn),()=>{Te.removeEventListener("mouseenter",Ln),Te.removeEventListener("mouseleave",He),Te.removeEventListener("mousemove",Dn),M.current&&clearTimeout(M.current)}},[E]);const{containerRef:I,videoRef:V,selectedQuality:D,setSelectedQuality:g,isPlaying:$,isLive:R,canSeek:W,currentTime:K,setCurrentTime:G,seekableEnd:j,playbackRate:Q,setPlaybackRate:L,zoom:_,setZoom:N,isFullscreen:O,isLoading:B,canAdjustPlaybackRate:Y,updateLiveStatus:U}=nx({stream:e,availableQualities:t,initialQuality:n,autoPlay:o,liveThresholdSeconds:l,allowPlaybackRateForStream:d}),z=mx(V),Z=px(V,W,U),q=gx(I),J=yx(t,g,r),me=vx(W,G),F=bx(V,W,U),_e=h.map(Te=>({value:Te,label:`${Math.round(Te*100)}%`})),Ue=f.map(Te=>({value:Te,label:`${Te}x`})),it=t.map(Te=>({value:Te.value,label:Te.label})),$r=(D==null?void 0:D.label)??"Auto",Qt=`${Math.round(_*100)}%`,en=`${Q}x`,tn=W&&j>0,Nr=tx(p,m,v);return y.jsxs(A.Box,{ref:I,className:`${Ae.container} ${c||""}`.trim(),style:Nr,sx:{borderRadius:0,backgroundColor:b.palette.common.black,...u},children:[B&&y.jsx(A.Box,{className:Ae.loader,sx:{backgroundColor:b.palette.common.black},children:y.jsx(A.CircularProgress,{size:60,sx:{color:b.palette.primary.contrastText,width:{xs:"48px",sm:"60px"},height:{xs:"48px",sm:"60px"}}})}),y.jsx("video",{ref:V,className:Ae.video,autoPlay:o,playsInline:s,muted:i,poster:a,style:{transform:`scale(${_})`}}),S&&w&&y.jsx(A.Box,{sx:{position:"absolute",top:0,left:0,right:0,padding:{xs:"10px 12px",sm:"12px 16px"}},children:y.jsx(A.Typography,{variant:"body2",sx:{color:b.palette.common.white,fontWeight:500,fontSize:{xs:"12px",sm:"14px"},textShadow:"0 2px 8px rgba(0,0,0,0.8)"},children:w})}),R&&!E&&y.jsx(A.Box,{sx:{position:"absolute",bottom:16,left:20,zIndex:10},children:y.jsx(A.Box,{className:Ae.liveBadge,sx:{backgroundColor:X.alpha(b.palette.common.white,.9),color:b.palette.common.black},component:"span","aria-live":"polite",children:"ao vivo"})}),y.jsxs(A.Box,{className:Ae.controlsOverlay,sx:{opacity:E?1:0,visibility:E?"visible":"hidden",transition:"opacity 0.3s ease, visibility 0.3s ease"},children:[T&&y.jsx(A.Box,{className:Ae.timeline,children:y.jsx(A.Slider,{size:"small",min:0,max:tn?j:1,step:1,value:tn?K:0,disabled:!tn,onChange:me,onChangeCommitted:F,"aria-label":"Linha do tempo do video",sx:{color:b.palette.common.white,"& .MuiSlider-thumb":{width:12,height:12,backgroundColor:b.palette.common.white},"& .MuiSlider-track":{border:"none",backgroundColor:b.palette.common.white},"& .MuiSlider-rail":{backgroundColor:X.alpha(b.palette.common.white,.3),opacity:1}}})}),y.jsxs(A.Box,{className:Ae.controlsRow,children:[y.jsxs(A.Box,{className:Ae.controlGroup,children:[y.jsx(A.Box,{className:Ae.liveBadge,sx:{backgroundColor:R?X.alpha(b.palette.common.white,.9):X.alpha(b.palette.common.white,.15),color:R?b.palette.common.black:X.alpha(b.palette.common.white,.7)},component:"span","aria-live":"polite",children:"ao vivo"}),y.jsx(A.Box,{className:Ae.seekButton,component:"button",onClick:()=>Z(-15),"aria-label":"Voltar 15 segundos",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,border:"none",cursor:"pointer","&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:"15s"}),y.jsx(A.IconButton,{className:Ae.iconButton,onClick:()=>Z(-15),"aria-label":"Recuar 15 segundos",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:y.jsx(Oe.FastRewind,{fontSize:"small"})}),y.jsx(A.IconButton,{className:Ae.iconButton,onClick:z,"aria-label":"Play/Pause",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:$?y.jsx(Oe.Pause,{fontSize:"small"}):y.jsx(Oe.PlayArrow,{fontSize:"small"})}),y.jsx(A.IconButton,{className:Ae.iconButton,onClick:()=>Z(15),"aria-label":"Avançar 15 segundos",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:y.jsx(Oe.FastForward,{fontSize:"small"})}),y.jsx(A.Box,{className:Ae.seekButton,component:"button",onClick:()=>Z(15),"aria-label":"Avançar 15 segundos",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,border:"none",cursor:"pointer","&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:"15s"})]}),y.jsxs(A.Box,{className:Ae.controlGroup,children:[y.jsx(A.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}}},children:y.jsx(go,{label:"",valueLabel:en,selectedValue:Q,options:Ue,ariaLabel:"Selecionar velocidade de reprodução",onChange:L,disabled:!Y})}),it.length>0?y.jsx(A.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}}},children:y.jsx(go,{label:"",valueLabel:$r,selectedValue:(D==null?void 0:D.value)??"auto",options:it,ariaLabel:"Selecionar qualidade do vídeo",onChange:J})}):null,y.jsx(A.Box,{sx:{"& .MuiButtonBase-root":{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}}},children:y.jsx(go,{label:"",valueLabel:Qt,selectedValue:_,options:_e,ariaLabel:"Selecionar zoom do vídeo",onChange:N})}),y.jsx(A.IconButton,{className:Ae.iconButton,onClick:q,"aria-label":"Fullscreen",sx:{backgroundColor:X.alpha(b.palette.common.white,.15),color:b.palette.common.white,"&:hover":{backgroundColor:X.alpha(b.palette.common.white,.25)}},children:O?y.jsx(Oe.FullscreenExit,{fontSize:"small"}):y.jsx(Oe.Fullscreen,{fontSize:"small"})})]})]})]})]})};Bu.displayName="VideoPlayer";const xx=st(y.jsx("path",{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8"}),"UndoOutlined"),Sx=st(y.jsx("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6z"}),"Add"),Tx=st(y.jsx("path",{d:"M19 13H5v-2h14z"}),"Remove"),Cx="_root_1gj5n_1",wx="_container_1gj5n_6",_x="_header_1gj5n_13",Ex="_headerText_1gj5n_21",Ax="_controls_1gj5n_27",Mx="_iconButton_1gj5n_34",Px="_zoomGroup_1gj5n_43",kx="_zoomTrack_1gj5n_52",Ix="_zoomTrackFill_1gj5n_59",Rx="_layers_1gj5n_67",Ox="_timeScale_1gj5n_78",Lx="_videoTrack_1gj5n_82",Dx="_eventsTrack_1gj5n_86",jx="_trackBox_1gj5n_90",Bx="_trackLabelRow_1gj5n_95",$x="_label_1gj5n_103",Nx="_trackArea_1gj5n_112",Vx="_tick_1gj5n_118",Fx="_tickMajor_1gj5n_126",zx="_tickMinor_1gj5n_131",Wx="_tickLabel_1gj5n_135",Ux="_segment_1gj5n_146",Hx="_event_1gj5n_86",Gx="_eventDot_1gj5n_166",Kx="_selectionOverlay_1gj5n_172",Yx="_playhead_1gj5n_180",Zx="_playheadLine_1gj5n_190",qx="_playheadHandle_1gj5n_199",ee={root:Cx,container:wx,header:_x,headerText:Ex,controls:Ax,iconButton:Mx,zoomGroup:Px,zoomTrack:kx,zoomTrackFill:Ix,layers:Rx,timeScale:Ox,videoTrack:Lx,eventsTrack:Dx,trackBox:jx,trackLabelRow:Bx,label:$x,trackArea:Nx,tick:Vx,tickMajor:Fx,tickMinor:zx,tickLabel:Wx,segment:Ux,event:Hx,eventDot:Gx,selectionOverlay:Kx,playhead:Yx,playheadLine:Zx,playheadHandle:qx},tt={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1};function $u(e){return"init"in e}function ns(e){return!!e.write}function nc(e){return"v"in e||"e"in e}function mr(e){if("e"in e)throw e.e;if((tt?"production":void 0)!=="production"&&!("v"in e))throw new Error("[Bug] atom state is not initialized");return e.v}const pr=new WeakMap;function Nu(e){var t;return gr(e)&&!!((t=pr.get(e))!=null&&t[0])}function Xx(e){const t=pr.get(e);t!=null&&t[0]&&(t[0]=!1,t[1].forEach(n=>n()))}function rs(e,t){let n=pr.get(e);if(!n){n=[!0,new Set],pr.set(e,n);const r=()=>{n[0]=!1};e.then(r,r)}n[1].add(t)}function gr(e){return typeof(e==null?void 0:e.then)=="function"}function Vu(e,t,n){if(!n.p.has(e)){n.p.add(e);const r=()=>n.p.delete(e);t.then(r,r)}}function Fu(e,t,n){var r;const o=new Set;for(const s of((r=n.get(e))==null?void 0:r.t)||[])o.add(s);for(const s of t.p)o.add(s);return o}const Jx=(e,t,...n)=>t.read(...n),Qx=(e,t,...n)=>t.write(...n),eS=(e,t)=>{if(t.INTERNAL_onInit)return t.INTERNAL_onInit(e);if(t.unstable_onInit)return console.warn("[DEPRECATED] atom.unstable_onInit is renamed to atom.INTERNAL_onInit."),t.unstable_onInit(e)},tS=(e,t,n)=>{var r;return(r=t.onMount)==null?void 0:r.call(t,n)},nS=(e,t)=>{var n;const r=ke(e),o=r[0],s=r[6],i=r[9];if((tt?"production":void 0)!=="production"&&!t)throw new Error("Atom is undefined or null");let a=o.get(t);return a||(a={d:new Map,p:new Set,n:0},o.set(t,a),(n=s.i)==null||n.call(s,t),i==null||i(e,t)),a},rS=e=>{const t=ke(e),n=t[1],r=t[3],o=t[4],s=t[5],i=t[6],a=t[13],c=[],u=l=>{try{l()}catch(d){c.push(d)}};do{i.f&&u(i.f);const l=new Set,d=l.add.bind(l);r.forEach(f=>{var h;return(h=n.get(f))==null?void 0:h.l.forEach(d)}),r.clear(),s.forEach(d),s.clear(),o.forEach(d),o.clear(),l.forEach(u),r.size&&a(e)}while(r.size||s.size||o.size);if(c.length)throw new AggregateError(c)},oS=e=>{const t=ke(e),n=t[1],r=t[2],o=t[3],s=t[11],i=t[14],a=t[17],c=[],u=new WeakSet,l=new WeakSet,d=Array.from(o);for(;d.length;){const f=d[d.length-1],h=s(e,f);if(l.has(f)){d.pop();continue}if(u.has(f)){if(r.get(f)===h.n)c.push([f,h]);else if((tt?"production":void 0)!=="production"&&r.has(f))throw new Error("[Bug] invalidated atom exists");l.add(f),d.pop();continue}u.add(f);for(const p of Fu(f,h,n))u.has(p)||d.push(p)}for(let f=c.length-1;f>=0;--f){const[h,p]=c[f];let m=!1;for(const v of p.d.keys())if(v!==h&&o.has(v)){m=!0;break}m&&(i(e,h),a(e,h)),r.delete(h)}},os=new WeakSet,sS=(e,t)=>{var n,r;const o=ke(e),s=o[1],i=o[2],a=o[3],c=o[6],u=o[7],l=o[11],d=o[12],f=o[13],h=o[14],p=o[16],m=o[17],v=o[20],S=l(e,t);if(nc(S)){if(s.has(t)&&i.get(t)!==S.n)return S;let I=!1;for(const[V,D]of S.d)if(h(e,V).n!==D){I=!0;break}if(!I)return S}S.d.clear();let T=!0;function b(){s.has(t)&&(m(e,t),f(e),d(e))}function w(I){var V;if(I===t){const g=l(e,I);if(!nc(g))if($u(I))v(e,I,I.init);else throw new Error("no atom init");return mr(g)}const D=h(e,I);try{return mr(D)}finally{S.d.set(I,D.n),Nu(S.v)&&Vu(t,S.v,D),s.has(t)&&((V=s.get(I))==null||V.t.add(t)),T||b()}}let C,E;const P={get signal(){return C||(C=new AbortController),C.signal},get setSelf(){return(tt?"production":void 0)!=="production"&&!ns(t)&&console.warn("setSelf function cannot be used with read-only atom"),!E&&ns(t)&&(E=(...I)=>{if((tt?"production":void 0)!=="production"&&T&&console.warn("setSelf function cannot be called in sync"),!T)try{return p(e,t,...I)}finally{f(e),d(e)}}),E}},M=S.n;try{(tt?"production":void 0)!=="production"&&os.delete(e);const I=u(e,t,w,P);return(tt?"production":void 0)!=="production"&&os.has(e)&&console.warn("Detected store mutation during atom read. This is not supported."),v(e,t,I),gr(I)&&(rs(I,()=>C==null?void 0:C.abort()),I.then(b,b)),(n=c.r)==null||n.call(c,t),S}catch(I){return delete S.v,S.e=I,++S.n,S}finally{T=!1,M!==S.n&&i.get(t)===M&&(i.set(t,S.n),a.add(t),(r=c.c)==null||r.call(c,t))}},iS=(e,t)=>{const n=ke(e),r=n[1],o=n[2],s=n[11],i=[t];for(;i.length;){const a=i.pop(),c=s(e,a);for(const u of Fu(a,c,r)){const l=s(e,u);o.set(u,l.n),i.push(u)}}},aS=(e,t,...n)=>{const r=ke(e),o=r[3],s=r[6],i=r[8],a=r[11],c=r[12],u=r[13],l=r[14],d=r[15],f=r[16],h=r[17],p=r[20];let m=!0;const v=T=>mr(l(e,T)),S=(T,...b)=>{var w;const C=a(e,T);try{if(T===t){if(!$u(T))throw new Error("atom not writable");(tt?"production":void 0)!=="production"&&os.add(e);const E=C.n,P=b[0];p(e,T,P),h(e,T),E!==C.n&&(o.add(T),d(e,T),(w=s.c)==null||w.call(s,T));return}else return f(e,T,...b)}finally{m||(u(e),c(e))}};try{return i(e,t,v,S,...n)}finally{m=!1}},cS=(e,t)=>{var n;const r=ke(e),o=r[1],s=r[3],i=r[6],a=r[11],c=r[15],u=r[18],l=r[19],d=a(e,t),f=o.get(t);if(f&&!Nu(d.v)){for(const[h,p]of d.d)if(!f.d.has(h)){const m=a(e,h);u(e,h).t.add(t),f.d.add(h),p!==m.n&&(s.add(h),c(e,h),(n=i.c)==null||n.call(i,h))}for(const h of f.d)if(!d.d.has(h)){f.d.delete(h);const p=l(e,h);p==null||p.t.delete(t)}}},lS=(e,t)=>{var n;const r=ke(e),o=r[1],s=r[4],i=r[6],a=r[10],c=r[11],u=r[12],l=r[13],d=r[14],f=r[16],h=r[18],p=c(e,t);let m=o.get(t);if(!m){d(e,t);for(const v of p.d.keys())h(e,v).t.add(t);if(m={l:new Set,d:new Set(p.d.keys()),t:new Set},o.set(t,m),ns(t)){const v=()=>{let S=!0;const T=(...b)=>{try{return f(e,t,...b)}finally{S||(l(e),u(e))}};try{const b=a(e,t,T);b&&(m.u=()=>{S=!0;try{b()}finally{S=!1}})}finally{S=!1}};s.add(v)}(n=i.m)==null||n.call(i,t)}return m},uS=(e,t)=>{var n,r;const o=ke(e),s=o[1],i=o[5],a=o[6],c=o[11],u=o[19],l=c(e,t);let d=s.get(t);if(!d||d.l.size)return d;let f=!1;for(const h of d.t)if((n=s.get(h))!=null&&n.d.has(t)){f=!0;break}if(!f){d.u&&i.add(d.u),d=void 0,s.delete(t);for(const h of l.d.keys()){const p=u(e,h);p==null||p.t.delete(t)}(r=a.u)==null||r.call(a,t);return}return d},dS=(e,t,n)=>{const r=ke(e)[11],o=r(e,t),s="v"in o,i=o.v;if(gr(n))for(const a of o.d.keys())Vu(t,n,r(e,a));o.v=n,delete o.e,(!s||!Object.is(i,o.v))&&(++o.n,gr(i)&&Xx(i))},fS=(e,t)=>{const n=ke(e)[14];return mr(n(e,t))},hS=(e,t,...n)=>{const r=ke(e),o=r[12],s=r[13],i=r[16];try{return i(e,t,...n)}finally{s(e),o(e)}},mS=(e,t,n)=>{const r=ke(e),o=r[12],s=r[18],i=r[19],c=s(e,t).l;return c.add(n),o(e),()=>{c.delete(n),i(e,t),o(e)}},zu=new WeakMap,ke=e=>{const t=zu.get(e);if((tt?"production":void 0)!=="production"&&!t)throw new Error("Store must be created by buildStore to read its building blocks");return t};function pS(...e){const t={get(r){const o=ke(t)[21];return o(t,r)},set(r,...o){const s=ke(t)[22];return s(t,r,...o)},sub(r,o){const s=ke(t)[23];return s(t,r,o)}},n=[new WeakMap,new WeakMap,new WeakMap,new Set,new Set,new Set,{},Jx,Qx,eS,tS,nS,rS,oS,sS,iS,aS,cS,lS,uS,dS,fS,hS,mS,void 0].map((r,o)=>e[o]||r);return zu.set(t,Object.freeze(n)),t}const Wu={};let gS=0;function Jt(e,t){const n=`atom${++gS}`,r={toString(){return(Wu?"production":void 0)!=="production"&&this.debugLabel?n+":"+this.debugLabel:n}};return typeof e=="function"?r.read=e:(r.init=e,r.read=yS,r.write=vS),r}function yS(e){return e(this)}function vS(e,t,n){return t(this,typeof n=="function"?n(e(this)):n)}function bS(){return pS()}let un;function xS(){return un||(un=bS(),(Wu?"production":void 0)!=="production"&&(globalThis.__JOTAI_DEFAULT_STORE__||(globalThis.__JOTAI_DEFAULT_STORE__=un),globalThis.__JOTAI_DEFAULT_STORE__!==un&&console.warn("Detected multiple Jotai instances. It may cause unexpected behavior with the default store. https://github.com/pmndrs/jotai/discussions/2044"))),un}const SS={},TS=x.createContext(void 0);function Uu(e){return x.useContext(TS)||xS()}const ss=e=>typeof(e==null?void 0:e.then)=="function",is=e=>{e.status||(e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}))},CS=x.use||(e=>{if(e.status==="pending")throw e;if(e.status==="fulfilled")return e.value;throw e.status==="rejected"?e.reason:(is(e),e)}),yo=new WeakMap,rc=(e,t)=>{let n=yo.get(e);return n||(n=new Promise((r,o)=>{let s=e;const i=u=>l=>{s===u&&r(l)},a=u=>l=>{s===u&&o(l)},c=()=>{try{const u=t();ss(u)?(yo.set(u,n),s=u,u.then(i(u),a(u)),rs(u,c)):r(u)}catch(u){o(u)}};e.then(i(e),a(e)),rs(e,c)}),yo.set(e,n)),n};function yr(e,t){const{delay:n,unstable_promiseStatus:r=!x.use}={},o=Uu(),[[s,i,a],c]=x.useReducer(l=>{const d=o.get(e);return Object.is(l[0],d)&&l[1]===o&&l[2]===e?l:[d,o,e]},void 0,()=>[o.get(e),o,e]);let u=s;if((i!==o||a!==e)&&(c(),u=o.get(e)),x.useEffect(()=>{const l=o.sub(e,()=>{if(r)try{const d=o.get(e);ss(d)&&is(rc(d,()=>o.get(e)))}catch{}if(typeof n=="number"){setTimeout(c,n);return}c()});return c(),l},[o,e,n,r]),x.useDebugValue(u),ss(u)){const l=rc(u,()=>o.get(e));return r&&is(l),CS(l)}return u}function wS(e,t){const n=Uu();return x.useCallback((...o)=>{if((SS?"production":void 0)!=="production"&&!("write"in e))throw new Error("not writable atom");return n.set(e,...o)},[n,e])}function zt(e,t){return[yr(e),wS(e)]}const Js=Jt(0),Qs=Jt(!0),ei=Jt(null),Hu=Jt({windowSeconds:24*60*60,fps:30}),Gu=Jt([]),Ku=Jt([]);function be(e,t,n){return Math.min(n,Math.max(t,e))}function ft(e){const{time:t,windowStart:n,windowSeconds:r,width:o}=e;return o<=0||r<=0?0:(t-n)/r*o}function dn(e){const{px:t,windowStart:n,windowSeconds:r,width:o}=e;return o<=0||r<=0?n:n+t/o*r}function we(e){return String(Math.floor(e)).padStart(2,"0")}function _S(e=Date.now()){const t=new Date(e);return t.getHours()*3600+t.getMinutes()*60+t.getSeconds()+t.getMilliseconds()/1e3}function vo(e){const t=Math.max(0,e),n=Math.floor(t/3600)%24,r=Math.floor(t%3600/60),o=Math.floor(t%60);return`${we(n)}:${we(r)}:${we(o)}`}function ES(e,t){const n=Math.max(0,e),r=Math.floor(n/3600)%24,o=Math.floor(n%3600/60),s=Math.floor(n%60),i=n-Math.floor(n),a=Math.floor(i*t);return`${we(r)}:${we(o)}:${we(s)}:${we(a)}`}function bo(e){const t=Math.max(0,e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),o=Math.floor(t%60);return n>0?`${we(n)}:${we(r)}:${we(o)}`:`${we(r)}:${we(o)}`}function AS(e,t){const n=Math.max(0,e),r=Math.floor(n/3600),o=Math.floor(n%3600/60),s=Math.floor(n%60),i=n-Math.floor(n),a=Math.floor(i*t);return r>0?`${we(r)}:${we(o)}:${we(s)}:${we(a)}`:`${we(o)}:${we(s)}:${we(a)}`}function MS(e){const{width:t,windowSeconds:n,fps:r}=e,o=t>0?t/n:0,s=1/Math.max(1,r),i=[s,2*s,5*s,.25,.5,1,2,5,10,15,30,60,2*60,5*60,10*60,15*60,30*60,60*60,2*60*60,3*60*60,6*60*60],a=90,c=45;let u=i[i.length-1];for(const f of i)if(f*o>=a){u=f;break}const l=[u/2,u/5,u/10].filter(f=>f>0);let d=l[0]??u;for(const f of l)if(f*o>=c){d=f;break}return{majorStep:u,minorStep:d}}const PS=(e,t,n)=>t>=3600?vo(e).slice(0,2)+":00:00":t>=60?vo(e).slice(0,5):t>=1?vo(e):ES(e,n),kS=(e,t,n)=>t>=3600||t>=60||t>=1?bo(e):AS(e,n);function IS(){const e=x.useRef(null),[t,n]=x.useState(0);return x.useLayoutEffect(()=>{const r=e.current;if(!r)return;const o=new ResizeObserver(()=>{n(r.getBoundingClientRect().width)});return o.observe(r),n(r.getBoundingClientRect().width),()=>o.disconnect()},[]),{ref:e,width:t}}function RS(e){const{totalSeconds:t,enableWheelZoom:n,autoZoomOnSelection:r,tickLabelFormatter:o,clearSelectionOnEventClick:s}=e,[i,a]=zt(Js),[c,u]=zt(Qs),[l,d]=zt(ei),f=yr(Gu),h=yr(Ku),[p,m]=zt(Hu),{ref:v,width:S}=IS(),T=102,w=Math.max(0,S-T-10),[C,E]=x.useState(0),P=x.useMemo(()=>{const O=Math.max(1/Math.max(1,p.fps),.05);return be(p.windowSeconds,O,t)},[p.windowSeconds,p.fps,t]);x.useEffect(()=>{if(!c||S<=0)return;const O=be(i-P*.9,0,Math.max(0,t-P));E(O)},[i,c,S,P,t]);const M=x.useMemo(()=>{const O=be(C,0,Math.max(0,t-P)),B=O+P;return{start:O,end:B,seconds:P}},[C,t,P]),I=x.useMemo(()=>{if(w<=0)return[];const{majorStep:O,minorStep:B}=MS({width:w,windowSeconds:M.seconds,fps:p.fps}),Y=Math.floor(M.start/B)*B,U=M.end,z=[],Z=B*1e-6;for(let q=Y;q<=U+Z;q+=B){const J=ft({time:q,windowStart:M.start,windowSeconds:M.seconds,width:w});if(J<-1||J>w+1)continue;const me=Math.abs(q/O-Math.round(q/O))<1e-6;z.push({time:q,px:J,kind:me?"major":"minor",label:me?o(q,O,p.fps):void 0})}return z},[w,o,M.end,M.seconds,M.start,p.fps]),V=x.useRef(null),D=x.useRef(null),g=O=>{D.current=O,V.current==null&&(V.current=requestAnimationFrame(()=>{V.current=null;const B=D.current;D.current=null,B==null||B()}))};x.useEffect(()=>()=>{V.current!=null&&cancelAnimationFrame(V.current)},[]);const $=x.useRef(null),R=O=>{const B=v.current;if(!B)return 0;const Y=B.getBoundingClientRect();return be(O-Y.left-T,0,w)};return{viewportRef:v,width:S,axisLeft:T,axisWidth:w,totalSeconds:t,zoom:p,setZoom:m,isLive:c,setIsLive:u,currentTime:i,selectedRange:l,setSelectedRange:d,videoSegments:f,events:h,view:M,ticks:I,onWheel:O=>{if(!n||S<=0)return;O.preventDefault(),u(!1);const B=R(O.clientX),Y=be(dn({px:B,windowStart:M.start,windowSeconds:M.seconds,width:w}),0,t),z=O.deltaY<0?.8:1.25,Z=be(M.seconds*z,Math.max(1/Math.max(1,p.fps),.05),t),q=be(Y-B/Math.max(1,w)*Z,0,Math.max(0,t-Z));m(J=>({...J,windowSeconds:Z})),E(q)},onPointerDownScrub:O=>{if(O.button!==0)return;const B=v.current;if(!B)return;B.setPointerCapture(O.pointerId);const Y=R(O.clientX),U=be(dn({px:Y,windowStart:M.start,windowSeconds:M.seconds,width:w}),0,t);u(!1),$.current={mode:"playhead",pointerId:O.pointerId,startPx:Y,startTime:U},a(U)},onPointerDownSelect:O=>{if(O.button!==0)return;const B=v.current;if(!B)return;B.setPointerCapture(O.pointerId);const Y=R(O.clientX),U=be(dn({px:Y,windowStart:M.start,windowSeconds:M.seconds,width:w}),0,t);u(!1),$.current={mode:"select",pointerId:O.pointerId,startPx:Y,startTime:U},d({start:U,end:U})},onPointerDownPlayhead:O=>{if(O.button!==0)return;const B=v.current;if(!B)return;B.setPointerCapture(O.pointerId);const Y=R(O.clientX),U=be(dn({px:Y,windowStart:M.start,windowSeconds:M.seconds,width:w}),0,t);u(!1),$.current={mode:"playhead",pointerId:O.pointerId,startPx:Y,startTime:U},a(U)},onPointerMove:O=>{const B=$.current;if(!B||B.pointerId!==O.pointerId)return;const Y=R(O.clientX);g(()=>{const U=be(dn({px:Y,windowStart:M.start,windowSeconds:M.seconds,width:w}),0,t);if(B.mode==="playhead")a(U);else{const z=Math.min(B.startTime,U),Z=Math.max(B.startTime,U);d({start:z,end:Z})}})},onPointerUp:O=>{const B=$.current;if(!(!B||B.pointerId!==O.pointerId)&&($.current=null,B.mode==="select"&&l)){const Y=Math.abs(l.end-l.start);if(Y<Math.max(1/Math.max(1,p.fps),.1))d(null);else if(r){const U=be(Y*1.05,Math.max(1/Math.max(1,p.fps),.05),t),z=be(l.start,0,Math.max(0,t-U));m(Z=>({...Z,windowSeconds:U})),E(z)}}},onClickEvent:O=>{s&&d(null),u(!1),a(be(O,0,t)),E(be(O-M.seconds/2,0,Math.max(0,t-M.seconds)))},resetView:()=>{u(!1),m(O=>({...O,windowSeconds:t})),E(0)}}}const Yu=({ticks:e,tickColor:t,labelColor:n})=>y.jsx("div",{className:ee.trackArea,children:e.map(r=>y.jsxs("div",{children:[y.jsx("div",{className:`${ee.tick} ${r.kind==="minor"?ee.tickMinor:ee.tickMajor}`.trim(),style:{left:`${r.px}px`,backgroundColor:t}}),r.kind==="major"&&r.label?y.jsx("div",{className:ee.tickLabel,style:{left:`${r.px}px`,color:n},children:r.label}):null]},`${r.time}-${r.kind}`))});Yu.displayName="TimeScale";const Zu=({segments:e,viewStart:t,viewSeconds:n,width:r,totalSeconds:o,segmentColor:s,segmentColorHover:i})=>{const a=e.map(c=>({start:be(c.start,0,o),end:be(c.end,0,o)})).filter(c=>c.end>c.start).map(c=>{const u=Math.max(c.start,t),l=Math.min(c.end,t+n);return{start:u,end:l}}).filter(c=>c.end>c.start);return y.jsx("div",{className:ee.trackArea,children:a.map((c,u)=>{const l=ft({time:c.start,windowStart:t,windowSeconds:n,width:r}),d=ft({time:c.end,windowStart:t,windowSeconds:n,width:r}),f=Math.max(0,d-l);return y.jsx("div",{className:ee.segment,style:{left:`${l}px`,width:`${f}px`,background:s},onMouseEnter:h=>{h.currentTarget.style.background=i},onMouseLeave:h=>{h.currentTarget.style.background=s},"aria-hidden":!0},`${c.start}-${c.end}-${u}`)})})};Zu.displayName="VideoTrack";const qu=({events:e,viewStart:t,viewSeconds:n,width:r,totalSeconds:o,onClickEvent:s,eventBg:i,eventBgHover:a,eventDot:c})=>{const u=e.map(l=>({...l,time:be(l.time,0,o)})).filter(l=>l.time>=t&&l.time<=t+n);return y.jsx("div",{className:ee.trackArea,children:u.map(l=>{const d=ft({time:l.time,windowStart:t,windowSeconds:n,width:r});return y.jsx("button",{type:"button",className:ee.event,onPointerDown:f=>{f.stopPropagation()},onClick:()=>s(l.time),style:{left:`${d}px`,backgroundColor:i,border:"none",padding:0},onMouseEnter:f=>{f.currentTarget.style.backgroundColor=a},onMouseLeave:f=>{f.currentTarget.style.backgroundColor=i},"aria-label":`Evento em ${l.time.toFixed(2)}s`,children:l.icon?l.icon:y.jsx("span",{className:ee.eventDot,style:{backgroundColor:c}})},l.id)})})};qu.displayName="EventsTrack";const Xu=({className:e,title:t="Timeline",subtitle:n="Arraste para selecionar e aplicar zoom no período desejado",showHeader:r=!0,timeScaleMode:o="day24h",tickLabelFormatter:s,totalSeconds:i=24*60*60,enableWheelZoom:a=!0,height:c=190,autoZoomOnSelection:u=!0,showZoomControls:l=!0,enableScrubOnTracks:d=!1,clearSelectionOnEventClick:f=!0})=>{const h=X.useTheme(),p=s??(o==="duration"?kS:PS),{viewportRef:m,axisLeft:v,axisWidth:S,zoom:T,currentTime:b,selectedRange:w,videoSegments:C,events:E,view:P,ticks:M,onWheel:I,onPointerDownScrub:V,onPointerDownSelect:D,onPointerDownPlayhead:g,onPointerMove:$,onPointerUp:R,onClickEvent:W,resetView:K,setZoom:G}=RS({totalSeconds:i,enableWheelZoom:a,autoZoomOnSelection:u,tickLabelFormatter:p,clearSelectionOnEventClick:f}),j=S?v+ft({time:b,windowStart:P.start,windowSeconds:P.seconds,width:S}):v,Q=h.palette.common.white,L=X.alpha(h.palette.common.black,.16),_="0px 4px 5.3px 0px rgba(0,0,0,0.16)",N=h.palette.mode==="dark"?X.alpha(h.palette.common.white,.7):"#79747e",O=X.alpha(h.palette.common.black,.16),B="#2c2c2c",Y=X.alpha(h.palette.primary.main,.15),U=X.alpha(h.palette.primary.main,.22),z=X.alpha(h.palette.common.white,1),Z=X.alpha(h.palette.common.white,1),q=X.alpha(h.palette.common.black,.55),J=X.alpha(h.palette.primary.main,.12),me=h.palette.primary.main,F=Math.max(1/Math.max(1,T.fps),.5),_e=F/i,Ue=(()=>{const Qt=be(P.seconds,F,i);if(_e<=0||_e>=1)return 0;const en=Math.log(Qt/i)/Math.log(_e)*100;return be(en,0,100)})(),it=Qt=>{const en=be(Qt,0,100),tn=i*Math.pow(_e,en/100);G(Nr=>({...Nr,windowSeconds:be(tn,F,i)}))},$r=`${Math.round(Ue)}%`;return y.jsxs(A.Box,{className:`${ee.root} ${ee.container} ${e??""}`.trim(),sx:{backgroundColor:Q,border:`1px solid ${L}`,boxShadow:_,px:1,py:2},children:[r?y.jsxs("div",{className:ee.header,children:[y.jsxs("div",{className:ee.headerText,children:[y.jsx(A.Typography,{variant:"subtitle1",sx:{color:N,fontWeight:500},children:t}),y.jsx(A.Typography,{variant:"body2",sx:{color:N},children:n})]}),l?y.jsxs("div",{className:ee.controls,children:[y.jsx(A.Box,{className:ee.iconButton,sx:{border:`1px solid ${X.alpha(h.palette.common.black,.22)}`},children:y.jsx(A.IconButton,{size:"small",onClick:K,"aria-label":"Reset zoom",sx:{width:32,height:32},children:y.jsx(xx,{fontSize:"small"})})}),y.jsxs(A.Box,{className:ee.zoomGroup,sx:{backgroundColor:h.palette.common.white,border:`1px solid ${X.alpha(h.palette.common.black,.22)}`},"aria-label":"Zoom controls",children:[y.jsx(A.IconButton,{size:"small","aria-label":"Zoom out",onClick:()=>it(Ue-10),children:y.jsx(Tx,{fontSize:"small"})}),y.jsxs("div",{className:ee.zoomTrack,"aria-hidden":!0,children:[y.jsx("div",{style:{position:"absolute",inset:0,backgroundColor:X.alpha("#f5f5f5",.3),borderRadius:1,boxShadow:"1px 1px 1px rgba(10,10,10,0.04)"}}),y.jsx("div",{className:ee.zoomTrackFill,style:{width:$r,backgroundColor:"#f5f5f5",boxShadow:"1px 1px 1px rgba(10,10,10,0.04)"}})]}),y.jsx(A.IconButton,{size:"small","aria-label":"Zoom in",onClick:()=>it(Ue+10),children:y.jsx(Sx,{fontSize:"small"})})]})]}):null]}):null,y.jsx(A.Box,{sx:{mt:r?2:0,height:c},children:y.jsxs("div",{ref:m,className:ee.layers,onWheel:I,onPointerMove:$,onPointerUp:R,children:[y.jsxs("div",{className:ee.playhead,style:{left:`${j}px`},onPointerDown:g,role:"slider","aria-label":"Playhead","aria-valuemin":0,"aria-valuemax":i,"aria-valuenow":b,tabIndex:0,children:[y.jsx("div",{className:ee.playheadHandle,style:{borderBottomColor:me}}),y.jsx("div",{className:ee.playheadLine,style:{backgroundColor:me}})]}),y.jsxs("div",{className:`${ee.trackLabelRow} ${ee.timeScale}`.trim(),children:[y.jsx("div",{}),y.jsx("div",{onPointerDown:V,style:{height:"100%",cursor:"ew-resize"},"aria-label":"Régua do tempo",children:y.jsx(Yu,{ticks:M,tickColor:O,labelColor:B})})]}),y.jsxs(A.Box,{className:ee.trackBox,sx:{mt:1,border:`1px solid ${X.alpha(h.palette.common.black,.1)}`,borderRadius:"12px",height:106,position:"relative"},children:[w?y.jsx("div",{className:ee.selectionOverlay,style:{left:`${v+ft({time:w.start,windowStart:P.start,windowSeconds:P.seconds,width:S})}px`,width:`${Math.max(0,ft({time:w.end,windowStart:P.start,windowSeconds:P.seconds,width:S})-ft({time:w.start,windowStart:P.start,windowSeconds:P.seconds,width:S}))}px`,backgroundColor:J}}):null,y.jsxs("div",{className:`${ee.trackLabelRow} ${ee.videoTrack}`.trim(),children:[y.jsx("div",{className:ee.label,style:{color:N},children:"Video"}),y.jsx("div",{onPointerDown:d?V:void 0,style:{height:"100%"},children:y.jsx(Zu,{segments:C,viewStart:P.start,viewSeconds:P.seconds,width:S,totalSeconds:i,segmentColor:Y,segmentColorHover:U})})]}),y.jsxs("div",{className:`${ee.trackLabelRow} ${ee.eventsTrack}`.trim(),children:[y.jsx("div",{className:ee.label,style:{color:N},children:"Eventos"}),y.jsx("div",{onPointerDown:d?V:void 0,style:{height:"100%"},children:y.jsx(qu,{events:E,viewStart:P.start,viewSeconds:P.seconds,width:S,totalSeconds:i,onClickEvent:W,eventBg:z,eventBgHover:Z,eventDot:q})})]}),y.jsx("div",{onPointerDown:D,style:{position:"absolute",left:v,right:10,top:0,bottom:0,cursor:"crosshair"},"aria-label":"Arraste para selecionar"})]})]})})]})};Xu.displayName="VideoTimeline";const Ju=({stream:e=null,src:t,autoPlay:n=!0,muted:r=!0,playsInline:o=!0,className:s,liveEdgeThresholdSeconds:i=2,updateTimeForLiveStream:a=!0,constrainToSelectedRange:c=!0,loopSelection:u=!1})=>{const l=x.useRef(null),[d,f]=zt(Js),[h,p]=zt(Qs),m=yr(ei),v=!!e;x.useEffect(()=>{const b=l.current;if(b){if(e){b.srcObject=e;return}b.srcObject=null,t&&(b.src=t)}},[e,t]),x.useEffect(()=>{const b=l.current;if(!b||v)return;const w=()=>{if(c&&m){const P=Math.max(0,m.start),M=Math.max(P,m.end);b.currentTime<P?b.currentTime=P:b.currentTime>M&&(u?b.currentTime=P:(b.pause(),b.currentTime=M))}if(f(b.currentTime),Number.isFinite(b.duration)&&b.duration>0){const P=b.duration-b.currentTime<=i;p(P)}},C=()=>{if(!c||!m)return;const P=Math.max(0,m.start),M=Math.max(P,m.end);(b.currentTime<P||b.currentTime>M)&&(b.currentTime=P)},E=()=>{h&&Number.isFinite(b.duration)&&b.duration>0&&(b.currentTime=b.duration)};return b.addEventListener("timeupdate",w),b.addEventListener("play",C),b.addEventListener("loadedmetadata",E),()=>{b.removeEventListener("timeupdate",w),b.removeEventListener("play",C),b.removeEventListener("loadedmetadata",E)}},[c,v,h,i,u,m,f,p]);const S=x.useRef(-1);x.useEffect(()=>{const b=l.current;if(!b||v||!t)return;if(h){if(Number.isFinite(b.duration)&&b.duration>0){const C=b.duration;Math.abs(b.currentTime-C)>.25&&(b.currentTime=C,S.current=C)}return}if(Math.abs(S.current-d)<.05)return;let w=d;if(c&&m){const C=Math.max(0,m.start),E=Math.max(C,m.end);w=Math.min(E,Math.max(C,w))}Math.abs(b.currentTime-w)>.25&&(b.currentTime=w,S.current=d)},[c,d,h,v,m,t]),x.useEffect(()=>{const b=l.current;if(!b||v||!t||!c||!m)return;const w=Math.max(0,m.start),C=!b.paused;b.currentTime=w,S.current=w,p(!1),f(w),C&&b.play().catch(()=>{})},[c,v,m,f,p,t]),x.useEffect(()=>{if(!v||(p(!0),!a))return;let b=null,w=!0;const C=()=>{w&&(f(_S()),b=requestAnimationFrame(C))};return b=requestAnimationFrame(C),()=>{w=!1,b!=null&&cancelAnimationFrame(b)}},[v,f,p,a]);const T=x.useMemo(()=>({width:"100%",maxWidth:920,background:"black",aspectRatio:"16 / 9",display:"block"}),[]);return y.jsx("video",{ref:l,className:s,style:T,autoPlay:n,muted:r,playsInline:o,controls:!0})};Ju.displayName="VideoPlayerWebRTC";const OS=st(y.jsx("path",{d:"M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"}),"Done"),LS="_container_1vjy6_1",DS="_segment_1vjy6_7",jS="_selected_1vjy6_20",BS="_label_1vjy6_28",$S="_icon_1vjy6_37",NS="_checkIcon_1vjy6_47",VS="_unselected_1vjy6_53",Ct={container:LS,segment:DS,selected:jS,label:BS,icon:$S,checkIcon:NS,unselected:VS},Qu=({items:e,className:t,sx:n,...r})=>{const s=A.useTheme().palette.mode==="dark",i=(a,c)=>{a.onClick?a.onClick(c):console.log(`Item "${a.label}" clicado`)};return y.jsx(A.Box,{className:`${Ct.container} ${t||""}`,sx:n,"data-theme":s?"dark":"light",...r,children:e.map((a,c)=>y.jsxs(A.Box,{className:`${Ct.segment} ${a.selected?Ct.selected:Ct.unselected}`,onClick:u=>i(a,u),children:[a.selected&&y.jsx(A.Box,{className:Ct.icon,children:y.jsx(OS,{className:Ct.checkIcon})}),y.jsx(A.Box,{className:Ct.label,children:a.label})]},c))})};Qu.displayName="DisplayTypes";const FS=600,xo=[.32,.72,0,1],So=400,ed=({leftContent:e,rightContent:t,gap:n=2,leftRatio:r=.5,leftCollapsed:o=!1,mobileShowOnly:s="both",mobileBreakpointPx:i=FS,className:a,sx:c})=>{const u=A.useTheme(),l=A.useMediaQuery(`(max-width:${i}px)`),d=!l||s==="left"||s==="both",f=!l||s==="right"||s==="both",h=u.spacing(n),p=`flex ${So}ms cubic-bezier(${xo.join(",")}), min-width ${So}ms cubic-bezier(${xo.join(",")})`;if(l&&s!=="both")return y.jsxs(A.Box,{className:a,sx:{display:"grid",gridTemplateColumns:"1fr",width:"100%",height:"100%",minHeight:0,overflow:"hidden",...c},children:[y.jsx(A.Box,{sx:{minWidth:0,minHeight:0,overflow:"hidden",display:d?"flex":"none",flexDirection:"column"},children:e}),y.jsx(A.Box,{sx:{minWidth:0,minHeight:0,overflow:"hidden",display:f?"flex":"none",flexDirection:"column"},children:t})]});const m=o?0:r,v=o?0:void 0,S=o?"none":"auto";return y.jsxs(A.Box,{className:a,sx:{display:"flex",flexDirection:"row",gap:o?0:h,width:"100%",height:"100%",minHeight:0,overflow:"hidden",transition:`gap ${So}ms cubic-bezier(${xo.join(",")})`,...c},children:[y.jsx(A.Box,{sx:{flex:m,minWidth:v,overflow:"hidden",display:"flex",flexDirection:"column",transition:p,pointerEvents:S},children:e}),y.jsx(A.Box,{sx:{flex:1,minWidth:0,minHeight:0,overflow:"hidden",display:"flex",flexDirection:"column"},children:t})]})};ed.displayName="SplitLayout";const zS=256,td=({children:e,minColumns:t=1,maxColumns:n=3,minItemWidthPx:r=zS,gap:o=2,className:s,sx:i})=>{const c=A.useTheme().spacing(o),u=n-1;return y.jsx(A.Box,{className:s,sx:{"--responsive-grid-gap":c,display:"grid",gap:c,width:"100%",minHeight:0,gridTemplateColumns:`repeat(auto-fill, minmax(min(100%, max(${r}px, calc((100% - ${u} * var(--responsive-grid-gap)) / ${n}))), 1fr))`,alignContent:"start",...i},children:e})};td.displayName="ResponsiveGrid";exports.Button=cs;exports.CAMERA_ALGORITHM_FACIAL=Dr;exports.CAMERA_ALGORITHM_LPR=jr;exports.CameraCard=S1;exports.CountCard=ep;exports.DisplayTypes=Qu;exports.FilterButton=dc;exports.FilterChip=fc;exports.FilterModal=Rc;exports.GoogleMap=Eu;exports.MapContent=Zs;exports.MapMarkers=Iu;exports.MapSpot=Ks;exports.ModuleMenu=ju;exports.NotFoundContent=Ou;exports.ResponsiveGrid=td;exports.SearchBar=Ru;exports.SidebarMenu=Du;exports.SplitLayout=ed;exports.VideoPlayer=Bu;exports.VideoPlayerWebRTC=Ju;exports.VideoTimeline=Xu;exports.VisioThemeProvider=md;exports.ZoomControls=M1;exports.currentTimeAtom=Js;exports.darkColors=ge;exports.darkTheme=cc;exports.eventsAtom=Ku;exports.isLiveAtom=Qs;exports.lightColors=pe;exports.lightTheme=ac;exports.radiiTokens=Yn;exports.selectedRangeAtom=ei;exports.spacingScale=dd;exports.spacingTokens=sc;exports.typographyTokens=Ee;exports.useGoogleMapContext=Ys;exports.useVisioTheme=pd;exports.videoSegmentsAtom=Gu;exports.zoomAtom=Hu;
99
108
  //# sourceMappingURL=index.cjs.js.map