(function(){"use strict";function Pd(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}var bo={exports:{}},Ja={};/**
 * @license React
 * react-jsx-runtime.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var iu;function em(){if(iu)return Ja;iu=1;var c=Symbol.for("react.transitional.element"),o=Symbol.for("react.fragment");function r(u,f,m){var y=null;if(m!==void 0&&(y=""+m),f.key!==void 0&&(y=""+f.key),"key"in f){m={};for(var S in f)S!=="key"&&(m[S]=f[S])}else m=f;return f=m.ref,{$$typeof:c,type:u,key:y,ref:f!==void 0?f:null,props:m}}return Ja.Fragment=o,Ja.jsx=r,Ja.jsxs=r,Ja}var ou;function tm(){return ou||(ou=1,bo.exports=em()),bo.exports}var _=tm(),xo={exports:{}},ce={};/**
 * @license React
 * react.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var cu;function lm(){if(cu)return ce;cu=1;var c=Symbol.for("react.transitional.element"),o=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),m=Symbol.for("react.consumer"),y=Symbol.for("react.context"),S=Symbol.for("react.forward_ref"),x=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),A=Symbol.for("react.lazy"),C=Symbol.for("react.activity"),Y=Symbol.iterator;function R(b){return b===null||typeof b!="object"?null:(b=Y&&b[Y]||b["@@iterator"],typeof b=="function"?b:null)}var L={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},G=Object.assign,Z={};function q(b,B,V){this.props=b,this.context=B,this.refs=Z,this.updater=V||L}q.prototype.isReactComponent={},q.prototype.setState=function(b,B){if(typeof b!="object"&&typeof b!="function"&&b!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,b,B,"setState")},q.prototype.forceUpdate=function(b){this.updater.enqueueForceUpdate(this,b,"forceUpdate")};function X(){}X.prototype=q.prototype;function j(b,B,V){this.props=b,this.context=B,this.refs=Z,this.updater=V||L}var F=j.prototype=new X;F.constructor=j,G(F,q.prototype),F.isPureReactComponent=!0;var ae=Array.isArray;function ne(){}var K={H:null,A:null,T:null,S:null},se=Object.prototype.hasOwnProperty;function Ee(b,B,V){var W=V.ref;return{$$typeof:c,type:b,key:B,ref:W!==void 0?W:null,props:V}}function $(b,B){return Ee(b.type,B,b.props)}function _e(b){return typeof b=="object"&&b!==null&&b.$$typeof===c}function ve(b){var B={"=":"=0",":":"=2"};return"$"+b.replace(/[=:]/g,function(V){return B[V]})}var ke=/\/+/g;function le(b,B){return typeof b=="object"&&b!==null&&b.key!=null?ve(""+b.key):B.toString(36)}function oe(b){switch(b.status){case"fulfilled":return b.value;case"rejected":throw b.reason;default:switch(typeof b.status=="string"?b.then(ne,ne):(b.status="pending",b.then(function(B){b.status==="pending"&&(b.status="fulfilled",b.value=B)},function(B){b.status==="pending"&&(b.status="rejected",b.reason=B)})),b.status){case"fulfilled":return b.value;case"rejected":throw b.reason}}throw b}function M(b,B,V,W,ue){var me=typeof b;(me==="undefined"||me==="boolean")&&(b=null);var ze=!1;if(b===null)ze=!0;else switch(me){case"bigint":case"string":case"number":ze=!0;break;case"object":switch(b.$$typeof){case c:case o:ze=!0;break;case A:return ze=b._init,M(ze(b._payload),B,V,W,ue)}}if(ze)return ue=ue(b),ze=W===""?"."+le(b,0):W,ae(ue)?(V="",ze!=null&&(V=ze.replace(ke,"$&/")+"/"),M(ue,B,V,"",function(Fa){return Fa})):ue!=null&&(_e(ue)&&(ue=$(ue,V+(ue.key==null||b&&b.key===ue.key?"":(""+ue.key).replace(ke,"$&/")+"/")+ze)),B.push(ue)),1;ze=0;var ut=W===""?".":W+":";if(ae(b))for(var Ze=0;Ze<b.length;Ze++)W=b[Ze],me=ut+le(W,Ze),ze+=M(W,B,V,me,ue);else if(Ze=R(b),typeof Ze=="function")for(b=Ze.call(b),Ze=0;!(W=b.next()).done;)W=W.value,me=ut+le(W,Ze++),ze+=M(W,B,V,me,ue);else if(me==="object"){if(typeof b.then=="function")return M(oe(b),B,V,W,ue);throw B=String(b),Error("Objects are not valid as a React child (found: "+(B==="[object Object]"?"object with keys {"+Object.keys(b).join(", ")+"}":B)+"). If you meant to render a collection of children, use an array instead.")}return ze}function U(b,B,V){if(b==null)return b;var W=[],ue=0;return M(b,W,"","",function(me){return B.call(V,me,ue++)}),W}function ee(b){if(b._status===-1){var B=b._result;B=B(),B.then(function(V){(b._status===0||b._status===-1)&&(b._status=1,b._result=V)},function(V){(b._status===0||b._status===-1)&&(b._status=2,b._result=V)}),b._status===-1&&(b._status=0,b._result=B)}if(b._status===1)return b._result.default;throw b._result}var Te=typeof reportError=="function"?reportError:function(b){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var B=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof b=="object"&&b!==null&&typeof b.message=="string"?String(b.message):String(b),error:b});if(!window.dispatchEvent(B))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",b);return}console.error(b)},Ce={map:U,forEach:function(b,B,V){U(b,function(){B.apply(this,arguments)},V)},count:function(b){var B=0;return U(b,function(){B++}),B},toArray:function(b){return U(b,function(B){return B})||[]},only:function(b){if(!_e(b))throw Error("React.Children.only expected to receive a single React element child.");return b}};return ce.Activity=C,ce.Children=Ce,ce.Component=q,ce.Fragment=r,ce.Profiler=f,ce.PureComponent=j,ce.StrictMode=u,ce.Suspense=x,ce.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=K,ce.__COMPILER_RUNTIME={__proto__:null,c:function(b){return K.H.useMemoCache(b)}},ce.cache=function(b){return function(){return b.apply(null,arguments)}},ce.cacheSignal=function(){return null},ce.cloneElement=function(b,B,V){if(b==null)throw Error("The argument must be a React element, but you passed "+b+".");var W=G({},b.props),ue=b.key;if(B!=null)for(me in B.key!==void 0&&(ue=""+B.key),B)!se.call(B,me)||me==="key"||me==="__self"||me==="__source"||me==="ref"&&B.ref===void 0||(W[me]=B[me]);var me=arguments.length-2;if(me===1)W.children=V;else if(1<me){for(var ze=Array(me),ut=0;ut<me;ut++)ze[ut]=arguments[ut+2];W.children=ze}return Ee(b.type,ue,W)},ce.createContext=function(b){return b={$$typeof:y,_currentValue:b,_currentValue2:b,_threadCount:0,Provider:null,Consumer:null},b.Provider=b,b.Consumer={$$typeof:m,_context:b},b},ce.createElement=function(b,B,V){var W,ue={},me=null;if(B!=null)for(W in B.key!==void 0&&(me=""+B.key),B)se.call(B,W)&&W!=="key"&&W!=="__self"&&W!=="__source"&&(ue[W]=B[W]);var ze=arguments.length-2;if(ze===1)ue.children=V;else if(1<ze){for(var ut=Array(ze),Ze=0;Ze<ze;Ze++)ut[Ze]=arguments[Ze+2];ue.children=ut}if(b&&b.defaultProps)for(W in ze=b.defaultProps,ze)ue[W]===void 0&&(ue[W]=ze[W]);return Ee(b,me,ue)},ce.createRef=function(){return{current:null}},ce.forwardRef=function(b){return{$$typeof:S,render:b}},ce.isValidElement=_e,ce.lazy=function(b){return{$$typeof:A,_payload:{_status:-1,_result:b},_init:ee}},ce.memo=function(b,B){return{$$typeof:h,type:b,compare:B===void 0?null:B}},ce.startTransition=function(b){var B=K.T,V={};K.T=V;try{var W=b(),ue=K.S;ue!==null&&ue(V,W),typeof W=="object"&&W!==null&&typeof W.then=="function"&&W.then(ne,Te)}catch(me){Te(me)}finally{B!==null&&V.types!==null&&(B.types=V.types),K.T=B}},ce.unstable_useCacheRefresh=function(){return K.H.useCacheRefresh()},ce.use=function(b){return K.H.use(b)},ce.useActionState=function(b,B,V){return K.H.useActionState(b,B,V)},ce.useCallback=function(b,B){return K.H.useCallback(b,B)},ce.useContext=function(b){return K.H.useContext(b)},ce.useDebugValue=function(){},ce.useDeferredValue=function(b,B){return K.H.useDeferredValue(b,B)},ce.useEffect=function(b,B){return K.H.useEffect(b,B)},ce.useEffectEvent=function(b){return K.H.useEffectEvent(b)},ce.useId=function(){return K.H.useId()},ce.useImperativeHandle=function(b,B,V){return K.H.useImperativeHandle(b,B,V)},ce.useInsertionEffect=function(b,B){return K.H.useInsertionEffect(b,B)},ce.useLayoutEffect=function(b,B){return K.H.useLayoutEffect(b,B)},ce.useMemo=function(b,B){return K.H.useMemo(b,B)},ce.useOptimistic=function(b,B){return K.H.useOptimistic(b,B)},ce.useReducer=function(b,B,V){return K.H.useReducer(b,B,V)},ce.useRef=function(b){return K.H.useRef(b)},ce.useState=function(b){return K.H.useState(b)},ce.useSyncExternalStore=function(b,B,V){return K.H.useSyncExternalStore(b,B,V)},ce.useTransition=function(){return K.H.useTransition()},ce.version="19.2.7",ce}var su;function So(){return su||(su=1,xo.exports=lm()),xo.exports}var g=So();const Qn=Pd(g);var wo={exports:{}},$a={},Eo={exports:{}},To={};/**
 * @license React
 * scheduler.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var uu;function am(){return uu||(uu=1,(function(c){function o(M,U){var ee=M.length;M.push(U);e:for(;0<ee;){var Te=ee-1>>>1,Ce=M[Te];if(0<f(Ce,U))M[Te]=U,M[ee]=Ce,ee=Te;else break e}}function r(M){return M.length===0?null:M[0]}function u(M){if(M.length===0)return null;var U=M[0],ee=M.pop();if(ee!==U){M[0]=ee;e:for(var Te=0,Ce=M.length,b=Ce>>>1;Te<b;){var B=2*(Te+1)-1,V=M[B],W=B+1,ue=M[W];if(0>f(V,ee))W<Ce&&0>f(ue,V)?(M[Te]=ue,M[W]=ee,Te=W):(M[Te]=V,M[B]=ee,Te=B);else if(W<Ce&&0>f(ue,ee))M[Te]=ue,M[W]=ee,Te=W;else break e}}return U}function f(M,U){var ee=M.sortIndex-U.sortIndex;return ee!==0?ee:M.id-U.id}if(c.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var m=performance;c.unstable_now=function(){return m.now()}}else{var y=Date,S=y.now();c.unstable_now=function(){return y.now()-S}}var x=[],h=[],A=1,C=null,Y=3,R=!1,L=!1,G=!1,Z=!1,q=typeof setTimeout=="function"?setTimeout:null,X=typeof clearTimeout=="function"?clearTimeout:null,j=typeof setImmediate<"u"?setImmediate:null;function F(M){for(var U=r(h);U!==null;){if(U.callback===null)u(h);else if(U.startTime<=M)u(h),U.sortIndex=U.expirationTime,o(x,U);else break;U=r(h)}}function ae(M){if(G=!1,F(M),!L)if(r(x)!==null)L=!0,ne||(ne=!0,ve());else{var U=r(h);U!==null&&oe(ae,U.startTime-M)}}var ne=!1,K=-1,se=5,Ee=-1;function $(){return Z?!0:!(c.unstable_now()-Ee<se)}function _e(){if(Z=!1,ne){var M=c.unstable_now();Ee=M;var U=!0;try{e:{L=!1,G&&(G=!1,X(K),K=-1),R=!0;var ee=Y;try{t:{for(F(M),C=r(x);C!==null&&!(C.expirationTime>M&&$());){var Te=C.callback;if(typeof Te=="function"){C.callback=null,Y=C.priorityLevel;var Ce=Te(C.expirationTime<=M);if(M=c.unstable_now(),typeof Ce=="function"){C.callback=Ce,F(M),U=!0;break t}C===r(x)&&u(x),F(M)}else u(x);C=r(x)}if(C!==null)U=!0;else{var b=r(h);b!==null&&oe(ae,b.startTime-M),U=!1}}break e}finally{C=null,Y=ee,R=!1}U=void 0}}finally{U?ve():ne=!1}}}var ve;if(typeof j=="function")ve=function(){j(_e)};else if(typeof MessageChannel<"u"){var ke=new MessageChannel,le=ke.port2;ke.port1.onmessage=_e,ve=function(){le.postMessage(null)}}else ve=function(){q(_e,0)};function oe(M,U){K=q(function(){M(c.unstable_now())},U)}c.unstable_IdlePriority=5,c.unstable_ImmediatePriority=1,c.unstable_LowPriority=4,c.unstable_NormalPriority=3,c.unstable_Profiling=null,c.unstable_UserBlockingPriority=2,c.unstable_cancelCallback=function(M){M.callback=null},c.unstable_forceFrameRate=function(M){0>M||125<M?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):se=0<M?Math.floor(1e3/M):5},c.unstable_getCurrentPriorityLevel=function(){return Y},c.unstable_next=function(M){switch(Y){case 1:case 2:case 3:var U=3;break;default:U=Y}var ee=Y;Y=U;try{return M()}finally{Y=ee}},c.unstable_requestPaint=function(){Z=!0},c.unstable_runWithPriority=function(M,U){switch(M){case 1:case 2:case 3:case 4:case 5:break;default:M=3}var ee=Y;Y=M;try{return U()}finally{Y=ee}},c.unstable_scheduleCallback=function(M,U,ee){var Te=c.unstable_now();switch(typeof ee=="object"&&ee!==null?(ee=ee.delay,ee=typeof ee=="number"&&0<ee?Te+ee:Te):ee=Te,M){case 1:var Ce=-1;break;case 2:Ce=250;break;case 5:Ce=1073741823;break;case 4:Ce=1e4;break;default:Ce=5e3}return Ce=ee+Ce,M={id:A++,callback:U,priorityLevel:M,startTime:ee,expirationTime:Ce,sortIndex:-1},ee>Te?(M.sortIndex=ee,o(h,M),r(x)===null&&M===r(h)&&(G?(X(K),K=-1):G=!0,oe(ae,ee-Te))):(M.sortIndex=Ce,o(x,M),L||R||(L=!0,ne||(ne=!0,ve()))),M},c.unstable_shouldYield=$,c.unstable_wrapCallback=function(M){var U=Y;return function(){var ee=Y;Y=U;try{return M.apply(this,arguments)}finally{Y=ee}}}})(To)),To}var ru;function nm(){return ru||(ru=1,Eo.exports=am()),Eo.exports}var No={exports:{}},st={};/**
 * @license React
 * react-dom.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var _u;function im(){if(_u)return st;_u=1;var c=So();function o(x){var h="https://react.dev/errors/"+x;if(1<arguments.length){h+="?args[]="+encodeURIComponent(arguments[1]);for(var A=2;A<arguments.length;A++)h+="&args[]="+encodeURIComponent(arguments[A])}return"Minified React error #"+x+"; visit "+h+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function r(){}var u={d:{f:r,r:function(){throw Error(o(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},f=Symbol.for("react.portal");function m(x,h,A){var C=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:f,key:C==null?null:""+C,children:x,containerInfo:h,implementation:A}}var y=c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function S(x,h){if(x==="font")return"";if(typeof h=="string")return h==="use-credentials"?h:""}return st.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=u,st.createPortal=function(x,h){var A=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!h||h.nodeType!==1&&h.nodeType!==9&&h.nodeType!==11)throw Error(o(299));return m(x,h,null,A)},st.flushSync=function(x){var h=y.T,A=u.p;try{if(y.T=null,u.p=2,x)return x()}finally{y.T=h,u.p=A,u.d.f()}},st.preconnect=function(x,h){typeof x=="string"&&(h?(h=h.crossOrigin,h=typeof h=="string"?h==="use-credentials"?h:"":void 0):h=null,u.d.C(x,h))},st.prefetchDNS=function(x){typeof x=="string"&&u.d.D(x)},st.preinit=function(x,h){if(typeof x=="string"&&h&&typeof h.as=="string"){var A=h.as,C=S(A,h.crossOrigin),Y=typeof h.integrity=="string"?h.integrity:void 0,R=typeof h.fetchPriority=="string"?h.fetchPriority:void 0;A==="style"?u.d.S(x,typeof h.precedence=="string"?h.precedence:void 0,{crossOrigin:C,integrity:Y,fetchPriority:R}):A==="script"&&u.d.X(x,{crossOrigin:C,integrity:Y,fetchPriority:R,nonce:typeof h.nonce=="string"?h.nonce:void 0})}},st.preinitModule=function(x,h){if(typeof x=="string")if(typeof h=="object"&&h!==null){if(h.as==null||h.as==="script"){var A=S(h.as,h.crossOrigin);u.d.M(x,{crossOrigin:A,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0})}}else h==null&&u.d.M(x)},st.preload=function(x,h){if(typeof x=="string"&&typeof h=="object"&&h!==null&&typeof h.as=="string"){var A=h.as,C=S(A,h.crossOrigin);u.d.L(x,A,{crossOrigin:C,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0,type:typeof h.type=="string"?h.type:void 0,fetchPriority:typeof h.fetchPriority=="string"?h.fetchPriority:void 0,referrerPolicy:typeof h.referrerPolicy=="string"?h.referrerPolicy:void 0,imageSrcSet:typeof h.imageSrcSet=="string"?h.imageSrcSet:void 0,imageSizes:typeof h.imageSizes=="string"?h.imageSizes:void 0,media:typeof h.media=="string"?h.media:void 0})}},st.preloadModule=function(x,h){if(typeof x=="string")if(h){var A=S(h.as,h.crossOrigin);u.d.m(x,{as:typeof h.as=="string"&&h.as!=="script"?h.as:void 0,crossOrigin:A,integrity:typeof h.integrity=="string"?h.integrity:void 0})}else u.d.m(x)},st.requestFormReset=function(x){u.d.r(x)},st.unstable_batchedUpdates=function(x,h){return x(h)},st.useFormState=function(x,h,A){return y.H.useFormState(x,h,A)},st.useFormStatus=function(){return y.H.useHostTransitionStatus()},st.version="19.2.7",st}var fu;function om(){if(fu)return No.exports;fu=1;function c(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(c)}catch(o){console.error(o)}}return c(),No.exports=im(),No.exports}/**
 * @license React
 * react-dom-client.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var du;function cm(){if(du)return $a;du=1;var c=nm(),o=So(),r=om();function u(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)t+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function f(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function m(e){var t=e,l=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(l=t.return),e=t.return;while(e)}return t.tag===3?l:null}function y(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function S(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function x(e){if(m(e)!==e)throw Error(u(188))}function h(e){var t=e.alternate;if(!t){if(t=m(e),t===null)throw Error(u(188));return t!==e?null:e}for(var l=e,a=t;;){var n=l.return;if(n===null)break;var i=n.alternate;if(i===null){if(a=n.return,a!==null){l=a;continue}break}if(n.child===i.child){for(i=n.child;i;){if(i===l)return x(n),e;if(i===a)return x(n),t;i=i.sibling}throw Error(u(188))}if(l.return!==a.return)l=n,a=i;else{for(var s=!1,d=n.child;d;){if(d===l){s=!0,l=n,a=i;break}if(d===a){s=!0,a=n,l=i;break}d=d.sibling}if(!s){for(d=i.child;d;){if(d===l){s=!0,l=i,a=n;break}if(d===a){s=!0,a=i,l=n;break}d=d.sibling}if(!s)throw Error(u(189))}}if(l.alternate!==a)throw Error(u(190))}if(l.tag!==3)throw Error(u(188));return l.stateNode.current===l?e:t}function A(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=A(e),t!==null)return t;e=e.sibling}return null}var C=Object.assign,Y=Symbol.for("react.element"),R=Symbol.for("react.transitional.element"),L=Symbol.for("react.portal"),G=Symbol.for("react.fragment"),Z=Symbol.for("react.strict_mode"),q=Symbol.for("react.profiler"),X=Symbol.for("react.consumer"),j=Symbol.for("react.context"),F=Symbol.for("react.forward_ref"),ae=Symbol.for("react.suspense"),ne=Symbol.for("react.suspense_list"),K=Symbol.for("react.memo"),se=Symbol.for("react.lazy"),Ee=Symbol.for("react.activity"),$=Symbol.for("react.memo_cache_sentinel"),_e=Symbol.iterator;function ve(e){return e===null||typeof e!="object"?null:(e=_e&&e[_e]||e["@@iterator"],typeof e=="function"?e:null)}var ke=Symbol.for("react.client.reference");function le(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===ke?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case G:return"Fragment";case q:return"Profiler";case Z:return"StrictMode";case ae:return"Suspense";case ne:return"SuspenseList";case Ee:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case L:return"Portal";case j:return e.displayName||"Context";case X:return(e._context.displayName||"Context")+".Consumer";case F:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case K:return t=e.displayName||null,t!==null?t:le(e.type)||"Memo";case se:t=e._payload,e=e._init;try{return le(e(t))}catch{}}return null}var oe=Array.isArray,M=o.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,U=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ee={pending:!1,data:null,method:null,action:null},Te=[],Ce=-1;function b(e){return{current:e}}function B(e){0>Ce||(e.current=Te[Ce],Te[Ce]=null,Ce--)}function V(e,t){Ce++,Te[Ce]=e.current,e.current=t}var W=b(null),ue=b(null),me=b(null),ze=b(null);function ut(e,t){switch(V(me,t),V(ue,e),V(W,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Sd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Sd(t),e=wd(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}B(W),V(W,e)}function Ze(){B(W),B(ue),B(me)}function Fa(e){e.memoizedState!==null&&V(ze,e);var t=W.current,l=wd(t,e.type);t!==l&&(V(ue,e),V(W,l))}function ti(e){ue.current===e&&(B(W),B(ue)),ze.current===e&&(B(ze),Yn._currentValue=ee)}var Yo,Fu;function Yl(e){if(Yo===void 0)try{throw Error()}catch(l){var t=l.stack.trim().match(/\n( *(at )?)/);Yo=t&&t[1]||"",Fu=-1<l.stack.indexOf(`
    at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
`+Yo+e+Fu}var Go=!1;function Xo(e,t){if(!e||Go)return"";Go=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var a={DetermineComponentFrameRoot:function(){try{if(t){var O=function(){throw Error()};if(Object.defineProperty(O.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(O,[])}catch(z){var N=z}Reflect.construct(e,[],O)}else{try{O.call()}catch(z){N=z}e.call(O.prototype)}}else{try{throw Error()}catch(z){N=z}(O=e())&&typeof O.catch=="function"&&O.catch(function(){})}}catch(z){if(z&&N&&typeof z.stack=="string")return[z.stack,N.stack]}return[null,null]}};a.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var n=Object.getOwnPropertyDescriptor(a.DetermineComponentFrameRoot,"name");n&&n.configurable&&Object.defineProperty(a.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=a.DetermineComponentFrameRoot(),s=i[0],d=i[1];if(s&&d){var p=s.split(`
`),T=d.split(`
`);for(n=a=0;a<p.length&&!p[a].includes("DetermineComponentFrameRoot");)a++;for(;n<T.length&&!T[n].includes("DetermineComponentFrameRoot");)n++;if(a===p.length||n===T.length)for(a=p.length-1,n=T.length-1;1<=a&&0<=n&&p[a]!==T[n];)n--;for(;1<=a&&0<=n;a--,n--)if(p[a]!==T[n]){if(a!==1||n!==1)do if(a--,n--,0>n||p[a]!==T[n]){var H=`
`+p[a].replace(" at new "," at ");return e.displayName&&H.includes("<anonymous>")&&(H=H.replace("<anonymous>",e.displayName)),H}while(1<=a&&0<=n);break}}}finally{Go=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Yl(l):""}function xp(e,t){switch(e.tag){case 26:case 27:case 5:return Yl(e.type);case 16:return Yl("Lazy");case 13:return e.child!==t&&t!==null?Yl("Suspense Fallback"):Yl("Suspense");case 19:return Yl("SuspenseList");case 0:case 15:return Xo(e.type,!1);case 11:return Xo(e.type.render,!1);case 1:return Xo(e.type,!0);case 31:return Yl("Activity");default:return""}}function Iu(e){try{var t="",l=null;do t+=xp(e,l),l=e,e=e.return;while(e);return t}catch(a){return`
Error generating stack: `+a.message+`
`+a.stack}}var Vo=Object.prototype.hasOwnProperty,Qo=c.unstable_scheduleCallback,Zo=c.unstable_cancelCallback,Sp=c.unstable_shouldYield,wp=c.unstable_requestPaint,vt=c.unstable_now,Ep=c.unstable_getCurrentPriorityLevel,Pu=c.unstable_ImmediatePriority,er=c.unstable_UserBlockingPriority,li=c.unstable_NormalPriority,Tp=c.unstable_LowPriority,tr=c.unstable_IdlePriority,Np=c.log,jp=c.unstable_setDisableYieldValue,Ia=null,bt=null;function dl(e){if(typeof Np=="function"&&jp(e),bt&&typeof bt.setStrictMode=="function")try{bt.setStrictMode(Ia,e)}catch{}}var xt=Math.clz32?Math.clz32:Mp,Cp=Math.log,zp=Math.LN2;function Mp(e){return e>>>=0,e===0?32:31-(Cp(e)/zp|0)|0}var ai=256,ni=262144,ii=4194304;function Gl(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function oi(e,t,l){var a=e.pendingLanes;if(a===0)return 0;var n=0,i=e.suspendedLanes,s=e.pingedLanes;e=e.warmLanes;var d=a&134217727;return d!==0?(a=d&~i,a!==0?n=Gl(a):(s&=d,s!==0?n=Gl(s):l||(l=d&~e,l!==0&&(n=Gl(l))))):(d=a&~i,d!==0?n=Gl(d):s!==0?n=Gl(s):l||(l=a&~e,l!==0&&(n=Gl(l)))),n===0?0:t!==0&&t!==n&&(t&i)===0&&(i=n&-n,l=t&-t,i>=l||i===32&&(l&4194048)!==0)?t:n}function Pa(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ap(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function lr(){var e=ii;return ii<<=1,(ii&62914560)===0&&(ii=4194304),e}function Ko(e){for(var t=[],l=0;31>l;l++)t.push(e);return t}function en(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Hp(e,t,l,a,n,i){var s=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var d=e.entanglements,p=e.expirationTimes,T=e.hiddenUpdates;for(l=s&~l;0<l;){var H=31-xt(l),O=1<<H;d[H]=0,p[H]=-1;var N=T[H];if(N!==null)for(T[H]=null,H=0;H<N.length;H++){var z=N[H];z!==null&&(z.lane&=-536870913)}l&=~O}a!==0&&ar(e,a,0),i!==0&&n===0&&e.tag!==0&&(e.suspendedLanes|=i&~(s&~t))}function ar(e,t,l){e.pendingLanes|=t,e.suspendedLanes&=~t;var a=31-xt(t);e.entangledLanes|=t,e.entanglements[a]=e.entanglements[a]|1073741824|l&261930}function nr(e,t){var l=e.entangledLanes|=t;for(e=e.entanglements;l;){var a=31-xt(l),n=1<<a;n&t|e[a]&t&&(e[a]|=t),l&=~n}}function ir(e,t){var l=t&-t;return l=(l&42)!==0?1:Jo(l),(l&(e.suspendedLanes|t))!==0?0:l}function Jo(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function $o(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function or(){var e=U.p;return e!==0?e:(e=window.event,e===void 0?32:Zd(e.type))}function cr(e,t){var l=U.p;try{return U.p=e,t()}finally{U.p=l}}var ml=Math.random().toString(36).slice(2),at="__reactFiber$"+ml,ft="__reactProps$"+ml,ra="__reactContainer$"+ml,Wo="__reactEvents$"+ml,Dp="__reactListeners$"+ml,Op="__reactHandles$"+ml,sr="__reactResources$"+ml,tn="__reactMarker$"+ml;function Fo(e){delete e[at],delete e[ft],delete e[Wo],delete e[Dp],delete e[Op]}function _a(e){var t=e[at];if(t)return t;for(var l=e.parentNode;l;){if(t=l[ra]||l[at]){if(l=t.alternate,t.child!==null||l!==null&&l.child!==null)for(e=Md(e);e!==null;){if(l=e[at])return l;e=Md(e)}return t}e=l,l=e.parentNode}return null}function fa(e){if(e=e[at]||e[ra]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ln(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(u(33))}function da(e){var t=e[sr];return t||(t=e[sr]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function tt(e){e[tn]=!0}var ur=new Set,rr={};function Xl(e,t){ma(e,t),ma(e+"Capture",t)}function ma(e,t){for(rr[e]=t,e=0;e<t.length;e++)ur.add(t[e])}var Rp=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),_r={},fr={};function Up(e){return Vo.call(fr,e)?!0:Vo.call(_r,e)?!1:Rp.test(e)?fr[e]=!0:(_r[e]=!0,!1)}function ci(e,t,l){if(Up(t))if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var a=t.toLowerCase().slice(0,5);if(a!=="data-"&&a!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+l)}}function si(e,t,l){if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+l)}}function $t(e,t,l,a){if(a===null)e.removeAttribute(l);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(t,l,""+a)}}function zt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function dr(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Lp(e,t,l){var a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var n=a.get,i=a.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return n.call(this)},set:function(s){l=""+s,i.call(this,s)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return l},setValue:function(s){l=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Io(e){if(!e._valueTracker){var t=dr(e)?"checked":"value";e._valueTracker=Lp(e,t,""+e[t])}}function mr(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var l=t.getValue(),a="";return e&&(a=dr(e)?e.checked?"true":"false":e.value),e=a,e!==l?(t.setValue(e),!0):!1}function ui(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var Bp=/[\n"\\]/g;function Mt(e){return e.replace(Bp,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Po(e,t,l,a,n,i,s,d){e.name="",s!=null&&typeof s!="function"&&typeof s!="symbol"&&typeof s!="boolean"?e.type=s:e.removeAttribute("type"),t!=null?s==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+zt(t)):e.value!==""+zt(t)&&(e.value=""+zt(t)):s!=="submit"&&s!=="reset"||e.removeAttribute("value"),t!=null?ec(e,s,zt(t)):l!=null?ec(e,s,zt(l)):a!=null&&e.removeAttribute("value"),n==null&&i!=null&&(e.defaultChecked=!!i),n!=null&&(e.checked=n&&typeof n!="function"&&typeof n!="symbol"),d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"?e.name=""+zt(d):e.removeAttribute("name")}function hr(e,t,l,a,n,i,s,d){if(i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(e.type=i),t!=null||l!=null){if(!(i!=="submit"&&i!=="reset"||t!=null)){Io(e);return}l=l!=null?""+zt(l):"",t=t!=null?""+zt(t):l,d||t===e.value||(e.value=t),e.defaultValue=t}a=a??n,a=typeof a!="function"&&typeof a!="symbol"&&!!a,e.checked=d?e.checked:!!a,e.defaultChecked=!!a,s!=null&&typeof s!="function"&&typeof s!="symbol"&&typeof s!="boolean"&&(e.name=s),Io(e)}function ec(e,t,l){t==="number"&&ui(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function ha(e,t,l,a){if(e=e.options,t){t={};for(var n=0;n<l.length;n++)t["$"+l[n]]=!0;for(l=0;l<e.length;l++)n=t.hasOwnProperty("$"+e[l].value),e[l].selected!==n&&(e[l].selected=n),n&&a&&(e[l].defaultSelected=!0)}else{for(l=""+zt(l),t=null,n=0;n<e.length;n++){if(e[n].value===l){e[n].selected=!0,a&&(e[n].defaultSelected=!0);return}t!==null||e[n].disabled||(t=e[n])}t!==null&&(t.selected=!0)}}function pr(e,t,l){if(t!=null&&(t=""+zt(t),t!==e.value&&(e.value=t),l==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=l!=null?""+zt(l):""}function yr(e,t,l,a){if(t==null){if(a!=null){if(l!=null)throw Error(u(92));if(oe(a)){if(1<a.length)throw Error(u(93));a=a[0]}l=a}l==null&&(l=""),t=l}l=zt(t),e.defaultValue=l,a=e.textContent,a===l&&a!==""&&a!==null&&(e.value=a),Io(e)}function pa(e,t){if(t){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=t;return}}e.textContent=t}var kp=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function gr(e,t,l){var a=t.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?a?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":a?e.setProperty(t,l):typeof l!="number"||l===0||kp.has(t)?t==="float"?e.cssFloat=l:e[t]=(""+l).trim():e[t]=l+"px"}function vr(e,t,l){if(t!=null&&typeof t!="object")throw Error(u(62));if(e=e.style,l!=null){for(var a in l)!l.hasOwnProperty(a)||t!=null&&t.hasOwnProperty(a)||(a.indexOf("--")===0?e.setProperty(a,""):a==="float"?e.cssFloat="":e[a]="");for(var n in t)a=t[n],t.hasOwnProperty(n)&&l[n]!==a&&gr(e,n,a)}else for(var i in t)t.hasOwnProperty(i)&&gr(e,i,t[i])}function tc(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var qp=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Yp=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function ri(e){return Yp.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Wt(){}var lc=null;function ac(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ya=null,ga=null;function br(e){var t=fa(e);if(t&&(e=t.stateNode)){var l=e[ft]||null;e:switch(e=t.stateNode,t.type){case"input":if(Po(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),t=l.name,l.type==="radio"&&t!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Mt(""+t)+'"][type="radio"]'),t=0;t<l.length;t++){var a=l[t];if(a!==e&&a.form===e.form){var n=a[ft]||null;if(!n)throw Error(u(90));Po(a,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name)}}for(t=0;t<l.length;t++)a=l[t],a.form===e.form&&mr(a)}break e;case"textarea":pr(e,l.value,l.defaultValue);break e;case"select":t=l.value,t!=null&&ha(e,!!l.multiple,t,!1)}}}var nc=!1;function xr(e,t,l){if(nc)return e(t,l);nc=!0;try{var a=e(t);return a}finally{if(nc=!1,(ya!==null||ga!==null)&&(Fi(),ya&&(t=ya,e=ga,ga=ya=null,br(t),e)))for(t=0;t<e.length;t++)br(e[t])}}function an(e,t){var l=e.stateNode;if(l===null)return null;var a=l[ft]||null;if(a===null)return null;l=a[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(a=!a.disabled)||(e=e.type,a=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!a;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(u(231,t,typeof l));return l}var Ft=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ic=!1;if(Ft)try{var nn={};Object.defineProperty(nn,"passive",{get:function(){ic=!0}}),window.addEventListener("test",nn,nn),window.removeEventListener("test",nn,nn)}catch{ic=!1}var hl=null,oc=null,_i=null;function Sr(){if(_i)return _i;var e,t=oc,l=t.length,a,n="value"in hl?hl.value:hl.textContent,i=n.length;for(e=0;e<l&&t[e]===n[e];e++);var s=l-e;for(a=1;a<=s&&t[l-a]===n[i-a];a++);return _i=n.slice(e,1<a?1-a:void 0)}function fi(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function di(){return!0}function wr(){return!1}function dt(e){function t(l,a,n,i,s){this._reactName=l,this._targetInst=n,this.type=a,this.nativeEvent=i,this.target=s,this.currentTarget=null;for(var d in e)e.hasOwnProperty(d)&&(l=e[d],this[d]=l?l(i):i[d]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?di:wr,this.isPropagationStopped=wr,this}return C(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=di)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=di)},persist:function(){},isPersistent:di}),t}var Vl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},mi=dt(Vl),on=C({},Vl,{view:0,detail:0}),Gp=dt(on),cc,sc,cn,hi=C({},on,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:rc,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==cn&&(cn&&e.type==="mousemove"?(cc=e.screenX-cn.screenX,sc=e.screenY-cn.screenY):sc=cc=0,cn=e),cc)},movementY:function(e){return"movementY"in e?e.movementY:sc}}),Er=dt(hi),Xp=C({},hi,{dataTransfer:0}),Vp=dt(Xp),Qp=C({},on,{relatedTarget:0}),uc=dt(Qp),Zp=C({},Vl,{animationName:0,elapsedTime:0,pseudoElement:0}),Kp=dt(Zp),Jp=C({},Vl,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),$p=dt(Jp),Wp=C({},Vl,{data:0}),Tr=dt(Wp),Fp={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Ip={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Pp={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function ey(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Pp[e])?!!t[e]:!1}function rc(){return ey}var ty=C({},on,{key:function(e){if(e.key){var t=Fp[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=fi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Ip[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:rc,charCode:function(e){return e.type==="keypress"?fi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?fi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),ly=dt(ty),ay=C({},hi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Nr=dt(ay),ny=C({},on,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:rc}),iy=dt(ny),oy=C({},Vl,{propertyName:0,elapsedTime:0,pseudoElement:0}),cy=dt(oy),sy=C({},hi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),uy=dt(sy),ry=C({},Vl,{newState:0,oldState:0}),_y=dt(ry),fy=[9,13,27,32],_c=Ft&&"CompositionEvent"in window,sn=null;Ft&&"documentMode"in document&&(sn=document.documentMode);var dy=Ft&&"TextEvent"in window&&!sn,jr=Ft&&(!_c||sn&&8<sn&&11>=sn),Cr=" ",zr=!1;function Mr(e,t){switch(e){case"keyup":return fy.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Ar(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var va=!1;function my(e,t){switch(e){case"compositionend":return Ar(t);case"keypress":return t.which!==32?null:(zr=!0,Cr);case"textInput":return e=t.data,e===Cr&&zr?null:e;default:return null}}function hy(e,t){if(va)return e==="compositionend"||!_c&&Mr(e,t)?(e=Sr(),_i=oc=hl=null,va=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return jr&&t.locale!=="ko"?null:t.data;default:return null}}var py={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Hr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!py[e.type]:t==="textarea"}function Dr(e,t,l,a){ya?ga?ga.push(a):ga=[a]:ya=a,t=no(t,"onChange"),0<t.length&&(l=new mi("onChange","change",null,l,a),e.push({event:l,listeners:t}))}var un=null,rn=null;function yy(e){pd(e,0)}function pi(e){var t=ln(e);if(mr(t))return e}function Or(e,t){if(e==="change")return t}var Rr=!1;if(Ft){var fc;if(Ft){var dc="oninput"in document;if(!dc){var Ur=document.createElement("div");Ur.setAttribute("oninput","return;"),dc=typeof Ur.oninput=="function"}fc=dc}else fc=!1;Rr=fc&&(!document.documentMode||9<document.documentMode)}function Lr(){un&&(un.detachEvent("onpropertychange",Br),rn=un=null)}function Br(e){if(e.propertyName==="value"&&pi(rn)){var t=[];Dr(t,rn,e,ac(e)),xr(yy,t)}}function gy(e,t,l){e==="focusin"?(Lr(),un=t,rn=l,un.attachEvent("onpropertychange",Br)):e==="focusout"&&Lr()}function vy(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return pi(rn)}function by(e,t){if(e==="click")return pi(t)}function xy(e,t){if(e==="input"||e==="change")return pi(t)}function Sy(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var St=typeof Object.is=="function"?Object.is:Sy;function _n(e,t){if(St(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var l=Object.keys(e),a=Object.keys(t);if(l.length!==a.length)return!1;for(a=0;a<l.length;a++){var n=l[a];if(!Vo.call(t,n)||!St(e[n],t[n]))return!1}return!0}function kr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function qr(e,t){var l=kr(e);e=0;for(var a;l;){if(l.nodeType===3){if(a=e+l.textContent.length,e<=t&&a>=t)return{node:l,offset:t-e};e=a}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=kr(l)}}function Yr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Yr(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Gr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=ui(e.document);t instanceof e.HTMLIFrameElement;){try{var l=typeof t.contentWindow.location.href=="string"}catch{l=!1}if(l)e=t.contentWindow;else break;t=ui(e.document)}return t}function mc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var wy=Ft&&"documentMode"in document&&11>=document.documentMode,ba=null,hc=null,fn=null,pc=!1;function Xr(e,t,l){var a=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;pc||ba==null||ba!==ui(a)||(a=ba,"selectionStart"in a&&mc(a)?a={start:a.selectionStart,end:a.selectionEnd}:(a=(a.ownerDocument&&a.ownerDocument.defaultView||window).getSelection(),a={anchorNode:a.anchorNode,anchorOffset:a.anchorOffset,focusNode:a.focusNode,focusOffset:a.focusOffset}),fn&&_n(fn,a)||(fn=a,a=no(hc,"onSelect"),0<a.length&&(t=new mi("onSelect","select",null,t,l),e.push({event:t,listeners:a}),t.target=ba)))}function Ql(e,t){var l={};return l[e.toLowerCase()]=t.toLowerCase(),l["Webkit"+e]="webkit"+t,l["Moz"+e]="moz"+t,l}var xa={animationend:Ql("Animation","AnimationEnd"),animationiteration:Ql("Animation","AnimationIteration"),animationstart:Ql("Animation","AnimationStart"),transitionrun:Ql("Transition","TransitionRun"),transitionstart:Ql("Transition","TransitionStart"),transitioncancel:Ql("Transition","TransitionCancel"),transitionend:Ql("Transition","TransitionEnd")},yc={},Vr={};Ft&&(Vr=document.createElement("div").style,"AnimationEvent"in window||(delete xa.animationend.animation,delete xa.animationiteration.animation,delete xa.animationstart.animation),"TransitionEvent"in window||delete xa.transitionend.transition);function Zl(e){if(yc[e])return yc[e];if(!xa[e])return e;var t=xa[e],l;for(l in t)if(t.hasOwnProperty(l)&&l in Vr)return yc[e]=t[l];return e}var Qr=Zl("animationend"),Zr=Zl("animationiteration"),Kr=Zl("animationstart"),Ey=Zl("transitionrun"),Ty=Zl("transitionstart"),Ny=Zl("transitioncancel"),Jr=Zl("transitionend"),$r=new Map,gc="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");gc.push("scrollEnd");function qt(e,t){$r.set(e,t),Xl(t,[e])}var yi=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},At=[],Sa=0,vc=0;function gi(){for(var e=Sa,t=vc=Sa=0;t<e;){var l=At[t];At[t++]=null;var a=At[t];At[t++]=null;var n=At[t];At[t++]=null;var i=At[t];if(At[t++]=null,a!==null&&n!==null){var s=a.pending;s===null?n.next=n:(n.next=s.next,s.next=n),a.pending=n}i!==0&&Wr(l,n,i)}}function vi(e,t,l,a){At[Sa++]=e,At[Sa++]=t,At[Sa++]=l,At[Sa++]=a,vc|=a,e.lanes|=a,e=e.alternate,e!==null&&(e.lanes|=a)}function bc(e,t,l,a){return vi(e,t,l,a),bi(e)}function Kl(e,t){return vi(e,null,null,t),bi(e)}function Wr(e,t,l){e.lanes|=l;var a=e.alternate;a!==null&&(a.lanes|=l);for(var n=!1,i=e.return;i!==null;)i.childLanes|=l,a=i.alternate,a!==null&&(a.childLanes|=l),i.tag===22&&(e=i.stateNode,e===null||e._visibility&1||(n=!0)),e=i,i=i.return;return e.tag===3?(i=e.stateNode,n&&t!==null&&(n=31-xt(l),e=i.hiddenUpdates,a=e[n],a===null?e[n]=[t]:a.push(t),t.lane=l|536870912),i):null}function bi(e){if(50<On)throw On=0,zs=null,Error(u(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var wa={};function jy(e,t,l,a){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=a,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function wt(e,t,l,a){return new jy(e,t,l,a)}function xc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function It(e,t){var l=e.alternate;return l===null?(l=wt(e.tag,t,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=t,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,t=e.dependencies,l.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function Fr(e,t){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,t=l.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function xi(e,t,l,a,n,i){var s=0;if(a=e,typeof e=="function")xc(e)&&(s=1);else if(typeof e=="string")s=Hg(e,l,W.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case Ee:return e=wt(31,l,t,n),e.elementType=Ee,e.lanes=i,e;case G:return Jl(l.children,n,i,t);case Z:s=8,n|=24;break;case q:return e=wt(12,l,t,n|2),e.elementType=q,e.lanes=i,e;case ae:return e=wt(13,l,t,n),e.elementType=ae,e.lanes=i,e;case ne:return e=wt(19,l,t,n),e.elementType=ne,e.lanes=i,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case j:s=10;break e;case X:s=9;break e;case F:s=11;break e;case K:s=14;break e;case se:s=16,a=null;break e}s=29,l=Error(u(130,e===null?"null":typeof e,"")),a=null}return t=wt(s,l,t,n),t.elementType=e,t.type=a,t.lanes=i,t}function Jl(e,t,l,a){return e=wt(7,e,a,t),e.lanes=l,e}function Sc(e,t,l){return e=wt(6,e,null,t),e.lanes=l,e}function Ir(e){var t=wt(18,null,null,0);return t.stateNode=e,t}function wc(e,t,l){return t=wt(4,e.children!==null?e.children:[],e.key,t),t.lanes=l,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var Pr=new WeakMap;function Ht(e,t){if(typeof e=="object"&&e!==null){var l=Pr.get(e);return l!==void 0?l:(t={value:e,source:t,stack:Iu(t)},Pr.set(e,t),t)}return{value:e,source:t,stack:Iu(t)}}var Ea=[],Ta=0,Si=null,dn=0,Dt=[],Ot=0,pl=null,Xt=1,Vt="";function Pt(e,t){Ea[Ta++]=dn,Ea[Ta++]=Si,Si=e,dn=t}function e_(e,t,l){Dt[Ot++]=Xt,Dt[Ot++]=Vt,Dt[Ot++]=pl,pl=e;var a=Xt;e=Vt;var n=32-xt(a)-1;a&=~(1<<n),l+=1;var i=32-xt(t)+n;if(30<i){var s=n-n%5;i=(a&(1<<s)-1).toString(32),a>>=s,n-=s,Xt=1<<32-xt(t)+n|l<<n|a,Vt=i+e}else Xt=1<<i|l<<n|a,Vt=e}function Ec(e){e.return!==null&&(Pt(e,1),e_(e,1,0))}function Tc(e){for(;e===Si;)Si=Ea[--Ta],Ea[Ta]=null,dn=Ea[--Ta],Ea[Ta]=null;for(;e===pl;)pl=Dt[--Ot],Dt[Ot]=null,Vt=Dt[--Ot],Dt[Ot]=null,Xt=Dt[--Ot],Dt[Ot]=null}function t_(e,t){Dt[Ot++]=Xt,Dt[Ot++]=Vt,Dt[Ot++]=pl,Xt=t.id,Vt=t.overflow,pl=e}var nt=null,Ue=null,be=!1,yl=null,Rt=!1,Nc=Error(u(519));function gl(e){var t=Error(u(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw mn(Ht(t,e)),Nc}function l_(e){var t=e.stateNode,l=e.type,a=e.memoizedProps;switch(t[at]=e,t[ft]=a,l){case"dialog":pe("cancel",t),pe("close",t);break;case"iframe":case"object":case"embed":pe("load",t);break;case"video":case"audio":for(l=0;l<Un.length;l++)pe(Un[l],t);break;case"source":pe("error",t);break;case"img":case"image":case"link":pe("error",t),pe("load",t);break;case"details":pe("toggle",t);break;case"input":pe("invalid",t),hr(t,a.value,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name,!0);break;case"select":pe("invalid",t);break;case"textarea":pe("invalid",t),yr(t,a.value,a.defaultValue,a.children)}l=a.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||t.textContent===""+l||a.suppressHydrationWarning===!0||bd(t.textContent,l)?(a.popover!=null&&(pe("beforetoggle",t),pe("toggle",t)),a.onScroll!=null&&pe("scroll",t),a.onScrollEnd!=null&&pe("scrollend",t),a.onClick!=null&&(t.onclick=Wt),t=!0):t=!1,t||gl(e,!0)}function a_(e){for(nt=e.return;nt;)switch(nt.tag){case 5:case 31:case 13:Rt=!1;return;case 27:case 3:Rt=!0;return;default:nt=nt.return}}function Na(e){if(e!==nt)return!1;if(!be)return a_(e),be=!0,!1;var t=e.tag,l;if((l=t!==3&&t!==27)&&((l=t===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||Vs(e.type,e.memoizedProps)),l=!l),l&&Ue&&gl(e),a_(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(317));Ue=zd(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(317));Ue=zd(e)}else t===27?(t=Ue,Hl(e.type)?(e=$s,$s=null,Ue=e):Ue=t):Ue=nt?Lt(e.stateNode.nextSibling):null;return!0}function $l(){Ue=nt=null,be=!1}function jc(){var e=yl;return e!==null&&(yt===null?yt=e:yt.push.apply(yt,e),yl=null),e}function mn(e){yl===null?yl=[e]:yl.push(e)}var Cc=b(null),Wl=null,el=null;function vl(e,t,l){V(Cc,t._currentValue),t._currentValue=l}function tl(e){e._currentValue=Cc.current,B(Cc)}function zc(e,t,l){for(;e!==null;){var a=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,a!==null&&(a.childLanes|=t)):a!==null&&(a.childLanes&t)!==t&&(a.childLanes|=t),e===l)break;e=e.return}}function Mc(e,t,l,a){var n=e.child;for(n!==null&&(n.return=e);n!==null;){var i=n.dependencies;if(i!==null){var s=n.child;i=i.firstContext;e:for(;i!==null;){var d=i;i=n;for(var p=0;p<t.length;p++)if(d.context===t[p]){i.lanes|=l,d=i.alternate,d!==null&&(d.lanes|=l),zc(i.return,l,e),a||(s=null);break e}i=d.next}}else if(n.tag===18){if(s=n.return,s===null)throw Error(u(341));s.lanes|=l,i=s.alternate,i!==null&&(i.lanes|=l),zc(s,l,e),s=null}else s=n.child;if(s!==null)s.return=n;else for(s=n;s!==null;){if(s===e){s=null;break}if(n=s.sibling,n!==null){n.return=s.return,s=n;break}s=s.return}n=s}}function ja(e,t,l,a){e=null;for(var n=t,i=!1;n!==null;){if(!i){if((n.flags&524288)!==0)i=!0;else if((n.flags&262144)!==0)break}if(n.tag===10){var s=n.alternate;if(s===null)throw Error(u(387));if(s=s.memoizedProps,s!==null){var d=n.type;St(n.pendingProps.value,s.value)||(e!==null?e.push(d):e=[d])}}else if(n===ze.current){if(s=n.alternate,s===null)throw Error(u(387));s.memoizedState.memoizedState!==n.memoizedState.memoizedState&&(e!==null?e.push(Yn):e=[Yn])}n=n.return}e!==null&&Mc(t,e,l,a),t.flags|=262144}function wi(e){for(e=e.firstContext;e!==null;){if(!St(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Fl(e){Wl=e,el=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function it(e){return n_(Wl,e)}function Ei(e,t){return Wl===null&&Fl(e),n_(e,t)}function n_(e,t){var l=t._currentValue;if(t={context:t,memoizedValue:l,next:null},el===null){if(e===null)throw Error(u(308));el=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else el=el.next=t;return l}var Cy=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(l,a){e.push(a)}};this.abort=function(){t.aborted=!0,e.forEach(function(l){return l()})}},zy=c.unstable_scheduleCallback,My=c.unstable_NormalPriority,$e={$$typeof:j,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Ac(){return{controller:new Cy,data:new Map,refCount:0}}function hn(e){e.refCount--,e.refCount===0&&zy(My,function(){e.controller.abort()})}var pn=null,Hc=0,Ca=0,za=null;function Ay(e,t){if(pn===null){var l=pn=[];Hc=0,Ca=Rs(),za={status:"pending",value:void 0,then:function(a){l.push(a)}}}return Hc++,t.then(i_,i_),t}function i_(){if(--Hc===0&&pn!==null){za!==null&&(za.status="fulfilled");var e=pn;pn=null,Ca=0,za=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function Hy(e,t){var l=[],a={status:"pending",value:null,reason:null,then:function(n){l.push(n)}};return e.then(function(){a.status="fulfilled",a.value=t;for(var n=0;n<l.length;n++)(0,l[n])(t)},function(n){for(a.status="rejected",a.reason=n,n=0;n<l.length;n++)(0,l[n])(void 0)}),a}var o_=M.S;M.S=function(e,t){Vf=vt(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&Ay(e,t),o_!==null&&o_(e,t)};var Il=b(null);function Dc(){var e=Il.current;return e!==null?e:Re.pooledCache}function Ti(e,t){t===null?V(Il,Il.current):V(Il,t.pool)}function c_(){var e=Dc();return e===null?null:{parent:$e._currentValue,pool:e}}var Ma=Error(u(460)),Oc=Error(u(474)),Ni=Error(u(542)),ji={then:function(){}};function s_(e){return e=e.status,e==="fulfilled"||e==="rejected"}function u_(e,t,l){switch(l=e[l],l===void 0?e.push(t):l!==t&&(t.then(Wt,Wt),t=l),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,__(e),e;default:if(typeof t.status=="string")t.then(Wt,Wt);else{if(e=Re,e!==null&&100<e.shellSuspendCounter)throw Error(u(482));e=t,e.status="pending",e.then(function(a){if(t.status==="pending"){var n=t;n.status="fulfilled",n.value=a}},function(a){if(t.status==="pending"){var n=t;n.status="rejected",n.reason=a}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,__(e),e}throw ea=t,Ma}}function Pl(e){try{var t=e._init;return t(e._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(ea=l,Ma):l}}var ea=null;function r_(){if(ea===null)throw Error(u(459));var e=ea;return ea=null,e}function __(e){if(e===Ma||e===Ni)throw Error(u(483))}var Aa=null,yn=0;function Ci(e){var t=yn;return yn+=1,Aa===null&&(Aa=[]),u_(Aa,e,t)}function gn(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function zi(e,t){throw t.$$typeof===Y?Error(u(525)):(e=Object.prototype.toString.call(t),Error(u(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function f_(e){function t(w,v){if(e){var E=w.deletions;E===null?(w.deletions=[v],w.flags|=16):E.push(v)}}function l(w,v){if(!e)return null;for(;v!==null;)t(w,v),v=v.sibling;return null}function a(w){for(var v=new Map;w!==null;)w.key!==null?v.set(w.key,w):v.set(w.index,w),w=w.sibling;return v}function n(w,v){return w=It(w,v),w.index=0,w.sibling=null,w}function i(w,v,E){return w.index=E,e?(E=w.alternate,E!==null?(E=E.index,E<v?(w.flags|=67108866,v):E):(w.flags|=67108866,v)):(w.flags|=1048576,v)}function s(w){return e&&w.alternate===null&&(w.flags|=67108866),w}function d(w,v,E,D){return v===null||v.tag!==6?(v=Sc(E,w.mode,D),v.return=w,v):(v=n(v,E),v.return=w,v)}function p(w,v,E,D){var te=E.type;return te===G?H(w,v,E.props.children,D,E.key):v!==null&&(v.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===se&&Pl(te)===v.type)?(v=n(v,E.props),gn(v,E),v.return=w,v):(v=xi(E.type,E.key,E.props,null,w.mode,D),gn(v,E),v.return=w,v)}function T(w,v,E,D){return v===null||v.tag!==4||v.stateNode.containerInfo!==E.containerInfo||v.stateNode.implementation!==E.implementation?(v=wc(E,w.mode,D),v.return=w,v):(v=n(v,E.children||[]),v.return=w,v)}function H(w,v,E,D,te){return v===null||v.tag!==7?(v=Jl(E,w.mode,D,te),v.return=w,v):(v=n(v,E),v.return=w,v)}function O(w,v,E){if(typeof v=="string"&&v!==""||typeof v=="number"||typeof v=="bigint")return v=Sc(""+v,w.mode,E),v.return=w,v;if(typeof v=="object"&&v!==null){switch(v.$$typeof){case R:return E=xi(v.type,v.key,v.props,null,w.mode,E),gn(E,v),E.return=w,E;case L:return v=wc(v,w.mode,E),v.return=w,v;case se:return v=Pl(v),O(w,v,E)}if(oe(v)||ve(v))return v=Jl(v,w.mode,E,null),v.return=w,v;if(typeof v.then=="function")return O(w,Ci(v),E);if(v.$$typeof===j)return O(w,Ei(w,v),E);zi(w,v)}return null}function N(w,v,E,D){var te=v!==null?v.key:null;if(typeof E=="string"&&E!==""||typeof E=="number"||typeof E=="bigint")return te!==null?null:d(w,v,""+E,D);if(typeof E=="object"&&E!==null){switch(E.$$typeof){case R:return E.key===te?p(w,v,E,D):null;case L:return E.key===te?T(w,v,E,D):null;case se:return E=Pl(E),N(w,v,E,D)}if(oe(E)||ve(E))return te!==null?null:H(w,v,E,D,null);if(typeof E.then=="function")return N(w,v,Ci(E),D);if(E.$$typeof===j)return N(w,v,Ei(w,E),D);zi(w,E)}return null}function z(w,v,E,D,te){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return w=w.get(E)||null,d(v,w,""+D,te);if(typeof D=="object"&&D!==null){switch(D.$$typeof){case R:return w=w.get(D.key===null?E:D.key)||null,p(v,w,D,te);case L:return w=w.get(D.key===null?E:D.key)||null,T(v,w,D,te);case se:return D=Pl(D),z(w,v,E,D,te)}if(oe(D)||ve(D))return w=w.get(E)||null,H(v,w,D,te,null);if(typeof D.then=="function")return z(w,v,E,Ci(D),te);if(D.$$typeof===j)return z(w,v,E,Ei(v,D),te);zi(v,D)}return null}function J(w,v,E,D){for(var te=null,Se=null,I=v,fe=v=0,ge=null;I!==null&&fe<E.length;fe++){I.index>fe?(ge=I,I=null):ge=I.sibling;var we=N(w,I,E[fe],D);if(we===null){I===null&&(I=ge);break}e&&I&&we.alternate===null&&t(w,I),v=i(we,v,fe),Se===null?te=we:Se.sibling=we,Se=we,I=ge}if(fe===E.length)return l(w,I),be&&Pt(w,fe),te;if(I===null){for(;fe<E.length;fe++)I=O(w,E[fe],D),I!==null&&(v=i(I,v,fe),Se===null?te=I:Se.sibling=I,Se=I);return be&&Pt(w,fe),te}for(I=a(I);fe<E.length;fe++)ge=z(I,w,fe,E[fe],D),ge!==null&&(e&&ge.alternate!==null&&I.delete(ge.key===null?fe:ge.key),v=i(ge,v,fe),Se===null?te=ge:Se.sibling=ge,Se=ge);return e&&I.forEach(function(Ll){return t(w,Ll)}),be&&Pt(w,fe),te}function ie(w,v,E,D){if(E==null)throw Error(u(151));for(var te=null,Se=null,I=v,fe=v=0,ge=null,we=E.next();I!==null&&!we.done;fe++,we=E.next()){I.index>fe?(ge=I,I=null):ge=I.sibling;var Ll=N(w,I,we.value,D);if(Ll===null){I===null&&(I=ge);break}e&&I&&Ll.alternate===null&&t(w,I),v=i(Ll,v,fe),Se===null?te=Ll:Se.sibling=Ll,Se=Ll,I=ge}if(we.done)return l(w,I),be&&Pt(w,fe),te;if(I===null){for(;!we.done;fe++,we=E.next())we=O(w,we.value,D),we!==null&&(v=i(we,v,fe),Se===null?te=we:Se.sibling=we,Se=we);return be&&Pt(w,fe),te}for(I=a(I);!we.done;fe++,we=E.next())we=z(I,w,fe,we.value,D),we!==null&&(e&&we.alternate!==null&&I.delete(we.key===null?fe:we.key),v=i(we,v,fe),Se===null?te=we:Se.sibling=we,Se=we);return e&&I.forEach(function(Xg){return t(w,Xg)}),be&&Pt(w,fe),te}function Oe(w,v,E,D){if(typeof E=="object"&&E!==null&&E.type===G&&E.key===null&&(E=E.props.children),typeof E=="object"&&E!==null){switch(E.$$typeof){case R:e:{for(var te=E.key;v!==null;){if(v.key===te){if(te=E.type,te===G){if(v.tag===7){l(w,v.sibling),D=n(v,E.props.children),D.return=w,w=D;break e}}else if(v.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===se&&Pl(te)===v.type){l(w,v.sibling),D=n(v,E.props),gn(D,E),D.return=w,w=D;break e}l(w,v);break}else t(w,v);v=v.sibling}E.type===G?(D=Jl(E.props.children,w.mode,D,E.key),D.return=w,w=D):(D=xi(E.type,E.key,E.props,null,w.mode,D),gn(D,E),D.return=w,w=D)}return s(w);case L:e:{for(te=E.key;v!==null;){if(v.key===te)if(v.tag===4&&v.stateNode.containerInfo===E.containerInfo&&v.stateNode.implementation===E.implementation){l(w,v.sibling),D=n(v,E.children||[]),D.return=w,w=D;break e}else{l(w,v);break}else t(w,v);v=v.sibling}D=wc(E,w.mode,D),D.return=w,w=D}return s(w);case se:return E=Pl(E),Oe(w,v,E,D)}if(oe(E))return J(w,v,E,D);if(ve(E)){if(te=ve(E),typeof te!="function")throw Error(u(150));return E=te.call(E),ie(w,v,E,D)}if(typeof E.then=="function")return Oe(w,v,Ci(E),D);if(E.$$typeof===j)return Oe(w,v,Ei(w,E),D);zi(w,E)}return typeof E=="string"&&E!==""||typeof E=="number"||typeof E=="bigint"?(E=""+E,v!==null&&v.tag===6?(l(w,v.sibling),D=n(v,E),D.return=w,w=D):(l(w,v),D=Sc(E,w.mode,D),D.return=w,w=D),s(w)):l(w,v)}return function(w,v,E,D){try{yn=0;var te=Oe(w,v,E,D);return Aa=null,te}catch(I){if(I===Ma||I===Ni)throw I;var Se=wt(29,I,null,w.mode);return Se.lanes=D,Se.return=w,Se}finally{}}}var ta=f_(!0),d_=f_(!1),bl=!1;function Rc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Uc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function xl(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Sl(e,t,l){var a=e.updateQueue;if(a===null)return null;if(a=a.shared,(Ne&2)!==0){var n=a.pending;return n===null?t.next=t:(t.next=n.next,n.next=t),a.pending=t,t=bi(e),Wr(e,null,l),t}return vi(e,a,t,l),bi(e)}function vn(e,t,l){if(t=t.updateQueue,t!==null&&(t=t.shared,(l&4194048)!==0)){var a=t.lanes;a&=e.pendingLanes,l|=a,t.lanes=l,nr(e,l)}}function Lc(e,t){var l=e.updateQueue,a=e.alternate;if(a!==null&&(a=a.updateQueue,l===a)){var n=null,i=null;if(l=l.firstBaseUpdate,l!==null){do{var s={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};i===null?n=i=s:i=i.next=s,l=l.next}while(l!==null);i===null?n=i=t:i=i.next=t}else n=i=t;l={baseState:a.baseState,firstBaseUpdate:n,lastBaseUpdate:i,shared:a.shared,callbacks:a.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=t:e.next=t,l.lastBaseUpdate=t}var Bc=!1;function bn(){if(Bc){var e=za;if(e!==null)throw e}}function xn(e,t,l,a){Bc=!1;var n=e.updateQueue;bl=!1;var i=n.firstBaseUpdate,s=n.lastBaseUpdate,d=n.shared.pending;if(d!==null){n.shared.pending=null;var p=d,T=p.next;p.next=null,s===null?i=T:s.next=T,s=p;var H=e.alternate;H!==null&&(H=H.updateQueue,d=H.lastBaseUpdate,d!==s&&(d===null?H.firstBaseUpdate=T:d.next=T,H.lastBaseUpdate=p))}if(i!==null){var O=n.baseState;s=0,H=T=p=null,d=i;do{var N=d.lane&-536870913,z=N!==d.lane;if(z?(ye&N)===N:(a&N)===N){N!==0&&N===Ca&&(Bc=!0),H!==null&&(H=H.next={lane:0,tag:d.tag,payload:d.payload,callback:null,next:null});e:{var J=e,ie=d;N=t;var Oe=l;switch(ie.tag){case 1:if(J=ie.payload,typeof J=="function"){O=J.call(Oe,O,N);break e}O=J;break e;case 3:J.flags=J.flags&-65537|128;case 0:if(J=ie.payload,N=typeof J=="function"?J.call(Oe,O,N):J,N==null)break e;O=C({},O,N);break e;case 2:bl=!0}}N=d.callback,N!==null&&(e.flags|=64,z&&(e.flags|=8192),z=n.callbacks,z===null?n.callbacks=[N]:z.push(N))}else z={lane:N,tag:d.tag,payload:d.payload,callback:d.callback,next:null},H===null?(T=H=z,p=O):H=H.next=z,s|=N;if(d=d.next,d===null){if(d=n.shared.pending,d===null)break;z=d,d=z.next,z.next=null,n.lastBaseUpdate=z,n.shared.pending=null}}while(!0);H===null&&(p=O),n.baseState=p,n.firstBaseUpdate=T,n.lastBaseUpdate=H,i===null&&(n.shared.lanes=0),jl|=s,e.lanes=s,e.memoizedState=O}}function m_(e,t){if(typeof e!="function")throw Error(u(191,e));e.call(t)}function h_(e,t){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)m_(l[e],t)}var Ha=b(null),Mi=b(0);function p_(e,t){e=rl,V(Mi,e),V(Ha,t),rl=e|t.baseLanes}function kc(){V(Mi,rl),V(Ha,Ha.current)}function qc(){rl=Mi.current,B(Ha),B(Mi)}var Et=b(null),Ut=null;function wl(e){var t=e.alternate;V(Ke,Ke.current&1),V(Et,e),Ut===null&&(t===null||Ha.current!==null||t.memoizedState!==null)&&(Ut=e)}function Yc(e){V(Ke,Ke.current),V(Et,e),Ut===null&&(Ut=e)}function y_(e){e.tag===22?(V(Ke,Ke.current),V(Et,e),Ut===null&&(Ut=e)):El()}function El(){V(Ke,Ke.current),V(Et,Et.current)}function Tt(e){B(Et),Ut===e&&(Ut=null),B(Ke)}var Ke=b(0);function Ai(e){for(var t=e;t!==null;){if(t.tag===13){var l=t.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||Ks(l)||Js(l)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ll=0,re=null,He=null,We=null,Hi=!1,Da=!1,la=!1,Di=0,Sn=0,Oa=null,Dy=0;function Ge(){throw Error(u(321))}function Gc(e,t){if(t===null)return!1;for(var l=0;l<t.length&&l<e.length;l++)if(!St(e[l],t[l]))return!1;return!0}function Xc(e,t,l,a,n,i){return ll=i,re=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,M.H=e===null||e.memoizedState===null?ef:ns,la=!1,i=l(a,n),la=!1,Da&&(i=v_(t,l,a,n)),g_(e),i}function g_(e){M.H=Tn;var t=He!==null&&He.next!==null;if(ll=0,We=He=re=null,Hi=!1,Sn=0,Oa=null,t)throw Error(u(300));e===null||Fe||(e=e.dependencies,e!==null&&wi(e)&&(Fe=!0))}function v_(e,t,l,a){re=e;var n=0;do{if(Da&&(Oa=null),Sn=0,Da=!1,25<=n)throw Error(u(301));if(n+=1,We=He=null,e.updateQueue!=null){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}M.H=tf,i=t(l,a)}while(Da);return i}function Oy(){var e=M.H,t=e.useState()[0];return t=typeof t.then=="function"?wn(t):t,e=e.useState()[0],(He!==null?He.memoizedState:null)!==e&&(re.flags|=1024),t}function Vc(){var e=Di!==0;return Di=0,e}function Qc(e,t,l){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l}function Zc(e){if(Hi){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Hi=!1}ll=0,We=He=re=null,Da=!1,Sn=Di=0,Oa=null}function rt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return We===null?re.memoizedState=We=e:We=We.next=e,We}function Je(){if(He===null){var e=re.alternate;e=e!==null?e.memoizedState:null}else e=He.next;var t=We===null?re.memoizedState:We.next;if(t!==null)We=t,He=e;else{if(e===null)throw re.alternate===null?Error(u(467)):Error(u(310));He=e,e={memoizedState:He.memoizedState,baseState:He.baseState,baseQueue:He.baseQueue,queue:He.queue,next:null},We===null?re.memoizedState=We=e:We=We.next=e}return We}function Oi(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function wn(e){var t=Sn;return Sn+=1,Oa===null&&(Oa=[]),e=u_(Oa,e,t),t=re,(We===null?t.memoizedState:We.next)===null&&(t=t.alternate,M.H=t===null||t.memoizedState===null?ef:ns),e}function Ri(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return wn(e);if(e.$$typeof===j)return it(e)}throw Error(u(438,String(e)))}function Kc(e){var t=null,l=re.updateQueue;if(l!==null&&(t=l.memoCache),t==null){var a=re.alternate;a!==null&&(a=a.updateQueue,a!==null&&(a=a.memoCache,a!=null&&(t={data:a.data.map(function(n){return n.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),l===null&&(l=Oi(),re.updateQueue=l),l.memoCache=t,l=t.data[t.index],l===void 0)for(l=t.data[t.index]=Array(e),a=0;a<e;a++)l[a]=$;return t.index++,l}function al(e,t){return typeof t=="function"?t(e):t}function Ui(e){var t=Je();return Jc(t,He,e)}function Jc(e,t,l){var a=e.queue;if(a===null)throw Error(u(311));a.lastRenderedReducer=l;var n=e.baseQueue,i=a.pending;if(i!==null){if(n!==null){var s=n.next;n.next=i.next,i.next=s}t.baseQueue=n=i,a.pending=null}if(i=e.baseState,n===null)e.memoizedState=i;else{t=n.next;var d=s=null,p=null,T=t,H=!1;do{var O=T.lane&-536870913;if(O!==T.lane?(ye&O)===O:(ll&O)===O){var N=T.revertLane;if(N===0)p!==null&&(p=p.next={lane:0,revertLane:0,gesture:null,action:T.action,hasEagerState:T.hasEagerState,eagerState:T.eagerState,next:null}),O===Ca&&(H=!0);else if((ll&N)===N){T=T.next,N===Ca&&(H=!0);continue}else O={lane:0,revertLane:T.revertLane,gesture:null,action:T.action,hasEagerState:T.hasEagerState,eagerState:T.eagerState,next:null},p===null?(d=p=O,s=i):p=p.next=O,re.lanes|=N,jl|=N;O=T.action,la&&l(i,O),i=T.hasEagerState?T.eagerState:l(i,O)}else N={lane:O,revertLane:T.revertLane,gesture:T.gesture,action:T.action,hasEagerState:T.hasEagerState,eagerState:T.eagerState,next:null},p===null?(d=p=N,s=i):p=p.next=N,re.lanes|=O,jl|=O;T=T.next}while(T!==null&&T!==t);if(p===null?s=i:p.next=d,!St(i,e.memoizedState)&&(Fe=!0,H&&(l=za,l!==null)))throw l;e.memoizedState=i,e.baseState=s,e.baseQueue=p,a.lastRenderedState=i}return n===null&&(a.lanes=0),[e.memoizedState,a.dispatch]}function $c(e){var t=Je(),l=t.queue;if(l===null)throw Error(u(311));l.lastRenderedReducer=e;var a=l.dispatch,n=l.pending,i=t.memoizedState;if(n!==null){l.pending=null;var s=n=n.next;do i=e(i,s.action),s=s.next;while(s!==n);St(i,t.memoizedState)||(Fe=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),l.lastRenderedState=i}return[i,a]}function b_(e,t,l){var a=re,n=Je(),i=be;if(i){if(l===void 0)throw Error(u(407));l=l()}else l=t();var s=!St((He||n).memoizedState,l);if(s&&(n.memoizedState=l,Fe=!0),n=n.queue,Ic(w_.bind(null,a,n,e),[e]),n.getSnapshot!==t||s||We!==null&&We.memoizedState.tag&1){if(a.flags|=2048,Ra(9,{destroy:void 0},S_.bind(null,a,n,l,t),null),Re===null)throw Error(u(349));i||(ll&127)!==0||x_(a,t,l)}return l}function x_(e,t,l){e.flags|=16384,e={getSnapshot:t,value:l},t=re.updateQueue,t===null?(t=Oi(),re.updateQueue=t,t.stores=[e]):(l=t.stores,l===null?t.stores=[e]:l.push(e))}function S_(e,t,l,a){t.value=l,t.getSnapshot=a,E_(t)&&T_(e)}function w_(e,t,l){return l(function(){E_(t)&&T_(e)})}function E_(e){var t=e.getSnapshot;e=e.value;try{var l=t();return!St(e,l)}catch{return!0}}function T_(e){var t=Kl(e,2);t!==null&&gt(t,e,2)}function Wc(e){var t=rt();if(typeof e=="function"){var l=e;if(e=l(),la){dl(!0);try{l()}finally{dl(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:e},t}function N_(e,t,l,a){return e.baseState=l,Jc(e,He,typeof a=="function"?a:al)}function Ry(e,t,l,a,n){if(ki(e))throw Error(u(485));if(e=t.action,e!==null){var i={payload:n,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(s){i.listeners.push(s)}};M.T!==null?l(!0):i.isTransition=!1,a(i),l=t.pending,l===null?(i.next=t.pending=i,j_(t,i)):(i.next=l.next,t.pending=l.next=i)}}function j_(e,t){var l=t.action,a=t.payload,n=e.state;if(t.isTransition){var i=M.T,s={};M.T=s;try{var d=l(n,a),p=M.S;p!==null&&p(s,d),C_(e,t,d)}catch(T){Fc(e,t,T)}finally{i!==null&&s.types!==null&&(i.types=s.types),M.T=i}}else try{i=l(n,a),C_(e,t,i)}catch(T){Fc(e,t,T)}}function C_(e,t,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(a){z_(e,t,a)},function(a){return Fc(e,t,a)}):z_(e,t,l)}function z_(e,t,l){t.status="fulfilled",t.value=l,M_(t),e.state=l,t=e.pending,t!==null&&(l=t.next,l===t?e.pending=null:(l=l.next,t.next=l,j_(e,l)))}function Fc(e,t,l){var a=e.pending;if(e.pending=null,a!==null){a=a.next;do t.status="rejected",t.reason=l,M_(t),t=t.next;while(t!==a)}e.action=null}function M_(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function A_(e,t){return t}function H_(e,t){if(be){var l=Re.formState;if(l!==null){e:{var a=re;if(be){if(Ue){t:{for(var n=Ue,i=Rt;n.nodeType!==8;){if(!i){n=null;break t}if(n=Lt(n.nextSibling),n===null){n=null;break t}}i=n.data,n=i==="F!"||i==="F"?n:null}if(n){Ue=Lt(n.nextSibling),a=n.data==="F!";break e}}gl(a)}a=!1}a&&(t=l[0])}}return l=rt(),l.memoizedState=l.baseState=t,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:A_,lastRenderedState:t},l.queue=a,l=F_.bind(null,re,a),a.dispatch=l,a=Wc(!1),i=as.bind(null,re,!1,a.queue),a=rt(),n={state:t,dispatch:null,action:e,pending:null},a.queue=n,l=Ry.bind(null,re,n,i,l),n.dispatch=l,a.memoizedState=e,[t,l,!1]}function D_(e){var t=Je();return O_(t,He,e)}function O_(e,t,l){if(t=Jc(e,t,A_)[0],e=Ui(al)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var a=wn(t)}catch(s){throw s===Ma?Ni:s}else a=t;t=Je();var n=t.queue,i=n.dispatch;return l!==t.memoizedState&&(re.flags|=2048,Ra(9,{destroy:void 0},Uy.bind(null,n,l),null)),[a,i,e]}function Uy(e,t){e.action=t}function R_(e){var t=Je(),l=He;if(l!==null)return O_(t,l,e);Je(),t=t.memoizedState,l=Je();var a=l.queue.dispatch;return l.memoizedState=e,[t,a,!1]}function Ra(e,t,l,a){return e={tag:e,create:l,deps:a,inst:t,next:null},t=re.updateQueue,t===null&&(t=Oi(),re.updateQueue=t),l=t.lastEffect,l===null?t.lastEffect=e.next=e:(a=l.next,l.next=e,e.next=a,t.lastEffect=e),e}function U_(){return Je().memoizedState}function Li(e,t,l,a){var n=rt();re.flags|=e,n.memoizedState=Ra(1|t,{destroy:void 0},l,a===void 0?null:a)}function Bi(e,t,l,a){var n=Je();a=a===void 0?null:a;var i=n.memoizedState.inst;He!==null&&a!==null&&Gc(a,He.memoizedState.deps)?n.memoizedState=Ra(t,i,l,a):(re.flags|=e,n.memoizedState=Ra(1|t,i,l,a))}function L_(e,t){Li(8390656,8,e,t)}function Ic(e,t){Bi(2048,8,e,t)}function Ly(e){re.flags|=4;var t=re.updateQueue;if(t===null)t=Oi(),re.updateQueue=t,t.events=[e];else{var l=t.events;l===null?t.events=[e]:l.push(e)}}function B_(e){var t=Je().memoizedState;return Ly({ref:t,nextImpl:e}),function(){if((Ne&2)!==0)throw Error(u(440));return t.impl.apply(void 0,arguments)}}function k_(e,t){return Bi(4,2,e,t)}function q_(e,t){return Bi(4,4,e,t)}function Y_(e,t){if(typeof t=="function"){e=e();var l=t(e);return function(){typeof l=="function"?l():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function G_(e,t,l){l=l!=null?l.concat([e]):null,Bi(4,4,Y_.bind(null,t,e),l)}function Pc(){}function X_(e,t){var l=Je();t=t===void 0?null:t;var a=l.memoizedState;return t!==null&&Gc(t,a[1])?a[0]:(l.memoizedState=[e,t],e)}function V_(e,t){var l=Je();t=t===void 0?null:t;var a=l.memoizedState;if(t!==null&&Gc(t,a[1]))return a[0];if(a=e(),la){dl(!0);try{e()}finally{dl(!1)}}return l.memoizedState=[a,t],a}function es(e,t,l){return l===void 0||(ll&1073741824)!==0&&(ye&261930)===0?e.memoizedState=t:(e.memoizedState=l,e=Zf(),re.lanes|=e,jl|=e,l)}function Q_(e,t,l,a){return St(l,t)?l:Ha.current!==null?(e=es(e,l,a),St(e,t)||(Fe=!0),e):(ll&42)===0||(ll&1073741824)!==0&&(ye&261930)===0?(Fe=!0,e.memoizedState=l):(e=Zf(),re.lanes|=e,jl|=e,t)}function Z_(e,t,l,a,n){var i=U.p;U.p=i!==0&&8>i?i:8;var s=M.T,d={};M.T=d,as(e,!1,t,l);try{var p=n(),T=M.S;if(T!==null&&T(d,p),p!==null&&typeof p=="object"&&typeof p.then=="function"){var H=Hy(p,a);En(e,t,H,Ct(e))}else En(e,t,a,Ct(e))}catch(O){En(e,t,{then:function(){},status:"rejected",reason:O},Ct())}finally{U.p=i,s!==null&&d.types!==null&&(s.types=d.types),M.T=s}}function By(){}function ts(e,t,l,a){if(e.tag!==5)throw Error(u(476));var n=K_(e).queue;Z_(e,n,t,ee,l===null?By:function(){return J_(e),l(a)})}function K_(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ee,baseState:ee,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:ee},next:null};var l={};return t.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:l},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function J_(e){var t=K_(e);t.next===null&&(t=e.alternate.memoizedState),En(e,t.next.queue,{},Ct())}function ls(){return it(Yn)}function $_(){return Je().memoizedState}function W_(){return Je().memoizedState}function ky(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var l=Ct();e=xl(l);var a=Sl(t,e,l);a!==null&&(gt(a,t,l),vn(a,t,l)),t={cache:Ac()},e.payload=t;return}t=t.return}}function qy(e,t,l){var a=Ct();l={lane:a,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},ki(e)?I_(t,l):(l=bc(e,t,l,a),l!==null&&(gt(l,e,a),P_(l,t,a)))}function F_(e,t,l){var a=Ct();En(e,t,l,a)}function En(e,t,l,a){var n={lane:a,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(ki(e))I_(t,n);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var s=t.lastRenderedState,d=i(s,l);if(n.hasEagerState=!0,n.eagerState=d,St(d,s))return vi(e,t,n,0),Re===null&&gi(),!1}catch{}finally{}if(l=bc(e,t,n,a),l!==null)return gt(l,e,a),P_(l,t,a),!0}return!1}function as(e,t,l,a){if(a={lane:2,revertLane:Rs(),gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},ki(e)){if(t)throw Error(u(479))}else t=bc(e,l,a,2),t!==null&&gt(t,e,2)}function ki(e){var t=e.alternate;return e===re||t!==null&&t===re}function I_(e,t){Da=Hi=!0;var l=e.pending;l===null?t.next=t:(t.next=l.next,l.next=t),e.pending=t}function P_(e,t,l){if((l&4194048)!==0){var a=t.lanes;a&=e.pendingLanes,l|=a,t.lanes=l,nr(e,l)}}var Tn={readContext:it,use:Ri,useCallback:Ge,useContext:Ge,useEffect:Ge,useImperativeHandle:Ge,useLayoutEffect:Ge,useInsertionEffect:Ge,useMemo:Ge,useReducer:Ge,useRef:Ge,useState:Ge,useDebugValue:Ge,useDeferredValue:Ge,useTransition:Ge,useSyncExternalStore:Ge,useId:Ge,useHostTransitionStatus:Ge,useFormState:Ge,useActionState:Ge,useOptimistic:Ge,useMemoCache:Ge,useCacheRefresh:Ge};Tn.useEffectEvent=Ge;var ef={readContext:it,use:Ri,useCallback:function(e,t){return rt().memoizedState=[e,t===void 0?null:t],e},useContext:it,useEffect:L_,useImperativeHandle:function(e,t,l){l=l!=null?l.concat([e]):null,Li(4194308,4,Y_.bind(null,t,e),l)},useLayoutEffect:function(e,t){return Li(4194308,4,e,t)},useInsertionEffect:function(e,t){Li(4,2,e,t)},useMemo:function(e,t){var l=rt();t=t===void 0?null:t;var a=e();if(la){dl(!0);try{e()}finally{dl(!1)}}return l.memoizedState=[a,t],a},useReducer:function(e,t,l){var a=rt();if(l!==void 0){var n=l(t);if(la){dl(!0);try{l(t)}finally{dl(!1)}}}else n=t;return a.memoizedState=a.baseState=n,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:n},a.queue=e,e=e.dispatch=qy.bind(null,re,e),[a.memoizedState,e]},useRef:function(e){var t=rt();return e={current:e},t.memoizedState=e},useState:function(e){e=Wc(e);var t=e.queue,l=F_.bind(null,re,t);return t.dispatch=l,[e.memoizedState,l]},useDebugValue:Pc,useDeferredValue:function(e,t){var l=rt();return es(l,e,t)},useTransition:function(){var e=Wc(!1);return e=Z_.bind(null,re,e.queue,!0,!1),rt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,l){var a=re,n=rt();if(be){if(l===void 0)throw Error(u(407));l=l()}else{if(l=t(),Re===null)throw Error(u(349));(ye&127)!==0||x_(a,t,l)}n.memoizedState=l;var i={value:l,getSnapshot:t};return n.queue=i,L_(w_.bind(null,a,i,e),[e]),a.flags|=2048,Ra(9,{destroy:void 0},S_.bind(null,a,i,l,t),null),l},useId:function(){var e=rt(),t=Re.identifierPrefix;if(be){var l=Vt,a=Xt;l=(a&~(1<<32-xt(a)-1)).toString(32)+l,t="_"+t+"R_"+l,l=Di++,0<l&&(t+="H"+l.toString(32)),t+="_"}else l=Dy++,t="_"+t+"r_"+l.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:ls,useFormState:H_,useActionState:H_,useOptimistic:function(e){var t=rt();t.memoizedState=t.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=l,t=as.bind(null,re,!0,l),l.dispatch=t,[e,t]},useMemoCache:Kc,useCacheRefresh:function(){return rt().memoizedState=ky.bind(null,re)},useEffectEvent:function(e){var t=rt(),l={impl:e};return t.memoizedState=l,function(){if((Ne&2)!==0)throw Error(u(440));return l.impl.apply(void 0,arguments)}}},ns={readContext:it,use:Ri,useCallback:X_,useContext:it,useEffect:Ic,useImperativeHandle:G_,useInsertionEffect:k_,useLayoutEffect:q_,useMemo:V_,useReducer:Ui,useRef:U_,useState:function(){return Ui(al)},useDebugValue:Pc,useDeferredValue:function(e,t){var l=Je();return Q_(l,He.memoizedState,e,t)},useTransition:function(){var e=Ui(al)[0],t=Je().memoizedState;return[typeof e=="boolean"?e:wn(e),t]},useSyncExternalStore:b_,useId:$_,useHostTransitionStatus:ls,useFormState:D_,useActionState:D_,useOptimistic:function(e,t){var l=Je();return N_(l,He,e,t)},useMemoCache:Kc,useCacheRefresh:W_};ns.useEffectEvent=B_;var tf={readContext:it,use:Ri,useCallback:X_,useContext:it,useEffect:Ic,useImperativeHandle:G_,useInsertionEffect:k_,useLayoutEffect:q_,useMemo:V_,useReducer:$c,useRef:U_,useState:function(){return $c(al)},useDebugValue:Pc,useDeferredValue:function(e,t){var l=Je();return He===null?es(l,e,t):Q_(l,He.memoizedState,e,t)},useTransition:function(){var e=$c(al)[0],t=Je().memoizedState;return[typeof e=="boolean"?e:wn(e),t]},useSyncExternalStore:b_,useId:$_,useHostTransitionStatus:ls,useFormState:R_,useActionState:R_,useOptimistic:function(e,t){var l=Je();return He!==null?N_(l,He,e,t):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:Kc,useCacheRefresh:W_};tf.useEffectEvent=B_;function is(e,t,l,a){t=e.memoizedState,l=l(a,t),l=l==null?t:C({},t,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var os={enqueueSetState:function(e,t,l){e=e._reactInternals;var a=Ct(),n=xl(a);n.payload=t,l!=null&&(n.callback=l),t=Sl(e,n,a),t!==null&&(gt(t,e,a),vn(t,e,a))},enqueueReplaceState:function(e,t,l){e=e._reactInternals;var a=Ct(),n=xl(a);n.tag=1,n.payload=t,l!=null&&(n.callback=l),t=Sl(e,n,a),t!==null&&(gt(t,e,a),vn(t,e,a))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var l=Ct(),a=xl(l);a.tag=2,t!=null&&(a.callback=t),t=Sl(e,a,l),t!==null&&(gt(t,e,l),vn(t,e,l))}};function lf(e,t,l,a,n,i,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(a,i,s):t.prototype&&t.prototype.isPureReactComponent?!_n(l,a)||!_n(n,i):!0}function af(e,t,l,a){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(l,a),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(l,a),t.state!==e&&os.enqueueReplaceState(t,t.state,null)}function aa(e,t){var l=t;if("ref"in t){l={};for(var a in t)a!=="ref"&&(l[a]=t[a])}if(e=e.defaultProps){l===t&&(l=C({},l));for(var n in e)l[n]===void 0&&(l[n]=e[n])}return l}function nf(e){yi(e)}function of(e){console.error(e)}function cf(e){yi(e)}function qi(e,t){try{var l=e.onUncaughtError;l(t.value,{componentStack:t.stack})}catch(a){setTimeout(function(){throw a})}}function sf(e,t,l){try{var a=e.onCaughtError;a(l.value,{componentStack:l.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(n){setTimeout(function(){throw n})}}function cs(e,t,l){return l=xl(l),l.tag=3,l.payload={element:null},l.callback=function(){qi(e,t)},l}function uf(e){return e=xl(e),e.tag=3,e}function rf(e,t,l,a){var n=l.type.getDerivedStateFromError;if(typeof n=="function"){var i=a.value;e.payload=function(){return n(i)},e.callback=function(){sf(t,l,a)}}var s=l.stateNode;s!==null&&typeof s.componentDidCatch=="function"&&(e.callback=function(){sf(t,l,a),typeof n!="function"&&(Cl===null?Cl=new Set([this]):Cl.add(this));var d=a.stack;this.componentDidCatch(a.value,{componentStack:d!==null?d:""})})}function Yy(e,t,l,a,n){if(l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){if(t=l.alternate,t!==null&&ja(t,l,n,!0),l=Et.current,l!==null){switch(l.tag){case 31:case 13:return Ut===null?Ii():l.alternate===null&&Xe===0&&(Xe=3),l.flags&=-257,l.flags|=65536,l.lanes=n,a===ji?l.flags|=16384:(t=l.updateQueue,t===null?l.updateQueue=new Set([a]):t.add(a),Hs(e,a,n)),!1;case 22:return l.flags|=65536,a===ji?l.flags|=16384:(t=l.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([a])},l.updateQueue=t):(l=t.retryQueue,l===null?t.retryQueue=new Set([a]):l.add(a)),Hs(e,a,n)),!1}throw Error(u(435,l.tag))}return Hs(e,a,n),Ii(),!1}if(be)return t=Et.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=n,a!==Nc&&(e=Error(u(422),{cause:a}),mn(Ht(e,l)))):(a!==Nc&&(t=Error(u(423),{cause:a}),mn(Ht(t,l))),e=e.current.alternate,e.flags|=65536,n&=-n,e.lanes|=n,a=Ht(a,l),n=cs(e.stateNode,a,n),Lc(e,n),Xe!==4&&(Xe=2)),!1;var i=Error(u(520),{cause:a});if(i=Ht(i,l),Dn===null?Dn=[i]:Dn.push(i),Xe!==4&&(Xe=2),t===null)return!0;a=Ht(a,l),l=t;do{switch(l.tag){case 3:return l.flags|=65536,e=n&-n,l.lanes|=e,e=cs(l.stateNode,a,e),Lc(l,e),!1;case 1:if(t=l.type,i=l.stateNode,(l.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||i!==null&&typeof i.componentDidCatch=="function"&&(Cl===null||!Cl.has(i))))return l.flags|=65536,n&=-n,l.lanes|=n,n=uf(n),rf(n,e,l,a),Lc(l,n),!1}l=l.return}while(l!==null);return!1}var ss=Error(u(461)),Fe=!1;function ot(e,t,l,a){t.child=e===null?d_(t,null,l,a):ta(t,e.child,l,a)}function _f(e,t,l,a,n){l=l.render;var i=t.ref;if("ref"in a){var s={};for(var d in a)d!=="ref"&&(s[d]=a[d])}else s=a;return Fl(t),a=Xc(e,t,l,s,i,n),d=Vc(),e!==null&&!Fe?(Qc(e,t,n),nl(e,t,n)):(be&&d&&Ec(t),t.flags|=1,ot(e,t,a,n),t.child)}function ff(e,t,l,a,n){if(e===null){var i=l.type;return typeof i=="function"&&!xc(i)&&i.defaultProps===void 0&&l.compare===null?(t.tag=15,t.type=i,df(e,t,i,a,n)):(e=xi(l.type,null,a,t,t.mode,n),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!ps(e,n)){var s=i.memoizedProps;if(l=l.compare,l=l!==null?l:_n,l(s,a)&&e.ref===t.ref)return nl(e,t,n)}return t.flags|=1,e=It(i,a),e.ref=t.ref,e.return=t,t.child=e}function df(e,t,l,a,n){if(e!==null){var i=e.memoizedProps;if(_n(i,a)&&e.ref===t.ref)if(Fe=!1,t.pendingProps=a=i,ps(e,n))(e.flags&131072)!==0&&(Fe=!0);else return t.lanes=e.lanes,nl(e,t,n)}return us(e,t,l,a,n)}function mf(e,t,l,a){var n=a.children,i=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.mode==="hidden"){if((t.flags&128)!==0){if(i=i!==null?i.baseLanes|l:l,e!==null){for(a=t.child=e.child,n=0;a!==null;)n=n|a.lanes|a.childLanes,a=a.sibling;a=n&~i}else a=0,t.child=null;return hf(e,t,i,l,a)}if((l&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ti(t,i!==null?i.cachePool:null),i!==null?p_(t,i):kc(),y_(t);else return a=t.lanes=536870912,hf(e,t,i!==null?i.baseLanes|l:l,l,a)}else i!==null?(Ti(t,i.cachePool),p_(t,i),El(),t.memoizedState=null):(e!==null&&Ti(t,null),kc(),El());return ot(e,t,n,l),t.child}function Nn(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function hf(e,t,l,a,n){var i=Dc();return i=i===null?null:{parent:$e._currentValue,pool:i},t.memoizedState={baseLanes:l,cachePool:i},e!==null&&Ti(t,null),kc(),y_(t),e!==null&&ja(e,t,a,!0),t.childLanes=n,null}function Yi(e,t){return t=Xi({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function pf(e,t,l){return ta(t,e.child,null,l),e=Yi(t,t.pendingProps),e.flags|=2,Tt(t),t.memoizedState=null,e}function Gy(e,t,l){var a=t.pendingProps,n=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(be){if(a.mode==="hidden")return e=Yi(t,a),t.lanes=536870912,Nn(null,e);if(Yc(t),(e=Ue)?(e=Cd(e,Rt),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:pl!==null?{id:Xt,overflow:Vt}:null,retryLane:536870912,hydrationErrors:null},l=Ir(e),l.return=t,t.child=l,nt=t,Ue=null)):e=null,e===null)throw gl(t);return t.lanes=536870912,null}return Yi(t,a)}var i=e.memoizedState;if(i!==null){var s=i.dehydrated;if(Yc(t),n)if(t.flags&256)t.flags&=-257,t=pf(e,t,l);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(u(558));else if(Fe||ja(e,t,l,!1),n=(l&e.childLanes)!==0,Fe||n){if(a=Re,a!==null&&(s=ir(a,l),s!==0&&s!==i.retryLane))throw i.retryLane=s,Kl(e,s),gt(a,e,s),ss;Ii(),t=pf(e,t,l)}else e=i.treeContext,Ue=Lt(s.nextSibling),nt=t,be=!0,yl=null,Rt=!1,e!==null&&t_(t,e),t=Yi(t,a),t.flags|=4096;return t}return e=It(e.child,{mode:a.mode,children:a.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Gi(e,t){var l=t.ref;if(l===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(u(284));(e===null||e.ref!==l)&&(t.flags|=4194816)}}function us(e,t,l,a,n){return Fl(t),l=Xc(e,t,l,a,void 0,n),a=Vc(),e!==null&&!Fe?(Qc(e,t,n),nl(e,t,n)):(be&&a&&Ec(t),t.flags|=1,ot(e,t,l,n),t.child)}function yf(e,t,l,a,n,i){return Fl(t),t.updateQueue=null,l=v_(t,a,l,n),g_(e),a=Vc(),e!==null&&!Fe?(Qc(e,t,i),nl(e,t,i)):(be&&a&&Ec(t),t.flags|=1,ot(e,t,l,i),t.child)}function gf(e,t,l,a,n){if(Fl(t),t.stateNode===null){var i=wa,s=l.contextType;typeof s=="object"&&s!==null&&(i=it(s)),i=new l(a,i),t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=os,t.stateNode=i,i._reactInternals=t,i=t.stateNode,i.props=a,i.state=t.memoizedState,i.refs={},Rc(t),s=l.contextType,i.context=typeof s=="object"&&s!==null?it(s):wa,i.state=t.memoizedState,s=l.getDerivedStateFromProps,typeof s=="function"&&(is(t,l,s,a),i.state=t.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(s=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),s!==i.state&&os.enqueueReplaceState(i,i.state,null),xn(t,a,i,n),bn(),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308),a=!0}else if(e===null){i=t.stateNode;var d=t.memoizedProps,p=aa(l,d);i.props=p;var T=i.context,H=l.contextType;s=wa,typeof H=="object"&&H!==null&&(s=it(H));var O=l.getDerivedStateFromProps;H=typeof O=="function"||typeof i.getSnapshotBeforeUpdate=="function",d=t.pendingProps!==d,H||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(d||T!==s)&&af(t,i,a,s),bl=!1;var N=t.memoizedState;i.state=N,xn(t,a,i,n),bn(),T=t.memoizedState,d||N!==T||bl?(typeof O=="function"&&(is(t,l,O,a),T=t.memoizedState),(p=bl||lf(t,l,p,a,N,T,s))?(H||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=a,t.memoizedState=T),i.props=a,i.state=T,i.context=s,a=p):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),a=!1)}else{i=t.stateNode,Uc(e,t),s=t.memoizedProps,H=aa(l,s),i.props=H,O=t.pendingProps,N=i.context,T=l.contextType,p=wa,typeof T=="object"&&T!==null&&(p=it(T)),d=l.getDerivedStateFromProps,(T=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(s!==O||N!==p)&&af(t,i,a,p),bl=!1,N=t.memoizedState,i.state=N,xn(t,a,i,n),bn();var z=t.memoizedState;s!==O||N!==z||bl||e!==null&&e.dependencies!==null&&wi(e.dependencies)?(typeof d=="function"&&(is(t,l,d,a),z=t.memoizedState),(H=bl||lf(t,l,H,a,N,z,p)||e!==null&&e.dependencies!==null&&wi(e.dependencies))?(T||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(a,z,p),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(a,z,p)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||s===e.memoizedProps&&N===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&N===e.memoizedState||(t.flags|=1024),t.memoizedProps=a,t.memoizedState=z),i.props=a,i.state=z,i.context=p,a=H):(typeof i.componentDidUpdate!="function"||s===e.memoizedProps&&N===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&N===e.memoizedState||(t.flags|=1024),a=!1)}return i=a,Gi(e,t),a=(t.flags&128)!==0,i||a?(i=t.stateNode,l=a&&typeof l.getDerivedStateFromError!="function"?null:i.render(),t.flags|=1,e!==null&&a?(t.child=ta(t,e.child,null,n),t.child=ta(t,null,l,n)):ot(e,t,l,n),t.memoizedState=i.state,e=t.child):e=nl(e,t,n),e}function vf(e,t,l,a){return $l(),t.flags|=256,ot(e,t,l,a),t.child}var rs={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function _s(e){return{baseLanes:e,cachePool:c_()}}function fs(e,t,l){return e=e!==null?e.childLanes&~l:0,t&&(e|=jt),e}function bf(e,t,l){var a=t.pendingProps,n=!1,i=(t.flags&128)!==0,s;if((s=i)||(s=e!==null&&e.memoizedState===null?!1:(Ke.current&2)!==0),s&&(n=!0,t.flags&=-129),s=(t.flags&32)!==0,t.flags&=-33,e===null){if(be){if(n?wl(t):El(),(e=Ue)?(e=Cd(e,Rt),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:pl!==null?{id:Xt,overflow:Vt}:null,retryLane:536870912,hydrationErrors:null},l=Ir(e),l.return=t,t.child=l,nt=t,Ue=null)):e=null,e===null)throw gl(t);return Js(e)?t.lanes=32:t.lanes=536870912,null}var d=a.children;return a=a.fallback,n?(El(),n=t.mode,d=Xi({mode:"hidden",children:d},n),a=Jl(a,n,l,null),d.return=t,a.return=t,d.sibling=a,t.child=d,a=t.child,a.memoizedState=_s(l),a.childLanes=fs(e,s,l),t.memoizedState=rs,Nn(null,a)):(wl(t),ds(t,d))}var p=e.memoizedState;if(p!==null&&(d=p.dehydrated,d!==null)){if(i)t.flags&256?(wl(t),t.flags&=-257,t=ms(e,t,l)):t.memoizedState!==null?(El(),t.child=e.child,t.flags|=128,t=null):(El(),d=a.fallback,n=t.mode,a=Xi({mode:"visible",children:a.children},n),d=Jl(d,n,l,null),d.flags|=2,a.return=t,d.return=t,a.sibling=d,t.child=a,ta(t,e.child,null,l),a=t.child,a.memoizedState=_s(l),a.childLanes=fs(e,s,l),t.memoizedState=rs,t=Nn(null,a));else if(wl(t),Js(d)){if(s=d.nextSibling&&d.nextSibling.dataset,s)var T=s.dgst;s=T,a=Error(u(419)),a.stack="",a.digest=s,mn({value:a,source:null,stack:null}),t=ms(e,t,l)}else if(Fe||ja(e,t,l,!1),s=(l&e.childLanes)!==0,Fe||s){if(s=Re,s!==null&&(a=ir(s,l),a!==0&&a!==p.retryLane))throw p.retryLane=a,Kl(e,a),gt(s,e,a),ss;Ks(d)||Ii(),t=ms(e,t,l)}else Ks(d)?(t.flags|=192,t.child=e.child,t=null):(e=p.treeContext,Ue=Lt(d.nextSibling),nt=t,be=!0,yl=null,Rt=!1,e!==null&&t_(t,e),t=ds(t,a.children),t.flags|=4096);return t}return n?(El(),d=a.fallback,n=t.mode,p=e.child,T=p.sibling,a=It(p,{mode:"hidden",children:a.children}),a.subtreeFlags=p.subtreeFlags&65011712,T!==null?d=It(T,d):(d=Jl(d,n,l,null),d.flags|=2),d.return=t,a.return=t,a.sibling=d,t.child=a,Nn(null,a),a=t.child,d=e.child.memoizedState,d===null?d=_s(l):(n=d.cachePool,n!==null?(p=$e._currentValue,n=n.parent!==p?{parent:p,pool:p}:n):n=c_(),d={baseLanes:d.baseLanes|l,cachePool:n}),a.memoizedState=d,a.childLanes=fs(e,s,l),t.memoizedState=rs,Nn(e.child,a)):(wl(t),l=e.child,e=l.sibling,l=It(l,{mode:"visible",children:a.children}),l.return=t,l.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=l,t.memoizedState=null,l)}function ds(e,t){return t=Xi({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function Xi(e,t){return e=wt(22,e,null,t),e.lanes=0,e}function ms(e,t,l){return ta(t,e.child,null,l),e=ds(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function xf(e,t,l){e.lanes|=t;var a=e.alternate;a!==null&&(a.lanes|=t),zc(e.return,t,l)}function hs(e,t,l,a,n,i){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:a,tail:l,tailMode:n,treeForkCount:i}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=a,s.tail=l,s.tailMode=n,s.treeForkCount=i)}function Sf(e,t,l){var a=t.pendingProps,n=a.revealOrder,i=a.tail;a=a.children;var s=Ke.current,d=(s&2)!==0;if(d?(s=s&1|2,t.flags|=128):s&=1,V(Ke,s),ot(e,t,a,l),a=be?dn:0,!d&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&xf(e,l,t);else if(e.tag===19)xf(e,l,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(n){case"forwards":for(l=t.child,n=null;l!==null;)e=l.alternate,e!==null&&Ai(e)===null&&(n=l),l=l.sibling;l=n,l===null?(n=t.child,t.child=null):(n=l.sibling,l.sibling=null),hs(t,!1,n,l,i,a);break;case"backwards":case"unstable_legacy-backwards":for(l=null,n=t.child,t.child=null;n!==null;){if(e=n.alternate,e!==null&&Ai(e)===null){t.child=n;break}e=n.sibling,n.sibling=l,l=n,n=e}hs(t,!0,l,null,i,a);break;case"together":hs(t,!1,null,null,void 0,a);break;default:t.memoizedState=null}return t.child}function nl(e,t,l){if(e!==null&&(t.dependencies=e.dependencies),jl|=t.lanes,(l&t.childLanes)===0)if(e!==null){if(ja(e,t,l,!1),(l&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(u(153));if(t.child!==null){for(e=t.child,l=It(e,e.pendingProps),t.child=l,l.return=t;e.sibling!==null;)e=e.sibling,l=l.sibling=It(e,e.pendingProps),l.return=t;l.sibling=null}return t.child}function ps(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&wi(e)))}function Xy(e,t,l){switch(t.tag){case 3:ut(t,t.stateNode.containerInfo),vl(t,$e,e.memoizedState.cache),$l();break;case 27:case 5:Fa(t);break;case 4:ut(t,t.stateNode.containerInfo);break;case 10:vl(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Yc(t),null;break;case 13:var a=t.memoizedState;if(a!==null)return a.dehydrated!==null?(wl(t),t.flags|=128,null):(l&t.child.childLanes)!==0?bf(e,t,l):(wl(t),e=nl(e,t,l),e!==null?e.sibling:null);wl(t);break;case 19:var n=(e.flags&128)!==0;if(a=(l&t.childLanes)!==0,a||(ja(e,t,l,!1),a=(l&t.childLanes)!==0),n){if(a)return Sf(e,t,l);t.flags|=128}if(n=t.memoizedState,n!==null&&(n.rendering=null,n.tail=null,n.lastEffect=null),V(Ke,Ke.current),a)break;return null;case 22:return t.lanes=0,mf(e,t,l,t.pendingProps);case 24:vl(t,$e,e.memoizedState.cache)}return nl(e,t,l)}function wf(e,t,l){if(e!==null)if(e.memoizedProps!==t.pendingProps)Fe=!0;else{if(!ps(e,l)&&(t.flags&128)===0)return Fe=!1,Xy(e,t,l);Fe=(e.flags&131072)!==0}else Fe=!1,be&&(t.flags&1048576)!==0&&e_(t,dn,t.index);switch(t.lanes=0,t.tag){case 16:e:{var a=t.pendingProps;if(e=Pl(t.elementType),t.type=e,typeof e=="function")xc(e)?(a=aa(e,a),t.tag=1,t=gf(null,t,e,a,l)):(t.tag=0,t=us(null,t,e,a,l));else{if(e!=null){var n=e.$$typeof;if(n===F){t.tag=11,t=_f(null,t,e,a,l);break e}else if(n===K){t.tag=14,t=ff(null,t,e,a,l);break e}}throw t=le(e)||e,Error(u(306,t,""))}}return t;case 0:return us(e,t,t.type,t.pendingProps,l);case 1:return a=t.type,n=aa(a,t.pendingProps),gf(e,t,a,n,l);case 3:e:{if(ut(t,t.stateNode.containerInfo),e===null)throw Error(u(387));a=t.pendingProps;var i=t.memoizedState;n=i.element,Uc(e,t),xn(t,a,null,l);var s=t.memoizedState;if(a=s.cache,vl(t,$e,a),a!==i.cache&&Mc(t,[$e],l,!0),bn(),a=s.element,i.isDehydrated)if(i={element:a,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){t=vf(e,t,a,l);break e}else if(a!==n){n=Ht(Error(u(424)),t),mn(n),t=vf(e,t,a,l);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(Ue=Lt(e.firstChild),nt=t,be=!0,yl=null,Rt=!0,l=d_(t,null,a,l),t.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if($l(),a===n){t=nl(e,t,l);break e}ot(e,t,a,l)}t=t.child}return t;case 26:return Gi(e,t),e===null?(l=Od(t.type,null,t.pendingProps,null))?t.memoizedState=l:be||(l=t.type,e=t.pendingProps,a=io(me.current).createElement(l),a[at]=t,a[ft]=e,ct(a,l,e),tt(a),t.stateNode=a):t.memoizedState=Od(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Fa(t),e===null&&be&&(a=t.stateNode=Ad(t.type,t.pendingProps,me.current),nt=t,Rt=!0,n=Ue,Hl(t.type)?($s=n,Ue=Lt(a.firstChild)):Ue=n),ot(e,t,t.pendingProps.children,l),Gi(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&be&&((n=a=Ue)&&(a=vg(a,t.type,t.pendingProps,Rt),a!==null?(t.stateNode=a,nt=t,Ue=Lt(a.firstChild),Rt=!1,n=!0):n=!1),n||gl(t)),Fa(t),n=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,a=i.children,Vs(n,i)?a=null:s!==null&&Vs(n,s)&&(t.flags|=32),t.memoizedState!==null&&(n=Xc(e,t,Oy,null,null,l),Yn._currentValue=n),Gi(e,t),ot(e,t,a,l),t.child;case 6:return e===null&&be&&((e=l=Ue)&&(l=bg(l,t.pendingProps,Rt),l!==null?(t.stateNode=l,nt=t,Ue=null,e=!0):e=!1),e||gl(t)),null;case 13:return bf(e,t,l);case 4:return ut(t,t.stateNode.containerInfo),a=t.pendingProps,e===null?t.child=ta(t,null,a,l):ot(e,t,a,l),t.child;case 11:return _f(e,t,t.type,t.pendingProps,l);case 7:return ot(e,t,t.pendingProps,l),t.child;case 8:return ot(e,t,t.pendingProps.children,l),t.child;case 12:return ot(e,t,t.pendingProps.children,l),t.child;case 10:return a=t.pendingProps,vl(t,t.type,a.value),ot(e,t,a.children,l),t.child;case 9:return n=t.type._context,a=t.pendingProps.children,Fl(t),n=it(n),a=a(n),t.flags|=1,ot(e,t,a,l),t.child;case 14:return ff(e,t,t.type,t.pendingProps,l);case 15:return df(e,t,t.type,t.pendingProps,l);case 19:return Sf(e,t,l);case 31:return Gy(e,t,l);case 22:return mf(e,t,l,t.pendingProps);case 24:return Fl(t),a=it($e),e===null?(n=Dc(),n===null&&(n=Re,i=Ac(),n.pooledCache=i,i.refCount++,i!==null&&(n.pooledCacheLanes|=l),n=i),t.memoizedState={parent:a,cache:n},Rc(t),vl(t,$e,n)):((e.lanes&l)!==0&&(Uc(e,t),xn(t,null,null,l),bn()),n=e.memoizedState,i=t.memoizedState,n.parent!==a?(n={parent:a,cache:a},t.memoizedState=n,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=n),vl(t,$e,a)):(a=i.cache,vl(t,$e,a),a!==n.cache&&Mc(t,[$e],l,!0))),ot(e,t,t.pendingProps.children,l),t.child;case 29:throw t.pendingProps}throw Error(u(156,t.tag))}function il(e){e.flags|=4}function ys(e,t,l,a,n){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(n&335544128)===n)if(e.stateNode.complete)e.flags|=8192;else if(Wf())e.flags|=8192;else throw ea=ji,Oc}else e.flags&=-16777217}function Ef(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!kd(t))if(Wf())e.flags|=8192;else throw ea=ji,Oc}function Vi(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?lr():536870912,e.lanes|=t,ka|=t)}function jn(e,t){if(!be)switch(e.tailMode){case"hidden":t=e.tail;for(var l=null;t!==null;)t.alternate!==null&&(l=t),t=t.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var a=null;l!==null;)l.alternate!==null&&(a=l),l=l.sibling;a===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:a.sibling=null}}function Le(e){var t=e.alternate!==null&&e.alternate.child===e.child,l=0,a=0;if(t)for(var n=e.child;n!==null;)l|=n.lanes|n.childLanes,a|=n.subtreeFlags&65011712,a|=n.flags&65011712,n.return=e,n=n.sibling;else for(n=e.child;n!==null;)l|=n.lanes|n.childLanes,a|=n.subtreeFlags,a|=n.flags,n.return=e,n=n.sibling;return e.subtreeFlags|=a,e.childLanes=l,t}function Vy(e,t,l){var a=t.pendingProps;switch(Tc(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Le(t),null;case 1:return Le(t),null;case 3:return l=t.stateNode,a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),tl($e),Ze(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(Na(t)?il(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,jc())),Le(t),null;case 26:var n=t.type,i=t.memoizedState;return e===null?(il(t),i!==null?(Le(t),Ef(t,i)):(Le(t),ys(t,n,null,a,l))):i?i!==e.memoizedState?(il(t),Le(t),Ef(t,i)):(Le(t),t.flags&=-16777217):(e=e.memoizedProps,e!==a&&il(t),Le(t),ys(t,n,e,a,l)),null;case 27:if(ti(t),l=me.current,n=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&il(t);else{if(!a){if(t.stateNode===null)throw Error(u(166));return Le(t),null}e=W.current,Na(t)?l_(t):(e=Ad(n,a,l),t.stateNode=e,il(t))}return Le(t),null;case 5:if(ti(t),n=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&il(t);else{if(!a){if(t.stateNode===null)throw Error(u(166));return Le(t),null}if(i=W.current,Na(t))l_(t);else{var s=io(me.current);switch(i){case 1:i=s.createElementNS("http://www.w3.org/2000/svg",n);break;case 2:i=s.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;default:switch(n){case"svg":i=s.createElementNS("http://www.w3.org/2000/svg",n);break;case"math":i=s.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;case"script":i=s.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof a.is=="string"?s.createElement("select",{is:a.is}):s.createElement("select"),a.multiple?i.multiple=!0:a.size&&(i.size=a.size);break;default:i=typeof a.is=="string"?s.createElement(n,{is:a.is}):s.createElement(n)}}i[at]=t,i[ft]=a;e:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)i.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break e;for(;s.sibling===null;){if(s.return===null||s.return===t)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=i;e:switch(ct(i,n,a),n){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break e;case"img":a=!0;break e;default:a=!1}a&&il(t)}}return Le(t),ys(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,l),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==a&&il(t);else{if(typeof a!="string"&&t.stateNode===null)throw Error(u(166));if(e=me.current,Na(t)){if(e=t.stateNode,l=t.memoizedProps,a=null,n=nt,n!==null)switch(n.tag){case 27:case 5:a=n.memoizedProps}e[at]=t,e=!!(e.nodeValue===l||a!==null&&a.suppressHydrationWarning===!0||bd(e.nodeValue,l)),e||gl(t,!0)}else e=io(e).createTextNode(a),e[at]=t,t.stateNode=e}return Le(t),null;case 31:if(l=t.memoizedState,e===null||e.memoizedState!==null){if(a=Na(t),l!==null){if(e===null){if(!a)throw Error(u(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(557));e[at]=t}else $l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Le(t),e=!1}else l=jc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),e=!0;if(!e)return t.flags&256?(Tt(t),t):(Tt(t),null);if((t.flags&128)!==0)throw Error(u(558))}return Le(t),null;case 13:if(a=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(n=Na(t),a!==null&&a.dehydrated!==null){if(e===null){if(!n)throw Error(u(318));if(n=t.memoizedState,n=n!==null?n.dehydrated:null,!n)throw Error(u(317));n[at]=t}else $l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Le(t),n=!1}else n=jc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),n=!0;if(!n)return t.flags&256?(Tt(t),t):(Tt(t),null)}return Tt(t),(t.flags&128)!==0?(t.lanes=l,t):(l=a!==null,e=e!==null&&e.memoizedState!==null,l&&(a=t.child,n=null,a.alternate!==null&&a.alternate.memoizedState!==null&&a.alternate.memoizedState.cachePool!==null&&(n=a.alternate.memoizedState.cachePool.pool),i=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(i=a.memoizedState.cachePool.pool),i!==n&&(a.flags|=2048)),l!==e&&l&&(t.child.flags|=8192),Vi(t,t.updateQueue),Le(t),null);case 4:return Ze(),e===null&&ks(t.stateNode.containerInfo),Le(t),null;case 10:return tl(t.type),Le(t),null;case 19:if(B(Ke),a=t.memoizedState,a===null)return Le(t),null;if(n=(t.flags&128)!==0,i=a.rendering,i===null)if(n)jn(a,!1);else{if(Xe!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(i=Ai(e),i!==null){for(t.flags|=128,jn(a,!1),e=i.updateQueue,t.updateQueue=e,Vi(t,e),t.subtreeFlags=0,e=l,l=t.child;l!==null;)Fr(l,e),l=l.sibling;return V(Ke,Ke.current&1|2),be&&Pt(t,a.treeForkCount),t.child}e=e.sibling}a.tail!==null&&vt()>$i&&(t.flags|=128,n=!0,jn(a,!1),t.lanes=4194304)}else{if(!n)if(e=Ai(i),e!==null){if(t.flags|=128,n=!0,e=e.updateQueue,t.updateQueue=e,Vi(t,e),jn(a,!0),a.tail===null&&a.tailMode==="hidden"&&!i.alternate&&!be)return Le(t),null}else 2*vt()-a.renderingStartTime>$i&&l!==536870912&&(t.flags|=128,n=!0,jn(a,!1),t.lanes=4194304);a.isBackwards?(i.sibling=t.child,t.child=i):(e=a.last,e!==null?e.sibling=i:t.child=i,a.last=i)}return a.tail!==null?(e=a.tail,a.rendering=e,a.tail=e.sibling,a.renderingStartTime=vt(),e.sibling=null,l=Ke.current,V(Ke,n?l&1|2:l&1),be&&Pt(t,a.treeForkCount),e):(Le(t),null);case 22:case 23:return Tt(t),qc(),a=t.memoizedState!==null,e!==null?e.memoizedState!==null!==a&&(t.flags|=8192):a&&(t.flags|=8192),a?(l&536870912)!==0&&(t.flags&128)===0&&(Le(t),t.subtreeFlags&6&&(t.flags|=8192)):Le(t),l=t.updateQueue,l!==null&&Vi(t,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),a=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),a!==l&&(t.flags|=2048),e!==null&&B(Il),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),tl($e),Le(t),null;case 25:return null;case 30:return null}throw Error(u(156,t.tag))}function Qy(e,t){switch(Tc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return tl($e),Ze(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ti(t),null;case 31:if(t.memoizedState!==null){if(Tt(t),t.alternate===null)throw Error(u(340));$l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(Tt(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(u(340));$l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return B(Ke),null;case 4:return Ze(),null;case 10:return tl(t.type),null;case 22:case 23:return Tt(t),qc(),e!==null&&B(Il),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return tl($e),null;case 25:return null;default:return null}}function Tf(e,t){switch(Tc(t),t.tag){case 3:tl($e),Ze();break;case 26:case 27:case 5:ti(t);break;case 4:Ze();break;case 31:t.memoizedState!==null&&Tt(t);break;case 13:Tt(t);break;case 19:B(Ke);break;case 10:tl(t.type);break;case 22:case 23:Tt(t),qc(),e!==null&&B(Il);break;case 24:tl($e)}}function Cn(e,t){try{var l=t.updateQueue,a=l!==null?l.lastEffect:null;if(a!==null){var n=a.next;l=n;do{if((l.tag&e)===e){a=void 0;var i=l.create,s=l.inst;a=i(),s.destroy=a}l=l.next}while(l!==n)}}catch(d){Ae(t,t.return,d)}}function Tl(e,t,l){try{var a=t.updateQueue,n=a!==null?a.lastEffect:null;if(n!==null){var i=n.next;a=i;do{if((a.tag&e)===e){var s=a.inst,d=s.destroy;if(d!==void 0){s.destroy=void 0,n=t;var p=l,T=d;try{T()}catch(H){Ae(n,p,H)}}}a=a.next}while(a!==i)}}catch(H){Ae(t,t.return,H)}}function Nf(e){var t=e.updateQueue;if(t!==null){var l=e.stateNode;try{h_(t,l)}catch(a){Ae(e,e.return,a)}}}function jf(e,t,l){l.props=aa(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(a){Ae(e,t,a)}}function zn(e,t){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var a=e.stateNode;break;case 30:a=e.stateNode;break;default:a=e.stateNode}typeof l=="function"?e.refCleanup=l(a):l.current=a}}catch(n){Ae(e,t,n)}}function Qt(e,t){var l=e.ref,a=e.refCleanup;if(l!==null)if(typeof a=="function")try{a()}catch(n){Ae(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(n){Ae(e,t,n)}else l.current=null}function Cf(e){var t=e.type,l=e.memoizedProps,a=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":l.autoFocus&&a.focus();break e;case"img":l.src?a.src=l.src:l.srcSet&&(a.srcset=l.srcSet)}}catch(n){Ae(e,e.return,n)}}function gs(e,t,l){try{var a=e.stateNode;dg(a,e.type,l,t),a[ft]=t}catch(n){Ae(e,e.return,n)}}function zf(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Hl(e.type)||e.tag===4}function vs(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||zf(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Hl(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function bs(e,t,l){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,t):(t=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,t.appendChild(e),l=l._reactRootContainer,l!=null||t.onclick!==null||(t.onclick=Wt));else if(a!==4&&(a===27&&Hl(e.type)&&(l=e.stateNode,t=null),e=e.child,e!==null))for(bs(e,t,l),e=e.sibling;e!==null;)bs(e,t,l),e=e.sibling}function Qi(e,t,l){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?l.insertBefore(e,t):l.appendChild(e);else if(a!==4&&(a===27&&Hl(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(Qi(e,t,l),e=e.sibling;e!==null;)Qi(e,t,l),e=e.sibling}function Mf(e){var t=e.stateNode,l=e.memoizedProps;try{for(var a=e.type,n=t.attributes;n.length;)t.removeAttributeNode(n[0]);ct(t,a,l),t[at]=e,t[ft]=l}catch(i){Ae(e,e.return,i)}}var ol=!1,Ie=!1,xs=!1,Af=typeof WeakSet=="function"?WeakSet:Set,lt=null;function Zy(e,t){if(e=e.containerInfo,Gs=fo,e=Gr(e),mc(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var a=l.getSelection&&l.getSelection();if(a&&a.rangeCount!==0){l=a.anchorNode;var n=a.anchorOffset,i=a.focusNode;a=a.focusOffset;try{l.nodeType,i.nodeType}catch{l=null;break e}var s=0,d=-1,p=-1,T=0,H=0,O=e,N=null;t:for(;;){for(var z;O!==l||n!==0&&O.nodeType!==3||(d=s+n),O!==i||a!==0&&O.nodeType!==3||(p=s+a),O.nodeType===3&&(s+=O.nodeValue.length),(z=O.firstChild)!==null;)N=O,O=z;for(;;){if(O===e)break t;if(N===l&&++T===n&&(d=s),N===i&&++H===a&&(p=s),(z=O.nextSibling)!==null)break;O=N,N=O.parentNode}O=z}l=d===-1||p===-1?null:{start:d,end:p}}else l=null}l=l||{start:0,end:0}}else l=null;for(Xs={focusedElem:e,selectionRange:l},fo=!1,lt=t;lt!==null;)if(t=lt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,lt=e;else for(;lt!==null;){switch(t=lt,i=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(l=0;l<e.length;l++)n=e[l],n.ref.impl=n.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&i!==null){e=void 0,l=t,n=i.memoizedProps,i=i.memoizedState,a=l.stateNode;try{var J=aa(l.type,n);e=a.getSnapshotBeforeUpdate(J,i),a.__reactInternalSnapshotBeforeUpdate=e}catch(ie){Ae(l,l.return,ie)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,l=e.nodeType,l===9)Zs(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Zs(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(u(163))}if(e=t.sibling,e!==null){e.return=t.return,lt=e;break}lt=t.return}}function Hf(e,t,l){var a=l.flags;switch(l.tag){case 0:case 11:case 15:sl(e,l),a&4&&Cn(5,l);break;case 1:if(sl(e,l),a&4)if(e=l.stateNode,t===null)try{e.componentDidMount()}catch(s){Ae(l,l.return,s)}else{var n=aa(l.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(n,t,e.__reactInternalSnapshotBeforeUpdate)}catch(s){Ae(l,l.return,s)}}a&64&&Nf(l),a&512&&zn(l,l.return);break;case 3:if(sl(e,l),a&64&&(e=l.updateQueue,e!==null)){if(t=null,l.child!==null)switch(l.child.tag){case 27:case 5:t=l.child.stateNode;break;case 1:t=l.child.stateNode}try{h_(e,t)}catch(s){Ae(l,l.return,s)}}break;case 27:t===null&&a&4&&Mf(l);case 26:case 5:sl(e,l),t===null&&a&4&&Cf(l),a&512&&zn(l,l.return);break;case 12:sl(e,l);break;case 31:sl(e,l),a&4&&Rf(e,l);break;case 13:sl(e,l),a&4&&Uf(e,l),a&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=tg.bind(null,l),xg(e,l))));break;case 22:if(a=l.memoizedState!==null||ol,!a){t=t!==null&&t.memoizedState!==null||Ie,n=ol;var i=Ie;ol=a,(Ie=t)&&!i?ul(e,l,(l.subtreeFlags&8772)!==0):sl(e,l),ol=n,Ie=i}break;case 30:break;default:sl(e,l)}}function Df(e){var t=e.alternate;t!==null&&(e.alternate=null,Df(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Fo(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var qe=null,mt=!1;function cl(e,t,l){for(l=l.child;l!==null;)Of(e,t,l),l=l.sibling}function Of(e,t,l){if(bt&&typeof bt.onCommitFiberUnmount=="function")try{bt.onCommitFiberUnmount(Ia,l)}catch{}switch(l.tag){case 26:Ie||Qt(l,t),cl(e,t,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Ie||Qt(l,t);var a=qe,n=mt;Hl(l.type)&&(qe=l.stateNode,mt=!1),cl(e,t,l),Bn(l.stateNode),qe=a,mt=n;break;case 5:Ie||Qt(l,t);case 6:if(a=qe,n=mt,qe=null,cl(e,t,l),qe=a,mt=n,qe!==null)if(mt)try{(qe.nodeType===9?qe.body:qe.nodeName==="HTML"?qe.ownerDocument.body:qe).removeChild(l.stateNode)}catch(i){Ae(l,t,i)}else try{qe.removeChild(l.stateNode)}catch(i){Ae(l,t,i)}break;case 18:qe!==null&&(mt?(e=qe,Nd(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),Ka(e)):Nd(qe,l.stateNode));break;case 4:a=qe,n=mt,qe=l.stateNode.containerInfo,mt=!0,cl(e,t,l),qe=a,mt=n;break;case 0:case 11:case 14:case 15:Tl(2,l,t),Ie||Tl(4,l,t),cl(e,t,l);break;case 1:Ie||(Qt(l,t),a=l.stateNode,typeof a.componentWillUnmount=="function"&&jf(l,t,a)),cl(e,t,l);break;case 21:cl(e,t,l);break;case 22:Ie=(a=Ie)||l.memoizedState!==null,cl(e,t,l),Ie=a;break;default:cl(e,t,l)}}function Rf(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Ka(e)}catch(l){Ae(t,t.return,l)}}}function Uf(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Ka(e)}catch(l){Ae(t,t.return,l)}}function Ky(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Af),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Af),t;default:throw Error(u(435,e.tag))}}function Zi(e,t){var l=Ky(e);t.forEach(function(a){if(!l.has(a)){l.add(a);var n=lg.bind(null,e,a);a.then(n,n)}})}function ht(e,t){var l=t.deletions;if(l!==null)for(var a=0;a<l.length;a++){var n=l[a],i=e,s=t,d=s;e:for(;d!==null;){switch(d.tag){case 27:if(Hl(d.type)){qe=d.stateNode,mt=!1;break e}break;case 5:qe=d.stateNode,mt=!1;break e;case 3:case 4:qe=d.stateNode.containerInfo,mt=!0;break e}d=d.return}if(qe===null)throw Error(u(160));Of(i,s,n),qe=null,mt=!1,i=n.alternate,i!==null&&(i.return=null),n.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Lf(t,e),t=t.sibling}var Yt=null;function Lf(e,t){var l=e.alternate,a=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ht(t,e),pt(e),a&4&&(Tl(3,e,e.return),Cn(3,e),Tl(5,e,e.return));break;case 1:ht(t,e),pt(e),a&512&&(Ie||l===null||Qt(l,l.return)),a&64&&ol&&(e=e.updateQueue,e!==null&&(a=e.callbacks,a!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?a:l.concat(a))));break;case 26:var n=Yt;if(ht(t,e),pt(e),a&512&&(Ie||l===null||Qt(l,l.return)),a&4){var i=l!==null?l.memoizedState:null;if(a=e.memoizedState,l===null)if(a===null)if(e.stateNode===null){e:{a=e.type,l=e.memoizedProps,n=n.ownerDocument||n;t:switch(a){case"title":i=n.getElementsByTagName("title")[0],(!i||i[tn]||i[at]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=n.createElement(a),n.head.insertBefore(i,n.querySelector("head > title"))),ct(i,a,l),i[at]=e,tt(i),a=i;break e;case"link":var s=Ld("link","href",n).get(a+(l.href||""));if(s){for(var d=0;d<s.length;d++)if(i=s[d],i.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&i.getAttribute("rel")===(l.rel==null?null:l.rel)&&i.getAttribute("title")===(l.title==null?null:l.title)&&i.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){s.splice(d,1);break t}}i=n.createElement(a),ct(i,a,l),n.head.appendChild(i);break;case"meta":if(s=Ld("meta","content",n).get(a+(l.content||""))){for(d=0;d<s.length;d++)if(i=s[d],i.getAttribute("content")===(l.content==null?null:""+l.content)&&i.getAttribute("name")===(l.name==null?null:l.name)&&i.getAttribute("property")===(l.property==null?null:l.property)&&i.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&i.getAttribute("charset")===(l.charSet==null?null:l.charSet)){s.splice(d,1);break t}}i=n.createElement(a),ct(i,a,l),n.head.appendChild(i);break;default:throw Error(u(468,a))}i[at]=e,tt(i),a=i}e.stateNode=a}else Bd(n,e.type,e.stateNode);else e.stateNode=Ud(n,a,e.memoizedProps);else i!==a?(i===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):i.count--,a===null?Bd(n,e.type,e.stateNode):Ud(n,a,e.memoizedProps)):a===null&&e.stateNode!==null&&gs(e,e.memoizedProps,l.memoizedProps)}break;case 27:ht(t,e),pt(e),a&512&&(Ie||l===null||Qt(l,l.return)),l!==null&&a&4&&gs(e,e.memoizedProps,l.memoizedProps);break;case 5:if(ht(t,e),pt(e),a&512&&(Ie||l===null||Qt(l,l.return)),e.flags&32){n=e.stateNode;try{pa(n,"")}catch(J){Ae(e,e.return,J)}}a&4&&e.stateNode!=null&&(n=e.memoizedProps,gs(e,n,l!==null?l.memoizedProps:n)),a&1024&&(xs=!0);break;case 6:if(ht(t,e),pt(e),a&4){if(e.stateNode===null)throw Error(u(162));a=e.memoizedProps,l=e.stateNode;try{l.nodeValue=a}catch(J){Ae(e,e.return,J)}}break;case 3:if(so=null,n=Yt,Yt=oo(t.containerInfo),ht(t,e),Yt=n,pt(e),a&4&&l!==null&&l.memoizedState.isDehydrated)try{Ka(t.containerInfo)}catch(J){Ae(e,e.return,J)}xs&&(xs=!1,Bf(e));break;case 4:a=Yt,Yt=oo(e.stateNode.containerInfo),ht(t,e),pt(e),Yt=a;break;case 12:ht(t,e),pt(e);break;case 31:ht(t,e),pt(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Zi(e,a)));break;case 13:ht(t,e),pt(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(Ji=vt()),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Zi(e,a)));break;case 22:n=e.memoizedState!==null;var p=l!==null&&l.memoizedState!==null,T=ol,H=Ie;if(ol=T||n,Ie=H||p,ht(t,e),Ie=H,ol=T,pt(e),a&8192)e:for(t=e.stateNode,t._visibility=n?t._visibility&-2:t._visibility|1,n&&(l===null||p||ol||Ie||na(e)),l=null,t=e;;){if(t.tag===5||t.tag===26){if(l===null){p=l=t;try{if(i=p.stateNode,n)s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none";else{d=p.stateNode;var O=p.memoizedProps.style,N=O!=null&&O.hasOwnProperty("display")?O.display:null;d.style.display=N==null||typeof N=="boolean"?"":(""+N).trim()}}catch(J){Ae(p,p.return,J)}}}else if(t.tag===6){if(l===null){p=t;try{p.stateNode.nodeValue=n?"":p.memoizedProps}catch(J){Ae(p,p.return,J)}}}else if(t.tag===18){if(l===null){p=t;try{var z=p.stateNode;n?jd(z,!0):jd(p.stateNode,!1)}catch(J){Ae(p,p.return,J)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;l===t&&(l=null),t=t.return}l===t&&(l=null),t.sibling.return=t.return,t=t.sibling}a&4&&(a=e.updateQueue,a!==null&&(l=a.retryQueue,l!==null&&(a.retryQueue=null,Zi(e,l))));break;case 19:ht(t,e),pt(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Zi(e,a)));break;case 30:break;case 21:break;default:ht(t,e),pt(e)}}function pt(e){var t=e.flags;if(t&2){try{for(var l,a=e.return;a!==null;){if(zf(a)){l=a;break}a=a.return}if(l==null)throw Error(u(160));switch(l.tag){case 27:var n=l.stateNode,i=vs(e);Qi(e,i,n);break;case 5:var s=l.stateNode;l.flags&32&&(pa(s,""),l.flags&=-33);var d=vs(e);Qi(e,d,s);break;case 3:case 4:var p=l.stateNode.containerInfo,T=vs(e);bs(e,T,p);break;default:throw Error(u(161))}}catch(H){Ae(e,e.return,H)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Bf(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Bf(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function sl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Hf(e,t.alternate,t),t=t.sibling}function na(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Tl(4,t,t.return),na(t);break;case 1:Qt(t,t.return);var l=t.stateNode;typeof l.componentWillUnmount=="function"&&jf(t,t.return,l),na(t);break;case 27:Bn(t.stateNode);case 26:case 5:Qt(t,t.return),na(t);break;case 22:t.memoizedState===null&&na(t);break;case 30:na(t);break;default:na(t)}e=e.sibling}}function ul(e,t,l){for(l=l&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var a=t.alternate,n=e,i=t,s=i.flags;switch(i.tag){case 0:case 11:case 15:ul(n,i,l),Cn(4,i);break;case 1:if(ul(n,i,l),a=i,n=a.stateNode,typeof n.componentDidMount=="function")try{n.componentDidMount()}catch(T){Ae(a,a.return,T)}if(a=i,n=a.updateQueue,n!==null){var d=a.stateNode;try{var p=n.shared.hiddenCallbacks;if(p!==null)for(n.shared.hiddenCallbacks=null,n=0;n<p.length;n++)m_(p[n],d)}catch(T){Ae(a,a.return,T)}}l&&s&64&&Nf(i),zn(i,i.return);break;case 27:Mf(i);case 26:case 5:ul(n,i,l),l&&a===null&&s&4&&Cf(i),zn(i,i.return);break;case 12:ul(n,i,l);break;case 31:ul(n,i,l),l&&s&4&&Rf(n,i);break;case 13:ul(n,i,l),l&&s&4&&Uf(n,i);break;case 22:i.memoizedState===null&&ul(n,i,l),zn(i,i.return);break;case 30:break;default:ul(n,i,l)}t=t.sibling}}function Ss(e,t){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&hn(l))}function ws(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&hn(e))}function Gt(e,t,l,a){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)kf(e,t,l,a),t=t.sibling}function kf(e,t,l,a){var n=t.flags;switch(t.tag){case 0:case 11:case 15:Gt(e,t,l,a),n&2048&&Cn(9,t);break;case 1:Gt(e,t,l,a);break;case 3:Gt(e,t,l,a),n&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&hn(e)));break;case 12:if(n&2048){Gt(e,t,l,a),e=t.stateNode;try{var i=t.memoizedProps,s=i.id,d=i.onPostCommit;typeof d=="function"&&d(s,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(p){Ae(t,t.return,p)}}else Gt(e,t,l,a);break;case 31:Gt(e,t,l,a);break;case 13:Gt(e,t,l,a);break;case 23:break;case 22:i=t.stateNode,s=t.alternate,t.memoizedState!==null?i._visibility&2?Gt(e,t,l,a):Mn(e,t):i._visibility&2?Gt(e,t,l,a):(i._visibility|=2,Ua(e,t,l,a,(t.subtreeFlags&10256)!==0||!1)),n&2048&&Ss(s,t);break;case 24:Gt(e,t,l,a),n&2048&&ws(t.alternate,t);break;default:Gt(e,t,l,a)}}function Ua(e,t,l,a,n){for(n=n&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var i=e,s=t,d=l,p=a,T=s.flags;switch(s.tag){case 0:case 11:case 15:Ua(i,s,d,p,n),Cn(8,s);break;case 23:break;case 22:var H=s.stateNode;s.memoizedState!==null?H._visibility&2?Ua(i,s,d,p,n):Mn(i,s):(H._visibility|=2,Ua(i,s,d,p,n)),n&&T&2048&&Ss(s.alternate,s);break;case 24:Ua(i,s,d,p,n),n&&T&2048&&ws(s.alternate,s);break;default:Ua(i,s,d,p,n)}t=t.sibling}}function Mn(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var l=e,a=t,n=a.flags;switch(a.tag){case 22:Mn(l,a),n&2048&&Ss(a.alternate,a);break;case 24:Mn(l,a),n&2048&&ws(a.alternate,a);break;default:Mn(l,a)}t=t.sibling}}var An=8192;function La(e,t,l){if(e.subtreeFlags&An)for(e=e.child;e!==null;)qf(e,t,l),e=e.sibling}function qf(e,t,l){switch(e.tag){case 26:La(e,t,l),e.flags&An&&e.memoizedState!==null&&Dg(l,Yt,e.memoizedState,e.memoizedProps);break;case 5:La(e,t,l);break;case 3:case 4:var a=Yt;Yt=oo(e.stateNode.containerInfo),La(e,t,l),Yt=a;break;case 22:e.memoizedState===null&&(a=e.alternate,a!==null&&a.memoizedState!==null?(a=An,An=16777216,La(e,t,l),An=a):La(e,t,l));break;default:La(e,t,l)}}function Yf(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Hn(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var a=t[l];lt=a,Xf(a,e)}Yf(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Gf(e),e=e.sibling}function Gf(e){switch(e.tag){case 0:case 11:case 15:Hn(e),e.flags&2048&&Tl(9,e,e.return);break;case 3:Hn(e);break;case 12:Hn(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Ki(e)):Hn(e);break;default:Hn(e)}}function Ki(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var a=t[l];lt=a,Xf(a,e)}Yf(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Tl(8,t,t.return),Ki(t);break;case 22:l=t.stateNode,l._visibility&2&&(l._visibility&=-3,Ki(t));break;default:Ki(t)}e=e.sibling}}function Xf(e,t){for(;lt!==null;){var l=lt;switch(l.tag){case 0:case 11:case 15:Tl(8,l,t);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var a=l.memoizedState.cachePool.pool;a!=null&&a.refCount++}break;case 24:hn(l.memoizedState.cache)}if(a=l.child,a!==null)a.return=l,lt=a;else e:for(l=e;lt!==null;){a=lt;var n=a.sibling,i=a.return;if(Df(a),a===l){lt=null;break e}if(n!==null){n.return=i,lt=n;break e}lt=i}}}var Jy={getCacheForType:function(e){var t=it($e),l=t.data.get(e);return l===void 0&&(l=e(),t.data.set(e,l)),l},cacheSignal:function(){return it($e).controller.signal}},$y=typeof WeakMap=="function"?WeakMap:Map,Ne=0,Re=null,he=null,ye=0,Me=0,Nt=null,Nl=!1,Ba=!1,Es=!1,rl=0,Xe=0,jl=0,ia=0,Ts=0,jt=0,ka=0,Dn=null,yt=null,Ns=!1,Ji=0,Vf=0,$i=1/0,Wi=null,Cl=null,et=0,zl=null,qa=null,_l=0,js=0,Cs=null,Qf=null,On=0,zs=null;function Ct(){return(Ne&2)!==0&&ye!==0?ye&-ye:M.T!==null?Rs():or()}function Zf(){if(jt===0)if((ye&536870912)===0||be){var e=ni;ni<<=1,(ni&3932160)===0&&(ni=262144),jt=e}else jt=536870912;return e=Et.current,e!==null&&(e.flags|=32),jt}function gt(e,t,l){(e===Re&&(Me===2||Me===9)||e.cancelPendingCommit!==null)&&(Ya(e,0),Ml(e,ye,jt,!1)),en(e,l),((Ne&2)===0||e!==Re)&&(e===Re&&((Ne&2)===0&&(ia|=l),Xe===4&&Ml(e,ye,jt,!1)),Zt(e))}function Kf(e,t,l){if((Ne&6)!==0)throw Error(u(327));var a=!l&&(t&127)===0&&(t&e.expiredLanes)===0||Pa(e,t),n=a?Iy(e,t):As(e,t,!0),i=a;do{if(n===0){Ba&&!a&&Ml(e,t,0,!1);break}else{if(l=e.current.alternate,i&&!Wy(l)){n=As(e,t,!1),i=!1;continue}if(n===2){if(i=t,e.errorRecoveryDisabledLanes&i)var s=0;else s=e.pendingLanes&-536870913,s=s!==0?s:s&536870912?536870912:0;if(s!==0){t=s;e:{var d=e;n=Dn;var p=d.current.memoizedState.isDehydrated;if(p&&(Ya(d,s).flags|=256),s=As(d,s,!1),s!==2){if(Es&&!p){d.errorRecoveryDisabledLanes|=i,ia|=i,n=4;break e}i=yt,yt=n,i!==null&&(yt===null?yt=i:yt.push.apply(yt,i))}n=s}if(i=!1,n!==2)continue}}if(n===1){Ya(e,0),Ml(e,t,0,!0);break}e:{switch(a=e,i=n,i){case 0:case 1:throw Error(u(345));case 4:if((t&4194048)!==t)break;case 6:Ml(a,t,jt,!Nl);break e;case 2:yt=null;break;case 3:case 5:break;default:throw Error(u(329))}if((t&62914560)===t&&(n=Ji+300-vt(),10<n)){if(Ml(a,t,jt,!Nl),oi(a,0,!0)!==0)break e;_l=t,a.timeoutHandle=Ed(Jf.bind(null,a,l,yt,Wi,Ns,t,jt,ia,ka,Nl,i,"Throttled",-0,0),n);break e}Jf(a,l,yt,Wi,Ns,t,jt,ia,ka,Nl,i,null,-0,0)}}break}while(!0);Zt(e)}function Jf(e,t,l,a,n,i,s,d,p,T,H,O,N,z){if(e.timeoutHandle=-1,O=t.subtreeFlags,O&8192||(O&16785408)===16785408){O={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Wt},qf(t,i,O);var J=(i&62914560)===i?Ji-vt():(i&4194048)===i?Vf-vt():0;if(J=Og(O,J),J!==null){_l=i,e.cancelPendingCommit=J(ld.bind(null,e,t,i,l,a,n,s,d,p,H,O,null,N,z)),Ml(e,i,s,!T);return}}ld(e,t,i,l,a,n,s,d,p)}function Wy(e){for(var t=e;;){var l=t.tag;if((l===0||l===11||l===15)&&t.flags&16384&&(l=t.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var a=0;a<l.length;a++){var n=l[a],i=n.getSnapshot;n=n.value;try{if(!St(i(),n))return!1}catch{return!1}}if(l=t.child,t.subtreeFlags&16384&&l!==null)l.return=t,t=l;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ml(e,t,l,a){t&=~Ts,t&=~ia,e.suspendedLanes|=t,e.pingedLanes&=~t,a&&(e.warmLanes|=t),a=e.expirationTimes;for(var n=t;0<n;){var i=31-xt(n),s=1<<i;a[i]=-1,n&=~s}l!==0&&ar(e,l,t)}function Fi(){return(Ne&6)===0?(Rn(0),!1):!0}function Ms(){if(he!==null){if(Me===0)var e=he.return;else e=he,el=Wl=null,Zc(e),Aa=null,yn=0,e=he;for(;e!==null;)Tf(e.alternate,e),e=e.return;he=null}}function Ya(e,t){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,pg(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),_l=0,Ms(),Re=e,he=l=It(e.current,null),ye=t,Me=0,Nt=null,Nl=!1,Ba=Pa(e,t),Es=!1,ka=jt=Ts=ia=jl=Xe=0,yt=Dn=null,Ns=!1,(t&8)!==0&&(t|=t&32);var a=e.entangledLanes;if(a!==0)for(e=e.entanglements,a&=t;0<a;){var n=31-xt(a),i=1<<n;t|=e[n],a&=~i}return rl=t,gi(),l}function $f(e,t){re=null,M.H=Tn,t===Ma||t===Ni?(t=r_(),Me=3):t===Oc?(t=r_(),Me=4):Me=t===ss?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,Nt=t,he===null&&(Xe=1,qi(e,Ht(t,e.current)))}function Wf(){var e=Et.current;return e===null?!0:(ye&4194048)===ye?Ut===null:(ye&62914560)===ye||(ye&536870912)!==0?e===Ut:!1}function Ff(){var e=M.H;return M.H=Tn,e===null?Tn:e}function If(){var e=M.A;return M.A=Jy,e}function Ii(){Xe=4,Nl||(ye&4194048)!==ye&&Et.current!==null||(Ba=!0),(jl&134217727)===0&&(ia&134217727)===0||Re===null||Ml(Re,ye,jt,!1)}function As(e,t,l){var a=Ne;Ne|=2;var n=Ff(),i=If();(Re!==e||ye!==t)&&(Wi=null,Ya(e,t)),t=!1;var s=Xe;e:do try{if(Me!==0&&he!==null){var d=he,p=Nt;switch(Me){case 8:Ms(),s=6;break e;case 3:case 2:case 9:case 6:Et.current===null&&(t=!0);var T=Me;if(Me=0,Nt=null,Ga(e,d,p,T),l&&Ba){s=0;break e}break;default:T=Me,Me=0,Nt=null,Ga(e,d,p,T)}}Fy(),s=Xe;break}catch(H){$f(e,H)}while(!0);return t&&e.shellSuspendCounter++,el=Wl=null,Ne=a,M.H=n,M.A=i,he===null&&(Re=null,ye=0,gi()),s}function Fy(){for(;he!==null;)Pf(he)}function Iy(e,t){var l=Ne;Ne|=2;var a=Ff(),n=If();Re!==e||ye!==t?(Wi=null,$i=vt()+500,Ya(e,t)):Ba=Pa(e,t);e:do try{if(Me!==0&&he!==null){t=he;var i=Nt;t:switch(Me){case 1:Me=0,Nt=null,Ga(e,t,i,1);break;case 2:case 9:if(s_(i)){Me=0,Nt=null,ed(t);break}t=function(){Me!==2&&Me!==9||Re!==e||(Me=7),Zt(e)},i.then(t,t);break e;case 3:Me=7;break e;case 4:Me=5;break e;case 7:s_(i)?(Me=0,Nt=null,ed(t)):(Me=0,Nt=null,Ga(e,t,i,7));break;case 5:var s=null;switch(he.tag){case 26:s=he.memoizedState;case 5:case 27:var d=he;if(s?kd(s):d.stateNode.complete){Me=0,Nt=null;var p=d.sibling;if(p!==null)he=p;else{var T=d.return;T!==null?(he=T,Pi(T)):he=null}break t}}Me=0,Nt=null,Ga(e,t,i,5);break;case 6:Me=0,Nt=null,Ga(e,t,i,6);break;case 8:Ms(),Xe=6;break e;default:throw Error(u(462))}}Py();break}catch(H){$f(e,H)}while(!0);return el=Wl=null,M.H=a,M.A=n,Ne=l,he!==null?0:(Re=null,ye=0,gi(),Xe)}function Py(){for(;he!==null&&!Sp();)Pf(he)}function Pf(e){var t=wf(e.alternate,e,rl);e.memoizedProps=e.pendingProps,t===null?Pi(e):he=t}function ed(e){var t=e,l=t.alternate;switch(t.tag){case 15:case 0:t=yf(l,t,t.pendingProps,t.type,void 0,ye);break;case 11:t=yf(l,t,t.pendingProps,t.type.render,t.ref,ye);break;case 5:Zc(t);default:Tf(l,t),t=he=Fr(t,rl),t=wf(l,t,rl)}e.memoizedProps=e.pendingProps,t===null?Pi(e):he=t}function Ga(e,t,l,a){el=Wl=null,Zc(t),Aa=null,yn=0;var n=t.return;try{if(Yy(e,n,t,l,ye)){Xe=1,qi(e,Ht(l,e.current)),he=null;return}}catch(i){if(n!==null)throw he=n,i;Xe=1,qi(e,Ht(l,e.current)),he=null;return}t.flags&32768?(be||a===1?e=!0:Ba||(ye&536870912)!==0?e=!1:(Nl=e=!0,(a===2||a===9||a===3||a===6)&&(a=Et.current,a!==null&&a.tag===13&&(a.flags|=16384))),td(t,e)):Pi(t)}function Pi(e){var t=e;do{if((t.flags&32768)!==0){td(t,Nl);return}e=t.return;var l=Vy(t.alternate,t,rl);if(l!==null){he=l;return}if(t=t.sibling,t!==null){he=t;return}he=t=e}while(t!==null);Xe===0&&(Xe=5)}function td(e,t){do{var l=Qy(e.alternate,e);if(l!==null){l.flags&=32767,he=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!t&&(e=e.sibling,e!==null)){he=e;return}he=e=l}while(e!==null);Xe=6,he=null}function ld(e,t,l,a,n,i,s,d,p){e.cancelPendingCommit=null;do eo();while(et!==0);if((Ne&6)!==0)throw Error(u(327));if(t!==null){if(t===e.current)throw Error(u(177));if(i=t.lanes|t.childLanes,i|=vc,Hp(e,l,i,s,d,p),e===Re&&(he=Re=null,ye=0),qa=t,zl=e,_l=l,js=i,Cs=n,Qf=a,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,ag(li,function(){return cd(),null})):(e.callbackNode=null,e.callbackPriority=0),a=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||a){a=M.T,M.T=null,n=U.p,U.p=2,s=Ne,Ne|=4;try{Zy(e,t,l)}finally{Ne=s,U.p=n,M.T=a}}et=1,ad(),nd(),id()}}function ad(){if(et===1){et=0;var e=zl,t=qa,l=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||l){l=M.T,M.T=null;var a=U.p;U.p=2;var n=Ne;Ne|=4;try{Lf(t,e);var i=Xs,s=Gr(e.containerInfo),d=i.focusedElem,p=i.selectionRange;if(s!==d&&d&&d.ownerDocument&&Yr(d.ownerDocument.documentElement,d)){if(p!==null&&mc(d)){var T=p.start,H=p.end;if(H===void 0&&(H=T),"selectionStart"in d)d.selectionStart=T,d.selectionEnd=Math.min(H,d.value.length);else{var O=d.ownerDocument||document,N=O&&O.defaultView||window;if(N.getSelection){var z=N.getSelection(),J=d.textContent.length,ie=Math.min(p.start,J),Oe=p.end===void 0?ie:Math.min(p.end,J);!z.extend&&ie>Oe&&(s=Oe,Oe=ie,ie=s);var w=qr(d,ie),v=qr(d,Oe);if(w&&v&&(z.rangeCount!==1||z.anchorNode!==w.node||z.anchorOffset!==w.offset||z.focusNode!==v.node||z.focusOffset!==v.offset)){var E=O.createRange();E.setStart(w.node,w.offset),z.removeAllRanges(),ie>Oe?(z.addRange(E),z.extend(v.node,v.offset)):(E.setEnd(v.node,v.offset),z.addRange(E))}}}}for(O=[],z=d;z=z.parentNode;)z.nodeType===1&&O.push({element:z,left:z.scrollLeft,top:z.scrollTop});for(typeof d.focus=="function"&&d.focus(),d=0;d<O.length;d++){var D=O[d];D.element.scrollLeft=D.left,D.element.scrollTop=D.top}}fo=!!Gs,Xs=Gs=null}finally{Ne=n,U.p=a,M.T=l}}e.current=t,et=2}}function nd(){if(et===2){et=0;var e=zl,t=qa,l=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||l){l=M.T,M.T=null;var a=U.p;U.p=2;var n=Ne;Ne|=4;try{Hf(e,t.alternate,t)}finally{Ne=n,U.p=a,M.T=l}}et=3}}function id(){if(et===4||et===3){et=0,wp();var e=zl,t=qa,l=_l,a=Qf;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?et=5:(et=0,qa=zl=null,od(e,e.pendingLanes));var n=e.pendingLanes;if(n===0&&(Cl=null),$o(l),t=t.stateNode,bt&&typeof bt.onCommitFiberRoot=="function")try{bt.onCommitFiberRoot(Ia,t,void 0,(t.current.flags&128)===128)}catch{}if(a!==null){t=M.T,n=U.p,U.p=2,M.T=null;try{for(var i=e.onRecoverableError,s=0;s<a.length;s++){var d=a[s];i(d.value,{componentStack:d.stack})}}finally{M.T=t,U.p=n}}(_l&3)!==0&&eo(),Zt(e),n=e.pendingLanes,(l&261930)!==0&&(n&42)!==0?e===zs?On++:(On=0,zs=e):On=0,Rn(0)}}function od(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,hn(t)))}function eo(){return ad(),nd(),id(),cd()}function cd(){if(et!==5)return!1;var e=zl,t=js;js=0;var l=$o(_l),a=M.T,n=U.p;try{U.p=32>l?32:l,M.T=null,l=Cs,Cs=null;var i=zl,s=_l;if(et=0,qa=zl=null,_l=0,(Ne&6)!==0)throw Error(u(331));var d=Ne;if(Ne|=4,Gf(i.current),kf(i,i.current,s,l),Ne=d,Rn(0,!1),bt&&typeof bt.onPostCommitFiberRoot=="function")try{bt.onPostCommitFiberRoot(Ia,i)}catch{}return!0}finally{U.p=n,M.T=a,od(e,t)}}function sd(e,t,l){t=Ht(l,t),t=cs(e.stateNode,t,2),e=Sl(e,t,2),e!==null&&(en(e,2),Zt(e))}function Ae(e,t,l){if(e.tag===3)sd(e,e,l);else for(;t!==null;){if(t.tag===3){sd(t,e,l);break}else if(t.tag===1){var a=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof a.componentDidCatch=="function"&&(Cl===null||!Cl.has(a))){e=Ht(l,e),l=uf(2),a=Sl(t,l,2),a!==null&&(rf(l,a,t,e),en(a,2),Zt(a));break}}t=t.return}}function Hs(e,t,l){var a=e.pingCache;if(a===null){a=e.pingCache=new $y;var n=new Set;a.set(t,n)}else n=a.get(t),n===void 0&&(n=new Set,a.set(t,n));n.has(l)||(Es=!0,n.add(l),e=eg.bind(null,e,t,l),t.then(e,e))}function eg(e,t,l){var a=e.pingCache;a!==null&&a.delete(t),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,Re===e&&(ye&l)===l&&(Xe===4||Xe===3&&(ye&62914560)===ye&&300>vt()-Ji?(Ne&2)===0&&Ya(e,0):Ts|=l,ka===ye&&(ka=0)),Zt(e)}function ud(e,t){t===0&&(t=lr()),e=Kl(e,t),e!==null&&(en(e,t),Zt(e))}function tg(e){var t=e.memoizedState,l=0;t!==null&&(l=t.retryLane),ud(e,l)}function lg(e,t){var l=0;switch(e.tag){case 31:case 13:var a=e.stateNode,n=e.memoizedState;n!==null&&(l=n.retryLane);break;case 19:a=e.stateNode;break;case 22:a=e.stateNode._retryCache;break;default:throw Error(u(314))}a!==null&&a.delete(t),ud(e,l)}function ag(e,t){return Qo(e,t)}var to=null,Xa=null,Ds=!1,lo=!1,Os=!1,Al=0;function Zt(e){e!==Xa&&e.next===null&&(Xa===null?to=Xa=e:Xa=Xa.next=e),lo=!0,Ds||(Ds=!0,ig())}function Rn(e,t){if(!Os&&lo){Os=!0;do for(var l=!1,a=to;a!==null;){if(e!==0){var n=a.pendingLanes;if(n===0)var i=0;else{var s=a.suspendedLanes,d=a.pingedLanes;i=(1<<31-xt(42|e)+1)-1,i&=n&~(s&~d),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(l=!0,dd(a,i))}else i=ye,i=oi(a,a===Re?i:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),(i&3)===0||Pa(a,i)||(l=!0,dd(a,i));a=a.next}while(l);Os=!1}}function ng(){rd()}function rd(){lo=Ds=!1;var e=0;Al!==0&&hg()&&(e=Al);for(var t=vt(),l=null,a=to;a!==null;){var n=a.next,i=_d(a,t);i===0?(a.next=null,l===null?to=n:l.next=n,n===null&&(Xa=l)):(l=a,(e!==0||(i&3)!==0)&&(lo=!0)),a=n}et!==0&&et!==5||Rn(e),Al!==0&&(Al=0)}function _d(e,t){for(var l=e.suspendedLanes,a=e.pingedLanes,n=e.expirationTimes,i=e.pendingLanes&-62914561;0<i;){var s=31-xt(i),d=1<<s,p=n[s];p===-1?((d&l)===0||(d&a)!==0)&&(n[s]=Ap(d,t)):p<=t&&(e.expiredLanes|=d),i&=~d}if(t=Re,l=ye,l=oi(e,e===t?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a=e.callbackNode,l===0||e===t&&(Me===2||Me===9)||e.cancelPendingCommit!==null)return a!==null&&a!==null&&Zo(a),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||Pa(e,l)){if(t=l&-l,t===e.callbackPriority)return t;switch(a!==null&&Zo(a),$o(l)){case 2:case 8:l=er;break;case 32:l=li;break;case 268435456:l=tr;break;default:l=li}return a=fd.bind(null,e),l=Qo(l,a),e.callbackPriority=t,e.callbackNode=l,t}return a!==null&&a!==null&&Zo(a),e.callbackPriority=2,e.callbackNode=null,2}function fd(e,t){if(et!==0&&et!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(eo()&&e.callbackNode!==l)return null;var a=ye;return a=oi(e,e===Re?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a===0?null:(Kf(e,a,t),_d(e,vt()),e.callbackNode!=null&&e.callbackNode===l?fd.bind(null,e):null)}function dd(e,t){if(eo())return null;Kf(e,t,!0)}function ig(){yg(function(){(Ne&6)!==0?Qo(Pu,ng):rd()})}function Rs(){if(Al===0){var e=Ca;e===0&&(e=ai,ai<<=1,(ai&261888)===0&&(ai=256)),Al=e}return Al}function md(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:ri(""+e)}function hd(e,t){var l=t.ownerDocument.createElement("input");return l.name=t.name,l.value=t.value,e.id&&l.setAttribute("form",e.id),t.parentNode.insertBefore(l,t),e=new FormData(e),l.parentNode.removeChild(l),e}function og(e,t,l,a,n){if(t==="submit"&&l&&l.stateNode===n){var i=md((n[ft]||null).action),s=a.submitter;s&&(t=(t=s[ft]||null)?md(t.formAction):s.getAttribute("formAction"),t!==null&&(i=t,s=null));var d=new mi("action","action",null,a,n);e.push({event:d,listeners:[{instance:null,listener:function(){if(a.defaultPrevented){if(Al!==0){var p=s?hd(n,s):new FormData(n);ts(l,{pending:!0,data:p,method:n.method,action:i},null,p)}}else typeof i=="function"&&(d.preventDefault(),p=s?hd(n,s):new FormData(n),ts(l,{pending:!0,data:p,method:n.method,action:i},i,p))},currentTarget:n}]})}}for(var Us=0;Us<gc.length;Us++){var Ls=gc[Us],cg=Ls.toLowerCase(),sg=Ls[0].toUpperCase()+Ls.slice(1);qt(cg,"on"+sg)}qt(Qr,"onAnimationEnd"),qt(Zr,"onAnimationIteration"),qt(Kr,"onAnimationStart"),qt("dblclick","onDoubleClick"),qt("focusin","onFocus"),qt("focusout","onBlur"),qt(Ey,"onTransitionRun"),qt(Ty,"onTransitionStart"),qt(Ny,"onTransitionCancel"),qt(Jr,"onTransitionEnd"),ma("onMouseEnter",["mouseout","mouseover"]),ma("onMouseLeave",["mouseout","mouseover"]),ma("onPointerEnter",["pointerout","pointerover"]),ma("onPointerLeave",["pointerout","pointerover"]),Xl("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Xl("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Xl("onBeforeInput",["compositionend","keypress","textInput","paste"]),Xl("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Xl("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Xl("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Un="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),ug=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Un));function pd(e,t){t=(t&4)!==0;for(var l=0;l<e.length;l++){var a=e[l],n=a.event;a=a.listeners;e:{var i=void 0;if(t)for(var s=a.length-1;0<=s;s--){var d=a[s],p=d.instance,T=d.currentTarget;if(d=d.listener,p!==i&&n.isPropagationStopped())break e;i=d,n.currentTarget=T;try{i(n)}catch(H){yi(H)}n.currentTarget=null,i=p}else for(s=0;s<a.length;s++){if(d=a[s],p=d.instance,T=d.currentTarget,d=d.listener,p!==i&&n.isPropagationStopped())break e;i=d,n.currentTarget=T;try{i(n)}catch(H){yi(H)}n.currentTarget=null,i=p}}}}function pe(e,t){var l=t[Wo];l===void 0&&(l=t[Wo]=new Set);var a=e+"__bubble";l.has(a)||(yd(t,e,2,!1),l.add(a))}function Bs(e,t,l){var a=0;t&&(a|=4),yd(l,e,a,t)}var ao="_reactListening"+Math.random().toString(36).slice(2);function ks(e){if(!e[ao]){e[ao]=!0,ur.forEach(function(l){l!=="selectionchange"&&(ug.has(l)||Bs(l,!1,e),Bs(l,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[ao]||(t[ao]=!0,Bs("selectionchange",!1,t))}}function yd(e,t,l,a){switch(Zd(t)){case 2:var n=Lg;break;case 8:n=Bg;break;default:n=eu}l=n.bind(null,t,l,e),n=void 0,!ic||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(n=!0),a?n!==void 0?e.addEventListener(t,l,{capture:!0,passive:n}):e.addEventListener(t,l,!0):n!==void 0?e.addEventListener(t,l,{passive:n}):e.addEventListener(t,l,!1)}function qs(e,t,l,a,n){var i=a;if((t&1)===0&&(t&2)===0&&a!==null)e:for(;;){if(a===null)return;var s=a.tag;if(s===3||s===4){var d=a.stateNode.containerInfo;if(d===n)break;if(s===4)for(s=a.return;s!==null;){var p=s.tag;if((p===3||p===4)&&s.stateNode.containerInfo===n)return;s=s.return}for(;d!==null;){if(s=_a(d),s===null)return;if(p=s.tag,p===5||p===6||p===26||p===27){a=i=s;continue e}d=d.parentNode}}a=a.return}xr(function(){var T=i,H=ac(l),O=[];e:{var N=$r.get(e);if(N!==void 0){var z=mi,J=e;switch(e){case"keypress":if(fi(l)===0)break e;case"keydown":case"keyup":z=ly;break;case"focusin":J="focus",z=uc;break;case"focusout":J="blur",z=uc;break;case"beforeblur":case"afterblur":z=uc;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":z=Er;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":z=Vp;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":z=iy;break;case Qr:case Zr:case Kr:z=Kp;break;case Jr:z=cy;break;case"scroll":case"scrollend":z=Gp;break;case"wheel":z=uy;break;case"copy":case"cut":case"paste":z=$p;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":z=Nr;break;case"toggle":case"beforetoggle":z=_y}var ie=(t&4)!==0,Oe=!ie&&(e==="scroll"||e==="scrollend"),w=ie?N!==null?N+"Capture":null:N;ie=[];for(var v=T,E;v!==null;){var D=v;if(E=D.stateNode,D=D.tag,D!==5&&D!==26&&D!==27||E===null||w===null||(D=an(v,w),D!=null&&ie.push(Ln(v,D,E))),Oe)break;v=v.return}0<ie.length&&(N=new z(N,J,null,l,H),O.push({event:N,listeners:ie}))}}if((t&7)===0){e:{if(N=e==="mouseover"||e==="pointerover",z=e==="mouseout"||e==="pointerout",N&&l!==lc&&(J=l.relatedTarget||l.fromElement)&&(_a(J)||J[ra]))break e;if((z||N)&&(N=H.window===H?H:(N=H.ownerDocument)?N.defaultView||N.parentWindow:window,z?(J=l.relatedTarget||l.toElement,z=T,J=J?_a(J):null,J!==null&&(Oe=m(J),ie=J.tag,J!==Oe||ie!==5&&ie!==27&&ie!==6)&&(J=null)):(z=null,J=T),z!==J)){if(ie=Er,D="onMouseLeave",w="onMouseEnter",v="mouse",(e==="pointerout"||e==="pointerover")&&(ie=Nr,D="onPointerLeave",w="onPointerEnter",v="pointer"),Oe=z==null?N:ln(z),E=J==null?N:ln(J),N=new ie(D,v+"leave",z,l,H),N.target=Oe,N.relatedTarget=E,D=null,_a(H)===T&&(ie=new ie(w,v+"enter",J,l,H),ie.target=E,ie.relatedTarget=Oe,D=ie),Oe=D,z&&J)t:{for(ie=rg,w=z,v=J,E=0,D=w;D;D=ie(D))E++;D=0;for(var te=v;te;te=ie(te))D++;for(;0<E-D;)w=ie(w),E--;for(;0<D-E;)v=ie(v),D--;for(;E--;){if(w===v||v!==null&&w===v.alternate){ie=w;break t}w=ie(w),v=ie(v)}ie=null}else ie=null;z!==null&&gd(O,N,z,ie,!1),J!==null&&Oe!==null&&gd(O,Oe,J,ie,!0)}}e:{if(N=T?ln(T):window,z=N.nodeName&&N.nodeName.toLowerCase(),z==="select"||z==="input"&&N.type==="file")var Se=Or;else if(Hr(N))if(Rr)Se=xy;else{Se=vy;var I=gy}else z=N.nodeName,!z||z.toLowerCase()!=="input"||N.type!=="checkbox"&&N.type!=="radio"?T&&tc(T.elementType)&&(Se=Or):Se=by;if(Se&&(Se=Se(e,T))){Dr(O,Se,l,H);break e}I&&I(e,N,T),e==="focusout"&&T&&N.type==="number"&&T.memoizedProps.value!=null&&ec(N,"number",N.value)}switch(I=T?ln(T):window,e){case"focusin":(Hr(I)||I.contentEditable==="true")&&(ba=I,hc=T,fn=null);break;case"focusout":fn=hc=ba=null;break;case"mousedown":pc=!0;break;case"contextmenu":case"mouseup":case"dragend":pc=!1,Xr(O,l,H);break;case"selectionchange":if(wy)break;case"keydown":case"keyup":Xr(O,l,H)}var fe;if(_c)e:{switch(e){case"compositionstart":var ge="onCompositionStart";break e;case"compositionend":ge="onCompositionEnd";break e;case"compositionupdate":ge="onCompositionUpdate";break e}ge=void 0}else va?Mr(e,l)&&(ge="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(ge="onCompositionStart");ge&&(jr&&l.locale!=="ko"&&(va||ge!=="onCompositionStart"?ge==="onCompositionEnd"&&va&&(fe=Sr()):(hl=H,oc="value"in hl?hl.value:hl.textContent,va=!0)),I=no(T,ge),0<I.length&&(ge=new Tr(ge,e,null,l,H),O.push({event:ge,listeners:I}),fe?ge.data=fe:(fe=Ar(l),fe!==null&&(ge.data=fe)))),(fe=dy?my(e,l):hy(e,l))&&(ge=no(T,"onBeforeInput"),0<ge.length&&(I=new Tr("onBeforeInput","beforeinput",null,l,H),O.push({event:I,listeners:ge}),I.data=fe)),og(O,e,T,l,H)}pd(O,t)})}function Ln(e,t,l){return{instance:e,listener:t,currentTarget:l}}function no(e,t){for(var l=t+"Capture",a=[];e!==null;){var n=e,i=n.stateNode;if(n=n.tag,n!==5&&n!==26&&n!==27||i===null||(n=an(e,l),n!=null&&a.unshift(Ln(e,n,i)),n=an(e,t),n!=null&&a.push(Ln(e,n,i))),e.tag===3)return a;e=e.return}return[]}function rg(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function gd(e,t,l,a,n){for(var i=t._reactName,s=[];l!==null&&l!==a;){var d=l,p=d.alternate,T=d.stateNode;if(d=d.tag,p!==null&&p===a)break;d!==5&&d!==26&&d!==27||T===null||(p=T,n?(T=an(l,i),T!=null&&s.unshift(Ln(l,T,p))):n||(T=an(l,i),T!=null&&s.push(Ln(l,T,p)))),l=l.return}s.length!==0&&e.push({event:t,listeners:s})}var _g=/\r\n?/g,fg=/\u0000|\uFFFD/g;function vd(e){return(typeof e=="string"?e:""+e).replace(_g,`
`).replace(fg,"")}function bd(e,t){return t=vd(t),vd(e)===t}function De(e,t,l,a,n,i){switch(l){case"children":typeof a=="string"?t==="body"||t==="textarea"&&a===""||pa(e,a):(typeof a=="number"||typeof a=="bigint")&&t!=="body"&&pa(e,""+a);break;case"className":si(e,"class",a);break;case"tabIndex":si(e,"tabindex",a);break;case"dir":case"role":case"viewBox":case"width":case"height":si(e,l,a);break;case"style":vr(e,a,i);break;case"data":if(t!=="object"){si(e,"data",a);break}case"src":case"href":if(a===""&&(t!=="a"||l!=="href")){e.removeAttribute(l);break}if(a==null||typeof a=="function"||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(l);break}a=ri(""+a),e.setAttribute(l,a);break;case"action":case"formAction":if(typeof a=="function"){e.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i=="function"&&(l==="formAction"?(t!=="input"&&De(e,t,"name",n.name,n,null),De(e,t,"formEncType",n.formEncType,n,null),De(e,t,"formMethod",n.formMethod,n,null),De(e,t,"formTarget",n.formTarget,n,null)):(De(e,t,"encType",n.encType,n,null),De(e,t,"method",n.method,n,null),De(e,t,"target",n.target,n,null)));if(a==null||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(l);break}a=ri(""+a),e.setAttribute(l,a);break;case"onClick":a!=null&&(e.onclick=Wt);break;case"onScroll":a!=null&&pe("scroll",e);break;case"onScrollEnd":a!=null&&pe("scrollend",e);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(u(61));if(l=a.__html,l!=null){if(n.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"multiple":e.multiple=a&&typeof a!="function"&&typeof a!="symbol";break;case"muted":e.muted=a&&typeof a!="function"&&typeof a!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(a==null||typeof a=="function"||typeof a=="boolean"||typeof a=="symbol"){e.removeAttribute("xlink:href");break}l=ri(""+a),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":a!=null&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,""+a):e.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":a&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":a===!0?e.setAttribute(l,""):a!==!1&&a!=null&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,a):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":a!=null&&typeof a!="function"&&typeof a!="symbol"&&!isNaN(a)&&1<=a?e.setAttribute(l,a):e.removeAttribute(l);break;case"rowSpan":case"start":a==null||typeof a=="function"||typeof a=="symbol"||isNaN(a)?e.removeAttribute(l):e.setAttribute(l,a);break;case"popover":pe("beforetoggle",e),pe("toggle",e),ci(e,"popover",a);break;case"xlinkActuate":$t(e,"http://www.w3.org/1999/xlink","xlink:actuate",a);break;case"xlinkArcrole":$t(e,"http://www.w3.org/1999/xlink","xlink:arcrole",a);break;case"xlinkRole":$t(e,"http://www.w3.org/1999/xlink","xlink:role",a);break;case"xlinkShow":$t(e,"http://www.w3.org/1999/xlink","xlink:show",a);break;case"xlinkTitle":$t(e,"http://www.w3.org/1999/xlink","xlink:title",a);break;case"xlinkType":$t(e,"http://www.w3.org/1999/xlink","xlink:type",a);break;case"xmlBase":$t(e,"http://www.w3.org/XML/1998/namespace","xml:base",a);break;case"xmlLang":$t(e,"http://www.w3.org/XML/1998/namespace","xml:lang",a);break;case"xmlSpace":$t(e,"http://www.w3.org/XML/1998/namespace","xml:space",a);break;case"is":ci(e,"is",a);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=qp.get(l)||l,ci(e,l,a))}}function Ys(e,t,l,a,n,i){switch(l){case"style":vr(e,a,i);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(u(61));if(l=a.__html,l!=null){if(n.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"children":typeof a=="string"?pa(e,a):(typeof a=="number"||typeof a=="bigint")&&pa(e,""+a);break;case"onScroll":a!=null&&pe("scroll",e);break;case"onScrollEnd":a!=null&&pe("scrollend",e);break;case"onClick":a!=null&&(e.onclick=Wt);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!rr.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(n=l.endsWith("Capture"),t=l.slice(2,n?l.length-7:void 0),i=e[ft]||null,i=i!=null?i[l]:null,typeof i=="function"&&e.removeEventListener(t,i,n),typeof a=="function")){typeof i!="function"&&i!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(t,a,n);break e}l in e?e[l]=a:a===!0?e.setAttribute(l,""):ci(e,l,a)}}}function ct(e,t,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":pe("error",e),pe("load",e);var a=!1,n=!1,i;for(i in l)if(l.hasOwnProperty(i)){var s=l[i];if(s!=null)switch(i){case"src":a=!0;break;case"srcSet":n=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(u(137,t));default:De(e,t,i,s,l,null)}}n&&De(e,t,"srcSet",l.srcSet,l,null),a&&De(e,t,"src",l.src,l,null);return;case"input":pe("invalid",e);var d=i=s=n=null,p=null,T=null;for(a in l)if(l.hasOwnProperty(a)){var H=l[a];if(H!=null)switch(a){case"name":n=H;break;case"type":s=H;break;case"checked":p=H;break;case"defaultChecked":T=H;break;case"value":i=H;break;case"defaultValue":d=H;break;case"children":case"dangerouslySetInnerHTML":if(H!=null)throw Error(u(137,t));break;default:De(e,t,a,H,l,null)}}hr(e,i,d,p,T,s,n,!1);return;case"select":pe("invalid",e),a=s=i=null;for(n in l)if(l.hasOwnProperty(n)&&(d=l[n],d!=null))switch(n){case"value":i=d;break;case"defaultValue":s=d;break;case"multiple":a=d;default:De(e,t,n,d,l,null)}t=i,l=s,e.multiple=!!a,t!=null?ha(e,!!a,t,!1):l!=null&&ha(e,!!a,l,!0);return;case"textarea":pe("invalid",e),i=n=a=null;for(s in l)if(l.hasOwnProperty(s)&&(d=l[s],d!=null))switch(s){case"value":a=d;break;case"defaultValue":n=d;break;case"children":i=d;break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(u(91));break;default:De(e,t,s,d,l,null)}yr(e,a,n,i);return;case"option":for(p in l)if(l.hasOwnProperty(p)&&(a=l[p],a!=null))switch(p){case"selected":e.selected=a&&typeof a!="function"&&typeof a!="symbol";break;default:De(e,t,p,a,l,null)}return;case"dialog":pe("beforetoggle",e),pe("toggle",e),pe("cancel",e),pe("close",e);break;case"iframe":case"object":pe("load",e);break;case"video":case"audio":for(a=0;a<Un.length;a++)pe(Un[a],e);break;case"image":pe("error",e),pe("load",e);break;case"details":pe("toggle",e);break;case"embed":case"source":case"link":pe("error",e),pe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(T in l)if(l.hasOwnProperty(T)&&(a=l[T],a!=null))switch(T){case"children":case"dangerouslySetInnerHTML":throw Error(u(137,t));default:De(e,t,T,a,l,null)}return;default:if(tc(t)){for(H in l)l.hasOwnProperty(H)&&(a=l[H],a!==void 0&&Ys(e,t,H,a,l,void 0));return}}for(d in l)l.hasOwnProperty(d)&&(a=l[d],a!=null&&De(e,t,d,a,l,null))}function dg(e,t,l,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var n=null,i=null,s=null,d=null,p=null,T=null,H=null;for(z in l){var O=l[z];if(l.hasOwnProperty(z)&&O!=null)switch(z){case"checked":break;case"value":break;case"defaultValue":p=O;default:a.hasOwnProperty(z)||De(e,t,z,null,a,O)}}for(var N in a){var z=a[N];if(O=l[N],a.hasOwnProperty(N)&&(z!=null||O!=null))switch(N){case"type":i=z;break;case"name":n=z;break;case"checked":T=z;break;case"defaultChecked":H=z;break;case"value":s=z;break;case"defaultValue":d=z;break;case"children":case"dangerouslySetInnerHTML":if(z!=null)throw Error(u(137,t));break;default:z!==O&&De(e,t,N,z,a,O)}}Po(e,s,d,p,T,H,i,n);return;case"select":z=s=d=N=null;for(i in l)if(p=l[i],l.hasOwnProperty(i)&&p!=null)switch(i){case"value":break;case"multiple":z=p;default:a.hasOwnProperty(i)||De(e,t,i,null,a,p)}for(n in a)if(i=a[n],p=l[n],a.hasOwnProperty(n)&&(i!=null||p!=null))switch(n){case"value":N=i;break;case"defaultValue":d=i;break;case"multiple":s=i;default:i!==p&&De(e,t,n,i,a,p)}t=d,l=s,a=z,N!=null?ha(e,!!l,N,!1):!!a!=!!l&&(t!=null?ha(e,!!l,t,!0):ha(e,!!l,l?[]:"",!1));return;case"textarea":z=N=null;for(d in l)if(n=l[d],l.hasOwnProperty(d)&&n!=null&&!a.hasOwnProperty(d))switch(d){case"value":break;case"children":break;default:De(e,t,d,null,a,n)}for(s in a)if(n=a[s],i=l[s],a.hasOwnProperty(s)&&(n!=null||i!=null))switch(s){case"value":N=n;break;case"defaultValue":z=n;break;case"children":break;case"dangerouslySetInnerHTML":if(n!=null)throw Error(u(91));break;default:n!==i&&De(e,t,s,n,a,i)}pr(e,N,z);return;case"option":for(var J in l)if(N=l[J],l.hasOwnProperty(J)&&N!=null&&!a.hasOwnProperty(J))switch(J){case"selected":e.selected=!1;break;default:De(e,t,J,null,a,N)}for(p in a)if(N=a[p],z=l[p],a.hasOwnProperty(p)&&N!==z&&(N!=null||z!=null))switch(p){case"selected":e.selected=N&&typeof N!="function"&&typeof N!="symbol";break;default:De(e,t,p,N,a,z)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var ie in l)N=l[ie],l.hasOwnProperty(ie)&&N!=null&&!a.hasOwnProperty(ie)&&De(e,t,ie,null,a,N);for(T in a)if(N=a[T],z=l[T],a.hasOwnProperty(T)&&N!==z&&(N!=null||z!=null))switch(T){case"children":case"dangerouslySetInnerHTML":if(N!=null)throw Error(u(137,t));break;default:De(e,t,T,N,a,z)}return;default:if(tc(t)){for(var Oe in l)N=l[Oe],l.hasOwnProperty(Oe)&&N!==void 0&&!a.hasOwnProperty(Oe)&&Ys(e,t,Oe,void 0,a,N);for(H in a)N=a[H],z=l[H],!a.hasOwnProperty(H)||N===z||N===void 0&&z===void 0||Ys(e,t,H,N,a,z);return}}for(var w in l)N=l[w],l.hasOwnProperty(w)&&N!=null&&!a.hasOwnProperty(w)&&De(e,t,w,null,a,N);for(O in a)N=a[O],z=l[O],!a.hasOwnProperty(O)||N===z||N==null&&z==null||De(e,t,O,N,a,z)}function xd(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function mg(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,l=performance.getEntriesByType("resource"),a=0;a<l.length;a++){var n=l[a],i=n.transferSize,s=n.initiatorType,d=n.duration;if(i&&d&&xd(s)){for(s=0,d=n.responseEnd,a+=1;a<l.length;a++){var p=l[a],T=p.startTime;if(T>d)break;var H=p.transferSize,O=p.initiatorType;H&&xd(O)&&(p=p.responseEnd,s+=H*(p<d?1:(d-T)/(p-T)))}if(--a,t+=8*(i+s)/(n.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Gs=null,Xs=null;function io(e){return e.nodeType===9?e:e.ownerDocument}function Sd(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function wd(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Vs(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Qs=null;function hg(){var e=window.event;return e&&e.type==="popstate"?e===Qs?!1:(Qs=e,!0):(Qs=null,!1)}var Ed=typeof setTimeout=="function"?setTimeout:void 0,pg=typeof clearTimeout=="function"?clearTimeout:void 0,Td=typeof Promise=="function"?Promise:void 0,yg=typeof queueMicrotask=="function"?queueMicrotask:typeof Td<"u"?function(e){return Td.resolve(null).then(e).catch(gg)}:Ed;function gg(e){setTimeout(function(){throw e})}function Hl(e){return e==="head"}function Nd(e,t){var l=t,a=0;do{var n=l.nextSibling;if(e.removeChild(l),n&&n.nodeType===8)if(l=n.data,l==="/$"||l==="/&"){if(a===0){e.removeChild(n),Ka(t);return}a--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")a++;else if(l==="html")Bn(e.ownerDocument.documentElement);else if(l==="head"){l=e.ownerDocument.head,Bn(l);for(var i=l.firstChild;i;){var s=i.nextSibling,d=i.nodeName;i[tn]||d==="SCRIPT"||d==="STYLE"||d==="LINK"&&i.rel.toLowerCase()==="stylesheet"||l.removeChild(i),i=s}}else l==="body"&&Bn(e.ownerDocument.body);l=n}while(l);Ka(t)}function jd(e,t){var l=e;e=0;do{var a=l.nextSibling;if(l.nodeType===1?t?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(t?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),a&&a.nodeType===8)if(l=a.data,l==="/$"){if(e===0)break;e--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||e++;l=a}while(l)}function Zs(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var l=t;switch(t=t.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Zs(l),Fo(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function vg(e,t,l,a){for(;e.nodeType===1;){var n=l;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!a&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(a){if(!e[tn])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(i=e.getAttribute("rel"),i==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(i!==n.rel||e.getAttribute("href")!==(n.href==null||n.href===""?null:n.href)||e.getAttribute("crossorigin")!==(n.crossOrigin==null?null:n.crossOrigin)||e.getAttribute("title")!==(n.title==null?null:n.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(i=e.getAttribute("src"),(i!==(n.src==null?null:n.src)||e.getAttribute("type")!==(n.type==null?null:n.type)||e.getAttribute("crossorigin")!==(n.crossOrigin==null?null:n.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var i=n.name==null?null:""+n.name;if(n.type==="hidden"&&e.getAttribute("name")===i)return e}else return e;if(e=Lt(e.nextSibling),e===null)break}return null}function bg(e,t,l){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=Lt(e.nextSibling),e===null))return null;return e}function Cd(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=Lt(e.nextSibling),e===null))return null;return e}function Ks(e){return e.data==="$?"||e.data==="$~"}function Js(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function xg(e,t){var l=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||l.readyState!=="loading")t();else{var a=function(){t(),l.removeEventListener("DOMContentLoaded",a)};l.addEventListener("DOMContentLoaded",a),e._reactRetry=a}}function Lt(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var $s=null;function zd(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="/$"||l==="/&"){if(t===0)return Lt(e.nextSibling);t--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||t++}e=e.nextSibling}return null}function Md(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(t===0)return e;t--}else l!=="/$"&&l!=="/&"||t++}e=e.previousSibling}return null}function Ad(e,t,l){switch(t=io(l),e){case"html":if(e=t.documentElement,!e)throw Error(u(452));return e;case"head":if(e=t.head,!e)throw Error(u(453));return e;case"body":if(e=t.body,!e)throw Error(u(454));return e;default:throw Error(u(451))}}function Bn(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Fo(e)}var Bt=new Map,Hd=new Set;function oo(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var fl=U.d;U.d={f:Sg,r:wg,D:Eg,C:Tg,L:Ng,m:jg,X:zg,S:Cg,M:Mg};function Sg(){var e=fl.f(),t=Fi();return e||t}function wg(e){var t=fa(e);t!==null&&t.tag===5&&t.type==="form"?J_(t):fl.r(e)}var Va=typeof document>"u"?null:document;function Dd(e,t,l){var a=Va;if(a&&typeof t=="string"&&t){var n=Mt(t);n='link[rel="'+e+'"][href="'+n+'"]',typeof l=="string"&&(n+='[crossorigin="'+l+'"]'),Hd.has(n)||(Hd.add(n),e={rel:e,crossOrigin:l,href:t},a.querySelector(n)===null&&(t=a.createElement("link"),ct(t,"link",e),tt(t),a.head.appendChild(t)))}}function Eg(e){fl.D(e),Dd("dns-prefetch",e,null)}function Tg(e,t){fl.C(e,t),Dd("preconnect",e,t)}function Ng(e,t,l){fl.L(e,t,l);var a=Va;if(a&&e&&t){var n='link[rel="preload"][as="'+Mt(t)+'"]';t==="image"&&l&&l.imageSrcSet?(n+='[imagesrcset="'+Mt(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(n+='[imagesizes="'+Mt(l.imageSizes)+'"]')):n+='[href="'+Mt(e)+'"]';var i=n;switch(t){case"style":i=Qa(e);break;case"script":i=Za(e)}Bt.has(i)||(e=C({rel:"preload",href:t==="image"&&l&&l.imageSrcSet?void 0:e,as:t},l),Bt.set(i,e),a.querySelector(n)!==null||t==="style"&&a.querySelector(kn(i))||t==="script"&&a.querySelector(qn(i))||(t=a.createElement("link"),ct(t,"link",e),tt(t),a.head.appendChild(t)))}}function jg(e,t){fl.m(e,t);var l=Va;if(l&&e){var a=t&&typeof t.as=="string"?t.as:"script",n='link[rel="modulepreload"][as="'+Mt(a)+'"][href="'+Mt(e)+'"]',i=n;switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Za(e)}if(!Bt.has(i)&&(e=C({rel:"modulepreload",href:e},t),Bt.set(i,e),l.querySelector(n)===null)){switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(qn(i)))return}a=l.createElement("link"),ct(a,"link",e),tt(a),l.head.appendChild(a)}}}function Cg(e,t,l){fl.S(e,t,l);var a=Va;if(a&&e){var n=da(a).hoistableStyles,i=Qa(e);t=t||"default";var s=n.get(i);if(!s){var d={loading:0,preload:null};if(s=a.querySelector(kn(i)))d.loading=5;else{e=C({rel:"stylesheet",href:e,"data-precedence":t},l),(l=Bt.get(i))&&Ws(e,l);var p=s=a.createElement("link");tt(p),ct(p,"link",e),p._p=new Promise(function(T,H){p.onload=T,p.onerror=H}),p.addEventListener("load",function(){d.loading|=1}),p.addEventListener("error",function(){d.loading|=2}),d.loading|=4,co(s,t,a)}s={type:"stylesheet",instance:s,count:1,state:d},n.set(i,s)}}}function zg(e,t){fl.X(e,t);var l=Va;if(l&&e){var a=da(l).hoistableScripts,n=Za(e),i=a.get(n);i||(i=l.querySelector(qn(n)),i||(e=C({src:e,async:!0},t),(t=Bt.get(n))&&Fs(e,t),i=l.createElement("script"),tt(i),ct(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},a.set(n,i))}}function Mg(e,t){fl.M(e,t);var l=Va;if(l&&e){var a=da(l).hoistableScripts,n=Za(e),i=a.get(n);i||(i=l.querySelector(qn(n)),i||(e=C({src:e,async:!0,type:"module"},t),(t=Bt.get(n))&&Fs(e,t),i=l.createElement("script"),tt(i),ct(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},a.set(n,i))}}function Od(e,t,l,a){var n=(n=me.current)?oo(n):null;if(!n)throw Error(u(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(t=Qa(l.href),l=da(n).hoistableStyles,a=l.get(t),a||(a={type:"style",instance:null,count:0,state:null},l.set(t,a)),a):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=Qa(l.href);var i=da(n).hoistableStyles,s=i.get(e);if(s||(n=n.ownerDocument||n,s={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(e,s),(i=n.querySelector(kn(e)))&&!i._p&&(s.instance=i,s.state.loading=5),Bt.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Bt.set(e,l),i||Ag(n,e,l,s.state))),t&&a===null)throw Error(u(528,""));return s}if(t&&a!==null)throw Error(u(529,""));return null;case"script":return t=l.async,l=l.src,typeof l=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Za(l),l=da(n).hoistableScripts,a=l.get(t),a||(a={type:"script",instance:null,count:0,state:null},l.set(t,a)),a):{type:"void",instance:null,count:0,state:null};default:throw Error(u(444,e))}}function Qa(e){return'href="'+Mt(e)+'"'}function kn(e){return'link[rel="stylesheet"]['+e+"]"}function Rd(e){return C({},e,{"data-precedence":e.precedence,precedence:null})}function Ag(e,t,l,a){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?a.loading=1:(t=e.createElement("link"),a.preload=t,t.addEventListener("load",function(){return a.loading|=1}),t.addEventListener("error",function(){return a.loading|=2}),ct(t,"link",l),tt(t),e.head.appendChild(t))}function Za(e){return'[src="'+Mt(e)+'"]'}function qn(e){return"script[async]"+e}function Ud(e,t,l){if(t.count++,t.instance===null)switch(t.type){case"style":var a=e.querySelector('style[data-href~="'+Mt(l.href)+'"]');if(a)return t.instance=a,tt(a),a;var n=C({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return a=(e.ownerDocument||e).createElement("style"),tt(a),ct(a,"style",n),co(a,l.precedence,e),t.instance=a;case"stylesheet":n=Qa(l.href);var i=e.querySelector(kn(n));if(i)return t.state.loading|=4,t.instance=i,tt(i),i;a=Rd(l),(n=Bt.get(n))&&Ws(a,n),i=(e.ownerDocument||e).createElement("link"),tt(i);var s=i;return s._p=new Promise(function(d,p){s.onload=d,s.onerror=p}),ct(i,"link",a),t.state.loading|=4,co(i,l.precedence,e),t.instance=i;case"script":return i=Za(l.src),(n=e.querySelector(qn(i)))?(t.instance=n,tt(n),n):(a=l,(n=Bt.get(i))&&(a=C({},l),Fs(a,n)),e=e.ownerDocument||e,n=e.createElement("script"),tt(n),ct(n,"link",a),e.head.appendChild(n),t.instance=n);case"void":return null;default:throw Error(u(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(a=t.instance,t.state.loading|=4,co(a,l.precedence,e));return t.instance}function co(e,t,l){for(var a=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),n=a.length?a[a.length-1]:null,i=n,s=0;s<a.length;s++){var d=a[s];if(d.dataset.precedence===t)i=d;else if(i!==n)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=l.nodeType===9?l.head:l,t.insertBefore(e,t.firstChild))}function Ws(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Fs(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var so=null;function Ld(e,t,l){if(so===null){var a=new Map,n=so=new Map;n.set(l,a)}else n=so,a=n.get(l),a||(a=new Map,n.set(l,a));if(a.has(e))return a;for(a.set(e,null),l=l.getElementsByTagName(e),n=0;n<l.length;n++){var i=l[n];if(!(i[tn]||i[at]||e==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var s=i.getAttribute(t)||"";s=e+s;var d=a.get(s);d?d.push(i):a.set(s,[i])}}return a}function Bd(e,t,l){e=e.ownerDocument||e,e.head.insertBefore(l,t==="title"?e.querySelector("head > title"):null)}function Hg(e,t,l){if(l===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function kd(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Dg(e,t,l,a){if(l.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var n=Qa(a.href),i=t.querySelector(kn(n));if(i){t=i._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=uo.bind(e),t.then(e,e)),l.state.loading|=4,l.instance=i,tt(i);return}i=t.ownerDocument||t,a=Rd(a),(n=Bt.get(n))&&Ws(a,n),i=i.createElement("link"),tt(i);var s=i;s._p=new Promise(function(d,p){s.onload=d,s.onerror=p}),ct(i,"link",a),l.instance=i}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(l,t),(t=l.state.preload)&&(l.state.loading&3)===0&&(e.count++,l=uo.bind(e),t.addEventListener("load",l),t.addEventListener("error",l))}}var Is=0;function Og(e,t){return e.stylesheets&&e.count===0&&_o(e,e.stylesheets),0<e.count||0<e.imgCount?function(l){var a=setTimeout(function(){if(e.stylesheets&&_o(e,e.stylesheets),e.unsuspend){var i=e.unsuspend;e.unsuspend=null,i()}},6e4+t);0<e.imgBytes&&Is===0&&(Is=62500*mg());var n=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&_o(e,e.stylesheets),e.unsuspend)){var i=e.unsuspend;e.unsuspend=null,i()}},(e.imgBytes>Is?50:800)+t);return e.unsuspend=l,function(){e.unsuspend=null,clearTimeout(a),clearTimeout(n)}}:null}function uo(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)_o(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var ro=null;function _o(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ro=new Map,t.forEach(Rg,e),ro=null,uo.call(e))}function Rg(e,t){if(!(t.state.loading&4)){var l=ro.get(e);if(l)var a=l.get(null);else{l=new Map,ro.set(e,l);for(var n=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<n.length;i++){var s=n[i];(s.nodeName==="LINK"||s.getAttribute("media")!=="not all")&&(l.set(s.dataset.precedence,s),a=s)}a&&l.set(null,a)}n=t.instance,s=n.getAttribute("data-precedence"),i=l.get(s)||a,i===a&&l.set(null,n),l.set(s,n),this.count++,a=uo.bind(this),n.addEventListener("load",a),n.addEventListener("error",a),i?i.parentNode.insertBefore(n,i.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(n,e.firstChild)),t.state.loading|=4}}var Yn={$$typeof:j,Provider:null,Consumer:null,_currentValue:ee,_currentValue2:ee,_threadCount:0};function Ug(e,t,l,a,n,i,s,d,p){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Ko(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ko(0),this.hiddenUpdates=Ko(null),this.identifierPrefix=a,this.onUncaughtError=n,this.onCaughtError=i,this.onRecoverableError=s,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=p,this.incompleteTransitions=new Map}function qd(e,t,l,a,n,i,s,d,p,T,H,O){return e=new Ug(e,t,l,s,p,T,H,O,d),t=1,i===!0&&(t|=24),i=wt(3,null,null,t),e.current=i,i.stateNode=e,t=Ac(),t.refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:a,isDehydrated:l,cache:t},Rc(i),e}function Yd(e){return e?(e=wa,e):wa}function Gd(e,t,l,a,n,i){n=Yd(n),a.context===null?a.context=n:a.pendingContext=n,a=xl(t),a.payload={element:l},i=i===void 0?null:i,i!==null&&(a.callback=i),l=Sl(e,a,t),l!==null&&(gt(l,e,t),vn(l,e,t))}function Xd(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<t?l:t}}function Ps(e,t){Xd(e,t),(e=e.alternate)&&Xd(e,t)}function Vd(e){if(e.tag===13||e.tag===31){var t=Kl(e,67108864);t!==null&&gt(t,e,67108864),Ps(e,67108864)}}function Qd(e){if(e.tag===13||e.tag===31){var t=Ct();t=Jo(t);var l=Kl(e,t);l!==null&&gt(l,e,t),Ps(e,t)}}var fo=!0;function Lg(e,t,l,a){var n=M.T;M.T=null;var i=U.p;try{U.p=2,eu(e,t,l,a)}finally{U.p=i,M.T=n}}function Bg(e,t,l,a){var n=M.T;M.T=null;var i=U.p;try{U.p=8,eu(e,t,l,a)}finally{U.p=i,M.T=n}}function eu(e,t,l,a){if(fo){var n=tu(a);if(n===null)qs(e,t,a,mo,l),Kd(e,a);else if(qg(n,e,t,l,a))a.stopPropagation();else if(Kd(e,a),t&4&&-1<kg.indexOf(e)){for(;n!==null;){var i=fa(n);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var s=Gl(i.pendingLanes);if(s!==0){var d=i;for(d.pendingLanes|=2,d.entangledLanes|=2;s;){var p=1<<31-xt(s);d.entanglements[1]|=p,s&=~p}Zt(i),(Ne&6)===0&&($i=vt()+500,Rn(0))}}break;case 31:case 13:d=Kl(i,2),d!==null&&gt(d,i,2),Fi(),Ps(i,2)}if(i=tu(a),i===null&&qs(e,t,a,mo,l),i===n)break;n=i}n!==null&&a.stopPropagation()}else qs(e,t,a,null,l)}}function tu(e){return e=ac(e),lu(e)}var mo=null;function lu(e){if(mo=null,e=_a(e),e!==null){var t=m(e);if(t===null)e=null;else{var l=t.tag;if(l===13){if(e=y(t),e!==null)return e;e=null}else if(l===31){if(e=S(t),e!==null)return e;e=null}else if(l===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return mo=e,null}function Zd(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Ep()){case Pu:return 2;case er:return 8;case li:case Tp:return 32;case tr:return 268435456;default:return 32}default:return 32}}var au=!1,Dl=null,Ol=null,Rl=null,Gn=new Map,Xn=new Map,Ul=[],kg="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Kd(e,t){switch(e){case"focusin":case"focusout":Dl=null;break;case"dragenter":case"dragleave":Ol=null;break;case"mouseover":case"mouseout":Rl=null;break;case"pointerover":case"pointerout":Gn.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xn.delete(t.pointerId)}}function Vn(e,t,l,a,n,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:l,eventSystemFlags:a,nativeEvent:i,targetContainers:[n]},t!==null&&(t=fa(t),t!==null&&Vd(t)),e):(e.eventSystemFlags|=a,t=e.targetContainers,n!==null&&t.indexOf(n)===-1&&t.push(n),e)}function qg(e,t,l,a,n){switch(t){case"focusin":return Dl=Vn(Dl,e,t,l,a,n),!0;case"dragenter":return Ol=Vn(Ol,e,t,l,a,n),!0;case"mouseover":return Rl=Vn(Rl,e,t,l,a,n),!0;case"pointerover":var i=n.pointerId;return Gn.set(i,Vn(Gn.get(i)||null,e,t,l,a,n)),!0;case"gotpointercapture":return i=n.pointerId,Xn.set(i,Vn(Xn.get(i)||null,e,t,l,a,n)),!0}return!1}function Jd(e){var t=_a(e.target);if(t!==null){var l=m(t);if(l!==null){if(t=l.tag,t===13){if(t=y(l),t!==null){e.blockedOn=t,cr(e.priority,function(){Qd(l)});return}}else if(t===31){if(t=S(l),t!==null){e.blockedOn=t,cr(e.priority,function(){Qd(l)});return}}else if(t===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ho(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var l=tu(e.nativeEvent);if(l===null){l=e.nativeEvent;var a=new l.constructor(l.type,l);lc=a,l.target.dispatchEvent(a),lc=null}else return t=fa(l),t!==null&&Vd(t),e.blockedOn=l,!1;t.shift()}return!0}function $d(e,t,l){ho(e)&&l.delete(t)}function Yg(){au=!1,Dl!==null&&ho(Dl)&&(Dl=null),Ol!==null&&ho(Ol)&&(Ol=null),Rl!==null&&ho(Rl)&&(Rl=null),Gn.forEach($d),Xn.forEach($d)}function po(e,t){e.blockedOn===t&&(e.blockedOn=null,au||(au=!0,c.unstable_scheduleCallback(c.unstable_NormalPriority,Yg)))}var yo=null;function Wd(e){yo!==e&&(yo=e,c.unstable_scheduleCallback(c.unstable_NormalPriority,function(){yo===e&&(yo=null);for(var t=0;t<e.length;t+=3){var l=e[t],a=e[t+1],n=e[t+2];if(typeof a!="function"){if(lu(a||l)===null)continue;break}var i=fa(l);i!==null&&(e.splice(t,3),t-=3,ts(i,{pending:!0,data:n,method:l.method,action:a},a,n))}}))}function Ka(e){function t(p){return po(p,e)}Dl!==null&&po(Dl,e),Ol!==null&&po(Ol,e),Rl!==null&&po(Rl,e),Gn.forEach(t),Xn.forEach(t);for(var l=0;l<Ul.length;l++){var a=Ul[l];a.blockedOn===e&&(a.blockedOn=null)}for(;0<Ul.length&&(l=Ul[0],l.blockedOn===null);)Jd(l),l.blockedOn===null&&Ul.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(a=0;a<l.length;a+=3){var n=l[a],i=l[a+1],s=n[ft]||null;if(typeof i=="function")s||Wd(l);else if(s){var d=null;if(i&&i.hasAttribute("formAction")){if(n=i,s=i[ft]||null)d=s.formAction;else if(lu(n)!==null)continue}else d=s.action;typeof d=="function"?l[a+1]=d:(l.splice(a,3),a-=3),Wd(l)}}}function Fd(){function e(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(s){return n=s})},focusReset:"manual",scroll:"manual"})}function t(){n!==null&&(n(),n=null),a||setTimeout(l,20)}function l(){if(!a&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var a=!1,n=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(l,100),function(){a=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),n!==null&&(n(),n=null)}}}function nu(e){this._internalRoot=e}go.prototype.render=nu.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(u(409));var l=t.current,a=Ct();Gd(l,a,e,t,null,null)},go.prototype.unmount=nu.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Gd(e.current,2,null,e,null,null),Fi(),t[ra]=null}};function go(e){this._internalRoot=e}go.prototype.unstable_scheduleHydration=function(e){if(e){var t=or();e={blockedOn:null,target:e,priority:t};for(var l=0;l<Ul.length&&t!==0&&t<Ul[l].priority;l++);Ul.splice(l,0,e),l===0&&Jd(e)}};var Id=o.version;if(Id!=="19.2.7")throw Error(u(527,Id,"19.2.7"));U.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(u(188)):(e=Object.keys(e).join(","),Error(u(268,e)));return e=h(t),e=e!==null?A(e):null,e=e===null?null:e.stateNode,e};var Gg={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:M,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var vo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!vo.isDisabled&&vo.supportsFiber)try{Ia=vo.inject(Gg),bt=vo}catch{}}return $a.createRoot=function(e,t){if(!f(e))throw Error(u(299));var l=!1,a="",n=nf,i=of,s=cf;return t!=null&&(t.unstable_strictMode===!0&&(l=!0),t.identifierPrefix!==void 0&&(a=t.identifierPrefix),t.onUncaughtError!==void 0&&(n=t.onUncaughtError),t.onCaughtError!==void 0&&(i=t.onCaughtError),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=qd(e,1,!1,null,null,l,a,null,n,i,s,Fd),e[ra]=t.current,ks(e),new nu(t)},$a.hydrateRoot=function(e,t,l){if(!f(e))throw Error(u(299));var a=!1,n="",i=nf,s=of,d=cf,p=null;return l!=null&&(l.unstable_strictMode===!0&&(a=!0),l.identifierPrefix!==void 0&&(n=l.identifierPrefix),l.onUncaughtError!==void 0&&(i=l.onUncaughtError),l.onCaughtError!==void 0&&(s=l.onCaughtError),l.onRecoverableError!==void 0&&(d=l.onRecoverableError),l.formState!==void 0&&(p=l.formState)),t=qd(e,1,!0,t,l??null,a,n,p,i,s,d,Fd),t.context=Yd(null),l=t.current,a=Ct(),a=Jo(a),n=xl(a),n.callback=null,Sl(l,n,a),l=a,t.current.lanes=l,en(t,l),Zt(t),e[ra]=t.current,ks(e),new go(t)},$a.version="19.2.7",$a}var mu;function sm(){if(mu)return wo.exports;mu=1;function c(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(c)}catch(o){console.error(o)}}return c(),wo.exports=cm(),wo.exports}var um=sm();const hu=c=>{let o;const r=new Set,u=(h,A)=>{const C=typeof h=="function"?h(o):h;if(!Object.is(C,o)){const Y=o;o=A??(typeof C!="object"||C===null)?C:Object.assign({},o,C),r.forEach(R=>R(o,Y))}},f=()=>o,S={setState:u,getState:f,getInitialState:()=>x,subscribe:h=>(r.add(h),()=>r.delete(h))},x=o=c(u,f,S);return S},rm=(c=>c?hu(c):hu),_m=c=>c;function fm(c,o=_m){const r=Qn.useSyncExternalStore(c.subscribe,Qn.useCallback(()=>o(c.getState()),[c,o]),Qn.useCallback(()=>o(c.getInitialState()),[c,o]));return Qn.useDebugValue(r),r}const dm=c=>{const o=rm(c),r=u=>fm(o,u);return Object.assign(r,o),r},mm=(c=>dm);function hm(c){const o=[],r=c.replace(/\/\*[\s\S]*?\*\//g,""),u=/([^{]+)\{([^}]*)\}/g;let f;for(;(f=u.exec(r))!==null;){const m=f[1].trim(),y=f[2].trim();if(!m||!y)continue;const S=m.split(",").map(h=>h.trim()).filter(Boolean),x=pu(y);if(Object.keys(x).length!==0)for(const h of S)o.push({selector:h,declarations:x})}return o}function pu(c){const o={},r=c.split(";");for(const u of r){const f=u.indexOf(":");if(f===-1)continue;const m=u.slice(0,f).trim().toLowerCase(),y=u.slice(f+1).trim();m&&y&&(o[m]=y)}return o}function pm(c){return!c||!c.trim()?{}:pu(c)}function ym(c){return Object.entries(c).filter(([,o])=>o!=="").map(([o,r])=>`${o}: ${r}`).join("; ")}function gm(c,o){try{return c.matches(o)}catch{return!1}}function vm(c){const o=c.querySelectorAll("style");return Array.from(o).map(r=>r.textContent??"").join(`
`)}function bm(c,o){const r={};for(const u of o)gm(c,u.selector)&&Object.assign(r,u.declarations);return r}function xm(c,o){return{...c,...o}}const Bl="notifal-notification-root",yu="notifal-notification-root",gu="notifal-post-feature-image",Sm="notifal-countdown";function wm(c){return c.includes(Bl)||c.includes(yu)}function vu(c){const o=c.trim();if(!o||!wm(o))return o;const r=/<html[\s>]/i.test(o),f=new DOMParser().parseFromString(r?o:`<!DOCTYPE html><html><head><meta charset="UTF-8"></head><body>${o}</body></html>`,"text/html"),m=f.getElementById(Bl)??f.querySelector(`.${yu}`);if(!m?.parentElement)return o;const y=m.parentElement;for(;m.firstChild;)y.insertBefore(m.firstChild,m);return y.removeChild(m),r?f.documentElement.outerHTML:f.body.innerHTML.trim()}function jo(c){return vu(c)}function Co(c){const o=c.trim();return!o||/<html[\s>]/i.test(o)?o:`<!DOCTYPE html><html><head><meta charset="UTF-8"></head><body>${o}</body></html>`}function Em(c){const r=vu(c).trim();return r?new DOMParser().parseFromString(r,"text/html").body.innerHTML.trim():""}const zo=["width","height","border-radius","object-fit"],bu={width:"data-notifal-image-width",height:"data-notifal-image-height","border-radius":"data-notifal-image-border-radius","object-fit":"data-notifal-image-object-fit"};function xu(c){const o={};return Object.entries(bu).forEach(([r,u])=>{const f=c.getAttribute(u);f&&(o[r]=f)}),o}function Tm(c,o){Object.entries(bu).forEach(([r,u])=>{const f=o[r];if(f){c.setAttribute(u,f);return}c.removeAttribute(u)})}function Su(c,o){const r={...c},u={...o};return zo.forEach(f=>{r[f]&&!u[f]&&(u[f]=r[f],delete r[f])}),{containerStyles:r,imageStyles:u}}function wu(c){return zo.includes(c)}function Mo(c){const o=Math.max(0,Math.floor(Number(c)||0));return{days:Math.floor(o/86400),hours:Math.floor(o%86400/3600),minutes:Math.floor(o%3600/60),seconds:o%60}}function Nm(c){const o=Math.max(0,Math.floor(Number(c)||0));return o<10?`0${o}`:String(o)}function jm(c,o){const r=Math.max(0,Math.floor(Number(c)||0)),u=Math.max(0,Math.min(59,Math.floor(Number(o)||0)));return r*60+u}function Cm(c){const o=c.getAttribute("data-countdown-seconds")??"0",r=parseInt(o,10);return!Number.isFinite(r)||r<0?0:r}function zm(c){const o=(c.getAttribute("data-countdown-on-complete")||"stay").toLowerCase();return o==="hide"||o==="close"?o:"stay"}function Mm(c,o){const r=Mo(o);c.querySelectorAll("[data-countdown-unit]").forEach(f=>{const m=(f.getAttribute("data-countdown-unit")||"").toLowerCase();m in r&&(f.textContent=Nm(r[m]))})}function Am(c,o){try{const u=c.evaluate(o,c,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue;return u&&u.nodeType===Node.ELEMENT_NODE?u:null}catch{return null}}function Hm(c,o,r){const f=new DOMParser().parseFromString(c,"text/html"),m=Am(f,o);if(!m)throw new Error("Countdown element not found");if(typeof r.totalSeconds=="number"){const y=Math.max(0,Math.floor(Number(r.totalSeconds)||0));m.setAttribute("data-countdown-seconds",String(y)),Mm(m,y)}return r.onComplete&&m.setAttribute("data-countdown-on-complete",r.onComplete),f.documentElement.outerHTML}const Dm=new Set(["script","style","noscript","template","meta","link","head"]),Eu=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]);function Om(c){const o=[];let r=c;for(;r&&r.nodeType===Node.ELEMENT_NODE;){let u=1,f=r.previousElementSibling;for(;f;)f.tagName===r.tagName&&u++,f=f.previousElementSibling;const m=r.tagName.toLowerCase();o.unshift(`${m}[${u}]`),r=r.parentElement}return"/"+o.join("/")}function Rm(c){const r=(c.getAttribute("style")??"").toLowerCase().replace(/\s/g,"");return r.includes("display:none")||r.includes("visibility:hidden")}function Um(c){for(const o of Array.from(c.childNodes))if(o.nodeType===Node.TEXT_NODE&&(o.textContent??"").trim().length>0)return!0;return!1}function Tu(c){for(const o of Array.from(c.children)){const r=o.tagName.toLowerCase();if(!Eu.has(r)&&(o.textContent??"").trim().length>0)return!0}return!1}function Lm(c){const o=[];for(const r of Array.from(c.childNodes))r.nodeType===Node.TEXT_NODE&&o.push(r.textContent??"");return o.join("").trim()}function Nu(c,o,r,u){const f=c.tagName.toLowerCase();if(Dm.has(f)||Rm(c))return null;const m=u.tagCounters.get(f)??0,y=`${f}-${m}`;u.tagCounters.set(f,m+1);const S=Um(c)&&!Eu.has(f)&&!Tu(c),x=c.getAttribute("class")??"",h=x.split(/\s+/).filter(Boolean),A=h.includes(gu),C=h.includes(Sm),Y=C?Cm(c):void 0,R=C?zm(c):void 0,L=c.getAttribute("style")??"";let G=pm(L);const Z=bm(c,u.cssRules);let q=xm(Z,G),X;if(A){const ve=xu(c),ke=Su(q,ve);q=ke.containerStyles,X=ke.imageStyles,G=Su(G,ve).containerStyles}const j=Object.keys(q).length>0||Object.keys(G).length>0||!!(X&&Object.keys(X).length>0),F=Om(c),ae=c.outerHTML,ne=f==="img"||A,K=f==="img"?c.getAttribute("src")??"":c.querySelector("img")?.getAttribute("src")??"",se=f==="a",Ee=se?c.getAttribute("href")??"":void 0,$=[];for(const ve of Array.from(c.children)){const ke=Nu(ve,y,r+1,u);ke&&$.push(ke)}return{id:y,tagName:f,textContent:Lm(c),xpath:F,styles:q,inlineStyles:G,isTextEditable:S,isStyleEditable:j,children:$,parentId:o,outerHtml:ae,depth:r,imageSrc:ne&&!A?K:void 0,isImageEditable:ne,isFeaturedImagePlaceholder:A,isCountdownPlaceholder:C,countdownSeconds:Y,countdownOnComplete:R,imageStyles:X,className:x||void 0,linkHref:Ee,isLinkEditable:se}}function Ao(c){const r=new DOMParser().parseFromString(c,"text/html"),u=vm(r),f=hm(u),m={tagCounters:new Map,cssRules:f},y=r.body;if(!y)return[];const S=[];for(const x of Array.from(y.children)){const h=Nu(x,null,0,m);h&&S.push(h)}return S}function Ho(c){const o=[];function r(u){o.push(u);for(const f of u.children)r(f)}for(const u of c)r(u);return o}function kt(c,o){for(const r of c){if(r.id===o)return r;const u=kt(r.children,o);if(u)return u}return null}function ju(c,o){for(const r of c){if(r.xpath===o)return r.id;const u=ju(r.children,o);if(u)return u}return null}function Bm(c,o){const r=new Map(Ho(c).map(m=>[m.id,m])),u=[];let f=r.get(o);for(;f?.parentId;)u.push(f.parentId),f=r.get(f.parentId);return u}function km(c,o){try{const u=c.evaluate(o,c,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue;return u&&u.nodeType===Node.ELEMENT_NODE?u:null}catch{return null}}function Cu(c,o){const r=ym(o);r?c.setAttribute("style",r):c.removeAttribute("style")}function Zn(c,o){const u=new DOMParser().parseFromString(c,"text/html"),f=Ho(o);for(const m of f){const y=km(u,m.xpath);if(y)if(m.isTextEditable&&!Tu(y)&&(y.children.length===0?y.textContent=m.textContent:qm(y,m.textContent)),m.isFeaturedImagePlaceholder){Tm(y,m.imageStyles??{});const S={...m.inlineStyles};zo.forEach(x=>{delete S[x]}),Cu(y,S)}else Cu(y,m.inlineStyles)}return u.documentElement.outerHTML}function qm(c,o){const r=[];for(const u of Array.from(c.childNodes))u.nodeType===Node.TEXT_NODE&&r.push(u);if(r.length!==0){if(r.length===1){r[0].textContent=o;return}r[0].textContent=o;for(let u=1;u<r.length;u++)r[u].textContent=""}}const Ym=/^<(br|hr|img|input|link|meta|area|base|col|embed|param|source|track|wbr)\b/i;function Gm(c,o,r){const u=c.replace(/\s*\{\s*/g,` {
`).replace(/\s*\}\s*/g,`
}
`).replace(/;\s*/g,`;
`).replace(/\n{2,}/g,`
`);let f="",m=0;const y=u.split(`
`);for(const S of y){const x=S.trim();x&&(x.startsWith("}")&&(m=Math.max(0,m-1)),f+=r.repeat(o+m)+x+`
`,x.endsWith("{")&&(m+=1))}return f}function zu(c){let o="",r=0;const u="  ";let f=!1,m=!1;const y=c.split(/(<[^>]+>)/);for(const S of y)if(S.trim()){if(/^<\/style\b/i.test(S)){f=!1,r=Math.max(0,r-1),o+=u.repeat(r)+S+`
`;continue}if(/^<\/script\b/i.test(S)){m=!1,r=Math.max(0,r-1),o+=u.repeat(r)+S+`
`;continue}if(/^<\//.test(S)){r=Math.max(0,r-1),o+=u.repeat(r)+S+`
`;continue}if(/^<style\b/i.test(S)){o+=u.repeat(r)+S+`
`,r+=1,f=!0;continue}if(/^<script\b/i.test(S)){o+=u.repeat(r)+S+`
`,r+=1,m=!0;continue}if(/^<[^>]+\/>$/.test(S)||Ym.test(S)){o+=u.repeat(r)+S+`
`;continue}if(/^</.test(S)){o+=u.repeat(r)+S+`
`,r+=1;continue}if(f){o+=Gm(S.trim(),r,u);continue}if(m){const x=S.trim().split(`
`);for(const h of x)h.trim()&&(o+=u.repeat(r)+h.trim()+`
`);continue}o+=u.repeat(r)+S.trim()+`
`}return o.trim()}function oa(c,o){try{const u=c.evaluate(o,c,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue;return u&&u.nodeType===Node.ELEMENT_NODE?u:null}catch{return null}}function Xm(c,o){const u=new DOMParser().parseFromString(c,"text/html"),f=oa(u,o);if(!f)throw new Error("Element not found");const m=f.tagName.toLowerCase();if(m==="body"||m==="html")throw new Error("Cannot remove root element");return f.parentNode?.removeChild(f),u.documentElement.outerHTML}function Vm(c,o){const u=new DOMParser().parseFromString(c,"text/html"),f=oa(u,o);if(!f||!f.parentNode)throw new Error("Element not found");const m=f.cloneNode(!0),y=f.nextSibling;return y?f.parentNode.insertBefore(m,y):f.parentNode.appendChild(m),u.documentElement.outerHTML}function Qm(c,o,r){const f=new DOMParser().parseFromString(c,"text/html"),m=oa(f,o);if(!m)throw new Error("Element not found");if(m.tagName.toLowerCase()==="img")m.setAttribute("src",r);else{const S=m.querySelector("img");if(S)S.setAttribute("src",r);else{const x=f.createElement("img");x.setAttribute("src",r),x.setAttribute("alt",""),m.appendChild(x)}}return f.documentElement.outerHTML}function Zm(c,o,r){const f=new DOMParser().parseFromString(c,"text/html"),m=oa(f,o);if(!m)throw new Error("Element not found");if(m.tagName.toLowerCase()!=="a")throw new Error("Element is not a link");return r.trim()===""?m.removeAttribute("href"):m.setAttribute("href",r),f.documentElement.outerHTML}function Km(c,o){const u=new DOMParser().parseFromString(c,"text/html");return oa(u,o)?.outerHTML??null}function Jm(c,o,r){const u=new DOMParser,f=u.parseFromString(c,"text/html"),m=oa(f,o);if(!m||!m.parentNode)throw new Error("Element not found");const y=m.tagName.toLowerCase();if(y==="body"||y==="html")throw new Error("Cannot replace root element");const x=u.parseFromString(`<body>${r.trim()}</body>`,"text/html").body.firstElementChild;if(!x)throw new Error("Invalid element HTML");const h=f.importNode(x,!0);return m.parentNode.replaceChild(h,m),f.documentElement.outerHTML}function $m(c){if(!c)return!1;const o=c.toLowerCase();return o.includes("notifal-post-feature-image")||o.includes("notifal-close-button")||o.includes("notifal-action-button")||o.includes("notifal-countdown")||/\{[a-z0-9_]+\}/i.test(c)}const Do=50,Wm=300;function kl(c){return c.map(Mu)}function Mu(c){return{...c,styles:{...c.styles},inlineStyles:{...c.inlineStyles},imageStyles:c.imageStyles?{...c.imageStyles}:void 0,children:c.children.map(Mu)}}function Oo(c,o,r){return c.map(u=>{if(u.id===o)return r(u);const f=Oo(u.children,o,r);return f===u.children?u:{...u,children:f}})}let ca=null,Wa=null;function sa(c,o,r,u=null,f=null){try{const m=jo(Co(r)),y=Ao(m),S=y.length>0?m:"",x={nodes:kl(y),rawHtml:S},h=o(),A=[...h.history.slice(0,h.historyIndex+1),x].slice(-Do);let C=u;f&&(C=ju(y,f)),c({rawHtml:S,nodes:y,selectedNodeId:C,isDirty:!0,history:A,historyIndex:A.length-1,error:null})}catch(m){const y=m instanceof Error?m.message:"Failed to update HTML";c({error:y})}}const Au={rawHtml:"",nodes:[],selectedNodeId:null,isDirty:!1,history:[],historyIndex:-1,isPreviewMode:!1,showHtmlModal:!1,error:null,previewWidth:null,previewDevice:"desktop",lastSavedAt:null,isAutoSaving:!1,tagPreviewStatus:"idle",isLeftPanelVisible:!0,isRightPanelVisible:!0,panelsVisibilityBeforePreview:null},Q=mm()((c,o)=>({...Au,loadHtml:(r,u)=>{try{const f=jo(Co(r)),m=Ao(f),y=m.length>0?f:"",S={nodes:kl(m),rawHtml:y};c({rawHtml:y,nodes:m,selectedNodeId:null,isDirty:!!u?.markDirty,history:[S],historyIndex:0,error:null})}catch(f){const m=f instanceof Error?f.message:"Failed to parse HTML";c({error:m})}},selectNode:r=>{c({selectedNodeId:r})},updateText:(r,u)=>{const f=o(),m=Oo(f.nodes,r,h=>({...h,textContent:u})),y=Zn(f.rawHtml,m),S={nodes:kl(m),rawHtml:y},x=[...f.history.slice(0,f.historyIndex+1),S].slice(-Do);c({nodes:m,rawHtml:y,isDirty:!0,history:x,historyIndex:x.length-1})},updateStyle:(r,u,f)=>{const m=o(),S=!!kt(m.nodes,r)?.isFeaturedImagePlaceholder&&wu(u),x=Oo(m.nodes,r,A=>{if(S){const R={...A.imageStyles??{}};return f?R[u]=f:delete R[u],{...A,imageStyles:R,isStyleEditable:!0}}const C={...A.styles,[u]:f},Y={...A.inlineStyles,[u]:f};return f||(delete C[u],delete Y[u]),{...A,styles:C,inlineStyles:Y,isStyleEditable:!0}}),h=Zn(m.rawHtml,x);c({nodes:x,rawHtml:h,isDirty:!0}),ca&&clearTimeout(ca),Wa={nodes:kl(x),rawHtml:h},ca=setTimeout(()=>{const A=o();if(!Wa)return;const C=[...A.history.slice(0,A.historyIndex+1),Wa].slice(-Do);c({history:C,historyIndex:C.length-1}),Wa=null,ca=null},Wm)},undo:()=>{const r=o();if(r.historyIndex<=0)return;const u=r.historyIndex-1,f=r.history[u];c({nodes:kl(f.nodes),rawHtml:f.rawHtml,historyIndex:u,isDirty:u>0,selectedNodeId:null})},redo:()=>{const r=o();if(r.historyIndex>=r.history.length-1)return;const u=r.historyIndex+1,f=r.history[u];c({nodes:kl(f.nodes),rawHtml:f.rawHtml,historyIndex:u,isDirty:!0,selectedNodeId:null})},exportHtml:()=>{const r=o();return Zn(r.rawHtml,r.nodes)},exportEditableHtml:()=>{const r=o(),u=Zn(r.rawHtml,r.nodes);return Em(u)},insertTag:r=>{const u=o(),f=r.startsWith("{")?r:`{${r}}`;if(u.selectedNodeId){const y=kt(u.nodes,u.selectedNodeId);if(y&&y.isTextEditable){o().updateText(u.selectedNodeId,y.textContent+f);return}}let m=u.rawHtml;m.includes("</body>")?m=m.replace("</body>",f+"</body>"):m=m+f,o().loadHtml(m),c({isDirty:!0})},markClean:()=>{c({isDirty:!1})},reset:()=>{ca&&clearTimeout(ca),Wa=null,c({...Au})},togglePreview:()=>{c(r=>{if(!r.isPreviewMode)return{isPreviewMode:!0,panelsVisibilityBeforePreview:{left:r.isLeftPanelVisible,right:r.isRightPanelVisible},isLeftPanelVisible:!1,isRightPanelVisible:!1};const f=r.panelsVisibilityBeforePreview??{left:!0,right:!0};return{isPreviewMode:!1,isLeftPanelVisible:f.left,isRightPanelVisible:f.right,panelsVisibilityBeforePreview:null}})},toggleLeftPanel:()=>{c(r=>({isLeftPanelVisible:!r.isLeftPanelVisible}))},toggleRightPanel:()=>{c(r=>({isRightPanelVisible:!r.isRightPanelVisible}))},setLeftPanelVisible:r=>{c({isLeftPanelVisible:r})},setRightPanelVisible:r=>{c({isRightPanelVisible:r})},toggleHtmlModal:()=>{c(r=>({showHtmlModal:!r.showHtmlModal}))},openHtmlModal:()=>{c({showHtmlModal:!0})},closeHtmlModal:()=>{c({showHtmlModal:!1})},applyHtmlSource:r=>{try{const u=jo(Co(r)),f=Ao(u),m=f.length>0?u:"",y={nodes:kl(f),rawHtml:m};c({rawHtml:m,nodes:f,selectedNodeId:null,isDirty:!0,history:[y],historyIndex:0,error:null,showHtmlModal:!1})}catch(u){const f=u instanceof Error?u.message:"Failed to parse HTML";c({error:f})}},clearError:()=>{c({error:null})},removeNode:r=>{const u=o(),f=kt(u.nodes,r);if(f)try{const m=Xm(u.rawHtml,f.xpath);sa(c,o,m,null)}catch(m){const y=m instanceof Error?m.message:"Failed to remove element";c({error:y})}},duplicateNode:r=>{const u=o(),f=kt(u.nodes,r);if(f)try{const m=Vm(u.rawHtml,f.xpath);sa(c,o,m,null)}catch(m){const y=m instanceof Error?m.message:"Failed to duplicate element";c({error:y})}},updateImageSrc:(r,u)=>{const f=o(),m=kt(f.nodes,r);if(m)try{const y=Qm(f.rawHtml,m.xpath,u);sa(c,o,y,null,m.xpath)}catch(y){const S=y instanceof Error?y.message:"Failed to update image";c({error:S})}},updateLinkHref:(r,u)=>{const f=o(),m=kt(f.nodes,r);if(m)try{const y=Zm(f.rawHtml,m.xpath,u);sa(c,o,y,null,m.xpath)}catch(y){const S=y instanceof Error?y.message:"Failed to update link";c({error:S})}},updateCountdownSettings:(r,u)=>{const f=o(),m=kt(f.nodes,r);if(!(!m||!m.isCountdownPlaceholder))try{const y=Hm(f.rawHtml,m.xpath,u);sa(c,o,y,null,m.xpath)}catch(y){const S=y instanceof Error?y.message:"Failed to update countdown";c({error:S})}},updateNodeOuterHtml:(r,u)=>{const f=o(),m=kt(f.nodes,r);if(m)try{const y=Jm(f.rawHtml,m.xpath,u);sa(c,o,y,null,m.xpath)}catch(y){const S=y instanceof Error?y.message:"Failed to update element HTML";c({error:S})}},setPreviewWidth:(r,u="custom")=>{c({previewWidth:r,previewDevice:u})},setAutoSaving:r=>{c({isAutoSaving:r})},setLastSavedAt:r=>{c({lastSavedAt:r})},setTagPreviewStatus:r=>{c({tagPreviewStatus:r})}}));function Fm(c){return c.selectedNodeId?kt(c.nodes,c.selectedNodeId):null}const Kt={button:"_button_ud3so_3","button--primary":"_button--primary_ud3so_34","button--secondary":"_button--secondary_ud3so_47","button--ghost":"_button--ghost_ud3so_58","button--danger":"_button--danger_ud3so_74","button--sm":"_button--sm_ud3so_85","button--md":"_button--md_ud3so_92","button--lg":"_button--lg_ud3so_98","button--full":"_button--full_ud3so_107","button--loading":"_button--loading_ud3so_111",button__label:"_button__label_ud3so_111",button__icon:"_button__icon_ud3so_117","button__icon--right":"_button__icon--right_ud3so_123",button__spinner:"_button__spinner_ud3so_133",spin:"_spin_ud3so_1"},Pe=({variant:c="secondary",size:o="md",icon:r,iconRight:u,loading:f=!1,fullWidth:m=!1,children:y,className:S="",disabled:x,...h})=>{const A=[Kt.button,Kt[`button--${c}`],Kt[`button--${o}`],m?Kt["button--full"]:"",f?Kt["button--loading"]:"",S].filter(Boolean).join(" ");return _.jsxs("button",{className:A,disabled:x||f,...h,children:[r&&_.jsx("span",{className:Kt.button__icon,children:r}),y&&_.jsx("span",{className:Kt.button__label,children:y}),u&&_.jsx("span",{className:Kt["button__icon--right"],children:u}),f&&_.jsx("span",{className:Kt.button__spinner,"aria-hidden":"true"})]})},Im={icon:"_icon_50mws_5"},Pm={12:"size-12",16:"size-16",20:"size-20",24:"size-24"},de=({name:c,size:o=16,className:r="",ariaHidden:u=!0})=>{const f=Pm[o]??"",m=f?void 0:o;return _.jsx("span",{className:["notifal-icon",`notifal-icon-${c}`,f,Im.icon,r].filter(Boolean).join(" "),style:m?{fontSize:`${m}px`}:void 0,"aria-hidden":u?!0:void 0})};function Hu(){return window.NotifalHtmlBuilderStrings??null}function ua(){const o=Hu()?.builder;return{back_to_templates:o?.back_to_templates??"Back to Templates",insert_tag:o?.insert_tag??"Insert Tag",copy_html:o?.copy_html??"Copy HTML",save:o?.save??"Save",saving:o?.saving??"Saving...",saved:o?.saved??"Saved!",publish:o?.publish??"Publish",publishing:o?.publishing??"Publishing...",published:o?.published??"Published!",publish_success:o?.publish_success??"Template published successfully.",status_draft:o?.status_draft??"Draft",status_published:o?.status_published??"Published",status_draft_hint:o?.status_draft_hint??"Draft templates are not available in notifications. Click Publish when you are ready.",preview_frontend:o?.preview_frontend??"Frontend Preview",refresh_preview:o?.refresh_preview??"Refresh Preview",title_placeholder:o?.title_placeholder??"Template title",tags_modal_title:o?.tags_modal_title??"Insert Notifal Tag",close:o?.close??"Close",html_copied:o?.html_copied??"HTML copied to clipboard!",tag_inserted:o?.tag_inserted??"Tag inserted.",tag_copied:o?.tag_copied??"Tag copied to clipboard.",save_success:o?.save_success??"Template saved successfully.",save_error:o?.save_error??"Failed to save template. Please try again.",preview_error:o?.preview_error??"Failed to refresh preview. Please try again.",paste_placeholder:o?.paste_placeholder??"<!-- Paste your HTML here… -->",app_name:o?.app_name??"Notifal Builder",app_subtitle:o?.app_subtitle??"Visual HTML template editor",paste_label:o?.paste_label??"Paste your HTML",paste_fragment_hint:o?.paste_fragment_hint??"Paste only the inner content of your notification (no <html>, <head>, or <body> tags). The builder wraps your markup automatically.",paste_no_document_tags:o?.paste_no_document_tags??"Please paste only the notification markup — do not include <html>, <head>, <body>, or <!DOCTYPE> tags.",load_html:o?.load_html??"Load HTML",editing:o?.editing??"Editing",preview_mode:o?.preview_mode??"Preview mode",tags_preview_pending:o?.tags_preview_pending??"Updating tags…",tags_preview_loading:o?.tags_preview_loading??"Rendering tags…",view_html:o?.view_html??"HTML",ai_prompt_button:o?.ai_prompt_button??"AI Prompt",ai_prompt_title:o?.ai_prompt_title??"AI Prompt for HTML Templates",ai_prompt_subtitle:o?.ai_prompt_subtitle??"Copy this prompt into ChatGPT, Claude, or any AI assistant. Paste the generated HTML fragment back into the builder.",ai_prompt_goal_label:o?.ai_prompt_goal_label??"Your notification goal",ai_prompt_goal_placeholder:o?.ai_prompt_goal_placeholder??"e.g. Exit-intent cart recovery popup for my WooCommerce blog…",ai_prompt_color_label:o?.ai_prompt_color_label??"Primary color",ai_prompt_copy:o?.ai_prompt_copy??"Copy Prompt",ai_prompt_copied:o?.ai_prompt_copied??"Copied!",ai_prompt_copy_hint:o?.ai_prompt_copy_hint??"Tip: describe your goal above, copy the prompt, then paste the AI HTML output into the builder.",ai_prompt_footer_text:o?.ai_prompt_footer_text??"Paste it into",ai_prompt_open_claude:o?.ai_prompt_open_claude??"Claude (recommended)",ai_prompt_open_chatgpt:o?.ai_prompt_open_chatgpt??"ChatGPT",ai_prompt_use_case_label:o?.ai_prompt_use_case_label??"Template use case",ai_prompt_use_case_placeholder:o?.ai_prompt_use_case_placeholder??"Select a goal (optional)",ai_prompt_layout_label:o?.ai_prompt_layout_label??"Display layout",ai_prompt_layout_placeholder:o?.ai_prompt_layout_placeholder??"Select a layout (optional)",ai_prompt_industry_label:o?.ai_prompt_industry_label??"Your industry or niche",ai_prompt_industry_placeholder:o?.ai_prompt_industry_placeholder??"e.g. Specialty coffee roastery, Online education for blind students, Luxury skincare boutique…",ai_prompt_industry_hint:o?.ai_prompt_industry_hint??"Be specific so the AI can match tone and visuals to your audience. Any industry works — add detail when it helps.",ai_prompt_examples_title:o?.ai_prompt_examples_title??"How to fill each field",ai_prompt_examples_lead:o?.ai_prompt_examples_lead??"These patterns show what good input looks like. Load one, then replace the placeholders with your own business details.",ai_prompt_examples_show:o?.ai_prompt_examples_show??"See filling examples",ai_prompt_examples_hide:o?.ai_prompt_examples_hide??"Hide examples",ai_prompt_examples_use:o?.ai_prompt_examples_use??"Load this pattern",ai_prompt_examples_active:o?.ai_prompt_examples_active??"Active pattern",welcome_title:o?.welcome_title??"How would you like to start?",welcome_subtitle:o?.welcome_subtitle??"Choose how you want to build your notification template.",welcome_lead:o?.welcome_lead??"Paste existing HTML or generate a template with AI, then refine it in the builder.",welcome_have_html:o?.welcome_have_html??"I have HTML",welcome_have_html_hint:o?.welcome_have_html_hint??"Paste a ready-made HTML fragment into the builder.",welcome_generate_ai:o?.welcome_generate_ai??"Generate with AI",welcome_generate_ai_hint:o?.welcome_generate_ai_hint??"Copy a tailored AI prompt, then paste the generated HTML back here.",welcome_back:o?.welcome_back??"Back",link_href:o?.link_href??"Link URL",link_href_placeholder:o?.link_href_placeholder??"https:// or {product_link}",link_href_hint:o?.link_href_hint??"Use a full URL or a Notifal merge tag such as {product_link}.",countdown_title:o?.countdown_title??"Countdown timer",countdown_hint:o?.countdown_hint??"Set how long the timer runs. Notifal starts the countdown when the notification is shown.",countdown_minutes:o?.countdown_minutes??"Minutes",countdown_seconds:o?.countdown_seconds??"Seconds",countdown_on_complete:o?.countdown_on_complete??"When timer ends",countdown_on_complete_hint:o?.countdown_on_complete_hint??"Choose what happens after the countdown reaches zero.",countdown_on_complete_stay:o?.countdown_on_complete_stay??"Keep showing 00:00",countdown_on_complete_hide:o?.countdown_on_complete_hide??"Hide the timer",countdown_on_complete_close:o?.countdown_on_complete_close??"Close the notification",reset:o?.reset??"Reset",reset_confirm:o?.reset_confirm??"You have unsaved changes. Are you sure you want to reset?",unsaved_changes:o?.unsaved_changes??"You have unsaved changes.",properties:o?.properties??"Properties",elements_panel:o?.elements_panel??"Elements",hide_left_panel:o?.hide_left_panel??"Hide elements panel",show_left_panel:o?.show_left_panel??"Show elements panel",hide_right_panel:o?.hide_right_panel??"Hide properties panel",show_right_panel:o?.show_right_panel??"Show properties panel",no_element_selected:o?.no_element_selected??"No element selected",text_not_editable:o?.text_not_editable??"This element has no direct text to edit.",text_not_editable_hint:o?.text_not_editable_hint??"Select an element that contains text directly inside it, or use the HTML tab for nested markup.",select_element_hint:o?.select_element_hint??"Click any element in the canvas or tree to edit.",load_html_hint:o?.load_html_hint??"Load an HTML template to start editing",canvas_empty_title:o?.canvas_empty_title??"No HTML in this template.",canvas_empty_import_link:o?.canvas_empty_import_link??"Click here to import a new one",html_source:o?.html_source??"HTML Source",html_source_search:o?.html_source_search??"Search HTML",html_source_search_placeholder:o?.html_source_search_placeholder??"Search in HTML…",html_source_search_count:o?.html_source_search_count??"%1$s of %2$s",html_source_search_none:o?.html_source_search_none??"No results",html_source_search_prev:o?.html_source_search_prev??"Previous result",html_source_search_next:o?.html_source_search_next??"Next result",update_html:o?.update_html??"Update HTML",element_html_label:o?.element_html_label??"Element HTML",element_html_hint:o?.element_html_hint??"Edit this element's outerHTML, then click Update HTML. Use a single root tag only.",element_html_invalid:o?.element_html_invalid??"Enter valid HTML for one element only (a single opening and closing tag).",chars:o?.chars??"chars",dismiss_error:o?.dismiss_error??"Dismiss error",duplicate_element:o?.duplicate_element??"Duplicate",remove_element:o?.remove_element??"Remove",image_src:o?.image_src??"Image URL",featured_image_placeholder:o?.featured_image_placeholder??"Featured Image Placeholder",featured_image_placeholder_notice:o?.featured_image_placeholder_notice??"This image is loaded dynamically from the notification context (product, post, or page). Preview shows sample data like Elementor and Block Editor.",featured_image_size_title:o?.featured_image_size_title??"Image Size",featured_image_size_notice:o?.featured_image_size_notice??"Width, height, and border radius apply to the dynamic image injected at render time — not the placeholder wrapper.",media_library:o?.media_library??"Media Library",select_image:o?.select_image??"Select Image",responsive_preview:o?.responsive_preview??"Responsive",device_desktop:o?.device_desktop??"Desktop",device_tablet:o?.device_tablet??"Tablet",device_mobile:o?.device_mobile??"Mobile",preview_width:o?.preview_width??"Preview width",preview_width_drag:o?.preview_width_drag??"Drag to resize preview width",unsaved_leave_confirm:o?.unsaved_leave_confirm??"You have unsaved changes. Leave without saving?",auto_saved:o?.auto_saved??"Auto-saved",select_tool:o?.select_tool??"Select",select_tool_title:o?.select_tool_title??"Select tool (click elements)",deselect:o?.deselect??"Deselect",undo_title:o?.undo_title??"Undo (Ctrl+Z)",redo_title:o?.redo_title??"Redo (Ctrl+Y)",one_element_selected:o?.one_element_selected??"1 element selected",tab_style:o?.tab_style??"Style",tab_content:o?.tab_content??"Content",load_html_to_see_elements:o?.load_html_to_see_elements??"Load HTML to see elements",no_editable_elements:o?.no_editable_elements??"No editable elements found",collapse:o?.collapse??"Collapse",expand:o?.expand??"Expand",text_editable:o?.text_editable??"Text editable",style_editable:o?.style_editable??"Style editable",resize_elements_panel:o?.resize_elements_panel??"Resize elements panel",resize_properties_panel:o?.resize_properties_panel??"Resize properties panel",choose_color:o?.choose_color??"Choose color",color_swatch:o?.color_swatch??"Color swatch",color_presets:o?.color_presets??"Color presets",custom_color:o?.custom_color??"Custom color",html_preview_title:o?.html_preview_title??"HTML Preview",copied:o?.copied??"Copied",style_section_typography:o?.style_section_typography??"Typography",style_section_background:o?.style_section_background??"Background",style_section_spacing:o?.style_section_spacing??"Spacing",style_section_size:o?.style_section_size??"Size",style_font_size:o?.style_font_size??"Font Size",style_font_weight:o?.style_font_weight??"Font Weight",style_line_height:o?.style_line_height??"Line Height",style_text_align:o?.style_text_align??"Text Align",style_color:o?.style_color??"Color",style_background_color:o?.style_background_color??"Background Color",style_padding_top:o?.style_padding_top??"Padding Top",style_padding_right:o?.style_padding_right??"Padding Right",style_padding_bottom:o?.style_padding_bottom??"Padding Bottom",style_padding_left:o?.style_padding_left??"Padding Left",style_margin_top:o?.style_margin_top??"Margin Top",style_margin_bottom:o?.style_margin_bottom??"Margin Bottom",style_width:o?.style_width??"Width",style_height:o?.style_height??"Height",style_border_radius:o?.style_border_radius??"Border Radius",style_object_fit:o?.style_object_fit??"Object Fit",style_font_weight_300:o?.style_font_weight_300??"300 Light",style_font_weight_400:o?.style_font_weight_400??"400 Regular",style_font_weight_500:o?.style_font_weight_500??"500 Medium",style_font_weight_600:o?.style_font_weight_600??"600 Semi-Bold",style_font_weight_700:o?.style_font_weight_700??"700 Bold",style_font_weight_800:o?.style_font_weight_800??"800 Extra Bold",style_font_weight_900:o?.style_font_weight_900??"900 Black",style_align_left:o?.style_align_left??"Left",style_align_center:o?.style_align_center??"Center",style_align_right:o?.style_align_right??"Right",style_align_justify:o?.style_align_justify??"Justify",style_object_fit_cover:o?.style_object_fit_cover??"Cover",style_object_fit_contain:o?.style_object_fit_contain??"Contain",style_object_fit_fill:o?.style_object_fit_fill??"Fill",style_object_fit_none:o?.style_object_fit_none??"None"}}function Kn(){const c=Hu()?.config;return{template_id:c?.template_id??0,title:c?.title??"",initial_html:c?.initial_html??"",post_status:c?.post_status??"draft",can_publish:c?.can_publish??!0,ajax_url:c?.ajax_url??"",templates_list_url:c?.templates_list_url??"",preview_url:c?.preview_url??"",logo_url:c?.logo_url??"",nonce:{save:c?.nonce?.save??"",preview:c?.nonce?.preview??""},user_id:c?.user_id??0,rtl:!!c?.rtl,primary_color:c?.primary_color??"#7e2bd2",active_plugins:Array.isArray(c?.active_plugins)?c.active_plugins:[],use_cases:Array.isArray(c?.use_cases)?c.use_cases:[],display_layouts:Array.isArray(c?.display_layouts)?c.display_layouts:[],ai_prompt_examples:Array.isArray(c?.ai_prompt_examples)?c.ai_prompt_examples:[]}}function Jt(c,o){window.NotifalUtils&&typeof window.NotifalUtils.showMessage=="function"&&window.NotifalUtils.showMessage(o,c)}async function eh(c){const o=Kn(),r=ua(),u=new URLSearchParams;u.append("action","notifal_html_builder_preview"),u.append("_wpnonce",o.nonce.preview),u.append("template_id",String(o.template_id)),u.append("html",c);try{const m=await(await fetch(o.ajax_url,{method:"POST",credentials:"same-origin",headers:{"Content-Type":"application/x-www-form-urlencoded; charset=UTF-8"},body:u.toString()})).json();return m.success?((m.data?.warnings||[]).forEach(y=>{Jt("info",y)}),m.data?.html??null):(Jt("error",m.data?.message||r.preview_error),null)}catch{return Jt("error",r.preview_error),null}}async function th(c,o,r={}){const u=Kn(),f=ua(),m=new URLSearchParams;m.append("action","notifal_save_html_template"),m.append("_wpnonce",u.nonce.save),m.append("template_id",String(u.template_id)),m.append("title",c),m.append("html",o),m.append("publish",r.publish?"1":"0");try{const S=await(await fetch(u.ajax_url,{method:"POST",credentials:"same-origin",headers:{"Content-Type":"application/x-www-form-urlencoded; charset=UTF-8"},body:m.toString()})).json();return S.success?(r.silent||Jt("success",S.data?.message||f.save_success),(S.data?.warnings||[]).forEach(x=>{r.silent||Jt("info",x)}),{success:!0,previewUrl:S.data?.preview_url||void 0,postStatus:S.data?.post_status||void 0}):(r.silent||Jt("error",S.data?.message||f.save_error),{success:!1})}catch{return r.silent||Jt("error",f.save_error),{success:!1}}}function lh(){const c=document.getElementById("notifal-html-builder-tags-modal");c&&(c.classList.add("notifal-modal-active"),c.classList.remove("notifal-hidden"))}function Du(){const c=document.getElementById("notifal-html-builder-tags-modal");c&&(c.classList.remove("notifal-modal-active"),c.classList.add("notifal-hidden"))}function Ro(c="notifal-html-builder-loader"){const o=document.getElementById(c);o&&(o.classList.add("notifal-loaded"),o.setAttribute("aria-busy","false"))}function Ou(c){const o=c.querySelector(".notifal-tag-text"),r=o?.dataset.originalText?.trim(),u=o?.textContent?.replace(/ - Copied$/,"").trim()??"",f=c.dataset.tagText?.trim()??"";return o&&u&&!o.dataset.originalText&&(o.dataset.originalText=u),r||u||f}function ah(c){const o=c.querySelector(".notifal-tag-text"),r=Ou(c),u=ua();!o||!r||(c.classList.add("copied"),o.textContent=`${r} - ${u.copied}`,window.setTimeout(()=>{c.classList.remove("copied"),o.textContent=r},1500))}async function Ru(c){const o=ua(),r=c.startsWith("{")?c:`{${c}}`,u=()=>{Jt("success",o.tag_copied)};if(navigator.clipboard&&navigator.clipboard.writeText)try{await navigator.clipboard.writeText(r),u();return}catch{}const f=document.createElement("textarea");f.value=r,f.setAttribute("readonly","readonly"),f.className="notifal-hidden",document.body.appendChild(f),f.select();try{document.execCommand("copy"),u()}catch{Jt("error",o.save_error)}document.body.removeChild(f)}function nh(){const c=document.getElementById("notifal-html-builder-tags-modal"),o=document.getElementById("notifal-html-builder-tags-close"),r=window.createDynamicKeysPopup;o?.addEventListener("click",Du),c?.addEventListener("click",u=>{const f=u.target;if(!f)return;if(f.id==="notifal-html-builder-tags-modal"){Du();return}const m=f.closest(".notifal-tag");if(!m)return;if(u.preventDefault(),u.stopPropagation(),m.classList.contains("notifal-tag-dynamic")){const S=Ou(m);typeof r=="function"&&S&&r(S,m,{onSelect:x=>{Ru(x)}});return}const y=m.dataset.tagText||"";Ru("{"+y+"}"),ah(m)})}const Uo=g.createContext(null),ih=({children:c})=>{const o=g.useMemo(()=>({config:Kn(),strings:ua()}),[]);return _.jsx(Uo.Provider,{value:o,children:c})};function Jn(){const c=g.useContext(Uo);return c?c.config:Kn()}function Be(){const c=g.useContext(Uo);return c?c.strings:ua()}function oh(c){return!c||c.length===0?"":`## Active plugins on this site

These plugins are currently active on my WordPress site. I list them so you can reuse their **shortcodes** inside the template when it genuinely helps the goal (e.g. an opt-in form, a product grid, a countdown, a rating). Only use a shortcode if you are confident it exists for that plugin; otherwise build plain HTML/CSS instead.

${c.map(r=>`- ${r}`).join(`
`)}

---

`}function ch(c){const o=(c||"").trim();return o?o.split(/[\s,]+/).slice(0,3).join(",").toLowerCase():"business,people"}function sh(){return"## Notifal dynamic merge tags\n\nInsert merge tags exactly as `{tag_name}`. Notifal replaces them on the frontend with live data (and sample data in preview). Only use a tag if its data source matches the notification type. Align `notification.settings.content_source` with the tag families you use.\n\n### Users\n- `{user_id}`, `{user_first_name}`, `{user_last_name}`, `{user_email}`, `{user_username}`\n- `{user_url}`, `{user_nicename}`, `{user_display_name}`\n- `{user_registered_date_{format}}`, `{user_meta_{key}}`\n\n### Posts\n- `{post_id}`, `{post_title}`, `{post_content}`, `{post_excerpt}`, `{post_author}`, `{post_url}`\n- `{post_published_date_{format}}`, `{post_modified_date_{format}}`, `{post_created_date_{format}}`\n- `{post_meta_{key}}`\n\n### Pages\n- `{page_id}`, `{page_title}`, `{page_content}`, `{page_url}`, `{page_parent_title}`\n- `{page_published_date_{format}}`, `{page_modified_date_{format}}`, `{page_meta_{key}}`\n\n### Orders (WooCommerce)\n- `{order_id}`\n- `{order_meta_{key}}` — e.g. `{order_meta__billing_first_name}`, `{order_meta_billing_city}`, `{order_meta_order_total}`\n- `{order_created_date_{format}}`, `{order_completed_date_{format}}`, `{order_paid_date_{format}}`\n\n### Products (WooCommerce)\n- `{product_id}`, `{product_name}`, `{product_link}`\n- `{product_discount_amount}`, `{product_discount_percent}`\n- `{product_meta_{key}}` — e.g. `{product_meta__price}`, `{product_meta__regular_price}`, `{product_meta__sale_price}`, `{product_meta__sku}`, `{product_meta_total_sales}`\n- `{product_publish_date_{format}}`, `{product_modified_date_{format}}`\n\n### Counters\n- `{order_counter}`, `{product_counter}`, `{post_counter}`, `{page_counter}`\n- `{comment_counter}` (Pro), `{custom_posttype_counter_{slug}}`\n\n### Cart (WooCommerce)\n- `{cart_total}`, `{cart_subtotal}`, `{cart_discount}`, `{cart_item_count}`\n- `{cart_unique_products}`, `{cart_coupons}`, `{cart_url}`, `{cart_checkout_url}`\n- `{cart_first_product_name}`\n\n### Comments (Notifal Pro)\n- `{comment_id}`, `{comment_author}`, `{comment_content}`, `{comment_post_title}`\n- `{comment_url}`, `{comment_date_{format}}`, `{comment_meta_{key}}`\n\n### Dynamic tag patterns\n- `{prefix_meta_{key}}` → replace `{key}` with the real meta key. WooCommerce internal keys often start with `_`, e.g. `{product_meta__price}`.\n- `{..._date_{format}}` → PHP date format after `_date_`. Examples: `{order_created_date_Y-m-d}` → `2024-01-15`; `{post_published_date_F j, Y}` → `January 15, 2024`; `{order_created_date_diff}` → `2 days ago`."}function uh(c){return`## Reference example — Recent-sale social proof (Floating Side Box / \`toast\`)

Quality and structure reference only — do not copy this design for other goals:

\`\`\`
<style>
  .notifal-rsale {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: 380px;
    background: #ffffff;
    border-radius: 18px;
    padding: 14px 16px 14px 14px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.04), 0 16px 48px rgba(20,18,40,0.13);
    font-family: Arial, "Helvetica Neue", sans-serif;
    box-sizing: border-box;
    position: relative;
    border-left: 4px solid ${c};
  }
  .notifal-rsale__media {
    flex: 0 0 auto;
    width: 60px;
    height: 60px;
    border-radius: 12px;
    overflow: hidden;
    background: #f3f0fb;
  }
  .notifal-rsale__media .notifal-post-feature-image,
  .notifal-rsale__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    display: block;
  }
  .notifal-rsale__body { flex: 1 1 auto; min-width: 0; }
  .notifal-rsale__badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: ${c};
    margin-bottom: 4px;
  }
  .notifal-rsale__badge::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #22c55e;
    border-radius: 50%;
    animation: notifal-pulse 1.6s ease-in-out infinite;
  }
  .notifal-rsale__message {
    margin: 0 0 8px;
    font-size: 13px;
    line-height: 1.45;
    color: #374151;
  }
  .notifal-rsale__message strong { color: #1f2430; }
  .notifal-rsale__cta {
    display: inline-block;
    padding: 7px 15px;
    background: ${c};
    color: #ffffff !important;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    border-radius: 999px;
    transition: opacity 0.15s;
  }
  .notifal-rsale__cta:hover { opacity: 0.88; }
  .notifal-rsale__close {
    flex: 0 0 auto;
    align-self: flex-start;
    width: 22px;
    height: 22px;
    border: none;
    background: transparent;
    color: #9ca3af;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    border-radius: 4px;
  }
  .notifal-rsale__close:hover { color: #4b5563; }
  @keyframes notifal-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.85); }
  }
  @media (max-width: 480px) {
    .notifal-rsale { max-width: 100%; }
  }
</style>

<div class="notifal-rsale">
  <div class="notifal-rsale__media">
    <div class="notifal-post-feature-image"></div>
  </div>
  <div class="notifal-rsale__body">
    <div class="notifal-rsale__badge">Live sale</div>
    <p class="notifal-rsale__message">
      <strong>{order_meta_billing_first_name}</strong> from
      <strong>{order_meta_billing_city}</strong> just bought
      <strong>{product_name}</strong> —
      <strong>{product_meta_total_sales} others</strong> grabbed it this week!
    </p>
    <a href="{product_link}" class="notifal-action-button notifal-rsale__cta">Shop Now →</a>
  </div>
  <button type="button" class="notifal-close-button notifal-rsale__close" aria-label="Close notification">×</button>
</div>
\`\`\``}function rh(){return'## Notifal special CSS classes (required for behavior)\n\nPlain HTML becomes functional only when these classes **and their data attributes** are set correctly. The class name alone is never enough for copy, ajax add to cart, close-as-action, or custom trigger buttons.\n\n### notifal-post-feature-image\n\nDynamic featured image — empty `<div>`, never use `src`:\n\n`<div class="notifal-post-feature-image"></div>`\n\nOptional attributes:\n\n- `data-preview-image-source` — `auto`, `product`, `post`, `page`, `order`, `comment` (default: `auto`)\n- `data-image-resolution` — WordPress image size (default: `large`)\n- `data-image-lazy-load` — `true` / `false` (default: lazy)\n\n### notifal-close-button\n\nDismisses the notification:\n\n`<button type="button" class="notifal-close-button" aria-label="Close notification">×</button>`\n\nNotifal adds `notifal-close`, `role="button"`, `tabindex="0"`, and `aria-label` when missing.\n\n### notifal-action-button\n\nPrimary CTA with click tracking. Set **`data-notifal-action`** (or **`data-link-type`**) for every non-default button. Do **not** set `data-action` manually — Notifal adds it at render time.\n\n#### Default — post/product link (notification context)\n\n`<a href="#" class="notifal-action-button">Buy now</a>`\n\nOr with an explicit merge tag:\n\n`<a href="{product_link}" class="notifal-action-button">Shop now →</a>`\n\nUse this when the CTA should **navigate to the product/post page**.\n\n#### Explicit action types (`data-notifal-action` or `data-link-type`)\n\n| Action | When to use | Required attributes | Optional attributes |\n|---|---|---|---|\n| `post-link` / `product` | Navigate to context product/post | `href="#"` or `href="{product_link}"` | — |\n| `copy` | Copy coupon, code, or text to clipboard | **`data-copy-text="..."`** (merge tags OK) | `href="#"` |\n| `ajax-add-to-cart` | Add product to cart without leaving the page | `data-notifal-action="ajax-add-to-cart"`; **`data-product-id="{product_id}"`** when no product context | `data-variation-id`, `data-add-to-cart-quantity` (default `1`), `data-add-to-cart-redirect` (`none` / `cart` / `checkout`), `data-add-to-cart-success-text` (default `Added!`) |\n| `close` | Close notification on click | — | `href="#"` |\n| `custom-trigger` | Show/hide other elements | **`data-hide-elements`** and/or **`data-show-elements`** (CSS selectors) | `href="#"` |\n| `custom` | Fixed external URL | `href="https://..."` or `data-custom-url="https://..."` | `data-loading-text` |\n\n#### Copy button (coupon / promo code)\n\n**Always** include both `data-notifal-action="copy"` and `data-copy-text`:\n\n`<a href="#" class="notifal-action-button" data-notifal-action="copy" data-copy-text="SAVE20">Copy code</a>`\n\nWith a merge tag:\n\n`<a href="#" class="notifal-action-button" data-notifal-action="copy" data-copy-text="{product_meta__sku}">Copy code</a>`\n\n#### Ajax add to cart (WooCommerce)\n\nUse when the CTA should **add to cart in place**, not open the product page:\n\n`<a href="#" class="notifal-action-button" data-notifal-action="ajax-add-to-cart" data-add-to-cart-quantity="1" data-add-to-cart-redirect="cart">Add to cart</a>`\n\nWhen product context may be missing, also set `data-product-id="{product_id}"`:\n\n`<a href="#" class="notifal-action-button" data-notifal-action="ajax-add-to-cart" data-product-id="{product_id}" data-add-to-cart-quantity="1">Add to cart</a>`\n\nVariable products: add `data-variation-id="{variation_id}"` when known.\n\n#### Custom URL\n\n`<a href="https://example.com" class="notifal-action-button">Visit</a>`\n\nOr: `data-notifal-action="custom"` + `data-custom-url="https://example.com"`\n\n#### Custom trigger — multi-step templates (show/hide sections)(if needed)\n\nUse **`data-notifal-action="custom-trigger"`** with **`data-hide-elements`** and/or **`data-show-elements`** to build multi-step content inside **one** notification. Each step is a wrapper `<div>` with a unique class. Hide later steps on load with CSS (`display: none`). Buttons on each step reveal the next panel.\n\n**Pattern:**\n\n1. Wrap each step: `<div class="notifal-offer-step-1">`, `notifal-offer-step-2`, etc.\n2. Hide steps 2+ in `<style>`: `.notifal-offer-step-2, .notifal-offer-step-3 { display: none; }`\n3. Add custom-trigger buttons that hide the current step and show the next.\n\n**Two-step example:**\n\n```html\n<style>\n  .notifal-offer-step-2 { display: none; }\n</style>\n<div class="notifal-offer-step-1">\n  <h3>Want 10% off?</h3>\n  <a href="#" class="notifal-action-button"\n     data-notifal-action="custom-trigger"\n     data-hide-elements=".notifal-offer-step-1"\n     data-show-elements=".notifal-offer-step-2">Yes, show my code</a>\n</div>\n<div class="notifal-offer-step-2">\n  <p>Use code <strong>SAVE10</strong> at checkout.</p>\n  <a href="#" class="notifal-action-button"\n     data-notifal-action="copy"\n     data-copy-text="SAVE10">Copy code</a>\n</div>\n```\n\n**Rules for multi-step AI output:**\n\n- Selectors are comma-separated CSS selectors scoped to the notification (e.g. `.notifal-offer-step-1`, `#notifal-step-email`).\n- Every step-advancing button MUST include `data-notifal-action="custom-trigger"` plus at least one of `data-hide-elements` or `data-show-elements`.\n- Keep all steps in the same template HTML string, not separate notifications.\n- Use for progressive forms, yes/no flows, reveal-offer steps, and guided opt-ins.\n- Do **not** set `data-action` manually on any button.\n\n#### Critical rules for AI\n\n- **Copy CTAs** ("Copy code", "Copy coupon"): MUST use `data-notifal-action="copy"` AND `data-copy-text="..."`. Never use only `class="notifal-action-button"`.\n- **Add to cart CTAs** that should not leave the page: MUST use `data-notifal-action="ajax-add-to-cart"`, not `href="{product_link}"`.\n- **Shop / view product CTAs**: use default post-link (`href="#"` or `href="{product_link}"`) without `data-notifal-action`.\n- **Multi-step popups** (progressive forms, yes/no, reveal offer): wrap each step in a unique `notifal-*` class, hide later steps with CSS, advance with `data-notifal-action="custom-trigger"` plus `data-hide-elements` / `data-show-elements`.\n- **Countdown / urgency timers**: MUST use `notifal-countdown` (see below). Do **not** invent custom countdown `<script>` blocks.\n- WooCommerce must be active for ajax add to cart.\n\n### notifal-countdown\n\nLive urgency timer powered by Notifal (no custom JS). Use whenever the design needs a countdown.\n\n**Required structure:**\n\n```html\n<div class="notifal-countdown" data-countdown-seconds="600" data-countdown-format="mm:ss" data-countdown-on-complete="stay" aria-label="Countdown timer">\n  <div class="notifal-countdown__box">\n    <span class="notifal-countdown__value" data-countdown-unit="minutes">10</span>\n    <span class="notifal-countdown__label">Minutes</span>\n  </div>\n  <span class="notifal-countdown__sep">:</span>\n  <div class="notifal-countdown__box">\n    <span class="notifal-countdown__value" data-countdown-unit="seconds">00</span>\n    <span class="notifal-countdown__label">Seconds</span>\n  </div>\n</div>\n```\n\n**Rules:**\n\n- Root element MUST include class `notifal-countdown` and **`data-countdown-seconds`** (total duration as an integer, e.g. `600` for 10 minutes).\n- Each ticking number MUST be a span with `data-countdown-unit` set to one of: `days`, `hours`, `minutes`, `seconds`.\n- Match visible units to the duration (e.g. `mm:ss` → minutes + seconds only; longer offers may add hours/days).\n- Optional **`data-countdown-on-complete`**: `stay` (default, leave 00:00), `hide` (hide the timer), or `close` (dismiss the notification).\n- Style freely with your own `notifal-*` classes on boxes/labels; keep the required class and data attributes above.\n- **Never** include a custom `<script>` countdown when using `notifal-countdown` — Notifal starts the timer on the frontend, and the HTML Builder Content panel edits the duration and on-complete action.\n- Keep initial unit text padded to two digits and consistent with `data-countdown-seconds` (e.g. 600 → minutes `10`, seconds `00`).'}function _h(c){const o=c.primaryColor,r=c.industryKeyword,u=c.pluginsSection||"";return`## Template generation (HTML + CSS for Notifal HTML Builder)

You are a world-class front-end developer and CRO specialist. The template is **only the visible notification UI** — Notifal's wrapper handles display type, position, backdrop, animations, and z-index.

### Visual style selection

Pick ONE personality that fits the industry, goal, and tone:

- **Bold & Energetic** — vivid gradients, heavy typography, urgency-first. Flash sales, cart abandonment.
- **Premium Minimal** — whitespace, refined type, subtle accent. Luxury, SaaS, high-ticket.
- **Warm & Human** — rounded corners, warm neutrals, friendly copy. Food, education, local business.
- **Glass & Depth** — frosted glass, layered surfaces, soft glow. Tech, modern SaaS.
- **Vibrant Social** — bright card, conversational copy, high-energy CTA. Social proof, email capture.

### CRO copy rules

- Lead with **benefit or social proof**, not features
- **One dominant CTA** with action-oriented label
- Match CTA **behavior** to the goal: copy coupon → \`data-notifal-action="copy"\` + \`data-copy-text\`; add to cart in place → \`data-notifal-action="ajax-add-to-cart"\`; visit product → \`href="{product_link}"\`; multi-step / reveal next panel → \`data-notifal-action="custom-trigger"\` + \`data-hide-elements\` / \`data-show-elements\`; urgency timer → \`notifal-countdown\` with \`data-countdown-seconds\` (see class placeholders below)
- Use **Notifal merge tags** (see full list below) where live data adds credibility
- If copy names a product/post/order (e.g. "bought {product_name}"), use \`<div class="notifal-post-feature-image"></div>\` — never a stock photo for that slot
- **Never** output placeholder stubs: \`lorem ipsum\`, \`your text here\`, \`TBD\`, \`...\`
- For countdown / limited-time offers, use \`notifal-countdown\` only — never a custom timer \`<script>\`

### Images (dynamic featured image vs decorative stock)

**If copy references a product, order, post, or page**, the image must be the **featured image** at runtime — not loremflickr.

**A) Dynamic featured image** — use \`<div class="notifal-post-feature-image"></div>\` (no \`src\`) when using \`{product_name}\`, \`{post_title}\`, \`{order_meta_*}\`, "just bought", etc.

**B) Decorative stock** — loremflickr on \`<img>\` only when the image is not tied to merge-tag entities:
\`https://loremflickr.com/{width}/{height}/{keywords}?lock=42\` e.g. \`https://loremflickr.com/80/80/${r}?lock=42\`

**When in doubt:** social proof / "X bought Y" → always **A**, never **B**.

### Critical template rules

- Return **HTML fragment only** for the final template output — raw HTML, no markdown fences around it.
- Do NOT split CSS and HTML across multiple messages.
- No \`<!DOCTYPE>\`, \`<html>\`, \`<head>\`, \`<body>\`, wrapper divs, backdrop overlay, or page positioning.
- **Prefix every class and id with \`notifal-\`**.
- Start with one \`<style>\` block (all CSS), then HTML markup. Fully responsive.
- **Never** use \`position: fixed/absolute/sticky\`, \`top/right/bottom/left\`, \`z-index\`, or \`inset\` for page placement.
- No external stylesheets or \`@import\`.

### How Notifal renders templates

Injected inside \`.notifal-onpage-notification-wrapper\` which handles display type, position, backdrop, animations.

| Display type | Best for | Design width |
|---|---|---|
| \`toast\` | Social proof, recent sales, cart nudges | ~360–500px max |
| \`popup\` | Exit intent, lead capture, offers | ~480–560px centered |
| \`topbar\` | Announcements, sitewide promos | 100% width strip |

### Styling approach

Modern UI: whitespace, type hierarchy, soft elevation, cohesive color. Use \`max-width: 100%\`, \`box-sizing: border-box\`, \`@media (max-width: 480px)\`, tap-friendly buttons (min ~44px).

### Brand color

Primary: **${o}** — CTAs, accents, badges, gradient origins. Neutrals: text \`#1f2430\`, muted \`#6b7280\`, borders \`#e5e7eb\`.

### Forms

If needed: build form UI only + comment \`<!-- Replace this form with your form builder shortcode -->\`

${u}${rh()}

${sh()}

---

## Accessibility & quality

- Semantic HTML (\`<button>\` for actions, \`<a>\` for links)
- \`aria-label\` on icon-only close buttons
- Readable font sizes (14px+ body), 4.5:1 contrast on body text
- Single dominant CTA

${uh(o)}`}function fh(){return`## Step 3 — Notifal settings recommendations

After the HTML, output a **"⚙️ Recommended Notifal Settings"** section. This is practical advice the user follows manually in the Notifal notification editor.

\`\`\`
⚙️ Recommended Notifal Settings

APPEARANCE
- Display type, position, animations — with one-line conversion reasons

TIMING
- Trigger, duration, frequency — with reasons

DISPLAY RULES (if relevant)

BEHAVIOR
- Close on action, dismiss options

CONTENT SOURCE (if dynamic tags used)
- Source type and filters aligned with merge tags in the template
\`\`\``}function dh(){return`## Final deliverable format

Respond in this exact order:

1. **Visual style chosen** — name + one sentence why.
2. **Display type** — confirm or recommend with conversion justification.
3. **Assumptions (if any)** — one line per assumption.
4. **The complete HTML fragment** — \`<style>\` + markup, raw HTML only, no markdown fences.
5. **⚙️ Recommended Notifal Settings** — as described in Step 3.`}const Lo="#7e2bd2";function Uu(c){const o=c.trim();return/^#[0-9a-fA-F]{3}$/.test(o)||/^#[0-9a-fA-F]{6}$/.test(o)?o:Lo}function mh(c){const o=["## My request"];c.displayLayout&&(o.push(`**Display layout:** ${c.displayLayout.label} (\`${c.displayLayout.value}\`)`),o.push(c.displayLayout.description),o.push("")),c.useCase&&(o.push(`**Use case:** ${c.useCase.label}`),o.push(c.useCase.description),o.push(""));const r=c.industry?.trim();r&&(o.push(`**Industry / niche:** ${r}`),o.push(""));const u=c.userGoal?.trim();return u?o.push(`**Notification goal:** ${u}`):o.push('**Notification goal:** (Describe your notification goal here before sending — e.g. "exit-intent cart recovery popup for WooCommerce" or "recent-sale social-proof floating side box".)'),o.push(""),o.join(`
`)}function hh(c){const o=Uu(c.primaryColor),r=mh(c),u=oh(c.activePlugins),f=ch(c.industry),m=_h({primaryColor:o,industryKeyword:f,pluginsSection:u});return`${r}---

You are a world-class front-end developer and conversion-rate optimization (CRO) specialist creating HTML/CSS notification templates for **Notifal** — a WordPress popup and on-page notification plugin.

Your north star is **conversions**, not just aesthetics.

---

## Step 1 — Clarify before you build (only if needed)

Read "My request" above carefully.

**If the goal is clear enough**, skip directly to Step 2 and generate the template.

**If critical information is missing**, ask ALL questions in a single message. A goal is "clear enough" if you can choose display type, visual style, copy angle, and relevant dynamic tags.

---

## Step 2 — Generate the template

If the user selected a display layout, use it unless you clearly explain why another type converts better and ask to proceed.

${m}

---

${fh()}

---

${dh()}

Generate the template now.`}const P={overlay:"_overlay_14fhm_5",modal:"_modal_14fhm_41",modal__header:"_modal__header_14fhm_77",modal__title_wrap:"_modal__title_wrap_14fhm_97",modal__title:"_modal__title_14fhm_97",modal__subtitle:"_modal__subtitle_14fhm_123",modal__close:"_modal__close_14fhm_139",modal__controls:"_modal__controls_14fhm_177","modal__controls--stacked":"_modal__controls--stacked_14fhm_195",modal__controls_row:"_modal__controls_row_14fhm_203","modal__controls_row--single":"_modal__controls_row--single_14fhm_215",modal__select:"_modal__select_14fhm_223",modal__use_case_guide:"_modal__use_case_guide_14fhm_257",modal__field_hint:"_modal__field_hint_14fhm_279",examples:"_examples_14fhm_297",examples__toggle_row:"_examples__toggle_row_14fhm_315",examples__toggle:"_examples__toggle_14fhm_315",examples__toggle_icon:"_examples__toggle_icon_14fhm_367","examples__toggle_icon--open":"_examples__toggle_icon--open_14fhm_383",examples__toggle_active:"_examples__toggle_active_14fhm_391",examples__header:"_examples__header_14fhm_411",examples__title:"_examples__title_14fhm_423",examples__lead:"_examples__lead_14fhm_437",examples__list:"_examples__list_14fhm_451",examples__card:"_examples__card_14fhm_469","examples__card--active":"_examples__card--active_14fhm_507",examples__card_top:"_examples__card_top_14fhm_519",examples__card_title:"_examples__card_title_14fhm_535",examples__swatch:"_examples__swatch_14fhm_549",examples__tags:"_examples__tags_14fhm_567",examples__tag:"_examples__tag_14fhm_567",examples__industry:"_examples__industry_14fhm_601",examples__action:"_examples__action_14fhm_621",examples__active:"_examples__active_14fhm_623",modal__field:"_modal__field_14fhm_279",modal__label:"_modal__label_14fhm_655",modal__input:"_modal__input_14fhm_667",modal__goal:"_modal__goal_14fhm_669",modal__body:"_modal__body_14fhm_717",modal__prompt:"_modal__prompt_14fhm_731",modal__footer:"_modal__footer_14fhm_775",modal__hint:"_modal__hint_14fhm_795",modal__link:"_modal__link_14fhm_809",modal__footer_actions:"_modal__footer_actions_14fhm_829"},ph=({examples:c,displayLayouts:o,useCases:r,activeExampleId:u,onSelect:f})=>{const m=Be(),y=g.useMemo(()=>new Map(o.map(h=>[h.slug,h.label])),[o]),S=g.useMemo(()=>new Map(r.map(h=>[h.slug,h.label])),[r]),x=g.useCallback((h,A)=>{(h.key==="Enter"||h.key===" ")&&(h.preventDefault(),f(A))},[f]);return c.length===0?null:_.jsxs("section",{className:P.examples,"aria-labelledby":"notifal-ai-prompt-examples-title",children:[_.jsxs("div",{className:P.examples__header,children:[_.jsx("h3",{id:"notifal-ai-prompt-examples-title",className:P.examples__title,children:m.ai_prompt_examples_title}),_.jsx("p",{className:P.examples__lead,children:m.ai_prompt_examples_lead})]}),_.jsx("div",{className:P.examples__list,role:"list",children:c.map(h=>{const A=u===h.id,C=y.get(h.layout_slug)??h.layout_slug,Y=S.get(h.use_case_slug)??h.use_case_slug;return _.jsxs("button",{type:"button",role:"listitem",className:[P.examples__card,A?P["examples__card--active"]:""].filter(Boolean).join(" "),onClick:()=>f(h),onKeyDown:R=>x(R,h),"aria-pressed":A,"aria-label":`${m.ai_prompt_examples_use}: ${h.title}`,children:[_.jsxs("span",{className:P.examples__card_top,children:[_.jsx("span",{className:P.examples__card_title,children:h.title}),_.jsx("span",{className:P.examples__swatch,style:{backgroundColor:h.primary_color},"aria-hidden":"true"})]}),_.jsxs("span",{className:P.examples__tags,children:[_.jsx("span",{className:P.examples__tag,children:C}),_.jsx("span",{className:P.examples__tag,children:Y})]}),_.jsx("span",{className:P.examples__industry,children:h.industry}),A?_.jsx("span",{className:P.examples__active,children:m.ai_prompt_examples_active}):_.jsx("span",{className:P.examples__action,children:m.ai_prompt_examples_use})]},h.id)})})]})},Lu=({variant:c="modal",onBack:o,onClose:r})=>{const u=Be(),f=Jn(),[m,y]=g.useState(f.primary_color||Lo),[S,x]=g.useState(""),[h,A]=g.useState(""),[C,Y]=g.useState(""),[R,L]=g.useState(""),[G,Z]=g.useState(""),[q,X]=g.useState(!1),[j,F]=g.useState(!1),ae=g.useMemo(()=>f.use_cases.find(le=>le.slug===h)??null,[f.use_cases,h]),ne=g.useMemo(()=>f.display_layouts.find(le=>le.slug===C)??null,[f.display_layouts,C]),K=g.useMemo(()=>hh({primaryColor:Uu(m),userGoal:S,industry:R,activePlugins:f.active_plugins,useCase:ae,displayLayout:ne}),[m,S,R,f.active_plugins,ae,ne]),se=g.useCallback(async()=>{try{await navigator.clipboard.writeText(K),F(!0),window.setTimeout(()=>F(!1),2e3)}catch{}},[K]),Ee=g.useCallback(le=>{Y(le.layout_slug),A(le.use_case_slug),L(le.industry),x(le.user_goal),y(le.primary_color),Z(le.id),X(!1)},[]),$=g.useCallback(()=>{X(le=>!le)},[]),_e=g.useMemo(()=>G?f.ai_prompt_examples.find(le=>le.id===G)?.title??"":"",[G,f.ai_prompt_examples]),ve=g.useCallback(le=>{G&&Z(""),le()},[G]),ke=c==="embedded";return _.jsxs(_.Fragment,{children:[ke?null:_.jsxs("div",{className:P.modal__header,children:[_.jsxs("div",{className:P.modal__title_wrap,children:[_.jsx("h2",{id:"notifal-ai-prompt-title",className:P.modal__title,children:u.ai_prompt_title}),_.jsx("p",{className:P.modal__subtitle,children:u.ai_prompt_subtitle})]}),r?_.jsx("button",{type:"button",className:P.modal__close,onClick:r,"aria-label":u.close,children:_.jsx(de,{name:"x-circle",size:14})}):null]}),_.jsxs("div",{className:[P.modal__controls,P["modal__controls--stacked"]].join(" "),children:[f.ai_prompt_examples.length>0?_.jsx("div",{className:P.examples__toggle_row,children:_.jsxs("button",{type:"button",className:P.examples__toggle,onClick:$,"aria-expanded":q,"aria-controls":"notifal-ai-prompt-examples-panel",children:[_.jsx("span",{className:[P.examples__toggle_icon,q?P["examples__toggle_icon--open"]:""].filter(Boolean).join(" "),"aria-hidden":"true",children:_.jsx(de,{name:"chevron-down1",size:14})}),_.jsx("span",{children:q?u.ai_prompt_examples_hide:u.ai_prompt_examples_show}),!q&&_e?_.jsx("span",{className:P.examples__toggle_active,children:_e}):null]})}):null,q&&f.ai_prompt_examples.length>0?_.jsx("div",{id:"notifal-ai-prompt-examples-panel",children:_.jsx(ph,{examples:f.ai_prompt_examples,displayLayouts:f.display_layouts,useCases:f.use_cases,activeExampleId:G,onSelect:Ee})}):null,_.jsxs("div",{className:P.modal__controls_row,children:[_.jsxs("div",{className:P.modal__field,children:[_.jsx("label",{className:P.modal__label,htmlFor:"notifal-ai-prompt-layout",children:u.ai_prompt_layout_label}),_.jsxs("select",{id:"notifal-ai-prompt-layout",className:P.modal__select,value:C,onChange:le=>ve(()=>Y(le.target.value)),children:[_.jsx("option",{value:"",children:u.ai_prompt_layout_placeholder}),f.display_layouts.map(le=>_.jsx("option",{value:le.slug,children:le.label},le.slug))]})]}),_.jsxs("div",{className:P.modal__field,children:[_.jsx("label",{className:P.modal__label,htmlFor:"notifal-ai-prompt-use-case",children:u.ai_prompt_use_case_label}),_.jsxs("select",{id:"notifal-ai-prompt-use-case",className:P.modal__select,value:h,onChange:le=>ve(()=>A(le.target.value)),children:[_.jsx("option",{value:"",children:u.ai_prompt_use_case_placeholder}),f.use_cases.map(le=>_.jsx("option",{value:le.slug,children:le.label},le.slug))]})]})]}),ne?_.jsx("p",{className:P.modal__use_case_guide,role:"note",children:ne.description}):null,ae?_.jsx("p",{className:P.modal__use_case_guide,role:"note",children:ae.description}):null,_.jsxs("div",{className:P.modal__field,children:[_.jsx("label",{className:P.modal__label,htmlFor:"notifal-ai-prompt-industry",children:u.ai_prompt_industry_label}),_.jsx("input",{id:"notifal-ai-prompt-industry",type:"text",className:P.modal__input,value:R,onChange:le=>ve(()=>L(le.target.value)),placeholder:u.ai_prompt_industry_placeholder,spellCheck:!0,autoComplete:"off"}),_.jsx("p",{className:P.modal__field_hint,children:u.ai_prompt_industry_hint})]}),_.jsxs("div",{className:[P.modal__controls_row,P["modal__controls_row--single"]].join(" "),children:[_.jsxs("div",{className:P.modal__field,children:[_.jsx("label",{className:P.modal__label,htmlFor:"notifal-ai-prompt-goal",children:u.ai_prompt_goal_label}),_.jsx("textarea",{id:"notifal-ai-prompt-goal",className:P.modal__goal,value:S,onChange:le=>ve(()=>x(le.target.value)),placeholder:u.ai_prompt_goal_placeholder,spellCheck:!0})]}),_.jsxs("div",{className:P.modal__field,children:[_.jsx("label",{className:P.modal__label,htmlFor:"notifal-ai-prompt-color",children:u.ai_prompt_color_label}),_.jsx("input",{id:"notifal-ai-prompt-color",type:"text",className:P.modal__input,value:m,onChange:le=>ve(()=>y(le.target.value)),placeholder:Lo,spellCheck:!1})]})]})]}),_.jsx("div",{className:P.modal__body,children:_.jsx("textarea",{className:P.modal__prompt,value:K,readOnly:!0,"aria-label":u.ai_prompt_title})}),_.jsxs("div",{className:P.modal__footer,children:[_.jsxs("p",{className:P.modal__hint,children:[u.ai_prompt_footer_text," ",_.jsx("a",{className:P.modal__link,href:"https://claude.ai",target:"_blank",rel:"noopener noreferrer",children:u.ai_prompt_open_claude})," / ",_.jsx("a",{className:P.modal__link,href:"https://chatgpt.com",target:"_blank",rel:"noopener noreferrer",children:u.ai_prompt_open_chatgpt})]}),_.jsxs("div",{className:P.modal__footer_actions,children:[o?_.jsx(Pe,{variant:"secondary",size:"sm",onClick:o,children:u.welcome_back}):null,r&&!ke?_.jsx(Pe,{variant:"secondary",size:"sm",onClick:r,children:u.close}):null,_.jsx(Pe,{variant:"primary",size:"sm",onClick:se,children:j?u.ai_prompt_copied:u.ai_prompt_copy})]})]})]})},yh=({onClose:c})=>{g.useEffect(()=>{const r=u=>{u.key==="Escape"&&c()};return window.addEventListener("keydown",r),()=>window.removeEventListener("keydown",r)},[c]);const o=g.useCallback(r=>{r.target===r.currentTarget&&c()},[c]);return _.jsx("div",{className:P.overlay,onClick:o,role:"dialog","aria-modal":"true","aria-labelledby":"notifal-ai-prompt-title",children:_.jsx("div",{className:P.modal,children:_.jsx(Lu,{variant:"modal",onClose:c})})})},Ve={topbar:"_topbar_ipcu5_3",topbar__left:"_topbar__left_ipcu5_18",topbar__back:"_topbar__back_ipcu5_25",topbar__logo:"_topbar__logo_ipcu5_43",topbar__logo_image:"_topbar__logo_image_ipcu5_50",topbar__logo_name:"_topbar__logo_name_ipcu5_57",topbar__dirty_dot:"_topbar__dirty_dot_ipcu5_64",topbar__title:"_topbar__title_ipcu5_79",topbar__post_status:"_topbar__post_status_ipcu5_98","topbar__post_status--draft":"_topbar__post_status--draft_ipcu5_108","topbar__post_status--published":"_topbar__post_status--published_ipcu5_114",topbar__center:"_topbar__center_ipcu5_120",topbar__status:"_topbar__status_ipcu5_125","topbar__status--tags_pending":"_topbar__status--tags_pending_ipcu5_138","topbar__status--tags_loading":"_topbar__status--tags_loading_ipcu5_144",topbar__status_spinner:"_topbar__status_spinner_ipcu5_150",topbar__actions:"_topbar__actions_ipcu5_166",topbar__separator:"_topbar__separator_ipcu5_174",topbar__preview_link:"_topbar__preview_link_ipcu5_181",topbar__save_success:"_topbar__save_success_ipcu5_201"},gh=()=>_.jsx("span",{className:Ve.topbar__status_spinner,"aria-hidden":"true"}),vh=2e3,bh=45e3,xh=()=>{const c=Jn(),o=Be(),r=Q(U=>U.isDirty),u=Q(U=>U.isPreviewMode),f=Q(U=>U.nodes.length>0),m=Q(U=>U.exportHtml),y=Q(U=>U.markClean),S=Q(U=>U.setAutoSaving),x=Q(U=>U.setLastSavedAt),h=Q(U=>U.togglePreview),A=Q(U=>U.openHtmlModal),C=Q(U=>U.rawHtml),Y=Q(U=>U.tagPreviewStatus),R=Y!=="idle",[L,G]=g.useState(c.title),[Z,q]=g.useState(c.preview_url),[X,j]=g.useState(c.post_status),[F,ae]=g.useState(!1),[ne,K]=g.useState(!1),[se,Ee]=g.useState(!1),$=X!=="publish",_e=c.can_publish,ve=$&&_e?o.publish:o.save,ke=$&&_e?o.publishing:o.saving,le=$&&_e?o.published:o.saved;g.useEffect(()=>{if(!se)return;const U=window.setTimeout(()=>{Ee(!1)},vh);return()=>window.clearTimeout(U)},[se]);const oe=g.useCallback(async(U=!1)=>{K(!0),Ee(!1),U&&S(!0);const ee=await th(L,m(),{silent:U,publish:!U&&_e});ee.success&&(y(),x(Date.now()),ee.previewUrl&&q(ee.previewUrl),ee.postStatus&&j(ee.postStatus),U||Ee(!0)),K(!1),S(!1)},[L,m,y,S,x,_e]);g.useEffect(()=>{if(!r||!f||ne)return;const U=window.setTimeout(()=>{oe(!0)},bh);return()=>window.clearTimeout(U)},[r,f,ne,C,L,oe]);const M=g.useCallback(U=>{if(!r)return;window.confirm(o.unsaved_leave_confirm)||U.preventDefault()},[r,o.unsaved_leave_confirm]);return _.jsxs(_.Fragment,{children:[_.jsxs("header",{className:Ve.topbar,children:[_.jsxs("div",{className:Ve.topbar__left,children:[_.jsxs("a",{href:c.templates_list_url,className:Ve.topbar__back,onClick:M,children:[_.jsx(de,{name:"arrow-left-short",size:14}),_.jsx("span",{children:o.back_to_templates})]}),_.jsxs("div",{className:Ve.topbar__logo,children:[c.logo_url?_.jsx("img",{src:c.logo_url,alt:o.app_name,className:Ve.topbar__logo_image,width:30,height:30}):null,_.jsx("span",{className:Ve.topbar__logo_name,children:o.app_name}),r&&f?_.jsx("span",{className:Ve.topbar__dirty_dot,title:o.unsaved_changes}):null]})]}),_.jsx("input",{type:"text",className:Ve.topbar__title,value:L,onChange:U=>G(U.target.value),placeholder:o.title_placeholder,"aria-label":o.title_placeholder}),f?_.jsx("span",{className:[Ve.topbar__post_status,$?Ve["topbar__post_status--draft"]:Ve["topbar__post_status--published"]].join(" "),title:$?o.status_draft_hint:o.status_published,children:$?o.status_draft:o.status_published}):null,f?_.jsx("div",{className:Ve.topbar__center,children:_.jsx("span",{className:[Ve.topbar__status,Y==="pending"?Ve["topbar__status--tags_pending"]:"",Y==="loading"?Ve["topbar__status--tags_loading"]:""].filter(Boolean).join(" "),role:R?"status":void 0,"aria-live":R?"polite":void 0,children:R?_.jsxs(_.Fragment,{children:[_.jsx(gh,{}),_.jsx("span",{children:Y==="pending"?o.tags_preview_pending:o.tags_preview_loading})]}):_.jsx("span",{children:u?o.preview_mode:o.editing})})}):null,_.jsxs("div",{className:Ve.topbar__actions,children:[_.jsx(Pe,{variant:"secondary",size:"sm",icon:_.jsx(de,{name:"ai",size:14}),onClick:()=>ae(!0),title:o.ai_prompt_title,children:o.ai_prompt_button}),_.jsx(Pe,{variant:"secondary",size:"sm",icon:_.jsx(de,{name:"file-earmark-code",size:16}),onClick:A,title:o.view_html,children:o.view_html}),f?_.jsxs(_.Fragment,{children:[_.jsx(Pe,{variant:"secondary",size:"sm",icon:_.jsx(de,{name:"tags-fill",size:14}),onClick:lh,title:o.insert_tag,children:o.insert_tag}),Z?_.jsxs("a",{href:Z,className:Ve.topbar__preview_link,target:"_blank",rel:"noopener noreferrer",children:[_.jsx(de,{name:"eye",size:15}),_.jsx("span",{children:o.preview_frontend})]}):null,_.jsx("div",{className:Ve.topbar__separator}),_.jsx(Pe,{variant:u?"primary":"secondary",size:"sm",icon:_.jsx(de,{name:"eye",size:15}),onClick:h,title:o.preview_mode,children:u?o.editing:o.preview_mode}),_.jsx(Pe,{variant:"primary",size:"sm",icon:se?_.jsx(de,{name:"check",size:14}):void 0,onClick:()=>oe(!1),loading:ne,title:$?o.status_draft_hint:o.save,className:se?Ve.topbar__save_success:void 0,children:ne?ke:se?le:ve})]}):r?_.jsx(Pe,{variant:"primary",size:"sm",icon:se?_.jsx(de,{name:"check",size:14}):void 0,onClick:()=>oe(!1),loading:ne,title:$?o.status_draft_hint:o.save,className:se?Ve.topbar__save_success:void 0,children:ne?ke:se?le:ve}):null]})]}),F?_.jsx(yh,{onClose:()=>ae(!1)}):null]})},Ye={panel:"_panel_i7hg9_5",panel__header:"_panel__header_i7hg9_18",panel__header_title:"_panel__header_title_i7hg9_29",panel__header_count:"_panel__header_count_i7hg9_40",panel__header_actions:"_panel__header_actions_i7hg9_49",panel__body:"_panel__body_i7hg9_58",panel__tree_body:"_panel__tree_body_i7hg9_74",panel__empty:"_panel__empty_i7hg9_83",panel__footer:"_panel__footer_i7hg9_99",tree__list:"_tree__list_i7hg9_110",tree__empty:"_tree__empty_i7hg9_114",element__item:"_element__item_i7hg9_127","element__item--selected":"_element__item--selected_i7hg9_145",element__preview:"_element__preview_i7hg9_153",element__item_inner:"_element__item_inner_i7hg9_158",element__toggle:"_element__toggle_i7hg9_168","element__toggle--hidden":"_element__toggle--hidden_i7hg9_189",element__chevron:"_element__chevron_i7hg9_194","element__chevron--expanded":"_element__chevron--expanded_i7hg9_198",element__tag:"_element__tag_i7hg9_204",element__badges:"_element__badges_i7hg9_230","element__badge--text":"_element__badge--text_i7hg9_237","element__badge--style":"_element__badge--style_i7hg9_238"},Sh={h1:"#e85d6b",h2:"#e85d6b",h3:"#e85d6b",h4:"#e85d6b",h5:"#e85d6b",h6:"#e85d6b",p:"#2d7fd3",span:"#2d9c5e",a:"#d36b2d",button:"#9b59b6",div:"#95a5a6",section:"#7f8c8d",article:"#7f8c8d",ul:"#c0392b",ol:"#c0392b",li:"#e74c3c",img:"#27ae60",input:"#9b59b6",form:"#8e44ad",table:"#2980b9",td:"#3498db",th:"#2980b9",label:"#16a085",nav:"#2c3e50",header:"#2c3e50",footer:"#2c3e50",main:"#2c3e50"};function wh(c){return Sh[c]??"#6B6A72"}const Bo=g.memo(({node:c,isSelected:o,isExpanded:r,onSelect:u,onContextMenu:f,onToggleExpand:m})=>{const y=Be(),S=c.children.length>0,x=c.depth*14,h=g.useCallback(L=>{L.stopPropagation(),u(c.id)},[c.id,u]),A=g.useCallback(L=>{L.stopPropagation(),m(c.id)},[c.id,m]),C=g.useCallback(L=>{L.preventDefault(),L.stopPropagation(),f(c.id,L)},[c.id,f]),Y=wh(c.tagName),R=c.textContent?c.textContent.slice(0,28)+(c.textContent.length>28?"…":""):"";return _.jsx("div",{className:[Ye.element__item,o?Ye["element__item--selected"]:""].filter(Boolean).join(" "),"data-node-id":c.id,onClick:h,onContextMenu:C,role:"treeitem","aria-selected":o,tabIndex:0,onKeyDown:L=>{(L.key==="Enter"||L.key===" ")&&(L.preventDefault(),u(c.id))},children:_.jsxs("div",{className:Ye.element__item_inner,style:{paddingInlineStart:`${8+x}px`},children:[_.jsx("button",{className:[Ye.element__toggle,S?"":Ye["element__toggle--hidden"]].filter(Boolean).join(" "),onClick:A,"aria-label":r?y.collapse:y.expand,tabIndex:-1,children:S?_.jsx(de,{name:"chevron-right",size:10,className:[Ye.element__chevron,r?Ye["element__chevron--expanded"]:""].filter(Boolean).join(" ")}):null}),_.jsx("span",{className:Ye.element__tag,style:{color:Y,borderColor:Y+"33",backgroundColor:Y+"12"},children:c.tagName}),R&&_.jsx("span",{className:Ye.element__preview,title:c.textContent,children:R}),_.jsxs("div",{className:Ye.element__badges,children:[c.isTextEditable&&_.jsx("span",{className:Ye["element__badge--text"],title:y.text_editable,children:_.jsx(de,{name:"pencil-square",size:9})}),c.isStyleEditable&&_.jsx("span",{className:Ye["element__badge--style"],title:y.style_editable,children:_.jsx(de,{name:"sliders2",size:9})})]})]})})});Bo.displayName="ElementItem";function Eh(c,o){const r=[];function u(f){const m=f.children.length>0,y=o.has(f.id);if(r.push({node:f,depth:f.depth,hasChildren:m,isExpanded:y}),y&&m)for(const S of f.children)u(S)}for(const f of c)u(f);return r}const ql=32,Bu=5,Th=({items:c,height:o,selectedNodeId:r,onSelect:u,onContextMenu:f,onToggleExpand:m})=>{const y=g.useRef(null),[S,x]=g.useState(0),h=c.length*ql,A=Math.ceil(o/ql),C=Math.max(0,Math.floor(S/ql)-Bu),Y=Math.min(c.length,C+A+Bu*2),R=g.useCallback(()=>{y.current&&x(y.current.scrollTop)},[]);g.useEffect(()=>{const q=y.current;if(q)return q.addEventListener("scroll",R,{passive:!0}),()=>q.removeEventListener("scroll",R)},[R]),g.useEffect(()=>{const q=y.current;if(!r||!q)return;const X=c.findIndex(K=>K.node.id===r);if(X<0)return;const j=X*ql,F=j+ql,ae=q.scrollTop,ne=ae+q.clientHeight;if(j<ae){q.scrollTop=j,x(j);return}if(F>ne){const K=F-q.clientHeight;q.scrollTop=K,x(K)}},[r,c]);const L=c.slice(C,Y),G=C*ql,Z=(c.length-Y)*ql;return _.jsx("div",{ref:y,className:Ye.panel__body,style:{height:o,overflowY:"auto"},children:_.jsx("div",{style:{height:h,position:"relative"},children:_.jsx("div",{style:{paddingTop:G,paddingBottom:Z},children:L.map(({node:q,isExpanded:X})=>_.jsx(Bo,{node:q,isSelected:r===q.id,isExpanded:X,onSelect:u,onContextMenu:f,onToggleExpand:m},q.id))})})})},Nh=({nodes:c,selectedNodeId:o,onSelect:r,onContextMenu:u,containerHeight:f})=>{const m=Be(),[y,S]=g.useState(()=>new Set(c.map(C=>C.id))),x=g.useCallback(C=>{S(Y=>{const R=new Set(Y);return R.has(C)?R.delete(C):R.add(C),R})},[]),h=g.useMemo(()=>Eh(c,y),[c,y]);g.useEffect(()=>{if(!o)return;const C=Bm(c,o);C.length!==0&&S(Y=>{const R=new Set(Y);let L=!1;return C.forEach(G=>{R.has(G)||(R.add(G),L=!0)}),L?R:Y})},[o,c]);const A=g.useRef(null);return g.useEffect(()=>{if(!o||h.length>80||!A.current)return;A.current.querySelector(`[data-node-id="${o}"]`)?.scrollIntoView({block:"nearest",behavior:"smooth"})},[o,h]),h.length===0?_.jsx("div",{className:Ye.tree__empty,children:_.jsx("p",{children:m.no_editable_elements})}):h.length>80?_.jsx(Th,{items:h,height:f,selectedNodeId:o,onSelect:r,onContextMenu:u,onToggleExpand:x}):_.jsx("div",{className:Ye.tree__list,role:"tree",ref:A,children:h.map(({node:C,isExpanded:Y})=>_.jsx(Bo,{node:C,isSelected:o===C.id,isExpanded:Y,onSelect:r,onContextMenu:u,onToggleExpand:x},C.id))})},$n={menu:"_menu_zjpjt_5",menu__item:"_menu__item_zjpjt_27","menu__item--danger":"_menu__item--danger_zjpjt_59"},jh=({isOpen:c,position:o,nodeId:r,onClose:u,onDuplicate:f,onRemove:m})=>{const y=Be(),S=g.useRef(null);return g.useEffect(()=>{if(!c)return;const x=A=>{S.current&&!S.current.contains(A.target)&&u()},h=A=>{A.key==="Escape"&&u()};return document.addEventListener("mousedown",x),document.addEventListener("keydown",h),()=>{document.removeEventListener("mousedown",x),document.removeEventListener("keydown",h)}},[c,u]),c?_.jsxs("div",{ref:S,className:$n.menu,style:{top:o.y,left:o.x},role:"menu",children:[_.jsx("button",{type:"button",className:$n.menu__item,role:"menuitem",onClick:()=>{f(r),u()},children:y.duplicate_element}),_.jsx("button",{type:"button",className:[$n.menu__item,$n["menu__item--danger"]].join(" "),role:"menuitem",onClick:()=>{m(r),u()},children:y.remove_element})]}):null},Wn={toggle:"_toggle_zws81_5","toggle--header":"_toggle--header_zws81_53","toggle--edge":"_toggle--edge_zws81_67","toggle--left":"_toggle--left_zws81_105","toggle--right":"_toggle--right_zws81_119"};function Ch(c,o){return c==="left"&&o||c==="right"&&!o?"chevron-left":"chevron-right"}const Fn=({side:c,isVisible:o,label:r,onClick:u,placement:f="header"})=>{const m=[Wn.toggle,f==="edge"?Wn["toggle--edge"]:Wn["toggle--header"],Wn[`toggle--${c}`]].filter(Boolean).join(" ");return _.jsx("button",{type:"button",className:m,onClick:u,title:r,"aria-label":r,"aria-expanded":o,children:_.jsx(de,{name:Ch(c,o),size:14})})},zh=40,Mh=32,Ah=()=>{const c=Be(),o=Q(j=>j.nodes),r=Q(j=>j.selectedNodeId),u=Q(j=>j.selectNode),f=Q(j=>j.removeNode),m=Q(j=>j.duplicateNode),y=Q(j=>j.isLeftPanelVisible),S=Q(j=>j.toggleLeftPanel),x=g.useRef(null),[h,A]=g.useState(400),[C,Y]=g.useState(null),R=g.useCallback(j=>{u(j)},[u]),L=g.useCallback((j,F)=>{F.preventDefault(),Y({nodeId:j,position:{x:F.clientX,y:F.clientY}})},[]),G=g.useCallback(()=>{Y(null)},[]);g.useEffect(()=>{const j=x.current;if(!j)return;const F=new ResizeObserver(ae=>{for(const ne of ae){const K=ne.contentRect.height,se=o.length>0?Mh:0;A(Math.max(100,K-zh-se))}});return F.observe(j),()=>F.disconnect()},[o.length]);const Z=Ho(o),q=Z.length,X=Z.filter(j=>j.isTextEditable||j.isStyleEditable).length;return _.jsxs("aside",{className:Ye.panel,ref:x,children:[_.jsxs("div",{className:Ye.panel__header,children:[_.jsxs("div",{className:Ye.panel__header_title,children:[_.jsx(de,{name:"layers",size:14}),_.jsx("span",{children:c.elements_panel})]}),_.jsxs("div",{className:Ye.panel__header_actions,children:[q>0&&_.jsxs("span",{className:Ye.panel__header_count,children:[X,"/",q]}),_.jsx(Fn,{side:"left",isVisible:y,label:c.hide_left_panel,onClick:S,placement:"header"})]})]}),_.jsx("div",{className:Ye.panel__tree_body,children:o.length===0?_.jsx("div",{className:Ye.panel__empty,children:_.jsx("p",{children:c.load_html_to_see_elements})}):_.jsx(Nh,{nodes:o,selectedNodeId:r,onSelect:R,onContextMenu:L,containerHeight:h})}),q>0&&_.jsx("div",{className:Ye.panel__footer,children:_.jsxs("span",{children:[q," nodes · ",X," editable"]})}),_.jsx(jh,{isOpen:!!C,position:C?.position??{x:0,y:0},nodeId:C?.nodeId??"",onClose:G,onDuplicate:m,onRemove:f})]})};function Hh(c,o){if(!o.trim())return c;const r=new DOMParser,u=r.parseFromString(c,"text/html"),f=/<html[\s>]/i.test(o.trim())?o:`<!DOCTYPE html><html><head><meta charset="UTF-8"></head><body>${o}</body></html>`,m=r.parseFromString(f,"text/html"),y=u.getElementById(Bl),S=m.getElementById(Bl)||m.body.querySelector(`#${Bl}`)||m.body.firstElementChild;if(y&&S)return y.innerHTML=S.innerHTML,u.documentElement.outerHTML;if(y){const A=r.parseFromString(`<div id="__merge__">${o}</div>`,"text/html").getElementById("__merge__");return A&&(y.innerHTML=A.innerHTML),u.documentElement.outerHTML}const x=S instanceof Element&&(S.id===Bl||S.classList.contains("notifal-notification-root"))?S.innerHTML:m.body.innerHTML;return u.body.innerHTML=x,u.documentElement.outerHTML}function Dh(c){const o=c.querySelectorAll(`.${gu}`),r=[];return o.forEach((u,f)=>{const m=xu(u);if(!Object.keys(m).length)return;const y=`nf-ph-${f}`;u.setAttribute("data-notifal-preview-id",y);const S=Object.entries(m).map(([x,h])=>`${x}:${h}`).join(";");r.push(`[data-notifal-preview-id="${y}"] img,[data-notifal-preview-id="${y}"] .notifal-featured-image {${S}}`)}),r.join(`
`)}function Oh(c){const r=new DOMParser().parseFromString(c,"text/html"),u=r.getElementById(Bl),f=Array.from(r.querySelectorAll("style")).map(S=>S.outerHTML).join(`
`),m=Dh(r),y=u?u.innerHTML:r.body.innerHTML;return`<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
${f}
<style>
  html, body {
    margin: 0;
    padding: 0;
    background: transparent;
    width: 100%;
    min-height: 100%;
  }
  body {
    display: flex;
    justify-content: center;
    align-items: flex-start;
  }
  ${m}
</style>
</head>
<body>${y}</body>
</html>`}const xe={canvas:"_canvas_1jx76_5",canvas__toolbar:"_canvas__toolbar_1jx76_16",canvas__toolbar_group:"_canvas__toolbar_group_1jx76_27",canvas__toolbar_divider:"_canvas__toolbar_divider_1jx76_33",canvas__toolbar_spacer:"_canvas__toolbar_spacer_1jx76_40",canvas__selection_badge:"_canvas__selection_badge_1jx76_44",canvas__frame_wrapper:"_canvas__frame_wrapper_1jx76_55",canvas__preview_row:"_canvas__preview_row_1jx76_67","canvas__preview_row--constrained":"_canvas__preview_row--constrained_1jx76_74",canvas__iframe_shell:"_canvas__iframe_shell_1jx76_79",canvas__iframe:"_canvas__iframe_1jx76_79",canvas__resize_handle:"_canvas__resize_handle_1jx76_110","canvas__resize_handle--dragging":"_canvas__resize_handle--dragging_1jx76_127",canvas__resize_handle_grip:"_canvas__resize_handle_grip_1jx76_132",canvas__resize_handle_label:"_canvas__resize_handle_label_1jx76_150",canvas__responsive:"_canvas__responsive_1jx76_169",canvas__responsive_btn:"_canvas__responsive_btn_1jx76_181","canvas__responsive_btn--active":"_canvas__responsive_btn--active_1jx76_199",canvas__responsive_custom:"_canvas__responsive_custom_1jx76_205",canvas__responsive_input:"_canvas__responsive_input_1jx76_212",canvas__responsive_unit:"_canvas__responsive_unit_1jx76_223",canvas__empty:"_canvas__empty_1jx76_230",canvas__empty_icon:"_canvas__empty_icon_1jx76_240",canvas__empty_text:"_canvas__empty_text_1jx76_246",canvas__empty_link:"_canvas__empty_link_1jx76_252"},In=280,Pn=2e3,Rh=({width:c})=>{const o=Be(),r=Q(R=>R.setPreviewWidth),[u,f]=g.useState(!1),[m,y]=g.useState(!1),S=g.useRef(null),x=g.useCallback(R=>Math.min(Pn,Math.max(In,Math.round(R))),[]),h=g.useCallback(R=>{R.preventDefault(),R.stopPropagation(),S.current={startX:R.clientX,startWidth:c},f(!0),R.currentTarget.setPointerCapture(R.pointerId)},[c]),A=g.useCallback(R=>{if(!S.current)return;const L=R.clientX-S.current.startX,G=x(S.current.startWidth+L);r(G,"custom")},[x,r]),C=g.useCallback(R=>{S.current=null,f(!1),R.currentTarget.hasPointerCapture(R.pointerId)&&R.currentTarget.releasePointerCapture(R.pointerId)},[]),Y=u||m;return _.jsxs("div",{className:[xe.canvas__resize_handle,u?xe["canvas__resize_handle--dragging"]:""].filter(Boolean).join(" "),onPointerDown:h,onPointerMove:A,onPointerUp:C,onPointerCancel:C,onMouseEnter:()=>y(!0),onMouseLeave:()=>y(!1),role:"separator","aria-orientation":"vertical","aria-label":o.preview_width_drag,"aria-valuemin":In,"aria-valuemax":Pn,"aria-valuenow":c,title:o.preview_width_drag,children:[_.jsxs("span",{className:xe.canvas__resize_handle_grip,"aria-hidden":"true",children:[_.jsx("span",{}),_.jsx("span",{}),_.jsx("span",{})]}),Y?_.jsxs("span",{className:xe.canvas__resize_handle_label,children:[c,"px"]}):null]})},Uh="#7e2bd2",Lh=600,Bh=`
(function() {
  var overlayEl = null;

  function getXPath(el) {
    var parts = [];
    var node = el;
    while (node && node.nodeType === 1) {
      var idx = 1;
      var sib = node.previousElementSibling;
      while (sib) {
        if (sib.tagName === node.tagName) idx++;
        sib = sib.previousElementSibling;
      }
      parts.unshift(node.tagName.toLowerCase() + '[' + idx + ']');
      node = node.parentElement;
    }
    return '/' + parts.join('/');
  }

  function removeOverlay() {
    if (overlayEl && overlayEl.parentNode) {
      overlayEl.parentNode.removeChild(overlayEl);
      overlayEl = null;
    }
  }

  function drawOverlay(el) {
    removeOverlay();
    var rect = el.getBoundingClientRect();
    var scrollTop = window.scrollY || document.documentElement.scrollTop;
    var scrollLeft = window.scrollX || document.documentElement.scrollLeft;
    overlayEl = document.createElement('div');
    overlayEl.id = '__notifal_builder_overlay__';
    overlayEl.style.cssText = [
      'position:absolute',
      'pointer-events:none',
      'z-index:99999',
      'box-sizing:border-box',
      'outline:2px solid ${Uh}',
      'outline-offset:1px',
      'background:rgba(126,43,210,0.06)',
      'border-radius:3px',
      'transition:all 80ms ease',
      'top:' + (rect.top + scrollTop) + 'px',
      'left:' + (rect.left + scrollLeft) + 'px',
      'width:' + rect.width + 'px',
      'height:' + rect.height + 'px',
    ].join(';');
    document.body.appendChild(overlayEl);
  }

  document.addEventListener('click', function(e) {
    var el = e.target;
    if (!el || el.id === '__notifal_builder_overlay__') return;
    e.preventDefault();
    e.stopPropagation();
    var xpath = getXPath(el);
    drawOverlay(el);
    window.parent.postMessage({ type: 'NOTIFAL_BUILDER_SELECT', xpath: xpath }, '*');
  }, true);

  window.addEventListener('message', function(e) {
    if (e.data && e.data.type === 'NOTIFAL_BUILDER_DESELECT') {
      removeOverlay();
    }
    if (e.data && e.data.type === 'NOTIFAL_BUILDER_HIGHLIGHT' && e.data.xpath) {
      var result = document.evaluate(
        e.data.xpath, document, null,
        XPathResult.FIRST_ORDERED_NODE_TYPE, null
      );
      var node = result.singleNodeValue;
      if (node) {
        drawOverlay(node);
        node.scrollIntoView({ behavior: 'smooth', block: 'nearest' });
      }
    }
  });

  document.addEventListener('click', function(e) {
    var el = e.target;
    while (el) {
      if (el.tagName === 'A') { e.preventDefault(); break; }
      el = el.parentElement;
    }
  });
})();
`;function kh(c){const o=`<script>
${Bh}
<\/script>`;return c.includes("</body>")?c.replace("</body>",`${o}</body>`):c+o}const ku=g.memo(({isPreviewMode:c})=>{const o=Be(),r=g.useRef(null),u=Q(j=>j.rawHtml),f=Q(j=>j.nodes),m=Q(j=>j.selectedNodeId),y=Q(j=>j.previewWidth),S=Q(j=>j.selectNode),x=Q(j=>j.exportHtml),h=Q(j=>j.setTagPreviewStatus),A=Q(j=>j.tagPreviewStatus),[C,Y]=g.useState(null),R=g.useMemo(()=>x(),[u,f,x]),L=c||$m(R),G=A!=="idle";g.useEffect(()=>{if(!L||!R){Y(null),h("idle");return}h("pending");let j=!1;const F=window.setTimeout(async()=>{if(j)return;h("loading");const ae=await eh(R);j||(Y(ae),h("idle"))},Lh);return()=>{j=!0,window.clearTimeout(F)}},[R,L,h]);const Z=g.useMemo(()=>{let j=R;return C&&(j=Hh(R,C)),Oh(j)},[R,C]),q=g.useMemo(()=>Z?c?Z:kh(Z):"",[Z,c]),X=g.useCallback(j=>{if(!j.data||typeof j.data!="object")return;const{type:F,xpath:ae}=j.data;if(F!=="NOTIFAL_BUILDER_SELECT"||!ae)return;const ne=se=>{for(const Ee of se){if(qu(Ee.xpath)===qu(ae))return Ee.id;const $=ne(Ee.children);if($)return $}return null},K=ne(f);K&&S(K)},[f,S]);return g.useEffect(()=>(window.addEventListener("message",X),()=>window.removeEventListener("message",X)),[X]),g.useEffect(()=>{if(!r.current?.contentWindow)return;if(!m){r.current.contentWindow.postMessage({type:"NOTIFAL_BUILDER_DESELECT"},"*");return}const j=(ae,ne)=>{for(const K of ae){if(K.id===ne)return K.xpath;const se=j(K.children,ne);if(se)return se}return null},F=j(f,m);F&&r.current.contentWindow.postMessage({type:"NOTIFAL_BUILDER_HIGHLIGHT",xpath:F},"*")},[m,f]),_.jsxs("div",{className:[xe.canvas__preview_row,y!==null?xe["canvas__preview_row--constrained"]:""].filter(Boolean).join(" "),children:[_.jsx("div",{className:xe.canvas__iframe_shell,style:y!==null?{width:`${y}px`,maxWidth:"100%"}:void 0,"data-preview-phase":G?A:void 0,children:_.jsx("iframe",{ref:r,className:xe.canvas__iframe,srcDoc:q,sandbox:"allow-same-origin allow-scripts",title:o.html_preview_title})}),y!==null?_.jsx(Rh,{width:y}):null]})});ku.displayName="HtmlPreview";function qu(c){return c.toLowerCase().trim()}const qh={desktop:null,tablet:768,mobile:375},Yh=()=>{const c=Be(),o=Q(y=>y.previewWidth),r=Q(y=>y.previewDevice),u=Q(y=>y.setPreviewWidth),f=g.useCallback(y=>{u(qh[y],y)},[u]),m=g.useCallback(y=>{const S=parseInt(y.target.value,10);!Number.isNaN(S)&&S>=In&&S<=Pn&&u(S,"custom")},[u]);return _.jsxs("div",{className:xe.canvas__responsive,children:[_.jsx("button",{type:"button",className:[xe.canvas__responsive_btn,r==="desktop"?xe["canvas__responsive_btn--active"]:""].filter(Boolean).join(" "),onClick:()=>f("desktop"),title:c.device_desktop,"aria-label":c.device_desktop,children:_.jsx(de,{name:"desktop",size:14})}),_.jsx("button",{type:"button",className:[xe.canvas__responsive_btn,r==="tablet"?xe["canvas__responsive_btn--active"]:""].filter(Boolean).join(" "),onClick:()=>f("tablet"),title:c.device_tablet,"aria-label":c.device_tablet,children:_.jsx(de,{name:"tablet",size:14})}),_.jsx("button",{type:"button",className:[xe.canvas__responsive_btn,r==="mobile"?xe["canvas__responsive_btn--active"]:""].filter(Boolean).join(" "),onClick:()=>f("mobile"),title:c.device_mobile,"aria-label":c.device_mobile,children:_.jsx(de,{name:"phone",size:14})}),o!==null?_.jsxs("div",{className:xe.canvas__responsive_custom,children:[_.jsx("input",{type:"number",className:xe.canvas__responsive_input,value:o,min:In,max:Pn,onChange:m,"aria-label":c.preview_width}),_.jsx("span",{className:xe.canvas__responsive_unit,children:"px"})]}):null]})},Gh=()=>{const c=Be(),o=Q(L=>L.undo),r=Q(L=>L.redo),u=Q(L=>L.selectNode),f=Q(L=>L.selectedNodeId),m=Q(L=>L.isPreviewMode),y=Q(L=>L.historyIndex),S=Q(L=>L.history),x=Q(L=>L.nodes),h=Q(L=>L.openHtmlModal),A=x.length>0,C=y>0,Y=y<S.length-1,R=g.useCallback(()=>{u(null)},[u]);return A?_.jsxs("div",{className:xe.canvas,children:[_.jsxs("div",{className:xe.canvas__toolbar,children:[m?null:_.jsxs(_.Fragment,{children:[_.jsxs("div",{className:xe.canvas__toolbar_group,children:[_.jsx(Pe,{variant:f?"ghost":"secondary",size:"sm",icon:_.jsx(de,{name:"cursor",size:14}),title:c.select_tool_title,children:c.select_tool}),f?_.jsx(Pe,{variant:"ghost",size:"sm",icon:_.jsx(de,{name:"x-circle",size:14}),onClick:R,title:c.deselect,children:c.deselect}):null]}),_.jsx("div",{className:xe.canvas__toolbar_divider}),_.jsxs("div",{className:xe.canvas__toolbar_group,children:[_.jsx(Pe,{variant:"ghost",size:"sm",icon:_.jsx(de,{name:"arrow-counterclockwise",size:14}),onClick:o,disabled:!C,title:c.undo_title}),_.jsx(Pe,{variant:"ghost",size:"sm",icon:_.jsx(de,{name:"arrow-repeat",size:14}),onClick:r,disabled:!Y,title:c.redo_title})]}),_.jsx("div",{className:xe.canvas__toolbar_divider})]}),_.jsx(Yh,{}),_.jsx("div",{className:xe.canvas__toolbar_spacer}),!m&&f?_.jsx("div",{className:xe.canvas__selection_badge,children:_.jsx("span",{children:c.one_element_selected})}):null]}),_.jsx("div",{className:xe.canvas__frame_wrapper,children:_.jsx(ku,{isPreviewMode:m})})]}):_.jsx("div",{className:xe.canvas,children:_.jsxs("div",{className:xe.canvas__empty,children:[_.jsx("div",{className:xe.canvas__empty_icon,children:_.jsx(de,{name:"layers-fill",size:24})}),_.jsx("p",{className:xe.canvas__empty_text,children:c.canvas_empty_title}),_.jsx("button",{type:"button",className:xe.canvas__empty_link,onClick:h,children:c.canvas_empty_import_link})]})})},k={panel:"_panel_1k1ei_5",panel__header:"_panel__header_1k1ei_18",panel__header_title:"_panel__header_title_1k1ei_29",panel__header_tag:"_panel__header_tag_1k1ei_40",panel__header_actions:"_panel__header_actions_1k1ei_49",panel__tabs:"_panel__tabs_1k1ei_58",panel__tab:"_panel__tab_1k1ei_58","panel__tab--active":"_panel__tab--active_1k1ei_85",panel__body:"_panel__body_1k1ei_103",panel__empty:"_panel__empty_1k1ei_122",panel__empty_icon:"_panel__empty_icon_1k1ei_133",panel__empty_title:"_panel__empty_title_1k1ei_138",panel__empty_hint:"_panel__empty_hint_1k1ei_145",style_editor:"_style_editor_1k1ei_155",style_editor__section:"_style_editor__section_1k1ei_159",style_editor__section_title:"_style_editor__section_title_1k1ei_163",style_editor__section_chevron:"_style_editor__section_chevron_1k1ei_193","style_editor__section_chevron--expanded":"_style_editor__section_chevron--expanded_1k1ei_198",style_editor__fields:"_style_editor__fields_1k1ei_202",field:"_field_1k1ei_211",field__label:"_field__label_1k1ei_218",field__input:"_field__input_1k1ei_226",field__select:"_field__select_1k1ei_248",field__input_row:"_field__input_row_1k1ei_271",field__number:"_field__number_1k1ei_279",field__unit:"_field__unit_1k1ei_309",colorpicker:"_colorpicker_1k1ei_326",colorpicker__label:"_colorpicker__label_1k1ei_332",colorpicker__row:"_colorpicker__row_1k1ei_339",colorpicker__swatch:"_colorpicker__swatch_1k1ei_345",colorpicker__native_hidden:"_colorpicker__native_hidden_1k1ei_364",colorpicker__hex:"_colorpicker__hex_1k1ei_375","colorpicker__hex--error":"_colorpicker__hex--error_1k1ei_396",colorpicker__popover:"_colorpicker__popover_1k1ei_400",colorpicker__presets:"_colorpicker__presets_1k1ei_419",colorpicker__preset:"_colorpicker__preset_1k1ei_419","colorpicker__preset--active":"_colorpicker__preset--active_1k1ei_440",colorpicker__custom:"_colorpicker__custom_1k1ei_445",colorpicker__custom_icon:"_colorpicker__custom_icon_1k1ei_466",text_editor:"_text_editor_1k1ei_484",text_editor__header:"_text_editor__header_1k1ei_491",text_editor__label:"_text_editor__label_1k1ei_497",text_editor__tag:"_text_editor__tag_1k1ei_503",text_editor__textarea:"_text_editor__textarea_1k1ei_512",text_editor__meta:"_text_editor__meta_1k1ei_536",text_editor__not_editable:"_text_editor__not_editable_1k1ei_543",text_editor__not_editable_icon:"_text_editor__not_editable_icon_1k1ei_552",text_editor__hint:"_text_editor__hint_1k1ei_571",html_tab:"_html_tab_1k1ei_579",html_tab__actions:"_html_tab__actions_1k1ei_585",html_tab__search:"_html_tab__search_1k1ei_595",html_tab__search_label:"_html_tab__search_label_1k1ei_605",html_tab__search_sr:"_html_tab__search_sr_1k1ei_612",html_tab__search_input:"_html_tab__search_input_1k1ei_624",html_tab__search_count:"_html_tab__search_count_1k1ei_643",html_tab__search_nav:"_html_tab__search_nav_1k1ei_652",html_tab__search_nav_btn:"_html_tab__search_nav_btn_1k1ei_659",html_tab__textarea:"_html_tab__textarea_1k1ei_682","html_tab__textarea--error":"_html_tab__textarea--error_1k1ei_707",html_tab__hint:"_html_tab__hint_1k1ei_711",html_tab__error:"_html_tab__error_1k1ei_720",countdown_editor:"_countdown_editor_1k1ei_763",countdown_editor__header:"_countdown_editor__header_1k1ei_768",countdown_editor__label:"_countdown_editor__label_1k1ei_772",countdown_editor__hint:"_countdown_editor__hint_1k1ei_778",countdown_editor__fields:"_countdown_editor__fields_1k1ei_785",countdown_editor__field:"_countdown_editor__field_1k1ei_785",countdown_editor__field_label:"_countdown_editor__field_label_1k1ei_795",countdown_editor__complete:"_countdown_editor__complete_1k1ei_807",countdown_editor__complete_hint:"_countdown_editor__complete_hint_1k1ei_820",image_editor:"_image_editor_1k1ei_829",image_editor__header:"_image_editor__header_1k1ei_834",image_editor__label:"_image_editor__label_1k1ei_838",image_editor__preview:"_image_editor__preview_1k1ei_846",image_editor__thumb:"_image_editor__thumb_1k1ei_850",image_editor__row:"_image_editor__row_1k1ei_859",image_editor__media_btn:"_image_editor__media_btn_1k1ei_865",image_editor__notice:"_image_editor__notice_1k1ei_883",link_editor:"_link_editor_1k1ei_894",link_editor__header:"_link_editor__header_1k1ei_899",link_editor__label:"_link_editor__label_1k1ei_903",link_editor__hint:"_link_editor__hint_1k1ei_909",field__unit_select:"_field__unit_select_1k1ei_916"};function ko(c){return c?c.startsWith("#")&&c.length===4?`#${c[1]}${c[1]}${c[2]}${c[2]}${c[3]}${c[3]}`:(c.startsWith("#")&&c.length===7,c):"#000000"}function Yu(c){const o=document.createElement("div");return o.style.color=c,o.style.color!==""}const Xh=["#1A1A2E","#534AB7","#7F77DD","#EEEDFE","#ffffff","#f4f3f8","#6B6A72","#A09FAA","#e85d6b","#f59e0b","#10b981","#3b82f6","#ec4899","#8b5cf6","#14b8a6","#f97316"],Vh=({value:c,onChange:o,label:r})=>{const u=Be(),[f,m]=g.useState(ko(c)),[y,S]=g.useState(!1),[x,h]=g.useState(!1),A=g.useRef(null),C=g.useRef(null);g.useEffect(()=>{m(ko(c))},[c]),g.useEffect(()=>{if(!y)return;const j=F=>{A.current&&!A.current.contains(F.target)&&S(!1)};return document.addEventListener("mousedown",j),()=>document.removeEventListener("mousedown",j)},[y]);const Y=g.useCallback(()=>{S(j=>!j)},[]),R=g.useCallback(()=>{S(!0)},[]),L=g.useCallback(j=>{const F=j.target.value;if(m(F),Yu(F)){h(!1),o(F);return}h(!0)},[o]),G=g.useCallback(j=>{const F=j.target.value;m(F),h(!1),o(F),S(!1)},[o]),Z=g.useCallback(j=>{m(j),h(!1),o(j),S(!1)},[o]),q=g.useCallback(()=>{C.current?.click()},[]),X=Yu(c)?c:"#cccccc";return _.jsxs("div",{className:k.colorpicker,ref:A,children:[r?_.jsx("span",{className:k.colorpicker__label,children:r}):null,_.jsxs("div",{className:k.colorpicker__row,children:[_.jsx("button",{type:"button",className:k.colorpicker__swatch,style:{background:X},onClick:Y,title:u.choose_color,"aria-label":u.color_swatch,"aria-expanded":y}),_.jsx("input",{type:"text",className:[k.colorpicker__hex,x?k["colorpicker__hex--error"]:""].filter(Boolean).join(" "),value:f,onChange:L,onFocus:R,placeholder:"#000000",spellCheck:!1,maxLength:25,"aria-expanded":y})]}),_.jsx("input",{ref:C,type:"color",className:k.colorpicker__native_hidden,value:f.startsWith("#")?f:"#000000",onChange:G,tabIndex:-1,"aria-hidden":"true"}),y?_.jsxs("div",{className:k.colorpicker__popover,role:"dialog","aria-label":u.color_presets,children:[_.jsx("div",{className:k.colorpicker__presets,children:Xh.map(j=>_.jsx("button",{type:"button",className:[k.colorpicker__preset,ko(c)===j?k["colorpicker__preset--active"]:""].filter(Boolean).join(" "),style:{background:j},onClick:()=>Z(j),title:j,"aria-label":j},j))}),_.jsxs("button",{type:"button",className:k.colorpicker__custom,onClick:q,children:[_.jsx("span",{className:k.colorpicker__custom_icon,"aria-hidden":"true"}),_.jsx("span",{children:u.custom_color})]})]}):null]})},Qh=["px","%","vw"];function Zh(c){return[{key:"typography",title:c.style_section_typography,fields:[{label:c.style_font_size,property:"font-size",type:"number-unit",unit:"px",placeholder:"16",min:1,max:200},{label:c.style_font_weight,property:"font-weight",type:"select",options:[{label:c.style_font_weight_300,value:"300"},{label:c.style_font_weight_400,value:"400"},{label:c.style_font_weight_500,value:"500"},{label:c.style_font_weight_600,value:"600"},{label:c.style_font_weight_700,value:"700"},{label:c.style_font_weight_800,value:"800"},{label:c.style_font_weight_900,value:"900"}]},{label:c.style_line_height,property:"line-height",type:"number-unit",unit:"",placeholder:"1.5"},{label:c.style_text_align,property:"text-align",type:"select",options:[{label:c.style_align_left,value:"left"},{label:c.style_align_center,value:"center"},{label:c.style_align_right,value:"right"},{label:c.style_align_justify,value:"justify"}]},{label:c.style_color,property:"color",type:"color"}]},{key:"background",title:c.style_section_background,fields:[{label:c.style_background_color,property:"background-color",type:"color"}]},{key:"spacing",title:c.style_section_spacing,fields:[{label:c.style_padding_top,property:"padding-top",type:"number-unit",unit:"px",placeholder:"0",min:0},{label:c.style_padding_right,property:"padding-right",type:"number-unit",unit:"px",placeholder:"0",min:0},{label:c.style_padding_bottom,property:"padding-bottom",type:"number-unit",unit:"px",placeholder:"0",min:0},{label:c.style_padding_left,property:"padding-left",type:"number-unit",unit:"px",placeholder:"0",min:0},{label:c.style_margin_top,property:"margin-top",type:"number-unit",unit:"px",placeholder:"0"},{label:c.style_margin_bottom,property:"margin-bottom",type:"number-unit",unit:"px",placeholder:"0"}]},{key:"size",title:c.style_section_size,fields:[{label:c.style_width,property:"width",type:"number-unit",unit:"px",placeholder:"auto"},{label:c.style_height,property:"height",type:"number-unit",unit:"px",placeholder:"auto"},{label:c.style_border_radius,property:"border-radius",type:"number-unit",unit:"px",placeholder:"0",min:0},{label:c.style_object_fit,property:"object-fit",type:"select",options:[{label:c.style_object_fit_cover,value:"cover"},{label:c.style_object_fit_contain,value:"contain"},{label:c.style_object_fit_fill,value:"fill"},{label:c.style_object_fit_none,value:"none"}]}]}]}function Gu(c,o){return c?o?c.replace(new RegExp(`${o}$`,"i"),"").trim():c.trim():""}function Xu(c){if(!c)return{num:"",unit:"px"};if(c==="auto")return{num:"auto",unit:""};const o=c.trim().match(/^(-?[\d.]+)(px|%|vw|em|rem)?$/i);return o?{num:o[1],unit:(o[2]||"px").toLowerCase()}:{num:c,unit:"px"}}const Kh=({expanded:c})=>_.jsx(de,{name:"chevron-right",size:12,className:[k.style_editor__section_chevron,c?k["style_editor__section_chevron--expanded"]:""].filter(Boolean).join(" ")}),Jh=({nodeId:c,field:o,currentStyles:r,onUpdate:u})=>{const f=r[o.property]??"",m=o.type==="number-unit"?Xu(f):{num:"",unit:""},y=o.units??(o.unit==="px"?Qh:o.unit?[o.unit]:[]),S=o.type==="number-unit"&&y.length>1,x=o.type==="number-unit"?S?m.num:Gu(f,o.unit??""):f,[h,A]=g.useState(x),[C,Y]=g.useState(S?m.unit||"px":o.unit??""),R=g.useRef(null);if(g.useEffect(()=>{if(o.type==="number-unit"){const L=Xu(r[o.property]??"");A(S?L.num:Gu(f,o.unit??"")),S&&Y(L.unit||"px");return}A(f)},[o.property,c]),g.useEffect(()=>()=>{R.current&&clearTimeout(R.current)},[]),o.type==="color")return _.jsxs("div",{className:k.field,children:[_.jsx("label",{className:k.field__label,children:o.label}),_.jsx(Vh,{value:f||"#000000",onChange:L=>u(o.property,L)})]});if(o.type==="select")return _.jsxs("div",{className:k.field,children:[_.jsx("label",{className:k.field__label,children:o.label}),_.jsxs("select",{className:k.field__select,value:f,onChange:L=>u(o.property,L.target.value),children:[_.jsx("option",{value:"",children:"— default —"}),o.options?.map(L=>_.jsx("option",{value:L.value,children:L.label},L.value))]})]});if(o.type==="number-unit"){const L=(G,Z)=>{if(!G){u(o.property,"");return}if(G==="auto"||!Z){u(o.property,G);return}u(o.property,`${G}${Z}`)};return _.jsxs("div",{className:k.field,children:[_.jsx("label",{className:k.field__label,children:o.label}),_.jsxs("div",{className:k.field__input_row,children:[_.jsx("input",{type:h==="auto"?"text":"number",className:k.field__number,value:h,placeholder:o.placeholder,min:o.min,max:o.max,onChange:G=>{const Z=G.target.value;A(Z),R.current&&clearTimeout(R.current),R.current=setTimeout(()=>{L(Z,S?C:o.unit??"")},150)}}),S?_.jsx("select",{className:k.field__unit_select,value:C,onChange:G=>{const Z=G.target.value;Y(Z),L(h,Z)},"aria-label":`${o.label} unit`,children:y.map(G=>_.jsx("option",{value:G,children:G},G))}):o.unit?_.jsx("span",{className:k.field__unit,children:o.unit}):null]})]})}return _.jsxs("div",{className:k.field,children:[_.jsx("label",{className:k.field__label,children:o.label}),_.jsx("input",{type:"text",className:k.field__input,value:h,placeholder:o.placeholder,onChange:L=>{const G=L.target.value;A(G),R.current&&clearTimeout(R.current),R.current=setTimeout(()=>{u(o.property,G)},150)}})]})},$h=({node:c,onUpdateStyle:o})=>{const r=Be(),u=g.useMemo(()=>Zh(r),[r]),[f,m]=g.useState({}),y=g.useCallback(x=>{m(h=>({...h,[x]:!h[x]}))},[]),S=g.useCallback(x=>c.isFeaturedImagePlaceholder&&wu(x)?c.imageStyles??{}:c.styles,[c.imageStyles,c.isFeaturedImagePlaceholder,c.styles]);return _.jsx("div",{className:k.style_editor,children:u.map(x=>{const h=!!f[x.key],A=c.isFeaturedImagePlaceholder&&x.key==="size";return _.jsxs("div",{className:k.style_editor__section,children:[_.jsxs("button",{type:"button",className:k.style_editor__section_title,onClick:()=>y(x.key),"aria-expanded":!h,children:[_.jsx(Kh,{expanded:!h}),_.jsx("span",{children:A?r.featured_image_size_title:x.title})]}),h?null:_.jsxs("div",{className:k.style_editor__fields,children:[A?_.jsx("p",{className:k.image_editor__notice,role:"note",children:r.featured_image_size_notice}):null,x.fields.filter(C=>C.property!=="object-fit"?!0:c.isFeaturedImagePlaceholder||c.tagName==="img").map(C=>_.jsx(Jh,{nodeId:c.id,field:C,currentStyles:S(C.property),onUpdate:o},C.property))]})]},x.key)})})},Wh=150,Fh=({node:c,onUpdateText:o})=>{const r=Be(),[u,f]=g.useState(c.textContent),m=g.useRef(null),y=g.useRef(null);g.useEffect(()=>{f(c.textContent)},[c.id,c.textContent]),g.useEffect(()=>{const x=y.current;x&&(x.style.height="auto",x.style.height=`${Math.min(x.scrollHeight,240)}px`)},[u]);const S=g.useCallback(x=>{const h=x.target.value;f(h),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{o(h)},Wh)},[o]);return g.useEffect(()=>()=>{m.current&&clearTimeout(m.current)},[]),c.isTextEditable?_.jsxs("div",{className:k.text_editor,children:[_.jsxs("div",{className:k.text_editor__header,children:[_.jsx("label",{className:k.text_editor__label,htmlFor:"content-textarea",children:"Text Content"}),_.jsxs("span",{className:k.text_editor__tag,children:["<",c.tagName,">"]})]}),_.jsx("textarea",{id:"content-textarea",ref:y,className:k.text_editor__textarea,value:u,onChange:S,placeholder:"Enter text content...",rows:3,spellCheck:!0}),_.jsxs("div",{className:k.text_editor__meta,children:[_.jsxs("span",{children:[u.length," chars"]}),_.jsxs("span",{children:[u.split(/\s+/).filter(Boolean).length," words"]})]})]}):_.jsxs("div",{className:k.text_editor__not_editable,children:[_.jsx("div",{className:k.text_editor__not_editable_icon,children:"✕"}),_.jsx("p",{children:r.text_not_editable}),_.jsx("p",{className:k.text_editor__hint,children:r.text_not_editable_hint})]})};function Ih(c){return c.url||c.attributes?.url||c.sizes?.full?.url||""}function Ph(c){return new Promise(o=>{if(!window.wp?.media){o(null);return}let r=!1;const u=m=>{r||(r=!0,o(m))},f=window.wp.media({title:c,button:{text:c},library:{type:"image"},multiple:!1});f.on("select",()=>{const m=f.state().get("selection").first().toJSON(),y=Ih(m);u(y||null)}),f.on("close",()=>{u(null)}),f.open()})}const ep=300,tp=({node:c,onUpdateSrc:o})=>{const r=Be(),[u,f]=g.useState(c.imageSrc??""),m=g.useRef(null),y=!!c.isFeaturedImagePlaceholder;g.useEffect(()=>{f(c.imageSrc??"")},[c.id]);const S=g.useCallback(h=>{const A=h.target.value;f(A),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{o(A)},ep)},[o]),x=g.useCallback(async()=>{const h=await Ph(r.select_image);h&&(f(h),o(h))},[o,r.select_image]);return g.useEffect(()=>()=>{m.current&&clearTimeout(m.current)},[]),c.isImageEditable?y?_.jsxs("div",{className:k.image_editor,children:[_.jsx("div",{className:k.image_editor__header,children:_.jsx("label",{className:k.image_editor__label,children:r.featured_image_placeholder})}),_.jsx("p",{className:k.image_editor__notice,role:"note",children:r.featured_image_placeholder_notice})]}):_.jsxs("div",{className:k.image_editor,children:[_.jsx("div",{className:k.image_editor__header,children:_.jsx("label",{className:k.image_editor__label,htmlFor:"image-src-input",children:r.image_src})}),u?_.jsx("div",{className:k.image_editor__preview,children:_.jsx("img",{src:u,alt:"",className:k.image_editor__thumb})}):null,_.jsxs("div",{className:k.image_editor__row,children:[_.jsx("input",{id:"image-src-input",type:"url",className:k.field__input,value:u,onChange:S,placeholder:"https://"}),_.jsx("button",{type:"button",className:k.image_editor__media_btn,onClick:x,children:r.media_library})]})]}):null},lp=300,ap=({node:c,onUpdateHref:o})=>{const r=Be(),[u,f]=g.useState(c.linkHref??""),m=g.useRef(null);g.useEffect(()=>{f(c.linkHref??"")},[c.id,c.linkHref]);const y=g.useCallback(S=>{const x=S.target.value;f(x),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{o(x)},lp)},[o]);return g.useEffect(()=>()=>{m.current&&clearTimeout(m.current)},[]),c.isLinkEditable?_.jsxs("div",{className:k.link_editor,children:[_.jsx("div",{className:k.link_editor__header,children:_.jsx("label",{className:k.link_editor__label,htmlFor:"link-href-input",children:r.link_href})}),_.jsx("input",{id:"link-href-input",type:"text",className:k.field__input,value:u,onChange:y,placeholder:r.link_href_placeholder,spellCheck:!1,autoComplete:"off"}),_.jsx("p",{className:k.link_editor__hint,children:r.link_href_hint})]}):null},np=300,ip=({node:c,onUpdateSettings:o})=>{const r=Be(),u=Mo(c.countdownSeconds??0),[f,m]=g.useState(String(u.minutes+u.hours*60+u.days*1440)),[y,S]=g.useState(String(u.seconds)),[x,h]=g.useState(c.countdownOnComplete??"stay"),A=g.useRef(null);g.useEffect(()=>{const G=Mo(c.countdownSeconds??0),Z=G.days*1440+G.hours*60+G.minutes;m(String(Z)),S(String(G.seconds)),h(c.countdownOnComplete??"stay")},[c.id,c.countdownSeconds,c.countdownOnComplete]);const C=g.useCallback((G,Z)=>{A.current&&clearTimeout(A.current),A.current=setTimeout(()=>{const q=jm(parseInt(G,10)||0,parseInt(Z,10)||0);o({totalSeconds:q})},np)},[o]),Y=g.useCallback(G=>{const Z=G.target.value;m(Z),C(Z,y)},[C,y]),R=g.useCallback(G=>{const Z=G.target.value;S(Z),C(f,Z)},[f,C]),L=g.useCallback(G=>{const Z=G.target.value;h(Z),o({onComplete:Z})},[o]);return g.useEffect(()=>()=>{A.current&&clearTimeout(A.current)},[]),_.jsxs("div",{className:k.countdown_editor,children:[_.jsx("div",{className:k.countdown_editor__header,children:_.jsx("label",{className:k.countdown_editor__label,children:r.countdown_title})}),_.jsx("p",{className:k.countdown_editor__hint,role:"note",children:r.countdown_hint}),_.jsxs("div",{className:k.countdown_editor__fields,children:[_.jsxs("div",{className:k.countdown_editor__field,children:[_.jsx("label",{className:k.countdown_editor__field_label,htmlFor:"countdown-minutes-input",children:r.countdown_minutes}),_.jsx("input",{id:"countdown-minutes-input",type:"number",min:0,className:k.field__input,value:f,onChange:Y})]}),_.jsxs("div",{className:k.countdown_editor__field,children:[_.jsx("label",{className:k.countdown_editor__field_label,htmlFor:"countdown-seconds-input",children:r.countdown_seconds}),_.jsx("input",{id:"countdown-seconds-input",type:"number",min:0,max:59,className:k.field__input,value:y,onChange:R})]})]}),_.jsxs("div",{className:k.countdown_editor__complete,children:[_.jsx("label",{className:k.countdown_editor__field_label,htmlFor:"countdown-on-complete-select",children:r.countdown_on_complete}),_.jsxs("select",{id:"countdown-on-complete-select",className:k.field__select,value:x,onChange:L,children:[_.jsx("option",{value:"stay",children:r.countdown_on_complete_stay}),_.jsx("option",{value:"hide",children:r.countdown_on_complete_hide}),_.jsx("option",{value:"close",children:r.countdown_on_complete_close})]}),_.jsx("p",{className:k.countdown_editor__complete_hint,children:r.countdown_on_complete_hint})]})]})},op=[{pattern:/<!doctype[\s>]/i,tag:"<!DOCTYPE>"},{pattern:/<html[\s>]/i,tag:"<html>"},{pattern:/<head[\s>]/i,tag:"<head>"},{pattern:/<body[\s>]/i,tag:"<body>"}];function Vu(c){const o=c.trim();return o?op.some(({pattern:r})=>r.test(o)):!1}function Qu(c){const o=c.trim();return o?Vu(o)?{valid:!1,reason:"document_tags"}:{valid:!0}:{valid:!1,reason:"empty"}}function cp(c){const o=c.trim();if(!o)return{valid:!1,reason:"empty"};if(Vu(o))return{valid:!1,reason:"document_tags"};const u=new DOMParser().parseFromString(`<body>${o}</body>`,"text/html");return Array.from(u.body.children).length!==1?{valid:!1,reason:"single_element"}:{valid:!0}}function Zu(c,o){if(!o)return[];const r=[],u=c.toLowerCase(),f=o.toLowerCase();let m=0;for(;m<=u.length-f.length;){const y=u.indexOf(f,m);if(y===-1)break;r.push(y),m=y+Math.max(1,f.length)}return r}function sp(c,o){const u=c.value.substring(0,Math.max(0,o)).split(`
`).length-1,f=window.getComputedStyle(c),m=parseFloat(f.lineHeight),y=Number.isFinite(m)&&m>0?m:22,S=parseFloat(f.paddingTop)||0,x=u*y-c.clientHeight/3+S;c.scrollTop=Math.max(0,x)}function Ku(c,o,r,u){const f=u?.focus!==!1;f&&c.focus(),(f||document.activeElement===c)&&c.setSelectionRange(o,o+r),sp(c,o)}const up=({node:c})=>{const o=Be(),r=Q(oe=>oe.rawHtml),u=Q(oe=>oe.updateNodeOuterHtml),[f,m]=g.useState(""),[y,S]=g.useState(null),[x,h]=g.useState(!1),[A,C]=g.useState(!1),[Y,R]=g.useState(""),[L,G]=g.useState(0),Z=g.useRef(null),q=g.useRef(null),X=g.useRef([]),j=g.useMemo(()=>Km(r,c.xpath)??c.outerHtml,[c.outerHtml,c.xpath,r]),F=g.useMemo(()=>zu(j),[j]);g.useEffect(()=>{m(F),S(null),R(""),G(0)},[F,c.id]);const ae=g.useMemo(()=>Zu(f,Y.trim()),[f,Y]);X.current=ae,g.useEffect(()=>{if(ae.length===0){G(0);return}G(oe=>oe>=ae.length?0:oe)},[ae]);const ne=g.useCallback((oe,M)=>{const U=Z.current,ee=X.current,Te=Y.trim();if(!U||ee.length===0||!Te)return;const Ce=ee[oe];typeof Ce=="number"&&window.requestAnimationFrame(()=>{Ku(U,Ce,Te.length,M)})},[Y]);g.useEffect(()=>{!Y.trim()||X.current.length===0||ne(0,{focus:!1})},[Y,ne]);const K=g.useCallback(async()=>{try{await navigator.clipboard.writeText(f),h(!0),window.setTimeout(()=>h(!1),2e3)}catch{}},[f]),se=g.useCallback(()=>{const oe=f.trim(),M=cp(oe);if(!M.valid){M.reason==="document_tags"?S(o.paste_no_document_tags):(M.reason,S(o.element_html_invalid));return}S(null),C(!0),u(c.id,oe),C(!1)},[f,c.id,o.element_html_invalid,o.paste_no_document_tags,u]),Ee=g.useCallback(()=>{ae.length!==0&&G(oe=>{const M=oe<=0?ae.length-1:oe-1;return ne(M,{focus:!0}),M})},[ae.length,ne]),$=g.useCallback(()=>{ae.length!==0&&G(oe=>{const M=oe>=ae.length-1?0:oe+1;return ne(M,{focus:!0}),M})},[ae.length,ne]),_e=g.useCallback(oe=>{oe.key==="Enter"&&(oe.preventDefault(),oe.shiftKey?Ee():$())},[$,Ee]),ve=f.trim()!==F.trim(),ke=ae.length>0?o.html_source_search_count.replace("%1$s",String(L+1)).replace("%2$s",String(ae.length)):Y.trim()?o.html_source_search_none:"",le=ae.length>0;return _.jsxs("div",{className:k.html_tab,children:[_.jsxs("div",{className:k.html_tab__actions,children:[_.jsx(Pe,{variant:"secondary",size:"sm",onClick:K,children:x?o.copied:o.copy_html}),_.jsx(Pe,{variant:"primary",size:"sm",onClick:se,loading:A,disabled:!ve||!f.trim(),children:o.update_html})]}),_.jsxs("div",{className:k.html_tab__search,role:"search",children:[_.jsxs("label",{className:k.html_tab__search_label,htmlFor:"notifal-element-html-search",children:[_.jsx(de,{name:"search",size:12}),_.jsx("span",{className:k.html_tab__search_sr,children:o.html_source_search})]}),_.jsx("input",{id:"notifal-element-html-search",ref:q,type:"search",className:k.html_tab__search_input,value:Y,onChange:oe=>{R(oe.target.value),G(0)},onKeyDown:_e,placeholder:o.html_source_search_placeholder,autoComplete:"off",spellCheck:!1}),_.jsx("span",{className:k.html_tab__search_count,"aria-live":"polite",children:ke}),_.jsxs("div",{className:k.html_tab__search_nav,children:[_.jsx("button",{type:"button",className:k.html_tab__search_nav_btn,onClick:Ee,disabled:!le,"aria-label":o.html_source_search_prev,title:o.html_source_search_prev,children:_.jsx(de,{name:"chevron-left",size:12})}),_.jsx("button",{type:"button",className:k.html_tab__search_nav_btn,onClick:$,disabled:!le,"aria-label":o.html_source_search_next,title:o.html_source_search_next,children:_.jsx(de,{name:"chevron-right",size:12})})]})]}),_.jsx("textarea",{ref:Z,className:[k.html_tab__textarea,y?k["html_tab__textarea--error"]:""].filter(Boolean).join(" "),value:f,onChange:oe=>{m(oe.target.value),y&&S(null)},spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off","aria-label":o.element_html_label,"aria-invalid":y?"true":void 0}),y?_.jsx("p",{className:k.html_tab__error,role:"alert",children:y}):_.jsx("p",{className:k.html_tab__hint,children:o.element_html_hint})]})};function rp(c,o){if(!o)return null;if(o.isCountdownPlaceholder)return o;let r=o.parentId;for(;r;){const u=kt(c,r);if(!u)break;if(u.isCountdownPlaceholder)return u;r=u.parentId}return null}const _p=()=>{const c=Be();return _.jsxs("div",{className:k.panel__empty,children:[_.jsx("div",{className:k.panel__empty_icon,children:_.jsx(de,{name:"cursor",size:20})}),_.jsx("p",{className:k.panel__empty_title,children:c.no_element_selected}),_.jsx("p",{className:k.panel__empty_hint,children:c.select_element_hint})]})},fp=()=>{const c=Be(),[o,r]=g.useState("style"),u=g.useMemo(()=>[{id:"style",label:c.tab_style},{id:"content",label:c.tab_content},{id:"html",label:c.view_html}],[c.tab_style,c.tab_content,c.view_html]),f=Q(Fm),m=Q(j=>j.nodes),y=Q(j=>j.updateText),S=Q(j=>j.updateStyle),x=Q(j=>j.updateImageSrc),h=Q(j=>j.updateLinkHref),A=Q(j=>j.updateCountdownSettings),C=Q(j=>j.isRightPanelVisible),Y=Q(j=>j.toggleRightPanel),R=g.useMemo(()=>rp(m,f),[m,f]),L=g.useCallback(j=>{f&&y(f.id,j)},[f,y]),G=g.useCallback((j,F)=>{f&&S(f.id,j,F)},[f,S]),Z=g.useCallback(j=>{f&&x(f.id,j)},[f,x]),q=g.useCallback(j=>{f&&h(f.id,j)},[f,h]),X=g.useCallback(j=>{R&&A(R.id,j)},[R,A]);return _.jsxs("aside",{className:k.panel,children:[_.jsxs("div",{className:k.panel__header,children:[_.jsxs("div",{className:k.panel__header_title,children:[_.jsx(de,{name:"sliders2",size:14}),_.jsx("span",{children:c.properties})]}),_.jsxs("div",{className:k.panel__header_actions,children:[f&&_.jsxs("span",{className:k.panel__header_tag,children:["<",f.tagName,">"]}),_.jsx(Fn,{side:"right",isVisible:C,label:c.hide_right_panel,onClick:Y,placement:"header"})]})]}),_.jsx("div",{className:k.panel__tabs,role:"tablist",children:u.map(j=>_.jsx("button",{className:[k.panel__tab,o===j.id?k["panel__tab--active"]:""].filter(Boolean).join(" "),role:"tab","aria-selected":o===j.id,onClick:()=>r(j.id),children:j.label},j.id))}),_.jsx("div",{className:k.panel__body,children:f?_.jsxs(_.Fragment,{children:[o==="style"&&_.jsx($h,{node:f,onUpdateStyle:G}),o==="content"&&_.jsxs(_.Fragment,{children:[R?_.jsx(ip,{node:R,onUpdateSettings:X}):null,f.isImageEditable?_.jsx(tp,{node:f,onUpdateSrc:Z}):null,f.isLinkEditable?_.jsx(ap,{node:f,onUpdateHref:q}):null,!R||f.isTextEditable?_.jsx(Fh,{node:f,onUpdateText:L}):null]}),o==="html"&&_.jsx(up,{node:f})]}):_.jsx(_p,{})})]})},_t={layout:"_layout_7codm_5",layout__panel:"_layout__panel_7codm_23","layout__panel--left":"_layout__panel--left_7codm_39","layout__panel--center":"_layout__panel--center_7codm_47","layout__panel--right":"_layout__panel--right_7codm_59","layout__panel--collapsed":"_layout__panel--collapsed_7codm_67",layout__center_shell:"_layout__center_shell_7codm_105",layout__resize_handle:"_layout__resize_handle_7codm_123","layout__resize_handle--active":"_layout__resize_handle--active_7codm_169"},dp=260,mp=280,hp=180,pp=220,Ju=180,$u="notifal_html_builder_panel_widths",yp=()=>{const c=Be(),o=g.useRef(null),[r,u]=g.useState(dp),[f,m]=g.useState(mp),[y,S]=g.useState(null),x=g.useRef(null),h=g.useRef(r),A=g.useRef(f),C=Q(q=>q.isLeftPanelVisible),Y=Q(q=>q.isRightPanelVisible),R=Q(q=>q.toggleLeftPanel),L=Q(q=>q.toggleRightPanel);h.current=r,A.current=f,g.useEffect(()=>{if(window.localStorage)try{const q=window.localStorage.getItem($u);if(!q)return;const X=JSON.parse(q);typeof X.left=="number"&&u(X.left),typeof X.right=="number"&&m(X.right)}catch{return}},[]);const G=g.useCallback((q,X)=>{window.localStorage&&window.localStorage.setItem($u,JSON.stringify({left:q,right:X}))},[]),Z=g.useCallback((q,X)=>{X.preventDefault(),x.current={side:q,startX:X.clientX,startLeft:r,startRight:f},S(q)},[r,f]);return g.useEffect(()=>{if(!y)return;const q=j=>{const F=x.current,ae=o.current;if(!F||!ae)return;const ne=ae.getBoundingClientRect().width,K=12,se=j.clientX-F.startX;if(F.side==="left"){const _e=ne-F.startRight-Ju-K,ve=Math.max(hp,Math.min(_e,F.startLeft+se));u(ve);return}const Ee=ne-F.startLeft-Ju-K,$=Math.max(pp,Math.min(Ee,F.startRight-se));m($)},X=()=>{S(null),x.current=null,G(h.current,A.current)};return document.addEventListener("mousemove",q),document.addEventListener("mouseup",X),()=>{document.removeEventListener("mousemove",q),document.removeEventListener("mouseup",X)}},[y,G]),_.jsxs("div",{className:_t.layout,ref:o,children:[_.jsx("div",{className:[_t.layout__panel,_t["layout__panel--left"],C?"":_t["layout__panel--collapsed"]].filter(Boolean).join(" "),style:{width:C?r:0},"aria-hidden":!C,children:_.jsx(Ah,{})}),C?_.jsx("div",{className:[_t.layout__resize_handle,y==="left"?_t["layout__resize_handle--active"]:""].filter(Boolean).join(" "),onMouseDown:q=>Z("left",q),role:"separator","aria-orientation":"vertical","aria-label":c.resize_elements_panel}):null,_.jsxs("div",{className:_t.layout__center_shell,children:[C?null:_.jsx(Fn,{side:"left",isVisible:!1,label:c.show_left_panel,onClick:R,placement:"edge"}),_.jsx("div",{className:`${_t.layout__panel} ${_t["layout__panel--center"]}`,children:_.jsx(Gh,{})}),Y?null:_.jsx(Fn,{side:"right",isVisible:!1,label:c.show_right_panel,onClick:L,placement:"edge"})]}),Y?_.jsx("div",{className:[_t.layout__resize_handle,y==="right"?_t["layout__resize_handle--active"]:""].filter(Boolean).join(" "),onMouseDown:q=>Z("right",q),role:"separator","aria-orientation":"vertical","aria-label":c.resize_properties_panel}):null,_.jsx("div",{className:[_t.layout__panel,_t["layout__panel--right"],Y?"":_t["layout__panel--collapsed"]].filter(Boolean).join(" "),style:{width:Y?f:0},"aria-hidden":!Y,children:_.jsx(fp,{})})]})},je={overlay:"_overlay_8w2gx_3",card:"_card_8w2gx_21","card--wide":"_card--wide_8w2gx_33",card__ai_embed:"_card__ai_embed_8w2gx_37",card__header:"_card__header_8w2gx_51",card__logo:"_card__logo_8w2gx_59",card__logo_image:"_card__logo_image_8w2gx_71",card__title:"_card__title_8w2gx_79",card__subtitle:"_card__subtitle_8w2gx_87",card__body:"_card__body_8w2gx_95",textarea__label:"_textarea__label_8w2gx_102",textarea__wrapper:"_textarea__wrapper_8w2gx_110",textarea:"_textarea_8w2gx_102","textarea--error":"_textarea--error_8w2gx_142",textarea__badge:"_textarea__badge_8w2gx_150",error:"_error_8w2gx_162",hint:"_hint_8w2gx_171",card__footer:"_card__footer_8w2gx_190",welcome__title:"_welcome__title_8w2gx_202",welcome__lead:"_welcome__lead_8w2gx_209",welcome__options:"_welcome__options_8w2gx_216",welcome__option:"_welcome__option_8w2gx_216",welcome__option_icon:"_welcome__option_icon_8w2gx_242",welcome__option_label:"_welcome__option_label_8w2gx_253",welcome__option_hint:"_welcome__option_hint_8w2gx_259"},gp=({isVisible:c})=>{const o=Jn(),r=Be(),[u,f]=g.useState("choice"),[m,y]=g.useState(""),[S,x]=g.useState(null),h=g.useRef(null),A=Q(L=>L.loadHtml);g.useEffect(()=>{c&&(f("choice"),x(null))},[c]),g.useEffect(()=>{c&&u==="paste"&&h.current&&window.setTimeout(()=>h.current?.focus(),100)},[c,u]);const C=g.useCallback(()=>{const L=m.trim();if(!L){x(r.paste_placeholder);return}const G=Qu(L);if(!G.valid){G.reason==="document_tags"?x(r.paste_no_document_tags):x(r.paste_placeholder);return}if(L.length<10){x(r.paste_label);return}x(null),A(L,{markDirty:!0})},[m,A,r.paste_label,r.paste_no_document_tags,r.paste_placeholder]),Y=g.useCallback(L=>{(L.ctrlKey||L.metaKey)&&L.key==="Enter"&&(L.preventDefault(),C())},[C]);if(!c)return null;const R=()=>_.jsxs("div",{className:je.card__header,children:[o.logo_url?_.jsx("img",{src:o.logo_url,alt:r.app_name,className:je.card__logo_image,width:40,height:40}):_.jsx("div",{className:je.card__logo,children:_.jsx(de,{name:"file-earmark-code",size:20})}),_.jsxs("div",{children:[_.jsx("h1",{className:je.card__title,children:r.app_name}),_.jsx("p",{className:je.card__subtitle,children:u==="choice"?r.welcome_subtitle:r.app_subtitle})]})]});return _.jsx("div",{className:je.overlay,role:"dialog","aria-modal":"true","aria-label":r.welcome_title,children:_.jsxs("div",{className:[je.card,u==="ai"?je["card--wide"]:""].filter(Boolean).join(" "),children:[u!=="ai"?R():null,u==="choice"?_.jsxs("div",{className:je.card__body,children:[_.jsx("h2",{className:je.welcome__title,children:r.welcome_title}),_.jsx("p",{className:je.welcome__lead,children:r.welcome_lead}),_.jsxs("div",{className:je.welcome__options,children:[_.jsxs("button",{type:"button",className:je.welcome__option,onClick:()=>f("paste"),children:[_.jsx("span",{className:je.welcome__option_icon,"aria-hidden":"true",children:_.jsx(de,{name:"clipboard",size:22})}),_.jsx("span",{className:je.welcome__option_label,children:r.welcome_have_html}),_.jsx("span",{className:je.welcome__option_hint,children:r.welcome_have_html_hint})]}),_.jsxs("button",{type:"button",className:je.welcome__option,onClick:()=>f("ai"),children:[_.jsx("span",{className:je.welcome__option_icon,"aria-hidden":"true",children:_.jsx(de,{name:"ai",size:22})}),_.jsx("span",{className:je.welcome__option_label,children:r.welcome_generate_ai}),_.jsx("span",{className:je.welcome__option_hint,children:r.welcome_generate_ai_hint})]})]})]}):null,u==="paste"?_.jsxs(_.Fragment,{children:[_.jsxs("div",{className:je.card__body,children:[_.jsx("label",{className:je.textarea__label,htmlFor:"notifal-html-builder-paste-input",children:r.paste_label}),_.jsxs("div",{className:je.textarea__wrapper,children:[_.jsx("textarea",{id:"notifal-html-builder-paste-input",ref:h,className:[je.textarea,S?je["textarea--error"]:""].filter(Boolean).join(" "),value:m,onChange:L=>{y(L.target.value),S&&x(null)},onKeyDown:Y,placeholder:r.paste_placeholder,spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off"}),m.length>0?_.jsxs("div",{className:je.textarea__badge,children:[m.length.toLocaleString()," ",r.chars]}):null]}),_.jsx("p",{className:je.hint,children:r.paste_fragment_hint}),S?_.jsx("p",{className:je.error,role:"alert",children:S}):null]}),_.jsxs("div",{className:je.card__footer,children:[_.jsx(Pe,{variant:"secondary",size:"lg",onClick:()=>f("choice"),children:r.welcome_back}),_.jsx(Pe,{variant:"primary",size:"lg",onClick:C,disabled:!m.trim(),children:r.load_html})]})]}):null,u==="ai"?_.jsx("div",{className:[P.modal,je.card__ai_embed].join(" "),children:_.jsx(Lu,{variant:"embedded",onBack:()=>f("choice")})}):null]})})},Qe={overlay:"_overlay_tely9_3",modal:"_modal_tely9_21",modal__header:"_modal__header_tely9_39",modal__title:"_modal__title_tely9_48",modal__close:"_modal__close_tely9_61",modal__search:"_modal__search_tely9_82",modal__search_label:"_modal__search_label_tely9_92",modal__search_sr:"_modal__search_sr_tely9_99",modal__search_input:"_modal__search_input_tely9_111",modal__search_count:"_modal__search_count_tely9_130",modal__search_nav:"_modal__search_nav_tely9_139",modal__search_nav_btn:"_modal__search_nav_btn_tely9_146",modal__body:"_modal__body_tely9_169",modal__textarea:"_modal__textarea_tely9_178","modal__textarea--error":"_modal__textarea--error_tely9_201",modal__hint:"_modal__hint_tely9_205",modal__error:"_modal__error_tely9_214",modal__footer:"_modal__footer_tely9_234",modal__footer_actions:"_modal__footer_actions_tely9_244",modal__chars:"_modal__chars_tely9_250"},vp=({onClose:c})=>{const o=Be(),r=Q($=>$.exportEditableHtml),u=Q($=>$.applyHtmlSource),[f,m]=g.useState(""),[y,S]=g.useState(!1),[x,h]=g.useState(null),[A,C]=g.useState(""),[Y,R]=g.useState(0),L=g.useRef(null),G=g.useRef(null),Z=g.useRef([]);g.useEffect(()=>{m(zu(r()))},[r]);const q=g.useMemo(()=>Zu(f,A.trim()),[f,A]);Z.current=q,g.useEffect(()=>{if(q.length===0){R(0);return}R($=>$>=q.length?0:$)},[q]);const X=g.useCallback(($,_e)=>{const ve=L.current,ke=Z.current,le=A.trim();if(!ve||ke.length===0||!le)return;const oe=ke[$];typeof oe=="number"&&window.requestAnimationFrame(()=>{Ku(ve,oe,le.length,_e)})},[A]);g.useEffect(()=>{!A.trim()||Z.current.length===0||X(0,{focus:!1})},[A,X]);const j=g.useCallback(()=>{const $=f.trim();if(!$)return;const _e=Qu($);if(!_e.valid){_e.reason==="document_tags"?h(o.paste_no_document_tags):h(o.paste_placeholder);return}h(null),S(!0),u($),S(!1),c()},[f,u,c,o.paste_no_document_tags,o.paste_placeholder]),F=g.useCallback($=>{$.target===$.currentTarget&&c()},[c]),ae=g.useCallback(()=>{q.length!==0&&R($=>{const _e=$<=0?q.length-1:$-1;return X(_e,{focus:!0}),_e})},[q.length,X]),ne=g.useCallback(()=>{q.length!==0&&R($=>{const _e=$>=q.length-1?0:$+1;return X(_e,{focus:!0}),_e})},[q.length,X]),K=g.useCallback($=>{$.key==="Enter"&&($.preventDefault(),$.shiftKey?ae():ne())},[ne,ae]);g.useEffect(()=>{const $=_e=>{if((_e.ctrlKey||_e.metaKey)&&_e.key.toLowerCase()==="f"){_e.preventDefault(),G.current?.focus(),G.current?.select();return}_e.key==="Escape"&&c()};return window.addEventListener("keydown",$),()=>window.removeEventListener("keydown",$)},[c]);const se=q.length>0?o.html_source_search_count.replace("%1$s",String(Y+1)).replace("%2$s",String(q.length)):A.trim()?o.html_source_search_none:"",Ee=q.length>0;return _.jsx("div",{className:Qe.overlay,onClick:F,role:"dialog","aria-modal":"true",children:_.jsxs("div",{className:Qe.modal,children:[_.jsxs("div",{className:Qe.modal__header,children:[_.jsx("h2",{className:Qe.modal__title,children:o.html_source}),_.jsx("button",{type:"button",className:Qe.modal__close,onClick:c,"aria-label":o.close,children:_.jsx(de,{name:"x-circle",size:14})})]}),_.jsxs("div",{className:Qe.modal__search,role:"search",children:[_.jsxs("label",{className:Qe.modal__search_label,htmlFor:"notifal-html-source-search",children:[_.jsx(de,{name:"search",size:14}),_.jsx("span",{className:Qe.modal__search_sr,children:o.html_source_search})]}),_.jsx("input",{id:"notifal-html-source-search",ref:G,type:"search",className:Qe.modal__search_input,value:A,onChange:$=>{C($.target.value),R(0)},onKeyDown:K,placeholder:o.html_source_search_placeholder,autoComplete:"off",spellCheck:!1}),_.jsx("span",{className:Qe.modal__search_count,"aria-live":"polite",children:se}),_.jsxs("div",{className:Qe.modal__search_nav,children:[_.jsx("button",{type:"button",className:Qe.modal__search_nav_btn,onClick:ae,disabled:!Ee,"aria-label":o.html_source_search_prev,title:o.html_source_search_prev,children:_.jsx(de,{name:"chevron-left",size:14})}),_.jsx("button",{type:"button",className:Qe.modal__search_nav_btn,onClick:ne,disabled:!Ee,"aria-label":o.html_source_search_next,title:o.html_source_search_next,children:_.jsx(de,{name:"chevron-right",size:14})})]})]}),_.jsxs("div",{className:Qe.modal__body,children:[_.jsx("textarea",{ref:L,className:[Qe.modal__textarea,x?Qe["modal__textarea--error"]:""].filter(Boolean).join(" "),value:f,onChange:$=>{m($.target.value),x&&h(null)},spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off","aria-label":o.html_source,"aria-invalid":x?"true":void 0}),x?_.jsx("p",{className:Qe.modal__error,role:"alert",children:x}):_.jsx("p",{className:Qe.modal__hint,children:o.paste_fragment_hint})]}),_.jsxs("div",{className:Qe.modal__footer,children:[_.jsxs("span",{className:Qe.modal__chars,children:[f.length.toLocaleString()," ",o.chars]}),_.jsxs("div",{className:Qe.modal__footer_actions,children:[_.jsx(Pe,{variant:"secondary",size:"sm",onClick:c,children:o.close}),_.jsx(Pe,{variant:"primary",size:"sm",onClick:j,loading:y,disabled:!f.trim(),children:o.update_html})]})]})]})})},ei={app:"_app_8m039_3",app__body:"_app__body_8m039_13",app__error:"_app__error_8m039_20",app__error_close:"_app__error_close_8m039_47"},bp=()=>{const c=Jn(),o=Be(),r=Q(X=>X.rawHtml),u=Q(X=>X.error),f=Q(X=>X.clearError),m=Q(X=>X.undo),y=Q(X=>X.redo),S=Q(X=>X.loadHtml),x=Q(X=>X.isDirty),h=Q(X=>X.historyIndex),A=Q(X=>X.history.length),C=Q(X=>X.showHtmlModal),Y=Q(X=>X.closeHtmlModal),R=c.initial_html.trim().length>0,[L,G]=g.useState(()=>!R),Z=L&&r.length===0&&!R;g.useLayoutEffect(()=>{R&&S(c.initial_html),G(!0)},[c.initial_html,R,S]),g.useEffect(()=>{nh()},[]),g.useEffect(()=>{const X=j=>{x&&(j.preventDefault(),j.returnValue=o.unsaved_leave_confirm)};return window.addEventListener("beforeunload",X),()=>window.removeEventListener("beforeunload",X)},[x,o.unsaved_leave_confirm]);const q=g.useCallback(X=>{const j=X.ctrlKey||X.metaKey;if(j&&X.key==="z"&&!X.shiftKey){h>0&&(X.preventDefault(),m());return}(j&&X.shiftKey&&X.key==="z"||j&&X.key==="y")&&h<A-1&&(X.preventDefault(),y())},[m,y,h,A]);return g.useEffect(()=>(window.addEventListener("keydown",q),()=>window.removeEventListener("keydown",q)),[q]),_.jsxs("div",{className:ei.app,dir:"ltr",children:[_.jsx(xh,{}),_.jsx("div",{className:ei.app__body,children:_.jsx(yp,{})}),u&&_.jsxs("div",{className:ei.app__error,role:"alert",children:[_.jsx("span",{children:u}),_.jsx("button",{type:"button",className:ei.app__error_close,onClick:f,"aria-label":o.dismiss_error,children:_.jsx(de,{name:"x-circle",size:12})})]}),_.jsx(gp,{isVisible:Z}),C?_.jsx(vp,{onClose:Y}):null]})},qo="notifal-html-builder-loader";function Wu(){const c=document.getElementById("notifal-html-builder-root");if(!c||!window.NotifalHtmlBuilderStrings){Ro(qo);return}try{um.createRoot(c).render(_.jsx(g.StrictMode,{children:_.jsx(ih,{children:_.jsx(bp,{})})}))}catch{Ro(qo);return}Ro(qo)}document.readyState==="loading"?document.addEventListener("DOMContentLoaded",Wu):Wu()})();
