@useloops/design-system 1.4.176 → 1.4.177

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.js CHANGED
@@ -20,4 +20,4 @@
20
20
  object-assign
21
21
  (c) Sindre Sorhus
22
22
  @license MIT
23
- */function fi(){if(ni)return ti;ni=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return ti=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach((function(e){o[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(o,i){for(var r,s,a=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(o),l=1;l<arguments.length;l++){for(var c in r=Object(arguments[l]))t.call(r,c)&&(a[c]=r[c]);if(e){s=e(r);for(var u=0;u<s.length;u++)n.call(r,s[u])&&(a[s[u]]=r[s[u]])}}return a},ti}function gi(){if(ii)return oi;ii=1;return oi="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function xi(){return si?ri:(si=1,ri=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var vi=mi();Yo.exports=function(){if(ui)return ci;ui=1;var e=mi(),t=fi(),n=gi(),o=xi(),i=function(){if(li)return ai;li=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=gi(),n={},o=xi();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function i(i,r,s,a,l){if("production"!==process.env.NODE_ENV)for(var c in i)if(o(i,c)){var u;try{if("function"!=typeof i[c]){var d=Error((a||"React class")+": "+s+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=i[c](r,c,a,s,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((a||"React class")+": type specification of "+s+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var p=l?l():"";e("Failed "+s+" type: "+u.message+(null!=p?p:""))}}}return i.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},ai=i}(),r=function(){};function s(){return null}return"production"!==process.env.NODE_ENV&&(r=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),ci=function(a,l){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:f("array"),bigint:f("bigint"),bool:f("boolean"),func:f("function"),number:f("number"),object:f("object"),string:f("string"),symbol:f("symbol"),any:m(s),arrayOf:function(e){return m((function(t,o,i,r,s){if("function"!=typeof e)return new h("Property `"+s+"` of component `"+i+"` has invalid PropType notation inside arrayOf.");var a=t[o];if(!Array.isArray(a))return new h("Invalid "+r+" `"+s+"` of type `"+v(a)+"` supplied to `"+i+"`, expected an array.");for(var l=0;l<a.length;l++){var c=e(a,l,i,r,s+"["+l+"]",n);if(c instanceof Error)return c}return null}))},element:m((function(e,t,n,o,i){var r=e[t];return a(r)?null:new h("Invalid "+o+" `"+i+"` of type `"+v(r)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:m((function(t,n,o,i,r){var s=t[n];return e.isValidElementType(s)?null:new h("Invalid "+i+" `"+r+"` of type `"+v(s)+"` supplied to `"+o+"`, expected a single ReactElement type.")})),instanceOf:function(e){return m((function(t,n,o,i,r){if(!(t[n]instanceof e)){var s=e.name||u;return new h("Invalid "+i+" `"+r+"` of type `"+((a=t[n]).constructor&&a.constructor.name?a.constructor.name:u)+"` supplied to `"+o+"`, expected instance of `"+s+"`.")}var a;return null}))},node:m((function(e,t,n,o,i){return x(e[t])?null:new h("Invalid "+o+" `"+i+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return m((function(t,i,r,s,a){if("function"!=typeof e)return new h("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var l=t[i],c=v(l);if("object"!==c)return new h("Invalid "+s+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected an object.");for(var u in l)if(o(l,u)){var d=e(l,u,r,s,a+"."+u,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?m((function(t,n,o,i,r){for(var s=t[n],a=0;a<e.length;a++)if(p(s,e[a]))return null;var l=JSON.stringify(e,(function(e,t){return"symbol"===y(t)?String(t):t}));return new h("Invalid "+i+" `"+r+"` of value `"+String(s)+"` supplied to `"+o+"`, expected one of "+l+".")})):("production"!==process.env.NODE_ENV&&r(arguments.length>1?"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]).":"Invalid argument supplied to oneOf, expected an array."),s)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&r("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var t=0;t<e.length;t++){var i=e[t];if("function"!=typeof i)return r("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+b(i)+" at index "+t+"."),s}return m((function(t,i,r,s,a){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,i,r,s,a,n);if(null==u)return null;u.data&&o(u.data,"expectedType")&&l.push(u.data.expectedType)}return new h("Invalid "+s+" `"+a+"` supplied to `"+r+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")}))},shape:function(e){return m((function(t,o,i,r,s){var a=t[o],l=v(a);if("object"!==l)return new h("Invalid "+r+" `"+s+"` of type `"+l+"` supplied to `"+i+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return g(i,r,s,c,y(u));var d=u(a,c,i,r,s+"."+c,n);if(d)return d}return null}))},exact:function(e){return m((function(i,r,s,a,l){var c=i[r],u=v(c);if("object"!==u)return new h("Invalid "+a+" `"+l+"` of type `"+u+"` supplied to `"+s+"`, expected `object`.");var d=t({},i[r],e);for(var p in d){var m=e[p];if(o(e,p)&&"function"!=typeof m)return g(s,a,l,p,y(m));if(!m)return new h("Invalid "+a+" `"+l+"` key `"+p+"` supplied to `"+s+"`.\nBad object: "+JSON.stringify(i[r],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var f=m(c,p,s,a,l+"."+p,n);if(f)return f}return null}))}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function m(e){if("production"!==process.env.NODE_ENV)var t={},o=0;function i(i,s,a,c,d,p,m){if(c=c||u,p=p||a,m!==n){if(l){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}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=c+":"+a;!t[g]&&o<3&&(r("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+c+"`. 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."),t[g]=!0,o++)}}return null==s[a]?i?null===s[a]?new h("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `null`."):new h("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(s,a,c,d,p)}var s=i.bind(null,!1);return s.isRequired=i.bind(null,!0),s}function f(e){return m((function(t,n,o,i,r,s){var a=t[n];return v(a)!==e?new h("Invalid "+i+" `"+r+"` of type `"+y(a)+"` supplied to `"+o+"`, expected `"+e+"`.",{expectedType:e}):null}))}function g(e,t,n,o,i){return new h((e||"React class")+": "+t+" type `"+n+"."+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+i+"`.")}function x(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(x);if(null===e||a(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,o=t.call(e);if(t!==e.entries){for(;!(n=o.next()).done;)if(!x(n.value))return!1}else for(;!(n=o.next()).done;){var i=n.value;if(i&&!x(i[1]))return!1}return!0;default:return!1}}function v(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function y(e){if(null==e)return""+e;var t=v(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function b(e){var t=y(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,d.checkPropTypes=i,d.resetWarningCache=i.resetWarningCache,d.PropTypes=d,d},ci}()(vi.isElement,!0)}else Yo.exports=function(){if(pi)return di;pi=1;var e=gi();function t(){}function n(){}return n.resetWarningCache=t,di=function(){function o(t,n,o,i,r,s){if(s!==e){var a=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 a.name="Invariant Violation",a}}function i(){return o}o.isRequired=o;var r={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:i,element:o,elementType:o,instanceOf:i,node:o,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return r.PropTypes=r,r}}()();var yi=ue(Yo.exports);function bi(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=bi(e[t]))&&(o&&(o+=" "),o+=n)}else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function wi(){for(var e,t,n=0,o="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=bi(e))&&(o&&(o+=" "),o+=t);return o}const ji=e=>e,Ci=(()=>{let e=ji;return{configure(t){e=t},generate:t=>e(t),reset(){e=ji}}})(),Si={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 ki(e,t,n="Mui"){const o=Si[t];return o?`${n}-${o}`:`${Ci.generate(e)}-${t}`}const Mi=A.createContext({});function Ti(e){return ki("MuiTimeline",e)}function Pi(e){return"alternate-reverse"===e?"positionAlternateReverse":`position${a.capitalize(e)}`}"production"!==process.env.NODE_ENV&&(Mi.displayName="TimelineContext"),function(e,t,n="Mui"){const o={};t.forEach((t=>{o[t]=ki(e,t,n)}))}("MuiTimeline",["root","positionLeft","positionRight","positionAlternate","positionAlternateReverse"]);const Bi=["position","className"],Ai=e=>{const{position:t,classes:n}=e;return function(e,t,n){const o={};return Object.keys(e).forEach((i=>{o[i]=e[i].reduce(((e,o)=>{if(o){const i=t(o);""!==i&&e.push(i),n&&n[o]&&e.push(n[o])}return e}),[]).join(" ")})),o}({root:["root",t&&Pi(t)]},Ti,n)},Ei=s.styled("ul",{name:"MuiTimeline",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.position&&t[Pi(n.position)]]}})({display:"flex",flexDirection:"column",padding:"6px 16px",flexGrow:1}),zi=A.forwardRef((function(e,t){const n=s.useThemeProps({props:e,name:"MuiTimeline"}),{position:o="right",className:i}=n,r=function(e,t){if(null==e)return{};var n={};for(var o in e)if({}.hasOwnProperty.call(e,o)){if(-1!==t.indexOf(o))continue;n[o]=e[o]}return n}(n,Bi),a=Ko({},n,{position:o}),l=Ai(a),c=A.useMemo((()=>({position:o})),[o]);return ge.jsx(Mi.Provider,{value:c,children:ge.jsx(Ei,Ko({className:wi(l.root,i),ownerState:a,ref:t},r))})}));"production"!==process.env.NODE_ENV&&(zi.propTypes={children:yi.node,classes:yi.object,className:yi.string,position:yi.oneOf(["alternate-reverse","alternate","left","right"]),sx:yi.oneOfType([yi.arrayOf(yi.oneOfType([yi.func,yi.object,yi.bool])),yi.func,yi.object])});const Ii=e.createContext({});const Ri=e.createContext(null),Vi=e.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});const Fi="undefined"!=typeof window,Li=Fi?e.useLayoutEffect:e.useEffect,Di=e=>e;let Oi=Di,$i=Di;"production"!==process.env.NODE_ENV&&(Oi=(e,t)=>{e||"undefined"==typeof console||console.warn(t)},$i=(e,t)=>{if(!e)throw new Error(t)});const Hi=!1;const Wi=["read","resolveKeyframes","update","preRender","render","postRender"];function Ni(e,t){let n=!1,o=!0;const i={delta:0,timestamp:0,isProcessing:!1},r=()=>n=!0,s=Wi.reduce(((e,t)=>(e[t]=function(e){let t=new Set,n=new Set,o=!1,i=!1;const r=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(t){r.has(t)&&(l.schedule(t),e()),t(s)}const l={schedule:(e,i=!1,s=!1)=>{const a=s&&o?t:n;return i&&r.add(e),a.has(e)||a.add(e),e},cancel:e=>{n.delete(e),r.delete(e)},process:e=>{s=e,o?i=!0:(o=!0,[t,n]=[n,t],t.forEach(a),t.clear(),o=!1,i&&(i=!1,l.process(e)))}};return l}(r),e)),{}),{read:a,resolveKeyframes:l,update:c,preRender:u,render:d,postRender:p}=s,h=()=>{const r=performance.now();n=!1,i.delta=o?1e3/60:Math.max(Math.min(r-i.timestamp,40),1),i.timestamp=r,i.isProcessing=!0,a.process(i),l.process(i),c.process(i),u.process(i),d.process(i),p.process(i),i.isProcessing=!1,n&&t&&(o=!1,e(h))};return{schedule:Wi.reduce(((t,r)=>{const a=s[r];return t[r]=(t,r=!1,s=!1)=>(n||(n=!0,o=!0,i.isProcessing||e(h)),a.schedule(t,r,s)),t}),{}),cancel:e=>{for(let t=0;t<Wi.length;t++)s[Wi[t]].cancel(e)},state:i,steps:s}}const{schedule:_i,cancel:Ui,state:Gi,steps:qi}=Ni("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:Di,!0),Ki=e.createContext({strict:!1}),Zi={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"]},Yi={};for(const e in Zi)Yi[e]={isEnabled:t=>Zi[e].some((e=>!!t[e]))};const Xi=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 Ji(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Xi.has(e)}let Qi=e=>!Ji(e);try{(er=require("@emotion/is-prop-valid").default)&&(Qi=e=>e.startsWith("on")?!Ji(e):er(e))}catch(e){}var er;const tr=new Set;function nr(e,t,n){e||tr.has(t)||(console.warn(t),tr.add(t))}function or(e){if("undefined"==typeof Proxy)return e;const t=new Map;return new Proxy(((...t)=>("production"!==process.env.NODE_ENV&&nr(!1,"motion() is deprecated. Use motion.create() instead."),e(...t))),{get:(n,o)=>"create"===o?e:(t.has(o)||t.set(o,e(o)),t.get(o))})}const ir=e.createContext({});function rr(e){return"string"==typeof e||Array.isArray(e)}function sr(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}const ar=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],lr=["initial",...ar];function cr(e){return sr(e.animate)||lr.some((t=>rr(e[t])))}function ur(e){return Boolean(cr(e)||e.variants)}function dr(t){const{initial:n,animate:o}=function(e,t){if(cr(e)){const{initial:t,animate:n}=e;return{initial:!1===t||rr(t)?t:void 0,animate:rr(n)?n:void 0}}return!1!==e.inherit?t:{}}(t,e.useContext(ir));return e.useMemo((()=>({initial:n,animate:o})),[pr(n),pr(o)])}function pr(e){return Array.isArray(e)?e.join(" "):e}const hr=Symbol.for("motionComponentSymbol");function mr(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function fr(t,n,o){return e.useCallback((e=>{e&&t.onMount&&t.onMount(e),n&&(e?n.mount(e):n.unmount()),o&&("function"==typeof o?o(e):mr(o)&&(o.current=e))}),[n])}const gr=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),xr="data-"+gr("framerAppearId"),{schedule:vr,cancel:yr}=Ni(queueMicrotask,!1),br=e.createContext({});function wr(t,n,o,i,r){var s,a;const{visualElement:l}=e.useContext(ir),c=e.useContext(Ki),u=e.useContext(Ri),d=e.useContext(Vi).reducedMotion,p=e.useRef(null);i=i||c.renderer,!p.current&&i&&(p.current=i(t,{visualState:n,parent:l,props:o,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:d}));const h=p.current,m=e.useContext(br);!h||h.projection||!r||"html"!==h.type&&"svg"!==h.type||function(e,t,n,o){const{layoutId:i,layout:r,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:jr(e.parent)),e.projection.setOptions({layoutId:i,layout:r,alwaysMeasureLayout:Boolean(s)||a&&mr(a),visualElement:e,animationType:"string"==typeof r?r:"both",initialPromotionConfig:o,layoutScroll:l,layoutRoot:c})}(p.current,o,r,m);const f=e.useRef(!1);e.useInsertionEffect((()=>{h&&f.current&&h.update(o,u)}));const g=o[xr],x=e.useRef(Boolean(g)&&!(null===(s=window.MotionHandoffIsComplete)||void 0===s?void 0:s.call(window,g))&&(null===(a=window.MotionHasOptimisedAnimation)||void 0===a?void 0:a.call(window,g)));return Li((()=>{h&&(f.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),vr.render(h.render),x.current&&h.animationState&&h.animationState.animateChanges())})),e.useEffect((()=>{h&&(!x.current&&h.animationState&&h.animationState.animateChanges(),x.current&&(queueMicrotask((()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)})),x.current=!1))})),h}function jr(e){if(e)return!1!==e.options.allowProjection?e.projection:jr(e.parent)}function Cr({preloadedFeatures:t,createVisualElement:n,useRender:o,useVisualState:i,Component:r}){var s,a;function l(s,a){let l;const c={...e.useContext(Vi),...s,layoutId:Sr(s)},{isStatic:u}=c,d=dr(s),p=i(s,u);if(!u&&Fi){!function(t,n){const o=e.useContext(Ki).strict;if("production"!==process.env.NODE_ENV&&n&&o){const e="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";t.ignoreStrict?Oi(!1,e):$i(!1,e)}}(c,t);const o=function(e){const{drag:t,layout:n}=Yi;if(!t&&!n)return{};const o={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}(c);l=o.MeasureLayout,d.visualElement=wr(r,p,c,n,o.ProjectionNode)}return ge.jsxs(ir.Provider,{value:d,children:[l&&d.visualElement?ge.jsx(l,{visualElement:d.visualElement,...c}):null,o(r,s,fr(p,d.visualElement,a),p,u,d.visualElement)]})}t&&function(e){for(const t in e)Yi[t]={...Yi[t],...e[t]}}(t),l.displayName=`motion.${"string"==typeof r?r:`create(${null!==(a=null!==(s=r.displayName)&&void 0!==s?s:r.name)&&void 0!==a?a:""})`}`;const c=e.forwardRef(l);return c[hr]=r,c}function Sr({layoutId:t}){const n=e.useContext(Ii).id;return n&&void 0!==t?n+"-"+t:t}const kr=["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 Mr(e){return"string"==typeof e&&!e.includes("-")&&!!(kr.indexOf(e)>-1||/[A-Z]/u.test(e))}function Tr(e){const t=[{},{}];return null==e||e.values.forEach(((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()})),t}function Pr(e,t,n,o){if("function"==typeof t){const[i,r]=Tr(o);t=t(void 0!==n?n:e.custom,i,r)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){const[i,r]=Tr(o);t=t(void 0!==n?n:e.custom,i,r)}return t}const Br=e=>Array.isArray(e),Ar=e=>Boolean(e&&e.getVelocity);function Er(e){const t=Ar(e)?e.get():e;return n=t,Boolean(n&&"object"==typeof n&&n.mix&&n.toValue)?t.toValue():t;var n}const zr=t=>(n,o)=>{const i=e.useContext(ir),r=e.useContext(Ri),s=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},o,i,r){const s={latestValues:Ir(o,i,r,e),renderState:t()};return n&&(s.onMount=e=>n({props:o,current:e,...s}),s.onUpdate=e=>n(e)),s}(t,n,i,r);return o?s():function(t){const n=e.useRef(null);return null===n.current&&(n.current=t()),n.current}(s)};function Ir(e,t,n,o){const i={},r=o(e,{});for(const e in r)i[e]=Er(r[e]);let{initial:s,animate:a}=e;const l=cr(e),c=ur(e);t&&c&&!l&&!1!==e.inherit&&(void 0===s&&(s=t.initial),void 0===a&&(a=t.animate));let u=!!n&&!1===n.initial;u=u||!1===s;const d=u?a:s;if(d&&"boolean"!=typeof d&&!sr(d)){const t=Array.isArray(d)?d:[d];for(let n=0;n<t.length;n++){const o=Pr(e,t[n]);if(o){const{transitionEnd:e,transition:t,...n}=o;for(const e in n){let t=n[e];if(Array.isArray(t)){t=t[u?t.length-1:0]}null!==t&&(i[e]=t)}for(const t in e)i[t]=e[t]}}}return i}const Rr=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Vr=new Set(Rr),Fr=e=>t=>"string"==typeof t&&t.startsWith(e),Lr=Fr("--"),Dr=Fr("var(--"),Or=e=>!!Dr(e)&&$r.test(e.split("/*")[0].trim()),$r=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Hr=(e,t)=>t&&"number"==typeof e?t.transform(e):e,Wr=(e,t,n)=>n>t?t:n<e?e:n,Nr={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},_r={...Nr,transform:e=>Wr(0,1,e)},Ur={...Nr,default:1},Gr=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),qr=Gr("deg"),Kr=Gr("%"),Zr=Gr("px"),Yr=Gr("vh"),Xr=Gr("vw"),Jr={...Kr,parse:e=>Kr.parse(e)/100,transform:e=>Kr.transform(100*e)},Qr={borderWidth:Zr,borderTopWidth:Zr,borderRightWidth:Zr,borderBottomWidth:Zr,borderLeftWidth:Zr,borderRadius:Zr,radius:Zr,borderTopLeftRadius:Zr,borderTopRightRadius:Zr,borderBottomRightRadius:Zr,borderBottomLeftRadius:Zr,width:Zr,maxWidth:Zr,height:Zr,maxHeight:Zr,top:Zr,right:Zr,bottom:Zr,left:Zr,padding:Zr,paddingTop:Zr,paddingRight:Zr,paddingBottom:Zr,paddingLeft:Zr,margin:Zr,marginTop:Zr,marginRight:Zr,marginBottom:Zr,marginLeft:Zr,backgroundPositionX:Zr,backgroundPositionY:Zr},es={rotate:qr,rotateX:qr,rotateY:qr,rotateZ:qr,scale:Ur,scaleX:Ur,scaleY:Ur,scaleZ:Ur,skew:qr,skewX:qr,skewY:qr,distance:Zr,translateX:Zr,translateY:Zr,translateZ:Zr,x:Zr,y:Zr,z:Zr,perspective:Zr,transformPerspective:Zr,opacity:_r,originX:Jr,originY:Jr,originZ:Zr},ts={...Nr,transform:Math.round},ns={...Qr,...es,zIndex:ts,size:Zr,fillOpacity:_r,strokeOpacity:_r,numOctaves:ts},os={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},is=Rr.length;function rs(e,t,n){const{style:o,vars:i,transformOrigin:r}=e;let s=!1,a=!1;for(const e in t){const n=t[e];if(Vr.has(e))s=!0;else if(Lr(e))i[e]=n;else{const t=Hr(n,ns[e]);e.startsWith("origin")?(a=!0,r[e]=t):o[e]=t}}if(t.transform||(s||n?o.transform=function(e,t,n){let o="",i=!0;for(let r=0;r<is;r++){const s=Rr[r],a=e[s];if(void 0===a)continue;let l=!0;if(l="number"==typeof a?a===(s.startsWith("scale")?1:0):0===parseFloat(a),!l||n){const e=Hr(a,ns[s]);l||(i=!1,o+=`${os[s]||s}(${e}) `),n&&(t[s]=e)}}return o=o.trim(),n?o=n(t,i?"":o):i&&(o="none"),o}(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:e="50%",originY:t="50%",originZ:n=0}=r;o.transformOrigin=`${e} ${t} ${n}`}}const ss={offset:"stroke-dashoffset",array:"stroke-dasharray"},as={offset:"strokeDashoffset",array:"strokeDasharray"};function ls(e,t,n){return"string"==typeof e?e:Zr.transform(t+n*e)}function cs(e,{attrX:t,attrY:n,attrScale:o,originX:i,originY:r,pathLength:s,pathSpacing:a=1,pathOffset:l=0,...c},u,d){if(rs(e,c,d),u)return void(e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox));e.attrs=e.style,e.style={};const{attrs:p,style:h,dimensions:m}=e;p.transform&&(m&&(h.transform=p.transform),delete p.transform),m&&(void 0!==i||void 0!==r||h.transform)&&(h.transformOrigin=function(e,t,n){return`${ls(t,e.x,e.width)} ${ls(n,e.y,e.height)}`}(m,void 0!==i?i:.5,void 0!==r?r:.5)),void 0!==t&&(p.x=t),void 0!==n&&(p.y=n),void 0!==o&&(p.scale=o),void 0!==s&&function(e,t,n=1,o=0,i=!0){e.pathLength=1;const r=i?ss:as;e[r.offset]=Zr.transform(-o);const s=Zr.transform(t),a=Zr.transform(n);e[r.array]=`${s} ${a}`}(p,s,a,l,!1)}const us=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),ds=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}}),ps=e=>"string"==typeof e&&"svg"===e.toLowerCase();function hs(e,{style:t,vars:n},o,i){Object.assign(e.style,t,i&&i.getProjectionStyles(o));for(const t in n)e.style.setProperty(t,n[t])}const ms=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"]);function fs(e,t,n,o){hs(e,t,void 0,o);for(const n in t.attrs)e.setAttribute(ms.has(n)?n:gr(n),t.attrs[n])}const gs={};function xs(e,{layout:t,layoutId:n}){return Vr.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!gs[e]||"opacity"===e)}function vs(e,t,n){var o;const{style:i}=e,r={};for(const s in i)(Ar(i[s])||t.style&&Ar(t.style[s])||xs(s,e)||void 0!==(null===(o=null==n?void 0:n.getValue(s))||void 0===o?void 0:o.liveStyle))&&(r[s]=i[s]);return r}function ys(e,t,n){const o=vs(e,t,n);for(const n in e)if(Ar(e[n])||Ar(t[n])){o[-1!==Rr.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=e[n]}return o}const bs=["x","y","width","height","cx","cy","r"],ws={useVisualState:zr({scrapeMotionValuesFromProps:ys,createRenderState:ds,onUpdate:({props:e,prevProps:t,current:n,renderState:o,latestValues:i})=>{if(!n)return;let r=!!e.drag;if(!r)for(const e in i)if(Vr.has(e)){r=!0;break}if(!r)return;let s=!t;if(t)for(let n=0;n<bs.length;n++){const o=bs[n];e[o]!==t[o]&&(s=!0)}s&&_i.read((()=>{!function(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(e){t.dimensions={x:0,y:0,width:0,height:0}}}(n,o),_i.render((()=>{cs(o,i,ps(n.tagName),e.transformTemplate),fs(n,o)}))}))}})},js={useVisualState:zr({scrapeMotionValuesFromProps:vs,createRenderState:us})};function Cs(e,t,n){for(const o in t)Ar(t[o])||xs(o,n)||(e[o]=t[o])}function Ss(t,n){const o={};return Cs(o,t.style||{},t),Object.assign(o,function({transformTemplate:t},n){return e.useMemo((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{}};return rs(e,n,t),Object.assign({},e.vars,e.style)}),[n])}(t,n)),o}function ks(e,t){const n={},o=Ss(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=o,n}function Ms(t,n,o,i){const r=e.useMemo((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return cs(e,n,ps(i),t.transformTemplate),{...e.attrs,style:{...e.style}}}),[n]);if(t.style){const e={};Cs(e,t.style,t),r.style={...e,...r.style}}return r}function Ts(t=!1){return(n,o,i,{latestValues:r},s)=>{const a=(Mr(n)?Ms:ks)(o,r,s,n),l=function(e,t,n){const o={};for(const i in e)"values"===i&&"object"==typeof e.values||(Qi(i)||!0===n&&Ji(i)||!t&&!Ji(i)||e.draggable&&i.startsWith("onDrag"))&&(o[i]=e[i]);return o}(o,"string"==typeof n,t),c=n!==e.Fragment?{...l,...a,ref:i}:{},{children:u}=o,d=e.useMemo((()=>Ar(u)?u.get():u),[u]);return e.createElement(n,{...c,children:d})}}function Ps(e,t){return function(n,{forwardMotionProps:o}={forwardMotionProps:!1}){return Cr({...Mr(n)?ws:js,preloadedFeatures:e,useRender:Ts(o),createVisualElement:t,Component:n})}}function Bs(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}function As(e,t,n){const o=e.getProps();return Pr(o,t,void 0!==n?n:o.custom,e)}function Es(e,t){return e?e[t]||e.default||e:void 0}const zs=new Set(["width","height","top","left","right","bottom",...Rr]);let Is;function Rs(){Is=void 0}const Vs={now:()=>(void 0===Is&&Vs.set(Gi.isProcessing||Hi?Gi.timestamp:performance.now()),Is),set:e=>{Is=e,queueMicrotask(Rs)}};function Fs(e,t){-1===e.indexOf(t)&&e.push(t)}function Ls(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Ds{constructor(){this.subscriptions=[]}add(e){return Fs(this.subscriptions,e),()=>Ls(this.subscriptions,e)}notify(e,t,n){const o=this.subscriptions.length;if(o)if(1===o)this.subscriptions[0](e,t,n);else for(let i=0;i<o;i++){const o=this.subscriptions[i];o&&o(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}function Os(e,t){return t?e*(1e3/t):0}class $s{constructor(e,t={}){this.version="12.0.6",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{const n=Vs.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){var t;this.current=e,this.updatedAt=Vs.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=(t=this.current,!isNaN(parseFloat(t))))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return"production"!==process.env.NODE_ENV&&nr(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new Ds);const n=this.events[e].add(t);return"change"===e?()=>{n(),_i.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=Vs.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;const t=Math.min(this.updatedAt-this.prevUpdatedAt,30);return Os(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),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(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Hs(e,t){return new $s(e,t)}function Ws(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Hs(n))}function Ns(e,t){const n=e.getValue("willChange");if(o=n,Boolean(Ar(o)&&o.add))return n.add(t);var o}function _s(e){return e.props[xr]}function Us(e){let t;return()=>(void 0===t&&(t=e()),t)}const Gs=Us((()=>void 0!==window.ScrollTimeline));class qs{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map((e=>"finished"in e?e.finished:e)))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e,t){const n=this.animations.map((n=>Gs()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0));return()=>{n.forEach(((e,t)=>{e&&e(),this.animations[t].stop()}))}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach((t=>t[e]()))}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class Ks extends qs{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}const Zs=e=>1e3*e,Ys=e=>e/1e3;function Xs(e){return"function"==typeof e}function Js(e,t){e.timeline=t,e.onfinish=null}const Qs=e=>Array.isArray(e)&&"number"==typeof e[0],ea={linearEasing:void 0};function ta(e,t){const n=Us(e);return()=>{var e;return null!==(e=ea[t])&&void 0!==e?e:n()}}const na=ta((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(e){return!1}return!0}),"linearEasing"),oa=(e,t,n)=>{const o=t-e;return 0===o?1:(n-e)/o},ia=(e,t,n=10)=>{let o="";const i=Math.max(Math.round(t/n),2);for(let t=0;t<i;t++)o+=e(oa(0,i-1,t))+", ";return`linear(${o.substring(0,o.length-2)})`};function ra(e){return Boolean("function"==typeof e&&na()||!e||"string"==typeof e&&(e in aa||na())||Qs(e)||Array.isArray(e)&&e.every(ra))}const sa=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,aa={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:sa([0,.65,.55,1]),circOut:sa([.55,0,1,.45]),backIn:sa([.31,.01,.66,-.59]),backOut:sa([.33,1.53,.69,.99])};function la(e,t){return e?"function"==typeof e&&na()?ia(e,t):Qs(e)?sa(e):Array.isArray(e)?e.map((e=>la(e,t)||aa.easeOut)):aa[e]:void 0}const ca=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function ua(e,t,n,o){if(e===t&&n===o)return Di;const i=t=>function(e,t,n,o,i){let r,s,a=0;do{s=t+(n-t)/2,r=ca(s,o,i)-e,r>0?n=s:t=s}while(Math.abs(r)>1e-7&&++a<12);return s}(t,0,1,e,n);return e=>0===e||1===e?e:ca(i(e),t,o)}const da=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,pa=e=>t=>1-e(1-t),ha=ua(.33,1.53,.69,.99),ma=pa(ha),fa=da(ma),ga=e=>(e*=2)<1?.5*ma(e):.5*(2-Math.pow(2,-10*(e-1))),xa=e=>1-Math.sin(Math.acos(e)),va=pa(xa),ya=da(xa),ba=e=>/^0[^.\s]+$/u.test(e);const wa=e=>Math.round(1e5*e)/1e5,ja=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const Ca=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Sa=(e,t)=>n=>Boolean("string"==typeof n&&Ca.test(n)&&n.startsWith(e)||t&&!function(e){return null==e}(n)&&Object.prototype.hasOwnProperty.call(n,t)),ka=(e,t,n)=>o=>{if("string"!=typeof o)return o;const[i,r,s,a]=o.match(ja);return{[e]:parseFloat(i),[t]:parseFloat(r),[n]:parseFloat(s),alpha:void 0!==a?parseFloat(a):1}},Ma={...Nr,transform:e=>Math.round((e=>Wr(0,255,e))(e))},Ta={test:Sa("rgb","red"),parse:ka("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+Ma.transform(e)+", "+Ma.transform(t)+", "+Ma.transform(n)+", "+wa(_r.transform(o))+")"};const Pa={test:Sa("#"),parse:function(e){let t="",n="",o="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,o+=o,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:i?parseInt(i,16)/255:1}},transform:Ta.transform},Ba={test:Sa("hsl","hue"),parse:ka("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+Kr.transform(wa(t))+", "+Kr.transform(wa(n))+", "+wa(_r.transform(o))+")"},Aa={test:e=>Ta.test(e)||Pa.test(e)||Ba.test(e),parse:e=>Ta.test(e)?Ta.parse(e):Ba.test(e)?Ba.parse(e):Pa.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?Ta.transform(e):Ba.transform(e)},Ea=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const za="number",Ia="color",Ra=/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 Va(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},i=[];let r=0;const s=t.replace(Ra,(e=>(Aa.test(e)?(o.color.push(r),i.push(Ia),n.push(Aa.parse(e))):e.startsWith("var(")?(o.var.push(r),i.push("var"),n.push(e)):(o.number.push(r),i.push(za),n.push(parseFloat(e))),++r,"${}"))).split("${}");return{values:n,split:s,indexes:o,types:i}}function Fa(e){return Va(e).values}function La(e){const{split:t,types:n}=Va(e),o=t.length;return e=>{let i="";for(let r=0;r<o;r++)if(i+=t[r],void 0!==e[r]){const t=n[r];i+=t===za?wa(e[r]):t===Ia?Aa.transform(e[r]):e[r]}return i}}const Da=e=>"number"==typeof e?0:e;const Oa={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(ja))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(Ea))||void 0===n?void 0:n.length)||0)>0},parse:Fa,createTransformer:La,getAnimatableNone:function(e){const t=Fa(e);return La(e)(t.map(Da))}},$a=new Set(["brightness","contrast","saturate","opacity"]);function Ha(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[o]=n.match(ja)||[];if(!o)return e;const i=n.replace(o,"");let r=$a.has(t)?1:0;return o!==n&&(r*=100),t+"("+r+i+")"}const Wa=/\b([a-z-]*)\(.*?\)/gu,Na={...Oa,getAnimatableNone:e=>{const t=e.match(Wa);return t?t.map(Ha).join(" "):e}},_a={...ns,color:Aa,backgroundColor:Aa,outlineColor:Aa,fill:Aa,stroke:Aa,borderColor:Aa,borderTopColor:Aa,borderRightColor:Aa,borderBottomColor:Aa,borderLeftColor:Aa,filter:Na,WebkitFilter:Na},Ua=e=>_a[e];function Ga(e,t){let n=Ua(e);return n!==Na&&(n=Oa),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const qa=new Set(["auto","none","0"]);const Ka=e=>e===Nr||e===Zr,Za=(e,t)=>parseFloat(e.split(", ")[t]),Ya=(e,t)=>(n,{transform:o})=>{if("none"===o||!o)return 0;const i=o.match(/^matrix3d\((.+)\)$/u);if(i)return Za(i[1],t);{const t=o.match(/^matrix\((.+)\)$/u);return t?Za(t[1],e):0}},Xa=new Set(["x","y","z"]),Ja=Rr.filter((e=>!Xa.has(e)));const Qa={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:Ya(4,13),y:Ya(5,14)};Qa.translateX=Qa.x,Qa.translateY=Qa.y;const el=new Set;let tl=!1,nl=!1;function ol(){if(nl){const e=Array.from(el).filter((e=>e.needsMeasurement)),t=new Set(e.map((e=>e.element))),n=new Map;t.forEach((e=>{const t=function(e){const t=[];return Ja.forEach((n=>{const o=e.getValue(n);void 0!==o&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))})),t}(e);t.length&&(n.set(e,t),e.render())})),e.forEach((e=>e.measureInitialState())),t.forEach((e=>{e.render();const t=n.get(e);t&&t.forEach((([t,n])=>{var o;null===(o=e.getValue(t))||void 0===o||o.set(n)}))})),e.forEach((e=>e.measureEndState())),e.forEach((e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)}))}nl=!1,tl=!1,el.forEach((e=>e.complete())),el.clear()}function il(){el.forEach((e=>{e.readKeyframes(),e.needsMeasurement&&(nl=!0)}))}class rl{constructor(e,t,n,o,i,r=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=o,this.element=i,this.isAsync=r}scheduleResolve(){this.isScheduled=!0,this.isAsync?(el.add(this),tl||(tl=!0,_i.read(il),_i.resolveKeyframes(ol))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:t,element:n,motionValue:o}=this;for(let i=0;i<e.length;i++)if(null===e[i])if(0===i){const i=null==o?void 0:o.get(),r=e[e.length-1];if(void 0!==i)e[0]=i;else if(n&&t){const o=n.readValue(t,r);null!=o&&(e[0]=o)}void 0===e[0]&&(e[0]=r),o&&void 0===i&&o.set(e[0])}else e[i]=e[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),el.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,el.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const sl=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),al=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ll(e,t,n=1){$i(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[o,i]=function(e){const t=al.exec(e);if(!t)return[,];const[,n,o,i]=t;return[`--${null!=n?n:o}`,i]}(e);if(!o)return;const r=window.getComputedStyle(t).getPropertyValue(o);if(r){const e=r.trim();return sl(e)?parseFloat(e):e}return Or(i)?ll(i,t,n+1):i}const cl=e=>t=>t.test(e),ul=[Nr,Zr,Kr,qr,Xr,Yr,{test:e=>"auto"===e,parse:e=>e}],dl=e=>ul.find(cl(e));class pl extends rl{constructor(e,t,n,o,i){super(e,t,n,o,i,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n<e.length;n++){let o=e[n];if("string"==typeof o&&(o=o.trim(),Or(o))){const i=ll(o,t.current);void 0!==i&&(e[n]=i),n===e.length-1&&(this.finalKeyframe=o)}}if(this.resolveNoneKeyframes(),!zs.has(n)||2!==e.length)return;const[o,i]=e,r=dl(o),s=dl(i);if(r!==s)if(Ka(r)&&Ka(s))for(let t=0;t<e.length;t++){const n=e[t];"string"==typeof n&&(e[t]=parseFloat(n))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:t}=this,n=[];for(let t=0;t<e.length;t++)("number"==typeof(o=e[t])?0===o:null===o||"none"===o||"0"===o||ba(o))&&n.push(t);var o;n.length&&function(e,t,n){let o,i=0;for(;i<e.length&&!o;){const t=e[i];"string"==typeof t&&!qa.has(t)&&Va(t).values.length&&(o=e[i]),i++}if(o&&n)for(const i of t)e[i]=Ga(n,o)}(e,n,t)}measureInitialState(){const{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Qa[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;const o=t[t.length-1];void 0!==o&&e.getValue(n,o).jump(o,!1)}measureEndState(){var e;const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const r=o.length-1,s=o[r];o[r]=Qa[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==s&&void 0===this.finalKeyframe&&(this.finalKeyframe=s),(null===(e=this.removedTransforms)||void 0===e?void 0:e.length)&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}const hl=(e,t)=>"zIndex"!==t&&(!("number"!=typeof e&&!Array.isArray(e))||!("string"!=typeof e||!Oa.test(e)&&"0"!==e||e.startsWith("url(")));function ml(e,t,n,o){const i=e[0];if(null===i)return!1;if("display"===t||"visibility"===t)return!0;const r=e[e.length-1],s=hl(i,t),a=hl(r,t);return Oi(s===a,`You are trying to animate ${t} from "${i}" to "${r}". ${i} is not an animatable value - to enable this animation set ${i} to a value animatable to ${r} via the \`style\` property.`),!(!s||!a)&&(function(e){const t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||("spring"===n||Xs(n))&&o)}const fl=e=>null!==e;function gl(e,{repeat:t,repeatType:n="loop"},o){const i=e.filter(fl),r=t&&"loop"!==n&&t%2==1?0:i.length-1;return r&&void 0!==o?o:i[r]}class xl{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:r="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=Vs.now(),this.options={autoplay:e,delay:t,type:n,repeat:o,repeatDelay:i,repeatType:r,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(il(),ol()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=Vs.now(),this.hasAttemptedResolve=!0;const{name:n,type:o,velocity:i,delay:r,onComplete:s,onUpdate:a,isGenerator:l}=this.options;if(!l&&!ml(e,n,o,i)){if(!r)return a&&a(gl(e,this.options,t)),s&&s(),void this.resolveFinishedPromise();this.options.duration=0}const c=this.initPlayback(e,t);!1!==c&&(this._resolved={keyframes:e,finalKeyframe:t,...c},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise((e=>{this.resolveFinishedPromise=e}))}}const vl=2e4;function yl(e){let t=0;let n=e.next(t);for(;!n.done&&t<vl;)t+=50,n=e.next(t);return t>=vl?1/0:t}const bl=(e,t,n)=>e+(t-e)*n;function wl(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function jl(e,t){return n=>n>0?t:e}const Cl=(e,t,n)=>{const o=e*e,i=n*(t*t-o)+o;return i<0?0:Math.sqrt(i)},Sl=[Pa,Ta,Ba];function kl(e){const t=(n=e,Sl.find((e=>e.test(n))));var n;if(Oi(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`),!Boolean(t))return!1;let o=t.parse(e);return t===Ba&&(o=function({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,n/=100;let i=0,r=0,s=0;if(t/=100){const o=n<.5?n*(1+t):n+t-n*t,a=2*n-o;i=wl(a,o,e+1/3),r=wl(a,o,e),s=wl(a,o,e-1/3)}else i=r=s=n;return{red:Math.round(255*i),green:Math.round(255*r),blue:Math.round(255*s),alpha:o}}(o)),o}const Ml=(e,t)=>{const n=kl(e),o=kl(t);if(!n||!o)return jl(e,t);const i={...n};return e=>(i.red=Cl(n.red,o.red,e),i.green=Cl(n.green,o.green,e),i.blue=Cl(n.blue,o.blue,e),i.alpha=bl(n.alpha,o.alpha,e),Ta.transform(i))},Tl=(e,t)=>n=>t(e(n)),Pl=(...e)=>e.reduce(Tl),Bl=new Set(["none","hidden"]);function Al(e,t){return n=>bl(e,t,n)}function El(e){return"number"==typeof e?Al:"string"==typeof e?Or(e)?jl:Aa.test(e)?Ml:Rl:Array.isArray(e)?zl:"object"==typeof e?Aa.test(e)?Ml:Il:jl}function zl(e,t){const n=[...e],o=n.length,i=e.map(((e,n)=>El(e)(e,t[n])));return e=>{for(let t=0;t<o;t++)n[t]=i[t](e);return n}}function Il(e,t){const n={...e,...t},o={};for(const i in n)void 0!==e[i]&&void 0!==t[i]&&(o[i]=El(e[i])(e[i],t[i]));return e=>{for(const t in o)n[t]=o[t](e);return n}}const Rl=(e,t)=>{const n=Oa.createTransformer(t),o=Va(e),i=Va(t);return o.indexes.var.length===i.indexes.var.length&&o.indexes.color.length===i.indexes.color.length&&o.indexes.number.length>=i.indexes.number.length?Bl.has(e)&&!i.values.length||Bl.has(t)&&!o.values.length?function(e,t){return Bl.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):Pl(zl(function(e,t){var n;const o=[],i={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const s=t.types[r],a=e.indexes[s][i[s]],l=null!==(n=e.values[a])&&void 0!==n?n:0;o[r]=l,i[s]++}return o}(o,i),i.values),n):(Oi(!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.`),jl(e,t))};function Vl(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return bl(e,t,n);return El(e)(e,t)}function Fl(e,t,n){const o=Math.max(t-5,0);return Os(n-e(o),t-o)}const Ll=100,Dl=10,Ol=1,$l=0,Hl=800,Wl=.3,Nl=.3,_l={granular:.01,default:2},Ul={granular:.005,default:.5},Gl=.01,ql=10,Kl=.05,Zl=1;function Yl({duration:e=Hl,bounce:t=Wl,velocity:n=$l,mass:o=Ol}){let i,r;Oi(e<=Zs(ql),"Spring duration must be 10 seconds or less");let s=1-t;s=Wr(Kl,Zl,s),e=Wr(Gl,ql,Ys(e)),s<1?(i=t=>{const o=t*s,i=o*e;return.001-(o-n)/Jl(t,s)*Math.exp(-i)},r=t=>{const o=t*s*e,r=o*n+n,a=Math.pow(s,2)*Math.pow(t,2)*e,l=Math.exp(-o),c=Jl(Math.pow(t,2),s);return(.001-i(t)>0?-1:1)*((r-a)*l)/c}):(i=t=>Math.exp(-t*e)*((t-n)*e+1)-.001,r=t=>Math.exp(-t*e)*(e*e*(n-t)));const a=function(e,t,n){let o=n;for(let n=1;n<Xl;n++)o-=e(o)/t(o);return o}(i,r,5/e);if(e=Zs(e),isNaN(a))return{stiffness:Ll,damping:Dl,duration:e};{const t=Math.pow(a,2)*o;return{stiffness:t,damping:2*s*Math.sqrt(o*t),duration:e}}}const Xl=12;function Jl(e,t){return e*Math.sqrt(1-t*t)}const Ql=["duration","bounce"],ec=["stiffness","damping","mass"];function tc(e,t){return t.some((t=>void 0!==e[t]))}function nc(e=Nl,t=Wl){const n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:i}=n;const r=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:r},{stiffness:l,damping:c,mass:u,duration:d,velocity:p,isResolvedFromDuration:h}=function(e){let t={velocity:$l,stiffness:Ll,damping:Dl,mass:Ol,isResolvedFromDuration:!1,...e};if(!tc(e,ec)&&tc(e,Ql))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(1.2*n),i=o*o,r=2*Wr(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:Ol,stiffness:i,damping:r}}else{const n=Yl(e);t={...t,...n,mass:Ol},t.isResolvedFromDuration=!0}return t}({...n,velocity:-Ys(n.velocity||0)}),m=p||0,f=c/(2*Math.sqrt(l*u)),g=s-r,x=Ys(Math.sqrt(l/u)),v=Math.abs(g)<5;let y;if(o||(o=v?_l.granular:_l.default),i||(i=v?Ul.granular:Ul.default),f<1){const e=Jl(x,f);y=t=>{const n=Math.exp(-f*x*t);return s-n*((m+f*x*g)/e*Math.sin(e*t)+g*Math.cos(e*t))}}else if(1===f)y=e=>s-Math.exp(-x*e)*(g+(m+x*g)*e);else{const e=x*Math.sqrt(f*f-1);y=t=>{const n=Math.exp(-f*x*t),o=Math.min(e*t,300);return s-n*((m+f*x*g)*Math.sinh(o)+e*g*Math.cosh(o))/e}}const b={calculatedDuration:h&&d||null,next:e=>{const t=y(e);if(h)a.done=e>=d;else{let n=0;f<1&&(n=0===e?Zs(m):Fl(y,e,t));const r=Math.abs(n)<=o,l=Math.abs(s-t)<=i;a.done=r&&l}return a.value=a.done?s:t,a},toString:()=>{const e=Math.min(yl(b),vl),t=ia((t=>b.next(e*t).value),e,30);return e+"ms "+t}};return b}function oc({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],p={done:!1,value:d},h=e=>void 0===a?l:void 0===l||Math.abs(a-e)<Math.abs(l-e)?a:l;let m=n*t;const f=d+m,g=void 0===s?f:s(f);g!==f&&(m=g-d);const x=e=>-m*Math.exp(-e/o),v=e=>g+x(e),y=e=>{const t=x(e),n=v(e);p.done=Math.abs(t)<=c,p.value=p.done?g:n};let b,w;const j=e=>{var t;(t=p.value,void 0!==a&&t<a||void 0!==l&&t>l)&&(b=e,w=nc({keyframes:[p.value,h(p.value)],velocity:Fl(v,e,p.value),damping:i,stiffness:r,restDelta:c,restSpeed:u}))};return j(0),{calculatedDuration:null,next:e=>{let t=!1;return w||void 0!==b||(t=!0,y(e),j(e)),void 0!==b&&e>=b?w.next(e-b):(!t&&y(e),p)}}}const ic=ua(.42,0,1,1),rc=ua(0,0,.58,1),sc=ua(.42,0,.58,1),ac={linear:Di,easeIn:ic,easeInOut:sc,easeOut:rc,circIn:xa,circInOut:ya,circOut:va,backIn:ma,backInOut:fa,backOut:ha,anticipate:ga},lc=e=>{if(Qs(e)){$i(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,o,i]=e;return ua(t,n,o,i)}return"string"==typeof e?($i(void 0!==ac[e],`Invalid easing type '${e}'`),ac[e]):e};function cc(e,t,{clamp:n=!0,ease:o,mixer:i}={}){const r=e.length;if($i(r===t.length,"Both input and output ranges must be the same length"),1===r)return()=>t[0];if(2===r&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[r-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=function(e,t,n){const o=[],i=n||Vl,r=e.length-1;for(let n=0;n<r;n++){let r=i(e[n],e[n+1]);if(t){const e=Array.isArray(t)?t[n]||Di:t;r=Pl(e,r)}o.push(r)}return o}(t,o,i),l=a.length,c=n=>{if(s&&n<e[0])return t[0];let o=0;if(l>1)for(;o<e.length-2&&!(n<e[o+1]);o++);const i=oa(e[o],e[o+1],n);return a[o](i)};return n?t=>c(Wr(e[0],e[r-1],t)):c}function uc(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const i=oa(0,t,o);e.push(bl(n,1,i))}}(t,e.length-1),t}function dc(e,t){return e.map((()=>t||sc)).splice(0,e.length-1)}function pc({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const i=(e=>Array.isArray(e)&&"number"!=typeof e[0])(o)?o.map(lc):lc(o),r={done:!1,value:t[0]},s=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:uc(t),e),a=cc(s,t,{ease:Array.isArray(i)?i:dc(t,i)});return{calculatedDuration:e,next:t=>(r.value=a(t),r.done=t>=e,r)}}const hc=e=>{const t=({timestamp:t})=>e(t);return{start:()=>_i.update(t,!0),stop:()=>Ui(t),now:()=>Gi.isProcessing?Gi.timestamp:Vs.now()}},mc={decay:oc,inertia:oc,tween:pc,keyframes:pc,spring:nc},fc=e=>e/100;class gc extends xl{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:e}=this.options;e&&e()};const{name:t,motionValue:n,element:o,keyframes:i}=this.options,r=(null==o?void 0:o.KeyframeResolver)||rl;this.resolver=new r(i,((e,t)=>this.onKeyframesResolved(e,t)),t,n,o),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){const{type:t="keyframes",repeat:n=0,repeatDelay:o=0,repeatType:i,velocity:r=0}=this.options,s=Xs(t)?t:mc[t]||pc;let a,l;s!==pc&&"number"!=typeof e[0]&&("production"!==process.env.NODE_ENV&&$i(2===e.length,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`),a=Pl(fc,Vl(e[0],e[1])),e=[0,100]);const c=s({...this.options,keyframes:e});"mirror"===i&&(l=s({...this.options,keyframes:[...e].reverse(),velocity:-r})),null===c.calculatedDuration&&(c.calculatedDuration=yl(c));const{calculatedDuration:u}=c,d=u+o;return{generator:c,mirroredGenerator:l,mapPercentToKeyframes:a,calculatedDuration:u,resolvedDuration:d,totalDuration:d*(n+1)-o}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){const{resolved:n}=this;if(!n){const{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}const{finalKeyframe:o,generator:i,mirroredGenerator:r,mapPercentToKeyframes:s,keyframes:a,calculatedDuration:l,totalDuration:c,resolvedDuration:u}=n;if(null===this.startTime)return i.next(0);const{delay:d,repeat:p,repeatType:h,repeatDelay:m,onUpdate:f}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),t?this.currentTime=e:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;const g=this.currentTime-d*(this.speed>=0?1:-1),x=this.speed>=0?g<0:g>c;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=c);let v=this.currentTime,y=i;if(p){const e=Math.min(this.currentTime,c)/u;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,p+1);Boolean(t%2)&&("reverse"===h?(n=1-n,m&&(n-=m/u)):"mirror"===h&&(y=r)),v=Wr(0,1,n)*u}const b=x?{done:!1,value:a[0]}:y.next(v);s&&(b.value=s(b.value));let{done:w}=b;x||null===l||(w=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const j=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return j&&void 0!==o&&(b.value=gl(a,this.options,o)),f&&f(b.value),j&&this.finish(),b}get duration(){const{resolved:e}=this;return e?Ys(e.calculatedDuration):0}get time(){return Ys(this.currentTime)}set time(e){e=Zs(e),this.currentTime=e,null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=Ys(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:e=hc,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e((e=>this.tick(e)))),t&&t();const o=this.driver.now();null!==this.holdTime?this.startTime=o-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=o):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;this._resolved?(this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const xc=new Set(["opacity","clipPath","filter","transform"]);function vc(e,t,n,{delay:o=0,duration:i=300,repeat:r=0,repeatType:s="loop",ease:a="easeInOut",times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=la(a,i);return Array.isArray(u)&&(c.easing=u),e.animate(c,{delay:o,duration:i,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:r+1,direction:"reverse"===s?"alternate":"normal"})}const yc=Us((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));const bc={anticipate:ga,backInOut:fa,circInOut:ya};class wc extends xl{constructor(e){super(e);const{name:t,motionValue:n,element:o,keyframes:i}=this.options;this.resolver=new pl(i,((e,t)=>this.onKeyframesResolved(e,t)),t,n,o),this.resolver.scheduleResolve()}initPlayback(e,t){let{duration:n=300,times:o,ease:i,type:r,motionValue:s,name:a,startTime:l}=this.options;if(!s.owner||!s.owner.current)return!1;if("string"==typeof i&&na()&&i in bc&&(i=bc[i]),function(e){return Xs(e.type)||"spring"===e.type||!ra(e.ease)}(this.options)){const{onComplete:t,onUpdate:s,motionValue:a,element:l,...c}=this.options,u=function(e,t){const n=new gc({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let o={done:!1,value:e[0]};const i=[];let r=0;for(;!o.done&&r<2e4;)o=n.sample(r),i.push(o.value),r+=10;return{times:void 0,keyframes:i,duration:r-10,ease:"linear"}}(e,c);1===(e=u.keyframes).length&&(e[1]=e[0]),n=u.duration,o=u.times,i=u.ease,r="keyframes"}const c=vc(s.owner.current,a,e,{...this.options,duration:n,times:o,ease:i});return c.startTime=null!=l?l:this.calcStartTime(),this.pendingTimeline?(Js(c,this.pendingTimeline),this.pendingTimeline=void 0):c.onfinish=()=>{const{onComplete:n}=this.options;s.set(gl(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:n,times:o,type:r,ease:i,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:t}=e;return Ys(t)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:t}=e;return Ys(t.currentTime||0)}set time(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.currentTime=Zs(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:t}=e;return t.playbackRate}set speed(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:t}=e;return t.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){const{resolved:t}=this;if(!t)return Di;const{animation:n}=t;Js(n,e)}else this.pendingTimeline=e;return Di}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:t,keyframes:n,duration:o,type:i,ease:r,times:s}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){const{motionValue:e,onUpdate:t,onComplete:a,element:l,...c}=this.options,u=new gc({...c,keyframes:n,duration:o,type:i,ease:r,times:s,isGenerator:!0}),d=Zs(this.time);e.setWithVelocity(u.sample(d-10).value,u.sample(d).value,10)}const{onStop:a}=this.options;a&&a(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:i,damping:r,type:s}=e;if(!(t&&t.owner&&t.owner.current instanceof HTMLElement))return!1;const{onUpdate:a,transformTemplate:l}=t.owner.getProps();return yc()&&n&&xc.has(n)&&!a&&!l&&!o&&"mirror"!==i&&0!==r&&"inertia"!==s}}const jc={type:"spring",stiffness:500,damping:25,restSpeed:10},Cc={type:"keyframes",duration:.8},Sc={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},kc=(e,{keyframes:t})=>t.length>2?Cc:Vr.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:jc:Sc;const Mc=(e,t,n,o={},i,r)=>s=>{const a=Es(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c-=Zs(l);let u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:e=>{t.set(e),a.onUpdate&&a.onUpdate(e)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:r?void 0:i};(function({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:i,repeat:r,repeatType:s,repeatDelay:a,from:l,elapsed:c,...u}){return!!Object.keys(u).length})(a)||(u={...u,...kc(e,u)}),u.duration&&(u.duration=Zs(u.duration)),u.repeatDelay&&(u.repeatDelay=Zs(u.repeatDelay)),void 0!==u.from&&(u.keyframes[0]=u.from);let d=!1;if((!1===u.type||0===u.duration&&!u.repeatDelay)&&(u.duration=0,0===u.delay&&(d=!0)),d&&!r&&void 0!==t.get()){const e=gl(u.keyframes,a);if(void 0!==e)return _i.update((()=>{u.onUpdate(e),u.onComplete()})),new Ks([])}return!r&&wc.supports(u)?new wc(u):new gc(u)};function Tc({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,o}function Pc(e,t,{delay:n=0,transitionOverride:o,type:i}={}){var r;let{transition:s=e.getDefaultTransition(),transitionEnd:a,...l}=t;o&&(s=o);const c=[],u=i&&e.animationState&&e.animationState.getState()[i];for(const t in l){const o=e.getValue(t,null!==(r=e.latestValues[t])&&void 0!==r?r:null),i=l[t];if(void 0===i||u&&Tc(u,t))continue;const a={delay:n,...Es(s||{},t)};let d=!1;if(window.MotionHandoffAnimation){const n=_s(e);if(n){const e=window.MotionHandoffAnimation(n,t,_i);null!==e&&(a.startTime=e,d=!0)}}Ns(e,t),o.start(Mc(t,o,i,e.shouldReduceMotion&&zs.has(t)?{type:!1}:a,e,d));const p=o.animation;p&&c.push(p)}return a&&Promise.all(c).then((()=>{_i.update((()=>{a&&function(e,t){const n=As(e,t);let{transitionEnd:o={},transition:i={},...r}=n||{};r={...r,...o};for(const t in r)Ws(e,t,(s=r[t],Br(s)?s[s.length-1]||0:s));var s}(e,a)}))})),c}function Bc(e,t,n={}){var o;const i=As(e,t,"exit"===n.type?null===(o=e.presenceContext)||void 0===o?void 0:o.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(r=n.transitionOverride);const s=i?()=>Promise.all(Pc(e,i,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(o=0)=>{const{delayChildren:i=0,staggerChildren:s,staggerDirection:a}=r;return function(e,t,n=0,o=0,i=1,r){const s=[],a=(e.variantChildren.size-1)*o,l=1===i?(e=0)=>e*o:(e=0)=>a-e*o;return Array.from(e.variantChildren).sort(Ac).forEach(((e,o)=>{e.notify("AnimationStart",t),s.push(Bc(e,t,{...r,delay:n+l(o)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(s)}(e,t,i+o,s,a,n)}:()=>Promise.resolve(),{when:l}=r;if(l){const[e,t]="beforeChildren"===l?[s,a]:[a,s];return e().then((()=>t()))}return Promise.all([s(),a(n.delay)])}function Ac(e,t){return e.sortNodePosition(t)}const Ec=lr.length;function zc(e){if(!e)return;if(!e.isControllingVariants){const t=e.parent&&zc(e.parent)||{};return void 0!==e.props.initial&&(t.initial=e.props.initial),t}const t={};for(let n=0;n<Ec;n++){const o=lr[n],i=e.props[o];(rr(i)||!1===i)&&(t[o]=i)}return t}const Ic=[...ar].reverse(),Rc=ar.length;function Vc(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let o;if(e.notify("AnimationStart",t),Array.isArray(t)){const i=t.map((t=>Bc(e,t,n)));o=Promise.all(i)}else if("string"==typeof t)o=Bc(e,t,n);else{const i="function"==typeof t?As(e,t,n.custom):t;o=Promise.all(Pc(e,i,n))}return o.then((()=>{e.notify("AnimationComplete",t)}))}(e,t,n))))}function Fc(e){let t=Vc(e),n=Oc(),o=!0;const i=t=>(n,o)=>{var i;const r=As(e,o,"exit"===t?null===(i=e.presenceContext)||void 0===i?void 0:i.custom:void 0);if(r){const{transition:e,transitionEnd:t,...o}=r;n={...n,...o,...t}}return n};function r(r){const{props:s}=e,a=zc(e.parent)||{},l=[],c=new Set;let u={},d=1/0;for(let t=0;t<Rc;t++){const p=Ic[t],h=n[p],m=void 0!==s[p]?s[p]:a[p],f=rr(m),g=p===r?h.isActive:null;!1===g&&(d=t);let x=m===a[p]&&m!==s[p]&&f;if(x&&o&&e.manuallyAnimateOnMount&&(x=!1),h.protectedKeys={...u},!h.isActive&&null===g||!m&&!h.prevProp||sr(m)||"boolean"==typeof m)continue;const v=Lc(h.prevProp,m);let y=v||p===r&&h.isActive&&!x&&f||t>d&&f,b=!1;const w=Array.isArray(m)?m:[m];let j=w.reduce(i(p),{});!1===g&&(j={});const{prevResolvedValues:C={}}=h,S={...C,...j},k=t=>{y=!0,c.has(t)&&(b=!0,c.delete(t)),h.needsAnimating[t]=!0;const n=e.getValue(t);n&&(n.liveStyle=!1)};for(const e in S){const t=j[e],n=C[e];if(u.hasOwnProperty(e))continue;let o=!1;o=Br(t)&&Br(n)?!Bs(t,n):t!==n,o?null!=t?k(e):c.add(e):void 0!==t&&c.has(e)?k(e):h.protectedKeys[e]=!0}h.prevProp=m,h.prevResolvedValues=j,h.isActive&&(u={...u,...j}),o&&e.blockInitialAnimation&&(y=!1);y&&(!(x&&v)||b)&&l.push(...w.map((e=>({animation:e,options:{type:p}}))))}if(c.size){const t={};c.forEach((n=>{const o=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=null!=o?o:null})),l.push({animation:t})}let p=Boolean(l.length);return!o||!1!==s.initial&&s.initial!==s.animate||e.manuallyAnimateOnMount||(p=!1),o=!1,p?t(l):Promise.resolve()}return{animateChanges:r,setActive:function(t,o){var i;if(n[t].isActive===o)return Promise.resolve();null===(i=e.variantChildren)||void 0===i||i.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,o)})),n[t].isActive=o;const s=r(t);for(const e in n)n[e].protectedKeys={};return s},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=Oc(),o=!0}}}function Lc(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!Bs(t,e)}function Dc(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Oc(){return{animate:Dc(!0),whileInView:Dc(),whileHover:Dc(),whileTap:Dc(),whileDrag:Dc(),whileFocus:Dc(),exit:Dc()}}class $c{constructor(e){this.isMounted=!1,this.node=e}update(){}}let Hc=0;const Wc={animation:{Feature:class extends $c{constructor(e){super(e),e.animationState||(e.animationState=Fc(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();sr(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}},exit:{Feature:class extends $c{constructor(){super(...arguments),this.id=Hc++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;const o=this.node.animationState.setActive("exit",!e);t&&!e&&o.then((()=>t(this.id)))}mount(){const{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}}},Nc={x:!1,y:!1};function _c(){return Nc.x||Nc.y}const Uc=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function Gc(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function qc(e){return{point:{x:e.pageX,y:e.pageY}}}function Kc(e,t,n,o){return Gc(e,t,(e=>t=>Uc(t)&&e(t,qc(t)))(n),o)}const Zc=(e,t)=>Math.abs(e-t);class Yc{constructor(e,t,{transformPagePoint:n,contextWindow:o,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=Qc(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=Zc(e.x,t.x),o=Zc(e.y,t.y);return Math.sqrt(n**2+o**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:o}=e,{timestamp:i}=Gi;this.history.push({...o,timestamp:i});const{onStart:r,onMove:s}=this.handlers;t||(r&&r(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),s&&s(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=Xc(t,this.transformPagePoint),_i.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();const{onEnd:n,onSessionEnd:o,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const r=Qc("pointercancel"===e.type?this.lastMoveEventInfo:Xc(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,r),o&&o(e,r)},!Uc(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.contextWindow=o||window;const r=Xc(qc(e),this.transformPagePoint),{point:s}=r,{timestamp:a}=Gi;this.history=[{...s,timestamp:a}];const{onSessionStart:l}=t;l&&l(e,Qc(r,this.history)),this.removeListeners=Pl(Kc(this.contextWindow,"pointermove",this.handlePointerMove),Kc(this.contextWindow,"pointerup",this.handlePointerUp),Kc(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),Ui(this.updatePoint)}}function Xc(e,t){return t?{point:t(e.point)}:e}function Jc(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Qc({point:e},t){return{point:e,delta:Jc(e,tu(t)),offset:Jc(e,eu(t)),velocity:nu(t,.1)}}function eu(e){return e[0]}function tu(e){return e[e.length-1]}function nu(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const i=tu(e);for(;n>=0&&(o=e[n],!(i.timestamp-o.timestamp>Zs(t)));)n--;if(!o)return{x:0,y:0};const r=Ys(i.timestamp-o.timestamp);if(0===r)return{x:0,y:0};const s={x:(i.x-o.x)/r,y:(i.y-o.y)/r};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function ou(e){return e.max-e.min}function iu(e,t,n,o=.5){e.origin=o,e.originPoint=bl(t.min,t.max,e.origin),e.scale=ou(n)/ou(t),e.translate=bl(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function ru(e,t,n,o){iu(e.x,t.x,n.x,o?o.originX:void 0),iu(e.y,t.y,n.y,o?o.originY:void 0)}function su(e,t,n){e.min=n.min+t.min,e.max=e.min+ou(t)}function au(e,t,n){e.min=t.min-n.min,e.max=e.min+ou(t)}function lu(e,t,n){au(e.x,t.x,n.x),au(e.y,t.y,n.y)}function cu(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function uu(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}const du=.35;function pu(e,t,n){return{min:hu(e,t),max:hu(e,n)}}function hu(e,t){return"number"==typeof e?e:e[t]||0}const mu=()=>({x:{min:0,max:0},y:{min:0,max:0}});function fu(e){return[e("x"),e("y")]}function gu({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function xu(e){return void 0===e||1===e}function vu({scale:e,scaleX:t,scaleY:n}){return!xu(e)||!xu(t)||!xu(n)}function yu(e){return vu(e)||bu(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function bu(e){return wu(e.x)||wu(e.y)}function wu(e){return e&&"0%"!==e}function ju(e,t,n){return n+t*(e-n)}function Cu(e,t,n,o,i){return void 0!==i&&(e=ju(e,i,o)),ju(e,n,o)+t}function Su(e,t=0,n=1,o,i){e.min=Cu(e.min,t,n,o,i),e.max=Cu(e.max,t,n,o,i)}function ku(e,{x:t,y:n}){Su(e.x,t.translate,t.scale,t.originPoint),Su(e.y,n.translate,n.scale,n.originPoint)}const Mu=.999999999999,Tu=1.0000000000001;function Pu(e,t){e.min=e.min+t,e.max=e.max+t}function Bu(e,t,n,o,i=.5){Su(e,t,n,bl(e.min,e.max,i),o)}function Au(e,t){Bu(e.x,t.x,t.scaleX,t.scale,t.originX),Bu(e.y,t.y,t.scaleY,t.scale,t.originY)}function Eu(e,t){return gu(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}(e.getBoundingClientRect(),t))}const zu=({current:e})=>e?e.ownerDocument.defaultView:null,Iu=new WeakMap;class Ru{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic={x:{min:0,max:0},y:{min:0,max:0}},this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:o}=this.getProps();this.panSession=new Yc(e,{onSessionStart:e=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(qc(e).point)},onStart:(e,t)=>{const{drag:n,dragPropagation:o,onDragStart:i}=this.getProps();if(n&&!o&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===(r=n)||"y"===r?Nc[r]?null:(Nc[r]=!0,()=>{Nc[r]=!1}):Nc.x||Nc.y?null:(Nc.x=Nc.y=!0,()=>{Nc.x=Nc.y=!1}),!this.openDragLock))return;var r;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),fu((e=>{let t=this.getAxisMotionValue(e).get()||0;if(Kr.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const o=n.layout.layoutBox[e];if(o){t=ou(o)*(parseFloat(t)/100)}}}this.originPoint[e]=t})),i&&_i.postRender((()=>i(e,t))),Ns(this.visualElement,"transform");const{animationState:s}=this.visualElement;s&&s.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:o,onDirectionLock:i,onDrag:r}=this.getProps();if(!n&&!this.openDragLock)return;const{offset:s}=t;if(o&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(s),void(null!==this.currentDirection&&i&&i(this.currentDirection));this.updateAxis("x",t.point,s),this.updateAxis("y",t.point,s),this.visualElement.render(),r&&r(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>fu((e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:o,contextWindow:zu(this.visualElement)})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:o}=t;this.startAnimation(o);const{onDragEnd:i}=this.getProps();i&&_i.postRender((()=>i(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:o}=this.getProps();if(!n||!Vu(e,o,this.currentDirection))return;const i=this.getAxisMotionValue(e);let r=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(r=function(e,{min:t,max:n},o){return void 0!==t&&e<t?e=o?bl(t,e,o.min):Math.max(e,t):void 0!==n&&e>n&&(e=o?bl(n,e,o.max):Math.min(e,n)),e}(r,this.constraints[e],this.elastic[e])),i.set(r)}resolveConstraints(){var e;const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,i=this.constraints;t&&mr(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!t||!o)&&function(e,{top:t,left:n,bottom:o,right:i}){return{x:cu(e.x,n,i),y:cu(e.y,t,o)}}(o.layoutBox,t),this.elastic=function(e=du){return!1===e?e=0:!0===e&&(e=du),{x:pu(e,"left","right"),y:pu(e,"top","bottom")}}(n),i!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&fu((e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(o.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!mr(e))return!1;const n=e.current;$i(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const i=function(e,t,n){const o=Eu(e,n),{scroll:i}=t;return i&&(Pu(o.x,i.offset.x),Pu(o.y,i.offset.y)),o}(n,o.root,this.visualElement.getTransformPagePoint());let r=function(e,t){return{x:uu(e.x,t.x),y:uu(e.y,t.y)}}(o.layout.layoutBox,i);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(r));this.hasMutatedConstraints=!!e,e&&(r=gu(e))}return r}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:o,dragTransition:i,dragSnapToOrigin:r,onDragTransitionEnd:s}=this.getProps(),a=this.constraints||{},l=fu((s=>{if(!Vu(s,t,this.currentDirection))return;let l=a[s]||{};r&&(l={min:0,max:0});const c=o?200:1e6,u=o?40:1e7,d={type:"inertia",velocity:n?e[s]:0,bounceStiffness:c,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...i,...l};return this.startAxisValueAnimation(s,d)}));return Promise.all(l).then(s)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return Ns(this.visualElement,e),n.start(Mc(e,n,0,t,this.visualElement,!1))}stopAnimation(){fu((e=>this.getAxisMotionValue(e).stop()))}pauseAnimation(){fu((e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()}))}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){const t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps(),o=n[t];return o||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){fu((t=>{const{drag:n}=this.getProps();if(!Vu(t,n,this.currentDirection))return;const{projection:o}=this.visualElement,i=this.getAxisMotionValue(t);if(o&&o.layout){const{min:n,max:r}=o.layout.layoutBox[t];i.set(e[t]-bl(n,r,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!mr(t)||!n||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};fu((e=>{const t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){const n=t.get();o[e]=function(e,t){let n=.5;const o=ou(e),i=ou(t);return i>o?n=oa(t.min,t.max-o,e.min):o>i&&(n=oa(e.min,e.max-i,t.min)),Wr(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),fu((t=>{if(!Vu(t,e,null))return;const n=this.getAxisMotionValue(t),{min:i,max:r}=this.constraints[t];n.set(bl(i,r,o[t]))}))}addListeners(){if(!this.visualElement.current)return;Iu.set(this.visualElement,this);const e=Kc(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();mr(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,o=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),_i.read(t);const i=Gc(window,"resize",(()=>this.scalePositionWithinConstraints())),r=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(fu((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{i(),e(),o(),r&&r()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:o=!1,dragConstraints:i=!1,dragElastic:r=du,dragMomentum:s=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:o,dragConstraints:i,dragElastic:r,dragMomentum:s}}}function Vu(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const Fu=e=>(t,n)=>{e&&_i.postRender((()=>e(t,n)))};const Lu={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Du(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ou={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!Zr.test(e))return e;e=parseFloat(e)}return`${Du(e,t.target.x)}% ${Du(e,t.target.y)}%`}},$u={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,i=Oa.parse(e);if(i.length>5)return o;const r=Oa.createTransformer(e),s="number"!=typeof i[0]?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=l;const c=bl(a,l,.5);return"number"==typeof i[2+s]&&(i[2+s]/=c),"number"==typeof i[3+s]&&(i[3+s]/=c),r(i)}};class Hu extends e.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:o}=this.props,{projection:i}=e;!function(e){for(const t in e)gs[t]=e[t],Lr(t)&&(gs[t].isCSSVariable=!0)}(Nu),i&&(t.group&&t.group.add(i),n&&n.register&&o&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",(()=>{this.safeToRemove()})),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),Lu.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:o,isPresent:i}=this.props,r=n.projection;return r?(r.isPresent=i,o||e.layoutDependency!==t||void 0===t?r.willUpdate():this.safeToRemove(),e.isPresent!==i&&(i?r.promote():r.relegate()||_i.postRender((()=>{const e=r.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),vr.postRender((()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:o}=e;o&&(o.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(o),n&&n.deregister&&n.deregister(o))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function Wu(t){const[n,o]=function(t=!0){const n=e.useContext(Ri);if(null===n)return[!0,null];const{isPresent:o,onExitComplete:i,register:r}=n,s=e.useId();e.useEffect((()=>{t&&r(s)}),[t]);const a=e.useCallback((()=>t&&i&&i(s)),[s,i,t]);return!o&&i?[!1,a]:[!0]}(),i=e.useContext(Ii);return ge.jsx(Hu,{...t,layoutGroup:i,switchLayoutGroup:e.useContext(br),isPresent:n,safeToRemove:o})}const Nu={borderRadius:{...Ou,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ou,borderTopRightRadius:Ou,borderBottomLeftRadius:Ou,borderBottomRightRadius:Ou,boxShadow:$u};const _u=(e,t)=>e.depth-t.depth;class Uu{constructor(){this.children=[],this.isDirty=!1}add(e){Fs(this.children,e),this.isDirty=!0}remove(e){Ls(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(_u),this.isDirty=!1,this.children.forEach(e)}}const Gu=["TopLeft","TopRight","BottomLeft","BottomRight"],qu=Gu.length,Ku=e=>"string"==typeof e?parseFloat(e):e,Zu=e=>"number"==typeof e||Zr.test(e);function Yu(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const Xu=Qu(0,.5,va),Ju=Qu(.5,.95,Di);function Qu(e,t,n){return o=>o<e?0:o>t?1:n(oa(e,t,o))}function ed(e,t){e.min=t.min,e.max=t.max}function td(e,t){ed(e.x,t.x),ed(e.y,t.y)}function nd(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function od(e,t,n,o,i){return e=ju(e-=t,1/n,o),void 0!==i&&(e=ju(e,1/i,o)),e}function id(e,t,[n,o,i],r,s){!function(e,t=0,n=1,o=.5,i,r=e,s=e){Kr.test(t)&&(t=parseFloat(t),t=bl(s.min,s.max,t/100)-s.min);if("number"!=typeof t)return;let a=bl(r.min,r.max,o);e===r&&(a-=t),e.min=od(e.min,t,n,a,i),e.max=od(e.max,t,n,a,i)}(e,t[n],t[o],t[i],t.scale,r,s)}const rd=["x","scaleX","originX"],sd=["y","scaleY","originY"];function ad(e,t,n,o){id(e.x,t,rd,n?n.x:void 0,o?o.x:void 0),id(e.y,t,sd,n?n.y:void 0,o?o.y:void 0)}function ld(e){return 0===e.translate&&1===e.scale}function cd(e){return ld(e.x)&&ld(e.y)}function ud(e,t){return e.min===t.min&&e.max===t.max}function dd(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function pd(e,t){return dd(e.x,t.x)&&dd(e.y,t.y)}function hd(e){return ou(e.x)/ou(e.y)}function md(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class fd{constructor(){this.members=[]}add(e){Fs(this.members,e),e.scheduleRender()}remove(e){if(Ls(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let e=t;e>=0;e--){const t=this.members[e];if(!1!==t.isPresent){n=t;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:o}=e.options;!1===o&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const gd={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},xd="undefined"!=typeof window&&void 0!==window.MotionDebug,vd=["","X","Y","Z"],yd={visibility:"hidden"};let bd=0;function wd(e,t,n,o){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),o&&(o[e]=0))}function jd(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=_s(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:t,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",_i,!(t||o))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&jd(o)}function Cd({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:i}){return class{constructor(e={},n=(null==t?void 0:t())){this.id=bd++,this.animationId=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.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,xd&&(gd.totalNodes=gd.resolvedTargetDeltas=gd.recalculatedProjection=0),this.nodes.forEach(Md),this.nodes.forEach(Id),this.nodes.forEach(Rd),this.nodes.forEach(Td),xd&&window.MotionDebug.record(gd)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new Uu)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new Ds),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){const n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;var o;this.isSVG=(o=t)instanceof SVGElement&&"svg"!==o.tagName,this.instance=t;const{layoutId:i,layout:r,visualElement:s}=this.options;if(s&&!s.current&&s.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(r||i)&&(this.isLayoutDirty=!0),e){let n;const o=()=>this.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=Vs.now(),o=({timestamp:i})=>{const r=i-n;r>=t&&(Ui(o),e(r-t))};return _i.read(o,!0),()=>Ui(o)}(o,250),Lu.hasAnimatedSinceResize&&(Lu.hasAnimatedSinceResize=!1,this.nodes.forEach(zd))}))}i&&this.root.registerSharedNode(i,this),!1!==this.options.animate&&s&&(i||r)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:o})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const i=this.options.transition||s.getDefaultTransition()||$d,{onLayoutAnimationStart:r,onLayoutAnimationComplete:a}=s.getProps(),l=!this.targetLayout||!pd(this.targetLayout,o),c=!t&&n;if(this.options.layoutRoot||this.resumeFrom||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...Es(i,"layout"),onPlay:r,onComplete:a};(s.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||zd(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=o}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Ui(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(Vd),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&jd(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){const t=this.path[e];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}const{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;const o=this.getTransformTemplate();this.prevTransformTemplateValue=o?o(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(Bd);this.isUpdating||this.nodes.forEach(Ad),this.isUpdating=!1,this.nodes.forEach(Ed),this.nodes.forEach(Sd),this.nodes.forEach(kd),this.clearAllSnapshots();const e=Vs.now();Gi.delta=Wr(0,1e3/60,e-Gi.timestamp),Gi.timestamp=e,Gi.isProcessing=!0,qi.update.process(Gi),qi.preRender.process(Gi),qi.render.process(Gi),Gi.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,vr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Pd),this.sharedNodes.forEach(Fd)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,_i.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){_i.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure(),!this.snapshot||ou(this.snapshot.measuredBox.x)||ou(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++){this.path[e].updateScroll()}const e=this.layout;this.layout=this.measure(!1),this.layoutCorrected={x:{min:0,max:0},y:{min:0,max:0}},this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){const t=o(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!i)return;const e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!cd(this.projectionDelta),n=this.getTransformTemplate(),o=n?n(this.latestValues,""):void 0,r=o!==this.prevTransformTemplateValue;e&&(t||yu(this.latestValues)||r)&&(i(this.instance,o),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){const t=this.measurePageBox();let n=this.removeElementScroll(t);var o;return e&&(n=this.removeTransform(n)),Nd((o=n).x),Nd(o.y),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var e;const{visualElement:t}=this.options;if(!t)return{x:{min:0,max:0},y:{min:0,max:0}};const n=t.measureViewportBox();if(!((null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)||this.path.some(Ud))){const{scroll:e}=this.root;e&&(Pu(n.x,e.offset.x),Pu(n.y,e.offset.y))}return n}removeElementScroll(e){var t;const n={x:{min:0,max:0},y:{min:0,max:0}};if(td(n,e),null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)return n;for(let t=0;t<this.path.length;t++){const o=this.path[t],{scroll:i,options:r}=o;o!==this.root&&i&&r.layoutScroll&&(i.wasRoot&&td(n,e),Pu(n.x,i.offset.x),Pu(n.y,i.offset.y))}return n}applyTransform(e,t=!1){const n={x:{min:0,max:0},y:{min:0,max:0}};td(n,e);for(let e=0;e<this.path.length;e++){const o=this.path[e];!t&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Au(n,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),yu(o.latestValues)&&Au(n,o.latestValues)}return yu(this.latestValues)&&Au(n,this.latestValues),n}removeTransform(e){const t={x:{min:0,max:0},y:{min:0,max:0}};td(t,e);for(let e=0;e<this.path.length;e++){const n=this.path[e];if(!n.instance)continue;if(!yu(n.latestValues))continue;vu(n.latestValues)&&n.updateSnapshot();const o={x:{min:0,max:0},y:{min:0,max:0}};td(o,n.measurePageBox()),ad(t,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,o)}return yu(this.latestValues)&&ad(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}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!==Gi.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const o=Boolean(this.resumingFrom)||this!==n;if(!(e||o&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:i,layoutId:r}=this.options;if(this.layout&&(i||r)){if(this.resolvedRelativeTargetAt=Gi.timestamp,!this.targetDelta&&!this.relativeTarget){const e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},lu(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),td(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){var s,a,l;if(this.target||(this.target={x:{min:0,max:0},y:{min:0,max:0}},this.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}}),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),s=this.target,a=this.relativeTarget,l=this.relativeParent.target,su(s.x,a.x,l.x),su(s.y,a.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):td(this.target,this.layout.layoutBox),ku(this.target,this.targetDelta)):td(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const e=this.getClosestProjectingParent();e&&Boolean(e.resumingFrom)===Boolean(this.resumingFrom)&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},lu(this.relativeTargetOrigin,this.target,e.target),td(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}xd&&gd.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(this.parent&&!vu(this.parent.latestValues)&&!bu(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;const t=this.getLead(),n=Boolean(this.resumingFrom)||this!==t;let o=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(o=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(o=!1),this.resolvedRelativeTargetAt===Gi.timestamp&&(o=!1),o)return;const{layout:i,layoutId:r}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!i&&!r)return;td(this.layoutCorrected,this.layout.layoutBox);const s=this.treeScale.x,a=this.treeScale.y;!function(e,t,n,o=!1){const i=n.length;if(!i)return;let r,s;t.x=t.y=1;for(let a=0;a<i;a++){r=n[a],s=r.projectionDelta;const{visualElement:i}=r.options;i&&i.props.style&&"contents"===i.props.style.display||(o&&r.options.layoutScroll&&r.scroll&&r!==r.root&&Au(e,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,ku(e,s)),o&&yu(r.latestValues)&&Au(e,r.latestValues))}t.x<Tu&&t.x>Mu&&(t.x=1),t.y<Tu&&t.y>Mu&&(t.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!t.layout||t.target||1===this.treeScale.x&&1===this.treeScale.y||(t.target=t.layout.layoutBox,t.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}});const{target:l}=t;l?(this.projectionDelta&&this.prevProjectionDelta?(nd(this.prevProjectionDelta.x,this.projectionDelta.x),nd(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),ru(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===s&&this.treeScale.y===a&&md(this.projectionDelta.x,this.prevProjectionDelta.x)&&md(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l)),xd&&gd.recalculatedProjection++):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDeltaWithTransform={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}}setAnimationOrigin(e,t=!1){const n=this.snapshot,o=n?n.latestValues:{},i={...this.latestValues},r={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const s={x:{min:0,max:0},y:{min:0,max:0}},a=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(a&&!c&&!0===this.options.crossfade&&!this.path.some(Od));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;var l,p,h,m,f,g;Ld(r.x,e.x,n),Ld(r.y,e.y,n),this.setTargetDelta(r),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(lu(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),h=this.relativeTarget,m=this.relativeTargetOrigin,f=s,g=n,Dd(h.x,m.x,f.x,g),Dd(h.y,m.y,f.y,g),d&&(l=this.relativeTarget,p=d,ud(l.x,p.x)&&ud(l.y,p.y))&&(this.isProjectionDirty=!1),d||(d={x:{min:0,max:0},y:{min:0,max:0}}),td(d,this.relativeTarget)),a&&(this.animationValues=i,function(e,t,n,o,i,r){i?(e.opacity=bl(0,void 0!==n.opacity?n.opacity:1,Xu(o)),e.opacityExit=bl(void 0!==t.opacity?t.opacity:1,0,Ju(o))):r&&(e.opacity=bl(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,o));for(let i=0;i<qu;i++){const r=`border${Gu[i]}Radius`;let s=Yu(t,r),a=Yu(n,r);void 0===s&&void 0===a||(s||(s=0),a||(a=0),0===s||0===a||Zu(s)===Zu(a)?(e[r]=Math.max(bl(Ku(s),Ku(a),o),0),(Kr.test(a)||Kr.test(s))&&(e[r]+="%")):e[r]=a)}(t.rotate||n.rotate)&&(e.rotate=bl(t.rotate||0,n.rotate||0,o))}(i,o,this.latestValues,n,u,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Ui(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=_i.update((()=>{Lu.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const o=Ar(e)?e:Hs(e);return o.start(Mc("",o,t,n)),o.animation}(0,1e3,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.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 e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:o,latestValues:i}=e;if(t&&n&&o){if(this!==e&&this.layout&&o&&_d(this.options.animationType,this.layout.layoutBox,o.layoutBox)){n=this.target||{x:{min:0,max:0},y:{min:0,max:0}};const t=ou(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const o=ou(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+o}td(t,n),Au(t,i),ru(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new fd);this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const o=this.getStack();o&&o.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;const o={};n.z&&wd("z",e,o,this.animationValues);for(let t=0;t<vd.length;t++)wd(`rotate${vd[t]}`,e,o,this.animationValues),wd(`skew${vd[t]}`,e,o,this.animationValues);e.render();for(const t in o)e.setStaticValue(t,o[t]),this.animationValues&&(this.animationValues[t]=o[t]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return yd;const o={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,o.opacity="",o.pointerEvents=Er(null==e?void 0:e.pointerEvents)||"",o.transform=i?i(this.latestValues,""):"none",o;const r=this.getLead();if(!this.projectionDelta||!this.layout||!r.target){const t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=Er(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!yu(this.latestValues)&&(t.transform=i?i({},""):"none",this.hasProjected=!1),t}const s=r.animationValues||r.latestValues;this.applyTransformsToTarget(),o.transform=function(e,t,n){let o="";const i=e.x.translate/t.x,r=e.y.translate/t.y,s=(null==n?void 0:n.z)||0;if((i||r||s)&&(o=`translate3d(${i}px, ${r}px, ${s}px) `),1===t.x&&1===t.y||(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:e,rotate:t,rotateX:i,rotateY:r,skewX:s,skewY:a}=n;e&&(o=`perspective(${e}px) ${o}`),t&&(o+=`rotate(${t}deg) `),i&&(o+=`rotateX(${i}deg) `),r&&(o+=`rotateY(${r}deg) `),s&&(o+=`skewX(${s}deg) `),a&&(o+=`skewY(${a}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return 1===a&&1===l||(o+=`scale(${a}, ${l})`),o||"none"}(this.projectionDeltaWithTransform,this.treeScale,s),i&&(o.transform=i(s,o.transform));const{x:a,y:l}=this.projectionDelta;o.transformOrigin=`${100*a.origin}% ${100*l.origin}% 0`,r.animationValues?o.opacity=r===this?null!==(n=null!==(t=s.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:o.opacity=r===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0;for(const e in gs){if(void 0===s[e])continue;const{correct:t,applyTo:n,isCSSVariable:i}=gs[e],a="none"===o.transform?s[e]:t(s[e],r);if(n){const e=n.length;for(let t=0;t<e;t++)o[n[t]]=a}else i?this.options.visualElement.renderState.vars[e]=a:o[e]=a}return this.options.layoutId&&(o.pointerEvents=r===this?Er(null==e?void 0:e.pointerEvents)||"":"none"),o}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(Bd),this.root.sharedNodes.clear()}}}function Sd(e){e.updateLayout()}function kd(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:o}=e.layout,{animationType:i}=e.options,r=n.source!==e.layout.source;"size"===i?fu((e=>{const o=r?n.measuredBox[e]:n.layoutBox[e],i=ou(o);o.min=t[e].min,o.max=o.min+i})):_d(i,n.layoutBox,t)&&fu((o=>{const i=r?n.measuredBox[o]:n.layoutBox[o],s=ou(t[o]);i.max=i.min+s,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[o].max=e.relativeTarget[o].min+s)}));const s={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};ru(s,t,n.layoutBox);const a={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};r?ru(a,e.applyTransform(o,!0),n.measuredBox):ru(a,t,n.layoutBox);const l=!cd(s);let c=!1;if(!e.resumeFrom){const o=e.getClosestProjectingParent();if(o&&!o.resumeFrom){const{snapshot:i,layout:r}=o;if(i&&r){const s={x:{min:0,max:0},y:{min:0,max:0}};lu(s,n.layoutBox,i.layoutBox);const a={x:{min:0,max:0},y:{min:0,max:0}};lu(a,t,r.layoutBox),pd(s,a)||(c=!0),o.options.layoutRoot&&(e.relativeTarget=a,e.relativeTargetOrigin=s,e.relativeParent=o)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function Md(e){xd&&gd.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Td(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Pd(e){e.clearSnapshot()}function Bd(e){e.clearMeasurements()}function Ad(e){e.isLayoutDirty=!1}function Ed(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function zd(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Id(e){e.resolveTargetDelta()}function Rd(e){e.calcProjection()}function Vd(e){e.resetSkewAndRotation()}function Fd(e){e.removeLeadSnapshot()}function Ld(e,t,n){e.translate=bl(t.translate,0,n),e.scale=bl(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Dd(e,t,n,o){e.min=bl(t.min,n.min,o),e.max=bl(t.max,n.max,o)}function Od(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const $d={duration:.45,ease:[.4,0,.1,1]},Hd=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Wd=Hd("applewebkit/")&&!Hd("chrome/")?Math.round:Di;function Nd(e){e.min=Wd(e.min),e.max=Wd(e.max)}function _d(e,t,n){return"position"===e||"preserve-aspect"===e&&(o=hd(t),i=hd(n),r=.2,!(Math.abs(o-i)<=r));var o,i,r}function Ud(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}const Gd=Cd({attachResizeListener:(e,t)=>Gc(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),qd={current:void 0},Kd=Cd({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!qd.current){const e=new Gd({});e.mount(window),e.setOptions({layoutScroll:!0}),qd.current=e}return qd.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),Zd={pan:{Feature:class extends $c{constructor(){super(...arguments),this.removePointerDownListener=Di}onPointerDown(e){this.session=new Yc(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:zu(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:o}=this.node.getProps();return{onSessionStart:Fu(e),onStart:Fu(t),onMove:n,onEnd:(e,t)=>{delete this.session,o&&_i.postRender((()=>o(e,t)))}}}mount(){this.removePointerDownListener=Kc(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends $c{constructor(e){super(e),this.removeGroupControls=Di,this.removeListeners=Di,this.controls=new Ru(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Di}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:Kd,MeasureLayout:Wu}};function Yd(e,t){const n=function(e){if(e instanceof Element)return[e];if("string"==typeof e){const t=document.querySelectorAll(e);return t?Array.from(t):[]}return Array.from(e)}(e),o=new AbortController;return[n,{passive:!0,...t,signal:o.signal},()=>o.abort()]}function Xd(e){return!("touch"===e.pointerType||_c())}function Jd(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover","Start"===n);const i=o["onHover"+n];i&&_i.postRender((()=>i(t,qc(t))))}const Qd=(e,t)=>!!t&&(e===t||Qd(e,t.parentElement)),ep=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);const tp=new WeakSet;function np(e){return t=>{"Enter"===t.key&&e(t)}}function op(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function ip(e){return Uc(e)&&!_c()}function rp(e,t,n={}){const[o,i,r]=Yd(e,n),s=e=>{const o=e.currentTarget;if(!ip(e)||tp.has(o))return;tp.add(o);const r=t(o,e),s=(e,t)=>{window.removeEventListener("pointerup",a),window.removeEventListener("pointercancel",l),ip(e)&&tp.has(o)&&(tp.delete(o),"function"==typeof r&&r(e,{success:t}))},a=e=>{s(e,n.useGlobalTarget||Qd(o,e.target))},l=e=>{s(e,!1)};window.addEventListener("pointerup",a,i),window.addEventListener("pointercancel",l,i)};return o.forEach((e=>{(function(e){return ep.has(e.tagName)||-1!==e.tabIndex})(e)||null!==e.getAttribute("tabindex")||(e.tabIndex=0);(n.useGlobalTarget?window:e).addEventListener("pointerdown",s,i),e.addEventListener("focus",(e=>((e,t)=>{const n=e.currentTarget;if(!n)return;const o=np((()=>{if(tp.has(n))return;op(n,"down");const e=np((()=>{op(n,"up")}));n.addEventListener("keyup",e,t),n.addEventListener("blur",(()=>op(n,"cancel")),t)}));n.addEventListener("keydown",o,t),n.addEventListener("blur",(()=>n.removeEventListener("keydown",o)),t)})(e,i)),i)})),r}function sp(e,t,n){const{props:o}=e;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap","Start"===n);const i=o["onTap"+("End"===n?"":n)];i&&_i.postRender((()=>i(t,qc(t))))}const ap=new WeakMap,lp=new WeakMap,cp=e=>{const t=ap.get(e.target);t&&t(e)},up=e=>{e.forEach(cp)};function dp(e,t,n){const o=function({root:e,...t}){const n=e||document;lp.has(n)||lp.set(n,{});const o=lp.get(n),i=JSON.stringify(t);return o[i]||(o[i]=new IntersectionObserver(up,{root:e,...t})),o[i]}(t);return ap.set(e,n),o.observe(e),()=>{ap.delete(e),o.unobserve(e)}}const pp={some:0,all:1};const hp={inView:{Feature:class extends $c{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:o="some",once:i}=e,r={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof o?o:pp[o]};return dp(this.node.current,r,(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,i&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:o}=this.node.getProps(),r=t?n:o;r&&r(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends $c{mount(){const{current:e}=this.node;e&&(this.unmount=rp(e,((e,t)=>(sp(this.node,t,"Start"),(e,{success:t})=>sp(this.node,e,t?"End":"Cancel"))),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends $c{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&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=Pl(Gc(this.node.current,"focus",(()=>this.onFocus())),Gc(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends $c{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[o,i,r]=Yd(e,n),s=e=>{if(!Xd(e))return;const{target:n}=e,o=t(n,e);if("function"!=typeof o||!n)return;const r=e=>{Xd(e)&&(o(e),n.removeEventListener("pointerleave",r))};n.addEventListener("pointerleave",r,i)};return o.forEach((e=>{e.addEventListener("pointerenter",s,i)})),r}(e,((e,t)=>(Jd(this.node,t,"Start"),e=>Jd(this.node,e,"End")))))}unmount(){}}}},mp={layout:{ProjectionNode:Kd,MeasureLayout:Wu}},fp={current:null},gp={current:!1};const xp=[...ul,Aa,Oa],vp=new WeakMap;const yp=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class bp{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:i,visualState:r},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=rl,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 e=Vs.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,_i.render(this.render,!1,!0))};const{latestValues:a,renderState:l,onUpdate:c}=r;this.onUpdate=c,this.latestValues=a,this.baseTarget={...a},this.initialValues=t.initial?{...a}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=o,this.options=s,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=cr(t),this.isVariantNode=ur(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(e&&e.current);const{willChange:u,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(const e in d){const t=d[e];void 0!==a[e]&&Ar(t)&&t.set(a[e],!1)}}mount(e){this.current=e,vp.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((e,t)=>this.bindToMotionValue(t,e))),gp.current||function(){if(gp.current=!0,Fi)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>fp.current=e.matches;e.addListener(t),t()}else fp.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||fp.current),"production"!==process.env.NODE_ENV&&nr(!0!==this.shouldReduceMotion,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){vp.delete(this.current),this.projection&&this.projection.unmount(),Ui(this.notifyUpdate),Ui(this.render),this.valueSubscriptions.forEach((e=>e())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const n=Vr.has(e),o=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&_i.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=t.on("renderRequest",this.scheduleRender);let r;window.MotionCheckAppearSync&&(r=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,(()=>{o(),i(),r&&r(),t.owner&&t.stop()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in Yi){const t=Yi[e];if(!t)continue;const{isEnabled:n,Feature:o}=t;if(!this.features[e]&&o&&n(this.props)&&(this.features[e]=new o(this)),this.features[e]){const t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<yp.length;t++){const n=yp[t];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);const o=e["on"+n];o&&(this.propEventSubscriptions[n]=this.on(n,o))}this.prevMotionValues=function(e,t,n){for(const o in t){const i=t[o],r=n[o];if(Ar(i))e.addValue(o,i),"development"===process.env.NODE_ENV&&nr("12.0.6"===i.version,`Attempting to mix Motion versions ${i.version} with 12.0.6 may not work as expected.`);else if(Ar(r))e.addValue(o,Hs(i,{owner:e}));else if(r!==i)if(e.hasValue(o)){const t=e.getValue(o);!0===t.liveStyle?t.jump(i):t.hasAnimated||t.set(i)}else{const t=e.getStaticValue(o);e.addValue(o,Hs(void 0!==t?t:i,{owner:e}))}}for(const o in n)void 0===t[o]&&e.removeValue(o);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]: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(e){const t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){const n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=Hs(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let o=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];var i;return null!=o&&("string"==typeof o&&(sl(o)||ba(o))?o=parseFloat(o):(i=o,!xp.find(cl(i))&&Oa.test(t)&&(o=Ga(e,t))),this.setBaseTarget(e,Ar(o)?o.get():o)),Ar(o)?o.get():o}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props;let o;if("string"==typeof n||"object"==typeof n){const i=Pr(this.props,n,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);i&&(o=i[e])}if(n&&void 0!==o)return o;const i=this.getBaseTargetFromProps(this.props,e);return void 0===i||Ar(i)?void 0!==this.initialValues[e]&&void 0===o?void 0:this.baseTarget[e]:i}on(e,t){return this.events[e]||(this.events[e]=new Ds),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class wp extends bp{constructor(){super(...arguments),this.KeyframeResolver=pl}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Ar(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}}class jp extends wp{constructor(){super(...arguments),this.type="html",this.renderInstance=hs}readValueFromInstance(e,t){if(Vr.has(t)){const e=Ua(t);return e&&e.default||0}{const o=(n=e,window.getComputedStyle(n)),i=(Lr(t)?o.getPropertyValue(t):o[t])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(e,{transformPagePoint:t}){return Eu(e,t)}build(e,t,n){rs(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return vs(e,t,n)}}class Cp extends wp{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=mu}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(Vr.has(t)){const e=Ua(t);return e&&e.default||0}return t=ms.has(t)?t:gr(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return ys(e,t,n)}build(e,t,n){cs(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,o){fs(e,t,0,o)}mount(e){this.isSVGTag=ps(e.tagName),super.mount(e)}}const Sp=(t,n)=>Mr(t)?new Cp(n):new jp(n,{allowProjection:t!==e.Fragment}),kp=or(Ps({...Wc,...hp,...Zd,...mp},Sp)),Mp=t.styled((({children:e,loading:n,sizing:o,...i})=>ge.jsxs(Jn,{...i,sizing:o,loading:n,children:[n&&ge.jsx(vn,{sizing:o}),ge.jsx(t.Box,{...n?{visibility:"hidden"}:void 0,children:e})]})))((({theme:e,variation:t,sizing:n})=>({color:e.custom.palette.text.primary,...n&&{...Yn(n)},...n&&{...Xn(n)},...n&&{...Zn(n)},"&:hover:before":{backgroundColor:e.custom.palette.interaction.hover},"&:focus:before":{backgroundColor:e.custom.palette.interaction.hover},"&:active:before":{backgroundColor:e.custom.palette.interaction.press},"&:disabled":{backgroundColor:e.custom.palette.interaction.disabled,color:e.custom.palette.text.disabled},..."subtle"===t&&{...Wn(e)},..."outlined"===t&&{...Nn(e)},..."secondary"===t&&{..._n(e)},..."primary"===t&&{...Un(e)}}))),Tp=({sizing:e="lg",variation:t="primary",...n})=>ge.jsx(Mp,{variation:t,sizing:e,...n}),Pp=t.styled(r.TimelineDot)((({theme:e,completed:t})=>({width:"24px",height:"24px",backgroundColor:e.custom.palette.surface.raised,boxShadow:"none",border:"none",padding:0,margin:"4px 0",...!t&&{border:`2px dashed ${e.custom.palette.icon.disabled}`}}))),Bp=t.styled(t.Box)((({theme:e})=>({display:"flex",flexDirection:"column",padding:`0 0 ${e.spacing(e.custom.padding.md)} ${e.spacing(e.custom.padding.sm)}`}))),Ap=e=>({display:"flex",flexWrap:"wrap",alignItems:"center",gap:e.spacing(e.custom.padding.sm),marginTop:e.spacing(e.custom.margin.xs)}),Ep=t.styled(cn)((({theme:e})=>({[`&.${t.linkClasses.root}`]:{...Ap(e),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.link},"&:hover":{"> .MuiTypography-root:first-child":{textDecoration:"underline"},"& .MuiSvgIcon-root":{color:e.custom.palette.icon.linkHover}}}}))),zp=t.styled(t.Box)((({theme:e})=>({[`&.${t.boxClasses.root}`]:{...Ap(e),"& .MuiTypography-root":{color:"inherit"}}}))),Ip=t.styled(dn)((()=>({color:"inherit",fontWeight:500,fontSize:Hn.lg}))),Rp=t.styled(dn)((({theme:e})=>({fontWeight:400,textDecoration:"none",color:e.custom.palette.text.secondary,flexBasis:"100%"}))),Vp=({children:e,complete:t,url:n})=>t?ge.jsx(zp,{children:e}):ge.jsx(Ep,{underline:"none",href:n,target:"_self",children:e}),Fp=({complete:e,title:t,description:n,url:o})=>ge.jsx(Bp,{children:ge.jsxs(Vp,{complete:e,url:o,children:[ge.jsx(Ip,{component:"p",variation:"lg",children:t}),!e&&ge.jsx(en,{name:"arrow-right",size:16}),!e&&n&&ge.jsx(Rp,{variation:"lg",component:"p",children:n})]})}),Lp=({item:e,showConnector:t})=>{const{complete:n,title:o,description:i,url:s}=e;return ge.jsxs(r.TimelineItem,{children:[ge.jsxs(r.TimelineSeparator,{children:[ge.jsx(Pp,{completed:n,children:n?ge.jsx(en,{name:"badge-tick-in-circle",size:24}):void 0}),t&&ge.jsx(r.TimelineConnector,{sx:{backgroundColor:e=>e.custom.palette.icon.disabled}})]}),e&&ge.jsx(r.TimelineContent,{component:()=>ge.jsx(Fp,{complete:n,title:o,description:i,url:s})})]})},Dp=({expanded:n,onToggleExpanded:o,items:i})=>{const s=i.find((e=>!e.complete)),a=e.useMemo((()=>n?i:[s]),[n]),l=e.useRef(null),[c,u]=e.useState("auto");return e.useEffect((()=>{if(!l.current)return;const e=l.current.scrollHeight+1.5*Q;u(e)}),[n,i]),ge.jsx(kp.div,{initial:!1,animate:{height:c},transition:{duration:.4,ease:[.645,.045,.355,1]},style:{overflow:"hidden",paddingBottom:1.5*Q},children:ge.jsx("div",{ref:l,children:ge.jsxs(zi,{sx:{paddingLeft:e=>e.spacing(e.custom.padding.xs),[`& .${r.timelineItemClasses.root}`]:{minHeight:0,":before":{flex:0,padding:0}}},children:[a.map(((e,t)=>{const n=t<a.length-1;return e&&e?.title===s?.title?ge.jsx(Lp,{item:e,showConnector:a.length>1?n:!!s?.description},e.title):e&&ge.jsx(Lp,{item:e,showConnector:n},e.title)})),!n&&ge.jsx(t.Box,{sx:{marginTop:e=>e.spacing(e.custom.margin.md),alignSelf:"center"},children:ge.jsx(Tp,{endIcon:ge.jsx(en,{name:"chevron-down",size:16}),sizing:"xs",variation:"outlined",onClick:o,children:"Show more"})})]})})})},Op=({completed:e,total:t})=>ge.jsx(dn,{component:"p",variation:"lg",sx:{fontWeight:500},children:`${e} of ${t} tasks completed`}),$p=t.styled(t.Box)((({theme:e})=>({width:2,height:2,borderRadius:"50%",backgroundColor:e.custom.palette.icon.disabled,marginLeft:e.spacing(e.custom.margin.sm),marginRight:e.spacing(e.custom.margin.sm)}))),Hp=(e,n)=>ge.jsxs(t.Box,{display:"flex",gap:1,children:[ge.jsx(dn,{variation:"sm",component:"p",weight:"bold",children:e||0}),ge.jsx(dn,{variation:"sm",component:"p",color:"text.secondary",children:n})]}),Wp=({loops:e,tests:n,drafts:o})=>ge.jsxs(t.Box,{display:"flex",alignItems:"center",children:[Hp(e,"Loops"),ge.jsx($p,{}),Hp(n,"Tests"),ge.jsx($p,{}),Hp(o,"Drafts")]}),Np=t.styled(t.Box)((({theme:e})=>({borderRadius:e.spacing(e.custom.radius.sm),border:`0.5px solid ${e.custom.palette.stroke.focus}`,backgroundColor:e.custom.palette.purple[0],padding:`${e.spacing(e.custom.padding.xs)} ${e.spacing(e.custom.padding.sm)}`,"& p":{color:e.custom.palette.purple[1e3]}}))),_p=({sx:e,body:t})=>ge.jsx(Np,{"data-id":"pill-container",sx:n.mergeSx(e,{position:"absolute",zIndex:1}),children:ge.jsx(dn,{variation:"xxs",component:"p",weight:"bold",children:t})}),Up=({title:e,maxLines:t})=>ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:{overflow:"hidden",display:"-webkit-box","-webkit-line-clamp":`${t}`,"-webkit-box-orient":"vertical"},children:e}),Gp=e=>{const t=e.toLowerCase();return["a","e","i","o","u"].some((e=>t.startsWith(e)))?"an":"a"},qp=(e,t,n)=>({maxLength:{value:n||255,message:`Maximum character limit of ${n||255}.`},...t&&{required:e?`Please enter ${Gp(e)} ${e}`:"This field is required"}}),Kp=qp().maxLength.value,Zp=e=>`linear-gradient(135deg, ${e.custom.palette.purple[400]} 0%, ${e.custom.palette.purple[200]} 100%)`,Yp=(e,n)=>{switch(n){case"tone1":default:return Zp(e);case"tone2":return(e=>`linear-gradient(135deg, ${e.custom.palette.purple[0]} 0%, ${e.custom.palette.purple[100]} 100%)`)(e);case"tone3":return(e=>`linear-gradient(135deg, ${e.custom.palette.blue[400]} 0%, ${e.custom.palette.purple[600]} 100%)`)(e);case"tone4":return(e=>`radial-gradient(54.59% 50% at 0% 50.04%, ${t.alpha(e.custom.palette.blue[1e3],.2)} 0%, ${t.alpha(e.custom.palette.blue[500],.2)} 100%), linear-gradient(135deg, ${e.custom.palette.purple[500]} 0%, ${e.custom.palette.purple[1e3]} 100%)`)(e)}},Xp=(e,t)=>{const n=Yp(e,t.gradient),o=(e=>"noise1"===e?"url(https://useloops-public.s3.eu-west-2.amazonaws.com/public/static/misc/noise_tile.png)":null)(t.texture);return o?[o,n].join(","):[n].join(",")},Jp=({label:e,sx:o,...i})=>{const r=t.useTheme(),s=e?r.custom.margin.md:0;return ge.jsx(t.FormControlLabel,{label:e||"",sx:n.mergeSx({ml:0,"&.Mui-disabled":{color:r.custom.palette.text.disabled},"&.Mui-error":{color:r.custom.palette.text.negative},"& .MuiFormControlLabel-label":{ml:s,color:"inherit",fontSize:{xs:On.sm.body.md,sm:On.sm.body.md,md:On.sm.body.md,lg:On.lg.body.md,xl:On.lg.body.md}},"&.MuiFormControlLabel-labelPlacementStart":{"& .MuiFormControlLabel-label":{ml:0,mr:s}}},o),...i})},Qp=t.styled(t.Checkbox)((({theme:e,sizing:t})=>({height:"default"===t?J[300]:J[400],width:"default"===t?J[300]:J[400],padding:0,flex:"none",borderRadius:e.spacing(e.custom.radius.sm),border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.input.default,position:"relative",transition:e.custom.easing.input,"& svg":{transition:e.custom.easing.input,fill:"none",width:"default"===t?Qt.sm:Qt.xl,height:"default"===t?Qt.sm:Qt.xl},"&:before":{content:'""',position:"absolute",inset:0},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled},"&.Mui-checked":{backgroundColor:e.custom.palette.purple[500],"& svg":{fill:e.custom.palette.icon.lockedWhite},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,"& svg":{fill:e.custom.palette.icon.disabled}}},"&.MuiCheckbox-indeterminate":{backgroundColor:e.custom.palette.purple[500],"& svg":{fill:e.custom.palette.icon.lockedWhite}},"&.Mui-focusVisible":{borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}}}))),eh=e=>ge.jsx(Qp,{checkedIcon:ge.jsx(o.Check,{}),indeterminateIcon:ge.jsx(o.Remove,{}),...e}),th=({internalChange:e,checkboxLabel:n,indeterminate:o,sizing:i="default",onChange:r,inputRef:s,value:a,...l})=>void 0===a?ge.jsx(t.Box,{}):ge.jsx(Jp,{inputRef:s,label:n,checked:a,control:ge.jsx(eh,{sizing:i,indeterminate:o}),onChange:(t,n)=>{r&&r(t,n),e&&e()},...l}),nh=t.styled(t.TextField)((({theme:e})=>({"& .MuiInputAdornment-root":{marginRight:0,"& .MuiSvgIcon-root":{width:Qt.xl,height:Qt.xl}},"& .MuiOutlinedInput-input":{padding:e.spacing(1),paddingLeft:e.spacing(2),paddingRight:e.spacing(2)},"& .MuiOutlinedInput-root":{backgroundColor:e.custom.palette.input.default,color:e.custom.palette.text.primary,borderRadius:e.spacing(e.custom.radius.md),lineHeight:"140%",[e.breakpoints.down("md")]:{minWidth:"100%"},paddingLeft:0,paddingRight:0,fontSize:On.sm.body.md,"&.Mui-focused":{"& fieldset":{transition:e.custom.easing.input,backgroundColor:e.custom.palette.interaction.press,borderColor:e.custom.palette.stroke.default},"& .MuiOutlinedInput-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.focus}`,boxShadow:e.custom.boxShadow.input.focus}},"&.Mui-disabled":{color:e.custom.palette.text.disabled,backgroundColor:e.custom.palette.input.disabled,"& fieldset":{transition:e.custom.easing.input,backgroundColor:e.custom.palette.interaction.none,borderColor:e.custom.palette.stroke.disabled},"& .MuiOutlinedInput-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.disabled}`,boxShadow:"none"}}},"&:hover":{"& .MuiOutlinedInput-root":{backgroundColor:e.custom.palette.input.default,"& fieldset":{backgroundColor:e.custom.palette.interaction.hover,borderColor:e.custom.palette.stroke.default},"&.Mui-focused":{"& fieldset":{backgroundColor:e.custom.palette.interaction.press,borderColor:e.custom.palette.stroke.default},"& .MuiOutlinedInput-notchedOutline":{border:`1px solid ${e.custom.palette.stroke.focus}`,boxShadow:e.custom.boxShadow.input.focus}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,"& fieldset":{backgroundColor:e.custom.palette.interaction.none,borderColor:e.custom.palette.stroke.disabled},"& .MuiOutlinedInput-notchedOutline":{border:`1px solid ${e.custom.palette.stroke.disabled}`,boxShadow:"none"}}}}}))),oh=({startAdornment:e,endAdornment:n,placeholder:o,onChange:i,internalChange:r,inputRef:s,...a})=>ge.jsx(nh,{placeholder:o,sx:{height:J[500],"& .MuiOutlinedInput-input":{pl:e?1:2,pr:e?1:2}},inputRef:s,InputProps:{startAdornment:e?ge.jsx(t.InputAdornment,{position:"start",sx:{pl:1},children:e}):null,endAdornment:n?ge.jsx(t.InputAdornment,{position:"start",sx:{pr:1},children:n}):null},...a,onChange:e=>{i&&i(e),r&&r()}}),ih=({sizing:e,options:n,other:o,internalChange:i,value:r,inputRef:s,onChange:a})=>{const l=o?.name||"other-option",c=`${l}-value-`,u=e=>`${c}${e}`,d=o?.enabled,p=r?.includes(l)&&d,h=r?.find((e=>e.includes(c)));if(!r)return ge.jsx("div",{});const m=(e,t)=>{let s=r.includes(e)?r.filter((t=>t!==e)):t?[e]:[...new Set(r),e];if(t||(s=s.filter((e=>!n.find((t=>t?.exclusive&&e===t.value))))),o?.enabled){!r.includes(l)||e!==l||(s=s.filter((e=>!e.includes(c))))}a(s),i&&i()};return ge.jsxs(ge.Fragment,{children:[ge.jsxs(t.FormGroup,{sx:{display:"flex",gap:e=>e.custom.margin.sm,label:{"&:last-child":{mb:0},"&:hover":{"& .MuiCheckbox-root":{backgroundColor:e=>e.custom.palette.interaction.hover,"&.Mui-checked":{backgroundColor:e=>e.custom.palette.purple[500]}}}}},children:[n?n.map(((t,n)=>{const o=t.value;return ge.jsx(Jp,{sx:{"& .MuiButtonBase-root.MuiCheckbox-root":{alignSelf:"baseline"},"& .MuiTypography-root":{mt:"default"!==e?.5:0}},onChange:()=>m(o,t.exclusive),checked:r.includes(o),control:ge.jsx(eh,{sizing:e}),label:t.label},o)})):null,d&&ge.jsx(Jp,{inputRef:s,onChange:()=>m(l),label:o?.label||"Other",checked:r.includes(l),control:ge.jsx(eh,{sizing:e})},l)]}),p&&ge.jsx(t.Box,{sx:{mt:1},children:ge.jsx(oh,{fullWidth:!0,autoFocus:!0,defaultValue:h?h.replace(c,""):"",placeholder:o?.placeholder,onChange:e=>{const t=r.find((e=>e.includes(c))),n=(t?r.map((t=>t.includes(c)?u(e.target.value):t)):[...r,u(e.target.value)]).filter((e=>e!==c));a(n),i&&i()},required:!0})})]})},rh=({inputField:e,onChange:t,internalChange:n,transformValue:o,...i})=>{const r=e;return ge.jsx(r,{onChange:e=>{t&&t(o?o(e):e),n&&n()},...i})},sh=t.styled(t.InputLabel)((({theme:e,align:t})=>({fontWeight:400,lineHeight:"140%",whiteSpace:"normal",textAlign:t,color:"inherit","&.Mui-disabled":{color:e.custom.palette.text.disabled},"&.Mui-error":{color:e.custom.palette.text.negative}}))),ah=e=>ge.jsx(sh,{...e}),lh=e=>{const{icon:n=null,state:i="default",disabled:r,showicon:s=!0}=e,a=t.useTheme();return ge.jsxs(t.Box,{sx:{display:"inline-flex",alignItems:"center",color:r?a.custom.palette.text.disabled:(()=>{switch(i){case"disabled":return a.custom.palette.text.disabled;case"positive":return a.custom.palette.text.positive;case"negative":return a.custom.palette.text.negative;default:return a.custom.palette.text.secondary}})(),"& svg":{marginRight:a.spacing(a.custom.margin.xs),width:Qt.xs,height:Qt.xs,color:"inherit"}},children:[(()=>{if(!s)return null;if(n)return n;switch(i){case"disabled":default:return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.Info,{})});case"positive":return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.Check,{})});case"negative":return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.ErrorOutline,{})})}})(),ge.jsx(ah,{...e,sx:{fontSize:{xs:On.sm.body.sm,sm:On.sm.body.sm,md:On.sm.body.sm,lg:On.lg.body.sm,xl:On.lg.body.sm}}})]})},ch=t.styled(t.Box)((({theme:e})=>({"& .MuiGrid-item":{"&:first-of-type":{"& .MuiBox-root":{"& .MuiRadio-root":{"&:before":{content:'""',position:"absolute",width:J[50],height:J[50],top:`calc(100% + ${J[50]}px)`,margin:"0 auto",background:e.custom.palette.stroke.default}}}},"&:last-of-type":{"& .MuiBox-root":{"& .MuiRadio-root":{"&:before":{content:'""',position:"absolute",width:J[50],height:J[50],top:`calc(100% + ${J[50]}px)`,margin:"0 auto",background:e.custom.palette.stroke.default}}}}}}))),uh=({children:e,width:t})=>ge.jsx(ch,{sx:{width:t,minWidth:300},children:e}),dh=t.styled(t.Radio)((({theme:e,sizing:t})=>({padding:0,backgroundColor:e.custom.palette.input.default,border:`1px solid ${e.custom.palette.stroke.default}`,position:"relative",transition:e.custom.easing.input,flexShrink:0,height:"default"===t?J[300]:J[400],width:"default"===t?J[300]:J[400],"& svg":{transition:e.custom.easing.input,fill:"none",width:"default"===t&&Qt.sm,height:"default"===t&&Qt.sm},"&:before":{content:'""',position:"absolute",inset:0,borderRadius:e.custom.radius.round},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.disabled}},"&.Mui-focusVisible":{borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-checked":{backgroundColor:e.custom.palette.purple[500],"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.lockedWhite},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.disabled}}}}))),ph=e=>ge.jsx(dh,{...e}),hh=t.styled(ph)((()=>({marginRight:0}))),mh=t.styled(t.Box)((({theme:e})=>({posiion:"relative","&:after":{content:'""',position:"absolute",top:"50%",right:"0",height:J[50],width:`calc(100% - ${J[400]}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default}}))),fh=e=>ge.jsx(mh,{sx:{position:"relative"},children:ge.jsx(hh,{...e})}),gh=({disabled:e=!1,onChange:n,labelLeft:o,labelRight:i,internalChange:r,labelCenter:s})=>{const a=[...Array(7).keys()];return ge.jsx(t.RadioGroup,{children:ge.jsxs(uh,{children:[ge.jsx(t.Grid,{container:!0,justifyContent:"space-between",children:a.map(((o,i)=>{const s=i+1!==a.length;return ge.jsx(t.Grid,{item:!0,sm:s,children:ge.jsx(fh,{disabled:e,value:o,onChange:(e,t)=>{n&&n(e,t),r&&r()},name:`radio-option-${o}`},o)},o)}))}),ge.jsxs(t.Grid,{container:!0,justifyContent:"space-between",sx:{mt:1},children:[ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"left"},children:ge.jsx(lh,{disabled:e,showicon:!1,children:o})}),ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"center"},children:ge.jsx(lh,{disabled:e,align:"center",showicon:!1,children:s})}),ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"right"},children:ge.jsx(lh,{disabled:e,align:"right",showicon:!1,children:i})})]})]})})},xh=t.styled(t.Menu)((({theme:e})=>({"& .MuiPaper-root":{backgroundColor:e.custom.palette.surface.raised,borderRadius:e.spacing(e.custom.radius.sm),marginTop:e.spacing(1),minWidth:180,border:`1px solid ${e.custom.palette.stroke.default}`,boxShadow:"none","& .MuiMenu-list":{padding:`${e.spacing(e.custom.padding.xs)} 0`},"& .MuiMenuItem-root":{"& .MuiSvgIcon-root":{color:e.custom.palette.text.primary},"&:active":{backgroundColor:t.alpha(e.palette.primary.main,e.palette.action.selectedOpacity)}}}}))),vh=t=>{const n=e.useRef();return e.useEffect((()=>{n.current=t}),[t]),n.current},yh=({children:e,...t})=>e,bh=({sx:e,...t})=>ge.jsx(ah,{...t,sx:n.mergeSx({fontSize:{xs:On.sm.body.md,sm:On.sm.body.md,md:On.sm.body.md,lg:On.lg.body.md,xl:On.lg.body.md}},!!e&&{...e})}),wh=t.styled(t.Box)((({theme:e})=>({"& .MuiGrid-item":{"&:first-of-type":{"& .MuiBox-root":{"&:before":{width:J[200],borderRadius:e.custom.radius.round,right:"50%",transform:`translateX(-${J[200]}px)`,left:"auto"}}},"&:last-child":{"& .MuiBox-root":{"&:after":{width:J[200],borderRadius:e.custom.radius.round,right:"auto",left:"50%",transform:`translateX(${J[200]}px)`}}}}}))),jh=({children:e,width:t})=>ge.jsx(wh,{sx:{width:t},children:e}),Ch=t.styled(lh)((()=>({lineHeight:"110%",textAlign:"center",width:"100%"}))),Sh=({disabled:e,children:t})=>ge.jsx(Ch,{showicon:!1,disabled:e,sx:{cursor:"inherit"},children:t}),kh=t.styled(ph)((()=>({marginRight:0}))),Mh=t.styled(t.Box)((({theme:e})=>({posiion:"relative","&:before":{content:'""',position:"absolute",top:"50%",left:0,height:J[50],width:`calc(50% - ${J[400]/2}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default},"&:after":{content:'""',position:"absolute",top:"50%",right:0,height:J[50],width:`calc(50% - ${J[400]/2}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default}}))),Th=e=>ge.jsx(Mh,{sx:{textAlign:"center",position:"relative"},children:ge.jsx(kh,{...e})}),Ph=({options:e=[],disabled:n=!1,sizing:o="lg",onChange:i,internalChange:r,value:s})=>{const a=t.useTheme();function l(e){console.warn(e),i(e.value),r&&r()}return ge.jsx(t.Box,{children:ge.jsx(jh,{children:ge.jsx(t.Grid,{container:!0,justifyContent:"space-between",children:e.map((e=>ge.jsxs(t.Grid,{item:!0,sm:!0,onClick:()=>l(e),sx:{...!n&&{cursor:"pointer"},textAlign:"center","&:hover":{"& .MuiButtonBase-root.MuiRadio-root":{"&:before":{...!n&&{backgroundColor:a.custom.palette.interaction.hover}}}},"&:active":{"& .MuiButtonBase-root.MuiRadio-root":{...!n&&{backgroundColor:a.custom.palette.input.default,borderColor:a.custom.palette.stroke.focus,boxShadow:a.custom.boxShadow.input.focus},"&:before":{...!n&&{backgroundColor:a.custom.palette.interaction.press}},"&.Mui-checked":{backgroundColor:a.custom.palette.purple[500]}}}},children:[ge.jsx(Th,{sizing:o,disabled:n,onChange:t=>l(e),checked:s===e.value},e.value),ge.jsx(t.Box,{sx:{mt:ee.xs,width:"100%"},children:ge.jsx(Sh,{disabled:n,children:e.label})})]},e.value)))})})})},Bh=e.forwardRef(((t,n)=>{const{decimalSeparator:o,thousandSeparator:i,value:r,...s}=t,a=e.useMemo((()=>{return e=void 0,new Intl.NumberFormat(e).formatToParts(1234.5678).find((e=>"group"===e.type))?.value??"";var e}),[void 0]),l=e.useMemo((()=>{return e=void 0,new Intl.NumberFormat(e).formatToParts(1234.5678).find((e=>"decimal"===e.type))?.value??".";var e}),[void 0]);return ge.jsx(u.NumericFormat,{...s,value:r??"",getInputRef:n,thousandSeparator:i??a,decimalSeparator:o??l})})),Ah=({disabled:n=!1,InputProps:i,inputProps:r,placeholder:s,hideActionButtons:a=!1,max:l=1/0,min:c=-1/0,startAdornment:u,endAdornment:d,internalChange:p,numericFormatProps:h,onChange:m,step:f=1,value:g,...x})=>{const v=t.useTheme(),[y,b]=e.useState(g),w=y,j=e=>{b(e),m&&m(e),p&&p()},C=()=>{const e=(null==w||Number.isNaN(w)?0:w)+f;e>l||j(e)},S=()=>{const e=(null==w||Number.isNaN(w)?0:w)-f;e<c||j(e)},k={decimalScale:5,isAllowed:({floatValue:e})=>null==e||e>=c&&e<=l,max:l!==1/0?l:void 0,min:c!==-1/0?c:void 0,step:1!==f?f:void 0,onKeyDown:e=>{"ArrowUp"===e.key?C():"ArrowDown"===e.key&&S()},onValueChange:({floatValue:e})=>{e!==w&&j(e)},value:w,...h};return ge.jsx(nh,{placeholder:s,sx:{height:J[500],"& .MuiOutlinedInput-input":{minWidth:J[300],pl:u?1:2,pr:u?1:2}},...x,value:w??"",disabled:n,InputProps:{...i,inputComponent:Bh,startAdornment:u?ge.jsx(t.InputAdornment,{position:"start",sx:{pl:1},children:u}):null,endAdornment:!a&&ge.jsxs(t.Stack,{gap:v.custom.margin.sm,sx:{height:"100%",alignItems:"center"},direction:"row",children:[d&&ge.jsx(t.InputAdornment,{position:"end",children:d}),ge.jsxs(t.Stack,{sx:{height:"100%",ml:"auto",width:32,borderLeft:`1px solid ${v.custom.palette.stroke.default}`},children:[ge.jsx(t.ButtonBase,{onClick:()=>C(),sx:{flex:1,borderTopRightRadius:v.spacing(v.custom.radius.md),fontSize:12,"&:hover":{background:v.custom.palette.interaction.hover}},children:ge.jsx(o.ArrowDropUp,{fontSize:"inherit"})}),ge.jsx(t.Divider,{}),ge.jsx(t.ButtonBase,{onClick:()=>S(),sx:{flex:1,borderBottomRightRadius:v.spacing(v.custom.radius.md),fontSize:12,"&:hover":{background:v.custom.palette.interaction.hover}},children:ge.jsx(o.ArrowDropDown,{fontSize:"inherit"})})]})]})},inputProps:{inputType:"number",...r,...k}})};const Eh=({options:n,onChange:o,other:i,value:r,internalChange:s,...a})=>{const l=i?.enabled,c="other-option",u=`${c}-value-`,[d,p]=e.useState(r),[h,m]=e.useState(!1),f=e.useRef(null);e.useEffect((()=>{!h&&d?.includes(u)?m(!0):h&&m(!1)}),[d]);return e.useEffect((()=>{f.current&&Array.from(f.current.getElementsByTagName("label")).forEach((e=>{if(e.clientHeight>4*Q){const t=e.querySelector(".MuiTypography-root");t&&(t.style.marginTop=Q/2+"px")}}))}),[f.current]),ge.jsxs(ge.Fragment,{children:[ge.jsxs(t.RadioGroup,{...a,value:d,ref:f,sx:{"& .MuiRadio-root":{alignSelf:"baseline"},"& .MuiTypography-root":{alignSelf:"center"},display:"flex",alignSelf:"baseline",gap:e=>e.custom.margin.sm,label:{"&:last-child":{mb:0},"&:hover":{"& .MuiRadio-root":{backgroundColor:e=>e.custom.palette.interaction.hover,"&.Mui-checked":{backgroundColor:e=>e.custom.palette.purple[500]}}}}},onChange:(e,t)=>{o&&o(t),p(t),s&&s()},children:[n?n.map(((e,t)=>ge.jsx(Jp,{sx:{"& .MuiButtonBase-root.MuiRadio-root":{alignSelf:"baseline"}},...e,control:ge.jsx(ph,{})},t))):null,l&&ge.jsx(Jp,{label:i?.label||"Other",value:u,control:ge.jsx(ph,{checked:d?.includes(u)})},c)]}),h&&ge.jsx(t.Box,{sx:{mt:1},children:ge.jsx(oh,{fullWidth:!0,autoFocus:!0,placeholder:i?.placeholder,defaultValue:d?.replace(u,""),onChange:e=>{var t;o&&o((t=e.target.value,`${u}${t}`)),s&&s()},required:!0})})]})},zh=({handleSelectAll:n,isIndeterminate:o,isAllSelected:i,sizing:r})=>{const[s,a]=e.useState(!1),l=t.useTheme();return e.useEffect((()=>{i&&a(i)}),[i]),ge.jsxs(t.Stack,{direction:"row",gap:l.spacing(l.custom.padding.sm),onClick:e=>{const t=!s;a(t),n(e,t)},sx:{marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",p:e=>e.custom.padding.sm},children:[ge.jsx(t.FormLabel,{sx:{cursor:"pointer",fontSize:()=>r&&Hn[r]},children:"Select all"}),ge.jsx(eh,{sizing:"default",indeterminate:o,checked:s})]})},Ih=e.forwardRef((({children:e,handleSelectAll:t,showSelectAll:n,value:o=[],selections:i,sizing:r,...s},a)=>{const l=Array.isArray(o)&&o.length===i.length,c=Array.isArray(o)&&o.length>0&&o.length<i.length;return ge.jsxs("ul",{ref:a,...s,children:[n&&ge.jsx(zh,{handleSelectAll:t,isIndeterminate:c,isAllSelected:l,sizing:r}),e]})})),Rh="0px 4px 8px 0px #06040D14, 0px 16px 24px 0px #06040D14, 0px 0px 4px 2px #06040D0A, 0px 0px 0px 1px #FFFFFF29",Vh=e=>{switch(e){case"xs":return 24;case"md":return 32;default:return 40}},Fh=(e,t)=>({"& .MuiTypography-root":{height:Vh(t),fontSize:Hn[t],display:"flex",alignItems:"center",paddingLeft:e.spacing("xs"===t?e.custom.padding.xs:e.custom.padding.sm),paddingRight:e.spacing("xs"===t?e.custom.padding.xs:e.custom.padding.sm)}}),Lh=e=>({fontSize:`${On.sm.body.md}`,borderRadius:e.spacing(e.custom.radius.md),position:"relative",padding:e.spacing(e.custom.padding.sm),"& .MuiSelect-outlined":{padding:0},"& .MuiSelect-select.MuiInputBase-input":{paddingRight:e.spacing(te.md)},"&:before":{transition:e.custom.easing.input,content:'""',position:"absolute",background:e.custom.palette.interaction.none,borderRadius:e.spacing(e.custom.radius.md),inset:0,zIndex:0},"&:hover:before":{backgroundColor:e.custom.palette.interaction.hover},"&.Mui-focused:before":{backgroundColor:e.custom.palette.interaction.press},"&.Mui-disabled:before":{backgroundColor:e.custom.palette.interaction.none},"& .MuiSelect-select":{position:"relative"}}),Dh=(e,t)=>{switch(t){case"lg":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.lg,height:Qt.lg,top:`calc(50% - ${Qt.lg/2}px)`}};case"md":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.md,height:Qt.md,top:`calc(50% - ${Qt.md/2}px)`}};case"xs":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.xs,height:Qt.xs,top:`calc(50% - ${Qt.xs/2}px)`}};default:return{height:Vh("lg"),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.lg,height:Qt.lg,top:`calc(50% - ${Qt.lg/2}px)`}}}},Oh=e=>({position:"relative",fontSize:`${On.sm.body.md}`,backgroundColor:e.custom.palette.interaction.none,color:e.custom.palette.text.primary,"&:before":{transition:e.custom.easing.input,content:'""',position:"absolute",inset:0,zIndex:1},"& > .MuiBox-root":{position:"relative",zIndex:2,width:"100%","& .MuiSvgIcon-root":{marginRight:e.spacing(e.custom.margin.sm),width:Qt.xl,height:Qt.xl},"& .MuiBox-root":{padding:e.spacing(e.custom.padding.sm),lineHeight:"22px"}}}),$h=e=>({"&.MuiModal-root.MuiPopover-root":{"&.MuiMenu-root":{borderRadius:e.spacing(e.custom.radius.sm),"& .MuiPaper-root":{border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.raised,boxShadow:Rh}}}}),Hh=t.styled(t.Autocomplete)((({theme:e,sizing:t,value:n})=>({maxWidth:"100%",backgroundColor:e.custom.palette.surface.raised,borderRadius:e.spacing(e.custom.radius.md),border:`1px solid ${e.custom.palette.stroke.default}`,transition:e.custom.easing.input,"& .MuiSvgIcon-root":{...t&&{width:Qt[t],height:Qt[t]}},"&.MuiAutocomplete-root .MuiOutlinedInput-root .MuiAutocomplete-input":{...t&&{height:"xs"===t?2*Q+"px":3*Q+"px"},paddingTop:0,paddingBottom:0,paddingLeft:n&&Array.isArray(n)&&n.length>0?0:e.spacing(e.custom.padding.sm),justifyContent:"center",textOverflow:"ellipsis",whiteSpace:"nowrap"},"& .MuiAutocomplete-inputRoot":{...t&&{fontSize:Hn[t],gap:"lg"===t?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs)},display:"flex",alignItems:"flex-start",paddingRight:3*Q+"px",flexWrap:"wrap",height:"auto"},"& .MuiOutlinedInput-root":{display:"flex",alignItems:"center",padding:"0"},"& .MuiAutocomplete-tag":{...t&&{height:"xs"===t?2*Q+"px":3*Q+"px"},margin:0,"& .MuiSvgIcon-root":{height:"12px",width:"12px"}},"&.Mui-disabled":{backgroundColor:`${e.custom.palette.input.disabled}`,borderColor:`${e.custom.palette.stroke.disabled}`},"&.Mui-focused":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus},"& .MuiChip-root .MuiChip-label":{height:20,lineHeight:"20px",maxWidth:140,...t&&{padding:`0 ${e.spacing(e.custom.padding.xs)}`}}}))),Wh=t.styled(t.Chip)((({theme:e,sizing:t})=>({borderRadius:e.spacing(e.custom.radius.sm),border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.default,...t&&{padding:`0 ${e.spacing(e.custom.padding.xs)}`},"& .MuiChip-deleteIcon":{fill:e.custom.palette.icon.primary,borderRadius:e.custom.radius.round,margin:0,"&:hover":{backgroundColor:e.custom.palette.interaction.hover},"&:active":{backgroundColor:e.custom.palette.interaction.press},"&:disabled":{backgroundColor:e.custom.palette.interaction.disabled,fill:e.custom.palette.icon.disabled}}}))),Nh=t.styled(t.TextField)((({theme:e,sizing:t})=>({"& .MuiOutlinedInput-root":{padding:0,...t&&{margin:"lg"===t?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs)}},"& .MuiInputBase-input":{padding:"0 14px"},"& .MuiOutlinedInput-notchedOutline":{border:"none"}}))),_h=t.styled(t.Popper)((({theme:e,sizing:n})=>({"& .MuiPaper-root":{...n&&{margin:"lg"===n?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs),marginLeft:"lg"===n?`-${e.spacing(e.custom.padding.sm)}`:`-${e.spacing(e.custom.padding.xs)}`,marginTop:`calc(${"lg"===n?e.spacing(e.custom.margin.sm):e.spacing(e.custom.margin.xs)} + ${e.spacing(e.custom.margin.xs)})`},border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.raised,boxShadow:Rh,borderRadius:e.spacing(e.custom.radius.sm)},[`& .${t.autocompleteClasses.listbox}`]:{overflowX:"hidden",[`& .${t.autocompleteClasses.option}`]:{fontSize:Hn[n],...n&&{height:"lg"===n?5*Q+"px":4*Q+"px"},"> span":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},'&[aria-selected="true"]':{backgroundColor:e.custom.palette.interaction.hover,display:"flex",alignItems:"center",justifyContent:"space-between"}}}}))),Uh=e=>ge.jsx(_h,{...e}),Gh=({selections:t,disableClearable:n=!1,disabled:i,internalChange:r,multiple:s=!0,onChange:a,placeholder:l="",renderListItem:c,sizing:u="lg",value:d=(s?[]:"")})=>{const[p,h]=e.useState(t.filter((e=>d.includes(e?.value)))),m=(e,n)=>{if(a){const o=n?t.map((({value:e})=>e)):[];h(n?t:[]),a(e,o,"selectOption"),r&&r()}},f=e=>null!==e&&(!Array.isArray(e)||e.length>0);return ge.jsx(Hh,{disabledItemsFocusable:!0,autoFocus:!1,disableCloseOnSelect:!0,blurOnSelect:!1,popupIcon:ge.jsx(o.KeyboardArrowDown,{}),sizing:u,disabled:i,disableClearable:n,autoComplete:!0,multiple:s,renderInput:e=>ge.jsx(Nh,{...e,placeholder:f(p)?void 0:l,sizing:u}),options:t,renderTags:(e,t)=>e.map(((e,n)=>{const{key:i,...r}=t({index:n});return ge.jsx(Wh,{sizing:u,deleteIcon:ge.jsx(o.CloseRounded,{fontSize:"small"}),label:e.label,...r},i)})),onChange:(e,t,n)=>{const o=Array.isArray(t)?t.map((e=>e.value)):t?.value??null;h(t),a?.(e,o,n),r?.()},PopperComponent:e=>ge.jsx(Uh,{...e,sizing:u}),isOptionEqualToValue:(e,t)=>e.value===t.value,renderOption:(e,t,{selected:n})=>{const{key:i,...r}=e;return ge.jsxs("li",{...r,children:[ge.jsx("span",{children:c?c(t.value,t.label):t.label}),ge.jsx(o.Check,{sx:{visibility:n?"visible":"hidden",fontSize:"16px"}})]},i)},ListboxComponent:e.forwardRef(((e,n)=>ge.jsx(Ih,{ref:n,...e,showSelectAll:s,handleSelectAll:m,value:p,selections:t,sizing:u}))),value:p})},qh=t.styled(t.MenuItem)((({theme:e})=>({...{...Oh(e)},"&.Mui-focusVisible":{backgroundColor:e.custom.palette.interaction.none},"&.Mui-selected":{backgroundColor:e.custom.palette.input.default,"&.Mui-focusVisible":{backgroundColor:e.custom.palette.input.default}},"&.MuiButtonBase-root.MuiMenuItem-root.Mui-disabled":{backgroundColor:e.custom.palette.input.default,color:e.custom.palette.text.disabled,"&:before":{backgroundColor:e.custom.palette.interaction.disabled}},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover},"&.Mui-selected":{backgroundColor:e.custom.palette.input.default,"&.Mui-focusVisible":{"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:before":{backgroundColor:e.custom.palette.interaction.hover}}},"&:active":{"&:before":{backgroundColor:e.custom.palette.interaction.press}}}))),Kh=({children:e,selected:n,...i})=>ge.jsx(qh,{...i,children:ge.jsxs(t.Box,{display:"flex",justifyContent:"space-between",alignItems:"center",children:[ge.jsx(t.Box,{children:e}),n&&ge.jsx(o.Check,{})]})}),Zh=t.styled(t.Select)((({theme:e,sizing:t})=>({...{...Lh(e)},...t&&{...Dh(e,t)},...t&&{...Fh(e,t)},backgroundColor:e.custom.palette.surface.raised,border:`1px solid ${e.custom.palette.stroke.default}`,transition:e.custom.easing.input,"& .MuiOutlinedInput-notchedOutline":{border:e.custom.palette.stroke.default},"&:hover":{"& .MuiOutlinedInput-notchedOutline":{borderColor:e.custom.palette.stroke.default}},"&.Mui-focused":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& .MuiSvgIcon-root":{color:e.custom.palette.icon.disabled,transition:e.custom.easing.input}}}))),Yh=({selections:e,autoComplete:n=!1,disabled:i=!1,disablePortal:r=!1,inputRef:s,internalChange:a,multi:l=!0,onChange:c,placeholder:u="",selectOptionProps:d,sizing:p="lg",sx:h,value:m=[],renderListItem:f,...g})=>{const x=t.useTheme(),v=Wo();return n?ge.jsx(Gh,{selections:e,placeholder:u,disabled:i,sizing:p,onChange:(e,t)=>{c&&c(t||""),a&&a()},value:Array.isArray(m)?m??[]:m??"",internalChange:a,renderListItem:f,multiple:l}):ge.jsxs(Zh,{sizing:p,inputRef:s,MenuProps:{disablePortal:r,sx:$h,anchorOrigin:{vertical:45,horizontal:"center"}},displayEmpty:!0,IconComponent:o.KeyboardArrowDown,renderValue:t=>u&&!t?ge.jsx(dn,{component:"p",variation:"sm"===v||"md"===v?"sm":"lg",sx:{color:x.custom.palette.text.placeholder},children:u}):ge.jsx(dn,{component:"p",variation:"sm"===v||"md"===v?"sm":"lg",children:e?.find((({value:e})=>e===t))?.label}),onChange:(e,t)=>{c&&c(e,t),a&&a()},sx:h,value:m,...g,children:[""!==u.trim()&&ge.jsx(Kh,{disabled:!0,value:"","aria-label":"placeholder",children:u},"placeholder"),e?.map((({value:e,label:t})=>ge.jsx(Kh,{value:e,...d,children:f?f(e,t):t},e)))]})},Xh=t.styled(t.Box)((({theme:e,disabled:t,fullWidth:n})=>({width:n?"100%":"auto",minWidth:240,backgroundColor:t?e.custom.palette.input.disabled:e.custom.palette.surface.raised,border:`1px solid ${t?e.custom.palette.stroke.disabled:e.custom.palette.stroke.default}`,borderRadius:e.spacing(e.custom.radius.lg),padding:e.spacing(e.custom.padding.md),position:"relative",zIndex:0,"&:after":{content:'""',backgroundColor:e.custom.palette.interaction.none,borderRadius:e.spacing(e.custom.radius.lg),position:"absolute",inset:0},"&:hover":{"&:after":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{"&:after":{backgroundColor:e.custom.palette.interaction.press}},"& svg":{fill:e.custom.palette.icon.primary},...t&&{background:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"&:after":{backgroundColor:e.custom.palette.interaction.none},"& .MuiBox-root > .MuiSvgIcon-root":{fill:"none"}}}))),Jh=t.styled(bh)((({theme:e})=>({fontSize:On.button.md,color:e.custom.palette.text.primary,lineHeight:"120%",letterSpacing:"0.16px"}))),Qh=({label:e="Placeholder",disabled:n,onChange:i,options:r,fullWidth:s})=>{const a=t.useTheme(),l=r.map((e=>e.label)).indexOf(e);return ge.jsx(Xh,{disabled:n,fullWidth:s,children:ge.jsxs(t.Stack,{display:"flex",justifyContent:"space-between",flexDirection:"row",alignItems:"center",sx:{position:"relative",zIndex:1},children:[ge.jsxs(t.Box,{display:"flex",alignItems:"center",sx:{"& svg":{fill:a.custom.palette.icon.secondary}},children:[ge.jsx(o.DragHandle,{sx:{width:Qt.lg,height:Qt.lg,mr:a.custom.padding.sm}}),ge.jsx(Jh,{align:"left",disabled:n,children:e})]}),ge.jsx(Yh,{name:"rank",sizing:"xs",selections:r.map(((e,t)=>({label:`${t+1}`,value:`${t}`}))),disabled:n,value:`${l}`,onChange:function(e){const t=l,n=Number(e.target.value),o=r;let s=1;const a=o.splice(t,s)[0];s=0,o.splice(n,s,a),i(o)},MenuProps:{anchorOrigin:{vertical:J[400],horizontal:"center"}}})]})})},em=e.createContext({attributes:{},listeners:void 0,ref(){}}),tm=e=>p.defaultAnimateLayoutChanges({...e,wasDragging:!0});function nm({children:n,top:o,bottom:i,id:r}){const{attributes:s,isDragging:a,listeners:l,setNodeRef:c,setActivatorNodeRef:u,transform:d,transition:m}=p.useSortable({id:r,animateLayoutChanges:tm}),f=e.useMemo((()=>({attributes:s,listeners:l,ref:u})),[s,l,u]),g={opacity:a?.4:void 0,transform:h.CSS.Translate.toString(d),transition:m};return ge.jsx(em.Provider,{value:f,children:ge.jsxs(t.Stack,{className:"SortableItem",...s,sx:{position:"relative",...g,width:"100%"},ref:c,children:[o&&o,ge.jsx(t.Box,{...l,sx:{display:"flex",cursor:"grab"},children:n}),i&&i]})})}const om={sideEffects:d.defaultDropAnimationSideEffects({styles:{active:{opacity:"0.4"}}})};function im({children:e}){return m.createPortal(ge.jsx(d.DragOverlay,{zIndex:999999,dropAnimation:om,children:e}),document.body)}const rm=({nativeEvent:e})=>{let t=e.target;for(;t;){if(t.dataset.noDnd)return!1;t=t.parentElement}return!0};class sm extends d.MouseSensor{static activators=[{eventName:"onMouseDown",handler:rm}]}class am extends d.TouchSensor{static activators=[{eventName:"onTouchStart",handler:rm}]}function lm({items:n,onChange:o,renderItem:i,disabled:r,direction:s}){if(!n)return;const[a,l]=e.useState(null),c=e.useMemo((()=>n.find((e=>e?.id===a?.id))),[a,n]),u=t.useTheme(),h=t.useMediaQuery(u.breakpoints.down("md")),m=d.useSensors(d.useSensor(sm,{activationConstraint:{distance:5}}),d.useSensor(am,{activationConstraint:{delay:h?300:0,tolerance:8}}),d.useSensor(d.KeyboardSensor,{coordinateGetter:p.sortableKeyboardCoordinates}));return ge.jsxs(d.DndContext,{measuring:{droppable:{strategy:d.MeasuringStrategy.Always}},sensors:m,onDragStart:({active:e})=>{l(e)},onDragEnd:({active:e,over:t})=>{if(t&&e.id!==t?.id){const i=n.findIndex((({id:t})=>t===e.id)),r=n.findIndex((({id:e})=>e===t.id));o(p.arrayMove(n,i,r))}l(null)},onDragCancel:()=>{l(null)},children:[ge.jsx(p.SortableContext,{items:n,disabled:r,strategy:"horizontal"===s?p.horizontalListSortingStrategy:p.verticalListSortingStrategy,children:ge.jsx(t.Stack,{sx:{..."horizontal"===s&&{flexDirection:"row"},display:"flex",m:0,gap:1,padding:0,alignContent:"flex-start"},children:n.map((t=>ge.jsx(e.Fragment,{children:i(t)},t.id)))})}),ge.jsx(im,{children:c?i(c,!0,!!a):null})]})}lm.Item=nm,lm.DragHandle=function(){const{attributes:n,listeners:o,ref:i}=e.useContext(em);return ge.jsx(t.Box,{...n,...o,ref:i,children:ge.jsx("svg",{viewBox:"0 0 20 20",width:"12",children:ge.jsx("path",{d:"M7 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 2zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 14zm6-8a2 2 0 1 0-.001-4.001A2 2 0 0 0 13 6zm0 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 14z"})})})};const cm=({labelTop:n,labelBottom:o,disabled:i,fullWidth:r=!1,options:s,onChange:a,value:l,internalChange:c})=>{const u=t.useTheme(),[d,p]=e.useState(l||s);function h(e){p(e),a(e.map((({id:e})=>e))),c&&c()}return ge.jsxs(t.Stack,{gap:u.custom.margin.sm,textAlign:"center",sx:{width:r?"100%":"auto"},children:[n&&ge.jsx(bh,{disabled:i,sx:{color:u.custom.palette.text.secondary},children:n}),ge.jsx(lm,{onChange:function(e){p(e),a(e.map((({id:e})=>e))),c&&c()},items:d,direction:"vertical",renderItem:({...e})=>ge.jsx(nm,{id:e.id,children:ge.jsx(Qh,{onChange:h,...e,options:d,disabled:i,selections:e.selections,fullWidth:r})})}),o&&ge.jsx(bh,{disabled:i,sx:{color:u.custom.palette.text.secondary},children:o})]})},um=t.styled(x.RichTextEditor)((({theme:e})=>({"&.MuiTiptap-FieldContainer-root":{backgroundColor:e.custom.palette.input.default,"&:hover":{".MuiTiptap-FieldContainer-notchedOutline":{borderSize:1,backgroundColor:e.custom.palette.interaction.hover,borderColor:e.custom.palette.stroke.default}}},"&.MuiTiptap-FieldContainer-focused":{".MuiTiptap-FieldContainer-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.focus}!important`,boxShadow:e.custom.boxShadow.input.focus}},".MuiTiptap-RichTextField-menuBar":{padding:0,borderRadius:e.spacing(e.custom.radius.md),background:e.custom.palette.surface.default,margin:e.spacing(e.custom.margin.sm),border:`1px solid ${e.custom.palette.stroke.default}`,marginBottom:0,".MuiTiptap-RichTextField-content":{padding:e.spacing(e.custom.padding.xs)}}}))),dm=({onChange:n,value:o,internalChange:i,minWidth:r=100,minHeight:s=100,maxHeight:a,placeholder:l})=>{const c=e.useRef(null),u=t.useTheme();return ge.jsx(um,{sx:{"& .ProseMirror":{overflowY:"auto",minHeight:s,minWidth:r,maxHeight:a}},ref:c,onUpdate:({editor:e})=>{n&&n(e.getHTML()),i&&i()},extensions:[g.StarterKit.configure({strike:!1,code:!1,heading:!1,listItem:!1,bulletList:!1,orderedList:!1,blockquote:!1,horizontalRule:!1,codeBlock:!1}),f.Placeholder.configure({placeholder:l}),v.Markdown],content:o,renderControls:()=>ge.jsxs(t.Stack,{gap:u.custom.margin.xs,direction:"row",children:[ge.jsx(x.MenuButtonBold,{}),ge.jsx(x.MenuButtonItalic,{})]})})},pm=e=>({"& .MuiSlider-thumb":{width:J[300],height:J[300],backgroundColor:e.custom.palette.text.primary,boxShadow:e.custom.boxShadow.input.handle,"&:after":{content:'""',position:"absolute",top:"50%",left:"50%",width:J[50],height:J[50],backgroundColor:e.custom.palette.icon.primaryInverted}}}),hm=e=>Array.isArray(e),mm=(e,t)=>({height:J[100],padding:`${J[100]}px 0`,"& .MuiSlider-rail":{width:`calc(100% + ${J[400]}px)`,left:`-${J[200]}px`,backgroundColor:e.custom.palette.icon.disabled,opacity:1},"& .MuiSlider-track":{position:"relative",border:"none",backgroundColor:e.custom.palette.purple[500],"&:before":{content:'""',position:"absolute",top:0,left:t&&hm(t)?`-${J[100]+1}px`:`-${J[200]+1}px`,width:`calc(100% + ${J[200]}px)`,height:"100%",borderRadius:"inherit",backgroundColor:"inherit"}},"& .MuiSlider-mark":{height:J[50],width:J[50],borderRadius:e.custom.radius.round,backgroundColor:e.custom.palette.text.primaryInverted,"&.MuiSlider-markActive":{backgroundColor:e.custom.palette.text.primaryInverted}}}),fm=e=>({"& .MuiSlider-valueLabel":{backgroundColor:e.custom.palette.purple[500],borderRadius:e.spacing(e.custom.radius.sm),padding:J[50],minWidth:J[400],"&.MuiSlider-valueLabelOpen":{top:"-9px"},"& .MuiSlider-valueLabelLabel":{padding:`0 ${e.spacing(e.custom.padding.xs)}`,fontSize:`${On.lg.body.sm}`,color:e.custom.palette.text.lockedWhite,fontWeight:500,lineHeight:"140%"}}}),gm=t.styled(t.Slider)((({theme:e,value:t,hideMarkLabels:n,hideMarks:o})=>({"&.MuiSlider-root":{width:`calc(100% - ${J[400]}px)`,marginLeft:J[400]/2,...{...mm(e,t)},...{...pm(e)},...{...fm(e)},"&.Mui-disabled":{"& .MuiSlider-rail, & .MuiSlider-track":{backgroundColor:e.custom.palette.icon.secondary},"& .MuiSlider-rail":{backgroundColor:e.custom.palette.icon.disabled},"& .MuiSlider-thumb":{backgroundColor:e.custom.palette.icon.disabled,"& .MuiSlider-valueLabel":{backgroundColor:e.custom.palette.icon.disabled}}},...n&&{".MuiSlider-markLabel":{visibility:"hidden"},".MuiSlider-markLabel:nth-of-type(4), .MuiSlider-markLabel:nth-last-of-type(2)":{visibility:"visible"}},".MuiSlider-mark":{color:e.custom.palette.text.secondary,...o&&{visibility:"hidden"},"&.MuiSlider-markLabelActive":{color:e.custom.palette.text.secondary}}}}))),xm=(e,t)=>{if(!e)return!1;const n=e.querySelectorAll(t);if(n.length<2)return!1;const o=Array.from(n).map((e=>e.getBoundingClientRect()));let i=!1;for(let e=0;e<o.length-1;e++)if(o[e].right+5>o[e+1].left){i=!0;break}return i},vm=({labelLeft:n,labelMiddle:o,labelRight:i,labelRightProps:r,labelLeftProps:s,disabled:a,onChange:l,internalChange:c,max:u=5,min:d=1,marks:p,marksStep:h=1,step:m=1,value:f=d,...g})=>{const{sanitisedMin:x,sanitisedMax:v}=((e,t)=>e>=t?{sanitisedMin:1,sanitisedMax:10}:{sanitisedMin:e,sanitisedMax:t})(d,u),y=e.useRef(null),b=p||((e,t,n)=>{const o=[];for(let i=e;i<=t;i++)i%n==0&&o.push({value:i,label:i.toString()});return o})(x,v,h),[w,j]=e.useState(!1),[C,S]=e.useState(!1),k=()=>{j(xm(y.current,".MuiSlider-markLabel")),S(xm(y.current,".MuiSlider-mark"))};return e.useEffect((()=>{k()}),[b?.length]),e.useEffect((()=>{const e=new ResizeObserver(k);return y.current&&e.observe(y.current),()=>{e.disconnect()}}),[]),ge.jsxs(t.Box,{sx:{minWidth:300},children:[ge.jsx(t.Box,{height:24,children:ge.jsx(gm,{ref:y,valueLabelDisplay:a?"on":"auto",disabled:a,marks:b,step:m,hideMarkLabels:w,hideMarks:C,max:v,min:x,onChangeCommitted:()=>{c&&c()},onChange:(e,t,n)=>{l&&l(e,t,n)},value:f,...g})}),ge.jsx(t.Box,{sx:{display:"flex",justifyContent:"space-between",pt:te.lg,gap:1},children:(n||o||i)&&ge.jsxs(ge.Fragment,{children:[ge.jsx(t.Box,{sx:{flex:1},children:ge.jsx(lh,{disabled:a,showicon:!1,...s,children:n})}),o&&ge.jsx(t.Box,{sx:{flex:1,textAlign:"center"},children:ge.jsx(lh,{showicon:!1,disabled:a,children:o})}),ge.jsx(t.Box,{sx:{flex:1,textAlign:"right"},children:ge.jsx(lh,{...r,showicon:!1,disabled:a,children:i})})]})})]})},ym=t.styled(t.Rating)((({theme:e})=>({"&.MuiRating-root":{"& .MuiRating-iconEmpty":{color:e.custom.palette.icon.secondary},"& .MuiRating-iconFilled":{color:e.custom.palette.yellow[600]},".MuiRating-iconHover":{fontSize:"inherit",transform:"none"},"&.Mui-disabled":{opacity:1,color:e.custom.palette.icon.disabled,"& .MuiRating-iconEmpty":{color:e.custom.palette.icon.disabled},"& .MuiRating-iconFilled":{color:e.custom.palette.icon.disabled}}}}))),bm=({internalChange:e,onChange:n,...o})=>ge.jsx(ym,{...o,onChange:(t,o)=>{n&&n(t,o),e&&e()},icon:ge.jsx(t.SvgIcon,{sx:{width:48,height:48},viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{d:"M24.114 35.395L32.414 40.415C33.934 41.335 35.794 39.975 35.394 38.255L33.194 28.815L40.534 22.455C41.874 21.295 41.154 19.095 39.394 18.955L29.734 18.135L25.954 9.21499C25.274 7.59499 22.954 7.59499 22.274 9.21499L18.494 18.115L8.83396 18.935C7.07396 19.075 6.35396 21.275 7.69396 22.435L15.034 28.795L12.834 38.235C12.434 39.955 14.294 41.315 15.814 40.395L24.114 35.395Z"})}),emptyIcon:ge.jsx(t.SvgIcon,{sx:{width:48,height:48},viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M39.1047 20.58L30.8559 27.7274L33.3274 38.3549L23.9992 32.713L14.6668 38.335L17.1388 27.7279L8.89132 20.5816L19.748 19.66L23.9966 9.63416L28.2463 19.6377L39.1047 20.58ZM12.7171 37.8892L14.9171 28.4492L7.57709 22.0892C6.23709 20.9292 6.95709 18.7292 8.71709 18.5892L18.3771 17.7692L22.1571 8.84916C22.8371 7.22916 25.1571 7.22916 25.8371 8.84916L29.6171 17.7492L39.2971 18.5892C41.0571 18.7292 41.7571 20.9292 40.4171 22.0892L33.0771 28.4492L35.2771 37.9092C35.6771 39.6292 33.8171 40.9892 32.2971 40.0692L23.9971 35.0492L15.6971 40.0492C14.1771 40.9692 12.3171 39.6092 12.7171 37.8892Z"})})}),wm=t.styled((e=>ge.jsx(t.Switch,{focusVisibleClassName:".Mui-focusVisible",disableRipple:!0,...e})))((({theme:e,sizing:t})=>({width:"lg"===t?54:36,height:"lg"===t?30:20,padding:0,"& .MuiSwitch-switchBase":{padding:0,margin:"lg"===t?3:2,transitionDuration:"300ms","&.Mui-checked":{transform:`translateX(${"lg"===t?24:16}px)`,color:"#fff","& + .MuiSwitch-track":{backgroundColor:e.custom.palette.green[500],opacity:1,border:0},"&.Mui-disabled + .MuiSwitch-track":{opacity:.5}},"&.Mui-focusVisible .MuiSwitch-thumb":{color:"#33cf4d",border:"6px solid #fff"},"&.Mui-disabled .MuiSwitch-thumb":{color:e.custom.palette.neutral[100]},"&.Mui-disabled + .MuiSwitch-track":{opacity:"light"===e.palette.mode?.7:.3}},"& .MuiSwitch-thumb":{width:"lg"===t?24:16,height:"lg"===t?24:16,boxSizing:"border-box",boxShadow:"none",backdropFilter:"blur(0)",filter:"drop-shadow(0 0 0 rgba(255, 255, 255, 0.52))",outline:("lg"===t?2:1)+"px solid rgba(255, 255, 255, 0.12)"},"& .MuiSwitch-track":{borderRadius:("lg"===t?30:20)/2,backgroundColor:e.custom.palette.neutral[100],opacity:1,transition:e.transitions.create(["background-color"],{duration:500})}}))),jm=({sizing:e="sm",sx:t,inputRef:o,value:i,label:r,labelPlacement:s="start",fullWidth:a,onChange:l,internalChange:c,...u})=>ge.jsx(Jp,{inputRef:o,checked:i,label:r,labelPlacement:s,control:ge.jsx(wm,{sizing:e}),onChange:(e,t)=>{l&&l(e,t),c&&c()},sx:n.mergeSx(a?{"& .MuiFormControlLabel-label":{width:"100%"}}:{},t),...u}),Cm=t.styled(nh)((({theme:e})=>({"& .MuiInputBase-root":{paddingTop:0,paddingBottom:0,minHeight:J[500],alignItems:"baseline","& .MuiInputBase-input":{},"& .MuiInputAdornment-root.MuiInputAdornment-positionStart":{alignSelf:"self-end",height:Qt.xl,marginTop:e.spacing(1),marginBottom:e.spacing(1),"&:first-of-type":{alignSelf:"self-start"}}}}))),Sm=({startAdornment:e,endAdornment:n,onChange:o,internalChange:i,inputRef:r,...s})=>ge.jsx(Cm,{multiline:!0,inputRef:r,InputProps:{startAdornment:e?ge.jsx(t.InputAdornment,{position:"start",children:e}):null,endAdornment:n?ge.jsx(t.InputAdornment,{position:"start",children:n}):null},...s,onChange:e=>{o&&o(e),i&&i()}}),km=(e,t)=>{switch(e){case 1:return t.custom.palette.red[500];case 2:return t.custom.palette.yellow[500];case 3:case 4:return t.custom.palette.green[500];default:return t.custom.palette.icon.disabled}},Mm=(e,t)=>{switch(e){case 1:return t.custom.palette.text.negative;case 2:return t.custom.palette.yellow[800];case 3:return t.custom.palette.green[800];case 4:return t.custom.palette.text.positive;default:return t.custom.palette.icon.disabled}},Tm=t.styled(t.LinearProgress)((({theme:e,score:n})=>({boxShadow:"unset",background:e.custom.palette.neutral[100],borderRadius:e.spacing(e.custom.radius.sm),[`.${t.linearProgressClasses.bar}`]:{borderRadius:e.spacing(e.custom.radius.sm),backgroundColor:km(n,e)}}))),Pm={translations:z.translations,graphs:E.adjacencyGraphs,dictionary:{...E.dictionary,...z.dictionary}};y.zxcvbnOptions.setOptions(Pm);const Bm=({label:n="Strength",width:o=60,value:i,onChange:r})=>{const[s,a]=e.useState(0),l=t.useTheme();return e.useEffect((()=>{a(y.zxcvbn(i).score)}),[i]),e.useEffect((()=>{r(s)}),[s]),ge.jsxs(t.Stack,{direction:"row",gap:1,sx:{alignItems:"center"},children:[ge.jsx(dn,{variation:"sm",component:"p",children:n}),ge.jsx(Tm,{variant:"determinate",value:0===s?6.6:25*s,score:s,sx:{width:o}}),ge.jsx(dn,{variation:"sm",component:"p",sx:{color:Mm(s,l)},children:["","Very weak","Weak","Strong","Excellent"][s]})]})},Am=({helperText:e,inputName:t,errors:n,...o})=>{const i=Boolean(n&&n[t]);return i?ge.jsx(j.ErrorMessage,{errors:n,name:t,render:({message:e})=>ge.jsx(lh,{showicon:!!e,state:"negative",children:e})}):e&&!i?ge.jsx(lh,{state:"default",...o,children:e}):null},Em={textfield:oh,numberfield:Ah,textarea:Sm,select:Yh,checkbox:th,checkboxGroup:ih,switch:jm,slider:vm,starRating:bm,differential:gh,likert:Ph,radioGroup:Eh,ranking:cm,richTextfield:dm,customfield:rh},zm=({name:o,fieldType:i,label:r,control:s,errors:a,labelProps:u,helperText:d,helpTextProps:p,validation:h,content:m,styleOverrides:f,defaultValue:g,onChange:x,watch:v,trigger:y,strengthIndicator:b,...w})=>{const{custom:j}=t.useTheme(),C=void 0!==a&&Object.keys(a).length>0,[S,k]=e.useState(0);return b&&e.useEffect((()=>{S>0&&y(o)}),[S]),h?.match?.field&&e.useEffect((()=>{h?.match?.field&&y(h?.match?.field)}),[v(o)]),ge.jsxs(t.Stack,{sx:n.mergeSx(f?.sxInputStack,w?.hidden&&{display:"none!important"}),gap:j.margin.sm,children:["switch"!==i?r&&ge.jsx(bh,{...u,children:r}):null,"html"===i&&m?ge.jsx(yh,{children:m}):ge.jsxs(ge.Fragment,{children:[ge.jsx(l.Controller,{name:o,control:s,render:e=>function({field:{ref:e,...t}}){const n=Em[i];return ge.jsx(n,{...w,...t,inputRef:e,..."switch"===i?{label:r}:{}})}(e),rules:{...h,validate:e=>{if(h&&"phone"in h)return c.isValidPhoneNumber(`+${v("extension")}${e}`)||h.phone.message;if(h&&"score"in h)return S<=h.score.value?h.score.message:void 0;if(h&&"white_space"in h)return!e.match(/^\s*$/g)||h.white_space.message;if(h&&"match"in h&&h?.match?.field)switch(h?.match?.comparison){case"not_eq":return e!=v(h.match.field)||h.match.message;case"gt":return e>v(h.match.field)||h.match.message;case"lt":return e<v(h.match.field)||h.match.message;default:return e===v(h.match.field)||h.match.message}}}}),b&&"password"===w?.type&&ge.jsx(Bm,{value:v(o),onChange:k})]}),ge.jsxs(ge.Fragment,{children:[Boolean(C)?ge.jsx(Am,{helperText:void 0,inputName:o,errors:a,showicon:!0}):null,Boolean(d)?ge.jsx(Am,{helperText:d,inputName:o,errors:void 0,...p}):null]})]})},Im=e=>e.reduce(((e,t)=>({...e,[t?.name]:Rm(t,t?.defaultValue)})),{}),Rm=(e,t)=>{switch(e.fieldType){case"select":return Array.isArray(t),t;case"starRating":case"numberfield":return t||0;case"slider":{const{min:n}=e;return Array.isArray(t)?t:t||n}case"likert":case"radioGroup":case"customfield":default:return t||"";case"checkboxGroup":return t||[];case"checkbox":case"switch":return t||!1;case"ranking":{const{options:n}=e;return t?t.map((e=>n.find((({id:t})=>t===e)))):n}}},Vm=e.forwardRef((({submitButton:n,secondaryButton:o,onFormSubmit:i,onFormChange:r,formConfig:s},a)=>{const{custom:c}=t.useTheme(),{fields:u,reValidateMode:d,styleOverrides:p,autoComplete:h,formId:m,mode:f}=s,g=vh(u),{reset:x,getValues:v,trigger:y,setValue:b,control:w,formState:{isValid:j,errors:C},setFocus:S,handleSubmit:k,watch:M}=l.useForm({mode:f||"onChange",reValidateMode:d,defaultValues:e.useMemo((()=>Im(u)),[]),shouldUnregister:!0});e.useEffect((()=>{if(void 0!==g){const e=g.filter((({fieldType:e})=>"html"!==e)).map((({name:e})=>e));u.filter((({name:t,fieldType:n})=>!e.includes(t)&&"html"!==n)).forEach((e=>{b(e.name,Rm(e,e.defaultValue))}))}}),[u]),e.useEffect((()=>{x(Im(u))}),[m]),e.useImperativeHandle(a,(()=>({set(e,t){b(e,t)},resetForm(){x()},focus(e){S(e)},submit(){i&&k(i)()},values:()=>v(),valid:()=>j,errors:()=>C,async triggerFormValidation(){await y()}})));const T=()=>{r&&r(v())};return ge.jsxs(t.Box,{component:"form",autoComplete:h,noValidate:!0,sx:p?.sxForm,...i&&{onSubmit:k(i)},children:[ge.jsx(t.Stack,{gap:c.margin.md,sx:p?.sxStack,children:u.map((({name:t,...n})=>e.createElement(zm,{...r&&{internalChange:T},name:t,key:t,errors:C,control:w,watch:M,trigger:y,...n})))}),(o||n)&&ge.jsxs(t.Stack,{direction:"row",sx:p?.sxButtons||{mt:c.margin.lg,gap:c.margin.sm,justifyContent:"flex-end"},children:[o&&o,n&&n]})]})})),Fm=t.styled(t.Box)((({theme:e})=>({alignItems:"center",display:"flex",flexDirection:"column",height:"100%",left:0,pointerEvents:"none",position:"fixed",top:0,width:"100%",zIndex:e.zIndex.tooltip}))),Lm=t.styled(t.Container)((({theme:e})=>({background:e.custom.palette.red[300],display:"flex",flex:1,opacity:.2,position:"relative"}))),Dm=t.styled(t.Box)((({theme:e})=>({background:e.custom.palette.purple[300],display:"flex",flex:1}))),Om=t.styled(t.Box)((({theme:e})=>({background:e.custom.palette.green[300],height:"100%"}))),$m=t.styled(t.Box)((({theme:e})=>({backgroundColor:e.custom.palette.surface.default,borderRadius:e.spacing(e.custom.radius.md),bottom:16,boxShadow:e.custom.elevation.overlay,display:"block",left:16,padding:e.spacing(1,2),position:"fixed"}))),Hm=e=>({"&:first-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderBottomLeftRadius:0,borderBottomRightRadius:0},"&:last-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopRightRadius:0,borderTopLeftRadius:0}}),Wm=e=>({"&:first-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopRightRadius:0,borderBottomRightRadius:0},"&:last-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopLeftRadius:0,borderBottomLeftRadius:0}}),Nm=t.styled(t.ButtonGroup)((({theme:e,variation:t,orientation:n="horizontal",iconColor:o,sizing:i="lg",groupRaised:r=!1})=>({"&.MuiButtonGroup-root":{backgroundColor:e.custom.palette.input.default,border:`1px solid ${e.custom.palette.stroke.default}`,...r&&{boxShadow:e.custom.elevation.raised,border:"none"},"& > button":{borderRadius:0,..."default"===t&&{...bn(e)},..."toggle"===t&&{...wn(e)},..."vertical"===n&&{...Hm(e)},..."horizontal"===n&&{...Wm(e)},...i&&{...Mn(i)}},"& .MuiSvgIcon-root":{...i&&{...Pn(i)},fill:o||"inherit"}}}))),_m=t.styled(t.Box)({"& .lazy-load-image-background.blur":{filter:"blur(15px)"},"& .lazy-load-image-background.blur.lazy-load-image-loaded":{filter:"blur(0)",transition:"filter .3s"},"& .lazy-load-image-background.blur > img":{opacity:"0"},"& .lazy-load-image-background.blur.lazy-load-image-loaded > img":{opacity:"1",transition:"opacity .3s"}}),Um=({children:n,src:o,alt:i,width:r,height:s,...a})=>{const[l,c]=e.useState(!1);return ge.jsxs(ge.Fragment,{children:[ge.jsx(t.Fade,{in:!l,unmountOnExit:!0,children:ge.jsx(t.Box,{sx:{width:r,height:s,position:"absolute",inset:0},children:ge.jsx(t.Skeleton,{variant:"rectangular",width:r,height:"100%"})})}),ge.jsx(_m,{children:ge.jsx(C.LazyLoadImage,{onLoad:()=>c(!0),alt:i,height:s,src:o,width:r,threshold:500,effect:"blur",wrapperProps:{style:{transitionDelay:"200ms"}},...a})})]})},Gm=t.styled(Tp)((({theme:e})=>({background:`linear-gradient(-18deg, ${e.custom.palette.purple[600]} 0%, ${e.custom.palette.blue[400]} 100%)`,color:e.custom.palette.white,padding:e.spacing(1),minWidth:0}))),qm={variation:"lg",component:"p",sx:{margin:0,"& > *":{display:"inline"}}},Km=t.styled("div")((()=>({whiteSpace:"pre"}))),Zm=(e,t)=>"light"===t?{fontWeight:400}:{fontWeight:500,textTransform:"uppercase"},Ym=(e,t,n)=>{switch(t){case"peach":return{background:e.custom.palette.peach[100],color:"heavy"===n?e.custom.palette.peach[1e3]:e.custom.palette.peach[800]};case"peachDark":return{background:e.custom.palette.peach[800],color:e.custom.palette.peach[0]};case"purple":return{background:e.custom.palette.purple[100],color:"heavy"===n?e.custom.palette.purple[1e3]:e.custom.palette.purple[800]};default:return{background:e.custom.palette.neutral[100],color:"heavy"===n?e.custom.palette.neutral[1e3]:e.custom.palette.neutral[800]}}},Xm=t.styled(t.Chip)((({theme:e,variation:t,weight:n})=>({borderRadius:e.spacing(e.custom.radius.md),height:28,...Ym(e,t,n),"& .MuiChip-label":{fontSize:`${On.sm.body.sm}`,padding:`0 ${e.spacing(e.custom.padding.sm)}`,...Zm(0,n)},"& .MuiChip-icon":{width:"0.8em",height:"0.8em",marginRight:-4,...Ym(e,t,n),...Zm(0,n)}})));var Jm=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(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]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)})),this.tags=[],this.ctr=0},e}();var Qm="undefined"!=typeof document,ef=function(e,t,n){for(var o=0,i=0;o=i,i=k.peek(),38===o&&12===i&&(t[n]=1),!k.token(i);)k.next();return k.slice(e,k.position)},tf=function(e,t){return k.dealloc(function(e,t){var n=-1,o=44;do{switch(k.token(o)){case 0:38===o&&12===k.peek()&&(t[n]=1),e[n]+=ef(k.position-1,t,n);break;case 2:e[n]+=k.delimit(o);break;case 4:if(44===o){e[++n]=58===k.peek()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=k.from(o)}}while(o=k.next());return e}(k.alloc(e),t))},nf=new WeakMap,of=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,o=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||nf.get(n))&&!o){nf.set(e,!0);for(var i=[],r=tf(t,i),s=n.props,a=0,l=0;a<r.length;a++)for(var c=0;c<s.length;c++,l++)e.props[l]=i[a]?r[a].replace(/&\f/g,s[c]):s[c]+" "+r[a]}}},rf=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function sf(e,t){switch(k.hash(e,t)){case 5103:return k.WEBKIT+"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 k.WEBKIT+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return k.WEBKIT+e+k.MOZ+e+k.MS+e+e;case 6828:case 4268:return k.WEBKIT+e+k.MS+e+e;case 6165:return k.WEBKIT+e+k.MS+"flex-"+e+e;case 5187:return k.WEBKIT+e+k.replace(e,/(\w+).+(:[^]+)/,k.WEBKIT+"box-$1$2"+k.MS+"flex-$1$2")+e;case 5443:return k.WEBKIT+e+k.MS+"flex-item-"+k.replace(e,/flex-|-self/,"")+e;case 4675:return k.WEBKIT+e+k.MS+"flex-line-pack"+k.replace(e,/align-content|flex-|-self/,"")+e;case 5548:return k.WEBKIT+e+k.MS+k.replace(e,"shrink","negative")+e;case 5292:return k.WEBKIT+e+k.MS+k.replace(e,"basis","preferred-size")+e;case 6060:return k.WEBKIT+"box-"+k.replace(e,"-grow","")+k.WEBKIT+e+k.MS+k.replace(e,"grow","positive")+e;case 4554:return k.WEBKIT+k.replace(e,/([^-])(transform)/g,"$1"+k.WEBKIT+"$2")+e;case 6187:return k.replace(k.replace(k.replace(e,/(zoom-|grab)/,k.WEBKIT+"$1"),/(image-set)/,k.WEBKIT+"$1"),e,"")+e;case 5495:case 3959:return k.replace(e,/(image-set\([^]*)/,k.WEBKIT+"$1$`$1");case 4968:return k.replace(k.replace(e,/(.+:)(flex-)?(.*)/,k.WEBKIT+"box-pack:$3"+k.MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+k.WEBKIT+e+e;case 4095:case 3583:case 4068:case 2532:return k.replace(e,/(.+)-inline(.+)/,k.WEBKIT+"$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(k.strlen(e)-1-t>6)switch(k.charat(e,t+1)){case 109:if(45!==k.charat(e,t+4))break;case 102:return k.replace(e,/(.+:)(.+)-([^]+)/,"$1"+k.WEBKIT+"$2-$3$1"+k.MOZ+(108==k.charat(e,t+3)?"$3":"$2-$3"))+e;case 115:return~k.indexof(e,"stretch")?sf(k.replace(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==k.charat(e,t+1))break;case 6444:switch(k.charat(e,k.strlen(e)-3-(~k.indexof(e,"!important")&&10))){case 107:return k.replace(e,":",":"+k.WEBKIT)+e;case 101:return k.replace(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+k.WEBKIT+(45===k.charat(e,14)?"inline-":"")+"box$3$1"+k.WEBKIT+"$2$3$1"+k.MS+"$2box$3")+e}break;case 5936:switch(k.charat(e,t+11)){case 114:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return k.WEBKIT+e+k.MS+e+e}return e}var af,lf,cf=Qm?void 0:(af=function(){return e=function(){return{}},t=Object.create(null),function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]};var e,t},lf=new WeakMap,function(e){if(lf.has(e))return lf.get(e);var t=af(e);return lf.set(e,t),t}),uf=[function(e,t,n,o){if(e.length>-1&&!e.return)switch(e.type){case k.DECLARATION:e.return=sf(e.value,e.length);break;case k.KEYFRAMES:return k.serialize([k.copy(e,{value:k.replace(e.value,"@","@"+k.WEBKIT)})],o);case k.RULESET:if(e.length)return k.combine(e.props,(function(t){switch(k.match(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return k.serialize([k.copy(e,{props:[k.replace(t,/:(read-\w+)/,":"+k.MOZ+"$1")]})],o);case"::placeholder":return k.serialize([k.copy(e,{props:[k.replace(t,/:(plac\w+)/,":"+k.WEBKIT+"input-$1")]}),k.copy(e,{props:[k.replace(t,/:(plac\w+)/,":"+k.MOZ+"$1")]}),k.copy(e,{props:[k.replace(t,/:(plac\w+)/,k.MS+"input-$1")]})],o)}return""}))}}],df=function(e){var t=e.key;if(Qm&&"css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var o,i,r=e.stylisPlugins||uf,s={},a=[];Qm&&(o=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)s[t[n]]=!0;a.push(e)})));var l=[of,rf];if(cf){var c=[k.stringify],u=k.middleware(l.concat(r,c)),d=cf(r)(t),p=function(e,t){var n=t.name;return void 0===d[n]&&(d[n]=function(e){return k.serialize(k.compile(e),u)}(e?e+"{"+t.styles+"}":t.styles)),d[n]};i=function(e,t,n,o){var i=t.name,r=p(e,t);return void 0===g.compat?(o&&(g.inserted[i]=!0),r):o?void(g.inserted[i]=r):r}}else{var h,m=[k.stringify,k.rulesheet((function(e){h.insert(e)}))],f=k.middleware(l.concat(r,m));i=function(e,t,n,o){h=n,function(e){k.serialize(k.compile(e),f)}(e?e+"{"+t.styles+"}":t.styles),o&&(g.inserted[t.name]=!0)}}var g={key:t,sheet:new Jm({key:t,container:o,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:s,registered:{},insert:i};return g.sheet.hydrate(a),g};const pf=t.styled("iframe")((()=>({border:"none",height:"100%",width:"100%"}))),hf=({status:e})=>{const n=t.useTheme();switch(e){case"neutral":return null;case"success":return ge.jsx(mf,{backgroundColor:n.custom.palette.green[500],name:"check-circle"});case"warning":return ge.jsx(mf,{backgroundColor:n.custom.palette.yellow[500],name:"error"});case"danger":return ge.jsx(mf,{backgroundColor:n.custom.palette.red[500],name:"warning"});case"discover":return ge.jsx(mf,{backgroundColor:n.custom.palette.purple[500],name:"lightbulb"})}},mf=({backgroundColor:e,name:n})=>{const o=t.useTheme();return ge.jsx(t.Box,{sx:{display:"flex",alignItems:"flex-start",pt:.25},children:ge.jsx(t.Box,{sx:{backgroundColor:e,borderRadius:o.custom.radius.round,color:o.custom.palette.white,display:"flex",p:.5},children:ge.jsx(en,{name:n,size:20})})})},ff=t.styled(t.Box)((({theme:e,divider:t=!1})=>({width:"100%",transition:"all 0.3s ease",borderBottom:t?`1px solid ${e.custom.palette.stroke.default}`:"none","&:hover":{'*[data-id="image-container"]':{boxShadow:e.custom.elevation.raised}}}))),gf=t.styled(t.CardActionArea)((({theme:e,disableHoverStyle:t=!1})=>({...!0===t&&{"& .MuiCardActionArea-focusHighlight":{backgroundColor:e.palette.background.paper}}}))),xf=t.styled(t.Box)((({theme:e})=>({transition:"all 200ms ease",boxShadow:"none",overflow:"hidden",height:150,position:"relative",borderRadius:e.spacing(e.custom.radius.md)}))),vf=({thumbnail:e,title:t,description:n})=>ge.jsx(Um,{src:e,alt:`${t} | ${n}`,title:`${t} | ${n}`,style:{width:"100%",height:"auto",objectFit:"cover"}}),yf=t.styled(t.CardContent)((({theme:e})=>({paddingTop:e.spacing(e.custom.padding.xs),paddingBottom:e.spacing(e.custom.padding.xs),paddingLeft:0,paddingRight:0,display:"flex",flexDirection:"column",gap:e.spacing(e.custom.margin.xs),'& [data-id="title-container"]':{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"start",gap:e.spacing(e.custom.margin.xs),"& > p":{alignSelf:"center"}}}))),bf=t.styled(t.Skeleton)((({theme:e})=>({transform:"none",width:"100%",height:"100%"}))),wf=({updatedDate:e,format:t=!1,noWrap:n})=>ge.jsxs(dn,{variation:"sm",component:"p",color:"text.secondary",noWrap:n,children:["Edited on ",t?T(e).format("DD MMM YYYY"):e]}),jf=({title:e,description:n,loopCount:o,testCount:i,draftCount:r,updatedAt:s,moreActions:a,thumbnail:l,isDemo:c,loading:u,onClick:d})=>u?ge.jsx(ff,{children:ge.jsxs(gf,{disableHoverStyle:!0,children:[ge.jsx(xf,{"data-id":"image-container",children:ge.jsx(bf,{})}),ge.jsxs(yf,{children:[ge.jsx(t.Box,{"data-id":"title-container",height:32,children:ge.jsx(bf,{})}),ge.jsx(bf,{}),ge.jsx(bf,{width:"60%"})]})]})}):ge.jsx(ff,{children:ge.jsxs(gf,{disableHoverStyle:!0,onClick:d,children:[ge.jsxs(xf,{"data-id":"image-container",children:[c&&ge.jsx(_p,{body:"Demo",sx:{bottom:8,left:8}}),ge.jsx(vf,{thumbnail:l,title:e,description:n})]}),ge.jsxs(yf,{children:[ge.jsxs(t.Box,{"data-id":"title-container",children:[ge.jsx(Up,{title:e,maxLines:2}),ge.jsx(t.Box,{"data-id":"more-actions-container",onClick:e=>{e.stopPropagation()},children:a})]}),ge.jsx(Wp,{loops:o,tests:i,drafts:r}),ge.jsx(wf,{updatedDate:s,format:!0})]})]})}),Cf=({title:e,description:n,loopCount:o,testCount:i,draftCount:r,updatedAt:s,moreActions:a,thumbnail:l,isDemo:c,loading:u,onClick:d})=>{const p=t.useTheme();return u?ge.jsx(ff,{divider:!0,children:ge.jsxs(gf,{onClick:d,sx:{p:p.spacing(p.custom.padding.xs),display:"flex",gap:p.spacing(p.custom.margin.sm),alignItems:"center"},children:[ge.jsx(xf,{sx:{height:72,width:108},"data-id":"image-container",children:ge.jsx(bf,{})}),ge.jsx(yf,{sx:{overflow:"hidden",pl:p.spacing(p.custom.padding.sm),minWidth:67,flex:1,"&:last-child":{pb:0}},children:ge.jsxs(t.Stack,{gap:p.spacing(p.custom.margin.xs),children:[ge.jsx(bf,{width:"100%",height:20}),ge.jsxs(t.Stack,{direction:"row",gap:p.spacing(p.custom.margin.xs),justifyContent:"space-between",flexWrap:"wrap",children:[ge.jsx(bf,{width:"70%"}),ge.jsx(bf,{width:200})]})]})})]})}):ge.jsx(ff,{divider:!0,children:ge.jsxs(gf,{onClick:d,sx:{p:p.spacing(p.custom.padding.xs),display:"flex",gap:p.spacing(p.custom.margin.sm),alignItems:"center"},children:[ge.jsxs(xf,{sx:{height:72,width:108},"data-id":"image-container",children:[c&&ge.jsx(_p,{sx:{top:4,right:4},body:"Demo"}),ge.jsx(vf,{thumbnail:l,title:e,description:n})]}),ge.jsx(yf,{sx:{overflow:"hidden",pl:p.spacing(p.custom.padding.sm),minWidth:67,flex:1,"&:last-child":{pb:0}},children:ge.jsxs(t.Stack,{gap:p.spacing(p.custom.margin.xs),children:[ge.jsx(Up,{title:e,maxLines:1}),ge.jsxs(t.Stack,{direction:"row",gap:p.spacing(p.custom.margin.xs),justifyContent:"space-between",flexWrap:"wrap",children:[ge.jsx(Wp,{loops:o,tests:i,drafts:r}),ge.jsx(wf,{updatedDate:s,format:!0,noWrap:!0})]})]})}),a&&ge.jsx(t.Box,{onClick:e=>e.stopPropagation(),children:a})]})})},Sf=t.styled(t.Box)((({theme:e})=>({alignItems:"center",backgroundColor:e.custom.palette.surface.default,borderBottom:`0.5px solid ${e.custom.palette.stroke.default}`,display:"flex",gap:e.spacing(1),justifyContent:"space-between",padding:1}))),kf=t.styled(t.Box)((({theme:e})=>({alignItems:"center",display:"flex",gap:e.spacing(1)}))),Mf=t.styled(dn)((({theme:e})=>({color:e.custom.palette.text.secondary})));var Tf={headings:{"01-starter":{heading:"Starter",pricing:"{{currencySymbol}} {{starterPrice}} / month"},"02-team":{heading:"Team",pricing:"{{currencySymbol}} {{teamPrice}} / month"},"03-plus":{heading:"Plus",pricing:"{{currencySymbol}} {{plusPrice}} / month"},"04-scale":{heading:"Scale",pricing:"{{currencySymbol}} {{scalePrice}} / month"}},rows:{"01-seats":{heading:"Seats",description:"The number of users you can have on your account.",starter:"1",team:"10",plus:"50",scale:"100+"},"02-servicing":{heading:"Client servicing included",description:"Get direct communication with a Loops Customer Success Manager.",starter:"{{dash}}",team:"{{dash}}",plus:"Serviced lite",scale:"💪\nFully serviced"},"03-respondents":{heading:"Price per respondent",description:"The amount you pay to recruit and survey each respondent.",starter:"{{currencySymbol}}{{starterRespondentPrice}}",team:"{{currencySymbol}}{{teamRespondentPrice}}",plus:"{{currencySymbol}}{{plusRespondentPrice}}",scale:"{{currencySymbol}}{{scaleRespondentPrice}}"},"04-questions":{heading:"Question limit",description:"The maximum number of questions you can add to a test.",starter:"10",team:"15",plus:"20",scale:"25"},"05-ai":{heading:"AI-powered insights",description:"Use Loops AI to summarise the findings from your tests.",starter:"Basic",team:"✨\nAdvanced",plus:"✨\nAdvanced",scale:"✨\nAdvanced"},"06-demographics":{heading:"Demographic filters",description:"Reach your target audience using built-in demographic filters.",starter:"Basic",team:"🎯\nAdvanced",plus:"🎯\nAdvanced",scale:"🎯\nAdvanced"},"07-training":{heading:"Training",description:"Our team will onboard you and get you set up.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"08-invite":{heading:"Invite your own respondents",description:"Share your test with your own recruited audience.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"09-email":{heading:"Email capture",description:"Ability to collect respondent email addresses.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"10-beta":{heading:"Beta features",description:"Assess to our latest features as they become available.",starter:"{{dash}}",team:"{{dash}}",plus:"{{tick}}",scale:"{{tick}}"},"11-sso":{heading:"Single sign on (SSO)",description:"Enterprise level authentication using SAML (supports Okta and OneLogin).",starter:"{{dash}}",team:"{{dash}}",plus:"{{dash}}",scale:"{{tick}}"},"12-minimum":{heading:"Minimum term",description:"The minimum subscription period.",starter:"30 days",team:"6 months",plus:"6 months",scale:"12 months"}}};const Pf=({text:e})=>{const n=t.useTheme(),o="{{tick}}"===e,i="{{dash}}"===e;return ge.jsx(t.Box,{sx:{display:"flex",alignItems:"center",textAlign:"center",width:122},children:ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"center",alignItems:"center",p:{sm:.5,md:1},flex:1},children:[o&&ge.jsx(en,{name:"badge-tick-in-circle",size:24}),i&&ge.jsx(en,{name:"badge-hyphen",size:24}),!o&&!i&&ge.jsx(dn,{variation:"lg",component:"p",sx:{color:n.custom.palette.text.secondary,hyphens:"none",whiteSpace:"pre"},children:ge.jsx(ge.Fragment,{children:e})})]})})},Bf=()=>{const t="object"==typeof window;function n(){return{width:t?window.innerWidth:void 0,height:t?window.innerHeight:void 0}}const[o,i]=e.useState(n);return e.useEffect((()=>{if(t)return window.addEventListener("resize",o),()=>window.removeEventListener("resize",o);function o(){e.startTransition((()=>{i(n())}))}}),[]),o};const Af="https://useloops-public.s3.eu-west-2.amazonaws.com/public/fonts/",Ef=()=>ge.jsx(t.GlobalStyles,{styles:{"strong, b":{fontWeight:500}}}),zf=e.createContext(null),If=(n="light",o="lg",i="ltr")=>{const{width:r}=Bf(),[s,a]=e.useState(n),[l,c]=e.useState(o),[u,d]=e.useState(i),[p,h]=e.useState(!1),[m,f]=e.useState("");e.useEffect((()=>{document.documentElement.setAttribute("dir",u)}),[u]);e.useEffect((()=>{e.startTransition((()=>{c(r&&r<X.lg?"sm":"lg")}))}),[r]),e.useEffect((()=>{e.startTransition((()=>{d(i)}))}),[i]),e.useEffect((()=>{e.startTransition((()=>{a(n)}))}),[n]);const g=e.useMemo((()=>((e,n,o)=>t.createTheme({direction:o,custom:{palette:{black:"#000000",white:"#ffffff",neutral:N[e],neutralAlpha:"light"===e?V:F,purple:U[e],red:G[e],peach:q[e],yellow:K[e],blue:Z[e],green:Y[e],icon:ae[e].icon,interaction:ae[e].interaction,stroke:ae[e].stroke,surface:ae[e].surface,text:ae[e].text,input:ae[e].input},margin:ee,padding:te,radius:ne,elevation:oe,elevationFilter:ie,boxShadow:re,easing:se,typography:On[n]},palette:{mode:e,primary:{main:L[500]}},spacing:Q,shape:{borderRadius:Q,hotspot:{default:12,active:24}},breakpoints:{values:X},typography:{fontFamily:`"${ce.FoundersGrotesk.name}", "Helvetica", "sans-serif"`},components:{MuiTypography:{variants:$n(n),styleOverrides:{root:{color:ae[e].text.primary,letterSpacing:0,lineHeight:"140%"}}},MuiCssBaseline:{styleOverrides:`\n\t\t\t\t\tbody {\n\t\t\t\t\t\tbackground: ${N[e][0]};\n\t\t\t\t\t\tmin-width: 320px;\n\t\t\t\t\t}\n\t\t\t\t\ta {\n\t\t\t\t\t\tcolor: inherit;\n\t\t\t\t\t\tdisplay: flex;\n\t\t\t\t\t\ttext-decoration: none;\n\t\t\t\t\t}\n\t\t\t\t\tb {\n\t\t\t\t\t\tfont-weight: 500;\n\t\t\t\t\t}\n @font-face {\n font-family: '${ce.Domaine.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.Domaine.default.weight};\n src: url(${Af}${ce.Domaine.default.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.Domaine.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.Domaine.bold.weight};\n src: url(${Af}${ce.Domaine.bold.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.FoundersGrotesk.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.FoundersGrotesk.default.weight};\n src: url(${Af}${ce.FoundersGrotesk.default.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.FoundersGrotesk.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.FoundersGrotesk.bold.weight};\n src: url(${Af}${ce.FoundersGrotesk.bold.fileName}) format('woff2');\n }\n `},MuiContainer:{defaultProps:{maxWidth:"xl",disableGutters:!0},styleOverrides:{root:{paddingLeft:16,paddingRight:16,[`@media (min-width: ${X.md}px)`]:{paddingLeft:24,paddingRight:24},[`@media (min-width: ${X.lg}px)`]:{paddingLeft:48,paddingRight:48}}}},MuiButtonBase:{defaultProps:{disableTouchRipple:!0,disableRipple:!0}},MuiButton:{defaultProps:{disableTouchRipple:!0,disableRipple:!0}},MuiTooltip:{styleOverrides:{arrow:({theme:{custom:e}})=>({color:e.palette.surface.overlay}),tooltip:({theme:{custom:e}})=>({backgroundColor:e.palette.surface.overlay,borderRadius:e.radius.md,color:e.palette.text.primary,backdropFilter:"blur(0)",filter:e.elevationFilter.overlay,fontFamily:ce.FoundersGrotesk.name,fontSize:e.typography.body.sm,fontWeight:400,padding:`${e.padding.sm*Q}px ${e.padding.md*Q}px`})}},MuiAvatarGroup:{styleOverrides:{root:{flexDirection:"row"},avatar:({theme:{custom:e}})=>({border:`1px solid ${e.palette.stroke.default}`,marginLeft:0,marginRight:-8,":last-child":{marginLeft:"auto"}})}}}}))(s,l,u)),[s,u,l]),x=t.useMediaQuery(g.breakpoints.only("sm"),{noSsr:!0}),v=t.useMediaQuery(g.breakpoints.only("md"),{noSsr:!0}),y=t.useMediaQuery(g.breakpoints.between("lg","xl"),{noSsr:!0}),b=t.useMediaQuery(g.breakpoints.up("xl"),{noSsr:!0});return e.useEffect((()=>{e.startTransition((()=>{x&&f("sm"),v&&f("md"),y&&f("lg"),b&&f("xl")}))}),[x,v,y,b]),{breakpoint:m,gridOverlayVisible:p,mode:s,theme:g,toggleGridOverlay:()=>{e.startTransition((()=>{h((e=>!e))}))},toggleMode:t=>{e.startTransition((()=>{if(t)return a(t);a((e=>"light"===e?"dark":"light"))}))}}},Rf=df({key:"muirtl",stylisPlugins:[k.prefixer,P]}),Vf=df({key:"mui"});exports.AnnualController=({body:e,currency:n,changeCurrencyEvent:o=()=>{},frequency:i,heading:r,setCurrency:s=()=>{},setFrequency:a=()=>{},togglePayAnnuallyEvent:l=()=>{},sizing:c="lg",selections:u=[{value:"gbp",label:"£"},{value:"eur",label:"€"},{value:"usd",label:"$"}]})=>{const d=t.useTheme(),p=Wo();return ge.jsxs(t.Box,{sx:{alignItems:"center",backgroundColor:d.custom.palette.surface.default,borderRadius:d.custom.radius.round,boxShadow:d.custom.elevation.raised,display:"flex",gap:{sm:2,lg:4},mb:2,mt:4,px:{sm:2,lg:"sm"===c?2:4},py:{sm:1,lg:2}},children:[ge.jsxs(t.Box,{sx:{alignItems:"center",display:"flex",gap:1},children:[ge.jsx(t.Box,{sx:{pr:2},children:ge.jsx(jm,{defaultChecked:!0,onChange:()=>(l(),void a("monthly"===i?"annual":"monthly")),role:"switch","aria-checked":"monthly"!==i,"aria-label":"Switch between monthly and annual billing",inputProps:{"aria-label":"Input for switch between monthly and annual billing"},sizing:c})}),ge.jsxs(t.Stack,{sx:{alignItems:"flex-start",display:"flex"},children:[ge.jsx(dn,{variation:"sm"===p||"md"===p||"sm"===c?"md":"xxl",component:"p",children:r}),ge.jsx(dn,{variation:"sm",component:"p",sx:{color:d.custom.palette.text.secondary},children:e})]})]}),ge.jsx(Yh,{name:"currency",onChange:e=>{return t=e.target.value,o(t),void s(t);var t},selections:u,value:u.find((e=>e.value===n))?.value,sx:{minWidth:{sm:64,lg:72},height:{sm:J[400],lg:J[500]}}})]})},exports.AuthContainerSurface=({children:e,headContent:o,sx:i,...r})=>{const s=t.useTheme();return ge.jsxs(an,{...r,sx:n.mergeSx(i,{mx:[s.spacing(s.custom.margin.md),0],width:1,maxWidth:[512]}),children:[o&&ge.jsx(t.Box,{sx:{width:"100%",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit",pt:s.spacing(s.custom.margin.md),px:s.spacing(s.custom.margin.md)},children:o}),ge.jsx(t.Box,{sx:{width:"100%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",pt:o?[s.spacing(s.custom.margin.md)]:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)],px:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)],pb:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)]},children:e})]})},exports.AuthFormHeader=({logo:e,headerText:n,subText:o})=>{const i=t.useTheme();return ge.jsxs(t.Stack,{gap:i.spacing(i.custom.margin.md),alignItems:"center",mb:i.spacing(i.custom.margin.lg),children:[!1===e?null:e||ge.jsx(en,{name:"brand-wordmark",sx:{width:{sm:79,md:79,lg:106},height:{sm:24,md:24,lg:32}}}),ge.jsxs(t.Stack,{gap:i.spacing(i.custom.margin.md),children:[n&&ge.jsx(dn,{variation:"sm",component:"h1",align:"center",weight:"bold",children:n}),function(){if(o)return"string"==typeof o?ge.jsx(dn,{variation:"md",component:"p",align:"center",children:o}):o}()]})]})},exports.Avatar=Co,exports.AvatarGroup=({variation:e="primary",...n})=>{if("primary"===e)return ge.jsx(t.AvatarGroup,{...n})},exports.Breadcrumb=gn,exports.Button=Tp,exports.Checkbox=th,exports.CheckboxGroup=ih,exports.ColorBackgroundContainer=({sx:e,children:o,texture:i="noise1",gradient:r="tone1",...s})=>{const a=t.useTheme();return ge.jsx(t.Container,{maxWidth:!1,disableGutters:!0,sx:n.mergeSx({background:Xp(a,{texture:i,gradient:r}),height:"100%",p:[0,0,0]},!!e&&{...e}),...s,children:o})},exports.CustomField=rh,exports.DEFAULT_MAX_INPUT_LENGTH=Kp,exports.Differential=gh,exports.DropdownMenu=({open:e,anchorEl:n,handleClick:o,handleClose:i,items:r,...s})=>ge.jsx(ge.Fragment,{children:ge.jsx(xh,{anchorEl:n,open:e,onClose:i,MenuListProps:{"aria-labelledby":"basic-button"},elevation:0,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},...s,children:r?.map(((e,n)=>ge.jsxs(t.MenuItem,{onClick:e.onClick,...e.menuItemProps,children:[e.icon&&ge.jsx(t.Box,{mr:1,children:e.icon}),e.label]},n)))})}),exports.FormControlLabel=Jp,exports.FormGenerator=Vm,exports.GridOverlay=({breakpoint:e})=>{const n=Array.from({length:6},((e,t)=>t));return e||(e=Wo()),ge.jsxs(Fm,{children:[ge.jsx(Lm,{children:ge.jsx(Dm,{children:ge.jsxs(t.Unstable_Grid2,{container:!0,spacing:2,sx:{flex:1},children:[n.map((e=>ge.jsx(t.Unstable_Grid2,{sm:!0,sx:{display:{sm:"none",md:"block"}},children:ge.jsx(Om,{})},`grid-1-${e}`))),n.map((e=>ge.jsx(t.Unstable_Grid2,{sm:!0,sx:{display:{sm:"block"}},children:ge.jsx(Om,{})},`grid-2-${e}`)))]})})}),!!e&&ge.jsx($m,{children:ge.jsx(dn,{variation:"md",component:"p",weight:"bold",children:e})})]})},exports.Header=({backHref:e,title:n,breadcrumbLinks:o,buttons:i,controlBar:r})=>ge.jsxs(ge.Fragment,{children:[ge.jsx(En,{sx:{justifyContent:"space-between"},children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsxs(Vn,{sx:{justifyContent:"space-between",py:1},children:[ge.jsxs(Vn,{children:[e&&ge.jsx(An,{sizing:"lg",icon:ge.jsx(en,{name:"arrow-left",size:20})}),ge.jsxs(Vn,{sx:{alignItems:"flex-start",flexDirection:"column",gap:0},children:[n&&ge.jsx(dn,{variation:"lg",component:"p",weight:"bold",children:n}),o&&ge.jsx(gn,{links:o})]})]}),i&&ge.jsx(Vn,{children:i})]})})})})}),r&&ge.jsx(zn,{children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsx(In,{children:ge.jsx(Rn,{children:r})})})})})})]}),exports.Html=yh,exports.Icon=en,exports.IconButton=An,exports.IconButtonGroup=({ButtonGroupProps:e,children:t,...n})=>ge.jsx(Nm,{...n,...e,children:t}),exports.Image=Um,exports.InputFieldBase=nh,exports.InputLabel=bh,exports.InputLabelHelp=lh,exports.Likert=Ph,exports.Link=cn,exports.Loader=()=>ge.jsx(t.Box,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:"calc(100dvh - 80px)"},children:ge.jsx("img",{src:"https://useloops-public.s3.eu-west-2.amazonaws.com/public/landing/brand/loading-animation.gif",width:125})}),exports.Logo=e=>ge.jsx("svg",{viewBox:"0 0 80 25",fill:"currentColor",...e,children:ge.jsx("path",{d:"M8.72886 20.0975C7.43461 19.1995 7.16357 18.9302 7.16357 16.9549V0.988281H-0.000106812V1.28748L0.0165316 1.29764C1.3293 2.09875 1.92633 2.46309 1.92633 4.43011V16.9549C1.92633 18.9302 1.65553 19.1995 0.361043 20.0975V20.3965H8.72886V20.0975ZM14.5709 13.437C13.7868 9.01598 14.1045 7.0153 16.0905 6.66718C18.0767 6.31907 19.0631 8.09095 19.8472 12.512C20.6311 16.933 20.3137 18.9335 18.3275 19.2816C16.3415 19.6299 15.3548 17.8578 14.5709 13.437ZM9.11663 14.3934C9.93203 18.9911 14.141 21.3529 18.5575 20.5785C22.9743 19.8041 26.1169 16.1534 25.3015 11.5559C24.4861 6.95793 20.2773 4.5961 15.8605 5.3705C11.444 6.14467 8.30123 9.79541 9.11663 14.3934ZM33.3669 6.66718C31.381 7.0153 31.0633 9.01598 31.8474 13.437C32.6313 17.8578 33.618 19.6299 35.6039 19.2816C37.5901 18.9335 37.9076 16.933 37.1237 12.512C36.3396 8.09095 35.3531 6.31907 33.3669 6.66718ZM35.834 20.5785C31.4175 21.3529 27.2085 18.9911 26.3931 14.3934C25.5777 9.79541 28.7205 6.14467 33.137 5.3705C37.5538 4.5961 41.7625 6.95793 42.5779 11.5559C43.3933 16.1534 40.2508 19.8041 35.834 20.5785ZM52.9075 18.9002C51.0712 18.9002 49.6266 16.8353 49.6266 14.441V12.3162C49.6266 9.6524 50.9209 7.64737 52.9075 7.64737C54.9843 7.64737 56.0078 9.53285 56.0078 12.7351C56.0078 16.955 54.9542 18.9002 52.9075 18.9002ZM51.6733 24.5936C50.1696 23.7488 49.6266 23.4437 49.6266 21.5189V17.9125C50.4091 19.4689 51.9744 20.6958 54.5629 20.6958C58.476 20.6958 61.5762 17.763 61.5762 12.7052C61.5762 7.55754 58.5663 5.25308 55.1047 5.25308C52.2753 5.25308 50.3187 6.83937 49.6266 9.02405L49.5063 5.55228H42.5833V5.85171L42.5873 5.85427C43.8786 6.69033 44.3891 7.02081 44.3891 8.99411V21.5189C44.3891 23.4942 44.1183 23.7637 42.824 24.6613V24.9605H51.7937V24.6613L51.6733 24.5936ZM79.8954 18.9002C79.8954 19.8689 79.1055 20.6543 78.1313 20.6543C77.157 20.6543 76.3671 19.8689 76.3671 18.9002C76.3671 17.9315 77.157 17.1462 78.1313 17.1462C79.1055 17.1462 79.8954 17.9315 79.8954 18.9002ZM70.0692 10.2734C68.0387 9.67975 66.9044 9.34812 66.9044 8.15614C66.9044 7.16849 67.8074 6.71957 68.8309 6.71957C70.7874 6.71957 72.3224 7.827 74.0985 10.4007H74.5196V5.25306H74.2187L72.8642 6.24072C72.8031 6.21577 72.742 6.19075 72.681 6.16573C71.5696 5.71024 70.454 5.25306 68.7707 5.25306C65.55 5.25306 62.9916 7.22837 62.9916 10.1612C62.9916 12.795 64.2557 14.2912 68.8008 15.4585C70.4863 15.8775 71.6601 16.1767 71.6601 17.4636C71.6601 18.6608 70.4863 19.2293 69.0718 19.2293C66.9044 19.2293 65.3093 17.763 63.2021 14.9797H62.7509L63.0819 20.6661H63.413L64.6169 19.4688C65.5801 19.9477 67.0851 20.6958 69.1019 20.6958C72.9546 20.6958 75.6334 18.571 75.6334 15.5783C75.6334 12.4956 73.7672 11.3584 70.095 10.2809L70.0692 10.2734Z"})}),exports.LoopsAiButton=()=>ge.jsx(Gm,{variation:"primary",sizing:"md",startIcon:ge.jsx(en,{name:"ai"}),children:"Loops AI"}),exports.Markdown=e=>{const{children:t}=e,n=t&&t.replaceAll(/\s/g,"&nbsp;").replaceAll(/<p><\/p>/g,"<br />");return ge.jsx(S,{options:{overrides:{p:{component:dn,props:qm},strong:{component:dn,props:{...qm,weight:"bold"}},em:{component:dn,props:{...qm,fontWeight:"inherit",fontStyle:"italic"}}},wrapper:Km,forceBlock:!0,forceWrapper:!0},children:n})},exports.MenuButton=io,exports.Navigation=({logoLink:e,isMobile:n,nudgeProps:o,primaryMenuItemProps:i,secondaryMenuItemProps:r,sizing:s="lg",tertiaryMenuItemProps:a,toggleMenuOnClick:l=()=>{},userMenuProps:c})=>{const u=t.useTheme();return ge.jsxs(Oo,{navigationSizing:s,children:[ge.jsx(Do,{logoLink:e,navigationSizing:s,toggleMenuOnClick:l,isMobile:n}),ge.jsx($o,{children:ge.jsxs(t.Stack,{sx:{gap:4,justifyContent:"space-between",width:"100%"},children:[i?.length>0&&ge.jsx(t.Stack,{sx:{gap:"lg"===s?.5:2,width:"100%"},children:i.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e},`primary-menu-item-${t}`)))}),ge.jsxs(t.Stack,{sx:{gap:2},children:[o?.title&&ge.jsx(jo,{navigationSizing:s,...o}),r?.length>0&&r.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e,label:"Help center"===e.label&&"sm"===s?"Help":e.label},`secondary-menu-item-${t}`))),ge.jsx(t.Divider,{sx:{color:u.custom.palette.stroke.default}}),ge.jsx(Io,{navigationSizing:s,...c}),a?.length>0&&ge.jsx(Ho,{children:a.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e},`tertiary-menu-item-${t}`)))})]})]})})]})},exports.Nudge=jo,exports.NumberField=Ah,exports.OnboardingCard=({cardTitle:n,cardSubtitle:i,welcomeImageUrl:r,welcomeImageAltDescription:s,items:a=[]})=>{const[l,c]=e.useState(!0),u=Wo(),d=()=>c(!l),p=a.length,h=a.filter((e=>e.complete)).length,m=h/p*100;return ge.jsxs(an,{variation:"raised",borderradius:"lg",sx:{display:"flex",flexDirection:"xl"===u?"row":"column",gap:e=>e.spacing(e.custom.margin.lg),padding:e=>e.spacing(e.custom.padding.lg)},children:[ge.jsxs(Uo,{children:[ge.jsx(t.Box,{component:"img",src:r,alt:s,width:"72px",height:"72px"}),ge.jsx(dn,{component:"h1",variation:"md",fontWeight:500,children:n}),ge.jsx(qo,{component:"p",variation:"lg",children:i})]}),ge.jsxs(Go,{children:[ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"space-between",alignItems:"start",width:"100%",height:"36px",paddingBottom:e=>e.spacing(e.custom.padding.sm)},children:[ge.jsx(Op,{completed:h,total:p}),l&&ge.jsx(An,{sizing:"sm",variation:"outlined",icon:ge.jsx(o.ExpandLess,{}),onClick:d})]}),ge.jsx(_o,{variation:"determinate",value:m}),ge.jsx(Dp,{expanded:l,onToggleExpanded:d,items:a})]})]})},exports.Pill=({body:e,maxWidth:t,...n})=>ge.jsx(Xm,{label:e,sx:{...t&&{maxWidth:`${t}px`}},...n}),exports.PlanFeatureTable=({currencySymbol:e,data:n,starterPrice:o,starterRespondentPrice:i,teamPrice:r,teamRespondentPrice:s,plusPrice:a,plusRespondentPrice:l,scalePrice:c,scaleRespondentPrice:u,variation:d="default"})=>{const p=t.useTheme();n||(n=Tf);const h=Object.values(n.headings).map((({heading:t,pricing:n})=>({heading:t,pricing:n.replace("{{currencySymbol}}",e).replace("{{starterPrice}}",o).replace("{{teamPrice}}",r).replace("{{plusPrice}}",a).replace("{{scalePrice}}",c)}))),m=t=>t.replace("{{currencySymbol}}",e).replace("{{starterRespondentPrice}}",i||"").replace("{{teamRespondentPrice}}",s||"").replace("{{plusRespondentPrice}}",l||"").replace("{{scaleRespondentPrice}}",u||""),f=[...Object.values(n.rows).map(((e,t)=>({key:`pricing-table-features-${t}`,type:"row",name:{heading:e.heading,description:e.description},starter:m(e.starter),team:m(e.team),plus:m(e.plus),scale:m(e.scale)})))];return ge.jsxs(t.Stack,{sx:{backgroundColor:p.custom.palette.surface.default,borderRadius:p.spacing(p.custom.radius.xl),boxShadow:p.custom.elevation.raised,display:"flex",gap:2,pb:{sm:2,lg:4},px:{sm:2,lg:4},minWidth:{sm:680}},children:[ge.jsxs(t.Box,{sx:{display:"flex",py:2,px:1,justifyContent:"space-between"},children:[ge.jsx(t.Box,{sx:{width:160}}),h.map((({heading:e,pricing:n})=>ge.jsxs(t.Stack,{sx:{alignItems:"center",display:"flex",justifyContent:"center",width:122},children:[ge.jsx(dn,{variation:"platform"===d?"lg":"xxl",component:"p",weight:"bold",children:e}),ge.jsx(dn,{variation:"platform"===d?"sm":"md",component:"p",sx:{color:p.custom.palette.text.secondary},children:n})]},e)))]}),f.map((e=>ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"space-between",p:1,"&:nth-of-type(odd)":{backgroundColor:p.custom.palette.surface.sunken}},children:[ge.jsx(t.Box,{sx:{display:"flex",alignItems:"center",width:160},children:ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"flex-start",alignItems:"center",flex:1,gap:1},children:[e.name.description&&ge.jsx(yn,{message:e.name.description,children:ge.jsx(t.Box,{sx:{alignItems:"center",color:p.custom.palette.icon.secondary,display:"flex"},children:ge.jsx(en,{name:"info",size:24})})}),ge.jsx(dn,{variation:"platform"===d?"md":"lg",component:"p",children:e.name.heading})]})}),ge.jsx(Pf,{text:e.starter}),ge.jsx(Pf,{text:e.team}),ge.jsx(Pf,{text:e.plus}),ge.jsx(Pf,{text:e.scale})]},e.key)))]})},exports.PlanTierCard=({amount:n,billingType:o,body:i,ctaEvent:r=()=>{},ctaLink:s="#",ctaTarget:a="_self",ctaText:l,ctaVariation:c="primary",currencySymbol:u,currentPlan:d,features:p=[],freeTrialLength:h,freeTrialText:m,frequency:f,heading:g,label:x,largestHeaderHeight:v=0,perMonth:y,setLargestHeaderHeight:b=()=>{},variation:w="default"})=>{const j=t.useTheme(),C=Wo(),{width:S}=Bf(),k=e.useRef(null),[M,T]=e.useState("sm");return e.useEffect((()=>{e.startTransition((()=>{T(C),C!==M&&b(0),k.current&&k.current.offsetHeight>v&&b(k.current.offsetHeight)}))}),[C,M,S]),ge.jsxs(t.Stack,{sx:{display:"flex",flex:1,position:"relative"},children:[ge.jsx(t.Stack,{sx:{alignItems:"center",backgroundColor:j.custom.palette.icon.primary,borderTopLeftRadius:j.spacing(j.custom.radius.lg),borderTopRightRadius:j.spacing(j.custom.radius.lg),boxShadow:j.custom.elevation.overlay,color:j.custom.palette.text.primaryInverted,justifyContent:"center",p:{sm:1,lg:2},textTransform:"uppercase",opacity:x?1:0,display:{sm:x?"flex":"none",md:"flex"}},children:ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:{color:j.custom.palette.white},children:x||"&nbsp;"})}),ge.jsxs(t.Stack,{sx:{backgroundColor:j.custom.palette.surface.default,borderBottomLeftRadius:j.spacing(j.custom.radius.lg),borderBottomRightRadius:j.spacing(j.custom.radius.lg),borderTopLeftRadius:x?0:j.spacing(j.custom.radius.lg),borderTopRightRadius:x?0:j.spacing(j.custom.radius.lg),boxShadow:j.custom.elevation.overlay,display:"flex",flex:1},children:[ge.jsxs(t.Stack,{sx:{display:"flex",gap:"sm"===C||"md"===C?1:2,textAlign:"center",minHeight:{sm:"none",md:v},px:2,py:{sm:2,lg:4}},ref:k,children:[ge.jsx(dn,{variation:"sm"===C?"xxl":"platform"===w?"md":"lg",component:"h2",weight:"bold",children:g}),ge.jsx(dn,{variation:"sm"===C?"md":"platform"===w?"md"===C?"sm":"md":"md"===C?"md":"lg",component:"p",sx:{color:j.custom.palette.text.secondary},children:i})]}),ge.jsxs(t.Stack,{sx:{alignItems:"center",display:"flex",gap:2,minHeight:{sm:"none",md:168,lg:"platform"===w?184:240,xl:"platform"===w?184:226},px:2,py:{sm:2,md:2,lg:"platform"===w?2:6}},children:[ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex",gap:.5,justifyContent:"center"},children:[ge.jsx(dn,{variation:"md"===C?"sm":"xxl",component:"p",weight:"bold",sx:{lineHeight:1,marginBottom:-.15,marginRight:-.4},children:u}),ge.jsx(dn,{variation:"xxl",component:"p",weight:"bold",sx:{fontSize:{sm:48,md:26,lg:48},lineHeight:.8},children:n}),y&&ge.jsx(dn,{variation:"sm",component:"p",sx:{color:j.custom.palette.text.secondary,lineHeight:1,marginLeft:-.5},children:y})]}),h&&m&&ge.jsxs(t.Box,{sx:{alignItems:"center",backgroundColor:j.custom.palette.yellow[300],borderRadius:j.custom.radius.round,boxShadow:j.custom.elevation.raised,display:"flex",gap:{sm:.5,md:1},px:2,py:1},children:[ge.jsx(en,{name:"gift",size:24}),ge.jsxs(t.Box,{sx:{display:"flex",flexDirection:{sm:"row",md:"column",lg:"row"},gap:{sm:.5,md:0,lg:.5}},children:[ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:{lineHeight:1},children:h}),ge.jsx(dn,{variation:"md",component:"p",sx:{lineHeight:1},children:m})]})]}),o&&ge.jsx(dn,{variation:"sm",component:"p",sx:{color:j.custom.palette.text.placeholder},children:o})]}),ge.jsxs(t.Stack,{sx:{display:"flex",flexDirection:{sm:"column-reverse",md:"column"}},children:[ge.jsx(t.Box,{sx:{py:{sm:2,md:0},px:{sm:2,lg:4}},children:ge.jsx(cn,{href:s,title:l,target:a,onClick:()=>{g&&r(g)},sx:{"&:hover":{cursor:d?"default":"pointer"}},children:ge.jsx(Tp,{fullWidth:!0,variation:c,sizing:"lg",disabled:d,children:l})})}),p?.length&&ge.jsx(t.Stack,{sx:{alignItems:"center",gap:.5,px:{sm:2,lg:4},py:{sm:2,md:4,lg:"platform"===w?4:6}},children:p.map(((e,n)=>ge.jsxs(t.Box,{sx:{alignItems:"center",display:"flex",gap:1,maxWidth:200,width:"100%"},children:[ge.jsx(en,{name:"badge-tick",size:24}),ge.jsx(dn,{variation:"md",component:"p",children:e})]},`${g}-feature-${n}`)))})]})]})]})},exports.PlanTierCardScale=({body:e,ctaEvent:n=()=>{},ctaLink:o="",ctaTarget:i="_blank",ctaText:r,currencySymbol:s,heading:a,postText:l,preText:c,amount:u})=>{const d=t.useTheme();return ge.jsxs(t.Box,{sx:{backgroundColor:d.custom.palette.purple[0],borderRadius:d.spacing(d.custom.radius.lg),display:"flex",flexDirection:{sm:"column",md:"row"},textAlign:{sm:"center",md:"left"},boxShadow:d.custom.elevation.overlay,flex:1,gap:{sm:4,md:2},p:{sm:2,lg:4}},children:[ge.jsxs(t.Stack,{sx:{flex:1,gap:2,justifyContent:"center"},children:[ge.jsx(dn,{variation:"md",component:"h2",sx:{fontWeight:500},children:a}),ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.secondary},children:e})]}),ge.jsxs(t.Stack,{sx:{flex:1,gap:{sm:4,md:2},justifyContent:"center",maxWidth:{sm:"none",md:180,lg:320},p:{sm:0,md:2,lg:4}},children:[ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex",justifyContent:"center"},children:[ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.placeholder,pr:.5},children:c}),ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex"},children:[ge.jsx(dn,{variation:"xxl",component:"p",sx:{fontWeight:500,lineHeight:1.2},children:s}),ge.jsx(dn,{variation:"xxl",component:"p",sx:{fontWeight:500,fontSize:{sm:"1.6rem",lg:"2.2rem"},lineHeight:{sm:1.15,lg:1}},children:u})]}),ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.placeholder,pl:.1},children:l})]}),ge.jsx(cn,{href:o,title:r,target:i,onClick:()=>{a&&n(a)},children:ge.jsx(Tp,{fullWidth:!0,variation:"outlined",sizing:"lg",children:r})})]})]})},exports.Popper=xo,exports.Portal=t=>{const[n,o]=e.useState(null),i=n?.contentWindow?.document?.body,r=df({key:"css",container:n?.contentWindow?.document?.head,prepend:!0});return ge.jsx(pf,{ref:o,children:i&&m.createPortal(ge.jsx(M.CacheProvider,{value:r,children:t.children}),i)})},exports.PoweredByWatermarkLogo=()=>ge.jsxs(t.Stack,{gap:.5,flexDirection:"row",children:[ge.jsx(t.SvgIcon,{sx:{width:67,height:12},viewBox:"0 0 67 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{d:"M2.09034 4.64868H4.09536C5.65956 4.64868 6.41322 4.00878 6.41322 2.84274C6.41322 1.69092 5.65956 1.05102 4.09536 1.05102H2.09034V4.64868ZM2.09034 5.6583V9H0.86742V0.0413991H4.1238C6.34212 0.0413991 7.6077 1.09368 7.6077 2.84274C7.6077 4.60602 6.34212 5.6583 4.1238 5.6583H2.09034ZM9.27266 5.90004C9.27266 7.27938 9.96944 8.26056 11.2208 8.26056C12.4864 8.26056 13.1974 7.27938 13.1974 5.90004C13.1974 4.50648 12.4864 3.53952 11.2208 3.53952C9.96944 3.53952 9.27266 4.50648 9.27266 5.90004ZM14.4061 5.90004C14.4061 7.83396 13.0552 9.17064 11.2208 9.17064C9.40064 9.17064 8.06396 7.83396 8.06396 5.90004C8.06396 3.96612 9.40064 2.61522 11.2208 2.61522C13.0552 2.61522 14.4061 3.96612 14.4061 5.90004ZM19.9082 2.78586L21.2449 7.49268H21.3018L22.738 2.78586H23.8329L21.8564 9H20.7188L19.3963 4.36428H19.3394L18.0312 9H16.8936L14.9028 2.78586H16.083L17.5477 7.49268H17.6046L18.9128 2.78586H19.9082ZM29.4445 6.78168L30.4257 6.89544C30.1271 8.31744 29.0748 9.17064 27.5248 9.17064C25.6762 9.17064 24.3253 7.91928 24.3253 5.98536C24.3253 4.023 25.6762 2.61522 27.4679 2.61522C29.4445 2.61522 30.4541 4.023 30.4541 5.71518V6.17022H25.5056C25.5624 7.40736 26.4299 8.24634 27.539 8.24634C28.5771 8.24634 29.2028 7.74864 29.4445 6.78168ZM25.534 5.445H29.2454C29.217 4.43538 28.634 3.51108 27.4679 3.51108C26.3445 3.51108 25.662 4.40694 25.534 5.445ZM35.5059 2.89962L35.3921 3.96612C35.0509 3.78126 34.8091 3.71016 34.4252 3.71016C33.5293 3.71016 32.861 4.5207 32.861 5.71518V9H31.6807V2.78586H32.861V4.05144C33.0885 3.34044 33.7284 2.61522 34.6243 2.61522C35.0082 2.61522 35.2926 2.71476 35.5059 2.89962ZM40.9288 6.78168L41.91 6.89544C41.6114 8.31744 40.5591 9.17064 39.0091 9.17064C37.1605 9.17064 35.8096 7.91928 35.8096 5.98536C35.8096 4.023 37.1605 2.61522 38.9522 2.61522C40.9288 2.61522 41.9384 4.023 41.9384 5.71518V6.17022H36.9899C37.0468 7.40736 37.9142 8.24634 39.0233 8.24634C40.0614 8.24634 40.6871 7.74864 40.9288 6.78168ZM37.0183 5.445H40.7297C40.7013 4.43538 40.1183 3.51108 38.9522 3.51108C37.8289 3.51108 37.1463 4.40694 37.0183 5.445ZM47.8993 6.07068V5.71518C47.8993 4.36428 47.0461 3.56796 45.9227 3.56796C44.6998 3.56796 44.0172 4.47804 44.0172 5.90004C44.0172 7.32204 44.6998 8.23212 45.9227 8.23212C47.0461 8.23212 47.8993 7.4358 47.8993 6.07068ZM47.8851 9V7.70598C47.6007 8.47386 46.8186 9.17064 45.6525 9.17064C43.8039 9.17064 42.8085 7.73442 42.8085 5.90004C42.8085 4.06566 43.8039 2.61522 45.6525 2.61522C46.8186 2.61522 47.6007 3.32622 47.8851 4.0941V0.0413991H49.0653V9H47.8851ZM54.3847 5.71518V6.07068C54.3847 7.4358 55.2521 8.23212 56.3755 8.23212C57.5984 8.23212 58.2668 7.32204 58.2668 5.90004C58.2668 4.47804 57.5984 3.56796 56.3755 3.56796C55.2521 3.56796 54.3847 4.36428 54.3847 5.71518ZM54.3847 7.70598L54.1288 9H53.2329V0.0413991H54.4132V4.0941C54.6833 3.32622 55.4797 2.61522 56.6457 2.61522C58.4801 2.61522 59.4897 4.06566 59.4897 5.90004C59.4897 7.73442 58.4801 9.17064 56.6315 9.17064C55.4797 9.17064 54.6691 8.48808 54.3847 7.70598ZM62.6822 11.389H61.5304L62.54 8.98578L59.9235 2.78586H61.1607L63.1372 7.56378H63.1941L65.0996 2.78586H66.2656L62.6822 11.389Z",fill:"#473F5C"})}),ge.jsxs(t.SvgIcon,{sx:{width:40,height:12},viewBox:"0 0 40 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[ge.jsx("g",{id:"Brand/Wordmark",clipPath:"url(#clip0_900_1816)",children:ge.jsx("path",{id:"Union",fillRule:"evenodd",clipRule:"evenodd",d:"M4.3189 9.56522C3.67851 9.11556 3.54429 8.98169 3.54429 7.99199V0H0V0.149886L0.00580287 0.153463C0.656931 0.554852 0.953183 0.737477 0.953183 1.72311V7.99199C0.953183 8.98169 0.818964 9.11556 0.17858 9.56522V9.7151H4.3189V9.56522ZM4.51113 6.71053C4.91378 9.01144 6.99646 10.1934 9.18264 9.80664C11.3677 9.41876 12.9226 7.58467 12.5199 5.28947C12.1173 2.99428 10.0346 1.80549 7.84841 2.19336C5.66223 2.58124 4.10847 4.40961 4.51113 6.71053ZM7.2103 6.23112C6.8247 4.01831 6.98053 3.01716 7.96215 2.84325C8.94377 2.66819 9.43515 3.55263 9.82074 5.76545C10.2063 7.97826 10.0516 8.97483 9.06889 9.15332C8.08613 9.33181 7.59589 8.44394 7.2103 6.23112ZM17.7306 9.80664C15.5455 10.1934 13.4629 9.01144 13.0591 6.71053C12.6553 4.40961 14.2102 2.58124 16.3963 2.19336C18.5825 1.80549 20.6641 2.99428 21.0678 5.28947C21.4716 7.58467 19.9156 9.41876 17.7306 9.80664ZM16.5101 2.84325C15.5273 3.01716 15.3726 4.01831 15.7582 6.23112C16.1438 8.44394 16.6341 9.33181 17.6168 9.15675C18.5996 8.98169 18.7543 7.98169 18.3687 5.76888C17.9831 3.55606 17.4928 2.66819 16.5101 2.84325ZM25.5683 11.8168C24.8234 11.3931 24.5553 11.2406 24.5553 10.2769L24.5575 8.4794C24.9443 9.25858 25.7189 9.873 26.9997 9.873C28.9356 9.873 30.47 8.40046 30.47 5.86842C30.47 3.29176 28.9743 2.13844 27.2681 2.13844C25.8679 2.13844 24.8988 2.93249 24.5575 4.02631L24.4973 2.28833H21.0724V2.43135L21.0731 2.43181C21.713 2.85024 21.9653 3.01524 21.9653 4.00458V10.2769C21.9653 11.2654 21.8322 11.4005 21.1907 11.8501V12H25.6267V11.8501L25.5683 11.8168ZM26.1784 8.9611C25.2696 8.9611 24.5553 7.92792 24.5553 6.72998V5.66247C24.5553 4.32952 25.1957 3.32494 26.1784 3.32494C27.2055 3.32494 27.7117 4.27002 27.7117 5.87185C27.7117 7.98741 27.1907 8.9611 26.1784 8.9611ZM38.6585 9.84325C39.1403 9.84325 39.5309 9.45034 39.5309 8.96567C39.5309 8.481 39.1403 8.0881 38.6585 8.0881C38.1767 8.0881 37.7861 8.481 37.7861 8.96567C37.7861 9.45034 38.1767 9.84325 38.6585 9.84325ZM34.6585 4.64621C33.661 4.35019 33.0998 4.18365 33.0998 3.5881C33.0998 3.08924 33.5548 2.86842 34.0552 2.86842C35.0244 2.86842 35.783 3.42334 36.6623 4.71167H36.8704V2.13501H36.7214L36.0515 2.62929C36.0223 2.61721 35.9931 2.6051 35.9639 2.59299C35.4126 2.36413 34.8607 2.13501 34.0257 2.13501C32.4321 2.13501 31.1661 3.12357 31.1661 4.59153C31.1661 5.90961 31.7929 6.65904 34.0416 7.24371C34.8765 7.45309 35.4566 7.60297 35.4566 8.24714C35.4566 8.84668 34.8765 9.13043 34.1758 9.13043C33.0998 9.13043 32.3138 8.39702 31.2799 7.00343H31.0524L31.2094 9.85011H31.3731L31.968 9.25057C32.4446 9.49085 33.1897 9.86499 34.1872 9.86499C36.0936 9.86499 37.4198 8.80091 37.4198 7.3032C37.4198 5.75973 36.4985 5.19107 34.6786 4.65217L34.6585 4.64621Z",fill:"#473F5C"})}),ge.jsx("defs",{children:ge.jsx("clipPath",{id:"clip0_900_1816",children:ge.jsx("rect",{width:"39.5321",height:"12",fill:"white"})})})]})]}),exports.Progress=vn,exports.ProgressBar=_o,exports.ProjectItem=e=>"list"===e.viewType?ge.jsx(Cf,{...e}):ge.jsx(jf,{...e}),exports.Radio=ph,exports.RadioGroup=Eh,exports.Rank=cm,exports.RichTextField=dm,exports.SectionHeader=({buttons:e,subtitle:n,title:o})=>ge.jsx(ge.Fragment,{children:ge.jsx(Sf,{sx:{justifyContent:"space-between"},children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsxs(kf,{sx:{justifyContent:"space-between",py:1},children:[ge.jsx(kf,{children:ge.jsxs(kf,{sx:{alignItems:"flex-start",flexDirection:"column",gap:0},children:[o&&ge.jsx(dn,{variation:"sm",component:"h2",weight:"bold",children:o}),n&&ge.jsx(Mf,{variation:"sm",component:"p",children:n})]})}),e&&ge.jsx(kf,{children:e})]})})})})})}),exports.Select=Yh,exports.Slider=vm,exports.SortableList=lm,exports.StarRating=bm,exports.Surface=an,exports.Switch=jm,exports.TextBarDivider=({typographyProps:e,text:o,sx:i})=>{const r=t.useTheme();return ge.jsx(t.Box,{sx:n.mergeSx(i,{width:"100%",position:"relative",display:"flex",gap:4,my:r.spacing(r.custom.margin.md),"&:before":{content:'""',width:"100%",background:r.custom.palette.stroke.default,height:"1px",display:"flex",alignSelf:"center"},"&:after":{content:'""',width:"100%",background:r.custom.palette.stroke.default,height:"1px",display:"flex",alignSelf:"center"}}),children:ge.jsx(dn,{align:"center",variation:"sm",component:"p",...e,children:o})})},exports.TextField=oh,exports.Textarea=Sm,exports.ThemeProvider=({mode:e="light",screenSize:n="lg",direction:o="ltr",children:i})=>{const r=If(e,n,o);return ge.jsx(zf.Provider,{value:r,children:ge.jsx(M.CacheProvider,{value:"rtl"===o?Rf:Vf,children:ge.jsxs(s.ThemeProvider,{theme:r.theme,children:[ge.jsx(t.CssBaseline,{}),ge.jsx(Ef,{}),i]})})})},exports.TickGroup=({heading:e,ticks:n})=>ge.jsxs(t.Stack,{sx:{display:"flex",gap:{sm:2,lg:4},py:{sm:2,lg:4}},children:[ge.jsx(dn,{variation:"xl",component:"p",sx:{textAlign:"center"},children:e}),ge.jsx(t.Box,{sx:{columnGap:4,display:"flex",flex:1,flexWrap:"wrap",justifyContent:"center",rowGap:2},children:n.map(((n,o)=>ge.jsxs(t.Box,{sx:{display:"flex",alignItems:"center",gap:1,px:{sm:0,lg:2}},children:[ge.jsx(en,{name:"badge-tick",size:32}),ge.jsx(dn,{variation:"xxl",component:"p",children:n})]},`tick-group-${e}-${o}`)))})]}),exports.Toast=({buttons:e,message:n,status:o="neutral",variation:i="sm"})=>{const r=t.useTheme();return ge.jsx(t.Stack,{sx:{backgroundColor:r.custom.palette.surface.overlay,borderRadius:r.spacing(r.custom.radius.lg),boxShadow:r.custom.elevation.overlay,color:r.custom.palette.text.primaryInverted,display:"flex",flex:1,gap:1,p:2},children:ge.jsxs(t.Box,{sx:{display:"flex",flex:1,flexDirection:"sm"===i?"row":"column",gap:2},children:[ge.jsxs(t.Box,{sx:{display:"flex",flex:1,gap:1},children:["neutral"!==o&&ge.jsx(hf,{status:o}),ge.jsx(t.Box,{sx:{display:"flex"},children:ge.jsx(dn,{variation:"md",component:"p",sx:{px:1,pt:.5},children:n})})]}),e&&ge.jsx(t.Box,{sx:{alignItems:"center",display:"flex",gap:2,justifyContent:"flex-end"},children:e})]})})},exports.Tooltip=yn,exports.Typography=dn,exports.UserMenu=Io,exports.backgroundCreator=Xp,exports.base=Q,exports.blue=H,exports.blueRamp=Z,exports.boxShadow=re,exports.breakpoints=X,exports.chooseArticle=Gp,exports.compareArrayMembers=function(e,t){const n=new Set(e),o=new Set(t);return e.every((e=>o.has(e)))&&t.every((e=>n.has(e)))},exports.darkNeutral=R,exports.darkNeutralAlpha=F,exports.defaultInputValidation=qp,exports.easing=se,exports.elevation=oe,exports.elevationFilter=ie,exports.emailValidation={pattern:{value:/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,30}$/i,message:"Please enter a valid email"}},exports.fonts=ce,exports.generateRamp=_,exports.green=W,exports.greenRamp=Y,exports.iconSizeMap=Qt,exports.margin=ee,exports.neutral=I,exports.neutralAlpha=V,exports.neutralRamp=N,exports.padding=te,exports.passwordValidation=e=>({minLength:{value:e||8,message:`Password must have at least ${e||8} characters`},equal:{value:"password",message:"You cannot choose 'password' as your password"}}),exports.peach=O,exports.peachRamp=q,exports.purple=L,exports.purpleRamp=U,exports.radius=ne,exports.red=D,exports.redRamp=G,exports.semantic=ae,exports.space=J,exports.useBreakpoint=Wo,exports.useDropdownMenu=()=>{const[t,n]=e.useState(null);return{open:Boolean(t),handleClick:e=>{n(e.currentTarget)},handleClose:()=>{n(null)},anchorEl:t}},exports.usePrevious=vh,exports.useScreenSize=Bf,exports.yellow=$,exports.yellowRamp=K;
23
+ */function fi(){if(ni)return ti;ni=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return ti=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach((function(e){o[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(o,i){for(var r,s,a=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(o),l=1;l<arguments.length;l++){for(var c in r=Object(arguments[l]))t.call(r,c)&&(a[c]=r[c]);if(e){s=e(r);for(var u=0;u<s.length;u++)n.call(r,s[u])&&(a[s[u]]=r[s[u]])}}return a},ti}function gi(){if(ii)return oi;ii=1;return oi="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function xi(){return si?ri:(si=1,ri=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var vi=mi();Yo.exports=function(){if(ui)return ci;ui=1;var e=mi(),t=fi(),n=gi(),o=xi(),i=function(){if(li)return ai;li=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=gi(),n={},o=xi();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function i(i,r,s,a,l){if("production"!==process.env.NODE_ENV)for(var c in i)if(o(i,c)){var u;try{if("function"!=typeof i[c]){var d=Error((a||"React class")+": "+s+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=i[c](r,c,a,s,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((a||"React class")+": type specification of "+s+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var p=l?l():"";e("Failed "+s+" type: "+u.message+(null!=p?p:""))}}}return i.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},ai=i}(),r=function(){};function s(){return null}return"production"!==process.env.NODE_ENV&&(r=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),ci=function(a,l){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:f("array"),bigint:f("bigint"),bool:f("boolean"),func:f("function"),number:f("number"),object:f("object"),string:f("string"),symbol:f("symbol"),any:m(s),arrayOf:function(e){return m((function(t,o,i,r,s){if("function"!=typeof e)return new h("Property `"+s+"` of component `"+i+"` has invalid PropType notation inside arrayOf.");var a=t[o];if(!Array.isArray(a))return new h("Invalid "+r+" `"+s+"` of type `"+v(a)+"` supplied to `"+i+"`, expected an array.");for(var l=0;l<a.length;l++){var c=e(a,l,i,r,s+"["+l+"]",n);if(c instanceof Error)return c}return null}))},element:m((function(e,t,n,o,i){var r=e[t];return a(r)?null:new h("Invalid "+o+" `"+i+"` of type `"+v(r)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:m((function(t,n,o,i,r){var s=t[n];return e.isValidElementType(s)?null:new h("Invalid "+i+" `"+r+"` of type `"+v(s)+"` supplied to `"+o+"`, expected a single ReactElement type.")})),instanceOf:function(e){return m((function(t,n,o,i,r){if(!(t[n]instanceof e)){var s=e.name||u;return new h("Invalid "+i+" `"+r+"` of type `"+((a=t[n]).constructor&&a.constructor.name?a.constructor.name:u)+"` supplied to `"+o+"`, expected instance of `"+s+"`.")}var a;return null}))},node:m((function(e,t,n,o,i){return x(e[t])?null:new h("Invalid "+o+" `"+i+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return m((function(t,i,r,s,a){if("function"!=typeof e)return new h("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var l=t[i],c=v(l);if("object"!==c)return new h("Invalid "+s+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected an object.");for(var u in l)if(o(l,u)){var d=e(l,u,r,s,a+"."+u,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?m((function(t,n,o,i,r){for(var s=t[n],a=0;a<e.length;a++)if(p(s,e[a]))return null;var l=JSON.stringify(e,(function(e,t){return"symbol"===y(t)?String(t):t}));return new h("Invalid "+i+" `"+r+"` of value `"+String(s)+"` supplied to `"+o+"`, expected one of "+l+".")})):("production"!==process.env.NODE_ENV&&r(arguments.length>1?"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]).":"Invalid argument supplied to oneOf, expected an array."),s)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&r("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var t=0;t<e.length;t++){var i=e[t];if("function"!=typeof i)return r("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+b(i)+" at index "+t+"."),s}return m((function(t,i,r,s,a){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,i,r,s,a,n);if(null==u)return null;u.data&&o(u.data,"expectedType")&&l.push(u.data.expectedType)}return new h("Invalid "+s+" `"+a+"` supplied to `"+r+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")}))},shape:function(e){return m((function(t,o,i,r,s){var a=t[o],l=v(a);if("object"!==l)return new h("Invalid "+r+" `"+s+"` of type `"+l+"` supplied to `"+i+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return g(i,r,s,c,y(u));var d=u(a,c,i,r,s+"."+c,n);if(d)return d}return null}))},exact:function(e){return m((function(i,r,s,a,l){var c=i[r],u=v(c);if("object"!==u)return new h("Invalid "+a+" `"+l+"` of type `"+u+"` supplied to `"+s+"`, expected `object`.");var d=t({},i[r],e);for(var p in d){var m=e[p];if(o(e,p)&&"function"!=typeof m)return g(s,a,l,p,y(m));if(!m)return new h("Invalid "+a+" `"+l+"` key `"+p+"` supplied to `"+s+"`.\nBad object: "+JSON.stringify(i[r],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var f=m(c,p,s,a,l+"."+p,n);if(f)return f}return null}))}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function m(e){if("production"!==process.env.NODE_ENV)var t={},o=0;function i(i,s,a,c,d,p,m){if(c=c||u,p=p||a,m!==n){if(l){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}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=c+":"+a;!t[g]&&o<3&&(r("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+c+"`. 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."),t[g]=!0,o++)}}return null==s[a]?i?null===s[a]?new h("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `null`."):new h("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(s,a,c,d,p)}var s=i.bind(null,!1);return s.isRequired=i.bind(null,!0),s}function f(e){return m((function(t,n,o,i,r,s){var a=t[n];return v(a)!==e?new h("Invalid "+i+" `"+r+"` of type `"+y(a)+"` supplied to `"+o+"`, expected `"+e+"`.",{expectedType:e}):null}))}function g(e,t,n,o,i){return new h((e||"React class")+": "+t+" type `"+n+"."+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+i+"`.")}function x(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(x);if(null===e||a(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,o=t.call(e);if(t!==e.entries){for(;!(n=o.next()).done;)if(!x(n.value))return!1}else for(;!(n=o.next()).done;){var i=n.value;if(i&&!x(i[1]))return!1}return!0;default:return!1}}function v(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function y(e){if(null==e)return""+e;var t=v(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function b(e){var t=y(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,d.checkPropTypes=i,d.resetWarningCache=i.resetWarningCache,d.PropTypes=d,d},ci}()(vi.isElement,!0)}else Yo.exports=function(){if(pi)return di;pi=1;var e=gi();function t(){}function n(){}return n.resetWarningCache=t,di=function(){function o(t,n,o,i,r,s){if(s!==e){var a=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 a.name="Invariant Violation",a}}function i(){return o}o.isRequired=o;var r={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:i,element:o,elementType:o,instanceOf:i,node:o,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return r.PropTypes=r,r}}()();var yi=ue(Yo.exports);function bi(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=bi(e[t]))&&(o&&(o+=" "),o+=n)}else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function wi(){for(var e,t,n=0,o="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=bi(e))&&(o&&(o+=" "),o+=t);return o}const ji=e=>e,Ci=(()=>{let e=ji;return{configure(t){e=t},generate:t=>e(t),reset(){e=ji}}})(),Si={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 ki(e,t,n="Mui"){const o=Si[t];return o?`${n}-${o}`:`${Ci.generate(e)}-${t}`}const Mi=A.createContext({});function Ti(e){return ki("MuiTimeline",e)}function Pi(e){return"alternate-reverse"===e?"positionAlternateReverse":`position${a.capitalize(e)}`}"production"!==process.env.NODE_ENV&&(Mi.displayName="TimelineContext"),function(e,t,n="Mui"){const o={};t.forEach((t=>{o[t]=ki(e,t,n)}))}("MuiTimeline",["root","positionLeft","positionRight","positionAlternate","positionAlternateReverse"]);const Bi=["position","className"],Ai=e=>{const{position:t,classes:n}=e;return function(e,t,n){const o={};return Object.keys(e).forEach((i=>{o[i]=e[i].reduce(((e,o)=>{if(o){const i=t(o);""!==i&&e.push(i),n&&n[o]&&e.push(n[o])}return e}),[]).join(" ")})),o}({root:["root",t&&Pi(t)]},Ti,n)},Ei=s.styled("ul",{name:"MuiTimeline",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.position&&t[Pi(n.position)]]}})({display:"flex",flexDirection:"column",padding:"6px 16px",flexGrow:1}),zi=A.forwardRef((function(e,t){const n=s.useThemeProps({props:e,name:"MuiTimeline"}),{position:o="right",className:i}=n,r=function(e,t){if(null==e)return{};var n={};for(var o in e)if({}.hasOwnProperty.call(e,o)){if(-1!==t.indexOf(o))continue;n[o]=e[o]}return n}(n,Bi),a=Ko({},n,{position:o}),l=Ai(a),c=A.useMemo((()=>({position:o})),[o]);return ge.jsx(Mi.Provider,{value:c,children:ge.jsx(Ei,Ko({className:wi(l.root,i),ownerState:a,ref:t},r))})}));"production"!==process.env.NODE_ENV&&(zi.propTypes={children:yi.node,classes:yi.object,className:yi.string,position:yi.oneOf(["alternate-reverse","alternate","left","right"]),sx:yi.oneOfType([yi.arrayOf(yi.oneOfType([yi.func,yi.object,yi.bool])),yi.func,yi.object])});const Ii=e.createContext({});const Ri=e.createContext(null),Vi=e.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});const Fi="undefined"!=typeof window,Li=Fi?e.useLayoutEffect:e.useEffect,Di=e=>e;let Oi=Di,$i=Di;"production"!==process.env.NODE_ENV&&(Oi=(e,t)=>{e||"undefined"==typeof console||console.warn(t)},$i=(e,t)=>{if(!e)throw new Error(t)});const Hi=!1;const Wi=["read","resolveKeyframes","update","preRender","render","postRender"];function Ni(e,t){let n=!1,o=!0;const i={delta:0,timestamp:0,isProcessing:!1},r=()=>n=!0,s=Wi.reduce(((e,t)=>(e[t]=function(e){let t=new Set,n=new Set,o=!1,i=!1;const r=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(t){r.has(t)&&(l.schedule(t),e()),t(s)}const l={schedule:(e,i=!1,s=!1)=>{const a=s&&o?t:n;return i&&r.add(e),a.has(e)||a.add(e),e},cancel:e=>{n.delete(e),r.delete(e)},process:e=>{s=e,o?i=!0:(o=!0,[t,n]=[n,t],t.forEach(a),t.clear(),o=!1,i&&(i=!1,l.process(e)))}};return l}(r),e)),{}),{read:a,resolveKeyframes:l,update:c,preRender:u,render:d,postRender:p}=s,h=()=>{const r=performance.now();n=!1,i.delta=o?1e3/60:Math.max(Math.min(r-i.timestamp,40),1),i.timestamp=r,i.isProcessing=!0,a.process(i),l.process(i),c.process(i),u.process(i),d.process(i),p.process(i),i.isProcessing=!1,n&&t&&(o=!1,e(h))};return{schedule:Wi.reduce(((t,r)=>{const a=s[r];return t[r]=(t,r=!1,s=!1)=>(n||(n=!0,o=!0,i.isProcessing||e(h)),a.schedule(t,r,s)),t}),{}),cancel:e=>{for(let t=0;t<Wi.length;t++)s[Wi[t]].cancel(e)},state:i,steps:s}}const{schedule:_i,cancel:Ui,state:Gi,steps:qi}=Ni("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:Di,!0),Ki=e.createContext({strict:!1}),Zi={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"]},Yi={};for(const e in Zi)Yi[e]={isEnabled:t=>Zi[e].some((e=>!!t[e]))};const Xi=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 Ji(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Xi.has(e)}let Qi=e=>!Ji(e);try{(er=require("@emotion/is-prop-valid").default)&&(Qi=e=>e.startsWith("on")?!Ji(e):er(e))}catch(e){}var er;const tr=new Set;function nr(e,t,n){e||tr.has(t)||(console.warn(t),tr.add(t))}function or(e){if("undefined"==typeof Proxy)return e;const t=new Map;return new Proxy(((...t)=>("production"!==process.env.NODE_ENV&&nr(!1,"motion() is deprecated. Use motion.create() instead."),e(...t))),{get:(n,o)=>"create"===o?e:(t.has(o)||t.set(o,e(o)),t.get(o))})}const ir=e.createContext({});function rr(e){return"string"==typeof e||Array.isArray(e)}function sr(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}const ar=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],lr=["initial",...ar];function cr(e){return sr(e.animate)||lr.some((t=>rr(e[t])))}function ur(e){return Boolean(cr(e)||e.variants)}function dr(t){const{initial:n,animate:o}=function(e,t){if(cr(e)){const{initial:t,animate:n}=e;return{initial:!1===t||rr(t)?t:void 0,animate:rr(n)?n:void 0}}return!1!==e.inherit?t:{}}(t,e.useContext(ir));return e.useMemo((()=>({initial:n,animate:o})),[pr(n),pr(o)])}function pr(e){return Array.isArray(e)?e.join(" "):e}const hr=Symbol.for("motionComponentSymbol");function mr(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function fr(t,n,o){return e.useCallback((e=>{e&&t.onMount&&t.onMount(e),n&&(e?n.mount(e):n.unmount()),o&&("function"==typeof o?o(e):mr(o)&&(o.current=e))}),[n])}const gr=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),xr="data-"+gr("framerAppearId"),{schedule:vr,cancel:yr}=Ni(queueMicrotask,!1),br=e.createContext({});function wr(t,n,o,i,r){var s,a;const{visualElement:l}=e.useContext(ir),c=e.useContext(Ki),u=e.useContext(Ri),d=e.useContext(Vi).reducedMotion,p=e.useRef(null);i=i||c.renderer,!p.current&&i&&(p.current=i(t,{visualState:n,parent:l,props:o,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:d}));const h=p.current,m=e.useContext(br);!h||h.projection||!r||"html"!==h.type&&"svg"!==h.type||function(e,t,n,o){const{layoutId:i,layout:r,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:jr(e.parent)),e.projection.setOptions({layoutId:i,layout:r,alwaysMeasureLayout:Boolean(s)||a&&mr(a),visualElement:e,animationType:"string"==typeof r?r:"both",initialPromotionConfig:o,layoutScroll:l,layoutRoot:c})}(p.current,o,r,m);const f=e.useRef(!1);e.useInsertionEffect((()=>{h&&f.current&&h.update(o,u)}));const g=o[xr],x=e.useRef(Boolean(g)&&!(null===(s=window.MotionHandoffIsComplete)||void 0===s?void 0:s.call(window,g))&&(null===(a=window.MotionHasOptimisedAnimation)||void 0===a?void 0:a.call(window,g)));return Li((()=>{h&&(f.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),vr.render(h.render),x.current&&h.animationState&&h.animationState.animateChanges())})),e.useEffect((()=>{h&&(!x.current&&h.animationState&&h.animationState.animateChanges(),x.current&&(queueMicrotask((()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)})),x.current=!1))})),h}function jr(e){if(e)return!1!==e.options.allowProjection?e.projection:jr(e.parent)}function Cr({preloadedFeatures:t,createVisualElement:n,useRender:o,useVisualState:i,Component:r}){var s,a;function l(s,a){let l;const c={...e.useContext(Vi),...s,layoutId:Sr(s)},{isStatic:u}=c,d=dr(s),p=i(s,u);if(!u&&Fi){!function(t,n){const o=e.useContext(Ki).strict;if("production"!==process.env.NODE_ENV&&n&&o){const e="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";t.ignoreStrict?Oi(!1,e):$i(!1,e)}}(c,t);const o=function(e){const{drag:t,layout:n}=Yi;if(!t&&!n)return{};const o={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}(c);l=o.MeasureLayout,d.visualElement=wr(r,p,c,n,o.ProjectionNode)}return ge.jsxs(ir.Provider,{value:d,children:[l&&d.visualElement?ge.jsx(l,{visualElement:d.visualElement,...c}):null,o(r,s,fr(p,d.visualElement,a),p,u,d.visualElement)]})}t&&function(e){for(const t in e)Yi[t]={...Yi[t],...e[t]}}(t),l.displayName=`motion.${"string"==typeof r?r:`create(${null!==(a=null!==(s=r.displayName)&&void 0!==s?s:r.name)&&void 0!==a?a:""})`}`;const c=e.forwardRef(l);return c[hr]=r,c}function Sr({layoutId:t}){const n=e.useContext(Ii).id;return n&&void 0!==t?n+"-"+t:t}const kr=["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 Mr(e){return"string"==typeof e&&!e.includes("-")&&!!(kr.indexOf(e)>-1||/[A-Z]/u.test(e))}function Tr(e){const t=[{},{}];return null==e||e.values.forEach(((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()})),t}function Pr(e,t,n,o){if("function"==typeof t){const[i,r]=Tr(o);t=t(void 0!==n?n:e.custom,i,r)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){const[i,r]=Tr(o);t=t(void 0!==n?n:e.custom,i,r)}return t}const Br=e=>Array.isArray(e),Ar=e=>Boolean(e&&e.getVelocity);function Er(e){const t=Ar(e)?e.get():e;return n=t,Boolean(n&&"object"==typeof n&&n.mix&&n.toValue)?t.toValue():t;var n}const zr=t=>(n,o)=>{const i=e.useContext(ir),r=e.useContext(Ri),s=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},o,i,r){const s={latestValues:Ir(o,i,r,e),renderState:t()};return n&&(s.onMount=e=>n({props:o,current:e,...s}),s.onUpdate=e=>n(e)),s}(t,n,i,r);return o?s():function(t){const n=e.useRef(null);return null===n.current&&(n.current=t()),n.current}(s)};function Ir(e,t,n,o){const i={},r=o(e,{});for(const e in r)i[e]=Er(r[e]);let{initial:s,animate:a}=e;const l=cr(e),c=ur(e);t&&c&&!l&&!1!==e.inherit&&(void 0===s&&(s=t.initial),void 0===a&&(a=t.animate));let u=!!n&&!1===n.initial;u=u||!1===s;const d=u?a:s;if(d&&"boolean"!=typeof d&&!sr(d)){const t=Array.isArray(d)?d:[d];for(let n=0;n<t.length;n++){const o=Pr(e,t[n]);if(o){const{transitionEnd:e,transition:t,...n}=o;for(const e in n){let t=n[e];if(Array.isArray(t)){t=t[u?t.length-1:0]}null!==t&&(i[e]=t)}for(const t in e)i[t]=e[t]}}}return i}const Rr=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Vr=new Set(Rr),Fr=e=>t=>"string"==typeof t&&t.startsWith(e),Lr=Fr("--"),Dr=Fr("var(--"),Or=e=>!!Dr(e)&&$r.test(e.split("/*")[0].trim()),$r=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Hr=(e,t)=>t&&"number"==typeof e?t.transform(e):e,Wr=(e,t,n)=>n>t?t:n<e?e:n,Nr={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},_r={...Nr,transform:e=>Wr(0,1,e)},Ur={...Nr,default:1},Gr=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),qr=Gr("deg"),Kr=Gr("%"),Zr=Gr("px"),Yr=Gr("vh"),Xr=Gr("vw"),Jr={...Kr,parse:e=>Kr.parse(e)/100,transform:e=>Kr.transform(100*e)},Qr={borderWidth:Zr,borderTopWidth:Zr,borderRightWidth:Zr,borderBottomWidth:Zr,borderLeftWidth:Zr,borderRadius:Zr,radius:Zr,borderTopLeftRadius:Zr,borderTopRightRadius:Zr,borderBottomRightRadius:Zr,borderBottomLeftRadius:Zr,width:Zr,maxWidth:Zr,height:Zr,maxHeight:Zr,top:Zr,right:Zr,bottom:Zr,left:Zr,padding:Zr,paddingTop:Zr,paddingRight:Zr,paddingBottom:Zr,paddingLeft:Zr,margin:Zr,marginTop:Zr,marginRight:Zr,marginBottom:Zr,marginLeft:Zr,backgroundPositionX:Zr,backgroundPositionY:Zr},es={rotate:qr,rotateX:qr,rotateY:qr,rotateZ:qr,scale:Ur,scaleX:Ur,scaleY:Ur,scaleZ:Ur,skew:qr,skewX:qr,skewY:qr,distance:Zr,translateX:Zr,translateY:Zr,translateZ:Zr,x:Zr,y:Zr,z:Zr,perspective:Zr,transformPerspective:Zr,opacity:_r,originX:Jr,originY:Jr,originZ:Zr},ts={...Nr,transform:Math.round},ns={...Qr,...es,zIndex:ts,size:Zr,fillOpacity:_r,strokeOpacity:_r,numOctaves:ts},os={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},is=Rr.length;function rs(e,t,n){const{style:o,vars:i,transformOrigin:r}=e;let s=!1,a=!1;for(const e in t){const n=t[e];if(Vr.has(e))s=!0;else if(Lr(e))i[e]=n;else{const t=Hr(n,ns[e]);e.startsWith("origin")?(a=!0,r[e]=t):o[e]=t}}if(t.transform||(s||n?o.transform=function(e,t,n){let o="",i=!0;for(let r=0;r<is;r++){const s=Rr[r],a=e[s];if(void 0===a)continue;let l=!0;if(l="number"==typeof a?a===(s.startsWith("scale")?1:0):0===parseFloat(a),!l||n){const e=Hr(a,ns[s]);l||(i=!1,o+=`${os[s]||s}(${e}) `),n&&(t[s]=e)}}return o=o.trim(),n?o=n(t,i?"":o):i&&(o="none"),o}(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:e="50%",originY:t="50%",originZ:n=0}=r;o.transformOrigin=`${e} ${t} ${n}`}}const ss={offset:"stroke-dashoffset",array:"stroke-dasharray"},as={offset:"strokeDashoffset",array:"strokeDasharray"};function ls(e,t,n){return"string"==typeof e?e:Zr.transform(t+n*e)}function cs(e,{attrX:t,attrY:n,attrScale:o,originX:i,originY:r,pathLength:s,pathSpacing:a=1,pathOffset:l=0,...c},u,d){if(rs(e,c,d),u)return void(e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox));e.attrs=e.style,e.style={};const{attrs:p,style:h,dimensions:m}=e;p.transform&&(m&&(h.transform=p.transform),delete p.transform),m&&(void 0!==i||void 0!==r||h.transform)&&(h.transformOrigin=function(e,t,n){return`${ls(t,e.x,e.width)} ${ls(n,e.y,e.height)}`}(m,void 0!==i?i:.5,void 0!==r?r:.5)),void 0!==t&&(p.x=t),void 0!==n&&(p.y=n),void 0!==o&&(p.scale=o),void 0!==s&&function(e,t,n=1,o=0,i=!0){e.pathLength=1;const r=i?ss:as;e[r.offset]=Zr.transform(-o);const s=Zr.transform(t),a=Zr.transform(n);e[r.array]=`${s} ${a}`}(p,s,a,l,!1)}const us=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),ds=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}}),ps=e=>"string"==typeof e&&"svg"===e.toLowerCase();function hs(e,{style:t,vars:n},o,i){Object.assign(e.style,t,i&&i.getProjectionStyles(o));for(const t in n)e.style.setProperty(t,n[t])}const ms=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"]);function fs(e,t,n,o){hs(e,t,void 0,o);for(const n in t.attrs)e.setAttribute(ms.has(n)?n:gr(n),t.attrs[n])}const gs={};function xs(e,{layout:t,layoutId:n}){return Vr.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!gs[e]||"opacity"===e)}function vs(e,t,n){var o;const{style:i}=e,r={};for(const s in i)(Ar(i[s])||t.style&&Ar(t.style[s])||xs(s,e)||void 0!==(null===(o=null==n?void 0:n.getValue(s))||void 0===o?void 0:o.liveStyle))&&(r[s]=i[s]);return r}function ys(e,t,n){const o=vs(e,t,n);for(const n in e)if(Ar(e[n])||Ar(t[n])){o[-1!==Rr.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=e[n]}return o}const bs=["x","y","width","height","cx","cy","r"],ws={useVisualState:zr({scrapeMotionValuesFromProps:ys,createRenderState:ds,onUpdate:({props:e,prevProps:t,current:n,renderState:o,latestValues:i})=>{if(!n)return;let r=!!e.drag;if(!r)for(const e in i)if(Vr.has(e)){r=!0;break}if(!r)return;let s=!t;if(t)for(let n=0;n<bs.length;n++){const o=bs[n];e[o]!==t[o]&&(s=!0)}s&&_i.read((()=>{!function(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(e){t.dimensions={x:0,y:0,width:0,height:0}}}(n,o),_i.render((()=>{cs(o,i,ps(n.tagName),e.transformTemplate),fs(n,o)}))}))}})},js={useVisualState:zr({scrapeMotionValuesFromProps:vs,createRenderState:us})};function Cs(e,t,n){for(const o in t)Ar(t[o])||xs(o,n)||(e[o]=t[o])}function Ss(t,n){const o={};return Cs(o,t.style||{},t),Object.assign(o,function({transformTemplate:t},n){return e.useMemo((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{}};return rs(e,n,t),Object.assign({},e.vars,e.style)}),[n])}(t,n)),o}function ks(e,t){const n={},o=Ss(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=o,n}function Ms(t,n,o,i){const r=e.useMemo((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return cs(e,n,ps(i),t.transformTemplate),{...e.attrs,style:{...e.style}}}),[n]);if(t.style){const e={};Cs(e,t.style,t),r.style={...e,...r.style}}return r}function Ts(t=!1){return(n,o,i,{latestValues:r},s)=>{const a=(Mr(n)?Ms:ks)(o,r,s,n),l=function(e,t,n){const o={};for(const i in e)"values"===i&&"object"==typeof e.values||(Qi(i)||!0===n&&Ji(i)||!t&&!Ji(i)||e.draggable&&i.startsWith("onDrag"))&&(o[i]=e[i]);return o}(o,"string"==typeof n,t),c=n!==e.Fragment?{...l,...a,ref:i}:{},{children:u}=o,d=e.useMemo((()=>Ar(u)?u.get():u),[u]);return e.createElement(n,{...c,children:d})}}function Ps(e,t){return function(n,{forwardMotionProps:o}={forwardMotionProps:!1}){return Cr({...Mr(n)?ws:js,preloadedFeatures:e,useRender:Ts(o),createVisualElement:t,Component:n})}}function Bs(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}function As(e,t,n){const o=e.getProps();return Pr(o,t,void 0!==n?n:o.custom,e)}function Es(e,t){return e?e[t]||e.default||e:void 0}const zs=new Set(["width","height","top","left","right","bottom",...Rr]);let Is;function Rs(){Is=void 0}const Vs={now:()=>(void 0===Is&&Vs.set(Gi.isProcessing||Hi?Gi.timestamp:performance.now()),Is),set:e=>{Is=e,queueMicrotask(Rs)}};function Fs(e,t){-1===e.indexOf(t)&&e.push(t)}function Ls(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Ds{constructor(){this.subscriptions=[]}add(e){return Fs(this.subscriptions,e),()=>Ls(this.subscriptions,e)}notify(e,t,n){const o=this.subscriptions.length;if(o)if(1===o)this.subscriptions[0](e,t,n);else for(let i=0;i<o;i++){const o=this.subscriptions[i];o&&o(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}function Os(e,t){return t?e*(1e3/t):0}class $s{constructor(e,t={}){this.version="12.0.6",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{const n=Vs.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){var t;this.current=e,this.updatedAt=Vs.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=(t=this.current,!isNaN(parseFloat(t))))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return"production"!==process.env.NODE_ENV&&nr(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new Ds);const n=this.events[e].add(t);return"change"===e?()=>{n(),_i.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=Vs.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;const t=Math.min(this.updatedAt-this.prevUpdatedAt,30);return Os(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),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(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Hs(e,t){return new $s(e,t)}function Ws(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Hs(n))}function Ns(e,t){const n=e.getValue("willChange");if(o=n,Boolean(Ar(o)&&o.add))return n.add(t);var o}function _s(e){return e.props[xr]}function Us(e){let t;return()=>(void 0===t&&(t=e()),t)}const Gs=Us((()=>void 0!==window.ScrollTimeline));class qs{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map((e=>"finished"in e?e.finished:e)))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e,t){const n=this.animations.map((n=>Gs()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0));return()=>{n.forEach(((e,t)=>{e&&e(),this.animations[t].stop()}))}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach((t=>t[e]()))}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class Ks extends qs{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}const Zs=e=>1e3*e,Ys=e=>e/1e3;function Xs(e){return"function"==typeof e}function Js(e,t){e.timeline=t,e.onfinish=null}const Qs=e=>Array.isArray(e)&&"number"==typeof e[0],ea={linearEasing:void 0};function ta(e,t){const n=Us(e);return()=>{var e;return null!==(e=ea[t])&&void 0!==e?e:n()}}const na=ta((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(e){return!1}return!0}),"linearEasing"),oa=(e,t,n)=>{const o=t-e;return 0===o?1:(n-e)/o},ia=(e,t,n=10)=>{let o="";const i=Math.max(Math.round(t/n),2);for(let t=0;t<i;t++)o+=e(oa(0,i-1,t))+", ";return`linear(${o.substring(0,o.length-2)})`};function ra(e){return Boolean("function"==typeof e&&na()||!e||"string"==typeof e&&(e in aa||na())||Qs(e)||Array.isArray(e)&&e.every(ra))}const sa=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,aa={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:sa([0,.65,.55,1]),circOut:sa([.55,0,1,.45]),backIn:sa([.31,.01,.66,-.59]),backOut:sa([.33,1.53,.69,.99])};function la(e,t){return e?"function"==typeof e&&na()?ia(e,t):Qs(e)?sa(e):Array.isArray(e)?e.map((e=>la(e,t)||aa.easeOut)):aa[e]:void 0}const ca=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function ua(e,t,n,o){if(e===t&&n===o)return Di;const i=t=>function(e,t,n,o,i){let r,s,a=0;do{s=t+(n-t)/2,r=ca(s,o,i)-e,r>0?n=s:t=s}while(Math.abs(r)>1e-7&&++a<12);return s}(t,0,1,e,n);return e=>0===e||1===e?e:ca(i(e),t,o)}const da=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,pa=e=>t=>1-e(1-t),ha=ua(.33,1.53,.69,.99),ma=pa(ha),fa=da(ma),ga=e=>(e*=2)<1?.5*ma(e):.5*(2-Math.pow(2,-10*(e-1))),xa=e=>1-Math.sin(Math.acos(e)),va=pa(xa),ya=da(xa),ba=e=>/^0[^.\s]+$/u.test(e);const wa=e=>Math.round(1e5*e)/1e5,ja=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const Ca=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Sa=(e,t)=>n=>Boolean("string"==typeof n&&Ca.test(n)&&n.startsWith(e)||t&&!function(e){return null==e}(n)&&Object.prototype.hasOwnProperty.call(n,t)),ka=(e,t,n)=>o=>{if("string"!=typeof o)return o;const[i,r,s,a]=o.match(ja);return{[e]:parseFloat(i),[t]:parseFloat(r),[n]:parseFloat(s),alpha:void 0!==a?parseFloat(a):1}},Ma={...Nr,transform:e=>Math.round((e=>Wr(0,255,e))(e))},Ta={test:Sa("rgb","red"),parse:ka("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+Ma.transform(e)+", "+Ma.transform(t)+", "+Ma.transform(n)+", "+wa(_r.transform(o))+")"};const Pa={test:Sa("#"),parse:function(e){let t="",n="",o="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,o+=o,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:i?parseInt(i,16)/255:1}},transform:Ta.transform},Ba={test:Sa("hsl","hue"),parse:ka("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+Kr.transform(wa(t))+", "+Kr.transform(wa(n))+", "+wa(_r.transform(o))+")"},Aa={test:e=>Ta.test(e)||Pa.test(e)||Ba.test(e),parse:e=>Ta.test(e)?Ta.parse(e):Ba.test(e)?Ba.parse(e):Pa.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?Ta.transform(e):Ba.transform(e)},Ea=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const za="number",Ia="color",Ra=/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 Va(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},i=[];let r=0;const s=t.replace(Ra,(e=>(Aa.test(e)?(o.color.push(r),i.push(Ia),n.push(Aa.parse(e))):e.startsWith("var(")?(o.var.push(r),i.push("var"),n.push(e)):(o.number.push(r),i.push(za),n.push(parseFloat(e))),++r,"${}"))).split("${}");return{values:n,split:s,indexes:o,types:i}}function Fa(e){return Va(e).values}function La(e){const{split:t,types:n}=Va(e),o=t.length;return e=>{let i="";for(let r=0;r<o;r++)if(i+=t[r],void 0!==e[r]){const t=n[r];i+=t===za?wa(e[r]):t===Ia?Aa.transform(e[r]):e[r]}return i}}const Da=e=>"number"==typeof e?0:e;const Oa={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(ja))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(Ea))||void 0===n?void 0:n.length)||0)>0},parse:Fa,createTransformer:La,getAnimatableNone:function(e){const t=Fa(e);return La(e)(t.map(Da))}},$a=new Set(["brightness","contrast","saturate","opacity"]);function Ha(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[o]=n.match(ja)||[];if(!o)return e;const i=n.replace(o,"");let r=$a.has(t)?1:0;return o!==n&&(r*=100),t+"("+r+i+")"}const Wa=/\b([a-z-]*)\(.*?\)/gu,Na={...Oa,getAnimatableNone:e=>{const t=e.match(Wa);return t?t.map(Ha).join(" "):e}},_a={...ns,color:Aa,backgroundColor:Aa,outlineColor:Aa,fill:Aa,stroke:Aa,borderColor:Aa,borderTopColor:Aa,borderRightColor:Aa,borderBottomColor:Aa,borderLeftColor:Aa,filter:Na,WebkitFilter:Na},Ua=e=>_a[e];function Ga(e,t){let n=Ua(e);return n!==Na&&(n=Oa),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const qa=new Set(["auto","none","0"]);const Ka=e=>e===Nr||e===Zr,Za=(e,t)=>parseFloat(e.split(", ")[t]),Ya=(e,t)=>(n,{transform:o})=>{if("none"===o||!o)return 0;const i=o.match(/^matrix3d\((.+)\)$/u);if(i)return Za(i[1],t);{const t=o.match(/^matrix\((.+)\)$/u);return t?Za(t[1],e):0}},Xa=new Set(["x","y","z"]),Ja=Rr.filter((e=>!Xa.has(e)));const Qa={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:Ya(4,13),y:Ya(5,14)};Qa.translateX=Qa.x,Qa.translateY=Qa.y;const el=new Set;let tl=!1,nl=!1;function ol(){if(nl){const e=Array.from(el).filter((e=>e.needsMeasurement)),t=new Set(e.map((e=>e.element))),n=new Map;t.forEach((e=>{const t=function(e){const t=[];return Ja.forEach((n=>{const o=e.getValue(n);void 0!==o&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))})),t}(e);t.length&&(n.set(e,t),e.render())})),e.forEach((e=>e.measureInitialState())),t.forEach((e=>{e.render();const t=n.get(e);t&&t.forEach((([t,n])=>{var o;null===(o=e.getValue(t))||void 0===o||o.set(n)}))})),e.forEach((e=>e.measureEndState())),e.forEach((e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)}))}nl=!1,tl=!1,el.forEach((e=>e.complete())),el.clear()}function il(){el.forEach((e=>{e.readKeyframes(),e.needsMeasurement&&(nl=!0)}))}class rl{constructor(e,t,n,o,i,r=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=o,this.element=i,this.isAsync=r}scheduleResolve(){this.isScheduled=!0,this.isAsync?(el.add(this),tl||(tl=!0,_i.read(il),_i.resolveKeyframes(ol))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:t,element:n,motionValue:o}=this;for(let i=0;i<e.length;i++)if(null===e[i])if(0===i){const i=null==o?void 0:o.get(),r=e[e.length-1];if(void 0!==i)e[0]=i;else if(n&&t){const o=n.readValue(t,r);null!=o&&(e[0]=o)}void 0===e[0]&&(e[0]=r),o&&void 0===i&&o.set(e[0])}else e[i]=e[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),el.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,el.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const sl=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),al=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ll(e,t,n=1){$i(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[o,i]=function(e){const t=al.exec(e);if(!t)return[,];const[,n,o,i]=t;return[`--${null!=n?n:o}`,i]}(e);if(!o)return;const r=window.getComputedStyle(t).getPropertyValue(o);if(r){const e=r.trim();return sl(e)?parseFloat(e):e}return Or(i)?ll(i,t,n+1):i}const cl=e=>t=>t.test(e),ul=[Nr,Zr,Kr,qr,Xr,Yr,{test:e=>"auto"===e,parse:e=>e}],dl=e=>ul.find(cl(e));class pl extends rl{constructor(e,t,n,o,i){super(e,t,n,o,i,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n<e.length;n++){let o=e[n];if("string"==typeof o&&(o=o.trim(),Or(o))){const i=ll(o,t.current);void 0!==i&&(e[n]=i),n===e.length-1&&(this.finalKeyframe=o)}}if(this.resolveNoneKeyframes(),!zs.has(n)||2!==e.length)return;const[o,i]=e,r=dl(o),s=dl(i);if(r!==s)if(Ka(r)&&Ka(s))for(let t=0;t<e.length;t++){const n=e[t];"string"==typeof n&&(e[t]=parseFloat(n))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:t}=this,n=[];for(let t=0;t<e.length;t++)("number"==typeof(o=e[t])?0===o:null===o||"none"===o||"0"===o||ba(o))&&n.push(t);var o;n.length&&function(e,t,n){let o,i=0;for(;i<e.length&&!o;){const t=e[i];"string"==typeof t&&!qa.has(t)&&Va(t).values.length&&(o=e[i]),i++}if(o&&n)for(const i of t)e[i]=Ga(n,o)}(e,n,t)}measureInitialState(){const{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Qa[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;const o=t[t.length-1];void 0!==o&&e.getValue(n,o).jump(o,!1)}measureEndState(){var e;const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const r=o.length-1,s=o[r];o[r]=Qa[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==s&&void 0===this.finalKeyframe&&(this.finalKeyframe=s),(null===(e=this.removedTransforms)||void 0===e?void 0:e.length)&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}const hl=(e,t)=>"zIndex"!==t&&(!("number"!=typeof e&&!Array.isArray(e))||!("string"!=typeof e||!Oa.test(e)&&"0"!==e||e.startsWith("url(")));function ml(e,t,n,o){const i=e[0];if(null===i)return!1;if("display"===t||"visibility"===t)return!0;const r=e[e.length-1],s=hl(i,t),a=hl(r,t);return Oi(s===a,`You are trying to animate ${t} from "${i}" to "${r}". ${i} is not an animatable value - to enable this animation set ${i} to a value animatable to ${r} via the \`style\` property.`),!(!s||!a)&&(function(e){const t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||("spring"===n||Xs(n))&&o)}const fl=e=>null!==e;function gl(e,{repeat:t,repeatType:n="loop"},o){const i=e.filter(fl),r=t&&"loop"!==n&&t%2==1?0:i.length-1;return r&&void 0!==o?o:i[r]}class xl{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:r="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=Vs.now(),this.options={autoplay:e,delay:t,type:n,repeat:o,repeatDelay:i,repeatType:r,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(il(),ol()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=Vs.now(),this.hasAttemptedResolve=!0;const{name:n,type:o,velocity:i,delay:r,onComplete:s,onUpdate:a,isGenerator:l}=this.options;if(!l&&!ml(e,n,o,i)){if(!r)return a&&a(gl(e,this.options,t)),s&&s(),void this.resolveFinishedPromise();this.options.duration=0}const c=this.initPlayback(e,t);!1!==c&&(this._resolved={keyframes:e,finalKeyframe:t,...c},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise((e=>{this.resolveFinishedPromise=e}))}}const vl=2e4;function yl(e){let t=0;let n=e.next(t);for(;!n.done&&t<vl;)t+=50,n=e.next(t);return t>=vl?1/0:t}const bl=(e,t,n)=>e+(t-e)*n;function wl(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function jl(e,t){return n=>n>0?t:e}const Cl=(e,t,n)=>{const o=e*e,i=n*(t*t-o)+o;return i<0?0:Math.sqrt(i)},Sl=[Pa,Ta,Ba];function kl(e){const t=(n=e,Sl.find((e=>e.test(n))));var n;if(Oi(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`),!Boolean(t))return!1;let o=t.parse(e);return t===Ba&&(o=function({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,n/=100;let i=0,r=0,s=0;if(t/=100){const o=n<.5?n*(1+t):n+t-n*t,a=2*n-o;i=wl(a,o,e+1/3),r=wl(a,o,e),s=wl(a,o,e-1/3)}else i=r=s=n;return{red:Math.round(255*i),green:Math.round(255*r),blue:Math.round(255*s),alpha:o}}(o)),o}const Ml=(e,t)=>{const n=kl(e),o=kl(t);if(!n||!o)return jl(e,t);const i={...n};return e=>(i.red=Cl(n.red,o.red,e),i.green=Cl(n.green,o.green,e),i.blue=Cl(n.blue,o.blue,e),i.alpha=bl(n.alpha,o.alpha,e),Ta.transform(i))},Tl=(e,t)=>n=>t(e(n)),Pl=(...e)=>e.reduce(Tl),Bl=new Set(["none","hidden"]);function Al(e,t){return n=>bl(e,t,n)}function El(e){return"number"==typeof e?Al:"string"==typeof e?Or(e)?jl:Aa.test(e)?Ml:Rl:Array.isArray(e)?zl:"object"==typeof e?Aa.test(e)?Ml:Il:jl}function zl(e,t){const n=[...e],o=n.length,i=e.map(((e,n)=>El(e)(e,t[n])));return e=>{for(let t=0;t<o;t++)n[t]=i[t](e);return n}}function Il(e,t){const n={...e,...t},o={};for(const i in n)void 0!==e[i]&&void 0!==t[i]&&(o[i]=El(e[i])(e[i],t[i]));return e=>{for(const t in o)n[t]=o[t](e);return n}}const Rl=(e,t)=>{const n=Oa.createTransformer(t),o=Va(e),i=Va(t);return o.indexes.var.length===i.indexes.var.length&&o.indexes.color.length===i.indexes.color.length&&o.indexes.number.length>=i.indexes.number.length?Bl.has(e)&&!i.values.length||Bl.has(t)&&!o.values.length?function(e,t){return Bl.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):Pl(zl(function(e,t){var n;const o=[],i={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const s=t.types[r],a=e.indexes[s][i[s]],l=null!==(n=e.values[a])&&void 0!==n?n:0;o[r]=l,i[s]++}return o}(o,i),i.values),n):(Oi(!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.`),jl(e,t))};function Vl(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return bl(e,t,n);return El(e)(e,t)}function Fl(e,t,n){const o=Math.max(t-5,0);return Os(n-e(o),t-o)}const Ll=100,Dl=10,Ol=1,$l=0,Hl=800,Wl=.3,Nl=.3,_l={granular:.01,default:2},Ul={granular:.005,default:.5},Gl=.01,ql=10,Kl=.05,Zl=1;function Yl({duration:e=Hl,bounce:t=Wl,velocity:n=$l,mass:o=Ol}){let i,r;Oi(e<=Zs(ql),"Spring duration must be 10 seconds or less");let s=1-t;s=Wr(Kl,Zl,s),e=Wr(Gl,ql,Ys(e)),s<1?(i=t=>{const o=t*s,i=o*e;return.001-(o-n)/Jl(t,s)*Math.exp(-i)},r=t=>{const o=t*s*e,r=o*n+n,a=Math.pow(s,2)*Math.pow(t,2)*e,l=Math.exp(-o),c=Jl(Math.pow(t,2),s);return(.001-i(t)>0?-1:1)*((r-a)*l)/c}):(i=t=>Math.exp(-t*e)*((t-n)*e+1)-.001,r=t=>Math.exp(-t*e)*(e*e*(n-t)));const a=function(e,t,n){let o=n;for(let n=1;n<Xl;n++)o-=e(o)/t(o);return o}(i,r,5/e);if(e=Zs(e),isNaN(a))return{stiffness:Ll,damping:Dl,duration:e};{const t=Math.pow(a,2)*o;return{stiffness:t,damping:2*s*Math.sqrt(o*t),duration:e}}}const Xl=12;function Jl(e,t){return e*Math.sqrt(1-t*t)}const Ql=["duration","bounce"],ec=["stiffness","damping","mass"];function tc(e,t){return t.some((t=>void 0!==e[t]))}function nc(e=Nl,t=Wl){const n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:i}=n;const r=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:r},{stiffness:l,damping:c,mass:u,duration:d,velocity:p,isResolvedFromDuration:h}=function(e){let t={velocity:$l,stiffness:Ll,damping:Dl,mass:Ol,isResolvedFromDuration:!1,...e};if(!tc(e,ec)&&tc(e,Ql))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(1.2*n),i=o*o,r=2*Wr(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:Ol,stiffness:i,damping:r}}else{const n=Yl(e);t={...t,...n,mass:Ol},t.isResolvedFromDuration=!0}return t}({...n,velocity:-Ys(n.velocity||0)}),m=p||0,f=c/(2*Math.sqrt(l*u)),g=s-r,x=Ys(Math.sqrt(l/u)),v=Math.abs(g)<5;let y;if(o||(o=v?_l.granular:_l.default),i||(i=v?Ul.granular:Ul.default),f<1){const e=Jl(x,f);y=t=>{const n=Math.exp(-f*x*t);return s-n*((m+f*x*g)/e*Math.sin(e*t)+g*Math.cos(e*t))}}else if(1===f)y=e=>s-Math.exp(-x*e)*(g+(m+x*g)*e);else{const e=x*Math.sqrt(f*f-1);y=t=>{const n=Math.exp(-f*x*t),o=Math.min(e*t,300);return s-n*((m+f*x*g)*Math.sinh(o)+e*g*Math.cosh(o))/e}}const b={calculatedDuration:h&&d||null,next:e=>{const t=y(e);if(h)a.done=e>=d;else{let n=0;f<1&&(n=0===e?Zs(m):Fl(y,e,t));const r=Math.abs(n)<=o,l=Math.abs(s-t)<=i;a.done=r&&l}return a.value=a.done?s:t,a},toString:()=>{const e=Math.min(yl(b),vl),t=ia((t=>b.next(e*t).value),e,30);return e+"ms "+t}};return b}function oc({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],p={done:!1,value:d},h=e=>void 0===a?l:void 0===l||Math.abs(a-e)<Math.abs(l-e)?a:l;let m=n*t;const f=d+m,g=void 0===s?f:s(f);g!==f&&(m=g-d);const x=e=>-m*Math.exp(-e/o),v=e=>g+x(e),y=e=>{const t=x(e),n=v(e);p.done=Math.abs(t)<=c,p.value=p.done?g:n};let b,w;const j=e=>{var t;(t=p.value,void 0!==a&&t<a||void 0!==l&&t>l)&&(b=e,w=nc({keyframes:[p.value,h(p.value)],velocity:Fl(v,e,p.value),damping:i,stiffness:r,restDelta:c,restSpeed:u}))};return j(0),{calculatedDuration:null,next:e=>{let t=!1;return w||void 0!==b||(t=!0,y(e),j(e)),void 0!==b&&e>=b?w.next(e-b):(!t&&y(e),p)}}}const ic=ua(.42,0,1,1),rc=ua(0,0,.58,1),sc=ua(.42,0,.58,1),ac={linear:Di,easeIn:ic,easeInOut:sc,easeOut:rc,circIn:xa,circInOut:ya,circOut:va,backIn:ma,backInOut:fa,backOut:ha,anticipate:ga},lc=e=>{if(Qs(e)){$i(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,o,i]=e;return ua(t,n,o,i)}return"string"==typeof e?($i(void 0!==ac[e],`Invalid easing type '${e}'`),ac[e]):e};function cc(e,t,{clamp:n=!0,ease:o,mixer:i}={}){const r=e.length;if($i(r===t.length,"Both input and output ranges must be the same length"),1===r)return()=>t[0];if(2===r&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[r-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=function(e,t,n){const o=[],i=n||Vl,r=e.length-1;for(let n=0;n<r;n++){let r=i(e[n],e[n+1]);if(t){const e=Array.isArray(t)?t[n]||Di:t;r=Pl(e,r)}o.push(r)}return o}(t,o,i),l=a.length,c=n=>{if(s&&n<e[0])return t[0];let o=0;if(l>1)for(;o<e.length-2&&!(n<e[o+1]);o++);const i=oa(e[o],e[o+1],n);return a[o](i)};return n?t=>c(Wr(e[0],e[r-1],t)):c}function uc(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const i=oa(0,t,o);e.push(bl(n,1,i))}}(t,e.length-1),t}function dc(e,t){return e.map((()=>t||sc)).splice(0,e.length-1)}function pc({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const i=(e=>Array.isArray(e)&&"number"!=typeof e[0])(o)?o.map(lc):lc(o),r={done:!1,value:t[0]},s=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:uc(t),e),a=cc(s,t,{ease:Array.isArray(i)?i:dc(t,i)});return{calculatedDuration:e,next:t=>(r.value=a(t),r.done=t>=e,r)}}const hc=e=>{const t=({timestamp:t})=>e(t);return{start:()=>_i.update(t,!0),stop:()=>Ui(t),now:()=>Gi.isProcessing?Gi.timestamp:Vs.now()}},mc={decay:oc,inertia:oc,tween:pc,keyframes:pc,spring:nc},fc=e=>e/100;class gc extends xl{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:e}=this.options;e&&e()};const{name:t,motionValue:n,element:o,keyframes:i}=this.options,r=(null==o?void 0:o.KeyframeResolver)||rl;this.resolver=new r(i,((e,t)=>this.onKeyframesResolved(e,t)),t,n,o),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){const{type:t="keyframes",repeat:n=0,repeatDelay:o=0,repeatType:i,velocity:r=0}=this.options,s=Xs(t)?t:mc[t]||pc;let a,l;s!==pc&&"number"!=typeof e[0]&&("production"!==process.env.NODE_ENV&&$i(2===e.length,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`),a=Pl(fc,Vl(e[0],e[1])),e=[0,100]);const c=s({...this.options,keyframes:e});"mirror"===i&&(l=s({...this.options,keyframes:[...e].reverse(),velocity:-r})),null===c.calculatedDuration&&(c.calculatedDuration=yl(c));const{calculatedDuration:u}=c,d=u+o;return{generator:c,mirroredGenerator:l,mapPercentToKeyframes:a,calculatedDuration:u,resolvedDuration:d,totalDuration:d*(n+1)-o}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){const{resolved:n}=this;if(!n){const{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}const{finalKeyframe:o,generator:i,mirroredGenerator:r,mapPercentToKeyframes:s,keyframes:a,calculatedDuration:l,totalDuration:c,resolvedDuration:u}=n;if(null===this.startTime)return i.next(0);const{delay:d,repeat:p,repeatType:h,repeatDelay:m,onUpdate:f}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),t?this.currentTime=e:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;const g=this.currentTime-d*(this.speed>=0?1:-1),x=this.speed>=0?g<0:g>c;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=c);let v=this.currentTime,y=i;if(p){const e=Math.min(this.currentTime,c)/u;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,p+1);Boolean(t%2)&&("reverse"===h?(n=1-n,m&&(n-=m/u)):"mirror"===h&&(y=r)),v=Wr(0,1,n)*u}const b=x?{done:!1,value:a[0]}:y.next(v);s&&(b.value=s(b.value));let{done:w}=b;x||null===l||(w=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const j=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return j&&void 0!==o&&(b.value=gl(a,this.options,o)),f&&f(b.value),j&&this.finish(),b}get duration(){const{resolved:e}=this;return e?Ys(e.calculatedDuration):0}get time(){return Ys(this.currentTime)}set time(e){e=Zs(e),this.currentTime=e,null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=Ys(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:e=hc,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e((e=>this.tick(e)))),t&&t();const o=this.driver.now();null!==this.holdTime?this.startTime=o-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=o):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;this._resolved?(this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const xc=new Set(["opacity","clipPath","filter","transform"]);function vc(e,t,n,{delay:o=0,duration:i=300,repeat:r=0,repeatType:s="loop",ease:a="easeInOut",times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=la(a,i);return Array.isArray(u)&&(c.easing=u),e.animate(c,{delay:o,duration:i,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:r+1,direction:"reverse"===s?"alternate":"normal"})}const yc=Us((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));const bc={anticipate:ga,backInOut:fa,circInOut:ya};class wc extends xl{constructor(e){super(e);const{name:t,motionValue:n,element:o,keyframes:i}=this.options;this.resolver=new pl(i,((e,t)=>this.onKeyframesResolved(e,t)),t,n,o),this.resolver.scheduleResolve()}initPlayback(e,t){let{duration:n=300,times:o,ease:i,type:r,motionValue:s,name:a,startTime:l}=this.options;if(!s.owner||!s.owner.current)return!1;if("string"==typeof i&&na()&&i in bc&&(i=bc[i]),function(e){return Xs(e.type)||"spring"===e.type||!ra(e.ease)}(this.options)){const{onComplete:t,onUpdate:s,motionValue:a,element:l,...c}=this.options,u=function(e,t){const n=new gc({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let o={done:!1,value:e[0]};const i=[];let r=0;for(;!o.done&&r<2e4;)o=n.sample(r),i.push(o.value),r+=10;return{times:void 0,keyframes:i,duration:r-10,ease:"linear"}}(e,c);1===(e=u.keyframes).length&&(e[1]=e[0]),n=u.duration,o=u.times,i=u.ease,r="keyframes"}const c=vc(s.owner.current,a,e,{...this.options,duration:n,times:o,ease:i});return c.startTime=null!=l?l:this.calcStartTime(),this.pendingTimeline?(Js(c,this.pendingTimeline),this.pendingTimeline=void 0):c.onfinish=()=>{const{onComplete:n}=this.options;s.set(gl(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:n,times:o,type:r,ease:i,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:t}=e;return Ys(t)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:t}=e;return Ys(t.currentTime||0)}set time(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.currentTime=Zs(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:t}=e;return t.playbackRate}set speed(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:t}=e;return t.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){const{resolved:t}=this;if(!t)return Di;const{animation:n}=t;Js(n,e)}else this.pendingTimeline=e;return Di}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:t,keyframes:n,duration:o,type:i,ease:r,times:s}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){const{motionValue:e,onUpdate:t,onComplete:a,element:l,...c}=this.options,u=new gc({...c,keyframes:n,duration:o,type:i,ease:r,times:s,isGenerator:!0}),d=Zs(this.time);e.setWithVelocity(u.sample(d-10).value,u.sample(d).value,10)}const{onStop:a}=this.options;a&&a(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:i,damping:r,type:s}=e;if(!(t&&t.owner&&t.owner.current instanceof HTMLElement))return!1;const{onUpdate:a,transformTemplate:l}=t.owner.getProps();return yc()&&n&&xc.has(n)&&!a&&!l&&!o&&"mirror"!==i&&0!==r&&"inertia"!==s}}const jc={type:"spring",stiffness:500,damping:25,restSpeed:10},Cc={type:"keyframes",duration:.8},Sc={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},kc=(e,{keyframes:t})=>t.length>2?Cc:Vr.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:jc:Sc;const Mc=(e,t,n,o={},i,r)=>s=>{const a=Es(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c-=Zs(l);let u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:e=>{t.set(e),a.onUpdate&&a.onUpdate(e)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:r?void 0:i};(function({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:i,repeat:r,repeatType:s,repeatDelay:a,from:l,elapsed:c,...u}){return!!Object.keys(u).length})(a)||(u={...u,...kc(e,u)}),u.duration&&(u.duration=Zs(u.duration)),u.repeatDelay&&(u.repeatDelay=Zs(u.repeatDelay)),void 0!==u.from&&(u.keyframes[0]=u.from);let d=!1;if((!1===u.type||0===u.duration&&!u.repeatDelay)&&(u.duration=0,0===u.delay&&(d=!0)),d&&!r&&void 0!==t.get()){const e=gl(u.keyframes,a);if(void 0!==e)return _i.update((()=>{u.onUpdate(e),u.onComplete()})),new Ks([])}return!r&&wc.supports(u)?new wc(u):new gc(u)};function Tc({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,o}function Pc(e,t,{delay:n=0,transitionOverride:o,type:i}={}){var r;let{transition:s=e.getDefaultTransition(),transitionEnd:a,...l}=t;o&&(s=o);const c=[],u=i&&e.animationState&&e.animationState.getState()[i];for(const t in l){const o=e.getValue(t,null!==(r=e.latestValues[t])&&void 0!==r?r:null),i=l[t];if(void 0===i||u&&Tc(u,t))continue;const a={delay:n,...Es(s||{},t)};let d=!1;if(window.MotionHandoffAnimation){const n=_s(e);if(n){const e=window.MotionHandoffAnimation(n,t,_i);null!==e&&(a.startTime=e,d=!0)}}Ns(e,t),o.start(Mc(t,o,i,e.shouldReduceMotion&&zs.has(t)?{type:!1}:a,e,d));const p=o.animation;p&&c.push(p)}return a&&Promise.all(c).then((()=>{_i.update((()=>{a&&function(e,t){const n=As(e,t);let{transitionEnd:o={},transition:i={},...r}=n||{};r={...r,...o};for(const t in r)Ws(e,t,(s=r[t],Br(s)?s[s.length-1]||0:s));var s}(e,a)}))})),c}function Bc(e,t,n={}){var o;const i=As(e,t,"exit"===n.type?null===(o=e.presenceContext)||void 0===o?void 0:o.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(r=n.transitionOverride);const s=i?()=>Promise.all(Pc(e,i,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(o=0)=>{const{delayChildren:i=0,staggerChildren:s,staggerDirection:a}=r;return function(e,t,n=0,o=0,i=1,r){const s=[],a=(e.variantChildren.size-1)*o,l=1===i?(e=0)=>e*o:(e=0)=>a-e*o;return Array.from(e.variantChildren).sort(Ac).forEach(((e,o)=>{e.notify("AnimationStart",t),s.push(Bc(e,t,{...r,delay:n+l(o)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(s)}(e,t,i+o,s,a,n)}:()=>Promise.resolve(),{when:l}=r;if(l){const[e,t]="beforeChildren"===l?[s,a]:[a,s];return e().then((()=>t()))}return Promise.all([s(),a(n.delay)])}function Ac(e,t){return e.sortNodePosition(t)}const Ec=lr.length;function zc(e){if(!e)return;if(!e.isControllingVariants){const t=e.parent&&zc(e.parent)||{};return void 0!==e.props.initial&&(t.initial=e.props.initial),t}const t={};for(let n=0;n<Ec;n++){const o=lr[n],i=e.props[o];(rr(i)||!1===i)&&(t[o]=i)}return t}const Ic=[...ar].reverse(),Rc=ar.length;function Vc(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let o;if(e.notify("AnimationStart",t),Array.isArray(t)){const i=t.map((t=>Bc(e,t,n)));o=Promise.all(i)}else if("string"==typeof t)o=Bc(e,t,n);else{const i="function"==typeof t?As(e,t,n.custom):t;o=Promise.all(Pc(e,i,n))}return o.then((()=>{e.notify("AnimationComplete",t)}))}(e,t,n))))}function Fc(e){let t=Vc(e),n=Oc(),o=!0;const i=t=>(n,o)=>{var i;const r=As(e,o,"exit"===t?null===(i=e.presenceContext)||void 0===i?void 0:i.custom:void 0);if(r){const{transition:e,transitionEnd:t,...o}=r;n={...n,...o,...t}}return n};function r(r){const{props:s}=e,a=zc(e.parent)||{},l=[],c=new Set;let u={},d=1/0;for(let t=0;t<Rc;t++){const p=Ic[t],h=n[p],m=void 0!==s[p]?s[p]:a[p],f=rr(m),g=p===r?h.isActive:null;!1===g&&(d=t);let x=m===a[p]&&m!==s[p]&&f;if(x&&o&&e.manuallyAnimateOnMount&&(x=!1),h.protectedKeys={...u},!h.isActive&&null===g||!m&&!h.prevProp||sr(m)||"boolean"==typeof m)continue;const v=Lc(h.prevProp,m);let y=v||p===r&&h.isActive&&!x&&f||t>d&&f,b=!1;const w=Array.isArray(m)?m:[m];let j=w.reduce(i(p),{});!1===g&&(j={});const{prevResolvedValues:C={}}=h,S={...C,...j},k=t=>{y=!0,c.has(t)&&(b=!0,c.delete(t)),h.needsAnimating[t]=!0;const n=e.getValue(t);n&&(n.liveStyle=!1)};for(const e in S){const t=j[e],n=C[e];if(u.hasOwnProperty(e))continue;let o=!1;o=Br(t)&&Br(n)?!Bs(t,n):t!==n,o?null!=t?k(e):c.add(e):void 0!==t&&c.has(e)?k(e):h.protectedKeys[e]=!0}h.prevProp=m,h.prevResolvedValues=j,h.isActive&&(u={...u,...j}),o&&e.blockInitialAnimation&&(y=!1);y&&(!(x&&v)||b)&&l.push(...w.map((e=>({animation:e,options:{type:p}}))))}if(c.size){const t={};c.forEach((n=>{const o=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=null!=o?o:null})),l.push({animation:t})}let p=Boolean(l.length);return!o||!1!==s.initial&&s.initial!==s.animate||e.manuallyAnimateOnMount||(p=!1),o=!1,p?t(l):Promise.resolve()}return{animateChanges:r,setActive:function(t,o){var i;if(n[t].isActive===o)return Promise.resolve();null===(i=e.variantChildren)||void 0===i||i.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,o)})),n[t].isActive=o;const s=r(t);for(const e in n)n[e].protectedKeys={};return s},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=Oc(),o=!0}}}function Lc(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!Bs(t,e)}function Dc(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Oc(){return{animate:Dc(!0),whileInView:Dc(),whileHover:Dc(),whileTap:Dc(),whileDrag:Dc(),whileFocus:Dc(),exit:Dc()}}class $c{constructor(e){this.isMounted=!1,this.node=e}update(){}}let Hc=0;const Wc={animation:{Feature:class extends $c{constructor(e){super(e),e.animationState||(e.animationState=Fc(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();sr(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}},exit:{Feature:class extends $c{constructor(){super(...arguments),this.id=Hc++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;const o=this.node.animationState.setActive("exit",!e);t&&!e&&o.then((()=>t(this.id)))}mount(){const{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}}},Nc={x:!1,y:!1};function _c(){return Nc.x||Nc.y}const Uc=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function Gc(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function qc(e){return{point:{x:e.pageX,y:e.pageY}}}function Kc(e,t,n,o){return Gc(e,t,(e=>t=>Uc(t)&&e(t,qc(t)))(n),o)}const Zc=(e,t)=>Math.abs(e-t);class Yc{constructor(e,t,{transformPagePoint:n,contextWindow:o,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=Qc(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=Zc(e.x,t.x),o=Zc(e.y,t.y);return Math.sqrt(n**2+o**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:o}=e,{timestamp:i}=Gi;this.history.push({...o,timestamp:i});const{onStart:r,onMove:s}=this.handlers;t||(r&&r(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),s&&s(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=Xc(t,this.transformPagePoint),_i.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();const{onEnd:n,onSessionEnd:o,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const r=Qc("pointercancel"===e.type?this.lastMoveEventInfo:Xc(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,r),o&&o(e,r)},!Uc(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.contextWindow=o||window;const r=Xc(qc(e),this.transformPagePoint),{point:s}=r,{timestamp:a}=Gi;this.history=[{...s,timestamp:a}];const{onSessionStart:l}=t;l&&l(e,Qc(r,this.history)),this.removeListeners=Pl(Kc(this.contextWindow,"pointermove",this.handlePointerMove),Kc(this.contextWindow,"pointerup",this.handlePointerUp),Kc(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),Ui(this.updatePoint)}}function Xc(e,t){return t?{point:t(e.point)}:e}function Jc(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Qc({point:e},t){return{point:e,delta:Jc(e,tu(t)),offset:Jc(e,eu(t)),velocity:nu(t,.1)}}function eu(e){return e[0]}function tu(e){return e[e.length-1]}function nu(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const i=tu(e);for(;n>=0&&(o=e[n],!(i.timestamp-o.timestamp>Zs(t)));)n--;if(!o)return{x:0,y:0};const r=Ys(i.timestamp-o.timestamp);if(0===r)return{x:0,y:0};const s={x:(i.x-o.x)/r,y:(i.y-o.y)/r};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function ou(e){return e.max-e.min}function iu(e,t,n,o=.5){e.origin=o,e.originPoint=bl(t.min,t.max,e.origin),e.scale=ou(n)/ou(t),e.translate=bl(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function ru(e,t,n,o){iu(e.x,t.x,n.x,o?o.originX:void 0),iu(e.y,t.y,n.y,o?o.originY:void 0)}function su(e,t,n){e.min=n.min+t.min,e.max=e.min+ou(t)}function au(e,t,n){e.min=t.min-n.min,e.max=e.min+ou(t)}function lu(e,t,n){au(e.x,t.x,n.x),au(e.y,t.y,n.y)}function cu(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function uu(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}const du=.35;function pu(e,t,n){return{min:hu(e,t),max:hu(e,n)}}function hu(e,t){return"number"==typeof e?e:e[t]||0}const mu=()=>({x:{min:0,max:0},y:{min:0,max:0}});function fu(e){return[e("x"),e("y")]}function gu({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function xu(e){return void 0===e||1===e}function vu({scale:e,scaleX:t,scaleY:n}){return!xu(e)||!xu(t)||!xu(n)}function yu(e){return vu(e)||bu(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function bu(e){return wu(e.x)||wu(e.y)}function wu(e){return e&&"0%"!==e}function ju(e,t,n){return n+t*(e-n)}function Cu(e,t,n,o,i){return void 0!==i&&(e=ju(e,i,o)),ju(e,n,o)+t}function Su(e,t=0,n=1,o,i){e.min=Cu(e.min,t,n,o,i),e.max=Cu(e.max,t,n,o,i)}function ku(e,{x:t,y:n}){Su(e.x,t.translate,t.scale,t.originPoint),Su(e.y,n.translate,n.scale,n.originPoint)}const Mu=.999999999999,Tu=1.0000000000001;function Pu(e,t){e.min=e.min+t,e.max=e.max+t}function Bu(e,t,n,o,i=.5){Su(e,t,n,bl(e.min,e.max,i),o)}function Au(e,t){Bu(e.x,t.x,t.scaleX,t.scale,t.originX),Bu(e.y,t.y,t.scaleY,t.scale,t.originY)}function Eu(e,t){return gu(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}(e.getBoundingClientRect(),t))}const zu=({current:e})=>e?e.ownerDocument.defaultView:null,Iu=new WeakMap;class Ru{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic={x:{min:0,max:0},y:{min:0,max:0}},this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:o}=this.getProps();this.panSession=new Yc(e,{onSessionStart:e=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(qc(e).point)},onStart:(e,t)=>{const{drag:n,dragPropagation:o,onDragStart:i}=this.getProps();if(n&&!o&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===(r=n)||"y"===r?Nc[r]?null:(Nc[r]=!0,()=>{Nc[r]=!1}):Nc.x||Nc.y?null:(Nc.x=Nc.y=!0,()=>{Nc.x=Nc.y=!1}),!this.openDragLock))return;var r;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),fu((e=>{let t=this.getAxisMotionValue(e).get()||0;if(Kr.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const o=n.layout.layoutBox[e];if(o){t=ou(o)*(parseFloat(t)/100)}}}this.originPoint[e]=t})),i&&_i.postRender((()=>i(e,t))),Ns(this.visualElement,"transform");const{animationState:s}=this.visualElement;s&&s.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:o,onDirectionLock:i,onDrag:r}=this.getProps();if(!n&&!this.openDragLock)return;const{offset:s}=t;if(o&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(s),void(null!==this.currentDirection&&i&&i(this.currentDirection));this.updateAxis("x",t.point,s),this.updateAxis("y",t.point,s),this.visualElement.render(),r&&r(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>fu((e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:o,contextWindow:zu(this.visualElement)})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:o}=t;this.startAnimation(o);const{onDragEnd:i}=this.getProps();i&&_i.postRender((()=>i(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:o}=this.getProps();if(!n||!Vu(e,o,this.currentDirection))return;const i=this.getAxisMotionValue(e);let r=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(r=function(e,{min:t,max:n},o){return void 0!==t&&e<t?e=o?bl(t,e,o.min):Math.max(e,t):void 0!==n&&e>n&&(e=o?bl(n,e,o.max):Math.min(e,n)),e}(r,this.constraints[e],this.elastic[e])),i.set(r)}resolveConstraints(){var e;const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,i=this.constraints;t&&mr(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!t||!o)&&function(e,{top:t,left:n,bottom:o,right:i}){return{x:cu(e.x,n,i),y:cu(e.y,t,o)}}(o.layoutBox,t),this.elastic=function(e=du){return!1===e?e=0:!0===e&&(e=du),{x:pu(e,"left","right"),y:pu(e,"top","bottom")}}(n),i!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&fu((e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(o.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!mr(e))return!1;const n=e.current;$i(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const i=function(e,t,n){const o=Eu(e,n),{scroll:i}=t;return i&&(Pu(o.x,i.offset.x),Pu(o.y,i.offset.y)),o}(n,o.root,this.visualElement.getTransformPagePoint());let r=function(e,t){return{x:uu(e.x,t.x),y:uu(e.y,t.y)}}(o.layout.layoutBox,i);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(r));this.hasMutatedConstraints=!!e,e&&(r=gu(e))}return r}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:o,dragTransition:i,dragSnapToOrigin:r,onDragTransitionEnd:s}=this.getProps(),a=this.constraints||{},l=fu((s=>{if(!Vu(s,t,this.currentDirection))return;let l=a[s]||{};r&&(l={min:0,max:0});const c=o?200:1e6,u=o?40:1e7,d={type:"inertia",velocity:n?e[s]:0,bounceStiffness:c,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...i,...l};return this.startAxisValueAnimation(s,d)}));return Promise.all(l).then(s)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return Ns(this.visualElement,e),n.start(Mc(e,n,0,t,this.visualElement,!1))}stopAnimation(){fu((e=>this.getAxisMotionValue(e).stop()))}pauseAnimation(){fu((e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()}))}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){const t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps(),o=n[t];return o||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){fu((t=>{const{drag:n}=this.getProps();if(!Vu(t,n,this.currentDirection))return;const{projection:o}=this.visualElement,i=this.getAxisMotionValue(t);if(o&&o.layout){const{min:n,max:r}=o.layout.layoutBox[t];i.set(e[t]-bl(n,r,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!mr(t)||!n||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};fu((e=>{const t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){const n=t.get();o[e]=function(e,t){let n=.5;const o=ou(e),i=ou(t);return i>o?n=oa(t.min,t.max-o,e.min):o>i&&(n=oa(e.min,e.max-i,t.min)),Wr(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),fu((t=>{if(!Vu(t,e,null))return;const n=this.getAxisMotionValue(t),{min:i,max:r}=this.constraints[t];n.set(bl(i,r,o[t]))}))}addListeners(){if(!this.visualElement.current)return;Iu.set(this.visualElement,this);const e=Kc(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();mr(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,o=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),_i.read(t);const i=Gc(window,"resize",(()=>this.scalePositionWithinConstraints())),r=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(fu((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{i(),e(),o(),r&&r()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:o=!1,dragConstraints:i=!1,dragElastic:r=du,dragMomentum:s=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:o,dragConstraints:i,dragElastic:r,dragMomentum:s}}}function Vu(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const Fu=e=>(t,n)=>{e&&_i.postRender((()=>e(t,n)))};const Lu={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Du(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ou={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!Zr.test(e))return e;e=parseFloat(e)}return`${Du(e,t.target.x)}% ${Du(e,t.target.y)}%`}},$u={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,i=Oa.parse(e);if(i.length>5)return o;const r=Oa.createTransformer(e),s="number"!=typeof i[0]?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=l;const c=bl(a,l,.5);return"number"==typeof i[2+s]&&(i[2+s]/=c),"number"==typeof i[3+s]&&(i[3+s]/=c),r(i)}};class Hu extends e.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:o}=this.props,{projection:i}=e;!function(e){for(const t in e)gs[t]=e[t],Lr(t)&&(gs[t].isCSSVariable=!0)}(Nu),i&&(t.group&&t.group.add(i),n&&n.register&&o&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",(()=>{this.safeToRemove()})),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),Lu.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:o,isPresent:i}=this.props,r=n.projection;return r?(r.isPresent=i,o||e.layoutDependency!==t||void 0===t?r.willUpdate():this.safeToRemove(),e.isPresent!==i&&(i?r.promote():r.relegate()||_i.postRender((()=>{const e=r.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),vr.postRender((()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:o}=e;o&&(o.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(o),n&&n.deregister&&n.deregister(o))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function Wu(t){const[n,o]=function(t=!0){const n=e.useContext(Ri);if(null===n)return[!0,null];const{isPresent:o,onExitComplete:i,register:r}=n,s=e.useId();e.useEffect((()=>{t&&r(s)}),[t]);const a=e.useCallback((()=>t&&i&&i(s)),[s,i,t]);return!o&&i?[!1,a]:[!0]}(),i=e.useContext(Ii);return ge.jsx(Hu,{...t,layoutGroup:i,switchLayoutGroup:e.useContext(br),isPresent:n,safeToRemove:o})}const Nu={borderRadius:{...Ou,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ou,borderTopRightRadius:Ou,borderBottomLeftRadius:Ou,borderBottomRightRadius:Ou,boxShadow:$u};const _u=(e,t)=>e.depth-t.depth;class Uu{constructor(){this.children=[],this.isDirty=!1}add(e){Fs(this.children,e),this.isDirty=!0}remove(e){Ls(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(_u),this.isDirty=!1,this.children.forEach(e)}}const Gu=["TopLeft","TopRight","BottomLeft","BottomRight"],qu=Gu.length,Ku=e=>"string"==typeof e?parseFloat(e):e,Zu=e=>"number"==typeof e||Zr.test(e);function Yu(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const Xu=Qu(0,.5,va),Ju=Qu(.5,.95,Di);function Qu(e,t,n){return o=>o<e?0:o>t?1:n(oa(e,t,o))}function ed(e,t){e.min=t.min,e.max=t.max}function td(e,t){ed(e.x,t.x),ed(e.y,t.y)}function nd(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function od(e,t,n,o,i){return e=ju(e-=t,1/n,o),void 0!==i&&(e=ju(e,1/i,o)),e}function id(e,t,[n,o,i],r,s){!function(e,t=0,n=1,o=.5,i,r=e,s=e){Kr.test(t)&&(t=parseFloat(t),t=bl(s.min,s.max,t/100)-s.min);if("number"!=typeof t)return;let a=bl(r.min,r.max,o);e===r&&(a-=t),e.min=od(e.min,t,n,a,i),e.max=od(e.max,t,n,a,i)}(e,t[n],t[o],t[i],t.scale,r,s)}const rd=["x","scaleX","originX"],sd=["y","scaleY","originY"];function ad(e,t,n,o){id(e.x,t,rd,n?n.x:void 0,o?o.x:void 0),id(e.y,t,sd,n?n.y:void 0,o?o.y:void 0)}function ld(e){return 0===e.translate&&1===e.scale}function cd(e){return ld(e.x)&&ld(e.y)}function ud(e,t){return e.min===t.min&&e.max===t.max}function dd(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function pd(e,t){return dd(e.x,t.x)&&dd(e.y,t.y)}function hd(e){return ou(e.x)/ou(e.y)}function md(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class fd{constructor(){this.members=[]}add(e){Fs(this.members,e),e.scheduleRender()}remove(e){if(Ls(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let e=t;e>=0;e--){const t=this.members[e];if(!1!==t.isPresent){n=t;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:o}=e.options;!1===o&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const gd={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},xd="undefined"!=typeof window&&void 0!==window.MotionDebug,vd=["","X","Y","Z"],yd={visibility:"hidden"};let bd=0;function wd(e,t,n,o){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),o&&(o[e]=0))}function jd(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=_s(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:t,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",_i,!(t||o))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&jd(o)}function Cd({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:i}){return class{constructor(e={},n=(null==t?void 0:t())){this.id=bd++,this.animationId=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.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,xd&&(gd.totalNodes=gd.resolvedTargetDeltas=gd.recalculatedProjection=0),this.nodes.forEach(Md),this.nodes.forEach(Id),this.nodes.forEach(Rd),this.nodes.forEach(Td),xd&&window.MotionDebug.record(gd)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new Uu)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new Ds),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){const n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;var o;this.isSVG=(o=t)instanceof SVGElement&&"svg"!==o.tagName,this.instance=t;const{layoutId:i,layout:r,visualElement:s}=this.options;if(s&&!s.current&&s.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(r||i)&&(this.isLayoutDirty=!0),e){let n;const o=()=>this.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=Vs.now(),o=({timestamp:i})=>{const r=i-n;r>=t&&(Ui(o),e(r-t))};return _i.read(o,!0),()=>Ui(o)}(o,250),Lu.hasAnimatedSinceResize&&(Lu.hasAnimatedSinceResize=!1,this.nodes.forEach(zd))}))}i&&this.root.registerSharedNode(i,this),!1!==this.options.animate&&s&&(i||r)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:o})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const i=this.options.transition||s.getDefaultTransition()||$d,{onLayoutAnimationStart:r,onLayoutAnimationComplete:a}=s.getProps(),l=!this.targetLayout||!pd(this.targetLayout,o),c=!t&&n;if(this.options.layoutRoot||this.resumeFrom||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...Es(i,"layout"),onPlay:r,onComplete:a};(s.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||zd(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=o}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Ui(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(Vd),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&jd(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){const t=this.path[e];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}const{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;const o=this.getTransformTemplate();this.prevTransformTemplateValue=o?o(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(Bd);this.isUpdating||this.nodes.forEach(Ad),this.isUpdating=!1,this.nodes.forEach(Ed),this.nodes.forEach(Sd),this.nodes.forEach(kd),this.clearAllSnapshots();const e=Vs.now();Gi.delta=Wr(0,1e3/60,e-Gi.timestamp),Gi.timestamp=e,Gi.isProcessing=!0,qi.update.process(Gi),qi.preRender.process(Gi),qi.render.process(Gi),Gi.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,vr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Pd),this.sharedNodes.forEach(Fd)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,_i.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){_i.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure(),!this.snapshot||ou(this.snapshot.measuredBox.x)||ou(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++){this.path[e].updateScroll()}const e=this.layout;this.layout=this.measure(!1),this.layoutCorrected={x:{min:0,max:0},y:{min:0,max:0}},this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){const t=o(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!i)return;const e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!cd(this.projectionDelta),n=this.getTransformTemplate(),o=n?n(this.latestValues,""):void 0,r=o!==this.prevTransformTemplateValue;e&&(t||yu(this.latestValues)||r)&&(i(this.instance,o),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){const t=this.measurePageBox();let n=this.removeElementScroll(t);var o;return e&&(n=this.removeTransform(n)),Nd((o=n).x),Nd(o.y),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var e;const{visualElement:t}=this.options;if(!t)return{x:{min:0,max:0},y:{min:0,max:0}};const n=t.measureViewportBox();if(!((null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)||this.path.some(Ud))){const{scroll:e}=this.root;e&&(Pu(n.x,e.offset.x),Pu(n.y,e.offset.y))}return n}removeElementScroll(e){var t;const n={x:{min:0,max:0},y:{min:0,max:0}};if(td(n,e),null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)return n;for(let t=0;t<this.path.length;t++){const o=this.path[t],{scroll:i,options:r}=o;o!==this.root&&i&&r.layoutScroll&&(i.wasRoot&&td(n,e),Pu(n.x,i.offset.x),Pu(n.y,i.offset.y))}return n}applyTransform(e,t=!1){const n={x:{min:0,max:0},y:{min:0,max:0}};td(n,e);for(let e=0;e<this.path.length;e++){const o=this.path[e];!t&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Au(n,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),yu(o.latestValues)&&Au(n,o.latestValues)}return yu(this.latestValues)&&Au(n,this.latestValues),n}removeTransform(e){const t={x:{min:0,max:0},y:{min:0,max:0}};td(t,e);for(let e=0;e<this.path.length;e++){const n=this.path[e];if(!n.instance)continue;if(!yu(n.latestValues))continue;vu(n.latestValues)&&n.updateSnapshot();const o={x:{min:0,max:0},y:{min:0,max:0}};td(o,n.measurePageBox()),ad(t,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,o)}return yu(this.latestValues)&&ad(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}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!==Gi.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const o=Boolean(this.resumingFrom)||this!==n;if(!(e||o&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:i,layoutId:r}=this.options;if(this.layout&&(i||r)){if(this.resolvedRelativeTargetAt=Gi.timestamp,!this.targetDelta&&!this.relativeTarget){const e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},lu(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),td(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){var s,a,l;if(this.target||(this.target={x:{min:0,max:0},y:{min:0,max:0}},this.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}}),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),s=this.target,a=this.relativeTarget,l=this.relativeParent.target,su(s.x,a.x,l.x),su(s.y,a.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):td(this.target,this.layout.layoutBox),ku(this.target,this.targetDelta)):td(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const e=this.getClosestProjectingParent();e&&Boolean(e.resumingFrom)===Boolean(this.resumingFrom)&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},lu(this.relativeTargetOrigin,this.target,e.target),td(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}xd&&gd.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(this.parent&&!vu(this.parent.latestValues)&&!bu(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;const t=this.getLead(),n=Boolean(this.resumingFrom)||this!==t;let o=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(o=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(o=!1),this.resolvedRelativeTargetAt===Gi.timestamp&&(o=!1),o)return;const{layout:i,layoutId:r}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!i&&!r)return;td(this.layoutCorrected,this.layout.layoutBox);const s=this.treeScale.x,a=this.treeScale.y;!function(e,t,n,o=!1){const i=n.length;if(!i)return;let r,s;t.x=t.y=1;for(let a=0;a<i;a++){r=n[a],s=r.projectionDelta;const{visualElement:i}=r.options;i&&i.props.style&&"contents"===i.props.style.display||(o&&r.options.layoutScroll&&r.scroll&&r!==r.root&&Au(e,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,ku(e,s)),o&&yu(r.latestValues)&&Au(e,r.latestValues))}t.x<Tu&&t.x>Mu&&(t.x=1),t.y<Tu&&t.y>Mu&&(t.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!t.layout||t.target||1===this.treeScale.x&&1===this.treeScale.y||(t.target=t.layout.layoutBox,t.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}});const{target:l}=t;l?(this.projectionDelta&&this.prevProjectionDelta?(nd(this.prevProjectionDelta.x,this.projectionDelta.x),nd(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),ru(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===s&&this.treeScale.y===a&&md(this.projectionDelta.x,this.prevProjectionDelta.x)&&md(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l)),xd&&gd.recalculatedProjection++):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDeltaWithTransform={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}}setAnimationOrigin(e,t=!1){const n=this.snapshot,o=n?n.latestValues:{},i={...this.latestValues},r={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const s={x:{min:0,max:0},y:{min:0,max:0}},a=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(a&&!c&&!0===this.options.crossfade&&!this.path.some(Od));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;var l,p,h,m,f,g;Ld(r.x,e.x,n),Ld(r.y,e.y,n),this.setTargetDelta(r),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(lu(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),h=this.relativeTarget,m=this.relativeTargetOrigin,f=s,g=n,Dd(h.x,m.x,f.x,g),Dd(h.y,m.y,f.y,g),d&&(l=this.relativeTarget,p=d,ud(l.x,p.x)&&ud(l.y,p.y))&&(this.isProjectionDirty=!1),d||(d={x:{min:0,max:0},y:{min:0,max:0}}),td(d,this.relativeTarget)),a&&(this.animationValues=i,function(e,t,n,o,i,r){i?(e.opacity=bl(0,void 0!==n.opacity?n.opacity:1,Xu(o)),e.opacityExit=bl(void 0!==t.opacity?t.opacity:1,0,Ju(o))):r&&(e.opacity=bl(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,o));for(let i=0;i<qu;i++){const r=`border${Gu[i]}Radius`;let s=Yu(t,r),a=Yu(n,r);void 0===s&&void 0===a||(s||(s=0),a||(a=0),0===s||0===a||Zu(s)===Zu(a)?(e[r]=Math.max(bl(Ku(s),Ku(a),o),0),(Kr.test(a)||Kr.test(s))&&(e[r]+="%")):e[r]=a)}(t.rotate||n.rotate)&&(e.rotate=bl(t.rotate||0,n.rotate||0,o))}(i,o,this.latestValues,n,u,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Ui(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=_i.update((()=>{Lu.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const o=Ar(e)?e:Hs(e);return o.start(Mc("",o,t,n)),o.animation}(0,1e3,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.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 e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:o,latestValues:i}=e;if(t&&n&&o){if(this!==e&&this.layout&&o&&_d(this.options.animationType,this.layout.layoutBox,o.layoutBox)){n=this.target||{x:{min:0,max:0},y:{min:0,max:0}};const t=ou(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const o=ou(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+o}td(t,n),Au(t,i),ru(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new fd);this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const o=this.getStack();o&&o.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;const o={};n.z&&wd("z",e,o,this.animationValues);for(let t=0;t<vd.length;t++)wd(`rotate${vd[t]}`,e,o,this.animationValues),wd(`skew${vd[t]}`,e,o,this.animationValues);e.render();for(const t in o)e.setStaticValue(t,o[t]),this.animationValues&&(this.animationValues[t]=o[t]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return yd;const o={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,o.opacity="",o.pointerEvents=Er(null==e?void 0:e.pointerEvents)||"",o.transform=i?i(this.latestValues,""):"none",o;const r=this.getLead();if(!this.projectionDelta||!this.layout||!r.target){const t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=Er(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!yu(this.latestValues)&&(t.transform=i?i({},""):"none",this.hasProjected=!1),t}const s=r.animationValues||r.latestValues;this.applyTransformsToTarget(),o.transform=function(e,t,n){let o="";const i=e.x.translate/t.x,r=e.y.translate/t.y,s=(null==n?void 0:n.z)||0;if((i||r||s)&&(o=`translate3d(${i}px, ${r}px, ${s}px) `),1===t.x&&1===t.y||(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:e,rotate:t,rotateX:i,rotateY:r,skewX:s,skewY:a}=n;e&&(o=`perspective(${e}px) ${o}`),t&&(o+=`rotate(${t}deg) `),i&&(o+=`rotateX(${i}deg) `),r&&(o+=`rotateY(${r}deg) `),s&&(o+=`skewX(${s}deg) `),a&&(o+=`skewY(${a}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return 1===a&&1===l||(o+=`scale(${a}, ${l})`),o||"none"}(this.projectionDeltaWithTransform,this.treeScale,s),i&&(o.transform=i(s,o.transform));const{x:a,y:l}=this.projectionDelta;o.transformOrigin=`${100*a.origin}% ${100*l.origin}% 0`,r.animationValues?o.opacity=r===this?null!==(n=null!==(t=s.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:o.opacity=r===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0;for(const e in gs){if(void 0===s[e])continue;const{correct:t,applyTo:n,isCSSVariable:i}=gs[e],a="none"===o.transform?s[e]:t(s[e],r);if(n){const e=n.length;for(let t=0;t<e;t++)o[n[t]]=a}else i?this.options.visualElement.renderState.vars[e]=a:o[e]=a}return this.options.layoutId&&(o.pointerEvents=r===this?Er(null==e?void 0:e.pointerEvents)||"":"none"),o}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(Bd),this.root.sharedNodes.clear()}}}function Sd(e){e.updateLayout()}function kd(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:o}=e.layout,{animationType:i}=e.options,r=n.source!==e.layout.source;"size"===i?fu((e=>{const o=r?n.measuredBox[e]:n.layoutBox[e],i=ou(o);o.min=t[e].min,o.max=o.min+i})):_d(i,n.layoutBox,t)&&fu((o=>{const i=r?n.measuredBox[o]:n.layoutBox[o],s=ou(t[o]);i.max=i.min+s,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[o].max=e.relativeTarget[o].min+s)}));const s={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};ru(s,t,n.layoutBox);const a={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};r?ru(a,e.applyTransform(o,!0),n.measuredBox):ru(a,t,n.layoutBox);const l=!cd(s);let c=!1;if(!e.resumeFrom){const o=e.getClosestProjectingParent();if(o&&!o.resumeFrom){const{snapshot:i,layout:r}=o;if(i&&r){const s={x:{min:0,max:0},y:{min:0,max:0}};lu(s,n.layoutBox,i.layoutBox);const a={x:{min:0,max:0},y:{min:0,max:0}};lu(a,t,r.layoutBox),pd(s,a)||(c=!0),o.options.layoutRoot&&(e.relativeTarget=a,e.relativeTargetOrigin=s,e.relativeParent=o)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function Md(e){xd&&gd.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Td(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Pd(e){e.clearSnapshot()}function Bd(e){e.clearMeasurements()}function Ad(e){e.isLayoutDirty=!1}function Ed(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function zd(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Id(e){e.resolveTargetDelta()}function Rd(e){e.calcProjection()}function Vd(e){e.resetSkewAndRotation()}function Fd(e){e.removeLeadSnapshot()}function Ld(e,t,n){e.translate=bl(t.translate,0,n),e.scale=bl(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Dd(e,t,n,o){e.min=bl(t.min,n.min,o),e.max=bl(t.max,n.max,o)}function Od(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const $d={duration:.45,ease:[.4,0,.1,1]},Hd=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Wd=Hd("applewebkit/")&&!Hd("chrome/")?Math.round:Di;function Nd(e){e.min=Wd(e.min),e.max=Wd(e.max)}function _d(e,t,n){return"position"===e||"preserve-aspect"===e&&(o=hd(t),i=hd(n),r=.2,!(Math.abs(o-i)<=r));var o,i,r}function Ud(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}const Gd=Cd({attachResizeListener:(e,t)=>Gc(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),qd={current:void 0},Kd=Cd({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!qd.current){const e=new Gd({});e.mount(window),e.setOptions({layoutScroll:!0}),qd.current=e}return qd.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),Zd={pan:{Feature:class extends $c{constructor(){super(...arguments),this.removePointerDownListener=Di}onPointerDown(e){this.session=new Yc(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:zu(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:o}=this.node.getProps();return{onSessionStart:Fu(e),onStart:Fu(t),onMove:n,onEnd:(e,t)=>{delete this.session,o&&_i.postRender((()=>o(e,t)))}}}mount(){this.removePointerDownListener=Kc(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends $c{constructor(e){super(e),this.removeGroupControls=Di,this.removeListeners=Di,this.controls=new Ru(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Di}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:Kd,MeasureLayout:Wu}};function Yd(e,t){const n=function(e){if(e instanceof Element)return[e];if("string"==typeof e){const t=document.querySelectorAll(e);return t?Array.from(t):[]}return Array.from(e)}(e),o=new AbortController;return[n,{passive:!0,...t,signal:o.signal},()=>o.abort()]}function Xd(e){return!("touch"===e.pointerType||_c())}function Jd(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover","Start"===n);const i=o["onHover"+n];i&&_i.postRender((()=>i(t,qc(t))))}const Qd=(e,t)=>!!t&&(e===t||Qd(e,t.parentElement)),ep=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);const tp=new WeakSet;function np(e){return t=>{"Enter"===t.key&&e(t)}}function op(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function ip(e){return Uc(e)&&!_c()}function rp(e,t,n={}){const[o,i,r]=Yd(e,n),s=e=>{const o=e.currentTarget;if(!ip(e)||tp.has(o))return;tp.add(o);const r=t(o,e),s=(e,t)=>{window.removeEventListener("pointerup",a),window.removeEventListener("pointercancel",l),ip(e)&&tp.has(o)&&(tp.delete(o),"function"==typeof r&&r(e,{success:t}))},a=e=>{s(e,n.useGlobalTarget||Qd(o,e.target))},l=e=>{s(e,!1)};window.addEventListener("pointerup",a,i),window.addEventListener("pointercancel",l,i)};return o.forEach((e=>{(function(e){return ep.has(e.tagName)||-1!==e.tabIndex})(e)||null!==e.getAttribute("tabindex")||(e.tabIndex=0);(n.useGlobalTarget?window:e).addEventListener("pointerdown",s,i),e.addEventListener("focus",(e=>((e,t)=>{const n=e.currentTarget;if(!n)return;const o=np((()=>{if(tp.has(n))return;op(n,"down");const e=np((()=>{op(n,"up")}));n.addEventListener("keyup",e,t),n.addEventListener("blur",(()=>op(n,"cancel")),t)}));n.addEventListener("keydown",o,t),n.addEventListener("blur",(()=>n.removeEventListener("keydown",o)),t)})(e,i)),i)})),r}function sp(e,t,n){const{props:o}=e;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap","Start"===n);const i=o["onTap"+("End"===n?"":n)];i&&_i.postRender((()=>i(t,qc(t))))}const ap=new WeakMap,lp=new WeakMap,cp=e=>{const t=ap.get(e.target);t&&t(e)},up=e=>{e.forEach(cp)};function dp(e,t,n){const o=function({root:e,...t}){const n=e||document;lp.has(n)||lp.set(n,{});const o=lp.get(n),i=JSON.stringify(t);return o[i]||(o[i]=new IntersectionObserver(up,{root:e,...t})),o[i]}(t);return ap.set(e,n),o.observe(e),()=>{ap.delete(e),o.unobserve(e)}}const pp={some:0,all:1};const hp={inView:{Feature:class extends $c{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:o="some",once:i}=e,r={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof o?o:pp[o]};return dp(this.node.current,r,(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,i&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:o}=this.node.getProps(),r=t?n:o;r&&r(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends $c{mount(){const{current:e}=this.node;e&&(this.unmount=rp(e,((e,t)=>(sp(this.node,t,"Start"),(e,{success:t})=>sp(this.node,e,t?"End":"Cancel"))),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends $c{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&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=Pl(Gc(this.node.current,"focus",(()=>this.onFocus())),Gc(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends $c{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[o,i,r]=Yd(e,n),s=e=>{if(!Xd(e))return;const{target:n}=e,o=t(n,e);if("function"!=typeof o||!n)return;const r=e=>{Xd(e)&&(o(e),n.removeEventListener("pointerleave",r))};n.addEventListener("pointerleave",r,i)};return o.forEach((e=>{e.addEventListener("pointerenter",s,i)})),r}(e,((e,t)=>(Jd(this.node,t,"Start"),e=>Jd(this.node,e,"End")))))}unmount(){}}}},mp={layout:{ProjectionNode:Kd,MeasureLayout:Wu}},fp={current:null},gp={current:!1};const xp=[...ul,Aa,Oa],vp=new WeakMap;const yp=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class bp{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:i,visualState:r},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=rl,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 e=Vs.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,_i.render(this.render,!1,!0))};const{latestValues:a,renderState:l,onUpdate:c}=r;this.onUpdate=c,this.latestValues=a,this.baseTarget={...a},this.initialValues=t.initial?{...a}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=o,this.options=s,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=cr(t),this.isVariantNode=ur(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(e&&e.current);const{willChange:u,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(const e in d){const t=d[e];void 0!==a[e]&&Ar(t)&&t.set(a[e],!1)}}mount(e){this.current=e,vp.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((e,t)=>this.bindToMotionValue(t,e))),gp.current||function(){if(gp.current=!0,Fi)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>fp.current=e.matches;e.addListener(t),t()}else fp.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||fp.current),"production"!==process.env.NODE_ENV&&nr(!0!==this.shouldReduceMotion,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){vp.delete(this.current),this.projection&&this.projection.unmount(),Ui(this.notifyUpdate),Ui(this.render),this.valueSubscriptions.forEach((e=>e())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const n=Vr.has(e),o=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&_i.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=t.on("renderRequest",this.scheduleRender);let r;window.MotionCheckAppearSync&&(r=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,(()=>{o(),i(),r&&r(),t.owner&&t.stop()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in Yi){const t=Yi[e];if(!t)continue;const{isEnabled:n,Feature:o}=t;if(!this.features[e]&&o&&n(this.props)&&(this.features[e]=new o(this)),this.features[e]){const t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<yp.length;t++){const n=yp[t];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);const o=e["on"+n];o&&(this.propEventSubscriptions[n]=this.on(n,o))}this.prevMotionValues=function(e,t,n){for(const o in t){const i=t[o],r=n[o];if(Ar(i))e.addValue(o,i),"development"===process.env.NODE_ENV&&nr("12.0.6"===i.version,`Attempting to mix Motion versions ${i.version} with 12.0.6 may not work as expected.`);else if(Ar(r))e.addValue(o,Hs(i,{owner:e}));else if(r!==i)if(e.hasValue(o)){const t=e.getValue(o);!0===t.liveStyle?t.jump(i):t.hasAnimated||t.set(i)}else{const t=e.getStaticValue(o);e.addValue(o,Hs(void 0!==t?t:i,{owner:e}))}}for(const o in n)void 0===t[o]&&e.removeValue(o);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]: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(e){const t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){const n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=Hs(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let o=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];var i;return null!=o&&("string"==typeof o&&(sl(o)||ba(o))?o=parseFloat(o):(i=o,!xp.find(cl(i))&&Oa.test(t)&&(o=Ga(e,t))),this.setBaseTarget(e,Ar(o)?o.get():o)),Ar(o)?o.get():o}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props;let o;if("string"==typeof n||"object"==typeof n){const i=Pr(this.props,n,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);i&&(o=i[e])}if(n&&void 0!==o)return o;const i=this.getBaseTargetFromProps(this.props,e);return void 0===i||Ar(i)?void 0!==this.initialValues[e]&&void 0===o?void 0:this.baseTarget[e]:i}on(e,t){return this.events[e]||(this.events[e]=new Ds),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class wp extends bp{constructor(){super(...arguments),this.KeyframeResolver=pl}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Ar(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}}class jp extends wp{constructor(){super(...arguments),this.type="html",this.renderInstance=hs}readValueFromInstance(e,t){if(Vr.has(t)){const e=Ua(t);return e&&e.default||0}{const o=(n=e,window.getComputedStyle(n)),i=(Lr(t)?o.getPropertyValue(t):o[t])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(e,{transformPagePoint:t}){return Eu(e,t)}build(e,t,n){rs(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return vs(e,t,n)}}class Cp extends wp{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=mu}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(Vr.has(t)){const e=Ua(t);return e&&e.default||0}return t=ms.has(t)?t:gr(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return ys(e,t,n)}build(e,t,n){cs(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,o){fs(e,t,0,o)}mount(e){this.isSVGTag=ps(e.tagName),super.mount(e)}}const Sp=(t,n)=>Mr(t)?new Cp(n):new jp(n,{allowProjection:t!==e.Fragment}),kp=or(Ps({...Wc,...hp,...Zd,...mp},Sp)),Mp=t.styled((({children:e,loading:n,sizing:o,...i})=>ge.jsxs(Jn,{...i,sizing:o,loading:n,children:[n&&ge.jsx(vn,{sizing:o}),ge.jsx(t.Box,{...n?{visibility:"hidden"}:void 0,children:e})]})))((({theme:e,variation:t,sizing:n})=>({color:e.custom.palette.text.primary,...n&&{...Yn(n)},...n&&{...Xn(n)},...n&&{...Zn(n)},"&:hover:before":{backgroundColor:e.custom.palette.interaction.hover},"&:focus:before":{backgroundColor:e.custom.palette.interaction.hover},"&:active:before":{backgroundColor:e.custom.palette.interaction.press},"&:disabled":{backgroundColor:e.custom.palette.interaction.disabled,color:e.custom.palette.text.disabled},..."subtle"===t&&{...Wn(e)},..."outlined"===t&&{...Nn(e)},..."secondary"===t&&{..._n(e)},..."primary"===t&&{...Un(e)}}))),Tp=({sizing:e="lg",variation:t="primary",...n})=>ge.jsx(Mp,{variation:t,sizing:e,...n}),Pp=t.styled(r.TimelineDot)((({theme:e,completed:t})=>({width:"24px",height:"24px",backgroundColor:e.custom.palette.surface.raised,boxShadow:"none",border:"none",padding:0,margin:"4px 0",...!t&&{border:`2px dashed ${e.custom.palette.icon.disabled}`}}))),Bp=t.styled(t.Box)((({theme:e})=>({display:"flex",flexDirection:"column",padding:`0 0 ${e.spacing(e.custom.padding.md)} ${e.spacing(e.custom.padding.sm)}`}))),Ap=e=>({display:"flex",flexWrap:"wrap",alignItems:"center",gap:e.spacing(e.custom.padding.sm),marginTop:e.spacing(e.custom.margin.xs)}),Ep=t.styled(cn)((({theme:e})=>({[`&.${t.linkClasses.root}`]:{...Ap(e),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.link},"&:hover":{"> .MuiTypography-root:first-child":{textDecoration:"underline"},"& .MuiSvgIcon-root":{color:e.custom.palette.icon.linkHover}}}}))),zp=t.styled(t.Box)((({theme:e})=>({[`&.${t.boxClasses.root}`]:{...Ap(e),"& .MuiTypography-root":{color:"inherit"}}}))),Ip=t.styled(dn)((()=>({color:"inherit",fontWeight:500,fontSize:Hn.lg}))),Rp=t.styled(dn)((({theme:e})=>({fontWeight:400,textDecoration:"none",color:e.custom.palette.text.secondary,flexBasis:"100%"}))),Vp=({children:e,complete:t,url:n})=>t?ge.jsx(zp,{children:e}):ge.jsx(Ep,{underline:"none",href:n,target:"_self",children:e}),Fp=({complete:e,title:t,description:n,url:o})=>ge.jsx(Bp,{children:ge.jsxs(Vp,{complete:e,url:o,children:[ge.jsx(Ip,{component:"p",variation:"lg",children:t}),!e&&ge.jsx(en,{name:"arrow-right",size:16}),!e&&n&&ge.jsx(Rp,{variation:"lg",component:"p",children:n})]})}),Lp=({item:e,showConnector:t})=>{const{complete:n,title:o,description:i,url:s}=e;return ge.jsxs(r.TimelineItem,{children:[ge.jsxs(r.TimelineSeparator,{children:[ge.jsx(Pp,{completed:n,children:n?ge.jsx(en,{name:"badge-tick-in-circle",size:24}):void 0}),t&&ge.jsx(r.TimelineConnector,{sx:{backgroundColor:e=>e.custom.palette.icon.disabled}})]}),e&&ge.jsx(r.TimelineContent,{component:()=>ge.jsx(Fp,{complete:n,title:o,description:i,url:s})})]})},Dp=({expanded:n,onToggleExpanded:o,items:i})=>{const s=i.find((e=>!e.complete)),a=e.useMemo((()=>n?i:[s]),[n]),l=e.useRef(null),[c,u]=e.useState("auto");return e.useEffect((()=>{if(!l.current)return;const e=l.current.scrollHeight+1.5*Q;u(e)}),[n,i]),ge.jsx(kp.div,{initial:!1,animate:{height:c},transition:{duration:.4,ease:[.645,.045,.355,1]},style:{overflow:"hidden",paddingBottom:1.5*Q},children:ge.jsx("div",{ref:l,children:ge.jsxs(zi,{sx:{paddingLeft:e=>e.spacing(e.custom.padding.xs),[`& .${r.timelineItemClasses.root}`]:{minHeight:0,":before":{flex:0,padding:0}}},children:[a.map(((e,t)=>{const n=t<a.length-1;return e&&e?.title===s?.title?ge.jsx(Lp,{item:e,showConnector:a.length>1?n:!!s?.description},e.title):e&&ge.jsx(Lp,{item:e,showConnector:n},e.title)})),!n&&ge.jsx(t.Box,{sx:{marginTop:e=>e.spacing(e.custom.margin.md),alignSelf:"center"},children:ge.jsx(Tp,{endIcon:ge.jsx(en,{name:"chevron-down",size:16}),sizing:"xs",variation:"outlined",onClick:o,children:"Show more"})})]})})})},Op=({completed:e,total:t})=>ge.jsx(dn,{component:"p",variation:"lg",sx:{fontWeight:500},children:`${e} of ${t} tasks completed`}),$p=t.styled(t.Box)((({theme:e})=>({width:2,height:2,borderRadius:"50%",backgroundColor:e.custom.palette.icon.disabled,marginLeft:e.spacing(e.custom.margin.sm),marginRight:e.spacing(e.custom.margin.sm)}))),Hp=(e,n)=>ge.jsxs(t.Box,{display:"flex",gap:1,children:[ge.jsx(dn,{variation:"sm",component:"p",weight:"bold",children:e||0}),ge.jsx(dn,{variation:"sm",component:"p",color:"text.secondary",children:n})]}),Wp=({loops:e,tests:n,drafts:o})=>ge.jsxs(t.Box,{display:"flex",alignItems:"center",children:[Hp(e,"Loops"),ge.jsx($p,{}),Hp(n,"Tests"),ge.jsx($p,{}),Hp(o,"Drafts")]}),Np=t.styled(t.Box)((({theme:e})=>({borderRadius:e.spacing(e.custom.radius.sm),border:`0.5px solid ${e.custom.palette.stroke.focus}`,backgroundColor:e.custom.palette.purple[0],padding:`${e.spacing(e.custom.padding.xs)} ${e.spacing(e.custom.padding.sm)}`,"& p":{color:e.custom.palette.purple[1e3]}}))),_p=({sx:e,body:t})=>ge.jsx(Np,{"data-id":"pill-container",sx:n.mergeSx(e,{position:"absolute",zIndex:1}),children:ge.jsx(dn,{variation:"xxs",component:"p",weight:"bold",children:t})}),Up=({title:e,maxLines:t,sx:o})=>ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:n.mergeSx({overflow:"hidden",display:"-webkit-box","-webkit-line-clamp":`${t}`,"-webkit-box-orient":"vertical"},o),children:e}),Gp=e=>{const t=e.toLowerCase();return["a","e","i","o","u"].some((e=>t.startsWith(e)))?"an":"a"},qp=(e,t,n)=>({maxLength:{value:n||255,message:`Maximum character limit of ${n||255}.`},...t&&{required:e?`Please enter ${Gp(e)} ${e}`:"This field is required"}}),Kp=qp().maxLength.value,Zp=e=>`linear-gradient(135deg, ${e.custom.palette.purple[400]} 0%, ${e.custom.palette.purple[200]} 100%)`,Yp=(e,n)=>{switch(n){case"tone1":default:return Zp(e);case"tone2":return(e=>`linear-gradient(135deg, ${e.custom.palette.purple[0]} 0%, ${e.custom.palette.purple[100]} 100%)`)(e);case"tone3":return(e=>`linear-gradient(135deg, ${e.custom.palette.blue[400]} 0%, ${e.custom.palette.purple[600]} 100%)`)(e);case"tone4":return(e=>`radial-gradient(54.59% 50% at 0% 50.04%, ${t.alpha(e.custom.palette.blue[1e3],.2)} 0%, ${t.alpha(e.custom.palette.blue[500],.2)} 100%), linear-gradient(135deg, ${e.custom.palette.purple[500]} 0%, ${e.custom.palette.purple[1e3]} 100%)`)(e)}},Xp=(e,t)=>{const n=Yp(e,t.gradient),o=(e=>"noise1"===e?"url(https://useloops-public.s3.eu-west-2.amazonaws.com/public/static/misc/noise_tile.png)":null)(t.texture);return o?[o,n].join(","):[n].join(",")},Jp=({label:e,sx:o,...i})=>{const r=t.useTheme(),s=e?r.custom.margin.md:0;return ge.jsx(t.FormControlLabel,{label:e||"",sx:n.mergeSx({ml:0,"&.Mui-disabled":{color:r.custom.palette.text.disabled},"&.Mui-error":{color:r.custom.palette.text.negative},"& .MuiFormControlLabel-label":{ml:s,color:"inherit",fontSize:{xs:On.sm.body.md,sm:On.sm.body.md,md:On.sm.body.md,lg:On.lg.body.md,xl:On.lg.body.md}},"&.MuiFormControlLabel-labelPlacementStart":{"& .MuiFormControlLabel-label":{ml:0,mr:s}}},o),...i})},Qp=t.styled(t.Checkbox)((({theme:e,sizing:t})=>({height:"default"===t?J[300]:J[400],width:"default"===t?J[300]:J[400],padding:0,flex:"none",borderRadius:e.spacing(e.custom.radius.sm),border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.input.default,position:"relative",transition:e.custom.easing.input,"& svg":{transition:e.custom.easing.input,fill:"none",width:"default"===t?Qt.sm:Qt.xl,height:"default"===t?Qt.sm:Qt.xl},"&:before":{content:'""',position:"absolute",inset:0},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled},"&.Mui-checked":{backgroundColor:e.custom.palette.purple[500],"& svg":{fill:e.custom.palette.icon.lockedWhite},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,"& svg":{fill:e.custom.palette.icon.disabled}}},"&.MuiCheckbox-indeterminate":{backgroundColor:e.custom.palette.purple[500],"& svg":{fill:e.custom.palette.icon.lockedWhite}},"&.Mui-focusVisible":{borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}}}))),eh=e=>ge.jsx(Qp,{checkedIcon:ge.jsx(o.Check,{}),indeterminateIcon:ge.jsx(o.Remove,{}),...e}),th=({internalChange:e,checkboxLabel:n,indeterminate:o,sizing:i="default",onChange:r,inputRef:s,value:a,...l})=>void 0===a?ge.jsx(t.Box,{}):ge.jsx(Jp,{inputRef:s,label:n,checked:a,control:ge.jsx(eh,{sizing:i,indeterminate:o}),onChange:(t,n)=>{r&&r(t,n),e&&e()},...l}),nh=t.styled(t.TextField)((({theme:e})=>({"& .MuiInputAdornment-root":{marginRight:0,"& .MuiSvgIcon-root":{width:Qt.xl,height:Qt.xl}},"& .MuiOutlinedInput-input":{padding:e.spacing(1),paddingLeft:e.spacing(2),paddingRight:e.spacing(2)},"& .MuiOutlinedInput-root":{backgroundColor:e.custom.palette.input.default,color:e.custom.palette.text.primary,borderRadius:e.spacing(e.custom.radius.md),lineHeight:"140%",[e.breakpoints.down("md")]:{minWidth:"100%"},paddingLeft:0,paddingRight:0,fontSize:On.sm.body.md,"&.Mui-focused":{"& fieldset":{transition:e.custom.easing.input,backgroundColor:e.custom.palette.interaction.press,borderColor:e.custom.palette.stroke.default},"& .MuiOutlinedInput-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.focus}`,boxShadow:e.custom.boxShadow.input.focus}},"&.Mui-disabled":{color:e.custom.palette.text.disabled,backgroundColor:e.custom.palette.input.disabled,"& fieldset":{transition:e.custom.easing.input,backgroundColor:e.custom.palette.interaction.none,borderColor:e.custom.palette.stroke.disabled},"& .MuiOutlinedInput-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.disabled}`,boxShadow:"none"}}},"&:hover":{"& .MuiOutlinedInput-root":{backgroundColor:e.custom.palette.input.default,"& fieldset":{backgroundColor:e.custom.palette.interaction.hover,borderColor:e.custom.palette.stroke.default},"&.Mui-focused":{"& fieldset":{backgroundColor:e.custom.palette.interaction.press,borderColor:e.custom.palette.stroke.default},"& .MuiOutlinedInput-notchedOutline":{border:`1px solid ${e.custom.palette.stroke.focus}`,boxShadow:e.custom.boxShadow.input.focus}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,"& fieldset":{backgroundColor:e.custom.palette.interaction.none,borderColor:e.custom.palette.stroke.disabled},"& .MuiOutlinedInput-notchedOutline":{border:`1px solid ${e.custom.palette.stroke.disabled}`,boxShadow:"none"}}}}}))),oh=({startAdornment:e,endAdornment:n,placeholder:o,onChange:i,internalChange:r,inputRef:s,...a})=>ge.jsx(nh,{placeholder:o,sx:{height:J[500],"& .MuiOutlinedInput-input":{pl:e?1:2,pr:e?1:2}},inputRef:s,InputProps:{startAdornment:e?ge.jsx(t.InputAdornment,{position:"start",sx:{pl:1},children:e}):null,endAdornment:n?ge.jsx(t.InputAdornment,{position:"start",sx:{pr:1},children:n}):null},...a,onChange:e=>{i&&i(e),r&&r()}}),ih=({sizing:e,options:n,other:o,internalChange:i,value:r,inputRef:s,onChange:a})=>{const l=o?.name||"other-option",c=`${l}-value-`,u=e=>`${c}${e}`,d=o?.enabled,p=r?.includes(l)&&d,h=r?.find((e=>e.includes(c)));if(!r)return ge.jsx("div",{});const m=(e,t)=>{let s=r.includes(e)?r.filter((t=>t!==e)):t?[e]:[...new Set(r),e];if(t||(s=s.filter((e=>!n.find((t=>t?.exclusive&&e===t.value))))),o?.enabled){!r.includes(l)||e!==l||(s=s.filter((e=>!e.includes(c))))}a(s),i&&i()};return ge.jsxs(ge.Fragment,{children:[ge.jsxs(t.FormGroup,{sx:{display:"flex",gap:e=>e.custom.margin.sm,label:{"&:last-child":{mb:0},"&:hover":{"& .MuiCheckbox-root":{backgroundColor:e=>e.custom.palette.interaction.hover,"&.Mui-checked":{backgroundColor:e=>e.custom.palette.purple[500]}}}}},children:[n?n.map(((t,n)=>{const o=t.value;return ge.jsx(Jp,{sx:{"& .MuiButtonBase-root.MuiCheckbox-root":{alignSelf:"baseline"},"& .MuiTypography-root":{mt:"default"!==e?.5:0}},onChange:()=>m(o,t.exclusive),checked:r.includes(o),control:ge.jsx(eh,{sizing:e}),label:t.label},o)})):null,d&&ge.jsx(Jp,{inputRef:s,onChange:()=>m(l),label:o?.label||"Other",checked:r.includes(l),control:ge.jsx(eh,{sizing:e})},l)]}),p&&ge.jsx(t.Box,{sx:{mt:1},children:ge.jsx(oh,{fullWidth:!0,autoFocus:!0,defaultValue:h?h.replace(c,""):"",placeholder:o?.placeholder,onChange:e=>{const t=r.find((e=>e.includes(c))),n=(t?r.map((t=>t.includes(c)?u(e.target.value):t)):[...r,u(e.target.value)]).filter((e=>e!==c));a(n),i&&i()},required:!0})})]})},rh=({inputField:e,onChange:t,internalChange:n,transformValue:o,...i})=>{const r=e;return ge.jsx(r,{onChange:e=>{t&&t(o?o(e):e),n&&n()},...i})},sh=t.styled(t.InputLabel)((({theme:e,align:t})=>({fontWeight:400,lineHeight:"140%",whiteSpace:"normal",textAlign:t,color:"inherit","&.Mui-disabled":{color:e.custom.palette.text.disabled},"&.Mui-error":{color:e.custom.palette.text.negative}}))),ah=e=>ge.jsx(sh,{...e}),lh=e=>{const{icon:n=null,state:i="default",disabled:r,showicon:s=!0}=e,a=t.useTheme();return ge.jsxs(t.Box,{sx:{display:"inline-flex",alignItems:"center",color:r?a.custom.palette.text.disabled:(()=>{switch(i){case"disabled":return a.custom.palette.text.disabled;case"positive":return a.custom.palette.text.positive;case"negative":return a.custom.palette.text.negative;default:return a.custom.palette.text.secondary}})(),"& svg":{marginRight:a.spacing(a.custom.margin.xs),width:Qt.xs,height:Qt.xs,color:"inherit"}},children:[(()=>{if(!s)return null;if(n)return n;switch(i){case"disabled":default:return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.Info,{})});case"positive":return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.Check,{})});case"negative":return ge.jsx(t.Box,{sx:{height:20,display:"flex",alignItems:"center",alignSelf:"flex-start"},children:ge.jsx(o.ErrorOutline,{})})}})(),ge.jsx(ah,{...e,sx:{fontSize:{xs:On.sm.body.sm,sm:On.sm.body.sm,md:On.sm.body.sm,lg:On.lg.body.sm,xl:On.lg.body.sm}}})]})},ch=t.styled(t.Box)((({theme:e})=>({"& .MuiGrid-item":{"&:first-of-type":{"& .MuiBox-root":{"& .MuiRadio-root":{"&:before":{content:'""',position:"absolute",width:J[50],height:J[50],top:`calc(100% + ${J[50]}px)`,margin:"0 auto",background:e.custom.palette.stroke.default}}}},"&:last-of-type":{"& .MuiBox-root":{"& .MuiRadio-root":{"&:before":{content:'""',position:"absolute",width:J[50],height:J[50],top:`calc(100% + ${J[50]}px)`,margin:"0 auto",background:e.custom.palette.stroke.default}}}}}}))),uh=({children:e,width:t})=>ge.jsx(ch,{sx:{width:t,minWidth:300},children:e}),dh=t.styled(t.Radio)((({theme:e,sizing:t})=>({padding:0,backgroundColor:e.custom.palette.input.default,border:`1px solid ${e.custom.palette.stroke.default}`,position:"relative",transition:e.custom.easing.input,flexShrink:0,height:"default"===t?J[300]:J[400],width:"default"===t?J[300]:J[400],"& svg":{transition:e.custom.easing.input,fill:"none",width:"default"===t&&Qt.sm,height:"default"===t&&Qt.sm},"&:before":{content:'""',position:"absolute",inset:0,borderRadius:e.custom.radius.round},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.disabled}},"&.Mui-focusVisible":{borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus,"&:before":{backgroundColor:e.custom.palette.interaction.press}},"&.Mui-checked":{backgroundColor:e.custom.palette.purple[500],"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.lockedWhite},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& svg":{"&:first-of-type":{fill:"transparent"},fill:e.custom.palette.icon.disabled}}}}))),ph=e=>ge.jsx(dh,{...e}),hh=t.styled(ph)((()=>({marginRight:0}))),mh=t.styled(t.Box)((({theme:e})=>({posiion:"relative","&:after":{content:'""',position:"absolute",top:"50%",right:"0",height:J[50],width:`calc(100% - ${J[400]}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default}}))),fh=e=>ge.jsx(mh,{sx:{position:"relative"},children:ge.jsx(hh,{...e})}),gh=({disabled:e=!1,onChange:n,labelLeft:o,labelRight:i,internalChange:r,labelCenter:s})=>{const a=[...Array(7).keys()];return ge.jsx(t.RadioGroup,{children:ge.jsxs(uh,{children:[ge.jsx(t.Grid,{container:!0,justifyContent:"space-between",children:a.map(((o,i)=>{const s=i+1!==a.length;return ge.jsx(t.Grid,{item:!0,sm:s,children:ge.jsx(fh,{disabled:e,value:o,onChange:(e,t)=>{n&&n(e,t),r&&r()},name:`radio-option-${o}`},o)},o)}))}),ge.jsxs(t.Grid,{container:!0,justifyContent:"space-between",sx:{mt:1},children:[ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"left"},children:ge.jsx(lh,{disabled:e,showicon:!1,children:o})}),ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"center"},children:ge.jsx(lh,{disabled:e,align:"center",showicon:!1,children:s})}),ge.jsx(t.Grid,{item:!0,sm:!0,sx:{textAlign:"right"},children:ge.jsx(lh,{disabled:e,align:"right",showicon:!1,children:i})})]})]})})},xh=t.styled(t.Menu)((({theme:e})=>({"& .MuiPaper-root":{backgroundColor:e.custom.palette.surface.raised,borderRadius:e.spacing(e.custom.radius.sm),marginTop:e.spacing(1),minWidth:180,border:`1px solid ${e.custom.palette.stroke.default}`,boxShadow:"none","& .MuiMenu-list":{padding:`${e.spacing(e.custom.padding.xs)} 0`},"& .MuiMenuItem-root":{"& .MuiSvgIcon-root":{color:e.custom.palette.text.primary},"&:active":{backgroundColor:t.alpha(e.palette.primary.main,e.palette.action.selectedOpacity)}}}}))),vh=t=>{const n=e.useRef();return e.useEffect((()=>{n.current=t}),[t]),n.current},yh=({children:e,...t})=>e,bh=({sx:e,...t})=>ge.jsx(ah,{...t,sx:n.mergeSx({fontSize:{xs:On.sm.body.md,sm:On.sm.body.md,md:On.sm.body.md,lg:On.lg.body.md,xl:On.lg.body.md}},!!e&&{...e})}),wh=t.styled(t.Box)((({theme:e})=>({"& .MuiGrid-item":{"&:first-of-type":{"& .MuiBox-root":{"&:before":{width:J[200],borderRadius:e.custom.radius.round,right:"50%",transform:`translateX(-${J[200]}px)`,left:"auto"}}},"&:last-child":{"& .MuiBox-root":{"&:after":{width:J[200],borderRadius:e.custom.radius.round,right:"auto",left:"50%",transform:`translateX(${J[200]}px)`}}}}}))),jh=({children:e,width:t})=>ge.jsx(wh,{sx:{width:t},children:e}),Ch=t.styled(lh)((()=>({lineHeight:"110%",textAlign:"center",width:"100%"}))),Sh=({disabled:e,children:t})=>ge.jsx(Ch,{showicon:!1,disabled:e,sx:{cursor:"inherit"},children:t}),kh=t.styled(ph)((()=>({marginRight:0}))),Mh=t.styled(t.Box)((({theme:e})=>({posiion:"relative","&:before":{content:'""',position:"absolute",top:"50%",left:0,height:J[50],width:`calc(50% - ${J[400]/2}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default},"&:after":{content:'""',position:"absolute",top:"50%",right:0,height:J[50],width:`calc(50% - ${J[400]/2}px)`,zIndex:0,backgroundColor:e.custom.palette.stroke.default}}))),Th=e=>ge.jsx(Mh,{sx:{textAlign:"center",position:"relative"},children:ge.jsx(kh,{...e})}),Ph=({options:e=[],disabled:n=!1,sizing:o="lg",onChange:i,internalChange:r,value:s})=>{const a=t.useTheme();function l(e){console.warn(e),i(e.value),r&&r()}return ge.jsx(t.Box,{children:ge.jsx(jh,{children:ge.jsx(t.Grid,{container:!0,justifyContent:"space-between",children:e.map((e=>ge.jsxs(t.Grid,{item:!0,sm:!0,onClick:()=>l(e),sx:{...!n&&{cursor:"pointer"},textAlign:"center","&:hover":{"& .MuiButtonBase-root.MuiRadio-root":{"&:before":{...!n&&{backgroundColor:a.custom.palette.interaction.hover}}}},"&:active":{"& .MuiButtonBase-root.MuiRadio-root":{...!n&&{backgroundColor:a.custom.palette.input.default,borderColor:a.custom.palette.stroke.focus,boxShadow:a.custom.boxShadow.input.focus},"&:before":{...!n&&{backgroundColor:a.custom.palette.interaction.press}},"&.Mui-checked":{backgroundColor:a.custom.palette.purple[500]}}}},children:[ge.jsx(Th,{sizing:o,disabled:n,onChange:t=>l(e),checked:s===e.value},e.value),ge.jsx(t.Box,{sx:{mt:ee.xs,width:"100%"},children:ge.jsx(Sh,{disabled:n,children:e.label})})]},e.value)))})})})},Bh=e.forwardRef(((t,n)=>{const{decimalSeparator:o,thousandSeparator:i,value:r,...s}=t,a=e.useMemo((()=>{return e=void 0,new Intl.NumberFormat(e).formatToParts(1234.5678).find((e=>"group"===e.type))?.value??"";var e}),[void 0]),l=e.useMemo((()=>{return e=void 0,new Intl.NumberFormat(e).formatToParts(1234.5678).find((e=>"decimal"===e.type))?.value??".";var e}),[void 0]);return ge.jsx(u.NumericFormat,{...s,value:r??"",getInputRef:n,thousandSeparator:i??a,decimalSeparator:o??l})})),Ah=({disabled:n=!1,InputProps:i,inputProps:r,placeholder:s,hideActionButtons:a=!1,max:l=1/0,min:c=-1/0,startAdornment:u,endAdornment:d,internalChange:p,numericFormatProps:h,onChange:m,step:f=1,value:g,...x})=>{const v=t.useTheme(),[y,b]=e.useState(g),w=y,j=e=>{b(e),m&&m(e),p&&p()},C=()=>{const e=(null==w||Number.isNaN(w)?0:w)+f;e>l||j(e)},S=()=>{const e=(null==w||Number.isNaN(w)?0:w)-f;e<c||j(e)},k={decimalScale:5,isAllowed:({floatValue:e})=>null==e||e>=c&&e<=l,max:l!==1/0?l:void 0,min:c!==-1/0?c:void 0,step:1!==f?f:void 0,onKeyDown:e=>{"ArrowUp"===e.key?C():"ArrowDown"===e.key&&S()},onValueChange:({floatValue:e})=>{e!==w&&j(e)},value:w,...h};return ge.jsx(nh,{placeholder:s,sx:{height:J[500],"& .MuiOutlinedInput-input":{minWidth:J[300],pl:u?1:2,pr:u?1:2}},...x,value:w??"",disabled:n,InputProps:{...i,inputComponent:Bh,startAdornment:u?ge.jsx(t.InputAdornment,{position:"start",sx:{pl:1},children:u}):null,endAdornment:!a&&ge.jsxs(t.Stack,{gap:v.custom.margin.sm,sx:{height:"100%",alignItems:"center"},direction:"row",children:[d&&ge.jsx(t.InputAdornment,{position:"end",children:d}),ge.jsxs(t.Stack,{sx:{height:"100%",ml:"auto",width:32,borderLeft:`1px solid ${v.custom.palette.stroke.default}`},children:[ge.jsx(t.ButtonBase,{onClick:()=>C(),sx:{flex:1,borderTopRightRadius:v.spacing(v.custom.radius.md),fontSize:12,"&:hover":{background:v.custom.palette.interaction.hover}},children:ge.jsx(o.ArrowDropUp,{fontSize:"inherit"})}),ge.jsx(t.Divider,{}),ge.jsx(t.ButtonBase,{onClick:()=>S(),sx:{flex:1,borderBottomRightRadius:v.spacing(v.custom.radius.md),fontSize:12,"&:hover":{background:v.custom.palette.interaction.hover}},children:ge.jsx(o.ArrowDropDown,{fontSize:"inherit"})})]})]})},inputProps:{inputType:"number",...r,...k}})};const Eh=({options:n,onChange:o,other:i,value:r,internalChange:s,...a})=>{const l=i?.enabled,c="other-option",u=`${c}-value-`,[d,p]=e.useState(r),[h,m]=e.useState(!1),f=e.useRef(null);e.useEffect((()=>{!h&&d?.includes(u)?m(!0):h&&m(!1)}),[d]);return e.useEffect((()=>{f.current&&Array.from(f.current.getElementsByTagName("label")).forEach((e=>{if(e.clientHeight>4*Q){const t=e.querySelector(".MuiTypography-root");t&&(t.style.marginTop=Q/2+"px")}}))}),[f.current]),ge.jsxs(ge.Fragment,{children:[ge.jsxs(t.RadioGroup,{...a,value:d,ref:f,sx:{"& .MuiRadio-root":{alignSelf:"baseline"},"& .MuiTypography-root":{alignSelf:"center"},display:"flex",alignSelf:"baseline",gap:e=>e.custom.margin.sm,label:{"&:last-child":{mb:0},"&:hover":{"& .MuiRadio-root":{backgroundColor:e=>e.custom.palette.interaction.hover,"&.Mui-checked":{backgroundColor:e=>e.custom.palette.purple[500]}}}}},onChange:(e,t)=>{o&&o(t),p(t),s&&s()},children:[n?n.map(((e,t)=>ge.jsx(Jp,{sx:{"& .MuiButtonBase-root.MuiRadio-root":{alignSelf:"baseline"}},...e,control:ge.jsx(ph,{})},t))):null,l&&ge.jsx(Jp,{label:i?.label||"Other",value:u,control:ge.jsx(ph,{checked:d?.includes(u)})},c)]}),h&&ge.jsx(t.Box,{sx:{mt:1},children:ge.jsx(oh,{fullWidth:!0,autoFocus:!0,placeholder:i?.placeholder,defaultValue:d?.replace(u,""),onChange:e=>{var t;o&&o((t=e.target.value,`${u}${t}`)),s&&s()},required:!0})})]})},zh=({handleSelectAll:n,isIndeterminate:o,isAllSelected:i,sizing:r})=>{const[s,a]=e.useState(!1),l=t.useTheme();return e.useEffect((()=>{i&&a(i)}),[i]),ge.jsxs(t.Stack,{direction:"row",gap:l.spacing(l.custom.padding.sm),onClick:e=>{const t=!s;a(t),n(e,t)},sx:{marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",p:e=>e.custom.padding.sm},children:[ge.jsx(t.FormLabel,{sx:{cursor:"pointer",fontSize:()=>r&&Hn[r]},children:"Select all"}),ge.jsx(eh,{sizing:"default",indeterminate:o,checked:s})]})},Ih=e.forwardRef((({children:e,handleSelectAll:t,showSelectAll:n,value:o=[],selections:i,sizing:r,...s},a)=>{const l=Array.isArray(o)&&o.length===i.length,c=Array.isArray(o)&&o.length>0&&o.length<i.length;return ge.jsxs("ul",{ref:a,...s,children:[n&&ge.jsx(zh,{handleSelectAll:t,isIndeterminate:c,isAllSelected:l,sizing:r}),e]})})),Rh="0px 4px 8px 0px #06040D14, 0px 16px 24px 0px #06040D14, 0px 0px 4px 2px #06040D0A, 0px 0px 0px 1px #FFFFFF29",Vh=e=>{switch(e){case"xs":return 24;case"md":return 32;default:return 40}},Fh=(e,t)=>({"& .MuiTypography-root":{height:Vh(t),fontSize:Hn[t],display:"flex",alignItems:"center",paddingLeft:e.spacing("xs"===t?e.custom.padding.xs:e.custom.padding.sm),paddingRight:e.spacing("xs"===t?e.custom.padding.xs:e.custom.padding.sm)}}),Lh=e=>({fontSize:`${On.sm.body.md}`,borderRadius:e.spacing(e.custom.radius.md),position:"relative",padding:e.spacing(e.custom.padding.sm),"& .MuiSelect-outlined":{padding:0},"& .MuiSelect-select.MuiInputBase-input":{paddingRight:e.spacing(te.md)},"&:before":{transition:e.custom.easing.input,content:'""',position:"absolute",background:e.custom.palette.interaction.none,borderRadius:e.spacing(e.custom.radius.md),inset:0,zIndex:0},"&:hover:before":{backgroundColor:e.custom.palette.interaction.hover},"&.Mui-focused:before":{backgroundColor:e.custom.palette.interaction.press},"&.Mui-disabled:before":{backgroundColor:e.custom.palette.interaction.none},"& .MuiSelect-select":{position:"relative"}}),Dh=(e,t)=>{switch(t){case"lg":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.lg,height:Qt.lg,top:`calc(50% - ${Qt.lg/2}px)`}};case"md":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.md,height:Qt.md,top:`calc(50% - ${Qt.md/2}px)`}};case"xs":return{height:Vh(t),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.xs,height:Qt.xs,top:`calc(50% - ${Qt.xs/2}px)`}};default:return{height:Vh("lg"),"& .MuiSvgIcon-root":{color:e.custom.palette.icon.primary,transition:e.custom.easing.input,width:Qt.lg,height:Qt.lg,top:`calc(50% - ${Qt.lg/2}px)`}}}},Oh=e=>({position:"relative",fontSize:`${On.sm.body.md}`,backgroundColor:e.custom.palette.interaction.none,color:e.custom.palette.text.primary,"&:before":{transition:e.custom.easing.input,content:'""',position:"absolute",inset:0,zIndex:1},"& > .MuiBox-root":{position:"relative",zIndex:2,width:"100%","& .MuiSvgIcon-root":{marginRight:e.spacing(e.custom.margin.sm),width:Qt.xl,height:Qt.xl},"& .MuiBox-root":{padding:e.spacing(e.custom.padding.sm),lineHeight:"22px"}}}),$h=e=>({"&.MuiModal-root.MuiPopover-root":{"&.MuiMenu-root":{borderRadius:e.spacing(e.custom.radius.sm),"& .MuiPaper-root":{border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.raised,boxShadow:Rh}}}}),Hh=t.styled(t.Autocomplete)((({theme:e,sizing:t,value:n})=>({maxWidth:"100%",backgroundColor:e.custom.palette.surface.raised,borderRadius:e.spacing(e.custom.radius.md),border:`1px solid ${e.custom.palette.stroke.default}`,transition:e.custom.easing.input,"& .MuiSvgIcon-root":{...t&&{width:Qt[t],height:Qt[t]}},"&.MuiAutocomplete-root .MuiOutlinedInput-root .MuiAutocomplete-input":{...t&&{height:"xs"===t?2*Q+"px":3*Q+"px"},paddingTop:0,paddingBottom:0,paddingLeft:n&&Array.isArray(n)&&n.length>0?0:e.spacing(e.custom.padding.sm),justifyContent:"center",textOverflow:"ellipsis",whiteSpace:"nowrap"},"& .MuiAutocomplete-inputRoot":{...t&&{fontSize:Hn[t],gap:"lg"===t?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs)},display:"flex",alignItems:"flex-start",paddingRight:3*Q+"px",flexWrap:"wrap",height:"auto"},"& .MuiOutlinedInput-root":{display:"flex",alignItems:"center",padding:"0"},"& .MuiAutocomplete-tag":{...t&&{height:"xs"===t?2*Q+"px":3*Q+"px"},margin:0,"& .MuiSvgIcon-root":{height:"12px",width:"12px"}},"&.Mui-disabled":{backgroundColor:`${e.custom.palette.input.disabled}`,borderColor:`${e.custom.palette.stroke.disabled}`},"&.Mui-focused":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus},"& .MuiChip-root .MuiChip-label":{height:20,lineHeight:"20px",maxWidth:140,...t&&{padding:`0 ${e.spacing(e.custom.padding.xs)}`}}}))),Wh=t.styled(t.Chip)((({theme:e,sizing:t})=>({borderRadius:e.spacing(e.custom.radius.sm),border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.default,...t&&{padding:`0 ${e.spacing(e.custom.padding.xs)}`},"& .MuiChip-deleteIcon":{fill:e.custom.palette.icon.primary,borderRadius:e.custom.radius.round,margin:0,"&:hover":{backgroundColor:e.custom.palette.interaction.hover},"&:active":{backgroundColor:e.custom.palette.interaction.press},"&:disabled":{backgroundColor:e.custom.palette.interaction.disabled,fill:e.custom.palette.icon.disabled}}}))),Nh=t.styled(t.TextField)((({theme:e,sizing:t})=>({"& .MuiOutlinedInput-root":{padding:0,...t&&{margin:"lg"===t?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs)}},"& .MuiInputBase-input":{padding:"0 14px"},"& .MuiOutlinedInput-notchedOutline":{border:"none"}}))),_h=t.styled(t.Popper)((({theme:e,sizing:n})=>({"& .MuiPaper-root":{...n&&{margin:"lg"===n?e.spacing(e.custom.padding.sm):e.spacing(e.custom.padding.xs),marginLeft:"lg"===n?`-${e.spacing(e.custom.padding.sm)}`:`-${e.spacing(e.custom.padding.xs)}`,marginTop:`calc(${"lg"===n?e.spacing(e.custom.margin.sm):e.spacing(e.custom.margin.xs)} + ${e.spacing(e.custom.margin.xs)})`},border:`1px solid ${e.custom.palette.stroke.default}`,backgroundColor:e.custom.palette.surface.raised,boxShadow:Rh,borderRadius:e.spacing(e.custom.radius.sm)},[`& .${t.autocompleteClasses.listbox}`]:{overflowX:"hidden",[`& .${t.autocompleteClasses.option}`]:{fontSize:Hn[n],...n&&{height:"lg"===n?5*Q+"px":4*Q+"px"},"> span":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},'&[aria-selected="true"]':{backgroundColor:e.custom.palette.interaction.hover,display:"flex",alignItems:"center",justifyContent:"space-between"}}}}))),Uh=e=>ge.jsx(_h,{...e}),Gh=({selections:t,disableClearable:n=!1,disabled:i,internalChange:r,multiple:s=!0,onChange:a,placeholder:l="",renderListItem:c,sizing:u="lg",value:d=(s?[]:"")})=>{const[p,h]=e.useState(t.filter((e=>d.includes(e?.value)))),m=(e,n)=>{if(a){const o=n?t.map((({value:e})=>e)):[];h(n?t:[]),a(e,o,"selectOption"),r&&r()}},f=e=>null!==e&&(!Array.isArray(e)||e.length>0);return ge.jsx(Hh,{disabledItemsFocusable:!0,autoFocus:!1,disableCloseOnSelect:!0,blurOnSelect:!1,popupIcon:ge.jsx(o.KeyboardArrowDown,{}),sizing:u,disabled:i,disableClearable:n,autoComplete:!0,multiple:s,renderInput:e=>ge.jsx(Nh,{...e,placeholder:f(p)?void 0:l,sizing:u}),options:t,renderTags:(e,t)=>e.map(((e,n)=>{const{key:i,...r}=t({index:n});return ge.jsx(Wh,{sizing:u,deleteIcon:ge.jsx(o.CloseRounded,{fontSize:"small"}),label:e.label,...r},i)})),onChange:(e,t,n)=>{const o=Array.isArray(t)?t.map((e=>e.value)):t?.value??null;h(t),a?.(e,o,n),r?.()},PopperComponent:e=>ge.jsx(Uh,{...e,sizing:u}),isOptionEqualToValue:(e,t)=>e.value===t.value,renderOption:(e,t,{selected:n})=>{const{key:i,...r}=e;return ge.jsxs("li",{...r,children:[ge.jsx("span",{children:c?c(t.value,t.label):t.label}),ge.jsx(o.Check,{sx:{visibility:n?"visible":"hidden",fontSize:"16px"}})]},i)},ListboxComponent:e.forwardRef(((e,n)=>ge.jsx(Ih,{ref:n,...e,showSelectAll:s,handleSelectAll:m,value:p,selections:t,sizing:u}))),value:p})},qh=t.styled(t.MenuItem)((({theme:e})=>({...{...Oh(e)},"&.Mui-focusVisible":{backgroundColor:e.custom.palette.interaction.none},"&.Mui-selected":{backgroundColor:e.custom.palette.input.default,"&.Mui-focusVisible":{backgroundColor:e.custom.palette.input.default}},"&.MuiButtonBase-root.MuiMenuItem-root.Mui-disabled":{backgroundColor:e.custom.palette.input.default,color:e.custom.palette.text.disabled,"&:before":{backgroundColor:e.custom.palette.interaction.disabled}},"&:hover":{backgroundColor:e.custom.palette.input.default,"&:before":{backgroundColor:e.custom.palette.interaction.hover},"&.Mui-selected":{backgroundColor:e.custom.palette.input.default,"&.Mui-focusVisible":{"&:before":{backgroundColor:e.custom.palette.interaction.hover}},"&:before":{backgroundColor:e.custom.palette.interaction.hover}}},"&:active":{"&:before":{backgroundColor:e.custom.palette.interaction.press}}}))),Kh=({children:e,selected:n,...i})=>ge.jsx(qh,{...i,children:ge.jsxs(t.Box,{display:"flex",justifyContent:"space-between",alignItems:"center",children:[ge.jsx(t.Box,{children:e}),n&&ge.jsx(o.Check,{})]})}),Zh=t.styled(t.Select)((({theme:e,sizing:t})=>({...{...Lh(e)},...t&&{...Dh(e,t)},...t&&{...Fh(e,t)},backgroundColor:e.custom.palette.surface.raised,border:`1px solid ${e.custom.palette.stroke.default}`,transition:e.custom.easing.input,"& .MuiOutlinedInput-notchedOutline":{border:e.custom.palette.stroke.default},"&:hover":{"& .MuiOutlinedInput-notchedOutline":{borderColor:e.custom.palette.stroke.default}},"&.Mui-focused":{backgroundColor:e.custom.palette.input.default,borderColor:e.custom.palette.stroke.focus,boxShadow:e.custom.boxShadow.input.focus},"&.Mui-disabled":{backgroundColor:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"& .MuiSvgIcon-root":{color:e.custom.palette.icon.disabled,transition:e.custom.easing.input}}}))),Yh=({selections:e,autoComplete:n=!1,disabled:i=!1,disablePortal:r=!1,inputRef:s,internalChange:a,multi:l=!0,onChange:c,placeholder:u="",selectOptionProps:d,sizing:p="lg",sx:h,value:m=[],renderListItem:f,...g})=>{const x=t.useTheme(),v=Wo();return n?ge.jsx(Gh,{selections:e,placeholder:u,disabled:i,sizing:p,onChange:(e,t)=>{c&&c(t||""),a&&a()},value:Array.isArray(m)?m??[]:m??"",internalChange:a,renderListItem:f,multiple:l}):ge.jsxs(Zh,{sizing:p,inputRef:s,MenuProps:{disablePortal:r,sx:$h,anchorOrigin:{vertical:45,horizontal:"center"}},displayEmpty:!0,IconComponent:o.KeyboardArrowDown,renderValue:t=>u&&!t?ge.jsx(dn,{component:"p",variation:"sm"===v||"md"===v?"sm":"lg",sx:{color:x.custom.palette.text.placeholder},children:u}):ge.jsx(dn,{component:"p",variation:"sm"===v||"md"===v?"sm":"lg",children:e?.find((({value:e})=>e===t))?.label}),onChange:(e,t)=>{c&&c(e,t),a&&a()},sx:h,value:m,...g,children:[""!==u.trim()&&ge.jsx(Kh,{disabled:!0,value:"","aria-label":"placeholder",children:u},"placeholder"),e?.map((({value:e,label:t})=>ge.jsx(Kh,{value:e,...d,children:f?f(e,t):t},e)))]})},Xh=t.styled(t.Box)((({theme:e,disabled:t,fullWidth:n})=>({width:n?"100%":"auto",minWidth:240,backgroundColor:t?e.custom.palette.input.disabled:e.custom.palette.surface.raised,border:`1px solid ${t?e.custom.palette.stroke.disabled:e.custom.palette.stroke.default}`,borderRadius:e.spacing(e.custom.radius.lg),padding:e.spacing(e.custom.padding.md),position:"relative",zIndex:0,"&:after":{content:'""',backgroundColor:e.custom.palette.interaction.none,borderRadius:e.spacing(e.custom.radius.lg),position:"absolute",inset:0},"&:hover":{"&:after":{backgroundColor:e.custom.palette.interaction.hover}},"&:active":{"&:after":{backgroundColor:e.custom.palette.interaction.press}},"& svg":{fill:e.custom.palette.icon.primary},...t&&{background:e.custom.palette.input.disabled,borderColor:e.custom.palette.stroke.disabled,"&:after":{backgroundColor:e.custom.palette.interaction.none},"& .MuiBox-root > .MuiSvgIcon-root":{fill:"none"}}}))),Jh=t.styled(bh)((({theme:e})=>({fontSize:On.button.md,color:e.custom.palette.text.primary,lineHeight:"120%",letterSpacing:"0.16px"}))),Qh=({label:e="Placeholder",disabled:n,onChange:i,options:r,fullWidth:s})=>{const a=t.useTheme(),l=r.map((e=>e.label)).indexOf(e);return ge.jsx(Xh,{disabled:n,fullWidth:s,children:ge.jsxs(t.Stack,{display:"flex",justifyContent:"space-between",flexDirection:"row",alignItems:"center",sx:{position:"relative",zIndex:1},children:[ge.jsxs(t.Box,{display:"flex",alignItems:"center",sx:{"& svg":{fill:a.custom.palette.icon.secondary}},children:[ge.jsx(o.DragHandle,{sx:{width:Qt.lg,height:Qt.lg,mr:a.custom.padding.sm}}),ge.jsx(Jh,{align:"left",disabled:n,children:e})]}),ge.jsx(Yh,{name:"rank",sizing:"xs",selections:r.map(((e,t)=>({label:`${t+1}`,value:`${t}`}))),disabled:n,value:`${l}`,onChange:function(e){const t=l,n=Number(e.target.value),o=r;let s=1;const a=o.splice(t,s)[0];s=0,o.splice(n,s,a),i(o)},MenuProps:{anchorOrigin:{vertical:J[400],horizontal:"center"}}})]})})},em=e.createContext({attributes:{},listeners:void 0,ref(){}}),tm=e=>p.defaultAnimateLayoutChanges({...e,wasDragging:!0});function nm({children:n,top:o,bottom:i,id:r}){const{attributes:s,isDragging:a,listeners:l,setNodeRef:c,setActivatorNodeRef:u,transform:d,transition:m}=p.useSortable({id:r,animateLayoutChanges:tm}),f=e.useMemo((()=>({attributes:s,listeners:l,ref:u})),[s,l,u]),g={opacity:a?.4:void 0,transform:h.CSS.Translate.toString(d),transition:m};return ge.jsx(em.Provider,{value:f,children:ge.jsxs(t.Stack,{className:"SortableItem",...s,sx:{position:"relative",...g,width:"100%"},ref:c,children:[o&&o,ge.jsx(t.Box,{...l,sx:{display:"flex",cursor:"grab"},children:n}),i&&i]})})}const om={sideEffects:d.defaultDropAnimationSideEffects({styles:{active:{opacity:"0.4"}}})};function im({children:e}){return m.createPortal(ge.jsx(d.DragOverlay,{zIndex:999999,dropAnimation:om,children:e}),document.body)}const rm=({nativeEvent:e})=>{let t=e.target;for(;t;){if(t.dataset.noDnd)return!1;t=t.parentElement}return!0};class sm extends d.MouseSensor{static activators=[{eventName:"onMouseDown",handler:rm}]}class am extends d.TouchSensor{static activators=[{eventName:"onTouchStart",handler:rm}]}function lm({items:n,onChange:o,renderItem:i,disabled:r,direction:s}){if(!n)return;const[a,l]=e.useState(null),c=e.useMemo((()=>n.find((e=>e?.id===a?.id))),[a,n]),u=t.useTheme(),h=t.useMediaQuery(u.breakpoints.down("md")),m=d.useSensors(d.useSensor(sm,{activationConstraint:{distance:5}}),d.useSensor(am,{activationConstraint:{delay:h?300:0,tolerance:8}}),d.useSensor(d.KeyboardSensor,{coordinateGetter:p.sortableKeyboardCoordinates}));return ge.jsxs(d.DndContext,{measuring:{droppable:{strategy:d.MeasuringStrategy.Always}},sensors:m,onDragStart:({active:e})=>{l(e)},onDragEnd:({active:e,over:t})=>{if(t&&e.id!==t?.id){const i=n.findIndex((({id:t})=>t===e.id)),r=n.findIndex((({id:e})=>e===t.id));o(p.arrayMove(n,i,r))}l(null)},onDragCancel:()=>{l(null)},children:[ge.jsx(p.SortableContext,{items:n,disabled:r,strategy:"horizontal"===s?p.horizontalListSortingStrategy:p.verticalListSortingStrategy,children:ge.jsx(t.Stack,{sx:{..."horizontal"===s&&{flexDirection:"row"},display:"flex",m:0,gap:1,padding:0,alignContent:"flex-start"},children:n.map((t=>ge.jsx(e.Fragment,{children:i(t)},t.id)))})}),ge.jsx(im,{children:c?i(c,!0,!!a):null})]})}lm.Item=nm,lm.DragHandle=function(){const{attributes:n,listeners:o,ref:i}=e.useContext(em);return ge.jsx(t.Box,{...n,...o,ref:i,children:ge.jsx("svg",{viewBox:"0 0 20 20",width:"12",children:ge.jsx("path",{d:"M7 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 2zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 14zm6-8a2 2 0 1 0-.001-4.001A2 2 0 0 0 13 6zm0 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 14z"})})})};const cm=({labelTop:n,labelBottom:o,disabled:i,fullWidth:r=!1,options:s,onChange:a,value:l,internalChange:c})=>{const u=t.useTheme(),[d,p]=e.useState(l||s);function h(e){p(e),a(e.map((({id:e})=>e))),c&&c()}return ge.jsxs(t.Stack,{gap:u.custom.margin.sm,textAlign:"center",sx:{width:r?"100%":"auto"},children:[n&&ge.jsx(bh,{disabled:i,sx:{color:u.custom.palette.text.secondary},children:n}),ge.jsx(lm,{onChange:function(e){p(e),a(e.map((({id:e})=>e))),c&&c()},items:d,direction:"vertical",renderItem:({...e})=>ge.jsx(nm,{id:e.id,children:ge.jsx(Qh,{onChange:h,...e,options:d,disabled:i,selections:e.selections,fullWidth:r})})}),o&&ge.jsx(bh,{disabled:i,sx:{color:u.custom.palette.text.secondary},children:o})]})},um=t.styled(x.RichTextEditor)((({theme:e})=>({"&.MuiTiptap-FieldContainer-root":{backgroundColor:e.custom.palette.input.default,"&:hover":{".MuiTiptap-FieldContainer-notchedOutline":{borderSize:1,backgroundColor:e.custom.palette.interaction.hover,borderColor:e.custom.palette.stroke.default}}},"&.MuiTiptap-FieldContainer-focused":{".MuiTiptap-FieldContainer-notchedOutline":{transition:e.custom.easing.input,border:`1px solid ${e.custom.palette.stroke.focus}!important`,boxShadow:e.custom.boxShadow.input.focus}},".MuiTiptap-RichTextField-menuBar":{padding:0,borderRadius:e.spacing(e.custom.radius.md),background:e.custom.palette.surface.default,margin:e.spacing(e.custom.margin.sm),border:`1px solid ${e.custom.palette.stroke.default}`,marginBottom:0,".MuiTiptap-RichTextField-content":{padding:e.spacing(e.custom.padding.xs)}}}))),dm=({onChange:n,value:o,internalChange:i,minWidth:r=100,minHeight:s=100,maxHeight:a,placeholder:l})=>{const c=e.useRef(null),u=t.useTheme();return ge.jsx(um,{sx:{"& .ProseMirror":{overflowY:"auto",minHeight:s,minWidth:r,maxHeight:a}},ref:c,onUpdate:({editor:e})=>{n&&n(e.getHTML()),i&&i()},extensions:[g.StarterKit.configure({strike:!1,code:!1,heading:!1,listItem:!1,bulletList:!1,orderedList:!1,blockquote:!1,horizontalRule:!1,codeBlock:!1}),f.Placeholder.configure({placeholder:l}),v.Markdown],content:o,renderControls:()=>ge.jsxs(t.Stack,{gap:u.custom.margin.xs,direction:"row",children:[ge.jsx(x.MenuButtonBold,{}),ge.jsx(x.MenuButtonItalic,{})]})})},pm=e=>({"& .MuiSlider-thumb":{width:J[300],height:J[300],backgroundColor:e.custom.palette.text.primary,boxShadow:e.custom.boxShadow.input.handle,"&:after":{content:'""',position:"absolute",top:"50%",left:"50%",width:J[50],height:J[50],backgroundColor:e.custom.palette.icon.primaryInverted}}}),hm=e=>Array.isArray(e),mm=(e,t)=>({height:J[100],padding:`${J[100]}px 0`,"& .MuiSlider-rail":{width:`calc(100% + ${J[400]}px)`,left:`-${J[200]}px`,backgroundColor:e.custom.palette.icon.disabled,opacity:1},"& .MuiSlider-track":{position:"relative",border:"none",backgroundColor:e.custom.palette.purple[500],"&:before":{content:'""',position:"absolute",top:0,left:t&&hm(t)?`-${J[100]+1}px`:`-${J[200]+1}px`,width:`calc(100% + ${J[200]}px)`,height:"100%",borderRadius:"inherit",backgroundColor:"inherit"}},"& .MuiSlider-mark":{height:J[50],width:J[50],borderRadius:e.custom.radius.round,backgroundColor:e.custom.palette.text.primaryInverted,"&.MuiSlider-markActive":{backgroundColor:e.custom.palette.text.primaryInverted}}}),fm=e=>({"& .MuiSlider-valueLabel":{backgroundColor:e.custom.palette.purple[500],borderRadius:e.spacing(e.custom.radius.sm),padding:J[50],minWidth:J[400],"&.MuiSlider-valueLabelOpen":{top:"-9px"},"& .MuiSlider-valueLabelLabel":{padding:`0 ${e.spacing(e.custom.padding.xs)}`,fontSize:`${On.lg.body.sm}`,color:e.custom.palette.text.lockedWhite,fontWeight:500,lineHeight:"140%"}}}),gm=t.styled(t.Slider)((({theme:e,value:t,hideMarkLabels:n,hideMarks:o})=>({"&.MuiSlider-root":{width:`calc(100% - ${J[400]}px)`,marginLeft:J[400]/2,...{...mm(e,t)},...{...pm(e)},...{...fm(e)},"&.Mui-disabled":{"& .MuiSlider-rail, & .MuiSlider-track":{backgroundColor:e.custom.palette.icon.secondary},"& .MuiSlider-rail":{backgroundColor:e.custom.palette.icon.disabled},"& .MuiSlider-thumb":{backgroundColor:e.custom.palette.icon.disabled,"& .MuiSlider-valueLabel":{backgroundColor:e.custom.palette.icon.disabled}}},...n&&{".MuiSlider-markLabel":{visibility:"hidden"},".MuiSlider-markLabel:nth-of-type(4), .MuiSlider-markLabel:nth-last-of-type(2)":{visibility:"visible"}},".MuiSlider-mark":{color:e.custom.palette.text.secondary,...o&&{visibility:"hidden"},"&.MuiSlider-markLabelActive":{color:e.custom.palette.text.secondary}}}}))),xm=(e,t)=>{if(!e)return!1;const n=e.querySelectorAll(t);if(n.length<2)return!1;const o=Array.from(n).map((e=>e.getBoundingClientRect()));let i=!1;for(let e=0;e<o.length-1;e++)if(o[e].right+5>o[e+1].left){i=!0;break}return i},vm=({labelLeft:n,labelMiddle:o,labelRight:i,labelRightProps:r,labelLeftProps:s,disabled:a,onChange:l,internalChange:c,max:u=5,min:d=1,marks:p,marksStep:h=1,step:m=1,value:f=d,...g})=>{const{sanitisedMin:x,sanitisedMax:v}=((e,t)=>e>=t?{sanitisedMin:1,sanitisedMax:10}:{sanitisedMin:e,sanitisedMax:t})(d,u),y=e.useRef(null),b=p||((e,t,n)=>{const o=[];for(let i=e;i<=t;i++)i%n==0&&o.push({value:i,label:i.toString()});return o})(x,v,h),[w,j]=e.useState(!1),[C,S]=e.useState(!1),k=()=>{j(xm(y.current,".MuiSlider-markLabel")),S(xm(y.current,".MuiSlider-mark"))};return e.useEffect((()=>{k()}),[b?.length]),e.useEffect((()=>{const e=new ResizeObserver(k);return y.current&&e.observe(y.current),()=>{e.disconnect()}}),[]),ge.jsxs(t.Box,{sx:{minWidth:300},children:[ge.jsx(t.Box,{height:24,children:ge.jsx(gm,{ref:y,valueLabelDisplay:a?"on":"auto",disabled:a,marks:b,step:m,hideMarkLabels:w,hideMarks:C,max:v,min:x,onChangeCommitted:()=>{c&&c()},onChange:(e,t,n)=>{l&&l(e,t,n)},value:f,...g})}),ge.jsx(t.Box,{sx:{display:"flex",justifyContent:"space-between",pt:te.lg,gap:1},children:(n||o||i)&&ge.jsxs(ge.Fragment,{children:[ge.jsx(t.Box,{sx:{flex:1},children:ge.jsx(lh,{disabled:a,showicon:!1,...s,children:n})}),o&&ge.jsx(t.Box,{sx:{flex:1,textAlign:"center"},children:ge.jsx(lh,{showicon:!1,disabled:a,children:o})}),ge.jsx(t.Box,{sx:{flex:1,textAlign:"right"},children:ge.jsx(lh,{...r,showicon:!1,disabled:a,children:i})})]})})]})},ym=t.styled(t.Rating)((({theme:e})=>({"&.MuiRating-root":{"& .MuiRating-iconEmpty":{color:e.custom.palette.icon.secondary},"& .MuiRating-iconFilled":{color:e.custom.palette.yellow[600]},".MuiRating-iconHover":{fontSize:"inherit",transform:"none"},"&.Mui-disabled":{opacity:1,color:e.custom.palette.icon.disabled,"& .MuiRating-iconEmpty":{color:e.custom.palette.icon.disabled},"& .MuiRating-iconFilled":{color:e.custom.palette.icon.disabled}}}}))),bm=({internalChange:e,onChange:n,...o})=>ge.jsx(ym,{...o,onChange:(t,o)=>{n&&n(t,o),e&&e()},icon:ge.jsx(t.SvgIcon,{sx:{width:48,height:48},viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{d:"M24.114 35.395L32.414 40.415C33.934 41.335 35.794 39.975 35.394 38.255L33.194 28.815L40.534 22.455C41.874 21.295 41.154 19.095 39.394 18.955L29.734 18.135L25.954 9.21499C25.274 7.59499 22.954 7.59499 22.274 9.21499L18.494 18.115L8.83396 18.935C7.07396 19.075 6.35396 21.275 7.69396 22.435L15.034 28.795L12.834 38.235C12.434 39.955 14.294 41.315 15.814 40.395L24.114 35.395Z"})}),emptyIcon:ge.jsx(t.SvgIcon,{sx:{width:48,height:48},viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M39.1047 20.58L30.8559 27.7274L33.3274 38.3549L23.9992 32.713L14.6668 38.335L17.1388 27.7279L8.89132 20.5816L19.748 19.66L23.9966 9.63416L28.2463 19.6377L39.1047 20.58ZM12.7171 37.8892L14.9171 28.4492L7.57709 22.0892C6.23709 20.9292 6.95709 18.7292 8.71709 18.5892L18.3771 17.7692L22.1571 8.84916C22.8371 7.22916 25.1571 7.22916 25.8371 8.84916L29.6171 17.7492L39.2971 18.5892C41.0571 18.7292 41.7571 20.9292 40.4171 22.0892L33.0771 28.4492L35.2771 37.9092C35.6771 39.6292 33.8171 40.9892 32.2971 40.0692L23.9971 35.0492L15.6971 40.0492C14.1771 40.9692 12.3171 39.6092 12.7171 37.8892Z"})})}),wm=t.styled((e=>ge.jsx(t.Switch,{focusVisibleClassName:".Mui-focusVisible",disableRipple:!0,...e})))((({theme:e,sizing:t})=>({width:"lg"===t?54:36,height:"lg"===t?30:20,padding:0,"& .MuiSwitch-switchBase":{padding:0,margin:"lg"===t?3:2,transitionDuration:"300ms","&.Mui-checked":{transform:`translateX(${"lg"===t?24:16}px)`,color:"#fff","& + .MuiSwitch-track":{backgroundColor:e.custom.palette.green[500],opacity:1,border:0},"&.Mui-disabled + .MuiSwitch-track":{opacity:.5}},"&.Mui-focusVisible .MuiSwitch-thumb":{color:"#33cf4d",border:"6px solid #fff"},"&.Mui-disabled .MuiSwitch-thumb":{color:e.custom.palette.neutral[100]},"&.Mui-disabled + .MuiSwitch-track":{opacity:"light"===e.palette.mode?.7:.3}},"& .MuiSwitch-thumb":{width:"lg"===t?24:16,height:"lg"===t?24:16,boxSizing:"border-box",boxShadow:"none",backdropFilter:"blur(0)",filter:"drop-shadow(0 0 0 rgba(255, 255, 255, 0.52))",outline:("lg"===t?2:1)+"px solid rgba(255, 255, 255, 0.12)"},"& .MuiSwitch-track":{borderRadius:("lg"===t?30:20)/2,backgroundColor:e.custom.palette.neutral[100],opacity:1,transition:e.transitions.create(["background-color"],{duration:500})}}))),jm=({sizing:e="sm",sx:t,inputRef:o,value:i,label:r,labelPlacement:s="start",fullWidth:a,onChange:l,internalChange:c,...u})=>ge.jsx(Jp,{inputRef:o,checked:i,label:r,labelPlacement:s,control:ge.jsx(wm,{sizing:e}),onChange:(e,t)=>{l&&l(e,t),c&&c()},sx:n.mergeSx(a?{"& .MuiFormControlLabel-label":{width:"100%"}}:{},t),...u}),Cm=t.styled(nh)((({theme:e})=>({"& .MuiInputBase-root":{paddingTop:0,paddingBottom:0,minHeight:J[500],alignItems:"baseline","& .MuiInputBase-input":{},"& .MuiInputAdornment-root.MuiInputAdornment-positionStart":{alignSelf:"self-end",height:Qt.xl,marginTop:e.spacing(1),marginBottom:e.spacing(1),"&:first-of-type":{alignSelf:"self-start"}}}}))),Sm=({startAdornment:e,endAdornment:n,onChange:o,internalChange:i,inputRef:r,...s})=>ge.jsx(Cm,{multiline:!0,inputRef:r,InputProps:{startAdornment:e?ge.jsx(t.InputAdornment,{position:"start",children:e}):null,endAdornment:n?ge.jsx(t.InputAdornment,{position:"start",children:n}):null},...s,onChange:e=>{o&&o(e),i&&i()}}),km=(e,t)=>{switch(e){case 1:return t.custom.palette.red[500];case 2:return t.custom.palette.yellow[500];case 3:case 4:return t.custom.palette.green[500];default:return t.custom.palette.icon.disabled}},Mm=(e,t)=>{switch(e){case 1:return t.custom.palette.text.negative;case 2:return t.custom.palette.yellow[800];case 3:return t.custom.palette.green[800];case 4:return t.custom.palette.text.positive;default:return t.custom.palette.icon.disabled}},Tm=t.styled(t.LinearProgress)((({theme:e,score:n})=>({boxShadow:"unset",background:e.custom.palette.neutral[100],borderRadius:e.spacing(e.custom.radius.sm),[`.${t.linearProgressClasses.bar}`]:{borderRadius:e.spacing(e.custom.radius.sm),backgroundColor:km(n,e)}}))),Pm={translations:z.translations,graphs:E.adjacencyGraphs,dictionary:{...E.dictionary,...z.dictionary}};y.zxcvbnOptions.setOptions(Pm);const Bm=({label:n="Strength",width:o=60,value:i,onChange:r})=>{const[s,a]=e.useState(0),l=t.useTheme();return e.useEffect((()=>{a(y.zxcvbn(i).score)}),[i]),e.useEffect((()=>{r(s)}),[s]),ge.jsxs(t.Stack,{direction:"row",gap:1,sx:{alignItems:"center"},children:[ge.jsx(dn,{variation:"sm",component:"p",children:n}),ge.jsx(Tm,{variant:"determinate",value:0===s?6.6:25*s,score:s,sx:{width:o}}),ge.jsx(dn,{variation:"sm",component:"p",sx:{color:Mm(s,l)},children:["","Very weak","Weak","Strong","Excellent"][s]})]})},Am=({helperText:e,inputName:t,errors:n,...o})=>{const i=Boolean(n&&n[t]);return i?ge.jsx(j.ErrorMessage,{errors:n,name:t,render:({message:e})=>ge.jsx(lh,{showicon:!!e,state:"negative",children:e})}):e&&!i?ge.jsx(lh,{state:"default",...o,children:e}):null},Em={textfield:oh,numberfield:Ah,textarea:Sm,select:Yh,checkbox:th,checkboxGroup:ih,switch:jm,slider:vm,starRating:bm,differential:gh,likert:Ph,radioGroup:Eh,ranking:cm,richTextfield:dm,customfield:rh},zm=({name:o,fieldType:i,label:r,control:s,errors:a,labelProps:u,helperText:d,helpTextProps:p,validation:h,content:m,styleOverrides:f,defaultValue:g,onChange:x,watch:v,trigger:y,strengthIndicator:b,...w})=>{const{custom:j}=t.useTheme(),C=void 0!==a&&Object.keys(a).length>0,[S,k]=e.useState(0);return b&&e.useEffect((()=>{S>0&&y(o)}),[S]),h?.match?.field&&e.useEffect((()=>{h?.match?.field&&y(h?.match?.field)}),[v(o)]),ge.jsxs(t.Stack,{sx:n.mergeSx(f?.sxInputStack,w?.hidden&&{display:"none!important"}),gap:j.margin.sm,children:["switch"!==i?r&&ge.jsx(bh,{...u,children:r}):null,"html"===i&&m?ge.jsx(yh,{children:m}):ge.jsxs(ge.Fragment,{children:[ge.jsx(l.Controller,{name:o,control:s,render:e=>function({field:{ref:e,...t}}){const n=Em[i];return ge.jsx(n,{...w,...t,inputRef:e,..."switch"===i?{label:r}:{}})}(e),rules:{...h,validate:e=>{if(h&&"phone"in h)return c.isValidPhoneNumber(`+${v("extension")}${e}`)||h.phone.message;if(h&&"score"in h)return S<=h.score.value?h.score.message:void 0;if(h&&"white_space"in h)return!e.match(/^\s*$/g)||h.white_space.message;if(h&&"match"in h&&h?.match?.field)switch(h?.match?.comparison){case"not_eq":return e!=v(h.match.field)||h.match.message;case"gt":return e>v(h.match.field)||h.match.message;case"lt":return e<v(h.match.field)||h.match.message;default:return e===v(h.match.field)||h.match.message}}}}),b&&"password"===w?.type&&ge.jsx(Bm,{value:v(o),onChange:k})]}),ge.jsxs(ge.Fragment,{children:[Boolean(C)?ge.jsx(Am,{helperText:void 0,inputName:o,errors:a,showicon:!0}):null,Boolean(d)?ge.jsx(Am,{helperText:d,inputName:o,errors:void 0,...p}):null]})]})},Im=e=>e.reduce(((e,t)=>({...e,[t?.name]:Rm(t,t?.defaultValue)})),{}),Rm=(e,t)=>{switch(e.fieldType){case"select":return Array.isArray(t),t;case"starRating":case"numberfield":return t||0;case"slider":{const{min:n}=e;return Array.isArray(t)?t:t||n}case"likert":case"radioGroup":case"customfield":default:return t||"";case"checkboxGroup":return t||[];case"checkbox":case"switch":return t||!1;case"ranking":{const{options:n}=e;return t?t.map((e=>n.find((({id:t})=>t===e)))):n}}},Vm=e.forwardRef((({submitButton:n,secondaryButton:o,onFormSubmit:i,onFormChange:r,formConfig:s},a)=>{const{custom:c}=t.useTheme(),{fields:u,reValidateMode:d,styleOverrides:p,autoComplete:h,formId:m,mode:f}=s,g=vh(u),{reset:x,getValues:v,trigger:y,setValue:b,control:w,formState:{isValid:j,errors:C},setFocus:S,handleSubmit:k,watch:M}=l.useForm({mode:f||"onChange",reValidateMode:d,defaultValues:e.useMemo((()=>Im(u)),[]),shouldUnregister:!0});e.useEffect((()=>{if(void 0!==g){const e=g.filter((({fieldType:e})=>"html"!==e)).map((({name:e})=>e));u.filter((({name:t,fieldType:n})=>!e.includes(t)&&"html"!==n)).forEach((e=>{b(e.name,Rm(e,e.defaultValue))}))}}),[u]),e.useEffect((()=>{x(Im(u))}),[m]),e.useImperativeHandle(a,(()=>({set(e,t){b(e,t)},resetForm(){x()},focus(e){S(e)},submit(){i&&k(i)()},values:()=>v(),valid:()=>j,errors:()=>C,async triggerFormValidation(){await y()}})));const T=()=>{r&&r(v())};return ge.jsxs(t.Box,{component:"form",autoComplete:h,noValidate:!0,sx:p?.sxForm,...i&&{onSubmit:k(i)},children:[ge.jsx(t.Stack,{gap:c.margin.md,sx:p?.sxStack,children:u.map((({name:t,...n})=>e.createElement(zm,{...r&&{internalChange:T},name:t,key:t,errors:C,control:w,watch:M,trigger:y,...n})))}),(o||n)&&ge.jsxs(t.Stack,{direction:"row",sx:p?.sxButtons||{mt:c.margin.lg,gap:c.margin.sm,justifyContent:"flex-end"},children:[o&&o,n&&n]})]})})),Fm=t.styled(t.Box)((({theme:e})=>({alignItems:"center",display:"flex",flexDirection:"column",height:"100%",left:0,pointerEvents:"none",position:"fixed",top:0,width:"100%",zIndex:e.zIndex.tooltip}))),Lm=t.styled(t.Container)((({theme:e})=>({background:e.custom.palette.red[300],display:"flex",flex:1,opacity:.2,position:"relative"}))),Dm=t.styled(t.Box)((({theme:e})=>({background:e.custom.palette.purple[300],display:"flex",flex:1}))),Om=t.styled(t.Box)((({theme:e})=>({background:e.custom.palette.green[300],height:"100%"}))),$m=t.styled(t.Box)((({theme:e})=>({backgroundColor:e.custom.palette.surface.default,borderRadius:e.spacing(e.custom.radius.md),bottom:16,boxShadow:e.custom.elevation.overlay,display:"block",left:16,padding:e.spacing(1,2),position:"fixed"}))),Hm=e=>({"&:first-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderBottomLeftRadius:0,borderBottomRightRadius:0},"&:last-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopRightRadius:0,borderTopLeftRadius:0}}),Wm=e=>({"&:first-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopRightRadius:0,borderBottomRightRadius:0},"&:last-of-type":{borderRadius:`calc(${e.spacing(e.custom.radius.md)} - 1px)`,borderTopLeftRadius:0,borderBottomLeftRadius:0}}),Nm=t.styled(t.ButtonGroup)((({theme:e,variation:t,orientation:n="horizontal",iconColor:o,sizing:i="lg",groupRaised:r=!1})=>({"&.MuiButtonGroup-root":{backgroundColor:e.custom.palette.input.default,border:`1px solid ${e.custom.palette.stroke.default}`,...r&&{boxShadow:e.custom.elevation.raised,border:"none"},"& > button":{borderRadius:0,..."default"===t&&{...bn(e)},..."toggle"===t&&{...wn(e)},..."vertical"===n&&{...Hm(e)},..."horizontal"===n&&{...Wm(e)},...i&&{...Mn(i)}},"& .MuiSvgIcon-root":{...i&&{...Pn(i)},fill:o||"inherit"}}}))),_m=t.styled(t.Box)({"& .lazy-load-image-background.blur":{filter:"blur(15px)"},"& .lazy-load-image-background.blur.lazy-load-image-loaded":{filter:"blur(0)",transition:"filter .3s"},"& .lazy-load-image-background.blur > img":{opacity:"0"},"& .lazy-load-image-background.blur.lazy-load-image-loaded > img":{opacity:"1",transition:"opacity .3s"}}),Um=({children:n,src:o,alt:i,width:r,height:s,...a})=>{const[l,c]=e.useState(!1);return ge.jsxs(ge.Fragment,{children:[ge.jsx(t.Fade,{in:!l,unmountOnExit:!0,children:ge.jsx(t.Box,{sx:{width:r,height:s,position:"absolute",inset:0},children:ge.jsx(t.Skeleton,{variant:"rectangular",width:r,height:"100%"})})}),ge.jsx(_m,{children:ge.jsx(C.LazyLoadImage,{onLoad:()=>c(!0),alt:i,height:s,src:o,width:r,threshold:500,effect:"blur",wrapperProps:{style:{transitionDelay:"200ms"}},...a})})]})},Gm=t.styled(Tp)((({theme:e})=>({background:`linear-gradient(-18deg, ${e.custom.palette.purple[600]} 0%, ${e.custom.palette.blue[400]} 100%)`,color:e.custom.palette.white,padding:e.spacing(1),minWidth:0}))),qm={variation:"lg",component:"p",sx:{margin:0,"& > *":{display:"inline"}}},Km=t.styled("div")((()=>({whiteSpace:"pre"}))),Zm=(e,t)=>"light"===t?{fontWeight:400}:{fontWeight:500,textTransform:"uppercase"},Ym=(e,t,n)=>{switch(t){case"peach":return{background:e.custom.palette.peach[100],color:"heavy"===n?e.custom.palette.peach[1e3]:e.custom.palette.peach[800]};case"peachDark":return{background:e.custom.palette.peach[800],color:e.custom.palette.peach[0]};case"purple":return{background:e.custom.palette.purple[100],color:"heavy"===n?e.custom.palette.purple[1e3]:e.custom.palette.purple[800]};default:return{background:e.custom.palette.neutral[100],color:"heavy"===n?e.custom.palette.neutral[1e3]:e.custom.palette.neutral[800]}}},Xm=t.styled(t.Chip)((({theme:e,variation:t,weight:n})=>({borderRadius:e.spacing(e.custom.radius.md),height:28,...Ym(e,t,n),"& .MuiChip-label":{fontSize:`${On.sm.body.sm}`,padding:`0 ${e.spacing(e.custom.padding.sm)}`,...Zm(0,n)},"& .MuiChip-icon":{width:"0.8em",height:"0.8em",marginRight:-4,...Ym(e,t,n),...Zm(0,n)}})));var Jm=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(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]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)})),this.tags=[],this.ctr=0},e}();var Qm="undefined"!=typeof document,ef=function(e,t,n){for(var o=0,i=0;o=i,i=k.peek(),38===o&&12===i&&(t[n]=1),!k.token(i);)k.next();return k.slice(e,k.position)},tf=function(e,t){return k.dealloc(function(e,t){var n=-1,o=44;do{switch(k.token(o)){case 0:38===o&&12===k.peek()&&(t[n]=1),e[n]+=ef(k.position-1,t,n);break;case 2:e[n]+=k.delimit(o);break;case 4:if(44===o){e[++n]=58===k.peek()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=k.from(o)}}while(o=k.next());return e}(k.alloc(e),t))},nf=new WeakMap,of=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,o=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||nf.get(n))&&!o){nf.set(e,!0);for(var i=[],r=tf(t,i),s=n.props,a=0,l=0;a<r.length;a++)for(var c=0;c<s.length;c++,l++)e.props[l]=i[a]?r[a].replace(/&\f/g,s[c]):s[c]+" "+r[a]}}},rf=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function sf(e,t){switch(k.hash(e,t)){case 5103:return k.WEBKIT+"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 k.WEBKIT+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return k.WEBKIT+e+k.MOZ+e+k.MS+e+e;case 6828:case 4268:return k.WEBKIT+e+k.MS+e+e;case 6165:return k.WEBKIT+e+k.MS+"flex-"+e+e;case 5187:return k.WEBKIT+e+k.replace(e,/(\w+).+(:[^]+)/,k.WEBKIT+"box-$1$2"+k.MS+"flex-$1$2")+e;case 5443:return k.WEBKIT+e+k.MS+"flex-item-"+k.replace(e,/flex-|-self/,"")+e;case 4675:return k.WEBKIT+e+k.MS+"flex-line-pack"+k.replace(e,/align-content|flex-|-self/,"")+e;case 5548:return k.WEBKIT+e+k.MS+k.replace(e,"shrink","negative")+e;case 5292:return k.WEBKIT+e+k.MS+k.replace(e,"basis","preferred-size")+e;case 6060:return k.WEBKIT+"box-"+k.replace(e,"-grow","")+k.WEBKIT+e+k.MS+k.replace(e,"grow","positive")+e;case 4554:return k.WEBKIT+k.replace(e,/([^-])(transform)/g,"$1"+k.WEBKIT+"$2")+e;case 6187:return k.replace(k.replace(k.replace(e,/(zoom-|grab)/,k.WEBKIT+"$1"),/(image-set)/,k.WEBKIT+"$1"),e,"")+e;case 5495:case 3959:return k.replace(e,/(image-set\([^]*)/,k.WEBKIT+"$1$`$1");case 4968:return k.replace(k.replace(e,/(.+:)(flex-)?(.*)/,k.WEBKIT+"box-pack:$3"+k.MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+k.WEBKIT+e+e;case 4095:case 3583:case 4068:case 2532:return k.replace(e,/(.+)-inline(.+)/,k.WEBKIT+"$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(k.strlen(e)-1-t>6)switch(k.charat(e,t+1)){case 109:if(45!==k.charat(e,t+4))break;case 102:return k.replace(e,/(.+:)(.+)-([^]+)/,"$1"+k.WEBKIT+"$2-$3$1"+k.MOZ+(108==k.charat(e,t+3)?"$3":"$2-$3"))+e;case 115:return~k.indexof(e,"stretch")?sf(k.replace(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==k.charat(e,t+1))break;case 6444:switch(k.charat(e,k.strlen(e)-3-(~k.indexof(e,"!important")&&10))){case 107:return k.replace(e,":",":"+k.WEBKIT)+e;case 101:return k.replace(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+k.WEBKIT+(45===k.charat(e,14)?"inline-":"")+"box$3$1"+k.WEBKIT+"$2$3$1"+k.MS+"$2box$3")+e}break;case 5936:switch(k.charat(e,t+11)){case 114:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return k.WEBKIT+e+k.MS+k.replace(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return k.WEBKIT+e+k.MS+e+e}return e}var af,lf,cf=Qm?void 0:(af=function(){return e=function(){return{}},t=Object.create(null),function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]};var e,t},lf=new WeakMap,function(e){if(lf.has(e))return lf.get(e);var t=af(e);return lf.set(e,t),t}),uf=[function(e,t,n,o){if(e.length>-1&&!e.return)switch(e.type){case k.DECLARATION:e.return=sf(e.value,e.length);break;case k.KEYFRAMES:return k.serialize([k.copy(e,{value:k.replace(e.value,"@","@"+k.WEBKIT)})],o);case k.RULESET:if(e.length)return k.combine(e.props,(function(t){switch(k.match(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return k.serialize([k.copy(e,{props:[k.replace(t,/:(read-\w+)/,":"+k.MOZ+"$1")]})],o);case"::placeholder":return k.serialize([k.copy(e,{props:[k.replace(t,/:(plac\w+)/,":"+k.WEBKIT+"input-$1")]}),k.copy(e,{props:[k.replace(t,/:(plac\w+)/,":"+k.MOZ+"$1")]}),k.copy(e,{props:[k.replace(t,/:(plac\w+)/,k.MS+"input-$1")]})],o)}return""}))}}],df=function(e){var t=e.key;if(Qm&&"css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var o,i,r=e.stylisPlugins||uf,s={},a=[];Qm&&(o=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)s[t[n]]=!0;a.push(e)})));var l=[of,rf];if(cf){var c=[k.stringify],u=k.middleware(l.concat(r,c)),d=cf(r)(t),p=function(e,t){var n=t.name;return void 0===d[n]&&(d[n]=function(e){return k.serialize(k.compile(e),u)}(e?e+"{"+t.styles+"}":t.styles)),d[n]};i=function(e,t,n,o){var i=t.name,r=p(e,t);return void 0===g.compat?(o&&(g.inserted[i]=!0),r):o?void(g.inserted[i]=r):r}}else{var h,m=[k.stringify,k.rulesheet((function(e){h.insert(e)}))],f=k.middleware(l.concat(r,m));i=function(e,t,n,o){h=n,function(e){k.serialize(k.compile(e),f)}(e?e+"{"+t.styles+"}":t.styles),o&&(g.inserted[t.name]=!0)}}var g={key:t,sheet:new Jm({key:t,container:o,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:s,registered:{},insert:i};return g.sheet.hydrate(a),g};const pf=t.styled("iframe")((()=>({border:"none",height:"100%",width:"100%"}))),hf=({status:e})=>{const n=t.useTheme();switch(e){case"neutral":return null;case"success":return ge.jsx(mf,{backgroundColor:n.custom.palette.green[500],name:"check-circle"});case"warning":return ge.jsx(mf,{backgroundColor:n.custom.palette.yellow[500],name:"error"});case"danger":return ge.jsx(mf,{backgroundColor:n.custom.palette.red[500],name:"warning"});case"discover":return ge.jsx(mf,{backgroundColor:n.custom.palette.purple[500],name:"lightbulb"})}},mf=({backgroundColor:e,name:n})=>{const o=t.useTheme();return ge.jsx(t.Box,{sx:{display:"flex",alignItems:"flex-start",pt:.25},children:ge.jsx(t.Box,{sx:{backgroundColor:e,borderRadius:o.custom.radius.round,color:o.custom.palette.white,display:"flex",p:.5},children:ge.jsx(en,{name:n,size:20})})})},ff=t.styled(t.Box)((({theme:e,divider:t=!1})=>({width:"100%",transition:"all 0.3s ease",borderBottom:t?`1px solid ${e.custom.palette.stroke.default}`:"none","&:hover":{'*[data-id="image-container"]':{boxShadow:e.custom.elevation.raised}}}))),gf=t.styled(t.CardActionArea)((({theme:e,disableHoverStyle:t=!1})=>({...!0===t&&{"& .MuiCardActionArea-focusHighlight":{backgroundColor:e.palette.background.paper}}}))),xf=t.styled(t.Box)((({theme:e})=>({transition:"all 200ms ease",boxShadow:"none",overflow:"hidden",height:150,position:"relative",borderRadius:e.spacing(e.custom.radius.md)}))),vf=({thumbnail:e,title:t,description:n})=>ge.jsx(Um,{src:e,alt:`${t} | ${n}`,title:`${t} | ${n}`,style:{width:"100%",height:"auto",objectFit:"cover"}}),yf=t.styled(t.CardContent)((({theme:e})=>({paddingTop:e.spacing(e.custom.padding.xs),paddingBottom:e.spacing(e.custom.padding.xs),paddingLeft:0,paddingRight:0,display:"flex",flexDirection:"column",gap:e.spacing(e.custom.margin.xs),'& [data-id="title-container"]':{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"start",gap:e.spacing(e.custom.margin.xs),"& > p":{alignSelf:"center"}}}))),bf=t.styled(t.Skeleton)((({theme:e})=>({transform:"none",width:"100%",height:"100%"}))),wf=t.styled(t.Box)((({theme:e,viewType:t})=>({width:"grid"===t?"100%":108,height:"grid"===t?150:72,backgroundColor:e.custom.palette.purple[0],display:"flex",justifyContent:"center",alignItems:"center",borderRadius:e.spacing(e.custom.radius.md),"& svg":{height:"grid"===t?64:32,width:"grid"===t?64:32}}))),jf=({updatedDate:e,format:t=!1,noWrap:n})=>ge.jsxs(dn,{variation:"sm",component:"p",color:"text.secondary",noWrap:n,children:["Edited on ",t?T(e).format("DD MMM YYYY"):e]}),Cf=({title:e,description:n,loopCount:o,testCount:i,draftCount:r,updatedAt:s,moreActions:a,thumbnail:l,isDemo:c,loading:u,onClick:d})=>u?ge.jsx(ff,{children:ge.jsxs(gf,{disableHoverStyle:!0,children:[ge.jsx(xf,{"data-id":"image-container",children:ge.jsx(bf,{})}),ge.jsxs(yf,{children:[ge.jsx(t.Box,{"data-id":"title-container",height:32,children:ge.jsx(bf,{})}),ge.jsx(bf,{}),ge.jsx(bf,{width:"60%"})]})]})}):ge.jsx(ff,{children:ge.jsxs(gf,{disableHoverStyle:!0,onClick:d,children:[ge.jsxs(xf,{"data-id":"image-container",children:[c&&ge.jsx(_p,{body:"Demo",sx:{bottom:8,left:8}}),ge.jsx(vf,{thumbnail:l,title:e,description:n})]}),ge.jsxs(yf,{children:[ge.jsxs(t.Box,{"data-id":"title-container",children:[ge.jsx(Up,{title:e,maxLines:2}),ge.jsx(t.Box,{"data-id":"more-actions-container",onClick:e=>{e.stopPropagation()},children:a})]}),ge.jsx(Wp,{loops:o,tests:i,drafts:r}),ge.jsx(jf,{updatedDate:s,format:!0})]})]})}),Sf=({title:e,description:n,loopCount:o,testCount:i,draftCount:r,updatedAt:s,moreActions:a,thumbnail:l,isDemo:c,loading:u,onClick:d})=>{const p=t.useTheme();return u?ge.jsx(ff,{divider:!0,children:ge.jsxs(gf,{onClick:d,sx:{p:p.spacing(p.custom.padding.xs),display:"flex",gap:p.spacing(p.custom.margin.sm),alignItems:"center"},children:[ge.jsx(xf,{sx:{height:72,width:108},"data-id":"image-container",children:ge.jsx(bf,{})}),ge.jsx(yf,{sx:{overflow:"hidden",pl:p.spacing(p.custom.padding.sm),minWidth:67,flex:1,"&:last-child":{pb:0}},children:ge.jsxs(t.Stack,{gap:p.spacing(p.custom.margin.xs),children:[ge.jsx(bf,{width:"100%",height:20}),ge.jsxs(t.Stack,{direction:"row",gap:p.spacing(p.custom.margin.xs),justifyContent:"space-between",flexWrap:"wrap",children:[ge.jsx(bf,{width:"70%"}),ge.jsx(bf,{width:200})]})]})})]})}):ge.jsx(ff,{divider:!0,children:ge.jsxs(gf,{onClick:d,sx:{p:p.spacing(p.custom.padding.xs),display:"flex",gap:p.spacing(p.custom.margin.sm),alignItems:"center"},children:[ge.jsxs(xf,{sx:{height:72,width:108},"data-id":"image-container",children:[c&&ge.jsx(_p,{sx:{top:4,right:4},body:"Demo"}),ge.jsx(vf,{thumbnail:l,title:e,description:n})]}),ge.jsx(yf,{sx:{overflow:"hidden",pl:p.spacing(p.custom.padding.sm),minWidth:67,flex:1,"&:last-child":{pb:0}},children:ge.jsxs(t.Stack,{gap:p.spacing(p.custom.margin.xs),children:[ge.jsx(Up,{title:e,maxLines:1}),ge.jsxs(t.Stack,{direction:"row",gap:p.spacing(p.custom.margin.xs),justifyContent:"space-between",flexWrap:"wrap",children:[ge.jsx(Wp,{loops:o,tests:i,drafts:r}),ge.jsx(jf,{updatedDate:s,format:!0,noWrap:!0})]})]})}),a&&ge.jsx(t.Box,{onClick:e=>e.stopPropagation(),children:a})]})})},kf=t.styled(t.Box)((({theme:e})=>({alignItems:"center",backgroundColor:e.custom.palette.surface.default,borderBottom:`0.5px solid ${e.custom.palette.stroke.default}`,display:"flex",gap:e.spacing(1),justifyContent:"space-between",padding:1}))),Mf=t.styled(t.Box)((({theme:e})=>({alignItems:"center",display:"flex",gap:e.spacing(1)}))),Tf=t.styled(dn)((({theme:e})=>({color:e.custom.palette.text.secondary})));var Pf={headings:{"01-starter":{heading:"Starter",pricing:"{{currencySymbol}} {{starterPrice}} / month"},"02-team":{heading:"Team",pricing:"{{currencySymbol}} {{teamPrice}} / month"},"03-plus":{heading:"Plus",pricing:"{{currencySymbol}} {{plusPrice}} / month"},"04-scale":{heading:"Scale",pricing:"{{currencySymbol}} {{scalePrice}} / month"}},rows:{"01-seats":{heading:"Seats",description:"The number of users you can have on your account.",starter:"1",team:"10",plus:"50",scale:"100+"},"02-servicing":{heading:"Client servicing included",description:"Get direct communication with a Loops Customer Success Manager.",starter:"{{dash}}",team:"{{dash}}",plus:"Serviced lite",scale:"💪\nFully serviced"},"03-respondents":{heading:"Price per respondent",description:"The amount you pay to recruit and survey each respondent.",starter:"{{currencySymbol}}{{starterRespondentPrice}}",team:"{{currencySymbol}}{{teamRespondentPrice}}",plus:"{{currencySymbol}}{{plusRespondentPrice}}",scale:"{{currencySymbol}}{{scaleRespondentPrice}}"},"04-questions":{heading:"Question limit",description:"The maximum number of questions you can add to a test.",starter:"10",team:"15",plus:"20",scale:"25"},"05-ai":{heading:"AI-powered insights",description:"Use Loops AI to summarise the findings from your tests.",starter:"Basic",team:"✨\nAdvanced",plus:"✨\nAdvanced",scale:"✨\nAdvanced"},"06-demographics":{heading:"Demographic filters",description:"Reach your target audience using built-in demographic filters.",starter:"Basic",team:"🎯\nAdvanced",plus:"🎯\nAdvanced",scale:"🎯\nAdvanced"},"07-training":{heading:"Training",description:"Our team will onboard you and get you set up.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"08-invite":{heading:"Invite your own respondents",description:"Share your test with your own recruited audience.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"09-email":{heading:"Email capture",description:"Ability to collect respondent email addresses.",starter:"{{dash}}",team:"{{tick}}",plus:"{{tick}}",scale:"{{tick}}"},"10-beta":{heading:"Beta features",description:"Assess to our latest features as they become available.",starter:"{{dash}}",team:"{{dash}}",plus:"{{tick}}",scale:"{{tick}}"},"11-sso":{heading:"Single sign on (SSO)",description:"Enterprise level authentication using SAML (supports Okta and OneLogin).",starter:"{{dash}}",team:"{{dash}}",plus:"{{dash}}",scale:"{{tick}}"},"12-minimum":{heading:"Minimum term",description:"The minimum subscription period.",starter:"30 days",team:"6 months",plus:"6 months",scale:"12 months"}}};const Bf=({text:e})=>{const n=t.useTheme(),o="{{tick}}"===e,i="{{dash}}"===e;return ge.jsx(t.Box,{sx:{display:"flex",alignItems:"center",textAlign:"center",width:122},children:ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"center",alignItems:"center",p:{sm:.5,md:1},flex:1},children:[o&&ge.jsx(en,{name:"badge-tick-in-circle",size:24}),i&&ge.jsx(en,{name:"badge-hyphen",size:24}),!o&&!i&&ge.jsx(dn,{variation:"lg",component:"p",sx:{color:n.custom.palette.text.secondary,hyphens:"none",whiteSpace:"pre"},children:ge.jsx(ge.Fragment,{children:e})})]})})},Af=()=>{const t="object"==typeof window;function n(){return{width:t?window.innerWidth:void 0,height:t?window.innerHeight:void 0}}const[o,i]=e.useState(n);return e.useEffect((()=>{if(t)return window.addEventListener("resize",o),()=>window.removeEventListener("resize",o);function o(){e.startTransition((()=>{i(n())}))}}),[]),o};const Ef="https://useloops-public.s3.eu-west-2.amazonaws.com/public/fonts/",zf=()=>ge.jsx(t.GlobalStyles,{styles:{"strong, b":{fontWeight:500}}}),If=e.createContext(null),Rf=(n="light",o="lg",i="ltr")=>{const{width:r}=Af(),[s,a]=e.useState(n),[l,c]=e.useState(o),[u,d]=e.useState(i),[p,h]=e.useState(!1),[m,f]=e.useState("");e.useEffect((()=>{document.documentElement.setAttribute("dir",u)}),[u]);e.useEffect((()=>{e.startTransition((()=>{c(r&&r<X.lg?"sm":"lg")}))}),[r]),e.useEffect((()=>{e.startTransition((()=>{d(i)}))}),[i]),e.useEffect((()=>{e.startTransition((()=>{a(n)}))}),[n]);const g=e.useMemo((()=>((e,n,o)=>t.createTheme({direction:o,custom:{palette:{black:"#000000",white:"#ffffff",neutral:N[e],neutralAlpha:"light"===e?V:F,purple:U[e],red:G[e],peach:q[e],yellow:K[e],blue:Z[e],green:Y[e],icon:ae[e].icon,interaction:ae[e].interaction,stroke:ae[e].stroke,surface:ae[e].surface,text:ae[e].text,input:ae[e].input},margin:ee,padding:te,radius:ne,elevation:oe,elevationFilter:ie,boxShadow:re,easing:se,typography:On[n]},palette:{mode:e,primary:{main:L[500]}},spacing:Q,shape:{borderRadius:Q,hotspot:{default:12,active:24}},breakpoints:{values:X},typography:{fontFamily:`"${ce.FoundersGrotesk.name}", "Helvetica", "sans-serif"`},components:{MuiTypography:{variants:$n(n),styleOverrides:{root:{color:ae[e].text.primary,letterSpacing:0,lineHeight:"140%"}}},MuiCssBaseline:{styleOverrides:`\n\t\t\t\t\tbody {\n\t\t\t\t\t\tbackground: ${N[e][0]};\n\t\t\t\t\t\tmin-width: 320px;\n\t\t\t\t\t}\n\t\t\t\t\ta {\n\t\t\t\t\t\tcolor: inherit;\n\t\t\t\t\t\tdisplay: flex;\n\t\t\t\t\t\ttext-decoration: none;\n\t\t\t\t\t}\n\t\t\t\t\tb {\n\t\t\t\t\t\tfont-weight: 500;\n\t\t\t\t\t}\n @font-face {\n font-family: '${ce.Domaine.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.Domaine.default.weight};\n src: url(${Ef}${ce.Domaine.default.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.Domaine.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.Domaine.bold.weight};\n src: url(${Ef}${ce.Domaine.bold.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.FoundersGrotesk.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.FoundersGrotesk.default.weight};\n src: url(${Ef}${ce.FoundersGrotesk.default.fileName}) format('woff2');\n }\n @font-face {\n font-family: '${ce.FoundersGrotesk.name}';\n font-style: normal;\n font-display: swap;\n font-weight: ${ce.FoundersGrotesk.bold.weight};\n src: url(${Ef}${ce.FoundersGrotesk.bold.fileName}) format('woff2');\n }\n `},MuiContainer:{defaultProps:{maxWidth:"xl",disableGutters:!0},styleOverrides:{root:{paddingLeft:16,paddingRight:16,[`@media (min-width: ${X.md}px)`]:{paddingLeft:24,paddingRight:24},[`@media (min-width: ${X.lg}px)`]:{paddingLeft:48,paddingRight:48}}}},MuiButtonBase:{defaultProps:{disableTouchRipple:!0,disableRipple:!0}},MuiButton:{defaultProps:{disableTouchRipple:!0,disableRipple:!0}},MuiTooltip:{styleOverrides:{arrow:({theme:{custom:e}})=>({color:e.palette.surface.overlay}),tooltip:({theme:{custom:e}})=>({backgroundColor:e.palette.surface.overlay,borderRadius:e.radius.md,color:e.palette.text.primary,backdropFilter:"blur(0)",filter:e.elevationFilter.overlay,fontFamily:ce.FoundersGrotesk.name,fontSize:e.typography.body.sm,fontWeight:400,padding:`${e.padding.sm*Q}px ${e.padding.md*Q}px`})}},MuiAvatarGroup:{styleOverrides:{root:{flexDirection:"row"},avatar:({theme:{custom:e}})=>({border:`1px solid ${e.palette.stroke.default}`,marginLeft:0,marginRight:-8,":last-child":{marginLeft:"auto"}})}}}}))(s,l,u)),[s,u,l]),x=t.useMediaQuery(g.breakpoints.only("sm"),{noSsr:!0}),v=t.useMediaQuery(g.breakpoints.only("md"),{noSsr:!0}),y=t.useMediaQuery(g.breakpoints.between("lg","xl"),{noSsr:!0}),b=t.useMediaQuery(g.breakpoints.up("xl"),{noSsr:!0});return e.useEffect((()=>{e.startTransition((()=>{x&&f("sm"),v&&f("md"),y&&f("lg"),b&&f("xl")}))}),[x,v,y,b]),{breakpoint:m,gridOverlayVisible:p,mode:s,theme:g,toggleGridOverlay:()=>{e.startTransition((()=>{h((e=>!e))}))},toggleMode:t=>{e.startTransition((()=>{if(t)return a(t);a((e=>"light"===e?"dark":"light"))}))}}},Vf=df({key:"muirtl",stylisPlugins:[k.prefixer,P]}),Ff=df({key:"mui"});exports.AnnualController=({body:e,currency:n,changeCurrencyEvent:o=()=>{},frequency:i,heading:r,setCurrency:s=()=>{},setFrequency:a=()=>{},togglePayAnnuallyEvent:l=()=>{},sizing:c="lg",selections:u=[{value:"gbp",label:"£"},{value:"eur",label:"€"},{value:"usd",label:"$"}]})=>{const d=t.useTheme(),p=Wo();return ge.jsxs(t.Box,{sx:{alignItems:"center",backgroundColor:d.custom.palette.surface.default,borderRadius:d.custom.radius.round,boxShadow:d.custom.elevation.raised,display:"flex",gap:{sm:2,lg:4},mb:2,mt:4,px:{sm:2,lg:"sm"===c?2:4},py:{sm:1,lg:2}},children:[ge.jsxs(t.Box,{sx:{alignItems:"center",display:"flex",gap:1},children:[ge.jsx(t.Box,{sx:{pr:2},children:ge.jsx(jm,{defaultChecked:!0,onChange:()=>(l(),void a("monthly"===i?"annual":"monthly")),role:"switch","aria-checked":"monthly"!==i,"aria-label":"Switch between monthly and annual billing",inputProps:{"aria-label":"Input for switch between monthly and annual billing"},sizing:c})}),ge.jsxs(t.Stack,{sx:{alignItems:"flex-start",display:"flex"},children:[ge.jsx(dn,{variation:"sm"===p||"md"===p||"sm"===c?"md":"xxl",component:"p",children:r}),ge.jsx(dn,{variation:"sm",component:"p",sx:{color:d.custom.palette.text.secondary},children:e})]})]}),ge.jsx(Yh,{name:"currency",onChange:e=>{return t=e.target.value,o(t),void s(t);var t},selections:u,value:u.find((e=>e.value===n))?.value,sx:{minWidth:{sm:64,lg:72},height:{sm:J[400],lg:J[500]}}})]})},exports.AuthContainerSurface=({children:e,headContent:o,sx:i,...r})=>{const s=t.useTheme();return ge.jsxs(an,{...r,sx:n.mergeSx(i,{mx:[s.spacing(s.custom.margin.md),0],width:1,maxWidth:[512]}),children:[o&&ge.jsx(t.Box,{sx:{width:"100%",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit",pt:s.spacing(s.custom.margin.md),px:s.spacing(s.custom.margin.md)},children:o}),ge.jsx(t.Box,{sx:{width:"100%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",pt:o?[s.spacing(s.custom.margin.md)]:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)],px:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)],pb:[s.spacing(s.custom.padding.lg),s.spacing(s.custom.padding.xl)]},children:e})]})},exports.AuthFormHeader=({logo:e,headerText:n,subText:o})=>{const i=t.useTheme();return ge.jsxs(t.Stack,{gap:i.spacing(i.custom.margin.md),alignItems:"center",mb:i.spacing(i.custom.margin.lg),children:[!1===e?null:e||ge.jsx(en,{name:"brand-wordmark",sx:{width:{sm:79,md:79,lg:106},height:{sm:24,md:24,lg:32}}}),ge.jsxs(t.Stack,{gap:i.spacing(i.custom.margin.md),children:[n&&ge.jsx(dn,{variation:"sm",component:"h1",align:"center",weight:"bold",children:n}),function(){if(o)return"string"==typeof o?ge.jsx(dn,{variation:"md",component:"p",align:"center",children:o}):o}()]})]})},exports.Avatar=Co,exports.AvatarGroup=({variation:e="primary",...n})=>{if("primary"===e)return ge.jsx(t.AvatarGroup,{...n})},exports.Breadcrumb=gn,exports.Button=Tp,exports.Checkbox=th,exports.CheckboxGroup=ih,exports.ColorBackgroundContainer=({sx:e,children:o,texture:i="noise1",gradient:r="tone1",...s})=>{const a=t.useTheme();return ge.jsx(t.Container,{maxWidth:!1,disableGutters:!0,sx:n.mergeSx({background:Xp(a,{texture:i,gradient:r}),height:"100%",p:[0,0,0]},!!e&&{...e}),...s,children:o})},exports.CustomField=rh,exports.DEFAULT_MAX_INPUT_LENGTH=Kp,exports.Differential=gh,exports.DropdownMenu=({open:e,anchorEl:n,handleClick:o,handleClose:i,items:r,...s})=>ge.jsx(ge.Fragment,{children:ge.jsx(xh,{anchorEl:n,open:e,onClose:i,MenuListProps:{"aria-labelledby":"basic-button"},elevation:0,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},...s,children:r?.map(((e,n)=>ge.jsxs(t.MenuItem,{onClick:e.onClick,...e.menuItemProps,children:[e.icon&&ge.jsx(t.Box,{mr:1,children:e.icon}),e.label]},n)))})}),exports.FormControlLabel=Jp,exports.FormGenerator=Vm,exports.GridOverlay=({breakpoint:e})=>{const n=Array.from({length:6},((e,t)=>t));return e||(e=Wo()),ge.jsxs(Fm,{children:[ge.jsx(Lm,{children:ge.jsx(Dm,{children:ge.jsxs(t.Unstable_Grid2,{container:!0,spacing:2,sx:{flex:1},children:[n.map((e=>ge.jsx(t.Unstable_Grid2,{sm:!0,sx:{display:{sm:"none",md:"block"}},children:ge.jsx(Om,{})},`grid-1-${e}`))),n.map((e=>ge.jsx(t.Unstable_Grid2,{sm:!0,sx:{display:{sm:"block"}},children:ge.jsx(Om,{})},`grid-2-${e}`)))]})})}),!!e&&ge.jsx($m,{children:ge.jsx(dn,{variation:"md",component:"p",weight:"bold",children:e})})]})},exports.Header=({backHref:e,title:n,breadcrumbLinks:o,buttons:i,controlBar:r})=>ge.jsxs(ge.Fragment,{children:[ge.jsx(En,{sx:{justifyContent:"space-between"},children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsxs(Vn,{sx:{justifyContent:"space-between",py:1},children:[ge.jsxs(Vn,{children:[e&&ge.jsx(An,{sizing:"lg",icon:ge.jsx(en,{name:"arrow-left",size:20})}),ge.jsxs(Vn,{sx:{alignItems:"flex-start",flexDirection:"column",gap:0},children:[n&&ge.jsx(dn,{variation:"lg",component:"p",weight:"bold",children:n}),o&&ge.jsx(gn,{links:o})]})]}),i&&ge.jsx(Vn,{children:i})]})})})})}),r&&ge.jsx(zn,{children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsx(In,{children:ge.jsx(Rn,{children:r})})})})})})]}),exports.Html=yh,exports.Icon=en,exports.IconButton=An,exports.IconButtonGroup=({ButtonGroupProps:e,children:t,...n})=>ge.jsx(Nm,{...n,...e,children:t}),exports.Image=Um,exports.InputFieldBase=nh,exports.InputLabel=bh,exports.InputLabelHelp=lh,exports.Likert=Ph,exports.Link=cn,exports.Loader=()=>ge.jsx(t.Box,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:"calc(100dvh - 80px)"},children:ge.jsx("img",{src:"https://useloops-public.s3.eu-west-2.amazonaws.com/public/landing/brand/loading-animation.gif",width:125})}),exports.Logo=e=>ge.jsx("svg",{viewBox:"0 0 80 25",fill:"currentColor",...e,children:ge.jsx("path",{d:"M8.72886 20.0975C7.43461 19.1995 7.16357 18.9302 7.16357 16.9549V0.988281H-0.000106812V1.28748L0.0165316 1.29764C1.3293 2.09875 1.92633 2.46309 1.92633 4.43011V16.9549C1.92633 18.9302 1.65553 19.1995 0.361043 20.0975V20.3965H8.72886V20.0975ZM14.5709 13.437C13.7868 9.01598 14.1045 7.0153 16.0905 6.66718C18.0767 6.31907 19.0631 8.09095 19.8472 12.512C20.6311 16.933 20.3137 18.9335 18.3275 19.2816C16.3415 19.6299 15.3548 17.8578 14.5709 13.437ZM9.11663 14.3934C9.93203 18.9911 14.141 21.3529 18.5575 20.5785C22.9743 19.8041 26.1169 16.1534 25.3015 11.5559C24.4861 6.95793 20.2773 4.5961 15.8605 5.3705C11.444 6.14467 8.30123 9.79541 9.11663 14.3934ZM33.3669 6.66718C31.381 7.0153 31.0633 9.01598 31.8474 13.437C32.6313 17.8578 33.618 19.6299 35.6039 19.2816C37.5901 18.9335 37.9076 16.933 37.1237 12.512C36.3396 8.09095 35.3531 6.31907 33.3669 6.66718ZM35.834 20.5785C31.4175 21.3529 27.2085 18.9911 26.3931 14.3934C25.5777 9.79541 28.7205 6.14467 33.137 5.3705C37.5538 4.5961 41.7625 6.95793 42.5779 11.5559C43.3933 16.1534 40.2508 19.8041 35.834 20.5785ZM52.9075 18.9002C51.0712 18.9002 49.6266 16.8353 49.6266 14.441V12.3162C49.6266 9.6524 50.9209 7.64737 52.9075 7.64737C54.9843 7.64737 56.0078 9.53285 56.0078 12.7351C56.0078 16.955 54.9542 18.9002 52.9075 18.9002ZM51.6733 24.5936C50.1696 23.7488 49.6266 23.4437 49.6266 21.5189V17.9125C50.4091 19.4689 51.9744 20.6958 54.5629 20.6958C58.476 20.6958 61.5762 17.763 61.5762 12.7052C61.5762 7.55754 58.5663 5.25308 55.1047 5.25308C52.2753 5.25308 50.3187 6.83937 49.6266 9.02405L49.5063 5.55228H42.5833V5.85171L42.5873 5.85427C43.8786 6.69033 44.3891 7.02081 44.3891 8.99411V21.5189C44.3891 23.4942 44.1183 23.7637 42.824 24.6613V24.9605H51.7937V24.6613L51.6733 24.5936ZM79.8954 18.9002C79.8954 19.8689 79.1055 20.6543 78.1313 20.6543C77.157 20.6543 76.3671 19.8689 76.3671 18.9002C76.3671 17.9315 77.157 17.1462 78.1313 17.1462C79.1055 17.1462 79.8954 17.9315 79.8954 18.9002ZM70.0692 10.2734C68.0387 9.67975 66.9044 9.34812 66.9044 8.15614C66.9044 7.16849 67.8074 6.71957 68.8309 6.71957C70.7874 6.71957 72.3224 7.827 74.0985 10.4007H74.5196V5.25306H74.2187L72.8642 6.24072C72.8031 6.21577 72.742 6.19075 72.681 6.16573C71.5696 5.71024 70.454 5.25306 68.7707 5.25306C65.55 5.25306 62.9916 7.22837 62.9916 10.1612C62.9916 12.795 64.2557 14.2912 68.8008 15.4585C70.4863 15.8775 71.6601 16.1767 71.6601 17.4636C71.6601 18.6608 70.4863 19.2293 69.0718 19.2293C66.9044 19.2293 65.3093 17.763 63.2021 14.9797H62.7509L63.0819 20.6661H63.413L64.6169 19.4688C65.5801 19.9477 67.0851 20.6958 69.1019 20.6958C72.9546 20.6958 75.6334 18.571 75.6334 15.5783C75.6334 12.4956 73.7672 11.3584 70.095 10.2809L70.0692 10.2734Z"})}),exports.LoopsAiButton=()=>ge.jsx(Gm,{variation:"primary",sizing:"md",startIcon:ge.jsx(en,{name:"ai"}),children:"Loops AI"}),exports.Markdown=e=>{const{children:t}=e,n=t&&t.replaceAll(/\s/g,"&nbsp;").replaceAll(/<p><\/p>/g,"<br />");return ge.jsx(S,{options:{overrides:{p:{component:dn,props:qm},strong:{component:dn,props:{...qm,weight:"bold"}},em:{component:dn,props:{...qm,fontWeight:"inherit",fontStyle:"italic"}}},wrapper:Km,forceBlock:!0,forceWrapper:!0},children:n})},exports.MenuButton=io,exports.Navigation=({logoLink:e,isMobile:n,nudgeProps:o,primaryMenuItemProps:i,secondaryMenuItemProps:r,sizing:s="lg",tertiaryMenuItemProps:a,toggleMenuOnClick:l=()=>{},userMenuProps:c})=>{const u=t.useTheme();return ge.jsxs(Oo,{navigationSizing:s,children:[ge.jsx(Do,{logoLink:e,navigationSizing:s,toggleMenuOnClick:l,isMobile:n}),ge.jsx($o,{children:ge.jsxs(t.Stack,{sx:{gap:4,justifyContent:"space-between",width:"100%"},children:[i?.length>0&&ge.jsx(t.Stack,{sx:{gap:"lg"===s?.5:2,width:"100%"},children:i.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e},`primary-menu-item-${t}`)))}),ge.jsxs(t.Stack,{sx:{gap:2},children:[o?.title&&ge.jsx(jo,{navigationSizing:s,...o}),r?.length>0&&r.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e,label:"Help center"===e.label&&"sm"===s?"Help":e.label},`secondary-menu-item-${t}`))),ge.jsx(t.Divider,{sx:{color:u.custom.palette.stroke.default}}),ge.jsx(Io,{navigationSizing:s,...c}),a?.length>0&&ge.jsx(Ho,{children:a.map(((e,t)=>ge.jsx(io,{navigationSizing:s,...e},`tertiary-menu-item-${t}`)))})]})]})})]})},exports.Nudge=jo,exports.NumberField=Ah,exports.OnboardingCard=({cardTitle:n,cardSubtitle:i,welcomeImageUrl:r,welcomeImageAltDescription:s,items:a=[]})=>{const[l,c]=e.useState(!0),u=Wo(),d=()=>c(!l),p=a.length,h=a.filter((e=>e.complete)).length,m=h/p*100;return ge.jsxs(an,{variation:"raised",borderradius:"lg",sx:{display:"flex",flexDirection:"xl"===u?"row":"column",gap:e=>e.spacing(e.custom.margin.lg),padding:e=>e.spacing(e.custom.padding.lg)},children:[ge.jsxs(Uo,{children:[ge.jsx(t.Box,{component:"img",src:r,alt:s,width:"72px",height:"72px"}),ge.jsx(dn,{component:"h1",variation:"md",fontWeight:500,children:n}),ge.jsx(qo,{component:"p",variation:"lg",children:i})]}),ge.jsxs(Go,{children:[ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"space-between",alignItems:"start",width:"100%",height:"36px",paddingBottom:e=>e.spacing(e.custom.padding.sm)},children:[ge.jsx(Op,{completed:h,total:p}),l&&ge.jsx(An,{sizing:"sm",variation:"outlined",icon:ge.jsx(o.ExpandLess,{}),onClick:d})]}),ge.jsx(_o,{variation:"determinate",value:m}),ge.jsx(Dp,{expanded:l,onToggleExpanded:d,items:a})]})]})},exports.Pill=({body:e,maxWidth:t,...n})=>ge.jsx(Xm,{label:e,sx:{...t&&{maxWidth:`${t}px`}},...n}),exports.PlanFeatureTable=({currencySymbol:e,data:n,starterPrice:o,starterRespondentPrice:i,teamPrice:r,teamRespondentPrice:s,plusPrice:a,plusRespondentPrice:l,scalePrice:c,scaleRespondentPrice:u,variation:d="default"})=>{const p=t.useTheme();n||(n=Pf);const h=Object.values(n.headings).map((({heading:t,pricing:n})=>({heading:t,pricing:n.replace("{{currencySymbol}}",e).replace("{{starterPrice}}",o).replace("{{teamPrice}}",r).replace("{{plusPrice}}",a).replace("{{scalePrice}}",c)}))),m=t=>t.replace("{{currencySymbol}}",e).replace("{{starterRespondentPrice}}",i||"").replace("{{teamRespondentPrice}}",s||"").replace("{{plusRespondentPrice}}",l||"").replace("{{scaleRespondentPrice}}",u||""),f=[...Object.values(n.rows).map(((e,t)=>({key:`pricing-table-features-${t}`,type:"row",name:{heading:e.heading,description:e.description},starter:m(e.starter),team:m(e.team),plus:m(e.plus),scale:m(e.scale)})))];return ge.jsxs(t.Stack,{sx:{backgroundColor:p.custom.palette.surface.default,borderRadius:p.spacing(p.custom.radius.xl),boxShadow:p.custom.elevation.raised,display:"flex",gap:2,pb:{sm:2,lg:4},px:{sm:2,lg:4},minWidth:{sm:680}},children:[ge.jsxs(t.Box,{sx:{display:"flex",py:2,px:1,justifyContent:"space-between"},children:[ge.jsx(t.Box,{sx:{width:160}}),h.map((({heading:e,pricing:n})=>ge.jsxs(t.Stack,{sx:{alignItems:"center",display:"flex",justifyContent:"center",width:122},children:[ge.jsx(dn,{variation:"platform"===d?"lg":"xxl",component:"p",weight:"bold",children:e}),ge.jsx(dn,{variation:"platform"===d?"sm":"md",component:"p",sx:{color:p.custom.palette.text.secondary},children:n})]},e)))]}),f.map((e=>ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"space-between",p:1,"&:nth-of-type(odd)":{backgroundColor:p.custom.palette.surface.sunken}},children:[ge.jsx(t.Box,{sx:{display:"flex",alignItems:"center",width:160},children:ge.jsxs(t.Box,{sx:{display:"flex",justifyContent:"flex-start",alignItems:"center",flex:1,gap:1},children:[e.name.description&&ge.jsx(yn,{message:e.name.description,children:ge.jsx(t.Box,{sx:{alignItems:"center",color:p.custom.palette.icon.secondary,display:"flex"},children:ge.jsx(en,{name:"info",size:24})})}),ge.jsx(dn,{variation:"platform"===d?"md":"lg",component:"p",children:e.name.heading})]})}),ge.jsx(Bf,{text:e.starter}),ge.jsx(Bf,{text:e.team}),ge.jsx(Bf,{text:e.plus}),ge.jsx(Bf,{text:e.scale})]},e.key)))]})},exports.PlanTierCard=({amount:n,billingType:o,body:i,ctaEvent:r=()=>{},ctaLink:s="#",ctaTarget:a="_self",ctaText:l,ctaVariation:c="primary",currencySymbol:u,currentPlan:d,features:p=[],freeTrialLength:h,freeTrialText:m,frequency:f,heading:g,label:x,largestHeaderHeight:v=0,perMonth:y,setLargestHeaderHeight:b=()=>{},variation:w="default"})=>{const j=t.useTheme(),C=Wo(),{width:S}=Af(),k=e.useRef(null),[M,T]=e.useState("sm");return e.useEffect((()=>{e.startTransition((()=>{T(C),C!==M&&b(0),k.current&&k.current.offsetHeight>v&&b(k.current.offsetHeight)}))}),[C,M,S]),ge.jsxs(t.Stack,{sx:{display:"flex",flex:1,position:"relative"},children:[ge.jsx(t.Stack,{sx:{alignItems:"center",backgroundColor:j.custom.palette.icon.primary,borderTopLeftRadius:j.spacing(j.custom.radius.lg),borderTopRightRadius:j.spacing(j.custom.radius.lg),boxShadow:j.custom.elevation.overlay,color:j.custom.palette.text.primaryInverted,justifyContent:"center",p:{sm:1,lg:2},textTransform:"uppercase",opacity:x?1:0,display:{sm:x?"flex":"none",md:"flex"}},children:ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:{color:j.custom.palette.white},children:x||"&nbsp;"})}),ge.jsxs(t.Stack,{sx:{backgroundColor:j.custom.palette.surface.default,borderBottomLeftRadius:j.spacing(j.custom.radius.lg),borderBottomRightRadius:j.spacing(j.custom.radius.lg),borderTopLeftRadius:x?0:j.spacing(j.custom.radius.lg),borderTopRightRadius:x?0:j.spacing(j.custom.radius.lg),boxShadow:j.custom.elevation.overlay,display:"flex",flex:1},children:[ge.jsxs(t.Stack,{sx:{display:"flex",gap:"sm"===C||"md"===C?1:2,textAlign:"center",minHeight:{sm:"none",md:v},px:2,py:{sm:2,lg:4}},ref:k,children:[ge.jsx(dn,{variation:"sm"===C?"xxl":"platform"===w?"md":"lg",component:"h2",weight:"bold",children:g}),ge.jsx(dn,{variation:"sm"===C?"md":"platform"===w?"md"===C?"sm":"md":"md"===C?"md":"lg",component:"p",sx:{color:j.custom.palette.text.secondary},children:i})]}),ge.jsxs(t.Stack,{sx:{alignItems:"center",display:"flex",gap:2,minHeight:{sm:"none",md:168,lg:"platform"===w?184:240,xl:"platform"===w?184:226},px:2,py:{sm:2,md:2,lg:"platform"===w?2:6}},children:[ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex",gap:.5,justifyContent:"center"},children:[ge.jsx(dn,{variation:"md"===C?"sm":"xxl",component:"p",weight:"bold",sx:{lineHeight:1,marginBottom:-.15,marginRight:-.4},children:u}),ge.jsx(dn,{variation:"xxl",component:"p",weight:"bold",sx:{fontSize:{sm:48,md:26,lg:48},lineHeight:.8},children:n}),y&&ge.jsx(dn,{variation:"sm",component:"p",sx:{color:j.custom.palette.text.secondary,lineHeight:1,marginLeft:-.5},children:y})]}),h&&m&&ge.jsxs(t.Box,{sx:{alignItems:"center",backgroundColor:j.custom.palette.yellow[300],borderRadius:j.custom.radius.round,boxShadow:j.custom.elevation.raised,display:"flex",gap:{sm:.5,md:1},px:2,py:1},children:[ge.jsx(en,{name:"gift",size:24}),ge.jsxs(t.Box,{sx:{display:"flex",flexDirection:{sm:"row",md:"column",lg:"row"},gap:{sm:.5,md:0,lg:.5}},children:[ge.jsx(dn,{variation:"md",component:"p",weight:"bold",sx:{lineHeight:1},children:h}),ge.jsx(dn,{variation:"md",component:"p",sx:{lineHeight:1},children:m})]})]}),o&&ge.jsx(dn,{variation:"sm",component:"p",sx:{color:j.custom.palette.text.placeholder},children:o})]}),ge.jsxs(t.Stack,{sx:{display:"flex",flexDirection:{sm:"column-reverse",md:"column"}},children:[ge.jsx(t.Box,{sx:{py:{sm:2,md:0},px:{sm:2,lg:4}},children:ge.jsx(cn,{href:s,title:l,target:a,onClick:()=>{g&&r(g)},sx:{"&:hover":{cursor:d?"default":"pointer"}},children:ge.jsx(Tp,{fullWidth:!0,variation:c,sizing:"lg",disabled:d,children:l})})}),p?.length&&ge.jsx(t.Stack,{sx:{alignItems:"center",gap:.5,px:{sm:2,lg:4},py:{sm:2,md:4,lg:"platform"===w?4:6}},children:p.map(((e,n)=>ge.jsxs(t.Box,{sx:{alignItems:"center",display:"flex",gap:1,maxWidth:200,width:"100%"},children:[ge.jsx(en,{name:"badge-tick",size:24}),ge.jsx(dn,{variation:"md",component:"p",children:e})]},`${g}-feature-${n}`)))})]})]})]})},exports.PlanTierCardScale=({body:e,ctaEvent:n=()=>{},ctaLink:o="",ctaTarget:i="_blank",ctaText:r,currencySymbol:s,heading:a,postText:l,preText:c,amount:u})=>{const d=t.useTheme();return ge.jsxs(t.Box,{sx:{backgroundColor:d.custom.palette.purple[0],borderRadius:d.spacing(d.custom.radius.lg),display:"flex",flexDirection:{sm:"column",md:"row"},textAlign:{sm:"center",md:"left"},boxShadow:d.custom.elevation.overlay,flex:1,gap:{sm:4,md:2},p:{sm:2,lg:4}},children:[ge.jsxs(t.Stack,{sx:{flex:1,gap:2,justifyContent:"center"},children:[ge.jsx(dn,{variation:"md",component:"h2",sx:{fontWeight:500},children:a}),ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.secondary},children:e})]}),ge.jsxs(t.Stack,{sx:{flex:1,gap:{sm:4,md:2},justifyContent:"center",maxWidth:{sm:"none",md:180,lg:320},p:{sm:0,md:2,lg:4}},children:[ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex",justifyContent:"center"},children:[ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.placeholder,pr:.5},children:c}),ge.jsxs(t.Box,{sx:{alignItems:"flex-end",display:"flex"},children:[ge.jsx(dn,{variation:"xxl",component:"p",sx:{fontWeight:500,lineHeight:1.2},children:s}),ge.jsx(dn,{variation:"xxl",component:"p",sx:{fontWeight:500,fontSize:{sm:"1.6rem",lg:"2.2rem"},lineHeight:{sm:1.15,lg:1}},children:u})]}),ge.jsx(dn,{variation:"md",component:"p",sx:{color:d.custom.palette.text.placeholder,pl:.1},children:l})]}),ge.jsx(cn,{href:o,title:r,target:i,onClick:()=>{a&&n(a)},children:ge.jsx(Tp,{fullWidth:!0,variation:"outlined",sizing:"lg",children:r})})]})]})},exports.Popper=xo,exports.Portal=t=>{const[n,o]=e.useState(null),i=n?.contentWindow?.document?.body,r=df({key:"css",container:n?.contentWindow?.document?.head,prepend:!0});return ge.jsx(pf,{ref:o,children:i&&m.createPortal(ge.jsx(M.CacheProvider,{value:r,children:t.children}),i)})},exports.PoweredByWatermarkLogo=()=>ge.jsxs(t.Stack,{gap:.5,flexDirection:"row",children:[ge.jsx(t.SvgIcon,{sx:{width:67,height:12},viewBox:"0 0 67 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:ge.jsx("path",{d:"M2.09034 4.64868H4.09536C5.65956 4.64868 6.41322 4.00878 6.41322 2.84274C6.41322 1.69092 5.65956 1.05102 4.09536 1.05102H2.09034V4.64868ZM2.09034 5.6583V9H0.86742V0.0413991H4.1238C6.34212 0.0413991 7.6077 1.09368 7.6077 2.84274C7.6077 4.60602 6.34212 5.6583 4.1238 5.6583H2.09034ZM9.27266 5.90004C9.27266 7.27938 9.96944 8.26056 11.2208 8.26056C12.4864 8.26056 13.1974 7.27938 13.1974 5.90004C13.1974 4.50648 12.4864 3.53952 11.2208 3.53952C9.96944 3.53952 9.27266 4.50648 9.27266 5.90004ZM14.4061 5.90004C14.4061 7.83396 13.0552 9.17064 11.2208 9.17064C9.40064 9.17064 8.06396 7.83396 8.06396 5.90004C8.06396 3.96612 9.40064 2.61522 11.2208 2.61522C13.0552 2.61522 14.4061 3.96612 14.4061 5.90004ZM19.9082 2.78586L21.2449 7.49268H21.3018L22.738 2.78586H23.8329L21.8564 9H20.7188L19.3963 4.36428H19.3394L18.0312 9H16.8936L14.9028 2.78586H16.083L17.5477 7.49268H17.6046L18.9128 2.78586H19.9082ZM29.4445 6.78168L30.4257 6.89544C30.1271 8.31744 29.0748 9.17064 27.5248 9.17064C25.6762 9.17064 24.3253 7.91928 24.3253 5.98536C24.3253 4.023 25.6762 2.61522 27.4679 2.61522C29.4445 2.61522 30.4541 4.023 30.4541 5.71518V6.17022H25.5056C25.5624 7.40736 26.4299 8.24634 27.539 8.24634C28.5771 8.24634 29.2028 7.74864 29.4445 6.78168ZM25.534 5.445H29.2454C29.217 4.43538 28.634 3.51108 27.4679 3.51108C26.3445 3.51108 25.662 4.40694 25.534 5.445ZM35.5059 2.89962L35.3921 3.96612C35.0509 3.78126 34.8091 3.71016 34.4252 3.71016C33.5293 3.71016 32.861 4.5207 32.861 5.71518V9H31.6807V2.78586H32.861V4.05144C33.0885 3.34044 33.7284 2.61522 34.6243 2.61522C35.0082 2.61522 35.2926 2.71476 35.5059 2.89962ZM40.9288 6.78168L41.91 6.89544C41.6114 8.31744 40.5591 9.17064 39.0091 9.17064C37.1605 9.17064 35.8096 7.91928 35.8096 5.98536C35.8096 4.023 37.1605 2.61522 38.9522 2.61522C40.9288 2.61522 41.9384 4.023 41.9384 5.71518V6.17022H36.9899C37.0468 7.40736 37.9142 8.24634 39.0233 8.24634C40.0614 8.24634 40.6871 7.74864 40.9288 6.78168ZM37.0183 5.445H40.7297C40.7013 4.43538 40.1183 3.51108 38.9522 3.51108C37.8289 3.51108 37.1463 4.40694 37.0183 5.445ZM47.8993 6.07068V5.71518C47.8993 4.36428 47.0461 3.56796 45.9227 3.56796C44.6998 3.56796 44.0172 4.47804 44.0172 5.90004C44.0172 7.32204 44.6998 8.23212 45.9227 8.23212C47.0461 8.23212 47.8993 7.4358 47.8993 6.07068ZM47.8851 9V7.70598C47.6007 8.47386 46.8186 9.17064 45.6525 9.17064C43.8039 9.17064 42.8085 7.73442 42.8085 5.90004C42.8085 4.06566 43.8039 2.61522 45.6525 2.61522C46.8186 2.61522 47.6007 3.32622 47.8851 4.0941V0.0413991H49.0653V9H47.8851ZM54.3847 5.71518V6.07068C54.3847 7.4358 55.2521 8.23212 56.3755 8.23212C57.5984 8.23212 58.2668 7.32204 58.2668 5.90004C58.2668 4.47804 57.5984 3.56796 56.3755 3.56796C55.2521 3.56796 54.3847 4.36428 54.3847 5.71518ZM54.3847 7.70598L54.1288 9H53.2329V0.0413991H54.4132V4.0941C54.6833 3.32622 55.4797 2.61522 56.6457 2.61522C58.4801 2.61522 59.4897 4.06566 59.4897 5.90004C59.4897 7.73442 58.4801 9.17064 56.6315 9.17064C55.4797 9.17064 54.6691 8.48808 54.3847 7.70598ZM62.6822 11.389H61.5304L62.54 8.98578L59.9235 2.78586H61.1607L63.1372 7.56378H63.1941L65.0996 2.78586H66.2656L62.6822 11.389Z",fill:"#473F5C"})}),ge.jsxs(t.SvgIcon,{sx:{width:40,height:12},viewBox:"0 0 40 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[ge.jsx("g",{id:"Brand/Wordmark",clipPath:"url(#clip0_900_1816)",children:ge.jsx("path",{id:"Union",fillRule:"evenodd",clipRule:"evenodd",d:"M4.3189 9.56522C3.67851 9.11556 3.54429 8.98169 3.54429 7.99199V0H0V0.149886L0.00580287 0.153463C0.656931 0.554852 0.953183 0.737477 0.953183 1.72311V7.99199C0.953183 8.98169 0.818964 9.11556 0.17858 9.56522V9.7151H4.3189V9.56522ZM4.51113 6.71053C4.91378 9.01144 6.99646 10.1934 9.18264 9.80664C11.3677 9.41876 12.9226 7.58467 12.5199 5.28947C12.1173 2.99428 10.0346 1.80549 7.84841 2.19336C5.66223 2.58124 4.10847 4.40961 4.51113 6.71053ZM7.2103 6.23112C6.8247 4.01831 6.98053 3.01716 7.96215 2.84325C8.94377 2.66819 9.43515 3.55263 9.82074 5.76545C10.2063 7.97826 10.0516 8.97483 9.06889 9.15332C8.08613 9.33181 7.59589 8.44394 7.2103 6.23112ZM17.7306 9.80664C15.5455 10.1934 13.4629 9.01144 13.0591 6.71053C12.6553 4.40961 14.2102 2.58124 16.3963 2.19336C18.5825 1.80549 20.6641 2.99428 21.0678 5.28947C21.4716 7.58467 19.9156 9.41876 17.7306 9.80664ZM16.5101 2.84325C15.5273 3.01716 15.3726 4.01831 15.7582 6.23112C16.1438 8.44394 16.6341 9.33181 17.6168 9.15675C18.5996 8.98169 18.7543 7.98169 18.3687 5.76888C17.9831 3.55606 17.4928 2.66819 16.5101 2.84325ZM25.5683 11.8168C24.8234 11.3931 24.5553 11.2406 24.5553 10.2769L24.5575 8.4794C24.9443 9.25858 25.7189 9.873 26.9997 9.873C28.9356 9.873 30.47 8.40046 30.47 5.86842C30.47 3.29176 28.9743 2.13844 27.2681 2.13844C25.8679 2.13844 24.8988 2.93249 24.5575 4.02631L24.4973 2.28833H21.0724V2.43135L21.0731 2.43181C21.713 2.85024 21.9653 3.01524 21.9653 4.00458V10.2769C21.9653 11.2654 21.8322 11.4005 21.1907 11.8501V12H25.6267V11.8501L25.5683 11.8168ZM26.1784 8.9611C25.2696 8.9611 24.5553 7.92792 24.5553 6.72998V5.66247C24.5553 4.32952 25.1957 3.32494 26.1784 3.32494C27.2055 3.32494 27.7117 4.27002 27.7117 5.87185C27.7117 7.98741 27.1907 8.9611 26.1784 8.9611ZM38.6585 9.84325C39.1403 9.84325 39.5309 9.45034 39.5309 8.96567C39.5309 8.481 39.1403 8.0881 38.6585 8.0881C38.1767 8.0881 37.7861 8.481 37.7861 8.96567C37.7861 9.45034 38.1767 9.84325 38.6585 9.84325ZM34.6585 4.64621C33.661 4.35019 33.0998 4.18365 33.0998 3.5881C33.0998 3.08924 33.5548 2.86842 34.0552 2.86842C35.0244 2.86842 35.783 3.42334 36.6623 4.71167H36.8704V2.13501H36.7214L36.0515 2.62929C36.0223 2.61721 35.9931 2.6051 35.9639 2.59299C35.4126 2.36413 34.8607 2.13501 34.0257 2.13501C32.4321 2.13501 31.1661 3.12357 31.1661 4.59153C31.1661 5.90961 31.7929 6.65904 34.0416 7.24371C34.8765 7.45309 35.4566 7.60297 35.4566 8.24714C35.4566 8.84668 34.8765 9.13043 34.1758 9.13043C33.0998 9.13043 32.3138 8.39702 31.2799 7.00343H31.0524L31.2094 9.85011H31.3731L31.968 9.25057C32.4446 9.49085 33.1897 9.86499 34.1872 9.86499C36.0936 9.86499 37.4198 8.80091 37.4198 7.3032C37.4198 5.75973 36.4985 5.19107 34.6786 4.65217L34.6585 4.64621Z",fill:"#473F5C"})}),ge.jsx("defs",{children:ge.jsx("clipPath",{id:"clip0_900_1816",children:ge.jsx("rect",{width:"39.5321",height:"12",fill:"white"})})})]})]}),exports.Progress=vn,exports.ProgressBar=_o,exports.ProjectItem=e=>"list"===e.viewType?ge.jsx(Sf,{...e}):ge.jsx(Cf,{...e}),exports.ProjectItemEmpty=({onClick:e,viewType:n,title:o})=>{const i=t.useTheme();return"list"===n?ge.jsx(ff,{divider:!0,children:ge.jsxs(gf,{onClick:e,sx:{p:i.spacing(i.custom.padding.xs),display:"flex",gap:i.spacing(i.custom.margin.sm),alignItems:"center"},children:[ge.jsx(xf,{sx:{height:72,width:108},"data-id":"image-container",children:ge.jsx(wf,{viewType:n,children:ge.jsx(en,{name:"add"})})}),ge.jsx(yf,{sx:{overflow:"hidden",pl:i.spacing(i.custom.padding.sm),minWidth:67,flex:1,"&:last-child":{pb:0}},children:ge.jsx(t.Stack,{gap:i.spacing(i.custom.margin.xs),children:ge.jsx(Up,{title:o,maxLines:1})})})]})}):ge.jsx(ff,{sx:{height:"100%"},children:ge.jsxs(gf,{onClick:e,disableHoverStyle:!0,sx:{height:"100%"},children:[ge.jsx(xf,{"data-id":"image-container",children:ge.jsx(wf,{viewType:n,children:ge.jsx(en,{name:"add"})})}),ge.jsx(yf,{sx:{height:"100%"},children:ge.jsx(Up,{title:o,maxLines:2,sx:{height:"100%"}})})]})})},exports.Radio=ph,exports.RadioGroup=Eh,exports.Rank=cm,exports.RichTextField=dm,exports.SectionHeader=({buttons:e,subtitle:n,title:o})=>ge.jsx(ge.Fragment,{children:ge.jsx(kf,{sx:{justifyContent:"space-between"},children:ge.jsx(t.Container,{children:ge.jsx(t.Unstable_Grid2,{container:!0,spacing:2,children:ge.jsx(t.Unstable_Grid2,{sm:!0,children:ge.jsxs(Mf,{sx:{justifyContent:"space-between",py:1},children:[ge.jsx(Mf,{children:ge.jsxs(Mf,{sx:{alignItems:"flex-start",flexDirection:"column",gap:0},children:[o&&ge.jsx(dn,{variation:"sm",component:"h2",weight:"bold",children:o}),n&&ge.jsx(Tf,{variation:"sm",component:"p",children:n})]})}),e&&ge.jsx(Mf,{children:e})]})})})})})}),exports.Select=Yh,exports.Slider=vm,exports.SortableList=lm,exports.StarRating=bm,exports.Surface=an,exports.Switch=jm,exports.TextBarDivider=({typographyProps:e,text:o,sx:i})=>{const r=t.useTheme();return ge.jsx(t.Box,{sx:n.mergeSx(i,{width:"100%",position:"relative",display:"flex",gap:4,my:r.spacing(r.custom.margin.md),"&:before":{content:'""',width:"100%",background:r.custom.palette.stroke.default,height:"1px",display:"flex",alignSelf:"center"},"&:after":{content:'""',width:"100%",background:r.custom.palette.stroke.default,height:"1px",display:"flex",alignSelf:"center"}}),children:ge.jsx(dn,{align:"center",variation:"sm",component:"p",...e,children:o})})},exports.TextField=oh,exports.Textarea=Sm,exports.ThemeProvider=({mode:e="light",screenSize:n="lg",direction:o="ltr",children:i})=>{const r=Rf(e,n,o);return ge.jsx(If.Provider,{value:r,children:ge.jsx(M.CacheProvider,{value:"rtl"===o?Vf:Ff,children:ge.jsxs(s.ThemeProvider,{theme:r.theme,children:[ge.jsx(t.CssBaseline,{}),ge.jsx(zf,{}),i]})})})},exports.TickGroup=({heading:e,ticks:n})=>ge.jsxs(t.Stack,{sx:{display:"flex",gap:{sm:2,lg:4},py:{sm:2,lg:4}},children:[ge.jsx(dn,{variation:"xl",component:"p",sx:{textAlign:"center"},children:e}),ge.jsx(t.Box,{sx:{columnGap:4,display:"flex",flex:1,flexWrap:"wrap",justifyContent:"center",rowGap:2},children:n.map(((n,o)=>ge.jsxs(t.Box,{sx:{display:"flex",alignItems:"center",gap:1,px:{sm:0,lg:2}},children:[ge.jsx(en,{name:"badge-tick",size:32}),ge.jsx(dn,{variation:"xxl",component:"p",children:n})]},`tick-group-${e}-${o}`)))})]}),exports.Toast=({buttons:e,message:n,status:o="neutral",variation:i="sm"})=>{const r=t.useTheme();return ge.jsx(t.Stack,{sx:{backgroundColor:r.custom.palette.surface.overlay,borderRadius:r.spacing(r.custom.radius.lg),boxShadow:r.custom.elevation.overlay,color:r.custom.palette.text.primaryInverted,display:"flex",flex:1,gap:1,p:2},children:ge.jsxs(t.Box,{sx:{display:"flex",flex:1,flexDirection:"sm"===i?"row":"column",gap:2},children:[ge.jsxs(t.Box,{sx:{display:"flex",flex:1,gap:1},children:["neutral"!==o&&ge.jsx(hf,{status:o}),ge.jsx(t.Box,{sx:{display:"flex"},children:ge.jsx(dn,{variation:"md",component:"p",sx:{px:1,pt:.5},children:n})})]}),e&&ge.jsx(t.Box,{sx:{alignItems:"center",display:"flex",gap:2,justifyContent:"flex-end"},children:e})]})})},exports.Tooltip=yn,exports.Typography=dn,exports.UserMenu=Io,exports.backgroundCreator=Xp,exports.base=Q,exports.blue=H,exports.blueRamp=Z,exports.boxShadow=re,exports.breakpoints=X,exports.chooseArticle=Gp,exports.compareArrayMembers=function(e,t){const n=new Set(e),o=new Set(t);return e.every((e=>o.has(e)))&&t.every((e=>n.has(e)))},exports.darkNeutral=R,exports.darkNeutralAlpha=F,exports.defaultInputValidation=qp,exports.easing=se,exports.elevation=oe,exports.elevationFilter=ie,exports.emailValidation={pattern:{value:/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,30}$/i,message:"Please enter a valid email"}},exports.fonts=ce,exports.generateRamp=_,exports.green=W,exports.greenRamp=Y,exports.iconSizeMap=Qt,exports.margin=ee,exports.neutral=I,exports.neutralAlpha=V,exports.neutralRamp=N,exports.padding=te,exports.passwordValidation=e=>({minLength:{value:e||8,message:`Password must have at least ${e||8} characters`},equal:{value:"password",message:"You cannot choose 'password' as your password"}}),exports.peach=O,exports.peachRamp=q,exports.purple=L,exports.purpleRamp=U,exports.radius=ne,exports.red=D,exports.redRamp=G,exports.semantic=ae,exports.space=J,exports.useBreakpoint=Wo,exports.useDropdownMenu=()=>{const[t,n]=e.useState(null);return{open:Boolean(t),handleClick:e=>{n(e.currentTarget)},handleClose:()=>{n(null)},anchorEl:t}},exports.usePrevious=vh,exports.useScreenSize=Af,exports.yellow=$,exports.yellowRamp=K;