webim-adapter 2.7.12 → 2.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,8 +5,8 @@
5
5
  `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
6
6
  `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{fe=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?de(n):``}function me(e,t){switch(e.tag){case 26:case 27:case 5:return de(e.type);case 16:return de(`Lazy`);case 13:return e.child!==t&&t!==null?de(`Suspense Fallback`):de(`Suspense`);case 19:return de(`SuspenseList`);case 0:case 15:return pe(e.type,!1);case 11:return pe(e.type.render,!1);case 1:return pe(e.type,!0);case 31:return de(`Activity`);default:return``}}function he(e){try{var t=``,n=null;do t+=me(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
7
7
  Error generating stack: `+e.message+`
8
- `+e.stack}}var ge=Object.prototype.hasOwnProperty,_e=t.unstable_scheduleCallback,ve=t.unstable_cancelCallback,ye=t.unstable_shouldYield,be=t.unstable_requestPaint,xe=t.unstable_now,Se=t.unstable_getCurrentPriorityLevel,Ce=t.unstable_ImmediatePriority,we=t.unstable_UserBlockingPriority,Te=t.unstable_NormalPriority,U=t.unstable_LowPriority,Ee=t.unstable_IdlePriority,De=t.log,Oe=t.unstable_setDisableYieldValue,ke=null,Ae=null;function je(e){if(typeof De==`function`&&Oe(e),Ae&&typeof Ae.setStrictMode==`function`)try{Ae.setStrictMode(ke,e)}catch{}}var Me=Math.clz32?Math.clz32:Fe,Ne=Math.log,Pe=Math.LN2;function Fe(e){return e>>>=0,e===0?32:31-(Ne(e)/Pe|0)|0}var Ie=256,Le=262144,Re=4194304;function ze(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 Be(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=ze(n))):i=ze(o):i=ze(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=ze(n))):i=ze(o)):i=ze(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Ve(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function He(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 Ue(){var e=Re;return Re<<=1,!(Re&62914560)&&(Re=4194304),e}function We(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ge(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ke(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Me(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&qe(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function qe(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Me(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Je(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Me(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Ye(e,t){var n=t&-t;return n=n&42?1:Xe(n),(n&(e.suspendedLanes|t))===0?n:0}function Xe(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 Ze(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function Qe(){var e=L.p;return e===0?(e=window.event,e===void 0?32:mp(e.type)):e}function $e(e,t){var n=L.p;try{return L.p=e,t()}finally{L.p=n}}var et=Math.random().toString(36).slice(2),tt=`__reactFiber$`+et,nt=`__reactProps$`+et,rt=`__reactContainer$`+et,it=`__reactEvents$`+et,at=`__reactListeners$`+et,ot=`__reactHandles$`+et,st=`__reactResources$`+et,ct=`__reactMarker$`+et;function lt(e){delete e[tt],delete e[nt],delete e[it],delete e[at],delete e[ot]}function ut(e){var t=e[tt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[rt]||n[tt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=df(e);e!==null;){if(n=e[tt])return n;e=df(e)}return t}e=n,n=e.parentNode}return null}function dt(e){if(e=e[tt]||e[rt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ft(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(s(33))}function pt(e){var t=e[st];return t||=e[st]={hoistableStyles:new Map,hoistableScripts:new Map},t}function mt(e){e[ct]=!0}var ht=new Set,gt={};function _t(e,t){vt(e,t),vt(e+`Capture`,t)}function vt(e,t){for(gt[e]=t,e=0;e<t.length;e++)ht.add(t[e])}var yt=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]*$`),bt={},xt={};function St(e){return ge.call(xt,e)?!0:ge.call(bt,e)?!1:yt.test(e)?xt[e]=!0:(bt[e]=!0,!1)}function Ct(e,t,n){if(St(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function wt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Tt(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Et(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Dt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Ot(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function kt(e){if(!e._valueTracker){var t=Dt(e)?`checked`:`value`;e._valueTracker=Ot(e,t,``+e[t])}}function At(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Dt(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function jt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Mt=/[\n"\\]/g;function Nt(e){return e.replace(Mt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Pt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Et(t)):e.value!==``+Et(t)&&(e.value=``+Et(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):It(e,o,Et(n)):It(e,o,Et(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Et(s):e.removeAttribute(`name`)}function Ft(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){kt(e);return}n=n==null?``:``+Et(n),t=t==null?n:``+Et(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),kt(e)}function It(e,t,n){t===`number`&&jt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Lt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Et(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Rt(e,t,n){if(t!=null&&(t=``+Et(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Et(n)}function zt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(s(92));if(F(r)){if(1<r.length)throw Error(s(93));r=r[0]}n=r}n??=``,t=n}n=Et(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),kt(e)}function Bt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Vt=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 Ht(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Vt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Ut(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(s(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var i in t)r=t[i],t.hasOwnProperty(i)&&n[i]!==r&&Ht(e,i,r)}else for(var a in t)t.hasOwnProperty(a)&&Ht(e,a,t[a])}function Wt(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 Gt=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`]]),Kt=/^[\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 qt(e){return Kt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Jt(){}var Yt=null;function Xt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Zt=null,Qt=null;function $t(e){var t=dt(e);if(t&&(e=t.stateNode)){var n=e[nt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Pt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Nt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=r[nt]||null;if(!i)throw Error(s(90));Pt(r,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&At(r)}break a;case`textarea`:Rt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Lt(e,!!n.multiple,t,!1)}}}var en=!1;function tn(e,t,n){if(en)return e(t,n);en=!0;try{return e(t)}finally{if(en=!1,(Zt!==null||Qt!==null)&&(vu(),Zt&&(t=Zt,e=Qt,Qt=Zt=null,$t(t),e)))for(t=0;t<e.length;t++)$t(e[t])}}function nn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[nt]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(s(231,t,typeof n));return n}var rn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),an=!1;if(rn)try{var on={};Object.defineProperty(on,"passive",{get:function(){an=!0}}),window.addEventListener(`test`,on,on),window.removeEventListener(`test`,on,on)}catch{an=!1}var sn=null,cn=null,ln=null;function un(){if(ln)return ln;var e,t=cn,n=t.length,r,i=`value`in sn?sn.value:sn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return ln=i.slice(e,1<r?1-r:void 0)}function dn(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 fn(){return!0}function pn(){return!1}function mn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?fn:pn,this.isPropagationStopped=pn,this}return h(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=fn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=fn)},persist:function(){},isPersistent:fn}),t}var hn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gn=mn(hn),_n=h({},hn,{view:0,detail:0}),vn=mn(_n),yn,bn,xn,Sn=h({},_n,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:W,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!==xn&&(xn&&e.type===`mousemove`?(yn=e.screenX-xn.screenX,bn=e.screenY-xn.screenY):bn=yn=0,xn=e),yn)},movementY:function(e){return`movementY`in e?e.movementY:bn}}),Cn=mn(Sn),wn=mn(h({},Sn,{dataTransfer:0})),Tn=mn(h({},_n,{relatedTarget:0})),En=mn(h({},hn,{animationName:0,elapsedTime:0,pseudoElement:0})),Dn=mn(h({},hn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),On=mn(h({},hn,{data:0})),kn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},An={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`},jn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Mn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=jn[e])?!!t[e]:!1}function W(){return Mn}var Nn=mn(h({},_n,{key:function(e){if(e.key){var t=kn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=dn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?An[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:W,charCode:function(e){return e.type===`keypress`?dn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?dn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Pn=mn(h({},Sn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Fn=mn(h({},_n,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:W})),In=mn(h({},hn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Ln=mn(h({},Sn,{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})),Rn=mn(h({},hn,{newState:0,oldState:0})),G=[9,13,27,32],zn=rn&&`CompositionEvent`in window,Bn=null;rn&&`documentMode`in document&&(Bn=document.documentMode);var Vn=rn&&`TextEvent`in window&&!Bn,Hn=rn&&(!zn||Bn&&8<Bn&&11>=Bn),Un=` `,Wn=!1;function Gn(e,t){switch(e){case`keyup`:return G.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Kn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var qn=!1;function Jn(e,t){switch(e){case`compositionend`:return Kn(t);case`keypress`:return t.which===32?(Wn=!0,Un):null;case`textInput`:return e=t.data,e===Un&&Wn?null:e;default:return null}}function Yn(e,t){if(qn)return e===`compositionend`||!zn&&Gn(e,t)?(e=un(),ln=cn=sn=null,qn=!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 Hn&&t.locale!==`ko`?null:t.data;default:return null}}var Xn={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 Zn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!Xn[e.type]:t===`textarea`}function Qn(e,t,n,r){Zt?Qt?Qt.push(r):Qt=[r]:Zt=r,t=Td(t,`onChange`),0<t.length&&(n=new gn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var $n=null,er=null;function tr(e){vd(e,0)}function nr(e){if(At(ft(e)))return e}function rr(e,t){if(e===`change`)return t}var ir=!1;if(rn){var ar;if(rn){var or=`oninput`in document;if(!or){var sr=document.createElement(`div`);sr.setAttribute(`oninput`,`return;`),or=typeof sr.oninput==`function`}ar=or}else ar=!1;ir=ar&&(!document.documentMode||9<document.documentMode)}function cr(){$n&&($n.detachEvent(`onpropertychange`,lr),er=$n=null)}function lr(e){if(e.propertyName===`value`&&nr(er)){var t=[];Qn(t,er,e,Xt(e)),tn(tr,t)}}function ur(e,t,n){e===`focusin`?(cr(),$n=t,er=n,$n.attachEvent(`onpropertychange`,lr)):e===`focusout`&&cr()}function dr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return nr(er)}function fr(e,t){if(e===`click`)return nr(t)}function pr(e,t){if(e===`input`||e===`change`)return nr(t)}function mr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var hr=typeof Object.is==`function`?Object.is:mr;function gr(e,t){if(hr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!ge.call(t,i)||!hr(e[i],t[i]))return!1}return!0}function _r(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function vr(e,t){var n=_r(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=_r(n)}}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 br(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=jt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=jt(e.document)}return t}function xr(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 Sr=rn&&`documentMode`in document&&11>=document.documentMode,Cr=null,wr=null,Tr=null,Er=!1;function Dr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Er||Cr==null||Cr!==jt(r)||(r=Cr,`selectionStart`in r&&xr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Tr&&gr(Tr,r)||(Tr=r,r=Td(wr,`onSelect`),0<r.length&&(t=new gn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Cr)))}function Or(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var kr={animationend:Or(`Animation`,`AnimationEnd`),animationiteration:Or(`Animation`,`AnimationIteration`),animationstart:Or(`Animation`,`AnimationStart`),transitionrun:Or(`Transition`,`TransitionRun`),transitionstart:Or(`Transition`,`TransitionStart`),transitioncancel:Or(`Transition`,`TransitionCancel`),transitionend:Or(`Transition`,`TransitionEnd`)},Ar={},jr={};rn&&(jr=document.createElement(`div`).style,`AnimationEvent`in window||(delete kr.animationend.animation,delete kr.animationiteration.animation,delete kr.animationstart.animation),`TransitionEvent`in window||delete kr.transitionend.transition);function Mr(e){if(Ar[e])return Ar[e];if(!kr[e])return e;var t=kr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in jr)return Ar[e]=t[n];return e}var Nr=Mr(`animationend`),Pr=Mr(`animationiteration`),Fr=Mr(`animationstart`),Ir=Mr(`transitionrun`),Lr=Mr(`transitionstart`),Rr=Mr(`transitioncancel`),zr=Mr(`transitionend`),Br=new Map,Vr=`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(` `);Vr.push(`scrollEnd`);function Hr(e,t){Br.set(e,t),_t(t,[e])}var Ur=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&&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)},Wr=[],Gr=0,Kr=0;function qr(){for(var e=Gr,t=Kr=Gr=0;t<e;){var n=Wr[t];Wr[t++]=null;var r=Wr[t];Wr[t++]=null;var i=Wr[t];Wr[t++]=null;var a=Wr[t];if(Wr[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&Zr(n,i,a)}}function Jr(e,t,n,r){Wr[Gr++]=e,Wr[Gr++]=t,Wr[Gr++]=n,Wr[Gr++]=r,Kr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function Yr(e,t,n,r){return Jr(e,t,n,r),Qr(e)}function Xr(e,t){return Jr(e,null,null,t),Qr(e)}function Zr(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Me(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function Qr(e){if(50<lu)throw lu=0,uu=null,Error(s(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var $r={};function ei(e,t,n,r){this.tag=e,this.key=n,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=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ti(e,t,n,r){return new ei(e,t,n,r)}function ni(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ri(e,t){var n=e.alternate;return n===null?(n=ti(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ii(e,t){e.flags&=65011714;var n=e.alternate;return n===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=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function ai(e,t,n,r,i,a){var o=0;if(r=e,typeof e==`function`)ni(e)&&(o=1);else if(typeof e==`string`)o=Uf(e,n,H.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case k:return e=ti(31,n,t,i),e.elementType=k,e.lanes=a,e;case y:return oi(n.children,i,a,t);case b:o=8,i|=24;break;case x:return e=ti(12,n,t,i|2),e.elementType=x,e.lanes=a,e;case T:return e=ti(13,n,t,i),e.elementType=T,e.lanes=a,e;case E:return e=ti(19,n,t,i),e.elementType=E,e.lanes=a,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:o=10;break a;case S:o=9;break a;case w:o=11;break a;case D:o=14;break a;case O:o=16,r=null;break a}o=29,n=Error(s(130,e===null?`null`:typeof e,``)),r=null}return t=ti(o,n,t,i),t.elementType=e,t.type=r,t.lanes=a,t}function oi(e,t,n,r){return e=ti(7,e,r,t),e.lanes=n,e}function si(e,t,n){return e=ti(6,e,null,t),e.lanes=n,e}function ci(e){var t=ti(18,null,null,0);return t.stateNode=e,t}function li(e,t,n){return t=ti(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var ui=new WeakMap;function di(e,t){if(typeof e==`object`&&e){var n=ui.get(e);return n===void 0?(t={value:e,source:t,stack:he(t)},ui.set(e,t),t):n}return{value:e,source:t,stack:he(t)}}var fi=[],pi=0,mi=null,hi=0,gi=[],_i=0,vi=null,yi=1,bi=``;function xi(e,t){fi[pi++]=hi,fi[pi++]=mi,mi=e,hi=t}function Si(e,t,n){gi[_i++]=yi,gi[_i++]=bi,gi[_i++]=vi,vi=e;var r=yi;e=bi;var i=32-Me(r)-1;r&=~(1<<i),n+=1;var a=32-Me(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,yi=1<<32-Me(t)+i|n<<i|r,bi=a+e}else yi=1<<a|n<<i|r,bi=e}function Ci(e){e.return!==null&&(xi(e,1),Si(e,1,0))}function wi(e){for(;e===mi;)mi=fi[--pi],fi[pi]=null,hi=fi[--pi],fi[pi]=null;for(;e===vi;)vi=gi[--_i],gi[_i]=null,bi=gi[--_i],gi[_i]=null,yi=gi[--_i],gi[_i]=null}function Ti(e,t){gi[_i++]=yi,gi[_i++]=bi,gi[_i++]=vi,yi=t.id,bi=t.overflow,vi=e}var Ei=null,Di=null,K=!1,Oi=null,ki=!1,Ai=Error(s(519));function ji(e){throw Li(di(Error(s(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Ai}function Mi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[tt]=e,t[nt]=r,n){case`dialog`:$(`cancel`,t),$(`close`,t);break;case`iframe`:case`object`:case`embed`:$(`load`,t);break;case`video`:case`audio`:for(n=0;n<gd.length;n++)$(gd[n],t);break;case`source`:$(`error`,t);break;case`img`:case`image`:case`link`:$(`error`,t),$(`load`,t);break;case`details`:$(`toggle`,t);break;case`input`:$(`invalid`,t),Ft(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:$(`invalid`,t);break;case`textarea`:$(`invalid`,t),zt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||jd(t.textContent,n)?(r.popover!=null&&($(`beforetoggle`,t),$(`toggle`,t)),r.onScroll!=null&&$(`scroll`,t),r.onScrollEnd!=null&&$(`scrollend`,t),r.onClick!=null&&(t.onclick=Jt),t=!0):t=!1,t||ji(e,!0)}function Ni(e){for(Ei=e.return;Ei;)switch(Ei.tag){case 5:case 31:case 13:ki=!1;return;case 27:case 3:ki=!0;return;default:Ei=Ei.return}}function Pi(e){if(e!==Ei)return!1;if(!K)return Ni(e),K=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Ud(e.type,e.memoizedProps)),n=!n),n&&Di&&ji(e),Ni(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(317));Di=uf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(317));Di=uf(e)}else t===27?(t=Di,Zd(e.type)?(e=lf,lf=null,Di=e):Di=t):Di=Ei?cf(e.stateNode.nextSibling):null;return!0}function Fi(){Di=Ei=null,K=!1}function Ii(){var e=Oi;return e!==null&&(Yl===null?Yl=e:Yl.push.apply(Yl,e),Oi=null),e}function Li(e){Oi===null?Oi=[e]:Oi.push(e)}var q=te(null),Ri=null,zi=null;function Bi(e,t,n){V(q,t._currentValue),t._currentValue=n}function Vi(e){e._currentValue=q.current,B(q)}function Hi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Ui(e,t,n,r){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var a=i.dependencies;if(a!==null){var o=i.child;a=a.firstContext;a:for(;a!==null;){var c=a;a=i;for(var l=0;l<t.length;l++)if(c.context===t[l]){a.lanes|=n,c=a.alternate,c!==null&&(c.lanes|=n),Hi(a.return,n,e),r||(o=null);break a}a=c.next}}else if(i.tag===18){if(o=i.return,o===null)throw Error(s(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Hi(o,n,e),o=null}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===e){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}}function Wi(e,t,n,r){e=null;for(var i=t,a=!1;i!==null;){if(!a){if(i.flags&524288)a=!0;else if(i.flags&262144)break}if(i.tag===10){var o=i.alternate;if(o===null)throw Error(s(387));if(o=o.memoizedProps,o!==null){var c=i.type;hr(i.pendingProps.value,o.value)||(e===null?e=[c]:e.push(c))}}else if(i===ie.current){if(o=i.alternate,o===null)throw Error(s(387));o.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e===null?e=[Qf]:e.push(Qf))}i=i.return}e!==null&&Ui(t,e,n,r),t.flags|=262144}function Gi(e){for(e=e.firstContext;e!==null;){if(!hr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Ki(e){Ri=e,zi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function qi(e){return Yi(Ri,e)}function Ji(e,t){return Ri===null&&Ki(e),Yi(e,t)}function Yi(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},zi===null){if(e===null)throw Error(s(308));zi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else zi=zi.next=t;return n}var Xi=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Zi=t.unstable_scheduleCallback,Qi=t.unstable_NormalPriority,$i={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ea(){return{controller:new Xi,data:new Map,refCount:0}}function ta(e){e.refCount--,e.refCount===0&&Zi(Qi,function(){e.controller.abort()})}var na=null,ra=0,ia=0,aa=null;function oa(e,t){if(na===null){var n=na=[];ra=0,ia=ud(),aa={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ra++,t.then(sa,sa),t}function sa(){if(--ra===0&&na!==null){aa!==null&&(aa.status=`fulfilled`);var e=na;na=null,ia=0,aa=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ca(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var la=I.S;I.S=function(e,t){Ql=xe(),typeof t==`object`&&t&&typeof t.then==`function`&&oa(e,t),la!==null&&la(e,t)};var ua=te(null);function da(){var e=ua.current;return e===null?Fl.pooledCache:e}function fa(e,t){t===null?V(ua,ua.current):V(ua,t.pool)}function pa(){var e=da();return e===null?null:{parent:$i._currentValue,pool:e}}var ma=Error(s(460)),ha=Error(s(474)),ga=Error(s(542)),_a={then:function(){}};function va(e){return e=e.status,e===`fulfilled`||e===`rejected`}function ya(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Jt,Jt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ca(e),e;default:if(typeof t.status==`string`)t.then(Jt,Jt);else{if(e=Fl,e!==null&&100<e.shellSuspendCounter)throw Error(s(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ca(e),e}throw xa=t,ma}}function ba(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(xa=e,ma):e}}var xa=null;function Sa(){if(xa===null)throw Error(s(459));var e=xa;return xa=null,e}function Ca(e){if(e===ma||e===ga)throw Error(s(483))}var wa=null,Ta=0;function Ea(e){var t=Ta;return Ta+=1,wa===null&&(wa=[]),ya(wa,e,t)}function Da(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Oa(e,t){throw t.$$typeof===g?Error(s(525)):(e=Object.prototype.toString.call(t),Error(s(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function ka(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function i(e,t){return e=ri(e,t),e.index=0,e.sibling=null,e}function a(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function o(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=si(n,e.mode,r),t.return=e,t):(t=i(t,n),t.return=e,t)}function l(e,t,n,r){var a=n.type;return a===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===a||typeof a==`object`&&a&&a.$$typeof===O&&ba(a)===t.type)?(t=i(t,n.props),Da(t,n),t.return=e,t):(t=ai(n.type,n.key,n.props,null,e.mode,r),Da(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=li(n,e.mode,r),t.return=e,t):(t=i(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,a){return t===null||t.tag!==7?(t=oi(n,e.mode,r,a),t.return=e,t):(t=i(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=si(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=ai(t.type,t.key,t.props,null,e.mode,n),Da(n,t),n.return=e,n;case v:return t=li(t,e.mode,n),t.return=e,t;case O:return t=ba(t),f(e,t,n)}if(F(t)||M(t))return t=oi(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ea(t),n);if(t.$$typeof===C)return f(e,Ji(e,t),n);Oa(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case O:return n=ba(n),p(e,t,n,r)}if(F(n)||M(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ea(n),r);if(n.$$typeof===C)return p(e,t,Ji(e,n),r);Oa(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case O:return r=ba(r),m(e,t,n,r,i)}if(F(r)||M(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Ea(r),i);if(r.$$typeof===C)return m(e,t,n,Ji(t,r),i);Oa(t,r)}return null}function h(i,o,s,c){for(var l=null,u=null,d=o,h=o=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),o=a(_,o,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),K&&xi(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(o=a(d,o,h),u===null?l=d:u.sibling=d,u=d);return K&&xi(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),o=a(g,o,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),K&&xi(i,h),l}function g(i,o,c,l){if(c==null)throw Error(s(151));for(var u=null,d=null,h=o,g=o=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),o=a(y,o,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),K&&xi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return K&&xi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),K&&xi(i,g),u}function b(e,r,a,c){if(typeof a==`object`&&a&&a.type===y&&a.key===null&&(a=a.props.children),typeof a==`object`&&a){switch(a.$$typeof){case _:a:{for(var l=a.key;r!==null;){if(r.key===l){if(l=a.type,l===y){if(r.tag===7){n(e,r.sibling),c=i(r,a.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===O&&ba(l)===r.type){n(e,r.sibling),c=i(r,a.props),Da(c,a),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}a.type===y?(c=oi(a.props.children,e.mode,c,a.key),c.return=e,e=c):(c=ai(a.type,a.key,a.props,null,e.mode,c),Da(c,a),c.return=e,e=c)}return o(e);case v:a:{for(l=a.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===a.containerInfo&&r.stateNode.implementation===a.implementation){n(e,r.sibling),c=i(r,a.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=li(a,e.mode,c),c.return=e,e=c}return o(e);case O:return a=ba(a),b(e,r,a,c)}if(F(a))return h(e,r,a,c);if(M(a)){if(l=M(a),typeof l!=`function`)throw Error(s(150));return a=l.call(a),g(e,r,a,c)}if(typeof a.then==`function`)return b(e,r,Ea(a),c);if(a.$$typeof===C)return b(e,r,Ji(e,a),c);Oa(e,a)}return typeof a==`string`&&a!==``||typeof a==`number`||typeof a==`bigint`?(a=``+a,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,a),c.return=e,e=c):(n(e,r),c=si(a,e.mode,c),c.return=e,e=c),o(e)):n(e,r)}return function(e,t,n,r){try{Ta=0;var i=b(e,t,n,r);return wa=null,i}catch(t){if(t===ma||t===ga)throw t;var a=ti(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Aa=ka(!0),ja=ka(!1),Ma=!1;function Na(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Pa(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 Fa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ia(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,X&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=Qr(e),Zr(e,null,n),t}return Jr(e,r,t,n),Qr(e)}function La(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Je(e,n)}}function Ra(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var za=!1;function Ba(){if(za){var e=aa;if(e!==null)throw e}}function Va(e,t,n,r){za=!1;var i=e.updateQueue;Ma=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(Q&f)===f:(r&f)===f){f!==0&&f===ia&&(za=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:Ma=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Ul|=o,e.lanes=o,e.memoizedState=d}}function Ha(e,t){if(typeof e!=`function`)throw Error(s(191,e));e.call(t)}function Ua(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ha(n[e],t)}var Wa=te(null),Ga=te(0);function Ka(e,t){e=Vl,V(Ga,e),V(Wa,t),Vl=e|t.baseLanes}function qa(){V(Ga,Vl),V(Wa,Wa.current)}function Ja(){Vl=Ga.current,B(Wa),B(Ga)}var Ya=te(null),Xa=null;function Za(e){var t=e.alternate;V(no,no.current&1),V(Ya,e),Xa===null&&(t===null||Wa.current!==null||t.memoizedState!==null)&&(Xa=e)}function Qa(e){V(no,no.current),V(Ya,e),Xa===null&&(Xa=e)}function $a(e){e.tag===22?(V(no,no.current),V(Ya,e),Xa===null&&(Xa=e)):eo(e)}function eo(){V(no,no.current),V(Ya,Ya.current)}function to(e){B(Ya),Xa===e&&(Xa=null),B(no)}var no=te(0);function ro(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||af(n)||of(n)))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)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 io=0,J=null,ao=null,oo=null,so=!1,co=!1,lo=!1,uo=0,fo=0,po=null,mo=0;function ho(){throw Error(s(321))}function go(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!hr(e[n],t[n]))return!1;return!0}function _o(e,t,n,r,i,a){return io=a,J=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,I.H=e===null||e.memoizedState===null?Ps:Fs,lo=!1,a=n(r,i),lo=!1,co&&(a=yo(t,n,r,i)),vo(e),a}function vo(e){I.H=Ns;var t=ao!==null&&ao.next!==null;if(io=0,oo=ao=J=null,so=!1,fo=0,po=null,t)throw Error(s(300));e===null||Zs||(e=e.dependencies,e!==null&&Gi(e)&&(Zs=!0))}function yo(e,t,n,r){J=e;var i=0;do{if(co&&(po=null),fo=0,co=!1,25<=i)throw Error(s(301));if(i+=1,oo=ao=null,e.updateQueue!=null){var a=e.updateQueue;a.lastEffect=null,a.events=null,a.stores=null,a.memoCache!=null&&(a.memoCache.index=0)}I.H=Is,a=t(n,r)}while(co);return a}function bo(){var e=I.H,t=e.useState()[0];return t=typeof t.then==`function`?Do(t):t,e=e.useState()[0],(ao===null?null:ao.memoizedState)!==e&&(J.flags|=1024),t}function xo(){var e=uo!==0;return uo=0,e}function So(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Co(e){if(so){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}so=!1}io=0,oo=ao=J=null,co=!1,fo=uo=0,po=null}function wo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return oo===null?J.memoizedState=oo=e:oo=oo.next=e,oo}function To(){if(ao===null){var e=J.alternate;e=e===null?null:e.memoizedState}else e=ao.next;var t=oo===null?J.memoizedState:oo.next;if(t!==null)oo=t,ao=e;else{if(e===null)throw J.alternate===null?Error(s(467)):Error(s(310));ao=e,e={memoizedState:ao.memoizedState,baseState:ao.baseState,baseQueue:ao.baseQueue,queue:ao.queue,next:null},oo===null?J.memoizedState=oo=e:oo=oo.next=e}return oo}function Eo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Do(e){var t=fo;return fo+=1,po===null&&(po=[]),e=ya(po,e,t),t=J,(oo===null?t.memoizedState:oo.next)===null&&(t=t.alternate,I.H=t===null||t.memoizedState===null?Ps:Fs),e}function Oo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Do(e);if(e.$$typeof===C)return qi(e)}throw Error(s(438,String(e)))}function ko(e){var t=null,n=J.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=J.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Eo(),J.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=A;return t.index++,n}function Ao(e,t){return typeof t==`function`?t(e):t}function jo(e){return Mo(To(),ao,e)}function Mo(e,t,n){var r=e.queue;if(r===null)throw Error(s(311));r.lastRenderedReducer=n;var i=e.baseQueue,a=r.pending;if(a!==null){if(i!==null){var o=i.next;i.next=a.next,a.next=o}t.baseQueue=i=a,r.pending=null}if(a=e.baseState,i===null)e.memoizedState=a;else{t=i.next;var c=o=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(io&f)===f:(Q&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ia&&(d=!0);else if((io&p)===p){u=u.next,p===ia&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,o=a):l=l.next=f,J.lanes|=p,Ul|=p;f=u.action,lo&&n(a,f),a=u.hasEagerState?u.eagerState:n(a,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,o=a):l=l.next=p,J.lanes|=f,Ul|=f;u=u.next}while(u!==null&&u!==t);if(l===null?o=a:l.next=c,!hr(a,e.memoizedState)&&(Zs=!0,d&&(n=aa,n!==null)))throw n;e.memoizedState=a,e.baseState=o,e.baseQueue=l,r.lastRenderedState=a}return i===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function No(e){var t=To(),n=t.queue;if(n===null)throw Error(s(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,a=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do a=e(a,o.action),o=o.next;while(o!==i);hr(a,t.memoizedState)||(Zs=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),n.lastRenderedState=a}return[a,r]}function Po(e,t,n){var r=J,i=To(),a=K;if(a){if(n===void 0)throw Error(s(407));n=n()}else n=t();var o=!hr((ao||i).memoizedState,n);if(o&&(i.memoizedState=n,Zs=!0),i=i.queue,as(Lo.bind(null,r,i,e),[e]),i.getSnapshot!==t||o||oo!==null&&oo.memoizedState.tag&1){if(r.flags|=2048,es(9,{destroy:void 0},Io.bind(null,r,i,n,t),null),Fl===null)throw Error(s(349));a||io&127||Fo(r,t,n)}return n}function Fo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=J.updateQueue,t===null?(t=Eo(),J.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Io(e,t,n,r){t.value=n,t.getSnapshot=r,Ro(t)&&zo(e)}function Lo(e,t,n){return n(function(){Ro(t)&&zo(e)})}function Ro(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!hr(e,n)}catch{return!0}}function zo(e){var t=Xr(e,2);t!==null&&pu(t,e,2)}function Bo(e){var t=wo();if(typeof e==`function`){var n=e;if(e=n(),lo){je(!0);try{n()}finally{je(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:e},t}function Vo(e,t,n,r){return e.baseState=n,Mo(e,ao,typeof r==`function`?r:Ao)}function Ho(e,t,n,r,i){if(As(e))throw Error(s(485));if(e=t.action,e!==null){var a={payload:i,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){a.listeners.push(e)}};I.T===null?a.isTransition=!1:n(!0),r(a),n=t.pending,n===null?(a.next=t.pending=a,Uo(t,a)):(a.next=n.next,t.pending=n.next=a)}}function Uo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=I.T,o={};I.T=o;try{var s=n(i,r),c=I.S;c!==null&&c(o,s),Wo(e,t,s)}catch(n){Ko(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),I.T=a}}else try{a=n(i,r),Wo(e,t,a)}catch(n){Ko(e,t,n)}}function Wo(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Go(e,t,n)},function(n){return Ko(e,t,n)}):Go(e,t,n)}function Go(e,t,n){t.status=`fulfilled`,t.value=n,qo(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Uo(e,n)))}function Ko(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,qo(t),t=t.next;while(t!==r)}e.action=null}function qo(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Jo(e,t){return t}function Yo(e,t){if(K){var n=Fl.formState;if(n!==null){a:{var r=J;if(K){if(Di){b:{for(var i=Di,a=ki;i.nodeType!==8;){if(!a){i=null;break b}if(i=cf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Di=cf(i.nextSibling),r=i.data===`F!`;break a}}ji(r)}r=!1}r&&(t=n[0])}}return n=wo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Jo,lastRenderedState:t},n.queue=r,n=Ds.bind(null,J,r),r.dispatch=n,r=Bo(!1),a=ks.bind(null,J,!1,r.queue),r=wo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Ho.bind(null,J,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Xo(e){return Zo(To(),ao,e)}function Zo(e,t,n){if(t=Mo(e,t,Jo)[0],e=jo(Ao)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Do(t)}catch(e){throw e===ma?ga:e}else r=t;t=To();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(J.flags|=2048,es(9,{destroy:void 0},Qo.bind(null,i,n),null)),[r,a,e]}function Qo(e,t){e.action=t}function $o(e){var t=To(),n=ao;if(n!==null)return Zo(t,n,e);To(),t=t.memoizedState,n=To();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function es(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=J.updateQueue,t===null&&(t=Eo(),J.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ts(){return To().memoizedState}function ns(e,t,n,r){var i=wo();J.flags|=e,i.memoizedState=es(1|t,{destroy:void 0},n,r===void 0?null:r)}function rs(e,t,n,r){var i=To();r=r===void 0?null:r;var a=i.memoizedState.inst;ao!==null&&r!==null&&go(r,ao.memoizedState.deps)?i.memoizedState=es(t,a,n,r):(J.flags|=e,i.memoizedState=es(1|t,a,n,r))}function is(e,t){ns(8390656,8,e,t)}function as(e,t){rs(2048,8,e,t)}function os(e){J.flags|=4;var t=J.updateQueue;if(t===null)t=Eo(),J.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ss(e){var t=To().memoizedState;return os({ref:t,nextImpl:e}),function(){if(X&2)throw Error(s(440));return t.impl.apply(void 0,arguments)}}function cs(e,t){return rs(4,2,e,t)}function ls(e,t){return rs(4,4,e,t)}function us(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ds(e,t,n){n=n==null?null:n.concat([e]),rs(4,4,us.bind(null,t,e),n)}function fs(){}function ps(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&go(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function ms(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&go(t,r[1]))return r[0];if(r=e(),lo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r}function hs(e,t,n){return n===void 0||io&1073741824&&!(Q&261930)?e.memoizedState=t:(e.memoizedState=n,e=fu(),J.lanes|=e,Ul|=e,n)}function gs(e,t,n,r){return hr(n,t)?n:Wa.current===null?!(io&42)||io&1073741824&&!(Q&261930)?(Zs=!0,e.memoizedState=n):(e=fu(),J.lanes|=e,Ul|=e,t):(e=hs(e,n,r),hr(e,t)||(Zs=!0),e)}function _s(e,t,n,r,i){var a=L.p;L.p=a!==0&&8>a?a:8;var o=I.T,s={};I.T=s,ks(e,!1,t,n);try{var c=i(),l=I.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Os(e,t,ca(c,r),du(e)):Os(e,t,r,du(e))}catch(n){Os(e,t,{then:function(){},status:`rejected`,reason:n},du())}finally{L.p=a,o!==null&&s.types!==null&&(o.types=s.types),I.T=o}}function vs(){}function ys(e,t,n,r){if(e.tag!==5)throw Error(s(476));var i=bs(e).queue;_s(e,i,t,R,n===null?vs:function(){return xs(e),n(r)})}function bs(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:R,baseState:R,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:R},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function xs(e){var t=bs(e);t.next===null&&(t=e.alternate.memoizedState),Os(e,t.next.queue,{},du())}function Ss(){return qi(Qf)}function Cs(){return To().memoizedState}function ws(){return To().memoizedState}function Ts(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=du();e=Fa(n);var r=Ia(t,e,n);r!==null&&(pu(r,t,n),La(r,t,n)),t={cache:ea()},e.payload=t;return}t=t.return}}function Es(e,t,n){var r=du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},As(e)?js(t,n):(n=Yr(e,t,n,r),n!==null&&(pu(n,e,r),Ms(n,t,r)))}function Ds(e,t,n){Os(e,t,n,du())}function Os(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(As(e))js(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,hr(s,o))return Jr(e,t,i,0),Fl===null&&qr(),!1}catch{}if(n=Yr(e,t,i,r),n!==null)return pu(n,e,r),Ms(n,t,r),!0}return!1}function ks(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},As(e)){if(t)throw Error(s(479))}else t=Yr(e,n,r,2),t!==null&&pu(t,e,2)}function As(e){var t=e.alternate;return e===J||t!==null&&t===J}function js(e,t){co=so=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ms(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Je(e,n)}}var Ns={readContext:qi,use:Oo,useCallback:ho,useContext:ho,useEffect:ho,useImperativeHandle:ho,useLayoutEffect:ho,useInsertionEffect:ho,useMemo:ho,useReducer:ho,useRef:ho,useState:ho,useDebugValue:ho,useDeferredValue:ho,useTransition:ho,useSyncExternalStore:ho,useId:ho,useHostTransitionStatus:ho,useFormState:ho,useActionState:ho,useOptimistic:ho,useMemoCache:ho,useCacheRefresh:ho};Ns.useEffectEvent=ho;var Ps={readContext:qi,use:Oo,useCallback:function(e,t){return wo().memoizedState=[e,t===void 0?null:t],e},useContext:qi,useEffect:is,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ns(4194308,4,us.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ns(4194308,4,e,t)},useInsertionEffect:function(e,t){ns(4,2,e,t)},useMemo:function(e,t){var n=wo();t=t===void 0?null:t;var r=e();if(lo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=wo();if(n!==void 0){var i=n(t);if(lo){je(!0);try{n(t)}finally{je(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Es.bind(null,J,e),[r.memoizedState,e]},useRef:function(e){var t=wo();return e={current:e},t.memoizedState=e},useState:function(e){e=Bo(e);var t=e.queue,n=Ds.bind(null,J,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:fs,useDeferredValue:function(e,t){return hs(wo(),e,t)},useTransition:function(){var e=Bo(!1);return e=_s.bind(null,J,e.queue,!0,!1),wo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=J,i=wo();if(K){if(n===void 0)throw Error(s(407));n=n()}else{if(n=t(),Fl===null)throw Error(s(349));Q&127||Fo(r,t,n)}i.memoizedState=n;var a={value:n,getSnapshot:t};return i.queue=a,is(Lo.bind(null,r,a,e),[e]),r.flags|=2048,es(9,{destroy:void 0},Io.bind(null,r,a,n,t),null),n},useId:function(){var e=wo(),t=Fl.identifierPrefix;if(K){var n=bi,r=yi;n=(r&~(1<<32-Me(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=uo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=mo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Ss,useFormState:Yo,useActionState:Yo,useOptimistic:function(e){var t=wo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=ks.bind(null,J,!0,n),n.dispatch=t,[e,t]},useMemoCache:ko,useCacheRefresh:function(){return wo().memoizedState=Ts.bind(null,J)},useEffectEvent:function(e){var t=wo(),n={impl:e};return t.memoizedState=n,function(){if(X&2)throw Error(s(440));return n.impl.apply(void 0,arguments)}}},Fs={readContext:qi,use:Oo,useCallback:ps,useContext:qi,useEffect:as,useImperativeHandle:ds,useInsertionEffect:cs,useLayoutEffect:ls,useMemo:ms,useReducer:jo,useRef:ts,useState:function(){return jo(Ao)},useDebugValue:fs,useDeferredValue:function(e,t){return gs(To(),ao.memoizedState,e,t)},useTransition:function(){var e=jo(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Cs,useHostTransitionStatus:Ss,useFormState:Xo,useActionState:Xo,useOptimistic:function(e,t){return Vo(To(),ao,e,t)},useMemoCache:ko,useCacheRefresh:ws};Fs.useEffectEvent=ss;var Is={readContext:qi,use:Oo,useCallback:ps,useContext:qi,useEffect:as,useImperativeHandle:ds,useInsertionEffect:cs,useLayoutEffect:ls,useMemo:ms,useReducer:No,useRef:ts,useState:function(){return No(Ao)},useDebugValue:fs,useDeferredValue:function(e,t){var n=To();return ao===null?hs(n,e,t):gs(n,ao.memoizedState,e,t)},useTransition:function(){var e=No(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Cs,useHostTransitionStatus:Ss,useFormState:$o,useActionState:$o,useOptimistic:function(e,t){var n=To();return ao===null?(n.baseState=e,[e,n.queue.dispatch]):Vo(n,ao,e,t)},useMemoCache:ko,useCacheRefresh:ws};Is.useEffectEvent=ss;function Ls(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Rs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=du(),i=Fa(r);i.payload=t,n!=null&&(i.callback=n),t=Ia(e,i,r),t!==null&&(pu(t,e,r),La(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=du(),i=Fa(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ia(e,i,r),t!==null&&(pu(t,e,r),La(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=du(),r=Fa(n);r.tag=2,t!=null&&(r.callback=t),t=Ia(e,r,n),t!==null&&(pu(t,e,n),La(t,e,n))}};function zs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!gr(n,r)||!gr(i,a):!0}function Bs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Rs.enqueueReplaceState(t,t.state,null)}function Vs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Hs(e){Ur(e)}function Us(e){console.error(e)}function Ws(e){Ur(e)}function Gs(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Y(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ks(e,t,n){return n=Fa(n),n.tag=3,n.payload={element:null},n.callback=function(){Gs(e,t)},n}function qs(e){return e=Fa(e),e.tag=3,e}function Js(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Y(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Y(t,n,r),typeof i!=`function`&&(tu===null?tu=new Set([this]):tu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Ys(e,t,n,r,i){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Wi(t,n,i,!0),n=Ya.current,n!==null){switch(n.tag){case 31:case 13:return Xa===null?Tu():n.alternate===null&&Hl===0&&(Hl=3),n.flags&=-257,n.flags|=65536,n.lanes=i,r===_a?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Wu(e,r,i)),!1;case 22:return n.flags|=65536,r===_a?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Wu(e,r,i)),!1}throw Error(s(435,n.tag))}return Wu(e,r,i),Tu(),!1}if(K)return t=Ya.current,t===null?(r!==Ai&&(t=Error(s(423),{cause:r}),Li(di(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,r=di(r,n),i=Ks(e.stateNode,r,i),Ra(e,i),Hl!==4&&(Hl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=i,r!==Ai&&(e=Error(s(422),{cause:r}),Li(di(e,n)))),!1;var a=Error(s(520),{cause:r});if(a=di(a,n),Jl===null?Jl=[a]:Jl.push(a),Hl!==4&&(Hl=2),t===null)return!0;r=di(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=Ks(n.stateNode,r,e),Ra(n,e),!1;case 1:if(t=n.type,a=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||a!==null&&typeof a.componentDidCatch==`function`&&(tu===null||!tu.has(a))))return n.flags|=65536,i&=-i,n.lanes|=i,i=qs(i),Js(i,e,n,r),Ra(n,i),!1}n=n.return}while(n!==null);return!1}var Xs=Error(s(461)),Zs=!1;function Qs(e,t,n,r){t.child=e===null?ja(t,null,n,r):Aa(t,e.child,n,r)}function $s(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Ki(t),r=_o(e,t,n,o,a,i),s=xo(),e!==null&&!Zs?(So(e,t,i),Cc(e,t,i)):(K&&s&&Ci(t),t.flags|=1,Qs(e,t,r,i),t.child)}function ec(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!ni(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,tc(e,t,a,r,i)):(e=ai(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!wc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?gr:n,n(o,r)&&e.ref===t.ref)return Cc(e,t,i)}return t.flags|=1,e=ri(a,r),e.ref=t.ref,e.return=t,t.child=e}function tc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(gr(a,r)&&e.ref===t.ref)if(Zs=!1,t.pendingProps=r=a,wc(e,i))e.flags&131072&&(Zs=!0);else return t.lanes=e.lanes,Cc(e,t,i)}return lc(e,t,n,r,i)}function nc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return ic(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&fa(t,a===null?null:a.cachePool),a===null?qa():Ka(t,a),$a(t);else return r=t.lanes=536870912,ic(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&fa(t,null),qa(),eo(t)):(fa(t,a.cachePool),Ka(t,a),eo(t),t.memoizedState=null);return Qs(e,t,i,n),t.child}function rc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function ic(e,t,n,r,i){var a=da();return a=a===null?null:{parent:$i._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&fa(t,null),qa(),$a(t),e!==null&&Wi(e,t,r,!0),t.childLanes=i,null}function ac(e,t){return t=vc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function oc(e,t,n){return Aa(t,e.child,null,n),e=ac(t,t.pendingProps),e.flags|=2,to(t),t.memoizedState=null,e}function sc(e,t,n){var r=t.pendingProps,i=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(K){if(r.mode===`hidden`)return e=ac(t,r),t.lanes=536870912,rc(null,e);if(Qa(t),(e=Di)?(e=rf(e,ki),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vi===null?null:{id:yi,overflow:bi},retryLane:536870912,hydrationErrors:null},n=ci(e),n.return=t,t.child=n,Ei=t,Di=null)):e=null,e===null)throw ji(t);return t.lanes=536870912,null}return ac(t,r)}var a=e.memoizedState;if(a!==null){var o=a.dehydrated;if(Qa(t),i)if(t.flags&256)t.flags&=-257,t=oc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(s(558));else if(Zs||Wi(e,t,n,!1),i=(n&e.childLanes)!==0,Zs||i){if(r=Fl,r!==null&&(o=Ye(r,n),o!==0&&o!==a.retryLane))throw a.retryLane=o,Xr(e,o),pu(r,e,o),Xs;Tu(),t=oc(e,t,n)}else e=a.treeContext,Di=cf(o.nextSibling),Ei=t,K=!0,Oi=null,ki=!1,e!==null&&Ti(t,e),t=ac(t,r),t.flags|=4096;return t}return e=ri(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function cc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(s(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function lc(e,t,n,r,i){return Ki(t),n=_o(e,t,n,r,void 0,i),r=xo(),e!==null&&!Zs?(So(e,t,i),Cc(e,t,i)):(K&&r&&Ci(t),t.flags|=1,Qs(e,t,n,i),t.child)}function uc(e,t,n,r,i,a){return Ki(t),t.updateQueue=null,n=yo(t,r,n,i),vo(e),r=xo(),e!==null&&!Zs?(So(e,t,a),Cc(e,t,a)):(K&&r&&Ci(t),t.flags|=1,Qs(e,t,n,a),t.child)}function dc(e,t,n,r,i){if(Ki(t),t.stateNode===null){var a=$r,o=n.contextType;typeof o==`object`&&o&&(a=qi(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Rs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Na(t),o=n.contextType,a.context=typeof o==`object`&&o?qi(o):$r,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ls(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Rs.enqueueReplaceState(a,a.state,null),Va(t,r,a,i),Ba(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Vs(n,s);a.props=c;var l=a.context,u=n.contextType;o=$r,typeof u==`object`&&u&&(o=qi(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Bs(t,a,r,o),Ma=!1;var f=t.memoizedState;a.state=f,Va(t,r,a,i),Ba(),l=t.memoizedState,s||f!==l||Ma?(typeof d==`function`&&(Ls(t,n,d,r),l=t.memoizedState),(c=Ma||zs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Pa(e,t),o=t.memoizedProps,u=Vs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=$r,typeof l==`object`&&l&&(c=qi(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Bs(t,a,r,c),Ma=!1,f=t.memoizedState,a.state=f,Va(t,r,a,i),Ba();var p=t.memoizedState;o!==d||f!==p||Ma||e!==null&&e.dependencies!==null&&Gi(e.dependencies)?(typeof s==`function`&&(Ls(t,n,s,r),p=t.memoizedState),(u=Ma||zs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Gi(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,cc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Aa(t,e.child,null,i),t.child=Aa(t,null,n,i)):Qs(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Cc(e,t,i),e}function fc(e,t,n,r){return Fi(),t.flags|=256,Qs(e,t,n,r),t.child}var pc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function mc(e){return{baseLanes:e,cachePool:pa()}}function hc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Kl),e}function gc(e,t,n){var r=t.pendingProps,i=!1,a=(t.flags&128)!=0,o;if((o=a)||(o=e!==null&&e.memoizedState===null?!1:(no.current&2)!=0),o&&(i=!0,t.flags&=-129),o=(t.flags&32)!=0,t.flags&=-33,e===null){if(K){if(i?Za(t):eo(t),(e=Di)?(e=rf(e,ki),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vi===null?null:{id:yi,overflow:bi},retryLane:536870912,hydrationErrors:null},n=ci(e),n.return=t,t.child=n,Ei=t,Di=null)):e=null,e===null)throw ji(t);return of(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,i?(eo(t),i=t.mode,c=vc({mode:`hidden`,children:c},i),r=oi(r,i,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=mc(n),r.childLanes=hc(e,o,n),t.memoizedState=pc,rc(null,r)):(Za(t),_c(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(a)t.flags&256?(Za(t),t.flags&=-257,t=yc(e,t,n)):t.memoizedState===null?(eo(t),c=r.fallback,i=t.mode,r=vc({mode:`visible`,children:r.children},i),c=oi(c,i,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Aa(t,e.child,null,n),r=t.child,r.memoizedState=mc(n),r.childLanes=hc(e,o,n),t.memoizedState=pc,t=rc(null,r)):(eo(t),t.child=e.child,t.flags|=128,t=null);else if(Za(t),of(c)){if(o=c.nextSibling&&c.nextSibling.dataset,o)var u=o.dgst;o=u,r=Error(s(419)),r.stack=``,r.digest=o,Li({value:r,source:null,stack:null}),t=yc(e,t,n)}else if(Zs||Wi(e,t,n,!1),o=(n&e.childLanes)!==0,Zs||o){if(o=Fl,o!==null&&(r=Ye(o,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Xr(e,r),pu(o,e,r),Xs;af(c)||Tu(),t=yc(e,t,n)}else af(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Di=cf(c.nextSibling),Ei=t,K=!0,Oi=null,ki=!1,e!==null&&Ti(t,e),t=_c(t,r.children),t.flags|=4096);return t}return i?(eo(t),c=r.fallback,i=t.mode,l=e.child,u=l.sibling,r=ri(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=oi(c,i,n,null),c.flags|=2):c=ri(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,rc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=mc(n):(i=c.cachePool,i===null?i=pa():(l=$i._currentValue,i=i.parent===l?i:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:i}),r.memoizedState=c,r.childLanes=hc(e,o,n),t.memoizedState=pc,rc(e.child,r)):(Za(t),n=e.child,e=n.sibling,n=ri(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=n,t.memoizedState=null,n)}function _c(e,t){return t=vc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function vc(e,t){return e=ti(22,e,null,t),e.lanes=0,e}function yc(e,t,n){return Aa(t,e.child,null,n),e=_c(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function bc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Hi(e.return,t,n)}function xc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Sc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=no.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,V(no,o),Qs(e,t,r,n),r=K?hi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&bc(e,n,t);else if(e.tag===19)bc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&ro(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),xc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&ro(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}xc(t,!0,n,null,a,r);break;case`together`:xc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Cc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Ul|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Wi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(s(153));if(t.child!==null){for(e=t.child,n=ri(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ri(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function wc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Gi(e))):!0}function Tc(e,t,n){switch(t.tag){case 3:ae(t,t.stateNode.containerInfo),Bi(t,$i,e.memoizedState.cache),Fi();break;case 27:case 5:se(t);break;case 4:ae(t,t.stateNode.containerInfo);break;case 10:Bi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Qa(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(Za(t),e=Cc(e,t,n),e===null?null:e.sibling):gc(e,t,n):(Za(t),t.flags|=128,null);Za(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(Wi(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Sc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),V(no,no.current),r)break;return null;case 22:return t.lanes=0,nc(e,t,n,t.pendingProps);case 24:Bi(t,$i,e.memoizedState.cache)}return Cc(e,t,n)}function Ec(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)Zs=!0;else{if(!wc(e,n)&&!(t.flags&128))return Zs=!1,Tc(e,t,n);Zs=!!(e.flags&131072)}else Zs=!1,K&&t.flags&1048576&&Si(t,hi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=ba(t.elementType),t.type=e,typeof e==`function`)ni(e)?(r=Vs(e,r),t.tag=1,t=dc(null,t,e,r,n)):(t.tag=0,t=lc(null,t,e,r,n));else{if(e!=null){var i=e.$$typeof;if(i===w){t.tag=11,t=$s(null,t,e,r,n);break a}else if(i===D){t.tag=14,t=ec(null,t,e,r,n);break a}}throw t=P(e)||e,Error(s(306,t,``))}}return t;case 0:return lc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,i=Vs(r,t.pendingProps),dc(e,t,r,i,n);case 3:a:{if(ae(t,t.stateNode.containerInfo),e===null)throw Error(s(387));r=t.pendingProps;var a=t.memoizedState;i=a.element,Pa(e,t),Va(t,r,null,n);var o=t.memoizedState;if(r=o.cache,Bi(t,$i,r),r!==a.cache&&Ui(t,[$i],n,!0),Ba(),r=o.element,a.isDehydrated)if(a={element:r,isDehydrated:!1,cache:o.cache},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){t=fc(e,t,r,n);break a}else if(r!==i){i=di(Error(s(424)),t),Li(i),t=fc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Di=cf(e.firstChild),Ei=t,K=!0,Oi=null,ki=!0,n=ja(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Fi(),r===i){t=Cc(e,t,n);break a}Qs(e,t,r,n)}t=t.child}return t;case 26:return cc(e,t),e===null?(n=kf(t.type,null,t.pendingProps,null))?t.memoizedState=n:K||(n=t.type,e=t.pendingProps,r=Bd(re.current).createElement(n),r[tt]=t,r[nt]=e,Pd(r,n,e),mt(r),t.stateNode=r):t.memoizedState=kf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return se(t),e===null&&K&&(r=t.stateNode=ff(t.type,t.pendingProps,re.current),Ei=t,ki=!0,i=Di,Zd(t.type)?(lf=i,Di=cf(r.firstChild)):Di=i),Qs(e,t,t.pendingProps.children,n),cc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&K&&((i=r=Di)&&(r=tf(r,t.type,t.pendingProps,ki),r===null?i=!1:(t.stateNode=r,Ei=t,Di=cf(r.firstChild),ki=!1,i=!0)),i||ji(t)),se(t),i=t.type,a=t.pendingProps,o=e===null?null:e.memoizedProps,r=a.children,Ud(i,a)?r=null:o!==null&&Ud(i,o)&&(t.flags|=32),t.memoizedState!==null&&(i=_o(e,t,bo,null,null,n),Qf._currentValue=i),cc(e,t),Qs(e,t,r,n),t.child;case 6:return e===null&&K&&((e=n=Di)&&(n=nf(n,t.pendingProps,ki),n===null?e=!1:(t.stateNode=n,Ei=t,Di=null,e=!0)),e||ji(t)),null;case 13:return gc(e,t,n);case 4:return ae(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Aa(t,null,r,n):Qs(e,t,r,n),t.child;case 11:return $s(e,t,t.type,t.pendingProps,n);case 7:return Qs(e,t,t.pendingProps,n),t.child;case 8:return Qs(e,t,t.pendingProps.children,n),t.child;case 12:return Qs(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Bi(t,t.type,r.value),Qs(e,t,r.children,n),t.child;case 9:return i=t.type._context,r=t.pendingProps.children,Ki(t),i=qi(i),r=r(i),t.flags|=1,Qs(e,t,r,n),t.child;case 14:return ec(e,t,t.type,t.pendingProps,n);case 15:return tc(e,t,t.type,t.pendingProps,n);case 19:return Sc(e,t,n);case 31:return sc(e,t,n);case 22:return nc(e,t,n,t.pendingProps);case 24:return Ki(t),r=qi($i),e===null?(i=da(),i===null&&(i=Fl,a=ea(),i.pooledCache=a,a.refCount++,a!==null&&(i.pooledCacheLanes|=n),i=a),t.memoizedState={parent:r,cache:i},Na(t),Bi(t,$i,i)):((e.lanes&n)!==0&&(Pa(e,t),Va(t,null,null,n),Ba()),i=e.memoizedState,a=t.memoizedState,i.parent===r?(r=a.cache,Bi(t,$i,r),r!==i.cache&&Ui(t,[$i],n,!0)):(i={parent:r,cache:r},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),Bi(t,$i,r))),Qs(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(s(156,t.tag))}function Dc(e){e.flags|=4}function Oc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Su())e.flags|=8192;else throw xa=_a,ha}else e.flags&=-16777217}function kc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Wf(t))if(Su())e.flags|=8192;else throw xa=_a,ha}function Ac(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ue(),e.lanes|=t,ql|=t)}function jc(e,t){if(!K)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Mc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Nc(e,t,n){var r=t.pendingProps;switch(wi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Mc(t),null;case 1:return Mc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Vi($i),oe(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Pi(t)?Dc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ii())),Mc(t),null;case 26:var i=t.type,a=t.memoizedState;return e===null?(Dc(t),a===null?(Mc(t),Oc(t,i,null,r,n)):(Mc(t),kc(t,a))):a?a===e.memoizedState?(Mc(t),t.flags&=-16777217):(Dc(t),Mc(t),kc(t,a)):(e=e.memoizedProps,e!==r&&Dc(t),Mc(t),Oc(t,i,e,r,n)),null;case 27:if(ce(t),n=re.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(!r){if(t.stateNode===null)throw Error(s(166));return Mc(t),null}e=H.current,Pi(t)?Mi(t,e):(e=ff(i,r,n),t.stateNode=e,Dc(t))}return Mc(t),null;case 5:if(ce(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(!r){if(t.stateNode===null)throw Error(s(166));return Mc(t),null}if(a=H.current,Pi(t))Mi(t,a);else{var o=Bd(re.current);switch(a){case 1:a=o.createElementNS(`http://www.w3.org/2000/svg`,i);break;case 2:a=o.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;default:switch(i){case`svg`:a=o.createElementNS(`http://www.w3.org/2000/svg`,i);break;case`math`:a=o.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;case`script`:a=o.createElement(`div`),a.innerHTML=`<script><\/script>`,a=a.removeChild(a.firstChild);break;case`select`:a=typeof r.is==`string`?o.createElement(`select`,{is:r.is}):o.createElement(`select`),r.multiple?a.multiple=!0:r.size&&(a.size=r.size);break;default:a=typeof r.is==`string`?o.createElement(i,{is:r.is}):o.createElement(i)}}a[tt]=t,a[nt]=r;a:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)a.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break a;for(;o.sibling===null;){if(o.return===null||o.return===t)break a;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=a;a:switch(Pd(a,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Dc(t)}}return Mc(t),Oc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(s(166));if(e=re.current,Pi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=Ei,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[tt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||ji(t,!0)}else e=Bd(e).createTextNode(r),e[tt]=t,t.stateNode=e}return Mc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Pi(t),n!==null){if(e===null){if(!r)throw Error(s(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(557));e[tt]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Mc(t),e=!1}else n=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(to(t),t):(to(t),null);if(t.flags&128)throw Error(s(558))}return Mc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Pi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(s(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(s(317));i[tt]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Mc(t),i=!1}else i=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(to(t),t):(to(t),null)}return to(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),a=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(a=r.memoizedState.cachePool.pool),a!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Ac(t,t.updateQueue),Mc(t),null);case 4:return oe(),e===null&&xd(t.stateNode.containerInfo),Mc(t),null;case 10:return Vi(t.type),Mc(t),null;case 19:if(B(no),r=t.memoizedState,r===null)return Mc(t),null;if(i=(t.flags&128)!=0,a=r.rendering,a===null)if(i)jc(r,!1);else{if(Hl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(a=ro(e),a!==null){for(t.flags|=128,jc(r,!1),e=a.updateQueue,t.updateQueue=e,Ac(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ii(n,e),n=n.sibling;return V(no,no.current&1|2),K&&xi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&xe()>$l&&(t.flags|=128,i=!0,jc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ro(a),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Ac(t,e),jc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!a.alternate&&!K)return Mc(t),null}else 2*xe()-r.renderingStartTime>$l&&n!==536870912&&(t.flags|=128,i=!0,jc(r,!1),t.lanes=4194304);r.isBackwards?(a.sibling=t.child,t.child=a):(e=r.last,e===null?t.child=a:e.sibling=a,r.last=a)}return r.tail===null?(Mc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=xe(),e.sibling=null,n=no.current,V(no,i?n&1|2:n&1),K&&xi(t,r.treeForkCount),e);case 22:case 23:return to(t),Ja(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Mc(t),t.subtreeFlags&6&&(t.flags|=8192)):Mc(t),n=t.updateQueue,n!==null&&Ac(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&B(ua),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Vi($i),Mc(t),null;case 25:return null;case 30:return null}throw Error(s(156,t.tag))}function Pc(e,t){switch(wi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vi($i),oe(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ce(t),null;case 31:if(t.memoizedState!==null){if(to(t),t.alternate===null)throw Error(s(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(to(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(s(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return B(no),null;case 4:return oe(),null;case 10:return Vi(t.type),null;case 22:case 23:return to(t),Ja(),e!==null&&B(ua),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Vi($i),null;case 25:return null;default:return null}}function Fc(e,t){switch(wi(t),t.tag){case 3:Vi($i),oe();break;case 26:case 27:case 5:ce(t);break;case 4:oe();break;case 31:t.memoizedState!==null&&to(t);break;case 13:to(t);break;case 19:B(no);break;case 10:Vi(t.type);break;case 22:case 23:to(t),Ja(),e!==null&&B(ua);break;case 24:Vi($i)}}function Ic(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Uu(t,t.return,e)}}function Lc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Uu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Uu(t,t.return,e)}}function Rc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ua(t,n)}catch(t){Uu(e,e.return,t)}}}function zc(e,t,n){n.props=Vs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Uu(e,t,n)}}function Bc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Uu(e,t,n)}}function Vc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Uu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Uu(e,t,n)}else n.current=null}function Hc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Uu(e,e.return,t)}}function Uc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[nt]=t}catch(t){Uu(e,e.return,t)}}function Wc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Gc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Wc(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&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Kc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Jt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Kc(e,t,n),e=e.sibling;e!==null;)Kc(e,t,n),e=e.sibling}function qc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(qc(e,t,n),e=e.sibling;e!==null;)qc(e,t,n),e=e.sibling}function Jc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[tt]=e,t[nt]=n}catch(t){Uu(e,e.return,t)}}var Yc=!1,Xc=!1,Zc=!1,Qc=typeof WeakSet==`function`?WeakSet:Set,$c=null;function el(e,t){if(e=e.containerInfo,Rd=sp,e=br(e),xr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,a=r.focusNode;r=r.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break a}var o=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=o+i),f!==a||r!==0&&f.nodeType!==3||(l=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=o),p===a&&++d===r&&(l=o),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,$c=t;$c!==null;)if(t=$c,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,$c=e;else for(;$c!==null;){switch(t=$c,a=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&a!==null){e=void 0,n=t,i=a.memoizedProps,a=a.memoizedState,r=n.stateNode;try{var h=Vs(n.type,i);e=r.getSnapshotBeforeUpdate(h,a),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Uu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ef(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ef(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(s(163))}if(e=t.sibling,e!==null){e.return=t.return,$c=e;break}$c=t.return}}function tl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:gl(e,n),r&4&&Ic(5,n);break;case 1:if(gl(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Uu(n,n.return,e)}else{var i=Vs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Uu(n,n.return,e)}}r&64&&Rc(n),r&512&&Bc(n,n.return);break;case 3:if(gl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Ua(e,t)}catch(e){Uu(n,n.return,e)}}break;case 27:t===null&&r&4&&Jc(n);case 26:case 5:gl(e,n),t===null&&r&4&&Hc(n),r&512&&Bc(n,n.return);break;case 12:gl(e,n);break;case 31:gl(e,n),r&4&&sl(e,n);break;case 13:gl(e,n),r&4&&cl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=qu.bind(null,n),sf(e,n))));break;case 22:if(r=n.memoizedState!==null||Yc,!r){t=t!==null&&t.memoizedState!==null||Xc,i=Yc;var a=Xc;Yc=r,(Xc=t)&&!a?vl(e,n,(n.subtreeFlags&8772)!=0):gl(e,n),Yc=i,Xc=a}break;case 30:break;default:gl(e,n)}}function nl(e){var t=e.alternate;t!==null&&(e.alternate=null,nl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&lt(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 rl=null,il=!1;function al(e,t,n){for(n=n.child;n!==null;)ol(e,t,n),n=n.sibling}function ol(e,t,n){if(Ae&&typeof Ae.onCommitFiberUnmount==`function`)try{Ae.onCommitFiberUnmount(ke,n)}catch{}switch(n.tag){case 26:Xc||Vc(n,t),al(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:Xc||Vc(n,t);var r=rl,i=il;Zd(n.type)&&(rl=n.stateNode,il=!1),al(e,t,n),pf(n.stateNode),rl=r,il=i;break;case 5:Xc||Vc(n,t);case 6:if(r=rl,i=il,rl=null,al(e,t,n),rl=r,il=i,rl!==null)if(il)try{(rl.nodeType===9?rl.body:rl.nodeName===`HTML`?rl.ownerDocument.body:rl).removeChild(n.stateNode)}catch(e){Uu(n,t,e)}else try{rl.removeChild(n.stateNode)}catch(e){Uu(n,t,e)}break;case 18:rl!==null&&(il?(e=rl,Qd(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Np(e)):Qd(rl,n.stateNode));break;case 4:r=rl,i=il,rl=n.stateNode.containerInfo,il=!0,al(e,t,n),rl=r,il=i;break;case 0:case 11:case 14:case 15:Lc(2,n,t),Xc||Lc(4,n,t),al(e,t,n);break;case 1:Xc||(Vc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&zc(n,t,r)),al(e,t,n);break;case 21:al(e,t,n);break;case 22:Xc=(r=Xc)||n.memoizedState!==null,al(e,t,n),Xc=r;break;default:al(e,t,n)}}function sl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Np(e)}catch(e){Uu(t,t.return,e)}}}function cl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Np(e)}catch(e){Uu(t,t.return,e)}}function ll(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Qc),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Qc),t;default:throw Error(s(435,e.tag))}}function ul(e,t){var n=ll(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ju.bind(null,e,t);t.then(r,r)}})}function dl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r],a=e,o=t,c=o;a:for(;c!==null;){switch(c.tag){case 27:if(Zd(c.type)){rl=c.stateNode,il=!1;break a}break;case 5:rl=c.stateNode,il=!1;break a;case 3:case 4:rl=c.stateNode.containerInfo,il=!0;break a}c=c.return}if(rl===null)throw Error(s(160));ol(a,o,i),rl=null,il=!1,a=i.alternate,a!==null&&(a.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)pl(t,e),t=t.sibling}var fl=null;function pl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:dl(t,e),ml(e),r&4&&(Lc(3,e,e.return),Ic(3,e),Lc(5,e,e.return));break;case 1:dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),r&64&&Yc&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var i=fl;if(dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),r&4){var a=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,i=i.ownerDocument||i;b:switch(r){case`title`:a=i.getElementsByTagName(`title`)[0],(!a||a[ct]||a[tt]||a.namespaceURI===`http://www.w3.org/2000/svg`||a.hasAttribute(`itemprop`))&&(a=i.createElement(r),i.head.insertBefore(a,i.querySelector(`head > title`))),Pd(a,r,n),a[tt]=e,mt(a),r=a;break a;case`link`:var o=Vf(`link`,`href`,i).get(r+(n.href||``));if(o){for(var c=0;c<o.length;c++)if(a=o[c],a.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&a.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&a.getAttribute(`title`)===(n.title==null?null:n.title)&&a.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){o.splice(c,1);break b}}a=i.createElement(r),Pd(a,r,n),i.head.appendChild(a);break;case`meta`:if(o=Vf(`meta`,`content`,i).get(r+(n.content||``))){for(c=0;c<o.length;c++)if(a=o[c],a.getAttribute(`content`)===(n.content==null?null:``+n.content)&&a.getAttribute(`name`)===(n.name==null?null:n.name)&&a.getAttribute(`property`)===(n.property==null?null:n.property)&&a.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&a.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){o.splice(c,1);break b}}a=i.createElement(r),Pd(a,r,n),i.head.appendChild(a);break;default:throw Error(s(468,r))}a[tt]=e,mt(a),r=a}e.stateNode=r}else Hf(i,e.type,e.stateNode);else e.stateNode=If(i,r,e.memoizedProps);else a===r?r===null&&e.stateNode!==null&&Uc(e,e.memoizedProps,n.memoizedProps):(a===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):a.count--,r===null?Hf(i,e.type,e.stateNode):If(i,r,e.memoizedProps))}break;case 27:dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),n!==null&&r&4&&Uc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),e.flags&32){i=e.stateNode;try{Bt(i,``)}catch(t){Uu(e,e.return,t)}}r&4&&e.stateNode!=null&&(i=e.memoizedProps,Uc(e,i,n===null?i:n.memoizedProps)),r&1024&&(Zc=!0);break;case 6:if(dl(t,e),ml(e),r&4){if(e.stateNode===null)throw Error(s(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Uu(e,e.return,t)}}break;case 3:if(Bf=null,i=fl,fl=gf(t.containerInfo),dl(t,e),fl=i,ml(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Np(t.containerInfo)}catch(t){Uu(e,e.return,t)}Zc&&(Zc=!1,hl(e));break;case 4:r=fl,fl=gf(e.stateNode.containerInfo),dl(t,e),ml(e),fl=r;break;case 12:dl(t,e),ml(e);break;case 31:dl(t,e),ml(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 13:dl(t,e),ml(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Zl=xe()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 22:i=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=Yc,d=Xc;if(Yc=u||i,Xc=d||l,dl(t,e),Xc=d,Yc=u,ml(e),r&8192)a:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||l||Yc||Xc||_l(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(a=l.stateNode,i)o=a.style,typeof o.setProperty==`function`?o.setProperty(`display`,`none`,`important`):o.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Uu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=i?``:l.memoizedProps}catch(e){Uu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;i?$d(m,!0):$d(l.stateNode,!1)}catch(e){Uu(l,l.return,e)}}}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 a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,ul(e,n))));break;case 19:dl(t,e),ml(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 30:break;case 21:break;default:dl(t,e),ml(e)}}function ml(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Wc(r)){n=r;break}r=r.return}if(n==null)throw Error(s(160));switch(n.tag){case 27:var i=n.stateNode;qc(e,Gc(e),i);break;case 5:var a=n.stateNode;n.flags&32&&(Bt(a,``),n.flags&=-33),qc(e,Gc(e),a);break;case 3:case 4:var o=n.stateNode.containerInfo;Kc(e,Gc(e),o);break;default:throw Error(s(161))}}catch(t){Uu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function hl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;hl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function gl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)tl(e,t.alternate,t),t=t.sibling}function _l(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Lc(4,t,t.return),_l(t);break;case 1:Vc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&zc(t,t.return,n),_l(t);break;case 27:pf(t.stateNode);case 26:case 5:Vc(t,t.return),_l(t);break;case 22:t.memoizedState===null&&_l(t);break;case 30:_l(t);break;default:_l(t)}e=e.sibling}}function vl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:vl(i,a,n),Ic(4,a);break;case 1:if(vl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Uu(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ha(c[i],s)}catch(e){Uu(r,r.return,e)}}n&&o&64&&Rc(a),Bc(a,a.return);break;case 27:Jc(a);case 26:case 5:vl(i,a,n),n&&r===null&&o&4&&Hc(a),Bc(a,a.return);break;case 12:vl(i,a,n);break;case 31:vl(i,a,n),n&&o&4&&sl(i,a);break;case 13:vl(i,a,n),n&&o&4&&cl(i,a);break;case 22:a.memoizedState===null&&vl(i,a,n),Bc(a,a.return);break;case 30:break;default:vl(i,a,n)}t=t.sibling}}function yl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&ta(n))}function bl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ta(e))}function xl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Sl(e,t,n,r),t=t.sibling}function Sl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:xl(e,t,n,r),i&2048&&Ic(9,t);break;case 1:xl(e,t,n,r);break;case 3:xl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ta(e)));break;case 12:if(i&2048){xl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Uu(t,t.return,e)}}else xl(e,t,n,r);break;case 31:xl(e,t,n,r);break;case 13:xl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?xl(e,t,n,r):(a._visibility|=2,Cl(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?xl(e,t,n,r):wl(e,t),i&2048&&yl(o,t);break;case 24:xl(e,t,n,r),i&2048&&bl(t.alternate,t);break;default:xl(e,t,n,r)}}function Cl(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Cl(a,o,s,c,i),Ic(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Cl(a,o,s,c,i)):u._visibility&2?Cl(a,o,s,c,i):wl(a,o),i&&l&2048&&yl(o.alternate,o);break;case 24:Cl(a,o,s,c,i),i&&l&2048&&bl(o.alternate,o);break;default:Cl(a,o,s,c,i)}t=t.sibling}}function wl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:wl(n,r),i&2048&&yl(r.alternate,r);break;case 24:wl(n,r),i&2048&&bl(r.alternate,r);break;default:wl(n,r)}t=t.sibling}}var Tl=8192;function El(e,t,n){if(e.subtreeFlags&Tl)for(e=e.child;e!==null;)Dl(e,t,n),e=e.sibling}function Dl(e,t,n){switch(e.tag){case 26:El(e,t,n),e.flags&Tl&&e.memoizedState!==null&&Gf(n,fl,e.memoizedState,e.memoizedProps);break;case 5:El(e,t,n);break;case 3:case 4:var r=fl;fl=gf(e.stateNode.containerInfo),El(e,t,n),fl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Tl,Tl=16777216,El(e,t,n),Tl=r):El(e,t,n));break;default:El(e,t,n)}}function Ol(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 kl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];$c=r,Ml(r,e)}Ol(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Al(e),e=e.sibling}function Al(e){switch(e.tag){case 0:case 11:case 15:kl(e),e.flags&2048&&Lc(9,e,e.return);break;case 3:kl(e);break;case 12:kl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,jl(e)):kl(e);break;default:kl(e)}}function jl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];$c=r,Ml(r,e)}Ol(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Lc(8,t,t.return),jl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,jl(t));break;default:jl(t)}e=e.sibling}}function Ml(e,t){for(;$c!==null;){var n=$c;switch(n.tag){case 0:case 11:case 15:Lc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:ta(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,$c=r;else a:for(n=e;$c!==null;){r=$c;var i=r.sibling,a=r.return;if(nl(r),r===n){$c=null;break a}if(i!==null){i.return=a,$c=i;break a}$c=a}}}var Nl={getCacheForType:function(e){var t=qi($i),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return qi($i).controller.signal}},Pl=typeof WeakMap==`function`?WeakMap:Map,X=0,Fl=null,Z=null,Q=0,Il=0,Ll=null,Rl=!1,zl=!1,Bl=!1,Vl=0,Hl=0,Ul=0,Wl=0,Gl=0,Kl=0,ql=0,Jl=null,Yl=null,Xl=!1,Zl=0,Ql=0,$l=1/0,eu=null,tu=null,nu=0,ru=null,iu=null,au=0,ou=0,su=null,cu=null,lu=0,uu=null;function du(){return X&2&&Q!==0?Q&-Q:I.T===null?Qe():ud()}function fu(){if(Kl===0)if(!(Q&536870912)||K){var e=Le;Le<<=1,!(Le&3932160)&&(Le=262144),Kl=e}else Kl=536870912;return e=Ya.current,e!==null&&(e.flags|=32),Kl}function pu(e,t,n){(e===Fl&&(Il===2||Il===9)||e.cancelPendingCommit!==null)&&(bu(e,0),_u(e,Q,Kl,!1)),Ge(e,n),(!(X&2)||e!==Fl)&&(e===Fl&&(!(X&2)&&(Wl|=n),Hl===4&&_u(e,Q,Kl,!1)),nd(e))}function mu(e,t,n){if(X&6)throw Error(s(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Ve(e,t),i=r?Ou(e,t):Eu(e,t,!0),a=r;do{if(i===0){zl&&!r&&_u(e,t,0,!1);break}else{if(n=e.current.alternate,a&&!gu(n)){i=Eu(e,t,!1),a=!1;continue}if(i===2){if(a=t,e.errorRecoveryDisabledLanes&a)var o=0;else o=e.pendingLanes&-536870913,o=o===0?o&536870912?536870912:0:o;if(o!==0){t=o;a:{var c=e;i=Jl;var l=c.current.memoizedState.isDehydrated;if(l&&(bu(c,o).flags|=256),o=Eu(c,o,!1),o!==2){if(Bl&&!l){c.errorRecoveryDisabledLanes|=a,Wl|=a,i=4;break a}a=Yl,Yl=i,a!==null&&(Yl===null?Yl=a:Yl.push.apply(Yl,a))}i=o}if(a=!1,i!==2)continue}}if(i===1){bu(e,0),_u(e,t,0,!0);break}a:{switch(r=e,a=i,a){case 0:case 1:throw Error(s(345));case 4:if((t&4194048)!==t)break;case 6:_u(r,t,Kl,!Rl);break a;case 2:Yl=null;break;case 3:case 5:break;default:throw Error(s(329))}if((t&62914560)===t&&(i=Zl+300-xe(),10<i)){if(_u(r,t,Kl,!Rl),Be(r,0,!0)!==0)break a;au=t,r.timeoutHandle=Kd(hu.bind(null,r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,a,`Throttled`,-0,0),i);break a}hu(r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,a,null,-0,0)}}break}while(1);nd(e)}function hu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Jt},Dl(t,a,d);var m=(a&62914560)===a?Zl-xe():(a&4194048)===a?Ql-xe():0;if(m=qf(d,m),m!==null){au=a,e.cancelPendingCommit=m(Fu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),_u(e,a,o,!l);return}}Fu(e,t,a,n,r,i,o,s,c)}function gu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!hr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;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 _u(e,t,n,r){t&=~Gl,t&=~Wl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Me(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&qe(e,n,t)}function vu(){return X&6?!0:(rd(0,!1),!1)}function yu(){if(Z!==null){if(Il===0)var e=Z.return;else e=Z,zi=Ri=null,Co(e),wa=null,Ta=0,e=Z;for(;e!==null;)Fc(e.alternate,e),e=e.return;Z=null}}function bu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,qd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),au=0,yu(),Fl=e,Z=n=ri(e.current,null),Q=t,Il=0,Ll=null,Rl=!1,zl=Ve(e,t),Bl=!1,ql=Kl=Gl=Wl=Ul=Hl=0,Yl=Jl=null,Xl=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Me(r),a=1<<i;t|=e[i],r&=~a}return Vl=t,qr(),n}function xu(e,t){J=null,I.H=Ns,t===ma||t===ga?(t=Sa(),Il=3):t===ha?(t=Sa(),Il=4):Il=t===Xs?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Ll=t,Z===null&&(Hl=1,Gs(e,di(t,e.current)))}function Su(){var e=Ya.current;return e===null?!0:(Q&4194048)===Q?Xa===null:(Q&62914560)===Q||Q&536870912?e===Xa:!1}function Cu(){var e=I.H;return I.H=Ns,e===null?Ns:e}function wu(){var e=I.A;return I.A=Nl,e}function Tu(){Hl=4,Rl||(Q&4194048)!==Q&&Ya.current!==null||(zl=!0),!(Ul&134217727)&&!(Wl&134217727)||Fl===null||_u(Fl,Q,Kl,!1)}function Eu(e,t,n){var r=X;X|=2;var i=Cu(),a=wu();(Fl!==e||Q!==t)&&(eu=null,bu(e,t)),t=!1;var o=Hl;a:do try{if(Il!==0&&Z!==null){var s=Z,c=Ll;switch(Il){case 8:yu(),o=6;break a;case 3:case 2:case 9:case 6:Ya.current===null&&(t=!0);var l=Il;if(Il=0,Ll=null,Mu(e,s,c,l),n&&zl){o=0;break a}break;default:l=Il,Il=0,Ll=null,Mu(e,s,c,l)}}Du(),o=Hl;break}catch(t){xu(e,t)}while(1);return t&&e.shellSuspendCounter++,zi=Ri=null,X=r,I.H=i,I.A=a,Z===null&&(Fl=null,Q=0,qr()),o}function Du(){for(;Z!==null;)Au(Z)}function Ou(e,t){var n=X;X|=2;var r=Cu(),i=wu();Fl!==e||Q!==t?(eu=null,$l=xe()+500,bu(e,t)):zl=Ve(e,t);a:do try{if(Il!==0&&Z!==null){t=Z;var a=Ll;b:switch(Il){case 1:Il=0,Ll=null,Mu(e,t,a,1);break;case 2:case 9:if(va(a)){Il=0,Ll=null,ju(t);break}t=function(){Il!==2&&Il!==9||Fl!==e||(Il=7),nd(e)},a.then(t,t);break a;case 3:Il=7;break a;case 4:Il=5;break a;case 7:va(a)?(Il=0,Ll=null,ju(t)):(Il=0,Ll=null,Mu(e,t,a,7));break;case 5:var o=null;switch(Z.tag){case 26:o=Z.memoizedState;case 5:case 27:var c=Z;if(o?Wf(o):c.stateNode.complete){Il=0,Ll=null;var l=c.sibling;if(l!==null)Z=l;else{var u=c.return;u===null?Z=null:(Z=u,Nu(u))}break b}}Il=0,Ll=null,Mu(e,t,a,5);break;case 6:Il=0,Ll=null,Mu(e,t,a,6);break;case 8:yu(),Hl=6;break a;default:throw Error(s(462))}}ku();break}catch(t){xu(e,t)}while(1);return zi=Ri=null,I.H=r,I.A=i,X=n,Z===null?(Fl=null,Q=0,qr(),Hl):0}function ku(){for(;Z!==null&&!ye();)Au(Z)}function Au(e){var t=Ec(e.alternate,e,Vl);e.memoizedProps=e.pendingProps,t===null?Nu(e):Z=t}function ju(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=uc(n,t,t.pendingProps,t.type,void 0,Q);break;case 11:t=uc(n,t,t.pendingProps,t.type.render,t.ref,Q);break;case 5:Co(t);default:Fc(n,t),t=Z=ii(t,Vl),t=Ec(n,t,Vl)}e.memoizedProps=e.pendingProps,t===null?Nu(e):Z=t}function Mu(e,t,n,r){zi=Ri=null,Co(t),wa=null,Ta=0;var i=t.return;try{if(Ys(e,i,t,n,Q)){Hl=1,Gs(e,di(n,e.current)),Z=null;return}}catch(t){if(i!==null)throw Z=i,t;Hl=1,Gs(e,di(n,e.current)),Z=null;return}t.flags&32768?(K||r===1?e=!0:zl||Q&536870912?e=!1:(Rl=e=!0,(r===2||r===9||r===3||r===6)&&(r=Ya.current,r!==null&&r.tag===13&&(r.flags|=16384))),Pu(t,e)):Nu(t)}function Nu(e){var t=e;do{if(t.flags&32768){Pu(t,Rl);return}e=t.return;var n=Nc(t.alternate,t,Vl);if(n!==null){Z=n;return}if(t=t.sibling,t!==null){Z=t;return}Z=t=e}while(t!==null);Hl===0&&(Hl=5)}function Pu(e,t){do{var n=Pc(e.alternate,e);if(n!==null){n.flags&=32767,Z=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Z=e;return}Z=e=n}while(e!==null);Hl=6,Z=null}function Fu(e,t,n,r,i,a,o,c,l){e.cancelPendingCommit=null;do Bu();while(nu!==0);if(X&6)throw Error(s(327));if(t!==null){if(t===e.current)throw Error(s(177));if(a=t.lanes|t.childLanes,a|=Kr,Ke(e,n,a,o,c,l),e===Fl&&(Z=Fl=null,Q=0),iu=t,ru=e,au=n,ou=a,su=i,cu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Yu(Te,function(){return Vu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=I.T,I.T=null,i=L.p,L.p=2,o=X,X|=4;try{el(e,t,n)}finally{X=o,L.p=i,I.T=r}}nu=1,Iu(),Lu(),Ru()}}function Iu(){if(nu===1){nu=0;var e=ru,t=iu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=I.T,I.T=null;var r=L.p;L.p=2;var i=X;X|=4;try{pl(t,e);var a=zd,o=br(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&yr(s.ownerDocument.documentElement,s)){if(c!==null&&xr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=vr(s,h),v=vr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}sp=!!Rd,zd=Rd=null}finally{X=i,L.p=r,I.T=n}}e.current=t,nu=2}}function Lu(){if(nu===2){nu=0;var e=ru,t=iu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=I.T,I.T=null;var r=L.p;L.p=2;var i=X;X|=4;try{tl(e,t.alternate,t)}finally{X=i,L.p=r,I.T=n}}nu=3}}function Ru(){if(nu===4||nu===3){nu=0,be();var e=ru,t=iu,n=au,r=cu;t.subtreeFlags&10256||t.flags&10256?nu=5:(nu=0,iu=ru=null,zu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(tu=null),Ze(n),t=t.stateNode,Ae&&typeof Ae.onCommitFiberRoot==`function`)try{Ae.onCommitFiberRoot(ke,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=I.T,i=L.p,L.p=2,I.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{I.T=t,L.p=i}}au&3&&Bu(),nd(e),i=e.pendingLanes,n&261930&&i&42?e===uu?lu++:(lu=0,uu=e):lu=0,rd(0,!1)}}function zu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ta(t)))}function Bu(){return Iu(),Lu(),Ru(),Vu()}function Vu(){if(nu!==5)return!1;var e=ru,t=ou;ou=0;var n=Ze(au),r=I.T,i=L.p;try{L.p=32>n?32:n,I.T=null,n=su,su=null;var a=ru,o=au;if(nu=0,iu=ru=null,au=0,X&6)throw Error(s(331));var c=X;if(X|=4,Al(a.current),Sl(a,a.current,o,n),X=c,rd(0,!1),Ae&&typeof Ae.onPostCommitFiberRoot==`function`)try{Ae.onPostCommitFiberRoot(ke,a)}catch{}return!0}finally{L.p=i,I.T=r,zu(e,t)}}function Hu(e,t,n){t=di(n,t),t=Ks(e.stateNode,t,2),e=Ia(e,t,2),e!==null&&(Ge(e,2),nd(e))}function Uu(e,t,n){if(e.tag===3)Hu(e,e,n);else for(;t!==null;){if(t.tag===3){Hu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(tu===null||!tu.has(r))){e=di(n,e),n=qs(2),r=Ia(t,n,2),r!==null&&(Js(n,r,t,e),Ge(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Pl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Bl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Fl===e&&(Q&n)===n&&(Hl===4||Hl===3&&(Q&62914560)===Q&&300>xe()-Zl?!(X&2)&&bu(e,0):Gl|=n,ql===Q&&(ql=0)),nd(e)}function Ku(e,t){t===0&&(t=Ue()),e=Xr(e,t),e!==null&&(Ge(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(s(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return _e(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Me(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Q,a=Be(r,r===Fl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Ve(r,a)||(n=!0,cd(r,a));r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Gd()&&(e=td);for(var t=xe(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}nu!==0&&nu!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Me(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=He(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Fl,n=Q,n=Be(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Il===2||Il===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&ve(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Ve(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&ve(r),Ze(n)){case 2:case 8:n=we;break;case 32:n=Te;break;case 268435456:n=Ee;break;default:n=Te}return r=sd.bind(null,e),n=_e(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&ve(r),e.callbackPriority=2,e.callbackNode=null,2}function sd(e,t){if(nu!==0&&nu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Bu()&&e.callbackNode!==n)return null;var r=Q;return r=Be(e,e===Fl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(mu(e,r,t),od(e,xe()),e.callbackNode!=null&&e.callbackNode===n?sd.bind(null,e):null)}function cd(e,t){if(Bu())return null;mu(e,t,!0)}function ld(){Yd(function(){X&6?_e(Ce,id):ad()})}function ud(){if(td===0){var e=ia;e===0&&(e=Ie,Ie<<=1,!(Ie&261888)&&(Ie=256)),td=e}return td}function dd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:qt(``+e)}function fd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function pd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=dd((i[nt]||null).action),o=r.submitter;o&&(t=(t=o[nt]||null)?dd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new gn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(td!==0){var e=o?fd(i,o):new FormData(i);ys(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?fd(i,o):new FormData(i),ys(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var md=0;md<Vr.length;md++){var hd=Vr[md];Hr(hd.toLowerCase(),`on`+(hd[0].toUpperCase()+hd.slice(1)))}Hr(Nr,`onAnimationEnd`),Hr(Pr,`onAnimationIteration`),Hr(Fr,`onAnimationStart`),Hr(`dblclick`,`onDoubleClick`),Hr(`focusin`,`onFocus`),Hr(`focusout`,`onBlur`),Hr(Ir,`onTransitionRun`),Hr(Lr,`onTransitionStart`),Hr(Rr,`onTransitionCancel`),Hr(zr,`onTransitionEnd`),vt(`onMouseEnter`,[`mouseout`,`mouseover`]),vt(`onMouseLeave`,[`mouseout`,`mouseover`]),vt(`onPointerEnter`,[`pointerout`,`pointerover`]),vt(`onPointerLeave`,[`pointerout`,`pointerover`]),_t(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),_t(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),_t(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),_t(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),_t(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),_t(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var gd=`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(` `),_d=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(gd));function vd(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Ur(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Ur(e)}i.currentTarget=null,a=c}}}}function $(e,t){var n=t[it];n===void 0&&(n=t[it]=new Set);var r=e+`__bubble`;n.has(r)||(Sd(t,e,2,!1),n.add(r))}function yd(e,t,n){var r=0;t&&(r|=4),Sd(n,e,r,t)}var bd=`_reactListening`+Math.random().toString(36).slice(2);function xd(e){if(!e[bd]){e[bd]=!0,ht.forEach(function(t){t!==`selectionchange`&&(_d.has(t)||yd(t,!1,e),yd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[bd]||(t[bd]=!0,yd(`selectionchange`,!1,t))}}function Sd(e,t,n,r){switch(mp(t)){case 2:var i=cp;break;case 8:i=lp;break;default:i=up}n=i.bind(null,t,n,e),i=void 0,!an||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Cd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var s=r.stateNode.containerInfo;if(s===i)break;if(o===4)for(o=r.return;o!==null;){var c=o.tag;if((c===3||c===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;s!==null;){if(o=ut(s),o===null)return;if(c=o.tag,c===5||c===6||c===26||c===27){r=a=o;continue a}s=s.parentNode}}r=r.return}tn(function(){var r=a,i=Xt(n),o=[];a:{var s=Br.get(e);if(s!==void 0){var c=gn,u=e;switch(e){case`keypress`:if(dn(n)===0)break a;case`keydown`:case`keyup`:c=Nn;break;case`focusin`:u=`focus`,c=Tn;break;case`focusout`:u=`blur`,c=Tn;break;case`beforeblur`:case`afterblur`:c=Tn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:c=Cn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:c=wn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:c=Fn;break;case Nr:case Pr:case Fr:c=En;break;case zr:c=In;break;case`scroll`:case`scrollend`:c=vn;break;case`wheel`:c=Ln;break;case`copy`:case`cut`:case`paste`:c=Dn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:c=Pn;break;case`toggle`:case`beforetoggle`:c=Rn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?s===null?null:s+`Capture`:s;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=nn(m,p),g!=null&&d.push(wd(m,g,h))),f)break;m=m.return}0<d.length&&(s=new c(s,u,null,n,i),o.push({event:s,listeners:d}))}}if(!(t&7)){a:{if(s=e===`mouseover`||e===`pointerover`,c=e===`mouseout`||e===`pointerout`,s&&n!==Yt&&(u=n.relatedTarget||n.fromElement)&&(ut(u)||u[rt]))break a;if((c||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,c?(u=n.relatedTarget||n.toElement,c=r,u=u?ut(u):null,u!==null&&(f=l(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(c=null,u=r),c!==u)){if(d=Cn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Pn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=c==null?s:ft(c),h=u==null?s:ft(u),s=new d(g,m+`leave`,c,n,i),s.target=f,s.relatedTarget=h,g=null,ut(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,c&&u)b:{for(d=Ed,p=c,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;c!==null&&Dd(o,s,c,d,!1),u!==null&&f!==null&&Dd(o,f,u,d,!0)}}a:{if(s=r?ft(r):window,c=s.nodeName&&s.nodeName.toLowerCase(),c===`select`||c===`input`&&s.type===`file`)var v=rr;else if(Zn(s))if(ir)v=pr;else{v=dr;var y=ur}else c=s.nodeName,!c||c.toLowerCase()!==`input`||s.type!==`checkbox`&&s.type!==`radio`?r&&Wt(r.elementType)&&(v=rr):v=fr;if(v&&=v(e,r)){Qn(o,v,n,i);break a}y&&y(e,s,r),e===`focusout`&&r&&s.type===`number`&&r.memoizedProps.value!=null&&It(s,`number`,s.value)}switch(y=r?ft(r):window,e){case`focusin`:(Zn(y)||y.contentEditable===`true`)&&(Cr=y,wr=r,Tr=null);break;case`focusout`:Tr=wr=Cr=null;break;case`mousedown`:Er=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Er=!1,Dr(o,n,i);break;case`selectionchange`:if(Sr)break;case`keydown`:case`keyup`:Dr(o,n,i)}var b;if(zn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else qn?Gn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Hn&&n.locale!==`ko`&&(qn||x!==`onCompositionStart`?x===`onCompositionEnd`&&qn&&(b=un()):(sn=i,cn=`value`in sn?sn.value:sn.textContent,qn=!0)),y=Td(r,x),0<y.length&&(x=new On(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=Kn(n),b!==null&&(x.data=b)))),(b=Vn?Jn(e,n):Yn(e,n))&&(x=Td(r,`onBeforeInput`),0<x.length&&(y=new On(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),pd(o,e,r,n,i)}vd(o,t)})}function wd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Td(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=nn(e,n),i!=null&&r.unshift(wd(e,i,a)),i=nn(e,t),i!=null&&r.push(wd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ed(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Dd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=nn(n,a),l!=null&&o.unshift(wd(n,l,c))):i||(l=nn(n,a),l!=null&&o.push(wd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Od=/\r\n?/g,kd=/\u0000|\uFFFD/g;function Ad(e){return(typeof e==`string`?e:``+e).replace(Od,`
9
- `).replace(kd,``)}function jd(e,t){return t=Ad(t),Ad(e)===t}function Md(e,t,n,r,i,a){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Bt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Bt(e,``+r);break;case`className`:wt(e,`class`,r);break;case`tabIndex`:wt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:wt(e,n,r);break;case`style`:Ut(e,r,a);break;case`data`:if(t!==`object`){wt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=qt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`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 a==`function`&&(n===`formAction`?(t!==`input`&&Md(e,t,`name`,i.name,i,null),Md(e,t,`formEncType`,i.formEncType,i,null),Md(e,t,`formMethod`,i.formMethod,i,null),Md(e,t,`formTarget`,i.formTarget,i,null)):(Md(e,t,`encType`,i.encType,i,null),Md(e,t,`method`,i.method,i,null),Md(e,t,`target`,i.target,i,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=qt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Jt);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(s(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=qt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);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`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:$(`beforetoggle`,e),$(`toggle`,e),Ct(e,`popover`,r);break;case`xlinkActuate`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Ct(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=Gt.get(n)||n,Ct(e,n,r))}}function Nd(e,t,n,r,i,a){switch(n){case`style`:Ut(e,r,a);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(s(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Bt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Bt(e,``+r);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Jt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!gt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(i=n.endsWith(`Capture`),t=n.slice(2,i?n.length-7:void 0),a=e[nt]||null,a=a==null?null:a[n],typeof a==`function`&&e.removeEventListener(t,a,i),typeof r==`function`)){typeof a!=`function`&&a!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,i);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Ct(e,n,r)}}}function Pd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:$(`error`,e),$(`load`,e);var r=!1,i=!1,a;for(a in n)if(n.hasOwnProperty(a)){var o=n[a];if(o!=null)switch(a){case`src`:r=!0;break;case`srcSet`:i=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(s(137,t));default:Md(e,t,a,o,n,null)}}i&&Md(e,t,`srcSet`,n.srcSet,n,null),r&&Md(e,t,`src`,n.src,n,null);return;case`input`:$(`invalid`,e);var c=a=o=i=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:i=d;break;case`type`:o=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:a=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(s(137,t));break;default:Md(e,t,r,d,n,null)}}Ft(e,a,c,l,u,o,i,!1);return;case`select`:for(i in $(`invalid`,e),r=o=a=null,n)if(n.hasOwnProperty(i)&&(c=n[i],c!=null))switch(i){case`value`:a=c;break;case`defaultValue`:o=c;break;case`multiple`:r=c;default:Md(e,t,i,c,n,null)}t=a,n=o,e.multiple=!!r,t==null?n!=null&&Lt(e,!!r,n,!0):Lt(e,!!r,t,!1);return;case`textarea`:for(o in $(`invalid`,e),a=i=r=null,n)if(n.hasOwnProperty(o)&&(c=n[o],c!=null))switch(o){case`value`:r=c;break;case`defaultValue`:i=c;break;case`children`:a=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(s(91));break;default:Md(e,t,o,c,n,null)}zt(e,r,i,a);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Md(e,t,l,r,n,null)}return;case`dialog`:$(`beforetoggle`,e),$(`toggle`,e),$(`cancel`,e),$(`close`,e);break;case`iframe`:case`object`:$(`load`,e);break;case`video`:case`audio`:for(r=0;r<gd.length;r++)$(gd[r],e);break;case`image`:$(`error`,e),$(`load`,e);break;case`details`:$(`toggle`,e);break;case`embed`:case`source`:case`link`:$(`error`,e),$(`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(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(s(137,t));default:Md(e,t,u,r,n,null)}return;default:if(Wt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Nd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Md(e,t,c,r,n,null))}function Fd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var i=null,a=null,o=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Md(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:a=m;break;case`name`:i=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:o=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(s(137,t));break;default:m!==f&&Md(e,t,p,m,r,f)}}Pt(e,o,c,l,u,d,a,i);return;case`select`:for(a in m=o=c=p=null,n)if(l=n[a],n.hasOwnProperty(a)&&l!=null)switch(a){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(a)||Md(e,t,a,null,r,l)}for(i in r)if(a=r[i],l=n[i],r.hasOwnProperty(i)&&(a!=null||l!=null))switch(i){case`value`:p=a;break;case`defaultValue`:c=a;break;case`multiple`:o=a;default:a!==l&&Md(e,t,i,a,r,l)}t=c,n=o,r=m,p==null?!!r!=!!n&&(t==null?Lt(e,!!n,n?[]:``,!1):Lt(e,!!n,t,!0)):Lt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(i=n[c],n.hasOwnProperty(c)&&i!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Md(e,t,c,null,r,i)}for(o in r)if(i=r[o],a=n[o],r.hasOwnProperty(o)&&(i!=null||a!=null))switch(o){case`value`:p=i;break;case`defaultValue`:m=i;break;case`children`:break;case`dangerouslySetInnerHTML`:if(i!=null)throw Error(s(91));break;default:i!==a&&Md(e,t,o,i,r,a)}Rt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Md(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Md(e,t,l,p,r,m)}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 g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Md(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(s(137,t));break;default:Md(e,t,u,p,r,m)}return;default:if(Wt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Nd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Nd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Md(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Md(e,t,f,p,r,m)}function Id(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Ld(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Id(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.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 Rd=null,zd=null;function Bd(e){return e.nodeType===9?e:e.ownerDocument}function Vd(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 Hd(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 Ud(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 Wd=null;function Gd(){var e=window.event;return e&&e.type===`popstate`?e===Wd?!1:(Wd=e,!0):(Wd=null,!1)}var Kd=typeof setTimeout==`function`?setTimeout:void 0,qd=typeof clearTimeout==`function`?clearTimeout:void 0,Jd=typeof Promise==`function`?Promise:void 0,Yd=typeof queueMicrotask==`function`?queueMicrotask:Jd===void 0?Kd:function(e){return Jd.resolve(null).then(e).catch(Xd)};function Xd(e){setTimeout(function(){throw e})}function Zd(e){return e===`head`}function Qd(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Np(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)pf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,pf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ct]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&pf(e.ownerDocument.body);n=i}while(n);Np(t)}function $d(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function ef(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ef(n),lt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function tf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[ct])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=cf(e.nextSibling),e===null)break}return null}function nf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=cf(e.nextSibling),e===null))return null;return e}function rf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=cf(e.nextSibling),e===null))return null;return e}function af(e){return e.data===`$?`||e.data===`$~`}function of(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function sf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function cf(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 lf=null;function uf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return cf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function df(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function ff(e,t,n){switch(t=Bd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(s(452));return e;case`head`:if(e=t.head,!e)throw Error(s(453));return e;case`body`:if(e=t.body,!e)throw Error(s(454));return e;default:throw Error(s(451))}}function pf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);lt(e)}var mf=new Map,hf=new Set;function gf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var _f=L.d;L.d={f:vf,r:yf,D:Sf,C:Cf,L:wf,m:Tf,X:Df,S:Ef,M:Of};function vf(){var e=_f.f(),t=vu();return e||t}function yf(e){var t=dt(e);t!==null&&t.tag===5&&t.type===`form`?xs(t):_f.r(e)}var bf=typeof document>`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Nt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Nt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Nt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Nt(n.imageSizes)+`"]`)):i+=`[href="`+Nt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Nt(r)+`"][href="`+Nt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=h({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),mt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=pt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);mt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=re.current)?gf(i):null;if(!i)throw Error(s(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=pt(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var a=pt(i).hoistableStyles,o=a.get(e);if(o||(i=i.ownerDocument||i,o={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},a.set(e,o),(a=i.querySelector(jf(e)))&&!a._p&&(o.instance=a,o.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),a||Nf(i,e,n,o.state))),t&&r===null)throw Error(s(528,``));return o}if(t&&r!==null)throw Error(s(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=pt(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(s(444,e))}}function Af(e){return`href="`+Nt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),mt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Nt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Nt(n.href)+`"]`);if(r)return t.instance=r,mt(r),r;var i=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),mt(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var a=e.querySelector(jf(i));if(a)return t.state.loading|=4,t.instance=a,mt(a),a;r=Mf(n),(i=mf.get(i))&&Rf(r,i),a=(e.ownerDocument||e).createElement(`link`),mt(a);var o=a;return o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),t.state.loading|=4,Lf(a,n.precedence,e),t.instance=a;case`script`:return a=Pf(n.src),(i=e.querySelector(Ff(a)))?(t.instance=i,mt(i),i):(r=n,(i=mf.get(a))&&(r=h({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),mt(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(s(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Rf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Bf=null;function Vf(e,t,n){if(Bf===null){var r=new Map,i=Bf=new Map;i.set(n,r)}else i=Bf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ct]||a[tt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Hf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Uf(e,t,n){if(n===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 Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,mt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),mt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Kf===0&&(Kf=62500*Ld());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Jf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var Qf={$$typeof:C,Provider:null,Consumer:null,_currentValue:R,_currentValue2:R,_threadCount:0};function $f(e,t,n,r,i,a,o,s,c){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=We(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=We(0),this.hiddenUpdates=We(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ep(e,t,n,r,i,a,o,s,c,l,u,d){return e=new $f(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ti(3,null,null,t),e.current=a,a.stateNode=e,t=ea(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Na(a),e}function tp(e){return e?(e=$r,e):$r}function np(e,t,n,r,i,a){i=tp(i),r.context===null?r.context=i:r.pendingContext=i,r=Fa(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ia(e,r,t),n!==null&&(pu(n,e,t),La(n,e,t))}function rp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function ip(e,t){rp(e,t),(e=e.alternate)&&rp(e,t)}function ap(e){if(e.tag===13||e.tag===31){var t=Xr(e,67108864);t!==null&&pu(t,e,67108864),ip(e,67108864)}}function op(e){if(e.tag===13||e.tag===31){var t=du();t=Xe(t);var n=Xr(e,t);n!==null&&pu(n,e,t),ip(e,t)}}var sp=!0;function cp(e,t,n,r){var i=I.T;I.T=null;var a=L.p;try{L.p=2,up(e,t,n,r)}finally{L.p=a,I.T=i}}function lp(e,t,n,r){var i=I.T;I.T=null;var a=L.p;try{L.p=8,up(e,t,n,r)}finally{L.p=a,I.T=i}}function up(e,t,n,r){if(sp){var i=dp(r);if(i===null)Cd(e,t,r,fp,n),Cp(e,r);else if(Tp(i,e,t,n,r))r.stopPropagation();else if(Cp(e,r),t&4&&-1<Sp.indexOf(e)){for(;i!==null;){var a=dt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=ze(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Me(o);s.entanglements[1]|=c,o&=~c}nd(a),!(X&6)&&($l=xe()+500,rd(0,!1))}}break;case 31:case 13:s=Xr(a,2),s!==null&&pu(s,a,2),vu(),ip(a,2)}if(a=dp(r),a===null&&Cd(e,t,r,fp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Cd(e,t,r,null,n)}}function dp(e){return e=Xt(e),pp(e)}var fp=null;function pp(e){if(fp=null,e=ut(e),e!==null){var t=l(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=u(t),e!==null)return e;e=null}else if(n===31){if(e=d(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return fp=e,null}function mp(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(Se()){case Ce:return 2;case we:return 8;case Te:case U:return 32;case Ee:return 268435456;default:return 32}default:return 32}}var hp=!1,gp=null,_p=null,vp=null,yp=new Map,bp=new Map,xp=[],Sp=`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 Cp(e,t){switch(e){case`focusin`:case`focusout`:gp=null;break;case`dragenter`:case`dragleave`:_p=null;break;case`mouseover`:case`mouseout`:vp=null;break;case`pointerover`:case`pointerout`:yp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:bp.delete(t.pointerId)}}function wp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=dt(t),t!==null&&ap(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Tp(e,t,n,r,i){switch(t){case`focusin`:return gp=wp(gp,e,t,n,r,i),!0;case`dragenter`:return _p=wp(_p,e,t,n,r,i),!0;case`mouseover`:return vp=wp(vp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return yp.set(a,wp(yp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,bp.set(a,wp(bp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ep(e){var t=ut(e.target);if(t!==null){var n=l(t);if(n!==null){if(t=n.tag,t===13){if(t=u(n),t!==null){e.blockedOn=t,$e(e.priority,function(){op(n)});return}}else if(t===31){if(t=d(n),t!==null){e.blockedOn=t,$e(e.priority,function(){op(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Dp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=dp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Yt=r,n.target.dispatchEvent(r),Yt=null}else return t=dt(n),t!==null&&ap(t),e.blockedOn=n,!1;t.shift()}return!0}function Op(e,t,n){Dp(e)&&n.delete(t)}function kp(){hp=!1,gp!==null&&Dp(gp)&&(gp=null),_p!==null&&Dp(_p)&&(_p=null),vp!==null&&Dp(vp)&&(vp=null),yp.forEach(Op),bp.forEach(Op)}function Ap(e,n){e.blockedOn===n&&(e.blockedOn=null,hp||(hp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,kp)))}var jp=null;function Mp(e){jp!==e&&(jp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){jp===e&&(jp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(pp(r||n)===null)continue;break}var a=dt(n);a!==null&&(e.splice(t,3),t-=3,ys(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Np(e){function t(t){return Ap(t,e)}gp!==null&&Ap(gp,e),_p!==null&&Ap(_p,e),vp!==null&&Ap(vp,e),yp.forEach(t),bp.forEach(t);for(var n=0;n<xp.length;n++){var r=xp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<xp.length&&(n=xp[0],n.blockedOn===null);)Ep(n),n.blockedOn===null&&xp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[nt]||null;if(typeof a==`function`)o||Mp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[nt]||null)s=o.formAction;else if(pp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Mp(n)}}}function Pp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Fp(e){this._internalRoot=e}Ip.prototype.render=Fp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(s(409));var n=t.current;np(n,du(),e,t,null,null)},Ip.prototype.unmount=Fp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;np(e.current,2,null,e,null,null),vu(),t[rt]=null}};function Ip(e){this._internalRoot=e}Ip.prototype.unstable_scheduleHydration=function(e){if(e){var t=Qe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<xp.length&&t!==0&&t<xp[n].priority;n++);xp.splice(n,0,e),n===0&&Ep(e)}};var Lp=r.version;if(Lp!==`19.2.8`)throw Error(s(527,Lp,`19.2.8`));L.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(s(188)):(e=Object.keys(e).join(`,`),Error(s(268,e)));return e=p(t),e=e===null?null:m(e),e=e===null?null:e.stateNode,e};var Rp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:I,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var zp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!zp.isDisabled&&zp.supportsFiber)try{ke=zp.inject(Rp),Ae=zp}catch{}}e.createRoot=function(e,t){if(!c(e))throw Error(s(299));var n=!1,r=``,i=Hs,a=Us,o=Ws;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(a=t.onCaughtError),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=ep(e,1,!1,null,null,n,r,null,i,a,o,Pp),e[rt]=t.current,xd(e),new Fp(t)}})),c=e(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=s()})),l=i(),u=c(),d=new Map([{family:`Bebas Neue`,fallback:`sans-serif`,weights:`400`},{family:`Crimson Text`,fallback:`serif`,weights:`400;600;700`},{family:`DM Sans`,fallback:`sans-serif`,weights:`100..1000`},{family:`Fira Sans`,fallback:`sans-serif`,weights:`100;200;300;400;500;600;700;800;900`},{family:`Inter`,fallback:`sans-serif`,weights:`100..900`},{family:`JetBrains Mono`,fallback:`monospace`,weights:`100..800`},{family:`Josefin Sans`,fallback:`sans-serif`,weights:`100..700`},{family:`Karla`,fallback:`sans-serif`,weights:`200..800`},{family:`Lato`,fallback:`sans-serif`,weights:`100;300;400;700;900`},{family:`Lora`,fallback:`serif`,weights:`400..700`},{family:`Manrope`,fallback:`sans-serif`,weights:`200..800`},{family:`Merriweather`,fallback:`serif`,weights:`300..900`},{family:`Montserrat`,fallback:`sans-serif`,weights:`100..900`},{family:`Nunito`,fallback:`sans-serif`,weights:`200..1000`},{family:`Open Sans`,fallback:`sans-serif`,weights:`300..800`},{family:`Oswald`,fallback:`sans-serif`,weights:`200..700`},{family:`Outfit`,fallback:`sans-serif`,weights:`100..900`},{family:`Playfair Display`,fallback:`serif`,weights:`400..900`},{family:`Poppins`,fallback:`sans-serif`,weights:`100;200;300;400;500;600;700;800;900`},{family:`Quicksand`,fallback:`sans-serif`,weights:`300..700`},{family:`Raleway`,fallback:`sans-serif`,weights:`100..900`},{family:`Roboto`,fallback:`sans-serif`,weights:`100..900`},{family:`Rubik`,fallback:`sans-serif`,weights:`300..900`},{family:`Source Sans 3`,fallback:`sans-serif`,weights:`200..900`},{family:`Space Grotesk`,fallback:`sans-serif`,weights:`300..700`},{family:`Work Sans`,fallback:`sans-serif`,weights:`100..900`}].map(e=>[e.family,e])),f=e=>`"${e.family}", ${e.fallback}`,p=e=>{let t=d.get(e)?.weights;return`family=${e.replace(/ /g,`+`)}${t?`:wght@${t}`:``}`};function m(e){return e.length?`https://fonts.googleapis.com/css2?${e.map(p).join(`&`)}&display=swap`:null}var h=e=>m([e]),g=e=>{let t=typeof e==`string`&&e.match(/^"([^"]+)"/);return t?t[1]:null},_=e=>{let t=d.get(e);return t?f(t):null};function v(e,t){let n=new Set,r=e=>{for(let t of Object.values(e||{}))for(let e of[`style`,`hover`,`pressed`,`focused`]){let r=g(t.props?.[e]?.fontFamily);r&&n.add(r)}};r(e);for(let e of Object.values(t||{}))r(e.template?.nodes);return[...n].sort()}var y=[`linear`,`ease`,`ease-in`,`ease-out`,`ease-in-out`,`spring`];function b(e){let t=1-Math.min(100,Math.max(0,Number(e)||0))/100*.85,n=Math.log(1e3)/t,r=e=>{if(t>=1)return 1-(1+n*e)*Math.exp(-n*e);let r=n*Math.sqrt(1-t*t);return 1-Math.exp(-t*n*e)*(Math.cos(r*e)+t*n/r*Math.sin(r*e))},i=[];for(let e=0;e<=40;e+=1)i.push(e===40?1:Math.round(r(e/40)*1e3)/1e3);return`linear(${i.join(`,`)})`}var x=e=>{let t=String(e??``).trim();if(!t)return null;let n=Number(t);return Number.isFinite(n)?n:null};function S(e){let t=[],n=[],r=x(e?.opacity),i=x(e?.x),a=x(e?.y),o=x(e?.scale),s=x(e?.rotate),c=x(e?.blur);return r!==null&&t.push(`opacity: ${r}`),i!==null&&n.push(`translateX(${i}px)`),a!==null&&n.push(`translateY(${a}px)`),o!==null&&n.push(`scale(${o})`),s!==null&&n.push(`rotate(${s}deg)`),n.length&&t.push(`transform: ${n.join(` `)}`),c!==null&&t.push(`filter: blur(${c}px)`),t.join(`; `)}var C=e=>`wb-anim-${String(e).replace(/[^\w-]/g,``)}`,w=e=>`--wb-anim-${String(e).replace(/[^\w-]/g,``)}`,T=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches;function E(e,t,{offset:n=0}={}){if(!e||!Array.isArray(t)||T())return;let r=window.getComputedStyle(e),i=t.map(e=>r.getPropertyValue(w(e)).trim()).filter(Boolean);if(!i.length)return;e.style.animation=`none`,e.offsetWidth,e.style.animation=i.join(`, `);let a=Math.max(0,Number(n)||0);if(a>0){let t=window.getComputedStyle(e).animationDelay.split(`,`).map(e=>parseFloat(e)*(e.trim().endsWith(`ms`)?1:1e3)||0);e.style.animationDelay=t.map(e=>`${e+a}ms`).join(`, `)}}var D=[`entry`,`cover`,`exit`],O=()=>typeof CSS<`u`&&typeof CSS.supports==`function`&&CSS.supports(`animation-timeline: view()`),k=(e,t)=>{let n=x(e);return n===null?t:Math.min(100,Math.max(0,n))};function A(e,t){let n=k(t?.start,0),r=Math.max(n,k(t?.end,100));if(e===`page`)return`${n}% ${r}%`;let i=D.includes(t?.phase)?t.phase:`entry`;return`${i} ${n}% ${i} ${r}%`}var j=[`animation-name`,`animation-duration`,`animation-timing-function`,`animation-delay`,`animation-iteration-count`,`animation-fill-mode`,`animation-timeline`,`animation-range`];function M(e,t,{timeline:n,range:r}){if(!e||!Array.isArray(t)||T())return()=>{};let i=window.getComputedStyle(e),a=t.map(e=>i.getPropertyValue(w(e)).trim().split(/\s+/)).filter(e=>e[0]);if(!a.length)return()=>{};let o=j.map(t=>e.style.getPropertyValue(t)),s=e=>a.map(()=>e).join(`, `);return e.style.setProperty(`animation-name`,a.map(e=>e[0]).join(`, `)),e.style.setProperty(`animation-duration`,s(`auto`)),e.style.setProperty(`animation-timing-function`,a.map(e=>e[2]||`linear`).join(`, `)),e.style.setProperty(`animation-delay`,s(`0s`)),e.style.setProperty(`animation-iteration-count`,s(`1`)),e.style.setProperty(`animation-fill-mode`,s(`both`)),e.style.setProperty(`animation-timeline`,s(n)),e.style.setProperty(`animation-range`,s(r)),()=>j.forEach((t,n)=>{o[n]?e.style.setProperty(t,o[n]):e.style.removeProperty(t)})}function N(e){for(let t=e.parentElement;t;t=t.parentElement){let{overflowY:e}=window.getComputedStyle(t);if(/(auto|scroll|overlay)/.test(e)&&t.scrollHeight>t.clientHeight)return t}return null}function P(e,t,n){if(T())return()=>{};let r=M(e,t,{timeline:`auto`,range:`normal`}),i=String(e.style.getPropertyValue(`animation-name`)).split(`,`).map(e=>e.trim()),a=1e3;e.style.setProperty(`animation-duration`,i.map(()=>`${a}ms`).join(`, `)),e.style.setProperty(`animation-play-state`,i.map(()=>`paused`).join(`, `));let o=typeof e.getAnimations==`function`?e.getAnimations().filter(e=>i.includes(e.animationName)):[];if(!o.length)return e.style.removeProperty(`animation-play-state`),r(),()=>{};let s=N(e),c=k(n?.start,0),l=Math.max(c+.001,k(n?.end,100)),u=D.includes(n?.phase)?n.phase:`entry`,d=()=>{if(n?.kind===`page`){let e=s??document.scrollingElement??document.documentElement,t=e.scrollHeight-e.clientHeight;return t>0?e.scrollTop/t*100:0}let t=e.getBoundingClientRect(),r=typeof DOMMatrixReadOnly==`function`?new DOMMatrixReadOnly(window.getComputedStyle(e).transform===`none`?void 0:window.getComputedStyle(e).transform).m42:0,i=e.offsetHeight||t.height,a={top:t.top+t.height/2-r-i/2,height:i},o=s?.getBoundingClientRect(),c=s?{top:o.top+s.clientTop,bottom:o.top+s.clientTop+s.clientHeight}:{top:0,bottom:window.innerHeight},[l,d]={entry:[c.bottom,c.bottom-a.height],exit:[c.top,c.top-a.height],cover:[c.bottom,c.top-a.height]}[u];return(l-a.top)/Math.max(1,l-d)*100},f=0,p=()=>{f=0;let e=Math.min(1,Math.max(0,(d()-c)/(l-c)));o.forEach(t=>{t.currentTime=e*a*.9999})},m=()=>{f||=requestAnimationFrame(p)};return p(),document.addEventListener(`scroll`,m,{capture:!0,passive:!0}),window.addEventListener(`resize`,m),()=>{f&&cancelAnimationFrame(f),document.removeEventListener(`scroll`,m,{capture:!0}),window.removeEventListener(`resize`,m),e.style.removeProperty(`animation-play-state`),r()}}function F(e){return Array.isArray(e)?e.map(e=>{let t=String(e?.id??``).replace(/[^\w-]/g,``);if(!t)return``;let n=C(t),r=S(e.from),i=S(e.to);if(!r&&!i)return``;let a=Math.max(0,x(e.duration)??400),o=Math.max(0,x(e.delay)??0),s=e.easing===`spring`,c=s?b(e.bounce??30):y.includes(e.easing)?e.easing:`ease-out`,l=e.loop?`infinite`:`1`,u=e=>`${n} ${a}ms ${e} ${o}ms ${l} both`,d=u(c);return[`@keyframes ${n} { from { ${r} } to { ${i} } }`,`:root { ${w(t)}: ${d}; }`,`.${n} { animation: ${d}; }`,...s?[`@supports not (animation-timing-function: linear(0, 1)) { :root { ${w(t)}: ${u(`ease-out`)}; } .${n} { animation: ${u(`ease-out`)}; } }`]:[]].join(`
8
+ `+e.stack}}var ge=Object.prototype.hasOwnProperty,_e=t.unstable_scheduleCallback,ve=t.unstable_cancelCallback,ye=t.unstable_shouldYield,be=t.unstable_requestPaint,xe=t.unstable_now,Se=t.unstable_getCurrentPriorityLevel,Ce=t.unstable_ImmediatePriority,we=t.unstable_UserBlockingPriority,Te=t.unstable_NormalPriority,U=t.unstable_LowPriority,Ee=t.unstable_IdlePriority,De=t.log,Oe=t.unstable_setDisableYieldValue,ke=null,Ae=null;function je(e){if(typeof De==`function`&&Oe(e),Ae&&typeof Ae.setStrictMode==`function`)try{Ae.setStrictMode(ke,e)}catch{}}var Me=Math.clz32?Math.clz32:Fe,Ne=Math.log,Pe=Math.LN2;function Fe(e){return e>>>=0,e===0?32:31-(Ne(e)/Pe|0)|0}var Ie=256,Le=262144,Re=4194304;function ze(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 Be(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=ze(n))):i=ze(o):i=ze(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=ze(n))):i=ze(o)):i=ze(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Ve(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function He(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 Ue(){var e=Re;return Re<<=1,!(Re&62914560)&&(Re=4194304),e}function We(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ge(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ke(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Me(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&qe(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function qe(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Me(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Je(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Me(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Ye(e,t){var n=t&-t;return n=n&42?1:Xe(n),(n&(e.suspendedLanes|t))===0?n:0}function Xe(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 Ze(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function Qe(){var e=L.p;return e===0?(e=window.event,e===void 0?32:mp(e.type)):e}function $e(e,t){var n=L.p;try{return L.p=e,t()}finally{L.p=n}}var et=Math.random().toString(36).slice(2),tt=`__reactFiber$`+et,nt=`__reactProps$`+et,rt=`__reactContainer$`+et,it=`__reactEvents$`+et,at=`__reactListeners$`+et,ot=`__reactHandles$`+et,st=`__reactResources$`+et,ct=`__reactMarker$`+et;function lt(e){delete e[tt],delete e[nt],delete e[it],delete e[at],delete e[ot]}function ut(e){var t=e[tt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[rt]||n[tt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=df(e);e!==null;){if(n=e[tt])return n;e=df(e)}return t}e=n,n=e.parentNode}return null}function dt(e){if(e=e[tt]||e[rt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ft(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(s(33))}function pt(e){var t=e[st];return t||=e[st]={hoistableStyles:new Map,hoistableScripts:new Map},t}function mt(e){e[ct]=!0}var ht=new Set,gt={};function _t(e,t){vt(e,t),vt(e+`Capture`,t)}function vt(e,t){for(gt[e]=t,e=0;e<t.length;e++)ht.add(t[e])}var yt=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]*$`),bt={},xt={};function St(e){return ge.call(xt,e)?!0:ge.call(bt,e)?!1:yt.test(e)?xt[e]=!0:(bt[e]=!0,!1)}function Ct(e,t,n){if(St(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function wt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Tt(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Et(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Dt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Ot(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function kt(e){if(!e._valueTracker){var t=Dt(e)?`checked`:`value`;e._valueTracker=Ot(e,t,``+e[t])}}function At(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Dt(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function jt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Mt=/[\n"\\]/g;function Nt(e){return e.replace(Mt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Pt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Et(t)):e.value!==``+Et(t)&&(e.value=``+Et(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):It(e,o,Et(n)):It(e,o,Et(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Et(s):e.removeAttribute(`name`)}function Ft(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){kt(e);return}n=n==null?``:``+Et(n),t=t==null?n:``+Et(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),kt(e)}function It(e,t,n){t===`number`&&jt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Lt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Et(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Rt(e,t,n){if(t!=null&&(t=``+Et(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Et(n)}function zt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(s(92));if(F(r)){if(1<r.length)throw Error(s(93));r=r[0]}n=r}n??=``,t=n}n=Et(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),kt(e)}function Bt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Vt=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 Ht(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Vt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Ut(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(s(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var i in t)r=t[i],t.hasOwnProperty(i)&&n[i]!==r&&Ht(e,i,r)}else for(var a in t)t.hasOwnProperty(a)&&Ht(e,a,t[a])}function Wt(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 Gt=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`]]),Kt=/^[\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 qt(e){return Kt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Jt(){}var Yt=null;function Xt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Zt=null,Qt=null;function $t(e){var t=dt(e);if(t&&(e=t.stateNode)){var n=e[nt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Pt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Nt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=r[nt]||null;if(!i)throw Error(s(90));Pt(r,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&At(r)}break a;case`textarea`:Rt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Lt(e,!!n.multiple,t,!1)}}}var en=!1;function tn(e,t,n){if(en)return e(t,n);en=!0;try{return e(t)}finally{if(en=!1,(Zt!==null||Qt!==null)&&(vu(),Zt&&(t=Zt,e=Qt,Qt=Zt=null,$t(t),e)))for(t=0;t<e.length;t++)$t(e[t])}}function nn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[nt]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(s(231,t,typeof n));return n}var rn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),an=!1;if(rn)try{var on={};Object.defineProperty(on,"passive",{get:function(){an=!0}}),window.addEventListener(`test`,on,on),window.removeEventListener(`test`,on,on)}catch{an=!1}var sn=null,cn=null,ln=null;function un(){if(ln)return ln;var e,t=cn,n=t.length,r,i=`value`in sn?sn.value:sn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return ln=i.slice(e,1<r?1-r:void 0)}function dn(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 fn(){return!0}function pn(){return!1}function mn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?fn:pn,this.isPropagationStopped=pn,this}return h(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=fn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=fn)},persist:function(){},isPersistent:fn}),t}var hn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gn=mn(hn),_n=h({},hn,{view:0,detail:0}),vn=mn(_n),yn,bn,xn,Sn=h({},_n,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:W,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!==xn&&(xn&&e.type===`mousemove`?(yn=e.screenX-xn.screenX,bn=e.screenY-xn.screenY):bn=yn=0,xn=e),yn)},movementY:function(e){return`movementY`in e?e.movementY:bn}}),Cn=mn(Sn),wn=mn(h({},Sn,{dataTransfer:0})),Tn=mn(h({},_n,{relatedTarget:0})),En=mn(h({},hn,{animationName:0,elapsedTime:0,pseudoElement:0})),Dn=mn(h({},hn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),On=mn(h({},hn,{data:0})),kn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},An={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`},jn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Mn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=jn[e])?!!t[e]:!1}function W(){return Mn}var G=mn(h({},_n,{key:function(e){if(e.key){var t=kn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=dn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?An[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:W,charCode:function(e){return e.type===`keypress`?dn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?dn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Nn=mn(h({},Sn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Pn=mn(h({},_n,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:W})),Fn=mn(h({},hn,{propertyName:0,elapsedTime:0,pseudoElement:0})),In=mn(h({},Sn,{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})),Ln=mn(h({},hn,{newState:0,oldState:0})),K=[9,13,27,32],Rn=rn&&`CompositionEvent`in window,zn=null;rn&&`documentMode`in document&&(zn=document.documentMode);var Bn=rn&&`TextEvent`in window&&!zn,Vn=rn&&(!Rn||zn&&8<zn&&11>=zn),Hn=` `,Un=!1;function Wn(e,t){switch(e){case`keyup`:return K.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Gn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Kn=!1;function qn(e,t){switch(e){case`compositionend`:return Gn(t);case`keypress`:return t.which===32?(Un=!0,Hn):null;case`textInput`:return e=t.data,e===Hn&&Un?null:e;default:return null}}function Jn(e,t){if(Kn)return e===`compositionend`||!Rn&&Wn(e,t)?(e=un(),ln=cn=sn=null,Kn=!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 Vn&&t.locale!==`ko`?null:t.data;default:return null}}var Yn={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 Xn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!Yn[e.type]:t===`textarea`}function Zn(e,t,n,r){Zt?Qt?Qt.push(r):Qt=[r]:Zt=r,t=Td(t,`onChange`),0<t.length&&(n=new gn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var Qn=null,$n=null;function er(e){vd(e,0)}function tr(e){if(At(ft(e)))return e}function nr(e,t){if(e===`change`)return t}var rr=!1;if(rn){var ir;if(rn){var ar=`oninput`in document;if(!ar){var or=document.createElement(`div`);or.setAttribute(`oninput`,`return;`),ar=typeof or.oninput==`function`}ir=ar}else ir=!1;rr=ir&&(!document.documentMode||9<document.documentMode)}function sr(){Qn&&(Qn.detachEvent(`onpropertychange`,cr),$n=Qn=null)}function cr(e){if(e.propertyName===`value`&&tr($n)){var t=[];Zn(t,$n,e,Xt(e)),tn(er,t)}}function lr(e,t,n){e===`focusin`?(sr(),Qn=t,$n=n,Qn.attachEvent(`onpropertychange`,cr)):e===`focusout`&&sr()}function ur(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return tr($n)}function dr(e,t){if(e===`click`)return tr(t)}function fr(e,t){if(e===`input`||e===`change`)return tr(t)}function pr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var mr=typeof Object.is==`function`?Object.is:pr;function hr(e,t){if(mr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!ge.call(t,i)||!mr(e[i],t[i]))return!1}return!0}function gr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function _r(e,t){var n=gr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=gr(n)}}function vr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?vr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function yr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=jt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=jt(e.document)}return t}function br(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 xr=rn&&`documentMode`in document&&11>=document.documentMode,Sr=null,Cr=null,wr=null,Tr=!1;function Er(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Tr||Sr==null||Sr!==jt(r)||(r=Sr,`selectionStart`in r&&br(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),wr&&hr(wr,r)||(wr=r,r=Td(Cr,`onSelect`),0<r.length&&(t=new gn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Sr)))}function Dr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Or={animationend:Dr(`Animation`,`AnimationEnd`),animationiteration:Dr(`Animation`,`AnimationIteration`),animationstart:Dr(`Animation`,`AnimationStart`),transitionrun:Dr(`Transition`,`TransitionRun`),transitionstart:Dr(`Transition`,`TransitionStart`),transitioncancel:Dr(`Transition`,`TransitionCancel`),transitionend:Dr(`Transition`,`TransitionEnd`)},kr={},Ar={};rn&&(Ar=document.createElement(`div`).style,`AnimationEvent`in window||(delete Or.animationend.animation,delete Or.animationiteration.animation,delete Or.animationstart.animation),`TransitionEvent`in window||delete Or.transitionend.transition);function jr(e){if(kr[e])return kr[e];if(!Or[e])return e;var t=Or[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Ar)return kr[e]=t[n];return e}var Mr=jr(`animationend`),Nr=jr(`animationiteration`),Pr=jr(`animationstart`),Fr=jr(`transitionrun`),Ir=jr(`transitionstart`),Lr=jr(`transitioncancel`),Rr=jr(`transitionend`),zr=new Map,Br=`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(` `);Br.push(`scrollEnd`);function Vr(e,t){zr.set(e,t),_t(t,[e])}var Hr=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&&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)},Ur=[],Wr=0,Gr=0;function Kr(){for(var e=Wr,t=Gr=Wr=0;t<e;){var n=Ur[t];Ur[t++]=null;var r=Ur[t];Ur[t++]=null;var i=Ur[t];Ur[t++]=null;var a=Ur[t];if(Ur[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&Xr(n,i,a)}}function qr(e,t,n,r){Ur[Wr++]=e,Ur[Wr++]=t,Ur[Wr++]=n,Ur[Wr++]=r,Gr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function Jr(e,t,n,r){return qr(e,t,n,r),Zr(e)}function Yr(e,t){return qr(e,null,null,t),Zr(e)}function Xr(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Me(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function Zr(e){if(50<lu)throw lu=0,uu=null,Error(s(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Qr={};function $r(e,t,n,r){this.tag=e,this.key=n,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=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ei(e,t,n,r){return new $r(e,t,n,r)}function ti(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ni(e,t){var n=e.alternate;return n===null?(n=ei(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ri(e,t){e.flags&=65011714;var n=e.alternate;return n===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=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function ii(e,t,n,r,i,a){var o=0;if(r=e,typeof e==`function`)ti(e)&&(o=1);else if(typeof e==`string`)o=Uf(e,n,H.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case k:return e=ei(31,n,t,i),e.elementType=k,e.lanes=a,e;case y:return ai(n.children,i,a,t);case b:o=8,i|=24;break;case x:return e=ei(12,n,t,i|2),e.elementType=x,e.lanes=a,e;case T:return e=ei(13,n,t,i),e.elementType=T,e.lanes=a,e;case E:return e=ei(19,n,t,i),e.elementType=E,e.lanes=a,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:o=10;break a;case S:o=9;break a;case w:o=11;break a;case D:o=14;break a;case O:o=16,r=null;break a}o=29,n=Error(s(130,e===null?`null`:typeof e,``)),r=null}return t=ei(o,n,t,i),t.elementType=e,t.type=r,t.lanes=a,t}function ai(e,t,n,r){return e=ei(7,e,r,t),e.lanes=n,e}function oi(e,t,n){return e=ei(6,e,null,t),e.lanes=n,e}function si(e){var t=ei(18,null,null,0);return t.stateNode=e,t}function ci(e,t,n){return t=ei(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var li=new WeakMap;function ui(e,t){if(typeof e==`object`&&e){var n=li.get(e);return n===void 0?(t={value:e,source:t,stack:he(t)},li.set(e,t),t):n}return{value:e,source:t,stack:he(t)}}var di=[],fi=0,pi=null,mi=0,hi=[],gi=0,_i=null,vi=1,yi=``;function bi(e,t){di[fi++]=mi,di[fi++]=pi,pi=e,mi=t}function xi(e,t,n){hi[gi++]=vi,hi[gi++]=yi,hi[gi++]=_i,_i=e;var r=vi;e=yi;var i=32-Me(r)-1;r&=~(1<<i),n+=1;var a=32-Me(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,vi=1<<32-Me(t)+i|n<<i|r,yi=a+e}else vi=1<<a|n<<i|r,yi=e}function Si(e){e.return!==null&&(bi(e,1),xi(e,1,0))}function Ci(e){for(;e===pi;)pi=di[--fi],di[fi]=null,mi=di[--fi],di[fi]=null;for(;e===_i;)_i=hi[--gi],hi[gi]=null,yi=hi[--gi],hi[gi]=null,vi=hi[--gi],hi[gi]=null}function wi(e,t){hi[gi++]=vi,hi[gi++]=yi,hi[gi++]=_i,vi=t.id,yi=t.overflow,_i=e}var Ti=null,Ei=null,q=!1,Di=null,Oi=!1,ki=Error(s(519));function Ai(e){throw Ii(ui(Error(s(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),ki}function ji(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[tt]=e,t[nt]=r,n){case`dialog`:$(`cancel`,t),$(`close`,t);break;case`iframe`:case`object`:case`embed`:$(`load`,t);break;case`video`:case`audio`:for(n=0;n<gd.length;n++)$(gd[n],t);break;case`source`:$(`error`,t);break;case`img`:case`image`:case`link`:$(`error`,t),$(`load`,t);break;case`details`:$(`toggle`,t);break;case`input`:$(`invalid`,t),Ft(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:$(`invalid`,t);break;case`textarea`:$(`invalid`,t),zt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||jd(t.textContent,n)?(r.popover!=null&&($(`beforetoggle`,t),$(`toggle`,t)),r.onScroll!=null&&$(`scroll`,t),r.onScrollEnd!=null&&$(`scrollend`,t),r.onClick!=null&&(t.onclick=Jt),t=!0):t=!1,t||Ai(e,!0)}function Mi(e){for(Ti=e.return;Ti;)switch(Ti.tag){case 5:case 31:case 13:Oi=!1;return;case 27:case 3:Oi=!0;return;default:Ti=Ti.return}}function Ni(e){if(e!==Ti)return!1;if(!q)return Mi(e),q=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Ud(e.type,e.memoizedProps)),n=!n),n&&Ei&&Ai(e),Mi(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(317));Ei=uf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(317));Ei=uf(e)}else t===27?(t=Ei,Zd(e.type)?(e=lf,lf=null,Ei=e):Ei=t):Ei=Ti?cf(e.stateNode.nextSibling):null;return!0}function Pi(){Ei=Ti=null,q=!1}function Fi(){var e=Di;return e!==null&&(Yl===null?Yl=e:Yl.push.apply(Yl,e),Di=null),e}function Ii(e){Di===null?Di=[e]:Di.push(e)}var Li=te(null),Ri=null,zi=null;function Bi(e,t,n){V(Li,t._currentValue),t._currentValue=n}function Vi(e){e._currentValue=Li.current,B(Li)}function Hi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Ui(e,t,n,r){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var a=i.dependencies;if(a!==null){var o=i.child;a=a.firstContext;a:for(;a!==null;){var c=a;a=i;for(var l=0;l<t.length;l++)if(c.context===t[l]){a.lanes|=n,c=a.alternate,c!==null&&(c.lanes|=n),Hi(a.return,n,e),r||(o=null);break a}a=c.next}}else if(i.tag===18){if(o=i.return,o===null)throw Error(s(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Hi(o,n,e),o=null}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===e){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}}function Wi(e,t,n,r){e=null;for(var i=t,a=!1;i!==null;){if(!a){if(i.flags&524288)a=!0;else if(i.flags&262144)break}if(i.tag===10){var o=i.alternate;if(o===null)throw Error(s(387));if(o=o.memoizedProps,o!==null){var c=i.type;mr(i.pendingProps.value,o.value)||(e===null?e=[c]:e.push(c))}}else if(i===ie.current){if(o=i.alternate,o===null)throw Error(s(387));o.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e===null?e=[Qf]:e.push(Qf))}i=i.return}e!==null&&Ui(t,e,n,r),t.flags|=262144}function Gi(e){for(e=e.firstContext;e!==null;){if(!mr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Ki(e){Ri=e,zi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function qi(e){return Yi(Ri,e)}function Ji(e,t){return Ri===null&&Ki(e),Yi(e,t)}function Yi(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},zi===null){if(e===null)throw Error(s(308));zi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else zi=zi.next=t;return n}var Xi=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Zi=t.unstable_scheduleCallback,Qi=t.unstable_NormalPriority,$i={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ea(){return{controller:new Xi,data:new Map,refCount:0}}function ta(e){e.refCount--,e.refCount===0&&Zi(Qi,function(){e.controller.abort()})}var na=null,ra=0,ia=0,aa=null;function oa(e,t){if(na===null){var n=na=[];ra=0,ia=ud(),aa={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ra++,t.then(sa,sa),t}function sa(){if(--ra===0&&na!==null){aa!==null&&(aa.status=`fulfilled`);var e=na;na=null,ia=0,aa=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ca(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var la=I.S;I.S=function(e,t){Ql=xe(),typeof t==`object`&&t&&typeof t.then==`function`&&oa(e,t),la!==null&&la(e,t)};var ua=te(null);function da(){var e=ua.current;return e===null?Fl.pooledCache:e}function fa(e,t){t===null?V(ua,ua.current):V(ua,t.pool)}function pa(){var e=da();return e===null?null:{parent:$i._currentValue,pool:e}}var ma=Error(s(460)),ha=Error(s(474)),ga=Error(s(542)),_a={then:function(){}};function va(e){return e=e.status,e===`fulfilled`||e===`rejected`}function ya(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Jt,Jt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ca(e),e;default:if(typeof t.status==`string`)t.then(Jt,Jt);else{if(e=Fl,e!==null&&100<e.shellSuspendCounter)throw Error(s(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ca(e),e}throw xa=t,ma}}function ba(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(xa=e,ma):e}}var xa=null;function Sa(){if(xa===null)throw Error(s(459));var e=xa;return xa=null,e}function Ca(e){if(e===ma||e===ga)throw Error(s(483))}var wa=null,Ta=0;function Ea(e){var t=Ta;return Ta+=1,wa===null&&(wa=[]),ya(wa,e,t)}function Da(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Oa(e,t){throw t.$$typeof===g?Error(s(525)):(e=Object.prototype.toString.call(t),Error(s(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function ka(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function i(e,t){return e=ni(e,t),e.index=0,e.sibling=null,e}function a(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function o(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=oi(n,e.mode,r),t.return=e,t):(t=i(t,n),t.return=e,t)}function l(e,t,n,r){var a=n.type;return a===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===a||typeof a==`object`&&a&&a.$$typeof===O&&ba(a)===t.type)?(t=i(t,n.props),Da(t,n),t.return=e,t):(t=ii(n.type,n.key,n.props,null,e.mode,r),Da(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=ci(n,e.mode,r),t.return=e,t):(t=i(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,a){return t===null||t.tag!==7?(t=ai(n,e.mode,r,a),t.return=e,t):(t=i(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=oi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=ii(t.type,t.key,t.props,null,e.mode,n),Da(n,t),n.return=e,n;case v:return t=ci(t,e.mode,n),t.return=e,t;case O:return t=ba(t),f(e,t,n)}if(F(t)||M(t))return t=ai(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ea(t),n);if(t.$$typeof===C)return f(e,Ji(e,t),n);Oa(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case O:return n=ba(n),p(e,t,n,r)}if(F(n)||M(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ea(n),r);if(n.$$typeof===C)return p(e,t,Ji(e,n),r);Oa(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case O:return r=ba(r),m(e,t,n,r,i)}if(F(r)||M(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Ea(r),i);if(r.$$typeof===C)return m(e,t,n,Ji(t,r),i);Oa(t,r)}return null}function h(i,o,s,c){for(var l=null,u=null,d=o,h=o=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),o=a(_,o,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),q&&bi(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(o=a(d,o,h),u===null?l=d:u.sibling=d,u=d);return q&&bi(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),o=a(g,o,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),q&&bi(i,h),l}function g(i,o,c,l){if(c==null)throw Error(s(151));for(var u=null,d=null,h=o,g=o=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),o=a(y,o,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),q&&bi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return q&&bi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),q&&bi(i,g),u}function b(e,r,a,c){if(typeof a==`object`&&a&&a.type===y&&a.key===null&&(a=a.props.children),typeof a==`object`&&a){switch(a.$$typeof){case _:a:{for(var l=a.key;r!==null;){if(r.key===l){if(l=a.type,l===y){if(r.tag===7){n(e,r.sibling),c=i(r,a.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===O&&ba(l)===r.type){n(e,r.sibling),c=i(r,a.props),Da(c,a),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}a.type===y?(c=ai(a.props.children,e.mode,c,a.key),c.return=e,e=c):(c=ii(a.type,a.key,a.props,null,e.mode,c),Da(c,a),c.return=e,e=c)}return o(e);case v:a:{for(l=a.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===a.containerInfo&&r.stateNode.implementation===a.implementation){n(e,r.sibling),c=i(r,a.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=ci(a,e.mode,c),c.return=e,e=c}return o(e);case O:return a=ba(a),b(e,r,a,c)}if(F(a))return h(e,r,a,c);if(M(a)){if(l=M(a),typeof l!=`function`)throw Error(s(150));return a=l.call(a),g(e,r,a,c)}if(typeof a.then==`function`)return b(e,r,Ea(a),c);if(a.$$typeof===C)return b(e,r,Ji(e,a),c);Oa(e,a)}return typeof a==`string`&&a!==``||typeof a==`number`||typeof a==`bigint`?(a=``+a,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,a),c.return=e,e=c):(n(e,r),c=oi(a,e.mode,c),c.return=e,e=c),o(e)):n(e,r)}return function(e,t,n,r){try{Ta=0;var i=b(e,t,n,r);return wa=null,i}catch(t){if(t===ma||t===ga)throw t;var a=ei(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Aa=ka(!0),ja=ka(!1),Ma=!1;function Na(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Pa(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 Fa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ia(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,X&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=Zr(e),Xr(e,null,n),t}return qr(e,r,t,n),Zr(e)}function La(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Je(e,n)}}function Ra(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var za=!1;function Ba(){if(za){var e=aa;if(e!==null)throw e}}function Va(e,t,n,r){za=!1;var i=e.updateQueue;Ma=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(Q&f)===f:(r&f)===f){f!==0&&f===ia&&(za=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:Ma=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Ul|=o,e.lanes=o,e.memoizedState=d}}function Ha(e,t){if(typeof e!=`function`)throw Error(s(191,e));e.call(t)}function Ua(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ha(n[e],t)}var Wa=te(null),Ga=te(0);function Ka(e,t){e=Vl,V(Ga,e),V(Wa,t),Vl=e|t.baseLanes}function qa(){V(Ga,Vl),V(Wa,Wa.current)}function Ja(){Vl=Ga.current,B(Wa),B(Ga)}var Ya=te(null),Xa=null;function Za(e){var t=e.alternate;V(no,no.current&1),V(Ya,e),Xa===null&&(t===null||Wa.current!==null||t.memoizedState!==null)&&(Xa=e)}function Qa(e){V(no,no.current),V(Ya,e),Xa===null&&(Xa=e)}function $a(e){e.tag===22?(V(no,no.current),V(Ya,e),Xa===null&&(Xa=e)):eo(e)}function eo(){V(no,no.current),V(Ya,Ya.current)}function to(e){B(Ya),Xa===e&&(Xa=null),B(no)}var no=te(0);function ro(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||af(n)||of(n)))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)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 io=0,J=null,ao=null,oo=null,so=!1,co=!1,lo=!1,uo=0,fo=0,po=null,mo=0;function ho(){throw Error(s(321))}function go(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!mr(e[n],t[n]))return!1;return!0}function _o(e,t,n,r,i,a){return io=a,J=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,I.H=e===null||e.memoizedState===null?Ps:Fs,lo=!1,a=n(r,i),lo=!1,co&&(a=yo(t,n,r,i)),vo(e),a}function vo(e){I.H=Ns;var t=ao!==null&&ao.next!==null;if(io=0,oo=ao=J=null,so=!1,fo=0,po=null,t)throw Error(s(300));e===null||Zs||(e=e.dependencies,e!==null&&Gi(e)&&(Zs=!0))}function yo(e,t,n,r){J=e;var i=0;do{if(co&&(po=null),fo=0,co=!1,25<=i)throw Error(s(301));if(i+=1,oo=ao=null,e.updateQueue!=null){var a=e.updateQueue;a.lastEffect=null,a.events=null,a.stores=null,a.memoCache!=null&&(a.memoCache.index=0)}I.H=Is,a=t(n,r)}while(co);return a}function bo(){var e=I.H,t=e.useState()[0];return t=typeof t.then==`function`?Do(t):t,e=e.useState()[0],(ao===null?null:ao.memoizedState)!==e&&(J.flags|=1024),t}function xo(){var e=uo!==0;return uo=0,e}function So(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Co(e){if(so){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}so=!1}io=0,oo=ao=J=null,co=!1,fo=uo=0,po=null}function wo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return oo===null?J.memoizedState=oo=e:oo=oo.next=e,oo}function To(){if(ao===null){var e=J.alternate;e=e===null?null:e.memoizedState}else e=ao.next;var t=oo===null?J.memoizedState:oo.next;if(t!==null)oo=t,ao=e;else{if(e===null)throw J.alternate===null?Error(s(467)):Error(s(310));ao=e,e={memoizedState:ao.memoizedState,baseState:ao.baseState,baseQueue:ao.baseQueue,queue:ao.queue,next:null},oo===null?J.memoizedState=oo=e:oo=oo.next=e}return oo}function Eo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Do(e){var t=fo;return fo+=1,po===null&&(po=[]),e=ya(po,e,t),t=J,(oo===null?t.memoizedState:oo.next)===null&&(t=t.alternate,I.H=t===null||t.memoizedState===null?Ps:Fs),e}function Oo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Do(e);if(e.$$typeof===C)return qi(e)}throw Error(s(438,String(e)))}function ko(e){var t=null,n=J.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=J.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Eo(),J.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=A;return t.index++,n}function Ao(e,t){return typeof t==`function`?t(e):t}function jo(e){return Mo(To(),ao,e)}function Mo(e,t,n){var r=e.queue;if(r===null)throw Error(s(311));r.lastRenderedReducer=n;var i=e.baseQueue,a=r.pending;if(a!==null){if(i!==null){var o=i.next;i.next=a.next,a.next=o}t.baseQueue=i=a,r.pending=null}if(a=e.baseState,i===null)e.memoizedState=a;else{t=i.next;var c=o=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(io&f)===f:(Q&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ia&&(d=!0);else if((io&p)===p){u=u.next,p===ia&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,o=a):l=l.next=f,J.lanes|=p,Ul|=p;f=u.action,lo&&n(a,f),a=u.hasEagerState?u.eagerState:n(a,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,o=a):l=l.next=p,J.lanes|=f,Ul|=f;u=u.next}while(u!==null&&u!==t);if(l===null?o=a:l.next=c,!mr(a,e.memoizedState)&&(Zs=!0,d&&(n=aa,n!==null)))throw n;e.memoizedState=a,e.baseState=o,e.baseQueue=l,r.lastRenderedState=a}return i===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function No(e){var t=To(),n=t.queue;if(n===null)throw Error(s(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,a=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do a=e(a,o.action),o=o.next;while(o!==i);mr(a,t.memoizedState)||(Zs=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),n.lastRenderedState=a}return[a,r]}function Po(e,t,n){var r=J,i=To(),a=q;if(a){if(n===void 0)throw Error(s(407));n=n()}else n=t();var o=!mr((ao||i).memoizedState,n);if(o&&(i.memoizedState=n,Zs=!0),i=i.queue,as(Lo.bind(null,r,i,e),[e]),i.getSnapshot!==t||o||oo!==null&&oo.memoizedState.tag&1){if(r.flags|=2048,es(9,{destroy:void 0},Io.bind(null,r,i,n,t),null),Fl===null)throw Error(s(349));a||io&127||Fo(r,t,n)}return n}function Fo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=J.updateQueue,t===null?(t=Eo(),J.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Io(e,t,n,r){t.value=n,t.getSnapshot=r,Ro(t)&&zo(e)}function Lo(e,t,n){return n(function(){Ro(t)&&zo(e)})}function Ro(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!mr(e,n)}catch{return!0}}function zo(e){var t=Yr(e,2);t!==null&&pu(t,e,2)}function Bo(e){var t=wo();if(typeof e==`function`){var n=e;if(e=n(),lo){je(!0);try{n()}finally{je(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:e},t}function Vo(e,t,n,r){return e.baseState=n,Mo(e,ao,typeof r==`function`?r:Ao)}function Ho(e,t,n,r,i){if(As(e))throw Error(s(485));if(e=t.action,e!==null){var a={payload:i,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){a.listeners.push(e)}};I.T===null?a.isTransition=!1:n(!0),r(a),n=t.pending,n===null?(a.next=t.pending=a,Uo(t,a)):(a.next=n.next,t.pending=n.next=a)}}function Uo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=I.T,o={};I.T=o;try{var s=n(i,r),c=I.S;c!==null&&c(o,s),Wo(e,t,s)}catch(n){Ko(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),I.T=a}}else try{a=n(i,r),Wo(e,t,a)}catch(n){Ko(e,t,n)}}function Wo(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Go(e,t,n)},function(n){return Ko(e,t,n)}):Go(e,t,n)}function Go(e,t,n){t.status=`fulfilled`,t.value=n,qo(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Uo(e,n)))}function Ko(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,qo(t),t=t.next;while(t!==r)}e.action=null}function qo(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Jo(e,t){return t}function Yo(e,t){if(q){var n=Fl.formState;if(n!==null){a:{var r=J;if(q){if(Ei){b:{for(var i=Ei,a=Oi;i.nodeType!==8;){if(!a){i=null;break b}if(i=cf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ei=cf(i.nextSibling),r=i.data===`F!`;break a}}Ai(r)}r=!1}r&&(t=n[0])}}return n=wo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Jo,lastRenderedState:t},n.queue=r,n=Ds.bind(null,J,r),r.dispatch=n,r=Bo(!1),a=ks.bind(null,J,!1,r.queue),r=wo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Ho.bind(null,J,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Xo(e){return Zo(To(),ao,e)}function Zo(e,t,n){if(t=Mo(e,t,Jo)[0],e=jo(Ao)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Do(t)}catch(e){throw e===ma?ga:e}else r=t;t=To();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(J.flags|=2048,es(9,{destroy:void 0},Qo.bind(null,i,n),null)),[r,a,e]}function Qo(e,t){e.action=t}function $o(e){var t=To(),n=ao;if(n!==null)return Zo(t,n,e);To(),t=t.memoizedState,n=To();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function es(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=J.updateQueue,t===null&&(t=Eo(),J.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ts(){return To().memoizedState}function ns(e,t,n,r){var i=wo();J.flags|=e,i.memoizedState=es(1|t,{destroy:void 0},n,r===void 0?null:r)}function rs(e,t,n,r){var i=To();r=r===void 0?null:r;var a=i.memoizedState.inst;ao!==null&&r!==null&&go(r,ao.memoizedState.deps)?i.memoizedState=es(t,a,n,r):(J.flags|=e,i.memoizedState=es(1|t,a,n,r))}function is(e,t){ns(8390656,8,e,t)}function as(e,t){rs(2048,8,e,t)}function os(e){J.flags|=4;var t=J.updateQueue;if(t===null)t=Eo(),J.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ss(e){var t=To().memoizedState;return os({ref:t,nextImpl:e}),function(){if(X&2)throw Error(s(440));return t.impl.apply(void 0,arguments)}}function cs(e,t){return rs(4,2,e,t)}function ls(e,t){return rs(4,4,e,t)}function us(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ds(e,t,n){n=n==null?null:n.concat([e]),rs(4,4,us.bind(null,t,e),n)}function fs(){}function ps(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&go(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function ms(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&go(t,r[1]))return r[0];if(r=e(),lo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r}function hs(e,t,n){return n===void 0||io&1073741824&&!(Q&261930)?e.memoizedState=t:(e.memoizedState=n,e=fu(),J.lanes|=e,Ul|=e,n)}function gs(e,t,n,r){return mr(n,t)?n:Wa.current===null?!(io&42)||io&1073741824&&!(Q&261930)?(Zs=!0,e.memoizedState=n):(e=fu(),J.lanes|=e,Ul|=e,t):(e=hs(e,n,r),mr(e,t)||(Zs=!0),e)}function _s(e,t,n,r,i){var a=L.p;L.p=a!==0&&8>a?a:8;var o=I.T,s={};I.T=s,ks(e,!1,t,n);try{var c=i(),l=I.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Os(e,t,ca(c,r),du(e)):Os(e,t,r,du(e))}catch(n){Os(e,t,{then:function(){},status:`rejected`,reason:n},du())}finally{L.p=a,o!==null&&s.types!==null&&(o.types=s.types),I.T=o}}function vs(){}function ys(e,t,n,r){if(e.tag!==5)throw Error(s(476));var i=bs(e).queue;_s(e,i,t,R,n===null?vs:function(){return xs(e),n(r)})}function bs(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:R,baseState:R,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:R},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function xs(e){var t=bs(e);t.next===null&&(t=e.alternate.memoizedState),Os(e,t.next.queue,{},du())}function Ss(){return qi(Qf)}function Cs(){return To().memoizedState}function ws(){return To().memoizedState}function Ts(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=du();e=Fa(n);var r=Ia(t,e,n);r!==null&&(pu(r,t,n),La(r,t,n)),t={cache:ea()},e.payload=t;return}t=t.return}}function Es(e,t,n){var r=du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},As(e)?js(t,n):(n=Jr(e,t,n,r),n!==null&&(pu(n,e,r),Ms(n,t,r)))}function Ds(e,t,n){Os(e,t,n,du())}function Os(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(As(e))js(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,mr(s,o))return qr(e,t,i,0),Fl===null&&Kr(),!1}catch{}if(n=Jr(e,t,i,r),n!==null)return pu(n,e,r),Ms(n,t,r),!0}return!1}function ks(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},As(e)){if(t)throw Error(s(479))}else t=Jr(e,n,r,2),t!==null&&pu(t,e,2)}function As(e){var t=e.alternate;return e===J||t!==null&&t===J}function js(e,t){co=so=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ms(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Je(e,n)}}var Ns={readContext:qi,use:Oo,useCallback:ho,useContext:ho,useEffect:ho,useImperativeHandle:ho,useLayoutEffect:ho,useInsertionEffect:ho,useMemo:ho,useReducer:ho,useRef:ho,useState:ho,useDebugValue:ho,useDeferredValue:ho,useTransition:ho,useSyncExternalStore:ho,useId:ho,useHostTransitionStatus:ho,useFormState:ho,useActionState:ho,useOptimistic:ho,useMemoCache:ho,useCacheRefresh:ho};Ns.useEffectEvent=ho;var Ps={readContext:qi,use:Oo,useCallback:function(e,t){return wo().memoizedState=[e,t===void 0?null:t],e},useContext:qi,useEffect:is,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ns(4194308,4,us.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ns(4194308,4,e,t)},useInsertionEffect:function(e,t){ns(4,2,e,t)},useMemo:function(e,t){var n=wo();t=t===void 0?null:t;var r=e();if(lo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=wo();if(n!==void 0){var i=n(t);if(lo){je(!0);try{n(t)}finally{je(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Es.bind(null,J,e),[r.memoizedState,e]},useRef:function(e){var t=wo();return e={current:e},t.memoizedState=e},useState:function(e){e=Bo(e);var t=e.queue,n=Ds.bind(null,J,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:fs,useDeferredValue:function(e,t){return hs(wo(),e,t)},useTransition:function(){var e=Bo(!1);return e=_s.bind(null,J,e.queue,!0,!1),wo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=J,i=wo();if(q){if(n===void 0)throw Error(s(407));n=n()}else{if(n=t(),Fl===null)throw Error(s(349));Q&127||Fo(r,t,n)}i.memoizedState=n;var a={value:n,getSnapshot:t};return i.queue=a,is(Lo.bind(null,r,a,e),[e]),r.flags|=2048,es(9,{destroy:void 0},Io.bind(null,r,a,n,t),null),n},useId:function(){var e=wo(),t=Fl.identifierPrefix;if(q){var n=yi,r=vi;n=(r&~(1<<32-Me(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=uo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=mo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Ss,useFormState:Yo,useActionState:Yo,useOptimistic:function(e){var t=wo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=ks.bind(null,J,!0,n),n.dispatch=t,[e,t]},useMemoCache:ko,useCacheRefresh:function(){return wo().memoizedState=Ts.bind(null,J)},useEffectEvent:function(e){var t=wo(),n={impl:e};return t.memoizedState=n,function(){if(X&2)throw Error(s(440));return n.impl.apply(void 0,arguments)}}},Fs={readContext:qi,use:Oo,useCallback:ps,useContext:qi,useEffect:as,useImperativeHandle:ds,useInsertionEffect:cs,useLayoutEffect:ls,useMemo:ms,useReducer:jo,useRef:ts,useState:function(){return jo(Ao)},useDebugValue:fs,useDeferredValue:function(e,t){return gs(To(),ao.memoizedState,e,t)},useTransition:function(){var e=jo(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Cs,useHostTransitionStatus:Ss,useFormState:Xo,useActionState:Xo,useOptimistic:function(e,t){return Vo(To(),ao,e,t)},useMemoCache:ko,useCacheRefresh:ws};Fs.useEffectEvent=ss;var Is={readContext:qi,use:Oo,useCallback:ps,useContext:qi,useEffect:as,useImperativeHandle:ds,useInsertionEffect:cs,useLayoutEffect:ls,useMemo:ms,useReducer:No,useRef:ts,useState:function(){return No(Ao)},useDebugValue:fs,useDeferredValue:function(e,t){var n=To();return ao===null?hs(n,e,t):gs(n,ao.memoizedState,e,t)},useTransition:function(){var e=No(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Cs,useHostTransitionStatus:Ss,useFormState:$o,useActionState:$o,useOptimistic:function(e,t){var n=To();return ao===null?(n.baseState=e,[e,n.queue.dispatch]):Vo(n,ao,e,t)},useMemoCache:ko,useCacheRefresh:ws};Is.useEffectEvent=ss;function Ls(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Rs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=du(),i=Fa(r);i.payload=t,n!=null&&(i.callback=n),t=Ia(e,i,r),t!==null&&(pu(t,e,r),La(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=du(),i=Fa(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ia(e,i,r),t!==null&&(pu(t,e,r),La(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=du(),r=Fa(n);r.tag=2,t!=null&&(r.callback=t),t=Ia(e,r,n),t!==null&&(pu(t,e,n),La(t,e,n))}};function zs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!hr(n,r)||!hr(i,a):!0}function Bs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Rs.enqueueReplaceState(t,t.state,null)}function Vs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Hs(e){Hr(e)}function Us(e){console.error(e)}function Ws(e){Hr(e)}function Gs(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Y(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ks(e,t,n){return n=Fa(n),n.tag=3,n.payload={element:null},n.callback=function(){Gs(e,t)},n}function qs(e){return e=Fa(e),e.tag=3,e}function Js(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Y(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Y(t,n,r),typeof i!=`function`&&(tu===null?tu=new Set([this]):tu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Ys(e,t,n,r,i){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Wi(t,n,i,!0),n=Ya.current,n!==null){switch(n.tag){case 31:case 13:return Xa===null?Tu():n.alternate===null&&Hl===0&&(Hl=3),n.flags&=-257,n.flags|=65536,n.lanes=i,r===_a?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Wu(e,r,i)),!1;case 22:return n.flags|=65536,r===_a?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Wu(e,r,i)),!1}throw Error(s(435,n.tag))}return Wu(e,r,i),Tu(),!1}if(q)return t=Ya.current,t===null?(r!==ki&&(t=Error(s(423),{cause:r}),Ii(ui(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,r=ui(r,n),i=Ks(e.stateNode,r,i),Ra(e,i),Hl!==4&&(Hl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=i,r!==ki&&(e=Error(s(422),{cause:r}),Ii(ui(e,n)))),!1;var a=Error(s(520),{cause:r});if(a=ui(a,n),Jl===null?Jl=[a]:Jl.push(a),Hl!==4&&(Hl=2),t===null)return!0;r=ui(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=Ks(n.stateNode,r,e),Ra(n,e),!1;case 1:if(t=n.type,a=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||a!==null&&typeof a.componentDidCatch==`function`&&(tu===null||!tu.has(a))))return n.flags|=65536,i&=-i,n.lanes|=i,i=qs(i),Js(i,e,n,r),Ra(n,i),!1}n=n.return}while(n!==null);return!1}var Xs=Error(s(461)),Zs=!1;function Qs(e,t,n,r){t.child=e===null?ja(t,null,n,r):Aa(t,e.child,n,r)}function $s(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Ki(t),r=_o(e,t,n,o,a,i),s=xo(),e!==null&&!Zs?(So(e,t,i),Cc(e,t,i)):(q&&s&&Si(t),t.flags|=1,Qs(e,t,r,i),t.child)}function ec(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!ti(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,tc(e,t,a,r,i)):(e=ii(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!wc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?hr:n,n(o,r)&&e.ref===t.ref)return Cc(e,t,i)}return t.flags|=1,e=ni(a,r),e.ref=t.ref,e.return=t,t.child=e}function tc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(hr(a,r)&&e.ref===t.ref)if(Zs=!1,t.pendingProps=r=a,wc(e,i))e.flags&131072&&(Zs=!0);else return t.lanes=e.lanes,Cc(e,t,i)}return lc(e,t,n,r,i)}function nc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return ic(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&fa(t,a===null?null:a.cachePool),a===null?qa():Ka(t,a),$a(t);else return r=t.lanes=536870912,ic(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&fa(t,null),qa(),eo(t)):(fa(t,a.cachePool),Ka(t,a),eo(t),t.memoizedState=null);return Qs(e,t,i,n),t.child}function rc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function ic(e,t,n,r,i){var a=da();return a=a===null?null:{parent:$i._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&fa(t,null),qa(),$a(t),e!==null&&Wi(e,t,r,!0),t.childLanes=i,null}function ac(e,t){return t=vc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function oc(e,t,n){return Aa(t,e.child,null,n),e=ac(t,t.pendingProps),e.flags|=2,to(t),t.memoizedState=null,e}function sc(e,t,n){var r=t.pendingProps,i=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(q){if(r.mode===`hidden`)return e=ac(t,r),t.lanes=536870912,rc(null,e);if(Qa(t),(e=Ei)?(e=rf(e,Oi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:_i===null?null:{id:vi,overflow:yi},retryLane:536870912,hydrationErrors:null},n=si(e),n.return=t,t.child=n,Ti=t,Ei=null)):e=null,e===null)throw Ai(t);return t.lanes=536870912,null}return ac(t,r)}var a=e.memoizedState;if(a!==null){var o=a.dehydrated;if(Qa(t),i)if(t.flags&256)t.flags&=-257,t=oc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(s(558));else if(Zs||Wi(e,t,n,!1),i=(n&e.childLanes)!==0,Zs||i){if(r=Fl,r!==null&&(o=Ye(r,n),o!==0&&o!==a.retryLane))throw a.retryLane=o,Yr(e,o),pu(r,e,o),Xs;Tu(),t=oc(e,t,n)}else e=a.treeContext,Ei=cf(o.nextSibling),Ti=t,q=!0,Di=null,Oi=!1,e!==null&&wi(t,e),t=ac(t,r),t.flags|=4096;return t}return e=ni(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function cc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(s(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function lc(e,t,n,r,i){return Ki(t),n=_o(e,t,n,r,void 0,i),r=xo(),e!==null&&!Zs?(So(e,t,i),Cc(e,t,i)):(q&&r&&Si(t),t.flags|=1,Qs(e,t,n,i),t.child)}function uc(e,t,n,r,i,a){return Ki(t),t.updateQueue=null,n=yo(t,r,n,i),vo(e),r=xo(),e!==null&&!Zs?(So(e,t,a),Cc(e,t,a)):(q&&r&&Si(t),t.flags|=1,Qs(e,t,n,a),t.child)}function dc(e,t,n,r,i){if(Ki(t),t.stateNode===null){var a=Qr,o=n.contextType;typeof o==`object`&&o&&(a=qi(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Rs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Na(t),o=n.contextType,a.context=typeof o==`object`&&o?qi(o):Qr,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ls(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Rs.enqueueReplaceState(a,a.state,null),Va(t,r,a,i),Ba(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Vs(n,s);a.props=c;var l=a.context,u=n.contextType;o=Qr,typeof u==`object`&&u&&(o=qi(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Bs(t,a,r,o),Ma=!1;var f=t.memoizedState;a.state=f,Va(t,r,a,i),Ba(),l=t.memoizedState,s||f!==l||Ma?(typeof d==`function`&&(Ls(t,n,d,r),l=t.memoizedState),(c=Ma||zs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Pa(e,t),o=t.memoizedProps,u=Vs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=Qr,typeof l==`object`&&l&&(c=qi(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Bs(t,a,r,c),Ma=!1,f=t.memoizedState,a.state=f,Va(t,r,a,i),Ba();var p=t.memoizedState;o!==d||f!==p||Ma||e!==null&&e.dependencies!==null&&Gi(e.dependencies)?(typeof s==`function`&&(Ls(t,n,s,r),p=t.memoizedState),(u=Ma||zs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Gi(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,cc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Aa(t,e.child,null,i),t.child=Aa(t,null,n,i)):Qs(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Cc(e,t,i),e}function fc(e,t,n,r){return Pi(),t.flags|=256,Qs(e,t,n,r),t.child}var pc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function mc(e){return{baseLanes:e,cachePool:pa()}}function hc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Kl),e}function gc(e,t,n){var r=t.pendingProps,i=!1,a=(t.flags&128)!=0,o;if((o=a)||(o=e!==null&&e.memoizedState===null?!1:(no.current&2)!=0),o&&(i=!0,t.flags&=-129),o=(t.flags&32)!=0,t.flags&=-33,e===null){if(q){if(i?Za(t):eo(t),(e=Ei)?(e=rf(e,Oi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:_i===null?null:{id:vi,overflow:yi},retryLane:536870912,hydrationErrors:null},n=si(e),n.return=t,t.child=n,Ti=t,Ei=null)):e=null,e===null)throw Ai(t);return of(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,i?(eo(t),i=t.mode,c=vc({mode:`hidden`,children:c},i),r=ai(r,i,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=mc(n),r.childLanes=hc(e,o,n),t.memoizedState=pc,rc(null,r)):(Za(t),_c(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(a)t.flags&256?(Za(t),t.flags&=-257,t=yc(e,t,n)):t.memoizedState===null?(eo(t),c=r.fallback,i=t.mode,r=vc({mode:`visible`,children:r.children},i),c=ai(c,i,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Aa(t,e.child,null,n),r=t.child,r.memoizedState=mc(n),r.childLanes=hc(e,o,n),t.memoizedState=pc,t=rc(null,r)):(eo(t),t.child=e.child,t.flags|=128,t=null);else if(Za(t),of(c)){if(o=c.nextSibling&&c.nextSibling.dataset,o)var u=o.dgst;o=u,r=Error(s(419)),r.stack=``,r.digest=o,Ii({value:r,source:null,stack:null}),t=yc(e,t,n)}else if(Zs||Wi(e,t,n,!1),o=(n&e.childLanes)!==0,Zs||o){if(o=Fl,o!==null&&(r=Ye(o,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Yr(e,r),pu(o,e,r),Xs;af(c)||Tu(),t=yc(e,t,n)}else af(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ei=cf(c.nextSibling),Ti=t,q=!0,Di=null,Oi=!1,e!==null&&wi(t,e),t=_c(t,r.children),t.flags|=4096);return t}return i?(eo(t),c=r.fallback,i=t.mode,l=e.child,u=l.sibling,r=ni(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ai(c,i,n,null),c.flags|=2):c=ni(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,rc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=mc(n):(i=c.cachePool,i===null?i=pa():(l=$i._currentValue,i=i.parent===l?i:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:i}),r.memoizedState=c,r.childLanes=hc(e,o,n),t.memoizedState=pc,rc(e.child,r)):(Za(t),n=e.child,e=n.sibling,n=ni(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=n,t.memoizedState=null,n)}function _c(e,t){return t=vc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function vc(e,t){return e=ei(22,e,null,t),e.lanes=0,e}function yc(e,t,n){return Aa(t,e.child,null,n),e=_c(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function bc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Hi(e.return,t,n)}function xc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Sc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=no.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,V(no,o),Qs(e,t,r,n),r=q?mi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&bc(e,n,t);else if(e.tag===19)bc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&ro(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),xc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&ro(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}xc(t,!0,n,null,a,r);break;case`together`:xc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Cc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Ul|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Wi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(s(153));if(t.child!==null){for(e=t.child,n=ni(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ni(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function wc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Gi(e))):!0}function Tc(e,t,n){switch(t.tag){case 3:ae(t,t.stateNode.containerInfo),Bi(t,$i,e.memoizedState.cache),Pi();break;case 27:case 5:se(t);break;case 4:ae(t,t.stateNode.containerInfo);break;case 10:Bi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Qa(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(Za(t),e=Cc(e,t,n),e===null?null:e.sibling):gc(e,t,n):(Za(t),t.flags|=128,null);Za(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(Wi(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Sc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),V(no,no.current),r)break;return null;case 22:return t.lanes=0,nc(e,t,n,t.pendingProps);case 24:Bi(t,$i,e.memoizedState.cache)}return Cc(e,t,n)}function Ec(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)Zs=!0;else{if(!wc(e,n)&&!(t.flags&128))return Zs=!1,Tc(e,t,n);Zs=!!(e.flags&131072)}else Zs=!1,q&&t.flags&1048576&&xi(t,mi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=ba(t.elementType),t.type=e,typeof e==`function`)ti(e)?(r=Vs(e,r),t.tag=1,t=dc(null,t,e,r,n)):(t.tag=0,t=lc(null,t,e,r,n));else{if(e!=null){var i=e.$$typeof;if(i===w){t.tag=11,t=$s(null,t,e,r,n);break a}else if(i===D){t.tag=14,t=ec(null,t,e,r,n);break a}}throw t=P(e)||e,Error(s(306,t,``))}}return t;case 0:return lc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,i=Vs(r,t.pendingProps),dc(e,t,r,i,n);case 3:a:{if(ae(t,t.stateNode.containerInfo),e===null)throw Error(s(387));r=t.pendingProps;var a=t.memoizedState;i=a.element,Pa(e,t),Va(t,r,null,n);var o=t.memoizedState;if(r=o.cache,Bi(t,$i,r),r!==a.cache&&Ui(t,[$i],n,!0),Ba(),r=o.element,a.isDehydrated)if(a={element:r,isDehydrated:!1,cache:o.cache},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){t=fc(e,t,r,n);break a}else if(r!==i){i=ui(Error(s(424)),t),Ii(i),t=fc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ei=cf(e.firstChild),Ti=t,q=!0,Di=null,Oi=!0,n=ja(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Pi(),r===i){t=Cc(e,t,n);break a}Qs(e,t,r,n)}t=t.child}return t;case 26:return cc(e,t),e===null?(n=kf(t.type,null,t.pendingProps,null))?t.memoizedState=n:q||(n=t.type,e=t.pendingProps,r=Bd(re.current).createElement(n),r[tt]=t,r[nt]=e,Pd(r,n,e),mt(r),t.stateNode=r):t.memoizedState=kf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return se(t),e===null&&q&&(r=t.stateNode=ff(t.type,t.pendingProps,re.current),Ti=t,Oi=!0,i=Ei,Zd(t.type)?(lf=i,Ei=cf(r.firstChild)):Ei=i),Qs(e,t,t.pendingProps.children,n),cc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&q&&((i=r=Ei)&&(r=tf(r,t.type,t.pendingProps,Oi),r===null?i=!1:(t.stateNode=r,Ti=t,Ei=cf(r.firstChild),Oi=!1,i=!0)),i||Ai(t)),se(t),i=t.type,a=t.pendingProps,o=e===null?null:e.memoizedProps,r=a.children,Ud(i,a)?r=null:o!==null&&Ud(i,o)&&(t.flags|=32),t.memoizedState!==null&&(i=_o(e,t,bo,null,null,n),Qf._currentValue=i),cc(e,t),Qs(e,t,r,n),t.child;case 6:return e===null&&q&&((e=n=Ei)&&(n=nf(n,t.pendingProps,Oi),n===null?e=!1:(t.stateNode=n,Ti=t,Ei=null,e=!0)),e||Ai(t)),null;case 13:return gc(e,t,n);case 4:return ae(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Aa(t,null,r,n):Qs(e,t,r,n),t.child;case 11:return $s(e,t,t.type,t.pendingProps,n);case 7:return Qs(e,t,t.pendingProps,n),t.child;case 8:return Qs(e,t,t.pendingProps.children,n),t.child;case 12:return Qs(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Bi(t,t.type,r.value),Qs(e,t,r.children,n),t.child;case 9:return i=t.type._context,r=t.pendingProps.children,Ki(t),i=qi(i),r=r(i),t.flags|=1,Qs(e,t,r,n),t.child;case 14:return ec(e,t,t.type,t.pendingProps,n);case 15:return tc(e,t,t.type,t.pendingProps,n);case 19:return Sc(e,t,n);case 31:return sc(e,t,n);case 22:return nc(e,t,n,t.pendingProps);case 24:return Ki(t),r=qi($i),e===null?(i=da(),i===null&&(i=Fl,a=ea(),i.pooledCache=a,a.refCount++,a!==null&&(i.pooledCacheLanes|=n),i=a),t.memoizedState={parent:r,cache:i},Na(t),Bi(t,$i,i)):((e.lanes&n)!==0&&(Pa(e,t),Va(t,null,null,n),Ba()),i=e.memoizedState,a=t.memoizedState,i.parent===r?(r=a.cache,Bi(t,$i,r),r!==i.cache&&Ui(t,[$i],n,!0)):(i={parent:r,cache:r},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),Bi(t,$i,r))),Qs(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(s(156,t.tag))}function Dc(e){e.flags|=4}function Oc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Su())e.flags|=8192;else throw xa=_a,ha}else e.flags&=-16777217}function kc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Wf(t))if(Su())e.flags|=8192;else throw xa=_a,ha}function Ac(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ue(),e.lanes|=t,ql|=t)}function jc(e,t){if(!q)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Mc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Nc(e,t,n){var r=t.pendingProps;switch(Ci(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Mc(t),null;case 1:return Mc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Vi($i),oe(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ni(t)?Dc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Fi())),Mc(t),null;case 26:var i=t.type,a=t.memoizedState;return e===null?(Dc(t),a===null?(Mc(t),Oc(t,i,null,r,n)):(Mc(t),kc(t,a))):a?a===e.memoizedState?(Mc(t),t.flags&=-16777217):(Dc(t),Mc(t),kc(t,a)):(e=e.memoizedProps,e!==r&&Dc(t),Mc(t),Oc(t,i,e,r,n)),null;case 27:if(ce(t),n=re.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(!r){if(t.stateNode===null)throw Error(s(166));return Mc(t),null}e=H.current,Ni(t)?ji(t,e):(e=ff(i,r,n),t.stateNode=e,Dc(t))}return Mc(t),null;case 5:if(ce(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(!r){if(t.stateNode===null)throw Error(s(166));return Mc(t),null}if(a=H.current,Ni(t))ji(t,a);else{var o=Bd(re.current);switch(a){case 1:a=o.createElementNS(`http://www.w3.org/2000/svg`,i);break;case 2:a=o.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;default:switch(i){case`svg`:a=o.createElementNS(`http://www.w3.org/2000/svg`,i);break;case`math`:a=o.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;case`script`:a=o.createElement(`div`),a.innerHTML=`<script><\/script>`,a=a.removeChild(a.firstChild);break;case`select`:a=typeof r.is==`string`?o.createElement(`select`,{is:r.is}):o.createElement(`select`),r.multiple?a.multiple=!0:r.size&&(a.size=r.size);break;default:a=typeof r.is==`string`?o.createElement(i,{is:r.is}):o.createElement(i)}}a[tt]=t,a[nt]=r;a:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)a.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break a;for(;o.sibling===null;){if(o.return===null||o.return===t)break a;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=a;a:switch(Pd(a,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Dc(t)}}return Mc(t),Oc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Dc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(s(166));if(e=re.current,Ni(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=Ti,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[tt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Ai(t,!0)}else e=Bd(e).createTextNode(r),e[tt]=t,t.stateNode=e}return Mc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ni(t),n!==null){if(e===null){if(!r)throw Error(s(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(557));e[tt]=t}else Pi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Mc(t),e=!1}else n=Fi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(to(t),t):(to(t),null);if(t.flags&128)throw Error(s(558))}return Mc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Ni(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(s(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(s(317));i[tt]=t}else Pi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Mc(t),i=!1}else i=Fi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(to(t),t):(to(t),null)}return to(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),a=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(a=r.memoizedState.cachePool.pool),a!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Ac(t,t.updateQueue),Mc(t),null);case 4:return oe(),e===null&&xd(t.stateNode.containerInfo),Mc(t),null;case 10:return Vi(t.type),Mc(t),null;case 19:if(B(no),r=t.memoizedState,r===null)return Mc(t),null;if(i=(t.flags&128)!=0,a=r.rendering,a===null)if(i)jc(r,!1);else{if(Hl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(a=ro(e),a!==null){for(t.flags|=128,jc(r,!1),e=a.updateQueue,t.updateQueue=e,Ac(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ri(n,e),n=n.sibling;return V(no,no.current&1|2),q&&bi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&xe()>$l&&(t.flags|=128,i=!0,jc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ro(a),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Ac(t,e),jc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!a.alternate&&!q)return Mc(t),null}else 2*xe()-r.renderingStartTime>$l&&n!==536870912&&(t.flags|=128,i=!0,jc(r,!1),t.lanes=4194304);r.isBackwards?(a.sibling=t.child,t.child=a):(e=r.last,e===null?t.child=a:e.sibling=a,r.last=a)}return r.tail===null?(Mc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=xe(),e.sibling=null,n=no.current,V(no,i?n&1|2:n&1),q&&bi(t,r.treeForkCount),e);case 22:case 23:return to(t),Ja(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Mc(t),t.subtreeFlags&6&&(t.flags|=8192)):Mc(t),n=t.updateQueue,n!==null&&Ac(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&B(ua),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Vi($i),Mc(t),null;case 25:return null;case 30:return null}throw Error(s(156,t.tag))}function Pc(e,t){switch(Ci(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vi($i),oe(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ce(t),null;case 31:if(t.memoizedState!==null){if(to(t),t.alternate===null)throw Error(s(340));Pi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(to(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(s(340));Pi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return B(no),null;case 4:return oe(),null;case 10:return Vi(t.type),null;case 22:case 23:return to(t),Ja(),e!==null&&B(ua),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Vi($i),null;case 25:return null;default:return null}}function Fc(e,t){switch(Ci(t),t.tag){case 3:Vi($i),oe();break;case 26:case 27:case 5:ce(t);break;case 4:oe();break;case 31:t.memoizedState!==null&&to(t);break;case 13:to(t);break;case 19:B(no);break;case 10:Vi(t.type);break;case 22:case 23:to(t),Ja(),e!==null&&B(ua);break;case 24:Vi($i)}}function Ic(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Uu(t,t.return,e)}}function Lc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Uu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Uu(t,t.return,e)}}function Rc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ua(t,n)}catch(t){Uu(e,e.return,t)}}}function zc(e,t,n){n.props=Vs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Uu(e,t,n)}}function Bc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Uu(e,t,n)}}function Vc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Uu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Uu(e,t,n)}else n.current=null}function Hc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Uu(e,e.return,t)}}function Uc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[nt]=t}catch(t){Uu(e,e.return,t)}}function Wc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Gc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Wc(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&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Kc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Jt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Kc(e,t,n),e=e.sibling;e!==null;)Kc(e,t,n),e=e.sibling}function qc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(qc(e,t,n),e=e.sibling;e!==null;)qc(e,t,n),e=e.sibling}function Jc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[tt]=e,t[nt]=n}catch(t){Uu(e,e.return,t)}}var Yc=!1,Xc=!1,Zc=!1,Qc=typeof WeakSet==`function`?WeakSet:Set,$c=null;function el(e,t){if(e=e.containerInfo,Rd=sp,e=yr(e),br(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,a=r.focusNode;r=r.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break a}var o=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=o+i),f!==a||r!==0&&f.nodeType!==3||(l=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=o),p===a&&++d===r&&(l=o),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,$c=t;$c!==null;)if(t=$c,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,$c=e;else for(;$c!==null;){switch(t=$c,a=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&a!==null){e=void 0,n=t,i=a.memoizedProps,a=a.memoizedState,r=n.stateNode;try{var h=Vs(n.type,i);e=r.getSnapshotBeforeUpdate(h,a),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Uu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ef(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ef(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(s(163))}if(e=t.sibling,e!==null){e.return=t.return,$c=e;break}$c=t.return}}function tl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:gl(e,n),r&4&&Ic(5,n);break;case 1:if(gl(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Uu(n,n.return,e)}else{var i=Vs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Uu(n,n.return,e)}}r&64&&Rc(n),r&512&&Bc(n,n.return);break;case 3:if(gl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Ua(e,t)}catch(e){Uu(n,n.return,e)}}break;case 27:t===null&&r&4&&Jc(n);case 26:case 5:gl(e,n),t===null&&r&4&&Hc(n),r&512&&Bc(n,n.return);break;case 12:gl(e,n);break;case 31:gl(e,n),r&4&&sl(e,n);break;case 13:gl(e,n),r&4&&cl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=qu.bind(null,n),sf(e,n))));break;case 22:if(r=n.memoizedState!==null||Yc,!r){t=t!==null&&t.memoizedState!==null||Xc,i=Yc;var a=Xc;Yc=r,(Xc=t)&&!a?vl(e,n,(n.subtreeFlags&8772)!=0):gl(e,n),Yc=i,Xc=a}break;case 30:break;default:gl(e,n)}}function nl(e){var t=e.alternate;t!==null&&(e.alternate=null,nl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&lt(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 rl=null,il=!1;function al(e,t,n){for(n=n.child;n!==null;)ol(e,t,n),n=n.sibling}function ol(e,t,n){if(Ae&&typeof Ae.onCommitFiberUnmount==`function`)try{Ae.onCommitFiberUnmount(ke,n)}catch{}switch(n.tag){case 26:Xc||Vc(n,t),al(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:Xc||Vc(n,t);var r=rl,i=il;Zd(n.type)&&(rl=n.stateNode,il=!1),al(e,t,n),pf(n.stateNode),rl=r,il=i;break;case 5:Xc||Vc(n,t);case 6:if(r=rl,i=il,rl=null,al(e,t,n),rl=r,il=i,rl!==null)if(il)try{(rl.nodeType===9?rl.body:rl.nodeName===`HTML`?rl.ownerDocument.body:rl).removeChild(n.stateNode)}catch(e){Uu(n,t,e)}else try{rl.removeChild(n.stateNode)}catch(e){Uu(n,t,e)}break;case 18:rl!==null&&(il?(e=rl,Qd(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Np(e)):Qd(rl,n.stateNode));break;case 4:r=rl,i=il,rl=n.stateNode.containerInfo,il=!0,al(e,t,n),rl=r,il=i;break;case 0:case 11:case 14:case 15:Lc(2,n,t),Xc||Lc(4,n,t),al(e,t,n);break;case 1:Xc||(Vc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&zc(n,t,r)),al(e,t,n);break;case 21:al(e,t,n);break;case 22:Xc=(r=Xc)||n.memoizedState!==null,al(e,t,n),Xc=r;break;default:al(e,t,n)}}function sl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Np(e)}catch(e){Uu(t,t.return,e)}}}function cl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Np(e)}catch(e){Uu(t,t.return,e)}}function ll(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Qc),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Qc),t;default:throw Error(s(435,e.tag))}}function ul(e,t){var n=ll(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ju.bind(null,e,t);t.then(r,r)}})}function dl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r],a=e,o=t,c=o;a:for(;c!==null;){switch(c.tag){case 27:if(Zd(c.type)){rl=c.stateNode,il=!1;break a}break;case 5:rl=c.stateNode,il=!1;break a;case 3:case 4:rl=c.stateNode.containerInfo,il=!0;break a}c=c.return}if(rl===null)throw Error(s(160));ol(a,o,i),rl=null,il=!1,a=i.alternate,a!==null&&(a.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)pl(t,e),t=t.sibling}var fl=null;function pl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:dl(t,e),ml(e),r&4&&(Lc(3,e,e.return),Ic(3,e),Lc(5,e,e.return));break;case 1:dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),r&64&&Yc&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var i=fl;if(dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),r&4){var a=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,i=i.ownerDocument||i;b:switch(r){case`title`:a=i.getElementsByTagName(`title`)[0],(!a||a[ct]||a[tt]||a.namespaceURI===`http://www.w3.org/2000/svg`||a.hasAttribute(`itemprop`))&&(a=i.createElement(r),i.head.insertBefore(a,i.querySelector(`head > title`))),Pd(a,r,n),a[tt]=e,mt(a),r=a;break a;case`link`:var o=Vf(`link`,`href`,i).get(r+(n.href||``));if(o){for(var c=0;c<o.length;c++)if(a=o[c],a.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&a.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&a.getAttribute(`title`)===(n.title==null?null:n.title)&&a.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){o.splice(c,1);break b}}a=i.createElement(r),Pd(a,r,n),i.head.appendChild(a);break;case`meta`:if(o=Vf(`meta`,`content`,i).get(r+(n.content||``))){for(c=0;c<o.length;c++)if(a=o[c],a.getAttribute(`content`)===(n.content==null?null:``+n.content)&&a.getAttribute(`name`)===(n.name==null?null:n.name)&&a.getAttribute(`property`)===(n.property==null?null:n.property)&&a.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&a.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){o.splice(c,1);break b}}a=i.createElement(r),Pd(a,r,n),i.head.appendChild(a);break;default:throw Error(s(468,r))}a[tt]=e,mt(a),r=a}e.stateNode=r}else Hf(i,e.type,e.stateNode);else e.stateNode=If(i,r,e.memoizedProps);else a===r?r===null&&e.stateNode!==null&&Uc(e,e.memoizedProps,n.memoizedProps):(a===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):a.count--,r===null?Hf(i,e.type,e.stateNode):If(i,r,e.memoizedProps))}break;case 27:dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),n!==null&&r&4&&Uc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(dl(t,e),ml(e),r&512&&(Xc||n===null||Vc(n,n.return)),e.flags&32){i=e.stateNode;try{Bt(i,``)}catch(t){Uu(e,e.return,t)}}r&4&&e.stateNode!=null&&(i=e.memoizedProps,Uc(e,i,n===null?i:n.memoizedProps)),r&1024&&(Zc=!0);break;case 6:if(dl(t,e),ml(e),r&4){if(e.stateNode===null)throw Error(s(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Uu(e,e.return,t)}}break;case 3:if(Bf=null,i=fl,fl=gf(t.containerInfo),dl(t,e),fl=i,ml(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Np(t.containerInfo)}catch(t){Uu(e,e.return,t)}Zc&&(Zc=!1,hl(e));break;case 4:r=fl,fl=gf(e.stateNode.containerInfo),dl(t,e),ml(e),fl=r;break;case 12:dl(t,e),ml(e);break;case 31:dl(t,e),ml(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 13:dl(t,e),ml(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Zl=xe()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 22:i=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=Yc,d=Xc;if(Yc=u||i,Xc=d||l,dl(t,e),Xc=d,Yc=u,ml(e),r&8192)a:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||l||Yc||Xc||_l(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(a=l.stateNode,i)o=a.style,typeof o.setProperty==`function`?o.setProperty(`display`,`none`,`important`):o.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Uu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=i?``:l.memoizedProps}catch(e){Uu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;i?$d(m,!0):$d(l.stateNode,!1)}catch(e){Uu(l,l.return,e)}}}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 a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,ul(e,n))));break;case 19:dl(t,e),ml(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ul(e,r)));break;case 30:break;case 21:break;default:dl(t,e),ml(e)}}function ml(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Wc(r)){n=r;break}r=r.return}if(n==null)throw Error(s(160));switch(n.tag){case 27:var i=n.stateNode;qc(e,Gc(e),i);break;case 5:var a=n.stateNode;n.flags&32&&(Bt(a,``),n.flags&=-33),qc(e,Gc(e),a);break;case 3:case 4:var o=n.stateNode.containerInfo;Kc(e,Gc(e),o);break;default:throw Error(s(161))}}catch(t){Uu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function hl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;hl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function gl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)tl(e,t.alternate,t),t=t.sibling}function _l(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Lc(4,t,t.return),_l(t);break;case 1:Vc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&zc(t,t.return,n),_l(t);break;case 27:pf(t.stateNode);case 26:case 5:Vc(t,t.return),_l(t);break;case 22:t.memoizedState===null&&_l(t);break;case 30:_l(t);break;default:_l(t)}e=e.sibling}}function vl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:vl(i,a,n),Ic(4,a);break;case 1:if(vl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Uu(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ha(c[i],s)}catch(e){Uu(r,r.return,e)}}n&&o&64&&Rc(a),Bc(a,a.return);break;case 27:Jc(a);case 26:case 5:vl(i,a,n),n&&r===null&&o&4&&Hc(a),Bc(a,a.return);break;case 12:vl(i,a,n);break;case 31:vl(i,a,n),n&&o&4&&sl(i,a);break;case 13:vl(i,a,n),n&&o&4&&cl(i,a);break;case 22:a.memoizedState===null&&vl(i,a,n),Bc(a,a.return);break;case 30:break;default:vl(i,a,n)}t=t.sibling}}function yl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&ta(n))}function bl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ta(e))}function xl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Sl(e,t,n,r),t=t.sibling}function Sl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:xl(e,t,n,r),i&2048&&Ic(9,t);break;case 1:xl(e,t,n,r);break;case 3:xl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ta(e)));break;case 12:if(i&2048){xl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Uu(t,t.return,e)}}else xl(e,t,n,r);break;case 31:xl(e,t,n,r);break;case 13:xl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?xl(e,t,n,r):(a._visibility|=2,Cl(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?xl(e,t,n,r):wl(e,t),i&2048&&yl(o,t);break;case 24:xl(e,t,n,r),i&2048&&bl(t.alternate,t);break;default:xl(e,t,n,r)}}function Cl(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Cl(a,o,s,c,i),Ic(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Cl(a,o,s,c,i)):u._visibility&2?Cl(a,o,s,c,i):wl(a,o),i&&l&2048&&yl(o.alternate,o);break;case 24:Cl(a,o,s,c,i),i&&l&2048&&bl(o.alternate,o);break;default:Cl(a,o,s,c,i)}t=t.sibling}}function wl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:wl(n,r),i&2048&&yl(r.alternate,r);break;case 24:wl(n,r),i&2048&&bl(r.alternate,r);break;default:wl(n,r)}t=t.sibling}}var Tl=8192;function El(e,t,n){if(e.subtreeFlags&Tl)for(e=e.child;e!==null;)Dl(e,t,n),e=e.sibling}function Dl(e,t,n){switch(e.tag){case 26:El(e,t,n),e.flags&Tl&&e.memoizedState!==null&&Gf(n,fl,e.memoizedState,e.memoizedProps);break;case 5:El(e,t,n);break;case 3:case 4:var r=fl;fl=gf(e.stateNode.containerInfo),El(e,t,n),fl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Tl,Tl=16777216,El(e,t,n),Tl=r):El(e,t,n));break;default:El(e,t,n)}}function Ol(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 kl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];$c=r,Ml(r,e)}Ol(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Al(e),e=e.sibling}function Al(e){switch(e.tag){case 0:case 11:case 15:kl(e),e.flags&2048&&Lc(9,e,e.return);break;case 3:kl(e);break;case 12:kl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,jl(e)):kl(e);break;default:kl(e)}}function jl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];$c=r,Ml(r,e)}Ol(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Lc(8,t,t.return),jl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,jl(t));break;default:jl(t)}e=e.sibling}}function Ml(e,t){for(;$c!==null;){var n=$c;switch(n.tag){case 0:case 11:case 15:Lc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:ta(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,$c=r;else a:for(n=e;$c!==null;){r=$c;var i=r.sibling,a=r.return;if(nl(r),r===n){$c=null;break a}if(i!==null){i.return=a,$c=i;break a}$c=a}}}var Nl={getCacheForType:function(e){var t=qi($i),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return qi($i).controller.signal}},Pl=typeof WeakMap==`function`?WeakMap:Map,X=0,Fl=null,Z=null,Q=0,Il=0,Ll=null,Rl=!1,zl=!1,Bl=!1,Vl=0,Hl=0,Ul=0,Wl=0,Gl=0,Kl=0,ql=0,Jl=null,Yl=null,Xl=!1,Zl=0,Ql=0,$l=1/0,eu=null,tu=null,nu=0,ru=null,iu=null,au=0,ou=0,su=null,cu=null,lu=0,uu=null;function du(){return X&2&&Q!==0?Q&-Q:I.T===null?Qe():ud()}function fu(){if(Kl===0)if(!(Q&536870912)||q){var e=Le;Le<<=1,!(Le&3932160)&&(Le=262144),Kl=e}else Kl=536870912;return e=Ya.current,e!==null&&(e.flags|=32),Kl}function pu(e,t,n){(e===Fl&&(Il===2||Il===9)||e.cancelPendingCommit!==null)&&(bu(e,0),_u(e,Q,Kl,!1)),Ge(e,n),(!(X&2)||e!==Fl)&&(e===Fl&&(!(X&2)&&(Wl|=n),Hl===4&&_u(e,Q,Kl,!1)),nd(e))}function mu(e,t,n){if(X&6)throw Error(s(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Ve(e,t),i=r?Ou(e,t):Eu(e,t,!0),a=r;do{if(i===0){zl&&!r&&_u(e,t,0,!1);break}else{if(n=e.current.alternate,a&&!gu(n)){i=Eu(e,t,!1),a=!1;continue}if(i===2){if(a=t,e.errorRecoveryDisabledLanes&a)var o=0;else o=e.pendingLanes&-536870913,o=o===0?o&536870912?536870912:0:o;if(o!==0){t=o;a:{var c=e;i=Jl;var l=c.current.memoizedState.isDehydrated;if(l&&(bu(c,o).flags|=256),o=Eu(c,o,!1),o!==2){if(Bl&&!l){c.errorRecoveryDisabledLanes|=a,Wl|=a,i=4;break a}a=Yl,Yl=i,a!==null&&(Yl===null?Yl=a:Yl.push.apply(Yl,a))}i=o}if(a=!1,i!==2)continue}}if(i===1){bu(e,0),_u(e,t,0,!0);break}a:{switch(r=e,a=i,a){case 0:case 1:throw Error(s(345));case 4:if((t&4194048)!==t)break;case 6:_u(r,t,Kl,!Rl);break a;case 2:Yl=null;break;case 3:case 5:break;default:throw Error(s(329))}if((t&62914560)===t&&(i=Zl+300-xe(),10<i)){if(_u(r,t,Kl,!Rl),Be(r,0,!0)!==0)break a;au=t,r.timeoutHandle=Kd(hu.bind(null,r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,a,`Throttled`,-0,0),i);break a}hu(r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,a,null,-0,0)}}break}while(1);nd(e)}function hu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Jt},Dl(t,a,d);var m=(a&62914560)===a?Zl-xe():(a&4194048)===a?Ql-xe():0;if(m=qf(d,m),m!==null){au=a,e.cancelPendingCommit=m(Fu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),_u(e,a,o,!l);return}}Fu(e,t,a,n,r,i,o,s,c)}function gu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!mr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;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 _u(e,t,n,r){t&=~Gl,t&=~Wl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Me(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&qe(e,n,t)}function vu(){return X&6?!0:(rd(0,!1),!1)}function yu(){if(Z!==null){if(Il===0)var e=Z.return;else e=Z,zi=Ri=null,Co(e),wa=null,Ta=0,e=Z;for(;e!==null;)Fc(e.alternate,e),e=e.return;Z=null}}function bu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,qd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),au=0,yu(),Fl=e,Z=n=ni(e.current,null),Q=t,Il=0,Ll=null,Rl=!1,zl=Ve(e,t),Bl=!1,ql=Kl=Gl=Wl=Ul=Hl=0,Yl=Jl=null,Xl=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Me(r),a=1<<i;t|=e[i],r&=~a}return Vl=t,Kr(),n}function xu(e,t){J=null,I.H=Ns,t===ma||t===ga?(t=Sa(),Il=3):t===ha?(t=Sa(),Il=4):Il=t===Xs?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Ll=t,Z===null&&(Hl=1,Gs(e,ui(t,e.current)))}function Su(){var e=Ya.current;return e===null?!0:(Q&4194048)===Q?Xa===null:(Q&62914560)===Q||Q&536870912?e===Xa:!1}function Cu(){var e=I.H;return I.H=Ns,e===null?Ns:e}function wu(){var e=I.A;return I.A=Nl,e}function Tu(){Hl=4,Rl||(Q&4194048)!==Q&&Ya.current!==null||(zl=!0),!(Ul&134217727)&&!(Wl&134217727)||Fl===null||_u(Fl,Q,Kl,!1)}function Eu(e,t,n){var r=X;X|=2;var i=Cu(),a=wu();(Fl!==e||Q!==t)&&(eu=null,bu(e,t)),t=!1;var o=Hl;a:do try{if(Il!==0&&Z!==null){var s=Z,c=Ll;switch(Il){case 8:yu(),o=6;break a;case 3:case 2:case 9:case 6:Ya.current===null&&(t=!0);var l=Il;if(Il=0,Ll=null,Mu(e,s,c,l),n&&zl){o=0;break a}break;default:l=Il,Il=0,Ll=null,Mu(e,s,c,l)}}Du(),o=Hl;break}catch(t){xu(e,t)}while(1);return t&&e.shellSuspendCounter++,zi=Ri=null,X=r,I.H=i,I.A=a,Z===null&&(Fl=null,Q=0,Kr()),o}function Du(){for(;Z!==null;)Au(Z)}function Ou(e,t){var n=X;X|=2;var r=Cu(),i=wu();Fl!==e||Q!==t?(eu=null,$l=xe()+500,bu(e,t)):zl=Ve(e,t);a:do try{if(Il!==0&&Z!==null){t=Z;var a=Ll;b:switch(Il){case 1:Il=0,Ll=null,Mu(e,t,a,1);break;case 2:case 9:if(va(a)){Il=0,Ll=null,ju(t);break}t=function(){Il!==2&&Il!==9||Fl!==e||(Il=7),nd(e)},a.then(t,t);break a;case 3:Il=7;break a;case 4:Il=5;break a;case 7:va(a)?(Il=0,Ll=null,ju(t)):(Il=0,Ll=null,Mu(e,t,a,7));break;case 5:var o=null;switch(Z.tag){case 26:o=Z.memoizedState;case 5:case 27:var c=Z;if(o?Wf(o):c.stateNode.complete){Il=0,Ll=null;var l=c.sibling;if(l!==null)Z=l;else{var u=c.return;u===null?Z=null:(Z=u,Nu(u))}break b}}Il=0,Ll=null,Mu(e,t,a,5);break;case 6:Il=0,Ll=null,Mu(e,t,a,6);break;case 8:yu(),Hl=6;break a;default:throw Error(s(462))}}ku();break}catch(t){xu(e,t)}while(1);return zi=Ri=null,I.H=r,I.A=i,X=n,Z===null?(Fl=null,Q=0,Kr(),Hl):0}function ku(){for(;Z!==null&&!ye();)Au(Z)}function Au(e){var t=Ec(e.alternate,e,Vl);e.memoizedProps=e.pendingProps,t===null?Nu(e):Z=t}function ju(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=uc(n,t,t.pendingProps,t.type,void 0,Q);break;case 11:t=uc(n,t,t.pendingProps,t.type.render,t.ref,Q);break;case 5:Co(t);default:Fc(n,t),t=Z=ri(t,Vl),t=Ec(n,t,Vl)}e.memoizedProps=e.pendingProps,t===null?Nu(e):Z=t}function Mu(e,t,n,r){zi=Ri=null,Co(t),wa=null,Ta=0;var i=t.return;try{if(Ys(e,i,t,n,Q)){Hl=1,Gs(e,ui(n,e.current)),Z=null;return}}catch(t){if(i!==null)throw Z=i,t;Hl=1,Gs(e,ui(n,e.current)),Z=null;return}t.flags&32768?(q||r===1?e=!0:zl||Q&536870912?e=!1:(Rl=e=!0,(r===2||r===9||r===3||r===6)&&(r=Ya.current,r!==null&&r.tag===13&&(r.flags|=16384))),Pu(t,e)):Nu(t)}function Nu(e){var t=e;do{if(t.flags&32768){Pu(t,Rl);return}e=t.return;var n=Nc(t.alternate,t,Vl);if(n!==null){Z=n;return}if(t=t.sibling,t!==null){Z=t;return}Z=t=e}while(t!==null);Hl===0&&(Hl=5)}function Pu(e,t){do{var n=Pc(e.alternate,e);if(n!==null){n.flags&=32767,Z=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Z=e;return}Z=e=n}while(e!==null);Hl=6,Z=null}function Fu(e,t,n,r,i,a,o,c,l){e.cancelPendingCommit=null;do Bu();while(nu!==0);if(X&6)throw Error(s(327));if(t!==null){if(t===e.current)throw Error(s(177));if(a=t.lanes|t.childLanes,a|=Gr,Ke(e,n,a,o,c,l),e===Fl&&(Z=Fl=null,Q=0),iu=t,ru=e,au=n,ou=a,su=i,cu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Yu(Te,function(){return Vu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=I.T,I.T=null,i=L.p,L.p=2,o=X,X|=4;try{el(e,t,n)}finally{X=o,L.p=i,I.T=r}}nu=1,Iu(),Lu(),Ru()}}function Iu(){if(nu===1){nu=0;var e=ru,t=iu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=I.T,I.T=null;var r=L.p;L.p=2;var i=X;X|=4;try{pl(t,e);var a=zd,o=yr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&vr(s.ownerDocument.documentElement,s)){if(c!==null&&br(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=_r(s,h),v=_r(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}sp=!!Rd,zd=Rd=null}finally{X=i,L.p=r,I.T=n}}e.current=t,nu=2}}function Lu(){if(nu===2){nu=0;var e=ru,t=iu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=I.T,I.T=null;var r=L.p;L.p=2;var i=X;X|=4;try{tl(e,t.alternate,t)}finally{X=i,L.p=r,I.T=n}}nu=3}}function Ru(){if(nu===4||nu===3){nu=0,be();var e=ru,t=iu,n=au,r=cu;t.subtreeFlags&10256||t.flags&10256?nu=5:(nu=0,iu=ru=null,zu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(tu=null),Ze(n),t=t.stateNode,Ae&&typeof Ae.onCommitFiberRoot==`function`)try{Ae.onCommitFiberRoot(ke,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=I.T,i=L.p,L.p=2,I.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{I.T=t,L.p=i}}au&3&&Bu(),nd(e),i=e.pendingLanes,n&261930&&i&42?e===uu?lu++:(lu=0,uu=e):lu=0,rd(0,!1)}}function zu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ta(t)))}function Bu(){return Iu(),Lu(),Ru(),Vu()}function Vu(){if(nu!==5)return!1;var e=ru,t=ou;ou=0;var n=Ze(au),r=I.T,i=L.p;try{L.p=32>n?32:n,I.T=null,n=su,su=null;var a=ru,o=au;if(nu=0,iu=ru=null,au=0,X&6)throw Error(s(331));var c=X;if(X|=4,Al(a.current),Sl(a,a.current,o,n),X=c,rd(0,!1),Ae&&typeof Ae.onPostCommitFiberRoot==`function`)try{Ae.onPostCommitFiberRoot(ke,a)}catch{}return!0}finally{L.p=i,I.T=r,zu(e,t)}}function Hu(e,t,n){t=ui(n,t),t=Ks(e.stateNode,t,2),e=Ia(e,t,2),e!==null&&(Ge(e,2),nd(e))}function Uu(e,t,n){if(e.tag===3)Hu(e,e,n);else for(;t!==null;){if(t.tag===3){Hu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(tu===null||!tu.has(r))){e=ui(n,e),n=qs(2),r=Ia(t,n,2),r!==null&&(Js(n,r,t,e),Ge(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Pl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Bl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Fl===e&&(Q&n)===n&&(Hl===4||Hl===3&&(Q&62914560)===Q&&300>xe()-Zl?!(X&2)&&bu(e,0):Gl|=n,ql===Q&&(ql=0)),nd(e)}function Ku(e,t){t===0&&(t=Ue()),e=Yr(e,t),e!==null&&(Ge(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(s(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return _e(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Me(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Q,a=Be(r,r===Fl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Ve(r,a)||(n=!0,cd(r,a));r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Gd()&&(e=td);for(var t=xe(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}nu!==0&&nu!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Me(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=He(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Fl,n=Q,n=Be(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Il===2||Il===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&ve(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Ve(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&ve(r),Ze(n)){case 2:case 8:n=we;break;case 32:n=Te;break;case 268435456:n=Ee;break;default:n=Te}return r=sd.bind(null,e),n=_e(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&ve(r),e.callbackPriority=2,e.callbackNode=null,2}function sd(e,t){if(nu!==0&&nu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Bu()&&e.callbackNode!==n)return null;var r=Q;return r=Be(e,e===Fl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(mu(e,r,t),od(e,xe()),e.callbackNode!=null&&e.callbackNode===n?sd.bind(null,e):null)}function cd(e,t){if(Bu())return null;mu(e,t,!0)}function ld(){Yd(function(){X&6?_e(Ce,id):ad()})}function ud(){if(td===0){var e=ia;e===0&&(e=Ie,Ie<<=1,!(Ie&261888)&&(Ie=256)),td=e}return td}function dd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:qt(``+e)}function fd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function pd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=dd((i[nt]||null).action),o=r.submitter;o&&(t=(t=o[nt]||null)?dd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new gn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(td!==0){var e=o?fd(i,o):new FormData(i);ys(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?fd(i,o):new FormData(i),ys(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var md=0;md<Br.length;md++){var hd=Br[md];Vr(hd.toLowerCase(),`on`+(hd[0].toUpperCase()+hd.slice(1)))}Vr(Mr,`onAnimationEnd`),Vr(Nr,`onAnimationIteration`),Vr(Pr,`onAnimationStart`),Vr(`dblclick`,`onDoubleClick`),Vr(`focusin`,`onFocus`),Vr(`focusout`,`onBlur`),Vr(Fr,`onTransitionRun`),Vr(Ir,`onTransitionStart`),Vr(Lr,`onTransitionCancel`),Vr(Rr,`onTransitionEnd`),vt(`onMouseEnter`,[`mouseout`,`mouseover`]),vt(`onMouseLeave`,[`mouseout`,`mouseover`]),vt(`onPointerEnter`,[`pointerout`,`pointerover`]),vt(`onPointerLeave`,[`pointerout`,`pointerover`]),_t(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),_t(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),_t(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),_t(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),_t(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),_t(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var gd=`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(` `),_d=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(gd));function vd(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Hr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Hr(e)}i.currentTarget=null,a=c}}}}function $(e,t){var n=t[it];n===void 0&&(n=t[it]=new Set);var r=e+`__bubble`;n.has(r)||(Sd(t,e,2,!1),n.add(r))}function yd(e,t,n){var r=0;t&&(r|=4),Sd(n,e,r,t)}var bd=`_reactListening`+Math.random().toString(36).slice(2);function xd(e){if(!e[bd]){e[bd]=!0,ht.forEach(function(t){t!==`selectionchange`&&(_d.has(t)||yd(t,!1,e),yd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[bd]||(t[bd]=!0,yd(`selectionchange`,!1,t))}}function Sd(e,t,n,r){switch(mp(t)){case 2:var i=cp;break;case 8:i=lp;break;default:i=up}n=i.bind(null,t,n,e),i=void 0,!an||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Cd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var s=r.stateNode.containerInfo;if(s===i)break;if(o===4)for(o=r.return;o!==null;){var c=o.tag;if((c===3||c===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;s!==null;){if(o=ut(s),o===null)return;if(c=o.tag,c===5||c===6||c===26||c===27){r=a=o;continue a}s=s.parentNode}}r=r.return}tn(function(){var r=a,i=Xt(n),o=[];a:{var s=zr.get(e);if(s!==void 0){var c=gn,u=e;switch(e){case`keypress`:if(dn(n)===0)break a;case`keydown`:case`keyup`:c=G;break;case`focusin`:u=`focus`,c=Tn;break;case`focusout`:u=`blur`,c=Tn;break;case`beforeblur`:case`afterblur`:c=Tn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:c=Cn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:c=wn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:c=Pn;break;case Mr:case Nr:case Pr:c=En;break;case Rr:c=Fn;break;case`scroll`:case`scrollend`:c=vn;break;case`wheel`:c=In;break;case`copy`:case`cut`:case`paste`:c=Dn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:c=Nn;break;case`toggle`:case`beforetoggle`:c=Ln}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?s===null?null:s+`Capture`:s;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=nn(m,p),g!=null&&d.push(wd(m,g,h))),f)break;m=m.return}0<d.length&&(s=new c(s,u,null,n,i),o.push({event:s,listeners:d}))}}if(!(t&7)){a:{if(s=e===`mouseover`||e===`pointerover`,c=e===`mouseout`||e===`pointerout`,s&&n!==Yt&&(u=n.relatedTarget||n.fromElement)&&(ut(u)||u[rt]))break a;if((c||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,c?(u=n.relatedTarget||n.toElement,c=r,u=u?ut(u):null,u!==null&&(f=l(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(c=null,u=r),c!==u)){if(d=Cn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Nn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=c==null?s:ft(c),h=u==null?s:ft(u),s=new d(g,m+`leave`,c,n,i),s.target=f,s.relatedTarget=h,g=null,ut(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,c&&u)b:{for(d=Ed,p=c,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;c!==null&&Dd(o,s,c,d,!1),u!==null&&f!==null&&Dd(o,f,u,d,!0)}}a:{if(s=r?ft(r):window,c=s.nodeName&&s.nodeName.toLowerCase(),c===`select`||c===`input`&&s.type===`file`)var v=nr;else if(Xn(s))if(rr)v=fr;else{v=ur;var y=lr}else c=s.nodeName,!c||c.toLowerCase()!==`input`||s.type!==`checkbox`&&s.type!==`radio`?r&&Wt(r.elementType)&&(v=nr):v=dr;if(v&&=v(e,r)){Zn(o,v,n,i);break a}y&&y(e,s,r),e===`focusout`&&r&&s.type===`number`&&r.memoizedProps.value!=null&&It(s,`number`,s.value)}switch(y=r?ft(r):window,e){case`focusin`:(Xn(y)||y.contentEditable===`true`)&&(Sr=y,Cr=r,wr=null);break;case`focusout`:wr=Cr=Sr=null;break;case`mousedown`:Tr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Tr=!1,Er(o,n,i);break;case`selectionchange`:if(xr)break;case`keydown`:case`keyup`:Er(o,n,i)}var b;if(Rn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else Kn?Wn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Vn&&n.locale!==`ko`&&(Kn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Kn&&(b=un()):(sn=i,cn=`value`in sn?sn.value:sn.textContent,Kn=!0)),y=Td(r,x),0<y.length&&(x=new On(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=Gn(n),b!==null&&(x.data=b)))),(b=Bn?qn(e,n):Jn(e,n))&&(x=Td(r,`onBeforeInput`),0<x.length&&(y=new On(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),pd(o,e,r,n,i)}vd(o,t)})}function wd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Td(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=nn(e,n),i!=null&&r.unshift(wd(e,i,a)),i=nn(e,t),i!=null&&r.push(wd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ed(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Dd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=nn(n,a),l!=null&&o.unshift(wd(n,l,c))):i||(l=nn(n,a),l!=null&&o.push(wd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Od=/\r\n?/g,kd=/\u0000|\uFFFD/g;function Ad(e){return(typeof e==`string`?e:``+e).replace(Od,`
9
+ `).replace(kd,``)}function jd(e,t){return t=Ad(t),Ad(e)===t}function Md(e,t,n,r,i,a){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Bt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Bt(e,``+r);break;case`className`:wt(e,`class`,r);break;case`tabIndex`:wt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:wt(e,n,r);break;case`style`:Ut(e,r,a);break;case`data`:if(t!==`object`){wt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=qt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`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 a==`function`&&(n===`formAction`?(t!==`input`&&Md(e,t,`name`,i.name,i,null),Md(e,t,`formEncType`,i.formEncType,i,null),Md(e,t,`formMethod`,i.formMethod,i,null),Md(e,t,`formTarget`,i.formTarget,i,null)):(Md(e,t,`encType`,i.encType,i,null),Md(e,t,`method`,i.method,i,null),Md(e,t,`target`,i.target,i,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=qt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Jt);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(s(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=qt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);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`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:$(`beforetoggle`,e),$(`toggle`,e),Ct(e,`popover`,r);break;case`xlinkActuate`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Tt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Tt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Ct(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=Gt.get(n)||n,Ct(e,n,r))}}function Nd(e,t,n,r,i,a){switch(n){case`style`:Ut(e,r,a);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(s(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Bt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Bt(e,``+r);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Jt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!gt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(i=n.endsWith(`Capture`),t=n.slice(2,i?n.length-7:void 0),a=e[nt]||null,a=a==null?null:a[n],typeof a==`function`&&e.removeEventListener(t,a,i),typeof r==`function`)){typeof a!=`function`&&a!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,i);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Ct(e,n,r)}}}function Pd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:$(`error`,e),$(`load`,e);var r=!1,i=!1,a;for(a in n)if(n.hasOwnProperty(a)){var o=n[a];if(o!=null)switch(a){case`src`:r=!0;break;case`srcSet`:i=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(s(137,t));default:Md(e,t,a,o,n,null)}}i&&Md(e,t,`srcSet`,n.srcSet,n,null),r&&Md(e,t,`src`,n.src,n,null);return;case`input`:$(`invalid`,e);var c=a=o=i=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:i=d;break;case`type`:o=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:a=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(s(137,t));break;default:Md(e,t,r,d,n,null)}}Ft(e,a,c,l,u,o,i,!1);return;case`select`:for(i in $(`invalid`,e),r=o=a=null,n)if(n.hasOwnProperty(i)&&(c=n[i],c!=null))switch(i){case`value`:a=c;break;case`defaultValue`:o=c;break;case`multiple`:r=c;default:Md(e,t,i,c,n,null)}t=a,n=o,e.multiple=!!r,t==null?n!=null&&Lt(e,!!r,n,!0):Lt(e,!!r,t,!1);return;case`textarea`:for(o in $(`invalid`,e),a=i=r=null,n)if(n.hasOwnProperty(o)&&(c=n[o],c!=null))switch(o){case`value`:r=c;break;case`defaultValue`:i=c;break;case`children`:a=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(s(91));break;default:Md(e,t,o,c,n,null)}zt(e,r,i,a);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Md(e,t,l,r,n,null)}return;case`dialog`:$(`beforetoggle`,e),$(`toggle`,e),$(`cancel`,e),$(`close`,e);break;case`iframe`:case`object`:$(`load`,e);break;case`video`:case`audio`:for(r=0;r<gd.length;r++)$(gd[r],e);break;case`image`:$(`error`,e),$(`load`,e);break;case`details`:$(`toggle`,e);break;case`embed`:case`source`:case`link`:$(`error`,e),$(`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(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(s(137,t));default:Md(e,t,u,r,n,null)}return;default:if(Wt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Nd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Md(e,t,c,r,n,null))}function Fd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var i=null,a=null,o=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Md(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:a=m;break;case`name`:i=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:o=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(s(137,t));break;default:m!==f&&Md(e,t,p,m,r,f)}}Pt(e,o,c,l,u,d,a,i);return;case`select`:for(a in m=o=c=p=null,n)if(l=n[a],n.hasOwnProperty(a)&&l!=null)switch(a){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(a)||Md(e,t,a,null,r,l)}for(i in r)if(a=r[i],l=n[i],r.hasOwnProperty(i)&&(a!=null||l!=null))switch(i){case`value`:p=a;break;case`defaultValue`:c=a;break;case`multiple`:o=a;default:a!==l&&Md(e,t,i,a,r,l)}t=c,n=o,r=m,p==null?!!r!=!!n&&(t==null?Lt(e,!!n,n?[]:``,!1):Lt(e,!!n,t,!0)):Lt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(i=n[c],n.hasOwnProperty(c)&&i!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Md(e,t,c,null,r,i)}for(o in r)if(i=r[o],a=n[o],r.hasOwnProperty(o)&&(i!=null||a!=null))switch(o){case`value`:p=i;break;case`defaultValue`:m=i;break;case`children`:break;case`dangerouslySetInnerHTML`:if(i!=null)throw Error(s(91));break;default:i!==a&&Md(e,t,o,i,r,a)}Rt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Md(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Md(e,t,l,p,r,m)}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 g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Md(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(s(137,t));break;default:Md(e,t,u,p,r,m)}return;default:if(Wt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Nd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Nd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Md(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Md(e,t,f,p,r,m)}function Id(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Ld(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Id(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.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 Rd=null,zd=null;function Bd(e){return e.nodeType===9?e:e.ownerDocument}function Vd(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 Hd(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 Ud(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 Wd=null;function Gd(){var e=window.event;return e&&e.type===`popstate`?e===Wd?!1:(Wd=e,!0):(Wd=null,!1)}var Kd=typeof setTimeout==`function`?setTimeout:void 0,qd=typeof clearTimeout==`function`?clearTimeout:void 0,Jd=typeof Promise==`function`?Promise:void 0,Yd=typeof queueMicrotask==`function`?queueMicrotask:Jd===void 0?Kd:function(e){return Jd.resolve(null).then(e).catch(Xd)};function Xd(e){setTimeout(function(){throw e})}function Zd(e){return e===`head`}function Qd(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Np(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)pf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,pf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ct]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&pf(e.ownerDocument.body);n=i}while(n);Np(t)}function $d(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function ef(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ef(n),lt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function tf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[ct])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=cf(e.nextSibling),e===null)break}return null}function nf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=cf(e.nextSibling),e===null))return null;return e}function rf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=cf(e.nextSibling),e===null))return null;return e}function af(e){return e.data===`$?`||e.data===`$~`}function of(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function sf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function cf(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 lf=null;function uf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return cf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function df(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function ff(e,t,n){switch(t=Bd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(s(452));return e;case`head`:if(e=t.head,!e)throw Error(s(453));return e;case`body`:if(e=t.body,!e)throw Error(s(454));return e;default:throw Error(s(451))}}function pf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);lt(e)}var mf=new Map,hf=new Set;function gf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var _f=L.d;L.d={f:vf,r:yf,D:Sf,C:Cf,L:wf,m:Tf,X:Df,S:Ef,M:Of};function vf(){var e=_f.f(),t=vu();return e||t}function yf(e){var t=dt(e);t!==null&&t.tag===5&&t.type===`form`?xs(t):_f.r(e)}var bf=typeof document>`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Nt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Nt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Nt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Nt(n.imageSizes)+`"]`)):i+=`[href="`+Nt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Nt(r)+`"][href="`+Nt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=h({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),mt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=pt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);mt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=re.current)?gf(i):null;if(!i)throw Error(s(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=pt(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var a=pt(i).hoistableStyles,o=a.get(e);if(o||(i=i.ownerDocument||i,o={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},a.set(e,o),(a=i.querySelector(jf(e)))&&!a._p&&(o.instance=a,o.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),a||Nf(i,e,n,o.state))),t&&r===null)throw Error(s(528,``));return o}if(t&&r!==null)throw Error(s(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=pt(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(s(444,e))}}function Af(e){return`href="`+Nt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),mt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Nt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Nt(n.href)+`"]`);if(r)return t.instance=r,mt(r),r;var i=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),mt(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var a=e.querySelector(jf(i));if(a)return t.state.loading|=4,t.instance=a,mt(a),a;r=Mf(n),(i=mf.get(i))&&Rf(r,i),a=(e.ownerDocument||e).createElement(`link`),mt(a);var o=a;return o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),t.state.loading|=4,Lf(a,n.precedence,e),t.instance=a;case`script`:return a=Pf(n.src),(i=e.querySelector(Ff(a)))?(t.instance=i,mt(i),i):(r=n,(i=mf.get(a))&&(r=h({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),mt(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(s(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Rf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Bf=null;function Vf(e,t,n){if(Bf===null){var r=new Map,i=Bf=new Map;i.set(n,r)}else i=Bf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ct]||a[tt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Hf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Uf(e,t,n){if(n===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 Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,mt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),mt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Kf===0&&(Kf=62500*Ld());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Jf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var Qf={$$typeof:C,Provider:null,Consumer:null,_currentValue:R,_currentValue2:R,_threadCount:0};function $f(e,t,n,r,i,a,o,s,c){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=We(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=We(0),this.hiddenUpdates=We(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ep(e,t,n,r,i,a,o,s,c,l,u,d){return e=new $f(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ei(3,null,null,t),e.current=a,a.stateNode=e,t=ea(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Na(a),e}function tp(e){return e?(e=Qr,e):Qr}function np(e,t,n,r,i,a){i=tp(i),r.context===null?r.context=i:r.pendingContext=i,r=Fa(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ia(e,r,t),n!==null&&(pu(n,e,t),La(n,e,t))}function rp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function ip(e,t){rp(e,t),(e=e.alternate)&&rp(e,t)}function ap(e){if(e.tag===13||e.tag===31){var t=Yr(e,67108864);t!==null&&pu(t,e,67108864),ip(e,67108864)}}function op(e){if(e.tag===13||e.tag===31){var t=du();t=Xe(t);var n=Yr(e,t);n!==null&&pu(n,e,t),ip(e,t)}}var sp=!0;function cp(e,t,n,r){var i=I.T;I.T=null;var a=L.p;try{L.p=2,up(e,t,n,r)}finally{L.p=a,I.T=i}}function lp(e,t,n,r){var i=I.T;I.T=null;var a=L.p;try{L.p=8,up(e,t,n,r)}finally{L.p=a,I.T=i}}function up(e,t,n,r){if(sp){var i=dp(r);if(i===null)Cd(e,t,r,fp,n),Cp(e,r);else if(Tp(i,e,t,n,r))r.stopPropagation();else if(Cp(e,r),t&4&&-1<Sp.indexOf(e)){for(;i!==null;){var a=dt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=ze(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Me(o);s.entanglements[1]|=c,o&=~c}nd(a),!(X&6)&&($l=xe()+500,rd(0,!1))}}break;case 31:case 13:s=Yr(a,2),s!==null&&pu(s,a,2),vu(),ip(a,2)}if(a=dp(r),a===null&&Cd(e,t,r,fp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Cd(e,t,r,null,n)}}function dp(e){return e=Xt(e),pp(e)}var fp=null;function pp(e){if(fp=null,e=ut(e),e!==null){var t=l(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=u(t),e!==null)return e;e=null}else if(n===31){if(e=d(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return fp=e,null}function mp(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(Se()){case Ce:return 2;case we:return 8;case Te:case U:return 32;case Ee:return 268435456;default:return 32}default:return 32}}var hp=!1,gp=null,_p=null,vp=null,yp=new Map,bp=new Map,xp=[],Sp=`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 Cp(e,t){switch(e){case`focusin`:case`focusout`:gp=null;break;case`dragenter`:case`dragleave`:_p=null;break;case`mouseover`:case`mouseout`:vp=null;break;case`pointerover`:case`pointerout`:yp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:bp.delete(t.pointerId)}}function wp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=dt(t),t!==null&&ap(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Tp(e,t,n,r,i){switch(t){case`focusin`:return gp=wp(gp,e,t,n,r,i),!0;case`dragenter`:return _p=wp(_p,e,t,n,r,i),!0;case`mouseover`:return vp=wp(vp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return yp.set(a,wp(yp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,bp.set(a,wp(bp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ep(e){var t=ut(e.target);if(t!==null){var n=l(t);if(n!==null){if(t=n.tag,t===13){if(t=u(n),t!==null){e.blockedOn=t,$e(e.priority,function(){op(n)});return}}else if(t===31){if(t=d(n),t!==null){e.blockedOn=t,$e(e.priority,function(){op(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Dp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=dp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Yt=r,n.target.dispatchEvent(r),Yt=null}else return t=dt(n),t!==null&&ap(t),e.blockedOn=n,!1;t.shift()}return!0}function Op(e,t,n){Dp(e)&&n.delete(t)}function kp(){hp=!1,gp!==null&&Dp(gp)&&(gp=null),_p!==null&&Dp(_p)&&(_p=null),vp!==null&&Dp(vp)&&(vp=null),yp.forEach(Op),bp.forEach(Op)}function Ap(e,n){e.blockedOn===n&&(e.blockedOn=null,hp||(hp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,kp)))}var jp=null;function Mp(e){jp!==e&&(jp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){jp===e&&(jp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(pp(r||n)===null)continue;break}var a=dt(n);a!==null&&(e.splice(t,3),t-=3,ys(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Np(e){function t(t){return Ap(t,e)}gp!==null&&Ap(gp,e),_p!==null&&Ap(_p,e),vp!==null&&Ap(vp,e),yp.forEach(t),bp.forEach(t);for(var n=0;n<xp.length;n++){var r=xp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<xp.length&&(n=xp[0],n.blockedOn===null);)Ep(n),n.blockedOn===null&&xp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[nt]||null;if(typeof a==`function`)o||Mp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[nt]||null)s=o.formAction;else if(pp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Mp(n)}}}function Pp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Fp(e){this._internalRoot=e}Ip.prototype.render=Fp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(s(409));var n=t.current;np(n,du(),e,t,null,null)},Ip.prototype.unmount=Fp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;np(e.current,2,null,e,null,null),vu(),t[rt]=null}};function Ip(e){this._internalRoot=e}Ip.prototype.unstable_scheduleHydration=function(e){if(e){var t=Qe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<xp.length&&t!==0&&t<xp[n].priority;n++);xp.splice(n,0,e),n===0&&Ep(e)}};var Lp=r.version;if(Lp!==`19.2.8`)throw Error(s(527,Lp,`19.2.8`));L.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(s(188)):(e=Object.keys(e).join(`,`),Error(s(268,e)));return e=p(t),e=e===null?null:m(e),e=e===null?null:e.stateNode,e};var Rp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:I,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var zp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!zp.isDisabled&&zp.supportsFiber)try{ke=zp.inject(Rp),Ae=zp}catch{}}e.createRoot=function(e,t){if(!c(e))throw Error(s(299));var n=!1,r=``,i=Hs,a=Us,o=Ws;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(a=t.onCaughtError),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=ep(e,1,!1,null,null,n,r,null,i,a,o,Pp),e[rt]=t.current,xd(e),new Fp(t)}})),c=e(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=s()})),l=i(),u=c(),d=new Map([{family:`Bebas Neue`,fallback:`sans-serif`,weights:`400`},{family:`Crimson Text`,fallback:`serif`,weights:`400;600;700`},{family:`DM Sans`,fallback:`sans-serif`,weights:`100..1000`},{family:`Fira Sans`,fallback:`sans-serif`,weights:`100;200;300;400;500;600;700;800;900`},{family:`Inter`,fallback:`sans-serif`,weights:`100..900`},{family:`JetBrains Mono`,fallback:`monospace`,weights:`100..800`},{family:`Josefin Sans`,fallback:`sans-serif`,weights:`100..700`},{family:`Karla`,fallback:`sans-serif`,weights:`200..800`},{family:`Lato`,fallback:`sans-serif`,weights:`100;300;400;700;900`},{family:`Lora`,fallback:`serif`,weights:`400..700`},{family:`Manrope`,fallback:`sans-serif`,weights:`200..800`},{family:`Merriweather`,fallback:`serif`,weights:`300..900`},{family:`Montserrat`,fallback:`sans-serif`,weights:`100..900`},{family:`Nunito`,fallback:`sans-serif`,weights:`200..1000`},{family:`Open Sans`,fallback:`sans-serif`,weights:`300..800`},{family:`Oswald`,fallback:`sans-serif`,weights:`200..700`},{family:`Outfit`,fallback:`sans-serif`,weights:`100..900`},{family:`Playfair Display`,fallback:`serif`,weights:`400..900`},{family:`Poppins`,fallback:`sans-serif`,weights:`100;200;300;400;500;600;700;800;900`},{family:`Quicksand`,fallback:`sans-serif`,weights:`300..700`},{family:`Raleway`,fallback:`sans-serif`,weights:`100..900`},{family:`Roboto`,fallback:`sans-serif`,weights:`100..900`},{family:`Rubik`,fallback:`sans-serif`,weights:`300..900`},{family:`Source Sans 3`,fallback:`sans-serif`,weights:`200..900`},{family:`Space Grotesk`,fallback:`sans-serif`,weights:`300..700`},{family:`Work Sans`,fallback:`sans-serif`,weights:`100..900`}].map(e=>[e.family,e])),f=e=>`"${e.family}", ${e.fallback}`,p=e=>{let t=d.get(e)?.weights;return`family=${e.replace(/ /g,`+`)}${t?`:wght@${t}`:``}`};function m(e){return e.length?`https://fonts.googleapis.com/css2?${e.map(p).join(`&`)}&display=swap`:null}var h=e=>m([e]),g=e=>{let t=typeof e==`string`&&e.match(/^"([^"]+)"/);return t?t[1]:null},_=e=>{let t=d.get(e);return t?f(t):null};function v(e,t){let n=new Set,r=e=>{for(let t of Object.values(e||{}))for(let e of[`style`,`hover`,`pressed`,`focused`]){let r=g(t.props?.[e]?.fontFamily);r&&n.add(r)}};r(e);for(let e of Object.values(t||{}))r(e.template?.nodes);return[...n].sort()}var y=[`linear`,`ease`,`ease-in`,`ease-out`,`ease-in-out`,`spring`];function b(e){let t=1-Math.min(100,Math.max(0,Number(e)||0))/100*.85,n=Math.log(1e3)/t,r=e=>{if(t>=1)return 1-(1+n*e)*Math.exp(-n*e);let r=n*Math.sqrt(1-t*t);return 1-Math.exp(-t*n*e)*(Math.cos(r*e)+t*n/r*Math.sin(r*e))},i=[];for(let e=0;e<=40;e+=1)i.push(e===40?1:Math.round(r(e/40)*1e3)/1e3);return`linear(${i.join(`,`)})`}var x=e=>{let t=String(e??``).trim();if(!t)return null;let n=Number(t);return Number.isFinite(n)?n:null};function S(e){let t=[],n=[],r=x(e?.opacity),i=x(e?.x),a=x(e?.y),o=x(e?.scale),s=x(e?.rotate),c=x(e?.blur);return r!==null&&t.push(`opacity: ${r}`),i!==null&&n.push(`translateX(${i}px)`),a!==null&&n.push(`translateY(${a}px)`),o!==null&&n.push(`scale(${o})`),s!==null&&n.push(`rotate(${s}deg)`),n.length&&t.push(`transform: ${n.join(` `)}`),c!==null&&t.push(`filter: blur(${c}px)`),t.join(`; `)}var C=e=>`wb-anim-${String(e).replace(/[^\w-]/g,``)}`,w=e=>`--wb-anim-${String(e).replace(/[^\w-]/g,``)}`,T=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches;function E(e,t,{offset:n=0}={}){if(!e||!Array.isArray(t)||T())return;let r=window.getComputedStyle(e),i=t.map(e=>r.getPropertyValue(w(e)).trim()).filter(Boolean);if(!i.length)return;e.style.animation=`none`,e.offsetWidth,e.style.animation=i.join(`, `);let a=Math.max(0,Number(n)||0);if(a>0){let t=window.getComputedStyle(e).animationDelay.split(`,`).map(e=>parseFloat(e)*(e.trim().endsWith(`ms`)?1:1e3)||0);e.style.animationDelay=t.map(e=>`${e+a}ms`).join(`, `)}}var D=[`entry`,`cover`,`exit`],O=()=>typeof CSS<`u`&&typeof CSS.supports==`function`&&CSS.supports(`animation-timeline: view()`),k=(e,t)=>{let n=x(e);return n===null?t:Math.min(100,Math.max(0,n))};function A(e,t){let n=k(t?.start,0),r=Math.max(n,k(t?.end,100));if(e===`page`)return`${n}% ${r}%`;let i=D.includes(t?.phase)?t.phase:`entry`;return`${i} ${n}% ${i} ${r}%`}var j=[`animation-name`,`animation-duration`,`animation-timing-function`,`animation-delay`,`animation-iteration-count`,`animation-fill-mode`,`animation-timeline`,`animation-range`];function M(e,t,{timeline:n,range:r}){if(!e||!Array.isArray(t)||T())return()=>{};let i=window.getComputedStyle(e),a=t.map(e=>i.getPropertyValue(w(e)).trim().split(/\s+/)).filter(e=>e[0]);if(!a.length)return()=>{};let o=j.map(t=>e.style.getPropertyValue(t)),s=e=>a.map(()=>e).join(`, `);return e.style.setProperty(`animation-name`,a.map(e=>e[0]).join(`, `)),e.style.setProperty(`animation-duration`,s(`auto`)),e.style.setProperty(`animation-timing-function`,a.map(e=>e[2]||`linear`).join(`, `)),e.style.setProperty(`animation-delay`,s(`0s`)),e.style.setProperty(`animation-iteration-count`,s(`1`)),e.style.setProperty(`animation-fill-mode`,s(`both`)),e.style.setProperty(`animation-timeline`,s(n)),e.style.setProperty(`animation-range`,s(r)),()=>j.forEach((t,n)=>{o[n]?e.style.setProperty(t,o[n]):e.style.removeProperty(t)})}function N(e){for(let t=e.parentElement;t;t=t.parentElement){let{overflowY:e}=window.getComputedStyle(t);if(/(auto|scroll|overlay)/.test(e)&&t.scrollHeight>t.clientHeight)return t}return null}function P(e,t,n){if(T())return()=>{};let r=M(e,t,{timeline:`auto`,range:`normal`}),i=String(e.style.getPropertyValue(`animation-name`)).split(`,`).map(e=>e.trim()),a=1e3;e.style.setProperty(`animation-duration`,i.map(()=>`${a}ms`).join(`, `)),e.style.setProperty(`animation-play-state`,i.map(()=>`paused`).join(`, `));let o=typeof e.getAnimations==`function`?e.getAnimations().filter(e=>i.includes(e.animationName)):[];if(!o.length)return e.style.removeProperty(`animation-play-state`),r(),()=>{};let s=N(e),c=k(n?.start,0),l=Math.max(c+.001,k(n?.end,100)),u=D.includes(n?.phase)?n.phase:`entry`,d=()=>{if(n?.kind===`page`){let e=s??document.scrollingElement??document.documentElement,t=e.scrollHeight-e.clientHeight;return t>0?e.scrollTop/t*100:0}let t=e.getBoundingClientRect(),r=typeof DOMMatrixReadOnly==`function`?new DOMMatrixReadOnly(window.getComputedStyle(e).transform===`none`?void 0:window.getComputedStyle(e).transform).m42:0,i=e.offsetHeight||t.height,a={top:t.top+t.height/2-r-i/2,height:i},o=s?.getBoundingClientRect(),c=s?{top:o.top+s.clientTop,bottom:o.top+s.clientTop+s.clientHeight}:{top:0,bottom:window.innerHeight},[l,d]={entry:[c.bottom,c.bottom-a.height],exit:[c.top,c.top-a.height],cover:[c.bottom,c.top-a.height]}[u];return(l-a.top)/Math.max(1,l-d)*100},f=0,p=()=>{f=0;let e=Math.min(1,Math.max(0,(d()-c)/(l-c)));o.forEach(t=>{t.currentTime=e*a*.9999})},m=()=>{f||=requestAnimationFrame(p)};return p(),document.addEventListener(`scroll`,m,{capture:!0,passive:!0}),window.addEventListener(`resize`,m),()=>{f&&cancelAnimationFrame(f),document.removeEventListener(`scroll`,m,{capture:!0}),window.removeEventListener(`resize`,m),e.style.removeProperty(`animation-play-state`),r()}}function F(e){return Array.isArray(e)?e.map(e=>{let t=String(e?.id??``).replace(/[^\w-]/g,``);if(!t)return``;let n=C(t),r=S(e.from),i=S(e.to);if(!r&&!i)return``;let a=Math.max(0,x(e.duration)??400),o=Math.max(0,x(e.delay)??0),s=e.easing===`spring`,c=s?b(e.bounce??30):y.includes(e.easing)?e.easing:`ease-out`,l=e.loop?`infinite`:`1`,u=e=>`${n} ${a}ms ${e} ${o}ms ${l} both`,d=u(c);return[`@keyframes ${n} { from { ${r} } to { ${i} } }`,`:root { ${w(t)}: ${d}; }`,`.${n} { animation: ${d}; }`,...s?[`@supports not (animation-timing-function: linear(0, 1)) { :root { ${w(t)}: ${u(`ease-out`)}; } .${n} { animation: ${u(`ease-out`)}; } }`]:[]].join(`
10
10
  `)}).filter(Boolean).concat(e.length?[`@media (prefers-reduced-motion: reduce) { [class*="wb-anim-"] { animation: none !important; } }`]:[]).join(`
11
11
  `):``}var I=new Set(`marginTop.marginRight.marginBottom.marginLeft.paddingTop.paddingRight.paddingBottom.paddingLeft.gap.rowGap.columnGap.flexBasis.fontSize.borderRadius.borderTopLeftRadius.borderTopRightRadius.borderBottomRightRadius.borderBottomLeftRadius.borderWidth.borderTopWidth.borderRightWidth.borderBottomWidth.borderLeftWidth.letterSpacing.textDecorationThickness.textUnderlineOffset.top.right.bottom.left`.split(`.`)),L=e=>typeof e==`number`||typeof e==`string`&&e.trim()!==``&&!Number.isNaN(Number(e))?`${Number(e)}px`:e,R=[`borderWidth`,`borderStyle`,`borderColor`,`borderRadius`,`gap`];function z(e){let t={};for(let n of R){let r=e?.[n];r!=null&&r!==``&&(t[n]=I.has(n)?L(r):r)}for(let[n,r]of Object.entries(e||{}))r==null||r===``||R.includes(n)||(t[n]=I.has(n)?L(r):r);let{gradientType:n,gradientAngle:r,gradientFrom:i,gradientTo:a}=t;delete t.gradientType,delete t.gradientAngle,delete t.gradientFrom,delete t.gradientTo;let{textShadows:o,textShadowX:s,textShadowY:c,textShadowBlur:l,textShadowColor:u}=t;delete t.textShadows,delete t.textShadowX,delete t.textShadowY,delete t.textShadowBlur,delete t.textShadowColor;let d=(Array.isArray(o)?o:[]).filter(e=>e&&e.on!==!1).map(e=>`${L(e.x??0)} ${L(e.y??0)} ${L(e.blur??0)} ${e.color||`rgba(0, 0, 0, 0.35)`}`);[s,c,l,u].some(e=>e!==void 0)&&d.push(`${L(s??0)} ${L(c??0)} ${L(l??0)} ${u||`rgba(0, 0, 0, 0.35)`}`),d.length&&(t.textShadow=d.join(`, `));let f=e=>typeof e==`number`||!Number.isNaN(Number(e))?`${Number(e)}deg`:e,p=e=>e.type===`move`?`translate(${L(e.x??0)}, ${L(e.y??0)})`:e.type===`scale`?`scale(${e.v??1})`:e.type===`rotate`?`rotate(${f(e.a??0)})`:e.type===`skew`?`skew(${f(e.x??0)}, ${f(e.y??0)})`:null,{transforms:m,translateX:h,translateY:g,scale:_,rotate:v,skewX:y,skewY:b}=t;delete t.transforms,delete t.translateX,delete t.translateY,delete t.scale,delete t.rotate,delete t.skewX,delete t.skewY;let x=(Array.isArray(m)?m:[]).filter(e=>e&&e.on!==!1).map(p).filter(Boolean);(h!==void 0||g!==void 0)&&x.push(`translate(${L(h??0)}, ${L(g??0)})`),_!==void 0&&x.push(`scale(${_})`),v!==void 0&&x.push(`rotate(${f(v)})`),(y!==void 0||b!==void 0)&&x.push(`skew(${f(y??0)}, ${f(b??0)})`),x.length&&(t.transform=x.join(` `));let S=e=>`${e.inset?`inset `:``}${L(e.x??0)} ${L(e.y??0)} ${L(e.blur??0)} ${L(e.spread??0)} ${e.color||`rgba(15, 23, 42, 0.2)`}`,{shadows:C,boxShadowX:w,boxShadowY:T,boxShadowBlur:E,boxShadowSpread:D,boxShadowColor:O,boxShadowInset:k}=t;delete t.shadows,delete t.boxShadowX,delete t.boxShadowY,delete t.boxShadowBlur,delete t.boxShadowSpread,delete t.boxShadowColor,delete t.boxShadowInset;let A=(Array.isArray(C)?C:[]).filter(e=>e&&e.on!==!1).map(S);[w,T,E,D,O,k].some(e=>e!==void 0)&&A.push(S({x:w,y:T,blur:E,spread:D,color:O,inset:k})),A.length&&(t.boxShadow=A.join(`, `));let j=e=>e.type===`blur`?`blur(${L(e.v??0)})`:e.type===`hue-rotate`?`hue-rotate(${f(e.v??0)})`:`${e.type}(${e.v??100}%)`,M=e=>(Array.isArray(e)?e:[]).filter(e=>e&&e.on!==!1&&e.type).map(j),{filters:N,backdropFilters:P,filterBlur:F,filterGrayscale:z,filterBrightness:ee,filterContrast:te,filterSaturate:B}=t;delete t.filters,delete t.backdropFilters,delete t.filterBlur,delete t.filterGrayscale,delete t.filterBrightness,delete t.filterContrast,delete t.filterSaturate;let V=M(N);F!==void 0&&V.push(`blur(${L(F)})`),z!==void 0&&V.push(`grayscale(${z}%)`),ee!==void 0&&V.push(`brightness(${ee}%)`),te!==void 0&&V.push(`contrast(${te}%)`),B!==void 0&&V.push(`saturate(${B}%)`),V.length&&(t.filter=V.join(` `));let H=M(P);H.length&&(t.backdropFilter=H.join(` `),t.WebkitBackdropFilter=t.backdropFilter);let{textStrokeWidth:ne,textStrokeColor:re}=t;delete t.textStrokeWidth,delete t.textStrokeColor,(ne!==void 0||re!==void 0)&&(t.WebkitTextStroke=`${L(ne??1)} ${re||`currentColor`}`);let{clipText:ie}=t;delete t.clipText,ie&&(t.WebkitBackgroundClip=`text`,t.backgroundClip=`text`,t.WebkitTextFillColor=`transparent`);let{transitions:ae,transitionDuration:oe,transitionEasing:se,transitionProperty:ce}=t,le=e=>typeof e==`number`||!Number.isNaN(Number(e))?`${Number(e)}ms`:e;delete t.transitions,delete t.transitionDuration,delete t.transitionEasing,delete t.transitionProperty;let ue=(Array.isArray(ae)?ae:[]).filter(e=>e&&e.on!==!1).map(e=>`${e.property||`all`} ${le(e.duration??200)} ${e.easing||`ease`}`);if(oe!==void 0&&ue.push(`${ce||`all`} ${le(oe)} ${se||`ease`}`),ue.length&&(t.transition=ue.join(`, `)),t.textDecoration!==void 0&&(t.textDecorationLine=t.textDecoration,delete t.textDecoration),t.backgroundImage&&!String(t.backgroundImage).includes(`(`)&&(t.backgroundImage=`url("${t.backgroundImage}")`),n){let e=`${i||`rgba(0,0,0,0.5)`}, ${a||`transparent`}`,o=n===`radial`?`radial-gradient(circle, ${e})`:`linear-gradient(${r??180}deg, ${e})`;t.backgroundImage=t.backgroundImage?`${o}, ${t.backgroundImage}`:o}delete t.backgroundVideo;let{overlayColor:de,overlayOpacity:fe}=t;if(delete t.overlayColor,delete t.overlayOpacity,de){let e=`color-mix(in srgb, ${de} ${fe??50}%, transparent)`,n=`linear-gradient(${e}, ${e})`;t.backgroundImage=t.backgroundImage?`${n}, ${t.backgroundImage}`:n}t.backgroundImage&&(t.backgroundSize??=`cover`,t.backgroundPosition??=`center`,t.backgroundRepeat??=`no-repeat`);let{backgroundLayers:pe}=t;delete t.backgroundLayers;let me=(Array.isArray(pe)?pe:[]).filter(e=>e&&e.on!==!1);if(me.length){let e=[],n=[],r=[],i=[],a=[];for(let t of me)if(t.kind===`linear`)e.push(`linear-gradient(${t.angle??180}deg, ${t.from||`rgba(0,0,0,0.5)`}, ${t.to||`transparent`})`),n.push(`auto`),r.push(`0% 0%`),i.push(`repeat`),a.push(`scroll`);else if(t.kind===`radial`)e.push(`radial-gradient(circle, ${t.from||`rgba(0,0,0,0.5)`}, ${t.to||`transparent`})`),n.push(`auto`),r.push(`0% 0%`),i.push(`repeat`),a.push(`scroll`);else{if(!t.src)continue;e.push(`url("${t.src}")`),n.push(t.size===`custom`?`${L(t.w??`auto`)} ${L(t.h??`auto`)}`:t.size||`cover`),r.push(`${L(t.posX??0)} ${L(t.posY??0)}`),i.push(t.repeat||`no-repeat`),a.push(t.fixed?`fixed`:`scroll`)}e.length&&(t.backgroundImage&&(e.push(t.backgroundImage),n.push(t.backgroundSize||`cover`),r.push(t.backgroundPosition||`center`),i.push(t.backgroundRepeat||`no-repeat`),a.push(`scroll`)),t.backgroundImage=e.join(`, `),t.backgroundSize=n.join(`, `),t.backgroundPosition=r.join(`, `),t.backgroundRepeat=i.join(`, `),t.backgroundAttachment=a.join(`, `))}return t}var ee={hover:`:hover`,pressed:`:active`,focused:`:focus`},te=new Set([`style`,`class`,`id`,`data-wb`,`data-wb-class`,`data-slot`]),B=e=>/^[a-zA-Z_][\w-]*$/.test(e)&&!/^on/i.test(e)&&!te.has(e.toLowerCase()),V=e=>[...new Set(String(e??``).split(/\s+/).map(e=>e.replace(/^\./,``)).filter(e=>/^-?[_a-zA-Z][\w-]*$/.test(e)))],H=[`click`,`dblclick`,`mouseenter`,`mouseleave`,`mousemove`,`focus`,`blur`,`input`,`change`,`submit`,`keydown`,`inview`,`scrollview`],ne=[`load`,`pagescroll`,`scrollpage`],re={scrollview:`view`,scrollpage:`page`},ie=[...H,...ne],ae=/^[A-Za-z_$][\w$]*$/;function oe(e,t){let n=String(t??``).trim();if(!n)return[e];let r=e.closest?.(`.webim-page`)??e.closest?.(`.builder-canvas`)??document,i=/^[A-Za-z_][\w-]*$/.test(n)?[`#${n}`,n]:[n];for(let e of i)try{let t=Array.from(r.querySelectorAll(e));if(t.length)return t}catch{return[]}return[]}function se(e,t){for(let t of[...e.__webimEvents??[]].reverse())t();let n=[];for(let r of t??[]){let t=String(r?.event??``),i=r?.action===`animation`,a=e=>(Array.isArray(e?.animations)?e.animations:[e?.animation]).map(e=>String(e??``).trim()).filter(Boolean),o=i?(Array.isArray(r?.steps)&&r.steps.length?r.steps:[r]).map(e=>({ids:a(e),target:e?.target,delay:Math.max(0,Number(e?.delay)||0),stagger:Math.max(0,Number(e?.stagger)||0)})).filter(e=>e.ids.length):[],s=o.flatMap(e=>e.ids),c=i?``:String(r?.handler??``).trim();if(!ie.includes(t)||(i?!s.length:!ae.test(c)))continue;if(re[t]){if(!i)continue;let a=re[t];if(O()){let t=a===`page`?`scroll(nearest block)`:`view(block)`,i=A(a,r);for(let r of o)for(let a of oe(e,r.target))n.push(M(a,r.ids,{timeline:t,range:i}))}else for(let t of o)for(let i of oe(e,t.target))n.push(P(i,t.ids,{kind:a,phase:r.phase,start:r.start,end:r.end}));continue}let l=t=>{if(i){for(let t of o)oe(e,t.target).forEach((e,n)=>{E(e,t.ids,{offset:t.delay+n*t.stagger})});return}let n=window[c];typeof n==`function`&&n.call(e,t)};if(t===`inview`){if(typeof IntersectionObserver>`u`)continue;let t=new IntersectionObserver(e=>{for(let n of e)n.isIntersecting&&(t.disconnect(),l(n))});t.observe(e),n.push(()=>t.disconnect())}else if(t===`load`)if(document.readyState===`complete`){let e=setTimeout(l,0);n.push(()=>clearTimeout(e))}else window.addEventListener(`load`,l,{once:!0}),n.push(()=>window.removeEventListener(`load`,l));else t===`pagescroll`?(document.addEventListener(`scroll`,l,{capture:!0,passive:!0}),n.push(()=>document.removeEventListener(`scroll`,l,{capture:!0}))):(e.addEventListener(t,l),n.push(()=>e.removeEventListener(t,l)))}e.__webimEvents=n}function ce(e,t,n=[]){t.htmlId?e.id=t.htmlId:e.removeAttribute(`id`);let r=V(t.classNames),i=V(e.getAttribute(`data-wb-class`));for(let t of i)r.includes(t)||e.classList.remove(t);for(let t of r)e.classList.add(t);r.length?e.setAttribute(`data-wb-class`,r.join(` `)):e.removeAttribute(`data-wb-class`);for(let t of n)e.removeAttribute(t);let a=[];for(let n of t.attributes??[]){let t=String(n?.name??``).trim();B(t)&&(e.setAttribute(t,n.value??``),a.push(t))}return a}var le=e=>e.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`);function ue(e,t=``){return[`[data-wb="${e}"]:not([data-wb-redirect])${t}`,`[data-wb="${e}"][data-wb-redirect] [data-wb-self]:not([data-wb="${e}"] [data-wb] [data-wb-self])${t}`].join(`, `)}function de(e,t,n,r=!1){let i=Object.entries(z(t)).map(([e,t])=>`${le(e)}: ${t} !important;`).join(` `);return i?`${ue(e,r?``:n)} { ${i} }`:``}var fe=e=>/^[a-z][a-z0-9-]{0,39}$/.test(String(e??``));function pe(e,t,n=``){return`[data-wb="${e}"] [data-wb-part~="${t}"]:not([data-wb="${e}"] [data-wb] [data-wb-part])${n}`}function me(e){let t=e?.partStyles;if(t&&typeof t==`object`&&!Array.isArray(t))return t;let n=e?.parts;return n&&typeof n==`object`&&!Array.isArray(n)?n:{}}var he=e=>Object.entries(me(e)).filter(([e,t])=>fe(e)&&t&&typeof t==`object`).sort(([e],[t])=>e.split(`-`).length-t.split(`-`).length);function ge(e,t,n,r=``,i=!1){let a=Object.entries(z(n)).map(([e,t])=>`${le(e)}: ${t} !important;`).join(` `);return a?`${pe(e,t,i?``:r)} { ${a} }`:``}function _e(e,t,n,r){return he(t).flatMap(([t,i])=>[ge(e,t,i.style),...Object.entries(ee).map(([a,o])=>ge(e,t,i[a],o,n===a&&r===t))]).filter(Boolean).join(`
12
12
  `)}function ve(e,t,n){return[...Object.entries(ee).map(([r,i])=>de(e,t?.[r],i,n===r)),_e(e,t)].filter(Boolean).join(`
@@ -15,13 +15,13 @@ Error generating stack: `+e.message+`
15
15
  `)}function Ce(e,t){let n=[],r=e=>{for(let[t,r]of Object.entries(e||{})){let e=ve(t,r.props);e&&n.push(e)}};r(e);for(let e of Object.values(t||{}))r(e.template?.nodes);return n.join(`
16
16
  `)}var we=`:where(.webim-page, .wb-artboard) :where([data-wb-link]) { color: var(--page-link, inherit); text-decoration-line: var(--page-link-decoration, underline); }
17
17
  :where(.webim-page, .wb-artboard) :where([data-wb-link]):hover { color: var(--page-link-hover, var(--page-link, inherit)); text-decoration-line: var(--page-link-hover-decoration, underline); }`,Te=`-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`,U={fontFamily:Te,fontStyle:`normal`,fontWeight:400,letterSpacing:`normal`,textTransform:`none`,lineHeight:1.4,textShadow:`none`},Ee={light:{background:`#f2f2f2`,surface:`#f2f2f2`,border:`#d1d5db`,text:`#111827`,accent:`#111827`,accentText:`#ffffff`,link:``,linkHover:``,primary:{light:`#4b5563`,main:`#111827`,dark:`#030712`,contrastText:`#ffffff`},secondary:{light:`#a5b4fc`,main:`#6366f1`,dark:`#4338ca`,contrastText:`#ffffff`}},dark:{background:`#0f172a`,surface:`#1e293b`,border:`rgba(226, 232, 240, 0.18)`,text:`#e2e8f0`,accent:`#6366f1`,accentText:`#ffffff`,link:``,linkHover:``,primary:{light:`#a5b4fc`,main:`#6366f1`,dark:`#4338ca`,contrastText:`#ffffff`},secondary:{light:`#5eead4`,main:`#14b8a6`,dark:`#0f766e`,contrastText:`#052e2b`}}},De={h1:40,h2:32,h3:26,h4:22,h5:19,h6:16},Oe=[`always`,`hover`,`never`],ke={font:`system`,headingFont:`inherit`,headings:De,bodySize:16,light:Ee.light,dark:Ee.dark},Ae={system:{label:`System`,value:Te},inter:{label:`Inter`,value:`"Inter", ${Te}`},outfit:{label:`Outfit`,value:`"Outfit", ${Te}`},serif:{label:`Serif`,value:`Georgia, "Times New Roman", serif`},mono:{label:`Mono`,value:`ui-monospace, SFMono-Regular, Menlo, Consolas, monospace`}},je=(e,t)=>Ae[e]?.value??_(e)??(typeof e==`string`&&e.trim()?`"${e.trim()}", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`:t),Me=(e,...t)=>{let n=Object.assign({},e,...t);return n.primary={...e.primary,...t.reduce((e,t)=>({...e,...t?.primary}),{})},n.secondary={...e.secondary,...t.reduce((e,t)=>({...e,...t?.secondary}),{})},n};function Ne(e){let{light:t,dark:n,font:r,headingFont:i,headings:a,bodySize:o,linkUnderline:s,responsive:c,...l}=e??{};return{font:r??ke.font,headingFont:i??ke.headingFont,headings:{...De,...a??{}},bodySize:o??16,linkUnderline:Oe.includes(s)?s:`always`,responsive:Le(c),light:Me(Ee.light,l,t),dark:Me(Ee.dark,n)}}function Pe(e){return{"--page-bg":e.background,"--page-surface":e.surface??e.background,"--page-border":e.border??Ee.light.border,"--page-text":e.text,"--page-accent":e.accent,"--page-accent-text":e.accentText,"--page-link":e.link||e.accent,"--page-link-hover":e.linkHover||e.link||e.accent,"--page-primary-light":e.primary.light,"--page-primary":e.primary.main,"--page-primary-dark":e.primary.dark,"--page-primary-contrast":e.primary.contrastText,"--page-secondary-light":e.secondary.light,"--page-secondary":e.secondary.main,"--page-secondary-dark":e.secondary.dark,"--page-secondary-contrast":e.secondary.contrastText}}function Fe(e){let t=Ne(e);return{backgroundColor:`var(--page-bg)`,color:`var(--page-text)`,fontFamily:je(t.font,Te),"--page-heading-font":t.headingFont===`inherit`?`inherit`:je(t.headingFont,`inherit`),...Ve(t.headings),"--page-body-size":Be(t.bodySize,16),"--page-link-decoration":t.linkUnderline===`always`?`underline`:`none`,"--page-link-hover-decoration":t.linkUnderline===`never`?`none`:`underline`}}var Ie=e=>e!==``&&e!=null;function Le(e){let t={};for(let{key:n}of ye){let r=e?.[n];if(!r||typeof r!=`object`)continue;let i={};for(let e of Object.keys(De))Ie(r.headings?.[e])&&(i[e]=r.headings[e]);let a={...Ie(r.bodySize)?{bodySize:r.bodySize}:null,...Object.keys(i).length?{headings:i}:null};Object.keys(a).length&&(t[n]=a)}return t}function Re(e){let t={};Ie(e?.bodySize)&&(t[`--page-body-size`]=Be(e.bodySize,16));for(let n of Object.keys(De))Ie(e?.headings?.[n])&&(t[`--page-${n}`]=Be(e.headings[n],De[n]));return t}function ze(e){let t=Ne(e);return ye.map(({key:e,max:n})=>{let r=Object.entries(Re(t.responsive[e]));return r.length?`@media (max-width: ${n}px) { .webim-page { ${r.map(([e,t])=>`${e}: ${t} !important;`).join(` `)} } }`:``}).filter(Boolean).join(`
18
- `)}function Be(e,t){return e===``||e==null?`${t}px`:isNaN(Number(e))?String(e):`${Number(e)}px`}function Ve(e){let t={};for(let n of Object.keys(De)){let r=e?.[n]??De[n];t[`--page-${n}`]=Be(r,De[n])}return t}function He(e,t=`light`){let n=Ne(e);return{...Fe(e),...Pe(n[t]??n.light)}}function Ue(e,t){return e?.themeRef&&t?.[e.themeRef]||e?.theme}function We(e,t){return e===`light`||e===`dark`?e:t===`light`||t===`dark`?t:`auto`}function Ge({page:e,settings:t,tenant:n,apiUrl:r,locale:i}){let a={...t?.global??{},...t?.tenant??{}},o=e.meta??{};return{schema:1,title:e.title,slug:e.slug,param:e.param??``,blocks:i&&o.i18n?.[i]?.blocks||e.blocks,theme:Ue(o,a.builder_themes?.themes),components:a.builder_components?.components??{},custom:o.custom,animations:o.animations,seo:o.seo,direction:o.direction,scheme:o.scheme,locale:i||a.locales?.default,locales:a.locales,tenant:n??``,apiUrl:r??``,settings:a}}var Ke=async e=>{let t=await e.json().catch(()=>null);if(!e.ok||t?.success===!1)throw Error(t?.error?.message||`Request failed (${e.status})`);return t?.payload??t};async function qe({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a,page:o,fetch:s}){if(!e)throw Error(`fetchPage: apiUrl is required`);if(!n)throw Error(`fetchPage: slug is required`);let c=s??fetch,l=e.replace(/\/$/,``),u={...t?{"x-tenant":t}:{},...a?{authorization:`Bearer ${a}`}:{}},[d,f]=await Promise.all([c(`${l}/render/${encodeURIComponent(n)}${i?`?preview=${encodeURIComponent(i)}`:``}`,{headers:u}).then(Ke),c(`${l}/settings/public`,{headers:u}).then(Ke)]),p=Ge({page:d,settings:f,tenant:t,apiUrl:l,locale:r}),m=[...new Set(Je(p.blocks,p.components).map(e=>e?.type?.resolvedName===`CollectionList`?e.props?.collection:[`TableBlock`,`OrgChartBlock`,`NavbarBlock`,`MenuTreeBlock`,`CalendarBlock`,`MasonryBlock`,`LogoCarousel`].includes(e?.type?.resolvedName)?e.props?.source:null).filter(Boolean))];if(m.length){let e=e=>e.startsWith(`api:`)?`${l}/data/${encodeURIComponent(e.slice(4))}`:`${l}/dynamic/${encodeURIComponent(e)}?all=1${r?`&locale=${encodeURIComponent(r)}`:``}`,t=await Promise.all(m.map(t=>c(e(t),{headers:u}).then(Ke).then(e=>{let n=Array.isArray(e)?e:Array.isArray(e?.data)?e.data:[],r=Number(e?.total?.filtered??e?.total?.all??n.length);return[[t,n],[`${t}:total`,Number.isFinite(r)?r:n.length]]}).catch(()=>[[t,[]]])));p.datasets=Object.fromEntries(t.flat())}let h=Number(o);return Number.isFinite(h)&&h>=1&&(p.datasets={...p.datasets??{},__page:Math.floor(h)}),p}function Je(e,t){let n=[],r=new Set,i=e=>{Object.values(e??{}).forEach(e=>{n.push(e);let a=e?.type?.resolvedName===`ComponentInstance`?e.props?.componentId:null;a&&!r.has(a)&&(r.add(a),i(t?.[a]?.template?.nodes))})};return i(e),n}var Ye={en:{skip:`Skip to main content`,openMenu:`Open menu`,closeMenu:`Close menu`,prevSlide:`Previous slide`,nextSlide:`Next slide`,prevLogos:`Previous logos`,nextLogos:`Next logos`,goToSlide:`Go to slide {n}`,slide:`Slide {n} of {total}`,pause:`Pause`,play:`Play`,required:`required`,requiredNote:`Fields marked * are required.`,fieldRequired:`This field is required.`,invalid:`Please check this field.`,submitted:`Your form has been sent.`,submitFailed:`Your form could not be sent. Please check the fields and try again.`,back:`Back`,next:`Next`,submit:`Submit`,start:`Start`,tab:`Tab {n}`,item:`Item {n}`,frame:`Embedded content`,video:`Video`,transcript:`Transcript`},tr:{skip:`Ana içeriğe geç`,openMenu:`Menüyü aç`,closeMenu:`Menüyü kapat`,prevSlide:`Önceki slayt`,nextSlide:`Sonraki slayt`,prevLogos:`Önceki logolar`,nextLogos:`Sonraki logolar`,goToSlide:`{n}. slayta git`,slide:`Slayt {n} / {total}`,pause:`Duraklat`,play:`Oynat`,required:`zorunlu`,requiredNote:`* ile işaretli alanlar zorunludur.`,fieldRequired:`Bu alan zorunludur.`,invalid:`Lütfen bu alanı kontrol edin.`,submitted:`Formunuz gönderildi.`,submitFailed:`Formunuz gönderilemedi. Lütfen alanları kontrol edip tekrar deneyin.`,back:`Geri`,next:`İleri`,submit:`Gönder`,start:`Başlangıç`,tab:`Sekme {n}`,item:`Öğe {n}`,frame:`Gömülü içerik`,video:`Video`,transcript:`Metin dökümü`}};function Xe(e){let t=Ye[String(e||``).toLowerCase().split(/[-_]/)[0]]??Ye.en;return(e,n)=>{let r=t[e]??Ye.en[e]??e;return n?r.replace(/\{(\w+)\}/g,(e,t)=>n[t]==null?e:String(n[t])):r}}var Ze={position:`absolute`,width:1,height:1,padding:0,margin:-1,overflow:`hidden`,clip:`rect(0 0 0 0)`,whiteSpace:`nowrap`,border:0},Qe=`.webim-page .wb-file:focus-within{outline:2px solid var(--page-accent,#111827);outline-offset:2px}`,$e=`.webim-skip{position:fixed;left:12px;top:-80px;z-index:2147483647;padding:10px 16px;border-radius:8px;background:var(--page-accent,#111827);color:var(--page-accent-text,#ffffff);font-weight:600;font-size:15px;text-decoration:none;box-shadow:0 4px 16px rgba(0,0,0,.25);transition:top 120ms}.webim-skip:focus{top:12px;outline:2px solid var(--page-text,#111827);outline-offset:2px}@media (prefers-reduced-motion: reduce){.webim-skip{transition:none}}.webim-page [data-wb][tabindex="-1"]:focus{outline:none}`,et=e=>{for(let t of Array.isArray(e?.attributes)?e.attributes:[])if(String(t?.name??``).trim().toLowerCase()===`role`)return String(t.value??``).trim().toLowerCase();return``};function tt(e,t,n,r=0){let i=t?.[e];if(!i||r>8)return null;if(i.type?.resolvedName===`ComponentInstance`){let e=n?.[i.props?.componentId]?.template;return e?tt(e.rootId,e.nodes,n,r+1):null}return{id:e,node:i,nodes:t}}function nt(e,t,n,r,i=new Set){let a=t?.[e];if(!a||a.hidden)return null;if(a.type?.resolvedName===`ComponentInstance`){let e=a.props?.componentId,t=n?.[e]?.template;return!t||i.has(e)?null:nt(t.rootId,t.nodes,n,r,new Set(i).add(e))}if(r(a,e))return{id:e,node:a};let o=[...a.nodes??[],...Object.values(a.linkedNodes??{})];for(let e of o){let a=nt(e,t,n,r,i);if(a)return a}return null}var rt=new Set([`NavbarBlock`,`MenuTreeBlock`,`BreadcrumbsBlock`,`DrawerTrigger`]),it=e=>rt.has(e.type?.resolvedName)||[`banner`,`navigation`].includes(et(e.props));function at(e,t){if(!e?.ROOT)return null;let n=e=>e?{id:e.id,htmlId:e.node.props?.htmlId||`webim-main`}:null,r=nt(`ROOT`,e,t,e=>et(e.props)===`main`);if(r)return n(r);let i=e.ROOT.nodes??[],a=0;for(;a<i.length&&nt(i[a],e,t,it);)a+=1;if(a===0||a>=i.length)return null;let o=tt(i[a],e,t);return o?n({id:o.id,node:o.node}):null}var ot=new Set([`ar`,`he`,`fa`,`ur`,`ps`,`sd`,`ug`,`yi`,`dv`,`ckb`]),st=e=>ot.has(String(e||``).toLowerCase().split(/[-_]/)[0])?`rtl`:`ltr`,ct=(e,t)=>e===`ltr`||e===`rtl`?e:t?st(t):void 0,lt=`prop:`,ut=e=>String(e??``).startsWith(lt)?String(e).slice(5):``,dt=e=>typeof e==`string`&&e.trim()!==``||typeof e==`number`||typeof e==`boolean`;function ft(e,t){let n=Array.isArray(e?.compProps)?e.compProps:[];if(!n.length||!t||typeof t!=`object`)return e;let r=e;for(let e of n){let n=t[e?.id];if(!dt(n))continue;let i=ut(e.field);i?r={...r,[i]:n}:e.field===`text`?r={...r,text:n,parts:null}:e.field===`src`?r={...r,src:n}:e.field===`bg`?r={...r,style:{...r.style??{},backgroundImage:n}}:e.field===`href`&&(r={...r,href:n})}return r}function pt(e,t){if(!(e&&typeof e==`object`&&Object.values(e).some(dt)))return t;let n=t?.mapProps;return{...t,mapProps:(t,r)=>{let i=ft(t,e);return n?n(i,r):i}}}var mt=o(),ht=/^(https?:|mailto:|tel:)/i,gt=/^[a-z][a-z0-9+.-]*:/i;function _t(e){let t=String(e??``).trim();return t?ht.test(t)||t.startsWith(`//`)?t:gt.test(t)?``:t:``}var vt=/^\\([\\`*_{}[\]()#+\-.!~>|])/,yt=/^(`+)([\s\S]*?[^`])\1(?!`)/,bt=/^!\[([^\]]*)\]\(\s*<?([^)\s>]*)>?(?:\s+"([^"]*)")?\s*\)/,xt=/^\[((?:[^[\]]|\[[^\]]*\])*)\]\(\s*<?([^)\s>]*)>?(?:\s+"([^"]*)")?\s*\)/,St=/^<((?:https?:\/\/|mailto:)[^>\s]+)>/,Ct=/^https?:\/\/[^\s<>"'`]+[^\s<>"'`.,;:!?)\]}]/,wt=/^(\*\*|__)(?=\S)([\s\S]*?\S)\1/,Tt=/^~~(?=\S)([\s\S]*?\S)~~/,Et=/^(\*|_)(?=\S)([\s\S]*?\S)\1/,Dt=/[\\`*_~![<\n]|https?:\/\//,Ot=(e,t)=>e.map(e=>e.br||e.image?{...e,...t.href?{href:t.href,target:t.target}:null}:{...e,...t});function kt(e,t={}){let n=String(e??``),r=t.newTab?`_blank`:void 0,i=[],a=``,o=0,s=()=>{a&&i.push({text:a}),a=``},c=e=>{s(),i.push(...e)};for(;o<n.length;){let e=n.slice(o),i=o>0?n[o-1]:``,s=vt.exec(e);if(s){a+=s[1],o+=s[0].length;continue}if(e[0]===`
18
+ `)}function Be(e,t){return e===``||e==null?`${t}px`:isNaN(Number(e))?String(e):`${Number(e)}px`}function Ve(e){let t={};for(let n of Object.keys(De)){let r=e?.[n]??De[n];t[`--page-${n}`]=Be(r,De[n])}return t}function He(e,t=`light`){let n=Ne(e);return{...Fe(e),...Pe(n[t]??n.light)}}function Ue(e,t){return e?.themeRef&&t?.[e.themeRef]||e?.theme}function We(e,t){return e===`light`||e===`dark`?e:t===`light`||t===`dark`?t:`auto`}function Ge({page:e,settings:t,tenant:n,apiUrl:r,locale:i}){let a={...t?.global??{},...t?.tenant??{}},o=e.meta??{};return{schema:1,title:e.title,slug:e.slug,param:e.param??``,blocks:i&&o.i18n?.[i]?.blocks||e.blocks,theme:Ue(o,a.builder_themes?.themes),components:a.builder_components?.components??{},custom:o.custom,animations:o.animations,seo:o.seo,direction:o.direction,scheme:o.scheme,locale:i||a.locales?.default,locales:a.locales,tenant:n??``,apiUrl:r??``,settings:a}}var Ke=async e=>{let t=await e.json().catch(()=>null);if(!e.ok||t?.success===!1)throw Error(t?.error?.message||`Request failed (${e.status})`);return t?.payload??t};async function qe({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a,page:o,fetch:s}){if(!e)throw Error(`fetchPage: apiUrl is required`);if(!n)throw Error(`fetchPage: slug is required`);let c=s??fetch,l=e.replace(/\/$/,``),u={...t?{"x-tenant":t}:{},...a?{authorization:`Bearer ${a}`}:{}},[d,f]=await Promise.all([c(`${l}/render/${encodeURIComponent(n)}${i?`?preview=${encodeURIComponent(i)}`:``}`,{headers:u}).then(Ke),c(`${l}/settings/public`,{headers:u}).then(Ke)]),p=Ge({page:d,settings:f,tenant:t,apiUrl:l,locale:r}),m=[...new Set(Je(p.blocks,p.components).map(e=>e?.type?.resolvedName===`CollectionList`?e.props?.collection:[`TableBlock`,`OrgChartBlock`,`NavbarBlock`,`MenuTreeBlock`,`CalendarBlock`,`MasonryBlock`,`LightboxGallery`,`LogoCarousel`].includes(e?.type?.resolvedName)?e.props?.source:null).filter(Boolean))];if(m.length){let e=e=>e.startsWith(`api:`)?`${l}/data/${encodeURIComponent(e.slice(4))}`:`${l}/dynamic/${encodeURIComponent(e)}?all=1${r?`&locale=${encodeURIComponent(r)}`:``}`,t=await Promise.all(m.map(t=>c(e(t),{headers:u}).then(Ke).then(e=>{let n=Array.isArray(e)?e:Array.isArray(e?.data)?e.data:[],r=Number(e?.total?.filtered??e?.total?.all??n.length);return[[t,n],[`${t}:total`,Number.isFinite(r)?r:n.length]]}).catch(()=>[[t,[]]])));p.datasets=Object.fromEntries(t.flat())}let h=Number(o);return Number.isFinite(h)&&h>=1&&(p.datasets={...p.datasets??{},__page:Math.floor(h)}),p}function Je(e,t){let n=[],r=new Set,i=e=>{Object.values(e??{}).forEach(e=>{n.push(e);let a=e?.type?.resolvedName===`ComponentInstance`?e.props?.componentId:null;a&&!r.has(a)&&(r.add(a),i(t?.[a]?.template?.nodes))})};return i(e),n}var Ye={en:{skip:`Skip to main content`,openMenu:`Open menu`,closeMenu:`Close menu`,prevSlide:`Previous slide`,nextSlide:`Next slide`,prevLogos:`Previous logos`,nextLogos:`Next logos`,goToSlide:`Go to slide {n}`,slide:`Slide {n} of {total}`,pause:`Pause`,play:`Play`,required:`required`,requiredNote:`Fields marked * are required.`,fieldRequired:`This field is required.`,invalid:`Please check this field.`,submitted:`Your form has been sent.`,submitFailed:`Your form could not be sent. Please check the fields and try again.`,back:`Back`,next:`Next`,submit:`Submit`,start:`Start`,tab:`Tab {n}`,item:`Item {n}`,frame:`Embedded content`,video:`Video`,transcript:`Transcript`,close:`Close`,prevItem:`Previous`,nextItem:`Next`,openItem:`Open {name}`,itemOf:`{n} of {total}`,gallery:`Gallery`},tr:{skip:`Ana içeriğe geç`,openMenu:`Menüyü aç`,closeMenu:`Menüyü kapat`,prevSlide:`Önceki slayt`,nextSlide:`Sonraki slayt`,prevLogos:`Önceki logolar`,nextLogos:`Sonraki logolar`,goToSlide:`{n}. slayta git`,slide:`Slayt {n} / {total}`,pause:`Duraklat`,play:`Oynat`,required:`zorunlu`,requiredNote:`* ile işaretli alanlar zorunludur.`,fieldRequired:`Bu alan zorunludur.`,invalid:`Lütfen bu alanı kontrol edin.`,submitted:`Formunuz gönderildi.`,submitFailed:`Formunuz gönderilemedi. Lütfen alanları kontrol edip tekrar deneyin.`,back:`Geri`,next:`İleri`,submit:`Gönder`,start:`Başlangıç`,tab:`Sekme {n}`,item:`Öğe {n}`,frame:`Gömülü içerik`,video:`Video`,transcript:`Metin dökümü`,close:`Kapat`,prevItem:`Önceki`,nextItem:`Sonraki`,openItem:`{name} öğesini aç`,itemOf:`{n} / {total}`,gallery:`Galeri`}};function Xe(e){let t=Ye[String(e||``).toLowerCase().split(/[-_]/)[0]]??Ye.en;return(e,n)=>{let r=t[e]??Ye.en[e]??e;return n?r.replace(/\{(\w+)\}/g,(e,t)=>n[t]==null?e:String(n[t])):r}}var Ze={position:`absolute`,width:1,height:1,padding:0,margin:-1,overflow:`hidden`,clip:`rect(0 0 0 0)`,whiteSpace:`nowrap`,border:0},Qe=`.webim-page .wb-file:focus-within{outline:2px solid var(--page-accent,#111827);outline-offset:2px}`,$e=`.webim-skip{position:fixed;left:12px;top:-80px;z-index:2147483647;padding:10px 16px;border-radius:8px;background:var(--page-accent,#111827);color:var(--page-accent-text,#ffffff);font-weight:600;font-size:15px;text-decoration:none;box-shadow:0 4px 16px rgba(0,0,0,.25);transition:top 120ms}.webim-skip:focus{top:12px;outline:2px solid var(--page-text,#111827);outline-offset:2px}@media (prefers-reduced-motion: reduce){.webim-skip{transition:none}}.webim-page [data-wb][tabindex="-1"]:focus{outline:none}`,et=e=>{for(let t of Array.isArray(e?.attributes)?e.attributes:[])if(String(t?.name??``).trim().toLowerCase()===`role`)return String(t.value??``).trim().toLowerCase();return``};function tt(e,t,n,r=0){let i=t?.[e];if(!i||r>8)return null;if(i.type?.resolvedName===`ComponentInstance`){let e=n?.[i.props?.componentId]?.template;return e?tt(e.rootId,e.nodes,n,r+1):null}return{id:e,node:i,nodes:t}}function nt(e,t,n,r,i=new Set){let a=t?.[e];if(!a||a.hidden)return null;if(a.type?.resolvedName===`ComponentInstance`){let e=a.props?.componentId,t=n?.[e]?.template;return!t||i.has(e)?null:nt(t.rootId,t.nodes,n,r,new Set(i).add(e))}if(r(a,e))return{id:e,node:a};let o=[...a.nodes??[],...Object.values(a.linkedNodes??{})];for(let e of o){let a=nt(e,t,n,r,i);if(a)return a}return null}var rt=new Set([`NavbarBlock`,`MenuTreeBlock`,`BreadcrumbsBlock`,`DrawerTrigger`]),it=e=>rt.has(e.type?.resolvedName)||[`banner`,`navigation`].includes(et(e.props));function at(e,t){if(!e?.ROOT)return null;let n=e=>e?{id:e.id,htmlId:e.node.props?.htmlId||`webim-main`}:null,r=nt(`ROOT`,e,t,e=>et(e.props)===`main`);if(r)return n(r);let i=e.ROOT.nodes??[],a=0;for(;a<i.length&&nt(i[a],e,t,it);)a+=1;if(a===0||a>=i.length)return null;let o=tt(i[a],e,t);return o?n({id:o.id,node:o.node}):null}var ot=new Set([`ar`,`he`,`fa`,`ur`,`ps`,`sd`,`ug`,`yi`,`dv`,`ckb`]),st=e=>ot.has(String(e||``).toLowerCase().split(/[-_]/)[0])?`rtl`:`ltr`,ct=(e,t)=>e===`ltr`||e===`rtl`?e:t?st(t):void 0,lt=`prop:`,ut=e=>String(e??``).startsWith(lt)?String(e).slice(5):``,dt=e=>typeof e==`string`&&e.trim()!==``||typeof e==`number`||typeof e==`boolean`;function ft(e,t){let n=Array.isArray(e?.compProps)?e.compProps:[];if(!n.length||!t||typeof t!=`object`)return e;let r=e;for(let e of n){let n=t[e?.id];if(!dt(n))continue;let i=ut(e.field);i?r={...r,[i]:n}:e.field===`text`?r={...r,text:n,parts:null}:e.field===`src`?r={...r,src:n}:e.field===`bg`?r={...r,style:{...r.style??{},backgroundImage:n}}:e.field===`href`&&(r={...r,href:n})}return r}function pt(e,t){if(!(e&&typeof e==`object`&&Object.values(e).some(dt)))return t;let n=t?.mapProps;return{...t,mapProps:(t,r)=>{let i=ft(t,e);return n?n(i,r):i}}}var mt=o(),ht=/^(https?:|mailto:|tel:)/i,gt=/^[a-z][a-z0-9+.-]*:/i;function _t(e){let t=String(e??``).trim();return t?ht.test(t)||t.startsWith(`//`)?t:gt.test(t)?``:t:``}var vt=/^\\([\\`*_{}[\]()#+\-.!~>|])/,yt=/^(`+)([\s\S]*?[^`])\1(?!`)/,bt=/^!\[([^\]]*)\]\(\s*<?([^)\s>]*)>?(?:\s+"([^"]*)")?\s*\)/,xt=/^\[((?:[^[\]]|\[[^\]]*\])*)\]\(\s*<?([^)\s>]*)>?(?:\s+"([^"]*)")?\s*\)/,St=/^<((?:https?:\/\/|mailto:)[^>\s]+)>/,Ct=/^https?:\/\/[^\s<>"'`]+[^\s<>"'`.,;:!?)\]}]/,wt=/^(\*\*|__)(?=\S)([\s\S]*?\S)\1/,Tt=/^~~(?=\S)([\s\S]*?\S)~~/,Et=/^(\*|_)(?=\S)([\s\S]*?\S)\1/,Dt=/[\\`*_~![<\n]|https?:\/\//,Ot=(e,t)=>e.map(e=>e.br||e.image?{...e,...t.href?{href:t.href,target:t.target}:null}:{...e,...t});function kt(e,t={}){let n=String(e??``),r=t.newTab?`_blank`:void 0,i=[],a=``,o=0,s=()=>{a&&i.push({text:a}),a=``},c=e=>{s(),i.push(...e)};for(;o<n.length;){let e=n.slice(o),i=o>0?n[o-1]:``,s=vt.exec(e);if(s){a+=s[1],o+=s[0].length;continue}if(e[0]===`
19
19
  `){/ {2,}$/.test(a)?(a=a.replace(/ +$/,``),c([{br:!0}])):a.endsWith(`\\`)?(a=a.slice(0,-1),c([{br:!0}])):a+=` `,o+=1;continue}if(s=yt.exec(e),s){c([{text:(/^ .* $/.test(s[2])?s[2].slice(1,-1):s[2]).replace(/\n/g,` `),code:!0}]),o+=s[0].length;continue}if(s=bt.exec(e),s){let e=_t(s[2]);e?c([{image:{src:e,alt:s[1]||``,title:s[3]||``}}]):a+=s[1],o+=s[0].length;continue}if(s=xt.exec(e),s){let e=_t(s[2]),n=kt(s[1],t);c(e?Ot(n,{href:e,target:r}):n),o+=s[0].length;continue}if(s=St.exec(e)??(/[\s(<]/.test(i)||o===0?Ct.exec(e):null),s){let e=s[1]??s[0],t=_t(e);t?c([{text:e.replace(/^mailto:/i,``),href:t,target:r}]):a+=e,o+=s[0].length;continue}if(s=wt.exec(e),s&&(s[1]===`**`||!/\w/.test(i))){c(Ot(kt(s[2],t),{bold:!0})),o+=s[0].length;continue}if(s=Tt.exec(e),s){c(Ot(kt(s[1],t),{strike:!0})),o+=s[0].length;continue}if(s=Et.exec(e),s&&(s[1]===`*`||!/\w/.test(i)&&!/\w/.test(n[o+s[0].length]??``))){c(Ot(kt(s[2],t),{italic:!0})),o+=s[0].length;continue}a+=n[o],o+=1;let l=n.slice(o).search(Dt);l>0?(a+=n.slice(o,o+l),o+=l):l===-1&&(a+=n.slice(o),o=n.length)}return s(),i}var At=/^[ \t]*$/,jt=/^ {0,3}(`{3,}|~{3,})[ \t]*([^`\s]*)[ \t]*$/,Mt=/^ {0,3}(#{1,6})(?:[ \t]+(.*?))?[ \t]*$/,Nt=/^ {0,3}(?:(?:\*[ \t]*){3,}|(?:-[ \t]*){3,}|(?:_[ \t]*){3,})$/,Pt=/^ {0,3}>[ \t]?(.*)$/,Ft=/^( *)([-*+])[ \t]+(.*)$/,It=/^( *)(\d{1,9})[.)][ \t]+(.*)$/,Lt=/^ {0,3}(=+|-+)[ \t]*$/,Rt=/^\[([ xX])\][ \t]+(.*)$/,zt=/^ {0,3}\|?(?:[ \t]*:?-+:?[ \t]*\|)+[ \t]*:?-*:?[ \t]*\|?[ \t]*$/,Bt=e=>(/^[ \t]*/.exec(e)[0].match(/\t/g)||[]).length*3+/^[ \t]*/.exec(e)[0].length;function Vt(e){let t=Ft.exec(e);if(t)return{indent:t[1].length,ordered:!1,text:t[3]};let n=It.exec(e);return n?{indent:n[1].length,ordered:!0,start:Number(n[2]),text:n[3]}:null}function Ht(e){let t=[],n=``;for(let r=0;r<e.length;r++)e[r]===`\\`&&e[r+1]===`|`?(n+=`|`,r+=1):e[r]===`|`?(t.push(n),n=``):n+=e[r];return t.push(n),t.length&&At.test(t[0])&&t.shift(),t.length&&At.test(t[t.length-1])&&t.pop(),t.map(e=>e.trim())}var Ut=e=>{let t=e.trim(),n=t.startsWith(`:`),r=t.endsWith(`:`);return n&&r?`center`:r?`right`:n?`left`:null};function Wt(e){let t=e.filter(e=>!(e.text&&!e.text.trim()));if(t.length===1&&t[0].image&&!t[0].href){let{src:e,alt:n,title:r}=t[0].image;return[{type:`image`,src:e,alt:n,caption:r||``,align:`left`,wrap:!1}]}return e.length?[{type:`p`,parts:e}]:[]}function Gt(e){let t=String(e??``).replace(/\r\n?/g,`
20
20
  `).replace(/^/,``).split(`
21
21
  `),n=null;return t.map(e=>{let t=jt.exec(e);return n?(t&&t[1].startsWith(n[0])&&t[1].length>=n.length&&(n=null),e):t?(n=t[1],e):e.replace(/^[ \t]+/,e=>e.replace(/\t/g,` `))})}function Kt(e,t){let n=[],r=0;for(;r<e.length;){let i=e[r];if(At.test(i)){r+=1;continue}let a=jt.exec(i);if(a){let t=[],i=r+1;for(;i<e.length;){let n=jt.exec(e[i]);if(n&&n[1][0]===a[1][0]&&n[1].length>=a[1].length&&!n[2])break;t.push(e[i]),i+=1}n.push({type:`code`,lang:a[2]||``,text:t.join(`
22
22
  `)}),r=i+1;continue}let o=Mt.exec(i);if(o){let e=(o[2]??``).replace(/[ \t]+#+[ \t]*$/,``);n.push({type:`h${o[1].length}`,parts:kt(e,t)}),r+=1;continue}if(Nt.test(i)){n.push({type:`divider`}),r+=1;continue}if(Pt.test(i)){let i=[];for(;r<e.length;){let t=Pt.exec(e[r]);if(t)i.push(t[1]);else if(!At.test(e[r])&&i.length&&!At.test(i[i.length-1]))i.push(e[r]);else break;r+=1}let a=Kt(i,t);n.push(a.length===1&&a[0].type===`p`?{type:`quote`,parts:a[0].parts}:{type:`quote`,blocks:a});continue}if(Vt(i)){r=qt(e,r,n,t);continue}if(i.includes(`|`)&&r+1<e.length&&zt.test(e[r+1])){let a=Ht(i),o=Ht(e[r+1]).map(Ut),s=[a.map(e=>kt(e,t))],c=r+2;for(;c<e.length&&!At.test(e[c])&&e[c].includes(`|`);){let n=Ht(e[c]);s.push(a.map((e,r)=>kt(n[r]??``,t))),c+=1}let l={};o.forEach((e,t)=>{e&&s.forEach((n,r)=>l[`${r}:${t}`]={align:e})}),n.push({type:`table`,header:!0,rows:s,cellStyles:l}),r=c;continue}let s=[i];for(r+=1;r<e.length&&!At.test(e[r]);){let i=e[r],a=Lt.exec(i);if(a){n.push({type:a[1][0]===`=`?`h1`:`h2`,parts:kt(s.join(`
23
23
  `),t)}),r+=1,s.length=0;break}if(jt.test(i)||Mt.test(i)||Nt.test(i)||Pt.test(i)||Vt(i))break;s.push(i),r+=1}s.length&&n.push(...Wt(kt(s.join(`
24
- `),t)))}return n}function qt(e,t,n,r){let i=Vt(e[t]),a=i.indent,o=[],s=null,c=t;for(;c<e.length;){let t=e[c],n=Vt(t);if(n&&n.indent<=a+1){if(n.ordered!==i.ordered)break;s={lines:[n.text]},o.push(s),c+=1;continue}if(At.test(t)){let t=c;for(;t<e.length&&At.test(e[t]);)t+=1;if(!(t<e.length&&(Bt(e[t])>=a+2||Vt(e[t])&&Vt(e[t]).ordered===i.ordered)))break;s?.lines.push(``),c=t;continue}if(!s)break;if(Bt(t)>=a+2)s.lines.push(t.slice(Math.min(t.length-t.trimStart().length,a+2)));else if(!n)s.lines.push(t.trim());else break;c+=1}return n.push({type:i.ordered?`ol`:`ul`,...i.ordered&&i.start!==1?{start:i.start}:null,items:o.map(e=>{let t=Rt.exec(e.lines[0]??``);t&&(e.lines[0]=t[2]);let n=Kt(e.lines,r),i=n[0]?.type===`p`?n.shift():null;return{parts:i?i.parts:[],...n.length?{blocks:n}:null,...t?{task:t[1].toLowerCase()===`x`}:null}})}),c}function Jt(e,t={}){return String(e??``).trim()?Kt(Gt(e),t):[]}function Yt(e,t){let n={data:e,depth:0,parent:null,children:null},r=[n];for(;r.length;){let e=r.pop(),n=t(e.data);if(n?.length){e.children=n.map(t=>({data:t,depth:e.depth+1,parent:e,children:null}));for(let t=e.children.length-1;t>=0;--t)r.push(e.children[t])}}return n}function Xt(e,t){let n=[e];for(;n.length;){let e=n.pop();if(t(e),e.children)for(let t=e.children.length-1;t>=0;--t)n.push(e.children[t])}}function Zt(e,t){let n=[e],r=[];for(;n.length;){let e=n.pop();if(r.push(e),e.children)for(let t of e.children)n.push(t)}for(;r.length;)t(r.pop())}function Qt(e,[t,n],r){let i=(e,t)=>({_:e,parent:null,children:null,A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:t}),a=i(e,0);a.a=a,Xt(a,e=>{e._.children&&(e.children=e._.children.map((t,n)=>{let r=i(t,n);return r.a=r,r.parent=e,r}))}),a.parent=i(null,0),a.parent.a=a.parent,a.parent.children=[a];let o=e=>e.children?e.children[0]:e.t,s=e=>e.children?e.children[e.children.length-1]:e.t,c=(e,t,n)=>{let r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n},l=e=>{let t=0,n=0;for(let r=e.children.length-1;r>=0;--r){let i=e.children[r];i.z+=t,i.m+=t,t+=i.s+(n+=i.c)}},u=(e,t,n)=>e.a.parent===t.parent?e.a:n,d=(e,t,n)=>{if(!t)return n;let i=e,a=e,l=t,d=i.parent.children[0],f=i.m,p=a.m,m=l.m,h=d.m;for(;l=s(l),i=o(i),l&&i;){d=o(d),a=s(a),a.a=e;let t=l.z+m-i.z-f+r(l._,i._);t>0&&(c(u(l,e,n),e,t),f+=t,p+=t),m+=l.m,f+=i.m,h+=d.m,p+=a.m}return l&&!s(a)&&(a.t=l,a.m+=m-p),i&&!o(d)&&(d.t=i,d.m+=f-h,n=e),n};return Zt(a,e=>{let t=e.parent.children,n=e.i?t[e.i-1]:null;if(e.children){l(e);let t=(e.children[0].z+e.children[e.children.length-1].z)/2;n?(e.z=n.z+r(e._,n._),e.m=e.z-t):e.z=t}else n&&(e.z=n.z+r(e._,n._));e.parent.A=d(e,n,e.parent.A||t[0])}),a.parent.m=-a.z,Xt(a,e=>{e._.x=e.z+e.parent.m,e.m+=e.parent.m}),Xt(e,e=>{e.x*=t,e.y=e.depth*n}),e}var $t=20,en={S:{width:200,height:80},M:{width:240,height:80},L:{width:280,height:100},XL:{width:320,height:120}},tn={across:20,down:80,stack:20},nn=tn.across/2,rn={pad:20,header:40},an=2*tn.stack,on=`__root__`,sn=20,cn=e=>Math.round(e/$t)*$t;function ln(e){let{people:t,direction:n}=e,r=en[e.cardSize]??en.M,i=n===`right`,a=new Map;for(let e of t){let t=e.parent??on;a.has(t)||a.set(t,[]),a.get(t).push(e)}let o=i?r.height+tn.across:r.width+tn.across,s=i?r.width+tn.down:r.height+tn.down,c=e=>e.id===on||!e.collapsed?a.get(e.id)??[]:[],l=e=>e.kind===`group`,u=e=>c(e).filter(e=>e.placement!==`below`),d=e=>c(e).filter(e=>e.placement===`below`),f=(e,t)=>e.memberTeams===`inside`?c(t):[],p=e=>u(e).flatMap(t=>e.memberTeams===`inside`?f(e,t):[t]),m=e=>{let t=u(e).length,n=i||e.memberTeams===`inside`,r=Math.max(1,Math.min(t,e.memberColumns||(n?t:1)));return{cols:r,rows:Math.ceil(t/r)}},h=(e,t)=>{let n=f(e,t).length;return r.height+(n?an+n*(r.height+tn.stack)-tn.stack:0)},g=e=>{let t=u(e),{cols:n,rows:i}=m(e),a=[],o=rn.header;for(let r=0;r<i;r+=1)a.push(o),o+=Math.max(...t.slice(r*n,(r+1)*n).map(t=>h(e,t)))+tn.stack;return{width:(t.length?n*(r.width+tn.across)-tn.across:r.width)+2*rn.pad,height:(t.length?o-tn.stack:rn.header)+rn.pad,tops:a}},_=(e,t=c(e))=>{if(i||e.id===on)return t;let n=[],r=[],a=()=>{r.length>1?n.push({id:`${r[0].id}:stack`,people:r,line:e.columns}):n.push(...r),r=[]};for(let e of t)c(e).length||l(e)?(a(),n.push(e)):r.push(e);return a(),n},v=(e,t,n)=>{let r=n;for(let n=Math.ceil(t/s);n>0;--n)r=[{id:`${e}:${n}`,spacer:!0,below:r}];return r},y=i?r.width:r.height,b=Yt({id:on},e=>{if(e.people)return v(e.id,(e.people.length-1)*(r.height+tn.stack),[]);if(e.spacer)return e.below;if(l(e)){let t=p(e).flatMap(e=>_(e)),n=_(e,d(e)),r=i?[...n,...t]:[...t,...n],a=i?g(e).width:g(e).height;return v(`${e.id}:frame`,a-y,r)}return _(e)}),x=e=>{if(!l(e.data))return 0;let t=g(e.data);return(i?t.height-r.height:t.width-r.width)/o};Qt(b,[o,s],(e,t)=>(e.parent===t.parent?1:1+2*$t/o)+(x(e)+x(t))/2);let S=new Map,C=[],w=[],T=[],E=new Map([[on,{x:0,y:0}]]),D=new Map,O=(e,t,a,o,s=null)=>{let c=E.get(t??on),u={x:c.x+(e.dx||0),y:c.y+(e.dy||0)},d=l(e)?g(e):null,f={person:e,x:cn(a.x)+u.x,y:cn(a.y)+u.y,width:d?d.width:r.width,height:d?d.height:r.height};if(E.set(e.id,u),S.set(e.id,f),(d?w:C).push(f),o?.inner)T.push(o.line===`center`?{kind:`straight`,source:o.above?.id??e.parent,target:e.id,from:`bottom`,to:`top`}:{kind:`rail`,source:e.parent,target:e.id,from:`bottom`,to:o.line===`right`?`right`:`left`,side:o.line===`right`?`right`:`left`,drop:an/2});else if(e.parent&&!s){let t=D.get(e.parent);t!==void 0&&!e.lineFrom&&!e.lineTo&&!(o?.line===`center`&&o.above)?T.push({kind:`exit`,source:e.parent,target:e.id,from:i?`right`:`bottom`,to:o?.line===`left`||i?`left`:`top`,exit:t,into:o?.line===`left`?`side`:`top`,level:o?.line===`left`?cn(o.top)+c.y-tn.down/2:null}):T.push(un(e,o,n))}};Xt(b,e=>{let t=e.data;if(t.id===on||t.spacer)return;let n=e.y-s;if(t.people){t.people.forEach((i,a)=>O(i,i.parent,{x:e.x-r.width/2,y:n+a*(r.height+tn.stack)},{line:t.line,above:t.people[a-1],top:n}));return}if(l(t)){let a=g(t),o=i?{x:n,y:e.x-a.height/2}:{x:e.x-a.width/2,y:n};O(t,t.parent,o,null);let s=E.get(t.id);p(t).forEach(e=>D.set(e.id,i?cn(o.y)+s.y+a.height+nn:cn(o.x)+s.x-nn));let{cols:c}=m(t);u(t).forEach((e,n)=>{let i={x:o.x+rn.pad+n%c*(r.width+tn.across),y:o.y+a.tops[Math.floor(n/c)]},s=f(t,e);O(e,t.id,i,null,t),s.forEach((n,a)=>O(n,e.id,{x:i.x,y:i.y+r.height+an+a*(r.height+tn.stack)},{line:e.columns,above:s[a-1],inner:!0},t))});return}O(t,t.parent,i?{x:n,y:e.x-r.height/2}:{x:e.x-r.width/2,y:n},null)});let k=[...w,...C],A=Math.min(...k.map(e=>e.x))-sn,j=Math.min(...k.map(e=>e.y))-sn;for(let e of k)e.x-=A,e.y-=j;let M=T.map(e=>pn(e,S,i)).filter(Boolean),N=[...k.flatMap(e=>[e.x+e.width]),...M.flatMap(e=>e.points.map(e=>e.x))],P=[...k.flatMap(e=>[e.y+e.height]),...M.flatMap(e=>e.points.map(e=>e.y))];return{cards:C,frames:w,links:M,width:Math.ceil(Math.max(...N)+sn),height:Math.ceil(Math.max(...P)+sn),size:r}}function un(e,t,n){let r=n===`right`,i=r?`right`:`bottom`,a=r?`left`:`top`;return(e.lineTo===`left`||e.lineTo===`right`)&&!r&&(!e.lineFrom||e.lineFrom===`bottom`)?{kind:`elbow`,source:e.parent,target:e.id,from:`bottom`,to:e.lineTo,side:e.lineTo}:e.lineFrom||e.lineTo?{kind:`step`,source:e.parent,target:e.id,from:e.lineFrom||i,to:e.lineTo||a}:t?t.line===`center`?t.above?{kind:`straight`,source:t.above.id,target:e.id,from:i,to:a}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}:t.line===`right`?{kind:`rail`,source:e.parent,target:e.id,from:i,to:`right`,side:`right`}:{kind:`rail`,source:e.parent,target:e.id,from:i,to:`left`,side:`left`}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}}function dn(e,t){return t===`top`?{x:e.x+e.width/2,y:e.y}:t===`bottom`?{x:e.x+e.width/2,y:e.y+e.height}:t===`left`?{x:e.x,y:e.y+e.height/2}:{x:e.x+e.width,y:e.y+e.height/2}}var fn={top:{x:0,y:-1},bottom:{x:0,y:1},left:{x:-1,y:0},right:{x:1,y:0}};function pn(e,t,n){let r=t.get(e.source),i=t.get(e.target);if(!r||!i)return null;let a=dn(r,e.from),o=dn(i,e.to),s;if(e.kind===`straight`)s=[a,o];else if(e.kind===`rail`){let t=a.y+(e.drop??tn.down/2),n=e.side===`right`?o.x+nn:o.x-nn;s=[a,{x:a.x,y:t},{x:n,y:t},{x:n,y:o.y},o]}else if(e.kind===`exit`){let{exit:t,into:r,level:i}=e;if(n){let e=a.x+tn.across/2;s=[a,{x:e,y:a.y},{x:e,y:t},{x:o.x-tn.down/2,y:t},{x:o.x-tn.down/2,y:o.y},o]}else{let e=a.y+tn.stack/2;s=r===`side`?[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:i},{x:o.x-nn,y:i},{x:o.x-nn,y:o.y},o]:[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:o.y-tn.down/2},{x:o.x,y:o.y-tn.down/2},o]}}else if(e.kind===`elbow`){let t=e.side===`right`?a.x<o.x+nn:a.x>o.x-nn,n=e.side===`right`?o.x+nn:o.x-nn;return s=t?[a,{x:a.x,y:a.y+tn.down/2},{x:n,y:a.y+tn.down/2},{x:n,y:o.y},o]:[a,{x:a.x,y:o.y},o],{points:hn(s),square:!t}}else s=mn(a,e.from,o,e.to);return{points:hn(s)}}function mn(e,t,n,r){let i=e=>e===`top`||e===`bottom`;if(t===`bottom`&&r===`top`&&n.y>e.y){let t=(e.y+n.y)/2;return[e,{x:e.x,y:t},{x:n.x,y:t},n]}if(t===`right`&&r===`left`&&n.x>e.x){let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}let a={x:e.x+fn[t].x*20,y:e.y+fn[t].y*20},o={x:n.x+fn[r].x*20,y:n.y+fn[r].y*20};return[e,a,i(t)?{x:a.x,y:o.y}:{x:o.x,y:a.y},o,n]}var hn=e=>e.filter((e,t,n)=>t===0||e.x!==n[t-1].x||e.y!==n[t-1].y);function gn(e,t=10){let{points:n}=e,r=e.square?0:t,i=`M ${n[0].x} ${n[0].y}`;for(let e=1;e<n.length-1;e+=1){let[t,a,o]=[n[e-1],n[e],n[e+1]],s=Math.min(r,Math.hypot(a.x-t.x,a.y-t.y)/2,Math.hypot(o.x-a.x,o.y-a.y)/2),c=(e,t)=>{let n=Math.hypot(t.x-e.x,t.y-e.y)||1;return{x:e.x+(t.x-e.x)/n*s,y:e.y+(t.y-e.y)/n*s}},l=c(a,t),u=c(a,o);i+=` L ${l.x} ${l.y} Q ${a.x} ${a.y} ${u.x} ${u.y}`}let a=n.at(-1);return`${i} L ${a.x} ${a.y}`}var _n=`#4f46e5`,vn={S:.85,M:1,L:1.15,XL:1.3},yn={name:14,title:12.5,unit:13.5,department:11,band:12.5},bn=1.3,xn={classic:12,band:6},Sn={left:`flex-start`,center:`center`,right:`flex-end`},Cn={card:`var(--page-bg, #ffffff)`,text:`var(--page-text, #111827)`,border:`rgba(148, 163, 184, 0.45)`,line:`rgba(148, 163, 184, 0.8)`},wn=e=>String(e).replace(/[&<>"']/g,e=>({"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`})[e]),Tn=e=>Object.entries(e).filter(([,e])=>e!=null).map(([e,t])=>`${e}:${t}`).join(`;`),En=e=>({display:`-webkit-box`,"-webkit-line-clamp":e,"-webkit-box-orient":`vertical`,overflow:`hidden`,"overflow-wrap":`anywhere`}),Dn=e=>`#${[1,3,5].map(t=>Math.round(parseInt(e.slice(t,t+2),16)*.55).toString(16).padStart(2,`0`)).join(``)}`,On=e=>e.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0].toUpperCase()).join(``)||`?`;function kn(e,t,n,r){let i=e=>yn[e]*n*bn,a=(e,t,n)=>Math.max(1,Math.min(n,Math.floor((e+.5)/i(t)))),o=e.height-xn.classic-(r.department?yn.department*n*1.4:0),s=r.title?t?a(o-i(`title`),`name`,2):1:a(o,`name`,t?20:2),c=e.height*.55-xn.band;return{name:s,title:a(o-s*i(`name`),`title`,t?20:2),unit:a(o,`unit`,t?20:3),top:a(c,`band`,t?20:2),bottom:a(e.height-c-2*xn.band,`band`,t?20:1),single:a(e.height-xn.band,`band`,t?20:3)}}function An(e,t,n,r){let i=vn[e.textSize||t.textSize]??1,a=e.textAlign||t.textAlign||`left`,o=e.color||_n,s=kn(n,t.wrapText,i,e),c={"box-sizing":`border-box`,width:`100%`,height:`100%`,overflow:`hidden`,position:`relative`,"font-family":`inherit`,"line-height":bn};if(t.cardStyle===`banded`){let t={display:`flex`,"align-items":`center`,"justify-content":Sn[a],"text-align":a,padding:`0 10px`,color:`#fff`,"font-weight":600,"font-size":`${yn.band*i}px`,"min-height":0},n=e.title||e.name;return n&&!(e.title&&e.name)?`<div style="${Tn({...c,...t,"border-radius":`10px`,background:`linear-gradient(${o} 50%, ${Dn(o)} 50%)`})}"><div style="${Tn(En(s.single))}">${wn(n)}</div></div>`:`<div style="${Tn({...c,display:`flex`,"flex-direction":`column`,"border-radius":`10px`,background:Dn(o)})}"><div style="${Tn({...t,flex:`0 0 55%`,background:o})}"><div style="${Tn(En(s.top))}">${wn(e.title)}</div></div><div style="${Tn({...t,"flex-grow":1})}"><div style="${Tn(En(s.bottom))}">${wn(e.name)}</div></div></div>`}let l=!!(e.photo||e.name),u=n.height>=120?56:n.height>=100?48:40,d=[];e.showPhoto&&l&&d.push(`<div style="${Tn({flex:`none`,width:`${u}px`,height:`${u}px`,"border-radius":`50%`,overflow:`hidden`,background:o,color:`#fff`,display:`flex`,"align-items":`center`,"justify-content":`center`,"font-weight":600,"font-size":`${u*.38}px`})}">`+(e.photo?`<img src="${e.photo}" alt="" style="width:100%;height:100%;object-fit:cover;display:block"/>`:wn(On(e.name)))+`</div>`);let f=[];return l&&e.name&&f.push(`<div style="${Tn({...En(s.name),"font-weight":600,"font-size":`${yn.name*i}px`})}">${wn(e.name)}</div>`),e.title&&f.push(`<div style="${Tn({...En(l?s.title:s.unit),"font-size":`${(l?yn.title:yn.unit)*i}px`,"font-weight":l?400:600,opacity:l?.7:1})}">${wn(e.title)}</div>`),e.department&&f.push(`<div style="${Tn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-size":`${yn.department*i}px`,"line-height":1.4,color:o,"font-weight":600,"letter-spacing":`0.2px`})}">${wn(e.department)}</div>`),d.push(`<div style="${Tn({"min-width":0,"flex-grow":1,"max-height":`100%`,overflow:`hidden`,padding:`6px 0`,"box-sizing":`border-box`,"text-align":a})}">${f.join(``)}</div>`),`<div style="${Tn({...c,display:`flex`,"align-items":`center`,gap:`10px`,padding:`0 10px 0 14px`,border:`1px solid ${r.border}`,"border-radius":`25px`,background:r.card,color:r.text})}"><div style="${Tn({position:`absolute`,left:0,top:0,bottom:0,width:`5px`,background:o})}"></div>${d.join(``)}</div>`}function jn(e,t){let n=e.color||_n;return`<div style="${Tn({"box-sizing":`border-box`,width:`100%`,height:`100%`,"border-radius":`30px`,border:`2px ${t?`solid`:`dashed`} ${n}`,background:`${n}14`,"font-family":`inherit`})}"><div style="${Tn({height:`${rn.header}px`,display:`flex`,"align-items":`center`,padding:`0 16px`})}"><div style="${Tn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-weight":700,"font-size":`14px`,color:n})}">${wn(e.name)}</div></div></div>`}var Mn=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),W=e(((e,t)=>{t.exports=Mn()}))(),Nn=(0,l.createContext)({tenant:``,apiUrl:`/api`,locale:``,settings:null,revision:0}),Pn=(0,l.createContext)(null),Fn=e=>{let t=Number(e?.__page);if(Number.isFinite(t)&&t>=1)return Math.floor(t);if(typeof window>`u`)return 1;let n=Number(new URLSearchParams(window.location.search).get(`page`));return Number.isFinite(n)&&n>=1?Math.floor(n):1},In=()=>{if(typeof window>`u`)return{};let e={};return new URLSearchParams(window.location.search).forEach((t,n)=>{n.startsWith(`f_`)&&n.length>2&&t!==``&&(e[n.slice(2)]=t)}),e},Ln=e=>{let t={...e&&typeof e==`object`&&!Array.isArray(e)?e:{},...In()};return Object.fromEntries(Object.entries(t).filter(([,e])=>typeof e==`string`&&e.trim()!==``))},Rn=(0,l.createContext)(null),G=(...e)=>({"data-wb-part":e.filter(Boolean).join(` `)}),zn=(0,l.createContext)(null);function Bn(e,t){if(!t)return[];let n=Kn(e?.data,t);return(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id:e).filter(e=>e!=null&&e!==``).map(String)}function Vn(e,t,n){if(!t||!n||!Array.isArray(e))return[];let r=String(n.id??``);return r?e.filter(e=>Bn(e,t).includes(r)):[]}var Hn=e=>Jn(e).trim().toLowerCase();function Un(e,t){let n=Array.isArray(e?.rules)?e.rules.filter(e=>e&&e.op):[];if(!n.length||!t?.entry)return!0;let r=e=>{if(e.op===`children`||e.op===`nochildren`){let n=Vn(t.all,t.parentField,t.entry).length>0;return e.op===`children`?n:!n}let n=Kn(t.entry.data,e.field),r=Hn(n),i=String(e.value??``).trim().toLowerCase(),a=(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id??e.code:null).filter(e=>e!=null).map(e=>String(e).toLowerCase()),o=Array.isArray(n)?n.length>0:r!==``;switch(e.op){case`set`:return o;case`empty`:return!o;case`eq`:return r===i||a.includes(i);case`neq`:return r!==i&&!a.includes(i);case`contains`:return i===``||r.includes(i);default:return!0}};return e.match===`any`?n.some(r):n.every(r)}function Wn({showWhen:e,children:t}){return Un(e,(0,l.useContext)(zn))?t:null}var Gn=e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);function Kn(e,t){if(t)return t.includes(`.`)?t.split(`.`).reduce((e,t)=>e&&typeof e==`object`?e[t]:void 0,e):e?.[t]}var qn=e=>{let t=[];for(let[n,r]of Object.entries(e??{})){if(!/^[\w-]+$/.test(n))continue;t.push(n);let e=Array.isArray(r)?r[0]:r,i=Array.isArray(r)?`${n}.0`:n;if(e&&typeof e==`object`&&!Array.isArray(e))for(let n of Object.keys(e))/^[\w-]+$/.test(n)&&t.push(`${i}.${n}`)}return t};function Jn(e){return e==null?``:typeof e==`string`||typeof e==`number`||typeof e==`boolean`?String(e):typeof e==`object`&&!Array.isArray(e)&&(`label`in e||`name`in e||`slug`in e)?String(e.label??e.name??e.slug??``):typeof e==`object`&&!Array.isArray(e)&&Number.isFinite(Number(e.lat))&&Number.isFinite(Number(e.lng))?`${e.lat}, ${e.lng}`:Array.isArray(e)?e.map(e=>typeof e==`string`?e:Array.isArray(e?.parts)?e.parts.map(e=>e?.text??``).join(``):Array.isArray(e?.items)?e.items.map(e=>e?.text??``).join(` `):e&&(e.label!=null||e.name!=null||e.slug!=null)?String(e.label??e.name??e.slug):``).filter(Boolean).join(` `):``}var Yn=new Set([`href`,`src`,`poster`,`backgroundImage`]),Xn=[`created_at`,`updated_at`,`publish_at`],Zn=[`date`,`short`,`iso`,`datetime`,`time`],Qn={date:{dateStyle:`long`},short:{day:`2-digit`,month:`2-digit`,year:`numeric`},datetime:{dateStyle:`long`,timeStyle:`short`},time:{timeStyle:`short`}},$n=e=>String(e).padStart(2,`0`);function er(e,t=`date`,n){if(typeof e!=`string`&&!(e instanceof Date))return``;let r=typeof e==`string`?e.match(/^(\d{4})-(\d{2})-(\d{2})$/):null,i=r?new Date(Number(r[1]),Number(r[2])-1,Number(r[3])):new Date(e);if(Number.isNaN(i.getTime()))return``;if(t===`iso`)return`${i.getFullYear()}-${$n(i.getMonth()+1)}-${$n(i.getDate())}`;try{return new Intl.DateTimeFormat(n||void 0,Qn[t]??Qn.date).format(i)}catch{return i.toISOString()}}function tr(e,t,n){let r=t?.data??{},i=qn(r),a=[...Zn].sort((e,t)=>t.length-e.length).join(`|`),o=[...i.map(Gn).map(e=>`${e}(?:\\.(?:${a}))?`),...Xn.filter(e=>!i.includes(e)).map(e=>`${e}(?:\\.(?:${a}))?`)],s=RegExp(`:(${o.sort((e,t)=>t.length-e.length).join(`|`)})`,`g`),c=e=>{if(i.includes(e))return Jn(Kn(r,e));let[,o,s]=e.match(RegExp(`^(.*?)(?:\\.(${a}))?$`));if(!i.includes(o)&&Xn.includes(o))return er(t?.[o],s||`date`,n);let c=Kn(r,o);return s?er(c,s,n):Jn(c)},l=e=>{let t=e.match(RegExp(`^:(${o.sort((e,t)=>t.length-e.length).join(`|`)})$`)),n=t?Kn(r,t[1]):void 0;return Array.isArray(n)&&n.length?Jn(n[0]):e.replace(s,(e,t)=>c(t))},u=(e,t)=>typeof e==`string`&&Yn.has(t)?l(e):typeof e==`string`?e.replace(s,(e,t)=>c(t)):Array.isArray(e)?e.map(e=>u(e)):e&&typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,u(t,e)])):e;return u(e)}var nr=[`Top`,`Right`,`Bottom`,`Left`],rr=[`TopLeft`,`TopRight`,`BottomRight`,`BottomLeft`];function ir(e){let t={},n=(n,r)=>{n in e||(t[n]=r)};for(let[r,i]of Object.entries(e))if(r===`margin`||r===`padding`){let[e,t=e,a=e,o=t]=typeof i==`number`?[i]:String(i).trim().split(/\s+/);[e,t,a,o].forEach((e,t)=>n(`${r}${nr[t]}`,e))}else if(r===`borderRadius`&&(typeof i==`number`||!/\s|\//.test(String(i))))rr.forEach(e=>n(`border${e}Radius`,i));else if(r===`border`){let[e,t,...r]=String(i).trim().split(/\s+/);nr.forEach(i=>{n(`border${i}Width`,e),n(`border${i}Style`,t),n(`border${i}Color`,r.join(` `))})}else r===`background`&&!/(gradient|url)\(/i.test(String(i))?n(`backgroundColor`,i):t[r]=i;return t}var ar=ir({margin:0,fontWeight:700,lineHeight:1.2,fontFamily:`var(--page-heading-font, inherit)`}),or=De,sr=e=>`var(--page-${e}, ${De[e]??De.h2}px)`,cr=ir({margin:0,fontSize:`var(--page-body-size, 16px)`}),lr={display:`inline-block`,textDecoration:`none`,cursor:`pointer`,backgroundColor:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},ur={flexGrow:1,display:`flex`,flexDirection:`column`,position:`relative`},dr={display:`flex`,flexDirection:`column`};function fr({style:e}){let t=e?.backgroundVideo;if(!t)return null;let n={position:`absolute`,inset:0,width:`100%`,height:`100%`,zIndex:-1,pointerEvents:`none`},r=e?.overlayColor?`color-mix(in srgb, ${e.overlayColor} ${e.overlayOpacity??50}%, transparent)`:null;return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`video`,{src:t,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{...n,objectFit:`cover`}}),r&&(0,W.jsx)(`div`,{style:{...n,background:r}})]})}var pr=(e,t)=>e?.backgroundVideo?{position:`relative`,...t,...z(e)}:{...t,...z(e)};function mr({style:e,nodeRef:t,children:n}){return(0,W.jsxs)(`div`,{ref:t,style:{...ur,...z(e)},children:[(0,W.jsx)(fr,{style:e}),n]})}function hr({style:e,nodeRef:t,children:n}){return(0,W.jsxs)(`section`,{ref:t,style:pr(e,dr),children:[(0,W.jsx)(fr,{style:e}),n]})}function gr({style:e,freeLayout:t,nodeRef:n,children:r}){let i=t?{position:`relative`,minHeight:240}:null;return(0,W.jsxs)(`div`,{ref:n,style:i?{...i,...pr(e)}:pr(e),children:[(0,W.jsx)(fr,{style:e}),r]})}function _r({href:e,target:t,style:n,nodeRef:r,children:i}){return(0,W.jsxs)(`a`,{ref:r,href:e||`#`,target:t||void 0,rel:t===`_blank`?`noopener noreferrer`:void 0,style:{...Rr,...pr(n)},children:[(0,W.jsx)(fr,{style:n}),i]})}function vr({text:e,parts:t,tag:n=`h2`,style:r,linked:i,nodeRef:a}){return(0,W.jsx)(n,{ref:a,style:{...ar,fontSize:sr(n),...z(r)},children:Sr(t,e,i)})}var yr={fontFamily:Ae.mono.value,background:`rgba(148, 163, 184, 0.18)`,padding:`1px 5px`,borderRadius:4,fontSize:`0.9em`},br=ir({fontFamily:Ae.mono.value,background:`rgba(148, 163, 184, 0.16)`,border:`1px solid rgba(148, 163, 184, 0.3)`,borderRadius:6,padding:`12px 14px`,fontSize:`0.875em`,lineHeight:1.55,overflowX:`auto`,whiteSpace:`pre`});function xr(e,t=[],n,r,i=!1){let a=e;return t.includes(`sup`)?a=(0,W.jsx)(`sup`,{children:a}):t.includes(`sub`)&&(a=(0,W.jsx)(`sub`,{children:a})),t.includes(`code`)&&(a=(0,W.jsx)(`code`,{style:yr,children:a})),t.includes(`strike`)&&(a=(0,W.jsx)(`s`,{children:a})),t.includes(`underline`)&&(a=(0,W.jsx)(`u`,{children:a})),t.includes(`italic`)&&(a=(0,W.jsx)(`em`,{children:a})),t.includes(`bold`)&&(a=(0,W.jsx)(`strong`,{children:a})),n?a=(0,W.jsx)(`a`,{href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":i?void 0:``,style:{...i&&{color:`inherit`},...t.includes(`nounderline`)&&{textDecoration:`none`}},children:a}):t.includes(`nounderline`)&&(a=(0,W.jsx)(`span`,{style:{textDecoration:`none`},children:a})),a}function Sr(e,t,n){return e?.length?e.map((e,t)=>{if(e.slot)return(0,W.jsx)(l.Fragment,{children:n?.[e.slot]??null},t);if(e.parts)return(0,W.jsx)(l.Fragment,{children:Sr(e.parts,``,n)},t);if(e.br)return(0,W.jsx)(`br`,{},t);let r=e.text;return e.image&&(r=(0,W.jsx)(`img`,{src:e.image.src,alt:e.image.alt||``,title:e.image.title||void 0,style:{maxWidth:`100%`,verticalAlign:`middle`}})),e.sup?r=(0,W.jsx)(`sup`,{children:r}):e.sub&&(r=(0,W.jsx)(`sub`,{children:r})),e.code&&(r=(0,W.jsx)(`code`,{style:yr,children:r})),e.strike&&(r=(0,W.jsx)(`s`,{children:r})),e.underline&&(r=(0,W.jsx)(`u`,{children:r})),e.italic&&(r=(0,W.jsx)(`em`,{children:r})),e.bold&&(r=(0,W.jsx)(`strong`,{children:r})),(e.color||e.background)&&(r=(0,W.jsx)(`span`,{style:{...e.color&&{color:e.color},...e.background&&{backgroundColor:e.background}},children:r})),e.href?r=(0,W.jsx)(`a`,{href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":``,style:{...e.color&&{color:e.color},...e.nounderline&&{textDecoration:`none`}},children:r}):e.nounderline&&(r=(0,W.jsx)(`span`,{style:{textDecoration:`none`},children:r})),(0,W.jsx)(l.Fragment,{children:r},t)}):t}function Cr({parts:e,text:t,marks:n,href:r,target:i,style:a}){return(0,W.jsx)(`span`,{style:z(a),children:e?.length?Sr(e,t):xr(t,n,r,i,!!z(a)?.color)})}var wr=[`left`,`center`,`right`,`justify`];function Tr(e,t,n){let r=e&&e.cellStyles;if(!r||typeof r!=`object`||Array.isArray(r))return{};let i=r[`${t}:${n}`];return i&&typeof i==`object`&&!Array.isArray(i)?i:{}}function Er(e,t){let n=e||{},r=typeof n.bold==`boolean`?n.bold:!!t;return{textAlign:wr.includes(n.align)?n.align:`left`,fontWeight:r?700:400,fontStyle:n.italic?`italic`:void 0,color:typeof n.color==`string`&&n.color?n.color:void 0,backgroundColor:typeof n.bg==`string`&&n.bg?n.bg:void 0}}function Dr({align:e=`center`,width:t,wrap:n}={}){let r=t?`${t}%`:void 0;if(e===`full`)return{width:`100%`};let i=e===`left`||e===`right`;return i&&(n??!0)?{float:e,width:r??`50%`,maxWidth:`100%`,marginTop:`4px`,marginBottom:`12px`,...e===`left`?{marginRight:`20px`,marginLeft:0}:{marginLeft:`20px`,marginRight:0}}:i?{width:r??`fit-content`,maxWidth:`100%`,...e===`left`?{marginLeft:0,marginRight:`auto`}:{marginLeft:`auto`,marginRight:0}}:{width:r??`fit-content`,maxWidth:`100%`,marginLeft:`auto`,marginRight:`auto`}}var Or={red:`#e03131`,orange:`#e8590c`,yellow:`#c98a00`,blue:`#1c7ed6`,purple:`#7048e8`,pink:`#d6336c`,green:`#2f9e44`,grey:`#868e96`},kr={red:`rgba(224, 49, 49, 0.12)`,orange:`rgba(232, 89, 12, 0.12)`,yellow:`rgba(201, 138, 0, 0.15)`,blue:`rgba(28, 126, 214, 0.12)`,purple:`rgba(112, 72, 232, 0.12)`,pink:`rgba(214, 51, 108, 0.12)`,green:`rgba(47, 158, 68, 0.12)`,grey:`rgba(134, 142, 150, 0.16)`};function Ar(e){let t=Or[e?.color]??(e?.color||``),n=kr[e?.background]??(e?.background||``);return{...t&&{color:t},...n&&{backgroundColor:n,padding:`8px 12px`,borderRadius:`8px`}}}function jr(e=[],t,n){let r=n??((e,n)=>Sr(e,n,t));return e.map((n,i)=>{let a={marginTop:0,marginBottom:i===e.length-1?0:14};if(n.type===`image`){if(!n.src)return null;let e=(0,W.jsx)(`img`,{...G(`image`),src:n.src,alt:n.alt||``,style:{width:`100%`,display:`block`,borderRadius:6}});return(0,W.jsxs)(`figure`,{...G(`figure`),style:{marginLeft:0,marginRight:0,...a,...Dr(n)},children:[n.href?(0,W.jsx)(`a`,{href:n.href,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`},children:e}):e,n.caption&&(0,W.jsx)(`figcaption`,{...G(`caption`),style:{fontSize:13,opacity:.65,marginTop:6,textAlign:`center`},children:n.caption})]},i)}if(n.type===`video`)return Kr(n.url)?(0,W.jsx)(`div`,{...G(`video`),style:{...a,...Dr({align:n.align,wrap:n.wrap,width:n.width??100})},children:(0,W.jsx)(qr,{url:n.url,autoplay:n.autoplay,muted:n.muted,loop:n.loop,controls:n.controls??!0,start:n.start})},i):null;if(n.type===`button`){if(!(typeof n.label==`string`&&n.label.trim()))return null;let e=Number.isFinite(Number(n.radius))?Number(n.radius):8,t=[`center`,`right`].includes(n.align)?n.align:`left`;return(0,W.jsx)(`div`,{style:{...a,textAlign:t},children:(0,W.jsx)(`table`,{role:`presentation`,cellPadding:0,cellSpacing:0,style:{borderCollapse:`separate`,display:`inline-table`},children:(0,W.jsx)(`tbody`,{children:(0,W.jsx)(`tr`,{children:(0,W.jsx)(`td`,{style:{backgroundColor:n.bg||`var(--page-accent, #4f46e5)`,borderRadius:e},children:(0,W.jsx)(`a`,{...G(`button`),href:n.href||`#`,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`inline-block`,padding:`13px 24px`,color:n.color||`#ffffff`,fontSize:15,fontWeight:600,lineHeight:1.2,textDecoration:`none`,borderRadius:e},children:n.label})})})})})},i)}if(n.type===`divider`)return(0,W.jsx)(`hr`,{...G(`divider`),style:{...a,border:0,borderTop:`1px solid rgba(148, 163, 184, 0.4)`}},i);if(n.type===`table`){let e=Array.isArray(n.rows)?n.rows.filter(Array.isArray):[];if(!e.length)return null;let t=n.header!==!1,o=n.borders===!1?void 0:`1px solid rgba(148, 163, 184, 0.4)`,s=Number.isFinite(n.padX)?Math.max(0,n.padX):10,c=Number.isFinite(n.padY)?Math.max(0,n.padY):6,l=Math.max(0,Number(n.spacing)||0),u={border:o,padding:`${c}px ${s}px`,verticalAlign:`top`},d=Array.isArray(n.heights)?n.heights:null,f=e=>{let t=Number(d?.[e]);return Number.isFinite(t)&&t>0?{height:`${t}px`}:void 0},p=t?e.slice(1):e,m=Array.isArray(n.widths)?n.widths:null,h=(e,t,r)=>({...u,...Er(Tr(n,e,t),r)}),g=n.spans&&typeof n.spans==`object`?n.spans:null,_=new Set;g&&e.forEach((e,t)=>e.forEach((e,n)=>{let r=g[`${t}:${n}`];if(!r)return;let i=Math.max(1,Number(r.c)||1),a=Math.max(1,Number(r.r)||1);for(let e=0;e<a;e+=1)for(let r=0;r<i;r+=1)(e||r)&&_.add(`${t+e}:${n+r}`)}));let v=(e,t)=>{let n=g?.[`${e}:${t}`],r=Math.max(1,Number(n?.c)||1),i=Math.max(1,Number(n?.r)||1);return{colSpan:r>1?r:void 0,rowSpan:i>1?i:void 0}};return(0,W.jsxs)(`table`,{...G(`table`),style:{...a,borderCollapse:l?`separate`:`collapse`,borderSpacing:l?`${l}px`:void 0,width:`100%`,fontSize:cr.fontSize,tableLayout:m?`fixed`:void 0},children:[typeof n.caption==`string`&&n.caption.trim()?(0,W.jsx)(`caption`,{...G(`caption`),style:{captionSide:`top`,textAlign:`left`,fontWeight:600,padding:`0 0 6px`},children:n.caption}):null,m&&(0,W.jsx)(`colgroup`,{children:m.map((e,t)=>(0,W.jsx)(`col`,{style:{width:`${e}%`}},t))}),t&&(0,W.jsx)(`thead`,{children:(0,W.jsx)(`tr`,{...G(`header-row`),style:f(0),children:e[0].map((e,t)=>_.has(`0:${t}`)?null:(0,W.jsx)(`th`,{...G(`header-cell`),scope:`col`,style:h(0,t,!0),...v(0,t),children:Array.isArray(e)?r(e):e},t))})}),(0,W.jsx)(`tbody`,{children:p.map((e,n)=>(0,W.jsx)(`tr`,{...G(`row`),style:f(t?n+1:n),children:e.map((e,i)=>{let a=t?n+1:n;return _.has(`${a}:${i}`)?null:(0,W.jsx)(`td`,{...G(`cell`),style:h(a,i,!1),...v(a,i),children:Array.isArray(e)?r(e):e},i)})},n))})]},i)}if(n.type===`ul`||n.type===`ol`){let e=n.type;return(0,W.jsx)(e,{...G(`list`,n.type===`ol`&&`list-ordered`),style:{fontSize:cr.fontSize,...a,...Ar(n),paddingLeft:n.background?34:24},start:n.type===`ol`?n.start:void 0,children:(n.items??[]).map((e,n)=>{let i=typeof e.task==`boolean`;return(0,W.jsxs)(`li`,{...G(`list-item`),style:{marginBottom:4,...i&&{listStyleType:`none`,marginLeft:-18}},children:[i&&(0,W.jsx)(`span`,{style:{marginRight:6},children:e.task?`☑`:`☐`}),r(e.parts,e.text),e.blocks?.length?jr(e.blocks,t,r):null]},n)})},i)}if(n.type===`quote`)return(0,W.jsx)(`blockquote`,{...G(`quote`),style:{...Pr,fontSize:cr.fontSize,...a,...Ar(n),...n.background&&{paddingLeft:20}},children:n.blocks?.length?jr(n.blocks,t,r):r(n.parts,n.text)},i);if(n.type===`code`)return(0,W.jsx)(`pre`,{...G(`code`),"data-lang":n.lang||void 0,style:{...a,...br},children:(0,W.jsx)(`code`,{style:{fontFamily:`inherit`},children:n.text})},i);if(or[n.type]){let e=n.type;return(0,W.jsx)(e,{...G(`heading`,`heading-${n.type}`),style:{...ar,fontSize:sr(n.type),...a,...Ar(n)},children:r(n.parts,n.text)},i)}return(0,W.jsx)(`p`,{...G(`paragraph`),style:{...cr,...a,...Ar(n)},children:r(n.parts,n.text)},i)})}function Mr({content:e,style:t,linked:n,nodeRef:r}){return(0,W.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(t)},children:jr(e,n)})}function Nr({markdown:e,newTab:t,style:n,nodeRef:r}){let i=(0,l.useMemo)(()=>Jt(e,{newTab:t}),[e,t]);return(0,W.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(n)},children:jr(i)})}var Pr=ir({margin:0,padding:`8px 0 8px 20px`,borderLeftWidth:`4px`,borderLeftStyle:`solid`,borderLeftColor:`var(--page-accent, rgba(148, 163, 184, 0.6))`});function Fr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,W.jsx)(`blockquote`,{ref:i,style:{...Pr,...z(n)},children:Sr(t,e,r)})}function Ir({ordered:e,items:t=[],style:n,nodeRef:r}){return(0,W.jsx)(e?`ol`:`ul`,{ref:r,style:{margin:0,paddingLeft:24,...z(n)},children:t.map((e,t)=>(0,W.jsx)(`li`,{...G(`item`),style:{marginBottom:4},children:Sr(e.parts,e.text)},t))})}function Lr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,W.jsx)(`p`,{ref:i,style:{...cr,...z(n)},children:Sr(t,e,r)})}var Rr={display:`block`,color:`inherit`,textDecoration:`none`,cursor:`pointer`},zr={textUnderlineOffset:3,cursor:`pointer`};function Br({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,W.jsx)(`a`,{ref:o,"data-wb-link":``,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...zr,...z(i)},children:Sr(t,e,a)})}function Vr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,W.jsx)(`a`,{ref:o,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...lr,...z(i)},children:Sr(t,e,a)})}function Hr({src:e,alt:t,decorative:n,style:r,nodeRef:i}){return e?(0,W.jsx)(`img`,{ref:i,src:e,alt:n?``:t||``,role:n?`presentation`:void 0,style:{display:`block`,maxWidth:`100%`,...z(r)}}):null}function Ur({text:e,locale:t}){let n=String(e??``).trim();return n?(0,W.jsxs)(`details`,{...G(`transcript`),style:{marginTop:8,fontSize:14},children:[(0,W.jsx)(`summary`,{...G(`transcript-toggle`),style:{cursor:`pointer`,fontWeight:600},children:Xe(t)(`transcript`)}),(0,W.jsx)(`div`,{...G(`transcript-text`),style:{marginTop:8,lineHeight:1.6},children:n.split(/\n\s*\n/).map((e,t)=>(0,W.jsx)(`p`,{style:{margin:`0 0 8px`,whiteSpace:`pre-line`},children:e},t))})]}):null}var Wr=e=>(Array.isArray(e)?e:[]).filter(e=>typeof e?.src==`string`&&e.src.trim());function Gr({src:e,poster:t,controls:n=!0,autoplay:r=!1,loop:i=!1,muted:a=!1,title:o=``,tracks:s,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(Nn);if(!e)return null;let p=Wr(s),m=typeof o==`string`&&o.trim()?o.trim():void 0,h=typeof c==`string`&&c.trim(),g=(0,W.jsx)(`video`,{ref:h?void 0:d,...h?{"data-wb-self":``}:{},src:e,poster:t||void 0,controls:n,"aria-label":m,autoPlay:r,muted:a||r,loop:i,playsInline:!0,crossOrigin:p.length?`anonymous`:void 0,style:{display:`block`,width:`100%`,maxWidth:`100%`,...z(u)},children:p.map((e,t)=>(0,W.jsx)(`track`,{kind:e.kind===`captions`?`captions`:`subtitles`,src:e.src,srcLang:e.srclang||void 0,label:e.label||e.srclang||void 0,default:e.default?!0:void 0},e.key??t))});return h?(0,W.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[g,(0,W.jsx)(Ur,{text:c,locale:f})]}):g}var Kr=(e=``)=>(e.match(/(?:youtu\.be\/|v=|embed\/|shorts\/|live\/)([\w-]{11})/)||e.match(/^([\w-]{11})$/))?.[1];function qr({url:e,autoplay:t=!1,muted:n=!1,loop:r=!1,controls:i=!0,start:a,title:o=``,captions:s=!1,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(Nn),p=Kr(e);if(!p)return null;let m=new URLSearchParams({rel:`0`});if(t&&m.set(`autoplay`,`1`),(n||t)&&m.set(`mute`,`1`),i||m.set(`controls`,`0`),r&&(m.set(`loop`,`1`),m.set(`playlist`,p)),Number(a)>0&&m.set(`start`,String(Math.floor(Number(a)))),s){m.set(`cc_load_policy`,`1`);let e=String(f||``).split(/[-_]/)[0];e&&m.set(`cc_lang_pref`,e)}let h=(0,W.jsx)(`iframe`,{...G(`frame`),src:`https://www.youtube-nocookie.com/embed/${p}?${m}`,title:typeof o==`string`&&o.trim()?o.trim():Xe(f)(`video`),allow:`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share`,allowFullScreen:!0,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,border:0}});return typeof c==`string`&&c.trim()?(0,W.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[(0,W.jsx)(`div`,{"data-wb-self":``,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h}),(0,W.jsx)(Ur,{text:c,locale:f})]}):(0,W.jsx)(`div`,{ref:d,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h})}function Jr({src:e,title:t,allowFullscreen:n=!0,style:r,nodeRef:i}){let{locale:a}=(0,l.useContext)(Nn);return e?(0,W.jsx)(`iframe`,{ref:i,src:e,title:t||Xe(a)(`frame`),loading:`lazy`,allowFullScreen:n,style:{display:`block`,width:`100%`,height:300,border:0,...z(r)}}):null}function Yr(e,{toolbar:t=!0,page:n,zoom:r}={}){let i=_t(e);if(!i)return``;let a=[];return t===!1&&a.push(`toolbar=0&navpanes=0`),Number(n)>1&&a.push(`page=${Number(n)}`),r&&r!==`auto`&&a.push(`zoom=${r}`),a.length?`${i.split(`#`)[0]}#${a.join(`&`)}`:i}function Xr({src:e,title:t,toolbar:n=!0,page:r,zoom:i=`auto`,link:a=!0,linkLabel:o,fallbackText:s,style:c,nodeRef:l}){let u=_t(e);if(!u)return null;let d=o||`Open the PDF`,f=t||`PDF document`;return(0,W.jsxs)(`div`,{ref:l,style:{display:`flex`,flexDirection:`column`,width:`100%`,height:600,...z(c)},children:[(0,W.jsx)(`object`,{data:Yr(u,{toolbar:n,page:r,zoom:i}),type:`application/pdf`,"aria-label":f,...G(`document`),style:{display:`block`,flex:`1 1 auto`,minHeight:0,width:`100%`,border:0},children:(0,W.jsxs)(`div`,{...G(`fallback`),style:{display:`grid`,placeItems:`center`,gap:8,height:`100%`,padding:16,textAlign:`center`},children:[(0,W.jsx)(`p`,{style:{...cr,opacity:.75},children:s||`This browser can’t show the PDF here.`}),!a&&(0,W.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, inherit)`},children:d})]})},Yr(u,{toolbar:n,page:r,zoom:i})),a&&(0,W.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,...G(`link`),style:{flexShrink:0,marginTop:8,color:`var(--page-accent, inherit)`,fontSize:14},children:d})]})}var Zr=/(^|[\s,>+~{}])(:root|html|body)(?=$|[\s,{.:#[>+~])/g;function Qr(e){return`@scope ([data-wb-embed]) {\n${e.replace(Zr,`$1:scope`)}\n}`}function $r({code:e,runScripts:t=!0,scopeStyles:n=!1,style:r,nodeRef:i}){let[a,o]=(0,l.useState)(null);return(0,l.useEffect)(()=>{a&&(a.innerHTML=e||``,n?(a.setAttribute(`data-wb-embed`,``),a.querySelectorAll(`style`).forEach(e=>{e.textContent=Qr(e.textContent||``)})):a.removeAttribute(`data-wb-embed`),t&&a.querySelectorAll(`script`).forEach(e=>{let t=document.createElement(`script`);for(let{name:n,value:r}of e.attributes)t.setAttribute(n,r);t.text=e.textContent,e.replaceWith(t)}))},[a,e,t,n]),(0,W.jsx)(`div`,{ref:e=>{o(e),i&&i(e)},style:z(r)})}function ei({height:e,style:t,nodeRef:n}){return(0,W.jsx)(`div`,{ref:n,style:{height:e||32,flexShrink:0,alignSelf:`stretch`,...z(t)}})}function ti({style:e,nodeRef:t}){return(0,W.jsx)(`div`,{ref:t,style:{height:1,alignSelf:`stretch`,flexShrink:0,...z(e)}})}function ni({style:e,nodeRef:t}){return(0,W.jsx)(`div`,{ref:t,style:{flexShrink:0,...z(e)}})}var ri={position:`absolute`,top:`50%`,transform:`translateY(-50%)`,width:36,height:36,borderRadius:`50%`,border:0,cursor:`pointer`,background:`rgba(17, 24, 39, 0.45)`,color:`#fff`,fontSize:20,lineHeight:1,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:0},ii={bottom:{inset:`auto 0 0 0`,padding:`40px 24px 20px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.55))`},top:{inset:`0 0 auto 0`,padding:`20px 24px 40px`,background:`linear-gradient(rgba(0, 0, 0, 0.55), transparent)`},middle:{inset:0,display:`flex`,flexDirection:`column`,justifyContent:`center`,padding:24,textShadow:`0 2px 12px rgba(0, 0, 0, 0.6)`}},ai=48;function oi({count:e,renderSlide:t,autoplay:n=!0,interval:r=5,height:i=320,swipe:a=!0,style:o,nodeRef:s}){let[c,u]=(0,l.useState)(0),[d,f]=(0,l.useState)(!1),[p,m]=(0,l.useState)(!1),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(null),{locale:y}=(0,l.useContext)(Nn),b=e?Math.min(c,e-1):0;if((0,l.useEffect)(()=>{window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches&&g(!0)},[]),(0,l.useEffect)(()=>{if(!n||h||d||p||_||e<2)return;let t=setInterval(()=>u(t=>(t+1)%e),Math.max(2,Number(r)||5)*1e3);return()=>clearInterval(t)},[n,h,d,p,_,r,e]),!e)return null;let x=Xe(y),S=t=>u((t+e)%e),C=()=>{if(!_)return;let{dx:e}=_;v(null),e<-48?S(b+1):e>ai&&S(b-1)};return(0,W.jsxs)(`div`,{ref:s,role:`region`,"aria-roledescription":`carousel`,onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1),onFocus:()=>m(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||m(!1)},onPointerDown:a&&e>1?e=>{e.pointerType===`mouse`&&e.button!==0||e.target.closest(`button`)||(e.currentTarget.setPointerCapture(e.pointerId),v({startX:e.clientX,dx:0}))}:void 0,onPointerMove:_?e=>v(t=>t&&{...t,dx:e.clientX-t.startX}):void 0,onPointerUp:C,onPointerCancel:C,style:{position:`relative`,overflow:`hidden`,width:`100%`,height:i,touchAction:`pan-y`,userSelect:_?`none`:void 0,cursor:_?`grabbing`:void 0,...z(o)},children:[(0,W.jsx)(`div`,{...G(`track`),style:{display:`flex`,height:`100%`,transform:`translateX(calc(${-b*100}% + ${_?.dx??0}px))`,transition:_?`none`:`transform 450ms ease`},children:Array.from({length:e},(n,r)=>(0,W.jsx)(`div`,{...G(`slide`,r===b&&`slide-active`),role:`group`,"aria-roledescription":`slide`,"aria-label":x(`slide`,{n:r+1,total:e}),"aria-hidden":r!==b||void 0,inert:r!==b||void 0,style:{position:`relative`,width:`100%`,flexShrink:0,overflow:`hidden`},children:t(r)},r))}),e>1&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`button`,{type:`button`,...G(`arrow`,`arrow-prev`),"aria-label":x(`prevSlide`),style:{...ri,left:12},onClick:()=>S(b-1),children:`‹`}),(0,W.jsx)(`button`,{type:`button`,...G(`arrow`,`arrow-next`),"aria-label":x(`nextSlide`),style:{...ri,right:12},onClick:()=>S(b+1),children:`›`}),(0,W.jsx)(`div`,{...G(`dots`),style:{position:`absolute`,bottom:10,left:0,right:0,display:`flex`,justifyContent:`center`,gap:6},children:Array.from({length:e},(e,t)=>(0,W.jsx)(`button`,{type:`button`,"aria-label":x(`goToSlide`,{n:t+1}),"aria-current":t===b?`true`:void 0,...G(`dot`,t===b&&`dot-active`),onClick:()=>S(t),style:{width:8,height:8,borderRadius:`50%`,border:0,padding:0,cursor:`pointer`,background:t===b?`#ffffff`:`rgba(255, 255, 255, 0.45)`}},t))}),n&&(0,W.jsx)(`button`,{type:`button`,...G(`pause`,h&&`pause-stopped`),"aria-label":x(h?`play`:`pause`),onClick:()=>g(!h),style:{...ri,top:`auto`,bottom:8,right:12,transform:`none`,width:28,height:28},children:(0,W.jsx)(`svg`,{viewBox:`0 0 24 24`,width:14,height:14,fill:`currentColor`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:h?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})})]})]})}var si=(e,t)=>({position:`absolute`,inset:0,backgroundImage:e?`url(${e})`:`none`,backgroundColor:t||(e?void 0:`rgba(148, 163, 184, 0.25)`),backgroundSize:`cover`,backgroundPosition:`center`});function ci({slides:e=[],captionPosition:t=`bottom`,captionAlign:n=`left`,...r}){return e.length?(0,W.jsx)(oi,{...r,count:e.length,renderSlide:r=>{let i=e[r];return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...G(`slide-image`),style:si(i.image)}),(i.title||i.text)&&(0,W.jsxs)(`div`,{...G(`caption`),style:{position:`absolute`,color:`#fff`,textAlign:n,...ii[t]??ii.bottom},children:[i.title&&(0,W.jsx)(`div`,{...G(`caption-title`),style:{fontSize:22,fontWeight:700},children:i.title}),i.text&&(0,W.jsx)(`div`,{...G(`caption-text`),style:{fontSize:14,opacity:.9,marginTop:4},children:i.text})]})]})}}):null}function li({slides:e=[],linked:t,...n}){return e.length?(0,W.jsx)(oi,{...n,count:e.length,renderSlide:n=>{let r=e[n];return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...G(`slide-background`),style:si(r.image,r.color)}),(0,W.jsx)(`div`,{...G(`slide-content`),style:{position:`absolute`,inset:0,display:`flex`,flexDirection:`column`},children:t?.[r.key]??null})]})}}):null}var ui=256,di=e=>Math.log(Math.tan(Math.PI/4+Math.max(-85,Math.min(85,e))*Math.PI/360)),fi=(e,t,n)=>{let r=ui*2**n;return{x:(Number(t)+180)/360*r,y:(.5-di(Number(e))/(2*Math.PI))*r}},pi=(e,t)=>{if(e===``||e==null)return null;let n=Number(e);return Number.isFinite(n)&&Math.abs(n)<=t?n:null},mi=e=>!!e&&pi(e.lat,90)!==null&&pi(e.lng,180)!==null;function hi(e,t,n=`directions`,r=``){let i=`${e},${t}`;return n===`place`?`https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(i)}${r?`&query_place_id=`:``}`:`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(i)}`}var gi=`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,_i=e=>{let t=String(e??``).trim();return/^https?:\/\//i.test(t)&&t.includes(`{z}`)&&t.includes(`{x}`)&&t.includes(`{y}`)?t:gi},vi=e=>{try{return new URL(e.replace(/[{}]/g,``)).host}catch{return e}},yi=(e,t,n=13)=>`https://www.openstreetmap.org/?mlat=${e}&mlon=${t}#map=${Math.round(Number(n)||13)}/${e}/${t}`;function bi({markers:e,lat:t,lng:n,zoom:r=``,height:i=320,pinSize:a=22,pinLink:o=`directions`,link:s=!1,label:c=``,tileUrl:u=``,tileError:d=``,style:f,nodeRef:p,inert:m}){let h=(0,l.useRef)(null),[g,_]=(0,l.useState)(1200),v=_i(u),[y,b]=(0,l.useState)({key:``,failed:0,loaded:0});(0,l.useEffect)(()=>{let e=h.current;if(!e||typeof ResizeObserver>`u`)return;let t=()=>_(t=>e.clientWidth&&e.clientWidth!==t?e.clientWidth:t);t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]);let x=(Array.isArray(e)?e:[]).filter(mi),S=mi({lat:t,lng:n})?{lat:pi(t,90),lng:pi(n,180)}:x.length?{lat:x.reduce((e,t)=>e+pi(t.lat,90),0)/x.length,lng:x.reduce((e,t)=>e+pi(t.lng,180),0)/x.length}:null,C=Math.max(80,Number(i)||320),w=pi(r,19)?Math.min(Math.max(Math.round(Number(r)),1),19):(()=>{if(x.length<2)return 13;for(let e=19;e>=1;e--){let t=x.map(t=>fi(pi(t.lat,90),pi(t.lng,180),e)),n=Math.max(...t.map(e=>e.x))-Math.min(...t.map(e=>e.x)),r=Math.max(...t.map(e=>e.y))-Math.min(...t.map(e=>e.y));if(n<=g*.8&&r<=C*.7)return e}return 1})(),T={width:`100%`,...z(f)};if(!S)return(0,W.jsx)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:{...T,minHeight:80,display:`grid`,placeItems:`center`,fontSize:13,opacity:.6,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:8},children:`Set the coordinates in Settings`});let E=fi(S.lat,S.lng,w),D={x:E.x-g/2,y:E.y-C/2},O=[],k=[];for(let e=Math.floor(D.x/ui);e<=Math.floor((D.x+g)/ui);e++)O.push(e);for(let e=Math.floor(D.y/ui);e<=Math.floor((D.y+C)/ui);e++)k.push(e);let A=2**w,j=`${v}|${w}`,M=y.key===j?y:{key:j,failed:0,loaded:0},N=e=>b(t=>{let n=t.key===j?t:{key:j,failed:0,loaded:0};return{...n,[e]:n[e]+1}}),P=M.failed>0&&M.loaded===0;return(0,W.jsxs)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:T,children:[(0,W.jsxs)(`div`,{role:`img`,"aria-label":c||`Map`,...G(`map`),style:{position:`relative`,height:C,overflow:`hidden`,borderRadius:`inherit`,background:`var(--page-surface, #e5e7eb)`},children:[k.map(e=>O.map(t=>{let n=(t%A+A)%A;return e<0||e>=A?null:(0,W.jsx)(`img`,{src:v.replace(`{z}`,w).replace(`{x}`,n).replace(`{y}`,e),alt:``,onLoad:()=>N(`loaded`),onError:e=>{e.currentTarget.style.visibility=`hidden`,N(`failed`)},width:ui,height:ui,loading:`lazy`,style:{position:`absolute`,left:Math.round(t*ui-D.x),top:Math.round(e*ui-D.y),width:ui,height:ui,userSelect:`none`,pointerEvents:`none`}},`${j}:${t}-${e}`)})),P&&m&&d?(0,W.jsx)(`div`,{style:{...U,position:`absolute`,left:12,right:12,top:12,padding:`8px 12px`,borderRadius:8,background:`rgba(15, 23, 42, 0.78)`,color:`#fff`,fontSize:12,lineHeight:1.45},children:d.replace(`{host}`,vi(v))}):null,x.map((e,t)=>{let n=fi(pi(e.lat,90),pi(e.lng,180),w),r=n.x-D.x,i=n.y-D.y,s=e.color||`var(--page-accent, #dc2626)`,c=o===`none`||m?null:hi(pi(e.lat,90),pi(e.lng,180),o,e.title);return(0,W.jsxs)(c?`a`:`span`,{...G(`pin`),href:c||void 0,target:c?`_blank`:void 0,rel:c?`noopener noreferrer`:void 0,title:c&&e.title||void 0,style:{position:`absolute`,left:r,top:i,transform:`translate(-50%, -100%)`,cursor:c?`pointer`:`default`,textDecoration:`none`,color:`inherit`},children:[e.title?(0,W.jsx)(`span`,{...G(`pin-label`),style:{position:`absolute`,left:`50%`,bottom:`100%`,transform:`translateX(-50%)`,marginBottom:4,padding:`3px 7px`,borderRadius:6,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.5))`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.25)`,fontSize:12,lineHeight:1.35,whiteSpace:`nowrap`},children:e.title}):null,(0,W.jsxs)(`svg`,{width:Math.max(10,Number(a)||22),height:Math.max(10,Number(a)||22),viewBox:`0 0 24 24`,fill:s,style:{display:`block`},children:[(0,W.jsx)(`path`,{d:`M12 22s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11z`}),xi[e.icon]?(0,W.jsx)(`path`,{d:xi[e.icon],transform:`translate(12 10.5) scale(0.46) translate(-12 -12)`,fill:`none`,stroke:`#fff`,strokeWidth:4,strokeLinecap:`round`,strokeLinejoin:`round`}):(0,W.jsx)(`circle`,{cx:`12`,cy:`10.5`,r:`2.6`,fill:`#fff`})]})]},t)}),(0,W.jsx)(`a`,{href:`https://www.openstreetmap.org/copyright`,target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...G(`credit`),style:{position:`absolute`,right:4,bottom:3,padding:`1px 5px`,borderRadius:4,background:`rgba(255, 255, 255, 0.75)`,color:`#334155`,fontSize:10,textDecoration:`none`},children:`© OpenStreetMap`})]}),s?(0,W.jsx)(`a`,{href:yi(S.lat,S.lng,w),target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...G(`link`),style:{display:`inline-block`,marginTop:6,fontSize:12,color:`var(--page-accent, inherit)`},children:`View larger map`}):null]})}var xi={check:`M4 12l5 5L20 6`,close:`M6 6l12 12M18 6L6 18`,plus:`M12 5v14M5 12h14`,minus:`M5 12h14`,"arrow-right":`M4 12h16M13 5l7 7-7 7`,"arrow-left":`M20 12H4M11 5l-7 7 7 7`,"arrow-up":`M12 20V4M5 11l7-7 7 7`,"arrow-down":`M12 4v16M5 13l7 7 7-7`,"chevron-right":`M9 5l7 7-7 7`,"chevron-left":`M15 5l-7 7 7 7`,"chevron-down":`M5 9l7 7 7-7`,"chevron-up":`M5 15l7-7 7 7`,menu:`M4 7h16M4 12h16M4 17h16`,star:`M12 3.5l2.6 5.3 5.9.9-4.3 4.1 1 5.8-5.2-2.7-5.2 2.7 1-5.8L3.5 9.7l5.9-.9z`,heart:`M12 20s-7-4.4-7-9a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 4.6-7 9-7 9z`,home:`M4 11l8-7 8 7M6 10v9h12v-9`,user:`M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM4 20c0-3.3 3.6-5 8-5s8 1.7 8 5`,mail:`M3 6h18v12H3zM3 6l9 7 9-7`,phone:`M6 3h4l2 5-3 2a12 12 0 0 0 5 5l2-3 5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 4 5a2 2 0 0 1 2-2z`,search:`M11 4a7 7 0 1 0 0 14 7 7 0 0 0 0-14zM20 20l-4.2-4.2`,clock:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 7v5l3 2`,calendar:`M4 6h16v14H4zM4 10h16M8 3v4M16 3v4`,download:`M12 4v10M8 11l4 4 4-4M4 19h16`,upload:`M12 20V10M8 13l4-4 4 4M4 5h16`,play:`M8 5l11 7-11 7z`,pause:`M9 5v14M15 5v14`,info:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 11v5M12 8h.01`,alert:`M12 4l9 16H3zM12 10v4M12 17h.01`,lock:`M6 11h12v9H6zM9 11V8a3 3 0 0 1 6 0v3`,chat:`M4 5h16v11H9l-5 4z`,"map-pin":`M12 21s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11zM12 12a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5z`,camera:`M4 8h4l2-2h4l2 2h4v12H4zM12 17a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z`,image:`M4 5h16v14H4zM8 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM6 17l5-5 4 4 2-2 3 3`,file:`M7 3h7l4 4v14H7zM14 3v5h4`,link:`M10 14a4 4 0 0 0 6 .5l2-2a4 4 0 0 0-6-6l-1 1M14 10a4 4 0 0 0-6-.5l-2 2a4 4 0 0 0 6 6l1-1`,external:`M14 4h6v6M20 4l-9 9M18 14v5H5V6h5`,trash:`M4 7h16M9 7V5h6v2M6 7l1 13h10l1-13`,edit:`M4 20h4L19 9l-4-4L4 16z`,filter:`M3 5h18l-7 8v6l-4-2v-4z`,refresh:`M20 12a8 8 0 1 1-2.3-5.7M20 4v5h-5`,globe:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM3 12h18M12 3c2.5 3 2.5 15 0 18M12 3c-2.5 3-2.5 15 0 18`,bell:`M6 16V11a6 6 0 1 1 12 0v5l2 3H4zM10 22h4`,tag:`M4 4h7l9 9-7 7-9-9zM8.5 8.5h.01`,cart:`M4 5h2l2 10h10l2-7H7M9 20h.01M18 20h.01`,card:`M3 6h18v12H3zM3 10h18`,shield:`M12 3l8 3v6c0 5-4 8-8 9-4-1-8-4-8-9V6z`,sun:`M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zM12 2v2M12 20v2M4 12H2M22 12h-2M5 5l1.5 1.5M17.5 17.5L19 19M19 5l-1.5 1.5M6.5 17.5L5 19`,moon:`M20 14a8 8 0 1 1-10-10 7 7 0 0 0 10 10z`,settings:`M12 9.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM12 2l1 2.6 2.7-.6 1 2.5 2.6 1-.6 2.7L21 12l-2.3 1.8.6 2.7-2.6 1-1 2.5-2.7-.6L12 22l-1-2.6-2.7.6-1-2.5-2.6-1 .6-2.7L3 12l2.3-1.8-.6-2.7 2.6-1 1-2.5 2.7.6z`,eye:`M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7zM12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z`,"eye-off":`M4 4l16 16M9.5 9.6A3 3 0 0 0 12 15c.8 0 1.5-.3 2.1-.8M6.6 6.7C3.9 8.3 2 12 2 12s4 7 10 7c1.9 0 3.5-.5 4.9-1.2M14.1 5.4C13.4 5.1 12.7 5 12 5`,share:`M8 12a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 6a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 18a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM7.8 10.8l8.4-3.6M7.8 13.2l8.4 3.6`,send:`M21 3L3 10l7 3 3 7z`,paperclip:`M20 11l-8.5 8.5a5 5 0 0 1-7-7L13 4a3.5 3.5 0 0 1 5 5l-8.5 8.5a2 2 0 0 1-3-3L15 6`,video:`M3 7h11v10H3zM14 11l6-3v8l-6-3`,music:`M9 18V6l10-2v12M9 18a2.5 2.5 0 1 1-2.5-2.5H9M19 16a2.5 2.5 0 1 1-2.5-2.5H19`,mic:`M12 3a3 3 0 0 1 3 3v5a3 3 0 0 1-6 0V6a3 3 0 0 1 3-3zM5 11a7 7 0 0 0 14 0M12 18v3`,headphones:`M4 15v-3a8 8 0 1 1 16 0v3M4 15h3v5H5a1 1 0 0 1-1-1zM20 15h-3v5h2a1 1 0 0 0 1-1z`,book:`M5 4h14v16H7a2 2 0 0 1-2-2zM7 4v14h12`,bookmark:`M7 4h10v16l-5-4-5 4z`,folder:`M4 6h5l2 2h9v10H4z`,cloud:`M7 18a4 4 0 0 1 .5-8 5.5 5.5 0 0 1 10.4 1.5A3.5 3.5 0 0 1 17.5 18z`,database:`M12 3c4.4 0 8 1.3 8 3s-3.6 3-8 3-8-1.3-8-3 3.6-3 8-3zM4 6v12c0 1.7 3.6 3 8 3s8-1.3 8-3V6M4 12c0 1.7 3.6 3 8 3s8-1.3 8-3`,server:`M4 4h16v6H4zM4 14h16v6H4zM8 7h.01M8 17h.01`,code:`M9 8l-5 4 5 4M15 8l5 4-5 4`,terminal:`M4 5h16v14H4zM8 10l3 2-3 2M13 14h4`,wifi:`M5 12a10 10 0 0 1 14 0M8 15a6 6 0 0 1 8 0M12 19h.01`,battery:`M3 8h15v8H3zM21 11v2`,printer:`M7 8V4h10v4M7 16H4V8h16v8h-3M7 13h10v7H7z`,gift:`M4 10h16v10H4zM3 6h18v4H3zM12 6v14M12 6c-2 0-4-1-4-2.5S9 2 10 3s2 3 2 3zM12 6c2 0 4-1 4-2.5S15 2 14 3s-2 3-2 3z`,key:`M15 4a5 5 0 1 0-4.6 7L9 12.4V15H6.5L4 17.5V20h4l7-7A5 5 0 0 0 15 4z`,compass:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM15 9l-2 5-5 2 2-5z`,flag:`M5 21V4h13l-2 4 2 4H5`,award:`M12 4a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM9 13l-1 7 4-2 4 2-1-7`,chart:`M4 20V4M4 20h16M8 16v-5M12 16V8M16 16v-8`,pie:`M12 3a9 9 0 1 0 9 9h-9z`,trending:`M3 17l6-6 4 4 8-8M15 7h6v6`,dollar:`M12 3v18M16 7.5C16 6 14.2 5 12 5S8 6 8 7.5 9.5 10 12 10.5s4 1.5 4 3-1.8 2.5-4 2.5-4-1-4-2.5`,percent:`M5 19L19 5M7.5 5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM16.5 14a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5z`,truck:`M3 6h11v9H3zM14 9h4l3 3v3h-7zM7.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM17.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3z`,package:`M12 3l8 4v10l-8 4-8-4V7zM4 7l8 4 8-4M12 11v10`,store:`M4 9h16v11H4zM4 9l1.5-5h13L20 9M9 20v-6h6v6`,building:`M5 21V4h9v17M14 9h5v12M8 8h3M8 12h3M8 16h3M17 12h.01M17 16h.01`,users:`M9 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM2 20c0-3.3 3.1-5 7-5s7 1.7 7 5M17 5a4 4 0 0 1 0 7.9M22 20c0-2.6-1.6-4.2-4-4.8`,"thumbs-up":`M7 21V10h3l3-6a2 2 0 0 1 2 2v4h4l-2 11z`,smile:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9 10h.01M15 10h.01M8.5 14.5a5 5 0 0 0 7 0`,help:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9.5 9.5a2.5 2.5 0 1 1 3.5 2.3c-.6.3-1 .9-1 1.7M12 17h.01`,checkbox:`M4 4h16v16H4zM8 12l3 3 5-5`,list:`M8 6h13M8 12h13M8 18h13M3.5 6h.01M3.5 12h.01M3.5 18h.01`,grid:`M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z`,apps:`M4.5 4.5h2v2h-2zM11 4.5h2v2h-2zM17.5 4.5h2v2h-2zM4.5 11h2v2h-2zM11 11h2v2h-2zM17.5 11h2v2h-2zM4.5 17.5h2v2h-2zM11 17.5h2v2h-2zM17.5 17.5h2v2h-2z`,layers:`M12 3l9 5-9 5-9-5zM3 13l9 5 9-5`,zap:`M13 3L5 14h6l-1 7 8-11h-6z`,flame:`M12 21a6 6 0 0 0 6-6c0-4-4-6-4-10 0 0-3 1.5-3 5 0 1.5-1 2-1.5 1.5C8 10 7.5 9 7.5 9A7.5 7.5 0 0 0 6 15a6 6 0 0 0 6 6z`,droplet:`M12 3s6 6.4 6 10.5a6 6 0 0 1-12 0C6 9.4 12 3 12 3z`,leaf:`M4 20c0-8 6-14 16-14 0 10-6 14-12 14H4zM8 16c2-4 5-6 8-7`};function Si({name:e=`star`,paths:t,fill:n=!1,size:r=24,stroke:i=2,color:a=``,href:o=``,target:s=``,label:c=``,style:l,nodeRef:u,inert:d}){let f=Array.isArray(t)?t.filter(e=>typeof e==`string`&&e.trim()):[],p=n&&f.length>0,m=f.length?f:[xi[e]??xi.star],h=Math.min(Math.max(Number(r)||24,8),240),g=a===`accent`?`var(--page-accent, currentColor)`:a||`currentColor`,_=(0,W.jsx)(`svg`,{...G(`glyph`),viewBox:`0 0 24 24`,width:h,height:h,fill:p?g:`none`,stroke:p?`none`:g,strokeWidth:p?void 0:Math.min(Math.max(Number(i)||2,.5),4),strokeLinecap:p?void 0:`round`,strokeLinejoin:p?void 0:`round`,role:c?`img`:void 0,"aria-label":c||void 0,"aria-hidden":c?void 0:`true`,style:{display:`block`},children:m.map((e,t)=>(0,W.jsx)(`path`,{d:e},t))}),v={display:`inline-flex`,lineHeight:0,...z(l)};return o?(0,W.jsx)(`a`,{ref:u,href:o,onClick:d?e=>e.preventDefault():void 0,target:s||void 0,rel:s===`_blank`?`noopener noreferrer`:void 0,style:{...v,color:`inherit`},children:_}):(0,W.jsx)(`span`,{ref:u,style:v,children:_})}function Ci(e,t={},n=0){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],i=e=>e==null?``:Jn(e),a=Math.max(0,Number(n)||0),o=[];for(let e of r){let n=e.data??e,r=Kn(n,t.imageField),s=(Array.isArray(r)?r:[r]).map(e=>e&&typeof e==`object`?e.url??e.src??``:e).filter(e=>typeof e==`string`&&e.trim()),c=t.nameField?i(Kn(n,t.nameField)):i(n.name),l=t.hrefField?i(Kn(n,t.hrefField)):``;for(let e of s)if(o.push({src:e,name:c,alt:c,href:l}),a&&o.length>=a)return o}return o}function wi({images:e=[],source:t=``,entry:n=``,imageField:r=``,nameField:i=``,hrefField:a=``,limit:o=0,emptyText:s=``,columns:c=3,gap:u=8,showNames:d=!1,lightbox:f=!0,style:p,nodeRef:m,inert:h}){let{tenant:g,apiUrl:_,revision:v}=(0,l.useContext)(Nn),y=(0,l.useContext)(Pn)?.[t],[b,x]=(0,l.useState)(null),[S,C]=(0,l.useState)(()=>new Set);(0,l.useEffect)(()=>{if(!t||y)return;let e=!0;return fetch(`${_}/dynamic/${encodeURIComponent(t)}`,{headers:g?{"x-tenant":g}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&x(n)}).catch(()=>e&&x([])),()=>{e=!1}},[v,t,g,_,y]);let w=y??b??[],T=n?w.filter(e=>e?.id===n||e?.data?.slug===n||e?.slug===n):w,E=Math.max(0,Number(o)||0),D=t?(()=>{let e=Ci(T,{imageField:r,nameField:i,hrefField:a},0).filter(e=>!S.has(e.src));return E?e.slice(0,E):e})():null,O=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],k=D??O,A=!!t&&!y&&b===null,j=Math.max(0,Number(u)||0),M=h?e=>e.preventDefault():void 0,[N,P]=(0,l.useState)(null),F=f&&!h&&N!==null&&k[N];(0,l.useEffect)(()=>{if(!F)return;let e=e=>{e.key===`Escape`&&P(null),e.key===`ArrowRight`&&P(e=>(e+1)%k.length),e.key===`ArrowLeft`&&P(e=>(e-1+k.length)%k.length)};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[F,k.length]);let I=e=>{if(typeof e.name==`string`&&e.name.trim())return e.name;if(typeof e.alt==`string`&&e.alt.trim())return e.alt;try{let t=String(e.src).split(`?`)[0].split(`/`).pop();return decodeURIComponent(t??``)}catch{return``}};return(0,W.jsxs)(`div`,{ref:m,style:{columnCount:Math.min(Math.max(Number(c)||3,1),8),columnGap:j,width:`100%`,...z(p)},children:[k.map((e,n)=>{let r=(0,W.jsxs)(`span`,{style:{position:`relative`,display:`block`,borderRadius:`inherit`,overflow:`hidden`},children:[(0,W.jsx)(`img`,{...G(`image`),src:e.src,alt:e.alt??``,onError:t?()=>C(t=>new Set(t).add(e.src)):void 0,style:{width:`100%`,display:`block`,borderRadius:`inherit`}}),d&&I(e)&&(0,W.jsx)(`span`,{...G(`caption`),style:{position:`absolute`,insetInline:0,bottom:0,padding:`14px 10px 8px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.65))`,color:`#fff`,fontSize:12,lineHeight:1.3,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`},children:I(e)})]}),i=e.href?(0,W.jsx)(`a`,{href:e.href,onClick:M,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`,borderRadius:`inherit`},children:r}):f&&!h?(0,W.jsx)(`span`,{role:`button`,tabIndex:0,onClick:()=>P(n),onKeyDown:e=>(e.key===`Enter`||e.key===` `)&&P(n),style:{display:`block`,borderRadius:`inherit`,cursor:`zoom-in`},children:r}):r;return(0,W.jsx)(`div`,{...G(`tile`),style:{breakInside:`avoid`,marginBottom:j,borderRadius:`inherit`,overflow:`hidden`},children:i},n)}),!k.length&&!A&&(0,W.jsx)(`div`,{...G(`empty`),style:{padding:`24px 12px`,fontSize:13,opacity:.55,textAlign:`center`,columnSpan:`all`},children:t?s||`No images yet`:`Pick images in Settings to fill the gallery`}),F&&(0,W.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,onClick:()=>P(null),style:{position:`fixed`,inset:0,zIndex:1400,background:`rgba(0, 0, 0, 0.86)`,display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,padding:24},children:[(0,W.jsx)(`img`,{src:k[N].src,alt:k[N].alt??``,onClick:e=>e.stopPropagation(),style:{maxWidth:`92vw`,maxHeight:`84vh`,borderRadius:8,boxShadow:`0 12px 48px rgba(0,0,0,0.5)`}}),I(k[N])&&(0,W.jsx)(`div`,{style:{color:`#fff`,fontSize:14,marginTop:12,opacity:.85},children:I(k[N])}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:()=>P(null),style:{position:`absolute`,top:16,right:20,background:`transparent`,border:0,color:`#fff`,fontSize:28,lineHeight:1,cursor:`pointer`},children:`×`}),k.length>1&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`button`,{type:`button`,"aria-label":`Previous`,onClick:e=>{e.stopPropagation(),P(e=>(e-1+k.length)%k.length)},style:{position:`absolute`,left:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`‹`}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Next`,onClick:e=>{e.stopPropagation(),P(e=>(e+1)%k.length)},style:{position:`absolute`,right:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`›`})]})]})]})}var Ti=e=>{let t=Array.isArray(e)?e[0]:e;return t&&typeof t==`object`?String(t.url??t.href??t.link??``):t==null?``:String(t)},Ei=e=>String(e??``).trim().toLowerCase().split(/[-_]/)[0];function Di(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=Ei(t.language),i=n.filter(e=>!t.langField||!r||Ei(Jn(e.data?.[t.langField]))===r),a=e=>String(e.data?.slug??e.slug??``),o=e=>{if(!t.parentField)return``;let n=e.data?.[t.parentField],r=Array.isArray(n)?n[0]:n;return r&&typeof r==`object`?String(r.id??r.slug??``):r==null?``:String(r)},s=e=>{let n=Number(t.orderField?Jn(e.data?.[t.orderField]):NaN);return Number.isFinite(n)?n:1/0},c=(e,t)=>s(e)-s(t)||a(e).localeCompare(a(t),void 0,{numeric:!0}),l=new Map;for(let e of i)l.set(String(e.id),e),a(e)&&l.set(a(e),e);let u=new Map;for(let e of i){let t=l.get(o(e)),n=t&&t!==e?t.id:``;u.has(n)||u.set(n,[]),u.get(n).push(e)}let d=[];if(t.root===`parent`){let e=t.rootEntry?l.get(String(t.rootEntry)):null;d=e?u.get(e.id)??[]:[]}else{let e=e=>!t.groupField||Jn(e.data?.[t.groupField])===String(t.groupValue??``);d=i.filter(t=>{if(!e(t))return!1;let n=l.get(o(t));return!n||n===t||!e(n)})}let f=Math.max(0,Number(t.depth)||0),p=new Set,m=(e,n)=>{if(p.has(e.id))return null;p.add(e.id);let r=f===0||n<f?u.get(e.id)??[]:[];return{key:e.id,label:Jn(e.data?.[t.labelField||`name`])||Jn(e.data?.name)||`Untitled`,href:_t(t.hrefField?Ti(e.data?.[t.hrefField]):``),icon:t.iconField?Jn(e.data?.[t.iconField]).trim():``,children:[...r].sort(c).map(e=>m(e,n+1)).filter(Boolean)}};return[...d].sort(c).map(e=>m(e,1)).filter(Boolean)}var K=(e,t)=>{if(!e||!t||!e.startsWith(`/`))return!1;let n=e=>e.length>1?e.replace(/\/+$/,``):e,r=n(e.split(/[?#]/)[0]),i=n(t);return r===i||r.length>1&&i.endsWith(r)&&i.charAt(i.length-r.length-1)===`/`},Oi=ir({display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:8,padding:`10px 16px`,color:`inherit`,textDecoration:`none`});function ki({source:e=``,labelField:t=``,hrefField:n=``,parentField:r=``,orderField:i=``,langField:a=``,root:o=`group`,groupField:s=``,groupValue:c=``,rootEntry:u=``,depth:d=0,expand:f=`current`,toggleOnClick:p=!0,indent:m=16,lines:h=`none`,lineColor:g=``,iconField:_=``,branchIcon:v=``,leafIcon:y=``,toggleIcon:b=`caret`,toggleSize:x=16,dividers:S=`none`,dividerColor:C=``,dividerWidth:w=1,linkColor:T=``,hoverBg:E=``,hoverColor:D=``,currentBg:O=``,currentColor:k=``,placeholder:A=``,style:j,nodeRef:M}){let{tenant:N,apiUrl:P,revision:F,locale:I}=(0,l.useContext)(Nn),L=(0,l.useContext)(Pn)?.[e],R=Number(m)||0,ee=(h===`solid`||h===`dotted`)&&R>=8,te=ee?`1px ${h} ${g||`currentColor`}`:``,B=g?1:.5,V=e=>16+(e-2)*R+6,H=`wb-mt-${(0,l.useId)().replace(/[^a-zA-Z0-9_-]/g,``)}`,ne=[`solid`,`dashed`,`dotted`].includes(S)?`${Math.min(Math.max(Number(w)||1,1),8)}px ${S} ${C||`rgba(148, 163, 184, 0.35)`}`:``,re=[ne&&`.${H} [data-wb-part~="link"]{border-top:${ne};}.${H} > [data-wb-part~="item"]:first-of-type > [data-wb-part~="link"]{border-top:0;}`,T&&`.${H} a{color:${T} !important;}`,(E||D)&&`.${H} a:hover{${E?`background-color:${E} !important;`:``}${D?`color:${D} !important;`:``}}`,(O||k)&&`.${H} a[aria-current="page"]{${O?`background-color:${O} !important;`:``}${k?`color:${k} !important;`:``}}`].filter(Boolean).join(``),ie=e=>{let t=e.icon||(e.children.length>0?v:y);return t?/^(https?:)?\/\/|^\//.test(t)?(0,W.jsx)(`img`,{...G(`icon`),src:t,alt:``,style:{width:18,height:18,objectFit:`contain`,flexShrink:0}}):xi[t]?(0,W.jsx)(`svg`,{...G(`icon`),viewBox:`0 0 24 24`,width:`18`,height:`18`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{flexShrink:0,opacity:.8},children:(0,W.jsx)(`path`,{d:xi[t]})}):null:null},ae=Math.min(Math.max(Number(x)||16,8),40),oe=e=>b===`plus`?(0,W.jsx)(`path`,{d:e?xi.minus:xi.plus}):b===`chevron`?(0,W.jsx)(`path`,{d:xi[`chevron-right`]}):null,[se,ce]=(0,l.useState)(null),[le,ue]=(0,l.useState)(``),[de,fe]=(0,l.useState)({});(0,l.useEffect)(()=>{ue(window.location.pathname)},[]),(0,l.useEffect)(()=>{if(!e||L)return;let t=!0,n=new URLSearchParams({all:`1`});return I&&n.set(`locale`,I),fetch(`${P}/dynamic/${encodeURIComponent(e)}?${n}`,{headers:N?{"x-tenant":N}:{}}).then(e=>e.json()).then(e=>{let n=Array.isArray(e?.payload)?e.payload:Array.isArray(e?.payload?.data)?e.payload.data:[];t&&ce(n)}).catch(()=>t&&ce([])),()=>{t=!1}},[F,e,N,P,I,L]);let pe=(0,l.useMemo)(()=>Di(L??se??[],{labelField:t,hrefField:n,parentField:r,orderField:i,langField:a,language:I,root:o,groupField:s,groupValue:c,rootEntry:u,depth:d,iconField:_}),[L,se,t,n,r,i,a,I,o,s,c,u,d,_]),me=(0,l.useMemo)(()=>{let e=new Set,t=(n,r)=>n.some(n=>K(n.href,le)?([...r,n.key].forEach(t=>e.add(t)),!0):t(n.children,[...r,n.key]));return t(pe,[]),e},[pe,le]),he=e=>e.key in de?de[e.key]:f===`all`||f===`current`&&me.has(e.key),ge=e=>fe(t=>({...t,[e.key]:!he(e)})),_e=(e,t)=>({position:`absolute`,left:V(e),pointerEvents:`none`,opacity:B,borderLeft:te,...t}),ve=(e,t,n)=>!ee||e<2?null:(0,W.jsxs)(W.Fragment,{children:[t.map((e,t)=>e?(0,W.jsx)(`span`,{...G(`line`),"aria-hidden":!0,style:_e(t+2,{top:0,bottom:0})},t):null),(0,W.jsx)(`span`,{...G(`line`),"aria-hidden":!0,style:_e(e,n?{top:0,height:`50%`}:{top:0,bottom:0})}),(0,W.jsx)(`span`,{...G(`line`),"aria-hidden":!0,style:{position:`absolute`,left:V(e),top:`50%`,width:Math.max(4,R-8),pointerEvents:`none`,opacity:B,borderTop:te}})]}),ye=(e,t,n=[])=>e.map((r,i)=>{let a=r.children.length>0,o=a&&he(r),s=K(r.href,le),c=ee&&t>1,l=i===e.length-1;return(0,W.jsxs)(`div`,{...G(`item`,o&&`item-open`),children:[(0,W.jsxs)(`a`,{...G(`link`,s&&`link-current`),href:r.href||`#`,"aria-current":s?`page`:void 0,"aria-expanded":a?o:void 0,onClick:a&&(p||!r.href)?e=>{e.preventDefault(),ge(r)}:void 0,style:{...Oi,paddingLeft:16+(t-1)*R,fontWeight:s?600:void 0,...c?{position:`relative`}:null},children:[ve(t,n,l),(0,W.jsxs)(`span`,{style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[ie(r),(0,W.jsx)(`span`,{...G(`label`),children:r.label})]}),a?(0,W.jsx)(`span`,{role:`button`,tabIndex:-1,"aria-label":o?`Collapse`:`Expand`,onClick:e=>{e.preventDefault(),e.stopPropagation(),ge(r)},style:{flexShrink:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,margin:`-8px -8px -8px 0`,padding:8,cursor:`pointer`},children:b===`plus`||b===`chevron`?(0,W.jsx)(`svg`,{...G(`toggle`),viewBox:`0 0 24 24`,width:ae+2,height:ae+2,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{transition:`transform .2s`,transform:b===`chevron`&&o?`rotate(90deg)`:`none`},children:oe(o)}):(0,W.jsx)(`svg`,{...G(`toggle`),viewBox:`0 0 24 24`,width:ae,height:ae,"aria-hidden":!0,style:{transition:`transform .2s`,transform:o?`rotate(180deg)`:`none`},children:(0,W.jsx)(`path`,{d:`M5 8.5h14L12 17z`,fill:`currentColor`})})}):null]}),o?(0,W.jsx)(`div`,{...G(`children`),children:ye(r.children,t+1,t>1?[...n,!l]:n)}):null]},r.key)});return(0,W.jsxs)(`nav`,{ref:M,"aria-label":`Menu`,className:re?H:void 0,style:{...z(j)},children:[re?(0,W.jsx)(`style`,{children:re}):null,pe.length?ye(pe,1):A?(0,W.jsx)(`div`,{...G(`empty`),style:{padding:`10px 16px`,opacity:.6,fontSize:14},children:A}):null]})}var Ai={color:`inherit`,textDecoration:`none`,fontSize:14,opacity:.85},ji=ir({background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.25)`,boxShadow:`0 16px 40px rgba(15, 23, 42, 0.16)`,zIndex:60});function Mi(e,t={},n=`dropdown`){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],i=e=>Array.isArray(e)?e[0]:e,a=e=>e==null?``:Jn(e),o=r.map(e=>{let n=e.data??{},r=t.parentField?i(n[t.parentField]):null;return{key:e.id,parent:(r&&typeof r==`object`?r.id:r)||null,label:a(n[t.labelField||`name`])||a(n.name)||`Untitled`,href:t.hrefField?a(n[t.hrefField]):``,image:t.imageField&&i(n[t.imageField])||``,desc:t.descField?a(n[t.descField]):``}}),s=new Map(o.map(e=>[e.key,e])),c=e=>{let t=new Set,n=e;for(;n.parent&&s.has(n.parent)&&!t.has(n.key);)t.add(n.key),n=s.get(n.parent);return n},l=[],u=new Map;for(let e of o){if(c(e)!==e)continue;let t={key:e.key,label:e.label,href:e.href,image:e.image,children:[]};u.set(e.key,t),l.push(t)}for(let e of o){let t=c(e);t!==e&&u.get(t.key)?.children.push({key:e.key,label:e.label,href:e.href,image:e.image,desc:e.desc})}return l.map(e=>({...e,type:e.children.length?n:`link`}))}function Ni({brand:e,logo:t,brandHref:n,brandTarget:r,links:i=[],style:a,nodeRef:o,menu:s=`auto`,breakpoint:c=768,source:u=``,labelField:d=``,hrefField:f=``,imageField:p=``,descField:m=``,parentField:h=``,submenu:g=`dropdown`}){let[_,v]=(0,l.useState)(null),[y,b]=(0,l.useState)(!1),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(null),{tenant:T,apiUrl:E,revision:D,locale:O}=(0,l.useContext)(Nn),k=Xe(O),A=(0,l.useId)(),j=(0,l.useContext)(Pn)?.[u],[M,N]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!u||j)return;let e=!0;return fetch(`${E}/dynamic/${encodeURIComponent(u)}`,{headers:T?{"x-tenant":T}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&N(n)}).catch(()=>e&&N([])),()=>{e=!1}},[D,u,T,E,j]),(0,l.useEffect)(()=>{if(!_)return;let e=new ResizeObserver(()=>b(_.offsetWidth<c));return e.observe(_),()=>e.disconnect()},[_,c]);let P=u?Mi(j??M??[],{labelField:d,hrefField:f,imageField:p,descField:m,parentField:h},g):i,F=s===`hamburger`||s===`auto`&&y,I=(e,t,n=!1)=>{let r=e.image?(0,W.jsx)(`img`,{...G(`sublink-image`),src:e.image,alt:``,style:n?{width:`100%`,aspectRatio:`16 / 9`,objectFit:`cover`,borderRadius:6,display:`block`,marginBottom:8}:{width:22,height:22,objectFit:`cover`,borderRadius:4,display:`block`,flexShrink:0}}):null;return(0,W.jsxs)(`a`,{...G(`sublink`,n&&`sublink-card`),href:e.href||`#`,style:{...Ai,display:n?`block`:`flex`,alignItems:n?void 0:`center`,gap:n?void 0:10,...t},children:[r,(0,W.jsxs)(`span`,{...G(`sublink-label`),style:{display:`block`,minWidth:0},children:[e.label,e.desc&&(0,W.jsx)(`span`,{...G(`sublink-desc`),style:{display:`block`,fontSize:12,opacity:.6,marginTop:2},children:e.desc})]})]},e.key)};return(0,W.jsxs)(`nav`,{ref:e=>{v(e),o&&o(e)},style:{display:`flex`,alignItems:`center`,gap:24,flexWrap:`wrap`,padding:`14px 24px`,width:`100%`,position:`relative`,...z(a)},children:[(t||e)&&(()=>{let i=(0,W.jsxs)(W.Fragment,{children:[t&&(0,W.jsx)(`img`,{...G(`logo`),src:t,alt:e||`Logo`,style:{height:28,display:`block`}}),e&&(0,W.jsx)(`span`,{...G(`brand-name`),style:{fontWeight:700,fontSize:18,fontFamily:`var(--page-heading-font, inherit)`},children:e})]}),a={display:`flex`,alignItems:`center`,gap:10,color:`inherit`,textDecoration:`none`};return n?(0,W.jsx)(`a`,{...G(`brand`),href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:a,children:i}):(0,W.jsx)(`div`,{...G(`brand`),style:a,children:i})})(),(0,W.jsx)(`div`,{style:{flexGrow:1}}),F?(0,W.jsx)(`button`,{type:`button`,...G(`menu-button`),"aria-label":k(x?`closeMenu`:`openMenu`),"aria-expanded":x,"aria-controls":x?`${A}-menu`:void 0,onClick:()=>S(!x),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4},children:x?`✕`:`☰`}):(0,W.jsx)(`div`,{...G(`links`),style:{display:`flex`,gap:20,alignItems:`center`,flexWrap:`wrap`},children:P.map(e=>{let t=e.children??[];if(!t.length)return(0,W.jsx)(`a`,{...G(`link`),href:e.href||`#`,style:Ai,children:e.label},e.key);let n=e.type===`mega`,r=`${A}-${e.key}`;return(0,W.jsxs)(`span`,{style:{position:n?`static`:`relative`,display:`inline-flex`},onMouseEnter:()=>w(e.key),onMouseLeave:()=>w(null),onFocus:t=>{t.currentTarget.contains(t.relatedTarget)||w(e.key)},onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||w(null)},onKeyDown:t=>{let n=t.currentTarget;t.key===`Escape`&&C===e.key?(t.stopPropagation(),w(null),n.querySelector(`a`)?.focus()):t.key===`ArrowDown`&&C!==e.key&&(t.preventDefault(),w(e.key),setTimeout(()=>n.querySelectorAll(`a`)[1]?.focus(),0))},children:[(0,W.jsxs)(`a`,{...G(`link`),href:e.href||`#`,"aria-haspopup":`true`,"aria-expanded":C===e.key,"aria-controls":C===e.key?r:void 0,style:{...Ai,cursor:`pointer`},children:[e.label,` `,(0,W.jsx)(`span`,{...G(`chevron`),"aria-hidden":`true`,style:{fontSize:9,opacity:.6},children:`▼`})]}),C===e.key&&(n?(0,W.jsx)(`div`,{id:r,...G(`mega-panel`),style:{...ji,position:`absolute`,left:0,right:0,top:`100%`,padding:24,display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(170px, 1fr))`,gap:16},children:t.map(e=>I(e,{padding:8,borderRadius:8},!0))}):(0,W.jsx)(`div`,{id:r,...G(`dropdown-panel`),style:{...ji,position:`absolute`,top:`100%`,left:0,minWidth:190,borderRadius:8,padding:8,display:`flex`,flexDirection:`column`},children:t.map(e=>I(e,{padding:`8px 12px`,borderRadius:6}))}))]},e.key)})}),F&&x&&(0,W.jsx)(`div`,{id:`${A}-menu`,...G(`mobile-menu`),style:{flexBasis:`100%`,width:`100%`,display:`flex`,flexDirection:`column`,paddingTop:10},children:P.map(e=>(0,W.jsxs)(l.Fragment,{children:[(0,W.jsx)(`a`,{...G(`mobile-link`),href:e.href||`#`,style:{...Ai,padding:`10px 4px`,fontWeight:(e.children??[]).length?600:400,opacity:1},children:e.label}),(e.children??[]).map(e=>I(e,{padding:`8px 4px 8px 22px`}))]},e.key))})]})}function Pi({tabs:e=[],linked:t,style:n,nodeRef:r}){let[i,a]=(0,l.useState)(0),{locale:o}=(0,l.useContext)(Nn),s=(0,l.useId)(),c=(0,l.useRef)(null),u=e.length?Math.min(i,e.length-1):0;if(!e.length)return null;let d=Xe(o),f=t=>{let n=e.length-1,r={ArrowRight:(u+1)%e.length,ArrowLeft:(u-1+e.length)%e.length,Home:0,End:n}[t.key];r!==void 0&&(t.preventDefault(),a(r),c.current?.querySelectorAll(`[role="tab"]`)[r]?.focus())};return(0,W.jsxs)(`div`,{ref:r,style:{width:`100%`,...z(n)},children:[(0,W.jsx)(`div`,{ref:c,role:`tablist`,...G(`tab-list`),onKeyDown:f,style:{display:`flex`,gap:4,borderBottom:`1px solid rgba(148, 163, 184, 0.35)`},children:e.map((e,t)=>(0,W.jsx)(`button`,{...G(`tab`,t===u&&`tab-active`),type:`button`,role:`tab`,id:`${s}-tab-${e.key}`,"aria-selected":t===u,"aria-controls":`${s}-panel-${e.key}`,tabIndex:t===u?0:-1,onClick:()=>a(t),style:{background:`transparent`,border:0,padding:`10px 16px`,fontSize:14,fontFamily:`inherit`,color:`inherit`,cursor:`pointer`,opacity:t===u?1:.6,fontWeight:t===u?600:500,boxShadow:t===u?`inset 0 -2px 0 var(--page-accent, #111827)`:`none`},children:e.label||d(`tab`,{n:t+1})},e.key))}),e.map((e,n)=>(0,W.jsx)(`div`,{...G(`panel`),role:`tabpanel`,id:`${s}-panel-${e.key}`,"aria-labelledby":`${s}-tab-${e.key}`,tabIndex:0,hidden:n!==u,style:{display:n===u?`flex`:`none`,flexDirection:`column`},children:t?.[e.key]??null},e.key))]})}function Fi({items:e=[],linked:t,multiple:n=!1,icon:r=``,padX:i,padY:a,headerBg:o,headerColor:s,openBg:c,openColor:u,borderColor:d,style:f,nodeRef:p}){let[m,h]=(0,l.useState)(()=>new Set(e.length?[e[0].key]:[])),{locale:g}=(0,l.useContext)(Nn),_=(0,l.useId)();if(!e.length)return null;let v=Xe(g),y=(e,t)=>typeof e==`string`&&e?e:t,b=(e,t)=>{let n=Number(e);return e===``||e==null||!Number.isFinite(n)?t:n},x=xi[r],S=e=>h(t=>{let r=new Set(n?t:[]);return t.has(e)?r.delete(e):r.add(e),r});return(0,W.jsx)(`div`,{ref:p,style:{width:`100%`,...z(f)},children:e.map((n,r)=>{let l=m.has(n.key);return(0,W.jsxs)(`div`,{...G(`item`,l&&`item-open`),style:{borderBottom:r<e.length-1?`1px solid ${y(d,`rgba(148, 163, 184, 0.35)`)}`:`none`},children:[(0,W.jsxs)(`button`,{type:`button`,...G(`header`,l&&`header-open`),id:`${_}-h-${n.key}`,"aria-expanded":l,"aria-controls":`${_}-b-${n.key}`,onClick:()=>S(n.key),style:{width:`100%`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:12,background:l?y(c,y(o,`transparent`)):y(o,`transparent`),border:0,padding:`${b(a,14)}px ${b(i,4)}px`,fontSize:15,fontWeight:600,fontFamily:`inherit`,color:l?y(u,y(s,`inherit`)):y(s,`inherit`),textAlign:`left`,cursor:`pointer`,transition:`background 180ms, color 180ms`},children:[(0,W.jsxs)(`span`,{...G(`title`),style:{display:`flex`,alignItems:`center`,gap:10,minWidth:0},children:[x?(0,W.jsx)(`svg`,{...G(`icon`),viewBox:`0 0 24 24`,width:16,height:16,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,style:{flexShrink:0},children:(0,W.jsx)(`path`,{d:x})}):null,n.title||v(`item`,{n:r+1})]}),(0,W.jsx)(`span`,{"aria-hidden":`true`,...G(`chevron`),style:{fontSize:12,opacity:.6,transform:l?`rotate(180deg)`:`none`,transition:`transform 180ms`},children:`▼`})]}),(0,W.jsx)(`div`,{...G(`body`),id:`${_}-b-${n.key}`,role:`region`,"aria-labelledby":`${_}-h-${n.key}`,hidden:!l,style:{display:l?`flex`:`none`,flexDirection:`column`},children:t?.[n.key]??null})]},n.key)})})}var Ii={display:`flex`,flexDirection:`column`,gap:`12px`},Li={fontSize:`14px`,fontWeight:500,color:`var(--page-text, #111827)`},q=ir({padding:`10px 12px`,border:`1px solid var(--page-border, #d1d5db)`,borderRadius:`6px`,fontSize:`14px`,fontFamily:`inherit`,width:`100%`,boxSizing:`border-box`,backgroundColor:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`}),Ri={display:`flex`,alignItems:`center`,gap:`8px`,fontSize:`14px`,color:`var(--page-text, #111827)`},zi=e=>e?{readOnly:!0,tabIndex:-1,onMouseDown:e=>e.preventDefault()}:{};function Bi(e,t){if(!e)return!0;let n=t[e.field],r=n==null||n===``?``:String(n),i=e.value??``;switch(e.op){case`eq`:return r===i;case`neq`:return r!==i;case`contains`:return r.toLowerCase().includes(i.toLowerCase());case`gt`:return Number(r)>Number(i);case`lt`:return Number(r)<Number(i);case`empty`:return r===``;case`notEmpty`:return r!==``;default:return!1}}var Vi={display:`flex`,flexDirection:`column`,gap:6},Hi=`#dc2626`,Ui={fontSize:13,fontWeight:500,color:Hi},Wi=ir({font:`inherit`,fontSize:15,padding:`10px 12px`,borderRadius:8,border:`1px solid rgba(148, 163, 184, 0.55)`,background:`transparent`,color:`inherit`,width:`100%`,boxSizing:`border-box`});function Gi(e,t){let n=Array.isArray(e?.options)?e.options:[];if(!e?.parentField)return n;let r=t?.[e.parentField];return r?n.filter(e=>typeof e==`string`?!1:!e.parent||e.parent===r):[]}var Ki=`g-recaptcha-response`,qi=e=>e?.type===`recaptcha`?Ki:e?.name,Ji=[[/^(full_?name|name|ad_?soyad|adsoyad|isim)$/,`name`],[/^(first_?name|given_?name|ad|adi|adiniz)$/,`given-name`],[/^(last_?name|family_?name|surname|soyad|soyadi|soyadiniz)$/,`family-name`],[/^(e_?mail|e_?posta|eposta|mail)$/,`email`],[/^(phone|tel|telephone|mobile|gsm|telefon|cep)$/,`tel`],[/^(company|organization|organisation|firma|sirket|kurum)$/,`organization`],[/^(address|street|adres|sokak)$/,`street-address`],[/^(city|town|sehir|il)$/,`address-level2`],[/^(district|ilce)$/,`address-level3`],[/^(zip|zip_?code|postal_?code|postcode|posta_?kodu)$/,`postal-code`],[/^(country|ulke)$/,`country-name`],[/^(website|web|url|site)$/,`url`]];function Yi(e){if(typeof e.autocomplete==`string`&&e.autocomplete)return e.autocomplete;let t={email:`email`,phone:`tel`,link:`url`}[e.type];if(t)return t;let n=String(e.name??``).toLowerCase();return Ji.find(([e])=>e.test(n))?.[1]}function Xi({field:e,value:t,onChange:n,inert:r,values:i,error:a,idBase:o}){let s=Xe((0,l.useContext)(Nn).locale),c=`${o}-${e.name}`,u=e.help?`${c}-help`:null,d=a?`${c}-error`:null,f=(0,W.jsxs)(`label`,{...G(`label`),htmlFor:c,style:{...Li,fontSize:14},children:[e.label,e.required?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,children:` *`}),(0,W.jsxs)(`span`,{style:Ze,children:[` (`,s(`required`),`)`]})]}):null]}),p=[u,d].filter(Boolean).join(` `)||void 0,m={id:c,"aria-invalid":a?!0:void 0,"aria-describedby":p},h={...G(`input`),...m,name:e.name,required:e.required||void 0,placeholder:e.placeholder||void 0,disabled:r||void 0,autoComplete:Yi(e),style:a?{...Wi,borderTopColor:Hi,borderRightColor:Hi,borderBottomColor:Hi,borderLeftColor:Hi}:Wi,value:t??``,onChange:t=>n(e.name,t.target.value)};return e.type===`display`?(0,W.jsx)(e.variant&&e.variant!==`p`?e.variant:`p`,{...G(`text`),style:{margin:0,color:e.color||`inherit`,fontSize:{h1:32,h2:26,h3:21,h4:18,h5:16,h6:14,p:15}[e.variant]??16,fontWeight:e.variant===`p`?400:700,lineHeight:1.35},children:e.label}):e.type===`image`?e.src?(0,W.jsx)(`img`,{...G(`image`),src:e.src,alt:e.label??``,style:{width:`100%`,borderRadius:8,display:`block`}}):null:e.type===`recaptcha`?(0,W.jsxs)(`div`,{...G(`field`),id:c,tabIndex:-1,style:Vi,children:[(0,W.jsx)(ta,{theme:e.captchaTheme,size:e.captchaSize,inert:r,onChange:e=>n(Ki,e)}),a&&(0,W.jsx)(`span`,{...G(`error`),id:d,style:Ui,children:a})]}):e.type===`video`?e.src?/youtube\.com|youtu\.be|vimeo\.com/i.test(e.src)?(0,W.jsx)(qr,{url:e.src,style:{width:`100%`}}):(0,W.jsx)(`video`,{...G(`video`),src:e.src,controls:!0,style:{width:`100%`,borderRadius:8,display:`block`}}):null:(0,W.jsxs)(`div`,{...G(`field`),style:Vi,children:[f,e.type===`textarea`||e.multiline?(0,W.jsx)(`textarea`,{...h,...G(`textarea`),rows:4,style:{...Wi,resize:`vertical`}}):e.type===`select`?(0,W.jsxs)(`select`,{...h,...G(`select`),disabled:h.disabled||!!e.parentField&&!i?.[e.parentField],children:[(0,W.jsx)(`option`,{value:``,children:e.placeholder||`—`}),Gi(e,i).map((e,t)=>(0,W.jsx)(`option`,{value:typeof e==`string`?e:e.value,children:typeof e==`string`?e:e.label??e.value},t))]}):e.type===`checkbox`?(0,W.jsx)(`input`,{type:`checkbox`,...G(`checkbox`),...m,name:e.name,required:e.required||void 0,disabled:r||void 0,checked:!!t,onChange:t=>n(e.name,t.target.checked),style:{width:18,height:18}}):e.type===`upload`?(0,W.jsx)(`input`,{type:`file`,...G(`file`),...m,name:e.name,accept:e.accept||void 0,required:e.required||void 0,disabled:r||void 0,onChange:t=>n(e.name,t.target.files?.[0]?.name??``),style:{font:`inherit`,fontSize:14}}):(0,W.jsx)(`input`,{...h,type:{email:`email`,number:`number`,date:`date`,datetime:`datetime-local`,phone:`tel`,link:`url`}[e.type]??`text`}),e.help&&(0,W.jsx)(`span`,{...G(`help`),id:u,style:{fontSize:12,opacity:.65},children:e.help}),a&&(0,W.jsx)(`span`,{...G(`error`),id:d,style:Ui,children:a})]})}function Zi({style:e,action:t,method:n,name:r,enctype:i,formSlug:a,auto:o,submitLabel:s,nodeRef:c,inert:u,children:d,linked:f,show:p}){let{tenant:m,apiUrl:h,locale:g}=(0,l.useContext)(Nn),[_,v]=(0,l.useState)(`form`),[y,b]=(0,l.useState)(null),[x,S]=(0,l.useState)({}),[C,w]=(0,l.useState)(0),[T,E]=(0,l.useState)({}),[D,O]=(0,l.useState)(``),k=(0,l.useId)(),A=(0,l.useRef)(null),j=(0,l.useRef)(null),M=u?p||`form`:_,N=Xe(g);(0,l.useEffect)(()=>{if(!o||!a)return;let e=!0;return fetch(`${h||`/api`}/forms/${encodeURIComponent(a)}`,{headers:m?{"x-tenant":m}:{}}).then(e=>e.json()).then(t=>e&&b(t?.payload&&typeof t.payload==`object`?t.payload:null)).catch(()=>e&&b(null)),()=>{e=!1}},[o,a,m,h]);let P=[{section:null,fields:[]}];for(let e of Array.isArray(y?.fields)?y.fields:[])e.type===`section`?P.push({section:e,fields:[]}):P[P.length-1].fields.push(e);let F=P.filter(e=>e.section||e.fields.length),I=F.filter(e=>!e.section||Bi(e.section.condition,x)).map(e=>({...e,fields:e.fields.filter(e=>Bi(e.condition,x))})),L=F.length>1,R=Math.min(C,Math.max(0,I.length-1)),ee=L?I[R]?.fields??[]:I.flatMap(e=>e.fields),te=ee.filter(e=>{let t=x[qi(e)];return e.required&&(t==null||t===``||t===!1)}),B=R>=I.length-1,V=(e,t)=>{E(t=>{let n=e===`g-recaptcha-response`?(Array.isArray(y?.fields)?y.fields:[]).find(e=>e?.type===`recaptcha`)?.name:e;if(!n||!t[n])return t;let r={...t};return delete r[n],r}),S(n=>{let r={...n,[e]:t};for(let t of Array.isArray(y?.fields)?y.fields:[])t?.parentField===e&&delete r[t.name];return r})},H=()=>{let e={};for(let t of ee){if(t.type===`recaptcha`){t.required&&!x[`g-recaptcha-response`]&&(e[t.name]=N(`fieldRequired`));continue}let n=A.current?.querySelector(`[name="${CSS.escape(String(t.name??``))}"]`);!n?.validity||n.validity.valid||(e[t.name]=n.validity.valueMissing?N(`fieldRequired`):n.validationMessage||N(`invalid`))}E(e);let t=ee.find(t=>e[t.name]);return t&&setTimeout(()=>document.getElementById(`${k}-${t.name}`)?.focus(),0),!t},ne=e=>{v(e),O(N(e===`success`?`submitted`:`submitFailed`)),e===`success`&&setTimeout(()=>j.current?.focus(),0)};return(0,W.jsxs)(`div`,{ref:c,style:z(e),children:[(0,W.jsx)(`form`,{ref:A,action:t||void 0,method:n||`post`,name:r||void 0,encType:i||void 0,noValidate:o&&a?!0:void 0,onSubmit:async e=>{if(e.preventDefault(),!u&&!(o&&a&&!H())){if(a){let t={};if(o)for(let[e,n]of Object.entries(x))n!=null&&n!==``&&(t[e]=n);else for(let[n,r]of new FormData(e.currentTarget).entries())typeof r==`string`&&(t[n]=r===`on`||r);try{let e=await fetch(`${h||`/api`}/forms/${a}/submit`,{method:`post`,headers:{"content-type":`application/json`,...m?{"x-tenant":m}:{}},body:JSON.stringify(t)}),n=await e.json().catch(()=>null),r=n?.error,i=r?.details?.field;if(o&&typeof i==`string`&&ee.some(e=>e.name===i)){E({[i]:typeof r.message==`string`&&r.message||N(`invalid`)}),O(N(`submitFailed`)),setTimeout(()=>document.getElementById(`${k}-${i}`)?.focus(),0);return}ne(e.ok&&n?.success!==!1?`success`:`error`)}catch{ne(`error`)}return}if(!t){ne(`success`);return}try{let r=await fetch(t,{method:n||`post`,body:new FormData(e.currentTarget)});ne(r.ok?`success`:`error`)}catch{ne(`error`)}}},style:{...Ii,display:M===`success`?`none`:`flex`},children:o&&a?(0,W.jsxs)(W.Fragment,{children:[L&&(0,W.jsx)(Na,{steps:I.map(e=>({label:e.section?.label??N(`start`)})),active:R+1,style:{marginBottom:8}}),L&&I[R]?.section?.help&&(0,W.jsx)(`p`,{...G(`step-help`),style:{margin:0,fontSize:14,opacity:.7},children:I[R].section.help}),ee.some(e=>e.required)&&(0,W.jsx)(`p`,{...G(`required-note`),style:{margin:0,fontSize:13,opacity:.7},children:N(`requiredNote`)}),ee.map(e=>(0,W.jsx)(Xi,{field:e,value:x[qi(e)],values:x,onChange:V,inert:u,error:T[e.name],idBase:k},e.name)),(0,W.jsxs)(`div`,{...G(`actions`),style:{display:`flex`,gap:10,alignItems:`center`,marginTop:4},children:[L&&R>0&&(0,W.jsx)(`button`,{type:`button`,...G(`back-button`),disabled:u||void 0,onClick:()=>{E({}),w(R-1)},style:{...lr,background:`transparent`,color:`inherit`,border:0,padding:`10px 16px`,cursor:`pointer`},children:N(`back`)}),L&&!B?(0,W.jsx)(`button`,{type:`button`,...G(`next-button`),disabled:u||void 0,onClick:()=>{H()&&w(R+1)},style:{...lr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:te.length?.75:1},children:N(`next`)}):(0,W.jsx)(`button`,{type:`submit`,...G(`submit-button`),disabled:u||void 0,style:{...lr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`},children:s||N(`submit`)})]})]}):d}),(0,W.jsx)(`div`,{ref:j,tabIndex:-1,style:{display:M===`success`?`block`:`none`,outline:`none`},children:f?.success??null}),(0,W.jsx)(`div`,{style:{display:M===`error`?`block`:`none`,marginTop:12},children:f?.error??null}),!u&&(0,W.jsx)(`div`,{role:`status`,"aria-live":`polite`,style:Ze,children:D})]})}var Qi=null,$i=null,ea=e=>{let t=typeof e==`string`&&e.trim()?e.trim():``;if(Qi&&$i===t)return Qi;if(Qi&&typeof window<`u`){for(let e of[`grecaptcha`,`___grecaptcha_cfg`])try{delete window[e]}catch{window[e]=void 0}document.querySelectorAll(`script[src*="recaptcha"]`).forEach(e=>e.remove())}return $i=t,Qi=new Promise(e=>{if(typeof window>`u`)return;if(window.grecaptcha?.render)return e(window.grecaptcha);window.__webimRecaptchaReady=()=>e(window.grecaptcha);let n=document.createElement(`script`);n.src=`https://www.google.com/recaptcha/api.js?onload=__webimRecaptchaReady&render=explicit${t?`&hl=${encodeURIComponent(t)}`:``}`,n.async=!0,document.head.appendChild(n)}),Qi};function ta({siteKey:e,theme:t,size:n,hl:r,style:i,nodeRef:a,inert:o,onChange:s}){let c=(0,l.useContext)(Nn),u=c?.settings&&typeof c.settings==`object`?c.settings[`google.recaptchaKey`]:``,d=typeof e==`string`&&e.trim()||(typeof u==`string`?u.trim():``),f=(0,l.useRef)(null),p=(0,l.useRef)(s);if(p.current=s,(0,l.useEffect)(()=>{if(o||!d||!f.current)return;let e=!0,i=t=>{e&&typeof p.current==`function`&&p.current(t)};return ea(r).then(r=>{if(!(!e||!f.current||!r?.render)){f.current.innerHTML=``,i(``);try{r.render(f.current,{sitekey:d,theme:t===`dark`?`dark`:`light`,size:n===`compact`?`compact`:`normal`,callback:e=>i(typeof e==`string`?e:``),"expired-callback":()=>i(``),"error-callback":()=>i(``)})}catch{}}}),()=>{e=!1}},[o,d,t,n,r]),o){let e=t===`dark`;return(0,W.jsxs)(`div`,{ref:a,style:z(i),children:[(0,W.jsxs)(`div`,{style:{width:n===`compact`?164:302,boxSizing:`border-box`,padding:`12px 14px`,display:`flex`,alignItems:`center`,gap:12,borderRadius:4,border:`1px solid ${e?`#52565b`:`#d3d3d3`}`,background:e?`#222528`:`#f9f9f9`,color:e?`#f1f1f1`:`#282828`,fontSize:14,fontFamily:`Roboto, Arial, sans-serif`},children:[(0,W.jsx)(`span`,{style:{width:24,height:24,flexShrink:0,borderRadius:3,border:`2px solid ${e?`#8a8f94`:`#c1c1c1`}`,background:e?`#2f3337`:`#fff`}}),(0,W.jsx)(`span`,{style:{flexGrow:1},children:`I'm not a robot`}),(0,W.jsx)(`span`,{style:{fontSize:9,opacity:.6,textAlign:`center`,lineHeight:1.3},children:`reCAPTCHA`})]}),!d&&(0,W.jsx)(`div`,{style:{marginTop:6,fontSize:11,color:`#b45309`},children:`Set the google.recaptchaKey tenant setting (or a site key in Settings) to activate it.`})]})}return d?(0,W.jsx)(`div`,{ref:a,style:z(i),children:(0,W.jsx)(`div`,{ref:f})}):null}var na=e=>typeof e==`string`&&e.trim()?`wb-field-${e.trim()}`:void 0;function ra({text:e,parts:t,htmlFor:n,style:r,nodeRef:i,linked:a}){return(0,W.jsx)(`label`,{ref:i,htmlFor:n||void 0,style:{...Li,...z(r)},children:Sr(t,e,a)})}function ia({type:e=`text`,name:t,placeholder:n,required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsx)(`input`,{ref:a,id:na(t),type:e,name:t||void 0,autoComplete:Yi({name:t,type:{email:`email`,tel:`phone`,url:`link`}[e]}),placeholder:n,required:!o&&!!r,style:{...q,...z(i)},...zi(o)})}function aa({name:e,placeholder:t,rows:n=4,required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsx)(`textarea`,{ref:a,id:na(e),name:e||void 0,placeholder:t,rows:n,required:!o&&!!r,style:{...q,resize:`vertical`,...z(i)},...zi(o)})}function oa({kind:e=`checkbox`,label:t,name:n,value:r,required:i,style:a,nodeRef:o,inert:s}){return(0,W.jsxs)(`label`,{ref:o,style:{...Ri,...z(a)},children:[(0,W.jsx)(`input`,{type:e,...G(`control`),name:n||void 0,value:r||void 0,required:!s&&!!i,onClick:s?e=>e.preventDefault():void 0,tabIndex:s?-1:void 0,style:{margin:0,accentColor:`var(--page-accent, #111827)`}}),t]})}function sa({name:e,placeholder:t,options:n=[],required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsxs)(`select`,{ref:a,id:na(e),name:e||void 0,autoComplete:Yi({name:e}),required:!o&&!!r,defaultValue:``,onMouseDown:o?e=>e.preventDefault():void 0,tabIndex:o?-1:void 0,style:{...q,appearance:`auto`,...z(i)},children:[t!==``&&(0,W.jsx)(`option`,{value:``,disabled:!0,children:t??`Select…`}),n.map((e,t)=>(0,W.jsx)(`option`,{value:e,children:e},t))]})}function ca({name:e,accept:t,required:n,text:r=`Choose a file…`,style:i,nodeRef:a,inert:o}){let[s,c]=(0,l.useState)(null);return(0,W.jsxs)(`label`,{ref:a,className:`wb-file`,style:{...q,display:`flex`,alignItems:`center`,gap:`8px`,cursor:o?`default`:`pointer`,borderStyle:`dashed`,color:s?`#111827`:`#6b7280`,...z(i)},children:[(0,W.jsx)(`input`,{type:`file`,name:e||void 0,accept:t||void 0,required:!o&&!!n,disabled:!!o,onChange:e=>c(e.target.files?.[0]?.name??null),style:Ze}),(0,W.jsx)(`span`,{"aria-hidden":!0,...G(`icon`),children:`📎`}),s??r]})}function la({legend:e=``,style:t,nodeRef:n,children:r}){return(0,W.jsxs)(`fieldset`,{ref:n,style:{...ir({border:`0 none`,margin:`0`,padding:`0`}),minWidth:0,display:`flex`,flexDirection:`column`,gap:`10px`,...z(t)},children:[typeof e==`string`&&e.trim()?(0,W.jsx)(`legend`,{...G(`legend`),style:{...Li,padding:0,marginBottom:6},children:e}):null,r]})}function ua({text:e=`Submit`,style:t,nodeRef:n,inert:r}){return(0,W.jsx)(`button`,{ref:n,type:r?`button`:`submit`,style:{...lr,border:0,cursor:`pointer`,alignSelf:`flex-start`,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,lineHeight:1.4,fontFamily:`inherit`,...z(t)},children:e})}function da({cols:e=2,rows:t=1,style:n,nodeRef:r,linked:i}){let a=Math.max(1,(Number(e)||1)*(Number(t)||1));return(0,W.jsx)(`div`,{ref:r,style:{display:`grid`,gridTemplateColumns:`repeat(${Math.max(1,Number(e)||1)}, minmax(0, 1fr))`,gap:16,width:`100%`,...z(n)},children:Array.from({length:a},(e,t)=>(0,W.jsx)(`div`,{style:{minWidth:0},children:i?.[`cell-${t}`]??null},t))})}function fa(e,t){if(e===``||e==null)return t;let n=Number(e);return Number.isFinite(n)&&n>=0?n:t}function pa({collection:e,limit:t=6,layout:n=`grid`,columns:r=3,imageField:i,titleField:a=`name`,textField:o,custom:s,templateId:c,renderTemplate:u,paged:d,filters:f,parentField:p,topLevel:m,childrenOf:h,gap:g,style:_,nodeRef:v}){let{tenant:y,apiUrl:b,revision:x,locale:S}=(0,l.useContext)(Nn),C=(0,l.useContext)(Rn),w=(0,l.useContext)(Pn),T=(0,l.useContext)(zn),E=h?null:e,D=!!p&&!h,[,O]=(0,l.useState)(0);(0,l.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>O(e=>e+1);return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]);let k=Ln(f),A=JSON.stringify(k),j=A!==`{}`&&!E?.startsWith?.(`api:`),M=j||!E?null:w?.[E],N=d?Fn(w):1,[P,F]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!E||M)return;let e=!0,n=E,r=new URLSearchParams;if(S&&r.set(`locale`,S),j&&r.set(`data_filter`,A),D&&!n.startsWith(`api:`))r.set(`all`,`1`);else if(d&&!n.startsWith(`api:`)){let e=Math.max(1,Number(t)||6);r.set(`offset`,String((N-1)*e)),r.set(`limit`,String(e))}let i=r.toString(),a=n.startsWith(`api:`)?`${b}/data/${encodeURIComponent(n.slice(4))}`:`${b}/dynamic/${encodeURIComponent(n)}${i?`?${i}`:``}`;return fetch(a,{headers:y?{"x-tenant":y}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&F(n.filter(e=>e&&typeof e==`object`))}).catch(()=>e&&F([])),()=>{e=!1}},[x,E,y,b,S,M,d,N,t,j,A,D]),!E&&!h)return null;let I=Math.max(1,Number(t)||6),L=h?T?.all??[]:M??P??[],R=h?T?.parentField:p,ee=h?T?.collection:E,te=h?Vn(L,R,T?.entry):D&&m?L.filter(e=>Bn(e,p).length===0):L,B=d&&(M||h||D||E.startsWith(`api:`))?te.slice((N-1)*I,N*I):te.slice(0,I),V=Math.min(Math.max(Number(r)||3,1),6),H=n===`list`?{display:`flex`,flexDirection:`column`,gap:fa(g,20)}:{display:`grid`,gridTemplateColumns:`repeat(${V}, minmax(0, 1fr))`,gap:fa(g,24)},ne=u??(c&&C?.render?e=>C.render(c,e):null);return s&&ne?(0,W.jsx)(`div`,{ref:v,style:{width:`100%`,...H,...z(_)},children:B.map(e=>(0,W.jsx)(`div`,{style:{minWidth:0},children:(0,W.jsx)(zn.Provider,{value:{entry:e,all:L,parentField:R,collection:ee},children:ne(t=>tr(t,e,S))})},e.id??e?.data?.slug))}):(0,W.jsx)(`div`,{ref:v,style:{width:`100%`,...H,...z(_)},children:B.map(e=>{let t=i?Kn(e?.data,i):null,r=a?Jn(Kn(e?.data,a)):null,s=o?Kn(e?.data,o):null,c=Array.isArray(s)?s:null,l=c||s==null?null:Jn(s),u=n===`list`;return(0,W.jsxs)(`div`,{...G(`card`),style:{display:`flex`,flexDirection:u?`row`:`column`,gap:u?20:12,alignItems:u?`center`:`stretch`,minWidth:0},children:[t&&(0,W.jsx)(`img`,{...G(`image`),src:t,alt:r??``,style:{width:u?160:`100%`,aspectRatio:`3 / 2`,objectFit:`cover`,borderRadius:10,flexShrink:0,display:`block`}}),(0,W.jsxs)(`div`,{...G(`body`),style:{minWidth:0},children:[r&&(0,W.jsx)(`h3`,{...G(`title`),style:{margin:0,fontSize:18,fontWeight:700},children:r}),l&&(0,W.jsx)(`p`,{...G(`text`),style:{margin:`6px 0 0`,fontSize:14,lineHeight:1.55,opacity:.75},children:l}),c&&(0,W.jsx)(`div`,{...G(`text`),style:{marginTop:6,fontSize:14,lineHeight:1.55,opacity:.85},children:jr(c)})]})]},e.id??e?.data?.slug)})})}function ma({fields:e=[],buttonLabel:t=`Search`,style:n,nodeRef:r,inert:i}){let a=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&typeof e.name==`string`&&e.name):[],o=i?{}:In(),s={height:34,padding:`0 12px`,borderRadius:8,border:`1px solid var(--page-border, rgba(100, 116, 139, 0.4))`,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,fontSize:13,fontFamily:`inherit`,outline:`none`,minWidth:140,flex:`0 1 auto`,boxSizing:`border-box`},c=e=>{let t=e&&typeof e==`object`?e.value:e,n=e&&typeof e==`object`?e.label??e.value:e;return{value:String(t??``),label:String(n??``)}};return(0,W.jsxs)(`form`,{ref:r,method:`get`,onSubmit:e=>{if(i){e.preventDefault();return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);for(let e of[...t.keys()])(e.startsWith(`f_`)||e===`page`)&&t.delete(e);for(let[n,r]of new FormData(e.currentTarget).entries())n.startsWith(`f_`)&&typeof r==`string`&&r.trim()!==``&&t.set(n,r);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`))},style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,width:`100%`,...z(n)},children:[a.map(e=>Array.isArray(e.options)&&e.options.length>0||e.type===`option`||e.type===`select`?(0,W.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...G(`select`),style:s,...zi(i),children:[(0,W.jsx)(`option`,{value:``,children:e.label||e.name}),(Array.isArray(e.options)?e.options:[]).map(e=>{let t=c(e);return(0,W.jsx)(`option`,{value:t.value,children:t.label},t.value)})]},e.name):e.type===`switch`?(0,W.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...G(`select`),style:s,...zi(i),children:[(0,W.jsx)(`option`,{value:``,children:e.label||e.name}),(0,W.jsx)(`option`,{value:`true`,children:`Yes`}),(0,W.jsx)(`option`,{value:`false`,children:`No`})]},e.name):(0,W.jsx)(`input`,{type:`text`,name:`f_${e.name}`,defaultValue:o[e.name]??``,placeholder:e.label||e.name,...G(`input`),style:s,...zi(i)},e.name)),(0,W.jsx)(`button`,{type:`submit`,...G(`button`),style:{...s,minWidth:0,padding:`0 18px`,border:`none`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,fontWeight:600,cursor:i?`default`:`pointer`},...zi(i),children:t})]})}function ha({items:e=[],separator:t=`/`,style:n,nodeRef:r}){return e.length?(0,W.jsx)(`nav`,{ref:r,"aria-label":`Breadcrumb`,style:{...z(n)},children:(0,W.jsx)(`ol`,{...G(`list`),style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,listStyle:`none`,margin:0,padding:0,fontSize:14},children:e.map((n,r)=>{let i=r===e.length-1;return(0,W.jsxs)(`li`,{...G(`item`),style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[r>0&&(0,W.jsx)(`span`,{...G(`separator`),style:{opacity:.4},"aria-hidden":!0,children:t}),i||!n.href?(0,W.jsx)(`span`,{...G(`crumb`,i&&`crumb-current`),style:{fontWeight:i?600:400,opacity:i?1:.7},"aria-current":i?`page`:void 0,children:n.label}):(0,W.jsx)(`a`,{...G(`crumb`),href:n.href,style:{color:`inherit`,opacity:.7,textDecoration:`none`},children:n.label})]},r)})})}):null}function ga({pages:e=5,current:t=1,prevNext:n=!0,href:r=`#`,source:i,pageSize:a=6,align:o,hideEmpty:s,inert:c,style:u,nodeRef:d}){let{tenant:f,apiUrl:p,revision:m}=(0,l.useContext)(Nn),h=(0,l.useContext)(Pn),[g,_]=(0,l.useState)(null),v=i?Number(h?.[`${i}:total`]):NaN;(0,l.useEffect)(()=>{if(!i||Number.isFinite(v))return;let e=!0,t=i.startsWith(`api:`)?`${p}/data/${encodeURIComponent(i.slice(4))}`:`${p}/dynamic/${encodeURIComponent(i)}?limit=1`;return fetch(t,{headers:f?{"x-tenant":f}:{}}).then(e=>e.json()).then(t=>{if(!e)return;let n=t?.payload,r=Array.isArray(n)?n.length:Number(n?.total?.filtered??n?.total?.all??(Array.isArray(n?.data)?n.data.length:0));_(Number.isFinite(r)?r:0)}).catch(()=>e&&_(0)),()=>{e=!1}},[m,i,f,p,v]);let y=Math.max(1,Number(a)||6),b=Number.isFinite(v)?v:g;if(i&&b===null||i&&s&&!(b>0))return null;let x=Math.min(Math.max(i?Math.ceil(b/y):Number(e)||1,1),50),S=Math.min(Math.max(i?Fn(h):Number(t)||1,1),x),C=e=>{if(i){if(typeof window<`u`){let t=new URLSearchParams(window.location.search);return t.set(`page`,String(e)),`?${t.toString()}`}return`?page=${e}`}return r&&r!==`#`?r.replace(`{page}`,String(e)):`#`},w=o===`center`?`center`:o===`right`?`flex-end`:`flex-start`,T=c?e=>e.preventDefault():void 0,E=e=>({display:`inline-flex`,alignItems:`center`,justifyContent:`center`,minWidth:36,height:36,padding:`0 8px`,borderRadius:8,fontSize:14,textDecoration:`none`,color:e?`var(--page-accent-text, #ffffff)`:`inherit`,background:e?`var(--page-accent, #111827)`:`transparent`,border:e?`1px solid transparent`:`1px solid rgba(148, 163, 184, 0.4)`});return(0,W.jsxs)(`nav`,{ref:d,"aria-label":`Pagination`,style:{display:`flex`,flexWrap:`wrap`,gap:8,alignItems:`center`,justifyContent:w,...z(u)},children:[n&&(0,W.jsx)(`a`,{...G(`page`,`page-arrow`),href:S>1?C(S-1):`#`,onClick:T,"aria-label":`Previous`,style:{...E(!1),opacity:S>1?1:.4},children:`‹`}),Array.from({length:x},(e,t)=>t+1).map(e=>(0,W.jsx)(`a`,{...G(`page`,e===S&&`page-active`),href:C(e),onClick:T,"aria-current":e===S?`page`:void 0,style:E(e===S),children:e},e)),n&&(0,W.jsx)(`a`,{...G(`page`,`page-arrow`),href:S<x?C(S+1):`#`,onClick:T,"aria-label":`Next`,style:{...E(!1),opacity:S<x?1:.4},children:`›`})]})}var _a=`webim.page_mode`,va=()=>{if(typeof window>`u`)return`auto`;try{let e=window.localStorage.getItem(_a);return e===`light`||e===`dark`?e:`auto`}catch{return`auto`}},ya=e=>{let t={width:16,height:16,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0};return e===`light`?(0,W.jsxs)(`svg`,{...t,children:[(0,W.jsx)(`circle`,{cx:`12`,cy:`12`,r:`4`}),(0,W.jsx)(`path`,{d:`M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4`})]}):e===`dark`?(0,W.jsx)(`svg`,{...t,children:(0,W.jsx)(`path`,{d:`M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z`})}):(0,W.jsxs)(`svg`,{...t,children:[(0,W.jsx)(`rect`,{x:`2`,y:`3`,width:`20`,height:`14`,rx:`2`}),(0,W.jsx)(`path`,{d:`M8 21h8M12 17v4`})]})},ba={light:`Light theme`,dark:`Dark theme`,auto:`Follow the device theme`};function xa({variant:e,showSystem:t,style:n,nodeRef:r,inert:i}){let[a,o]=(0,l.useState)(i?`auto`:va),s=(0,l.useRef)(null),c=e=>{s.current=e,typeof r==`function`&&r(e)};(0,l.useEffect)(()=>{if(i)return;let e=s.current?.closest?.(`.webim-page`);e&&(a===`light`||a===`dark`?e.setAttribute(`data-webim-mode`,a):e.removeAttribute(`data-webim-mode`));try{a===`auto`?window.localStorage.removeItem(_a):window.localStorage.setItem(_a,a)}catch{}},[a,i]);let u=t===!1?[`light`,`dark`]:[`light`,`dark`,`auto`],d=u.includes(a)?a:u[0],f={appearance:`none`,border:0,margin:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,background:`transparent`,color:`inherit`,font:`inherit`,cursor:i?`default`:`pointer`,borderRadius:999};if(e===`buttons`)return(0,W.jsx)(`div`,{ref:c,role:`group`,"aria-label":`Theme`,style:{display:`inline-flex`,alignItems:`center`,gap:2,padding:3,borderRadius:999,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:u.map(e=>(0,W.jsx)(`button`,{...G(`option`,e===d&&`option-active`),type:`button`,title:ba[e],"aria-label":ba[e],"aria-pressed":e===d,onClick:i?void 0:()=>o(e),style:{...f,width:28,height:28,color:e===d?`var(--page-accent-text, #ffffff)`:`inherit`,background:e===d?`var(--page-accent, #111827)`:`transparent`,opacity:e===d?1:.7},children:ya(e)},e))});let p=u[(u.indexOf(d)+1)%u.length];return(0,W.jsx)(`button`,{ref:c,type:`button`,title:ba[d],"aria-label":`Theme: ${ba[d]} — switch to ${ba[p]}`,onClick:i?void 0:()=>o(p),style:{...f,width:36,height:36,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:ya(d)})}function Sa(e){let t=e?.parentElement;for(;t&&t!==document.body;){let e=getComputedStyle(t).overflowY;if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t;t=t.parentElement}return window}var Ca=e=>e===window?window.scrollY:e.scrollTop,wa={"bottom-right":e=>({right:e,bottom:e}),"bottom-left":e=>({left:e,bottom:e}),"bottom-center":e=>({left:`50%`,bottom:e,transform:`translateX(-50%)`})},Ta={linear:e=>e,out:e=>1-(1-e)**3,inout:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2},Ea=e=>{let t=e.getBoundingClientRect(),n=e.parentElement;for(;n&&n!==document.body;){let e=getComputedStyle(n);if(/(auto|scroll)/.test(e.overflowY)&&n.scrollHeight>n.clientHeight)break;n=n.parentElement}return!n||n===document.body?Math.max(document.documentElement.scrollHeight-(t.bottom+window.scrollY),0):Math.max(n.scrollHeight-(t.bottom-n.getBoundingClientRect().top+n.scrollTop),0)},Da=(e,t)=>{let n=typeof e==`number`?e:parseFloat(e);return Number.isFinite(n)?n:t};function Oa(e,{locale:t,decimals:n=0,separator:r=`auto`}={}){let i=Math.min(Math.max(Math.round(Da(n,0)),0),6);try{return new Intl.NumberFormat(t||void 0,{minimumFractionDigits:i,maximumFractionDigits:i,useGrouping:r!==`none`}).format(e)}catch{return e.toFixed(i)}}function ka({from:e,to:t,duration:n,delay:r,decimals:i,prefix:a,suffix:o,separator:s,easing:c,trigger:u,offset:d,once:f,label:p,align:m,style:h,nodeRef:g,inert:_}){let{locale:v}=(0,l.useContext)(Nn),y=Math.max(Da(d,0),0),b=Da(e,0),x=Da(t,100),[S,C]=(0,l.useState)(x),w=(0,l.useRef)(null),[T,E]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=w.current;if(_||!T||!e){C(x);return}C(b);let t=Math.max(Da(n,2e3),0),i=Math.max(Da(r,0),0),a=Ta[c]||Ta.out,o=typeof window<`u`&&window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,s=0,l=0,d=!1,p=()=>{if(cancelAnimationFrame(s),clearTimeout(l),o||t===0){C(x);return}l=setTimeout(()=>{let e=performance.now(),n=r=>{let i=Math.min((r-e)/t,1);C(b+(x-b)*a(i)),i<1&&(s=requestAnimationFrame(n))};s=requestAnimationFrame(n)},i)};if(u===`load`||typeof IntersectionObserver>`u`)return p(),()=>{cancelAnimationFrame(s),clearTimeout(l)};let m=new IntersectionObserver(e=>{let t=e.some(e=>e.isIntersecting);t&&(!d||f===!1)?(d=!0,p()):!t&&f===!1&&(cancelAnimationFrame(s),clearTimeout(l),C(b))},{rootMargin:`0px 0px -${Math.min(y,Math.floor(Ea(e)))}px 0px`,threshold:y>0?0:.3});return m.observe(e),()=>{m.disconnect(),cancelAnimationFrame(s),clearTimeout(l)}},[T,_,b,x,n,r,c,u,y,f]),(0,W.jsxs)(`div`,{ref:e=>{w.current=e,e&&E(!0),typeof g==`function`&&g(e)},"data-wb-counter":``,style:{display:`flex`,flexDirection:`column`,alignItems:m===`left`?`flex-start`:m===`right`?`flex-end`:`center`,gap:4,fontSize:48,fontWeight:700,lineHeight:1.1,textAlign:m===`left`?`left`:m===`right`?`right`:`center`,...z(h)},children:[(0,W.jsxs)(`span`,{...G(`number`),style:{fontVariantNumeric:`tabular-nums`,whiteSpace:`nowrap`},children:[a||``,Oa(S,{locale:v,decimals:i,separator:s}),o||``]}),p?(0,W.jsx)(`span`,{...G(`label`),style:{fontSize:`0.3em`,fontWeight:400,lineHeight:1.4,opacity:.72},children:p}):null]})}function Aa({variant:e,label:t,position:n,offset:r,showAfter:i,smooth:a,bg:o,fg:s,style:c,nodeRef:u,inert:d,frame:f,builder:p}){let[m,h]=(0,l.useState)(!!d),[g,_]=(0,l.useState)(null),v=e=>{_(e),typeof u==`function`&&u(e)};(0,l.useEffect)(()=>{if(d){h(!0);return}if(!g)return;let e=Number(i)>=0?Number(i):300,t=()=>{let t=Sa(g),n=p&&!(t===window?document.documentElement.scrollHeight>window.innerHeight:t.scrollHeight>t.clientHeight);h(n||Ca(t)>e)};return t(),document.addEventListener(`scroll`,t,{capture:!0,passive:!0}),()=>document.removeEventListener(`scroll`,t,{capture:!0})},[d,g,i,p]);let y=()=>{if(d)return;let e=Sa(g),t=window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,n=a===!1||t?`auto`:`smooth`;e===window?window.scrollTo({top:0,behavior:n}):e.scrollTo({top:0,behavior:n})},b=Number(r)>=0?Number(r):24,x=e===`pill`,S=t||`Top`,C=wa[n]?n:`bottom-right`,w=f?{position:`fixed`,zIndex:5,bottom:(f.bottom??0)+b,...C===`bottom-left`?{left:(f.left??0)+b}:null,...C===`bottom-right`?{right:(f.right??0)+b}:null,...C===`bottom-center`?{left:(f.left??0)+(f.width??0)/2,transform:`translateX(-50%)`}:null}:{position:`fixed`,zIndex:2147482e3,...wa[C](b)};return(0,W.jsxs)(`button`,{ref:v,type:`button`,title:S,"aria-label":S,"aria-hidden":!m,tabIndex:m?0:-1,onClick:y,style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,gap:x?8:0,appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,width:x?`auto`:44,height:44,padding:x?`0 18px`:0,borderRadius:999,border:`1px solid transparent`,background:o||`var(--page-accent, #111827)`,color:s||`var(--page-accent-text, #ffffff)`,boxShadow:`0 6px 20px rgba(15, 23, 42, 0.25)`,cursor:d?`default`:`pointer`,opacity:+!!m,pointerEvents:m?`auto`:`none`,transition:`opacity 160ms ease, transform 160ms ease`,...w,...z(c),...w.transform?{transform:w.transform}:null},children:[(0,W.jsx)(`svg`,{...G(`icon`),width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:`M12 19V5M12 5l-7 7M12 5l7 7`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`})}),x?(0,W.jsx)(`span`,{...G(`label`),children:S}):null]})}var ja={facebook:{label:`Facebook`,color:`#1877f2`,d:`M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z`},instagram:{label:`Instagram`,color:`#e4405f`,d:`M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24 12 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06zm0 5.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z`},x:{label:`X (Twitter)`,color:`#000000`,d:`M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z`},linkedin:{label:`LinkedIn`,color:`#0a66c2`,d:`M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z`},youtube:{label:`YouTube`,color:`#ff0000`,d:`M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z`},tiktok:{label:`TikTok`,color:`#000000`,d:`M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z`},whatsapp:{label:`WhatsApp`,color:`#25d366`,d:`M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z`},telegram:{label:`Telegram`,color:`#26a5e4`,d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`},pinterest:{label:`Pinterest`,color:`#bd081c`,d:`M12 0C5.373 0 0 5.372 0 12c0 5.084 3.163 9.426 7.627 11.174-.105-.949-.2-2.405.042-3.441.218-.937 1.407-5.965 1.407-5.965s-.359-.719-.359-1.782c0-1.668.967-2.914 2.171-2.914 1.023 0 1.518.769 1.518 1.69 0 1.03-.655 2.569-.994 3.995-.283 1.194.599 2.169 1.777 2.169 2.133 0 3.772-2.249 3.772-5.495 0-2.873-2.064-4.882-5.012-4.882-3.414 0-5.418 2.561-5.418 5.207 0 1.031.397 2.138.893 2.738a.36.36 0 01.083.345l-.333 1.36c-.053.22-.174.267-.402.161-1.499-.698-2.436-2.889-2.436-4.649 0-3.785 2.75-7.262 7.929-7.262 4.163 0 7.398 2.967 7.398 6.931 0 4.136-2.607 7.464-6.227 7.464-1.216 0-2.359-.631-2.75-1.378l-.748 2.853c-.271 1.043-1.002 2.35-1.492 3.146C9.57 23.812 10.763 24 12 24c6.627 0 12-5.373 12-12 0-6.628-5.373-12-12-12z`},github:{label:`GitHub`,color:`#181717`,d:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`},discord:{label:`Discord`,color:`#5865f2`,d:`M20.317 4.37a19.791 19.791 0 00-4.885-1.515.074.074 0 00-.079.037c-.21.375-.444.865-.608 1.25a18.27 18.27 0 00-5.487 0 12.64 12.64 0 00-.617-1.25.077.077 0 00-.079-.037A19.736 19.736 0 003.677 4.37a.07.07 0 00-.032.027C.533 9.046-.32 13.58.099 18.058a.082.082 0 00.031.056 19.9 19.9 0 005.993 3.03.078.078 0 00.084-.028c.462-.63.873-1.295 1.226-1.994a.076.076 0 00-.041-.106 13.107 13.107 0 01-1.872-.892.077.077 0 01-.008-.128c.126-.094.252-.192.372-.291a.074.074 0 01.077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 01.078.009c.12.099.246.198.373.292a.077.077 0 01-.006.127 12.299 12.299 0 01-1.873.892.077.077 0 00-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 00.084.028 19.839 19.839 0 006.002-3.03.077.077 0 00.032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 00-.031-.03zM8.02 15.331c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z`},email:{label:`E-mail`,color:`#64748b`,d:`M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z`},website:{label:`Website`,color:`#64748b`,d:`M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z`}};function Ma({links:e=[],variant:t,color:n,size:r,gap:i,newTab:a,style:o,nodeRef:s,inert:c}){let l=Array.isArray(e)?e.filter(e=>e&&ja[e.network]):[];if(!l.length)return null;let u=Math.min(Math.max(Number(r)||18,10),64),d=Math.round(u*1.9),f=Number.isFinite(Number(i))?Number(i):10,p=e=>n===`accent`?`var(--page-accent, #111827)`:n===`inherit`?`currentColor`:e.color,m=c?e=>e.preventDefault():void 0;return(0,W.jsx)(`div`,{ref:s,style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:f,...z(o)},children:l.map((e,r)=>{let i=ja[e.network],o=t!==`outline`&&t!==`plain`,s=o?n===`accent`?`var(--page-accent-text, #ffffff)`:n===`inherit`?`var(--page-bg, #ffffff)`:`#ffffff`:p(i);return(0,W.jsx)(`a`,{...G(`link`,/^[a-z]+$/.test(e.network??``)&&`link-${e.network}`),href:e.url||`#`,onClick:m,"aria-label":e.label||i.label,title:e.label||i.label,...a!==!1&&!c?{target:`_blank`,rel:`noopener noreferrer`}:{},style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,width:t===`plain`?u:d,height:t===`plain`?u:d,borderRadius:`50%`,background:o?p(i):`transparent`,border:t===`outline`?`1px solid ${p(i)}`:`none`,color:`inherit`,textDecoration:`none`},children:(0,W.jsx)(`svg`,{...G(`icon`),width:u,height:u,viewBox:`0 0 24 24`,fill:s,"aria-hidden":!0,children:(0,W.jsx)(`path`,{d:i.d})})},`${e.network}-${r}`)})})}function Na({steps:e=[],active:t=1,vertical:n=!1,style:r,nodeRef:i}){if(!e.length)return null;let a=Math.min(Math.max(Number(t)||1,1),e.length),o=e=>({width:32,height:32,borderRadius:`50%`,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:14,fontWeight:600,flexShrink:0,color:e===`todo`?`inherit`:`var(--page-accent-text, #ffffff)`,background:e===`todo`?`transparent`:`var(--page-accent, #111827)`,border:e===`todo`?`1px solid rgba(148, 163, 184, 0.5)`:`1px solid transparent`,opacity:e===`todo`?.6:1,boxShadow:e===`active`?`0 0 0 4px rgba(99, 102, 241, 0.2)`:`none`}),s=e=>({flexGrow:1,alignSelf:`center`,background:e?`var(--page-accent, #111827)`:`rgba(148, 163, 184, 0.4)`,...n?{width:2,minHeight:24,marginLeft:15,alignSelf:`auto`}:{height:2,minWidth:24}});return(0,W.jsx)(`div`,{ref:i,style:{display:`flex`,flexDirection:n?`column`:`row`,alignItems:n?`stretch`:`flex-start`,gap:n?4:8,...z(r)},children:e.map((e,t)=>{let r=t+1,i=r<a?`done`:r===a?`active`:`todo`;return(0,W.jsxs)(l.Fragment,{children:[t>0&&(0,W.jsx)(`div`,{...G(`step-line`,r<=a&&`step-line-done`),style:s(r<=a),"aria-hidden":!0}),(0,W.jsxs)(`div`,{...G(`step`,`step-${i}`),style:{display:`flex`,flexDirection:n?`row`:`column`,alignItems:`center`,gap:8,minWidth:0,textAlign:n?`left`:`center`},children:[(0,W.jsx)(`div`,{...G(`step-circle`,`step-circle-${i}`),style:o(i),children:i===`done`?`✓`:r}),(0,W.jsxs)(`div`,{style:{minWidth:0},children:[(0,W.jsx)(`div`,{...G(`step-label`,`step-label-${i}`),style:{fontSize:13,fontWeight:i===`active`?700:500,opacity:i===`todo`?.6:1},children:e.label}),e.description&&(0,W.jsx)(`div`,{...G(`step-description`),style:{fontSize:12,opacity:.6},children:e.description})]})]})]},t)})})}var Pa={small:{w:132,h:46,name:11.5,title:10,avatar:28},medium:{w:168,h:56,name:13,title:11,avatar:36},large:{w:210,h:70,name:15.5,title:12.5,avatar:46}},Fa=e=>Pa[e]??Pa.medium;Pa.medium.w,Pa.medium.h;var Ia=e=>String(e?.group??``).trim(),La=e=>{let t=[],n=new Map;return e.forEach((e,r)=>{let i=Ia(e)||`#${r}`;n.has(i)||(n.set(i,[]),t.push(i)),n.get(i).push(e)}),t.flatMap(e=>n.get(e))},Ra=20,za=12,Ba=[`left`,`center`,`right`],Va=e=>e.points.map((e,t)=>`${t?`L`:`M`} ${e.x} ${e.y}`).join(` `);function Ha(e,{size:t=`medium`,horizontal:n=!1,groupTitles:r=`top`,columns:i=`off`}={}){let a=Fa(t),o=n?a.h:a.w,s=n?16:20,c=(n?a.w:a.h)+(n?56:48),l=Array.isArray(e)?e.filter(e=>e&&e.id):[],u=new Set(l.map(e=>e.id)),d=new Map,f=[];for(let e of l)e.parent&&u.has(e.parent)&&e.parent!==e.id?(d.has(e.parent)||d.set(e.parent,[]),d.get(e.parent).push(e)):f.push(e);f=La(f);for(let[e,t]of d)d.set(e,La(t));let p=!n&&Ba.includes(i),m=e=>Ba.includes(e?.columns)?e.columns:i,h=e=>{let t=d.get(e.id)??[];if(!p)return t.map(e=>({nodes:[e]}));let n=[],r=[],i=()=>{r.length>1?n.push({nodes:r,line:m(e)}):r.forEach(e=>n.push({nodes:[e]})),r=[]};for(let e of t){let t=!(d.get(e.id)??[]).length;r.length&&(!t||Ia(r[0])!==Ia(e))&&i(),t?r.push(e):n.push({nodes:[e]})}return i(),n},g=(e,t)=>s+(Ia(e)!==Ia(t)&&(Ia(e)||Ia(t))?24:0),_=(e,t)=>g(e.nodes.at(-1),t.nodes[0]),v=e=>o+(e.line===`center`?0:Ra),y=new Map,b=(e,t)=>{if(t.has(e.id))return 0;t.add(e.id);let n=h(e),r=n.reduce((e,r,i)=>{let a=r.line?v(r):b(r.nodes[0],t);return r.line&&r.nodes.forEach(e=>t.add(e.id)),e+a+(i?_(n[i-1],r):0)},0),i=Math.max(o,r);return y.set(e.id,i),i};f.forEach(e=>b(e,new Set));let x=[],S=[],C=new Map,w=0,T=(e,t,r)=>{x.push({node:e,x:t,y:r});let i=Ia(e);if(i){let n=`${e.parent&&u.has(e.parent)&&e.parent!==e.id?e.parent:``}|${i}`;C.has(n)||C.set(n,{title:i,color:``,members:[]});let a=C.get(n);!a.color&&e.groupColor&&(a.color=e.groupColor),a.members.push({x:t,y:r})}w=Math.max(w,n?t+a.w:r+a.h)},E=(e,t,n,r)=>{let i=t+(e.line===`left`?Ra:0),o=n*c,s=r.y+(o-r.y)/2,l=e.line===`left`?i-Ra/2:i+a.w+Ra/2;e.nodes.forEach((t,n)=>{let c=o+n*(a.h+za),u=c+a.h/2;if(T(t,i,c),e.line===`center`)S.push(n?{points:[{x:i+a.w/2,y:c-za},{x:i+a.w/2,y:c}]}:{points:[r,{x:r.x,y:s},{x:i+a.w/2,y:s},{x:i+a.w/2,y:c}]});else{let t=e.line===`left`?i:i+a.w;S.push({points:[r,{x:r.x,y:s},{x:l,y:s},{x:l,y:u},{x:t,y:u}]})}})},D=(e,t,r,i)=>{if(i.has(e.id))return;i.add(e.id);let s=t+((y.get(e.id)??o)-o)/2,l=r*c;T(e,n?l:s,n?s:l);let u=t,d=h(e),f=n?{x:l+a.w,y:s+a.h/2}:{x:s+a.w/2,y:l+a.h};d.forEach((e,t)=>{if(t&&(u+=_(d[t-1],e)),e.line){E(e,u,r+1,f),e.nodes.forEach(e=>i.add(e.id)),u+=v(e);return}let a=e.nodes[0],s=u+((y.get(a.id)??o)-o)/2+o/2,l=(r+1)*c;S.push({points:n?[f,{x:(f.x+l)/2,y:f.y},{x:(f.x+l)/2,y:s},{x:l,y:s}]:[f,{x:f.x,y:(f.y+l)/2},{x:s,y:(f.y+l)/2},{x:s,y:l}]}),D(a,u,r+1,i),u+=y.get(a.id)??o})},O=0,k=new Set;f.forEach((e,t)=>{t&&(O+=g(f[t-1],e)),D(e,O,0,k),O+=y.get(e.id)??o});let A=Math.max(O,o),j=r===`hidden`?0:22,M=[...C.values()].map(e=>{let t=Math.min(...e.members.map(e=>e.x))-12,n=Math.max(...e.members.map(e=>e.x))+a.w+12,i=Math.min(...e.members.map(e=>e.y))-12-(r===`bottom`?0:j),o=Math.max(...e.members.map(e=>e.y))+a.h+12+(r===`bottom`?j:0);return{x:t,y:i,width:n-t,height:o-i,title:e.title,color:e.color}}),N=n?Math.max(w,a.w):A,P=n?A:Math.max(w,a.h),F=Math.max(0,...M.map(e=>-e.x)),I=Math.max(0,...M.map(e=>-e.y));if(M.length&&(N=Math.max(N,...M.map(e=>e.x+e.width))+F,P=Math.max(P,...M.map(e=>e.y+e.height))+I,F||I)){for(let e of x)e.x+=F,e.y+=I;for(let e of S)e.points=e.points.map(e=>({x:e.x+F,y:e.y+I}));for(let e of M)e.x+=F,e.y+=I}return{boxes:x,links:S,groups:M,width:N,height:P,horizontal:n}}var Ua=(e,t)=>{let n=String(e??``);return n.length>t?`${n.slice(0,t-1)}…`:n},Wa=e=>{let t=/^#([0-9a-f]{6}|[0-9a-f]{3})$/i.exec(String(e??``).trim());if(!t)return`#ffffff`;let n=t[1];n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=parseInt(n,16);return .299*(r>>16&255)+.587*(r>>8&255)+.114*(r&255)>150?`#111827`:`#ffffff`},Ga=e=>!!(e?.cv?.trim?.()||e?.photo||e?.profilePhoto||e?.profile?.length);function Ka(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:Jn(e);return n.map(e=>{let n=e.data??{},a=r(n[t.parentField]),o=a&&typeof a==`object`?a.id??null:a||null;return{id:e.id,name:i(n[t.nameField||`name`])||i(n.name)||`Untitled`,title:t.titleField?i(n[t.titleField]):``,photo:t.photoField&&r(n[t.photoField])||``,parent:t.parentField?o:null,cv:t.cvField?i(n[t.cvField]):``,href:t.hrefField?i(n[t.hrefField]):``,group:t.groupField?i(n[t.groupField]):``}})}var qa=/^(https?:\/\/[^\s"<>]+|mailto:[^\s"<>]+|tel:[+\d][\d\s().-]*|\/(?!\/)[^\s"<>]*)$/i,Ja=e=>{let t=String(e??``).trim();return qa.test(t)?t:``},Ya=e=>{e.startsWith(`/`)?window.location.assign(e):window.open(e,`_blank`,`noopener,noreferrer`)},Xa={size:36,pad:10};function Za({node:e,onClose:t}){(0,l.useEffect)(()=>{let e=e=>e.key===`Escape`&&t();return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let n=e.profile?.length?e.profile:null,r=n?``:e.profilePhoto||e.photo,i=e.title||e.name,a=e.title&&e.name?e.name:``,o=!!(n||r&&e.cv),s=Ja(e.href);return(0,W.jsx)(`div`,{onClick:t,role:`dialog`,"aria-modal":`true`,"aria-label":i,style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(2, 6, 23, 0.6)`,backdropFilter:`blur(4px)`,WebkitBackdropFilter:`blur(4px)`,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:16},children:(0,W.jsxs)(`div`,{onClick:e=>e.stopPropagation(),style:{background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.35)`,borderRadius:14,maxWidth:o?900:440,width:`100%`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,overflow:`hidden`,boxShadow:`0 24px 64px rgba(2, 6, 23, 0.5)`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:12,padding:`18px 20px 14px 24px`,borderBottom:`1px solid rgba(148, 163, 184, 0.3)`},children:[(0,W.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{style:{fontSize:18,fontWeight:700,lineHeight:1.35},children:i}),a&&(0,W.jsx)(`div`,{style:{fontSize:14,opacity:.7,marginTop:2},children:a})]}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:t,style:{flexShrink:0,width:32,height:32,border:0,borderRadius:8,background:`transparent`,color:`inherit`,fontSize:20,lineHeight:1,cursor:`pointer`,opacity:.6},children:`×`})]}),(0,W.jsxs)(`div`,{style:{overflowY:`auto`,padding:24,display:`flex`,flexWrap:`wrap`,gap:24,alignItems:`flex-start`},children:[r&&(0,W.jsx)(`img`,{src:r,alt:e.name||i,style:o?{flex:`1 1 220px`,maxWidth:340,width:`100%`,height:`auto`,borderRadius:10,objectFit:`cover`}:{width:96,height:96,borderRadius:`50%`,objectFit:`cover`}}),(n||e.cv||s)&&(0,W.jsxs)(`div`,{style:{flex:`2 1 320px`,minWidth:0},children:[n&&(0,W.jsx)(`div`,{style:{display:`flow-root`,marginBottom:s?12:0},children:jr(n)}),!n&&e.cv&&String(e.cv).split(/\n+/).map((e,t)=>(0,W.jsx)(`p`,{style:{fontSize:15,lineHeight:1.65,margin:`0 0 12px`},children:e},t)),s&&(0,W.jsx)(`a`,{href:s,target:`_blank`,rel:`noopener noreferrer`,style:{display:`inline-block`,marginTop:6,padding:`8px 14px`,borderRadius:8,fontSize:13,fontWeight:600,textDecoration:`none`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:`Open profile ↗`})]})]})]})})}function Qa(e){return e.chart?.people?.length?(0,W.jsx)($a,{...e}):(0,W.jsx)(eo,{...e})}function $a({chart:e,profiles:t,style:n,nodeRef:r,interactive:i=!0}){let[a,o]=(0,l.useState)(null),s=(0,l.useMemo)(()=>ln(e),[e]),c=(0,l.useMemo)(()=>new Set(e.people.map(e=>e.parent)),[e]);return(0,W.jsxs)(`div`,{ref:r,style:{maxWidth:`100%`,overflowX:`auto`,...z(n)},children:[(0,W.jsxs)(`svg`,{viewBox:`0 0 ${s.width} ${s.height}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:s.width,height:`auto`,margin:`0 auto`},children:[s.frames.map(({person:e,x:t,y:n,width:r,height:i})=>(0,W.jsx)(`foreignObject`,{x:t,y:n,width:r,height:i,children:(0,W.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:jn(e,c.has(e.id))}})},e.id)),s.links.map((e,t)=>(0,W.jsx)(`path`,{d:gn(e),fill:`none`,stroke:Cn.line,strokeWidth:`1.5`},t)),s.cards.map(({person:n,x:r,y:a,width:c,height:l})=>{let u=Array.isArray(t?.[n.id])&&t[n.id].length?t[n.id]:null,d={id:n.id,name:n.name,title:n.title,cv:n.description,photo:n.photo,profilePhoto:n.photo,href:n.link,profile:u},f=Ja(n.link),p=i&&(f||Ga(d)),m=()=>f?Ya(f):o(d);return(0,W.jsx)(`g`,{onClick:p?m:void 0,onKeyDown:p?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),m())}:void 0,tabIndex:p?0:void 0,style:p?{cursor:`pointer`}:void 0,role:p?f?`link`:`button`:void 0,"aria-label":p?f?`${n.name||n.title} — open link`:`Open ${n.name||n.title}'s profile`:void 0,children:(0,W.jsx)(`foreignObject`,{x:r,y:a,width:c,height:l,children:(0,W.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:An(n,e,s.size,Cn)}})})},n.id)})]}),a&&(0,W.jsx)(Za,{node:a,onClose:()=>o(null)})]})}function eo({nodes:e=[],source:t,nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c,groupTitles:u=`top`,groupBg:d=``,size:f=`medium`,horizontal:p=!1,columns:m=`off`,style:h,nodeRef:g,interactive:_=!0}){let v=(0,l.useId)(),[y,b]=(0,l.useState)(null),{tenant:x,apiUrl:S,revision:C}=(0,l.useContext)(Nn),w=(0,l.useContext)(Pn)?.[t],[T,E]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[C,t,x,S,w]);let D=t?Ka(w??T??[],{nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c}):e,O=Fa(f),{boxes:k,links:A,groups:j,width:M,height:N}=Ha(D,{size:f,horizontal:p,groupTitles:u,columns:m});if(!k.length)return!_&&t?(0,W.jsxs)(`div`,{ref:g,style:{padding:18,border:`1px dashed rgba(148, 163, 184, 0.6)`,borderRadius:10,fontSize:13,opacity:.7,textAlign:`center`,...z(h)},children:[`Org Chart — no published entries in “`,t,`” yet`]}):null;let P=new Set(k.filter(e=>e.node.parent==null||e.node.parent===``).map(e=>e.node.id));return(0,W.jsxs)(`div`,{ref:g,style:{maxWidth:`100%`,overflowX:`auto`,...z(h)},children:[(0,W.jsxs)(`svg`,{viewBox:`0 0 ${M} ${N}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:M,height:`auto`,margin:`0 auto`},children:[j.map((e,t)=>{let n=e.color||d||`rgba(148, 163, 184, 0.16)`,r=!!(e.color||d);return(0,W.jsxs)(`g`,{children:[(0,W.jsx)(`rect`,{x:e.x,y:e.y,width:e.width,height:e.height,rx:`16`,fill:n}),u!==`hidden`&&e.title&&(0,W.jsx)(`text`,{x:e.x+e.width/2,y:u===`bottom`?e.y+e.height-22*.42:e.y+22*.78,textAnchor:`middle`,fontSize:O.title+1,fontWeight:`600`,opacity:`0.55`,fill:r?Wa(e.color||d):`var(--page-text, #111827)`,children:Ua(e.title,Math.floor(e.width/7))})]},`group-${t}`)}),A.map((e,t)=>(0,W.jsx)(`path`,{d:Va(e),fill:`none`,stroke:`rgba(148, 163, 184, 0.7)`,strokeWidth:`1.5`},t)),k.map(({node:e,x:t,y:n})=>{let r=P.has(e.id),i=!!e.color2,a=!!e.color||r||i,o=e.color||(r?`var(--page-accent, #4f46e5)`:`var(--page-bg, #ffffff)`),s=e.color?Wa(e.color):r?`var(--page-accent-text, #ffffff)`:`var(--page-text, #111827)`,c=i?Wa(e.color2):s,l=Ja(e.href),u=_&&(l||Ga(e)),d=()=>l?Ya(l):b(e),f=e.photo?t+Xa.pad+O.avatar+8:t+O.w/2,p=e.photo?`start`:`middle`,m=e.photo?Math.floor((O.w-O.avatar-26)/7):Math.floor(O.w/7.6),h=O.h/2,g=[e.name,e.title].map(e=>String(e??``).trim()).filter(Boolean);return(0,W.jsxs)(`g`,{onClick:u?d:void 0,onKeyDown:u?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),d())}:void 0,tabIndex:u?0:void 0,style:u?{cursor:`pointer`}:void 0,role:u?l?`link`:`button`:void 0,"aria-label":u?l?`${e.name||e.title} — open link`:`Open ${e.name||e.title}'s profile`:void 0,children:[i&&e.gradient?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsxs)(`linearGradient`,{id:`${v}-${e.id}-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,W.jsx)(`stop`,{offset:`0%`,stopColor:e.color||`var(--page-accent, #4f46e5)`}),(0,W.jsx)(`stop`,{offset:`100%`,stopColor:e.color2})]}),(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:`url(#${v}-${e.id}-grad)`})]}):i?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`clipPath`,{id:`${v}-${e.id}-box`,children:(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`})}),(0,W.jsxs)(`g`,{clipPath:`url(#${v}-${e.id}-box)`,children:[(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:h,fill:o}),(0,W.jsx)(`rect`,{x:t,y:n+h,width:O.w,height:O.h-h,fill:e.color2})]})]}):(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:o,stroke:a?`none`:`var(--page-accent, #4f46e5)`,strokeWidth:a?0:1.5}),e.photo&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`clipPath`,{id:`${v}-${e.id}`,children:(0,W.jsx)(`circle`,{cx:t+Xa.pad+O.avatar/2,cy:n+O.h/2,r:O.avatar/2})}),(0,W.jsx)(`image`,{href:e.photo,x:t+Xa.pad,y:n+(O.h-O.avatar)/2,width:O.avatar,height:O.avatar,preserveAspectRatio:`xMidYMid slice`,clipPath:`url(#${v}-${e.id})`})]}),i&&!e.gradient?(0,W.jsxs)(W.Fragment,{children:[e.title&&(0,W.jsx)(`text`,{x:f,y:n+h/2+O.title*.35,textAnchor:p,fontSize:O.title,fontWeight:`600`,fill:s,children:Ua(e.title,m+4)}),e.name&&(0,W.jsx)(`text`,{x:f,y:n+h+h/2+O.name*.35,textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:c,children:Ua(e.name,m)})]}):(0,W.jsxs)(W.Fragment,{children:[g[0]&&(0,W.jsx)(`text`,{x:f,y:n+(g[1]?O.h*.43:O.h*.57),textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:s,children:Ua(g[0],m)}),g[1]&&(0,W.jsx)(`text`,{x:f,y:n+O.h*.73,textAnchor:p,fontSize:O.title,opacity:`0.7`,fill:s,children:Ua(g[1],m+4)})]})]},e.id)})]}),y&&(0,W.jsx)(Za,{node:y,onClose:()=>b(null)})]})}function to({value:e,onCommit:t,style:n,hint:r}){let[i,a]=(0,l.useState)(!1),o=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!i||!o.current)return;let e=o.current,t=document.createRange();e.focus(),t.selectNodeContents(e),t.collapse(!1);let n=window.getSelection();n.removeAllRanges(),n.addRange(t)},[i]),(0,W.jsx)(`span`,{ref:o,contentEditable:i,suppressContentEditableWarning:!0,title:i?void 0:r||`Double-click to edit`,onDoubleClick:()=>a(!0),onBlur:i?e=>{a(!1),t(e.currentTarget.textContent)}:void 0,onKeyDown:i?t=>{t.stopPropagation(),t.key===`Escape`&&(t.currentTarget.textContent=e??``,t.currentTarget.blur()),t.key===`Enter`&&(t.preventDefault(),t.currentTarget.blur())}:void 0,style:{display:`block`,minHeight:`1em`,outline:`none`,cursor:i?`text`:`inherit`,...n},children:e??``})}var no=360,ro=`
24
+ `),t)))}return n}function qt(e,t,n,r){let i=Vt(e[t]),a=i.indent,o=[],s=null,c=t;for(;c<e.length;){let t=e[c],n=Vt(t);if(n&&n.indent<=a+1){if(n.ordered!==i.ordered)break;s={lines:[n.text]},o.push(s),c+=1;continue}if(At.test(t)){let t=c;for(;t<e.length&&At.test(e[t]);)t+=1;if(!(t<e.length&&(Bt(e[t])>=a+2||Vt(e[t])&&Vt(e[t]).ordered===i.ordered)))break;s?.lines.push(``),c=t;continue}if(!s)break;if(Bt(t)>=a+2)s.lines.push(t.slice(Math.min(t.length-t.trimStart().length,a+2)));else if(!n)s.lines.push(t.trim());else break;c+=1}return n.push({type:i.ordered?`ol`:`ul`,...i.ordered&&i.start!==1?{start:i.start}:null,items:o.map(e=>{let t=Rt.exec(e.lines[0]??``);t&&(e.lines[0]=t[2]);let n=Kt(e.lines,r),i=n[0]?.type===`p`?n.shift():null;return{parts:i?i.parts:[],...n.length?{blocks:n}:null,...t?{task:t[1].toLowerCase()===`x`}:null}})}),c}function Jt(e,t={}){return String(e??``).trim()?Kt(Gt(e),t):[]}function Yt(e,t){let n={data:e,depth:0,parent:null,children:null},r=[n];for(;r.length;){let e=r.pop(),n=t(e.data);if(n?.length){e.children=n.map(t=>({data:t,depth:e.depth+1,parent:e,children:null}));for(let t=e.children.length-1;t>=0;--t)r.push(e.children[t])}}return n}function Xt(e,t){let n=[e];for(;n.length;){let e=n.pop();if(t(e),e.children)for(let t=e.children.length-1;t>=0;--t)n.push(e.children[t])}}function Zt(e,t){let n=[e],r=[];for(;n.length;){let e=n.pop();if(r.push(e),e.children)for(let t of e.children)n.push(t)}for(;r.length;)t(r.pop())}function Qt(e,[t,n],r){let i=(e,t)=>({_:e,parent:null,children:null,A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:t}),a=i(e,0);a.a=a,Xt(a,e=>{e._.children&&(e.children=e._.children.map((t,n)=>{let r=i(t,n);return r.a=r,r.parent=e,r}))}),a.parent=i(null,0),a.parent.a=a.parent,a.parent.children=[a];let o=e=>e.children?e.children[0]:e.t,s=e=>e.children?e.children[e.children.length-1]:e.t,c=(e,t,n)=>{let r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n},l=e=>{let t=0,n=0;for(let r=e.children.length-1;r>=0;--r){let i=e.children[r];i.z+=t,i.m+=t,t+=i.s+(n+=i.c)}},u=(e,t,n)=>e.a.parent===t.parent?e.a:n,d=(e,t,n)=>{if(!t)return n;let i=e,a=e,l=t,d=i.parent.children[0],f=i.m,p=a.m,m=l.m,h=d.m;for(;l=s(l),i=o(i),l&&i;){d=o(d),a=s(a),a.a=e;let t=l.z+m-i.z-f+r(l._,i._);t>0&&(c(u(l,e,n),e,t),f+=t,p+=t),m+=l.m,f+=i.m,h+=d.m,p+=a.m}return l&&!s(a)&&(a.t=l,a.m+=m-p),i&&!o(d)&&(d.t=i,d.m+=f-h,n=e),n};return Zt(a,e=>{let t=e.parent.children,n=e.i?t[e.i-1]:null;if(e.children){l(e);let t=(e.children[0].z+e.children[e.children.length-1].z)/2;n?(e.z=n.z+r(e._,n._),e.m=e.z-t):e.z=t}else n&&(e.z=n.z+r(e._,n._));e.parent.A=d(e,n,e.parent.A||t[0])}),a.parent.m=-a.z,Xt(a,e=>{e._.x=e.z+e.parent.m,e.m+=e.parent.m}),Xt(e,e=>{e.x*=t,e.y=e.depth*n}),e}var $t=20,en={S:{width:200,height:80},M:{width:240,height:80},L:{width:280,height:100},XL:{width:320,height:120}},tn={across:20,down:80,stack:20},nn=tn.across/2,rn={pad:20,header:40},an=2*tn.stack,on=`__root__`,sn=20,cn=e=>Math.round(e/$t)*$t;function ln(e){let{people:t,direction:n}=e,r=en[e.cardSize]??en.M,i=n===`right`,a=new Map;for(let e of t){let t=e.parent??on;a.has(t)||a.set(t,[]),a.get(t).push(e)}let o=i?r.height+tn.across:r.width+tn.across,s=i?r.width+tn.down:r.height+tn.down,c=e=>e.id===on||!e.collapsed?a.get(e.id)??[]:[],l=e=>e.kind===`group`,u=e=>c(e).filter(e=>e.placement!==`below`),d=e=>c(e).filter(e=>e.placement===`below`),f=(e,t)=>e.memberTeams===`inside`?c(t):[],p=e=>u(e).flatMap(t=>e.memberTeams===`inside`?f(e,t):[t]),m=e=>{let t=u(e).length,n=i||e.memberTeams===`inside`,r=Math.max(1,Math.min(t,e.memberColumns||(n?t:1)));return{cols:r,rows:Math.ceil(t/r)}},h=(e,t)=>{let n=f(e,t).length;return r.height+(n?an+n*(r.height+tn.stack)-tn.stack:0)},g=e=>{let t=u(e),{cols:n,rows:i}=m(e),a=[],o=rn.header;for(let r=0;r<i;r+=1)a.push(o),o+=Math.max(...t.slice(r*n,(r+1)*n).map(t=>h(e,t)))+tn.stack;return{width:(t.length?n*(r.width+tn.across)-tn.across:r.width)+2*rn.pad,height:(t.length?o-tn.stack:rn.header)+rn.pad,tops:a}},_=(e,t=c(e))=>{if(i||e.id===on)return t;let n=[],r=[],a=()=>{r.length>1?n.push({id:`${r[0].id}:stack`,people:r,line:e.columns}):n.push(...r),r=[]};for(let e of t)c(e).length||l(e)?(a(),n.push(e)):r.push(e);return a(),n},v=(e,t,n)=>{let r=n;for(let n=Math.ceil(t/s);n>0;--n)r=[{id:`${e}:${n}`,spacer:!0,below:r}];return r},y=i?r.width:r.height,b=Yt({id:on},e=>{if(e.people)return v(e.id,(e.people.length-1)*(r.height+tn.stack),[]);if(e.spacer)return e.below;if(l(e)){let t=p(e).flatMap(e=>_(e)),n=_(e,d(e)),r=i?[...n,...t]:[...t,...n],a=i?g(e).width:g(e).height;return v(`${e.id}:frame`,a-y,r)}return _(e)}),x=e=>{if(!l(e.data))return 0;let t=g(e.data);return(i?t.height-r.height:t.width-r.width)/o};Qt(b,[o,s],(e,t)=>(e.parent===t.parent?1:1+2*$t/o)+(x(e)+x(t))/2);let S=new Map,C=[],w=[],T=[],E=new Map([[on,{x:0,y:0}]]),D=new Map,O=(e,t,a,o,s=null)=>{let c=E.get(t??on),u={x:c.x+(e.dx||0),y:c.y+(e.dy||0)},d=l(e)?g(e):null,f={person:e,x:cn(a.x)+u.x,y:cn(a.y)+u.y,width:d?d.width:r.width,height:d?d.height:r.height};if(E.set(e.id,u),S.set(e.id,f),(d?w:C).push(f),o?.inner)T.push(o.line===`center`?{kind:`straight`,source:o.above?.id??e.parent,target:e.id,from:`bottom`,to:`top`}:{kind:`rail`,source:e.parent,target:e.id,from:`bottom`,to:o.line===`right`?`right`:`left`,side:o.line===`right`?`right`:`left`,drop:an/2});else if(e.parent&&!s){let t=D.get(e.parent);t!==void 0&&!e.lineFrom&&!e.lineTo&&!(o?.line===`center`&&o.above)?T.push({kind:`exit`,source:e.parent,target:e.id,from:i?`right`:`bottom`,to:o?.line===`left`||i?`left`:`top`,exit:t,into:o?.line===`left`?`side`:`top`,level:o?.line===`left`?cn(o.top)+c.y-tn.down/2:null}):T.push(un(e,o,n))}};Xt(b,e=>{let t=e.data;if(t.id===on||t.spacer)return;let n=e.y-s;if(t.people){t.people.forEach((i,a)=>O(i,i.parent,{x:e.x-r.width/2,y:n+a*(r.height+tn.stack)},{line:t.line,above:t.people[a-1],top:n}));return}if(l(t)){let a=g(t),o=i?{x:n,y:e.x-a.height/2}:{x:e.x-a.width/2,y:n};O(t,t.parent,o,null);let s=E.get(t.id);p(t).forEach(e=>D.set(e.id,i?cn(o.y)+s.y+a.height+nn:cn(o.x)+s.x-nn));let{cols:c}=m(t);u(t).forEach((e,n)=>{let i={x:o.x+rn.pad+n%c*(r.width+tn.across),y:o.y+a.tops[Math.floor(n/c)]},s=f(t,e);O(e,t.id,i,null,t),s.forEach((n,a)=>O(n,e.id,{x:i.x,y:i.y+r.height+an+a*(r.height+tn.stack)},{line:e.columns,above:s[a-1],inner:!0},t))});return}O(t,t.parent,i?{x:n,y:e.x-r.height/2}:{x:e.x-r.width/2,y:n},null)});let k=[...w,...C],A=Math.min(...k.map(e=>e.x))-sn,j=Math.min(...k.map(e=>e.y))-sn;for(let e of k)e.x-=A,e.y-=j;let M=T.map(e=>pn(e,S,i)).filter(Boolean),N=[...k.flatMap(e=>[e.x+e.width]),...M.flatMap(e=>e.points.map(e=>e.x))],P=[...k.flatMap(e=>[e.y+e.height]),...M.flatMap(e=>e.points.map(e=>e.y))];return{cards:C,frames:w,links:M,width:Math.ceil(Math.max(...N)+sn),height:Math.ceil(Math.max(...P)+sn),size:r}}function un(e,t,n){let r=n===`right`,i=r?`right`:`bottom`,a=r?`left`:`top`;return(e.lineTo===`left`||e.lineTo===`right`)&&!r&&(!e.lineFrom||e.lineFrom===`bottom`)?{kind:`elbow`,source:e.parent,target:e.id,from:`bottom`,to:e.lineTo,side:e.lineTo}:e.lineFrom||e.lineTo?{kind:`step`,source:e.parent,target:e.id,from:e.lineFrom||i,to:e.lineTo||a}:t?t.line===`center`?t.above?{kind:`straight`,source:t.above.id,target:e.id,from:i,to:a}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}:t.line===`right`?{kind:`rail`,source:e.parent,target:e.id,from:i,to:`right`,side:`right`}:{kind:`rail`,source:e.parent,target:e.id,from:i,to:`left`,side:`left`}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}}function dn(e,t){return t===`top`?{x:e.x+e.width/2,y:e.y}:t===`bottom`?{x:e.x+e.width/2,y:e.y+e.height}:t===`left`?{x:e.x,y:e.y+e.height/2}:{x:e.x+e.width,y:e.y+e.height/2}}var fn={top:{x:0,y:-1},bottom:{x:0,y:1},left:{x:-1,y:0},right:{x:1,y:0}};function pn(e,t,n){let r=t.get(e.source),i=t.get(e.target);if(!r||!i)return null;let a=dn(r,e.from),o=dn(i,e.to),s;if(e.kind===`straight`)s=[a,o];else if(e.kind===`rail`){let t=a.y+(e.drop??tn.down/2),n=e.side===`right`?o.x+nn:o.x-nn;s=[a,{x:a.x,y:t},{x:n,y:t},{x:n,y:o.y},o]}else if(e.kind===`exit`){let{exit:t,into:r,level:i}=e;if(n){let e=a.x+tn.across/2;s=[a,{x:e,y:a.y},{x:e,y:t},{x:o.x-tn.down/2,y:t},{x:o.x-tn.down/2,y:o.y},o]}else{let e=a.y+tn.stack/2;s=r===`side`?[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:i},{x:o.x-nn,y:i},{x:o.x-nn,y:o.y},o]:[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:o.y-tn.down/2},{x:o.x,y:o.y-tn.down/2},o]}}else if(e.kind===`elbow`){let t=e.side===`right`?a.x<o.x+nn:a.x>o.x-nn,n=e.side===`right`?o.x+nn:o.x-nn;return s=t?[a,{x:a.x,y:a.y+tn.down/2},{x:n,y:a.y+tn.down/2},{x:n,y:o.y},o]:[a,{x:a.x,y:o.y},o],{points:hn(s),square:!t}}else s=mn(a,e.from,o,e.to);return{points:hn(s)}}function mn(e,t,n,r){let i=e=>e===`top`||e===`bottom`;if(t===`bottom`&&r===`top`&&n.y>e.y){let t=(e.y+n.y)/2;return[e,{x:e.x,y:t},{x:n.x,y:t},n]}if(t===`right`&&r===`left`&&n.x>e.x){let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}let a={x:e.x+fn[t].x*20,y:e.y+fn[t].y*20},o={x:n.x+fn[r].x*20,y:n.y+fn[r].y*20};return[e,a,i(t)?{x:a.x,y:o.y}:{x:o.x,y:a.y},o,n]}var hn=e=>e.filter((e,t,n)=>t===0||e.x!==n[t-1].x||e.y!==n[t-1].y);function gn(e,t=10){let{points:n}=e,r=e.square?0:t,i=`M ${n[0].x} ${n[0].y}`;for(let e=1;e<n.length-1;e+=1){let[t,a,o]=[n[e-1],n[e],n[e+1]],s=Math.min(r,Math.hypot(a.x-t.x,a.y-t.y)/2,Math.hypot(o.x-a.x,o.y-a.y)/2),c=(e,t)=>{let n=Math.hypot(t.x-e.x,t.y-e.y)||1;return{x:e.x+(t.x-e.x)/n*s,y:e.y+(t.y-e.y)/n*s}},l=c(a,t),u=c(a,o);i+=` L ${l.x} ${l.y} Q ${a.x} ${a.y} ${u.x} ${u.y}`}let a=n.at(-1);return`${i} L ${a.x} ${a.y}`}var _n=`#4f46e5`,vn={S:.85,M:1,L:1.15,XL:1.3},yn={name:14,title:12.5,unit:13.5,department:11,band:12.5},bn=1.3,xn={classic:12,band:6},Sn={left:`flex-start`,center:`center`,right:`flex-end`},Cn={card:`var(--page-bg, #ffffff)`,text:`var(--page-text, #111827)`,border:`rgba(148, 163, 184, 0.45)`,line:`rgba(148, 163, 184, 0.8)`},wn=e=>String(e).replace(/[&<>"']/g,e=>({"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`})[e]),Tn=e=>Object.entries(e).filter(([,e])=>e!=null).map(([e,t])=>`${e}:${t}`).join(`;`),En=e=>({display:`-webkit-box`,"-webkit-line-clamp":e,"-webkit-box-orient":`vertical`,overflow:`hidden`,"overflow-wrap":`anywhere`}),Dn=e=>`#${[1,3,5].map(t=>Math.round(parseInt(e.slice(t,t+2),16)*.55).toString(16).padStart(2,`0`)).join(``)}`,On=e=>e.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0].toUpperCase()).join(``)||`?`;function kn(e,t,n,r){let i=e=>yn[e]*n*bn,a=(e,t,n)=>Math.max(1,Math.min(n,Math.floor((e+.5)/i(t)))),o=e.height-xn.classic-(r.department?yn.department*n*1.4:0),s=r.title?t?a(o-i(`title`),`name`,2):1:a(o,`name`,t?20:2),c=e.height*.55-xn.band;return{name:s,title:a(o-s*i(`name`),`title`,t?20:2),unit:a(o,`unit`,t?20:3),top:a(c,`band`,t?20:2),bottom:a(e.height-c-2*xn.band,`band`,t?20:1),single:a(e.height-xn.band,`band`,t?20:3)}}function An(e,t,n,r){let i=vn[e.textSize||t.textSize]??1,a=e.textAlign||t.textAlign||`left`,o=e.color||_n,s=kn(n,t.wrapText,i,e),c={"box-sizing":`border-box`,width:`100%`,height:`100%`,overflow:`hidden`,position:`relative`,"font-family":`inherit`,"line-height":bn};if(t.cardStyle===`banded`){let t={display:`flex`,"align-items":`center`,"justify-content":Sn[a],"text-align":a,padding:`0 10px`,color:`#fff`,"font-weight":600,"font-size":`${yn.band*i}px`,"min-height":0},n=e.title||e.name;return n&&!(e.title&&e.name)?`<div style="${Tn({...c,...t,"border-radius":`10px`,background:`linear-gradient(${o} 50%, ${Dn(o)} 50%)`})}"><div style="${Tn(En(s.single))}">${wn(n)}</div></div>`:`<div style="${Tn({...c,display:`flex`,"flex-direction":`column`,"border-radius":`10px`,background:Dn(o)})}"><div style="${Tn({...t,flex:`0 0 55%`,background:o})}"><div style="${Tn(En(s.top))}">${wn(e.title)}</div></div><div style="${Tn({...t,"flex-grow":1})}"><div style="${Tn(En(s.bottom))}">${wn(e.name)}</div></div></div>`}let l=!!(e.photo||e.name),u=n.height>=120?56:n.height>=100?48:40,d=[];e.showPhoto&&l&&d.push(`<div style="${Tn({flex:`none`,width:`${u}px`,height:`${u}px`,"border-radius":`50%`,overflow:`hidden`,background:o,color:`#fff`,display:`flex`,"align-items":`center`,"justify-content":`center`,"font-weight":600,"font-size":`${u*.38}px`})}">`+(e.photo?`<img src="${e.photo}" alt="" style="width:100%;height:100%;object-fit:cover;display:block"/>`:wn(On(e.name)))+`</div>`);let f=[];return l&&e.name&&f.push(`<div style="${Tn({...En(s.name),"font-weight":600,"font-size":`${yn.name*i}px`})}">${wn(e.name)}</div>`),e.title&&f.push(`<div style="${Tn({...En(l?s.title:s.unit),"font-size":`${(l?yn.title:yn.unit)*i}px`,"font-weight":l?400:600,opacity:l?.7:1})}">${wn(e.title)}</div>`),e.department&&f.push(`<div style="${Tn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-size":`${yn.department*i}px`,"line-height":1.4,color:o,"font-weight":600,"letter-spacing":`0.2px`})}">${wn(e.department)}</div>`),d.push(`<div style="${Tn({"min-width":0,"flex-grow":1,"max-height":`100%`,overflow:`hidden`,padding:`6px 0`,"box-sizing":`border-box`,"text-align":a})}">${f.join(``)}</div>`),`<div style="${Tn({...c,display:`flex`,"align-items":`center`,gap:`10px`,padding:`0 10px 0 14px`,border:`1px solid ${r.border}`,"border-radius":`25px`,background:r.card,color:r.text})}"><div style="${Tn({position:`absolute`,left:0,top:0,bottom:0,width:`5px`,background:o})}"></div>${d.join(``)}</div>`}function jn(e,t){let n=e.color||_n;return`<div style="${Tn({"box-sizing":`border-box`,width:`100%`,height:`100%`,"border-radius":`30px`,border:`2px ${t?`solid`:`dashed`} ${n}`,background:`${n}14`,"font-family":`inherit`})}"><div style="${Tn({height:`${rn.header}px`,display:`flex`,"align-items":`center`,padding:`0 16px`})}"><div style="${Tn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-weight":700,"font-size":`14px`,color:n})}">${wn(e.name)}</div></div></div>`}var Mn=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),W=e(((e,t)=>{t.exports=Mn()}))(),G=(0,l.createContext)({tenant:``,apiUrl:`/api`,locale:``,settings:null,revision:0}),Nn=(0,l.createContext)(null),Pn=e=>{let t=Number(e?.__page);if(Number.isFinite(t)&&t>=1)return Math.floor(t);if(typeof window>`u`)return 1;let n=Number(new URLSearchParams(window.location.search).get(`page`));return Number.isFinite(n)&&n>=1?Math.floor(n):1},Fn=()=>{if(typeof window>`u`)return{};let e={};return new URLSearchParams(window.location.search).forEach((t,n)=>{n.startsWith(`f_`)&&n.length>2&&t!==``&&(e[n.slice(2)]=t)}),e},In=e=>{let t={...e&&typeof e==`object`&&!Array.isArray(e)?e:{},...Fn()};return Object.fromEntries(Object.entries(t).filter(([,e])=>typeof e==`string`&&e.trim()!==``))},Ln=(0,l.createContext)(null),K=(...e)=>({"data-wb-part":e.filter(Boolean).join(` `)}),Rn=(0,l.createContext)(null);function zn(e,t){if(!t)return[];let n=Gn(e?.data,t);return(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id:e).filter(e=>e!=null&&e!==``).map(String)}function Bn(e,t,n){if(!t||!n||!Array.isArray(e))return[];let r=String(n.id??``);return r?e.filter(e=>zn(e,t).includes(r)):[]}var Vn=e=>qn(e).trim().toLowerCase();function Hn(e,t){let n=Array.isArray(e?.rules)?e.rules.filter(e=>e&&e.op):[];if(!n.length||!t?.entry)return!0;let r=e=>{if(e.op===`children`||e.op===`nochildren`){let n=Bn(t.all,t.parentField,t.entry).length>0;return e.op===`children`?n:!n}let n=Gn(t.entry.data,e.field),r=Vn(n),i=String(e.value??``).trim().toLowerCase(),a=(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id??e.code:null).filter(e=>e!=null).map(e=>String(e).toLowerCase()),o=Array.isArray(n)?n.length>0:r!==``;switch(e.op){case`set`:return o;case`empty`:return!o;case`eq`:return r===i||a.includes(i);case`neq`:return r!==i&&!a.includes(i);case`contains`:return i===``||r.includes(i);default:return!0}};return e.match===`any`?n.some(r):n.every(r)}function Un({showWhen:e,children:t}){return Hn(e,(0,l.useContext)(Rn))?t:null}var Wn=e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);function Gn(e,t){if(t)return t.includes(`.`)?t.split(`.`).reduce((e,t)=>e&&typeof e==`object`?e[t]:void 0,e):e?.[t]}var Kn=e=>{let t=[];for(let[n,r]of Object.entries(e??{})){if(!/^[\w-]+$/.test(n))continue;t.push(n);let e=Array.isArray(r)?r[0]:r,i=Array.isArray(r)?`${n}.0`:n;if(e&&typeof e==`object`&&!Array.isArray(e))for(let n of Object.keys(e))/^[\w-]+$/.test(n)&&t.push(`${i}.${n}`)}return t};function qn(e){return e==null?``:typeof e==`string`||typeof e==`number`||typeof e==`boolean`?String(e):typeof e==`object`&&!Array.isArray(e)&&(`label`in e||`name`in e||`slug`in e)?String(e.label??e.name??e.slug??``):typeof e==`object`&&!Array.isArray(e)&&Number.isFinite(Number(e.lat))&&Number.isFinite(Number(e.lng))?`${e.lat}, ${e.lng}`:Array.isArray(e)?e.map(e=>typeof e==`string`?e:Array.isArray(e?.parts)?e.parts.map(e=>e?.text??``).join(``):Array.isArray(e?.items)?e.items.map(e=>e?.text??``).join(` `):e&&(e.label!=null||e.name!=null||e.slug!=null)?String(e.label??e.name??e.slug):``).filter(Boolean).join(` `):``}var Jn=new Set([`href`,`src`,`poster`,`backgroundImage`]),Yn=[`created_at`,`updated_at`,`publish_at`],Xn=[`date`,`short`,`iso`,`datetime`,`time`],Zn={date:{dateStyle:`long`},short:{day:`2-digit`,month:`2-digit`,year:`numeric`},datetime:{dateStyle:`long`,timeStyle:`short`},time:{timeStyle:`short`}},Qn=e=>String(e).padStart(2,`0`);function $n(e,t=`date`,n){if(typeof e!=`string`&&!(e instanceof Date))return``;let r=typeof e==`string`?e.match(/^(\d{4})-(\d{2})-(\d{2})$/):null,i=r?new Date(Number(r[1]),Number(r[2])-1,Number(r[3])):new Date(e);if(Number.isNaN(i.getTime()))return``;if(t===`iso`)return`${i.getFullYear()}-${Qn(i.getMonth()+1)}-${Qn(i.getDate())}`;try{return new Intl.DateTimeFormat(n||void 0,Zn[t]??Zn.date).format(i)}catch{return i.toISOString()}}function er(e,t,n){let r=t?.data??{},i=Kn(r),a=[...Xn].sort((e,t)=>t.length-e.length).join(`|`),o=[...i.map(Wn).map(e=>`${e}(?:\\.(?:${a}))?`),...Yn.filter(e=>!i.includes(e)).map(e=>`${e}(?:\\.(?:${a}))?`)],s=RegExp(`:(${o.sort((e,t)=>t.length-e.length).join(`|`)})`,`g`),c=e=>{if(i.includes(e))return qn(Gn(r,e));let[,o,s]=e.match(RegExp(`^(.*?)(?:\\.(${a}))?$`));if(!i.includes(o)&&Yn.includes(o))return $n(t?.[o],s||`date`,n);let c=Gn(r,o);return s?$n(c,s,n):qn(c)},l=e=>{let t=e.match(RegExp(`^:(${o.sort((e,t)=>t.length-e.length).join(`|`)})$`)),n=t?Gn(r,t[1]):void 0;return Array.isArray(n)&&n.length?qn(n[0]):e.replace(s,(e,t)=>c(t))},u=(e,t)=>typeof e==`string`&&Jn.has(t)?l(e):typeof e==`string`?e.replace(s,(e,t)=>c(t)):Array.isArray(e)?e.map(e=>u(e)):e&&typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,u(t,e)])):e;return u(e)}var tr=[`Top`,`Right`,`Bottom`,`Left`],nr=[`TopLeft`,`TopRight`,`BottomRight`,`BottomLeft`];function rr(e){let t={},n=(n,r)=>{n in e||(t[n]=r)};for(let[r,i]of Object.entries(e))if(r===`margin`||r===`padding`){let[e,t=e,a=e,o=t]=typeof i==`number`?[i]:String(i).trim().split(/\s+/);[e,t,a,o].forEach((e,t)=>n(`${r}${tr[t]}`,e))}else if(r===`borderRadius`&&(typeof i==`number`||!/\s|\//.test(String(i))))nr.forEach(e=>n(`border${e}Radius`,i));else if(r===`border`){let[e,t,...r]=String(i).trim().split(/\s+/);tr.forEach(i=>{n(`border${i}Width`,e),n(`border${i}Style`,t),n(`border${i}Color`,r.join(` `))})}else r===`background`&&!/(gradient|url)\(/i.test(String(i))?n(`backgroundColor`,i):t[r]=i;return t}var ir=rr({margin:0,fontWeight:700,lineHeight:1.2,fontFamily:`var(--page-heading-font, inherit)`}),ar=De,or=e=>`var(--page-${e}, ${De[e]??De.h2}px)`,sr=rr({margin:0,fontSize:`var(--page-body-size, 16px)`}),cr={display:`inline-block`,textDecoration:`none`,cursor:`pointer`,backgroundColor:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},lr={flexGrow:1,display:`flex`,flexDirection:`column`,position:`relative`},ur={display:`flex`,flexDirection:`column`};function dr({style:e}){let t=e?.backgroundVideo;if(!t)return null;let n={position:`absolute`,inset:0,width:`100%`,height:`100%`,zIndex:-1,pointerEvents:`none`},r=e?.overlayColor?`color-mix(in srgb, ${e.overlayColor} ${e.overlayOpacity??50}%, transparent)`:null;return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`video`,{src:t,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{...n,objectFit:`cover`}}),r&&(0,W.jsx)(`div`,{style:{...n,background:r}})]})}var fr=(e,t)=>e?.backgroundVideo?{position:`relative`,...t,...z(e)}:{...t,...z(e)};function pr({style:e,nodeRef:t,children:n}){return(0,W.jsxs)(`div`,{ref:t,style:{...lr,...z(e)},children:[(0,W.jsx)(dr,{style:e}),n]})}function mr({style:e,nodeRef:t,children:n}){return(0,W.jsxs)(`section`,{ref:t,style:fr(e,ur),children:[(0,W.jsx)(dr,{style:e}),n]})}function hr({style:e,freeLayout:t,nodeRef:n,children:r}){let i=t?{position:`relative`,minHeight:240}:null;return(0,W.jsxs)(`div`,{ref:n,style:i?{...i,...fr(e)}:fr(e),children:[(0,W.jsx)(dr,{style:e}),r]})}function gr({href:e,target:t,style:n,nodeRef:r,children:i}){return(0,W.jsxs)(`a`,{ref:r,href:e||`#`,target:t||void 0,rel:t===`_blank`?`noopener noreferrer`:void 0,style:{...Lr,...fr(n)},children:[(0,W.jsx)(dr,{style:n}),i]})}function _r({text:e,parts:t,tag:n=`h2`,style:r,linked:i,nodeRef:a}){return(0,W.jsx)(n,{ref:a,style:{...ir,fontSize:or(n),...z(r)},children:xr(t,e,i)})}var vr={fontFamily:Ae.mono.value,background:`rgba(148, 163, 184, 0.18)`,padding:`1px 5px`,borderRadius:4,fontSize:`0.9em`},yr=rr({fontFamily:Ae.mono.value,background:`rgba(148, 163, 184, 0.16)`,border:`1px solid rgba(148, 163, 184, 0.3)`,borderRadius:6,padding:`12px 14px`,fontSize:`0.875em`,lineHeight:1.55,overflowX:`auto`,whiteSpace:`pre`});function br(e,t=[],n,r,i=!1){let a=e;return t.includes(`sup`)?a=(0,W.jsx)(`sup`,{children:a}):t.includes(`sub`)&&(a=(0,W.jsx)(`sub`,{children:a})),t.includes(`code`)&&(a=(0,W.jsx)(`code`,{style:vr,children:a})),t.includes(`strike`)&&(a=(0,W.jsx)(`s`,{children:a})),t.includes(`underline`)&&(a=(0,W.jsx)(`u`,{children:a})),t.includes(`italic`)&&(a=(0,W.jsx)(`em`,{children:a})),t.includes(`bold`)&&(a=(0,W.jsx)(`strong`,{children:a})),n?a=(0,W.jsx)(`a`,{href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":i?void 0:``,style:{...i&&{color:`inherit`},...t.includes(`nounderline`)&&{textDecoration:`none`}},children:a}):t.includes(`nounderline`)&&(a=(0,W.jsx)(`span`,{style:{textDecoration:`none`},children:a})),a}function xr(e,t,n){return e?.length?e.map((e,t)=>{if(e.slot)return(0,W.jsx)(l.Fragment,{children:n?.[e.slot]??null},t);if(e.parts)return(0,W.jsx)(l.Fragment,{children:xr(e.parts,``,n)},t);if(e.br)return(0,W.jsx)(`br`,{},t);let r=e.text;return e.image&&(r=(0,W.jsx)(`img`,{src:e.image.src,alt:e.image.alt||``,title:e.image.title||void 0,style:{maxWidth:`100%`,verticalAlign:`middle`}})),e.sup?r=(0,W.jsx)(`sup`,{children:r}):e.sub&&(r=(0,W.jsx)(`sub`,{children:r})),e.code&&(r=(0,W.jsx)(`code`,{style:vr,children:r})),e.strike&&(r=(0,W.jsx)(`s`,{children:r})),e.underline&&(r=(0,W.jsx)(`u`,{children:r})),e.italic&&(r=(0,W.jsx)(`em`,{children:r})),e.bold&&(r=(0,W.jsx)(`strong`,{children:r})),(e.color||e.background)&&(r=(0,W.jsx)(`span`,{style:{...e.color&&{color:e.color},...e.background&&{backgroundColor:e.background}},children:r})),e.href?r=(0,W.jsx)(`a`,{href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":``,style:{...e.color&&{color:e.color},...e.nounderline&&{textDecoration:`none`}},children:r}):e.nounderline&&(r=(0,W.jsx)(`span`,{style:{textDecoration:`none`},children:r})),(0,W.jsx)(l.Fragment,{children:r},t)}):t}function Sr({parts:e,text:t,marks:n,href:r,target:i,style:a}){return(0,W.jsx)(`span`,{style:z(a),children:e?.length?xr(e,t):br(t,n,r,i,!!z(a)?.color)})}var Cr=[`left`,`center`,`right`,`justify`];function wr(e,t,n){let r=e&&e.cellStyles;if(!r||typeof r!=`object`||Array.isArray(r))return{};let i=r[`${t}:${n}`];return i&&typeof i==`object`&&!Array.isArray(i)?i:{}}function Tr(e,t){let n=e||{},r=typeof n.bold==`boolean`?n.bold:!!t;return{textAlign:Cr.includes(n.align)?n.align:`left`,fontWeight:r?700:400,fontStyle:n.italic?`italic`:void 0,color:typeof n.color==`string`&&n.color?n.color:void 0,backgroundColor:typeof n.bg==`string`&&n.bg?n.bg:void 0}}function Er({align:e=`center`,width:t,wrap:n}={}){let r=t?`${t}%`:void 0;if(e===`full`)return{width:`100%`};let i=e===`left`||e===`right`;return i&&(n??!0)?{float:e,width:r??`50%`,maxWidth:`100%`,marginTop:`4px`,marginBottom:`12px`,...e===`left`?{marginRight:`20px`,marginLeft:0}:{marginLeft:`20px`,marginRight:0}}:i?{width:r??`fit-content`,maxWidth:`100%`,...e===`left`?{marginLeft:0,marginRight:`auto`}:{marginLeft:`auto`,marginRight:0}}:{width:r??`fit-content`,maxWidth:`100%`,marginLeft:`auto`,marginRight:`auto`}}var Dr={red:`#e03131`,orange:`#e8590c`,yellow:`#c98a00`,blue:`#1c7ed6`,purple:`#7048e8`,pink:`#d6336c`,green:`#2f9e44`,grey:`#868e96`},Or={red:`rgba(224, 49, 49, 0.12)`,orange:`rgba(232, 89, 12, 0.12)`,yellow:`rgba(201, 138, 0, 0.15)`,blue:`rgba(28, 126, 214, 0.12)`,purple:`rgba(112, 72, 232, 0.12)`,pink:`rgba(214, 51, 108, 0.12)`,green:`rgba(47, 158, 68, 0.12)`,grey:`rgba(134, 142, 150, 0.16)`};function kr(e){let t=Dr[e?.color]??(e?.color||``),n=Or[e?.background]??(e?.background||``);return{...t&&{color:t},...n&&{backgroundColor:n,padding:`8px 12px`,borderRadius:`8px`}}}function Ar(e=[],t,n){let r=n??((e,n)=>xr(e,n,t));return e.map((n,i)=>{let a={marginTop:0,marginBottom:i===e.length-1?0:14};if(n.type===`image`){if(!n.src)return null;let e=(0,W.jsx)(`img`,{...K(`image`),src:n.src,alt:n.alt||``,style:{width:`100%`,display:`block`,borderRadius:6}});return(0,W.jsxs)(`figure`,{...K(`figure`),style:{marginLeft:0,marginRight:0,...a,...Er(n)},children:[n.href?(0,W.jsx)(`a`,{href:n.href,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`},children:e}):e,n.caption&&(0,W.jsx)(`figcaption`,{...K(`caption`),style:{fontSize:13,opacity:.65,marginTop:6,textAlign:`center`},children:n.caption})]},i)}if(n.type===`video`)return Gr(n.url)?(0,W.jsx)(`div`,{...K(`video`),style:{...a,...Er({align:n.align,wrap:n.wrap,width:n.width??100})},children:(0,W.jsx)(Kr,{url:n.url,autoplay:n.autoplay,muted:n.muted,loop:n.loop,controls:n.controls??!0,start:n.start})},i):null;if(n.type===`button`){if(!(typeof n.label==`string`&&n.label.trim()))return null;let e=Number.isFinite(Number(n.radius))?Number(n.radius):8,t=[`center`,`right`].includes(n.align)?n.align:`left`;return(0,W.jsx)(`div`,{style:{...a,textAlign:t},children:(0,W.jsx)(`table`,{role:`presentation`,cellPadding:0,cellSpacing:0,style:{borderCollapse:`separate`,display:`inline-table`},children:(0,W.jsx)(`tbody`,{children:(0,W.jsx)(`tr`,{children:(0,W.jsx)(`td`,{style:{backgroundColor:n.bg||`var(--page-accent, #4f46e5)`,borderRadius:e},children:(0,W.jsx)(`a`,{...K(`button`),href:n.href||`#`,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`inline-block`,padding:`13px 24px`,color:n.color||`#ffffff`,fontSize:15,fontWeight:600,lineHeight:1.2,textDecoration:`none`,borderRadius:e},children:n.label})})})})})},i)}if(n.type===`divider`)return(0,W.jsx)(`hr`,{...K(`divider`),style:{...a,border:0,borderTop:`1px solid rgba(148, 163, 184, 0.4)`}},i);if(n.type===`table`){let e=Array.isArray(n.rows)?n.rows.filter(Array.isArray):[];if(!e.length)return null;let t=n.header!==!1,o=n.borders===!1?void 0:`1px solid rgba(148, 163, 184, 0.4)`,s=Number.isFinite(n.padX)?Math.max(0,n.padX):10,c=Number.isFinite(n.padY)?Math.max(0,n.padY):6,l=Math.max(0,Number(n.spacing)||0),u={border:o,padding:`${c}px ${s}px`,verticalAlign:`top`},d=Array.isArray(n.heights)?n.heights:null,f=e=>{let t=Number(d?.[e]);return Number.isFinite(t)&&t>0?{height:`${t}px`}:void 0},p=t?e.slice(1):e,m=Array.isArray(n.widths)?n.widths:null,h=(e,t,r)=>({...u,...Tr(wr(n,e,t),r)}),g=n.spans&&typeof n.spans==`object`?n.spans:null,_=new Set;g&&e.forEach((e,t)=>e.forEach((e,n)=>{let r=g[`${t}:${n}`];if(!r)return;let i=Math.max(1,Number(r.c)||1),a=Math.max(1,Number(r.r)||1);for(let e=0;e<a;e+=1)for(let r=0;r<i;r+=1)(e||r)&&_.add(`${t+e}:${n+r}`)}));let v=(e,t)=>{let n=g?.[`${e}:${t}`],r=Math.max(1,Number(n?.c)||1),i=Math.max(1,Number(n?.r)||1);return{colSpan:r>1?r:void 0,rowSpan:i>1?i:void 0}};return(0,W.jsxs)(`table`,{...K(`table`),style:{...a,borderCollapse:l?`separate`:`collapse`,borderSpacing:l?`${l}px`:void 0,width:`100%`,fontSize:sr.fontSize,tableLayout:m?`fixed`:void 0},children:[typeof n.caption==`string`&&n.caption.trim()?(0,W.jsx)(`caption`,{...K(`caption`),style:{captionSide:`top`,textAlign:`left`,fontWeight:600,padding:`0 0 6px`},children:n.caption}):null,m&&(0,W.jsx)(`colgroup`,{children:m.map((e,t)=>(0,W.jsx)(`col`,{style:{width:`${e}%`}},t))}),t&&(0,W.jsx)(`thead`,{children:(0,W.jsx)(`tr`,{...K(`header-row`),style:f(0),children:e[0].map((e,t)=>_.has(`0:${t}`)?null:(0,W.jsx)(`th`,{...K(`header-cell`),scope:`col`,style:h(0,t,!0),...v(0,t),children:Array.isArray(e)?r(e):e},t))})}),(0,W.jsx)(`tbody`,{children:p.map((e,n)=>(0,W.jsx)(`tr`,{...K(`row`),style:f(t?n+1:n),children:e.map((e,i)=>{let a=t?n+1:n;return _.has(`${a}:${i}`)?null:(0,W.jsx)(`td`,{...K(`cell`),style:h(a,i,!1),...v(a,i),children:Array.isArray(e)?r(e):e},i)})},n))})]},i)}if(n.type===`ul`||n.type===`ol`){let e=n.type;return(0,W.jsx)(e,{...K(`list`,n.type===`ol`&&`list-ordered`),style:{fontSize:sr.fontSize,...a,...kr(n),paddingLeft:n.background?34:24},start:n.type===`ol`?n.start:void 0,children:(n.items??[]).map((e,n)=>{let i=typeof e.task==`boolean`;return(0,W.jsxs)(`li`,{...K(`list-item`),style:{marginBottom:4,...i&&{listStyleType:`none`,marginLeft:-18}},children:[i&&(0,W.jsx)(`span`,{style:{marginRight:6},children:e.task?`☑`:`☐`}),r(e.parts,e.text),e.blocks?.length?Ar(e.blocks,t,r):null]},n)})},i)}if(n.type===`quote`)return(0,W.jsx)(`blockquote`,{...K(`quote`),style:{...Nr,fontSize:sr.fontSize,...a,...kr(n),...n.background&&{paddingLeft:20}},children:n.blocks?.length?Ar(n.blocks,t,r):r(n.parts,n.text)},i);if(n.type===`code`)return(0,W.jsx)(`pre`,{...K(`code`),"data-lang":n.lang||void 0,style:{...a,...yr},children:(0,W.jsx)(`code`,{style:{fontFamily:`inherit`},children:n.text})},i);if(ar[n.type]){let e=n.type;return(0,W.jsx)(e,{...K(`heading`,`heading-${n.type}`),style:{...ir,fontSize:or(n.type),...a,...kr(n)},children:r(n.parts,n.text)},i)}return(0,W.jsx)(`p`,{...K(`paragraph`),style:{...sr,...a,...kr(n)},children:r(n.parts,n.text)},i)})}function jr({content:e,style:t,linked:n,nodeRef:r}){return(0,W.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(t)},children:Ar(e,n)})}function Mr({markdown:e,newTab:t,style:n,nodeRef:r}){let i=(0,l.useMemo)(()=>Jt(e,{newTab:t}),[e,t]);return(0,W.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(n)},children:Ar(i)})}var Nr=rr({margin:0,padding:`8px 0 8px 20px`,borderLeftWidth:`4px`,borderLeftStyle:`solid`,borderLeftColor:`var(--page-accent, rgba(148, 163, 184, 0.6))`});function Pr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,W.jsx)(`blockquote`,{ref:i,style:{...Nr,...z(n)},children:xr(t,e,r)})}function Fr({ordered:e,items:t=[],style:n,nodeRef:r}){return(0,W.jsx)(e?`ol`:`ul`,{ref:r,style:{margin:0,paddingLeft:24,...z(n)},children:t.map((e,t)=>(0,W.jsx)(`li`,{...K(`item`),style:{marginBottom:4},children:xr(e.parts,e.text)},t))})}function Ir({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,W.jsx)(`p`,{ref:i,style:{...sr,...z(n)},children:xr(t,e,r)})}var Lr={display:`block`,color:`inherit`,textDecoration:`none`,cursor:`pointer`},Rr={textUnderlineOffset:3,cursor:`pointer`};function zr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,W.jsx)(`a`,{ref:o,"data-wb-link":``,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...Rr,...z(i)},children:xr(t,e,a)})}function Br({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,W.jsx)(`a`,{ref:o,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...cr,...z(i)},children:xr(t,e,a)})}function Vr({src:e,alt:t,decorative:n,style:r,nodeRef:i}){return e?(0,W.jsx)(`img`,{ref:i,src:e,alt:n?``:t||``,role:n?`presentation`:void 0,style:{display:`block`,maxWidth:`100%`,...z(r)}}):null}function Hr({text:e,locale:t}){let n=String(e??``).trim();return n?(0,W.jsxs)(`details`,{...K(`transcript`),style:{marginTop:8,fontSize:14},children:[(0,W.jsx)(`summary`,{...K(`transcript-toggle`),style:{cursor:`pointer`,fontWeight:600},children:Xe(t)(`transcript`)}),(0,W.jsx)(`div`,{...K(`transcript-text`),style:{marginTop:8,lineHeight:1.6},children:n.split(/\n\s*\n/).map((e,t)=>(0,W.jsx)(`p`,{style:{margin:`0 0 8px`,whiteSpace:`pre-line`},children:e},t))})]}):null}var Ur=e=>(Array.isArray(e)?e:[]).filter(e=>typeof e?.src==`string`&&e.src.trim());function Wr({src:e,poster:t,controls:n=!0,autoplay:r=!1,loop:i=!1,muted:a=!1,title:o=``,tracks:s,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(G);if(!e)return null;let p=Ur(s),m=typeof o==`string`&&o.trim()?o.trim():void 0,h=typeof c==`string`&&c.trim(),g=(0,W.jsx)(`video`,{ref:h?void 0:d,...h?{"data-wb-self":``}:{},src:e,poster:t||void 0,controls:n,"aria-label":m,autoPlay:r,muted:a||r,loop:i,playsInline:!0,crossOrigin:p.length?`anonymous`:void 0,style:{display:`block`,width:`100%`,maxWidth:`100%`,...z(u)},children:p.map((e,t)=>(0,W.jsx)(`track`,{kind:e.kind===`captions`?`captions`:`subtitles`,src:e.src,srcLang:e.srclang||void 0,label:e.label||e.srclang||void 0,default:e.default?!0:void 0},e.key??t))});return h?(0,W.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[g,(0,W.jsx)(Hr,{text:c,locale:f})]}):g}var Gr=(e=``)=>(e.match(/(?:youtu\.be\/|v=|embed\/|shorts\/|live\/)([\w-]{11})/)||e.match(/^([\w-]{11})$/))?.[1];function Kr({url:e,autoplay:t=!1,muted:n=!1,loop:r=!1,controls:i=!0,start:a,title:o=``,captions:s=!1,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(G),p=Gr(e);if(!p)return null;let m=new URLSearchParams({rel:`0`});if(t&&m.set(`autoplay`,`1`),(n||t)&&m.set(`mute`,`1`),i||m.set(`controls`,`0`),r&&(m.set(`loop`,`1`),m.set(`playlist`,p)),Number(a)>0&&m.set(`start`,String(Math.floor(Number(a)))),s){m.set(`cc_load_policy`,`1`);let e=String(f||``).split(/[-_]/)[0];e&&m.set(`cc_lang_pref`,e)}let h=(0,W.jsx)(`iframe`,{...K(`frame`),src:`https://www.youtube-nocookie.com/embed/${p}?${m}`,title:typeof o==`string`&&o.trim()?o.trim():Xe(f)(`video`),allow:`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share`,allowFullScreen:!0,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,border:0}});return typeof c==`string`&&c.trim()?(0,W.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[(0,W.jsx)(`div`,{"data-wb-self":``,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h}),(0,W.jsx)(Hr,{text:c,locale:f})]}):(0,W.jsx)(`div`,{ref:d,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h})}function qr({src:e,title:t,allowFullscreen:n=!0,style:r,nodeRef:i}){let{locale:a}=(0,l.useContext)(G);return e?(0,W.jsx)(`iframe`,{ref:i,src:e,title:t||Xe(a)(`frame`),loading:`lazy`,allowFullScreen:n,style:{display:`block`,width:`100%`,height:300,border:0,...z(r)}}):null}function Jr(e,{toolbar:t=!0,page:n,zoom:r}={}){let i=_t(e);if(!i)return``;let a=[];return t===!1&&a.push(`toolbar=0&navpanes=0`),Number(n)>1&&a.push(`page=${Number(n)}`),r&&r!==`auto`&&a.push(`zoom=${r}`),a.length?`${i.split(`#`)[0]}#${a.join(`&`)}`:i}function Yr({src:e,title:t,toolbar:n=!0,page:r,zoom:i=`auto`,link:a=!0,linkLabel:o,fallbackText:s,style:c,nodeRef:l}){let u=_t(e);if(!u)return null;let d=o||`Open the PDF`,f=t||`PDF document`;return(0,W.jsxs)(`div`,{ref:l,style:{display:`flex`,flexDirection:`column`,width:`100%`,height:600,...z(c)},children:[(0,W.jsx)(`object`,{data:Jr(u,{toolbar:n,page:r,zoom:i}),type:`application/pdf`,"aria-label":f,...K(`document`),style:{display:`block`,flex:`1 1 auto`,minHeight:0,width:`100%`,border:0},children:(0,W.jsxs)(`div`,{...K(`fallback`),style:{display:`grid`,placeItems:`center`,gap:8,height:`100%`,padding:16,textAlign:`center`},children:[(0,W.jsx)(`p`,{style:{...sr,opacity:.75},children:s||`This browser can’t show the PDF here.`}),!a&&(0,W.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, inherit)`},children:d})]})},Jr(u,{toolbar:n,page:r,zoom:i})),a&&(0,W.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,...K(`link`),style:{flexShrink:0,marginTop:8,color:`var(--page-accent, inherit)`,fontSize:14},children:d})]})}var Xr=/(^|[\s,>+~{}])(:root|html|body)(?=$|[\s,{.:#[>+~])/g;function Zr(e){return`@scope ([data-wb-embed]) {\n${e.replace(Xr,`$1:scope`)}\n}`}function Qr({code:e,runScripts:t=!0,scopeStyles:n=!1,style:r,nodeRef:i}){let[a,o]=(0,l.useState)(null);return(0,l.useEffect)(()=>{a&&(a.innerHTML=e||``,n?(a.setAttribute(`data-wb-embed`,``),a.querySelectorAll(`style`).forEach(e=>{e.textContent=Zr(e.textContent||``)})):a.removeAttribute(`data-wb-embed`),t&&a.querySelectorAll(`script`).forEach(e=>{let t=document.createElement(`script`);for(let{name:n,value:r}of e.attributes)t.setAttribute(n,r);t.text=e.textContent,e.replaceWith(t)}))},[a,e,t,n]),(0,W.jsx)(`div`,{ref:e=>{o(e),i&&i(e)},style:z(r)})}function $r({height:e,style:t,nodeRef:n}){return(0,W.jsx)(`div`,{ref:n,style:{height:e||32,flexShrink:0,alignSelf:`stretch`,...z(t)}})}function ei({style:e,nodeRef:t}){return(0,W.jsx)(`div`,{ref:t,style:{height:1,alignSelf:`stretch`,flexShrink:0,...z(e)}})}function ti({style:e,nodeRef:t}){return(0,W.jsx)(`div`,{ref:t,style:{flexShrink:0,...z(e)}})}var ni={position:`absolute`,top:`50%`,transform:`translateY(-50%)`,width:36,height:36,borderRadius:`50%`,border:0,cursor:`pointer`,background:`rgba(17, 24, 39, 0.45)`,color:`#fff`,fontSize:20,lineHeight:1,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:0},ri={bottom:{inset:`auto 0 0 0`,padding:`40px 24px 20px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.55))`},top:{inset:`0 0 auto 0`,padding:`20px 24px 40px`,background:`linear-gradient(rgba(0, 0, 0, 0.55), transparent)`},middle:{inset:0,display:`flex`,flexDirection:`column`,justifyContent:`center`,padding:24,textShadow:`0 2px 12px rgba(0, 0, 0, 0.6)`}},ii=48;function ai({count:e,renderSlide:t,autoplay:n=!0,interval:r=5,height:i=320,swipe:a=!0,style:o,nodeRef:s}){let[c,u]=(0,l.useState)(0),[d,f]=(0,l.useState)(!1),[p,m]=(0,l.useState)(!1),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(null),{locale:y}=(0,l.useContext)(G),b=e?Math.min(c,e-1):0;if((0,l.useEffect)(()=>{window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches&&g(!0)},[]),(0,l.useEffect)(()=>{if(!n||h||d||p||_||e<2)return;let t=setInterval(()=>u(t=>(t+1)%e),Math.max(2,Number(r)||5)*1e3);return()=>clearInterval(t)},[n,h,d,p,_,r,e]),!e)return null;let x=Xe(y),S=t=>u((t+e)%e),C=()=>{if(!_)return;let{dx:e}=_;v(null),e<-48?S(b+1):e>ii&&S(b-1)};return(0,W.jsxs)(`div`,{ref:s,role:`region`,"aria-roledescription":`carousel`,onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1),onFocus:()=>m(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||m(!1)},onPointerDown:a&&e>1?e=>{e.pointerType===`mouse`&&e.button!==0||e.target.closest(`button`)||(e.currentTarget.setPointerCapture(e.pointerId),v({startX:e.clientX,dx:0}))}:void 0,onPointerMove:_?e=>v(t=>t&&{...t,dx:e.clientX-t.startX}):void 0,onPointerUp:C,onPointerCancel:C,style:{position:`relative`,overflow:`hidden`,width:`100%`,height:i,touchAction:`pan-y`,userSelect:_?`none`:void 0,cursor:_?`grabbing`:void 0,...z(o)},children:[(0,W.jsx)(`div`,{...K(`track`),style:{display:`flex`,height:`100%`,transform:`translateX(calc(${-b*100}% + ${_?.dx??0}px))`,transition:_?`none`:`transform 450ms ease`},children:Array.from({length:e},(n,r)=>(0,W.jsx)(`div`,{...K(`slide`,r===b&&`slide-active`),role:`group`,"aria-roledescription":`slide`,"aria-label":x(`slide`,{n:r+1,total:e}),"aria-hidden":r!==b||void 0,inert:r!==b||void 0,style:{position:`relative`,width:`100%`,flexShrink:0,overflow:`hidden`},children:t(r)},r))}),e>1&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`button`,{type:`button`,...K(`arrow`,`arrow-prev`),"aria-label":x(`prevSlide`),style:{...ni,left:12},onClick:()=>S(b-1),children:`‹`}),(0,W.jsx)(`button`,{type:`button`,...K(`arrow`,`arrow-next`),"aria-label":x(`nextSlide`),style:{...ni,right:12},onClick:()=>S(b+1),children:`›`}),(0,W.jsx)(`div`,{...K(`dots`),style:{position:`absolute`,bottom:10,left:0,right:0,display:`flex`,justifyContent:`center`,gap:6},children:Array.from({length:e},(e,t)=>(0,W.jsx)(`button`,{type:`button`,"aria-label":x(`goToSlide`,{n:t+1}),"aria-current":t===b?`true`:void 0,...K(`dot`,t===b&&`dot-active`),onClick:()=>S(t),style:{width:8,height:8,borderRadius:`50%`,border:0,padding:0,cursor:`pointer`,background:t===b?`#ffffff`:`rgba(255, 255, 255, 0.45)`}},t))}),n&&(0,W.jsx)(`button`,{type:`button`,...K(`pause`,h&&`pause-stopped`),"aria-label":x(h?`play`:`pause`),onClick:()=>g(!h),style:{...ni,top:`auto`,bottom:8,right:12,transform:`none`,width:28,height:28},children:(0,W.jsx)(`svg`,{viewBox:`0 0 24 24`,width:14,height:14,fill:`currentColor`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:h?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})})]})]})}var oi=(e,t)=>({position:`absolute`,inset:0,backgroundImage:e?`url(${e})`:`none`,backgroundColor:t||(e?void 0:`rgba(148, 163, 184, 0.25)`),backgroundSize:`cover`,backgroundPosition:`center`});function si({slides:e=[],captionPosition:t=`bottom`,captionAlign:n=`left`,...r}){return e.length?(0,W.jsx)(ai,{...r,count:e.length,renderSlide:r=>{let i=e[r];return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...K(`slide-image`),style:oi(i.image)}),(i.title||i.text)&&(0,W.jsxs)(`div`,{...K(`caption`),style:{position:`absolute`,color:`#fff`,textAlign:n,...ri[t]??ri.bottom},children:[i.title&&(0,W.jsx)(`div`,{...K(`caption-title`),style:{fontSize:22,fontWeight:700},children:i.title}),i.text&&(0,W.jsx)(`div`,{...K(`caption-text`),style:{fontSize:14,opacity:.9,marginTop:4},children:i.text})]})]})}}):null}function ci({slides:e=[],linked:t,...n}){return e.length?(0,W.jsx)(ai,{...n,count:e.length,renderSlide:n=>{let r=e[n];return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...K(`slide-background`),style:oi(r.image,r.color)}),(0,W.jsx)(`div`,{...K(`slide-content`),style:{position:`absolute`,inset:0,display:`flex`,flexDirection:`column`},children:t?.[r.key]??null})]})}}):null}var li=256,ui=e=>Math.log(Math.tan(Math.PI/4+Math.max(-85,Math.min(85,e))*Math.PI/360)),di=(e,t,n)=>{let r=li*2**n;return{x:(Number(t)+180)/360*r,y:(.5-ui(Number(e))/(2*Math.PI))*r}},fi=(e,t)=>{if(e===``||e==null)return null;let n=Number(e);return Number.isFinite(n)&&Math.abs(n)<=t?n:null},pi=e=>!!e&&fi(e.lat,90)!==null&&fi(e.lng,180)!==null;function mi(e,t,n=`directions`,r=``){let i=`${e},${t}`;return n===`place`?`https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(i)}${r?`&query_place_id=`:``}`:`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(i)}`}var hi=`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,gi=e=>{let t=String(e??``).trim();return/^https?:\/\//i.test(t)&&t.includes(`{z}`)&&t.includes(`{x}`)&&t.includes(`{y}`)?t:hi},_i=e=>{try{return new URL(e.replace(/[{}]/g,``)).host}catch{return e}},vi=(e,t,n=13)=>`https://www.openstreetmap.org/?mlat=${e}&mlon=${t}#map=${Math.round(Number(n)||13)}/${e}/${t}`;function yi({markers:e,lat:t,lng:n,zoom:r=``,height:i=320,pinSize:a=22,pinLink:o=`directions`,link:s=!1,label:c=``,tileUrl:u=``,tileError:d=``,style:f,nodeRef:p,inert:m}){let h=(0,l.useRef)(null),[g,_]=(0,l.useState)(1200),v=gi(u),[y,b]=(0,l.useState)({key:``,failed:0,loaded:0});(0,l.useEffect)(()=>{let e=h.current;if(!e||typeof ResizeObserver>`u`)return;let t=()=>_(t=>e.clientWidth&&e.clientWidth!==t?e.clientWidth:t);t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]);let x=(Array.isArray(e)?e:[]).filter(pi),S=pi({lat:t,lng:n})?{lat:fi(t,90),lng:fi(n,180)}:x.length?{lat:x.reduce((e,t)=>e+fi(t.lat,90),0)/x.length,lng:x.reduce((e,t)=>e+fi(t.lng,180),0)/x.length}:null,C=Math.max(80,Number(i)||320),w=fi(r,19)?Math.min(Math.max(Math.round(Number(r)),1),19):(()=>{if(x.length<2)return 13;for(let e=19;e>=1;e--){let t=x.map(t=>di(fi(t.lat,90),fi(t.lng,180),e)),n=Math.max(...t.map(e=>e.x))-Math.min(...t.map(e=>e.x)),r=Math.max(...t.map(e=>e.y))-Math.min(...t.map(e=>e.y));if(n<=g*.8&&r<=C*.7)return e}return 1})(),T={width:`100%`,...z(f)};if(!S)return(0,W.jsx)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:{...T,minHeight:80,display:`grid`,placeItems:`center`,fontSize:13,opacity:.6,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:8},children:`Set the coordinates in Settings`});let E=di(S.lat,S.lng,w),D={x:E.x-g/2,y:E.y-C/2},O=[],k=[];for(let e=Math.floor(D.x/li);e<=Math.floor((D.x+g)/li);e++)O.push(e);for(let e=Math.floor(D.y/li);e<=Math.floor((D.y+C)/li);e++)k.push(e);let A=2**w,j=`${v}|${w}`,M=y.key===j?y:{key:j,failed:0,loaded:0},N=e=>b(t=>{let n=t.key===j?t:{key:j,failed:0,loaded:0};return{...n,[e]:n[e]+1}}),P=M.failed>0&&M.loaded===0;return(0,W.jsxs)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:T,children:[(0,W.jsxs)(`div`,{role:`img`,"aria-label":c||`Map`,...K(`map`),style:{position:`relative`,height:C,overflow:`hidden`,borderRadius:`inherit`,background:`var(--page-surface, #e5e7eb)`},children:[k.map(e=>O.map(t=>{let n=(t%A+A)%A;return e<0||e>=A?null:(0,W.jsx)(`img`,{src:v.replace(`{z}`,w).replace(`{x}`,n).replace(`{y}`,e),alt:``,onLoad:()=>N(`loaded`),onError:e=>{e.currentTarget.style.visibility=`hidden`,N(`failed`)},width:li,height:li,loading:`lazy`,style:{position:`absolute`,left:Math.round(t*li-D.x),top:Math.round(e*li-D.y),width:li,height:li,userSelect:`none`,pointerEvents:`none`}},`${j}:${t}-${e}`)})),P&&m&&d?(0,W.jsx)(`div`,{style:{...U,position:`absolute`,left:12,right:12,top:12,padding:`8px 12px`,borderRadius:8,background:`rgba(15, 23, 42, 0.78)`,color:`#fff`,fontSize:12,lineHeight:1.45},children:d.replace(`{host}`,_i(v))}):null,x.map((e,t)=>{let n=di(fi(e.lat,90),fi(e.lng,180),w),r=n.x-D.x,i=n.y-D.y,s=e.color||`var(--page-accent, #dc2626)`,c=o===`none`||m?null:mi(fi(e.lat,90),fi(e.lng,180),o,e.title);return(0,W.jsxs)(c?`a`:`span`,{...K(`pin`),href:c||void 0,target:c?`_blank`:void 0,rel:c?`noopener noreferrer`:void 0,title:c&&e.title||void 0,style:{position:`absolute`,left:r,top:i,transform:`translate(-50%, -100%)`,cursor:c?`pointer`:`default`,textDecoration:`none`,color:`inherit`},children:[e.title?(0,W.jsx)(`span`,{...K(`pin-label`),style:{position:`absolute`,left:`50%`,bottom:`100%`,transform:`translateX(-50%)`,marginBottom:4,padding:`3px 7px`,borderRadius:6,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.5))`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.25)`,fontSize:12,lineHeight:1.35,whiteSpace:`nowrap`},children:e.title}):null,(0,W.jsxs)(`svg`,{width:Math.max(10,Number(a)||22),height:Math.max(10,Number(a)||22),viewBox:`0 0 24 24`,fill:s,style:{display:`block`},children:[(0,W.jsx)(`path`,{d:`M12 22s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11z`}),bi[e.icon]?(0,W.jsx)(`path`,{d:bi[e.icon],transform:`translate(12 10.5) scale(0.46) translate(-12 -12)`,fill:`none`,stroke:`#fff`,strokeWidth:4,strokeLinecap:`round`,strokeLinejoin:`round`}):(0,W.jsx)(`circle`,{cx:`12`,cy:`10.5`,r:`2.6`,fill:`#fff`})]})]},t)}),(0,W.jsx)(`a`,{href:`https://www.openstreetmap.org/copyright`,target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...K(`credit`),style:{position:`absolute`,right:4,bottom:3,padding:`1px 5px`,borderRadius:4,background:`rgba(255, 255, 255, 0.75)`,color:`#334155`,fontSize:10,textDecoration:`none`},children:`© OpenStreetMap`})]}),s?(0,W.jsx)(`a`,{href:vi(S.lat,S.lng,w),target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...K(`link`),style:{display:`inline-block`,marginTop:6,fontSize:12,color:`var(--page-accent, inherit)`},children:`View larger map`}):null]})}var bi={check:`M4 12l5 5L20 6`,close:`M6 6l12 12M18 6L6 18`,plus:`M12 5v14M5 12h14`,minus:`M5 12h14`,"arrow-right":`M4 12h16M13 5l7 7-7 7`,"arrow-left":`M20 12H4M11 5l-7 7 7 7`,"arrow-up":`M12 20V4M5 11l7-7 7 7`,"arrow-down":`M12 4v16M5 13l7 7 7-7`,"chevron-right":`M9 5l7 7-7 7`,"chevron-left":`M15 5l-7 7 7 7`,"chevron-down":`M5 9l7 7 7-7`,"chevron-up":`M5 15l7-7 7 7`,menu:`M4 7h16M4 12h16M4 17h16`,star:`M12 3.5l2.6 5.3 5.9.9-4.3 4.1 1 5.8-5.2-2.7-5.2 2.7 1-5.8L3.5 9.7l5.9-.9z`,heart:`M12 20s-7-4.4-7-9a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 4.6-7 9-7 9z`,home:`M4 11l8-7 8 7M6 10v9h12v-9`,user:`M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM4 20c0-3.3 3.6-5 8-5s8 1.7 8 5`,mail:`M3 6h18v12H3zM3 6l9 7 9-7`,phone:`M6 3h4l2 5-3 2a12 12 0 0 0 5 5l2-3 5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 4 5a2 2 0 0 1 2-2z`,search:`M11 4a7 7 0 1 0 0 14 7 7 0 0 0 0-14zM20 20l-4.2-4.2`,clock:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 7v5l3 2`,calendar:`M4 6h16v14H4zM4 10h16M8 3v4M16 3v4`,download:`M12 4v10M8 11l4 4 4-4M4 19h16`,upload:`M12 20V10M8 13l4-4 4 4M4 5h16`,play:`M8 5l11 7-11 7z`,pause:`M9 5v14M15 5v14`,info:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 11v5M12 8h.01`,alert:`M12 4l9 16H3zM12 10v4M12 17h.01`,lock:`M6 11h12v9H6zM9 11V8a3 3 0 0 1 6 0v3`,chat:`M4 5h16v11H9l-5 4z`,"map-pin":`M12 21s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11zM12 12a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5z`,camera:`M4 8h4l2-2h4l2 2h4v12H4zM12 17a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z`,image:`M4 5h16v14H4zM8 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM6 17l5-5 4 4 2-2 3 3`,file:`M7 3h7l4 4v14H7zM14 3v5h4`,link:`M10 14a4 4 0 0 0 6 .5l2-2a4 4 0 0 0-6-6l-1 1M14 10a4 4 0 0 0-6-.5l-2 2a4 4 0 0 0 6 6l1-1`,external:`M14 4h6v6M20 4l-9 9M18 14v5H5V6h5`,trash:`M4 7h16M9 7V5h6v2M6 7l1 13h10l1-13`,edit:`M4 20h4L19 9l-4-4L4 16z`,filter:`M3 5h18l-7 8v6l-4-2v-4z`,refresh:`M20 12a8 8 0 1 1-2.3-5.7M20 4v5h-5`,globe:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM3 12h18M12 3c2.5 3 2.5 15 0 18M12 3c-2.5 3-2.5 15 0 18`,bell:`M6 16V11a6 6 0 1 1 12 0v5l2 3H4zM10 22h4`,tag:`M4 4h7l9 9-7 7-9-9zM8.5 8.5h.01`,cart:`M4 5h2l2 10h10l2-7H7M9 20h.01M18 20h.01`,card:`M3 6h18v12H3zM3 10h18`,shield:`M12 3l8 3v6c0 5-4 8-8 9-4-1-8-4-8-9V6z`,sun:`M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zM12 2v2M12 20v2M4 12H2M22 12h-2M5 5l1.5 1.5M17.5 17.5L19 19M19 5l-1.5 1.5M6.5 17.5L5 19`,moon:`M20 14a8 8 0 1 1-10-10 7 7 0 0 0 10 10z`,settings:`M12 9.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM12 2l1 2.6 2.7-.6 1 2.5 2.6 1-.6 2.7L21 12l-2.3 1.8.6 2.7-2.6 1-1 2.5-2.7-.6L12 22l-1-2.6-2.7.6-1-2.5-2.6-1 .6-2.7L3 12l2.3-1.8-.6-2.7 2.6-1 1-2.5 2.7.6z`,eye:`M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7zM12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z`,"eye-off":`M4 4l16 16M9.5 9.6A3 3 0 0 0 12 15c.8 0 1.5-.3 2.1-.8M6.6 6.7C3.9 8.3 2 12 2 12s4 7 10 7c1.9 0 3.5-.5 4.9-1.2M14.1 5.4C13.4 5.1 12.7 5 12 5`,share:`M8 12a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 6a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 18a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM7.8 10.8l8.4-3.6M7.8 13.2l8.4 3.6`,send:`M21 3L3 10l7 3 3 7z`,paperclip:`M20 11l-8.5 8.5a5 5 0 0 1-7-7L13 4a3.5 3.5 0 0 1 5 5l-8.5 8.5a2 2 0 0 1-3-3L15 6`,video:`M3 7h11v10H3zM14 11l6-3v8l-6-3`,music:`M9 18V6l10-2v12M9 18a2.5 2.5 0 1 1-2.5-2.5H9M19 16a2.5 2.5 0 1 1-2.5-2.5H19`,mic:`M12 3a3 3 0 0 1 3 3v5a3 3 0 0 1-6 0V6a3 3 0 0 1 3-3zM5 11a7 7 0 0 0 14 0M12 18v3`,headphones:`M4 15v-3a8 8 0 1 1 16 0v3M4 15h3v5H5a1 1 0 0 1-1-1zM20 15h-3v5h2a1 1 0 0 0 1-1z`,book:`M5 4h14v16H7a2 2 0 0 1-2-2zM7 4v14h12`,bookmark:`M7 4h10v16l-5-4-5 4z`,folder:`M4 6h5l2 2h9v10H4z`,cloud:`M7 18a4 4 0 0 1 .5-8 5.5 5.5 0 0 1 10.4 1.5A3.5 3.5 0 0 1 17.5 18z`,database:`M12 3c4.4 0 8 1.3 8 3s-3.6 3-8 3-8-1.3-8-3 3.6-3 8-3zM4 6v12c0 1.7 3.6 3 8 3s8-1.3 8-3V6M4 12c0 1.7 3.6 3 8 3s8-1.3 8-3`,server:`M4 4h16v6H4zM4 14h16v6H4zM8 7h.01M8 17h.01`,code:`M9 8l-5 4 5 4M15 8l5 4-5 4`,terminal:`M4 5h16v14H4zM8 10l3 2-3 2M13 14h4`,wifi:`M5 12a10 10 0 0 1 14 0M8 15a6 6 0 0 1 8 0M12 19h.01`,battery:`M3 8h15v8H3zM21 11v2`,printer:`M7 8V4h10v4M7 16H4V8h16v8h-3M7 13h10v7H7z`,gift:`M4 10h16v10H4zM3 6h18v4H3zM12 6v14M12 6c-2 0-4-1-4-2.5S9 2 10 3s2 3 2 3zM12 6c2 0 4-1 4-2.5S15 2 14 3s-2 3-2 3z`,key:`M15 4a5 5 0 1 0-4.6 7L9 12.4V15H6.5L4 17.5V20h4l7-7A5 5 0 0 0 15 4z`,compass:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM15 9l-2 5-5 2 2-5z`,flag:`M5 21V4h13l-2 4 2 4H5`,award:`M12 4a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM9 13l-1 7 4-2 4 2-1-7`,chart:`M4 20V4M4 20h16M8 16v-5M12 16V8M16 16v-8`,pie:`M12 3a9 9 0 1 0 9 9h-9z`,trending:`M3 17l6-6 4 4 8-8M15 7h6v6`,dollar:`M12 3v18M16 7.5C16 6 14.2 5 12 5S8 6 8 7.5 9.5 10 12 10.5s4 1.5 4 3-1.8 2.5-4 2.5-4-1-4-2.5`,percent:`M5 19L19 5M7.5 5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM16.5 14a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5z`,truck:`M3 6h11v9H3zM14 9h4l3 3v3h-7zM7.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM17.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3z`,package:`M12 3l8 4v10l-8 4-8-4V7zM4 7l8 4 8-4M12 11v10`,store:`M4 9h16v11H4zM4 9l1.5-5h13L20 9M9 20v-6h6v6`,building:`M5 21V4h9v17M14 9h5v12M8 8h3M8 12h3M8 16h3M17 12h.01M17 16h.01`,users:`M9 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM2 20c0-3.3 3.1-5 7-5s7 1.7 7 5M17 5a4 4 0 0 1 0 7.9M22 20c0-2.6-1.6-4.2-4-4.8`,"thumbs-up":`M7 21V10h3l3-6a2 2 0 0 1 2 2v4h4l-2 11z`,smile:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9 10h.01M15 10h.01M8.5 14.5a5 5 0 0 0 7 0`,help:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9.5 9.5a2.5 2.5 0 1 1 3.5 2.3c-.6.3-1 .9-1 1.7M12 17h.01`,checkbox:`M4 4h16v16H4zM8 12l3 3 5-5`,list:`M8 6h13M8 12h13M8 18h13M3.5 6h.01M3.5 12h.01M3.5 18h.01`,grid:`M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z`,apps:`M4.5 4.5h2v2h-2zM11 4.5h2v2h-2zM17.5 4.5h2v2h-2zM4.5 11h2v2h-2zM11 11h2v2h-2zM17.5 11h2v2h-2zM4.5 17.5h2v2h-2zM11 17.5h2v2h-2zM17.5 17.5h2v2h-2z`,layers:`M12 3l9 5-9 5-9-5zM3 13l9 5 9-5`,zap:`M13 3L5 14h6l-1 7 8-11h-6z`,flame:`M12 21a6 6 0 0 0 6-6c0-4-4-6-4-10 0 0-3 1.5-3 5 0 1.5-1 2-1.5 1.5C8 10 7.5 9 7.5 9A7.5 7.5 0 0 0 6 15a6 6 0 0 0 6 6z`,droplet:`M12 3s6 6.4 6 10.5a6 6 0 0 1-12 0C6 9.4 12 3 12 3z`,leaf:`M4 20c0-8 6-14 16-14 0 10-6 14-12 14H4zM8 16c2-4 5-6 8-7`};function xi({name:e=`star`,paths:t,fill:n=!1,size:r=24,stroke:i=2,color:a=``,href:o=``,target:s=``,label:c=``,style:l,nodeRef:u,inert:d}){let f=Array.isArray(t)?t.filter(e=>typeof e==`string`&&e.trim()):[],p=n&&f.length>0,m=f.length?f:[bi[e]??bi.star],h=Math.min(Math.max(Number(r)||24,8),240),g=a===`accent`?`var(--page-accent, currentColor)`:a||`currentColor`,_=(0,W.jsx)(`svg`,{...K(`glyph`),viewBox:`0 0 24 24`,width:h,height:h,fill:p?g:`none`,stroke:p?`none`:g,strokeWidth:p?void 0:Math.min(Math.max(Number(i)||2,.5),4),strokeLinecap:p?void 0:`round`,strokeLinejoin:p?void 0:`round`,role:c?`img`:void 0,"aria-label":c||void 0,"aria-hidden":c?void 0:`true`,style:{display:`block`},children:m.map((e,t)=>(0,W.jsx)(`path`,{d:e},t))}),v={display:`inline-flex`,lineHeight:0,...z(l)};return o?(0,W.jsx)(`a`,{ref:u,href:o,onClick:d?e=>e.preventDefault():void 0,target:s||void 0,rel:s===`_blank`?`noopener noreferrer`:void 0,style:{...v,color:`inherit`},children:_}):(0,W.jsx)(`span`,{ref:u,style:v,children:_})}function Si(e,t={},n=0){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],i=e=>e==null?``:qn(e),a=Math.max(0,Number(n)||0),o=[];for(let e of r){let n=e.data??e,r=Gn(n,t.imageField),s=(Array.isArray(r)?r:[r]).map(e=>e&&typeof e==`object`?e.url??e.src??``:e).filter(e=>typeof e==`string`&&e.trim()),c=t.nameField?i(Gn(n,t.nameField)):i(n.name),l=t.hrefField?i(Gn(n,t.hrefField)):``;for(let e of s)if(o.push({src:e,name:c,alt:c,href:l}),a&&o.length>=a)return o}return o}function Ci({images:e=[],source:t=``,entry:n=``,imageField:r=``,nameField:i=``,hrefField:a=``,limit:o=0,emptyText:s=``,columns:c=3,gap:u=8,showNames:d=!1,lightbox:f=!0,style:p,nodeRef:m,inert:h}){let{tenant:g,apiUrl:_,revision:v}=(0,l.useContext)(G),y=(0,l.useContext)(Nn)?.[t],[b,x]=(0,l.useState)(null),[S,C]=(0,l.useState)(()=>new Set);(0,l.useEffect)(()=>{if(!t||y)return;let e=!0;return fetch(`${_}/dynamic/${encodeURIComponent(t)}`,{headers:g?{"x-tenant":g}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&x(n)}).catch(()=>e&&x([])),()=>{e=!1}},[v,t,g,_,y]);let w=y??b??[],T=n?w.filter(e=>e?.id===n||e?.data?.slug===n||e?.slug===n):w,E=Math.max(0,Number(o)||0),D=t?(()=>{let e=Si(T,{imageField:r,nameField:i,hrefField:a},0).filter(e=>!S.has(e.src));return E?e.slice(0,E):e})():null,O=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],k=D??O,A=!!t&&!y&&b===null,j=Math.max(0,Number(u)||0),M=h?e=>e.preventDefault():void 0,[N,P]=(0,l.useState)(null),F=f&&!h&&N!==null&&k[N];(0,l.useEffect)(()=>{if(!F)return;let e=e=>{e.key===`Escape`&&P(null),e.key===`ArrowRight`&&P(e=>(e+1)%k.length),e.key===`ArrowLeft`&&P(e=>(e-1+k.length)%k.length)};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[F,k.length]);let I=e=>{if(typeof e.name==`string`&&e.name.trim())return e.name;if(typeof e.alt==`string`&&e.alt.trim())return e.alt;try{let t=String(e.src).split(`?`)[0].split(`/`).pop();return decodeURIComponent(t??``)}catch{return``}};return(0,W.jsxs)(`div`,{ref:m,style:{columnCount:Math.min(Math.max(Number(c)||3,1),8),columnGap:j,width:`100%`,...z(p)},children:[k.map((e,n)=>{let r=(0,W.jsxs)(`span`,{style:{position:`relative`,display:`block`,borderRadius:`inherit`,overflow:`hidden`},children:[(0,W.jsx)(`img`,{...K(`image`),src:e.src,alt:e.alt??``,onError:t?()=>C(t=>new Set(t).add(e.src)):void 0,style:{width:`100%`,display:`block`,borderRadius:`inherit`}}),d&&I(e)&&(0,W.jsx)(`span`,{...K(`caption`),style:{position:`absolute`,insetInline:0,bottom:0,padding:`14px 10px 8px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.65))`,color:`#fff`,fontSize:12,lineHeight:1.3,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`},children:I(e)})]}),i=e.href?(0,W.jsx)(`a`,{href:e.href,onClick:M,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`,borderRadius:`inherit`},children:r}):f&&!h?(0,W.jsx)(`span`,{role:`button`,tabIndex:0,onClick:()=>P(n),onKeyDown:e=>(e.key===`Enter`||e.key===` `)&&P(n),style:{display:`block`,borderRadius:`inherit`,cursor:`zoom-in`},children:r}):r;return(0,W.jsx)(`div`,{...K(`tile`),style:{breakInside:`avoid`,marginBottom:j,borderRadius:`inherit`,overflow:`hidden`},children:i},n)}),!k.length&&!A&&(0,W.jsx)(`div`,{...K(`empty`),style:{padding:`24px 12px`,fontSize:13,opacity:.55,textAlign:`center`,columnSpan:`all`},children:t?s||`No images yet`:`Pick images in Settings to fill the gallery`}),F&&(0,W.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,onClick:()=>P(null),style:{position:`fixed`,inset:0,zIndex:1400,background:`rgba(0, 0, 0, 0.86)`,display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,padding:24},children:[(0,W.jsx)(`img`,{src:k[N].src,alt:k[N].alt??``,onClick:e=>e.stopPropagation(),style:{maxWidth:`92vw`,maxHeight:`84vh`,borderRadius:8,boxShadow:`0 12px 48px rgba(0,0,0,0.5)`}}),I(k[N])&&(0,W.jsx)(`div`,{style:{color:`#fff`,fontSize:14,marginTop:12,opacity:.85},children:I(k[N])}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:()=>P(null),style:{position:`absolute`,top:16,right:20,background:`transparent`,border:0,color:`#fff`,fontSize:28,lineHeight:1,cursor:`pointer`},children:`×`}),k.length>1&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`button`,{type:`button`,"aria-label":`Previous`,onClick:e=>{e.stopPropagation(),P(e=>(e-1+k.length)%k.length)},style:{position:`absolute`,left:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`‹`}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Next`,onClick:e=>{e.stopPropagation(),P(e=>(e+1)%k.length)},style:{position:`absolute`,right:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`›`})]})]})]})}var wi=e=>{let t=Array.isArray(e)?e[0]:e;return t&&typeof t==`object`?String(t.url??t.href??t.link??``):t==null?``:String(t)},Ti=e=>String(e??``).trim().toLowerCase().split(/[-_]/)[0];function Ei(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=Ti(t.language),i=n.filter(e=>!t.langField||!r||Ti(qn(e.data?.[t.langField]))===r),a=e=>String(e.data?.slug??e.slug??``),o=e=>{if(!t.parentField)return``;let n=e.data?.[t.parentField],r=Array.isArray(n)?n[0]:n;return r&&typeof r==`object`?String(r.id??r.slug??``):r==null?``:String(r)},s=e=>{let n=Number(t.orderField?qn(e.data?.[t.orderField]):NaN);return Number.isFinite(n)?n:1/0},c=(e,t)=>s(e)-s(t)||a(e).localeCompare(a(t),void 0,{numeric:!0}),l=new Map;for(let e of i)l.set(String(e.id),e),a(e)&&l.set(a(e),e);let u=new Map;for(let e of i){let t=l.get(o(e)),n=t&&t!==e?t.id:``;u.has(n)||u.set(n,[]),u.get(n).push(e)}let d=[];if(t.root===`parent`){let e=t.rootEntry?l.get(String(t.rootEntry)):null;d=e?u.get(e.id)??[]:[]}else{let e=e=>!t.groupField||qn(e.data?.[t.groupField])===String(t.groupValue??``);d=i.filter(t=>{if(!e(t))return!1;let n=l.get(o(t));return!n||n===t||!e(n)})}let f=Math.max(0,Number(t.depth)||0),p=new Set,m=(e,n)=>{if(p.has(e.id))return null;p.add(e.id);let r=f===0||n<f?u.get(e.id)??[]:[];return{key:e.id,label:qn(e.data?.[t.labelField||`name`])||qn(e.data?.name)||`Untitled`,href:_t(t.hrefField?wi(e.data?.[t.hrefField]):``),icon:t.iconField?qn(e.data?.[t.iconField]).trim():``,children:[...r].sort(c).map(e=>m(e,n+1)).filter(Boolean)}};return[...d].sort(c).map(e=>m(e,1)).filter(Boolean)}var q=(e,t)=>{if(!e||!t||!e.startsWith(`/`))return!1;let n=e=>e.length>1?e.replace(/\/+$/,``):e,r=n(e.split(/[?#]/)[0]),i=n(t);return r===i||r.length>1&&i.endsWith(r)&&i.charAt(i.length-r.length-1)===`/`},Di=rr({display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:8,padding:`10px 16px`,color:`inherit`,textDecoration:`none`});function Oi({source:e=``,labelField:t=``,hrefField:n=``,parentField:r=``,orderField:i=``,langField:a=``,root:o=`group`,groupField:s=``,groupValue:c=``,rootEntry:u=``,depth:d=0,expand:f=`current`,toggleOnClick:p=!0,indent:m=16,lines:h=`none`,lineColor:g=``,iconField:_=``,branchIcon:v=``,leafIcon:y=``,toggleIcon:b=`caret`,toggleSize:x=16,dividers:S=`none`,dividerColor:C=``,dividerWidth:w=1,linkColor:T=``,hoverBg:E=``,hoverColor:D=``,currentBg:O=``,currentColor:k=``,placeholder:A=``,style:j,nodeRef:M}){let{tenant:N,apiUrl:P,revision:F,locale:I}=(0,l.useContext)(G),L=(0,l.useContext)(Nn)?.[e],R=Number(m)||0,ee=(h===`solid`||h===`dotted`)&&R>=8,te=ee?`1px ${h} ${g||`currentColor`}`:``,B=g?1:.5,V=e=>16+(e-2)*R+6,H=`wb-mt-${(0,l.useId)().replace(/[^a-zA-Z0-9_-]/g,``)}`,ne=[`solid`,`dashed`,`dotted`].includes(S)?`${Math.min(Math.max(Number(w)||1,1),8)}px ${S} ${C||`rgba(148, 163, 184, 0.35)`}`:``,re=[ne&&`.${H} [data-wb-part~="link"]{border-top:${ne};}.${H} > [data-wb-part~="item"]:first-of-type > [data-wb-part~="link"]{border-top:0;}`,T&&`.${H} a{color:${T} !important;}`,(E||D)&&`.${H} a:hover{${E?`background-color:${E} !important;`:``}${D?`color:${D} !important;`:``}}`,(O||k)&&`.${H} a[aria-current="page"]{${O?`background-color:${O} !important;`:``}${k?`color:${k} !important;`:``}}`].filter(Boolean).join(``),ie=e=>{let t=e.icon||(e.children.length>0?v:y);return t?/^(https?:)?\/\/|^\//.test(t)?(0,W.jsx)(`img`,{...K(`icon`),src:t,alt:``,style:{width:18,height:18,objectFit:`contain`,flexShrink:0}}):bi[t]?(0,W.jsx)(`svg`,{...K(`icon`),viewBox:`0 0 24 24`,width:`18`,height:`18`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{flexShrink:0,opacity:.8},children:(0,W.jsx)(`path`,{d:bi[t]})}):null:null},ae=Math.min(Math.max(Number(x)||16,8),40),oe=e=>b===`plus`?(0,W.jsx)(`path`,{d:e?bi.minus:bi.plus}):b===`chevron`?(0,W.jsx)(`path`,{d:bi[`chevron-right`]}):null,[se,ce]=(0,l.useState)(null),[le,ue]=(0,l.useState)(``),[de,fe]=(0,l.useState)({});(0,l.useEffect)(()=>{ue(window.location.pathname)},[]),(0,l.useEffect)(()=>{if(!e||L)return;let t=!0,n=new URLSearchParams({all:`1`});return I&&n.set(`locale`,I),fetch(`${P}/dynamic/${encodeURIComponent(e)}?${n}`,{headers:N?{"x-tenant":N}:{}}).then(e=>e.json()).then(e=>{let n=Array.isArray(e?.payload)?e.payload:Array.isArray(e?.payload?.data)?e.payload.data:[];t&&ce(n)}).catch(()=>t&&ce([])),()=>{t=!1}},[F,e,N,P,I,L]);let pe=(0,l.useMemo)(()=>Ei(L??se??[],{labelField:t,hrefField:n,parentField:r,orderField:i,langField:a,language:I,root:o,groupField:s,groupValue:c,rootEntry:u,depth:d,iconField:_}),[L,se,t,n,r,i,a,I,o,s,c,u,d,_]),me=(0,l.useMemo)(()=>{let e=new Set,t=(n,r)=>n.some(n=>q(n.href,le)?([...r,n.key].forEach(t=>e.add(t)),!0):t(n.children,[...r,n.key]));return t(pe,[]),e},[pe,le]),he=e=>e.key in de?de[e.key]:f===`all`||f===`current`&&me.has(e.key),ge=e=>fe(t=>({...t,[e.key]:!he(e)})),_e=(e,t)=>({position:`absolute`,left:V(e),pointerEvents:`none`,opacity:B,borderLeft:te,...t}),ve=(e,t,n)=>!ee||e<2?null:(0,W.jsxs)(W.Fragment,{children:[t.map((e,t)=>e?(0,W.jsx)(`span`,{...K(`line`),"aria-hidden":!0,style:_e(t+2,{top:0,bottom:0})},t):null),(0,W.jsx)(`span`,{...K(`line`),"aria-hidden":!0,style:_e(e,n?{top:0,height:`50%`}:{top:0,bottom:0})}),(0,W.jsx)(`span`,{...K(`line`),"aria-hidden":!0,style:{position:`absolute`,left:V(e),top:`50%`,width:Math.max(4,R-8),pointerEvents:`none`,opacity:B,borderTop:te}})]}),ye=(e,t,n=[])=>e.map((r,i)=>{let a=r.children.length>0,o=a&&he(r),s=q(r.href,le),c=ee&&t>1,l=i===e.length-1;return(0,W.jsxs)(`div`,{...K(`item`,o&&`item-open`),children:[(0,W.jsxs)(`a`,{...K(`link`,s&&`link-current`),href:r.href||`#`,"aria-current":s?`page`:void 0,"aria-expanded":a?o:void 0,onClick:a&&(p||!r.href)?e=>{e.preventDefault(),ge(r)}:void 0,style:{...Di,paddingLeft:16+(t-1)*R,fontWeight:s?600:void 0,...c?{position:`relative`}:null},children:[ve(t,n,l),(0,W.jsxs)(`span`,{style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[ie(r),(0,W.jsx)(`span`,{...K(`label`),children:r.label})]}),a?(0,W.jsx)(`span`,{role:`button`,tabIndex:-1,"aria-label":o?`Collapse`:`Expand`,onClick:e=>{e.preventDefault(),e.stopPropagation(),ge(r)},style:{flexShrink:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,margin:`-8px -8px -8px 0`,padding:8,cursor:`pointer`},children:b===`plus`||b===`chevron`?(0,W.jsx)(`svg`,{...K(`toggle`),viewBox:`0 0 24 24`,width:ae+2,height:ae+2,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{transition:`transform .2s`,transform:b===`chevron`&&o?`rotate(90deg)`:`none`},children:oe(o)}):(0,W.jsx)(`svg`,{...K(`toggle`),viewBox:`0 0 24 24`,width:ae,height:ae,"aria-hidden":!0,style:{transition:`transform .2s`,transform:o?`rotate(180deg)`:`none`},children:(0,W.jsx)(`path`,{d:`M5 8.5h14L12 17z`,fill:`currentColor`})})}):null]}),o?(0,W.jsx)(`div`,{...K(`children`),children:ye(r.children,t+1,t>1?[...n,!l]:n)}):null]},r.key)});return(0,W.jsxs)(`nav`,{ref:M,"aria-label":`Menu`,className:re?H:void 0,style:{...z(j)},children:[re?(0,W.jsx)(`style`,{children:re}):null,pe.length?ye(pe,1):A?(0,W.jsx)(`div`,{...K(`empty`),style:{padding:`10px 16px`,opacity:.6,fontSize:14},children:A}):null]})}var ki={color:`inherit`,textDecoration:`none`,fontSize:14,opacity:.85},Ai=rr({background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.25)`,boxShadow:`0 16px 40px rgba(15, 23, 42, 0.16)`,zIndex:60});function ji(e,t={},n=`dropdown`){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],i=e=>Array.isArray(e)?e[0]:e,a=e=>e==null?``:qn(e),o=r.map(e=>{let n=e.data??{},r=t.parentField?i(n[t.parentField]):null;return{key:e.id,parent:(r&&typeof r==`object`?r.id:r)||null,label:a(n[t.labelField||`name`])||a(n.name)||`Untitled`,href:t.hrefField?a(n[t.hrefField]):``,image:t.imageField&&i(n[t.imageField])||``,desc:t.descField?a(n[t.descField]):``}}),s=new Map(o.map(e=>[e.key,e])),c=e=>{let t=new Set,n=e;for(;n.parent&&s.has(n.parent)&&!t.has(n.key);)t.add(n.key),n=s.get(n.parent);return n},l=[],u=new Map;for(let e of o){if(c(e)!==e)continue;let t={key:e.key,label:e.label,href:e.href,image:e.image,children:[]};u.set(e.key,t),l.push(t)}for(let e of o){let t=c(e);t!==e&&u.get(t.key)?.children.push({key:e.key,label:e.label,href:e.href,image:e.image,desc:e.desc})}return l.map(e=>({...e,type:e.children.length?n:`link`}))}function Mi({brand:e,logo:t,brandHref:n,brandTarget:r,links:i=[],style:a,nodeRef:o,menu:s=`auto`,breakpoint:c=768,source:u=``,labelField:d=``,hrefField:f=``,imageField:p=``,descField:m=``,parentField:h=``,submenu:g=`dropdown`}){let[_,v]=(0,l.useState)(null),[y,b]=(0,l.useState)(!1),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(null),{tenant:T,apiUrl:E,revision:D,locale:O}=(0,l.useContext)(G),k=Xe(O),A=(0,l.useId)(),j=(0,l.useContext)(Nn)?.[u],[M,N]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!u||j)return;let e=!0;return fetch(`${E}/dynamic/${encodeURIComponent(u)}`,{headers:T?{"x-tenant":T}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&N(n)}).catch(()=>e&&N([])),()=>{e=!1}},[D,u,T,E,j]),(0,l.useEffect)(()=>{if(!_)return;let e=new ResizeObserver(()=>b(_.offsetWidth<c));return e.observe(_),()=>e.disconnect()},[_,c]);let P=u?ji(j??M??[],{labelField:d,hrefField:f,imageField:p,descField:m,parentField:h},g):i,F=s===`hamburger`||s===`auto`&&y,I=(e,t,n=!1)=>{let r=e.image?(0,W.jsx)(`img`,{...K(`sublink-image`),src:e.image,alt:``,style:n?{width:`100%`,aspectRatio:`16 / 9`,objectFit:`cover`,borderRadius:6,display:`block`,marginBottom:8}:{width:22,height:22,objectFit:`cover`,borderRadius:4,display:`block`,flexShrink:0}}):null;return(0,W.jsxs)(`a`,{...K(`sublink`,n&&`sublink-card`),href:e.href||`#`,style:{...ki,display:n?`block`:`flex`,alignItems:n?void 0:`center`,gap:n?void 0:10,...t},children:[r,(0,W.jsxs)(`span`,{...K(`sublink-label`),style:{display:`block`,minWidth:0},children:[e.label,e.desc&&(0,W.jsx)(`span`,{...K(`sublink-desc`),style:{display:`block`,fontSize:12,opacity:.6,marginTop:2},children:e.desc})]})]},e.key)};return(0,W.jsxs)(`nav`,{ref:e=>{v(e),o&&o(e)},style:{display:`flex`,alignItems:`center`,gap:24,flexWrap:`wrap`,padding:`14px 24px`,width:`100%`,position:`relative`,...z(a)},children:[(t||e)&&(()=>{let i=(0,W.jsxs)(W.Fragment,{children:[t&&(0,W.jsx)(`img`,{...K(`logo`),src:t,alt:e||`Logo`,style:{height:28,display:`block`}}),e&&(0,W.jsx)(`span`,{...K(`brand-name`),style:{fontWeight:700,fontSize:18,fontFamily:`var(--page-heading-font, inherit)`},children:e})]}),a={display:`flex`,alignItems:`center`,gap:10,color:`inherit`,textDecoration:`none`};return n?(0,W.jsx)(`a`,{...K(`brand`),href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:a,children:i}):(0,W.jsx)(`div`,{...K(`brand`),style:a,children:i})})(),(0,W.jsx)(`div`,{style:{flexGrow:1}}),F?(0,W.jsx)(`button`,{type:`button`,...K(`menu-button`),"aria-label":k(x?`closeMenu`:`openMenu`),"aria-expanded":x,"aria-controls":x?`${A}-menu`:void 0,onClick:()=>S(!x),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4},children:x?`✕`:`☰`}):(0,W.jsx)(`div`,{...K(`links`),style:{display:`flex`,gap:20,alignItems:`center`,flexWrap:`wrap`},children:P.map(e=>{let t=e.children??[];if(!t.length)return(0,W.jsx)(`a`,{...K(`link`),href:e.href||`#`,style:ki,children:e.label},e.key);let n=e.type===`mega`,r=`${A}-${e.key}`;return(0,W.jsxs)(`span`,{style:{position:n?`static`:`relative`,display:`inline-flex`},onMouseEnter:()=>w(e.key),onMouseLeave:()=>w(null),onFocus:t=>{t.currentTarget.contains(t.relatedTarget)||w(e.key)},onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||w(null)},onKeyDown:t=>{let n=t.currentTarget;t.key===`Escape`&&C===e.key?(t.stopPropagation(),w(null),n.querySelector(`a`)?.focus()):t.key===`ArrowDown`&&C!==e.key&&(t.preventDefault(),w(e.key),setTimeout(()=>n.querySelectorAll(`a`)[1]?.focus(),0))},children:[(0,W.jsxs)(`a`,{...K(`link`),href:e.href||`#`,"aria-haspopup":`true`,"aria-expanded":C===e.key,"aria-controls":C===e.key?r:void 0,style:{...ki,cursor:`pointer`},children:[e.label,` `,(0,W.jsx)(`span`,{...K(`chevron`),"aria-hidden":`true`,style:{fontSize:9,opacity:.6},children:`▼`})]}),C===e.key&&(n?(0,W.jsx)(`div`,{id:r,...K(`mega-panel`),style:{...Ai,position:`absolute`,left:0,right:0,top:`100%`,padding:24,display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(170px, 1fr))`,gap:16},children:t.map(e=>I(e,{padding:8,borderRadius:8},!0))}):(0,W.jsx)(`div`,{id:r,...K(`dropdown-panel`),style:{...Ai,position:`absolute`,top:`100%`,left:0,minWidth:190,borderRadius:8,padding:8,display:`flex`,flexDirection:`column`},children:t.map(e=>I(e,{padding:`8px 12px`,borderRadius:6}))}))]},e.key)})}),F&&x&&(0,W.jsx)(`div`,{id:`${A}-menu`,...K(`mobile-menu`),style:{flexBasis:`100%`,width:`100%`,display:`flex`,flexDirection:`column`,paddingTop:10},children:P.map(e=>(0,W.jsxs)(l.Fragment,{children:[(0,W.jsx)(`a`,{...K(`mobile-link`),href:e.href||`#`,style:{...ki,padding:`10px 4px`,fontWeight:(e.children??[]).length?600:400,opacity:1},children:e.label}),(e.children??[]).map(e=>I(e,{padding:`8px 4px 8px 22px`}))]},e.key))})]})}function Ni({tabs:e=[],linked:t,style:n,nodeRef:r}){let[i,a]=(0,l.useState)(0),{locale:o}=(0,l.useContext)(G),s=(0,l.useId)(),c=(0,l.useRef)(null),u=e.length?Math.min(i,e.length-1):0;if(!e.length)return null;let d=Xe(o),f=t=>{let n=e.length-1,r={ArrowRight:(u+1)%e.length,ArrowLeft:(u-1+e.length)%e.length,Home:0,End:n}[t.key];r!==void 0&&(t.preventDefault(),a(r),c.current?.querySelectorAll(`[role="tab"]`)[r]?.focus())};return(0,W.jsxs)(`div`,{ref:r,style:{width:`100%`,...z(n)},children:[(0,W.jsx)(`div`,{ref:c,role:`tablist`,...K(`tab-list`),onKeyDown:f,style:{display:`flex`,gap:4,borderBottom:`1px solid rgba(148, 163, 184, 0.35)`},children:e.map((e,t)=>(0,W.jsx)(`button`,{...K(`tab`,t===u&&`tab-active`),type:`button`,role:`tab`,id:`${s}-tab-${e.key}`,"aria-selected":t===u,"aria-controls":`${s}-panel-${e.key}`,tabIndex:t===u?0:-1,onClick:()=>a(t),style:{background:`transparent`,border:0,padding:`10px 16px`,fontSize:14,fontFamily:`inherit`,color:`inherit`,cursor:`pointer`,opacity:t===u?1:.6,fontWeight:t===u?600:500,boxShadow:t===u?`inset 0 -2px 0 var(--page-accent, #111827)`:`none`},children:e.label||d(`tab`,{n:t+1})},e.key))}),e.map((e,n)=>(0,W.jsx)(`div`,{...K(`panel`),role:`tabpanel`,id:`${s}-panel-${e.key}`,"aria-labelledby":`${s}-tab-${e.key}`,tabIndex:0,hidden:n!==u,style:{display:n===u?`flex`:`none`,flexDirection:`column`},children:t?.[e.key]??null},e.key))]})}function Pi({items:e=[],linked:t,multiple:n=!1,icon:r=``,padX:i,padY:a,headerBg:o,headerColor:s,openBg:c,openColor:u,borderColor:d,style:f,nodeRef:p}){let[m,h]=(0,l.useState)(()=>new Set(e.length?[e[0].key]:[])),{locale:g}=(0,l.useContext)(G),_=(0,l.useId)();if(!e.length)return null;let v=Xe(g),y=(e,t)=>typeof e==`string`&&e?e:t,b=(e,t)=>{let n=Number(e);return e===``||e==null||!Number.isFinite(n)?t:n},x=bi[r],S=e=>h(t=>{let r=new Set(n?t:[]);return t.has(e)?r.delete(e):r.add(e),r});return(0,W.jsx)(`div`,{ref:p,style:{width:`100%`,...z(f)},children:e.map((n,r)=>{let l=m.has(n.key);return(0,W.jsxs)(`div`,{...K(`item`,l&&`item-open`),style:{borderBottom:r<e.length-1?`1px solid ${y(d,`rgba(148, 163, 184, 0.35)`)}`:`none`},children:[(0,W.jsxs)(`button`,{type:`button`,...K(`header`,l&&`header-open`),id:`${_}-h-${n.key}`,"aria-expanded":l,"aria-controls":`${_}-b-${n.key}`,onClick:()=>S(n.key),style:{width:`100%`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:12,background:l?y(c,y(o,`transparent`)):y(o,`transparent`),border:0,padding:`${b(a,14)}px ${b(i,4)}px`,fontSize:15,fontWeight:600,fontFamily:`inherit`,color:l?y(u,y(s,`inherit`)):y(s,`inherit`),textAlign:`left`,cursor:`pointer`,transition:`background 180ms, color 180ms`},children:[(0,W.jsxs)(`span`,{...K(`title`),style:{display:`flex`,alignItems:`center`,gap:10,minWidth:0},children:[x?(0,W.jsx)(`svg`,{...K(`icon`),viewBox:`0 0 24 24`,width:16,height:16,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,style:{flexShrink:0},children:(0,W.jsx)(`path`,{d:x})}):null,n.title||v(`item`,{n:r+1})]}),(0,W.jsx)(`span`,{"aria-hidden":`true`,...K(`chevron`),style:{fontSize:12,opacity:.6,transform:l?`rotate(180deg)`:`none`,transition:`transform 180ms`},children:`▼`})]}),(0,W.jsx)(`div`,{...K(`body`),id:`${_}-b-${n.key}`,role:`region`,"aria-labelledby":`${_}-h-${n.key}`,hidden:!l,style:{display:l?`flex`:`none`,flexDirection:`column`},children:t?.[n.key]??null})]},n.key)})})}var Fi={display:`flex`,flexDirection:`column`,gap:`12px`},Ii={fontSize:`14px`,fontWeight:500,color:`var(--page-text, #111827)`},Li=rr({padding:`10px 12px`,border:`1px solid var(--page-border, #d1d5db)`,borderRadius:`6px`,fontSize:`14px`,fontFamily:`inherit`,width:`100%`,boxSizing:`border-box`,backgroundColor:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`}),Ri={display:`flex`,alignItems:`center`,gap:`8px`,fontSize:`14px`,color:`var(--page-text, #111827)`},zi=e=>e?{readOnly:!0,tabIndex:-1,onMouseDown:e=>e.preventDefault()}:{};function Bi(e,t){if(!e)return!0;let n=t[e.field],r=n==null||n===``?``:String(n),i=e.value??``;switch(e.op){case`eq`:return r===i;case`neq`:return r!==i;case`contains`:return r.toLowerCase().includes(i.toLowerCase());case`gt`:return Number(r)>Number(i);case`lt`:return Number(r)<Number(i);case`empty`:return r===``;case`notEmpty`:return r!==``;default:return!1}}var Vi={display:`flex`,flexDirection:`column`,gap:6},Hi=`#dc2626`,Ui={fontSize:13,fontWeight:500,color:Hi},Wi=rr({font:`inherit`,fontSize:15,padding:`10px 12px`,borderRadius:8,border:`1px solid rgba(148, 163, 184, 0.55)`,background:`transparent`,color:`inherit`,width:`100%`,boxSizing:`border-box`});function Gi(e,t){let n=Array.isArray(e?.options)?e.options:[];if(!e?.parentField)return n;let r=t?.[e.parentField];return r?n.filter(e=>typeof e==`string`?!1:!e.parent||e.parent===r):[]}var Ki=`g-recaptcha-response`,qi=e=>e?.type===`recaptcha`?Ki:e?.name,Ji=[[/^(full_?name|name|ad_?soyad|adsoyad|isim)$/,`name`],[/^(first_?name|given_?name|ad|adi|adiniz)$/,`given-name`],[/^(last_?name|family_?name|surname|soyad|soyadi|soyadiniz)$/,`family-name`],[/^(e_?mail|e_?posta|eposta|mail)$/,`email`],[/^(phone|tel|telephone|mobile|gsm|telefon|cep)$/,`tel`],[/^(company|organization|organisation|firma|sirket|kurum)$/,`organization`],[/^(address|street|adres|sokak)$/,`street-address`],[/^(city|town|sehir|il)$/,`address-level2`],[/^(district|ilce)$/,`address-level3`],[/^(zip|zip_?code|postal_?code|postcode|posta_?kodu)$/,`postal-code`],[/^(country|ulke)$/,`country-name`],[/^(website|web|url|site)$/,`url`]];function Yi(e){if(typeof e.autocomplete==`string`&&e.autocomplete)return e.autocomplete;let t={email:`email`,phone:`tel`,link:`url`}[e.type];if(t)return t;let n=String(e.name??``).toLowerCase();return Ji.find(([e])=>e.test(n))?.[1]}function Xi({field:e,value:t,onChange:n,inert:r,values:i,error:a,idBase:o}){let s=Xe((0,l.useContext)(G).locale),c=`${o}-${e.name}`,u=e.help?`${c}-help`:null,d=a?`${c}-error`:null,f=(0,W.jsxs)(`label`,{...K(`label`),htmlFor:c,style:{...Ii,fontSize:14},children:[e.label,e.required?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,children:` *`}),(0,W.jsxs)(`span`,{style:Ze,children:[` (`,s(`required`),`)`]})]}):null]}),p=[u,d].filter(Boolean).join(` `)||void 0,m={id:c,"aria-invalid":a?!0:void 0,"aria-describedby":p},h={...K(`input`),...m,name:e.name,required:e.required||void 0,placeholder:e.placeholder||void 0,disabled:r||void 0,autoComplete:Yi(e),style:a?{...Wi,borderTopColor:Hi,borderRightColor:Hi,borderBottomColor:Hi,borderLeftColor:Hi}:Wi,value:t??``,onChange:t=>n(e.name,t.target.value)};return e.type===`display`?(0,W.jsx)(e.variant&&e.variant!==`p`?e.variant:`p`,{...K(`text`),style:{margin:0,color:e.color||`inherit`,fontSize:{h1:32,h2:26,h3:21,h4:18,h5:16,h6:14,p:15}[e.variant]??16,fontWeight:e.variant===`p`?400:700,lineHeight:1.35},children:e.label}):e.type===`image`?e.src?(0,W.jsx)(`img`,{...K(`image`),src:e.src,alt:e.label??``,style:{width:`100%`,borderRadius:8,display:`block`}}):null:e.type===`recaptcha`?(0,W.jsxs)(`div`,{...K(`field`),id:c,tabIndex:-1,style:Vi,children:[(0,W.jsx)(ta,{theme:e.captchaTheme,size:e.captchaSize,inert:r,onChange:e=>n(Ki,e)}),a&&(0,W.jsx)(`span`,{...K(`error`),id:d,style:Ui,children:a})]}):e.type===`video`?e.src?/youtube\.com|youtu\.be|vimeo\.com/i.test(e.src)?(0,W.jsx)(Kr,{url:e.src,style:{width:`100%`}}):(0,W.jsx)(`video`,{...K(`video`),src:e.src,controls:!0,style:{width:`100%`,borderRadius:8,display:`block`}}):null:(0,W.jsxs)(`div`,{...K(`field`),style:Vi,children:[f,e.type===`textarea`||e.multiline?(0,W.jsx)(`textarea`,{...h,...K(`textarea`),rows:4,style:{...Wi,resize:`vertical`}}):e.type===`select`?(0,W.jsxs)(`select`,{...h,...K(`select`),disabled:h.disabled||!!e.parentField&&!i?.[e.parentField],children:[(0,W.jsx)(`option`,{value:``,children:e.placeholder||`—`}),Gi(e,i).map((e,t)=>(0,W.jsx)(`option`,{value:typeof e==`string`?e:e.value,children:typeof e==`string`?e:e.label??e.value},t))]}):e.type===`checkbox`?(0,W.jsx)(`input`,{type:`checkbox`,...K(`checkbox`),...m,name:e.name,required:e.required||void 0,disabled:r||void 0,checked:!!t,onChange:t=>n(e.name,t.target.checked),style:{width:18,height:18}}):e.type===`upload`?(0,W.jsx)(`input`,{type:`file`,...K(`file`),...m,name:e.name,accept:e.accept||void 0,required:e.required||void 0,disabled:r||void 0,onChange:t=>n(e.name,t.target.files?.[0]?.name??``),style:{font:`inherit`,fontSize:14}}):(0,W.jsx)(`input`,{...h,type:{email:`email`,number:`number`,date:`date`,datetime:`datetime-local`,phone:`tel`,link:`url`}[e.type]??`text`}),e.help&&(0,W.jsx)(`span`,{...K(`help`),id:u,style:{fontSize:12,opacity:.65},children:e.help}),a&&(0,W.jsx)(`span`,{...K(`error`),id:d,style:Ui,children:a})]})}function Zi({style:e,action:t,method:n,name:r,enctype:i,formSlug:a,auto:o,submitLabel:s,nodeRef:c,inert:u,children:d,linked:f,show:p}){let{tenant:m,apiUrl:h,locale:g}=(0,l.useContext)(G),[_,v]=(0,l.useState)(`form`),[y,b]=(0,l.useState)(null),[x,S]=(0,l.useState)({}),[C,w]=(0,l.useState)(0),[T,E]=(0,l.useState)({}),[D,O]=(0,l.useState)(``),k=(0,l.useId)(),A=(0,l.useRef)(null),j=(0,l.useRef)(null),M=u?p||`form`:_,N=Xe(g);(0,l.useEffect)(()=>{if(!o||!a)return;let e=!0;return fetch(`${h||`/api`}/forms/${encodeURIComponent(a)}`,{headers:m?{"x-tenant":m}:{}}).then(e=>e.json()).then(t=>e&&b(t?.payload&&typeof t.payload==`object`?t.payload:null)).catch(()=>e&&b(null)),()=>{e=!1}},[o,a,m,h]);let P=[{section:null,fields:[]}];for(let e of Array.isArray(y?.fields)?y.fields:[])e.type===`section`?P.push({section:e,fields:[]}):P[P.length-1].fields.push(e);let F=P.filter(e=>e.section||e.fields.length),I=F.filter(e=>!e.section||Bi(e.section.condition,x)).map(e=>({...e,fields:e.fields.filter(e=>Bi(e.condition,x))})),L=F.length>1,R=Math.min(C,Math.max(0,I.length-1)),ee=L?I[R]?.fields??[]:I.flatMap(e=>e.fields),te=ee.filter(e=>{let t=x[qi(e)];return e.required&&(t==null||t===``||t===!1)}),B=R>=I.length-1,V=(e,t)=>{E(t=>{let n=e===`g-recaptcha-response`?(Array.isArray(y?.fields)?y.fields:[]).find(e=>e?.type===`recaptcha`)?.name:e;if(!n||!t[n])return t;let r={...t};return delete r[n],r}),S(n=>{let r={...n,[e]:t};for(let t of Array.isArray(y?.fields)?y.fields:[])t?.parentField===e&&delete r[t.name];return r})},H=()=>{let e={};for(let t of ee){if(t.type===`recaptcha`){t.required&&!x[`g-recaptcha-response`]&&(e[t.name]=N(`fieldRequired`));continue}let n=A.current?.querySelector(`[name="${CSS.escape(String(t.name??``))}"]`);!n?.validity||n.validity.valid||(e[t.name]=n.validity.valueMissing?N(`fieldRequired`):n.validationMessage||N(`invalid`))}E(e);let t=ee.find(t=>e[t.name]);return t&&setTimeout(()=>document.getElementById(`${k}-${t.name}`)?.focus(),0),!t},ne=e=>{v(e),O(N(e===`success`?`submitted`:`submitFailed`)),e===`success`&&setTimeout(()=>j.current?.focus(),0)};return(0,W.jsxs)(`div`,{ref:c,style:z(e),children:[(0,W.jsx)(`form`,{ref:A,action:t||void 0,method:n||`post`,name:r||void 0,encType:i||void 0,noValidate:o&&a?!0:void 0,onSubmit:async e=>{if(e.preventDefault(),!u&&!(o&&a&&!H())){if(a){let t={};if(o)for(let[e,n]of Object.entries(x))n!=null&&n!==``&&(t[e]=n);else for(let[n,r]of new FormData(e.currentTarget).entries())typeof r==`string`&&(t[n]=r===`on`||r);try{let e=await fetch(`${h||`/api`}/forms/${a}/submit`,{method:`post`,headers:{"content-type":`application/json`,...m?{"x-tenant":m}:{}},body:JSON.stringify(t)}),n=await e.json().catch(()=>null),r=n?.error,i=r?.details?.field;if(o&&typeof i==`string`&&ee.some(e=>e.name===i)){E({[i]:typeof r.message==`string`&&r.message||N(`invalid`)}),O(N(`submitFailed`)),setTimeout(()=>document.getElementById(`${k}-${i}`)?.focus(),0);return}ne(e.ok&&n?.success!==!1?`success`:`error`)}catch{ne(`error`)}return}if(!t){ne(`success`);return}try{let r=await fetch(t,{method:n||`post`,body:new FormData(e.currentTarget)});ne(r.ok?`success`:`error`)}catch{ne(`error`)}}},style:{...Fi,display:M===`success`?`none`:`flex`},children:o&&a?(0,W.jsxs)(W.Fragment,{children:[L&&(0,W.jsx)(Na,{steps:I.map(e=>({label:e.section?.label??N(`start`)})),active:R+1,style:{marginBottom:8}}),L&&I[R]?.section?.help&&(0,W.jsx)(`p`,{...K(`step-help`),style:{margin:0,fontSize:14,opacity:.7},children:I[R].section.help}),ee.some(e=>e.required)&&(0,W.jsx)(`p`,{...K(`required-note`),style:{margin:0,fontSize:13,opacity:.7},children:N(`requiredNote`)}),ee.map(e=>(0,W.jsx)(Xi,{field:e,value:x[qi(e)],values:x,onChange:V,inert:u,error:T[e.name],idBase:k},e.name)),(0,W.jsxs)(`div`,{...K(`actions`),style:{display:`flex`,gap:10,alignItems:`center`,marginTop:4},children:[L&&R>0&&(0,W.jsx)(`button`,{type:`button`,...K(`back-button`),disabled:u||void 0,onClick:()=>{E({}),w(R-1)},style:{...cr,background:`transparent`,color:`inherit`,border:0,padding:`10px 16px`,cursor:`pointer`},children:N(`back`)}),L&&!B?(0,W.jsx)(`button`,{type:`button`,...K(`next-button`),disabled:u||void 0,onClick:()=>{H()&&w(R+1)},style:{...cr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:te.length?.75:1},children:N(`next`)}):(0,W.jsx)(`button`,{type:`submit`,...K(`submit-button`),disabled:u||void 0,style:{...cr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`},children:s||N(`submit`)})]})]}):d}),(0,W.jsx)(`div`,{ref:j,tabIndex:-1,style:{display:M===`success`?`block`:`none`,outline:`none`},children:f?.success??null}),(0,W.jsx)(`div`,{style:{display:M===`error`?`block`:`none`,marginTop:12},children:f?.error??null}),!u&&(0,W.jsx)(`div`,{role:`status`,"aria-live":`polite`,style:Ze,children:D})]})}var Qi=null,$i=null,ea=e=>{let t=typeof e==`string`&&e.trim()?e.trim():``;if(Qi&&$i===t)return Qi;if(Qi&&typeof window<`u`){for(let e of[`grecaptcha`,`___grecaptcha_cfg`])try{delete window[e]}catch{window[e]=void 0}document.querySelectorAll(`script[src*="recaptcha"]`).forEach(e=>e.remove())}return $i=t,Qi=new Promise(e=>{if(typeof window>`u`)return;if(window.grecaptcha?.render)return e(window.grecaptcha);window.__webimRecaptchaReady=()=>e(window.grecaptcha);let n=document.createElement(`script`);n.src=`https://www.google.com/recaptcha/api.js?onload=__webimRecaptchaReady&render=explicit${t?`&hl=${encodeURIComponent(t)}`:``}`,n.async=!0,document.head.appendChild(n)}),Qi};function ta({siteKey:e,theme:t,size:n,hl:r,style:i,nodeRef:a,inert:o,onChange:s}){let c=(0,l.useContext)(G),u=c?.settings&&typeof c.settings==`object`?c.settings[`google.recaptchaKey`]:``,d=typeof e==`string`&&e.trim()||(typeof u==`string`?u.trim():``),f=(0,l.useRef)(null),p=(0,l.useRef)(s);if(p.current=s,(0,l.useEffect)(()=>{if(o||!d||!f.current)return;let e=!0,i=t=>{e&&typeof p.current==`function`&&p.current(t)};return ea(r).then(r=>{if(!(!e||!f.current||!r?.render)){f.current.innerHTML=``,i(``);try{r.render(f.current,{sitekey:d,theme:t===`dark`?`dark`:`light`,size:n===`compact`?`compact`:`normal`,callback:e=>i(typeof e==`string`?e:``),"expired-callback":()=>i(``),"error-callback":()=>i(``)})}catch{}}}),()=>{e=!1}},[o,d,t,n,r]),o){let e=t===`dark`;return(0,W.jsxs)(`div`,{ref:a,style:z(i),children:[(0,W.jsxs)(`div`,{style:{width:n===`compact`?164:302,boxSizing:`border-box`,padding:`12px 14px`,display:`flex`,alignItems:`center`,gap:12,borderRadius:4,border:`1px solid ${e?`#52565b`:`#d3d3d3`}`,background:e?`#222528`:`#f9f9f9`,color:e?`#f1f1f1`:`#282828`,fontSize:14,fontFamily:`Roboto, Arial, sans-serif`},children:[(0,W.jsx)(`span`,{style:{width:24,height:24,flexShrink:0,borderRadius:3,border:`2px solid ${e?`#8a8f94`:`#c1c1c1`}`,background:e?`#2f3337`:`#fff`}}),(0,W.jsx)(`span`,{style:{flexGrow:1},children:`I'm not a robot`}),(0,W.jsx)(`span`,{style:{fontSize:9,opacity:.6,textAlign:`center`,lineHeight:1.3},children:`reCAPTCHA`})]}),!d&&(0,W.jsx)(`div`,{style:{marginTop:6,fontSize:11,color:`#b45309`},children:`Set the google.recaptchaKey tenant setting (or a site key in Settings) to activate it.`})]})}return d?(0,W.jsx)(`div`,{ref:a,style:z(i),children:(0,W.jsx)(`div`,{ref:f})}):null}var na=e=>typeof e==`string`&&e.trim()?`wb-field-${e.trim()}`:void 0;function ra({text:e,parts:t,htmlFor:n,style:r,nodeRef:i,linked:a}){return(0,W.jsx)(`label`,{ref:i,htmlFor:n||void 0,style:{...Ii,...z(r)},children:xr(t,e,a)})}function ia({type:e=`text`,name:t,placeholder:n,required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsx)(`input`,{ref:a,id:na(t),type:e,name:t||void 0,autoComplete:Yi({name:t,type:{email:`email`,tel:`phone`,url:`link`}[e]}),placeholder:n,required:!o&&!!r,style:{...Li,...z(i)},...zi(o)})}function aa({name:e,placeholder:t,rows:n=4,required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsx)(`textarea`,{ref:a,id:na(e),name:e||void 0,placeholder:t,rows:n,required:!o&&!!r,style:{...Li,resize:`vertical`,...z(i)},...zi(o)})}function oa({kind:e=`checkbox`,label:t,name:n,value:r,required:i,style:a,nodeRef:o,inert:s}){return(0,W.jsxs)(`label`,{ref:o,style:{...Ri,...z(a)},children:[(0,W.jsx)(`input`,{type:e,...K(`control`),name:n||void 0,value:r||void 0,required:!s&&!!i,onClick:s?e=>e.preventDefault():void 0,tabIndex:s?-1:void 0,style:{margin:0,accentColor:`var(--page-accent, #111827)`}}),t]})}function sa({name:e,placeholder:t,options:n=[],required:r,style:i,nodeRef:a,inert:o}){return(0,W.jsxs)(`select`,{ref:a,id:na(e),name:e||void 0,autoComplete:Yi({name:e}),required:!o&&!!r,defaultValue:``,onMouseDown:o?e=>e.preventDefault():void 0,tabIndex:o?-1:void 0,style:{...Li,appearance:`auto`,...z(i)},children:[t!==``&&(0,W.jsx)(`option`,{value:``,disabled:!0,children:t??`Select…`}),n.map((e,t)=>(0,W.jsx)(`option`,{value:e,children:e},t))]})}function ca({name:e,accept:t,required:n,text:r=`Choose a file…`,style:i,nodeRef:a,inert:o}){let[s,c]=(0,l.useState)(null);return(0,W.jsxs)(`label`,{ref:a,className:`wb-file`,style:{...Li,display:`flex`,alignItems:`center`,gap:`8px`,cursor:o?`default`:`pointer`,borderStyle:`dashed`,color:s?`#111827`:`#6b7280`,...z(i)},children:[(0,W.jsx)(`input`,{type:`file`,name:e||void 0,accept:t||void 0,required:!o&&!!n,disabled:!!o,onChange:e=>c(e.target.files?.[0]?.name??null),style:Ze}),(0,W.jsx)(`span`,{"aria-hidden":!0,...K(`icon`),children:`📎`}),s??r]})}function la({legend:e=``,style:t,nodeRef:n,children:r}){return(0,W.jsxs)(`fieldset`,{ref:n,style:{...rr({border:`0 none`,margin:`0`,padding:`0`}),minWidth:0,display:`flex`,flexDirection:`column`,gap:`10px`,...z(t)},children:[typeof e==`string`&&e.trim()?(0,W.jsx)(`legend`,{...K(`legend`),style:{...Ii,padding:0,marginBottom:6},children:e}):null,r]})}function ua({text:e=`Submit`,style:t,nodeRef:n,inert:r}){return(0,W.jsx)(`button`,{ref:n,type:r?`button`:`submit`,style:{...cr,border:0,cursor:`pointer`,alignSelf:`flex-start`,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,lineHeight:1.4,fontFamily:`inherit`,...z(t)},children:e})}function da({cols:e=2,rows:t=1,style:n,nodeRef:r,linked:i}){let a=Math.max(1,(Number(e)||1)*(Number(t)||1));return(0,W.jsx)(`div`,{ref:r,style:{display:`grid`,gridTemplateColumns:`repeat(${Math.max(1,Number(e)||1)}, minmax(0, 1fr))`,gap:16,width:`100%`,...z(n)},children:Array.from({length:a},(e,t)=>(0,W.jsx)(`div`,{style:{minWidth:0},children:i?.[`cell-${t}`]??null},t))})}function fa(e,t){if(e===``||e==null)return t;let n=Number(e);return Number.isFinite(n)&&n>=0?n:t}function pa({collection:e,limit:t=6,layout:n=`grid`,columns:r=3,imageField:i,titleField:a=`name`,textField:o,custom:s,templateId:c,renderTemplate:u,paged:d,filters:f,parentField:p,topLevel:m,childrenOf:h,gap:g,style:_,nodeRef:v}){let{tenant:y,apiUrl:b,revision:x,locale:S}=(0,l.useContext)(G),C=(0,l.useContext)(Ln),w=(0,l.useContext)(Nn),T=(0,l.useContext)(Rn),E=h?null:e,D=!!p&&!h,[,O]=(0,l.useState)(0);(0,l.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>O(e=>e+1);return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]);let k=In(f),A=JSON.stringify(k),j=A!==`{}`&&!E?.startsWith?.(`api:`),M=j||!E?null:w?.[E],N=d?Pn(w):1,[P,F]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!E||M)return;let e=!0,n=E,r=new URLSearchParams;if(S&&r.set(`locale`,S),j&&r.set(`data_filter`,A),D&&!n.startsWith(`api:`))r.set(`all`,`1`);else if(d&&!n.startsWith(`api:`)){let e=Math.max(1,Number(t)||6);r.set(`offset`,String((N-1)*e)),r.set(`limit`,String(e))}let i=r.toString(),a=n.startsWith(`api:`)?`${b}/data/${encodeURIComponent(n.slice(4))}`:`${b}/dynamic/${encodeURIComponent(n)}${i?`?${i}`:``}`;return fetch(a,{headers:y?{"x-tenant":y}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&F(n.filter(e=>e&&typeof e==`object`))}).catch(()=>e&&F([])),()=>{e=!1}},[x,E,y,b,S,M,d,N,t,j,A,D]),!E&&!h)return null;let I=Math.max(1,Number(t)||6),L=h?T?.all??[]:M??P??[],R=h?T?.parentField:p,ee=h?T?.collection:E,te=h?Bn(L,R,T?.entry):D&&m?L.filter(e=>zn(e,p).length===0):L,B=d&&(M||h||D||E.startsWith(`api:`))?te.slice((N-1)*I,N*I):te.slice(0,I),V=Math.min(Math.max(Number(r)||3,1),6),H=n===`list`?{display:`flex`,flexDirection:`column`,gap:fa(g,20)}:{display:`grid`,gridTemplateColumns:`repeat(${V}, minmax(0, 1fr))`,gap:fa(g,24)},ne=u??(c&&C?.render?e=>C.render(c,e):null);return s&&ne?(0,W.jsx)(`div`,{ref:v,style:{width:`100%`,...H,...z(_)},children:B.map(e=>(0,W.jsx)(`div`,{style:{minWidth:0},children:(0,W.jsx)(Rn.Provider,{value:{entry:e,all:L,parentField:R,collection:ee},children:ne(t=>er(t,e,S))})},e.id??e?.data?.slug))}):(0,W.jsx)(`div`,{ref:v,style:{width:`100%`,...H,...z(_)},children:B.map(e=>{let t=i?Gn(e?.data,i):null,r=a?qn(Gn(e?.data,a)):null,s=o?Gn(e?.data,o):null,c=Array.isArray(s)?s:null,l=c||s==null?null:qn(s),u=n===`list`;return(0,W.jsxs)(`div`,{...K(`card`),style:{display:`flex`,flexDirection:u?`row`:`column`,gap:u?20:12,alignItems:u?`center`:`stretch`,minWidth:0},children:[t&&(0,W.jsx)(`img`,{...K(`image`),src:t,alt:r??``,style:{width:u?160:`100%`,aspectRatio:`3 / 2`,objectFit:`cover`,borderRadius:10,flexShrink:0,display:`block`}}),(0,W.jsxs)(`div`,{...K(`body`),style:{minWidth:0},children:[r&&(0,W.jsx)(`h3`,{...K(`title`),style:{margin:0,fontSize:18,fontWeight:700},children:r}),l&&(0,W.jsx)(`p`,{...K(`text`),style:{margin:`6px 0 0`,fontSize:14,lineHeight:1.55,opacity:.75},children:l}),c&&(0,W.jsx)(`div`,{...K(`text`),style:{marginTop:6,fontSize:14,lineHeight:1.55,opacity:.85},children:Ar(c)})]})]},e.id??e?.data?.slug)})})}function ma({fields:e=[],buttonLabel:t=`Search`,style:n,nodeRef:r,inert:i}){let a=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&typeof e.name==`string`&&e.name):[],o=i?{}:Fn(),s={height:34,padding:`0 12px`,borderRadius:8,border:`1px solid var(--page-border, rgba(100, 116, 139, 0.4))`,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,fontSize:13,fontFamily:`inherit`,outline:`none`,minWidth:140,flex:`0 1 auto`,boxSizing:`border-box`},c=e=>{let t=e&&typeof e==`object`?e.value:e,n=e&&typeof e==`object`?e.label??e.value:e;return{value:String(t??``),label:String(n??``)}};return(0,W.jsxs)(`form`,{ref:r,method:`get`,onSubmit:e=>{if(i){e.preventDefault();return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);for(let e of[...t.keys()])(e.startsWith(`f_`)||e===`page`)&&t.delete(e);for(let[n,r]of new FormData(e.currentTarget).entries())n.startsWith(`f_`)&&typeof r==`string`&&r.trim()!==``&&t.set(n,r);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`))},style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,width:`100%`,...z(n)},children:[a.map(e=>Array.isArray(e.options)&&e.options.length>0||e.type===`option`||e.type===`select`?(0,W.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...K(`select`),style:s,...zi(i),children:[(0,W.jsx)(`option`,{value:``,children:e.label||e.name}),(Array.isArray(e.options)?e.options:[]).map(e=>{let t=c(e);return(0,W.jsx)(`option`,{value:t.value,children:t.label},t.value)})]},e.name):e.type===`switch`?(0,W.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...K(`select`),style:s,...zi(i),children:[(0,W.jsx)(`option`,{value:``,children:e.label||e.name}),(0,W.jsx)(`option`,{value:`true`,children:`Yes`}),(0,W.jsx)(`option`,{value:`false`,children:`No`})]},e.name):(0,W.jsx)(`input`,{type:`text`,name:`f_${e.name}`,defaultValue:o[e.name]??``,placeholder:e.label||e.name,...K(`input`),style:s,...zi(i)},e.name)),(0,W.jsx)(`button`,{type:`submit`,...K(`button`),style:{...s,minWidth:0,padding:`0 18px`,border:`none`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,fontWeight:600,cursor:i?`default`:`pointer`},...zi(i),children:t})]})}function ha({items:e=[],separator:t=`/`,style:n,nodeRef:r}){return e.length?(0,W.jsx)(`nav`,{ref:r,"aria-label":`Breadcrumb`,style:{...z(n)},children:(0,W.jsx)(`ol`,{...K(`list`),style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,listStyle:`none`,margin:0,padding:0,fontSize:14},children:e.map((n,r)=>{let i=r===e.length-1;return(0,W.jsxs)(`li`,{...K(`item`),style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[r>0&&(0,W.jsx)(`span`,{...K(`separator`),style:{opacity:.4},"aria-hidden":!0,children:t}),i||!n.href?(0,W.jsx)(`span`,{...K(`crumb`,i&&`crumb-current`),style:{fontWeight:i?600:400,opacity:i?1:.7},"aria-current":i?`page`:void 0,children:n.label}):(0,W.jsx)(`a`,{...K(`crumb`),href:n.href,style:{color:`inherit`,opacity:.7,textDecoration:`none`},children:n.label})]},r)})})}):null}function ga({pages:e=5,current:t=1,prevNext:n=!0,href:r=`#`,source:i,pageSize:a=6,align:o,hideEmpty:s,inert:c,style:u,nodeRef:d}){let{tenant:f,apiUrl:p,revision:m}=(0,l.useContext)(G),h=(0,l.useContext)(Nn),[g,_]=(0,l.useState)(null),v=i?Number(h?.[`${i}:total`]):NaN;(0,l.useEffect)(()=>{if(!i||Number.isFinite(v))return;let e=!0,t=i.startsWith(`api:`)?`${p}/data/${encodeURIComponent(i.slice(4))}`:`${p}/dynamic/${encodeURIComponent(i)}?limit=1`;return fetch(t,{headers:f?{"x-tenant":f}:{}}).then(e=>e.json()).then(t=>{if(!e)return;let n=t?.payload,r=Array.isArray(n)?n.length:Number(n?.total?.filtered??n?.total?.all??(Array.isArray(n?.data)?n.data.length:0));_(Number.isFinite(r)?r:0)}).catch(()=>e&&_(0)),()=>{e=!1}},[m,i,f,p,v]);let y=Math.max(1,Number(a)||6),b=Number.isFinite(v)?v:g;if(i&&b===null||i&&s&&!(b>0))return null;let x=Math.min(Math.max(i?Math.ceil(b/y):Number(e)||1,1),50),S=Math.min(Math.max(i?Pn(h):Number(t)||1,1),x),C=e=>{if(i){if(typeof window<`u`){let t=new URLSearchParams(window.location.search);return t.set(`page`,String(e)),`?${t.toString()}`}return`?page=${e}`}return r&&r!==`#`?r.replace(`{page}`,String(e)):`#`},w=o===`center`?`center`:o===`right`?`flex-end`:`flex-start`,T=c?e=>e.preventDefault():void 0,E=e=>({display:`inline-flex`,alignItems:`center`,justifyContent:`center`,minWidth:36,height:36,padding:`0 8px`,borderRadius:8,fontSize:14,textDecoration:`none`,color:e?`var(--page-accent-text, #ffffff)`:`inherit`,background:e?`var(--page-accent, #111827)`:`transparent`,border:e?`1px solid transparent`:`1px solid rgba(148, 163, 184, 0.4)`});return(0,W.jsxs)(`nav`,{ref:d,"aria-label":`Pagination`,style:{display:`flex`,flexWrap:`wrap`,gap:8,alignItems:`center`,justifyContent:w,...z(u)},children:[n&&(0,W.jsx)(`a`,{...K(`page`,`page-arrow`),href:S>1?C(S-1):`#`,onClick:T,"aria-label":`Previous`,style:{...E(!1),opacity:S>1?1:.4},children:`‹`}),Array.from({length:x},(e,t)=>t+1).map(e=>(0,W.jsx)(`a`,{...K(`page`,e===S&&`page-active`),href:C(e),onClick:T,"aria-current":e===S?`page`:void 0,style:E(e===S),children:e},e)),n&&(0,W.jsx)(`a`,{...K(`page`,`page-arrow`),href:S<x?C(S+1):`#`,onClick:T,"aria-label":`Next`,style:{...E(!1),opacity:S<x?1:.4},children:`›`})]})}var _a=`webim.page_mode`,va=()=>{if(typeof window>`u`)return`auto`;try{let e=window.localStorage.getItem(_a);return e===`light`||e===`dark`?e:`auto`}catch{return`auto`}},ya=e=>{let t={width:16,height:16,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0};return e===`light`?(0,W.jsxs)(`svg`,{...t,children:[(0,W.jsx)(`circle`,{cx:`12`,cy:`12`,r:`4`}),(0,W.jsx)(`path`,{d:`M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4`})]}):e===`dark`?(0,W.jsx)(`svg`,{...t,children:(0,W.jsx)(`path`,{d:`M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z`})}):(0,W.jsxs)(`svg`,{...t,children:[(0,W.jsx)(`rect`,{x:`2`,y:`3`,width:`20`,height:`14`,rx:`2`}),(0,W.jsx)(`path`,{d:`M8 21h8M12 17v4`})]})},ba={light:`Light theme`,dark:`Dark theme`,auto:`Follow the device theme`};function xa({variant:e,showSystem:t,style:n,nodeRef:r,inert:i}){let[a,o]=(0,l.useState)(i?`auto`:va),s=(0,l.useRef)(null),c=e=>{s.current=e,typeof r==`function`&&r(e)};(0,l.useEffect)(()=>{if(i)return;let e=s.current?.closest?.(`.webim-page`);e&&(a===`light`||a===`dark`?e.setAttribute(`data-webim-mode`,a):e.removeAttribute(`data-webim-mode`));try{a===`auto`?window.localStorage.removeItem(_a):window.localStorage.setItem(_a,a)}catch{}},[a,i]);let u=t===!1?[`light`,`dark`]:[`light`,`dark`,`auto`],d=u.includes(a)?a:u[0],f={appearance:`none`,border:0,margin:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,background:`transparent`,color:`inherit`,font:`inherit`,cursor:i?`default`:`pointer`,borderRadius:999};if(e===`buttons`)return(0,W.jsx)(`div`,{ref:c,role:`group`,"aria-label":`Theme`,style:{display:`inline-flex`,alignItems:`center`,gap:2,padding:3,borderRadius:999,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:u.map(e=>(0,W.jsx)(`button`,{...K(`option`,e===d&&`option-active`),type:`button`,title:ba[e],"aria-label":ba[e],"aria-pressed":e===d,onClick:i?void 0:()=>o(e),style:{...f,width:28,height:28,color:e===d?`var(--page-accent-text, #ffffff)`:`inherit`,background:e===d?`var(--page-accent, #111827)`:`transparent`,opacity:e===d?1:.7},children:ya(e)},e))});let p=u[(u.indexOf(d)+1)%u.length];return(0,W.jsx)(`button`,{ref:c,type:`button`,title:ba[d],"aria-label":`Theme: ${ba[d]} — switch to ${ba[p]}`,onClick:i?void 0:()=>o(p),style:{...f,width:36,height:36,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:ya(d)})}function Sa(e){let t=e?.parentElement;for(;t&&t!==document.body;){let e=getComputedStyle(t).overflowY;if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t;t=t.parentElement}return window}var Ca=e=>e===window?window.scrollY:e.scrollTop,wa={"bottom-right":e=>({right:e,bottom:e}),"bottom-left":e=>({left:e,bottom:e}),"bottom-center":e=>({left:`50%`,bottom:e,transform:`translateX(-50%)`})},Ta={linear:e=>e,out:e=>1-(1-e)**3,inout:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2},Ea=e=>{let t=e.getBoundingClientRect(),n=e.parentElement;for(;n&&n!==document.body;){let e=getComputedStyle(n);if(/(auto|scroll)/.test(e.overflowY)&&n.scrollHeight>n.clientHeight)break;n=n.parentElement}return!n||n===document.body?Math.max(document.documentElement.scrollHeight-(t.bottom+window.scrollY),0):Math.max(n.scrollHeight-(t.bottom-n.getBoundingClientRect().top+n.scrollTop),0)},Da=(e,t)=>{let n=typeof e==`number`?e:parseFloat(e);return Number.isFinite(n)?n:t};function Oa(e,{locale:t,decimals:n=0,separator:r=`auto`}={}){let i=Math.min(Math.max(Math.round(Da(n,0)),0),6);try{return new Intl.NumberFormat(t||void 0,{minimumFractionDigits:i,maximumFractionDigits:i,useGrouping:r!==`none`}).format(e)}catch{return e.toFixed(i)}}function ka({from:e,to:t,duration:n,delay:r,decimals:i,prefix:a,suffix:o,separator:s,easing:c,trigger:u,offset:d,once:f,label:p,align:m,style:h,nodeRef:g,inert:_}){let{locale:v}=(0,l.useContext)(G),y=Math.max(Da(d,0),0),b=Da(e,0),x=Da(t,100),[S,C]=(0,l.useState)(x),w=(0,l.useRef)(null),[T,E]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=w.current;if(_||!T||!e){C(x);return}C(b);let t=Math.max(Da(n,2e3),0),i=Math.max(Da(r,0),0),a=Ta[c]||Ta.out,o=typeof window<`u`&&window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,s=0,l=0,d=!1,p=()=>{if(cancelAnimationFrame(s),clearTimeout(l),o||t===0){C(x);return}l=setTimeout(()=>{let e=performance.now(),n=r=>{let i=Math.min((r-e)/t,1);C(b+(x-b)*a(i)),i<1&&(s=requestAnimationFrame(n))};s=requestAnimationFrame(n)},i)};if(u===`load`||typeof IntersectionObserver>`u`)return p(),()=>{cancelAnimationFrame(s),clearTimeout(l)};let m=new IntersectionObserver(e=>{let t=e.some(e=>e.isIntersecting);t&&(!d||f===!1)?(d=!0,p()):!t&&f===!1&&(cancelAnimationFrame(s),clearTimeout(l),C(b))},{rootMargin:`0px 0px -${Math.min(y,Math.floor(Ea(e)))}px 0px`,threshold:y>0?0:.3});return m.observe(e),()=>{m.disconnect(),cancelAnimationFrame(s),clearTimeout(l)}},[T,_,b,x,n,r,c,u,y,f]),(0,W.jsxs)(`div`,{ref:e=>{w.current=e,e&&E(!0),typeof g==`function`&&g(e)},"data-wb-counter":``,style:{display:`flex`,flexDirection:`column`,alignItems:m===`left`?`flex-start`:m===`right`?`flex-end`:`center`,gap:4,fontSize:48,fontWeight:700,lineHeight:1.1,textAlign:m===`left`?`left`:m===`right`?`right`:`center`,...z(h)},children:[(0,W.jsxs)(`span`,{...K(`number`),style:{fontVariantNumeric:`tabular-nums`,whiteSpace:`nowrap`},children:[a||``,Oa(S,{locale:v,decimals:i,separator:s}),o||``]}),p?(0,W.jsx)(`span`,{...K(`label`),style:{fontSize:`0.3em`,fontWeight:400,lineHeight:1.4,opacity:.72},children:p}):null]})}function Aa({variant:e,label:t,position:n,offset:r,showAfter:i,smooth:a,bg:o,fg:s,style:c,nodeRef:u,inert:d,frame:f,builder:p}){let[m,h]=(0,l.useState)(!!d),[g,_]=(0,l.useState)(null),v=e=>{_(e),typeof u==`function`&&u(e)};(0,l.useEffect)(()=>{if(d){h(!0);return}if(!g)return;let e=Number(i)>=0?Number(i):300,t=()=>{let t=Sa(g),n=p&&!(t===window?document.documentElement.scrollHeight>window.innerHeight:t.scrollHeight>t.clientHeight);h(n||Ca(t)>e)};return t(),document.addEventListener(`scroll`,t,{capture:!0,passive:!0}),()=>document.removeEventListener(`scroll`,t,{capture:!0})},[d,g,i,p]);let y=()=>{if(d)return;let e=Sa(g),t=window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,n=a===!1||t?`auto`:`smooth`;e===window?window.scrollTo({top:0,behavior:n}):e.scrollTo({top:0,behavior:n})},b=Number(r)>=0?Number(r):24,x=e===`pill`,S=t||`Top`,C=wa[n]?n:`bottom-right`,w=f?{position:`fixed`,zIndex:5,bottom:(f.bottom??0)+b,...C===`bottom-left`?{left:(f.left??0)+b}:null,...C===`bottom-right`?{right:(f.right??0)+b}:null,...C===`bottom-center`?{left:(f.left??0)+(f.width??0)/2,transform:`translateX(-50%)`}:null}:{position:`fixed`,zIndex:2147482e3,...wa[C](b)};return(0,W.jsxs)(`button`,{ref:v,type:`button`,title:S,"aria-label":S,"aria-hidden":!m,tabIndex:m?0:-1,onClick:y,style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,gap:x?8:0,appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,width:x?`auto`:44,height:44,padding:x?`0 18px`:0,borderRadius:999,border:`1px solid transparent`,background:o||`var(--page-accent, #111827)`,color:s||`var(--page-accent-text, #ffffff)`,boxShadow:`0 6px 20px rgba(15, 23, 42, 0.25)`,cursor:d?`default`:`pointer`,opacity:+!!m,pointerEvents:m?`auto`:`none`,transition:`opacity 160ms ease, transform 160ms ease`,...w,...z(c),...w.transform?{transform:w.transform}:null},children:[(0,W.jsx)(`svg`,{...K(`icon`),width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:`M12 19V5M12 5l-7 7M12 5l7 7`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`})}),x?(0,W.jsx)(`span`,{...K(`label`),children:S}):null]})}var ja={facebook:{label:`Facebook`,color:`#1877f2`,d:`M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z`},instagram:{label:`Instagram`,color:`#e4405f`,d:`M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24 12 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06zm0 5.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z`},x:{label:`X (Twitter)`,color:`#000000`,d:`M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z`},linkedin:{label:`LinkedIn`,color:`#0a66c2`,d:`M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z`},youtube:{label:`YouTube`,color:`#ff0000`,d:`M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z`},tiktok:{label:`TikTok`,color:`#000000`,d:`M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z`},whatsapp:{label:`WhatsApp`,color:`#25d366`,d:`M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z`},telegram:{label:`Telegram`,color:`#26a5e4`,d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`},pinterest:{label:`Pinterest`,color:`#bd081c`,d:`M12 0C5.373 0 0 5.372 0 12c0 5.084 3.163 9.426 7.627 11.174-.105-.949-.2-2.405.042-3.441.218-.937 1.407-5.965 1.407-5.965s-.359-.719-.359-1.782c0-1.668.967-2.914 2.171-2.914 1.023 0 1.518.769 1.518 1.69 0 1.03-.655 2.569-.994 3.995-.283 1.194.599 2.169 1.777 2.169 2.133 0 3.772-2.249 3.772-5.495 0-2.873-2.064-4.882-5.012-4.882-3.414 0-5.418 2.561-5.418 5.207 0 1.031.397 2.138.893 2.738a.36.36 0 01.083.345l-.333 1.36c-.053.22-.174.267-.402.161-1.499-.698-2.436-2.889-2.436-4.649 0-3.785 2.75-7.262 7.929-7.262 4.163 0 7.398 2.967 7.398 6.931 0 4.136-2.607 7.464-6.227 7.464-1.216 0-2.359-.631-2.75-1.378l-.748 2.853c-.271 1.043-1.002 2.35-1.492 3.146C9.57 23.812 10.763 24 12 24c6.627 0 12-5.373 12-12 0-6.628-5.373-12-12-12z`},github:{label:`GitHub`,color:`#181717`,d:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`},discord:{label:`Discord`,color:`#5865f2`,d:`M20.317 4.37a19.791 19.791 0 00-4.885-1.515.074.074 0 00-.079.037c-.21.375-.444.865-.608 1.25a18.27 18.27 0 00-5.487 0 12.64 12.64 0 00-.617-1.25.077.077 0 00-.079-.037A19.736 19.736 0 003.677 4.37a.07.07 0 00-.032.027C.533 9.046-.32 13.58.099 18.058a.082.082 0 00.031.056 19.9 19.9 0 005.993 3.03.078.078 0 00.084-.028c.462-.63.873-1.295 1.226-1.994a.076.076 0 00-.041-.106 13.107 13.107 0 01-1.872-.892.077.077 0 01-.008-.128c.126-.094.252-.192.372-.291a.074.074 0 01.077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 01.078.009c.12.099.246.198.373.292a.077.077 0 01-.006.127 12.299 12.299 0 01-1.873.892.077.077 0 00-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 00.084.028 19.839 19.839 0 006.002-3.03.077.077 0 00.032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 00-.031-.03zM8.02 15.331c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z`},email:{label:`E-mail`,color:`#64748b`,d:`M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z`},website:{label:`Website`,color:`#64748b`,d:`M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z`}};function Ma({links:e=[],variant:t,color:n,size:r,gap:i,newTab:a,style:o,nodeRef:s,inert:c}){let l=Array.isArray(e)?e.filter(e=>e&&ja[e.network]):[];if(!l.length)return null;let u=Math.min(Math.max(Number(r)||18,10),64),d=Math.round(u*1.9),f=Number.isFinite(Number(i))?Number(i):10,p=e=>n===`accent`?`var(--page-accent, #111827)`:n===`inherit`?`currentColor`:e.color,m=c?e=>e.preventDefault():void 0;return(0,W.jsx)(`div`,{ref:s,style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:f,...z(o)},children:l.map((e,r)=>{let i=ja[e.network],o=t!==`outline`&&t!==`plain`,s=o?n===`accent`?`var(--page-accent-text, #ffffff)`:n===`inherit`?`var(--page-bg, #ffffff)`:`#ffffff`:p(i);return(0,W.jsx)(`a`,{...K(`link`,/^[a-z]+$/.test(e.network??``)&&`link-${e.network}`),href:e.url||`#`,onClick:m,"aria-label":e.label||i.label,title:e.label||i.label,...a!==!1&&!c?{target:`_blank`,rel:`noopener noreferrer`}:{},style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,width:t===`plain`?u:d,height:t===`plain`?u:d,borderRadius:`50%`,background:o?p(i):`transparent`,border:t===`outline`?`1px solid ${p(i)}`:`none`,color:`inherit`,textDecoration:`none`},children:(0,W.jsx)(`svg`,{...K(`icon`),width:u,height:u,viewBox:`0 0 24 24`,fill:s,"aria-hidden":!0,children:(0,W.jsx)(`path`,{d:i.d})})},`${e.network}-${r}`)})})}function Na({steps:e=[],active:t=1,vertical:n=!1,style:r,nodeRef:i}){if(!e.length)return null;let a=Math.min(Math.max(Number(t)||1,1),e.length),o=e=>({width:32,height:32,borderRadius:`50%`,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:14,fontWeight:600,flexShrink:0,color:e===`todo`?`inherit`:`var(--page-accent-text, #ffffff)`,background:e===`todo`?`transparent`:`var(--page-accent, #111827)`,border:e===`todo`?`1px solid rgba(148, 163, 184, 0.5)`:`1px solid transparent`,opacity:e===`todo`?.6:1,boxShadow:e===`active`?`0 0 0 4px rgba(99, 102, 241, 0.2)`:`none`}),s=e=>({flexGrow:1,alignSelf:`center`,background:e?`var(--page-accent, #111827)`:`rgba(148, 163, 184, 0.4)`,...n?{width:2,minHeight:24,marginLeft:15,alignSelf:`auto`}:{height:2,minWidth:24}});return(0,W.jsx)(`div`,{ref:i,style:{display:`flex`,flexDirection:n?`column`:`row`,alignItems:n?`stretch`:`flex-start`,gap:n?4:8,...z(r)},children:e.map((e,t)=>{let r=t+1,i=r<a?`done`:r===a?`active`:`todo`;return(0,W.jsxs)(l.Fragment,{children:[t>0&&(0,W.jsx)(`div`,{...K(`step-line`,r<=a&&`step-line-done`),style:s(r<=a),"aria-hidden":!0}),(0,W.jsxs)(`div`,{...K(`step`,`step-${i}`),style:{display:`flex`,flexDirection:n?`row`:`column`,alignItems:`center`,gap:8,minWidth:0,textAlign:n?`left`:`center`},children:[(0,W.jsx)(`div`,{...K(`step-circle`,`step-circle-${i}`),style:o(i),children:i===`done`?`✓`:r}),(0,W.jsxs)(`div`,{style:{minWidth:0},children:[(0,W.jsx)(`div`,{...K(`step-label`,`step-label-${i}`),style:{fontSize:13,fontWeight:i===`active`?700:500,opacity:i===`todo`?.6:1},children:e.label}),e.description&&(0,W.jsx)(`div`,{...K(`step-description`),style:{fontSize:12,opacity:.6},children:e.description})]})]})]},t)})})}var Pa={small:{w:132,h:46,name:11.5,title:10,avatar:28},medium:{w:168,h:56,name:13,title:11,avatar:36},large:{w:210,h:70,name:15.5,title:12.5,avatar:46}},Fa=e=>Pa[e]??Pa.medium;Pa.medium.w,Pa.medium.h;var Ia=e=>String(e?.group??``).trim(),La=e=>{let t=[],n=new Map;return e.forEach((e,r)=>{let i=Ia(e)||`#${r}`;n.has(i)||(n.set(i,[]),t.push(i)),n.get(i).push(e)}),t.flatMap(e=>n.get(e))},Ra=20,za=12,Ba=[`left`,`center`,`right`],Va=e=>e.points.map((e,t)=>`${t?`L`:`M`} ${e.x} ${e.y}`).join(` `);function Ha(e,{size:t=`medium`,horizontal:n=!1,groupTitles:r=`top`,columns:i=`off`}={}){let a=Fa(t),o=n?a.h:a.w,s=n?16:20,c=(n?a.w:a.h)+(n?56:48),l=Array.isArray(e)?e.filter(e=>e&&e.id):[],u=new Set(l.map(e=>e.id)),d=new Map,f=[];for(let e of l)e.parent&&u.has(e.parent)&&e.parent!==e.id?(d.has(e.parent)||d.set(e.parent,[]),d.get(e.parent).push(e)):f.push(e);f=La(f);for(let[e,t]of d)d.set(e,La(t));let p=!n&&Ba.includes(i),m=e=>Ba.includes(e?.columns)?e.columns:i,h=e=>{let t=d.get(e.id)??[];if(!p)return t.map(e=>({nodes:[e]}));let n=[],r=[],i=()=>{r.length>1?n.push({nodes:r,line:m(e)}):r.forEach(e=>n.push({nodes:[e]})),r=[]};for(let e of t){let t=!(d.get(e.id)??[]).length;r.length&&(!t||Ia(r[0])!==Ia(e))&&i(),t?r.push(e):n.push({nodes:[e]})}return i(),n},g=(e,t)=>s+(Ia(e)!==Ia(t)&&(Ia(e)||Ia(t))?24:0),_=(e,t)=>g(e.nodes.at(-1),t.nodes[0]),v=e=>o+(e.line===`center`?0:Ra),y=new Map,b=(e,t)=>{if(t.has(e.id))return 0;t.add(e.id);let n=h(e),r=n.reduce((e,r,i)=>{let a=r.line?v(r):b(r.nodes[0],t);return r.line&&r.nodes.forEach(e=>t.add(e.id)),e+a+(i?_(n[i-1],r):0)},0),i=Math.max(o,r);return y.set(e.id,i),i};f.forEach(e=>b(e,new Set));let x=[],S=[],C=new Map,w=0,T=(e,t,r)=>{x.push({node:e,x:t,y:r});let i=Ia(e);if(i){let n=`${e.parent&&u.has(e.parent)&&e.parent!==e.id?e.parent:``}|${i}`;C.has(n)||C.set(n,{title:i,color:``,members:[]});let a=C.get(n);!a.color&&e.groupColor&&(a.color=e.groupColor),a.members.push({x:t,y:r})}w=Math.max(w,n?t+a.w:r+a.h)},E=(e,t,n,r)=>{let i=t+(e.line===`left`?Ra:0),o=n*c,s=r.y+(o-r.y)/2,l=e.line===`left`?i-Ra/2:i+a.w+Ra/2;e.nodes.forEach((t,n)=>{let c=o+n*(a.h+za),u=c+a.h/2;if(T(t,i,c),e.line===`center`)S.push(n?{points:[{x:i+a.w/2,y:c-za},{x:i+a.w/2,y:c}]}:{points:[r,{x:r.x,y:s},{x:i+a.w/2,y:s},{x:i+a.w/2,y:c}]});else{let t=e.line===`left`?i:i+a.w;S.push({points:[r,{x:r.x,y:s},{x:l,y:s},{x:l,y:u},{x:t,y:u}]})}})},D=(e,t,r,i)=>{if(i.has(e.id))return;i.add(e.id);let s=t+((y.get(e.id)??o)-o)/2,l=r*c;T(e,n?l:s,n?s:l);let u=t,d=h(e),f=n?{x:l+a.w,y:s+a.h/2}:{x:s+a.w/2,y:l+a.h};d.forEach((e,t)=>{if(t&&(u+=_(d[t-1],e)),e.line){E(e,u,r+1,f),e.nodes.forEach(e=>i.add(e.id)),u+=v(e);return}let a=e.nodes[0],s=u+((y.get(a.id)??o)-o)/2+o/2,l=(r+1)*c;S.push({points:n?[f,{x:(f.x+l)/2,y:f.y},{x:(f.x+l)/2,y:s},{x:l,y:s}]:[f,{x:f.x,y:(f.y+l)/2},{x:s,y:(f.y+l)/2},{x:s,y:l}]}),D(a,u,r+1,i),u+=y.get(a.id)??o})},O=0,k=new Set;f.forEach((e,t)=>{t&&(O+=g(f[t-1],e)),D(e,O,0,k),O+=y.get(e.id)??o});let A=Math.max(O,o),j=r===`hidden`?0:22,M=[...C.values()].map(e=>{let t=Math.min(...e.members.map(e=>e.x))-12,n=Math.max(...e.members.map(e=>e.x))+a.w+12,i=Math.min(...e.members.map(e=>e.y))-12-(r===`bottom`?0:j),o=Math.max(...e.members.map(e=>e.y))+a.h+12+(r===`bottom`?j:0);return{x:t,y:i,width:n-t,height:o-i,title:e.title,color:e.color}}),N=n?Math.max(w,a.w):A,P=n?A:Math.max(w,a.h),F=Math.max(0,...M.map(e=>-e.x)),I=Math.max(0,...M.map(e=>-e.y));if(M.length&&(N=Math.max(N,...M.map(e=>e.x+e.width))+F,P=Math.max(P,...M.map(e=>e.y+e.height))+I,F||I)){for(let e of x)e.x+=F,e.y+=I;for(let e of S)e.points=e.points.map(e=>({x:e.x+F,y:e.y+I}));for(let e of M)e.x+=F,e.y+=I}return{boxes:x,links:S,groups:M,width:N,height:P,horizontal:n}}var Ua=(e,t)=>{let n=String(e??``);return n.length>t?`${n.slice(0,t-1)}…`:n},Wa=e=>{let t=/^#([0-9a-f]{6}|[0-9a-f]{3})$/i.exec(String(e??``).trim());if(!t)return`#ffffff`;let n=t[1];n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=parseInt(n,16);return .299*(r>>16&255)+.587*(r>>8&255)+.114*(r&255)>150?`#111827`:`#ffffff`},Ga=e=>!!(e?.cv?.trim?.()||e?.photo||e?.profilePhoto||e?.profile?.length);function Ka(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:qn(e);return n.map(e=>{let n=e.data??{},a=r(n[t.parentField]),o=a&&typeof a==`object`?a.id??null:a||null;return{id:e.id,name:i(n[t.nameField||`name`])||i(n.name)||`Untitled`,title:t.titleField?i(n[t.titleField]):``,photo:t.photoField&&r(n[t.photoField])||``,parent:t.parentField?o:null,cv:t.cvField?i(n[t.cvField]):``,href:t.hrefField?i(n[t.hrefField]):``,group:t.groupField?i(n[t.groupField]):``}})}var qa=/^(https?:\/\/[^\s"<>]+|mailto:[^\s"<>]+|tel:[+\d][\d\s().-]*|\/(?!\/)[^\s"<>]*)$/i,Ja=e=>{let t=String(e??``).trim();return qa.test(t)?t:``},Ya=e=>{e.startsWith(`/`)?window.location.assign(e):window.open(e,`_blank`,`noopener,noreferrer`)},Xa={size:36,pad:10};function Za({node:e,onClose:t}){(0,l.useEffect)(()=>{let e=e=>e.key===`Escape`&&t();return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let n=e.profile?.length?e.profile:null,r=n?``:e.profilePhoto||e.photo,i=e.title||e.name,a=e.title&&e.name?e.name:``,o=!!(n||r&&e.cv),s=Ja(e.href);return(0,W.jsx)(`div`,{onClick:t,role:`dialog`,"aria-modal":`true`,"aria-label":i,style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(2, 6, 23, 0.6)`,backdropFilter:`blur(4px)`,WebkitBackdropFilter:`blur(4px)`,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:16},children:(0,W.jsxs)(`div`,{onClick:e=>e.stopPropagation(),style:{background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.35)`,borderRadius:14,maxWidth:o?900:440,width:`100%`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,overflow:`hidden`,boxShadow:`0 24px 64px rgba(2, 6, 23, 0.5)`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:12,padding:`18px 20px 14px 24px`,borderBottom:`1px solid rgba(148, 163, 184, 0.3)`},children:[(0,W.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{style:{fontSize:18,fontWeight:700,lineHeight:1.35},children:i}),a&&(0,W.jsx)(`div`,{style:{fontSize:14,opacity:.7,marginTop:2},children:a})]}),(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:t,style:{flexShrink:0,width:32,height:32,border:0,borderRadius:8,background:`transparent`,color:`inherit`,fontSize:20,lineHeight:1,cursor:`pointer`,opacity:.6},children:`×`})]}),(0,W.jsxs)(`div`,{style:{overflowY:`auto`,padding:24,display:`flex`,flexWrap:`wrap`,gap:24,alignItems:`flex-start`},children:[r&&(0,W.jsx)(`img`,{src:r,alt:e.name||i,style:o?{flex:`1 1 220px`,maxWidth:340,width:`100%`,height:`auto`,borderRadius:10,objectFit:`cover`}:{width:96,height:96,borderRadius:`50%`,objectFit:`cover`}}),(n||e.cv||s)&&(0,W.jsxs)(`div`,{style:{flex:`2 1 320px`,minWidth:0},children:[n&&(0,W.jsx)(`div`,{style:{display:`flow-root`,marginBottom:s?12:0},children:Ar(n)}),!n&&e.cv&&String(e.cv).split(/\n+/).map((e,t)=>(0,W.jsx)(`p`,{style:{fontSize:15,lineHeight:1.65,margin:`0 0 12px`},children:e},t)),s&&(0,W.jsx)(`a`,{href:s,target:`_blank`,rel:`noopener noreferrer`,style:{display:`inline-block`,marginTop:6,padding:`8px 14px`,borderRadius:8,fontSize:13,fontWeight:600,textDecoration:`none`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:`Open profile ↗`})]})]})]})})}function Qa(e){return e.chart?.people?.length?(0,W.jsx)($a,{...e}):(0,W.jsx)(eo,{...e})}function $a({chart:e,profiles:t,style:n,nodeRef:r,interactive:i=!0}){let[a,o]=(0,l.useState)(null),s=(0,l.useMemo)(()=>ln(e),[e]),c=(0,l.useMemo)(()=>new Set(e.people.map(e=>e.parent)),[e]);return(0,W.jsxs)(`div`,{ref:r,style:{maxWidth:`100%`,overflowX:`auto`,...z(n)},children:[(0,W.jsxs)(`svg`,{viewBox:`0 0 ${s.width} ${s.height}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:s.width,height:`auto`,margin:`0 auto`},children:[s.frames.map(({person:e,x:t,y:n,width:r,height:i})=>(0,W.jsx)(`foreignObject`,{x:t,y:n,width:r,height:i,children:(0,W.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:jn(e,c.has(e.id))}})},e.id)),s.links.map((e,t)=>(0,W.jsx)(`path`,{d:gn(e),fill:`none`,stroke:Cn.line,strokeWidth:`1.5`},t)),s.cards.map(({person:n,x:r,y:a,width:c,height:l})=>{let u=Array.isArray(t?.[n.id])&&t[n.id].length?t[n.id]:null,d={id:n.id,name:n.name,title:n.title,cv:n.description,photo:n.photo,profilePhoto:n.photo,href:n.link,profile:u},f=Ja(n.link),p=i&&(f||Ga(d)),m=()=>f?Ya(f):o(d);return(0,W.jsx)(`g`,{onClick:p?m:void 0,onKeyDown:p?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),m())}:void 0,tabIndex:p?0:void 0,style:p?{cursor:`pointer`}:void 0,role:p?f?`link`:`button`:void 0,"aria-label":p?f?`${n.name||n.title} — open link`:`Open ${n.name||n.title}'s profile`:void 0,children:(0,W.jsx)(`foreignObject`,{x:r,y:a,width:c,height:l,children:(0,W.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:An(n,e,s.size,Cn)}})})},n.id)})]}),a&&(0,W.jsx)(Za,{node:a,onClose:()=>o(null)})]})}function eo({nodes:e=[],source:t,nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c,groupTitles:u=`top`,groupBg:d=``,size:f=`medium`,horizontal:p=!1,columns:m=`off`,style:h,nodeRef:g,interactive:_=!0}){let v=(0,l.useId)(),[y,b]=(0,l.useState)(null),{tenant:x,apiUrl:S,revision:C}=(0,l.useContext)(G),w=(0,l.useContext)(Nn)?.[t],[T,E]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[C,t,x,S,w]);let D=t?Ka(w??T??[],{nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c}):e,O=Fa(f),{boxes:k,links:A,groups:j,width:M,height:N}=Ha(D,{size:f,horizontal:p,groupTitles:u,columns:m});if(!k.length)return!_&&t?(0,W.jsxs)(`div`,{ref:g,style:{padding:18,border:`1px dashed rgba(148, 163, 184, 0.6)`,borderRadius:10,fontSize:13,opacity:.7,textAlign:`center`,...z(h)},children:[`Org Chart — no published entries in “`,t,`” yet`]}):null;let P=new Set(k.filter(e=>e.node.parent==null||e.node.parent===``).map(e=>e.node.id));return(0,W.jsxs)(`div`,{ref:g,style:{maxWidth:`100%`,overflowX:`auto`,...z(h)},children:[(0,W.jsxs)(`svg`,{viewBox:`0 0 ${M} ${N}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:M,height:`auto`,margin:`0 auto`},children:[j.map((e,t)=>{let n=e.color||d||`rgba(148, 163, 184, 0.16)`,r=!!(e.color||d);return(0,W.jsxs)(`g`,{children:[(0,W.jsx)(`rect`,{x:e.x,y:e.y,width:e.width,height:e.height,rx:`16`,fill:n}),u!==`hidden`&&e.title&&(0,W.jsx)(`text`,{x:e.x+e.width/2,y:u===`bottom`?e.y+e.height-22*.42:e.y+22*.78,textAnchor:`middle`,fontSize:O.title+1,fontWeight:`600`,opacity:`0.55`,fill:r?Wa(e.color||d):`var(--page-text, #111827)`,children:Ua(e.title,Math.floor(e.width/7))})]},`group-${t}`)}),A.map((e,t)=>(0,W.jsx)(`path`,{d:Va(e),fill:`none`,stroke:`rgba(148, 163, 184, 0.7)`,strokeWidth:`1.5`},t)),k.map(({node:e,x:t,y:n})=>{let r=P.has(e.id),i=!!e.color2,a=!!e.color||r||i,o=e.color||(r?`var(--page-accent, #4f46e5)`:`var(--page-bg, #ffffff)`),s=e.color?Wa(e.color):r?`var(--page-accent-text, #ffffff)`:`var(--page-text, #111827)`,c=i?Wa(e.color2):s,l=Ja(e.href),u=_&&(l||Ga(e)),d=()=>l?Ya(l):b(e),f=e.photo?t+Xa.pad+O.avatar+8:t+O.w/2,p=e.photo?`start`:`middle`,m=e.photo?Math.floor((O.w-O.avatar-26)/7):Math.floor(O.w/7.6),h=O.h/2,g=[e.name,e.title].map(e=>String(e??``).trim()).filter(Boolean);return(0,W.jsxs)(`g`,{onClick:u?d:void 0,onKeyDown:u?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),d())}:void 0,tabIndex:u?0:void 0,style:u?{cursor:`pointer`}:void 0,role:u?l?`link`:`button`:void 0,"aria-label":u?l?`${e.name||e.title} — open link`:`Open ${e.name||e.title}'s profile`:void 0,children:[i&&e.gradient?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsxs)(`linearGradient`,{id:`${v}-${e.id}-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,W.jsx)(`stop`,{offset:`0%`,stopColor:e.color||`var(--page-accent, #4f46e5)`}),(0,W.jsx)(`stop`,{offset:`100%`,stopColor:e.color2})]}),(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:`url(#${v}-${e.id}-grad)`})]}):i?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`clipPath`,{id:`${v}-${e.id}-box`,children:(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`})}),(0,W.jsxs)(`g`,{clipPath:`url(#${v}-${e.id}-box)`,children:[(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:h,fill:o}),(0,W.jsx)(`rect`,{x:t,y:n+h,width:O.w,height:O.h-h,fill:e.color2})]})]}):(0,W.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:o,stroke:a?`none`:`var(--page-accent, #4f46e5)`,strokeWidth:a?0:1.5}),e.photo&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`clipPath`,{id:`${v}-${e.id}`,children:(0,W.jsx)(`circle`,{cx:t+Xa.pad+O.avatar/2,cy:n+O.h/2,r:O.avatar/2})}),(0,W.jsx)(`image`,{href:e.photo,x:t+Xa.pad,y:n+(O.h-O.avatar)/2,width:O.avatar,height:O.avatar,preserveAspectRatio:`xMidYMid slice`,clipPath:`url(#${v}-${e.id})`})]}),i&&!e.gradient?(0,W.jsxs)(W.Fragment,{children:[e.title&&(0,W.jsx)(`text`,{x:f,y:n+h/2+O.title*.35,textAnchor:p,fontSize:O.title,fontWeight:`600`,fill:s,children:Ua(e.title,m+4)}),e.name&&(0,W.jsx)(`text`,{x:f,y:n+h+h/2+O.name*.35,textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:c,children:Ua(e.name,m)})]}):(0,W.jsxs)(W.Fragment,{children:[g[0]&&(0,W.jsx)(`text`,{x:f,y:n+(g[1]?O.h*.43:O.h*.57),textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:s,children:Ua(g[0],m)}),g[1]&&(0,W.jsx)(`text`,{x:f,y:n+O.h*.73,textAnchor:p,fontSize:O.title,opacity:`0.7`,fill:s,children:Ua(g[1],m+4)})]})]},e.id)})]}),y&&(0,W.jsx)(Za,{node:y,onClose:()=>b(null)})]})}function to({value:e,onCommit:t,style:n,hint:r}){let[i,a]=(0,l.useState)(!1),o=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!i||!o.current)return;let e=o.current,t=document.createRange();e.focus(),t.selectNodeContents(e),t.collapse(!1);let n=window.getSelection();n.removeAllRanges(),n.addRange(t)},[i]),(0,W.jsx)(`span`,{ref:o,contentEditable:i,suppressContentEditableWarning:!0,title:i?void 0:r||`Double-click to edit`,onDoubleClick:()=>a(!0),onBlur:i?e=>{a(!1),t(e.currentTarget.textContent)}:void 0,onKeyDown:i?t=>{t.stopPropagation(),t.key===`Escape`&&(t.currentTarget.textContent=e??``,t.currentTarget.blur()),t.key===`Enter`&&(t.preventDefault(),t.currentTarget.blur())}:void 0,style:{display:`block`,minHeight:`1em`,outline:`none`,cursor:i?`text`:`inherit`,...n},children:e??``})}var no=360,ro=`
25
25
  .wb-tedit-btn {
26
26
  cursor: pointer;
27
27
  border-radius: 4px;
@@ -73,7 +73,7 @@ Error generating stack: `+e.message+`
73
73
  }
74
74
  .wb-tedit-sep { width: 1px; align-self: stretch; margin: 0 2px; background: rgba(148, 163, 184, 0.3); }
75
75
  .wb-tedit-at { font-size: 10px; color: #94a3b8; padding-right: 2px; }
76
- `,io=(e,t)=>e&&t?`cell-${e}-${t}`:``,J=e=>{if(!e||typeof e!=`object`)return e??``;let t=String(e.text??``);return typeof e.href==`string`&&e.href?(0,W.jsx)(`a`,{href:e.href,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #4f46e5)`},children:t}):t};function ao({columns:e=[],rows:t=[],widths:n=[],rowKeys:r=[],colKeys:i=[],heights:a=[],spans:o,linked:s,source:c,limit:u=10,header:d=!0,striped:f=!0,bordered:p=!1,compact:m=!1,padX:h,padY:g,paged:_,emptyText:v,stickyHeader:y,headerBg:b,headerColor:x,headerAlign:S,borderColor:C,maxHeight:w,caption:T=``,captionHidden:E=!1,rowHeaders:D=!1,style:O,nodeRef:k,edit:A}){let j=(0,l.useRef)(null),M=(0,l.useRef)(null),[N,P]=(0,l.useState)(null),[F,I]=(0,l.useState)(null),L=(e,t)=>()=>P({r:e,c:t});(0,l.useEffect)(()=>{if(!A)return;let e=M.current,t=N&&e?.querySelector(`[data-cell="${N.r}-${N.c}"]`);if(!t){F&&I(null);return}let n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i={top:r.bottom-n.top+4,left:Math.max(0,Math.min(r.left-n.left,n.width-no))};(F?.top!==i.top||F?.left!==i.left)&&I(i)}),(0,l.useEffect)(()=>{if(!A||!N)return;let e=e=>{M.current?.contains(e.target)||P(null)};return document.addEventListener(`mousedown`,e,!0),()=>document.removeEventListener(`mousedown`,e,!0)},[A,N]);let{tenant:R,apiUrl:ee,revision:te}=(0,l.useContext)(Nn),B=(0,l.useContext)(Pn),V=B?.[c],H=_?Fn(B):1,[ne,re]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!c||V)return;let e=!0,t=Math.max(1,Number(u)||10),n=_&&!c.startsWith(`api:`)?`?offset=${(H-1)*t}&limit=${t}`:``,r=c.startsWith(`api:`)?`${ee}/data/${encodeURIComponent(c.slice(4))}`:`${ee}/dynamic/${encodeURIComponent(c)}${n}`;return fetch(r,{headers:R?{"x-tenant":R}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&re(n)}).catch(()=>e&&re([])),()=>{e=!1}},[te,c,R,ee,V,_,H,u]),!e.length)return null;let ie=Math.max(1,Number(u)||10),ae=c?_?V||c.startsWith(`api:`)?(V??ne??[]).slice((H-1)*ie,H*ie):(ne??[]).slice(0,ie):(V??ne??[]).slice(0,ie):null,oe=ae?ae.map(t=>e.map(e=>Jn(Kn(t?.data,e.field)))):t,se=!!c&&!(c&&!V&&ne===null)&&oe.length===0,ce=m?{y:6,x:10}:{y:10,x:14},le=`${Number.isFinite(Number(g))&&g!==``?Number(g):ce.y}px ${Number.isFinite(Number(h))&&h!==``?Number(h):ce.x}px`,ue=`1px solid ${typeof C==`string`&&C?C:`rgba(148, 163, 184, 0.35)`}`,de=p?{border:ue}:{borderBottom:ue},fe=Array.isArray(n)&&n.length===e.length&&n.every(e=>Number.isFinite(e)&&e>0),pe=[`left`,`center`,`right`],me=t=>pe.includes(e[t]?.align)?e[t].align:``,he=e=>me(e)||(pe.includes(S)?S:`left`),ge=Number.isFinite(Number(w))&&Number(w)>0?Number(w):0,_e=z(O),ve=!ge&&_e&&_e.maxHeight!==void 0?_e.maxHeight:0,ye=ge||ve,be=ve?{..._e,maxHeight:void 0}:_e,xe=!!A&&A.rows!==!1,Se=t=>r=>{if(!A?.resize||t>=e.length-1)return;r.preventDefault(),r.stopPropagation();let i=j.current,a=i?i.clientWidth:0;if(!a)return;let o=fe?[...n]:e.map(()=>100/e.length),s=r.clientX,c=o[t]+o[t+1],l=e=>{let n=(e.clientX-s)/a*100,r=Math.min(c-5,Math.max(5,o[t]+n)),i=[...o];i[t]=Math.round(r*10)/10,i[t+1]=Math.round((c-r)*10)/10,A.resize(i)},u=()=>{window.removeEventListener(`pointermove`,l),window.removeEventListener(`pointerup`,u)};window.addEventListener(`pointermove`,l),window.addEventListener(`pointerup`,u)},Ce=new Set;o&&oe.forEach((t,n)=>e.forEach((e,t)=>{let a=o[io(r[n],i[t])];if(!a)return;let s=Math.max(1,Number(a.c)||1),c=Math.max(1,Number(a.r)||1);for(let e=0;e<c;e++)for(let r=0;r<s;r++)(e||r)&&Ce.add(`${n+e},${t+r}`)}));let we=e=>t=>{if(!A?.resizeRow)return;t.preventDefault(),t.stopPropagation();let n=t.currentTarget.closest(`tr`);if(!n)return;let r=t.clientY,i=n.offsetHeight,a=t=>A.resizeRow(e,Math.max(20,Math.round(i+(t.clientY-r)))),o=()=>{window.removeEventListener(`pointermove`,a),window.removeEventListener(`pointerup`,o)};window.addEventListener(`pointermove`,a),window.addEventListener(`pointerup`,o)},Te=(e,t,n,r)=>r?null:(0,W.jsx)(`span`,{className:`wb-tedit-btn`,role:`button`,"data-hint":t,onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:n,children:e},t),U=N&&N.r<oe.length&&N.c<e.length?N:null,Ee=(e,t)=>A?.labels?.[e]??t,De=U?o?.[io(r[U.r],i[U.c])]:null,Oe=Math.max(1,Number(De?.c)||1),ke=Math.max(1,Number(De?.r)||1);return(0,W.jsxs)(`div`,{ref:e=>{M.current=e,typeof k==`function`&&k(e)},style:{width:`100%`,...A?{position:`relative`}:null,...be},children:[A&&(0,W.jsx)(`style`,{children:ro}),A&&U&&F&&(0,W.jsxs)(`div`,{className:`wb-tedit-bar`,style:{top:F.top,left:F.left},onMouseDown:e=>e.stopPropagation(),children:[(0,W.jsx)(`span`,{className:`wb-tedit-at`,children:`R${U.r+1}·C${U.c+1}`}),Te(`+↑`,Ee(`rowAbove`,`Insert row above`),()=>A.addRow(U.r-1)),Te(`+↓`,Ee(`rowBelow`,`Insert row below`),()=>A.addRow(U.r)),Te(`↑`,Ee(`rowUp`,`Move row up`),()=>A.moveRow(U.r,-1),U.r===0),Te(`↓`,Ee(`rowDown`,`Move row down`),()=>A.moveRow(U.r,1),U.r>=oe.length-1),Te(`✕ row`,Ee(`rowDelete`,`Delete row`),()=>A.dropRow(U.r),oe.length<=1),(0,W.jsx)(`span`,{className:`wb-tedit-sep`}),Te(`+←`,Ee(`colLeft`,`Insert column left`),()=>A.addColumn(U.c-1)),Te(`+→`,Ee(`colRight`,`Insert column right`),()=>A.addColumn(U.c)),Te(`←`,Ee(`colMoveLeft`,`Move column left`),()=>A.moveColumn(U.c,-1),U.c===0),Te(`→`,Ee(`colMoveRight`,`Move column right`),()=>A.moveColumn(U.c,1),U.c>=e.length-1),Te(`✕ col`,Ee(`colDelete`,`Delete column`),()=>A.dropColumn(U.c),e.length<=1),(0,W.jsx)(`span`,{className:`wb-tedit-sep`}),Te(`↔`,Ee(`mergeRight`,`Merge with the cell on the right`),()=>A.merge(U.r,U.c,`right`),U.c+Oe>=e.length),Te(`↕`,Ee(`mergeDown`,`Merge with the cell below`),()=>A.merge(U.r,U.c,`down`),U.r+ke>=oe.length),Te(`⤫`,Ee(`split`,`Split this cell`),()=>A.split(U.r,U.c),Oe===1&&ke===1)]}),(0,W.jsx)(`div`,{style:{width:`100%`,overflowX:`auto`,...ye?{maxHeight:ye,overflowY:`auto`}:null},children:(0,W.jsxs)(`table`,{ref:j,...G(`table`),style:{width:`100%`,borderCollapse:y&&d!==!1?`separate`:`collapse`,borderSpacing:0,fontSize:14,...fe?{tableLayout:`fixed`}:null,...p?{border:ue}:{}},children:[typeof T==`string`&&T.trim()?(0,W.jsx)(`caption`,{...G(`caption`),style:E?Ze:{captionSide:`top`,textAlign:`left`,fontWeight:600,fontSize:15,padding:`0 0 8px`},children:T}):null,fe&&(0,W.jsx)(`colgroup`,{children:n.map((e,t)=>(0,W.jsx)(`col`,{style:{width:`${e}%`}},t))}),d===!1?null:(0,W.jsx)(`thead`,{children:(0,W.jsx)(`tr`,{...G(`header-row`),children:e.map((t,n)=>(0,W.jsx)(`th`,{...G(`header-cell`),scope:`col`,className:A?`wb-tedit-head`:void 0,style:{textAlign:he(n),fontWeight:600,padding:le,...typeof x==`string`&&x?{color:x}:null,background:typeof b==`string`&&b?b:y?`var(--page-surface, #f2f2f2)`:`rgba(148, 163, 184, 0.12)`,...y?{position:`sticky`,top:0,zIndex:2}:A?{position:`relative`}:null,...de},children:A?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(to,{value:t.label??t,onCommit:e=>A.header(n,e),hint:Ee(`editCell`,`Double-click to edit`),style:{paddingRight:6}}),n<e.length-1&&(0,W.jsx)(`span`,{className:`wb-tedit-grip`,title:Ee(`colWidth`,`Drag to resize the column`),onPointerDown:Se(n)})]}):t.label??t},n))})}),(0,W.jsxs)(`tbody`,{children:[se&&(0,W.jsx)(`tr`,{children:(0,W.jsx)(`td`,{colSpan:e.length,...G(`empty`),style:{padding:le,textAlign:`center`,opacity:.6,...de},children:v||`No data yet`})}),oe.map((t,n)=>(0,W.jsx)(`tr`,{...G(`row`,n%2==1&&`row-alt`),className:A?`wb-tedit-row`:void 0,style:{...f&&n%2==1?{background:`rgba(148, 163, 184, 0.07)`}:null,...Number.isFinite(Number(a?.[n]))&&a[n]>0?{height:a[n]}:null},children:e.map((e,a)=>{if(Ce.has(`${n},${a}`))return null;let c=io(r[n],i[a]),l=s?.[c],u=o?.[c],d=Math.max(1,Number(u?.c)||1),f=Math.max(1,Number(u?.r)||1),p=D&&a===0?`th`:`td`;return(0,W.jsxs)(p,{...G(`cell`,p===`th`&&`row-header`),scope:p===`th`?`row`:void 0,className:A?`wb-tedit-cell${N?.r===n&&N?.c===a?` wb-tedit-cellon`:``}`:void 0,onMouseDownCapture:xe?L(n,a):void 0,"data-cell":A?`${n}-${a}`:void 0,colSpan:d>1?d:void 0,rowSpan:f>1?f:void 0,style:{padding:le,...p===`th`?{textAlign:`left`,fontWeight:600}:null,...me(a)?{textAlign:me(a)}:null,...A?{position:`relative`}:null,...de},children:[l??J(t?.[a]),A&&xe&&(0,W.jsx)(`span`,{className:`wb-tedit-rowgrip`,title:Ee(`rowHeight`,`Drag to set the row height — double-click to fit the content`),onPointerDown:we(n),onDoubleClick:()=>A.resizeRow(n,0)})]},a)})},r[n]??n))]})]})})]})}var oo={small:{cell:62,font:10.5,head:11,title:15,pad:4,gap:2},medium:{cell:92,font:12,head:12,title:18,pad:6,gap:3},large:{cell:124,font:13,head:13,title:22,pad:8,gap:4}},so=e=>`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,`0`)}-${String(e.getDate()).padStart(2,`0`)}`,co=e=>new Date(e.getFullYear(),e.getMonth(),e.getDate()),lo=366;function uo(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:Jn(e),a=e=>{let t=i(r(e)),n=t?new Date(t):null;return n&&!Number.isNaN(n.getTime())?n:null};return n.map(e=>{let n=e.data??{},o=a(n[t.startField]);return o?{key:e.id,title:i(n[t.titleField||`name`])||i(n.name)||`Untitled`,start:o,end:a(n[t.endField]),href:t.hrefField?i(n[t.hrefField]):``,color:t.colorField?i(r(n[t.colorField])):``}:null}).filter(Boolean)}function fo(e){return(Array.isArray(e)?e:[]).map((e,t)=>{let n=e?.start?new Date(e.start):null;if(!n||Number.isNaN(n.getTime()))return null;let r=e?.end?new Date(e.end):null;return{key:e.key??`event-${t}`,title:e.title??``,start:n,end:r&&!Number.isNaN(r.getTime())?r:null,href:e.href??``,color:e.color??``}}).filter(Boolean)}function po(e){let t=new Map;for(let n of e){let e=co(n.start),r=n.end?co(n.end):e,i=Math.min(Math.max(0,Math.round((r-e)/864e5)),lo);for(let r=0;r<=i;r+=1){let i=so(new Date(e.getFullYear(),e.getMonth(),e.getDate()+r));t.has(i)||t.set(i,[]),t.get(i).push(n)}}for(let e of t.values())e.sort((e,t)=>e.start-t.start);return t}function mo({events:e=[],source:t=``,titleField:n=``,startField:r=``,endField:i=``,hrefField:a=``,colorField:o=``,variant:s=`month`,size:c=`medium`,accent:u=``,eventBg:d=``,eventText:f=``,borderColor:p=``,weekStart:m=`monday`,max:h=3,emptyText:g=`No events`,style:_,nodeRef:v,interactive:y=!0}){let{tenant:b,apiUrl:x,revision:S,locale:C}=(0,l.useContext)(Nn),w=(0,l.useContext)(Pn)?.[t],[T,E]=(0,l.useState)(null),[D,O]=(0,l.useState)(()=>{let e=new Date;return{year:e.getFullYear(),month:e.getMonth()}});(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${x}/dynamic/${encodeURIComponent(t)}`,{headers:b?{"x-tenant":b}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[S,t,b,x,w]);let k=oo[c]??oo.medium,A=u||`var(--page-accent, #4f46e5)`,j=p||`var(--page-border, rgba(148, 163, 184, 0.35))`,M=d||A,N=f||`var(--page-accent-text, #ffffff)`,P=t?uo(w??T??[],{titleField:n,startField:r,endField:i,hrefField:a,colorField:o}):fo(e),F=po(P),I=C||void 0,L=(e,t)=>{let n=(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`span`,{...G(`event-dot`),style:{width:6,height:6,borderRadius:`50%`,background:e.color||N,flexShrink:0,opacity:e.color?1:.85}}),(0,W.jsx)(`span`,{style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:e.title})]}),r={display:`flex`,alignItems:`center`,gap:5,background:e.color?`color-mix(in srgb, ${e.color} 18%, transparent)`:M,color:e.color?`inherit`:N,borderRadius:4,padding:`2px 5px`,fontSize:k.font,lineHeight:1.35,textDecoration:`none`,...t};return e.href&&y?(0,W.jsx)(`a`,{...G(`event`),href:e.href,style:r,title:e.title,children:n},e.key):(0,W.jsx)(`div`,{...G(`event`),style:r,title:e.title,children:n},e.key)},R=new Intl.DateTimeFormat(I,{month:`long`,year:`numeric`}).format(new Date(D.year,D.month,1)),ee=e=>O(t=>{let n=new Date(t.year,t.month+e,1);return{year:n.getFullYear(),month:n.getMonth()}}),te=(e,t)=>(0,W.jsx)(`button`,{type:`button`,"aria-label":e,...G(`nav-button`),onClick:()=>ee(t),style:{background:`transparent`,border:`1px solid ${j}`,borderRadius:6,color:`inherit`,cursor:`pointer`,fontSize:k.head,lineHeight:1,padding:`4px 8px`},children:t<0?`‹`:`›`}),B=(0,W.jsxs)(`div`,{...G(`header`),style:{display:`flex`,alignItems:`center`,gap:8,marginBottom:k.pad+2},children:[(0,W.jsx)(`div`,{...G(`month`),style:{fontSize:k.title,fontWeight:700,flexGrow:1,fontFamily:`var(--page-heading-font, inherit)`},children:R}),te(`Previous month`,-1),te(`Next month`,1)]});if(s===`list`){let e=P.filter(e=>e.start.getFullYear()===D.year&&e.start.getMonth()===D.month).sort((e,t)=>e.start-t.start),t=new Intl.DateTimeFormat(I,{day:`numeric`,month:`short`,hour:`2-digit`,minute:`2-digit`});return(0,W.jsxs)(`div`,{ref:v,style:{width:`100%`,...z(_)},children:[B,e.length?(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:k.gap+2},children:e.map(e=>(0,W.jsxs)(`div`,{...G(`agenda-row`),style:{display:`flex`,alignItems:`center`,gap:10,borderBottom:`1px solid ${j}`,paddingBottom:k.gap+2},children:[(0,W.jsx)(`span`,{...G(`agenda-date`),style:{fontSize:k.font,opacity:.7,minWidth:96},children:t.format(e.start)}),L(e,{flexGrow:1,minWidth:0})]},e.key))}):(0,W.jsx)(`div`,{...G(`empty`),style:{fontSize:k.font,opacity:.6,padding:k.pad*2},children:g})]})}let V=new Date(D.year,D.month,1),H=m===`sunday`?0:1,ne=(V.getDay()-H+7)%7,re=new Date(D.year,D.month+1,0).getDate(),ie=Math.ceil((ne+re)/7),ae=so(new Date),oe=new Intl.DateTimeFormat(I,{weekday:`short`}),se=[];for(let e=0;e<ie*7;e+=1){let t=e-ne+1,n=t>=1&&t<=re,r=so(new Date(D.year,D.month,t)),i=n?F.get(r)??[]:[],a=i.slice(0,Math.max(1,h)),o=n&&r===ae;se.push((0,W.jsxs)(`div`,{...G(`day`,!n&&`day-outside`,o&&`day-today`),style:{minHeight:k.cell,borderTop:`1px solid ${j}`,borderLeft:`1px solid ${j}`,padding:k.pad,display:`flex`,flexDirection:`column`,gap:k.gap,opacity:n?1:.35,minWidth:0},children:[(0,W.jsx)(`span`,{...G(`day-number`,o&&`day-number-today`),style:{fontSize:k.font,fontWeight:o?700:400,alignSelf:`flex-start`,borderRadius:`999px`,padding:o?`1px 6px`:0,background:o?A:`transparent`,color:o?N:`inherit`},children:n?t:new Date(D.year,D.month,t).getDate()}),a.map(e=>L(e)),i.length>a.length&&(0,W.jsx)(`span`,{...G(`more`),style:{fontSize:k.font,opacity:.6},children:`+${i.length-a.length}`})]},e))}return(0,W.jsxs)(`div`,{ref:v,style:{width:`100%`,...z(_)},children:[B,(0,W.jsxs)(`div`,{...G(`grid`),style:{display:`grid`,gridTemplateColumns:`repeat(7, minmax(0, 1fr))`},children:[Array.from({length:7},(e,t)=>(0,W.jsx)(`div`,{...G(`weekday`),style:{fontSize:k.head,fontWeight:600,opacity:.7,textAlign:`center`,padding:`0 0 ${k.pad}px`},children:oe.format(new Date(2024,0,7+H+t))},`head-${t}`)),se]}),(0,W.jsx)(`div`,{style:{borderTop:`1px solid ${j}`}})]})}var ho={small:36,medium:56,large:88};function go(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],r=e=>e==null?``:Jn(e);return n.map(e=>{let n=e.data??e,i=Kn(n,t.imageField),a=Array.isArray(i)?i[0]:i,o=a&&typeof a==`object`?a.url??a.src??``:a,s=t.nameField?r(Kn(n,t.nameField)):r(n.name);return{src:typeof o==`string`?o.trim():``,alt:s,href:t.hrefField?r(Kn(n,t.hrefField)):``}}).filter(e=>e.src)}function _o({logos:e=[],source:t=``,imageField:n=``,nameField:r=``,hrefField:i=``,variant:a=`step`,size:o=`medium`,perView:s=5,gap:c=48,hold:u=3,slideMs:d=500,direction:f=`left`,arrows:p=`show`,pauseOnHover:m=!0,grayscale:h=!0,newTab:g=!0,emptyText:_=``,style:v,nodeRef:y,inert:b}){let{tenant:x,apiUrl:S,revision:C,locale:w}=(0,l.useContext)(Nn),T=Xe(w),E=(0,l.useContext)(Pn)?.[t],[D,O]=(0,l.useState)(null),k=(0,l.useRef)(null),A=(0,l.useRef)(null),[j,M]=(0,l.useState)(0),[N,P]=(0,l.useState)(0),[F,I]=(0,l.useState)(0),[L,R]=(0,l.useState)(!0),[ee,te]=(0,l.useState)(!1),[B,V]=(0,l.useState)(!1),[H,ne]=(0,l.useState)(!1),[re,ie]=(0,l.useState)(!1);(0,l.useEffect)(()=>{if(!t||E)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&O(n)}).catch(()=>e&&O([])),()=>{e=!1}},[C,t,x,S,E]),(0,l.useEffect)(()=>{if(typeof window>`u`||!window.matchMedia)return;let e=window.matchMedia(`(prefers-reduced-motion: reduce)`),t=()=>ie(e.matches);return t(),e.addEventListener?.(`change`,t),()=>e.removeEventListener?.(`change`,t)},[]),(0,l.useEffect)(()=>{let e=A.current;if(!e)return;let t=()=>M(e.clientWidth);if(t(),typeof ResizeObserver>`u`)return;let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]),(0,l.useEffect)(()=>{let e=k.current;if(!e)return;let t=!0,n=()=>{let n=[...e.querySelectorAll(`img`)].filter(e=>e.complete&&e.naturalHeight).map(e=>e.naturalWidth/e.naturalHeight*se);t&&n.length&&P(Math.ceil(Math.max(...n)))};n();let r=[...e.querySelectorAll(`img`)].filter(e=>!e.complete);return r.forEach(e=>e.addEventListener(`load`,n)),()=>{t=!1,r.forEach(e=>e.removeEventListener(`load`,n))}});let ae=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],oe=t?go(E??D??[],{imageField:n,nameField:r,hrefField:i}):ae,se=ho[o]??ho.medium,ce=Number.isFinite(Number(c))?Math.max(0,Number(c)):48,le=a===`marquee`?`step`:a,ue=Math.min(3e4,Math.max(300,(Number(u)||3)*1e3)),de=Math.min(3e3,Math.max(100,Number(d)||500)),fe=Math.min(12,Math.max(1,Math.round(Number(s)||5))),pe=(N||se*3)+ce,me=j?Math.max(1,Math.floor(j/pe)):fe,he=Math.min(fe,me),ge=j?Math.min(pe,j/he):pe;if(!oe.length)return(0,W.jsx)(`div`,{ref:y,style:{width:`100%`,...z(v)},children:b?(0,W.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`center`,flexWrap:`wrap`,gap:ce},children:[0,1,2,3,4].map(e=>(0,W.jsx)(`div`,{style:{height:se,width:se*3,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.5))`,borderRadius:6,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:Math.max(10,Math.round(se/4)),opacity:.45,...U},children:`LOGO`},e))}):_?(0,W.jsx)(`div`,{...G(`empty`),style:{fontSize:13,opacity:.6,textAlign:`center`,padding:16},children:_}):null});let _e=oe.length,ve=le===`step`&&_e>he,ye=le===`slider`,be=ve&&!b&&!ee&&!B&&!H&&!re,xe=f===`right`,Se=xe?_e:0,Ce=ve?[...oe,...oe]:oe,we=ve?F*ge:0,Te=(e,t,n)=>{let r=(0,W.jsx)(`img`,{...G(`logo`),src:e.src,alt:e.alt??``,style:{height:se,width:`auto`,maxWidth:`100%`,objectFit:`contain`,display:`block`}}),i=ve?{width:ge,flex:`0 0 auto`,padding:`0 ${ce/2}px`,justifyContent:`center`}:{};return e.href&&!b?(0,W.jsx)(`a`,{href:e.href,...G(`item`),className:`wb-logo`,title:e.alt||void 0,style:i,...g===!1?{}:{target:`_blank`,rel:`noopener noreferrer`},...n?{"aria-hidden":`true`,tabIndex:-1}:{},children:r},`${n?`c`:`o`}-${t}`):(0,W.jsx)(`div`,{...G(`item`),className:`wb-logo`,style:i,...n?{"aria-hidden":`true`}:{},children:r},`${n?`c`:`o`}-${t}`)},Ee=(0,W.jsx)(`div`,{ref:k,...G(`track`),className:`wb-logos-track`,style:{display:`flex`,alignItems:`center`,...ve?{width:Ce.length*ge,transform:`translateX(-${we}px)`,transition:L?`transform ${de}ms ease`:`none`}:ye?{gap:ce,overflowX:`auto`,scrollBehavior:`smooth`,scrollSnapType:`x proximity`}:{gap:ce,flexWrap:`wrap`,justifyContent:`center`}},children:Ce.map((e,t)=>Te(e,t,ve&&t>=_e))}),De=e=>{if(ye){let t=k.current;t&&t.scrollBy({left:e*Math.max(120,t.clientWidth*.8),behavior:`smooth`});return}let t=F+e;if(t>=0&&t<=_e){R(!0),I(t);return}let n=t<0?_e:0;R(!1),I(n),requestAnimationFrame(()=>requestAnimationFrame(()=>{R(!0),I(n+e)}))},Oe=p===!1||p===`off`?`off`:p===`hover`?`hover`:`show`,ke=Oe!==`off`&&(ye?j>0:ve),Ae=e=>(0,W.jsx)(`button`,{type:`button`,"aria-label":T(e<0?`prevLogos`:`nextLogos`),...G(`arrow`,e<0?`arrow-prev`:`arrow-next`),onClick:()=>De(e),className:`wb-logos-arrow${Oe===`hover`?` wb-logos-arrow-shy`:``}`,style:{[e<0?`left`:`right`]:0},children:e<0?`‹`:`›`});return(0,W.jsxs)(`div`,{ref:e=>{A.current=e,y&&y(e)},className:`wb-logos`,style:{width:`100%`,position:`relative`,overflow:`hidden`,...z(v)},onMouseEnter:m===!1?void 0:()=>te(!0),onMouseLeave:m===!1?void 0:()=>te(!1),onFocus:()=>V(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||V(!1)},children:[(0,W.jsx)(`style`,{children:`
76
+ `,io=(e,t)=>e&&t?`cell-${e}-${t}`:``,J=e=>{if(!e||typeof e!=`object`)return e??``;let t=String(e.text??``);return typeof e.href==`string`&&e.href?(0,W.jsx)(`a`,{href:e.href,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #4f46e5)`},children:t}):t};function ao({columns:e=[],rows:t=[],widths:n=[],rowKeys:r=[],colKeys:i=[],heights:a=[],spans:o,linked:s,source:c,limit:u=10,header:d=!0,striped:f=!0,bordered:p=!1,compact:m=!1,padX:h,padY:g,paged:_,emptyText:v,stickyHeader:y,headerBg:b,headerColor:x,headerAlign:S,borderColor:C,maxHeight:w,caption:T=``,captionHidden:E=!1,rowHeaders:D=!1,style:O,nodeRef:k,edit:A}){let j=(0,l.useRef)(null),M=(0,l.useRef)(null),[N,P]=(0,l.useState)(null),[F,I]=(0,l.useState)(null),L=(e,t)=>()=>P({r:e,c:t});(0,l.useEffect)(()=>{if(!A)return;let e=M.current,t=N&&e?.querySelector(`[data-cell="${N.r}-${N.c}"]`);if(!t){F&&I(null);return}let n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i={top:r.bottom-n.top+4,left:Math.max(0,Math.min(r.left-n.left,n.width-no))};(F?.top!==i.top||F?.left!==i.left)&&I(i)}),(0,l.useEffect)(()=>{if(!A||!N)return;let e=e=>{M.current?.contains(e.target)||P(null)};return document.addEventListener(`mousedown`,e,!0),()=>document.removeEventListener(`mousedown`,e,!0)},[A,N]);let{tenant:R,apiUrl:ee,revision:te}=(0,l.useContext)(G),B=(0,l.useContext)(Nn),V=B?.[c],H=_?Pn(B):1,[ne,re]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!c||V)return;let e=!0,t=Math.max(1,Number(u)||10),n=_&&!c.startsWith(`api:`)?`?offset=${(H-1)*t}&limit=${t}`:``,r=c.startsWith(`api:`)?`${ee}/data/${encodeURIComponent(c.slice(4))}`:`${ee}/dynamic/${encodeURIComponent(c)}${n}`;return fetch(r,{headers:R?{"x-tenant":R}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&re(n)}).catch(()=>e&&re([])),()=>{e=!1}},[te,c,R,ee,V,_,H,u]),!e.length)return null;let ie=Math.max(1,Number(u)||10),ae=c?_?V||c.startsWith(`api:`)?(V??ne??[]).slice((H-1)*ie,H*ie):(ne??[]).slice(0,ie):(V??ne??[]).slice(0,ie):null,oe=ae?ae.map(t=>e.map(e=>qn(Gn(t?.data,e.field)))):t,se=!!c&&!(c&&!V&&ne===null)&&oe.length===0,ce=m?{y:6,x:10}:{y:10,x:14},le=`${Number.isFinite(Number(g))&&g!==``?Number(g):ce.y}px ${Number.isFinite(Number(h))&&h!==``?Number(h):ce.x}px`,ue=`1px solid ${typeof C==`string`&&C?C:`rgba(148, 163, 184, 0.35)`}`,de=p?{border:ue}:{borderBottom:ue},fe=Array.isArray(n)&&n.length===e.length&&n.every(e=>Number.isFinite(e)&&e>0),pe=[`left`,`center`,`right`],me=t=>pe.includes(e[t]?.align)?e[t].align:``,he=e=>me(e)||(pe.includes(S)?S:`left`),ge=Number.isFinite(Number(w))&&Number(w)>0?Number(w):0,_e=z(O),ve=!ge&&_e&&_e.maxHeight!==void 0?_e.maxHeight:0,ye=ge||ve,be=ve?{..._e,maxHeight:void 0}:_e,xe=!!A&&A.rows!==!1,Se=t=>r=>{if(!A?.resize||t>=e.length-1)return;r.preventDefault(),r.stopPropagation();let i=j.current,a=i?i.clientWidth:0;if(!a)return;let o=fe?[...n]:e.map(()=>100/e.length),s=r.clientX,c=o[t]+o[t+1],l=e=>{let n=(e.clientX-s)/a*100,r=Math.min(c-5,Math.max(5,o[t]+n)),i=[...o];i[t]=Math.round(r*10)/10,i[t+1]=Math.round((c-r)*10)/10,A.resize(i)},u=()=>{window.removeEventListener(`pointermove`,l),window.removeEventListener(`pointerup`,u)};window.addEventListener(`pointermove`,l),window.addEventListener(`pointerup`,u)},Ce=new Set;o&&oe.forEach((t,n)=>e.forEach((e,t)=>{let a=o[io(r[n],i[t])];if(!a)return;let s=Math.max(1,Number(a.c)||1),c=Math.max(1,Number(a.r)||1);for(let e=0;e<c;e++)for(let r=0;r<s;r++)(e||r)&&Ce.add(`${n+e},${t+r}`)}));let we=e=>t=>{if(!A?.resizeRow)return;t.preventDefault(),t.stopPropagation();let n=t.currentTarget.closest(`tr`);if(!n)return;let r=t.clientY,i=n.offsetHeight,a=t=>A.resizeRow(e,Math.max(20,Math.round(i+(t.clientY-r)))),o=()=>{window.removeEventListener(`pointermove`,a),window.removeEventListener(`pointerup`,o)};window.addEventListener(`pointermove`,a),window.addEventListener(`pointerup`,o)},Te=(e,t,n,r)=>r?null:(0,W.jsx)(`span`,{className:`wb-tedit-btn`,role:`button`,"data-hint":t,onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:n,children:e},t),U=N&&N.r<oe.length&&N.c<e.length?N:null,Ee=(e,t)=>A?.labels?.[e]??t,De=U?o?.[io(r[U.r],i[U.c])]:null,Oe=Math.max(1,Number(De?.c)||1),ke=Math.max(1,Number(De?.r)||1);return(0,W.jsxs)(`div`,{ref:e=>{M.current=e,typeof k==`function`&&k(e)},style:{width:`100%`,...A?{position:`relative`}:null,...be},children:[A&&(0,W.jsx)(`style`,{children:ro}),A&&U&&F&&(0,W.jsxs)(`div`,{className:`wb-tedit-bar`,style:{top:F.top,left:F.left},onMouseDown:e=>e.stopPropagation(),children:[(0,W.jsx)(`span`,{className:`wb-tedit-at`,children:`R${U.r+1}·C${U.c+1}`}),Te(`+↑`,Ee(`rowAbove`,`Insert row above`),()=>A.addRow(U.r-1)),Te(`+↓`,Ee(`rowBelow`,`Insert row below`),()=>A.addRow(U.r)),Te(`↑`,Ee(`rowUp`,`Move row up`),()=>A.moveRow(U.r,-1),U.r===0),Te(`↓`,Ee(`rowDown`,`Move row down`),()=>A.moveRow(U.r,1),U.r>=oe.length-1),Te(`✕ row`,Ee(`rowDelete`,`Delete row`),()=>A.dropRow(U.r),oe.length<=1),(0,W.jsx)(`span`,{className:`wb-tedit-sep`}),Te(`+←`,Ee(`colLeft`,`Insert column left`),()=>A.addColumn(U.c-1)),Te(`+→`,Ee(`colRight`,`Insert column right`),()=>A.addColumn(U.c)),Te(`←`,Ee(`colMoveLeft`,`Move column left`),()=>A.moveColumn(U.c,-1),U.c===0),Te(`→`,Ee(`colMoveRight`,`Move column right`),()=>A.moveColumn(U.c,1),U.c>=e.length-1),Te(`✕ col`,Ee(`colDelete`,`Delete column`),()=>A.dropColumn(U.c),e.length<=1),(0,W.jsx)(`span`,{className:`wb-tedit-sep`}),Te(`↔`,Ee(`mergeRight`,`Merge with the cell on the right`),()=>A.merge(U.r,U.c,`right`),U.c+Oe>=e.length),Te(`↕`,Ee(`mergeDown`,`Merge with the cell below`),()=>A.merge(U.r,U.c,`down`),U.r+ke>=oe.length),Te(`⤫`,Ee(`split`,`Split this cell`),()=>A.split(U.r,U.c),Oe===1&&ke===1)]}),(0,W.jsx)(`div`,{style:{width:`100%`,overflowX:`auto`,...ye?{maxHeight:ye,overflowY:`auto`}:null},children:(0,W.jsxs)(`table`,{ref:j,...K(`table`),style:{width:`100%`,borderCollapse:y&&d!==!1?`separate`:`collapse`,borderSpacing:0,fontSize:14,...fe?{tableLayout:`fixed`}:null,...p?{border:ue}:{}},children:[typeof T==`string`&&T.trim()?(0,W.jsx)(`caption`,{...K(`caption`),style:E?Ze:{captionSide:`top`,textAlign:`left`,fontWeight:600,fontSize:15,padding:`0 0 8px`},children:T}):null,fe&&(0,W.jsx)(`colgroup`,{children:n.map((e,t)=>(0,W.jsx)(`col`,{style:{width:`${e}%`}},t))}),d===!1?null:(0,W.jsx)(`thead`,{children:(0,W.jsx)(`tr`,{...K(`header-row`),children:e.map((t,n)=>(0,W.jsx)(`th`,{...K(`header-cell`),scope:`col`,className:A?`wb-tedit-head`:void 0,style:{textAlign:he(n),fontWeight:600,padding:le,...typeof x==`string`&&x?{color:x}:null,background:typeof b==`string`&&b?b:y?`var(--page-surface, #f2f2f2)`:`rgba(148, 163, 184, 0.12)`,...y?{position:`sticky`,top:0,zIndex:2}:A?{position:`relative`}:null,...de},children:A?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(to,{value:t.label??t,onCommit:e=>A.header(n,e),hint:Ee(`editCell`,`Double-click to edit`),style:{paddingRight:6}}),n<e.length-1&&(0,W.jsx)(`span`,{className:`wb-tedit-grip`,title:Ee(`colWidth`,`Drag to resize the column`),onPointerDown:Se(n)})]}):t.label??t},n))})}),(0,W.jsxs)(`tbody`,{children:[se&&(0,W.jsx)(`tr`,{children:(0,W.jsx)(`td`,{colSpan:e.length,...K(`empty`),style:{padding:le,textAlign:`center`,opacity:.6,...de},children:v||`No data yet`})}),oe.map((t,n)=>(0,W.jsx)(`tr`,{...K(`row`,n%2==1&&`row-alt`),className:A?`wb-tedit-row`:void 0,style:{...f&&n%2==1?{background:`rgba(148, 163, 184, 0.07)`}:null,...Number.isFinite(Number(a?.[n]))&&a[n]>0?{height:a[n]}:null},children:e.map((e,a)=>{if(Ce.has(`${n},${a}`))return null;let c=io(r[n],i[a]),l=s?.[c],u=o?.[c],d=Math.max(1,Number(u?.c)||1),f=Math.max(1,Number(u?.r)||1),p=D&&a===0?`th`:`td`;return(0,W.jsxs)(p,{...K(`cell`,p===`th`&&`row-header`),scope:p===`th`?`row`:void 0,className:A?`wb-tedit-cell${N?.r===n&&N?.c===a?` wb-tedit-cellon`:``}`:void 0,onMouseDownCapture:xe?L(n,a):void 0,"data-cell":A?`${n}-${a}`:void 0,colSpan:d>1?d:void 0,rowSpan:f>1?f:void 0,style:{padding:le,...p===`th`?{textAlign:`left`,fontWeight:600}:null,...me(a)?{textAlign:me(a)}:null,...A?{position:`relative`}:null,...de},children:[l??J(t?.[a]),A&&xe&&(0,W.jsx)(`span`,{className:`wb-tedit-rowgrip`,title:Ee(`rowHeight`,`Drag to set the row height — double-click to fit the content`),onPointerDown:we(n),onDoubleClick:()=>A.resizeRow(n,0)})]},a)})},r[n]??n))]})]})})]})}var oo={small:{cell:62,font:10.5,head:11,title:15,pad:4,gap:2},medium:{cell:92,font:12,head:12,title:18,pad:6,gap:3},large:{cell:124,font:13,head:13,title:22,pad:8,gap:4}},so=e=>`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,`0`)}-${String(e.getDate()).padStart(2,`0`)}`,co=e=>new Date(e.getFullYear(),e.getMonth(),e.getDate()),lo=366;function uo(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:qn(e),a=e=>{let t=i(r(e)),n=t?new Date(t):null;return n&&!Number.isNaN(n.getTime())?n:null};return n.map(e=>{let n=e.data??{},o=a(n[t.startField]);return o?{key:e.id,title:i(n[t.titleField||`name`])||i(n.name)||`Untitled`,start:o,end:a(n[t.endField]),href:t.hrefField?i(n[t.hrefField]):``,color:t.colorField?i(r(n[t.colorField])):``}:null}).filter(Boolean)}function fo(e){return(Array.isArray(e)?e:[]).map((e,t)=>{let n=e?.start?new Date(e.start):null;if(!n||Number.isNaN(n.getTime()))return null;let r=e?.end?new Date(e.end):null;return{key:e.key??`event-${t}`,title:e.title??``,start:n,end:r&&!Number.isNaN(r.getTime())?r:null,href:e.href??``,color:e.color??``}}).filter(Boolean)}function po(e){let t=new Map;for(let n of e){let e=co(n.start),r=n.end?co(n.end):e,i=Math.min(Math.max(0,Math.round((r-e)/864e5)),lo);for(let r=0;r<=i;r+=1){let i=so(new Date(e.getFullYear(),e.getMonth(),e.getDate()+r));t.has(i)||t.set(i,[]),t.get(i).push(n)}}for(let e of t.values())e.sort((e,t)=>e.start-t.start);return t}function mo({events:e=[],source:t=``,titleField:n=``,startField:r=``,endField:i=``,hrefField:a=``,colorField:o=``,variant:s=`month`,size:c=`medium`,accent:u=``,eventBg:d=``,eventText:f=``,borderColor:p=``,weekStart:m=`monday`,max:h=3,emptyText:g=`No events`,style:_,nodeRef:v,interactive:y=!0}){let{tenant:b,apiUrl:x,revision:S,locale:C}=(0,l.useContext)(G),w=(0,l.useContext)(Nn)?.[t],[T,E]=(0,l.useState)(null),[D,O]=(0,l.useState)(()=>{let e=new Date;return{year:e.getFullYear(),month:e.getMonth()}});(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${x}/dynamic/${encodeURIComponent(t)}`,{headers:b?{"x-tenant":b}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[S,t,b,x,w]);let k=oo[c]??oo.medium,A=u||`var(--page-accent, #4f46e5)`,j=p||`var(--page-border, rgba(148, 163, 184, 0.35))`,M=d||A,N=f||`var(--page-accent-text, #ffffff)`,P=t?uo(w??T??[],{titleField:n,startField:r,endField:i,hrefField:a,colorField:o}):fo(e),F=po(P),I=C||void 0,L=(e,t)=>{let n=(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`span`,{...K(`event-dot`),style:{width:6,height:6,borderRadius:`50%`,background:e.color||N,flexShrink:0,opacity:e.color?1:.85}}),(0,W.jsx)(`span`,{style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:e.title})]}),r={display:`flex`,alignItems:`center`,gap:5,background:e.color?`color-mix(in srgb, ${e.color} 18%, transparent)`:M,color:e.color?`inherit`:N,borderRadius:4,padding:`2px 5px`,fontSize:k.font,lineHeight:1.35,textDecoration:`none`,...t};return e.href&&y?(0,W.jsx)(`a`,{...K(`event`),href:e.href,style:r,title:e.title,children:n},e.key):(0,W.jsx)(`div`,{...K(`event`),style:r,title:e.title,children:n},e.key)},R=new Intl.DateTimeFormat(I,{month:`long`,year:`numeric`}).format(new Date(D.year,D.month,1)),ee=e=>O(t=>{let n=new Date(t.year,t.month+e,1);return{year:n.getFullYear(),month:n.getMonth()}}),te=(e,t)=>(0,W.jsx)(`button`,{type:`button`,"aria-label":e,...K(`nav-button`),onClick:()=>ee(t),style:{background:`transparent`,border:`1px solid ${j}`,borderRadius:6,color:`inherit`,cursor:`pointer`,fontSize:k.head,lineHeight:1,padding:`4px 8px`},children:t<0?`‹`:`›`}),B=(0,W.jsxs)(`div`,{...K(`header`),style:{display:`flex`,alignItems:`center`,gap:8,marginBottom:k.pad+2},children:[(0,W.jsx)(`div`,{...K(`month`),style:{fontSize:k.title,fontWeight:700,flexGrow:1,fontFamily:`var(--page-heading-font, inherit)`},children:R}),te(`Previous month`,-1),te(`Next month`,1)]});if(s===`list`){let e=P.filter(e=>e.start.getFullYear()===D.year&&e.start.getMonth()===D.month).sort((e,t)=>e.start-t.start),t=new Intl.DateTimeFormat(I,{day:`numeric`,month:`short`,hour:`2-digit`,minute:`2-digit`});return(0,W.jsxs)(`div`,{ref:v,style:{width:`100%`,...z(_)},children:[B,e.length?(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:k.gap+2},children:e.map(e=>(0,W.jsxs)(`div`,{...K(`agenda-row`),style:{display:`flex`,alignItems:`center`,gap:10,borderBottom:`1px solid ${j}`,paddingBottom:k.gap+2},children:[(0,W.jsx)(`span`,{...K(`agenda-date`),style:{fontSize:k.font,opacity:.7,minWidth:96},children:t.format(e.start)}),L(e,{flexGrow:1,minWidth:0})]},e.key))}):(0,W.jsx)(`div`,{...K(`empty`),style:{fontSize:k.font,opacity:.6,padding:k.pad*2},children:g})]})}let V=new Date(D.year,D.month,1),H=m===`sunday`?0:1,ne=(V.getDay()-H+7)%7,re=new Date(D.year,D.month+1,0).getDate(),ie=Math.ceil((ne+re)/7),ae=so(new Date),oe=new Intl.DateTimeFormat(I,{weekday:`short`}),se=[];for(let e=0;e<ie*7;e+=1){let t=e-ne+1,n=t>=1&&t<=re,r=so(new Date(D.year,D.month,t)),i=n?F.get(r)??[]:[],a=i.slice(0,Math.max(1,h)),o=n&&r===ae;se.push((0,W.jsxs)(`div`,{...K(`day`,!n&&`day-outside`,o&&`day-today`),style:{minHeight:k.cell,borderTop:`1px solid ${j}`,borderLeft:`1px solid ${j}`,padding:k.pad,display:`flex`,flexDirection:`column`,gap:k.gap,opacity:n?1:.35,minWidth:0},children:[(0,W.jsx)(`span`,{...K(`day-number`,o&&`day-number-today`),style:{fontSize:k.font,fontWeight:o?700:400,alignSelf:`flex-start`,borderRadius:`999px`,padding:o?`1px 6px`:0,background:o?A:`transparent`,color:o?N:`inherit`},children:n?t:new Date(D.year,D.month,t).getDate()}),a.map(e=>L(e)),i.length>a.length&&(0,W.jsx)(`span`,{...K(`more`),style:{fontSize:k.font,opacity:.6},children:`+${i.length-a.length}`})]},e))}return(0,W.jsxs)(`div`,{ref:v,style:{width:`100%`,...z(_)},children:[B,(0,W.jsxs)(`div`,{...K(`grid`),style:{display:`grid`,gridTemplateColumns:`repeat(7, minmax(0, 1fr))`},children:[Array.from({length:7},(e,t)=>(0,W.jsx)(`div`,{...K(`weekday`),style:{fontSize:k.head,fontWeight:600,opacity:.7,textAlign:`center`,padding:`0 0 ${k.pad}px`},children:oe.format(new Date(2024,0,7+H+t))},`head-${t}`)),se]}),(0,W.jsx)(`div`,{style:{borderTop:`1px solid ${j}`}})]})}var ho={small:36,medium:56,large:88};function go(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],r=e=>e==null?``:qn(e);return n.map(e=>{let n=e.data??e,i=Gn(n,t.imageField),a=Array.isArray(i)?i[0]:i,o=a&&typeof a==`object`?a.url??a.src??``:a,s=t.nameField?r(Gn(n,t.nameField)):r(n.name);return{src:typeof o==`string`?o.trim():``,alt:s,href:t.hrefField?r(Gn(n,t.hrefField)):``}}).filter(e=>e.src)}function _o({logos:e=[],source:t=``,imageField:n=``,nameField:r=``,hrefField:i=``,variant:a=`step`,size:o=`medium`,perView:s=5,gap:c=48,hold:u=3,slideMs:d=500,direction:f=`left`,arrows:p=`show`,pauseOnHover:m=!0,grayscale:h=!0,newTab:g=!0,emptyText:_=``,style:v,nodeRef:y,inert:b}){let{tenant:x,apiUrl:S,revision:C,locale:w}=(0,l.useContext)(G),T=Xe(w),E=(0,l.useContext)(Nn)?.[t],[D,O]=(0,l.useState)(null),k=(0,l.useRef)(null),A=(0,l.useRef)(null),[j,M]=(0,l.useState)(0),[N,P]=(0,l.useState)(0),[F,I]=(0,l.useState)(0),[L,R]=(0,l.useState)(!0),[ee,te]=(0,l.useState)(!1),[B,V]=(0,l.useState)(!1),[H,ne]=(0,l.useState)(!1),[re,ie]=(0,l.useState)(!1);(0,l.useEffect)(()=>{if(!t||E)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&O(n)}).catch(()=>e&&O([])),()=>{e=!1}},[C,t,x,S,E]),(0,l.useEffect)(()=>{if(typeof window>`u`||!window.matchMedia)return;let e=window.matchMedia(`(prefers-reduced-motion: reduce)`),t=()=>ie(e.matches);return t(),e.addEventListener?.(`change`,t),()=>e.removeEventListener?.(`change`,t)},[]),(0,l.useEffect)(()=>{let e=A.current;if(!e)return;let t=()=>M(e.clientWidth);if(t(),typeof ResizeObserver>`u`)return;let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]),(0,l.useEffect)(()=>{let e=k.current;if(!e)return;let t=!0,n=()=>{let n=[...e.querySelectorAll(`img`)].filter(e=>e.complete&&e.naturalHeight).map(e=>e.naturalWidth/e.naturalHeight*se);t&&n.length&&P(Math.ceil(Math.max(...n)))};n();let r=[...e.querySelectorAll(`img`)].filter(e=>!e.complete);return r.forEach(e=>e.addEventListener(`load`,n)),()=>{t=!1,r.forEach(e=>e.removeEventListener(`load`,n))}});let ae=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],oe=t?go(E??D??[],{imageField:n,nameField:r,hrefField:i}):ae,se=ho[o]??ho.medium,ce=Number.isFinite(Number(c))?Math.max(0,Number(c)):48,le=a===`marquee`?`step`:a,ue=Math.min(3e4,Math.max(300,(Number(u)||3)*1e3)),de=Math.min(3e3,Math.max(100,Number(d)||500)),fe=Math.min(12,Math.max(1,Math.round(Number(s)||5))),pe=(N||se*3)+ce,me=j?Math.max(1,Math.floor(j/pe)):fe,he=Math.min(fe,me),ge=j?Math.min(pe,j/he):pe;if(!oe.length)return(0,W.jsx)(`div`,{ref:y,style:{width:`100%`,...z(v)},children:b?(0,W.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`center`,flexWrap:`wrap`,gap:ce},children:[0,1,2,3,4].map(e=>(0,W.jsx)(`div`,{style:{height:se,width:se*3,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.5))`,borderRadius:6,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:Math.max(10,Math.round(se/4)),opacity:.45,...U},children:`LOGO`},e))}):_?(0,W.jsx)(`div`,{...K(`empty`),style:{fontSize:13,opacity:.6,textAlign:`center`,padding:16},children:_}):null});let _e=oe.length,ve=le===`step`&&_e>he,ye=le===`slider`,be=ve&&!b&&!ee&&!B&&!H&&!re,xe=f===`right`,Se=xe?_e:0,Ce=ve?[...oe,...oe]:oe,we=ve?F*ge:0,Te=(e,t,n)=>{let r=(0,W.jsx)(`img`,{...K(`logo`),src:e.src,alt:e.alt??``,style:{height:se,width:`auto`,maxWidth:`100%`,objectFit:`contain`,display:`block`}}),i=ve?{width:ge,flex:`0 0 auto`,padding:`0 ${ce/2}px`,justifyContent:`center`}:{};return e.href&&!b?(0,W.jsx)(`a`,{href:e.href,...K(`item`),className:`wb-logo`,title:e.alt||void 0,style:i,...g===!1?{}:{target:`_blank`,rel:`noopener noreferrer`},...n?{"aria-hidden":`true`,tabIndex:-1}:{},children:r},`${n?`c`:`o`}-${t}`):(0,W.jsx)(`div`,{...K(`item`),className:`wb-logo`,style:i,...n?{"aria-hidden":`true`}:{},children:r},`${n?`c`:`o`}-${t}`)},Ee=(0,W.jsx)(`div`,{ref:k,...K(`track`),className:`wb-logos-track`,style:{display:`flex`,alignItems:`center`,...ve?{width:Ce.length*ge,transform:`translateX(-${we}px)`,transition:L?`transform ${de}ms ease`:`none`}:ye?{gap:ce,overflowX:`auto`,scrollBehavior:`smooth`,scrollSnapType:`x proximity`}:{gap:ce,flexWrap:`wrap`,justifyContent:`center`}},children:Ce.map((e,t)=>Te(e,t,ve&&t>=_e))}),De=e=>{if(ye){let t=k.current;t&&t.scrollBy({left:e*Math.max(120,t.clientWidth*.8),behavior:`smooth`});return}let t=F+e;if(t>=0&&t<=_e){R(!0),I(t);return}let n=t<0?_e:0;R(!1),I(n),requestAnimationFrame(()=>requestAnimationFrame(()=>{R(!0),I(n+e)}))},Oe=p===!1||p===`off`?`off`:p===`hover`?`hover`:`show`,ke=Oe!==`off`&&(ye?j>0:ve),Ae=e=>(0,W.jsx)(`button`,{type:`button`,"aria-label":T(e<0?`prevLogos`:`nextLogos`),...K(`arrow`,e<0?`arrow-prev`:`arrow-next`),onClick:()=>De(e),className:`wb-logos-arrow${Oe===`hover`?` wb-logos-arrow-shy`:``}`,style:{[e<0?`left`:`right`]:0},children:e<0?`‹`:`›`});return(0,W.jsxs)(`div`,{ref:e=>{A.current=e,y&&y(e)},className:`wb-logos`,style:{width:`100%`,position:`relative`,overflow:`hidden`,...z(v)},onMouseEnter:m===!1?void 0:()=>te(!0),onMouseLeave:m===!1?void 0:()=>te(!1),onFocus:()=>V(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||V(!1)},children:[(0,W.jsx)(`style`,{children:`
77
77
  .wb-logos .wb-logo { display: flex; align-items: center; flex-shrink: 0; text-decoration: none; box-sizing: border-box; }
78
78
  .wb-logos .wb-logo img { filter: ${h===!1?`none`:`grayscale(1)`}; opacity: ${h===!1?1:.7}; transition: filter .2s ease, opacity .2s ease; }
79
79
  .wb-logos .wb-logo:hover img { filter: none; opacity: 1; }
@@ -99,16 +99,16 @@ Error generating stack: `+e.message+`
99
99
  color: inherit; background: var(--page-surface, #f2f2f2);
100
100
  border: 1px solid var(--page-border, rgba(148, 163, 184, 0.5));
101
101
  }
102
- `}),ve?(0,W.jsxs)(`div`,{style:{position:`relative`,width:he*ge,maxWidth:`100%`,margin:`0 auto`},children:[ke?Ae(-1):null,(0,W.jsx)(`div`,{style:{overflow:`hidden`},children:Ee}),ke?Ae(1):null]}):(0,W.jsxs)(W.Fragment,{children:[ke?Ae(-1):null,Ee,ke?Ae(1):null]}),ve&&!b&&!re&&(0,W.jsx)(`button`,{type:`button`,...G(`pause`,H&&`pause-stopped`),className:`wb-logos-pause`,"aria-label":T(H?`play`:`pause`),onClick:()=>ne(!H),children:(0,W.jsx)(`svg`,{viewBox:`0 0 24 24`,width:12,height:12,fill:`currentColor`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:H?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})}),(0,W.jsx)(vo,{running:be,every:ue+de,slide:de,step:xe?-1:1,index:F,total:_e,home:Se,setIndex:I,setAnimate:R})]})}function vo({running:e,every:t,slide:n,step:r,index:i,total:a,home:o,setIndex:s,setAnimate:c}){(0,l.useEffect)(()=>{if(!e)return;let n=setInterval(()=>{c(!0),s(e=>e+r)},t);return()=>clearInterval(n)},[e,t,r,s,c]),(0,l.useEffect)(()=>{c(!1),s(o)},[o,s,c]);let u=r>0?i>=a:i<=0;return(0,l.useEffect)(()=>{if(!u||i===o)return;let e=setTimeout(()=>{c(!1),s(o)},n);return()=>clearTimeout(e)},[u,i,n,o,s,c]),null}var yo={tablet:991,mobileLandscape:767,mobile:478},bo=`M4 6h16M4 12h16M4 18h16`,xo=e=>e&&xi[e]?xi[e]:bo;function So({drawerId:e=``,breakpoint:t=`tablet`,side:n=`left`,width:r=300,trigger:i=`button`,triggerLabel:a=``,icon:o=``,title:s=``,showClose:c=!0,backdropClose:u=!0,closeOnLink:d=!0,forceMode:f,frame:p,editorOpen:m=!0,editorLabel:h=`Drawer`,linked:g,style:_,nodeRef:v,inert:y=!1}){let[b,x]=(0,l.useState)(!1),S=`wb-drw-${(0,l.useId)().replace(/[^\w-]/g,``)}`,C=(0,l.useRef)(null),w=t===`always`?``:`(max-width: ${yo[t]??991}px)`,T=(0,l.useCallback)(()=>f?f===`drawer`:!w||typeof window<`u`&&window.matchMedia(w).matches,[f,w]),E=(0,l.useRef)(null),[D,O]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(y||typeof window>`u`)return;let e=()=>{let e=E.current;if(!e||!T()){O(null);return}let t=e.closest(`.webim-page`)??e.closest(`.wb-artboard`)??document.body;O(n=>n?.target===t?n:{target:t,wb:e.getAttribute(`data-wb`)??void 0})};if(e(),f||!w)return;let t=window.matchMedia(w);return t.addEventListener?.(`change`,e),()=>t.removeEventListener?.(`change`,e)},[y,f,w,T]),(0,l.useEffect)(()=>{if(y||f||!w||typeof window>`u`)return;let e=window.matchMedia(w),t=()=>!e.matches&&x(!1);return e.addEventListener?.(`change`,t),()=>e.removeEventListener?.(`change`,t)},[y,f,w]),(0,l.useEffect)(()=>{if(y||!e)return;let t=t=>{!t.target.closest?.(`a[href="#${e}"], [data-webim-open="${e}"]`)||!T()||(t.preventDefault(),x(!0))};return document.addEventListener(`click`,t),()=>document.removeEventListener(`click`,t)},[y,e,T]),(0,l.useEffect)(()=>{if(y||!b)return;let e=e=>e.key===`Escape`&&x(!1),t=document.body.style.overflow;return document.addEventListener(`keydown`,e),document.body.style.overflow=`hidden`,C.current?.focus?.(),()=>{document.removeEventListener(`keydown`,e),document.body.style.overflow=t}},[y,b]);let k=Math.max(120,Number(r)||300),A=[`left`,`right`,`top`,`bottom`].includes(n)?n:`left`,j=A===`top`||A===`bottom`,M=j?`left: 0 !important; right: 0 !important; ${A}: 0 !important; ${A===`top`?`bottom`:`top`}: auto !important; width: 100% !important; height: min(${k}px, 86vh) !important; transform: translateY(${A===`top`?`-`:``}100%);`:`top: 0 !important; bottom: 0 !important; ${A}: 0 !important; ${A===`right`?`left`:`right`}: auto !important; width: min(${k}px, 86vw) !important; height: 100% !important; transform: translateX(${A===`right`?``:`-`}100%);`,N=[`.${S} .wb-drw-trigger { display: inline-flex; }`,`.${S} .wb-drw-head { display: flex; }`,`.${S} .wb-drw-panel { position: fixed !important; ${M} max-width: none !important; max-height: none !important; margin: 0 !important; overflow-y: auto; z-index: 2147483001; visibility: hidden; transition: transform .26s ease, visibility 0s linear .26s; background: var(--page-surface, #ffffff); color: var(--page-text, #111827); box-shadow: 0 0 48px rgba(15, 23, 42, .3); }`,`.${S}.is-open .wb-drw-panel { transform: none; visibility: visible; transition: transform .26s ease; }`,`.${S}.is-open .wb-drw-backdrop { display: block; }`,`@media (prefers-reduced-motion: reduce) { .wb-drw-panel { transition: none !important; } }`].join(`
102
+ `}),ve?(0,W.jsxs)(`div`,{style:{position:`relative`,width:he*ge,maxWidth:`100%`,margin:`0 auto`},children:[ke?Ae(-1):null,(0,W.jsx)(`div`,{style:{overflow:`hidden`},children:Ee}),ke?Ae(1):null]}):(0,W.jsxs)(W.Fragment,{children:[ke?Ae(-1):null,Ee,ke?Ae(1):null]}),ve&&!b&&!re&&(0,W.jsx)(`button`,{type:`button`,...K(`pause`,H&&`pause-stopped`),className:`wb-logos-pause`,"aria-label":T(H?`play`:`pause`),onClick:()=>ne(!H),children:(0,W.jsx)(`svg`,{viewBox:`0 0 24 24`,width:12,height:12,fill:`currentColor`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:H?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})}),(0,W.jsx)(vo,{running:be,every:ue+de,slide:de,step:xe?-1:1,index:F,total:_e,home:Se,setIndex:I,setAnimate:R})]})}function vo({running:e,every:t,slide:n,step:r,index:i,total:a,home:o,setIndex:s,setAnimate:c}){(0,l.useEffect)(()=>{if(!e)return;let n=setInterval(()=>{c(!0),s(e=>e+r)},t);return()=>clearInterval(n)},[e,t,r,s,c]),(0,l.useEffect)(()=>{c(!1),s(o)},[o,s,c]);let u=r>0?i>=a:i<=0;return(0,l.useEffect)(()=>{if(!u||i===o)return;let e=setTimeout(()=>{c(!1),s(o)},n);return()=>clearTimeout(e)},[u,i,n,o,s,c]),null}var yo={tablet:991,mobileLandscape:767,mobile:478},bo=`M4 6h16M4 12h16M4 18h16`,xo=e=>e&&bi[e]?bi[e]:bo;function So({drawerId:e=``,breakpoint:t=`tablet`,side:n=`left`,width:r=300,trigger:i=`button`,triggerLabel:a=``,icon:o=``,title:s=``,showClose:c=!0,backdropClose:u=!0,closeOnLink:d=!0,forceMode:f,frame:p,editorOpen:m=!0,editorLabel:h=`Drawer`,linked:g,style:_,nodeRef:v,inert:y=!1}){let[b,x]=(0,l.useState)(!1),S=`wb-drw-${(0,l.useId)().replace(/[^\w-]/g,``)}`,C=(0,l.useRef)(null),w=t===`always`?``:`(max-width: ${yo[t]??991}px)`,T=(0,l.useCallback)(()=>f?f===`drawer`:!w||typeof window<`u`&&window.matchMedia(w).matches,[f,w]),E=(0,l.useRef)(null),[D,O]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(y||typeof window>`u`)return;let e=()=>{let e=E.current;if(!e||!T()){O(null);return}let t=e.closest(`.webim-page`)??e.closest(`.wb-artboard`)??document.body;O(n=>n?.target===t?n:{target:t,wb:e.getAttribute(`data-wb`)??void 0})};if(e(),f||!w)return;let t=window.matchMedia(w);return t.addEventListener?.(`change`,e),()=>t.removeEventListener?.(`change`,e)},[y,f,w,T]),(0,l.useEffect)(()=>{if(y||f||!w||typeof window>`u`)return;let e=window.matchMedia(w),t=()=>!e.matches&&x(!1);return e.addEventListener?.(`change`,t),()=>e.removeEventListener?.(`change`,t)},[y,f,w]),(0,l.useEffect)(()=>{if(y||!e)return;let t=t=>{!t.target.closest?.(`a[href="#${e}"], [data-webim-open="${e}"]`)||!T()||(t.preventDefault(),x(!0))};return document.addEventListener(`click`,t),()=>document.removeEventListener(`click`,t)},[y,e,T]),(0,l.useEffect)(()=>{if(y||!b)return;let e=e=>e.key===`Escape`&&x(!1),t=document.body.style.overflow;return document.addEventListener(`keydown`,e),document.body.style.overflow=`hidden`,C.current?.focus?.(),()=>{document.removeEventListener(`keydown`,e),document.body.style.overflow=t}},[y,b]);let k=Math.max(120,Number(r)||300),A=[`left`,`right`,`top`,`bottom`].includes(n)?n:`left`,j=A===`top`||A===`bottom`,M=j?`left: 0 !important; right: 0 !important; ${A}: 0 !important; ${A===`top`?`bottom`:`top`}: auto !important; width: 100% !important; height: min(${k}px, 86vh) !important; transform: translateY(${A===`top`?`-`:``}100%);`:`top: 0 !important; bottom: 0 !important; ${A}: 0 !important; ${A===`right`?`left`:`right`}: auto !important; width: min(${k}px, 86vw) !important; height: 100% !important; transform: translateX(${A===`right`?``:`-`}100%);`,N=[`.${S} .wb-drw-trigger { display: inline-flex; }`,`.${S} .wb-drw-head { display: flex; }`,`.${S} .wb-drw-panel { position: fixed !important; ${M} max-width: none !important; max-height: none !important; margin: 0 !important; overflow-y: auto; z-index: 2147483001; visibility: hidden; transition: transform .26s ease, visibility 0s linear .26s; background: var(--page-surface, #ffffff); color: var(--page-text, #111827); box-shadow: 0 0 48px rgba(15, 23, 42, .3); }`,`.${S}.is-open .wb-drw-panel { transform: none; visibility: visible; transition: transform .26s ease; }`,`.${S}.is-open .wb-drw-backdrop { display: block; }`,`@media (prefers-reduced-motion: reduce) { .wb-drw-panel { transition: none !important; } }`].join(`
103
103
  `),P=!y&&(!f||f===`drawer`),F=[`.${S} .wb-drw-trigger, .${S} .wb-drw-head, .${S} .wb-drw-backdrop { display: none; }`,P?w&&!f?`@media ${w} {\n${N}\n}`:N:``].join(`
104
- `),I=y&&(f===`drawer`||!f&&!w),L=I&&m!==!1&&!(p&&Number.isFinite(p.top)),R=(()=>{if(!I)return null;if(m===!1)return{display:`none`};if(p&&Number.isFinite(p.top)){let e=Number.isFinite(p.boardLeft)?p.boardLeft:p.left,t=Number.isFinite(p.boardRight)?p.boardRight:p.innerRight,n=Number.isFinite(p.boardWidth)?p.boardWidth:p.innerWidth||800,r={position:`fixed`,zIndex:6,overflowY:`auto`,boxSizing:`border-box`,marginTop:0,marginRight:0,marginBottom:0,marginLeft:0,maxWidth:`none`,maxHeight:`none`,boxShadow:`0 0 40px rgba(15, 23, 42, .28)`},i=p.bottom;if(j){let n=Math.min(k,Math.round((p.innerHeight||600)*.86));return{...r,left:e,right:t,width:`auto`,height:n,...A===`top`?{top:p.top}:{bottom:i}}}let a=Math.min(k,Math.round(n*.86));return{...r,top:p.top,bottom:i,width:a,height:`auto`,...A===`right`?{right:t}:{left:e}}}return j?{width:`100%`,height:k,maxHeight:`none`,overflowY:`auto`,boxSizing:`border-box`}:{width:`min(${k}px, 100%)`,maxWidth:`none`,boxSizing:`border-box`,...A===`right`?{marginLeft:`auto`}:null}})(),ee=()=>!y&&x(!1),te=(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...G(`backdrop`),className:`wb-drw-backdrop`,onClick:u===!1?void 0:ee,style:{position:`fixed`,inset:0,zIndex:2147483e3,background:`rgba(15, 23, 42, .5)`}}),(0,W.jsxs)(`div`,{ref:C,"data-wb-self":``,className:`wb-drw-panel`,role:b?`dialog`:void 0,"aria-modal":b?`true`:void 0,"aria-label":s||void 0,tabIndex:-1,onClick:e=>{if(d===!1||!b||e.defaultPrevented)return;let t=e.target.closest?.(`a[href]`),n=(t?.getAttribute(`href`)??``).trim();!t||n===``||n===`#`||/^javascript:/i.test(n)||e.target.closest(`[role="button"]`)&&t.contains(e.target.closest(`[role="button"]`))||x(!1)},style:{outline:`none`,...I?{backgroundColor:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,boxShadow:`0 0 0 1px var(--page-border, rgba(148, 163, 184, .4))`}:null,...!I&&!j?{width:k,maxWidth:`100%`,boxSizing:`border-box`}:null,...z(_),...I?R:null},children:[(s||c!==!1)&&(0,W.jsxs)(`div`,{...G(`header`),className:`wb-drw-head`,style:{alignItems:`center`,gap:12,padding:`14px 16px`,...I?{display:`flex`}:null},children:[(0,W.jsx)(`span`,{...G(`title`),style:{flexGrow:1,fontWeight:700,fontSize:17},children:s}),c!==!1&&(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,...G(`close-button`),onClick:ee,style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4,opacity:.75},children:`✕`})]}),(0,W.jsx)(`div`,{...G(`content`),children:g?.content})]})]});return(0,W.jsxs)(`div`,{ref:e=>{E.current=e,typeof v==`function`?v(e):v&&(v.current=e)},id:e||void 0,"data-wb-redirect":``,className:`${S}${b?` is-open`:``}`,children:[(0,W.jsx)(`style`,{children:F}),i===`button`&&(0,W.jsxs)(`button`,{type:`button`,...G(`trigger`),className:`wb-drw-trigger`,"aria-expanded":b,"aria-label":a?void 0:s||`Menu`,onClick:()=>!y&&x(!0),style:{alignItems:`center`,gap:8,padding:`8px 12px`,border:`1px solid var(--page-border, rgba(148, 163, 184, .4))`,borderRadius:8,background:`transparent`,color:`inherit`,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,...I?{display:`inline-flex`,marginBottom:L?12:0}:null},children:[(0,W.jsx)(`svg`,{...G(`icon`),width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:xo(o)})}),a?(0,W.jsx)(`span`,{children:a}):null]}),I&&i!==`button`&&!L&&(0,W.jsxs)(`div`,{style:{...U,display:`inline-flex`,alignItems:`center`,gap:6,padding:`4px 10px`,border:`1px dashed rgba(100, 116, 139, .55)`,borderRadius:6,fontSize:12,lineHeight:1.4,color:`rgba(100, 116, 139, .9)`,verticalAlign:`top`},children:[(0,W.jsxs)(`svg`,{width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,"aria-hidden":`true`,children:[(0,W.jsx)(`rect`,{x:`3`,y:`4`,width:`18`,height:`16`,rx:`2`}),(0,W.jsx)(`path`,{d:n===`right`?`M15 4v16`:n===`top`?`M3 10h18`:n===`bottom`?`M3 14h18`:`M9 4v16`})]}),h]}),D?(0,mt.createPortal)((0,W.jsx)(`div`,{className:`${S}${b?` is-open`:``}`,"data-wb":D.wb,"data-wb-redirect":``,style:{display:`contents`},children:te}),D.target):te]})}function Co({target:e=``,breakpoint:t=`tablet`,label:n=``,icon:r=``,forceMode:i,style:a,nodeRef:o,inert:s=!1}){let c=`wb-dbt-${(0,l.useId)().replace(/[^\w-]/g,``)}`,u=yo[t],d=i||t===`always`||!u?``:`@media (min-width: ${u+1}px) { .${c} { display: none !important; } }`,f=i===`inline`;return(0,W.jsxs)(W.Fragment,{children:[d?(0,W.jsx)(`style`,{children:d}):null,(0,W.jsxs)(`button`,{ref:o,type:`button`,className:c,"data-webim-open":!s&&e?e:void 0,"aria-label":n?void 0:`Menu`,onClick:s?e=>e.preventDefault():void 0,style:{display:f&&!s?`none`:`inline-flex`,opacity:f&&s?.35:void 0,alignItems:`center`,gap:8,padding:`8px 10px`,border:0,borderRadius:8,background:`transparent`,color:`inherit`,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,...z(a)},children:[(0,W.jsx)(`svg`,{...G(`icon`),width:`22`,height:`22`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:xo(r)})}),n?(0,W.jsx)(`span`,{...G(`label`),children:n}):null]})]})}var wo={small:380,medium:560,large:820,full:`100%`};function To({dialogId:e=``,trigger:t=`button`,triggerLabel:n=`Open`,openOn:r=`trigger`,delay:i=0,size:a=`medium`,title:o=``,showClose:s=!0,backdropClose:c=!0,position:u=`center`,actions:d=[],showCloseAction:f=!1,closeLabel:p=`Close`,actionsAlign:m=`right`,linked:h,style:g,nodeRef:_,inert:v=!1}){let[y,b]=(0,l.useState)(!1),x=(0,l.useRef)(null);(0,l.useEffect)(()=>{if(v||!e)return;let t=t=>{t.target.closest?.(`a[href="#${e}"], [data-webim-open="${e}"]`)&&(t.preventDefault(),b(!0))};return document.addEventListener(`click`,t),()=>document.removeEventListener(`click`,t)},[v,e]),(0,l.useEffect)(()=>{if(v||r!==`load`)return;let e=setTimeout(()=>b(!0),Math.max(0,Number(i)||0)*1e3);return()=>clearTimeout(e)},[v,r,i]),(0,l.useEffect)(()=>{if(v||!y)return;let e=e=>e.key===`Escape`&&b(!1);document.addEventListener(`keydown`,e);let t=document.body.style.overflow;return document.body.style.overflow=`hidden`,x.current?.focus?.(),()=>{document.removeEventListener(`keydown`,e),document.body.style.overflow=t}},[v,y]);let S=wo[a]??wo.medium,C=e=>{let t=e.variant??`primary`,n={padding:`9px 16px`,borderRadius:6,cursor:`pointer`,fontSize:14,fontFamily:`inherit`,textDecoration:`none`,display:`inline-block`,...{primary:{background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`,border:`1px solid transparent`},outline:{background:`transparent`,color:`inherit`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},text:{background:`transparent`,color:`inherit`,border:`1px solid transparent`},danger:{background:`#dc2626`,color:`#ffffff`,border:`1px solid transparent`}}[t]??{}};return e.href&&!v?(0,W.jsx)(`a`,{...G(`button`,/^[a-z]+$/.test(t)&&`button-${t}`),href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:n,children:e.label},e.key):(0,W.jsx)(`button`,{...G(`button`,/^[a-z]+$/.test(t)&&`button-${t}`),type:`button`,onClick:()=>!v&&b(!1),style:n,children:e.label},e.key)},w=Array.isArray(d)?d:[],T=w.filter(e=>e.side===`left`),E=w.filter(e=>e.side!==`left`),D=f===!0?C({key:`__close`,label:p||`Close`,variant:`outline`}):null,O=T.length||E.length||D?(0,W.jsxs)(`div`,{...G(`footer`),style:{display:`flex`,alignItems:`center`,gap:8,padding:`14px 20px`,borderTop:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,justifyContent:T.length?`space-between`:m===`left`?`flex-start`:m===`center`?`center`:`flex-end`},children:[T.length>0&&(0,W.jsx)(`div`,{style:{display:`flex`,gap:8},children:T.map(C)}),(0,W.jsxs)(`div`,{style:{display:`flex`,gap:8},children:[D,E.map(C)]})]}):null,k=(0,W.jsxs)(`div`,{ref:x,role:`dialog`,"aria-modal":v?void 0:`true`,"aria-label":o||void 0,tabIndex:-1,onClick:e=>e.stopPropagation(),style:{width:typeof S==`number`?`min(${S}px, 100%)`:S,maxHeight:v?void 0:`85vh`,overflowY:v?void 0:`auto`,borderRadius:12,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,boxShadow:v?`none`:`0 24px 64px rgba(15, 23, 42, 0.35)`,outline:`none`,...z(g)},children:[(o||s!==!1)&&(0,W.jsxs)(`div`,{...G(`header`),style:{display:`flex`,alignItems:`center`,gap:12,padding:`16px 20px`,borderBottom:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},children:[(0,W.jsx)(`span`,{...G(`title`),style:{fontWeight:700,fontSize:17,flexGrow:1,fontFamily:`var(--page-heading-font, inherit)`},children:o}),s!==!1&&(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,...G(`close-button`),onClick:()=>!v&&b(!1),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:2,opacity:.7},children:`✕`})]}),(0,W.jsx)(`div`,{...G(`content`),style:{padding:20},children:h?.content}),O]});return(0,W.jsxs)(`div`,{ref:_,id:e||void 0,style:v?void 0:{display:`contents`},children:[t===`button`&&(0,W.jsx)(`button`,{type:`button`,...G(`trigger`),onClick:()=>!v&&b(!0),style:{padding:`10px 18px`,border:0,borderRadius:6,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:n}),v?(0,W.jsx)(`div`,{style:{marginTop:t===`button`?12:0},children:k}):y&&(0,W.jsx)(`div`,{...G(`backdrop`),onClick:c===!1?void 0:()=>b(!1),style:{position:`fixed`,inset:0,zIndex:2147483e3,display:`flex`,alignItems:u===`top`?`flex-start`:`center`,justifyContent:`center`,padding:20,paddingTop:u===`top`?`8vh`:20,background:`rgba(15, 23, 42, 0.55)`,backdropFilter:`blur(2px)`},children:k})]})}function Eo({dropdownId:e=``,trigger:t=`button`,triggerLabel:n=`Menu`,openOn:r=`hover`,align:i=`left`,panelWidth:a=``,offset:o=8,editorOpen:s=!0,linked:c,style:u,nodeRef:d,inert:f=!1}){let[p,m]=(0,l.useState)(!1),h=(0,l.useRef)(null),g=(0,l.useRef)(null),_=r!==`click`,v=()=>{g.current&&clearTimeout(g.current),g.current=null},y=()=>{v(),g.current=setTimeout(()=>m(!1),160)};(0,l.useEffect)(()=>{if(f||!e)return;let t=`[data-webim-toggle="${e}"]`,n=e=>{e.target.closest?.(t)&&(e.preventDefault(),v(),m(e=>!e))},r=e=>{e.target.closest?.(t)&&(v(),m(!0))},i=e=>{let n=e.target.closest?.(t);!n||e.relatedTarget&&n.contains(e.relatedTarget)||y()};return document.addEventListener(`click`,n),_&&(document.addEventListener(`mouseover`,r),document.addEventListener(`mouseout`,i)),()=>{document.removeEventListener(`click`,n),document.removeEventListener(`mouseover`,r),document.removeEventListener(`mouseout`,i)}},[f,e,_]),(0,l.useEffect)(()=>{if(f||!p)return;let t=t=>{h.current?.contains(t.target)||e&&t.target.closest?.(`[data-webim-toggle="${e}"]`)||m(!1)},n=e=>e.key===`Escape`&&m(!1);return document.addEventListener(`mousedown`,t),document.addEventListener(`keydown`,n),()=>{document.removeEventListener(`mousedown`,t),document.removeEventListener(`keydown`,n)}},[f,p,e]),(0,l.useEffect)(()=>v,[]);let b=Number(a)>0?Number(a):null,x=f?s!==!1:p,S=(0,W.jsx)(`div`,{style:{position:`absolute`,top:`calc(100% + ${Number(o)||0}px)`,...i===`right`?{right:0}:i===`center`?{left:`50%`,transform:`translateX(-50%)`}:{left:0},zIndex:60,display:x?`block`:`none`,minWidth:b??240,width:b??void 0,maxWidth:`92vw`,padding:14,borderRadius:10,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, inherit)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,boxShadow:`0 16px 44px rgba(15, 23, 42, 0.22)`,...z(u)},children:c?.content??null});return(0,W.jsxs)(`div`,{ref:e=>{h.current=e,d&&d(e)},id:e||void 0,onMouseEnter:!f&&_?()=>{v(),m(!0)}:void 0,onMouseLeave:!f&&_?y:void 0,style:{position:`relative`,display:`inline-block`},children:[t!==`none`&&(0,W.jsxs)(`button`,{type:`button`,...G(`trigger`),"aria-haspopup":`true`,"aria-expanded":f?void 0:p,onClick:()=>!f&&m(e=>!e),style:{padding:`9px 16px`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,borderRadius:6,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,background:`var(--page-surface, transparent)`,color:`inherit`,display:`inline-flex`,alignItems:`center`,gap:6},children:[n,(0,W.jsx)(`span`,{"aria-hidden":`true`,...G(`chevron`),style:{fontSize:10,opacity:.7},children:`▾`})]}),S]})}var Do={PageRoot:mr,MarkdownBlock:Nr,CalendarBlock:mo,LogoCarousel:_o,DialogBlock:To,DrawerBlock:So,DrawerTrigger:Co,DropdownBlock:Eo,Section:hr,Container:gr,LinkBlock:_r,Heading:vr,TextBlock:Lr,ButtonBlock:Vr,ImageBlock:Hr,Spacer:ei,Divider:ti,BoxBlock:ni,SliderBlock:ci,CanvasSlider:li,TabsBlock:Pi,QuickStack:da,CollectionList:pa,CollectionSearch:ma,BreadcrumbsBlock:ha,PaginationBlock:ga,StepperBlock:Na,SocialLinksBlock:Ma,ThemeModeBlock:xa,ScrollTopBlock:Aa,CounterBlock:ka,OrgChartBlock:Qa,TableBlock:ao,IconBlock:Si,MapBlock:bi,MasonryBlock:wi,AccordionBlock:Fi,NavbarBlock:Ni,MenuTreeBlock:ki,ListBlock:Ir,TextSpan:Cr,QuoteBlock:Fr,TextLink:Br,RichTextBlock:Mr,RichContentBlock:Mr,VideoBlock:Gr,YouTubeBlock:qr,IframeBlock:Jr,PdfBlock:Xr,EmbedBlock:$r,FormBlock:Zi,FormLabel:ra,FormFieldset:la,FormInput:ia,FormTextarea:aa,FormCheckbox:e=>(0,W.jsx)(oa,{kind:`checkbox`,...e}),FormRadio:e=>(0,W.jsx)(oa,{kind:`radio`,...e}),FormSelect:sa,FormFile:ca,FormRecaptcha:ta,FormSubmit:ua},Oo={id:`auth`,label:`Accounts`,category:`Apps`,keys:[`SiteLoginForm`,`SiteAccountMenu`],ssr:`shell`,settings:[`site.authRedirect`]},ko=(0,l.createContext)({user:null,status:`idle`,ensure:()=>{},refresh:()=>{},signOut:()=>{}});function Ao(e,t){return t?/^https?:\/\//i.test(t)?t:`${e.replace(/\/+$/,``)}${t.startsWith(`/`)?t:`/${t}`}`:``}function jo(e){let t=e&&typeof e==`object`?e[`site.session`]:null,n=t&&typeof t==`object`&&!Array.isArray(t)?t:{},r=e=>typeof e==`string`?e.trim():``,i=r(n.url),a=r(n.mePath),o=r(n.logoutPath);return{mode:n.mode===`custom`||n.mode===`off`?n.mode:`system`,url:i,mePath:a,logoutPath:o,meUrl:Ao(i,a),logoutUrl:Ao(i,o),loginPage:r(n.loginPage),userPath:r(n.userPath),auth:n.auth===`bearer`?`bearer`:`cookies`,tokenKey:r(n.tokenKey)||`webim_session_token`}}function Mo(e,t){if(!t)return e??null;let n=e;for(let e of t.split(`.`)){if(!n||typeof n!=`object`)return null;n=n[e]}return n??null}function No(e){try{return window.localStorage.getItem(e)||``}catch{return``}}function Po(e){try{window.localStorage.removeItem(e)}catch{}}var Fo=()=>{let e=(0,l.useContext)(ko);return(0,l.useEffect)(()=>{e.ensure()},[e]),e};function Io({children:e,initialUser:t,disabled:n,apiUrl:r,tenant:i}){let a=(0,l.useContext)(Nn),o=r||a?.apiUrl||`/api`,s=i||a?.tenant||``,c=(0,l.useMemo)(()=>jo(a?.settings),[a?.settings]),[u,d]=(0,l.useState)(t??null),[f,p]=(0,l.useState)(t?`user`:n?`guest`:`idle`),m=(0,l.useRef)(!1),h=(0,l.useCallback)((e,t)=>fetch(`${o}${e}`,{...t,credentials:`include`,headers:{"content-type":`application/json`,...s?{"x-tenant":s}:{},...t?.headers}}),[o,s]),g=(0,l.useCallback)(e=>(d(e),p(e?`user`:`guest`),e),[]),_=(0,l.useCallback)(()=>{if(n)return Promise.resolve(null);if(c.mode===`off`)return Promise.resolve(g(null));if(c.mode===`custom`){let e=c.auth===`bearer`?No(c.tokenKey):``;return!c.meUrl||c.auth===`bearer`&&!e?Promise.resolve(g(null)):fetch(c.meUrl,{...c.auth===`bearer`?{headers:{authorization:`Bearer ${e}`}}:{credentials:`include`}}).then(e=>e.ok?e.json():null).then(e=>{let t=Mo(e,c.userPath);return g(t&&typeof t==`object`?t:null)}).catch(()=>g(null))}return h(`/site/me`).then(e=>e.ok?e.json():null).then(e=>g(e?.payload??null)).catch(()=>g(null))},[h,c,n,g]),v=(0,l.useCallback)(()=>{if(c.mode===`off`)return g(null),Promise.resolve();if(c.mode===`custom`){let e=c.auth===`bearer`?No(c.tokenKey):``;return(c.logoutUrl?fetch(c.logoutUrl,{method:`post`,...c.auth===`bearer`?{headers:e?{authorization:`Bearer ${e}`}:{}}:{credentials:`include`}}).catch(()=>{}):Promise.resolve()).then(()=>{c.auth===`bearer`&&Po(c.tokenKey),g(null)})}return h(`/site/logout`,{method:`post`}).catch(()=>{}).then(()=>{g(null)})},[h,c,g]),y=(0,l.useCallback)(()=>{m.current||n||t||(m.current=!0,p(`loading`),_())},[n,t,_]),b=(0,l.useMemo)(()=>({user:u,status:f,ensure:y,refresh:_,signOut:v}),[u,f,y,_,v]);return(0,l.useEffect)(()=>{n||typeof window>`u`||(window.webim={...window.webim,user:u,status:f,loginUrl:c.loginPage||null,requireUser:()=>m.current||t?Promise.resolve(u):_(),refresh:_,signOut:v},window.dispatchEvent(new CustomEvent(`webim:session`,{detail:{user:u,status:f}})))},[n,u,f,t,c.loginPage,_,v]),(0,W.jsx)(ko.Provider,{value:b,children:e})}function Lo({when:e,children:t}){let{status:n}=Fo();return!e||e===`always`?t:n===`idle`||n===`loading`?null:e===`user`==(n===`user`)?t:null}function Ro({mode:e=`login`,redirect:t,emailLabel:n=`Email`,passwordLabel:r=`Password`,nameLabel:i=`Name`,submitLabel:a,style:o,nodeRef:s,inert:c,linked:u,show:d}){let{tenant:f,apiUrl:p,settings:m}=(0,l.useContext)(Nn),[h,g]=(0,l.useState)(`form`),[_,v]=(0,l.useState)(``),[y,b]=(0,l.useState)(!1),x=e===`register`,S=c?d||`form`:h,C=e=>typeof e==`string`&&e.startsWith(`/`)&&!e.startsWith(`//`)?e:``,w=async e=>{if(e.preventDefault(),c)return;let n=new FormData(e.currentTarget);b(!0),v(``);try{let e=await fetch(`${p||`/api`}/site/${x?`register`:`login`}`,{method:`post`,headers:{"content-type":`application/json`,...f?{"x-tenant":f}:{}},credentials:`same-origin`,body:JSON.stringify({email:n.get(`email`),password:n.get(`password`),...x?{name:n.get(`name`)||``}:{}})}),r=await e.json().catch(()=>null);if(!e.ok||r?.success===!1){v(r?.error?.message||`Sign-in failed`),g(`error`),b(!1);return}if(g(`success`),typeof window<`u`){let e=C(t)||C(new URLSearchParams(window.location.search).get(`next`))||C(m?.[`site.authRedirect`])||C(m?.[`apps.auth.redirect`])||`/`;window.location.assign(e)}}catch{v(`Sign-in failed`),g(`error`),b(!1)}};return(0,W.jsxs)(`div`,{ref:s,style:{display:`grid`,gap:12,maxWidth:360,...z(o)},children:[(0,W.jsxs)(`form`,{...G(`form`),onSubmit:w,style:{display:S===`form`?`grid`:`none`,gap:10},children:[x?(0,W.jsxs)(`label`,{...G(`label`),style:{...Li,display:`grid`,gap:6},children:[i,(0,W.jsx)(`input`,{...G(`input`),name:`name`,type:`text`,style:q,...zi(c)})]}):null,(0,W.jsxs)(`label`,{...G(`label`),style:{...Li,display:`grid`,gap:6},children:[n,(0,W.jsx)(`input`,{...G(`input`),name:`email`,type:`email`,required:!c,style:q,...zi(c)})]}),(0,W.jsxs)(`label`,{...G(`label`),style:{...Li,display:`grid`,gap:6},children:[r,(0,W.jsx)(`input`,{...G(`input`),name:`password`,type:`password`,required:!c,style:q,...zi(c)})]}),(0,W.jsx)(`button`,{...G(`button`,y&&`button-busy`),type:c?`button`:`submit`,disabled:y||void 0,style:{...lr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:y?.6:1},children:a||(x?`Create account`:`Sign in`)}),_?(0,W.jsx)(`p`,{...G(`error`),style:{margin:0,fontSize:14,color:`#dc2626`},children:_}):null]}),(0,W.jsx)(`div`,{style:{display:S===`success`?`block`:`none`},children:u?.success??null}),(0,W.jsx)(`div`,{style:{display:S===`error`?`block`:`none`},children:u?.error??null})]})}function zo({greeting:e=`Hi`,signOutLabel:t=`Sign out`,showEmail:n=!1,style:r,nodeRef:i,inert:a,linked:o,show:s}){let{user:c,status:l,signOut:u}=Fo(),d=a?s||`user`:l,f=a?{name:`Ada Lovelace`,email:`ada@example.com`}:c;return d===`loading`?(0,W.jsx)(`div`,{ref:i,style:{minHeight:24,...z(r)}}):d===`user`?(0,W.jsxs)(`div`,{ref:i,style:{display:`flex`,alignItems:`center`,gap:10,...z(r)},children:[(0,W.jsxs)(`span`,{...G(`greeting`),style:{...Li,fontWeight:600},children:[e,` `,f?.name||f?.email||``]}),n&&f?.email?(0,W.jsx)(`span`,{...G(`email`),style:{...Li,opacity:.7},children:f.email}):null,(0,W.jsx)(`button`,{...G(`button`),type:`button`,onClick:a?void 0:u,style:{...lr,border:0,padding:`8px 16px`,borderRadius:8,fontSize:14,cursor:a?`default`:`pointer`},...zi(a),children:t})]}):(0,W.jsx)(`div`,{ref:i,style:{display:`flex`,alignItems:`center`,gap:10,...z(r)},children:o?.signedOut??null})}var Bo={id:`consent`,label:`Cookie consent`,category:`Apps`,keys:[`CookieConsent`],ssr:`shell`,settings:[]},Vo=`webim.cookie_consent`;function Ho(){try{let e=window.localStorage.getItem(Vo),t=e?JSON.parse(e):null;return t?.choice===`accepted`||t?.choice===`declined`?t.choice:``}catch{return``}}function Uo(e){try{document.querySelectorAll(`.webim-page`).forEach(t=>t.setAttribute(`data-webim-consent`,e))}catch{}}function Wo(e){try{window.localStorage.setItem(Vo,JSON.stringify({choice:e,at:new Date().toISOString()}))}catch{}Uo(e);try{window.dispatchEvent(new CustomEvent(`webim:consent`,{detail:{choice:e}}))}catch{}}var Go={bottom:{left:0,right:0,bottom:0},top:{left:0,right:0,top:0},"bottom-left":{left:16,bottom:16,maxWidth:400},"bottom-right":{right:16,bottom:16,maxWidth:400}};function Ko({message:e,acceptLabel:t,rejectLabel:n,showReject:r,linkLabel:i,linkHref:a,position:o,linked:s,style:c,nodeRef:u,inert:d}){let[f,p]=(0,l.useState)(!!d),[m,h]=(0,l.useState)(null),g=e=>{h(e),typeof u==`function`&&u(e)};if((0,l.useEffect)(()=>{if(d)return;let e=Ho();e?Uo(e):p(!0)},[d,m]),!f)return null;let _=e=>()=>{d||(Wo(e),p(!1))},v=Go[o]??Go.bottom,y={appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,padding:`8px 16px`,borderRadius:8,cursor:d?`default`:`pointer`,whiteSpace:`nowrap`};return(0,W.jsxs)(`div`,{ref:g,role:`region`,"aria-label":`Cookie consent`,style:{...d?{position:`relative`}:{position:`fixed`,zIndex:2147483e3,...v},display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:12,padding:16,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:o===`bottom`||o===`top`?0:12,boxShadow:`0 8px 30px rgba(15, 23, 42, 0.18)`,fontSize:14,lineHeight:1.5,...z(c)},children:[(0,W.jsxs)(`div`,{...G(`message`),style:{flex:`1 1 260px`,minWidth:0},children:[s?.content??(e||`We use cookies to run this site and to understand how it is used.`),i&&a?(0,W.jsxs)(W.Fragment,{children:[` `,(0,W.jsx)(`a`,{...G(`link`),href:a,onClick:d?e=>e.preventDefault():void 0,style:{color:`var(--page-accent, inherit)`,textDecoration:`underline`},children:i})]}):null]}),(0,W.jsxs)(`div`,{...G(`actions`),style:{display:`flex`,gap:8,flexShrink:0},children:[r===!1?null:(0,W.jsx)(`button`,{...G(`decline-button`),type:`button`,onClick:_(`declined`),style:{...y,background:`transparent`,color:`inherit`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.6))`},children:n||`Decline`}),(0,W.jsx)(`button`,{...G(`accept-button`),type:`button`,onClick:_(`accepted`),style:{...y,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,border:`1px solid transparent`},children:t||`Accept`})]})]})}var qo={id:`language`,label:`Language`,category:`Apps`,keys:[`SiteLanguagePicker`],ssr:`prefetch`,settings:[`locales`]},Jo={id:`search`,label:`Search`,category:`Apps`,keys:[`SiteSearch`],ssr:`prefetch`,settings:[]},Yo=50,Xo=2e3;function Zo(){return typeof window>`u`?``:new URLSearchParams(window.location.search).get(`q`)??``}function Qo(e,t){let n=e?.data??{},r=[];for(let e of Object.values(n)){let t=e==null?``:Jn(e);if(t&&r.push(t),r.join(` `).length>Xo)break}return r.join(` `).slice(0,Xo).toLocaleLowerCase(t||void 0)}function $o({placeholder:e=`Search…`,buttonLabel:t=`Search`,showButton:n=!0,live:r=!1,layout:i=`inline`,includePages:a=!0,collections:o=[],limit:s=10,emptyText:c=`Nothing found`,hint:u=``,style:d,nodeRef:f,inert:p=!1,sample:m=!1}){let{tenant:h,apiUrl:g,locale:_}=(0,l.useContext)(Nn),[v,y]=(0,l.useState)(()=>Zo()),[b,x]=(0,l.useState)(()=>Zo()),[S,C]=(0,l.useState)(null),[w,T]=(0,l.useState)(!1),E=(0,l.useRef)(null),D=i===`popup`;(0,l.useEffect)(()=>{let e=()=>{let e=Zo();y(e),x(e)};return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]),(0,l.useEffect)(()=>{if(!r)return;let e=setTimeout(()=>{y(b),b.trim()&&T(!0)},200);return()=>clearTimeout(e)},[r,b]),(0,l.useEffect)(()=>{if(!D)return;let e=e=>{E.current&&!E.current.contains(e.target)&&T(!1)},t=e=>e.key===`Escape`&&T(!1);return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[D]),(0,l.useEffect)(()=>{let e=!0,t=h?{"x-tenant":h}:{},n=e=>fetch(`${g}${e}`,{headers:t}).then(e=>e.json()).then(e=>e?.payload).catch(()=>null),r=[a?n(`/site/pages`).then(e=>({kind:`page`,rows:Array.isArray(e)?e:[]})):null,...(Array.isArray(o)?o:[]).filter(Boolean).map(e=>n(`/dynamic/${encodeURIComponent(e)}?all=1${_?`&locale=${encodeURIComponent(_)}`:``}`).then(t=>({kind:`entry`,slug:e,rows:Array.isArray(t)?t:Array.isArray(t?.data)?t.data:[]})))].filter(Boolean);return Promise.all(r).then(t=>e&&C(t)),()=>{e=!1}},[g,h,_,a,JSON.stringify(o)]);let O=v.trim().toLocaleLowerCase(_||void 0),k=[];if(O&&S)for(let e of S)if(e.kind===`page`)for(let t of e.rows){if(t?.access&&t.access!==`public`)continue;let e=String(t?.title??``);`${e} ${t?.slug??``}`.toLocaleLowerCase(_||void 0).includes(O)&&k.push({key:`page:${t.slug}`,title:e||t.slug,url:`/${t.slug}`,kind:`page`})}else for(let t of e.rows){if(!Qo(t,_).includes(O))continue;let n=t?.data??{},r=Jn(n.name)||`Untitled`,i=Jn(n.slug);k.push({key:`entry:${t.id}`,title:r,url:i?`/${e.slug}/${i}`:`/${e.slug}`,kind:`entry`})}let A=k.slice(0,Math.min(Math.max(1,s),Yo)),j=e=>{if(p){e.preventDefault(),y(b),T(!0);return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);b.trim()?t.set(`q`,b.trim()):t.delete(`q`),t.delete(`page`);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`)),T(!0)},M=m&&!O?[{key:`sample-1`,title:`About us`,url:`/about`,kind:`page`},{key:`sample-2`,title:`Spring collection`,url:`/blog/spring`,kind:`entry`}]:null,N=M??A,P=!M&&O&&S&&!A.length,F=!D||w&&(N.length>0||P),I=N.length>0&&(0,W.jsx)(`ul`,{...G(`results`),style:{listStyle:`none`,margin:0,padding:0,display:`flex`,flexDirection:`column`,gap:2},children:N.map(e=>(0,l.createElement)(`li`,{...G(`item`),key:e.key},(0,W.jsxs)(`a`,{...G(`result`),href:p?void 0:e.url,style:{display:`block`,padding:`10px 12px`,borderRadius:6,color:`inherit`,textDecoration:`none`,border:D?0:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},children:[(0,W.jsx)(`span`,{...G(`title`),style:{display:`block`,fontWeight:600},children:e.title}),(0,W.jsx)(`span`,{...G(`url`),style:{display:`block`,fontSize:12,opacity:.6},children:e.url})]})))});return(0,W.jsx)(`div`,{ref:f,style:{width:`100%`,...z(d)},children:(0,W.jsxs)(`div`,{ref:E,style:{position:`relative`},children:[(0,W.jsxs)(`form`,{...G(`form`),method:`get`,onSubmit:j,style:{display:`flex`,gap:8,alignItems:`center`},children:[(0,W.jsx)(`input`,{...G(`input`),type:`search`,name:`q`,value:b,placeholder:e,onChange:e=>x(e.target.value),onFocus:()=>O&&T(!0),style:{...q,flexGrow:1,minWidth:0}}),n!==!1&&(0,W.jsx)(`button`,{...G(`button`),type:`submit`,style:{padding:`10px 16px`,border:0,borderRadius:6,cursor:`pointer`,fontSize:14,fontFamily:`inherit`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:t})]}),u&&(0,W.jsx)(`div`,{...G(`hint`),style:{fontSize:13,opacity:.65,marginTop:6},children:u}),F&&(0,W.jsxs)(`div`,{...G(`panel`),style:D?{position:`absolute`,top:`100%`,left:0,right:0,zIndex:30,marginTop:6,padding:6,maxHeight:320,overflowY:`auto`,borderRadius:8,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,background:`var(--page-surface, #f2f2f2)`,boxShadow:`0 12px 32px rgba(15, 23, 42, 0.18)`}:{marginTop:14},children:[I,P&&(0,W.jsx)(`div`,{...G(`empty`),style:{fontSize:14,opacity:.65,padding:D?`10px 12px`:0},children:c})]})]})})}var es={id:`shop`,label:`Shop`,category:`Shop`,keys:[`ShopProductGrid`,`ShopProduct`,`ShopCartButton`,`ShopCheckout`,`ShopOrderHistory`,`ShopCurrencyPicker`,`ShopFavorites`],ssr:`shell`,settings:[`shop.enabled`]},ts=`webim.cart.`,ns=`webim.currency.`,rs=new Map,is={get(e){try{return window.localStorage.getItem(e)??``}catch{return``}},set(e,t){try{t?window.localStorage.setItem(e,t):window.localStorage.removeItem(e)}catch{}}};function as(e){if(typeof window>`u`)return!1;try{return new URL(e,window.location.href).origin===window.location.origin}catch{return!1}}async function os(e,t,n,{method:r=`GET`,body:i}={}){let a=await fetch(`${e}${n}`,{method:r,...as(e)?{credentials:`include`}:{},headers:{...t?{"x-tenant":t}:{},...i?{"content-type":`application/json`}:{}},body:i?JSON.stringify(i):void 0}),o=await a.json().catch(()=>null);if(!o||o.success===!1||!a.ok){let e=o?.error;throw{message:(e&&typeof e==`object`?e.message:e)||`Request failed (${a.status})`,code:(e&&typeof e==`object`?e.code:o?.code)||`ERROR`}}return o.payload}var ss={id:``,currency:``,lines:[],count:0,subtotal:0,coupon:null,coupon_error:null,coupon_error_code:null,discounts:[],discount_total:0,shipping_before:0,shipping_total:0,total:0};function cs(e,t){let n=`${ts}${t||`default`}`,r=`${ns}${t||`default`}`,i=new Set,a={cart:ss,loading:!1,loaded:!1,error:null,currency:is.get(r)},o=null,s=()=>i.forEach(e=>e()),c=e=>{a={...a,...e},s()},l=e=>(e&&typeof e==`object`&&(e.id&&is.set(n,e.id),c({cart:e,loaded:!0,error:null})),e),u=()=>{if(o)return o;let r=is.get(n),i=new URLSearchParams({...r?{id:r}:{},...a.currency?{currency:a.currency}:{}}).toString();return c({loading:!0}),o=os(e,t,`/store/cart${i?`?${i}`:``}`).then(l).catch(e=>c({error:e,loaded:!0})).finally(()=>{o=null,c({loading:!1})}),o},d=async(r,i,o)=>{c({loading:!0});try{return l(await os(e,t,`/store/cart`,{method:`POST`,body:{cart_id:is.get(n)||void 0,product_id:r,variant_id:i??null,quantity:o,currency:a.currency||void 0}}))}finally{c({loading:!1})}};return typeof window<`u`&&window.addEventListener(`storage`,e=>{e.key===r&&c({currency:is.get(r)}),(e.key===n||e.key===r)&&u()}),{getState:()=>a,subscribe:e=>(i.add(e),()=>i.delete(e)),load:u,setLine:d,add:(e,t,n=1)=>{let r=a.cart.lines.find(n=>n.product_id===e&&(n.variant_id??null)===(t??null));return d(e,t,(r?.quantity??0)+n)},setCoupon:async r=>{c({loading:!0});try{return l(await os(e,t,`/store/cart/coupon`,{method:`POST`,body:{cart_id:is.get(n),code:r}}))}finally{c({loading:!1})}},setCountry:async(r,i)=>is.get(n)?l(await os(e,t,`/store/cart/country`,{method:`POST`,body:{cart_id:is.get(n),country:r,...i!==void 0&&{postal_code:i}}})):a.cart,setDelivery:async r=>is.get(n)?l(await os(e,t,`/store/cart/delivery`,{method:`POST`,body:{cart_id:is.get(n),delivery:r}})):a.cart,setCurrency:async i=>{if(is.set(r,i),c({currency:i}),!is.get(n))return u();try{return l(await os(e,t,`/store/cart/currency`,{method:`POST`,body:{cart_id:is.get(n),currency:i}}))}catch{return is.set(r,``),c({currency:``}),u()}},reset:()=>{is.set(n,``),c({cart:ss})},cartId:()=>is.get(n)}}function ls(e,t){let n=`${e}|${t}`;return rs.has(n)||rs.set(n,cs(e,t)),rs.get(n)}function us(e,t){let n=Array.isArray(e?.currencies)?e.currencies:[];return t&&n.includes(t)?t:e?.currency||``}var ds=`AD AE AF AG AI AL AM AO AQ AR AS AT AU AW AX AZ BA BB BD BE BF BG BH BI BJ BL BM BN BO BQ BR BS BT BV BW BY BZ CA CC CD CF CG CH CI CK CL CM CN CO CR CU CV CW CX CY CZ DE DJ DK DM DO DZ EC EE EG EH ER ES ET FI FJ FK FM FO FR GA GB GD GE GF GG GH GI GL GM GN GP GQ GR GS GT GU GW GY HK HM HN HR HT HU ID IE IL IM IN IO IQ IR IS IT JE JM JO JP KE KG KH KI KM KN KP KR KW KY KZ LA LB LC LI LK LR LS LT LU LV LY MA MC MD ME MF MG MH MK ML MM MN MO MP MQ MR MS MT MU MV MW MX MY MZ NA NC NE NF NG NI NL NO NP NR NU NZ OM PA PE PF PG PH PK PL PM PN PR PS PT PW PY QA RE RO RS RU RW SA SB SC SD SE SG SH SI SJ SK SL SM SN SO SR SS ST SV SX SY SZ TC TD TF TG TH TJ TK TL TM TN TO TR TT TV TW TZ UA UG UM US UY UZ VA VC VE VG VI VN VU WF WS YE YT ZA ZM ZW`.split(` `);function fs(e,t=[],n=null){let r;try{r=new Intl.DisplayNames([e||`en`],{type:`region`})}catch{r={of:e=>e}}let i=(n??ds).map(e=>({code:e,name:r.of(e)??e})),a=i.filter(e=>t.includes(e.code)).sort((t,n)=>t.name.localeCompare(n.name,e||void 0)),o=i.filter(e=>!t.includes(e.code)).sort((t,n)=>t.name.localeCompare(n.name,e||void 0));return[...a,...o]}function ps(e,t,n){let r=t||`USD`;try{let t=new Intl.NumberFormat(n||void 0,{style:`currency`,currency:r}),i=t.resolvedOptions().maximumFractionDigits??2;return t.format(Number(e||0)/10**i)}catch{return`${(Number(e||0)/100).toFixed(2)} ${r}`}}var ms={en:{add:`Add to cart`,adding:`Adding…`,added:`Added to cart`,choose:`Choose options`,soldOut:`Sold out`,onlyLeft:`Only {n} left`,quantity:`Quantity`,cart:`Cart`,emptyCart:`Your cart is empty.`,subtotal:`Subtotal`,shipping:`Shipping`,free:`Free`,total:`Total`,remove:`Remove`,contact:`Contact`,name:`Full name`,email:`E-mail`,phone:`Phone`,address:`Delivery address`,line1:`Address`,line2:`Apartment, suite (optional)`,city:`City`,region:`State / province`,postal:`Postal code`,country:`Country`,note:`Order note (optional)`,gift:`This order is a gift`,giftHint:`No prices on the packing slip in the parcel.`,giftMessage:`Gift message (optional)`,giftRecipient:`Recipient’s name (optional — the parcel is addressed to them)`,payment:`Payment`,stripe:`Card`,bank_transfer:`Bank transfer`,cash_on_delivery:`Cash on delivery`,placeOrder:`Place order`,placing:`Placing order…`,required:`Please fill in the required fields.`,noMethods:`This shop has no payment method set up yet.`,thanks:`Thank you! Your order {number} is placed.`,paid:`Your payment was received.`,awaiting:`We are waiting for your payment to be confirmed.`,transfer:`Please transfer the total using the details below:`,reference:`Payment reference`,referenceNote:`Write this reference in the transfer description — it is how your payment is matched to your order.`,copy:`Copy`,copied:`Copied`,cod:`You will pay when the order is delivered.`,cancelled:`The payment was cancelled — your cart is still here.`,closed:`This shop is not open right now.`,continue:`Continue shopping`,noProducts:`No products yet.`,coupon:`Discount code`,apply:`Apply`,removeCoupon:`Remove`,discount:`Discount`,tax:`VAT`,taxIncluded:`incl. VAT`,chooseCountry:`Choose a country`,noShipping:`This shop does not ship to that country.`,delivery:`Delivery`,deliveryPick:`Enter your country to see the delivery options.`,arrives:`Arrives {date}`,arrivesRange:`Arrives {from} – {to}`,pickupAt:`Pick up at {name}`,pickupNote:`We will let you know when it is ready.`,deliveredBy:`Delivery: {name}`,SHIPPING_UNAVAILABLE:`This shop does not ship to that country.`,DELIVERY_UNAVAILABLE:`That delivery option is no longer available — pick another.`,COUPON_INVALID:`This code is not valid.`,COUPON_NOT_STARTED:`This code is not active yet.`,COUPON_EXPIRED:`This code has expired.`,COUPON_USED_UP:`This code has been used up.`,COUPON_MIN_SUBTOTAL:`Your cart is below this code’s minimum.`,COUPON_MIN_QUANTITY:`Add more items to use this code.`,COUPON_NOT_ELIGIBLE:`This code is not available for your account.`,COUPON_ALREADY_USED:`You have already used this code.`,COUPON_NOT_APPLICABLE:`None of the items in your cart qualify for this code.`,COUPON_NOT_COMBINABLE:`This code can’t be combined with a better discount already applied.`,COUPON_SHIPPING_NA:`This code doesn’t apply to this delivery.`,myOrders:`My orders`,signInForOrders:`Sign in to see your orders.`,noOrders:`You have no orders yet.`,order:`Order`,date:`Date`,status:`Status`,st_pending:`Pending`,st_processing:`Processing`,st_shipped:`Shipped`,downloads_title:`Your downloads`,download:`Download`,download_left:`{count} downloads left`,download_until:`valid until {date}`,download_expired:`expired on {date}`,download_unavailable:`No longer available`,policy_refund:`Refund policy`,policy_privacy:`Privacy policy`,policy_terms:`Terms of service`,policy_shipping:`Shipping policy`,policy_contact:`Contact information`,policy_legal:`Legal notice`,policy_agree:`By placing your order you agree to our {terms}.`,policy_updated:`Last updated {date}`,contact_email:`E-mail`,contact_phone:`Phone`,contact_address:`Address`,contact_trade:`Trade register / VAT number`,close:`Close`,tracking:`Tracking`,track_parcel:`Track parcel`,st_delivered:`Delivered`,st_cancelled:`Cancelled`,pay_unpaid:`Awaiting payment`,pay_refunded:`Refunded`,pay_failed:`Payment failed`,reviewsTitle:`Reviews`,reviewsCount:`{n} reviews`,reviewsOne:`1 review`,qaCount:`{n} Q&A`,lovedBy:`Loved! {n} people favorited this`,lovedByOne:`1 person favorited this`,favorite:`Add to favorites`,unfavorite:`Remove from favorites`,noReviews:`No reviews yet. Be the first to review this product.`,writeReview:`Write a review`,editReview:`Edit your review`,yourRating:`Your rating`,reviewTitle:`Title (optional)`,reviewBody:`What did you think?`,submitReview:`Submit review`,reviewPending:`Thanks! Your review appears here once the shop approves it.`,reviewThanks:`Thanks for your review!`,awaitingApproval:`Awaiting approval`,verified:`Verified purchase`,shopReply:`Reply from the shop`,signInToReview:`Sign in to write a review`,pickRating:`Choose a rating first.`,sortNewest:`Newest`,sortHighest:`Highest rated`,sortLowest:`Lowest rated`,sortHelpful:`Most detailed`,allRatings:`All ratings`,starsN:`{n} stars`,loadMore:`Show more`,questionsTitle:`Questions & answers`,noQuestions:`No questions yet.`,askQuestion:`Ask a question`,questionPlaceholder:`What would you like to know about this product?`,submitQuestion:`Send question`,questionPending:`Thanks! Your question appears here once the shop answers it.`,signInToAsk:`Sign in to ask a question`,answerLabel:`Answer`,qMark:`Q:`,aMark:`A:`,awaitingAnswer:`Waiting for an answer`,anonymous:`A customer`,myFavorites:`My favorites`,noFavorites:`You have no favorites yet.`,signInForFavorites:`Sign in to see your favorites`,REVIEW_BUYERS_ONLY:`Only customers who bought this product can review it.`,QUESTION_LIMIT:`You already have questions waiting for an answer.`,specifications:`Specifications`,yes:`Yes`,no:`No`},tr:{add:`Sepete ekle`,adding:`Ekleniyor…`,added:`Sepete eklendi`,choose:`Seçenekleri gör`,soldOut:`Tükendi`,onlyLeft:`Son {n} adet`,quantity:`Adet`,cart:`Sepet`,emptyCart:`Sepetiniz boş.`,subtotal:`Ara toplam`,shipping:`Kargo`,free:`Ücretsiz`,total:`Toplam`,remove:`Kaldır`,contact:`İletişim`,name:`Ad soyad`,email:`E-posta`,phone:`Telefon`,address:`Teslimat adresi`,line1:`Adres`,line2:`Daire, kat (isteğe bağlı)`,city:`Şehir`,region:`İlçe / bölge`,postal:`Posta kodu`,country:`Ülke`,note:`Sipariş notu (isteğe bağlı)`,gift:`Bu sipariş bir hediye`,giftHint:`Paketteki irsaliyede fiyat yer almaz.`,giftMessage:`Hediye notu (isteğe bağlı)`,giftRecipient:`Alıcının adı (isteğe bağlı — paket bu kişiye gönderilir)`,payment:`Ödeme`,stripe:`Kredi kartı`,bank_transfer:`Havale / EFT`,cash_on_delivery:`Kapıda ödeme`,placeOrder:`Siparişi ver`,placing:`Sipariş veriliyor…`,required:`Lütfen zorunlu alanları doldurun.`,noMethods:`Bu mağazada henüz bir ödeme yöntemi tanımlı değil.`,thanks:`Teşekkürler! {number} numaralı siparişiniz alındı.`,paid:`Ödemeniz alındı.`,awaiting:`Ödemenizin onaylanmasını bekliyoruz.`,transfer:`Lütfen toplam tutarı aşağıdaki bilgilere gönderin:`,reference:`Ödeme referansı`,referenceNote:`Bu referansı havale / EFT açıklamasına yazın — ödemeniz siparişinizle bu sayede eşleşir.`,copy:`Kopyala`,copied:`Kopyalandı`,cod:`Ödemeyi sipariş teslim edilirken yapacaksınız.`,cancelled:`Ödeme iptal edildi — sepetiniz duruyor.`,closed:`Bu mağaza şu anda açık değil.`,continue:`Alışverişe devam et`,noProducts:`Henüz ürün yok.`,coupon:`İndirim kodu`,apply:`Uygula`,removeCoupon:`Kaldır`,discount:`İndirim`,tax:`KDV`,taxIncluded:`dahil KDV`,chooseCountry:`Ülke seçin`,noShipping:`Bu mağaza o ülkeye gönderim yapmıyor.`,delivery:`Teslimat`,deliveryPick:`Teslimat seçeneklerini görmek için ülkenizi seçin.`,arrives:`Tahmini teslim: {date}`,arrivesRange:`Tahmini teslim: {from} – {to}`,pickupAt:`{name} mağazasından teslim alın`,pickupNote:`Hazır olduğunda size haber vereceğiz.`,deliveredBy:`Teslimat: {name}`,SHIPPING_UNAVAILABLE:`Bu mağaza o ülkeye gönderim yapmıyor.`,DELIVERY_UNAVAILABLE:`Bu teslimat seçeneği artık yok — başka birini seçin.`,COUPON_INVALID:`Bu kod geçerli değil.`,COUPON_NOT_STARTED:`Bu kod henüz aktif değil.`,COUPON_EXPIRED:`Bu kodun süresi dolmuş.`,COUPON_USED_UP:`Bu kodun kullanım hakkı dolmuş.`,COUPON_MIN_SUBTOTAL:`Sepetiniz bu kodun alt sınırının altında.`,COUPON_MIN_QUANTITY:`Bu kodu kullanmak için daha fazla ürün ekleyin.`,COUPON_NOT_ELIGIBLE:`Bu kod hesabınız için geçerli değil.`,COUPON_ALREADY_USED:`Bu kodu zaten kullandınız.`,COUPON_NOT_APPLICABLE:`Sepetinizdeki ürünlerden hiçbiri bu koda uygun değil.`,COUPON_NOT_COMBINABLE:`Bu kod, uygulanan daha avantajlı bir indirimle birleştirilemez.`,COUPON_SHIPPING_NA:`Bu kod bu teslimat için geçerli değil.`,myOrders:`Siparişlerim`,signInForOrders:`Siparişlerinizi görmek için giriş yapın.`,noOrders:`Henüz siparişiniz yok.`,order:`Sipariş`,date:`Tarih`,status:`Durum`,st_pending:`Bekliyor`,st_processing:`Hazırlanıyor`,st_shipped:`Kargoda`,downloads_title:`İndirmeleriniz`,download:`İndir`,download_left:`{count} indirme hakkı kaldı`,download_until:`{date} tarihine kadar geçerli`,download_expired:`{date} tarihinde sona erdi`,download_unavailable:`Artık kullanılamıyor`,policy_refund:`İade politikası`,policy_privacy:`Gizlilik politikası`,policy_terms:`Hizmet koşulları`,policy_shipping:`Kargo politikası`,policy_contact:`İletişim bilgileri`,policy_legal:`Yasal bildirim`,policy_agree:`Siparişi vererek {terms} kabul etmiş olursunuz.`,policy_updated:`Son güncelleme: {date}`,contact_email:`E-posta`,contact_phone:`Telefon`,contact_address:`Adres`,contact_trade:`Ticaret sicil / Vergi no`,close:`Kapat`,tracking:`Kargo takibi`,track_parcel:`Kargonu takip et`,st_delivered:`Teslim edildi`,st_cancelled:`İptal edildi`,pay_unpaid:`Ödeme bekleniyor`,pay_refunded:`İade edildi`,pay_failed:`Ödeme başarısız`,reviewsTitle:`Değerlendirmeler`,reviewsCount:`{n} Değerlendirme`,reviewsOne:`1 Değerlendirme`,qaCount:`{n} Soru-Cevap`,lovedBy:`Sevilen ürün! {n} kişi favoriledi!`,lovedByOne:`1 kişi favoriledi`,favorite:`Favorilere ekle`,unfavorite:`Favorilerden çıkar`,noReviews:`Henüz değerlendirme yok. İlk değerlendiren siz olun.`,writeReview:`Değerlendirme yaz`,editReview:`Değerlendirmenizi düzenleyin`,yourRating:`Puanınız`,reviewTitle:`Başlık (isteğe bağlı)`,reviewBody:`Ürün hakkında ne düşünüyorsunuz?`,submitReview:`Değerlendirmeyi gönder`,reviewPending:`Teşekkürler! Değerlendirmeniz mağaza onayladıktan sonra burada görünür.`,reviewThanks:`Değerlendirmeniz için teşekkürler!`,awaitingApproval:`Onay bekliyor`,verified:`Doğrulanmış alışveriş`,shopReply:`Mağazanın yanıtı`,signInToReview:`Değerlendirme yazmak için giriş yapın`,pickRating:`Önce bir puan seçin.`,sortNewest:`En yeni`,sortHighest:`En yüksek puan`,sortLowest:`En düşük puan`,sortHelpful:`En detaylı`,allRatings:`Tüm puanlar`,starsN:`{n} yıldız`,loadMore:`Daha fazla göster`,questionsTitle:`Soru-Cevap`,noQuestions:`Henüz soru yok.`,askQuestion:`Soru sor`,questionPlaceholder:`Bu ürün hakkında ne öğrenmek istersiniz?`,submitQuestion:`Soruyu gönder`,questionPending:`Teşekkürler! Sorunuz mağaza yanıtladıktan sonra burada görünür.`,signInToAsk:`Soru sormak için giriş yapın`,answerLabel:`Yanıt`,qMark:`S:`,aMark:`C:`,awaitingAnswer:`Yanıt bekliyor`,anonymous:`Bir müşteri`,myFavorites:`Favorilerim`,noFavorites:`Henüz favoriniz yok.`,signInForFavorites:`Favorilerinizi görmek için giriş yapın`,REVIEW_BUYERS_ONLY:`Bu ürünü yalnızca satın alan müşteriler değerlendirebilir.`,QUESTION_LIMIT:`Yanıt bekleyen sorularınız var.`,specifications:`Özellikler`,yes:`Evet`,no:`Hayır`}};function hs(e){let t=ms[String(e||``).toLowerCase().split(`-`)[0]]??ms.en,n=(e,n)=>{let r=t[e]??ms.en[e]??e;return n?r.replace(/\{(\w+)\}/g,(e,t)=>t in n?String(n[t]):e):r};return n.has=e=>e in ms.en,n}var gs=(e,t)=>t?.code&&e.has(t.code)?e(t.code):t?.message??``,_s=new Map;function vs(e,t){let n=`${e}|${t}`;return _s.has(n)||_s.set(n,os(e,t,`/store/policies`).then(e=>Array.isArray(e)?e:[]).catch(()=>(_s.delete(n),[]))),_s.get(n)}function ys(e){let t=new Date,n=Math.max(0,Math.round(Number(e)||0));for(;n>0;)t.setDate(t.getDate()+1),t.getDay()!==0&&t.getDay()!==6&&--n;return t}function bs(e,t,n,r){let i=e=>e!=null&&Number.isFinite(Number(e));if(!i(n)&&!i(r))return``;let a;try{a=new Intl.DateTimeFormat(t||`en`,{month:`short`,day:`numeric`})}catch{a=new Intl.DateTimeFormat(`en`,{month:`short`,day:`numeric`})}let o=a.format(ys(i(n)?n:r)),s=a.format(ys(i(r)?r:n));return o===s?e(`arrives`,{date:o}):e(`arrivesRange`,{from:o,to:s})}var xs=`var(--page-muted, rgba(100,116,139,1))`,Ss=`1px solid var(--page-border, #d1d5db)`,Cs=`var(--page-surface, #f2f2f2)`,ws=`#f59e0b`,Ts={...lr,border:0,borderRadius:`8px`,padding:`10px 18px`,fontSize:`14px`,fontWeight:600,fontFamily:`inherit`},Es={...Ts,backgroundColor:`transparent`,color:`var(--page-text, #111827)`,border:Ss};function Ds(){let{tenant:e,apiUrl:t,locale:n,settings:r}=(0,l.useContext)(Nn),i=(0,l.useMemo)(()=>hs(n),[n]),a=e=>r?.[e]!==!1;return{tenant:e,apiUrl:t||`/api`,locale:n,words:i,reviewsOn:a(`shop.reviews`),questionsOn:a(`shop.questions`),favoritesOn:a(`shop.favorites`),moderated:r?.[`shop.reviewModeration`]!==`auto`,loginHref:()=>{let e=jo(r).loginPage||`/login`,t=typeof window>`u`?``:`${window.location.pathname}${window.location.search}`;return t?`${e}${e.includes(`?`)?`&`:`?`}next=${encodeURIComponent(t)}`:e}}}var Os=(e,t)=>{try{return new Intl.NumberFormat(t||void 0,{notation:`compact`,maximumFractionDigits:1}).format(e)}catch{return String(e)}},ks=(e,t)=>{try{return new Intl.DateTimeFormat(t||void 0,{day:`numeric`,month:`long`,year:`numeric`}).format(new Date(e))}catch{return String(e).slice(0,10)}},As=`M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z`;function js({fill:e=0,size:t=16,clipId:n}){return(0,W.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,"aria-hidden":`true`,style:{display:`block`},children:[(0,W.jsx)(`defs`,{children:(0,W.jsx)(`clipPath`,{id:n,children:(0,W.jsx)(`rect`,{x:`0`,y:`0`,width:24*e,height:`24`})})}),(0,W.jsx)(`path`,{d:As,fill:`var(--page-border, #d1d5db)`}),e>0&&(0,W.jsx)(`path`,{d:As,fill:ws,clipPath:`url(#${n})`})]})}function Ms({value:e=0,size:t=16}){let n=(0,l.useId)().replace(/:/g,``);return(0,W.jsx)(`span`,{role:`img`,"aria-label":`${e}/5`,...G(`stars`),style:{display:`inline-flex`,gap:`1px`,verticalAlign:`middle`},children:[0,1,2,3,4].map(r=>(0,W.jsx)(js,{fill:Math.max(0,Math.min(1,e-r)),size:t,clipId:`${n}-${r}`},r))})}function Ns({value:e,onChange:t,size:n=28,label:r}){let i=(0,l.useId)().replace(/:/g,``),[a,o]=(0,l.useState)(0),s=a||e;return(0,W.jsx)(`span`,{role:`radiogroup`,"aria-label":r,...G(`star-picker`),style:{display:`inline-flex`,gap:`2px`},onMouseLeave:()=>o(0),children:[1,2,3,4,5].map(r=>(0,W.jsx)(`button`,{type:`button`,role:`radio`,"aria-checked":e===r,"aria-label":String(r),onMouseEnter:()=>o(r),onClick:()=>t(r),style:{background:`none`,border:0,padding:0,cursor:`pointer`,lineHeight:0},children:(0,W.jsx)(js,{fill:+(s>=r),size:n,clipId:`${i}-${r}`})},r))})}function Ps(e,{inert:t}){let{tenant:n,apiUrl:r,favoritesOn:i}=Ds(),[a,o]=(0,l.useState)({favorited:!1,count:null});(0,l.useEffect)(()=>{if(!e||!i||t)return;let a=!0;return os(r,n,`/store/products/${encodeURIComponent(e)}/favorite`).then(e=>a&&o(e)).catch(()=>{}),()=>{a=!1}},[r,n,e,i,t]);let s=async()=>{let t=!a.favorited;o(e=>({favorited:t,count:Math.max(0,(e.count??0)+(t?1:-1))}));try{o(await os(r,n,`/store/products/${encodeURIComponent(e)}/favorite`,{method:`POST`,body:{on:t}}))}catch(e){throw o(e=>({favorited:!t,count:Math.max(0,(e.count??0)+(t?-1:1))})),e}};return{...a,toggle:s}}var Fs=e=>(0,W.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,"aria-hidden":`true`,style:{display:`block`},children:(0,W.jsx)(`path`,{d:`M12 21s-7.5-4.6-9.6-9.2C.9 8.4 3 4.5 6.8 4.5c2.1 0 3.6 1.1 5.2 3 1.6-1.9 3.1-3 5.2-3 3.8 0 5.9 3.9 4.4 7.3C19.5 16.4 12 21 12 21z`,fill:e?`#ef4444`:`none`,stroke:e?`#ef4444`:`currentColor`,strokeWidth:`1.8`})});function Is({product:e,inert:t=!1,sample:n=!1}){let{locale:r,words:i,reviewsOn:a,questionsOn:o,favoritesOn:s,loginHref:c}=Ds(),u=e?.sample?``:e?.slug||e?.id||``,d=Ps(u,{inert:t||!u}),[f,p]=(0,l.useState)(``),m=n?29:e?.rating_count??0,h=n?4.3:Number(e?.rating_avg??0),g=n?110:e?.questions_count??0,_=n?1300:d.count??e?.favorites_count??0,v=e=>n=>{n.preventDefault(),!t&&document.getElementById(e)?.scrollIntoView({behavior:`smooth`,block:`start`})},y=async()=>{if(!(t||!u))try{await d.toggle()}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(c()):p(gs(i,e))}},b=[];return a&&m>0&&b.push((0,W.jsxs)(`span`,{...G(`rating`),style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,W.jsx)(`strong`,{...G(`rating-value`),children:h.toLocaleString(r||void 0,{minimumFractionDigits:1,maximumFractionDigits:1})}),(0,W.jsx)(Ms,{value:h}),(0,W.jsx)(`a`,{href:`#reviews`,onClick:v(`reviews`),...G(`rating-link`),style:{color:`inherit`},children:m===1?i(`reviewsOne`):i(`reviewsCount`,{n:Os(m,r)})})]},`r`)),o&&g>0&&b.push((0,W.jsx)(`a`,{href:`#questions`,onClick:v(`questions`),...G(`qa-link`),style:{color:`inherit`},children:i(`qaCount`,{n:Os(g,r)})},`q`)),!b.length&&!s?null:(0,W.jsxs)(`div`,{...G(`engagement`),style:{display:`flex`,flexDirection:`column`,gap:`8px`,fontSize:`14px`},children:[b.length>0&&(0,W.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:b.flatMap((e,t)=>t?[(0,W.jsx)(`span`,{...G(`separator`),style:{color:xs},children:`•`},`s${t}`),e]:[e])}),s&&(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`},children:[(0,W.jsx)(`button`,{type:`button`,onClick:y,...G(`favorite-button`,d.favorited&&`favorite-button-active`),"aria-pressed":d.favorited,"aria-label":d.favorited?i(`unfavorite`):i(`favorite`),title:d.favorited?i(`unfavorite`):i(`favorite`),style:{...Es,padding:`7px`,borderRadius:`999px`,lineHeight:0},children:Fs(d.favorited)}),_>0&&(0,W.jsx)(`span`,{...G(`favorites-count`),style:{fontWeight:600},children:_===1?i(`lovedByOne`):i(`lovedBy`,{n:Os(_,r)})})]}),f&&(0,W.jsx)(`span`,{...G(`note`),style:{color:xs,fontSize:`13px`},children:f})]})}var Ls={data:[{id:`s1`,author:`Ayşe Y.`,rating:5,title:`Harika`,body:`Beklediğimden de iyi çıktı.`,verified:!0,reply:``,created_at:new Date().toISOString()},{id:`s2`,author:`Mehmet K.`,rating:4,title:``,body:`Kaliteli, kargo biraz gecikti.`,verified:!1,reply:`Geri bildiriminiz için teşekkürler!`,created_at:new Date(Date.now()-864e5*3).toISOString()}],total:{all:29,filtered:29},summary:{average:4.3,count:29,histogram:[1,1,3,6,18]}};function Rs({product:e,inert:t=!1,sample:n=!1}){let{tenant:r,apiUrl:i,locale:a,words:o,reviewsOn:s,moderated:c,loginHref:u}=Ds(),d=Fo(),f=e?.sample?``:e?.slug||e?.id||``,[p,m]=(0,l.useState)(null),[h,g]=(0,l.useState)(`newest`),[_,v]=(0,l.useState)(0),[y,b]=(0,l.useState)(5),[x,S]=(0,l.useState)(0),[C,w]=(0,l.useState)({rating:0,title:``,body:``}),[T,E]=(0,l.useState)(!1),[D,O]=(0,l.useState)(!1),[k,A]=(0,l.useState)(``);if((0,l.useEffect)(()=>{if(!s||!f)return;let e=!0,t=`?limit=${y}&sort=${h}${_?`&rating=${_}`:``}`;return os(i,r,`/store/products/${encodeURIComponent(f)}/reviews${t}`).then(t=>e&&m(t)).catch(()=>e&&m({data:[],total:{all:0,filtered:0},summary:{average:0,count:0,histogram:[0,0,0,0,0]}})),()=>{e=!1}},[i,r,f,h,_,y,x,s]),!s)return null;let j=n||!f?Ls:p,M=j?.summary??{average:0,count:0,histogram:[0,0,0,0,0]},N=j?.data?.find(e=>e.mine),P=d.status===`user`,F=()=>{if(!t){if(!P){window.location.assign(u());return}w(N?{rating:N.rating,title:N.title,body:N.body}:{rating:0,title:``,body:``}),A(``),E(!0)}},I=async e=>{if(e.preventDefault(),!C.rating){A(o(`pickRating`));return}O(!0),A(``);try{await os(i,r,`/store/products/${encodeURIComponent(f)}/reviews`,{method:`POST`,body:C}),E(!1),A(o(c?`reviewPending`:`reviewThanks`)),S(e=>e+1)}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(u()):A(gs(o,e))}finally{O(!1)}},L=Math.max(1,...M.histogram);return(0,W.jsxs)(`section`,{id:`reviews`,...G(`reviews`),style:{display:`flex`,flexDirection:`column`,gap:`16px`,scrollMarginTop:`80px`},children:[(0,W.jsx)(`h2`,{...G(`reviews-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:o(`reviewsTitle`)}),(0,W.jsxs)(`div`,{...G(`reviews-summary`),style:{display:`flex`,gap:`32px`,flexWrap:`wrap`,alignItems:`center`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,alignItems:`flex-start`,gap:`4px`},children:[(0,W.jsx)(`span`,{...G(`reviews-average`),style:{fontSize:`40px`,fontWeight:700,lineHeight:1},children:M.count?M.average.toLocaleString(a||void 0,{minimumFractionDigits:1,maximumFractionDigits:1}):`–`}),(0,W.jsx)(Ms,{value:M.average,size:18}),(0,W.jsx)(`span`,{...G(`reviews-count`),style:{color:xs,fontSize:`13px`},children:M.count===1?o(`reviewsOne`):o(`reviewsCount`,{n:M.count})})]}),(0,W.jsx)(`div`,{...G(`histogram`),style:{display:`flex`,flexDirection:`column`,gap:`4px`,minWidth:`220px`,flex:`1 1 220px`,maxWidth:`360px`},children:[5,4,3,2,1].map(e=>{let n=M.histogram[e-1]??0,r=_===e;return(0,W.jsxs)(`button`,{type:`button`,disabled:!n&&!r,onClick:()=>!t&&v(r?0:e),title:o(`starsN`,{n:e}),...G(`histogram-row`,r&&`histogram-row-active`),style:{display:`grid`,gridTemplateColumns:`28px 1fr 32px`,alignItems:`center`,gap:`8px`,background:`none`,border:0,padding:`2px 0`,cursor:n?`pointer`:`default`,color:`inherit`,fontFamily:`inherit`,fontSize:`13px`,fontWeight:r?700:400},children:[(0,W.jsxs)(`span`,{children:[e,`★`]}),(0,W.jsx)(`span`,{...G(`histogram-track`),style:{height:`8px`,borderRadius:`4px`,background:Cs,overflow:`hidden`},children:(0,W.jsx)(`span`,{...G(`histogram-bar`),style:{display:`block`,height:`100%`,width:`${n/L*100}%`,background:ws}})}),(0,W.jsx)(`span`,{style:{color:xs,textAlign:`right`},children:n})]},e)})}),(0,W.jsx)(`div`,{style:{marginLeft:`auto`},children:(0,W.jsx)(`button`,{type:`button`,onClick:F,...G(`review-button`),style:Ts,children:o(P||t?N?`editReview`:`writeReview`:`signInToReview`)})})]}),T&&(0,W.jsxs)(`form`,{onSubmit:I,...G(`review-form`),style:{display:`flex`,flexDirection:`column`,gap:`10px`,padding:`16px`,border:Ss,borderRadius:`12px`},children:[(0,W.jsxs)(`label`,{...G(`label`),style:{display:`flex`,alignItems:`center`,gap:`12px`,fontWeight:600},children:[o(`yourRating`),(0,W.jsx)(Ns,{value:C.rating,label:o(`yourRating`),onChange:e=>w(t=>({...t,rating:e}))})]}),(0,W.jsx)(`input`,{value:C.title,maxLength:150,placeholder:o(`reviewTitle`),...G(`input`),onChange:e=>w(t=>({...t,title:e.target.value})),style:q}),(0,W.jsx)(`textarea`,{value:C.body,maxLength:4e3,rows:4,placeholder:o(`reviewBody`),...G(`textarea`),onChange:e=>w(t=>({...t,body:e.target.value})),style:{...q,resize:`vertical`,fontFamily:`inherit`}}),(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,W.jsx)(`button`,{type:`submit`,disabled:D,...G(`submit-button`),style:Ts,children:o(`submitReview`)}),(0,W.jsx)(`button`,{type:`button`,onClick:()=>E(!1),...G(`cancel-button`),style:Es,children:`✕`})]})]}),k&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:xs},children:k}),(0,W.jsxs)(`div`,{...G(`reviews-toolbar`),style:{display:`flex`,alignItems:`center`,gap:`12px`,flexWrap:`wrap`},children:[(0,W.jsxs)(`select`,{value:h,onChange:e=>g(e.target.value),disabled:t,...G(`sort-select`),style:{...q,width:`auto`},children:[(0,W.jsx)(`option`,{value:`newest`,children:o(`sortNewest`)}),(0,W.jsx)(`option`,{value:`helpful`,children:o(`sortHelpful`)}),(0,W.jsx)(`option`,{value:`highest`,children:o(`sortHighest`)}),(0,W.jsx)(`option`,{value:`lowest`,children:o(`sortLowest`)})]}),_>0&&(0,W.jsxs)(`button`,{type:`button`,onClick:()=>v(0),...G(`filter-chip`),style:{...Es,padding:`6px 12px`},children:[o(`starsN`,{n:_}),` ✕`]})]}),j&&!j.data.length&&(0,W.jsx)(`p`,{...G(`empty`),style:{margin:0,color:xs},children:o(`noReviews`)}),(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`},children:(j?.data??[]).map(e=>(0,W.jsxs)(`article`,{...G(`review`),style:{padding:`16px 0`,borderTop:Ss,display:`flex`,flexDirection:`column`,gap:`6px`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:[(0,W.jsx)(Ms,{value:e.rating}),e.title&&(0,W.jsx)(`strong`,{...G(`review-title`),children:e.title}),e.mine&&e.status===`pending`&&(0,W.jsx)(`span`,{...G(`badge`),style:{fontSize:`12px`,padding:`2px 8px`,borderRadius:`999px`,background:Cs,color:xs},children:o(`awaitingApproval`)})]}),e.body&&(0,W.jsx)(`p`,{...G(`review-body`),style:{margin:0,whiteSpace:`pre-wrap`,lineHeight:1.55},children:e.body}),(0,W.jsxs)(`span`,{...G(`meta`),style:{fontSize:`13px`,color:xs},children:[e.author||o(`anonymous`),` · `,ks(e.created_at,a),e.verified&&(0,W.jsxs)(`span`,{...G(`verified`),style:{color:`#16a34a`,fontWeight:600},children:[` · ✓ `,o(`verified`)]})]}),e.reply&&(0,W.jsxs)(`div`,{...G(`reply`),style:{marginTop:`4px`,padding:`10px 12px`,borderRadius:`8px`,background:Cs,fontSize:`14px`},children:[(0,W.jsx)(`strong`,{...G(`reply-label`),style:{display:`block`,fontSize:`12px`,color:xs,marginBottom:`2px`},children:o(`shopReply`)}),(0,W.jsx)(`span`,{style:{whiteSpace:`pre-wrap`},children:e.reply})]})]},e.id))}),j&&j.data.length<(j.total?.filtered??0)&&!t&&(0,W.jsx)(`button`,{type:`button`,onClick:()=>b(e=>e+10),...G(`load-more`),style:{...Es,alignSelf:`center`},children:o(`loadMore`)})]})}var zs={data:[{id:`q1`,author:`Can D.`,question:`Bulaşık makinesinde yıkanır mı?`,answer:`Evet, yıkanabilir.`,created_at:new Date().toISOString()}],total:{all:1,filtered:1}};function Bs({product:e,inert:t=!1,sample:n=!1}){let{tenant:r,apiUrl:i,locale:a,words:o,questionsOn:s,loginHref:c}=Ds(),u=Fo(),d=e?.sample?``:e?.slug||e?.id||``,[f,p]=(0,l.useState)(null),[m,h]=(0,l.useState)(5),[g,_]=(0,l.useState)(0),[v,y]=(0,l.useState)(``),[b,x]=(0,l.useState)(!1),[S,C]=(0,l.useState)(``);if((0,l.useEffect)(()=>{if(!s||!d)return;let e=!0;return os(i,r,`/store/products/${encodeURIComponent(d)}/questions?limit=${m}`).then(t=>e&&p(t)).catch(()=>e&&p({data:[],total:{all:0,filtered:0}})),()=>{e=!1}},[i,r,d,m,g,s]),!s)return null;let w=n||!d?zs:f,T=u.status===`user`,E=async e=>{if(e.preventDefault(),!(t||v.trim().length<3)){if(!T){window.location.assign(c());return}x(!0),C(``);try{await os(i,r,`/store/products/${encodeURIComponent(d)}/questions`,{method:`POST`,body:{question:v.trim()}}),y(``),C(o(`questionPending`)),_(e=>e+1)}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(c()):C(gs(o,e))}finally{x(!1)}}};return(0,W.jsxs)(`section`,{id:`questions`,...G(`questions`),style:{display:`flex`,flexDirection:`column`,gap:`16px`,scrollMarginTop:`80px`},children:[(0,W.jsx)(`h2`,{...G(`questions-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:o(`questionsTitle`)}),T||t?(0,W.jsxs)(`form`,{onSubmit:E,...G(`question-form`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:[(0,W.jsx)(`input`,{value:v,maxLength:1e3,placeholder:o(`questionPlaceholder`),...G(`input`),onChange:e=>y(e.target.value),style:{...q,flex:`1 1 260px`}}),(0,W.jsx)(`button`,{type:`submit`,disabled:b||v.trim().length<3,...G(`submit-button`),style:Ts,children:o(`submitQuestion`)})]}):(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:c(),...G(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:o(`signInToAsk`)})}),S&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:xs},children:S}),w&&!w.data.length&&(0,W.jsx)(`p`,{...G(`empty`),style:{margin:0,color:xs},children:o(`noQuestions`)}),(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`},children:(w?.data??[]).map(e=>(0,W.jsxs)(`article`,{...G(`question`),style:{padding:`14px 0`,borderTop:Ss,display:`flex`,flexDirection:`column`,gap:`6px`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`baseline`},children:[(0,W.jsx)(`strong`,{...G(`question-mark`),style:{color:`var(--page-accent, #111827)`},children:o(`qMark`)}),(0,W.jsx)(`span`,{...G(`question-text`),style:{fontWeight:600},children:e.question})]}),e.answer?(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`baseline`},children:[(0,W.jsx)(`strong`,{...G(`answer-mark`),style:{color:`#16a34a`},children:o(`aMark`)}),(0,W.jsx)(`span`,{...G(`answer-text`),style:{whiteSpace:`pre-wrap`},children:e.answer})]}):(0,W.jsx)(`span`,{...G(`badge`),style:{fontSize:`12px`,color:xs},children:o(`awaitingAnswer`)}),(0,W.jsxs)(`span`,{...G(`meta`),style:{fontSize:`12px`,color:xs},children:[e.author||o(`anonymous`),` · `,ks(e.created_at,a)]})]},e.id))}),w&&w.data.length<(w.total?.filtered??0)&&!t&&(0,W.jsx)(`button`,{type:`button`,onClick:()=>h(e=>e+10),...G(`load-more`),style:{...Es,alignSelf:`center`},children:o(`loadMore`)})]})}var Vs=`1px solid var(--page-border, #d1d5db)`,Hs=`var(--page-muted, rgba(100,116,139,1))`,Us=e=>/^(https?:)?\/\//i.test(String(e))||String(e).startsWith(`/`)?String(e):``;function Ws(e,t,n,r){let i=n||void 0;switch(e.type){case`integer`:case`number`:return Number(t).toLocaleString(i);case`money`:try{return new Intl.NumberFormat(i,{style:`currency`,currency:t.currency}).format(t.amount)}catch{return`${t.amount} ${t.currency}`}case`measurement`:return`${Number(t.value).toLocaleString(i)} ${String(t.unit).replace(`_`,` `)}`;case`rating`:{let n=Number(e.config?.max??5);return(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[n===5&&(0,W.jsx)(Ms,{value:Number(t)}),Number(t).toLocaleString(i),` / `,n]})}case`date`:case`datetime`:try{return new Intl.DateTimeFormat(i,e.type===`date`?{day:`numeric`,month:`long`,year:`numeric`}:{dateStyle:`medium`,timeStyle:`short`}).format(new Date(t))}catch{return String(t)}case`switch`:return r(t?`yes`:`no`);case`color`:return(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,W.jsx)(`span`,{style:{width:`14px`,height:`14px`,borderRadius:`4px`,background:t,border:Vs,display:`inline-block`}}),t]});case`link`:{let e=Us(t);return e?(0,W.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`},children:t}):String(t)}case`image`:return Us(t)?(0,W.jsx)(`img`,{src:t,alt:e.name,style:{maxWidth:`160px`,maxHeight:`120px`,borderRadius:`6px`,display:`block`}}):``;case`video`:case`file`:return Us(t)?(0,W.jsx)(`a`,{href:t,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`},children:String(t).split(`/`).pop()}):``;case`media`:return(Array.isArray(t)?t:[t]).filter(Us).map((e,t)=>(0,W.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`,marginRight:`8px`},children:String(e).split(`/`).pop()},t));case`language`:try{return new Intl.DisplayNames([n||`en`],{type:`language`}).of(t)??t}catch{return String(t)}case`product`:return t?.slug?(0,W.jsx)(`a`,{href:`/product/${encodeURIComponent(t.slug)}`,style:{color:`var(--page-accent, #111827)`},children:t.name}):``;case`page`:return t?.slug?(0,W.jsx)(`a`,{href:`/${t.slug}`,style:{color:`var(--page-accent, #111827)`},children:t.name}):``;case`shop_collection`:return t?.name??``;case`richtext`:return Array.isArray(t)?(0,W.jsx)(`div`,{style:{lineHeight:1.55},children:jr(t)}):String(t);case`json`:return(0,W.jsx)(`code`,{style:{fontSize:`12px`,whiteSpace:`pre-wrap`},children:JSON.stringify(t)});default:return String(t)}}function Gs({specs:e,locale:t,words:n}){return!Array.isArray(e)||!e.length?null:(0,W.jsxs)(`section`,{...G(`specs`),style:{display:`flex`,flexDirection:`column`,gap:`12px`},children:[(0,W.jsx)(`h2`,{...G(`specs-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:n(`specifications`)}),(0,W.jsx)(`div`,{role:`table`,...G(`specs-table`),style:{border:Vs,borderRadius:`10px`,overflow:`hidden`},children:e.map((e,r)=>{let i=e.multiple&&Array.isArray(e.value)?e.value:[e.value];return(0,W.jsxs)(`div`,{role:`row`,...G(`spec-row`),style:{display:`grid`,gridTemplateColumns:`minmax(120px, 34%) 1fr`,gap:`16px`,padding:`10px 14px`,borderTop:r?Vs:0,fontSize:`14px`},children:[(0,W.jsx)(`span`,{role:`rowheader`,...G(`spec-name`),style:{color:Hs},children:e.name}),(0,W.jsx)(`span`,{role:`cell`,...G(`spec-value`),style:{display:`flex`,flexWrap:`wrap`,gap:`4px 10px`,alignItems:`center`},children:i.map((r,a)=>(0,W.jsxs)(`span`,{children:[Ws(e,r,t,n),a<i.length-1&&e.type!==`color`?`,`:``]},a))})]},e.key)})})]})}var Y=`var(--page-muted, rgba(100,116,139,1))`,Ks=`1px solid var(--page-border, #d1d5db)`,qs=`var(--page-surface, #f2f2f2)`,Js={...lr,border:0,borderRadius:`8px`,padding:`10px 18px`,fontSize:`14px`,fontWeight:600,fontFamily:`inherit`,textAlign:`center`},Ys={...Js,backgroundColor:`transparent`,color:`var(--page-text, #111827)`,border:Ks};function Xs(){let{tenant:e,apiUrl:t,locale:n,param:r,settings:i}=(0,l.useContext)(Nn),a=(0,l.useMemo)(()=>hs(n),[n]),o=i?.[`shop.orderPrefix`],s=i?.[`shop.orderSuffix`],c=(0,l.useCallback)(e=>`${typeof o==`string`?o:`#`}${e}${typeof s==`string`?s:``}`,[o,s]);return{tenant:e,apiUrl:t||`/api`,locale:n,param:r||``,words:a,orderId:c}}function Zs(e,t,n=!0){let r=(0,l.useMemo)(()=>ls(e,t),[e,t]),i=(0,l.useSyncExternalStore)(r.subscribe,r.getState,r.getState);return(0,l.useEffect)(()=>{n&&!i.loaded&&!i.loading&&r.load()},[n,r]),{store:r,...i}}var Qs=e=>typeof window>`u`?``:new URLSearchParams(window.location.search).get(e)??``;function $s({value:e,label:t,onCommit:n}){let[r,i]=(0,l.useState)(null),a=()=>{if(r===null)return;let t=Math.max(1,Math.round(Number(r))||1);i(null),t!==Number(e)&&n(t)};return(0,W.jsx)(`input`,{type:`number`,...G(`quantity-input`),min:1,"aria-label":t,value:r??e,onChange:e=>i(e.target.value),onBlur:a,onKeyDown:e=>{e.key===`Enter`&&a()},style:{...q,width:`64px`,padding:`4px 8px`}})}var ec=`/product/{slug}`,tc=e=>!e||e===`/product?product={slug}`?ec:e,nc=(e,t)=>String(tc(e)).replace(/\{slug\}/g,encodeURIComponent(t.slug)).replace(/\{id\}/g,t.id);function rc(e){let t=e.variants?.length?e.variants.map(e=>e.stock):[e.stock];return t.some(e=>e==null)?null:t.reduce((e,t)=>e+Number(t),0)}function ic({product:e,variant:t,locale:n,size:r=16}){let i=e.currency,a=t?.price??e.price;return(0,W.jsxs)(`span`,{...G(`price`),style:{display:`inline-flex`,alignItems:`baseline`,gap:`8px`,fontSize:`${r}px`},children:[(0,W.jsx)(`span`,{...G(`price-current`),style:{fontWeight:700},children:ps(a,i,n)}),e.compare_at_price>a&&(0,W.jsx)(`span`,{...G(`price-old`),style:{color:Y,textDecoration:`line-through`,fontSize:`0.85em`},children:ps(e.compare_at_price,i,n)})]})}var ac=[1,2,3].map(e=>({id:`sample-${e}`,slug:`sample-${e}`,name:`Product ${e}`,price:e*1990,compare_at_price:e===2?4990:null,images:[],variants:[],stock:null,currency:`USD`,sample:!0}));function oc({columns:e=3,limit:t=12,gap:n=20,productHref:r=`/product/{slug}`,showButton:i=!0,buttonLabel:a=``,emptyText:o=``,collection:s=``,source:c=`catalog`,loginHref:u=``,style:d,nodeRef:f,inert:p=!1,sample:m=!1,noNavigate:h=!1}){let{tenant:g,apiUrl:_,locale:v,words:y}=Xs(),b=Ds(),[x,S]=(0,l.useState)(null),[C,w]=(0,l.useState)(null),[T,E]=(0,l.useState)(``),[D,O]=(0,l.useState)({}),[k,A]=(0,l.useState)(!1),{store:j,currency:M}=Zs(_,g,!p),N=c===`favorites`;(0,l.useEffect)(()=>{let e=!0,n=Math.max(1,Math.min(100,Number(t)||12)),r=M?`&currency=${encodeURIComponent(M)}`:``;if(N&&p){S([]);return}return A(!1),Promise.all([os(_,g,N?`/store/my/favorites?limit=${n}${r}`:`/store/products?limit=${n}${r}${s?`&collection=${encodeURIComponent(s)}`:``}`),os(_,g,`/store/config`)]).then(([t,n])=>{if(!e)return;let r=us(n,M);w(n),S(Array.isArray(t?.data)?t.data.map(e=>({...e,currency:r})):[])}).catch(t=>{e&&(A(N&&t?.code===`LOGIN_REQUIRED`),S([]))}),()=>{e=!1}},[_,g,t,M,s,N,p]);let P=x?.length||!m?x??[]:ac,F=async e=>{if(!(p||e.sample)){E(e.id);try{await j.add(e.id,null,1),O(t=>({...t,[e.id]:y(`added`)}))}catch(t){O(n=>({...n,[e.id]:gs(y,t)}))}finally{E(``)}}};return(0,W.jsxs)(`div`,{ref:f,style:{...z(d)},children:[N&&(0,W.jsx)(`h2`,{...G(`title`),style:{margin:`0 0 12px`,fontSize:`22px`},children:y(`myFavorites`)}),k&&(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:u||b.loginHref(),onClick:h?e=>e.preventDefault():void 0,...G(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:y(`signInForFavorites`)})}),x!==null&&!k&&!P.length&&(0,W.jsx)(`p`,{...G(`empty`),style:{color:Y,margin:0},children:o||(N?y(`noFavorites`):C&&!C.enabled?y(`closed`):y(`noProducts`))}),(0,W.jsx)(`div`,{...G(`grid`),style:{display:`grid`,gridTemplateColumns:`repeat(auto-fill, minmax(min(100%, max(160px, calc((100% - ${(Number(e)-1)*n}px) / ${Number(e)||3}))), 1fr))`,gap:`${n}px`},children:P.map(e=>{let t=rc(e)===0,n=nc(r,e);return(0,W.jsxs)(`div`,{...G(`card`),style:{display:`flex`,flexDirection:`column`,gap:`10px`},children:[(0,W.jsxs)(`a`,{href:n,onClick:h?e=>e.preventDefault():void 0,...G(`card-link`),style:{color:`inherit`,textDecoration:`none`},children:[(0,W.jsx)(`div`,{...G(`card-media`),style:{aspectRatio:`1 / 1`,borderRadius:`10px`,overflow:`hidden`,background:qs},children:e.images?.[0]&&(0,W.jsx)(`img`,{src:e.images[0],alt:e.name,loading:`lazy`,...G(`card-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),(0,W.jsx)(`div`,{...G(`card-title`),style:{marginTop:`10px`,fontWeight:600},children:e.name})]}),b.reviewsOn&&e.rating_count>0&&(0,W.jsxs)(`span`,{...G(`card-rating`),style:{display:`inline-flex`,alignItems:`center`,gap:`6px`,fontSize:`13px`,color:Y},children:[(0,W.jsx)(Ms,{value:Number(e.rating_avg),size:14}),`(`,Os(e.rating_count,v),`)`]}),(0,W.jsx)(ic,{product:e,locale:v}),i&&(e.variants?.length?(0,W.jsx)(`a`,{href:n,onClick:h?e=>e.preventDefault():void 0,...G(`choose-button`),style:{...Ys,display:`block`},children:y(`choose`)}):(0,W.jsx)(`button`,{type:`button`,disabled:t||T===e.id,onClick:()=>F(e),...G(`add-button`,t&&`add-button-sold-out`),style:{...Js,opacity:t?.5:1},children:t?y(`soldOut`):T===e.id?y(`adding`):a||y(`add`)})),D[e.id]&&(0,W.jsx)(`span`,{...G(`note`),style:{fontSize:`13px`,color:Y},children:D[e.id]})]},e.id)})})]})}function sc({slug:e=``,buttonLabel:t=``,showReviews:n=!0,showQuestions:r=!0,showSpecs:i=!0,style:a,nodeRef:o,inert:s=!1,sample:c=!1,noNavigate:u=!1}){let{tenant:d,apiUrl:f,locale:p,param:m,words:h}=Xs(),[g,_]=(0,l.useState)(null),[v,y]=(0,l.useState)(!1),[b,x]=(0,l.useState)(0),[S,C]=(0,l.useState)(``),[w,T]=(0,l.useState)(1),[E,D]=(0,l.useState)(!1),[O,k]=(0,l.useState)(``),{store:A,currency:j}=Zs(f,d,!s),M=e||m||Qs(`product`),N=j?`?currency=${encodeURIComponent(j)}`:``;if((0,l.useEffect)(()=>{let e=!0;return y(!1),(async()=>{let t=await os(f,d,`/store/config`),n=M?await os(f,d,`/store/products/${encodeURIComponent(M)}${N}`):c||u?(await os(f,d,`/store/products?limit=1${j?`&currency=${encodeURIComponent(j)}`:``}`))?.data?.[0]:null;if(e){if(!n){y(!0),_(c?ac[0]:null);return}_({...n,currency:us(t,j)}),C(e=>n.variants?.some(t=>t.id===e)?e:n.variants?.[0]?.id??``),x(0)}})().catch(()=>{e&&(y(!0),_(c?ac[0]:null))}),()=>{e=!1}},[f,d,M,j]),!g)return(0,W.jsx)(`div`,{ref:o,style:{...z(a)},children:v&&(0,W.jsx)(`p`,{...G(`empty`),style:{color:Y,margin:0},children:h(`noProducts`)})});let P=g.variants?.find(e=>e.id===S)??null,F=P?P.stock:g.variants?.length?null:g.stock,I=F===0,L=async()=>{if(!(s||g.sample)){D(!0),k(``);try{await A.add(g.id,P?.id??null,Math.max(1,Number(w)||1)),k(h(`added`))}catch(e){k(gs(h,e))}finally{D(!1)}}};return(0,W.jsxs)(`div`,{ref:o,style:{display:`flex`,flexDirection:`column`,gap:`48px`,...z(a)},children:[(0,W.jsxs)(`div`,{...G(`details`),style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 320px), 1fr))`,gap:`32px`},children:[(0,W.jsxs)(`div`,{...G(`gallery`),style:{display:`flex`,flexDirection:`column`,gap:`10px`},children:[(0,W.jsx)(`div`,{...G(`media`),style:{aspectRatio:`1 / 1`,borderRadius:`12px`,overflow:`hidden`,background:qs},children:g.images?.[b]&&(0,W.jsx)(`img`,{src:g.images[b],alt:g.name,...G(`image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),g.images?.length>1&&(0,W.jsx)(`div`,{...G(`thumbnails`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:g.images.map((e,t)=>(0,W.jsx)(`button`,{type:`button`,onClick:()=>x(t),...G(`thumbnail`,t===b&&`thumbnail-selected`),style:{width:`64px`,height:`64px`,padding:0,borderRadius:`8px`,overflow:`hidden`,cursor:`pointer`,border:t===b?`2px solid var(--page-accent, #111827)`:Ks,background:qs},children:(0,W.jsx)(`img`,{src:e,alt:``,...G(`thumbnail-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})},e))})]}),(0,W.jsxs)(`div`,{...G(`info`),style:{display:`flex`,flexDirection:`column`,gap:`16px`},children:[(0,W.jsx)(`h1`,{...G(`title`),style:{margin:0,fontSize:`var(--page-h2, 32px)`},children:g.name}),(0,W.jsx)(Is,{product:g,inert:s,sample:c&&!!g.sample}),(0,W.jsx)(ic,{product:g,variant:P,locale:p,size:22}),g.variants?.length>0&&(0,W.jsx)(`div`,{...G(`variants`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:g.variants.map(e=>{let t=e.stock===0;return(0,W.jsx)(`button`,{type:`button`,disabled:t,onClick:()=>C(e.id),...G(`variant`,e.id===S&&`variant-selected`,t&&`variant-sold-out`),style:{...Ys,padding:`8px 14px`,opacity:t?.45:1,textDecoration:t?`line-through`:`none`,borderColor:e.id===S?`var(--page-accent, #111827)`:void 0,boxShadow:e.id===S?`inset 0 0 0 1px var(--page-accent, #111827)`:`none`},children:e.title},e.id)})}),(0,W.jsxs)(`div`,{...G(`buy-row`),style:{display:`flex`,gap:`10px`,alignItems:`center`},children:[(0,W.jsx)(`input`,{type:`number`,...G(`quantity-input`),min:1,"aria-label":h(`quantity`),value:w,onChange:e=>T(e.target.value),style:{...q,width:`80px`}}),(0,W.jsx)(`button`,{type:`button`,disabled:I||E,onClick:L,...G(`add-button`,I&&`add-button-sold-out`),style:{...Js,flex:1,opacity:I?.5:1},children:I?h(`soldOut`):E?h(`adding`):t||h(`add`)})]}),F!==null&&F>0&&F<=5&&(0,W.jsx)(`span`,{...G(`stock-note`),style:{fontSize:`13px`,color:`var(--page-accent, #b45309)`},children:h(`onlyLeft`,{n:F})}),O&&(0,W.jsx)(`span`,{...G(`note`),style:{fontSize:`13px`,color:Y},children:O}),Array.isArray(g.description)&&g.description.length>0&&(0,W.jsx)(`div`,{...G(`description`),style:{lineHeight:1.6},children:jr(g.description)})]})]}),i&&(0,W.jsx)(Gs,{specs:g.specs,locale:p,words:h}),n&&(0,W.jsx)(Rs,{product:g,inert:s,sample:c&&!!g.sample}),r&&(0,W.jsx)(Bs,{product:g,inert:s,sample:c&&!!g.sample})]})}function cc(e){return(0,W.jsx)(oc,{...e,source:`favorites`})}var lc=(0,W.jsxs)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,...G(`icon`),children:[(0,W.jsx)(`path`,{d:`M6 7h12l-1 13H7L6 7Z`}),(0,W.jsx)(`path`,{d:`M9 7a3 3 0 0 1 6 0`})]});function uc({href:e=`/cart`,label:t=``,showLabel:n=!1,style:r,nodeRef:i,inert:a=!1,sample:o=!1,noNavigate:s=!1}){let{tenant:c,apiUrl:l,words:u}=Xs(),{cart:d}=Zs(l,c,!a),f=o&&!d.count?2:d.count;return(0,W.jsxs)(`a`,{ref:i,href:e,onClick:s?e=>e.preventDefault():void 0,"aria-label":t||u(`cart`),style:{position:`relative`,display:`inline-flex`,alignItems:`center`,gap:`8px`,color:`inherit`,textDecoration:`none`,padding:`6px`,...z(r)},children:[lc,n&&(0,W.jsx)(`span`,{...G(`label`),children:t||u(`cart`)}),f>0&&(0,W.jsx)(`span`,{...G(`badge`),style:{position:`absolute`,top:`-4px`,left:`18px`,minWidth:`18px`,height:`18px`,padding:`0 5px`,borderRadius:`9px`,fontSize:`11px`,fontWeight:700,lineHeight:`18px`,textAlign:`center`,boxSizing:`border-box`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},children:f>99?`99+`:f})]})}function dc(e,t,n){if(t===`code`)return e;try{if(t===`name`)return`${new Intl.DisplayNames([n||`en`],{type:`currency`}).of(e)??e} (${e})`;let r=new Intl.NumberFormat(n||void 0,{style:`currency`,currency:e}).formatToParts(0).find(e=>e.type===`currency`)?.value;return r&&r!==e?`${r} ${e}`:e}catch{return e}}function fc({display:e=`symbol`,label:t=``,style:n,nodeRef:r,inert:i=!1}){let{tenant:a,apiUrl:o,locale:s}=Xs(),{store:c,currency:u}=Zs(o,a,!i),[d,f]=(0,l.useState)(null),p={display:`inline-flex`,alignItems:`center`,gap:8,...z(n)};(0,l.useEffect)(()=>{let e=!0;return os(o,a,`/store/config`).then(t=>e&&f(t)).catch(()=>e&&f({currencies:[]})),()=>{e=!1}},[o,a]);let m=Array.isArray(d?.currencies)?d.currencies:[];return m.length<2?i?(0,W.jsx)(`div`,{ref:r,style:{...p,padding:`8px 12px`,border:`1px dashed rgba(100, 116, 139, 0.45)`,borderRadius:6,color:`rgba(100, 116, 139, 0.8)`,fontSize:12},children:`Add currencies in Settings → Shop`}):null:(0,W.jsxs)(`div`,{ref:r,style:p,children:[t?(0,W.jsx)(`span`,{...G(`label`),style:{opacity:.7},children:t}):null,(0,W.jsx)(`select`,{"aria-label":t||`Currency`,...G(`select`),value:us(d,u),onChange:i?void 0:e=>c.setCurrency(e.target.value===d.currency?``:e.target.value),onKeyDown:i?e=>e.preventDefault():void 0,style:{font:`inherit`,color:`inherit`,background:`var(--page-surface, transparent)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:6,padding:`4px 8px`,cursor:i?`default`:`pointer`},children:m.map(t=>(0,W.jsx)(`option`,{value:t,children:dc(t,e,s)},t))})]})}var pc={display:`flex`,flexDirection:`column`,gap:`6px`,fontSize:`13px`},mc={margin:`0 0 12px`,fontSize:`18px`};function hc({label:e,required:t,children:n}){return(0,W.jsxs)(`label`,{...G(`field`),style:pc,children:[(0,W.jsxs)(`span`,{...G(`field-label`),style:{fontWeight:500},children:[e,t&&(0,W.jsx)(`span`,{...G(`required`),style:{color:`var(--page-accent, #dc2626)`},children:` *`})]}),n]})}var gc=[{id:`ship:standard`,type:`shipping`,name:`Standard`,amount:2990,min_days:2,max_days:4,detail:``},{id:`pickup:sample`,type:`pickup`,name:`Store pickup`,amount:0,min_days:null,max_days:null,detail:`Main Street 1`}],_c={name:``,email:``,phone:``,line1:``,line2:``,city:``,region:``,postal_code:``,country:``,note:``,gift:!1,recipient:``,gift_message:``};function vc({continueHref:e=`/`,style:t,nodeRef:n,inert:r=!1,sample:i=!1,noNavigate:a=!1}){let{tenant:o,apiUrl:s,locale:c,words:u,orderId:d}=Xs(),{store:f,cart:p,loaded:m}=Zs(s,o,!r),[h,g]=(0,l.useState)(null),[_,v]=(0,l.useState)(_c),[y,b]=(0,l.useState)(``),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(``),[T,E]=(0,l.useState)(null),[D,O]=(0,l.useState)(``),[k,A]=(0,l.useState)(!1),j=!r&&Qs(`cancelled`)===`1`,M=e=>ps(e,p.currency||h?.currency,c);(0,l.useEffect)(()=>{os(s,o,`/store/config`).then(e=>{g(e),b(t=>t||e?.methods?.[0]||``)}).catch(()=>g({enabled:!1,methods:[]}))},[s,o]),(0,l.useEffect)(()=>{let e=Qs(`order`);r||!e||j||os(s,o,`/store/orders/${encodeURIComponent(e)}`).then(e=>{E(e),e?.payment_status===`paid`&&f.reset()}).catch(e=>w(gs(u,e)))},[s,o]);let N=e=>t=>v(n=>({...n,[e]:t.target.value})),P=(0,l.useMemo)(()=>fs(c,h?.zone_countries??[],h&&!h.ships_elsewhere&&h.zone_countries?.length?h.zone_countries:null),[c,h]);(0,l.useEffect)(()=>{p.country&&!_.country&&v(e=>({...e,country:p.country}))},[p.country]);let F=async e=>{if(!r){A(!0),w(``);try{await f.setCoupon(e),O(``)}catch(e){w(gs(u,e))}finally{A(!1)}}},I=async e=>{if(e.preventDefault(),!r){if((R&&!ne?[`name`,`email`,`line1`,`city`,`country`]:[`name`,`email`]).some(e=>!_[e].trim())){w(u(`required`));return}S(!0),w(``);try{let e=new URL(window.location.href);[`order`,`paid`,`cancelled`].forEach(t=>e.searchParams.delete(t));let t=await os(s,o,`/store/checkout`,{method:`POST`,body:{cart_id:f.cartId(),method:y,customer:{name:_.name,email:_.email,phone:_.phone},address:{name:_.gift?_.recipient.trim():``,line1:_.line1,line2:_.line2,city:_.city,region:_.region,postal_code:_.postal_code,country:_.country},note:_.note,gift:_.gift,gift_message:_.gift?_.gift_message:``,delivery:p.delivery||``,return_url:e.toString()}});if(t?.redirect_url){window.location.assign(t.redirect_url);return}E(t?.order??null),f.reset()}catch(e){w(gs(u,e))}finally{S(!1)}}},L={...z(t)},R=r&&i&&!p.lines.length?!0:p.requires_shipping!==!1,ee=Array.isArray(p.discounts)?p.discounts:[],te=ee.filter(e=>e.type!==`shipping`),B=ee.find(e=>e.type===`shipping`)??null,V=r&&i&&!p.lines.length?gc:Array.isArray(p.delivery_options)?p.delivery_options:[],H=V.find(e=>e.id===p.delivery)??(r&&i?V[0]:null),ne=H?.type===`pickup`,re=e=>{r||e===p.delivery||(w(``),f.setDelivery(e).catch(e=>w(gs(u,e))))};if(T){let t=T.payment_status===`paid`;return(0,W.jsxs)(`div`,{ref:n,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...L},children:[(0,W.jsx)(`h2`,{...G(`thanks-title`),style:{margin:0},children:u(`thanks`,{number:d(T.number)})}),(0,W.jsx)(`p`,{...G(`thanks-message`),style:{margin:0},children:T.payment_method===`bank_transfer`?u(`transfer`):T.payment_method===`cash_on_delivery`?u(`cod`):u(t?`paid`:`awaiting`)}),Array.isArray(T.instructions_content)&&T.instructions_content.length>0?(0,W.jsx)(`div`,{...G(`instructions`),style:{padding:`12px`,borderRadius:`8px`,background:qs},children:jr(T.instructions_content)}):T.instructions?(0,W.jsx)(`pre`,{...G(`instructions`),style:{margin:0,padding:`12px`,borderRadius:`8px`,background:qs,whiteSpace:`pre-wrap`,fontFamily:`inherit`},children:T.instructions}):null,T.delivery&&(0,W.jsxs)(`div`,{...G(`delivery-info`),style:{padding:`12px`,borderRadius:`8px`,background:qs},children:[(0,W.jsx)(`div`,{...G(`delivery-name`),style:{fontWeight:600},children:T.delivery.type===`pickup`?u(`pickupAt`,{name:T.delivery.name}):u(`deliveredBy`,{name:T.delivery.name})}),T.delivery.location&&(0,W.jsxs)(`div`,{...G(`delivery-detail`),style:{fontSize:`14px`,color:Y},children:[[T.delivery.location.line1,T.delivery.location.line2,[T.delivery.location.postal_code,T.delivery.location.city].filter(Boolean).join(` `)].filter(Boolean).join(`, `),T.delivery.location.instructions&&(0,W.jsx)(`div`,{children:T.delivery.location.instructions}),(0,W.jsx)(`div`,{children:u(`pickupNote`)})]}),!T.delivery.location&&bs(u,c,T.delivery.min_days,T.delivery.max_days)&&(0,W.jsx)(`div`,{...G(`delivery-detail`),style:{fontSize:`14px`,color:Y},children:bs(u,c,T.delivery.min_days,T.delivery.max_days)})]}),(0,W.jsxs)(`p`,{...G(`total`),style:{margin:0,fontWeight:700},children:[u(`total`),`: `,ps(T.total,T.currency,c)]}),!t&&(0,W.jsx)(Cc,{reference:T.transfer_reference,words:u}),(0,W.jsx)(wc,{downloads:T.downloads,apiUrl:s,words:u,locale:c,noNavigate:a}),(0,W.jsx)(`a`,{href:e,onClick:a?e=>e.preventDefault():void 0,...G(`continue-button`),style:{...Ys,alignSelf:`flex-start`},children:u(`continue`)})]})}let ie=r&&i&&!p.lines.length?ac.slice(0,2).map(e=>({...e,product_id:e.id,variant_id:null,quantity:1,unit_price:e.price,total:e.price,image:``,variant_title:``})):p.lines,ae=r&&i&&!p.lines.length?ie.reduce((e,t)=>e+t.total,0):p.subtotal;if(h&&!h.enabled&&!r)return(0,W.jsx)(`div`,{ref:n,style:L,children:(0,W.jsx)(`p`,{...G(`empty`),style:{color:Y},children:u(`closed`)})});if(m&&!ie.length&&!r)return(0,W.jsxs)(`div`,{ref:n,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...L},children:[j&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:Y},children:u(`cancelled`)}),(0,W.jsx)(`p`,{...G(`empty`),style:{margin:0},children:u(`emptyCart`)}),(0,W.jsx)(`a`,{href:e,onClick:a?e=>e.preventDefault():void 0,...G(`continue-button`),style:{...Ys,alignSelf:`flex-start`},children:u(`continue`)})]});let oe=h?.methods??[];return(0,W.jsxs)(`form`,{ref:n,onSubmit:I,style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 340px), 1fr))`,gap:`32px`,alignItems:`start`,...L},children:[(0,W.jsxs)(`div`,{...G(`form-column`),style:{display:`flex`,flexDirection:`column`,gap:`20px`},children:[j&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:Y},children:u(`cancelled`)}),(0,W.jsxs)(`section`,{...G(`section`),children:[(0,W.jsx)(`h3`,{...G(`heading`),style:mc,children:u(`contact`)}),(0,W.jsxs)(`div`,{...G(`fields`),style:{display:`grid`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`name`),required:!0,children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.name,onChange:N(`name`),autoComplete:`name`})}),(0,W.jsxs)(`div`,{...G(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`email`),required:!0,children:(0,W.jsx)(`input`,{type:`email`,...G(`input`),style:q,value:_.email,onChange:N(`email`),autoComplete:`email`})}),(0,W.jsx)(hc,{label:u(`phone`),children:(0,W.jsx)(`input`,{type:`tel`,...G(`input`),style:q,value:_.phone,onChange:N(`phone`),autoComplete:`tel`})})]})]})]}),R&&(0,W.jsxs)(`section`,{...G(`section`),children:[(0,W.jsx)(`h3`,{...G(`heading`),style:mc,children:u(`delivery`)}),(0,W.jsx)(`div`,{style:{marginBottom:`12px`},children:(0,W.jsxs)(`div`,{...G(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`postal`),children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.postal_code,onChange:N(`postal_code`),onBlur:()=>!r&&_.country&&f.setCountry(_.country,_.postal_code).catch(e=>w(gs(u,e))),autoComplete:`postal-code`})}),(0,W.jsx)(hc,{label:u(`country`),required:!ne,children:(0,W.jsxs)(`select`,{...G(`select`),style:q,value:_.country,autoComplete:`country`,onChange:e=>{let t=e.target.value;v(e=>({...e,country:t})),r||f.setCountry(t,_.postal_code).catch(e=>w(gs(u,e)))},children:[(0,W.jsx)(`option`,{value:``,children:u(`chooseCountry`)}),P.map(e=>(0,W.jsx)(`option`,{value:e.code,children:e.name},e.code))]})})]})}),!V.length&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:Y,fontSize:`14px`},children:_.country?u(`noShipping`):u(`deliveryPick`)}),(0,W.jsx)(`div`,{...G(`delivery-options`),style:{display:`grid`,gap:`8px`},children:V.map(e=>{let t=bs(u,c,e.min_days,e.max_days);return(0,W.jsxs)(`label`,{...G(`delivery-option`,H?.id===e.id&&`delivery-option-selected`),style:{display:`flex`,alignItems:`flex-start`,gap:`10px`,padding:`12px`,borderRadius:`8px`,border:H?.id===e.id?`1px solid var(--page-accent, #4f46e5)`:Ks,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`radio`,...G(`radio`),name:`delivery`,value:e.id,checked:H?.id===e.id,onChange:()=>re(e.id),style:{marginTop:`3px`}}),(0,W.jsxs)(`span`,{...G(`option-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`span`,{...G(`option-name`),style:{display:`block`,fontWeight:600},children:e.name}),t&&(0,W.jsx)(`span`,{...G(`option-detail`),style:{display:`block`,fontSize:`13px`,color:Y},children:t}),e.detail&&(0,W.jsx)(`span`,{...G(`option-detail`),style:{display:`block`,fontSize:`13px`,color:Y},children:e.detail})]}),(0,W.jsx)(`span`,{...G(`option-price`),style:{fontWeight:600},children:e.amount?M(e.amount):u(`free`)})]},e.id)})})]}),R&&!ne&&(0,W.jsxs)(`section`,{...G(`section`),children:[(0,W.jsx)(`h3`,{...G(`heading`),style:mc,children:u(`address`)}),(0,W.jsxs)(`div`,{...G(`fields`),style:{display:`grid`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`line1`),required:!0,children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.line1,onChange:N(`line1`),autoComplete:`address-line1`})}),(0,W.jsx)(hc,{label:u(`line2`),children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.line2,onChange:N(`line2`),autoComplete:`address-line2`})}),(0,W.jsxs)(`div`,{...G(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`city`),required:!0,children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.city,onChange:N(`city`),autoComplete:`address-level2`})}),(0,W.jsx)(hc,{label:u(`region`),children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.region,onChange:N(`region`),autoComplete:`address-level1`})})]}),(0,W.jsx)(hc,{label:u(`note`),children:(0,W.jsx)(`textarea`,{rows:2,...G(`textarea`),style:{...q,resize:`vertical`},value:_.note,onChange:N(`note`)})})]})]}),(0,W.jsxs)(`section`,{...G(`section`),children:[(0,W.jsxs)(`label`,{...G(`checkbox-row`),style:{display:`flex`,alignItems:`flex-start`,gap:`10px`,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`checkbox`,...G(`checkbox`),checked:_.gift,onChange:e=>v(t=>({...t,gift:e.target.checked})),style:{marginTop:`3px`}}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`span`,{...G(`checkbox-label`),style:{fontWeight:600},children:u(`gift`)}),(0,W.jsx)(`span`,{...G(`checkbox-hint`),style:{display:`block`,fontSize:`13px`,color:Y},children:u(`giftHint`)})]})]}),_.gift&&(0,W.jsxs)(`div`,{...G(`fields`),style:{marginTop:`12px`,display:`grid`,gap:`12px`},children:[R&&!ne&&(0,W.jsx)(hc,{label:u(`giftRecipient`),children:(0,W.jsx)(`input`,{...G(`input`),style:q,value:_.recipient,onChange:N(`recipient`),maxLength:200,autoComplete:`off`})}),(0,W.jsx)(hc,{label:u(`giftMessage`),children:(0,W.jsx)(`textarea`,{rows:3,maxLength:500,...G(`textarea`),style:{...q,resize:`vertical`},value:_.gift_message,onChange:N(`gift_message`)})})]})]}),(0,W.jsxs)(`section`,{...G(`section`),children:[(0,W.jsx)(`h3`,{...G(`heading`),style:mc,children:u(`payment`)}),!oe.length&&!r&&(0,W.jsx)(`p`,{...G(`note`),style:{margin:0,color:Y},children:u(`noMethods`)}),(0,W.jsx)(`div`,{...G(`payment-options`),style:{display:`grid`,gap:`8px`},children:(r&&!oe.length?[`stripe`,`bank_transfer`]:oe).map(e=>(0,W.jsxs)(`label`,{...G(`payment-option`,y===e&&`payment-option-selected`),style:{display:`flex`,alignItems:`center`,gap:`10px`,padding:`12px`,borderRadius:`8px`,border:Ks,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`radio`,...G(`radio`),name:`method`,value:e,checked:y===e,onChange:()=>b(e)}),(0,W.jsx)(`span`,{...G(`payment-name`),children:h?.method_names?.[e]??u(e)})]},e))})]})]}),(0,W.jsxs)(`aside`,{...G(`summary`),style:{display:`flex`,flexDirection:`column`,gap:`14px`,padding:`20px`,borderRadius:`12px`,background:qs},children:[(0,W.jsx)(`h3`,{...G(`summary-title`),style:{...mc,margin:0},children:u(`cart`)}),ie.map(e=>(0,W.jsxs)(`div`,{...G(`line`),style:{display:`flex`,gap:`12px`,alignItems:`center`},children:[(0,W.jsx)(`div`,{...G(`line-media`),style:{width:`52px`,height:`52px`,borderRadius:`8px`,overflow:`hidden`,background:`var(--page-bg, #fff)`,flexShrink:0},children:e.image&&(0,W.jsx)(`img`,{src:e.image,alt:``,...G(`line-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),(0,W.jsxs)(`div`,{...G(`line-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{...G(`line-name`),style:{fontWeight:600},children:e.name}),e.variant_title&&(0,W.jsx)(`div`,{...G(`line-variant`),style:{fontSize:`13px`,color:Y},children:e.variant_title}),(0,W.jsxs)(`div`,{...G(`line-controls`),style:{display:`flex`,alignItems:`center`,gap:`8px`,marginTop:`4px`},children:[(0,W.jsx)($s,{value:e.quantity,label:u(`quantity`),onCommit:t=>!r&&f.setLine(e.product_id,e.variant_id,t).catch(e=>w(gs(u,e)))}),(0,W.jsx)(`button`,{type:`button`,onClick:()=>!r&&f.setLine(e.product_id,e.variant_id,0).catch(e=>w(gs(u,e))),...G(`remove-button`),style:{background:`none`,border:0,padding:0,color:Y,cursor:`pointer`,fontSize:`13px`,textDecoration:`underline`,fontFamily:`inherit`},children:u(`remove`)})]})]}),(0,W.jsxs)(`div`,{...G(`line-price`),style:{textAlign:`right`},children:[e.discount>0&&(0,W.jsx)(`div`,{...G(`line-price-old`),style:{fontSize:`12px`,color:Y,textDecoration:`line-through`},children:M(e.total)}),(0,W.jsx)(`div`,{...G(`line-total`),style:{fontWeight:600},children:M(e.total-(e.discount||0))})]})]},`${e.product_id}:${e.variant_id??``}`)),p.coupon?(0,W.jsxs)(`div`,{...G(`coupon`),style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:`8px`,fontSize:`14px`},children:[(0,W.jsx)(`span`,{...G(`coupon-code`),style:{padding:`4px 10px`,borderRadius:`999px`,border:Ks,fontWeight:600,letterSpacing:`0.04em`},children:p.coupon.code}),(0,W.jsx)(`button`,{type:`button`,disabled:k,onClick:()=>F(``),...G(`coupon-remove`),style:{background:`none`,border:0,padding:0,color:Y,cursor:`pointer`,fontSize:`13px`,textDecoration:`underline`,fontFamily:`inherit`},children:u(`removeCoupon`)})]}):(0,W.jsxs)(`div`,{...G(`coupon-form`),style:{display:`flex`,gap:`8px`},children:[(0,W.jsx)(`input`,{"aria-label":u(`coupon`),...G(`coupon-input`),placeholder:u(`coupon`),value:D,onChange:e=>O(e.target.value.toUpperCase()),onKeyDown:e=>{e.key===`Enter`&&(e.preventDefault(),D.trim()&&F(D.trim()))},style:{...q,flex:1,letterSpacing:`0.04em`}}),(0,W.jsx)(`button`,{type:`button`,disabled:k||!D.trim(),onClick:()=>F(D.trim()),...G(`coupon-button`),style:{...Ys,padding:`8px 14px`},children:u(`apply`)})]}),p.coupon_error&&(0,W.jsx)(`span`,{...G(`coupon-error`),style:{fontSize:`13px`,color:Y},children:p.coupon_error_code&&u.has(p.coupon_error_code)?u(p.coupon_error_code):p.coupon_error}),(0,W.jsxs)(`div`,{...G(`totals`),style:{borderTop:Ks,paddingTop:`12px`,display:`grid`,gap:`6px`,fontSize:`14px`},children:[(0,W.jsxs)(`div`,{...G(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsx)(`span`,{children:u(`subtotal`)}),(0,W.jsx)(`span`,{children:M(ae)})]}),te.length?te.map(e=>(0,W.jsxs)(`div`,{...G(`summary-row`),style:{display:`flex`,justifyContent:`space-between`,gap:`8px`},children:[(0,W.jsxs)(`span`,{children:[u(`discount`),` · `,e.title]}),(0,W.jsxs)(`span`,{children:[`−`,M(e.amount)]})]},e.id)):p.discount_total>0&&(0,W.jsxs)(`div`,{...G(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsx)(`span`,{children:u(`discount`)}),(0,W.jsxs)(`span`,{children:[`−`,M(p.discount_total)]})]}),R&&(0,W.jsxs)(`div`,{...G(`summary-row`),style:{display:`flex`,justifyContent:`space-between`,gap:`8px`},children:[(0,W.jsxs)(`span`,{children:[H?.name??u(`shipping`),B?` · ${B.title}`:``]}),(0,W.jsxs)(`span`,{children:[B&&(0,W.jsx)(`span`,{...G(`shipping-old`),style:{color:Y,textDecoration:`line-through`,marginRight:`6px`},children:M(p.shipping_before)}),(B?p.shipping_total:H?.amount??p.shipping_total)?M(B?p.shipping_total:H?.amount??p.shipping_total):u(`free`)]})]}),!p.tax_included&&p.tax_total>0&&(0,W.jsxs)(`div`,{...G(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsxs)(`span`,{children:[u(`tax`),` (`,p.tax_rate,`%)`]}),(0,W.jsx)(`span`,{children:M(p.tax_total)})]}),(0,W.jsxs)(`div`,{...G(`summary-row`,`summary-row-total`),style:{display:`flex`,justifyContent:`space-between`,fontWeight:700,fontSize:`16px`},children:[(0,W.jsx)(`span`,{children:u(`total`)}),(0,W.jsx)(`span`,{children:M(r&&i&&!p.lines.length?ae:p.total)})]}),p.tax_included&&p.tax_total>0&&(0,W.jsxs)(`div`,{...G(`summary-row`,`summary-row-muted`),style:{display:`flex`,justifyContent:`space-between`,fontSize:`12px`,color:Y},children:[(0,W.jsxs)(`span`,{children:[u(`taxIncluded`),` (`,p.tax_rate,`%)`]}),(0,W.jsx)(`span`,{children:M(p.tax_total)})]})]}),p.shipping_available===!1&&(0,W.jsx)(`p`,{...G(`error`),style:{margin:0,color:`#dc2626`,fontSize:`13px`},children:u(`noShipping`)}),C&&(0,W.jsx)(`p`,{...G(`error`),style:{margin:0,color:`#dc2626`,fontSize:`13px`},children:C}),(0,W.jsx)(`button`,{type:`submit`,...G(`submit-button`),disabled:x||!y||p.shipping_available===!1,style:{...Js,width:`100%`,padding:`12px`},children:u(x?`placing`:`placeOrder`)}),(0,W.jsx)(bc,{apiUrl:s,tenant:o,words:u,locale:c,sample:i,inert:r})]})]})}var yc=[`refund`,`privacy`,`terms`,`shipping`].map(e=>({kind:e,content:[],fields:{},updated_at:null}));function bc({apiUrl:e,tenant:t,words:n,locale:r,sample:i,inert:a}){let[o,s]=(0,l.useState)(i?yc:[]),[c,u]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(i)return;let n=!0;return vs(e,t).then(e=>n&&s(e)),()=>{n=!1}},[e,t,i]),!o.length)return null;let d=o.find(e=>e.kind===`terms`),f=e=>t=>{t.preventDefault(),a||u(e)},p=e=>(0,W.jsx)(`a`,{href:`#policy-${e.kind}`,onClick:f(e),...G(`policy-link`),style:{color:Y,textDecoration:`underline`},children:n(`policy_${e.kind}`)},e.kind);return(0,W.jsxs)(`div`,{...G(`policies`),style:{display:`grid`,gap:`8px`,fontSize:`12px`,color:Y},children:[d&&(0,W.jsxs)(`span`,{...G(`policy-agree`),children:[n(`policy_agree`).split(`{terms}`)[0],p(d),n(`policy_agree`).split(`{terms}`)[1]]}),(0,W.jsx)(`div`,{...G(`policy-links`),style:{display:`flex`,flexWrap:`wrap`,gap:`6px 14px`,borderTop:Ks,paddingTop:`10px`},children:o.map(p)}),c&&(0,W.jsx)(xc,{policy:c,words:n,locale:r,onClose:()=>u(null)})]})}function xc({policy:e,words:t,locale:n,onClose:r}){(0,l.useEffect)(()=>{let e=e=>{e.key===`Escape`&&r()};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[r]);let i=e.fields??{},a=[i.line1,i.line2,[i.postal_code,i.city].filter(Boolean).join(` `),[i.region,i.country].filter(Boolean).join(`, `)].filter(Boolean),o=``;try{o=e.updated_at?new Date(e.updated_at).toLocaleDateString(n||void 0,{dateStyle:`long`}):``}catch{o=``}return(0,W.jsx)(`div`,{role:`dialog`,"aria-modal":`true`,"aria-label":t(`policy_${e.kind}`),onMouseDown:e=>e.target===e.currentTarget&&r(),...G(`modal`),style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(15, 23, 42, .55)`,display:`grid`,placeItems:`center`,padding:`16px`},children:(0,W.jsxs)(`div`,{...G(`modal-panel`),style:{background:`var(--page-bg, #fff)`,color:`var(--page-text, #111827)`,border:Ks,borderRadius:`12px`,width:`min(720px, 100%)`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,textAlign:`left`},children:[(0,W.jsxs)(`div`,{...G(`modal-header`),style:{display:`flex`,alignItems:`center`,gap:`12px`,padding:`16px 20px`,borderBottom:Ks},children:[(0,W.jsx)(`strong`,{...G(`modal-title`),style:{flex:1,fontSize:`17px`},children:t(`policy_${e.kind}`)}),(0,W.jsx)(`button`,{type:`button`,onClick:r,"aria-label":t(`close`),...G(`modal-close`),style:{...Ys,padding:`4px 10px`},children:`×`})]}),(0,W.jsxs)(`div`,{...G(`modal-body`),style:{padding:`8px 20px 20px`,overflowY:`auto`,fontSize:`14px`,lineHeight:1.6},children:[e.kind===`contact`?(0,W.jsxs)(`div`,{style:{display:`grid`,gap:`10px`,paddingTop:`10px`},children:[i.business_name&&(0,W.jsx)(`strong`,{children:i.business_name}),a.length>0&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_address`),`: `]}),a.join(`, `)]}),i.email&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_email`),`: `]}),(0,W.jsx)(`a`,{href:`mailto:${i.email}`,children:i.email})]}),i.phone&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_phone`),`: `]}),i.phone]}),i.trade_number&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_trade`),`: `]}),i.trade_number]})]}):jr(e.content),o&&(0,W.jsx)(`p`,{...G(`modal-updated`),style:{color:Y,fontSize:`12px`,marginTop:`16px`},children:t(`policy_updated`,{date:o})})]})]})})}var Sc={year:`numeric`,month:`short`,day:`numeric`};function Cc({reference:e,words:t}){let[n,r]=(0,l.useState)(!1);if(!e)return null;let i=()=>{try{navigator.clipboard?.writeText(e).then(()=>{r(!0),setTimeout(()=>r(!1),1500)},()=>{})}catch{}};return(0,W.jsxs)(`div`,{...G(`reference`),style:{display:`grid`,gap:`4px`},children:[(0,W.jsx)(`span`,{...G(`reference-label`),style:{fontSize:`13px`,color:Y},children:t(`reference`)}),(0,W.jsxs)(`div`,{...G(`reference-row`),style:{display:`flex`,alignItems:`center`,gap:`8px`,flexWrap:`wrap`},children:[(0,W.jsx)(`code`,{...G(`reference-code`),style:{padding:`8px 12px`,border:`2px dashed var(--page-border, #d1d5db)`,borderRadius:`8px`,font:`700 20px/1.2 ui-monospace, Menlo, Consolas, monospace`,letterSpacing:`2px`},children:e}),(0,W.jsx)(`button`,{type:`button`,onClick:i,...G(`copy-button`),style:{...Ys,padding:`6px 12px`},children:t(n?`copied`:`copy`)})]}),(0,W.jsx)(`span`,{...G(`reference-note`),style:{fontSize:`13px`,color:Y},children:t(`referenceNote`)})]})}function wc({downloads:e,apiUrl:t,words:n,locale:r,noNavigate:i}){let a=Array.isArray(e)?e.filter(e=>e&&e.token&&!e.revoked_at):[];if(!a.length)return null;let o=e=>{try{return new Date(e).toLocaleDateString(r||void 0,{dateStyle:`medium`})}catch{return``}};return(0,W.jsxs)(`div`,{...G(`downloads`),style:{display:`grid`,gap:`8px`,paddingTop:`8px`},children:[(0,W.jsx)(`strong`,{...G(`downloads-title`),style:{fontSize:`14px`},children:n(`downloads_title`)}),a.map(e=>{let r=typeof e.download_limit==`number`?Math.max(0,e.download_limit-(e.downloads??0)):null,a=e.expires_at&&new Date(e.expires_at).getTime()<=Date.now(),s=!a&&(r===null||r>0),c=[r!==null&&n(`download_left`,{count:r}),e.expires_at&&n(a?`download_expired`:`download_until`,{date:o(e.expires_at)})].filter(Boolean);return(0,W.jsxs)(`div`,{...G(`download`),style:{display:`flex`,alignItems:`center`,gap:`12px`,padding:`10px 12px`,border:Ks,borderRadius:`8px`},children:[(0,W.jsxs)(`div`,{...G(`download-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{...G(`download-name`),style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:e.filename}),c.length>0&&(0,W.jsx)(`div`,{...G(`download-note`),style:{fontSize:`12px`,color:Y},children:c.join(` · `)})]}),s?(0,W.jsx)(`a`,{href:`${t}/store/downloads/${encodeURIComponent(e.token)}`,onClick:i?e=>e.preventDefault():void 0,...G(`download-button`),style:{...Js,padding:`6px 14px`,textDecoration:`none`,fontSize:`14px`},children:n(`download`)}):(0,W.jsx)(`span`,{...G(`download-unavailable`),style:{fontSize:`13px`,color:Y},children:n(`download_unavailable`)})]},e.token)})]})}function Tc({tracking:e,words:t,noNavigate:n}){let r=typeof e?.carrier==`string`?e.carrier:``,i=typeof e?.number==`string`?e.number:``,a=typeof e?.url==`string`&&/^https?:\/\//i.test(e.url)?e.url:``;return!r&&!i&&!a?null:(0,W.jsxs)(`div`,{...G(`tracking`),style:{marginTop:`4px`,paddingTop:`8px`,borderTop:`1px solid var(--page-border, rgba(0,0,0,.1))`,display:`flex`,gap:`10px`,flexWrap:`wrap`,alignItems:`baseline`},children:[(0,W.jsx)(`span`,{...G(`tracking-label`),style:{color:Y},children:t(`tracking`)}),(0,W.jsx)(`span`,{...G(`tracking-number`),children:[r,i].filter(Boolean).join(` · `)}),a&&(0,W.jsx)(`a`,{href:a,target:`_blank`,rel:`noopener noreferrer`,onClick:n?e=>e.preventDefault():void 0,...G(`tracking-link`),style:{color:`var(--page-accent, #4f46e5)`},children:t(`track_parcel`)})]})}function Ec({loginHref:e=`/login`,limit:t=20,style:n,nodeRef:r,inert:i=!1,sample:a=!1,noNavigate:o=!1}){let{tenant:s,apiUrl:c,locale:u,words:d,orderId:f}=Xs(),[p,m]=(0,l.useState)(null),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(``);(0,l.useEffect)(()=>{if(i)return;let e=!0;return os(c,s,`/store/my/orders?limit=${Math.max(1,Math.min(100,Number(t)||20))}`).then(t=>e&&m(Array.isArray(t?.data)?t.data:[])).catch(t=>{e&&(g(t?.code===`LOGIN_REQUIRED`),m([]))}),()=>{e=!1}},[c,s,t,i]);let y=i&&a?[{id:`s1`,number:1042,status:`shipped`,payment_status:`paid`,currency:`USD`,total:8490,created_at:new Date().toISOString(),items:[]},{id:`s2`,number:1041,status:`delivered`,payment_status:`paid`,currency:`USD`,total:2990,created_at:new Date(Date.now()-864e6).toISOString(),items:[]}]:p??[],b=e=>{try{return new Intl.DateTimeFormat(u||void 0,Sc).format(new Date(e))}catch{return String(e).slice(0,10)}};return(0,W.jsxs)(`div`,{ref:r,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...z(n)},children:[(0,W.jsx)(`h2`,{...G(`title`),style:{margin:0,fontSize:`22px`},children:d(`myOrders`)}),h&&(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:e,onClick:o?e=>e.preventDefault():void 0,...G(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:d(`signInForOrders`)})}),!h&&(p!==null||i)&&!y.length&&(0,W.jsx)(`p`,{...G(`empty`),style:{margin:0,color:Y},children:d(`noOrders`)}),y.map(e=>(0,W.jsxs)(`div`,{...G(`order`,_===e.id&&`order-open`),style:{border:Ks,borderRadius:`10px`,overflow:`hidden`},children:[(0,W.jsxs)(`button`,{type:`button`,onClick:()=>v(t=>t===e.id?``:e.id),...G(`order-header`),style:{width:`100%`,display:`grid`,gridTemplateColumns:`1fr auto auto`,gap:`12px`,alignItems:`center`,padding:`12px 14px`,background:`transparent`,border:0,color:`inherit`,font:`inherit`,textAlign:`left`,cursor:`pointer`},children:[(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`strong`,{...G(`order-number`),children:f(e.number)}),(0,W.jsx)(`span`,{...G(`order-date`),style:{color:Y,marginLeft:`8px`,fontSize:`13px`},children:b(e.created_at)})]}),(0,W.jsxs)(`span`,{...G(`status`),style:{fontSize:`13px`,padding:`2px 10px`,borderRadius:`999px`,background:qs},children:[d(`st_${e.status}`),e.payment_status===`paid`?``:` · ${d(`pay_${e.payment_status}`)}`]}),(0,W.jsx)(`strong`,{...G(`order-total`),children:ps(e.total,e.currency,u)})]}),_===e.id&&e.items?.length>0&&(0,W.jsxs)(`div`,{...G(`order-items`),style:{padding:`0 14px 12px`,display:`grid`,gap:`6px`,fontSize:`14px`},children:[e.items.map(t=>(0,W.jsxs)(`div`,{...G(`order-item`),style:{display:`flex`,justifyContent:`space-between`,gap:`12px`},children:[(0,W.jsxs)(`span`,{children:[t.quantity,` × `,t.name,t.variant_title&&(0,W.jsxs)(`span`,{...G(`order-item-variant`),style:{color:Y},children:[` — `,t.variant_title]})]}),(0,W.jsx)(`span`,{...G(`order-item-price`),children:ps(t.total,e.currency,u)})]},t.id)),e.payment_status===`unpaid`&&e.status!==`cancelled`&&(0,W.jsx)(Cc,{reference:e.transfer_reference,words:d}),(0,W.jsx)(Tc,{tracking:e.tracking,words:d,noNavigate:o}),(0,W.jsx)(wc,{downloads:e.downloads,apiUrl:c,words:d,locale:u,noNavigate:o})]})]},e.id))]})}function Dc(e){let t=e?.locales,n=[typeof t?.default==`string`&&t.default.trim()?t.default.trim():``,...Array.isArray(t?.enabled)?t.enabled:[]].filter(e=>typeof e==`string`&&e.trim());return[...new Set(n.map(e=>e.trim()))]}var Oc=e=>e&&e.charAt(0).toUpperCase()+e.slice(1);function kc(e,t){let n=String(e??``).toUpperCase();if(t===`code`)return n;let r=``;try{r=Oc(new Intl.DisplayNames([e],{type:`language`}).of(e)??``)}catch{}return!r||r.toUpperCase()===n?n:t===`both`?`${n} — ${r}`:r}function Ac(e,t){let n=t?``:`?locale=${encodeURIComponent(e)}`;if(typeof window>`u`)return n||`?`;try{let n=new URL(window.location.href);return t?n.searchParams.delete(`locale`):n.searchParams.set(`locale`,e),n.searchParams.delete(`page`),`${n.pathname}${n.search}${n.hash}`}catch{return n||`/`}}function jc({variant:e,display:t,separator:n,label:r,style:i,nodeRef:a,inert:o}){let s=(0,l.useContext)(Nn),c=Dc(s?.settings),u=c[0]??``,d=c.includes(s?.locale)?s.locale:u,f={display:`inline-flex`,alignItems:`center`,gap:8,...z(i)};if(c.length<2)return o?(0,W.jsx)(`div`,{ref:a,style:{...f,padding:`8px 12px`,border:`1px dashed rgba(100, 116, 139, 0.45)`,borderRadius:6,color:`rgba(100, 116, 139, 0.8)`,fontSize:12},children:`Add site languages in Settings → Languages`}):null;let p=r?(0,W.jsx)(`span`,{...G(`label`),style:{opacity:.7},children:r}):null;return e===`inline`?(0,W.jsxs)(`div`,{ref:a,style:f,children:[p,c.map((e,r)=>(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:8},children:[r>0&&(0,W.jsx)(`span`,{...G(`separator`),style:{opacity:.4},children:n??`·`}),(0,W.jsx)(`a`,{...G(`link`,e===d&&`link-current`),href:Ac(e,e===u),hrefLang:e,"aria-current":e===d?`true`:void 0,onClick:o?e=>e.preventDefault():void 0,style:{color:e===d?`var(--page-accent, inherit)`:`inherit`,fontWeight:e===d?600:400,textDecoration:`none`,cursor:o?`default`:`pointer`},children:kc(e,t)})]},e))]}):(0,W.jsxs)(`div`,{ref:a,style:f,children:[p,(0,W.jsx)(`select`,{...G(`select`),"aria-label":r||`Language`,value:d,onChange:o?void 0:e=>{let t=e.target.value;window.location.assign(Ac(t,t===u))},onKeyDown:o?e=>e.preventDefault():void 0,style:{font:`inherit`,color:`inherit`,background:`var(--page-surface, transparent)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:6,padding:`4px 8px`,cursor:o?`default`:`pointer`},children:c.map(e=>(0,l.createElement)(`option`,{...G(`option`,e===d&&`option-current`),key:e,value:e},kc(e,t)))})]})}var Mc=[Oo,qo,Bo,Jo,es],Nc={SiteLoginForm:Ro,SiteAccountMenu:zo,SiteLanguagePicker:jc,CookieConsent:Ko,SiteSearch:$o,ShopProductGrid:oc,ShopProduct:sc,ShopCartButton:uc,ShopCheckout:vc,ShopOrderHistory:Ec,ShopCurrencyPicker:fc,ShopFavorites:cc};new Set(Mc.filter(e=>e.ssr===`shell`).flatMap(e=>e.keys));var Pc=`0.185.1`,Fc=`4.2.0`,Ic=`https://cdn.jsdelivr.net/npm`,Lc=`${Ic}/three@${Pc}/+esm`,Rc=`${Ic}/@google/model-viewer@${Fc}/dist/model-viewer.min.js`,zc=e=>import(e),Bc=new Map;function Vc(e){if(Bc.has(e))return Bc.get(e);if(typeof window>`u`)return new Promise(()=>{});let t=zc(e).catch(t=>{throw Bc.delete(e),t});return Bc.set(e,t),t}var Hc=()=>Vc(Lc),Uc=e=>Vc(`${Ic}/three@${Pc}/examples/jsm/${e}/+esm`);function Wc(){return typeof window<`u`&&window.customElements?.get(`model-viewer`)?Promise.resolve(null):Vc(Rc)}var Gc=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,Kc=(e=2)=>Math.min(typeof window>`u`?1:window.devicePixelRatio||1,e);function qc(e,t){let n=0,r=0,i=0,a=!0,o=e=>{n=requestAnimationFrame(o),i||=e;let a=r?(e-r)/1e3:0;r=e,t(a,(e-i)/1e3)},s=()=>{n&&cancelAnimationFrame(n),n=0,r=0},c=()=>{let e=a&&document.visibilityState!==`hidden`;e&&!n?n=requestAnimationFrame(o):!e&&n&&s()};t(0,0);let l=typeof IntersectionObserver>`u`?null:new IntersectionObserver(e=>{a=e.some(e=>e.isIntersecting),c()},{rootMargin:`120px`});return l&&e&&l.observe(e),document.addEventListener(`visibilitychange`,c),c(),()=>{s(),l?.disconnect(),document.removeEventListener(`visibilitychange`,c)}}function Jc(e,t,n={}){let r={radius:n.distance??4,polar:n.polar??Math.PI/2.4,azimuth:n.azimuth??.6,target:n.target??{x:0,y:0,z:0}},i={...r},a=n.minDistance??.4,o=n.maxDistance??200,s=n.damping??.12,c=.05,l=null,u=e=>{e.button!==void 0&&e.button!==0||(l={x:e.clientX,y:e.clientY,id:e.pointerId},t.setPointerCapture?.(e.pointerId))},d=e=>{if(!l||e.pointerId!==l.id)return;let t=e.clientX-l.x,n=e.clientY-l.y;l={...l,x:e.clientX,y:e.clientY},i.azimuth-=t*.006,i.polar=Math.max(c,Math.min(Math.PI-c,i.polar-n*.006)),e.preventDefault()},f=e=>{l&&e.pointerId===l.id&&t.releasePointerCapture?.(e.pointerId),l=null},p=e=>{n.enableZoom!==!1&&(e.preventDefault(),i.radius=Math.max(a,Math.min(o,i.radius*(1+Math.sign(e.deltaY)*.12))))};return t.addEventListener(`pointerdown`,u),t.addEventListener(`pointermove`,d),t.addEventListener(`pointerup`,f),t.addEventListener(`pointercancel`,f),t.addEventListener(`wheel`,p,{passive:!1}),{update:()=>{r.radius+=(i.radius-r.radius)*s,r.polar+=(i.polar-r.polar)*s,r.azimuth+=(i.azimuth-r.azimuth)*s;let t=Math.sin(r.polar);e.position.set(r.target.x+r.radius*t*Math.sin(r.azimuth),r.target.y+r.radius*Math.cos(r.polar),r.target.z+r.radius*t*Math.cos(r.azimuth)),e.lookAt(r.target.x,r.target.y,r.target.z)},dragging:()=>!!l,autoSpin:(e,t)=>{!l&&e&&(i.azimuth+=e*t)},frame:(e,t)=>{i.radius=Math.max(a,Math.min(o,e)),r.radius=i.radius,t&&(r.target={...t},i.target={...t})},dispose:()=>{t.removeEventListener(`pointerdown`,u),t.removeEventListener(`pointermove`,d),t.removeEventListener(`pointerup`,f),t.removeEventListener(`pointercancel`,f),t.removeEventListener(`wheel`,p)}}}var Yc=(e,t)=>Number.isFinite(Number(e))&&Number(e)>0?Number(e):t,Xc=(e,t)=>(Number.isFinite(Number(e))?Number(e):t)/100,Zc=e=>(Number.isFinite(Number(e))?Number(e):0)*Math.PI/180,Qc=e=>typeof e==`string`&&!!e.trim();function $c({label:e,note:t,height:n,nodeRef:r,style:i}){return(0,W.jsxs)(`div`,{ref:r,style:{...z(i),minHeight:Yc(n,320),display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,gap:6,border:`1px dashed rgba(148,163,184,.55)`,borderRadius:10,background:`rgba(148,163,184,.08)`,...U,color:`rgba(100,116,139,.95)`,fontSize:13,textAlign:`center`,padding:16},children:[(0,W.jsx)(`div`,{style:{fontWeight:600},children:e}),t?(0,W.jsx)(`div`,{style:{fontSize:11,opacity:.8,maxWidth:320},children:t}):null]})}function el({src:e,poster:t,alt:n,height:r,bg:i,autoRotate:a,rotateDelay:o,cameraControls:s,ar:c,exposure:u,shadow:d,fieldOfView:f,environment:p,style:m,nodeRef:h,inert:g}){let[_,v]=(0,l.useState)(typeof window<`u`&&!!window.customElements?.get(`model-viewer`)),[y,b]=(0,l.useState)(!1);(0,l.useEffect)(()=>{if(_||!e)return;let t=!0;return Wc().then(()=>t&&v(!0),()=>t&&b(!0)),()=>{t=!1}},[_,e]);let x={display:`block`,width:`100%`,minHeight:Yc(r,360),height:Yc(r,360),backgroundColor:i||`transparent`,...z(m)};if(!e)return g?(0,W.jsx)($c,{nodeRef:h,style:m,height:r,label:`3D Model`,note:`Pick a .glb or .gltf file in the Settings panel.`}):(0,W.jsx)(`div`,{ref:h,style:x});if(y)return(0,W.jsx)(`div`,{ref:h,style:{...x,display:`flex`,alignItems:`center`,justifyContent:`center`},children:t?(0,W.jsx)(`img`,{src:t,alt:n||``,style:{maxWidth:`100%`,maxHeight:`100%`}}):null});let S=e=>e?``:void 0,C=a!==!1;return(0,W.jsx)(`model-viewer`,{ref:h,src:e,alt:n||`A 3D model`,poster:t||void 0,style:x,"camera-controls":S(!g&&s!==!1),"auto-rotate":S(C&&!Gc()),"auto-rotate-delay":C?String(Yc(o,0)):void 0,"rotation-per-second":`18deg`,ar:S(!g&&c===!0),"ar-modes":`webxr scene-viewer quick-look`,"shadow-intensity":String(Xc(d,100)),exposure:String(Xc(u,100)),"field-of-view":f?`${Number(f)}deg`:void 0,"environment-image":p&&p!==`neutral`?p:`neutral`,"interaction-prompt":g?`none`:void 0,loading:`lazy`,"touch-action":`pan-y`,children:t?(0,W.jsx)(`img`,{slot:`poster`,src:t,alt:n||``,style:{width:`100%`,height:`100%`,objectFit:`contain`}}):null})}var tl=[`attribute vec2 p;`,`void main() { gl_Position = vec4(p, 0.0, 1.0); }`].join(`
104
+ `),I=y&&(f===`drawer`||!f&&!w),L=I&&m!==!1&&!(p&&Number.isFinite(p.top)),R=(()=>{if(!I)return null;if(m===!1)return{display:`none`};if(p&&Number.isFinite(p.top)){let e=Number.isFinite(p.boardLeft)?p.boardLeft:p.left,t=Number.isFinite(p.boardRight)?p.boardRight:p.innerRight,n=Number.isFinite(p.boardWidth)?p.boardWidth:p.innerWidth||800,r={position:`fixed`,zIndex:6,overflowY:`auto`,boxSizing:`border-box`,marginTop:0,marginRight:0,marginBottom:0,marginLeft:0,maxWidth:`none`,maxHeight:`none`,boxShadow:`0 0 40px rgba(15, 23, 42, .28)`},i=p.bottom;if(j){let n=Math.min(k,Math.round((p.innerHeight||600)*.86));return{...r,left:e,right:t,width:`auto`,height:n,...A===`top`?{top:p.top}:{bottom:i}}}let a=Math.min(k,Math.round(n*.86));return{...r,top:p.top,bottom:i,width:a,height:`auto`,...A===`right`?{right:t}:{left:e}}}return j?{width:`100%`,height:k,maxHeight:`none`,overflowY:`auto`,boxSizing:`border-box`}:{width:`min(${k}px, 100%)`,maxWidth:`none`,boxSizing:`border-box`,...A===`right`?{marginLeft:`auto`}:null}})(),ee=()=>!y&&x(!1),te=(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`div`,{...K(`backdrop`),className:`wb-drw-backdrop`,onClick:u===!1?void 0:ee,style:{position:`fixed`,inset:0,zIndex:2147483e3,background:`rgba(15, 23, 42, .5)`}}),(0,W.jsxs)(`div`,{ref:C,"data-wb-self":``,className:`wb-drw-panel`,role:b?`dialog`:void 0,"aria-modal":b?`true`:void 0,"aria-label":s||void 0,tabIndex:-1,onClick:e=>{if(d===!1||!b||e.defaultPrevented)return;let t=e.target.closest?.(`a[href]`),n=(t?.getAttribute(`href`)??``).trim();!t||n===``||n===`#`||/^javascript:/i.test(n)||e.target.closest(`[role="button"]`)&&t.contains(e.target.closest(`[role="button"]`))||x(!1)},style:{outline:`none`,...I?{backgroundColor:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,boxShadow:`0 0 0 1px var(--page-border, rgba(148, 163, 184, .4))`}:null,...!I&&!j?{width:k,maxWidth:`100%`,boxSizing:`border-box`}:null,...z(_),...I?R:null},children:[(s||c!==!1)&&(0,W.jsxs)(`div`,{...K(`header`),className:`wb-drw-head`,style:{alignItems:`center`,gap:12,padding:`14px 16px`,...I?{display:`flex`}:null},children:[(0,W.jsx)(`span`,{...K(`title`),style:{flexGrow:1,fontWeight:700,fontSize:17},children:s}),c!==!1&&(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,...K(`close-button`),onClick:ee,style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4,opacity:.75},children:`✕`})]}),(0,W.jsx)(`div`,{...K(`content`),children:g?.content})]})]});return(0,W.jsxs)(`div`,{ref:e=>{E.current=e,typeof v==`function`?v(e):v&&(v.current=e)},id:e||void 0,"data-wb-redirect":``,className:`${S}${b?` is-open`:``}`,children:[(0,W.jsx)(`style`,{children:F}),i===`button`&&(0,W.jsxs)(`button`,{type:`button`,...K(`trigger`),className:`wb-drw-trigger`,"aria-expanded":b,"aria-label":a?void 0:s||`Menu`,onClick:()=>!y&&x(!0),style:{alignItems:`center`,gap:8,padding:`8px 12px`,border:`1px solid var(--page-border, rgba(148, 163, 184, .4))`,borderRadius:8,background:`transparent`,color:`inherit`,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,...I?{display:`inline-flex`,marginBottom:L?12:0}:null},children:[(0,W.jsx)(`svg`,{...K(`icon`),width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:xo(o)})}),a?(0,W.jsx)(`span`,{children:a}):null]}),I&&i!==`button`&&!L&&(0,W.jsxs)(`div`,{style:{...U,display:`inline-flex`,alignItems:`center`,gap:6,padding:`4px 10px`,border:`1px dashed rgba(100, 116, 139, .55)`,borderRadius:6,fontSize:12,lineHeight:1.4,color:`rgba(100, 116, 139, .9)`,verticalAlign:`top`},children:[(0,W.jsxs)(`svg`,{width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,"aria-hidden":`true`,children:[(0,W.jsx)(`rect`,{x:`3`,y:`4`,width:`18`,height:`16`,rx:`2`}),(0,W.jsx)(`path`,{d:n===`right`?`M15 4v16`:n===`top`?`M3 10h18`:n===`bottom`?`M3 14h18`:`M9 4v16`})]}),h]}),D?(0,mt.createPortal)((0,W.jsx)(`div`,{className:`${S}${b?` is-open`:``}`,"data-wb":D.wb,"data-wb-redirect":``,style:{display:`contents`},children:te}),D.target):te]})}function Co({target:e=``,breakpoint:t=`tablet`,label:n=``,icon:r=``,forceMode:i,style:a,nodeRef:o,inert:s=!1}){let c=`wb-dbt-${(0,l.useId)().replace(/[^\w-]/g,``)}`,u=yo[t],d=i||t===`always`||!u?``:`@media (min-width: ${u+1}px) { .${c} { display: none !important; } }`,f=i===`inline`;return(0,W.jsxs)(W.Fragment,{children:[d?(0,W.jsx)(`style`,{children:d}):null,(0,W.jsxs)(`button`,{ref:o,type:`button`,className:c,"data-webim-open":!s&&e?e:void 0,"aria-label":n?void 0:`Menu`,onClick:s?e=>e.preventDefault():void 0,style:{display:f&&!s?`none`:`inline-flex`,opacity:f&&s?.35:void 0,alignItems:`center`,gap:8,padding:`8px 10px`,border:0,borderRadius:8,background:`transparent`,color:`inherit`,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,...z(a)},children:[(0,W.jsx)(`svg`,{...K(`icon`),width:`22`,height:`22`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,children:(0,W.jsx)(`path`,{d:xo(r)})}),n?(0,W.jsx)(`span`,{...K(`label`),children:n}):null]})]})}var wo={small:380,medium:560,large:820,full:`100%`};function To({dialogId:e=``,trigger:t=`button`,triggerLabel:n=`Open`,openOn:r=`trigger`,delay:i=0,size:a=`medium`,title:o=``,showClose:s=!0,backdropClose:c=!0,position:u=`center`,actions:d=[],showCloseAction:f=!1,closeLabel:p=`Close`,actionsAlign:m=`right`,linked:h,style:g,nodeRef:_,inert:v=!1}){let[y,b]=(0,l.useState)(!1),x=(0,l.useRef)(null);(0,l.useEffect)(()=>{if(v||!e)return;let t=t=>{t.target.closest?.(`a[href="#${e}"], [data-webim-open="${e}"]`)&&(t.preventDefault(),b(!0))};return document.addEventListener(`click`,t),()=>document.removeEventListener(`click`,t)},[v,e]),(0,l.useEffect)(()=>{if(v||r!==`load`)return;let e=setTimeout(()=>b(!0),Math.max(0,Number(i)||0)*1e3);return()=>clearTimeout(e)},[v,r,i]),(0,l.useEffect)(()=>{if(v||!y)return;let e=e=>e.key===`Escape`&&b(!1);document.addEventListener(`keydown`,e);let t=document.body.style.overflow;return document.body.style.overflow=`hidden`,x.current?.focus?.(),()=>{document.removeEventListener(`keydown`,e),document.body.style.overflow=t}},[v,y]);let S=wo[a]??wo.medium,C=e=>{let t=e.variant??`primary`,n={padding:`9px 16px`,borderRadius:6,cursor:`pointer`,fontSize:14,fontFamily:`inherit`,textDecoration:`none`,display:`inline-block`,...{primary:{background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`,border:`1px solid transparent`},outline:{background:`transparent`,color:`inherit`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},text:{background:`transparent`,color:`inherit`,border:`1px solid transparent`},danger:{background:`#dc2626`,color:`#ffffff`,border:`1px solid transparent`}}[t]??{}};return e.href&&!v?(0,W.jsx)(`a`,{...K(`button`,/^[a-z]+$/.test(t)&&`button-${t}`),href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:n,children:e.label},e.key):(0,W.jsx)(`button`,{...K(`button`,/^[a-z]+$/.test(t)&&`button-${t}`),type:`button`,onClick:()=>!v&&b(!1),style:n,children:e.label},e.key)},w=Array.isArray(d)?d:[],T=w.filter(e=>e.side===`left`),E=w.filter(e=>e.side!==`left`),D=f===!0?C({key:`__close`,label:p||`Close`,variant:`outline`}):null,O=T.length||E.length||D?(0,W.jsxs)(`div`,{...K(`footer`),style:{display:`flex`,alignItems:`center`,gap:8,padding:`14px 20px`,borderTop:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,justifyContent:T.length?`space-between`:m===`left`?`flex-start`:m===`center`?`center`:`flex-end`},children:[T.length>0&&(0,W.jsx)(`div`,{style:{display:`flex`,gap:8},children:T.map(C)}),(0,W.jsxs)(`div`,{style:{display:`flex`,gap:8},children:[D,E.map(C)]})]}):null,k=(0,W.jsxs)(`div`,{ref:x,role:`dialog`,"aria-modal":v?void 0:`true`,"aria-label":o||void 0,tabIndex:-1,onClick:e=>e.stopPropagation(),style:{width:typeof S==`number`?`min(${S}px, 100%)`:S,maxHeight:v?void 0:`85vh`,overflowY:v?void 0:`auto`,borderRadius:12,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,boxShadow:v?`none`:`0 24px 64px rgba(15, 23, 42, 0.35)`,outline:`none`,...z(g)},children:[(o||s!==!1)&&(0,W.jsxs)(`div`,{...K(`header`),style:{display:`flex`,alignItems:`center`,gap:12,padding:`16px 20px`,borderBottom:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},children:[(0,W.jsx)(`span`,{...K(`title`),style:{fontWeight:700,fontSize:17,flexGrow:1,fontFamily:`var(--page-heading-font, inherit)`},children:o}),s!==!1&&(0,W.jsx)(`button`,{type:`button`,"aria-label":`Close`,...K(`close-button`),onClick:()=>!v&&b(!1),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:2,opacity:.7},children:`✕`})]}),(0,W.jsx)(`div`,{...K(`content`),style:{padding:20},children:h?.content}),O]});return(0,W.jsxs)(`div`,{ref:_,id:e||void 0,style:v?void 0:{display:`contents`},children:[t===`button`&&(0,W.jsx)(`button`,{type:`button`,...K(`trigger`),onClick:()=>!v&&b(!0),style:{padding:`10px 18px`,border:0,borderRadius:6,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:n}),v?(0,W.jsx)(`div`,{style:{marginTop:t===`button`?12:0},children:k}):y&&(0,W.jsx)(`div`,{...K(`backdrop`),onClick:c===!1?void 0:()=>b(!1),style:{position:`fixed`,inset:0,zIndex:2147483e3,display:`flex`,alignItems:u===`top`?`flex-start`:`center`,justifyContent:`center`,padding:20,paddingTop:u===`top`?`8vh`:20,background:`rgba(15, 23, 42, 0.55)`,backdropFilter:`blur(2px)`},children:k})]})}function Eo({dropdownId:e=``,trigger:t=`button`,triggerLabel:n=`Menu`,openOn:r=`hover`,align:i=`left`,panelWidth:a=``,offset:o=8,editorOpen:s=!0,linked:c,style:u,nodeRef:d,inert:f=!1}){let[p,m]=(0,l.useState)(!1),h=(0,l.useRef)(null),g=(0,l.useRef)(null),_=r!==`click`,v=()=>{g.current&&clearTimeout(g.current),g.current=null},y=()=>{v(),g.current=setTimeout(()=>m(!1),160)};(0,l.useEffect)(()=>{if(f||!e)return;let t=`[data-webim-toggle="${e}"]`,n=e=>{e.target.closest?.(t)&&(e.preventDefault(),v(),m(e=>!e))},r=e=>{e.target.closest?.(t)&&(v(),m(!0))},i=e=>{let n=e.target.closest?.(t);!n||e.relatedTarget&&n.contains(e.relatedTarget)||y()};return document.addEventListener(`click`,n),_&&(document.addEventListener(`mouseover`,r),document.addEventListener(`mouseout`,i)),()=>{document.removeEventListener(`click`,n),document.removeEventListener(`mouseover`,r),document.removeEventListener(`mouseout`,i)}},[f,e,_]),(0,l.useEffect)(()=>{if(f||!p)return;let t=t=>{h.current?.contains(t.target)||e&&t.target.closest?.(`[data-webim-toggle="${e}"]`)||m(!1)},n=e=>e.key===`Escape`&&m(!1);return document.addEventListener(`mousedown`,t),document.addEventListener(`keydown`,n),()=>{document.removeEventListener(`mousedown`,t),document.removeEventListener(`keydown`,n)}},[f,p,e]),(0,l.useEffect)(()=>v,[]);let b=Number(a)>0?Number(a):null,x=f?s!==!1:p,S=(0,W.jsx)(`div`,{style:{position:`absolute`,top:`calc(100% + ${Number(o)||0}px)`,...i===`right`?{right:0}:i===`center`?{left:`50%`,transform:`translateX(-50%)`}:{left:0},zIndex:60,display:x?`block`:`none`,minWidth:b??240,width:b??void 0,maxWidth:`92vw`,padding:14,borderRadius:10,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, inherit)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,boxShadow:`0 16px 44px rgba(15, 23, 42, 0.22)`,...z(u)},children:c?.content??null});return(0,W.jsxs)(`div`,{ref:e=>{h.current=e,d&&d(e)},id:e||void 0,onMouseEnter:!f&&_?()=>{v(),m(!0)}:void 0,onMouseLeave:!f&&_?y:void 0,style:{position:`relative`,display:`inline-block`},children:[t!==`none`&&(0,W.jsxs)(`button`,{type:`button`,...K(`trigger`),"aria-haspopup":`true`,"aria-expanded":f?void 0:p,onClick:()=>!f&&m(e=>!e),style:{padding:`9px 16px`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,borderRadius:6,cursor:`pointer`,fontSize:15,fontFamily:`inherit`,background:`var(--page-surface, transparent)`,color:`inherit`,display:`inline-flex`,alignItems:`center`,gap:6},children:[n,(0,W.jsx)(`span`,{"aria-hidden":`true`,...K(`chevron`),style:{fontSize:10,opacity:.7},children:`▾`})]}),S]})}var Do={PageRoot:pr,MarkdownBlock:Mr,CalendarBlock:mo,LogoCarousel:_o,DialogBlock:To,DrawerBlock:So,DrawerTrigger:Co,DropdownBlock:Eo,Section:mr,Container:hr,LinkBlock:gr,Heading:_r,TextBlock:Ir,ButtonBlock:Br,ImageBlock:Vr,Spacer:$r,Divider:ei,BoxBlock:ti,SliderBlock:si,CanvasSlider:ci,TabsBlock:Ni,QuickStack:da,CollectionList:pa,CollectionSearch:ma,BreadcrumbsBlock:ha,PaginationBlock:ga,StepperBlock:Na,SocialLinksBlock:Ma,ThemeModeBlock:xa,ScrollTopBlock:Aa,CounterBlock:ka,OrgChartBlock:Qa,TableBlock:ao,IconBlock:xi,MapBlock:yi,MasonryBlock:Ci,AccordionBlock:Pi,NavbarBlock:Mi,MenuTreeBlock:Oi,ListBlock:Fr,TextSpan:Sr,QuoteBlock:Pr,TextLink:zr,RichTextBlock:jr,RichContentBlock:jr,VideoBlock:Wr,YouTubeBlock:Kr,IframeBlock:qr,PdfBlock:Yr,EmbedBlock:Qr,FormBlock:Zi,FormLabel:ra,FormFieldset:la,FormInput:ia,FormTextarea:aa,FormCheckbox:e=>(0,W.jsx)(oa,{kind:`checkbox`,...e}),FormRadio:e=>(0,W.jsx)(oa,{kind:`radio`,...e}),FormSelect:sa,FormFile:ca,FormRecaptcha:ta,FormSubmit:ua},Oo={id:`auth`,label:`Accounts`,category:`Apps`,keys:[`SiteLoginForm`,`SiteAccountMenu`],ssr:`shell`,settings:[`site.authRedirect`]},ko=(0,l.createContext)({user:null,status:`idle`,ensure:()=>{},refresh:()=>{},signOut:()=>{}});function Ao(e,t){return t?/^https?:\/\//i.test(t)?t:`${e.replace(/\/+$/,``)}${t.startsWith(`/`)?t:`/${t}`}`:``}function jo(e){let t=e&&typeof e==`object`?e[`site.session`]:null,n=t&&typeof t==`object`&&!Array.isArray(t)?t:{},r=e=>typeof e==`string`?e.trim():``,i=r(n.url),a=r(n.mePath),o=r(n.logoutPath);return{mode:n.mode===`custom`||n.mode===`off`?n.mode:`system`,url:i,mePath:a,logoutPath:o,meUrl:Ao(i,a),logoutUrl:Ao(i,o),loginPage:r(n.loginPage),userPath:r(n.userPath),auth:n.auth===`bearer`?`bearer`:`cookies`,tokenKey:r(n.tokenKey)||`webim_session_token`}}function Mo(e,t){if(!t)return e??null;let n=e;for(let e of t.split(`.`)){if(!n||typeof n!=`object`)return null;n=n[e]}return n??null}function No(e){try{return window.localStorage.getItem(e)||``}catch{return``}}function Po(e){try{window.localStorage.removeItem(e)}catch{}}var Fo=()=>{let e=(0,l.useContext)(ko);return(0,l.useEffect)(()=>{e.ensure()},[e]),e};function Io({children:e,initialUser:t,disabled:n,apiUrl:r,tenant:i}){let a=(0,l.useContext)(G),o=r||a?.apiUrl||`/api`,s=i||a?.tenant||``,c=(0,l.useMemo)(()=>jo(a?.settings),[a?.settings]),[u,d]=(0,l.useState)(t??null),[f,p]=(0,l.useState)(t?`user`:n?`guest`:`idle`),m=(0,l.useRef)(!1),h=(0,l.useCallback)((e,t)=>fetch(`${o}${e}`,{...t,credentials:`include`,headers:{"content-type":`application/json`,...s?{"x-tenant":s}:{},...t?.headers}}),[o,s]),g=(0,l.useCallback)(e=>(d(e),p(e?`user`:`guest`),e),[]),_=(0,l.useCallback)(()=>{if(n)return Promise.resolve(null);if(c.mode===`off`)return Promise.resolve(g(null));if(c.mode===`custom`){let e=c.auth===`bearer`?No(c.tokenKey):``;return!c.meUrl||c.auth===`bearer`&&!e?Promise.resolve(g(null)):fetch(c.meUrl,{...c.auth===`bearer`?{headers:{authorization:`Bearer ${e}`}}:{credentials:`include`}}).then(e=>e.ok?e.json():null).then(e=>{let t=Mo(e,c.userPath);return g(t&&typeof t==`object`?t:null)}).catch(()=>g(null))}return h(`/site/me`).then(e=>e.ok?e.json():null).then(e=>g(e?.payload??null)).catch(()=>g(null))},[h,c,n,g]),v=(0,l.useCallback)(()=>{if(c.mode===`off`)return g(null),Promise.resolve();if(c.mode===`custom`){let e=c.auth===`bearer`?No(c.tokenKey):``;return(c.logoutUrl?fetch(c.logoutUrl,{method:`post`,...c.auth===`bearer`?{headers:e?{authorization:`Bearer ${e}`}:{}}:{credentials:`include`}}).catch(()=>{}):Promise.resolve()).then(()=>{c.auth===`bearer`&&Po(c.tokenKey),g(null)})}return h(`/site/logout`,{method:`post`}).catch(()=>{}).then(()=>{g(null)})},[h,c,g]),y=(0,l.useCallback)(()=>{m.current||n||t||(m.current=!0,p(`loading`),_())},[n,t,_]),b=(0,l.useMemo)(()=>({user:u,status:f,ensure:y,refresh:_,signOut:v}),[u,f,y,_,v]);return(0,l.useEffect)(()=>{n||typeof window>`u`||(window.webim={...window.webim,user:u,status:f,loginUrl:c.loginPage||null,requireUser:()=>m.current||t?Promise.resolve(u):_(),refresh:_,signOut:v},window.dispatchEvent(new CustomEvent(`webim:session`,{detail:{user:u,status:f}})))},[n,u,f,t,c.loginPage,_,v]),(0,W.jsx)(ko.Provider,{value:b,children:e})}function Lo({when:e,children:t}){let{status:n}=Fo();return!e||e===`always`?t:n===`idle`||n===`loading`?null:e===`user`==(n===`user`)?t:null}function Ro({mode:e=`login`,redirect:t,emailLabel:n=`Email`,passwordLabel:r=`Password`,nameLabel:i=`Name`,submitLabel:a,style:o,nodeRef:s,inert:c,linked:u,show:d}){let{tenant:f,apiUrl:p,settings:m}=(0,l.useContext)(G),[h,g]=(0,l.useState)(`form`),[_,v]=(0,l.useState)(``),[y,b]=(0,l.useState)(!1),x=e===`register`,S=c?d||`form`:h,C=e=>typeof e==`string`&&e.startsWith(`/`)&&!e.startsWith(`//`)?e:``,w=async e=>{if(e.preventDefault(),c)return;let n=new FormData(e.currentTarget);b(!0),v(``);try{let e=await fetch(`${p||`/api`}/site/${x?`register`:`login`}`,{method:`post`,headers:{"content-type":`application/json`,...f?{"x-tenant":f}:{}},credentials:`same-origin`,body:JSON.stringify({email:n.get(`email`),password:n.get(`password`),...x?{name:n.get(`name`)||``}:{}})}),r=await e.json().catch(()=>null);if(!e.ok||r?.success===!1){v(r?.error?.message||`Sign-in failed`),g(`error`),b(!1);return}if(g(`success`),typeof window<`u`){let e=C(t)||C(new URLSearchParams(window.location.search).get(`next`))||C(m?.[`site.authRedirect`])||C(m?.[`apps.auth.redirect`])||`/`;window.location.assign(e)}}catch{v(`Sign-in failed`),g(`error`),b(!1)}};return(0,W.jsxs)(`div`,{ref:s,style:{display:`grid`,gap:12,maxWidth:360,...z(o)},children:[(0,W.jsxs)(`form`,{...K(`form`),onSubmit:w,style:{display:S===`form`?`grid`:`none`,gap:10},children:[x?(0,W.jsxs)(`label`,{...K(`label`),style:{...Ii,display:`grid`,gap:6},children:[i,(0,W.jsx)(`input`,{...K(`input`),name:`name`,type:`text`,style:Li,...zi(c)})]}):null,(0,W.jsxs)(`label`,{...K(`label`),style:{...Ii,display:`grid`,gap:6},children:[n,(0,W.jsx)(`input`,{...K(`input`),name:`email`,type:`email`,required:!c,style:Li,...zi(c)})]}),(0,W.jsxs)(`label`,{...K(`label`),style:{...Ii,display:`grid`,gap:6},children:[r,(0,W.jsx)(`input`,{...K(`input`),name:`password`,type:`password`,required:!c,style:Li,...zi(c)})]}),(0,W.jsx)(`button`,{...K(`button`,y&&`button-busy`),type:c?`button`:`submit`,disabled:y||void 0,style:{...cr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:y?.6:1},children:a||(x?`Create account`:`Sign in`)}),_?(0,W.jsx)(`p`,{...K(`error`),style:{margin:0,fontSize:14,color:`#dc2626`},children:_}):null]}),(0,W.jsx)(`div`,{style:{display:S===`success`?`block`:`none`},children:u?.success??null}),(0,W.jsx)(`div`,{style:{display:S===`error`?`block`:`none`},children:u?.error??null})]})}function zo({greeting:e=`Hi`,signOutLabel:t=`Sign out`,showEmail:n=!1,style:r,nodeRef:i,inert:a,linked:o,show:s}){let{user:c,status:l,signOut:u}=Fo(),d=a?s||`user`:l,f=a?{name:`Ada Lovelace`,email:`ada@example.com`}:c;return d===`loading`?(0,W.jsx)(`div`,{ref:i,style:{minHeight:24,...z(r)}}):d===`user`?(0,W.jsxs)(`div`,{ref:i,style:{display:`flex`,alignItems:`center`,gap:10,...z(r)},children:[(0,W.jsxs)(`span`,{...K(`greeting`),style:{...Ii,fontWeight:600},children:[e,` `,f?.name||f?.email||``]}),n&&f?.email?(0,W.jsx)(`span`,{...K(`email`),style:{...Ii,opacity:.7},children:f.email}):null,(0,W.jsx)(`button`,{...K(`button`),type:`button`,onClick:a?void 0:u,style:{...cr,border:0,padding:`8px 16px`,borderRadius:8,fontSize:14,cursor:a?`default`:`pointer`},...zi(a),children:t})]}):(0,W.jsx)(`div`,{ref:i,style:{display:`flex`,alignItems:`center`,gap:10,...z(r)},children:o?.signedOut??null})}var Bo={id:`consent`,label:`Cookie consent`,category:`Apps`,keys:[`CookieConsent`],ssr:`shell`,settings:[]},Vo=`webim.cookie_consent`;function Ho(){try{let e=window.localStorage.getItem(Vo),t=e?JSON.parse(e):null;return t?.choice===`accepted`||t?.choice===`declined`?t.choice:``}catch{return``}}function Uo(e){try{document.querySelectorAll(`.webim-page`).forEach(t=>t.setAttribute(`data-webim-consent`,e))}catch{}}function Wo(e){try{window.localStorage.setItem(Vo,JSON.stringify({choice:e,at:new Date().toISOString()}))}catch{}Uo(e);try{window.dispatchEvent(new CustomEvent(`webim:consent`,{detail:{choice:e}}))}catch{}}var Go={bottom:{left:0,right:0,bottom:0},top:{left:0,right:0,top:0},"bottom-left":{left:16,bottom:16,maxWidth:400},"bottom-right":{right:16,bottom:16,maxWidth:400}};function Ko({message:e,acceptLabel:t,rejectLabel:n,showReject:r,linkLabel:i,linkHref:a,position:o,linked:s,style:c,nodeRef:u,inert:d}){let[f,p]=(0,l.useState)(!!d),[m,h]=(0,l.useState)(null),g=e=>{h(e),typeof u==`function`&&u(e)};if((0,l.useEffect)(()=>{if(d)return;let e=Ho();e?Uo(e):p(!0)},[d,m]),!f)return null;let _=e=>()=>{d||(Wo(e),p(!1))},v=Go[o]??Go.bottom,y={appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,padding:`8px 16px`,borderRadius:8,cursor:d?`default`:`pointer`,whiteSpace:`nowrap`};return(0,W.jsxs)(`div`,{ref:g,role:`region`,"aria-label":`Cookie consent`,style:{...d?{position:`relative`}:{position:`fixed`,zIndex:2147483e3,...v},display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:12,padding:16,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:o===`bottom`||o===`top`?0:12,boxShadow:`0 8px 30px rgba(15, 23, 42, 0.18)`,fontSize:14,lineHeight:1.5,...z(c)},children:[(0,W.jsxs)(`div`,{...K(`message`),style:{flex:`1 1 260px`,minWidth:0},children:[s?.content??(e||`We use cookies to run this site and to understand how it is used.`),i&&a?(0,W.jsxs)(W.Fragment,{children:[` `,(0,W.jsx)(`a`,{...K(`link`),href:a,onClick:d?e=>e.preventDefault():void 0,style:{color:`var(--page-accent, inherit)`,textDecoration:`underline`},children:i})]}):null]}),(0,W.jsxs)(`div`,{...K(`actions`),style:{display:`flex`,gap:8,flexShrink:0},children:[r===!1?null:(0,W.jsx)(`button`,{...K(`decline-button`),type:`button`,onClick:_(`declined`),style:{...y,background:`transparent`,color:`inherit`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.6))`},children:n||`Decline`}),(0,W.jsx)(`button`,{...K(`accept-button`),type:`button`,onClick:_(`accepted`),style:{...y,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,border:`1px solid transparent`},children:t||`Accept`})]})]})}var qo={id:`language`,label:`Language`,category:`Apps`,keys:[`SiteLanguagePicker`],ssr:`prefetch`,settings:[`locales`]},Jo={id:`search`,label:`Search`,category:`Apps`,keys:[`SiteSearch`],ssr:`prefetch`,settings:[]},Yo=50,Xo=2e3;function Zo(){return typeof window>`u`?``:new URLSearchParams(window.location.search).get(`q`)??``}function Qo(e,t){let n=e?.data??{},r=[];for(let e of Object.values(n)){let t=e==null?``:qn(e);if(t&&r.push(t),r.join(` `).length>Xo)break}return r.join(` `).slice(0,Xo).toLocaleLowerCase(t||void 0)}function $o({placeholder:e=`Search…`,buttonLabel:t=`Search`,showButton:n=!0,live:r=!1,layout:i=`inline`,includePages:a=!0,collections:o=[],limit:s=10,emptyText:c=`Nothing found`,hint:u=``,style:d,nodeRef:f,inert:p=!1,sample:m=!1}){let{tenant:h,apiUrl:g,locale:_}=(0,l.useContext)(G),[v,y]=(0,l.useState)(()=>Zo()),[b,x]=(0,l.useState)(()=>Zo()),[S,C]=(0,l.useState)(null),[w,T]=(0,l.useState)(!1),E=(0,l.useRef)(null),D=i===`popup`;(0,l.useEffect)(()=>{let e=()=>{let e=Zo();y(e),x(e)};return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]),(0,l.useEffect)(()=>{if(!r)return;let e=setTimeout(()=>{y(b),b.trim()&&T(!0)},200);return()=>clearTimeout(e)},[r,b]),(0,l.useEffect)(()=>{if(!D)return;let e=e=>{E.current&&!E.current.contains(e.target)&&T(!1)},t=e=>e.key===`Escape`&&T(!1);return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[D]),(0,l.useEffect)(()=>{let e=!0,t=h?{"x-tenant":h}:{},n=e=>fetch(`${g}${e}`,{headers:t}).then(e=>e.json()).then(e=>e?.payload).catch(()=>null),r=[a?n(`/site/pages`).then(e=>({kind:`page`,rows:Array.isArray(e)?e:[]})):null,...(Array.isArray(o)?o:[]).filter(Boolean).map(e=>n(`/dynamic/${encodeURIComponent(e)}?all=1${_?`&locale=${encodeURIComponent(_)}`:``}`).then(t=>({kind:`entry`,slug:e,rows:Array.isArray(t)?t:Array.isArray(t?.data)?t.data:[]})))].filter(Boolean);return Promise.all(r).then(t=>e&&C(t)),()=>{e=!1}},[g,h,_,a,JSON.stringify(o)]);let O=v.trim().toLocaleLowerCase(_||void 0),k=[];if(O&&S)for(let e of S)if(e.kind===`page`)for(let t of e.rows){if(t?.access&&t.access!==`public`)continue;let e=String(t?.title??``);`${e} ${t?.slug??``}`.toLocaleLowerCase(_||void 0).includes(O)&&k.push({key:`page:${t.slug}`,title:e||t.slug,url:`/${t.slug}`,kind:`page`})}else for(let t of e.rows){if(!Qo(t,_).includes(O))continue;let n=t?.data??{},r=qn(n.name)||`Untitled`,i=qn(n.slug);k.push({key:`entry:${t.id}`,title:r,url:i?`/${e.slug}/${i}`:`/${e.slug}`,kind:`entry`})}let A=k.slice(0,Math.min(Math.max(1,s),Yo)),j=e=>{if(p){e.preventDefault(),y(b),T(!0);return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);b.trim()?t.set(`q`,b.trim()):t.delete(`q`),t.delete(`page`);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`)),T(!0)},M=m&&!O?[{key:`sample-1`,title:`About us`,url:`/about`,kind:`page`},{key:`sample-2`,title:`Spring collection`,url:`/blog/spring`,kind:`entry`}]:null,N=M??A,P=!M&&O&&S&&!A.length,F=!D||w&&(N.length>0||P),I=N.length>0&&(0,W.jsx)(`ul`,{...K(`results`),style:{listStyle:`none`,margin:0,padding:0,display:`flex`,flexDirection:`column`,gap:2},children:N.map(e=>(0,l.createElement)(`li`,{...K(`item`),key:e.key},(0,W.jsxs)(`a`,{...K(`result`),href:p?void 0:e.url,style:{display:`block`,padding:`10px 12px`,borderRadius:6,color:`inherit`,textDecoration:`none`,border:D?0:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`},children:[(0,W.jsx)(`span`,{...K(`title`),style:{display:`block`,fontWeight:600},children:e.title}),(0,W.jsx)(`span`,{...K(`url`),style:{display:`block`,fontSize:12,opacity:.6},children:e.url})]})))});return(0,W.jsx)(`div`,{ref:f,style:{width:`100%`,...z(d)},children:(0,W.jsxs)(`div`,{ref:E,style:{position:`relative`},children:[(0,W.jsxs)(`form`,{...K(`form`),method:`get`,onSubmit:j,style:{display:`flex`,gap:8,alignItems:`center`},children:[(0,W.jsx)(`input`,{...K(`input`),type:`search`,name:`q`,value:b,placeholder:e,onChange:e=>x(e.target.value),onFocus:()=>O&&T(!0),style:{...Li,flexGrow:1,minWidth:0}}),n!==!1&&(0,W.jsx)(`button`,{...K(`button`),type:`submit`,style:{padding:`10px 16px`,border:0,borderRadius:6,cursor:`pointer`,fontSize:14,fontFamily:`inherit`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:t})]}),u&&(0,W.jsx)(`div`,{...K(`hint`),style:{fontSize:13,opacity:.65,marginTop:6},children:u}),F&&(0,W.jsxs)(`div`,{...K(`panel`),style:D?{position:`absolute`,top:`100%`,left:0,right:0,zIndex:30,marginTop:6,padding:6,maxHeight:320,overflowY:`auto`,borderRadius:8,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.35))`,background:`var(--page-surface, #f2f2f2)`,boxShadow:`0 12px 32px rgba(15, 23, 42, 0.18)`}:{marginTop:14},children:[I,P&&(0,W.jsx)(`div`,{...K(`empty`),style:{fontSize:14,opacity:.65,padding:D?`10px 12px`:0},children:c})]})]})})}var es={id:`shop`,label:`Shop`,category:`Shop`,keys:[`ShopProductGrid`,`ShopProduct`,`ShopCartButton`,`ShopCheckout`,`ShopOrderHistory`,`ShopCurrencyPicker`,`ShopFavorites`],ssr:`shell`,settings:[`shop.enabled`]},ts=`webim.cart.`,ns=`webim.currency.`,rs=new Map,is={get(e){try{return window.localStorage.getItem(e)??``}catch{return``}},set(e,t){try{t?window.localStorage.setItem(e,t):window.localStorage.removeItem(e)}catch{}}};function as(e){if(typeof window>`u`)return!1;try{return new URL(e,window.location.href).origin===window.location.origin}catch{return!1}}async function os(e,t,n,{method:r=`GET`,body:i}={}){let a=await fetch(`${e}${n}`,{method:r,...as(e)?{credentials:`include`}:{},headers:{...t?{"x-tenant":t}:{},...i?{"content-type":`application/json`}:{}},body:i?JSON.stringify(i):void 0}),o=await a.json().catch(()=>null);if(!o||o.success===!1||!a.ok){let e=o?.error;throw{message:(e&&typeof e==`object`?e.message:e)||`Request failed (${a.status})`,code:(e&&typeof e==`object`?e.code:o?.code)||`ERROR`}}return o.payload}var ss={id:``,currency:``,lines:[],count:0,subtotal:0,coupon:null,coupon_error:null,coupon_error_code:null,discounts:[],discount_total:0,shipping_before:0,shipping_total:0,total:0};function cs(e,t){let n=`${ts}${t||`default`}`,r=`${ns}${t||`default`}`,i=new Set,a={cart:ss,loading:!1,loaded:!1,error:null,currency:is.get(r)},o=null,s=()=>i.forEach(e=>e()),c=e=>{a={...a,...e},s()},l=e=>(e&&typeof e==`object`&&(e.id&&is.set(n,e.id),c({cart:e,loaded:!0,error:null})),e),u=()=>{if(o)return o;let r=is.get(n),i=new URLSearchParams({...r?{id:r}:{},...a.currency?{currency:a.currency}:{}}).toString();return c({loading:!0}),o=os(e,t,`/store/cart${i?`?${i}`:``}`).then(l).catch(e=>c({error:e,loaded:!0})).finally(()=>{o=null,c({loading:!1})}),o},d=async(r,i,o)=>{c({loading:!0});try{return l(await os(e,t,`/store/cart`,{method:`POST`,body:{cart_id:is.get(n)||void 0,product_id:r,variant_id:i??null,quantity:o,currency:a.currency||void 0}}))}finally{c({loading:!1})}};return typeof window<`u`&&window.addEventListener(`storage`,e=>{e.key===r&&c({currency:is.get(r)}),(e.key===n||e.key===r)&&u()}),{getState:()=>a,subscribe:e=>(i.add(e),()=>i.delete(e)),load:u,setLine:d,add:(e,t,n=1)=>{let r=a.cart.lines.find(n=>n.product_id===e&&(n.variant_id??null)===(t??null));return d(e,t,(r?.quantity??0)+n)},setCoupon:async r=>{c({loading:!0});try{return l(await os(e,t,`/store/cart/coupon`,{method:`POST`,body:{cart_id:is.get(n),code:r}}))}finally{c({loading:!1})}},setCountry:async(r,i)=>is.get(n)?l(await os(e,t,`/store/cart/country`,{method:`POST`,body:{cart_id:is.get(n),country:r,...i!==void 0&&{postal_code:i}}})):a.cart,setDelivery:async r=>is.get(n)?l(await os(e,t,`/store/cart/delivery`,{method:`POST`,body:{cart_id:is.get(n),delivery:r}})):a.cart,setCurrency:async i=>{if(is.set(r,i),c({currency:i}),!is.get(n))return u();try{return l(await os(e,t,`/store/cart/currency`,{method:`POST`,body:{cart_id:is.get(n),currency:i}}))}catch{return is.set(r,``),c({currency:``}),u()}},reset:()=>{is.set(n,``),c({cart:ss})},cartId:()=>is.get(n)}}function ls(e,t){let n=`${e}|${t}`;return rs.has(n)||rs.set(n,cs(e,t)),rs.get(n)}function us(e,t){let n=Array.isArray(e?.currencies)?e.currencies:[];return t&&n.includes(t)?t:e?.currency||``}var ds=`AD AE AF AG AI AL AM AO AQ AR AS AT AU AW AX AZ BA BB BD BE BF BG BH BI BJ BL BM BN BO BQ BR BS BT BV BW BY BZ CA CC CD CF CG CH CI CK CL CM CN CO CR CU CV CW CX CY CZ DE DJ DK DM DO DZ EC EE EG EH ER ES ET FI FJ FK FM FO FR GA GB GD GE GF GG GH GI GL GM GN GP GQ GR GS GT GU GW GY HK HM HN HR HT HU ID IE IL IM IN IO IQ IR IS IT JE JM JO JP KE KG KH KI KM KN KP KR KW KY KZ LA LB LC LI LK LR LS LT LU LV LY MA MC MD ME MF MG MH MK ML MM MN MO MP MQ MR MS MT MU MV MW MX MY MZ NA NC NE NF NG NI NL NO NP NR NU NZ OM PA PE PF PG PH PK PL PM PN PR PS PT PW PY QA RE RO RS RU RW SA SB SC SD SE SG SH SI SJ SK SL SM SN SO SR SS ST SV SX SY SZ TC TD TF TG TH TJ TK TL TM TN TO TR TT TV TW TZ UA UG UM US UY UZ VA VC VE VG VI VN VU WF WS YE YT ZA ZM ZW`.split(` `);function fs(e,t=[],n=null){let r;try{r=new Intl.DisplayNames([e||`en`],{type:`region`})}catch{r={of:e=>e}}let i=(n??ds).map(e=>({code:e,name:r.of(e)??e})),a=i.filter(e=>t.includes(e.code)).sort((t,n)=>t.name.localeCompare(n.name,e||void 0)),o=i.filter(e=>!t.includes(e.code)).sort((t,n)=>t.name.localeCompare(n.name,e||void 0));return[...a,...o]}function ps(e,t,n){let r=t||`USD`;try{let t=new Intl.NumberFormat(n||void 0,{style:`currency`,currency:r}),i=t.resolvedOptions().maximumFractionDigits??2;return t.format(Number(e||0)/10**i)}catch{return`${(Number(e||0)/100).toFixed(2)} ${r}`}}var ms={en:{add:`Add to cart`,adding:`Adding…`,added:`Added to cart`,choose:`Choose options`,soldOut:`Sold out`,onlyLeft:`Only {n} left`,quantity:`Quantity`,cart:`Cart`,emptyCart:`Your cart is empty.`,subtotal:`Subtotal`,shipping:`Shipping`,free:`Free`,total:`Total`,remove:`Remove`,contact:`Contact`,name:`Full name`,email:`E-mail`,phone:`Phone`,address:`Delivery address`,line1:`Address`,line2:`Apartment, suite (optional)`,city:`City`,region:`State / province`,postal:`Postal code`,country:`Country`,note:`Order note (optional)`,gift:`This order is a gift`,giftHint:`No prices on the packing slip in the parcel.`,giftMessage:`Gift message (optional)`,giftRecipient:`Recipient’s name (optional — the parcel is addressed to them)`,payment:`Payment`,stripe:`Card`,bank_transfer:`Bank transfer`,cash_on_delivery:`Cash on delivery`,placeOrder:`Place order`,placing:`Placing order…`,required:`Please fill in the required fields.`,noMethods:`This shop has no payment method set up yet.`,thanks:`Thank you! Your order {number} is placed.`,paid:`Your payment was received.`,awaiting:`We are waiting for your payment to be confirmed.`,transfer:`Please transfer the total using the details below:`,reference:`Payment reference`,referenceNote:`Write this reference in the transfer description — it is how your payment is matched to your order.`,copy:`Copy`,copied:`Copied`,cod:`You will pay when the order is delivered.`,cancelled:`The payment was cancelled — your cart is still here.`,closed:`This shop is not open right now.`,continue:`Continue shopping`,noProducts:`No products yet.`,coupon:`Discount code`,apply:`Apply`,removeCoupon:`Remove`,discount:`Discount`,tax:`VAT`,taxIncluded:`incl. VAT`,chooseCountry:`Choose a country`,noShipping:`This shop does not ship to that country.`,delivery:`Delivery`,deliveryPick:`Enter your country to see the delivery options.`,arrives:`Arrives {date}`,arrivesRange:`Arrives {from} – {to}`,pickupAt:`Pick up at {name}`,pickupNote:`We will let you know when it is ready.`,deliveredBy:`Delivery: {name}`,SHIPPING_UNAVAILABLE:`This shop does not ship to that country.`,DELIVERY_UNAVAILABLE:`That delivery option is no longer available — pick another.`,COUPON_INVALID:`This code is not valid.`,COUPON_NOT_STARTED:`This code is not active yet.`,COUPON_EXPIRED:`This code has expired.`,COUPON_USED_UP:`This code has been used up.`,COUPON_MIN_SUBTOTAL:`Your cart is below this code’s minimum.`,COUPON_MIN_QUANTITY:`Add more items to use this code.`,COUPON_NOT_ELIGIBLE:`This code is not available for your account.`,COUPON_ALREADY_USED:`You have already used this code.`,COUPON_NOT_APPLICABLE:`None of the items in your cart qualify for this code.`,COUPON_NOT_COMBINABLE:`This code can’t be combined with a better discount already applied.`,COUPON_SHIPPING_NA:`This code doesn’t apply to this delivery.`,myOrders:`My orders`,signInForOrders:`Sign in to see your orders.`,noOrders:`You have no orders yet.`,order:`Order`,date:`Date`,status:`Status`,st_pending:`Pending`,st_processing:`Processing`,st_shipped:`Shipped`,downloads_title:`Your downloads`,download:`Download`,download_left:`{count} downloads left`,download_until:`valid until {date}`,download_expired:`expired on {date}`,download_unavailable:`No longer available`,policy_refund:`Refund policy`,policy_privacy:`Privacy policy`,policy_terms:`Terms of service`,policy_shipping:`Shipping policy`,policy_contact:`Contact information`,policy_legal:`Legal notice`,policy_agree:`By placing your order you agree to our {terms}.`,policy_updated:`Last updated {date}`,contact_email:`E-mail`,contact_phone:`Phone`,contact_address:`Address`,contact_trade:`Trade register / VAT number`,close:`Close`,tracking:`Tracking`,track_parcel:`Track parcel`,st_delivered:`Delivered`,st_cancelled:`Cancelled`,pay_unpaid:`Awaiting payment`,pay_refunded:`Refunded`,pay_failed:`Payment failed`,reviewsTitle:`Reviews`,reviewsCount:`{n} reviews`,reviewsOne:`1 review`,qaCount:`{n} Q&A`,lovedBy:`Loved! {n} people favorited this`,lovedByOne:`1 person favorited this`,favorite:`Add to favorites`,unfavorite:`Remove from favorites`,noReviews:`No reviews yet. Be the first to review this product.`,writeReview:`Write a review`,editReview:`Edit your review`,yourRating:`Your rating`,reviewTitle:`Title (optional)`,reviewBody:`What did you think?`,submitReview:`Submit review`,reviewPending:`Thanks! Your review appears here once the shop approves it.`,reviewThanks:`Thanks for your review!`,awaitingApproval:`Awaiting approval`,verified:`Verified purchase`,shopReply:`Reply from the shop`,signInToReview:`Sign in to write a review`,pickRating:`Choose a rating first.`,sortNewest:`Newest`,sortHighest:`Highest rated`,sortLowest:`Lowest rated`,sortHelpful:`Most detailed`,allRatings:`All ratings`,starsN:`{n} stars`,loadMore:`Show more`,questionsTitle:`Questions & answers`,noQuestions:`No questions yet.`,askQuestion:`Ask a question`,questionPlaceholder:`What would you like to know about this product?`,submitQuestion:`Send question`,questionPending:`Thanks! Your question appears here once the shop answers it.`,signInToAsk:`Sign in to ask a question`,answerLabel:`Answer`,qMark:`Q:`,aMark:`A:`,awaitingAnswer:`Waiting for an answer`,anonymous:`A customer`,myFavorites:`My favorites`,noFavorites:`You have no favorites yet.`,signInForFavorites:`Sign in to see your favorites`,REVIEW_BUYERS_ONLY:`Only customers who bought this product can review it.`,QUESTION_LIMIT:`You already have questions waiting for an answer.`,specifications:`Specifications`,yes:`Yes`,no:`No`},tr:{add:`Sepete ekle`,adding:`Ekleniyor…`,added:`Sepete eklendi`,choose:`Seçenekleri gör`,soldOut:`Tükendi`,onlyLeft:`Son {n} adet`,quantity:`Adet`,cart:`Sepet`,emptyCart:`Sepetiniz boş.`,subtotal:`Ara toplam`,shipping:`Kargo`,free:`Ücretsiz`,total:`Toplam`,remove:`Kaldır`,contact:`İletişim`,name:`Ad soyad`,email:`E-posta`,phone:`Telefon`,address:`Teslimat adresi`,line1:`Adres`,line2:`Daire, kat (isteğe bağlı)`,city:`Şehir`,region:`İlçe / bölge`,postal:`Posta kodu`,country:`Ülke`,note:`Sipariş notu (isteğe bağlı)`,gift:`Bu sipariş bir hediye`,giftHint:`Paketteki irsaliyede fiyat yer almaz.`,giftMessage:`Hediye notu (isteğe bağlı)`,giftRecipient:`Alıcının adı (isteğe bağlı — paket bu kişiye gönderilir)`,payment:`Ödeme`,stripe:`Kredi kartı`,bank_transfer:`Havale / EFT`,cash_on_delivery:`Kapıda ödeme`,placeOrder:`Siparişi ver`,placing:`Sipariş veriliyor…`,required:`Lütfen zorunlu alanları doldurun.`,noMethods:`Bu mağazada henüz bir ödeme yöntemi tanımlı değil.`,thanks:`Teşekkürler! {number} numaralı siparişiniz alındı.`,paid:`Ödemeniz alındı.`,awaiting:`Ödemenizin onaylanmasını bekliyoruz.`,transfer:`Lütfen toplam tutarı aşağıdaki bilgilere gönderin:`,reference:`Ödeme referansı`,referenceNote:`Bu referansı havale / EFT açıklamasına yazın — ödemeniz siparişinizle bu sayede eşleşir.`,copy:`Kopyala`,copied:`Kopyalandı`,cod:`Ödemeyi sipariş teslim edilirken yapacaksınız.`,cancelled:`Ödeme iptal edildi — sepetiniz duruyor.`,closed:`Bu mağaza şu anda açık değil.`,continue:`Alışverişe devam et`,noProducts:`Henüz ürün yok.`,coupon:`İndirim kodu`,apply:`Uygula`,removeCoupon:`Kaldır`,discount:`İndirim`,tax:`KDV`,taxIncluded:`dahil KDV`,chooseCountry:`Ülke seçin`,noShipping:`Bu mağaza o ülkeye gönderim yapmıyor.`,delivery:`Teslimat`,deliveryPick:`Teslimat seçeneklerini görmek için ülkenizi seçin.`,arrives:`Tahmini teslim: {date}`,arrivesRange:`Tahmini teslim: {from} – {to}`,pickupAt:`{name} mağazasından teslim alın`,pickupNote:`Hazır olduğunda size haber vereceğiz.`,deliveredBy:`Teslimat: {name}`,SHIPPING_UNAVAILABLE:`Bu mağaza o ülkeye gönderim yapmıyor.`,DELIVERY_UNAVAILABLE:`Bu teslimat seçeneği artık yok — başka birini seçin.`,COUPON_INVALID:`Bu kod geçerli değil.`,COUPON_NOT_STARTED:`Bu kod henüz aktif değil.`,COUPON_EXPIRED:`Bu kodun süresi dolmuş.`,COUPON_USED_UP:`Bu kodun kullanım hakkı dolmuş.`,COUPON_MIN_SUBTOTAL:`Sepetiniz bu kodun alt sınırının altında.`,COUPON_MIN_QUANTITY:`Bu kodu kullanmak için daha fazla ürün ekleyin.`,COUPON_NOT_ELIGIBLE:`Bu kod hesabınız için geçerli değil.`,COUPON_ALREADY_USED:`Bu kodu zaten kullandınız.`,COUPON_NOT_APPLICABLE:`Sepetinizdeki ürünlerden hiçbiri bu koda uygun değil.`,COUPON_NOT_COMBINABLE:`Bu kod, uygulanan daha avantajlı bir indirimle birleştirilemez.`,COUPON_SHIPPING_NA:`Bu kod bu teslimat için geçerli değil.`,myOrders:`Siparişlerim`,signInForOrders:`Siparişlerinizi görmek için giriş yapın.`,noOrders:`Henüz siparişiniz yok.`,order:`Sipariş`,date:`Tarih`,status:`Durum`,st_pending:`Bekliyor`,st_processing:`Hazırlanıyor`,st_shipped:`Kargoda`,downloads_title:`İndirmeleriniz`,download:`İndir`,download_left:`{count} indirme hakkı kaldı`,download_until:`{date} tarihine kadar geçerli`,download_expired:`{date} tarihinde sona erdi`,download_unavailable:`Artık kullanılamıyor`,policy_refund:`İade politikası`,policy_privacy:`Gizlilik politikası`,policy_terms:`Hizmet koşulları`,policy_shipping:`Kargo politikası`,policy_contact:`İletişim bilgileri`,policy_legal:`Yasal bildirim`,policy_agree:`Siparişi vererek {terms} kabul etmiş olursunuz.`,policy_updated:`Son güncelleme: {date}`,contact_email:`E-posta`,contact_phone:`Telefon`,contact_address:`Adres`,contact_trade:`Ticaret sicil / Vergi no`,close:`Kapat`,tracking:`Kargo takibi`,track_parcel:`Kargonu takip et`,st_delivered:`Teslim edildi`,st_cancelled:`İptal edildi`,pay_unpaid:`Ödeme bekleniyor`,pay_refunded:`İade edildi`,pay_failed:`Ödeme başarısız`,reviewsTitle:`Değerlendirmeler`,reviewsCount:`{n} Değerlendirme`,reviewsOne:`1 Değerlendirme`,qaCount:`{n} Soru-Cevap`,lovedBy:`Sevilen ürün! {n} kişi favoriledi!`,lovedByOne:`1 kişi favoriledi`,favorite:`Favorilere ekle`,unfavorite:`Favorilerden çıkar`,noReviews:`Henüz değerlendirme yok. İlk değerlendiren siz olun.`,writeReview:`Değerlendirme yaz`,editReview:`Değerlendirmenizi düzenleyin`,yourRating:`Puanınız`,reviewTitle:`Başlık (isteğe bağlı)`,reviewBody:`Ürün hakkında ne düşünüyorsunuz?`,submitReview:`Değerlendirmeyi gönder`,reviewPending:`Teşekkürler! Değerlendirmeniz mağaza onayladıktan sonra burada görünür.`,reviewThanks:`Değerlendirmeniz için teşekkürler!`,awaitingApproval:`Onay bekliyor`,verified:`Doğrulanmış alışveriş`,shopReply:`Mağazanın yanıtı`,signInToReview:`Değerlendirme yazmak için giriş yapın`,pickRating:`Önce bir puan seçin.`,sortNewest:`En yeni`,sortHighest:`En yüksek puan`,sortLowest:`En düşük puan`,sortHelpful:`En detaylı`,allRatings:`Tüm puanlar`,starsN:`{n} yıldız`,loadMore:`Daha fazla göster`,questionsTitle:`Soru-Cevap`,noQuestions:`Henüz soru yok.`,askQuestion:`Soru sor`,questionPlaceholder:`Bu ürün hakkında ne öğrenmek istersiniz?`,submitQuestion:`Soruyu gönder`,questionPending:`Teşekkürler! Sorunuz mağaza yanıtladıktan sonra burada görünür.`,signInToAsk:`Soru sormak için giriş yapın`,answerLabel:`Yanıt`,qMark:`S:`,aMark:`C:`,awaitingAnswer:`Yanıt bekliyor`,anonymous:`Bir müşteri`,myFavorites:`Favorilerim`,noFavorites:`Henüz favoriniz yok.`,signInForFavorites:`Favorilerinizi görmek için giriş yapın`,REVIEW_BUYERS_ONLY:`Bu ürünü yalnızca satın alan müşteriler değerlendirebilir.`,QUESTION_LIMIT:`Yanıt bekleyen sorularınız var.`,specifications:`Özellikler`,yes:`Evet`,no:`Hayır`}};function hs(e){let t=ms[String(e||``).toLowerCase().split(`-`)[0]]??ms.en,n=(e,n)=>{let r=t[e]??ms.en[e]??e;return n?r.replace(/\{(\w+)\}/g,(e,t)=>t in n?String(n[t]):e):r};return n.has=e=>e in ms.en,n}var gs=(e,t)=>t?.code&&e.has(t.code)?e(t.code):t?.message??``,_s=new Map;function vs(e,t){let n=`${e}|${t}`;return _s.has(n)||_s.set(n,os(e,t,`/store/policies`).then(e=>Array.isArray(e)?e:[]).catch(()=>(_s.delete(n),[]))),_s.get(n)}function ys(e){let t=new Date,n=Math.max(0,Math.round(Number(e)||0));for(;n>0;)t.setDate(t.getDate()+1),t.getDay()!==0&&t.getDay()!==6&&--n;return t}function bs(e,t,n,r){let i=e=>e!=null&&Number.isFinite(Number(e));if(!i(n)&&!i(r))return``;let a;try{a=new Intl.DateTimeFormat(t||`en`,{month:`short`,day:`numeric`})}catch{a=new Intl.DateTimeFormat(`en`,{month:`short`,day:`numeric`})}let o=a.format(ys(i(n)?n:r)),s=a.format(ys(i(r)?r:n));return o===s?e(`arrives`,{date:o}):e(`arrivesRange`,{from:o,to:s})}var xs=`var(--page-muted, rgba(100,116,139,1))`,Ss=`1px solid var(--page-border, #d1d5db)`,Cs=`var(--page-surface, #f2f2f2)`,ws=`#f59e0b`,Ts={...cr,border:0,borderRadius:`8px`,padding:`10px 18px`,fontSize:`14px`,fontWeight:600,fontFamily:`inherit`},Es={...Ts,backgroundColor:`transparent`,color:`var(--page-text, #111827)`,border:Ss};function Ds(){let{tenant:e,apiUrl:t,locale:n,settings:r}=(0,l.useContext)(G),i=(0,l.useMemo)(()=>hs(n),[n]),a=e=>r?.[e]!==!1;return{tenant:e,apiUrl:t||`/api`,locale:n,words:i,reviewsOn:a(`shop.reviews`),questionsOn:a(`shop.questions`),favoritesOn:a(`shop.favorites`),moderated:r?.[`shop.reviewModeration`]!==`auto`,loginHref:()=>{let e=jo(r).loginPage||`/login`,t=typeof window>`u`?``:`${window.location.pathname}${window.location.search}`;return t?`${e}${e.includes(`?`)?`&`:`?`}next=${encodeURIComponent(t)}`:e}}}var Os=(e,t)=>{try{return new Intl.NumberFormat(t||void 0,{notation:`compact`,maximumFractionDigits:1}).format(e)}catch{return String(e)}},ks=(e,t)=>{try{return new Intl.DateTimeFormat(t||void 0,{day:`numeric`,month:`long`,year:`numeric`}).format(new Date(e))}catch{return String(e).slice(0,10)}},As=`M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z`;function js({fill:e=0,size:t=16,clipId:n}){return(0,W.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,"aria-hidden":`true`,style:{display:`block`},children:[(0,W.jsx)(`defs`,{children:(0,W.jsx)(`clipPath`,{id:n,children:(0,W.jsx)(`rect`,{x:`0`,y:`0`,width:24*e,height:`24`})})}),(0,W.jsx)(`path`,{d:As,fill:`var(--page-border, #d1d5db)`}),e>0&&(0,W.jsx)(`path`,{d:As,fill:ws,clipPath:`url(#${n})`})]})}function Ms({value:e=0,size:t=16}){let n=(0,l.useId)().replace(/:/g,``);return(0,W.jsx)(`span`,{role:`img`,"aria-label":`${e}/5`,...K(`stars`),style:{display:`inline-flex`,gap:`1px`,verticalAlign:`middle`},children:[0,1,2,3,4].map(r=>(0,W.jsx)(js,{fill:Math.max(0,Math.min(1,e-r)),size:t,clipId:`${n}-${r}`},r))})}function Ns({value:e,onChange:t,size:n=28,label:r}){let i=(0,l.useId)().replace(/:/g,``),[a,o]=(0,l.useState)(0),s=a||e;return(0,W.jsx)(`span`,{role:`radiogroup`,"aria-label":r,...K(`star-picker`),style:{display:`inline-flex`,gap:`2px`},onMouseLeave:()=>o(0),children:[1,2,3,4,5].map(r=>(0,W.jsx)(`button`,{type:`button`,role:`radio`,"aria-checked":e===r,"aria-label":String(r),onMouseEnter:()=>o(r),onClick:()=>t(r),style:{background:`none`,border:0,padding:0,cursor:`pointer`,lineHeight:0},children:(0,W.jsx)(js,{fill:+(s>=r),size:n,clipId:`${i}-${r}`})},r))})}function Ps(e,{inert:t}){let{tenant:n,apiUrl:r,favoritesOn:i}=Ds(),[a,o]=(0,l.useState)({favorited:!1,count:null});(0,l.useEffect)(()=>{if(!e||!i||t)return;let a=!0;return os(r,n,`/store/products/${encodeURIComponent(e)}/favorite`).then(e=>a&&o(e)).catch(()=>{}),()=>{a=!1}},[r,n,e,i,t]);let s=async()=>{let t=!a.favorited;o(e=>({favorited:t,count:Math.max(0,(e.count??0)+(t?1:-1))}));try{o(await os(r,n,`/store/products/${encodeURIComponent(e)}/favorite`,{method:`POST`,body:{on:t}}))}catch(e){throw o(e=>({favorited:!t,count:Math.max(0,(e.count??0)+(t?-1:1))})),e}};return{...a,toggle:s}}var Fs=e=>(0,W.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,"aria-hidden":`true`,style:{display:`block`},children:(0,W.jsx)(`path`,{d:`M12 21s-7.5-4.6-9.6-9.2C.9 8.4 3 4.5 6.8 4.5c2.1 0 3.6 1.1 5.2 3 1.6-1.9 3.1-3 5.2-3 3.8 0 5.9 3.9 4.4 7.3C19.5 16.4 12 21 12 21z`,fill:e?`#ef4444`:`none`,stroke:e?`#ef4444`:`currentColor`,strokeWidth:`1.8`})});function Is({product:e,inert:t=!1,sample:n=!1}){let{locale:r,words:i,reviewsOn:a,questionsOn:o,favoritesOn:s,loginHref:c}=Ds(),u=e?.sample?``:e?.slug||e?.id||``,d=Ps(u,{inert:t||!u}),[f,p]=(0,l.useState)(``),m=n?29:e?.rating_count??0,h=n?4.3:Number(e?.rating_avg??0),g=n?110:e?.questions_count??0,_=n?1300:d.count??e?.favorites_count??0,v=e=>n=>{n.preventDefault(),!t&&document.getElementById(e)?.scrollIntoView({behavior:`smooth`,block:`start`})},y=async()=>{if(!(t||!u))try{await d.toggle()}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(c()):p(gs(i,e))}},b=[];return a&&m>0&&b.push((0,W.jsxs)(`span`,{...K(`rating`),style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,W.jsx)(`strong`,{...K(`rating-value`),children:h.toLocaleString(r||void 0,{minimumFractionDigits:1,maximumFractionDigits:1})}),(0,W.jsx)(Ms,{value:h}),(0,W.jsx)(`a`,{href:`#reviews`,onClick:v(`reviews`),...K(`rating-link`),style:{color:`inherit`},children:m===1?i(`reviewsOne`):i(`reviewsCount`,{n:Os(m,r)})})]},`r`)),o&&g>0&&b.push((0,W.jsx)(`a`,{href:`#questions`,onClick:v(`questions`),...K(`qa-link`),style:{color:`inherit`},children:i(`qaCount`,{n:Os(g,r)})},`q`)),!b.length&&!s?null:(0,W.jsxs)(`div`,{...K(`engagement`),style:{display:`flex`,flexDirection:`column`,gap:`8px`,fontSize:`14px`},children:[b.length>0&&(0,W.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:b.flatMap((e,t)=>t?[(0,W.jsx)(`span`,{...K(`separator`),style:{color:xs},children:`•`},`s${t}`),e]:[e])}),s&&(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`},children:[(0,W.jsx)(`button`,{type:`button`,onClick:y,...K(`favorite-button`,d.favorited&&`favorite-button-active`),"aria-pressed":d.favorited,"aria-label":d.favorited?i(`unfavorite`):i(`favorite`),title:d.favorited?i(`unfavorite`):i(`favorite`),style:{...Es,padding:`7px`,borderRadius:`999px`,lineHeight:0},children:Fs(d.favorited)}),_>0&&(0,W.jsx)(`span`,{...K(`favorites-count`),style:{fontWeight:600},children:_===1?i(`lovedByOne`):i(`lovedBy`,{n:Os(_,r)})})]}),f&&(0,W.jsx)(`span`,{...K(`note`),style:{color:xs,fontSize:`13px`},children:f})]})}var Ls={data:[{id:`s1`,author:`Ayşe Y.`,rating:5,title:`Harika`,body:`Beklediğimden de iyi çıktı.`,verified:!0,reply:``,created_at:new Date().toISOString()},{id:`s2`,author:`Mehmet K.`,rating:4,title:``,body:`Kaliteli, kargo biraz gecikti.`,verified:!1,reply:`Geri bildiriminiz için teşekkürler!`,created_at:new Date(Date.now()-864e5*3).toISOString()}],total:{all:29,filtered:29},summary:{average:4.3,count:29,histogram:[1,1,3,6,18]}};function Rs({product:e,inert:t=!1,sample:n=!1}){let{tenant:r,apiUrl:i,locale:a,words:o,reviewsOn:s,moderated:c,loginHref:u}=Ds(),d=Fo(),f=e?.sample?``:e?.slug||e?.id||``,[p,m]=(0,l.useState)(null),[h,g]=(0,l.useState)(`newest`),[_,v]=(0,l.useState)(0),[y,b]=(0,l.useState)(5),[x,S]=(0,l.useState)(0),[C,w]=(0,l.useState)({rating:0,title:``,body:``}),[T,E]=(0,l.useState)(!1),[D,O]=(0,l.useState)(!1),[k,A]=(0,l.useState)(``);if((0,l.useEffect)(()=>{if(!s||!f)return;let e=!0,t=`?limit=${y}&sort=${h}${_?`&rating=${_}`:``}`;return os(i,r,`/store/products/${encodeURIComponent(f)}/reviews${t}`).then(t=>e&&m(t)).catch(()=>e&&m({data:[],total:{all:0,filtered:0},summary:{average:0,count:0,histogram:[0,0,0,0,0]}})),()=>{e=!1}},[i,r,f,h,_,y,x,s]),!s)return null;let j=n||!f?Ls:p,M=j?.summary??{average:0,count:0,histogram:[0,0,0,0,0]},N=j?.data?.find(e=>e.mine),P=d.status===`user`,F=()=>{if(!t){if(!P){window.location.assign(u());return}w(N?{rating:N.rating,title:N.title,body:N.body}:{rating:0,title:``,body:``}),A(``),E(!0)}},I=async e=>{if(e.preventDefault(),!C.rating){A(o(`pickRating`));return}O(!0),A(``);try{await os(i,r,`/store/products/${encodeURIComponent(f)}/reviews`,{method:`POST`,body:C}),E(!1),A(o(c?`reviewPending`:`reviewThanks`)),S(e=>e+1)}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(u()):A(gs(o,e))}finally{O(!1)}},L=Math.max(1,...M.histogram);return(0,W.jsxs)(`section`,{id:`reviews`,...K(`reviews`),style:{display:`flex`,flexDirection:`column`,gap:`16px`,scrollMarginTop:`80px`},children:[(0,W.jsx)(`h2`,{...K(`reviews-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:o(`reviewsTitle`)}),(0,W.jsxs)(`div`,{...K(`reviews-summary`),style:{display:`flex`,gap:`32px`,flexWrap:`wrap`,alignItems:`center`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,alignItems:`flex-start`,gap:`4px`},children:[(0,W.jsx)(`span`,{...K(`reviews-average`),style:{fontSize:`40px`,fontWeight:700,lineHeight:1},children:M.count?M.average.toLocaleString(a||void 0,{minimumFractionDigits:1,maximumFractionDigits:1}):`–`}),(0,W.jsx)(Ms,{value:M.average,size:18}),(0,W.jsx)(`span`,{...K(`reviews-count`),style:{color:xs,fontSize:`13px`},children:M.count===1?o(`reviewsOne`):o(`reviewsCount`,{n:M.count})})]}),(0,W.jsx)(`div`,{...K(`histogram`),style:{display:`flex`,flexDirection:`column`,gap:`4px`,minWidth:`220px`,flex:`1 1 220px`,maxWidth:`360px`},children:[5,4,3,2,1].map(e=>{let n=M.histogram[e-1]??0,r=_===e;return(0,W.jsxs)(`button`,{type:`button`,disabled:!n&&!r,onClick:()=>!t&&v(r?0:e),title:o(`starsN`,{n:e}),...K(`histogram-row`,r&&`histogram-row-active`),style:{display:`grid`,gridTemplateColumns:`28px 1fr 32px`,alignItems:`center`,gap:`8px`,background:`none`,border:0,padding:`2px 0`,cursor:n?`pointer`:`default`,color:`inherit`,fontFamily:`inherit`,fontSize:`13px`,fontWeight:r?700:400},children:[(0,W.jsxs)(`span`,{children:[e,`★`]}),(0,W.jsx)(`span`,{...K(`histogram-track`),style:{height:`8px`,borderRadius:`4px`,background:Cs,overflow:`hidden`},children:(0,W.jsx)(`span`,{...K(`histogram-bar`),style:{display:`block`,height:`100%`,width:`${n/L*100}%`,background:ws}})}),(0,W.jsx)(`span`,{style:{color:xs,textAlign:`right`},children:n})]},e)})}),(0,W.jsx)(`div`,{style:{marginLeft:`auto`},children:(0,W.jsx)(`button`,{type:`button`,onClick:F,...K(`review-button`),style:Ts,children:o(P||t?N?`editReview`:`writeReview`:`signInToReview`)})})]}),T&&(0,W.jsxs)(`form`,{onSubmit:I,...K(`review-form`),style:{display:`flex`,flexDirection:`column`,gap:`10px`,padding:`16px`,border:Ss,borderRadius:`12px`},children:[(0,W.jsxs)(`label`,{...K(`label`),style:{display:`flex`,alignItems:`center`,gap:`12px`,fontWeight:600},children:[o(`yourRating`),(0,W.jsx)(Ns,{value:C.rating,label:o(`yourRating`),onChange:e=>w(t=>({...t,rating:e}))})]}),(0,W.jsx)(`input`,{value:C.title,maxLength:150,placeholder:o(`reviewTitle`),...K(`input`),onChange:e=>w(t=>({...t,title:e.target.value})),style:Li}),(0,W.jsx)(`textarea`,{value:C.body,maxLength:4e3,rows:4,placeholder:o(`reviewBody`),...K(`textarea`),onChange:e=>w(t=>({...t,body:e.target.value})),style:{...Li,resize:`vertical`,fontFamily:`inherit`}}),(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,W.jsx)(`button`,{type:`submit`,disabled:D,...K(`submit-button`),style:Ts,children:o(`submitReview`)}),(0,W.jsx)(`button`,{type:`button`,onClick:()=>E(!1),...K(`cancel-button`),style:Es,children:`✕`})]})]}),k&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:xs},children:k}),(0,W.jsxs)(`div`,{...K(`reviews-toolbar`),style:{display:`flex`,alignItems:`center`,gap:`12px`,flexWrap:`wrap`},children:[(0,W.jsxs)(`select`,{value:h,onChange:e=>g(e.target.value),disabled:t,...K(`sort-select`),style:{...Li,width:`auto`},children:[(0,W.jsx)(`option`,{value:`newest`,children:o(`sortNewest`)}),(0,W.jsx)(`option`,{value:`helpful`,children:o(`sortHelpful`)}),(0,W.jsx)(`option`,{value:`highest`,children:o(`sortHighest`)}),(0,W.jsx)(`option`,{value:`lowest`,children:o(`sortLowest`)})]}),_>0&&(0,W.jsxs)(`button`,{type:`button`,onClick:()=>v(0),...K(`filter-chip`),style:{...Es,padding:`6px 12px`},children:[o(`starsN`,{n:_}),` ✕`]})]}),j&&!j.data.length&&(0,W.jsx)(`p`,{...K(`empty`),style:{margin:0,color:xs},children:o(`noReviews`)}),(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`},children:(j?.data??[]).map(e=>(0,W.jsxs)(`article`,{...K(`review`),style:{padding:`16px 0`,borderTop:Ss,display:`flex`,flexDirection:`column`,gap:`6px`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:[(0,W.jsx)(Ms,{value:e.rating}),e.title&&(0,W.jsx)(`strong`,{...K(`review-title`),children:e.title}),e.mine&&e.status===`pending`&&(0,W.jsx)(`span`,{...K(`badge`),style:{fontSize:`12px`,padding:`2px 8px`,borderRadius:`999px`,background:Cs,color:xs},children:o(`awaitingApproval`)})]}),e.body&&(0,W.jsx)(`p`,{...K(`review-body`),style:{margin:0,whiteSpace:`pre-wrap`,lineHeight:1.55},children:e.body}),(0,W.jsxs)(`span`,{...K(`meta`),style:{fontSize:`13px`,color:xs},children:[e.author||o(`anonymous`),` · `,ks(e.created_at,a),e.verified&&(0,W.jsxs)(`span`,{...K(`verified`),style:{color:`#16a34a`,fontWeight:600},children:[` · ✓ `,o(`verified`)]})]}),e.reply&&(0,W.jsxs)(`div`,{...K(`reply`),style:{marginTop:`4px`,padding:`10px 12px`,borderRadius:`8px`,background:Cs,fontSize:`14px`},children:[(0,W.jsx)(`strong`,{...K(`reply-label`),style:{display:`block`,fontSize:`12px`,color:xs,marginBottom:`2px`},children:o(`shopReply`)}),(0,W.jsx)(`span`,{style:{whiteSpace:`pre-wrap`},children:e.reply})]})]},e.id))}),j&&j.data.length<(j.total?.filtered??0)&&!t&&(0,W.jsx)(`button`,{type:`button`,onClick:()=>b(e=>e+10),...K(`load-more`),style:{...Es,alignSelf:`center`},children:o(`loadMore`)})]})}var zs={data:[{id:`q1`,author:`Can D.`,question:`Bulaşık makinesinde yıkanır mı?`,answer:`Evet, yıkanabilir.`,created_at:new Date().toISOString()}],total:{all:1,filtered:1}};function Bs({product:e,inert:t=!1,sample:n=!1}){let{tenant:r,apiUrl:i,locale:a,words:o,questionsOn:s,loginHref:c}=Ds(),u=Fo(),d=e?.sample?``:e?.slug||e?.id||``,[f,p]=(0,l.useState)(null),[m,h]=(0,l.useState)(5),[g,_]=(0,l.useState)(0),[v,y]=(0,l.useState)(``),[b,x]=(0,l.useState)(!1),[S,C]=(0,l.useState)(``);if((0,l.useEffect)(()=>{if(!s||!d)return;let e=!0;return os(i,r,`/store/products/${encodeURIComponent(d)}/questions?limit=${m}`).then(t=>e&&p(t)).catch(()=>e&&p({data:[],total:{all:0,filtered:0}})),()=>{e=!1}},[i,r,d,m,g,s]),!s)return null;let w=n||!d?zs:f,T=u.status===`user`,E=async e=>{if(e.preventDefault(),!(t||v.trim().length<3)){if(!T){window.location.assign(c());return}x(!0),C(``);try{await os(i,r,`/store/products/${encodeURIComponent(d)}/questions`,{method:`POST`,body:{question:v.trim()}}),y(``),C(o(`questionPending`)),_(e=>e+1)}catch(e){e?.code===`LOGIN_REQUIRED`?window.location.assign(c()):C(gs(o,e))}finally{x(!1)}}};return(0,W.jsxs)(`section`,{id:`questions`,...K(`questions`),style:{display:`flex`,flexDirection:`column`,gap:`16px`,scrollMarginTop:`80px`},children:[(0,W.jsx)(`h2`,{...K(`questions-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:o(`questionsTitle`)}),T||t?(0,W.jsxs)(`form`,{onSubmit:E,...K(`question-form`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:[(0,W.jsx)(`input`,{value:v,maxLength:1e3,placeholder:o(`questionPlaceholder`),...K(`input`),onChange:e=>y(e.target.value),style:{...Li,flex:`1 1 260px`}}),(0,W.jsx)(`button`,{type:`submit`,disabled:b||v.trim().length<3,...K(`submit-button`),style:Ts,children:o(`submitQuestion`)})]}):(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:c(),...K(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:o(`signInToAsk`)})}),S&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:xs},children:S}),w&&!w.data.length&&(0,W.jsx)(`p`,{...K(`empty`),style:{margin:0,color:xs},children:o(`noQuestions`)}),(0,W.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`},children:(w?.data??[]).map(e=>(0,W.jsxs)(`article`,{...K(`question`),style:{padding:`14px 0`,borderTop:Ss,display:`flex`,flexDirection:`column`,gap:`6px`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`baseline`},children:[(0,W.jsx)(`strong`,{...K(`question-mark`),style:{color:`var(--page-accent, #111827)`},children:o(`qMark`)}),(0,W.jsx)(`span`,{...K(`question-text`),style:{fontWeight:600},children:e.question})]}),e.answer?(0,W.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`baseline`},children:[(0,W.jsx)(`strong`,{...K(`answer-mark`),style:{color:`#16a34a`},children:o(`aMark`)}),(0,W.jsx)(`span`,{...K(`answer-text`),style:{whiteSpace:`pre-wrap`},children:e.answer})]}):(0,W.jsx)(`span`,{...K(`badge`),style:{fontSize:`12px`,color:xs},children:o(`awaitingAnswer`)}),(0,W.jsxs)(`span`,{...K(`meta`),style:{fontSize:`12px`,color:xs},children:[e.author||o(`anonymous`),` · `,ks(e.created_at,a)]})]},e.id))}),w&&w.data.length<(w.total?.filtered??0)&&!t&&(0,W.jsx)(`button`,{type:`button`,onClick:()=>h(e=>e+10),...K(`load-more`),style:{...Es,alignSelf:`center`},children:o(`loadMore`)})]})}var Vs=`1px solid var(--page-border, #d1d5db)`,Hs=`var(--page-muted, rgba(100,116,139,1))`,Us=e=>/^(https?:)?\/\//i.test(String(e))||String(e).startsWith(`/`)?String(e):``;function Ws(e,t,n,r){let i=n||void 0;switch(e.type){case`integer`:case`number`:return Number(t).toLocaleString(i);case`money`:try{return new Intl.NumberFormat(i,{style:`currency`,currency:t.currency}).format(t.amount)}catch{return`${t.amount} ${t.currency}`}case`measurement`:return`${Number(t.value).toLocaleString(i)} ${String(t.unit).replace(`_`,` `)}`;case`rating`:{let n=Number(e.config?.max??5);return(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[n===5&&(0,W.jsx)(Ms,{value:Number(t)}),Number(t).toLocaleString(i),` / `,n]})}case`date`:case`datetime`:try{return new Intl.DateTimeFormat(i,e.type===`date`?{day:`numeric`,month:`long`,year:`numeric`}:{dateStyle:`medium`,timeStyle:`short`}).format(new Date(t))}catch{return String(t)}case`switch`:return r(t?`yes`:`no`);case`color`:return(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,W.jsx)(`span`,{style:{width:`14px`,height:`14px`,borderRadius:`4px`,background:t,border:Vs,display:`inline-block`}}),t]});case`link`:{let e=Us(t);return e?(0,W.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`},children:t}):String(t)}case`image`:return Us(t)?(0,W.jsx)(`img`,{src:t,alt:e.name,style:{maxWidth:`160px`,maxHeight:`120px`,borderRadius:`6px`,display:`block`}}):``;case`video`:case`file`:return Us(t)?(0,W.jsx)(`a`,{href:t,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`},children:String(t).split(`/`).pop()}):``;case`media`:return(Array.isArray(t)?t:[t]).filter(Us).map((e,t)=>(0,W.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, #111827)`,marginRight:`8px`},children:String(e).split(`/`).pop()},t));case`language`:try{return new Intl.DisplayNames([n||`en`],{type:`language`}).of(t)??t}catch{return String(t)}case`product`:return t?.slug?(0,W.jsx)(`a`,{href:`/product/${encodeURIComponent(t.slug)}`,style:{color:`var(--page-accent, #111827)`},children:t.name}):``;case`page`:return t?.slug?(0,W.jsx)(`a`,{href:`/${t.slug}`,style:{color:`var(--page-accent, #111827)`},children:t.name}):``;case`shop_collection`:return t?.name??``;case`richtext`:return Array.isArray(t)?(0,W.jsx)(`div`,{style:{lineHeight:1.55},children:Ar(t)}):String(t);case`json`:return(0,W.jsx)(`code`,{style:{fontSize:`12px`,whiteSpace:`pre-wrap`},children:JSON.stringify(t)});default:return String(t)}}function Gs({specs:e,locale:t,words:n}){return!Array.isArray(e)||!e.length?null:(0,W.jsxs)(`section`,{...K(`specs`),style:{display:`flex`,flexDirection:`column`,gap:`12px`},children:[(0,W.jsx)(`h2`,{...K(`specs-title`),style:{margin:0,fontSize:`var(--page-h3, 24px)`},children:n(`specifications`)}),(0,W.jsx)(`div`,{role:`table`,...K(`specs-table`),style:{border:Vs,borderRadius:`10px`,overflow:`hidden`},children:e.map((e,r)=>{let i=e.multiple&&Array.isArray(e.value)?e.value:[e.value];return(0,W.jsxs)(`div`,{role:`row`,...K(`spec-row`),style:{display:`grid`,gridTemplateColumns:`minmax(120px, 34%) 1fr`,gap:`16px`,padding:`10px 14px`,borderTop:r?Vs:0,fontSize:`14px`},children:[(0,W.jsx)(`span`,{role:`rowheader`,...K(`spec-name`),style:{color:Hs},children:e.name}),(0,W.jsx)(`span`,{role:`cell`,...K(`spec-value`),style:{display:`flex`,flexWrap:`wrap`,gap:`4px 10px`,alignItems:`center`},children:i.map((r,a)=>(0,W.jsxs)(`span`,{children:[Ws(e,r,t,n),a<i.length-1&&e.type!==`color`?`,`:``]},a))})]},e.key)})})]})}var Y=`var(--page-muted, rgba(100,116,139,1))`,Ks=`1px solid var(--page-border, #d1d5db)`,qs=`var(--page-surface, #f2f2f2)`,Js={...cr,border:0,borderRadius:`8px`,padding:`10px 18px`,fontSize:`14px`,fontWeight:600,fontFamily:`inherit`,textAlign:`center`},Ys={...Js,backgroundColor:`transparent`,color:`var(--page-text, #111827)`,border:Ks};function Xs(){let{tenant:e,apiUrl:t,locale:n,param:r,settings:i}=(0,l.useContext)(G),a=(0,l.useMemo)(()=>hs(n),[n]),o=i?.[`shop.orderPrefix`],s=i?.[`shop.orderSuffix`],c=(0,l.useCallback)(e=>`${typeof o==`string`?o:`#`}${e}${typeof s==`string`?s:``}`,[o,s]);return{tenant:e,apiUrl:t||`/api`,locale:n,param:r||``,words:a,orderId:c}}function Zs(e,t,n=!0){let r=(0,l.useMemo)(()=>ls(e,t),[e,t]),i=(0,l.useSyncExternalStore)(r.subscribe,r.getState,r.getState);return(0,l.useEffect)(()=>{n&&!i.loaded&&!i.loading&&r.load()},[n,r]),{store:r,...i}}var Qs=e=>typeof window>`u`?``:new URLSearchParams(window.location.search).get(e)??``;function $s({value:e,label:t,onCommit:n}){let[r,i]=(0,l.useState)(null),a=()=>{if(r===null)return;let t=Math.max(1,Math.round(Number(r))||1);i(null),t!==Number(e)&&n(t)};return(0,W.jsx)(`input`,{type:`number`,...K(`quantity-input`),min:1,"aria-label":t,value:r??e,onChange:e=>i(e.target.value),onBlur:a,onKeyDown:e=>{e.key===`Enter`&&a()},style:{...Li,width:`64px`,padding:`4px 8px`}})}var ec=`/product/{slug}`,tc=e=>!e||e===`/product?product={slug}`?ec:e,nc=(e,t)=>String(tc(e)).replace(/\{slug\}/g,encodeURIComponent(t.slug)).replace(/\{id\}/g,t.id);function rc(e){let t=e.variants?.length?e.variants.map(e=>e.stock):[e.stock];return t.some(e=>e==null)?null:t.reduce((e,t)=>e+Number(t),0)}function ic({product:e,variant:t,locale:n,size:r=16}){let i=e.currency,a=t?.price??e.price;return(0,W.jsxs)(`span`,{...K(`price`),style:{display:`inline-flex`,alignItems:`baseline`,gap:`8px`,fontSize:`${r}px`},children:[(0,W.jsx)(`span`,{...K(`price-current`),style:{fontWeight:700},children:ps(a,i,n)}),e.compare_at_price>a&&(0,W.jsx)(`span`,{...K(`price-old`),style:{color:Y,textDecoration:`line-through`,fontSize:`0.85em`},children:ps(e.compare_at_price,i,n)})]})}var ac=[1,2,3].map(e=>({id:`sample-${e}`,slug:`sample-${e}`,name:`Product ${e}`,price:e*1990,compare_at_price:e===2?4990:null,images:[],variants:[],stock:null,currency:`USD`,sample:!0}));function oc({columns:e=3,limit:t=12,gap:n=20,productHref:r=`/product/{slug}`,showButton:i=!0,buttonLabel:a=``,emptyText:o=``,collection:s=``,source:c=`catalog`,loginHref:u=``,style:d,nodeRef:f,inert:p=!1,sample:m=!1,noNavigate:h=!1}){let{tenant:g,apiUrl:_,locale:v,words:y}=Xs(),b=Ds(),[x,S]=(0,l.useState)(null),[C,w]=(0,l.useState)(null),[T,E]=(0,l.useState)(``),[D,O]=(0,l.useState)({}),[k,A]=(0,l.useState)(!1),{store:j,currency:M}=Zs(_,g,!p),N=c===`favorites`;(0,l.useEffect)(()=>{let e=!0,n=Math.max(1,Math.min(100,Number(t)||12)),r=M?`&currency=${encodeURIComponent(M)}`:``;if(N&&p){S([]);return}return A(!1),Promise.all([os(_,g,N?`/store/my/favorites?limit=${n}${r}`:`/store/products?limit=${n}${r}${s?`&collection=${encodeURIComponent(s)}`:``}`),os(_,g,`/store/config`)]).then(([t,n])=>{if(!e)return;let r=us(n,M);w(n),S(Array.isArray(t?.data)?t.data.map(e=>({...e,currency:r})):[])}).catch(t=>{e&&(A(N&&t?.code===`LOGIN_REQUIRED`),S([]))}),()=>{e=!1}},[_,g,t,M,s,N,p]);let P=x?.length||!m?x??[]:ac,F=async e=>{if(!(p||e.sample)){E(e.id);try{await j.add(e.id,null,1),O(t=>({...t,[e.id]:y(`added`)}))}catch(t){O(n=>({...n,[e.id]:gs(y,t)}))}finally{E(``)}}};return(0,W.jsxs)(`div`,{ref:f,style:{...z(d)},children:[N&&(0,W.jsx)(`h2`,{...K(`title`),style:{margin:`0 0 12px`,fontSize:`22px`},children:y(`myFavorites`)}),k&&(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:u||b.loginHref(),onClick:h?e=>e.preventDefault():void 0,...K(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:y(`signInForFavorites`)})}),x!==null&&!k&&!P.length&&(0,W.jsx)(`p`,{...K(`empty`),style:{color:Y,margin:0},children:o||(N?y(`noFavorites`):C&&!C.enabled?y(`closed`):y(`noProducts`))}),(0,W.jsx)(`div`,{...K(`grid`),style:{display:`grid`,gridTemplateColumns:`repeat(auto-fill, minmax(min(100%, max(160px, calc((100% - ${(Number(e)-1)*n}px) / ${Number(e)||3}))), 1fr))`,gap:`${n}px`},children:P.map(e=>{let t=rc(e)===0,n=nc(r,e);return(0,W.jsxs)(`div`,{...K(`card`),style:{display:`flex`,flexDirection:`column`,gap:`10px`},children:[(0,W.jsxs)(`a`,{href:n,onClick:h?e=>e.preventDefault():void 0,...K(`card-link`),style:{color:`inherit`,textDecoration:`none`},children:[(0,W.jsx)(`div`,{...K(`card-media`),style:{aspectRatio:`1 / 1`,borderRadius:`10px`,overflow:`hidden`,background:qs},children:e.images?.[0]&&(0,W.jsx)(`img`,{src:e.images[0],alt:e.name,loading:`lazy`,...K(`card-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),(0,W.jsx)(`div`,{...K(`card-title`),style:{marginTop:`10px`,fontWeight:600},children:e.name})]}),b.reviewsOn&&e.rating_count>0&&(0,W.jsxs)(`span`,{...K(`card-rating`),style:{display:`inline-flex`,alignItems:`center`,gap:`6px`,fontSize:`13px`,color:Y},children:[(0,W.jsx)(Ms,{value:Number(e.rating_avg),size:14}),`(`,Os(e.rating_count,v),`)`]}),(0,W.jsx)(ic,{product:e,locale:v}),i&&(e.variants?.length?(0,W.jsx)(`a`,{href:n,onClick:h?e=>e.preventDefault():void 0,...K(`choose-button`),style:{...Ys,display:`block`},children:y(`choose`)}):(0,W.jsx)(`button`,{type:`button`,disabled:t||T===e.id,onClick:()=>F(e),...K(`add-button`,t&&`add-button-sold-out`),style:{...Js,opacity:t?.5:1},children:t?y(`soldOut`):T===e.id?y(`adding`):a||y(`add`)})),D[e.id]&&(0,W.jsx)(`span`,{...K(`note`),style:{fontSize:`13px`,color:Y},children:D[e.id]})]},e.id)})})]})}function sc({slug:e=``,buttonLabel:t=``,showReviews:n=!0,showQuestions:r=!0,showSpecs:i=!0,style:a,nodeRef:o,inert:s=!1,sample:c=!1,noNavigate:u=!1}){let{tenant:d,apiUrl:f,locale:p,param:m,words:h}=Xs(),[g,_]=(0,l.useState)(null),[v,y]=(0,l.useState)(!1),[b,x]=(0,l.useState)(0),[S,C]=(0,l.useState)(``),[w,T]=(0,l.useState)(1),[E,D]=(0,l.useState)(!1),[O,k]=(0,l.useState)(``),{store:A,currency:j}=Zs(f,d,!s),M=e||m||Qs(`product`),N=j?`?currency=${encodeURIComponent(j)}`:``;if((0,l.useEffect)(()=>{let e=!0;return y(!1),(async()=>{let t=await os(f,d,`/store/config`),n=M?await os(f,d,`/store/products/${encodeURIComponent(M)}${N}`):c||u?(await os(f,d,`/store/products?limit=1${j?`&currency=${encodeURIComponent(j)}`:``}`))?.data?.[0]:null;if(e){if(!n){y(!0),_(c?ac[0]:null);return}_({...n,currency:us(t,j)}),C(e=>n.variants?.some(t=>t.id===e)?e:n.variants?.[0]?.id??``),x(0)}})().catch(()=>{e&&(y(!0),_(c?ac[0]:null))}),()=>{e=!1}},[f,d,M,j]),!g)return(0,W.jsx)(`div`,{ref:o,style:{...z(a)},children:v&&(0,W.jsx)(`p`,{...K(`empty`),style:{color:Y,margin:0},children:h(`noProducts`)})});let P=g.variants?.find(e=>e.id===S)??null,F=P?P.stock:g.variants?.length?null:g.stock,I=F===0,L=async()=>{if(!(s||g.sample)){D(!0),k(``);try{await A.add(g.id,P?.id??null,Math.max(1,Number(w)||1)),k(h(`added`))}catch(e){k(gs(h,e))}finally{D(!1)}}};return(0,W.jsxs)(`div`,{ref:o,style:{display:`flex`,flexDirection:`column`,gap:`48px`,...z(a)},children:[(0,W.jsxs)(`div`,{...K(`details`),style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 320px), 1fr))`,gap:`32px`},children:[(0,W.jsxs)(`div`,{...K(`gallery`),style:{display:`flex`,flexDirection:`column`,gap:`10px`},children:[(0,W.jsx)(`div`,{...K(`media`),style:{aspectRatio:`1 / 1`,borderRadius:`12px`,overflow:`hidden`,background:qs},children:g.images?.[b]&&(0,W.jsx)(`img`,{src:g.images[b],alt:g.name,...K(`image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),g.images?.length>1&&(0,W.jsx)(`div`,{...K(`thumbnails`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:g.images.map((e,t)=>(0,W.jsx)(`button`,{type:`button`,onClick:()=>x(t),...K(`thumbnail`,t===b&&`thumbnail-selected`),style:{width:`64px`,height:`64px`,padding:0,borderRadius:`8px`,overflow:`hidden`,cursor:`pointer`,border:t===b?`2px solid var(--page-accent, #111827)`:Ks,background:qs},children:(0,W.jsx)(`img`,{src:e,alt:``,...K(`thumbnail-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})},e))})]}),(0,W.jsxs)(`div`,{...K(`info`),style:{display:`flex`,flexDirection:`column`,gap:`16px`},children:[(0,W.jsx)(`h1`,{...K(`title`),style:{margin:0,fontSize:`var(--page-h2, 32px)`},children:g.name}),(0,W.jsx)(Is,{product:g,inert:s,sample:c&&!!g.sample}),(0,W.jsx)(ic,{product:g,variant:P,locale:p,size:22}),g.variants?.length>0&&(0,W.jsx)(`div`,{...K(`variants`),style:{display:`flex`,gap:`8px`,flexWrap:`wrap`},children:g.variants.map(e=>{let t=e.stock===0;return(0,W.jsx)(`button`,{type:`button`,disabled:t,onClick:()=>C(e.id),...K(`variant`,e.id===S&&`variant-selected`,t&&`variant-sold-out`),style:{...Ys,padding:`8px 14px`,opacity:t?.45:1,textDecoration:t?`line-through`:`none`,borderColor:e.id===S?`var(--page-accent, #111827)`:void 0,boxShadow:e.id===S?`inset 0 0 0 1px var(--page-accent, #111827)`:`none`},children:e.title},e.id)})}),(0,W.jsxs)(`div`,{...K(`buy-row`),style:{display:`flex`,gap:`10px`,alignItems:`center`},children:[(0,W.jsx)(`input`,{type:`number`,...K(`quantity-input`),min:1,"aria-label":h(`quantity`),value:w,onChange:e=>T(e.target.value),style:{...Li,width:`80px`}}),(0,W.jsx)(`button`,{type:`button`,disabled:I||E,onClick:L,...K(`add-button`,I&&`add-button-sold-out`),style:{...Js,flex:1,opacity:I?.5:1},children:I?h(`soldOut`):E?h(`adding`):t||h(`add`)})]}),F!==null&&F>0&&F<=5&&(0,W.jsx)(`span`,{...K(`stock-note`),style:{fontSize:`13px`,color:`var(--page-accent, #b45309)`},children:h(`onlyLeft`,{n:F})}),O&&(0,W.jsx)(`span`,{...K(`note`),style:{fontSize:`13px`,color:Y},children:O}),Array.isArray(g.description)&&g.description.length>0&&(0,W.jsx)(`div`,{...K(`description`),style:{lineHeight:1.6},children:Ar(g.description)})]})]}),i&&(0,W.jsx)(Gs,{specs:g.specs,locale:p,words:h}),n&&(0,W.jsx)(Rs,{product:g,inert:s,sample:c&&!!g.sample}),r&&(0,W.jsx)(Bs,{product:g,inert:s,sample:c&&!!g.sample})]})}function cc(e){return(0,W.jsx)(oc,{...e,source:`favorites`})}var lc=(0,W.jsxs)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,...K(`icon`),children:[(0,W.jsx)(`path`,{d:`M6 7h12l-1 13H7L6 7Z`}),(0,W.jsx)(`path`,{d:`M9 7a3 3 0 0 1 6 0`})]});function uc({href:e=`/cart`,label:t=``,showLabel:n=!1,style:r,nodeRef:i,inert:a=!1,sample:o=!1,noNavigate:s=!1}){let{tenant:c,apiUrl:l,words:u}=Xs(),{cart:d}=Zs(l,c,!a),f=o&&!d.count?2:d.count;return(0,W.jsxs)(`a`,{ref:i,href:e,onClick:s?e=>e.preventDefault():void 0,"aria-label":t||u(`cart`),style:{position:`relative`,display:`inline-flex`,alignItems:`center`,gap:`8px`,color:`inherit`,textDecoration:`none`,padding:`6px`,...z(r)},children:[lc,n&&(0,W.jsx)(`span`,{...K(`label`),children:t||u(`cart`)}),f>0&&(0,W.jsx)(`span`,{...K(`badge`),style:{position:`absolute`,top:`-4px`,left:`18px`,minWidth:`18px`,height:`18px`,padding:`0 5px`,borderRadius:`9px`,fontSize:`11px`,fontWeight:700,lineHeight:`18px`,textAlign:`center`,boxSizing:`border-box`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},children:f>99?`99+`:f})]})}function dc(e,t,n){if(t===`code`)return e;try{if(t===`name`)return`${new Intl.DisplayNames([n||`en`],{type:`currency`}).of(e)??e} (${e})`;let r=new Intl.NumberFormat(n||void 0,{style:`currency`,currency:e}).formatToParts(0).find(e=>e.type===`currency`)?.value;return r&&r!==e?`${r} ${e}`:e}catch{return e}}function fc({display:e=`symbol`,label:t=``,style:n,nodeRef:r,inert:i=!1}){let{tenant:a,apiUrl:o,locale:s}=Xs(),{store:c,currency:u}=Zs(o,a,!i),[d,f]=(0,l.useState)(null),p={display:`inline-flex`,alignItems:`center`,gap:8,...z(n)};(0,l.useEffect)(()=>{let e=!0;return os(o,a,`/store/config`).then(t=>e&&f(t)).catch(()=>e&&f({currencies:[]})),()=>{e=!1}},[o,a]);let m=Array.isArray(d?.currencies)?d.currencies:[];return m.length<2?i?(0,W.jsx)(`div`,{ref:r,style:{...p,padding:`8px 12px`,border:`1px dashed rgba(100, 116, 139, 0.45)`,borderRadius:6,color:`rgba(100, 116, 139, 0.8)`,fontSize:12},children:`Add currencies in Settings → Shop`}):null:(0,W.jsxs)(`div`,{ref:r,style:p,children:[t?(0,W.jsx)(`span`,{...K(`label`),style:{opacity:.7},children:t}):null,(0,W.jsx)(`select`,{"aria-label":t||`Currency`,...K(`select`),value:us(d,u),onChange:i?void 0:e=>c.setCurrency(e.target.value===d.currency?``:e.target.value),onKeyDown:i?e=>e.preventDefault():void 0,style:{font:`inherit`,color:`inherit`,background:`var(--page-surface, transparent)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:6,padding:`4px 8px`,cursor:i?`default`:`pointer`},children:m.map(t=>(0,W.jsx)(`option`,{value:t,children:dc(t,e,s)},t))})]})}var pc={display:`flex`,flexDirection:`column`,gap:`6px`,fontSize:`13px`},mc={margin:`0 0 12px`,fontSize:`18px`};function hc({label:e,required:t,children:n}){return(0,W.jsxs)(`label`,{...K(`field`),style:pc,children:[(0,W.jsxs)(`span`,{...K(`field-label`),style:{fontWeight:500},children:[e,t&&(0,W.jsx)(`span`,{...K(`required`),style:{color:`var(--page-accent, #dc2626)`},children:` *`})]}),n]})}var gc=[{id:`ship:standard`,type:`shipping`,name:`Standard`,amount:2990,min_days:2,max_days:4,detail:``},{id:`pickup:sample`,type:`pickup`,name:`Store pickup`,amount:0,min_days:null,max_days:null,detail:`Main Street 1`}],_c={name:``,email:``,phone:``,line1:``,line2:``,city:``,region:``,postal_code:``,country:``,note:``,gift:!1,recipient:``,gift_message:``};function vc({continueHref:e=`/`,style:t,nodeRef:n,inert:r=!1,sample:i=!1,noNavigate:a=!1}){let{tenant:o,apiUrl:s,locale:c,words:u,orderId:d}=Xs(),{store:f,cart:p,loaded:m}=Zs(s,o,!r),[h,g]=(0,l.useState)(null),[_,v]=(0,l.useState)(_c),[y,b]=(0,l.useState)(``),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(``),[T,E]=(0,l.useState)(null),[D,O]=(0,l.useState)(``),[k,A]=(0,l.useState)(!1),j=!r&&Qs(`cancelled`)===`1`,M=e=>ps(e,p.currency||h?.currency,c);(0,l.useEffect)(()=>{os(s,o,`/store/config`).then(e=>{g(e),b(t=>t||e?.methods?.[0]||``)}).catch(()=>g({enabled:!1,methods:[]}))},[s,o]),(0,l.useEffect)(()=>{let e=Qs(`order`);r||!e||j||os(s,o,`/store/orders/${encodeURIComponent(e)}`).then(e=>{E(e),e?.payment_status===`paid`&&f.reset()}).catch(e=>w(gs(u,e)))},[s,o]);let N=e=>t=>v(n=>({...n,[e]:t.target.value})),P=(0,l.useMemo)(()=>fs(c,h?.zone_countries??[],h&&!h.ships_elsewhere&&h.zone_countries?.length?h.zone_countries:null),[c,h]);(0,l.useEffect)(()=>{p.country&&!_.country&&v(e=>({...e,country:p.country}))},[p.country]);let F=async e=>{if(!r){A(!0),w(``);try{await f.setCoupon(e),O(``)}catch(e){w(gs(u,e))}finally{A(!1)}}},I=async e=>{if(e.preventDefault(),!r){if((R&&!ne?[`name`,`email`,`line1`,`city`,`country`]:[`name`,`email`]).some(e=>!_[e].trim())){w(u(`required`));return}S(!0),w(``);try{let e=new URL(window.location.href);[`order`,`paid`,`cancelled`].forEach(t=>e.searchParams.delete(t));let t=await os(s,o,`/store/checkout`,{method:`POST`,body:{cart_id:f.cartId(),method:y,customer:{name:_.name,email:_.email,phone:_.phone},address:{name:_.gift?_.recipient.trim():``,line1:_.line1,line2:_.line2,city:_.city,region:_.region,postal_code:_.postal_code,country:_.country},note:_.note,gift:_.gift,gift_message:_.gift?_.gift_message:``,delivery:p.delivery||``,return_url:e.toString()}});if(t?.redirect_url){window.location.assign(t.redirect_url);return}E(t?.order??null),f.reset()}catch(e){w(gs(u,e))}finally{S(!1)}}},L={...z(t)},R=r&&i&&!p.lines.length?!0:p.requires_shipping!==!1,ee=Array.isArray(p.discounts)?p.discounts:[],te=ee.filter(e=>e.type!==`shipping`),B=ee.find(e=>e.type===`shipping`)??null,V=r&&i&&!p.lines.length?gc:Array.isArray(p.delivery_options)?p.delivery_options:[],H=V.find(e=>e.id===p.delivery)??(r&&i?V[0]:null),ne=H?.type===`pickup`,re=e=>{r||e===p.delivery||(w(``),f.setDelivery(e).catch(e=>w(gs(u,e))))};if(T){let t=T.payment_status===`paid`;return(0,W.jsxs)(`div`,{ref:n,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...L},children:[(0,W.jsx)(`h2`,{...K(`thanks-title`),style:{margin:0},children:u(`thanks`,{number:d(T.number)})}),(0,W.jsx)(`p`,{...K(`thanks-message`),style:{margin:0},children:T.payment_method===`bank_transfer`?u(`transfer`):T.payment_method===`cash_on_delivery`?u(`cod`):u(t?`paid`:`awaiting`)}),Array.isArray(T.instructions_content)&&T.instructions_content.length>0?(0,W.jsx)(`div`,{...K(`instructions`),style:{padding:`12px`,borderRadius:`8px`,background:qs},children:Ar(T.instructions_content)}):T.instructions?(0,W.jsx)(`pre`,{...K(`instructions`),style:{margin:0,padding:`12px`,borderRadius:`8px`,background:qs,whiteSpace:`pre-wrap`,fontFamily:`inherit`},children:T.instructions}):null,T.delivery&&(0,W.jsxs)(`div`,{...K(`delivery-info`),style:{padding:`12px`,borderRadius:`8px`,background:qs},children:[(0,W.jsx)(`div`,{...K(`delivery-name`),style:{fontWeight:600},children:T.delivery.type===`pickup`?u(`pickupAt`,{name:T.delivery.name}):u(`deliveredBy`,{name:T.delivery.name})}),T.delivery.location&&(0,W.jsxs)(`div`,{...K(`delivery-detail`),style:{fontSize:`14px`,color:Y},children:[[T.delivery.location.line1,T.delivery.location.line2,[T.delivery.location.postal_code,T.delivery.location.city].filter(Boolean).join(` `)].filter(Boolean).join(`, `),T.delivery.location.instructions&&(0,W.jsx)(`div`,{children:T.delivery.location.instructions}),(0,W.jsx)(`div`,{children:u(`pickupNote`)})]}),!T.delivery.location&&bs(u,c,T.delivery.min_days,T.delivery.max_days)&&(0,W.jsx)(`div`,{...K(`delivery-detail`),style:{fontSize:`14px`,color:Y},children:bs(u,c,T.delivery.min_days,T.delivery.max_days)})]}),(0,W.jsxs)(`p`,{...K(`total`),style:{margin:0,fontWeight:700},children:[u(`total`),`: `,ps(T.total,T.currency,c)]}),!t&&(0,W.jsx)(Cc,{reference:T.transfer_reference,words:u}),(0,W.jsx)(wc,{downloads:T.downloads,apiUrl:s,words:u,locale:c,noNavigate:a}),(0,W.jsx)(`a`,{href:e,onClick:a?e=>e.preventDefault():void 0,...K(`continue-button`),style:{...Ys,alignSelf:`flex-start`},children:u(`continue`)})]})}let ie=r&&i&&!p.lines.length?ac.slice(0,2).map(e=>({...e,product_id:e.id,variant_id:null,quantity:1,unit_price:e.price,total:e.price,image:``,variant_title:``})):p.lines,ae=r&&i&&!p.lines.length?ie.reduce((e,t)=>e+t.total,0):p.subtotal;if(h&&!h.enabled&&!r)return(0,W.jsx)(`div`,{ref:n,style:L,children:(0,W.jsx)(`p`,{...K(`empty`),style:{color:Y},children:u(`closed`)})});if(m&&!ie.length&&!r)return(0,W.jsxs)(`div`,{ref:n,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...L},children:[j&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:Y},children:u(`cancelled`)}),(0,W.jsx)(`p`,{...K(`empty`),style:{margin:0},children:u(`emptyCart`)}),(0,W.jsx)(`a`,{href:e,onClick:a?e=>e.preventDefault():void 0,...K(`continue-button`),style:{...Ys,alignSelf:`flex-start`},children:u(`continue`)})]});let oe=h?.methods??[];return(0,W.jsxs)(`form`,{ref:n,onSubmit:I,style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 340px), 1fr))`,gap:`32px`,alignItems:`start`,...L},children:[(0,W.jsxs)(`div`,{...K(`form-column`),style:{display:`flex`,flexDirection:`column`,gap:`20px`},children:[j&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:Y},children:u(`cancelled`)}),(0,W.jsxs)(`section`,{...K(`section`),children:[(0,W.jsx)(`h3`,{...K(`heading`),style:mc,children:u(`contact`)}),(0,W.jsxs)(`div`,{...K(`fields`),style:{display:`grid`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`name`),required:!0,children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.name,onChange:N(`name`),autoComplete:`name`})}),(0,W.jsxs)(`div`,{...K(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`email`),required:!0,children:(0,W.jsx)(`input`,{type:`email`,...K(`input`),style:Li,value:_.email,onChange:N(`email`),autoComplete:`email`})}),(0,W.jsx)(hc,{label:u(`phone`),children:(0,W.jsx)(`input`,{type:`tel`,...K(`input`),style:Li,value:_.phone,onChange:N(`phone`),autoComplete:`tel`})})]})]})]}),R&&(0,W.jsxs)(`section`,{...K(`section`),children:[(0,W.jsx)(`h3`,{...K(`heading`),style:mc,children:u(`delivery`)}),(0,W.jsx)(`div`,{style:{marginBottom:`12px`},children:(0,W.jsxs)(`div`,{...K(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`postal`),children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.postal_code,onChange:N(`postal_code`),onBlur:()=>!r&&_.country&&f.setCountry(_.country,_.postal_code).catch(e=>w(gs(u,e))),autoComplete:`postal-code`})}),(0,W.jsx)(hc,{label:u(`country`),required:!ne,children:(0,W.jsxs)(`select`,{...K(`select`),style:Li,value:_.country,autoComplete:`country`,onChange:e=>{let t=e.target.value;v(e=>({...e,country:t})),r||f.setCountry(t,_.postal_code).catch(e=>w(gs(u,e)))},children:[(0,W.jsx)(`option`,{value:``,children:u(`chooseCountry`)}),P.map(e=>(0,W.jsx)(`option`,{value:e.code,children:e.name},e.code))]})})]})}),!V.length&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:Y,fontSize:`14px`},children:_.country?u(`noShipping`):u(`deliveryPick`)}),(0,W.jsx)(`div`,{...K(`delivery-options`),style:{display:`grid`,gap:`8px`},children:V.map(e=>{let t=bs(u,c,e.min_days,e.max_days);return(0,W.jsxs)(`label`,{...K(`delivery-option`,H?.id===e.id&&`delivery-option-selected`),style:{display:`flex`,alignItems:`flex-start`,gap:`10px`,padding:`12px`,borderRadius:`8px`,border:H?.id===e.id?`1px solid var(--page-accent, #4f46e5)`:Ks,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`radio`,...K(`radio`),name:`delivery`,value:e.id,checked:H?.id===e.id,onChange:()=>re(e.id),style:{marginTop:`3px`}}),(0,W.jsxs)(`span`,{...K(`option-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`span`,{...K(`option-name`),style:{display:`block`,fontWeight:600},children:e.name}),t&&(0,W.jsx)(`span`,{...K(`option-detail`),style:{display:`block`,fontSize:`13px`,color:Y},children:t}),e.detail&&(0,W.jsx)(`span`,{...K(`option-detail`),style:{display:`block`,fontSize:`13px`,color:Y},children:e.detail})]}),(0,W.jsx)(`span`,{...K(`option-price`),style:{fontWeight:600},children:e.amount?M(e.amount):u(`free`)})]},e.id)})})]}),R&&!ne&&(0,W.jsxs)(`section`,{...K(`section`),children:[(0,W.jsx)(`h3`,{...K(`heading`),style:mc,children:u(`address`)}),(0,W.jsxs)(`div`,{...K(`fields`),style:{display:`grid`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`line1`),required:!0,children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.line1,onChange:N(`line1`),autoComplete:`address-line1`})}),(0,W.jsx)(hc,{label:u(`line2`),children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.line2,onChange:N(`line2`),autoComplete:`address-line2`})}),(0,W.jsxs)(`div`,{...K(`field-row`),style:{display:`grid`,gridTemplateColumns:`1fr 1fr`,gap:`12px`},children:[(0,W.jsx)(hc,{label:u(`city`),required:!0,children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.city,onChange:N(`city`),autoComplete:`address-level2`})}),(0,W.jsx)(hc,{label:u(`region`),children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.region,onChange:N(`region`),autoComplete:`address-level1`})})]}),(0,W.jsx)(hc,{label:u(`note`),children:(0,W.jsx)(`textarea`,{rows:2,...K(`textarea`),style:{...Li,resize:`vertical`},value:_.note,onChange:N(`note`)})})]})]}),(0,W.jsxs)(`section`,{...K(`section`),children:[(0,W.jsxs)(`label`,{...K(`checkbox-row`),style:{display:`flex`,alignItems:`flex-start`,gap:`10px`,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`checkbox`,...K(`checkbox`),checked:_.gift,onChange:e=>v(t=>({...t,gift:e.target.checked})),style:{marginTop:`3px`}}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`span`,{...K(`checkbox-label`),style:{fontWeight:600},children:u(`gift`)}),(0,W.jsx)(`span`,{...K(`checkbox-hint`),style:{display:`block`,fontSize:`13px`,color:Y},children:u(`giftHint`)})]})]}),_.gift&&(0,W.jsxs)(`div`,{...K(`fields`),style:{marginTop:`12px`,display:`grid`,gap:`12px`},children:[R&&!ne&&(0,W.jsx)(hc,{label:u(`giftRecipient`),children:(0,W.jsx)(`input`,{...K(`input`),style:Li,value:_.recipient,onChange:N(`recipient`),maxLength:200,autoComplete:`off`})}),(0,W.jsx)(hc,{label:u(`giftMessage`),children:(0,W.jsx)(`textarea`,{rows:3,maxLength:500,...K(`textarea`),style:{...Li,resize:`vertical`},value:_.gift_message,onChange:N(`gift_message`)})})]})]}),(0,W.jsxs)(`section`,{...K(`section`),children:[(0,W.jsx)(`h3`,{...K(`heading`),style:mc,children:u(`payment`)}),!oe.length&&!r&&(0,W.jsx)(`p`,{...K(`note`),style:{margin:0,color:Y},children:u(`noMethods`)}),(0,W.jsx)(`div`,{...K(`payment-options`),style:{display:`grid`,gap:`8px`},children:(r&&!oe.length?[`stripe`,`bank_transfer`]:oe).map(e=>(0,W.jsxs)(`label`,{...K(`payment-option`,y===e&&`payment-option-selected`),style:{display:`flex`,alignItems:`center`,gap:`10px`,padding:`12px`,borderRadius:`8px`,border:Ks,cursor:`pointer`},children:[(0,W.jsx)(`input`,{type:`radio`,...K(`radio`),name:`method`,value:e,checked:y===e,onChange:()=>b(e)}),(0,W.jsx)(`span`,{...K(`payment-name`),children:h?.method_names?.[e]??u(e)})]},e))})]})]}),(0,W.jsxs)(`aside`,{...K(`summary`),style:{display:`flex`,flexDirection:`column`,gap:`14px`,padding:`20px`,borderRadius:`12px`,background:qs},children:[(0,W.jsx)(`h3`,{...K(`summary-title`),style:{...mc,margin:0},children:u(`cart`)}),ie.map(e=>(0,W.jsxs)(`div`,{...K(`line`),style:{display:`flex`,gap:`12px`,alignItems:`center`},children:[(0,W.jsx)(`div`,{...K(`line-media`),style:{width:`52px`,height:`52px`,borderRadius:`8px`,overflow:`hidden`,background:`var(--page-bg, #fff)`,flexShrink:0},children:e.image&&(0,W.jsx)(`img`,{src:e.image,alt:``,...K(`line-image`),style:{width:`100%`,height:`100%`,objectFit:`cover`,display:`block`}})}),(0,W.jsxs)(`div`,{...K(`line-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{...K(`line-name`),style:{fontWeight:600},children:e.name}),e.variant_title&&(0,W.jsx)(`div`,{...K(`line-variant`),style:{fontSize:`13px`,color:Y},children:e.variant_title}),(0,W.jsxs)(`div`,{...K(`line-controls`),style:{display:`flex`,alignItems:`center`,gap:`8px`,marginTop:`4px`},children:[(0,W.jsx)($s,{value:e.quantity,label:u(`quantity`),onCommit:t=>!r&&f.setLine(e.product_id,e.variant_id,t).catch(e=>w(gs(u,e)))}),(0,W.jsx)(`button`,{type:`button`,onClick:()=>!r&&f.setLine(e.product_id,e.variant_id,0).catch(e=>w(gs(u,e))),...K(`remove-button`),style:{background:`none`,border:0,padding:0,color:Y,cursor:`pointer`,fontSize:`13px`,textDecoration:`underline`,fontFamily:`inherit`},children:u(`remove`)})]})]}),(0,W.jsxs)(`div`,{...K(`line-price`),style:{textAlign:`right`},children:[e.discount>0&&(0,W.jsx)(`div`,{...K(`line-price-old`),style:{fontSize:`12px`,color:Y,textDecoration:`line-through`},children:M(e.total)}),(0,W.jsx)(`div`,{...K(`line-total`),style:{fontWeight:600},children:M(e.total-(e.discount||0))})]})]},`${e.product_id}:${e.variant_id??``}`)),p.coupon?(0,W.jsxs)(`div`,{...K(`coupon`),style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:`8px`,fontSize:`14px`},children:[(0,W.jsx)(`span`,{...K(`coupon-code`),style:{padding:`4px 10px`,borderRadius:`999px`,border:Ks,fontWeight:600,letterSpacing:`0.04em`},children:p.coupon.code}),(0,W.jsx)(`button`,{type:`button`,disabled:k,onClick:()=>F(``),...K(`coupon-remove`),style:{background:`none`,border:0,padding:0,color:Y,cursor:`pointer`,fontSize:`13px`,textDecoration:`underline`,fontFamily:`inherit`},children:u(`removeCoupon`)})]}):(0,W.jsxs)(`div`,{...K(`coupon-form`),style:{display:`flex`,gap:`8px`},children:[(0,W.jsx)(`input`,{"aria-label":u(`coupon`),...K(`coupon-input`),placeholder:u(`coupon`),value:D,onChange:e=>O(e.target.value.toUpperCase()),onKeyDown:e=>{e.key===`Enter`&&(e.preventDefault(),D.trim()&&F(D.trim()))},style:{...Li,flex:1,letterSpacing:`0.04em`}}),(0,W.jsx)(`button`,{type:`button`,disabled:k||!D.trim(),onClick:()=>F(D.trim()),...K(`coupon-button`),style:{...Ys,padding:`8px 14px`},children:u(`apply`)})]}),p.coupon_error&&(0,W.jsx)(`span`,{...K(`coupon-error`),style:{fontSize:`13px`,color:Y},children:p.coupon_error_code&&u.has(p.coupon_error_code)?u(p.coupon_error_code):p.coupon_error}),(0,W.jsxs)(`div`,{...K(`totals`),style:{borderTop:Ks,paddingTop:`12px`,display:`grid`,gap:`6px`,fontSize:`14px`},children:[(0,W.jsxs)(`div`,{...K(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsx)(`span`,{children:u(`subtotal`)}),(0,W.jsx)(`span`,{children:M(ae)})]}),te.length?te.map(e=>(0,W.jsxs)(`div`,{...K(`summary-row`),style:{display:`flex`,justifyContent:`space-between`,gap:`8px`},children:[(0,W.jsxs)(`span`,{children:[u(`discount`),` · `,e.title]}),(0,W.jsxs)(`span`,{children:[`−`,M(e.amount)]})]},e.id)):p.discount_total>0&&(0,W.jsxs)(`div`,{...K(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsx)(`span`,{children:u(`discount`)}),(0,W.jsxs)(`span`,{children:[`−`,M(p.discount_total)]})]}),R&&(0,W.jsxs)(`div`,{...K(`summary-row`),style:{display:`flex`,justifyContent:`space-between`,gap:`8px`},children:[(0,W.jsxs)(`span`,{children:[H?.name??u(`shipping`),B?` · ${B.title}`:``]}),(0,W.jsxs)(`span`,{children:[B&&(0,W.jsx)(`span`,{...K(`shipping-old`),style:{color:Y,textDecoration:`line-through`,marginRight:`6px`},children:M(p.shipping_before)}),(B?p.shipping_total:H?.amount??p.shipping_total)?M(B?p.shipping_total:H?.amount??p.shipping_total):u(`free`)]})]}),!p.tax_included&&p.tax_total>0&&(0,W.jsxs)(`div`,{...K(`summary-row`),style:{display:`flex`,justifyContent:`space-between`},children:[(0,W.jsxs)(`span`,{children:[u(`tax`),` (`,p.tax_rate,`%)`]}),(0,W.jsx)(`span`,{children:M(p.tax_total)})]}),(0,W.jsxs)(`div`,{...K(`summary-row`,`summary-row-total`),style:{display:`flex`,justifyContent:`space-between`,fontWeight:700,fontSize:`16px`},children:[(0,W.jsx)(`span`,{children:u(`total`)}),(0,W.jsx)(`span`,{children:M(r&&i&&!p.lines.length?ae:p.total)})]}),p.tax_included&&p.tax_total>0&&(0,W.jsxs)(`div`,{...K(`summary-row`,`summary-row-muted`),style:{display:`flex`,justifyContent:`space-between`,fontSize:`12px`,color:Y},children:[(0,W.jsxs)(`span`,{children:[u(`taxIncluded`),` (`,p.tax_rate,`%)`]}),(0,W.jsx)(`span`,{children:M(p.tax_total)})]})]}),p.shipping_available===!1&&(0,W.jsx)(`p`,{...K(`error`),style:{margin:0,color:`#dc2626`,fontSize:`13px`},children:u(`noShipping`)}),C&&(0,W.jsx)(`p`,{...K(`error`),style:{margin:0,color:`#dc2626`,fontSize:`13px`},children:C}),(0,W.jsx)(`button`,{type:`submit`,...K(`submit-button`),disabled:x||!y||p.shipping_available===!1,style:{...Js,width:`100%`,padding:`12px`},children:u(x?`placing`:`placeOrder`)}),(0,W.jsx)(bc,{apiUrl:s,tenant:o,words:u,locale:c,sample:i,inert:r})]})]})}var yc=[`refund`,`privacy`,`terms`,`shipping`].map(e=>({kind:e,content:[],fields:{},updated_at:null}));function bc({apiUrl:e,tenant:t,words:n,locale:r,sample:i,inert:a}){let[o,s]=(0,l.useState)(i?yc:[]),[c,u]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(i)return;let n=!0;return vs(e,t).then(e=>n&&s(e)),()=>{n=!1}},[e,t,i]),!o.length)return null;let d=o.find(e=>e.kind===`terms`),f=e=>t=>{t.preventDefault(),a||u(e)},p=e=>(0,W.jsx)(`a`,{href:`#policy-${e.kind}`,onClick:f(e),...K(`policy-link`),style:{color:Y,textDecoration:`underline`},children:n(`policy_${e.kind}`)},e.kind);return(0,W.jsxs)(`div`,{...K(`policies`),style:{display:`grid`,gap:`8px`,fontSize:`12px`,color:Y},children:[d&&(0,W.jsxs)(`span`,{...K(`policy-agree`),children:[n(`policy_agree`).split(`{terms}`)[0],p(d),n(`policy_agree`).split(`{terms}`)[1]]}),(0,W.jsx)(`div`,{...K(`policy-links`),style:{display:`flex`,flexWrap:`wrap`,gap:`6px 14px`,borderTop:Ks,paddingTop:`10px`},children:o.map(p)}),c&&(0,W.jsx)(xc,{policy:c,words:n,locale:r,onClose:()=>u(null)})]})}function xc({policy:e,words:t,locale:n,onClose:r}){(0,l.useEffect)(()=>{let e=e=>{e.key===`Escape`&&r()};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[r]);let i=e.fields??{},a=[i.line1,i.line2,[i.postal_code,i.city].filter(Boolean).join(` `),[i.region,i.country].filter(Boolean).join(`, `)].filter(Boolean),o=``;try{o=e.updated_at?new Date(e.updated_at).toLocaleDateString(n||void 0,{dateStyle:`long`}):``}catch{o=``}return(0,W.jsx)(`div`,{role:`dialog`,"aria-modal":`true`,"aria-label":t(`policy_${e.kind}`),onMouseDown:e=>e.target===e.currentTarget&&r(),...K(`modal`),style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(15, 23, 42, .55)`,display:`grid`,placeItems:`center`,padding:`16px`},children:(0,W.jsxs)(`div`,{...K(`modal-panel`),style:{background:`var(--page-bg, #fff)`,color:`var(--page-text, #111827)`,border:Ks,borderRadius:`12px`,width:`min(720px, 100%)`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,textAlign:`left`},children:[(0,W.jsxs)(`div`,{...K(`modal-header`),style:{display:`flex`,alignItems:`center`,gap:`12px`,padding:`16px 20px`,borderBottom:Ks},children:[(0,W.jsx)(`strong`,{...K(`modal-title`),style:{flex:1,fontSize:`17px`},children:t(`policy_${e.kind}`)}),(0,W.jsx)(`button`,{type:`button`,onClick:r,"aria-label":t(`close`),...K(`modal-close`),style:{...Ys,padding:`4px 10px`},children:`×`})]}),(0,W.jsxs)(`div`,{...K(`modal-body`),style:{padding:`8px 20px 20px`,overflowY:`auto`,fontSize:`14px`,lineHeight:1.6},children:[e.kind===`contact`?(0,W.jsxs)(`div`,{style:{display:`grid`,gap:`10px`,paddingTop:`10px`},children:[i.business_name&&(0,W.jsx)(`strong`,{children:i.business_name}),a.length>0&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_address`),`: `]}),a.join(`, `)]}),i.email&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_email`),`: `]}),(0,W.jsx)(`a`,{href:`mailto:${i.email}`,children:i.email})]}),i.phone&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_phone`),`: `]}),i.phone]}),i.trade_number&&(0,W.jsxs)(`div`,{children:[(0,W.jsxs)(`span`,{style:{color:Y},children:[t(`contact_trade`),`: `]}),i.trade_number]})]}):Ar(e.content),o&&(0,W.jsx)(`p`,{...K(`modal-updated`),style:{color:Y,fontSize:`12px`,marginTop:`16px`},children:t(`policy_updated`,{date:o})})]})]})})}var Sc={year:`numeric`,month:`short`,day:`numeric`};function Cc({reference:e,words:t}){let[n,r]=(0,l.useState)(!1);if(!e)return null;let i=()=>{try{navigator.clipboard?.writeText(e).then(()=>{r(!0),setTimeout(()=>r(!1),1500)},()=>{})}catch{}};return(0,W.jsxs)(`div`,{...K(`reference`),style:{display:`grid`,gap:`4px`},children:[(0,W.jsx)(`span`,{...K(`reference-label`),style:{fontSize:`13px`,color:Y},children:t(`reference`)}),(0,W.jsxs)(`div`,{...K(`reference-row`),style:{display:`flex`,alignItems:`center`,gap:`8px`,flexWrap:`wrap`},children:[(0,W.jsx)(`code`,{...K(`reference-code`),style:{padding:`8px 12px`,border:`2px dashed var(--page-border, #d1d5db)`,borderRadius:`8px`,font:`700 20px/1.2 ui-monospace, Menlo, Consolas, monospace`,letterSpacing:`2px`},children:e}),(0,W.jsx)(`button`,{type:`button`,onClick:i,...K(`copy-button`),style:{...Ys,padding:`6px 12px`},children:t(n?`copied`:`copy`)})]}),(0,W.jsx)(`span`,{...K(`reference-note`),style:{fontSize:`13px`,color:Y},children:t(`referenceNote`)})]})}function wc({downloads:e,apiUrl:t,words:n,locale:r,noNavigate:i}){let a=Array.isArray(e)?e.filter(e=>e&&e.token&&!e.revoked_at):[];if(!a.length)return null;let o=e=>{try{return new Date(e).toLocaleDateString(r||void 0,{dateStyle:`medium`})}catch{return``}};return(0,W.jsxs)(`div`,{...K(`downloads`),style:{display:`grid`,gap:`8px`,paddingTop:`8px`},children:[(0,W.jsx)(`strong`,{...K(`downloads-title`),style:{fontSize:`14px`},children:n(`downloads_title`)}),a.map(e=>{let r=typeof e.download_limit==`number`?Math.max(0,e.download_limit-(e.downloads??0)):null,a=e.expires_at&&new Date(e.expires_at).getTime()<=Date.now(),s=!a&&(r===null||r>0),c=[r!==null&&n(`download_left`,{count:r}),e.expires_at&&n(a?`download_expired`:`download_until`,{date:o(e.expires_at)})].filter(Boolean);return(0,W.jsxs)(`div`,{...K(`download`),style:{display:`flex`,alignItems:`center`,gap:`12px`,padding:`10px 12px`,border:Ks,borderRadius:`8px`},children:[(0,W.jsxs)(`div`,{...K(`download-info`),style:{flex:1,minWidth:0},children:[(0,W.jsx)(`div`,{...K(`download-name`),style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:e.filename}),c.length>0&&(0,W.jsx)(`div`,{...K(`download-note`),style:{fontSize:`12px`,color:Y},children:c.join(` · `)})]}),s?(0,W.jsx)(`a`,{href:`${t}/store/downloads/${encodeURIComponent(e.token)}`,onClick:i?e=>e.preventDefault():void 0,...K(`download-button`),style:{...Js,padding:`6px 14px`,textDecoration:`none`,fontSize:`14px`},children:n(`download`)}):(0,W.jsx)(`span`,{...K(`download-unavailable`),style:{fontSize:`13px`,color:Y},children:n(`download_unavailable`)})]},e.token)})]})}function Tc({tracking:e,words:t,noNavigate:n}){let r=typeof e?.carrier==`string`?e.carrier:``,i=typeof e?.number==`string`?e.number:``,a=typeof e?.url==`string`&&/^https?:\/\//i.test(e.url)?e.url:``;return!r&&!i&&!a?null:(0,W.jsxs)(`div`,{...K(`tracking`),style:{marginTop:`4px`,paddingTop:`8px`,borderTop:`1px solid var(--page-border, rgba(0,0,0,.1))`,display:`flex`,gap:`10px`,flexWrap:`wrap`,alignItems:`baseline`},children:[(0,W.jsx)(`span`,{...K(`tracking-label`),style:{color:Y},children:t(`tracking`)}),(0,W.jsx)(`span`,{...K(`tracking-number`),children:[r,i].filter(Boolean).join(` · `)}),a&&(0,W.jsx)(`a`,{href:a,target:`_blank`,rel:`noopener noreferrer`,onClick:n?e=>e.preventDefault():void 0,...K(`tracking-link`),style:{color:`var(--page-accent, #4f46e5)`},children:t(`track_parcel`)})]})}function Ec({loginHref:e=`/login`,limit:t=20,style:n,nodeRef:r,inert:i=!1,sample:a=!1,noNavigate:o=!1}){let{tenant:s,apiUrl:c,locale:u,words:d,orderId:f}=Xs(),[p,m]=(0,l.useState)(null),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(``);(0,l.useEffect)(()=>{if(i)return;let e=!0;return os(c,s,`/store/my/orders?limit=${Math.max(1,Math.min(100,Number(t)||20))}`).then(t=>e&&m(Array.isArray(t?.data)?t.data:[])).catch(t=>{e&&(g(t?.code===`LOGIN_REQUIRED`),m([]))}),()=>{e=!1}},[c,s,t,i]);let y=i&&a?[{id:`s1`,number:1042,status:`shipped`,payment_status:`paid`,currency:`USD`,total:8490,created_at:new Date().toISOString(),items:[]},{id:`s2`,number:1041,status:`delivered`,payment_status:`paid`,currency:`USD`,total:2990,created_at:new Date(Date.now()-864e6).toISOString(),items:[]}]:p??[],b=e=>{try{return new Intl.DateTimeFormat(u||void 0,Sc).format(new Date(e))}catch{return String(e).slice(0,10)}};return(0,W.jsxs)(`div`,{ref:r,style:{display:`flex`,flexDirection:`column`,gap:`12px`,...z(n)},children:[(0,W.jsx)(`h2`,{...K(`title`),style:{margin:0,fontSize:`22px`},children:d(`myOrders`)}),h&&(0,W.jsx)(`p`,{style:{margin:0},children:(0,W.jsx)(`a`,{href:e,onClick:o?e=>e.preventDefault():void 0,...K(`signin-link`),style:{color:`var(--page-accent, #111827)`},children:d(`signInForOrders`)})}),!h&&(p!==null||i)&&!y.length&&(0,W.jsx)(`p`,{...K(`empty`),style:{margin:0,color:Y},children:d(`noOrders`)}),y.map(e=>(0,W.jsxs)(`div`,{...K(`order`,_===e.id&&`order-open`),style:{border:Ks,borderRadius:`10px`,overflow:`hidden`},children:[(0,W.jsxs)(`button`,{type:`button`,onClick:()=>v(t=>t===e.id?``:e.id),...K(`order-header`),style:{width:`100%`,display:`grid`,gridTemplateColumns:`1fr auto auto`,gap:`12px`,alignItems:`center`,padding:`12px 14px`,background:`transparent`,border:0,color:`inherit`,font:`inherit`,textAlign:`left`,cursor:`pointer`},children:[(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`strong`,{...K(`order-number`),children:f(e.number)}),(0,W.jsx)(`span`,{...K(`order-date`),style:{color:Y,marginLeft:`8px`,fontSize:`13px`},children:b(e.created_at)})]}),(0,W.jsxs)(`span`,{...K(`status`),style:{fontSize:`13px`,padding:`2px 10px`,borderRadius:`999px`,background:qs},children:[d(`st_${e.status}`),e.payment_status===`paid`?``:` · ${d(`pay_${e.payment_status}`)}`]}),(0,W.jsx)(`strong`,{...K(`order-total`),children:ps(e.total,e.currency,u)})]}),_===e.id&&e.items?.length>0&&(0,W.jsxs)(`div`,{...K(`order-items`),style:{padding:`0 14px 12px`,display:`grid`,gap:`6px`,fontSize:`14px`},children:[e.items.map(t=>(0,W.jsxs)(`div`,{...K(`order-item`),style:{display:`flex`,justifyContent:`space-between`,gap:`12px`},children:[(0,W.jsxs)(`span`,{children:[t.quantity,` × `,t.name,t.variant_title&&(0,W.jsxs)(`span`,{...K(`order-item-variant`),style:{color:Y},children:[` — `,t.variant_title]})]}),(0,W.jsx)(`span`,{...K(`order-item-price`),children:ps(t.total,e.currency,u)})]},t.id)),e.payment_status===`unpaid`&&e.status!==`cancelled`&&(0,W.jsx)(Cc,{reference:e.transfer_reference,words:d}),(0,W.jsx)(Tc,{tracking:e.tracking,words:d,noNavigate:o}),(0,W.jsx)(wc,{downloads:e.downloads,apiUrl:c,words:d,locale:u,noNavigate:o})]})]},e.id))]})}function Dc(e){let t=e?.locales,n=[typeof t?.default==`string`&&t.default.trim()?t.default.trim():``,...Array.isArray(t?.enabled)?t.enabled:[]].filter(e=>typeof e==`string`&&e.trim());return[...new Set(n.map(e=>e.trim()))]}var Oc=e=>e&&e.charAt(0).toUpperCase()+e.slice(1);function kc(e,t){let n=String(e??``).toUpperCase();if(t===`code`)return n;let r=``;try{r=Oc(new Intl.DisplayNames([e],{type:`language`}).of(e)??``)}catch{}return!r||r.toUpperCase()===n?n:t===`both`?`${n} — ${r}`:r}function Ac(e,t){let n=t?``:`?locale=${encodeURIComponent(e)}`;if(typeof window>`u`)return n||`?`;try{let n=new URL(window.location.href);return t?n.searchParams.delete(`locale`):n.searchParams.set(`locale`,e),n.searchParams.delete(`page`),`${n.pathname}${n.search}${n.hash}`}catch{return n||`/`}}function jc({variant:e,display:t,separator:n,label:r,style:i,nodeRef:a,inert:o}){let s=(0,l.useContext)(G),c=Dc(s?.settings),u=c[0]??``,d=c.includes(s?.locale)?s.locale:u,f={display:`inline-flex`,alignItems:`center`,gap:8,...z(i)};if(c.length<2)return o?(0,W.jsx)(`div`,{ref:a,style:{...f,padding:`8px 12px`,border:`1px dashed rgba(100, 116, 139, 0.45)`,borderRadius:6,color:`rgba(100, 116, 139, 0.8)`,fontSize:12},children:`Add site languages in Settings → Languages`}):null;let p=r?(0,W.jsx)(`span`,{...K(`label`),style:{opacity:.7},children:r}):null;return e===`inline`?(0,W.jsxs)(`div`,{ref:a,style:f,children:[p,c.map((e,r)=>(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:8},children:[r>0&&(0,W.jsx)(`span`,{...K(`separator`),style:{opacity:.4},children:n??`·`}),(0,W.jsx)(`a`,{...K(`link`,e===d&&`link-current`),href:Ac(e,e===u),hrefLang:e,"aria-current":e===d?`true`:void 0,onClick:o?e=>e.preventDefault():void 0,style:{color:e===d?`var(--page-accent, inherit)`:`inherit`,fontWeight:e===d?600:400,textDecoration:`none`,cursor:o?`default`:`pointer`},children:kc(e,t)})]},e))]}):(0,W.jsxs)(`div`,{ref:a,style:f,children:[p,(0,W.jsx)(`select`,{...K(`select`),"aria-label":r||`Language`,value:d,onChange:o?void 0:e=>{let t=e.target.value;window.location.assign(Ac(t,t===u))},onKeyDown:o?e=>e.preventDefault():void 0,style:{font:`inherit`,color:`inherit`,background:`var(--page-surface, transparent)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:6,padding:`4px 8px`,cursor:o?`default`:`pointer`},children:c.map(e=>(0,l.createElement)(`option`,{...K(`option`,e===d&&`option-current`),key:e,value:e},kc(e,t)))})]})}var Mc=[Oo,qo,Bo,Jo,es],Nc={SiteLoginForm:Ro,SiteAccountMenu:zo,SiteLanguagePicker:jc,CookieConsent:Ko,SiteSearch:$o,ShopProductGrid:oc,ShopProduct:sc,ShopCartButton:uc,ShopCheckout:vc,ShopOrderHistory:Ec,ShopCurrencyPicker:fc,ShopFavorites:cc};new Set(Mc.filter(e=>e.ssr===`shell`).flatMap(e=>e.keys));var Pc=`0.185.1`,Fc=`4.2.0`,Ic=`https://cdn.jsdelivr.net/npm`,Lc=`${Ic}/three@${Pc}/+esm`,Rc=`${Ic}/@google/model-viewer@${Fc}/dist/model-viewer.min.js`,zc=e=>import(e),Bc=new Map;function Vc(e){if(Bc.has(e))return Bc.get(e);if(typeof window>`u`)return new Promise(()=>{});let t=zc(e).catch(t=>{throw Bc.delete(e),t});return Bc.set(e,t),t}var Hc=()=>Vc(Lc),Uc=e=>Vc(`${Ic}/three@${Pc}/examples/jsm/${e}/+esm`);function Wc(){return typeof window<`u`&&window.customElements?.get(`model-viewer`)?Promise.resolve(null):Vc(Rc)}var Gc=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,Kc=(e=2)=>Math.min(typeof window>`u`?1:window.devicePixelRatio||1,e);function qc(e,t){let n=0,r=0,i=0,a=!0,o=e=>{n=requestAnimationFrame(o),i||=e;let a=r?(e-r)/1e3:0;r=e,t(a,(e-i)/1e3)},s=()=>{n&&cancelAnimationFrame(n),n=0,r=0},c=()=>{let e=a&&document.visibilityState!==`hidden`;e&&!n?n=requestAnimationFrame(o):!e&&n&&s()};t(0,0);let l=typeof IntersectionObserver>`u`?null:new IntersectionObserver(e=>{a=e.some(e=>e.isIntersecting),c()},{rootMargin:`120px`});return l&&e&&l.observe(e),document.addEventListener(`visibilitychange`,c),c(),()=>{s(),l?.disconnect(),document.removeEventListener(`visibilitychange`,c)}}function Jc(e,t,n={}){let r={radius:n.distance??4,polar:n.polar??Math.PI/2.4,azimuth:n.azimuth??.6,target:n.target??{x:0,y:0,z:0}},i={...r},a=n.minDistance??.4,o=n.maxDistance??200,s=n.damping??.12,c=.05,l=null,u=e=>{e.button!==void 0&&e.button!==0||(l={x:e.clientX,y:e.clientY,id:e.pointerId},t.setPointerCapture?.(e.pointerId))},d=e=>{if(!l||e.pointerId!==l.id)return;let t=e.clientX-l.x,n=e.clientY-l.y;l={...l,x:e.clientX,y:e.clientY},i.azimuth-=t*.006,i.polar=Math.max(c,Math.min(Math.PI-c,i.polar-n*.006)),e.preventDefault()},f=e=>{l&&e.pointerId===l.id&&t.releasePointerCapture?.(e.pointerId),l=null},p=e=>{n.enableZoom!==!1&&(e.preventDefault(),i.radius=Math.max(a,Math.min(o,i.radius*(1+Math.sign(e.deltaY)*.12))))};return t.addEventListener(`pointerdown`,u),t.addEventListener(`pointermove`,d),t.addEventListener(`pointerup`,f),t.addEventListener(`pointercancel`,f),t.addEventListener(`wheel`,p,{passive:!1}),{update:()=>{r.radius+=(i.radius-r.radius)*s,r.polar+=(i.polar-r.polar)*s,r.azimuth+=(i.azimuth-r.azimuth)*s;let t=Math.sin(r.polar);e.position.set(r.target.x+r.radius*t*Math.sin(r.azimuth),r.target.y+r.radius*Math.cos(r.polar),r.target.z+r.radius*t*Math.cos(r.azimuth)),e.lookAt(r.target.x,r.target.y,r.target.z)},dragging:()=>!!l,autoSpin:(e,t)=>{!l&&e&&(i.azimuth+=e*t)},frame:(e,t)=>{i.radius=Math.max(a,Math.min(o,e)),r.radius=i.radius,t&&(r.target={...t},i.target={...t})},dispose:()=>{t.removeEventListener(`pointerdown`,u),t.removeEventListener(`pointermove`,d),t.removeEventListener(`pointerup`,f),t.removeEventListener(`pointercancel`,f),t.removeEventListener(`wheel`,p)}}}var Yc=(e,t)=>Number.isFinite(Number(e))&&Number(e)>0?Number(e):t,Xc=(e,t)=>(Number.isFinite(Number(e))?Number(e):t)/100,Zc=e=>(Number.isFinite(Number(e))?Number(e):0)*Math.PI/180,Qc=e=>typeof e==`string`&&!!e.trim();function $c({label:e,note:t,height:n,nodeRef:r,style:i}){return(0,W.jsxs)(`div`,{ref:r,style:{...z(i),minHeight:Yc(n,320),display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,gap:6,border:`1px dashed rgba(148,163,184,.55)`,borderRadius:10,background:`rgba(148,163,184,.08)`,...U,color:`rgba(100,116,139,.95)`,fontSize:13,textAlign:`center`,padding:16},children:[(0,W.jsx)(`div`,{style:{fontWeight:600},children:e}),t?(0,W.jsx)(`div`,{style:{fontSize:11,opacity:.8,maxWidth:320},children:t}):null]})}function el({src:e,poster:t,alt:n,height:r,bg:i,autoRotate:a,rotateDelay:o,cameraControls:s,ar:c,exposure:u,shadow:d,fieldOfView:f,environment:p,style:m,nodeRef:h,inert:g}){let[_,v]=(0,l.useState)(typeof window<`u`&&!!window.customElements?.get(`model-viewer`)),[y,b]=(0,l.useState)(!1);(0,l.useEffect)(()=>{if(_||!e)return;let t=!0;return Wc().then(()=>t&&v(!0),()=>t&&b(!0)),()=>{t=!1}},[_,e]);let x={display:`block`,width:`100%`,minHeight:Yc(r,360),height:Yc(r,360),backgroundColor:i||`transparent`,...z(m)};if(!e)return g?(0,W.jsx)($c,{nodeRef:h,style:m,height:r,label:`3D Model`,note:`Pick a .glb or .gltf file in the Settings panel.`}):(0,W.jsx)(`div`,{ref:h,style:x});if(y)return(0,W.jsx)(`div`,{ref:h,style:{...x,display:`flex`,alignItems:`center`,justifyContent:`center`},children:t?(0,W.jsx)(`img`,{src:t,alt:n||``,style:{maxWidth:`100%`,maxHeight:`100%`}}):null});let S=e=>e?``:void 0,C=a!==!1;return(0,W.jsx)(`model-viewer`,{ref:h,src:e,alt:n||`A 3D model`,poster:t||void 0,style:x,"camera-controls":S(!g&&s!==!1),"auto-rotate":S(C&&!Gc()),"auto-rotate-delay":C?String(Yc(o,0)):void 0,"rotation-per-second":`18deg`,ar:S(!g&&c===!0),"ar-modes":`webxr scene-viewer quick-look`,"shadow-intensity":String(Xc(d,100)),exposure:String(Xc(u,100)),"field-of-view":f?`${Number(f)}deg`:void 0,"environment-image":p&&p!==`neutral`?p:`neutral`,"interaction-prompt":g?`none`:void 0,loading:`lazy`,"touch-action":`pan-y`,children:t?(0,W.jsx)(`img`,{slot:`poster`,src:t,alt:n||``,style:{width:`100%`,height:`100%`,objectFit:`contain`}}):null})}var tl=[`attribute vec2 p;`,`void main() { gl_Position = vec4(p, 0.0, 1.0); }`].join(`
105
105
  `),nl=[`precision highp float;`,`uniform vec2 u_res;`,`uniform float u_time;`,`uniform vec2 u_mouse;`,`uniform vec3 u_a;`,`uniform vec3 u_b;`,`uniform vec3 u_c;`,`uniform float u_scale;`,``,`float hash(vec2 p){ return fract(sin(dot(p, vec2(127.1, 311.7))) * 43758.5453123); }`,`float noise(vec2 p){`,` vec2 i = floor(p); vec2 f = fract(p);`,` vec2 u = f * f * (3.0 - 2.0 * f);`,` return mix(mix(hash(i), hash(i + vec2(1.0, 0.0)), u.x),`,` mix(hash(i + vec2(0.0, 1.0)), hash(i + vec2(1.0, 1.0)), u.x), u.y);`,`}`,`float fbm(vec2 p){`,` float v = 0.0; float a = 0.5;`,` for (int i = 0; i < 5; i++) { v += a * noise(p); p *= 2.02; a *= 0.5; }`,` return v;`,`}`,``].join(`
106
106
  `),rl={gradient:[`void main(){`,` vec2 uv = gl_FragCoord.xy / u_res;`,` vec2 sp = (gl_FragCoord.xy - 0.5 * u_res) / min(u_res.x, u_res.y);`,` float t = u_time * 0.25;`,` float d1 = length(sp - vec2(sin(t) * 0.4, cos(t * 0.8) * 0.3) - u_mouse * 0.25);`,` float d2 = length(sp + vec2(cos(t * 1.1) * 0.45, sin(t * 0.7) * 0.35));`,` vec3 col = mix(u_a, u_b, smoothstep(0.0, 1.0, d1 * u_scale));`,` col = mix(col, u_c, smoothstep(0.0, 1.2, d2 * u_scale) * 0.65);`,` gl_FragColor = vec4(col, 1.0);`,`}`].join(`
107
107
  `),waves:[`void main(){`,` vec2 uv = gl_FragCoord.xy / u_res;`,` float t = u_time * 0.5;`,` float y = uv.y * u_scale;`,` float w = sin((uv.x * 6.0) + t) * 0.08 + sin((uv.x * 11.0) - (t * 1.3)) * 0.05;`,` float band = smoothstep(0.0, 1.0, y + w + (u_mouse.y * 0.1));`,` vec3 col = mix(u_a, u_b, band);`,` col += u_c * (0.12 * smoothstep(0.02, 0.0, abs(y + w - 0.5)));`,` gl_FragColor = vec4(col, 1.0);`,`}`].join(`
108
108
  `),plasma:[`void main(){`,` vec2 uv = gl_FragCoord.xy / u_res;`,` vec2 p = (uv - 0.5) * u_scale * 3.0 + u_mouse * 0.3;`,` float t = u_time * 0.2;`,` float n = fbm(p + vec2(fbm(p + t), fbm(p - t)));`,` vec3 col = mix(u_a, u_b, smoothstep(0.25, 0.75, n));`,` col = mix(col, u_c, smoothstep(0.6, 0.95, n));`,` gl_FragColor = vec4(col, 1.0);`,`}`].join(`
109
109
  `),grid:[`void main(){`,` vec2 uv = gl_FragCoord.xy / u_res;`,` vec2 sp = (gl_FragCoord.xy - 0.5 * u_res) / min(u_res.x, u_res.y);`,` float t = u_time * 0.15;`,` vec2 g = sp * (8.0 * u_scale);`,` g.y += t;`,` vec2 f = abs(fract(g) - 0.5);`,` float line = smoothstep(0.48, 0.5, max(f.x, f.y));`,` float glow = 1.0 - smoothstep(0.0, 0.9, length(sp - u_mouse * 0.4));`,` vec3 col = mix(u_a, u_b, line);`,` col += u_c * glow * 0.35;`,` gl_FragColor = vec4(col, 1.0);`,`}`].join(`
110
- `)};function il(e,t){let n=/^#?([0-9a-f]{6})$/i.exec(String(e??``).trim());if(!n)return t;let r=parseInt(n[1],16);return[(r>>16&255)/255,(r>>8&255)/255,(r&255)/255]}function al(e,t,n){let r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS)){let t=e.getShaderInfoLog(r);throw e.deleteShader(r),Error(t||`Shader failed to compile`)}return r}function ol({preset:e,code:t,colorA:n,colorB:r,colorC:i,speed:a,scale:o,height:s,interactive:c,style:u,nodeRef:d,inert:f}){let p=(0,l.useRef)(null),m=(0,l.useRef)(null),h=(0,l.useRef)(null),[g,_]=(0,l.useState)(``);(0,l.useEffect)(()=>()=>{let e=h.current;h.current=null,e?.getExtension(`WEBGL_lose_context`)?.loseContext()},[]);let v=typeof t==`string`&&t.trim()?t:rl[e]??rl.gradient,y=String(n??``),b=String(r??``),x=String(i??``),S=Xc(a,100),C=Math.max(.05,Xc(o,100));return(0,l.useEffect)(()=>{let e=p.current,t=m.current;if(!e||!t)return;let n=h.current??=e.getContext(`webgl`,{antialias:!0,alpha:!0,premultipliedAlpha:!1});if(!n){_(`WebGL is not available in this browser`);return}let r=null;try{let e=al(n,n.VERTEX_SHADER,tl),t=al(n,n.FRAGMENT_SHADER,nl+v);if(r=n.createProgram(),n.attachShader(r,e),n.attachShader(r,t),n.linkProgram(r),!n.getProgramParameter(r,n.LINK_STATUS))throw Error(n.getProgramInfoLog(r)||`Link failed`);_(``)}catch(e){_(e?.message||`Shader failed to compile`);return}n.useProgram(r);let i=n.createBuffer();n.bindBuffer(n.ARRAY_BUFFER,i),n.bufferData(n.ARRAY_BUFFER,new Float32Array([-1,-1,3,-1,-1,3]),n.STATIC_DRAW);let a=n.getAttribLocation(r,`p`);n.enableVertexAttribArray(a),n.vertexAttribPointer(a,2,n.FLOAT,!1,0,0);let o=e=>n.getUniformLocation(r,e),s={res:o(`u_res`),time:o(`u_time`),mouse:o(`u_mouse`),a:o(`u_a`),b:o(`u_b`),c:o(`u_c`),scale:o(`u_scale`)},l={x:0,y:0},u=t=>{let n=e.getBoundingClientRect();!n.width||!n.height||(l.x=((t.clientX-n.left)/n.width-.5)*2,l.y=(.5-(t.clientY-n.top)/n.height)*2)};c!==!1&&t.addEventListener(`pointermove`,u);let d=()=>{let r=Kc(),i=Math.max(1,Math.round(t.clientWidth*r)),a=Math.max(1,Math.round(t.clientHeight*r));(e.width!==i||e.height!==a)&&(e.width=i,e.height=a,n.viewport(0,0,i,a))},f=typeof ResizeObserver>`u`?null:new ResizeObserver(d);f?.observe(t),d();let g=Gc(),w={a:il(y,[.35,.4,.95]),b:il(b,[.05,.06,.16]),c:il(x,[.95,.35,.6])},T={};return T.stop=qc(t,(t,r)=>{d(),n.uniform2f(s.res,e.width,e.height),n.uniform1f(s.time,(g?0:r)*S),n.uniform2f(s.mouse,l.x,l.y),n.uniform3fv(s.a,w.a),n.uniform3fv(s.b,w.b),n.uniform3fv(s.c,w.c),n.uniform1f(s.scale,C),n.drawArrays(n.TRIANGLES,0,3),g&&T.stop?.()}),()=>{T.stop?.(),f?.disconnect(),t.removeEventListener(`pointermove`,u),n.deleteProgram(r),n.deleteBuffer(i)}},[v,y,b,x,S,C,c]),(0,W.jsxs)(`div`,{ref:e=>{m.current=e,typeof d==`function`&&d(e)},style:{position:`relative`,minHeight:Yc(s,320),overflow:`hidden`,...z(u)},children:[(0,W.jsx)(`canvas`,{ref:p,style:{display:`block`,width:`100%`,height:`100%`,position:`absolute`,inset:0}}),g&&f?(0,W.jsx)(`div`,{style:{position:`absolute`,inset:0,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:12,background:`rgba(15,23,42,.75)`,...U,color:`#fecaca`,fontSize:11,whiteSpace:`pre-wrap`,overflow:`auto`},children:g}):null]})}function sl(e,t){let n=new e.Scene,r=new e.BoxGeometry;r.deleteAttribute(`uv`);let i=new e.Mesh(r,new e.MeshBasicMaterial({side:e.BackSide,color:6710886}));i.scale.setScalar(12),n.add(i);let a=(t,i,a,o,s,c,l,u)=>{let d=new e.Mesh(r,new e.MeshBasicMaterial);d.material.color.setHex(t),d.material.color.multiplyScalar(i),d.position.set(a,o,s),d.scale.set(c,l,u),n.add(d)};a(16777215,4,0,6,0,10,.5,10),a(16777215,1.4,-6,1,2,.4,6,6),a(16777215,1,6,1,-2,.4,6,6);let o=new e.PMREMGenerator(t),s=o.fromScene(n,.04);return o.dispose(),r.dispose(),n.traverse(e=>e.material?.dispose?.()),s.texture}var cl=new Map;function ll(e){if(cl.has(e))return cl.get(e);let t=Uc(`loaders/GLTFLoader.js`).then(t=>new Promise((n,r)=>{new t.GLTFLoader().load(e,e=>n(e.scene),void 0,r)})).catch(t=>{throw cl.delete(e),t});return cl.set(e,t),t}function ul(e,t){let n=new e.Box3().setFromObject(t);if(n.isEmpty())return t;let r=n.getSize(new e.Vector3),i=n.getCenter(new e.Vector3),a=Math.max(r.x,r.y,r.z)||1,o=new e.Group;return t.position.sub(i),t.scale.multiplyScalar(1/a),t.position.multiplyScalar(1/a),o.add(t),o}var dl={box:e=>new e.BoxGeometry(1,1,1,1,1,1),sphere:e=>new e.SphereGeometry(.62,48,32),torus:e=>new e.TorusGeometry(.5,.2,24,64),knot:e=>new e.TorusKnotGeometry(.44,.15,128,24),cone:e=>new e.ConeGeometry(.55,1.1,48),cylinder:e=>new e.CylinderGeometry(.45,.45,1.1,48),plane:e=>new e.PlaneGeometry(1.4,1.4),capsule:e=>new e.CapsuleGeometry(.35,.6,8,32)},fl=(e,t)=>Number.isFinite(Number(e))?Number(e):t;function pl({objects:e,background:t,cameraDistance:n,fov:r,autoRotate:i,spinSpeed:a,controls:o,ground:s,height:c,style:u,nodeRef:d,inert:f}){let p=(0,l.useRef)(null),[m,h]=(0,l.useState)(!1),g=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],_=JSON.stringify(g),v=i!==!1&&!Gc(),y=o!==!1&&!f;return(0,l.useEffect)(()=>{let e=p.current;if(!e)return;let i=!0,o=null;return Hc().then(c=>{if(!i||!e)return;let l=new c.WebGLRenderer({antialias:!0,alpha:!t});l.setPixelRatio(Kc()),l.shadowMap.enabled=s!==!1,l.shadowMap.type=c.PCFSoftShadowMap,l.outputColorSpace=c.SRGBColorSpace,l.toneMapping=c.ACESFilmicToneMapping,l.domElement.style.display=`block`,l.domElement.style.width=`100%`,l.domElement.style.height=`100%`,e.appendChild(l.domElement);let u=new c.Scene;t&&(u.background=new c.Color(t)),u.environment=sl(c,l);let d=new c.PerspectiveCamera(fl(r,45),1,.1,400),f=Jc(d,l.domElement,{distance:fl(n,5),enableZoom:y}),p=new c.DirectionalLight(16777215,2.2);p.position.set(4,7,5),p.castShadow=s!==!1,p.shadow.mapSize.set(1024,1024),p.shadow.camera.near=.5,p.shadow.camera.far=30,u.add(p,new c.AmbientLight(16777215,.35));let m=[],h=new c.Group,_=(e,t)=>{let n=fl(t.scale,1);e.position.set(fl(t.x,0),fl(t.y,0),fl(t.z,0)),e.rotation.set(Zc(t.rx),Zc(t.ry),Zc(t.rz)),e.scale.setScalar(n>0?n:1),e.userData.spin=Zc(t.spin)};for(let e of g){if(e.shape===`model`){if(!Qc(e.src))continue;let t=new c.Group;_(t,e),h.add(t),ll(e.src).then(e=>{if(!i)return;let n=ul(c,e.clone(!0));n.traverse(e=>{e.isMesh&&(e.castShadow=!0,e.receiveShadow=!0)}),t.add(n)},()=>{});continue}let t=(dl[e.shape]??dl.box)(c),n=new c.MeshStandardMaterial({color:/^#?[0-9a-f]{6}$/i.test(String(e.color??``))?e.color:`#6366f1`,metalness:Math.min(1,Math.max(0,Xc(e.metalness,10))),roughness:Math.min(1,Math.max(0,Xc(e.roughness,35))),transparent:Xc(e.opacity,100)<1,opacity:Math.min(1,Math.max(0,Xc(e.opacity,100))),flatShading:e.flat===!0,wireframe:e.wireframe===!0,side:e.shape===`plane`?c.DoubleSide:c.FrontSide}),r=new c.Mesh(t,n);_(r,e),r.castShadow=!0,r.receiveShadow=!0,h.add(r),m.push(t,n)}u.add(h);let b=null;if(s!==!1){let e=new c.ShadowMaterial({opacity:.22}),t=new c.PlaneGeometry(60,60);b=new c.Mesh(t,e),b.rotation.x=-Math.PI/2,b.position.y=fl(s===!0?0:s,-.85),b.receiveShadow=!0,u.add(b),m.push(t,e)}let x=()=>{let t=Math.max(1,e.clientWidth),n=Math.max(1,e.clientHeight);l.setSize(t,n,!1),d.aspect=t/n,d.updateProjectionMatrix()},S=typeof ResizeObserver>`u`?null:new ResizeObserver(x);S?.observe(e),x();let C=Zc(Number.isFinite(Number(a))?a:20),w=qc(e,e=>{f.autoSpin(v?C:0,e),f.update();for(let t of h.children)t.userData.spin&&(t.rotation.y+=t.userData.spin*e);l.render(u,d)});o=()=>{w(),S?.disconnect(),f.dispose();for(let e of m)e.dispose?.();u.environment?.dispose?.(),l.dispose(),l.domElement.remove()}},()=>{i&&h(!0)}),()=>{i=!1,o?.()}},[_,t,n,r,v,a,y,s]),m&&f?(0,W.jsx)($c,{nodeRef:d,style:u,height:c,label:`3D Scene`,note:`The 3D engine could not be loaded. Check the connection and try again.`}):(0,W.jsx)(`div`,{ref:e=>{p.current=e,typeof d==`function`&&d(e)},style:{minHeight:Yc(c,380),height:Yc(c,380),overflow:`hidden`,touchAction:y?`pan-y`:void 0,...z(u)}})}function ml({code:e,height:t,background:n,style:r,nodeRef:i,inert:a}){let o=(0,l.useRef)(null),[s,c]=(0,l.useState)(``);return(0,l.useEffect)(()=>{let t=o.current;if(a||!t||typeof e!=`string`||!e.trim())return;let r=!0,i=null;return Hc().then(a=>{if(!r||!t)return;let o=new a.WebGLRenderer({antialias:!0,alpha:!n});o.setPixelRatio(Kc()),o.outputColorSpace=a.SRGBColorSpace,o.domElement.style.display=`block`,o.domElement.style.width=`100%`,o.domElement.style.height=`100%`,t.appendChild(o.domElement);let s=new a.Scene;n&&(s.background=new a.Color(n));let l=new a.PerspectiveCamera(45,1,.1,1e3);l.position.set(0,1.2,4);let u=null;try{u=Function(`ctx`,`"use strict";\n${e}`)({THREE:a,scene:s,camera:l,renderer:o,canvas:o.domElement,host:t})}catch(e){c(e?.message||String(e))}let d=()=>{let e=Math.max(1,t.clientWidth),n=Math.max(1,t.clientHeight);o.setSize(e,n,!1),l.aspect=e/n,l.updateProjectionMatrix()},f=typeof ResizeObserver>`u`?null:new ResizeObserver(d);f?.observe(t),d();let p=!1,m=qc(t,(e,t)=>{if(!p&&typeof u?.frame==`function`)try{u.frame(e,t)}catch(e){p=!0,c(e?.message||String(e))}o.render(s,l)});i=()=>{m(),f?.disconnect();try{u?.dispose?.()}catch{}o.dispose(),o.domElement.remove()}}),()=>{r=!1,i?.()}},[e,a,n]),a?(0,W.jsx)($c,{nodeRef:i,style:r,height:t,label:`three.js`,note:typeof e==`string`&&e.trim()?`Custom scene code runs in Preview and on the published page.`:`Open the code editor in the Settings panel to write your scene.`}):(0,W.jsx)(`div`,{ref:e=>{o.current=e,typeof i==`function`&&i(e)},style:{minHeight:Yc(t,380),height:Yc(t,380),overflow:`hidden`,position:`relative`,touchAction:`pan-y`,...z(r)},children:s?(0,W.jsx)(`div`,{style:{position:`absolute`,left:8,top:8,right:8,padding:`6px 8px`,borderRadius:6,background:`rgba(127,29,29,.85)`,...U,color:`#fee2e2`,fontSize:11},children:s}):null})}var hl={ModelViewerBlock:el,ShaderBlock:ol,SceneBlock:pl,ThreeCanvasBlock:ml},gl=`2.44.0`,_l=`https://cdn.jsdelivr.net/npm`,vl=`${_l}/@rive-app/canvas@${gl}/+esm`,yl=`${_l}/@rive-app/canvas@${gl}/rive.wasm`,bl=e=>import(e),xl=null;function Sl(){return typeof window>`u`?new Promise(()=>{}):xl||(xl=bl(vl).then(e=>{let t=e?.default??e;return t?.RuntimeLoader?.setWasmUrl&&t.RuntimeLoader.setWasmUrl(yl),t}).catch(e=>{throw xl=null,e}),xl)}var Cl=new Map,wl={56:`number`,58:`trigger`,59:`boolean`},Tl=new Set;function El(e,t){if(!e||!t)return;let n=(Array.isArray(t.artboards)?t.artboards:[]).map(e=>({name:String(e?.name??``),animations:(Array.isArray(e?.animations)?e.animations:[]).map(String),stateMachines:(Array.isArray(e?.stateMachines)?e.stateMachines:[]).map(e=>({name:String(e?.name??``),inputs:(Array.isArray(e?.inputs)?e.inputs:[]).map(e=>({name:String(e?.name??``),type:wl[e?.type]??`unknown`}))}))}));Cl.set(e,{artboards:n}),Tl.forEach(t=>t(e))}var Dl=(e,t)=>Number.isFinite(Number(e))&&Number(e)>0?Number(e):t,Ol=[`contain`,`cover`,`fill`,`fitWidth`,`fitHeight`,`scaleDown`,`none`,`layout`],kl=[`center`,`topLeft`,`topCenter`,`topRight`,`centerLeft`,`centerRight`,`bottomLeft`,`bottomCenter`,`bottomRight`],Al=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,jl=131;function Ml(e,t,n,r){if(!e||!t||!n)return;let i=[];try{i=e.stateMachineInputs(t)??[]}catch{return}let a=i.find(e=>e?.name===n);a&&(a.type===58?r&&a.fire():a.type===59?a.value=!!r:a.type===56&&(a.value=+!!r))}function Nl({src:e,poster:t,alt:n,height:r,bg:i,artboard:a,mode:o=`stateMachine`,stateMachine:s,animation:c,fit:u=`contain`,alignment:d=`center`,autoplay:f=!0,hoverInput:p,clickInput:m,style:h,nodeRef:g,inert:_}){let v=(0,l.useRef)(null),y=(0,l.useRef)(null),b=(0,l.useRef)(null),x=(0,l.useRef)(``),[S,C]=(0,l.useState)(!1),[w,T]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let t=y.current,n=v.current;if(C(!1),T(!1),!e||!t)return;let r=!0,i=null,l=null,p=null;return Sl().then(m=>{if(!r)return;let h=o!==`animation`,g=f!==!1&&!Al();try{i=new m.Rive({src:e,canvas:t,artboard:a||void 0,stateMachines:h&&s?s:void 0,animations:!h&&c?c:void 0,autoplay:g,layout:new m.Layout({fit:Ol.includes(u)?u:`contain`,alignment:kl.includes(d)?d:`center`}),shouldDisableRiveListeners:!!_,isTouchScrollEnabled:!0,onLoad:()=>{if(!r)return;i.resizeDrawingSurfaceToCanvas();let t=i.contents;if(El(e,t),h){let e=((t?.artboards??[]).find(e=>e.name===(a||i.activeArtboard))??t?.artboards?.[0])?.stateMachines?.[0]?.name??``;if(x.current=s||e,!s&&e)try{i.play(e),g||i.pause(e)}catch{}}C(!0)},onLoadError:()=>r&&T(!0)})}catch{T(!0);return}b.current=i,n&&(n.rive=i),i.on(m.EventType.RiveEvent,e=>{let t=e?.data;_||t?.type!==jl||!t?.url||(t.target===`_self`?window.location.assign(t.url):window.open(t.url,t.target||`_blank`,`noopener`))}),n&&typeof ResizeObserver<`u`&&(l=new ResizeObserver(()=>i?.resizeDrawingSurfaceToCanvas()),l.observe(n)),n&&typeof IntersectionObserver<`u`&&(p=new IntersectionObserver(([e])=>{i&&(e?.isIntersecting?i.startRendering?.():i.stopRendering?.())}),p.observe(n))},()=>r&&T(!0)),()=>{r=!1,l?.disconnect(),p?.disconnect(),n&&n.rive===i&&delete n.rive,b.current=null,x.current=``;try{i?.cleanup()}catch{}}},[e,a,o,s,c,u,d,f,_]);let E=!_&&S,D=(e,t)=>E&&Ml(b.current,x.current,e,t),O={position:`relative`,display:`block`,width:`100%`,height:Dl(r,360),backgroundColor:i||`transparent`,overflow:`hidden`,...z(h)};return e?(0,W.jsxs)(`div`,{ref:e=>{v.current=e,typeof g==`function`&&g(e)},style:O,onMouseEnter:p?()=>D(p,!0):void 0,onMouseLeave:p?()=>D(p,!1):void 0,onClick:m?()=>D(m,!0):void 0,children:[(0,W.jsx)(`canvas`,{ref:y,...G(`canvas`),role:`img`,"aria-label":n||`Animation`,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,display:`block`}}),t&&(!S||w)?(0,W.jsx)(`img`,{...G(`poster`),src:t,alt:n||``,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,objectFit:`contain`,pointerEvents:`none`}}):null]}):_?(0,W.jsxs)(`div`,{ref:g,style:{...O,display:`flex`,alignItems:`center`,justifyContent:`center`,flexDirection:`column`,gap:6,border:`1px dashed rgba(148,163,184,.55)`,borderRadius:10,background:`rgba(148,163,184,.08)`,...U,color:`rgba(100,116,139,.95)`,fontSize:13,textAlign:`center`,padding:16},children:[(0,W.jsx)(`strong`,{style:{fontSize:14},children:`Rive`}),(0,W.jsx)(`span`,{children:`Pick a .riv file in the Settings panel.`})]}):null}var Pl={RiveBlock:Nl},X=new Map;function Fl(e){if(X.has(e))return X.get(e);let t=URL.createObjectURL(new Blob([e],{type:`text/javascript`})),n=import(t).finally(()=>URL.revokeObjectURL(t));return X.set(e,n),n}function Z(e){let t=e&&typeof e==`object`?e.builder_plugins:null,n=t&&typeof t==`object`?t.plugins:null;return n&&typeof n==`object`?n:{}}async function Q(e,t){let n=await Fl(e);return(Array.isArray(n?.default?.blocks)?n.default.blocks:[]).find(e=>e?.id===t&&typeof e.mount==`function`)??null}var Il={padding:`10px 12px`,border:`1px dashed rgba(148, 163, 184, 0.5)`,borderRadius:8,fontSize:12,opacity:.6};function Ll({pluginId:e,blockId:t,props:n,style:r,nodeRef:i}){let a=(0,l.useContext)(Nn),o=Z(a?.settings)[e],s=(0,l.useRef)(null),c=(0,l.useRef)(null),u={tenant:a?.tenant??``,apiUrl:a?.apiUrl??`/api`,locale:a?.locale??``,settings:a?.settings??null},d=(0,l.useRef)(u);d.current=u;let f=JSON.stringify(n??{});return(0,l.useEffect)(()=>{let e=s.current;if(!o?.code||!e)return;let n=!0;return Q(o.code,t).then(e=>{if(!(!n||!e||!s.current)){c.current=e;try{e.mount(s.current,JSON.parse(f),d.current)}catch{c.current=null}}}).catch(()=>{}),()=>{n=!1;let t=c.current;c.current=null;try{t?.unmount?.(e)}catch{}e&&(e.innerHTML=``)}},[o?.code,t]),(0,l.useEffect)(()=>{let e=c.current,t=s.current;if(!(!e||!t))try{e.update?e.update(t,JSON.parse(f),d.current):(e.unmount?.(t),t.innerHTML=``,e.mount(t,JSON.parse(f),d.current))}catch{}},[f]),o?(0,W.jsx)(`div`,{ref:i,style:z(r),children:(0,W.jsx)(`div`,{ref:s})}):(0,W.jsxs)(`div`,{ref:i,style:{...Il,...z(r)},children:[`Plugin “`,e,`” is not installed`]})}function Rl(e,t,n){let r={"data-wb":e};t.htmlId&&(r.id=t.htmlId),n&&n.id===e&&(r.id=t.htmlId||n.htmlId,r.tabIndex=-1);let i=V(t.classNames);i.length&&(r[`data-wb-class`]=i.join(` `));for(let e of Array.isArray(t.attributes)?t.attributes:[]){let t=String(e?.name??``).trim();B(t)&&(r[t===`tabindex`?`tabIndex`:t]=e.value??``)}return{attrs:r,classes:i}}function zl({View:e,markup:t,...n}){let r=e(n);if(!(0,l.isValidElement)(r)||typeof r.type!=`string`)return r;let i=[r.props.className,...t.classes].filter(Boolean).join(` `);return(0,l.cloneElement)(r,{...t.attrs,...i?{className:i}:{}})}var Bl=new Set([`FormInput`,`FormTextarea`,`FormSelect`]);function Vl(e,t,n,r){if(t.forNode===`__none`)return``;let i=t.forNode?n[t.forNode]:null;if(!t.forNode){let t=n[r]?.nodes??[];i=n[t[t.indexOf(e)+1]]??null}return!i||!Bl.has(i.type?.resolvedName)?``:i.props?.htmlId||na(i.props?.name)||``}var Hl=`slot-`,Ul={...Do,...Nc,...hl,...Pl,PluginBlock:Ll};function Wl(e,t,n,r=new Set,i=void 0){let a=t[e];if(!a||a.hidden)return null;let o=a.type?.resolvedName,s=i?.mapProps?i.mapProps(a.props??{},o):a.props??{};if(o===`ComponentInstance`){let o=a.props?.componentId,c=n?.[o];if(!c?.template||r.has(o))return null;let u=new Set(r).add(o),d=Object.fromEntries(Object.entries(a.linkedNodes??{}).filter(([e])=>e.startsWith(Hl)).map(([e,a])=>[e.slice(5),Wl(a,t,n,r,i)]));return(0,W.jsx)(l.Fragment,{children:Wl(c.template.rootId,c.template.nodes,n,u,{...pt(s.values,i),slots:d})},e)}let c=Ul[o];if(!c)return null;let u=s.compSlot?.id,d=u&&i?.slots&&Object.hasOwn(i.slots,u)?i.slots[u]:void 0,f=d===void 0?(a.nodes??[]).map(e=>Wl(e,t,n,r,i)).filter(Boolean):[d].filter(Boolean),p=Object.entries(a.linkedNodes??{}),m=p.length?Object.fromEntries(p.map(([e,a])=>[e,Wl(a,t,n,r,i)])):void 0,h=(0,W.jsx)(typeof c==`function`?zl:c,{...typeof c==`function`?{View:c,markup:Rl(e,s,i?.skipTarget)}:null,...s,...o===`CollectionList`?{templateId:a.linkedNodes?.card,renderTemplate:a.linkedNodes?.card?e=>Wl(a.linkedNodes.card,t,n,r,{...i,mapProps:i?.mapProps?(t,n)=>i.mapProps(e(t,n),n):e}):void 0}:null,...o===`FormLabel`?{htmlFor:Vl(e,s,t,a.parent)}:null,linked:m,nodeRef:t=>{t&&(t.setAttribute(`data-wb`,e),ce(t,s),i?.skipTarget?.id===e&&(t.id=s.htmlId||i.skipTarget.htmlId,t.tabIndex=-1),se(t,i?.events===!1?[]:s.events))},children:f.length?f:void 0},e),g=s.when&&s.when!==`always`?(0,W.jsx)(Lo,{when:s.when,children:h},e):h;return Array.isArray(s.showWhen?.rules)&&s.showWhen.rules.length?(0,W.jsx)(Wn,{showWhen:s.showWhen,children:g},e):g}var Gl=e=>Object.entries(e).map(([e,t])=>`${e}: ${t};`).join(` `),Kl=e=>`.webim-page[data-webim-mode="light"] { ${Object.entries(Pe(e.light)).map(([e,t])=>`${e}: ${t} !important;`).join(` `)} }
111
- .webim-page[data-webim-mode="dark"] { ${Object.entries(Pe(e.dark)).map(([e,t])=>`${e}: ${t} !important;`).join(` `)} }`;function ql({blocks:e,theme:t,components:n,mode:r=`auto`,style:i,custom:a,animations:o,tenant:s,apiUrl:c,datasets:u,locale:d,direction:f,settings:p,siteUser:m,param:g}){let _=a?.js?.trim(),y=p&&p[`site.code`]&&typeof p[`site.code`]==`object`?p[`site.code`]:null,b=typeof y?.js==`string`?y.js.trim():``,x=typeof y?.css==`string`?y.css.trim():``;if((0,l.useEffect)(()=>{if(!b)return;let e=document.createElement(`script`);return e.text=b,document.body.appendChild(e),()=>e.remove()},[b]),(0,l.useEffect)(()=>{if(!_)return;let e=document.createElement(`script`);return e.text=_,document.body.appendChild(e),()=>e.remove()},[_]),!e?.ROOT)return null;let S={lang:d||void 0,dir:ct(f,d)},C=`.webim-page, .webim-page *, .webim-page *::before, .webim-page *::after { box-sizing: border-box; }
110
+ `)};function il(e,t){let n=/^#?([0-9a-f]{6})$/i.exec(String(e??``).trim());if(!n)return t;let r=parseInt(n[1],16);return[(r>>16&255)/255,(r>>8&255)/255,(r&255)/255]}function al(e,t,n){let r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS)){let t=e.getShaderInfoLog(r);throw e.deleteShader(r),Error(t||`Shader failed to compile`)}return r}function ol({preset:e,code:t,colorA:n,colorB:r,colorC:i,speed:a,scale:o,height:s,interactive:c,style:u,nodeRef:d,inert:f}){let p=(0,l.useRef)(null),m=(0,l.useRef)(null),h=(0,l.useRef)(null),[g,_]=(0,l.useState)(``);(0,l.useEffect)(()=>()=>{let e=h.current;h.current=null,e?.getExtension(`WEBGL_lose_context`)?.loseContext()},[]);let v=typeof t==`string`&&t.trim()?t:rl[e]??rl.gradient,y=String(n??``),b=String(r??``),x=String(i??``),S=Xc(a,100),C=Math.max(.05,Xc(o,100));return(0,l.useEffect)(()=>{let e=p.current,t=m.current;if(!e||!t)return;let n=h.current??=e.getContext(`webgl`,{antialias:!0,alpha:!0,premultipliedAlpha:!1});if(!n){_(`WebGL is not available in this browser`);return}let r=null;try{let e=al(n,n.VERTEX_SHADER,tl),t=al(n,n.FRAGMENT_SHADER,nl+v);if(r=n.createProgram(),n.attachShader(r,e),n.attachShader(r,t),n.linkProgram(r),!n.getProgramParameter(r,n.LINK_STATUS))throw Error(n.getProgramInfoLog(r)||`Link failed`);_(``)}catch(e){_(e?.message||`Shader failed to compile`);return}n.useProgram(r);let i=n.createBuffer();n.bindBuffer(n.ARRAY_BUFFER,i),n.bufferData(n.ARRAY_BUFFER,new Float32Array([-1,-1,3,-1,-1,3]),n.STATIC_DRAW);let a=n.getAttribLocation(r,`p`);n.enableVertexAttribArray(a),n.vertexAttribPointer(a,2,n.FLOAT,!1,0,0);let o=e=>n.getUniformLocation(r,e),s={res:o(`u_res`),time:o(`u_time`),mouse:o(`u_mouse`),a:o(`u_a`),b:o(`u_b`),c:o(`u_c`),scale:o(`u_scale`)},l={x:0,y:0},u=t=>{let n=e.getBoundingClientRect();!n.width||!n.height||(l.x=((t.clientX-n.left)/n.width-.5)*2,l.y=(.5-(t.clientY-n.top)/n.height)*2)};c!==!1&&t.addEventListener(`pointermove`,u);let d=()=>{let r=Kc(),i=Math.max(1,Math.round(t.clientWidth*r)),a=Math.max(1,Math.round(t.clientHeight*r));(e.width!==i||e.height!==a)&&(e.width=i,e.height=a,n.viewport(0,0,i,a))},f=typeof ResizeObserver>`u`?null:new ResizeObserver(d);f?.observe(t),d();let g=Gc(),w={a:il(y,[.35,.4,.95]),b:il(b,[.05,.06,.16]),c:il(x,[.95,.35,.6])},T={};return T.stop=qc(t,(t,r)=>{d(),n.uniform2f(s.res,e.width,e.height),n.uniform1f(s.time,(g?0:r)*S),n.uniform2f(s.mouse,l.x,l.y),n.uniform3fv(s.a,w.a),n.uniform3fv(s.b,w.b),n.uniform3fv(s.c,w.c),n.uniform1f(s.scale,C),n.drawArrays(n.TRIANGLES,0,3),g&&T.stop?.()}),()=>{T.stop?.(),f?.disconnect(),t.removeEventListener(`pointermove`,u),n.deleteProgram(r),n.deleteBuffer(i)}},[v,y,b,x,S,C,c]),(0,W.jsxs)(`div`,{ref:e=>{m.current=e,typeof d==`function`&&d(e)},style:{position:`relative`,minHeight:Yc(s,320),overflow:`hidden`,...z(u)},children:[(0,W.jsx)(`canvas`,{ref:p,style:{display:`block`,width:`100%`,height:`100%`,position:`absolute`,inset:0}}),g&&f?(0,W.jsx)(`div`,{style:{position:`absolute`,inset:0,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:12,background:`rgba(15,23,42,.75)`,...U,color:`#fecaca`,fontSize:11,whiteSpace:`pre-wrap`,overflow:`auto`},children:g}):null]})}function sl(e,t){let n=new e.Scene,r=new e.BoxGeometry;r.deleteAttribute(`uv`);let i=new e.Mesh(r,new e.MeshBasicMaterial({side:e.BackSide,color:6710886}));i.scale.setScalar(12),n.add(i);let a=(t,i,a,o,s,c,l,u)=>{let d=new e.Mesh(r,new e.MeshBasicMaterial);d.material.color.setHex(t),d.material.color.multiplyScalar(i),d.position.set(a,o,s),d.scale.set(c,l,u),n.add(d)};a(16777215,4,0,6,0,10,.5,10),a(16777215,1.4,-6,1,2,.4,6,6),a(16777215,1,6,1,-2,.4,6,6);let o=new e.PMREMGenerator(t),s=o.fromScene(n,.04);return o.dispose(),r.dispose(),n.traverse(e=>e.material?.dispose?.()),s.texture}var cl=new Map;function ll(e){if(cl.has(e))return cl.get(e);let t=Uc(`loaders/GLTFLoader.js`).then(t=>new Promise((n,r)=>{new t.GLTFLoader().load(e,e=>n(e.scene),void 0,r)})).catch(t=>{throw cl.delete(e),t});return cl.set(e,t),t}function ul(e,t){let n=new e.Box3().setFromObject(t);if(n.isEmpty())return t;let r=n.getSize(new e.Vector3),i=n.getCenter(new e.Vector3),a=Math.max(r.x,r.y,r.z)||1,o=new e.Group;return t.position.sub(i),t.scale.multiplyScalar(1/a),t.position.multiplyScalar(1/a),o.add(t),o}var dl={box:e=>new e.BoxGeometry(1,1,1,1,1,1),sphere:e=>new e.SphereGeometry(.62,48,32),torus:e=>new e.TorusGeometry(.5,.2,24,64),knot:e=>new e.TorusKnotGeometry(.44,.15,128,24),cone:e=>new e.ConeGeometry(.55,1.1,48),cylinder:e=>new e.CylinderGeometry(.45,.45,1.1,48),plane:e=>new e.PlaneGeometry(1.4,1.4),capsule:e=>new e.CapsuleGeometry(.35,.6,8,32)},fl=(e,t)=>Number.isFinite(Number(e))?Number(e):t;function pl({objects:e,background:t,cameraDistance:n,fov:r,autoRotate:i,spinSpeed:a,controls:o,ground:s,height:c,style:u,nodeRef:d,inert:f}){let p=(0,l.useRef)(null),[m,h]=(0,l.useState)(!1),g=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],_=JSON.stringify(g),v=i!==!1&&!Gc(),y=o!==!1&&!f;return(0,l.useEffect)(()=>{let e=p.current;if(!e)return;let i=!0,o=null;return Hc().then(c=>{if(!i||!e)return;let l=new c.WebGLRenderer({antialias:!0,alpha:!t});l.setPixelRatio(Kc()),l.shadowMap.enabled=s!==!1,l.shadowMap.type=c.PCFSoftShadowMap,l.outputColorSpace=c.SRGBColorSpace,l.toneMapping=c.ACESFilmicToneMapping,l.domElement.style.display=`block`,l.domElement.style.width=`100%`,l.domElement.style.height=`100%`,e.appendChild(l.domElement);let u=new c.Scene;t&&(u.background=new c.Color(t)),u.environment=sl(c,l);let d=new c.PerspectiveCamera(fl(r,45),1,.1,400),f=Jc(d,l.domElement,{distance:fl(n,5),enableZoom:y}),p=new c.DirectionalLight(16777215,2.2);p.position.set(4,7,5),p.castShadow=s!==!1,p.shadow.mapSize.set(1024,1024),p.shadow.camera.near=.5,p.shadow.camera.far=30,u.add(p,new c.AmbientLight(16777215,.35));let m=[],h=new c.Group,_=(e,t)=>{let n=fl(t.scale,1);e.position.set(fl(t.x,0),fl(t.y,0),fl(t.z,0)),e.rotation.set(Zc(t.rx),Zc(t.ry),Zc(t.rz)),e.scale.setScalar(n>0?n:1),e.userData.spin=Zc(t.spin)};for(let e of g){if(e.shape===`model`){if(!Qc(e.src))continue;let t=new c.Group;_(t,e),h.add(t),ll(e.src).then(e=>{if(!i)return;let n=ul(c,e.clone(!0));n.traverse(e=>{e.isMesh&&(e.castShadow=!0,e.receiveShadow=!0)}),t.add(n)},()=>{});continue}let t=(dl[e.shape]??dl.box)(c),n=new c.MeshStandardMaterial({color:/^#?[0-9a-f]{6}$/i.test(String(e.color??``))?e.color:`#6366f1`,metalness:Math.min(1,Math.max(0,Xc(e.metalness,10))),roughness:Math.min(1,Math.max(0,Xc(e.roughness,35))),transparent:Xc(e.opacity,100)<1,opacity:Math.min(1,Math.max(0,Xc(e.opacity,100))),flatShading:e.flat===!0,wireframe:e.wireframe===!0,side:e.shape===`plane`?c.DoubleSide:c.FrontSide}),r=new c.Mesh(t,n);_(r,e),r.castShadow=!0,r.receiveShadow=!0,h.add(r),m.push(t,n)}u.add(h);let b=null;if(s!==!1){let e=new c.ShadowMaterial({opacity:.22}),t=new c.PlaneGeometry(60,60);b=new c.Mesh(t,e),b.rotation.x=-Math.PI/2,b.position.y=fl(s===!0?0:s,-.85),b.receiveShadow=!0,u.add(b),m.push(t,e)}let x=()=>{let t=Math.max(1,e.clientWidth),n=Math.max(1,e.clientHeight);l.setSize(t,n,!1),d.aspect=t/n,d.updateProjectionMatrix()},S=typeof ResizeObserver>`u`?null:new ResizeObserver(x);S?.observe(e),x();let C=Zc(Number.isFinite(Number(a))?a:20),w=qc(e,e=>{f.autoSpin(v?C:0,e),f.update();for(let t of h.children)t.userData.spin&&(t.rotation.y+=t.userData.spin*e);l.render(u,d)});o=()=>{w(),S?.disconnect(),f.dispose();for(let e of m)e.dispose?.();u.environment?.dispose?.(),l.dispose(),l.domElement.remove()}},()=>{i&&h(!0)}),()=>{i=!1,o?.()}},[_,t,n,r,v,a,y,s]),m&&f?(0,W.jsx)($c,{nodeRef:d,style:u,height:c,label:`3D Scene`,note:`The 3D engine could not be loaded. Check the connection and try again.`}):(0,W.jsx)(`div`,{ref:e=>{p.current=e,typeof d==`function`&&d(e)},style:{minHeight:Yc(c,380),height:Yc(c,380),overflow:`hidden`,touchAction:y?`pan-y`:void 0,...z(u)}})}function ml({code:e,height:t,background:n,style:r,nodeRef:i,inert:a}){let o=(0,l.useRef)(null),[s,c]=(0,l.useState)(``);return(0,l.useEffect)(()=>{let t=o.current;if(a||!t||typeof e!=`string`||!e.trim())return;let r=!0,i=null;return Hc().then(a=>{if(!r||!t)return;let o=new a.WebGLRenderer({antialias:!0,alpha:!n});o.setPixelRatio(Kc()),o.outputColorSpace=a.SRGBColorSpace,o.domElement.style.display=`block`,o.domElement.style.width=`100%`,o.domElement.style.height=`100%`,t.appendChild(o.domElement);let s=new a.Scene;n&&(s.background=new a.Color(n));let l=new a.PerspectiveCamera(45,1,.1,1e3);l.position.set(0,1.2,4);let u=null;try{u=Function(`ctx`,`"use strict";\n${e}`)({THREE:a,scene:s,camera:l,renderer:o,canvas:o.domElement,host:t})}catch(e){c(e?.message||String(e))}let d=()=>{let e=Math.max(1,t.clientWidth),n=Math.max(1,t.clientHeight);o.setSize(e,n,!1),l.aspect=e/n,l.updateProjectionMatrix()},f=typeof ResizeObserver>`u`?null:new ResizeObserver(d);f?.observe(t),d();let p=!1,m=qc(t,(e,t)=>{if(!p&&typeof u?.frame==`function`)try{u.frame(e,t)}catch(e){p=!0,c(e?.message||String(e))}o.render(s,l)});i=()=>{m(),f?.disconnect();try{u?.dispose?.()}catch{}o.dispose(),o.domElement.remove()}}),()=>{r=!1,i?.()}},[e,a,n]),a?(0,W.jsx)($c,{nodeRef:i,style:r,height:t,label:`three.js`,note:typeof e==`string`&&e.trim()?`Custom scene code runs in Preview and on the published page.`:`Open the code editor in the Settings panel to write your scene.`}):(0,W.jsx)(`div`,{ref:e=>{o.current=e,typeof i==`function`&&i(e)},style:{minHeight:Yc(t,380),height:Yc(t,380),overflow:`hidden`,position:`relative`,touchAction:`pan-y`,...z(r)},children:s?(0,W.jsx)(`div`,{style:{position:`absolute`,left:8,top:8,right:8,padding:`6px 8px`,borderRadius:6,background:`rgba(127,29,29,.85)`,...U,color:`#fee2e2`,fontSize:11},children:s}):null})}var hl={ModelViewerBlock:el,ShaderBlock:ol,SceneBlock:pl,ThreeCanvasBlock:ml},gl=`2.44.0`,_l=`https://cdn.jsdelivr.net/npm`,vl=`${_l}/@rive-app/canvas@${gl}/+esm`,yl=`${_l}/@rive-app/canvas@${gl}/rive.wasm`,bl=e=>import(e),xl=null;function Sl(){return typeof window>`u`?new Promise(()=>{}):xl||(xl=bl(vl).then(e=>{let t=e?.default??e;return t?.RuntimeLoader?.setWasmUrl&&t.RuntimeLoader.setWasmUrl(yl),t}).catch(e=>{throw xl=null,e}),xl)}var Cl=new Map,wl={56:`number`,58:`trigger`,59:`boolean`},Tl=new Set;function El(e,t){if(!e||!t)return;let n=(Array.isArray(t.artboards)?t.artboards:[]).map(e=>({name:String(e?.name??``),animations:(Array.isArray(e?.animations)?e.animations:[]).map(String),stateMachines:(Array.isArray(e?.stateMachines)?e.stateMachines:[]).map(e=>({name:String(e?.name??``),inputs:(Array.isArray(e?.inputs)?e.inputs:[]).map(e=>({name:String(e?.name??``),type:wl[e?.type]??`unknown`}))}))}));Cl.set(e,{artboards:n}),Tl.forEach(t=>t(e))}var Dl=(e,t)=>Number.isFinite(Number(e))&&Number(e)>0?Number(e):t,Ol=[`contain`,`cover`,`fill`,`fitWidth`,`fitHeight`,`scaleDown`,`none`,`layout`],kl=[`center`,`topLeft`,`topCenter`,`topRight`,`centerLeft`,`centerRight`,`bottomLeft`,`bottomCenter`,`bottomRight`],Al=()=>typeof window<`u`&&!!window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,jl=131;function Ml(e,t,n,r){if(!e||!t||!n)return;let i=[];try{i=e.stateMachineInputs(t)??[]}catch{return}let a=i.find(e=>e?.name===n);a&&(a.type===58?r&&a.fire():a.type===59?a.value=!!r:a.type===56&&(a.value=+!!r))}function Nl({src:e,poster:t,alt:n,height:r,bg:i,artboard:a,mode:o=`stateMachine`,stateMachine:s,animation:c,fit:u=`contain`,alignment:d=`center`,autoplay:f=!0,hoverInput:p,clickInput:m,style:h,nodeRef:g,inert:_}){let v=(0,l.useRef)(null),y=(0,l.useRef)(null),b=(0,l.useRef)(null),x=(0,l.useRef)(``),[S,C]=(0,l.useState)(!1),[w,T]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let t=y.current,n=v.current;if(C(!1),T(!1),!e||!t)return;let r=!0,i=null,l=null,p=null;return Sl().then(m=>{if(!r)return;let h=o!==`animation`,g=f!==!1&&!Al();try{i=new m.Rive({src:e,canvas:t,artboard:a||void 0,stateMachines:h&&s?s:void 0,animations:!h&&c?c:void 0,autoplay:g,layout:new m.Layout({fit:Ol.includes(u)?u:`contain`,alignment:kl.includes(d)?d:`center`}),shouldDisableRiveListeners:!!_,isTouchScrollEnabled:!0,onLoad:()=>{if(!r)return;i.resizeDrawingSurfaceToCanvas();let t=i.contents;if(El(e,t),h){let e=((t?.artboards??[]).find(e=>e.name===(a||i.activeArtboard))??t?.artboards?.[0])?.stateMachines?.[0]?.name??``;if(x.current=s||e,!s&&e)try{i.play(e),g||i.pause(e)}catch{}}C(!0)},onLoadError:()=>r&&T(!0)})}catch{T(!0);return}b.current=i,n&&(n.rive=i),i.on(m.EventType.RiveEvent,e=>{let t=e?.data;_||t?.type!==jl||!t?.url||(t.target===`_self`?window.location.assign(t.url):window.open(t.url,t.target||`_blank`,`noopener`))}),n&&typeof ResizeObserver<`u`&&(l=new ResizeObserver(()=>i?.resizeDrawingSurfaceToCanvas()),l.observe(n)),n&&typeof IntersectionObserver<`u`&&(p=new IntersectionObserver(([e])=>{i&&(e?.isIntersecting?i.startRendering?.():i.stopRendering?.())}),p.observe(n))},()=>r&&T(!0)),()=>{r=!1,l?.disconnect(),p?.disconnect(),n&&n.rive===i&&delete n.rive,b.current=null,x.current=``;try{i?.cleanup()}catch{}}},[e,a,o,s,c,u,d,f,_]);let E=!_&&S,D=(e,t)=>E&&Ml(b.current,x.current,e,t),O={position:`relative`,display:`block`,width:`100%`,height:Dl(r,360),backgroundColor:i||`transparent`,overflow:`hidden`,...z(h)};return e?(0,W.jsxs)(`div`,{ref:e=>{v.current=e,typeof g==`function`&&g(e)},style:O,onMouseEnter:p?()=>D(p,!0):void 0,onMouseLeave:p?()=>D(p,!1):void 0,onClick:m?()=>D(m,!0):void 0,children:[(0,W.jsx)(`canvas`,{ref:y,...K(`canvas`),role:`img`,"aria-label":n||`Animation`,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,display:`block`}}),t&&(!S||w)?(0,W.jsx)(`img`,{...K(`poster`),src:t,alt:n||``,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,objectFit:`contain`,pointerEvents:`none`}}):null]}):_?(0,W.jsxs)(`div`,{ref:g,style:{...O,display:`flex`,alignItems:`center`,justifyContent:`center`,flexDirection:`column`,gap:6,border:`1px dashed rgba(148,163,184,.55)`,borderRadius:10,background:`rgba(148,163,184,.08)`,...U,color:`rgba(100,116,139,.95)`,fontSize:13,textAlign:`center`,padding:16},children:[(0,W.jsx)(`strong`,{style:{fontSize:14},children:`Rive`}),(0,W.jsx)(`span`,{children:`Pick a .riv file in the Settings panel.`})]}):null}var Pl={RiveBlock:Nl},X=/\.(mp4|webm|ogv|ogg|mov|m4v)(\?|#|$)/i,Fl=/\.(jpe?g|png|gif|webp|avif|svg|bmp)(\?|#|$)/i,Z=/\.(pdf|docx?|xlsx?|pptx?|odt|ods|odp|txt|csv|zip|rar|7z|mp3|wav|m4a)(\?|#|$)/i,Q=/vimeo\.com\/(?:video\/)?(\d+)/i,Il=`data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%20320%20240%22%3E%3Crect%20width%3D%22320%22%20height%3D%22240%22%20fill%3D%22%231e293b%22%2F%3E%3Ccircle%20cx%3D%22160%22%20cy%3D%22120%22%20r%3D%2234%22%20fill%3D%22rgba(255%2C255%2C255%2C0.16)%22%2F%3E%3Cpath%20d%3D%22M150%20102%20L178%20120%20L150%20138%20Z%22%20fill%3D%22%23fff%22%2F%3E%3C%2Fsvg%3E`;function Ll(e,t=``){let n=String(e??``);return Gr(n)&&/youtu/i.test(n)?`youtube`:Q.test(n)?`vimeo`:String(t).startsWith(`video/`)||X.test(n)?`video`:String(t).startsWith(`image/`)||Fl.test(n)?`image`:t||Z.test(n)?`document`:`unknown`}var Rl=new Map;function zl(e){return Rl.has(e)||Rl.set(e,new Promise(t=>{let n=new Image;n.onload=()=>t(`image`),n.onerror=()=>{fetch(e,{method:`HEAD`}).then(e=>t(String(e.headers.get(`content-type`)??``).startsWith(`video/`)?`video`:`drop`)).catch(()=>t(`drop`))},n.src=e})),Rl.get(e)}function Bl(e,t=0){let[n,r]=(0,l.useState)({}),i=e.filter(e=>e.kind===`unknown`&&!(e.src in n)).map(e=>e.src).join(`|`);return(0,l.useEffect)(()=>{if(!i||typeof window>`u`)return;let e=!0;return i.split(`|`).forEach(t=>{zl(t).then(n=>e&&r(e=>({...e,[t]:n})))}),()=>{e=!1}},[i]),e.map(e=>{if(e.kind!==`unknown`)return e;let t=n[e.src]??`image`;return t===`drop`?null:{...e,kind:t,thumb:t===`video`?Hl(e.src,`video`,e.poster):e.thumb}}).filter(Boolean).slice(0,Math.max(0,Number(t)||0)||void 0).map((e,t)=>({...e,index:t+1}))}var Vl=e=>e===`video`||e===`youtube`||e===`vimeo`;function Hl(e,t,n){return n||(t===`image`||t===`unknown`?e:t===`youtube`?`https://i.ytimg.com/vi/${Gr(e)}/hqdefault.jpg`:Il)}var Ul=e=>e==null?``:qn(e),Wl=e=>(Array.isArray(e)?e:[e]).map(e=>e&&typeof e==`object`?{url:e.url??e.src??``,mime:e.mime??``}:{url:e,mime:``}).filter(e=>typeof e.url==`string`&&e.url.trim()),Gl=e=>{try{return decodeURIComponent(String(e).split(/[?#]/)[0].split(`/`).pop()??``)}catch{return``}};function Kl({items:e,entries:t,mediaField:n,nameField:r,posterField:i,limit:a}){let o=Math.max(0,Number(a)||0),s=[],c=e=>o&&s.length>=o?!1:(s.push({...e,index:s.length+1}),!0);if(Array.isArray(t)){for(let e of t){if(!e||typeof e!=`object`)continue;let t=e.data??e,a=Ul(r?Gn(t,r):t.name),o=i?Wl(Gn(t,i))[0]?.url??``:``;for(let{url:r,mime:i}of Wl(Gn(t,n))){let t=Ll(r,i);if(t!==`document`&&!c({src:r,kind:t,poster:o,thumb:Hl(r,t,o),name:a,alt:a,entry:e}))return s}}return s}for(let t of Array.isArray(e)?e:[]){if(!t||typeof t!=`object`||!t.src)continue;let e=Ll(t.src,t.mime),n=t.name||``;if(e!==`document`&&!c({src:t.src,kind:e,poster:t.poster,thumb:Hl(t.src,e,t.poster),name:n,alt:t.alt||n,entry:null}))break}return s}function ql(e){let t=e.entry&&typeof e.entry==`object`?e.entry:{id:`item-${e.index}`};return{...t,data:{...t.data??{},src:e.src,thumb:e.thumb,name:e.name||Gl(e.src),kind:Vl(e.kind)?`video`:`image`,index:e.index}}}function Jl({item:e}){return(0,W.jsxs)(`span`,{...K(`tile-media`),style:{position:`relative`,display:`block`,borderRadius:`inherit`,overflow:`hidden`},children:[(0,W.jsx)(`img`,{...K(`thumb`),src:e.thumb,alt:e.alt||``,loading:`lazy`,style:{display:`block`,width:`100%`,aspectRatio:`1 / 1`,objectFit:`cover`,borderRadius:`inherit`}}),Vl(e.kind)&&(0,W.jsx)(Yl,{})]})}function Yl(){return(0,W.jsx)(`span`,{...K(`play`),"aria-hidden":`true`,style:{position:`absolute`,left:`50%`,top:`50%`,width:44,height:44,marginLeft:-22,marginTop:-22,borderRadius:`50%`,background:`rgba(0, 0, 0, 0.55)`,display:`flex`,alignItems:`center`,justifyContent:`center`,pointerEvents:`none`},children:(0,W.jsx)(`svg`,{width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`#fff`,children:(0,W.jsx)(`path`,{d:`M8 5v14l11-7z`})})})}function Xl({item:e,autoplay:t}){let n={maxWidth:`92vw`,maxHeight:`80vh`,borderRadius:8,boxShadow:`0 12px 48px rgba(0,0,0,0.5)`,display:`block`};if(e.kind===`youtube`||e.kind===`vimeo`){let r=e.kind===`youtube`?`https://www.youtube-nocookie.com/embed/${Gr(e.src)}?rel=0${t?`&autoplay=1`:``}`:`https://player.vimeo.com/video/${e.src.match(Q)?.[1]}${t?`?autoplay=1`:``}`;return(0,W.jsx)(`iframe`,{...K(`media`),src:r,title:e.name||`Video`,allow:`autoplay; encrypted-media; fullscreen; picture-in-picture`,allowFullScreen:!0,style:{...n,width:`min(92vw, calc(80vh * 16 / 9))`,aspectRatio:`16 / 9`,border:0,background:`#000`}})}return e.kind===`video`?(0,W.jsx)(`video`,{...K(`media`),src:e.src,poster:e.thumb===Il?void 0:e.thumb,controls:!0,autoPlay:t,playsInline:!0,style:{...n,background:`#000`}}):(0,W.jsx)(`img`,{...K(`media`),src:e.src,alt:e.alt||``,style:n})}var Zl={position:`absolute`,top:`50%`,transform:`translateY(-50%)`,width:48,height:48,borderRadius:`50%`,border:0,background:`rgba(255, 255, 255, 0.12)`,color:`inherit`,cursor:`pointer`,display:`flex`,alignItems:`center`,justifyContent:`center`};function Ql({list:e,index:t,onIndex:n,onClose:r,options:i,locale:a}){let o=Xe(a),{loop:s=!0,caption:c=!0,counter:u=!0,thumbs:d=!1,backdrop:f=``,color:p=``,autoplay:m=!0}=i,h=e[t],g=(0,l.useRef)(null),_=e.length,v=s||t>0,y=s||t<_-1,b=e=>n(t=>{let n=t+e;return s?(n+_)%_:Math.min(Math.max(n,0),_-1)});if((0,l.useEffect)(()=>{let e=e=>{e.key===`Escape`&&r(),e.key===`ArrowRight`&&b(1),e.key===`ArrowLeft`&&b(-1)},t=document.body,n=t.style.overflow;return window.addEventListener(`keydown`,e),t.style.overflow=`hidden`,g.current?.focus(),()=>{window.removeEventListener(`keydown`,e),t.style.overflow=n}},[_,s]),!h)return null;let x=e=>e.stopPropagation(),S=h.name||Gl(h.src);return(0,W.jsxs)(`div`,{...K(`backdrop`),role:`dialog`,"aria-modal":`true`,"aria-label":o(`gallery`),onClick:r,style:{position:`fixed`,inset:0,zIndex:2147483e3,background:f||`rgba(0, 0, 0, 0.88)`,color:p||`#fff`,display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,padding:24,gap:12},children:[(0,W.jsx)(`div`,{...K(`stage`),onClick:x,style:{display:`flex`,alignItems:`center`,justifyContent:`center`},children:(0,W.jsx)(Xl,{item:h,autoplay:m},t)}),(c&&S||u&&_>1)&&(0,W.jsxs)(`div`,{onClick:x,style:{display:`flex`,gap:12,alignItems:`baseline`,fontSize:14},children:[c&&S&&(0,W.jsx)(`span`,{...K(`caption`),style:{opacity:.9},children:S}),u&&_>1&&(0,W.jsx)(`span`,{...K(`counter`),style:{opacity:.6,fontVariantNumeric:`tabular-nums`},children:o(`itemOf`,{n:t+1,total:_})})]}),d&&_>1&&(0,W.jsx)(`div`,{...K(`thumbs`),onClick:x,style:{display:`flex`,gap:6,maxWidth:`92vw`,overflowX:`auto`,padding:4},children:e.map((e,r)=>(0,W.jsx)(`button`,{type:`button`,...K(`thumb-button`,r===t&&`thumb-button-active`),"aria-label":o(`itemOf`,{n:r+1,total:_}),"aria-current":r===t||void 0,onClick:()=>n(r),style:{flexShrink:0,padding:0,border:`2px solid ${r===t?`currentColor`:`transparent`}`,borderRadius:6,background:`none`,cursor:`pointer`,opacity:r===t?1:.6},children:(0,W.jsx)(`img`,{src:e.thumb,alt:``,style:{display:`block`,width:56,height:42,objectFit:`cover`,borderRadius:4}})},r))}),(0,W.jsx)(`button`,{ref:g,type:`button`,...K(`close-button`),"aria-label":o(`close`),onClick:r,style:{position:`absolute`,top:16,right:16,width:44,height:44,borderRadius:`50%`,border:0,background:`rgba(255, 255, 255, 0.12)`,color:`inherit`,cursor:`pointer`,fontSize:24,lineHeight:1},children:`×`}),_>1&&(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`button`,{type:`button`,...K(`arrow`,`arrow-prev`),"aria-label":o(`prevItem`),disabled:!v,onClick:e=>{x(e),b(-1)},style:{...Zl,left:16,opacity:v?1:.3},children:(0,W.jsx)(`svg`,{width:`22`,height:`22`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2.2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,W.jsx)(`path`,{d:`M15 18l-6-6 6-6`})})}),(0,W.jsx)(`button`,{type:`button`,...K(`arrow`,`arrow-next`),"aria-label":o(`nextItem`),disabled:!y,onClick:e=>{x(e),b(1)},style:{...Zl,right:16,opacity:y?1:.3},children:(0,W.jsx)(`svg`,{width:`22`,height:`22`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2.2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,W.jsx)(`path`,{d:`M9 18l6-6-6-6`})})})]})]})}function $l(e,t,n){let[r,i]=(0,l.useState)(null);return{open:i,overlay:r!==null&&e[r]&&typeof document<`u`?(0,mt.createPortal)((0,W.jsx)(Ql,{list:e,index:r,onIndex:i,onClose:()=>i(null),options:t,locale:n}),document.body):null}}function eu(e,t,n){return{role:`button`,tabIndex:0,"aria-label":Xe(n)(`openItem`,{name:t}),onClick:t=>{t.target?.closest?.(`a[href]`)||e()},onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),e())}}}function tu(e){let{tenant:t,apiUrl:n,revision:r,locale:i}=(0,l.useContext)(G),a=(0,l.useContext)(Nn)?.[e],[o,s]=(0,l.useState)(null);return(0,l.useEffect)(()=>{if(!e||a)return;let r=!0,o=new URLSearchParams({all:`1`,...i?{locale:i}:{}});return fetch(`${n}/dynamic/${encodeURIComponent(e)}?${o}`,{headers:t?{"x-tenant":t}:{}}).then(e=>e.json()).then(e=>{let t=Array.isArray(e?.payload)?e.payload:Array.isArray(e?.payload?.data)?e.payload.data:[];r&&s(t.filter(e=>e&&typeof e==`object`))}).catch(()=>r&&s([])),()=>{r=!1}},[r,e,t,n,i,a]),e?a??o:null}var nu=(e,t)=>t?e.filter(e=>e?.id===t||e?.data?.slug===t||e?.slug===t):e,ru=(e,t)=>({display:`grid`,gridTemplateColumns:`repeat(${Math.min(Math.max(Number(e)||4,1),8)}, minmax(0, 1fr))`,gap:t===``||t==null||!Number.isFinite(Number(t))?12:Math.max(0,Number(t))}),iu=e=>({loop:e.loop!==!1,caption:e.caption!==!1,counter:e.counter!==!1,thumbs:!!e.thumbs,autoplay:e.autoplay!==!1,backdrop:e.backdrop||``,color:e.color||``});function au(e){let{items:t=[],source:n=``,entry:r=``,mediaField:i=``,nameField:a=``,posterField:o=``,limit:s=0,emptyText:c=``,columns:u=4,gap:d=``,templateId:f,renderTemplate:p,style:m,nodeRef:h,inert:g}=e,{locale:_}=(0,l.useContext)(G),v=(0,l.useContext)(Ln),y=(0,l.useContext)(Rn),b=tu(n),x=Bl(Kl({items:t,entries:n?nu(b??[],r):null,mediaField:i,nameField:a,posterField:o}),s),{open:S,overlay:C}=$l(x,iu(e),_),w=p??(f&&v?.render?e=>v.render(f,e):null),T=!!n&&b===null;return(0,W.jsxs)(`div`,{ref:h,...K(`grid`),style:{width:`100%`,...ru(u,d),...z(m)},children:[x.map(t=>{let n=ql(t);return(0,W.jsx)(`div`,{...K(`item`,Vl(t.kind)&&`item-video`),...g?null:eu(()=>S(t.index-1),n.data.name,_),style:{minWidth:0,position:`relative`,cursor:g?void 0:`zoom-in`},children:w?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Rn.Provider,{value:{...y??{},entry:n},children:w(e=>er(e,n,_))}),e.playMark!==!1&&Vl(t.kind)&&(0,W.jsx)(Yl,{})]}):(0,W.jsx)(Jl,{item:t})},`${t.index}-${t.src}`)}),!x.length&&!T&&(n?c:null)&&(0,W.jsx)(`div`,{...K(`empty`),style:{gridColumn:`1 / -1`,padding:`24px 12px`,fontSize:13,opacity:.55,textAlign:`center`},children:c}),C]})}var ou={LightboxGallery:au},su=new Map;function cu(e){if(su.has(e))return su.get(e);let t=URL.createObjectURL(new Blob([e],{type:`text/javascript`})),n=import(t).finally(()=>URL.revokeObjectURL(t));return su.set(e,n),n}function lu(e){let t=e&&typeof e==`object`?e.builder_plugins:null,n=t&&typeof t==`object`?t.plugins:null;return n&&typeof n==`object`?n:{}}async function uu(e,t){let n=await cu(e);return(Array.isArray(n?.default?.blocks)?n.default.blocks:[]).find(e=>e?.id===t&&typeof e.mount==`function`)??null}var du={padding:`10px 12px`,border:`1px dashed rgba(148, 163, 184, 0.5)`,borderRadius:8,fontSize:12,opacity:.6};function fu({pluginId:e,blockId:t,props:n,style:r,nodeRef:i}){let a=(0,l.useContext)(G),o=lu(a?.settings)[e],s=(0,l.useRef)(null),c=(0,l.useRef)(null),u={tenant:a?.tenant??``,apiUrl:a?.apiUrl??`/api`,locale:a?.locale??``,settings:a?.settings??null},d=(0,l.useRef)(u);d.current=u;let f=JSON.stringify(n??{});return(0,l.useEffect)(()=>{let e=s.current;if(!o?.code||!e)return;let n=!0;return uu(o.code,t).then(e=>{if(!(!n||!e||!s.current)){c.current=e;try{e.mount(s.current,JSON.parse(f),d.current)}catch{c.current=null}}}).catch(()=>{}),()=>{n=!1;let t=c.current;c.current=null;try{t?.unmount?.(e)}catch{}e&&(e.innerHTML=``)}},[o?.code,t]),(0,l.useEffect)(()=>{let e=c.current,t=s.current;if(!(!e||!t))try{e.update?e.update(t,JSON.parse(f),d.current):(e.unmount?.(t),t.innerHTML=``,e.mount(t,JSON.parse(f),d.current))}catch{}},[f]),o?(0,W.jsx)(`div`,{ref:i,style:z(r),children:(0,W.jsx)(`div`,{ref:s})}):(0,W.jsxs)(`div`,{ref:i,style:{...du,...z(r)},children:[`Plugin “`,e,`” is not installed`]})}function pu(e,t,n){let r={"data-wb":e};t.htmlId&&(r.id=t.htmlId),n&&n.id===e&&(r.id=t.htmlId||n.htmlId,r.tabIndex=-1);let i=V(t.classNames);i.length&&(r[`data-wb-class`]=i.join(` `));for(let e of Array.isArray(t.attributes)?t.attributes:[]){let t=String(e?.name??``).trim();B(t)&&(r[t===`tabindex`?`tabIndex`:t]=e.value??``)}return{attrs:r,classes:i}}function mu({View:e,markup:t,...n}){let r=e(n);if(!(0,l.isValidElement)(r)||typeof r.type!=`string`)return r;let i=[r.props.className,...t.classes].filter(Boolean).join(` `);return(0,l.cloneElement)(r,{...t.attrs,...i?{className:i}:{}})}var hu=new Set([`FormInput`,`FormTextarea`,`FormSelect`]);function gu(e,t,n,r){if(t.forNode===`__none`)return``;let i=t.forNode?n[t.forNode]:null;if(!t.forNode){let t=n[r]?.nodes??[];i=n[t[t.indexOf(e)+1]]??null}return!i||!hu.has(i.type?.resolvedName)?``:i.props?.htmlId||na(i.props?.name)||``}var _u=`slot-`,vu={...Do,...Nc,...hl,...Pl,...ou,PluginBlock:fu};function yu(e,t,n,r=new Set,i=void 0){let a=t[e];if(!a||a.hidden)return null;let o=a.type?.resolvedName,s=i?.mapProps?i.mapProps(a.props??{},o):a.props??{};if(o===`ComponentInstance`){let o=a.props?.componentId,c=n?.[o];if(!c?.template||r.has(o))return null;let u=new Set(r).add(o),d=Object.fromEntries(Object.entries(a.linkedNodes??{}).filter(([e])=>e.startsWith(_u)).map(([e,a])=>[e.slice(5),yu(a,t,n,r,i)]));return(0,W.jsx)(l.Fragment,{children:yu(c.template.rootId,c.template.nodes,n,u,{...pt(s.values,i),slots:d})},e)}let c=vu[o];if(!c)return null;let u=s.compSlot?.id,d=u&&i?.slots&&Object.hasOwn(i.slots,u)?i.slots[u]:void 0,f=d===void 0?(a.nodes??[]).map(e=>yu(e,t,n,r,i)).filter(Boolean):[d].filter(Boolean),p=Object.entries(a.linkedNodes??{}),m=p.length?Object.fromEntries(p.map(([e,a])=>[e,yu(a,t,n,r,i)])):void 0,h=(0,W.jsx)(typeof c==`function`?mu:c,{...typeof c==`function`?{View:c,markup:pu(e,s,i?.skipTarget)}:null,...s,...o===`CollectionList`?{templateId:a.linkedNodes?.card,renderTemplate:a.linkedNodes?.card?e=>yu(a.linkedNodes.card,t,n,r,{...i,mapProps:i?.mapProps?(t,n)=>i.mapProps(e(t,n),n):e}):void 0}:null,...o===`LightboxGallery`&&a.linkedNodes?.item?{renderTemplate:e=>yu(a.linkedNodes.item,t,n,r,{...i,mapProps:i?.mapProps?(t,n)=>i.mapProps(e(t,n),n):e})}:null,...o===`FormLabel`?{htmlFor:gu(e,s,t,a.parent)}:null,linked:m,nodeRef:t=>{t&&(t.setAttribute(`data-wb`,e),ce(t,s),i?.skipTarget?.id===e&&(t.id=s.htmlId||i.skipTarget.htmlId,t.tabIndex=-1),se(t,i?.events===!1?[]:s.events))},children:f.length?f:void 0},e),g=s.when&&s.when!==`always`?(0,W.jsx)(Lo,{when:s.when,children:h},e):h;return Array.isArray(s.showWhen?.rules)&&s.showWhen.rules.length?(0,W.jsx)(Un,{showWhen:s.showWhen,children:g},e):g}var bu=e=>Object.entries(e).map(([e,t])=>`${e}: ${t};`).join(` `),xu=e=>`.webim-page[data-webim-mode="light"] { ${Object.entries(Pe(e.light)).map(([e,t])=>`${e}: ${t} !important;`).join(` `)} }
111
+ .webim-page[data-webim-mode="dark"] { ${Object.entries(Pe(e.dark)).map(([e,t])=>`${e}: ${t} !important;`).join(` `)} }`;function Su({blocks:e,theme:t,components:n,mode:r=`auto`,style:i,custom:a,animations:o,tenant:s,apiUrl:c,datasets:u,locale:d,direction:f,settings:p,siteUser:m,param:g}){let _=a?.js?.trim(),y=p&&p[`site.code`]&&typeof p[`site.code`]==`object`?p[`site.code`]:null,b=typeof y?.js==`string`?y.js.trim():``,x=typeof y?.css==`string`?y.css.trim():``;if((0,l.useEffect)(()=>{if(!b)return;let e=document.createElement(`script`);return e.text=b,document.body.appendChild(e),()=>e.remove()},[b]),(0,l.useEffect)(()=>{if(!_)return;let e=document.createElement(`script`);return e.text=_,document.body.appendChild(e),()=>e.remove()},[_]),!e?.ROOT)return null;let S={lang:d||void 0,dir:ct(f,d)},C=`.webim-page, .webim-page *, .webim-page *::before, .webim-page *::after { box-sizing: border-box; }
112
112
  `+we+`
113
- `+Qe,w={minHeight:`100%`,display:`flex`,flexDirection:`column`},T=at(e,n),E=Wl(`ROOT`,e,n,void 0,T?{skipTarget:T}:void 0),D=T?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`style`,{children:$e}),(0,W.jsx)(`a`,{className:`webim-skip`,href:`#${T.htmlId}`,children:Xe(d||p?.locales?.default)(`skip`)})]}):null,O=(0,l.useMemo)(()=>({render:(t,r)=>Wl(t,e,n,void 0,{mapProps:r})}),[e,n]),k=Ce(e,n),A=Se(e,n),j=a?.css?.trim(),M=F(o),N=Ne(t),P=[N.font,N.headingFont].filter(e=>typeof e==`string`&&e.trim()&&e!==`inherit`&&!Ae[e]),I=[...new Set([...v(e,n),...P])].map(e=>(0,W.jsx)(`link`,{rel:`stylesheet`,precedence:`default`,href:h(e)},e)),L=Kl(N),R=ze(t);return r===`auto`?(0,W.jsx)(Nn.Provider,{value:{tenant:s||``,apiUrl:c||`/api`,locale:d||``,settings:p??null,param:g||``},children:(0,W.jsx)(Io,{initialUser:m,children:(0,W.jsx)(Pn.Provider,{value:u??null,children:(0,W.jsx)(Rn.Provider,{value:O,children:(0,W.jsxs)(`div`,{...S,className:`webim-page`,style:{...w,...Fe(t),...i},children:[D,(0,W.jsx)(`style`,{children:`.webim-page { ${Gl(Pe(N.light))} }
114
- @media (prefers-color-scheme: dark) { .webim-page { ${Gl(Pe(N.dark))} } }`}),(0,W.jsx)(`style`,{children:L}),I,(0,W.jsx)(`style`,{children:C}),R&&(0,W.jsx)(`style`,{children:R}),k&&(0,W.jsx)(`style`,{children:k}),A&&(0,W.jsx)(`style`,{children:A}),M&&(0,W.jsx)(`style`,{children:M}),x&&(0,W.jsx)(`style`,{children:x}),j&&(0,W.jsx)(`style`,{children:j}),E]})})})})}):(0,W.jsx)(Nn.Provider,{value:{tenant:s||``,apiUrl:c||`/api`,locale:d||``,settings:p??null,param:g||``},children:(0,W.jsx)(Io,{initialUser:m,children:(0,W.jsx)(Pn.Provider,{value:u??null,children:(0,W.jsx)(Rn.Provider,{value:O,children:(0,W.jsxs)(`div`,{...S,className:`webim-page`,style:{...w,...He(t,r),...i},children:[D,I,(0,W.jsx)(`style`,{children:L}),(0,W.jsx)(`style`,{children:C}),R&&(0,W.jsx)(`style`,{children:R}),k&&(0,W.jsx)(`style`,{children:k}),A&&(0,W.jsx)(`style`,{children:A}),M&&(0,W.jsx)(`style`,{children:M}),x&&(0,W.jsx)(`style`,{children:x}),j&&(0,W.jsx)(`style`,{children:j}),E]})})})})})}function Jl({bundle:e,mode:t=`auto`,style:n}){return e?.blocks?.ROOT?(0,W.jsx)(ql,{blocks:e.blocks,theme:e.theme,components:e.components,custom:e.custom,animations:e.animations,tenant:e.tenant,apiUrl:e.apiUrl,datasets:e.datasets,locale:e.locale,direction:e.direction,settings:e.settings,param:e.param,mode:We(t,e.scheme),style:n}):null}function Yl({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a,mode:o=`auto`,style:s,fallback:c=null,errorFallback:u=null,onLoad:d,onError:f}){let[p,m]=(0,l.useState)({status:`loading`}),h=(0,l.useRef)({onLoad:d,onError:f});return h.current={onLoad:d,onError:f},(0,l.useEffect)(()=>{let o=!0;return m({status:`loading`}),qe({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a}).then(e=>{o&&(m({status:`ready`,bundle:e}),h.current.onLoad?.(e))}).catch(e=>{o&&(m({status:`error`,error:e}),h.current.onError?.(e))}),()=>{o=!1}},[e,t,n,r,i,a]),p.status===`loading`?c:p.status===`error`?typeof u==`function`?u(p.error):u:(0,W.jsx)(Jl,{bundle:p.bundle,mode:o,style:s})}function Xl(e,t={}){let n=(0,u.createRoot)(e);return n.render((0,W.jsx)(Yl,{apiUrl:t.apiUrl||t.api,tenant:t.tenant,slug:t.slug,locale:t.locale||void 0,token:t.token||void 0,mode:t.mode||`auto`,onError:e=>console.error(`[webim-embed]`,t.slug,e)})),n}function Zl(e=document){for(let t of e.querySelectorAll(`[data-webim-page]:not([data-webim-mounted])`))t.setAttribute(`data-webim-mounted`,``),Xl(t,t.dataset)}var Ql=document.currentScript,$l=()=>{if(Zl(),Ql?.dataset.slug){let e=document.createElement(`div`);e.setAttribute(`data-webim-mounted`,``),Ql.parentElement&&Ql.parentElement!==document.head?Ql.insertAdjacentElement(`beforebegin`,e):document.body.appendChild(e),Xl(e,Ql.dataset)}};document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,$l,{once:!0}):$l(),window.WebimEmbed={mount:Xl,scan:Zl}})();
113
+ `+Qe,w={minHeight:`100%`,display:`flex`,flexDirection:`column`},T=at(e,n),E=yu(`ROOT`,e,n,void 0,T?{skipTarget:T}:void 0),D=T?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`style`,{children:$e}),(0,W.jsx)(`a`,{className:`webim-skip`,href:`#${T.htmlId}`,children:Xe(d||p?.locales?.default)(`skip`)})]}):null,O=(0,l.useMemo)(()=>({render:(t,r)=>yu(t,e,n,void 0,{mapProps:r})}),[e,n]),k=Ce(e,n),A=Se(e,n),j=a?.css?.trim(),M=F(o),N=Ne(t),P=[N.font,N.headingFont].filter(e=>typeof e==`string`&&e.trim()&&e!==`inherit`&&!Ae[e]),I=[...new Set([...v(e,n),...P])].map(e=>(0,W.jsx)(`link`,{rel:`stylesheet`,precedence:`default`,href:h(e)},e)),L=xu(N),R=ze(t);return r===`auto`?(0,W.jsx)(G.Provider,{value:{tenant:s||``,apiUrl:c||`/api`,locale:d||``,settings:p??null,param:g||``},children:(0,W.jsx)(Io,{initialUser:m,children:(0,W.jsx)(Nn.Provider,{value:u??null,children:(0,W.jsx)(Ln.Provider,{value:O,children:(0,W.jsxs)(`div`,{...S,className:`webim-page`,style:{...w,...Fe(t),...i},children:[D,(0,W.jsx)(`style`,{children:`.webim-page { ${bu(Pe(N.light))} }
114
+ @media (prefers-color-scheme: dark) { .webim-page { ${bu(Pe(N.dark))} } }`}),(0,W.jsx)(`style`,{children:L}),I,(0,W.jsx)(`style`,{children:C}),R&&(0,W.jsx)(`style`,{children:R}),k&&(0,W.jsx)(`style`,{children:k}),A&&(0,W.jsx)(`style`,{children:A}),M&&(0,W.jsx)(`style`,{children:M}),x&&(0,W.jsx)(`style`,{children:x}),j&&(0,W.jsx)(`style`,{children:j}),E]})})})})}):(0,W.jsx)(G.Provider,{value:{tenant:s||``,apiUrl:c||`/api`,locale:d||``,settings:p??null,param:g||``},children:(0,W.jsx)(Io,{initialUser:m,children:(0,W.jsx)(Nn.Provider,{value:u??null,children:(0,W.jsx)(Ln.Provider,{value:O,children:(0,W.jsxs)(`div`,{...S,className:`webim-page`,style:{...w,...He(t,r),...i},children:[D,I,(0,W.jsx)(`style`,{children:L}),(0,W.jsx)(`style`,{children:C}),R&&(0,W.jsx)(`style`,{children:R}),k&&(0,W.jsx)(`style`,{children:k}),A&&(0,W.jsx)(`style`,{children:A}),M&&(0,W.jsx)(`style`,{children:M}),x&&(0,W.jsx)(`style`,{children:x}),j&&(0,W.jsx)(`style`,{children:j}),E]})})})})})}function Cu({bundle:e,mode:t=`auto`,style:n}){return e?.blocks?.ROOT?(0,W.jsx)(Su,{blocks:e.blocks,theme:e.theme,components:e.components,custom:e.custom,animations:e.animations,tenant:e.tenant,apiUrl:e.apiUrl,datasets:e.datasets,locale:e.locale,direction:e.direction,settings:e.settings,param:e.param,mode:We(t,e.scheme),style:n}):null}function wu({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a,mode:o=`auto`,style:s,fallback:c=null,errorFallback:u=null,onLoad:d,onError:f}){let[p,m]=(0,l.useState)({status:`loading`}),h=(0,l.useRef)({onLoad:d,onError:f});return h.current={onLoad:d,onError:f},(0,l.useEffect)(()=>{let o=!0;return m({status:`loading`}),qe({apiUrl:e,tenant:t,slug:n,locale:r,preview:i,token:a}).then(e=>{o&&(m({status:`ready`,bundle:e}),h.current.onLoad?.(e))}).catch(e=>{o&&(m({status:`error`,error:e}),h.current.onError?.(e))}),()=>{o=!1}},[e,t,n,r,i,a]),p.status===`loading`?c:p.status===`error`?typeof u==`function`?u(p.error):u:(0,W.jsx)(Cu,{bundle:p.bundle,mode:o,style:s})}function Tu(e,t={}){let n=(0,u.createRoot)(e);return n.render((0,W.jsx)(wu,{apiUrl:t.apiUrl||t.api,tenant:t.tenant,slug:t.slug,locale:t.locale||void 0,token:t.token||void 0,mode:t.mode||`auto`,onError:e=>console.error(`[webim-embed]`,t.slug,e)})),n}function Eu(e=document){for(let t of e.querySelectorAll(`[data-webim-page]:not([data-webim-mounted])`))t.setAttribute(`data-webim-mounted`,``),Tu(t,t.dataset)}var Du=document.currentScript,Ou=()=>{if(Eu(),Du?.dataset.slug){let e=document.createElement(`div`);e.setAttribute(`data-webim-mounted`,``),Du.parentElement&&Du.parentElement!==document.head?Du.insertAdjacentElement(`beforebegin`,e):document.body.appendChild(e),Tu(e,Du.dataset)}};document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,Ou,{once:!0}):Ou(),window.WebimEmbed={mount:Tu,scan:Eu}})();