smbls 3.14.822 → 3.14.824

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/smbls.cjs CHANGED
@@ -1,36 +1,36 @@
1
- "use strict";var XA=Object.create;var al=Object.defineProperty;var ZA=Object.getOwnPropertyDescriptor;var JA=Object.getOwnPropertyNames;var QA=Object.getPrototypeOf,tT=Object.prototype.hasOwnProperty;var V=(t,e,r)=>()=>{if(r)throw r[0];try{return t&&(e=t(t=0)),e}catch(n){throw r=[n],n}};var lp=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}},$=(t,e)=>{for(var r in e)al(t,r,{get:e[r],enumerable:!0})},Dw=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of JA(e))!tT.call(t,o)&&o!==r&&al(t,o,{get:()=>e[o],enumerable:!(n=ZA(e,o))||n.enumerable});return t};var eT=(t,e,r)=>(r=t!=null?XA(QA(t)):{},Dw(e||!t||!t.__esModule?al(r,"default",{value:t,enumerable:!0}):r,t)),rT=t=>Dw(al({},"__esModule",{value:!0}),t);var Tp,Op,E,st,ai=V(()=>{"use strict";Tp=globalThis,Op=globalThis,E=globalThis,st=E.document});var dr,ci,Zt,li=V(()=>{"use strict";ai();dr=t=>(typeof Node=="object"?t instanceof E.Node:t&&typeof t=="object"&&typeof t.nodeType=="number"&&typeof t.nodeName=="string")||!1,ci=t=>(typeof HTMLElement=="object"?t instanceof E.HTMLElement:t&&typeof t=="object"&&t!==null&&t.nodeType===1&&typeof t.nodeName=="string")||!1,Zt=t=>typeof E<"u"&&(E.Node&&t instanceof E.Node||E.Window&&t instanceof E.Window||t===E||st!==void 0&&t===st)});var v,k,Ke,R,bl,_l,P,wl,B,Tt,Lt,fi,Jt,Rp,It=V(()=>{"use strict";li();v=t=>t===null?!1:typeof t=="object"&&t.constructor===Object,k=t=>typeof t=="string",Ke=t=>typeof t=="number",R=t=>typeof t=="function",bl=t=>t===!0||t===!1,_l=t=>t===null,P=t=>Array.isArray(t),wl=t=>t instanceof Date,B=t=>t===null?!1:typeof t=="object",Tt=t=>t!==void 0,Lt=t=>t===void 0,fi={boolean:bl,array:P,object:v,string:k,date:wl,number:Ke,null:_l,function:R,objectLike:B,node:dr,htmlElement:ci,defined:Tt},Jt=t=>(...e)=>e.some(r=>fi[r](t)),Rp=t=>(...e)=>!e.some(r=>fi[r](t))});var Pp,Dp,Lp,Ip,ko,ui,$p,Mp,di,Fp,Np,jp,Bp,Vp,Up,zp,vo,pi,Co=V(()=>{"use strict";pr();It();Pp=(t,e)=>e.every(r=>t.includes(r)),Dp=(t,e)=>{let r=0;for(let n=0;n<t.length;n++)t[n]===e&&r++;return r},Lp=(t,e)=>{if(k(e)&&(e=parseInt(e)),Ke(e)){if(e<0||e>=t.length||isNaN(e))throw new Error("Invalid index");t.splice(e,1)}else throw new Error("Invalid index");return t},Ip=(t,e,r)=>{e<0||r<0||e>=t.length||r>=t.length||([t[e],t[r]]=[t[r],t[e]])},ko=(...t)=>[].concat(...t),ui=(t,e=[])=>t.reduce((r,n)=>at(r,lt(n,{exclude:e}),e),{}),$p=(t,e)=>{let r=t.indexOf(e);return r!==-1?t.slice(0,r):t},Mp=(t,e)=>{if(!P(t))return;let r=t.indexOf(e);return r!==-1?t.slice(r+1):t},di=(t,e)=>{let r=t.indexOf(e);if(r>-1){let n=[...t];return n.splice(r,1),n}return t},Fp=(t,e)=>t.filter(r=>r!==e),Np=(t,e)=>{let r=[];for(let n=0;n<t.length;n++)r.push(t[n]),n<t.length-1&&r.push(e);return r},jp=(t,e,r)=>{let n=[...t],o=n.indexOf(e),s=n.indexOf(r);if(o!==-1&&s!==-1){let i=n.splice(o,1)[0],a=s<o?s:s+1;n.splice(a,0,i)}return n},Bp=(t,e)=>{if(t.length!==e.length)return!1;for(let r=0;r<t.length;r++)if(t[r]!==e[r])return!1;return!0},Vp=(t,e)=>t.filter(r=>!e.includes(r)),Up=(t,e)=>{let r=new Set(e);return t.filter(n=>!r.has(n))},zp=(t,e)=>{if(!t)return 0;let r=0;for(let n=0;n<e.length;n++)t.includes(e[n])&&r++;return r},vo=t=>P(t)?[...new Set(t)]:t,pi=(t,e)=>{for(let r in e)Object.defineProperty(t,r,{value:e[r],enumerable:!1,configurable:!0,writable:!0})}});function Ft(t,e,r={}){let{bracketsLength:n=2,authored:o=!1}=r,s=n===3?"{{{":"{{";if(!t.includes(s)||o!==!0&&!wT(this,t))return t;let i=_T[n],a=e||this.state||{},c=this;return t.replace(i,(l,f,u,d)=>{let g=u.trim();if(d){let p=c?.context,h=p?.functions?.[d]||p?.utils?.[d]||p?.methods?.[d]||p?.snippets?.[d]||c?.[d];if(h&&typeof h=="function")try{return String(h.call(c,g)??"")}catch{return""}return""}if(f){let p=(f.match(/\.\.\//g)||[]).length,h=a;for(let _=0;_<p;_++){if(!h||!h.parent)return"";h=h.parent}if(g==="parent")return String(h.value??"");let m=hi(h,g);return m!=null&&typeof m=="object"?"":String(m??"")}else{let p=hi(a,g);if(p!=null&&typeof p!="object")return String(p);let h=c?.context?.polyglot;if(h?.translations){let m=a?.root?.lang||a?.lang||c?.context?.state?.lang||h.defaultLang||"en",_=h.translations[m];if(_){let y=hi(_,g);if(y!=null&&typeof y!="object")return String(y);for(let b in _){let w=_[b];if(w&&typeof w=="object"&&!Array.isArray(w)){let S=hi(w,g);if(S!=null&&typeof S!="object")return String(S)}}}let x=hi(h.translations,g);if(x!=null&&typeof x!="object")return String(x)}return""}})}var gi,Hp,_T,hi,wT,xn,Wp,xT,qp,Kp,Gp,ST,Yp,Xp,mi=V(()=>{"use strict";gi=(t,e)=>{for(let r of e)if(t.includes(r))return!0;return!1},Hp=(t,e)=>{let r=new RegExp(`[${e.join("\\")}]`,"g");return t.replace(r,"")},_T={2:/{{\s*((?:\.\.\/)*)([\w\d.]+)\s*(?:\|\s*([\w\d.]+))?\s*}}/g,3:/{{{(\s*(?:\.\.\/)*)([\w\d.]+)\s*(?:\|\s*([\w\d.]+))?\s*}}}/g},hi=(t,e)=>e.split(".").reduce((r,n)=>r?.[n],t),wT=(t,e)=>{if(!t||!t.__ref)return!0;let r=t;for(;r;){if(r.allowRuntimeTemplates===!0)return!0;let n=r.__ref&&r.__ref.__authoredTemplates;if(n&&n.has(e))return!0;r=r.parent}return!1};xn=t=>`${t.charAt(0).toLowerCase()}${t.slice(1)}`,Wp=(t,e)=>{let r=t.split(`
2
- `),n=-1,o=-1,s=-1,i=-1,a=new RegExp(`\\b${e}\\b\\s*:\\s*`),c=0,l=!1;for(let f=0;f<r.length;f++)if(a.test(r[f])&&!l){if(l=!0,n=f+1,s=r[f].indexOf(e)+1,r[f].includes("{}")){o=n,i=r[f].indexOf("{}")+3;break}let u=r[f].slice(s+e.length);if(u.includes("{")||u.includes("["))c=1;else{o=f+1,i=r[f].length+1;break}}else if(l&&(c+=(r[f].match(/{/g)||[]).length,c+=(r[f].match(/\[/g)||[]).length,c-=(r[f].match(/}/g)||[]).length,c-=(r[f].match(/]/g)||[]).length,c===0)){o=f+1,i=r[f].lastIndexOf("}")!==-1?r[f].lastIndexOf("}")+2:r[f].length+1;break}return{startColumn:s,endColumn:i,startLineNumber:n,endLineNumber:o}},xT=/\\([0-7]{1,3})/g,qp=t=>t.replace(xT,(e,r)=>String.fromCharCode(parseInt(r,8))),Kp=t=>t.replace(/\n/g,"/////n").replace(/`/g,"/////tilde").replace(/\$/g,"/////dlrsgn"),Gp=t=>t.replace(/\/\/\/\/\/n/g,`
3
- `).replace(/\/\/\/\/\/tilde/g,"`").replace(/\/\/\/\/\/dlrsgn/g,"$"),ST=/[^a-zA-Z0-9\s]/g,Yp=t=>t.replace(ST,e=>"%"+e.charCodeAt(0).toString(16).toUpperCase()),Xp=t=>t.replace(/%[0-9A-Fa-f]{2}/g,e=>String.fromCharCode(parseInt(e.slice(1),16)))});var Mr,yi,Zp,Sn,Fr,Nr,Jp,Eo,kn,bi,Qp,vn=V(()=>{"use strict";Mr=new Set(["attr","style","text","html","content","data","classlist","state","scope","root","deps","extend","extends","$router","routes","children","childExtend","childExtends","childExtendRecursive","childExtendsRecursive","props","if","define","__name","__ref","__hash","__text","key","tag","query","parent","node","variables","on","fetch","component","context","preventContentUpdate","preventContentRecreate"]),yi=new Set(["attr","style","text","html","content","data","class","state","scope","children","props","if","key","tag","query","on","context"]),Zp=["ref","parent","__element","__depends","__ref","__children","root"],Sn=new Set(["update","parse","clean","create","destroy","add","toggle","remove","apply","set","reset","replace","quietReplace","quietUpdate","applyReplace","applyFunction","keys","values","ref","rootUpdate","parentUpdate","parent","__element","__depends","__ref","__children","root","setByPath","setPathCollection","removeByPath","removePathCollection","getByPath"]),Fr=new Set(["update","__element"]),Nr=new Set(["set","reset","update","remove","updateContent","removeContent","lookup","lookdown","lookdownAll","getRef","getPath","setNodeStyles","spotByPath","keys","parse","setProps","parseDeep","variables","if","log","verbose","warn","error","call","nextElement","previousElement","getRootState","getRoot","getRootData","getRootContext","getContext","getQuery","getDB","getChildren","preventContentUpdate","preventContentRecreate"]),Jp=t=>Nr.has(t),Eo=new Set(["log","warn","error","verbose"]),kn=t=>Nr.has(t)&&!Eo.has(t),bi=new Set(["node","context","extends","__element","__ref",...Nr,...Sn,...Fr]),Qp=new Set(["init","beforeClassAssign","render","renderRouter","attachNode","stateInit","stateCreated","beforeStateUpdate","stateUpdate","beforeUpdate","done","create","complete","frame","update","fetchError","fetchComplete"])});function FT(){let t=Cn.get(this);return t?t.src.trim():Function.prototype.toString.call(this)}var Hw,En,dt,eh,bt,at,Jw,rh,lt,wi,kT,vT,Ww,xi,CT,ET,AT,De,Qw,TT,xl,tx,th,Cn,OT,RT,PT,DT,LT,qw,IT,Kw,$T,Gw,Sl,MT,NT,jT,BT,Yw,nh,Le,An,VT,UT,be,ex,rx,nx,ox,sx,Xw,_i,Zw,Si,oh,sh,kl,ih,ah,ki,Tn,Wt,vl,zT,ch,lh,Cl,fh,uh,dh,ph,hh,gh,mh,pr=V(()=>{"use strict";ai();It();Co();mi();li();vn();Hw="production",En=t=>t.charCodeAt(0)===95&&t.charCodeAt(1)===95,dt=(t,e,r,n)=>{if(R(t))return e?typeof t.call!="function"?t:t.call(e,e,r||e.state,n||e.context):void 0;if(t!=null&&e?.context?.plugins&&(P(t)||v(t)&&!Zt(t))){let o=e.context.plugins;for(let s of o)if(s.resolveHandler){let i=s.resolveHandler(t,e);if(typeof i=="function")return dt(i,e,r,n)}}return t},eh=(t,e,r)=>{for(let n in e)t[n]=dt(e[n],r)},bt=(t,e,r=[])=>{let n=r instanceof Set;for(let o in e)Object.prototype.hasOwnProperty.call(e,o)&&(En(o)||(n?r.has(o):r.includes(o))||t[o]===void 0&&(t[o]=e[o]));return t},at=(t,e,r=bi)=>Jw(t,e,r,null),Jw=(t,e,r,n)=>{if(t===e)return t;if(n){for(let s=0;s<n.length;s+=2)if(n[s]===t&&n[s+1]===e)return t}let o=r instanceof Set;for(let s in e){if(!Object.prototype.hasOwnProperty.call(e,s)||En(s)||s==="constructor"||s==="prototype"||(o?r.has(s):r.includes(s)))continue;let i=t[s],a=e[s];if(B(i)&&B(a)){let c=n||[];c.push(t,e),Jw(i,a,r,c),c.length-=2}else i===void 0&&(t[s]=a)}return t},rh=(t,e=[])=>{let r=e instanceof Set,n={};for(let o in t)Object.prototype.hasOwnProperty.call(t,o)&&(En(o)||(r?e.has(o):e.includes(o))||(n[o]=t[o]));return n},lt=(t,e={})=>{let{exclude:r=[],cleanUndefined:n=!1,cleanNull:o=!1,visited:s=new WeakMap,handleExtends:i=!1}=e;if(!B(t)||Zt(t))return t;if(s.has(t))return s.get(t);let a=r instanceof Set?r:r.length>3?new Set(r):null,c=u=>a?a.has(u):r.includes(u),l=P(t)?[]:{};s.set(t,l);let f=[[t,l]];for(;f.length;){let[u,d]=f.pop();for(let g in u){if(!Object.prototype.hasOwnProperty.call(u,g)||En(g)||g==="__proto__"||c(g))continue;let p=u[g];if(!(n&&p===void 0)&&!(o&&p===null)){if(Zt(p)){d[g]=p;continue}if(i&&g==="extends"&&P(p)){d[g]=ui(p,r);continue}if(R(p)){d[g]=p;continue}if(B(p))if(s.has(p))d[g]=s.get(p);else{let h=P(p)?[]:{};s.set(p,h),d[g]=h,f.push([p,h])}else d[g]=p}}}return l},wi=(t,e={})=>{(t.node||t.__ref||t.parent||t.__element||t.parse)&&((t.__element||t.parent?.__element).warn("Trying to clone element or state at",t),t=t.parse?.());for(let r in t){let n=t[r];if(R(n))e[r]=n.toString();else if(v(n))e[r]={},wi(n,e[r]);else if(P(n)){let o=e[r]=[];for(let s=0;s<n.length;s++){let i=n[s];v(i)?(o[s]={},wi(i,o[s])):R(i)?o[s]=i.toString():o[s]=i}}else e[r]=n}return e},kT=/^[A-Za-z_$][A-Za-z0-9_$]*$/,vT=t=>`'${String(t).replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\r/g,"\\r").replace(/\n/g,"\\n")}'`,Ww=t=>{let e=String(t);return gi(e,[`
4
- `,"'"])?"`"+e.replace(/\\/g,"\\\\").replace(/`/g,"\\`").replace(/\$\{/g,"\\${")+"`":"'"+e.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\r/g,"\\r")+"'"},xi=(t={},e=0)=>{if(t===null||typeof t!="object"||t instanceof RegExp)return String(t);let r=!1;for(let s in t){r=!0;break}if(!r)return"{}";let n=" ".repeat(e),o=`{
5
- `;for(let s in t){if(!Object.prototype.hasOwnProperty.call(t,s))continue;let i=t[s],a=kT.test(s)?s:vT(s);if(o+=`${n} ${a}: `,i instanceof RegExp)o+=String(i);else if(P(i)){o+=`[
1
+ "use strict";var iT=Object.create;var ll=Object.defineProperty;var aT=Object.getOwnPropertyDescriptor;var cT=Object.getOwnPropertyNames;var lT=Object.getPrototypeOf,fT=Object.prototype.hasOwnProperty;var V=(t,e,r)=>()=>{if(r)throw r[0];try{return t&&(e=t(t=0)),e}catch(n){throw r=[n],n}};var up=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}},$=(t,e)=>{for(var r in e)ll(t,r,{get:e[r],enumerable:!0})},Nx=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of cT(e))!fT.call(t,o)&&o!==r&&ll(t,o,{get:()=>e[o],enumerable:!(n=aT(e,o))||n.enumerable});return t};var uT=(t,e,r)=>(r=t!=null?iT(lT(t)):{},Nx(e||!t||!t.__esModule?ll(r,"default",{value:t,enumerable:!0}):r,t)),dT=t=>Nx(ll({},"__esModule",{value:!0}),t);var Rp,Pp,C,st,li=V(()=>{"use strict";Rp=globalThis,Pp=globalThis,C=globalThis,st=C.document});var pr,fi,Zt,ui=V(()=>{"use strict";li();pr=t=>(typeof Node=="object"?t instanceof C.Node:t&&typeof t=="object"&&typeof t.nodeType=="number"&&typeof t.nodeName=="string")||!1,fi=t=>(typeof HTMLElement=="object"?t instanceof C.HTMLElement:t&&typeof t=="object"&&t!==null&&t.nodeType===1&&typeof t.nodeName=="string")||!1,Zt=t=>typeof C<"u"&&(C.Node&&t instanceof C.Node||C.Window&&t instanceof C.Window||t===C||st!==void 0&&t===st)});var v,k,Ge,R,xl,wl,P,Sl,B,Tt,Lt,di,Jt,Dp,It=V(()=>{"use strict";ui();v=t=>t===null?!1:typeof t=="object"&&t.constructor===Object,k=t=>typeof t=="string",Ge=t=>typeof t=="number",R=t=>typeof t=="function",xl=t=>t===!0||t===!1,wl=t=>t===null,P=t=>Array.isArray(t),Sl=t=>t instanceof Date,B=t=>t===null?!1:typeof t=="object",Tt=t=>t!==void 0,Lt=t=>t===void 0,di={boolean:xl,array:P,object:v,string:k,date:Sl,number:Ge,null:wl,function:R,objectLike:B,node:pr,htmlElement:fi,defined:Tt},Jt=t=>(...e)=>e.some(r=>di[r](t)),Dp=t=>(...e)=>!e.some(r=>di[r](t))});var Lp,Ip,$p,Mp,ko,pi,Fp,Np,hi,jp,Bp,Vp,Up,zp,Hp,Wp,vo,gi,Co=V(()=>{"use strict";hr();It();Lp=(t,e)=>e.every(r=>t.includes(r)),Ip=(t,e)=>{let r=0;for(let n=0;n<t.length;n++)t[n]===e&&r++;return r},$p=(t,e)=>{if(k(e)&&(e=parseInt(e)),Ge(e)){if(e<0||e>=t.length||isNaN(e))throw new Error("Invalid index");t.splice(e,1)}else throw new Error("Invalid index");return t},Mp=(t,e,r)=>{e<0||r<0||e>=t.length||r>=t.length||([t[e],t[r]]=[t[r],t[e]])},ko=(...t)=>[].concat(...t),pi=(t,e=[])=>t.reduce((r,n)=>at(r,lt(n,{exclude:e}),e),{}),Fp=(t,e)=>{let r=t.indexOf(e);return r!==-1?t.slice(0,r):t},Np=(t,e)=>{if(!P(t))return;let r=t.indexOf(e);return r!==-1?t.slice(r+1):t},hi=(t,e)=>{let r=t.indexOf(e);if(r>-1){let n=[...t];return n.splice(r,1),n}return t},jp=(t,e)=>t.filter(r=>r!==e),Bp=(t,e)=>{let r=[];for(let n=0;n<t.length;n++)r.push(t[n]),n<t.length-1&&r.push(e);return r},Vp=(t,e,r)=>{let n=[...t],o=n.indexOf(e),s=n.indexOf(r);if(o!==-1&&s!==-1){let i=n.splice(o,1)[0],a=s<o?s:s+1;n.splice(a,0,i)}return n},Up=(t,e)=>{if(t.length!==e.length)return!1;for(let r=0;r<t.length;r++)if(t[r]!==e[r])return!1;return!0},zp=(t,e)=>t.filter(r=>!e.includes(r)),Hp=(t,e)=>{let r=new Set(e);return t.filter(n=>!r.has(n))},Wp=(t,e)=>{if(!t)return 0;let r=0;for(let n=0;n<e.length;n++)t.includes(e[n])&&r++;return r},vo=t=>P(t)?[...new Set(t)]:t,gi=(t,e)=>{for(let r in e)Object.defineProperty(t,r,{value:e[r],enumerable:!1,configurable:!0,writable:!0})}});function Nt(t,e,r={}){let{bracketsLength:n=2,authored:o=!1}=r,s=n===3?"{{{":"{{";if(!t.includes(s)||o!==!0&&!RT(this,t))return t;let i=OT[n],a=e||this.state||{},c=this;return t.replace(i,(l,f,u,d)=>{let g=u.trim();if(d){let p=c?.context,h=p?.functions?.[d]||p?.utils?.[d]||p?.methods?.[d]||p?.snippets?.[d]||c?.[d];if(h&&typeof h=="function")try{return String(h.call(c,g)??"")}catch{return""}return""}if(f){let p=(f.match(/\.\.\//g)||[]).length,h=a;for(let y=0;y<p;y++){if(!h||!h.parent)return"";h=h.parent}if(g==="parent")return String(h.value??"");let m=mi(h,g);return m!=null&&typeof m=="object"?"":String(m??"")}else{let p=mi(a,g);if(p!=null&&typeof p!="object")return String(p);let h=c?.context?.polyglot;if(h?.translations){let m=a?.root?.lang||a?.lang||c?.context?.state?.lang||h.defaultLang||"en",y=h.translations[m];if(y){let b=mi(y,g);if(b!=null&&typeof b!="object")return String(b);for(let _ in y){let w=y[_];if(w&&typeof w=="object"&&!Array.isArray(w)){let S=mi(w,g);if(S!=null&&typeof S!="object")return String(S)}}}let x=mi(h.translations,g);if(x!=null&&typeof x!="object")return String(x)}return""}})}var yi,qp,OT,mi,RT,_n,Kp,PT,Gp,Yp,Xp,DT,Zp,Jp,bi=V(()=>{"use strict";yi=(t,e)=>{for(let r of e)if(t.includes(r))return!0;return!1},qp=(t,e)=>{let r=new RegExp(`[${e.join("\\")}]`,"g");return t.replace(r,"")},OT={2:/{{\s*((?:\.\.\/)*)([\w\d.]+)\s*(?:\|\s*([\w\d.]+))?\s*}}/g,3:/{{{(\s*(?:\.\.\/)*)([\w\d.]+)\s*(?:\|\s*([\w\d.]+))?\s*}}}/g},mi=(t,e)=>e.split(".").reduce((r,n)=>r?.[n],t),RT=(t,e)=>{if(!t||!t.__ref)return!0;let r=t;for(;r;){if(r.allowRuntimeTemplates===!0)return!0;let n=r.__ref&&r.__ref.__authoredTemplates;if(n&&n.has(e))return!0;r=r.parent}return!1};_n=t=>`${t.charAt(0).toLowerCase()}${t.slice(1)}`,Kp=(t,e)=>{let r=t.split(`
2
+ `),n=-1,o=-1,s=-1,i=-1,a=new RegExp(`\\b${e}\\b\\s*:\\s*`),c=0,l=!1;for(let f=0;f<r.length;f++)if(a.test(r[f])&&!l){if(l=!0,n=f+1,s=r[f].indexOf(e)+1,r[f].includes("{}")){o=n,i=r[f].indexOf("{}")+3;break}let u=r[f].slice(s+e.length);if(u.includes("{")||u.includes("["))c=1;else{o=f+1,i=r[f].length+1;break}}else if(l&&(c+=(r[f].match(/{/g)||[]).length,c+=(r[f].match(/\[/g)||[]).length,c-=(r[f].match(/}/g)||[]).length,c-=(r[f].match(/]/g)||[]).length,c===0)){o=f+1,i=r[f].lastIndexOf("}")!==-1?r[f].lastIndexOf("}")+2:r[f].length+1;break}return{startColumn:s,endColumn:i,startLineNumber:n,endLineNumber:o}},PT=/\\([0-7]{1,3})/g,Gp=t=>t.replace(PT,(e,r)=>String.fromCharCode(parseInt(r,8))),Yp=t=>t.replace(/\n/g,"/////n").replace(/`/g,"/////tilde").replace(/\$/g,"/////dlrsgn"),Xp=t=>t.replace(/\/\/\/\/\/n/g,`
3
+ `).replace(/\/\/\/\/\/tilde/g,"`").replace(/\/\/\/\/\/dlrsgn/g,"$"),DT=/[^a-zA-Z0-9\s]/g,Zp=t=>t.replace(DT,e=>"%"+e.charCodeAt(0).toString(16).toUpperCase()),Jp=t=>t.replace(/%[0-9A-Fa-f]{2}/g,e=>String.fromCharCode(parseInt(e.slice(1),16)))});var $r,_i,Qp,xn,Mr,Fr,th,Eo,wn,xi,eh,Sn=V(()=>{"use strict";$r=new Set(["attr","style","text","html","content","data","classlist","state","scope","root","deps","extend","extends","$router","routes","children","childExtend","childExtends","childExtendRecursive","childExtendsRecursive","props","if","define","__name","__ref","__hash","__text","key","tag","query","parent","node","variables","on","fetch","component","context","preventContentUpdate","preventContentRecreate"]),_i=new Set(["attr","style","text","html","content","data","class","state","scope","children","props","if","key","tag","query","on","context"]),Qp=["ref","parent","__element","__depends","__ref","__children","root"],xn=new Set(["update","parse","clean","create","destroy","add","toggle","remove","apply","set","reset","replace","quietReplace","quietUpdate","applyReplace","applyFunction","keys","values","ref","rootUpdate","parentUpdate","parent","__element","__depends","__ref","__children","root","setByPath","setPathCollection","removeByPath","removePathCollection","getByPath"]),Mr=new Set(["update","__element"]),Fr=new Set(["set","reset","update","remove","updateContent","removeContent","lookup","lookdown","lookdownAll","getRef","getPath","setNodeStyles","spotByPath","keys","parse","setProps","parseDeep","variables","if","log","verbose","warn","error","call","nextElement","previousElement","getRootState","getRoot","getRootData","getRootContext","getContext","getQuery","getDB","getChildren","preventContentUpdate","preventContentRecreate"]),th=t=>Fr.has(t),Eo=new Set(["log","warn","error","verbose"]),wn=t=>Fr.has(t)&&!Eo.has(t),xi=new Set(["node","context","extends","__element","__ref",...Fr,...xn,...Mr]),eh=new Set(["init","beforeClassAssign","render","renderRouter","attachNode","stateInit","stateCreated","beforeStateUpdate","stateUpdate","beforeUpdate","done","create","complete","frame","update","fetchError","fetchComplete"])});function KT(){let t=kn.get(this);return t?t.src.trim():Function.prototype.toString.call(this)}var Xx,vn,dt,nh,bt,at,ow,oh,lt,Si,LT,IT,Zx,ki,$T,MT,FT,De,sw,NT,kl,iw,rh,kn,jT,BT,VT,UT,zT,Jx,HT,Qx,WT,tw,vl,qT,GT,YT,XT,ew,sh,Le,Cn,ZT,JT,be,aw,cw,lw,fw,uw,rw,wi,nw,vi,ih,ah,Cl,ch,lh,Ci,En,Wt,El,QT,fh,uh,Al,dh,ph,hh,gh,mh,yh,bh,hr=V(()=>{"use strict";li();It();Co();bi();ui();Sn();Xx="production",vn=t=>t.charCodeAt(0)===95&&t.charCodeAt(1)===95,dt=(t,e,r,n)=>{if(R(t))return e?typeof t.call!="function"?t:t.call(e,e,r||e.state,n||e.context):void 0;if(t!=null&&e?.context?.plugins&&(P(t)||v(t)&&!Zt(t))){let o=e.context.plugins;for(let s of o)if(s.resolveHandler){let i=s.resolveHandler(t,e);if(typeof i=="function")return dt(i,e,r,n)}}return t},nh=(t,e,r)=>{for(let n in e)t[n]=dt(e[n],r)},bt=(t,e,r=[])=>{let n=r instanceof Set;for(let o in e)Object.prototype.hasOwnProperty.call(e,o)&&(vn(o)||(n?r.has(o):r.includes(o))||t[o]===void 0&&(t[o]=e[o]));return t},at=(t,e,r=xi)=>ow(t,e,r,null),ow=(t,e,r,n)=>{if(t===e)return t;if(n){for(let s=0;s<n.length;s+=2)if(n[s]===t&&n[s+1]===e)return t}let o=r instanceof Set;for(let s in e){if(!Object.prototype.hasOwnProperty.call(e,s)||vn(s)||s==="constructor"||s==="prototype"||(o?r.has(s):r.includes(s)))continue;let i=t[s],a=e[s];if(B(i)&&B(a)){let c=n||[];c.push(t,e),ow(i,a,r,c),c.length-=2}else i===void 0&&(t[s]=a)}return t},oh=(t,e=[])=>{let r=e instanceof Set,n={};for(let o in t)Object.prototype.hasOwnProperty.call(t,o)&&(vn(o)||(r?e.has(o):e.includes(o))||(n[o]=t[o]));return n},lt=(t,e={})=>{let{exclude:r=[],cleanUndefined:n=!1,cleanNull:o=!1,visited:s=new WeakMap,handleExtends:i=!1}=e;if(!B(t)||Zt(t))return t;if(s.has(t))return s.get(t);let a=r instanceof Set?r:r.length>3?new Set(r):null,c=u=>a?a.has(u):r.includes(u),l=P(t)?[]:{};s.set(t,l);let f=[[t,l]];for(;f.length;){let[u,d]=f.pop();for(let g in u){if(!Object.prototype.hasOwnProperty.call(u,g)||vn(g)||g==="__proto__"||c(g))continue;let p=u[g];if(!(n&&p===void 0)&&!(o&&p===null)){if(Zt(p)){d[g]=p;continue}if(i&&g==="extends"&&P(p)){d[g]=pi(p,r);continue}if(R(p)){d[g]=p;continue}if(B(p))if(s.has(p))d[g]=s.get(p);else{let h=P(p)?[]:{};s.set(p,h),d[g]=h,f.push([p,h])}else d[g]=p}}}return l},Si=(t,e={})=>{(t.node||t.__ref||t.parent||t.__element||t.parse)&&((t.__element||t.parent?.__element).warn("Trying to clone element or state at",t),t=t.parse?.());for(let r in t){let n=t[r];if(R(n))e[r]=n.toString();else if(v(n))e[r]={},Si(n,e[r]);else if(P(n)){let o=e[r]=[];for(let s=0;s<n.length;s++){let i=n[s];v(i)?(o[s]={},Si(i,o[s])):R(i)?o[s]=i.toString():o[s]=i}}else e[r]=n}return e},LT=/^[A-Za-z_$][A-Za-z0-9_$]*$/,IT=t=>`'${String(t).replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\r/g,"\\r").replace(/\n/g,"\\n")}'`,Zx=t=>{let e=String(t);return yi(e,[`
4
+ `,"'"])?"`"+e.replace(/\\/g,"\\\\").replace(/`/g,"\\`").replace(/\$\{/g,"\\${")+"`":"'"+e.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\r/g,"\\r")+"'"},ki=(t={},e=0)=>{if(t===null||typeof t!="object"||t instanceof RegExp)return String(t);let r=!1;for(let s in t){r=!0;break}if(!r)return"{}";let n=" ".repeat(e),o=`{
5
+ `;for(let s in t){if(!Object.prototype.hasOwnProperty.call(t,s))continue;let i=t[s],a=LT.test(s)?s:IT(s);if(o+=`${n} ${a}: `,i instanceof RegExp)o+=String(i);else if(P(i)){o+=`[
6
6
  `;for(let c of i)c instanceof RegExp?o+=`${n} ${String(c)},
7
- `:B(c)&&c!==null?o+=`${n} ${xi(c,e+2)},
8
- `:k(c)?o+=`${n} ${Ww(c)},
7
+ `:B(c)&&c!==null?o+=`${n} ${ki(c,e+2)},
8
+ `:k(c)?o+=`${n} ${Zx(c)},
9
9
  `:o+=`${n} ${c},
10
- `;o+=`${n} ]`}else B(i)?o+=xi(i,e+1):k(i)?o+=Ww(i):o+=i;o+=`,
11
- `}return o+=`${n}}`,o},CT=[/^\(\s*\{[^}]*\}\s*\)\s*=>/,/^(\([^)]*\)|[^=]*)\s*=>/,/^function[\s(]/,/^async\s+/,/^\(\s*function/,/^[a-zA-Z_$][a-zA-Z0-9_$]*\s*=>/,/^(?:\*\s*)?[a-zA-Z_$][\w$]*\s*\((?:[^()]|\([^()]*\))*\)\s*\{[\s\S]*\}$/],ET=/^["[{]/,AT=/^(export|import)\s/,De=t=>{if(!t)return!1;let e=t.trim();if(e===""||e==="{}"||e==="[]")return!1;let r=e.includes("=>");if(!r&&e.charCodeAt(0)!==40&&!e.startsWith("function")&&!e.startsWith("async")&&!(e.charCodeAt(e.length-1)===125&&e.includes("("))||AT.test(e)||!CT.some(s=>s.test(e)))return!1;let o=e.charCodeAt(0);return!(o===123&&!r||o===91||ET.test(e)&&!r)},Qw=t=>(0,eval)(t),TT=(t,e)=>{let r=/^(\s*(?:async\s+)?function\s*[\w$]*\s*\([^)]*\)\s*)\{/.exec(t);if(!r)return null;let n=r[0].length,o=[],s=n,i=1,a=null,c=t.length,l=new RegExp("^(?:const|let|var)\\s+"+e+"\\b");for(;s<c&&i>0;){let u=t[s];if(u==="/"&&t[s+1]==="/"){let d=t.indexOf(`
10
+ `;o+=`${n} ]`}else B(i)?o+=ki(i,e+1):k(i)?o+=Zx(i):o+=i;o+=`,
11
+ `}return o+=`${n}}`,o},$T=[/^\(\s*\{[^}]*\}\s*\)\s*=>/,/^(\([^)]*\)|[^=]*)\s*=>/,/^function[\s(]/,/^async\s+/,/^\(\s*function/,/^[a-zA-Z_$][a-zA-Z0-9_$]*\s*=>/,/^(?:\*\s*)?[a-zA-Z_$][\w$]*\s*\((?:[^()]|\([^()]*\))*\)\s*\{[\s\S]*\}$/],MT=/^["[{]/,FT=/^(export|import)\s/,De=t=>{if(!t)return!1;let e=t.trim();if(e===""||e==="{}"||e==="[]")return!1;let r=e.includes("=>");if(!r&&e.charCodeAt(0)!==40&&!e.startsWith("function")&&!e.startsWith("async")&&!(e.charCodeAt(e.length-1)===125&&e.includes("("))||FT.test(e)||!$T.some(s=>s.test(e)))return!1;let o=e.charCodeAt(0);return!(o===123&&!r||o===91||MT.test(e)&&!r)},sw=t=>(0,eval)(t),NT=(t,e)=>{let r=/^(\s*(?:async\s+)?function\s*[\w$]*\s*\([^)]*\)\s*)\{/.exec(t);if(!r)return null;let n=r[0].length,o=[],s=n,i=1,a=null,c=t.length,l=new RegExp("^(?:const|let|var)\\s+"+e+"\\b");for(;s<c&&i>0;){let u=t[s];if(u==="/"&&t[s+1]==="/"){let d=t.indexOf(`
12
12
  `,s);s=d===-1?c:d;continue}if(u==="/"&&t[s+1]==="*"){let d=t.indexOf("*/",s+2);s=d===-1?c:d+2;continue}if(u==='"'||u==="'"||u==="`"){let d=u;for(s++;s<c;){if(t[s]==="\\"){s+=2;continue}if(t[s]===d){s++;break}if(d==="`"&&t[s]==="$"&&t[s+1]==="{"){s+=2;let g=1;for(;s<c&&g>0;)t[s]==="{"?g++:t[s]==="}"&&g--,s++;continue}s++}continue}if(u==="{"){i++,s++;continue}if(u==="}"){i--,s++;continue}if(i===1&&l.test(t.slice(s))){let d=s,g=0,p=s;for(;p<c;){let h=t[p];if(h==='"'||h==="'"||h==="`"){let m=h;for(p++;p<c;){if(t[p]==="\\"){p+=2;continue}if(t[p]===m){p++;break}p++}continue}if(h==="("||h==="["||h==="{"){g++,p++;continue}if(h===")"||h==="]"||h==="}"){if(g===0)break;g--,p++;continue}if(g===0&&(h===";"||h===`
13
- `)){p++;break}p++}o.push([d,p]),s=p;continue}s++}if(!o.length)return null;let f=t;for(let u=o.length-1;u>=0;u--)f=f.slice(0,o[u][0])+f.slice(o[u][1]);return f},xl=(t,e,r,n)=>{let o=String(t).trimStart();if(/^(export|import)\s/.test(o))return t;try{return r.window.eval(`(${t})`)}catch(s){let i=s&&s.message?s.message:String(s),a=/await is only valid in async/.test(i),c=/Identifier '([^']+)' has already been declared/.exec(i),l=null;if(a){let f=String(t).trim();if(/^function[\s(]/.test(f))try{l=r.window.eval("(async "+f+")")}catch{}}else if(c){let f=String(t),u=c[1];for(let d=0;d<5;d++){let g=TT(f,u);if(!g||g===f)break;f=g;try{l=r.window.eval("("+f+")");break}catch(p){let h=/Identifier '([^']+)' has already been declared/.exec(p&&p.message||String(p));if(!h||h[1]!==u)break}}}if(!l&&/Unexpected (token '\{'|identifier)/.test(i))try{let f=r.window.eval("({"+t+"})");if(f&&typeof f=="object"){let u=Object.keys(f);u.length===1&&typeof f[u[0]]=="function"&&(l=f[u[0]])}}catch{}return l||(typeof console<"u"&&console.warn&&console.warn(`[smbls] deepDestringifyFunctions: eval failed on ${e} \u2014 `+(n?"revived lazily, so its source compiled on this first use; it acts as the string it replaces (a call returns the source text, el.call treats it as not callable). Reason: ":"value will be left as a string. Reason: ")+i+`.
14
- First 200 chars of source: `+String(t).slice(0,200)),t)}},tx=1,th=2,Cn=new WeakMap,OT=/^(async\s+)?function(?![\w$])\s*(\*)?\s*([A-Za-z_$][\w$]*)?\s*\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*\{/,RT=/^(async\s+)?[A-Za-z_$][\w$]*\s*=>/,PT=/^(async\s*)?\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*=>/,DT=/^(async\s+)?([A-Za-z_$][\w$]*)\s*\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*\{/,LT=new Set(["if","for","while","switch","catch","with","do","return","typeof","void","delete","new","in","of","instanceof","function","class","const","let","var","await","yield","import","export","try","else","throw","case","default","break","continue","debugger","finally","super","this","null","true","false","async","get","set","static"]),qw=t=>t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===36||t===95,IT=(t,e,r)=>{let n=t.indexOf(e,r);for(;n!==-1;){let o=n+e.length;if((n===0||!qw(t.charCodeAt(n-1)))&&(o>=t.length||!qw(t.charCodeAt(o))))return!0;n=t.indexOf(e,o)}return!1},Kw=t=>{let e=t.length-1;for(;e>=0&&t.charCodeAt(e)<=32;)e--;return e<0?-1:t.charCodeAt(e)},$T=t=>{let e=t,r=0;for(;r<e.length&&e.charCodeAt(r)<=32;)r++;r&&(e=e.slice(r));let n=OT.exec(e);if(n){if(n[2]||Kw(e)!==125)return null;let o=n[3]||"";return o&&IT(e,o,n[0].indexOf("("))||e.indexOf("arguments.callee")!==-1?null:{src:t,name:o,kind:n[1]?th:tx,async:!!n[1],fn:void 0}}return n=RT.exec(e)||PT.exec(e),n?{src:t,name:"",kind:th,async:!!n[1],fn:void 0}:(n=DT.exec(e),n&&!LT.has(n[2])&&Kw(e)===125?e.indexOf("arguments.callee")!==-1?null:{src:t,name:n[2],kind:th,async:!!n[1],fn:void 0}:null)},Gw=t=>t.index===-1?`"${t.key}"`:`array index ${t.index} (prop "${t.key}")`,Sl=t=>{let e=xl(t.src,Gw(t),t.opts,!0),r=null;return typeof e=="function"?r=e:(t.value=e,typeof e!="string"&&typeof console<"u"&&console.warn&&console.warn(`[smbls] deepDestringifyFunctions: ${Gw(t)} did not evaluate to a function \u2014 the lazily revived function returns that value.
15
- First 200 chars of source: `+String(t.src).slice(0,200))),t.fn=r,t.opts=null,r},MT=(t,e,r)=>Reflect.construct(t,e,r);NT={length:{get(){let t=Cn.get(this);if(!t)return 0;let e=t.fn===void 0?Sl(t):t.fn;return e?e.length:0},configurable:!0},name:{get(){let t=Cn.get(this);return t?t.name:""},configurable:!0},toString:{value:FT,writable:!0,configurable:!0}},jT=Object.getPrototypeOf(async function(){}),BT=t=>{let e;return t.kind===tx?e=function(){let r=t.fn===void 0?Sl(t):t.fn;return r===null?t.value:new.target?MT(r,arguments,new.target):r.apply(this,arguments)}:e={lazy(){let r=t.fn===void 0?Sl(t):t.fn;return r===null?t.value:r.apply(this,arguments)}}.lazy,Cn.set(e,t),Object.defineProperties(e,NT),t.async&&Object.setPrototypeOf(e,jT),e},Yw=(t,e,r,n)=>{let o=$T(t);return o?(o.key=e,o.index=r,o.opts=n,BT(o)):xl(t,r===-1?`"${e}"`:`array index ${r} (prop "${e}")`,n)},nh=t=>typeof t=="function"&&Cn.has(t),Le=t=>{let e=Cn.get(t);return e?e.src.trim():Function.prototype.toString.call(t)},An=t=>{let e=typeof t=="function"?Cn.get(t):void 0;return e?(e.fn===void 0?Sl(e):e.fn)===null:!1},VT=new Set(["components","pages","functions","methods","snippets","app","globalScope"]),UT={window:{eval:Qw}},be=(t,e={},r=UT)=>{if(!t||typeof t!="object")return e;(!r||!r.window||typeof r.window.eval!="function")&&(r={...r,window:{eval:Qw}});let n=r.lazy===!0,o=r.lazy==="context",s=(a,c,l)=>n||o&&(a===t?VT.has(c):l),i=[[t,e,n]];for(;i.length;){let[a,c,l]=i.pop();for(let f in a){if(!Object.prototype.hasOwnProperty.call(a,f))continue;let u=a[f];if(k(u))De(u)?c[f]=l?Yw(u,f,-1,r):xl(u,`"${f}"`,r):c[f]=u;else if(P(u)){let d=c[f]=[],g=s(a,f,l);for(let p=0;p<u.length;p++){let h=u[p];if(k(h))d.push(De(h)?g?Yw(h,f,p,r):xl(h,`array index ${p} (prop "${f}")`,r):h);else if(v(h)){let m=Zw(h);if(m)d.push(m);else{let _={};d.push(_),i.push([h,_,g])}}else d.push(h)}}else if(v(u)){let d=Zw(u);if(d){c[f]=d;continue}let g=c[f]&&typeof c[f]=="object"&&!P(c[f])?c[f]:c[f]={};i.push([u,g,s(a,f,l)])}else c[f]=u}}return e},ex="Set",rx="Map",nx="RegExp",ox="WeakMap",sx="WeakSet",Xw=t=>{let e=Object.keys(t);return e.length===1&&e[0]==="__type"},_i=(t,e)=>{if(!t||typeof t!="object")return t;let r=s=>_i(s,e||(e=new WeakMap));if(t.__type===ex&&P(t.values))return new Set(t.values.map(r));if(t.__type===rx&&P(t.entries))return new Map(t.entries.map(s=>P(s)?[r(s[0]),r(s[1])]:s));if(t.__type===ox&&Xw(t))return new WeakMap;if(t.__type===sx&&Xw(t))return new WeakSet;if(t.__type===nx&&k(t.source))try{return new RegExp(t.source,k(t.flags)?t.flags:"")}catch{return t}if(e||(e=new WeakMap),e.has(t))return e.get(t);let n=!1;if(P(t)){let s=new Array(t.length);e.set(t,s);for(let i=0;i<t.length;i++)s[i]=_i(t[i],e),s[i]!==t[i]&&(n=!0);return n||e.set(t,t),n?s:t}let o={};e.set(t,o);for(let s of Object.keys(t))o[s]=_i(t[s],e),o[s]!==t[s]&&(n=!0);return n||e.set(t,t),n?o:t},Zw=t=>{if(!t||typeof t!="object")return null;let e=t.__type;if(e!==nx&&e!==ex&&e!==rx&&e!==ox&&e!==sx)return null;let r=_i(t);return r===t?null:r},Si=t=>{if(!t||typeof t!="object")return t;let e={},r=[];for(let i of Object.keys(t)){let a=t[i];k(a)&&De(a)?r.push([i,a]):e[i]=_i(a)}if(r.length===0)return e;let n=i=>/^[A-Za-z_$][\w$]*$/.test(i),o=r.filter(([i])=>n(i)),s=Object.keys(e).filter(n).map(i=>`var ${i} = __gs__[${JSON.stringify(i)}];`).join(`
13
+ `)){p++;break}p++}o.push([d,p]),s=p;continue}s++}if(!o.length)return null;let f=t;for(let u=o.length-1;u>=0;u--)f=f.slice(0,o[u][0])+f.slice(o[u][1]);return f},kl=(t,e,r,n)=>{let o=String(t).trimStart();if(/^(export|import)\s/.test(o))return t;try{return r.window.eval(`(${t})`)}catch(s){let i=s&&s.message?s.message:String(s),a=/await is only valid in async/.test(i),c=/Identifier '([^']+)' has already been declared/.exec(i),l=null;if(a){let f=String(t).trim();if(/^function[\s(]/.test(f))try{l=r.window.eval("(async "+f+")")}catch{}}else if(c){let f=String(t),u=c[1];for(let d=0;d<5;d++){let g=NT(f,u);if(!g||g===f)break;f=g;try{l=r.window.eval("("+f+")");break}catch(p){let h=/Identifier '([^']+)' has already been declared/.exec(p&&p.message||String(p));if(!h||h[1]!==u)break}}}if(!l&&/Unexpected (token '\{'|identifier)/.test(i))try{let f=r.window.eval("({"+t+"})");if(f&&typeof f=="object"){let u=Object.keys(f);u.length===1&&typeof f[u[0]]=="function"&&(l=f[u[0]])}}catch{}return l||(typeof console<"u"&&console.warn&&console.warn(`[smbls] deepDestringifyFunctions: eval failed on ${e} \u2014 `+(n?"revived lazily, so its source compiled on this first use; it acts as the string it replaces (a call returns the source text, el.call treats it as not callable). Reason: ":"value will be left as a string. Reason: ")+i+`.
14
+ First 200 chars of source: `+String(t).slice(0,200)),t)}},iw=1,rh=2,kn=new WeakMap,jT=/^(async\s+)?function(?![\w$])\s*(\*)?\s*([A-Za-z_$][\w$]*)?\s*\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*\{/,BT=/^(async\s+)?[A-Za-z_$][\w$]*\s*=>/,VT=/^(async\s*)?\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*=>/,UT=/^(async\s+)?([A-Za-z_$][\w$]*)\s*\((?:[^()'"`/]|\([^()'"`/]*\))*\)\s*\{/,zT=new Set(["if","for","while","switch","catch","with","do","return","typeof","void","delete","new","in","of","instanceof","function","class","const","let","var","await","yield","import","export","try","else","throw","case","default","break","continue","debugger","finally","super","this","null","true","false","async","get","set","static"]),Jx=t=>t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===36||t===95,HT=(t,e,r)=>{let n=t.indexOf(e,r);for(;n!==-1;){let o=n+e.length;if((n===0||!Jx(t.charCodeAt(n-1)))&&(o>=t.length||!Jx(t.charCodeAt(o))))return!0;n=t.indexOf(e,o)}return!1},Qx=t=>{let e=t.length-1;for(;e>=0&&t.charCodeAt(e)<=32;)e--;return e<0?-1:t.charCodeAt(e)},WT=t=>{let e=t,r=0;for(;r<e.length&&e.charCodeAt(r)<=32;)r++;r&&(e=e.slice(r));let n=jT.exec(e);if(n){if(n[2]||Qx(e)!==125)return null;let o=n[3]||"";return o&&HT(e,o,n[0].indexOf("("))||e.indexOf("arguments.callee")!==-1?null:{src:t,name:o,kind:n[1]?rh:iw,async:!!n[1],fn:void 0}}return n=BT.exec(e)||VT.exec(e),n?{src:t,name:"",kind:rh,async:!!n[1],fn:void 0}:(n=UT.exec(e),n&&!zT.has(n[2])&&Qx(e)===125?e.indexOf("arguments.callee")!==-1?null:{src:t,name:n[2],kind:rh,async:!!n[1],fn:void 0}:null)},tw=t=>t.index===-1?`"${t.key}"`:`array index ${t.index} (prop "${t.key}")`,vl=t=>{let e=kl(t.src,tw(t),t.opts,!0),r=null;return typeof e=="function"?r=e:(t.value=e,typeof e!="string"&&typeof console<"u"&&console.warn&&console.warn(`[smbls] deepDestringifyFunctions: ${tw(t)} did not evaluate to a function \u2014 the lazily revived function returns that value.
15
+ First 200 chars of source: `+String(t.src).slice(0,200))),t.fn=r,t.opts=null,r},qT=(t,e,r)=>Reflect.construct(t,e,r);GT={length:{get(){let t=kn.get(this);if(!t)return 0;let e=t.fn===void 0?vl(t):t.fn;return e?e.length:0},configurable:!0},name:{get(){let t=kn.get(this);return t?t.name:""},configurable:!0},toString:{value:KT,writable:!0,configurable:!0}},YT=Object.getPrototypeOf(async function(){}),XT=t=>{let e;return t.kind===iw?e=function(){let r=t.fn===void 0?vl(t):t.fn;return r===null?t.value:new.target?qT(r,arguments,new.target):r.apply(this,arguments)}:e={lazy(){let r=t.fn===void 0?vl(t):t.fn;return r===null?t.value:r.apply(this,arguments)}}.lazy,kn.set(e,t),Object.defineProperties(e,GT),t.async&&Object.setPrototypeOf(e,YT),e},ew=(t,e,r,n)=>{let o=WT(t);return o?(o.key=e,o.index=r,o.opts=n,XT(o)):kl(t,r===-1?`"${e}"`:`array index ${r} (prop "${e}")`,n)},sh=t=>typeof t=="function"&&kn.has(t),Le=t=>{let e=kn.get(t);return e?e.src.trim():Function.prototype.toString.call(t)},Cn=t=>{let e=typeof t=="function"?kn.get(t):void 0;return e?(e.fn===void 0?vl(e):e.fn)===null:!1},ZT=new Set(["components","pages","functions","methods","snippets","app","globalScope"]),JT={window:{eval:sw}},be=(t,e={},r=JT)=>{if(!t||typeof t!="object")return e;(!r||!r.window||typeof r.window.eval!="function")&&(r={...r,window:{eval:sw}});let n=r.lazy===!0,o=r.lazy==="context",s=(a,c,l)=>n||o&&(a===t?ZT.has(c):l),i=[[t,e,n]];for(;i.length;){let[a,c,l]=i.pop();for(let f in a){if(!Object.prototype.hasOwnProperty.call(a,f))continue;let u=a[f];if(k(u))De(u)?c[f]=l?ew(u,f,-1,r):kl(u,`"${f}"`,r):c[f]=u;else if(P(u)){let d=c[f]=[],g=s(a,f,l);for(let p=0;p<u.length;p++){let h=u[p];if(k(h))d.push(De(h)?g?ew(h,f,p,r):kl(h,`array index ${p} (prop "${f}")`,r):h);else if(v(h)){let m=nw(h);if(m)d.push(m);else{let y={};d.push(y),i.push([h,y,g])}}else d.push(h)}}else if(v(u)){let d=nw(u);if(d){c[f]=d;continue}let g=c[f]&&typeof c[f]=="object"&&!P(c[f])?c[f]:c[f]={};i.push([u,g,s(a,f,l)])}else c[f]=u}}return e},aw="Set",cw="Map",lw="RegExp",fw="WeakMap",uw="WeakSet",rw=t=>{let e=Object.keys(t);return e.length===1&&e[0]==="__type"},wi=(t,e)=>{if(!t||typeof t!="object")return t;let r=s=>wi(s,e||(e=new WeakMap));if(t.__type===aw&&P(t.values))return new Set(t.values.map(r));if(t.__type===cw&&P(t.entries))return new Map(t.entries.map(s=>P(s)?[r(s[0]),r(s[1])]:s));if(t.__type===fw&&rw(t))return new WeakMap;if(t.__type===uw&&rw(t))return new WeakSet;if(t.__type===lw&&k(t.source))try{return new RegExp(t.source,k(t.flags)?t.flags:"")}catch{return t}if(e||(e=new WeakMap),e.has(t))return e.get(t);let n=!1;if(P(t)){let s=new Array(t.length);e.set(t,s);for(let i=0;i<t.length;i++)s[i]=wi(t[i],e),s[i]!==t[i]&&(n=!0);return n||e.set(t,t),n?s:t}let o={};e.set(t,o);for(let s of Object.keys(t))o[s]=wi(t[s],e),o[s]!==t[s]&&(n=!0);return n||e.set(t,t),n?o:t},nw=t=>{if(!t||typeof t!="object")return null;let e=t.__type;if(e!==lw&&e!==aw&&e!==cw&&e!==fw&&e!==uw)return null;let r=wi(t);return r===t?null:r},vi=t=>{if(!t||typeof t!="object")return t;let e={},r=[];for(let i of Object.keys(t)){let a=t[i];k(a)&&De(a)?r.push([i,a]):e[i]=wi(a)}if(r.length===0)return e;let n=i=>/^[A-Za-z_$][\w$]*$/.test(i),o=r.filter(([i])=>n(i)),s=Object.keys(e).filter(n).map(i=>`var ${i} = __gs__[${JSON.stringify(i)}];`).join(`
16
16
  `);try{let i=o.map(([l,f])=>`var ${l} = (${f});`).join(`
17
- `),a="{ "+o.map(([l])=>`${JSON.stringify(l)}: ${l}`).join(", ")+" }",c=E.eval(`(function(__gs__) { ${s}
17
+ `),a="{ "+o.map(([l])=>`${JSON.stringify(l)}: ${l}`).join(", ")+" }",c=C.eval(`(function(__gs__) { ${s}
18
18
  ${i}
19
19
  return ${a}; })`)(e);Object.assign(e,c)}catch{for(let[a,c]of o)try{let l=Object.keys(e).filter(n).map(f=>`var ${f} = __gs__[${JSON.stringify(f)}];`).join(`
20
- `);e[a]=E.eval(`(function(__gs__) { ${l}
21
- return (${c}); })`)(e)}catch{try{e[a]=E.eval(`(${c})`)}catch{e[a]=c}}}for(let[i,a]of r)if(!n(i))try{e[i]=E.eval(`(${a})`)}catch{e[i]=a}return e},oh=(t,e={verbose:!0})=>{try{return t?E.eval("("+t+")"):{}}catch(r){e.verbose&&console.warn(r)}},sh=(t,...e)=>Object.prototype.hasOwnProperty.call(t,...e),kl=t=>{for(let e in t)return!1;return!0},ih=t=>v(t)&&kl(t),ah=()=>Object.create(null),ki=(t,e,r={})=>{let n=r.exclude||[],o=r.preventUnderscore;for(let s in e)n.includes(s)||!o&&En(s)||s==="constructor"||s==="prototype"||e[s]!==void 0&&(t[s]=e[s]);return t},Tn=(t,e,r=[])=>{let n=r instanceof Set;for(let o in e)En(o)||o==="constructor"||o==="prototype"||(n?r.has(o):r.includes(o))||(t[o]=e[o]);return t},Wt=(t,e,r={},n=new WeakMap)=>{if(!B(t)||!B(e)||Zt(t)||Zt(e))return e;if(n.has(t))return n.get(t);n.set(t,t);let o=r.exclude,s=o?o instanceof Set?o:new Set(o):null,i=!r.preventForce;for(let a in e){if(!Object.prototype.hasOwnProperty.call(e,a)||s&&s.has(a)||i&&En(a)||a==="constructor"||a==="prototype")continue;let c=t[a],l=e[a];Zt(l)?t[a]=l:B(c)&&B(l)?t[a]=Wt(c,l,r,n):l!==void 0&&(t[a]=l)}return t},vl=(t,e,r=new Set)=>{if(typeof t!="object"||typeof e!="object"||t===null||e===null)return t===e;if(r.has(t)||r.has(e))return!0;r.add(t),r.add(e);let n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(let s=0;s<n.length;s++){let i=n[s];if(!Object.prototype.hasOwnProperty.call(e,i)||!vl(t[i],e[i],r))return!1}return!0},zT=new Set(["node","__ref"]),ch=(t,e,r=zT)=>{if(t===e)return!0;if(!B(t)||!B(e)||Zt(t)||Zt(e))return t===e;let n=r instanceof Set?r:new Set(r),o=new WeakSet;function s(i,a){if(o.has(a))return!0;o.add(a);for(let c in a){if(!Object.prototype.hasOwnProperty.call(a,c)||n.has(c))continue;if(!Object.prototype.hasOwnProperty.call(i,c))return!1;let l=a[c],f=i[c];if(Zt(l)||Zt(f)){if(l!==f)return!1}else if(B(l)&&B(f)){if(!s(f,l))return!1}else if(l!==f)return!1}return!0}return s(t,e)},lh=(t,e)=>{if(e==null)return t;if(Jt(e)("string","number"))delete t[e];else if(P(e))for(let r=0;r<e.length;r++)delete t[e[r]];else throw new Error("Invalid input: props must be a string or an array of strings");return t},Cl=t=>{if(t===null||typeof t!="object")return t;let e=Object.create(null);for(let r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=Cl(t[r]));return e},fh=(t,e)=>{if(t.length===0)return e;let r={},n=r;for(let o=0;o<t.length;o++)o===t.length-1&&e?n[t[o]]=e:(n[t[o]]={},n=n[t[o]]);return r},uh=(t,e)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let r=t;for(let o=0;o<e.length-1;o++){if(r[e[o]]===void 0)return;r=r[e[o]]}let n=e[e.length-1];r&&Object.prototype.hasOwnProperty.call(r,n)&&delete r[n]},dh=(t,e,r)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let n=t;for(let o=0;o<e.length-1;o++)(!n[e[o]]||typeof n[e[o]]!="object")&&(n[e[o]]={}),n=n[e[o]];return n[e[e.length-1]]=r,t},ph=(t,e)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let r=t;for(let n=0;n<e.length;n++){if(r==null)return;r=r[e[n]]}return r},hh=t=>{let r=[],n=0;for(let o=0;o<t.length;o++)if(r.length<2)r.push(t[o]);else if(t[o]===r[o%2]?n++:(r=[t[o-1],t[o]],n=1),n>=20)return(Hw==="test"||Hw==="development")&&console.warn("Warning: Potential infinite loop detected due to repeated sequence:",r),!0},gh=t=>{let e=new WeakSet;function r(n){if(n&&typeof n=="object"){if(e.has(n))return!0;e.add(n);for(let o in n)if(Object.prototype.hasOwnProperty.call(n,o)&&r(n[o]))return console.log(n,"cycle at "+o),!0}return!1}return r(t)},mh=(t,e)=>{let r=e instanceof Set?e:new Set(e),n={};for(let o in t)Object.prototype.hasOwnProperty.call(t,o)&&!r.has(o)&&(n[o]=t[o]);return n}});var vi,Ci,Ei,El=V(()=>{"use strict";pr();vi=(function(){let t=0;function e(){return t++,t}return e})(),Ci=vi,Ei=(t,e,r)=>(dt(r,t)||r||t.key||vi()).toString()});var Ie,yh,jr,Al,bh,_h,wh,Br,xh,On,gt,Tl=V(()=>{"use strict";Ie="production",yh=Ie,jr=(t=Ie)=>t==="production",Al=(t=Ie)=>t==="testing"||t==="test",bh=Al,_h=(t=Ie)=>t==="staging",wh=(t=Ie)=>t==="local",Br=(t=Ie)=>t==="development"||t==="dev"||t==="local",xh=(t,e=Ie)=>e[t],On=(t=Ie)=>!jr(t),gt=t=>{let e=t&&"env"in t?t.env:typeof process<"u"&&process.env?"production":void 0;if(e&&e!=="production")return!0;let r=t&&"hostname"in t?t.hostname:typeof location<"u"?location.hostname:void 0;return typeof r=="string"&&r?r==="localhost"||r==="127.0.0.1"||r.endsWith(".localhost"):!1}});function Ai(t,e,r){let n;return function(){let o=this,s=arguments,i=function(){n=null,r||t.apply(o,s)},a=r&&!n;clearTimeout(n),n=setTimeout(i,e),a&&t.apply(o,s)}}function vh(t,e=window){let r=function(){return t.apply(e,arguments)};for(let n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n]);return r}var Sh,kh,HT,Ti,Ao,To,Ot,Rn=V(()=>{"use strict";Sh=(t,e,r=300)=>{let n;return(...o)=>{clearTimeout(n),n=setTimeout(()=>{e.apply(t,o)},r)}},kh=t=>{let e={};return(...r)=>{let n=r[0];if(n in e)return e[n];{let o=t(n);return e[n]=o,o}}},HT=/^\s*(?:async\s+)?(?:function\b|\([^)]*\)\s*=>|[a-zA-Z_$][\w$]*\s*=>)/,Ti=t=>HT.test(t),Ao=t=>{let e=t?.plugins;if(!e||!e.length)return!1;for(let r of e)if(r.resolveHandler)return!0;return!1},To=(t,e)=>{if(typeof t=="function")return t;let r=e?.context?.plugins;if(!r)return t;for(let n of r)if(n.resolveHandler){let o=n.resolveHandler(t,e);if(typeof o=="function")return o}return t},Ot=(t,e,...r)=>{let n=e?.context?.plugins;if(!n)return!1;let o=!1;for(let s of n)typeof s[t]=="function"&&(s[t](e,...r),o=!0);return o}});var Ch,ix=V(()=>{"use strict";It();pr();Ch=(t,e)=>{let{__ref:r}=t,n=t.if;if(R(n)){let o;try{o=n(t,t.state,t.context)}catch(s){typeof console<"u"&&console.warn("[DOMQL] if condition error:",s),delete r.__if;return}o?r.__if=!0:delete r.__if}else n!=null&&typeof n=="object"?dt(n,t)?r.__if=!0:delete r.__if:r.__if=!0}});var Eh,Ah,ax=V(()=>{"use strict";Eh=(t,...e)=>{t&&e.map(r=>console.log(r))},Ah=(t,e,...r)=>{t&&(console.group(e),r.map(n=>console.log(n)),console.groupEnd(e))}});function Dh(t){let e;try{if(!window.localStorage)return;e=window.localStorage.getItem(t)}catch{return}if(e!==null)try{return JSON.parse(e)}catch{return}}function Lh(t,e){if(e!=null)try{if(!window.localStorage)return;let r=typeof e=="object"?JSON.stringify(e):e;window.localStorage.setItem(t,r)}catch{}}var Th,Oh,Rh,Ph,cx=V(()=>{"use strict";It();ai();Th=typeof navigator>"u"?!1:/Mobi/.test(navigator.userAgent),Oh=(t,e,r=365)=>{if(Lt(st)||Lt(st.cookie))return;let n=new Date;n.setTime(n.getTime()+r*24*60*60*1e3);let o=`expires=${n.toUTCString()}`;st.cookie=`${t}=${e};${o};path=/`},Rh=t=>{if(Lt(st)||Lt(st.cookie))return;let e=`${t}=`,n=decodeURIComponent(st.cookie).split(";");for(let o=0;o<n.length;o++){let s=n[o];for(;s.charAt(0)===" ";)s=s.substring(1);if(s.indexOf(e)===0)return s.substring(e.length,s.length)}return""},Ph=t=>{Lt(st)||Lt(st.cookie)||(st.cookie=t+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;")}});var Oo,lx,Ih,$h=V(()=>{"use strict";Oo={root:["body","html"],head:["title","base","meta","style","noscript","script"],body:new Set(["string","style","fragment","a","abbr","acronym","address","applet","area","article","aside","audio","b","basefont","bdi","bdo","big","blockquote","br","button","canvas","caption","center","cite","code","search","col","colgroup","data","datalist","dd","del","details","dfn","dialog","dir","div","dl","dt","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","meter","nav","noframes","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","hgroup","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strike","strong","sub","summary","sup","table","tbody","td","template","hgroup","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr","svg","path","circle","ellipse","line","polygon","polyline","rect","g","defs","symbol","use","text","tspan","image","clipPath","mask","pattern","marker","linearGradient","radialGradient","stop","filter","feGaussianBlur","feOffset","feMerge","feMergeNode","feBlend","feColorMatrix","feFlood","feComposite","foreignObject"])},lx=new Set(["svg","path","circle","ellipse","line","polygon","polyline","rect","g","defs","symbol","use","text","tspan","image","clipPath","mask","pattern","marker","linearGradient","radialGradient","stop","filter","feGaussianBlur","feOffset","feMerge","feMergeNode","feBlend","feColorMatrix","feFlood","feComposite","foreignObject"]),Ih=t=>Oo.body.has(t)});var Mh,fx,Ro,_e,Po,Pi,Ge,Fh,Ol,Di,Nh,Li,Rl,Pl,Ii,Dl,Do,WT,Ye,ux,Oi,$i,jh,Ri,Bh,Vh,Ll,Il,$l,Ml,Fl,Nl,dx,jl=V(()=>{"use strict";Co();Uh();pr();It();Mh="production",fx=t=>t.sourcemap!==!1&&Mh!=="production",Ro=t=>{if(!t)return[];let e=[],r=t.extends;r&&(P(r)?e.push(...r):e.push(r));let n=t.extend;return n&&(P(n)?e.push(...n):e.push(n)),e},_e=t=>{if(!P(t))return t;let e=[];for(let r=t.length-1;r>=0;r--){let n=t[r];e.push(P(n)?_e(n):n)}return e},Po=t=>{if(t.includes("+"))return t.split("+").filter(Xe);if(t.includes("_")){let[e]=t.split("_");return[e]}if(t.includes(".")&&!Xe(t.split(".")[1])){let[e]=t.split(".");return[e]}return[t]},Pi=(t,e,r)=>{let n=[],o=Po(r);o&&(n=[...o]);let s=_e(Ro(t));return s.length&&(n=[...n,...s]),n},Ge=(t,e)=>{let{__ref:r}=e,{__extends:n}=r;if(!t)return n;let o=e.variant,s=e.context;if(o&&s?.components&&!Array.isArray(t)&&typeof t=="string"){let i=`${t}.${o}`;s.components[i]&&(t=i)}return n.includes(t)||(n=Array.isArray(t)?[...n,...t]:[...n,t],r.__extends=n),n},Fh=(t,e)=>{if(!t)return e;let{extends:r}=e,n=P(r)?r:[r],o=P(t)?t:[t];return{...e,extends:ko(o,n)}},Ol=()=>Math.random().toString(36).substring(2),Di={},Nh={},Li=t=>Di[t.__hash],Rl=(t,e)=>{let r=Ol();return k(t)||(t.__hash=r),r!=="__proto__"&&r!=="constructor"&&r!=="prototype"&&(Di[r]=e),e},Pl=(t,e)=>t.__hash?e.concat(Li(t)):Rl(t,e),Ii=(t,e,r,n=new Set,o,s)=>{for(let i of t)P(i)?Ii(i,e,r,n,o,s):Do(i,e,r,n,o,void 0,s);return e},Dl=(t,e,r,n=new Set,o,s,i)=>{let a=Ro(t),c={...t};delete c.extends,delete c.extend;let l=!1;for(let f in c){l=!0;break}return l&&(e.push(c),o&&o.push(s)),a.length&&Do(_e(a),e,r,n,o,s,i),e},Do=(t,e,r,n=new Set,o,s,i)=>{if(!t||n.has(t))return e;if(P(t))return Ii(t,e,r,n,o,i);let a=s;return k(t)?(a=t,t=$i(t,r)):i&&v(t)&&i.has(t)&&(a=i.get(t)),n.has(t)||(n.add(t),t?.extends||t?.extend?Dl(t,e,r,n,o,a,i):t&&(e.push(t),o&&o.push(a))),e},WT=new Set(["parent","node","__ref","__proto__","extends","extend","childExtends","childExtendsRecursive"]),Ye=(t,e,r,n,o)=>{e=lt(e);for(let s in e){if(WT.has(s))continue;let i=t[s],a=e[s];if(a!==void 0&&Object.prototype.hasOwnProperty.call(e,s)&&s!=="__proto__"&&s!=="constructor"&&s!=="prototype"){if(i===void 0)t[s]=a,r&&n?v(a)&&!P(a)?(r[s]=r[s]||{},ux(r[s],a,n)):r[s]=n:r&&o?.[s]&&(r[s]=o[s]);else if(v(i)&&v(a)){let c=r?r[s]=r[s]||{}:void 0,l=o?.[s];Xe(s)?t[s]=Ye(i,a,c,n,l):Ye(i,a,c,n,l)}if(s==="extends"||s==="childExtends"||s==="childExtendsRecursive"){if(P(i)&&P(a))t[s]=i.concat(a);else if(P(i)&&v(a)){let c=Ye({},i);t[s]=Ye(c,a)}}}}return t},ux=(t,e,r,n)=>{if(n||(n=new WeakSet),!n.has(e)){n.add(e);for(let o in e){if(!Object.prototype.hasOwnProperty.call(e,o)||o==="__proto__"||o==="constructor"||o==="prototype")continue;let s=e[o];v(s)&&!P(s)?(t[o]=t[o]||{},ux(t[o],s,r,n)):t[o]=r}}},Oi=(t,e,r)=>t.reduce((n,o,s)=>{let i=lt(o),a=r?r[s]:void 0;return Ye(n,i,e,a)},{}),$i=(t,e,r={},n)=>{let o=e?.components||r.components,s=e?.pages||r.pages;if(k(t)){let i=o&&(o[t+"."+n]||o[t]||o["smbls."+t]),a=s&&t.charCodeAt(0)===47&&s[t];if(i)return i;if(a)return a;r.verbose&&(Mh==="test"||Mh==="development")&&console.warn("Extend is string but component was not found:",t);return}return t},jh=(t,e)=>[].concat(t.slice(0,1)).concat(e.slice(0,1)).concat(t.slice(1)).concat(e.slice(1)),Ri=(t,e,r,n)=>{if(!t)return[];if(t.__hash)return Li(t)||[];let s=Do(t,[],e,new Set,r,void 0,n);return r?s:Pl(t,s)},Bh=(t,e)=>{if(!t)return e;let r=P(t)?t:[t];return ko(r,e)},Vh=t=>{let e=[];function r(n){for(let o in n)Object.prototype.hasOwnProperty.call(n,o)&&(Xe(o)&&e.push(o),o==="extends"&&(typeof n[o]=="string"?e.push(n[o]):Array.isArray(n[o])&&(e=e.concat(n[o]))),typeof n[o]=="object"&&n[o]!==null&&r(n[o]))}return r(t),e},Ll=(t,e,r={})=>{let{__ref:n}=t,o=t.context||e.context,s=t.variant,i=Ro(t);if(i.length){let a=_e(i),[c,...l]=a,f=typeof c=="string"&&s&&o?.components?`${c}.${s}`:null;f&&o.components[f]?Ge([f,...l],t):Ge(a,t)}return Il(t,e,r),$l(t,e,r),Ml(t,e,r),t.component&&Ge(_e(dt(t.component,t)),t),o.defaultExtends&&Ge(_e(o.defaultExtends),t),vo(n.__extends)},Il=(t,e,r={})=>{let{__ref:n}=t;return r.ignoreChildExtends||t.ignoreChildExtends||e.childProps?.extends&&Ge(_e(e.childProps.extends),t),n.__extends},$l=(t,e,r={})=>{let{__ref:n}=t,o=r.ignoreChildExtends||t.ignoreChildExtends,s=e.childExtends;return!o&&s&&Ge(_e(s),t),n.__extends},Ml=(t,e,r={})=>{let{__ref:n}=t,o=e.childExtendsRecursive,s=r.ignoreChildExtendsRecursive||t.ignoreChildExtendsRecursive,i=t.key==="__text";return o&&!i&&!s&&Ge(_e(o),t),n.__extends},Fl=(t,e,r={})=>{let{__ref:n}=t,o=t.context||e.context,s=t.variant,i=fx(r),a=i?[...n.__extends]:null,c=vo(n.__extends.map((l,f)=>$i(l,o,r,f===0&&s)));if(i){let l=new WeakMap;for(let d=0;d<c.length;d++){let g=c[d],p=a[d];g&&v(g)&&k(p)&&l.set(g,p)}let f=[],u=Ri(c,o,f,l);n.__extendsStack=u,n.__extendsNames=f}else{let l=Ri(c,o);n.__extendsStack=l}return n.__extendsStack},Nl=(t,e,r={})=>{let{__ref:n}=t,{__extendsStack:o}=n;if(fx(r)){let s={},i=n.__extendsNames||[],a=Oi(o,s,i),c={};Ye(t,a,c,void 0,s),n.__sourcemap=c}else{let s=Oi(o);Ye(t,s)}return t},dx=(t,e,r={})=>(Ll(t,e,r),Fl(t,e,r),Nl(t,e,r),t)});function zh(t){return Object.keys(t).filter(e=>/^[A-Z]/.test(e))}function Hh(t){return Object.keys(t).filter(e=>/^\d+$/.test(e))}function Wh(t,e,r){let{context:n}=e||{},[o]=Po(r),s=r||o;return n?.components?.[s]||n?.pages?.[s]}var Xe,Uh=V(()=>{"use strict";jl();It();Xe=t=>{if(!k(t)||!t.length)return!1;let e=t.charCodeAt(0);return e>=65&&e<=90}});function px(t,e){let{props:r,on:n}=e,o=xn(t.split("on")[1]),s=n[o],i=r[t];R(s)?n[o]=(...a)=>{if(s(...a)!==!1&&R(i))return i(...a)}:n[o]=i}var hx=V(()=>{"use strict";mi();It()});function Bl(t,e={}){let r=e.cachedKeys||[];for(let n in t){let o=t[n];if(n.length>2&&n.charCodeAt(0)===111&&n.charCodeAt(1)===110&&n[2]===n[2].toUpperCase()&&(R(o)||o!=null&&Ao(this.context))){let p=xn(n.slice(2));t.on&&(t.on[p]=o),delete t[n];continue}if(n==="childProps"){t.props[n]=o,delete t[n],r.push(n);continue}let a=this.define?.[n],c=this.context?.define?.[n],l=v(a)||R(a),f=v(c)||R(c);if(l||f)continue;let u=n.charAt(0);if(mx.has(u)){t.props[n]=o,delete t[n],r.push(n);continue}let d=qh.test(n)||gx.test(n)||KT(o),g=Mr.has(n);!d&&!g&&(n in t.props||(t.props[n]=o),delete t[n],r.push(n))}return t}function Vl(t=this,e){let r=e.cachedKeys||[];for(let n in t.props){let o=t.props[n],s=n.length>2&&n.charCodeAt(0)===111&&n.charCodeAt(1)===110,i=R(o)||o!=null&&Ao(this.context);if(s&&i){px(n,t),delete t.props[n];continue}if(r.includes(n)||n==="childProps")continue;let a=n.charAt(0);if(mx.has(a))continue;let c=this.define?.[n],l=this.context?.define?.[n],f=v(c)||R(c),u=v(l)||R(l),d=qh.test(n)||gx.test(n),g=Mr.has(n);(d||g||f||u)&&(t[n]===void 0||o===null)&&(t[n]=o,t.props&&delete t.props[n])}return t}function Ul(t=this){let e=[];return Bl.call(this,t,{cachedKeys:e}),Vl.call(this,t,{cachedKeys:e}),t}function Kh(t={}){return t.on||(t.on={}),t.props||(t.props={}),Ul.call(this,t)}function Yh(t,e){this.__element.update({props:t},e)}function Bi(t){let e={update:Yh.bind(t.props),__element:t};Object.setPrototypeOf(t.props,e)}var qh,gx,mx,qT,KT,Ni,Mi,Gh,ji,Vi,Ui,zl,Fi,Xh,Zh,Jh=V(()=>{"use strict";vn();hx();pr();It();mi();Rn();qh=/^[A-Z]/,gx=/^\d+$/,mx=new Set([":","@","[","*","+","~","&",">","$","-",".","!"]),qT=new Set(["extend","props","text","tag","on","if","childExtend","children","childrenAs","state","html","attr","define","content"]),KT=t=>{if(!t||typeof t!="object"||Array.isArray(t))return!1;for(let e in t)if(qT.has(e)||qh.test(e))return!0;return!1},Ni=(t,e,r)=>{let{props:n,__ref:o}=t;if(o.__propsStack=[],n)o.__initialProps=n;else return{};return B(n)?{...n}:(o.__propsStack.push(n),{})};Mi=t=>Jt(t)("string","number")?{inheritedString:t}:t,Gh=(t,e)=>!t||!e.length?!1:e.includes(t),ji=(t,e)=>{let{__ref:r}=t,n=r.__propsStack||[],o=e.props;if(!o)return n;let s=o[t.key],i=o.childProps||e.childProps,a=t.props?.ignoreChildProps;if(i&&!a){let c=Mi(i);n.unshift(c)}if(s){let c=Mi(s);n.unshift(c)}return n};Vi=t=>{let e=new Set;return t.filter(r=>!r||Fr.has(r)||e.has(r)?!1:(e.add(r),!0))},Ui=(t,e,r)=>(e.props=t.reduce((n,o)=>{if(Fr.has(o))return n;for(;R(o);)o=dt(o,e);return at(n,lt(o,{exclude:Fr}))},{}),Bi(e),e.props),zl=(t,e)=>{let{props:r,__ref:n}=t,o=n.__propsStack||[];if(e?.props&&(o=[...ji(t,e)]),v(r)?o.push(r):r==="inherit"&&e?.props?o.push(e.props):r&&o.push(r),P(n.__extendsStack))for(let s=0;s<n.__extendsStack.length;s++){let i=n.__extendsStack[s];i.props&&i.props!==r&&o.push(i.props)}return n.__propsStack=Vi(o),n.__propsStack},Fi=(t,e)=>{let{__ref:r}=t,n=zl(t,e);n.length?Ui(n,t):(r.__propsStack=[],t.props={})},Xh=function(t,e,r){let{__ref:n}=t;if(n.__if)Fi(t,e);else try{Fi(t,e)}catch(o){t.context?.designSystem?.verbose&&console.warn("initProps error at",n.path?.join("."),o),t.props={},n.__propsStack=[]}return Bi(t),t},Zh=(t,e,r)=>{let{__ref:n}=e,s=[...n.__propsStack||[]],i=ji(e,r);return i.length&&(s=[...i,...s]),t&&(s=[t,...s]),n.__propsStack=Vi(s),n.__propsStack.length&&Ui(n.__propsStack,e),e}});var yx,Hl,Wl,ql,Kl,Qh,Gl,Yl,Xl,tg,bx=V(()=>{"use strict";jl();El();li();Jh();$h();It();yx="production",Hl=(t,e,r)=>{let n=e.childExtends&&e.childExtends.tag,o=e.childProps&&e.childProps.tag,s=Oo.body.has(r)&&r;return{text:t,tag:n||o||s||"string"}},Wl=(t,e,r)=>{if(t===void 0)return(yx==="test"||yx==="development")&&console.warn(r,"element is undefined in",e?.__ref?.path),{};if(t!==null)return t===!0?{}:Jt(t)("string","number")?Hl(t,e,r):R(t)?{props:t}:t},ql=(t,e)=>{let r={};return r.origin=t,r.parent=e,r},Kl=(t,e,r,n,o)=>{if(!e)return o;if(dr(e)){let s={key:":root",node:e};return o[`${r}_parent`]=s,s}return e},Qh=(t,e)=>{let{__ref:r}=t,{__ref:n}=e,o=e&&e.key===":root";r?.root||(r.root=o?t:n?.root)},Gl=(t,e,r)=>{let{__ref:n}=e;return n||(n=e.ref={}),n.path||(n.path=[]),n.path.concat(r)},Yl=(t,e,r,n,o)=>(n.context&&!o.context&&!t.context&&(o.context=n.context),n.context||e.context||o.context||t.context),Xl=(t,e,r)=>{let n=ql(t,e);return t.__ref=n,n.__defineCache||(n.__defineCache={}),n.__exec||(n.__exec={}),n.__execProps||(n.__execProps={}),n.__class||(n.__class={}),n.__classNames||(n.__classNames={}),n.__attr||(n.__attr={}),n.__changes||(n.__changes=[]),n.__children||(n.__children=[]),n.__extends=Pi(t,e,r),n.path=Gl(t,e,r),n},tg=(t,e,r,n,o)=>{let i=t?.__hash?{extends:[t]}:Wl(t,e,r);if(!i)return;let a=Kl(i,e,r,n,o),c=Ei(i,a,r);Xl(i,a,c);let l=Ni(i,a,c),f=Yl(i,a,c,n,o),u=i.on||{};return{...i,key:c,props:l,parent:a,context:f,on:u}}});var eg,Zl,Jl,Ql,tf,rg,ef,ng,og,sg,ig,_x,Lo,Pn,wx,xx,Sx,zi,Ze,kx=V(()=>{"use strict";Co();vn();pr();It();eg=t=>{let{state:e,props:r,__ref:n}=t,o=r?.state||e;return Jt(o)("string","number")?(n.__state=o,{value:o}):o===!0?(n.__state=t.key,{}):o?(n.__hasRootState=!0,o):!1},Zl=(t,e)=>{if(!t.includes("~/"))return;if(t.split("~/").length>1)return e.root},Jl=(t,e)=>{if(!t.includes("../"))return;let n=t.split("../").length-1;for(let o=0;o<n;o++){if(!e.parent)return null;e=e.parent}return e},Ql=(t,e,r={})=>{let n=k(t)?t.split("/"):[t],o=n.length-1;for(let s=0;s<o;s++){let i=n[s],a=n[s+1];if(i==="__proto__"||a==="__proto__")return;let c=e[i];c||(c=e[i]={}),c[a]||(c[a]={}),t=a,e=c}return r.returnParent?e:e[t]},tf=(t,e,r={})=>{let o=t.__ref.__state;if(!ef(t))return;let s=Zl(o,e.state),i=e.state;if(s)i=s,o=o.replaceAll("~/","");else{let a=Jl(o,e.state);a&&(i=a,o=o.replaceAll("../",""))}if(i)return Ql(o,i,r)},rg=(t,e)=>{let r=t.__ref,n=tf(t,e);if(n===void 0)return t.state;if(Jt(n)("object","array"))return lt(n);if(Jt(n)("string","number","boolean"))return r.__stateType=typeof n,{value:n};console.warn(r.__state,"is not present. Replacing with",{})},ef=t=>{let{__ref:e}=t,r=e?.__state;return!!(r&&Jt(r)("number","string","boolean"))},ng=function(t){return B(t)?!!(t.update&&t.parse&&t.clean&&t.create&&t.parent&&t.destroy&&t.rootUpdate&&t.parentUpdate&&t.keys&&t.values&&t.toggle&&t.replace&&t.quietUpdate&&t.quietReplace&&t.add&&t.apply&&t.applyReplace&&t.setByPath&&t.setPathCollection&&t.removeByPath&&t.removePathCollection&&t.getByPath&&t.applyFunction&&t.__element&&t.__children):!1},og=(t,e)=>{if(!t)return e||{};let r=t.split("/"),n={},o=n,s=r.length-1;for(let i=0;i<=s;i++)o[r[i]]=i===s?e||{}:{},o=o[r[i]];return n},sg=(t,e)=>{let{__element:r}=e,n=r?.state;if(!n)return;let o=lt(n,Sn),s={[t.key]:o},i=v(n.__depends)?{...n.__depends,...s}:s;return Array.isArray(n)?pi(n,{...Object.getPrototypeOf(n),__depends:i}):Object.setPrototypeOf(n,{...Object.getPrototypeOf(n),__depends:i}),o},ig=(t,e,r={})=>{let{overwrite:n}=r;if(!n)return;let o=n==="shallow";if(n==="merge"){at(t,e,Sn);return}(o?Tn:Wt)(t,e,Sn)},_x="__polyglotSeededKeys",Lo=t=>{if(!v(t))return new Set;let e=t[_x];if(!(e instanceof Set)){e=new Set;try{Object.defineProperty(t,_x,{value:e,enumerable:!1,writable:!0,configurable:!0})}catch{}}return e},Pn=(t,e,r)=>Lo(t).has(e)?!0:!v(r)||r[e]===void 0,wx="__polyglotSeededValues",xx=t=>{if(!v(t))return new Map;let e=t[wx];if(!(e instanceof Map)){e=new Map;try{Object.defineProperty(t,wx,{value:e,enumerable:!1,writable:!0,configurable:!0})}catch{}}return e},Sx=t=>{if(t===null||typeof t!="object")return typeof t+":"+String(t);try{return"json:"+JSON.stringify(t)}catch{return null}},zi=(t,e,r)=>{if(!Lo(t).has(e))return!1;let n=xx(t);if(!n.has(e))return!0;let o=v(r)||Array.isArray(r)?r[e]:void 0,s=Sx(o);return s!==null&&s===n.get(e)},Ze=(t,e,...r)=>(Lo(t).add(e),r.length&&xx(t).set(e,Sx(r[0])),e)});var GT,ag,vx=V(()=>{"use strict";GT=(t,e)=>{let r=e;for(;r;){if(r===t)return!0;r=Object.getPrototypeOf(r)}return!1},ag=(t,e)=>{let{__ref:r}=t,n=t.context||e.context||r.root?.context;n&&!n.globalScope&&(n.globalScope={});let o=e.scope||r.root?.scope,s=n?.globalScope;if(!t.scope)o?t.scope=o:s?t.scope=Object.create(s):t.scope={};else if(typeof t.scope=="object"&&t.scope!==null&&Object.getPrototypeOf(t.scope)===Object.prototype){let i=o||s;i&&!GT(t.scope,i)&&Object.setPrototypeOf(t.scope,i)}}});var Cx,rf,hr,nf,cg,lg=V(()=>{"use strict";It();Rn();Cx=(t,e)=>{let r="on"+t.charAt(0).toUpperCase()+t.slice(1);return e[r]},rf=(t,e,r,n,o)=>{if(t=To(t,e),!!R(t))try{let s=t.call(e,e,r||e.state,n||e.context,o);return s&&typeof s.then=="function"&&s.catch(i=>{e.error=i,i instanceof ReferenceError?console.warn("[DOMQL] Async event warning:",i.message):console.error("[DOMQL] Async event error:",i)}),s}catch(s){if(e.error=s,s instanceof ReferenceError?console.warn("[DOMQL] Event handler warning:",s.message):console.error("[DOMQL] Event handler error:",s),e.context?.strictMode)throw s}},hr=(t,e,r)=>{if(!e)throw new Error("Element is required");Ot(t,e,r);let n=Cx(t,e);if(n){let{state:o,context:s}=e;return rf(n,e,o,s,r)}},nf=(t,e,r,n,o,s)=>{if(t=To(t,r),!!R(t))try{let i=t.call(r,e,r,n||r.state,o||r.context,s);return i&&typeof i.then=="function"&&i.catch(a=>{r.error=a,console.error("[DOMQL] Async event update error:",a)}),i}catch(i){if(r.error=i,console.error("[DOMQL] Event update error:",i),r.context?.strictMode)throw i}},cg=(t,e,r,n)=>{Ot(t,r,e,n);let o=Cx(t,r);if(o){let{state:s,context:i}=r;return nf(o,e,r,s,i,n)}}});var fg,Hi,ug=V(()=>{"use strict";fg={},Hi={}});var Rx={};$(Rx,{restAdapter:()=>Ox,setup:()=>oO});var YT,Tx,Ex,XT,ZT,JT,Ax,gr,QT,tO,eO,dg,rO,nO,oO,Ox,Px=V(()=>{"use strict";YT=(t,e,r)=>{let n=e&&!e.startsWith("/")?"/":"",o=new URL(`${t}${n}${e}`);if(r)for(let s in r){let i=r[s];i!=null&&o.searchParams.set(s,typeof i=="object"?JSON.stringify(i):i)}return o.toString()},Tx=t=>Object.prototype.toString.call(t).slice(8,-1),Ex=["auto","json","text","blob","arrayBuffer","stream","response"],XT={json:async t=>{let e=await t.text();return e?JSON.parse(e):null},text:t=>t.text(),blob:t=>t.blob(),arrayBuffer:t=>t.arrayBuffer(),stream:t=>t.body,response:t=>t},ZT=t=>{let e=t.headers.get("content-type");return e&&e.includes("json")?t.json():t.text()},JT=async t=>{let e=await t.text(),r=t.headers.get("content-type");if(e&&r&&r.includes("json"))try{return JSON.parse(e)}catch{}return e},Ax=(t,e)=>t?.message||t?.error||e.statusText||`HTTP ${e.status}`,gr=async(t,e,r)=>{let n=r??"auto";if(!Ex.includes(n))throw new TypeError(`@symbo.ls/fetch rest: unknown responseType "${n}" \u2014 use one of: ${Ex.join(", ")}`);let o=await globalThis.fetch(t,e);if(n==="auto"){let s=await ZT(o);return{data:s,error:o.ok?null:Ax(s,o),status:o.status}}if(!o.ok){let s=await JT(n==="response"?o.clone():o);return{data:n==="response"?o:s,error:Ax(s,o),status:o.status}}return{data:await XT[n](o),error:null,status:o.status}},QT=["FormData","Blob","File","URLSearchParams","ReadableStream","ArrayBuffer"],tO=t=>t!==null&&typeof t=="object"&&(ArrayBuffer.isView(t)||QT.includes(Tx(t))),eO=t=>Array.isArray(t)?t:typeof t.entries=="function"?t.entries():Object.entries(t),dg=(...t)=>{let e={},r=new Map;for(let n of t)if(n)for(let[o,s]of eO(n)){let i=o.toLowerCase();if(r.has(i)&&delete e[r.get(i)],s==null){r.delete(i);continue}r.set(i,o),e[o]=s}return e},rO={"Content-Type":"application/json"},nO={"Content-Type":void 0},oO=async({url:t,headers:e,auth:r,fetchOptions:n})=>{if(!t)throw new Error("@symbo.ls/fetch rest: url is required");return Ox(t,e,r,n)},Ox=(t,e={},r,n={})=>{let o=r?.token||null,s=()=>o?{Authorization:`Bearer ${o}`}:null,i=u=>dg(e,s(),u),a=u=>({...n,...u}),c=(u,d,g)=>{if(!tO(d))return a({method:u,headers:dg(e,s(),rO,g),body:JSON.stringify(d)});let p={method:u,headers:dg(e,s(),nO,g),body:d};return Tx(d)==="ReadableStream"&&(p.duplex="half"),a(p)},l=(u,d)=>{let g=d||t;if(u&&(u.startsWith("http://")||u.startsWith("https://")))return u;let p=u&&!u.startsWith("/")?"/":"";return`${g}${p}${u||""}`};return{name:"rest",setToken:u=>{o=u},getSession:async()=>{if(!r?.sessionUrl)return o?{token:o}:null;let u=await gr(l(r.sessionUrl,r.baseUrl),a({headers:i()}));return u.error?null:u.data},signIn:async u=>{if(!r?.signInUrl)throw new Error("rest: auth.signInUrl not configured");let d=await gr(l(r.signInUrl,r.baseUrl),c("POST",u));return d.data?.token&&(o=d.data.token),d},signOut:async()=>(r?.signOutUrl&&await gr(l(r.signOutUrl,r.baseUrl),a({method:"POST",headers:i()})),o=null,{error:null}),select:({from:u,params:d,select:g,limit:p,offset:h,order:m,single:_,headers:x,baseUrl:y,responseType:b})=>{let w={...d};return g&&(w.select=g),p&&(w.limit=p),h&&(w.offset=h),_&&(w.single=!0),m&&(typeof m=="string"?w.order=m:Array.isArray(m)?w.order=m.map(S=>`${S.by}:${S.asc===!1?"desc":"asc"}`).join(","):m.by&&(w.order=`${m.by}:${m.asc===!1?"desc":"asc"}`)),gr(YT(y||t,u||"",w),a({headers:i(x)}),b)},rpc:({from:u,params:d,headers:g,baseUrl:p,responseType:h})=>gr(l(`rpc/${u}`,p),c("POST",d,g),h),insert:({from:u,data:d,headers:g,baseUrl:p,responseType:h})=>gr(l(u,p),c("POST",d,g),h),update:({from:u,data:d,params:g,method:p,headers:h,baseUrl:m,responseType:_})=>{let x=g?.id||d?.id,y=x?`${u}/${x}`:u;return gr(l(y,m),c(p||"PATCH",d,h),_)},upsert:({from:u,data:d,params:g,method:p,headers:h,baseUrl:m,responseType:_})=>{let x=g?.id||d?.id,y=x?`${u}/${x}`:u;return gr(l(y,m),c(p||"PUT",d,h),_)},delete:({from:u,params:d,headers:g,baseUrl:p,responseType:h})=>{let m=d?.id,_=m?`${u}/${m}`:u;return gr(l(_,p),a({method:"DELETE",headers:i(g)}),h)}}}});var Lx={};$(Lx,{localAdapter:()=>Dx,setup:()=>iO});var of,sO,iO,Dx,Ix=V(()=>{"use strict";of=(t,e)=>{if(!e)return!0;for(let r in e){let n=e[r];if(n===null){if(t[r]!==null&&t[r]!==void 0)return!1}else if(Array.isArray(n)){if(!n.includes(t[r]))return!1}else if(typeof n=="object"){for(let o in n)if(o==="gt"&&!(t[r]>n[o])||o==="gte"&&!(t[r]>=n[o])||o==="lt"&&!(t[r]<n[o])||o==="lte"&&!(t[r]<=n[o])||o==="neq"&&t[r]===n[o]||o==="like"&&!String(t[r]).includes(n[o]))return!1}else if(t[r]!==n)return!1}return!0},sO=(t,{order:e,limit:r,offset:n,single:o})=>{let s=[...t];if(e){let i=typeof e=="string"?e:e.by,a=e.asc!==!1;s.sort((c,l)=>c[i]<l[i]?a?-1:1:c[i]>l[i]?a?1:-1:0)}return n&&(s=s.slice(n)),r&&(s=s.slice(0,r)),o?{data:s[0]||null,error:null}:{data:s,error:null}},iO=async({data:t,...e})=>Dx(t,e),Dx=(t={},e={})=>{let r={},n={},o=e.persist!==!1&&typeof localStorage<"u",s=e.prefix||"smbls_db_",i=f=>{if(!r[f])if(o)try{let u=localStorage.getItem(s+f);r[f]=u?JSON.parse(u):t[f]||[]}catch{r[f]=t[f]||[]}else r[f]=t[f]||[];return r[f]},a=f=>{if(o)try{localStorage.setItem(s+f,JSON.stringify(r[f]))}catch{}},c=(f,u,d,g)=>{let p=n[f];if(p)for(let h of p)h(d,g,{event:u,table:f})},l=Date.now();return{name:"local",store:r,select:async({from:f,params:u,...d})=>{let p=i(f).filter(h=>of(h,u));return sO(p,d)},insert:async({from:f,data:u})=>{let d=i(f),p=(Array.isArray(u)?u:[u]).map(h=>{let m={id:h.id||++l,...h};return d.push(m),m});a(f);for(let h of p)c(f,"INSERT",h,null);return{data:Array.isArray(u)?p:p[0],error:null}},update:async({from:f,data:u,params:d})=>{let g=i(f),p=[];for(let h=0;h<g.length;h++)if(of(g[h],d)){let m={...g[h]};Object.assign(g[h],u),p.push(g[h]),c(f,"UPDATE",g[h],m)}return a(f),{data:p,error:null}},upsert:async({from:f,data:u,params:d})=>{let g=i(f),p=Array.isArray(u)?u:[u],h=[];for(let m of p){let _=d||(m.id!==void 0?{id:m.id}:null),x=_?g.findIndex(y=>of(y,_)):-1;if(x>-1){let y={...g[x]};Object.assign(g[x],m),h.push(g[x]),c(f,"UPDATE",g[x],y)}else{let y={id:m.id||++l,...m};g.push(y),h.push(y),c(f,"INSERT",y,null)}}return a(f),{data:Array.isArray(u)?h:h[0],error:null}},delete:async({from:f,params:u})=>{let d=i(f),g=[];for(let p=d.length-1;p>=0;p--)of(d[p],u)&&(g.push(d[p]),d.splice(p,1),c(f,"DELETE",null,g[g.length-1]));return a(f),{data:g,error:null}},subscribe:({from:f,on:u},d)=>{n[f]||(n[f]=[]);let g=(p,h,m)=>{u&&u!=="*"&&u!==m.event||d(p,h,m)};return n[f].push(g),()=>{let p=n[f].indexOf(g);p>-1&&n[f].splice(p,1)}}}}});var df={};$(df,{createAdapter:()=>dO,default:()=>kO,executeFetch:()=>Zi,fetchPlugin:()=>xg,initAdapterAuth:()=>ff,parseDuration:()=>qi,queryClient:()=>SO,registerAdapter:()=>uO,resolveDb:()=>Nx});var aO,cO,sf,Wi,af,gg,lO,fO,uO,dO,Nx,qi,qt,jx,Io,pO,Xi,Ki,Gi,cf,bg,lf,hO,$x,pg,Bx,Vx,$o,Mx,gO,Fx,mO,uf,mg,Ux,ff,_g,we,$e,Yi,wg,yO,yg,Dn,Je,Vr,bO,_O,wO,hg,xO,Zi,SO,xg,kO,Ji=V(()=>{"use strict";D();aO=["select","rpc","insert","update","upsert","delete","subscribe"],cO={rest:()=>Promise.resolve().then(()=>(Px(),Rx)),local:()=>Promise.resolve().then(()=>(Ix(),Lx))},sf=Symbol.for("@symbo.ls/fetch:CUSTOM_ADAPTERS"),Wi=(()=>{if(typeof globalThis<"u"&&globalThis[sf])return globalThis[sf];let t={};if(typeof globalThis<"u")try{return Object.defineProperty(globalThis,sf,{value:t,writable:!1,configurable:!1,enumerable:!1}),globalThis[sf]}catch{}return t})(),af=Symbol.for("@symbo.ls/fetch:PENDING_ADAPTERS"),gg=(()=>{if(typeof globalThis<"u"&&globalThis[af])return globalThis[af];let t={};if(typeof globalThis<"u")try{return Object.defineProperty(globalThis,af,{value:t,writable:!1,configurable:!1,enumerable:!1}),globalThis[af]}catch{}return t})(),lO=5e3,fO=t=>new Promise(e=>{if(Wi[t])return e(Wi[t]);let r=gg[t]||=[],n=!1,o=()=>{n||(n=!0,e(Wi[t]||null))};r.push(o),setTimeout(o,lO)}),uO=(t,e)=>{Wi[t]=e;let r=gg[t];if(r&&r.length){gg[t]=[];for(let n of r)n()}},dO=t=>{let e={};for(let r of aO)t[r]&&(e[r]=t[r]);return e.name=t.name||"custom",e},Nx=async t=>{if(!t)return null;if(typeof t.select=="function")return t;let{adapter:e,...r}=t,n=typeof e=="string"?e:typeof t=="string"?t:null;if(!n)return null;let o=Wi[n]||cO[n];if(!o&&(o=await fO(n),!o))throw new Error(`Unknown db adapter: "${n}". Use registerAdapter() for adapters with optional deps.`);let s=await o();if(!s||typeof s.setup!="function")throw new Error(`Adapter "${n}" loader returned a module without a setup() function. Got keys: [${Object.keys(s||{}).join(", ")}]. Likely a bundler chunk-resolution issue.`);return s.setup(r)},qi=t=>{if(!t)return 0;if(typeof t=="number")return t;let e=t.match(/^(\d+)(ms|s|m|h)$/);if(!e)return 0;let r=parseInt(e[1]),n=e[2];return n==="ms"?r:n==="s"?r*1e3:n==="m"?r*6e4:n==="h"?r*36e5:0},qt=new Map,jx=new Map,Io=new Map,pO=(t,e,r)=>{if(t.cache?.key)return t.cache.key;let n=mO(t.params),o=r?`${r}:`:"",s=`${t.from}:${t.method}:${o}${JSON.stringify(n||"")}`;return e?`${s}:${e}`:s},Xi=t=>qt.get(t)||null,Ki=(t,e,r)=>{let n=qt.get(t),o={data:e,error:r,time:Date.now(),stale:!1};qt.set(t,o);let s=jx.get(t);if(s)for(let i of s)R(i)&&i(o);return o},Gi=t=>{if(t){let e=qt.get(t);e&&(e.stale=!0);return}for(let[,e]of qt)e.stale=!0},cf=t=>{if(t){qt.delete(t);return}qt.clear()},bg=t=>!t&&t!==!1?{staleTime:6e4,gcTime:3e5}:t===!1?null:t===!0?{staleTime:6e4,gcTime:3e5}:typeof t=="number"?{staleTime:t,gcTime:Math.max(t*5,3e5)}:k(t)?{staleTime:qi(t),gcTime:3e5}:{staleTime:qi(t.stale||t.staleTime)||6e4,gcTime:qi(t.gc||t.gcTime||t.expire)||3e5,key:t.key},lf=null,hO=()=>{lf||(lf=setInterval(()=>{let t=Date.now();for(let[e,r]of qt){let n=jx.get(e);!(n&&n.size>0)&&t-r.time>(r.gcTime||3e5)&&qt.delete(e)}},3e4),lf.unref&&lf.unref())};hO();$x=3,pg=t=>Math.min(1e3*2**t,3e4),Bx=t=>{let e=t.retry;return e===!1?{count:0}:e===!0||e===void 0?{count:$x,delay:pg}:typeof e=="number"?{count:e,delay:pg}:{count:e.count??$x,delay:R(e.delay)?e.delay:typeof e.delay=="number"?()=>e.delay:pg}},Vx=async(t,e)=>{let{count:r,delay:n}=e,o;for(let s=0;s<=r;s++)try{let i=await t();if(i?.error){if(o=i.error,s<r){let a=R(n)?n(s,o):n;await new Promise(c=>setTimeout(c,a));continue}return i}return i}catch(i){if(o=i,s<r){let a=R(n)?n(s,i):n;await new Promise(c=>setTimeout(c,a));continue}throw i}return{data:null,error:o}},$o={focus:new Set,online:new Set},Mx=!1,gO=()=>{if(Mx||typeof window>"u")return;Mx=!0;let t=()=>{for(let r of $o.focus)r()},e=()=>{for(let r of $o.online)r()};window.addEventListener("visibilitychange",()=>{document.visibilityState==="visible"&&t()}),window.addEventListener("focus",t),window.addEventListener("online",e)},Fx=(t,e)=>{let r=e.__ref;if(t===!0)return{from:r.__state||e.key,method:"select",query:!0,on:"create"};if(k(t))return{from:t,method:"select",query:!0,on:"create"};if(v(t)){let n={...t};return n.from=n.from||r.__state||e.key,n.method=n.method||"select",n.on=n.on||"create",n.query===void 0&&(n.query=!0),n}return null},mO=t=>(!t||R(t),t),uf=(t,e)=>{let r=t?.state?.root||e?.state?.root;if(r?.lang)return r.lang},mg=(t,e)=>{let n=(t?.state?.root||e?.state?.root)?.__fetchScope;return n?String(n):void 0},Ux=(t,e,r)=>{let n;if(!t)n=void 0;else if(R(t))n=t(e,e.state);else{n={};for(let o in t){let s=t[o];n[o]=R(s)?s(e,e.state):s}}return n},ff=async(t,e)=>{if(!t||t.__authInitialized||(t.__authInitialized=!0,!t.getSession))return;let r=(n,o)=>{let s=e.state?.root;s?.update&&s.update({auth:{user:n,session:o,loading:!1}})};try{let n=await t.getSession();r(n?.user||null,n)}catch(n){console.warn("[fetch] Failed to restore auth session:",n.message)}t.onAuthStateChange&&t.onAuthStateChange((n,o)=>{r(o?.user||null,o)})},_g=async(t,e)=>{if(R(t.select))return t.auth!==!1&&await ff(t,e),t;if(t.__resolved)return t.auth!==!1&&await ff(t.__resolved,e),t.__resolved;if(t.__resolving)return t.__resolving;t.__resolving=Nx(t);let r=await t.__resolving;return delete t.__resolving,r?(r.auth=t.auth,r.url=t.url,r.key=t.key,t.__resolved=r,e.fetch=r,t.auth!==!1&&await ff(r,e),r):null},we=(t,e,...r)=>{let n=R(t[e])?t[e]:null;n&&n.call(t,...r,t,t.state,t.context)},$e=(t,e,r,...n)=>{let o=t&&R(t[r])?t[r]:null;o&&o.call(e,...n,e,e.state,e.context)},Yi=t=>{let e={},r=t.node;if(!r)return e;if(r.tagName==="FORM"){let o=new FormData(r);for(let[s,i]of o.entries())e[s]=i;return e}let n=r.querySelectorAll("input, textarea, select");for(let o=0;o<n.length;o++){let s=n[o],i=s.name||s.getAttribute("name");i&&(s.type==="checkbox"?e[i]=s.checked:s.type==="file"?e[i]=s.files:e[i]=s.value)}return e},wg=t=>t.responseType==="stream"||t.responseType==="response",yO=["Blob","File","ArrayBuffer","ReadableStream","Response"],yg=t=>t!==null&&typeof t=="object"&&(ArrayBuffer.isView(t)||yO.includes(Object.prototype.toString.call(t).slice(8,-1))),Dn=(t,e,r,n={})=>{if(!r&&yg(e))return;let o=r&&r.startsWith("~/"),s=o&&t.state?.root||t.state;if(s?.update)if(o){let i=r.slice(2);e&&typeof e=="object"&&!Array.isArray(e)&&!yg(e)&&i in e?s.update(e,{preventFetch:!0,...n}):s.update({[i]:e},{preventFetch:!0,...n})}else{let i=r?{[r]:e}:e;s.update(i,{preventFetch:!0,...n})}},Je=(t,e)=>{let r=t?.__ref;r&&(r.__fetchStatus=e,r.__fetching=e.isFetching,r.__fetchError=e.error)},Vr=async(t,e,r,n={})=>{let o=r?.fetch;if(!o||!e||!e.__ref)return;let s=e.__ref,i=mg(e,r);(!s.__fetchScopeOwner||s.__fetchScopeOwner.scope!==i)&&(s.__fetchScopeOwner={scope:i});let a=s.__fetchScopeOwner,c=()=>e.__ref===s&&s.__fetchScopeOwner===a&&mg(e,r)===i;if(t.enabled===!1||R(t.enabled)&&!t.enabled(e,e.state)||t.skip===!0||R(t.skip)&&t.skip(e,e.state))return;let l=await _g(o,r);if(!l||!c())return;let{from:f,method:u,query:d,params:g,cache:p,transform:h,single:m,auth:_,fields:x,as:y,limit:b,offset:w,order:S,headers:C,baseUrl:O,responseType:L,page:T,cursor:M,getNextPageParam:U,getPreviousPageParam:rt,infinite:Rt,placeholderData:mt,initialData:F,select:W,keepPreviousData:yt}=t,St=k(W)?W:void 0;if(d&&R(e.getQuery)){let Q=e.getQuery(l.name||"paths");Q&&(St=Q.select||Q.length&&Q.join(",")||St)}let Pt=Ux(g,e,r),G=wg(t)?null:bg(p),j=Bx(t),nt=uf(e,r),N=nt?`:${nt}`:"",J=i?`${i}:`:"",z=G?p?.key||`${f}:${u}:${J}${JSON.stringify(Pt||"")}${Rt?":infinite":""}${T?":p"+JSON.stringify(T):""}${N}`:null;if(!s.__fetchInitialized&&z&&(s.__fetchInitialized=!0,F!==void 0)){let Q=R(F)?F():F;Ki(z,Q,null)}if((u==="select"||u==="rpc")&&z&&G){let Q=Xi(z);if(Q&&!Q.error){let X=Date.now()-Q.time,Z=Q.stale||X>(G.staleTime||0),q=Q.data;if(R(W)&&(q=W(q,e,e.state)),h&&(q=h(q,e,e.state)),!c())return;if(Dn(e,q,y),!Z){Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"});return}}else if(mt!==void 0){let X=R(mt)?mt(e,e.state):mt;X!==void 0&&Dn(e,X,y)}}if(z&&Io.has(z)&&!n.force){let Q=Io.get(z);try{let X=await Promise.race([Q,new Promise((Z,q)=>setTimeout(()=>q("DEDUP_TIMEOUT"),15e3))]);if(!c())return;if(X?.data!==void 0){let Z=X.data;if(R(W)&&(Z=W(Z,e,e.state)),h&&(Z=h(Z,e,e.state)),!c())return;Dn(e,Z,y),we(e,"onFetchComplete",Z),$e(t,e,"onFetchComplete",Z)}}catch{if(!c())return}return}let cr=!Xi(z)?.data;Je(e,{isFetching:!0,isLoading:cr,isStale:!1,isSuccess:!1,error:null,status:"pending",fetchStatus:"fetching"}),we(e,"onFetchStart"),$e(t,e,"onFetchStart");let At=r?.analyze?.emitNetwork,ti=At?typeof performance<"u"?performance.now():Date.now():0;At&&At({phase:"start",mode:"query",from:f,method:u,cacheKey:z,lang:nt});let Dt=Vx(async()=>{if(!c())return;if(_!==!1&&l.auth!==!1&&l.getSession){let q=await l.getSession();if(!c())return;if(_===!0&&!q){let zt={message:"Not authenticated"};return Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:zt,status:"error",fetchStatus:"idle"}),we(e,"onFetchError",zt),$e(t,e,"onFetchError",zt),{data:null,error:zt}}}let Q=l[u];if(!R(Q))return{data:null,error:{message:`Method "${u}" not found on adapter`}};let X={from:f,select:St,params:Pt,single:m,limit:b,offset:w,order:S,headers:C,baseUrl:O};L!==void 0&&(X.responseType=L);let Z=uf(e,r);if(Z&&(X.headers={...X.headers,"Accept-Language":Z}),T!==void 0){if(v(T))T.offset!==void 0&&(X.offset=T.offset),T.limit!==void 0&&(X.limit=T.limit),T.cursor!==void 0&&(X.params={...X.params,cursor:T.cursor});else if(typeof T=="number"){let q=t.pageSize||b||20;X.offset=(T-1)*q,X.limit=q}}if(M!==void 0&&(X.params={...X.params,cursor:M}),u==="insert"||u==="update"||u==="upsert"){let q;if(x===!0||t.on==="submit")q=Yi(e);else if(P(x)){let zt=Yi(e);q={};for(let cp of x)q[cp]=zt[cp]}else e.state?.parse?q=e.state.parse():v(e.state)&&(q={...e.state});h&&(q=h(q,e,e.state)),X.data=q}if(u==="rpc"){let q=Pt;if(t.on==="submit"){let zt=Yi(e);q=t.transformParams?t.transformParams(zt,e,e.state):zt}X.params=q}if(u==="subscribe"){let q=l.subscribe({from:f,params:Pt,on:t.subscribeOn},(zt,cp,Z$)=>{c()&&(Dn(e,zt,y),we(e,"onFetchComplete",zt),$e(t,e,"onFetchComplete",zt))});return c()?(s.__unsubscribe=q,{data:null,error:null,subscribed:!0}):(R(q)&&q(),{data:null,error:null,subscribed:!0})}return Q(X)},j);z&&Io.set(z,Dt);try{let Q=await Dt;if(!c()||Q?.subscribed)return;let{data:X,error:Z}=Q||{};if(Z){z&&Ki(z,null,Z),Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:Z,status:"error",fetchStatus:"idle"}),we(e,"onFetchError",Z),$e(t,e,"onFetchError",Z),At&&At({phase:"error",mode:"query",from:f,method:u,cacheKey:z,error:Z.message||Z,durationMs:(typeof performance<"u"?performance.now():Date.now())-ti});return}if(X!==void 0){if((u==="select"||u==="rpc")&&z){let zt=Ki(z,X,null);zt.gcTime=G?.gcTime||3e5}let q=X;if(Rt&&P(X)&&(s.__pages||(s.__pages=[]),n.direction==="previous"?s.__pages.unshift(X):s.__pages.push(X),q=s.__pages.flat(),U&&(s.__nextPageParam=U(X,s.__pages),s.__hasNextPage=s.__nextPageParam!=null),rt&&(s.__prevPageParam=rt(X,s.__pages),s.__hasPreviousPage=s.__prevPageParam!=null)),R(W)&&(q=W(q,e,e.state)),h&&(q=h(q,e,e.state)),!c())return;(!yt||q!==void 0)&&Dn(e,q,y),Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"}),we(e,"onFetchComplete",q),$e(t,e,"onFetchComplete",q),At&&At({phase:"success",mode:"query",ok:!0,from:f,method:u,cacheKey:z,durationMs:(typeof performance<"u"?performance.now():Date.now())-ti})}}catch(Q){if(!c())return;Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:Q,status:"error",fetchStatus:"idle"}),we(e,"onFetchError",Q),$e(t,e,"onFetchError",Q),At&&At({phase:"error",mode:"query",from:f,method:u,cacheKey:z,error:Q.message||String(Q),durationMs:(typeof performance<"u"?performance.now():Date.now())-ti})}finally{z&&Io.get(z)===Dt&&Io.delete(z)}},bO=(t,e,r)=>{let n=t.on,o=e.__ref;o.__fetchListeners||(o.__fetchListeners=[]);let s=t.__runner||Vr;if(n==="submit"){let i=c=>{c.preventDefault(),s(t,e,r)},a=e.node;a&&(a.addEventListener("submit",i),o.__fetchListeners.push(()=>a.removeEventListener("submit",i)))}else if(n==="click"){let i=()=>s(t,e,r),a=e.node;a&&(a.addEventListener("click",i),o.__fetchListeners.push(()=>a.removeEventListener("click",i)))}else n==="stateChange"&&(o.__fetchOnStateChange=()=>s(t,e,r))},_O=(t,e,r)=>{let n=e.__ref;n.__fetchCleanups||(n.__fetchCleanups=[]),gO();let o=t.refetchInterval;if(o){let c=typeof o=="number"?o:qi(o);if(c>0){let l=setInterval(()=>{(t.refetchIntervalInBackground||typeof document>"u"||document.visibilityState==="visible")&&Vr(t,e,r,{force:!0})},c);n.__fetchCleanups.push(()=>clearInterval(l))}}let s=wg(t),i=t.refetchOnWindowFocus===void 0?!s:t.refetchOnWindowFocus!==!1,a=t.refetchOnReconnect===void 0?!s:t.refetchOnReconnect!==!1;if(i){let c=()=>{let l=uf(e,r),f=mg(e,r),u=pO(t,l,f),d=Xi(u),g=bg(t.cache);(!d||d.stale||Date.now()-d.time>(g?.staleTime||0))&&Vr(t,e,r,{force:!0})};$o.focus.add(c),n.__fetchCleanups.push(()=>$o.focus.delete(c))}if(a){let c=()=>Vr(t,e,r,{force:!0});$o.online.add(c),n.__fetchCleanups.push(()=>$o.online.delete(c))}},wO=(t,e,r)=>{if(!e.optimistic)return null;let n=t.__ref,o=e.as,s=t.state?.parse?t.state.parse():v(t.state)?{...t.state}:t.state;n.__optimisticSnapshot=s;let i=R(e.optimistic)?e.optimistic(r,s,t):e.optimistic;return i!==void 0&&Dn(t,i,o),s},hg=(t,e)=>{let r=t.__ref,n=r.__optimisticSnapshot;n!==void 0&&(Dn(t,n,e.as),delete r.__optimisticSnapshot)},xO=async(t,e,r)=>{let n=r?.fetch;if(!n)return;let o=await _g(n,r);if(!o)return;let s=e.__ref,{method:i,from:a,fields:c,transform:l,as:f,on:u,auth:d,headers:g,baseUrl:p,responseType:h,invalidates:m,optimistic:_,onMutate:x,onSuccess:y,onError:b,onSettled:w}=t,S;if(c===!0||u==="submit")S=Yi(e);else if(P(c)){let T=Yi(e);S={};for(let M of c)S[M]=T[M]}else e.state?.parse?S=e.state.parse():v(e.state)&&(S={...e.state});l&&(S=l(S,e,e.state)),R(x)&&x(S,e,e.state);let C=_?wO(e,t,S):null;s.__fetching=!0,Je(e,{isFetching:!0,isLoading:!1,isStale:!1,isSuccess:!1,error:null,status:"pending",fetchStatus:"fetching"}),we(e,"onFetchStart"),$e(t,e,"onFetchStart");let O=r?.analyze?.emitNetwork,L=O?typeof performance<"u"?performance.now():Date.now():0;O&&O({phase:"start",mode:"mutation",from:a,method:i});try{if(d!==!1&&o.auth!==!1&&o.getSession){let W=await o.getSession();if(d===!0&&!W){C!==void 0&&hg(e,t);let yt={message:"Not authenticated"};we(e,"onFetchError",yt),$e(t,e,"onFetchError",yt);return}}let T=o[i];if(!R(T))return;let M={from:a,data:S,headers:g,baseUrl:p};h!==void 0&&(M.responseType=h),t.params&&(M.params=Ux(t.params,e,r));let U=uf(e,r);U&&(M.headers={...M.headers,"Accept-Language":U});let rt=Bx(t),Rt=await Vx(()=>T(M),rt),{data:mt,error:F}=Rt||{};if(F){C!==void 0&&hg(e,t),Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:F,status:"error",fetchStatus:"idle"}),we(e,"onFetchError",F),R(b)&&b(F,S,e),R(w)&&w(null,F,S,e),O&&O({phase:"error",mode:"mutation",from:a,method:i,error:F.message||String(F),durationMs:(typeof performance<"u"?performance.now():Date.now())-L});return}if(delete s.__optimisticSnapshot,mt!==void 0&&(f||!yg(mt))){let W=f?{[f]:mt}:mt;e.state?.update&&e.state.update(W,{preventFetch:!0})}if(Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"}),we(e,"onFetchComplete",mt),$e(t,e,"onFetchComplete",mt),R(y)&&y(mt,S,e),R(w)&&w(mt,null,S,e),O&&O({phase:"success",mode:"mutation",ok:!0,from:a,method:i,durationMs:(typeof performance<"u"?performance.now():Date.now())-L}),m){let W=P(m)?m:[m];for(let yt of W)if(yt===!0||yt==="*")for(let[St]of qt)St.startsWith(a+":")&&Gi(St);else Gi(yt)}}catch(T){C!==void 0&&hg(e,t),Je(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:T,status:"error",fetchStatus:"idle"}),we(e,"onFetchError",T),$e(t,e,"onFetchError",T),R(b)&&b(T,S,e),R(w)&&w(null,T,S,e),O&&O({phase:"error",mode:"mutation",from:a,method:i,error:T.message||String(T),durationMs:(typeof performance<"u"?performance.now():Date.now())-L})}finally{s.__fetching=!1}},Zi=(t,e,r,n)=>{if(!t||!n?.fetch)return;let s=dt(t,e);if(!s)return;let i=P(s)?s.map(c=>Fx(dt(c,e),e)).filter(Boolean):[Fx(s,e)].filter(Boolean);for(let c of i){let l=c.method==="insert"||c.method==="update"||c.method==="upsert"||c.method==="delete",f=l?xO:Vr;c.on==="create"?f(c,e,n):Promise.resolve().then(()=>{bO({...c,__runner:f},e,n)}),!l&&c.on==="create"&&(c.refetchInterval||c.refetchOnWindowFocus!==!1||c.refetchOnReconnect!==!1)&&_O(c,e,n)}let a=e.__ref;a.refetch=c=>{for(let l of i)Vr(l,e,n,{force:!0,...c})},a.fetchNextPage=()=>{let c=i[0];if(!c||!c.infinite)return;let l=a.__nextPageParam;if(l==null)return;let f={...c,cursor:l};Vr(f,e,n,{direction:"next",force:!0})},a.fetchPreviousPage=()=>{let c=i[0];if(!c||!c.infinite)return;let l=a.__prevPageParam;if(l==null)return;let f={...c,cursor:l};Vr(f,e,n,{direction:"previous",force:!0})}},SO={invalidateQueries:t=>{if(!t){Gi();return}if(k(t))for(let[e]of qt)(e.startsWith(t)||e.includes(t))&&Gi(e);else if(P(t)){let e=t.join(":");for(let[r]of qt)r.includes(e)&&Gi(r)}},removeQueries:t=>{if(!t){cf();return}if(k(t))for(let[e]of qt)(e.startsWith(t)||e.includes(t))&&cf(e)},getQueryData:t=>Xi(t)?.data??void 0,setQueryData:(t,e)=>{let r=Xi(t),n=R(e)?e(r?.data):e;Ki(t,n,null)},prefetchQuery:async(t,e)=>{let r=e?.fetch;if(!r)return;let n=await _g(r,e);if(!n)return;let o=t.cache?.key||`${t.from}:${t.method||"select"}:${JSON.stringify(t.params||"")}`,s=n[t.method||"select"];if(!R(s))return;let i={from:t.from,params:t.params,limit:t.limit,offset:t.offset,order:t.order,single:t.single,headers:t.headers,baseUrl:t.baseUrl};t.responseType!==void 0&&(i.responseType=t.responseType);let a=await s(i);if(a?.data!==void 0&&!a?.error&&!wg(t)){let c=Ki(o,a.data,null);c.gcTime=bg(t.cache)?.gcTime||3e5}return a},getCache:()=>qt,clear:()=>cf(),dropNonLang:t=>{if(!t)return;let e=`:${t}`;for(let[r]of qt)r.match(/:([a-z]{2,3})$/i)&&(r.endsWith(e)||cf(r))}},xg={name:"fetch",create(t){let e=t.fetch;e&&(t.parent||Io.clear(),Zi(e,t,t.state,t.context))}},kO=Zi});function ta(t){let e=this,{__ref:r}=e,n=[].concat(t),o=r.root[n[0]];if(!n||!n.length)return console.log(n,"on",e.key,"is undefined");for(;o.key===n[0]&&(n.shift(),!!n.length);)if(o=o[n[0]],!o)return;return o}function kg(t){let e=this,{parent:r}=e;if(R(t))return r.state&&t(r,r.state,r.context)?r:r.parent?r.lookup(t):void 0;if(e[t])return e[t];for(;r.param!==t;){if(r[t])return r[t];if(r=r.parent,!r)return}return r}function vg(t){let e=this,{__ref:r}=e,n=r?.__children;if(n)for(let o=0;o<n.length;o++){let s=n[o],i=e[s];if(s===t)return i;if(R(t)){let c=t(i,i.state,i.context);if(i.state&&c)return i}let a=i?.lookdown?.(t);if(a)return a}}function Cg(t,e=[]){let r=this,{__ref:n}=r,o=n?.__children;if(o){for(let s=0;s<o.length;s++){let i=o[s],a=r[i];if(i===t)e.push(a);else if(R(t)){let c=t(a,a.state,a.context);a.state&&c&&e.push(a)}a?.lookdownAll?.(t,e)}return e.length?e:void 0}}function gf(t={}){let e=this;if(e.node?.style){for(let r in t){let n=t[r],o=e[r];if(v(n)&&o)gf.call(o,n);else if(n!=null){let s=r.replace(/[A-Z]/g,a=>"-"+a.toLowerCase()),i=String(n).replace(/\s*!important\s*$/,"");e.node.style.setProperty(s,i,"important")}}return e}}function Hx(t){let e=this;if(hr("beforeRemove",e,t)===!1)return e;R(e.node.remove)?e.node.remove():jr()||(console.warn("This item cant be removed"),e.log()),delete e.parent[e.key],e.parent.__ref&&(e.parent.__ref.__children=di(e.parent.__ref.__children,e.key)),hr("remove",e,t)}function Eg(t){return this[t]}function Ag(t,e){let r=this;if(t)return r.update(t,e),r}function Tg(t){return t?this.__ref&&this.__ref[t]:this.__ref}function Og(){let t=this.getRef("__children");return Array.isArray(t)?t.map(e=>this[e]):[]}function ea(){return this.getRef().path}function na(t){let e=null,r=n=>n.__element&&n.root?.isRootState;if(!this)e=zx();else if(r(this))e=this.root;else if(this.__ref&&this.__ref.path){let n=this.state&&r(this.state),o=R(this.state)&&this.parent.state&&r(this.parent.state);(n||o)&&(e=this.state.root||this.parent.state.root)}return e||(e=zx()),t?e?.[t]:e}function oa(t){let e=this?.__ref?.root||this.getRootState()?.__element;if(!e)throw new Error(`[smbls] getRoot() could not resolve a root element for "${this?.key||"<unknown>"}" \u2014 it has no __ref (never went through create()) and no root state is registered. Answering undefined here used to no-op silently for every caller.`);return Object.keys(e).length>0&&t?e[t]:e}function sa(t){return this.getRoot("data")&&Object.keys(this.getRoot("data")).length>0&&t?this.getRoot("data")[t]:this.getRoot("data")}function ia(t){let e=this.getRoot()?.context;return t?e[t]:e}function aa(t){let e=this.context;return t?e[t]:e}function mf(){let t=this,e=[];for(let r in t)!Object.prototype.hasOwnProperty.call(t,r)||Mr.has(r)&&!yi.has(r)||e.push(r);return e}function yf(t=[]){let e=this,r={},n=mf.call(e),o=n.includes("children"),s=t.length?new Set(t):null;for(let i=0;i<n.length;i++){let a=n[i];if(s&&s.has(a)||!Object.prototype.hasOwnProperty.call(e,a)||o&&a==="content")continue;let c=e[a];if(a==="state"){if(e.__ref&&!e.__ref.__hasRootState)continue;let l=R(c&&c.parse)?c.parse():c;r[a]=R(l)?l:JSON.parse(JSON.stringify(l||{}))}else if(a==="scope"){if(e.__ref&&!e.__ref.__hasRootScope)continue;r[a]=JSON.parse(JSON.stringify(c||{}))}else if(a==="props"){let{__element:l,update:f,...u}=e[a];r[a]=u}else Tt(c)&&Object.prototype.hasOwnProperty.call(e,a)&&(r[a]=c)}return r}function Qi(t=[],e=new WeakSet){let r=this;if(e.has(r))return;e.add(r);let n=yf.call(r,t),o=t.length?new Set(t):null;for(let s in n){if(o&&o.has(s)||!Object.prototype.hasOwnProperty.call(r,s))continue;let i=n[s];Array.isArray(i)?n[s]=i.map(a=>B(a)?Qi.call(a,t,e):a):B(i)&&(n[s]=Qi.call(i,t,e))}return n}function Fo(...t){if(Ur!=="test"&&Ur!=="development")return;let e=this,{__ref:r}=e;return console.groupCollapsed(e.key),t.length?t.forEach(n=>console.log(`%c${n}:
22
- `,"font-weight: bold",e[n])):(console.log(r.path),e.keys().forEach(o=>console.log(`%c${o}:`,"font-weight: bold",e[o]))),console.log(e),console.groupEnd(e.key),e}function Pg(...t){(Ur==="test"||Ur==="development")&&console.log(...t)}function ca(...t){(Ur==="test"||Ur==="development")&&console.warn(...t)}function Ln(...t){if(Ur==="test"||Ur==="development"){if(t[t.length-1]?.debugger)debugger;throw t[t.length-1]?.verbose&&Fo.call(this),new Error(...t)}}function la(){let t=this,{key:e,parent:r}=t,{__children:n}=r.__ref,o=n.indexOf(e),s=n[o+1];return r[s]}function fa(t){let e=t||this,{key:r,parent:n}=e,{__children:o}=n.__ref;if(!o)return;let s=o.indexOf(r);return n[o[s-1]]}function ua(t={}){let e=this;e.data||(e.data={}),e.data.varCaches||(e.data.varCaches={});let r=e.data.varCaches,n={},o;for(let s in t)t[s]!==r[s]&&(o=!0,n[s]=t[s]);return{changed:s=>{if(!o)return;let i=s(n,lt(r));for(let a in n)r[a]=n[a];return i},timeout:(s,i)=>{if(!o)return;let a=setTimeout(()=>{s(n),clearTimeout(a)},i)}}}function Dg(t,...e){let r=this.context,n=r.utils?.[t]||r.functions?.[t]||r.methods?.[t]||r.snippets?.[t];if(n&&!An(n))try{let o=n.call(this,...e);return o&&typeof o.then=="function"&&o.catch(s=>{Ln.call(this,s)}),o}catch(o){if(Ln.call(this,o),r?.strictMode)throw o}}async function da(){let t=this,e=t.context?.fetch;if(!e)return null;if(typeof e.select=="function"){if(!e.__authInitialized&&e.getSession){let{initAdapterAuth:o}=await pf();await o(e,t.context)}return e}if(e.__resolved){if(!e.__resolved.__authInitialized&&e.__resolved.getSession){let{initAdapterAuth:o}=await pf();await o(e.__resolved,t.context)}return e.__resolved}if(e.__resolving)return e.__resolving;let r=pf().then(({resolveDb:o})=>o(e));e.__resolving=r;let n=await r;if(e.__resolved=n,t.context.fetch=n,delete e.__resolving,n?.getSession){let{initAdapterAuth:o}=await pf();await o(n,t.context)}return n}function pa(t){let e=this,r=t||Hi.useStateQuery||e.context?.useStateQuery;if(!r)return null;let n={};if(Sg(e,n),r===!0)return n;let o=PO[r];return o?o(n):n}function Lg(t,e){return!!(Nr.has(t)||e?.context?.methods?.[t])}var Ur,hf,ra,Mo,zx,Rg,vO,pf,Sg,CO,Wx,EO,AO,TO,OO,RO,PO,qx=V(()=>{"use strict";lg();vn();It();pr();Tl();Co();ug();Ur="production";hf=null,ra=t=>{hf=t||null},Mo=(t,e)=>{t&&e&&hf===t&&(hf=e)},zx=()=>hf||null;Rg=(t,e,r,n)=>Object.defineProperty(t,e,{get:r,set:n});vO="[smbls] getDB needs @symbo.ls/fetch, which the smbls embed bundle does not include: add @symbo.ls/fetch to the page's importmap (the runtime import then resolves) or use the full smbls bundle.",pf=()=>Promise.resolve().then(()=>(Ji(),df)).catch(t=>{throw new Error(vO,{cause:t})});Sg=(t,e)=>{let r=t.__ref;if(!r)return;let n=r.__state;n&&typeof n=="string"&&CO(e,n);let o=r.__children;if(o)for(let a=0;a<o.length;a++){let c=t[o[a]];c&&c.__ref&&Sg(c,e)}let s=r.contentElementKey||"content",i=t[s];i&&i.__ref&&Sg(i,e)},CO=(t,e)=>{let n=e.replaceAll("../","").replaceAll("~/","").split("/"),o=t;for(let s=0;s<n.length;s++){let i=n[s];s===n.length-1?o[i]||(o[i]=!0):(o[i]===!0&&(o[i]={}),o[i]||(o[i]={}),o=o[i])}},Wx=(t,e=0)=>{let r=" ".repeat(e),n=Object.entries(t);return n.length?n.map(([s,i])=>i===!0?`${r}${s}`:`${r}${s} {
23
- ${Wx(i,e+1)}
20
+ `);e[a]=C.eval(`(function(__gs__) { ${l}
21
+ return (${c}); })`)(e)}catch{try{e[a]=C.eval(`(${c})`)}catch{e[a]=c}}}for(let[i,a]of r)if(!n(i))try{e[i]=C.eval(`(${a})`)}catch{e[i]=a}return e},ih=(t,e={verbose:!0})=>{try{return t?C.eval("("+t+")"):{}}catch(r){e.verbose&&console.warn(r)}},ah=(t,...e)=>Object.prototype.hasOwnProperty.call(t,...e),Cl=t=>{for(let e in t)return!1;return!0},ch=t=>v(t)&&Cl(t),lh=()=>Object.create(null),Ci=(t,e,r={})=>{let n=r.exclude||[],o=r.preventUnderscore;for(let s in e)n.includes(s)||!o&&vn(s)||s==="constructor"||s==="prototype"||e[s]!==void 0&&(t[s]=e[s]);return t},En=(t,e,r=[])=>{let n=r instanceof Set;for(let o in e)vn(o)||o==="constructor"||o==="prototype"||(n?r.has(o):r.includes(o))||(t[o]=e[o]);return t},Wt=(t,e,r={},n=new WeakMap)=>{if(!B(t)||!B(e)||Zt(t)||Zt(e))return e;if(n.has(t))return n.get(t);n.set(t,t);let o=r.exclude,s=o?o instanceof Set?o:new Set(o):null,i=!r.preventForce;for(let a in e){if(!Object.prototype.hasOwnProperty.call(e,a)||s&&s.has(a)||i&&vn(a)||a==="constructor"||a==="prototype")continue;let c=t[a],l=e[a];Zt(l)?t[a]=l:B(c)&&B(l)?t[a]=Wt(c,l,r,n):l!==void 0&&(t[a]=l)}return t},El=(t,e,r=new Set)=>{if(typeof t!="object"||typeof e!="object"||t===null||e===null)return t===e;if(r.has(t)||r.has(e))return!0;r.add(t),r.add(e);let n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(let s=0;s<n.length;s++){let i=n[s];if(!Object.prototype.hasOwnProperty.call(e,i)||!El(t[i],e[i],r))return!1}return!0},QT=new Set(["node","__ref"]),fh=(t,e,r=QT)=>{if(t===e)return!0;if(!B(t)||!B(e)||Zt(t)||Zt(e))return t===e;let n=r instanceof Set?r:new Set(r),o=new WeakSet;function s(i,a){if(o.has(a))return!0;o.add(a);for(let c in a){if(!Object.prototype.hasOwnProperty.call(a,c)||n.has(c))continue;if(!Object.prototype.hasOwnProperty.call(i,c))return!1;let l=a[c],f=i[c];if(Zt(l)||Zt(f)){if(l!==f)return!1}else if(B(l)&&B(f)){if(!s(f,l))return!1}else if(l!==f)return!1}return!0}return s(t,e)},uh=(t,e)=>{if(e==null)return t;if(Jt(e)("string","number"))delete t[e];else if(P(e))for(let r=0;r<e.length;r++)delete t[e[r]];else throw new Error("Invalid input: props must be a string or an array of strings");return t},Al=t=>{if(t===null||typeof t!="object")return t;let e=Object.create(null);for(let r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=Al(t[r]));return e},dh=(t,e)=>{if(t.length===0)return e;let r={},n=r;for(let o=0;o<t.length;o++)o===t.length-1&&e?n[t[o]]=e:(n[t[o]]={},n=n[t[o]]);return r},ph=(t,e)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let r=t;for(let o=0;o<e.length-1;o++){if(r[e[o]]===void 0)return;r=r[e[o]]}let n=e[e.length-1];r&&Object.prototype.hasOwnProperty.call(r,n)&&delete r[n]},hh=(t,e,r)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let n=t;for(let o=0;o<e.length-1;o++)(!n[e[o]]||typeof n[e[o]]!="object")&&(n[e[o]]={}),n=n[e[o]];return n[e[e.length-1]]=r,t},gh=(t,e)=>{if(!Array.isArray(e))throw new Error("Path must be an array.");let r=t;for(let n=0;n<e.length;n++){if(r==null)return;r=r[e[n]]}return r},mh=t=>{let r=[],n=0;for(let o=0;o<t.length;o++)if(r.length<2)r.push(t[o]);else if(t[o]===r[o%2]?n++:(r=[t[o-1],t[o]],n=1),n>=20)return(Xx==="test"||Xx==="development")&&console.warn("Warning: Potential infinite loop detected due to repeated sequence:",r),!0},yh=t=>{let e=new WeakSet;function r(n){if(n&&typeof n=="object"){if(e.has(n))return!0;e.add(n);for(let o in n)if(Object.prototype.hasOwnProperty.call(n,o)&&r(n[o]))return console.log(n,"cycle at "+o),!0}return!1}return r(t)},bh=(t,e)=>{let r=e instanceof Set?e:new Set(e),n={};for(let o in t)Object.prototype.hasOwnProperty.call(t,o)&&!r.has(o)&&(n[o]=t[o]);return n}});var Ei,Ai,Ti,Tl=V(()=>{"use strict";hr();Ei=(function(){let t=0;function e(){return t++,t}return e})(),Ai=Ei,Ti=(t,e,r)=>(dt(r,t)||r||t.key||Ei()).toString()});var Ie,_h,Nr,Ol,xh,wh,Sh,jr,kh,An,gt,Rl=V(()=>{"use strict";Ie="production",_h=Ie,Nr=(t=Ie)=>t==="production",Ol=(t=Ie)=>t==="testing"||t==="test",xh=Ol,wh=(t=Ie)=>t==="staging",Sh=(t=Ie)=>t==="local",jr=(t=Ie)=>t==="development"||t==="dev"||t==="local",kh=(t,e=Ie)=>e[t],An=(t=Ie)=>!Nr(t),gt=t=>{let e=t&&"env"in t?t.env:typeof process<"u"&&process.env?"production":void 0;if(e&&e!=="production")return!0;let r=t&&"hostname"in t?t.hostname:typeof location<"u"?location.hostname:void 0;return typeof r=="string"&&r?r==="localhost"||r==="127.0.0.1"||r.endsWith(".localhost"):!1}});function Oi(t,e,r){let n;return function(){let o=this,s=arguments,i=function(){n=null,r||t.apply(o,s)},a=r&&!n;clearTimeout(n),n=setTimeout(i,e),a&&t.apply(o,s)}}function Eh(t,e=window){let r=function(){return t.apply(e,arguments)};for(let n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n]);return r}var vh,Ch,tO,Ao,To,Oo,Ot,Tn=V(()=>{"use strict";vh=(t,e,r=300)=>{let n;return(...o)=>{clearTimeout(n),n=setTimeout(()=>{e.apply(t,o)},r)}},Ch=t=>{let e={};return(...r)=>{let n=r[0];if(n in e)return e[n];{let o=t(n);return e[n]=o,o}}},tO=/^\s*(?:async\s+)?(?:function\b|\([^)]*\)\s*=>|[a-zA-Z_$][\w$]*\s*=>)/,Ao=t=>tO.test(t),To=t=>{let e=t?.plugins;if(!e||!e.length)return!1;for(let r of e)if(r.resolveHandler)return!0;return!1},Oo=(t,e)=>{if(typeof t=="function")return t;let r=e?.context?.plugins;if(!r)return t;for(let n of r)if(n.resolveHandler){let o=n.resolveHandler(t,e);if(typeof o=="function")return o}return t},Ot=(t,e,...r)=>{let n=e?.context?.plugins;if(!n)return!1;let o=!1;for(let s of n)typeof s[t]=="function"&&(s[t](e,...r),o=!0);return o}});var Ah,dw=V(()=>{"use strict";It();hr();Ah=(t,e)=>{let{__ref:r}=t,n=t.if;if(R(n)){let o;try{o=n(t,t.state,t.context)}catch(s){typeof console<"u"&&console.warn("[DOMQL] if condition error:",s),delete r.__if;return}o?r.__if=!0:delete r.__if}else n!=null&&typeof n=="object"?dt(n,t)?r.__if=!0:delete r.__if:r.__if=!0}});var Th,Oh,pw=V(()=>{"use strict";Th=(t,...e)=>{t&&e.map(r=>console.log(r))},Oh=(t,e,...r)=>{t&&(console.group(e),r.map(n=>console.log(n)),console.groupEnd(e))}});function Ih(t){let e;try{if(!window.localStorage)return;e=window.localStorage.getItem(t)}catch{return}if(e!==null)try{return JSON.parse(e)}catch{return}}function $h(t,e){if(e!=null)try{if(!window.localStorage)return;let r=typeof e=="object"?JSON.stringify(e):e;window.localStorage.setItem(t,r)}catch{}}var Rh,Ph,Dh,Lh,hw=V(()=>{"use strict";It();li();Rh=typeof navigator>"u"?!1:/Mobi/.test(navigator.userAgent),Ph=(t,e,r=365)=>{if(Lt(st)||Lt(st.cookie))return;let n=new Date;n.setTime(n.getTime()+r*24*60*60*1e3);let o=`expires=${n.toUTCString()}`;st.cookie=`${t}=${e};${o};path=/`},Dh=t=>{if(Lt(st)||Lt(st.cookie))return;let e=`${t}=`,n=decodeURIComponent(st.cookie).split(";");for(let o=0;o<n.length;o++){let s=n[o];for(;s.charAt(0)===" ";)s=s.substring(1);if(s.indexOf(e)===0)return s.substring(e.length,s.length)}return""},Lh=t=>{Lt(st)||Lt(st.cookie)||(st.cookie=t+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;")}});var Ro,gw,Mh,Fh=V(()=>{"use strict";Ro={root:["body","html"],head:["title","base","meta","style","noscript","script"],body:new Set(["string","style","fragment","a","abbr","acronym","address","applet","area","article","aside","audio","b","basefont","bdi","bdo","big","blockquote","br","button","canvas","caption","center","cite","code","search","col","colgroup","data","datalist","dd","del","details","dfn","dialog","dir","div","dl","dt","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","meter","nav","noframes","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","hgroup","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strike","strong","sub","summary","sup","table","tbody","td","template","hgroup","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr","svg","path","circle","ellipse","line","polygon","polyline","rect","g","defs","symbol","use","text","tspan","image","clipPath","mask","pattern","marker","linearGradient","radialGradient","stop","filter","feGaussianBlur","feOffset","feMerge","feMergeNode","feBlend","feColorMatrix","feFlood","feComposite","foreignObject"])},gw=new Set(["svg","path","circle","ellipse","line","polygon","polyline","rect","g","defs","symbol","use","text","tspan","image","clipPath","mask","pattern","marker","linearGradient","radialGradient","stop","filter","feGaussianBlur","feOffset","feMerge","feMergeNode","feBlend","feColorMatrix","feFlood","feComposite","foreignObject"]),Mh=t=>Ro.body.has(t)});var Nh,mw,Po,_e,Do,Di,Ye,jh,Pl,Li,Bh,Ii,Dl,Ll,$i,Il,Lo,eO,Xe,yw,Ri,Mi,Vh,Pi,Uh,zh,$l,Ml,Fl,Nl,jl,Bl,bw,Vl=V(()=>{"use strict";Co();Hh();hr();It();Nh="production",mw=t=>t.sourcemap!==!1&&Nh!=="production",Po=t=>{if(!t)return[];let e=[],r=t.extends;r&&(P(r)?e.push(...r):e.push(r));let n=t.extend;return n&&(P(n)?e.push(...n):e.push(n)),e},_e=t=>{if(!P(t))return t;let e=[];for(let r=t.length-1;r>=0;r--){let n=t[r];e.push(P(n)?_e(n):n)}return e},Do=t=>{if(t.includes("+"))return t.split("+").filter(Ze);if(t.includes("_")){let[e]=t.split("_");return[e]}if(t.includes(".")&&!Ze(t.split(".")[1])){let[e]=t.split(".");return[e]}return[t]},Di=(t,e,r)=>{let n=[],o=Do(r);o&&(n=[...o]);let s=_e(Po(t));return s.length&&(n=[...n,...s]),n},Ye=(t,e)=>{let{__ref:r}=e,{__extends:n}=r;if(!t)return n;let o=e.variant,s=e.context;if(o&&s?.components&&!Array.isArray(t)&&typeof t=="string"){let i=`${t}.${o}`;s.components[i]&&(t=i)}return n.includes(t)||(n=Array.isArray(t)?[...n,...t]:[...n,t],r.__extends=n),n},jh=(t,e)=>{if(!t)return e;let{extends:r}=e,n=P(r)?r:[r],o=P(t)?t:[t];return{...e,extends:ko(o,n)}},Pl=()=>Math.random().toString(36).substring(2),Li={},Bh={},Ii=t=>Li[t.__hash],Dl=(t,e)=>{let r=Pl();return k(t)||(t.__hash=r),r!=="__proto__"&&r!=="constructor"&&r!=="prototype"&&(Li[r]=e),e},Ll=(t,e)=>t.__hash?e.concat(Ii(t)):Dl(t,e),$i=(t,e,r,n=new Set,o,s)=>{for(let i of t)P(i)?$i(i,e,r,n,o,s):Lo(i,e,r,n,o,void 0,s);return e},Il=(t,e,r,n=new Set,o,s,i)=>{let a=Po(t),c={...t};delete c.extends,delete c.extend;let l=!1;for(let f in c){l=!0;break}return l&&(e.push(c),o&&o.push(s)),a.length&&Lo(_e(a),e,r,n,o,s,i),e},Lo=(t,e,r,n=new Set,o,s,i)=>{if(!t||n.has(t))return e;if(P(t))return $i(t,e,r,n,o,i);let a=s;return k(t)?(a=t,t=Mi(t,r)):i&&v(t)&&i.has(t)&&(a=i.get(t)),n.has(t)||(n.add(t),t?.extends||t?.extend?Il(t,e,r,n,o,a,i):t&&(e.push(t),o&&o.push(a))),e},eO=new Set(["parent","node","__ref","__proto__","extends","extend","childExtends","childExtendsRecursive"]),Xe=(t,e,r,n,o)=>{e=lt(e);for(let s in e){if(eO.has(s))continue;let i=t[s],a=e[s];if(a!==void 0&&Object.prototype.hasOwnProperty.call(e,s)&&s!=="__proto__"&&s!=="constructor"&&s!=="prototype"){if(i===void 0)t[s]=a,r&&n?v(a)&&!P(a)?(r[s]=r[s]||{},yw(r[s],a,n)):r[s]=n:r&&o?.[s]&&(r[s]=o[s]);else if(v(i)&&v(a)){let c=r?r[s]=r[s]||{}:void 0,l=o?.[s];Ze(s)?t[s]=Xe(i,a,c,n,l):Xe(i,a,c,n,l)}if(s==="extends"||s==="childExtends"||s==="childExtendsRecursive"){if(P(i)&&P(a))t[s]=i.concat(a);else if(P(i)&&v(a)){let c=Xe({},i);t[s]=Xe(c,a)}}}}return t},yw=(t,e,r,n)=>{if(n||(n=new WeakSet),!n.has(e)){n.add(e);for(let o in e){if(!Object.prototype.hasOwnProperty.call(e,o)||o==="__proto__"||o==="constructor"||o==="prototype")continue;let s=e[o];v(s)&&!P(s)?(t[o]=t[o]||{},yw(t[o],s,r,n)):t[o]=r}}},Ri=(t,e,r)=>t.reduce((n,o,s)=>{let i=lt(o),a=r?r[s]:void 0;return Xe(n,i,e,a)},{}),Mi=(t,e,r={},n)=>{let o=e?.components||r.components,s=e?.pages||r.pages;if(k(t)){let i=o&&(o[t+"."+n]||o[t]||o["smbls."+t]),a=s&&t.charCodeAt(0)===47&&s[t];if(i)return i;if(a)return a;r.verbose&&(Nh==="test"||Nh==="development")&&console.warn("Extend is string but component was not found:",t);return}return t},Vh=(t,e)=>[].concat(t.slice(0,1)).concat(e.slice(0,1)).concat(t.slice(1)).concat(e.slice(1)),Pi=(t,e,r,n)=>{if(!t)return[];if(t.__hash)return Ii(t)||[];let s=Lo(t,[],e,new Set,r,void 0,n);return r?s:Ll(t,s)},Uh=(t,e)=>{if(!t)return e;let r=P(t)?t:[t];return ko(r,e)},zh=t=>{let e=[];function r(n){for(let o in n)Object.prototype.hasOwnProperty.call(n,o)&&(Ze(o)&&e.push(o),o==="extends"&&(typeof n[o]=="string"?e.push(n[o]):Array.isArray(n[o])&&(e=e.concat(n[o]))),typeof n[o]=="object"&&n[o]!==null&&r(n[o]))}return r(t),e},$l=(t,e,r={})=>{let{__ref:n}=t,o=t.context||e.context,s=t.variant,i=Po(t);if(i.length){let a=_e(i),[c,...l]=a,f=typeof c=="string"&&s&&o?.components?`${c}.${s}`:null;f&&o.components[f]?Ye([f,...l],t):Ye(a,t)}return Ml(t,e,r),Fl(t,e,r),Nl(t,e,r),t.component&&Ye(_e(dt(t.component,t)),t),o.defaultExtends&&Ye(_e(o.defaultExtends),t),vo(n.__extends)},Ml=(t,e,r={})=>{let{__ref:n}=t;return r.ignoreChildExtends||t.ignoreChildExtends||e.childProps?.extends&&Ye(_e(e.childProps.extends),t),n.__extends},Fl=(t,e,r={})=>{let{__ref:n}=t,o=r.ignoreChildExtends||t.ignoreChildExtends,s=e.childExtends;return!o&&s&&Ye(_e(s),t),n.__extends},Nl=(t,e,r={})=>{let{__ref:n}=t,o=e.childExtendsRecursive,s=r.ignoreChildExtendsRecursive||t.ignoreChildExtendsRecursive,i=t.key==="__text";return o&&!i&&!s&&Ye(_e(o),t),n.__extends},jl=(t,e,r={})=>{let{__ref:n}=t,o=t.context||e.context,s=t.variant,i=mw(r),a=i?[...n.__extends]:null,c=vo(n.__extends.map((l,f)=>Mi(l,o,r,f===0&&s)));if(i){let l=new WeakMap;for(let d=0;d<c.length;d++){let g=c[d],p=a[d];g&&v(g)&&k(p)&&l.set(g,p)}let f=[],u=Pi(c,o,f,l);n.__extendsStack=u,n.__extendsNames=f}else{let l=Pi(c,o);n.__extendsStack=l}return n.__extendsStack},Bl=(t,e,r={})=>{let{__ref:n}=t,{__extendsStack:o}=n;if(mw(r)){let s={},i=n.__extendsNames||[],a=Ri(o,s,i),c={};Xe(t,a,c,void 0,s),n.__sourcemap=c}else{let s=Ri(o);Xe(t,s)}return t},bw=(t,e,r={})=>($l(t,e,r),jl(t,e,r),Bl(t,e,r),t)});function Wh(t){return Object.keys(t).filter(e=>/^[A-Z]/.test(e))}function qh(t){return Object.keys(t).filter(e=>/^\d+$/.test(e))}function Kh(t,e,r){let{context:n}=e||{},[o]=Do(r),s=r||o;return n?.components?.[s]||n?.pages?.[s]}var Ze,Hh=V(()=>{"use strict";Vl();It();Ze=t=>{if(!k(t)||!t.length)return!1;let e=t.charCodeAt(0);return e>=65&&e<=90}});function _w(t,e){let{props:r,on:n}=e,o=_n(t.split("on")[1]),s=n[o],i=r[t];R(s)?n[o]=(...a)=>{if(s(...a)!==!1&&R(i))return i(...a)}:n[o]=i}var xw=V(()=>{"use strict";bi();It()});function Ul(t,e={}){let r=e.cachedKeys||[];for(let n in t){let o=t[n];if(n.length>2&&n.charCodeAt(0)===111&&n.charCodeAt(1)===110&&n[2]===n[2].toUpperCase()&&(R(o)||o!=null&&To(this.context))){let p=_n(n.slice(2));t.on&&(t.on[p]=o),delete t[n];continue}if(n==="childProps"){t.props[n]=o,delete t[n],r.push(n);continue}let a=this.define?.[n],c=this.context?.define?.[n],l=v(a)||R(a),f=v(c)||R(c);if(l||f)continue;let u=n.charAt(0);if(Sw.has(u)){t.props[n]=o,delete t[n],r.push(n);continue}let d=Gh.test(n)||ww.test(n)||nO(o),g=$r.has(n);!d&&!g&&(n in t.props||(t.props[n]=o),delete t[n],r.push(n))}return t}function zl(t=this,e){let r=e.cachedKeys||[];for(let n in t.props){let o=t.props[n],s=n.length>2&&n.charCodeAt(0)===111&&n.charCodeAt(1)===110,i=R(o)||o!=null&&To(this.context);if(s&&i){_w(n,t),delete t.props[n];continue}if(r.includes(n)||n==="childProps")continue;let a=n.charAt(0);if(Sw.has(a))continue;let c=this.define?.[n],l=this.context?.define?.[n],f=v(c)||R(c),u=v(l)||R(l),d=Gh.test(n)||ww.test(n),g=$r.has(n);(d||g||f||u)&&(t[n]===void 0||o===null)&&(t[n]=o,t.props&&delete t.props[n])}return t}function Hl(t=this){let e=[];return Ul.call(this,t,{cachedKeys:e}),zl.call(this,t,{cachedKeys:e}),t}function Yh(t={}){return t.on||(t.on={}),t.props||(t.props={}),Hl.call(this,t)}function Zh(t,e){this.__element.update({props:t},e)}function Vi(t){let e={update:Zh.bind(t.props),__element:t};Object.setPrototypeOf(t.props,e)}var Gh,ww,Sw,rO,nO,ji,Fi,Xh,Bi,Ui,zi,Wl,Ni,Jh,Qh,tg=V(()=>{"use strict";Sn();xw();hr();It();bi();Tn();Gh=/^[A-Z]/,ww=/^\d+$/,Sw=new Set([":","@","[","*","+","~","&",">","$","-",".","!"]),rO=new Set(["extend","props","text","tag","on","if","childExtend","children","childrenAs","state","html","attr","define","content"]),nO=t=>{if(!t||typeof t!="object"||Array.isArray(t))return!1;for(let e in t)if(rO.has(e)||Gh.test(e))return!0;return!1},ji=(t,e,r)=>{let{props:n,__ref:o}=t;if(o.__propsStack=[],n)o.__initialProps=n;else return{};return B(n)?{...n}:(o.__propsStack.push(n),{})};Fi=t=>Jt(t)("string","number")?{inheritedString:t}:t,Xh=(t,e)=>!t||!e.length?!1:e.includes(t),Bi=(t,e)=>{let{__ref:r}=t,n=r.__propsStack||[],o=e.props;if(!o)return n;let s=o[t.key],i=o.childProps||e.childProps,a=t.props?.ignoreChildProps;if(i&&!a){let c=Fi(i);n.unshift(c)}if(s){let c=Fi(s);n.unshift(c)}return n};Ui=t=>{let e=new Set;return t.filter(r=>!r||Mr.has(r)||e.has(r)?!1:(e.add(r),!0))},zi=(t,e,r)=>(e.props=t.reduce((n,o)=>{if(Mr.has(o))return n;for(;R(o);)o=dt(o,e);return at(n,lt(o,{exclude:Mr}))},{}),Vi(e),e.props),Wl=(t,e)=>{let{props:r,__ref:n}=t,o=n.__propsStack||[];if(e?.props&&(o=[...Bi(t,e)]),v(r)?o.push(r):r==="inherit"&&e?.props?o.push(e.props):r&&o.push(r),P(n.__extendsStack))for(let s=0;s<n.__extendsStack.length;s++){let i=n.__extendsStack[s];i.props&&i.props!==r&&o.push(i.props)}return n.__propsStack=Ui(o),n.__propsStack},Ni=(t,e)=>{let{__ref:r}=t,n=Wl(t,e);n.length?zi(n,t):(r.__propsStack=[],t.props={})},Jh=function(t,e,r){let{__ref:n}=t;if(n.__if)Ni(t,e);else try{Ni(t,e)}catch(o){t.context?.designSystem?.verbose&&console.warn("initProps error at",n.path?.join("."),o),t.props={},n.__propsStack=[]}return Vi(t),t},Qh=(t,e,r)=>{let{__ref:n}=e,s=[...n.__propsStack||[]],i=Bi(e,r);return i.length&&(s=[...i,...s]),t&&(s=[t,...s]),n.__propsStack=Ui(s),n.__propsStack.length&&zi(n.__propsStack,e),e}});var kw,ql,Kl,Gl,Yl,eg,Xl,Zl,Jl,rg,vw=V(()=>{"use strict";Vl();Tl();ui();tg();Fh();It();kw="production",ql=(t,e,r)=>{let n=e.childExtends&&e.childExtends.tag,o=e.childProps&&e.childProps.tag,s=Ro.body.has(r)&&r;return{text:t,tag:n||o||s||"string"}},Kl=(t,e,r)=>{if(t===void 0)return(kw==="test"||kw==="development")&&console.warn(r,"element is undefined in",e?.__ref?.path),{};if(t!==null)return t===!0?{}:Jt(t)("string","number")?ql(t,e,r):R(t)?{props:t}:t},Gl=(t,e)=>{let r={};return r.origin=t,r.parent=e,r},Yl=(t,e,r,n,o)=>{if(!e)return o;if(pr(e)){let s={key:":root",node:e};return o[`${r}_parent`]=s,s}return e},eg=(t,e)=>{let{__ref:r}=t,{__ref:n}=e,o=e&&e.key===":root";r?.root||(r.root=o?t:n?.root)},Xl=(t,e,r)=>{let{__ref:n}=e;return n||(n=e.ref={}),n.path||(n.path=[]),n.path.concat(r)},Zl=(t,e,r,n,o)=>(n.context&&!o.context&&!t.context&&(o.context=n.context),n.context||e.context||o.context||t.context),Jl=(t,e,r)=>{let n=Gl(t,e);return t.__ref=n,n.__defineCache||(n.__defineCache={}),n.__exec||(n.__exec={}),n.__execProps||(n.__execProps={}),n.__class||(n.__class={}),n.__classNames||(n.__classNames={}),n.__attr||(n.__attr={}),n.__changes||(n.__changes=[]),n.__children||(n.__children=[]),n.__extends=Di(t,e,r),n.path=Xl(t,e,r),n},rg=(t,e,r,n,o)=>{let i=t?.__hash?{extends:[t]}:Kl(t,e,r);if(!i)return;let a=Yl(i,e,r,n,o),c=Ti(i,a,r);Jl(i,a,c);let l=ji(i,a,c),f=Zl(i,a,c,n,o),u=i.on||{};return{...i,key:c,props:l,parent:a,context:f,on:u}}});var ng,Ql,tf,ef,rf,og,nf,sg,ig,ag,cg,Cw,Io,On,Ew,Aw,Tw,Hi,Je,Ow=V(()=>{"use strict";Co();Sn();hr();It();ng=t=>{let{state:e,props:r,__ref:n}=t,o=r?.state||e;return Jt(o)("string","number")?(n.__state=o,{value:o}):o===!0?(n.__state=t.key,{}):o?(n.__hasRootState=!0,o):!1},Ql=(t,e)=>{if(!t.includes("~/"))return;if(t.split("~/").length>1)return e.root},tf=(t,e)=>{if(!t.includes("../"))return;let n=t.split("../").length-1;for(let o=0;o<n;o++){if(!e.parent)return null;e=e.parent}return e},ef=(t,e,r={})=>{let n=k(t)?t.split("/"):[t],o=n.length-1;for(let s=0;s<o;s++){let i=n[s],a=n[s+1];if(i==="__proto__"||a==="__proto__")return;let c=e[i];c||(c=e[i]={}),c[a]||(c[a]={}),t=a,e=c}return r.returnParent?e:e[t]},rf=(t,e,r={})=>{let o=t.__ref.__state;if(!nf(t))return;let s=Ql(o,e.state),i=e.state;if(s)i=s,o=o.replaceAll("~/","");else{let a=tf(o,e.state);a&&(i=a,o=o.replaceAll("../",""))}if(i)return ef(o,i,r)},og=(t,e)=>{let r=t.__ref,n=rf(t,e);if(n===void 0)return t.state;if(Jt(n)("object","array"))return lt(n);if(Jt(n)("string","number","boolean"))return r.__stateType=typeof n,{value:n};console.warn(r.__state,"is not present. Replacing with",{})},nf=t=>{let{__ref:e}=t,r=e?.__state;return!!(r&&Jt(r)("number","string","boolean"))},sg=function(t){return B(t)?!!(t.update&&t.parse&&t.clean&&t.create&&t.parent&&t.destroy&&t.rootUpdate&&t.parentUpdate&&t.keys&&t.values&&t.toggle&&t.replace&&t.quietUpdate&&t.quietReplace&&t.add&&t.apply&&t.applyReplace&&t.setByPath&&t.setPathCollection&&t.removeByPath&&t.removePathCollection&&t.getByPath&&t.applyFunction&&t.__element&&t.__children):!1},ig=(t,e)=>{if(!t)return e||{};let r=t.split("/"),n={},o=n,s=r.length-1;for(let i=0;i<=s;i++)o[r[i]]=i===s?e||{}:{},o=o[r[i]];return n},ag=(t,e)=>{let{__element:r}=e,n=r?.state;if(!n)return;let o=lt(n,xn),s={[t.key]:o},i=v(n.__depends)?{...n.__depends,...s}:s;return Array.isArray(n)?gi(n,{...Object.getPrototypeOf(n),__depends:i}):Object.setPrototypeOf(n,{...Object.getPrototypeOf(n),__depends:i}),o},cg=(t,e,r={})=>{let{overwrite:n}=r;if(!n)return;let o=n==="shallow";if(n==="merge"){at(t,e,xn);return}(o?En:Wt)(t,e,xn)},Cw="__polyglotSeededKeys",Io=t=>{if(!v(t))return new Set;let e=t[Cw];if(!(e instanceof Set)){e=new Set;try{Object.defineProperty(t,Cw,{value:e,enumerable:!1,writable:!0,configurable:!0})}catch{}}return e},On=(t,e,r)=>Io(t).has(e)?!0:!v(r)||r[e]===void 0,Ew="__polyglotSeededValues",Aw=t=>{if(!v(t))return new Map;let e=t[Ew];if(!(e instanceof Map)){e=new Map;try{Object.defineProperty(t,Ew,{value:e,enumerable:!1,writable:!0,configurable:!0})}catch{}}return e},Tw=t=>{if(t===null||typeof t!="object")return typeof t+":"+String(t);try{return"json:"+JSON.stringify(t)}catch{return null}},Hi=(t,e,r)=>{if(!Io(t).has(e))return!1;let n=Aw(t);if(!n.has(e))return!0;let o=v(r)||Array.isArray(r)?r[e]:void 0,s=Tw(o);return s!==null&&s===n.get(e)},Je=(t,e,...r)=>(Io(t).add(e),r.length&&Aw(t).set(e,Tw(r[0])),e)});var oO,lg,Rw=V(()=>{"use strict";oO=(t,e)=>{let r=e;for(;r;){if(r===t)return!0;r=Object.getPrototypeOf(r)}return!1},lg=(t,e)=>{let{__ref:r}=t,n=t.context||e.context||r.root?.context;n&&!n.globalScope&&(n.globalScope={});let o=e.scope||r.root?.scope,s=n?.globalScope;if(!t.scope)o?t.scope=o:s?t.scope=Object.create(s):t.scope={};else if(typeof t.scope=="object"&&t.scope!==null&&Object.getPrototypeOf(t.scope)===Object.prototype){let i=o||s;i&&!oO(t.scope,i)&&Object.setPrototypeOf(t.scope,i)}}});var Pw,of,gr,sf,fg,ug=V(()=>{"use strict";It();Tn();Pw=(t,e)=>{let r="on"+t.charAt(0).toUpperCase()+t.slice(1);return e[r]},of=(t,e,r,n,o)=>{if(t=Oo(t,e),!!R(t))try{let s=t.call(e,e,r||e.state,n||e.context,o);return s&&typeof s.then=="function"&&s.catch(i=>{e.error=i,i instanceof ReferenceError?console.warn("[DOMQL] Async event warning:",i.message):console.error("[DOMQL] Async event error:",i)}),s}catch(s){if(e.error=s,s instanceof ReferenceError?console.warn("[DOMQL] Event handler warning:",s.message):console.error("[DOMQL] Event handler error:",s),e.context?.strictMode)throw s}},gr=(t,e,r)=>{if(!e)throw new Error("Element is required");Ot(t,e,r);let n=Pw(t,e);if(n){let{state:o,context:s}=e;return of(n,e,o,s,r)}},sf=(t,e,r,n,o,s)=>{if(t=Oo(t,r),!!R(t))try{let i=t.call(r,e,r,n||r.state,o||r.context,s);return i&&typeof i.then=="function"&&i.catch(a=>{r.error=a,console.error("[DOMQL] Async event update error:",a)}),i}catch(i){if(r.error=i,console.error("[DOMQL] Event update error:",i),r.context?.strictMode)throw i}},fg=(t,e,r,n)=>{Ot(t,r,e,n);let o=Pw(t,r);if(o){let{state:s,context:i}=r;return sf(o,e,r,s,i,n)}}});var dg,Wi,pg=V(()=>{"use strict";dg={},Wi={}});var Mw={};$(Mw,{restAdapter:()=>$w,setup:()=>hO});var sO,Iw,Dw,iO,aO,cO,Lw,mr,lO,fO,uO,hg,dO,pO,hO,$w,Fw=V(()=>{"use strict";sO=(t,e,r)=>{let n=e&&!e.startsWith("/")?"/":"",o=new URL(`${t}${n}${e}`);if(r)for(let s in r){let i=r[s];i!=null&&o.searchParams.set(s,typeof i=="object"?JSON.stringify(i):i)}return o.toString()},Iw=t=>Object.prototype.toString.call(t).slice(8,-1),Dw=["auto","json","text","blob","arrayBuffer","stream","response"],iO={json:async t=>{let e=await t.text();return e?JSON.parse(e):null},text:t=>t.text(),blob:t=>t.blob(),arrayBuffer:t=>t.arrayBuffer(),stream:t=>t.body,response:t=>t},aO=t=>{let e=t.headers.get("content-type");return e&&e.includes("json")?t.json():t.text()},cO=async t=>{let e=await t.text(),r=t.headers.get("content-type");if(e&&r&&r.includes("json"))try{return JSON.parse(e)}catch{}return e},Lw=(t,e)=>t?.message||t?.error||e.statusText||`HTTP ${e.status}`,mr=async(t,e,r)=>{let n=r??"auto";if(!Dw.includes(n))throw new TypeError(`@symbo.ls/fetch rest: unknown responseType "${n}" \u2014 use one of: ${Dw.join(", ")}`);let o=await globalThis.fetch(t,e);if(n==="auto"){let s=await aO(o);return{data:s,error:o.ok?null:Lw(s,o),status:o.status}}if(!o.ok){let s=await cO(n==="response"?o.clone():o);return{data:n==="response"?o:s,error:Lw(s,o),status:o.status}}return{data:await iO[n](o),error:null,status:o.status}},lO=["FormData","Blob","File","URLSearchParams","ReadableStream","ArrayBuffer"],fO=t=>t!==null&&typeof t=="object"&&(ArrayBuffer.isView(t)||lO.includes(Iw(t))),uO=t=>Array.isArray(t)?t:typeof t.entries=="function"?t.entries():Object.entries(t),hg=(...t)=>{let e={},r=new Map;for(let n of t)if(n)for(let[o,s]of uO(n)){let i=o.toLowerCase();if(r.has(i)&&delete e[r.get(i)],s==null){r.delete(i);continue}r.set(i,o),e[o]=s}return e},dO={"Content-Type":"application/json"},pO={"Content-Type":void 0},hO=async({url:t,headers:e,auth:r,fetchOptions:n})=>{if(!t)throw new Error("@symbo.ls/fetch rest: url is required");return $w(t,e,r,n)},$w=(t,e={},r,n={})=>{let o=r?.token||null,s=()=>o?{Authorization:`Bearer ${o}`}:null,i=u=>hg(e,s(),u),a=u=>({...n,...u}),c=(u,d,g)=>{if(!fO(d))return a({method:u,headers:hg(e,s(),dO,g),body:JSON.stringify(d)});let p={method:u,headers:hg(e,s(),pO,g),body:d};return Iw(d)==="ReadableStream"&&(p.duplex="half"),a(p)},l=(u,d)=>{let g=d||t;if(u&&(u.startsWith("http://")||u.startsWith("https://")))return u;let p=u&&!u.startsWith("/")?"/":"";return`${g}${p}${u||""}`};return{name:"rest",setToken:u=>{o=u},getSession:async()=>{if(!r?.sessionUrl)return o?{token:o}:null;let u=await mr(l(r.sessionUrl,r.baseUrl),a({headers:i()}));return u.error?null:u.data},signIn:async u=>{if(!r?.signInUrl)throw new Error("rest: auth.signInUrl not configured");let d=await mr(l(r.signInUrl,r.baseUrl),c("POST",u));return d.data?.token&&(o=d.data.token),d},signOut:async()=>(r?.signOutUrl&&await mr(l(r.signOutUrl,r.baseUrl),a({method:"POST",headers:i()})),o=null,{error:null}),select:({from:u,params:d,select:g,limit:p,offset:h,order:m,single:y,headers:x,baseUrl:b,responseType:_})=>{let w={...d};return g&&(w.select=g),p&&(w.limit=p),h&&(w.offset=h),y&&(w.single=!0),m&&(typeof m=="string"?w.order=m:Array.isArray(m)?w.order=m.map(S=>`${S.by}:${S.asc===!1?"desc":"asc"}`).join(","):m.by&&(w.order=`${m.by}:${m.asc===!1?"desc":"asc"}`)),mr(sO(b||t,u||"",w),a({headers:i(x)}),_)},rpc:({from:u,params:d,headers:g,baseUrl:p,responseType:h})=>mr(l(`rpc/${u}`,p),c("POST",d,g),h),insert:({from:u,data:d,headers:g,baseUrl:p,responseType:h})=>mr(l(u,p),c("POST",d,g),h),update:({from:u,data:d,params:g,method:p,headers:h,baseUrl:m,responseType:y})=>{let x=g?.id||d?.id,b=x?`${u}/${x}`:u;return mr(l(b,m),c(p||"PATCH",d,h),y)},upsert:({from:u,data:d,params:g,method:p,headers:h,baseUrl:m,responseType:y})=>{let x=g?.id||d?.id,b=x?`${u}/${x}`:u;return mr(l(b,m),c(p||"PUT",d,h),y)},delete:({from:u,params:d,headers:g,baseUrl:p,responseType:h})=>{let m=d?.id,y=m?`${u}/${m}`:u;return mr(l(y,p),a({method:"DELETE",headers:i(g)}),h)}}}});var jw={};$(jw,{localAdapter:()=>Nw,setup:()=>mO});var af,gO,mO,Nw,Bw=V(()=>{"use strict";af=(t,e)=>{if(!e)return!0;for(let r in e){let n=e[r];if(n===null){if(t[r]!==null&&t[r]!==void 0)return!1}else if(Array.isArray(n)){if(!n.includes(t[r]))return!1}else if(typeof n=="object"){for(let o in n)if(o==="gt"&&!(t[r]>n[o])||o==="gte"&&!(t[r]>=n[o])||o==="lt"&&!(t[r]<n[o])||o==="lte"&&!(t[r]<=n[o])||o==="neq"&&t[r]===n[o]||o==="like"&&!String(t[r]).includes(n[o]))return!1}else if(t[r]!==n)return!1}return!0},gO=(t,{order:e,limit:r,offset:n,single:o})=>{let s=[...t];if(e){let i=typeof e=="string"?e:e.by,a=e.asc!==!1;s.sort((c,l)=>c[i]<l[i]?a?-1:1:c[i]>l[i]?a?1:-1:0)}return n&&(s=s.slice(n)),r&&(s=s.slice(0,r)),o?{data:s[0]||null,error:null}:{data:s,error:null}},mO=async({data:t,...e})=>Nw(t,e),Nw=(t={},e={})=>{let r={},n={},o=e.persist!==!1&&typeof localStorage<"u",s=e.prefix||"smbls_db_",i=f=>{if(!r[f])if(o)try{let u=localStorage.getItem(s+f);r[f]=u?JSON.parse(u):t[f]||[]}catch{r[f]=t[f]||[]}else r[f]=t[f]||[];return r[f]},a=f=>{if(o)try{localStorage.setItem(s+f,JSON.stringify(r[f]))}catch{}},c=(f,u,d,g)=>{let p=n[f];if(p)for(let h of p)h(d,g,{event:u,table:f})},l=Date.now();return{name:"local",store:r,select:async({from:f,params:u,...d})=>{let p=i(f).filter(h=>af(h,u));return gO(p,d)},insert:async({from:f,data:u})=>{let d=i(f),p=(Array.isArray(u)?u:[u]).map(h=>{let m={id:h.id||++l,...h};return d.push(m),m});a(f);for(let h of p)c(f,"INSERT",h,null);return{data:Array.isArray(u)?p:p[0],error:null}},update:async({from:f,data:u,params:d})=>{let g=i(f),p=[];for(let h=0;h<g.length;h++)if(af(g[h],d)){let m={...g[h]};Object.assign(g[h],u),p.push(g[h]),c(f,"UPDATE",g[h],m)}return a(f),{data:p,error:null}},upsert:async({from:f,data:u,params:d})=>{let g=i(f),p=Array.isArray(u)?u:[u],h=[];for(let m of p){let y=d||(m.id!==void 0?{id:m.id}:null),x=y?g.findIndex(b=>af(b,y)):-1;if(x>-1){let b={...g[x]};Object.assign(g[x],m),h.push(g[x]),c(f,"UPDATE",g[x],b)}else{let b={id:m.id||++l,...m};g.push(b),h.push(b),c(f,"INSERT",b,null)}}return a(f),{data:Array.isArray(u)?h:h[0],error:null}},delete:async({from:f,params:u})=>{let d=i(f),g=[];for(let p=d.length-1;p>=0;p--)af(d[p],u)&&(g.push(d[p]),d.splice(p,1),c(f,"DELETE",null,g[g.length-1]));return a(f),{data:g,error:null}},subscribe:({from:f,on:u},d)=>{n[f]||(n[f]=[]);let g=(p,h,m)=>{u&&u!=="*"&&u!==m.event||d(p,h,m)};return n[f].push(g),()=>{let p=n[f].indexOf(g);p>-1&&n[f].splice(p,1)}}}}});var hf={};$(hf,{createAdapter:()=>SO,default:()=>LO,executeFetch:()=>Ji,fetchPlugin:()=>kg,initAdapterAuth:()=>df,parseDuration:()=>Ki,queryClient:()=>DO,registerAdapter:()=>wO,resolveDb:()=>Hw});var yO,bO,cf,qi,lf,yg,_O,xO,wO,SO,Hw,Ki,qt,Ww,$o,kO,Zi,Gi,Yi,ff,xg,uf,vO,Vw,gg,qw,Kw,Mo,Uw,CO,zw,EO,pf,bg,Gw,df,wg,xe,$e,Xi,Sg,AO,_g,Rn,Qe,Br,TO,OO,RO,mg,PO,Ji,DO,kg,LO,Qi=V(()=>{"use strict";D();yO=["select","rpc","insert","update","upsert","delete","subscribe"],bO={rest:()=>Promise.resolve().then(()=>(Fw(),Mw)),local:()=>Promise.resolve().then(()=>(Bw(),jw))},cf=Symbol.for("@symbo.ls/fetch:CUSTOM_ADAPTERS"),qi=(()=>{if(typeof globalThis<"u"&&globalThis[cf])return globalThis[cf];let t={};if(typeof globalThis<"u")try{return Object.defineProperty(globalThis,cf,{value:t,writable:!1,configurable:!1,enumerable:!1}),globalThis[cf]}catch{}return t})(),lf=Symbol.for("@symbo.ls/fetch:PENDING_ADAPTERS"),yg=(()=>{if(typeof globalThis<"u"&&globalThis[lf])return globalThis[lf];let t={};if(typeof globalThis<"u")try{return Object.defineProperty(globalThis,lf,{value:t,writable:!1,configurable:!1,enumerable:!1}),globalThis[lf]}catch{}return t})(),_O=5e3,xO=t=>new Promise(e=>{if(qi[t])return e(qi[t]);let r=yg[t]||=[],n=!1,o=()=>{n||(n=!0,e(qi[t]||null))};r.push(o),setTimeout(o,_O)}),wO=(t,e)=>{qi[t]=e;let r=yg[t];if(r&&r.length){yg[t]=[];for(let n of r)n()}},SO=t=>{let e={};for(let r of yO)t[r]&&(e[r]=t[r]);return e.name=t.name||"custom",e},Hw=async t=>{if(!t)return null;if(typeof t.select=="function")return t;let{adapter:e,...r}=t,n=typeof e=="string"?e:typeof t=="string"?t:null;if(!n)return null;let o=qi[n]||bO[n];if(!o&&(o=await xO(n),!o))throw new Error(`Unknown db adapter: "${n}". Use registerAdapter() for adapters with optional deps.`);let s=await o();if(!s||typeof s.setup!="function")throw new Error(`Adapter "${n}" loader returned a module without a setup() function. Got keys: [${Object.keys(s||{}).join(", ")}]. Likely a bundler chunk-resolution issue.`);return s.setup(r)},Ki=t=>{if(!t)return 0;if(typeof t=="number")return t;let e=t.match(/^(\d+)(ms|s|m|h)$/);if(!e)return 0;let r=parseInt(e[1]),n=e[2];return n==="ms"?r:n==="s"?r*1e3:n==="m"?r*6e4:n==="h"?r*36e5:0},qt=new Map,Ww=new Map,$o=new Map,kO=(t,e,r)=>{if(t.cache?.key)return t.cache.key;let n=EO(t.params),o=r?`${r}:`:"",s=`${t.from}:${t.method}:${o}${JSON.stringify(n||"")}`;return e?`${s}:${e}`:s},Zi=t=>qt.get(t)||null,Gi=(t,e,r)=>{let n=qt.get(t),o={data:e,error:r,time:Date.now(),stale:!1};qt.set(t,o);let s=Ww.get(t);if(s)for(let i of s)R(i)&&i(o);return o},Yi=t=>{if(t){let e=qt.get(t);e&&(e.stale=!0);return}for(let[,e]of qt)e.stale=!0},ff=t=>{if(t){qt.delete(t);return}qt.clear()},xg=t=>!t&&t!==!1?{staleTime:6e4,gcTime:3e5}:t===!1?null:t===!0?{staleTime:6e4,gcTime:3e5}:typeof t=="number"?{staleTime:t,gcTime:Math.max(t*5,3e5)}:k(t)?{staleTime:Ki(t),gcTime:3e5}:{staleTime:Ki(t.stale||t.staleTime)||6e4,gcTime:Ki(t.gc||t.gcTime||t.expire)||3e5,key:t.key},uf=null,vO=()=>{uf||(uf=setInterval(()=>{let t=Date.now();for(let[e,r]of qt){let n=Ww.get(e);!(n&&n.size>0)&&t-r.time>(r.gcTime||3e5)&&qt.delete(e)}},3e4),uf.unref&&uf.unref())};vO();Vw=3,gg=t=>Math.min(1e3*2**t,3e4),qw=t=>{let e=t.retry;return e===!1?{count:0}:e===!0||e===void 0?{count:Vw,delay:gg}:typeof e=="number"?{count:e,delay:gg}:{count:e.count??Vw,delay:R(e.delay)?e.delay:typeof e.delay=="number"?()=>e.delay:gg}},Kw=async(t,e)=>{let{count:r,delay:n}=e,o;for(let s=0;s<=r;s++)try{let i=await t();if(i?.error){if(o=i.error,s<r){let a=R(n)?n(s,o):n;await new Promise(c=>setTimeout(c,a));continue}return i}return i}catch(i){if(o=i,s<r){let a=R(n)?n(s,i):n;await new Promise(c=>setTimeout(c,a));continue}throw i}return{data:null,error:o}},Mo={focus:new Set,online:new Set},Uw=!1,CO=()=>{if(Uw||typeof window>"u")return;Uw=!0;let t=()=>{for(let r of Mo.focus)r()},e=()=>{for(let r of Mo.online)r()};window.addEventListener("visibilitychange",()=>{document.visibilityState==="visible"&&t()}),window.addEventListener("focus",t),window.addEventListener("online",e)},zw=(t,e)=>{let r=e.__ref;if(t===!0)return{from:r.__state||e.key,method:"select",query:!0,on:"create"};if(k(t))return{from:t,method:"select",query:!0,on:"create"};if(v(t)){let n={...t};return n.from=n.from||r.__state||e.key,n.method=n.method||"select",n.on=n.on||"create",n.query===void 0&&(n.query=!0),n}return null},EO=t=>(!t||R(t),t),pf=(t,e)=>{let r=t?.state?.root||e?.state?.root;if(r?.lang)return r.lang},bg=(t,e)=>{let n=(t?.state?.root||e?.state?.root)?.__fetchScope;return n?String(n):void 0},Gw=(t,e,r)=>{let n;if(!t)n=void 0;else if(R(t))n=t(e,e.state);else{n={};for(let o in t){let s=t[o];n[o]=R(s)?s(e,e.state):s}}return n},df=async(t,e)=>{if(!t||t.__authInitialized||(t.__authInitialized=!0,!t.getSession))return;let r=(n,o)=>{let s=e.state?.root;s?.update&&s.update({auth:{user:n,session:o,loading:!1}})};try{let n=await t.getSession();r(n?.user||null,n)}catch(n){console.warn("[fetch] Failed to restore auth session:",n.message)}t.onAuthStateChange&&t.onAuthStateChange((n,o)=>{r(o?.user||null,o)})},wg=async(t,e)=>{if(R(t.select))return t.auth!==!1&&await df(t,e),t;if(t.__resolved)return t.auth!==!1&&await df(t.__resolved,e),t.__resolved;if(t.__resolving)return t.__resolving;t.__resolving=Hw(t);let r=await t.__resolving;return delete t.__resolving,r?(r.auth=t.auth,r.url=t.url,r.key=t.key,t.__resolved=r,e.fetch=r,t.auth!==!1&&await df(r,e),r):null},xe=(t,e,...r)=>{let n=R(t[e])?t[e]:null;n&&n.call(t,...r,t,t.state,t.context)},$e=(t,e,r,...n)=>{let o=t&&R(t[r])?t[r]:null;o&&o.call(e,...n,e,e.state,e.context)},Xi=t=>{let e={},r=t.node;if(!r)return e;if(r.tagName==="FORM"){let o=new FormData(r);for(let[s,i]of o.entries())e[s]=i;return e}let n=r.querySelectorAll("input, textarea, select");for(let o=0;o<n.length;o++){let s=n[o],i=s.name||s.getAttribute("name");i&&(s.type==="checkbox"?e[i]=s.checked:s.type==="file"?e[i]=s.files:e[i]=s.value)}return e},Sg=t=>t.responseType==="stream"||t.responseType==="response",AO=["Blob","File","ArrayBuffer","ReadableStream","Response"],_g=t=>t!==null&&typeof t=="object"&&(ArrayBuffer.isView(t)||AO.includes(Object.prototype.toString.call(t).slice(8,-1))),Rn=(t,e,r,n={})=>{if(!r&&_g(e))return;let o=r&&r.startsWith("~/"),s=o&&t.state?.root||t.state;if(s?.update)if(o){let i=r.slice(2);e&&typeof e=="object"&&!Array.isArray(e)&&!_g(e)&&i in e?s.update(e,{preventFetch:!0,...n}):s.update({[i]:e},{preventFetch:!0,...n})}else{let i=r?{[r]:e}:e;s.update(i,{preventFetch:!0,...n})}},Qe=(t,e)=>{let r=t?.__ref;r&&(r.__fetchStatus=e,r.__fetching=e.isFetching,r.__fetchError=e.error)},Br=async(t,e,r,n={})=>{let o=r?.fetch;if(!o||!e||!e.__ref)return;let s=e.__ref,i=bg(e,r);(!s.__fetchScopeOwner||s.__fetchScopeOwner.scope!==i)&&(s.__fetchScopeOwner={scope:i});let a=s.__fetchScopeOwner,c=()=>e.__ref===s&&s.__fetchScopeOwner===a&&bg(e,r)===i;if(t.enabled===!1||R(t.enabled)&&!t.enabled(e,e.state)||t.skip===!0||R(t.skip)&&t.skip(e,e.state))return;let l=await wg(o,r);if(!l||!c())return;let{from:f,method:u,query:d,params:g,cache:p,transform:h,single:m,auth:y,fields:x,as:b,limit:_,offset:w,order:S,headers:E,baseUrl:O,responseType:L,page:T,cursor:M,getNextPageParam:U,getPreviousPageParam:rt,infinite:Rt,placeholderData:mt,initialData:F,select:W,keepPreviousData:yt}=t,St=k(W)?W:void 0;if(d&&R(e.getQuery)){let Q=e.getQuery(l.name||"paths");Q&&(St=Q.select||Q.length&&Q.join(",")||St)}let Pt=Gw(g,e,r),G=Sg(t)?null:xg(p),j=qw(t),nt=pf(e,r),N=nt?`:${nt}`:"",J=i?`${i}:`:"",z=G?p?.key||`${f}:${u}:${J}${JSON.stringify(Pt||"")}${Rt?":infinite":""}${T?":p"+JSON.stringify(T):""}${N}`:null;if(!s.__fetchInitialized&&z&&(s.__fetchInitialized=!0,F!==void 0)){let Q=R(F)?F():F;Gi(z,Q,null)}if((u==="select"||u==="rpc")&&z&&G){let Q=Zi(z);if(Q&&!Q.error){let X=Date.now()-Q.time,Z=Q.stale||X>(G.staleTime||0),q=Q.data;if(R(W)&&(q=W(q,e,e.state)),h&&(q=h(q,e,e.state)),!c())return;if(Rn(e,q,b),!Z){Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"});return}}else if(mt!==void 0){let X=R(mt)?mt(e,e.state):mt;X!==void 0&&Rn(e,X,b)}}if(z&&$o.has(z)&&!n.force){let Q=$o.get(z);try{let X=await Promise.race([Q,new Promise((Z,q)=>setTimeout(()=>q("DEDUP_TIMEOUT"),15e3))]);if(!c())return;if(X?.data!==void 0){let Z=X.data;if(R(W)&&(Z=W(Z,e,e.state)),h&&(Z=h(Z,e,e.state)),!c())return;Rn(e,Z,b),xe(e,"onFetchComplete",Z),$e(t,e,"onFetchComplete",Z)}}catch{if(!c())return}return}let cr=!Zi(z)?.data;Qe(e,{isFetching:!0,isLoading:cr,isStale:!1,isSuccess:!1,error:null,status:"pending",fetchStatus:"fetching"}),xe(e,"onFetchStart"),$e(t,e,"onFetchStart");let At=r?.analyze?.emitNetwork,ri=At?typeof performance<"u"?performance.now():Date.now():0;At&&At({phase:"start",mode:"query",from:f,method:u,cacheKey:z,lang:nt});let Dt=Kw(async()=>{if(!c())return;if(y!==!1&&l.auth!==!1&&l.getSession){let q=await l.getSession();if(!c())return;if(y===!0&&!q){let zt={message:"Not authenticated"};return Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:zt,status:"error",fetchStatus:"idle"}),xe(e,"onFetchError",zt),$e(t,e,"onFetchError",zt),{data:null,error:zt}}}let Q=l[u];if(!R(Q))return{data:null,error:{message:`Method "${u}" not found on adapter`}};let X={from:f,select:St,params:Pt,single:m,limit:_,offset:w,order:S,headers:E,baseUrl:O};L!==void 0&&(X.responseType=L);let Z=pf(e,r);if(Z&&(X.headers={...X.headers,"Accept-Language":Z}),T!==void 0){if(v(T))T.offset!==void 0&&(X.offset=T.offset),T.limit!==void 0&&(X.limit=T.limit),T.cursor!==void 0&&(X.params={...X.params,cursor:T.cursor});else if(typeof T=="number"){let q=t.pageSize||_||20;X.offset=(T-1)*q,X.limit=q}}if(M!==void 0&&(X.params={...X.params,cursor:M}),u==="insert"||u==="update"||u==="upsert"){let q;if(x===!0||t.on==="submit")q=Xi(e);else if(P(x)){let zt=Xi(e);q={};for(let fp of x)q[fp]=zt[fp]}else e.state?.parse?q=e.state.parse():v(e.state)&&(q={...e.state});h&&(q=h(q,e,e.state)),X.data=q}if(u==="rpc"){let q=Pt;if(t.on==="submit"){let zt=Xi(e);q=t.transformParams?t.transformParams(zt,e,e.state):zt}X.params=q}if(u==="subscribe"){let q=l.subscribe({from:f,params:Pt,on:t.subscribeOn},(zt,fp,dM)=>{c()&&(Rn(e,zt,b),xe(e,"onFetchComplete",zt),$e(t,e,"onFetchComplete",zt))});return c()?(s.__unsubscribe=q,{data:null,error:null,subscribed:!0}):(R(q)&&q(),{data:null,error:null,subscribed:!0})}return Q(X)},j);z&&$o.set(z,Dt);try{let Q=await Dt;if(!c()||Q?.subscribed)return;let{data:X,error:Z}=Q||{};if(Z){z&&Gi(z,null,Z),Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:Z,status:"error",fetchStatus:"idle"}),xe(e,"onFetchError",Z),$e(t,e,"onFetchError",Z),At&&At({phase:"error",mode:"query",from:f,method:u,cacheKey:z,error:Z.message||Z,durationMs:(typeof performance<"u"?performance.now():Date.now())-ri});return}if(X!==void 0){if((u==="select"||u==="rpc")&&z){let zt=Gi(z,X,null);zt.gcTime=G?.gcTime||3e5}let q=X;if(Rt&&P(X)&&(s.__pages||(s.__pages=[]),n.direction==="previous"?s.__pages.unshift(X):s.__pages.push(X),q=s.__pages.flat(),U&&(s.__nextPageParam=U(X,s.__pages),s.__hasNextPage=s.__nextPageParam!=null),rt&&(s.__prevPageParam=rt(X,s.__pages),s.__hasPreviousPage=s.__prevPageParam!=null)),R(W)&&(q=W(q,e,e.state)),h&&(q=h(q,e,e.state)),!c())return;(!yt||q!==void 0)&&Rn(e,q,b),Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"}),xe(e,"onFetchComplete",q),$e(t,e,"onFetchComplete",q),At&&At({phase:"success",mode:"query",ok:!0,from:f,method:u,cacheKey:z,durationMs:(typeof performance<"u"?performance.now():Date.now())-ri})}}catch(Q){if(!c())return;Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:Q,status:"error",fetchStatus:"idle"}),xe(e,"onFetchError",Q),$e(t,e,"onFetchError",Q),At&&At({phase:"error",mode:"query",from:f,method:u,cacheKey:z,error:Q.message||String(Q),durationMs:(typeof performance<"u"?performance.now():Date.now())-ri})}finally{z&&$o.get(z)===Dt&&$o.delete(z)}},TO=(t,e,r)=>{let n=t.on,o=e.__ref;o.__fetchListeners||(o.__fetchListeners=[]);let s=t.__runner||Br;if(n==="submit"){let i=c=>{c.preventDefault(),s(t,e,r)},a=e.node;a&&(a.addEventListener("submit",i),o.__fetchListeners.push(()=>a.removeEventListener("submit",i)))}else if(n==="click"){let i=()=>s(t,e,r),a=e.node;a&&(a.addEventListener("click",i),o.__fetchListeners.push(()=>a.removeEventListener("click",i)))}else n==="stateChange"&&(o.__fetchOnStateChange=()=>s(t,e,r))},OO=(t,e,r)=>{let n=e.__ref;n.__fetchCleanups||(n.__fetchCleanups=[]),CO();let o=t.refetchInterval;if(o){let c=typeof o=="number"?o:Ki(o);if(c>0){let l=setInterval(()=>{(t.refetchIntervalInBackground||typeof document>"u"||document.visibilityState==="visible")&&Br(t,e,r,{force:!0})},c);n.__fetchCleanups.push(()=>clearInterval(l))}}let s=Sg(t),i=t.refetchOnWindowFocus===void 0?!s:t.refetchOnWindowFocus!==!1,a=t.refetchOnReconnect===void 0?!s:t.refetchOnReconnect!==!1;if(i){let c=()=>{let l=pf(e,r),f=bg(e,r),u=kO(t,l,f),d=Zi(u),g=xg(t.cache);(!d||d.stale||Date.now()-d.time>(g?.staleTime||0))&&Br(t,e,r,{force:!0})};Mo.focus.add(c),n.__fetchCleanups.push(()=>Mo.focus.delete(c))}if(a){let c=()=>Br(t,e,r,{force:!0});Mo.online.add(c),n.__fetchCleanups.push(()=>Mo.online.delete(c))}},RO=(t,e,r)=>{if(!e.optimistic)return null;let n=t.__ref,o=e.as,s=t.state?.parse?t.state.parse():v(t.state)?{...t.state}:t.state;n.__optimisticSnapshot=s;let i=R(e.optimistic)?e.optimistic(r,s,t):e.optimistic;return i!==void 0&&Rn(t,i,o),s},mg=(t,e)=>{let r=t.__ref,n=r.__optimisticSnapshot;n!==void 0&&(Rn(t,n,e.as),delete r.__optimisticSnapshot)},PO=async(t,e,r)=>{let n=r?.fetch;if(!n)return;let o=await wg(n,r);if(!o)return;let s=e.__ref,{method:i,from:a,fields:c,transform:l,as:f,on:u,auth:d,headers:g,baseUrl:p,responseType:h,invalidates:m,optimistic:y,onMutate:x,onSuccess:b,onError:_,onSettled:w}=t,S;if(c===!0||u==="submit")S=Xi(e);else if(P(c)){let T=Xi(e);S={};for(let M of c)S[M]=T[M]}else e.state?.parse?S=e.state.parse():v(e.state)&&(S={...e.state});l&&(S=l(S,e,e.state)),R(x)&&x(S,e,e.state);let E=y?RO(e,t,S):null;s.__fetching=!0,Qe(e,{isFetching:!0,isLoading:!1,isStale:!1,isSuccess:!1,error:null,status:"pending",fetchStatus:"fetching"}),xe(e,"onFetchStart"),$e(t,e,"onFetchStart");let O=r?.analyze?.emitNetwork,L=O?typeof performance<"u"?performance.now():Date.now():0;O&&O({phase:"start",mode:"mutation",from:a,method:i});try{if(d!==!1&&o.auth!==!1&&o.getSession){let W=await o.getSession();if(d===!0&&!W){E!==void 0&&mg(e,t);let yt={message:"Not authenticated"};xe(e,"onFetchError",yt),$e(t,e,"onFetchError",yt);return}}let T=o[i];if(!R(T))return;let M={from:a,data:S,headers:g,baseUrl:p};h!==void 0&&(M.responseType=h),t.params&&(M.params=Gw(t.params,e,r));let U=pf(e,r);U&&(M.headers={...M.headers,"Accept-Language":U});let rt=qw(t),Rt=await Kw(()=>T(M),rt),{data:mt,error:F}=Rt||{};if(F){E!==void 0&&mg(e,t),Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:F,status:"error",fetchStatus:"idle"}),xe(e,"onFetchError",F),R(_)&&_(F,S,e),R(w)&&w(null,F,S,e),O&&O({phase:"error",mode:"mutation",from:a,method:i,error:F.message||String(F),durationMs:(typeof performance<"u"?performance.now():Date.now())-L});return}if(delete s.__optimisticSnapshot,mt!==void 0&&(f||!_g(mt))){let W=f?{[f]:mt}:mt;e.state?.update&&e.state.update(W,{preventFetch:!0})}if(Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!0,error:null,status:"success",fetchStatus:"idle"}),xe(e,"onFetchComplete",mt),$e(t,e,"onFetchComplete",mt),R(b)&&b(mt,S,e),R(w)&&w(mt,null,S,e),O&&O({phase:"success",mode:"mutation",ok:!0,from:a,method:i,durationMs:(typeof performance<"u"?performance.now():Date.now())-L}),m){let W=P(m)?m:[m];for(let yt of W)if(yt===!0||yt==="*")for(let[St]of qt)St.startsWith(a+":")&&Yi(St);else Yi(yt)}}catch(T){E!==void 0&&mg(e,t),Qe(e,{isFetching:!1,isLoading:!1,isStale:!1,isSuccess:!1,error:T,status:"error",fetchStatus:"idle"}),xe(e,"onFetchError",T),$e(t,e,"onFetchError",T),R(_)&&_(T,S,e),R(w)&&w(null,T,S,e),O&&O({phase:"error",mode:"mutation",from:a,method:i,error:T.message||String(T),durationMs:(typeof performance<"u"?performance.now():Date.now())-L})}finally{s.__fetching=!1}},Ji=(t,e,r,n)=>{if(!t||!n?.fetch)return;let s=dt(t,e);if(!s)return;let i=P(s)?s.map(c=>zw(dt(c,e),e)).filter(Boolean):[zw(s,e)].filter(Boolean);for(let c of i){let l=c.method==="insert"||c.method==="update"||c.method==="upsert"||c.method==="delete",f=l?PO:Br;c.on==="create"?f(c,e,n):Promise.resolve().then(()=>{TO({...c,__runner:f},e,n)}),!l&&c.on==="create"&&(c.refetchInterval||c.refetchOnWindowFocus!==!1||c.refetchOnReconnect!==!1)&&OO(c,e,n)}let a=e.__ref;a.refetch=c=>{for(let l of i)Br(l,e,n,{force:!0,...c})},a.fetchNextPage=()=>{let c=i[0];if(!c||!c.infinite)return;let l=a.__nextPageParam;if(l==null)return;let f={...c,cursor:l};Br(f,e,n,{direction:"next",force:!0})},a.fetchPreviousPage=()=>{let c=i[0];if(!c||!c.infinite)return;let l=a.__prevPageParam;if(l==null)return;let f={...c,cursor:l};Br(f,e,n,{direction:"previous",force:!0})}},DO={invalidateQueries:t=>{if(!t){Yi();return}if(k(t))for(let[e]of qt)(e.startsWith(t)||e.includes(t))&&Yi(e);else if(P(t)){let e=t.join(":");for(let[r]of qt)r.includes(e)&&Yi(r)}},removeQueries:t=>{if(!t){ff();return}if(k(t))for(let[e]of qt)(e.startsWith(t)||e.includes(t))&&ff(e)},getQueryData:t=>Zi(t)?.data??void 0,setQueryData:(t,e)=>{let r=Zi(t),n=R(e)?e(r?.data):e;Gi(t,n,null)},prefetchQuery:async(t,e)=>{let r=e?.fetch;if(!r)return;let n=await wg(r,e);if(!n)return;let o=t.cache?.key||`${t.from}:${t.method||"select"}:${JSON.stringify(t.params||"")}`,s=n[t.method||"select"];if(!R(s))return;let i={from:t.from,params:t.params,limit:t.limit,offset:t.offset,order:t.order,single:t.single,headers:t.headers,baseUrl:t.baseUrl};t.responseType!==void 0&&(i.responseType=t.responseType);let a=await s(i);if(a?.data!==void 0&&!a?.error&&!Sg(t)){let c=Gi(o,a.data,null);c.gcTime=xg(t.cache)?.gcTime||3e5}return a},getCache:()=>qt,clear:()=>ff(),dropNonLang:t=>{if(!t)return;let e=`:${t}`;for(let[r]of qt)r.match(/:([a-z]{2,3})$/i)&&(r.endsWith(e)||ff(r))}},kg={name:"fetch",create(t){let e=t.fetch;e&&(t.parent||$o.clear(),Ji(e,t,t.state,t.context))}},LO=Ji});function ea(t){let e=this,{__ref:r}=e,n=[].concat(t),o=r.root[n[0]];if(!n||!n.length)return console.log(n,"on",e.key,"is undefined");for(;o.key===n[0]&&(n.shift(),!!n.length);)if(o=o[n[0]],!o)return;return o}function Cg(t){let e=this,{parent:r}=e;if(R(t))return r.state&&t(r,r.state,r.context)?r:r.parent?r.lookup(t):void 0;if(e[t])return e[t];for(;r.param!==t;){if(r[t])return r[t];if(r=r.parent,!r)return}return r}function Eg(t){let e=this,{__ref:r}=e,n=r?.__children;if(n)for(let o=0;o<n.length;o++){let s=n[o],i=e[s];if(s===t)return i;if(R(t)){let c=t(i,i.state,i.context);if(i.state&&c)return i}let a=i?.lookdown?.(t);if(a)return a}}function Ag(t,e=[]){let r=this,{__ref:n}=r,o=n?.__children;if(o){for(let s=0;s<o.length;s++){let i=o[s],a=r[i];if(i===t)e.push(a);else if(R(t)){let c=t(a,a.state,a.context);a.state&&c&&e.push(a)}a?.lookdownAll?.(t,e)}return e.length?e:void 0}}function yf(t={}){let e=this;if(e.node?.style){for(let r in t){let n=t[r],o=e[r];if(v(n)&&o)yf.call(o,n);else if(n!=null){let s=r.replace(/[A-Z]/g,a=>"-"+a.toLowerCase()),i=String(n).replace(/\s*!important\s*$/,"");e.node.style.setProperty(s,i,"important")}}return e}}function Xw(t){let e=this;if(gr("beforeRemove",e,t)===!1)return e;R(e.node.remove)?e.node.remove():Nr()||(console.warn("This item cant be removed"),e.log()),delete e.parent[e.key],e.parent.__ref&&(e.parent.__ref.__children=hi(e.parent.__ref.__children,e.key)),gr("remove",e,t)}function Tg(t){return this[t]}function Og(t,e){let r=this;if(t)return r.update(t,e),r}function Rg(t){return t?this.__ref&&this.__ref[t]:this.__ref}function Pg(){let t=this.getRef("__children");return Array.isArray(t)?t.map(e=>this[e]):[]}function ra(){return this.getRef().path}function oa(t){let e=null,r=n=>n.__element&&n.root?.isRootState;if(!this)e=Yw();else if(r(this))e=this.root;else if(this.__ref&&this.__ref.path){let n=this.state&&r(this.state),o=R(this.state)&&this.parent.state&&r(this.parent.state);(n||o)&&(e=this.state.root||this.parent.state.root)}return e||(e=Yw()),t?e?.[t]:e}function sa(t){let e=this?.__ref?.root||this.getRootState()?.__element;if(!e)throw new Error(`[smbls] getRoot() could not resolve a root element for "${this?.key||"<unknown>"}" \u2014 it has no __ref (never went through create()) and no root state is registered. Answering undefined here used to no-op silently for every caller.`);return Object.keys(e).length>0&&t?e[t]:e}function ia(t){return this.getRoot("data")&&Object.keys(this.getRoot("data")).length>0&&t?this.getRoot("data")[t]:this.getRoot("data")}function aa(t){let e=this.getRoot()?.context;return t?e[t]:e}function ca(t){let e=this.context;return t?e[t]:e}function bf(){let t=this,e=[];for(let r in t)!Object.prototype.hasOwnProperty.call(t,r)||$r.has(r)&&!_i.has(r)||e.push(r);return e}function _f(t=[]){let e=this,r={},n=bf.call(e),o=n.includes("children"),s=t.length?new Set(t):null;for(let i=0;i<n.length;i++){let a=n[i];if(s&&s.has(a)||!Object.prototype.hasOwnProperty.call(e,a)||o&&a==="content")continue;let c=e[a];if(a==="state"){if(e.__ref&&!e.__ref.__hasRootState)continue;let l=R(c&&c.parse)?c.parse():c;r[a]=R(l)?l:JSON.parse(JSON.stringify(l||{}))}else if(a==="scope"){if(e.__ref&&!e.__ref.__hasRootScope)continue;r[a]=JSON.parse(JSON.stringify(c||{}))}else if(a==="props"){let{__element:l,update:f,...u}=e[a];r[a]=u}else Tt(c)&&Object.prototype.hasOwnProperty.call(e,a)&&(r[a]=c)}return r}function ta(t=[],e=new WeakSet){let r=this;if(e.has(r))return;e.add(r);let n=_f.call(r,t),o=t.length?new Set(t):null;for(let s in n){if(o&&o.has(s)||!Object.prototype.hasOwnProperty.call(r,s))continue;let i=n[s];Array.isArray(i)?n[s]=i.map(a=>B(a)?ta.call(a,t,e):a):B(i)&&(n[s]=ta.call(i,t,e))}return n}function No(...t){if(Vr!=="test"&&Vr!=="development")return;let e=this,{__ref:r}=e;return console.groupCollapsed(e.key),t.length?t.forEach(n=>console.log(`%c${n}:
22
+ `,"font-weight: bold",e[n])):(console.log(r.path),e.keys().forEach(o=>console.log(`%c${o}:`,"font-weight: bold",e[o]))),console.log(e),console.groupEnd(e.key),e}function Lg(...t){(Vr==="test"||Vr==="development")&&console.log(...t)}function la(...t){(Vr==="test"||Vr==="development")&&console.warn(...t)}function Pn(...t){if(Vr==="test"||Vr==="development"){if(t[t.length-1]?.debugger)debugger;throw t[t.length-1]?.verbose&&No.call(this),new Error(...t)}}function fa(){let t=this,{key:e,parent:r}=t,{__children:n}=r.__ref,o=n.indexOf(e),s=n[o+1];return r[s]}function ua(t){let e=t||this,{key:r,parent:n}=e,{__children:o}=n.__ref;if(!o)return;let s=o.indexOf(r);return n[o[s-1]]}function da(t={}){let e=this;e.data||(e.data={}),e.data.varCaches||(e.data.varCaches={});let r=e.data.varCaches,n={},o;for(let s in t)t[s]!==r[s]&&(o=!0,n[s]=t[s]);return{changed:s=>{if(!o)return;let i=s(n,lt(r));for(let a in n)r[a]=n[a];return i},timeout:(s,i)=>{if(!o)return;let a=setTimeout(()=>{s(n),clearTimeout(a)},i)}}}function Ig(t,...e){let r=this.context,n=r.utils?.[t]||r.functions?.[t]||r.methods?.[t]||r.snippets?.[t];if(n&&!Cn(n))try{let o=n.call(this,...e);return o&&typeof o.then=="function"&&o.catch(s=>{Pn.call(this,s)}),o}catch(o){if(Pn.call(this,o),r?.strictMode)throw o}}async function pa(){let t=this,e=t.context?.fetch;if(!e)return null;if(typeof e.select=="function"){if(!e.__authInitialized&&e.getSession){let{initAdapterAuth:o}=await gf();await o(e,t.context)}return e}if(e.__resolved){if(!e.__resolved.__authInitialized&&e.__resolved.getSession){let{initAdapterAuth:o}=await gf();await o(e.__resolved,t.context)}return e.__resolved}if(e.__resolving)return e.__resolving;let r=gf().then(({resolveDb:o})=>o(e));e.__resolving=r;let n=await r;if(e.__resolved=n,t.context.fetch=n,delete e.__resolving,n?.getSession){let{initAdapterAuth:o}=await gf();await o(n,t.context)}return n}function ha(t){let e=this,r=t||Wi.useStateQuery||e.context?.useStateQuery;if(!r)return null;let n={};if(vg(e,n),r===!0)return n;let o=VO[r];return o?o(n):n}function $g(t,e){return!!(Fr.has(t)||e?.context?.methods?.[t])}var Vr,mf,na,Fo,Yw,Dg,IO,gf,vg,$O,Zw,MO,FO,NO,jO,BO,VO,Jw=V(()=>{"use strict";ug();Sn();It();hr();Rl();Co();pg();Vr="production";mf=null,na=t=>{mf=t||null},Fo=(t,e)=>{t&&e&&mf===t&&(mf=e)},Yw=()=>mf||null;Dg=(t,e,r,n)=>Object.defineProperty(t,e,{get:r,set:n});IO="[smbls] getDB needs @symbo.ls/fetch, which the smbls embed bundle does not include: add @symbo.ls/fetch to the page's importmap (the runtime import then resolves) or use the full smbls bundle.",gf=()=>Promise.resolve().then(()=>(Qi(),hf)).catch(t=>{throw new Error(IO,{cause:t})});vg=(t,e)=>{let r=t.__ref;if(!r)return;let n=r.__state;n&&typeof n=="string"&&$O(e,n);let o=r.__children;if(o)for(let a=0;a<o.length;a++){let c=t[o[a]];c&&c.__ref&&vg(c,e)}let s=r.contentElementKey||"content",i=t[s];i&&i.__ref&&vg(i,e)},$O=(t,e)=>{let n=e.replaceAll("../","").replaceAll("~/","").split("/"),o=t;for(let s=0;s<n.length;s++){let i=n[s];s===n.length-1?o[i]||(o[i]=!0):(o[i]===!0&&(o[i]={}),o[i]||(o[i]={}),o=o[i])}},Zw=(t,e=0)=>{let r=" ".repeat(e),n=Object.entries(t);return n.length?n.map(([s,i])=>i===!0?`${r}${s}`:`${r}${s} {
23
+ ${Zw(i,e+1)}
24
24
  ${r}}`).join(`
25
- `):""},EO=t=>`{
26
- ${Wx(t,1)}
27
- }`,AO=t=>{let e={fields:{},include:[]},r=(n,o)=>{let s=[];for(let i in n)if(n[i]===!0)s.push(i);else{let a=o?`${o}.${i}`:i;e.include.push(a),r(n[i],a)}s.length&&(e.fields[o||"_root"]=s)};return r(t,""),e},TO=t=>{let e=s=>{let i=[],a=[];for(let c in s)if(s[c]===!0)i.push(c);else{let l=e(s[c]),f=[];l.select&&f.push(`$select=${l.select}`),l.expand&&f.push(`$expand=${l.expand}`),a.push(f.length?`${c}(${f.join(";")})`:c)}return{select:i.length?i.join(","):"",expand:a.length?a.join(","):""}},{select:r,expand:n}=e(t),o=[];return r&&o.push(`$select=${r}`),n&&o.push(`$expand=${n}`),o.join("&")},OO=(t,e)=>{let r=[],n=[],o=new Set,s=(f,u,d)=>{o.add(u),d&&n.push(`LEFT JOIN ${u} ON ${u}.${d}_id = ${d}.id`);for(let g in f)f[g]===!0?r.push(`${u}.${g}`):s(f[g],g,u)},i=Object.keys(t);i.length===1&&t[i[0]]!==!0?s(t[i[0]],i[0],null):s(t,"_root",null);let a=[...o][0]||"_root",c=r.length?r.join(", "):"*",l=n.length?`
25
+ `):""},MO=t=>`{
26
+ ${Zw(t,1)}
27
+ }`,FO=t=>{let e={fields:{},include:[]},r=(n,o)=>{let s=[];for(let i in n)if(n[i]===!0)s.push(i);else{let a=o?`${o}.${i}`:i;e.include.push(a),r(n[i],a)}s.length&&(e.fields[o||"_root"]=s)};return r(t,""),e},NO=t=>{let e=s=>{let i=[],a=[];for(let c in s)if(s[c]===!0)i.push(c);else{let l=e(s[c]),f=[];l.select&&f.push(`$select=${l.select}`),l.expand&&f.push(`$expand=${l.expand}`),a.push(f.length?`${c}(${f.join(";")})`:c)}return{select:i.length?i.join(","):"",expand:a.length?a.join(","):""}},{select:r,expand:n}=e(t),o=[];return r&&o.push(`$select=${r}`),n&&o.push(`$expand=${n}`),o.join("&")},jO=(t,e)=>{let r=[],n=[],o=new Set,s=(f,u,d)=>{o.add(u),d&&n.push(`LEFT JOIN ${u} ON ${u}.${d}_id = ${d}.id`);for(let g in f)f[g]===!0?r.push(`${u}.${g}`):s(f[g],g,u)},i=Object.keys(t);i.length===1&&t[i[0]]!==!0?s(t[i[0]],i[0],null):s(t,"_root",null);let a=[...o][0]||"_root",c=r.length?r.join(", "):"*",l=n.length?`
28
28
  `+n.join(`
29
29
  `):"";return`SELECT ${c}
30
- FROM ${a}${l}`},RO=t=>{let e=[],r=(n,o)=>{for(let s in n){let i=o?`${o}/${s}`:s;n[s]===!0?e.push(i):r(n[s],i)}};return r(t,""),e},PO={graphql:EO,"json-api":AO,odata:TO,sql:OO,paths:RO}});var DO,Ig,Kx=V(()=>{"use strict";El();DO={snapshotId:Ci},Ig=(t,e)=>{let r=t.__ref,{currentSnapshot:n,calleeElement:o}=e;if(!o||o===t){let a=DO.snapshotId();return r.__currentSnapshot=a,[a,t]}let i=o.__ref.__currentSnapshot;return n<i?[i,o,!0]:[i,o]}});var bf,$g,Gx=V(()=>{bf=new Set(["__proto__","constructor","prototype","_id","__v","id","createdAt","updatedAt","schema"]),$g=t=>typeof t=="string"&&bf.has(t)});async function Mg(t){if(document.fullscreenElement)await document.exitFullscreen();else try{await(this.node||document).requestFullscreen()}catch(e){console.warn(`Error attempting to enable fullscreen mode: ${e.message} (${e.name})`)}}var Yx=V(()=>{"use strict"});var No,jo,ha,xe,zr,Bo,ga,Me,_f,LO,Hr,IO,In,$n,Fg,Xx=V(()=>{"use strict";No=t=>t!=="latest"?`@${t}`:"",jo=t=>t?`/${t}`:"",ha=t=>{let e=typeof t=="string"?t.replace(/\/+$/,""):"";if(!e)return{name:"",subpath:""};let r=e.split("/"),n=e.startsWith("@")?2:1;return{name:r.slice(0,n).join("/"),subpath:r.slice(n).join("/")}},xe={skypack:{url:"https://cdn.skypack.dev",formatUrl:(t,e,r)=>`${xe.skypack.url}/${t}${No(e)}${jo(r)}`},esmsh:{url:"https://esm.sh",formatUrl:(t,e,r)=>`${xe.esmsh.url}/${t}${No(e)}${jo(r)}`},unpkg:{url:"https://unpkg.com",formatUrl:(t,e,r)=>`${xe.unpkg.url}/${t}${No(e)}${jo(r)}?module`},jsdelivr:{url:"https://cdn.jsdelivr.net/npm",formatUrl:(t,e,r)=>`${xe.jsdelivr.url}/${t}${No(e)}${jo(r)}/+esm`},symbols:{url:"https://pkg.symbo.ls",formatUrl:(t,e,r)=>`${xe.symbols.url}/${t}${No(e)}${jo(r)}/+esm`}},zr={"esm.sh":"esmsh",unpkg:"unpkg",skypack:"skypack",jsdelivr:"jsdelivr","pkg.symbo.ls":"symbols"},Bo=(t={})=>{let{packageManager:e}=t;return zr[e]||null},ga=t=>{if(typeof t!="string")return t;let e=t.trim().match(/^[\^~](\d.*)$/);return e?e[1]:t},Me=(t,e="latest",r="esmsh")=>{let n=xe[r]||xe.esmsh,{name:o,subpath:s}=ha(t);return n.formatUrl(o||t,ga(e),s)},_f=(t,e="latest",r="esmsh")=>{let n=xe[r]||xe.esmsh,o=ga(e),{name:s,subpath:i}=ha(t);return`${n.url}/${s||t}${No(o)}${jo(i)}/`},LO=/^node:|^@symbo-ls\//,Hr=t=>typeof t=="string"&&LO.test(t),IO=/[<>…]/,In=t=>typeof t=="string"&&IO.test(t),$n=t=>!!t&&typeof t=="object"&&!Array.isArray(t),Fg=(t,e="skypack",r={})=>{let n=t.dependencies;if(!$n(n))return"";let o=Object.keys(n);if(!o.length)return"";let s=r.pin||{},i={};for(let f of o){if(Hr(f)||In(f))continue;let u=s[f]||n[f]||"latest";i[f]=Me(f,u,e),f.endsWith("/")||(i[f+"/"]=_f(f,u,e))}if(!Object.keys(i).length)return"";let a='<script type="importmap">',c="<\/script>",l=`{
30
+ FROM ${a}${l}`},BO=t=>{let e=[],r=(n,o)=>{for(let s in n){let i=o?`${o}/${s}`:s;n[s]===!0?e.push(i):r(n[s],i)}};return r(t,""),e},VO={graphql:MO,"json-api":FO,odata:NO,sql:jO,paths:BO}});var UO,Mg,Qw=V(()=>{"use strict";Tl();UO={snapshotId:Ai},Mg=(t,e)=>{let r=t.__ref,{currentSnapshot:n,calleeElement:o}=e;if(!o||o===t){let a=UO.snapshotId();return r.__currentSnapshot=a,[a,t]}let i=o.__ref.__currentSnapshot;return n<i?[i,o,!0]:[i,o]}});var xf,Fg,tS=V(()=>{xf=new Set(["__proto__","constructor","prototype","_id","__v","id","createdAt","updatedAt","schema"]),Fg=t=>typeof t=="string"&&xf.has(t)});async function Ng(t){if(document.fullscreenElement)await document.exitFullscreen();else try{await(this.node||document).requestFullscreen()}catch(e){console.warn(`Error attempting to enable fullscreen mode: ${e.message} (${e.name})`)}}var eS=V(()=>{"use strict"});var jo,Bo,ga,we,Ur,Vo,ma,Me,wf,zO,zr,HO,Dn,Ln,jg,rS=V(()=>{"use strict";jo=t=>t!=="latest"?`@${t}`:"",Bo=t=>t?`/${t}`:"",ga=t=>{let e=typeof t=="string"?t.replace(/\/+$/,""):"";if(!e)return{name:"",subpath:""};let r=e.split("/"),n=e.startsWith("@")?2:1;return{name:r.slice(0,n).join("/"),subpath:r.slice(n).join("/")}},we={skypack:{url:"https://cdn.skypack.dev",formatUrl:(t,e,r)=>`${we.skypack.url}/${t}${jo(e)}${Bo(r)}`},esmsh:{url:"https://esm.sh",formatUrl:(t,e,r)=>`${we.esmsh.url}/${t}${jo(e)}${Bo(r)}`},unpkg:{url:"https://unpkg.com",formatUrl:(t,e,r)=>`${we.unpkg.url}/${t}${jo(e)}${Bo(r)}?module`},jsdelivr:{url:"https://cdn.jsdelivr.net/npm",formatUrl:(t,e,r)=>`${we.jsdelivr.url}/${t}${jo(e)}${Bo(r)}/+esm`},symbols:{url:"https://pkg.symbo.ls",formatUrl:(t,e,r)=>`${we.symbols.url}/${t}${jo(e)}${Bo(r)}/+esm`}},Ur={"esm.sh":"esmsh",unpkg:"unpkg",skypack:"skypack",jsdelivr:"jsdelivr","pkg.symbo.ls":"symbols"},Vo=(t={})=>{let{packageManager:e}=t;return Ur[e]||null},ma=t=>{if(typeof t!="string")return t;let e=t.trim().match(/^[\^~](\d.*)$/);return e?e[1]:t},Me=(t,e="latest",r="esmsh")=>{let n=we[r]||we.esmsh,{name:o,subpath:s}=ga(t);return n.formatUrl(o||t,ma(e),s)},wf=(t,e="latest",r="esmsh")=>{let n=we[r]||we.esmsh,o=ma(e),{name:s,subpath:i}=ga(t);return`${n.url}/${s||t}${jo(o)}${Bo(i)}/`},zO=/^node:|^@symbo-ls\//,zr=t=>typeof t=="string"&&zO.test(t),HO=/[<>…]/,Dn=t=>typeof t=="string"&&HO.test(t),Ln=t=>!!t&&typeof t=="object"&&!Array.isArray(t),jg=(t,e="skypack",r={})=>{let n=t.dependencies;if(!Ln(n))return"";let o=Object.keys(n);if(!o.length)return"";let s=r.pin||{},i={};for(let f of o){if(zr(f)||Dn(f))continue;let u=s[f]||n[f]||"latest";i[f]=Me(f,u,e),f.endsWith("/")||(i[f+"/"]=wf(f,u,e))}if(!Object.keys(i).length)return"";let a='<script type="importmap">',c="<\/script>",l=`{
31
31
  "imports": ${JSON.stringify(i,null,2)}
32
- }`;return`${a}${l}${c}`}});var Ng,Zx=V(()=>{"use strict";Ng=t=>{if(!t)return"";let e=new Date(t),r=new Intl.DateTimeFormat("en",{year:"numeric"}).format(e),n=new Intl.DateTimeFormat("en",{month:"short"}).format(e);return`${new Intl.DateTimeFormat("en",{day:"2-digit"}).format(e)} ${n}, ${r}`}});var jg,Jx=V(()=>{"use strict";jg=(t,e)=>{let r=setTimeout(()=>{let{props:n}=t;if(!e.clientHeight){let{node:{clientHeight:o}}=t;o&&(e.clientHeight=o)}if(e.active){if(n.height==="auto")return;t.update({height:e.clientHeight},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0});let o=setTimeout(()=>{t.update({height:"auto"},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0}),clearTimeout(o)},450)}else t.update({height:"0"},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0});clearTimeout(r)})}});var Bg,Qx=V(()=>{"use strict";Bg=function(e){let r=[0,1];for(let n=2;n<=e;n++)r[n]=r[n-1]+r[n-2];return r[e]}});var Vg,tS=V(()=>{"use strict";Vg=t=>["jpeg","gif","jpg","png","tiff","woff"].includes(t)});function Vo(t,e={}){let{window:r=globalThis}=e,{document:n=r.document}=e;return new Promise((o,s)=>{let i=n.querySelector(`script[src="${t}"]`);if(i)return o(i);let a=n.createElement("script");a.src=t,a.async=e.async===!0,a.type=e.type||"text/javascript",e.id&&(a.id=e.id),e.integrity&&(a.integrity=e.integrity),e.crossOrigin&&(a.crossOrigin=e.crossOrigin),a.onload=()=>{a.onerror=a.onload=null,o(a)},a.onerror=()=>{a.onerror=a.onload=null,s(new Error(`Failed to load script: ${t}`))},n.head.appendChild(a)})}async function Kg(t,e={}){let{window:r=globalThis}=e,{document:n=r.document}=e;return new Promise((o,s)=>{let i=n.querySelector(`link[href="${t}"]`);if(i)return o(i);let a=n.createElement("link");a.href=t,a.rel=e.rel||"stylesheet",a.type="text/css",a.media=e.media||"all",e.id&&(a.id=e.id),e.integrity&&(a.integrity=e.integrity),e.crossOrigin&&(a.crossOrigin=e.crossOrigin),a.onload=()=>{a.onerror=a.onload=null,o(a)},a.onerror=()=>{a.onerror=a.onload=null,s(new Error(`Failed to load stylesheet: ${t}`))},n.head.appendChild(a)})}var Ug,zg,Hg,Wg,qg,eS=V(()=>{"use strict";Ug=(t,e=!1,r=document,n="text/javascript")=>new Promise((o,s)=>{try{let i=r.createElement("script");i.type=n,i.async=e,i.src=t,i.addEventListener("load",a=>{o({status:!0})}),i.addEventListener("error",a=>{s(new Error({status:!1,message:`Failed to load the script ${t}`}))}),r.body.appendChild(i)}catch(i){s(i)}}),zg=(t,e=document,r="text/javascript")=>new Promise((n,o)=>{let s=e.createElement("script");s.type=r,s.src=t;let i=e.createElement("div");i.style.cssText="position:fixed;top:0;left:0;right:0;bottom:0;background:rgba(255,255,255,0.8);z-index:9999;",e.body.appendChild(i),s.onload=()=>{console.log(`Successfully loaded: ${t}`),e.body.removeChild(i),n()},s.onerror=()=>{e.body.removeChild(i),o(new Error(`Failed to load: ${t}`))},e.body.appendChild(s)}),Hg=(t,e=document,r,n="text/javascript")=>{let o=new window.XMLHttpRequest;if(o.open("GET",t,!1),o.send(),o.status===200){let s=e.createElement("script");s.type=n,s.text=o.responseText,e.body.appendChild(s),typeof r=="function"&&r()}else throw new Error(`Failed to load the script ${t}`)},Wg=(t,e=!1,r=document,n="text/javascript")=>new Promise((o,s)=>{try{let i=r.createElement("link");i.rel="stylesheet",i.href=t,i.addEventListener("load",a=>{o({status:!0})}),r.head.appendChild(i)}catch(i){s(i)}}),qg=(t,e=!1,r=document,n="text/javascript",o="smbls-script")=>{try{let s=r.createElement("script");s.type=n,s.async=e,s.id=o,s.innerHTML=t,r.body.appendChild(s)}catch(s){console.warn(s)}}});function NO(t,e){if(!e||typeof e!="object")return t;let r=o=>{if(!FO(o))return o;let s=e[o];return s?.src?s.src:o},n={...t};for(let[o,s]of Object.entries(n))typeof s=="string"?n[o]=r(s):Array.isArray(s)&&(n[o]=s.map(i=>typeof i=="string"?r(i):i));return n}function wf(t,e){if(!t||!e)return;let r=e.split("."),n=t;for(let o of r){if(n==null||typeof n!="object")return;n=n[o]}return n}function jO(t,e,r){let o=(e.config||e.settings||{}).polyglot||e.polyglot,s=r?.lang||o?.defaultLang||"en",a=(o?.translations||{})[s]||{},c=r?.state||{},l={...t};for(let[f,u]of Object.entries(l))typeof u!="string"||!u.includes("{{")||(l[f]=u.replace(/\{\{\s*([^|{}]+?)\s*(?:\|\s*(\w+)\s*)?\}\}/g,(d,g,p)=>{let h=g.trim();if(p==="polyglot")return a[h]??wf(a,h)??d;if(p==="getLocalStateLang")return wf(c,h+s)??d;let m=wf(c,h);return m!==void 0?m:a[h]??wf(a,h)??d}));return l}function rS(t){if(!v(t))return{};let e={...t};for(let[r,n]of Object.entries(e))if(typeof n=="function"){let o=n.toString(),s=o.match(/el\.call\(\s*["']getLocalStateLang["']\s*,\s*["']([^"']+)["']\s*\)/);if(s){e[r]=`{{ ${s[1]} | getLocalStateLang }}`;continue}let i=o.match(/el\.call\(\s*["']polyglot["']\s*,\s*["']([^"']+)["']\s*\)/);if(i){e[r]=`{{ ${i[1]} | polyglot }}`;continue}let a=o.match(/s\.(\w+(?:\.\w+)+)/);if(a){e[r]=`{{ ${a[1]} }}`;continue}delete e[r]}else if(typeof n=="string"){let o=n.match(/el\.call\(\s*["']getLocalStateLang["']\s*,\s*["']([^"']+)["']\s*\)/);if(o){e[r]=`{{ ${o[1]} | getLocalStateLang }}`;continue}let s=n.match(/el\.call\(\s*["']polyglot["']\s*,\s*["']([^"']+)["']\s*\)/);if(s){e[r]=`{{ ${s[1]} | polyglot }}`;continue}if(n.includes("=>")&&n.includes("s.")){let i=n.match(/s\.(\w+(?:\.\w+)+)/);if(i){e[r]=`{{ ${i[1]} }}`;continue}}Ti(n)&&delete e[r]}return e}function Yg(t,e,r,{isProduction:n=!1,channel:o="production"}={}){let s=t.pages?.[e],i=v(s?.state)&&s?.state,a=s?.metadata||s?.helmet||i||{},c=rS(a),l=new Set(Object.keys(c)),f=t.app?.metadata||{},u=rS(f),d={};if(t.integrations?.seo?d={...t.integrations.seo,...u,...c}:Object.keys(u).length?d={...u,...c}:d={...c},!d.title){let h=t.name||t.key;h?n?d.title=h:o==="development"?d.title=`${h} / dev:symbo.ls`:o==="staging"?d.title=`${h} / staging:symbo.ls`:d.title=`${h} / symbo.ls`:d.title="Symbols demo"}d=jO(d,t,r),d.title&&(l.has("title")||!d["og:title"])&&(l.has("og:title")||(d["og:title"]=d.title)),d.description&&(l.has("description")||!d["og:description"])&&(l.has("og:description")||(d["og:description"]=d.description)),d.title&&!d["twitter:title"]&&(d["twitter:title"]=d.title),d.description&&!d["twitter:description"]&&(d["twitter:description"]=d.description);let g=r?.actualPathname||e;if(d["og:url"]||d.url){let h=(d["og:url"]||d.url||"").replace(/\/$/,"");if(h&&g&&g!=="/"){let m=g.startsWith("/")?g:"/"+g;d["og:url"]=h+m}}d=NO(d,t.files);let p=t.name||t.app?.metadata?.title||t.app?.name||"";for(let[h,m]of Object.entries(d))if(typeof m=="string"&&m.includes("{{")){let _=m.replace(/\{\{[^}]*\}\}/g,"").trim();_?d[h]=_:h==="title"?d[h]=p:delete d[h]}return d}var $t,$O,Uo,MO,xf,Gg,FO,nS=V(()=>{"use strict";It();Rn();$t=t=>{if(t==null)return"";let e={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#039;"};return t.toString().replace(/[&<>"']/g,r=>e[r])},$O=t=>Object.entries(t||{}).filter(([e,r])=>r!==void 0).map(([e,r])=>`${e}="${$t(r)}"`).join(" "),Uo=t=>{let e=5381,r=String(t);for(let n=0;n<r.length;n++)e=(e*33^r.charCodeAt(n))>>>0;return e.toString(36)},MO=new Set(["jsonLd","styles","scripts"]),xf=t=>{let e=[];if(Array.isArray(t.jsonLd))for(let r of t.jsonLd){if(r==null)continue;let n=typeof r=="string"?r:JSON.stringify(r),o=String(n).replace(/<\/script/gi,"<\\/script");e.push(`<script type="application/ld+json" data-smbls-jsonld="${Uo(n)}">${o}<\/script>`)}if(Array.isArray(t.styles))for(let r of t.styles){if(r==null||!String(r).trim())continue;let n=String(r).replace(/<\/style/gi,"<\\/style");e.push(`<style data-smbls-style="${Uo(n)}">${n}</style>`)}if(Array.isArray(t.scripts))for(let r of t.scripts){if(!r)continue;let n=typeof r=="string",o=n?r:r.src;if(!o&&!r.body)continue;let s=[];o&&s.push(`src="${$t(o)}"`),n||(r.type&&s.push(`type="${$t(r.type)}"`),r.async&&s.push("async"),r.defer&&s.push("defer"),r.integrity&&s.push(`integrity="${$t(r.integrity)}"`),r.crossorigin&&s.push(`crossorigin="${$t(r.crossorigin)}"`),r.referrerpolicy&&s.push(`referrerpolicy="${$t(r.referrerpolicy)}"`),r.nomodule&&s.push("nomodule"));let i=` data-smbls-script="${$t(o||Uo(r.body||""))}"`;if(!n&&r.body){let a=String(r.body).replace(/<\/script/gi,"<\\/script");e.push(`<script ${s.join(" ")}${i}>${a}<\/script>`)}else e.push(`<script ${s.join(" ")}${i}><\/script>`)}return e},Gg=(t,e)=>{e||(t={...t,robots:"noindex"});let r=Object.entries(t).reduce((n,[o,s])=>{if(!s&&s!==0&&s!==!1||MO.has(o))return n;if(o==="title")return n.push(`<title>${$t(s)}</title>`),n;if(o==="canonical")return n.push(`<link rel="canonical" href="${$t(s)}">`),n;if(o==="manifest")return n.push(`<link rel="manifest" href="${$t(s)}">`),n;if(o==="favicon"||o==="favicons"||o==="icon"||o==="icons")return(Array.isArray(s)?s:[s]).forEach(f=>{if(typeof f=="string")n.push(`<link rel="icon" href="${$t(f)}">`);else if(typeof f=="object"){let u=$O(f);/rel=/.test(u)?n.push(`<link ${u}>`):n.push(`<link rel="icon" ${u}>`)}}),n;if(o==="alternate")return(Array.isArray(s)?s:[s]).forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).filter(([d,g])=>g!==void 0).map(([d,g])=>`${d}="${$t(g)}"`).join(" ");n.push(`<link rel="alternate" ${u}>`)}}),n;let i=(l,f,u="name")=>{if(typeof f=="string"||typeof f=="number"||typeof f=="boolean")n.push(`<meta ${u}="${$t(l)}" content="${$t(f)}">`);else if(Array.isArray(f))f.forEach(d=>{if(typeof d=="string"||typeof d=="number"||typeof d=="boolean")n.push(`<meta ${u}="${$t(l)}" content="${$t(d)}">`);else if(typeof d=="object"){let g=Object.entries(d).filter(([p,h])=>h!==void 0).map(([p,h])=>`${p}="${$t(h)}"`).join(" ");n.push(`<meta ${g}>`)}});else if(typeof f=="object"){let d=Object.entries(f).filter(([g,p])=>p!==void 0).map(([g,p])=>`${g}="${$t(p)}"`).join(" ");n.push(`<meta ${d}>`)}};if(o.startsWith("http-equiv:")){let l=o.replace("http-equiv:","");return i(l,s,"http-equiv"),n}if(o.startsWith("itemprop:")){let l=o.replace("itemprop:","");return i(l,s,"itemprop"),n}let c=["og:","twitter:","fb:","article:","profile:","book:","business:","music:","product:","video:","DC:","DCTERMS:"].find(l=>o.startsWith(l));if(c){let l=o.replace(c,"");return i(`${c.replace(":","")}:${l}`,s,c==="twitter:"||c==="DC:"||c==="DCTERMS:"?"name":"property"),n}if(o.startsWith("apple:")||o.startsWith("msapplication:")){let l=o.startsWith("apple:")?"apple-":"msapplication-",f=o.replace(/^apple:|^msapplication:/,"");return i(`${l}${f}`,s,"name"),n}return i(o,s),n},['<meta charset="UTF-8">','<meta name="viewport" content="width=device-width, initial-scale=1">']);return r.push(...xf(t)),r.join(`
33
- `)},FO=t=>typeof t=="string"&&t.length>0&&!t.startsWith("/")&&!t.startsWith("http")});var Sf,Xg,oS=V(()=>{"use strict";It();Sf=(t,e)=>(P(e)?e:Object.values(e)).reduce((r,n)=>Math.abs(n-t)<Math.abs(r-t)?n:r),Xg=(t,e)=>(t=parseFloat(t),v(e)&&(e=Object.values(e)),Sf(t,e))});function zo(t){let e=String(t||"").trim();if(!e)return{owner:sS,key:"",full:""};let r=null,n=e;if(e.includes("/")){let s=e.indexOf("/");r=e.slice(0,s),n=e.slice(s+1)}n=n.replace(/\.symbo\.ls$/iu,""),r||(r=sS);let o=n?`${r}/${n}`:"";return{owner:r,key:n,full:o}}async function kf(t,e={}){if((e.provider||"kv")==="api")return aS(t,e);let n=await ZO(t,e);return n||aS(t,e)}async function ZO(t,e={}){let r=e.kvBaseUrl||BO,n=e.env||"production",o=`${r}/kv/${encodeURIComponent(t)}?env=${n}`;try{let s=await fetch(o,{method:"GET"});return s.ok&&(await s.json())?.value||null}catch{return null}}async function aS(t,e={}){let r=e.apiBaseUrl||VO,{key:n}=zo(t);try{let o=`${r}/core/projects/libraries/available?search=${encodeURIComponent(n)}&limit=10`,s=await fetch(o,{method:"GET"});if(!s.ok)return null;let i=await s.json(),c=(i?.items||i?.data||(Array.isArray(i)?i:[])).find(g=>{let{key:p}=zo(g?.key);return p.toLowerCase()===n.toLowerCase()});if(!c?.id&&!c?._id)return null;let l=c.id||c._id,f=`${r}/core/projects/${encodeURIComponent(l)}/data?branch=main`,u=await fetch(f,{method:"GET"});if(!u.ok)return null;let d=await u.json();return d?.data||d||null}catch{return null}}async function cS(t,e={}){if(v(t))return t;if(k(t)){let{full:r}=zo(t);if(!r)return null;try{let n=await kf(r,e);return n||console.warn(`[smbls] Shared library "${r}" not found`),n}catch(n){return console.warn(`[smbls] Failed to fetch shared library "${r}":`,n.message),null}}return null}async function tm(t,e={}){return!t||!t.length?[]:(await Promise.all(t.map(async n=>{if(Qe(n)){let o=await cS(uS(n),e);return o?{library:o,ignoreList:n.ignoreList}:null}return cS(n,e)}))).filter(Boolean)}var sS,BO,VO,ma,lS,UO,zO,iS,fS,HO,WO,qO,Wr,Jg,Qe,uS,Zg,Qg,KO,GO,YO,XO,ya,dS=V(()=>{"use strict";It();vn();Tl();sS="system",BO="https://smbls-kv.nika-980.workers.dev",VO="https://api.symbols.app";ma=(t,e,r,n)=>{for(let o in e){let s=n?`${n}/${o}`:o;r&&r.has(s)||(o in t?v(t[o])&&v(e[o])&&ma(t[o],e[o],r,s):t[o]=e[o])}},lS=(t,e,r)=>{if(!v(t)||!e.size)return t;let n=`${r}/`,o=!1;for(let i of e)if(i.startsWith(n)){o=!0;break}if(!o)return t;let s={};for(let i in t){if(!Object.prototype.hasOwnProperty.call(t,i))continue;let a=`${r}/${i}`;e.has(a)||(s[i]=lS(t[i],e,a))}return s},UO=new Set,zO=new Set(["components","pages","functions","snippets","methods"]),iS=(t,e)=>e===""&&zO.has(t),fS=["fontFamily","fontfamily","font_family","FONT_FAMILY"],HO=t=>{let e=new Map;if(!v(t))return e;for(let r of fS){let n=t[r];if(v(n))for(let o in n)!v(n[o])||!n[o].isDefault||(e.has(r)||e.set(r,new Set),e.get(r).add(o))}return e},WO=(t,e)=>{for(let r of fS){let n=t[r];if(!v(n))continue;let o=e.get(r),s=null;for(let i in n){let a=n[i];if(!v(a)||!a.isDefault||o&&o.has(i))continue;let c={...a};delete c.isDefault,s||(s={...n}),s[i]=c}s&&(t[r]=s)}},qO=t=>t.replace(/\.js$/iu,""),Wr=t=>{let e=new Set;if(!Array.isArray(t))return e;for(let r of t){if(!k(r))continue;let n=r.split("/").map(o=>qO(o.trim())).filter(Boolean).join("/");n&&e.add(n)}return e},Jg=(t,e={})=>({library:t,ignoreList:Array.isArray(e.ignoreList)?e.ignoreList:[]}),Qe=t=>v(t)&&Array.isArray(t.ignoreList)&&("library"in t||"key"in t||"name"in t),uS=t=>t.library!==void 0?t.library:t.key??t.name,Zg=new Set,Qg=()=>{Zg.clear()},KO=(t,e)=>{let r=e.filter(n=>!Zg.has(n));if(r.length){for(let n of r)Zg.add(n);gt()&&console.warn(`[smbls] shared library "${t}" ships ${r.map(n=>`methods.${n}`).join(", ")} \u2014 named like a built-in element method. Refused: the built-in wins; a library cannot replace an element method on the consuming app. If the app wants this version, declare it in the app's OWN methods.`)}},GO=(t,e,r)=>{let n=null;for(let o in t)if(kn(o)&&(e.has(`methods/${o}`)||r.push(o),!n)){n={};for(let s in t)kn(s)||(n[s]=t[s])}return n||t},YO=(t,e,r,n="library")=>{let o=Wr(e.sharedLibIgnore);e.sharePages===!1&&o.add("pages");let s=o.size?new Set([...r,...o]):r,i=[];for(let a in e)if(Object.prototype.hasOwnProperty.call(e,a)&&!(a==="sharePages"||a==="sharedLibIgnore")&&a!=="app"&&!s.has(a)){if(v(e[a])&&v(t[a])){if(a==="designSystem")ma(t[a],e[a],s,a);else for(let c in e[a])if(!s.has(`${a}/${c}`)){if(a==="methods"&&kn(c)){c in t[a]||i.push(c);continue}c in t[a]?iS(a,t[a][c])&&!iS(a,e[a][c])&&(t[a][c]=e[a][c]):t[a][c]=e[a][c]}}else if(!(a in t)){let c=e[a],l=a==="methods"&&c&&typeof c=="object"?GO(c,s,i):c;t[a]=lS(l,s,a)}}i.length&&KO(n,i)},XO=(t,e,r)=>{if(t!==e){let n=uS(t);if(k(n)&&n)return n;if(t.key||t.name)return t.key||t.name}return e&&(e.key||e.name)||`sharedLibraries[${r}]`},ya=(t,e)=>{if(!e||!e.length)return;let r=HO(t.designSystem);for(let n=0;n<e.length;n++){let o=e[n],s=o,i=UO;Qe(s)&&(i=Wr(s.ignoreList),s=s.library),v(s)&&YO(t,s,i,XO(o,s,n))}r.size&&WO(t.designSystem,r)}});var em,rm,nm,ba,om,_a,sm,Mn,pS=V(()=>{"use strict";It();em=async t=>{try{await navigator.clipboard.writeText(t)}catch(e){console.warn("Failed to copy text: ",e)}},rm=async t=>{try{let e=new Blob([t],{type:"text/javascript"}),r=new window.ClipboardItem({"text/plain":e});await navigator.clipboard.write([r]),console.log("JavaScript code copied to clipboard as text/javascript")}catch(e){console.error("Failed to copy JavaScript code: ",e)}},nm=t=>t.replace(/[^a-zA-Z0-9_]/g,""),ba=t=>(typeof t!="string"&&(t=String(t||"")),t.replace(/(?:^\w|[A-Z]|\b\w)/g,function(e,r){return r===0?e.toLowerCase():e.toUpperCase()}).replace(/\s+/g,"")),om=t=>t&&t.replace(/\w\S*/g,e=>e.charAt(0).toUpperCase()+e.substr(1).toLowerCase()),_a=t=>t.replace(/[^a-zA-Z0-9]/g," ").trim().toLowerCase().replace(/\s+/g,"-").replace(/-+/g,"-").replace(/^-|-$/g,""),sm=(t="")=>{if(typeof t!="string")return;let e=t.replace(/([A-Z])/g," $1");return e.charAt(0).toUpperCase()+e.slice(1)},Mn=t=>{if(P(t))return t;if(k(t))return t.split(" ");if(v(t))return Object.values(t);if(Ke(t))return[t]}});var im,hS=V(()=>{"use strict";im=()=>{let t=document.styleSheets[0],e="";if(t)try{let r=t.cssRules||t.rules;for(let n=0;n<r.length;n++)e+=r[n].cssText}catch(r){console.error("Unable to access CSS rules. This may be due to CORS restrictions:",r)}else console.log("No stylesheets found in document.styleSheets[0].");return e}});var Qt,Ho,wa,xa,gS=V(()=>{"use strict";Qt=t=>{let e=t&&t.src;if(!e||typeof e!="string")return null;let r=t.context;if(!r)return null;let n=r.assets&&r.assets[e]||r.files&&r.files[e];if(!n)return null;if(typeof n=="string")return{src:n,type:null,variants:null};if(typeof n=="object"){if(typeof n.src=="string")return n;let o=n.content,s=o&&o.src;if(typeof s=="string")return{...n,src:s,type:n.type??o.type??null,variants:n.variants??o.variants??null}}return null},Ho=(t,{keepOneX:e=!0}={})=>{if(!Array.isArray(t)||!t.length)return"";let r=t.some(o=>typeof o.width=="number"),n=[];for(let o of t)r&&typeof o.width=="number"?n.push(`${o.src} ${o.width}w`):r||(o.scale===1&&e?n.push(o.src):o.scale&&o.scale!==1&&n.push(`${o.src} ${o.scale}x`));return n.join(", ")},wa=t=>{if(!t||!Array.isArray(t.variants))return"";let e=t.variants.filter(r=>r.format===t.type);return Ho(e,{keepOneX:!1})},xa=(t,e)=>{if(!t||typeof t!="object"||typeof t.src!="string")return[];if(!Array.isArray(t.variants)||!t.variants.length)return[{tag:"img",attr:{src:t.src,alt:e||""}}];let r=new Map;for(let a of t.variants)r.has(a.format)||r.set(a.format,[]),r.get(a.format).push(a);let n=[];for(let[a,c]of r)a!==t.type&&n.push({tag:"source",attr:{type:a,srcset:Ho(c,{keepOneX:!0})}});let o=r.get(t.type)||[],s=Ho(o,{keepOneX:!1}),i={src:t.src,alt:e||""};return s&&(i.srcset=s),[...n,{tag:"img",attr:i}]}});var Wo={};$(Wo,{CDN_PROVIDERS:()=>xe,DOMQL_EVENTS:()=>Qp,DOMQ_PROPERTIES:()=>Mr,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>yh,HTML_TAGS:()=>Oo,METHODS:()=>Nr,METHODS_EXL:()=>bi,NODE_ENV:()=>Ie,OPTIONS:()=>Hi,PACKAGE_MANAGER_TO_CDN:()=>zr,PARSED_DOMQ_PROPERTIES:()=>yi,PROPS_METHODS:()=>Fr,STATE_METHODS:()=>Sn,STATE_PROPERTIES:()=>Zp,SVG_TAGS:()=>lx,TYPES:()=>fi,UNIVERSAL_RESERVED_KEYS:()=>bf,__resetBuiltinMethodWarnings:()=>Qg,addCaching:()=>Xl,addContext:()=>Yl,addExtend:()=>Bh,addExtends:()=>Ge,addItemAfterEveryElement:()=>Np,addProtoToArray:()=>pi,addRef:()=>ql,applyDependentState:()=>sg,applyEvent:()=>rf,applyEventUpdate:()=>nf,applyExtends:()=>dx,applyProps:()=>Fi,arrayContainsOtherArray:()=>Pp,arraysEqual:()=>Bp,arrayzeValue:()=>Mn,buildImgSrcset:()=>wa,buildSourcesAndImg:()=>xa,cache:()=>fg,call:()=>Dg,captureSnapshot:()=>Ig,checkForStateTypes:()=>eg,checkIfInherits:()=>ef,checkIfStringIsInArray:()=>zp,clone:()=>rh,cloneAndMergeArrayExtend:()=>Oi,cloneFunction:()=>vh,collectExtendsList:()=>Ro,concatAddExtends:()=>Fh,copyJavaScriptToClipboard:()=>rm,copyStringToClipboard:()=>em,createBasedOnType:()=>Wl,createElement:()=>tg,createElementExtends:()=>Ll,createExtends:()=>Pi,createExtendsFromKeys:()=>Po,createExtendsStack:()=>Fl,createIfConditionFlag:()=>Ch,createInheritedState:()=>rg,createKey:()=>Ei,createNestedObject:()=>fh,createNestedObjectByKeyPath:()=>og,createObjectWithoutPrototype:()=>Cl,createParent:()=>Kl,createPath:()=>Gl,createProps:()=>Ni,createPropsStack:()=>zl,createRoot:()=>Qh,createScope:()=>ag,createSnapshotId:()=>Ci,customDecodeURIComponent:()=>Xp,customEncodeURIComponent:()=>Yp,cutArrayAfterValue:()=>Mp,cutArrayBeforeValue:()=>$p,debounce:()=>Ai,debounceOnContext:()=>Sh,decodeNewlines:()=>Gp,deepClone:()=>lt,deepContains:()=>ch,deepDefaults:()=>ma,deepDestringifyFunctions:()=>be,deepExtend:()=>Dl,deepMerge:()=>at,deepMergeExtends:()=>Ye,deepStringifyFunctions:()=>wi,defineSetter:()=>Rg,destringifyGlobalScope:()=>Si,detectHeightOnInit:()=>jg,detectInfiniteLoop:()=>hh,document:()=>st,encodeNewlines:()=>Kp,error:()=>Ln,excludeKeysFromObject:()=>mh,exec:()=>dt,extendCachedRegistry:()=>Nh,extendStackRegistry:()=>Di,extractArrayExtend:()=>Ii,fetchLibraryData:()=>kf,fibonacciNumberByIndex:()=>Bg,filterArrays:()=>Vp,filterArraysFast:()=>Up,finalizeExtends:()=>Nl,findClosestNumber:()=>Sf,findClosestNumberInFactory:()=>Xg,findInheritedState:()=>tf,findKeyPosition:()=>Wp,flattenExtend:()=>Do,formatDate:()=>Ng,generateHash:()=>Ol,generateHeadArrayTags:()=>xf,generateKey:()=>vi,generateMetaTags:()=>Gg,get:()=>Eg,getCDNDirUrl:()=>_f,getCDNUrl:()=>Me,getCapitalCaseKeys:()=>zh,getCdnProviderFromConfig:()=>Bo,getChildStateInKey:()=>Ql,getChildren:()=>Og,getContext:()=>aa,getCookie:()=>Rh,getDB:()=>da,getEmotionStylesheet:()=>im,getExtendsInElement:()=>Vh,getExtendsStack:()=>Ri,getExtendsStackRegistry:()=>Pl,getFrequencyInArray:()=>Dp,getFunctionSource:()=>Le,getHashedExtend:()=>Li,getImportMapScript:()=>Fg,getInObjectByPath:()=>ph,getLocalStorage:()=>Dh,getNev:()=>xh,getPageMetadata:()=>Yg,getParentStateInKey:()=>Jl,getPath:()=>ea,getQuery:()=>pa,getRef:()=>Tg,getRoot:()=>oa,getRootContext:()=>ia,getRootData:()=>sa,getRootState:()=>na,getRootStateInKey:()=>Zl,getSpreadChildren:()=>Hh,global:()=>Tp,hasFunction:()=>De,hasHandlerPlugin:()=>Ao,hasOwnProperty:()=>sh,hashContent:()=>Uo,inheritChildExtends:()=>$l,inheritChildPropsExtends:()=>Il,inheritParentProps:()=>ji,inheritRecursiveChildExtends:()=>Ml,initProps:()=>Xh,is:()=>Jt,isArray:()=>P,isBoolean:()=>bl,isBuiltinElementMethod:()=>Jp,isContextComponent:()=>Wh,isCyclic:()=>gh,isDOMNode:()=>Zt,isDate:()=>wl,isDefined:()=>Tt,isDevelopment:()=>Br,isEmpty:()=>kl,isEmptyObject:()=>ih,isEqualDeep:()=>vl,isFailedRevival:()=>An,isFunction:()=>R,isHtmlElement:()=>ci,isLazyFunction:()=>nh,isLocal:()=>wh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>In,isMethod:()=>Lg,isMobile:()=>Th,isNode:()=>dr,isNot:()=>Rp,isNotProduction:()=>On,isNull:()=>_l,isNumber:()=>Ke,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>Vg,isPolyglotRetranslatableKey:()=>zi,isPolyglotWritableKey:()=>Pn,isProduction:()=>jr,isProtectedElementMethod:()=>kn,isStaging:()=>_h,isState:()=>ng,isString:()=>k,isStringFunction:()=>Ti,isTest:()=>Al,isTesting:()=>bh,isUndefined:()=>Lt,isUniversallyReservedKey:()=>$g,isUnresolvableDependency:()=>Hr,isValidDependencyMap:()=>$n,isValidHtmlTag:()=>Ih,isWrappedLibrary:()=>Qe,joinArrays:()=>ko,jointStacks:()=>jh,keys:()=>mf,loadCssFile:()=>Wg,loadJavascript:()=>qg,loadJavascriptFile:()=>Ug,loadJavascriptFileEmbedSync:()=>Hg,loadJavascriptFileSync:()=>zg,loadRemoteCSS:()=>Kg,loadRemoteScript:()=>Vo,log:()=>Pg,logGroupIf:()=>Ah,logIf:()=>Eh,lookdown:()=>vg,lookdownAll:()=>Cg,lookup:()=>kg,lowercaseFirstLetter:()=>xn,makeObjectWithoutPrototype:()=>ah,map:()=>eh,mapStringsWithContextComponents:()=>$i,markPolyglotSeeded:()=>Ze,matchesComponentNaming:()=>Xe,memoize:()=>kh,merge:()=>bt,mergeSharedLibraries:()=>ya,nextElement:()=>la,normalizeIgnoreList:()=>Wr,normalizeLibraryKey:()=>zo,objectToString:()=>xi,objectizeStringProperty:()=>Mi,overwrite:()=>ki,overwriteDeep:()=>Wt,overwriteShallow:()=>Tn,overwriteState:()=>ig,parse:()=>yf,parseDeep:()=>Qi,pickupElementFromProps:()=>Vl,pickupPropsFromElement:()=>Bl,polyglotSeededKeys:()=>Lo,previousElement:()=>fa,promoteActiveRootState:()=>Mo,propExists:()=>Gh,propertizeElement:()=>Ul,propertizeUpdate:()=>Kh,remove:()=>Hx,removeChars:()=>nm,removeCookie:()=>Ph,removeDuplicateProps:()=>Vi,removeDuplicatesInArray:()=>vo,removeFromArray:()=>Lp,removeFromObject:()=>lh,removeNestedKeyByPath:()=>uh,removeValueFromArray:()=>di,removeValueFromArrayAll:()=>Fp,reorderArrayByValues:()=>jp,replaceLiteralsWithObjectFields:()=>Ft,replaceOctalEscapeSequences:()=>qp,resolveAsset:()=>Qt,resolveHandler:()=>To,resolveSharedLibraries:()=>tm,returnValueAsText:()=>Hl,runPluginHook:()=>Ot,self:()=>Op,setActiveRootState:()=>ra,setCookie:()=>Oh,setHashedExtend:()=>Rl,setInObjectByPath:()=>dh,setLocalStorage:()=>Lh,setNodeStyles:()=>gf,setProps:()=>Ag,setPropsPrototype:()=>Bi,sharedLibrary:()=>Jg,splitPackageSpecifier:()=>ha,spotByPath:()=>ta,srcsetFor:()=>Ho,stringIncludesAny:()=>gi,stringToObject:()=>oh,stripVersionRangePrefix:()=>ga,swapItemsInArray:()=>Ip,syncProps:()=>Ui,toCamelCase:()=>ba,toDashCase:()=>_a,toDescriptionCase:()=>sm,toPriorityOrder:()=>_e,toTitleCase:()=>om,toggleFullscreen:()=>Mg,triggerEventOn:()=>hr,triggerEventOnUpdate:()=>cg,trimStringFromSymbols:()=>Hp,unstackArrayOfObjects:()=>ui,update:()=>Yh,updateProps:()=>Zh,variables:()=>ua,verbose:()=>Fo,warn:()=>ca,window:()=>E});var D=V(()=>{"use strict";El();Tl();It();pr();Rn();Co();li();ix();ax();mi();ai();cx();$h();Uh();Jh();jl();bx();kx();vn();vx();qx();ug();Kx();lg();Gx();Yx();Xx();Zx();Jx();Qx();tS();eS();nS();oS();dS();pS();hS();gS()});var Q1=lp((Az,J1)=>{var Hs=1e3,Ws=Hs*60,qs=Ws*60,ho=qs*24,KI=ho*7,GI=ho*365.25;J1.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return YI(t);if(r==="number"&&isFinite(t))return e.long?ZI(t):XI(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function YI(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),n=(e[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*GI;case"weeks":case"week":case"w":return r*KI;case"days":case"day":case"d":return r*ho;case"hours":case"hour":case"hrs":case"hr":case"h":return r*qs;case"minutes":case"minute":case"mins":case"min":case"m":return r*Ws;case"seconds":case"second":case"secs":case"sec":case"s":return r*Hs;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function XI(t){var e=Math.abs(t);return e>=ho?Math.round(t/ho)+"d":e>=qs?Math.round(t/qs)+"h":e>=Ws?Math.round(t/Ws)+"m":e>=Hs?Math.round(t/Hs)+"s":t+"ms"}function ZI(t){var e=Math.abs(t);return e>=ho?Dd(t,e,ho,"day"):e>=qs?Dd(t,e,qs,"hour"):e>=Ws?Dd(t,e,Ws,"minute"):e>=Hs?Dd(t,e,Hs,"second"):t+" ms"}function Dd(t,e,r,n){var o=e>=r*1.5;return Math.round(t/r)+" "+n+(o?"s":"")}});var eA=lp((Tz,tA)=>{function JI(t){r.debug=r,r.default=r,r.coerce=c,r.disable=i,r.enable=o,r.enabled=a,r.humanize=Q1(),r.destroy=l,Object.keys(t).forEach(f=>{r[f]=t[f]}),r.names=[],r.skips=[],r.formatters={};function e(f){let u=0;for(let d=0;d<f.length;d++)u=(u<<5)-u+f.charCodeAt(d),u|=0;return r.colors[Math.abs(u)%r.colors.length]}r.selectColor=e;function r(f){let u,d=null,g,p;function h(...m){if(!h.enabled)return;let _=h,x=Number(new Date),y=x-(u||x);_.diff=y,_.prev=u,_.curr=x,u=x,m[0]=r.coerce(m[0]),typeof m[0]!="string"&&m.unshift("%O");let b=0;m[0]=m[0].replace(/%([a-zA-Z%])/g,(S,C)=>{if(S==="%%")return"%";b++;let O=r.formatters[C];if(typeof O=="function"){let L=m[b];S=O.call(_,L),m.splice(b,1),b--}return S}),r.formatArgs.call(_,m),(_.log||r.log).apply(_,m)}return h.namespace=f,h.useColors=r.useColors(),h.color=r.selectColor(f),h.extend=n,h.destroy=r.destroy,Object.defineProperty(h,"enabled",{enumerable:!0,configurable:!1,get:()=>d!==null?d:(g!==r.namespaces&&(g=r.namespaces,p=r.enabled(f)),p),set:m=>{d=m}}),typeof r.init=="function"&&r.init(h),h}function n(f,u){let d=r(this.namespace+(typeof u>"u"?":":u)+f);return d.log=this.log,d}function o(f){r.save(f),r.namespaces=f,r.names=[],r.skips=[];let u=(typeof f=="string"?f:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let d of u)d[0]==="-"?r.skips.push(d.slice(1)):r.names.push(d)}function s(f,u){let d=0,g=0,p=-1,h=0;for(;d<f.length;)if(g<u.length&&(u[g]===f[d]||u[g]==="*"))u[g]==="*"?(p=g,h=d,g++):(d++,g++);else if(p!==-1)g=p+1,h++,d=h;else return!1;for(;g<u.length&&u[g]==="*";)g++;return g===u.length}function i(){let f=[...r.names,...r.skips.map(u=>"-"+u)].join(",");return r.enable(""),f}function a(f){for(let u of r.skips)if(s(f,u))return!1;for(let u of r.names)if(s(f,u))return!0;return!1}function c(f){return f instanceof Error?f.stack||f.message:f}function l(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}tA.exports=JI});var rA=lp((ce,Ld)=>{ce.formatArgs=t$;ce.save=e$;ce.load=r$;ce.useColors=QI;ce.storage=n$();ce.destroy=(()=>{let t=!1;return()=>{t||(t=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();ce.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function QI(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let t;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(t=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(t[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function t$(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+Ld.exports.humanize(this.diff),!this.useColors)return;let e="color: "+this.color;t.splice(1,0,e,"color: inherit");let r=0,n=0;t[0].replace(/%[a-zA-Z%]/g,o=>{o!=="%%"&&(r++,o==="%c"&&(n=r))}),t.splice(n,0,e)}ce.log=console.debug||console.log||(()=>{});function e$(t){try{t?ce.storage.setItem("debug",t):ce.storage.removeItem("debug")}catch{}}function r$(){let t;try{t=ce.storage.getItem("debug")||ce.storage.getItem("DEBUG")}catch{}return!t&&typeof process<"u"&&"env"in process&&(t=process.env.DEBUG),t}function n$(){try{return localStorage}catch{}}Ld.exports=eA()(ce);var{formatters:o$}=Ld.exports;o$.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}});var Pw={};$(Pw,{ANIMATION_PROPS:()=>Oy,ARIA_ROLES:()=>SP,ATTR_TRANSFORMS:()=>Qn,BLOCK_PROPS:()=>Ry,CDN_PROVIDERS:()=>xe,COMPOUND_CSS_KEYWORDS:()=>Nn,CONFIG:()=>Un,CONFIG_MERGE_EXL:()=>ue,CSS_NAMED_COLOR_HEX:()=>vf,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_PROPS_REGISTRY:()=>xt,CSS_UNITS:()=>So,DEFAULT_CONFIG:()=>kc,DEFAULT_CSS_PROPERTIES_LIST:()=>Et,DELEGATED_EVENTS:()=>gs,DESIGN_SYSTEM_OPTIONS:()=>g_,DOMQL_EVENTS:()=>Qp,DOMQ_PROPERTIES:()=>Mr,DOM_EVENTS:()=>E0,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>yh,FACTORY:()=>fe,FLEX_PROPS:()=>$y,FONT_PROPS:()=>Py,GRID_PROPS:()=>My,HOST_REGISTERED_PACKAGES:()=>n1,HTML_ATTRIBUTES:()=>mu,HTML_TAGS:()=>Oo,LIFECYCLE_EVENTS:()=>nn,METHODS:()=>Nr,METHODS_EXL:()=>bi,MISC_PROPS:()=>Dy,MIXINS:()=>du,NODE_ENV:()=>Ie,OPTIONS:()=>Hi,PACKAGE_MANAGER_TO_CDN:()=>zr,PARSED_DOMQ_PROPERTIES:()=>yi,POSITION_PROPS:()=>Ly,PROPS_METHODS:()=>Fr,REGISTRY:()=>Nt,RESERVED_STORE_METHODS:()=>Vw,ROUTER_OPTIONS:()=>td,SIGNAL_ENGINE_KEY:()=>wo,SIGNAL_INSTANCES_KEY:()=>bo,STANDARD_SCHEME_QUERIES:()=>Kf,STATE_PROPERTIES:()=>Zp,STORE_METHOD_NAMES:()=>Bw,SVG_TAGS:()=>ps,THEME_PROPS:()=>Iy,TIMING_PROPS:()=>lc,TYPES:()=>fi,UNIVERSAL_RESERVED_KEYS:()=>bf,VALUE_TRANSFORMERS:()=>nu,VERSION:()=>zw,__resetBuiltinMethodWarnings:()=>Qg,__resetSignalEngine:()=>Cp,__resetSignalInstances:()=>vp,__resetSkinWarnings:()=>ny,__resetStateShadowWarnings:()=>Uw,activateConfig:()=>wS,addCaching:()=>Xl,addContext:()=>Yl,addDelegatedEvent:()=>ac,addExtend:()=>Bh,addExtends:()=>Ge,addItemAfterEveryElement:()=>Np,addMethods:()=>xs,addProtoToArray:()=>pi,addRef:()=>ql,aliasCaseVariants:()=>ts,animation:()=>Pm,appendSVGSprite:()=>Qa,appendSvgIconsSprite:()=>Gn,applyAttrTransforms:()=>Ey,applyCSS:()=>a_,applyDependentState:()=>sg,applyDocument:()=>Ja,applyEvent:()=>rf,applyEventUpdate:()=>nf,applyExtends:()=>ys,applyHeadings:()=>Xf,applyInitialState:()=>Tu,applyMediaSequenceVars:()=>Kr,applyProps:()=>Fi,applyReset:()=>tc,applySequenceGlobalVars:()=>Fa,applySequenceVars:()=>_r,applySkins:()=>ec,applySpacingSequence:()=>Va,applyStateMethods:()=>me,applyTimingSequence:()=>Za,applyTrueProps:()=>Ny,applyTypographySequence:()=>Ga,arrayContainsOtherArray:()=>Pp,arraysEqual:()=>Bp,arrayzeValue:()=>Mn,assertEmitIntegrity:()=>gy,batch:()=>gl,breakpoints:()=>Om,buildImgSrcset:()=>wa,buildSkinVarStyles:()=>Yn,buildSourcesAndImg:()=>xa,buildThemeVarStyles:()=>Ju,cache:()=>fg,cacheNode:()=>rn,call:()=>Dg,callStateMethod:()=>uc,camelToAttr:()=>or,camelToLowerAttr:()=>A0,captureSnapshot:()=>Ig,changeGlobalTheme:()=>ou,changeLightness:()=>dm,checkAttributeByTagName:()=>Te,checkEventFunctions:()=>Cy,checkForStateTypes:()=>eg,checkIfBoxSize:()=>Ba,checkIfInherits:()=>ef,checkIfStringIsInArray:()=>zp,class:()=>Mm,clone:()=>rh,cloneAndMergeArrayExtend:()=>Oi,cloneFunction:()=>vh,collectExtendsList:()=>Ro,color:()=>Sm,colorStringToRgbaArray:()=>Se,components:()=>Os,compositeOverBackdrop:()=>jn,concatAddExtends:()=>Fh,contrastRatio:()=>Go,convertSvgToSymbol:()=>ja,copyJavaScriptToClipboard:()=>rm,copyStringToClipboard:()=>em,create:()=>Rw,createAsync:()=>G$,createBasedOnType:()=>Wl,createComputed:()=>Nw,createConfig:()=>Ra,createDefine:()=>lE,createEffect:()=>Y,createElement:()=>tg,createElementExtends:()=>Ll,createExtends:()=>Pi,createExtendsFromKeys:()=>Po,createExtendsStack:()=>Fl,createHTMLNode:()=>ds,createIfConditionFlag:()=>Ch,createInheritedState:()=>rg,createKey:()=>Ei,createNestedObject:()=>fh,createNestedObjectByKeyPath:()=>og,createObjectWithoutPrototype:()=>Cl,createParent:()=>Kl,createPath:()=>Gl,createProps:()=>Ni,createPropsStack:()=>zl,createRoot:()=>Qh,createScope:()=>ag,createScopeStore:()=>ml,createSignal:()=>si,createSkeleton:()=>X$,createSnapshotId:()=>Ci,createState:()=>Gy,createStore:()=>lr,createSync:()=>Y$,css:()=>he,cssMediaVars:()=>Uf,cssVars:()=>Vf,customDecodeURIComponent:()=>Xp,customEncodeURIComponent:()=>Yp,cutArrayAfterValue:()=>Mp,cutArrayBeforeValue:()=>$p,debounce:()=>Ai,debounceOnContext:()=>Sh,decodeNewlines:()=>Gp,deepClone:()=>lt,deepContains:()=>ch,deepDefaults:()=>ma,deepDestringifyFunctions:()=>be,deepExtend:()=>Dl,deepMerge:()=>at,deepMergeExtends:()=>Ye,deepStringifyFunctions:()=>wi,defaultDefine:()=>Is,defineResolvedThemeSignal:()=>Qo,defineSetter:()=>Rg,defineThemeSignal:()=>Jo,destringifyGlobalScope:()=>Si,destroy:()=>Oc,detectHeightOnInit:()=>jg,detectInfiniteLoop:()=>hh,detectTag:()=>en,devices:()=>Rm,dispose:()=>kr,encodeNewlines:()=>Kp,error:()=>Ln,excludeKeysFromObject:()=>mh,exec:()=>dt,executeAttr:()=>EP,exetuteClassPerComponent:()=>o2,extendCachedRegistry:()=>Nh,extendStackRegistry:()=>Di,extractArrayExtend:()=>Ii,extractConditionalAttrs:()=>OP,fetchLibraryData:()=>kf,fibonacciNumberByIndex:()=>Bg,filterArrays:()=>Vp,filterArraysFast:()=>Up,filterAttributesByTagName:()=>CP,finalizeExtends:()=>Nl,findClosestNumber:()=>Sf,findClosestNumberInFactory:()=>Xg,findHeadingLetter:()=>Wf,findHeadings:()=>Ma,findInheritedState:()=>tf,findKeyPosition:()=>Wp,flattenExtend:()=>Do,font:()=>mm,fontFace:()=>_m,fontFamily:()=>ym,fontFamilyTypes:()=>bm,formatDate:()=>Ng,generateHash:()=>Ol,generateHeadArrayTags:()=>xf,generateKey:()=>vi,generateMetaTags:()=>Gg,generateSequence:()=>te,generateSequencePosition:()=>zm,generateSprite:()=>Na,generateSubSequence:()=>Ia,get:()=>Eg,getActiveConfig:()=>A,getActiveDocument:()=>Jn,getActiveLang:()=>un,getCDNDirUrl:()=>_f,getCDNUrl:()=>Me,getCacheSize:()=>yy,getCapitalCaseKeys:()=>zh,getCdnProviderFromConfig:()=>Bo,getChildStateInKey:()=>Ql,getChildren:()=>Og,getColor:()=>ot,getColorShade:()=>Of,getContext:()=>aa,getCookie:()=>Rh,getDB:()=>da,getDefaultOrFirstKey:()=>Bn,getEmitStats:()=>fu,getEmotionStylesheet:()=>im,getExtendsInElement:()=>Vh,getExtendsStack:()=>Ri,getExtendsStackRegistry:()=>Pl,getFnPrefixAndValue:()=>br,getFontFace:()=>hm,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>Ff,getFontFaceString:()=>Ea,getFontFamily:()=>Ka,getFontFormat:()=>$f,getFontSizeByKey:()=>Ya,getFrequencyInArray:()=>Dp,getFunctionSource:()=>Le,getHashedExtend:()=>Li,getImportMapScript:()=>Fg,getInObjectByPath:()=>ph,getLanguages:()=>Pc,getLocalStateLang:()=>Mc,getLocalStorage:()=>Dh,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getNev:()=>xh,getObserver:()=>Lr,getPageMetadata:()=>Yg,getParentStateInKey:()=>Jl,getPath:()=>ea,getQuery:()=>pa,getRef:()=>Tg,getResolvedThemeSignal:()=>_S,getRgbTone:()=>tr,getRoot:()=>oa,getRootContext:()=>ia,getRootData:()=>sa,getRootState:()=>na,getRootStateInKey:()=>Zl,getSafeInk:()=>Gf,getSafeInkInfo:()=>Km,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>$a,getSequenceValuePropertyPair:()=>rr,getShadow:()=>za,getShapeByKey:()=>Xa,getSignals:()=>jw,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getSpreadChildren:()=>Hh,getSubratio:()=>La,getSubratioDifference:()=>Da,getSystemGlobalTheme:()=>ge,getTheme:()=>Zm,getThemeSignal:()=>bS,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,global:()=>Tp,gradient:()=>km,grid:()=>$m,hasFunction:()=>De,hasHandlerPlugin:()=>Ao,hasOwnProperty:()=>sh,hashContent:()=>Uo,hexToRgb:()=>cm,hexToRgbArray:()=>Cf,hexToRgba:()=>fm,hslToRgb:()=>Tf,icons:()=>Em,inheritChildExtends:()=>$l,inheritChildPropsExtends:()=>Il,inheritParentProps:()=>ji,inheritRecursiveChildExtends:()=>Ml,init:()=>Er,initPolyglot:()=>nd,initProps:()=>Xh,injectGlobal:()=>wt,is:()=>Jt,isArray:()=>P,isBoolean:()=>bl,isBuiltinElementMethod:()=>Jp,isCSSVar:()=>_t,isContextComponent:()=>Wh,isCyclic:()=>gh,isDOMNode:()=>Zt,isDate:()=>wl,isDefined:()=>Tt,isDevelopment:()=>Br,isDomDocument:()=>fr,isEmpty:()=>kl,isEmptyObject:()=>ih,isEnumeratedTrueFalseAttr:()=>sr,isEqualDeep:()=>vl,isFailedRevival:()=>An,isFunction:()=>R,isGoogleFontsUrl:()=>Yo,isHostObject:()=>ur,isHtmlElement:()=>ci,isLazyFunction:()=>nh,isLocal:()=>wh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>In,isMethod:()=>Lg,isMobile:()=>Th,isNode:()=>dr,isNot:()=>Rp,isNotProduction:()=>On,isNull:()=>_l,isNumber:()=>Ke,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>Vg,isPlainColor:()=>Xr,isPolyglotRetranslatableKey:()=>zi,isPolyglotWritableKey:()=>Pn,isProduction:()=>jr,isProtectedElementMethod:()=>kn,isRawUnitValue:()=>ii,isResolvedColor:()=>Fe,isScalingUnit:()=>wn,isStaging:()=>_h,isState:()=>ng,isStore:()=>kt,isString:()=>k,isStringFunction:()=>Ti,isSvgTag:()=>hs,isTest:()=>Al,isTesting:()=>bh,isTracking:()=>Xy,isUndefined:()=>Lt,isUniversallyReservedKey:()=>$g,isUnresolvableDependency:()=>Hr,isValidDependencyMap:()=>$n,isValidHtmlTag:()=>Ih,isValidTag:()=>us,isWasmLoaded:()=>GC,isWrappedLibrary:()=>Qe,isWritableFamilyBucket:()=>Ap,joinArrays:()=>ko,jointStacks:()=>jh,keyframes:()=>fs,keys:()=>mf,linearChannelToSrgb:()=>Df,loadCssFile:()=>Wg,loadJavascript:()=>qg,loadJavascriptFile:()=>Ug,loadJavascriptFileEmbedSync:()=>Hg,loadJavascriptFileSync:()=>zg,loadRemoteCSS:()=>Kg,loadRemoteScript:()=>Vo,loadTranslations:()=>Lc,loadWasm:()=>KC,log:()=>Pg,logGroupIf:()=>Ah,logIf:()=>Eh,lookdown:()=>vg,lookdownAll:()=>Cg,lookup:()=>kg,lowercaseFirstLetter:()=>xn,makeObjectWithoutPrototype:()=>ah,map:()=>eh,mapStringsWithContextComponents:()=>$i,markPolyglotSeeded:()=>Ze,matchesComponentNaming:()=>Xe,media:()=>wm,memoize:()=>kh,merge:()=>bt,mergeSharedLibraries:()=>ya,mixTwoColors:()=>am,mixTwoRgb:()=>um,mixTwoRgba:()=>Rf,nextElement:()=>la,normalizeIgnoreList:()=>Wr,normalizeLibraryKey:()=>zo,numToLetterMap:()=>er,objectToString:()=>xi,objectizeStringProperty:()=>Mi,oklabToLinearSrgb:()=>Lf,oklabToOklch:()=>ka,oklchToGamutSafeSrgb:()=>va,oklchToOklab:()=>If,opacify:()=>Ko,overwrite:()=>ki,overwriteDeep:()=>Wt,overwriteShallow:()=>Tn,overwriteState:()=>ig,parkHostObject:()=>$r,parse:()=>yf,parseColorToken:()=>Ut,parseDeep:()=>Qi,pickupElementFromProps:()=>Vl,pickupPropsFromElement:()=>Bl,polyglotFunctions:()=>Gc,polyglotPlugin:()=>Ms,polyglotSeededKeys:()=>Lo,popConfig:()=>it,popStaticCssPass:()=>wu,previousElement:()=>fa,promoteActiveRootState:()=>Mo,propExists:()=>Gh,propertizeElement:()=>Ul,propertizeUpdate:()=>Kh,pushConfig:()=>ct,pushStaticCssPass:()=>_u,quietColorProbe:()=>Hn,refreshContextProto:()=>ku,registerEvent:()=>ms,registerHostPackages:()=>o1,registerSignalInstance:()=>_o,reinit:()=>i_,relativeLuminance:()=>Fn,remove:()=>ws,removeChars:()=>nm,removeCookie:()=>Ph,removeDelegatedEvent:()=>cc,removeDuplicateProps:()=>Vi,removeDuplicatesInArray:()=>vo,removeFromArray:()=>Lp,removeFromObject:()=>lh,removeNestedKeyByPath:()=>uh,removeValueFromArray:()=>di,removeValueFromArrayAll:()=>Fp,reorderArrayByValues:()=>jp,replaceLiteralsWithObjectFields:()=>Ft,replaceOctalEscapeSequences:()=>qp,resetEmitStats:()=>hy,resolveAsset:()=>Qt,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveColorsInGradient:()=>nc,resolveConfigDocument:()=>xo,resolveDesignSystemClass:()=>j0,resolveFileSource:()=>vy,resolveFileUrl:()=>ke,resolveGridTracks:()=>I0,resolveHandler:()=>To,resolvePropValue:()=>on,resolveShadowValue:()=>qn,resolveSharedLibraries:()=>tm,returnSubThemeOrDefault:()=>pm,returnValueAsText:()=>Hl,rgbArrayToHex:()=>Ef,rgbToHSL:()=>Af,rgbToHex:()=>lm,runPluginHook:()=>Ot,runThroughMedia:()=>Yf,schemeGuardSelector:()=>Jr,schemeMediaQuery:()=>Zr,scratchDefaultConfig:()=>Zo,scratchSystem:()=>ss,scratchUtils:()=>Gr,self:()=>Op,semanticIcons:()=>Am,sequence:()=>yr,serializeAttrValue:()=>re,set:()=>Xn,setActiveConfig:()=>zf,setActiveDocument:()=>py,setActiveRootState:()=>ra,setAdaptiveSchemeVar:()=>Qr,setClass:()=>RD,setClassname:()=>s2,setColor:()=>Yr,setCookie:()=>Oh,setCssEngineHook:()=>Zu,setCustomFont:()=>Ca,setCustomFontMedia:()=>qr,setEach:()=>iy,setFont:()=>qa,setFontFamily:()=>ns,setFontImport:()=>Xo,setGradient:()=>es,setHashedExtend:()=>Rl,setInCustomFontMedia:()=>Mf,setInObjectByPath:()=>dh,setLang:()=>Ic,setLocalStorage:()=>Lh,setMediaTheme:()=>rs,setNodeStyles:()=>gf,setObserver:()=>Ir,setProps:()=>Ag,setPropsPrototype:()=>Bi,setSVG:()=>os,setScalingVar:()=>Pa,setShadow:()=>tn,setSubScalingVar:()=>Hf,setSvgIcon:()=>Kn,setTheme:()=>Wa,setValue:()=>sy,setVariables:()=>Hm,setWasmEngine:()=>ic,shadow:()=>Cm,shape:()=>jm,sharedLibrary:()=>Jg,sizes:()=>Nm,skins:()=>Bm,spacing:()=>xm,splitPackageSpecifier:()=>ha,splitSpacedValue:()=>Ua,splitTopLevelCommas:()=>mr,splitTopLevelSpaces:()=>pt,splitTransition:()=>ru,spotByPath:()=>ta,srcsetFor:()=>Ho,srgbChannelToLinear:()=>Pf,srgbToOklab:()=>Sa,stringIncludesAny:()=>gi,stringToObject:()=>oh,stripVersionRangePrefix:()=>ga,svg:()=>Dm,svgData:()=>Lm,swapItemsInArray:()=>Ip,syncProps:()=>Ui,templates:()=>Im,theme:()=>vm,timing:()=>Tm,toCamel:()=>Oa,toCamelCase:()=>ba,toDashCase:()=>_a,toDescriptionCase:()=>sm,toLinearChannel:()=>qo,toPriorityOrder:()=>_e,toTitleCase:()=>om,toggleFullscreen:()=>Mg,transformBackgroundImage:()=>Qf,transformBorder:()=>nr,transformBorderRadius:()=>wr,transformBoxShadow:()=>rc,transformClassname:()=>V0,transformDuration:()=>oc,transformGridTemplate:()=>eu,transformShadow:()=>Jf,transformSize:()=>vt,transformSizeRatio:()=>I,transformTextStroke:()=>Zf,transformTransition:()=>oy,transformersByPrefix:()=>jy,transfromGap:()=>tu,translate:()=>Dc,triggerEventOn:()=>hr,triggerEventOnUpdate:()=>cg,trimStringFromSymbols:()=>Hp,typography:()=>Aa,unit:()=>gm,unstackArrayOfObjects:()=>ui,update:()=>bs,updateProps:()=>Zh,updateVars:()=>OD,upsertTranslation:()=>$c,useCssInProps:()=>se,useHostState:()=>Yy,usePropsAsCSS:()=>N0,useSelectorsAsCSS:()=>B0,variables:()=>ua,vars:()=>Fm,verbose:()=>Fo,warn:()=>ca,warnStateKeyShadowsMethod:()=>yl,window:()=>E,wrapHoverRule:()=>xr});module.exports=rT(Pw);var Ep={};$(Ep,{RESERVED_STORE_METHODS:()=>Vw,SIGNAL_ENGINE_KEY:()=>wo,SIGNAL_INSTANCES_KEY:()=>bo,STORE_METHOD_NAMES:()=>Bw,VERSION:()=>zw,__resetSignalEngine:()=>Cp,__resetSignalInstances:()=>vp,__resetStateShadowWarnings:()=>Uw,batch:()=>gl,createComputed:()=>Nw,createEffect:()=>Y,createScopeStore:()=>ml,createSignal:()=>si,createStore:()=>lr,getObserver:()=>Lr,getSignals:()=>jw,isStore:()=>kt,registerSignalInstance:()=>_o,setObserver:()=>Ir,warnStateKeyShadowsMethod:()=>yl});var mp={};$(mp,{WRITE_JOURNAL:()=>ei,batch:()=>ni,createComputed:()=>oT,createEffect:()=>sT,createSignal:()=>We,getObserver:()=>hp,journalWrite:()=>ri,setObserver:()=>nT});var Xt=null,cl=0,ll=[],hp=()=>Xt,nT=t=>{Xt=t},fl=0,fp=[];function We(t){let e=new Set;function r(){return Xt&&(e.add(Xt),Xt._sources.add(s)),t}function n(i){i!==t&&(t=i,uT(e))}function o(){return t}let s={get:r,set:n,peek:o,_subscribers:e,_type:"signal"};return s}function oT(t){let e,r=!0,n=new Set,o={_sources:new Set,_type:"computed",_subscribers:n,_execute(){pp(o);let s=Xt;Xt=o;try{e=t(),r=!1}finally{Xt=s}},_notify(){r=!0,n.size>0&&Mw(n)},get(){return Xt&&(n.add(Xt),Xt._sources.add(o)),r&&o._execute(),e},peek(){return r&&o._execute(),e}};return o._execute(),o}var Pe=new Set,up=!1,ei=[];function ri(t){ei.push(t),ei.length>32&&ei.shift()}function sT(t,e){let r=e?.depth??0,n={_sources:new Set,_type:"effect",_depth:r,_label:e?.label,_disposed:!1,_subscribers:new Set,_execute(){if(n._disposed)return;pp(n);let o=Xt;Xt=n;try{t()}catch(s){console.error("[smbls] effect error:",s)}finally{Xt=o}},_notify(){n._disposed||(cl>0?ll.push(n):fl>0?fp.push(n):gp(n))},dispose(){n._disposed=!0,pp(n)}};return n._execute(),n}function ni(t){cl++;try{t()}finally{cl--,cl===0&&fT()}}var dp=!1,Lw=1e3,iT=8,aT=256,cT=4;function Iw(){return typeof performance<"u"?performance.now():Date.now()}function gp(t){Pe.add(t),!dp&&(up||(up=!0,queueMicrotask($w)))}var yo=[];function lT(){if(Pe.size===1){let[e]=Pe;return Pe.clear(),e._disposed?0:(e._execute(),1)}yo.length=0;for(let e of Pe)yo.push(e);Pe.clear(),yo.sort((e,r)=>e._depth-r._depth);let t=0;for(let e=0;e<yo.length;e++){let r=yo[e];r._disposed||(r._execute(),t++)}return yo.length=0,t}function $w(t=0,e=0){if(up=!1,Pe.size===0)return;dp=!0;let r=Iw(),n=!1;try{for(;Pe.size>0;){if(++t>Lw){let o=new Map;for(let c of Pe){let l=c._label;if(typeof l=="function")try{l=l()}catch{l="<label error>"}if(l=l||"<unlabeled>",o.set(l,(o.get(l)||0)+1),o.size>=12)break}let s=[...o.entries()].map(([c,l])=>l>1?`${c} \xD7${l}`:c).join(", "),i=new Map;for(let c of ei)i.set(c,(i.get(c)||0)+1);let a=[...i.entries()].map(([c,l])=>l>1?`${c} \xD7${l}`:c).join(", ");console.error("[smbls] reactive effect cascade exceeded",Lw,"passes in a single flush \u2014 breaking to avoid hanging the thread.","This usually means an effect (or an onUpdate/subscribeTo handler","it calls into) unconditionally writes back a signal it depends on.","Still queued at break (the loop participants):",s||"<queue empty>","\u2014 last notifying store writes:",a||"<none recorded>"),Pe.clear();break}if(e+=lT(),Pe.size>0&&(e>=aT||t>=cT)&&Iw()-r>iT){n=!0,setTimeout(()=>$w(t,e),0);break}}}finally{n||(dp=!1)}}function fT(){for(let t=0;t<ll.length;t++)gp(ll[t]);ll.length=0}function Mw(t){fl++;try{for(let e of t)e._notify()}finally{if(fl--,fl===0&&fp.length>0){let e=fp.splice(0);for(let r=0;r<e.length;r++)gp(e[r])}}}function uT(t){Mw(t)}function pp(t){for(let e of t._sources)e._subscribers.delete(t);t._sources.clear()}var kp={};$(kp,{RESERVED_STORE_METHODS:()=>oi,STORE_METHOD_NAMES:()=>Sp,__resetStateShadowWarnings:()=>dT,createScopeStore:()=>mT,createStore:()=>ul,getSignals:()=>gT,isStore:()=>hT,warnStateKeyShadowsMethod:()=>xp});var qe=Symbol("store"),dl=Symbol("signals"),Sp=["update","parse","clean","keys","values","replace","add","remove","destroy","quietUpdate"],oi=new Set(Sp),wp=new Set,yp=(t,e)=>t?t+"."+e:String(e);function xp(t,e){let r=(e||"")+"::"+t;if(wp.has(r))return;wp.add(r);let n=e?`state.${e}`:"state",o=`[smbls/state] "${t}" is a reserved store-method name and was written as DATA at ${n}.${t}. The value is preserved and readable \u2014 data wins over the method \u2014 but "${n}.${t}(\u2026)" no longer reaches the store method on this node. Use "${n}.$${t}(\u2026)" for the method, or rename the data key. Reserved: ${Sp.join(", ")}.`;typeof console<"u"&&console.warn&&console.warn(o)}function dT(){wp.clear()}var bp=t=>!t||typeof t!="object"||Array.isArray(t)||t[qe]||Object.isFrozen(t)||typeof Node<"u"&&t instanceof Node||t.__ref||t.nodeType||t.nodeName||!pl(t),pT=12,pl=t=>{if(!t||typeof t!="object")return!1;let e=Object.getPrototypeOf(t);return e===Object.prototype||e===null};function hl(t,e,r){if(t===e)return!0;if(r>pT)return!1;if(Array.isArray(t)||Array.isArray(e)){if(!Array.isArray(t)||!Array.isArray(e)||t.length!==e.length)return!1;for(let n=0;n<t.length;n++)if(!hl(t[n],e[n],r+1))return!1;return!0}if(pl(t)&&pl(e)){let n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(let s of n)if(!Object.prototype.hasOwnProperty.call(e,s)||!hl(t[s],e[s],r+1))return!1;return!0}return!1}function ul(t,e,r,n){r===void 0&&(r=0),n===void 0&&(n="");let o={},s={},i=y=>Object.prototype.hasOwnProperty.call(o,y)&&Object.prototype.hasOwnProperty.call(s,y),a=e&&e.maxDepth||8;if(t&&typeof t=="object")for(let y in t){if(y==="__proto__"||!Object.prototype.hasOwnProperty.call(t,y))continue;if(y.startsWith("__")){s[y]=t[y];continue}oi.has(y)&&xp(y,n);let b=t[y];r<a&&b&&typeof b=="object"&&!bp(b)?(s[y]=b,o[y]=We(ul(b,e,r+1,yp(n,y)))):(s[y]=b,o[y]=We(b))}let c=new Proxy(s,{get(y,b){if(b===qe)return!0;if(b===dl)return o;if(b==="__raw")return y;if(b==="$update")return l;if(b==="$parse")return u;if(b==="$clean")return d;if(b==="$keys")return g;if(b==="$values")return p;if(b==="$replace")return h;if(b==="$add")return m;if(b==="$remove")return _;if(b==="$destroy")return x;if(b==="$quietUpdate")return f;if(oi.has(b)&&!Object.prototype.hasOwnProperty.call(o,b))switch(b){case"update":return l;case"parse":return u;case"clean":return d;case"keys":return g;case"values":return p;case"replace":return h;case"add":return m;case"remove":return _;case"destroy":return x;case"quietUpdate":return f}if(b==="__element")return y.__element;if(b==="parent")return y.parent;if(b==="root")return y.root;if(Object.prototype.hasOwnProperty.call(o,b)){let S=o[b].get();if(S!==void 0||!(b!=="root"&&y.root&&y.root!==c))return S}if(y[b]!==void 0)return y[b];let w=typeof b=="string"&&!b.startsWith("__")&&b!=="then"&&b!=="constructor"&&hp()!=null;if(b!=="root"&&y.root&&y.root!==c){let S=y.root[b];return w&&!Object.prototype.hasOwnProperty.call(o,b)&&(o[b]=We(void 0),o[b].get()),S}if(w)return o[b]=We(void 0),o[b].get()},set(y,b,w){if(b==="__proto__")return!1;if(b==="__element"||b==="parent"||b==="root"||typeof b=="string"&&b.startsWith("__")&&!Object.prototype.hasOwnProperty.call(o,b))return y[b]=w,!0;oi.has(b)&&xp(b,n);let S=yp(n,b);if(Object.prototype.hasOwnProperty.call(o,b))if(w&&typeof w=="object"&&!bp(w)){if(w===y[b])return!0;let C=o[b].peek(),O=C&&C[qe]?C.$parse():C;if(hl(w,O,0))return!0;y[b]=w,ri(S),o[b].set(ul(w,e,r+1,S))}else{if(Array.isArray(w)&&w!==y[b]&&Array.isArray(o[b].peek())&&hl(w,o[b].peek(),0))return!0;o[b].peek()!==w&&ri(S),y[b]=w,o[b].set(w)}else y[b]=w,w&&typeof w=="object"&&!bp(w)?o[b]=We(ul(w,e,r+1,S)):o[b]=We(w);return!0},has(y,b){return typeof b=="string"&&b.charCodeAt(0)===36&&oi.has(b.slice(1))?!0:b in y},ownKeys(y){return Object.keys(o).filter(i)},getOwnPropertyDescriptor(y,b){return i(b)?{enumerable:!0,configurable:!0,value:o[b].peek()}:Object.getOwnPropertyDescriptor(y,b)},deleteProperty(y,b){return o[b]&&(o[b].peek()!==void 0&&ri(yp(n,b)),o[b].set(void 0),delete o[b]),delete y[b],!0}});function l(y,b){ni(()=>{for(let S in y)S!=="__proto__"&&(c[S]=y[S])});let w=s.__element;return w&&w.onUpdate&&!b?.quiet&&w.onUpdate(w,c,w.context),c}function f(y){return l(y,{quiet:!0})}function u(y){if(y||(y=new Set),y.has(c))return"[Circular]";y.add(c);let b={};for(let w in o){if(w==="parent"||w==="root"||w.startsWith("__")||!Object.prototype.hasOwnProperty.call(s,w))continue;let S=o[w].peek();S&&S[qe]?b[w]=S.$parse(y):b[w]=S}return b}function d(){return ni(()=>{for(let y in o)delete c[y]}),c}function g(){return Object.keys(o).filter(i)}function p(){return Object.keys(o).filter(i).map(y=>o[y].peek())}function h(y){return ni(()=>{for(let b in o)b in y||delete c[b];for(let b in y)b!=="__proto__"&&(c[b]=y[b])}),c}function m(y,b){let w=Object.prototype.hasOwnProperty.call(o,y)?o[y].peek():s[y];if(Array.isArray(w))return c[y]=[...w,b],c;if(w&&typeof w=="object"&&!Array.isArray(w)){if(pl(b))w[qe]?w.$update(b):c[y]={...w,...b};else{let S=String(Object.keys(w).length);w[qe]?w.$update({[S]:b}):c[y]={...w,[S]:b}}return c}return c[y]=b,c}function _(y){return delete c[y],c}function x(){d(),s.__element=null,s.parent=null}return c}function hT(t){return t&&t[qe]===!0}function gT(t){return t[dl]}function mT(t,e){let r={},n={};if(t&&typeof t=="object")for(let i in t)n[i]=t[i],r[i]=We(t[i]);let o=i=>{if(Object.prototype.hasOwnProperty.call(r,i))return r;let a=e;for(;a;){let c=a[dl];if(c&&Object.prototype.hasOwnProperty.call(c,i))return c;a=a[qe]?a[_p]:null}return null};return new Proxy(n,{get(i,a){return a===qe?!0:a===dl?r:a===_p?e:a==="__raw"?i:Object.prototype.hasOwnProperty.call(r,a)?r[a].get():e&&a!=="then"&&a!=="constructor"?e[a]:i[a]},set(i,a,c){let l=o(a);return l?(l===r&&(i[a]=c),l[a].set(c),!0):(i[a]=c,r[a]=We(c),!0)},has(i,a){if(a in r||a in i)return!0;let c=e;for(;c;){if(a in c)return!0;c=c[qe]?c[_p]:null}return!1},ownKeys(){return Object.keys(r)},getOwnPropertyDescriptor(i,a){return a in r?{enumerable:!0,configurable:!0,value:r[a].peek()}:Object.getOwnPropertyDescriptor(i,a)}})}var _p=Symbol("scope.parent");var _n="3.14.785";var bo="__SMBLS_SIGNAL_INSTANCES__",_o=(t,e,r)=>{let n=e||(typeof globalThis<"u"?globalThis:null);if(!n)return null;let o=n[bo]||(n[bo]={versions:[],engines:0,reported:!1});return typeof o.engines!="number"&&(o.engines=o.versions.length),o.versions.push(t||_n),r||o.engines++,o.engines>1&&!o.reported&&(o.reported=!0,console.error("[smbls] duplicate @symbo.ls/signal instance \u2014",o.engines,"copies of the reactive engine are loaded on this page:",o.versions.join(", ")+".","Each copy keeps its own observer and effect queue, so an effect created","by one copy never re-fires from another copy's store writes, and one","copy's cascade breaker cannot see the other's queue.","Copies of the SAME version adopt a single engine automatically, so","this means the versions above DIFFER: a fossil copy is resolving beside","the current one. That is a dependency-graph fault, not an application","bug \u2014 align the version wherever @symbo.ls/signal is imported, then","regenerate the lockfile so exactly one version resolves.")),o},vp=t=>{let e=t||(typeof globalThis<"u"?globalThis:null);e&&delete e[bo]};var wo="__SMBLS_SIGNAL_ENGINE__",Fw=(t,e,r)=>{let n=e||_n,o=r||(typeof globalThis<"u"?globalThis:null);if(!o)return t;let s=o[wo];return s&&s.engine&&s.version===n?(_o(n,o,!0),s.engine):(s||(o[wo]={version:n,engine:t}),_o(n,o,!1),t)},Cp=t=>{let e=t||(typeof globalThis<"u"?globalThis:null);e&&delete e[wo]};var Ht=Fw({...mp,...kp,VERSION:_n},_n),si=Ht.createSignal,Nw=Ht.createComputed,Y=Ht.createEffect,gl=Ht.batch,Lr=Ht.getObserver,Ir=Ht.setObserver,lr=Ht.createStore,ml=Ht.createScopeStore,kt=Ht.isStore,jw=Ht.getSignals,Bw=Ht.STORE_METHOD_NAMES,Vw=Ht.RESERVED_STORE_METHODS,yl=Ht.warnStateKeyShadowsMethod,Uw=Ht.__resetStateShadowWarnings,zw=Ht.VERSION;var by={};$(by,{assertEmitIntegrity:()=>gy,css:()=>he,getActiveDocument:()=>Jn,getCacheSize:()=>yy,getEmitStats:()=>fu,injectGlobal:()=>wt,keyframes:()=>fs,reset:()=>g0,resetEmitStats:()=>hy,setActiveDocument:()=>py,setWasmEngine:()=>ic,wrapHoverRule:()=>xr});var ay={};$(ay,{COMPOUND_CSS_KEYWORDS:()=>Nn,CONFIG:()=>Un,CONFIG_MERGE_EXL:()=>ue,CSS_NAMED_COLOR_HEX:()=>vf,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_UNITS:()=>So,FACTORY:()=>fe,STANDARD_SCHEME_QUERIES:()=>Kf,VALUE_TRANSFORMERS:()=>nu,__resetSkinWarnings:()=>ny,activateConfig:()=>wS,aliasCaseVariants:()=>ts,animation:()=>Pm,appendSVGSprite:()=>Qa,appendSvgIconsSprite:()=>Gn,applyDocument:()=>Ja,applyHeadings:()=>Xf,applyMediaSequenceVars:()=>Kr,applyReset:()=>tc,applySequenceGlobalVars:()=>Fa,applySequenceVars:()=>_r,applySkins:()=>ec,applySpacingSequence:()=>Va,applyTimingSequence:()=>Za,applyTypographySequence:()=>Ga,breakpoints:()=>Om,buildSkinVarStyles:()=>Yn,changeGlobalTheme:()=>ou,changeLightness:()=>dm,checkIfBoxSize:()=>Ba,class:()=>Mm,color:()=>Sm,colorStringToRgbaArray:()=>Se,compositeOverBackdrop:()=>jn,contrastRatio:()=>Go,convertSvgToSymbol:()=>ja,createConfig:()=>Ra,cssMediaVars:()=>Uf,cssVars:()=>Vf,defineResolvedThemeSignal:()=>Qo,defineThemeSignal:()=>Jo,devices:()=>Rm,document:()=>mS,findHeadingLetter:()=>Wf,findHeadings:()=>Ma,font:()=>mm,fontFace:()=>_m,fontFamily:()=>ym,fontFamilyTypes:()=>bm,generateSequence:()=>te,generateSequencePosition:()=>zm,generateSprite:()=>Na,generateSubSequence:()=>Ia,getActiveConfig:()=>A,getColor:()=>ot,getColorShade:()=>Of,getDefaultOrFirstKey:()=>Bn,getFnPrefixAndValue:()=>br,getFontFace:()=>hm,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>Ff,getFontFaceString:()=>Ea,getFontFamily:()=>Ka,getFontFormat:()=>$f,getFontSizeByKey:()=>Ya,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getResolvedThemeSignal:()=>_S,getRgbTone:()=>tr,getSafeInk:()=>Gf,getSafeInkInfo:()=>Km,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>$a,getSequenceValuePropertyPair:()=>rr,getShadow:()=>za,getShapeByKey:()=>Xa,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getSubratio:()=>La,getSubratioDifference:()=>Da,getTheme:()=>Zm,getThemeSignal:()=>bS,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,gradient:()=>km,grid:()=>$m,hexToRgb:()=>cm,hexToRgbArray:()=>Cf,hexToRgba:()=>fm,hslToRgb:()=>Tf,icons:()=>Em,isCSSVar:()=>_t,isDomDocument:()=>fr,isGoogleFontsUrl:()=>Yo,isHostObject:()=>ur,isPlainColor:()=>Xr,isRawUnitValue:()=>ii,isResolvedColor:()=>Fe,isScalingUnit:()=>wn,isWritableFamilyBucket:()=>Ap,linearChannelToSrgb:()=>Df,media:()=>wm,mixTwoColors:()=>am,mixTwoRgb:()=>um,mixTwoRgba:()=>Rf,numToLetterMap:()=>er,oklabToLinearSrgb:()=>Lf,oklabToOklch:()=>ka,oklchToGamutSafeSrgb:()=>va,oklchToOklab:()=>If,opacify:()=>Ko,parkHostObject:()=>$r,parseColorToken:()=>Ut,popConfig:()=>it,pushConfig:()=>ct,quietColorProbe:()=>Hn,relativeLuminance:()=>Fn,reset:()=>yS,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveColorsInGradient:()=>nc,resolveConfigDocument:()=>xo,resolveFileUrl:()=>ke,resolveShadowValue:()=>qn,returnSubThemeOrDefault:()=>pm,rgbArrayToHex:()=>Ef,rgbToHSL:()=>Af,rgbToHex:()=>lm,runThroughMedia:()=>Yf,schemeGuardSelector:()=>Jr,schemeMediaQuery:()=>Zr,scratchDefaultConfig:()=>Zo,scratchSystem:()=>ss,scratchUtils:()=>Gr,semanticIcons:()=>Am,sequence:()=>yr,set:()=>Xn,setActiveConfig:()=>zf,setAdaptiveSchemeVar:()=>Qr,setColor:()=>Yr,setCustomFont:()=>Ca,setCustomFontMedia:()=>qr,setEach:()=>iy,setFont:()=>qa,setFontFamily:()=>ns,setFontImport:()=>Xo,setGradient:()=>es,setInCustomFontMedia:()=>Mf,setMediaTheme:()=>rs,setSVG:()=>os,setScalingVar:()=>Pa,setShadow:()=>tn,setSubScalingVar:()=>Hf,setSvgIcon:()=>Kn,setTheme:()=>Wa,setValue:()=>sy,setVariables:()=>Hm,shadow:()=>Cm,shape:()=>jm,sizes:()=>Nm,skins:()=>Bm,spacing:()=>xm,splitSpacedValue:()=>Ua,splitTopLevelCommas:()=>mr,splitTopLevelSpaces:()=>pt,splitTransition:()=>ru,srgbChannelToLinear:()=>Pf,srgbToOklab:()=>Sa,svg:()=>Dm,svgData:()=>Lm,templates:()=>Im,theme:()=>vm,timing:()=>Tm,toCamel:()=>Oa,toLinearChannel:()=>qo,transformBackgroundImage:()=>Qf,transformBorder:()=>nr,transformBorderRadius:()=>wr,transformBoxShadow:()=>rc,transformDuration:()=>oc,transformGridTemplate:()=>eu,transformShadow:()=>Jf,transformSize:()=>vt,transformSizeRatio:()=>I,transformTextStroke:()=>Zf,transformTransition:()=>oy,transfromGap:()=>tu,typography:()=>Aa,unit:()=>gm,vars:()=>Fm});var Gr={};$(Gr,{COMPOUND_CSS_KEYWORDS:()=>Nn,CSS_NAMED_COLOR_HEX:()=>vf,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_UNITS:()=>So,applyMediaSequenceVars:()=>Kr,applySequenceGlobalVars:()=>Fa,applySequenceVars:()=>_r,changeLightness:()=>dm,colorStringToRgbaArray:()=>Se,compositeOverBackdrop:()=>jn,contrastRatio:()=>Go,convertSvgToSymbol:()=>ja,findHeadingLetter:()=>Wf,findHeadings:()=>Ma,generateSequence:()=>te,generateSequencePosition:()=>zm,generateSprite:()=>Na,generateSubSequence:()=>Ia,getColorShade:()=>Of,getDefaultOrFirstKey:()=>Bn,getFnPrefixAndValue:()=>br,getFontFace:()=>hm,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>Ff,getFontFaceString:()=>Ea,getFontFormat:()=>$f,getRgbTone:()=>tr,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>$a,getSequenceValuePropertyPair:()=>rr,getSubratio:()=>La,getSubratioDifference:()=>Da,hexToRgb:()=>cm,hexToRgbArray:()=>Cf,hexToRgba:()=>fm,hslToRgb:()=>Tf,isCSSVar:()=>_t,isDomDocument:()=>fr,isGoogleFontsUrl:()=>Yo,isHostObject:()=>ur,isRawUnitValue:()=>ii,isResolvedColor:()=>Fe,isScalingUnit:()=>wn,isWritableFamilyBucket:()=>Ap,linearChannelToSrgb:()=>Df,mixTwoColors:()=>am,mixTwoRgb:()=>um,mixTwoRgba:()=>Rf,numToLetterMap:()=>er,oklabToLinearSrgb:()=>Lf,oklabToOklch:()=>ka,oklchToGamutSafeSrgb:()=>va,oklchToOklab:()=>If,opacify:()=>Ko,parkHostObject:()=>$r,parseColorToken:()=>Ut,relativeLuminance:()=>Fn,resolveConfigDocument:()=>xo,resolveFileUrl:()=>ke,returnSubThemeOrDefault:()=>pm,rgbArrayToHex:()=>Ef,rgbToHSL:()=>Af,rgbToHex:()=>lm,setCustomFont:()=>Ca,setCustomFontMedia:()=>qr,setFontImport:()=>Xo,setInCustomFontMedia:()=>Mf,setScalingVar:()=>Pa,setSubScalingVar:()=>Hf,setVariables:()=>Hm,splitTopLevelCommas:()=>mr,splitTopLevelSpaces:()=>pt,srgbChannelToLinear:()=>Pf,srgbToOklab:()=>Sa,toLinearChannel:()=>qo});var fr=t=>!!(t&&t.documentElement&&typeof t.createElement=="function"&&t.head!==void 0),ur=t=>{if(t===null||typeof t!="object")return!1;let e=Object.prototype.toString.call(t);return!!(e!=="[object Object]"&&e!=="[object Array]"||typeof t.nodeType=="number"||t.defaultView||t.window===t||t.self===t)},Ap=t=>t!==null&&typeof t=="object"&&!ur(t),$r=(t,e,r)=>{if(!t)return;if(fr(r)){t.__domDocument||(t.__domDocument=r);return}let n=`__host_${e}`;t[n]||(t[n]=r)},xo=t=>t?fr(t.__domDocument)?t.__domDocument:fr(t.document)?t.document:null:null;var wn=t=>t==="em"||t==="rem"||t==="vw"||t==="vh"||t==="vmax"||t==="vmin",So=["px","cm","mm","in","pt","pc","em","rem","ex","cap","ch","ic","lh","rlh","%","vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh","cqw","cqh","cqi","cqb","cqmin","cqmax","deg","rad","grad","turn","s","ms","dpi","dpcm","dppx","fr","auto"],yT=t=>t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),bT=new RegExp(`^-?(?:\\d+\\.?\\d*|\\.\\d+)(?:${So.filter(t=>t!=="auto").map(yT).join("|")})$`),ii=t=>bT.test(String(t).trim());D();var vf={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},Se=t=>{if(t==="")return[0,0,0,0];if(t.toLowerCase()==="transparent")return[0,0,0,0];let e=vf[t.toLowerCase()];if(e&&(t=e),t[0]==="#")return t.length<7&&(t="#"+t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+(t.length>4?t[4]+t[4]:"")),[parseInt(t.substr(1,2),16),parseInt(t.substr(3,2),16),parseInt(t.substr(5,2),16),t.length>7?parseInt(t.substr(7,2),16)/255:1];if(t.indexOf("rgb")===-1&&st&&E){let r=st.body.appendChild(st.createElement("fictum")),n="rgb(1, 2, 3)";if(r.style.color=n,r.style.color!==n){st.body.removeChild(r);return}if(r.style.color=t,r.style.color===n||r.style.color==="")return st.body.removeChild(r),[0,0,0,0];t=E.getComputedStyle(r).color,st.body.removeChild(r)}return t.indexOf("rgb")===0?(t.indexOf("rgba")===-1&&(t=`${t}, 1`),t.match(/[\.\d]+/g).map(r=>+r)):[0,0,0,0]},am=(t,e,r=.5)=>(t=Se(t),e=Se(e),Rf(t,e,r)),cm=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return`rgb(${r},${n},${o})`},Cf=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return[r,n,o]},lm=(t,e,r)=>"#"+(1<<24|t<<16|e<<8|r).toString(16).slice(1),Ef=([t,e,r])=>((1<<24)+(t<<16)+(e<<8)+r).toString(16).slice(1),fm=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return`rgba(${r},${n},${o},${e})`},um=(t,e,r=.5)=>{let n=[];for(let o=0;o<3;o++)n[o]=~~(t[o]+(e[o]-t[o])*r);return`rgb(${n})`},dm=(t,e)=>{let[r,n,o]=e,s=Math.max(0,Math.min(100,o+parseFloat(t)));return[r,n,s]},Af=(t,e,r)=>{let n=Math.max(t,e,r),o=n-Math.min(t,e,r),s=1-Math.abs(n+n-o-1),i=o&&(n==t?(e-r)/o:n==e?2+(r-t)/o:4+(t-e)/o);return[60*(i<0?i+6:i),s?o/s:0,(n+n-o)/2]},Tf=(t,e,r,n=e*Math.min(r,1-r),o=(s,i=(s+t/30)%12)=>r-n*Math.max(Math.min(i-3,9-i,1),-1))=>[o(0),o(8),o(4)],Of=(t,e)=>{let r=parseInt(t,16),n=(r>>16)+e;n>255?n=255:n<0&&(n=0);let o=(r>>8&255)+e;o>255?o=255:o<0&&(o=0);let s=(r&255)+e;return s>255?s=255:s<0&&(s=0),((s|o<<8|n<<16)+16777216).toString(16).slice(1)},Rf=(t,e,r=.5)=>{let n=[];for(let o=0;o<4;o++){let s=o===3?i=>i:Math.round;n[o]=s(t[o]+(e[o]-t[o])*r)}return`rgba(${n})`},Ko=(t,e)=>{let r=Se(t);if(!r){On()&&console.warn(t+" color is not rgba");return}return r[3]=e,`rgba(${r})`},_t=t=>t.charCodeAt(0)===45&&t.charCodeAt(1)===45,Nn=new Set(["currentcolor","transparent","thin","medium","thick"]),le=/(?:rgba?\(|hsla?\(|#[0-9a-fA-F]{3,8}\b)/,JO=/^([a-zA-Z]\w*(?:-[a-zA-Z]\w*)*)(?:\.(\d+))?(?:([+-]\d+|=\d+))?$/,Ut=t=>{if(!k(t))return null;if(le.test(t))return{passthrough:t};if(_t(t))return{cssVar:t};let e=t.match(JO);if(!e)return null;let[,r,n,o]=e,s=n!==void 0?`0.${n}`:void 0,i=o&&o[0]==="="?o.slice(1):o;return{name:r,alpha:s,tone:i}},Fe=t=>k(t)&&(t.includes("rgb")||t.includes("var(")||t.includes("#")),mr=t=>{let e=[],r="",n=0;for(let o of t){if(o==="("?n+=1:o===")"&&n>0&&(n-=1),o===","&&n===0){e.push(r),r="";continue}r+=o}return(r.length||!e.length)&&e.push(r),e},pt=t=>{let e=[],r="",n=0;for(let o of t){if(o==="("?n+=1:o===")"&&n>0&&(n-=1),n===0&&/\s/.test(o)){r.length&&e.push(r),r="";continue}r+=o}return r.length&&e.push(r),e},qo=t=>(t/=255,t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)),Fn=t=>.2126*qo(t[0])+.7152*qo(t[1])+.0722*qo(t[2]),Go=(t,e)=>{let r=Fn(t)+.05,n=Fn(e)+.05;return r>n?r/n:n/r},Pf=t=>(t/=255,t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)),Df=t=>(t<=.0031308?t*12.92:1.055*Math.pow(t,1/2.4)-.055)*255,Sa=([t,e,r])=>{let[n,o,s]=[t,e,r].map(Pf),i=.4122214708*n+.5363325363*o+.0514459929*s,a=.2119034982*n+.6806995451*o+.1073969566*s,c=.0883024619*n+.2817188376*o+.6299787005*s,l=Math.cbrt(i),f=Math.cbrt(a),u=Math.cbrt(c);return[.2104542553*l+.793617785*f-.0040720468*u,1.9779984951*l-2.428592205*f+.4505937099*u,.0259040371*l+.7827717662*f-.808675766*u]},Lf=([t,e,r])=>{let n=t+.3963377774*e+.2158037573*r,o=t-.1055613458*e-.0638541728*r,s=t-.0894841775*e-1.291485548*r,i=n**3,a=o**3,c=s**3;return[4.0767416621*i-3.3077115913*a+.2309699292*c,-1.2684380046*i+2.6097574011*a-.3413193965*c,-.0041960863*i-.7034186147*a+1.707614701*c]},ka=([t,e,r])=>{let n=Math.atan2(r,e)*180/Math.PI;return n<0&&(n+=360),[t,Math.sqrt(e*e+r*r),n]},If=([t,e,r])=>{let n=r*Math.PI/180;return[t,e*Math.cos(n),e*Math.sin(n)]},va=(t,e,r,n=24)=>{let o=a=>Lf(If([t,a,r])),s=a=>a.every(c=>c>=-1e-4&&c<=1.0001),i=o(e);if(!s(i)){let a=0,c=e;for(let l=0;l<n;l++){let f=(a+c)/2;s(o(f))?a=f:c=f}i=o(a)}return i.map(a=>Df(Math.max(0,Math.min(1,a))))},jn=(t,e=1,r=[255,255,255])=>e>=1?t:t.map((n,o)=>n*e+r[o]*(1-e)),tr=(t,e)=>{k(t)&&t.includes("rgb")&&(t=Se(t).join(", ")),k(t)&&(t=t.split(",").map(o=>parseFloat(o.trim()))),Ke(e)&&(e+="");let r=Ef(t),n=e.slice(0,1);if(n==="-"||n==="+"){let o=Of(r,parseFloat(e));return Cf(o).join(", ")}else{let[o,s,i]=t,[a,c]=Af(o/255,s/255,i/255),l=Math.max(0,Math.min(100,parseFloat(e)))/100;return Tf(a,c,l).map(u=>Math.round(Math.max(0,Math.min(1,u))*255)).join(", ")}};var pm=(t,e)=>{if(t)return t.themes&&t.themes[e]?t.themes[e]:t[e]?[t,t[e]]:t};var ke=(t,e)=>{if(!t||!e)return null;try{return new URL(t),null}catch{}let r=e[t];return r?r.content&&r.content.src:null},Bn=(t,e)=>{if(t[e])return t[e].value;let r=()=>Object.keys(t).find(o=>o!=="default"&&t[o]&&t[o].value&&!t[o].isSystemFallback);if(t.default){let o=t[t.default];if(o&&o.isSystemFallback){let s=r();if(s)return t[s].value}if(o)return o.value}let n=r()||Object.keys(t).find(o=>o!=="default"&&t[o]&&t[o].value);return n&&t[n]&&t[n].value},$f=t=>{if(typeof t!="string"||!t)return null;let e=t.split(/[#?]/)[0].split(".").pop().trim();return["woff2","woff","ttf","otf","eot"].includes(e)?e:null},Yo=t=>t&&(t.includes("fonts.googleapis.com")||t.includes("fonts.gstatic.com")),Xo=t=>`@import url('${t}');`,Mf=t=>`@font-face { ${t} }`,Ca=(t,e,r,n={})=>{let i=(Array.isArray(e)?e:[e]).filter(a=>typeof a=="string"&&a).map(a=>{let c=$f(a),l=c?` format('${c}')`:"";return`url('${a}')${l}`}).join(`,
32
+ }`;return`${a}${l}${c}`}});var Bg,nS=V(()=>{"use strict";Bg=t=>{if(!t)return"";let e=new Date(t),r=new Intl.DateTimeFormat("en",{year:"numeric"}).format(e),n=new Intl.DateTimeFormat("en",{month:"short"}).format(e);return`${new Intl.DateTimeFormat("en",{day:"2-digit"}).format(e)} ${n}, ${r}`}});var Vg,oS=V(()=>{"use strict";Vg=(t,e)=>{let r=setTimeout(()=>{let{props:n}=t;if(!e.clientHeight){let{node:{clientHeight:o}}=t;o&&(e.clientHeight=o)}if(e.active){if(n.height==="auto")return;t.update({height:e.clientHeight},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0});let o=setTimeout(()=>{t.update({height:"auto"},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0}),clearTimeout(o)},450)}else t.update({height:"0"},{preventBeforeUpdateListener:!0,preventChildrenUpdate:!0});clearTimeout(r)})}});var Ug,sS=V(()=>{"use strict";Ug=function(e){let r=[0,1];for(let n=2;n<=e;n++)r[n]=r[n-1]+r[n-2];return r[e]}});var zg,iS=V(()=>{"use strict";zg=t=>["jpeg","gif","jpg","png","tiff","woff"].includes(t)});function Uo(t,e={}){let{window:r=globalThis}=e,{document:n=r.document}=e;return new Promise((o,s)=>{let i=n.querySelector(`script[src="${t}"]`);if(i)return o(i);let a=n.createElement("script");a.src=t,a.async=e.async===!0,a.type=e.type||"text/javascript",e.id&&(a.id=e.id),e.integrity&&(a.integrity=e.integrity),e.crossOrigin&&(a.crossOrigin=e.crossOrigin),a.onload=()=>{a.onerror=a.onload=null,o(a)},a.onerror=()=>{a.onerror=a.onload=null,s(new Error(`Failed to load script: ${t}`))},n.head.appendChild(a)})}async function Yg(t,e={}){let{window:r=globalThis}=e,{document:n=r.document}=e;return new Promise((o,s)=>{let i=n.querySelector(`link[href="${t}"]`);if(i)return o(i);let a=n.createElement("link");a.href=t,a.rel=e.rel||"stylesheet",a.type="text/css",a.media=e.media||"all",e.id&&(a.id=e.id),e.integrity&&(a.integrity=e.integrity),e.crossOrigin&&(a.crossOrigin=e.crossOrigin),a.onload=()=>{a.onerror=a.onload=null,o(a)},a.onerror=()=>{a.onerror=a.onload=null,s(new Error(`Failed to load stylesheet: ${t}`))},n.head.appendChild(a)})}var Hg,Wg,qg,Kg,Gg,aS=V(()=>{"use strict";Hg=(t,e=!1,r=document,n="text/javascript")=>new Promise((o,s)=>{try{let i=r.createElement("script");i.type=n,i.async=e,i.src=t,i.addEventListener("load",a=>{o({status:!0})}),i.addEventListener("error",a=>{s(new Error({status:!1,message:`Failed to load the script ${t}`}))}),r.body.appendChild(i)}catch(i){s(i)}}),Wg=(t,e=document,r="text/javascript")=>new Promise((n,o)=>{let s=e.createElement("script");s.type=r,s.src=t;let i=e.createElement("div");i.style.cssText="position:fixed;top:0;left:0;right:0;bottom:0;background:rgba(255,255,255,0.8);z-index:9999;",e.body.appendChild(i),s.onload=()=>{console.log(`Successfully loaded: ${t}`),e.body.removeChild(i),n()},s.onerror=()=>{e.body.removeChild(i),o(new Error(`Failed to load: ${t}`))},e.body.appendChild(s)}),qg=(t,e=document,r,n="text/javascript")=>{let o=new window.XMLHttpRequest;if(o.open("GET",t,!1),o.send(),o.status===200){let s=e.createElement("script");s.type=n,s.text=o.responseText,e.body.appendChild(s),typeof r=="function"&&r()}else throw new Error(`Failed to load the script ${t}`)},Kg=(t,e=!1,r=document,n="text/javascript")=>new Promise((o,s)=>{try{let i=r.createElement("link");i.rel="stylesheet",i.href=t,i.addEventListener("load",a=>{o({status:!0})}),r.head.appendChild(i)}catch(i){s(i)}}),Gg=(t,e=!1,r=document,n="text/javascript",o="smbls-script")=>{try{let s=r.createElement("script");s.type=n,s.async=e,s.id=o,s.innerHTML=t,r.body.appendChild(s)}catch(s){console.warn(s)}}});function In(t,e){if(!e||typeof e!="object")return t;let r=o=>!KO(o)||!Object.prototype.hasOwnProperty.call(e,o)?o:kf(e[o])||o,n={...t};for(let[o,s]of Object.entries(n))typeof s=="string"?n[o]=r(s):Array.isArray(s)&&(n[o]=s.map(i=>typeof i=="string"?r(i):i));return n}function Zg(t,e){if(!t||!e)return;let r=e.split("."),n=t;for(let o of r){if(n==null||typeof n!="object")return;n=n[o]}return n}function GO(t,e){let r=Zg(t,e);if(typeof r=="number")return Number.isFinite(r)?r:void 0;if(typeof r=="string"&&!Ao(r))return r}function YO(t,e,r){let o=(e.config||e.settings||{}).polyglot||e.polyglot,s=r?.lang||o?.defaultLang||"en",a=(o?.translations||{})[s]||{},c=[r?.state,e.state].filter(u=>u&&typeof u=="object"),l=u=>{for(let d of c){let g=GO(d,u);if(g!==void 0)return g}},f={...t};for(let[u,d]of Object.entries(f))typeof d!="string"||!d.includes("{{")||(f[u]=d.replace(/\{\{\s*([^|{}]+?)\s*(?:\|\s*(\w+)\s*)?\}\}/g,(g,p,h)=>{let m=p.trim();if(h==="polyglot")return a[m]??Zg(a,m)??g;if(h==="getLocalStateLang")return l(m+s)??g;let y=l(m);return y!==void 0?y:a[m]??Zg(a,m)??g}));return f}function cS(t){if(!v(t))return{};let e={...t};for(let[r,n]of Object.entries(e))if(typeof n=="function"){let o=n.toString(),s=o.match(/el\.call\(\s*["']getLocalStateLang["']\s*,\s*["']([^"']+)["']\s*\)/);if(s){e[r]=`{{ ${s[1]} | getLocalStateLang }}`;continue}let i=o.match(/el\.call\(\s*["']polyglot["']\s*,\s*["']([^"']+)["']\s*\)/);if(i){e[r]=`{{ ${i[1]} | polyglot }}`;continue}let a=o.match(/s\.(\w+(?:\.\w+)+)/);if(a){e[r]=`{{ ${a[1]} }}`;continue}delete e[r]}else if(typeof n=="string"){let o=n.match(/el\.call\(\s*["']getLocalStateLang["']\s*,\s*["']([^"']+)["']\s*\)/);if(o){e[r]=`{{ ${o[1]} | getLocalStateLang }}`;continue}let s=n.match(/el\.call\(\s*["']polyglot["']\s*,\s*["']([^"']+)["']\s*\)/);if(s){e[r]=`{{ ${s[1]} | polyglot }}`;continue}if(n.includes("=>")&&n.includes("s.")){let i=n.match(/s\.(\w+(?:\.\w+)+)/);if(i){e[r]=`{{ ${i[1]} }}`;continue}}Ao(n)&&delete e[r]}return e}function Qg(t,e,r,{isProduction:n=!1,channel:o="production"}={}){let s=t.pages?.[e],i=v(s?.state)&&s?.state,a=s?.metadata||s?.helmet||i||{},c=cS(a),l=new Set(Object.keys(c)),f=t.app?.metadata||{},u=cS(f),d={};if(t.integrations?.seo?d={...t.integrations.seo,...u,...c}:Object.keys(u).length?d={...u,...c}:d={...c},!d.title){let h=t.name||t.key;h?n?d.title=h:o==="development"?d.title=`${h} / dev:symbo.ls`:o==="staging"?d.title=`${h} / staging:symbo.ls`:d.title=`${h} / symbo.ls`:d.title="Symbols demo"}d=YO(d,t,r),d.title&&(l.has("title")||!d["og:title"])&&(l.has("og:title")||(d["og:title"]=d.title)),d.description&&(l.has("description")||!d["og:description"])&&(l.has("og:description")||(d["og:description"]=d.description)),d.title&&!d["twitter:title"]&&(d["twitter:title"]=d.title),d.description&&!d["twitter:description"]&&(d["twitter:description"]=d.description);let g=r?.actualPathname||e;if(d["og:url"]||d.url){let h=(d["og:url"]||d.url||"").replace(/\/$/,"");if(h&&g&&g!=="/"){let m=g.startsWith("/")?g:"/"+g;d["og:url"]=h+m}}d=In(d,t.files);let p=t.name||t.app?.metadata?.title||t.app?.name||"";for(let[h,m]of Object.entries(d))if(typeof m=="string"&&m.includes("{{")){let y=m.replace(/\{\{[^}]*\}\}/g,"").trim();y?d[h]=y:h==="title"?d[h]=p:delete d[h]}return d}var $t,WO,zo,qO,Sf,Jg,KO,Xg,kf,lS=V(()=>{"use strict";It();Tn();$t=t=>{if(t==null)return"";let e={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#039;"};return t.toString().replace(/[&<>"']/g,r=>e[r])},WO=t=>Object.entries(t||{}).filter(([e,r])=>r!==void 0).map(([e,r])=>`${e}="${$t(r)}"`).join(" "),zo=t=>{let e=5381,r=String(t);for(let n=0;n<r.length;n++)e=(e*33^r.charCodeAt(n))>>>0;return e.toString(36)},qO=new Set(["jsonLd","styles","scripts"]),Sf=t=>{let e=[];if(Array.isArray(t.jsonLd))for(let r of t.jsonLd){if(r==null)continue;let n=typeof r=="string"?r:JSON.stringify(r),o=String(n).replace(/<\/script/gi,"<\\/script");e.push(`<script type="application/ld+json" data-smbls-jsonld="${zo(n)}">${o}<\/script>`)}if(Array.isArray(t.styles))for(let r of t.styles){if(r==null||!String(r).trim())continue;let n=String(r).replace(/<\/style/gi,"<\\/style");e.push(`<style data-smbls-style="${zo(n)}">${n}</style>`)}if(Array.isArray(t.scripts))for(let r of t.scripts){if(!r)continue;let n=typeof r=="string",o=n?r:r.src;if(!o&&!r.body)continue;let s=[];o&&s.push(`src="${$t(o)}"`),n||(r.type&&s.push(`type="${$t(r.type)}"`),r.async&&s.push("async"),r.defer&&s.push("defer"),r.integrity&&s.push(`integrity="${$t(r.integrity)}"`),r.crossorigin&&s.push(`crossorigin="${$t(r.crossorigin)}"`),r.referrerpolicy&&s.push(`referrerpolicy="${$t(r.referrerpolicy)}"`),r.nomodule&&s.push("nomodule"));let i=` data-smbls-script="${$t(o||zo(r.body||""))}"`;if(!n&&r.body){let a=String(r.body).replace(/<\/script/gi,"<\\/script");e.push(`<script ${s.join(" ")}${i}>${a}<\/script>`)}else e.push(`<script ${s.join(" ")}${i}><\/script>`)}return e},Jg=(t,e)=>{e||(t={...t,robots:"noindex"});let r=Object.entries(t).reduce((n,[o,s])=>{if(!s&&s!==0&&s!==!1||qO.has(o))return n;if(o==="title")return n.push(`<title>${$t(s)}</title>`),n;if(o==="canonical")return n.push(`<link rel="canonical" href="${$t(s)}">`),n;if(o==="manifest")return n.push(`<link rel="manifest" href="${$t(s)}">`),n;if(o==="favicon"||o==="favicons"||o==="icon"||o==="icons")return(Array.isArray(s)?s:[s]).forEach(f=>{if(typeof f=="string")n.push(`<link rel="icon" href="${$t(f)}">`);else if(typeof f=="object"){let u=WO(f);/rel=/.test(u)?n.push(`<link ${u}>`):n.push(`<link rel="icon" ${u}>`)}}),n;if(o==="alternate")return(Array.isArray(s)?s:[s]).forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).filter(([d,g])=>g!==void 0).map(([d,g])=>`${d}="${$t(g)}"`).join(" ");n.push(`<link rel="alternate" ${u}>`)}}),n;let i=(l,f,u="name")=>{if(typeof f=="string"||typeof f=="number"||typeof f=="boolean")n.push(`<meta ${u}="${$t(l)}" content="${$t(f)}">`);else if(Array.isArray(f))f.forEach(d=>{if(typeof d=="string"||typeof d=="number"||typeof d=="boolean")n.push(`<meta ${u}="${$t(l)}" content="${$t(d)}">`);else if(typeof d=="object"){let g=Object.entries(d).filter(([p,h])=>h!==void 0).map(([p,h])=>`${p}="${$t(h)}"`).join(" ");n.push(`<meta ${g}>`)}});else if(typeof f=="object"){let d=Object.entries(f).filter(([g,p])=>p!==void 0).map(([g,p])=>`${g}="${$t(p)}"`).join(" ");n.push(`<meta ${d}>`)}};if(o.startsWith("http-equiv:")){let l=o.replace("http-equiv:","");return i(l,s,"http-equiv"),n}if(o.startsWith("itemprop:")){let l=o.replace("itemprop:","");return i(l,s,"itemprop"),n}let c=["og:","twitter:","fb:","article:","profile:","book:","business:","music:","product:","video:","DC:","DCTERMS:"].find(l=>o.startsWith(l));if(c){let l=o.replace(c,"");return i(`${c.replace(":","")}:${l}`,s,c==="twitter:"||c==="DC:"||c==="DCTERMS:"?"name":"property"),n}if(o.startsWith("apple:")||o.startsWith("msapplication:")){let l=o.startsWith("apple:")?"apple-":"msapplication-",f=o.replace(/^apple:|^msapplication:/,"");return i(`${l}${f}`,s,"name"),n}return i(o,s),n},['<meta charset="UTF-8">','<meta name="viewport" content="width=device-width, initial-scale=1">']);return r.push(...Sf(t)),r.join(`
33
+ `)},KO=t=>typeof t=="string"&&t.length>0&&!t.startsWith("/")&&!t.startsWith("http"),Xg=t=>typeof t=="string"&&t.length>0,kf=t=>{if(!t||typeof t!="object")return null;if(Xg(t.src))return t.src;let e=t.content;return!e||typeof e!="object"?null:Xg(e.src)?e.src:Xg(e.storageUrl)?e.storageUrl:null}});var vf,tm,fS=V(()=>{"use strict";It();vf=(t,e)=>(P(e)?e:Object.values(e)).reduce((r,n)=>Math.abs(n-t)<Math.abs(r-t)?n:r),tm=(t,e)=>(t=parseFloat(t),v(e)&&(e=Object.values(e)),vf(t,e))});function $n(t){let e=String(t||"").trim();if(!e)return{owner:em,key:"",full:""};let r=null,n=e;if(e.includes("/")){let s=e.indexOf("/");r=e.slice(0,s),n=e.slice(s+1)}n=n.replace(/\.symbo\.ls$/iu,""),r||(r=em);let o=n?`${r}/${n}`:"";return{owner:r,key:n,full:o}}async function Cf(t,e={}){if((e.provider||"kv")==="api")return pS(t,e);let n=await lR(t,e);return n||pS(t,e)}async function lR(t,e={}){let r=e.kvBaseUrl||XO,n=e.env||"production",o=`${r}/kv/${encodeURIComponent(t)}?env=${n}`;try{let s=await fetch(o,{method:"GET"});return s.ok&&(await s.json())?.value||null}catch{return null}}async function pS(t,e={}){let r=e.apiBaseUrl||ZO,{key:n}=$n(t);try{let o=`${r}/core/projects/libraries/available?search=${encodeURIComponent(n)}&limit=10`,s=await fetch(o,{method:"GET"});if(!s.ok)return null;let i=await s.json(),c=(i?.items||i?.data||(Array.isArray(i)?i:[])).find(g=>{let{key:p}=$n(g?.key);return p.toLowerCase()===n.toLowerCase()});if(!c?.id&&!c?._id)return null;let l=c.id||c._id,f=`${r}/core/projects/${encodeURIComponent(l)}/data?branch=main`,u=await fetch(f,{method:"GET"});if(!u.ok)return null;let d=await u.json();return d?.data||d||null}catch{return null}}async function hS(t,e={}){if(v(t))return t;if(k(t)){let{full:r}=$n(t);if(!r)return null;try{let n=await Cf(r,e);return n||console.warn(`[smbls] Shared library "${r}" not found`),n}catch(n){return console.warn(`[smbls] Failed to fetch shared library "${r}":`,n.message),null}}return null}async function sm(t,e={}){return!t||!t.length?[]:(await Promise.all(t.map(async n=>{if(Hr(n)){let o=await hS(bS(n),e);return o?{library:o,ignoreList:n.ignoreList}:null}return hS(n,e)}))).filter(Boolean)}var em,XO,ZO,Ho,gS,JO,QO,uS,mS,dS,yS,tR,ya,nm,Hr,bS,rm,om,eR,rR,_S,nR,oR,sR,iR,aR,cR,xS,ba,_a,wS=V(()=>{"use strict";It();Sn();Rl();em="system",XO="https://smbls-kv.nika-980.workers.dev",ZO="https://api.symbols.app";Ho=(t,e,r,n)=>{for(let o in e){let s=n?`${n}/${o}`:o;r&&r.has(s)||(o in t?v(t[o])&&v(e[o])&&Ho(t[o],e[o],r,s):t[o]=e[o])}},gS=(t,e,r)=>{if(!v(t)||!e.size)return t;let n=`${r}/`,o=!1;for(let i of e)if(i.startsWith(n)){o=!0;break}if(!o)return t;let s={};for(let i in t){if(!Object.prototype.hasOwnProperty.call(t,i))continue;let a=`${r}/${i}`;e.has(a)||(s[i]=gS(t[i],e,a))}return s},JO=new Set,QO=new Set(["components","pages","functions","snippets","methods"]),uS=(t,e)=>e===""&&QO.has(t),mS=["fontFamily","fontfamily","font_family","FONT_FAMILY"],dS=t=>{let e=new Map;if(!v(t))return e;for(let r of mS){let n=t[r];if(v(n))for(let o in n)!v(n[o])||!n[o].isDefault||(e.has(r)||e.set(r,new Set),e.get(r).add(o))}return e},yS=(t,e)=>{for(let r of mS){let n=t[r];if(!v(n))continue;let o=e.get(r),s=null;for(let i in n){let a=n[i];if(!v(a)||!a.isDefault||o&&o.has(i))continue;let c={...a};delete c.isDefault,s||(s={...n}),s[i]=c}s&&(t[r]=s)}},tR=t=>t.replace(/\.js$/iu,""),ya=t=>{let e=new Set;if(!Array.isArray(t))return e;for(let r of t){if(!k(r))continue;let n=r.split("/").map(o=>tR(o.trim())).filter(Boolean).join("/");n&&e.add(n)}return e},nm=(t,e={})=>({library:t,ignoreList:Array.isArray(e.ignoreList)?e.ignoreList:[]}),Hr=t=>v(t)&&Array.isArray(t.ignoreList)&&("library"in t||"key"in t||"name"in t),bS=t=>t.library!==void 0?t.library:t.key??t.name,rm=new Set,om=()=>{rm.clear()},eR=(t,e)=>{let r=e.filter(n=>!rm.has(n));if(r.length){for(let n of r)rm.add(n);gt()&&console.warn(`[smbls] shared library "${t}" ships ${r.map(n=>`methods.${n}`).join(", ")} \u2014 named like a built-in element method. Refused: the built-in wins; a library cannot replace an element method on the consuming app. If the app wants this version, declare it in the app's OWN methods.`)}},rR=(t,e,r)=>{let n=null;for(let o in t)if(wn(o)&&(e.has(`methods/${o}`)||r.push(o),!n)){n={};for(let s in t)wn(s)||(n[s]=t[s])}return n||t},_S=(t,e)=>{let r=ya(t.sharedLibIgnore);return t.sharePages===!1&&r.add("pages"),r.size?new Set([...e,...r]):e},nR=(t,e,r,n="library")=>{let o=_S(e,r),s=[];for(let i in e)if(Object.prototype.hasOwnProperty.call(e,i)&&!(i==="sharePages"||i==="sharedLibIgnore")&&i!=="app"&&!o.has(i)){if(v(e[i])&&v(t[i])){if(i==="designSystem")Ho(t[i],e[i],o,i);else for(let a in e[i])if(!o.has(`${i}/${a}`)){if(i==="methods"&&wn(a)){a in t[i]||s.push(a);continue}a in t[i]?uS(i,t[i][a])&&!uS(i,e[i][a])&&(t[i][a]=e[i][a]):t[i][a]=e[i][a]}}else if(!(i in t)){let a=e[i],c=i==="methods"&&a&&typeof a=="object"?rR(a,o,s):a;t[i]=gS(c,o,i)}}s.length&&eR(n,s)},oR=(t,e,r)=>{if(t!==e){let n=bS(t);if(k(n)&&n)return n;if(t.key||t.name)return t.key||t.name}return e&&(e.key||e.name)||`sharedLibraries[${r}]`},sR=`${em}/default`,iR=t=>k(t)&&t!==""&&$n(t).full===sR,aR=(t,e)=>{if(k(e.key)&&e.key)return e.key;if(t!==e){if(k(t.key)&&t.key)return t.key;if(k(t.name)&&t.name)return t.name}return null},cR=t=>{let e=[],r=[];for(let n=0;n<t.length;n++){let o=t[n],s=o,i=JO;if(Hr(s)&&(i=ya(s.ignoreList),s=s.library),!v(s))continue;let a={entry:o,lib:s,ignore:i,index:n};iR(aR(o,s))?r.push(a):e.push(a)}return{linked:e,bases:r}},xS=(t,e,r)=>{let n=dS(e()),{linked:o,bases:s}=cR(t);for(let a of o)r(a);let i=!n.size&&s.length?dS(e()):null;for(let a of s)r(a);return n.size?n:i&&i.size?i:null},ba=(t,e)=>{if(!e||!e.length)return;let r=t.designSystem,n=xS(e,()=>t.designSystem,({entry:o,lib:s,ignore:i,index:a})=>nR(t,s,i,oR(o,s,a)));n&&(t.designSystem!==r&&(t.designSystem={...t.designSystem}),yS(t.designSystem,n))},_a=(t,e,r=Ho)=>{if(!v(t)||!Array.isArray(e)||!e.length)return t;let n=xS(e,()=>t,({lib:o,ignore:s})=>{let i=o.designSystem;if(!i||typeof i!="object")return;let a=_S(o,s);a.has("designSystem")||r(t,i,a,"designSystem")});return n&&yS(t,n),t}});var im,am,cm,xa,lm,wa,fm,Mn,SS=V(()=>{"use strict";It();im=async t=>{try{await navigator.clipboard.writeText(t)}catch(e){console.warn("Failed to copy text: ",e)}},am=async t=>{try{let e=new Blob([t],{type:"text/javascript"}),r=new window.ClipboardItem({"text/plain":e});await navigator.clipboard.write([r]),console.log("JavaScript code copied to clipboard as text/javascript")}catch(e){console.error("Failed to copy JavaScript code: ",e)}},cm=t=>t.replace(/[^a-zA-Z0-9_]/g,""),xa=t=>(typeof t!="string"&&(t=String(t||"")),t.replace(/(?:^\w|[A-Z]|\b\w)/g,function(e,r){return r===0?e.toLowerCase():e.toUpperCase()}).replace(/\s+/g,"")),lm=t=>t&&t.replace(/\w\S*/g,e=>e.charAt(0).toUpperCase()+e.substr(1).toLowerCase()),wa=t=>t.replace(/[^a-zA-Z0-9]/g," ").trim().toLowerCase().replace(/\s+/g,"-").replace(/-+/g,"-").replace(/^-|-$/g,""),fm=(t="")=>{if(typeof t!="string")return;let e=t.replace(/([A-Z])/g," $1");return e.charAt(0).toUpperCase()+e.slice(1)},Mn=t=>{if(P(t))return t;if(k(t))return t.split(" ");if(v(t))return Object.values(t);if(Ge(t))return[t]}});var um,kS=V(()=>{"use strict";um=()=>{let t=document.styleSheets[0],e="";if(t)try{let r=t.cssRules||t.rules;for(let n=0;n<r.length;n++)e+=r[n].cssText}catch(r){console.error("Unable to access CSS rules. This may be due to CORS restrictions:",r)}else console.log("No stylesheets found in document.styleSheets[0].");return e}});var Qt,Wo,Sa,ka,vS=V(()=>{"use strict";Qt=t=>{let e=t&&t.src;if(!e||typeof e!="string")return null;let r=t.context;if(!r)return null;let n=r.assets&&r.assets[e]||r.files&&r.files[e];if(!n)return null;if(typeof n=="string")return{src:n,type:null,variants:null};if(typeof n=="object"){if(typeof n.src=="string")return n;let o=n.content,s=o&&o.src;if(typeof s=="string")return{...n,src:s,type:n.type??o.type??null,variants:n.variants??o.variants??null}}return null},Wo=(t,{keepOneX:e=!0}={})=>{if(!Array.isArray(t)||!t.length)return"";let r=t.some(o=>typeof o.width=="number"),n=[];for(let o of t)r&&typeof o.width=="number"?n.push(`${o.src} ${o.width}w`):r||(o.scale===1&&e?n.push(o.src):o.scale&&o.scale!==1&&n.push(`${o.src} ${o.scale}x`));return n.join(", ")},Sa=t=>{if(!t||!Array.isArray(t.variants))return"";let e=t.variants.filter(r=>r.format===t.type);return Wo(e,{keepOneX:!1})},ka=(t,e)=>{if(!t||typeof t!="object"||typeof t.src!="string")return[];if(!Array.isArray(t.variants)||!t.variants.length)return[{tag:"img",attr:{src:t.src,alt:e||""}}];let r=new Map;for(let a of t.variants)r.has(a.format)||r.set(a.format,[]),r.get(a.format).push(a);let n=[];for(let[a,c]of r)a!==t.type&&n.push({tag:"source",attr:{type:a,srcset:Wo(c,{keepOneX:!0})}});let o=r.get(t.type)||[],s=Wo(o,{keepOneX:!1}),i={src:t.src,alt:e||""};return s&&(i.srcset=s),[...n,{tag:"img",attr:i}]}});var qo={};$(qo,{CDN_PROVIDERS:()=>we,DOMQL_EVENTS:()=>eh,DOMQ_PROPERTIES:()=>$r,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>_h,HTML_TAGS:()=>Ro,METHODS:()=>Fr,METHODS_EXL:()=>xi,NODE_ENV:()=>Ie,OPTIONS:()=>Wi,PACKAGE_MANAGER_TO_CDN:()=>Ur,PARSED_DOMQ_PROPERTIES:()=>_i,PROPS_METHODS:()=>Mr,STATE_METHODS:()=>xn,STATE_PROPERTIES:()=>Qp,SVG_TAGS:()=>gw,TYPES:()=>di,UNIVERSAL_RESERVED_KEYS:()=>xf,__resetBuiltinMethodWarnings:()=>om,addCaching:()=>Jl,addContext:()=>Zl,addExtend:()=>Uh,addExtends:()=>Ye,addItemAfterEveryElement:()=>Bp,addProtoToArray:()=>gi,addRef:()=>Gl,applyDependentState:()=>ag,applyEvent:()=>of,applyEventUpdate:()=>sf,applyExtends:()=>bw,applyProps:()=>Ni,arrayContainsOtherArray:()=>Lp,arraysEqual:()=>Up,arrayzeValue:()=>Mn,buildImgSrcset:()=>Sa,buildSourcesAndImg:()=>ka,cache:()=>dg,call:()=>Ig,captureSnapshot:()=>Mg,checkForStateTypes:()=>ng,checkIfInherits:()=>nf,checkIfStringIsInArray:()=>Wp,clone:()=>oh,cloneAndMergeArrayExtend:()=>Ri,cloneFunction:()=>Eh,collectExtendsList:()=>Po,concatAddExtends:()=>jh,copyJavaScriptToClipboard:()=>am,copyStringToClipboard:()=>im,createBasedOnType:()=>Kl,createElement:()=>rg,createElementExtends:()=>$l,createExtends:()=>Di,createExtendsFromKeys:()=>Do,createExtendsStack:()=>jl,createIfConditionFlag:()=>Ah,createInheritedState:()=>og,createKey:()=>Ti,createNestedObject:()=>dh,createNestedObjectByKeyPath:()=>ig,createObjectWithoutPrototype:()=>Al,createParent:()=>Yl,createPath:()=>Xl,createProps:()=>ji,createPropsStack:()=>Wl,createRoot:()=>eg,createScope:()=>lg,createSnapshotId:()=>Ai,customDecodeURIComponent:()=>Jp,customEncodeURIComponent:()=>Zp,cutArrayAfterValue:()=>Np,cutArrayBeforeValue:()=>Fp,debounce:()=>Oi,debounceOnContext:()=>vh,decodeNewlines:()=>Xp,deepClone:()=>lt,deepContains:()=>fh,deepDefaults:()=>Ho,deepDestringifyFunctions:()=>be,deepExtend:()=>Il,deepMerge:()=>at,deepMergeExtends:()=>Xe,deepStringifyFunctions:()=>Si,defineSetter:()=>Dg,destringifyGlobalScope:()=>vi,detectHeightOnInit:()=>Vg,detectInfiniteLoop:()=>mh,document:()=>st,encodeNewlines:()=>Yp,error:()=>Pn,excludeKeysFromObject:()=>bh,exec:()=>dt,extendCachedRegistry:()=>Bh,extendStackRegistry:()=>Li,extractArrayExtend:()=>$i,fetchLibraryData:()=>Cf,fibonacciNumberByIndex:()=>Ug,fileEntryUrl:()=>kf,filterArrays:()=>zp,filterArraysFast:()=>Hp,finalizeExtends:()=>Bl,findClosestNumber:()=>vf,findClosestNumberInFactory:()=>tm,findInheritedState:()=>rf,findKeyPosition:()=>Kp,flattenExtend:()=>Lo,formatDate:()=>Bg,generateHash:()=>Pl,generateHeadArrayTags:()=>Sf,generateKey:()=>Ei,generateMetaTags:()=>Jg,get:()=>Tg,getCDNDirUrl:()=>wf,getCDNUrl:()=>Me,getCapitalCaseKeys:()=>Wh,getCdnProviderFromConfig:()=>Vo,getChildStateInKey:()=>ef,getChildren:()=>Pg,getContext:()=>ca,getCookie:()=>Dh,getDB:()=>pa,getEmotionStylesheet:()=>um,getExtendsInElement:()=>zh,getExtendsStack:()=>Pi,getExtendsStackRegistry:()=>Ll,getFrequencyInArray:()=>Ip,getFunctionSource:()=>Le,getHashedExtend:()=>Ii,getImportMapScript:()=>jg,getInObjectByPath:()=>gh,getLocalStorage:()=>Ih,getNev:()=>kh,getPageMetadata:()=>Qg,getParentStateInKey:()=>tf,getPath:()=>ra,getQuery:()=>ha,getRef:()=>Rg,getRoot:()=>sa,getRootContext:()=>aa,getRootData:()=>ia,getRootState:()=>oa,getRootStateInKey:()=>Ql,getSpreadChildren:()=>qh,global:()=>Rp,hasFunction:()=>De,hasHandlerPlugin:()=>To,hasOwnProperty:()=>ah,hashContent:()=>zo,inheritChildExtends:()=>Fl,inheritChildPropsExtends:()=>Ml,inheritParentProps:()=>Bi,inheritRecursiveChildExtends:()=>Nl,initProps:()=>Jh,is:()=>Jt,isArray:()=>P,isBoolean:()=>xl,isBuiltinElementMethod:()=>th,isContextComponent:()=>Kh,isCyclic:()=>yh,isDOMNode:()=>Zt,isDate:()=>Sl,isDefined:()=>Tt,isDevelopment:()=>jr,isEmpty:()=>Cl,isEmptyObject:()=>ch,isEqualDeep:()=>El,isFailedRevival:()=>Cn,isFunction:()=>R,isHtmlElement:()=>fi,isLazyFunction:()=>sh,isLocal:()=>Sh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>Dn,isMethod:()=>$g,isMobile:()=>Rh,isNode:()=>pr,isNot:()=>Dp,isNotProduction:()=>An,isNull:()=>wl,isNumber:()=>Ge,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>zg,isPolyglotRetranslatableKey:()=>Hi,isPolyglotWritableKey:()=>On,isProduction:()=>Nr,isProtectedElementMethod:()=>wn,isStaging:()=>wh,isState:()=>sg,isString:()=>k,isStringFunction:()=>Ao,isTest:()=>Ol,isTesting:()=>xh,isUndefined:()=>Lt,isUniversallyReservedKey:()=>Fg,isUnresolvableDependency:()=>zr,isValidDependencyMap:()=>Ln,isValidHtmlTag:()=>Mh,isWrappedLibrary:()=>Hr,joinArrays:()=>ko,jointStacks:()=>Vh,keys:()=>bf,loadCssFile:()=>Kg,loadJavascript:()=>Gg,loadJavascriptFile:()=>Hg,loadJavascriptFileEmbedSync:()=>qg,loadJavascriptFileSync:()=>Wg,loadRemoteCSS:()=>Yg,loadRemoteScript:()=>Uo,log:()=>Lg,logGroupIf:()=>Oh,logIf:()=>Th,lookdown:()=>Eg,lookdownAll:()=>Ag,lookup:()=>Cg,lowercaseFirstLetter:()=>_n,makeObjectWithoutPrototype:()=>lh,map:()=>nh,mapStringsWithContextComponents:()=>Mi,markPolyglotSeeded:()=>Je,matchesComponentNaming:()=>Ze,memoize:()=>Ch,merge:()=>bt,mergeSharedLibraries:()=>ba,mergeSharedLibraryDesignSystems:()=>_a,nextElement:()=>fa,normalizeIgnoreList:()=>ya,normalizeLibraryKey:()=>$n,objectToString:()=>ki,objectizeStringProperty:()=>Fi,overwrite:()=>Ci,overwriteDeep:()=>Wt,overwriteShallow:()=>En,overwriteState:()=>cg,parse:()=>_f,parseDeep:()=>ta,pickupElementFromProps:()=>zl,pickupPropsFromElement:()=>Ul,polyglotSeededKeys:()=>Io,previousElement:()=>ua,promoteActiveRootState:()=>Fo,propExists:()=>Xh,propertizeElement:()=>Hl,propertizeUpdate:()=>Yh,remove:()=>Xw,removeChars:()=>cm,removeCookie:()=>Lh,removeDuplicateProps:()=>Ui,removeDuplicatesInArray:()=>vo,removeFromArray:()=>$p,removeFromObject:()=>uh,removeNestedKeyByPath:()=>ph,removeValueFromArray:()=>hi,removeValueFromArrayAll:()=>jp,reorderArrayByValues:()=>Vp,replaceLiteralsWithObjectFields:()=>Nt,replaceOctalEscapeSequences:()=>Gp,resolveAsset:()=>Qt,resolveFileReferences:()=>In,resolveHandler:()=>Oo,resolveSharedLibraries:()=>sm,returnValueAsText:()=>ql,runPluginHook:()=>Ot,self:()=>Pp,setActiveRootState:()=>na,setCookie:()=>Ph,setHashedExtend:()=>Dl,setInObjectByPath:()=>hh,setLocalStorage:()=>$h,setNodeStyles:()=>yf,setProps:()=>Og,setPropsPrototype:()=>Vi,sharedLibrary:()=>nm,splitPackageSpecifier:()=>ga,spotByPath:()=>ea,srcsetFor:()=>Wo,stringIncludesAny:()=>yi,stringToObject:()=>ih,stripVersionRangePrefix:()=>ma,swapItemsInArray:()=>Mp,syncProps:()=>zi,toCamelCase:()=>xa,toDashCase:()=>wa,toDescriptionCase:()=>fm,toPriorityOrder:()=>_e,toTitleCase:()=>lm,toggleFullscreen:()=>Ng,triggerEventOn:()=>gr,triggerEventOnUpdate:()=>fg,trimStringFromSymbols:()=>qp,unstackArrayOfObjects:()=>pi,update:()=>Zh,updateProps:()=>Qh,variables:()=>da,verbose:()=>No,warn:()=>la,window:()=>C});var D=V(()=>{"use strict";Tl();Rl();It();hr();Tn();Co();ui();dw();pw();bi();li();hw();Fh();Hh();tg();Vl();vw();Ow();Sn();Rw();Jw();pg();Qw();ug();tS();eS();rS();nS();oS();sS();iS();aS();lS();fS();wS();SS();kS();vS()});var lA=up((Uz,cA)=>{var qs=1e3,Ks=qs*60,Gs=Ks*60,ho=Gs*24,c$=ho*7,l$=ho*365.25;cA.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return f$(t);if(r==="number"&&isFinite(t))return e.long?d$(t):u$(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function f$(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),n=(e[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*l$;case"weeks":case"week":case"w":return r*c$;case"days":case"day":case"d":return r*ho;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Gs;case"minutes":case"minute":case"mins":case"min":case"m":return r*Ks;case"seconds":case"second":case"secs":case"sec":case"s":return r*qs;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function u$(t){var e=Math.abs(t);return e>=ho?Math.round(t/ho)+"d":e>=Gs?Math.round(t/Gs)+"h":e>=Ks?Math.round(t/Ks)+"m":e>=qs?Math.round(t/qs)+"s":t+"ms"}function d$(t){var e=Math.abs(t);return e>=ho?Id(t,e,ho,"day"):e>=Gs?Id(t,e,Gs,"hour"):e>=Ks?Id(t,e,Ks,"minute"):e>=qs?Id(t,e,qs,"second"):t+" ms"}function Id(t,e,r,n){var o=e>=r*1.5;return Math.round(t/r)+" "+n+(o?"s":"")}});var uA=up((zz,fA)=>{function p$(t){r.debug=r,r.default=r,r.coerce=c,r.disable=i,r.enable=o,r.enabled=a,r.humanize=lA(),r.destroy=l,Object.keys(t).forEach(f=>{r[f]=t[f]}),r.names=[],r.skips=[],r.formatters={};function e(f){let u=0;for(let d=0;d<f.length;d++)u=(u<<5)-u+f.charCodeAt(d),u|=0;return r.colors[Math.abs(u)%r.colors.length]}r.selectColor=e;function r(f){let u,d=null,g,p;function h(...m){if(!h.enabled)return;let y=h,x=Number(new Date),b=x-(u||x);y.diff=b,y.prev=u,y.curr=x,u=x,m[0]=r.coerce(m[0]),typeof m[0]!="string"&&m.unshift("%O");let _=0;m[0]=m[0].replace(/%([a-zA-Z%])/g,(S,E)=>{if(S==="%%")return"%";_++;let O=r.formatters[E];if(typeof O=="function"){let L=m[_];S=O.call(y,L),m.splice(_,1),_--}return S}),r.formatArgs.call(y,m),(y.log||r.log).apply(y,m)}return h.namespace=f,h.useColors=r.useColors(),h.color=r.selectColor(f),h.extend=n,h.destroy=r.destroy,Object.defineProperty(h,"enabled",{enumerable:!0,configurable:!1,get:()=>d!==null?d:(g!==r.namespaces&&(g=r.namespaces,p=r.enabled(f)),p),set:m=>{d=m}}),typeof r.init=="function"&&r.init(h),h}function n(f,u){let d=r(this.namespace+(typeof u>"u"?":":u)+f);return d.log=this.log,d}function o(f){r.save(f),r.namespaces=f,r.names=[],r.skips=[];let u=(typeof f=="string"?f:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let d of u)d[0]==="-"?r.skips.push(d.slice(1)):r.names.push(d)}function s(f,u){let d=0,g=0,p=-1,h=0;for(;d<f.length;)if(g<u.length&&(u[g]===f[d]||u[g]==="*"))u[g]==="*"?(p=g,h=d,g++):(d++,g++);else if(p!==-1)g=p+1,h++,d=h;else return!1;for(;g<u.length&&u[g]==="*";)g++;return g===u.length}function i(){let f=[...r.names,...r.skips.map(u=>"-"+u)].join(",");return r.enable(""),f}function a(f){for(let u of r.skips)if(s(f,u))return!1;for(let u of r.names)if(s(f,u))return!0;return!1}function c(f){return f instanceof Error?f.stack||f.message:f}function l(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}fA.exports=p$});var dA=up((ce,$d)=>{ce.formatArgs=g$;ce.save=m$;ce.load=y$;ce.useColors=h$;ce.storage=b$();ce.destroy=(()=>{let t=!1;return()=>{t||(t=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();ce.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function h$(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let t;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(t=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(t[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function g$(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+$d.exports.humanize(this.diff),!this.useColors)return;let e="color: "+this.color;t.splice(1,0,e,"color: inherit");let r=0,n=0;t[0].replace(/%[a-zA-Z%]/g,o=>{o!=="%%"&&(r++,o==="%c"&&(n=r))}),t.splice(n,0,e)}ce.log=console.debug||console.log||(()=>{});function m$(t){try{t?ce.storage.setItem("debug",t):ce.storage.removeItem("debug")}catch{}}function y$(){let t;try{t=ce.storage.getItem("debug")||ce.storage.getItem("DEBUG")}catch{}return!t&&typeof process<"u"&&"env"in process&&(t=process.env.DEBUG),t}function b$(){try{return localStorage}catch{}}$d.exports=uA()(ce);var{formatters:_$}=$d.exports;_$.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}});var Fx={};$(Fx,{ANIMATION_PROPS:()=>Iy,ARIA_ROLES:()=>IP,ATTR_TRANSFORMS:()=>Qn,BLOCK_PROPS:()=>$y,CDN_PROVIDERS:()=>we,COMPOUND_CSS_KEYWORDS:()=>Nn,CONFIG:()=>Un,CONFIG_MERGE_EXL:()=>ue,CSS_NAMED_COLOR_HEX:()=>Ef,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_PROPS_REGISTRY:()=>wt,CSS_UNITS:()=>So,DEFAULT_CONFIG:()=>Cc,DEFAULT_CSS_PROPERTIES_LIST:()=>Et,DELEGATED_EVENTS:()=>ms,DESIGN_SYSTEM_OPTIONS:()=>w_,DOMQL_EVENTS:()=>eh,DOMQ_PROPERTIES:()=>$r,DOM_EVENTS:()=>$0,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>_h,FACTORY:()=>fe,FLEX_PROPS:()=>By,FONT_PROPS:()=>My,GRID_PROPS:()=>Vy,HOST_REGISTERED_PACKAGES:()=>p1,HTML_ATTRIBUTES:()=>bu,HTML_TAGS:()=>Ro,LIFECYCLE_EVENTS:()=>rn,METHODS:()=>Fr,METHODS_EXL:()=>xi,MISC_PROPS:()=>Fy,MIXINS:()=>hu,NODE_ENV:()=>Ie,OPTIONS:()=>Wi,PACKAGE_MANAGER_TO_CDN:()=>Ur,PARSED_DOMQ_PROPERTIES:()=>_i,POSITION_PROPS:()=>Ny,PROPS_METHODS:()=>Mr,REGISTRY:()=>jt,RESERVED_STORE_METHODS:()=>Kx,ROUTER_OPTIONS:()=>rd,SIGNAL_ENGINE_KEY:()=>xo,SIGNAL_INSTANCES_KEY:()=>bo,STANDARD_SCHEME_QUERIES:()=>Yf,STATE_PROPERTIES:()=>Qp,STORE_METHOD_NAMES:()=>qx,SVG_TAGS:()=>hs,THEME_PROPS:()=>jy,TIMING_PROPS:()=>uc,TYPES:()=>di,UNIVERSAL_RESERVED_KEYS:()=>xf,VALUE_TRANSFORMERS:()=>su,VERSION:()=>Yx,__resetBuiltinMethodWarnings:()=>om,__resetSignalEngine:()=>Ap,__resetSignalInstances:()=>Ep,__resetSkinWarnings:()=>cy,__resetStateShadowWarnings:()=>Gx,activateConfig:()=>OS,addCaching:()=>Jl,addContext:()=>Zl,addDelegatedEvent:()=>lc,addExtend:()=>Uh,addExtends:()=>Ye,addItemAfterEveryElement:()=>Bp,addMethods:()=>Ss,addProtoToArray:()=>gi,addRef:()=>Gl,aliasCaseVariants:()=>es,animation:()=>Mm,appendSVGSprite:()=>ec,appendSvgIconsSprite:()=>Gn,applyAttrTransforms:()=>Py,applyCSS:()=>d_,applyDependentState:()=>ag,applyDocument:()=>tc,applyEvent:()=>of,applyEventUpdate:()=>sf,applyExtends:()=>bs,applyHeadings:()=>Jf,applyInitialState:()=>Ru,applyMediaSequenceVars:()=>qr,applyProps:()=>Ni,applyReset:()=>rc,applySequenceGlobalVars:()=>ja,applySequenceVars:()=>xr,applySkins:()=>nc,applySpacingSequence:()=>za,applyStateMethods:()=>me,applyTimingSequence:()=>Qa,applyTrueProps:()=>zy,applyTypographySequence:()=>Xa,arrayContainsOtherArray:()=>Lp,arraysEqual:()=>Up,arrayzeValue:()=>Mn,assertEmitIntegrity:()=>xy,batch:()=>yl,breakpoints:()=>Im,buildImgSrcset:()=>Sa,buildSkinVarStyles:()=>Yn,buildSourcesAndImg:()=>ka,buildThemeVarStyles:()=>td,cache:()=>dg,cacheNode:()=>en,call:()=>Ig,callStateMethod:()=>pc,camelToAttr:()=>or,camelToLowerAttr:()=>M0,captureSnapshot:()=>Mg,changeGlobalTheme:()=>iu,changeLightness:()=>ym,checkAttributeByTagName:()=>Te,checkEventFunctions:()=>Ry,checkForStateTypes:()=>ng,checkIfBoxSize:()=>Ua,checkIfInherits:()=>nf,checkIfStringIsInArray:()=>Wp,class:()=>Vm,clone:()=>oh,cloneAndMergeArrayExtend:()=>Ri,cloneFunction:()=>Eh,collectExtendsList:()=>Po,color:()=>Am,colorStringToRgbaArray:()=>Se,components:()=>Rs,compositeOverBackdrop:()=>jn,concatAddExtends:()=>jh,contrastRatio:()=>Yo,convertSvgToSymbol:()=>Va,copyJavaScriptToClipboard:()=>am,copyStringToClipboard:()=>im,create:()=>Mx,createAsync:()=>lM,createBasedOnType:()=>Kl,createComputed:()=>Hx,createConfig:()=>Da,createDefine:()=>_E,createEffect:()=>Y,createElement:()=>rg,createElementExtends:()=>$l,createExtends:()=>Di,createExtendsFromKeys:()=>Do,createExtendsStack:()=>jl,createHTMLNode:()=>ps,createIfConditionFlag:()=>Ah,createInheritedState:()=>og,createKey:()=>Ti,createNestedObject:()=>dh,createNestedObjectByKeyPath:()=>ig,createObjectWithoutPrototype:()=>Al,createParent:()=>Yl,createPath:()=>Xl,createProps:()=>ji,createPropsStack:()=>Wl,createRoot:()=>eg,createScope:()=>lg,createScopeStore:()=>bl,createSignal:()=>ai,createSkeleton:()=>uM,createSnapshotId:()=>Ai,createState:()=>Qy,createStore:()=>fr,createSync:()=>fM,css:()=>he,cssMediaVars:()=>Hf,cssVars:()=>zf,customDecodeURIComponent:()=>Jp,customEncodeURIComponent:()=>Zp,cutArrayAfterValue:()=>Np,cutArrayBeforeValue:()=>Fp,debounce:()=>Oi,debounceOnContext:()=>vh,decodeNewlines:()=>Xp,deepClone:()=>lt,deepContains:()=>fh,deepDefaults:()=>Ho,deepDestringifyFunctions:()=>be,deepExtend:()=>Il,deepMerge:()=>at,deepMergeExtends:()=>Xe,deepStringifyFunctions:()=>Si,defaultDefine:()=>Ms,defineResolvedThemeSignal:()=>ts,defineSetter:()=>Dg,defineThemeSignal:()=>Qo,destringifyGlobalScope:()=>vi,destroy:()=>Pc,detectHeightOnInit:()=>Vg,detectInfiniteLoop:()=>mh,detectTag:()=>tn,devices:()=>$m,dispose:()=>vr,encodeNewlines:()=>Yp,error:()=>Pn,excludeKeysFromObject:()=>bh,exec:()=>dt,executeAttr:()=>NP,exetuteClassPerComponent:()=>m2,extendCachedRegistry:()=>Bh,extendStackRegistry:()=>Li,extractArrayExtend:()=>$i,extractConditionalAttrs:()=>VP,fetchLibraryData:()=>Cf,fibonacciNumberByIndex:()=>Ug,fileEntryUrl:()=>kf,filterArrays:()=>zp,filterArraysFast:()=>Hp,filterAttributesByTagName:()=>FP,finalizeExtends:()=>Bl,findClosestNumber:()=>vf,findClosestNumberInFactory:()=>tm,findHeadingLetter:()=>Kf,findHeadings:()=>Na,findInheritedState:()=>rf,findKeyPosition:()=>Kp,flattenExtend:()=>Lo,font:()=>wm,fontFace:()=>vm,fontFamily:()=>Sm,fontFamilyTypes:()=>km,formatDate:()=>Bg,generateHash:()=>Pl,generateHeadArrayTags:()=>Sf,generateKey:()=>Ei,generateMetaTags:()=>Jg,generateSequence:()=>te,generateSequencePosition:()=>Gm,generateSprite:()=>Ba,generateSubSequence:()=>Ma,get:()=>Tg,getActiveConfig:()=>A,getActiveDocument:()=>Jn,getActiveLang:()=>ln,getCDNDirUrl:()=>wf,getCDNUrl:()=>Me,getCacheSize:()=>Sy,getCapitalCaseKeys:()=>Wh,getCdnProviderFromConfig:()=>Vo,getChildStateInKey:()=>ef,getChildren:()=>Pg,getColor:()=>ot,getColorShade:()=>Pf,getContext:()=>ca,getCookie:()=>Dh,getDB:()=>pa,getDefaultOrFirstKey:()=>Bn,getEmitStats:()=>du,getEmotionStylesheet:()=>um,getExtendsInElement:()=>zh,getExtendsStack:()=>Pi,getExtendsStackRegistry:()=>Ll,getFnPrefixAndValue:()=>_r,getFontFace:()=>_m,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>jf,getFontFaceString:()=>Ta,getFontFamily:()=>Ya,getFontFormat:()=>Ff,getFontSizeByKey:()=>Za,getFrequencyInArray:()=>Ip,getFunctionSource:()=>Le,getHashedExtend:()=>Ii,getImportMapScript:()=>jg,getInObjectByPath:()=>gh,getLanguages:()=>Lc,getLocalStateLang:()=>Nc,getLocalStorage:()=>Ih,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getNev:()=>kh,getObserver:()=>lr,getPageMetadata:()=>Qg,getParentStateInKey:()=>tf,getPath:()=>ra,getQuery:()=>ha,getRef:()=>Rg,getResolvedThemeSignal:()=>TS,getRgbTone:()=>tr,getRoot:()=>sa,getRootContext:()=>aa,getRootData:()=>ia,getRootState:()=>oa,getRootStateInKey:()=>Ql,getSafeInk:()=>Xf,getSafeInkInfo:()=>Jm,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>Fa,getSequenceValuePropertyPair:()=>rr,getShadow:()=>Wa,getShapeByKey:()=>Ja,getSignals:()=>Wx,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getSpreadChildren:()=>qh,getSubratio:()=>$a,getSubratioDifference:()=>Ia,getSystemGlobalTheme:()=>ge,getTheme:()=>ry,getThemeSignal:()=>AS,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,global:()=>Rp,gradient:()=>Tm,grid:()=>Bm,hasFunction:()=>De,hasHandlerPlugin:()=>To,hasOwnProperty:()=>ah,hashContent:()=>zo,hexToRgb:()=>pm,hexToRgbArray:()=>Af,hexToRgba:()=>gm,hslToRgb:()=>Rf,icons:()=>Pm,inheritChildExtends:()=>Fl,inheritChildPropsExtends:()=>Ml,inheritParentProps:()=>Bi,inheritRecursiveChildExtends:()=>Nl,init:()=>Ar,initPolyglot:()=>sd,initProps:()=>Jh,injectGlobal:()=>xt,is:()=>Jt,isArray:()=>P,isBoolean:()=>xl,isBuiltinElementMethod:()=>th,isCSSVar:()=>_t,isContextComponent:()=>Kh,isCyclic:()=>yh,isDOMNode:()=>Zt,isDate:()=>Sl,isDefined:()=>Tt,isDevelopment:()=>jr,isDomDocument:()=>ur,isEmpty:()=>Cl,isEmptyObject:()=>ch,isEnumeratedTrueFalseAttr:()=>sr,isEqualDeep:()=>El,isFailedRevival:()=>Cn,isFunction:()=>R,isGoogleFontsUrl:()=>Xo,isHostObject:()=>dr,isHtmlElement:()=>fi,isLazyFunction:()=>sh,isLocal:()=>Sh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>Dn,isMethod:()=>$g,isMobile:()=>Rh,isNode:()=>pr,isNot:()=>Dp,isNotProduction:()=>An,isNull:()=>wl,isNumber:()=>Ge,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>zg,isPlainColor:()=>Yr,isPolyglotRetranslatableKey:()=>Hi,isPolyglotWritableKey:()=>On,isProduction:()=>Nr,isProtectedElementMethod:()=>wn,isRawUnitValue:()=>ci,isResolvedColor:()=>Fe,isScalingUnit:()=>bn,isStaging:()=>wh,isState:()=>sg,isStore:()=>kt,isString:()=>k,isStringFunction:()=>Ao,isSvgTag:()=>gs,isTest:()=>Ol,isTesting:()=>xh,isTracking:()=>eb,isUndefined:()=>Lt,isUniversallyReservedKey:()=>Fg,isUnresolvableDependency:()=>zr,isValidDependencyMap:()=>Ln,isValidHtmlTag:()=>Mh,isValidTag:()=>ds,isWasmLoaded:()=>oE,isWrappedLibrary:()=>Hr,isWritableFamilyBucket:()=>Op,joinArrays:()=>ko,jointStacks:()=>Vh,keyframes:()=>us,keys:()=>bf,linearChannelToSrgb:()=>If,loadCssFile:()=>Kg,loadJavascript:()=>Gg,loadJavascriptFile:()=>Hg,loadJavascriptFileEmbedSync:()=>qg,loadJavascriptFileSync:()=>Wg,loadRemoteCSS:()=>Yg,loadRemoteScript:()=>Uo,loadTranslations:()=>$c,loadWasm:()=>nE,log:()=>Lg,logGroupIf:()=>Oh,logIf:()=>Th,lookdown:()=>Eg,lookdownAll:()=>Ag,lookup:()=>Cg,lowercaseFirstLetter:()=>_n,makeObjectWithoutPrototype:()=>lh,map:()=>nh,mapStringsWithContextComponents:()=>Mi,markPolyglotSeeded:()=>Je,matchesComponentNaming:()=>Ze,media:()=>Cm,memoize:()=>Ch,merge:()=>bt,mergeSharedLibraries:()=>ba,mergeSharedLibraryDesignSystems:()=>_a,mixTwoColors:()=>dm,mixTwoRgb:()=>mm,mixTwoRgba:()=>Df,nextElement:()=>fa,normalizeIgnoreList:()=>ya,normalizeLibraryKey:()=>$n,numToLetterMap:()=>er,objectToString:()=>ki,objectizeStringProperty:()=>Fi,oklabToLinearSrgb:()=>$f,oklabToOklch:()=>Ca,oklchToGamutSafeSrgb:()=>Ea,oklchToOklab:()=>Mf,opacify:()=>Go,overwrite:()=>Ci,overwriteDeep:()=>Wt,overwriteShallow:()=>En,overwriteState:()=>cg,parkHostObject:()=>Ir,parse:()=>_f,parseColorToken:()=>Ut,parseDeep:()=>ta,pickupElementFromProps:()=>zl,pickupPropsFromElement:()=>Ul,polyglotFunctions:()=>Xc,polyglotPlugin:()=>Ns,polyglotSeededKeys:()=>Io,popConfig:()=>it,popStaticCssPass:()=>Su,previousElement:()=>ua,promoteActiveRootState:()=>Fo,propExists:()=>Xh,propertizeElement:()=>Hl,propertizeUpdate:()=>Yh,pushConfig:()=>ct,pushStaticCssPass:()=>wu,quietColorProbe:()=>Hn,refreshContextProto:()=>Cu,registerEvent:()=>ys,registerHostPackages:()=>h1,registerSignalInstance:()=>_o,reinit:()=>u_,relativeLuminance:()=>Fn,remove:()=>ws,removeChars:()=>cm,removeCookie:()=>Lh,removeDelegatedEvent:()=>fc,removeDuplicateProps:()=>Ui,removeDuplicatesInArray:()=>vo,removeFromArray:()=>$p,removeFromObject:()=>uh,removeNestedKeyByPath:()=>ph,removeValueFromArray:()=>hi,removeValueFromArrayAll:()=>jp,reorderArrayByValues:()=>Vp,replaceLiteralsWithObjectFields:()=>Nt,replaceOctalEscapeSequences:()=>Gp,resetEmitStats:()=>_y,resolveAsset:()=>Qt,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveColorsInGradient:()=>sc,resolveConfigDocument:()=>wo,resolveDesignSystemClass:()=>G0,resolveFileReferences:()=>In,resolveFileSource:()=>Oy,resolveFileUrl:()=>ke,resolveGridTracks:()=>z0,resolveHandler:()=>Oo,resolvePropValue:()=>nn,resolveShadowValue:()=>qn,resolveSharedLibraries:()=>sm,returnSubThemeOrDefault:()=>bm,returnValueAsText:()=>ql,rgbArrayToHex:()=>Tf,rgbToHSL:()=>Of,rgbToHex:()=>hm,runPluginHook:()=>Ot,runThroughMedia:()=>Zf,schemeGuardSelector:()=>Zr,schemeMediaQuery:()=>Xr,scratchDefaultConfig:()=>Jo,scratchSystem:()=>is,scratchUtils:()=>Kr,self:()=>Pp,semanticIcons:()=>Dm,sequence:()=>br,serializeAttrValue:()=>re,set:()=>Xn,setActiveConfig:()=>Wf,setActiveDocument:()=>by,setActiveRootState:()=>na,setAdaptiveSchemeVar:()=>Jr,setClass:()=>WD,setClassname:()=>y2,setColor:()=>Gr,setCookie:()=>Ph,setCssEngineHook:()=>Qu,setCustomFont:()=>Aa,setCustomFontMedia:()=>Wr,setEach:()=>uy,setFont:()=>Ga,setFontFamily:()=>os,setFontImport:()=>Zo,setGradient:()=>rs,setHashedExtend:()=>Dl,setInCustomFontMedia:()=>Nf,setInObjectByPath:()=>hh,setLang:()=>Mc,setLocalStorage:()=>$h,setMediaTheme:()=>ns,setNodeStyles:()=>yf,setObserver:()=>Ke,setProps:()=>Og,setPropsPrototype:()=>Vi,setSVG:()=>ss,setScalingVar:()=>La,setShadow:()=>Qr,setSubScalingVar:()=>qf,setSvgIcon:()=>Kn,setTheme:()=>Ka,setValue:()=>fy,setVariables:()=>Ym,setWasmEngine:()=>cc,shadow:()=>Rm,shape:()=>Hm,sharedLibrary:()=>nm,sizes:()=>zm,skins:()=>Wm,spacing:()=>Em,splitPackageSpecifier:()=>ga,splitSpacedValue:()=>Ha,splitTopLevelCommas:()=>yr,splitTopLevelSpaces:()=>pt,splitTransition:()=>ou,spotByPath:()=>ea,srcsetFor:()=>Wo,srgbChannelToLinear:()=>Lf,srgbToOklab:()=>va,stringIncludesAny:()=>yi,stringToObject:()=>ih,stripVersionRangePrefix:()=>ma,svg:()=>Fm,svgData:()=>Nm,swapItemsInArray:()=>Mp,syncProps:()=>zi,templates:()=>jm,theme:()=>Om,timing:()=>Lm,toCamel:()=>Pa,toCamelCase:()=>xa,toDashCase:()=>wa,toDescriptionCase:()=>fm,toLinearChannel:()=>Ko,toPriorityOrder:()=>_e,toTitleCase:()=>lm,toggleFullscreen:()=>Ng,transformBackgroundImage:()=>eu,transformBorder:()=>nr,transformBorderRadius:()=>wr,transformBoxShadow:()=>oc,transformClassname:()=>X0,transformDuration:()=>ic,transformGridTemplate:()=>nu,transformShadow:()=>tu,transformSize:()=>vt,transformSizeRatio:()=>I,transformTextStroke:()=>Qf,transformTransition:()=>ly,transformersByPrefix:()=>Hy,transfromGap:()=>ru,translate:()=>Ic,triggerEventOn:()=>gr,triggerEventOnUpdate:()=>fg,trimStringFromSymbols:()=>qp,typography:()=>Oa,unit:()=>xm,unstackArrayOfObjects:()=>pi,update:()=>_s,updateProps:()=>Qh,updateVars:()=>HD,upsertTranslation:()=>Fc,useCssInProps:()=>se,useHostState:()=>tb,usePropsAsCSS:()=>K0,useSelectorsAsCSS:()=>Y0,variables:()=>da,vars:()=>Um,verbose:()=>No,warn:()=>la,warnStateKeyShadowsMethod:()=>_l,window:()=>C,wrapHoverRule:()=>Sr});module.exports=dT(Fx);var Tp={};$(Tp,{RESERVED_STORE_METHODS:()=>Kx,SIGNAL_ENGINE_KEY:()=>xo,SIGNAL_INSTANCES_KEY:()=>bo,STORE_METHOD_NAMES:()=>qx,VERSION:()=>Yx,__resetSignalEngine:()=>Ap,__resetSignalInstances:()=>Ep,__resetStateShadowWarnings:()=>Gx,batch:()=>yl,createComputed:()=>Hx,createEffect:()=>Y,createScopeStore:()=>bl,createSignal:()=>ai,createStore:()=>fr,getObserver:()=>lr,getSignals:()=>Wx,isStore:()=>kt,registerSignalInstance:()=>_o,setObserver:()=>Ke,warnStateKeyShadowsMethod:()=>_l});var bp={};$(bp,{WRITE_JOURNAL:()=>ni,batch:()=>si,createComputed:()=>hT,createEffect:()=>gT,createSignal:()=>We,getObserver:()=>mp,journalWrite:()=>oi,setObserver:()=>pT});var Xt=null,fl=0,ul=[],mp=()=>Xt,pT=t=>{Xt=t},dl=0,dp=[];function We(t){let e=new Set;function r(){return Xt&&(e.add(Xt),Xt._sources.add(s)),t}function n(i){i!==t&&(t=i,wT(e))}function o(){return t}let s={get:r,set:n,peek:o,_subscribers:e,_type:"signal"};return s}function hT(t){let e,r=!0,n=new Set,o={_sources:new Set,_type:"computed",_subscribers:n,_execute(){gp(o);let s=Xt;Xt=o;try{e=t(),r=!1}finally{Xt=s}},_notify(){r=!0,n.size>0&&Ux(n)},get(){return Xt&&(n.add(Xt),Xt._sources.add(o)),r&&o._execute(),e},peek(){return r&&o._execute(),e}};return o._execute(),o}var Pe=new Set,pp=!1,ni=[];function oi(t){ni.push(t),ni.length>32&&ni.shift()}function gT(t,e){let r=e?.depth??0,n={_sources:new Set,_type:"effect",_depth:r,_label:e?.label,_disposed:!1,_subscribers:new Set,_execute(){if(n._disposed)return;gp(n);let o=Xt;Xt=n;try{t()}catch(s){console.error("[smbls] effect error:",s)}finally{Xt=o}},_notify(){n._disposed||(fl>0?ul.push(n):dl>0?dp.push(n):yp(n))},dispose(){n._disposed=!0,gp(n)}};return n._execute(),n}function si(t){fl++;try{t()}finally{fl--,fl===0&&xT()}}var hp=!1,jx=1e3,mT=8,yT=256,bT=4;function Bx(){return typeof performance<"u"?performance.now():Date.now()}function yp(t){Pe.add(t),!hp&&(pp||(pp=!0,queueMicrotask(Vx)))}var yo=[];function _T(){if(Pe.size===1){let[e]=Pe;return Pe.clear(),e._disposed?0:(e._execute(),1)}yo.length=0;for(let e of Pe)yo.push(e);Pe.clear(),yo.sort((e,r)=>e._depth-r._depth);let t=0;for(let e=0;e<yo.length;e++){let r=yo[e];r._disposed||(r._execute(),t++)}return yo.length=0,t}function Vx(t=0,e=0){if(pp=!1,Pe.size===0)return;hp=!0;let r=Bx(),n=!1;try{for(;Pe.size>0;){if(++t>jx){let o=new Map;for(let c of Pe){let l=c._label;if(typeof l=="function")try{l=l()}catch{l="<label error>"}if(l=l||"<unlabeled>",o.set(l,(o.get(l)||0)+1),o.size>=12)break}let s=[...o.entries()].map(([c,l])=>l>1?`${c} \xD7${l}`:c).join(", "),i=new Map;for(let c of ni)i.set(c,(i.get(c)||0)+1);let a=[...i.entries()].map(([c,l])=>l>1?`${c} \xD7${l}`:c).join(", ");console.error("[smbls] reactive effect cascade exceeded",jx,"passes in a single flush \u2014 breaking to avoid hanging the thread.","This usually means an effect (or an onUpdate/subscribeTo handler","it calls into) unconditionally writes back a signal it depends on.","Still queued at break (the loop participants):",s||"<queue empty>","\u2014 last notifying store writes:",a||"<none recorded>"),Pe.clear();break}if(e+=_T(),Pe.size>0&&(e>=yT||t>=bT)&&Bx()-r>mT){n=!0,setTimeout(()=>Vx(t,e),0);break}}}finally{n||(hp=!1)}}function xT(){for(let t=0;t<ul.length;t++)yp(ul[t]);ul.length=0}function Ux(t){dl++;try{for(let e of t)e._notify()}finally{if(dl--,dl===0&&dp.length>0){let e=dp.splice(0);for(let r=0;r<e.length;r++)yp(e[r])}}}function wT(t){Ux(t)}function gp(t){for(let e of t._sources)e._subscribers.delete(t);t._sources.clear()}var Cp={};$(Cp,{RESERVED_STORE_METHODS:()=>ii,STORE_METHOD_NAMES:()=>vp,__resetStateShadowWarnings:()=>ST,createScopeStore:()=>ET,createStore:()=>pl,getSignals:()=>CT,isStore:()=>vT,warnStateKeyShadowsMethod:()=>kp});var qe=Symbol("store"),hl=Symbol("signals"),vp=["update","parse","clean","keys","values","replace","add","remove","destroy","quietUpdate"],ii=new Set(vp),Sp=new Set,_p=(t,e)=>t?t+"."+e:String(e);function kp(t,e){let r=(e||"")+"::"+t;if(Sp.has(r))return;Sp.add(r);let n=e?`state.${e}`:"state",o=`[smbls/state] "${t}" is a reserved store-method name and was written as DATA at ${n}.${t}. The value is preserved and readable \u2014 data wins over the method \u2014 but "${n}.${t}(\u2026)" no longer reaches the store method on this node. Use "${n}.$${t}(\u2026)" for the method, or rename the data key. Reserved: ${vp.join(", ")}.`;typeof console<"u"&&console.warn&&console.warn(o)}function ST(){Sp.clear()}var xp=t=>!t||typeof t!="object"||Array.isArray(t)||t[qe]||Object.isFrozen(t)||typeof Node<"u"&&t instanceof Node||t.__ref||t.nodeType||t.nodeName||!gl(t),kT=12,gl=t=>{if(!t||typeof t!="object")return!1;let e=Object.getPrototypeOf(t);return e===Object.prototype||e===null};function ml(t,e,r){if(t===e)return!0;if(r>kT)return!1;if(Array.isArray(t)||Array.isArray(e)){if(!Array.isArray(t)||!Array.isArray(e)||t.length!==e.length)return!1;for(let n=0;n<t.length;n++)if(!ml(t[n],e[n],r+1))return!1;return!0}if(gl(t)&&gl(e)){let n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(let s of n)if(!Object.prototype.hasOwnProperty.call(e,s)||!ml(t[s],e[s],r+1))return!1;return!0}return!1}function pl(t,e,r,n){r===void 0&&(r=0),n===void 0&&(n="");let o={},s={},i=b=>Object.prototype.hasOwnProperty.call(o,b)&&Object.prototype.hasOwnProperty.call(s,b),a=e&&e.maxDepth||8;if(t&&typeof t=="object")for(let b in t){if(b==="__proto__"||!Object.prototype.hasOwnProperty.call(t,b))continue;if(b.startsWith("__")){s[b]=t[b];continue}ii.has(b)&&kp(b,n);let _=t[b];r<a&&_&&typeof _=="object"&&!xp(_)?(s[b]=_,o[b]=We(pl(_,e,r+1,_p(n,b)))):(s[b]=_,o[b]=We(_))}let c=new Proxy(s,{get(b,_){if(_===qe)return!0;if(_===hl)return o;if(_==="__raw")return b;if(_==="$update")return l;if(_==="$parse")return u;if(_==="$clean")return d;if(_==="$keys")return g;if(_==="$values")return p;if(_==="$replace")return h;if(_==="$add")return m;if(_==="$remove")return y;if(_==="$destroy")return x;if(_==="$quietUpdate")return f;if(ii.has(_)&&!Object.prototype.hasOwnProperty.call(o,_))switch(_){case"update":return l;case"parse":return u;case"clean":return d;case"keys":return g;case"values":return p;case"replace":return h;case"add":return m;case"remove":return y;case"destroy":return x;case"quietUpdate":return f}if(_==="__element")return b.__element;if(_==="parent")return b.parent;if(_==="root")return b.root;if(Object.prototype.hasOwnProperty.call(o,_)){let S=o[_].get();if(S!==void 0||!(_!=="root"&&b.root&&b.root!==c))return S}if(b[_]!==void 0)return b[_];let w=typeof _=="string"&&!_.startsWith("__")&&_!=="then"&&_!=="constructor"&&mp()!=null;if(_!=="root"&&b.root&&b.root!==c){let S=b.root[_];return w&&!Object.prototype.hasOwnProperty.call(o,_)&&(o[_]=We(void 0),o[_].get()),S}if(w)return o[_]=We(void 0),o[_].get()},set(b,_,w){if(_==="__proto__")return!1;if(_==="__element"||_==="parent"||_==="root"||typeof _=="string"&&_.startsWith("__")&&!Object.prototype.hasOwnProperty.call(o,_))return b[_]=w,!0;ii.has(_)&&kp(_,n);let S=_p(n,_);if(Object.prototype.hasOwnProperty.call(o,_))if(w&&typeof w=="object"&&!xp(w)){if(w===b[_])return!0;let E=o[_].peek(),O=E&&E[qe]?E.$parse():E;if(ml(w,O,0))return!0;b[_]=w,oi(S),o[_].set(pl(w,e,r+1,S))}else{if(Array.isArray(w)&&w!==b[_]&&Array.isArray(o[_].peek())&&ml(w,o[_].peek(),0))return!0;o[_].peek()!==w&&oi(S),b[_]=w,o[_].set(w)}else b[_]=w,w&&typeof w=="object"&&!xp(w)?o[_]=We(pl(w,e,r+1,S)):o[_]=We(w);return!0},has(b,_){return typeof _=="string"&&_.charCodeAt(0)===36&&ii.has(_.slice(1))?!0:_ in b},ownKeys(b){return Object.keys(o).filter(i)},getOwnPropertyDescriptor(b,_){return i(_)?{enumerable:!0,configurable:!0,value:o[_].peek()}:Object.getOwnPropertyDescriptor(b,_)},deleteProperty(b,_){return o[_]&&(o[_].peek()!==void 0&&oi(_p(n,_)),o[_].set(void 0),delete o[_]),delete b[_],!0}});function l(b,_){si(()=>{for(let S in b)S!=="__proto__"&&(c[S]=b[S])});let w=s.__element;return w&&w.onUpdate&&!_?.quiet&&w.onUpdate(w,c,w.context),c}function f(b){return l(b,{quiet:!0})}function u(b){if(b||(b=new Set),b.has(c))return"[Circular]";b.add(c);let _={};for(let w in o){if(w==="parent"||w==="root"||w.startsWith("__")||!Object.prototype.hasOwnProperty.call(s,w))continue;let S=o[w].peek();S&&S[qe]?_[w]=S.$parse(b):_[w]=S}return _}function d(){return si(()=>{for(let b in o)delete c[b]}),c}function g(){return Object.keys(o).filter(i)}function p(){return Object.keys(o).filter(i).map(b=>o[b].peek())}function h(b){return si(()=>{for(let _ in o)_ in b||delete c[_];for(let _ in b)_!=="__proto__"&&(c[_]=b[_])}),c}function m(b,_){let w=Object.prototype.hasOwnProperty.call(o,b)?o[b].peek():s[b];if(Array.isArray(w))return c[b]=[...w,_],c;if(w&&typeof w=="object"&&!Array.isArray(w)){if(gl(_))w[qe]?w.$update(_):c[b]={...w,..._};else{let S=String(Object.keys(w).length);w[qe]?w.$update({[S]:_}):c[b]={...w,[S]:_}}return c}return c[b]=_,c}function y(b){return delete c[b],c}function x(){d(),s.__element=null,s.parent=null}return c}function vT(t){return t&&t[qe]===!0}function CT(t){return t[hl]}function ET(t,e){let r={},n={};if(t&&typeof t=="object")for(let i in t)n[i]=t[i],r[i]=We(t[i]);let o=i=>{if(Object.prototype.hasOwnProperty.call(r,i))return r;let a=e;for(;a;){let c=a[hl];if(c&&Object.prototype.hasOwnProperty.call(c,i))return c;a=a[qe]?a[wp]:null}return null};return new Proxy(n,{get(i,a){return a===qe?!0:a===hl?r:a===wp?e:a==="__raw"?i:Object.prototype.hasOwnProperty.call(r,a)?r[a].get():e&&a!=="then"&&a!=="constructor"?e[a]:i[a]},set(i,a,c){let l=o(a);return l?(l===r&&(i[a]=c),l[a].set(c),!0):(i[a]=c,r[a]=We(c),!0)},has(i,a){if(a in r||a in i)return!0;let c=e;for(;c;){if(a in c)return!0;c=c[qe]?c[wp]:null}return!1},ownKeys(){return Object.keys(r)},getOwnPropertyDescriptor(i,a){return a in r?{enumerable:!0,configurable:!0,value:r[a].peek()}:Object.getOwnPropertyDescriptor(i,a)}})}var wp=Symbol("scope.parent");var yn="3.14.785";var bo="__SMBLS_SIGNAL_INSTANCES__",_o=(t,e,r)=>{let n=e||(typeof globalThis<"u"?globalThis:null);if(!n)return null;let o=n[bo]||(n[bo]={versions:[],engines:0,reported:!1});return typeof o.engines!="number"&&(o.engines=o.versions.length),o.versions.push(t||yn),r||o.engines++,o.engines>1&&!o.reported&&(o.reported=!0,console.error("[smbls] duplicate @symbo.ls/signal instance \u2014",o.engines,"copies of the reactive engine are loaded on this page:",o.versions.join(", ")+".","Each copy keeps its own observer and effect queue, so an effect created","by one copy never re-fires from another copy's store writes, and one","copy's cascade breaker cannot see the other's queue.","Copies of the SAME version adopt a single engine automatically, so","this means the versions above DIFFER: a fossil copy is resolving beside","the current one. That is a dependency-graph fault, not an application","bug \u2014 align the version wherever @symbo.ls/signal is imported, then","regenerate the lockfile so exactly one version resolves.")),o},Ep=t=>{let e=t||(typeof globalThis<"u"?globalThis:null);e&&delete e[bo]};var xo="__SMBLS_SIGNAL_ENGINE__",zx=(t,e,r)=>{let n=e||yn,o=r||(typeof globalThis<"u"?globalThis:null);if(!o)return t;let s=o[xo];return s&&s.engine&&s.version===n?(_o(n,o,!0),s.engine):(s||(o[xo]={version:n,engine:t}),_o(n,o,!1),t)},Ap=t=>{let e=t||(typeof globalThis<"u"?globalThis:null);e&&delete e[xo]};var Ht=zx({...bp,...Cp,VERSION:yn},yn),ai=Ht.createSignal,Hx=Ht.createComputed,Y=Ht.createEffect,yl=Ht.batch,lr=Ht.getObserver,Ke=Ht.setObserver,fr=Ht.createStore,bl=Ht.createScopeStore,kt=Ht.isStore,Wx=Ht.getSignals,qx=Ht.STORE_METHOD_NAMES,Kx=Ht.RESERVED_STORE_METHODS,_l=Ht.warnStateKeyShadowsMethod,Gx=Ht.__resetStateShadowWarnings,Yx=Ht.VERSION;var ky={};$(ky,{assertEmitIntegrity:()=>xy,css:()=>he,getActiveDocument:()=>Jn,getCacheSize:()=>Sy,getEmitStats:()=>du,injectGlobal:()=>xt,keyframes:()=>us,reset:()=>v0,resetEmitStats:()=>_y,setActiveDocument:()=>by,setWasmEngine:()=>cc,wrapHoverRule:()=>Sr});var dy={};$(dy,{COMPOUND_CSS_KEYWORDS:()=>Nn,CONFIG:()=>Un,CONFIG_MERGE_EXL:()=>ue,CSS_NAMED_COLOR_HEX:()=>Ef,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_UNITS:()=>So,FACTORY:()=>fe,STANDARD_SCHEME_QUERIES:()=>Yf,VALUE_TRANSFORMERS:()=>su,__resetSkinWarnings:()=>cy,activateConfig:()=>OS,aliasCaseVariants:()=>es,animation:()=>Mm,appendSVGSprite:()=>ec,appendSvgIconsSprite:()=>Gn,applyDocument:()=>tc,applyHeadings:()=>Jf,applyMediaSequenceVars:()=>qr,applyReset:()=>rc,applySequenceGlobalVars:()=>ja,applySequenceVars:()=>xr,applySkins:()=>nc,applySpacingSequence:()=>za,applyTimingSequence:()=>Qa,applyTypographySequence:()=>Xa,breakpoints:()=>Im,buildSkinVarStyles:()=>Yn,changeGlobalTheme:()=>iu,changeLightness:()=>ym,checkIfBoxSize:()=>Ua,class:()=>Vm,color:()=>Am,colorStringToRgbaArray:()=>Se,compositeOverBackdrop:()=>jn,contrastRatio:()=>Yo,convertSvgToSymbol:()=>Va,createConfig:()=>Da,cssMediaVars:()=>Hf,cssVars:()=>zf,defineResolvedThemeSignal:()=>ts,defineThemeSignal:()=>Qo,devices:()=>$m,document:()=>CS,findHeadingLetter:()=>Kf,findHeadings:()=>Na,font:()=>wm,fontFace:()=>vm,fontFamily:()=>Sm,fontFamilyTypes:()=>km,generateSequence:()=>te,generateSequencePosition:()=>Gm,generateSprite:()=>Ba,generateSubSequence:()=>Ma,getActiveConfig:()=>A,getColor:()=>ot,getColorShade:()=>Pf,getDefaultOrFirstKey:()=>Bn,getFnPrefixAndValue:()=>_r,getFontFace:()=>_m,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>jf,getFontFaceString:()=>Ta,getFontFamily:()=>Ya,getFontFormat:()=>Ff,getFontSizeByKey:()=>Za,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getResolvedThemeSignal:()=>TS,getRgbTone:()=>tr,getSafeInk:()=>Xf,getSafeInkInfo:()=>Jm,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>Fa,getSequenceValuePropertyPair:()=>rr,getShadow:()=>Wa,getShapeByKey:()=>Ja,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getSubratio:()=>$a,getSubratioDifference:()=>Ia,getTheme:()=>ry,getThemeSignal:()=>AS,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,gradient:()=>Tm,grid:()=>Bm,hexToRgb:()=>pm,hexToRgbArray:()=>Af,hexToRgba:()=>gm,hslToRgb:()=>Rf,icons:()=>Pm,isCSSVar:()=>_t,isDomDocument:()=>ur,isGoogleFontsUrl:()=>Xo,isHostObject:()=>dr,isPlainColor:()=>Yr,isRawUnitValue:()=>ci,isResolvedColor:()=>Fe,isScalingUnit:()=>bn,isWritableFamilyBucket:()=>Op,linearChannelToSrgb:()=>If,media:()=>Cm,mixTwoColors:()=>dm,mixTwoRgb:()=>mm,mixTwoRgba:()=>Df,numToLetterMap:()=>er,oklabToLinearSrgb:()=>$f,oklabToOklch:()=>Ca,oklchToGamutSafeSrgb:()=>Ea,oklchToOklab:()=>Mf,opacify:()=>Go,parkHostObject:()=>Ir,parseColorToken:()=>Ut,popConfig:()=>it,pushConfig:()=>ct,quietColorProbe:()=>Hn,relativeLuminance:()=>Fn,reset:()=>ES,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveColorsInGradient:()=>sc,resolveConfigDocument:()=>wo,resolveFileUrl:()=>ke,resolveShadowValue:()=>qn,returnSubThemeOrDefault:()=>bm,rgbArrayToHex:()=>Tf,rgbToHSL:()=>Of,rgbToHex:()=>hm,runThroughMedia:()=>Zf,schemeGuardSelector:()=>Zr,schemeMediaQuery:()=>Xr,scratchDefaultConfig:()=>Jo,scratchSystem:()=>is,scratchUtils:()=>Kr,semanticIcons:()=>Dm,sequence:()=>br,set:()=>Xn,setActiveConfig:()=>Wf,setAdaptiveSchemeVar:()=>Jr,setColor:()=>Gr,setCustomFont:()=>Aa,setCustomFontMedia:()=>Wr,setEach:()=>uy,setFont:()=>Ga,setFontFamily:()=>os,setFontImport:()=>Zo,setGradient:()=>rs,setInCustomFontMedia:()=>Nf,setMediaTheme:()=>ns,setSVG:()=>ss,setScalingVar:()=>La,setShadow:()=>Qr,setSubScalingVar:()=>qf,setSvgIcon:()=>Kn,setTheme:()=>Ka,setValue:()=>fy,setVariables:()=>Ym,shadow:()=>Rm,shape:()=>Hm,sizes:()=>zm,skins:()=>Wm,spacing:()=>Em,splitSpacedValue:()=>Ha,splitTopLevelCommas:()=>yr,splitTopLevelSpaces:()=>pt,splitTransition:()=>ou,srgbChannelToLinear:()=>Lf,srgbToOklab:()=>va,svg:()=>Fm,svgData:()=>Nm,templates:()=>jm,theme:()=>Om,timing:()=>Lm,toCamel:()=>Pa,toLinearChannel:()=>Ko,transformBackgroundImage:()=>eu,transformBorder:()=>nr,transformBorderRadius:()=>wr,transformBoxShadow:()=>oc,transformDuration:()=>ic,transformGridTemplate:()=>nu,transformShadow:()=>tu,transformSize:()=>vt,transformSizeRatio:()=>I,transformTextStroke:()=>Qf,transformTransition:()=>ly,transfromGap:()=>ru,typography:()=>Oa,unit:()=>xm,vars:()=>Um});var Kr={};$(Kr,{COMPOUND_CSS_KEYWORDS:()=>Nn,CSS_NAMED_COLOR_HEX:()=>Ef,CSS_NATIVE_COLOR_REGEX:()=>le,CSS_UNITS:()=>So,applyMediaSequenceVars:()=>qr,applySequenceGlobalVars:()=>ja,applySequenceVars:()=>xr,changeLightness:()=>ym,colorStringToRgbaArray:()=>Se,compositeOverBackdrop:()=>jn,contrastRatio:()=>Yo,convertSvgToSymbol:()=>Va,findHeadingLetter:()=>Kf,findHeadings:()=>Na,generateSequence:()=>te,generateSequencePosition:()=>Gm,generateSprite:()=>Ba,generateSubSequence:()=>Ma,getColorShade:()=>Pf,getDefaultOrFirstKey:()=>Bn,getFnPrefixAndValue:()=>_r,getFontFace:()=>_m,getFontFaceEach:()=>Vn,getFontFaceEachString:()=>jf,getFontFaceString:()=>Ta,getFontFormat:()=>Ff,getRgbTone:()=>tr,getSequenceValue:()=>zn,getSequenceValueBySymbols:()=>Fa,getSequenceValuePropertyPair:()=>rr,getSubratio:()=>$a,getSubratioDifference:()=>Ia,hexToRgb:()=>pm,hexToRgbArray:()=>Af,hexToRgba:()=>gm,hslToRgb:()=>Rf,isCSSVar:()=>_t,isDomDocument:()=>ur,isGoogleFontsUrl:()=>Xo,isHostObject:()=>dr,isRawUnitValue:()=>ci,isResolvedColor:()=>Fe,isScalingUnit:()=>bn,isWritableFamilyBucket:()=>Op,linearChannelToSrgb:()=>If,mixTwoColors:()=>dm,mixTwoRgb:()=>mm,mixTwoRgba:()=>Df,numToLetterMap:()=>er,oklabToLinearSrgb:()=>$f,oklabToOklch:()=>Ca,oklchToGamutSafeSrgb:()=>Ea,oklchToOklab:()=>Mf,opacify:()=>Go,parkHostObject:()=>Ir,parseColorToken:()=>Ut,relativeLuminance:()=>Fn,resolveConfigDocument:()=>wo,resolveFileUrl:()=>ke,returnSubThemeOrDefault:()=>bm,rgbArrayToHex:()=>Tf,rgbToHSL:()=>Of,rgbToHex:()=>hm,setCustomFont:()=>Aa,setCustomFontMedia:()=>Wr,setFontImport:()=>Zo,setInCustomFontMedia:()=>Nf,setScalingVar:()=>La,setSubScalingVar:()=>qf,setVariables:()=>Ym,splitTopLevelCommas:()=>yr,splitTopLevelSpaces:()=>pt,srgbChannelToLinear:()=>Lf,srgbToOklab:()=>va,toLinearChannel:()=>Ko});var ur=t=>!!(t&&t.documentElement&&typeof t.createElement=="function"&&t.head!==void 0),dr=t=>{if(t===null||typeof t!="object")return!1;let e=Object.prototype.toString.call(t);return!!(e!=="[object Object]"&&e!=="[object Array]"||typeof t.nodeType=="number"||t.defaultView||t.window===t||t.self===t)},Op=t=>t!==null&&typeof t=="object"&&!dr(t),Ir=(t,e,r)=>{if(!t)return;if(ur(r)){t.__domDocument||(t.__domDocument=r);return}let n=`__host_${e}`;t[n]||(t[n]=r)},wo=t=>t?ur(t.__domDocument)?t.__domDocument:ur(t.document)?t.document:null:null;var bn=t=>t==="em"||t==="rem"||t==="vw"||t==="vh"||t==="vmax"||t==="vmin",So=["px","cm","mm","in","pt","pc","em","rem","ex","cap","ch","ic","lh","rlh","%","vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh","cqw","cqh","cqi","cqb","cqmin","cqmax","deg","rad","grad","turn","s","ms","dpi","dpcm","dppx","fr","auto"],AT=t=>t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),TT=new RegExp(`^-?(?:\\d+\\.?\\d*|\\.\\d+)(?:${So.filter(t=>t!=="auto").map(AT).join("|")})$`),ci=t=>TT.test(String(t).trim());D();var Ef={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},Se=t=>{if(t==="")return[0,0,0,0];if(t.toLowerCase()==="transparent")return[0,0,0,0];let e=Ef[t.toLowerCase()];if(e&&(t=e),t[0]==="#")return t.length<7&&(t="#"+t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+(t.length>4?t[4]+t[4]:"")),[parseInt(t.substr(1,2),16),parseInt(t.substr(3,2),16),parseInt(t.substr(5,2),16),t.length>7?parseInt(t.substr(7,2),16)/255:1];if(t.indexOf("rgb")===-1&&st&&C){let r=st.body.appendChild(st.createElement("fictum")),n="rgb(1, 2, 3)";if(r.style.color=n,r.style.color!==n){st.body.removeChild(r);return}if(r.style.color=t,r.style.color===n||r.style.color==="")return st.body.removeChild(r),[0,0,0,0];t=C.getComputedStyle(r).color,st.body.removeChild(r)}return t.indexOf("rgb")===0?(t.indexOf("rgba")===-1&&(t=`${t}, 1`),t.match(/[\.\d]+/g).map(r=>+r)):[0,0,0,0]},dm=(t,e,r=.5)=>(t=Se(t),e=Se(e),Df(t,e,r)),pm=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return`rgb(${r},${n},${o})`},Af=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return[r,n,o]},hm=(t,e,r)=>"#"+(1<<24|t<<16|e<<8|r).toString(16).slice(1),Tf=([t,e,r])=>((1<<24)+(t<<16)+(e<<8)+r).toString(16).slice(1),gm=(t,e=1)=>{let[r,n,o]=t.match(/\w\w/g).map(s=>parseInt(s,16));return`rgba(${r},${n},${o},${e})`},mm=(t,e,r=.5)=>{let n=[];for(let o=0;o<3;o++)n[o]=~~(t[o]+(e[o]-t[o])*r);return`rgb(${n})`},ym=(t,e)=>{let[r,n,o]=e,s=Math.max(0,Math.min(100,o+parseFloat(t)));return[r,n,s]},Of=(t,e,r)=>{let n=Math.max(t,e,r),o=n-Math.min(t,e,r),s=1-Math.abs(n+n-o-1),i=o&&(n==t?(e-r)/o:n==e?2+(r-t)/o:4+(t-e)/o);return[60*(i<0?i+6:i),s?o/s:0,(n+n-o)/2]},Rf=(t,e,r,n=e*Math.min(r,1-r),o=(s,i=(s+t/30)%12)=>r-n*Math.max(Math.min(i-3,9-i,1),-1))=>[o(0),o(8),o(4)],Pf=(t,e)=>{let r=parseInt(t,16),n=(r>>16)+e;n>255?n=255:n<0&&(n=0);let o=(r>>8&255)+e;o>255?o=255:o<0&&(o=0);let s=(r&255)+e;return s>255?s=255:s<0&&(s=0),((s|o<<8|n<<16)+16777216).toString(16).slice(1)},Df=(t,e,r=.5)=>{let n=[];for(let o=0;o<4;o++){let s=o===3?i=>i:Math.round;n[o]=s(t[o]+(e[o]-t[o])*r)}return`rgba(${n})`},Go=(t,e)=>{let r=Se(t);if(!r){An()&&console.warn(t+" color is not rgba");return}return r[3]=e,`rgba(${r})`},_t=t=>t.charCodeAt(0)===45&&t.charCodeAt(1)===45,Nn=new Set(["currentcolor","transparent","thin","medium","thick"]),le=/(?:rgba?\(|hsla?\(|#[0-9a-fA-F]{3,8}\b)/,fR=/^([a-zA-Z]\w*(?:-[a-zA-Z]\w*)*)(?:\.(\d+))?(?:([+-]\d+|=\d+))?$/,Ut=t=>{if(!k(t))return null;if(le.test(t))return{passthrough:t};if(_t(t))return{cssVar:t};let e=t.match(fR);if(!e)return null;let[,r,n,o]=e,s=n!==void 0?`0.${n}`:void 0,i=o&&o[0]==="="?o.slice(1):o;return{name:r,alpha:s,tone:i}},Fe=t=>k(t)&&(t.includes("rgb")||t.includes("var(")||t.includes("#")),yr=t=>{let e=[],r="",n=0;for(let o of t){if(o==="("?n+=1:o===")"&&n>0&&(n-=1),o===","&&n===0){e.push(r),r="";continue}r+=o}return(r.length||!e.length)&&e.push(r),e},pt=t=>{let e=[],r="",n=0;for(let o of t){if(o==="("?n+=1:o===")"&&n>0&&(n-=1),n===0&&/\s/.test(o)){r.length&&e.push(r),r="";continue}r+=o}return r.length&&e.push(r),e},Ko=t=>(t/=255,t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)),Fn=t=>.2126*Ko(t[0])+.7152*Ko(t[1])+.0722*Ko(t[2]),Yo=(t,e)=>{let r=Fn(t)+.05,n=Fn(e)+.05;return r>n?r/n:n/r},Lf=t=>(t/=255,t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)),If=t=>(t<=.0031308?t*12.92:1.055*Math.pow(t,1/2.4)-.055)*255,va=([t,e,r])=>{let[n,o,s]=[t,e,r].map(Lf),i=.4122214708*n+.5363325363*o+.0514459929*s,a=.2119034982*n+.6806995451*o+.1073969566*s,c=.0883024619*n+.2817188376*o+.6299787005*s,l=Math.cbrt(i),f=Math.cbrt(a),u=Math.cbrt(c);return[.2104542553*l+.793617785*f-.0040720468*u,1.9779984951*l-2.428592205*f+.4505937099*u,.0259040371*l+.7827717662*f-.808675766*u]},$f=([t,e,r])=>{let n=t+.3963377774*e+.2158037573*r,o=t-.1055613458*e-.0638541728*r,s=t-.0894841775*e-1.291485548*r,i=n**3,a=o**3,c=s**3;return[4.0767416621*i-3.3077115913*a+.2309699292*c,-1.2684380046*i+2.6097574011*a-.3413193965*c,-.0041960863*i-.7034186147*a+1.707614701*c]},Ca=([t,e,r])=>{let n=Math.atan2(r,e)*180/Math.PI;return n<0&&(n+=360),[t,Math.sqrt(e*e+r*r),n]},Mf=([t,e,r])=>{let n=r*Math.PI/180;return[t,e*Math.cos(n),e*Math.sin(n)]},Ea=(t,e,r,n=24)=>{let o=a=>$f(Mf([t,a,r])),s=a=>a.every(c=>c>=-1e-4&&c<=1.0001),i=o(e);if(!s(i)){let a=0,c=e;for(let l=0;l<n;l++){let f=(a+c)/2;s(o(f))?a=f:c=f}i=o(a)}return i.map(a=>If(Math.max(0,Math.min(1,a))))},jn=(t,e=1,r=[255,255,255])=>e>=1?t:t.map((n,o)=>n*e+r[o]*(1-e)),tr=(t,e)=>{k(t)&&t.includes("rgb")&&(t=Se(t).join(", ")),k(t)&&(t=t.split(",").map(o=>parseFloat(o.trim()))),Ge(e)&&(e+="");let r=Tf(t),n=e.slice(0,1);if(n==="-"||n==="+"){let o=Pf(r,parseFloat(e));return Af(o).join(", ")}else{let[o,s,i]=t,[a,c]=Of(o/255,s/255,i/255),l=Math.max(0,Math.min(100,parseFloat(e)))/100;return Rf(a,c,l).map(u=>Math.round(Math.max(0,Math.min(1,u))*255)).join(", ")}};var bm=(t,e)=>{if(t)return t.themes&&t.themes[e]?t.themes[e]:t[e]?[t,t[e]]:t};var ke=(t,e)=>{if(!t||!e)return null;try{return new URL(t),null}catch{}let r=e[t];return r?r.content&&r.content.src:null},Bn=(t,e)=>{if(t[e])return t[e].value;let r=()=>Object.keys(t).find(o=>o!=="default"&&t[o]&&t[o].value&&!t[o].isSystemFallback);if(t.default){let o=t[t.default];if(o&&o.isSystemFallback){let s=r();if(s)return t[s].value}if(o)return o.value}let n=r()||Object.keys(t).find(o=>o!=="default"&&t[o]&&t[o].value);return n&&t[n]&&t[n].value},Ff=t=>{if(typeof t!="string"||!t)return null;let e=t.split(/[#?]/)[0].split(".").pop().trim();return["woff2","woff","ttf","otf","eot"].includes(e)?e:null},Xo=t=>t&&(t.includes("fonts.googleapis.com")||t.includes("fonts.gstatic.com")),Zo=t=>`@import url('${t}');`,Nf=t=>`@font-face { ${t} }`,Aa=(t,e,r,n={})=>{let i=(Array.isArray(e)?e:[e]).filter(a=>typeof a=="string"&&a).map(a=>{let c=Ff(a),l=c?` format('${c}')`:"";return`url('${a}')${l}`}).join(`,
34
34
  `);return`
35
35
  font-family: '${t}';
36
36
  font-style: ${n.fontStyle||"normal"};${r?`
@@ -38,24 +38,24 @@ FROM ${a}${l}`},RO=t=>{let e=[],r=(n,o)=>{for(let s in n){let i=o?`${o}/${s}`:s;
38
38
  font-stretch: ${n.fontStretch};`:""}${n.fontDisplay?`
39
39
  font-display: ${n.fontDisplay};`:""}${n.unicodeRange?`
40
40
  unicode-range: ${n.unicodeRange};`:""}
41
- src: ${i};`},qr=(t,e,r,n)=>`@font-face {${Ca(t,e,r,n)}
42
- }`,Vn=(t,e,r)=>Object.keys(e).map(o=>{let{url:s,fontWeight:i,fontStyle:a,fontDisplay:c,fontStretch:l,unicodeRange:f}=e[o],u=Array.isArray(s)?s.map(d=>ke(d,r)||d):ke(s,r)||s;return Ca(t,u,i,{fontStyle:a,fontDisplay:c,fontStretch:l,unicodeRange:f})}),hm=t=>Object.keys(t).map(r=>Vn(r,t[r].value)),Ff=(t,e,r)=>{if(e&&e.isVariable){let s=ke(e.url,r)||e.url;return Yo(s)?Xo(s):qr(t,s,e.fontWeight,{fontStretch:e.fontStretch,fontDisplay:e.fontDisplay||"swap",unicodeRange:e.unicodeRange})}if(e[0])return Vn(t,e,r).map(Mf);let o=Array.isArray(e.url)?e.url.map(s=>ke(s,r)||s):ke(e.url,r)||e.url;return qr(t,o,e.fontWeight,{fontStyle:e.fontStyle,fontDisplay:e.fontDisplay,fontStretch:e.fontStretch,unicodeRange:e.unicodeRange})},Ea=(t,e)=>Object.keys(t).map(n=>Ff(n,t[n].value,e));D();D();D();D();var Zo={};$(Zo,{animation:()=>Pm,breakpoints:()=>Om,class:()=>Mm,color:()=>Sm,devices:()=>Rm,document:()=>mS,font:()=>mm,fontFace:()=>_m,fontFamily:()=>ym,fontFamilyTypes:()=>bm,gradient:()=>km,grid:()=>$m,icons:()=>Em,media:()=>wm,reset:()=>yS,semanticIcons:()=>Am,sequence:()=>yr,shadow:()=>Cm,shape:()=>jm,sizes:()=>Nm,skins:()=>Bm,spacing:()=>xm,svg:()=>Dm,svgData:()=>Lm,templates:()=>Im,theme:()=>vm,timing:()=>Tm,typography:()=>Aa,unit:()=>gm,vars:()=>Fm});var yr={"minor-second":1.067,"major-second":1.125,"minor-third":1.2,"major-third":1.25,"perfect-fourth":1.333,"augmented-fourth":1.414,"perfect-fifth":1.5,"minor-sixth":1.6,phi:1.618,"major-sixth":1.667,"square-root-3":1.732,"minor-seventh":1.778,"major-seventh":1.875,octave:2,"square-root-5":2.23,"major-tenth":2.5,"major-eleventh":2.667,"major-twelfth":3,pi:3.14,"double-octave":4};var gm={default:"em"};var QO={browserDefault:16,base:16,type:"font-size",ratio:yr["minor-third"],range:[-3,12],h1Matches:6,lineHeight:1.5,subSequence:!0,mediaRegenerate:!1,unit:"em",templates:{},sequence:{},scales:{},vars:{}},Aa=QO;var mm={};var ym={},bm={"sans-serif":"Helvetica, Arial, sans-serif, --system-default",serif:"Times New Roman, Georgia, serif, --system-default",monospace:"Courier New, monospace, --system-default"},_m={};var wm={tv:"(min-width: 2780px)",light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)",print:"print"};var tR={base:Aa.base,type:"spacing",ratio:yr.phi,range:[-5,15],subSequence:!0,mediaRegenerate:!1,unit:"em",sequence:{},scales:{},vars:{}},xm=tR;var Sm={},km={};var vm={};var Cm={};var Em={},Am={};var eR={default:150,base:150,type:"timing",ratio:yr["perfect-fourth"],range:[-3,12],mediaRegenerate:!1,unit:"ms",sequence:{},scales:{},vars:{}},Tm=eR;var mS={};var Om={screenL:1920,screenM:1680,screenS:1440,tabletL:1366,tabletM:1280,tabletS:1024,mobileL:768,mobileM:560,mobileS:480,mobileXS:375},Rm={screenXXL:[2560,1440],screenXL:[2240,1260],screenL:[1920,1024],screenM:[1680,1024],screenS:[1440,720],tabletL:[1366,926],tabletM:[1280,768],tabletS:[1024,768],mobileL:[768,375],mobileM:[560,768],mobileS:[480,768],mobileXS:[375,768]};var Pm={};var Dm={},Lm={};var Im={};var rR={},$m=rR;var Mm={};var yS={},Fm={},Nm={},jm={},Bm={};var Vf={},Uf={},ue=new Set,Nf=Zo,jf={},Oa=t=>t.replace(/_([a-z])/g,(e,r)=>r.toUpperCase());for(let t in Nf){let e=t.toLowerCase();jf[e]=Nf[t];let r=Oa(e);r!==e&&(jf[r]=Nf[t]),e!==t&&(jf[t]=Nf[t])}var Un={verbose:!1,useVariable:!0,useReset:!0,globalTheme:"auto",cssVars:Vf,cssMediaVars:Uf,CSS_VARS:Vf,CSS_MEDIA_VARS:Uf,cssSkinVars:{},cssSkinFallback:{},_scratchConfig:!0,...jf},Jo=(t,e)=>{if(!t)return null;if(t.__globalThemeSignal)return Tt(e)&&t.__globalThemeSignal.set(e),t.__globalThemeSignal;let r=Tt(e)?e:t.globalTheme,n=si(Tt(r)?r:"auto");return Object.defineProperty(t,"globalTheme",{get(){return n.get()},set(o){n.set(o)},enumerable:!0,configurable:!0}),Object.defineProperty(t,"__globalThemeSignal",{value:n,enumerable:!1,configurable:!0,writable:!0}),n},bS=t=>t?Jo(t):null,Qo=(t,e)=>{if(!t)return null;if(t.__resolvedThemeSignal)return Tt(e)&&t.__resolvedThemeSignal.set(e),t.__resolvedThemeSignal;let r=Tt(e)?e:t.resolvedTheme,n=si(Tt(r)?r:null);return Object.defineProperty(t,"resolvedTheme",{get(){return n.get()},set(o){n.set(o)},enumerable:!1,configurable:!0}),Object.defineProperty(t,"__resolvedThemeSignal",{value:n,enumerable:!1,configurable:!0,writable:!0}),n},_S=t=>t?Qo(t):null;Jo(Un);Qo(Un);var Bf=lt(Un),fe={active:"0",0:Un},wS=t=>(Tt(t)&&(fe.active=t),fe[t||fe.active]),Ta=[],ct=t=>{t&&t._scratchConfig&&Ta.push(t)},it=()=>{Ta.pop()},A=t=>Ta.length?Ta[Ta.length-1]:fe[t||fe.active]||Un,zf=t=>{if(v(t))return fe.active="1",fe[1]=at(t,lt(Bf),ue),ts(fe[1]),Jo(fe[1]),Qo(fe[1]),t},nR=["useReset","useFontImport","useIconSprite","useSvgSprite","useDocumentTheme","useDefaultIcons","useDefaultConfig"],oR=["useVariable","globalTheme","verbose"],sR=[["fontfamily","fontFamily","font_family"],["fontfamilytypes","fontFamilyTypes"],["semanticicons","semanticIcons"],["svgdata","svgData"]],ts=t=>{for(let e of sR){let r;for(let n of e){let o=t[n];v(o)&&(r=r?at(r,o,ue):o)}if(r)for(let n of e)v(t[n])&&(t[n]=r)}},Ra=(t,e,{cleanBase:r=!1}={})=>{let n=r?null:A(),o=lt(!r&&n&&n._scratchConfig?n:Bf);for(let i of nR)delete o[i];for(let i of oR)Object.prototype.hasOwnProperty.call(Bf,i)?o[i]=Bf[i]:delete o[i];let s=at(e||{},o,ue);return s.cssVars={},s.cssMediaVars={},s.CSS_VARS=s.cssVars,s.CSS_MEDIA_VARS=s.cssMediaVars,s.cssSkinVars={},s.cssSkinFallback={},s._scratchConfig=!0,ts(s),Jo(s),Qo(s),t&&(fe[t]=s),s};var er={"-6":"U","-5":"V","-4":"W","-3":"X","-2":"Y","-1":"Z",0:"A",1:"B",2:"C",3:"D",4:"E",5:"F",6:"G",7:"H",8:"I",9:"J",10:"K",11:"L",12:"M",13:"N",14:"O",15:"P",16:"Q",17:"R",18:"S",19:"T"},Um=(t,e)=>{let{key:r,variable:n,value:o,scaling:s,index:i,scalingVariable:a}=t;e.sequence[r]={key:r,decimal:~~(o*100)/100,val:~~o,scaling:s,index:i,scalingVariable:a,variable:n},e.scales[r]=s;let c=xS.has(e.unit)?"rem":e.unit;e.vars[n]=s+c},br=t=>{if(!t.includes("("))return t;let e=t.trim(),r=e.indexOf("("),n=e.slice(0,r),o=0,s=-1;for(let i=r;i<e.length;i++){let a=e[i];if(a==="(")o++;else if(a===")"&&(o--,o===0)){s=i;break}}return s===-1||/\s/.test(n)||e.slice(s+1).trim()!==""?[void 0,t]:[n,e.slice(r+1,s)]},Vm="\0",iR=(t,e)=>{let r="",n=0,o="";for(let s of t){if(n===0&&s!=="("){r+=s;continue}o+=s,s==="("?n++:s===")"&&(n--,n===0&&(r+=Vm+e.length+Vm,e.push(o),o=""))}return r+o},aR=(t,e)=>t.indexOf(Vm)===-1?t:t.replace(/\u0000(\d+)\u0000/g,(r,n)=>e[Number(n)]),cR=/^(calc|min|max|clamp)\((.*)\)$/,lR=(t,e)=>{let r=cR.exec(t);return r?`${r[1]}(${$a(r[2],e)})`:t.indexOf("(")!==-1?t:zn(t,e)},xS=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),Pa=(t,e)=>{let{base:r,type:n,unit:o}=e,s=xS.has(o)?"rem":o,i=(wn(s)?1:r)+s;if(t===0)return i;let c="--"+(e.varPrefix?e.varPrefix+"-":"")+(n&&n.replace(".","-")),l=`${c}-ratio`;if(t>0){let f=er[t-1];return`calc(var(${c}-${f}) * var(${l}))`}if(t<0){let f=er[t+1],u=Math.abs(t),d=Math.pow(SS,2*u),g=er[u];return g?`max(calc(var(${c}-${f}) / var(${l})), calc(var(${c}-${g}) / ${d.toFixed(4)}))`:`calc(var(${c}-${f}) / var(${l}))`}},Hf=(t,e,r,n)=>{let{type:o}=n,i=t===2&&e.length===2?t+1:t,l=`${"--"+(n.varPrefix?n.varPrefix+"-":"")+(o&&o.replace(".","-"))}-sub-ratio-`;return`calc(var(${r}) * var(${l+i}))`},Da=(t,e)=>{let n=(t*e-t)/1.618,o=t*e-n,s=t+n,i=(o+s)/2;return[o,i,s]},La=(t,e)=>Da(t,e).map(r=>r/t),Ia=(t,e)=>{let{key:r,base:n,value:o,ratio:s,variable:i,index:a}=t,l=~~(o*s)-~~o,f,[u,d,g]=Da(o,s);l>16?f=[u,d,g]:f=[u,g],f.forEach((p,h)=>{let m=~~(p/n*1e3)/1e3,_=i+(h+1),x=a+(h+1)/10,y=Hf(h+1,f,i,e),b={key:r+(h+1),variable:_,value:p,scaling:m,scalingVariable:y,index:x};Um(b,e)})},SS=1.618,fR=(t,e,r)=>{if(t>=0)return e*Math.pow(r,t);let n=Math.abs(t),o=e*Math.pow(r,t),s=e*Math.pow(r,n)/Math.pow(SS,2*n);return Math.max(o,s)},te=t=>{let{type:e,base:r,ratio:n,range:o,subSequence:s}=t,i=Math.abs(o[0])+Math.abs(o[1]),c="--"+(t.varPrefix?t.varPrefix+"-":"")+(e&&e.replace(".","-"))+"-";for(let l=0;l<=i;l++){let f=o[1]-l,u=er[f],d=fR(f,r,n),g=~~(d/r*100)/100,p=c+u,h=Pa(f,t),m={key:u,variable:p,value:d,base:r,scaling:g,scalingVariable:h,ratio:n,index:f};Um(m,t),s&&Ia(m,t)}return t},zm=(t,e=0)=>{let{type:r,base:n,ratio:o,subSequence:s}=t,i=k(e)?e:er[e],a=k(e)?Object.entries(er).find(([,m])=>m===e)?.[0]:e;if(!i)return console.warn(`Position ${e} is out of range in numToLetterMap`),null;let c={sequence:{},scales:{},vars:{},...t},l=n*Math.pow(o,a),f=~~(l/n*100)/100,g="--"+(t.varPrefix?t.varPrefix+"-":"")+(r&&r.replace(".","-"))+"-"+i,p=Pa(a,t),h={key:i,variable:g,value:l,base:n,scaling:f,scalingVariable:p,ratio:o,index:a};return Um(h,c),s&&Ia(h,c),c},zn=(t="A",e)=>{let r=A(),{unit:n}=r;if(k(t)&&_t(t))return`var(${t})`;if(k(t)&&/^(?:env|var|calc|min|max|clamp)\(/.test(t.trim()))return t;if(k(t)){let y=r.sizes;if(y){let b=y[t]||y[t.toLowerCase()];if(b!==void 0)return t.slice(0,1)==="-"?`calc(${b} * -1)`:b}}let{sequence:o,unit:s=n.default,useVariable:i}=e,a=/^-?[a-zA-Z]/i,c=a.test(t);if(ii(t)||!c||["none","auto","max-content","min-content","fit-content","inherit","initial","unset","revert","revert-layer"].includes(t))return t;let d=`--${e.varPrefix?e.varPrefix+"-":""}${_a(e.type.replace(".","-"))}-`,g=t.toUpperCase(),p=g.slice(0,1)==="-"?"-":"",h=p?g.slice(1):g,m="";h.includes("_")&&(m="_"+h.split("_")[1].toLowerCase(),h=h.split("_")[0]);let _=y=>a.test(y)?`var(${d}${y}${m})`:y;if(h.includes("+")){let[y,b]=h.split("+"),w=`${_(y)} + ${_(b)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}else if(h.includes("*")){let[y,b]=h.split("*"),w=`${_(y)} * ${_(b)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}else if(h.includes("-")){let[y,b]=h.split("-"),w=`${_(y)} - ${_(b)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}if(!o[h]&&h.length===2&&(r.verbose&&console.warn(h,"- value is not found because `subSequence` is set to false"),h=h.slice(0,1)),i||r.useVariable){let y=`var(${d}${h}${m})`;return p?`calc(${y} * -1)`:y}let x=o?o[h]:null;if(!x){if(console.warn("can't find",o,h),gt())throw new Error(`[smbls] Unresolvable design-system token "${t}"`+(e.type?` for sequence "${e.type}"`:"")+" \u2014 not a registered `sizes` name and not a valid spacing/typography/timing sequence letter. The CSS property using it would silently be dropped in production. Register the token in `designSystem/sizes.js` (or the relevant sequence family) or fix the typo.");return}return s==="ms"||s==="s"?p+x.val+s:p+x.scaling+s},$a=(t,e)=>{if(!["+","-","*","/",","].filter(i=>t.includes(i+" ")).length)return t;let n=/(\s+-\s+|\s*[+*/,]\s*)/,o=[];return iR(t,o).split(n).map(i=>{let a=aR(i,o),c=a.trim();return!c||["+","-","*","/",","].includes(c)?a:lR(c,e)}).join("")},rr=(t,e,r,n)=>{if(typeof t!="string")return A().verbose&&console.warn(e,t,"is not a string"),{[e]:t};if(t==="-"||t==="")return{};if(!n&&t.includes("(")){if(/^(?:env|var)\(/.test(t.trim()))return{[e]:t};let s=br(t);n=s[0],t=s[1]}return["+","-","*","/",","].filter(s=>t.includes(s+" ")).length?t=$a(t,r):t=zn(t,r),{[e]:n?`${n}(${t})`:t}},Wf=(t,e)=>er[t-e],Ma=t=>{let{h1Matches:e,sequence:r}=t;return new Array(6).fill(null).map((n,o)=>{let s=Wf(e,o);return r[s]})};D();var Hm=(t,e)=>{let r=A(),{cssVars:n}=r;B(t.value)||(n[t.var]=t.value)},Fa=(t,e,r)=>{let n=A(),{unit:o}=n,s=e.unit||o.default,{base:i,ratio:a,type:c}=e,f="--"+(e.varPrefix?e.varPrefix+"-":"")+(c&&c.replace(".","-"));t[`${f}-base`]=i,t[`${f}-unit`]=s;let u=`${f}-ratio`;t[u]=a;let[d,g,p]=La(i,a);t[`${f}-sub-ratio-1`]=`calc(var(${f}-ratio) * ${d/a})`,t[`${f}-sub-ratio-2`]=`calc(var(${f}-ratio) * ${g/a})`,t[`${f}-sub-ratio-3`]=`calc(var(${f}-ratio) * ${p/a})`},kS=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),_r=(t,e={})=>{let r=A(),{unit:n,timing:o,cssVars:s}=r,i=t.unit||n.default,a=kS.has(i)?"rem":i,{mediaRegenerate:c,sequence:l,scales:f}=t;c||Fa(s,t,e);for(let u in l){let d=l[u],g=(t.type===o.type?l[u].val:f[u])+a;if(!c){s[d.variable+"_default"]=g,s[d.variable]=d.scalingVariable;continue}e.useDefault===!1?s[d.variable]=g:(s[d.variable+"_default"]=g,s[d.variable]=`var(${d.variable+"_default"})`)}},Kr=(t,e,r={})=>{let n=A(),{unit:o,media:s,cssVars:i}=n,a=e.slice(1),c=t[e],l=c.unit||t.unit||o.default,f=kS.has(l)?"rem":l,{mediaRegenerate:u}=t,{sequence:d,scales:g}=c,p=s[a];if(!p&&n.verbose&&console.warn("Can't find media query ",p),!u){let h=i[`@media ${p}`];h||(h=i[`@media ${p}`]={}),Fa(h,c,r);let m=t.unit||o.default;if(f!==m&&d)for(let _ in d){let x=d[_],y=g[_]+f;h[x.variable+"_default"]=y,h[x.variable]=y}return}for(let h in d){let m=d[h],_=(wn(f)?g[h]:d[h].val)+f;!p&&n.verbose&&console.warn("Can't find query ",p);let x=i[`@media ${p}`];x||(x=i[`@media ${p}`]={}),x[m.variable]=`var(${m.variable+"_"+a})`,i[m.variable+"_"+a]=_}};D();var CS=On(),Na=t=>{let e=A(),r="";for(let n in t)e.__svgCache[n]||(e.__svgCache[n]=!0,r+=t[n]);return r},uR=t=>{let e=t&&(t.default||t);if(!k(e))return CS&&console.warn("parseRootAttributes:",e,"is not a string"),{};let r=e.match(/<svg\s+(.*?)>/);if(!r||!r[1])return{};let o=r[1].match(/(\S+)=["']?((?:.(?!["']?\s+(?:\S+)=|\s*\/?[>"']))+.)["']?/gm);return o?o.reduce((s,i)=>{let[a,c]=i.split("=");return s[a]=c.replace(/['"]/g,""),s},{}):{}},dR=(t,e)=>{let r=[];if(t.replace(/id="([^"]*)"/g,(o,s)=>(r.push(s),o)),!r.length)return t;let n=t;for(let o of r){let s=o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),i=`${e}-${o}`;n=n.replace(new RegExp(`id="${s}"`,"g"),`id="${i}"`).replace(new RegExp(`url\\(#${s}\\)`,"g"),`url(#${i})`).replace(new RegExp(`xlink:href="#${s}"`,"g"),`xlink:href="#${i}"`).replace(new RegExp(`href="#${s}"`,"g"),`href="#${i}"`)}return n},vS=new Set,ja=(t,e)=>{let r=e&&e.default?e.default:e;if(!k(r))return CS&&!vS.has(t)&&(vS.add(t),console.warn("convertSvgToSymbol:",t,"is not a string")),"";e=r;let n=e.match(/^<symbol\b[^>]*\bid="([^"]*)"/);if(n){let u=n[1];return u===t?e:e.replace(`id="${u}"`,`id="${t}"`)}let o=uR(e),{width:s,height:i}=o,a=o.viewBox||`0 0 ${s||24} ${i||24}`,f=dR(e,t).replace("<svg",`<symbol id="${t}" xmlns="http://www.w3.org/2000/svg" viewBox="${a}"`);return f=f.replace(/^<symbol\b[^>]*>/,u=>u.replace(/\s(width|height)="[^"]*"/g,"")),f=f.replace("</svg","</symbol"),f=gR(f),f},pR="line|circle|ellipse|rect|polyline|polygon|path|stop|use|image",hR=new RegExp(`<(${pR})\\b([^>]*?)\\s*/>`,"g"),gR=t=>t.replace(hR,"<$1$2></$1>");var ss={};$(ss,{STANDARD_SCHEME_QUERIES:()=>Kf,__resetSkinWarnings:()=>ny,appendSVGSprite:()=>Qa,appendSvgIconsSprite:()=>Gn,applyDocument:()=>Ja,applyHeadings:()=>Xf,applyReset:()=>tc,applySkins:()=>ec,applySpacingSequence:()=>Va,applyTimingSequence:()=>Za,applyTypographySequence:()=>Ga,buildSkinVarStyles:()=>Yn,checkIfBoxSize:()=>Ba,getColor:()=>ot,getFontFamily:()=>Ka,getFontSizeByKey:()=>Ya,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getSafeInk:()=>Gf,getSafeInkInfo:()=>Km,getShadow:()=>za,getShapeByKey:()=>Xa,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getTheme:()=>Zm,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,isPlainColor:()=>Xr,quietColorProbe:()=>Hn,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveShadowValue:()=>qn,runThroughMedia:()=>Yf,schemeGuardSelector:()=>Jr,schemeMediaQuery:()=>Zr,setAdaptiveSchemeVar:()=>Qr,setColor:()=>Yr,setFont:()=>qa,setFontFamily:()=>ns,setGradient:()=>es,setMediaTheme:()=>rs,setSVG:()=>os,setShadow:()=>tn,setSvgIcon:()=>Kn,setTheme:()=>Wa,splitSpacedValue:()=>Ua});D();var Kf={light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)"},Zr=(t,e)=>{let r=e.media&&e.media[t]||Kf[t];return r?"@media "+(r==="print"?`${r}`:`screen and ${r}`):null},Jr=t=>{let e=t.scopeSelector||":root";return`${e===":root"?":root:not([data-theme])":`:root:not([data-theme]) ${e}:not([data-theme])`} &`},ve=new Set,OS=new Set(["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","green","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"]),mR=/^(?:#[0-9a-f]{3,8}$|(?:rgba?|hsla?|hwb|lab|lch|oklab|oklch|color|color-mix)\()/i,yR=/gradient\(|url\(|image-set\(|var\(/i,bR=new Set(["transparent","currentColor","currentcolor"]),Xr=t=>{if(!k(t))return!1;let e=t.trim();return yR.test(e)?!1:mR.test(e)?!0:OS.has(e)||bR.has(e)},qf=new Set,ES=t=>{if(!t)return!1;let{color:e,gradient:r}=t;return!!(v(e)&&Object.keys(e).length||v(r)&&Object.keys(r).length)},AS=new Set,Wm=0,Hn=t=>{Wm++;try{return t()}finally{Wm--}},_R=(t,e)=>{if(!k(t)||t.indexOf(" ")===-1)return null;let r=t.replace(/\s+/g,""),n=Ut(r);if(!n||n.passthrough||n.cssVar)return null;let{color:o,gradient:s}=e;return!o[n.name]&&!s[n.name]?null:r},qm=(t,e,r)=>{let n=_R(t,r);if(n){if(!AS.has(t)){AS.add(t);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color token \`${t}\` has a space before its alpha/tone modifier${i} \u2014 did you mean \`${n}\`? The space form never resolves, so the atomic class it mints carries no CSS value and paints invisibly. Dropped rather than shipped invisible.`)}return}let o=Ut(t);if(o&&o.name&&!o.passthrough&&!o.cssVar&&(o.alpha!==void 0||o.tone!==void 0)&&ES(r)&&!r.color[o.name]&&!r.gradient[o.name]){if(!Wm&&!qf.has(t)){qf.add(t);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color token \`${t}\` does not resolve${i} \u2014 \`${o.name}\` is not in the palette. Dropped rather than emitted as a raw value, which is invalid CSS the browser discards silently. Define it in designSystem/color.js or use a palette token.`)}return}let s=k(e)?e.toLowerCase():"";if(!OS.has(s)||!ES(r))return t;if(!qf.has(s)){qf.add(s);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color \`${t}\` is a CSS named colour that is not in the palette${i}. Dropped rather than emitted as a raw browser colour, which renders theme-blind and can be unreadable ("looks designed", so it ships unnoticed). Define it in designSystem/color.js or use a palette token.`)}},RS=(t,e,r)=>{let n=e!==void 0?e:1;if(!r)return`rgb(from ${t} r g b / ${n})`;if(r.charCodeAt(0)===43||r.charCodeAt(0)===45){let s=parseFloat(r),i=s<0?"-":"+",a=Math.abs(s);return`rgb(from ${t} calc(r ${i} ${a}) calc(g ${i} ${a}) calc(b ${i} ${a}) / ${n})`}return`hsl(from ${t} h s ${r}% / ${n})`},ot=(t,e,r)=>{let n=r||A();if(!k(t)){n.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;e&&t[e]&&(t=t[e]);let o,s,i;if(P(t))[o,s,i]=t;else{let u=Ut(t);if(!u){let{color:d,gradient:g}=n,p=g[t]||d[t];return p?(e&&p[e]&&(p=p[e]),n.useVariable?`var(${p.var})`:p.value):qm(t,t,n)}if(u.passthrough)return u.passthrough;if(u.cssVar)return`var(${u.cssVar})`;o=u.name,s=u.alpha,i=u.tone}let{color:a,gradient:c}=n,l=a[o]||c[o];if(!l)return qm(t,o,n);if(e)if(l[e]!==void 0)l=l[e];else if(P(l)){let u=e.charCodeAt(0)===64?e.slice(1):e;u==="dark"?l=l[1]!==void 0?l[1]:l[0]:(u!=="light"&&n.verbose&&console.warn(t," - array-form color tokens only support light/dark; falling back to the light slot for scheme",e),l=l[0])}else n.verbose&&console.warn(t," - does not have ",e);if(k(l)){if(ve.has(o))return l;ve.add(o);try{return ot(l,null,r)}finally{ve.delete(o)}}let f=l.rgb;if(!f){let u=n.useVariable?`var(${l.var})`:l.value;return(s||i)&&u?RS(u,s,i):u}return i&&!l[i]&&(f=tr(f,i),l[i]={rgb:f,var:`${l.var}-${i}`}),l[i]&&(f=l[i].rgb),s?`rgba(${f}, ${s})`:i?`rgba(${f}, ${l.alpha!==void 0?l.alpha:1})`:n.useVariable?`var(${l.var})`:l.value!==void 0?l.value:`rgb(${f})`},TS=t=>{let e=Se(t);return!e||e.length<3||e[0]===0&&e[1]===0&&e[2]===0&&e[3]===0&&t.toLowerCase()!=="transparent"?null:{rgb:[e[0],e[1],e[2]],alpha:e[3]!==void 0?e[3]:1}},wR=(t,e)=>{if(!e)return t;let r=t.rgb;if(e.tone){let o=tr(r,e.tone);r=k(o)?o.split(",").map(s=>parseFloat(s.trim())):o}let n=e.alpha!==void 0?parseFloat(e.alpha):t.alpha;return{rgb:r,alpha:n}},Wn=(t,e,r)=>{let n=e||A();if(!k(t))return null;let o=Ut(t);if(o){if(o.passthrough){let d=Se(o.passthrough);return d&&d.length>=3?{rgb:[d[0],d[1],d[2]],alpha:d[3]!==void 0?d[3]:1}:null}if(o.cssVar)return null}let s=o?o.name:t,{color:i,gradient:a}=n,c=i[s]||a[s];if(!c)return TS(t);if(k(c)){let d;if(ve.has(s))d=TS(c);else{ve.add(s);try{d=Wn(c,n,r)}finally{ve.delete(s)}}return d?wR(d,o):null}if(c.rgb===void 0&&v(c)){let d=`@${r||"light"}`;c=c[d]!==void 0?c[d]:c["@light"]}if(!c||c.rgb===void 0)return null;let l=c.rgb;o&&o.tone&&(l=tr(l,o.tone));let f=k(l)?l.split(",").map(d=>parseFloat(d.trim())):l,u=o&&o.alpha!==void 0?parseFloat(o.alpha):c.alpha!==void 0?c.alpha:1;return{rgb:f,alpha:u}},PS=t=>v(t)&&t.value!==void 0&&(t.rgb!==void 0||t.var!==void 0),DS=t=>{if(!v(t)||t.value!==void 0)return null;let e=[];for(let r in t)if(r!=="var"){if(r.charCodeAt(0)!==64||!PS(t[r]))return null;e.push(r.slice(1))}return e.length?e:null},xR=t=>k(t&&t.var)&&DS(t)!==null,SR=(t,e,r,n,o)=>{let s=DS(e);if(!s)return;if(k(e.var)){let c=`var(${e.var})`;return r||n?RS(c,r,n):c}if(s.length!==2||!s.includes("light")||!s.includes("dark"))return;let i=ot(t,"@light",o),a=ot(t,"@dark",o);if(!(!Xr(i)||!Xr(a)))return i===a?i:`light-dark(${i}, ${a})`},Mt=(t,e,r)=>{let n=r||A();if(e||(e=n.globalTheme==="auto"?null:n.globalTheme),!k(t)){n.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;let o,s,i;if(P(t))o=t[0];else{let u=Ut(t);if(u){if(u.passthrough)return u.passthrough;if(u.cssVar)return`var(${u.cssVar})`;o=u.name,s=u.alpha,i=u.tone}else o=t}let{color:a,gradient:c}=n,l=a[o]||c[o],f=v(l);if(f&&l.value)return ot(t,`@${e}`,r);if(f){if(n.useVariable&&l.var)return s||i?ot(t,null,r):`var(${l.var})`;if(e){if(!n.useVariable&&a[o]===l){let u=SR(t,l,s,i,r);if(u!==void 0)return u}return ot(t,`@${e}`,r)}else{let u={},d=Jr(n);for(let g in l){if(g.charCodeAt(0)!==64)continue;let p=g.slice(1),h=ot(t,g,r);if(h!==void 0&&(u[`[data-theme="${p}"] &`]=h,p==="light"||p==="dark")){let m=Zr(p,n);if(!m)continue;u[m]={[d]:h}}}return u}}else return qm(t,o,n)},Qr=(t,e,r,n)=>{let s=`--${n.varPrefix?n.varPrefix+"-":""}${e}-${r}`,i,a={};for(let c in t){if(c.charCodeAt(0)!==64)continue;let l=c.slice(1),f=t[c],u=f&&(f.value||f);!u||typeof u!="string"||(a[l]=u,(l==="light"||i===void 0)&&(i=u))}if(i!==void 0){n.cssVars[s]=i,n.cssMediaVars||(n.cssMediaVars={});for(let c in a){let l=`[data-theme="${c}"]`;if(n.cssMediaVars[l]||(n.cssMediaVars[l]={}),n.cssMediaVars[l][s]=a[c],c==="light"||c==="dark"){let f=`@media (prefers-color-scheme: ${c})`;n.cssMediaVars[f]||(n.cssMediaVars[f]={}),n.cssMediaVars[f][s]=a[c]}}return t.var=s,s}},Yr=(t,e,r)=>{let n=A();if(PS(t))return n.useVariable&&t.var&&(n.cssVars[t.var]=t.value),t;if(!n.useVariable&&xR(t))return t;if(k(t)&&_t(t)){let h=t.slice(2);if(t=ot(h),!(t.includes("rgb")||t.includes("var")||t.includes("#"))){let m=h.split(" "),_=n.color[m[0]];if(_&&!_.value&&!_.rgb&&(k(_)||P(_)||v(_))&&!ve.has(m[0])){ve.add(m[0]);try{n.color[m[0]]=Yr(_,m[0])}finally{ve.delete(m[0])}_=n.color[m[0]]}if(_&&_.value){let x=_.rgb,y=m[1]!==void 0?m[1]:"1",b=m[2];b&&(x=tr(x,b)),t=`rgba(${x}, ${y})`}else{let x=m[2],y=m[1]!==void 0?m[1]:"1";if(x)try{let b=Se(m[0]);b&&b.length>=3?t=`rgba(${tr(b.slice(0,3).join(", "),x)}, ${y})`:t=m[0]}catch{t=m[0]}else t=m[0]}}}if(P(t)&&(t={"@light":t[0],"@dark":t[1]!==void 0?t[1]:t[0]}),v(t)){let h={};for(let m in t)m!=="var"&&(h[m]=Yr(t[m],e,m.slice(0,1)==="@"?m.slice(1):m));return n.useVariable&&Qr(h,"color",e,n),h}let s=`--${n.varPrefix?n.varPrefix+"-":""}color-${e}`+(r?`-${r}`:""),i=t.value||t;if(k(i)&&!i.includes("(")&&!i.startsWith("#")){let h=Ut(i);if(h&&h.name&&!h.passthrough&&!h.cssVar){let m=n.color[h.name];if(m&&!m.value&&!m.rgb&&(k(m)||P(m)||v(m))&&!ve.has(h.name)){ve.add(h.name);try{n.color[h.name]=Yr(m,h.name)}finally{ve.delete(h.name)}}let _=n.color[h.name];if(_&&_.rgb){let x=_.rgb;h.tone&&(x=tr(x,h.tone));let y=h.alpha!==void 0?parseFloat(h.alpha):_.alpha!==void 0?_.alpha:1;i=`rgba(${x}, ${y})`}}}let a=Se(i),[c,l,f,u=1]=a,d=parseFloat(u.toFixed(2)),g=`${c}, ${l}, ${f}`,p=`rgba(${g}, ${d})`;return n.useVariable&&(n.cssVars[s]=p),{var:s,rgb:g,alpha:d,value:p}},es=(t,e,r)=>{let n=A();if(v(t)&&t.value!==void 0&&t.var!==void 0)return n.useVariable&&(n.cssVars[t.var]=t.value),t;if(k(t)&&_t(t)&&(t=ot(t.slice(2))),P(t)&&(t={"@light":t[0],"@dark":t[1]!==void 0?t[1]:t[0]}),v(t)){let i={};for(let a in t)a!=="var"&&(i[a]=es(t[a],e,a.slice(0,1)==="@"?a.slice(1):a));return n.useVariable&&Qr(i,"gradient",e,n),i}let s=`--${n.varPrefix?n.varPrefix+"-":""}gradient-${e}`+(r?`-${r}`:"");return n.useVariable&&(n.cssVars[s]=t.value||t),{var:s,value:t.value||t}};D();var Gf=(t,e,r={},n)=>{let o=n||A(),{min:s=4.5,large:i=!1,scheme:a,meta:c=!1,maxIterations:l=15}=r,f=i?3:s,u=a||(o.globalTheme&&o.globalTheme!=="auto"?o.globalTheme:"light"),d=k(e)?e:String(e),g=Ut(t),p=g&&!g.passthrough&&!g.cssVar?g.name:null,h=(N,J)=>c?{value:N,...J}:N;if(p){let N=o.color[`${p}Safe`];if(N){let J=`${d}@${u}`,z=N[J]!==void 0?N[J]:N[d];if(z!==void 0){let cr=z&&z.rgb!==void 0?o.useVariable&&z.var?`var(${z.var})`:z.value:ot(z,null,o);return h(cr,{ratio:null,deviation:0,derived:!1,overridden:!0})}}}let m=ot(t,u?`@${u}`:null,o),_=Wn(t,o,u),x=Wn(e,o,u);if(!_||!x)return o.verbose&&console.warn("getSafeInk: could not resolve",t,e,"\u2014 returning hue unchanged"),h(m,{ratio:null,deviation:0,derived:!1,overridden:!1,unresolved:!0});let y=jn(x.rgb,x.alpha),b=jn(_.rgb,_.alpha,y),w=Go(b,y);if(w>=f-.02)return h(m,{ratio:w,deviation:0,derived:!1,overridden:!1});let[S,C,O]=Sa(_.rgb),[,L,T]=ka([S,C,O]),M=Fn(y)>.5,U=M?S:1-S,rt=N=>{let J=M?S-N:S+N,z=Math.max(0,Math.min(1,J));return{rgb:va(z,L,T),L:z}},Rt=N=>{let{rgb:J}=rt(N),z=jn(J.map(cr=>Math.round(cr)),_.alpha,y);return Go(z,y)},mt=0,F=U,W=Rt(F)>=f;if(W)for(let N=0;N<l;N++){let J=(mt+F)/2;Rt(J)>=f?F=J:mt=J}else mt=F;let{rgb:yt,L:St}=rt(F),Pt=yt.map(N=>Math.round(N)),G=Rt(F),j=_.alpha<1?`rgba(${Pt.join(", ")}, ${_.alpha})`:`rgb(${Pt.join(", ")})`,nt=Math.abs(St-S)*100;return h(j,{rgb:Pt,ratio:G,startRatio:w,deviation:nt,derived:!0,overridden:!1,reachable:W})},Km=(t,e,r={},n)=>Gf(t,e,{...r,meta:!0},n);D();D();var kR=t=>{let r=A().spacing||{},n=parseFloat(t.spacingRatio),o={...r,ratio:Number.isFinite(n)?n:r.ratio,sequence:{},scales:{}};return te(o),o},vR=t=>{for(let e in t){let r=t[e];if(!(e.slice(0,1)==="@"))continue;let{type:o,base:s,ratio:i,range:a,subSequence:c,h1Matches:l,unit:f}=t;bt(r,{type:o,base:s,ratio:i,range:a,subSequence:c,h1Matches:l,unit:f,sequence:{},scales:{},templates:{},vars:{}}),te(r),Kr(t,e)}},Ba=t=>{let e=t.toLowerCase(),r=e.includes("width")||e.includes("height"),n=e.includes("border")||e.includes("outline");return r&&!n},Va=()=>{let t=A(),{spacing:e}=t;te(e),_r(e),vR(e)},CR=t=>{let e=A(),{spacing:r}=e;return!t||!t.sequence?r:Object.keys(t.sequence).length>0?t:te(t)},Ct=(t,e="padding",r,n)=>{let o=CR(r);if(k(t)){if(!n&&/^(?:env|var)\(/.test(t.trim()))return{[e]:t};if(!n&&t.includes("(")){let i=br(t);n=i[0],t=i[1]}}let s=n?[t]:k(t)&&t.includes("(")?pt(t):Mn(t);if(P(s)){if(s.length>1){let i="";e==="borderWidth"&&(e="border",i="Width");let a={2:["Block","Inline"],3:["BlockStart","Inline","BlockEnd"],4:["BlockStart","InlineEnd","BlockEnd","InlineStart"]},c=(l,f)=>rr(s[f],e+l+i,o,n);return a[s.length].map((l,f)=>c(l,f))}return rr(t,e,o,n)}},Ce=(t,e,r,n)=>{let o=A(),{spacing:s}=o,i=r||t[e];if(!n&&k(i)&&/^(?:env|var)\(/.test(i.trim()))return{[e]:i};if(!n&&k(i)&&i.includes("(")){let a=br(i);n=a[0],i=a[1]}if(t.spacingRatio){let a=kR(t);return Ct(i,e,a,n)}return Ct(i,e,s,n)},Ua=t=>{let e=r=>{let n=["+","-","*","/"].includes(r),o=So.some(i=>t.includes(i));return n||o?r:r.length<3&&/[A-Z]/.test(r)?r+"_default":r};return t.split(",").map(r=>r.trim()).map(e).join(",").split(" ").map(e).join(" ")};D();var qn=(t,e,r)=>!k(t)||le.test(t)?t:mr(t).map(n=>(n=n.trim(),n.split(/\s+/).map(o=>{if(o=o.trim(),!o)return"";if(o.startsWith("--"))return`var(${o})`;let s=Hn(()=>ot(o,e));if(Fe(s))return s;if(/^\d/.test(o)||o==="0"||o.includes("px")||o.slice(-2)==="em"||o==="inset"||o==="none"||Nn.has(o.toLowerCase()))return o;r&&r(o);let i=Ct(o,"shadow");return i&&i.shadow?i.shadow:o}).join(" "))).join(", "),tn=(t,e,r,n)=>{let o=A();if(v(t)&&t.value!==void 0&&t.var!==void 0)return o.useVariable&&(o.cssVars[t.var]=t.value),t;if(P(t)){let a={"@light":tn(t[0],e,"light"),"@dark":tn(t[1],e,"dark")};return o.useVariable&&Qr(a,"shadow",e,o),a}if(v(t)){let a={};for(let c in t)a[c]=tn(t[c],e,c.startsWith("@")?c.slice(1):c);return o.useVariable&&Qr(a,"shadow",e,o),a}k(t)&&!le.test(t)&&(t=qn(t));let i=`--${o.varPrefix?o.varPrefix+"-":""}shadow-${e}`+(r?`-${r}`:"");return o.useVariable&&(o.cssVars[i]=t),{var:i,value:t}},za=(t,e)=>{let r=A();if(e||(e=r.globalTheme==="auto"?null:r.globalTheme),!k(t)){r.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;let[n]=P(t)?t:t.split(" "),s=r.shadow[n],i=v(s);if(!s)return r.verbose&&console.warn("Can't find color ",n),t;if(i&&!s.value&&r.useVariable&&s.var)return`var(${s.var})`;if(e){let a=s["@"+e]||s[e];if(a)return a.value!==void 0?a.value:a;r.verbose&&console.warn(t," - does not have ",e)}if(i&&s.value)return s.value;if(i){let a={},c=Jr(r);for(let l in s){if(l.charCodeAt(0)!==64)continue;let f=l.slice(1),u=s[l],d=u&&(u.value!==void 0?u.value:u);if(d!==void 0&&(a[`[data-theme="${f}"] &`]=d,f==="light"||f==="dark")){let g=Zr(f,r);if(!g)continue;a[g]={[c]:d}}}return a}return r.verbose&&console.warn("Can't find color",t),t};var ER=new Set(["none","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset","initial"]),AR=t=>ER.has(t),de=(t,e,r)=>{if(t==null)return;let n=t+"";if(le.test(n))return n;let o=n.trim();return o==="none"||o==="0"||o==="initial"||o==="inherit"||o==="unset"?n:n.split(/\s+/).map(s=>{if(s=s.trim(),!s)return"";if(_t(s))return`var(${s})`;if(AR(s)||/^\d/.test(s)||s==="0")return s;let i=Hn(()=>ot(s,e));if(Fe(i))return i;if(Nn.has(s.toLowerCase()))return s;r&&r(s);let a=Ct(s,"border");return a&&a.border?a.border:s}).join(" ")};D();var TR=new Set(["black","white","red","green","blue","yellow","orange","purple","pink","brown","gray","grey","cyan","magenta","lime","olive","navy","teal","aqua","maroon","silver","fuchsia","transparent","currentColor","currentcolor","inherit","initial","unset","none","aliceblue","antiquewhite","aquamarine","azure","beige","bisque","blanchedalmond","blueviolet","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","gainsboro","ghostwhite","gold","goldenrod","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","limegreen","linen","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","oldlace","olivedrab","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","plum","powderblue","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","thistle","tomato","turquoise","violet","wheat","whitesmoke","yellowgreen","rebeccapurple"]),LS=["color","Color","background","Background","fill","Fill","stroke","Stroke"],FS=t=>{for(let e=0;e<LS.length;e++)if(t.includes(LS[e]))return!0;return!1},OR={boxShadow:qn,textShadow:qn,border:de,borderTop:de,borderRight:de,borderBottom:de,borderLeft:de,outline:de,columnRule:de},RR=t=>{if(!t)return!1;let e=Ut(t);return!e||!e.name||e.passthrough||e.cssVar?!1:e.alpha!==void 0||e.tone!==void 0},IS=new Set,PR=(t,e,r,n,o,s)=>{if(!gt())return;let i=`${t}::${e}::${r||""}::${n}`;IS.has(i)||(IS.add(i),console.warn(`[smbls/scratch] theme param "${e}" on "${t}"`+(r?` (${r})`:"")+` did not fully resolve: "${n}" -> "${o}" still contains the unresolved token "${s}". This is not valid CSS \u2014 the browser will drop the whole declaration. Register "${s}" as a design-system color token or fix the typo.`))},Xm=(t,e,r,n)=>{let o=OR[e];if(!o)return ot(r,n);let s=null,i=o(r,n,a=>{!s&&RR(a)&&(s=a)});return s&&PR(t,e,n,r,i,s),i},Zm=(t,e)=>Ee(t,e),DR=t=>v(t)&&B(t.value),LR=t=>{for(let e in t){let r=t[e];if(k(r)&&r.startsWith("var(--"))return!0}return!1},Wa=(t,e)=>{let r=A();return DR(t)?!r.useVariable&&LR(t)?t:rs(t.value,e):rs(t,e)},NS=(t,e)=>{let r=new Set;for(let n of e){let o=n.slice(0,1);if(!(o==="@"||o==="."||o===":")&&FS(n))for(let s in t){if(r.has(s))continue;let i=t[s]?.[n];if(i===void 0)continue;let a=ot(i,`@${s}`);a!==void 0&&k(a)&&/^[a-z][a-zA-Z]+$/.test(a)&&!TR.has(a)&&r.add(s)}}return r},IR=t=>t.startsWith("[data-theme=")||t.startsWith("@media"),Ha=(t,e)=>{for(let r in e){let n=e[r];v(n)?Ha(t[r]||(t[r]={}),n):t[r]=n}return t},$S=(t,e,r,n)=>{if(Ha(t,{[`[data-theme="${e}"] &`]:r}),e!=="light"&&e!=="dark")return;let o=Zr(e,n);o&&Ha(t,{[o]:{[Jr(n)]:r}})},jS=(t,e,r,n)=>{let o=r.globalTheme!==void 0?r.globalTheme:"auto",s=o&&o!=="auto"?String(o).replace(/^'|'$/g,""):null,i=new Set(n?Object.keys(n):[]);for(let l in t)if(t[l])for(let f of Object.keys(t[l]))i.add(f);let a=NS(t,i),c={};for(let l of i){let f=l.slice(0,1);if(f==="@")continue;if(f==="."||f===":"){let _={};for(let b in t)B(t[b]?.[l])&&(_[b]=t[b][l]);let x=n&&B(n[l])?n[l]:void 0;if(!Object.keys(_).length&&!x)continue;let y=f==="."?l.slice(1):l.replace(/^:+/,"");c[l]=jS(_,`${e}-${y}`,r,x);continue}let u=n&&!B(n[l])?n[l]:void 0,d=new Set(Object.keys(t));u!==void 0&&(d.add("light"),d.add("dark"),s&&d.add(s));let g={},p;for(let _ of d){if(a.has(_))continue;let x=t[_]?.[l];if((x===void 0||B(x))&&(x=u),x===void 0)continue;let y=Xm(e,l,x,`@${_}`);y!==void 0&&(g[_]=y,(s&&_===s||!s&&(_==="light"||p===void 0))&&(p=y))}let h={},m=Object.keys(g).filter(_=>g[_]!==p);if(m.length){let _=g.light!==void 0?g.light:p,x=g.dark!==void 0?g.dark:p;if(FS(l)&&Xr(_)&&Xr(x)){h[l]=_===x?_:`light-dark(${_}, ${x})`;for(let y in g)y==="light"||y==="dark"||$S(h,y,{[l]:g[y]},r)}else{p!==void 0&&(h[l]=p);for(let y of m)$S(h,y,{[l]:g[y]},r)}}else{if(p===void 0)continue;h[l]=p}Ha(c,h),c[`.${l}`]=h}return(c.background||c.color||c.backgroundColor)&&(c[".inversed"]={color:c.background||c.backgroundColor,background:c.color}),c},Gm=(t,e,r,n)=>{let{cssVars:o}=r;r.cssMediaVars||(r.cssMediaVars={});let s=r.cssMediaVars,i=r.globalTheme!==void 0?r.globalTheme:"auto",a=i&&i!=="auto"?String(i).replace(/^'|'$/g,""):null,c={},l=new Set(n?Object.keys(n):[]);for(let u in t)if(t[u])for(let d of Object.keys(t[u]))l.add(d);let f=NS(t,l);for(let u of l){let d=u.slice(0,1),g=B(n?.[u])||Object.values(t).some(p=>B(p?.[u]));if(d==="."&&g){let p=u.slice(1),h={};for(let _ in t)B(t[_]?.[u])&&(h[_]=t[_][u]);let m=B(n?.[u])?n[u]:void 0;c[u]=Gm(h,`${e}-${p}`,r,m)}else if(d===":"&&g){let p=u.replace(/^:+/,""),h={};for(let _ in t)B(t[_]?.[u])&&(h[_]=t[_][u]);let m=B(n?.[u])?n[u]:void 0;c[u]=Gm(h,`${e}-${p}`,r,m)}else if(d!=="@"&&d!=="."&&d!==":"){let h=`--${r.varPrefix?r.varPrefix+"-":""}theme-${e}-${u}`,m=n&&!B(n[u])?n[u]:void 0,_=new Set(Object.keys(t));m!==void 0&&(_.add("light"),_.add("dark"),a&&_.add(a));let x,y=!1;for(let b of _){if(f.has(b))continue;let w=t[b]?.[u];if((w===void 0||B(w))&&(w=m),w===void 0)continue;let S=Xm(e,u,w,`@${b}`);if(S===void 0)continue;y=!0,(a&&b===a||!a&&(b==="light"||x===void 0))&&(x=S);let C=`[data-theme="${b}"]`;if(s[C]||(s[C]={}),s[C][h]=S,b==="dark"||b==="light"){let O=`@media (prefers-color-scheme: ${b})`;s[O]||(s[O]={}),s[O][h]=S}}if(x!==void 0&&(o[h]=x),!y)continue;c[u]=`var(${h})`,c[`.${u}`]={[u]:c[u]}}}return(c.background||c.color||c.backgroundColor)&&(c[".inversed"]={color:c.background||c.backgroundColor,background:c.color}),c},rs=(t,e,r,n)=>{let o=A(),{cssVars:s}=o,i={value:t},a=!r&&!n,c,l;if(B(t)){if(a&&o.useVariable){let f={},u={};for(let d in t)d.startsWith("@")?B(t[d])&&(f[d.slice(1)]=t[d]):u[d]=t[d];(Object.keys(f).length||Object.keys(u).length)&&(l=Gm(f,e,o,u),Object.assign(i,l))}else if(a){let f={},u={};for(let d in t)d.startsWith("@")?B(t[d])&&(f[d.slice(1)]=t[d]):u[d]=t[d];c=jS(f,e,o,u),Object.assign(i,c)}for(let f in t){let u=f.slice(0,1),d=t[f];if(u==="@"||u===":"||u==="."){let g=u==="@"&&f;i[f]=rs(d,e,f,n||g)}else if(!a){let g=Xm(e,f,d,n),p=[...new Set([n,r].filter(x=>x).map(x=>x.slice(1)))],h=p.length?"-"+p.join("-"):"",_=`--${o.varPrefix?o.varPrefix+"-":""}theme-${e}${h}-${f}`;o.useVariable?(o.useThemeSuffixedVars&&(s[_]=g),i[f]=`var(${_})`):i[f]=g,i[`.${f}`]={[f]:i[f]}}}if(c)for(let f in c){let u=f.slice(0,1);(u==="."||u===":")&&B(t[f])&&(i[f]=c[f])}if(l)for(let f in l){let u=f.slice(0,1);(u==="."||u===":")&&B(t[f])&&(i[f]=l[f])}!i[".inversed"]&&(i.background||i.color||i.backgroundColor)&&(i[".inversed"]={color:i.background||i.backgroundColor,background:i.color})}if(k(t)&&_t(t)){let u=o.theme[t.slice(2)];return Ee(u,n)}return i},Ym=(t,e)=>{let r={};for(let n in t){let o=n.slice(0,1);if(B(t[n]))if(e&&IR(n))r[n]=Ha({},t[n]);else{if(o==="@")continue;o===":"?r[`&${n}`]=Ym(t[n],e):o==="."&&(r[`&${n}`]=Ym(t[n],e))}else r[n]=t[n]}return r},BS=(t,e)=>{let r=e.shift();return t[r]?BS(t[r],e):t},MS=(t,e)=>P(e)?BS(t,e):k(e)&&t[e]?t[e]:t;var Ee=(t,e)=>{let r=A();if(k(t)&&_t(t)&&(t=Ee(t.slice(2))),!t||!k(t)){r.verbose&&console.warn(`${t} - Theme is not a string`);return}let[n,...o]=P(t)?t:t.split(" "),s=r.theme[n];return s&&o.length?s=MS(s,o):s&&e&&(s=MS(s,e)),Ym(s,!r.useVariable)};D();D();var qa=(t,e)=>{let r=A(),n=`--font-${e}`;if(!t||P(t)&&!t[0])return;let o;if(t.isVariable){let s=ke(t.url,r.files)||t.url;Yo(s)?o=Xo(s):o=qr(e,s,t.fontWeight,{fontStretch:t.fontStretch,fontDisplay:t.fontDisplay||"swap",unicodeRange:t.unicodeRange})}else if(t[0])o=Vn(e,t,r.files);else{let s=Array.isArray(t.url)?t.url.map(i=>ke(i,r.files)||i):ke(t.url,r.files)||t.url;o=qr(e,s,t.fontWeight,{fontStyle:t.fontStyle,fontDisplay:t.fontDisplay,fontStretch:t.fontStretch,unicodeRange:t.unicodeRange})}return{var:n,value:t,fontFace:o}},Ka=(t,e)=>{let r=A(),{fontFamily:n}=r;return Bn(e||n,t)},ns=(t,e)=>{let r=A(),{fontFamily:n,fontFamilyTypes:o}=r,{value:s,type:i}=t;t.isDefault&&(!t.isSystemFallback||!n.default)&&(n.default=e),v(s)&&(s=Mn(s));let a=`--font-family-${e}`,c=`${s.join(", ")}, ${o[i]}`;return{var:a,value:c,arr:s,type:i,isSystemFallback:!!t.isSystemFallback}};D();var Yf=t=>{let e=A(),{typography:r,media:n}=e;for(let o in t){let s=o.slice(0,1)==="@",i=t[o];if(!s)continue;let{mediaRegenerate:a}=t,c=o.slice(1),{type:l,base:f,ratio:u,range:d,subSequence:g,h1Matches:p,unit:h}=t;bt(i,{type:l,base:f,ratio:u,range:d,subSequence:g,h1Matches:p,unit:h});let m=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),_=i.unit||h,x=!i.unit&&m.has(h)?"rem":_,y=n[c],b="@media "+(y==="print"?`${y}`:`screen and ${y}`);if(r.templates[b]={fontSize:i.base/r.browserDefault+x},!a){bt(i,{sequence:{},scales:{},vars:{}}),te(i),Kr(t,o);continue}bt(i,{sequence:{},scales:{},templates:{},vars:{}}),te(i),Kr(t,o)}},Xf=t=>{let e=A();if(t.h1Matches){let r=t.unit,n=Ma(t),{templates:o}=t;for(let s in n){let i=`h${parseInt(s)+1}`,a=o[i];o[i]={fontSize:e.useVariable?`var(${n[s]?.variable})`:`${n[s]?.scaling}${r}`,margin:a?a.margin:0,lineHeight:a?a.lineHeight:t.lineHeight,letterSpacing:a?a.letterSpacing:t.letterSpacing,fontWeight:a?a.fontWeight:900-s*100}}}},Ga=()=>{let t=A(),{typography:e}=t;te(e),Xf(e),_r(e),Yf(e)},Ya=t=>{let e=A(),{typography:r}=e;return rr(t,"fontSize",r)};D();var Xa=t=>{if(!k(t))return;let r=A().shape;if(r)return r[t]!==void 0?r[t]:r[t.toLowerCase()]};D();var Za=()=>{let t=A(),{timing:e}=t;te(e),_r(e)},Ae=t=>{let e=A(),{timing:r}=e;return r[t]||r[ba(t)]||t},pe=(t,e="timing")=>{let r=A(),{timing:n}=r;return rr(t,e,n)};D();var Ja=()=>{let t=A(),{fontFamily:e,theme:r,typography:n}=t,o=t.document;return ur(o)?($r(t,"document",o),o=t.document={}):o||(o=t.document={}),bt(o,{theme:r.document,fontFamily:Bn(e),fontSize:n.base,lineHeight:n.lineHeight})};D();var ty={document:st},VS=new WeakMap,US=new WeakMap,$R=128,zS=1048576,Jm=8192,ey=t=>t.nodeType===1&&t.localName==="symbol"&&t.getAttribute("id"),qS=t=>t.nodeType===8||t.nodeType===3&&!t.textContent.trim(),MR=(t,e)=>{let r=1,n=t.ownerDocument;if(n&&typeof n.createTreeWalker=="function"){let s=n.createTreeWalker(t,4294967295);for(;s.nextNode();)if(++r>e)return r;return r}let o=[t];for(;o.length;){let s=o.pop().childNodes||[];for(let i=0;i<s.length;i++){if(++r>e)return r;o.push(s[i])}}return r},Qm=(t,e)=>{if(typeof t.importNode=="function")return t.importNode(e,!0);let r=e.cloneNode(!0);return typeof t.adoptNode=="function"?t.adoptNode(r):r},FR=(t,e)=>{if(typeof t.prepend=="function")return t.prepend(e);let r=t.firstChild!==void 0?t.firstChild:t.childNodes&&t.childNodes[0];return typeof t.insertBefore=="function"?t.insertBefore(e,r||null):t.appendChild(e)},os=(t,e)=>{let r=A();if(!t){r.verbose&&console.warn("setSVG: val is not defined",e);return}return r.useSvgSprite?ja(e,t):t},Qa=(t,e=ty)=>{let r=A(),n=Object.keys(t).length?{}:r.svg;for(let o in t)n[o]=t[o];GS(n,e)},Kn=(t,e)=>{let r=A();return r.useIconSprite&&!r.semanticIcons?.[e]?os(t,e):t},Gn=(t,e=ty)=>{let r=A(),n=Object.keys(t).length?{}:r.icons;for(let o in t)n[o]=t[o];GS(n,e)},KS=(t,e={isRoot:!0})=>{if(!t||!t.createElementNS)return;let r=t.createElementNS("http://www.w3.org/2000/svg","svg");return e.isRoot&&(r.setAttribute("aria-hidden","true"),r.setAttribute("width","0"),r.setAttribute("height","0"),r.setAttribute("style","position:absolute"),r.setAttribute("id","svgSprite")),r},NR=(t,e)=>{let r=typeof DOMParser<"u"?DOMParser:null;if(r){let n=`<svg xmlns="http://www.w3.org/2000/svg">${e}</svg>`,s=new r().parseFromString(n,"image/svg+xml");return s.querySelector("parsererror")?null:s.documentElement}return null},jR=(t,e,r)=>{let n=String(r),o=US.get(e),s=o?.entries.get(n);if(s)return o.entries.delete(n),o.entries.set(n,s),s.root;let i=NR(t,n);if(i||(i=KS(t,{isRoot:!1}),i.innerHTML=n),n.length>zS)return i;let a=MR(i,Jm);if(a>Jm)return i;for(o||(o={entries:new Map,units:0,nodes:0},US.set(e,o));o.entries.size>=$R||o.units+n.length>zS||o.nodes+a>Jm;){let c=o.entries.keys().next().value,l=o.entries.get(c);o.units-=c.length,o.nodes-=l.nodes,o.entries.delete(c)}return o.entries.set(n,{root:i,nodes:a}),o.units+=n.length,o.nodes+=a,i},HS=t=>{let e=new Map;for(let r of t.children){let n=ey(r);if(!n)continue;let o=e.get(n)||[];o.push(r),e.set(n,o)}return e},BR=t=>t.replace(/["\\\u0000-\u001f\u007f]/g,e=>`\\${e.charCodeAt(0).toString(16)} `),WS=(t,e,r,n)=>{let o=0,s=e.childElementCount>8?HS(r):null,i=a=>{if(!s)try{return[...r.querySelectorAll(`symbol[id="${BR(a)}"]`)].filter(c=>c.parentNode===r)}catch{s=HS(r)}return s.get(a)};for(let a of e.childNodes){if(qS(a))continue;let c=ey(a);if(!c&&n){let u=o++,d=n.nodes[u];if(!d&&n.complete||d?.parentNode===r)continue;let g=Qm(t,d||a);r.appendChild(g),n.nodes[u]=g;continue}let l=c&&i(c),f=l&&l[0];if(!f)f=Qm(t,a),r.appendChild(f);else if(!f.isEqualNode(a)){let u=Qm(t,a);r.replaceChild(u,f),f=u}if(l)for(let u=1;u<l.length;u++)l[u].remove();c&&s&&s.set(c,[f])}},GS=(t,e=ty)=>{let r=A(),n=e.document||st;if(!n||!n.documentElement)return r.verbose&&console.warn("To append SVG sprites it should be run in browser environment"),Na(t);let o=n.querySelector("#svgSprite"),s="";for(let d in t)s+=t[d];let i=o||KS(n);if(!i||!i.nodeType)return;let a=d=>jR(n,i,d),c=a(s),l=VS.get(i);l||VS.set(i,l=new WeakMap);let f=l.get(r);if(f||l.set(r,f=new Map),[...c.childNodes].some(d=>!qS(d)&&!ey(d))){let d=[];for(let g in t)d.push(g);for(let g of d){let p=f.get(g);p||f.set(g,p={nodes:[],complete:!1}),WS(n,d.length===1?c:a(t[g]),i,p),p.complete=!0}}else{WS(n,c,i);for(let d in t)f.has(d)||f.set(d,{nodes:[],complete:!0})}o||FR(n.body,i);for(let d in t)r.__svgCache[d]=!0};D();var tc=(t={})=>{let e=A(),r=e.typography||{},n=e.document||{},o=v(e.reset)?e.reset:e.reset={};if(o[":root"]){let c=o,l=r.templates||{};c.body={...e.useDocumentTheme?Ee("document"):{},...l.body},c.h1=l.h1,c.h2=l.h2,c.h3=l.h3,c.h4=l.h4,c.h5=l.h5,c.h6=l.h6}let{body:s,...i}=r.templates||{},a=e.useDocumentTheme?Ee("document"):{};if(o.html&&Wt(o.html,a),r.unit)for(let c in i){if(c.slice(0,6)!=="@media")continue;let l=i[c];delete i[c],!(!l||!l.fontSize)&&(o[c]||(o[c]={}),o[c].html||(o[c].html={}),o[c].html.fontSize===void 0&&(o[c].html.fontSize=l.fontSize))}if(r.unit){let c=e.media||{};for(let l in r){if(l.charAt(0)!=="@")continue;let f=r[l];if(!f||f.unit===r.unit||!f.unit)continue;let u=f.unit,d=f.base||r.base,g=f.browserDefault||r.browserDefault,p=l.slice(1),h=c[p];if(!h)continue;let m="@media "+(h==="print"?h:"screen and "+h);o[m]||(o[m]={}),o[m].html||(o[m].html={}),o[m].html.fontSize=d/g+u}}return at(bt(o,t),{html:{position:"absolute",width:"100%",height:"100%",top:"0",left:"0",margin:"0",WebkitFontSmoothing:"subpixel-antialiased",textSizeAdjust:"100%",WebkitTextSizeAdjust:"100%",...a,fontSize:r.unit?r.base/r.browserDefault+r.unit:r.browserDefault+"px",fontFamily:n.fontFamily,lineHeight:n.lineHeight},body:{boxSizing:"border-box",height:"100%",margin:0,fontFamily:n.fontFamily,fontSize:r.unit?"1"+e.unit.default:r.base/r.browserDefault+e.unit.default,...i,...s},a:{color:"currentColor"},button:{color:"inherit",font:"inherit",background:"transparent",border:"none",cursor:"pointer",appearance:"none",WebkitAppearance:"none"},"input, select, textarea":{color:"inherit",font:"inherit"},fieldset:{border:0,padding:0,margin:0}},ue)};D();var VR=new Set(["fallback"]),ry=new Set,YS=(t,e)=>{ry.has(t)||(ry.add(t),gt()&&console.warn(e))},ny=()=>{ry.clear()},XS=t=>{for(let e in t)delete t[e];return t},ec=()=>{let t=A(),e=v(t.cssSkinVars)?XS(t.cssSkinVars):t.cssSkinVars={},r=v(t.cssSkinFallback)?XS(t.cssSkinFallback):t.cssSkinFallback={},n=t.skins;if(!v(n))return e;let o=t.varPrefix?t.varPrefix+"-":"",s=t.color||{},i=t.cssVars||{},a=c=>k(c)&&Object.prototype.hasOwnProperty.call(s,c)?`var(--${o}color-${c})`:c;for(let c in n){let l=n[c];if(!v(l))continue;let f={};for(let u in l){if(VR.has(u))continue;let d=l[u];if(v(d))for(let g in d){let p=`--${o}theme-${u}-${g}`;t.useVariable!==!1&&!(p in i)&&YS(`${c}/${u}/${g}`,`[scratch] skin "${c}" rewrites theme "${u}" param "${g}", which the theme does not declare \u2014 no element reads ${p}, so the skin changes nothing there. Declare "${g}" on the "${u}" theme (its no-skin value).`),f[p]=a(d[g])}}e[c]=f,k(l.fallback)&&(r[c]=l.fallback)}for(let c in r){let l=r[c];e[l]||(YS(`${c}/fallback/${l}`,`[scratch] skin "${c}" falls back to "${l}", which is not a declared skin \u2014 the reduced-transparency fallback is skipped.`),delete r[c])}return e},ZS=(t,e)=>{let r=`[data-skin="${t}"]`;return!e||e===":root"?`:root${r}, ${r}`:`${e}${r}, ${r} ${e}, ${e} ${r}`},Yn=(t,e,r)=>{let n={};if(!v(t))return n;for(let s in t)n[ZS(s,r)]=t[s];let o={};for(let s in e||{}){let i=t[e[s]];i&&(o[ZS(s,r)]=i)}return Object.keys(o).length&&(n["@media (prefers-reduced-transparency: reduce)"]=o),n};D();var UR=new Set(["to","top","bottom","left","right","center","at","circle","ellipse","closest-side","farthest-side","closest-corner","farthest-corner"]),JS=/^-?[A-Z][0-9]?$/,nr=t=>de(t),Zf=t=>{if(k(t))return le.test(t)?t:t.split(/\s+/).map(e=>{if(e=e.trim(),!e)return"";if(_t(e))return`var(${e})`;if(/^\d/.test(e)||e.includes("px")||e==="0")return e;let r=ot(e);return Fe(r)?r:e}).join(" ")},Jf=(t,e)=>za(t,e),rc=(t,e)=>{if(k(t))return le.test(t)?t:mr(t).map(r=>(r=r.trim(),r?r.split(/\s+/).map(n=>{if(n=n.trim(),!n)return"";if(_t(n))return`var(${n})`;if(n==="inset"||n==="none")return n;let o=ot(n);if(Fe(o)){let i=Mt(n,e);return v(i)?Object.values(i).filter(a=>a.includes(": "+e))[0]:i}if(/^\d/.test(n)||n==="0"||n.includes("px")||n.slice(-2)==="em")return n;let s=Ct(n,"shadow");return s&&s.shadow?s.shadow:n}).join(" "):"")).join(", ")},nc=(t,e)=>{let r=t.indexOf("(");if(r===-1)return t;let n=t.slice(0,r+1),o=t.slice(r+1,t.lastIndexOf(")")),s=")",a=mr(o).map(c=>(c=c.trim(),c.split(/\s+/).map(f=>{if(!f||/^\d/.test(f)||f==="0"||UR.has(f)||f==="transparent"||le.test(f))return f;let u=ot(f);return Fe(u)?u:f}).join(" ")));return n+a.join(", ")+s},Qf=(t,e)=>{if(!k(t))return;let r=A();return mr(t).map(n=>{let o=n.trim();if(_t(o))return`var(${o})`;if(/^var\(/.test(o)||o.includes("url"))return o;if(r.gradient?.[o]){let s=Mt(o,e);if(k(s))return s;if(v(s)){for(let i in s)if(k(s[i]))return s[i]}return o}return o.includes("gradient")?nc(o,e):o.includes("/")||o.startsWith("http")||o.includes(".")&&!Ut(o)?`url(${o})`:o}).join(", ")},tu=t=>k(t)&&pt(t).map(e=>Ct(e,"gap").gap).join(" "),eu=t=>{if(!k(t))return t;let e=A();return pt(t).map(r=>JS.test(r)?zn(r,e.spacing):r).join(" ")},oy=t=>{if(!k(t))return;let e=t.split(" ");return e.length?e.map(r=>_t(r)?`var(${r})`:r.length<3||r.includes("ms")?pe(r).timing||r:Ae(r)?Ae(r):r).join(" "):t},oc=(t,e,r)=>{if(k(t))return t.split(",").map(n=>pe(n).timing||n).join(",")},ru=t=>{if(!k(t))return;let e=t.split(",");if(e.length)return e.map(oy).join(",")};function vt(t,e,r={},n={}){let o=dt.call(this,e||r[t]);if(o==null)return;let s;if(k(o)){if(/^(?:env|var)\(/.test(o.trim()))return{[t]:o};if(o.includes("(")){let c=br(o);s=c[0],o=c[1]}let i=r.scaleBoxSize,a=Ba(t);!i&&a&&!n.ratio&&(o=Ua(o))}return n.ratio?Ce(r,t,o,s):Ct(o,t,void 0,s)}var I=(t,e=null,r)=>vt(t,e,r,{ratio:!0}),zR=(t,e,r)=>k(t)?pt(t).map(n=>JS.test(n)?Ce(e,r,n)[r]:n).join(" "):t,wr=(t,e,r,n="borderRadius")=>{if(k(t))return{[n]:pt(t).map(o=>{let s=Xa(o);return s!==void 0?zR(s,e,r):Ce(e,r,o)[r]}).join(" ")}};D();var is="__smblsThemeRootOwner",as=t=>{let e=t&&t.__prefersListener,r=t&&t.__prefersMq;if(e&&r)try{typeof r.removeEventListener=="function"?r.removeEventListener("change",e):typeof r.removeListener=="function"&&r.removeListener(e)}catch{try{r.removeListener(e)}catch{}}t&&(t.__prefersListener=null,t.__prefersMq=null)},QS=(t,e,r)=>{if(!(!t||!e)){as(t),t.__prefersListener=r,t.__prefersMq=e;try{e.addEventListener("change",r)}catch{e.addListener(r)}}},HR=(t,e)=>{let r=A(),{cssVars:n}=r,o=e.startsWith("--")?e:`--${e}`;return n[o]=t,t},Kt=t=>t,nu={color:Yr,gradient:es,font:qa,fontFamily:ns,fontfamily:ns,theme:Wa,icons:Kn,semanticIcons:Kt,semanticicons:Kt,svg:os,svgData:Kt,typography:Kt,shadow:tn,spacing:Kt,media:Kt,grid:Kt,class:Kt,timing:Kt,reset:Kt,unit:Kt,animation:Kt,vars:HR,sizes:Kt,shape:Kt,skins:Kt},WR=(t,e,r,n)=>{$r(t,r,e);let o={};for(let s of n)t[s]===e&&(t[s]=o);return t.verbose&&console.warn("[scratch] design-system family",r,"resolved to a host object; parked it and allocated a plain bucket"),o},sy=(t,e,r)=>{let n=A(),o=Oa(t),s=o.toLowerCase(),i=n[o]||n[s]||n[t],a=ur(i)?WR(n,i,s,[o,s,t]):i,c=nu[o]||nu[s];if(c)try{let l=c(e,r);return a&&(a[r]=l),a}catch(l){n.verbose&&console.warn("Error setting",s,"value",e,r,l)}if(!c){let l=a||(n[s]={});return l[r]=e,l}n.verbose&&console.warn("Can not find",s,"method in scratch")},iy=(t,e)=>{let r=A(),n=t.toLowerCase();return ur(e)?($r(r,n,e),r.verbose&&console.warn("[scratch] ignoring host object passed as the",n,"design-system family"),r[n]||r[t]):e==null?(r.verbose&&console.warn("[scratch] skipping empty design-system family",n),r[n]||r[t]):(Object.keys(e).sort((s,i)=>{let a=v(e[s])||P(e[s])?1:0,c=v(e[i])||P(e[i])?1:0;return a-c}).forEach(s=>{try{return sy(n,e[s],s)}catch(i){r.verbose&&console.warn("Error setting",n,"value",e[s],s,i)}}),r[n]||r[t])},ou=(t,e)=>{let r=e||A();r.globalTheme=t;let o=xo(r)||(typeof document<"u"?document:null),s=o&&o.defaultView||(typeof window<"u"?window:null);if(o){let a=r.themeRoot||o.documentElement,c=t&&t!=="auto";if(a[is]=r,c)as(r),a.setAttribute("data-theme",t),r.resolvedTheme=t,t==="dark"||t==="light"?a.style.colorScheme=t:a.style.colorScheme="light dark";else if(s&&s.matchMedia){let l=u=>{let d=u.matches?"dark":"light";a.setAttribute("data-theme",d),r.resolvedTheme=d},f=s.matchMedia("(prefers-color-scheme: dark)");l(f),a.style.colorScheme="light dark",QS(r,f,l)}else as(r),a.setAttribute("data-theme","light"),r.resolvedTheme="light",a.style.colorScheme="light"}let i=r.varPrefix?`--${r.varPrefix}-theme-`:"--theme-";for(let a in r.cssVars)a.startsWith(i)&&delete r.cssVars[a];for(let a in r.cssMediaVars)delete r.cssMediaVars[a];if(o&&r.cssVars){let a=r.scopeSelector||":root",c=o.styleSheets;for(let l=0;l<c.length;l++)try{let f=c[l].cssRules;for(let u=0;u<f.length;u++)if(f[u].selectorText===a){for(let d in r.cssVars)f[u].style.setProperty(d,r.cssVars[d]);return r}}catch{}}return r},qR={},Xn=(t,e=qR)=>{let r=e.config||A(),{version:n,verbose:o,useVariable:s,useReset:i,useSvgSprite:a,useFontImport:c,useIconSprite:l,globalTheme:f,themeRoot:u,useDocumentTheme:d,useDefaultConfig:g,semanticIcons:p,hoverMedia:h,files:m,assets:_,...x}=t;e.newConfig&&(r=zf(e.newConfig)),fr(x.document)&&(r.__domDocument=x.document,delete x.document),fr(r.document)&&(r.__domDocument||(r.__domDocument=r.document),r.document={}),m!==void 0&&(r.files=m),_!==void 0&&(r.assets=_),o!==void 0&&(r.verbose=o),s!==void 0&&(r.useVariable=s),i!==void 0&&(r.useReset=i),c!==void 0&&(r.useFontImport=c),a!==void 0&&(r.useSvgSprite=a),l!==void 0&&(r.useIconSprite=l),d!==void 0&&(r.useDocumentTheme=d),f!==void 0&&(r.globalTheme=f),u!==void 0&&(r.themeRoot=u),t.useThemeSuffixedVars!==void 0&&(r.useThemeSuffixedVars=t.useThemeSuffixedVars),g!==void 0&&(r.useDefaultConfig=g),p!==void 0&&(r.semanticIcons=p),h!==void 0&&(r.hoverMedia=h),r.verbose&&console.log(r);let b=xo(r)||(typeof document<"u"?document:null),w=b&&b.defaultView||(typeof window<"u"?window:null),S=b&&(r.themeRoot||b.documentElement);if(S&&typeof S.setAttribute=="function")if(r.globalTheme&&r.globalTheme!=="auto")as(r),S.setAttribute("data-theme",r.globalTheme),r.resolvedTheme=r.globalTheme,S[is]=r,r.globalTheme==="dark"||r.globalTheme==="light"?S.style.colorScheme=r.globalTheme:S.style.colorScheme="light dark";else if(S[is]&&S[is]!==r&&S.hasAttribute("data-theme"))as(r),r.resolvedTheme=S.getAttribute("data-theme");else if(w&&w.matchMedia){let M=rt=>{let Rt=rt.matches?"dark":"light";S.setAttribute("data-theme",Rt),r.resolvedTheme=Rt},U=w.matchMedia("(prefers-color-scheme: dark)");M(U),S.style.colorScheme="light dark",S[is]=r,QS(r,U,M)}else as(r),S.setAttribute("data-theme","light"),r.resolvedTheme="light",S.style.colorScheme="light",S[is]=r;r.__svgCache||(r.__svgCache={}),ts(x);let C=Object.keys(x).filter(T=>!T.startsWith("__")),O=new Set(C);if(C.forEach(T=>{let M=T.toLowerCase();M!==T&&O.has(M)&&at(x[M],x[T],ue)}),C.map(T=>{let M=T.toLowerCase();if(!(M!==T&&O.has(M)))return iy(T,x[T])}),r.varPrefix&&(r.typography&&(r.typography.varPrefix=r.varPrefix),r.spacing&&(r.spacing.varPrefix=r.varPrefix),r.timing&&(r.timing.varPrefix=r.varPrefix)),x.typography)try{Ga()}catch(T){r.verbose&&console.warn("Error applying typography sequence",T)}if(x.spacing)try{Va()}catch(T){r.verbose&&console.warn("Error applying spacing sequence",T)}if(x.timing)try{Za()}catch(T){r.verbose&&console.warn("Error applying timing sequence",T)}try{ec()}catch(T){r.verbose&&console.warn("Error applying skins",T)}Ja();let L=tc();return L&&(r.reset=L),r};var ls=new Map,u0=null,cy=null,KR=null;function ic(t){t.batchAtomicCss&&(cy=t.batchAtomicCss),t.compoundCssClass&&(KR=t.compoundCssClass)}var GR=new Set,e0=t=>!!(t&&t.documentElement&&typeof t.createElement=="function"&&t.head!==void 0);function py(t){try{let e=A();e&&(e.__domDocument=t)}catch{}t&&GR.add(t)}function Jn(){try{let t=A();if(t){if(e0(t.__domDocument))return t.__domDocument;if(e0(t.document))return t.document}}catch{}return typeof document<"u"?document:null}var ee={atomic:0,variable:0,global:0,keyframes:0,duplicate:0,invalid:0,dropped:0};function fu(){return{...ee}}function hy(){for(let t in ee)ee[t]=0;cu=!1}var cu=!1,au=(t,e)=>`${t} ${e}${t===1?"":"s"}`;function YR(t){let e=Date.parse(t);if(!isFinite(e))return"";let r=Math.floor((Date.now()-e)/864e5);return r<1?" (today)":` (${au(r,"day")} ago)`}function XR(){try{let t=iP();if(!t.length)return-1;let e=0;for(let r=0;r<t.length;r++)e+=t[r].cssRules?t[r].cssRules.length:0;return e}catch{return-1}}function ZR(t,e){if(cu)return!1;cu=!0;let r="n/a \u2014 running from src/ (unbuilt), so no dist is in play",n="this IS the source",o="@symbo.ls/css";return console.error(`[@symbo.ls/css] CSS EMIT FAILURE (${t}) \u2014 the engine emitted ${au(ee.variable,"variable rule")} and ${au(ee.atomic,"atomic rule")}, while the design system held ${au(e,"CSS variable")}.
41
+ src: ${i};`},Wr=(t,e,r,n)=>`@font-face {${Aa(t,e,r,n)}
42
+ }`,Vn=(t,e,r)=>Object.keys(e).map(o=>{let{url:s,fontWeight:i,fontStyle:a,fontDisplay:c,fontStretch:l,unicodeRange:f}=e[o],u=Array.isArray(s)?s.map(d=>ke(d,r)||d):ke(s,r)||s;return Aa(t,u,i,{fontStyle:a,fontDisplay:c,fontStretch:l,unicodeRange:f})}),_m=t=>Object.keys(t).map(r=>Vn(r,t[r].value)),jf=(t,e,r)=>{if(e&&e.isVariable){let s=ke(e.url,r)||e.url;return Xo(s)?Zo(s):Wr(t,s,e.fontWeight,{fontStretch:e.fontStretch,fontDisplay:e.fontDisplay||"swap",unicodeRange:e.unicodeRange})}if(e[0])return Vn(t,e,r).map(Nf);let o=Array.isArray(e.url)?e.url.map(s=>ke(s,r)||s):ke(e.url,r)||e.url;return Wr(t,o,e.fontWeight,{fontStyle:e.fontStyle,fontDisplay:e.fontDisplay,fontStretch:e.fontStretch,unicodeRange:e.unicodeRange})},Ta=(t,e)=>Object.keys(t).map(n=>jf(n,t[n].value,e));D();D();D();D();var Jo={};$(Jo,{animation:()=>Mm,breakpoints:()=>Im,class:()=>Vm,color:()=>Am,devices:()=>$m,document:()=>CS,font:()=>wm,fontFace:()=>vm,fontFamily:()=>Sm,fontFamilyTypes:()=>km,gradient:()=>Tm,grid:()=>Bm,icons:()=>Pm,media:()=>Cm,reset:()=>ES,semanticIcons:()=>Dm,sequence:()=>br,shadow:()=>Rm,shape:()=>Hm,sizes:()=>zm,skins:()=>Wm,spacing:()=>Em,svg:()=>Fm,svgData:()=>Nm,templates:()=>jm,theme:()=>Om,timing:()=>Lm,typography:()=>Oa,unit:()=>xm,vars:()=>Um});var br={"minor-second":1.067,"major-second":1.125,"minor-third":1.2,"major-third":1.25,"perfect-fourth":1.333,"augmented-fourth":1.414,"perfect-fifth":1.5,"minor-sixth":1.6,phi:1.618,"major-sixth":1.667,"square-root-3":1.732,"minor-seventh":1.778,"major-seventh":1.875,octave:2,"square-root-5":2.23,"major-tenth":2.5,"major-eleventh":2.667,"major-twelfth":3,pi:3.14,"double-octave":4};var xm={default:"em"};var uR={browserDefault:16,base:16,type:"font-size",ratio:br["minor-third"],range:[-3,12],h1Matches:6,lineHeight:1.5,subSequence:!0,mediaRegenerate:!1,unit:"em",templates:{},sequence:{},scales:{},vars:{}},Oa=uR;var wm={};var Sm={},km={"sans-serif":"Helvetica, Arial, sans-serif, --system-default",serif:"Times New Roman, Georgia, serif, --system-default",monospace:"Courier New, monospace, --system-default"},vm={};var Cm={tv:"(min-width: 2780px)",light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)",print:"print"};var dR={base:Oa.base,type:"spacing",ratio:br.phi,range:[-5,15],subSequence:!0,mediaRegenerate:!1,unit:"em",sequence:{},scales:{},vars:{}},Em=dR;var Am={},Tm={};var Om={};var Rm={};var Pm={},Dm={};var pR={default:150,base:150,type:"timing",ratio:br["perfect-fourth"],range:[-3,12],mediaRegenerate:!1,unit:"ms",sequence:{},scales:{},vars:{}},Lm=pR;var CS={};var Im={screenL:1920,screenM:1680,screenS:1440,tabletL:1366,tabletM:1280,tabletS:1024,mobileL:768,mobileM:560,mobileS:480,mobileXS:375},$m={screenXXL:[2560,1440],screenXL:[2240,1260],screenL:[1920,1024],screenM:[1680,1024],screenS:[1440,720],tabletL:[1366,926],tabletM:[1280,768],tabletS:[1024,768],mobileL:[768,375],mobileM:[560,768],mobileS:[480,768],mobileXS:[375,768]};var Mm={};var Fm={},Nm={};var jm={};var hR={},Bm=hR;var Vm={};var ES={},Um={},zm={},Hm={},Wm={};var zf={},Hf={},ue=new Set,Bf=Jo,Vf={},Pa=t=>t.replace(/_([a-z])/g,(e,r)=>r.toUpperCase());for(let t in Bf){let e=t.toLowerCase();Vf[e]=Bf[t];let r=Pa(e);r!==e&&(Vf[r]=Bf[t]),e!==t&&(Vf[t]=Bf[t])}var Un={verbose:!1,useVariable:!0,useReset:!0,globalTheme:"auto",cssVars:zf,cssMediaVars:Hf,CSS_VARS:zf,CSS_MEDIA_VARS:Hf,cssSkinVars:{},cssSkinFallback:{},_scratchConfig:!0,...Vf},Qo=(t,e)=>{if(!t)return null;if(t.__globalThemeSignal)return Tt(e)&&t.__globalThemeSignal.set(e),t.__globalThemeSignal;let r=Tt(e)?e:t.globalTheme,n=ai(Tt(r)?r:"auto");return Object.defineProperty(t,"globalTheme",{get(){return n.get()},set(o){n.set(o)},enumerable:!0,configurable:!0}),Object.defineProperty(t,"__globalThemeSignal",{value:n,enumerable:!1,configurable:!0,writable:!0}),n},AS=t=>t?Qo(t):null,ts=(t,e)=>{if(!t)return null;if(t.__resolvedThemeSignal)return Tt(e)&&t.__resolvedThemeSignal.set(e),t.__resolvedThemeSignal;let r=Tt(e)?e:t.resolvedTheme,n=ai(Tt(r)?r:null);return Object.defineProperty(t,"resolvedTheme",{get(){return n.get()},set(o){n.set(o)},enumerable:!1,configurable:!0}),Object.defineProperty(t,"__resolvedThemeSignal",{value:n,enumerable:!1,configurable:!0,writable:!0}),n},TS=t=>t?ts(t):null;Qo(Un);ts(Un);var Uf=lt(Un),fe={active:"0",0:Un},OS=t=>(Tt(t)&&(fe.active=t),fe[t||fe.active]),Ra=[],ct=t=>{t&&t._scratchConfig&&Ra.push(t)},it=()=>{Ra.pop()},A=t=>Ra.length?Ra[Ra.length-1]:fe[t||fe.active]||Un,Wf=t=>{if(v(t))return fe.active="1",fe[1]=at(t,lt(Uf),ue),es(fe[1]),Qo(fe[1]),ts(fe[1]),t},gR=["useReset","useFontImport","useIconSprite","useSvgSprite","useDocumentTheme","useDefaultIcons","useDefaultConfig"],mR=["useVariable","globalTheme","verbose"],yR=[["fontfamily","fontFamily","font_family"],["fontfamilytypes","fontFamilyTypes"],["semanticicons","semanticIcons"],["svgdata","svgData"]],es=t=>{for(let e of yR){let r;for(let n of e){let o=t[n];v(o)&&(r=r?at(r,o,ue):o)}if(r)for(let n of e)v(t[n])&&(t[n]=r)}},Da=(t,e,{cleanBase:r=!1}={})=>{let n=r?null:A(),o=lt(!r&&n&&n._scratchConfig?n:Uf);for(let i of gR)delete o[i];for(let i of mR)Object.prototype.hasOwnProperty.call(Uf,i)?o[i]=Uf[i]:delete o[i];let s=at(e||{},o,ue);return s.cssVars={},s.cssMediaVars={},s.CSS_VARS=s.cssVars,s.CSS_MEDIA_VARS=s.cssMediaVars,s.cssSkinVars={},s.cssSkinFallback={},s._scratchConfig=!0,es(s),Qo(s),ts(s),t&&(fe[t]=s),s};var er={"-6":"U","-5":"V","-4":"W","-3":"X","-2":"Y","-1":"Z",0:"A",1:"B",2:"C",3:"D",4:"E",5:"F",6:"G",7:"H",8:"I",9:"J",10:"K",11:"L",12:"M",13:"N",14:"O",15:"P",16:"Q",17:"R",18:"S",19:"T"},Km=(t,e)=>{let{key:r,variable:n,value:o,scaling:s,index:i,scalingVariable:a}=t;e.sequence[r]={key:r,decimal:~~(o*100)/100,val:~~o,scaling:s,index:i,scalingVariable:a,variable:n},e.scales[r]=s;let c=RS.has(e.unit)?"rem":e.unit;e.vars[n]=s+c},_r=t=>{if(!t.includes("("))return t;let e=t.trim(),r=e.indexOf("("),n=e.slice(0,r),o=0,s=-1;for(let i=r;i<e.length;i++){let a=e[i];if(a==="(")o++;else if(a===")"&&(o--,o===0)){s=i;break}}return s===-1||/\s/.test(n)||e.slice(s+1).trim()!==""?[void 0,t]:[n,e.slice(r+1,s)]},qm="\0",bR=(t,e)=>{let r="",n=0,o="";for(let s of t){if(n===0&&s!=="("){r+=s;continue}o+=s,s==="("?n++:s===")"&&(n--,n===0&&(r+=qm+e.length+qm,e.push(o),o=""))}return r+o},_R=(t,e)=>t.indexOf(qm)===-1?t:t.replace(/\u0000(\d+)\u0000/g,(r,n)=>e[Number(n)]),xR=/^(calc|min|max|clamp)\((.*)\)$/,wR=(t,e)=>{let r=xR.exec(t);return r?`${r[1]}(${Fa(r[2],e)})`:t.indexOf("(")!==-1?t:zn(t,e)},RS=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),La=(t,e)=>{let{base:r,type:n,unit:o}=e,s=RS.has(o)?"rem":o,i=(bn(s)?1:r)+s;if(t===0)return i;let c="--"+(e.varPrefix?e.varPrefix+"-":"")+(n&&n.replace(".","-")),l=`${c}-ratio`;if(t>0){let f=er[t-1];return`calc(var(${c}-${f}) * var(${l}))`}if(t<0){let f=er[t+1],u=Math.abs(t),d=Math.pow(PS,2*u),g=er[u];return g?`max(calc(var(${c}-${f}) / var(${l})), calc(var(${c}-${g}) / ${d.toFixed(4)}))`:`calc(var(${c}-${f}) / var(${l}))`}},qf=(t,e,r,n)=>{let{type:o}=n,i=t===2&&e.length===2?t+1:t,l=`${"--"+(n.varPrefix?n.varPrefix+"-":"")+(o&&o.replace(".","-"))}-sub-ratio-`;return`calc(var(${r}) * var(${l+i}))`},Ia=(t,e)=>{let n=(t*e-t)/1.618,o=t*e-n,s=t+n,i=(o+s)/2;return[o,i,s]},$a=(t,e)=>Ia(t,e).map(r=>r/t),Ma=(t,e)=>{let{key:r,base:n,value:o,ratio:s,variable:i,index:a}=t,l=~~(o*s)-~~o,f,[u,d,g]=Ia(o,s);l>16?f=[u,d,g]:f=[u,g],f.forEach((p,h)=>{let m=~~(p/n*1e3)/1e3,y=i+(h+1),x=a+(h+1)/10,b=qf(h+1,f,i,e),_={key:r+(h+1),variable:y,value:p,scaling:m,scalingVariable:b,index:x};Km(_,e)})},PS=1.618,SR=(t,e,r)=>{if(t>=0)return e*Math.pow(r,t);let n=Math.abs(t),o=e*Math.pow(r,t),s=e*Math.pow(r,n)/Math.pow(PS,2*n);return Math.max(o,s)},te=t=>{let{type:e,base:r,ratio:n,range:o,subSequence:s}=t,i=Math.abs(o[0])+Math.abs(o[1]),c="--"+(t.varPrefix?t.varPrefix+"-":"")+(e&&e.replace(".","-"))+"-";for(let l=0;l<=i;l++){let f=o[1]-l,u=er[f],d=SR(f,r,n),g=~~(d/r*100)/100,p=c+u,h=La(f,t),m={key:u,variable:p,value:d,base:r,scaling:g,scalingVariable:h,ratio:n,index:f};Km(m,t),s&&Ma(m,t)}return t},Gm=(t,e=0)=>{let{type:r,base:n,ratio:o,subSequence:s}=t,i=k(e)?e:er[e],a=k(e)?Object.entries(er).find(([,m])=>m===e)?.[0]:e;if(!i)return console.warn(`Position ${e} is out of range in numToLetterMap`),null;let c={sequence:{},scales:{},vars:{},...t},l=n*Math.pow(o,a),f=~~(l/n*100)/100,g="--"+(t.varPrefix?t.varPrefix+"-":"")+(r&&r.replace(".","-"))+"-"+i,p=La(a,t),h={key:i,variable:g,value:l,base:n,scaling:f,scalingVariable:p,ratio:o,index:a};return Km(h,c),s&&Ma(h,c),c},zn=(t="A",e)=>{let r=A(),{unit:n}=r;if(k(t)&&_t(t))return`var(${t})`;if(k(t)&&/^(?:env|var|calc|min|max|clamp)\(/.test(t.trim()))return t;if(k(t)){let b=r.sizes;if(b){let _=b[t]||b[t.toLowerCase()];if(_!==void 0)return t.slice(0,1)==="-"?`calc(${_} * -1)`:_}}let{sequence:o,unit:s=n.default,useVariable:i}=e,a=/^-?[a-zA-Z]/i,c=a.test(t);if(ci(t)||!c||["none","auto","max-content","min-content","fit-content","inherit","initial","unset","revert","revert-layer"].includes(t))return t;let d=`--${e.varPrefix?e.varPrefix+"-":""}${wa(e.type.replace(".","-"))}-`,g=t.toUpperCase(),p=g.slice(0,1)==="-"?"-":"",h=p?g.slice(1):g,m="";h.includes("_")&&(m="_"+h.split("_")[1].toLowerCase(),h=h.split("_")[0]);let y=b=>a.test(b)?`var(${d}${b}${m})`:b;if(h.includes("+")){let[b,_]=h.split("+"),w=`${y(b)} + ${y(_)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}else if(h.includes("*")){let[b,_]=h.split("*"),w=`${y(b)} * ${y(_)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}else if(h.includes("-")){let[b,_]=h.split("-"),w=`${y(b)} - ${y(_)}`;return p?`calc((${w}) * -1)`:`calc(${w})`}if(!o[h]&&h.length===2&&(r.verbose&&console.warn(h,"- value is not found because `subSequence` is set to false"),h=h.slice(0,1)),i||r.useVariable){let b=`var(${d}${h}${m})`;return p?`calc(${b} * -1)`:b}let x=o?o[h]:null;if(!x){if(console.warn("can't find",o,h),gt())throw new Error(`[smbls] Unresolvable design-system token "${t}"`+(e.type?` for sequence "${e.type}"`:"")+" \u2014 not a registered `sizes` name and not a valid spacing/typography/timing sequence letter. The CSS property using it would silently be dropped in production. Register the token in `designSystem/sizes.js` (or the relevant sequence family) or fix the typo.");return}return s==="ms"||s==="s"?p+x.val+s:p+x.scaling+s},Fa=(t,e)=>{if(!["+","-","*","/",","].filter(i=>t.includes(i+" ")).length)return t;let n=/(\s+-\s+|\s*[+*/,]\s*)/,o=[];return bR(t,o).split(n).map(i=>{let a=_R(i,o),c=a.trim();return!c||["+","-","*","/",","].includes(c)?a:wR(c,e)}).join("")},rr=(t,e,r,n)=>{if(typeof t!="string")return A().verbose&&console.warn(e,t,"is not a string"),{[e]:t};if(t==="-"||t==="")return{};if(!n&&t.includes("(")){if(/^(?:env|var)\(/.test(t.trim()))return{[e]:t};let s=_r(t);n=s[0],t=s[1]}return["+","-","*","/",","].filter(s=>t.includes(s+" ")).length?t=Fa(t,r):t=zn(t,r),{[e]:n?`${n}(${t})`:t}},Kf=(t,e)=>er[t-e],Na=t=>{let{h1Matches:e,sequence:r}=t;return new Array(6).fill(null).map((n,o)=>{let s=Kf(e,o);return r[s]})};D();var Ym=(t,e)=>{let r=A(),{cssVars:n}=r;B(t.value)||(n[t.var]=t.value)},ja=(t,e,r)=>{let n=A(),{unit:o}=n,s=e.unit||o.default,{base:i,ratio:a,type:c}=e,f="--"+(e.varPrefix?e.varPrefix+"-":"")+(c&&c.replace(".","-"));t[`${f}-base`]=i,t[`${f}-unit`]=s;let u=`${f}-ratio`;t[u]=a;let[d,g,p]=$a(i,a);t[`${f}-sub-ratio-1`]=`calc(var(${f}-ratio) * ${d/a})`,t[`${f}-sub-ratio-2`]=`calc(var(${f}-ratio) * ${g/a})`,t[`${f}-sub-ratio-3`]=`calc(var(${f}-ratio) * ${p/a})`},DS=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),xr=(t,e={})=>{let r=A(),{unit:n,timing:o,cssVars:s}=r,i=t.unit||n.default,a=DS.has(i)?"rem":i,{mediaRegenerate:c,sequence:l,scales:f}=t;c||ja(s,t,e);for(let u in l){let d=l[u],g=(t.type===o.type?l[u].val:f[u])+a;if(!c){s[d.variable+"_default"]=g,s[d.variable]=d.scalingVariable;continue}e.useDefault===!1?s[d.variable]=g:(s[d.variable+"_default"]=g,s[d.variable]=`var(${d.variable+"_default"})`)}},qr=(t,e,r={})=>{let n=A(),{unit:o,media:s,cssVars:i}=n,a=e.slice(1),c=t[e],l=c.unit||t.unit||o.default,f=DS.has(l)?"rem":l,{mediaRegenerate:u}=t,{sequence:d,scales:g}=c,p=s[a];if(!p&&n.verbose&&console.warn("Can't find media query ",p),!u){let h=i[`@media ${p}`];h||(h=i[`@media ${p}`]={}),ja(h,c,r);let m=t.unit||o.default;if(f!==m&&d)for(let y in d){let x=d[y],b=g[y]+f;h[x.variable+"_default"]=b,h[x.variable]=b}return}for(let h in d){let m=d[h],y=(bn(f)?g[h]:d[h].val)+f;!p&&n.verbose&&console.warn("Can't find query ",p);let x=i[`@media ${p}`];x||(x=i[`@media ${p}`]={}),x[m.variable]=`var(${m.variable+"_"+a})`,i[m.variable+"_"+a]=y}};D();var IS=An(),Ba=t=>{let e=A(),r="";for(let n in t)e.__svgCache[n]||(e.__svgCache[n]=!0,r+=t[n]);return r},kR=t=>{let e=t&&(t.default||t);if(!k(e))return IS&&console.warn("parseRootAttributes:",e,"is not a string"),{};let r=e.match(/<svg\s+(.*?)>/);if(!r||!r[1])return{};let o=r[1].match(/(\S+)=["']?((?:.(?!["']?\s+(?:\S+)=|\s*\/?[>"']))+.)["']?/gm);return o?o.reduce((s,i)=>{let[a,c]=i.split("=");return s[a]=c.replace(/['"]/g,""),s},{}):{}},vR=(t,e)=>{let r=[];if(t.replace(/id="([^"]*)"/g,(o,s)=>(r.push(s),o)),!r.length)return t;let n=t;for(let o of r){let s=o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),i=`${e}-${o}`;n=n.replace(new RegExp(`id="${s}"`,"g"),`id="${i}"`).replace(new RegExp(`url\\(#${s}\\)`,"g"),`url(#${i})`).replace(new RegExp(`xlink:href="#${s}"`,"g"),`xlink:href="#${i}"`).replace(new RegExp(`href="#${s}"`,"g"),`href="#${i}"`)}return n},LS=new Set,Va=(t,e)=>{let r=e&&e.default?e.default:e;if(!k(r))return IS&&!LS.has(t)&&(LS.add(t),console.warn("convertSvgToSymbol:",t,"is not a string")),"";e=r;let n=e.match(/^<symbol\b[^>]*\bid="([^"]*)"/);if(n){let u=n[1];return u===t?e:e.replace(`id="${u}"`,`id="${t}"`)}let o=kR(e),{width:s,height:i}=o,a=o.viewBox||`0 0 ${s||24} ${i||24}`,f=vR(e,t).replace("<svg",`<symbol id="${t}" xmlns="http://www.w3.org/2000/svg" viewBox="${a}"`);return f=f.replace(/^<symbol\b[^>]*>/,u=>u.replace(/\s(width|height)="[^"]*"/g,"")),f=f.replace("</svg","</symbol"),f=AR(f),f},CR="line|circle|ellipse|rect|polyline|polygon|path|stop|use|image",ER=new RegExp(`<(${CR})\\b([^>]*?)\\s*/>`,"g"),AR=t=>t.replace(ER,"<$1$2></$1>");var is={};$(is,{STANDARD_SCHEME_QUERIES:()=>Yf,__resetSkinWarnings:()=>cy,appendSVGSprite:()=>ec,appendSvgIconsSprite:()=>Gn,applyDocument:()=>tc,applyHeadings:()=>Jf,applyReset:()=>rc,applySkins:()=>nc,applySpacingSequence:()=>za,applyTimingSequence:()=>Qa,applyTypographySequence:()=>Xa,buildSkinVarStyles:()=>Yn,checkIfBoxSize:()=>Ua,getColor:()=>ot,getFontFamily:()=>Ya,getFontSizeByKey:()=>Za,getMediaColor:()=>Mt,getMediaTheme:()=>Ee,getSafeInk:()=>Xf,getSafeInkInfo:()=>Jm,getShadow:()=>Wa,getShapeByKey:()=>Ja,getSpacingBasedOnRatio:()=>Ce,getSpacingByKey:()=>Ct,getTheme:()=>ry,getTimingByKey:()=>pe,getTimingFunction:()=>Ae,isPlainColor:()=>Yr,quietColorProbe:()=>Hn,resolveBorderValue:()=>de,resolveColorRgb:()=>Wn,resolveShadowValue:()=>qn,runThroughMedia:()=>Zf,schemeGuardSelector:()=>Zr,schemeMediaQuery:()=>Xr,setAdaptiveSchemeVar:()=>Jr,setColor:()=>Gr,setFont:()=>Ga,setFontFamily:()=>os,setGradient:()=>rs,setMediaTheme:()=>ns,setSVG:()=>ss,setShadow:()=>Qr,setSvgIcon:()=>Kn,setTheme:()=>Ka,splitSpacedValue:()=>Ha});D();var Yf={light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)"},Xr=(t,e)=>{let r=e.media&&e.media[t]||Yf[t];return r?"@media "+(r==="print"?`${r}`:`screen and ${r}`):null},Zr=t=>{let e=t.scopeSelector||":root";return`${e===":root"?":root:not([data-theme])":`:root:not([data-theme]) ${e}:not([data-theme])`} &`},ve=new Set,NS=new Set(["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","green","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"]),TR=/^(?:#[0-9a-f]{3,8}$|(?:rgba?|hsla?|hwb|lab|lch|oklab|oklch|color|color-mix)\()/i,OR=/gradient\(|url\(|image-set\(|var\(/i,RR=new Set(["transparent","currentColor","currentcolor"]),Yr=t=>{if(!k(t))return!1;let e=t.trim();return OR.test(e)?!1:TR.test(e)?!0:NS.has(e)||RR.has(e)},Gf=new Set,$S=t=>{if(!t)return!1;let{color:e,gradient:r}=t;return!!(v(e)&&Object.keys(e).length||v(r)&&Object.keys(r).length)},MS=new Set,Xm=0,Hn=t=>{Xm++;try{return t()}finally{Xm--}},PR=(t,e)=>{if(!k(t)||t.indexOf(" ")===-1)return null;let r=t.replace(/\s+/g,""),n=Ut(r);if(!n||n.passthrough||n.cssVar)return null;let{color:o,gradient:s}=e;return!o[n.name]&&!s[n.name]?null:r},Zm=(t,e,r)=>{let n=PR(t,r);if(n){if(!MS.has(t)){MS.add(t);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color token \`${t}\` has a space before its alpha/tone modifier${i} \u2014 did you mean \`${n}\`? The space form never resolves, so the atomic class it mints carries no CSS value and paints invisibly. Dropped rather than shipped invisible.`)}return}let o=Ut(t);if(o&&o.name&&!o.passthrough&&!o.cssVar&&(o.alpha!==void 0||o.tone!==void 0)&&$S(r)&&!r.color[o.name]&&!r.gradient[o.name]){if(!Xm&&!Gf.has(t)){Gf.add(t);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color token \`${t}\` does not resolve${i} \u2014 \`${o.name}\` is not in the palette. Dropped rather than emitted as a raw value, which is invalid CSS the browser discards silently. Define it in designSystem/color.js or use a palette token.`)}return}let s=k(e)?e.toLowerCase():"";if(!NS.has(s)||!$S(r))return t;if(!Gf.has(s)){Gf.add(s);let i=r&&r.name?` (design system \`${r.name}\`)`:"";console.warn(`[scratch] color \`${t}\` is a CSS named colour that is not in the palette${i}. Dropped rather than emitted as a raw browser colour, which renders theme-blind and can be unreadable ("looks designed", so it ships unnoticed). Define it in designSystem/color.js or use a palette token.`)}},jS=(t,e,r)=>{let n=e!==void 0?e:1;if(!r)return`rgb(from ${t} r g b / ${n})`;if(r.charCodeAt(0)===43||r.charCodeAt(0)===45){let s=parseFloat(r),i=s<0?"-":"+",a=Math.abs(s);return`rgb(from ${t} calc(r ${i} ${a}) calc(g ${i} ${a}) calc(b ${i} ${a}) / ${n})`}return`hsl(from ${t} h s ${r}% / ${n})`},ot=(t,e,r)=>{let n=r||A();if(!k(t)){n.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;e&&t[e]&&(t=t[e]);let o,s,i;if(P(t))[o,s,i]=t;else{let u=Ut(t);if(!u){let{color:d,gradient:g}=n,p=g[t]||d[t];return p?(e&&p[e]&&(p=p[e]),n.useVariable?`var(${p.var})`:p.value):Zm(t,t,n)}if(u.passthrough)return u.passthrough;if(u.cssVar)return`var(${u.cssVar})`;o=u.name,s=u.alpha,i=u.tone}let{color:a,gradient:c}=n,l=a[o]||c[o];if(!l)return Zm(t,o,n);if(e)if(l[e]!==void 0)l=l[e];else if(P(l)){let u=e.charCodeAt(0)===64?e.slice(1):e;u==="dark"?l=l[1]!==void 0?l[1]:l[0]:(u!=="light"&&n.verbose&&console.warn(t," - array-form color tokens only support light/dark; falling back to the light slot for scheme",e),l=l[0])}else n.verbose&&console.warn(t," - does not have ",e);if(k(l)){if(ve.has(o))return l;ve.add(o);try{return ot(l,null,r)}finally{ve.delete(o)}}let f=l.rgb;if(!f){let u=n.useVariable?`var(${l.var})`:l.value;return(s||i)&&u?jS(u,s,i):u}return i&&!l[i]&&(f=tr(f,i),l[i]={rgb:f,var:`${l.var}-${i}`}),l[i]&&(f=l[i].rgb),s?`rgba(${f}, ${s})`:i?`rgba(${f}, ${l.alpha!==void 0?l.alpha:1})`:n.useVariable?`var(${l.var})`:l.value!==void 0?l.value:`rgb(${f})`},FS=t=>{let e=Se(t);return!e||e.length<3||e[0]===0&&e[1]===0&&e[2]===0&&e[3]===0&&t.toLowerCase()!=="transparent"?null:{rgb:[e[0],e[1],e[2]],alpha:e[3]!==void 0?e[3]:1}},DR=(t,e)=>{if(!e)return t;let r=t.rgb;if(e.tone){let o=tr(r,e.tone);r=k(o)?o.split(",").map(s=>parseFloat(s.trim())):o}let n=e.alpha!==void 0?parseFloat(e.alpha):t.alpha;return{rgb:r,alpha:n}},Wn=(t,e,r)=>{let n=e||A();if(!k(t))return null;let o=Ut(t);if(o){if(o.passthrough){let d=Se(o.passthrough);return d&&d.length>=3?{rgb:[d[0],d[1],d[2]],alpha:d[3]!==void 0?d[3]:1}:null}if(o.cssVar)return null}let s=o?o.name:t,{color:i,gradient:a}=n,c=i[s]||a[s];if(!c)return FS(t);if(k(c)){let d;if(ve.has(s))d=FS(c);else{ve.add(s);try{d=Wn(c,n,r)}finally{ve.delete(s)}}return d?DR(d,o):null}if(c.rgb===void 0&&v(c)){let d=`@${r||"light"}`;c=c[d]!==void 0?c[d]:c["@light"]}if(!c||c.rgb===void 0)return null;let l=c.rgb;o&&o.tone&&(l=tr(l,o.tone));let f=k(l)?l.split(",").map(d=>parseFloat(d.trim())):l,u=o&&o.alpha!==void 0?parseFloat(o.alpha):c.alpha!==void 0?c.alpha:1;return{rgb:f,alpha:u}},BS=t=>v(t)&&t.value!==void 0&&(t.rgb!==void 0||t.var!==void 0),VS=t=>{if(!v(t)||t.value!==void 0)return null;let e=[];for(let r in t)if(r!=="var"){if(r.charCodeAt(0)!==64||!BS(t[r]))return null;e.push(r.slice(1))}return e.length?e:null},LR=t=>k(t&&t.var)&&VS(t)!==null,IR=(t,e,r,n,o)=>{let s=VS(e);if(!s)return;if(k(e.var)){let c=`var(${e.var})`;return r||n?jS(c,r,n):c}if(s.length!==2||!s.includes("light")||!s.includes("dark"))return;let i=ot(t,"@light",o),a=ot(t,"@dark",o);if(!(!Yr(i)||!Yr(a)))return i===a?i:`light-dark(${i}, ${a})`},Mt=(t,e,r)=>{let n=r||A();if(e||(e=n.globalTheme==="auto"?null:n.globalTheme),!k(t)){n.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;let o,s,i;if(P(t))o=t[0];else{let u=Ut(t);if(u){if(u.passthrough)return u.passthrough;if(u.cssVar)return`var(${u.cssVar})`;o=u.name,s=u.alpha,i=u.tone}else o=t}let{color:a,gradient:c}=n,l=a[o]||c[o],f=v(l);if(f&&l.value)return ot(t,`@${e}`,r);if(f){if(n.useVariable&&l.var)return s||i?ot(t,null,r):`var(${l.var})`;if(e){if(!n.useVariable&&a[o]===l){let u=IR(t,l,s,i,r);if(u!==void 0)return u}return ot(t,`@${e}`,r)}else{let u={},d=Zr(n);for(let g in l){if(g.charCodeAt(0)!==64)continue;let p=g.slice(1),h=ot(t,g,r);if(h!==void 0&&(u[`[data-theme="${p}"] &`]=h,p==="light"||p==="dark")){let m=Xr(p,n);if(!m)continue;u[m]={[d]:h}}}return u}}else return Zm(t,o,n)},Jr=(t,e,r,n)=>{let s=`--${n.varPrefix?n.varPrefix+"-":""}${e}-${r}`,i,a={};for(let c in t){if(c.charCodeAt(0)!==64)continue;let l=c.slice(1),f=t[c],u=f&&(f.value||f);!u||typeof u!="string"||(a[l]=u,(l==="light"||i===void 0)&&(i=u))}if(i!==void 0){n.cssVars[s]=i,n.cssMediaVars||(n.cssMediaVars={});for(let c in a){let l=`[data-theme="${c}"]`;if(n.cssMediaVars[l]||(n.cssMediaVars[l]={}),n.cssMediaVars[l][s]=a[c],c==="light"||c==="dark"){let f=`@media (prefers-color-scheme: ${c})`;n.cssMediaVars[f]||(n.cssMediaVars[f]={}),n.cssMediaVars[f][s]=a[c]}}return t.var=s,s}},Gr=(t,e,r)=>{let n=A();if(BS(t))return n.useVariable&&t.var&&(n.cssVars[t.var]=t.value),t;if(!n.useVariable&&LR(t))return t;if(k(t)&&_t(t)){let h=t.slice(2);if(t=ot(h),!(t.includes("rgb")||t.includes("var")||t.includes("#"))){let m=h.split(" "),y=n.color[m[0]];if(y&&!y.value&&!y.rgb&&(k(y)||P(y)||v(y))&&!ve.has(m[0])){ve.add(m[0]);try{n.color[m[0]]=Gr(y,m[0])}finally{ve.delete(m[0])}y=n.color[m[0]]}if(y&&y.value){let x=y.rgb,b=m[1]!==void 0?m[1]:"1",_=m[2];_&&(x=tr(x,_)),t=`rgba(${x}, ${b})`}else{let x=m[2],b=m[1]!==void 0?m[1]:"1";if(x)try{let _=Se(m[0]);_&&_.length>=3?t=`rgba(${tr(_.slice(0,3).join(", "),x)}, ${b})`:t=m[0]}catch{t=m[0]}else t=m[0]}}}if(P(t)&&(t={"@light":t[0],"@dark":t[1]!==void 0?t[1]:t[0]}),v(t)){let h={};for(let m in t)m!=="var"&&(h[m]=Gr(t[m],e,m.slice(0,1)==="@"?m.slice(1):m));return n.useVariable&&Jr(h,"color",e,n),h}let s=`--${n.varPrefix?n.varPrefix+"-":""}color-${e}`+(r?`-${r}`:""),i=t.value||t;if(k(i)&&!i.includes("(")&&!i.startsWith("#")){let h=Ut(i);if(h&&h.name&&!h.passthrough&&!h.cssVar){let m=n.color[h.name];if(m&&!m.value&&!m.rgb&&(k(m)||P(m)||v(m))&&!ve.has(h.name)){ve.add(h.name);try{n.color[h.name]=Gr(m,h.name)}finally{ve.delete(h.name)}}let y=n.color[h.name];if(y&&y.rgb){let x=y.rgb;h.tone&&(x=tr(x,h.tone));let b=h.alpha!==void 0?parseFloat(h.alpha):y.alpha!==void 0?y.alpha:1;i=`rgba(${x}, ${b})`}}}let a=Se(i),[c,l,f,u=1]=a,d=parseFloat(u.toFixed(2)),g=`${c}, ${l}, ${f}`,p=`rgba(${g}, ${d})`;return n.useVariable&&(n.cssVars[s]=p),{var:s,rgb:g,alpha:d,value:p}},rs=(t,e,r)=>{let n=A();if(v(t)&&t.value!==void 0&&t.var!==void 0)return n.useVariable&&(n.cssVars[t.var]=t.value),t;if(k(t)&&_t(t)&&(t=ot(t.slice(2))),P(t)&&(t={"@light":t[0],"@dark":t[1]!==void 0?t[1]:t[0]}),v(t)){let i={};for(let a in t)a!=="var"&&(i[a]=rs(t[a],e,a.slice(0,1)==="@"?a.slice(1):a));return n.useVariable&&Jr(i,"gradient",e,n),i}let s=`--${n.varPrefix?n.varPrefix+"-":""}gradient-${e}`+(r?`-${r}`:"");return n.useVariable&&(n.cssVars[s]=t.value||t),{var:s,value:t.value||t}};D();var Xf=(t,e,r={},n)=>{let o=n||A(),{min:s=4.5,large:i=!1,scheme:a,meta:c=!1,maxIterations:l=15}=r,f=i?3:s,u=a||(o.globalTheme&&o.globalTheme!=="auto"?o.globalTheme:"light"),d=k(e)?e:String(e),g=Ut(t),p=g&&!g.passthrough&&!g.cssVar?g.name:null,h=(N,J)=>c?{value:N,...J}:N;if(p){let N=o.color[`${p}Safe`];if(N){let J=`${d}@${u}`,z=N[J]!==void 0?N[J]:N[d];if(z!==void 0){let cr=z&&z.rgb!==void 0?o.useVariable&&z.var?`var(${z.var})`:z.value:ot(z,null,o);return h(cr,{ratio:null,deviation:0,derived:!1,overridden:!0})}}}let m=ot(t,u?`@${u}`:null,o),y=Wn(t,o,u),x=Wn(e,o,u);if(!y||!x)return o.verbose&&console.warn("getSafeInk: could not resolve",t,e,"\u2014 returning hue unchanged"),h(m,{ratio:null,deviation:0,derived:!1,overridden:!1,unresolved:!0});let b=jn(x.rgb,x.alpha),_=jn(y.rgb,y.alpha,b),w=Yo(_,b);if(w>=f-.02)return h(m,{ratio:w,deviation:0,derived:!1,overridden:!1});let[S,E,O]=va(y.rgb),[,L,T]=Ca([S,E,O]),M=Fn(b)>.5,U=M?S:1-S,rt=N=>{let J=M?S-N:S+N,z=Math.max(0,Math.min(1,J));return{rgb:Ea(z,L,T),L:z}},Rt=N=>{let{rgb:J}=rt(N),z=jn(J.map(cr=>Math.round(cr)),y.alpha,b);return Yo(z,b)},mt=0,F=U,W=Rt(F)>=f;if(W)for(let N=0;N<l;N++){let J=(mt+F)/2;Rt(J)>=f?F=J:mt=J}else mt=F;let{rgb:yt,L:St}=rt(F),Pt=yt.map(N=>Math.round(N)),G=Rt(F),j=y.alpha<1?`rgba(${Pt.join(", ")}, ${y.alpha})`:`rgb(${Pt.join(", ")})`,nt=Math.abs(St-S)*100;return h(j,{rgb:Pt,ratio:G,startRatio:w,deviation:nt,derived:!0,overridden:!1,reachable:W})},Jm=(t,e,r={},n)=>Xf(t,e,{...r,meta:!0},n);D();D();var $R=t=>{let r=A().spacing||{},n=parseFloat(t.spacingRatio),o={...r,ratio:Number.isFinite(n)?n:r.ratio,sequence:{},scales:{}};return te(o),o},MR=t=>{for(let e in t){let r=t[e];if(!(e.slice(0,1)==="@"))continue;let{type:o,base:s,ratio:i,range:a,subSequence:c,h1Matches:l,unit:f}=t;bt(r,{type:o,base:s,ratio:i,range:a,subSequence:c,h1Matches:l,unit:f,sequence:{},scales:{},templates:{},vars:{}}),te(r),qr(t,e)}},Ua=t=>{let e=t.toLowerCase(),r=e.includes("width")||e.includes("height"),n=e.includes("border")||e.includes("outline");return r&&!n},za=()=>{let t=A(),{spacing:e}=t;te(e),xr(e),MR(e)},FR=t=>{let e=A(),{spacing:r}=e;return!t||!t.sequence?r:Object.keys(t.sequence).length>0?t:te(t)},Ct=(t,e="padding",r,n)=>{let o=FR(r);if(k(t)){if(!n&&/^(?:env|var)\(/.test(t.trim()))return{[e]:t};if(!n&&t.includes("(")){let i=_r(t);n=i[0],t=i[1]}}let s=n?[t]:k(t)&&t.includes("(")?pt(t):Mn(t);if(P(s)){if(s.length>1){let i="";e==="borderWidth"&&(e="border",i="Width");let a={2:["Block","Inline"],3:["BlockStart","Inline","BlockEnd"],4:["BlockStart","InlineEnd","BlockEnd","InlineStart"]},c=(l,f)=>rr(s[f],e+l+i,o,n);return a[s.length].map((l,f)=>c(l,f))}return rr(t,e,o,n)}},Ce=(t,e,r,n)=>{let o=A(),{spacing:s}=o,i=r||t[e];if(!n&&k(i)&&/^(?:env|var)\(/.test(i.trim()))return{[e]:i};if(!n&&k(i)&&i.includes("(")){let a=_r(i);n=a[0],i=a[1]}if(t.spacingRatio){let a=$R(t);return Ct(i,e,a,n)}return Ct(i,e,s,n)},Ha=t=>{let e=r=>{let n=["+","-","*","/"].includes(r),o=So.some(i=>t.includes(i));return n||o?r:r.length<3&&/[A-Z]/.test(r)?r+"_default":r};return t.split(",").map(r=>r.trim()).map(e).join(",").split(" ").map(e).join(" ")};D();var qn=(t,e,r)=>!k(t)||le.test(t)?t:yr(t).map(n=>(n=n.trim(),n.split(/\s+/).map(o=>{if(o=o.trim(),!o)return"";if(o.startsWith("--"))return`var(${o})`;let s=Hn(()=>ot(o,e));if(Fe(s))return s;if(/^\d/.test(o)||o==="0"||o.includes("px")||o.slice(-2)==="em"||o==="inset"||o==="none"||Nn.has(o.toLowerCase()))return o;r&&r(o);let i=Ct(o,"shadow");return i&&i.shadow?i.shadow:o}).join(" "))).join(", "),Qr=(t,e,r,n)=>{let o=A();if(v(t)&&t.value!==void 0&&t.var!==void 0)return o.useVariable&&(o.cssVars[t.var]=t.value),t;if(P(t)){let a={"@light":Qr(t[0],e,"light"),"@dark":Qr(t[1],e,"dark")};return o.useVariable&&Jr(a,"shadow",e,o),a}if(v(t)){let a={};for(let c in t)a[c]=Qr(t[c],e,c.startsWith("@")?c.slice(1):c);return o.useVariable&&Jr(a,"shadow",e,o),a}k(t)&&!le.test(t)&&(t=qn(t));let i=`--${o.varPrefix?o.varPrefix+"-":""}shadow-${e}`+(r?`-${r}`:"");return o.useVariable&&(o.cssVars[i]=t),{var:i,value:t}},Wa=(t,e)=>{let r=A();if(e||(e=r.globalTheme==="auto"?null:r.globalTheme),!k(t)){r.verbose&&console.warn(t,"- type for color is not valid");return}if(_t(t))return`var(${t})`;let[n]=P(t)?t:t.split(" "),s=r.shadow[n],i=v(s);if(!s)return r.verbose&&console.warn("Can't find color ",n),t;if(i&&!s.value&&r.useVariable&&s.var)return`var(${s.var})`;if(e){let a=s["@"+e]||s[e];if(a)return a.value!==void 0?a.value:a;r.verbose&&console.warn(t," - does not have ",e)}if(i&&s.value)return s.value;if(i){let a={},c=Zr(r);for(let l in s){if(l.charCodeAt(0)!==64)continue;let f=l.slice(1),u=s[l],d=u&&(u.value!==void 0?u.value:u);if(d!==void 0&&(a[`[data-theme="${f}"] &`]=d,f==="light"||f==="dark")){let g=Xr(f,r);if(!g)continue;a[g]={[c]:d}}}return a}return r.verbose&&console.warn("Can't find color",t),t};var NR=new Set(["none","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset","initial"]),jR=t=>NR.has(t),de=(t,e,r)=>{if(t==null)return;let n=t+"";if(le.test(n))return n;let o=n.trim();return o==="none"||o==="0"||o==="initial"||o==="inherit"||o==="unset"?n:n.split(/\s+/).map(s=>{if(s=s.trim(),!s)return"";if(_t(s))return`var(${s})`;if(jR(s)||/^\d/.test(s)||s==="0")return s;let i=Hn(()=>ot(s,e));if(Fe(i))return i;if(Nn.has(s.toLowerCase()))return s;r&&r(s);let a=Ct(s,"border");return a&&a.border?a.border:s}).join(" ")};D();var BR=new Set(["black","white","red","green","blue","yellow","orange","purple","pink","brown","gray","grey","cyan","magenta","lime","olive","navy","teal","aqua","maroon","silver","fuchsia","transparent","currentColor","currentcolor","inherit","initial","unset","none","aliceblue","antiquewhite","aquamarine","azure","beige","bisque","blanchedalmond","blueviolet","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","gainsboro","ghostwhite","gold","goldenrod","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","limegreen","linen","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","oldlace","olivedrab","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","plum","powderblue","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","thistle","tomato","turquoise","violet","wheat","whitesmoke","yellowgreen","rebeccapurple"]),US=["color","Color","background","Background","fill","Fill","stroke","Stroke"],qS=t=>{for(let e=0;e<US.length;e++)if(t.includes(US[e]))return!0;return!1},VR={boxShadow:qn,textShadow:qn,border:de,borderTop:de,borderRight:de,borderBottom:de,borderLeft:de,outline:de,columnRule:de},UR=t=>{if(!t)return!1;let e=Ut(t);return!e||!e.name||e.passthrough||e.cssVar?!1:e.alpha!==void 0||e.tone!==void 0},zS=new Set,zR=(t,e,r,n,o,s)=>{if(!gt())return;let i=`${t}::${e}::${r||""}::${n}`;zS.has(i)||(zS.add(i),console.warn(`[smbls/scratch] theme param "${e}" on "${t}"`+(r?` (${r})`:"")+` did not fully resolve: "${n}" -> "${o}" still contains the unresolved token "${s}". This is not valid CSS \u2014 the browser will drop the whole declaration. Register "${s}" as a design-system color token or fix the typo.`))},ey=(t,e,r,n)=>{let o=VR[e];if(!o)return ot(r,n);let s=null,i=o(r,n,a=>{!s&&UR(a)&&(s=a)});return s&&zR(t,e,n,r,i,s),i},ry=(t,e)=>Ee(t,e),HR=t=>v(t)&&B(t.value),WR=t=>{for(let e in t){let r=t[e];if(k(r)&&r.startsWith("var(--"))return!0}return!1},Ka=(t,e)=>{let r=A();return HR(t)?!r.useVariable&&WR(t)?t:ns(t.value,e):ns(t,e)},KS=(t,e)=>{let r=new Set;for(let n of e){let o=n.slice(0,1);if(!(o==="@"||o==="."||o===":")&&qS(n))for(let s in t){if(r.has(s))continue;let i=t[s]?.[n];if(i===void 0)continue;let a=ot(i,`@${s}`);a!==void 0&&k(a)&&/^[a-z][a-zA-Z]+$/.test(a)&&!BR.has(a)&&r.add(s)}}return r},qR=t=>t.startsWith("[data-theme=")||t.startsWith("@media"),qa=(t,e)=>{for(let r in e){let n=e[r];v(n)?qa(t[r]||(t[r]={}),n):t[r]=n}return t},HS=(t,e,r,n)=>{if(qa(t,{[`[data-theme="${e}"] &`]:r}),e!=="light"&&e!=="dark")return;let o=Xr(e,n);o&&qa(t,{[o]:{[Zr(n)]:r}})},GS=(t,e,r,n)=>{let o=r.globalTheme!==void 0?r.globalTheme:"auto",s=o&&o!=="auto"?String(o).replace(/^'|'$/g,""):null,i=new Set(n?Object.keys(n):[]);for(let l in t)if(t[l])for(let f of Object.keys(t[l]))i.add(f);let a=KS(t,i),c={};for(let l of i){let f=l.slice(0,1);if(f==="@")continue;if(f==="."||f===":"){let y={};for(let _ in t)B(t[_]?.[l])&&(y[_]=t[_][l]);let x=n&&B(n[l])?n[l]:void 0;if(!Object.keys(y).length&&!x)continue;let b=f==="."?l.slice(1):l.replace(/^:+/,"");c[l]=GS(y,`${e}-${b}`,r,x);continue}let u=n&&!B(n[l])?n[l]:void 0,d=new Set(Object.keys(t));u!==void 0&&(d.add("light"),d.add("dark"),s&&d.add(s));let g={},p;for(let y of d){if(a.has(y))continue;let x=t[y]?.[l];if((x===void 0||B(x))&&(x=u),x===void 0)continue;let b=ey(e,l,x,`@${y}`);b!==void 0&&(g[y]=b,(s&&y===s||!s&&(y==="light"||p===void 0))&&(p=b))}let h={},m=Object.keys(g).filter(y=>g[y]!==p);if(m.length){let y=g.light!==void 0?g.light:p,x=g.dark!==void 0?g.dark:p;if(qS(l)&&Yr(y)&&Yr(x)){h[l]=y===x?y:`light-dark(${y}, ${x})`;for(let b in g)b==="light"||b==="dark"||HS(h,b,{[l]:g[b]},r)}else{p!==void 0&&(h[l]=p);for(let b of m)HS(h,b,{[l]:g[b]},r)}}else{if(p===void 0)continue;h[l]=p}qa(c,h),c[`.${l}`]=h}return(c.background||c.color||c.backgroundColor)&&(c[".inversed"]={color:c.background||c.backgroundColor,background:c.color}),c},Qm=(t,e,r,n)=>{let{cssVars:o}=r;r.cssMediaVars||(r.cssMediaVars={});let s=r.cssMediaVars,i=r.globalTheme!==void 0?r.globalTheme:"auto",a=i&&i!=="auto"?String(i).replace(/^'|'$/g,""):null,c={},l=new Set(n?Object.keys(n):[]);for(let u in t)if(t[u])for(let d of Object.keys(t[u]))l.add(d);let f=KS(t,l);for(let u of l){let d=u.slice(0,1),g=B(n?.[u])||Object.values(t).some(p=>B(p?.[u]));if(d==="."&&g){let p=u.slice(1),h={};for(let y in t)B(t[y]?.[u])&&(h[y]=t[y][u]);let m=B(n?.[u])?n[u]:void 0;c[u]=Qm(h,`${e}-${p}`,r,m)}else if(d===":"&&g){let p=u.replace(/^:+/,""),h={};for(let y in t)B(t[y]?.[u])&&(h[y]=t[y][u]);let m=B(n?.[u])?n[u]:void 0;c[u]=Qm(h,`${e}-${p}`,r,m)}else if(d!=="@"&&d!=="."&&d!==":"){let h=`--${r.varPrefix?r.varPrefix+"-":""}theme-${e}-${u}`,m=n&&!B(n[u])?n[u]:void 0,y=new Set(Object.keys(t));m!==void 0&&(y.add("light"),y.add("dark"),a&&y.add(a));let x,b=!1;for(let _ of y){if(f.has(_))continue;let w=t[_]?.[u];if((w===void 0||B(w))&&(w=m),w===void 0)continue;let S=ey(e,u,w,`@${_}`);if(S===void 0)continue;b=!0,(a&&_===a||!a&&(_==="light"||x===void 0))&&(x=S);let E=`[data-theme="${_}"]`;if(s[E]||(s[E]={}),s[E][h]=S,_==="dark"||_==="light"){let O=`@media (prefers-color-scheme: ${_})`;s[O]||(s[O]={}),s[O][h]=S}}if(x!==void 0&&(o[h]=x),!b)continue;c[u]=`var(${h})`,c[`.${u}`]={[u]:c[u]}}}return(c.background||c.color||c.backgroundColor)&&(c[".inversed"]={color:c.background||c.backgroundColor,background:c.color}),c},ns=(t,e,r,n)=>{let o=A(),{cssVars:s}=o,i={value:t},a=!r&&!n,c,l;if(B(t)){if(a&&o.useVariable){let f={},u={};for(let d in t)d.startsWith("@")?B(t[d])&&(f[d.slice(1)]=t[d]):u[d]=t[d];(Object.keys(f).length||Object.keys(u).length)&&(l=Qm(f,e,o,u),Object.assign(i,l))}else if(a){let f={},u={};for(let d in t)d.startsWith("@")?B(t[d])&&(f[d.slice(1)]=t[d]):u[d]=t[d];c=GS(f,e,o,u),Object.assign(i,c)}for(let f in t){let u=f.slice(0,1),d=t[f];if(u==="@"||u===":"||u==="."){let g=u==="@"&&f;i[f]=ns(d,e,f,n||g)}else if(!a){let g=ey(e,f,d,n),p=[...new Set([n,r].filter(x=>x).map(x=>x.slice(1)))],h=p.length?"-"+p.join("-"):"",y=`--${o.varPrefix?o.varPrefix+"-":""}theme-${e}${h}-${f}`;o.useVariable?(o.useThemeSuffixedVars&&(s[y]=g),i[f]=`var(${y})`):i[f]=g,i[`.${f}`]={[f]:i[f]}}}if(c)for(let f in c){let u=f.slice(0,1);(u==="."||u===":")&&B(t[f])&&(i[f]=c[f])}if(l)for(let f in l){let u=f.slice(0,1);(u==="."||u===":")&&B(t[f])&&(i[f]=l[f])}!i[".inversed"]&&(i.background||i.color||i.backgroundColor)&&(i[".inversed"]={color:i.background||i.backgroundColor,background:i.color})}if(k(t)&&_t(t)){let u=o.theme[t.slice(2)];return Ee(u,n)}return i},ty=(t,e)=>{let r={};for(let n in t){let o=n.slice(0,1);if(B(t[n]))if(e&&qR(n))r[n]=qa({},t[n]);else{if(o==="@")continue;o===":"?r[`&${n}`]=ty(t[n],e):o==="."&&(r[`&${n}`]=ty(t[n],e))}else r[n]=t[n]}return r},YS=(t,e)=>{let r=e.shift();return t[r]?YS(t[r],e):t},WS=(t,e)=>P(e)?YS(t,e):k(e)&&t[e]?t[e]:t;var Ee=(t,e)=>{let r=A();if(k(t)&&_t(t)&&(t=Ee(t.slice(2))),!t||!k(t)){r.verbose&&console.warn(`${t} - Theme is not a string`);return}let[n,...o]=P(t)?t:t.split(" "),s=r.theme[n];return s&&o.length?s=WS(s,o):s&&e&&(s=WS(s,e)),ty(s,!r.useVariable)};D();D();var Ga=(t,e)=>{let r=A(),n=`--font-${e}`;if(!t||P(t)&&!t[0])return;let o;if(t.isVariable){let s=ke(t.url,r.files)||t.url;Xo(s)?o=Zo(s):o=Wr(e,s,t.fontWeight,{fontStretch:t.fontStretch,fontDisplay:t.fontDisplay||"swap",unicodeRange:t.unicodeRange})}else if(t[0])o=Vn(e,t,r.files);else{let s=Array.isArray(t.url)?t.url.map(i=>ke(i,r.files)||i):ke(t.url,r.files)||t.url;o=Wr(e,s,t.fontWeight,{fontStyle:t.fontStyle,fontDisplay:t.fontDisplay,fontStretch:t.fontStretch,unicodeRange:t.unicodeRange})}return{var:n,value:t,fontFace:o}},Ya=(t,e)=>{let r=A(),{fontFamily:n}=r;return Bn(e||n,t)},os=(t,e)=>{let r=A(),{fontFamily:n,fontFamilyTypes:o}=r,{value:s,type:i}=t;t.isDefault&&(!t.isSystemFallback||!n.default)&&(n.default=e),v(s)&&(s=Mn(s));let a=`--font-family-${e}`,c=`${s.join(", ")}, ${o[i]}`;return{var:a,value:c,arr:s,type:i,isSystemFallback:!!t.isSystemFallback}};D();var Zf=t=>{let e=A(),{typography:r,media:n}=e;for(let o in t){let s=o.slice(0,1)==="@",i=t[o];if(!s)continue;let{mediaRegenerate:a}=t,c=o.slice(1),{type:l,base:f,ratio:u,range:d,subSequence:g,h1Matches:p,unit:h}=t;bt(i,{type:l,base:f,ratio:u,range:d,subSequence:g,h1Matches:p,unit:h});let m=new Set(["vw","vh","vmin","vmax","svw","svh","lvw","lvh","dvw","dvh"]),y=i.unit||h,x=!i.unit&&m.has(h)?"rem":y,b=n[c],_="@media "+(b==="print"?`${b}`:`screen and ${b}`);if(r.templates[_]={fontSize:i.base/r.browserDefault+x},!a){bt(i,{sequence:{},scales:{},vars:{}}),te(i),qr(t,o);continue}bt(i,{sequence:{},scales:{},templates:{},vars:{}}),te(i),qr(t,o)}},Jf=t=>{let e=A();if(t.h1Matches){let r=t.unit,n=Na(t),{templates:o}=t;for(let s in n){let i=`h${parseInt(s)+1}`,a=o[i];o[i]={fontSize:e.useVariable?`var(${n[s]?.variable})`:`${n[s]?.scaling}${r}`,margin:a?a.margin:0,lineHeight:a?a.lineHeight:t.lineHeight,letterSpacing:a?a.letterSpacing:t.letterSpacing,fontWeight:a?a.fontWeight:900-s*100}}}},Xa=()=>{let t=A(),{typography:e}=t;te(e),Jf(e),xr(e),Zf(e)},Za=t=>{let e=A(),{typography:r}=e;return rr(t,"fontSize",r)};D();var Ja=t=>{if(!k(t))return;let r=A().shape;if(r)return r[t]!==void 0?r[t]:r[t.toLowerCase()]};D();var Qa=()=>{let t=A(),{timing:e}=t;te(e),xr(e)},Ae=t=>{let e=A(),{timing:r}=e;return r[t]||r[xa(t)]||t},pe=(t,e="timing")=>{let r=A(),{timing:n}=r;return rr(t,e,n)};D();var tc=()=>{let t=A(),{fontFamily:e,theme:r,typography:n}=t,o=t.document;return dr(o)?(Ir(t,"document",o),o=t.document={}):o||(o=t.document={}),bt(o,{theme:r.document,fontFamily:Bn(e),fontSize:n.base,lineHeight:n.lineHeight})};D();var sy={document:st},XS=new WeakMap,ZS=new WeakMap,KR=128,JS=1048576,ny=8192,iy=t=>t.nodeType===1&&t.localName==="symbol"&&t.getAttribute("id"),e0=t=>t.nodeType===8||t.nodeType===3&&!t.textContent.trim(),GR=(t,e)=>{let r=1,n=t.ownerDocument;if(n&&typeof n.createTreeWalker=="function"){let s=n.createTreeWalker(t,4294967295);for(;s.nextNode();)if(++r>e)return r;return r}let o=[t];for(;o.length;){let s=o.pop().childNodes||[];for(let i=0;i<s.length;i++){if(++r>e)return r;o.push(s[i])}}return r},oy=(t,e)=>{if(typeof t.importNode=="function")return t.importNode(e,!0);let r=e.cloneNode(!0);return typeof t.adoptNode=="function"?t.adoptNode(r):r},YR=(t,e)=>{if(typeof t.prepend=="function")return t.prepend(e);let r=t.firstChild!==void 0?t.firstChild:t.childNodes&&t.childNodes[0];return typeof t.insertBefore=="function"?t.insertBefore(e,r||null):t.appendChild(e)},ss=(t,e)=>{let r=A();if(!t){r.verbose&&console.warn("setSVG: val is not defined",e);return}return r.useSvgSprite?Va(e,t):t},ec=(t,e=sy)=>{let r=A(),n=Object.keys(t).length?{}:r.svg;for(let o in t)n[o]=t[o];n0(n,e)},Kn=(t,e)=>{let r=A();return r.useIconSprite&&!r.semanticIcons?.[e]?ss(t,e):t},Gn=(t,e=sy)=>{let r=A(),n=Object.keys(t).length?{}:r.icons;for(let o in t)n[o]=t[o];n0(n,e)},r0=(t,e={isRoot:!0})=>{if(!t||!t.createElementNS)return;let r=t.createElementNS("http://www.w3.org/2000/svg","svg");return e.isRoot&&(r.setAttribute("aria-hidden","true"),r.setAttribute("width","0"),r.setAttribute("height","0"),r.setAttribute("style","position:absolute"),r.setAttribute("id","svgSprite")),r},XR=(t,e)=>{let r=typeof DOMParser<"u"?DOMParser:null;if(r){let n=`<svg xmlns="http://www.w3.org/2000/svg">${e}</svg>`,s=new r().parseFromString(n,"image/svg+xml");return s.querySelector("parsererror")?null:s.documentElement}return null},ZR=(t,e,r)=>{let n=String(r),o=ZS.get(e),s=o?.entries.get(n);if(s)return o.entries.delete(n),o.entries.set(n,s),s.root;let i=XR(t,n);if(i||(i=r0(t,{isRoot:!1}),i.innerHTML=n),n.length>JS)return i;let a=GR(i,ny);if(a>ny)return i;for(o||(o={entries:new Map,units:0,nodes:0},ZS.set(e,o));o.entries.size>=KR||o.units+n.length>JS||o.nodes+a>ny;){let c=o.entries.keys().next().value,l=o.entries.get(c);o.units-=c.length,o.nodes-=l.nodes,o.entries.delete(c)}return o.entries.set(n,{root:i,nodes:a}),o.units+=n.length,o.nodes+=a,i},QS=t=>{let e=new Map;for(let r of t.children){let n=iy(r);if(!n)continue;let o=e.get(n)||[];o.push(r),e.set(n,o)}return e},JR=t=>t.replace(/["\\\u0000-\u001f\u007f]/g,e=>`\\${e.charCodeAt(0).toString(16)} `),t0=(t,e,r,n)=>{let o=0,s=e.childElementCount>8?QS(r):null,i=a=>{if(!s)try{return[...r.querySelectorAll(`symbol[id="${JR(a)}"]`)].filter(c=>c.parentNode===r)}catch{s=QS(r)}return s.get(a)};for(let a of e.childNodes){if(e0(a))continue;let c=iy(a);if(!c&&n){let u=o++,d=n.nodes[u];if(!d&&n.complete||d?.parentNode===r)continue;let g=oy(t,d||a);r.appendChild(g),n.nodes[u]=g;continue}let l=c&&i(c),f=l&&l[0];if(!f)f=oy(t,a),r.appendChild(f);else if(!f.isEqualNode(a)){let u=oy(t,a);r.replaceChild(u,f),f=u}if(l)for(let u=1;u<l.length;u++)l[u].remove();c&&s&&s.set(c,[f])}},n0=(t,e=sy)=>{let r=A(),n=e.document||st;if(!n||!n.documentElement)return r.verbose&&console.warn("To append SVG sprites it should be run in browser environment"),Ba(t);let o=n.querySelector("#svgSprite"),s="";for(let d in t)s+=t[d];let i=o||r0(n);if(!i||!i.nodeType)return;let a=d=>ZR(n,i,d),c=a(s),l=XS.get(i);l||XS.set(i,l=new WeakMap);let f=l.get(r);if(f||l.set(r,f=new Map),[...c.childNodes].some(d=>!e0(d)&&!iy(d))){let d=[];for(let g in t)d.push(g);for(let g of d){let p=f.get(g);p||f.set(g,p={nodes:[],complete:!1}),t0(n,d.length===1?c:a(t[g]),i,p),p.complete=!0}}else{t0(n,c,i);for(let d in t)f.has(d)||f.set(d,{nodes:[],complete:!0})}o||YR(n.body,i);for(let d in t)r.__svgCache[d]=!0};D();var rc=(t={})=>{let e=A(),r=e.typography||{},n=e.document||{},o=v(e.reset)?e.reset:e.reset={};if(o[":root"]){let c=o,l=r.templates||{};c.body={...e.useDocumentTheme?Ee("document"):{},...l.body},c.h1=l.h1,c.h2=l.h2,c.h3=l.h3,c.h4=l.h4,c.h5=l.h5,c.h6=l.h6}let{body:s,...i}=r.templates||{},a=e.useDocumentTheme?Ee("document"):{};if(o.html&&Wt(o.html,a),r.unit)for(let c in i){if(c.slice(0,6)!=="@media")continue;let l=i[c];delete i[c],!(!l||!l.fontSize)&&(o[c]||(o[c]={}),o[c].html||(o[c].html={}),o[c].html.fontSize===void 0&&(o[c].html.fontSize=l.fontSize))}if(r.unit){let c=e.media||{};for(let l in r){if(l.charAt(0)!=="@")continue;let f=r[l];if(!f||f.unit===r.unit||!f.unit)continue;let u=f.unit,d=f.base||r.base,g=f.browserDefault||r.browserDefault,p=l.slice(1),h=c[p];if(!h)continue;let m="@media "+(h==="print"?h:"screen and "+h);o[m]||(o[m]={}),o[m].html||(o[m].html={}),o[m].html.fontSize=d/g+u}}return at(bt(o,t),{html:{position:"absolute",width:"100%",height:"100%",top:"0",left:"0",margin:"0",WebkitFontSmoothing:"subpixel-antialiased",textSizeAdjust:"100%",WebkitTextSizeAdjust:"100%",...a,fontSize:r.unit?r.base/r.browserDefault+r.unit:r.browserDefault+"px",fontFamily:n.fontFamily,lineHeight:n.lineHeight},body:{boxSizing:"border-box",height:"100%",margin:0,fontFamily:n.fontFamily,fontSize:r.unit?"1"+e.unit.default:r.base/r.browserDefault+e.unit.default,...i,...s},a:{color:"currentColor"},button:{color:"inherit",font:"inherit",background:"transparent",border:"none",cursor:"pointer",appearance:"none",WebkitAppearance:"none"},"input, select, textarea":{color:"inherit",font:"inherit"},fieldset:{border:0,padding:0,margin:0}},ue)};D();var QR=new Set(["fallback"]),ay=new Set,o0=(t,e)=>{ay.has(t)||(ay.add(t),gt()&&console.warn(e))},cy=()=>{ay.clear()},s0=t=>{for(let e in t)delete t[e];return t},nc=()=>{let t=A(),e=v(t.cssSkinVars)?s0(t.cssSkinVars):t.cssSkinVars={},r=v(t.cssSkinFallback)?s0(t.cssSkinFallback):t.cssSkinFallback={},n=t.skins;if(!v(n))return e;let o=t.varPrefix?t.varPrefix+"-":"",s=t.color||{},i=t.cssVars||{},a=c=>k(c)&&Object.prototype.hasOwnProperty.call(s,c)?`var(--${o}color-${c})`:c;for(let c in n){let l=n[c];if(!v(l))continue;let f={};for(let u in l){if(QR.has(u))continue;let d=l[u];if(v(d))for(let g in d){let p=`--${o}theme-${u}-${g}`;t.useVariable!==!1&&!(p in i)&&o0(`${c}/${u}/${g}`,`[scratch] skin "${c}" rewrites theme "${u}" param "${g}", which the theme does not declare \u2014 no element reads ${p}, so the skin changes nothing there. Declare "${g}" on the "${u}" theme (its no-skin value).`),f[p]=a(d[g])}}e[c]=f,k(l.fallback)&&(r[c]=l.fallback)}for(let c in r){let l=r[c];e[l]||(o0(`${c}/fallback/${l}`,`[scratch] skin "${c}" falls back to "${l}", which is not a declared skin \u2014 the reduced-transparency fallback is skipped.`),delete r[c])}return e},i0=(t,e)=>{let r=`[data-skin="${t}"]`;return!e||e===":root"?`:root${r}, ${r}`:`${e}${r}, ${r} ${e}, ${e} ${r}`},Yn=(t,e,r)=>{let n={};if(!v(t))return n;for(let s in t)n[i0(s,r)]=t[s];let o={};for(let s in e||{}){let i=t[e[s]];i&&(o[i0(s,r)]=i)}return Object.keys(o).length&&(n["@media (prefers-reduced-transparency: reduce)"]=o),n};D();var tP=new Set(["to","top","bottom","left","right","center","at","circle","ellipse","closest-side","farthest-side","closest-corner","farthest-corner"]),a0=/^-?[A-Z][0-9]?$/,nr=t=>de(t),Qf=t=>{if(k(t))return le.test(t)?t:t.split(/\s+/).map(e=>{if(e=e.trim(),!e)return"";if(_t(e))return`var(${e})`;if(/^\d/.test(e)||e.includes("px")||e==="0")return e;let r=ot(e);return Fe(r)?r:e}).join(" ")},tu=(t,e)=>Wa(t,e),oc=(t,e)=>{if(k(t))return le.test(t)?t:yr(t).map(r=>(r=r.trim(),r?r.split(/\s+/).map(n=>{if(n=n.trim(),!n)return"";if(_t(n))return`var(${n})`;if(n==="inset"||n==="none")return n;let o=ot(n);if(Fe(o)){let i=Mt(n,e);return v(i)?Object.values(i).filter(a=>a.includes(": "+e))[0]:i}if(/^\d/.test(n)||n==="0"||n.includes("px")||n.slice(-2)==="em")return n;let s=Ct(n,"shadow");return s&&s.shadow?s.shadow:n}).join(" "):"")).join(", ")},sc=(t,e)=>{let r=t.indexOf("(");if(r===-1)return t;let n=t.slice(0,r+1),o=t.slice(r+1,t.lastIndexOf(")")),s=")",a=yr(o).map(c=>(c=c.trim(),c.split(/\s+/).map(f=>{if(!f||/^\d/.test(f)||f==="0"||tP.has(f)||f==="transparent"||le.test(f))return f;let u=ot(f);return Fe(u)?u:f}).join(" ")));return n+a.join(", ")+s},eu=(t,e)=>{if(!k(t))return;let r=A();return yr(t).map(n=>{let o=n.trim();if(_t(o))return`var(${o})`;if(/^var\(/.test(o)||o.includes("url"))return o;if(r.gradient?.[o]){let s=Mt(o,e);if(k(s))return s;if(v(s)){for(let i in s)if(k(s[i]))return s[i]}return o}return o.includes("gradient")?sc(o,e):o.includes("/")||o.startsWith("http")||o.includes(".")&&!Ut(o)?`url(${o})`:o}).join(", ")},ru=t=>k(t)&&pt(t).map(e=>Ct(e,"gap").gap).join(" "),nu=t=>{if(!k(t))return t;let e=A();return pt(t).map(r=>a0.test(r)?zn(r,e.spacing):r).join(" ")},ly=t=>{if(!k(t))return;let e=t.split(" ");return e.length?e.map(r=>_t(r)?`var(${r})`:r.length<3||r.includes("ms")?pe(r).timing||r:Ae(r)?Ae(r):r).join(" "):t},ic=(t,e,r)=>{if(k(t))return t.split(",").map(n=>pe(n).timing||n).join(",")},ou=t=>{if(!k(t))return;let e=t.split(",");if(e.length)return e.map(ly).join(",")};function vt(t,e,r={},n={}){let o=dt.call(this,e||r[t]);if(o==null)return;let s;if(k(o)){if(/^(?:env|var)\(/.test(o.trim()))return{[t]:o};if(o.includes("(")){let c=_r(o);s=c[0],o=c[1]}let i=r.scaleBoxSize,a=Ua(t);!i&&a&&!n.ratio&&(o=Ha(o))}return n.ratio?Ce(r,t,o,s):Ct(o,t,void 0,s)}var I=(t,e=null,r)=>vt(t,e,r,{ratio:!0}),eP=(t,e,r)=>k(t)?pt(t).map(n=>a0.test(n)?Ce(e,r,n)[r]:n).join(" "):t,wr=(t,e,r,n="borderRadius")=>{if(k(t))return{[n]:pt(t).map(o=>{let s=Ja(o);return s!==void 0?eP(s,e,r):Ce(e,r,o)[r]}).join(" ")}};D();var as="__smblsThemeRootOwner",cs=t=>{let e=t&&t.__prefersListener,r=t&&t.__prefersMq;if(e&&r)try{typeof r.removeEventListener=="function"?r.removeEventListener("change",e):typeof r.removeListener=="function"&&r.removeListener(e)}catch{try{r.removeListener(e)}catch{}}t&&(t.__prefersListener=null,t.__prefersMq=null)},c0=(t,e,r)=>{if(!(!t||!e)){cs(t),t.__prefersListener=r,t.__prefersMq=e;try{e.addEventListener("change",r)}catch{e.addListener(r)}}},rP=(t,e)=>{let r=A(),{cssVars:n}=r,o=e.startsWith("--")?e:`--${e}`;return n[o]=t,t},Kt=t=>t,su={color:Gr,gradient:rs,font:Ga,fontFamily:os,fontfamily:os,theme:Ka,icons:Kn,semanticIcons:Kt,semanticicons:Kt,svg:ss,svgData:Kt,typography:Kt,shadow:Qr,spacing:Kt,media:Kt,grid:Kt,class:Kt,timing:Kt,reset:Kt,unit:Kt,animation:Kt,vars:rP,sizes:Kt,shape:Kt,skins:Kt},nP=(t,e,r,n)=>{Ir(t,r,e);let o={};for(let s of n)t[s]===e&&(t[s]=o);return t.verbose&&console.warn("[scratch] design-system family",r,"resolved to a host object; parked it and allocated a plain bucket"),o},fy=(t,e,r)=>{let n=A(),o=Pa(t),s=o.toLowerCase(),i=n[o]||n[s]||n[t],a=dr(i)?nP(n,i,s,[o,s,t]):i,c=su[o]||su[s];if(c)try{let l=c(e,r);return a&&(a[r]=l),a}catch(l){n.verbose&&console.warn("Error setting",s,"value",e,r,l)}if(!c){let l=a||(n[s]={});return l[r]=e,l}n.verbose&&console.warn("Can not find",s,"method in scratch")},uy=(t,e)=>{let r=A(),n=t.toLowerCase();return dr(e)?(Ir(r,n,e),r.verbose&&console.warn("[scratch] ignoring host object passed as the",n,"design-system family"),r[n]||r[t]):e==null?(r.verbose&&console.warn("[scratch] skipping empty design-system family",n),r[n]||r[t]):(Object.keys(e).sort((s,i)=>{let a=v(e[s])||P(e[s])?1:0,c=v(e[i])||P(e[i])?1:0;return a-c}).forEach(s=>{try{return fy(n,e[s],s)}catch(i){r.verbose&&console.warn("Error setting",n,"value",e[s],s,i)}}),r[n]||r[t])},iu=(t,e)=>{let r=e||A();r.globalTheme=t;let o=wo(r)||(typeof document<"u"?document:null),s=o&&o.defaultView||(typeof window<"u"?window:null);if(o){let a=r.themeRoot||o.documentElement,c=t&&t!=="auto";if(a[as]=r,c)cs(r),a.setAttribute("data-theme",t),r.resolvedTheme=t,t==="dark"||t==="light"?a.style.colorScheme=t:a.style.colorScheme="light dark";else if(s&&s.matchMedia){let l=u=>{let d=u.matches?"dark":"light";a.setAttribute("data-theme",d),r.resolvedTheme=d},f=s.matchMedia("(prefers-color-scheme: dark)");l(f),a.style.colorScheme="light dark",c0(r,f,l)}else cs(r),a.setAttribute("data-theme","light"),r.resolvedTheme="light",a.style.colorScheme="light"}let i=r.varPrefix?`--${r.varPrefix}-theme-`:"--theme-";for(let a in r.cssVars)a.startsWith(i)&&delete r.cssVars[a];for(let a in r.cssMediaVars)delete r.cssMediaVars[a];if(o&&r.cssVars){let a=r.scopeSelector||":root",c=o.styleSheets;for(let l=0;l<c.length;l++)try{let f=c[l].cssRules;for(let u=0;u<f.length;u++)if(f[u].selectorText===a){for(let d in r.cssVars)f[u].style.setProperty(d,r.cssVars[d]);return r}}catch{}}return r},oP={},Xn=(t,e=oP)=>{let r=e.config||A(),{version:n,verbose:o,useVariable:s,useReset:i,useSvgSprite:a,useFontImport:c,useIconSprite:l,globalTheme:f,themeRoot:u,useDocumentTheme:d,useDefaultConfig:g,semanticIcons:p,hoverMedia:h,files:m,assets:y,...x}=t;e.newConfig&&(r=Wf(e.newConfig)),ur(x.document)&&(r.__domDocument=x.document,delete x.document),ur(r.document)&&(r.__domDocument||(r.__domDocument=r.document),r.document={}),m!==void 0&&(r.files=m),y!==void 0&&(r.assets=y),o!==void 0&&(r.verbose=o),s!==void 0&&(r.useVariable=s),i!==void 0&&(r.useReset=i),c!==void 0&&(r.useFontImport=c),a!==void 0&&(r.useSvgSprite=a),l!==void 0&&(r.useIconSprite=l),d!==void 0&&(r.useDocumentTheme=d),f!==void 0&&(r.globalTheme=f),u!==void 0&&(r.themeRoot=u),t.useThemeSuffixedVars!==void 0&&(r.useThemeSuffixedVars=t.useThemeSuffixedVars),g!==void 0&&(r.useDefaultConfig=g),p!==void 0&&(r.semanticIcons=p),h!==void 0&&(r.hoverMedia=h),r.verbose&&console.log(r);let _=wo(r)||(typeof document<"u"?document:null),w=_&&_.defaultView||(typeof window<"u"?window:null),S=_&&(r.themeRoot||_.documentElement);if(S&&typeof S.setAttribute=="function")if(r.globalTheme&&r.globalTheme!=="auto")cs(r),S.setAttribute("data-theme",r.globalTheme),r.resolvedTheme=r.globalTheme,S[as]=r,r.globalTheme==="dark"||r.globalTheme==="light"?S.style.colorScheme=r.globalTheme:S.style.colorScheme="light dark";else if(S[as]&&S[as]!==r&&S.hasAttribute("data-theme"))cs(r),r.resolvedTheme=S.getAttribute("data-theme");else if(w&&w.matchMedia){let M=rt=>{let Rt=rt.matches?"dark":"light";S.setAttribute("data-theme",Rt),r.resolvedTheme=Rt},U=w.matchMedia("(prefers-color-scheme: dark)");M(U),S.style.colorScheme="light dark",S[as]=r,c0(r,U,M)}else cs(r),S.setAttribute("data-theme","light"),r.resolvedTheme="light",S.style.colorScheme="light",S[as]=r;r.__svgCache||(r.__svgCache={}),es(x);let E=Object.keys(x).filter(T=>!T.startsWith("__")),O=new Set(E);if(E.forEach(T=>{let M=T.toLowerCase();M!==T&&O.has(M)&&at(x[M],x[T],ue)}),E.map(T=>{let M=T.toLowerCase();if(!(M!==T&&O.has(M)))return uy(T,x[T])}),r.varPrefix&&(r.typography&&(r.typography.varPrefix=r.varPrefix),r.spacing&&(r.spacing.varPrefix=r.varPrefix),r.timing&&(r.timing.varPrefix=r.varPrefix)),x.typography)try{Xa()}catch(T){r.verbose&&console.warn("Error applying typography sequence",T)}if(x.spacing)try{za()}catch(T){r.verbose&&console.warn("Error applying spacing sequence",T)}if(x.timing)try{Qa()}catch(T){r.verbose&&console.warn("Error applying timing sequence",T)}try{nc()}catch(T){r.verbose&&console.warn("Error applying skins",T)}tc();let L=rc();return L&&(r.reset=L),r};var fs=new Map,x0=null,py=null,sP=null;function cc(t){t.batchAtomicCss&&(py=t.batchAtomicCss),t.compoundCssClass&&(sP=t.compoundCssClass)}var iP=new Set,f0=t=>!!(t&&t.documentElement&&typeof t.createElement=="function"&&t.head!==void 0);function by(t){try{let e=A();e&&(e.__domDocument=t)}catch{}t&&iP.add(t)}function Jn(){try{let t=A();if(t){if(f0(t.__domDocument))return t.__domDocument;if(f0(t.document))return t.document}}catch{}return typeof document<"u"?document:null}var ee={atomic:0,variable:0,global:0,keyframes:0,duplicate:0,invalid:0,dropped:0};function du(){return{...ee}}function _y(){for(let t in ee)ee[t]=0;fu=!1}var fu=!1,lu=(t,e)=>`${t} ${e}${t===1?"":"s"}`;function aP(t){let e=Date.parse(t);if(!isFinite(e))return"";let r=Math.floor((Date.now()-e)/864e5);return r<1?" (today)":` (${lu(r,"day")} ago)`}function cP(){try{let t=bP();if(!t.length)return-1;let e=0;for(let r=0;r<t.length;r++)e+=t[r].cssRules?t[r].cssRules.length:0;return e}catch{return-1}}function lP(t,e){if(fu)return!1;fu=!0;let r="n/a \u2014 running from src/ (unbuilt), so no dist is in play",n="this IS the source",o="@symbo.ls/css";return console.error(`[@symbo.ls/css] CSS EMIT FAILURE (${t}) \u2014 the engine emitted ${lu(ee.variable,"variable rule")} and ${lu(ee.atomic,"atomic rule")}, while the design system held ${lu(e,"CSS variable")}.
43
43
  The document will render UNSTYLED and nothing else will report an error.
44
44
  This is what a STALE dist/ looks like: an obsolete emitter against a current design system.
45
45
  package : ${o}
46
46
  built : ${r}
47
47
  source : ${n}
48
48
  emitted : ${JSON.stringify(ee)}
49
- sheets : the style[data-smbls] tiers currently hold ${XR()} rule(s)
49
+ sheets : the style[data-smbls] tiers currently hold ${cP()} rule(s)
50
50
  FIX : cd smbls && npm run check:stale # every package whose src is newer than its dist
51
51
  then rebuild the listed packages and clear the app's .parcel-cache
52
- Do NOT trust any browser measurement taken on this page until that reads clean.`),!0}function d0(){try{let t=A(),e=t&&(t.CSS_VARS||t.cssVars);return e?Object.keys(e).length:0}catch{return 0}}function r0(t){cu||ee.variable>0||ee.atomic>0||p0(Math.max(t,d0()))}function gy(t){let e=t&&(t.CSS_VARS||t.cssVars);return p0(e?Object.keys(e).length:d0())}function p0(t){let e=fu();if(t===0)return{ok:!0,reason:"no-design-system",stats:e,varCount:t};if(!uu())return{ok:!0,reason:"no-sheet",stats:e,varCount:t};if(e.variable>0||e.atomic>0)return{ok:!0,reason:null,stats:e,varCount:t};let r=e.invalid>0?"every rule was rejected as malformed":"no rule was ever produced";return ZR(r,t),{ok:!1,reason:r,stats:e,varCount:t}}var JR={display:"d",position:"pos",padding:"p",paddingTop:"pt",paddingRight:"pr",paddingBottom:"pb",paddingLeft:"pl",margin:"m",marginTop:"mt",marginRight:"mr",marginBottom:"mb",marginLeft:"ml",width:"w",height:"h",minWidth:"mnw",minHeight:"mnh",maxWidth:"mxw",maxHeight:"mxh",top:"t",right:"r",bottom:"b",left:"l",flex:"fx",flexDirection:"fxd",flexWrap:"fxw",flexGrow:"fxg",flexShrink:"fxs",flexBasis:"fxb",justifyContent:"jc",alignItems:"ai",alignSelf:"as",alignContent:"ac",gap:"g",rowGap:"rg",columnGap:"cg",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",gridColumn:"gc",gridRow:"gr",overflow:"of",overflowX:"ofx",overflowY:"ofy",fontSize:"fs",fontWeight:"fw",fontFamily:"ff",fontStyle:"fst",lineHeight:"lh",letterSpacing:"ls",textAlign:"ta",textDecoration:"td",textTransform:"tt",color:"c",background:"bg",backgroundColor:"bgc",backgroundImage:"bgi",border:"bd",borderRadius:"br",borderColor:"bdc",borderWidth:"bdw",borderStyle:"bds",boxShadow:"bxsh",opacity:"op",zIndex:"z",cursor:"cur",transition:"tr",transform:"tf",animation:"an",visibility:"vis",whiteSpace:"ws",wordBreak:"wb",objectFit:"obj",pointerEvents:"pe",userSelect:"us",boxSizing:"bxz",outline:"ol",listStyle:"lis",textOverflow:"txo",verticalAlign:"va",float:"fl",clear:"cl",content:"cnt",backdropFilter:"bdf",filter:"flt",resize:"rsz",appearance:"apr",fill:"fil",stroke:"stk"};function Zn(t){return t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function lu(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e.toString(36)}function QR(t){let e=String(t);return e.length<=20?e.replace(/\s+/g,"_").replace(/[^a-zA-Z0-9_-]/g,"").toLowerCase():lu(e)}var tP={"backdrop-filter":"-webkit-backdrop-filter","user-select":"-webkit-user-select","mask-image":"-webkit-mask-image","mask-size":"-webkit-mask-size","mask-repeat":"-webkit-mask-repeat","mask-position":"-webkit-mask-position","mask-clip":"-webkit-mask-clip","mask-origin":"-webkit-mask-origin","background-clip":"-webkit-background-clip"};function cs(t,e){let r=tP[t];return r?`${t}:${e};${r}:${e};`:`${t}:${e};`}function ly(t){let e="";for(let r in t){let n=t[r];if(typeof n!="object"||n===null)continue;let o="";for(let s in n){let i=s.charCodeAt(0)===45&&s.charCodeAt(1)===45;o+=cs(i?s:Zn(s),n[s])}e+=`${r}{${o}}`}return e}var eP="@media (hover: hover)",rP=/(?:^|[^\\]):hover(?![\w-])/;function my(){try{let t=A();if(t&&t.hoverMedia===!1)return!1}catch{}return!0}function xr(t,e,r){return r===!1||!rP.test(e)||r===void 0&&!my()?t:`${eP}{${t}}`}function n0(t,e,r){let n=(r?r+"":"")+t+":"+e,o=ls.get(n),s=o?null:Zn(t);if(!o){let c=JR[t]||lu(t),l=QR(e);o=r?`_${r}_${c}-${l}`:`_${c}-${l}`,ls.set(n,o)}if(typeof e=="string"&&(e.indexOf("}")!==-1||e.indexOf("{")!==-1))return o;let i=s||Zn(t),a=`.${o}{${cs(i,e)}}`;return Ne(a,void 0,"atomic"),o}var o0=new WeakMap,s0=new WeakMap;function Ne(t,e,r){let n=uu(e,nP(t));if(!n)return ee.dropped++,"dropped";let o=o0.get(n);if(o||(o=new Set,o0.set(n,o)),o.has(t))return ee.duplicate++,ee[r||"global"]++,"duplicate";let s=s0.get(n);if(s&&s.has(t))return ee.invalid++,"invalid";try{n.insertRule(t,n.cssRules.length)}catch{return s||(s=new Set,s0.set(n,s)),s.add(t),ee.invalid++,"invalid"}return o.add(t),ee[r||"global"]++,"inserted"}var je="0:0",i0="1:0",a0=/\((max|min)-width:\s*([\d.]+)(px|em|rem)?\)/g;function nP(t){if(typeof t!="string"||!t)return je;if(t.charCodeAt(0)===64){if(!t.startsWith("@media")&&!t.startsWith("@supports")&&!t.startsWith("@container"))return je;let e=1/0,r=-1/0;a0.lastIndex=0;let n;for(;n=a0.exec(t);){let o=parseFloat(n[2])*(n[3]==="em"||n[3]==="rem"?16:1);n[1]==="max"?e=Math.min(e,o):r=Math.max(r,o)}return e!==1/0?"2:"+-e:r!==-1/0?"3:"+r:i0}return t.charCodeAt(0)!==46||/^\.[\w-]+\{/.test(t)?je:i0}var c0=t=>{let e=t.indexOf(":");return[Number(t.slice(0,e)),Number(t.slice(e+1))]},oP=(t,e)=>{let[r,n]=c0(t),[o,s]=c0(e);return r!==o?r<o:n<s},sP=t=>t.getAttribute("data-tier")||je,l0=new WeakMap;function uu(t,e){let r=t||Jn();if(!r||!r.head)return null;let n=e||je,o=l0.get(r);o||(o=new Map,l0.set(r,o));let s=o.get(n);if(s&&s.ownerNode&&s.ownerNode.parentNode===r.head)return s;n!==je&&uu(r,je);let i=n===je?r.head.querySelector("style[data-smbls]:not([data-tier])"):r.head.querySelector(`style[data-smbls][data-tier="${n}"]`);if(!i){i=r.createElement("style"),i.setAttribute("data-smbls",""),n!==je&&i.setAttribute("data-tier",n);let c=r.head.querySelectorAll("style[data-smbls]"),l=null;for(let u=0;u<c.length;u++)if(oP(n,sP(c[u]))){l=c[u];break}let f=c.length?c[c.length-1]:null;l?r.head.insertBefore(i,l):f?r.head.insertBefore(i,f.nextSibling):r.head.appendChild(i)}let a=i.sheet;return o.set(n,a),n===je&&(u0=a),a}function iP(t){let e=t||Jn();if(!e||!e.head)return[];let r=[],n=e.head.querySelectorAll("style[data-smbls]");for(let o=0;o<n.length;o++)n[o].sheet&&r.push(n[o].sheet);return r}var aP=8;function he(t,e,r,n){if(!t||typeof t!="object")return"";let o=!!(n&&n.state),s=null,i=0,a=[],c=[],l=Object.keys(t);for(let u=0;u<l.length;u++){let d=l[u],g=t[d];g==null||g===!1||g===""||(typeof g=="object"?c.push([d,g]):cy?(s||(s=[]),s.push(d,String(g)),i++):a.push(n0(d,String(g),r)))}if(s&&i>=aP){let u=s.join("\0"),d=cy(u),g=d.indexOf("\0"),p=d.substring(0,g),h=d.substring(g+1);if(h){let m=h.split(`
53
- `);for(let _=0;_<m.length;_++)m[_]&&Ne(m[_],void 0,"atomic")}a.push(p)}else if(s)for(let u=0;u<s.length;u+=2)a.push(n0(s[u],s[u+1],r));let f=[];for(let u=0;u<c.length;u++)f.push(uP(c[u][0],c[u][1],r,o));return a.concat(f).join(" ").trim()}var f0=new Map,cP=/^&?:(hover|focus|focus-visible|focus-within|active)(?![\w-])/;function sc(t){return/^@(media|supports|container)\b/.test(t)}function lP(t){return typeof t!="string"||!t||sc(t)?!1:t.split(",").every(e=>cP.test(e.trim()))}var h0=t=>{let e=Object.prototype.toString.call(t);return e==="[object Object]"||e==="[object Array]"},fy=32,uy=1024,dy=!1;function iu(t,e,r){if(dy)return;dy=!0;let n=[e,...r],o=n.length>12?[...n.slice(0,6),`\u2026${n.length-9} more\u2026`,...n.slice(-3)]:n;console.warn(`[@symbo.ls/css] ${t} at ${o.join(" > ")} \u2014 skipped. A style block may hold only CSS values and nested plain blocks; the rest of this rule is still emitted. (One warning per page.)`)}function fP(t){try{return JSON.stringify(t)}catch{let r=[],n=0;return JSON.stringify(t,function(o,s){if(!s||typeof s!="object")return s;for(;r.length&&r[r.length-1]!==this;)r.pop();if(!(r.length&&(r.includes(s)||!h0(s)||r.length>fy||++n>uy)))return r.push(s),s})}}function uP(t,e,r,n){let o=fP(e),s=t.indexOf(":hover")!==-1||o.indexOf(":hover")!==-1,i=s&&my(),a=(r?r+"":"")+t+o+(s&&!i?"rawhover":"")+(n?"state":""),c=ls.get(a);if(c){let w=f0.get(c);if(w)for(let S=0;S<w.length;S++)Ne(w[S],void 0,"atomic");return c}c=r?`_${r}_c${lu(a)}`:`_c${lu(a)}`;let l=n?`.${c}.${c}`:`.${c}`,f=lP(t)?`${l}.${c}`:l,u="",d=[],g=w=>typeof w=="string"&&(w.indexOf("{")!==-1||w.indexOf("}")!==-1),p=new Set,h=0,m=(w,S)=>{p.add(S);let C="",O=Object.keys(S);for(let L=0;L<O.length;L++){let T=O[L],M=S[T];if(M!=null)if(typeof M=="object"){let U=[...w,T];p.has(M)?iu("a style value that loops back to one of its own ancestors",t,U):h0(M)?U.length>fy?iu(`a style block nested more than ${fy} levels deep`,t,U):++h>uy?iu(`a style object with more than ${uy} nested blocks`,t,U):m(U,M):iu(`a ${Object.prototype.toString.call(M).slice(8,-1)} (not a style block)`,t,U)}else{if(g(M))continue;C+=cs(Zn(T),M)}}p.delete(S),C&&(w.length===0?u+=C:d.push({chain:w,body:C}))};m([],e);let _=w=>w.startsWith(":")||w.startsWith("["),x=(w,S=!0)=>{let C=S&&w.length===1?f:l;if(!w.length)return C;let O=w[0].split(",").map(L=>L.trim()).map(L=>L.includes("&")?L.replace(/&/g,C):_(L)?`${C}${L}`:`${C} ${L}`);for(let L=1;L<w.length;L++){let T=w[L].split(",").map(U=>U.trim()),M=[];for(let U of O)for(let rt of T)rt.includes("&")?M.push(rt.replace(/&/g,U)):_(rt)?M.push(U+rt):M.push(U+" "+rt);O=M}return O.join(", ")},y=[],b=(w,S)=>{let C=w.filter(sc),O=x(w.filter(T=>!sc(T)),C.length===0),L=`${O}{${S}}`;for(let T=C.length-1;T>=0;T--)L=`${C[T]}{${L}}`;L=xr(L,O,i),y.push(L),Ne(L,void 0,"atomic")};u&&b([t],u);for(let w of d)b([t,...w.chain],w.body);return f0.set(c,y),ls.set(a,c),c}function wt(t){if(t==null||typeof t!="string"&&typeof t!="object")return;if(uu(),typeof t=="string"){let s=t.indexOf("--")!==-1;Ne(t,void 0,s?"variable":"global"),s&&r0(1);return}let e=my(),r=0,n=Object.keys(t),o=s=>{let i=s.match(/max-width:\s*(\d+)/);return i?parseInt(i[1]):0};n.sort((s,i)=>{let a=s.startsWith("@media"),c=i.startsWith("@media");return!a&&!c?0:a?c?o(i)-o(s):1:-1});for(let s of n){let i=t[s];if(s.startsWith("@keyframes")){let a=ly(i);a&&Ne(`${s}{${a}}`,void 0,"keyframes");continue}if(sc(s))for(let a in i){let c=i[a];if(a.startsWith("@keyframes")){let l=ly(c);l&&Ne(`${s}{${a}{${l}}}`,void 0,"keyframes");continue}if(typeof c=="object"&&c!==null){let l="",f=0;for(let u in c){let d=u.charCodeAt(0)===45&&u.charCodeAt(1)===45;d&&f++;let g=d?u:Zn(u);l+=cs(g,c[u])}r+=f,Ne(xr(`${s}{${a}{${l}}}`,a,e),void 0,f?"variable":"global")}else{let l=a.charCodeAt(0)===45&&a.charCodeAt(1)===45;l&&r++;let f=l?a:Zn(a);Ne(`${s}{${cs(f,c)}}`,void 0,l?"variable":"global")}}else{let a="",c=!1,l=0;for(let f in i){let u=i[f];if(typeof u=="object"&&u!==null)c=!0;else{let d=f.charCodeAt(0)===45&&f.charCodeAt(1)===45;d&&l++;let g=d?f:Zn(f);a+=cs(g,u)}}if(r+=l,a&&Ne(xr(`${s}{${a}}`,s,e),void 0,l?"variable":"global"),c){let f=[],u=[];for(let d in i)typeof i[d]=="object"&&i[d]!==null&&(sc(d)?f.push(d):u.push(d));f.sort((d,g)=>{let p=h=>{let m=h.match(/max-width:\s*(\d+)/);return m?parseInt(m[1]):0};return p(g)-p(d)});for(let d of u)wt({[`${s} ${d}`]:i[d]});for(let d of f)wt({[d]:{[s]:i[d]}})}}}r>0&&r0(r)}function fs(t,e){return Ne(`@keyframes ${t}{${ly(e)}}`,void 0,"keyframes"),t}function g0(){ls.clear(),u0=null,dy=!1}function yy(){return ls.size}D();var mb={};$(mb,{DELEGATED_EVENTS:()=>gs,LIFECYCLE_EVENTS:()=>nn,MIXINS:()=>du,NON_BUBBLING_EVENTS:()=>pu,REGISTRY:()=>Nt,SVG_TAGS:()=>ps,addDelegatedEvent:()=>ac,addMethods:()=>xs,applyExtends:()=>ys,cacheNode:()=>rn,create:()=>ne,createHTMLNode:()=>ds,detectTag:()=>en,dispose:()=>kr,flushMounts:()=>mc,globalEventKeyInfo:()=>hu,isSvgTag:()=>hs,isValidTag:()=>us,refreshContextProto:()=>ku,registerEvent:()=>ms,registerGlobalEvent:()=>gu,remove:()=>ws,removeDelegatedEvent:()=>cc,update:()=>bs});var _y="http://www.w3.org/2000/svg",ps=new Set(["svg","path","circle","ellipse","line","polyline","polygon","rect","g","defs","use","symbol","clipPath","mask","pattern","image","text","tspan","textPath","marker","linearGradient","radialGradient","stop","filter","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feFlood","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","feSpecularLighting","feTile","feTurbulence","animate","animateMotion","animateTransform","set","foreignObject","desc","title","metadata"]),dP=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","menu","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","search","section","select","slot","small","source","span","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","string","fragment","shadow"]);function us(t){return dP.has(t)||ps.has(t)}function hs(t){return ps.has(t)}function en(t){let{tag:e,key:r}=t;if(typeof e=="function")try{e=e(t,t.state,t.context)}catch(s){e=void 0,typeof console<"u"&&console.error&&console.error(`[smbls] \`tag:\` factory threw on "${r||"<anon>"}" \u2014 falling back to key-based tag detection:`,s?.message||s)}if(e===!0&&(e=r),typeof e=="string"&&us(e))return e;if(!r||typeof r!="string")return"div";let n=new Set(["html","head","body","meta","link","script","style","title","base","noscript","template","th","tr","td","thead","tbody","tfoot","caption","col","colgroup"]),o=r.toLowerCase();return o.includes(".")&&(o=o.split(".")[0]),o.includes("_")&&(o=o.split("_")[0]),us(o)&&!n.has(o)?o:"div"}var m0={};function ds(t,e){let r=e?.context?.document||globalThis.document;if(!r)return null;if(t==="string")return r.createTextNode(e?.text||"");if(t==="fragment")return r.createDocumentFragment();if(hs(t)){let n=e?.parent;if(t==="svg"||n?.node?.namespaceURI===_y)return r.createElementNS(_y,t);if(t!=="svg")return r.createElement("div")}return r.createElement(t)}function rn(t){let e=t.tag=en(t),n=hs(e)&&(e==="svg"||t.parent?.node?.namespaceURI===_y)?"svg:"+e:e,o=t?.context?.document||globalThis.document,s=m0[n];if(s||(s=m0[n]=ds(e,t)),!s)return null;let i=o&&s.ownerDocument!==o?ds(e,t):s.cloneNode(!0);return e==="string"&&(i.nodeValue=t.text||""),i}var Nt=new Set(["extends","children","content","childrenAs","childExtends","childExtendsRecursive","childProps","inheritParentProps","state","if","define","deps","tag","attr","style","text","html","value","data","classlist","class","scope","root","context","$router","routes","fetch","variables","query","key","component","preventContentUpdate","preventContentRecreate","subscribeTo","autoGrow","srcObject","allowRuntimeTemplates","__name","__ref","__hash","__text","parent","node"]),du={text:"text",html:"html",style:"style",attr:"attr",data:"data",classlist:"classlist",state:"state",scope:"scope"},nn=new Set(["start","init","complete","attachNode","stateInit","stateCreated","beforeUpdate","update","afterUpdate","beforeClassAssign","lazyLoad","render","renderRouter","done","create","frame","mounted","contentUpdate","startUpdate","stateUpdate","beforeStateUpdate","initInspect","initSync","beforeRemove","remove"]),pu=new Set(["load","error","abort","scroll","canplay","canplaythrough","ended","pause","play","playing","ratechange","seeked","seeking","stalled","suspend","timeupdate","volumechange","waiting","durationchange","loadeddata","loadedmetadata","progress","emptied","resize"]),wy=new Set(["wheel","mousewheel","touchstart","touchmove","touchend","touchcancel"]),gs=new Set(["click","dblclick","mousedown","mouseup","mousemove","mouseenter","mouseleave","mouseover","mouseout","pointerdown","pointerup","pointermove","pointerenter","pointerleave","pointerover","pointerout","touchstart","touchend","touchmove","keydown","keyup","keypress","input","change","submit","reset","focus","blur","focusin","focusout","wheel","contextmenu","drag","dragstart","dragend","dragenter","dragleave","dragover","drop"]);var Sy=new WeakMap,pP={passive:!0},hP={passive:!0,capture:!0},ky=(t,e)=>wy.has(t)?e?hP:pP:e||!1;function _0(t){let e=Sy.get(t);return e||(e={handlers:new Map,installed:new Set},Sy.set(t,e)),e}function gP(t,e){let r=_0(e);if(r.installed.has(t))return;r.installed.add(t);let n=t==="focus"||t==="blur"||t==="focusin"||t==="focusout"||t==="mouseenter"||t==="mouseleave"||t==="pointerenter"||t==="pointerleave",o=t==="mouseenter"||t==="mouseleave"||t==="pointerenter"||t==="pointerleave";e.addEventListener(t,s=>{if(o){let a=s.target,c=r.handlers.get(t),l=c&&a?c.get(a):null;if(!l||s.relatedTarget&&typeof a.contains=="function"&&a.contains(s.relatedTarget))return;l(s);return}let i=s.target;for(;i&&i!==e;){let a=r.handlers.get(t);if(a){let c=a.get(i);if(c&&(c(s),s.cancelBubble))return}i=i.parentNode}},ky(t,n))}function ac(t,e,r,n){n||(n=e.ownerDocument?.documentElement||e.getRootNode());let o=_0(n);gP(t,n),o.handlers.has(t)||o.handlers.set(t,new WeakMap),o.handlers.get(t).set(e,r)}function cc(t,e,r){r||(r=e.ownerDocument?.documentElement||e.getRootNode());let n=Sy.get(r);if(!n)return;let o=n.handlers.get(t);o&&o.delete(e)}function y0(t){return gs.has(t)&&!nn.has(t)}function w0(t,e){let{context:r}=t,n=r?.designSystem;return o=>{n&&ct(n);try{let s=e.call(t,o,t,t.state,r);if(s&&typeof s.then=="function"){s.catch(i=>{t.error=i,console.error("[DOMQL] Async event error:",i)}).finally(()=>{n&&it()});return}}catch(s){if(t.error=s,console.error("[DOMQL] Event error:",s),r?.strictMode)throw s}n&&it()}}function ms(t,e,r){let{node:n,context:o}=e;if(!n)return;let s=w0(e,r),i=pu.has(t);if(!i&&y0(t)){let a=o?.rootNode||n.ownerDocument?.documentElement;ac(t,n,s,a)}else n.addEventListener(t,s,ky(t,!1));e.__ref.__eventCleanup||(e.__ref.__eventCleanup=[]),e.__ref.__eventCleanup.push(()=>{if(!i&&y0(t)){let a=o?.rootNode||n.ownerDocument?.documentElement;cc(t,n,a)}else n.removeEventListener(t,s,ky(t,!1))})}var xy=[["onDocument","document"],["onWindow","window"],["onVisualViewport","visualViewport"],["onMediaQuery","mediaQuery"]];function hu(t){if(typeof t!="string")return null;for(let e=0;e<xy.length;e++){let r=xy[e][0];if(t.length<=r.length||!t.startsWith(r))continue;let n=t.charCodeAt(r.length);if(!(n<65||n>90))return{target:xy[e][1],eventName:t.slice(r.length).toLowerCase()}}return null}var mP=/^[A-Za-z_$][\w$]*$/;function yP(t,e,r){let n=e,o=!1,s,i=!1,a=null;if(e&&typeof e=="object"&&typeof e!="function"&&(n=e.handler,o=!!e.capture,i=!!e.once,typeof e.passive=="boolean"&&(s=e.passive),typeof e.query=="string"&&(a=e.query)),typeof n=="string"&&mP.test(n)){let c=n;n=function(f){return t.call(c,f)}}return typeof n!="function"?null:(s===void 0&&(s=wy.has(r)),{handler:n,capture:o,passive:s,once:i,query:a})}function bP(t,e,r){let n=t.node?.ownerDocument||t.context?.document||(typeof document<"u"?document:null);if(!n||typeof n.addEventListener!="function")return null;if(e==="document")return n;let o=n.defaultView||(typeof window<"u"?window:null);if(!o)return null;if(e==="window")return typeof o.addEventListener=="function"?o:null;if(e==="visualViewport"){let s=o.visualViewport;return s&&typeof s.addEventListener=="function"?s:null}if(e==="mediaQuery"){let s=r&&r.query;if(typeof s!="string"||!s.trim()||typeof o.matchMedia!="function")return null;try{return o.matchMedia(s)||null}catch{return null}}return null}function _P(t,e,r,n){try{return t.addEventListener(e,r,n),!0}catch{return typeof t.addListener=="function"?(t.addListener(r),!0):!1}}function wP(t,e,r,n){try{t.removeEventListener(e,r,n)}catch{typeof t.removeListener=="function"&&t.removeListener(r)}}function xP(t){let e=t.node;if(!e)return!1;let r=e.nodeType===11?t.__ref?.__fragmentAnchor:e;return r?r.isConnected!==!1:!1}function gu(t,e,r){if(e.__ref){if(Array.isArray(r)){if(t.target!=="mediaQuery")return;for(let o=0;o<r.length;o++)b0(t,e,r[o]);return}b0(t,e,r)}}function b0(t,e,r){let n=e.__ref,o=yP(e,r,t.eventName);if(!o||t.target==="mediaQuery"&&t.eventName!=="change")return;let s=bP(e,t.target,o);if(!s)return;let i=t.target+":"+(o.query?o.query+":":"")+t.eventName+":"+(o.capture?1:0);if(n.__globalEvents&&n.__globalEvents.has(i))return;let a=w0(e,o.handler),c=f=>{xP(e)&&a(f)},l={capture:o.capture,passive:o.passive,once:o.once};_P(s,t.eventName,c,l)&&(n.__globalEvents||(n.__globalEvents=new Map),n.__globalEvents.set(i,{target:s,eventName:t.eventName,listener:c,options:l}),n.__eventCleanup||(n.__eventCleanup=[]),n.__eventCleanup.push(()=>{wP(s,t.eventName,c,l),n.__globalEvents&&n.__globalEvents.delete(i)}))}function x0(t){let e=[];return t.extends&&(Array.isArray(t.extends)?e.push(...t.extends):e.push(t.extends)),t.extend&&(Array.isArray(t.extend)?e.push(...t.extend):e.push(t.extend)),e}function ys(t,e,r){let n=x0(e);if(!n.length)return;let s=(t.context||r?.context||{}).components||{};for(let i=0;i<n.length;i++){let a=S0(n[i],s);a&&a!==e&&k0(t,a,r,new Set([e]))}}function S0(t,e){if(typeof t=="string"){if(t.includes(">")){let r=t.split(">").map(o=>o.trim()),n=e[r[0]]||e[`smbls.${r[0]}`];for(let o=1;o<r.length&&n;o++)n=n[r[o]];return n||null}return e[t]||e[`smbls.${t}`]||null}return typeof t=="object"&&t!==null?t:null}function k0(t,e,r,n=new Set){if(n.has(e))return;n.add(e);let o=x0(e);if(o.length){let i=(t.context||r?.context||{}).components||{};for(let a=0;a<o.length;a++){let c=S0(o[a],i);c&&k0(t,c,r,n)}}for(let s in e){if(s==="extends"||s==="extend")continue;let i=e[s];t[s]===void 0?i&&typeof i=="object"&&!Array.isArray(i)&&typeof i!="function"?t[s]={...i}:t[s]=i:typeof t[s]=="object"&&typeof i=="object"&&!Array.isArray(t[s])&&!Array.isArray(i)&&t[s]!==null&&i!==null?t[s]=v0(t[s],i):t[s]=i}}function v0(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=v0(o,s):r[n]=s}return r}Rn();D();var SP=["alert","alertdialog","application","article","banner","button","cell","checkbox","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","menuitemcheckbox","menuitemradio","navigation","none","note","option","presentation","progressbar","radio","radiogroup","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"],mu={default:["accesskey","autofocus","class","contenteditable","contextmenu","dir","draggable","hidden","id","lang","part","placeholder","slot","spellcheck","style","tabindex","title","translate","inert","radiogroup","role","about","datatype","inlist","prefix","property","resource","typeof","vocab","autocapitalize","autocorrect","autosave","color","itemprop","itemscope","itemtype","itemid","itemref","results","security","unselectable","is"],a:["accesskey","charset","coords","download","href","hreflang","name","rel","rev","shape","target","type"],aria:["aria-activedescendant","aria-atomic","aria-autocomplete","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-dropeffect","aria-errormessage","aria-expanded","aria-flowto","aria-grabbed","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext"],anchor:["download","href","hreflang","media","ping","rel","target","type","referrerpolicy"],audio:["autoplay","controls","crossorigin","loop","muted","preload","src"],area:["alt","coords","download","href","hreflang","media","referrerpolicy","rel","shape","target","ping"],base:["href","target"],blockquote:["cite"],button:["disabled","form","formaction","formenctype","formmethod","formnovalidate","formtarget","name","type","value"],canvas:["height","width"],col:["span","width"],colgroup:["span"],data:["value"],details:["open"],del:["cite","datetime"],dialog:["open"],embed:["height","src","type","width"],fieldset:["disabled","form","name"],form:["acceptcharset","action","autocomplete","enctype","method","name","novalidate","target","rel"],html:["manifest"],iframe:["allow","allowfullscreen","allowtransparency","frameborder","height","loading","marginheight","marginwidth","mozallowfullscreen","name","referrerpolicy","sandbox","scrolling","seamless","src","srcdoc","webkitallowfullscreen","width"],img:["alt","crossorigin","decoding","height","ismap","loading","referrerpolicy","sizes","src","srcset","usemap","width"],ins:["cite","datetime"],input:["accept","alt","autocomplete","capture","checked","crossorigin","disabled","form","formaction","formenctype","formmethod","formnovalidate","formtarget","height","indeterminate","list","max","maxlength","min","minlength","multiple","name","pattern","placeholder","readonly","required","size","src","step","type","value","width"],keygen:["challenge","disabled","form","keytype","keyparams","name"],label:["form","for"],li:["value"],link:["as","crossorigin","href","hreflang","integrity","media","imagesrcset","imagesizes","referrerpolicy","rel","sizes","type","charset"],map:["name"],menu:["type"],media:["autoplay","controls","currenttime","defaultmuted","defaultplaybackrate","loop","mediagroup","muted","playsinline","preload","src","volume"],meta:["charset","content","http-equiv","name","media"],meter:["form","high","low","max","min","optimum","value"],quote:["cite"],object:["classid","data","form","height","name","type","usemap","width","wmode"],ol:["reversed","start","type"],optgroup:["disabled","label"],option:["disabled","label","selected","value"],output:["form","for","name"],param:["name","value"],progress:["max","value"],slot:["name"],script:["async","charset","crossorigin","defer","integrity","nomodule","nonce","referrerpolicy","src","type"],select:["autocomplete","disabled","form","multiple","name","required","size","value","onchange"],source:["height","media","sizes","src","srcset","type","width"],style:["media","nonce","scoped","type"],table:["align","bgcolor","border","cellpadding","cellspacing","frame","rules","summary","width"],textarea:["autocomplete","cols","dirname","disabled","form","maxlength","minlength","name","placeholder","readonly","required","rows","value","wrap"],td:["align","colspan","headers","rowspan","scope","abbr","height","width","valign"],th:["align","colspan","headers","rowspan","scope","abbr"],time:["datetime"],track:["default","kind","label","src","srclang"],video:["autoplay","controls","crossorigin","disablepictureinpicture","disableremoteplayback","height","loop","muted","playsinline","poster","preload","src","width"],svg:["className","class","color","height","id","lang","max","media","method","min","name","style","target","type","width","role","tabindex","crossorigin","accent-height","accumulate","additive","alignment-baseline","allowReorder","alphabetic","amplitude","arabic-form","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baseline-shift","baseProfile","bbox","begin","bias","by","calcMode","cap-height","clip","clip-path","clipPathUnits","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominant-baseline","dur","dx","dy","edgeMode","elevation","enable-background","end","exponent","externalResourcesRequired","fill","fill-opacity","fill-rule","filter","filterRes","filterUnits","flood-color","flood-opacity","focusable","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","format","from","fx","fy","g1","g2","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","glyphRef","gradientTransform","gradientUnits","hanging","href","horiz-adv-x","horiz-origin-x","ideographic","image-rendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letter-spacing","lighting-color","limitingConeAngle","local","marker-end","markerHeight","marker-mid","marker-start","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overline-position","overline-thickness","paint-order","panose-1","path","pathLength","patternContentUnits","patternTransform","patternUnits","pointer-events","points","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","rendering-intent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","scale","seed","shape-rendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","string","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","surfaceScale","systemLanguage","tableValues","targetX","targetY","text-anchor","text-decoration","textLength","text-rendering","to","transform","u1","u2","underline-position","underline-thickness","unicode","unicode-bidi","unicode-range","units-per-em","v-alphabetic","values","vector-effect","version","vert-adv-y","vert-origin-x","vert-origin-y","v-hanging","v-ideographic","viewBox","viewTarget","visibility","v-mathematical","widths","word-spacing","writing-mode","x1","x2","x","xChannelSelector","x-height","xlink:actuate","xlink:arcrole","xlink:href","xlink:role","xlink:show","xlink:title","xlink:type","xml:base","xml:lang","xmlns","xmlns:xlink","xml:space","y1","y2","y","yChannelSelector","z","zoomAndPan"]},E0=["oncopy","oncut","onpaste","oncompositionend","oncompositionstart","oncompositionupdate","onfocus","onfocusin","onfocusout","onblur","onchange","onbeforeinput","oninput","onreset","onsubmit","oninvalid","onformdata","onload","onerror","ontoggle","onkeydown","onkeypress","onkeyup","onabort","oncanplay","oncanplaythrough","oncuechange","ondurationchange","onemptied","onencrypted","onended","onloadeddata","onloadedmetadata","onloadstart","onpause","onplay","onplaying","onprogress","onratechange","onseeked","onseeking","onstalled","onsuspend","ontimeupdate","onvolumechange","onwaiting","onauxclick","onclick","oncontextmenu","ondblclick","ondrag","ondragend","ondragenter","ondragexit","ondragleave","ondragover","ondragstart","ondrop","onmousedown","onmouseenter","onmouseleave","onmousemove","onmouseout","onmouseover","onmouseup","onselect","onselectionchange","onselectstart","ontouchcancel","ontouchend","ontouchmove","ontouchstart","ongotpointercapture","onpointercancel","onpointerdown","onpointerenter","onpointerleave","onpointermove","onpointerout","onpointerover","onpointerup","onlostpointercapture","onscroll","onresize","onwheel","onanimationstart","onanimationend","onanimationiteration","ontransitionstart","ontransitionrun","ontransitionend","ontransitioncancel","onoutrostart","onoutroend","onintrostart","onintroend","onmessage","onmessageerror","onvisibilitychange","oncancel","onclose","onfullscreenchange","onfullscreenerror"],or=t=>t.startsWith("aria")&&t.length>4&&t.charCodeAt(4)>=65&&t.charCodeAt(4)<=90?"aria-"+t.charAt(4).toLowerCase()+t.slice(5).replace(/([A-Z])/g,e=>"-"+e.toLowerCase()):t.startsWith("data")&&t.length>4&&t.charCodeAt(4)>=65&&t.charCodeAt(4)<=90?"data-"+t.charAt(4).toLowerCase()+t.slice(5).replace(/([A-Z])/g,e=>"-"+e.toLowerCase()):A0(t),kP=new Set(["tabIndex","readOnly","maxLength","minLength","autoComplete","autoFocus","autoPlay","contentEditable","spellCheck","colSpan","rowSpan","srcSet","crossOrigin","accessKey","inputMode","enterKeyHint","formAction","noValidate"]),A0=t=>kP.has(t)?t.toLowerCase():null,vP=new Set(["draggable","contenteditable","spellcheck","autocorrect"]),sr=t=>typeof t=="string"&&(vP.has(t)||t.startsWith("aria-")),re=(t,e)=>e!==!0&&e!==!1?e:sr(t)?e?"true":"false":e===!0?"":e,Te=(t,e)=>e.startsWith("aria-")||e.startsWith("data-")||or(e)||mu.default.includes(e)?!0:Object.prototype.hasOwnProperty.call(mu,t)?mu[t].includes(e):!1,Cy=t=>{if(!k(t))return!1;let e=t.toLowerCase();return E0.includes(e)},CP=(t,e,r)=>{let n={};for(let o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(r&&o in r)continue;if(o==="aria"&&e[o]&&typeof e[o]=="object"){for(let a in e[o])Tt(e[o][a])&&(n["aria-"+a]=e[o][a]);continue}if(o==="data"&&e[o]&&typeof e[o]=="object"){for(let a in e[o])if(Tt(e[o][a])){let c=a.replace(/([A-Z])/g,l=>"-"+l.toLowerCase());n["data-"+c]=e[o][a]}continue}let s=Te(t,o),i=Cy(o);if(Tt(e[o])&&(s||i)){let a=or(o)||o;n[a]=e[o]}}return n},EP=(t,e)=>{let r={};if(t.attr)for(let n in t.attr)r[n]=t.attr[n](e,e.state,e.context);if(t.aria&&typeof t.aria=="object")for(let n in t.aria){let o=t.aria[n];typeof o=="function"&&(r["aria-"+n]=o(e,e.state,e.context))}if(t.data&&typeof t.data=="object")for(let n in t.data){let o=t.data[n];if(typeof o=="function"){let s=n.replace(/([A-Z])/g,i=>"-"+i.toLowerCase());r["data-"+s]=o(e,e.state,e.context)}}return r},on=(t,e)=>{let r=t.call("exec",e,t);if(r)return k(r)&&r.includes("{{")&&(r=t.call("replaceLiteralsWithObjectFields",r)),r},vy=(t,e)=>{let r=(t.preSrc||"")+(on(t,e)||"");if(!r)return;try{return new URL(r),r}catch{}let{context:n}=t;if(!n.files&&!n.assets)return r;if(r.startsWith("/assets/")){let o=r.slice(8),s=n.assets&&(n.assets[r]||n.assets[o]);return s&&s.content?s.content.src:r}if(r.startsWith("/files/")){let o=r.slice(7),s=n.files&&(n.files[r]||n.files[o]);return s&&s.content?s.content.src:r}if(n.assets){let o=n.assets[r];if(o&&o.content)return o.content.src}if(n.files){let o=n.files[r];if(o&&o.content)return o.content.src}return r},Qn={src:t=>vy(t,t.src),href:t=>on(t,t.href),action:t=>on(t,t.action),poster:t=>vy(t,t.poster),data:t=>on(t,t.data)},Ey=t=>{let e=t.tag||"div",r={};for(let n in Qn)if(t[n]!==void 0&&Te(e,n)){let o=Qn[n](t);o!==void 0&&(r[n]=o)}return r},C0=(t,e)=>{let r=e.context?.cases?.[t];if(r!==void 0)return R(r)?r.call(e,e):!!r},AP=(t,e,r)=>{if(t==="$"){let o=C0(e,r);return o===void 0&&(o=!!r[e]),o}let n=r[e]===!0||r.state[e];if(!n){let o=C0(e,r);o!==void 0&&(n=o)}return t==="."?!!n:!n},TP=new Set(["$",".","!"]),OP=(t,e,r)=>{let n={},o=(s,i,a,c)=>{let l=i;n[s]=f=>{if(AP(a,c,f))return R(l)?l(f):l}};for(let s in t){let i=s.charAt(0);if(!TP.has(i))continue;let a=t[s];if(!a||typeof a!="object")continue;let c=s.slice(1);for(let l in a){if(r&&l in r)continue;if(l==="aria"&&a[l]&&typeof a[l]=="object"){for(let g in a[l])o("aria-"+g,a[l][g],i,c);continue}if(l==="data"&&a[l]&&typeof a[l]=="object"){for(let g in a[l]){let p=g.replace(/([A-Z])/g,h=>"-"+h.toLowerCase());o("data-"+p,a[l][g],i,c)}continue}let f=Te(e,l),u=Cy(l);if(!f&&!u)continue;let d=or(l)||l;o(d,a[l],i,c)}}return n};function bs(t={},e={}){let r=this,n=r.__ref;if(!n)return;if((typeof t=="string"||typeof t=="number")&&(t={text:t}),!e.preventListeners&&typeof r.onBeforeUpdate=="function"&&Ay(n))try{let i=r.onBeforeUpdate(r,r.state,r.context,e);if(i&&typeof i.then=="function")i.then(()=>Sr(n,!1),a=>{Sr(n,!0),r.context?.plugins?.length&&Ot("error",r,{hook:"onBeforeUpdate",error:a})||console.error("[DOMQL] onBeforeUpdate error:",a)});else if(Sr(n,!1),i===!1)return r}catch(i){throw Sr(n,!0),i}let o=!t||Object.keys(t).length===0,s=[];gl(()=>{if(t.state&&kt(r.state)&&r.state.$update(t.state),t.text!==void 0&&(r.text=t.text,!n.__exec.text&&r.node&&_s(r,t.text??"")),t.html!==void 0&&(r.html=t.html,!n.__exec.html&&r.node&&(r.node.innerHTML=t.html)),t.style&&r.node?.style){if(!n.__exec.style)for(let i in t.style){let a=t.style[i];if(a==null)continue;let c=i.replace(/[A-Z]/g,f=>"-"+f.toLowerCase()),l=String(a).replace(/\s*!important\s*$/,"");r.node.style.setProperty(c,l,"important")}r.style||(r.style={}),Object.assign(r.style,t.style)}if(t.attr&&r.node?.setAttribute){for(let i in t.attr){let a=t.attr[i];a==null||a===!1&&!sr(i)?r.node.removeAttribute(i):typeof a!="function"&&typeof a!="object"&&r.node.setAttribute(i,re(i,a))}r.attr||(r.attr={}),Object.assign(r.attr,t.attr)}if(t.data&&r.node?.dataset){for(let i in t.data)r.node.dataset[i]=t.data[i];r.data||(r.data={}),Object.assign(r.data,t.data)}for(let i in t){if(Nt.has(i)||i==="state")continue;let a=t[i],c=r[i];if(c&&c.__ref&&typeof c.update=="function")c.update(a,e);else if(typeof a=="object"&&a!==null){let l=i.charCodeAt(0);l>=65&&l<=90&&ne(a,r,i,e)}else i!=="text"&&i!=="html"&&i!=="style"&&i!=="attr"&&i!=="data"&&(r[i]=a,typeof a!="function"&&s.push(i))}});for(let i=0;i<s.length;i++)R0(r,s[i]);if(r.node){for(let i=0;i<s.length;i++)if(T0(s[i])){O0(r);break}}if(r.node&&o&&n.__effects&&n.__effects.length)for(let i=0;i<n.__effects.length;i++){let a=n.__effects[i];a&&!a._disposed&&!a._isSubscribeToEffect&&typeof a._execute=="function"&&a._execute()}else if(r.node&&n.__conditionalRunners)for(let i of n.__conditionalRunners)i();return Ot("update",r),!e.preventListeners&&typeof r.onUpdate=="function"&&r.onUpdate(r,r.state,r.context,e),r}function kr(t){if(!t)return;let e=t.__ref;if(!e)return;let r=Lr();if(r){Ir(null);try{return kr(t)}finally{Ir(r)}}e.__disposed=!0;try{typeof t.onBeforeRemove=="function"&&t.onBeforeRemove(t,t.state,t.context)}catch(o){console.error("[smbls] onBeforeRemove error:",o)}if(e.__effects){for(let o=0;o<e.__effects.length;o++)e.__effects[o].dispose();e.__effects.length=0}if(typeof e.__releaseMedia=="function"&&(e.__releaseMedia(),e.__releaseMedia=null),e.__eventCleanup){for(let o=0;o<e.__eventCleanup.length;o++)e.__eventCleanup[o]();e.__eventCleanup.length=0}if(e.__children){let o=e.__children.slice();e.__children.length=0;for(let s=0;s<o.length;s++){let i=t[o[s]];i&&i.__ref&&kr(i)}}t.node?.parentNode?t.node.remove():t.tag==="fragment"&&e.__fragmentAnchor?.parentNode&&e.__fragmentAnchor.remove();let n=t.state?.$destroy||t.state?.destroy;if(typeof n=="function"&&t.state.__element===t&&n.call(t.state),t.parent?.__ref?.__children){let o=t.parent.__ref.__children.indexOf(t.key);o!==-1&&t.parent.__ref.__children.splice(o,1),delete t.parent[t.key]}try{typeof t.onRemove=="function"&&t.onRemove(t)}catch(o){console.error("[smbls] onRemove error:",o)}t.node=null,t.parent=null,t.__ref=null}function ws(){kr(this)}D();D();D();var RP=["ease","linear","ease-in","ease-out","ease-in-out","step-start","step-end"],PP=["none","forwards","backwards","both"],DP=["normal","reverse","alternate","alternate-reverse"],LP=["running","paused"],IP=t=>/^[\d.]+m?s$/.test(t),$P=/^(?:translate(?:3d|x|y|z)?\((?:\s*0[a-z%]*\s*,?)+\)|scale(?:3d|x|y|z)?\((?:\s*1(?:\.0+)?\s*,?)+\)|rotate(?:3d|x|y|z)?\((?:\s*0[a-z%]*\s*,?)+\)|skew(?:x|y)?\((?:\s*0[a-z%]*\s*,?)+\)|matrix\(\s*1\s*,\s*0\s*,\s*0\s*,\s*1\s*,\s*0\s*,\s*0\s*\))$/,MP=t=>{let e=String(t).trim().toLowerCase();if(e===""||e==="none"||e==="initial"||e==="unset")return!0;let r=e.match(/[a-z0-9]+\([^()]*\)/g);return!r||r.join("").replace(/\s+/g,"")!==e.replace(/\s+/g,"")?!1:r.every(n=>$P.test(n.replace(/\s+/g,"")))},P0=t=>/^(?:\s*0[a-z%]*)+\s*$/.test(String(t).toLowerCase())||/^(none|initial|unset)$/.test(String(t).trim().toLowerCase()),FP={transform:MP,translate:P0,rotate:t=>P0(t)||/^\s*(?:[xyz]\s+)?0(?:deg|rad|turn|grad)?\s*$/.test(String(t).toLowerCase()),scale:t=>/^(none|initial|unset)$/.test(String(t).trim().toLowerCase())||/^(?:\s*1(?:\.0+)?)+\s*$/.test(String(t)),opacity:t=>/^(initial|unset)$/.test(String(t).trim().toLowerCase())||Number(t)===1},NP=t=>{let e=String(t).trim().toLowerCase();if(e==="from")return 0;if(e==="to")return 100;let r=e.match(/^(\d+(?:\.\d+)?)%$/);return r?Number(r[1]):null},jP=t=>{if(!v(t))return null;let e=null,r=-1;for(let n in t){let o=NP(n);o==null||!v(t[n])||o>=r&&(r=o,e=t[n])}return e},BP=t=>{let e=jP(t);if(!e)return!1;let r=Object.keys(e);if(!r.length)return!1;for(let n of r){let o=FP[n];if(!o)return!1;let s=e[n];if(s==null||typeof s=="object"||typeof s=="function"||!o(s))return!1}return!0},VP=(t,e)=>{if(v(t))return t;let{animation:r}=e.context&&e.context.designSystem||{},n=r&&r[t];return v(n)?n:null},UP=["reverse","alternate","alternate-reverse"],D0=(t,e,r)=>{let n=r||e.animationDirection;return n&&UP.includes(String(n))?"both":BP(VP(t,e))?"backwards":"both"},zP=0,L0=new Map,Ty=(t,e)=>{let{animation:r}=e.context&&e.context.designSystem||{};if(v(t)){let o=JSON.stringify(t),s=L0.get(o);if(s)return s;let i=`smbls-anim-${zP++}`,a=fs(i,t);return L0.set(o,a),a}let n=r&&r[t];return v(n)?fs(t,n):t},HP=t=>{let e=[],r=0,n="";for(let o of String(t).trim())o==="("?r++:o===")"&&r>0&&r--,r===0&&/\s/.test(o)?(n&&e.push(n),n=""):n+=o;return n&&e.push(n),e},WP=(t,e)=>{let{animation:r}=e.context&&e.context.designSystem||{},n=HP(t),o=null,s=[],i=null,a=null,c=null,l=null,f=null;for(let u of n)r&&r[u]?o=u:IP(u)?s.push(u):RP.includes(u)||u.startsWith("cubic-bezier")||u.startsWith("steps(")||u.startsWith("linear(")?i=u:u==="infinite"||/^\d+$/.test(u)?a=u==="infinite"?u:Number(u):DP.includes(u)?c=u:PP.includes(u)?l=u:LP.includes(u)?f=u:o||(o=u);return{name:o,durations:s,timingFunction:i,iterationCount:a,direction:c,fillMode:l,playState:f}},Oy={animation:(t,e)=>{if(t!=null){if(k(t)&&t.includes(" ")){let r=WP(t,e);return{animationName:Ty(r.name||t,e),animationDuration:r.durations[0]||pe(e.animationDuration||"A").timing,animationDelay:r.durations[1]||pe(e.animationDelay||"0s").timing,animationTimingFunction:r.timingFunction||Ae(e.animationTimingFunction||"ease"),animationFillMode:r.fillMode||e.animationFillMode||D0(r.name||t,e,r.direction),animationIterationCount:r.iterationCount!=null?r.iterationCount:e.animationIterationCount||1,animationPlayState:r.playState||e.animationPlayState,animationDirection:r.direction||e.animationDirection}}return{animationName:Ty(t,e),animationDuration:pe(e.animationDuration||"A").timing,animationDelay:pe(e.animationDelay||"0s").timing,animationTimingFunction:Ae(e.animationTimingFunction||"ease"),animationFillMode:e.animationFillMode||D0(t,e),animationIterationCount:e.animationIterationCount||1,animationPlayState:e.animationPlayState,animationDirection:e.animationDirection}}},animationName:(t,e)=>({animationName:Ty(t,e)}),animationDuration:t=>({animationDuration:pe(t).timing}),animationDelay:t=>({animationDelay:pe(t).timing}),animationTimingFunction:t=>({animationTimingFunction:Ae(t)}),animationIterationCount:t=>({animationIterationCount:t}),animationFillMode:t=>({animationFillMode:t}),animationPlayState:t=>({animationPlayState:t}),animationDirection:t=>({animationDirection:t})};D();var yu=(t,e,r)=>{if(typeof e=="number"&&(e=String(e)),!k(e))return;let[n,o]=pt(e);return{...I(t+"Start",n,r),...I(t+"End",o||n,r)}},Ry={show:t=>t?void 0:{display:"none !important"},hide:t=>t?{display:"none !important"}:void 0,height:(t,e)=>I("height",t,e),width:(t,e)=>I("width",t,e),boxSizing:t=>Lt(t)?{boxSizing:"border-box"}:{boxSizing:t},boxSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("height",e),...vt("width",r||e)}},inlineSize:(t,e)=>I("inlineSize",t,e),blockSize:(t,e)=>I("blockSize",t,e),minWidth:(t,e)=>I("minWidth",t,e),maxWidth:(t,e)=>I("maxWidth",t,e),widthRange:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minWidth",e),...vt("maxWidth",r||e)}},minHeight:(t,e)=>I("minHeight",t,e),maxHeight:(t,e)=>I("maxHeight",t,e),heightRange:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minHeight",e),...vt("maxHeight",r||e)}},size:t=>{if(!k(t))return;let[e,r]=pt(t);return{...I("inlineSize",e),...I("blockSize",r||e)}},minBlockSize:(t,e)=>I("minBlockSize",t,e),minInlineSize:(t,e)=>I("minInlineSize",t,e),maxBlockSize:(t,e)=>I("maxBlockSize",t,e),maxInlineSize:(t,e)=>I("maxInlineSize",t,e),minSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minInlineSize",e),...vt("minBlockSize",r||e)}},maxSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("maxInlineSize",e),...vt("maxBlockSize",r||e)}},borderWidth:(t,e)=>I("borderWidth",t,e),borderTopWidth:(t,e)=>I("borderTopWidth",t,e),borderRightWidth:(t,e)=>I("borderRightWidth",t,e),borderBottomWidth:(t,e)=>I("borderBottomWidth",t,e),borderLeftWidth:(t,e)=>I("borderLeftWidth",t,e),textDecorationThickness:(t,e)=>I("textDecorationThickness",t,e),textUnderlineOffset:(t,e)=>I("textUnderlineOffset",t,e),padding:(t,e)=>I("padding",t,e),paddingInline:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("paddingInlineStart",e),...vt("paddingInlineEnd",r||e)}},paddingBlock:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("paddingBlockStart",e),...vt("paddingBlockEnd",r||e)}},paddingTop:(t,e)=>I("paddingBlockStart",t,e),paddingBottom:(t,e)=>I("paddingBlockEnd",t,e),paddingLeft:(t,e)=>I("paddingInlineStart",t,e),paddingRight:(t,e)=>I("paddingInlineEnd",t,e),paddingBlockStart:(t,e)=>I("paddingBlockStart",t,e),paddingBlockEnd:(t,e)=>I("paddingBlockEnd",t,e),paddingInlineStart:(t,e)=>I("paddingInlineStart",t,e),paddingInlineEnd:(t,e)=>I("paddingInlineEnd",t,e),margin:(t,e)=>I("margin",t,e),marginInline:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("marginInlineStart",e),...vt("marginInlineEnd",r||e)}},marginBlock:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("marginBlockStart",e),...vt("marginBlockEnd",r||e)}},marginTop:(t,e)=>I("marginBlockStart",t,e),marginBottom:(t,e)=>I("marginBlockEnd",t,e),marginLeft:(t,e)=>I("marginInlineStart",t,e),marginRight:(t,e)=>I("marginInlineEnd",t,e),marginInlineStart:(t,e)=>I("marginInlineStart",t,e),marginInlineEnd:(t,e)=>I("marginInlineEnd",t,e),marginBlockStart:(t,e)=>I("marginBlockStart",t,e),marginBlockEnd:(t,e)=>I("marginBlockEnd",t,e),scrollMargin:(t,e)=>I("scrollMargin",t,e),scrollMarginTop:(t,e)=>I("scrollMarginTop",t,e),scrollMarginRight:(t,e)=>I("scrollMarginRight",t,e),scrollMarginBottom:(t,e)=>I("scrollMarginBottom",t,e),scrollMarginLeft:(t,e)=>I("scrollMarginLeft",t,e),scrollMarginBlock:(t,e)=>yu("scrollMarginBlock",t,e),scrollMarginInline:(t,e)=>yu("scrollMarginInline",t,e),scrollMarginBlockStart:(t,e)=>I("scrollMarginBlockStart",t,e),scrollMarginBlockEnd:(t,e)=>I("scrollMarginBlockEnd",t,e),scrollMarginInlineStart:(t,e)=>I("scrollMarginInlineStart",t,e),scrollMarginInlineEnd:(t,e)=>I("scrollMarginInlineEnd",t,e),scrollPadding:(t,e)=>I("scrollPadding",t,e),scrollPaddingTop:(t,e)=>I("scrollPaddingTop",t,e),scrollPaddingRight:(t,e)=>I("scrollPaddingRight",t,e),scrollPaddingBottom:(t,e)=>I("scrollPaddingBottom",t,e),scrollPaddingLeft:(t,e)=>I("scrollPaddingLeft",t,e),scrollPaddingBlock:(t,e)=>yu("scrollPaddingBlock",t,e),scrollPaddingInline:(t,e)=>yu("scrollPaddingInline",t,e),scrollPaddingBlockStart:(t,e)=>I("scrollPaddingBlockStart",t,e),scrollPaddingBlockEnd:(t,e)=>I("scrollPaddingBlockEnd",t,e),scrollPaddingInlineStart:(t,e)=>I("scrollPaddingInlineStart",t,e),scrollPaddingInlineEnd:(t,e)=>I("scrollPaddingInlineEnd",t,e),gap:t=>({gap:tu(t)}),columnGap:(t,e)=>Ce(e,"columnGap",t),rowGap:(t,e)=>Ce(e,"rowGap",t),flexWrap:t=>{if(t!=null)return{display:"flex",flexWrap:t}},flexFlow:(t,e)=>{let r=e.reverse;if(!k(t))return;let[n,o]=(t||"row").split(" ");return(t.startsWith("x")||t==="row")&&(n="row"),(t.startsWith("y")||t==="column")&&(n="column"),{display:"flex",flexFlow:(n||"")+(!n.includes("-reverse")&&r?"-reverse":"")+" "+(o||"")}},flexAlign:t=>{if(!k(t))return;let[e,r]=t.split(" ");return{display:"flex",alignItems:e,justifyContent:r}},round:(t,e)=>wr(t??e.borderRadius,e,"round"),borderRadius:(t,e)=>wr(t??e.round,e,"borderRadius"),borderTopLeftRadius:(t,e)=>wr(t,e,"borderTopLeftRadius","borderTopLeftRadius"),borderTopRightRadius:(t,e)=>wr(t,e,"borderTopRightRadius","borderTopRightRadius"),borderBottomLeftRadius:(t,e)=>wr(t,e,"borderBottomLeftRadius","borderBottomLeftRadius"),borderBottomRightRadius:(t,e)=>wr(t,e,"borderBottomRightRadius","borderBottomRightRadius")};var Py={fontSize:t=>Ya(t)||t,fontFamily:t=>({fontFamily:Ka(t)||t}),fontWeight:t=>({fontWeight:t,fontVariationSettings:'"wght" '+t}),lineClamp:t=>{if(t!=null)return t==="none"?{WebkitLineClamp:"none",lineClamp:"none"}:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:String(t),lineClamp:String(t),overflow:"hidden"}}};var Dy={overflow:t=>({overflow:t}),cursor:(t,e,r,n)=>{if(!t)return;let o=n.assets&&n.assets[t];if(o&&o.content)t=`url(${o.content.src})`;else{let s=n.files&&n.files[t];s&&s.content&&(t=`url(${s.content.src})`)}return{cursor:t}},opacity:t=>t!=null?{opacity:String(t)}:void 0,visibility:t=>t!=null?{visibility:t}:void 0,pointerEvents:t=>t!=null?{pointerEvents:t}:void 0};var Ly={inset:(t,e)=>{if(e.call("isNumber",t))return{inset:t};if(e.call("isString",t))return{inset:pt(t).map(r=>Ct(r,"k").k).join(" ")}},left:t=>Ct(t,"left"),top:t=>Ct(t,"top"),right:t=>Ct(t,"right"),bottom:t=>Ct(t,"bottom"),verticalInset:t=>{if(typeof t!="string")return;let e=pt(t).map(r=>Ct(r,"k").k);return{top:e[0],bottom:e[1]||e[0]}},horizontalInset:t=>{if(typeof t!="string")return;let e=pt(t).map(r=>Ct(r,"k").k);return{left:e[0],right:e[1]||e[0]}}};D();var bu=0,_u=()=>{bu++},wu=()=>{bu>0&&bu--},ge=({context:t,state:e})=>{let r=t?.designSystem,n=e?.root?.globalTheme||r?.globalTheme;return n&&n!=="auto"?n:bu>0?null:r&&r.resolvedTheme||null},oe=(t,e)=>{if(e==null||e==="")return;if(!v(e))return{[t]:e};let r={},n=!1;for(let o in e){let s=e[o];if(!(s==null||s==="")){if(v(s)){let i=oe(t,s);i&&(r[o]=i,n=!0);continue}r[o]={[t]:s},n=!0}}return n?r:void 0},Iy={theme:(t,e)=>{if(t)return e.themeModifier?Ee(t,`@${e.themeModifier}`):Ee(t)},color:(t,e)=>{let r=ge(e);if(t)return oe("color",Mt(t,r))},background:(t,e)=>{let r=ge(e);if(t)return k(t)&&t.includes("gradient")&&t.includes("(")?{background:nc(t,r)}:oe("background",Mt(t,r))},backgroundColor:(t,e)=>{let r=ge(e);if(t)return oe("backgroundColor",Mt(t,r))},backgroundImage:(t,e,r,n)=>{let o=ge(e);if(!t)return;let s=n.assets&&n.assets[t];if(s&&s.content)t=s.content.src;else{let i=n.files&&n.files[t];i&&i.content&&(t=i.content.src)}return oe("backgroundImage",Qf(t,o))},textStroke:t=>{let e=Zf(t);if(e!=null)return{WebkitTextStroke:e}},outline:t=>({outline:nr(t)}),outlineWidth:(t,e)=>I("outlineWidth",t,e),outlineColor:(t,e)=>{let r=ge(e);if(t)return oe("outlineColor",Mt(t,r))},outlineOffset:(t,e)=>I("outlineOffset",t,e),border:t=>({border:nr(t)}),borderColor:(t,e)=>{let r=ge(e);if(t)return oe("borderColor",Mt(t,r))},borderTopColor:(t,e)=>{let r=ge(e);if(t)return oe("borderTopColor",Mt(t,r))},borderBottomColor:(t,e)=>{let r=ge(e);if(t)return oe("borderBottomColor",Mt(t,r))},borderLeftColor:(t,e)=>{let r=ge(e);if(t)return oe("borderLeftColor",Mt(t,r))},borderRightColor:(t,e)=>{let r=ge(e);if(t)return oe("borderRightColor",Mt(t,r))},borderLeft:t=>({borderLeft:nr(t)}),borderTop:t=>({borderTop:nr(t)}),borderRight:t=>({borderRight:nr(t)}),borderBottom:t=>({borderBottom:nr(t)}),shadow:(t,e)=>{let r=ge(e);if(t)return oe("boxShadow",Jf(t,r))},boxShadow:(t,e)=>{if(!k(t))return;let[r,n]=t.split("!importan"),o=ge(e),s=n?" !important":"",i=rc(r.trim(),o);return k(i)?{boxShadow:i+s}:oe("boxShadow",i)},textShadow:(t,{context:e})=>oe("textShadow",rc(t,e.designSystem.globalTheme)),columnRule:t=>({columnRule:nr(t)})};var lc={transition:t=>{let e=ru(t);if(e!=null)return{transition:e}},transitionDuration:t=>({transitionDuration:oc(t)}),transitionDelay:t=>({transitionDelay:oc(t)}),transitionTimingFunction:t=>({transitionTimingFunction:Ae(t)}),transitionProperty:t=>({transitionProperty:t,willChange:t})};D();var $y={flow:(t,e)=>{let r=e.reverse;if(!k(t))return;let[n,o]=(t||"row").split(" ");return(t.startsWith("x")||t==="row")&&(n="row"),(t.startsWith("y")||t==="column")&&(n="column"),{display:"flex",flexFlow:(n||"")+(!n.includes("-reverse")&&r?"-reverse":"")+" "+(o||"")}},wrap:(t,e)=>{if(t!=null)return{display:"flex",flexWrap:t}},align:(t,e)=>{if(!k(t))return;let[r,n]=t.split(" ");return{display:"flex",alignItems:r,justifyContent:n}}};D();var qP=/(^|[^\w.-])([A-Za-z_][\w-]*)/g,I0=t=>{if(!k(t))return t;let e=A().sizes;return e?t.replace(qP,(r,n,o)=>{let s=e[o];return s==null?r:n+String(s)}):t},ir=t=>I0(eu(t)),My={gridTemplateColumns:t=>({gridTemplateColumns:ir(t)}),gridTemplateRows:t=>({gridTemplateRows:ir(t)}),gridAutoColumns:t=>({gridAutoColumns:ir(t)}),gridAutoRows:t=>({gridAutoRows:ir(t)}),area:t=>({gridArea:t}),template:t=>({gridTemplate:t}),templateAreas:t=>({gridTemplateAreas:t}),column:t=>({gridColumn:t}),columns:t=>({gridTemplateColumns:ir(t)}),templateColumns:t=>({gridTemplateColumns:ir(t)}),autoColumns:t=>({gridAutoColumns:ir(t)}),columnStart:t=>({gridColumnStart:t}),row:t=>({gridRow:t}),rows:t=>({gridTemplateRows:ir(t)}),templateRows:t=>({gridTemplateRows:ir(t)}),autoRows:t=>({gridAutoRows:ir(t)}),rowStart:t=>({gridRowStart:t}),autoFlow:t=>({gridAutoFlow:t})};var xt={...Oy,...Ry,...Py,...Dy,...Ly,...Iy,...lc,...$y,...My};var Et=new Set(["accentColor","alignContent","alignItems","alignSelf","alignmentBaseline","all","animation","animationDelay","animationDirection","animationDuration","animationFillMode","animationIterationCount","animationName","animationPlayState","animationRange","animationRangeEnd","animationRangeStart","animationTimeline","animationTimingFunction","appearance","aspectRatio","backdropFilter","backfaceVisibility","background","backgroundAttachment","backgroundBlendMode","backgroundClip","backgroundColor","backgroundImage","backgroundOrigin","backgroundPosition","backgroundPositionX","backgroundPositionY","backgroundRepeat","backgroundRepeatX","backgroundRepeatY","backgroundSize","baselineShift","blockSize","border","borderBlock","borderBlockColor","borderBlockEnd","borderBlockEndColor","borderBlockEndStyle","borderBlockEndWidth","borderBlockStart","borderBlockStartColor","borderBlockStartStyle","borderBlockStartWidth","borderBlockStyle","borderBlockWidth","borderBottom","borderBottomColor","borderBottomLeftRadius","borderBottomRightRadius","borderBottomStyle","borderBottomWidth","borderCollapse","borderColor","borderImage","borderImageOutset","borderImageRepeat","borderImageSlice","borderImageSource","borderImageWidth","borderLeft","borderLeftColor","borderLeftStyle","borderLeftWidth","borderRadius","borderRight","borderRightColor","borderRightStyle","borderRightWidth","borderSpacing","borderStyle","borderTop","borderTopColor","borderTopLeftRadius","borderTopRightRadius","borderTopStyle","borderTopWidth","borderWidth","bottom","boxDecorationBreak","boxShadow","boxSizing","breakAfter","breakBefore","breakInside","captionSide","caretColor","clear","clip","clipPath","color","colorAdjust","colorInterpolation","colorInterpolationFilters","colorRendering","columnCount","columnFill","columnGap","columnRule","columnRuleColor","columnRuleStyle","columnRuleWidth","columnSpan","columnWidth","columns","contain","content","counterIncrement","counterReset","cursor","direction","display","emptyCells","filter","flex","flexBasis","flexDirection","flexFlow","flexGrow","flexShrink","flexWrap","float","font","fontFamily","fontFeatureSettings","fontKerning","fontLanguageOverride","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontVariantAlternates","fontVariantCaps","fontVariantEastAsian","fontVariantNumeric","fontVariantPosition","fontWeight","fontVariationSettings","fontSynthesis","forcedColorAdjust","gap","grid","gridArea","gridAutoColumns","gridAutoFlow","gridAutoRows","gridColumn","gridColumnEnd","gridColumnGap","gridColumnStart","gridGap","gridRow","gridRowEnd","gridRowGap","gridRowStart","gridTemplate","gridTemplateAreas","gridTemplateColumns","gridTemplateRows","height","hyphens","imageOrientation","imageRendering","imeMode","inset","insetBlock","insetBlockEnd","insetBlockStart","insetInline","insetInlineEnd","insetInlineStart","initialLetter","interpolateSize","isolation","justifyContent","justifyItems","justifySelf","left","letterSpacing","lineBreak","lineClamp","lineHeight","listStyle","listStyleImage","listStylePosition","listStyleType","margin","marginBottom","marginLeft","marginRight","marginTop","marginBlock","marginBlockEnd","marginBlockStart","marginInline","marginInlineEnd","marginInlineStart","mask","maskBorder","maskBorderImage","maskBorderOutset","maskBorderRepeat","maskBorderSlice","maskBorderSource","maskBorderWidth","maskClip","maskComposite","maskImage","maskOrigin","maskPosition","maskRepeat","maskSize","maskType","maxBlockSize","maxHeight","maxInlineSize","maxWidth","minBlockSize","minHeight","minInlineSize","minWidth","mixBlendMode","objectFit","objectPosition","objectViewBox","offset","offsetDistance","offsetPath","offsetRotate","opacity","order","orientation","outline","outlineColor","outlineOffset","outlineStyle","outlineWidth","overflow","overflowAnchor","overflowClip","overflowScrolling","overflowWrap","overflowX","overflowY","overscrollBehavior","overscrollBehaviorX","overscrollBehaviorY","padding","paddingBottom","paddingLeft","paddingRight","paddingTop","pageBreakAfter","pageBreakBefore","pageBreakInside","paintOrder","perspective","perspectiveOrigin","placeContent","placeItems","placeSelf","pointerEvents","position","resize","right","rotate","rowGap","scrollBehavior","scrollMargin","scrollMarginBlock","scrollMarginBlockEnd","scrollMarginBlockStart","scrollMarginBottom","scrollMarginInline","scrollMarginInlineEnd","scrollMarginInlineStart","scrollMarginLeft","scrollMarginRight","scrollMarginTop","scrollPadding","scrollPaddingBlock","scrollPaddingBlockEnd","scrollPaddingBlockStart","scrollPaddingBottom","scrollPaddingInline","scrollPaddingInlineEnd","scrollPaddingInlineStart","scrollPaddingLeft","scrollPaddingRight","scrollPaddingTop","scrollSnapAlign","scrollSnapStop","scrollSnapType","scrollTimeline","scrollTimelineAxis","scrollTimelineName","scrollbarColor","scrollbarGutter","scrollbarWidth","shapeImageThreshold","shapeMargin","shapeOutside","tabSize","tableLayout","textAlign","textAlignLast","textDecoration","textDecorationColor","textDecorationLine","textDecorationSkipInk","textDecorationStyle","textDecorationThickness","textIndent","textOverflow","textShadow","textTransform","textUnderlineOffset","timelineScope","top","touchAction","transform","transformOrigin","transformStyle","transition","transitionDelay","transitionDuration","transitionProperty","transitionTimingFunction","translate","translateX","translateY","translateZ","unicodeBidi","userSelect","verticalAlign","viewTimeline","viewTimelineAxis","viewTimelineInset","viewTimelineName","visibility","whiteSpace","widows","width","willChange","wordBreak","wordSpacing","wordWrap","writingMode","zIndex"]);D();var KP=/^-?[A-Z][0-9]?$/,GP=/^[a-z][0-9]?$/,$0=/var\(\s*(--[A-Za-z0-9-]+)/g,YP=t=>{let e=new Set,r=new Set;if(!t||typeof t!="object")return{knownLetters:e,knownVars:r};for(let n in t){let o=t[n];if(!(!o||typeof o!="object")){if(o.sequence&&typeof o.sequence=="object")for(let s in o.sequence)e.add(s);if(o.vars&&typeof o.vars=="object")for(let s in o.vars)r.add(s)}}return{knownLetters:e,knownVars:r}},XP=(t,e)=>{if(!e.size)return[];let r=t.split(/[(),\s]+/).filter(Boolean),n=new Set;for(let o of r){if(!KP.test(o))continue;let s=o.charCodeAt(0)===45?o.slice(1):o;e.has(s)&&n.add(o)}return[...n]},ZP=(t,e)=>{if(!e.size)return[];let r=[];$0.lastIndex=0;let n;for(;n=$0.exec(t);){let o=n[1];if(e.has(o))continue;let s=o.lastIndexOf("-");if(s===-1)continue;let i=o.slice(s+1);if(!GP.test(i))continue;let a=o.slice(0,s+1)+i.toUpperCase();a!==o&&e.has(a)&&r.push({varName:o,corrected:a})}return r},xu=new Set,M0=(t,e,r)=>{if(!gt()||!k(e)||!e)return;let n;try{n=A()}catch{return}let{knownLetters:o,knownVars:s}=YP(n);if(!o.size&&!s.size)return;let i=XP(e,o),a=ZP(e,s);if(!i.length&&!a.length)return;let c=r?.__ref?.path?r.__ref.path.join("."):r?.key||"?";for(let l of i){let f=`${c}::${t}::bare::${l}::${e}`;xu.has(f)||(xu.add(f),console.warn(`[smbls/css-in-props] "${t}" on <${c}> looks like it contains an un-wrapped design-system token ("${l}") \u2014 "${t}" has no registered resolver, so its value is forwarded to the browser untouched. A bare letter token there is invalid CSS, so the browser drops the ENTIRE "${t}" declaration (not just this argument). Wrap it in var(--<family>-${l.replace("-","")}) (or calc(-1 * var(--<family>-${l.replace("-","")})) for a negative). Value: "${e}"`))}for(let{varName:l,corrected:f}of a){let u=`${c}::${t}::case::${l}::${e}`;xu.has(u)||(xu.add(u),console.warn(`[smbls/css-in-props] "${t}" on <${c}> references ${l}, which the active design system never emits. CSS custom-property names are case-sensitive \u2014 the real variable is ${f}, so this reference silently never resolves. Value: "${e}"`))}};D();var JP=/^\[data-theme=(?:"([^"]+)"|'([^']+)')\]$/,QP=(t,e,r)=>{let{context:n}=r;if(!n.designSystem?.media)return;let o=t.slice(1),s=n.designSystem.media[o],i=se(e,r);if(!s)return{[t]:i};if(/^@(media|supports|container)\b/.test(s))return{[s]:i};if(s==="print")return{"@media print":i};if(s[0]==="(")return{[`@media screen and ${s}`]:i};let a=s.match(JP),c=a?a[1]||a[2]:o,l={[`${s} &`]:i};if(c==="dark"||c==="light"){let f=n.designSystem?.scopeSelector||":root",u=f===":root"?":root:not([data-theme])":`${f}:not([data-theme])`;l[`@media (prefers-color-scheme: ${c})`]={[`${u} &`]:i}}return l},F0=(t,e,r)=>({[t]:se(e,r)}),fc=(t,e,r)=>{let n=`&${t}`,o=se(e,r);if(t.includes(",")&&o){let s={},i={};for(let a in o)typeof o[a]=="object"&&o[a]!==null?i[a]=o[a]:s[a]=o[a];if(Object.keys(i).length){let a=n.split(",").map(l=>l.trim()),c={};Object.keys(s).length&&(c[n]=s);for(let l in i){let f=a.map(u=>`${u} ${l}`).join(", ");c[f]=i[l]}return c}}return{[n]:o}},Fy=(t,e)=>{let r=e.context?.cases?.[t];if(r!==void 0)return R(r)?r.call(e,e):!!r},t2=(t,e,r)=>{let n=t.slice(1),o=Fy(n,r);if(o===void 0&&(o=!!r[n]),!!o)return se(e,r)},e2=(t,e,r)=>({[t]:e}),r2=(t,e,r)=>{let n=t.slice(1),o=r[n]===!0||r.state?.[n];if(!o)if(typeof r[n]=="function")try{o=r[n](r,r.state,r.context)}catch{}else{let s=Fy(n,r);s!==void 0&&(o=s)}if(o)return se(e,r)},n2=(t,e,r)=>{let n=t.slice(1),o=r[n]===!0||r.state?.[n];if(!o)if(typeof r[n]=="function")try{o=r[n](r,r.state,r.context)}catch{}else{let s=Fy(n,r);s!==void 0&&(o=s)}if(!o)return se(e,r)},Ny=(t,e)=>se(t,e),jy={"@":QP,":":fc,"[":fc,"*":fc,"+":fc,"~":fc,"&":F0,">":F0,$:t2,"-":e2,".":r2,"!":n2};var Su=jr(),N0=(t,e,r)=>{let n=e?.context?.designSystem;n&&ct(n);try{let o={},s={},i=(a,c)=>{if(r.unpack){o={...o,...c};return}o[a]=c};for(let a in t){let c=t[a];if(c!==null)if(a==="class"&&k(c)){let l=j0(c,e);l&&(r.unpack?bt(o,l):o.designSystemClass=l)}else if(a==="true"){let l=dt(c,e);bt(o,Ny(l,e))}else if(e.classlist?.[a]){let l=e.classlist[a],f=R(l)?l(e,e.state,e.context):l;f&&i(a,f),!Su&&v(o[a])&&(o[a].label=a)}else if(xt[a]){let l=dt(c,e);if(l===null)continue;P(l)&&(l=l.reduce((u,d)=>bt(u,d),{}));let f=xt[a](l,e,e.state,e.context);P(f)&&(f=f.reduce((u,d)=>bt(u,d),{})),f&&i(a,f),!Su&&v(o[a])&&(o[a].label=a)}else if(Et.has(a)){let l=dt(c,e);if(l===null)continue;typeof l=="string"&&l.charCodeAt(0)===45&&l.charCodeAt(1)===45&&(l=`var(${l})`),Su||M0(a,l,e),i(a,{[a]:l}),!Su&&v(o[a])&&(o[a].label=a)}else s[a]=c}return[o,s]}finally{n&&it()}},j0=(t,e)=>{if(!k(t))return;let r=e?.context?.designSystem?.class;if(!r)return;let n;for(let o of t.split(" ")){if(!o)continue;let s=r[o];if(!v(s))continue;let i=lt(s);n=n?Wt(n,i):i}if(n)return se(n,e)},B0=(t,e)=>{let r={};for(let n in t){let o=jy[n.slice(0,1)];if(o){let s=o(n,t[n],e);if(s)for(let i in s)Object.prototype.hasOwnProperty.call(s,i)&&(r[i]&&typeof r[i]=="object"&&typeof s[i]=="object"?Wt(r[i],s[i]):r[i]=s[i])}}return r},se=(t,e,r={unpack:!0})=>{let[n,o]=N0(t,e,r),s=B0(o,e),i=!1;for(let a in s){i=!0;break}if(i){if(r.unpack)return ki(n,s);n._selectors=s}return n},o2=(t,e)=>{let r={};if(t.class)for(let n in t.class)r[n]=t.class[n](e);return r};D();var V0=t=>{if(v(t))return se(t,t)},s2=(t,e)=>{let r=V0(t);return typeof e=="function"?e(r):he(r)};D();D();function Uy(t,e,r){let n=t?.context?.analyze;if(!n||!n.emit||e==="warn"&&!n.shouldCapture("warnings")||e==="error"&&!n.shouldCapture("errors"))return;let o=r.map(s=>s?.message||(typeof s=="string"?s:null)).filter(Boolean).join(" ");n.emit({id:`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,6)}`,ts:Date.now(),type:e==="error"?"error":"warning",level:e,hook:e==="error"?"el.error":"el.warn",element:{key:t.key!=null?String(t.key):null,name:t.__name||null,tag:t.tag||null},message:o||null,args:r})}var U0=new Set;function z0(t,e,r){let n=String(e);if(U0.has(n))return;U0.add(n);let o=t?.__ref?.path,s=Array.isArray(o)&&o.length?o.join("."):t?.key!=null?String(t.key):"(unknown element)",i=r!=null?`resolves to a non-function (${typeof r}) \u2014 it cannot be called`:"is not registered in context.methods, context.functions, or context.utils, and is not an element method",a=`[smbls] el.call('${n}') at <${s}>: "${n}" ${i}. Returning undefined (unchanged behavior) \u2014 check the name for typos or register the function on the project. Warned once per name; repeat misses are silent.`;Uy(t,"error",[a]),console.error(a)}var W0=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),i2=new Set,q0=t=>W0(By,t)&&!(Eo||i2).has(t),H0=new Set;function K0(t,e){H0.has(t)||(H0.add(t),gt()&&console.warn(`[smbls] ${e}: context.methods.${t} is named like a built-in element method and is not the app's own override (it was not on the element prototype when it was built) \u2014 ignored; the built-in keeps winning. Declare an intentional override in the app's OWN methods.`))}function a2(...t){return Uy(this,"warn",t),ca.apply(this,t)}function c2(...t){return Uy(this,"error",t),Ln.apply(this,t)}var By={update:bs,remove:ws,getDB:da,getQuery:pa,getRootData:sa,getPath:ea,nextElement:la,previousElement:fa,verbose:Fo,warn:a2,error:c2,variables:ua,spotByPath:ta,set(t,e){let r=this.__ref;if(r){if(r.__setLocked){r.__setQueued={content:t,options:e};return}r.__setLocked=!0}try{if(this.removeContent(),t!=null){let n=this.context?.__create;n&&n(t,this,"content",e)}this.__ref&&(this.__ref.contentManaged=!0)}finally{if(r){r.__setLocked=!1;let n=r.__setQueued;n&&(r.__setQueued=null,this.set(n.content,n.options))}}},reset(t){let e=this.context?.__create;if(!e)return this;let r=this.parent,n=this.key,o=this.parse();return this.remove(),e(o,r,n,t)},lookup(t){let e=this.parent;for(;e;){if(typeof t=="function"){if(t(e))return e}else if(typeof t=="string"){if(e.key===t)return e;if(e[t]&&e[t].__ref)return e[t]}e=e.parent}return null},lookdown(t){let e=this.__ref;if(!e?.__children)return null;for(let r of e.__children){let n=this[r];if(!n)continue;if(typeof t=="function"){if(t(n))return n}else if(typeof t=="string"&&n.key===t)return n;let o=n.lookdown?.(t);if(o)return o}return null},lookdownAll(t,e=[]){let r=this.__ref;if(!r?.__children)return e;for(let n of r.__children){let o=this[n];o&&(typeof t=="function"?t(o)&&e.push(o):typeof t=="string"&&o.key===t&&e.push(o),o.lookdownAll?.(t,e))}return e},getRef(t){return t?this.__ref&&this.__ref[t]:this.__ref},getChildren(){let t=this.__ref&&this.__ref.__children;return Array.isArray(t)?t.map(e=>this[e]):[]},getRoot:oa,getRootState:na,getRootContext:ia,getContext:aa,parse(t){let e={},r=t?new Set(t):null,n=this.__ref?.__exec;for(let o in this)if(!(o==="parent"||o==="node"||o==="__ref")&&!r?.has(o)){if(n&&n[o]!==void 0){e[o]=n[o];continue}typeof this[o]!="function"&&(e[o]=this[o])}return e},parseDeep(t){let e=this.parse(t),r=this.__ref;if(r?.__children)for(let n of r.__children)this[n]?.parseDeep&&(e[n]=this[n].parseDeep(t));return e},keys(){return Object.keys(this)},log(...t){if(t.length){let e={};for(let r of t)e[r]=this[r];console.log(e)}else console.log(this)},setProps(t,e){return this.update(t,e)},setNodeStyles(t){if(this.node?.style)for(let e in t){let r=t[e];if(r==null)continue;let n=e.replace(/[A-Z]/g,s=>"-"+s.toLowerCase()),o=String(r).replace(/\s*!important\s*$/,"");this.node.style.setProperty(n,o,"important")}},call(t,...e){let r=this.context,n=q0(t);n&&r?.methods?.[t]&&r.methods[t]!==this[t]&&K0(t,"el.call");let o=n?this[t]:r?.methods?.[t]||r?.functions?.[t]||r?.utils?.[t]||this[t];if(typeof o=="function"){let s=An;if(!s||!s(o))return o.call(this,...e);gt()&&z0(this,t,Le(o));return}gt()&&z0(this,t,o)},removeContent(){let t=this.__ref;if(!t?.__children)return;let e=this.content;if(e?.remove){e.remove(),delete this.content;let r=t.__children.indexOf("content");r!==-1&&t.__children.splice(r,1)}e?.node?.parentNode&&e.node.parentNode.removeChild(e.node)}},Vy=new WeakMap;function l2(t){if(!t)return By;let e=Vy.get(t);if(e)return e;e=Object.create(By);let r=t.methods;if(r)for(let n in r)e[n]=r[n];return Vy.set(t,e),e}function xs(t){let e=l2(t.context);Object.setPrototypeOf(t,e)}function ku(t){if(!t)return!1;let e=Vy.get(t);if(!e)return!1;let r=t.methods;if(!r)return!1;for(let n in r){if(q0(n)&&!W0(e,n)){K0(n,"refreshContextProto");continue}e[n]=r[n]}return!0}var vu=[],Cu=!1,sn=0;function Eu(){return typeof performance<"u"&&typeof performance.now=="function"?performance.now():Date.now()}function G0(t){let e=typeof globalThis<"u"?globalThis.scheduler:null;if(e&&typeof e.yield=="function"){e.yield().then(t,t);return}if(typeof MessageChannel=="function"){let r=new MessageChannel;r.port1.onmessage=()=>{r.port1.close(),t()},r.port2.postMessage(0);return}setTimeout(t,0)}function zy(){return sn?Eu()-sn>=50:!1}var Ss=0;function Hy(){Ss===0&&!sn&&(sn=Eu()),Ss++}function Wy(){Ss>0&&Ss--,Ss===0&&!Cu&&(sn=0)}function qy(t){vu.push(t),Cu||(Cu=!0,G0(Y0))}function Y0(){for(sn=Eu();vu.length;){let t=vu.shift();try{t()}catch(e){typeof console<"u"&&console.error&&console.error("[smbls] deferred mount chunk failed:",e?.message||e)}if(Eu()-sn>=50)break}if(vu.length){G0(Y0);return}Cu=!1,sn=0,Ss=0}D();D();Rn();var Zy={};$(Zy,{STATE_METHODS:()=>X0,applyInitialState:()=>Tu,applyStateMethods:()=>me,callStateMethod:()=>uc,createState:()=>Gy,isTracking:()=>Xy,useHostState:()=>Yy});var X0=new Set(["update","parse","clean","destroy","create","add","toggle","remove","set","replace","setByPath","setPathCollection","removeByPath","removePathCollection","getByPath","reset","apply","applyReplace","applyFunction","quietUpdate","quietReplace","rootUpdate","parentUpdate","keys","values","__element","__children","parent","root"]),Au=(t,e,r)=>{Object.defineProperty(t,e,{value:r,enumerable:!1,configurable:!0,writable:!0})},Be=(t,e,r,{onlyIfAbsent:n}={})=>{Au(t,"$"+e,r),!(n&&Object.prototype.hasOwnProperty.call(t,e))&&Au(t,e,r)},uc=(t,e,...r)=>{if(!t)return;let n=t["$"+e];if(typeof n=="function")return n.apply(t,r);let o=t[e];if(typeof o=="function")return o.apply(t,r)},me=(t,e)=>{if(kt(e)){let o=e.__raw||e;Be(o,"toggle",function(s,i={}){e[s]=!e[s]},{onlyIfAbsent:!0}),Be(o,"set",function(s,i={}){return e.$clean({preventStateUpdate:!0}),typeof s=="object"&&s!==null&&e.$update(s,i),e},{onlyIfAbsent:!0}),Be(o,"setByPath",function(s,i,a={}){let c=s.split("."),l=e;for(let f=0;f<c.length-1;f++)l[c[f]]===void 0&&(l[c[f]]={}),l=l[c[f]];return l[c[c.length-1]]=i,e}),Be(o,"getByPath",function(s){let i=s.split("."),a=e;for(let c=0;c<i.length;c++){if(a==null)return;a=a[i[c]]}return a}),Be(o,"removeByPath",function(s,i={}){let a=s.split("."),c=e;for(let l=0;l<a.length-1;l++){if(c==null)return e;c=c[a[l]]}return c&&delete c[a[a.length-1]],e}),Be(o,"reset",function(s={}){let i=e.$parse();return e.$set(i,s)}),Be(o,"apply",function(s,i={}){if(typeof s=="function"){let a=s(e);return e.$update(a,i)}}),Be(o,"applyFunction",function(s,i={}){if(typeof s=="function")return s(e),e.$update(e.$parse(),i)}),Be(o,"rootUpdate",function(s,i={}){let a=e;for(;a?.parent&&kt(a.parent);)a=a.parent;return uc(a,"update",s,i)}),Be(o,"parentUpdate",function(s,i={}){if(e.parent)return uc(e.parent,"update",s,i)}),Be(o,"quietReplace",function(s,i={}){return e.$replace(s,{quiet:!0,...i})}),Object.getOwnPropertyDescriptor(o,"root")||Object.defineProperty(o,"root",{get:function(){let s=e,i=kt(s)?s:null;for(let a=0;a<64&&s?.parent&&s.parent!==s;a++)s=s.parent,kt(s)&&(i=s);return i||s},enumerable:!1,configurable:!0});return}if(!e||typeof e!="object")return;let r=()=>{for(let o in e)Object.prototype.hasOwnProperty.call(e,o)&&delete e[o]},n={update(o){if(!o||typeof o!="object")return e;for(let s in o)e[s]=o[s];return e},apply(o){if(typeof o!="function")return e;let s=o(e);return s?e.$update(s):e},parse(){return{...e}},toggle(o){return e[o]=!e[o],e},set(o){if(!o||typeof o!="object")return e;r();for(let s in o)e[s]=o[s];return e},replace(o){return e.$set(o)},clean(){return r(),e}};for(let o in n)if(Au(e,"$"+o,n[o]),typeof e[o]!="function"){if(Object.prototype.hasOwnProperty.call(e,o)){yl(o,"");continue}Au(e,o,n[o])}};var Gy=function(t,e,r){return t.state=Tu(t,e,r),t.state},Tu=function(t,e,r){let{__ref:n}=t,o=t.state;if(o==null||o===!1){let s=e?.state||{};return me(t,s),s}if(typeof o=="string")return n&&(n.__state=o),n.__stateType="string",f2(o,t,e);if(typeof o=="number"||typeof o=="boolean"){n&&(n.__state=o,n.__stateType=typeof o,n.__hasRootState=!0);let s=lr({value:o});return s.__element=t,e?.state&&(s.parent=e.state),me(t,s),s}if(typeof o=="function"&&(o=o(t,e?.state)||{}),typeof o=="object"&&!kt(o)){n&&(n.__hasRootState=!0),o.isRootState&&n&&(n.__hasRootState=!0);let s=lr({...o});if(s.__element=t,!Object.getOwnPropertyDescriptor(s,"root")){let i=e?.state?.root||e?.state||s;Object.defineProperty(s,"root",{get:()=>i,enumerable:!1,configurable:!0})}return e?.state&&(s.parent=e.state,e.state.__children&&(e.state.__children[t.key]=s)),me(t,s),typeof t.onStateCreated=="function"&&t.onStateCreated(t,s,t.context,r),s}return kt(o)?(o.__element=t,o):e?.state||{}};function Ky(t,e){if(!e)return t;let r=e.split("/"),n=t;for(let o of r){if(n==null)return{};n=n[o]}return n??{}}function f2(t,e,r){if(!r?.state)return{};if(t===".")return r.state;if(t.startsWith("../")){let o=t.slice(3),s=r.state?.parent;return o&&s?Ky(s,o):s??r.state??{}}if(t.startsWith("~/")){let o=r.state;for(;o?.parent;)o=o.parent;let s=t.slice(2);return s?Ky(o,s):o??{}}let n=Ky(r.state,t);if(n&&typeof n=="object"&&!kt(n)&&!Object.getOwnPropertyDescriptor(n,"root")){let o=r.state?.root||r.state;Object.defineProperty(n,"root",{get:()=>o,enumerable:!1,configurable:!0})}return n}var Yy=(t,e)=>{if(!t)return J0;let r=d2(t,e);return!r||!r.state?J0:h2(r.state)},Xy=()=>Lr()!=null,u2=128;function d2(t,e){let r=typeof e=="function"?e:typeof e=="string"?s=>!!s?.[e]:s=>!!s?.state,n=t,o=null;for(let s=0;s<u2&&n;s++){if(r(n)&&n.state)return n;if(n.state&&!o&&(o=n),!n.parent||n.parent===n)break;n=n.parent}return o}var p2={get(t,e){return t[e]}},Z0=new WeakMap,h2=t=>{let e=Z0.get(t);return e||(e=new Proxy(t,p2),Z0.set(t,e)),e},J0=new Proxy(Object.create(null),{get(){},has(){return!1}});var Ou="3.14.797";var Q0="__SMBLS_ELEMENT_ID_ENGINE__",tk=(t,e,r)=>{let n=e||Ou,o=r||(typeof globalThis<"u"?globalThis:null);if(!o)return t;let s=o[Q0];return s&&s.engine&&s.version===n?s.engine:(s||(o[Q0]={version:n,engine:t}),t)};var K=(t,e)=>e.split(" ").map(r=>t+"-"+r),Jy="top right bottom left",Qy=Jy+" block block-start block-end inline inline-start inline-end",an="start end",to="width style color",Ru=t=>K(t,Qy),g2=(()=>{let t=K("border","width style color image");for(let e of Qy.split(" "))t.push("border-"+e,...K("border-"+e,to));return t})(),ek=t=>[...K("border-"+t,to+" start end"),...K("border-"+t+"-start",to),...K("border-"+t+"-end",to)],vr={animation:K("animation","name duration timing-function delay iteration-count direction fill-mode play-state timeline range range-start range-end"),background:K("background","image position position-x position-y size repeat origin clip attachment color"),border:g2};for(let t of["width","style","color"])vr["border-"+t]=Qy.split(" ").map(e=>"border-"+e+"-"+t);for(let t of Jy.split(" "))vr["border-"+t]=K("border-"+t,to);vr["border-block"]=ek("block");vr["border-inline"]=ek("inline");Object.assign(vr,{"border-image":K("border-image","source slice width outset repeat"),"border-radius":"top-left top-right bottom-right bottom-left start-start start-end end-start end-end".split(" ").map(t=>"border-"+t+"-radius"),columns:K("column","width count"),"column-rule":K("column-rule",to),container:K("container","name type"),"contain-intrinsic-size":K("contain-intrinsic","width height"),flex:K("flex","grow shrink basis"),"flex-flow":K("flex","direction wrap"),font:[...K("font","style variant weight stretch size"),"line-height",...K("font","family size-adjust kerning feature-settings variation-settings optical-sizing")],gap:["row-gap","column-gap"],grid:K("grid","template template-rows template-columns template-areas auto-rows auto-columns auto-flow"),"grid-template":K("grid-template","rows columns areas"),"grid-area":K("grid","row column row-start row-end column-start column-end"),"grid-row":K("grid-row",an),"grid-column":K("grid-column",an),inset:[...Jy.split(" "),...K("inset","block block-start block-end inline inline-start inline-end")],"inset-block":K("inset-block",an),"inset-inline":K("inset-inline",an),"list-style":K("list-style","type position image"),margin:Ru("margin"),"margin-block":K("margin-block",an),"margin-inline":K("margin-inline",an),mask:K("mask","image mode repeat position clip origin size composite"),offset:K("offset","position path distance rotate anchor"),outline:K("outline",to),overflow:K("overflow","x y"),"overscroll-behavior":K("overscroll-behavior","x y"),padding:Ru("padding"),"padding-block":K("padding-block",an),"padding-inline":K("padding-inline",an)});for(let t of["content","items","self"])vr["place-"+t]=["align-"+t,"justify-"+t];Object.assign(vr,{"scroll-margin":Ru("scroll-margin"),"scroll-padding":Ru("scroll-padding"),"text-decoration":K("text-decoration","line style color thickness"),"text-emphasis":K("text-emphasis","style color"),transition:K("transition","property duration timing-function delay behavior")});var dc={};for(let t in vr)for(let e of vr[t])(dc[e]||(dc[e]=[])).push(t);var m2=new Set(["rows","cols","wrap"]),Pu=(t,e)=>m2.has(e)&&Te(t,e),ks=(t,e)=>!!(xt[e]||Et&&Et.has(e))&&!Pu(t,e);var _k=tk({uniqId:1,scopedStyleId:0},Ou),hc=[],eo=new Set,ub=!1,wk=0,Cs=null,wc=null;function Es(){return typeof Date<"u"&&typeof Date.now=="function"?Date.now():0}function xk(){return typeof document<"u"&&document.visibilityState==="hidden"}var y2=250,b2=1e3;function _2(){return wc&&(wc!==(typeof requestAnimationFrame=="function"?requestAnimationFrame:null)||xk())?!0:Es()-wk>=b2}function w2(){if(ub=!0,wk=Es(),wc=null,typeof requestAnimationFrame!="function"){let t=typeof clearTimeout=="function"?clearTimeout:null,e=setTimeout(mc,0);Cs=t?()=>t(e):null;return}if(xk()){let t=typeof clearTimeout=="function"?clearTimeout:null,e=setTimeout(mc,y2);Cs=t?()=>t(e):null}else{let t=typeof cancelAnimationFrame=="function"?cancelAnimationFrame:null;wc=requestAnimationFrame;let e=requestAnimationFrame(mc);Cs=t?()=>t(e):null}}function ju(){if(ub){if(!_2())return;let t=Cs;if(Cs=null,t)try{t()}catch{}}w2()}var Sk=300,kk=15e4;function mc(){if(ub=!1,Cs=null,wc=null,eo.size&&X2(),!hc.length)return;let t=hc.splice(0,hc.length);for(let e=0;e<t.length;e++){let r=t[e];if(r.node){if(!r.node.isConnected){let n=r.__ref||(r.__ref={});n.__mountAttempts=(n.__mountAttempts||0)+1,n.__mountFirstAttemptAt==null&&(n.__mountFirstAttemptAt=Es());let o=Es()-n.__mountFirstAttemptAt;n.__mountAttempts<=Sk&&o<kk?(hc.push(r),ju()):console.warn("[DOMQL] onMounted dropped after",n.__mountAttempts,"attempts /",o,"ms \u2014 node never connected:",r.key||r.tag||r);continue}ie("Mounted",r,r.__ref?.__mountOptions||{})}}}function nb(t,e){let r=t.__ref?.__autoGrow;r&&r.active&&Sc(t,!0),typeof t.onMounted=="function"&&(t.__ref.__mountOptions=e,hc.push(t),ju())}function rk(t,e){if(typeof t.onContentUpdate!="function")return;t.context?.plugins?.length&&Ot("contentUpdate",t,e);let r=t.context?.designSystem;r&&ct(r);try{t.onContentUpdate(t,t.state,t.context,e)}catch(n){if(t.context?.plugins?.length&&Ot("error",t,{hook:"onContentUpdate",error:n})||console.error('[DOMQL] Lifecycle "onContentUpdate" error:',n),t.context?.strictMode)throw n}finally{r&&it()}}function Cr(t){return t.length>2&&t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)>=65&&t.charCodeAt(2)<=90}function x2(t){return t.charAt(2).toLowerCase()+t.slice(3)}function S2(t){return t.toLowerCase()}function ob(t){let e=t.charCodeAt(0);return e===58||e===64||e===38||e===91}function gc(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=gc(o,s):r[n]=s}return r}function $u(t){if(typeof t=="string")return t||void 0;if(typeof t=="number"||typeof t=="bigint")return String(t)}function vk(t,e,r){return $u(t)||(e&&typeof e=="object"?$u(e.key):void 0)||String(r)}function ne(t,e,r,n={},o){let s=Lr();if(s){Ir(null);try{return ne(t,e,r,n,o)}finally{Ir(s)}}if(t==null||t===!1)return null;let i=P2(t);(typeof t=="string"||typeof t=="number")&&(t={text:t}),r=$u(r);let a=$u(t.key),c=Object.create(null);c.key=r||a||`_${_k.uniqId++}`,c.parent=e||null,c.context=t.context||e?.context||n.context||{},c.context.__create||(c.context.__create=ne);let l=c.__ref={__if:!0,__children:[],__exec:{},__effects:[],__eventCleanup:[],root:e?.__ref?.root||c,path:e?.__ref?.path?[...e.__ref.path,c.key]:[c.key],origin:t};if(i&&(l.__runtimeSource=i),r&&!t.extends&&!t.extend){let y=r.indexOf("_"),b=r.indexOf("."),w=y>0?y:-1;if(b>0&&(w<0||b<w)&&(w=b),w>0){let S=r.substring(0,w),C=c.context?.components;C&&(C[S]||C["smbls."+S])?t={...t,extends:S}:C&&gt()&&(/^[A-Z]\w*_\d+$/.test(r)||/^[A-Z]\w*\.\w+$/.test(r))&&console.warn(`[smbls] auto-extend: key "${r}" looks like an instance of "${S}" but neither "${S}" nor "smbls.${S}" is registered in context.components \u2014 element will render as a plain <div>. Register the base component or rename the key.`)}}ys(c,t,n);let f=new Set(["childProps","attr","style","scope","data"]),u=c.props&&typeof c.props=="object"?c.props:null;for(let y in t){if(y==="parent"||y==="node"||y==="__ref"||y==="extends"||y==="context"||y==="props")continue;if(y==="key"){a&&(c.key=a);continue}let b=t[y],w=c[y],S=w&&b&&typeof w=="object"&&typeof b=="object"&&!Array.isArray(w)&&!Array.isArray(b)&&typeof w!="function"&&typeof b!="function";S&&y.charCodeAt(0)>=65&&y.charCodeAt(0)<=90?c[y]=gc(w,b):S&&f.has(y)?c[y]={...w,...b}:S&&ob(y)?c[y]=gc(w,b):c[y]=b}function d(y){for(let b in y){let w=y[b],S=c[b],C=S&&w&&typeof S=="object"&&typeof w=="object"&&!Array.isArray(S)&&!Array.isArray(w)&&typeof S!="function"&&typeof w!="function";C&&b.charCodeAt(0)>=65&&b.charCodeAt(0)<=90?c[b]=gc(S,w):C&&f.has(b)?c[b]={...S,...w}:C&&ob(b)?c[b]=gc(S,w):c[b]=w}}u&&d(u),t.props&&typeof t.props=="object"&&d(t.props),t.classlist!==void 0&&(c.classlist=t.classlist),t.text!==void 0&&(c.text=t.text),t.html!==void 0&&(c.html=t.html);let g=c.scope&&typeof c.scope=="object"?c.scope:null,p=e?.scope,h=c.context&&typeof c.context.globalScope=="object"&&c.context.globalScope||null,m=p||h||null;if(t.scope!==void 0||g){let y={};g&&Object.assign(y,g),t.scope!==void 0&&Object.assign(y,t.scope),c.scope=ml(y,m)}else m&&(c.scope=m);t.if!==void 0&&(c.if=t.if);let _=D2(c,i);if(_&&(l.__declaredArrays=_),xs(c),k2(c,e,t),c.if!=null){let y;if(typeof c.if=="function")try{y=c.if(c,c.state,c.context)}catch(b){if(y=!1,l.__ifError=b,typeof console<"u"&&console.warn){let w=c.key||c.tag||"?";console.warn(`[smbls] \`if:\` evaluator threw on ${w} \u2014 treating as false:`,b?.message||b)}}else y=c.if;l.__if=!!y}if(l.__if)typeof c.if=="function"&&(l.__ifInitialized=!0);else return e&&(e[c.key]=c),typeof c.if=="function"&&Tk(c,l,c.if),c;c.tag||(c.tag=en(c)),ie("Init",c,n);let x=c.node=rn(c);if(!x)return c;if(c.tag==="fragment"){let b=(c.context?.document||globalThis.document).createComment("");x.appendChild(b),l.__fragmentAnchor=b}ie("AttachNode",c,n),x.setAttribute&&c.key&&x.setAttribute("data-key",c.key),e&&(e[c.key]=c,e.__ref?.__children&&(e.__ref.__children.includes(c.key)||e.__ref.__children.push(c.key))),x.setAttribute&&c.context?.scopeSelector&&c.context.scopeSelector!==":root"&&c.context.key&&c.key===c.context.key&&x.setAttribute("data-smbls-app",c.context.key),c.id&&x.setAttribute&&(x.id=c.id),Nk(c,n),Ak(c),ab(c),$k(c),Mk(c),tD(c);try{jk(c,n)}catch(y){if(typeof console<"u"&&console.error){let b=c.__ref?.path?.join(".")||c.key||"<root>";console.error(`[smbls] createChildren failed at ${b}:`,y?.message||y,y?.stack?`
54
- `+y.stack.split(`
52
+ Do NOT trust any browser measurement taken on this page until that reads clean.`),!0}function w0(){try{let t=A(),e=t&&(t.CSS_VARS||t.cssVars);return e?Object.keys(e).length:0}catch{return 0}}function u0(t){fu||ee.variable>0||ee.atomic>0||S0(Math.max(t,w0()))}function xy(t){let e=t&&(t.CSS_VARS||t.cssVars);return S0(e?Object.keys(e).length:w0())}function S0(t){let e=du();if(t===0)return{ok:!0,reason:"no-design-system",stats:e,varCount:t};if(!pu())return{ok:!0,reason:"no-sheet",stats:e,varCount:t};if(e.variable>0||e.atomic>0)return{ok:!0,reason:null,stats:e,varCount:t};let r=e.invalid>0?"every rule was rejected as malformed":"no rule was ever produced";return lP(r,t),{ok:!1,reason:r,stats:e,varCount:t}}var fP={display:"d",position:"pos",padding:"p",paddingTop:"pt",paddingRight:"pr",paddingBottom:"pb",paddingLeft:"pl",margin:"m",marginTop:"mt",marginRight:"mr",marginBottom:"mb",marginLeft:"ml",width:"w",height:"h",minWidth:"mnw",minHeight:"mnh",maxWidth:"mxw",maxHeight:"mxh",top:"t",right:"r",bottom:"b",left:"l",flex:"fx",flexDirection:"fxd",flexWrap:"fxw",flexGrow:"fxg",flexShrink:"fxs",flexBasis:"fxb",justifyContent:"jc",alignItems:"ai",alignSelf:"as",alignContent:"ac",gap:"g",rowGap:"rg",columnGap:"cg",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",gridColumn:"gc",gridRow:"gr",overflow:"of",overflowX:"ofx",overflowY:"ofy",fontSize:"fs",fontWeight:"fw",fontFamily:"ff",fontStyle:"fst",lineHeight:"lh",letterSpacing:"ls",textAlign:"ta",textDecoration:"td",textTransform:"tt",color:"c",background:"bg",backgroundColor:"bgc",backgroundImage:"bgi",border:"bd",borderRadius:"br",borderColor:"bdc",borderWidth:"bdw",borderStyle:"bds",boxShadow:"bxsh",opacity:"op",zIndex:"z",cursor:"cur",transition:"tr",transform:"tf",animation:"an",visibility:"vis",whiteSpace:"ws",wordBreak:"wb",objectFit:"obj",pointerEvents:"pe",userSelect:"us",boxSizing:"bxz",outline:"ol",listStyle:"lis",textOverflow:"txo",verticalAlign:"va",float:"fl",clear:"cl",content:"cnt",backdropFilter:"bdf",filter:"flt",resize:"rsz",appearance:"apr",fill:"fil",stroke:"stk"};function Zn(t){return t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function uu(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e.toString(36)}function uP(t){let e=String(t);return e.length<=20?e.replace(/\s+/g,"_").replace(/[^a-zA-Z0-9_-]/g,"").toLowerCase():uu(e)}var dP={"backdrop-filter":"-webkit-backdrop-filter","user-select":"-webkit-user-select","mask-image":"-webkit-mask-image","mask-size":"-webkit-mask-size","mask-repeat":"-webkit-mask-repeat","mask-position":"-webkit-mask-position","mask-clip":"-webkit-mask-clip","mask-origin":"-webkit-mask-origin","background-clip":"-webkit-background-clip"};function ls(t,e){let r=dP[t];return r?`${t}:${e};${r}:${e};`:`${t}:${e};`}function hy(t){let e="";for(let r in t){let n=t[r];if(typeof n!="object"||n===null)continue;let o="";for(let s in n){let i=s.charCodeAt(0)===45&&s.charCodeAt(1)===45;o+=ls(i?s:Zn(s),n[s])}e+=`${r}{${o}}`}return e}var pP="@media (hover: hover)",hP=/(?:^|[^\\]):hover(?![\w-])/;function wy(){try{let t=A();if(t&&t.hoverMedia===!1)return!1}catch{}return!0}function Sr(t,e,r){return r===!1||!hP.test(e)||r===void 0&&!wy()?t:`${pP}{${t}}`}function d0(t,e,r){let n=(r?r+"":"")+t+":"+e,o=fs.get(n),s=o?null:Zn(t);if(!o){let c=fP[t]||uu(t),l=uP(e);o=r?`_${r}_${c}-${l}`:`_${c}-${l}`,fs.set(n,o)}if(typeof e=="string"&&(e.indexOf("}")!==-1||e.indexOf("{")!==-1))return o;let i=s||Zn(t),a=`.${o}{${ls(i,e)}}`;return Ne(a,void 0,"atomic"),o}var p0=new WeakMap,h0=new WeakMap;function Ne(t,e,r){let n=pu(e,gP(t));if(!n)return ee.dropped++,"dropped";let o=p0.get(n);if(o||(o=new Set,p0.set(n,o)),o.has(t))return ee.duplicate++,ee[r||"global"]++,"duplicate";let s=h0.get(n);if(s&&s.has(t))return ee.invalid++,"invalid";try{n.insertRule(t,n.cssRules.length)}catch{return s||(s=new Set,h0.set(n,s)),s.add(t),ee.invalid++,"invalid"}return o.add(t),ee[r||"global"]++,"inserted"}var je="0:0",g0="1:0",m0=/\((max|min)-width:\s*([\d.]+)(px|em|rem)?\)/g;function gP(t){if(typeof t!="string"||!t)return je;if(t.charCodeAt(0)===64){if(!t.startsWith("@media")&&!t.startsWith("@supports")&&!t.startsWith("@container"))return je;let e=1/0,r=-1/0;m0.lastIndex=0;let n;for(;n=m0.exec(t);){let o=parseFloat(n[2])*(n[3]==="em"||n[3]==="rem"?16:1);n[1]==="max"?e=Math.min(e,o):r=Math.max(r,o)}return e!==1/0?"2:"+-e:r!==-1/0?"3:"+r:g0}return t.charCodeAt(0)!==46||/^\.[\w-]+\{/.test(t)?je:g0}var y0=t=>{let e=t.indexOf(":");return[Number(t.slice(0,e)),Number(t.slice(e+1))]},mP=(t,e)=>{let[r,n]=y0(t),[o,s]=y0(e);return r!==o?r<o:n<s},yP=t=>t.getAttribute("data-tier")||je,b0=new WeakMap;function pu(t,e){let r=t||Jn();if(!r||!r.head)return null;let n=e||je,o=b0.get(r);o||(o=new Map,b0.set(r,o));let s=o.get(n);if(s&&s.ownerNode&&s.ownerNode.parentNode===r.head)return s;n!==je&&pu(r,je);let i=n===je?r.head.querySelector("style[data-smbls]:not([data-tier])"):r.head.querySelector(`style[data-smbls][data-tier="${n}"]`);if(!i){i=r.createElement("style"),i.setAttribute("data-smbls",""),n!==je&&i.setAttribute("data-tier",n);let c=r.head.querySelectorAll("style[data-smbls]"),l=null;for(let u=0;u<c.length;u++)if(mP(n,yP(c[u]))){l=c[u];break}let f=c.length?c[c.length-1]:null;l?r.head.insertBefore(i,l):f?r.head.insertBefore(i,f.nextSibling):r.head.appendChild(i)}let a=i.sheet;return o.set(n,a),n===je&&(x0=a),a}function bP(t){let e=t||Jn();if(!e||!e.head)return[];let r=[],n=e.head.querySelectorAll("style[data-smbls]");for(let o=0;o<n.length;o++)n[o].sheet&&r.push(n[o].sheet);return r}var _P=8;function he(t,e,r,n){if(!t||typeof t!="object")return"";let o=!!(n&&n.state),s=null,i=0,a=[],c=[],l=Object.keys(t);for(let u=0;u<l.length;u++){let d=l[u],g=t[d];g==null||g===!1||g===""||(typeof g=="object"?c.push([d,g]):py?(s||(s=[]),s.push(d,String(g)),i++):a.push(d0(d,String(g),r)))}if(s&&i>=_P){let u=s.join("\0"),d=py(u),g=d.indexOf("\0"),p=d.substring(0,g),h=d.substring(g+1);if(h){let m=h.split(`
53
+ `);for(let y=0;y<m.length;y++)m[y]&&Ne(m[y],void 0,"atomic")}a.push(p)}else if(s)for(let u=0;u<s.length;u+=2)a.push(d0(s[u],s[u+1],r));let f=[];for(let u=0;u<c.length;u++)f.push(kP(c[u][0],c[u][1],r,o));return a.concat(f).join(" ").trim()}var _0=new Map,xP=/^&?:(hover|focus|focus-visible|focus-within|active)(?![\w-])/;function ac(t){return/^@(media|supports|container)\b/.test(t)}function wP(t){return typeof t!="string"||!t||ac(t)?!1:t.split(",").every(e=>xP.test(e.trim()))}var k0=t=>{let e=Object.prototype.toString.call(t);return e==="[object Object]"||e==="[object Array]"},gy=32,my=1024,yy=!1;function cu(t,e,r){if(yy)return;yy=!0;let n=[e,...r],o=n.length>12?[...n.slice(0,6),`\u2026${n.length-9} more\u2026`,...n.slice(-3)]:n;console.warn(`[@symbo.ls/css] ${t} at ${o.join(" > ")} \u2014 skipped. A style block may hold only CSS values and nested plain blocks; the rest of this rule is still emitted. (One warning per page.)`)}function SP(t){try{return JSON.stringify(t)}catch{let r=[],n=0;return JSON.stringify(t,function(o,s){if(!s||typeof s!="object")return s;for(;r.length&&r[r.length-1]!==this;)r.pop();if(!(r.length&&(r.includes(s)||!k0(s)||r.length>gy||++n>my)))return r.push(s),s})}}function kP(t,e,r,n){let o=SP(e),s=t.indexOf(":hover")!==-1||o.indexOf(":hover")!==-1,i=s&&wy(),a=(r?r+"":"")+t+o+(s&&!i?"rawhover":"")+(n?"state":""),c=fs.get(a);if(c){let w=_0.get(c);if(w)for(let S=0;S<w.length;S++)Ne(w[S],void 0,"atomic");return c}c=r?`_${r}_c${uu(a)}`:`_c${uu(a)}`;let l=n?`.${c}.${c}`:`.${c}`,f=wP(t)?`${l}.${c}`:l,u="",d=[],g=w=>typeof w=="string"&&(w.indexOf("{")!==-1||w.indexOf("}")!==-1),p=new Set,h=0,m=(w,S)=>{p.add(S);let E="",O=Object.keys(S);for(let L=0;L<O.length;L++){let T=O[L],M=S[T];if(M!=null)if(typeof M=="object"){let U=[...w,T];p.has(M)?cu("a style value that loops back to one of its own ancestors",t,U):k0(M)?U.length>gy?cu(`a style block nested more than ${gy} levels deep`,t,U):++h>my?cu(`a style object with more than ${my} nested blocks`,t,U):m(U,M):cu(`a ${Object.prototype.toString.call(M).slice(8,-1)} (not a style block)`,t,U)}else{if(g(M))continue;E+=ls(Zn(T),M)}}p.delete(S),E&&(w.length===0?u+=E:d.push({chain:w,body:E}))};m([],e);let y=w=>w.startsWith(":")||w.startsWith("["),x=(w,S=!0)=>{let E=S&&w.length===1?f:l;if(!w.length)return E;let O=w[0].split(",").map(L=>L.trim()).map(L=>L.includes("&")?L.replace(/&/g,E):y(L)?`${E}${L}`:`${E} ${L}`);for(let L=1;L<w.length;L++){let T=w[L].split(",").map(U=>U.trim()),M=[];for(let U of O)for(let rt of T)rt.includes("&")?M.push(rt.replace(/&/g,U)):y(rt)?M.push(U+rt):M.push(U+" "+rt);O=M}return O.join(", ")},b=[],_=(w,S)=>{let E=w.filter(ac),O=x(w.filter(T=>!ac(T)),E.length===0),L=`${O}{${S}}`;for(let T=E.length-1;T>=0;T--)L=`${E[T]}{${L}}`;L=Sr(L,O,i),b.push(L),Ne(L,void 0,"atomic")};u&&_([t],u);for(let w of d)_([t,...w.chain],w.body);return _0.set(c,b),fs.set(a,c),c}function xt(t){if(t==null||typeof t!="string"&&typeof t!="object")return;if(pu(),typeof t=="string"){let s=t.indexOf("--")!==-1;Ne(t,void 0,s?"variable":"global"),s&&u0(1);return}let e=wy(),r=0,n=Object.keys(t),o=s=>{let i=s.match(/max-width:\s*(\d+)/);return i?parseInt(i[1]):0};n.sort((s,i)=>{let a=s.startsWith("@media"),c=i.startsWith("@media");return!a&&!c?0:a?c?o(i)-o(s):1:-1});for(let s of n){let i=t[s];if(s.startsWith("@keyframes")){let a=hy(i);a&&Ne(`${s}{${a}}`,void 0,"keyframes");continue}if(ac(s))for(let a in i){let c=i[a];if(a.startsWith("@keyframes")){let l=hy(c);l&&Ne(`${s}{${a}{${l}}}`,void 0,"keyframes");continue}if(typeof c=="object"&&c!==null){let l="",f=0;for(let u in c){let d=u.charCodeAt(0)===45&&u.charCodeAt(1)===45;d&&f++;let g=d?u:Zn(u);l+=ls(g,c[u])}r+=f,Ne(Sr(`${s}{${a}{${l}}}`,a,e),void 0,f?"variable":"global")}else{let l=a.charCodeAt(0)===45&&a.charCodeAt(1)===45;l&&r++;let f=l?a:Zn(a);Ne(`${s}{${ls(f,c)}}`,void 0,l?"variable":"global")}}else{let a="",c=!1,l=0;for(let f in i){let u=i[f];if(typeof u=="object"&&u!==null)c=!0;else{let d=f.charCodeAt(0)===45&&f.charCodeAt(1)===45;d&&l++;let g=d?f:Zn(f);a+=ls(g,u)}}if(r+=l,a&&Ne(Sr(`${s}{${a}}`,s,e),void 0,l?"variable":"global"),c){let f=[],u=[];for(let d in i)typeof i[d]=="object"&&i[d]!==null&&(ac(d)?f.push(d):u.push(d));f.sort((d,g)=>{let p=h=>{let m=h.match(/max-width:\s*(\d+)/);return m?parseInt(m[1]):0};return p(g)-p(d)});for(let d of u)xt({[`${s} ${d}`]:i[d]});for(let d of f)xt({[d]:{[s]:i[d]}})}}}r>0&&u0(r)}function us(t,e){return Ne(`@keyframes ${t}{${hy(e)}}`,void 0,"keyframes"),t}function v0(){fs.clear(),x0=null,yy=!1}function Sy(){return fs.size}D();var wb={};$(wb,{DELEGATED_EVENTS:()=>ms,LIFECYCLE_EVENTS:()=>rn,MIXINS:()=>hu,NON_BUBBLING_EVENTS:()=>gu,REGISTRY:()=>jt,SVG_TAGS:()=>hs,addDelegatedEvent:()=>lc,addMethods:()=>Ss,applyExtends:()=>bs,cacheNode:()=>en,create:()=>ne,createHTMLNode:()=>ps,detectTag:()=>tn,dispose:()=>vr,flushMounts:()=>bc,globalEventKeyInfo:()=>mu,isSvgTag:()=>gs,isValidTag:()=>ds,refreshContextProto:()=>Cu,registerEvent:()=>ys,registerGlobalEvent:()=>yu,remove:()=>ws,removeDelegatedEvent:()=>fc,update:()=>_s});var vy="http://www.w3.org/2000/svg",hs=new Set(["svg","path","circle","ellipse","line","polyline","polygon","rect","g","defs","use","symbol","clipPath","mask","pattern","image","text","tspan","textPath","marker","linearGradient","radialGradient","stop","filter","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feFlood","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","feSpecularLighting","feTile","feTurbulence","animate","animateMotion","animateTransform","set","foreignObject","desc","title","metadata"]),vP=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","menu","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","search","section","select","slot","small","source","span","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","string","fragment","shadow"]);function ds(t){return vP.has(t)||hs.has(t)}function gs(t){return hs.has(t)}function tn(t){let{tag:e,key:r}=t;if(typeof e=="function")try{e=e(t,t.state,t.context)}catch(s){e=void 0,typeof console<"u"&&console.error&&console.error(`[smbls] \`tag:\` factory threw on "${r||"<anon>"}" \u2014 falling back to key-based tag detection:`,s?.message||s)}if(e===!0&&(e=r),typeof e=="string"&&ds(e))return e;if(!r||typeof r!="string")return"div";let n=new Set(["html","head","body","meta","link","script","style","title","base","noscript","template","th","tr","td","thead","tbody","tfoot","caption","col","colgroup"]),o=r.toLowerCase();return o.includes(".")&&(o=o.split(".")[0]),o.includes("_")&&(o=o.split("_")[0]),ds(o)&&!n.has(o)?o:"div"}var C0={};function ps(t,e){let r=e?.context?.document||globalThis.document;if(!r)return null;if(t==="string")return r.createTextNode(e?.text||"");if(t==="fragment")return r.createDocumentFragment();if(gs(t)){let n=e?.parent;if(t==="svg"||n?.node?.namespaceURI===vy)return r.createElementNS(vy,t);if(t!=="svg")return r.createElement("div")}return r.createElement(t)}function en(t){let e=t.tag=tn(t),n=gs(e)&&(e==="svg"||t.parent?.node?.namespaceURI===vy)?"svg:"+e:e,o=t?.context?.document||globalThis.document,s=C0[n];if(s||(s=C0[n]=ps(e,t)),!s)return null;let i=o&&s.ownerDocument!==o?ps(e,t):s.cloneNode(!0);return e==="string"&&(i.nodeValue=t.text||""),i}var jt=new Set(["extends","children","content","childrenAs","childExtends","childExtendsRecursive","childProps","inheritParentProps","state","if","define","deps","tag","attr","style","text","html","value","data","classlist","class","scope","root","context","$router","routes","fetch","variables","query","key","component","preventContentUpdate","preventContentRecreate","subscribeTo","autoGrow","srcObject","allowRuntimeTemplates","__name","__ref","__hash","__text","parent","node"]),hu={text:"text",html:"html",style:"style",attr:"attr",data:"data",classlist:"classlist",state:"state",scope:"scope"},rn=new Set(["start","init","complete","attachNode","stateInit","stateCreated","beforeUpdate","update","afterUpdate","beforeClassAssign","lazyLoad","render","renderRouter","done","create","frame","mounted","contentUpdate","startUpdate","stateUpdate","beforeStateUpdate","initInspect","initSync","beforeRemove","remove"]),gu=new Set(["load","error","abort","scroll","canplay","canplaythrough","ended","pause","play","playing","ratechange","seeked","seeking","stalled","suspend","timeupdate","volumechange","waiting","durationchange","loadeddata","loadedmetadata","progress","emptied","resize"]),Cy=new Set(["wheel","mousewheel","touchstart","touchmove","touchend","touchcancel"]),ms=new Set(["click","dblclick","mousedown","mouseup","mousemove","mouseenter","mouseleave","mouseover","mouseout","pointerdown","pointerup","pointermove","pointerenter","pointerleave","pointerover","pointerout","touchstart","touchend","touchmove","keydown","keyup","keypress","input","change","submit","reset","focus","blur","focusin","focusout","wheel","contextmenu","drag","dragstart","dragend","dragenter","dragleave","dragover","drop"]);var Ay=new WeakMap,CP={passive:!0},EP={passive:!0,capture:!0},Ty=(t,e)=>Cy.has(t)?e?EP:CP:e||!1;function T0(t){let e=Ay.get(t);return e||(e={handlers:new Map,installed:new Set},Ay.set(t,e)),e}function AP(t,e){let r=T0(e);if(r.installed.has(t))return;r.installed.add(t);let n=t==="focus"||t==="blur"||t==="focusin"||t==="focusout"||t==="mouseenter"||t==="mouseleave"||t==="pointerenter"||t==="pointerleave",o=t==="mouseenter"||t==="mouseleave"||t==="pointerenter"||t==="pointerleave";e.addEventListener(t,s=>{if(o){let a=s.target,c=r.handlers.get(t),l=c&&a?c.get(a):null;if(!l||s.relatedTarget&&typeof a.contains=="function"&&a.contains(s.relatedTarget))return;l(s);return}let i=s.target;for(;i&&i!==e;){let a=r.handlers.get(t);if(a){let c=a.get(i);if(c&&(c(s),s.cancelBubble))return}i=i.parentNode}},Ty(t,n))}function lc(t,e,r,n){n||(n=e.ownerDocument?.documentElement||e.getRootNode());let o=T0(n);AP(t,n),o.handlers.has(t)||o.handlers.set(t,new WeakMap),o.handlers.get(t).set(e,r)}function fc(t,e,r){r||(r=e.ownerDocument?.documentElement||e.getRootNode());let n=Ay.get(r);if(!n)return;let o=n.handlers.get(t);o&&o.delete(e)}function E0(t){return ms.has(t)&&!rn.has(t)}function O0(t,e){let{context:r}=t,n=r?.designSystem;return o=>{n&&ct(n);try{let s=e.call(t,o,t,t.state,r);if(s&&typeof s.then=="function"){s.catch(i=>{t.error=i,console.error("[DOMQL] Async event error:",i)}).finally(()=>{n&&it()});return}}catch(s){if(t.error=s,console.error("[DOMQL] Event error:",s),r?.strictMode)throw s}n&&it()}}function ys(t,e,r){let{node:n,context:o}=e;if(!n)return;let s=O0(e,r),i=gu.has(t);if(!i&&E0(t)){let a=o?.rootNode||n.ownerDocument?.documentElement;lc(t,n,s,a)}else n.addEventListener(t,s,Ty(t,!1));e.__ref.__eventCleanup||(e.__ref.__eventCleanup=[]),e.__ref.__eventCleanup.push(()=>{if(!i&&E0(t)){let a=o?.rootNode||n.ownerDocument?.documentElement;fc(t,n,a)}else n.removeEventListener(t,s,Ty(t,!1))})}var Ey=[["onDocument","document"],["onWindow","window"],["onVisualViewport","visualViewport"],["onMediaQuery","mediaQuery"]];function mu(t){if(typeof t!="string")return null;for(let e=0;e<Ey.length;e++){let r=Ey[e][0];if(t.length<=r.length||!t.startsWith(r))continue;let n=t.charCodeAt(r.length);if(!(n<65||n>90))return{target:Ey[e][1],eventName:t.slice(r.length).toLowerCase()}}return null}var TP=/^[A-Za-z_$][\w$]*$/;function OP(t,e,r){let n=e,o=!1,s,i=!1,a=null;if(e&&typeof e=="object"&&typeof e!="function"&&(n=e.handler,o=!!e.capture,i=!!e.once,typeof e.passive=="boolean"&&(s=e.passive),typeof e.query=="string"&&(a=e.query)),typeof n=="string"&&TP.test(n)){let c=n;n=function(f){return t.call(c,f)}}return typeof n!="function"?null:(s===void 0&&(s=Cy.has(r)),{handler:n,capture:o,passive:s,once:i,query:a})}function RP(t,e,r){let n=t.node?.ownerDocument||t.context?.document||(typeof document<"u"?document:null);if(!n||typeof n.addEventListener!="function")return null;if(e==="document")return n;let o=n.defaultView||(typeof window<"u"?window:null);if(!o)return null;if(e==="window")return typeof o.addEventListener=="function"?o:null;if(e==="visualViewport"){let s=o.visualViewport;return s&&typeof s.addEventListener=="function"?s:null}if(e==="mediaQuery"){let s=r&&r.query;if(typeof s!="string"||!s.trim()||typeof o.matchMedia!="function")return null;try{return o.matchMedia(s)||null}catch{return null}}return null}function PP(t,e,r,n){try{return t.addEventListener(e,r,n),!0}catch{return typeof t.addListener=="function"?(t.addListener(r),!0):!1}}function DP(t,e,r,n){try{t.removeEventListener(e,r,n)}catch{typeof t.removeListener=="function"&&t.removeListener(r)}}function LP(t){let e=t.node;if(!e)return!1;let r=e.nodeType===11?t.__ref?.__fragmentAnchor:e;return r?r.isConnected!==!1:!1}function yu(t,e,r){if(e.__ref){if(Array.isArray(r)){if(t.target!=="mediaQuery")return;for(let o=0;o<r.length;o++)A0(t,e,r[o]);return}A0(t,e,r)}}function A0(t,e,r){let n=e.__ref,o=OP(e,r,t.eventName);if(!o||t.target==="mediaQuery"&&t.eventName!=="change")return;let s=RP(e,t.target,o);if(!s)return;let i=t.target+":"+(o.query?o.query+":":"")+t.eventName+":"+(o.capture?1:0);if(n.__globalEvents&&n.__globalEvents.has(i))return;let a=O0(e,o.handler),c=f=>{LP(e)&&a(f)},l={capture:o.capture,passive:o.passive,once:o.once};PP(s,t.eventName,c,l)&&(n.__globalEvents||(n.__globalEvents=new Map),n.__globalEvents.set(i,{target:s,eventName:t.eventName,listener:c,options:l}),n.__eventCleanup||(n.__eventCleanup=[]),n.__eventCleanup.push(()=>{DP(s,t.eventName,c,l),n.__globalEvents&&n.__globalEvents.delete(i)}))}function R0(t){let e=[];return t.extends&&(Array.isArray(t.extends)?e.push(...t.extends):e.push(t.extends)),t.extend&&(Array.isArray(t.extend)?e.push(...t.extend):e.push(t.extend)),e}function bs(t,e,r){let n=R0(e);if(!n.length)return;let s=(t.context||r?.context||{}).components||{};for(let i=0;i<n.length;i++){let a=P0(n[i],s);a&&a!==e&&D0(t,a,r,new Set([e]))}}function P0(t,e){if(typeof t=="string"){if(t.includes(">")){let r=t.split(">").map(o=>o.trim()),n=e[r[0]]||e[`smbls.${r[0]}`];for(let o=1;o<r.length&&n;o++)n=n[r[o]];return n||null}return e[t]||e[`smbls.${t}`]||null}return typeof t=="object"&&t!==null?t:null}function D0(t,e,r,n=new Set){if(n.has(e))return;n.add(e);let o=R0(e);if(o.length){let i=(t.context||r?.context||{}).components||{};for(let a=0;a<o.length;a++){let c=P0(o[a],i);c&&D0(t,c,r,n)}}for(let s in e){if(s==="extends"||s==="extend")continue;let i=e[s];t[s]===void 0?i&&typeof i=="object"&&!Array.isArray(i)&&typeof i!="function"?t[s]={...i}:t[s]=i:typeof t[s]=="object"&&typeof i=="object"&&!Array.isArray(t[s])&&!Array.isArray(i)&&t[s]!==null&&i!==null?t[s]=L0(t[s],i):t[s]=i}}function L0(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=L0(o,s):r[n]=s}return r}Tn();D();var IP=["alert","alertdialog","application","article","banner","button","cell","checkbox","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","menuitemcheckbox","menuitemradio","navigation","none","note","option","presentation","progressbar","radio","radiogroup","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"],bu={default:["accesskey","autofocus","class","contenteditable","contextmenu","dir","draggable","hidden","id","lang","part","placeholder","slot","spellcheck","style","tabindex","title","translate","inert","radiogroup","role","about","datatype","inlist","prefix","property","resource","typeof","vocab","autocapitalize","autocorrect","autosave","color","itemprop","itemscope","itemtype","itemid","itemref","results","security","unselectable","is"],a:["accesskey","charset","coords","download","href","hreflang","name","rel","rev","shape","target","type"],aria:["aria-activedescendant","aria-atomic","aria-autocomplete","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-dropeffect","aria-errormessage","aria-expanded","aria-flowto","aria-grabbed","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext"],anchor:["download","href","hreflang","media","ping","rel","target","type","referrerpolicy"],audio:["autoplay","controls","crossorigin","loop","muted","preload","src"],area:["alt","coords","download","href","hreflang","media","referrerpolicy","rel","shape","target","ping"],base:["href","target"],blockquote:["cite"],button:["disabled","form","formaction","formenctype","formmethod","formnovalidate","formtarget","name","type","value"],canvas:["height","width"],col:["span","width"],colgroup:["span"],data:["value"],details:["open"],del:["cite","datetime"],dialog:["open"],embed:["height","src","type","width"],fieldset:["disabled","form","name"],form:["acceptcharset","action","autocomplete","enctype","method","name","novalidate","target","rel"],html:["manifest"],iframe:["allow","allowfullscreen","allowtransparency","frameborder","height","loading","marginheight","marginwidth","mozallowfullscreen","name","referrerpolicy","sandbox","scrolling","seamless","src","srcdoc","webkitallowfullscreen","width"],img:["alt","crossorigin","decoding","height","ismap","loading","referrerpolicy","sizes","src","srcset","usemap","width"],ins:["cite","datetime"],input:["accept","alt","autocomplete","capture","checked","crossorigin","disabled","form","formaction","formenctype","formmethod","formnovalidate","formtarget","height","indeterminate","list","max","maxlength","min","minlength","multiple","name","pattern","placeholder","readonly","required","size","src","step","type","value","width"],keygen:["challenge","disabled","form","keytype","keyparams","name"],label:["form","for"],li:["value"],link:["as","crossorigin","href","hreflang","integrity","media","imagesrcset","imagesizes","referrerpolicy","rel","sizes","type","charset"],map:["name"],menu:["type"],media:["autoplay","controls","currenttime","defaultmuted","defaultplaybackrate","loop","mediagroup","muted","playsinline","preload","src","volume"],meta:["charset","content","http-equiv","name","media"],meter:["form","high","low","max","min","optimum","value"],quote:["cite"],object:["classid","data","form","height","name","type","usemap","width","wmode"],ol:["reversed","start","type"],optgroup:["disabled","label"],option:["disabled","label","selected","value"],output:["form","for","name"],param:["name","value"],progress:["max","value"],slot:["name"],script:["async","charset","crossorigin","defer","integrity","nomodule","nonce","referrerpolicy","src","type"],select:["autocomplete","disabled","form","multiple","name","required","size","value","onchange"],source:["height","media","sizes","src","srcset","type","width"],style:["media","nonce","scoped","type"],table:["align","bgcolor","border","cellpadding","cellspacing","frame","rules","summary","width"],textarea:["autocomplete","cols","dirname","disabled","form","maxlength","minlength","name","placeholder","readonly","required","rows","value","wrap"],td:["align","colspan","headers","rowspan","scope","abbr","height","width","valign"],th:["align","colspan","headers","rowspan","scope","abbr"],time:["datetime"],track:["default","kind","label","src","srclang"],video:["autoplay","controls","crossorigin","disablepictureinpicture","disableremoteplayback","height","loop","muted","playsinline","poster","preload","src","width"],svg:["className","class","color","height","id","lang","max","media","method","min","name","style","target","type","width","role","tabindex","crossorigin","accent-height","accumulate","additive","alignment-baseline","allowReorder","alphabetic","amplitude","arabic-form","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baseline-shift","baseProfile","bbox","begin","bias","by","calcMode","cap-height","clip","clip-path","clipPathUnits","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominant-baseline","dur","dx","dy","edgeMode","elevation","enable-background","end","exponent","externalResourcesRequired","fill","fill-opacity","fill-rule","filter","filterRes","filterUnits","flood-color","flood-opacity","focusable","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","format","from","fx","fy","g1","g2","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","glyphRef","gradientTransform","gradientUnits","hanging","href","horiz-adv-x","horiz-origin-x","ideographic","image-rendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letter-spacing","lighting-color","limitingConeAngle","local","marker-end","markerHeight","marker-mid","marker-start","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overline-position","overline-thickness","paint-order","panose-1","path","pathLength","patternContentUnits","patternTransform","patternUnits","pointer-events","points","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","rendering-intent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","scale","seed","shape-rendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","string","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","surfaceScale","systemLanguage","tableValues","targetX","targetY","text-anchor","text-decoration","textLength","text-rendering","to","transform","u1","u2","underline-position","underline-thickness","unicode","unicode-bidi","unicode-range","units-per-em","v-alphabetic","values","vector-effect","version","vert-adv-y","vert-origin-x","vert-origin-y","v-hanging","v-ideographic","viewBox","viewTarget","visibility","v-mathematical","widths","word-spacing","writing-mode","x1","x2","x","xChannelSelector","x-height","xlink:actuate","xlink:arcrole","xlink:href","xlink:role","xlink:show","xlink:title","xlink:type","xml:base","xml:lang","xmlns","xmlns:xlink","xml:space","y1","y2","y","yChannelSelector","z","zoomAndPan"]},$0=["oncopy","oncut","onpaste","oncompositionend","oncompositionstart","oncompositionupdate","onfocus","onfocusin","onfocusout","onblur","onchange","onbeforeinput","oninput","onreset","onsubmit","oninvalid","onformdata","onload","onerror","ontoggle","onkeydown","onkeypress","onkeyup","onabort","oncanplay","oncanplaythrough","oncuechange","ondurationchange","onemptied","onencrypted","onended","onloadeddata","onloadedmetadata","onloadstart","onpause","onplay","onplaying","onprogress","onratechange","onseeked","onseeking","onstalled","onsuspend","ontimeupdate","onvolumechange","onwaiting","onauxclick","onclick","oncontextmenu","ondblclick","ondrag","ondragend","ondragenter","ondragexit","ondragleave","ondragover","ondragstart","ondrop","onmousedown","onmouseenter","onmouseleave","onmousemove","onmouseout","onmouseover","onmouseup","onselect","onselectionchange","onselectstart","ontouchcancel","ontouchend","ontouchmove","ontouchstart","ongotpointercapture","onpointercancel","onpointerdown","onpointerenter","onpointerleave","onpointermove","onpointerout","onpointerover","onpointerup","onlostpointercapture","onscroll","onresize","onwheel","onanimationstart","onanimationend","onanimationiteration","ontransitionstart","ontransitionrun","ontransitionend","ontransitioncancel","onoutrostart","onoutroend","onintrostart","onintroend","onmessage","onmessageerror","onvisibilitychange","oncancel","onclose","onfullscreenchange","onfullscreenerror"],or=t=>t.startsWith("aria")&&t.length>4&&t.charCodeAt(4)>=65&&t.charCodeAt(4)<=90?"aria-"+t.charAt(4).toLowerCase()+t.slice(5).replace(/([A-Z])/g,e=>"-"+e.toLowerCase()):t.startsWith("data")&&t.length>4&&t.charCodeAt(4)>=65&&t.charCodeAt(4)<=90?"data-"+t.charAt(4).toLowerCase()+t.slice(5).replace(/([A-Z])/g,e=>"-"+e.toLowerCase()):M0(t),$P=new Set(["tabIndex","readOnly","maxLength","minLength","autoComplete","autoFocus","autoPlay","contentEditable","spellCheck","colSpan","rowSpan","srcSet","crossOrigin","accessKey","inputMode","enterKeyHint","formAction","noValidate"]),M0=t=>$P.has(t)?t.toLowerCase():null,MP=new Set(["draggable","contenteditable","spellcheck","autocorrect"]),sr=t=>typeof t=="string"&&(MP.has(t)||t.startsWith("aria-")),re=(t,e)=>e!==!0&&e!==!1?e:sr(t)?e?"true":"false":e===!0?"":e,Te=(t,e)=>e.startsWith("aria-")||e.startsWith("data-")||or(e)||bu.default.includes(e)?!0:Object.prototype.hasOwnProperty.call(bu,t)?bu[t].includes(e):!1,Ry=t=>{if(!k(t))return!1;let e=t.toLowerCase();return $0.includes(e)},FP=(t,e,r)=>{let n={};for(let o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(r&&o in r)continue;if(o==="aria"&&e[o]&&typeof e[o]=="object"){for(let a in e[o])Tt(e[o][a])&&(n["aria-"+a]=e[o][a]);continue}if(o==="data"&&e[o]&&typeof e[o]=="object"){for(let a in e[o])if(Tt(e[o][a])){let c=a.replace(/([A-Z])/g,l=>"-"+l.toLowerCase());n["data-"+c]=e[o][a]}continue}let s=Te(t,o),i=Ry(o);if(Tt(e[o])&&(s||i)){let a=or(o)||o;n[a]=e[o]}}return n},NP=(t,e)=>{let r={};if(t.attr)for(let n in t.attr)r[n]=t.attr[n](e,e.state,e.context);if(t.aria&&typeof t.aria=="object")for(let n in t.aria){let o=t.aria[n];typeof o=="function"&&(r["aria-"+n]=o(e,e.state,e.context))}if(t.data&&typeof t.data=="object")for(let n in t.data){let o=t.data[n];if(typeof o=="function"){let s=n.replace(/([A-Z])/g,i=>"-"+i.toLowerCase());r["data-"+s]=o(e,e.state,e.context)}}return r},nn=(t,e)=>{let r=t.call("exec",e,t);if(r)return k(r)&&r.includes("{{")&&(r=t.call("replaceLiteralsWithObjectFields",r)),r},Oy=(t,e)=>{let r=(t.preSrc||"")+(nn(t,e)||"");if(!r)return;try{return new URL(r),r}catch{}let{context:n}=t;if(!n.files&&!n.assets)return r;if(r.startsWith("/assets/")){let o=r.slice(8),s=n.assets&&(n.assets[r]||n.assets[o]);return s&&s.content?s.content.src:r}if(r.startsWith("/files/")){let o=r.slice(7),s=n.files&&(n.files[r]||n.files[o]);return s&&s.content?s.content.src:r}if(n.assets){let o=n.assets[r];if(o&&o.content)return o.content.src}if(n.files){let o=n.files[r];if(o&&o.content)return o.content.src}return r},Qn={src:t=>Oy(t,t.src),href:t=>nn(t,t.href),action:t=>nn(t,t.action),poster:t=>Oy(t,t.poster),data:t=>nn(t,t.data)},Py=t=>{let e=t.tag||"div",r={};for(let n in Qn)if(t[n]!==void 0&&Te(e,n)){let o=Qn[n](t);o!==void 0&&(r[n]=o)}return r},I0=(t,e)=>{let r=e.context?.cases?.[t];if(r!==void 0)return R(r)?r.call(e,e):!!r},jP=(t,e,r)=>{if(t==="$"){let o=I0(e,r);return o===void 0&&(o=!!r[e]),o}let n=r[e]===!0||r.state[e];if(!n){let o=I0(e,r);o!==void 0&&(n=o)}return t==="."?!!n:!n},BP=new Set(["$",".","!"]),VP=(t,e,r)=>{let n={},o=(s,i,a,c)=>{let l=i;n[s]=f=>{if(jP(a,c,f))return R(l)?l(f):l}};for(let s in t){let i=s.charAt(0);if(!BP.has(i))continue;let a=t[s];if(!a||typeof a!="object")continue;let c=s.slice(1);for(let l in a){if(r&&l in r)continue;if(l==="aria"&&a[l]&&typeof a[l]=="object"){for(let g in a[l])o("aria-"+g,a[l][g],i,c);continue}if(l==="data"&&a[l]&&typeof a[l]=="object"){for(let g in a[l]){let p=g.replace(/([A-Z])/g,h=>"-"+h.toLowerCase());o("data-"+p,a[l][g],i,c)}continue}let f=Te(e,l),u=Ry(l);if(!f&&!u)continue;let d=or(l)||l;o(d,a[l],i,c)}}return n};function _s(t={},e={}){let r=this,n=r.__ref;if(!n)return;if((typeof t=="string"||typeof t=="number")&&(t={text:t}),!e.preventListeners&&typeof r.onBeforeUpdate=="function"&&Dy(n))try{let i=r.onBeforeUpdate(r,r.state,r.context,e);if(i&&typeof i.then=="function")i.then(()=>kr(n,!1),a=>{kr(n,!0),r.context?.plugins?.length&&Ot("error",r,{hook:"onBeforeUpdate",error:a})||console.error("[DOMQL] onBeforeUpdate error:",a)});else if(kr(n,!1),i===!1)return r}catch(i){throw kr(n,!0),i}let o=!t||Object.keys(t).length===0,s=[];yl(()=>{if(t.state&&kt(r.state)&&r.state.$update(t.state),t.text!==void 0&&(r.text=t.text,!n.__exec.text&&r.node&&xs(r,t.text??"")),t.html!==void 0&&(r.html=t.html,!n.__exec.html&&r.node&&(r.node.innerHTML=t.html)),t.style&&r.node?.style){if(!n.__exec.style)for(let i in t.style){let a=t.style[i];if(a==null)continue;let c=i.replace(/[A-Z]/g,f=>"-"+f.toLowerCase()),l=String(a).replace(/\s*!important\s*$/,"");r.node.style.setProperty(c,l,"important")}r.style||(r.style={}),Object.assign(r.style,t.style)}if(t.attr&&r.node?.setAttribute){for(let i in t.attr){let a=t.attr[i];a==null||a===!1&&!sr(i)?r.node.removeAttribute(i):typeof a!="function"&&typeof a!="object"&&r.node.setAttribute(i,re(i,a))}r.attr||(r.attr={}),Object.assign(r.attr,t.attr)}if(t.data&&r.node?.dataset){for(let i in t.data)r.node.dataset[i]=t.data[i];r.data||(r.data={}),Object.assign(r.data,t.data)}for(let i in t){if(jt.has(i)||i==="state")continue;let a=t[i],c=r[i];if(c&&c.__ref&&typeof c.update=="function")c.update(a,e);else if(typeof a=="object"&&a!==null){let l=i.charCodeAt(0);l>=65&&l<=90&&ne(a,r,i,e)}else i!=="text"&&i!=="html"&&i!=="style"&&i!=="attr"&&i!=="data"&&(r[i]=a,typeof a!="function"&&s.push(i))}});for(let i=0;i<s.length;i++)j0(r,s[i]);if(r.node){for(let i=0;i<s.length;i++)if(F0(s[i])){N0(r);break}}if(r.node&&o&&n.__effects&&n.__effects.length)for(let i=0;i<n.__effects.length;i++){let a=n.__effects[i];a&&!a._disposed&&!a._isSubscribeToEffect&&typeof a._execute=="function"&&a._execute()}else if(r.node&&n.__conditionalRunners)for(let i of n.__conditionalRunners)i();return Ot("update",r),!e.preventListeners&&typeof r.onUpdate=="function"&&r.onUpdate(r,r.state,r.context,e),r}function vr(t){if(!t)return;let e=t.__ref;if(!e)return;let r=lr();if(r){Ke(null);try{return vr(t)}finally{Ke(r)}}e.__disposed=!0;try{typeof t.onBeforeRemove=="function"&&t.onBeforeRemove(t,t.state,t.context)}catch(o){console.error("[smbls] onBeforeRemove error:",o)}if(e.__effects){for(let o=0;o<e.__effects.length;o++)e.__effects[o].dispose();e.__effects.length=0}if(typeof e.__releaseMedia=="function"&&(e.__releaseMedia(),e.__releaseMedia=null),e.__eventCleanup){for(let o=0;o<e.__eventCleanup.length;o++)e.__eventCleanup[o]();e.__eventCleanup.length=0}if(e.__children){let o=e.__children.slice();e.__children.length=0;for(let s=0;s<o.length;s++){let i=t[o[s]];i&&i.__ref&&vr(i)}}t.node?.parentNode?t.node.remove():t.tag==="fragment"&&e.__fragmentAnchor?.parentNode&&e.__fragmentAnchor.remove();let n=t.state?.$destroy||t.state?.destroy;if(typeof n=="function"&&t.state.__element===t&&n.call(t.state),t.parent?.__ref?.__children){let o=t.parent.__ref.__children.indexOf(t.key);o!==-1&&t.parent.__ref.__children.splice(o,1),delete t.parent[t.key]}try{typeof t.onRemove=="function"&&t.onRemove(t)}catch(o){console.error("[smbls] onRemove error:",o)}t.node=null,t.parent=null,t.__ref=null}function ws(){vr(this)}D();D();D();var UP=["ease","linear","ease-in","ease-out","ease-in-out","step-start","step-end"],zP=["none","forwards","backwards","both"],HP=["normal","reverse","alternate","alternate-reverse"],WP=["running","paused"],qP=t=>/^[\d.]+m?s$/.test(t),KP=/^(?:translate(?:3d|x|y|z)?\((?:\s*0[a-z%]*\s*,?)+\)|scale(?:3d|x|y|z)?\((?:\s*1(?:\.0+)?\s*,?)+\)|rotate(?:3d|x|y|z)?\((?:\s*0[a-z%]*\s*,?)+\)|skew(?:x|y)?\((?:\s*0[a-z%]*\s*,?)+\)|matrix\(\s*1\s*,\s*0\s*,\s*0\s*,\s*1\s*,\s*0\s*,\s*0\s*\))$/,GP=t=>{let e=String(t).trim().toLowerCase();if(e===""||e==="none"||e==="initial"||e==="unset")return!0;let r=e.match(/[a-z0-9]+\([^()]*\)/g);return!r||r.join("").replace(/\s+/g,"")!==e.replace(/\s+/g,"")?!1:r.every(n=>KP.test(n.replace(/\s+/g,"")))},B0=t=>/^(?:\s*0[a-z%]*)+\s*$/.test(String(t).toLowerCase())||/^(none|initial|unset)$/.test(String(t).trim().toLowerCase()),YP={transform:GP,translate:B0,rotate:t=>B0(t)||/^\s*(?:[xyz]\s+)?0(?:deg|rad|turn|grad)?\s*$/.test(String(t).toLowerCase()),scale:t=>/^(none|initial|unset)$/.test(String(t).trim().toLowerCase())||/^(?:\s*1(?:\.0+)?)+\s*$/.test(String(t)),opacity:t=>/^(initial|unset)$/.test(String(t).trim().toLowerCase())||Number(t)===1},XP=t=>{let e=String(t).trim().toLowerCase();if(e==="from")return 0;if(e==="to")return 100;let r=e.match(/^(\d+(?:\.\d+)?)%$/);return r?Number(r[1]):null},ZP=t=>{if(!v(t))return null;let e=null,r=-1;for(let n in t){let o=XP(n);o==null||!v(t[n])||o>=r&&(r=o,e=t[n])}return e},JP=t=>{let e=ZP(t);if(!e)return!1;let r=Object.keys(e);if(!r.length)return!1;for(let n of r){let o=YP[n];if(!o)return!1;let s=e[n];if(s==null||typeof s=="object"||typeof s=="function"||!o(s))return!1}return!0},QP=(t,e)=>{if(v(t))return t;let{animation:r}=e.context&&e.context.designSystem||{},n=r&&r[t];return v(n)?n:null},t2=["reverse","alternate","alternate-reverse"],V0=(t,e,r)=>{let n=r||e.animationDirection;return n&&t2.includes(String(n))?"both":JP(QP(t,e))?"backwards":"both"},e2=0,U0=new Map,Ly=(t,e)=>{let{animation:r}=e.context&&e.context.designSystem||{};if(v(t)){let o=JSON.stringify(t),s=U0.get(o);if(s)return s;let i=`smbls-anim-${e2++}`,a=us(i,t);return U0.set(o,a),a}let n=r&&r[t];return v(n)?us(t,n):t},r2=t=>{let e=[],r=0,n="";for(let o of String(t).trim())o==="("?r++:o===")"&&r>0&&r--,r===0&&/\s/.test(o)?(n&&e.push(n),n=""):n+=o;return n&&e.push(n),e},n2=(t,e)=>{let{animation:r}=e.context&&e.context.designSystem||{},n=r2(t),o=null,s=[],i=null,a=null,c=null,l=null,f=null;for(let u of n)r&&r[u]?o=u:qP(u)?s.push(u):UP.includes(u)||u.startsWith("cubic-bezier")||u.startsWith("steps(")||u.startsWith("linear(")?i=u:u==="infinite"||/^\d+$/.test(u)?a=u==="infinite"?u:Number(u):HP.includes(u)?c=u:zP.includes(u)?l=u:WP.includes(u)?f=u:o||(o=u);return{name:o,durations:s,timingFunction:i,iterationCount:a,direction:c,fillMode:l,playState:f}},Iy={animation:(t,e)=>{if(t!=null){if(k(t)&&t.includes(" ")){let r=n2(t,e);return{animationName:Ly(r.name||t,e),animationDuration:r.durations[0]||pe(e.animationDuration||"A").timing,animationDelay:r.durations[1]||pe(e.animationDelay||"0s").timing,animationTimingFunction:r.timingFunction||Ae(e.animationTimingFunction||"ease"),animationFillMode:r.fillMode||e.animationFillMode||V0(r.name||t,e,r.direction),animationIterationCount:r.iterationCount!=null?r.iterationCount:e.animationIterationCount||1,animationPlayState:r.playState||e.animationPlayState,animationDirection:r.direction||e.animationDirection}}return{animationName:Ly(t,e),animationDuration:pe(e.animationDuration||"A").timing,animationDelay:pe(e.animationDelay||"0s").timing,animationTimingFunction:Ae(e.animationTimingFunction||"ease"),animationFillMode:e.animationFillMode||V0(t,e),animationIterationCount:e.animationIterationCount||1,animationPlayState:e.animationPlayState,animationDirection:e.animationDirection}}},animationName:(t,e)=>({animationName:Ly(t,e)}),animationDuration:t=>({animationDuration:pe(t).timing}),animationDelay:t=>({animationDelay:pe(t).timing}),animationTimingFunction:t=>({animationTimingFunction:Ae(t)}),animationIterationCount:t=>({animationIterationCount:t}),animationFillMode:t=>({animationFillMode:t}),animationPlayState:t=>({animationPlayState:t}),animationDirection:t=>({animationDirection:t})};D();var _u=(t,e,r)=>{if(typeof e=="number"&&(e=String(e)),!k(e))return;let[n,o]=pt(e);return{...I(t+"Start",n,r),...I(t+"End",o||n,r)}},$y={show:t=>t?void 0:{display:"none !important"},hide:t=>t?{display:"none !important"}:void 0,height:(t,e)=>I("height",t,e),width:(t,e)=>I("width",t,e),boxSizing:t=>Lt(t)?{boxSizing:"border-box"}:{boxSizing:t},boxSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("height",e),...vt("width",r||e)}},inlineSize:(t,e)=>I("inlineSize",t,e),blockSize:(t,e)=>I("blockSize",t,e),minWidth:(t,e)=>I("minWidth",t,e),maxWidth:(t,e)=>I("maxWidth",t,e),widthRange:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minWidth",e),...vt("maxWidth",r||e)}},minHeight:(t,e)=>I("minHeight",t,e),maxHeight:(t,e)=>I("maxHeight",t,e),heightRange:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minHeight",e),...vt("maxHeight",r||e)}},size:t=>{if(!k(t))return;let[e,r]=pt(t);return{...I("inlineSize",e),...I("blockSize",r||e)}},minBlockSize:(t,e)=>I("minBlockSize",t,e),minInlineSize:(t,e)=>I("minInlineSize",t,e),maxBlockSize:(t,e)=>I("maxBlockSize",t,e),maxInlineSize:(t,e)=>I("maxInlineSize",t,e),minSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("minInlineSize",e),...vt("minBlockSize",r||e)}},maxSize:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("maxInlineSize",e),...vt("maxBlockSize",r||e)}},borderWidth:(t,e)=>I("borderWidth",t,e),borderTopWidth:(t,e)=>I("borderTopWidth",t,e),borderRightWidth:(t,e)=>I("borderRightWidth",t,e),borderBottomWidth:(t,e)=>I("borderBottomWidth",t,e),borderLeftWidth:(t,e)=>I("borderLeftWidth",t,e),textDecorationThickness:(t,e)=>I("textDecorationThickness",t,e),textUnderlineOffset:(t,e)=>I("textUnderlineOffset",t,e),padding:(t,e)=>I("padding",t,e),paddingInline:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("paddingInlineStart",e),...vt("paddingInlineEnd",r||e)}},paddingBlock:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("paddingBlockStart",e),...vt("paddingBlockEnd",r||e)}},paddingTop:(t,e)=>I("paddingBlockStart",t,e),paddingBottom:(t,e)=>I("paddingBlockEnd",t,e),paddingLeft:(t,e)=>I("paddingInlineStart",t,e),paddingRight:(t,e)=>I("paddingInlineEnd",t,e),paddingBlockStart:(t,e)=>I("paddingBlockStart",t,e),paddingBlockEnd:(t,e)=>I("paddingBlockEnd",t,e),paddingInlineStart:(t,e)=>I("paddingInlineStart",t,e),paddingInlineEnd:(t,e)=>I("paddingInlineEnd",t,e),margin:(t,e)=>I("margin",t,e),marginInline:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("marginInlineStart",e),...vt("marginInlineEnd",r||e)}},marginBlock:t=>{if(!k(t))return;let[e,r]=pt(t);return{...vt("marginBlockStart",e),...vt("marginBlockEnd",r||e)}},marginTop:(t,e)=>I("marginBlockStart",t,e),marginBottom:(t,e)=>I("marginBlockEnd",t,e),marginLeft:(t,e)=>I("marginInlineStart",t,e),marginRight:(t,e)=>I("marginInlineEnd",t,e),marginInlineStart:(t,e)=>I("marginInlineStart",t,e),marginInlineEnd:(t,e)=>I("marginInlineEnd",t,e),marginBlockStart:(t,e)=>I("marginBlockStart",t,e),marginBlockEnd:(t,e)=>I("marginBlockEnd",t,e),scrollMargin:(t,e)=>I("scrollMargin",t,e),scrollMarginTop:(t,e)=>I("scrollMarginTop",t,e),scrollMarginRight:(t,e)=>I("scrollMarginRight",t,e),scrollMarginBottom:(t,e)=>I("scrollMarginBottom",t,e),scrollMarginLeft:(t,e)=>I("scrollMarginLeft",t,e),scrollMarginBlock:(t,e)=>_u("scrollMarginBlock",t,e),scrollMarginInline:(t,e)=>_u("scrollMarginInline",t,e),scrollMarginBlockStart:(t,e)=>I("scrollMarginBlockStart",t,e),scrollMarginBlockEnd:(t,e)=>I("scrollMarginBlockEnd",t,e),scrollMarginInlineStart:(t,e)=>I("scrollMarginInlineStart",t,e),scrollMarginInlineEnd:(t,e)=>I("scrollMarginInlineEnd",t,e),scrollPadding:(t,e)=>I("scrollPadding",t,e),scrollPaddingTop:(t,e)=>I("scrollPaddingTop",t,e),scrollPaddingRight:(t,e)=>I("scrollPaddingRight",t,e),scrollPaddingBottom:(t,e)=>I("scrollPaddingBottom",t,e),scrollPaddingLeft:(t,e)=>I("scrollPaddingLeft",t,e),scrollPaddingBlock:(t,e)=>_u("scrollPaddingBlock",t,e),scrollPaddingInline:(t,e)=>_u("scrollPaddingInline",t,e),scrollPaddingBlockStart:(t,e)=>I("scrollPaddingBlockStart",t,e),scrollPaddingBlockEnd:(t,e)=>I("scrollPaddingBlockEnd",t,e),scrollPaddingInlineStart:(t,e)=>I("scrollPaddingInlineStart",t,e),scrollPaddingInlineEnd:(t,e)=>I("scrollPaddingInlineEnd",t,e),gap:t=>({gap:ru(t)}),columnGap:(t,e)=>Ce(e,"columnGap",t),rowGap:(t,e)=>Ce(e,"rowGap",t),flexWrap:t=>{if(t!=null)return{display:"flex",flexWrap:t}},flexFlow:(t,e)=>{let r=e.reverse;if(!k(t))return;let[n,o]=(t||"row").split(" ");return(t.startsWith("x")||t==="row")&&(n="row"),(t.startsWith("y")||t==="column")&&(n="column"),{display:"flex",flexFlow:(n||"")+(!n.includes("-reverse")&&r?"-reverse":"")+" "+(o||"")}},flexAlign:t=>{if(!k(t))return;let[e,r]=t.split(" ");return{display:"flex",alignItems:e,justifyContent:r}},round:(t,e)=>wr(t??e.borderRadius,e,"round"),borderRadius:(t,e)=>wr(t??e.round,e,"borderRadius"),borderTopLeftRadius:(t,e)=>wr(t,e,"borderTopLeftRadius","borderTopLeftRadius"),borderTopRightRadius:(t,e)=>wr(t,e,"borderTopRightRadius","borderTopRightRadius"),borderBottomLeftRadius:(t,e)=>wr(t,e,"borderBottomLeftRadius","borderBottomLeftRadius"),borderBottomRightRadius:(t,e)=>wr(t,e,"borderBottomRightRadius","borderBottomRightRadius")};var My={fontSize:t=>Za(t)||t,fontFamily:t=>({fontFamily:Ya(t)||t}),fontWeight:t=>({fontWeight:t,fontVariationSettings:'"wght" '+t}),lineClamp:t=>{if(t!=null)return t==="none"?{WebkitLineClamp:"none",lineClamp:"none"}:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:String(t),lineClamp:String(t),overflow:"hidden"}}};var Fy={overflow:t=>({overflow:t}),cursor:(t,e,r,n)=>{if(!t)return;let o=n.assets&&n.assets[t];if(o&&o.content)t=`url(${o.content.src})`;else{let s=n.files&&n.files[t];s&&s.content&&(t=`url(${s.content.src})`)}return{cursor:t}},opacity:t=>t!=null?{opacity:String(t)}:void 0,visibility:t=>t!=null?{visibility:t}:void 0,pointerEvents:t=>t!=null?{pointerEvents:t}:void 0};var Ny={inset:(t,e)=>{if(e.call("isNumber",t))return{inset:t};if(e.call("isString",t))return{inset:pt(t).map(r=>Ct(r,"k").k).join(" ")}},left:t=>Ct(t,"left"),top:t=>Ct(t,"top"),right:t=>Ct(t,"right"),bottom:t=>Ct(t,"bottom"),verticalInset:t=>{if(typeof t!="string")return;let e=pt(t).map(r=>Ct(r,"k").k);return{top:e[0],bottom:e[1]||e[0]}},horizontalInset:t=>{if(typeof t!="string")return;let e=pt(t).map(r=>Ct(r,"k").k);return{left:e[0],right:e[1]||e[0]}}};D();var xu=0,wu=()=>{xu++},Su=()=>{xu>0&&xu--},ge=({context:t,state:e})=>{let r=t?.designSystem,n=e?.root?.globalTheme||r?.globalTheme;return n&&n!=="auto"?n:xu>0?null:r&&r.resolvedTheme||null},oe=(t,e)=>{if(e==null||e==="")return;if(!v(e))return{[t]:e};let r={},n=!1;for(let o in e){let s=e[o];if(!(s==null||s==="")){if(v(s)){let i=oe(t,s);i&&(r[o]=i,n=!0);continue}r[o]={[t]:s},n=!0}}return n?r:void 0},jy={theme:(t,e)=>{if(t)return e.themeModifier?Ee(t,`@${e.themeModifier}`):Ee(t)},color:(t,e)=>{let r=ge(e);if(t)return oe("color",Mt(t,r))},background:(t,e)=>{let r=ge(e);if(t)return k(t)&&t.includes("gradient")&&t.includes("(")?{background:sc(t,r)}:oe("background",Mt(t,r))},backgroundColor:(t,e)=>{let r=ge(e);if(t)return oe("backgroundColor",Mt(t,r))},backgroundImage:(t,e,r,n)=>{let o=ge(e);if(!t)return;let s=n.assets&&n.assets[t];if(s&&s.content)t=s.content.src;else{let i=n.files&&n.files[t];i&&i.content&&(t=i.content.src)}return oe("backgroundImage",eu(t,o))},textStroke:t=>{let e=Qf(t);if(e!=null)return{WebkitTextStroke:e}},outline:t=>({outline:nr(t)}),outlineWidth:(t,e)=>I("outlineWidth",t,e),outlineColor:(t,e)=>{let r=ge(e);if(t)return oe("outlineColor",Mt(t,r))},outlineOffset:(t,e)=>I("outlineOffset",t,e),border:t=>({border:nr(t)}),borderColor:(t,e)=>{let r=ge(e);if(t)return oe("borderColor",Mt(t,r))},borderTopColor:(t,e)=>{let r=ge(e);if(t)return oe("borderTopColor",Mt(t,r))},borderBottomColor:(t,e)=>{let r=ge(e);if(t)return oe("borderBottomColor",Mt(t,r))},borderLeftColor:(t,e)=>{let r=ge(e);if(t)return oe("borderLeftColor",Mt(t,r))},borderRightColor:(t,e)=>{let r=ge(e);if(t)return oe("borderRightColor",Mt(t,r))},borderLeft:t=>({borderLeft:nr(t)}),borderTop:t=>({borderTop:nr(t)}),borderRight:t=>({borderRight:nr(t)}),borderBottom:t=>({borderBottom:nr(t)}),shadow:(t,e)=>{let r=ge(e);if(t)return oe("boxShadow",tu(t,r))},boxShadow:(t,e)=>{if(!k(t))return;let[r,n]=t.split("!importan"),o=ge(e),s=n?" !important":"",i=oc(r.trim(),o);return k(i)?{boxShadow:i+s}:oe("boxShadow",i)},textShadow:(t,{context:e})=>oe("textShadow",oc(t,e.designSystem.globalTheme)),columnRule:t=>({columnRule:nr(t)})};var uc={transition:t=>{let e=ou(t);if(e!=null)return{transition:e}},transitionDuration:t=>({transitionDuration:ic(t)}),transitionDelay:t=>({transitionDelay:ic(t)}),transitionTimingFunction:t=>({transitionTimingFunction:Ae(t)}),transitionProperty:t=>({transitionProperty:t,willChange:t})};D();var By={flow:(t,e)=>{let r=e.reverse;if(!k(t))return;let[n,o]=(t||"row").split(" ");return(t.startsWith("x")||t==="row")&&(n="row"),(t.startsWith("y")||t==="column")&&(n="column"),{display:"flex",flexFlow:(n||"")+(!n.includes("-reverse")&&r?"-reverse":"")+" "+(o||"")}},wrap:(t,e)=>{if(t!=null)return{display:"flex",flexWrap:t}},align:(t,e)=>{if(!k(t))return;let[r,n]=t.split(" ");return{display:"flex",alignItems:r,justifyContent:n}}};D();var o2=/(^|[^\w.-])([A-Za-z_][\w-]*)/g,z0=t=>{if(!k(t))return t;let e=A().sizes;return e?t.replace(o2,(r,n,o)=>{let s=e[o];return s==null?r:n+String(s)}):t},ir=t=>z0(nu(t)),Vy={gridTemplateColumns:t=>({gridTemplateColumns:ir(t)}),gridTemplateRows:t=>({gridTemplateRows:ir(t)}),gridAutoColumns:t=>({gridAutoColumns:ir(t)}),gridAutoRows:t=>({gridAutoRows:ir(t)}),area:t=>({gridArea:t}),template:t=>({gridTemplate:t}),templateAreas:t=>({gridTemplateAreas:t}),column:t=>({gridColumn:t}),columns:t=>({gridTemplateColumns:ir(t)}),templateColumns:t=>({gridTemplateColumns:ir(t)}),autoColumns:t=>({gridAutoColumns:ir(t)}),columnStart:t=>({gridColumnStart:t}),row:t=>({gridRow:t}),rows:t=>({gridTemplateRows:ir(t)}),templateRows:t=>({gridTemplateRows:ir(t)}),autoRows:t=>({gridAutoRows:ir(t)}),rowStart:t=>({gridRowStart:t}),autoFlow:t=>({gridAutoFlow:t})};var wt={...Iy,...$y,...My,...Fy,...Ny,...jy,...uc,...By,...Vy};var Et=new Set(["accentColor","alignContent","alignItems","alignSelf","alignmentBaseline","all","animation","animationDelay","animationDirection","animationDuration","animationFillMode","animationIterationCount","animationName","animationPlayState","animationRange","animationRangeEnd","animationRangeStart","animationTimeline","animationTimingFunction","appearance","aspectRatio","backdropFilter","backfaceVisibility","background","backgroundAttachment","backgroundBlendMode","backgroundClip","backgroundColor","backgroundImage","backgroundOrigin","backgroundPosition","backgroundPositionX","backgroundPositionY","backgroundRepeat","backgroundRepeatX","backgroundRepeatY","backgroundSize","baselineShift","blockSize","border","borderBlock","borderBlockColor","borderBlockEnd","borderBlockEndColor","borderBlockEndStyle","borderBlockEndWidth","borderBlockStart","borderBlockStartColor","borderBlockStartStyle","borderBlockStartWidth","borderBlockStyle","borderBlockWidth","borderBottom","borderBottomColor","borderBottomLeftRadius","borderBottomRightRadius","borderBottomStyle","borderBottomWidth","borderCollapse","borderColor","borderImage","borderImageOutset","borderImageRepeat","borderImageSlice","borderImageSource","borderImageWidth","borderLeft","borderLeftColor","borderLeftStyle","borderLeftWidth","borderRadius","borderRight","borderRightColor","borderRightStyle","borderRightWidth","borderSpacing","borderStyle","borderTop","borderTopColor","borderTopLeftRadius","borderTopRightRadius","borderTopStyle","borderTopWidth","borderWidth","bottom","boxDecorationBreak","boxShadow","boxSizing","breakAfter","breakBefore","breakInside","captionSide","caretColor","clear","clip","clipPath","color","colorAdjust","colorInterpolation","colorInterpolationFilters","colorRendering","columnCount","columnFill","columnGap","columnRule","columnRuleColor","columnRuleStyle","columnRuleWidth","columnSpan","columnWidth","columns","contain","content","counterIncrement","counterReset","cursor","direction","display","emptyCells","filter","flex","flexBasis","flexDirection","flexFlow","flexGrow","flexShrink","flexWrap","float","font","fontFamily","fontFeatureSettings","fontKerning","fontLanguageOverride","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontVariantAlternates","fontVariantCaps","fontVariantEastAsian","fontVariantNumeric","fontVariantPosition","fontWeight","fontVariationSettings","fontSynthesis","forcedColorAdjust","gap","grid","gridArea","gridAutoColumns","gridAutoFlow","gridAutoRows","gridColumn","gridColumnEnd","gridColumnGap","gridColumnStart","gridGap","gridRow","gridRowEnd","gridRowGap","gridRowStart","gridTemplate","gridTemplateAreas","gridTemplateColumns","gridTemplateRows","height","hyphens","imageOrientation","imageRendering","imeMode","inset","insetBlock","insetBlockEnd","insetBlockStart","insetInline","insetInlineEnd","insetInlineStart","initialLetter","interpolateSize","isolation","justifyContent","justifyItems","justifySelf","left","letterSpacing","lineBreak","lineClamp","lineHeight","listStyle","listStyleImage","listStylePosition","listStyleType","margin","marginBottom","marginLeft","marginRight","marginTop","marginBlock","marginBlockEnd","marginBlockStart","marginInline","marginInlineEnd","marginInlineStart","mask","maskBorder","maskBorderImage","maskBorderOutset","maskBorderRepeat","maskBorderSlice","maskBorderSource","maskBorderWidth","maskClip","maskComposite","maskImage","maskOrigin","maskPosition","maskRepeat","maskSize","maskType","maxBlockSize","maxHeight","maxInlineSize","maxWidth","minBlockSize","minHeight","minInlineSize","minWidth","mixBlendMode","objectFit","objectPosition","objectViewBox","offset","offsetDistance","offsetPath","offsetRotate","opacity","order","orientation","outline","outlineColor","outlineOffset","outlineStyle","outlineWidth","overflow","overflowAnchor","overflowClip","overflowScrolling","overflowWrap","overflowX","overflowY","overscrollBehavior","overscrollBehaviorX","overscrollBehaviorY","padding","paddingBottom","paddingLeft","paddingRight","paddingTop","pageBreakAfter","pageBreakBefore","pageBreakInside","paintOrder","perspective","perspectiveOrigin","placeContent","placeItems","placeSelf","pointerEvents","position","resize","right","rotate","rowGap","scrollBehavior","scrollMargin","scrollMarginBlock","scrollMarginBlockEnd","scrollMarginBlockStart","scrollMarginBottom","scrollMarginInline","scrollMarginInlineEnd","scrollMarginInlineStart","scrollMarginLeft","scrollMarginRight","scrollMarginTop","scrollPadding","scrollPaddingBlock","scrollPaddingBlockEnd","scrollPaddingBlockStart","scrollPaddingBottom","scrollPaddingInline","scrollPaddingInlineEnd","scrollPaddingInlineStart","scrollPaddingLeft","scrollPaddingRight","scrollPaddingTop","scrollSnapAlign","scrollSnapStop","scrollSnapType","scrollTimeline","scrollTimelineAxis","scrollTimelineName","scrollbarColor","scrollbarGutter","scrollbarWidth","shapeImageThreshold","shapeMargin","shapeOutside","tabSize","tableLayout","textAlign","textAlignLast","textDecoration","textDecorationColor","textDecorationLine","textDecorationSkipInk","textDecorationStyle","textDecorationThickness","textIndent","textOverflow","textShadow","textTransform","textUnderlineOffset","textWrap","textWrapMode","textWrapStyle","timelineScope","top","touchAction","transform","transformOrigin","transformStyle","transition","transitionDelay","transitionDuration","transitionProperty","transitionTimingFunction","translate","translateX","translateY","translateZ","unicodeBidi","userSelect","verticalAlign","viewTimeline","viewTimelineAxis","viewTimelineInset","viewTimelineName","visibility","whiteSpace","widows","width","willChange","wordBreak","wordSpacing","wordWrap","writingMode","zIndex"]);D();var s2=/^-?[A-Z][0-9]?$/,i2=/^[a-z][0-9]?$/,H0=/var\(\s*(--[A-Za-z0-9-]+)/g,a2=t=>{let e=new Set,r=new Set;if(!t||typeof t!="object")return{knownLetters:e,knownVars:r};for(let n in t){let o=t[n];if(!(!o||typeof o!="object")){if(o.sequence&&typeof o.sequence=="object")for(let s in o.sequence)e.add(s);if(o.vars&&typeof o.vars=="object")for(let s in o.vars)r.add(s)}}return{knownLetters:e,knownVars:r}},c2=(t,e)=>{if(!e.size)return[];let r=t.split(/[(),\s]+/).filter(Boolean),n=new Set;for(let o of r){if(!s2.test(o))continue;let s=o.charCodeAt(0)===45?o.slice(1):o;e.has(s)&&n.add(o)}return[...n]},l2=(t,e)=>{if(!e.size)return[];let r=[];H0.lastIndex=0;let n;for(;n=H0.exec(t);){let o=n[1];if(e.has(o))continue;let s=o.lastIndexOf("-");if(s===-1)continue;let i=o.slice(s+1);if(!i2.test(i))continue;let a=o.slice(0,s+1)+i.toUpperCase();a!==o&&e.has(a)&&r.push({varName:o,corrected:a})}return r},ku=new Set,W0=(t,e,r)=>{if(!gt()||!k(e)||!e)return;let n;try{n=A()}catch{return}let{knownLetters:o,knownVars:s}=a2(n);if(!o.size&&!s.size)return;let i=c2(e,o),a=l2(e,s);if(!i.length&&!a.length)return;let c=r?.__ref?.path?r.__ref.path.join("."):r?.key||"?";for(let l of i){let f=`${c}::${t}::bare::${l}::${e}`;ku.has(f)||(ku.add(f),console.warn(`[smbls/css-in-props] "${t}" on <${c}> looks like it contains an un-wrapped design-system token ("${l}") \u2014 "${t}" has no registered resolver, so its value is forwarded to the browser untouched. A bare letter token there is invalid CSS, so the browser drops the ENTIRE "${t}" declaration (not just this argument). Wrap it in var(--<family>-${l.replace("-","")}) (or calc(-1 * var(--<family>-${l.replace("-","")})) for a negative). Value: "${e}"`))}for(let{varName:l,corrected:f}of a){let u=`${c}::${t}::case::${l}::${e}`;ku.has(u)||(ku.add(u),console.warn(`[smbls/css-in-props] "${t}" on <${c}> references ${l}, which the active design system never emits. CSS custom-property names are case-sensitive \u2014 the real variable is ${f}, so this reference silently never resolves. Value: "${e}"`))}};D();var f2=/^\[data-theme=(?:"([^"]+)"|'([^']+)')\]$/,u2=(t,e,r)=>{let{context:n}=r;if(!n.designSystem?.media)return;let o=t.slice(1),s=n.designSystem.media[o],i=se(e,r);if(!s)return{[t]:i};if(/^@(media|supports|container)\b/.test(s))return{[s]:i};if(s==="print")return{"@media print":i};if(s[0]==="(")return{[`@media screen and ${s}`]:i};let a=s.match(f2),c=a?a[1]||a[2]:o,l={[`${s} &`]:i};if(c==="dark"||c==="light"){let f=n.designSystem?.scopeSelector||":root",u=f===":root"?":root:not([data-theme])":`${f}:not([data-theme])`;l[`@media (prefers-color-scheme: ${c})`]={[`${u} &`]:i}}return l},q0=(t,e,r)=>({[t]:se(e,r)}),dc=(t,e,r)=>{let n=`&${t}`,o=se(e,r);if(t.includes(",")&&o){let s={},i={};for(let a in o)typeof o[a]=="object"&&o[a]!==null?i[a]=o[a]:s[a]=o[a];if(Object.keys(i).length){let a=n.split(",").map(l=>l.trim()),c={};Object.keys(s).length&&(c[n]=s);for(let l in i){let f=a.map(u=>`${u} ${l}`).join(", ");c[f]=i[l]}return c}}return{[n]:o}},Uy=(t,e)=>{let r=e.context?.cases?.[t];if(r!==void 0)return R(r)?r.call(e,e):!!r},d2=(t,e,r)=>{let n=t.slice(1),o=Uy(n,r);if(o===void 0&&(o=!!r[n]),!!o)return se(e,r)},p2=(t,e,r)=>({[t]:e}),h2=(t,e,r)=>{let n=t.slice(1),o=r[n]===!0||r.state?.[n];if(!o)if(typeof r[n]=="function")try{o=r[n](r,r.state,r.context)}catch{}else{let s=Uy(n,r);s!==void 0&&(o=s)}if(o)return se(e,r)},g2=(t,e,r)=>{let n=t.slice(1),o=r[n]===!0||r.state?.[n];if(!o)if(typeof r[n]=="function")try{o=r[n](r,r.state,r.context)}catch{}else{let s=Uy(n,r);s!==void 0&&(o=s)}if(!o)return se(e,r)},zy=(t,e)=>se(t,e),Hy={"@":u2,":":dc,"[":dc,"*":dc,"+":dc,"~":dc,"&":q0,">":q0,$:d2,"-":p2,".":h2,"!":g2};var vu=Nr(),K0=(t,e,r)=>{let n=e?.context?.designSystem;n&&ct(n);try{let o={},s={},i=(a,c)=>{if(r.unpack){o={...o,...c};return}o[a]=c};for(let a in t){let c=t[a];if(c!==null)if(a==="class"&&k(c)){let l=G0(c,e);l&&(r.unpack?bt(o,l):o.designSystemClass=l)}else if(a==="true"){let l=dt(c,e);bt(o,zy(l,e))}else if(e.classlist?.[a]){let l=e.classlist[a],f=R(l)?l(e,e.state,e.context):l;f&&i(a,f),!vu&&v(o[a])&&(o[a].label=a)}else if(wt[a]){let l=dt(c,e);if(l===null)continue;P(l)&&(l=l.reduce((u,d)=>bt(u,d),{}));let f=wt[a](l,e,e.state,e.context);P(f)&&(f=f.reduce((u,d)=>bt(u,d),{})),f&&i(a,f),!vu&&v(o[a])&&(o[a].label=a)}else if(Et.has(a)){let l=dt(c,e);if(l===null)continue;typeof l=="string"&&l.charCodeAt(0)===45&&l.charCodeAt(1)===45&&(l=`var(${l})`),vu||W0(a,l,e),i(a,{[a]:l}),!vu&&v(o[a])&&(o[a].label=a)}else s[a]=c}return[o,s]}finally{n&&it()}},G0=(t,e)=>{if(!k(t))return;let r=e?.context?.designSystem?.class;if(!r)return;let n;for(let o of t.split(" ")){if(!o)continue;let s=r[o];if(!v(s))continue;let i=lt(s);n=n?Wt(n,i):i}if(n)return se(n,e)},Y0=(t,e)=>{let r={};for(let n in t){let o=Hy[n.slice(0,1)];if(o){let s=o(n,t[n],e);if(s)for(let i in s)Object.prototype.hasOwnProperty.call(s,i)&&(r[i]&&typeof r[i]=="object"&&typeof s[i]=="object"?Wt(r[i],s[i]):r[i]=s[i])}}return r},se=(t,e,r={unpack:!0})=>{let[n,o]=K0(t,e,r),s=Y0(o,e),i=!1;for(let a in s){i=!0;break}if(i){if(r.unpack)return Ci(n,s);n._selectors=s}return n},m2=(t,e)=>{let r={};if(t.class)for(let n in t.class)r[n]=t.class[n](e);return r};D();var X0=t=>{if(v(t))return se(t,t)},y2=(t,e)=>{let r=X0(t);return typeof e=="function"?e(r):he(r)};D();D();function Ky(t,e,r){let n=t?.context?.analyze;if(!n||!n.emit||e==="warn"&&!n.shouldCapture("warnings")||e==="error"&&!n.shouldCapture("errors"))return;let o=r.map(s=>s?.message||(typeof s=="string"?s:null)).filter(Boolean).join(" ");n.emit({id:`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,6)}`,ts:Date.now(),type:e==="error"?"error":"warning",level:e,hook:e==="error"?"el.error":"el.warn",element:{key:t.key!=null?String(t.key):null,name:t.__name||null,tag:t.tag||null},message:o||null,args:r})}var Z0=new Set;function J0(t,e,r){let n=String(e);if(Z0.has(n))return;Z0.add(n);let o=t?.__ref?.path,s=Array.isArray(o)&&o.length?o.join("."):t?.key!=null?String(t.key):"(unknown element)",i=r!=null?`resolves to a non-function (${typeof r}) \u2014 it cannot be called`:"is not registered in context.methods, context.functions, or context.utils, and is not an element method",a=`[smbls] el.call('${n}') at <${s}>: "${n}" ${i}. Returning undefined (unchanged behavior) \u2014 check the name for typos or register the function on the project. Warned once per name; repeat misses are silent.`;Ky(t,"error",[a]),console.error(a)}var tk=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),b2=new Set,ek=t=>tk(Wy,t)&&!(Eo||b2).has(t),Q0=new Set;function rk(t,e){Q0.has(t)||(Q0.add(t),gt()&&console.warn(`[smbls] ${e}: context.methods.${t} is named like a built-in element method and is not the app's own override (it was not on the element prototype when it was built) \u2014 ignored; the built-in keeps winning. Declare an intentional override in the app's OWN methods.`))}function _2(...t){return Ky(this,"warn",t),la.apply(this,t)}function x2(...t){return Ky(this,"error",t),Pn.apply(this,t)}var Wy={update:_s,remove:ws,getDB:pa,getQuery:ha,getRootData:ia,getPath:ra,nextElement:fa,previousElement:ua,verbose:No,warn:_2,error:x2,variables:da,spotByPath:ea,set(t,e){let r=this.__ref;if(r){if(r.__setLocked){r.__setQueued={content:t,options:e};return}r.__setLocked=!0}try{if(this.removeContent(),t!=null){let n=this.context?.__create;n&&n(t,this,"content",e)}this.__ref&&(this.__ref.contentManaged=!0)}finally{if(r){r.__setLocked=!1;let n=r.__setQueued;n&&(r.__setQueued=null,this.set(n.content,n.options))}}},reset(t){let e=this.context?.__create;if(!e)return this;let r=this.parent,n=this.key,o=this.parse();return this.remove(),e(o,r,n,t)},lookup(t){let e=this.parent;for(;e;){if(typeof t=="function"){if(t(e))return e}else if(typeof t=="string"){if(e.key===t)return e;if(e[t]&&e[t].__ref)return e[t]}e=e.parent}return null},lookdown(t){let e=this.__ref;if(!e?.__children)return null;for(let r of e.__children){let n=this[r];if(!n)continue;if(typeof t=="function"){if(t(n))return n}else if(typeof t=="string"&&n.key===t)return n;let o=n.lookdown?.(t);if(o)return o}return null},lookdownAll(t,e=[]){let r=this.__ref;if(!r?.__children)return e;for(let n of r.__children){let o=this[n];o&&(typeof t=="function"?t(o)&&e.push(o):typeof t=="string"&&o.key===t&&e.push(o),o.lookdownAll?.(t,e))}return e},getRef(t){return t?this.__ref&&this.__ref[t]:this.__ref},getChildren(){let t=this.__ref&&this.__ref.__children;return Array.isArray(t)?t.map(e=>this[e]):[]},getRoot:sa,getRootState:oa,getRootContext:aa,getContext:ca,parse(t){let e={},r=t?new Set(t):null,n=this.__ref?.__exec;for(let o in this)if(!(o==="parent"||o==="node"||o==="__ref")&&!r?.has(o)){if(n&&n[o]!==void 0){e[o]=n[o];continue}typeof this[o]!="function"&&(e[o]=this[o])}return e},parseDeep(t){let e=this.parse(t),r=this.__ref;if(r?.__children)for(let n of r.__children)this[n]?.parseDeep&&(e[n]=this[n].parseDeep(t));return e},keys(){return Object.keys(this)},log(...t){if(t.length){let e={};for(let r of t)e[r]=this[r];console.log(e)}else console.log(this)},setProps(t,e){return this.update(t,e)},setNodeStyles(t){if(this.node?.style)for(let e in t){let r=t[e];if(r==null)continue;let n=e.replace(/[A-Z]/g,s=>"-"+s.toLowerCase()),o=String(r).replace(/\s*!important\s*$/,"");this.node.style.setProperty(n,o,"important")}},call(t,...e){let r=this.context,n=ek(t);n&&r?.methods?.[t]&&r.methods[t]!==this[t]&&rk(t,"el.call");let o=n?this[t]:r?.methods?.[t]||r?.functions?.[t]||r?.utils?.[t]||this[t];if(typeof o=="function"){let s=Cn;if(!s||!s(o))return o.call(this,...e);gt()&&J0(this,t,Le(o));return}gt()&&J0(this,t,o)},removeContent(){let t=this.__ref;if(!t?.__children)return;let e=this.content;if(e?.remove){e.remove(),delete this.content;let r=t.__children.indexOf("content");r!==-1&&t.__children.splice(r,1)}e?.node?.parentNode&&e.node.parentNode.removeChild(e.node)}},qy=new WeakMap;function w2(t){if(!t)return Wy;let e=qy.get(t);if(e)return e;e=Object.create(Wy);let r=t.methods;if(r)for(let n in r)e[n]=r[n];return qy.set(t,e),e}function Ss(t){let e=w2(t.context);Object.setPrototypeOf(t,e)}function Cu(t){if(!t)return!1;let e=qy.get(t);if(!e)return!1;let r=t.methods;if(!r)return!1;for(let n in r){if(ek(n)&&!tk(e,n)){rk(n,"refreshContextProto");continue}e[n]=r[n]}return!0}var Eu=[],Au=!1,on=0;function Tu(){return typeof performance<"u"&&typeof performance.now=="function"?performance.now():Date.now()}function nk(t){let e=typeof globalThis<"u"?globalThis.scheduler:null;if(e&&typeof e.yield=="function"){e.yield().then(t,t);return}if(typeof MessageChannel=="function"){let r=new MessageChannel;r.port1.onmessage=()=>{r.port1.close(),t()},r.port2.postMessage(0);return}setTimeout(t,0)}function Gy(){return on?Tu()-on>=50:!1}var ks=0;function Yy(){ks===0&&!on&&(on=Tu()),ks++}function Xy(){ks>0&&ks--,ks===0&&!Au&&(on=0)}function Zy(t){Eu.push(t),Au||(Au=!0,nk(ok))}function ok(){for(on=Tu();Eu.length;){let t=Eu.shift();try{t()}catch(e){typeof console<"u"&&console.error&&console.error("[smbls] deferred mount chunk failed:",e?.message||e)}if(Tu()-on>=50)break}if(Eu.length){nk(ok);return}Au=!1,on=0,ks=0}D();D();Tn();var rb={};$(rb,{STATE_METHODS:()=>sk,applyInitialState:()=>Ru,applyStateMethods:()=>me,callStateMethod:()=>pc,createState:()=>Qy,isTracking:()=>eb,useHostState:()=>tb});var sk=new Set(["update","parse","clean","destroy","create","add","toggle","remove","set","replace","setByPath","setPathCollection","removeByPath","removePathCollection","getByPath","reset","apply","applyReplace","applyFunction","quietUpdate","quietReplace","rootUpdate","parentUpdate","keys","values","__element","__children","parent","root"]),Ou=(t,e,r)=>{Object.defineProperty(t,e,{value:r,enumerable:!1,configurable:!0,writable:!0})},Be=(t,e,r,{onlyIfAbsent:n}={})=>{Ou(t,"$"+e,r),!(n&&Object.prototype.hasOwnProperty.call(t,e))&&Ou(t,e,r)},pc=(t,e,...r)=>{if(!t)return;let n=t["$"+e];if(typeof n=="function")return n.apply(t,r);let o=t[e];if(typeof o=="function")return o.apply(t,r)},me=(t,e)=>{if(kt(e)){let o=e.__raw||e;Be(o,"toggle",function(s,i={}){e[s]=!e[s]},{onlyIfAbsent:!0}),Be(o,"set",function(s,i={}){return e.$clean({preventStateUpdate:!0}),typeof s=="object"&&s!==null&&e.$update(s,i),e},{onlyIfAbsent:!0}),Be(o,"setByPath",function(s,i,a={}){let c=s.split("."),l=e;for(let f=0;f<c.length-1;f++)l[c[f]]===void 0&&(l[c[f]]={}),l=l[c[f]];return l[c[c.length-1]]=i,e}),Be(o,"getByPath",function(s){let i=s.split("."),a=e;for(let c=0;c<i.length;c++){if(a==null)return;a=a[i[c]]}return a}),Be(o,"removeByPath",function(s,i={}){let a=s.split("."),c=e;for(let l=0;l<a.length-1;l++){if(c==null)return e;c=c[a[l]]}return c&&delete c[a[a.length-1]],e}),Be(o,"reset",function(s={}){let i=e.$parse();return e.$set(i,s)}),Be(o,"apply",function(s,i={}){if(typeof s=="function"){let a=s(e);return e.$update(a,i)}}),Be(o,"applyFunction",function(s,i={}){if(typeof s=="function")return s(e),e.$update(e.$parse(),i)}),Be(o,"rootUpdate",function(s,i={}){let a=e;for(;a?.parent&&kt(a.parent);)a=a.parent;return pc(a,"update",s,i)}),Be(o,"parentUpdate",function(s,i={}){if(e.parent)return pc(e.parent,"update",s,i)}),Be(o,"quietReplace",function(s,i={}){return e.$replace(s,{quiet:!0,...i})}),Object.getOwnPropertyDescriptor(o,"root")||Object.defineProperty(o,"root",{get:function(){let s=e,i=kt(s)?s:null;for(let a=0;a<64&&s?.parent&&s.parent!==s;a++)s=s.parent,kt(s)&&(i=s);return i||s},enumerable:!1,configurable:!0});return}if(!e||typeof e!="object")return;let r=()=>{for(let o in e)Object.prototype.hasOwnProperty.call(e,o)&&delete e[o]},n={update(o){if(!o||typeof o!="object")return e;for(let s in o)e[s]=o[s];return e},apply(o){if(typeof o!="function")return e;let s=o(e);return s?e.$update(s):e},parse(){return{...e}},toggle(o){return e[o]=!e[o],e},set(o){if(!o||typeof o!="object")return e;r();for(let s in o)e[s]=o[s];return e},replace(o){return e.$set(o)},clean(){return r(),e}};for(let o in n)if(Ou(e,"$"+o,n[o]),typeof e[o]!="function"){if(Object.prototype.hasOwnProperty.call(e,o)){_l(o,"");continue}Ou(e,o,n[o])}};var Qy=function(t,e,r){return t.state=Ru(t,e,r),t.state},Ru=function(t,e,r){let{__ref:n}=t,o=t.state;if(o==null||o===!1){let s=e?.state||{};return me(t,s),s}if(typeof o=="string")return n&&(n.__state=o),n.__stateType="string",S2(o,t,e);if(typeof o=="number"||typeof o=="boolean"){n&&(n.__state=o,n.__stateType=typeof o,n.__hasRootState=!0);let s=fr({value:o});return s.__element=t,e?.state&&(s.parent=e.state),me(t,s),s}if(typeof o=="function"&&(o=o(t,e?.state)||{}),typeof o=="object"&&!kt(o)){n&&(n.__hasRootState=!0),o.isRootState&&n&&(n.__hasRootState=!0);let s=fr({...o});if(s.__element=t,!Object.getOwnPropertyDescriptor(s,"root")){let i=e?.state?.root||e?.state||s;Object.defineProperty(s,"root",{get:()=>i,enumerable:!1,configurable:!0})}return e?.state&&(s.parent=e.state,e.state.__children&&(e.state.__children[t.key]=s)),me(t,s),typeof t.onStateCreated=="function"&&t.onStateCreated(t,s,t.context,r),s}return kt(o)?(o.__element=t,o):e?.state||{}};function Jy(t,e){if(!e)return t;let r=e.split("/"),n=t;for(let o of r){if(n==null)return{};n=n[o]}return n??{}}function S2(t,e,r){if(!r?.state)return{};if(t===".")return r.state;if(t.startsWith("../")){let o=t.slice(3),s=r.state?.parent;return o&&s?Jy(s,o):s??r.state??{}}if(t.startsWith("~/")){let o=r.state;for(;o?.parent;)o=o.parent;let s=t.slice(2);return s?Jy(o,s):o??{}}let n=Jy(r.state,t);if(n&&typeof n=="object"&&!kt(n)&&!Object.getOwnPropertyDescriptor(n,"root")){let o=r.state?.root||r.state;Object.defineProperty(n,"root",{get:()=>o,enumerable:!1,configurable:!0})}return n}var tb=(t,e)=>{if(!t)return ak;let r=v2(t,e);return!r||!r.state?ak:E2(r.state)},eb=()=>lr()!=null,k2=128;function v2(t,e){let r=typeof e=="function"?e:typeof e=="string"?s=>!!s?.[e]:s=>!!s?.state,n=t,o=null;for(let s=0;s<k2&&n;s++){if(r(n)&&n.state)return n;if(n.state&&!o&&(o=n),!n.parent||n.parent===n)break;n=n.parent}return o}var C2={get(t,e){return t[e]}},ik=new WeakMap,E2=t=>{let e=ik.get(t);return e||(e=new Proxy(t,C2),ik.set(t,e)),e},ak=new Proxy(Object.create(null),{get(){},has(){return!1}});var Pu="3.14.798";var ck="__SMBLS_ELEMENT_ID_ENGINE__",lk=(t,e,r)=>{let n=e||Pu,o=r||(typeof globalThis<"u"?globalThis:null);if(!o)return t;let s=o[ck];return s&&s.engine&&s.version===n?s.engine:(s||(o[ck]={version:n,engine:t}),t)};var K=(t,e)=>e.split(" ").map(r=>t+"-"+r),nb="top right bottom left",ob=nb+" block block-start block-end inline inline-start inline-end",sn="start end",to="width style color",Du=t=>K(t,ob),A2=(()=>{let t=K("border","width style color image");for(let e of ob.split(" "))t.push("border-"+e,...K("border-"+e,to));return t})(),fk=t=>[...K("border-"+t,to+" start end"),...K("border-"+t+"-start",to),...K("border-"+t+"-end",to)],Cr={animation:K("animation","name duration timing-function delay iteration-count direction fill-mode play-state timeline range range-start range-end"),background:K("background","image position position-x position-y size repeat origin clip attachment color"),border:A2};for(let t of["width","style","color"])Cr["border-"+t]=ob.split(" ").map(e=>"border-"+e+"-"+t);for(let t of nb.split(" "))Cr["border-"+t]=K("border-"+t,to);Cr["border-block"]=fk("block");Cr["border-inline"]=fk("inline");Object.assign(Cr,{"border-image":K("border-image","source slice width outset repeat"),"border-radius":"top-left top-right bottom-right bottom-left start-start start-end end-start end-end".split(" ").map(t=>"border-"+t+"-radius"),columns:K("column","width count"),"column-rule":K("column-rule",to),container:K("container","name type"),"contain-intrinsic-size":K("contain-intrinsic","width height"),flex:K("flex","grow shrink basis"),"flex-flow":K("flex","direction wrap"),font:[...K("font","style variant weight stretch size"),"line-height",...K("font","family size-adjust kerning feature-settings variation-settings optical-sizing")],gap:["row-gap","column-gap"],grid:K("grid","template template-rows template-columns template-areas auto-rows auto-columns auto-flow"),"grid-template":K("grid-template","rows columns areas"),"grid-area":K("grid","row column row-start row-end column-start column-end"),"grid-row":K("grid-row",sn),"grid-column":K("grid-column",sn),inset:[...nb.split(" "),...K("inset","block block-start block-end inline inline-start inline-end")],"inset-block":K("inset-block",sn),"inset-inline":K("inset-inline",sn),"list-style":K("list-style","type position image"),margin:Du("margin"),"margin-block":K("margin-block",sn),"margin-inline":K("margin-inline",sn),mask:K("mask","image mode repeat position clip origin size composite"),offset:K("offset","position path distance rotate anchor"),outline:K("outline",to),overflow:K("overflow","x y"),"overscroll-behavior":K("overscroll-behavior","x y"),padding:Du("padding"),"padding-block":K("padding-block",sn),"padding-inline":K("padding-inline",sn)});for(let t of["content","items","self"])Cr["place-"+t]=["align-"+t,"justify-"+t];Object.assign(Cr,{"scroll-margin":Du("scroll-margin"),"scroll-padding":Du("scroll-padding"),"text-decoration":K("text-decoration","line style color thickness"),"text-emphasis":K("text-emphasis","style color"),transition:K("transition","property duration timing-function delay behavior")});var hc={};for(let t in Cr)for(let e of Cr[t])(hc[e]||(hc[e]=[])).push(t);var T2=new Set(["rows","cols","wrap"]),Lu=(t,e)=>T2.has(e)&&Te(t,e),vs=(t,e)=>!!(wt[e]||Et&&Et.has(e))&&!Lu(t,e);var Tk=lk({uniqId:1,scopedStyleId:0},Pu),mc=[],eo=new Set,mb=!1,Ok=0,Es=null,Sc=null;function As(){return typeof Date<"u"&&typeof Date.now=="function"?Date.now():0}function Rk(){return typeof document<"u"&&document.visibilityState==="hidden"}var O2=250,R2=1e3;function P2(){return Sc&&(Sc!==(typeof requestAnimationFrame=="function"?requestAnimationFrame:null)||Rk())?!0:As()-Ok>=R2}function D2(){if(mb=!0,Ok=As(),Sc=null,typeof requestAnimationFrame!="function"){let t=typeof clearTimeout=="function"?clearTimeout:null,e=setTimeout(bc,0);Es=t?()=>t(e):null;return}if(Rk()){let t=typeof clearTimeout=="function"?clearTimeout:null,e=setTimeout(bc,O2);Es=t?()=>t(e):null}else{let t=typeof cancelAnimationFrame=="function"?cancelAnimationFrame:null;Sc=requestAnimationFrame;let e=requestAnimationFrame(bc);Es=t?()=>t(e):null}}function Vu(){if(mb){if(!P2())return;let t=Es;if(Es=null,t)try{t()}catch{}}D2()}var Pk=300,Dk=15e4;function bc(){if(mb=!1,Es=null,Sc=null,eo.size&&uD(),!mc.length)return;let t=mc.splice(0,mc.length);for(let e=0;e<t.length;e++){let r=t[e];if(r.node){if(!r.node.isConnected){let n=r.__ref||(r.__ref={});n.__mountAttempts=(n.__mountAttempts||0)+1,n.__mountFirstAttemptAt==null&&(n.__mountFirstAttemptAt=As());let o=As()-n.__mountFirstAttemptAt;n.__mountAttempts<=Pk&&o<Dk?(mc.push(r),Vu()):console.warn("[DOMQL] onMounted dropped after",n.__mountAttempts,"attempts /",o,"ms \u2014 node never connected:",r.key||r.tag||r);continue}ie("Mounted",r,r.__ref?.__mountOptions||{})}}}function cb(t,e){let r=t.__ref?.__autoGrow;r&&r.active&&vc(t,!0),typeof t.onMounted=="function"&&(t.__ref.__mountOptions=e,mc.push(t),Vu())}function uk(t,e){if(typeof t.onContentUpdate!="function")return;t.context?.plugins?.length&&Ot("contentUpdate",t,e);let r=t.context?.designSystem;r&&ct(r);try{t.onContentUpdate(t,t.state,t.context,e)}catch(n){if(t.context?.plugins?.length&&Ot("error",t,{hook:"onContentUpdate",error:n})||console.error('[DOMQL] Lifecycle "onContentUpdate" error:',n),t.context?.strictMode)throw n}finally{r&&it()}}function Er(t){return t.length>2&&t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)>=65&&t.charCodeAt(2)<=90}function L2(t){return t.charAt(2).toLowerCase()+t.slice(3)}function I2(t){return t.toLowerCase()}function lb(t){let e=t.charCodeAt(0);return e===58||e===64||e===38||e===91}function yc(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=yc(o,s):r[n]=s}return r}function Fu(t){if(typeof t=="string")return t||void 0;if(typeof t=="number"||typeof t=="bigint")return String(t)}function Lk(t,e,r){return Fu(t)||(e&&typeof e=="object"?Fu(e.key):void 0)||String(r)}function ne(t,e,r,n={},o){let s=lr();if(s){Ke(null);try{return ne(t,e,r,n,o)}finally{Ke(s)}}if(t==null||t===!1)return null;let i=q2(t);(typeof t=="string"||typeof t=="number")&&(t={text:t}),r=Fu(r);let a=Fu(t.key),c=Object.create(null);c.key=r||a||`_${Tk.uniqId++}`,c.parent=e||null,c.context=t.context||e?.context||n.context||{},c.context.__create||(c.context.__create=ne);let l=c.__ref={__if:!0,__children:[],__exec:{},__effects:[],__eventCleanup:[],root:e?.__ref?.root||c,path:e?.__ref?.path?[...e.__ref.path,c.key]:[c.key],origin:t};i&&(l.__runtimeSource=i);let f=t;if(t=Ik(c,t,r,a,e,n),c.if!=null){let d;if(typeof c.if=="function")try{d=c.if(c,c.state,c.context)}catch(g){if(d=!1,l.__ifError=g,typeof console<"u"&&console.warn){let p=c.key||c.tag||"?";console.warn(`[smbls] \`if:\` evaluator threw on ${p} \u2014 treating as false:`,g?.message||g)}}else d=c.if;l.__if=!!d}if(l.__if)typeof c.if=="function"&&(l.__ifInitialized=!0);else{e&&(e[c.key]=c);let d=F2(t,r,c.context?.components);return d.length&&(l.__ifLateMerge={definition:f,key:r,ownKey:a,names:d,options:n}),typeof c.if=="function"&&Nk(c,l,c.if),c}c.tag||(c.tag=tn(c)),ie("Init",c,n);let u=c.node=en(c);if(!u)return c;if(c.tag==="fragment"){let g=(c.context?.document||globalThis.document).createComment("");u.appendChild(g),l.__fragmentAnchor=g}ie("AttachNode",c,n),u.setAttribute&&c.key&&u.setAttribute("data-key",c.key),e&&(e[c.key]=c,e.__ref?.__children&&(e.__ref.__children.includes(c.key)||e.__ref.__children.push(c.key))),u.setAttribute&&c.context?.scopeSelector&&c.context.scopeSelector!==":root"&&c.context.key&&c.key===c.context.key&&u.setAttribute("data-smbls-app",c.context.key),c.id&&u.setAttribute&&(u.id=c.id),Gk(c,n),Fk(c),db(c),Wk(c),qk(c),gD(c);try{Yk(c,n)}catch(d){if(typeof console<"u"&&console.error){let g=c.__ref?.path?.join(".")||c.key||"<root>";console.error(`[smbls] createChildren failed at ${g}:`,d?.message||d,d?.stack?`
54
+ `+d.stack.split(`
55
55
  `).slice(0,6).join(`
56
- `):"")}}if(Nu(c,!0),Bk(c,e,o),typeof c.html=="function"&&c.node&&!c.node.innerHTML){let y=c.context?.designSystem;y&&ct(y);try{let b=c.html(c,c.state,c.context);b!=null&&typeof b!="function"&&(c.node.innerHTML=b)}catch{}finally{y&&it()}}if(ie("Create",c,n),ie("Complete",c,n),ie("Render",c,n),ie("RenderRouter",c,n),nb(c,n),typeof c.onFrame=="function"){let y=c.onFrame,b=c.context?.designSystem,w=()=>{if(c.node){if(c.node.isConnected){b&&ct(b);try{y(c,c.state,c.context)}catch(S){console.error("[DOMQL] onFrame error:",S)}finally{b&&it()}}requestAnimationFrame(w)}};requestAnimationFrame(w)}return c}function k2(t,e,r){let n=!e,o=r.state&&typeof r.state=="object"&&!Array.isArray(r.state)&&Object.keys(r.state).length===0,s=n&&o&&t.context?.state,i=r.state!==void 0&&!s?r.state:t.state&&!kt(t.state)?t.state:void 0;if(i==null){if(e?.state)t.state=e.state,me(t,t.state);else if(t.context?.state){let a=t.context.state,c={...a},l=t.context?.polyglot;if(l?.translations){let f=t.context,u=a.lang||l.defaultLang||"en",d=new Set,g=(m,_)=>{d.has(m)||Pn(f,m,c)&&(c[m]=_,d.add(m),Ze(f,m,_))},p=l.translations[u];if(p&&typeof p=="object")for(let m in p)g(m,p[m]);let h=new Set(l.languages||[]);for(let m in l.translations)h.has(m)||g(m,l.translations[m])}t.state=kt(c)?c:lr(c),t.state.__element=t,t.state.root=t.state,me(t,t.state),Mo?.(a,t.state)}else t.state={},Object.defineProperty(t.state,"root",{value:t.state,enumerable:!1,configurable:!0,writable:!0}),me(t,t.state);return}if(typeof i=="string"){if(t.state=Ck(i,e),t.state&&typeof t.state=="object"&&!kt(t.state)){let a=e?.state?.root||e?.state||t.state;Object.defineProperty(t.state,"root",{value:a,enumerable:!1,configurable:!0,writable:!0})}me(t,t.state);return}if(typeof i=="function"){let a=i(t,e?.state);t.state=kt(a)?a:lr(a||{})}else kt(i)?t.state=i:t.state=lr({...i});t.state.__element=t,e?.state?(t.state.parent=e.state,t.state.root=e.state.root||e.state):t.state.root=t.state,me(t,t.state),Mo?.(i,t.state)}function tb(t,e){if(!e)return t;let r=e.split("/"),n=t;for(let o of r){if(n==null)return{};n=n[o]}return n??{}}function Ck(t,e){if(!e)return{};if(t===".")return e.state||{};if(t.startsWith("../")){let o=t.slice(3);return o?tb(e.state,o):e.state??{}}if(t.startsWith("~/")){let o=e.state?.root||e.state,s=t.slice(2);return s?tb(o,s):o??{}}if(e.state?.[t]!==void 0)return e.state[t];let r=tb(e.state,t);if(r!=null&&Object.keys(r).length>0)return r;let n=e.context?.polyglot;if(n?.translations){let o=e.state?.root?.lang||n.defaultLang||"en",s=n.translations[o];if(s?.[t]!==void 0)return s[t];if(n.translations[t]!==void 0)return n.translations[t]}return{}}var v2=new Set(["s","state","ctx","context"]);function C2(t){try{let r=(typeof Le=="function"?Le(t):Function.prototype.toString.call(t)).match(/^[^(]*\(([^)]*)\)/);return r?r[1].split(",").map(n=>n.trim().split("=")[0].trim()).filter(Boolean):[]}catch{return[]}}function E2(t){if(typeof t!="function"||t.length!==2)return!1;let e=C2(t);if(e.length<2)return!1;let r=e[1].replace(/[{}[\]]/g,"").trim();return r.length>0&&!v2.has(r)}function A2(t){let e=t.__ref,r=t.tag||"div",n=t.context?.designSystem,o=[],s=Object.keys(t);for(let i=0;i<s.length;i++){let a=s[i];if(typeof t[a]!="function"||Nt.has(a))continue;let c=a.charCodeAt(0);c>=65&&c<=90||Cr(a)||xt[a]||Et&&Et.has(a)||Te(r,a)||(gt()&&E2(t[a])&&console.warn(`[smbls] custom prop "${a}"${t.key?` on key "${t.key}"`:""} is a function \u2014 it will be auto-invoked on read and its RETURN VALUE stored, not preserved as a callable reference. If you meant to stash a callback, use el.call('${a}', \u2026) instead of reading el.${a}(\u2026) directly (see RULES.md Rule 8).`),o.push({prop:a,fn:t[a]}))}for(let i=0;i<o.length;i++){let{prop:a,fn:c}=o[i];e.__exec[a]=c,Object.defineProperty(t,a,{get(){n&&ct(n);try{return c(t,t.state,t.context)}catch{return}finally{n&&it()}},set(l){delete e.__exec[a],Object.defineProperty(t,a,{value:l,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}}function T2(t,e){if(!(!Array.isArray(e)||e.length===0))for(let r=0;r<e.length;r++){let n=e[r];try{typeof n=="function"?n(t,t.state,t.context):typeof n=="string"&&t.state?.[n]}catch{}}}function jt(t,e,r){return!Array.isArray(e)||e.length===0?r:function(...n){return T2(t,e),r.apply(this,n)}}function pc(t,e){if(!(!t||Array.isArray(t)||typeof t!="object"))return t[e]}function ft(t,e){return()=>t.path.join(".")+"::"+e}var nk=new Set;function Gt(t,e,r){if(!gt())return;let n=ft(t,e)();nk.has(n)||(nk.add(n),console.warn(`[smbls] "${e}" effect threw on ${t.path.join(".")} \u2014 keeping previous value:`,r?.message||r))}var ok=/(['"`])((?:\\.|(?!\1)[^\\])*)\1/g,O2=(t,e)=>{let r;try{r=String(t)}catch{return}if(!r.includes("{{"))return;ok.lastIndex=0;let n;for(;(n=ok.exec(r))!==null;)n[2].includes("{{")&&e.add(n[2])},R2=(t,e)=>!Cr(t)&&!ks(e,t),sk=(t,e,r,n,o)=>{if(typeof e=="string"){!o&&e.includes("{{")&&r.add(e);return}typeof e=="function"&&R2(t,n)&&O2(e,r)},sb=new WeakMap,xc=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),yc=t=>{if(typeof t=="string"||typeof t=="number")return{text:t};if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t.props;return e&&typeof e=="object"&&!Array.isArray(e)?no(t,e):t},bc=(t,e)=>t&&e?no(t,e):t||e||null,Ek=(t,e)=>{let r=t.__ref&&t.__ref.__runtimeSource;return!!r&&xc(r,e)},vs=(t,e)=>Ek(t,e)?yc(t.__ref.__runtimeSource[e]):null,_c=(t,e)=>(e&&t&&typeof t=="object"&&sb.set(t,e),t),P2=t=>{if(!t||typeof t!="object")return;let e=sb.get(t);return e&&sb.delete(t),e},ib=(t,e,r)=>{if(typeof t=="string"){t.includes("{{")&&e.add(t);return}if(!(!t||typeof t!="object"||r.has(t))){if(r.add(t),Array.isArray(t)){for(let n=0;n<t.length;n++)ib(t[n],e,r);return}if(!t.__ref)for(let n of Object.keys(t)){if(n==="state")continue;let o=Object.getOwnPropertyDescriptor(t,n);o&&"value"in o&&ib(o.value,e,r)}}},D2=(t,e)=>{let r=null;for(let n of Object.keys(t)){if(Nt.has(n)||e&&xc(e,n))continue;let o=Object.getOwnPropertyDescriptor(t,n),s=o&&o.value;if(!Array.isArray(s))continue;let i=new Set;ib(s,i,new Set),i.size&&(r||(r=new Map),r.set(s,i))}return r},ik=(t,e)=>{if(Array.isArray(e))for(let r=t;r;r=r.parent){let n=r.__ref&&r.__ref.__declaredArrays,o=n&&n.get(e);if(!o)continue;let s=t.__ref;s.__authoredTemplates||(s.__authoredTemplates=new Set);for(let i of o)s.__authoredTemplates.add(i);return}},L2=["attr","aria","data","metadata"],I2=t=>{if(L2.includes(t))return!0;let e=t.charCodeAt(0);return e===46||e===33||e===64},$2=(t,e)=>{let r=new Set,n=t.tag||"div";for(let o of Object.keys(t)){let s=Object.getOwnPropertyDescriptor(t,o),i=s&&s.value,a=!!e&&xc(e,o);if(i&&typeof i=="object"&&!Array.isArray(i)){if(!I2(o))continue;let c=a?e[o]:null,l=c&&typeof c=="object"?c:null;for(let f in i){let u=a&&(!l||xc(l,f));sk(f,i[f],r,n,u)}continue}sk(o,i,r,n,a)}return r};function Ak(t,e){let r=t.__ref,n=!!(e&&e.skipIfEffect),o=$2(t,r.__runtimeSource);if(r.__authoredTemplates)for(let c of o)r.__authoredTemplates.add(c);else r.__authoredTemplates=o;if(A2(t),typeof t.text=="function"){let c=t.text,l=jt(t,t.textDeps,c),f=Y(()=>{if(!r.contentManaged)try{let u=l(t,t.state,t.context);t.node&&u!=null&&typeof u!="function"&&typeof u!="object"&&(typeof u=="string"&&u.includes("{{")&&(u=Ft.call(t,u,t.state)),_s(t,u))}catch(u){Gt(r,"text",u)}},{depth:r.path.length,label:ft(r,"text")});r.__effects.push(f),r.__exec.text=c}else if(typeof t.text=="string"&&t.text.includes("{{")){let c=t.text,l=Y(()=>{if(r.contentManaged)return;let f=Ft.call(t,c,t.state);f!=null&&(t.text=f),t.node&&_s(t,f??"")},{depth:r.path.length,label:ft(r,"text")});r.__effects.push(l),r.__exec.text=c}let s=t.tag||"div";for(let c of Object.keys(t))if(typeof t[c]=="function"&&!Nt.has(c)&&!Cr(c)&&!r.__exec[c]&&!Pu(s,c)){if(xt[c]){let l=t[c],f=jt(t,t[c+"Deps"],l),u=c,d,g=null,p=null,h,m=Y(()=>{let _=t.context?.designSystem;_&&ct(_);try{let x=f(t,t.state,t.context);_u();let y;try{y=xt[u](x,t,t.state,t.context)}finally{wu()}if(Array.isArray(y)){let w={};for(let S of y)if(S)for(let C in S)w[C]=S[C];y=w}let b=u==="show"||u==="hide";if(y&&t.node&&M2(y)){let w=Iu(y);if(w===null||w!==h){h=w;let S=he(y,null,t.context?.cssPrefix),C=S?S.split(" ").filter(Boolean):null;if(t.node.classList){if(p)for(let O of p)t.node.classList.remove(O);if(C&&C.length)for(let O of C)t.node.classList.add(O);p=C}}d=void 0,g=null}else if(y&&t.node){if(p){for(let S of p)t.node.classList.remove(S);p=null,h=void 0}let w=Iu(y);if(w===null||w!==d||!Lu(t.node,g)){d=w;let S=lk(t,y);g=Du(t.node,S)}}else t.node&&b&&(d=void 0,g=null,t.node.style.display="")}finally{_&&it()}},{depth:r.path.length,label:ft(r,u)});r.__effects.push(m),r.__exec[c]=l}else if(Et&&Et.has(c)){let l=t[c],f=jt(t,t[c+"Deps"],l),u=c,d,g=null,p=Y(()=>{let h=t.context?.designSystem;h&&ct(h);try{let m=f(t,t.state,t.context);if(t.node)if(m!=null){let _=u+":"+String(m);if(_!==d||!Lu(t.node,g)){d=_;let x={[u]:m},y=lk(t,x);g=Du(t.node,y)}}else d=void 0,g=null,t.node.style[u]=""}finally{h&&it()}},{depth:r.path.length,label:ft(r,u)});r.__effects.push(p),r.__exec[c]=l}}if(typeof t.html=="function"){let c=t.html,l=jt(t,t.htmlDeps,c),f=Y(()=>{let u=t.context?.designSystem;u&&ct(u);try{let d=l(t,t.state,t.context);t.node&&d!=null&&typeof d!="function"&&(t.node.innerHTML=d)}finally{u&&it()}},{depth:r.path.length,label:ft(r,"html")});r.__effects.push(f),r.__exec.html=c}if(typeof t.value=="function"){let c=t.value,l=jt(t,t.valueDeps,c),f=Y(()=>{try{let u=l(t,t.state,t.context);typeof u=="string"&&u.includes("{{")&&(u=Ft.call(t,u,t.state)),ck(t,u)}catch(u){Gt(r,"value",u)}},{depth:r.path.length,label:ft(r,"value")});r.__effects.push(f),r.__exec.value=c}else if(typeof t.value=="string"&&t.value.includes("{{")){let c=t.value,l=Y(()=>{try{ck(t,Ft.call(t,c,t.state))}catch(f){Gt(r,"value",f)}},{depth:r.path.length,label:ft(r,"value")});r.__effects.push(l),r.__exec.value=c}if(typeof t.style=="function"){let c=t.style,l=jt(t,t.styleDeps,c),f,u=null,d=Y(()=>{let g=l(t,t.state,t.context),p=Iu(g);(p===null||p!==f||!Lu(t.node,u))&&(f=p,F2(t.node,u,g),ro(t.node,g),u=Du(t.node,g))},{depth:r.path.length,label:ft(r,"style")});r.__effects.push(d),r.__exec.style=c}else if(t.style&&typeof t.style=="object")for(let c in t.style){let l=t.style[c];if(typeof l!="function")continue;let f=jt(t,pc(t.styleDeps,c),l),u,d=null,g=Y(()=>{try{let p=f(t,t.state,t.context);if(t.node){let h=c+":"+String(p);if(h!==u||!Lu(t.node,d)){u=h;let m={[c]:p};ro(t.node,m),d=Du(t.node,m)}}}catch(p){Gt(r,"style."+c,p)}},{depth:r.path.length,label:ft(r,"style."+c)});r.__effects.push(g)}if(t.attr&&typeof t.attr=="object"){for(let c in t.attr)if(typeof t.attr[c]=="function"){let l=jt(t,pc(t.attrDeps,c),t.attr[c]),f=c,u=Y(()=>{try{let d=l(t,t.state,t.context);typeof d=="string"&&d.includes("{{")&&(d=Ft.call(t,d,t.state)),t.node?.setAttribute&&(d==null||d===!1&&!sr(f)?t.node.removeAttribute(f):typeof d!="function"&&typeof d!="object"&&t.node.setAttribute(f,re(f,d)))}catch(d){Gt(r,"attr."+f,d)}},{depth:r.path.length,label:ft(r,"attr."+f)});u._attrName=f.toLowerCase(),r.__effects.push(u)}else if(typeof t.attr[c]=="string"&&t.attr[c].includes("{{")){let l=t.attr[c],f=c,u=Y(()=>{try{let d=Ft.call(t,l,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(f,re(f,d??""))}catch(d){Gt(r,"attr."+f,d)}},{depth:r.path.length,label:ft(r,"attr."+f)});u._attrName=f.toLowerCase(),r.__effects.push(u)}}if(t.aria&&typeof t.aria=="object")for(let c in t.aria){let l=t.aria[c];if(typeof l=="string"&&l.includes("{{")){let g=l,p="aria-"+c.replace(/[A-Z]/g,m=>"-"+m.toLowerCase()),h=Y(()=>{try{let m=Ft.call(t,g,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(p,re(p,m??""))}catch(m){Gt(r,"aria."+c,m)}},{depth:r.path.length,label:ft(r,"aria."+c)});h._attrName=p,r.__effects.push(h);continue}if(typeof l!="function")continue;let f=jt(t,pc(t.ariaDeps,c),t.aria[c]),u="aria-"+c.replace(/[A-Z]/g,g=>"-"+g.toLowerCase()),d=Y(()=>{try{let g=f(t,t.state,t.context);if(!t.node?.setAttribute)return;g==null?t.node.removeAttribute(u):typeof g!="function"&&typeof g!="object"&&t.node.setAttribute(u,re(u,g))}catch(g){Gt(r,"aria."+c,g)}},{depth:r.path.length,label:ft(r,"aria."+c)});d._attrName=u,r.__effects.push(d)}if(t.data&&typeof t.data=="object")for(let c in t.data){let l=t.data[c];if(typeof l=="string"&&l.includes("{{")){let p=l,h="data-"+c.replace(/[A-Z]/g,_=>"-"+_.toLowerCase()),m=Y(()=>{try{let _=Ft.call(t,p,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(h,_??"")}catch(_){Gt(r,"data."+c,_)}},{depth:r.path.length,label:ft(r,"data."+c)});m._attrName=h,r.__effects.push(m);continue}if(typeof l!="function")continue;let f=jt(t,pc(t.dataDeps,c),t.data[c]),d="data-"+c.replace(/[A-Z]/g,p=>"-"+p.toLowerCase()),g=Y(()=>{try{let p=f(t,t.state,t.context);if(!t.node?.setAttribute)return;p==null||p===!1?t.node.removeAttribute(d):typeof p!="function"&&typeof p!="object"&&t.node.setAttribute(d,p===!0?"":p)}catch(p){Gt(r,"data."+c,p)}},{depth:r.path.length,label:ft(r,"data."+c)});g._attrName=d,r.__effects.push(g)}let i=t.classlist&&typeof t.classlist=="object"&&!Array.isArray(t.classlist)?t.classlist:t.class&&typeof t.class=="object"&&!Array.isArray(t.class)?t.class:null;if(i)for(let c in i){if(typeof i[c]!="function")continue;let l=jt(t,pc(t.classDeps,c),i[c]),f=Y(()=>{try{let u=l(t,t.state,t.context);if(!t.node?.classList)return;typeof u=="string"?t.node.classList.add(u):u?t.node.classList.add(c):t.node.classList.remove(c)}catch(u){Gt(r,"class."+c,u)}},{depth:r.path.length,label:ft(r,"class."+c)});r.__effects.push(f)}!n&&typeof t.if=="function"&&Tk(t,r,t.if);for(let c of Object.keys(t)){if(Nt.has(c)||typeof t[c]!="function")continue;let l=c.charCodeAt(0);if(l>=65&&l<=90||Cr(c))continue;let f=t[c];r.__exec[c]=f;let u=t.tag||"div";if(Te(u,c)&&!ks(u,c)){let d=or(c)||c,g=jt(t,t[c+"Deps"],f),p=Y(()=>{try{let h=g(t,t.state,t.context);typeof h=="string"&&h.includes("{{")&&(h=Ft.call(t,h,t.state)),t.node?.setAttribute&&(h==null||h===!1&&!sr(d)?t.node.removeAttribute(d):typeof h!="function"&&typeof h!="object"&&(d==="src"&&"src"in t.node?t.node.src=h:t.node.setAttribute(d,re(d,h))))}catch(h){Gt(r,c,h)}},{depth:r.path.length,label:ft(r,c)});p._attrName=d.toLowerCase(),r.__effects.push(p)}}let a=t.tag||"div";for(let c of Object.keys(t)){if(Nt.has(c))continue;let l=t[c];if(typeof l!="string"||!l.includes("{{"))continue;let f=c.charCodeAt(0);if(f>=65&&f<=90||Cr(c)||ks(a,c)||Qn[c]||!Te(a,c))continue;let u=or(c)||c,d=Y(()=>{try{let g=Ft.call(t,l,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(u,re(u,g??""))}catch(g){Gt(r,c,g)}},{depth:r.path.length,label:ft(r,c)});d._attrName=u.toLowerCase(),r.__effects.push(d)}if(z2(t),K2(t),typeof t.onStateUpdate=="function"&&Array.isArray(t.stateDeps)){let c=t.onStateUpdate,l=t.stateDeps,f=!1,u=[],d=Y(()=>{let g=[];for(let _=0;_<l.length;_++){let x=l[_];try{g[_]=typeof x=="function"?x(t,t.state,t.context):t.state?.[x]}catch{g[_]=void 0}}if(!f){f=!0,u=g;return}let p=g.length!==u.length;for(let _=0;!p&&_<g.length;_++)g[_]!==u[_]&&(p=!0);let h=u;if(u=g,!p)return;let m=t.context?.designSystem;m&&ct(m);try{c(t,t.state,t.context,{prev:h,next:g})}catch(_){if(t.context?.plugins?.length&&Ot("error",t,{hook:"onStateUpdate",error:_})||console.error('[DOMQL] Lifecycle "onStateUpdate" error:',_),t.context?.strictMode)throw _}finally{m&&it()}},{depth:r.path.length,label:ft(r,"onStateUpdate")});r.__effects.push(d)}q2(t)}function ak(t){let e=t.parent,r=e?.node;if(!r||!t.node){Bk(t,t.parent);return}let n=null,o=Object.keys(e),s=o.indexOf(t.key);for(let i=s+1;i<o.length;i++){let a=e[o[i]];if(a?.node?.parentNode===r){n=a.node;break}}n?r.insertBefore(t.node,n):r.appendChild(t.node)}function Tk(t,e,r){let n=jt(t,t.ifDeps,r),o=Y(()=>{let s;try{s=n(t,t.state,t.context)}catch(a){if(s=!1,e.__ifError=a,typeof console<"u"&&console.warn){let c=t.key||t.tag||"?";console.warn(`[smbls] \`if:\` reactive effect threw on ${c} \u2014 treating as false:`,a?.message||a)}return}let i=e.__if;if(e.__if=!!s,i&&!e.__if&&t.node){t.node.remove();try{typeof t.onRemove=="function"&&t.onRemove(t)}catch(a){console.error("[smbls] onRemove error:",a)}}else if(!i&&e.__if)if(e.__ifInitialized)t.node||(t.node=rn(t)),t.node&&(t.node.ref=t),ak(t),ab(t),ie("Render",t,{}),nb(t,{});else{if(e.__ifInitialized=!0,t.tag||(t.tag=en(t)),ie("Init",t,{}),t.node||(t.node=rn(t)),!t.node)return;if(t.parent?.__ref?.__children&&!t.parent.__ref.__children.includes(t.key)&&t.parent.__ref.__children.push(t.key),t.tag==="fragment"&&!e.__fragmentAnchor){let c=(t.context?.document||globalThis.document).createComment("");t.node.appendChild(c),e.__fragmentAnchor=c}ie("AttachNode",t,{}),t.node.setAttribute&&t.key&&t.node.setAttribute("data-key",t.key),t.id&&t.node.setAttribute&&(t.node.id=t.id),Nk(t,{}),Ak(t,{skipIfEffect:!0}),ab(t),$k(t),Mk(t),jk(t,{}),ak(t),ie("Create",t,{}),ie("Complete",t,{}),ie("Render",t,{}),ie("RenderRouter",t,{}),nb(t,{})}},{depth:e.path.length,label:ft(e,"if")});e.__effects.push(o)}function _s(t,e){let r=t.node;if(!r)return;let n=e==null||typeof e=="object"?"":String(e);if(t.tag==="string"){r.nodeValue!==n&&(r.nodeValue=n);return}let o=t.__ref,s=o?o.__textNode:null;if(s&&s.parentNode!==r&&(s=null),!s){let i=r.firstChild;i&&i.nodeType===3&&(s=i)}s?s.nodeValue!==n&&(s.nodeValue=n):r.firstChild?(s=(r.ownerDocument||t.context?.document||globalThis.document).createTextNode(n),r.insertBefore(s,r.firstChild)):(r.textContent=n,s=r.firstChild&&r.firstChild.nodeType===3?r.firstChild:null),o&&(o.__textNode=s||null)}function ck(t,e){let r=t.node;if(!r||!("value"in r))return;let n=e==null?"":String(e);if(r.value===n)return;let o=typeof document<"u"&&document.activeElement===r,s=o&&typeof r.selectionStart=="number"?r.selectionStart:null,i=o&&typeof r.selectionEnd=="number"?r.selectionEnd:null;if(r.value=n,o&&s!=null&&i!=null)try{r.setSelectionRange(s,i)}catch{}let a=t.__ref&&t.__ref.__autoGrow;a&&a.active&&a.resize()}function ab(t){let{node:e}=t;if(e){if((typeof t.text=="string"&&!t.text.includes("{{")||typeof t.text=="number")&&_s(t,t.text),Ik(t),typeof t.html=="string"&&(e.innerHTML=t.html),t.value!=null&&typeof t.value!="function"&&!(typeof t.value=="string"&&t.value.includes("{{"))&&"value"in e){let r=String(t.value);e.value!==r&&(e.value=r)}if(t.style&&typeof t.style=="object"){let r=t.style;for(let n in t.style)if(typeof t.style[n]=="function"){r={};for(let o in t.style)typeof t.style[o]!="function"&&(r[o]=t.style[o]);break}ro(e,r)}if(t.attr&&typeof t.attr=="object")for(let r in t.attr){let n=t.attr[r];typeof n=="function"||typeof n=="object"||n!=null&&(typeof n=="string"&&n.includes("{{")||n===!1&&!sr(r)||e.setAttribute&&e.setAttribute(r,re(r,n)))}if(typeof t.themeModifier=="string"&&t.themeModifier&&e.setAttribute&&e.setAttribute("data-theme",t.themeModifier),t.data&&typeof t.data=="object")for(let r in t.data){let n=t.data[r];typeof n=="function"||typeof n=="object"||n==null||n===!1||typeof n=="string"&&n.includes("{{")||e.dataset&&(e.dataset[r]=n===!0?"":n)}if(t.classlist||t.class){let r=t.classlist||t.class;if(typeof r=="string")r.split(" ").forEach(n=>n&&e.classList.add(n));else if(typeof r=="object")for(let n in r){let o=typeof r[n]=="function"?r[n](t,t.state,t.context):r[n];o&&e.classList.add(typeof o=="string"?o:n)}}}}function Iu(t){if(t==null||typeof t!="object")return"s:"+String(t);try{return"o:"+JSON.stringify(t)}catch{return null}}function M2(t){if(!t||typeof t!="object")return!1;for(let e in t){let r=t[e];if(r&&typeof r=="object"&&!Array.isArray(r))return!0}return!1}function Du(t,e){if(!t||!t.style||!e)return null;let r=t.style,n=[];for(let o in e){if(e[o]==null||o.charAt(0)==="&")continue;let i=Bu(o);n.push(i,db(r,i),Ok(r,i))}return n}function db(t,e){return typeof t.getPropertyValue=="function"?t.getPropertyValue(e):""}function Ok(t,e){return typeof t.getPropertyPriority=="function"?t.getPropertyPriority(e):""}function Bu(t){return Mu(t)?t:t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function F2(t,e,r){if(!t||!t.style||!e||!e.length)return;let n=t.style,o=new Set;if(r&&typeof r=="object")for(let s in r)r[s]==null||s.charAt(0)==="&"||o.add(Bu(s));for(let s=0;s<e.length;s+=3){let i=e[s];o.has(i)||db(n,i)===e[s+1]&&typeof n.removeProperty=="function"&&n.removeProperty(i)}}function Lu(t,e){if(!e||!t||!t.style)return!1;let r=t.style;for(let n=0;n<e.length;n+=3)if(db(r,e[n])!==e[n+1]||Ok(r,e[n])!==e[n+2])return!1;return!0}var Mu=t=>t.charCodeAt(0)===45&&t.charCodeAt(1)===45;function N2(t){let e=null;for(let r in t)t[r]!=null&&r.charAt(0)!=="&"&&(e||(e=new Set),e.add(Bu(r)));return e}function j2(t,e,r,n){let o=t.__ref;if(!o)return;let s=null;if(r)for(let i of r){if(n&&n.has(i))continue;let a=e[i];if(a==null||typeof a=="object")continue;let c=Bu(i);dc[c]&&(s||(s={}),s[c]=a)}o.__declaredLonghands=s}function Rk(t,e){let r=t.__ref,n=r&&r.__declaredLonghands;if(!n||!e)return null;let o=null;for(let s in n){if(e.has(s))continue;let i=dc[s],a=!1;for(let c=0;c<i.length;c++)if(e.has(i[c])){a=!0;break}a&&(o||(o={}),o[s]=n[s])}return o}function lk(t,e){let r=t.node;ro(r,e);let n=N2(e);if(!n)return e;let o=t.__ref;if(o)if(o.__inlineCssKeys)for(let i of n)o.__inlineCssKeys.add(i);else o.__inlineCssKeys=new Set(n);let s=Rk(t,n);return s?(ro(r,s),Object.assign({},e,s)):e}function B2(t){let e=t.__ref;if(!e||!e.__inlineCssKeys||!e.__declaredLonghands)return;let r=Rk(t,e.__inlineCssKeys);r&&ro(t.node,r)}function ro(t,e){if(!t||!e||!t.style)return;let r=null;for(let n in e){let o=e[n];if(o!=null){if(n.charAt(0)==="&"&&typeof o=="object"){r||(r={}),r[n]=o;continue}try{let s=String(o),i=Mu(n)?n:n.replace(/[A-Z]/g,f=>"-"+f.toLowerCase()),a=s.trim(),c=/\s*!important\s*$/.test(a),l=a.replace(/\s*!important\s*$/,"");t.style.setProperty(i,l,c?"important":"")}catch{}}}r&&V2(t,r)}function V2(t,e){let r=`_ds${_k.scopedStyleId++}`;t.classList.add(r);let n=t.ownerDocument,o=n.querySelector("style[data-smbls-scoped]");o||(o=n.createElement("style"),o.setAttribute("data-smbls-scoped",""),n.head.appendChild(o));let s="";for(let i in e){let a="."+r,c=i.replace(/&/g,a).split(",").map(f=>{let u=f.trim();return u.includes(a)?u:a+u}).join(", "),l=e[i];if(typeof l=="object"){let f="",u="";for(let d in l){let g=l[d];if(typeof g=="object"){let p=d.includes("&")?c.split(", ").map(m=>d.replace(/&/g,m)).join(", "):c.split(", ").map(m=>`${m} ${d}`).join(", "),h="";for(let m in g)h+=`${m.replace(/[A-Z]/g,_=>"-"+_.toLowerCase())}: ${g[m]};`;u+=xr(`${p} { ${h} }`,p)+`
57
- `}else f+=`${d.replace(/[A-Z]/g,p=>"-"+p.toLowerCase())}: ${g};`}f&&(s+=xr(`${c} { ${f} }`,c)+`
58
- `),u&&(s+=u)}}s&&(o.textContent+=s)}var fk=new Set;function uk(t){if(!Array.isArray(t))return"";let e=[];for(let r=0;r<t.length;r++)typeof t[r]=="string"&&t[r].length&&e.push(t[r]);return e.sort(),e.join("|")}function U2(t,e,r){let n=uk(r);queueMicrotask(()=>{if(!t.__ref)return;let o;try{o=e(t,t.state,t.context)}catch{return}if(uk(o)===n)return;let s=t.__ref.path?t.__ref.path.join("."):t.key||"?";fk.has(s)||(fk.add(s),console.warn(`[smbls] subscribeTo function at "${s}" resolved to a DIFFERENT key list one microtask after create \u2014 wired [${r.join(", ")||"(none)"}], probed [${Array.isArray(o)?o.join(", "):String(o)}]. subscribeTo's function form is resolved ONCE at element-create time (registerSubscribeToEffects, @symbo.ls/element create.js) \u2014 this element stays wired to the ORIGINAL list for its whole lifetime, so this drift is invisible to the reactive effect and any key only present in the new list will never trigger onUpdate. If the watched key genuinely is not known until later (e.g. a module config that loads after shell boot), route the write through an imperative call instead of subscribeTo \u2014 see functions/moduleOpenBridge.js's moduleOpenPage (workspace repo) for the house pattern.`))})}function z2(t){let e=t.subscribeTo,r=typeof e=="function",n=e;if(r)try{n=e(t,t.state,t.context)}catch{n=null}if(r&&gt()&&U2(t,e,Array.isArray(n)?n:[]),!Array.isArray(n)||n.length===0)return;let o=t.__ref;for(let s=0;s<n.length;s++){let i=n[s];if(typeof i!="string"||i.length===0)continue;let a=i.split("."),c=a[0],l=a.slice(1),f={value:!1},u=Y(()=>{let d=t.state&&(kt(t.state)?t.state.root:null);if(!d||!kt(d))return;let g=d;g=g[c];for(let h=0;h<l.length&&!(g==null||typeof g!="object");h++)if(kt(g))g=g[l[h]];else break;if(!f.value)return;let p=!1;if(typeof t.onBeforeUpdate=="function"){let h=t.context?.designSystem;h&&ct(h);try{if(Ay(o)){let m=t.onBeforeUpdate(t,t.state,t.context,{updateBySubscription:!0});m&&typeof m.then=="function"?m.then(()=>Sr(o,!1),_=>{Sr(o,!0),t.context?.plugins?.length&&Ot("error",t,{hook:"onBeforeUpdate",error:_})||console.error("[DOMQL] subscribeTo onBeforeUpdate error:",_)}):(Sr(o,!1),m===!1&&(p=!0))}}catch(m){Sr(o,!0),t.context?.plugins?.length&&Ot("error",t,{hook:"onBeforeUpdate",error:m})||console.error("[DOMQL] subscribeTo onBeforeUpdate error:",m)}finally{h&&it()}}if(!p&&t.node&&o.__effects)for(let h=0;h<o.__effects.length;h++){let m=o.__effects[h];m&&m!==u&&!m._disposed&&!m._isSubscribeToEffect&&typeof m._execute=="function"&&m._execute()}if(!p&&typeof t.onUpdate=="function"){let h=t.context?.designSystem;h&&ct(h);try{t.onUpdate(t,t.state,t.context)}catch(m){t.context?.plugins?.length&&Ot("error",t,{hook:"onUpdate",error:m})||console.error("[DOMQL] subscribeTo onUpdate error:",m)}finally{h&&it()}}},{depth:o.path.length,label:ft(o,"subscribeTo("+i+")")});f.value=!0,u._isSubscribeToEffect=!0,o.__effects.push(u)}}function pb(t,e){return t.charCodeAt(0)===64&&t.length>1&&!t.startsWith("@media")&&!t.startsWith("@keyframes")&&!t.startsWith("@supports")&&!t.startsWith("@container")&&(t==="@dark"||t==="@light"||!e.context?.designSystem?.media?.[t.slice(1)])}function hb(t,e){if(t.charCodeAt(0)!==64||/^@(media|supports|container|keyframes)\b/.test(t))return t;let r=e.context?.designSystem?.media?.[t.slice(1)];return r?/^@(media|supports|container)\b/.test(r)?r:`@media ${r}`:t}var dk=new Set;function H2(t,e){let r=e?.__ref?.path?e.__ref.path.join("."):e?.key||"?",n=r+"::"+t;dk.has(n)||(dk.add(n),console.warn(`[smbls/css] "${t}" at ${r} is a CHILD-COMPONENT key nested inside a pseudo/selector block (":hover", "@dark", etc.) \u2014 that is never a valid CSS selector fragment. The rule is DROPPED (not shipped as a dead/never-matching selector). To reveal a child on a parent state, target the child's OWN class from the parent selector instead, e.g. move the declaration onto the child element itself, or use a sibling-selector combinator in a top-level style block.`))}function As(t,e,r,n){let o={},s=new Set,i=(a,c,l)=>{let f=l?new Set(Object.keys(o)):null;if(xt[a]){let u=xt[a](c,e,e.state,e.context);if(u){let d=Array.isArray(u)?u:[u];for(let g of d)g&&Object.assign(o,g)}}else o[a]=c;if(l)for(let u in o)f.has(u)||s.add(u)};for(let a in t){if(!Object.prototype.hasOwnProperty.call(t,a))continue;let c=t[a];if(typeof c=="function"&&(c=c(e,e.state,e.context)),c==null||typeof c=="function")continue;if(typeof c=="object"&&!Array.isArray(c)){if(a==="style"){for(let g in c){let p=c[g];if(typeof p=="function"&&(p=p(e,e.state,e.context)),p==null||typeof p=="function")continue;let h=typeof e[g]=="function"&&(xt[g]||Et&&Et.has(g))||!!(n&&n.has(g));i(g,p,h)}continue}if(pb(a,e)){let g=As(c,e,!1,n);Object.keys(g).length&&(o[`[data-theme="${a.slice(1)}"] &`]=g);continue}if(/^[A-Z][A-Za-z0-9]*$/.test(a)){gt()&&H2(a,e);continue}let u=hb(a,e),d=As(c,e,!1,n);Object.keys(d).length&&(o[u]=d);continue}let l=typeof e[a]=="function"&&(xt[a]||Et&&Et.has(a)),f=!!(n&&n.has(a));i(a,c,l||f)}if(r)for(let a in o)s.add(a);for(let a of s){let c=o[a];typeof c=="string"&&!c.includes("!important")&&(o[a]=c+" !important")}return o}var Fu=t=>!!t&&typeof t=="object"&&!Array.isArray(t);function Pk(t,e){for(let r in e){let n=e[r];t[r]=Fu(n)?Pk(Fu(t[r])?t[r]:{},n):n}return t}function W2(t,e){if(!Fu(e))return;let r;for(let n of t.split(" ")){let o=n?e[n]:null;Fu(o)&&(r=Pk(r||{},o))}return r}function gb(t,e){if(e===void 0&&(e=0),e>8)return!1;if(typeof t=="function")return!0;if(t&&typeof t=="object"&&!Array.isArray(t)){for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&gb(t[r],e+1))return!0}return!1}function Dk(t,e,r){if(!e||typeof e!="object"||Array.isArray(e))return null;if(pb(t,r)){let s=As(e,r,!1);return Object.keys(s).length?{cssProp:`[data-theme="${t.slice(1)}"] &`,block:s}:null}let n=hb(t,r),o=As(e,r,!1);return Object.keys(o).length?{cssProp:n,block:o}:null}function q2(t){let e=t.__ref;for(let r of Object.keys(t)){if(!ob(r))continue;let n=t[r];if(!n||typeof n!="object"||Array.isArray(n)||!gb(n))continue;let o=null,s,i=Y(()=>{if(!t.node)return;let a=t.context?.designSystem;a&&ct(a);let c,l=!1;try{let f=Dk(r,n,t),u=f?Iu(f.block)+"::"+f.cssProp:null;if(u!==null&&u===s)l=!0;else if(s=u,f){let d=he({[f.cssProp]:f.block},null,t.context?.cssPrefix);c=d?d.split(" ").filter(Boolean):null}else c=null}finally{a&&it()}if(!(l||!t.node.classList)){if(o)for(let f of o)t.node.classList.remove(f);if(c&&c.length)for(let f of c)t.node.classList.add(f);o=c}},{depth:e.path.length,label:ft(e,"cssBlock("+r+")")});e.__effects.push(i)}}function K2(t){let e=t.__ref;e.__conditionalRunners=[];let r=new Map;for(let n of Object.keys(t)){let o=n.charAt(0);if(o!=="."&&o!=="!")continue;let s=n.slice(1);if(!s)continue;if(/[:@\s>~+[\]]/.test(s)){if(typeof console<"u"&&console.warn){let p=s.split(/[:@\s>~+[\]]/)[0];console.warn(`[smbls] conditional \`${n}\` on ${t.key||"?"} will never match \u2014 the whole string after \`${o}\` is read as one prop name. Nest the selector inside instead: \`${o}${p}: { '${s.slice(p.length)}': {...} }\`.`)}continue}let i=t[n];if(!i||typeof i!="object")continue;let a=o==="!",c={lastMatch:!1,appliedKeys:null,appliedClasses:null},l=new Set;for(let p in i){if(!Object.prototype.hasOwnProperty.call(i,p))continue;let h=p.charAt(0),m=i[p];(h===":"||h==="@"||h==="&"||h==="[")&&m&&typeof m=="object"&&!Array.isArray(m)||l.add(p)}let f=()=>{let p,h=t[s];if(h===void 0){let x=!!t.state&&s in t.state,y=t.state?t.state[s]:void 0;if(x||y!==void 0)p=y;else{let b=t.context?.cases?.[s];if(b===void 0)return;try{p=typeof b=="function"?b.call(t,t):b}catch(w){p=!1,e.__conditionalError=w,typeof console<"u"&&console.warn&&console.warn(`[smbls] conditional \`${n}\` case fn threw on ${t.key||"?"} \u2014 treating as false:`,w?.message||w)}}}else if(typeof h=="function")try{p=h(t,t.state,t.context)}catch(x){p=!1,e.__conditionalError=x,typeof console<"u"&&console.warn&&console.warn(`[smbls] conditional \`${n}\` predicate threw on ${t.key||"?"} \u2014 treating as false:`,x?.message||x)}else p=h;let m=a?!p:!!p;if(!t.node||m===c.lastMatch)return;c.lastMatch=m;let _=t.context?.designSystem;_&&ct(_);try{if(m){let x={},y={},b=!1;for(let S in i){if(!Object.prototype.hasOwnProperty.call(i,S))continue;let C=i[S],O=S.charAt(0);if((O===":"||O==="@"||O==="&"||O==="[")&&C&&typeof C=="object"&&!Array.isArray(C)){if(pb(S,t)){let T=As(C,t,!1,l);Object.keys(T).length&&(y[`[data-theme="${S.slice(1)}"] &`]=T,b=!0)}else{let T=hb(S,t),M=As(C,t,!1,l);Object.keys(M).length&&(y[T]=M,b=!0)}continue}let L=typeof C=="function"?C(t,t.state,t.context):C;if(L!=null)if(xt[S]){let T=xt[S](L,t,t.state,t.context);if(T){let M=Array.isArray(T)?T:[T];for(let U of M)U&&Object.assign(x,U)}}else(Et&&Et.has(S)||Mu(S))&&(x[S]=L)}let w=Object.keys(x);if(w.length){ro(t.node,x);for(let S of w)r.set(S,n);c.appliedKeys=w}else c.appliedKeys=null;if(b){let S=he(y,null,t.context?.cssPrefix,{state:!0}),C=S?S.split(" ").filter(Boolean):[];if(C.length&&t.node.classList){for(let O of C)t.node.classList.add(O);c.appliedClasses=C}else c.appliedClasses=null}else if(c.appliedClasses){for(let S of c.appliedClasses)t.node.classList.remove(S);c.appliedClasses=null}}else{if(c.appliedKeys){for(let x of c.appliedKeys)r.get(x)===n&&(Mu(x)?t.node.style.removeProperty(x):t.node.style[x]="",r.delete(x));c.appliedKeys=null}if(c.appliedClasses){for(let x of c.appliedClasses)t.node.classList.remove(x);c.appliedClasses=null}}}finally{_&&it()}};e.__conditionalRunners.push(f);let u=jt(t,t[s+"Deps"],f),d=Y(u,{depth:e.path.length,label:ft(e,"conditional("+n+")")}),g=e.__exec&&e.__exec[s]||t[s];d._sources.size===0&&typeof g=="function"&&gt()&&console.warn(`[smbls] conditional \`${n}\` on ${t.key||"?"} subscribed to nothing \u2014 its predicate tracked no reactive read on its first run, so no state write will ever re-evaluate it (only a direct element.update() on this element re-runs it). If the predicate guards its state reads (\`in\`, short-circuits, \`?.\`), declare \`${s}Deps: [...]\` (state-key strings or \`(el, s) => \u2026\` selectors) so the subscription is armed unconditionally.`),e.__effects.push(d)}}var eb=new WeakSet;function G2(t){let e=t.ownerDocument;!e||eb.has(e)||(eb.add(e),queueMicrotask(()=>{eb.delete(e);let r=e.body||e.documentElement;r&&r.offsetWidth}))}var rb=new WeakSet,pk=!1;function hk(t){return t.startsWith("[data-theme=")||t.startsWith("@media")&&t.includes("prefers-color-scheme")}function cb(t,e){let r={...t};for(let n in e){let o=e[n],s=r[n];r[n]=o&&typeof o=="object"&&s&&typeof s=="object"?cb(s,o):o}return r}function Lk(t,e){let r={};for(let n in t){let o=t[n];if(o&&typeof o=="object"){let s=Lk(o,e);Object.keys(s).length&&(r[n]=s)}else e.has(n)||(r[n]=o)}return r}function Ik(t){let{node:e}=t;if(!e)return;if(pk||(pk=!0,he({display:"none"})),rb.has(t)){console.error("[applyCssInProps] re-entry detected for element",t.key,"prop path:",t.__ref?.path);return}rb.add(t);let r=t.context?.designSystem;r&&ct(r),_u();try{let n={},o=!1,s=[],i=null,a=null,c=null,l=(p,h)=>{if(h&&typeof h=="object"&&hk(p)){a||(a={});let m=a[p];m&&(h=cb(m,h)),a[p]=h}else(h===null||typeof h!="object")&&(c||(c=new Set),c.add(p));n[p]=h};if(Object.prototype.hasOwnProperty.call(t,"theme")&&typeof t.theme!="function"&&xt.theme){let p=xt.theme(t.theme,t,t.state,t.context);if(p){let h=m=>{for(let _ in m){let x=m[_];x&&typeof x=="object"&&hk(_)&&(i||(i={}),i[_]=x),n[_]=x}};if(Array.isArray(p))for(let m of p)m&&h(m);else h(p);o=!0}}let f=(p,h)=>{if(xt[p]){let m=xt[p](h,t,t.state,t.context);if(m){if(Array.isArray(m)){for(let _ of m)if(_)for(let x in _)l(x,_[x])}else for(let _ in m)l(_,m[_]);o=!0}}else if(Et&&Et.has(p))h!=null&&typeof h!="object"&&(l(p,h),o=!0);else if(p.charCodeAt(0)===45)h!=null&&typeof h!="object"&&(l(p,h),o=!0);else if((p.charAt(0)==="&"||p.charAt(0)==="@"||p.charAt(0)===":"||p.charAt(0)==="[")&&h&&typeof h=="object"&&!Array.isArray(h)){if(gb(h))return;let m=Dk(p,h,t);m&&(l(m.cssProp,m.block),o=!0)}};if(typeof t.class=="string"){let p=W2(t.class,t.context?.designSystem?.class);if(p)for(let h in p)f(h,p[h])}let u=c?new Set(c):null,d=t.tag||"div";for(let p of Object.keys(t)){if(typeof t[p]=="function"||Nt.has(p)||p==="theme")continue;let h=p.charCodeAt(0);h>=65&&h<=90||Cr(p)||Pu(d,p)||f(p,t[p])}if(i)for(let p in i){let h=c?Lk(i[p],c):i[p];a&&a[p]&&(h=cb(h,a[p])),Object.keys(h).length?n[p]=h:delete n[p]}if(j2(t,n,c,u),o){n.display&&String(n.display).includes("!important")&&(e.style.setProperty("display",String(n.display).replace(/\s*!important\s*$/,""),"important"),delete n.display);let p=t.display!=null&&typeof t.display!="function"?t.display:t.hide===!0||t.show===!1?"none":null;typeof p=="string"&&p!==""&&n.display&&n.display!==p&&(n.display=p);let h=he(n,null,t.context?.cssPrefix);if(s=h?h.split(" ").filter(Boolean):[],h&&e.classList){let m=s,_=!1;for(let x of m)e.classList.add(x),_||(x.charCodeAt(0)===95&&x.charCodeAt(1)===99||x.charCodeAt(0)===95&&x.indexOf("_c",1)!==-1)&&(_=!0);_&&G2(e)}}let g=t.__ref;if(g){let p=g.__staticCssClasses;if(p&&e.classList){let h=new Set(s);for(let m of p)h.has(m)||e.classList.remove(m)}g.__staticCssClasses=s}B2(t)}finally{wu(),r&&it(),rb.delete(t)}}var T0=t=>!!xt[t]||!!(Et&&Et.has(t))||typeof t=="string"&&t.charCodeAt(0)===45;function O0(t){t&&t.node&&Ik(t)}function $k(t){let{node:e}=t;if(!e||!e.setAttribute)return;if(t.aria&&typeof t.aria=="object")for(let o in t.aria){let s=t.aria[o];if(typeof s=="function"||typeof s=="object"||s==null||typeof s=="string"&&s.includes("{{"))continue;let i="aria-"+o.replace(/[A-Z]/g,a=>"-"+a.toLowerCase());e.setAttribute(i,re(i,s))}let r=Ey(t);for(let o in r){let s=r[o];s!=null&&s!==!1&&typeof s!="function"&&typeof s!="object"&&e.setAttribute(o,s===!0?"":s)}let n=t.tag||"div";for(let o of Object.keys(t)){if(typeof t[o]=="function"||Nt.has(o)||o==="on"||r[o]!==void 0)continue;let s=o.charCodeAt(0);if(!(s>=65&&s<=90)&&!Cr(o)&&!ks(n,o)&&Te(n,o)){let i=t[o];if(i==null)continue;if(typeof i=="string"&&i.includes("{{")){if(!Qn[o])continue;i=Ft.call(t,i,t.state)}if(i==null||typeof i=="function"||typeof i=="object"||i===!1&&!sr(or(o)||o))continue;let a=or(o)||o;e.setAttribute(a,re(a,i))}}}function R0(t,e){let{node:r}=t;if(!r||!r.setAttribute)return;let n=e.charCodeAt(0);if(n>=65&&n<=90||Cr(e))return;let o=t.tag||"div";if(ks(o,e)||!Te(o,e))return;let s=or(e)||e,i=s.toLowerCase(),a=t.__ref&&t.__ref.__effects,c=!1;if(a)for(let u=0;u<a.length;u++){let d=a[u];d&&d._attrName===i&&!d._disposed&&typeof d._execute=="function"&&(c=!0,d._execute())}if(c)return;let l=t[e],f=Qn[e];if(f&&l!=null){let u=f(t);u!==void 0&&(l=u)}typeof l=="string"&&l.includes("{{")&&(l=Ft.call(t,l,t.state)),l==null||l===!1&&!sr(s)?r.removeAttribute(s):typeof l!="function"&&typeof l!="object"&&r.setAttribute(s,re(s,l))}function Y2(t,e){let r=t.node,n=t.__ref,o=n.__autoGrow;if(!e){if(o&&o.active){try{r.removeEventListener("input",o.resize)}catch{}mk(o),eo.delete(t),r.style.height="",o.appliedMax!=null&&r.style.maxHeight===o.appliedMax&&(r.style.maxHeight=""),yk(r,o,!1),o.active=!1,o.appliedMax=null,o.lastMeasure=0}return}o||(o=n.__autoGrow={active:!1,appliedMax:null,lastMeasure:0,lastWidth:null,watch:null,awaitingLayout:!1,appliedScroll:!1,fontsHooked:!1,attachAttempts:0,firstAttemptAt:null,resize:()=>{if(!r.isConnected){Sc(t,!0);return}if(!(r.scrollHeight>0)){o.awaitingLayout=!0,gk(t,o);return}o.awaitingLayout=!1;let i=r.style.height;r.style.height="0px";let a=r.scrollHeight;if(!(a>0)){r.style.height=i;return}let c=J2(r),l=c!=null&&a>c;r.style.height=(l?c:a)+"px",yk(r,o,l),o.lastMeasure=a,o.lastWidth=r.clientWidth,gk(t,o)}},n.__eventCleanup||(n.__eventCleanup=[]),n.__eventCleanup.push(()=>{try{r.removeEventListener("input",o.resize)}catch{}mk(o),eo.delete(t)})),o.active||(r.addEventListener("input",o.resize),o.active=!0,Z2(t,o));let s=typeof e=="object"&&e.max!=null?String(e.max):null;s!==o.appliedMax&&(s==null?o.appliedMax!=null&&r.style.maxHeight===o.appliedMax&&(r.style.maxHeight=""):r.style.maxHeight=s,o.appliedMax=s),o.resize()}function Sc(t,e){let r=t.__ref?.__autoGrow;r&&(e&&(r.attachAttempts=0,r.firstAttemptAt=null),eo.add(t),ju())}function X2(){let t=Array.from(eo);eo.clear();for(let e=0;e<t.length;e++){let r=t[e],n=r.node,o=r.__ref?.__autoGrow;if(!(!n||!o||!o.active)){if(!n.isConnected){o.firstAttemptAt==null&&(o.firstAttemptAt=Es()),o.attachAttempts+=1,o.attachAttempts<=Sk&&Es()-o.firstAttemptAt<kk&&(eo.add(r),ju());continue}o.attachAttempts=0,o.firstAttemptAt=null,o.resize()}}}function gk(t,e){if(e.watch)return;let r=t.node;if(!r)return;let n=r.ownerDocument&&r.ownerDocument.defaultView,o=n&&n.ResizeObserver||(typeof ResizeObserver=="function"?ResizeObserver:null);if(typeof o!="function")return;let s=()=>{if(!e.active||!r.isConnected||!(r.scrollHeight>0))return;if(e.awaitingLayout){e.awaitingLayout=!1,Sc(t,!0);return}let a=r.clientWidth;e.lastWidth!=null&&Math.abs(a-e.lastWidth)<.5||(e.lastWidth=a,Sc(t,!0))},i;try{i=new o(s),i.observe(r)}catch{return}e.watch=i}function mk(t){let e=t.watch;if(e){t.watch=null;try{e.disconnect()}catch{}}}function Z2(t,e){if(e.fontsHooked)return;e.fontsHooked=!0;let r=t.node&&t.node.ownerDocument,n=r&&r.fonts&&r.fonts.ready;!n||typeof n.then!="function"||n.then(()=>{e.active&&t.node&&Sc(t,!0)},()=>{})}function J2(t){let e=t.ownerDocument&&t.ownerDocument.defaultView,r;try{r=e&&e.getComputedStyle?e.getComputedStyle(t):null}catch{r=null}if(!r)return null;let n=f=>typeof f=="string"&&/^\s*-?\d*\.?\d+px\s*$/.test(f)?parseFloat(f):null,o=n(r.maxHeight);if(o==null||!(o>0))return null;let s=(n(r.paddingTop)||0)+(n(r.paddingBottom)||0),i=(n(r.borderTopWidth)||0)+(n(r.borderBottomWidth)||0),a=r.boxSizing==="border-box"?o-i:o+s,c=n(r.lineHeight);if(!(c>0))return a;let l=Math.floor((a-s)/c+1e-6);return l>=1?l*c+s:a}function yk(t,e,r){r?e.appliedScroll||(t.style.overflowY="auto",e.appliedScroll=!0):e.appliedScroll&&(t.style.overflowY==="auto"&&(t.style.overflowY=""),e.appliedScroll=!1)}var bk=["srcObject","muted"],Q2=(t,e)=>t==="muted"?e===!0||e===""||e==="true"||e==="muted":e??null;function tD(t){let e=t.node,r=t.__ref;if(!(!e||!r))for(let n=0;n<bk.length;n++){let o=bk[n],s=t[o];if(s===void 0||!(o in e))continue;let i=a=>{let c=Q2(o,a);if(e[o]!==c)try{e[o]=c}catch(l){Gt(r,o,l)}};if(typeof s=="function"){let a=jt(t,t[o+"Deps"],s),c=Y(()=>{try{i(a(t,t.state,t.context))}catch(l){Gt(r,o,l)}},{depth:r.path.length,label:ft(r,o)});r.__effects.push(c),r.__exec[o]=s}else i(s);o==="srcObject"&&(r.__releaseMedia=()=>{try{e.srcObject!=null&&(e.srcObject=null)}catch{}})}}function Mk(t){if(!t.autoGrow)return;let e=t.node;if(!e||e.tagName!=="TEXTAREA")return;let r=t.__ref,n=t.autoGrow,o=typeof n=="function"?jt(t,t.autoGrowDeps,n):null,s=Y(()=>{let i=t.autoGrow,a=i;if(typeof i=="function")try{a=(i===n&&o?o:i)(t,t.state,t.context)}catch{a=null}Y2(t,a)},{depth:r.path.length,label:ft(r,"autoGrow")});r.__effects||(r.__effects=[]),r.__effects.push(s),o&&(r.__exec.autoGrow=n)}var Fk=new Set(["onSwipe","onSwipeLeft","onSwipeRight","onSwipeUp","onSwipeDown"]);function Nk(t,e){for(let r of Object.keys(t)){if(!Cr(r)||Fk.has(r))continue;let n=hu(r);if(n){gu(n,t,t[r]);continue}let o=t[r];if(typeof o=="string"&&/^[A-Za-z_$][\w$]*$/.test(o)){let i=o;o=function(c){return t.call(i,c)}}if(typeof o!="function")continue;let s=x2(r);nn.has(s)||ms(S2(s),t,o)}eD(t)}function eD(t){let e=t.node;if(!e||!e.addEventListener)return;let r={},n=!1;for(let d of Fk){let g=t[d];typeof g=="function"&&(r[d]=g,n=!0)}if(!n)return;let o=typeof t.swipeThreshold=="number"?t.swipeThreshold:40,s=typeof t.swipeMaxDuration=="number"?t.swipeMaxDuration:600,i=0,a=0,c=0,l=!1,f=d=>{let g=d.touches&&d.touches[0]||d.changedTouches&&d.changedTouches[0];g&&(i=g.clientX,a=g.clientY,c=Date.now(),l=!0)},u=d=>{if(!l)return;l=!1;let g=d.changedTouches&&d.changedTouches[0]||d.touches&&d.touches[0];if(!g)return;let p=g.clientX-i,h=g.clientY-a,m=Date.now()-c;if(m>s)return;let _=Math.abs(p),x=Math.abs(h);if(Math.max(_,x)<o)return;let y;if(_>x*1.2)y=p<0?"left":"right";else if(x>_*1.2)y=h<0?"up":"down";else return;let b="onSwipe"+y.charAt(0).toUpperCase()+y.slice(1),w=r[b],S=r.onSwipe;w&&w.call(t,d,t,t.state,t.context),S&&S.call(t,{direction:y,dx:p,dy:h,dt:m,event:d},t,t.state,t.context)};e.addEventListener("touchstart",f,{passive:!0}),e.addEventListener("touchend",u,{passive:!0}),t.__ref.__eventCleanup||(t.__ref.__eventCleanup=[]),t.__ref.__eventCleanup.push(()=>{try{e.removeEventListener("touchstart",f)}catch{}try{e.removeEventListener("touchend",u)}catch{}})}function no(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=no(o,s):r[n]=s}return r}function lb(t,e,r,n,o){if(!e||!t.node)return;let s=t.childExtends,i=vs(t,"childProps");if(Array.isArray(e)){let a=t.tag==="fragment",c=t.context?.document||globalThis.document,l=a?null:c?.createDocumentFragment();if(!a&&!l)return;let f=t.childProps,u=t.childrenAs,d=x=>{let y=e[x],b=y;(typeof y=="string"||typeof y=="number")&&(y={text:y});let w=f;if(typeof f=="function")try{w=f(t,y)}catch{w=null}let S=typeof f=="function"?yc(w):i;if(o&&u!=="state"&&(S=bc(S,yc(b))),u==="state"){let O=b;(typeof b=="string"||typeof b=="number")&&(O={value:b,text:b}),y=w?{...w,state:O}:{state:O}}else w&&(y=no(w,y));if(s&&!y.ignoreChildExtends)if(y.extends){let O=Array.isArray(y.extends)?y.extends:[y.extends],L=Array.isArray(s)?s:[s];y={...y,extends:[...L,...O]}}else y={...y,extends:s};let C=vk(y?.key,b,x);try{return ne(_c(y,S),t,C,r)}catch(O){if(typeof console<"u"&&console.error){let L=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${C}" failed to construct at ${L} (initial render, skipping this row):`,O?.message||O)}return null}},g=t.__ref;if(!(n===!0&&!a&&!!g&&(r?.mountYield===!0||t.yieldChildren===!0))){for(let x=0;x<e.length;x++){let y=d(x);!a&&y?.node&&l.appendChild(y.node)}return a||t.node.appendChild(l),!0}let h=g.__childrenChunkGen=(g.__childrenChunkGen||0)+1;Hy();let m=null,_=x=>{if(g.__disposed||g.__childrenChunkGen!==h){m&&m.parentNode&&m.remove();return}for(let y=x;y<e.length;y++){let b=d(y);if(b?.node&&(m?t.node.insertBefore(b.node,m):l.appendChild(b.node)),y+1<e.length&&zy()){m||(m=c.createComment("smbls-mount"),l.appendChild(m),t.node.appendChild(l));let w=y+1;qy(()=>_(w));return}}m?(m.remove(),t.node.tagName==="SELECT"&&Nu(t,!0)):t.node.appendChild(l)};return _(0),Wy(),!0}if(typeof e=="string"){let a=Ck(e,t);if(Array.isArray(a))return lb(t,a,r,n,!0)}if(typeof e=="object")for(let a in e){if(Nt.has(a))continue;let c=e[a];if(c==null||c===!1)continue;let l=o?bc(i,yc(c)):i;if((typeof c=="string"||typeof c=="number")&&(c={text:c}),t.childProps&&(c=no(t.childProps,c)),s&&!c.ignoreChildExtends)if(c.extends){let f=Array.isArray(c.extends)?c.extends:[c.extends],u=Array.isArray(s)?s:[s];c={...c,extends:[...u,...f]}}else c={...c,extends:s};ne(_c(c,l),t,a,r)}}function Nu(t,e){let r=t.node;if(!r||r.tagName!=="SELECT")return;let n=r.options;if(!n||!n.length)return;let o=t.__ref,s=o&&o.__exec&&o.__exec.value,i=typeof s=="function",a=t.value!=null&&typeof t.value!="function";if(i||a){let f;if(i)try{f=s(t,t.state,t.context)}catch{return}else f=t.value,typeof f=="string"&&f.includes("{{")&&(f=Ft.call(t,f,t.state));let u=f==null?"":String(f);r.value!==u&&(r.value=u);return}let c=e||!(o&&o.__selectSynced);if(o&&(o.__selectSynced=!0),!c)return;let l=-1;for(let f=0;f<n.length;f++)n[f].defaultSelected&&(l=f);l>=0&&r.selectedIndex!==l&&(r.selectedIndex=l)}function jk(t,e){let{children:r,content:n}=t,o=t.childExtends,s=typeof r=="function"||Ek(t,"children");if(typeof r=="function"){let p=r;try{r=p(t,t.state,t.context)}catch(y){if(r=void 0,typeof console<"u"&&console.error){let b=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] \`children:\` factory threw at ${b} (initial run, treating as empty):`,y?.message||y)}}ik(t,r),t.children=r;let h=t.__ref,m=!1,_=jt(t,t.childrenDeps,p),x=Y(()=>{let y=m;m=!0;let b;try{b=_(t,t.state,t.context)}catch(U){if(typeof console<"u"&&console.error){let rt=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] \`children:\` factory threw at ${rt}${y?"":" (initial tracking run)"}:`,U?.message||U)}return}if(!y||b===t.children)return;ik(t,b),t.children=b,h.__childrenChunkGen!=null&&h.__childrenChunkGen++;let w=typeof t.onContentUpdate=="function",S=w?[]:null,C=w?[]:null,O=w?[]:null;if(Array.isArray(b)&&t.childrenAs==="state"){let U=t.childProps,rt=[],Rt=new Map;for(let j=0;j<b.length;j++){let nt=b[j],N=U;if(typeof U=="function")try{N=U(t,nt)}catch{N=null}let J=vk(N&&N.key,nt,j);rt.push(J),Rt.set(J,{rawChild:nt,childProps:N})}let mt=new Set(rt),F=h.__children.slice();for(let j of F)if(!mt.has(j)){let nt=t[j];nt?.remove&&nt.remove(),delete t[j],C&&C.push(j)}let W=t.childExtends,yt=t.tag==="fragment",St=t.context?.document||globalThis.document,Pt=yt?null:St?.createDocumentFragment(),G=new Set;for(let j of rt){let nt=Rt.get(j),N=nt.rawChild,J=t[j];if(J&&J.state){if(N&&typeof N=="object"){let Dt=J.state,Q=Dt.$replace||Dt.replace,X=Dt.$update||Dt.update;try{if(typeof Q=="function")Q.call(Dt,N);else if(typeof X=="function"){for(let Z in Dt)if(!(Z==="__element"||Z==="root"||Z==="parent"||Z==="update")&&!Object.prototype.hasOwnProperty.call(N,Z))try{Dt[Z]=void 0}catch{}X.call(Dt,N)}else for(let Z in N)Dt[Z]=N[Z]}catch(Z){if(typeof console<"u"&&console.error){let q=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${j}" failed to patch at ${q} (reconcile, keeping its previous data for this pass):`,Z?.message||Z)}}}O&&O.push(j);continue}let z=N;(typeof N=="string"||typeof N=="number")&&(z={value:N,text:N});let cr=nt.childProps,At=cr?{...cr,state:z}:{state:z},ti=typeof U=="function"?yc(cr):vs(t,"childProps");if(W&&!At.ignoreChildExtends)if(At.extends){let Dt=Array.isArray(At.extends)?At.extends:[At.extends],Q=Array.isArray(W)?W:[W];At={...At,extends:[...Q,...Dt]}}else At={...At,extends:W};let il;try{il=ne(_c(At,ti),t,j,e)}catch(Dt){if(typeof console<"u"&&console.error){let Q=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${j}" failed to construct at ${Q} (reconcile, skipping this row):`,Dt?.message||Dt)}G.add(j);continue}!yt&&il?.node&&Pt&&Pt.appendChild(il.node),S&&S.push(j)}if(!yt&&Pt&&Pt.childNodes.length&&t.node&&t.node.appendChild(Pt),!yt&&t.node){let j=null;for(let nt of rt){let N=t[nt]?.node;if(!N)continue;let J=j?j.nextSibling:t.node.firstChild;N!==J&&t.node.insertBefore(N,J),j=N}}h.__children=G.size?rt.filter(j=>!G.has(j)):rt,w&&(S.length||C.length)&&rk(t,{added:S,removed:C,kept:O}),Nu(t,!1);return}let M=w?[...h.__children]:null;for(let U of[...h.__children]){let rt=t[U];rt?.remove&&rt.remove(),delete t[U]}h.__children=[],lb(t,b,e,!1,!0),Nu(t,!1),w&&rk(t,{added:[...h.__children],removed:M,kept:[]})},{depth:h.path.length,label:ft(h,"children")});h.__effects.push(x)}let i=lb(t,r,e,!0,s);if(n!=null&&!(n&&n.__ref)){let p=n;if(typeof p=="string"||typeof p=="number"?p={text:p}:typeof p!="object"&&(p={}),t.childProps&&(p=no(t.childProps,p)),o&&!p.ignoreChildExtends)if(p.extends){let m=Array.isArray(p.extends)?p.extends:[p.extends],_=Array.isArray(o)?o:[o];p={...p,extends:[..._,...m]}}else p={...p,extends:o};let h=bc(vs(t,"childProps"),vs(t,"content"));ne(_c(p,h),t,"content",e)}if(r&&!i)return;let a=t.context?.components||{},c=t.__ref&&t.__ref.__runtimeSource,l=c?{}:null;{let p=Object.keys(t);for(let h=0;h<p.length;h++){let m=p[h];if(!m.endsWith("Extends")||typeof t[m]!="string")continue;let _=m.slice(0,-7);if(!_||_.charCodeAt(0)<65||_.charCodeAt(0)>90)continue;let x={extends:t[m]};delete t[m];for(let y=h+1;y<p.length;y++){let b=p[y],w=b.charCodeAt(0);if(w>=65&&w<=90||Nt.has(b)||typeof t[b]=="function"&&(b.startsWith("on")||b.startsWith(".")))break;let S=t[b];S!==void 0&&(x[b]=S,delete t[b],l&&xc(c,b)&&(l[_]||(l[_]={}),l[_][b]=c[b]))}t[_]&&typeof t[_]=="object"?t[_]={...x,...t[_]}:t[_]=x}}let f=e?.mountYield===!0||t.yieldChildren===!0,u=Object.keys(t),d=p=>{if(Nt.has(p)||typeof t[p]!="object"||t[p]===null)return;let h=p.charCodeAt(0);if(h<65||h>90)return;let m=t[p];if(m.__ref)return;if(!m.extends&&!m.extend){let x=a[p]||a[`smbls.${p}`];x&&(m={...m,extends:x})}if(t.childProps&&(m=no(t.childProps,m)),o&&!m.ignoreChildExtends)if(m.extends){let x=Array.isArray(m.extends)?m.extends:[m.extends],y=Array.isArray(o)?o:[o];m={...m,extends:[...y,...x]}}else m={...m,extends:o};let _=c?bc(vs(t,"childProps"),bc(l[p]||null,vs(t,p))):null;ne(_c(m,_),t,p,e)};if(!f){for(let p of u)d(p);return}Hy();let g=p=>{for(let h=p;h<u.length;h++)if(d(u[h]),h+1<u.length&&zy()){let m=h+1;qy(()=>g(m));return}};g(0),Wy()}function Bk(t,e,r){let{node:n}=t;if(!n)return;n.ref=t;let o=e?.tag==="fragment"?e.__ref?.__fragmentAnchor:null;if(o){let i=o.parentNode;if(i){if(r?.position==="before"&&r.node)i.insertBefore(n,r.node);else if(r?.position==="after"&&r.node){let a=r.node.nextSibling;i.insertBefore(n,a||o)}else i.insertBefore(n,o);return}}let s=e?.node||(e?.nodeType?e:null);if(s)if(r?.position==="before"&&r.node)s.insertBefore(n,r.node);else if(r?.position==="after"&&r.node){let i=r.node.nextSibling;i?s.insertBefore(n,i):s.appendChild(n)}else s.appendChild(n)}var fb=3;function Ay(t){return!t||t.__inBeforeUpdate||(t.__beforeUpdateFailCount||0)>=fb?!1:(t.__inBeforeUpdate=!0,!0)}function Sr(t,e){t&&(t.__inBeforeUpdate=!1,e?(t.__beforeUpdateFailCount=(t.__beforeUpdateFailCount||0)+1,t.__beforeUpdateFailCount===fb&&typeof console<"u"&&console.error&&console.error(`[DOMQL] onBeforeUpdate failed ${fb}x in a row on this element \u2014 pausing automatic retries until a future prop/state change re-arms it.`)):t.__beforeUpdateFailCount=0)}function ie(t,e,r){let n=t.charAt(0).toLowerCase()+t.slice(1);e.context?.plugins?.length&&Ot(n,e,r);let o="on"+t,s=e[o];if(typeof s=="function"){let c=t==="Render"?"__inRender":t==="RenderRouter"?"__inRenderRouter":null;if(c){if(e.__ref[c])return!0;e.__ref[c]=!0}let l=e.context?.designSystem;l&&ct(l);let f=!!c;try{let u=s(e,e.state,e.context,r);if(u&&typeof u.then=="function"){let d=e.__ref;return u.catch(g=>{e.context?.plugins?.length&&Ot("error",e,{hook:o,error:g})||console.error(`[DOMQL] Lifecycle "${o}" error:`,g)}).finally(()=>{c&&d&&(d[c]=!1)}),f=!1,!0}if(u===!1)return!1}catch(u){if(e.context?.plugins?.length&&Ot("error",e,{hook:o,error:u})||console.error(`[DOMQL] Lifecycle "${o}" error:`,u),e.context?.strictMode)throw u}finally{l&&it(),f&&e.__ref&&(e.__ref[c]=!1)}}return!0}var Vk={blue:"#213eb0",green:"#389d34",red:"#e15c55",yellow:"#EDCB38",orange:"#e97c16",transparent:"rgba(0, 0, 0, 0)",black:"black",gray:"#4e4e50",white:"white",title:["--gray 1 -168","--gray 1 +168"],caption:["--gray 1 -68","--gray 1 +68"],paragraph:["--gray 1 -42","--gray 1 +42"],disabled:["--gray 1 -26","--gray 1 +26"],line:["--gray 1 -16","--gray 1 +16"],scrim:["black.45","black.55"],scrimSoft:["black.2","black.3"],blueDeep:"#0A5CB8",blueBright:"#47A8FF",accentInk:["blueDeep","blueBright"],greenDeep:"#2A6E28",greenBright:"#7FD07B",successInk:["greenDeep","greenBright"],redDeep:"#A83520",redBright:"#FF8C78",dangerInk:["redDeep","redBright"],orangeDeep:"#94500F",orangeBright:"#F4A45E",warningInk:["orangeDeep","orangeBright"],magentaDeep:"#A100A1",magentaBright:"#FF7AFF",magentaInk:["magentaDeep","magentaBright"]},Uk={"gradient-blue-light":`linear-gradient(to right,
56
+ `):"")}}if(Bu(c,!0),Xk(c,e,o),typeof c.html=="function"&&c.node&&!c.node.innerHTML){let d=c.context?.designSystem;d&&ct(d);try{let g=c.html(c,c.state,c.context);g!=null&&typeof g!="function"&&(c.node.innerHTML=g)}catch{}finally{d&&it()}}if(ie("Create",c,n),ie("Complete",c,n),ie("Render",c,n),ie("RenderRouter",c,n),cb(c,n),typeof c.onFrame=="function"){let d=c.onFrame,g=c.context?.designSystem,p=()=>{if(c.node){if(c.node.isConnected){g&&ct(g);try{d(c,c.state,c.context)}catch(h){console.error("[DOMQL] onFrame error:",h)}finally{g&&it()}}requestAnimationFrame(p)}};requestAnimationFrame(p)}return c}function Ik(t,e,r,n,o,s){if(r&&!e.extends&&!e.extend){let h=r.indexOf("_"),m=r.indexOf("."),y=h>0?h:-1;if(m>0&&(y<0||m<y)&&(y=m),y>0){let x=r.substring(0,y),b=t.context?.components;b&&(b[x]||b["smbls."+x])?e={...e,extends:x}:b&&gt()&&(/^[A-Z]\w*_\d+$/.test(r)||/^[A-Z]\w*\.\w+$/.test(r))&&console.warn(`[smbls] auto-extend: key "${r}" looks like an instance of "${x}" but neither "${x}" nor "smbls.${x}" is registered in context.components \u2014 element will render as a plain <div>. Register the base component or rename the key.`)}}bs(t,e,s);let i=new Set(["childProps","attr","style","scope","data"]),a=t.props&&typeof t.props=="object"?t.props:null;for(let h in e){if(h==="parent"||h==="node"||h==="__ref"||h==="extends"||h==="context"||h==="props")continue;if(h==="key"){n&&(t.key=n);continue}let m=e[h],y=t[h],x=y&&m&&typeof y=="object"&&typeof m=="object"&&!Array.isArray(y)&&!Array.isArray(m)&&typeof y!="function"&&typeof m!="function";x&&h.charCodeAt(0)>=65&&h.charCodeAt(0)<=90?t[h]=yc(y,m):x&&i.has(h)?t[h]={...y,...m}:x&&lb(h)?t[h]=yc(y,m):t[h]=m}function c(h){for(let m in h){let y=h[m],x=t[m],b=x&&y&&typeof x=="object"&&typeof y=="object"&&!Array.isArray(x)&&!Array.isArray(y)&&typeof x!="function"&&typeof y!="function";b&&m.charCodeAt(0)>=65&&m.charCodeAt(0)<=90?t[m]=yc(x,y):b&&i.has(m)?t[m]={...x,...y}:b&&lb(m)?t[m]=yc(x,y):t[m]=y}}a&&c(a),e.props&&typeof e.props=="object"&&c(e.props),e.classlist!==void 0&&(t.classlist=e.classlist),e.text!==void 0&&(t.text=e.text),e.html!==void 0&&(t.html=e.html);let l=t.scope&&typeof t.scope=="object"?t.scope:null,f=o?.scope,u=t.context&&typeof t.context.globalScope=="object"&&t.context.globalScope||null,d=f||u||null;if(e.scope!==void 0||l){let h={};l&&Object.assign(h,l),e.scope!==void 0&&Object.assign(h,e.scope),t.scope=bl(h,d)}else d&&(t.scope=d);e.if!==void 0&&(t.if=e.if);let g=t.__ref,p=K2(t,g&&g.__runtimeSource);return g&&(g.__declaredArrays=p||void 0),Ss(t),N2(t,o,e),e}var $2=new Set(["key","parent","context","__ref"]);function M2(t,e){for(let o of Object.keys(t))$2.has(o)||delete t[o];let r=lr();r&&Ke(null);let n=e.definition;if(!n.extends&&!n.extend&&typeof e.key=="string"){let o=t.context?.components||{},s=o[e.key]||o["smbls."+e.key];s&&(n={...n,extends:s})}try{Ik(t,n,e.key,e.ownKey,t.parent,e.options)}finally{r&&Ke(r)}}function F2(t,e,r){let n=r||{},o=a=>!!(n[a]||n["smbls."+a]),s=[],i=[];if(t.extends&&i.push(...Array.isArray(t.extends)?t.extends:[t.extends]),t.extend&&i.push(...Array.isArray(t.extend)?t.extend:[t.extend]),i.length){for(let a of i){if(typeof a!="string")continue;let c=a.includes(">")?a.split(">")[0].trim():a;o(c)||s.push(c)}return s}if(typeof e=="string"&&/^[A-Z]/.test(e)){let a=-1,c=e.indexOf("_"),l=e.indexOf(".");c>0&&(a=c),l>0&&(a<0||l<a)&&(a=l);let f=a>0?e.substring(0,a):e;o(f)||s.push(f)}return s}function N2(t,e,r){let n=!e,o=r.state&&typeof r.state=="object"&&!Array.isArray(r.state)&&Object.keys(r.state).length===0,s=n&&o&&t.context?.state,i=r.state!==void 0&&!s?r.state:t.state&&!kt(t.state)?t.state:void 0;if(i==null){if(e?.state)t.state=e.state,me(t,t.state);else if(t.context?.state){let a=t.context.state,c={...a},l=t.context?.polyglot;if(l?.translations){let f=t.context,u=a.lang||l.defaultLang||"en",d=new Set,g=(m,y)=>{d.has(m)||On(f,m,c)&&(c[m]=y,d.add(m),Je(f,m,y))},p=l.translations[u];if(p&&typeof p=="object")for(let m in p)g(m,p[m]);let h=new Set(l.languages||[]);for(let m in l.translations)h.has(m)||g(m,l.translations[m])}t.state=kt(c)?c:fr(c),t.state.__element=t,t.state.root=t.state,me(t,t.state),Fo?.(a,t.state)}else t.state={},Object.defineProperty(t.state,"root",{value:t.state,enumerable:!1,configurable:!0,writable:!0}),me(t,t.state);return}if(typeof i=="string"){if(t.state=$k(i,e),t.state&&typeof t.state=="object"&&!kt(t.state)){let a=e?.state?.root||e?.state||t.state;Object.defineProperty(t.state,"root",{value:a,enumerable:!1,configurable:!0,writable:!0})}me(t,t.state);return}if(typeof i=="function"){let a=i(t,e?.state);t.state=kt(a)?a:fr(a||{})}else kt(i)?t.state=i:t.state=fr({...i});t.state.__element=t,e?.state?(t.state.parent=e.state,t.state.root=e.state.root||e.state):t.state.root=t.state,me(t,t.state),Fo?.(i,t.state)}function sb(t,e){if(!e)return t;let r=e.split("/"),n=t;for(let o of r){if(n==null)return{};n=n[o]}return n??{}}function $k(t,e){if(!e)return{};if(t===".")return e.state||{};if(t.startsWith("../")){let o=t.slice(3);return o?sb(e.state,o):e.state??{}}if(t.startsWith("~/")){let o=e.state?.root||e.state,s=t.slice(2);return s?sb(o,s):o??{}}if(e.state?.[t]!==void 0)return e.state[t];let r=sb(e.state,t);if(r!=null&&Object.keys(r).length>0)return r;let n=e.context?.polyglot;if(n?.translations){let o=e.state?.root?.lang||n.defaultLang||"en",s=n.translations[o];if(s?.[t]!==void 0)return s[t];if(n.translations[t]!==void 0)return n.translations[t]}return{}}var j2=new Set(["s","state","ctx","context"]);function B2(t){try{let r=(typeof Le=="function"?Le(t):Function.prototype.toString.call(t)).match(/^[^(]*\(([^)]*)\)/);return r?r[1].split(",").map(n=>n.trim().split("=")[0].trim()).filter(Boolean):[]}catch{return[]}}function V2(t){if(typeof t!="function"||t.length!==2)return!1;let e=B2(t);if(e.length<2)return!1;let r=e[1].replace(/[{}[\]]/g,"").trim();return r.length>0&&!j2.has(r)}function U2(t){let e=t.__ref,r=t.tag||"div",n=t.context?.designSystem,o=[],s=Object.keys(t);for(let i=0;i<s.length;i++){let a=s[i];if(typeof t[a]!="function"||jt.has(a))continue;let c=a.charCodeAt(0);c>=65&&c<=90||Er(a)||wt[a]||Et&&Et.has(a)||Te(r,a)||(gt()&&V2(t[a])&&console.warn(`[smbls] custom prop "${a}"${t.key?` on key "${t.key}"`:""} is a function \u2014 it will be auto-invoked on read and its RETURN VALUE stored, not preserved as a callable reference. If you meant to stash a callback, use el.call('${a}', \u2026) instead of reading el.${a}(\u2026) directly (see RULES.md Rule 8).`),o.push({prop:a,fn:t[a]}))}for(let i=0;i<o.length;i++){let{prop:a,fn:c}=o[i];e.__exec[a]=c,Object.defineProperty(t,a,{get(){n&&ct(n);try{return c(t,t.state,t.context)}catch{return}finally{n&&it()}},set(l){delete e.__exec[a],Object.defineProperty(t,a,{value:l,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}}function z2(t,e){if(!(!Array.isArray(e)||e.length===0))for(let r=0;r<e.length;r++){let n=e[r];try{typeof n=="function"?n(t,t.state,t.context):typeof n=="string"&&t.state?.[n]}catch{}}}function Ft(t,e,r){return!Array.isArray(e)||e.length===0?r:function(...n){return z2(t,e),r.apply(this,n)}}function gc(t,e){if(!(!t||Array.isArray(t)||typeof t!="object"))return t[e]}function ft(t,e){return()=>t.path.join(".")+"::"+e}var dk=new Set;function Gt(t,e,r){if(!gt())return;let n=ft(t,e)();dk.has(n)||(dk.add(n),console.warn(`[smbls] "${e}" effect threw on ${t.path.join(".")} \u2014 keeping previous value:`,r?.message||r))}var pk=/(['"`])((?:\\.|(?!\1)[^\\])*)\1/g,H2=(t,e)=>{let r;try{r=String(t)}catch{return}if(!r.includes("{{"))return;pk.lastIndex=0;let n;for(;(n=pk.exec(r))!==null;)n[2].includes("{{")&&e.add(n[2])},W2=(t,e)=>!Er(t)&&!vs(e,t),hk=(t,e,r,n,o)=>{if(typeof e=="string"){!o&&e.includes("{{")&&r.add(e);return}typeof e=="function"&&W2(t,n)&&H2(e,r)},fb=new WeakMap,kc=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),_c=t=>{if(typeof t=="string"||typeof t=="number")return{text:t};if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t.props;return e&&typeof e=="object"&&!Array.isArray(e)?no(t,e):t},xc=(t,e)=>t&&e?no(t,e):t||e||null,Mk=(t,e)=>{let r=t.__ref&&t.__ref.__runtimeSource;return!!r&&kc(r,e)},Cs=(t,e)=>Mk(t,e)?_c(t.__ref.__runtimeSource[e]):null,wc=(t,e)=>(e&&t&&typeof t=="object"&&fb.set(t,e),t),q2=t=>{if(!t||typeof t!="object")return;let e=fb.get(t);return e&&fb.delete(t),e},ub=(t,e,r)=>{if(typeof t=="string"){t.includes("{{")&&e.add(t);return}if(!(!t||typeof t!="object"||r.has(t))){if(r.add(t),Array.isArray(t)){for(let n=0;n<t.length;n++)ub(t[n],e,r);return}if(!t.__ref)for(let n of Object.keys(t)){if(n==="state")continue;let o=Object.getOwnPropertyDescriptor(t,n);o&&"value"in o&&ub(o.value,e,r)}}},K2=(t,e)=>{let r=null;for(let n of Object.keys(t)){if(jt.has(n)||e&&kc(e,n))continue;let o=Object.getOwnPropertyDescriptor(t,n),s=o&&o.value;if(!Array.isArray(s))continue;let i=new Set;ub(s,i,new Set),i.size&&(r||(r=new Map),r.set(s,i))}return r},gk=(t,e)=>{if(Array.isArray(e))for(let r=t;r;r=r.parent){let n=r.__ref&&r.__ref.__declaredArrays,o=n&&n.get(e);if(!o)continue;let s=t.__ref;s.__authoredTemplates||(s.__authoredTemplates=new Set);for(let i of o)s.__authoredTemplates.add(i);return}},G2=["attr","aria","data","metadata"],Y2=t=>{if(G2.includes(t))return!0;let e=t.charCodeAt(0);return e===46||e===33||e===64},X2=(t,e)=>{let r=new Set,n=t.tag||"div";for(let o of Object.keys(t)){let s=Object.getOwnPropertyDescriptor(t,o),i=s&&s.value,a=!!e&&kc(e,o);if(i&&typeof i=="object"&&!Array.isArray(i)){if(!Y2(o))continue;let c=a?e[o]:null,l=c&&typeof c=="object"?c:null;for(let f in i){let u=a&&(!l||kc(l,f));hk(f,i[f],r,n,u)}continue}hk(o,i,r,n,a)}return r};function Fk(t,e){let r=t.__ref,n=!!(e&&e.skipIfEffect),o=X2(t,r.__runtimeSource);if(r.__authoredTemplates)for(let c of o)r.__authoredTemplates.add(c);else r.__authoredTemplates=o;if(U2(t),typeof t.text=="function"){let c=t.text,l=Ft(t,t.textDeps,c),f=Y(()=>{if(!r.contentManaged)try{let u=l(t,t.state,t.context);t.node&&u!=null&&typeof u!="function"&&typeof u!="object"&&(typeof u=="string"&&u.includes("{{")&&(u=Nt.call(t,u,t.state)),xs(t,u))}catch(u){Gt(r,"text",u)}},{depth:r.path.length,label:ft(r,"text")});r.__effects.push(f),r.__exec.text=c}else if(typeof t.text=="string"&&t.text.includes("{{")){let c=t.text,l=Y(()=>{if(r.contentManaged)return;let f=Nt.call(t,c,t.state);f!=null&&(t.text=f),t.node&&xs(t,f??"")},{depth:r.path.length,label:ft(r,"text")});r.__effects.push(l),r.__exec.text=c}let s=t.tag||"div";for(let c of Object.keys(t))if(typeof t[c]=="function"&&!jt.has(c)&&!Er(c)&&!r.__exec[c]&&!Lu(s,c)){if(wt[c]){let l=t[c],f=Ft(t,t[c+"Deps"],l),u=c,d,g=null,p=null,h,m=Y(()=>{let y=t.context?.designSystem;y&&ct(y);try{let x=f(t,t.state,t.context);wu();let b;try{b=wt[u](x,t,t.state,t.context)}finally{Su()}if(Array.isArray(b)){let w={};for(let S of b)if(S)for(let E in S)w[E]=S[E];b=w}let _=u==="show"||u==="hide";if(b&&t.node&&Z2(b)){let w=Mu(b);if(w===null||w!==h){h=w;let S=he(b,null,t.context?.cssPrefix),E=S?S.split(" ").filter(Boolean):null;if(t.node.classList){if(p)for(let O of p)t.node.classList.remove(O);if(E&&E.length)for(let O of E)t.node.classList.add(O);p=E}}d=void 0,g=null}else if(b&&t.node){if(p){for(let S of p)t.node.classList.remove(S);p=null,h=void 0}let w=Mu(b);if(w===null||w!==d||!$u(t.node,g)){d=w;let S=bk(t,b);g=Iu(t.node,S)}}else t.node&&_&&(d=void 0,g=null,t.node.style.display="")}finally{y&&it()}},{depth:r.path.length,label:ft(r,u)});r.__effects.push(m),r.__exec[c]=l}else if(Et&&Et.has(c)){let l=t[c],f=Ft(t,t[c+"Deps"],l),u=c,d,g=null,p=Y(()=>{let h=t.context?.designSystem;h&&ct(h);try{let m=f(t,t.state,t.context);if(t.node)if(m!=null){let y=u+":"+String(m);if(y!==d||!$u(t.node,g)){d=y;let x={[u]:m},b=bk(t,x);g=Iu(t.node,b)}}else d=void 0,g=null,t.node.style[u]=""}finally{h&&it()}},{depth:r.path.length,label:ft(r,u)});r.__effects.push(p),r.__exec[c]=l}}if(typeof t.html=="function"){let c=t.html,l=Ft(t,t.htmlDeps,c),f=Y(()=>{let u=t.context?.designSystem;u&&ct(u);try{let d=l(t,t.state,t.context);t.node&&d!=null&&typeof d!="function"&&(t.node.innerHTML=d)}finally{u&&it()}},{depth:r.path.length,label:ft(r,"html")});r.__effects.push(f),r.__exec.html=c}if(typeof t.value=="function"){let c=t.value,l=Ft(t,t.valueDeps,c),f=Y(()=>{try{let u=l(t,t.state,t.context);typeof u=="string"&&u.includes("{{")&&(u=Nt.call(t,u,t.state)),yk(t,u)}catch(u){Gt(r,"value",u)}},{depth:r.path.length,label:ft(r,"value")});r.__effects.push(f),r.__exec.value=c}else if(typeof t.value=="string"&&t.value.includes("{{")){let c=t.value,l=Y(()=>{try{yk(t,Nt.call(t,c,t.state))}catch(f){Gt(r,"value",f)}},{depth:r.path.length,label:ft(r,"value")});r.__effects.push(l),r.__exec.value=c}if(typeof t.style=="function"){let c=t.style,l=Ft(t,t.styleDeps,c),f,u=null,d=Y(()=>{let g=l(t,t.state,t.context),p=Mu(g);(p===null||p!==f||!$u(t.node,u))&&(f=p,J2(t.node,u,g),ro(t.node,g),u=Iu(t.node,g))},{depth:r.path.length,label:ft(r,"style")});r.__effects.push(d),r.__exec.style=c}else if(t.style&&typeof t.style=="object")for(let c in t.style){let l=t.style[c];if(typeof l!="function")continue;let f=Ft(t,gc(t.styleDeps,c),l),u,d=null,g=Y(()=>{try{let p=f(t,t.state,t.context);if(t.node){let h=c+":"+String(p);if(h!==u||!$u(t.node,d)){u=h;let m={[c]:p};ro(t.node,m),d=Iu(t.node,m)}}}catch(p){Gt(r,"style."+c,p)}},{depth:r.path.length,label:ft(r,"style."+c)});r.__effects.push(g)}if(t.attr&&typeof t.attr=="object"){for(let c in t.attr)if(typeof t.attr[c]=="function"){let l=Ft(t,gc(t.attrDeps,c),t.attr[c]),f=c,u=Y(()=>{try{let d=l(t,t.state,t.context);typeof d=="string"&&d.includes("{{")&&(d=Nt.call(t,d,t.state)),t.node?.setAttribute&&(d==null||d===!1&&!sr(f)?t.node.removeAttribute(f):typeof d!="function"&&typeof d!="object"&&t.node.setAttribute(f,re(f,d)))}catch(d){Gt(r,"attr."+f,d)}},{depth:r.path.length,label:ft(r,"attr."+f)});u._attrName=f.toLowerCase(),r.__effects.push(u)}else if(typeof t.attr[c]=="string"&&t.attr[c].includes("{{")){let l=t.attr[c],f=c,u=Y(()=>{try{let d=Nt.call(t,l,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(f,re(f,d??""))}catch(d){Gt(r,"attr."+f,d)}},{depth:r.path.length,label:ft(r,"attr."+f)});u._attrName=f.toLowerCase(),r.__effects.push(u)}}if(t.aria&&typeof t.aria=="object")for(let c in t.aria){let l=t.aria[c];if(typeof l=="string"&&l.includes("{{")){let g=l,p="aria-"+c.replace(/[A-Z]/g,m=>"-"+m.toLowerCase()),h=Y(()=>{try{let m=Nt.call(t,g,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(p,re(p,m??""))}catch(m){Gt(r,"aria."+c,m)}},{depth:r.path.length,label:ft(r,"aria."+c)});h._attrName=p,r.__effects.push(h);continue}if(typeof l!="function")continue;let f=Ft(t,gc(t.ariaDeps,c),t.aria[c]),u="aria-"+c.replace(/[A-Z]/g,g=>"-"+g.toLowerCase()),d=Y(()=>{try{let g=f(t,t.state,t.context);if(!t.node?.setAttribute)return;g==null?t.node.removeAttribute(u):typeof g!="function"&&typeof g!="object"&&t.node.setAttribute(u,re(u,g))}catch(g){Gt(r,"aria."+c,g)}},{depth:r.path.length,label:ft(r,"aria."+c)});d._attrName=u,r.__effects.push(d)}if(t.data&&typeof t.data=="object")for(let c in t.data){let l=t.data[c];if(typeof l=="string"&&l.includes("{{")){let p=l,h="data-"+c.replace(/[A-Z]/g,y=>"-"+y.toLowerCase()),m=Y(()=>{try{let y=Nt.call(t,p,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(h,y??"")}catch(y){Gt(r,"data."+c,y)}},{depth:r.path.length,label:ft(r,"data."+c)});m._attrName=h,r.__effects.push(m);continue}if(typeof l!="function")continue;let f=Ft(t,gc(t.dataDeps,c),t.data[c]),d="data-"+c.replace(/[A-Z]/g,p=>"-"+p.toLowerCase()),g=Y(()=>{try{let p=f(t,t.state,t.context);if(!t.node?.setAttribute)return;p==null||p===!1?t.node.removeAttribute(d):typeof p!="function"&&typeof p!="object"&&t.node.setAttribute(d,p===!0?"":p)}catch(p){Gt(r,"data."+c,p)}},{depth:r.path.length,label:ft(r,"data."+c)});g._attrName=d,r.__effects.push(g)}let i=t.classlist&&typeof t.classlist=="object"&&!Array.isArray(t.classlist)?t.classlist:t.class&&typeof t.class=="object"&&!Array.isArray(t.class)?t.class:null;if(i)for(let c in i){if(typeof i[c]!="function")continue;let l=Ft(t,gc(t.classDeps,c),i[c]),f=Y(()=>{try{let u=l(t,t.state,t.context);if(!t.node?.classList)return;typeof u=="string"?t.node.classList.add(u):u?t.node.classList.add(c):t.node.classList.remove(c)}catch(u){Gt(r,"class."+c,u)}},{depth:r.path.length,label:ft(r,"class."+c)});r.__effects.push(f)}!n&&typeof t.if=="function"&&Nk(t,r,t.if);for(let c of Object.keys(t)){if(jt.has(c)||typeof t[c]!="function")continue;let l=c.charCodeAt(0);if(l>=65&&l<=90||Er(c))continue;let f=t[c];r.__exec[c]=f;let u=t.tag||"div";if(Te(u,c)&&!vs(u,c)){let d=or(c)||c,g=Ft(t,t[c+"Deps"],f),p=Y(()=>{try{let h=g(t,t.state,t.context);typeof h=="string"&&h.includes("{{")&&(h=Nt.call(t,h,t.state)),t.node?.setAttribute&&(h==null||h===!1&&!sr(d)?t.node.removeAttribute(d):typeof h!="function"&&typeof h!="object"&&(d==="src"&&"src"in t.node?t.node.src=h:t.node.setAttribute(d,re(d,h))))}catch(h){Gt(r,c,h)}},{depth:r.path.length,label:ft(r,c)});p._attrName=d.toLowerCase(),r.__effects.push(p)}}let a=t.tag||"div";for(let c of Object.keys(t)){if(jt.has(c))continue;let l=t[c];if(typeof l!="string"||!l.includes("{{"))continue;let f=c.charCodeAt(0);if(f>=65&&f<=90||Er(c)||vs(a,c)||Qn[c]||!Te(a,c))continue;let u=or(c)||c,d=Y(()=>{try{let g=Nt.call(t,l,t.state);if(!t.node||!t.node.setAttribute)return;t.node.setAttribute(u,re(u,g??""))}catch(g){Gt(r,c,g)}},{depth:r.path.length,label:ft(r,c)});d._attrName=u.toLowerCase(),r.__effects.push(d)}if(oD(t),cD(t),typeof t.onStateUpdate=="function"&&Array.isArray(t.stateDeps)){let c=t.onStateUpdate,l=t.stateDeps,f=!1,u=[],d=Y(()=>{let g=[];for(let y=0;y<l.length;y++){let x=l[y];try{g[y]=typeof x=="function"?x(t,t.state,t.context):t.state?.[x]}catch{g[y]=void 0}}if(!f){f=!0,u=g;return}let p=g.length!==u.length;for(let y=0;!p&&y<g.length;y++)g[y]!==u[y]&&(p=!0);let h=u;if(u=g,!p)return;let m=t.context?.designSystem;m&&ct(m);try{c(t,t.state,t.context,{prev:h,next:g})}catch(y){if(t.context?.plugins?.length&&Ot("error",t,{hook:"onStateUpdate",error:y})||console.error('[DOMQL] Lifecycle "onStateUpdate" error:',y),t.context?.strictMode)throw y}finally{m&&it()}},{depth:r.path.length,label:ft(r,"onStateUpdate")});r.__effects.push(d)}aD(t)}function mk(t){let e=t.parent,r=e?.node;if(!r||!t.node){Xk(t,t.parent);return}let n=null,o=Object.keys(e),s=o.indexOf(t.key);for(let i=s+1;i<o.length;i++){let a=e[o[i]];if(a?.node?.parentNode===r){n=a.node;break}}n?r.insertBefore(t.node,n):r.appendChild(t.node)}function Nk(t,e,r){let n=Ft(t,t.ifDeps,r),o=Y(()=>{let s=!e.__ifInitialized&&e.__ifLateMerge;if(s){let c=t.context?.components||{};s.names.some(l=>c[l]||c["smbls."+l])&&(e.__ifLateMerge=null,M2(t,s),n=Ft(t,t.ifDeps,typeof t.if=="function"?t.if:r))}let i;try{i=n(t,t.state,t.context)}catch(c){if(i=!1,e.__ifError=c,typeof console<"u"&&console.warn){let l=t.key||t.tag||"?";console.warn(`[smbls] \`if:\` reactive effect threw on ${l} \u2014 treating as false:`,c?.message||c)}return}let a=e.__if;if(e.__if=!!i,a&&!e.__if&&t.node){t.node.remove();try{typeof t.onRemove=="function"&&t.onRemove(t)}catch(c){console.error("[smbls] onRemove error:",c)}}else if(!a&&e.__if)if(e.__ifInitialized)t.node||(t.node=en(t)),t.node&&(t.node.ref=t),mk(t),db(t),ie("Render",t,{}),cb(t,{});else{if(e.__ifInitialized=!0,e.__ifLateMerge=null,t.tag||(t.tag=tn(t)),ie("Init",t,{}),t.node||(t.node=en(t)),!t.node)return;if(t.parent?.__ref?.__children&&!t.parent.__ref.__children.includes(t.key)&&t.parent.__ref.__children.push(t.key),t.tag==="fragment"&&!e.__fragmentAnchor){let l=(t.context?.document||globalThis.document).createComment("");t.node.appendChild(l),e.__fragmentAnchor=l}ie("AttachNode",t,{}),t.node.setAttribute&&t.key&&t.node.setAttribute("data-key",t.key),t.id&&t.node.setAttribute&&(t.node.id=t.id),Gk(t,{}),Fk(t,{skipIfEffect:!0}),db(t),Wk(t),qk(t),Yk(t,{}),mk(t),ie("Create",t,{}),ie("Complete",t,{}),ie("Render",t,{}),ie("RenderRouter",t,{}),cb(t,{})}},{depth:e.path.length,label:ft(e,"if")});e.__effects.push(o)}function xs(t,e){let r=t.node;if(!r)return;let n=e==null||typeof e=="object"?"":String(e);if(t.tag==="string"){r.nodeValue!==n&&(r.nodeValue=n);return}let o=t.__ref,s=o?o.__textNode:null;if(s&&s.parentNode!==r&&(s=null),!s){let i=r.firstChild;i&&i.nodeType===3&&(s=i)}s?s.nodeValue!==n&&(s.nodeValue=n):r.firstChild?(s=(r.ownerDocument||t.context?.document||globalThis.document).createTextNode(n),r.insertBefore(s,r.firstChild)):(r.textContent=n,s=r.firstChild&&r.firstChild.nodeType===3?r.firstChild:null),o&&(o.__textNode=s||null)}function yk(t,e){let r=t.node;if(!r||!("value"in r))return;let n=e==null?"":String(e);if(r.value===n)return;let o=typeof document<"u"&&document.activeElement===r,s=o&&typeof r.selectionStart=="number"?r.selectionStart:null,i=o&&typeof r.selectionEnd=="number"?r.selectionEnd:null;if(r.value=n,o&&s!=null&&i!=null)try{r.setSelectionRange(s,i)}catch{}let a=t.__ref&&t.__ref.__autoGrow;a&&a.active&&a.resize()}function db(t){let{node:e}=t;if(e){if((typeof t.text=="string"&&!t.text.includes("{{")||typeof t.text=="number")&&xs(t,t.text),Hk(t),typeof t.html=="string"&&(e.innerHTML=t.html),t.value!=null&&typeof t.value!="function"&&!(typeof t.value=="string"&&t.value.includes("{{"))&&"value"in e){let r=String(t.value);e.value!==r&&(e.value=r)}if(t.style&&typeof t.style=="object"){let r=t.style;for(let n in t.style)if(typeof t.style[n]=="function"){r={};for(let o in t.style)typeof t.style[o]!="function"&&(r[o]=t.style[o]);break}ro(e,r)}if(t.attr&&typeof t.attr=="object")for(let r in t.attr){let n=t.attr[r];typeof n=="function"||typeof n=="object"||n!=null&&(typeof n=="string"&&n.includes("{{")||n===!1&&!sr(r)||e.setAttribute&&e.setAttribute(r,re(r,n)))}if(typeof t.themeModifier=="string"&&t.themeModifier&&e.setAttribute&&e.setAttribute("data-theme",t.themeModifier),t.data&&typeof t.data=="object")for(let r in t.data){let n=t.data[r];typeof n=="function"||typeof n=="object"||n==null||n===!1||typeof n=="string"&&n.includes("{{")||e.dataset&&(e.dataset[r]=n===!0?"":n)}if(t.classlist||t.class){let r=t.classlist||t.class;if(typeof r=="string")r.split(" ").forEach(n=>n&&e.classList.add(n));else if(typeof r=="object")for(let n in r){let o=typeof r[n]=="function"?r[n](t,t.state,t.context):r[n];o&&e.classList.add(typeof o=="string"?o:n)}}}}function Mu(t){if(t==null||typeof t!="object")return"s:"+String(t);try{return"o:"+JSON.stringify(t)}catch{return null}}function Z2(t){if(!t||typeof t!="object")return!1;for(let e in t){let r=t[e];if(r&&typeof r=="object"&&!Array.isArray(r))return!0}return!1}function Iu(t,e){if(!t||!t.style||!e)return null;let r=t.style,n=[];for(let o in e){if(e[o]==null||o.charAt(0)==="&")continue;let i=Uu(o);n.push(i,yb(r,i),jk(r,i))}return n}function yb(t,e){return typeof t.getPropertyValue=="function"?t.getPropertyValue(e):""}function jk(t,e){return typeof t.getPropertyPriority=="function"?t.getPropertyPriority(e):""}function Uu(t){return Nu(t)?t:t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function J2(t,e,r){if(!t||!t.style||!e||!e.length)return;let n=t.style,o=new Set;if(r&&typeof r=="object")for(let s in r)r[s]==null||s.charAt(0)==="&"||o.add(Uu(s));for(let s=0;s<e.length;s+=3){let i=e[s];o.has(i)||yb(n,i)===e[s+1]&&typeof n.removeProperty=="function"&&n.removeProperty(i)}}function $u(t,e){if(!e||!t||!t.style)return!1;let r=t.style;for(let n=0;n<e.length;n+=3)if(yb(r,e[n])!==e[n+1]||jk(r,e[n])!==e[n+2])return!1;return!0}var Nu=t=>t.charCodeAt(0)===45&&t.charCodeAt(1)===45;function Q2(t){let e=null;for(let r in t)t[r]!=null&&r.charAt(0)!=="&"&&(e||(e=new Set),e.add(Uu(r)));return e}function tD(t,e,r,n){let o=t.__ref;if(!o)return;let s=null;if(r)for(let i of r){if(n&&n.has(i))continue;let a=e[i];if(a==null||typeof a=="object")continue;let c=Uu(i);hc[c]&&(s||(s={}),s[c]=a)}o.__declaredLonghands=s}function Bk(t,e){let r=t.__ref,n=r&&r.__declaredLonghands;if(!n||!e)return null;let o=null;for(let s in n){if(e.has(s))continue;let i=hc[s],a=!1;for(let c=0;c<i.length;c++)if(e.has(i[c])){a=!0;break}a&&(o||(o={}),o[s]=n[s])}return o}function bk(t,e){let r=t.node;ro(r,e);let n=Q2(e);if(!n)return e;let o=t.__ref;if(o)if(o.__inlineCssKeys)for(let i of n)o.__inlineCssKeys.add(i);else o.__inlineCssKeys=new Set(n);let s=Bk(t,n);return s?(ro(r,s),Object.assign({},e,s)):e}function eD(t){let e=t.__ref;if(!e||!e.__inlineCssKeys||!e.__declaredLonghands)return;let r=Bk(t,e.__inlineCssKeys);r&&ro(t.node,r)}function ro(t,e){if(!t||!e||!t.style)return;let r=null;for(let n in e){let o=e[n];if(o!=null){if(n.charAt(0)==="&"&&typeof o=="object"){r||(r={}),r[n]=o;continue}try{let s=String(o),i=Nu(n)?n:n.replace(/[A-Z]/g,f=>"-"+f.toLowerCase()),a=s.trim(),c=/\s*!important\s*$/.test(a),l=a.replace(/\s*!important\s*$/,"");t.style.setProperty(i,l,c?"important":"")}catch{}}}r&&rD(t,r)}function rD(t,e){let r=`_ds${Tk.scopedStyleId++}`;t.classList.add(r);let n=t.ownerDocument,o=n.querySelector("style[data-smbls-scoped]");o||(o=n.createElement("style"),o.setAttribute("data-smbls-scoped",""),n.head.appendChild(o));let s="";for(let i in e){let a="."+r,c=i.replace(/&/g,a).split(",").map(f=>{let u=f.trim();return u.includes(a)?u:a+u}).join(", "),l=e[i];if(typeof l=="object"){let f="",u="";for(let d in l){let g=l[d];if(typeof g=="object"){let p=d.includes("&")?c.split(", ").map(m=>d.replace(/&/g,m)).join(", "):c.split(", ").map(m=>`${m} ${d}`).join(", "),h="";for(let m in g)h+=`${m.replace(/[A-Z]/g,y=>"-"+y.toLowerCase())}: ${g[m]};`;u+=Sr(`${p} { ${h} }`,p)+`
57
+ `}else f+=`${d.replace(/[A-Z]/g,p=>"-"+p.toLowerCase())}: ${g};`}f&&(s+=Sr(`${c} { ${f} }`,c)+`
58
+ `),u&&(s+=u)}}s&&(o.textContent+=s)}var _k=new Set;function xk(t){if(!Array.isArray(t))return"";let e=[];for(let r=0;r<t.length;r++)typeof t[r]=="string"&&t[r].length&&e.push(t[r]);return e.sort(),e.join("|")}function nD(t,e,r){let n=xk(r);queueMicrotask(()=>{if(!t.__ref)return;let o;try{o=e(t,t.state,t.context)}catch{return}if(xk(o)===n)return;let s=t.__ref.path?t.__ref.path.join("."):t.key||"?";_k.has(s)||(_k.add(s),console.warn(`[smbls] subscribeTo function at "${s}" resolved to a DIFFERENT key list one microtask after create \u2014 wired [${r.join(", ")||"(none)"}], probed [${Array.isArray(o)?o.join(", "):String(o)}]. subscribeTo's function form is resolved ONCE at element-create time (registerSubscribeToEffects, @symbo.ls/element create.js) \u2014 this element stays wired to the ORIGINAL list for its whole lifetime, so this drift is invisible to the reactive effect and any key only present in the new list will never trigger onUpdate. If the watched key genuinely is not known until later (e.g. a module config that loads after shell boot), route the write through an imperative call instead of subscribeTo \u2014 see functions/moduleOpenBridge.js's moduleOpenPage (workspace repo) for the house pattern.`))})}function oD(t){let e=t.subscribeTo,r=typeof e=="function",n=e;if(r)try{n=e(t,t.state,t.context)}catch{n=null}if(r&&gt()&&nD(t,e,Array.isArray(n)?n:[]),!Array.isArray(n)||n.length===0)return;let o=t.__ref;for(let s=0;s<n.length;s++){let i=n[s];if(typeof i!="string"||i.length===0)continue;let a=i.split("."),c=a[0],l=a.slice(1),f={value:!1},u=Y(()=>{let d=t.state&&(kt(t.state)?t.state.root:null);if(!d||!kt(d))return;let g=d;g=g[c];for(let h=0;h<l.length&&!(g==null||typeof g!="object");h++)if(kt(g))g=g[l[h]];else break;if(!f.value)return;let p=!1;if(typeof t.onBeforeUpdate=="function"){let h=t.context?.designSystem;h&&ct(h);try{if(Dy(o)){let m=t.onBeforeUpdate(t,t.state,t.context,{updateBySubscription:!0});m&&typeof m.then=="function"?m.then(()=>kr(o,!1),y=>{kr(o,!0),t.context?.plugins?.length&&Ot("error",t,{hook:"onBeforeUpdate",error:y})||console.error("[DOMQL] subscribeTo onBeforeUpdate error:",y)}):(kr(o,!1),m===!1&&(p=!0))}}catch(m){kr(o,!0),t.context?.plugins?.length&&Ot("error",t,{hook:"onBeforeUpdate",error:m})||console.error("[DOMQL] subscribeTo onBeforeUpdate error:",m)}finally{h&&it()}}if(!p&&t.node&&o.__effects)for(let h=0;h<o.__effects.length;h++){let m=o.__effects[h];m&&m!==u&&!m._disposed&&!m._isSubscribeToEffect&&typeof m._execute=="function"&&m._execute()}if(!p&&typeof t.onUpdate=="function"){let h=t.context?.designSystem;h&&ct(h);try{t.onUpdate(t,t.state,t.context)}catch(m){t.context?.plugins?.length&&Ot("error",t,{hook:"onUpdate",error:m})||console.error("[DOMQL] subscribeTo onUpdate error:",m)}finally{h&&it()}}},{depth:o.path.length,label:ft(o,"subscribeTo("+i+")")});f.value=!0,u._isSubscribeToEffect=!0,o.__effects.push(u)}}function bb(t,e){return t.charCodeAt(0)===64&&t.length>1&&!t.startsWith("@media")&&!t.startsWith("@keyframes")&&!t.startsWith("@supports")&&!t.startsWith("@container")&&(t==="@dark"||t==="@light"||!e.context?.designSystem?.media?.[t.slice(1)])}function _b(t,e){if(t.charCodeAt(0)!==64||/^@(media|supports|container|keyframes)\b/.test(t))return t;let r=e.context?.designSystem?.media?.[t.slice(1)];return r?/^@(media|supports|container)\b/.test(r)?r:`@media ${r}`:t}var wk=new Set;function sD(t,e){let r=e?.__ref?.path?e.__ref.path.join("."):e?.key||"?",n=r+"::"+t;wk.has(n)||(wk.add(n),console.warn(`[smbls/css] "${t}" at ${r} is a CHILD-COMPONENT key nested inside a pseudo/selector block (":hover", "@dark", etc.) \u2014 that is never a valid CSS selector fragment. The rule is DROPPED (not shipped as a dead/never-matching selector). To reveal a child on a parent state, target the child's OWN class from the parent selector instead, e.g. move the declaration onto the child element itself, or use a sibling-selector combinator in a top-level style block.`))}function Ts(t,e,r,n){let o={},s=new Set,i=(a,c,l)=>{let f=l?new Set(Object.keys(o)):null;if(wt[a]){let u=wt[a](c,e,e.state,e.context);if(u){let d=Array.isArray(u)?u:[u];for(let g of d)g&&Object.assign(o,g)}}else o[a]=c;if(l)for(let u in o)f.has(u)||s.add(u)};for(let a in t){if(!Object.prototype.hasOwnProperty.call(t,a))continue;let c=t[a];if(typeof c=="function"&&(c=c(e,e.state,e.context)),c==null||typeof c=="function")continue;if(typeof c=="object"&&!Array.isArray(c)){if(a==="style"){for(let g in c){let p=c[g];if(typeof p=="function"&&(p=p(e,e.state,e.context)),p==null||typeof p=="function")continue;let h=typeof e[g]=="function"&&(wt[g]||Et&&Et.has(g))||!!(n&&n.has(g));i(g,p,h)}continue}if(bb(a,e)){let g=Ts(c,e,!1,n);Object.keys(g).length&&(o[`[data-theme="${a.slice(1)}"] &`]=g);continue}if(/^[A-Z][A-Za-z0-9]*$/.test(a)){gt()&&sD(a,e);continue}let u=_b(a,e),d=Ts(c,e,!1,n);Object.keys(d).length&&(o[u]=d);continue}let l=typeof e[a]=="function"&&(wt[a]||Et&&Et.has(a)),f=!!(n&&n.has(a));i(a,c,l||f)}if(r)for(let a in o)s.add(a);for(let a of s){let c=o[a];typeof c=="string"&&!c.includes("!important")&&(o[a]=c+" !important")}return o}var ju=t=>!!t&&typeof t=="object"&&!Array.isArray(t);function Vk(t,e){for(let r in e){let n=e[r];t[r]=ju(n)?Vk(ju(t[r])?t[r]:{},n):n}return t}function iD(t,e){if(!ju(e))return;let r;for(let n of t.split(" ")){let o=n?e[n]:null;ju(o)&&(r=Vk(r||{},o))}return r}function xb(t,e){if(e===void 0&&(e=0),e>8)return!1;if(typeof t=="function")return!0;if(t&&typeof t=="object"&&!Array.isArray(t)){for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&xb(t[r],e+1))return!0}return!1}function Uk(t,e,r){if(!e||typeof e!="object"||Array.isArray(e))return null;if(bb(t,r)){let s=Ts(e,r,!1);return Object.keys(s).length?{cssProp:`[data-theme="${t.slice(1)}"] &`,block:s}:null}let n=_b(t,r),o=Ts(e,r,!1);return Object.keys(o).length?{cssProp:n,block:o}:null}function aD(t){let e=t.__ref;for(let r of Object.keys(t)){if(!lb(r))continue;let n=t[r];if(!n||typeof n!="object"||Array.isArray(n)||!xb(n))continue;let o=null,s,i=Y(()=>{if(!t.node)return;let a=t.context?.designSystem;a&&ct(a);let c,l=!1;try{let f=Uk(r,n,t),u=f?Mu(f.block)+"::"+f.cssProp:null;if(u!==null&&u===s)l=!0;else if(s=u,f){let d=he({[f.cssProp]:f.block},null,t.context?.cssPrefix);c=d?d.split(" ").filter(Boolean):null}else c=null}finally{a&&it()}if(!(l||!t.node.classList)){if(o)for(let f of o)t.node.classList.remove(f);if(c&&c.length)for(let f of c)t.node.classList.add(f);o=c}},{depth:e.path.length,label:ft(e,"cssBlock("+r+")")});e.__effects.push(i)}}function cD(t){let e=t.__ref;e.__conditionalRunners=[];let r=new Map;for(let n of Object.keys(t)){let o=n.charAt(0);if(o!=="."&&o!=="!")continue;let s=n.slice(1);if(!s)continue;if(/[:@\s>~+[\]]/.test(s)){if(typeof console<"u"&&console.warn){let p=s.split(/[:@\s>~+[\]]/)[0];console.warn(`[smbls] conditional \`${n}\` on ${t.key||"?"} will never match \u2014 the whole string after \`${o}\` is read as one prop name. Nest the selector inside instead: \`${o}${p}: { '${s.slice(p.length)}': {...} }\`.`)}continue}let i=t[n];if(!i||typeof i!="object")continue;let a=o==="!",c={lastMatch:!1,appliedKeys:null,appliedClasses:null},l=new Set;for(let p in i){if(!Object.prototype.hasOwnProperty.call(i,p))continue;let h=p.charAt(0),m=i[p];(h===":"||h==="@"||h==="&"||h==="[")&&m&&typeof m=="object"&&!Array.isArray(m)||l.add(p)}let f=()=>{let p,h=t[s];if(h===void 0){let x=!!t.state&&s in t.state,b=t.state?t.state[s]:void 0;if(x||b!==void 0)p=b;else{let _=t.context?.cases?.[s];if(_===void 0)return;try{p=typeof _=="function"?_.call(t,t):_}catch(w){p=!1,e.__conditionalError=w,typeof console<"u"&&console.warn&&console.warn(`[smbls] conditional \`${n}\` case fn threw on ${t.key||"?"} \u2014 treating as false:`,w?.message||w)}}}else if(typeof h=="function")try{p=h(t,t.state,t.context)}catch(x){p=!1,e.__conditionalError=x,typeof console<"u"&&console.warn&&console.warn(`[smbls] conditional \`${n}\` predicate threw on ${t.key||"?"} \u2014 treating as false:`,x?.message||x)}else p=h;let m=a?!p:!!p;if(!t.node||m===c.lastMatch)return;c.lastMatch=m;let y=t.context?.designSystem;y&&ct(y);try{if(m){let x={},b={},_=!1;for(let S in i){if(!Object.prototype.hasOwnProperty.call(i,S))continue;let E=i[S],O=S.charAt(0);if((O===":"||O==="@"||O==="&"||O==="[")&&E&&typeof E=="object"&&!Array.isArray(E)){if(bb(S,t)){let T=Ts(E,t,!1,l);Object.keys(T).length&&(b[`[data-theme="${S.slice(1)}"] &`]=T,_=!0)}else{let T=_b(S,t),M=Ts(E,t,!1,l);Object.keys(M).length&&(b[T]=M,_=!0)}continue}let L=typeof E=="function"?E(t,t.state,t.context):E;if(L!=null)if(wt[S]){let T=wt[S](L,t,t.state,t.context);if(T){let M=Array.isArray(T)?T:[T];for(let U of M)U&&Object.assign(x,U)}}else(Et&&Et.has(S)||Nu(S))&&(x[S]=L)}let w=Object.keys(x);if(w.length){ro(t.node,x);for(let S of w)r.set(S,n);c.appliedKeys=w}else c.appliedKeys=null;if(_){let S=he(b,null,t.context?.cssPrefix,{state:!0}),E=S?S.split(" ").filter(Boolean):[];if(E.length&&t.node.classList){for(let O of E)t.node.classList.add(O);c.appliedClasses=E}else c.appliedClasses=null}else if(c.appliedClasses){for(let S of c.appliedClasses)t.node.classList.remove(S);c.appliedClasses=null}}else{if(c.appliedKeys){for(let x of c.appliedKeys)r.get(x)===n&&(Nu(x)?t.node.style.removeProperty(x):t.node.style[x]="",r.delete(x));c.appliedKeys=null}if(c.appliedClasses){for(let x of c.appliedClasses)t.node.classList.remove(x);c.appliedClasses=null}}}finally{y&&it()}};e.__conditionalRunners.push(f);let u=Ft(t,t[s+"Deps"],f),d=Y(u,{depth:e.path.length,label:ft(e,"conditional("+n+")")}),g=e.__exec&&e.__exec[s]||t[s];d._sources.size===0&&typeof g=="function"&&gt()&&console.warn(`[smbls] conditional \`${n}\` on ${t.key||"?"} subscribed to nothing \u2014 its predicate tracked no reactive read on its first run, so no state write will ever re-evaluate it (only a direct element.update() on this element re-runs it). If the predicate guards its state reads (\`in\`, short-circuits, \`?.\`), declare \`${s}Deps: [...]\` (state-key strings or \`(el, s) => \u2026\` selectors) so the subscription is armed unconditionally.`),e.__effects.push(d)}}var ib=new WeakSet;function lD(t){let e=t.ownerDocument;!e||ib.has(e)||(ib.add(e),queueMicrotask(()=>{ib.delete(e);let r=e.body||e.documentElement;r&&r.offsetWidth}))}var ab=new WeakSet,Sk=!1;function kk(t){return t.startsWith("[data-theme=")||t.startsWith("@media")&&t.includes("prefers-color-scheme")}function pb(t,e){let r={...t};for(let n in e){let o=e[n],s=r[n];r[n]=o&&typeof o=="object"&&s&&typeof s=="object"?pb(s,o):o}return r}function zk(t,e){let r={};for(let n in t){let o=t[n];if(o&&typeof o=="object"){let s=zk(o,e);Object.keys(s).length&&(r[n]=s)}else e.has(n)||(r[n]=o)}return r}function Hk(t){let{node:e}=t;if(!e)return;if(Sk||(Sk=!0,he({display:"none"})),ab.has(t)){console.error("[applyCssInProps] re-entry detected for element",t.key,"prop path:",t.__ref?.path);return}ab.add(t);let r=t.context?.designSystem;r&&ct(r),wu();try{let n={},o=!1,s=[],i=null,a=null,c=null,l=(p,h)=>{if(h&&typeof h=="object"&&kk(p)){a||(a={});let m=a[p];m&&(h=pb(m,h)),a[p]=h}else(h===null||typeof h!="object")&&(c||(c=new Set),c.add(p));n[p]=h};if(Object.prototype.hasOwnProperty.call(t,"theme")&&typeof t.theme!="function"&&wt.theme){let p=wt.theme(t.theme,t,t.state,t.context);if(p){let h=m=>{for(let y in m){let x=m[y];x&&typeof x=="object"&&kk(y)&&(i||(i={}),i[y]=x),n[y]=x}};if(Array.isArray(p))for(let m of p)m&&h(m);else h(p);o=!0}}let f=(p,h)=>{if(wt[p]){let m=wt[p](h,t,t.state,t.context);if(m){if(Array.isArray(m)){for(let y of m)if(y)for(let x in y)l(x,y[x])}else for(let y in m)l(y,m[y]);o=!0}}else if(Et&&Et.has(p))h!=null&&typeof h!="object"&&(l(p,h),o=!0);else if(p.charCodeAt(0)===45)h!=null&&typeof h!="object"&&(l(p,h),o=!0);else if((p.charAt(0)==="&"||p.charAt(0)==="@"||p.charAt(0)===":"||p.charAt(0)==="[")&&h&&typeof h=="object"&&!Array.isArray(h)){if(xb(h))return;let m=Uk(p,h,t);m&&(l(m.cssProp,m.block),o=!0)}};if(typeof t.class=="string"){let p=iD(t.class,t.context?.designSystem?.class);if(p)for(let h in p)f(h,p[h])}let u=c?new Set(c):null,d=t.tag||"div";for(let p of Object.keys(t)){if(typeof t[p]=="function"||jt.has(p)||p==="theme")continue;let h=p.charCodeAt(0);h>=65&&h<=90||Er(p)||Lu(d,p)||f(p,t[p])}if(i)for(let p in i){let h=c?zk(i[p],c):i[p];a&&a[p]&&(h=pb(h,a[p])),Object.keys(h).length?n[p]=h:delete n[p]}if(tD(t,n,c,u),o){n.display&&String(n.display).includes("!important")&&(e.style.setProperty("display",String(n.display).replace(/\s*!important\s*$/,""),"important"),delete n.display);let p=t.display!=null&&typeof t.display!="function"?t.display:t.hide===!0||t.show===!1?"none":null;typeof p=="string"&&p!==""&&n.display&&n.display!==p&&(n.display=p);let h=he(n,null,t.context?.cssPrefix);if(s=h?h.split(" ").filter(Boolean):[],h&&e.classList){let m=s,y=!1;for(let x of m)e.classList.add(x),y||(x.charCodeAt(0)===95&&x.charCodeAt(1)===99||x.charCodeAt(0)===95&&x.indexOf("_c",1)!==-1)&&(y=!0);y&&lD(e)}}let g=t.__ref;if(g){let p=g.__staticCssClasses;if(p&&e.classList){let h=new Set(s);for(let m of p)h.has(m)||e.classList.remove(m)}g.__staticCssClasses=s}eD(t)}finally{Su(),r&&it(),ab.delete(t)}}var F0=t=>!!wt[t]||!!(Et&&Et.has(t))||typeof t=="string"&&t.charCodeAt(0)===45;function N0(t){t&&t.node&&Hk(t)}function Wk(t){let{node:e}=t;if(!e||!e.setAttribute)return;if(t.aria&&typeof t.aria=="object")for(let o in t.aria){let s=t.aria[o];if(typeof s=="function"||typeof s=="object"||s==null||typeof s=="string"&&s.includes("{{"))continue;let i="aria-"+o.replace(/[A-Z]/g,a=>"-"+a.toLowerCase());e.setAttribute(i,re(i,s))}let r=Py(t);for(let o in r){let s=r[o];s!=null&&s!==!1&&typeof s!="function"&&typeof s!="object"&&e.setAttribute(o,s===!0?"":s)}let n=t.tag||"div";for(let o of Object.keys(t)){if(typeof t[o]=="function"||jt.has(o)||o==="on"||r[o]!==void 0)continue;let s=o.charCodeAt(0);if(!(s>=65&&s<=90)&&!Er(o)&&!vs(n,o)&&Te(n,o)){let i=t[o];if(i==null)continue;if(typeof i=="string"&&i.includes("{{")){if(!Qn[o])continue;i=Nt.call(t,i,t.state)}if(i==null||typeof i=="function"||typeof i=="object"||i===!1&&!sr(or(o)||o))continue;let a=or(o)||o;e.setAttribute(a,re(a,i))}}}function j0(t,e){let{node:r}=t;if(!r||!r.setAttribute)return;let n=e.charCodeAt(0);if(n>=65&&n<=90||Er(e))return;let o=t.tag||"div";if(vs(o,e)||!Te(o,e))return;let s=or(e)||e,i=s.toLowerCase(),a=t.__ref&&t.__ref.__effects,c=!1;if(a)for(let u=0;u<a.length;u++){let d=a[u];d&&d._attrName===i&&!d._disposed&&typeof d._execute=="function"&&(c=!0,d._execute())}if(c)return;let l=t[e],f=Qn[e];if(f&&l!=null){let u=f(t);u!==void 0&&(l=u)}typeof l=="string"&&l.includes("{{")&&(l=Nt.call(t,l,t.state)),l==null||l===!1&&!sr(s)?r.removeAttribute(s):typeof l!="function"&&typeof l!="object"&&r.setAttribute(s,re(s,l))}function fD(t,e){let r=t.node,n=t.__ref,o=n.__autoGrow;if(!e){if(o&&o.active){try{r.removeEventListener("input",o.resize)}catch{}Ck(o),eo.delete(t),r.style.height="",o.appliedMax!=null&&r.style.maxHeight===o.appliedMax&&(r.style.maxHeight=""),Ek(r,o,!1),o.active=!1,o.appliedMax=null,o.lastMeasure=0}return}o||(o=n.__autoGrow={active:!1,appliedMax:null,lastMeasure:0,lastWidth:null,watch:null,awaitingLayout:!1,appliedScroll:!1,fontsHooked:!1,attachAttempts:0,firstAttemptAt:null,resize:()=>{if(!r.isConnected){vc(t,!0);return}if(!(r.scrollHeight>0)){o.awaitingLayout=!0,vk(t,o);return}o.awaitingLayout=!1;let i=r.style.height;r.style.height="0px";let a=r.scrollHeight;if(!(a>0)){r.style.height=i;return}let c=pD(r),l=c!=null&&a>c;r.style.height=(l?c:a)+"px",Ek(r,o,l),o.lastMeasure=a,o.lastWidth=r.clientWidth,vk(t,o)}},n.__eventCleanup||(n.__eventCleanup=[]),n.__eventCleanup.push(()=>{try{r.removeEventListener("input",o.resize)}catch{}Ck(o),eo.delete(t)})),o.active||(r.addEventListener("input",o.resize),o.active=!0,dD(t,o));let s=typeof e=="object"&&e.max!=null?String(e.max):null;s!==o.appliedMax&&(s==null?o.appliedMax!=null&&r.style.maxHeight===o.appliedMax&&(r.style.maxHeight=""):r.style.maxHeight=s,o.appliedMax=s),o.resize()}function vc(t,e){let r=t.__ref?.__autoGrow;r&&(e&&(r.attachAttempts=0,r.firstAttemptAt=null),eo.add(t),Vu())}function uD(){let t=Array.from(eo);eo.clear();for(let e=0;e<t.length;e++){let r=t[e],n=r.node,o=r.__ref?.__autoGrow;if(!(!n||!o||!o.active)){if(!n.isConnected){o.firstAttemptAt==null&&(o.firstAttemptAt=As()),o.attachAttempts+=1,o.attachAttempts<=Pk&&As()-o.firstAttemptAt<Dk&&(eo.add(r),Vu());continue}o.attachAttempts=0,o.firstAttemptAt=null,o.resize()}}}function vk(t,e){if(e.watch)return;let r=t.node;if(!r)return;let n=r.ownerDocument&&r.ownerDocument.defaultView,o=n&&n.ResizeObserver||(typeof ResizeObserver=="function"?ResizeObserver:null);if(typeof o!="function")return;let s=()=>{if(!e.active||!r.isConnected||!(r.scrollHeight>0))return;if(e.awaitingLayout){e.awaitingLayout=!1,vc(t,!0);return}let a=r.clientWidth;e.lastWidth!=null&&Math.abs(a-e.lastWidth)<.5||(e.lastWidth=a,vc(t,!0))},i;try{i=new o(s),i.observe(r)}catch{return}e.watch=i}function Ck(t){let e=t.watch;if(e){t.watch=null;try{e.disconnect()}catch{}}}function dD(t,e){if(e.fontsHooked)return;e.fontsHooked=!0;let r=t.node&&t.node.ownerDocument,n=r&&r.fonts&&r.fonts.ready;!n||typeof n.then!="function"||n.then(()=>{e.active&&t.node&&vc(t,!0)},()=>{})}function pD(t){let e=t.ownerDocument&&t.ownerDocument.defaultView,r;try{r=e&&e.getComputedStyle?e.getComputedStyle(t):null}catch{r=null}if(!r)return null;let n=f=>typeof f=="string"&&/^\s*-?\d*\.?\d+px\s*$/.test(f)?parseFloat(f):null,o=n(r.maxHeight);if(o==null||!(o>0))return null;let s=(n(r.paddingTop)||0)+(n(r.paddingBottom)||0),i=(n(r.borderTopWidth)||0)+(n(r.borderBottomWidth)||0),a=r.boxSizing==="border-box"?o-i:o+s,c=n(r.lineHeight);if(!(c>0))return a;let l=Math.floor((a-s)/c+1e-6);return l>=1?l*c+s:a}function Ek(t,e,r){r?e.appliedScroll||(t.style.overflowY="auto",e.appliedScroll=!0):e.appliedScroll&&(t.style.overflowY==="auto"&&(t.style.overflowY=""),e.appliedScroll=!1)}var Ak=["srcObject","muted"],hD=(t,e)=>t==="muted"?e===!0||e===""||e==="true"||e==="muted":e??null;function gD(t){let e=t.node,r=t.__ref;if(!(!e||!r))for(let n=0;n<Ak.length;n++){let o=Ak[n],s=t[o];if(s===void 0||!(o in e))continue;let i=a=>{let c=hD(o,a);if(e[o]!==c)try{e[o]=c}catch(l){Gt(r,o,l)}};if(typeof s=="function"){let a=Ft(t,t[o+"Deps"],s),c=Y(()=>{try{i(a(t,t.state,t.context))}catch(l){Gt(r,o,l)}},{depth:r.path.length,label:ft(r,o)});r.__effects.push(c),r.__exec[o]=s}else i(s);o==="srcObject"&&(r.__releaseMedia=()=>{try{e.srcObject!=null&&(e.srcObject=null)}catch{}})}}function qk(t){if(!t.autoGrow)return;let e=t.node;if(!e||e.tagName!=="TEXTAREA")return;let r=t.__ref,n=t.autoGrow,o=typeof n=="function"?Ft(t,t.autoGrowDeps,n):null,s=Y(()=>{let i=t.autoGrow,a=i;if(typeof i=="function")try{a=(i===n&&o?o:i)(t,t.state,t.context)}catch{a=null}fD(t,a)},{depth:r.path.length,label:ft(r,"autoGrow")});r.__effects||(r.__effects=[]),r.__effects.push(s),o&&(r.__exec.autoGrow=n)}var Kk=new Set(["onSwipe","onSwipeLeft","onSwipeRight","onSwipeUp","onSwipeDown"]);function Gk(t,e){for(let r of Object.keys(t)){if(!Er(r)||Kk.has(r))continue;let n=mu(r);if(n){yu(n,t,t[r]);continue}let o=t[r];if(typeof o=="string"&&/^[A-Za-z_$][\w$]*$/.test(o)){let i=o;o=function(c){return t.call(i,c)}}if(typeof o!="function")continue;let s=L2(r);rn.has(s)||ys(I2(s),t,o)}mD(t)}function mD(t){let e=t.node;if(!e||!e.addEventListener)return;let r={},n=!1;for(let d of Kk){let g=t[d];typeof g=="function"&&(r[d]=g,n=!0)}if(!n)return;let o=typeof t.swipeThreshold=="number"?t.swipeThreshold:40,s=typeof t.swipeMaxDuration=="number"?t.swipeMaxDuration:600,i=0,a=0,c=0,l=!1,f=d=>{let g=d.touches&&d.touches[0]||d.changedTouches&&d.changedTouches[0];g&&(i=g.clientX,a=g.clientY,c=Date.now(),l=!0)},u=d=>{if(!l)return;l=!1;let g=d.changedTouches&&d.changedTouches[0]||d.touches&&d.touches[0];if(!g)return;let p=g.clientX-i,h=g.clientY-a,m=Date.now()-c;if(m>s)return;let y=Math.abs(p),x=Math.abs(h);if(Math.max(y,x)<o)return;let b;if(y>x*1.2)b=p<0?"left":"right";else if(x>y*1.2)b=h<0?"up":"down";else return;let _="onSwipe"+b.charAt(0).toUpperCase()+b.slice(1),w=r[_],S=r.onSwipe;w&&w.call(t,d,t,t.state,t.context),S&&S.call(t,{direction:b,dx:p,dy:h,dt:m,event:d},t,t.state,t.context)};e.addEventListener("touchstart",f,{passive:!0}),e.addEventListener("touchend",u,{passive:!0}),t.__ref.__eventCleanup||(t.__ref.__eventCleanup=[]),t.__ref.__eventCleanup.push(()=>{try{e.removeEventListener("touchstart",f)}catch{}try{e.removeEventListener("touchend",u)}catch{}})}function no(t,e){let r={...t};for(let n in e){let o=r[n],s=e[n];o&&s&&typeof o=="object"&&typeof s=="object"&&!Array.isArray(o)&&!Array.isArray(s)&&typeof o!="function"&&typeof s!="function"?r[n]=no(o,s):r[n]=s}return r}function hb(t,e,r,n,o){if(!e||!t.node)return;let s=t.childExtends,i=Cs(t,"childProps");if(Array.isArray(e)){let a=t.tag==="fragment",c=t.context?.document||globalThis.document,l=a?null:c?.createDocumentFragment();if(!a&&!l)return;let f=t.childProps,u=t.childrenAs,d=x=>{let b=e[x],_=b;(typeof b=="string"||typeof b=="number")&&(b={text:b});let w=f;if(typeof f=="function")try{w=f(t,b)}catch{w=null}let S=typeof f=="function"?_c(w):i;if(o&&u!=="state"&&(S=xc(S,_c(_))),u==="state"){let O=_;(typeof _=="string"||typeof _=="number")&&(O={value:_,text:_}),b=w?{...w,state:O}:{state:O}}else w&&(b=no(w,b));if(s&&!b.ignoreChildExtends)if(b.extends){let O=Array.isArray(b.extends)?b.extends:[b.extends],L=Array.isArray(s)?s:[s];b={...b,extends:[...L,...O]}}else b={...b,extends:s};let E=Lk(b?.key,_,x);try{return ne(wc(b,S),t,E,r)}catch(O){if(typeof console<"u"&&console.error){let L=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${E}" failed to construct at ${L} (initial render, skipping this row):`,O?.message||O)}return null}},g=t.__ref;if(!(n===!0&&!a&&!!g&&(r?.mountYield===!0||t.yieldChildren===!0))){for(let x=0;x<e.length;x++){let b=d(x);!a&&b?.node&&l.appendChild(b.node)}return a||t.node.appendChild(l),!0}let h=g.__childrenChunkGen=(g.__childrenChunkGen||0)+1;Yy();let m=null,y=x=>{if(g.__disposed||g.__childrenChunkGen!==h){m&&m.parentNode&&m.remove();return}for(let b=x;b<e.length;b++){let _=d(b);if(_?.node&&(m?t.node.insertBefore(_.node,m):l.appendChild(_.node)),b+1<e.length&&Gy()){m||(m=c.createComment("smbls-mount"),l.appendChild(m),t.node.appendChild(l));let w=b+1;Zy(()=>y(w));return}}m?(m.remove(),t.node.tagName==="SELECT"&&Bu(t,!0)):t.node.appendChild(l)};return y(0),Xy(),!0}if(typeof e=="string"){let a=$k(e,t);if(Array.isArray(a))return hb(t,a,r,n,!0)}if(typeof e=="object")for(let a in e){if(jt.has(a))continue;let c=e[a];if(c==null||c===!1)continue;let l=o?xc(i,_c(c)):i;if((typeof c=="string"||typeof c=="number")&&(c={text:c}),t.childProps&&(c=no(t.childProps,c)),s&&!c.ignoreChildExtends)if(c.extends){let f=Array.isArray(c.extends)?c.extends:[c.extends],u=Array.isArray(s)?s:[s];c={...c,extends:[...u,...f]}}else c={...c,extends:s};ne(wc(c,l),t,a,r)}}function Bu(t,e){let r=t.node;if(!r||r.tagName!=="SELECT")return;let n=r.options;if(!n||!n.length)return;let o=t.__ref,s=o&&o.__exec&&o.__exec.value,i=typeof s=="function",a=t.value!=null&&typeof t.value!="function";if(i||a){let f;if(i)try{f=s(t,t.state,t.context)}catch{return}else f=t.value,typeof f=="string"&&f.includes("{{")&&(f=Nt.call(t,f,t.state));let u=f==null?"":String(f);r.value!==u&&(r.value=u);return}let c=e||!(o&&o.__selectSynced);if(o&&(o.__selectSynced=!0),!c)return;let l=-1;for(let f=0;f<n.length;f++)n[f].defaultSelected&&(l=f);l>=0&&r.selectedIndex!==l&&(r.selectedIndex=l)}function Yk(t,e){let{children:r,content:n}=t,o=t.childExtends,s=typeof r=="function"||Mk(t,"children");if(typeof r=="function"){let p=r;try{r=p(t,t.state,t.context)}catch(b){if(r=void 0,typeof console<"u"&&console.error){let _=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] \`children:\` factory threw at ${_} (initial run, treating as empty):`,b?.message||b)}}gk(t,r),t.children=r;let h=t.__ref,m=!1,y=Ft(t,t.childrenDeps,p),x=Y(()=>{let b=m;m=!0;let _;try{_=y(t,t.state,t.context)}catch(U){if(typeof console<"u"&&console.error){let rt=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] \`children:\` factory threw at ${rt}${b?"":" (initial tracking run)"}:`,U?.message||U)}return}if(!b||_===t.children)return;gk(t,_),t.children=_,h.__childrenChunkGen!=null&&h.__childrenChunkGen++;let w=typeof t.onContentUpdate=="function",S=w?[]:null,E=w?[]:null,O=w?[]:null;if(Array.isArray(_)&&t.childrenAs==="state"){let U=t.childProps,rt=[],Rt=new Map;for(let j=0;j<_.length;j++){let nt=_[j],N=U;if(typeof U=="function")try{N=U(t,nt)}catch{N=null}let J=Lk(N&&N.key,nt,j);rt.push(J),Rt.set(J,{rawChild:nt,childProps:N})}let mt=new Set(rt),F=h.__children.slice();for(let j of F)if(!mt.has(j)){let nt=t[j];nt?.remove&&nt.remove(),delete t[j],E&&E.push(j)}let W=t.childExtends,yt=t.tag==="fragment",St=t.context?.document||globalThis.document,Pt=yt?null:St?.createDocumentFragment(),G=new Set;for(let j of rt){let nt=Rt.get(j),N=nt.rawChild,J=t[j];if(J&&J.state){if(N&&typeof N=="object"){let Dt=J.state,Q=Dt.$replace||Dt.replace,X=Dt.$update||Dt.update;try{if(typeof Q=="function")Q.call(Dt,N);else if(typeof X=="function"){for(let Z in Dt)if(!(Z==="__element"||Z==="root"||Z==="parent"||Z==="update")&&!Object.prototype.hasOwnProperty.call(N,Z))try{Dt[Z]=void 0}catch{}X.call(Dt,N)}else for(let Z in N)Dt[Z]=N[Z]}catch(Z){if(typeof console<"u"&&console.error){let q=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${j}" failed to patch at ${q} (reconcile, keeping its previous data for this pass):`,Z?.message||Z)}}}O&&O.push(j);continue}let z=N;(typeof N=="string"||typeof N=="number")&&(z={value:N,text:N});let cr=nt.childProps,At=cr?{...cr,state:z}:{state:z},ri=typeof U=="function"?_c(cr):Cs(t,"childProps");if(W&&!At.ignoreChildExtends)if(At.extends){let Dt=Array.isArray(At.extends)?At.extends:[At.extends],Q=Array.isArray(W)?W:[W];At={...At,extends:[...Q,...Dt]}}else At={...At,extends:W};let cl;try{cl=ne(wc(At,ri),t,j,e)}catch(Dt){if(typeof console<"u"&&console.error){let Q=t.__ref?.path?.join(".")||t.key||"<root>";console.error(`[smbls] child "${j}" failed to construct at ${Q} (reconcile, skipping this row):`,Dt?.message||Dt)}G.add(j);continue}!yt&&cl?.node&&Pt&&Pt.appendChild(cl.node),S&&S.push(j)}if(!yt&&Pt&&Pt.childNodes.length&&t.node&&t.node.appendChild(Pt),!yt&&t.node){let j=null;for(let nt of rt){let N=t[nt]?.node;if(!N)continue;let J=j?j.nextSibling:t.node.firstChild;N!==J&&t.node.insertBefore(N,J),j=N}}h.__children=G.size?rt.filter(j=>!G.has(j)):rt,w&&(S.length||E.length)&&uk(t,{added:S,removed:E,kept:O}),Bu(t,!1);return}let M=w?[...h.__children]:null;for(let U of[...h.__children]){let rt=t[U];rt?.remove&&rt.remove(),delete t[U]}h.__children=[],hb(t,_,e,!1,!0),Bu(t,!1),w&&uk(t,{added:[...h.__children],removed:M,kept:[]})},{depth:h.path.length,label:ft(h,"children")});h.__effects.push(x)}let i=hb(t,r,e,!0,s);if(n!=null&&!(n&&n.__ref)){let p=n;if(typeof p=="string"||typeof p=="number"?p={text:p}:typeof p!="object"&&(p={}),t.childProps&&(p=no(t.childProps,p)),o&&!p.ignoreChildExtends)if(p.extends){let m=Array.isArray(p.extends)?p.extends:[p.extends],y=Array.isArray(o)?o:[o];p={...p,extends:[...y,...m]}}else p={...p,extends:o};let h=xc(Cs(t,"childProps"),Cs(t,"content"));ne(wc(p,h),t,"content",e)}if(r&&!i)return;let a=t.context?.components||{},c=t.__ref&&t.__ref.__runtimeSource,l=c?{}:null;{let p=Object.keys(t);for(let h=0;h<p.length;h++){let m=p[h];if(!m.endsWith("Extends")||typeof t[m]!="string")continue;let y=m.slice(0,-7);if(!y||y.charCodeAt(0)<65||y.charCodeAt(0)>90)continue;let x={extends:t[m]};delete t[m];for(let b=h+1;b<p.length;b++){let _=p[b],w=_.charCodeAt(0);if(w>=65&&w<=90||jt.has(_)||typeof t[_]=="function"&&(_.startsWith("on")||_.startsWith(".")))break;let S=t[_];S!==void 0&&(x[_]=S,delete t[_],l&&kc(c,_)&&(l[y]||(l[y]={}),l[y][_]=c[_]))}t[y]&&typeof t[y]=="object"?t[y]={...x,...t[y]}:t[y]=x}}let f=e?.mountYield===!0||t.yieldChildren===!0,u=Object.keys(t),d=p=>{if(jt.has(p)||typeof t[p]!="object"||t[p]===null)return;let h=p.charCodeAt(0);if(h<65||h>90)return;let m=t[p];if(m.__ref)return;if(!m.extends&&!m.extend){let x=a[p]||a[`smbls.${p}`];x&&(m={...m,extends:x})}if(t.childProps&&(m=no(t.childProps,m)),o&&!m.ignoreChildExtends)if(m.extends){let x=Array.isArray(m.extends)?m.extends:[m.extends],b=Array.isArray(o)?o:[o];m={...m,extends:[...b,...x]}}else m={...m,extends:o};let y=c?xc(Cs(t,"childProps"),xc(l[p]||null,Cs(t,p))):null;ne(wc(m,y),t,p,e)};if(!f){for(let p of u)d(p);return}Yy();let g=p=>{for(let h=p;h<u.length;h++)if(d(u[h]),h+1<u.length&&Gy()){let m=h+1;Zy(()=>g(m));return}};g(0),Xy()}function Xk(t,e,r){let{node:n}=t;if(!n)return;n.ref=t;let o=e?.tag==="fragment"?e.__ref?.__fragmentAnchor:null;if(o){let i=o.parentNode;if(i){if(r?.position==="before"&&r.node)i.insertBefore(n,r.node);else if(r?.position==="after"&&r.node){let a=r.node.nextSibling;i.insertBefore(n,a||o)}else i.insertBefore(n,o);return}}let s=e?.node||(e?.nodeType?e:null);if(s)if(r?.position==="before"&&r.node)s.insertBefore(n,r.node);else if(r?.position==="after"&&r.node){let i=r.node.nextSibling;i?s.insertBefore(n,i):s.appendChild(n)}else s.appendChild(n)}var gb=3;function Dy(t){return!t||t.__inBeforeUpdate||(t.__beforeUpdateFailCount||0)>=gb?!1:(t.__inBeforeUpdate=!0,!0)}function kr(t,e){t&&(t.__inBeforeUpdate=!1,e?(t.__beforeUpdateFailCount=(t.__beforeUpdateFailCount||0)+1,t.__beforeUpdateFailCount===gb&&typeof console<"u"&&console.error&&console.error(`[DOMQL] onBeforeUpdate failed ${gb}x in a row on this element \u2014 pausing automatic retries until a future prop/state change re-arms it.`)):t.__beforeUpdateFailCount=0)}function ie(t,e,r){let n=t.charAt(0).toLowerCase()+t.slice(1);e.context?.plugins?.length&&Ot(n,e,r);let o="on"+t,s=e[o];if(typeof s=="function"){let c=t==="Render"?"__inRender":t==="RenderRouter"?"__inRenderRouter":null;if(c){if(e.__ref[c])return!0;e.__ref[c]=!0}let l=e.context?.designSystem;l&&ct(l);let f=!!c;try{let u=s(e,e.state,e.context,r);if(u&&typeof u.then=="function"){let d=e.__ref;return u.catch(g=>{e.context?.plugins?.length&&Ot("error",e,{hook:o,error:g})||console.error(`[DOMQL] Lifecycle "${o}" error:`,g)}).finally(()=>{c&&d&&(d[c]=!1)}),f=!1,!0}if(u===!1)return!1}catch(u){if(e.context?.plugins?.length&&Ot("error",e,{hook:o,error:u})||console.error(`[DOMQL] Lifecycle "${o}" error:`,u),e.context?.strictMode)throw u}finally{l&&it(),f&&e.__ref&&(e.__ref[c]=!1)}}return!0}var Zk={blue:"#213eb0",green:"#389d34",red:"#e15c55",yellow:"#EDCB38",orange:"#e97c16",transparent:"rgba(0, 0, 0, 0)",black:"black",gray:"#4e4e50",white:"white",title:["--gray 1 -168","--gray 1 +168"],caption:["--gray 1 -68","--gray 1 +68"],paragraph:["--gray 1 -42","--gray 1 +42"],disabled:["--gray 1 -26","--gray 1 +26"],line:["--gray 1 -16","--gray 1 +16"],scrim:["black.45","black.55"],scrimSoft:["black.2","black.3"],blueDeep:"#0A5CB8",blueBright:"#47A8FF",accentInk:["blueDeep","blueBright"],greenDeep:"#2A6E28",greenBright:"#7FD07B",successInk:["greenDeep","greenBright"],redDeep:"#A83520",redBright:"#FF8C78",dangerInk:["redDeep","redBright"],orangeDeep:"#94500F",orangeBright:"#F4A45E",warningInk:["orangeDeep","orangeBright"],magentaDeep:"#A100A1",magentaBright:"#FF7AFF",magentaInk:["magentaDeep","magentaBright"]},Jk={"gradient-blue-light":`linear-gradient(to right,
59
59
  rgba(4, 116, 242, 1),
60
60
  rgba(0, 48, 103, 1)
61
61
  )`,"gradient-blue-dark":`linear-gradient(to right,
@@ -81,28 +81,28 @@ FROM ${a}${l}`},RO=t=>{let e=[],r=(n,o)=>{for(let s in n){let i=o?`${o}/${s}`:s;
81
81
  #1E54F0 36%,
82
82
  #8B4CCA 69%,
83
83
  #C66894 100%
84
- )`};var rD={primary:{"@dark":{color:"white",background:"blue",".color-only":{color:"blue"},".inactive":{background:"gray+16"},".gradient":{color:"white",background:"gradient-blue"}},"@light":{color:"white",background:"gradient-blue",".color-only":{color:"blue"},".gradient":{color:"white",background:"gradient-colorful"}}},secondary:{"@dark":{color:"white",background:"green",".color-only":{color:"green"}},"@light":{color:"white",background:"green",".color-only":{color:"green"}},".child":"--primary"},tertiary:{"@dark":{color:"white",background:"gray.92+8"},"@light":{background:"gray.1"}},quaternary:{"@light":{color:"white",background:"gradient-light"},"@dark":{color:"white",background:"gradient-dark-active"}},quinary:{"@dark":{color:"gray=90",background:"gradient-light",":hover":{color:"gray=95",background:"gradient-light-active"},":focus":{color:"gray=120",background:"gradient-light-active"},":active":{color:"gray=120",background:"gradient-light-active"},".active":{color:"gray=120",background:"gradient-light-active"}},"@light":{color:"gray3",background:"gradient-dark",":hover":{color:"gray1",background:"gradient-dark-active"},":active":{color:"gray1",background:"gradient-dark-active"},".active":{color:"gray1",background:"gradient-dark-active"}}}},nD={alert:{"@dark":{color:"white",background:"red"}},warning:{"@dark":{color:"black",background:"yellow"}},success:{"@dark":{color:"black",background:"green"}}},oD={field:{"@light":{color:"black",background:"gray.975+144",borderColor:"gray.975+144","::placeholder":{color:"gray-68"}},"@dark":{color:"white",background:"gray.975-52",borderColor:"gray.975-52","::placeholder":{color:"gray+68"}}},label:{"@dark":{color:"white",background:"gray.92+8"},"@light":{background:"gray.1"},".light":{color:"white",background:"gray3"},".dark":{color:"white",background:"black.35"}},card:{"@light":{background:"gray.975+150"},"@dark":{color:"white",background:"gray.975-56"},".child":{color:"white",background:"gray3"},".secondary":{color:"white",background:"gradient-blue-dark",".child":{color:"white",background:"black.35"}}},dialog:{"@dark":{color:"white",background:"gray.92",".helper":{color:"white",background:"black"}},"@light":{color:"currentColor",background:"gray.1"}}},zk={document:{"@light":{color:"black",background:"white"},"@dark":{color:"white",background:"black"}},...rD,...nD,...oD,backdrop:{"@light":{background:"scrim",backdropFilter:"blur(8px)"},"@dark":{background:"scrim",backdropFilter:"blur(8px)"}},backdropSoft:{"@light":{background:"scrimSoft",backdropFilter:"blur(4px)"},"@dark":{background:"scrimSoft",backdropFilter:"blur(4px)"}},none:{color:"none",background:"none"},transparent:{color:"currentColor",background:"transparent"}};var Hk={base:16,ratio:1.25,subSequence:!0,useCapsize:!0,templates:{}};var Wk={ratio:1.618,subSequence:!0};var qk={SourceSans:[{url:""}]},Kk={system:{isDefault:!0,isSystemFallback:!0,value:["system-ui","-apple-system","BlinkMacSystemFont",'"Segoe UI"',"Roboto",'"Helvetica Neue"',"Arial",'"Noto Sans"','"Liberation Sans"'],type:"sans-serif"}};var Gk={symbols:'<svg xmlns="http://www.w3.org/2000/svg" width="41" height="42" viewBox="0 0 41 42"><path fill="currentColor" fill-rule="evenodd" d="M26.6448969,0.699064106 C31.4862479,1.83000067 35.6718819,4.48073656 38.3104478,8.91022511 C40.5212645,12.5974948 41.4936378,17.0951724 40.5085112,21.3679841 C39.7174644,25.0315254 37.8558379,27.853625 34.8002871,29.8369535 C31.9792925,31.7073227 27.90737,32.069064 24.6776501,31.3213124 C23.2887047,30.9944607 20.6411869,29.9775216 19.044333,28.0178349 C17.5928447,26.2365433 17.1250067,23.5192397 17.0461096,22.8419583 C16.9044422,21.6258334 17.1065683,20.249997 17.3800113,19.0276209 C17.9614095,16.4655592 18.9984397,14.7924534 21.1401118,13.3818866 C22.95018,12.1750388 24.6834696,11.8738651 26.7601335,12.3496124 C28.1855093,12.6880929 29.4520072,13.526716 30.3514025,14.7276098 C30.6271426,15.093878 30.8260324,15.4389318 31.059655,15.8362933 L30.9598079,15.7715366 C29.6377659,14.9422902 28.1654404,14.6590001 26.6448969,15.0752526 C25.2996601,15.4486698 24.1453463,16.3687006 23.4390969,17.6304467 C22.6973258,18.9448239 22.4839364,20.5087166 22.8465467,21.9733145 C23.2152637,23.4394215 24.1276197,24.6832715 25.381967,25.429977 C26.7647836,26.2608222 28.5893081,26.47537 30.1320438,26.0161118 C32.0344739,25.4497656 33.5958796,24.1165457 34.5824098,22.3233381 C35.8078311,20.0959926 36.0316242,17.5753145 35.4197363,15.1376991 C34.8712232,12.9726344 33.491011,11.1258939 31.7578503,9.86101942 C28.3978494,7.40873928 23.8145474,6.88014849 19.8961329,8.1555193 C16.9596954,9.11146975 14.399202,11.0657028 12.6221782,13.707146 C10.5375814,16.8894059 9.73736372,20.794518 10.3986926,24.5579956 C10.9302311,27.7327705 12.5716868,31.0242929 14.8485647,33.1339502 C15.5517576,33.7855358 16.0056239,34.2996296 16.8186608,34.9238068 C16.1252729,35.6670587 15.729719,36.1210912 15.0276006,36.8553491 L10.5425168,41.6144377 C8.59431563,40.2572487 6.84060794,38.6181461 5.33246714,36.7448351 C1.65619854,32.1632109 -0.0655234106,26.1858125 0.562658817,20.1851649 C1.1000136,14.4158268 3.81414269,9.08050481 8.0996615,5.36924966 C12.3107417,1.69300072 17.6911238,0.0107792851 23.1108097,0.299129816 C25.006381,0.458182488 26.18441,0.591493918 26.6448969,0.699064106 Z"/></svg>',logo:'<svg xmlns="http://www.w3.org/2000/svg" width="41" height="42" viewBox="0 0 41 42"><path fill="currentColor" fill-rule="evenodd" d="M26.6448969,0.699064106 C31.4862479,1.83000067 35.6718819,4.48073656 38.3104478,8.91022511 C40.5212645,12.5974948 41.4936378,17.0951724 40.5085112,21.3679841 C39.7174644,25.0315254 37.8558379,27.853625 34.8002871,29.8369535 C31.9792925,31.7073227 27.90737,32.069064 24.6776501,31.3213124 C23.2887047,30.9944607 20.6411869,29.9775216 19.044333,28.0178349 C17.5928447,26.2365433 17.1250067,23.5192397 17.0461096,22.8419583 C16.9044422,21.6258334 17.1065683,20.249997 17.3800113,19.0276209 C17.9614095,16.4655592 18.9984397,14.7924534 21.1401118,13.3818866 C22.95018,12.1750388 24.6834696,11.8738651 26.7601335,12.3496124 C28.1855093,12.6880929 29.4520072,13.526716 30.3514025,14.7276098 C30.6271426,15.093878 30.8260324,15.4389318 31.059655,15.8362933 L30.9598079,15.7715366 C29.6377659,14.9422902 28.1654404,14.6590001 26.6448969,15.0752526 C25.2996601,15.4486698 24.1453463,16.3687006 23.4390969,17.6304467 C22.6973258,18.9448239 22.4839364,20.5087166 22.8465467,21.9733145 C23.2152637,23.4394215 24.1276197,24.6832715 25.381967,25.429977 C26.7647836,26.2608222 28.5893081,26.47537 30.1320438,26.0161118 C32.0344739,25.4497656 33.5958796,24.1165457 34.5824098,22.3233381 C35.8078311,20.0959926 36.0316242,17.5753145 35.4197363,15.1376991 C34.8712232,12.9726344 33.491011,11.1258939 31.7578503,9.86101942 C28.3978494,7.40873928 23.8145474,6.88014849 19.8961329,8.1555193 C16.9596954,9.11146975 14.399202,11.0657028 12.6221782,13.707146 C10.5375814,16.8894059 9.73736372,20.794518 10.3986926,24.5579956 C10.9302311,27.7327705 12.5716868,31.0242929 14.8485647,33.1339502 C15.5517576,33.7855358 16.0056239,34.2996296 16.8186608,34.9238068 C16.1252729,35.6670587 15.729719,36.1210912 15.0276006,36.8553491 L10.5425168,41.6144377 C8.59431563,40.2572487 6.84060794,38.6181461 5.33246714,36.7448351 C1.65619854,32.1632109 -0.0655234106,26.1858125 0.562658817,20.1851649 C1.1000136,14.4158268 3.81414269,9.08050481 8.0996615,5.36924966 C12.3107417,1.69300072 17.6911238,0.0107792851 23.1108097,0.299129816 C25.006381,0.458182488 26.18441,0.591493918 26.6448969,0.699064106 Z"/></svg>',arrowDownCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-circle"><circle cx="12" cy="12" r="10"/><path d="M8 12l4 4 4-4M12 8v8"/></svg>',arrowDownLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-left"><path d="M17 7L7 17M17 17H7V7"/></svg>',arrowDownRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-right"><path d="M7 7l10 10M17 7v10H7"/></svg>',arrowDown:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down"><path d="M12 5v14M19 12l-7 7-7-7"/></svg>',arrowLeftCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-left-circle"><circle cx="12" cy="12" r="10"/><path d="M12 8l-4 4 4 4M16 12H8"/></svg>',arrowLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-left"><path d="M19 12H5M12 19l-7-7 7-7"/></svg>',arrowRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right"><path d="M5 12h14M12 5l7 7-7 7"/></svg>',arrowRightCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right-circle"><circle cx="12" cy="12" r="10"/><path d="M12 16l4-4-4-4M8 12h8"/></svg>',arrowUpCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-circle"><circle cx="12" cy="12" r="10"/><path d="M16 12l-4-4-4 4M12 16V8"/></svg>',arrowUpLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-left"><path d="M17 17L7 7M7 17V7h10"/></svg>',arrowUpRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-right"><path d="M7 17L17 7M7 7h10v10"/></svg>',arrowUp:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up"><path d="M12 19V5M5 12l7-7 7 7"/></svg>',checkCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-check-circle"><path d="M22 11.08V12a10 10 0 11-5.93-9.14"/><path d="M22 4L12 14.01l-3-3"/></svg>',check:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-check"><path d="M20 6L9 17l-5-5"/></svg>',chevronDown:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-down"><path d="M6 9l6 6 6-6"/></svg>',chevronLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-left"><path d="M15 18l-6-6 6-6"/></svg>',chevronRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><path d="M9 18l6-6-6-6"/></svg>',chevronUp:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-up"><path d="M18 15l-6-6-6 6"/></svg>',copy:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-copy"><rect x="9" y="9" width="13" height="13" rx="2" ry="2"/><path d="M5 15H4a2 2 0 01-2-2V4a2 2 0 012-2h9a2 2 0 012 2v1"/></svg>',eyeOff:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-eye-off"><path d="M17.94 17.94A10.07 10.07 0 0112 20c-7 0-11-8-11-8a18.45 18.45 0 015.06-5.94M9.9 4.24A9.12 9.12 0 0112 4c7 0 11 8 11 8a18.5 18.5 0 01-2.16 3.19m-6.72-1.07a3 3 0 11-4.24-4.24M1 1l22 22"/></svg>',eye:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-eye"><path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"/><circle cx="12" cy="12" r="3"/></svg>',info:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-info"><circle cx="12" cy="12" r="10"/><path d="M12 16v-4M12 8h.01"/></svg>',lock:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-lock"><rect x="3" y="11" width="18" height="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0110 0v4"/></svg>',minus:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-minus"><path d="M5 12h14"/></svg>',sun:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-sun"><circle cx="12" cy="12" r="5"/><path d="M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42"/></svg>',moon:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-moon"><path d="M21 12.79A9 9 0 1111.21 3 7 7 0 0021 12.79z"/></svg>',moreHorizontal:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-more-horizontal"><circle cx="12" cy="12" r="1"/><circle cx="19" cy="12" r="1"/><circle cx="5" cy="12" r="1"/></svg>',moreVertical:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-more-vertical"><circle cx="12" cy="12" r="1"/><circle cx="12" cy="5" r="1"/><circle cx="12" cy="19" r="1"/></svg>',send:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-send"><path d="M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z"/></svg>',smile:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-smile"><circle cx="12" cy="12" r="10"/><path d="M8 14s1.5 2 4 2 4-2 4-2M9 9h.01M15 9h.01"/></svg>',search:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-search"><circle cx="11" cy="11" r="8"/><path d="M21 21l-4.35-4.35"/></svg>',upload:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-upload"><path d="M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 3v12"/></svg>',video:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-video"><path d="M23 7l-7 5 7 5V7z"/><rect x="1" y="5" width="15" height="14" rx="2" ry="2"/></svg>',x:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-x"><path d="M18 6L6 18M6 6l12 12"/></svg>',star:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-star"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>',plus:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-plus"><path d="M12 5v14M5 12h14"/></svg>'};var Yk={tv:"(min-width: 2780px)",screenL:"(max-width: 1920px)","screenL<":"(min-width: 1920px)",screenM:"(max-width: 1680px)","screenM<":"(min-width: 1680px)",screenS:"(max-width: 1440px)","screenS<":"(min-width: 1440px)",tabletL:"(max-width: 1366px)","tabletL<":"(min-width: 1366px)",tabletM:"(max-width: 1280px)","tabletM<":"(min-width: 1280px)",tabletS:"(max-width: 1024px)","tabletS<":"(min-width: 1024px)",mobileL:"(max-width: 768px)","mobileL<":"(min-width: 768px)",mobileM:"(max-width: 560px)","mobileM<":"(min-width: 560px)",mobileS:"(max-width: 480px)","mobileS<":"(min-width: 480px)",mobileXS:"(max-width: 375px)","mobileXS<":"(min-width: 375px)",light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)",print:"print"};var Xk={base:150,ratio:1.333,unit:"ms",subSequence:!0,defaultBezier:"cubic-bezier(.29, .67, .51, .97)",springBezier:"cubic-bezier(.32, .72, 0, 1)"};var Zk={radiusControl:"12px",radiusCard:"17px",radiusSheet:"24px",radiusPill:"999px",controlH:"44px",controlHCompact:"36px"};var kc={version:"0.0.1",color:Vk,gradient:Uk,theme:zk,typography:Hk,spacing:Wk,font:qk,fontFamily:Kk,timing:Xk,icons:Gk,media:Yk,sizes:Zk,reset:{html:{},body:{}},animation:{fadeIn:{from:{opacity:0},to:{opacity:1}},modalIn:{from:{transform:"scale(0.95)",opacity:0},to:{transform:"",opacity:1}},modalOut:{to:{transform:"scale(0.95)",opacity:0}}},devices:{},class:{},svg:{},grid:{},shape:{}};var Os={};$(Os,{A:()=>mC,AssetPicture:()=>gv,Audio:()=>bv,Avatar:()=>PC,B:()=>Fv,Block:()=>Jk,Box:()=>Wu,Br:()=>Vv,Button:()=>_C,ButtonSet:()=>kC,COMPONENTS:()=>oo,Caption:()=>Tv,Checkbox:()=>Zv,CheckboxHgroup:()=>Jv,Circle:()=>dv,CircleButton:()=>xC,Clickable:()=>lv,Data:()=>jv,Dialog:()=>CC,DialogFooter:()=>AC,DialogHeader:()=>EC,Dropdown:()=>LC,DropdownList:()=>IC,DropdownParent:()=>$C,DropdownParentFocus:()=>MC,DropdownSiblingFocus:()=>FC,FileIcon:()=>fC,Flex:()=>tv,Focusable:()=>fv,FocusableComponent:()=>uv,Footnote:()=>Mv,Form:()=>iv,Grid:()=>rv,Gutter:()=>ov,H1:()=>xv,H2:()=>Sv,H3:()=>kv,H4:()=>vv,H5:()=>Cv,H6:()=>Ev,Headline:()=>Iv,Hgroup:()=>qv,HgroupButton:()=>Gv,HgroupRows:()=>Kv,Hoverable:()=>cv,Hr:()=>Bv,I:()=>Nv,Icon:()=>cC,IconButton:()=>vC,IconText:()=>lC,Iframe:()=>av,Img:()=>sv,Inline:()=>Qk,InlineFlex:()=>ev,InlineGrid:()=>nv,Input:()=>Yv,Italic:()=>Dv,KangorooButton:()=>SC,Li:()=>Uv,Link:()=>Wb,Notification:()=>NC,NumberInput:()=>Xv,Ol:()=>Hv,P:()=>Av,Picture:()=>hv,Radio:()=>Qv,RadioHgroup:()=>tC,Range:()=>DC,RouteLink:()=>yC,RouterLink:()=>qb,SHAPES:()=>zu,Select:()=>bC,Shape:()=>Sb,Span:()=>wv,SquareButton:()=>wC,Strong:()=>Ov,Subhead:()=>$v,Svg:()=>mv,Text:()=>_v,Textarea:()=>nC,TextareaWithButton:()=>oC,Theme:()=>pv,Title:()=>Lv,Toggle:()=>eC,ToggleHgroup:()=>rC,Tooltip:()=>TC,TooltipHidden:()=>OC,TooltipParent:()=>RC,U:()=>Rv,Ul:()=>zv,Underline:()=>Pv,Video:()=>yv,depth:()=>Hu,focusableRingEnabled:()=>Vu,getSystemGlobalTheme:()=>vc});var yb={};$(yb,{Block:()=>Jk,Flex:()=>tv,Grid:()=>rv,Gutter:()=>ov,Inline:()=>Qk,InlineFlex:()=>ev,InlineGrid:()=>nv});var Jk={display:"block"},Qk={display:"inline"},tv={display:"flex"},ev={display:"inline-flex"},rv={display:"grid"},nv={display:"inline-grid"},ov={boxSize:"C1"};var bb={};$(bb,{Img:()=>sv});D();var sv={tag:"img",attr:{title:t=>t.title||t.alt,alt:t=>t.alt!=null?t.alt:t.title||"",src:t=>{let e=Qt(t);return e&&e.src||t.src},srcset:t=>{let e=Qt(t);return(e?wa(e):"")||t.srcset}}};var _b={};$(_b,{Form:()=>iv});var iv={tag:"form"};var wb={};$(wb,{Iframe:()=>av});var av={tag:"iframe",position:"relative",minWidth:"G",minHeight:"G"};var xb={};$(xb,{Clickable:()=>lv,Focusable:()=>fv,FocusableComponent:()=>uv,Hoverable:()=>cv,focusableRingEnabled:()=>Vu});var sD={appearance:"none",fontFamily:"inherit"},cv={transition:"C defaultBezier",transitionProperty:"opacity, transform",opacity:.85,":hover":{opacity:.9,transform:"scale(1.015)"},":active":{opacity:1,transform:"scale(1.015)"},".active":{opacity:1,transform:"scale(1.015)",":hover":{opacity:1}}},lv={extends:"Hoverable",":active":{opacity:1,transform:"scale(1.015)"},".active":{opacity:1}};function Vu(t){let e=t.context&&t.context.designSystem;return!e||e.focusableRing!==!1}var fv={border:"none",outline:t=>Vu(t)?"solid 0 currentColor":"none",":focus-visible":{opacity:1,outline:t=>Vu(t)?"solid X currentColor":"none"},attr:{tabIndex:t=>t.tabIndex}},uv={extends:"Focusable",tag:"button",fontSize:"A",type:"button",border:"none",textDecoration:"none",lineHeight:"1",whiteSpace:"nowrap",fontFamily:"inherit",cursor:"pointer",":disabled":{cursor:"not-allowed"},style:sD};var Cb={};$(Cb,{Picture:()=>hv});var vb={};$(vb,{Theme:()=>pv,getSystemGlobalTheme:()=>vc});var kb={};$(kb,{Circle:()=>dv,SHAPES:()=>zu,Shape:()=>Sb,default:()=>iD,depth:()=>Hu});D();var Oe=A(),Hu={4:{boxShadow:`rgba(0,0,0,.10) 0 2${Oe.unit.default} 4${Oe.unit.default}`},6:{boxShadow:`rgba(0,0,0,.10) 0 3${Oe.unit.default} 6${Oe.unit.default}`},10:{boxShadow:`rgba(0,0,0,.10) 0 4${Oe.unit.default} 10${Oe.unit.default}`},16:{boxShadow:`rgba(0,0,0,.10) 0 8${Oe.unit.default} 16${Oe.unit.default}`},26:{boxShadow:`rgba(0,0,0,.10) 0 14${Oe.unit.default} 26${Oe.unit.default}`},42:{boxShadow:`rgba(0,0,0,.10) 0 20${Oe.unit.default} 42${Oe.unit.default}`}},Ts=t=>ot(t.shapeDirectionColor)||ot(t.borderColor)||ot(t.backgroundColor)||ot(t.background),Uu=t=>{let e=lc.transition(t.transition,t);return e&&e.transition},zu={rectangle:{},circle:{borderRadius:"100%"},bubble:{},tv:{borderRadius:"1.15em/2.5em"},tooltip:t=>({position:t.position||"relative","&:before":{content:'""',display:"block",width:"0px",height:"0px",border:".35em solid",borderColor:Ts(t),transition:Uu(t),transitionProperty:"border-color",position:"absolute",borderRadius:".15em"}}),tooltipDirection:{top:{"&:before":{top:"0",left:"50%",transform:"translate(-50%, -50%) rotate(45deg)"}},right:{"&:before":{top:"50%",right:"0",transform:"translate(50%, -50%) rotate(45deg)"}},bottom:{"&:before":{bottom:"0",left:"50%",transform:"translate(-50%, 50%) rotate(45deg)"}},left:{"&:before":{top:"50%",left:"0",transform:"translate(-50%, -50%) rotate(45deg)"}}},tag:t=>({position:"relative","&:before":{content:'""',display:"block",background:Ts(t),transition:Uu(t),transitionProperty:"background",borderRadius:".25em",position:"absolute",zIndex:"-1",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",height:"73%"}}),tagDirection:{top:{"&:before":{bottom:"100%",left:"50%",transform:"translate(-50%, 50%) rotate(45deg)"}},right:{"&:before":{top:"50%",left:"100%",transform:"translate(-50%, -50%) rotate(45deg)"}},bottom:{"&:before":{top:"100%",left:"50%",transform:"translate(-50%, -50%) rotate(45deg)"}},left:{"&:before":{top:"50%",right:"100%",transform:"translate(50%, -50%) rotate(45deg)"}}},hexagon:t=>({position:"relative","&:before, &:after":{content:'""',display:"block",position:"absolute",zIndex:"-1",borderRadius:".25em",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",height:"73%",background:Ts(t),transition:Uu(t),transitionProperty:"background"},"&:before":{left:"0",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"},"&:after":{left:"100%",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}}),chevron:t=>({position:"relative","&:before, &:after":{content:'""',display:"block",position:"absolute",zIndex:"-1",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",transition:Uu(t),transitionProperty:"background"},"&:before":{background:`linear-gradient(225deg, ${Ts(t)} 25%, transparent 25%), linear-gradient(315deg, ${Ts(t)} 25%, transparent 25%)`},"&:after":{background:Ts(t),borderRadius:".25em"}}),chevronDirection:{left:{"&:before":{height:"100%",left:"100%",transform:"translate3d(-1%, -50%, 1px) scale(-1, 1)"},"&:after":{height:"73%",left:"0",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}},right:{"&:before":{height:"100%",left:"0",transform:"translate3d(-99%, -50%, 1px)"},"&:after":{height:"73%",left:"100%",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}}}},Sb={deps:{exec:dt,getSpacingBasedOnRatio:Ce,getMediaColor:Mt},classlist:{shape:t=>t.deps.exec(zu[t.shape],t),shapeDirection:t=>{if(!t.shape||!t.shapeDirection)return;let e=zu[t.shape+"Direction"];return t.shape&&e?e[t.shapeDirection||"left"]:null},shapeDirectionColor:t=>{let e={borderColor:t.deps.getMediaColor(t.background||t.backgroundColor)};return t.shapeDirection?e:null}}},dv={round:"100%"},iD=Sb;D();var vc=({context:t,state:e})=>{let r=e&&e.root,n=r&&r.globalTheme||t.designSystem&&t.designSystem.globalTheme;return n==="auto"?null:n},pv={deps:{depth:Hu},classlist:{depth:t=>!Lt(t.depth)&&t.deps.depth[t.depth]}};var hv={deps:{getSystemGlobalTheme:vc},tag:"picture",childExtends:{deps:{getSystemGlobalTheme:vc},tag:"source",attr:{media:t=>{let{key:e,context:r,deps:n}=t,{media:o}=r.designSystem,s=n.getSystemGlobalTheme(t),i=(t.media||e).slice(1);return i===s?"(min-width: 0px)":i==="dark"||i==="light"?"(max-width: 0px)":o[i]}}},Img:{width:"inherit",ignoreChildExtends:!0,height:"inherit",src:(t,e)=>t.parent?.src||e.src}};var Eb={};$(Eb,{AssetPicture:()=>gv});D();var gv={tag:"picture",children:t=>{let e=Qt(t);if(e)return xa(e,t.alt)}};var Ab={};$(Ab,{Svg:()=>mv});var mv={tag:"svg",attr:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"},html:t=>{let{context:e}=t;if(t.semanticIcons)return;if(t.html&&typeof t.html!="function")return t.call("exec",t.html,t);let{designSystem:r,utils:n}=e,o=r&&r.svg,s=t.spriteId||r&&r.useSvgSprite,i=t.call("exec",t.src,t),a=d=>`<use xlink:href="#${d}" />`;if(typeof i=="string"){let d=i.match(/^\s*<symbol\b[^>]*\bid="([^"]+)"/);if(d){let g=d[1],p=e.document||(typeof document<"u"?document:null);if(!(p&&typeof p.getElementById=="function"&&p.getElementById(g))){let m=n&&n.scratchSystem&&n.scratchSystem.appendSVGSprite;r&&!r.__svgCache&&(r.__svgCache={}),typeof m=="function"?m({[g]:i},{document:p}):n&&typeof n.init=="function"&&n.init({svg:{[g]:i}},{document:p,emotion:e.emotion})}return a(g)}}if(!s&&i)return i;let c=t.spriteId;if(c)return a(c);if(o&&o[i])return a(i);let l=Symbol.for(i),f=o[l];if(f&&o[f])return a(f);if(!i)return a("");if(typeof i=="string"&&!i.includes("<"))return typeof console<"u"&&console.warn&&console.warn(`[Svg] Unknown sprite symbol "${i}" \u2014 not registered in design-system sprite. Set the icon name to one that exists in designSystem.icons / context.svg, or register the SVG body via utils.init({ svg: { '${i}': '<svg>...</svg>' } }).`),a("");let u=0;for(let d=0;d<i.length;d++)u=(u<<5)-u+i.charCodeAt(d)|0;return f=o[l]=`svg-${(u>>>0).toString(36)}`,n.init({svg:{[f]:i}},{document:e.document,emotion:e.emotion}),a(f)}};var Tb={};$(Tb,{Video:()=>yv});D();var yv={tag:"video",controls:!0,attr:{src:t=>{let e=Qt(t);return e&&e.src||t.src}},children:t=>{let e=Qt(t);if(!(!e||!Array.isArray(e.variants)||!e.variants.length))return e.variants.map(r=>({tag:"source",attr:{src:r.src,type:r.format}}))},childExtends:{tag:"source"}};var Ob={};$(Ob,{Audio:()=>bv});D();var bv={tag:"audio",controls:!0,attr:{src:t=>{let e=Qt(t);return e&&e.src||t.src}},children:t=>{let e=Qt(t);if(!(!e||!Array.isArray(e.variants)||!e.variants.length))return e.variants.map(r=>({tag:"source",attr:{src:r.src,type:r.format}}))},childExtends:{tag:"source"}};var Rb={};$(Rb,{B:()=>Fv,Caption:()=>Tv,Data:()=>jv,Footnote:()=>Mv,H1:()=>xv,H2:()=>Sv,H3:()=>kv,H4:()=>vv,H5:()=>Cv,H6:()=>Ev,Headline:()=>Iv,I:()=>Nv,Italic:()=>Dv,P:()=>Av,Span:()=>wv,Strong:()=>Ov,Subhead:()=>$v,Text:()=>_v,Title:()=>Lv,U:()=>Rv,Underline:()=>Pv});var _v={},wv={tag:"span"},xv={tag:"h1"},Sv={tag:"h2"},kv={tag:"h3"},vv={tag:"h4"},Cv={tag:"h5"},Ev={tag:"h6"},Av={tag:"p"},Tv={tag:"caption"},Ov={tag:"strong",fontWeight:"700"},Rv={tag:"u"},Pv={tag:"u"},Dv={tag:"i"},Lv={},Iv={tag:"h6",fontSize:"B",fontWeight:500},$v={tag:"span",fontSize:"Z1"},Mv={tag:"span",fontSize:"Z"},Fv={tag:"b"},Nv={tag:"i"},jv={tag:"data"};var Pb={};$(Pb,{Box:()=>Wu,Br:()=>Vv,Hr:()=>Bv,Li:()=>Uv,Ol:()=>Hv,Ul:()=>zv});var aD=t=>{if(!t.context)return;let{props:e,__ref:r}=t,n=se(e,t,{unpack:!1});r.__class=n},Wu={extends:["Shape","Theme"],boxSizing:"border-box",onBeforeClassAssign:aD},Bv={tag:"hr",margin:"C1 0"},Vv={tag:"br"},Uv={tag:"li"},zv={tag:"ul",childExtends:{extends:"Li"}},Hv={tag:"ol",childExtends:{extends:"Li"}};var Db={};$(Db,{Hgroup:()=>qv,HgroupButton:()=>Gv,HgroupRows:()=>Kv});var Wv=t=>{if(t.text!=null||t.html!=null)return!0;for(let e in t){let r=e.charCodeAt(0);if(r>=65&&r<=90)return!0}return!1},qv={display:"flex",tag:"hgroup",flow:"y",gap:"Y2",H:{if:Wv,color:"title",tag:"h3",lineHeight:"1em",margin:"0"},P:{if:Wv,margin:"0",color:"paragraph"}},Kv={extends:"Hgroup",H:{display:"flex",color:"title",align:"center space-between"},P:{color:"paragraph",align:"center space-between"}},Gv={extends:"HgroupRows",H:{justifyContent:"space-between",Span:{},Button:{background:"transparent",color:"currentColor",padding:"0",Icon:{name:"x",fontSize:"C"}}},P:{}};var Lb={};$(Lb,{Input:()=>Yv});var Yv={extends:["Focusable"],tag:"input",border:"none",theme:"field",fontSize:"A",round:"C",lineHeight:"1",padding:"Z2 B",attr:{pattern:t=>t.pattern,minLength:t=>t.minlength,maxLength:t=>t.maxlength,name:t=>t.name,autocomplete:t=>t.autocomplete,placeholder:t=>t.placeholder,value:t=>{if(!t.value)return;let e=t.call("exec",t.value,t);return t.call("isString",e)&&e.includes("{{")?t.call("replaceLiteralsWithObjectFields",e):e},checked:t=>t.call("exec",t.checked,t),disabled:t=>t.disabled||null,readonly:t=>t.readonly,required:t=>t.required,type:t=>t.type}};var Ib={};$(Ib,{NumberInput:()=>Xv});var Xv={extends:["Flex","Input"],type:"number",boxSize:"C+X",align:"center center",textAlign:"center",round:"Y1",theme:"transparent",border:"solid gray3",borderWidth:"1px",placeholder:"0",fontWeight:"400","::-webkit-inner-spin-button":{appearance:"none"},attr:{step:t=>t.step,min:t=>t.min,max:t=>t.max}};var $b={};$($b,{Checkbox:()=>Zv,CheckboxHgroup:()=>Jv});var Zv={extends:"Focusable",tag:"label",boxSize:"fit-content fit-content",cursor:"pointer",round:"Y",Input:{type:"checkbox",position:"absolute",opacity:"0",width:"1px",height:"1px",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",":checked + div":{theme:"primary"},":checked + div > svg":{transform:"none",opacity:"1"},":focus-visible + div":{outline:"solid X currentColor",outlineOffset:"Z"},attr:{checked:t=>t.call("exec",t.parent.checked)}},Flex:{align:"center center",fontSize:"B1",padding:"V",theme:"field",round:"X2",transition:"background A defaultBezier",Icon:{icon:"check",opacity:"0",transform:"scale(0.9) rotate(-15deg)",transition:"opacity B defaultBezier"}}},Jv={display:"flex",tag:"label",boxSize:"fit-content",align:"flex-start flex-start",gap:"A",Checkbox:{tag:"div"},HgroupRows:{gap:"Z1",margin:"Y - - -"}};var Mb={};$(Mb,{Radio:()=>Qv,RadioHgroup:()=>tC});var Qv={extends:"Checkbox",Input:{type:"radio",":checked + div:after":{opacity:"1"}},Flex:{round:"100%",padding:"Y",":after":{content:'""',display:"block",boxSize:"X+W1",round:"100%",background:"white",opacity:"0",transition:"opacity .15s ease-in-out"},Icon:null}},tC={extends:"CheckboxHgroup",Checkbox:null,Radio:{}};var Fb={};$(Fb,{Toggle:()=>eC,ToggleHgroup:()=>rC});var eC={extends:"Checkbox",Input:{role:"switch",":checked + div":{background:"green2+8",justifyContent:"flex-end"}},Flex:{boxSize:"A1 B1",padding:"- W_default",round:"D",align:"center flex-start",theme:"field",border:"none",transition:"opacity .15s ease",":after":{content:'""',boxSize:"A A",round:"100%",background:"white",boxShadow:"gray.2 1px 1px Z"},Icon:null}},rC={extends:"CheckboxHgroup",Checkbox:null,Toggle:{}};var Nb={};$(Nb,{Textarea:()=>nC,TextareaWithButton:()=>oC});var nC={tag:"textarea",extends:["Input","Flex"],fontfamily:"Avenir",placeholder:"Leave us a message...",padding:"A",theme:"field",border:"none",minHeight:"E_default",width:"100%",height:"E1_default",fontFamily:"inherit",round:"Z2",lineHeight:1.4,".outlined":{borderWidth:"1px",borderStyle:"solid"}},oC={display:"flex",gap:"Y2",Textarea:{height:"C2+W",minWidth:"H",padding:"A",fontSize:"Z1",round:"Z2",minHeight:"fit-content"},SquareButton:{background:"blue",Icon:{name:"send"}}};var jb={};$(jb,{FileIcon:()=>fC,Icon:()=>cC,IconText:()=>lC});var sC=new Set,iC=(t,e)=>{if(!sC.has(t)&&(sC.add(t),typeof console<"u"&&console.warn)){let r=e&&e.__ref&&e.__ref.path,n=r&&r.length?` at <${r.join(".")}>`:"";console.warn(`[Icon] Unknown icon name "${t}"${n} \u2014 not registered in designSystem.icons, rendering the noIcon placeholder. Fix the name or register the icon in the design system.`)}},aC=new WeakMap,cD=t=>{let e=aC.get(t);return e||(e={pending:new Map,waiting:new Map,failed:new Set},aC.set(t,e)),e},lD=(t,e)=>{if(!t)return null;let r=t.default||t;return typeof r=="string"?r.trim()?{[e]:r}:null:typeof r=="object"&&!Array.isArray(r)&&Object.keys(r).length?r:null},fD=(t,e,r)=>{let n=r&&r.context&&r.context.document||(typeof document<"u"?document:null);ct(t);try{let o=A();o&&!o.__svgCache&&(o.__svgCache={}),t.__svgCache||(t.__svgCache={});let s={};for(let i in e){let a=Kn(e[i],i);a&&(t.icons[i]=a,s[i]=a)}return t.useIconSprite&&n&&Object.keys(s).length&&Gn(s,{document:n}),Object.keys(s).length>0}finally{it()}},uD=(t,e,r,n,o)=>{let s=t&&t.designSystem,i=s&&s.iconsLoader;if(typeof i!="function"||!s.icons)return!1;let a=cD(s);if(a.failed.has(e))return!1;let c=a.waiting.get(e);if(c||(c=new Set,a.waiting.set(e,c)),c.add(o),a.pending.has(e))return!0;let l=Promise.resolve().then(()=>i(e,t)).then(f=>{let u=lD(f,r);return u?fD(s,u,n):!1}).catch(f=>(typeof console<"u"&&console.error&&console.error(`[Icon] iconsLoader failed for "${e}":`,f),!1)).then(f=>{a.pending.delete(e);let u=a.waiting.get(e);a.waiting.delete(e),f||a.failed.add(e),u&&u.forEach(d=>{try{d(f)}catch(g){console.error("[Icon] repaint error:",g)}})});return a.pending.set(e,l),!0},cC={extends:"Svg",width:"A",height:"A",display:"inline-block",style:{fill:"currentColor","*":{fill:"currentColor"}},onInit:(t,e,r)=>{let{parent:n}=t,{icons:o,useIconSprite:s,verbose:i}=r&&r.designSystem,{toCamelCase:a}=r&&r.utils,c=p=>{let h=p[".isActive"];if(h)return p.call("exec",h.name||h.icon)},l=(p,h,m)=>{let{semanticIcons:_}=m&&m.designSystem,{toCamelCase:x}=m&&m.utils,y=f(p,h),w=x(y).split(/([a-z])([A-Z])/g),S=w[1]?w[0]:y.split(".")[0].split(" ")[0],C=_&&_[S];if(C){let O=y.includes(".")?"sfsymbols."+y.split(".").slice(1).join("."):"sfsymbols";return y=C[O]||C[y.split(".")[0].split(" ")[0]],{tag:"span",semanticIcons:!0,width:"A",height:"A",lineHeight:"1em",":after":{fontSize:"Z",fontWeight:"300",content:`"${y}"`,textAlign:"center",display:"inline-block",style:{color:"currentColor",fontFamily:"'SF Pro Icons', 'SF Pro', 'SF Symbols', 'Segoe UI'"}}}}},f=(p,h)=>{let{key:m}=p,_=p.call("exec",p.name||p.icon||m,p);return p.call("isString",_)&&_.includes("{{")&&(_=p.call("replaceLiteralsWithObjectFields",_)),p.call("isString",_)?_:m},u=t.src,d,g=()=>{let p=f(t,e),h=p;if(p.includes(" ")){let T=p.split(" ");p=T[0]+T.slice(1).map(M=>M.charAt(0).toUpperCase()+M.slice(1)).join("")}let m=a(p),_=m.split(/([a-z])([A-Z])/g),x=l(t,e,r);if(x){Object.assign(t,x);return}let y;t.isActive&&(y=c(t));let b=n[".isActive"];n&&n.isActive&&b&&b.icon&&(y=t.call("exec",b.icon||b.Icon.name||b.Icon.icon,t)),t.call("isString",y)&&y.includes("{{")&&(y=t.call("replaceLiteralsWithObjectFields",y));let w;o[y]&&(w=y),o[m]?w=m:o[_[0]+_[1]]?w=_[0]+_[1]:o[_[0]]?w=_[0]:i&&t.warn("Can't find icon:",p,w);let S=o[w],C=n&&n.src||u;!S&&!C&&(uD(r,h,m,t,M=>{if(!(d&&d._disposed)){if(!M)return iC(h,t);g()}})||iC(h,t));let O=s&&w,L=S||C||o.noIcon;if(!(t.spriteId===O&&t.src===L&&t.node&&t.node.innerHTML)&&(t.spriteId=O,t.src=L,typeof t.html=="function"&&t.node)){let T=t.context&&t.context.designSystem;T&&ct(T);try{let M=t.html(t,t.state,t.context);M!=null&&typeof M!="function"&&(t.node.innerHTML=M)}finally{T&&it()}}};d=Y(g,{depth:t.__ref&&t.__ref.path&&t.__ref.path.length||0}),t.__ref&&(t.__ref.__effects||(t.__ref.__effects=[]),t.__ref.__effects.push(d))},attr:{viewBox:"0 0 24 24","aria-hidden":t=>t.ariaLabel||t.role==="img"?null:"true",focusable:"false"}},lC={display:"flex",align:"center center",lineHeight:1,".reversed":{flow:"row-reverse"},".vertical":{flow:"column"},Icon:{if:t=>{let{parent:e}=t,r=t.call("exec",t.icon,t);return t.call("exec",r||e.icon||t.name||t.sfSymbols||e.sfSymbols,t)},icon:t=>t.call("exec",t.parent.icon,t.parent)},text:t=>t.text},fC={display:"flex",theme:"tertiary",boxSize:"C1",align:"center center",round:"Z2",Icon:{fontSize:"B",margin:"auto",icon:"file"}};var Kb={};$(Kb,{A:()=>mC,Link:()=>Wb,RouteLink:()=>yC,RouterLink:()=>qb});var Cc={};$(Cc,{default:()=>yD,getActiveRoute:()=>Hb,lastLevel:()=>Ku,lastPathname:()=>qu,matchRoute:()=>Vb,parseQuery:()=>Ub,parseRoutePattern:()=>Bb,router:()=>ar,runGuards:()=>zb});D();var dC=/^:(.+)/,pC=/^\*$/,uC=new Map,Bb=t=>{let e=uC.get(t);if(e)return e;let r=t.replace(/^\//,"").split("/"),n=[],o=!1;for(let i=0;i<r.length;i++){let a=r[i].match(dC);a?n.push({index:i,name:a[1]}):pC.test(r[i])&&(o=!0)}let s={segments:r,params:n,hasWildcard:o,pattern:t};return uC.set(t,s),s},Vb=(t,e,r=0)=>{let o=t.replace(/^\//,"").split("/").filter(Boolean).slice(r),s="/"+(o[0]||"");if(!e)return{key:null,content:null,params:{},routePath:s};let i=null,a=-1,c={};for(let l in e){if(l==="/*")continue;let f=Bb(l),u=dD(o,f);u>a&&(a=u,i=l,c=pD(o,f))}return!i&&e["/*"]&&(i="/*"),{key:i,content:i?e[i]:null,params:c,routePath:s}},dD=(t,e)=>{let{segments:r,hasWildcard:n}=e;if(!n&&r.length!==t.length&&r.length!==1&&r.length>t.length)return-1;let o=0,s=Math.min(r.length,t.length);for(let i=0;i<s;i++)if(r[i]===t[i])o+=3;else if(dC.test(r[i]))o+=1;else if(pC.test(r[i]))o+=.5;else return-1;return o},pD=(t,e)=>{let r={};for(let{index:n,name:o}of e.params)t[n]&&(r[o]=decodeURIComponent(t[n]));return r},Ub=t=>{if(!t||t==="?")return{};let e={};return new URLSearchParams(t).forEach((n,o)=>{e[o]!==void 0?(Array.isArray(e[o])||(e[o]=[e[o]]),e[o].push(n)):e[o]=n}),e},zb=async(t,e)=>{if(!t||!t.length)return!0;for(let r of t){let n=await r(e);if(n===!1)return!1;if(typeof n=="string")return n}return!0},Hb=(t=0,e)=>{e||(e=typeof E<"u"?E.location.pathname:"/");let n=e.split("/")[t+1];if(n)return`/${n}`},qu,Ku=0,hD=t=>!t||t==="srcdoc"||t==="about:srcdoc"?"/":t,hC={level:Ku,pushState:!0,replace:!1,initialRender:!1,scrollToTop:!0,scrollToNode:!1,get scrollNode(){return typeof st<"u"&&(st.scrollingElement||st.documentElement)||null},scrollBody:!1,useFragment:!1,updateState:!0,scrollToOffset:0,contentElementKey:"content",scrollToOptions:{behavior:"smooth"},useParamsMatching:!0,exitTimeout:300},gD=(t,e)=>{if(!t||t.visibilityState!=="visible")return!1;try{let r=e&&typeof e.matchMedia=="function"&&e.matchMedia("(prefers-reduced-motion: reduce)");if(r&&r.matches)return!1}catch{}return!0},gC=t=>{let e=t.__routeExit;e&&(t.__routeExit=null,e.abort())},mD=(t,e,r,n,o,s,i)=>{let a=e.__routeExit;if(a&&a.page===r)return a.wait;if(gC(e),!r||!r.node||typeof t.onRouteExit>"u"||!gD(s,i))return null;let c=typeof o=="number"&&o>=0?o:hC.exitTimeout,l=typeof AbortController=="function"?new AbortController:null,f={...n,page:r,timeout:c,signal:l?l.signal:void 0},u;try{u=hr("routeExit",t,f)}catch{return null}if(!u||typeof u.then!="function")return null;let d={page:r,abort:()=>{l&&!l.signal.aborted&&l.abort()}};return d.wait=new Promise(g=>{let p=setTimeout(()=>{d.abort(),g()},c),h=()=>{clearTimeout(p),g()};u.then(h,h)}),e.__routeExit=d,d.wait},ar=async(t,e,r={},n={})=>{let o=e||void 0,s=o?.context?.window||E,i=o?.context?.document||st,a={...hC,...o.context.routerOptions,...n};Ku=a.lastLevel;let c=o.__ref;(a.contentElementKey!=="content"&&a.contentElementKey!==c.contentElementKey||!c.contentElementKey)&&(c.contentElementKey=a.contentElementKey||"content");let l=c.contentElementKey||a.contentElementKey||"content",f=s.location.origin!=="null"?s.location.origin:"http://localhost";t=hD(t);let u=typeof s.URL=="function"?s.URL:typeof globalThis<"u"&&globalThis.URL||URL,d=new u(f+t),{pathname:g,search:p,hash:h}=d,m=Ub(p),_=o.node,x=h&&h!==s.location.hash.slice(1),y=g!==qu;qu=g;let b=c.__routerRendered,w,S,C,O;if(a.useParamsMatching){let F=Vb(g,o.routes,a.level);w=F.key,S=F.routePath,C=F.content,O=F.params}else{w=Hb(a.level,g),S=w;let F=o.routes;C=F?F[w||"/"]||F["/*"]:null,O={}}let L=a.scrollToNode?_:a.scrollNode;if(o.state?.root?.debugging){o.state.root.debugging=!1;return}if(!C){a.onNotFound?a.onNotFound({pathname:g,route:w,element:o}):a.silent||console.warn("[smbls/router] no content matched for path",g,"\u2014 available routes:",Object.keys(o.routes||{}));return}if(a.guards&&a.guards.length){let F={pathname:g,route:w,params:O,query:m,hash:h,element:o,state:r},W=await zb(a.guards,F);if(W===!1)return;if(typeof W=="string")return ar(W,e,r,{...n,guards:[]})}let T=c.__routerNavSeq=(c.__routerNavSeq||0)+1,M=!b||b.content!==C||b.route!==w,U=y||M||a.force===!0;if(U&&b){let F=mD(o,c,o[l],{from:b.route,to:w,pathname:g,params:O,query:m,hash:h},a.exitTimeout,i,s);if(F&&(await F,c.__routerNavSeq!==T||(c.__routeExit&&c.__routeExit.wait===F&&(c.__routeExit=null),typeof o?.set!="function")))return}else gC(c);if(a.pushState){let F=g+(p||"")+(h||"");try{a.replace?s.history.replaceState(r,null,F):s.history.pushState(r,null,F)}catch{}}let Rt=y||!x?{route:w,routePath:S,hash:h,params:O,query:m,debugging:!1}:{params:O,query:m};if(a.updateState&&o.state.update(Rt,{preventContentUpdate:!0}),U){l&&a.removeOldElement&&o[l].remove();let F=o.__ref?.origin?.content,W={};if(F)for(let G in F){let j=F[G];G==="__ref"||G==="props"||G==="node"||G==="parent"||G==="key"||(typeof j=="string"||typeof j=="number"||typeof j=="boolean"||typeof j=="object"&&j!==null&&!j.node&&!j.__ref)&&(W[G]=j)}let yt={...W,...typeof C=="object"?C:{extends:C}};a.useFragment&&(yt.tag="fragment");let St={content:C,route:w},Pt=c.__routerRendered;try{if(typeof o?.set!="function")return;c.__routerRendered=St,o.set(yt,{contentElementKey:l})}catch(G){c.__routerRendered===St&&(c.__routerRendered=Pt),console.error("[smbls/router] failed to render route content",g,G)}}let mt=!y&&x;if(a.scrollToTop&&!mt&&L?.scrollTo&&L.scrollTo({...a.scrollToOptions||{},top:0,left:0}),a.scrollToNode&&C[l]?.node?.scrollTo&&C[l].node.scrollTo({...a.scrollToOptions||{},top:0,left:0}),h){let F=i.getElementById(h.slice(1));if(F&&L?.scrollTo){let W=s.getComputedStyle?s.getComputedStyle(F):null,yt=W&&parseFloat(W.scrollMarginTop)||0,St=F.getBoundingClientRect().top+L.scrollTop-yt-(a.scrollToOffset||0);L.scrollTo({...a.scrollToOptions||{},top:St,left:0})}}hr("routeChanged",o,a)},yD=ar;var bD=(t,e,r)=>{let{context:n}=e,{href:o,scrollToTop:s,stopPropagation:i}=e,a=e.call("exec",o,e);if(e.call("isString",a)&&a.includes("{{")&&(a=e.call("replaceLiteralsWithObjectFields",a)),i&&t.stopPropagation(),!a)return;let{utils:c,snippets:l,functions:f,routerOptions:u}=n,d=e.__ref.root,g=a.startsWith("http://")||a.startsWith("https://")||a.startsWith("mailto:")||a.startsWith("tel:")||a.startsWith("sketch:")||a.startsWith("whatsapp:")||a.startsWith("sms:")||a.startsWith("skype:")||a.startsWith("viber:")||a.startsWith("callto:")||a.startsWith("facetime:")||a.startsWith("facetime-audio:")||a.startsWith("geo:")||a.startsWith("maps:");if(a&&!g){t.preventDefault();try{let p=d;if(u&&u.customRouterElement){let h=Array.isArray(u.customRouterElement)?u.customRouterElement:u.customRouterElement.split("."),m=d;for(let _ of h){if(!m||!m[_]){m=null;break}m=m[_]}m&&(p=m,d.routes&&(p.routes=d.routes))}(f.router||l.router||c.router||ar)(a,p,{},{scrollToOptions:{behavior:"instant"},scrollToTop:e.call("isDefined",s)?s:!0,...u,...e.routerOptions})}catch(p){console.warn(p)}}},Wb={extends:"Focusable",tag:"a",aria:{},fontWeight:"bold",textDecoration:"none",color:"currentColor",draggable:!1,attr:{href:t=>on(t,t.href)||on(t,t.call("exec",t,t).href),"aria-label":t=>t.aria?t.aria.label:t.text},onClick:bD},mC={extends:"Link"},qb={onClick:(t,e,r)=>{let{context:n}=e,{href:o,scrollToTop:s,stopPropagation:i}=e,a=e.call("exec",o,e);if(e.call("isString",a)&&a.includes("{{")&&(a=e.call("replaceLiteralsWithObjectFields",a)),i&&t.stopPropagation(),!a)return;let{utils:c,snippets:l,functions:f,routerOptions:u}=n,d=e.__ref.root,g=a.startsWith("http://")||a.startsWith("https://")||a.startsWith("mailto:")||a.startsWith("tel:")||a.startsWith("sketch:")||a.startsWith("whatsapp:")||a.startsWith("sms:")||a.startsWith("skype:")||a.startsWith("viber:")||a.startsWith("callto:")||a.startsWith("facetime:")||a.startsWith("facetime-audio:")||a.startsWith("geo:")||a.startsWith("maps:");if(a&&!g){t.preventDefault();try{let p=d;if(u&&u.customRouterElement){let h=Array.isArray(u.customRouterElement)?u.customRouterElement:u.customRouterElement.split("."),m=d;for(let _ of h){if(!m||!m[_]){m=null;break}m=m[_]}m&&(p=m,d.routes&&(p.routes=d.routes))}(f.router||l.router||c.router||ar)(a,p,{},{scrollToOptions:{behavior:"instant"},scrollToTop:e.call("isDefined",s)?s:!0,...u,...e.routerOptions})}catch(p){console.warn(p)}}}},yC={extends:[Wb,qb]};var Gb={};$(Gb,{Select:()=>bC});var bC={extends:"Focusable",tag:"select",fontSize:"A",border:"none",boxSizing:"border-box",theme:"field",cursor:"pointer",childProps:{tag:"option",attr:{value:t=>t.value,selected:t=>t.selected,disabled:t=>t.disabled}},attr:{name:t=>t.name,disabled:t=>t.disabled,value:t=>{if(!t.value)return;let e=t.call("exec",t.value,t);return t.call("isString",e)&&e.includes("{{")?t.call("replaceLiteralsWithObjectFields",e):e}}};var Yb={};$(Yb,{Button:()=>_C,ButtonSet:()=>kC,CircleButton:()=>xC,IconButton:()=>vC,KangorooButton:()=>SC,SquareButton:()=>wC});var _C={extends:["IconText","FocusableComponent"],tag:"button",minHeight:"controlH",fontSize:"Z2",type:"button",borderStyle:"none",display:"inline-flex",align:"center center",textDecoration:"none",lineHeight:"1",whiteSpace:"nowrap",padding:"0 A",fontWeight:"700",fontFamily:"inherit",round:"radiusPill",disabled:t=>t.call("exec",t.disabled)},wC={extends:"Button",fontSize:"A",width:"A",minHeight:"auto",padding:"Z",aspectRatio:"1 / 1",boxSize:"fit-content fit-content",justifyContent:"center",round:"Z2",boxSizing:"content-box"},xC={extends:"SquareButton",round:"C"},SC={extends:"Button",childExtends:"IconText"},kC={tag:"nav",display:"flex",childExtends:"SquareButton"},vC={extends:["SquareButton","ClickableItem"],round:"Z"};var Xb={};$(Xb,{Dialog:()=>CC,DialogFooter:()=>AC,DialogHeader:()=>EC});var CC={display:"flex",tag:"dialog",flow:"column",border:"0",theme:"dialog",round:"Z2"},EC={extends:"Hgroup",minWidth:"100%",gap:"A",Title:{align:"center space-between",Text:{text:"Title"},SquareButton:{icon:"x",theme:"transparent"}},Paragraph:{color:"caption"}},AC={display:"flex",align:"center flex-end",gap:"X2",margin:"auto - -",padding:"Y2 X2",childExtends:{extends:"Button",textTransform:"uppercase",background:"transparent","@dark":{theme:"primary @dark .color-only"},"@light":{theme:"primary @light .color-only"},"&":{padding:"Z A"},":hover":{theme:"tertiary"},":active":{background:"white.1"}},Cancel:{text:"cancel"},Ok:{text:"ok"}};var Zb={};$(Zb,{Tooltip:()=>TC,TooltipHidden:()=>OC,TooltipParent:()=>RC});D();var TC={display:"flex",theme:"dialog",background:"black",flow:"column",shape:"tooltip",shapeDirection:"left",padding:"Z1 A",round:"Y2",width:"fit-content",minWidth:"D2",maxWidth:"F2",gap:"X",textAlign:"center",attr:{tooltip:!0},Title:{if:t=>Tt(t.parent.title)||t.parent.title,width:"fit-content",fontWeight:500,color:"gray12",text:t=>t.parent.title},P:{if:(t,e)=>t.call("isDefined",t.call("exec",t.parent.description,t))||t.text,width:"fit-content",fontSize:"Z2",margin:"0",color:"gray6",fontWeight:"400",text:(t,e)=>t.call("exec",t.parent.description,t)}},OC={extends:"Tooltip",position:"absolute",pointerEvents:"none",opacity:"0",visibility:"hidden",transition:"C defaultBezier opacity, C defaultBezier visibility, B defaultBezier transform",onInit:t=>{let e=!t.shapeDirection||t.shapeDirection==="top"?{top:"112%",left:"50%",transform:"translate3d(-50%,10%,0)",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="right"?{transform:"translate3d(10%,-50%,0)",left:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="bottom"?{transform:"translate3d(-50%,-10%,0)",bottom:"112%",left:"50%",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="left"?{transform:"translate3d(10%,-50%,0)",right:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:{};Object.assign(t,e)}},RC={position:"relative",zIndex:999,onInit:t=>{let{Tooltip:e,TooltipHidden:r}=t,n=e||r;if(!n)return;let o=n&&n[".isActive"];Object.assign(t,{":hover, &:focus-visible":{zIndex:1e3,"& [tooltip]":o||{transform:"translate3d(-50%, 0, 0)",opacity:1,visibility:"visible"}}})}};var Jb={};$(Jb,{Avatar:()=>PC});var _D=t=>{let r=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64"><rect width="64" height="64" rx="32" fill="#71718A"/><text x="32" y="42" font-family="system-ui,sans-serif" font-size="28" font-weight="700" text-anchor="middle" fill="#fff">${String(t||"").trim().charAt(0).toUpperCase()||"?"}</text></svg>`;return"data:image/svg+xml;utf8,"+encodeURIComponent(r)},PC={extends:"Img",display:"block",avatarType:"adventurer-neutral",borderRadius:"100%",boxSize:"C+X C+X",src:t=>`https://api.dicebear.com/7.x/${t.avatarType||"initials"}/svg?seed=${t.key||"no-avatar"}`,onError:(t,e)=>{if(!e.node||e.node.__avatarFallbackApplied)return;e.node.__avatarFallbackApplied=!0;let r=e.node.getAttribute("alt")||(e.key!=="no-avatar"?e.key:"");e.node.src=_D(r)},attr:{alt:t=>t.alt!=null?t.alt:t.text?t.call("exec",t.text,t):t.key&&t.key!=="no-avatar"?t.key:""}};var Qb={};$(Qb,{Range:()=>DC});var DC={tag:"input",appearance:"none",width:"100%",height:"2px",outline:"none",flex:1,onInput:(t,e,r)=>{e.call("isFunction",e.onInput)?e.onInput(t,e,r):r.update({value:parseFloat(e.node.value)})},onChange:(t,e,r)=>{e.call("isFunction",e.onChange)?e.onChange(t,e,r):r.update({value:parseFloat(e.node.value)})},"::-webkit-slider-thumb":{boxSizing:"content-box",width:"8px",height:"8px",borderWidth:"2px",borderStyle:"solid",borderRadius:"100%",opacity:".8",appearance:"none"},"::-webkit-slider-runnable-track":{},"@dark":{background:"white.2","::-webkit-slider-thumb":{background:"#232526",borderColor:Ko("#454646",.75)},":hover":{"::-webkit-slider-thumb":{borderColor:Ko("#fff",.35)}},":focus":{"::-webkit-slider-thumb":{borderColor:"#3C6AC0"}}},"@light":{background:"gray9","::-webkit-slider-thumb":{background:"white",borderColor:"gray9"},":hover":{"::-webkit-slider-thumb":{borderColor:"gray7"}},":focus":{"::-webkit-slider-thumb":{borderColor:"blue"}}},deps:{returnPropertyValue:(t,e,r)=>{let n=t.call("exec",t[e],t);return(t.call("isFunction",n)?n(t,t.state):n!==void 0?n:r!==void 0?r:0)+""}},attr:{type:"range",value:(t,e)=>t.call("exec",e.value||t.value||t.defaultValue,t),min:(t,e)=>t.deps.returnPropertyValue(t,"min",0),max:(t,e)=>t.deps.returnPropertyValue(t,"max",100),step:(t,e)=>t.deps.returnPropertyValue(t,"step",1)}};var t_={};$(t_,{Dropdown:()=>LC,DropdownList:()=>IC,DropdownParent:()=>$C,DropdownParentFocus:()=>MC,DropdownSiblingFocus:()=>FC});var LC={attr:{dropdown:!0},position:"absolute",top:"100%",left:"0",zIndex:1e3,theme:"quaternary",padding:"Y",round:"Z2",flow:"column",gap:"X",transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},IC={display:"flex",attr:{dropdown:!0},padding:"0 Y",maxHeight:"G",flow:"column",theme:"quaternary",overflow:"hidden auto",style:{listStyleType:"none"},transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",children:t=>t.options||[],childrenAs:"props",".hidden":{transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},childExtends:{extends:"Button",state:{},isActive:({key:t,state:e})=>e.active===t,position:"relative",round:"0",align:"center flex-end",flow:"row-reverse",padding:"Z2 C Z2 Y2",margin:"0",gap:"Y2",theme:"quaternary .child",":hover":{style:{svg:{opacity:"0.5"}}},Icon:{isActive:({key:t,state:e})=>e.active===t,name:"checkmark",opacity:"0.1",".active":{opacity:"1"}},":not(:first-child)":{"@dark":{border:"solid gray4.65"},"@light":{border:"solid gray11"},borderWidth:"1px 0 0"}}},$C={position:"relative",zIndex:999,":hover":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}}},MC={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}},Dropdown:{onClick:()=>{document.activeElement?.blur()}}},FC={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& ~ [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}}};var e_={};$(e_,{Notification:()=>NC});var NC={display:"flex",theme:"alert",padding:"Z1 B Z A",round:"A A A Y2",gap:"X2",cursor:"pointer",align:"flex-start center",IconText:{Icon:{name:"info outline"},Text:{":empty":{hide:!0}}},Hgroup:{extends:["Flex","Hgroup"],flow:"y",align:"flex-start",gap:"X2",H:{tag:"h6",margin:"0",fontWeight:"600",lineHeight:"1em",text:"Notification",":empty":{hide:!0}},P:{fontSize:"Z",margin:"0",text:"is not always a distraction",":empty":{hide:!0}}}};var oo=Object.assign({},yb,bb,_b,wb,xb,Cb,Eb,Ab,kb,Tb,Ob,vb,Rb,Pb,Db,Lb,Ib,$b,Mb,Fb,Nb,jb,Kb,Gb,Yb,Xb,Zb,Jb,Qb,t_,e_);function Gu(t){if(t==null)return 0;if(typeof t!="object")return jC(String(t));let e=2166136261;if(Array.isArray(t)){e=(e^91)*16777619;for(let n=0;n<t.length;n++)e=(e^Gu(t[n]))*16777619;return e>>>0}let r=Object.keys(t).sort();for(let n=0;n<r.length;n++)e=(e^jC(r[n]))*16777619,e=(e^Gu(t[r[n]]))*16777619;return e>>>0}function jC(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e}function Yu(t,e){if(t===e)return!0;if(t===null||e===null||typeof t!=typeof e||typeof t!="object")return!1;if(Array.isArray(t)){if(!Array.isArray(e)||t.length!==e.length)return!1;for(let o=0;o<t.length;o++)if(!Yu(t[o],e[o]))return!1;return!0}let r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;for(let o=0;o<r.length;o++){let s=r[o];if(!Object.prototype.hasOwnProperty.call(e,s)||!Yu(t[s],e[s]))return!1}return!0}function r_(t,e){if(e===void 0)return t;if(t===void 0)return e;if(e===null)return null;if(typeof e!="object"||Array.isArray(e))return e;if(typeof t!="object"||Array.isArray(t))return{...e};let r=!1,n={};for(let o in t)if(o in e){let s=r_(t[o],e[o]);n[o]=s,s!==t[o]&&(r=!0)}else n[o]=t[o];for(let o in e)o in t||(n[o]=e[o],r=!0);return r?n:t}function n_(t,e,r){if(!e||typeof e!="object")return t;if(!t||typeof t!="object")return e;if(r||(r=new WeakSet),r.has(e))return t;r.add(e);for(let n in e){let o=e[n];o&&typeof o=="object"&&!Array.isArray(o)&&t[n]&&typeof t[n]=="object"&&!Array.isArray(t[n])?n_(t[n],o,r):t[n]=o}return t}function cn(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e.toString(36)}function Rs(t){return t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function Ec(t){let e=String(t);return e.length<=20?e.replace(/\s+/g,"_").replace(/[^a-zA-Z0-9_-]/g,"").toLowerCase():cn(e)}function BC(t){return t.split(`
85
- `).map(cn).join(`
86
- `)}var VC={display:"d",position:"pos",padding:"p",paddingTop:"pt",paddingRight:"pr",paddingBottom:"pb",paddingLeft:"pl",paddingBlock:"pbl",paddingInline:"pin",margin:"m",marginTop:"mt",marginRight:"mr",marginBottom:"mb",marginLeft:"ml",marginBlock:"mbl",marginInline:"min",width:"w",height:"h",minWidth:"mnw",minHeight:"mnh",maxWidth:"mxw",maxHeight:"mxh",top:"t",right:"r",bottom:"b",left:"l",flex:"fx",flexDirection:"fxd",flexWrap:"fxw",flexGrow:"fxg",flexShrink:"fxs",flexBasis:"fxb",justifyContent:"jc",alignItems:"ai",alignSelf:"as",alignContent:"ac",gap:"g",rowGap:"rg",columnGap:"cg",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",gridColumn:"gc",gridRow:"gr",overflow:"of",overflowX:"ofx",overflowY:"ofy",fontSize:"fs",fontWeight:"fw",fontFamily:"ff",fontStyle:"fst",lineHeight:"lh",letterSpacing:"ls",textAlign:"ta",textDecoration:"td",textTransform:"tt",color:"c",background:"bg",backgroundColor:"bgc",backgroundImage:"bgi",border:"bd",borderRadius:"br",borderColor:"bdc",borderWidth:"bdw",borderStyle:"bds",boxShadow:"bxsh",opacity:"op",zIndex:"z",cursor:"cur",transition:"tr",transform:"tf",animation:"an",visibility:"vis",whiteSpace:"ws",wordBreak:"wb",objectFit:"obj",pointerEvents:"pe",userSelect:"us",boxSizing:"bxz",outline:"ol",listStyle:"lis",textOverflow:"txo",verticalAlign:"va",float:"fl",clear:"cl",content:"cnt",backdropFilter:"bdf",filter:"flt",resize:"rsz",appearance:"apr",fill:"fil",stroke:"stk",scrollBehavior:"sb",inset:"ins"};function UC(t,e){let r=VC[t]||cn(t),n=Ec(e),o=`_${r}-${n}`,s=Rs(t),i=kD[s],a=i?`${s}: ${e};${i}: ${e}`:`${s}: ${e}`,c=`.${o}{${a}}`;return`${o}
87
- ${c}`}var kD={"backdrop-filter":"-webkit-backdrop-filter","user-select":"-webkit-user-select","mask-image":"-webkit-mask-image","mask-size":"-webkit-mask-size","mask-repeat":"-webkit-mask-repeat","mask-position":"-webkit-mask-position","mask-clip":"-webkit-mask-clip","mask-origin":"-webkit-mask-origin","background-clip":"-webkit-background-clip"},vD="@media (hover: hover)",CD=/(?:^|[^\\]):hover(?![\w-])/,zC=t=>typeof t=="string"&&(t.indexOf("{")!==-1||t.indexOf("}")!==-1);function HC(t){let e=t.split("\0"),r=[],n=[];for(let o=0;o+1<e.length;o+=2){let s=e[o],i=e[o+1];if(!i||zC(i))continue;let a=VC[s]||cn(s),c=Ec(i),l=`_${a}-${c}`,f=Rs(s);r.push(l),n.push(`.${l}{${f}:${i}}`)}return r.join(" ")+"\0"+n.join(`
88
- `)}function WC(t,e,r){let n=t+e,o=`_c${cn(n)}`,s=e.split("\0"),i="";for(let l=0;l+1<s.length;l+=2){let f=s[l],u=s[l+1];u&&(zC(u)||(i+=`${Rs(f)}:${u};`))}let a,c;if(t.startsWith("@media"))c=`.${o}`,a=`${t}{${c}{${i}}}`;else if(t.startsWith(":")||t.startsWith("&")||t.startsWith("[")&&!t.includes("&")){let l=t.startsWith("&")?t.slice(1):t;c=`.${o}${l}`,a=`${c}{${i}}`}else t.includes("&")?(c=t.replace("&",`.${o}`),a=`${c}{${i}}`):(c=`.${o} ${t}`,a=`${c}{${i}}`);return r!==!1&&CD.test(c)&&(a=`${vD}{${a}}`),`${o}
89
- ${a}`}var o_=null;function Zu(t){o_=t}var Ve={structuralHash:Gu,deepEqual:Yu,mergeStructural:r_,overwriteDeep:n_,shortHash:cn,toKebab:Rs,sanitizeValue:Ec,batchShortHash:BC,atomicCssClass:UC,batchAtomicCss:HC,compoundCssClass:WC},qC=!1,Xu=null;function KC(t){return Xu||(Xu=import(t||"@symbo.ls/wasm/pkg").then(e=>(e.structuralHash&&(Ve.structuralHash=e.structuralHash),e.deepEqual&&(Ve.deepEqual=e.deepEqual),e.mergeStructural&&(Ve.mergeStructural=e.mergeStructural),e.overwriteDeep&&(Ve.overwriteDeep=e.overwriteDeep),e.shortHash&&(Ve.shortHash=e.shortHash),e.toKebab&&(Ve.toKebab=e.toKebab),e.sanitizeValue&&(Ve.sanitizeValue=e.sanitizeValue),e.batchShortHash&&(Ve.batchShortHash=e.batchShortHash),e.atomicCssClass&&(Ve.atomicCssClass=e.atomicCssClass),e.batchAtomicCss&&(Ve.batchAtomicCss=e.batchAtomicCss),e.compoundCssClass&&(Ve.compoundCssClass=e.compoundCssClass),qC=!0,o_&&e.batchAtomicCss&&o_({batchAtomicCss:e.batchAtomicCss,compoundCssClass:e.compoundCssClass}),!0)).catch(e=>(console.debug("[smbls] WASM not available, using JS fallbacks:",e.message),!1)),Xu)}function GC(){return qC}D();var Ac={};$(Ac,{CDN_PROVIDERS:()=>xe,DOMQL_EVENTS:()=>Qp,DOMQ_PROPERTIES:()=>Mr,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>yh,HTML_TAGS:()=>Oo,METHODS:()=>Nr,METHODS_EXL:()=>bi,NODE_ENV:()=>Ie,OPTIONS:()=>Hi,PACKAGE_MANAGER_TO_CDN:()=>zr,PARSED_DOMQ_PROPERTIES:()=>yi,PROPS_METHODS:()=>Fr,STATE_METHODS:()=>Sn,STATE_PROPERTIES:()=>Zp,SVG_TAGS:()=>lx,TYPES:()=>fi,UNIVERSAL_RESERVED_KEYS:()=>bf,__resetBuiltinMethodWarnings:()=>Qg,addCaching:()=>Xl,addContext:()=>Yl,addExtend:()=>Bh,addExtends:()=>Ge,addItemAfterEveryElement:()=>Np,addProtoToArray:()=>pi,addRef:()=>ql,applyCSS:()=>a_,applyDependentState:()=>sg,applyEvent:()=>rf,applyEventUpdate:()=>nf,applyExtends:()=>dx,applyProps:()=>Fi,arrayContainsOtherArray:()=>Pp,arraysEqual:()=>Bp,arrayzeValue:()=>Mn,buildImgSrcset:()=>wa,buildSourcesAndImg:()=>xa,cache:()=>fg,call:()=>Dg,captureSnapshot:()=>Ig,checkForStateTypes:()=>eg,checkIfInherits:()=>ef,checkIfStringIsInArray:()=>zp,clone:()=>rh,cloneAndMergeArrayExtend:()=>Oi,cloneFunction:()=>vh,collectExtendsList:()=>Ro,concatAddExtends:()=>Fh,copyJavaScriptToClipboard:()=>rm,copyStringToClipboard:()=>em,createBasedOnType:()=>Wl,createElement:()=>tg,createElementExtends:()=>Ll,createExtends:()=>Pi,createExtendsFromKeys:()=>Po,createExtendsStack:()=>Fl,createIfConditionFlag:()=>Ch,createInheritedState:()=>rg,createKey:()=>Ei,createNestedObject:()=>fh,createNestedObjectByKeyPath:()=>og,createObjectWithoutPrototype:()=>Cl,createParent:()=>Kl,createPath:()=>Gl,createProps:()=>Ni,createPropsStack:()=>zl,createRoot:()=>Qh,createScope:()=>ag,createSnapshotId:()=>Ci,customDecodeURIComponent:()=>Xp,customEncodeURIComponent:()=>Yp,cutArrayAfterValue:()=>Mp,cutArrayBeforeValue:()=>$p,debounce:()=>Ai,debounceOnContext:()=>Sh,decodeNewlines:()=>Gp,deepClone:()=>lt,deepContains:()=>ch,deepDefaults:()=>ma,deepDestringifyFunctions:()=>be,deepExtend:()=>Dl,deepMerge:()=>at,deepMergeExtends:()=>Ye,deepStringifyFunctions:()=>wi,defineSetter:()=>Rg,destringifyGlobalScope:()=>Si,detectHeightOnInit:()=>jg,detectInfiniteLoop:()=>hh,document:()=>st,encodeNewlines:()=>Kp,error:()=>Ln,excludeKeysFromObject:()=>mh,exec:()=>dt,extendCachedRegistry:()=>Nh,extendStackRegistry:()=>Di,extractArrayExtend:()=>Ii,fetchLibraryData:()=>kf,fibonacciNumberByIndex:()=>Bg,filterArrays:()=>Vp,filterArraysFast:()=>Up,finalizeExtends:()=>Nl,findClosestNumber:()=>Sf,findClosestNumberInFactory:()=>Xg,findInheritedState:()=>tf,findKeyPosition:()=>Wp,flattenExtend:()=>Do,formatDate:()=>Ng,generateHash:()=>Ol,generateHeadArrayTags:()=>xf,generateKey:()=>vi,generateMetaTags:()=>Gg,get:()=>Eg,getActiveRoute:()=>Hb,getCDNDirUrl:()=>_f,getCDNUrl:()=>Me,getCapitalCaseKeys:()=>zh,getCdnProviderFromConfig:()=>Bo,getChildStateInKey:()=>Ql,getChildren:()=>Og,getContext:()=>aa,getCookie:()=>Rh,getDB:()=>da,getEmotionStylesheet:()=>im,getExtendsInElement:()=>Vh,getExtendsStack:()=>Ri,getExtendsStackRegistry:()=>Pl,getFrequencyInArray:()=>Dp,getFunctionSource:()=>Le,getHashedExtend:()=>Li,getImportMapScript:()=>Fg,getInObjectByPath:()=>ph,getLocalStorage:()=>Dh,getNev:()=>xh,getPageMetadata:()=>Yg,getParentStateInKey:()=>Jl,getPath:()=>ea,getQuery:()=>pa,getRef:()=>Tg,getRoot:()=>oa,getRootContext:()=>ia,getRootData:()=>sa,getRootState:()=>na,getRootStateInKey:()=>Zl,getSpreadChildren:()=>Hh,global:()=>Tp,hasFunction:()=>De,hasHandlerPlugin:()=>Ao,hasOwnProperty:()=>sh,hashContent:()=>Uo,inheritChildExtends:()=>$l,inheritChildPropsExtends:()=>Il,inheritParentProps:()=>ji,inheritRecursiveChildExtends:()=>Ml,init:()=>Er,initProps:()=>Xh,is:()=>Jt,isArray:()=>P,isBoolean:()=>bl,isBuiltinElementMethod:()=>Jp,isContextComponent:()=>Wh,isCyclic:()=>gh,isDOMNode:()=>Zt,isDate:()=>wl,isDefined:()=>Tt,isDevelopment:()=>Br,isEmpty:()=>kl,isEmptyObject:()=>ih,isEqualDeep:()=>vl,isFailedRevival:()=>An,isFunction:()=>R,isHtmlElement:()=>ci,isLazyFunction:()=>nh,isLocal:()=>wh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>In,isMethod:()=>Lg,isMobile:()=>Th,isNode:()=>dr,isNot:()=>Rp,isNotProduction:()=>On,isNull:()=>_l,isNumber:()=>Ke,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>Vg,isPolyglotRetranslatableKey:()=>zi,isPolyglotWritableKey:()=>Pn,isProduction:()=>jr,isProtectedElementMethod:()=>kn,isStaging:()=>_h,isState:()=>ng,isString:()=>k,isStringFunction:()=>Ti,isTest:()=>Al,isTesting:()=>bh,isUndefined:()=>Lt,isUniversallyReservedKey:()=>$g,isUnresolvableDependency:()=>Hr,isValidDependencyMap:()=>$n,isValidHtmlTag:()=>Ih,isWrappedLibrary:()=>Qe,joinArrays:()=>ko,jointStacks:()=>jh,keys:()=>mf,lastLevel:()=>Ku,lastPathname:()=>qu,loadCssFile:()=>Wg,loadJavascript:()=>qg,loadJavascriptFile:()=>Ug,loadJavascriptFileEmbedSync:()=>Hg,loadJavascriptFileSync:()=>zg,loadRemoteCSS:()=>Kg,loadRemoteScript:()=>Vo,log:()=>Pg,logGroupIf:()=>Ah,logIf:()=>Eh,lookdown:()=>vg,lookdownAll:()=>Cg,lookup:()=>kg,lowercaseFirstLetter:()=>xn,makeObjectWithoutPrototype:()=>ah,map:()=>eh,mapStringsWithContextComponents:()=>$i,markPolyglotSeeded:()=>Ze,matchRoute:()=>Vb,matchesComponentNaming:()=>Xe,memoize:()=>kh,merge:()=>bt,mergeSharedLibraries:()=>ya,nextElement:()=>la,normalizeIgnoreList:()=>Wr,normalizeLibraryKey:()=>zo,objectToString:()=>xi,objectizeStringProperty:()=>Mi,overwrite:()=>ki,overwriteDeep:()=>Wt,overwriteShallow:()=>Tn,overwriteState:()=>ig,parse:()=>yf,parseDeep:()=>Qi,parseQuery:()=>Ub,parseRoutePattern:()=>Bb,pickupElementFromProps:()=>Vl,pickupPropsFromElement:()=>Bl,polyglotSeededKeys:()=>Lo,previousElement:()=>fa,promoteActiveRootState:()=>Mo,propExists:()=>Gh,propertizeElement:()=>Ul,propertizeUpdate:()=>Kh,reinit:()=>i_,remove:()=>Hx,removeChars:()=>nm,removeCookie:()=>Ph,removeDuplicateProps:()=>Vi,removeDuplicatesInArray:()=>vo,removeFromArray:()=>Lp,removeFromObject:()=>lh,removeNestedKeyByPath:()=>uh,removeValueFromArray:()=>di,removeValueFromArrayAll:()=>Fp,reorderArrayByValues:()=>jp,replaceLiteralsWithObjectFields:()=>Ft,replaceOctalEscapeSequences:()=>qp,resolveAsset:()=>Qt,resolveHandler:()=>To,resolveSharedLibraries:()=>tm,returnValueAsText:()=>Hl,router:()=>ar,runGuards:()=>zb,runPluginHook:()=>Ot,scratchSystem:()=>ss,scratchUtils:()=>Gr,self:()=>Op,set:()=>Xn,setActiveRootState:()=>ra,setCookie:()=>Oh,setHashedExtend:()=>Rl,setInObjectByPath:()=>dh,setLocalStorage:()=>Lh,setNodeStyles:()=>gf,setProps:()=>Ag,setPropsPrototype:()=>Bi,sharedLibrary:()=>Jg,splitPackageSpecifier:()=>ha,spotByPath:()=>ta,srcsetFor:()=>Ho,stringIncludesAny:()=>gi,stringToObject:()=>oh,stripVersionRangePrefix:()=>ga,swapItemsInArray:()=>Ip,syncProps:()=>Ui,toCamelCase:()=>ba,toDashCase:()=>_a,toDescriptionCase:()=>sm,toPriorityOrder:()=>_e,toTitleCase:()=>om,toggleFullscreen:()=>Mg,triggerEventOn:()=>hr,triggerEventOnUpdate:()=>cg,trimStringFromSymbols:()=>Hp,unstackArrayOfObjects:()=>ui,update:()=>Yh,updateProps:()=>Zh,variables:()=>ua,verbose:()=>Fo,warn:()=>ca,window:()=>E});D();D();var AD=A(),YC=(t=AD,e)=>{let r=v(e.localFile)?e.localFile:{},n=lt(r.designSystem||{});return at(t,n,ue)},TD={useVariable:!0,useReset:!0,useFontImport:!0,useIconSprite:!0,useDocumentTheme:!0,useSvgSprite:!0},Ju=(t,e)=>{let r=!e||e===":root",n={};for(let o in t)if(o.startsWith("@media")){let s=r?":root:not([data-theme])":`:root:not([data-theme]) ${e}:not([data-theme])`;n[o]={[s]:t[o]}}else r?n[o]=t[o]:n[`${e}${o}, ${o} ${e}`]=t[o];return n},s_=(t,e)=>{t.CSS_MEDIA_VARS&&wt(Ju(t.CSS_MEDIA_VARS,e));let r=Yn(t.cssSkinVars,t.cssSkinFallback,e);Object.keys(r).length&&wt(r)},Er=(t,e=TD)=>{let r=YC(t||{},e),n=e.scopeSelector||":root",o=e.globalTheme;if(typeof window<"u"&&window.location){let h=new URLSearchParams(window.location.search).get("globalTheme");h&&(o=h)}let s=Xn({verbose:e.verbose,useReset:e.useReset,useFontImport:e.useFontImport,useVariable:e.useVariable,useSvgSprite:e.useSvgSprite,useDocumentTheme:e.useDocumentTheme,useIconSprite:e.useIconSprite,useDefaultConfig:e.useDefaultConfig,globalTheme:o,themeRoot:e.themeRoot,files:e.files,assets:e.assets,...r},{newConfig:e.newConfig,config:e.config});s&&(s.scopeSelector=n);let i=Ea(s.font,s.files),a=s.useReset,c=s.useVariable,l=s.useFontImport,f=s.useSvgSprite,u=t.svg,d=s.useIconSprite,g=t.icons;l&&wt(i),c&&(wt({[n]:s.CSS_VARS}),s_(s,n)),a&&wt(s.reset);let p=s.animation;if(p){let h={};for(let m in p)h[`@keyframes ${m}`]=p[m];wt(h)}return(u||f)&&Qa(s.svg,{document:e.document}),(g||d)&&Gn(s.icons,{document:e.document}),s},Qu={},i_=(t,e=Qu)=>{let r=YC(t||{},e),n=e.scopeSelector||":root",o=Xn({verbose:!1,...r});return e.preventInject||(wt({[n]:o.CSS_VARS}),s_(o,n),wt(o.reset)),o},a_=(t,e=Qu)=>{wt(t)},OD=(t,e=Qu)=>{let r=e.scopeSelector||":root";wt({[r]:t.CSS_VARS}),s_(t,r)};var RD=(t,e=Qu)=>{};D();var ZC=t=>!t||t==="srcdoc"||t==="about:srcdoc"||t==="blank"||t==="about:blank"?"/":t,PD=t=>{let e=t&&t.initialPath;return typeof e!="string"||!e?null:e[0]==="/"?e:"/"+e},l_={initRouter:!0,injectRouterInLinkComponent:!0,popState:!0},Tc=(t,e)=>{if(!e)return t;let r=Array.isArray(e)?e:e.split("."),n=t;for(let o of r){if(!n||!n[o])return null;n=n[o]}return n},DD=["manual","auto"],c_=new WeakMap,XC=(t,e)=>{let r=e.claims[e.claims.length-1],n=r?r.value:e.found;t.scrollRestoration!==n&&(t.scrollRestoration=n)},LD=(t,e)=>{let r=e&&e.scrollRestoration;if(r!=null){if(!DD.includes(r)){if(t.verbose!==!1){let n=typeof r=="string"?JSON.stringify(r):`a ${typeof r}`;console.warn(`[smbls/router] router.scrollRestoration must be 'manual' or 'auto', got ${n} \u2014 the browser default stays`)}return}try{let n=t.window||E,o=n&&n.history;if(!o||!("scrollRestoration"in o))return;let s=c_.get(o);s||(s={found:o.scrollRestoration,claims:[]},c_.set(o,s));let i={value:r};s.claims.push(i),XC(o,s),t.__teardowns=t.__teardowns||[],t.__teardowns.push(()=>{let a=s.claims.indexOf(i);if(a!==-1){s.claims.splice(a,1),s.claims.length||c_.delete(o);try{XC(o,s)}catch{}}})}catch{}}},JC=(t,e)=>{if(e.router===!1)return;e.router===!0?e.router=l_:e.router=bt(e.router||{},l_);let r=e.router;LD(e,r);let n=async(s,i)=>{let a=s.context?.window||E,c=PD(r);if(!c){if(!a.location)return;let{pathname:f,search:u,hash:d}=a.location;f=ZC(f),c=f+u+d}let l=s;if(r.customRouterElement){let f=Tc(s,r.customRouterElement);f&&(l=f,s.routes&&(l.routes=s.routes))}l.routes&&await ar(c,l,{},{initialRender:!0,pushState:!1})},o=!Lt(t.onRenderRouter);return r&&r.initRouter&&!o&&(t.onRenderRouter=n),ID(e,r),r},f_=(t,e)=>{if(e.router===!1)return;let r=e.router||l_;if(!r.popState)return;let n=e.utils&&e.utils.router?e.utils.router:ar,o=e.window||E,s=async i=>{let{pathname:a,search:c,hash:l}=o.location;a=ZC(a);let f=a+c+l,u=t;if(r.customRouterElement){let d=Tc(t,r.customRouterElement);d&&(u=d,t.routes&&(u.routes=t.routes))}await u.call("router",f,u,{},{pushState:!1,scrollToTop:!1,level:0,event:i})};o.addEventListener("popstate",s),e.__teardowns=e.__teardowns||[],e.__teardowns.push(()=>o.removeEventListener("popstate",s))},ID=(t,e)=>{let{components:r}=t;if(e&&e.injectRouterInLinkComponent)return at(r.Link||r["smbls.Link"],r.RouterLink||r["smbls.RouterLink"])};D();var u_=E&&E.location?E.location.host.includes("dev."):Br(),QC=u_?"http://localhost:8080/get":"https://api.symbols.app/get",$D={endpoint:QC},tE=async(t,e=$D)=>{let r=e.endpoint||QC,n=e.serviceRoute?P(e.serviceRoute)?e.serviceRoute.map(s=>s.toLowerCase()+"=true").join("&"):e.serviceRoute:"",o;try{return o=await globalThis.fetch(r+"/?"+n,{method:"GET",headers:{"Content-Type":"application/json","X-AppKey":t,"X-Metadata":e.metadata}}),await o.json()}catch(s){if(R(e.onError))return e.onError(s);console.error(s)}},MD=async(t,e)=>{let{editor:r}=e;if(r&&r.remote){let n=await tE(t,r),o=u_||e.isDevelopment?be(n):be(n.releases[0]);r.serviceRoute?P(r.serviceRoute)?r.serviceRoute.forEach(s=>{Wt(e[s],o[s.toLowerCase()])}):Wt(e[r.serviceRoute],o):["state","designSystem","components","snippets","pages","utils","files","assets","packages","functions","globalScope"].forEach(s=>{Wt(e[s],o[s.toLowerCase()])})}return e},FD=async(t,e,r)=>{let{editor:n}=e;if(n&&n.remote){let o=await tE(t,n),s=u_||e.isDevelopment?be(o):be(o.releases[0]);r(s)}},eE=async(t,e)=>{if(t&&e.editor)try{e.editor.async||await MD(t,e)}catch(r){console.error(r)}},rE=(t,e,r,n)=>{if(e&&r.editor)try{r.editor.async&&FD(e,r,n||(o=>{let s=o.designSystem;v(s)&&r.utils.init(s),v(o.state)&&t.state.set(o.state)}))}catch(o){console.error(o)}};var Oc=t=>{if(!t||t.__destroyed)return!1;let e=t.context;if(!e)return t.__destroyed=!0,!1;if(Array.isArray(e.__teardowns)){for(let r of e.__teardowns)try{r()}catch(n){console.error("[smbls] destroy teardown error:",n)}e.__teardowns.length=0}try{kr(t)}catch(r){console.error("[smbls] dispose error:",r)}if(e.fetch&&e.fetch.__resolved&&delete e.fetch.__resolved,e.fetch&&e.fetch.__resolving&&delete e.fetch.__resolving,e.db&&e.db.__resolved&&delete e.db.__resolved,e.db&&e.db.__resolving&&delete e.db.__resolving,e.analyze?.destroy)try{e.analyze.destroy()}catch(r){console.error("[analyze] destroy error:",r)}return t.__destroyed=!0,!0};var h_={};$(h_,{Helmet:()=>sE,applyMetadata:()=>Ls,default:()=>WD,extractMetadata:()=>UD,generateHeadHtml:()=>HD,helmetPlugin:()=>p_,resolveMetadata:()=>ln});D();var ND={title:{tag:"title"},description:{tag:"meta",attr:"name",key:"description"},keywords:{tag:"meta",attr:"name",key:"keywords"},robots:{tag:"meta",attr:"name",key:"robots"},author:{tag:"meta",attr:"name",key:"author"},canonical:{tag:"link",attr:"rel",key:"canonical",valueAttr:"href"},image:{tag:"meta",attr:"property",key:"og:image"},url:{tag:"meta",attr:"property",key:"og:url"},siteName:{tag:"meta",attr:"property",key:"og:site_name"},type:{tag:"meta",attr:"property",key:"og:type"},locale:{tag:"meta",attr:"property",key:"og:locale"},"og:title":{tag:"meta",attr:"property",key:"og:title"},"og:description":{tag:"meta",attr:"property",key:"og:description"},"og:image":{tag:"meta",attr:"property",key:"og:image"},"og:url":{tag:"meta",attr:"property",key:"og:url"},"og:type":{tag:"meta",attr:"property",key:"og:type"},"og:site_name":{tag:"meta",attr:"property",key:"og:site_name"},"og:locale":{tag:"meta",attr:"property",key:"og:locale"},"twitter:card":{tag:"meta",attr:"name",key:"twitter:card"},"twitter:title":{tag:"meta",attr:"name",key:"twitter:title"},"twitter:description":{tag:"meta",attr:"name",key:"twitter:description"},"twitter:image":{tag:"meta",attr:"name",key:"twitter:image"},"twitter:site":{tag:"meta",attr:"name",key:"twitter:site"},"theme-color":{tag:"meta",attr:"name",key:"theme-color"}},jD=t=>{if(t.tag==="link")return`link[${t.attr}="${t.key}"]`;if(t.tag&&!t.attr&&!t.key)return t.tag;if(t.tag&&t.attr&&t.key)return`${t.tag}[${t.attr}="${t.key}"]`},nE=t=>be({v:t}).v,oE=(t,e,r,n)=>{try{return dt(t,e,r)}catch(o){console.warn(`[helmet] metadata factory for "${n}" threw; treating as unset:`,o&&o.message||o);return}},d_=Object.freeze({authored:!0}),ln=(t,e,r,n)=>{if(!t)return{};let o=t;k(o)&&De(o)&&(o=nE(o));let s=R(o),i=!s&&n?.authored===!0,a=s?oE(o,e,r,"metadata"):v(o)?{...o}:{};if(!v(a))return{};for(let c in a){let l=a[c],f=i&&k(l)&&!De(l);k(l)&&De(l)&&(l=nE(l)),R(l)?l=oE(l,e,r,c):k(l)&&De(l)&&(l=void 0),k(l)&&l.includes("{{")&&e?.call&&(l=f?e.call("replaceLiteralsWithObjectFields",l,r,d_):e.call("replaceLiteralsWithObjectFields",l,r)),a[c]=l}return a},BD=t=>!!t&&typeof t=="object"&&(t.notFound===!0||t.metadata?.notFound===!0),VD=(t,e)=>{if(Object.prototype.hasOwnProperty.call(t,e))return t[e];if(t["/*"])return t["/*"];if(t["*"])return t["*"];for(let r in t)if(BD(t[r]))return t[r]},UD=(t,e="/",r,n)=>{let o=t.pages||{},s=VD(o,e),i={};if(t.integrations?.seo&&(i={...t.integrations.seo}),t.app?.metadata){let c=ln(t.app.metadata,r,n,d_);i={...i,...c}}let a=new Set;if(s){let c=s.metadata||s.helmet||{},l=ln(c,r,n,d_);for(let f in l)a.add(f);i={...i,...l},!i.title&&s.state?.title&&(i.title=s.state.title,a.add("title")),!i.description&&s.state?.description&&(i.description=s.state.description,a.add("description"))}if(i.title||(i.title=t.name||"Symbols"),i.title&&(a.has("title")||!i["og:title"])&&(a.has("og:title")||(i["og:title"]=i.title)),i.description&&(a.has("description")||!i["og:description"])&&(a.has("og:description")||(i["og:description"]=i.description)),i.title&&!i["twitter:title"]&&(i["twitter:title"]=i.title),i.description&&!i["twitter:description"]&&(i["twitter:description"]=i.description),i["og:url"]||i.url){let c=(i["og:url"]||i.url||"").replace(/\/$/,"");if(c&&e&&e!=="/"){let l=e.startsWith("/")?e:"/"+e;i["og:url"]=c+l}}if(t.files)for(let c in i){let l=i[c];if(typeof l=="string"&&l.length>0&&!l.startsWith("/")&&!l.startsWith("http")){let f=t.files[l];f?.src&&(i[c]=f.src)}}return i},zD=(t,e)=>{let r=e.createElement(t.tag);return t.attr&&r.setAttribute(t.attr,t.key),(e.head||e.querySelector("head")).appendChild(r),r},Ds=t=>{let e=5381,r=String(t);for(let n=0;n<r.length;n++)e=(e*33^r.charCodeAt(n))>>>0;return e.toString(36)},Ps=(t,e,r,n)=>{let o=t.head||t.querySelector("head");if(!o)return;let s=new Map;for(let a of o.querySelectorAll(`[${e}]`))s.set(a.getAttribute(e),a);let i=new Set;for(let a of r)i.add(a);for(let[a,c]of s)i.has(a)||c.remove();for(let a of r){if(s.has(a))continue;let c=n(a);c&&(c.setAttribute(e,a),o.appendChild(c))}},Ls=(t,e)=>{if(!(!v(t)||!e)){for(let r in t){let n=t[r];if(n==null||r==="jsonLd"||r==="styles"||r==="scripts"||r==="alternate"||r==="favicons"||r==="icon"||r==="favicon")continue;let o=ND[r];if(!o)continue;let s=jD(o),i=e.querySelector(s)||zD(o,e);i&&(r==="title"?i.textContent=n:o.valueAttr?i.setAttribute(o.valueAttr,n):i.setAttribute("content",n))}if(Array.isArray(t.jsonLd)){let n=t.jsonLd.filter(s=>s!=null).map(s=>k(s)?s:JSON.stringify(s)),o=n.map(Ds);Ps(e,"data-smbls-jsonld",o,s=>{let i=o.indexOf(s),a=e.createElement("script");return a.setAttribute("type","application/ld+json"),a.textContent=n[i],a})}if(Array.isArray(t.styles)){let r=t.styles.filter(o=>o!=null&&String(o).trim()),n=r.map(Ds);Ps(e,"data-smbls-style",n,o=>{let s=n.indexOf(o),i=e.createElement("style");return i.textContent=String(r[s]),i})}if(Array.isArray(t.scripts)){let r=t.scripts.filter(o=>o&&(k(o)?o.trim():o.src)),n=r.map(o=>k(o)?o:String(o.src));Ps(e,"data-smbls-script",n,o=>{let s=n.indexOf(o),i=r[s],a=e.createElement("script");return k(i)?a.setAttribute("src",i):(i.src&&a.setAttribute("src",i.src),i.type&&a.setAttribute("type",i.type),i.async&&(a.async=!0),i.defer&&(a.defer=!0),i.integrity&&a.setAttribute("integrity",i.integrity),i.crossorigin&&a.setAttribute("crossorigin",i.crossorigin),i.referrerpolicy&&a.setAttribute("referrerpolicy",i.referrerpolicy),i.nomodule&&(a.noModule=!0),i.body&&(a.textContent=String(i.body))),a})}if(Array.isArray(t.alternate)){let r=t.alternate.filter(o=>v(o)),n=r.map(o=>`${o.hreflang||""}|${o.href||""}`);Ps(e,"data-smbls-alternate",n,o=>{let s=n.indexOf(o),i=e.createElement("link");i.setAttribute("rel","alternate");for(let[a,c]of Object.entries(r[s]))i.setAttribute(a,c);return i})}if(Array.isArray(t.favicons)){let r=t.favicons.filter(o=>o!=null),n=r.map(o=>v(o)?Ds(JSON.stringify(o)):String(o));Ps(e,"data-smbls-favicon",n,o=>{let s=n.indexOf(o),i=r[s],a=e.createElement("link");if(a.setAttribute("rel","icon"),v(i))for(let[c,l]of Object.entries(i))a.setAttribute(c,l);else a.setAttribute("href",String(i));return a})}if(t.icon||t.favicon){let r=String(t.icon||t.favicon),n=r.endsWith(".svg")?"image/svg+xml":r.endsWith(".png")?"image/png":"";Ps(e,"data-smbls-single-icon",[r],o=>{let s=e.createElement("link");return s.setAttribute("rel","icon"),s.setAttribute("href",o),n&&s.setAttribute("type",n),s})}}},ut=t=>{if(t==null)return"";let e={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#039;"};return t.toString().replace(/[&<>"']/g,r=>e[r])},HD=t=>{let e=['<meta charset="UTF-8">'],r=new Set(["charset","jsonLd","styles","scripts"]),n=!1;for(let[o,s]of Object.entries(t)){if(!s&&s!==0&&s!==!1||r.has(o)||typeof s=="function")continue;if(o==="title"){e.push(`<title>${ut(s)}</title>`);continue}if(o==="viewport"){n||(e.push(`<meta name="viewport" content="${ut(s)}">`),n=!0);continue}if(o==="canonical"){e.push(`<link rel="canonical" href="${ut(s)}">`);continue}if(o==="icon"||o==="favicon"){let f=ut(s),u=f.endsWith(".svg")?' type="image/svg+xml"':f.endsWith(".png")?' type="image/png"':"";e.push(`<link rel="icon" href="${f}"${u}>`);continue}if(o==="favicons"&&Array.isArray(s)){s.forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).map(([d,g])=>`${d}="${ut(g)}"`).join(" ");e.push(`<link rel="icon" ${u}>`)}else typeof f=="string"&&e.push(`<link rel="icon" href="${ut(f)}">`)});continue}if(o==="alternate"&&Array.isArray(s)){s.forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).map(([d,g])=>`${d}="${ut(g)}"`).join(" ");e.push(`<link rel="alternate" ${u}>`)}});continue}let i=["og:","article:","product:","fb:","profile:","book:","business:","music:","video:"],a=["twitter:","DC:","DCTERMS:"],c=i.some(f=>o.startsWith(f)),l=a.some(f=>o.startsWith(f));if(o.startsWith("http-equiv:")){let f=o.replace("http-equiv:","");e.push(`<meta http-equiv="${ut(f)}" content="${ut(s)}">`)}else if(o.startsWith("itemprop:")){let f=o.replace("itemprop:","");e.push(`<meta itemprop="${ut(f)}" content="${ut(s)}">`)}else c?Array.isArray(s)?s.forEach(f=>e.push(`<meta property="${ut(o)}" content="${ut(f)}">`)):e.push(`<meta property="${ut(o)}" content="${ut(s)}">`):l?e.push(`<meta name="${ut(o)}" content="${ut(s)}">`):Array.isArray(s)?s.forEach(f=>e.push(`<meta name="${ut(o)}" content="${ut(f)}">`)):(typeof s=="string"||typeof s=="number"||typeof s=="boolean")&&e.push(`<meta name="${ut(o)}" content="${ut(s)}">`)}if(n||e.splice(1,0,'<meta name="viewport" content="width=device-width, initial-scale=1">'),Array.isArray(t.jsonLd))for(let o of t.jsonLd){if(o==null)continue;let s=typeof o=="string"?o:JSON.stringify(o),i=String(s).replace(/<\/script/gi,"<\\/script");e.push(`<script type="application/ld+json" data-smbls-jsonld="${Ds(s)}">${i}<\/script>`)}if(Array.isArray(t.styles))for(let o of t.styles){if(o==null||!String(o).trim())continue;let s=String(o).replace(/<\/style/gi,"<\\/style");e.push(`<style data-smbls-style="${Ds(s)}">${s}</style>`)}if(Array.isArray(t.scripts))for(let o of t.scripts){if(!o)continue;let s=typeof o=="string",i=s?o:o.src;if(!i&&!(o&&o.body))continue;let a=[];i&&a.push(`src="${ut(i)}"`),s||(o.type&&a.push(`type="${ut(o.type)}"`),o.async&&a.push("async"),o.defer&&a.push("defer"),o.integrity&&a.push(`integrity="${ut(o.integrity)}"`),o.crossorigin&&a.push(`crossorigin="${ut(o.crossorigin)}"`),o.referrerpolicy&&a.push(`referrerpolicy="${ut(o.referrerpolicy)}"`),o.nomodule&&a.push("nomodule"));let c=` data-smbls-script="${ut(i||Ds(o.body||""))}"`;if(!s&&o.body){let l=String(o.body).replace(/<\/script/gi,"<\\/script");e.push(`<script ${a.join(" ")}${c}>${l}<\/script>`)}else e.push(`<script ${a.join(" ")}${c}><\/script>`)}return e.join(`
90
- `)},sE={define:{metadata:(t,e,r)=>{let n=e.context?.document||typeof document<"u"&&document;if(!n)return;let o=Y(()=>{let s=ln(t,e,e.state);Ls(s,n);let i=e.state?.root;v(i)&&(i.$helmet=s)});e.__ref?.__effects&&e.__ref.__effects.push(o)}}},p_={name:"helmet",create(t){if(!t.metadata)return;let e=t.context?.document||typeof document<"u"&&document;if(!e)return;let r=Y(()=>{let n=t.metadata;if(!n)return;let o=ln(n,t,t.state);Ls(o,e)});t.__ref?.__effects&&t.__ref.__effects.push(r)},update(t){let e=t.metadata;if(!e)return;let r=t.context?.document||typeof document<"u"&&document;if(!r)return;let n=ln(e,t,t.state);Ls(n,r)}},WD=sE;Ji();var iE=(t,e,r,n)=>{t&&Zi(t,e,r,n)},aE=(t,e,r)=>{if(!t)return;let n=e.context?.document||typeof document<"u"&&document;if(!n)return;let o=ln(t,e,r);Ls(o,n)},cE=async(t,e)=>{if(!t)return;let r={tag:"fragment",...t},n=async()=>{await e.set(r,{preventDefineUpdate:"$router"})};return e.lazyLoad?window.requestAnimationFrame(n):await n(),r},Is={routes:t=>t,metadata:aE,fetch:iE,$router:cE},lE=(t={})=>{let e={routes:r=>r};return t.metadata!==!1&&(e.metadata=aE),t.fetch!==!1&&(e.fetch=iE),t.router!==!1&&(e.$router=cE),e};var g_={useReset:!0,useVariable:!0,useIconSprite:!0,useSvgSprite:!0,useDocumentTheme:!0,useDefaultIcons:!0,useFontImport:!0,useDefaultConfig:!0},td={initRouter:!0,popState:!0,injectRouterInLinkComponent:!0},ed={...g_,router:td},qD={state:{},pages:{},components:{},router:td,define:Is},fn=qD;D();D();var fE=(t,e)=>B(t.extends)?t.extends:[];D();var m_={};$(m_,{default:()=>XD,getActiveLang:()=>un,getLanguages:()=>Pc,getLocalStateLang:()=>Mc,initPolyglot:()=>nd,loadTranslations:()=>Lc,polyglotPlugin:()=>Ms,setLang:()=>Ic,translate:()=>Dc,upsertTranslation:()=>$c});D();var dE="smbls_lang",KD="smbls_t_",GD="smbls_tv_",$s={get(t){try{return window?.localStorage.getItem(t)}catch{return null}},set(t,e){try{window?.localStorage.setItem(t,e)}catch(r){console.warn("[polyglot] localStorage unavailable:",r.message)}},remove(t){try{window?.localStorage.removeItem(t)}catch(e){console.warn("[polyglot] localStorage unavailable:",e.message)}}},Rc={};function un(){let t=this?.context,e=t?.polyglot;return(this?.state?.root||t?.state?.root)?.lang||t?.state?.lang||e?.defaultLang||"en"}function Pc(){let t=this?.context?.polyglot;return t?t.languages?t.languages:t.translations?Object.keys(t.translations):[]:[]}var rd=(t,e)=>{if(!t||!e)return;if(t[e]!==void 0)return t[e];if(e.indexOf(".")===-1)return;let r=e.split("."),n=t;for(let o=0;o<r.length;o++){if(n==null)return;n=n[r[o]]}return n},uE=(t,e,r)=>{let n=e.lastIndexOf(".");if(n===-1)return t[e+"_"+r];let o=rd(t,e.substring(0,n));if(o!=null)return o[e.substring(n+1)+"_"+r]};function Dc(t,e){if(!t)return"";let r=this?.context,n=r?.polyglot,o=e||this.call("getActiveLang"),s=this?.state;if(s){let l=uE(s,t,o);if(l!==void 0)return l}if(n?.translations){let l=n.translations[o];if(l){let f=rd(l,t);if(f!==void 0)return f}}let a=(s?.root||r?.state?.root)?.translations;if(a){let l=a[o];if(l){let f=rd(l,t);if(f!==void 0)return f}}let c=n?.defaultLang||"en";if(s){let l=uE(s,t,c);if(l!==void 0)return l}if(n?.translations){let l=n.translations[c];if(l){let f=rd(l,t);if(f!==void 0)return f}}return t}async function Lc(t){let e=this?.context,r=e?.polyglot,n=this?.state?.root||e?.state?.root;if(!r||!n)return;let o=r.storagePrefix||KD,s=r.storageVersionPrefix||(r.storagePrefix?r.storagePrefix.replace(/_$/,"v_"):GD);if(r.translations&&r.translations[t]&&!r.fetch||!r.fetch||r._fetchFailed?.[t])return;if(!n.translations?.[t]){let c=$s.get(o+t);if(c)try{let l=JSON.parse(c),f={translations:{...n.translations||{}}};f.translations[t]=l,n.update&&n.update(f)}catch(l){console.warn("[polyglot] Failed to apply language update:",l.message)}}let i=(r.storagePrefix||"smbls")+":"+t;if(Rc[i])return Rc[i];let a=this;return Rc[i]=(async()=>{try{let c=r.fetch,l=parseInt($s.get(s+t),10)||0,f,u,d;if(R(c)){let p=await c(t,l,a);if(!p||p.changed===!1)return;f=p.translations||p.data||p,u=p.version||0,d=!0}else if(v(c)){let p=a.getDB||(()=>e.fetch),h=R(p)?await p.call(a):e.fetch;if(!h)return;let m=c.rpc||c.from||"get_translations_if_changed",_={p_lang:t,p_cached_version:l,...c.params||{}},x=await h.rpc({from:m,params:_});if(x.error)throw r._fetchFailed||(r._fetchFailed={}),r._fetchFailed[t]=!0,x.error;let y=x.data;if(!y||!y.changed)return;f=y.translations||{},u=y.version||0,d=!0}else return;if(!d||!f)return;$s.set(o+t,JSON.stringify(f)),u&&$s.set(s+t,String(u));let g={translations:{...n.translations||{}}};g.translations[t]=f,n.update&&n.update(g)}catch(c){if(r.verbose!==!1){let l=c?.message||c?.details||(typeof c=="object"?JSON.stringify(c):String(c));console.warn("[polyglot] Failed to load translations for",t,"-",l)}}finally{delete Rc[i]}})(),Rc[i]}var YD=(t,e,r)=>{let n=t.__ref;if(!n||n.contentManaged||r==null||typeof r=="object")return;let o=n.__textNode;if(!o||o.parentNode!==e)return;let s=String(r);o.nodeValue!==s&&(o.nodeValue=s)};async function Ic(t,e){let r=this?.context,n=r?.polyglot,o=this?.state?.root||r?.state?.root,s=r?.document||globalThis.document;if(!o)return;if(e?.persist!==!1){let l=n?.storageLangKey||dE;$s.set(l,t)}if(s?.documentElement&&(s.documentElement.lang=t),this.call("getActiveLang")===t)return;n?.fetch&&await this.call("loadTranslations",t),r?.state&&(r.state.lang=t);let i=n?.translations?.[t],a={lang:t},c=l=>zi(r,l,o);if(i&&typeof i=="object")for(let l in i){if(!c(l))continue;let f=i[l];(Array.isArray(f)||typeof f=="string"||typeof f=="number")&&(a[l]=f)}o.update&&o.update(a);for(let l in a)l!=="lang"&&Ze(r,l,a[l]);if(i&&typeof i=="object")for(let l in i){if(!c(l))continue;let f=i[l];if(f&&typeof f=="object"&&!Array.isArray(f)&&o[l]&&typeof o[l]=="object"&&!Array.isArray(o[l])){for(let u in f)o[l][u]=f[u];Ze(r,l,o[l])}}if(s&&i){let l=s.querySelectorAll("[data-key]");for(let f of l){let u=f.ref;if(!u)continue;let d=u.__ref?.__exec?.text;if(typeof d=="string"&&d.includes("{{"))try{YD(u,f,u.call("replaceLiteralsWithObjectFields",d,u.state))}catch{}}}}async function $c(t,e,r){let n=this?.context,o=n?.polyglot,s=this?.state?.root||n?.state?.root;if(s?.translations?.[e]&&(s.translations[e][t]=r),o?.translations?.[e]&&(o.translations[e][t]=r),o?.fetch&&v(o.fetch)){let i=this.getDB||(()=>n.fetch),a=R(i)?await i.call(this):n.fetch;if(!a)return;let c=o.fetch.table||"translations",l=await a.upsert({from:c,data:{key:t,lang:e,text:r}});if(l?.error)throw l.error;return l.data}}async function nd(){let t=this?.context,e=t?.polyglot;if(!e)return;let r=this?.state?.root||t?.state?.root;if(!r)return;let n=e.storageLangKey||dE,s=$s.get(n)||un.call(this),i=t?.document||globalThis.document;i?.documentElement&&(i.documentElement.lang=s),r.update&&r.lang!==s&&r.update({lang:s}),e.fetch&&!(e.translations&&e.translations[s])&&await this.call("loadTranslations",s)}function Mc(t){try{let e=un.call(this),r=this?.state;if(!r)return"";let n=t.lastIndexOf(".");if(n===-1)return r[t+e]??"";let o=t.substring(0,n).split("."),s=r;for(let i=0;i<o.length;i++){if(s==null)return"";s=s[o[i]]}return s==null?"":s[t.substring(n+1)+e]??""}catch{return""}}var Ms={name:"polyglot",render(t){t.parent&&t.parent.parent||t.__polyglotInitialized||(t.__polyglotInitialized=!0,nd.call(t))}},XD=Ms;Ji();var b_={};$(b_,{SYSTEM_METRICS:()=>Fc,capsizeHandler:()=>y_,capsizePlugin:()=>sd,computeCapsize:()=>pE,default:()=>ZD,resolveFontSizePx:()=>hE,resolveMetrics:()=>gE});var Fc={arial:{capHeight:716,ascent:1854,descent:-434,lineGap:67,unitsPerEm:2048},helvetica:{capHeight:714,ascent:770,descent:-230,lineGap:0,unitsPerEm:1e3},"helvetica neue":{capHeight:714,ascent:952,descent:-213,lineGap:28,unitsPerEm:1e3},georgia:{capHeight:1419,ascent:1878,descent:-449,lineGap:0,unitsPerEm:2048},"times new roman":{capHeight:1356,ascent:1825,descent:-443,lineGap:87,unitsPerEm:2048},"courier new":{capHeight:1170,ascent:1705,descent:-615,lineGap:0,unitsPerEm:2048},verdana:{capHeight:1489,ascent:2059,descent:-430,lineGap:0,unitsPerEm:2048},roboto:{capHeight:1456,ascent:1900,descent:-500,lineGap:0,unitsPerEm:2048},"open sans":{capHeight:1462,ascent:2189,descent:-600,lineGap:0,unitsPerEm:2048},inter:{capHeight:1490,ascent:2048,descent:-512,lineGap:0,unitsPerEm:2048},lato:{capHeight:1434,ascent:1974,descent:-426,lineGap:0,unitsPerEm:2e3},"source sans":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},"source sans pro":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},"source sans 3":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},montserrat:{capHeight:700,ascent:968,descent:-251,lineGap:0,unitsPerEm:1e3},poppins:{capHeight:700,ascent:1050,descent:-350,lineGap:100,unitsPerEm:1e3},raleway:{capHeight:710,ascent:1e3,descent:-250,lineGap:0,unitsPerEm:1e3},"dm sans":{capHeight:700,ascent:992,descent:-312,lineGap:0,unitsPerEm:1e3},nunito:{capHeight:705,ascent:1011,descent:-353,lineGap:0,unitsPerEm:1e3},"work sans":{capHeight:684,ascent:930,descent:-243,lineGap:0,unitsPerEm:1e3},manrope:{capHeight:708,ascent:980,descent:-300,lineGap:0,unitsPerEm:1e3},"ibm plex sans":{capHeight:698,ascent:1025,descent:-275,lineGap:0,unitsPerEm:1e3},"plus jakarta sans":{capHeight:720,ascent:1060,descent:-300,lineGap:0,unitsPerEm:1e3}},od=t=>parseFloat(t.toFixed(4)),pE=(t,e,r)=>{let{ascent:n,descent:o,lineGap:s,unitsPerEm:i,capHeight:a}=e,c=Math.abs(o),l=n+c+s,f=r!==void 0?r:l/i*t,u=f/t,d=l/i,g=(n-a+s/2)/i-(u-d)/2,p=(c+s/2)/i-(u-d)/2;return{fontSize:`${od(t/16)}rem`,lineHeight:`${od(f)}px`,capHeightTrim:`${od(-g)}em`,baselineTrim:`${od(-p)}em`}},hE=(t,e)=>{if(typeof t=="number")return t;let r=e?.designSystem;if(!r)return null;let{typography:n}=r;if(n?.sequence){let s=String(t).toUpperCase(),i=n.sequence[s];if(i)return i.decimal||i.val}let o=parseFloat(t);return isNaN(o)?null:typeof t=="string"&&t.endsWith("rem")?o*(r.typography?.browserDefault||16):o},gE=(t,e)=>{let n=e?.designSystem?.font_family||{};if(t){let s=n[t];if(s?.metrics)return s.metrics;let i=String(t).toLowerCase().replace(/['"]/g,"").trim();if(Fc[i])return Fc[i]}let o=n.default||Object.keys(n)[0];if(o){let s=n[o];if(s?.metrics)return s.metrics;if(s?.value&&Array.isArray(s.value))for(let i of s.value){let a=i.toLowerCase().replace(/['"]/g,"").trim();if(Fc[a])return Fc[a]}}return null},y_=(t,e,r,n)=>{if(!t)return;let o=hE(e.fontSize,n);if(!o)return;let s=gE(e.fontFamily,n);if(!s)return;let i=e.lineHeight?parseFloat(e.lineHeight):void 0,{lineHeight:a,capHeightTrim:c,baselineTrim:l}=pE(o,s,i),f={};return e.lineHeight||(f.lineHeight=a),f["::before"]={content:'""',marginBottom:c,display:"table"},f["::after"]={content:'""',marginTop:l,display:"table"},f},sd={name:"capsize",init(t){t.useCapsize===void 0&&t.fontSize&&(t.useCapsize=!0)}},ZD=sd;var C_={};$(C_,{PRESERVE_VALUE_KEYS:()=>Vt,SKIP_INLINE_KEYS:()=>dn,abbrToProp:()=>Bt,decode:()=>wE,encode:()=>yE,expand:()=>io,isComponentKey:()=>Ue,isSelectorKey:()=>ze,parse:()=>ao,parseFurther:()=>lo,propToAbbr:()=>Re,shorten:()=>Nc,shorthandPlugin:()=>jc,stringify:()=>so,stringifyFurther:()=>co});var Re={attr:"at",childExtends:"cex",childExtendsRecursive:"cexr",childProps:"cp",children:"ch",childrenAs:"cha",class:"cl",content:"cnt",context:"ctx",data:"dt",extends:"ext",hide:"hd",html:"htm",if:"if",ignoreChildExtends:"icex",key:"ky",query:"qy",routes:"rt",scope:"scp",show:"shw",state:"st",style:"sy",tag:"tg",text:"tx",align:"aln",boxSize:"bsz",flow:"fl",heightRange:"hr",horizontalInset:"hi",round:"rnd",shadow:"shd",size:"sz",templateColumns:"tcol",verticalInset:"vi",widthRange:"wr",wrap:"wrp",aspectRatio:"ar",blockSize:"bks",boxSizing:"bxs",height:"h",inlineSize:"ins",margin:"m",marginBottom:"mb",marginLeft:"ml",marginRight:"mr",marginTop:"mt",maxBlockSize:"mxbs",maxHeight:"mxh",maxInlineSize:"mxis",maxWidth:"mxw",minBlockSize:"mnbs",minHeight:"mnh",minInlineSize:"mnis",minWidth:"mnw",padding:"p",paddingBottom:"pb",paddingInline:"pil",paddingLeft:"pl",paddingRight:"pr",paddingTop:"pt",width:"w",alignContent:"ac",alignItems:"ai",alignSelf:"as",flex:"fx",flexBasis:"fxb",flexDirection:"fxd",flexFlow:"fxf",flexGrow:"fxg",flexShrink:"fxs",flexWrap:"fxw",gap:"g",justifyContent:"jc",justifyItems:"ji",justifySelf:"js",order:"od",placeContent:"pcn",placeItems:"pit",placeSelf:"psl",rowGap:"rg",columnGap:"cg",gridArea:"ga",gridAutoColumns:"gac",gridAutoFlow:"gaf",gridAutoRows:"gar",gridColumn:"gc",gridColumnEnd:"gce",gridColumnStart:"gcs",gridRow:"gr",gridRowEnd:"gre",gridRowStart:"grs",gridTemplateAreas:"gta",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",bottom:"bot",float:"flt",inset:"ist",left:"lft",position:"pos",right:"rgt",top:"tp",zIndex:"zi",clear:"clr",contain:"ctn",cursor:"cur",display:"d",opacity:"op",overflow:"ov",overflowX:"ovx",overflowY:"ovy",pointerEvents:"pe",resize:"rsz",userSelect:"us",visibility:"vis",background:"bg",backgroundAttachment:"bga",backgroundBlendMode:"bgbm",backgroundClip:"bgcl",backgroundColor:"bgc",backgroundImage:"bgi",backgroundOrigin:"bgo",backgroundPosition:"bgp",backgroundPositionX:"bgpx",backgroundPositionY:"bgpy",backgroundRepeat:"bgr",backgroundRepeatX:"bgrx",backgroundRepeatY:"bgry",backgroundSize:"bgs",color:"c",theme:"thm",themeModifier:"thmm",border:"bd",borderBottom:"bdb",borderBottomLeftRadius:"bdblr",borderBottomRightRadius:"bdbrr",borderCollapse:"bdcl",borderColor:"bdc",borderImage:"bdi",borderImageOutset:"bdio",borderImageRepeat:"bdir",borderImageSlice:"bdis",borderImageSource:"bdisrc",borderImageWidth:"bdiw",borderLeft:"bdl",borderRadius:"bdr",borderRight:"bdrg",borderSpacing:"bdsp",borderStyle:"bdst",borderTop:"bdt",borderTopLeftRadius:"bdtlr",borderTopRightRadius:"bdtrr",borderWidth:"bdw",outline:"ol",outlineColor:"olc",outlineOffset:"olo",outlineStyle:"ols",outlineWidth:"olw",boxShadow:"bxsh",textShadow:"txsh",direction:"dir",fontDisplay:"fdi",fontFamily:"ff",fontFeatureSettings:"ffs",fontKerning:"fk",fontOpticalSizing:"fos",fontPalette:"fpl",fontSize:"fs",fontSizeAdjust:"fsa",fontSmooth:"fsm",fontStretch:"fsr",fontStyle:"fsy",fontSynthesis:"fsyn",fontVariant:"fv",fontVariationSettings:"fvs",fontWeight:"fw",hyphens:"hyp",letterSpacing:"ls",lineHeight:"lh",tabSize:"tsz",textAlign:"ta",textDecoration:"td",textDecorationColor:"tdc",textDecorationLine:"tdl",textDecorationStyle:"tds",textIndent:"ti",textOverflow:"tov",textStroke:"tsk",textTransform:"tt",unicodeBidi:"ub",verticalAlign:"va",whiteSpace:"ws",wordBreak:"wbr",wordSpacing:"wsp",wordWrap:"wwr",writingMode:"wm",captionSide:"cps",counterIncrement:"ci",counterReset:"cr",emptyCells:"ec",listStyle:"lst",listStyleImage:"lsi",listStylePosition:"lsp",listStyleType:"lsty",quotes:"qt",tableLayout:"tl",columnCount:"cc",columnFill:"cf",columnRule:"crl",columnRuleColor:"crlc",columnRuleStyle:"crls",columnRuleWidth:"crlw",columnSpan:"cspn",columnWidth:"cwi",columns:"col",backdropFilter:"bdf",boxDecorationBreak:"bxdb",clipPath:"cpth",filter:"fil",isolation:"iso",mixBlendMode:"mbm",objectFit:"obf",objectPosition:"obp",perspective:"prs",perspectiveOrigin:"prso",willChange:"wc",transform:"tf",transformOrigin:"tfo",transformStyle:"tfs",transition:"trn",transitionDelay:"trnd",transitionDuration:"trndr",transitionProperty:"trnp",transitionTimingFunction:"trntf",animation:"an",animationDelay:"and",animationDirection:"andr",animationDuration:"andur",animationFillMode:"anfm",animationIterationCount:"anic",animationName:"ann",animationPlayState:"anps",animationTimingFunction:"antf",scrollBehavior:"sb",scrollMargin:"smr",scrollMarginBottom:"smrb",scrollMarginLeft:"smrl",scrollMarginRight:"smrr",scrollMarginTop:"smrt",scrollPadding:"spd",scrollPaddingBottom:"spdb",scrollPaddingLeft:"spdl",scrollPaddingRight:"spdr",scrollPaddingTop:"spdt",scrollSnapAlign:"ssa",scrollSnapStop:"sss",scrollSnapType:"sst",breakAfter:"bka",breakBefore:"bkb",breakInside:"bki",pageBreakAfter:"pbka",pageBreakBefore:"pbkb",pageBreakInside:"pbki",accessKey:"ack",className:"cn",contentEditable:"ced",contextMenu:"cmu",draggable:"drg",hidden:"hid",id:"id",is:"is",lang:"lng",nonce:"nnc",spellCheck:"spc",tabIndex:"tbi",title:"ttl",translate:"trl",accept:"acp",acceptCharset:"accs",action:"act",autoComplete:"atc",autoFocus:"atf",capture:"cap",challenge:"chg",checked:"chk",cols:"cls",colSpan:"csn",controls:"ctl",default:"def",defer:"dfr",disabled:"dis",encType:"ect",form:"frm",formAction:"fac",formEncType:"fect",formMethod:"fme",formNoValidate:"fnv",formTarget:"ftg",high:"hgh",inputMode:"imd",kind:"knd",label:"lbl",list:"lis",loop:"lp",low:"lw",max:"mx",maxLength:"mxl",method:"mtd",min:"mn",minLength:"mnl",multiple:"mul",muted:"mut",name:"nm",open:"opn",optimum:"opt",pattern:"ptn",placeholder:"phd",readOnly:"ro",required:"req",reversed:"rev",rows:"rws",rowSpan:"rsn",selected:"sel",span:"spn",start:"srt",step:"stp",type:"typ",value:"val",download:"dl",href:"hrf",hrefLang:"hrl",ping:"png",referrerPolicy:"rfp",rel:"rl",target:"tgt",allow:"alw",allowFullScreen:"afs",allowPaymentRequest:"apr",alt:"alt",cellPadding:"cpg",cellSpacing:"csg",cite:"cit",coords:"crd",crossOrigin:"cor",dateTime:"dtm",fetchPriority:"fpr",headers:"hds",httpEquiv:"hte",integrity:"itg",isMap:"ism",keyType:"kty",loading:"ldg",manifest:"mft",media:"mda",poster:"pst",preload:"prl",radioGroup:"rdg",sandbox:"sbx",scoped:"scod",seamless:"sml",shape:"shp",sizes:"szs",src:"src",srcDoc:"srd",srcLang:"srl",srcSet:"srs",useMap:"ump",ariaActiveDescendant:"aad",ariaAtomic:"aat",ariaBusy:"abu",ariaChecked:"achk",ariaControls:"acl",ariaCurrent:"acr",ariaDescribedBy:"adb",ariaDetails:"adt",ariaDisabled:"adis",ariaDropEffect:"ade",ariaErrorMessage:"aem",ariaExpanded:"aexp",ariaGrabbed:"agr",ariaHasPopup:"ahp",ariaHidden:"ahid",ariaInvalid:"ainv",ariaLabel:"alb",ariaLabelledBy:"alby",ariaLive:"alv",ariaModal:"amod",ariaMultiSelectable:"ams",ariaOrientation:"aor",ariaOwns:"aow",ariaPosInSet:"apis",ariaPressed:"aprs",ariaReadOnly:"aro",ariaRelevant:"arl",ariaRequired:"areq",ariaSelected:"asel",ariaSetSize:"assz",ariaValueMax:"avmx",ariaValueMin:"avmn",ariaValueNow:"avn",role:"role",onInit:"@in",onRender:"@rn",onUpdate:"@up",onStateChange:"@sc",onStateUpdate:"@su",onClick:"@ck",onContextMenu:"@cm",onDblClick:"@dc",onMouseDown:"@md",onMouseEnter:"@me",onMouseLeave:"@ml",onMouseMove:"@mm",onMouseOut:"@mo",onMouseOver:"@mv",onMouseUp:"@mu",onKeyDown:"@kd",onKeyPress:"@kp",onKeyUp:"@ku",onBlur:"@bl",onFocus:"@fc",onFocusIn:"@fi",onFocusOut:"@fo",onBeforeInput:"@bi",onChange:"@cg",onFormData:"@fd",onInput:"@ip",onInvalid:"@iv",onReset:"@rs",onSearch:"@sr",onSelect:"@sl",onSubmit:"@sm",onTouchCancel:"@tc",onTouchEnd:"@te",onTouchMove:"@tm",onTouchStart:"@ts",onPointerCancel:"@pc",onPointerDown:"@pd",onPointerEnter:"@pe",onPointerLeave:"@ple",onPointerMove:"@pm",onPointerOut:"@po",onPointerOver:"@pov",onPointerUp:"@pu",onDrag:"@dg",onDragEnd:"@dge",onDragEnter:"@dgn",onDragLeave:"@dgl",onDragOver:"@dgo",onDragStart:"@dgs",onDrop:"@dp",onResize:"@rz",onScroll:"@scl",onWheel:"@wh",onCopy:"@cy",onCut:"@ct",onPaste:"@pt",onCompositionEnd:"@cpe",onCompositionStart:"@cps",onCompositionUpdate:"@cpu",onAnimationEnd:"@ae",onAnimationIteration:"@ai",onAnimationStart:"@as",onTransitionEnd:"@tre",onTransitionStart:"@trs",onAbort:"@ab",onCanPlay:"@cap",onCanPlayThrough:"@cpt",onDurationChange:"@duc",onEmptied:"@em",onEncrypted:"@enc",onEnded:"@end",onError:"@er",onLoad:"@ld",onLoadedData:"@ldd",onLoadedMetadata:"@ldm",onPause:"@pa",onPlay:"@pl",onPlaying:"@plg",onProgress:"@prg",onRateChange:"@rc",onSeeked:"@sk",onSeeking:"@skg",onStalled:"@stl",onSuspend:"@ssp",onTimeUpdate:"@tu",onVolumeChange:"@vc",onWaiting:"@wt",icon:"ico",iconText:"ict",lookup:"lkp",router:"rtr",shapeModifier:"shpm"},Bt=Object.create(null);for(let t in Re)Bt[Re[t]]=t;var __=Object.create(null);for(let t in Re){let e=Re[t];if(__[e])throw new Error(`Duplicate abbreviation "${e}" for "${t}" \u2014 already used by "${__[e]}"`);__[e]=t}var Vt=new Set(["state","st","scope","scp","attr","at","style","sy","data","dt","context","ctx","query","qy","class","cl"]),dn=new Set(["text","tx","html","htm","content","cnt","placeholder","phd","src","href","hrf"]);function Ue(t){return/^[A-Z]/.test(t)}function ze(t){return/^[:@.!$>&]/.test(t)||t.startsWith("> ")}function yE(t){if(!t||typeof t!="object")return"";let e=[];for(let r in t){let n=t[r];if(typeof n=="function"||n!==null&&typeof n=="object"&&!Array.isArray(n)||n===void 0)continue;let o=Re[r]||r;if(n===!0)e.push(o);else if(n===!1)e.push("!"+o);else if(Array.isArray(n)){let s=n.map(i=>id(i));e.push(o+":"+s.join(","))}else e.push(o+":"+id(n))}return e.join(" ")}function id(t){return String(t).replace(/ /g,"_")}function Nc(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?Nc(r):r});let e={};for(let r in t){let n=t[r];if(Ue(r)){e[r]=w_(n);continue}if(ze(r)){e[r]=w_(n);continue}let o=Re[r]||r;if(Vt.has(r)||Vt.has(o)){e[o]=n;continue}e[o]=w_(n)}return e}function w_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?Nc(e):e}):typeof t=="object"?Nc(t):t}function so(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(n){return n!==null&&typeof n=="object"?so(n):n});let e={},r=[];for(let n in t){let o=t[n];if(Ue(n)){e[n]=mE(o);continue}if(ze(n)){e[n]=mE(o);continue}let s=Re[n]||n;if(Vt.has(n)||Vt.has(s)){e[s]=o;continue}if(typeof o=="function"){e[s]=o;continue}if(o==null){e[s]=o;continue}if(dn.has(n)||dn.has(s)){e[s]=o;continue}if(Array.isArray(o)){if(o.some(function(a){return a!==null&&typeof a=="object"})){e[s]=o.map(function(a){return a!==null&&typeof a=="object"?so(a):a});continue}if(o.length<=1){e[s]=o;continue}r.push(s+":"+o.map(id).join(","));continue}if(typeof o=="object"){e[s]=so(o);continue}o===!0?r.push(s):o===!1?r.push("!"+s):typeof o=="number"||typeof o=="string"&&(o.includes(",")||o.includes("_"))?e[s]=o:r.push(s+":"+id(o))}return r.length&&(e.in=r.join(" ")),e}function mE(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?so(e):e}):typeof t=="object"?so(t):t}function wE(t){if(!t||typeof t!="string")return{};let e={},r=xE(t);for(let n of r){if(n.startsWith("!")){let c=n.slice(1),l=Bt[c]||c;e[l]=!1;continue}let o=n.indexOf(":");if(o===-1){let c=Bt[n]||n;e[c]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s;if(i.includes(",")){e[a]=i.split(",").map(bE);continue}e[a]=bE(i)}return e}function xE(t){return t.trim().split(/\s+/).filter(Boolean)}function bE(t){let e=t.replace(/_/g," ");return/^-?\d+(\.\d+)?$/.test(e)?Number(e):e}function _E(t){return t.replace(/_/g," ")}function JD(t){if(!t||typeof t!="string")return{};let e={},r=xE(t);for(let n of r){if(n.startsWith("!")){let c=n.slice(1),l=Bt[c]||c;e[l]=!1;continue}let o=n.indexOf(":");if(o===-1){let c=Bt[n]||n;e[c]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s;if(i.includes(",")){e[a]=i.split(",").map(_E);continue}e[a]=_E(i)}return e}function io(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?io(r):r});let e={};for(let r in t){let n=t[r];if(Ue(r)){e[r]=x_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){e[r]=x_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=x_(n)}return e}function x_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?io(e):e}):typeof t=="object"?io(t):t}function ao(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?ao(r):r});let e={};if(typeof t.in=="string"){let r=JD(t.in);for(let n in r)e[n]=r[n]}for(let r in t){if(r==="in")continue;let n=t[r];if(Ue(r)){e[r]=S_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){e[r]=S_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=S_(n)}return e}function S_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?ao(e):e}):typeof t=="object"?ao(t):t}function SE(t){return String(t).replace(/\\/g,"\\\\").replace(/_/g,"\\_").replace(/,/g,"\\,").replace(/ /g,"_")}function QD(t){let e="",r=0;for(;r<t.length;){if(t[r]==="\\"&&r+1<t.length){let n=t[r+1];if(n===","||n==="_"||n==="\\"){e+=n,r+=2;continue}}t[r]==="_"?e+=" ":e+=t[r],r++}return e}function tL(t){let e=[],r="",n=0;for(;n<t.length;){if(t[n]==="\\"&&n+1<t.length){r+=t[n]+t[n+1],n+=2;continue}if(t[n]===","){e.push(r),r="",n++;continue}r+=t[n],n++}return e.push(r),e}function kE(t){if(t==null||typeof t!="object"||Array.isArray(t))return!1;let e=Object.keys(t);return e.length===1&&e[0]==="in"&&typeof t.in=="string"}function co(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(n){return n!==null&&typeof n=="object"?co(n):n});let e={},r=[];for(let n in t){let o=t[n];if(Ue(n)){let i=vE(o);e[n]=kE(i)?i.in:i;continue}if(ze(n)){let i=vE(o);e[n]=kE(i)?i.in:i;continue}let s=Re[n]||n;if(Vt.has(n)||Vt.has(s)){e[s]=o;continue}if(typeof o=="function"){e[s]=o;continue}if(o==null){e[s]=o;continue}if(dn.has(n)||dn.has(s)){e[s]=o;continue}if(Array.isArray(o)){if(o.some(function(a){return a!==null&&typeof a=="object"})){e[s]=o.map(function(a){return a!==null&&typeof a=="object"?co(a):a});continue}if(o.length<=1){e[s]=o;continue}r.push(s+":"+o.map(SE).join(","));continue}if(typeof o=="object"){e[s]=co(o);continue}if(o===!0){r.push(s);continue}if(o===!1){r.push("!"+s);continue}if(typeof o=="number"){r.push(s+":#"+o);continue}r.push(s+":"+SE(o))}return r.length&&(e.in=r.join(" ")),e}function vE(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?co(e):e}):typeof t=="object"?co(t):t}function CE(t){return t.startsWith("#")&&/^#-?\d+(\.\d+)?$/.test(t)?Number(t.slice(1)):QD(t)}function k_(t){if(!t||typeof t!="string")return{};let e={},r=t.trim().split(/\s+/).filter(Boolean);for(let n of r){if(n.startsWith("!")){let l=n.slice(1),f=Bt[l]||l;e[f]=!1;continue}let o=n.indexOf(":");if(o===-1){let l=Bt[n]||n;e[l]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s,c=tL(i);if(c.length>1){e[a]=c.map(CE);continue}e[a]=CE(i)}return e}function lo(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?lo(r):r});let e={};if(typeof t.in=="string"){let r=k_(t.in);for(let n in r)e[n]=r[n]}for(let r in t){if(r==="in")continue;let n=t[r];if(Ue(r)){typeof n=="string"?e[r]=k_(n):e[r]=v_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){typeof n=="string"?e[r]=k_(n):e[r]=v_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=v_(n)}return e}function v_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?lo(e):e}):typeof t=="object"?lo(t):t}var eL={shorten:io,stringify:ao,stringifyFurther:lo};function rL(t,e){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(n=>e(n));let r={};for(let n in t){let o=t[n];r[n]=o&&typeof o=="object"?e(o):o}return r}var nL=["components","pages","snippets"],jc={name:"shorthand",prepareContext(t){let e=t.shorthand;if(!e)return;let n=eL[e===!0?"shorten":e];if(n){for(let o of nL)t[o]&&(t[o]=rL(t[o],n));t.app&&typeof t.app=="object"&&(t.app=n(t.app))}}};var F_={};$(F_,{LEVELS:()=>Bc,analyzePlugin:()=>Ns,attachBrowserListeners:()=>gd,attachNetworkListeners:()=>Uc,classifyEvent:()=>D_,createAnalyzeState:()=>md,createBeaconSink:()=>$_,createConsoleSink:()=>L_,createDedupe:()=>O_,createEnrich:()=>A_,createMemorySink:()=>I_,createPipeline:()=>fd,createRedact:()=>ld,createRemoteSink:()=>dd,createSample:()=>R_,createSummarize:()=>T_,default:()=>Ns,emitFetchEvent:()=>LE,makeEvent:()=>tt,meetsLevel:()=>ad,normalizeLevel:()=>Vc,resolveSinks:()=>hd,summarizeElement:()=>fo});var oL=0,sL=()=>`${Date.now().toString(36)}-${(oL++).toString(36)}`,tt=(t,e,r={})=>({id:sL(),ts:Date.now(),type:t,level:e,...r}),iL=t=>{let e=[],r=t,n=0;for(;r&&n<32;)r.key!=null&&e.unshift(String(r.key)),r=r.parent,n++;return e.join(" > ")},fo=t=>t?{key:t.key!=null?String(t.key):null,name:t.__name||t.name||null,path:iL(t),tag:t.tag||null,component:t.component||null,route:t.context?.routerOptions?.currentRoute||null}:null;var Fs=t=>t?.context?.analyze,aL={init:{category:"lifecycle",type:"lifecycle",level:"debug"},create:{category:"lifecycle",type:"lifecycle",level:"debug"},render:{category:"lifecycle",type:"lifecycle",level:"debug"},beforeRemove:{category:"lifecycle",type:"lifecycle",level:"debug"},remove:{category:"lifecycle",type:"lifecycle",level:"debug"}},cL=(t,{category:e,type:r,level:n})=>o=>{let s=Fs(o);!s||!s.shouldCapture(e)||s.emit(tt(r,n,{hook:t,element:fo(o)}))},EE=t=>(e,r)=>{let n=Fs(e);!n||!n.shouldCapture("state")||n.emit(tt("state","debug",{hook:t,element:fo(e),changedKeys:r?.changedKeys||null}))},Ns={name:"analyze",error(t,e){let r=Fs(t);if(!r||r.config.enabled===!1||!r.shouldCapture("errors"))return;let n=e?.error||e?.err||(e instanceof Error?e:null);r.emit(tt("error","error",{hook:e?.hook||"error",element:fo(t),error:n,message:n?.message||(typeof e?.message=="string"?e.message:null)}))},renderRouter(t){let e=Fs(t);e&&(!e.shouldCapture("navigation")&&!e.shouldCapture("lifecycle")||e.emit(tt("navigation","info",{hook:"renderRouter",route:t.context?.routerOptions?.currentRoute||null})))},beforeUpdate(t){let e=Fs(t);!e||!e.shouldCapture("updates")||t.__ref&&(t.__ref.__analyzeUpdateStart=typeof performance<"u"?performance.now():Date.now())},update(t){let e=Fs(t);if(!e||!e.shouldCapture("updates"))return;let r=null;t.__ref?.__analyzeUpdateStart!=null&&(r=(typeof performance<"u"?performance.now():Date.now())-t.__ref.__analyzeUpdateStart,t.__ref.__analyzeUpdateStart=null),e.emit(tt("update","debug",{hook:"update",element:fo(t),durationMs:r}))},beforeStateUpdate:EE("beforeStateUpdate"),stateUpdate:EE("stateUpdate")};for(let[t,e]of Object.entries(aL))Ns[t]=cL(t,e);D();var Bc={error:0,warn:1,info:2,debug:3,trace:4};var ad=(t,e)=>{let r=Bc[t],n=Bc[e];return r==null||n==null?!0:r<=n},Vc=t=>Bc[t]!=null?t:"warn";D();var cd=/password|token|secret|ssn|card|cvv|pin|apikey|api_key|auth|email|otp/i;var lL=(t,e)=>{for(let r of e)if(r instanceof RegExp){if(r.test(t))return!0}else if(typeof r=="string"&&t.toLowerCase().includes(r.toLowerCase()))return!0;return!1},fL=(t,e)=>{if(e!=="redact"){if(e==="hash"){let r=0,n=String(t);for(let o=0;o<n.length;o++)r=(r<<5)-r+n.charCodeAt(o)|0;return`#${(r>>>0).toString(36)}`}return"***"}},E_=(t,e,r,n)=>{if(n>6||t==null||typeof t!="object")return t;if(Array.isArray(t))return t.map(s=>E_(s,e,r,n+1));let o={};for(let s of Object.keys(t))if(lL(s,e)||cd.test(s)){let a=fL(t[s],r);a!==void 0&&(o[s]=a)}else o[s]=E_(t[s],e,r,n+1);return o},ld=(t=[],e="mask")=>{let r=Array.isArray(t)?t:[t];return n=>{if(!n)return n;let{id:o,ts:s,type:i,level:a,hook:c,error:l,message:f,durationMs:u,element:d,target:g,...p}=n,h=E_(p,r,e,0);return{id:o,ts:s,type:i,level:a,hook:c,error:l,message:f,durationMs:u,element:d,target:g,...h}}};var A_=t=>{let e=`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,8)}`,r=typeof navigator<"u"?navigator.userAgent:null,n=t.config.buildHash||null,o=t.config.appId||null;return s=>{if(!s)return s;let i=t.context?.routerOptions?.currentRoute||null,a=E,c=a&&a.innerWidth?{w:a.innerWidth,h:a.innerHeight}:null;return{...s,session:e,app:{id:o,build:n,route:i},meta:{ua:r,viewport:c}}}},T_=()=>t=>{if(!t)return t;if(t.element&&typeof t.element=="object"){let e=t.element;(e.node||e.parent||e.__ref)&&(t={...t,element:{key:e.key!=null?String(e.key):null,name:e.__name||e.name||null,tag:e.tag||null,component:e.component||null}})}return t.error instanceof Error&&(t={...t,error:{name:t.error.name,message:t.error.message,stack:t.error.stack}}),t},O_=(t=1e3,e=500)=>{let r=new Map;return n=>{if(!n)return n;let o=`${n.type}:${n.level}:${n.message||""}:${n.error?.message||""}`,s=r.get(o),i=n.ts||Date.now();if(s&&i-s<t)return null;if(r.set(o,i),r.size>e){let a=Math.ceil(e/10),c=0;for(let l of r.keys()){if(c++>=a)break;r.delete(l)}}return n}},R_=t=>e=>{if(!e)return e;let r=t[e.type];return r==null||r>=1?e:Math.random()>r?null:e},AE={redact:t=>ld(t.config.redact||[],t.config.maskStrategy),enrich:t=>A_(t),summarize:()=>T_(),dedupe:t=>O_(t.config.cache?.dedupeWindowMs||1e3),sample:t=>R_(t.config.sample||{})},uL=(t,e)=>{if(typeof t=="function")return t;if(typeof t=="string"){let r=AE[t];return r?r(e):null}return null},fd=t=>{let e=t.config,r=Array.isArray(e.transformers)?e.transformers.slice():[],n=r.findIndex(s=>s==="redact");n>=0&&r.splice(n,1);let o=[];e.redact!==!1&&o.push(AE.redact(t));for(let s of r){let i=uL(s,t);i&&o.push(i)}return s=>{let i=s;for(let a of o){if(i==null)return null;let c=a(i);if(c==null)return null;if(Array.isArray(c)){let l=o.slice(o.indexOf(a)+1),f=[];for(let u of c){let d=u,g=!1;for(let p of l)if(d=p(d),d==null){g=!0;break}!g&&d!=null&&f.push(d)}return f}i=c}return i}};D();D();var ud=typeof E<"u"&&typeof E.document<"u",dL=5e3,pL=50,hL=3,gL=1500,mL=1e3,D_=t=>t?t.level==="error"||t.type==="error"?"bug":t.type==="network"?"network":t.type==="console"?t.level==="error"||t.level==="warn"?"bug":"log":t.level==="warn"?"bug":t.level==="info"?"log":"verbose":"verbose",yL=t=>{try{return JSON.stringify(t)}catch{return null}},bL=()=>{try{return Intl.DateTimeFormat().resolvedOptions().timeZone||null}catch{return null}},_L=t=>{if(!t)return null;let e=String(t),r;return(r=e.match(/Edg\/([\d.]+)/))?{name:"Edge",version:r[1]}:(r=e.match(/OPR\/([\d.]+)/))?{name:"Opera",version:r[1]}:(r=e.match(/Firefox\/([\d.]+)/))?{name:"Firefox",version:r[1]}:/Chrome\/([\d.]+)/.test(e)&&/Safari\//.test(e)?(r=e.match(/Chrome\/([\d.]+)/),{name:"Chrome",version:r[1]}):(r=e.match(/Version\/([\d.]+).*Safari/))?{name:"Safari",version:r[1]}:{name:null,version:null}},wL=()=>{if(!ud)return null;try{let t=E.document?.documentElement?.getAttribute("data-theme")||null,e=typeof E.matchMedia=="function"?E.matchMedia("(prefers-color-scheme: dark)").matches:null;return{active:t||(e?"dark":e===!1?"light":null),forced:t||null,prefers:e==null?null:e?"dark":"light"}}catch{return null}},xL=()=>{if(!ud)return null;let t=E.location,e=typeof navigator<"u"?navigator:null,r=typeof screen<"u"?screen:null;return{url:t?.href||null,path:t?.pathname||null,referrer:E.document?.referrer||null,title:E.document?.title||null,ua:e?.userAgent||null,browser:_L(e?.userAgent),language:e?.language||null,languages:e?.languages||null,timezone:bL(),viewport:E.innerWidth?{w:E.innerWidth,h:E.innerHeight,dpr:E.devicePixelRatio||1}:null,screen:r?{w:r.width||null,h:r.height||null,availW:r.availWidth||null,availH:r.availHeight||null,colorDepth:r.colorDepth||null,orientation:r.orientation?.type||null}:null,theme:wL()}},dd=(t={})=>{let e=t.url,r=typeof t.transport=="function"?t.transport:null,n=typeof t.syncTransport=="function"?t.syncTransport:null;if(!e&&!r)return()=>{};let o=t.apiKey||null,s=t.appKey||t.appId||null,i=t.tenantKey||t.tenant||null,a=t.release||null,c=t.env||null,l=t.sdk||null,f=typeof t.getAuth=="function"?t.getAuth:null,u=typeof t.getContext=="function"?t.getContext:null,d=typeof t.classify=="function"?t.classify:D_,g=typeof t.beforeSend=="function"?t.beforeSend:null,p=t.debug===!0,h=typeof t.getDebug=="function"?t.getDebug:null,m=t.batchMs!=null?t.batchMs:dL,_=t.maxBatch||pL,x=t.maxRetries!=null?t.maxRetries:hL,y=t.backoffMs||gL,b=t.queueLimit||mL,w=t.sampleRate!=null?t.sampleRate:1,S=()=>typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`,C=t.sessionId||S(),O=[],L=[],T=null,M=null,U=()=>{T||!O.length||(T=setTimeout(F,m))},rt=G=>{if(M)return;let j=y*Math.pow(2,Math.max(0,G-1));M=setTimeout(()=>{if(M=null,!L.length)return;let nt=L.shift();mt(nt.envelope,nt.attempt)},j)},Rt=(G,j=!1)=>{let nt=u?P_(u):null,N={id:C,sentAt:Date.now()};j&&(N.endedAt=Date.now());let J={v:1,session:N,app:{key:s,release:a,env:c},tenant:i,sdk:l,page:xL(),user:nt?.user||null,traits:nt?.traits||null,tags:nt?.tags||null,events:G};if((h?P_(h)===!0:p)&&(J.app.debug=!0),g)try{return g(J)||null}catch{return J}return J},mt=async(G,j=1)=>{if(G)try{let nt=!0;if(r){let N=await r(G);nt=N!==!1&&N?.ok!==!1}else nt=await SL(e,G,{apiKey:o,getAuth:f});!nt&&j<x&&(L.push({envelope:G,attempt:j+1}),rt(j+1))}catch{j<x&&(L.push({envelope:G,attempt:j+1}),rt(j+1))}},F=(G=!1,j=!1)=>{if(T&&(clearTimeout(T),T=null),!O.length&&!j)return;let nt=O;O=[];let N=Rt(nt,j);if(N){if(G&&ud){if(typeof n=="function"&&P_(()=>n(N)))return;if(navigator.sendBeacon&&e){let J=yL(N);if(J)try{navigator.sendBeacon(e,new E.Blob([J],{type:"application/json"}));return}catch{}}}mt(N)}},W=!1,yt=()=>{W||(W=!0,F(!0,!0))};ud&&(E.addEventListener("pagehide",yt,{passive:!0}),E.addEventListener("beforeunload",yt,{passive:!0}),E.addEventListener("visibilitychange",()=>{E.document.visibilityState==="hidden"&&F(!0)},{passive:!0}));let St=G=>{if(!G||w<1&&Math.random()>w)return;W&&(W=!1);let j={...G,log_type:d(G)};O.push(j),O.length>b&&(O=O.slice(-b)),O.length>=_?F():U()},Pt=G=>(F(!1,!0),C=G||S(),W=!1,St.sessionId=C,C);return St.flush=()=>F(!1),St.endSession=yt,St.startNewSession=Pt,St.sessionId=C,St},P_=t=>{try{return t()}catch{return null}},SL=async(t,e,{apiKey:r,getAuth:n})=>{let o={"Content-Type":"application/json","X-Analyze-Beacon":"1"};if(r&&(o["X-Analyze-Key"]=r),n)try{let s=await n();s&&(o.Authorization=`Bearer ${s}`)}catch{}try{return(await fetch(t,{method:"POST",headers:o,body:JSON.stringify(e),keepalive:!0,credentials:"omit",mode:"cors"})).ok}catch{return!1}};var kL={error:"\x1B[31m",warn:"\x1B[33m",info:"\x1B[36m",debug:"\x1B[90m",trace:"\x1B[90m"},vL="\x1B[0m",pd=typeof E<"u"&&typeof E.document<"u",L_=(t={})=>{let e=t.minLevel||null,r=console.error.bind(console),n=console.warn.bind(console),o=console.log.bind(console);return s=>{if(!s)return;let i=s.level==="error"?r:s.level==="warn"?n:o,a=`[analyze:${s.type}]`;if(pd)i(a,s);else{let c=kL[s.level]||"";i(`${c}${a}${vL}`,s)}}},I_=(t,e={})=>{let r=e.max||t.config.cache?.max||500,n=new Array(r),o=0,s=0,i=a=>{n[o]=a,o=(o+1)%r,s<r&&s++};return t.__memory={push:i,snapshot:()=>{let a=new Array(s),c=(o-s+r)%r;for(let l=0;l<s;l++)a[l]=n[(c+l)%r];return a},query:(a={})=>{let c=t.__memory.snapshot(),l=a.sinceMs?Date.now()-a.sinceMs:0;return c.filter(f=>!(!f||a.level&&f.level!==a.level||a.type&&f.type!==a.type||l&&f.ts<l))},clear:()=>{o=0,s=0}},i},$_=(t={})=>{let e=t.url,r=t.batchMs!=null?t.batchMs:5e3,n=t.maxBatch||50;if(!e)return()=>{};let o=[],s=null,i=()=>{if(s&&(clearTimeout(s),s=null),!o.length)return;let c=JSON.stringify({events:o});o=[];let l=pd?new E.Blob([c],{type:"application/json"}):c;if(pd&&navigator.sendBeacon)try{navigator.sendBeacon(e,l);return}catch{}typeof fetch<"u"&&fetch(e,{method:"POST",headers:{"Content-Type":"application/json","X-Analyze-Beacon":"1"},body:c,keepalive:!0}).catch(()=>{})};pd&&(E.addEventListener("pagehide",i,{passive:!0}),E.addEventListener("beforeunload",i,{passive:!0}));let a=c=>{c&&(o.push(c),o.length>=n?i():s||(s=setTimeout(i,r)))};return a.flush=i,a},TE={console:L_,memory:I_,beacon:$_,remote:dd},OE=(t,e)=>e.getDebug!=null||e.debug!=null?e:{...e,getDebug:()=>t.config.debug===!0},hd=t=>{let e=Array.isArray(t.config.sinks)?t.config.sinks:["console"],r=[];for(let n of e)if(typeof n=="function")r.push(n);else if(typeof n=="string"){let o=TE[n];if(!o)continue;r.push(n==="memory"?o(t,{}):o(n==="remote"?OE(t,{}):{}))}else if(n&&typeof n=="object"&&n.type){let o=TE[n.type];if(!o)continue;r.push(n.type==="memory"?o(t,n):o(n.type==="remote"?OE(t,n):n))}return r};D();var CL=typeof E<"u"&&typeof E.document<"u",EL=new Set(["password","hidden"]),RE=(t,e)=>{let r=0,n=null,o=null;return(...s)=>{let i=Date.now();i-r>=e?(r=i,t(...s)):(o=s,n||(n=setTimeout(()=>{r=Date.now(),n=null,o&&(t(...o),o=null)},e-(i-r))))}},M_="__analyzeKeyPath",js=t=>{let e=t.target;if(!e)return{selector:null,key:null,path:null};if(e[M_])return e[M_];let r=[],n=e,o=0,s=null;for(;n&&o<64;){if(n.getAttribute){let a=n.getAttribute("data-key");a&&(s==null&&(s=a),r.unshift(a))}n=n.parentNode,o++}let i;if(r.length)i={selector:null,key:s,path:r.join(" > "),tag:e.tagName?.toLowerCase()||null};else{let a=(e.tagName||"unknown").toLowerCase(),c=e.id?`#${e.id}`:"",l=e.className&&typeof e.className=="string"?"."+e.className.trim().split(/\s+/).slice(0,2).join("."):"";i={selector:`${a}${c}${l}`,key:null,path:null}}try{e[M_]=i}catch{}return i},AL=(t,e)=>{if(e==="mask")return"***";if(e!=="redact"){if(e==="hash"){let r=0,n=String(t||"");for(let o=0;o<n.length;o++)r=(r<<5)-r+n.charCodeAt(o)|0;return`#${(r>>>0).toString(36)}`}return"***"}},TL=t=>!!(!t||t.tagName==="INPUT"&&EL.has(t.type)||cd.test(t.name||"")||cd.test(t.id||"")||t.dataset?.analyze==="skip"),gd=t=>{if(!CL)return;let e=t.config.capture,r=t.config.throttle,n=t.__teardown,o=(s,i,a,c)=>{s.addEventListener(i,a,c),n.push(()=>s.removeEventListener(i,a,c))};if(e.errors&&(o(E,"error",s=>{t.emit(tt("error","error",{hook:"window.onerror",message:s.message||null,error:s.error||null,source:s.filename||null,line:s.lineno||null,col:s.colno||null}))}),o(E,"unhandledrejection",s=>{let i=s.reason,a=i instanceof Error?i:null;t.emit(tt("error","error",{hook:"unhandledrejection",message:a?.message||(typeof i=="string"?i:"Unhandled promise rejection"),error:a}))})),e.pointer){o(E,"click",i=>{t.emit(tt("pointer","info",{hook:"click",target:js(i),button:i.button,x:i.clientX,y:i.clientY,modifiers:PE(i)}))},{passive:!0,capture:!0}),o(E,"dblclick",i=>{t.emit(tt("pointer","info",{hook:"dblclick",target:js(i),x:i.clientX,y:i.clientY}))},{passive:!0,capture:!0}),o(E,"contextmenu",i=>{t.emit(tt("pointer","info",{hook:"contextmenu",target:js(i),x:i.clientX,y:i.clientY}))},{passive:!0,capture:!0});let s=RE(i=>{t.emit(tt("pointer","trace",{hook:"pointermove",x:i.clientX,y:i.clientY}))},r.pointermove);o(E,"pointermove",s,{passive:!0})}if(e.keyboard&&o(E,"keydown",s=>{t.emit(tt("keyboard","info",{hook:"keydown",code:s.code,key:s.key&&s.key.length===1?"\xB7":s.key,modifiers:PE(s),target:js(s)}))},{passive:!0,capture:!0}),e.forms){let s=i=>{let a=i.target;if(!a||!a.tagName||!["INPUT","TEXTAREA","SELECT"].includes(a.tagName))return;let l=TL(a),f=a.dataset?.analyze==="track",u=null;f&&!l?u=a.value:t.config.maskFormValues!==!1&&(u=AL(a.value,t.config.maskStrategy)),t.emit(tt("forms","info",{hook:i.type,target:js(i),field:{name:a.name||null,type:a.type||a.tagName.toLowerCase()},value:u}))};o(E,"input",s,{passive:!0,capture:!0}),o(E,"change",s,{passive:!0,capture:!0}),o(E,"submit",i=>{t.emit(tt("forms","info",{hook:"submit",target:js(i)}))},{passive:!0,capture:!0})}if(e.scroll){let s=RE(()=>{t.emit(tt("scroll","trace",{hook:"scroll",x:E.scrollX,y:E.scrollY}))},r.scroll);o(E,"scroll",s,{passive:!0,capture:!0})}if(e.viewport){let s=Ai(()=>{t.emit(tt("viewport","info",{hook:"resize",w:E.innerWidth,h:E.innerHeight,dpr:E.devicePixelRatio||1}))},r.resize);o(E,"resize",s,{passive:!0}),o(E,"orientationchange",()=>{t.emit(tt("viewport","info",{hook:"orientationchange",orientation:typeof screen<"u"&&screen.orientation?screen.orientation.type:null}))},{passive:!0}),o(E.document,"visibilitychange",()=>{t.emit(tt("viewport","info",{hook:"visibilitychange",hidden:E.document.hidden}))},{passive:!0}),t.emit(tt("viewport","info",{hook:"initial",w:E.innerWidth,h:E.innerHeight,dpr:E.devicePixelRatio||1}))}if(e.console)for(let s of["log","warn","error","debug"]){let i=console[s];console[s]=function(...a){try{t.emit(tt("console",s==="error"?"error":s==="warn"?"warn":"debug",{hook:`console.${s}`,args:a.map(DE)}))}catch{}return i.apply(console,a)},n.push(()=>{console[s]=i})}if(e.performance&&typeof PerformanceObserver<"u")try{let s=new PerformanceObserver(a=>{for(let c of a.getEntries())t.emit(tt("performance","info",{hook:c.entryType,name:c.name,startTime:c.startTime,duration:c.duration,value:c.value!=null?c.value:null}))}),i=["largest-contentful-paint","layout-shift","longtask","paint","first-input","event"];for(let a of i)try{s.observe({type:a,buffered:!0})}catch{}n.push(()=>s.disconnect())}catch{}},PE=t=>({shift:!!t.shiftKey,ctrl:!!t.ctrlKey,alt:!!t.altKey,meta:!!t.metaKey}),OL=t=>{let e={name:t.name||"Error",message:typeof t.message=="string"?t.message:String(t),stack:typeof t.stack=="string"?t.stack:null};return t.cause!==void 0&&(e.cause=DE(t.cause)),e},DE=t=>{if(t==null)return t;if(t instanceof Error)return OL(t);if(typeof t=="object")try{return JSON.parse(JSON.stringify(t))}catch{return String(t)}return t};D();var RL=typeof E<"u"&&typeof E.document<"u",LE=(t,e)=>{let r=t?.analyze;if(!r||!r.shouldCapture("network"))return;let n=e.phase==="error"?"error":"info";r.emit(tt("network",n,{hook:`fetch.${e.phase}`,source:"symbo-fetch",...e}))},Uc=t=>{if(RL&&t.config.capture.network&&!t.__networkListeners){if(t.__networkListeners=!0,t.__teardown.push(()=>{t.__networkListeners=!1}),typeof E.fetch=="function"){let e=E.fetch.bind(E),r=function(n,o){if(o?.headers?.["X-Analyze-Beacon"]||!t.shouldCapture("network"))return e(n,o);let s=typeof n=="string"?n:n&&n.url||"",i=(o?.method||typeof n=="object"&&n?.method||"GET").toUpperCase(),a=typeof performance<"u"?performance.now():Date.now();return t.emit(tt("network","info",{hook:"fetch.start",source:"window.fetch",url:s,method:i})),e(n,o).then(c=>{let l=(typeof performance<"u"?performance.now():Date.now())-a;return t.emit(tt("network",c.ok?"info":"warn",{hook:"fetch.success",source:"window.fetch",url:s,method:i,status:c.status,ok:c.ok,durationMs:l})),c}).catch(c=>{let l=(typeof performance<"u"?performance.now():Date.now())-a;throw t.emit(tt("network","error",{hook:"fetch.error",source:"window.fetch",url:s,method:i,error:c,durationMs:l})),c})};E.fetch=r,t.__teardown.push(()=>{E.fetch=e})}if(typeof E.XMLHttpRequest=="function"){let e=E.XMLHttpRequest,r=e.prototype.open,n=e.prototype.send;e.prototype.open=function(o,s){return this.__analyze={method:String(o).toUpperCase(),url:String(s)},r.apply(this,arguments)},e.prototype.send=function(o){let s=this.__analyze;if(!s||!t.shouldCapture("network"))return n.apply(this,arguments);let i=typeof performance<"u"?performance.now():Date.now();t.emit(tt("network","info",{hook:"xhr.start",source:"xhr",url:s.url,method:s.method}));let a=()=>{let l=(typeof performance<"u"?performance.now():Date.now())-i,f=this.status>=200&&this.status<400;t.emit(tt("network",f?"info":"warn",{hook:"xhr.success",source:"xhr",url:s.url,method:s.method,status:this.status,ok:f,durationMs:l}))},c=()=>{let l=(typeof performance<"u"?performance.now():Date.now())-i;t.emit(tt("network","error",{hook:"xhr.error",source:"xhr",url:s.url,method:s.method,status:this.status,durationMs:l}))};return this.addEventListener("loadend",a),this.addEventListener("error",c),n.apply(this,arguments)},t.__teardown.push(()=>{e.prototype.open=r,e.prototype.send=n})}}};var PL={errors:!0,warnings:!0,pointer:!1,keyboard:!1,forms:!1,scroll:!1,viewport:!1,network:!1,performance:!1,navigation:!1,console:!1,lifecycle:!1,state:!1,updates:!1,replay:!1,telemetry:!1},DL={errors:!0,warnings:!0,pointer:!0,keyboard:!0,forms:!0,scroll:!0,viewport:!0,navigation:!0,state:!0},LL={errors:!0,warnings:!0,pointer:!0,navigation:!0,performance:!0,viewport:!0},IL={errors:!0,warnings:!0,console:!0,network:!1,navigation:!0,performance:!0,viewport:!0,lifecycle:!1,state:!1,updates:!1},$L=t=>{let e={...PL,...t};return e.replay&&Object.assign(e,DL),e.telemetry&&Object.assign(e,LL),e.remote&&Object.assign(e,IL),Object.assign(e,t),e},ML=64,FL=()=>{if(typeof E>"u"||!E.location)return null;try{let e=new URLSearchParams(E.location.search).get("analyze");return e||null}catch{return null}},md=(t={})=>{let e=t===!0?{}:{...t};e.capture=$L(e.capture||{});let r=FL();(r==="debug"||e.debug)&&(e.level="debug",e.debug=!0,e.capture={...e.capture,lifecycle:!0,state:!0,updates:!0,console:!0,network:!0}),r==="off"&&(e.enabled=!1),e.level=Vc(e.level||"warn"),e.cache={max:500,dedupeWindowMs:1e3,...e.cache||{}},e.throttle={pointermove:80,mousemove:80,scroll:100,resize:200,...e.throttle||{}},e.maskFormValues==null&&(e.maskFormValues=!0),e.maskStrategy||(e.maskStrategy="mask"),Array.isArray(e.sinks)||(e.sinks=["console","memory"]),Array.isArray(e.transformers)||(e.transformers=["enrich","summarize"]);let n={config:e,context:null,__ready:!1,__paused:!1,__preBuffer:[],__teardown:[],__pipeline:null,__sinks:null,__memory:null,__initialSnapshot:null},o=()=>{n.__pipeline||(n.__pipeline=fd(n),n.__sinks=hd(n))};return n.shouldCapture=s=>n.config.enabled===!1?!1:!!n.config.capture[s],n.emit=s=>{if(s&&n.config.enabled!==!1&&!n.__paused&&ad(s.level,n.config.level)){if(!n.__ready){if(s.level!=="error"&&!n.config.captureDuringHydration)return;n.__preBuffer.length<ML&&n.__preBuffer.push(s);return}o(),IE(n,s)}},n.activate=s=>{if(n.context==null&&(n.context=s||null),n.__ready)return;n.__ready=!0;let i=n.__preBuffer;if(n.__preBuffer=[],i.length){o();for(let a of i)IE(n,a)}try{gd(n)}catch(a){console.error("[analyze] browser attach error:",a)}try{Uc(n)}catch(a){console.error("[analyze] network attach error:",a)}for(let a of n.__onActivate||[])try{a(n)}catch(c){console.error("[analyze] onActivate error:",c)}},n.pause=()=>{n.__paused=!0},n.resume=()=>{n.__paused=!1},n.setLevel=s=>{n.config.level=Vc(s)},n.setCapture=(s,i)=>{if(n.config.capture[s]=!!i,s==="network"&&i&&n.__ready)try{Uc(n)}catch(a){console.error("[analyze] network attach error:",a)}},n.query=s=>n.__memory?n.__memory.query(s):[],n.snapshot=()=>n.__memory?n.__memory.snapshot():[],n.emitNetwork=s=>{if(!n.shouldCapture("network"))return;let i=s?.phase,a=i==="error"?"error":i==="success"&&s.ok===!1?"warn":"info";n.emit({id:`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,6)}`,ts:Date.now(),type:"network",level:a,hook:`fetch.${i||"unknown"}`,...s})},n.flush=()=>{if(n.__sinks)for(let s of n.__sinks)typeof s.flush=="function"&&s.flush()},n.startNewSession=s=>{let i=s||(typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`),a=Array.isArray(n.config.sinks)?n.config.sinks:[];for(let c of a)c&&typeof c=="object"&&c.type==="remote"&&(c.sessionId=i);if(n.__sinks)for(let c of n.__sinks)typeof c.startNewSession=="function"&&c.startNewSession(i);return i},n.replay=()=>({initialSnapshot:n.__initialSnapshot,events:n.snapshot()}),n.destroy=()=>{for(let s of n.__teardown)try{s()}catch{}n.__teardown=[],n.__ready=!1,n.__paused=!0},n.__onActivate=[],n.onActivate=s=>{n.__onActivate.push(s)},n},IE=(t,e)=>{let r=t.__pipeline(e);if(r==null)return;let n=Array.isArray(r)?r:[r];for(let o of n){if(typeof t.config.onEvent=="function")try{t.config.onEvent(o)}catch{}for(let s of t.__sinks)try{s(o)}catch(i){console.error("[analyze] sink error:",i)}}};var B_={};$(B_,{Inspect:()=>yd,inspectPlugin:()=>j_});D();function $E(t){return k(t)?t:P(t)?t.find(e=>k(e)):""}function N_(t){if(!t)return;let e=t.__ref.__componentKey,r=t.extends&&$E(t.extends),n=t.parent&&t.parent.childExtends&&$E(t.parent.childExtends);return(e||r||n||"").split("_")[0].split(".")[0].split("+")[0]}function bd(t){if(!t||!t.__ref)return;let{components:e,pages:r,editor:n}=t.context,o=N_(t);return n&&n.onInitInspect&&!n.onInitInspect(o,t,t.state)?bd(t.parent):o&&(e[o]||r[o])?t:bd(t.parent)}var NL=(t,e,r)=>{let n=r.window||window;n.onkeydown=o=>{o.altKey&&o.shiftKey&&t.state.update({debugging:!0,preventSelect:!0},{preventUpdate:!0,preventContentUpdate:!0,preventRecursive:!0})},n.onkeyup=o=>{t.state.preventSelect&&(!o.altKey||!o.shiftKey)&&(t.state.replace({debugging:!1,preventSelect:!1},{preventUpdate:!0,preventContentUpdate:!0,preventRecursive:!0}),t.Inspector.state.update({area:!1}))}},yd={".preventSelect":{userSelect:"none"},"!preventSelect":{userSelect:"auto"},onInspect:NL,onMousemove:(t,e,r)=>{let n=t.target.ref,o=bd(n),s=e.Inspector.state;if(!o||!r.debugging||!o.__ref)return s.update({area:!1});let i=N_(o),a=l=>{s.update({area:l,focusKey:i})},c=()=>{if(t.altKey&&t.shiftKey){let{x:l,y:f,width:u,height:d}=o.node.getBoundingClientRect(),g={x:l,y:f,width:u,height:d};if(!s.area)return a(g);s.area.x!==g.x&&a(g)}else s.area&&s.update({area:!1})};window.requestAnimationFrame(()=>{c(),window.requestAnimationFrame(c)})},onMousedown:(t,e,r)=>{if(!r.debugging)return;let n=t.target.ref,o=bd(n);if(!o)return;let s=N_(o);if(!s)return;let i=n.context.editor;if(i&&i.onInspect)return i.onInspect(s,n,n.state,{allowRouterWhileInspect:!0});let a=JSON.stringify({componentKey:`${s}`});return n.context.socket?.emit&&n.context.socket.emit("route",a),t.preventDefault(),t.stopPropagation(),!1},Inspector:{state:{},transition:"all, defaultBezier, X",position:"fixed",hide:(t,e)=>!(e.area&&e.parent.debugging),style:{boxShadow:"0 0 10px #3686F733, 0 0 0 3px #3686F766, 0 0 100vmax 100vmax #000A",zIndex:"9999999",borderRadius:"10px",pointerEvents:"none"},Span:{position:"absolute",margin:"A2 0",fontSize:"Z",color:"text",zIndex:"99999999",transition:"all, defaultBezier, X",textDecoration:"underline",fontWeight:"500",top:"100%",style:{boxShadow:"0 25px 10px 35px black",textShadow:"0 0 10px black"},text:"{{ focusKey }}"},onInit:({context:t})=>{let{components:e}=t;if(v(e)){let{Content:r,...n}=e;for(let o in n)Os[o]||(n[o].__ref||(n[o].__ref={}),n[o].__ref.__componentKey||(n[o].__ref.__componentKey=o))}},onBeforeUpdate:(t,e,r)=>{let{area:n}=r,o=r.area&&r.parent.debugging,s;if(!o)s="display: none !important";else if(n){let{x:i,y:a,width:c,height:l}=n;s=`
84
+ )`};var yD={primary:{"@dark":{color:"white",background:"blue",".color-only":{color:"blue"},".inactive":{background:"gray+16"},".gradient":{color:"white",background:"gradient-blue"}},"@light":{color:"white",background:"gradient-blue",".color-only":{color:"blue"},".gradient":{color:"white",background:"gradient-colorful"}}},secondary:{"@dark":{color:"white",background:"green",".color-only":{color:"green"}},"@light":{color:"white",background:"green",".color-only":{color:"green"}},".child":"--primary"},tertiary:{"@dark":{color:"white",background:"gray.92+8"},"@light":{background:"gray.1"}},quaternary:{"@light":{color:"white",background:"gradient-light"},"@dark":{color:"white",background:"gradient-dark-active"}},quinary:{"@dark":{color:"gray=90",background:"gradient-light",":hover":{color:"gray=95",background:"gradient-light-active"},":focus":{color:"gray=120",background:"gradient-light-active"},":active":{color:"gray=120",background:"gradient-light-active"},".active":{color:"gray=120",background:"gradient-light-active"}},"@light":{color:"gray3",background:"gradient-dark",":hover":{color:"gray1",background:"gradient-dark-active"},":active":{color:"gray1",background:"gradient-dark-active"},".active":{color:"gray1",background:"gradient-dark-active"}}}},bD={alert:{"@dark":{color:"white",background:"red"}},warning:{"@dark":{color:"black",background:"yellow"}},success:{"@dark":{color:"black",background:"green"}}},_D={field:{"@light":{color:"black",background:"gray.975+144",borderColor:"gray.975+144","::placeholder":{color:"gray-68"}},"@dark":{color:"white",background:"gray.975-52",borderColor:"gray.975-52","::placeholder":{color:"gray+68"}}},label:{"@dark":{color:"white",background:"gray.92+8"},"@light":{background:"gray.1"},".light":{color:"white",background:"gray3"},".dark":{color:"white",background:"black.35"}},card:{"@light":{background:"gray.975+150"},"@dark":{color:"white",background:"gray.975-56"},".child":{color:"white",background:"gray3"},".secondary":{color:"white",background:"gradient-blue-dark",".child":{color:"white",background:"black.35"}}},dialog:{"@dark":{color:"white",background:"gray.92",".helper":{color:"white",background:"black"}},"@light":{color:"currentColor",background:"gray.1"}}},Qk={document:{"@light":{color:"black",background:"white"},"@dark":{color:"white",background:"black"}},...yD,...bD,..._D,backdrop:{"@light":{background:"scrim",backdropFilter:"blur(8px)"},"@dark":{background:"scrim",backdropFilter:"blur(8px)"}},backdropSoft:{"@light":{background:"scrimSoft",backdropFilter:"blur(4px)"},"@dark":{background:"scrimSoft",backdropFilter:"blur(4px)"}},none:{color:"none",background:"none"},transparent:{color:"currentColor",background:"transparent"}};var tv={base:16,ratio:1.25,subSequence:!0,useCapsize:!0,templates:{}};var ev={ratio:1.618,subSequence:!0};var rv={SourceSans:[{url:""}]},nv={system:{isDefault:!0,isSystemFallback:!0,value:["system-ui","-apple-system","BlinkMacSystemFont",'"Segoe UI"',"Roboto",'"Helvetica Neue"',"Arial",'"Noto Sans"','"Liberation Sans"'],type:"sans-serif"}};var ov={symbols:'<svg xmlns="http://www.w3.org/2000/svg" width="41" height="42" viewBox="0 0 41 42"><path fill="currentColor" fill-rule="evenodd" d="M26.6448969,0.699064106 C31.4862479,1.83000067 35.6718819,4.48073656 38.3104478,8.91022511 C40.5212645,12.5974948 41.4936378,17.0951724 40.5085112,21.3679841 C39.7174644,25.0315254 37.8558379,27.853625 34.8002871,29.8369535 C31.9792925,31.7073227 27.90737,32.069064 24.6776501,31.3213124 C23.2887047,30.9944607 20.6411869,29.9775216 19.044333,28.0178349 C17.5928447,26.2365433 17.1250067,23.5192397 17.0461096,22.8419583 C16.9044422,21.6258334 17.1065683,20.249997 17.3800113,19.0276209 C17.9614095,16.4655592 18.9984397,14.7924534 21.1401118,13.3818866 C22.95018,12.1750388 24.6834696,11.8738651 26.7601335,12.3496124 C28.1855093,12.6880929 29.4520072,13.526716 30.3514025,14.7276098 C30.6271426,15.093878 30.8260324,15.4389318 31.059655,15.8362933 L30.9598079,15.7715366 C29.6377659,14.9422902 28.1654404,14.6590001 26.6448969,15.0752526 C25.2996601,15.4486698 24.1453463,16.3687006 23.4390969,17.6304467 C22.6973258,18.9448239 22.4839364,20.5087166 22.8465467,21.9733145 C23.2152637,23.4394215 24.1276197,24.6832715 25.381967,25.429977 C26.7647836,26.2608222 28.5893081,26.47537 30.1320438,26.0161118 C32.0344739,25.4497656 33.5958796,24.1165457 34.5824098,22.3233381 C35.8078311,20.0959926 36.0316242,17.5753145 35.4197363,15.1376991 C34.8712232,12.9726344 33.491011,11.1258939 31.7578503,9.86101942 C28.3978494,7.40873928 23.8145474,6.88014849 19.8961329,8.1555193 C16.9596954,9.11146975 14.399202,11.0657028 12.6221782,13.707146 C10.5375814,16.8894059 9.73736372,20.794518 10.3986926,24.5579956 C10.9302311,27.7327705 12.5716868,31.0242929 14.8485647,33.1339502 C15.5517576,33.7855358 16.0056239,34.2996296 16.8186608,34.9238068 C16.1252729,35.6670587 15.729719,36.1210912 15.0276006,36.8553491 L10.5425168,41.6144377 C8.59431563,40.2572487 6.84060794,38.6181461 5.33246714,36.7448351 C1.65619854,32.1632109 -0.0655234106,26.1858125 0.562658817,20.1851649 C1.1000136,14.4158268 3.81414269,9.08050481 8.0996615,5.36924966 C12.3107417,1.69300072 17.6911238,0.0107792851 23.1108097,0.299129816 C25.006381,0.458182488 26.18441,0.591493918 26.6448969,0.699064106 Z"/></svg>',logo:'<svg xmlns="http://www.w3.org/2000/svg" width="41" height="42" viewBox="0 0 41 42"><path fill="currentColor" fill-rule="evenodd" d="M26.6448969,0.699064106 C31.4862479,1.83000067 35.6718819,4.48073656 38.3104478,8.91022511 C40.5212645,12.5974948 41.4936378,17.0951724 40.5085112,21.3679841 C39.7174644,25.0315254 37.8558379,27.853625 34.8002871,29.8369535 C31.9792925,31.7073227 27.90737,32.069064 24.6776501,31.3213124 C23.2887047,30.9944607 20.6411869,29.9775216 19.044333,28.0178349 C17.5928447,26.2365433 17.1250067,23.5192397 17.0461096,22.8419583 C16.9044422,21.6258334 17.1065683,20.249997 17.3800113,19.0276209 C17.9614095,16.4655592 18.9984397,14.7924534 21.1401118,13.3818866 C22.95018,12.1750388 24.6834696,11.8738651 26.7601335,12.3496124 C28.1855093,12.6880929 29.4520072,13.526716 30.3514025,14.7276098 C30.6271426,15.093878 30.8260324,15.4389318 31.059655,15.8362933 L30.9598079,15.7715366 C29.6377659,14.9422902 28.1654404,14.6590001 26.6448969,15.0752526 C25.2996601,15.4486698 24.1453463,16.3687006 23.4390969,17.6304467 C22.6973258,18.9448239 22.4839364,20.5087166 22.8465467,21.9733145 C23.2152637,23.4394215 24.1276197,24.6832715 25.381967,25.429977 C26.7647836,26.2608222 28.5893081,26.47537 30.1320438,26.0161118 C32.0344739,25.4497656 33.5958796,24.1165457 34.5824098,22.3233381 C35.8078311,20.0959926 36.0316242,17.5753145 35.4197363,15.1376991 C34.8712232,12.9726344 33.491011,11.1258939 31.7578503,9.86101942 C28.3978494,7.40873928 23.8145474,6.88014849 19.8961329,8.1555193 C16.9596954,9.11146975 14.399202,11.0657028 12.6221782,13.707146 C10.5375814,16.8894059 9.73736372,20.794518 10.3986926,24.5579956 C10.9302311,27.7327705 12.5716868,31.0242929 14.8485647,33.1339502 C15.5517576,33.7855358 16.0056239,34.2996296 16.8186608,34.9238068 C16.1252729,35.6670587 15.729719,36.1210912 15.0276006,36.8553491 L10.5425168,41.6144377 C8.59431563,40.2572487 6.84060794,38.6181461 5.33246714,36.7448351 C1.65619854,32.1632109 -0.0655234106,26.1858125 0.562658817,20.1851649 C1.1000136,14.4158268 3.81414269,9.08050481 8.0996615,5.36924966 C12.3107417,1.69300072 17.6911238,0.0107792851 23.1108097,0.299129816 C25.006381,0.458182488 26.18441,0.591493918 26.6448969,0.699064106 Z"/></svg>',arrowDownCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-circle"><circle cx="12" cy="12" r="10"/><path d="M8 12l4 4 4-4M12 8v8"/></svg>',arrowDownLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-left"><path d="M17 7L7 17M17 17H7V7"/></svg>',arrowDownRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down-right"><path d="M7 7l10 10M17 7v10H7"/></svg>',arrowDown:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down"><path d="M12 5v14M19 12l-7 7-7-7"/></svg>',arrowLeftCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-left-circle"><circle cx="12" cy="12" r="10"/><path d="M12 8l-4 4 4 4M16 12H8"/></svg>',arrowLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-left"><path d="M19 12H5M12 19l-7-7 7-7"/></svg>',arrowRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right"><path d="M5 12h14M12 5l7 7-7 7"/></svg>',arrowRightCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right-circle"><circle cx="12" cy="12" r="10"/><path d="M12 16l4-4-4-4M8 12h8"/></svg>',arrowUpCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-circle"><circle cx="12" cy="12" r="10"/><path d="M16 12l-4-4-4 4M12 16V8"/></svg>',arrowUpLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-left"><path d="M17 17L7 7M7 17V7h10"/></svg>',arrowUpRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up-right"><path d="M7 17L17 7M7 7h10v10"/></svg>',arrowUp:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-up"><path d="M12 19V5M5 12l7-7 7 7"/></svg>',checkCircle:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-check-circle"><path d="M22 11.08V12a10 10 0 11-5.93-9.14"/><path d="M22 4L12 14.01l-3-3"/></svg>',check:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-check"><path d="M20 6L9 17l-5-5"/></svg>',chevronDown:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-down"><path d="M6 9l6 6 6-6"/></svg>',chevronLeft:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-left"><path d="M15 18l-6-6 6-6"/></svg>',chevronRight:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><path d="M9 18l6-6-6-6"/></svg>',chevronUp:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-up"><path d="M18 15l-6-6-6 6"/></svg>',copy:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-copy"><rect x="9" y="9" width="13" height="13" rx="2" ry="2"/><path d="M5 15H4a2 2 0 01-2-2V4a2 2 0 012-2h9a2 2 0 012 2v1"/></svg>',eyeOff:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-eye-off"><path d="M17.94 17.94A10.07 10.07 0 0112 20c-7 0-11-8-11-8a18.45 18.45 0 015.06-5.94M9.9 4.24A9.12 9.12 0 0112 4c7 0 11 8 11 8a18.5 18.5 0 01-2.16 3.19m-6.72-1.07a3 3 0 11-4.24-4.24M1 1l22 22"/></svg>',eye:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-eye"><path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"/><circle cx="12" cy="12" r="3"/></svg>',info:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-info"><circle cx="12" cy="12" r="10"/><path d="M12 16v-4M12 8h.01"/></svg>',lock:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-lock"><rect x="3" y="11" width="18" height="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0110 0v4"/></svg>',minus:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-minus"><path d="M5 12h14"/></svg>',sun:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-sun"><circle cx="12" cy="12" r="5"/><path d="M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42"/></svg>',moon:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-moon"><path d="M21 12.79A9 9 0 1111.21 3 7 7 0 0021 12.79z"/></svg>',moreHorizontal:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-more-horizontal"><circle cx="12" cy="12" r="1"/><circle cx="19" cy="12" r="1"/><circle cx="5" cy="12" r="1"/></svg>',moreVertical:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-more-vertical"><circle cx="12" cy="12" r="1"/><circle cx="12" cy="5" r="1"/><circle cx="12" cy="19" r="1"/></svg>',send:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-send"><path d="M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z"/></svg>',smile:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-smile"><circle cx="12" cy="12" r="10"/><path d="M8 14s1.5 2 4 2 4-2 4-2M9 9h.01M15 9h.01"/></svg>',search:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-search"><circle cx="11" cy="11" r="8"/><path d="M21 21l-4.35-4.35"/></svg>',upload:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-upload"><path d="M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 3v12"/></svg>',video:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-video"><path d="M23 7l-7 5 7 5V7z"/><rect x="1" y="5" width="15" height="14" rx="2" ry="2"/></svg>',x:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-x"><path d="M18 6L6 18M6 6l12 12"/></svg>',star:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-star"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>',plus:'<svg width="24" height="24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-plus"><path d="M12 5v14M5 12h14"/></svg>'};var sv={tv:"(min-width: 2780px)",screenL:"(max-width: 1920px)","screenL<":"(min-width: 1920px)",screenM:"(max-width: 1680px)","screenM<":"(min-width: 1680px)",screenS:"(max-width: 1440px)","screenS<":"(min-width: 1440px)",tabletL:"(max-width: 1366px)","tabletL<":"(min-width: 1366px)",tabletM:"(max-width: 1280px)","tabletM<":"(min-width: 1280px)",tabletS:"(max-width: 1024px)","tabletS<":"(min-width: 1024px)",mobileL:"(max-width: 768px)","mobileL<":"(min-width: 768px)",mobileM:"(max-width: 560px)","mobileM<":"(min-width: 560px)",mobileS:"(max-width: 480px)","mobileS<":"(min-width: 480px)",mobileXS:"(max-width: 375px)","mobileXS<":"(min-width: 375px)",light:"(prefers-color-scheme: light)",dark:"(prefers-color-scheme: dark)",print:"print"};var iv={base:150,ratio:1.333,unit:"ms",subSequence:!0,defaultBezier:"cubic-bezier(.29, .67, .51, .97)",springBezier:"cubic-bezier(.32, .72, 0, 1)"};var av={radiusControl:"12px",radiusCard:"17px",radiusSheet:"24px",radiusPill:"999px",controlH:"44px",controlHCompact:"36px"};var Cc={version:"0.0.1",color:Zk,gradient:Jk,theme:Qk,typography:tv,spacing:ev,font:rv,fontFamily:nv,timing:iv,icons:ov,media:sv,sizes:av,reset:{html:{},body:{}},animation:{fadeIn:{from:{opacity:0},to:{opacity:1}},modalIn:{from:{transform:"scale(0.95)",opacity:0},to:{transform:"",opacity:1}},modalOut:{to:{transform:"scale(0.95)",opacity:0}}},devices:{},class:{},svg:{},grid:{},shape:{}};var Rs={};$(Rs,{A:()=>EC,AssetPicture:()=>Cv,Audio:()=>Tv,Avatar:()=>VC,B:()=>Kv,Block:()=>cv,Box:()=>Ku,Br:()=>Zv,Button:()=>OC,ButtonSet:()=>LC,COMPONENTS:()=>oo,Caption:()=>Nv,Checkbox:()=>aC,CheckboxHgroup:()=>cC,Circle:()=>Sv,CircleButton:()=>PC,Clickable:()=>_v,Data:()=>Yv,Dialog:()=>$C,DialogFooter:()=>FC,DialogHeader:()=>MC,Dropdown:()=>zC,DropdownList:()=>HC,DropdownParent:()=>WC,DropdownParentFocus:()=>qC,DropdownSiblingFocus:()=>KC,FileIcon:()=>xC,Flex:()=>fv,Focusable:()=>xv,FocusableComponent:()=>wv,Footnote:()=>qv,Form:()=>mv,Grid:()=>dv,Gutter:()=>hv,H1:()=>Pv,H2:()=>Dv,H3:()=>Lv,H4:()=>Iv,H5:()=>$v,H6:()=>Mv,Headline:()=>Hv,Hgroup:()=>rC,HgroupButton:()=>oC,HgroupRows:()=>nC,Hoverable:()=>bv,Hr:()=>Xv,I:()=>Gv,Icon:()=>bC,IconButton:()=>IC,IconText:()=>_C,Iframe:()=>yv,Img:()=>gv,Inline:()=>lv,InlineFlex:()=>uv,InlineGrid:()=>pv,Input:()=>sC,Italic:()=>Uv,KangorooButton:()=>DC,Li:()=>Jv,Link:()=>Xb,Notification:()=>GC,NumberInput:()=>iC,Ol:()=>tC,P:()=>Fv,Picture:()=>vv,Radio:()=>lC,RadioHgroup:()=>fC,Range:()=>UC,RouteLink:()=>AC,RouterLink:()=>Zb,SHAPES:()=>Wu,Select:()=>TC,Shape:()=>Ab,Span:()=>Rv,SquareButton:()=>RC,Strong:()=>jv,Subhead:()=>Wv,Svg:()=>Ev,Text:()=>Ov,Textarea:()=>pC,TextareaWithButton:()=>hC,Theme:()=>kv,Title:()=>zv,Toggle:()=>uC,ToggleHgroup:()=>dC,Tooltip:()=>NC,TooltipHidden:()=>jC,TooltipParent:()=>BC,U:()=>Bv,Ul:()=>Qv,Underline:()=>Vv,Video:()=>Av,depth:()=>qu,focusableRingEnabled:()=>zu,getSystemGlobalTheme:()=>Ec});var Sb={};$(Sb,{Block:()=>cv,Flex:()=>fv,Grid:()=>dv,Gutter:()=>hv,Inline:()=>lv,InlineFlex:()=>uv,InlineGrid:()=>pv});var cv={display:"block"},lv={display:"inline"},fv={display:"flex"},uv={display:"inline-flex"},dv={display:"grid"},pv={display:"inline-grid"},hv={boxSize:"C1"};var kb={};$(kb,{Img:()=>gv});D();var gv={tag:"img",attr:{title:t=>t.title||t.alt,alt:t=>t.alt!=null?t.alt:t.title||"",src:t=>{let e=Qt(t);return e&&e.src||t.src},srcset:t=>{let e=Qt(t);return(e?Sa(e):"")||t.srcset}}};var vb={};$(vb,{Form:()=>mv});var mv={tag:"form"};var Cb={};$(Cb,{Iframe:()=>yv});var yv={tag:"iframe",position:"relative",minWidth:"G",minHeight:"G"};var Eb={};$(Eb,{Clickable:()=>_v,Focusable:()=>xv,FocusableComponent:()=>wv,Hoverable:()=>bv,focusableRingEnabled:()=>zu});var xD={appearance:"none",fontFamily:"inherit"},bv={transition:"C defaultBezier",transitionProperty:"opacity, transform",opacity:.85,":hover":{opacity:.9,transform:"scale(1.015)"},":active":{opacity:1,transform:"scale(1.015)"},".active":{opacity:1,transform:"scale(1.015)",":hover":{opacity:1}}},_v={extends:"Hoverable",":active":{opacity:1,transform:"scale(1.015)"},".active":{opacity:1}};function zu(t){let e=t.context&&t.context.designSystem;return!e||e.focusableRing!==!1}var xv={border:"none",outline:t=>zu(t)?"solid 0 currentColor":"none",":focus-visible":{opacity:1,outline:t=>zu(t)?"solid X currentColor":"none"},attr:{tabIndex:t=>t.tabIndex}},wv={extends:"Focusable",tag:"button",fontSize:"A",type:"button",border:"none",textDecoration:"none",lineHeight:"1",whiteSpace:"nowrap",fontFamily:"inherit",cursor:"pointer",":disabled":{cursor:"not-allowed"},style:xD};var Rb={};$(Rb,{Picture:()=>vv});var Ob={};$(Ob,{Theme:()=>kv,getSystemGlobalTheme:()=>Ec});var Tb={};$(Tb,{Circle:()=>Sv,SHAPES:()=>Wu,Shape:()=>Ab,default:()=>wD,depth:()=>qu});D();var Oe=A(),qu={4:{boxShadow:`rgba(0,0,0,.10) 0 2${Oe.unit.default} 4${Oe.unit.default}`},6:{boxShadow:`rgba(0,0,0,.10) 0 3${Oe.unit.default} 6${Oe.unit.default}`},10:{boxShadow:`rgba(0,0,0,.10) 0 4${Oe.unit.default} 10${Oe.unit.default}`},16:{boxShadow:`rgba(0,0,0,.10) 0 8${Oe.unit.default} 16${Oe.unit.default}`},26:{boxShadow:`rgba(0,0,0,.10) 0 14${Oe.unit.default} 26${Oe.unit.default}`},42:{boxShadow:`rgba(0,0,0,.10) 0 20${Oe.unit.default} 42${Oe.unit.default}`}},Os=t=>ot(t.shapeDirectionColor)||ot(t.borderColor)||ot(t.backgroundColor)||ot(t.background),Hu=t=>{let e=uc.transition(t.transition,t);return e&&e.transition},Wu={rectangle:{},circle:{borderRadius:"100%"},bubble:{},tv:{borderRadius:"1.15em/2.5em"},tooltip:t=>({position:t.position||"relative","&:before":{content:'""',display:"block",width:"0px",height:"0px",border:".35em solid",borderColor:Os(t),transition:Hu(t),transitionProperty:"border-color",position:"absolute",borderRadius:".15em"}}),tooltipDirection:{top:{"&:before":{top:"0",left:"50%",transform:"translate(-50%, -50%) rotate(45deg)"}},right:{"&:before":{top:"50%",right:"0",transform:"translate(50%, -50%) rotate(45deg)"}},bottom:{"&:before":{bottom:"0",left:"50%",transform:"translate(-50%, 50%) rotate(45deg)"}},left:{"&:before":{top:"50%",left:"0",transform:"translate(-50%, -50%) rotate(45deg)"}}},tag:t=>({position:"relative","&:before":{content:'""',display:"block",background:Os(t),transition:Hu(t),transitionProperty:"background",borderRadius:".25em",position:"absolute",zIndex:"-1",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",height:"73%"}}),tagDirection:{top:{"&:before":{bottom:"100%",left:"50%",transform:"translate(-50%, 50%) rotate(45deg)"}},right:{"&:before":{top:"50%",left:"100%",transform:"translate(-50%, -50%) rotate(45deg)"}},bottom:{"&:before":{top:"100%",left:"50%",transform:"translate(-50%, -50%) rotate(45deg)"}},left:{"&:before":{top:"50%",right:"100%",transform:"translate(50%, -50%) rotate(45deg)"}}},hexagon:t=>({position:"relative","&:before, &:after":{content:'""',display:"block",position:"absolute",zIndex:"-1",borderRadius:".25em",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",height:"73%",background:Os(t),transition:Hu(t),transitionProperty:"background"},"&:before":{left:"0",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"},"&:after":{left:"100%",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}}),chevron:t=>({position:"relative","&:before, &:after":{content:'""',display:"block",position:"absolute",zIndex:"-1",aspectRatio:"1/1",top:"50%",transformOrigin:"50% 50%",transition:Hu(t),transitionProperty:"background"},"&:before":{background:`linear-gradient(225deg, ${Os(t)} 25%, transparent 25%), linear-gradient(315deg, ${Os(t)} 25%, transparent 25%)`},"&:after":{background:Os(t),borderRadius:".25em"}}),chevronDirection:{left:{"&:before":{height:"100%",left:"100%",transform:"translate3d(-1%, -50%, 1px) scale(-1, 1)"},"&:after":{height:"73%",left:"0",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}},right:{"&:before":{height:"100%",left:"0",transform:"translate3d(-99%, -50%, 1px)"},"&:after":{height:"73%",left:"100%",transform:"translate3d(-50%, -50%, 1px) rotate(45deg)"}}}},Ab={deps:{exec:dt,getSpacingBasedOnRatio:Ce,getMediaColor:Mt},classlist:{shape:t=>t.deps.exec(Wu[t.shape],t),shapeDirection:t=>{if(!t.shape||!t.shapeDirection)return;let e=Wu[t.shape+"Direction"];return t.shape&&e?e[t.shapeDirection||"left"]:null},shapeDirectionColor:t=>{let e={borderColor:t.deps.getMediaColor(t.background||t.backgroundColor)};return t.shapeDirection?e:null}}},Sv={round:"100%"},wD=Ab;D();var Ec=({context:t,state:e})=>{let r=e&&e.root,n=r&&r.globalTheme||t.designSystem&&t.designSystem.globalTheme;return n==="auto"?null:n},kv={deps:{depth:qu},classlist:{depth:t=>!Lt(t.depth)&&t.deps.depth[t.depth]}};var vv={deps:{getSystemGlobalTheme:Ec},tag:"picture",childExtends:{deps:{getSystemGlobalTheme:Ec},tag:"source",attr:{media:t=>{let{key:e,context:r,deps:n}=t,{media:o}=r.designSystem,s=n.getSystemGlobalTheme(t),i=(t.media||e).slice(1);return i===s?"(min-width: 0px)":i==="dark"||i==="light"?"(max-width: 0px)":o[i]}}},Img:{width:"inherit",ignoreChildExtends:!0,height:"inherit",src:(t,e)=>t.parent?.src||e.src}};var Pb={};$(Pb,{AssetPicture:()=>Cv});D();var Cv={tag:"picture",children:t=>{let e=Qt(t);if(e)return ka(e,t.alt)}};var Db={};$(Db,{Svg:()=>Ev});var Ev={tag:"svg",attr:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"},html:t=>{let{context:e}=t;if(t.semanticIcons)return;if(t.html&&typeof t.html!="function")return t.call("exec",t.html,t);let{designSystem:r,utils:n}=e,o=r&&r.svg,s=t.spriteId||r&&r.useSvgSprite,i=t.call("exec",t.src,t),a=d=>`<use xlink:href="#${d}" />`;if(typeof i=="string"){let d=i.match(/^\s*<symbol\b[^>]*\bid="([^"]+)"/);if(d){let g=d[1],p=e.document||(typeof document<"u"?document:null);if(!(p&&typeof p.getElementById=="function"&&p.getElementById(g))){let m=n&&n.scratchSystem&&n.scratchSystem.appendSVGSprite;r&&!r.__svgCache&&(r.__svgCache={}),typeof m=="function"?m({[g]:i},{document:p}):n&&typeof n.init=="function"&&n.init({svg:{[g]:i}},{document:p,emotion:e.emotion})}return a(g)}}if(!s&&i)return i;let c=t.spriteId;if(c)return a(c);if(o&&o[i])return a(i);let l=Symbol.for(i),f=o[l];if(f&&o[f])return a(f);if(!i)return a("");if(typeof i=="string"&&!i.includes("<"))return typeof console<"u"&&console.warn&&console.warn(`[Svg] Unknown sprite symbol "${i}" \u2014 not registered in design-system sprite. Set the icon name to one that exists in designSystem.icons / context.svg, or register the SVG body via utils.init({ svg: { '${i}': '<svg>...</svg>' } }).`),a("");let u=0;for(let d=0;d<i.length;d++)u=(u<<5)-u+i.charCodeAt(d)|0;return f=o[l]=`svg-${(u>>>0).toString(36)}`,n.init({svg:{[f]:i}},{document:e.document,emotion:e.emotion}),a(f)}};var Lb={};$(Lb,{Video:()=>Av});D();var Av={tag:"video",controls:!0,attr:{src:t=>{let e=Qt(t);return e&&e.src||t.src}},children:t=>{let e=Qt(t);if(!(!e||!Array.isArray(e.variants)||!e.variants.length))return e.variants.map(r=>({tag:"source",attr:{src:r.src,type:r.format}}))},childExtends:{tag:"source"}};var Ib={};$(Ib,{Audio:()=>Tv});D();var Tv={tag:"audio",controls:!0,attr:{src:t=>{let e=Qt(t);return e&&e.src||t.src}},children:t=>{let e=Qt(t);if(!(!e||!Array.isArray(e.variants)||!e.variants.length))return e.variants.map(r=>({tag:"source",attr:{src:r.src,type:r.format}}))},childExtends:{tag:"source"}};var $b={};$($b,{B:()=>Kv,Caption:()=>Nv,Data:()=>Yv,Footnote:()=>qv,H1:()=>Pv,H2:()=>Dv,H3:()=>Lv,H4:()=>Iv,H5:()=>$v,H6:()=>Mv,Headline:()=>Hv,I:()=>Gv,Italic:()=>Uv,P:()=>Fv,Span:()=>Rv,Strong:()=>jv,Subhead:()=>Wv,Text:()=>Ov,Title:()=>zv,U:()=>Bv,Underline:()=>Vv});var Ov={},Rv={tag:"span"},Pv={tag:"h1"},Dv={tag:"h2"},Lv={tag:"h3"},Iv={tag:"h4"},$v={tag:"h5"},Mv={tag:"h6"},Fv={tag:"p"},Nv={tag:"caption"},jv={tag:"strong",fontWeight:"700"},Bv={tag:"u"},Vv={tag:"u"},Uv={tag:"i"},zv={},Hv={tag:"h6",fontSize:"B",fontWeight:500},Wv={tag:"span",fontSize:"Z1"},qv={tag:"span",fontSize:"Z"},Kv={tag:"b"},Gv={tag:"i"},Yv={tag:"data"};var Mb={};$(Mb,{Box:()=>Ku,Br:()=>Zv,Hr:()=>Xv,Li:()=>Jv,Ol:()=>tC,Ul:()=>Qv});var SD=t=>{if(!t.context)return;let{props:e,__ref:r}=t,n=se(e,t,{unpack:!1});r.__class=n},Ku={extends:["Shape","Theme"],boxSizing:"border-box",onBeforeClassAssign:SD},Xv={tag:"hr",margin:"C1 0"},Zv={tag:"br"},Jv={tag:"li"},Qv={tag:"ul",childExtends:{extends:"Li"}},tC={tag:"ol",childExtends:{extends:"Li"}};var Fb={};$(Fb,{Hgroup:()=>rC,HgroupButton:()=>oC,HgroupRows:()=>nC});var eC=t=>{if(t.text!=null||t.html!=null)return!0;for(let e in t){let r=e.charCodeAt(0);if(r>=65&&r<=90)return!0}return!1},rC={display:"flex",tag:"hgroup",flow:"y",gap:"Y2",H:{if:eC,color:"title",tag:"h3",lineHeight:"1em",margin:"0"},P:{if:eC,margin:"0",color:"paragraph"}},nC={extends:"Hgroup",H:{display:"flex",color:"title",align:"center space-between"},P:{color:"paragraph",align:"center space-between"}},oC={extends:"HgroupRows",H:{justifyContent:"space-between",Span:{},Button:{background:"transparent",color:"currentColor",padding:"0",Icon:{name:"x",fontSize:"C"}}},P:{}};var Nb={};$(Nb,{Input:()=>sC});var sC={extends:["Focusable"],tag:"input",border:"none",theme:"field",fontSize:"A",round:"C",lineHeight:"1",padding:"Z2 B",attr:{pattern:t=>t.pattern,minLength:t=>t.minlength,maxLength:t=>t.maxlength,name:t=>t.name,autocomplete:t=>t.autocomplete,placeholder:t=>t.placeholder,value:t=>{if(!t.value)return;let e=t.call("exec",t.value,t);return t.call("isString",e)&&e.includes("{{")?t.call("replaceLiteralsWithObjectFields",e):e},checked:t=>t.call("exec",t.checked,t),disabled:t=>t.disabled||null,readonly:t=>t.readonly,required:t=>t.required,type:t=>t.type}};var jb={};$(jb,{NumberInput:()=>iC});var iC={extends:["Flex","Input"],type:"number",boxSize:"C+X",align:"center center",textAlign:"center",round:"Y1",theme:"transparent",border:"solid gray3",borderWidth:"1px",placeholder:"0",fontWeight:"400","::-webkit-inner-spin-button":{appearance:"none"},attr:{step:t=>t.step,min:t=>t.min,max:t=>t.max}};var Bb={};$(Bb,{Checkbox:()=>aC,CheckboxHgroup:()=>cC});var aC={extends:"Focusable",tag:"label",boxSize:"fit-content fit-content",cursor:"pointer",round:"Y",Input:{type:"checkbox",position:"absolute",opacity:"0",width:"1px",height:"1px",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",":checked + div":{theme:"primary"},":checked + div > svg":{transform:"none",opacity:"1"},":focus-visible + div":{outline:"solid X currentColor",outlineOffset:"Z"},attr:{checked:t=>t.call("exec",t.parent.checked)}},Flex:{align:"center center",fontSize:"B1",padding:"V",theme:"field",round:"X2",transition:"background A defaultBezier",Icon:{icon:"check",opacity:"0",transform:"scale(0.9) rotate(-15deg)",transition:"opacity B defaultBezier"}}},cC={display:"flex",tag:"label",boxSize:"fit-content",align:"flex-start flex-start",gap:"A",Checkbox:{tag:"div"},HgroupRows:{gap:"Z1",margin:"Y - - -"}};var Vb={};$(Vb,{Radio:()=>lC,RadioHgroup:()=>fC});var lC={extends:"Checkbox",Input:{type:"radio",":checked + div:after":{opacity:"1"}},Flex:{round:"100%",padding:"Y",":after":{content:'""',display:"block",boxSize:"X+W1",round:"100%",background:"white",opacity:"0",transition:"opacity .15s ease-in-out"},Icon:null}},fC={extends:"CheckboxHgroup",Checkbox:null,Radio:{}};var Ub={};$(Ub,{Toggle:()=>uC,ToggleHgroup:()=>dC});var uC={extends:"Checkbox",Input:{role:"switch",":checked + div":{background:"green2+8",justifyContent:"flex-end"}},Flex:{boxSize:"A1 B1",padding:"- W_default",round:"D",align:"center flex-start",theme:"field",border:"none",transition:"opacity .15s ease",":after":{content:'""',boxSize:"A A",round:"100%",background:"white",boxShadow:"gray.2 1px 1px Z"},Icon:null}},dC={extends:"CheckboxHgroup",Checkbox:null,Toggle:{}};var zb={};$(zb,{Textarea:()=>pC,TextareaWithButton:()=>hC});var pC={tag:"textarea",extends:["Input","Flex"],fontfamily:"Avenir",placeholder:"Leave us a message...",padding:"A",theme:"field",border:"none",minHeight:"E_default",width:"100%",height:"E1_default",fontFamily:"inherit",round:"Z2",lineHeight:1.4,".outlined":{borderWidth:"1px",borderStyle:"solid"}},hC={display:"flex",gap:"Y2",Textarea:{height:"C2+W",minWidth:"H",padding:"A",fontSize:"Z1",round:"Z2",minHeight:"fit-content"},SquareButton:{background:"blue",Icon:{name:"send"}}};var Hb={};$(Hb,{FileIcon:()=>xC,Icon:()=>bC,IconText:()=>_C});var gC=new Set,mC=(t,e)=>{if(!gC.has(t)&&(gC.add(t),typeof console<"u"&&console.warn)){let r=e&&e.__ref&&e.__ref.path,n=r&&r.length?` at <${r.join(".")}>`:"";console.warn(`[Icon] Unknown icon name "${t}"${n} \u2014 not registered in designSystem.icons, rendering the noIcon placeholder. Fix the name or register the icon in the design system.`)}},yC=new WeakMap,kD=t=>{let e=yC.get(t);return e||(e={pending:new Map,waiting:new Map,failed:new Set},yC.set(t,e)),e},vD=(t,e)=>{if(!t)return null;let r=t.default||t;return typeof r=="string"?r.trim()?{[e]:r}:null:typeof r=="object"&&!Array.isArray(r)&&Object.keys(r).length?r:null},CD=(t,e,r)=>{let n=r&&r.context&&r.context.document||(typeof document<"u"?document:null);ct(t);try{let o=A();o&&!o.__svgCache&&(o.__svgCache={}),t.__svgCache||(t.__svgCache={});let s={};for(let i in e){let a=Kn(e[i],i);a&&(t.icons[i]=a,s[i]=a)}return t.useIconSprite&&n&&Object.keys(s).length&&Gn(s,{document:n}),Object.keys(s).length>0}finally{it()}},ED=(t,e,r,n,o)=>{let s=t&&t.designSystem,i=s&&s.iconsLoader;if(typeof i!="function"||!s.icons)return!1;let a=kD(s);if(a.failed.has(e))return!1;let c=a.waiting.get(e);if(c||(c=new Set,a.waiting.set(e,c)),c.add(o),a.pending.has(e))return!0;let l=Promise.resolve().then(()=>i(e,t)).then(f=>{let u=vD(f,r);return u?CD(s,u,n):!1}).catch(f=>(typeof console<"u"&&console.error&&console.error(`[Icon] iconsLoader failed for "${e}":`,f),!1)).then(f=>{a.pending.delete(e);let u=a.waiting.get(e);a.waiting.delete(e),f||a.failed.add(e),u&&u.forEach(d=>{try{d(f)}catch(g){console.error("[Icon] repaint error:",g)}})});return a.pending.set(e,l),!0},bC={extends:"Svg",width:"A",height:"A",display:"inline-block",style:{fill:"currentColor","*":{fill:"currentColor"}},onInit:(t,e,r)=>{let{parent:n}=t,{icons:o,useIconSprite:s,verbose:i}=r&&r.designSystem,{toCamelCase:a}=r&&r.utils,c=p=>{let h=p[".isActive"];if(h)return p.call("exec",h.name||h.icon)},l=(p,h,m)=>{let{semanticIcons:y}=m&&m.designSystem,{toCamelCase:x}=m&&m.utils,b=f(p,h),w=x(b).split(/([a-z])([A-Z])/g),S=w[1]?w[0]:b.split(".")[0].split(" ")[0],E=y&&y[S];if(E){let O=b.includes(".")?"sfsymbols."+b.split(".").slice(1).join("."):"sfsymbols";return b=E[O]||E[b.split(".")[0].split(" ")[0]],{tag:"span",semanticIcons:!0,width:"A",height:"A",lineHeight:"1em",":after":{fontSize:"Z",fontWeight:"300",content:`"${b}"`,textAlign:"center",display:"inline-block",style:{color:"currentColor",fontFamily:"'SF Pro Icons', 'SF Pro', 'SF Symbols', 'Segoe UI'"}}}}},f=(p,h)=>{let{key:m}=p,y=p.call("exec",p.name||p.icon||m,p);return p.call("isString",y)&&y.includes("{{")&&(y=p.call("replaceLiteralsWithObjectFields",y)),p.call("isString",y)?y:m},u=t.src,d,g=()=>{let p=f(t,e),h=p;if(p.includes(" ")){let T=p.split(" ");p=T[0]+T.slice(1).map(M=>M.charAt(0).toUpperCase()+M.slice(1)).join("")}let m=a(p),y=m.split(/([a-z])([A-Z])/g),x=l(t,e,r);if(x){Object.assign(t,x);return}let b;t.isActive&&(b=c(t));let _=n[".isActive"];n&&n.isActive&&_&&_.icon&&(b=t.call("exec",_.icon||_.Icon.name||_.Icon.icon,t)),t.call("isString",b)&&b.includes("{{")&&(b=t.call("replaceLiteralsWithObjectFields",b));let w;o[b]&&(w=b),o[m]?w=m:o[y[0]+y[1]]?w=y[0]+y[1]:o[y[0]]?w=y[0]:i&&t.warn("Can't find icon:",p,w);let S=o[w],E=n&&n.src||u;!S&&!E&&(ED(r,h,m,t,M=>{if(!(d&&d._disposed)){if(!M)return mC(h,t);g()}})||mC(h,t));let O=s&&w,L=S||E||o.noIcon;if(!(t.spriteId===O&&t.src===L&&t.node&&t.node.innerHTML)&&(t.spriteId=O,t.src=L,typeof t.html=="function"&&t.node)){let T=t.context&&t.context.designSystem;T&&ct(T);try{let M=t.html(t,t.state,t.context);M!=null&&typeof M!="function"&&(t.node.innerHTML=M)}finally{T&&it()}}};d=Y(g,{depth:t.__ref&&t.__ref.path&&t.__ref.path.length||0}),t.__ref&&(t.__ref.__effects||(t.__ref.__effects=[]),t.__ref.__effects.push(d))},attr:{viewBox:"0 0 24 24","aria-hidden":t=>t.ariaLabel||t.role==="img"?null:"true",focusable:"false"}},_C={display:"flex",align:"center center",lineHeight:1,".reversed":{flow:"row-reverse"},".vertical":{flow:"column"},Icon:{if:t=>{let{parent:e}=t,r=t.call("exec",t.icon,t);return t.call("exec",r||e.icon||t.name||t.sfSymbols||e.sfSymbols,t)},icon:t=>t.call("exec",t.parent.icon,t.parent)},text:t=>t.text},xC={display:"flex",theme:"tertiary",boxSize:"C1",align:"center center",round:"Z2",Icon:{fontSize:"B",margin:"auto",icon:"file"}};var Jb={};$(Jb,{A:()=>EC,Link:()=>Xb,RouteLink:()=>AC,RouterLink:()=>Zb});var Ac={};$(Ac,{default:()=>DD,getActiveRoute:()=>Yb,lastLevel:()=>Yu,lastPathname:()=>Gu,matchRoute:()=>qb,parseQuery:()=>Kb,parseRoutePattern:()=>Wb,router:()=>ar,runGuards:()=>Gb});D();var SC=/^:(.+)/,kC=/^\*$/,wC=new Map,Wb=t=>{let e=wC.get(t);if(e)return e;let r=t.replace(/^\//,"").split("/"),n=[],o=!1;for(let i=0;i<r.length;i++){let a=r[i].match(SC);a?n.push({index:i,name:a[1]}):kC.test(r[i])&&(o=!0)}let s={segments:r,params:n,hasWildcard:o,pattern:t};return wC.set(t,s),s},qb=(t,e,r=0)=>{let o=t.replace(/^\//,"").split("/").filter(Boolean).slice(r),s="/"+(o[0]||"");if(!e)return{key:null,content:null,params:{},routePath:s};let i=null,a=-1,c={};for(let l in e){if(l==="/*")continue;let f=Wb(l),u=AD(o,f);u>a&&(a=u,i=l,c=TD(o,f))}return!i&&e["/*"]&&(i="/*"),{key:i,content:i?e[i]:null,params:c,routePath:s}},AD=(t,e)=>{let{segments:r,hasWildcard:n}=e;if(!n&&r.length!==t.length&&r.length!==1&&r.length>t.length)return-1;let o=0,s=Math.min(r.length,t.length);for(let i=0;i<s;i++)if(r[i]===t[i])o+=3;else if(SC.test(r[i]))o+=1;else if(kC.test(r[i]))o+=.5;else return-1;return o},TD=(t,e)=>{let r={};for(let{index:n,name:o}of e.params)t[n]&&(r[o]=decodeURIComponent(t[n]));return r},Kb=t=>{if(!t||t==="?")return{};let e={};return new URLSearchParams(t).forEach((n,o)=>{e[o]!==void 0?(Array.isArray(e[o])||(e[o]=[e[o]]),e[o].push(n)):e[o]=n}),e},Gb=async(t,e)=>{if(!t||!t.length)return!0;for(let r of t){let n=await r(e);if(n===!1)return!1;if(typeof n=="string")return n}return!0},Yb=(t=0,e)=>{e||(e=typeof C<"u"?C.location.pathname:"/");let n=e.split("/")[t+1];if(n)return`/${n}`},Gu,Yu=0,OD=t=>!t||t==="srcdoc"||t==="about:srcdoc"?"/":t,vC={level:Yu,pushState:!0,replace:!1,initialRender:!1,scrollToTop:!0,scrollToNode:!1,get scrollNode(){return typeof st<"u"&&(st.scrollingElement||st.documentElement)||null},scrollBody:!1,useFragment:!1,updateState:!0,scrollToOffset:0,contentElementKey:"content",scrollToOptions:{behavior:"smooth"},useParamsMatching:!0,exitTimeout:300},RD=(t,e)=>{if(!t||t.visibilityState!=="visible")return!1;try{let r=e&&typeof e.matchMedia=="function"&&e.matchMedia("(prefers-reduced-motion: reduce)");if(r&&r.matches)return!1}catch{}return!0},CC=t=>{let e=t.__routeExit;e&&(t.__routeExit=null,e.abort())},PD=(t,e,r,n,o,s,i)=>{let a=e.__routeExit;if(a&&a.page===r)return a.wait;if(CC(e),!r||!r.node||typeof t.onRouteExit>"u"||!RD(s,i))return null;let c=typeof o=="number"&&o>=0?o:vC.exitTimeout,l=typeof AbortController=="function"?new AbortController:null,f={...n,page:r,timeout:c,signal:l?l.signal:void 0},u;try{u=gr("routeExit",t,f)}catch{return null}if(!u||typeof u.then!="function")return null;let d={page:r,abort:()=>{l&&!l.signal.aborted&&l.abort()}};return d.wait=new Promise(g=>{let p=setTimeout(()=>{d.abort(),g()},c),h=()=>{clearTimeout(p),g()};u.then(h,h)}),e.__routeExit=d,d.wait},ar=async(t,e,r={},n={})=>{let o=e||void 0,s=o?.context?.window||C,i=o?.context?.document||st,a={...vC,...o.context.routerOptions,...n};Yu=a.lastLevel;let c=o.__ref;(a.contentElementKey!=="content"&&a.contentElementKey!==c.contentElementKey||!c.contentElementKey)&&(c.contentElementKey=a.contentElementKey||"content");let l=c.contentElementKey||a.contentElementKey||"content",f=s.location.origin!=="null"?s.location.origin:"http://localhost";t=OD(t);let u=typeof s.URL=="function"?s.URL:typeof globalThis<"u"&&globalThis.URL||URL,d=new u(f+t),{pathname:g,search:p,hash:h}=d,m=Kb(p),y=o.node,x=h&&h!==s.location.hash.slice(1),b=g!==Gu;Gu=g;let _=c.__routerRendered,w,S,E,O;if(a.useParamsMatching){let F=qb(g,o.routes,a.level);w=F.key,S=F.routePath,E=F.content,O=F.params}else{w=Yb(a.level,g),S=w;let F=o.routes;E=F?F[w||"/"]||F["/*"]:null,O={}}let L=a.scrollToNode?y:a.scrollNode;if(o.state?.root?.debugging){o.state.root.debugging=!1;return}if(!E){a.onNotFound?a.onNotFound({pathname:g,route:w,element:o}):a.silent||console.warn("[smbls/router] no content matched for path",g,"\u2014 available routes:",Object.keys(o.routes||{}));return}if(a.guards&&a.guards.length){let F={pathname:g,route:w,params:O,query:m,hash:h,element:o,state:r},W=await Gb(a.guards,F);if(W===!1)return;if(typeof W=="string")return ar(W,e,r,{...n,guards:[]})}let T=c.__routerNavSeq=(c.__routerNavSeq||0)+1,M=!_||_.content!==E||_.route!==w,U=b||M||a.force===!0;if(U&&_){let F=PD(o,c,o[l],{from:_.route,to:w,pathname:g,params:O,query:m,hash:h},a.exitTimeout,i,s);if(F&&(await F,c.__routerNavSeq!==T||(c.__routeExit&&c.__routeExit.wait===F&&(c.__routeExit=null),typeof o?.set!="function")))return}else CC(c);if(a.pushState){let F=g+(p||"")+(h||"");try{a.replace?s.history.replaceState(r,null,F):s.history.pushState(r,null,F)}catch{}}let Rt=b||!x?{route:w,routePath:S,hash:h,params:O,query:m,debugging:!1}:{params:O,query:m};if(a.updateState&&o.state.update(Rt,{preventContentUpdate:!0}),U){l&&a.removeOldElement&&o[l].remove();let F=o.__ref?.origin?.content,W={};if(F)for(let G in F){let j=F[G];G==="__ref"||G==="props"||G==="node"||G==="parent"||G==="key"||(typeof j=="string"||typeof j=="number"||typeof j=="boolean"||typeof j=="object"&&j!==null&&!j.node&&!j.__ref)&&(W[G]=j)}let yt={...W,...typeof E=="object"?E:{extends:E}};a.useFragment&&(yt.tag="fragment");let St={content:E,route:w},Pt=c.__routerRendered;try{if(typeof o?.set!="function")return;c.__routerRendered=St,o.set(yt,{contentElementKey:l})}catch(G){c.__routerRendered===St&&(c.__routerRendered=Pt),console.error("[smbls/router] failed to render route content",g,G)}}let mt=!b&&x;if(a.scrollToTop&&!mt&&L?.scrollTo&&L.scrollTo({...a.scrollToOptions||{},top:0,left:0}),a.scrollToNode&&E[l]?.node?.scrollTo&&E[l].node.scrollTo({...a.scrollToOptions||{},top:0,left:0}),h){let F=i.getElementById(h.slice(1));if(F&&L?.scrollTo){let W=s.getComputedStyle?s.getComputedStyle(F):null,yt=W&&parseFloat(W.scrollMarginTop)||0,St=F.getBoundingClientRect().top+L.scrollTop-yt-(a.scrollToOffset||0);L.scrollTo({...a.scrollToOptions||{},top:St,left:0})}}gr("routeChanged",o,a)},DD=ar;var LD=(t,e,r)=>{let{context:n}=e,{href:o,scrollToTop:s,stopPropagation:i}=e,a=e.call("exec",o,e);if(e.call("isString",a)&&a.includes("{{")&&(a=e.call("replaceLiteralsWithObjectFields",a)),i&&t.stopPropagation(),!a)return;let{utils:c,snippets:l,functions:f,routerOptions:u}=n,d=e.__ref.root,g=a.startsWith("http://")||a.startsWith("https://")||a.startsWith("mailto:")||a.startsWith("tel:")||a.startsWith("sketch:")||a.startsWith("whatsapp:")||a.startsWith("sms:")||a.startsWith("skype:")||a.startsWith("viber:")||a.startsWith("callto:")||a.startsWith("facetime:")||a.startsWith("facetime-audio:")||a.startsWith("geo:")||a.startsWith("maps:");if(a&&!g){t.preventDefault();try{let p=d;if(u&&u.customRouterElement){let h=Array.isArray(u.customRouterElement)?u.customRouterElement:u.customRouterElement.split("."),m=d;for(let y of h){if(!m||!m[y]){m=null;break}m=m[y]}m&&(p=m,d.routes&&(p.routes=d.routes))}(f.router||l.router||c.router||ar)(a,p,{},{scrollToOptions:{behavior:"instant"},scrollToTop:e.call("isDefined",s)?s:!0,...u,...e.routerOptions})}catch(p){console.warn(p)}}},Xb={extends:"Focusable",tag:"a",aria:{},fontWeight:"bold",textDecoration:"none",color:"currentColor",draggable:!1,attr:{href:t=>nn(t,t.href)||nn(t,t.call("exec",t,t).href),"aria-label":t=>t.aria?t.aria.label:t.text},onClick:LD},EC={extends:"Link"},Zb={onClick:(t,e,r)=>{let{context:n}=e,{href:o,scrollToTop:s,stopPropagation:i}=e,a=e.call("exec",o,e);if(e.call("isString",a)&&a.includes("{{")&&(a=e.call("replaceLiteralsWithObjectFields",a)),i&&t.stopPropagation(),!a)return;let{utils:c,snippets:l,functions:f,routerOptions:u}=n,d=e.__ref.root,g=a.startsWith("http://")||a.startsWith("https://")||a.startsWith("mailto:")||a.startsWith("tel:")||a.startsWith("sketch:")||a.startsWith("whatsapp:")||a.startsWith("sms:")||a.startsWith("skype:")||a.startsWith("viber:")||a.startsWith("callto:")||a.startsWith("facetime:")||a.startsWith("facetime-audio:")||a.startsWith("geo:")||a.startsWith("maps:");if(a&&!g){t.preventDefault();try{let p=d;if(u&&u.customRouterElement){let h=Array.isArray(u.customRouterElement)?u.customRouterElement:u.customRouterElement.split("."),m=d;for(let y of h){if(!m||!m[y]){m=null;break}m=m[y]}m&&(p=m,d.routes&&(p.routes=d.routes))}(f.router||l.router||c.router||ar)(a,p,{},{scrollToOptions:{behavior:"instant"},scrollToTop:e.call("isDefined",s)?s:!0,...u,...e.routerOptions})}catch(p){console.warn(p)}}}},AC={extends:[Xb,Zb]};var Qb={};$(Qb,{Select:()=>TC});var TC={extends:"Focusable",tag:"select",fontSize:"A",border:"none",boxSizing:"border-box",theme:"field",cursor:"pointer",childProps:{tag:"option",attr:{value:t=>t.value,selected:t=>t.selected,disabled:t=>t.disabled}},attr:{name:t=>t.name,disabled:t=>t.disabled,value:t=>{if(!t.value)return;let e=t.call("exec",t.value,t);return t.call("isString",e)&&e.includes("{{")?t.call("replaceLiteralsWithObjectFields",e):e}}};var t_={};$(t_,{Button:()=>OC,ButtonSet:()=>LC,CircleButton:()=>PC,IconButton:()=>IC,KangorooButton:()=>DC,SquareButton:()=>RC});var OC={extends:["IconText","FocusableComponent"],tag:"button",minHeight:"controlH",fontSize:"Z2",type:"button",borderStyle:"none",display:"inline-flex",align:"center center",textDecoration:"none",lineHeight:"1",whiteSpace:"nowrap",padding:"0 A",fontWeight:"700",fontFamily:"inherit",round:"radiusPill",disabled:t=>t.call("exec",t.disabled)},RC={extends:"Button",fontSize:"A",width:"A",minHeight:"auto",padding:"Z",aspectRatio:"1 / 1",boxSize:"fit-content fit-content",justifyContent:"center",round:"Z2",boxSizing:"content-box"},PC={extends:"SquareButton",round:"C"},DC={extends:"Button",childExtends:"IconText"},LC={tag:"nav",display:"flex",childExtends:"SquareButton"},IC={extends:["SquareButton","ClickableItem"],round:"Z"};var e_={};$(e_,{Dialog:()=>$C,DialogFooter:()=>FC,DialogHeader:()=>MC});var $C={display:"flex",tag:"dialog",flow:"column",border:"0",theme:"dialog",round:"Z2"},MC={extends:"Hgroup",minWidth:"100%",gap:"A",Title:{align:"center space-between",Text:{text:"Title"},SquareButton:{icon:"x",theme:"transparent"}},Paragraph:{color:"caption"}},FC={display:"flex",align:"center flex-end",gap:"X2",margin:"auto - -",padding:"Y2 X2",childExtends:{extends:"Button",textTransform:"uppercase",background:"transparent","@dark":{theme:"primary @dark .color-only"},"@light":{theme:"primary @light .color-only"},"&":{padding:"Z A"},":hover":{theme:"tertiary"},":active":{background:"white.1"}},Cancel:{text:"cancel"},Ok:{text:"ok"}};var r_={};$(r_,{Tooltip:()=>NC,TooltipHidden:()=>jC,TooltipParent:()=>BC});D();var NC={display:"flex",theme:"dialog",background:"black",flow:"column",shape:"tooltip",shapeDirection:"left",padding:"Z1 A",round:"Y2",width:"fit-content",minWidth:"D2",maxWidth:"F2",gap:"X",textAlign:"center",attr:{tooltip:!0},Title:{if:t=>Tt(t.parent.title)||t.parent.title,width:"fit-content",fontWeight:500,color:"gray12",text:t=>t.parent.title},P:{if:(t,e)=>t.call("isDefined",t.call("exec",t.parent.description,t))||t.text,width:"fit-content",fontSize:"Z2",margin:"0",color:"gray6",fontWeight:"400",text:(t,e)=>t.call("exec",t.parent.description,t)}},jC={extends:"Tooltip",position:"absolute",pointerEvents:"none",opacity:"0",visibility:"hidden",transition:"C defaultBezier opacity, C defaultBezier visibility, B defaultBezier transform",onInit:t=>{let e=!t.shapeDirection||t.shapeDirection==="top"?{top:"112%",left:"50%",transform:"translate3d(-50%,10%,0)",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="right"?{transform:"translate3d(10%,-50%,0)",left:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="bottom"?{transform:"translate3d(-50%,-10%,0)",bottom:"112%",left:"50%",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="left"?{transform:"translate3d(10%,-50%,0)",right:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:{};Object.assign(t,e)}},BC={position:"relative",zIndex:999,onInit:t=>{let{Tooltip:e,TooltipHidden:r}=t,n=e||r;if(!n)return;let o=n&&n[".isActive"];Object.assign(t,{":hover, &:focus-visible":{zIndex:1e3,"& [tooltip]":o||{transform:"translate3d(-50%, 0, 0)",opacity:1,visibility:"visible"}}})}};var n_={};$(n_,{Avatar:()=>VC});var ID=t=>{let r=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64"><rect width="64" height="64" rx="32" fill="#71718A"/><text x="32" y="42" font-family="system-ui,sans-serif" font-size="28" font-weight="700" text-anchor="middle" fill="#fff">${String(t||"").trim().charAt(0).toUpperCase()||"?"}</text></svg>`;return"data:image/svg+xml;utf8,"+encodeURIComponent(r)},VC={extends:"Img",display:"block",avatarType:"adventurer-neutral",borderRadius:"100%",boxSize:"C+X C+X",src:t=>`https://api.dicebear.com/7.x/${t.avatarType||"initials"}/svg?seed=${t.key||"no-avatar"}`,onError:(t,e)=>{if(!e.node||e.node.__avatarFallbackApplied)return;e.node.__avatarFallbackApplied=!0;let r=e.node.getAttribute("alt")||(e.key!=="no-avatar"?e.key:"");e.node.src=ID(r)},attr:{alt:t=>t.alt!=null?t.alt:t.text?t.call("exec",t.text,t):t.key&&t.key!=="no-avatar"?t.key:""}};var o_={};$(o_,{Range:()=>UC});var UC={tag:"input",appearance:"none",width:"100%",height:"2px",outline:"none",flex:1,onInput:(t,e,r)=>{e.call("isFunction",e.onInput)?e.onInput(t,e,r):r.update({value:parseFloat(e.node.value)})},onChange:(t,e,r)=>{e.call("isFunction",e.onChange)?e.onChange(t,e,r):r.update({value:parseFloat(e.node.value)})},"::-webkit-slider-thumb":{boxSizing:"content-box",width:"8px",height:"8px",borderWidth:"2px",borderStyle:"solid",borderRadius:"100%",opacity:".8",appearance:"none"},"::-webkit-slider-runnable-track":{},"@dark":{background:"white.2","::-webkit-slider-thumb":{background:"#232526",borderColor:Go("#454646",.75)},":hover":{"::-webkit-slider-thumb":{borderColor:Go("#fff",.35)}},":focus":{"::-webkit-slider-thumb":{borderColor:"#3C6AC0"}}},"@light":{background:"gray9","::-webkit-slider-thumb":{background:"white",borderColor:"gray9"},":hover":{"::-webkit-slider-thumb":{borderColor:"gray7"}},":focus":{"::-webkit-slider-thumb":{borderColor:"blue"}}},deps:{returnPropertyValue:(t,e,r)=>{let n=t.call("exec",t[e],t);return(t.call("isFunction",n)?n(t,t.state):n!==void 0?n:r!==void 0?r:0)+""}},attr:{type:"range",value:(t,e)=>t.call("exec",e.value||t.value||t.defaultValue,t),min:(t,e)=>t.deps.returnPropertyValue(t,"min",0),max:(t,e)=>t.deps.returnPropertyValue(t,"max",100),step:(t,e)=>t.deps.returnPropertyValue(t,"step",1)}};var s_={};$(s_,{Dropdown:()=>zC,DropdownList:()=>HC,DropdownParent:()=>WC,DropdownParentFocus:()=>qC,DropdownSiblingFocus:()=>KC});var zC={attr:{dropdown:!0},position:"absolute",top:"100%",left:"0",zIndex:1e3,theme:"quaternary",padding:"Y",round:"Z2",flow:"column",gap:"X",transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},HC={display:"flex",attr:{dropdown:!0},padding:"0 Y",maxHeight:"G",flow:"column",theme:"quaternary",overflow:"hidden auto",style:{listStyleType:"none"},transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",children:t=>t.options||[],childrenAs:"props",".hidden":{transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},childExtends:{extends:"Button",state:{},isActive:({key:t,state:e})=>e.active===t,position:"relative",round:"0",align:"center flex-end",flow:"row-reverse",padding:"Z2 C Z2 Y2",margin:"0",gap:"Y2",theme:"quaternary .child",":hover":{style:{svg:{opacity:"0.5"}}},Icon:{isActive:({key:t,state:e})=>e.active===t,name:"checkmark",opacity:"0.1",".active":{opacity:"1"}},":not(:first-child)":{"@dark":{border:"solid gray4.65"},"@light":{border:"solid gray11"},borderWidth:"1px 0 0"}}},WC={position:"relative",zIndex:999,":hover":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}}},qC={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}},Dropdown:{onClick:()=>{document.activeElement?.blur()}}},KC={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& ~ [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}}};var i_={};$(i_,{Notification:()=>GC});var GC={display:"flex",theme:"alert",padding:"Z1 B Z A",round:"A A A Y2",gap:"X2",cursor:"pointer",align:"flex-start center",IconText:{Icon:{name:"info outline"},Text:{":empty":{hide:!0}}},Hgroup:{extends:["Flex","Hgroup"],flow:"y",align:"flex-start",gap:"X2",H:{tag:"h6",margin:"0",fontWeight:"600",lineHeight:"1em",text:"Notification",":empty":{hide:!0}},P:{fontSize:"Z",margin:"0",text:"is not always a distraction",":empty":{hide:!0}}}};var oo=Object.assign({},Sb,kb,vb,Cb,Eb,Rb,Pb,Db,Tb,Lb,Ib,Ob,$b,Mb,Fb,Nb,jb,Bb,Vb,Ub,zb,Hb,Jb,Qb,t_,e_,r_,n_,o_,s_,i_);function Xu(t){if(t==null)return 0;if(typeof t!="object")return YC(String(t));let e=2166136261;if(Array.isArray(t)){e=(e^91)*16777619;for(let n=0;n<t.length;n++)e=(e^Xu(t[n]))*16777619;return e>>>0}let r=Object.keys(t).sort();for(let n=0;n<r.length;n++)e=(e^YC(r[n]))*16777619,e=(e^Xu(t[r[n]]))*16777619;return e>>>0}function YC(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e}function Zu(t,e){if(t===e)return!0;if(t===null||e===null||typeof t!=typeof e||typeof t!="object")return!1;if(Array.isArray(t)){if(!Array.isArray(e)||t.length!==e.length)return!1;for(let o=0;o<t.length;o++)if(!Zu(t[o],e[o]))return!1;return!0}let r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;for(let o=0;o<r.length;o++){let s=r[o];if(!Object.prototype.hasOwnProperty.call(e,s)||!Zu(t[s],e[s]))return!1}return!0}function a_(t,e){if(e===void 0)return t;if(t===void 0)return e;if(e===null)return null;if(typeof e!="object"||Array.isArray(e))return e;if(typeof t!="object"||Array.isArray(t))return{...e};let r=!1,n={};for(let o in t)if(o in e){let s=a_(t[o],e[o]);n[o]=s,s!==t[o]&&(r=!0)}else n[o]=t[o];for(let o in e)o in t||(n[o]=e[o],r=!0);return r?n:t}function c_(t,e,r){if(!e||typeof e!="object")return t;if(!t||typeof t!="object")return e;if(r||(r=new WeakSet),r.has(e))return t;r.add(e);for(let n in e){let o=e[n];o&&typeof o=="object"&&!Array.isArray(o)&&t[n]&&typeof t[n]=="object"&&!Array.isArray(t[n])?c_(t[n],o,r):t[n]=o}return t}function an(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=e*16777619>>>0;return e.toString(36)}function Ps(t){return t.replace(/[A-Z]/g,e=>"-"+e.toLowerCase())}function Tc(t){let e=String(t);return e.length<=20?e.replace(/\s+/g,"_").replace(/[^a-zA-Z0-9_-]/g,"").toLowerCase():an(e)}function XC(t){return t.split(`
85
+ `).map(an).join(`
86
+ `)}var ZC={display:"d",position:"pos",padding:"p",paddingTop:"pt",paddingRight:"pr",paddingBottom:"pb",paddingLeft:"pl",paddingBlock:"pbl",paddingInline:"pin",margin:"m",marginTop:"mt",marginRight:"mr",marginBottom:"mb",marginLeft:"ml",marginBlock:"mbl",marginInline:"min",width:"w",height:"h",minWidth:"mnw",minHeight:"mnh",maxWidth:"mxw",maxHeight:"mxh",top:"t",right:"r",bottom:"b",left:"l",flex:"fx",flexDirection:"fxd",flexWrap:"fxw",flexGrow:"fxg",flexShrink:"fxs",flexBasis:"fxb",justifyContent:"jc",alignItems:"ai",alignSelf:"as",alignContent:"ac",gap:"g",rowGap:"rg",columnGap:"cg",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",gridColumn:"gc",gridRow:"gr",overflow:"of",overflowX:"ofx",overflowY:"ofy",fontSize:"fs",fontWeight:"fw",fontFamily:"ff",fontStyle:"fst",lineHeight:"lh",letterSpacing:"ls",textAlign:"ta",textDecoration:"td",textTransform:"tt",color:"c",background:"bg",backgroundColor:"bgc",backgroundImage:"bgi",border:"bd",borderRadius:"br",borderColor:"bdc",borderWidth:"bdw",borderStyle:"bds",boxShadow:"bxsh",opacity:"op",zIndex:"z",cursor:"cur",transition:"tr",transform:"tf",animation:"an",visibility:"vis",whiteSpace:"ws",wordBreak:"wb",objectFit:"obj",pointerEvents:"pe",userSelect:"us",boxSizing:"bxz",outline:"ol",listStyle:"lis",textOverflow:"txo",verticalAlign:"va",float:"fl",clear:"cl",content:"cnt",backdropFilter:"bdf",filter:"flt",resize:"rsz",appearance:"apr",fill:"fil",stroke:"stk",scrollBehavior:"sb",inset:"ins"};function JC(t,e){let r=ZC[t]||an(t),n=Tc(e),o=`_${r}-${n}`,s=Ps(t),i=ND[s],a=i?`${s}: ${e};${i}: ${e}`:`${s}: ${e}`,c=`.${o}{${a}}`;return`${o}
87
+ ${c}`}var ND={"backdrop-filter":"-webkit-backdrop-filter","user-select":"-webkit-user-select","mask-image":"-webkit-mask-image","mask-size":"-webkit-mask-size","mask-repeat":"-webkit-mask-repeat","mask-position":"-webkit-mask-position","mask-clip":"-webkit-mask-clip","mask-origin":"-webkit-mask-origin","background-clip":"-webkit-background-clip"},jD="@media (hover: hover)",BD=/(?:^|[^\\]):hover(?![\w-])/,QC=t=>typeof t=="string"&&(t.indexOf("{")!==-1||t.indexOf("}")!==-1);function tE(t){let e=t.split("\0"),r=[],n=[];for(let o=0;o+1<e.length;o+=2){let s=e[o],i=e[o+1];if(!i||QC(i))continue;let a=ZC[s]||an(s),c=Tc(i),l=`_${a}-${c}`,f=Ps(s);r.push(l),n.push(`.${l}{${f}:${i}}`)}return r.join(" ")+"\0"+n.join(`
88
+ `)}function eE(t,e,r){let n=t+e,o=`_c${an(n)}`,s=e.split("\0"),i="";for(let l=0;l+1<s.length;l+=2){let f=s[l],u=s[l+1];u&&(QC(u)||(i+=`${Ps(f)}:${u};`))}let a,c;if(t.startsWith("@media"))c=`.${o}`,a=`${t}{${c}{${i}}}`;else if(t.startsWith(":")||t.startsWith("&")||t.startsWith("[")&&!t.includes("&")){let l=t.startsWith("&")?t.slice(1):t;c=`.${o}${l}`,a=`${c}{${i}}`}else t.includes("&")?(c=t.replace("&",`.${o}`),a=`${c}{${i}}`):(c=`.${o} ${t}`,a=`${c}{${i}}`);return r!==!1&&BD.test(c)&&(a=`${jD}{${a}}`),`${o}
89
+ ${a}`}var l_=null;function Qu(t){l_=t}var Ve={structuralHash:Xu,deepEqual:Zu,mergeStructural:a_,overwriteDeep:c_,shortHash:an,toKebab:Ps,sanitizeValue:Tc,batchShortHash:XC,atomicCssClass:JC,batchAtomicCss:tE,compoundCssClass:eE},rE=!1,Ju=null;function nE(t){return Ju||(Ju=import(t||"@symbo.ls/wasm/pkg").then(e=>(e.structuralHash&&(Ve.structuralHash=e.structuralHash),e.deepEqual&&(Ve.deepEqual=e.deepEqual),e.mergeStructural&&(Ve.mergeStructural=e.mergeStructural),e.overwriteDeep&&(Ve.overwriteDeep=e.overwriteDeep),e.shortHash&&(Ve.shortHash=e.shortHash),e.toKebab&&(Ve.toKebab=e.toKebab),e.sanitizeValue&&(Ve.sanitizeValue=e.sanitizeValue),e.batchShortHash&&(Ve.batchShortHash=e.batchShortHash),e.atomicCssClass&&(Ve.atomicCssClass=e.atomicCssClass),e.batchAtomicCss&&(Ve.batchAtomicCss=e.batchAtomicCss),e.compoundCssClass&&(Ve.compoundCssClass=e.compoundCssClass),rE=!0,l_&&e.batchAtomicCss&&l_({batchAtomicCss:e.batchAtomicCss,compoundCssClass:e.compoundCssClass}),!0)).catch(e=>(console.debug("[smbls] WASM not available, using JS fallbacks:",e.message),!1)),Ju)}function oE(){return rE}D();var Oc={};$(Oc,{CDN_PROVIDERS:()=>we,DOMQL_EVENTS:()=>eh,DOMQ_PROPERTIES:()=>$r,ELEMENT_METHOD_OVERRIDE_POINTS:()=>Eo,ENV:()=>_h,HTML_TAGS:()=>Ro,METHODS:()=>Fr,METHODS_EXL:()=>xi,NODE_ENV:()=>Ie,OPTIONS:()=>Wi,PACKAGE_MANAGER_TO_CDN:()=>Ur,PARSED_DOMQ_PROPERTIES:()=>_i,PROPS_METHODS:()=>Mr,STATE_METHODS:()=>xn,STATE_PROPERTIES:()=>Qp,SVG_TAGS:()=>gw,TYPES:()=>di,UNIVERSAL_RESERVED_KEYS:()=>xf,__resetBuiltinMethodWarnings:()=>om,addCaching:()=>Jl,addContext:()=>Zl,addExtend:()=>Uh,addExtends:()=>Ye,addItemAfterEveryElement:()=>Bp,addProtoToArray:()=>gi,addRef:()=>Gl,applyCSS:()=>d_,applyDependentState:()=>ag,applyEvent:()=>of,applyEventUpdate:()=>sf,applyExtends:()=>bw,applyProps:()=>Ni,arrayContainsOtherArray:()=>Lp,arraysEqual:()=>Up,arrayzeValue:()=>Mn,buildImgSrcset:()=>Sa,buildSourcesAndImg:()=>ka,cache:()=>dg,call:()=>Ig,captureSnapshot:()=>Mg,checkForStateTypes:()=>ng,checkIfInherits:()=>nf,checkIfStringIsInArray:()=>Wp,clone:()=>oh,cloneAndMergeArrayExtend:()=>Ri,cloneFunction:()=>Eh,collectExtendsList:()=>Po,concatAddExtends:()=>jh,copyJavaScriptToClipboard:()=>am,copyStringToClipboard:()=>im,createBasedOnType:()=>Kl,createElement:()=>rg,createElementExtends:()=>$l,createExtends:()=>Di,createExtendsFromKeys:()=>Do,createExtendsStack:()=>jl,createIfConditionFlag:()=>Ah,createInheritedState:()=>og,createKey:()=>Ti,createNestedObject:()=>dh,createNestedObjectByKeyPath:()=>ig,createObjectWithoutPrototype:()=>Al,createParent:()=>Yl,createPath:()=>Xl,createProps:()=>ji,createPropsStack:()=>Wl,createRoot:()=>eg,createScope:()=>lg,createSnapshotId:()=>Ai,customDecodeURIComponent:()=>Jp,customEncodeURIComponent:()=>Zp,cutArrayAfterValue:()=>Np,cutArrayBeforeValue:()=>Fp,debounce:()=>Oi,debounceOnContext:()=>vh,decodeNewlines:()=>Xp,deepClone:()=>lt,deepContains:()=>fh,deepDefaults:()=>Ho,deepDestringifyFunctions:()=>be,deepExtend:()=>Il,deepMerge:()=>at,deepMergeExtends:()=>Xe,deepStringifyFunctions:()=>Si,defineSetter:()=>Dg,destringifyGlobalScope:()=>vi,detectHeightOnInit:()=>Vg,detectInfiniteLoop:()=>mh,document:()=>st,encodeNewlines:()=>Yp,error:()=>Pn,excludeKeysFromObject:()=>bh,exec:()=>dt,extendCachedRegistry:()=>Bh,extendStackRegistry:()=>Li,extractArrayExtend:()=>$i,fetchLibraryData:()=>Cf,fibonacciNumberByIndex:()=>Ug,fileEntryUrl:()=>kf,filterArrays:()=>zp,filterArraysFast:()=>Hp,finalizeExtends:()=>Bl,findClosestNumber:()=>vf,findClosestNumberInFactory:()=>tm,findInheritedState:()=>rf,findKeyPosition:()=>Kp,flattenExtend:()=>Lo,formatDate:()=>Bg,generateHash:()=>Pl,generateHeadArrayTags:()=>Sf,generateKey:()=>Ei,generateMetaTags:()=>Jg,get:()=>Tg,getActiveRoute:()=>Yb,getCDNDirUrl:()=>wf,getCDNUrl:()=>Me,getCapitalCaseKeys:()=>Wh,getCdnProviderFromConfig:()=>Vo,getChildStateInKey:()=>ef,getChildren:()=>Pg,getContext:()=>ca,getCookie:()=>Dh,getDB:()=>pa,getEmotionStylesheet:()=>um,getExtendsInElement:()=>zh,getExtendsStack:()=>Pi,getExtendsStackRegistry:()=>Ll,getFrequencyInArray:()=>Ip,getFunctionSource:()=>Le,getHashedExtend:()=>Ii,getImportMapScript:()=>jg,getInObjectByPath:()=>gh,getLocalStorage:()=>Ih,getNev:()=>kh,getPageMetadata:()=>Qg,getParentStateInKey:()=>tf,getPath:()=>ra,getQuery:()=>ha,getRef:()=>Rg,getRoot:()=>sa,getRootContext:()=>aa,getRootData:()=>ia,getRootState:()=>oa,getRootStateInKey:()=>Ql,getSpreadChildren:()=>qh,global:()=>Rp,hasFunction:()=>De,hasHandlerPlugin:()=>To,hasOwnProperty:()=>ah,hashContent:()=>zo,inheritChildExtends:()=>Fl,inheritChildPropsExtends:()=>Ml,inheritParentProps:()=>Bi,inheritRecursiveChildExtends:()=>Nl,init:()=>Ar,initProps:()=>Jh,is:()=>Jt,isArray:()=>P,isBoolean:()=>xl,isBuiltinElementMethod:()=>th,isContextComponent:()=>Kh,isCyclic:()=>yh,isDOMNode:()=>Zt,isDate:()=>Sl,isDefined:()=>Tt,isDevelopment:()=>jr,isEmpty:()=>Cl,isEmptyObject:()=>ch,isEqualDeep:()=>El,isFailedRevival:()=>Cn,isFunction:()=>R,isHtmlElement:()=>fi,isLazyFunction:()=>sh,isLocal:()=>Sh,isLoudDevRuntime:()=>gt,isMalformedDependency:()=>Dn,isMethod:()=>$g,isMobile:()=>Rh,isNode:()=>pr,isNot:()=>Dp,isNotProduction:()=>An,isNull:()=>wl,isNumber:()=>Ge,isObject:()=>v,isObjectLike:()=>B,isPhoto:()=>zg,isPolyglotRetranslatableKey:()=>Hi,isPolyglotWritableKey:()=>On,isProduction:()=>Nr,isProtectedElementMethod:()=>wn,isStaging:()=>wh,isState:()=>sg,isString:()=>k,isStringFunction:()=>Ao,isTest:()=>Ol,isTesting:()=>xh,isUndefined:()=>Lt,isUniversallyReservedKey:()=>Fg,isUnresolvableDependency:()=>zr,isValidDependencyMap:()=>Ln,isValidHtmlTag:()=>Mh,isWrappedLibrary:()=>Hr,joinArrays:()=>ko,jointStacks:()=>Vh,keys:()=>bf,lastLevel:()=>Yu,lastPathname:()=>Gu,loadCssFile:()=>Kg,loadJavascript:()=>Gg,loadJavascriptFile:()=>Hg,loadJavascriptFileEmbedSync:()=>qg,loadJavascriptFileSync:()=>Wg,loadRemoteCSS:()=>Yg,loadRemoteScript:()=>Uo,log:()=>Lg,logGroupIf:()=>Oh,logIf:()=>Th,lookdown:()=>Eg,lookdownAll:()=>Ag,lookup:()=>Cg,lowercaseFirstLetter:()=>_n,makeObjectWithoutPrototype:()=>lh,map:()=>nh,mapStringsWithContextComponents:()=>Mi,markPolyglotSeeded:()=>Je,matchRoute:()=>qb,matchesComponentNaming:()=>Ze,memoize:()=>Ch,merge:()=>bt,mergeSharedLibraries:()=>ba,mergeSharedLibraryDesignSystems:()=>_a,nextElement:()=>fa,normalizeIgnoreList:()=>ya,normalizeLibraryKey:()=>$n,objectToString:()=>ki,objectizeStringProperty:()=>Fi,overwrite:()=>Ci,overwriteDeep:()=>Wt,overwriteShallow:()=>En,overwriteState:()=>cg,parse:()=>_f,parseDeep:()=>ta,parseQuery:()=>Kb,parseRoutePattern:()=>Wb,pickupElementFromProps:()=>zl,pickupPropsFromElement:()=>Ul,polyglotSeededKeys:()=>Io,previousElement:()=>ua,promoteActiveRootState:()=>Fo,propExists:()=>Xh,propertizeElement:()=>Hl,propertizeUpdate:()=>Yh,reinit:()=>u_,remove:()=>Xw,removeChars:()=>cm,removeCookie:()=>Lh,removeDuplicateProps:()=>Ui,removeDuplicatesInArray:()=>vo,removeFromArray:()=>$p,removeFromObject:()=>uh,removeNestedKeyByPath:()=>ph,removeValueFromArray:()=>hi,removeValueFromArrayAll:()=>jp,reorderArrayByValues:()=>Vp,replaceLiteralsWithObjectFields:()=>Nt,replaceOctalEscapeSequences:()=>Gp,resolveAsset:()=>Qt,resolveFileReferences:()=>In,resolveHandler:()=>Oo,resolveSharedLibraries:()=>sm,returnValueAsText:()=>ql,router:()=>ar,runGuards:()=>Gb,runPluginHook:()=>Ot,scratchSystem:()=>is,scratchUtils:()=>Kr,self:()=>Pp,set:()=>Xn,setActiveRootState:()=>na,setCookie:()=>Ph,setHashedExtend:()=>Dl,setInObjectByPath:()=>hh,setLocalStorage:()=>$h,setNodeStyles:()=>yf,setProps:()=>Og,setPropsPrototype:()=>Vi,sharedLibrary:()=>nm,splitPackageSpecifier:()=>ga,spotByPath:()=>ea,srcsetFor:()=>Wo,stringIncludesAny:()=>yi,stringToObject:()=>ih,stripVersionRangePrefix:()=>ma,swapItemsInArray:()=>Mp,syncProps:()=>zi,toCamelCase:()=>xa,toDashCase:()=>wa,toDescriptionCase:()=>fm,toPriorityOrder:()=>_e,toTitleCase:()=>lm,toggleFullscreen:()=>Ng,triggerEventOn:()=>gr,triggerEventOnUpdate:()=>fg,trimStringFromSymbols:()=>qp,unstackArrayOfObjects:()=>pi,update:()=>Zh,updateProps:()=>Qh,variables:()=>da,verbose:()=>No,warn:()=>la,window:()=>C});D();D();var UD=A(),sE=(t=UD,e)=>{let r=v(e.localFile)?e.localFile:{},n=lt(r.designSystem||{});return at(t,n,ue)},zD={useVariable:!0,useReset:!0,useFontImport:!0,useIconSprite:!0,useDocumentTheme:!0,useSvgSprite:!0},td=(t,e)=>{let r=!e||e===":root",n={};for(let o in t)if(o.startsWith("@media")){let s=r?":root:not([data-theme])":`:root:not([data-theme]) ${e}:not([data-theme])`;n[o]={[s]:t[o]}}else r?n[o]=t[o]:n[`${e}${o}, ${o} ${e}`]=t[o];return n},f_=(t,e)=>{t.CSS_MEDIA_VARS&&xt(td(t.CSS_MEDIA_VARS,e));let r=Yn(t.cssSkinVars,t.cssSkinFallback,e);Object.keys(r).length&&xt(r)},Ar=(t,e=zD)=>{let r=sE(t||{},e),n=e.scopeSelector||":root",o=e.globalTheme;if(typeof window<"u"&&window.location){let h=new URLSearchParams(window.location.search).get("globalTheme");h&&(o=h)}let s=Xn({verbose:e.verbose,useReset:e.useReset,useFontImport:e.useFontImport,useVariable:e.useVariable,useSvgSprite:e.useSvgSprite,useDocumentTheme:e.useDocumentTheme,useIconSprite:e.useIconSprite,useDefaultConfig:e.useDefaultConfig,globalTheme:o,themeRoot:e.themeRoot,files:e.files,assets:e.assets,...r},{newConfig:e.newConfig,config:e.config});s&&(s.scopeSelector=n);let i=Ta(s.font,s.files),a=s.useReset,c=s.useVariable,l=s.useFontImport,f=s.useSvgSprite,u=t.svg,d=s.useIconSprite,g=t.icons;l&&xt(i),c&&(xt({[n]:s.CSS_VARS}),f_(s,n)),a&&xt(s.reset);let p=s.animation;if(p){let h={};for(let m in p)h[`@keyframes ${m}`]=p[m];xt(h)}return(u||f)&&ec(s.svg,{document:e.document}),(g||d)&&Gn(s.icons,{document:e.document}),s},ed={},u_=(t,e=ed)=>{let r=sE(t||{},e),n=e.scopeSelector||":root",o=Xn({verbose:!1,...r});return e.preventInject||(xt({[n]:o.CSS_VARS}),f_(o,n),xt(o.reset)),o},d_=(t,e=ed)=>{xt(t)},HD=(t,e=ed)=>{let r=e.scopeSelector||":root";xt({[r]:t.CSS_VARS}),f_(t,r)};var WD=(t,e=ed)=>{};D();var aE=t=>!t||t==="srcdoc"||t==="about:srcdoc"||t==="blank"||t==="about:blank"?"/":t,qD=t=>{let e=t&&t.initialPath;return typeof e!="string"||!e?null:e[0]==="/"?e:"/"+e},h_={initRouter:!0,injectRouterInLinkComponent:!0,popState:!0},Rc=(t,e)=>{if(!e)return t;let r=Array.isArray(e)?e:e.split("."),n=t;for(let o of r){if(!n||!n[o])return null;n=n[o]}return n},KD=["manual","auto"],p_=new WeakMap,iE=(t,e)=>{let r=e.claims[e.claims.length-1],n=r?r.value:e.found;t.scrollRestoration!==n&&(t.scrollRestoration=n)},GD=(t,e)=>{let r=e&&e.scrollRestoration;if(r!=null){if(!KD.includes(r)){if(t.verbose!==!1){let n=typeof r=="string"?JSON.stringify(r):`a ${typeof r}`;console.warn(`[smbls/router] router.scrollRestoration must be 'manual' or 'auto', got ${n} \u2014 the browser default stays`)}return}try{let n=t.window||C,o=n&&n.history;if(!o||!("scrollRestoration"in o))return;let s=p_.get(o);s||(s={found:o.scrollRestoration,claims:[]},p_.set(o,s));let i={value:r};s.claims.push(i),iE(o,s),t.__teardowns=t.__teardowns||[],t.__teardowns.push(()=>{let a=s.claims.indexOf(i);if(a!==-1){s.claims.splice(a,1),s.claims.length||p_.delete(o);try{iE(o,s)}catch{}}})}catch{}}},cE=(t,e)=>{if(e.router===!1)return;e.router===!0?e.router=h_:e.router=bt(e.router||{},h_);let r=e.router;GD(e,r);let n=async(s,i)=>{let a=s.context?.window||C,c=qD(r);if(!c){if(!a.location)return;let{pathname:f,search:u,hash:d}=a.location;f=aE(f),c=f+u+d}let l=s;if(r.customRouterElement){let f=Rc(s,r.customRouterElement);f&&(l=f,s.routes&&(l.routes=s.routes))}l.routes&&await ar(c,l,{},{initialRender:!0,pushState:!1})},o=!Lt(t.onRenderRouter);return r&&r.initRouter&&!o&&(t.onRenderRouter=n),YD(e,r),r},g_=(t,e)=>{if(e.router===!1)return;let r=e.router||h_;if(!r.popState)return;let n=e.utils&&e.utils.router?e.utils.router:ar,o=e.window||C,s=async i=>{let{pathname:a,search:c,hash:l}=o.location;a=aE(a);let f=a+c+l,u=t;if(r.customRouterElement){let d=Rc(t,r.customRouterElement);d&&(u=d,t.routes&&(u.routes=t.routes))}await u.call("router",f,u,{},{pushState:!1,scrollToTop:!1,level:0,event:i})};o.addEventListener("popstate",s),e.__teardowns=e.__teardowns||[],e.__teardowns.push(()=>o.removeEventListener("popstate",s))},YD=(t,e)=>{let{components:r}=t;if(e&&e.injectRouterInLinkComponent)return at(r.Link||r["smbls.Link"],r.RouterLink||r["smbls.RouterLink"])};D();var m_=C&&C.location?C.location.host.includes("dev."):jr(),lE=m_?"http://localhost:8080/get":"https://api.symbols.app/get",XD={endpoint:lE},fE=async(t,e=XD)=>{let r=e.endpoint||lE,n=e.serviceRoute?P(e.serviceRoute)?e.serviceRoute.map(s=>s.toLowerCase()+"=true").join("&"):e.serviceRoute:"",o;try{return o=await globalThis.fetch(r+"/?"+n,{method:"GET",headers:{"Content-Type":"application/json","X-AppKey":t,"X-Metadata":e.metadata}}),await o.json()}catch(s){if(R(e.onError))return e.onError(s);console.error(s)}},ZD=async(t,e)=>{let{editor:r}=e;if(r&&r.remote){let n=await fE(t,r),o=m_||e.isDevelopment?be(n):be(n.releases[0]);r.serviceRoute?P(r.serviceRoute)?r.serviceRoute.forEach(s=>{Wt(e[s],o[s.toLowerCase()])}):Wt(e[r.serviceRoute],o):["state","designSystem","components","snippets","pages","utils","files","assets","packages","functions","globalScope"].forEach(s=>{Wt(e[s],o[s.toLowerCase()])})}return e},JD=async(t,e,r)=>{let{editor:n}=e;if(n&&n.remote){let o=await fE(t,n),s=m_||e.isDevelopment?be(o):be(o.releases[0]);r(s)}},uE=async(t,e)=>{if(t&&e.editor)try{e.editor.async||await ZD(t,e)}catch(r){console.error(r)}},dE=(t,e,r,n)=>{if(e&&r.editor)try{r.editor.async&&JD(e,r,n||(o=>{let s=o.designSystem;v(s)&&r.utils.init(s),v(o.state)&&t.state.set(o.state)}))}catch(o){console.error(o)}};var Pc=t=>{if(!t||t.__destroyed)return!1;let e=t.context;if(!e)return t.__destroyed=!0,!1;if(Array.isArray(e.__teardowns)){for(let r of e.__teardowns)try{r()}catch(n){console.error("[smbls] destroy teardown error:",n)}e.__teardowns.length=0}try{vr(t)}catch(r){console.error("[smbls] dispose error:",r)}if(e.fetch&&e.fetch.__resolved&&delete e.fetch.__resolved,e.fetch&&e.fetch.__resolving&&delete e.fetch.__resolving,e.db&&e.db.__resolved&&delete e.db.__resolved,e.db&&e.db.__resolving&&delete e.db.__resolving,e.analyze?.destroy)try{e.analyze.destroy()}catch(r){console.error("[analyze] destroy error:",r)}return t.__destroyed=!0,!0};var x_={};$(x_,{Helmet:()=>gE,applyMetadata:()=>$s,default:()=>iL,extractMetadata:()=>nL,generateHeadHtml:()=>sL,helmetPlugin:()=>__,resolveMetadata:()=>Is});D();var QD={title:{tag:"title"},description:{tag:"meta",attr:"name",key:"description"},keywords:{tag:"meta",attr:"name",key:"keywords"},robots:{tag:"meta",attr:"name",key:"robots"},author:{tag:"meta",attr:"name",key:"author"},canonical:{tag:"link",attr:"rel",key:"canonical",valueAttr:"href"},image:{tag:"meta",attr:"property",key:"og:image"},url:{tag:"meta",attr:"property",key:"og:url"},siteName:{tag:"meta",attr:"property",key:"og:site_name"},type:{tag:"meta",attr:"property",key:"og:type"},locale:{tag:"meta",attr:"property",key:"og:locale"},"og:title":{tag:"meta",attr:"property",key:"og:title"},"og:description":{tag:"meta",attr:"property",key:"og:description"},"og:image":{tag:"meta",attr:"property",key:"og:image"},"og:url":{tag:"meta",attr:"property",key:"og:url"},"og:type":{tag:"meta",attr:"property",key:"og:type"},"og:site_name":{tag:"meta",attr:"property",key:"og:site_name"},"og:locale":{tag:"meta",attr:"property",key:"og:locale"},"twitter:card":{tag:"meta",attr:"name",key:"twitter:card"},"twitter:title":{tag:"meta",attr:"name",key:"twitter:title"},"twitter:description":{tag:"meta",attr:"name",key:"twitter:description"},"twitter:image":{tag:"meta",attr:"name",key:"twitter:image"},"twitter:site":{tag:"meta",attr:"name",key:"twitter:site"},"theme-color":{tag:"meta",attr:"name",key:"theme-color"}},tL=t=>{if(t.tag==="link")return`link[${t.attr}="${t.key}"]`;if(t.tag&&!t.attr&&!t.key)return t.tag;if(t.tag&&t.attr&&t.key)return`${t.tag}[${t.attr}="${t.key}"]`},pE=t=>be({v:t}).v,hE=(t,e,r,n)=>{try{return dt(t,e,r)}catch(o){console.warn(`[helmet] metadata factory for "${n}" threw; treating as unset:`,o&&o.message||o);return}},y_=Object.freeze({authored:!0}),Is=(t,e,r,n)=>{if(!t)return{};let o=t;k(o)&&De(o)&&(o=pE(o));let s=R(o),i=!s&&n?.authored===!0,a=s?hE(o,e,r,"metadata"):v(o)?{...o}:{};if(!v(a))return{};for(let c in a){let l=a[c],f=i&&k(l)&&!De(l);k(l)&&De(l)&&(l=pE(l)),R(l)?l=hE(l,e,r,c):k(l)&&De(l)&&(l=void 0),k(l)&&l.includes("{{")&&e?.call&&(l=f?e.call("replaceLiteralsWithObjectFields",l,r,y_):e.call("replaceLiteralsWithObjectFields",l,r)),a[c]=l}return a},eL=t=>!!t&&typeof t=="object"&&(t.notFound===!0||t.metadata?.notFound===!0),rL=(t,e)=>{if(Object.prototype.hasOwnProperty.call(t,e))return t[e];if(t["/*"])return t["/*"];if(t["*"])return t["*"];for(let r in t)if(eL(t[r]))return t[r]},nL=(t,e="/",r,n)=>{let o=t.pages||{},s=rL(o,e),i={};if(t.integrations?.seo&&(i={...t.integrations.seo}),t.app?.metadata){let c=Is(t.app.metadata,r,n,y_);i={...i,...c}}let a=new Set;if(s){let c=s.metadata||s.helmet||{},l=Is(c,r,n,y_);for(let f in l)a.add(f);i={...i,...l},!i.title&&s.state?.title&&(i.title=s.state.title,a.add("title")),!i.description&&s.state?.description&&(i.description=s.state.description,a.add("description"))}if(i.title||(i.title=t.name||"Symbols"),i.title&&(a.has("title")||!i["og:title"])&&(a.has("og:title")||(i["og:title"]=i.title)),i.description&&(a.has("description")||!i["og:description"])&&(a.has("og:description")||(i["og:description"]=i.description)),i.title&&!i["twitter:title"]&&(i["twitter:title"]=i.title),i.description&&!i["twitter:description"]&&(i["twitter:description"]=i.description),i["og:url"]||i.url){let c=(i["og:url"]||i.url||"").replace(/\/$/,"");if(c&&e&&e!=="/"){let l=e.startsWith("/")?e:"/"+e;i["og:url"]=c+l}}return In(i,t.files)},b_=(t,e)=>In(Is(t,e,e.state),e.context?.files),oL=(t,e)=>{let r=e.createElement(t.tag);return t.attr&&r.setAttribute(t.attr,t.key),(e.head||e.querySelector("head")).appendChild(r),r},Ls=t=>{let e=5381,r=String(t);for(let n=0;n<r.length;n++)e=(e*33^r.charCodeAt(n))>>>0;return e.toString(36)},Ds=(t,e,r,n)=>{let o=t.head||t.querySelector("head");if(!o)return;let s=new Map;for(let a of o.querySelectorAll(`[${e}]`))s.set(a.getAttribute(e),a);let i=new Set;for(let a of r)i.add(a);for(let[a,c]of s)i.has(a)||c.remove();for(let a of r){if(s.has(a))continue;let c=n(a);c&&(c.setAttribute(e,a),o.appendChild(c))}},$s=(t,e)=>{if(!(!v(t)||!e)){for(let r in t){let n=t[r];if(n==null||r==="jsonLd"||r==="styles"||r==="scripts"||r==="alternate"||r==="favicons"||r==="icon"||r==="favicon")continue;let o=QD[r];if(!o)continue;let s=tL(o),i=e.querySelector(s)||oL(o,e);i&&(r==="title"?i.textContent=n:o.valueAttr?i.setAttribute(o.valueAttr,n):i.setAttribute("content",n))}if(Array.isArray(t.jsonLd)){let n=t.jsonLd.filter(s=>s!=null).map(s=>k(s)?s:JSON.stringify(s)),o=n.map(Ls);Ds(e,"data-smbls-jsonld",o,s=>{let i=o.indexOf(s),a=e.createElement("script");return a.setAttribute("type","application/ld+json"),a.textContent=n[i],a})}if(Array.isArray(t.styles)){let r=t.styles.filter(o=>o!=null&&String(o).trim()),n=r.map(Ls);Ds(e,"data-smbls-style",n,o=>{let s=n.indexOf(o),i=e.createElement("style");return i.textContent=String(r[s]),i})}if(Array.isArray(t.scripts)){let r=t.scripts.filter(o=>o&&(k(o)?o.trim():o.src)),n=r.map(o=>k(o)?o:String(o.src));Ds(e,"data-smbls-script",n,o=>{let s=n.indexOf(o),i=r[s],a=e.createElement("script");return k(i)?a.setAttribute("src",i):(i.src&&a.setAttribute("src",i.src),i.type&&a.setAttribute("type",i.type),i.async&&(a.async=!0),i.defer&&(a.defer=!0),i.integrity&&a.setAttribute("integrity",i.integrity),i.crossorigin&&a.setAttribute("crossorigin",i.crossorigin),i.referrerpolicy&&a.setAttribute("referrerpolicy",i.referrerpolicy),i.nomodule&&(a.noModule=!0),i.body&&(a.textContent=String(i.body))),a})}if(Array.isArray(t.alternate)){let r=t.alternate.filter(o=>v(o)),n=r.map(o=>`${o.hreflang||""}|${o.href||""}`);Ds(e,"data-smbls-alternate",n,o=>{let s=n.indexOf(o),i=e.createElement("link");i.setAttribute("rel","alternate");for(let[a,c]of Object.entries(r[s]))i.setAttribute(a,c);return i})}if(Array.isArray(t.favicons)){let r=t.favicons.filter(o=>o!=null),n=r.map(o=>v(o)?Ls(JSON.stringify(o)):String(o));Ds(e,"data-smbls-favicon",n,o=>{let s=n.indexOf(o),i=r[s],a=e.createElement("link");if(a.setAttribute("rel","icon"),v(i))for(let[c,l]of Object.entries(i))a.setAttribute(c,l);else a.setAttribute("href",String(i));return a})}if(t.icon||t.favicon){let r=String(t.icon||t.favicon),n=r.endsWith(".svg")?"image/svg+xml":r.endsWith(".png")?"image/png":"";Ds(e,"data-smbls-single-icon",[r],o=>{let s=e.createElement("link");return s.setAttribute("rel","icon"),s.setAttribute("href",o),n&&s.setAttribute("type",n),s})}}},ut=t=>{if(t==null)return"";let e={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#039;"};return t.toString().replace(/[&<>"']/g,r=>e[r])},sL=t=>{let e=['<meta charset="UTF-8">'],r=new Set(["charset","jsonLd","styles","scripts"]),n=!1;for(let[o,s]of Object.entries(t)){if(!s&&s!==0&&s!==!1||r.has(o)||typeof s=="function")continue;if(o==="title"){e.push(`<title>${ut(s)}</title>`);continue}if(o==="viewport"){n||(e.push(`<meta name="viewport" content="${ut(s)}">`),n=!0);continue}if(o==="canonical"){e.push(`<link rel="canonical" href="${ut(s)}">`);continue}if(o==="icon"||o==="favicon"){let f=ut(s),u=f.endsWith(".svg")?' type="image/svg+xml"':f.endsWith(".png")?' type="image/png"':"";e.push(`<link rel="icon" href="${f}"${u}>`);continue}if(o==="favicons"&&Array.isArray(s)){s.forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).map(([d,g])=>`${d}="${ut(g)}"`).join(" ");e.push(`<link rel="icon" ${u}>`)}else typeof f=="string"&&e.push(`<link rel="icon" href="${ut(f)}">`)});continue}if(o==="alternate"&&Array.isArray(s)){s.forEach(f=>{if(typeof f=="object"){let u=Object.entries(f).map(([d,g])=>`${d}="${ut(g)}"`).join(" ");e.push(`<link rel="alternate" ${u}>`)}});continue}let i=["og:","article:","product:","fb:","profile:","book:","business:","music:","video:"],a=["twitter:","DC:","DCTERMS:"],c=i.some(f=>o.startsWith(f)),l=a.some(f=>o.startsWith(f));if(o.startsWith("http-equiv:")){let f=o.replace("http-equiv:","");e.push(`<meta http-equiv="${ut(f)}" content="${ut(s)}">`)}else if(o.startsWith("itemprop:")){let f=o.replace("itemprop:","");e.push(`<meta itemprop="${ut(f)}" content="${ut(s)}">`)}else c?Array.isArray(s)?s.forEach(f=>e.push(`<meta property="${ut(o)}" content="${ut(f)}">`)):e.push(`<meta property="${ut(o)}" content="${ut(s)}">`):l?e.push(`<meta name="${ut(o)}" content="${ut(s)}">`):Array.isArray(s)?s.forEach(f=>e.push(`<meta name="${ut(o)}" content="${ut(f)}">`)):(typeof s=="string"||typeof s=="number"||typeof s=="boolean")&&e.push(`<meta name="${ut(o)}" content="${ut(s)}">`)}if(n||e.splice(1,0,'<meta name="viewport" content="width=device-width, initial-scale=1">'),Array.isArray(t.jsonLd))for(let o of t.jsonLd){if(o==null)continue;let s=typeof o=="string"?o:JSON.stringify(o),i=String(s).replace(/<\/script/gi,"<\\/script");e.push(`<script type="application/ld+json" data-smbls-jsonld="${Ls(s)}">${i}<\/script>`)}if(Array.isArray(t.styles))for(let o of t.styles){if(o==null||!String(o).trim())continue;let s=String(o).replace(/<\/style/gi,"<\\/style");e.push(`<style data-smbls-style="${Ls(s)}">${s}</style>`)}if(Array.isArray(t.scripts))for(let o of t.scripts){if(!o)continue;let s=typeof o=="string",i=s?o:o.src;if(!i&&!(o&&o.body))continue;let a=[];i&&a.push(`src="${ut(i)}"`),s||(o.type&&a.push(`type="${ut(o.type)}"`),o.async&&a.push("async"),o.defer&&a.push("defer"),o.integrity&&a.push(`integrity="${ut(o.integrity)}"`),o.crossorigin&&a.push(`crossorigin="${ut(o.crossorigin)}"`),o.referrerpolicy&&a.push(`referrerpolicy="${ut(o.referrerpolicy)}"`),o.nomodule&&a.push("nomodule"));let c=` data-smbls-script="${ut(i||Ls(o.body||""))}"`;if(!s&&o.body){let l=String(o.body).replace(/<\/script/gi,"<\\/script");e.push(`<script ${a.join(" ")}${c}>${l}<\/script>`)}else e.push(`<script ${a.join(" ")}${c}><\/script>`)}return e.join(`
90
+ `)},gE={define:{metadata:(t,e,r)=>{let n=e.context?.document||typeof document<"u"&&document;if(!n)return;let o=Y(()=>{let s=b_(t,e);$s(s,n);let i=e.state?.root;v(i)&&(i.$helmet=s)});e.__ref?.__effects&&e.__ref.__effects.push(o)}}},__={name:"helmet",create(t){if(!t.metadata)return;let e=t.context?.document||typeof document<"u"&&document;if(!e)return;let r=Y(()=>{let n=t.metadata;if(!n)return;let o=b_(n,t);$s(o,e)});t.__ref?.__effects&&t.__ref.__effects.push(r)},update(t){let e=t.metadata;if(!e)return;let r=t.context?.document||typeof document<"u"&&document;if(!r)return;let n=b_(e,t);$s(n,r)}},iL=gE;Qi();var mE=(t,e,r,n)=>{t&&Ji(t,e,r,n)},yE=(t,e,r)=>{if(!t)return;let n=e.context?.document||typeof document<"u"&&document;if(!n)return;let o=Is(t,e,r);$s(o,n)},bE=async(t,e)=>{if(!t)return;let r={tag:"fragment",...t},n=async()=>{await e.set(r,{preventDefineUpdate:"$router"})};return e.lazyLoad?window.requestAnimationFrame(n):await n(),r},Ms={routes:t=>t,metadata:yE,fetch:mE,$router:bE},_E=(t={})=>{let e={routes:r=>r};return t.metadata!==!1&&(e.metadata=yE),t.fetch!==!1&&(e.fetch=mE),t.router!==!1&&(e.$router=bE),e};var w_={useReset:!0,useVariable:!0,useIconSprite:!0,useSvgSprite:!0,useDocumentTheme:!0,useDefaultIcons:!0,useFontImport:!0,useDefaultConfig:!0},rd={initRouter:!0,popState:!0,injectRouterInLinkComponent:!0},nd={...w_,router:rd},aL={state:{},pages:{},components:{},router:rd,define:Ms},cn=aL;D();D();var xE=(t,e)=>B(t.extends)?t.extends:[];D();var S_={};$(S_,{default:()=>uL,getActiveLang:()=>ln,getLanguages:()=>Lc,getLocalStateLang:()=>Nc,initPolyglot:()=>sd,loadTranslations:()=>$c,polyglotPlugin:()=>Ns,setLang:()=>Mc,translate:()=>Ic,upsertTranslation:()=>Fc});D();var SE="smbls_lang",cL="smbls_t_",lL="smbls_tv_",Fs={get(t){try{return window?.localStorage.getItem(t)}catch{return null}},set(t,e){try{window?.localStorage.setItem(t,e)}catch(r){console.warn("[polyglot] localStorage unavailable:",r.message)}},remove(t){try{window?.localStorage.removeItem(t)}catch(e){console.warn("[polyglot] localStorage unavailable:",e.message)}}},Dc={};function ln(){let t=this?.context,e=t?.polyglot;return(this?.state?.root||t?.state?.root)?.lang||t?.state?.lang||e?.defaultLang||"en"}function Lc(){let t=this?.context?.polyglot;return t?t.languages?t.languages:t.translations?Object.keys(t.translations):[]:[]}var od=(t,e)=>{if(!t||!e)return;if(t[e]!==void 0)return t[e];if(e.indexOf(".")===-1)return;let r=e.split("."),n=t;for(let o=0;o<r.length;o++){if(n==null)return;n=n[r[o]]}return n},wE=(t,e,r)=>{let n=e.lastIndexOf(".");if(n===-1)return t[e+"_"+r];let o=od(t,e.substring(0,n));if(o!=null)return o[e.substring(n+1)+"_"+r]};function Ic(t,e){if(!t)return"";let r=this?.context,n=r?.polyglot,o=e||this.call("getActiveLang"),s=this?.state;if(s){let l=wE(s,t,o);if(l!==void 0)return l}if(n?.translations){let l=n.translations[o];if(l){let f=od(l,t);if(f!==void 0)return f}}let a=(s?.root||r?.state?.root)?.translations;if(a){let l=a[o];if(l){let f=od(l,t);if(f!==void 0)return f}}let c=n?.defaultLang||"en";if(s){let l=wE(s,t,c);if(l!==void 0)return l}if(n?.translations){let l=n.translations[c];if(l){let f=od(l,t);if(f!==void 0)return f}}return t}async function $c(t){let e=this?.context,r=e?.polyglot,n=this?.state?.root||e?.state?.root;if(!r||!n)return;let o=r.storagePrefix||cL,s=r.storageVersionPrefix||(r.storagePrefix?r.storagePrefix.replace(/_$/,"v_"):lL);if(r.translations&&r.translations[t]&&!r.fetch||!r.fetch||r._fetchFailed?.[t])return;if(!n.translations?.[t]){let c=Fs.get(o+t);if(c)try{let l=JSON.parse(c),f={translations:{...n.translations||{}}};f.translations[t]=l,n.update&&n.update(f)}catch(l){console.warn("[polyglot] Failed to apply language update:",l.message)}}let i=(r.storagePrefix||"smbls")+":"+t;if(Dc[i])return Dc[i];let a=this;return Dc[i]=(async()=>{try{let c=r.fetch,l=parseInt(Fs.get(s+t),10)||0,f,u,d;if(R(c)){let p=await c(t,l,a);if(!p||p.changed===!1)return;f=p.translations||p.data||p,u=p.version||0,d=!0}else if(v(c)){let p=a.getDB||(()=>e.fetch),h=R(p)?await p.call(a):e.fetch;if(!h)return;let m=c.rpc||c.from||"get_translations_if_changed",y={p_lang:t,p_cached_version:l,...c.params||{}},x=await h.rpc({from:m,params:y});if(x.error)throw r._fetchFailed||(r._fetchFailed={}),r._fetchFailed[t]=!0,x.error;let b=x.data;if(!b||!b.changed)return;f=b.translations||{},u=b.version||0,d=!0}else return;if(!d||!f)return;Fs.set(o+t,JSON.stringify(f)),u&&Fs.set(s+t,String(u));let g={translations:{...n.translations||{}}};g.translations[t]=f,n.update&&n.update(g)}catch(c){if(r.verbose!==!1){let l=c?.message||c?.details||(typeof c=="object"?JSON.stringify(c):String(c));console.warn("[polyglot] Failed to load translations for",t,"-",l)}}finally{delete Dc[i]}})(),Dc[i]}var fL=(t,e,r)=>{let n=t.__ref;if(!n||n.contentManaged||r==null||typeof r=="object")return;let o=n.__textNode;if(!o||o.parentNode!==e)return;let s=String(r);o.nodeValue!==s&&(o.nodeValue=s)};async function Mc(t,e){let r=this?.context,n=r?.polyglot,o=this?.state?.root||r?.state?.root,s=r?.document||globalThis.document;if(!o)return;if(e?.persist!==!1){let l=n?.storageLangKey||SE;Fs.set(l,t)}if(s?.documentElement&&(s.documentElement.lang=t),this.call("getActiveLang")===t)return;n?.fetch&&await this.call("loadTranslations",t),r?.state&&(r.state.lang=t);let i=n?.translations?.[t],a={lang:t},c=l=>Hi(r,l,o);if(i&&typeof i=="object")for(let l in i){if(!c(l))continue;let f=i[l];(Array.isArray(f)||typeof f=="string"||typeof f=="number")&&(a[l]=f)}o.update&&o.update(a);for(let l in a)l!=="lang"&&Je(r,l,a[l]);if(i&&typeof i=="object")for(let l in i){if(!c(l))continue;let f=i[l];if(f&&typeof f=="object"&&!Array.isArray(f)&&o[l]&&typeof o[l]=="object"&&!Array.isArray(o[l])){for(let u in f)o[l][u]=f[u];Je(r,l,o[l])}}if(s&&i){let l=s.querySelectorAll("[data-key]");for(let f of l){let u=f.ref;if(!u)continue;let d=u.__ref?.__exec?.text;if(typeof d=="string"&&d.includes("{{"))try{fL(u,f,u.call("replaceLiteralsWithObjectFields",d,u.state))}catch{}}}}async function Fc(t,e,r){let n=this?.context,o=n?.polyglot,s=this?.state?.root||n?.state?.root;if(s?.translations?.[e]&&(s.translations[e][t]=r),o?.translations?.[e]&&(o.translations[e][t]=r),o?.fetch&&v(o.fetch)){let i=this.getDB||(()=>n.fetch),a=R(i)?await i.call(this):n.fetch;if(!a)return;let c=o.fetch.table||"translations",l=await a.upsert({from:c,data:{key:t,lang:e,text:r}});if(l?.error)throw l.error;return l.data}}async function sd(){let t=this?.context,e=t?.polyglot;if(!e)return;let r=this?.state?.root||t?.state?.root;if(!r)return;let n=e.storageLangKey||SE,s=Fs.get(n)||ln.call(this),i=t?.document||globalThis.document;i?.documentElement&&(i.documentElement.lang=s),r.update&&r.lang!==s&&r.update({lang:s}),e.fetch&&!(e.translations&&e.translations[s])&&await this.call("loadTranslations",s)}function Nc(t){try{let e=ln.call(this),r=this?.state;if(!r)return"";let n=t.lastIndexOf(".");if(n===-1)return r[t+e]??"";let o=t.substring(0,n).split("."),s=r;for(let i=0;i<o.length;i++){if(s==null)return"";s=s[o[i]]}return s==null?"":s[t.substring(n+1)+e]??""}catch{return""}}var Ns={name:"polyglot",render(t){t.parent&&t.parent.parent||t.__polyglotInitialized||(t.__polyglotInitialized=!0,sd.call(t))}},uL=Ns;Qi();var v_={};$(v_,{SYSTEM_METRICS:()=>jc,capsizeHandler:()=>k_,capsizePlugin:()=>ad,computeCapsize:()=>kE,default:()=>dL,resolveFontSizePx:()=>vE,resolveMetrics:()=>CE});var jc={arial:{capHeight:716,ascent:1854,descent:-434,lineGap:67,unitsPerEm:2048},helvetica:{capHeight:714,ascent:770,descent:-230,lineGap:0,unitsPerEm:1e3},"helvetica neue":{capHeight:714,ascent:952,descent:-213,lineGap:28,unitsPerEm:1e3},georgia:{capHeight:1419,ascent:1878,descent:-449,lineGap:0,unitsPerEm:2048},"times new roman":{capHeight:1356,ascent:1825,descent:-443,lineGap:87,unitsPerEm:2048},"courier new":{capHeight:1170,ascent:1705,descent:-615,lineGap:0,unitsPerEm:2048},verdana:{capHeight:1489,ascent:2059,descent:-430,lineGap:0,unitsPerEm:2048},roboto:{capHeight:1456,ascent:1900,descent:-500,lineGap:0,unitsPerEm:2048},"open sans":{capHeight:1462,ascent:2189,descent:-600,lineGap:0,unitsPerEm:2048},inter:{capHeight:1490,ascent:2048,descent:-512,lineGap:0,unitsPerEm:2048},lato:{capHeight:1434,ascent:1974,descent:-426,lineGap:0,unitsPerEm:2e3},"source sans":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},"source sans pro":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},"source sans 3":{capHeight:660,ascent:984,descent:-273,lineGap:0,unitsPerEm:1e3},montserrat:{capHeight:700,ascent:968,descent:-251,lineGap:0,unitsPerEm:1e3},poppins:{capHeight:700,ascent:1050,descent:-350,lineGap:100,unitsPerEm:1e3},raleway:{capHeight:710,ascent:1e3,descent:-250,lineGap:0,unitsPerEm:1e3},"dm sans":{capHeight:700,ascent:992,descent:-312,lineGap:0,unitsPerEm:1e3},nunito:{capHeight:705,ascent:1011,descent:-353,lineGap:0,unitsPerEm:1e3},"work sans":{capHeight:684,ascent:930,descent:-243,lineGap:0,unitsPerEm:1e3},manrope:{capHeight:708,ascent:980,descent:-300,lineGap:0,unitsPerEm:1e3},"ibm plex sans":{capHeight:698,ascent:1025,descent:-275,lineGap:0,unitsPerEm:1e3},"plus jakarta sans":{capHeight:720,ascent:1060,descent:-300,lineGap:0,unitsPerEm:1e3}},id=t=>parseFloat(t.toFixed(4)),kE=(t,e,r)=>{let{ascent:n,descent:o,lineGap:s,unitsPerEm:i,capHeight:a}=e,c=Math.abs(o),l=n+c+s,f=r!==void 0?r:l/i*t,u=f/t,d=l/i,g=(n-a+s/2)/i-(u-d)/2,p=(c+s/2)/i-(u-d)/2;return{fontSize:`${id(t/16)}rem`,lineHeight:`${id(f)}px`,capHeightTrim:`${id(-g)}em`,baselineTrim:`${id(-p)}em`}},vE=(t,e)=>{if(typeof t=="number")return t;let r=e?.designSystem;if(!r)return null;let{typography:n}=r;if(n?.sequence){let s=String(t).toUpperCase(),i=n.sequence[s];if(i)return i.decimal||i.val}let o=parseFloat(t);return isNaN(o)?null:typeof t=="string"&&t.endsWith("rem")?o*(r.typography?.browserDefault||16):o},CE=(t,e)=>{let n=e?.designSystem?.font_family||{};if(t){let s=n[t];if(s?.metrics)return s.metrics;let i=String(t).toLowerCase().replace(/['"]/g,"").trim();if(jc[i])return jc[i]}let o=n.default||Object.keys(n)[0];if(o){let s=n[o];if(s?.metrics)return s.metrics;if(s?.value&&Array.isArray(s.value))for(let i of s.value){let a=i.toLowerCase().replace(/['"]/g,"").trim();if(jc[a])return jc[a]}}return null},k_=(t,e,r,n)=>{if(!t)return;let o=vE(e.fontSize,n);if(!o)return;let s=CE(e.fontFamily,n);if(!s)return;let i=e.lineHeight?parseFloat(e.lineHeight):void 0,{lineHeight:a,capHeightTrim:c,baselineTrim:l}=kE(o,s,i),f={};return e.lineHeight||(f.lineHeight=a),f["::before"]={content:'""',marginBottom:c,display:"table"},f["::after"]={content:'""',marginTop:l,display:"table"},f},ad={name:"capsize",init(t){t.useCapsize===void 0&&t.fontSize&&(t.useCapsize=!0)}},dL=ad;var P_={};$(P_,{PRESERVE_VALUE_KEYS:()=>Vt,SKIP_INLINE_KEYS:()=>fn,abbrToProp:()=>Bt,decode:()=>RE,encode:()=>AE,expand:()=>io,isComponentKey:()=>Ue,isSelectorKey:()=>ze,parse:()=>ao,parseFurther:()=>lo,propToAbbr:()=>Re,shorten:()=>Bc,shorthandPlugin:()=>Vc,stringify:()=>so,stringifyFurther:()=>co});var Re={attr:"at",childExtends:"cex",childExtendsRecursive:"cexr",childProps:"cp",children:"ch",childrenAs:"cha",class:"cl",content:"cnt",context:"ctx",data:"dt",extends:"ext",hide:"hd",html:"htm",if:"if",ignoreChildExtends:"icex",key:"ky",query:"qy",routes:"rt",scope:"scp",show:"shw",state:"st",style:"sy",tag:"tg",text:"tx",align:"aln",boxSize:"bsz",flow:"fl",heightRange:"hr",horizontalInset:"hi",round:"rnd",shadow:"shd",size:"sz",templateColumns:"tcol",verticalInset:"vi",widthRange:"wr",wrap:"wrp",aspectRatio:"ar",blockSize:"bks",boxSizing:"bxs",height:"h",inlineSize:"ins",margin:"m",marginBottom:"mb",marginLeft:"ml",marginRight:"mr",marginTop:"mt",maxBlockSize:"mxbs",maxHeight:"mxh",maxInlineSize:"mxis",maxWidth:"mxw",minBlockSize:"mnbs",minHeight:"mnh",minInlineSize:"mnis",minWidth:"mnw",padding:"p",paddingBottom:"pb",paddingInline:"pil",paddingLeft:"pl",paddingRight:"pr",paddingTop:"pt",width:"w",alignContent:"ac",alignItems:"ai",alignSelf:"as",flex:"fx",flexBasis:"fxb",flexDirection:"fxd",flexFlow:"fxf",flexGrow:"fxg",flexShrink:"fxs",flexWrap:"fxw",gap:"g",justifyContent:"jc",justifyItems:"ji",justifySelf:"js",order:"od",placeContent:"pcn",placeItems:"pit",placeSelf:"psl",rowGap:"rg",columnGap:"cg",gridArea:"ga",gridAutoColumns:"gac",gridAutoFlow:"gaf",gridAutoRows:"gar",gridColumn:"gc",gridColumnEnd:"gce",gridColumnStart:"gcs",gridRow:"gr",gridRowEnd:"gre",gridRowStart:"grs",gridTemplateAreas:"gta",gridTemplateColumns:"gtc",gridTemplateRows:"gtr",bottom:"bot",float:"flt",inset:"ist",left:"lft",position:"pos",right:"rgt",top:"tp",zIndex:"zi",clear:"clr",contain:"ctn",cursor:"cur",display:"d",opacity:"op",overflow:"ov",overflowX:"ovx",overflowY:"ovy",pointerEvents:"pe",resize:"rsz",userSelect:"us",visibility:"vis",background:"bg",backgroundAttachment:"bga",backgroundBlendMode:"bgbm",backgroundClip:"bgcl",backgroundColor:"bgc",backgroundImage:"bgi",backgroundOrigin:"bgo",backgroundPosition:"bgp",backgroundPositionX:"bgpx",backgroundPositionY:"bgpy",backgroundRepeat:"bgr",backgroundRepeatX:"bgrx",backgroundRepeatY:"bgry",backgroundSize:"bgs",color:"c",theme:"thm",themeModifier:"thmm",border:"bd",borderBottom:"bdb",borderBottomLeftRadius:"bdblr",borderBottomRightRadius:"bdbrr",borderCollapse:"bdcl",borderColor:"bdc",borderImage:"bdi",borderImageOutset:"bdio",borderImageRepeat:"bdir",borderImageSlice:"bdis",borderImageSource:"bdisrc",borderImageWidth:"bdiw",borderLeft:"bdl",borderRadius:"bdr",borderRight:"bdrg",borderSpacing:"bdsp",borderStyle:"bdst",borderTop:"bdt",borderTopLeftRadius:"bdtlr",borderTopRightRadius:"bdtrr",borderWidth:"bdw",outline:"ol",outlineColor:"olc",outlineOffset:"olo",outlineStyle:"ols",outlineWidth:"olw",boxShadow:"bxsh",textShadow:"txsh",direction:"dir",fontDisplay:"fdi",fontFamily:"ff",fontFeatureSettings:"ffs",fontKerning:"fk",fontOpticalSizing:"fos",fontPalette:"fpl",fontSize:"fs",fontSizeAdjust:"fsa",fontSmooth:"fsm",fontStretch:"fsr",fontStyle:"fsy",fontSynthesis:"fsyn",fontVariant:"fv",fontVariationSettings:"fvs",fontWeight:"fw",hyphens:"hyp",letterSpacing:"ls",lineHeight:"lh",tabSize:"tsz",textAlign:"ta",textDecoration:"td",textDecorationColor:"tdc",textDecorationLine:"tdl",textDecorationStyle:"tds",textIndent:"ti",textOverflow:"tov",textStroke:"tsk",textTransform:"tt",unicodeBidi:"ub",verticalAlign:"va",whiteSpace:"ws",wordBreak:"wbr",wordSpacing:"wsp",wordWrap:"wwr",writingMode:"wm",captionSide:"cps",counterIncrement:"ci",counterReset:"cr",emptyCells:"ec",listStyle:"lst",listStyleImage:"lsi",listStylePosition:"lsp",listStyleType:"lsty",quotes:"qt",tableLayout:"tl",columnCount:"cc",columnFill:"cf",columnRule:"crl",columnRuleColor:"crlc",columnRuleStyle:"crls",columnRuleWidth:"crlw",columnSpan:"cspn",columnWidth:"cwi",columns:"col",backdropFilter:"bdf",boxDecorationBreak:"bxdb",clipPath:"cpth",filter:"fil",isolation:"iso",mixBlendMode:"mbm",objectFit:"obf",objectPosition:"obp",perspective:"prs",perspectiveOrigin:"prso",willChange:"wc",transform:"tf",transformOrigin:"tfo",transformStyle:"tfs",transition:"trn",transitionDelay:"trnd",transitionDuration:"trndr",transitionProperty:"trnp",transitionTimingFunction:"trntf",animation:"an",animationDelay:"and",animationDirection:"andr",animationDuration:"andur",animationFillMode:"anfm",animationIterationCount:"anic",animationName:"ann",animationPlayState:"anps",animationTimingFunction:"antf",scrollBehavior:"sb",scrollMargin:"smr",scrollMarginBottom:"smrb",scrollMarginLeft:"smrl",scrollMarginRight:"smrr",scrollMarginTop:"smrt",scrollPadding:"spd",scrollPaddingBottom:"spdb",scrollPaddingLeft:"spdl",scrollPaddingRight:"spdr",scrollPaddingTop:"spdt",scrollSnapAlign:"ssa",scrollSnapStop:"sss",scrollSnapType:"sst",breakAfter:"bka",breakBefore:"bkb",breakInside:"bki",pageBreakAfter:"pbka",pageBreakBefore:"pbkb",pageBreakInside:"pbki",accessKey:"ack",className:"cn",contentEditable:"ced",contextMenu:"cmu",draggable:"drg",hidden:"hid",id:"id",is:"is",lang:"lng",nonce:"nnc",spellCheck:"spc",tabIndex:"tbi",title:"ttl",translate:"trl",accept:"acp",acceptCharset:"accs",action:"act",autoComplete:"atc",autoFocus:"atf",capture:"cap",challenge:"chg",checked:"chk",cols:"cls",colSpan:"csn",controls:"ctl",default:"def",defer:"dfr",disabled:"dis",encType:"ect",form:"frm",formAction:"fac",formEncType:"fect",formMethod:"fme",formNoValidate:"fnv",formTarget:"ftg",high:"hgh",inputMode:"imd",kind:"knd",label:"lbl",list:"lis",loop:"lp",low:"lw",max:"mx",maxLength:"mxl",method:"mtd",min:"mn",minLength:"mnl",multiple:"mul",muted:"mut",name:"nm",open:"opn",optimum:"opt",pattern:"ptn",placeholder:"phd",readOnly:"ro",required:"req",reversed:"rev",rows:"rws",rowSpan:"rsn",selected:"sel",span:"spn",start:"srt",step:"stp",type:"typ",value:"val",download:"dl",href:"hrf",hrefLang:"hrl",ping:"png",referrerPolicy:"rfp",rel:"rl",target:"tgt",allow:"alw",allowFullScreen:"afs",allowPaymentRequest:"apr",alt:"alt",cellPadding:"cpg",cellSpacing:"csg",cite:"cit",coords:"crd",crossOrigin:"cor",dateTime:"dtm",fetchPriority:"fpr",headers:"hds",httpEquiv:"hte",integrity:"itg",isMap:"ism",keyType:"kty",loading:"ldg",manifest:"mft",media:"mda",poster:"pst",preload:"prl",radioGroup:"rdg",sandbox:"sbx",scoped:"scod",seamless:"sml",shape:"shp",sizes:"szs",src:"src",srcDoc:"srd",srcLang:"srl",srcSet:"srs",useMap:"ump",ariaActiveDescendant:"aad",ariaAtomic:"aat",ariaBusy:"abu",ariaChecked:"achk",ariaControls:"acl",ariaCurrent:"acr",ariaDescribedBy:"adb",ariaDetails:"adt",ariaDisabled:"adis",ariaDropEffect:"ade",ariaErrorMessage:"aem",ariaExpanded:"aexp",ariaGrabbed:"agr",ariaHasPopup:"ahp",ariaHidden:"ahid",ariaInvalid:"ainv",ariaLabel:"alb",ariaLabelledBy:"alby",ariaLive:"alv",ariaModal:"amod",ariaMultiSelectable:"ams",ariaOrientation:"aor",ariaOwns:"aow",ariaPosInSet:"apis",ariaPressed:"aprs",ariaReadOnly:"aro",ariaRelevant:"arl",ariaRequired:"areq",ariaSelected:"asel",ariaSetSize:"assz",ariaValueMax:"avmx",ariaValueMin:"avmn",ariaValueNow:"avn",role:"role",onInit:"@in",onRender:"@rn",onUpdate:"@up",onStateChange:"@sc",onStateUpdate:"@su",onClick:"@ck",onContextMenu:"@cm",onDblClick:"@dc",onMouseDown:"@md",onMouseEnter:"@me",onMouseLeave:"@ml",onMouseMove:"@mm",onMouseOut:"@mo",onMouseOver:"@mv",onMouseUp:"@mu",onKeyDown:"@kd",onKeyPress:"@kp",onKeyUp:"@ku",onBlur:"@bl",onFocus:"@fc",onFocusIn:"@fi",onFocusOut:"@fo",onBeforeInput:"@bi",onChange:"@cg",onFormData:"@fd",onInput:"@ip",onInvalid:"@iv",onReset:"@rs",onSearch:"@sr",onSelect:"@sl",onSubmit:"@sm",onTouchCancel:"@tc",onTouchEnd:"@te",onTouchMove:"@tm",onTouchStart:"@ts",onPointerCancel:"@pc",onPointerDown:"@pd",onPointerEnter:"@pe",onPointerLeave:"@ple",onPointerMove:"@pm",onPointerOut:"@po",onPointerOver:"@pov",onPointerUp:"@pu",onDrag:"@dg",onDragEnd:"@dge",onDragEnter:"@dgn",onDragLeave:"@dgl",onDragOver:"@dgo",onDragStart:"@dgs",onDrop:"@dp",onResize:"@rz",onScroll:"@scl",onWheel:"@wh",onCopy:"@cy",onCut:"@ct",onPaste:"@pt",onCompositionEnd:"@cpe",onCompositionStart:"@cps",onCompositionUpdate:"@cpu",onAnimationEnd:"@ae",onAnimationIteration:"@ai",onAnimationStart:"@as",onTransitionEnd:"@tre",onTransitionStart:"@trs",onAbort:"@ab",onCanPlay:"@cap",onCanPlayThrough:"@cpt",onDurationChange:"@duc",onEmptied:"@em",onEncrypted:"@enc",onEnded:"@end",onError:"@er",onLoad:"@ld",onLoadedData:"@ldd",onLoadedMetadata:"@ldm",onPause:"@pa",onPlay:"@pl",onPlaying:"@plg",onProgress:"@prg",onRateChange:"@rc",onSeeked:"@sk",onSeeking:"@skg",onStalled:"@stl",onSuspend:"@ssp",onTimeUpdate:"@tu",onVolumeChange:"@vc",onWaiting:"@wt",icon:"ico",iconText:"ict",lookup:"lkp",router:"rtr",shapeModifier:"shpm"},Bt=Object.create(null);for(let t in Re)Bt[Re[t]]=t;var C_=Object.create(null);for(let t in Re){let e=Re[t];if(C_[e])throw new Error(`Duplicate abbreviation "${e}" for "${t}" \u2014 already used by "${C_[e]}"`);C_[e]=t}var Vt=new Set(["state","st","scope","scp","attr","at","style","sy","data","dt","context","ctx","query","qy","class","cl"]),fn=new Set(["text","tx","html","htm","content","cnt","placeholder","phd","src","href","hrf"]);function Ue(t){return/^[A-Z]/.test(t)}function ze(t){return/^[:@.!$>&]/.test(t)||t.startsWith("> ")}function AE(t){if(!t||typeof t!="object")return"";let e=[];for(let r in t){let n=t[r];if(typeof n=="function"||n!==null&&typeof n=="object"&&!Array.isArray(n)||n===void 0)continue;let o=Re[r]||r;if(n===!0)e.push(o);else if(n===!1)e.push("!"+o);else if(Array.isArray(n)){let s=n.map(i=>cd(i));e.push(o+":"+s.join(","))}else e.push(o+":"+cd(n))}return e.join(" ")}function cd(t){return String(t).replace(/ /g,"_")}function Bc(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?Bc(r):r});let e={};for(let r in t){let n=t[r];if(Ue(r)){e[r]=E_(n);continue}if(ze(r)){e[r]=E_(n);continue}let o=Re[r]||r;if(Vt.has(r)||Vt.has(o)){e[o]=n;continue}e[o]=E_(n)}return e}function E_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?Bc(e):e}):typeof t=="object"?Bc(t):t}function so(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(n){return n!==null&&typeof n=="object"?so(n):n});let e={},r=[];for(let n in t){let o=t[n];if(Ue(n)){e[n]=EE(o);continue}if(ze(n)){e[n]=EE(o);continue}let s=Re[n]||n;if(Vt.has(n)||Vt.has(s)){e[s]=o;continue}if(typeof o=="function"){e[s]=o;continue}if(o==null){e[s]=o;continue}if(fn.has(n)||fn.has(s)){e[s]=o;continue}if(Array.isArray(o)){if(o.some(function(a){return a!==null&&typeof a=="object"})){e[s]=o.map(function(a){return a!==null&&typeof a=="object"?so(a):a});continue}if(o.length<=1){e[s]=o;continue}r.push(s+":"+o.map(cd).join(","));continue}if(typeof o=="object"){e[s]=so(o);continue}o===!0?r.push(s):o===!1?r.push("!"+s):typeof o=="number"||typeof o=="string"&&(o.includes(",")||o.includes("_"))?e[s]=o:r.push(s+":"+cd(o))}return r.length&&(e.in=r.join(" ")),e}function EE(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?so(e):e}):typeof t=="object"?so(t):t}function RE(t){if(!t||typeof t!="string")return{};let e={},r=PE(t);for(let n of r){if(n.startsWith("!")){let c=n.slice(1),l=Bt[c]||c;e[l]=!1;continue}let o=n.indexOf(":");if(o===-1){let c=Bt[n]||n;e[c]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s;if(i.includes(",")){e[a]=i.split(",").map(TE);continue}e[a]=TE(i)}return e}function PE(t){return t.trim().split(/\s+/).filter(Boolean)}function TE(t){let e=t.replace(/_/g," ");return/^-?\d+(\.\d+)?$/.test(e)?Number(e):e}function OE(t){return t.replace(/_/g," ")}function pL(t){if(!t||typeof t!="string")return{};let e={},r=PE(t);for(let n of r){if(n.startsWith("!")){let c=n.slice(1),l=Bt[c]||c;e[l]=!1;continue}let o=n.indexOf(":");if(o===-1){let c=Bt[n]||n;e[c]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s;if(i.includes(",")){e[a]=i.split(",").map(OE);continue}e[a]=OE(i)}return e}function io(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?io(r):r});let e={};for(let r in t){let n=t[r];if(Ue(r)){e[r]=A_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){e[r]=A_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=A_(n)}return e}function A_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?io(e):e}):typeof t=="object"?io(t):t}function ao(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?ao(r):r});let e={};if(typeof t.in=="string"){let r=pL(t.in);for(let n in r)e[n]=r[n]}for(let r in t){if(r==="in")continue;let n=t[r];if(Ue(r)){e[r]=T_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){e[r]=T_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=T_(n)}return e}function T_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?ao(e):e}):typeof t=="object"?ao(t):t}function DE(t){return String(t).replace(/\\/g,"\\\\").replace(/_/g,"\\_").replace(/,/g,"\\,").replace(/ /g,"_")}function hL(t){let e="",r=0;for(;r<t.length;){if(t[r]==="\\"&&r+1<t.length){let n=t[r+1];if(n===","||n==="_"||n==="\\"){e+=n,r+=2;continue}}t[r]==="_"?e+=" ":e+=t[r],r++}return e}function gL(t){let e=[],r="",n=0;for(;n<t.length;){if(t[n]==="\\"&&n+1<t.length){r+=t[n]+t[n+1],n+=2;continue}if(t[n]===","){e.push(r),r="",n++;continue}r+=t[n],n++}return e.push(r),e}function LE(t){if(t==null||typeof t!="object"||Array.isArray(t))return!1;let e=Object.keys(t);return e.length===1&&e[0]==="in"&&typeof t.in=="string"}function co(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(n){return n!==null&&typeof n=="object"?co(n):n});let e={},r=[];for(let n in t){let o=t[n];if(Ue(n)){let i=IE(o);e[n]=LE(i)?i.in:i;continue}if(ze(n)){let i=IE(o);e[n]=LE(i)?i.in:i;continue}let s=Re[n]||n;if(Vt.has(n)||Vt.has(s)){e[s]=o;continue}if(typeof o=="function"){e[s]=o;continue}if(o==null){e[s]=o;continue}if(fn.has(n)||fn.has(s)){e[s]=o;continue}if(Array.isArray(o)){if(o.some(function(a){return a!==null&&typeof a=="object"})){e[s]=o.map(function(a){return a!==null&&typeof a=="object"?co(a):a});continue}if(o.length<=1){e[s]=o;continue}r.push(s+":"+o.map(DE).join(","));continue}if(typeof o=="object"){e[s]=co(o);continue}if(o===!0){r.push(s);continue}if(o===!1){r.push("!"+s);continue}if(typeof o=="number"){r.push(s+":#"+o);continue}r.push(s+":"+DE(o))}return r.length&&(e.in=r.join(" ")),e}function IE(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?co(e):e}):typeof t=="object"?co(t):t}function $E(t){return t.startsWith("#")&&/^#-?\d+(\.\d+)?$/.test(t)?Number(t.slice(1)):hL(t)}function O_(t){if(!t||typeof t!="string")return{};let e={},r=t.trim().split(/\s+/).filter(Boolean);for(let n of r){if(n.startsWith("!")){let l=n.slice(1),f=Bt[l]||l;e[f]=!1;continue}let o=n.indexOf(":");if(o===-1){let l=Bt[n]||n;e[l]=!0;continue}let s=n.slice(0,o),i=n.slice(o+1),a=Bt[s]||s,c=gL(i);if(c.length>1){e[a]=c.map($E);continue}e[a]=$E(i)}return e}function lo(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(function(r){return r!==null&&typeof r=="object"?lo(r):r});let e={};if(typeof t.in=="string"){let r=O_(t.in);for(let n in r)e[n]=r[n]}for(let r in t){if(r==="in")continue;let n=t[r];if(Ue(r)){typeof n=="string"?e[r]=O_(n):e[r]=R_(n);continue}let o=Bt[r]||r;if(ze(r)&&o===r){typeof n=="string"?e[r]=O_(n):e[r]=R_(n);continue}if(Vt.has(o)||Vt.has(r)){e[o]=n;continue}e[o]=R_(n)}return e}function R_(t){return t==null||typeof t=="function"?t:Array.isArray(t)?t.map(function(e){return e!==null&&typeof e=="object"?lo(e):e}):typeof t=="object"?lo(t):t}var mL={shorten:io,stringify:ao,stringifyFurther:lo};function yL(t,e){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(n=>e(n));let r={};for(let n in t){let o=t[n];r[n]=o&&typeof o=="object"?e(o):o}return r}var bL=["components","pages","snippets"],Vc={name:"shorthand",prepareContext(t){let e=t.shorthand;if(!e)return;let n=mL[e===!0?"shorten":e];if(n){for(let o of bL)t[o]&&(t[o]=yL(t[o],n));t.app&&typeof t.app=="object"&&(t.app=n(t.app))}}};var z_={};$(z_,{LEVELS:()=>Uc,analyzePlugin:()=>Bs,attachBrowserListeners:()=>yd,attachNetworkListeners:()=>Hc,classifyEvent:()=>N_,createAnalyzeState:()=>bd,createBeaconSink:()=>V_,createConsoleSink:()=>j_,createDedupe:()=>$_,createEnrich:()=>L_,createMemorySink:()=>B_,createPipeline:()=>dd,createRedact:()=>ud,createRemoteSink:()=>hd,createSample:()=>M_,createSummarize:()=>I_,default:()=>Bs,emitFetchEvent:()=>zE,makeEvent:()=>tt,meetsLevel:()=>ld,normalizeLevel:()=>zc,resolveSinks:()=>md,summarizeElement:()=>fo});var _L=0,xL=()=>`${Date.now().toString(36)}-${(_L++).toString(36)}`,tt=(t,e,r={})=>({id:xL(),ts:Date.now(),type:t,level:e,...r}),wL=t=>{let e=[],r=t,n=0;for(;r&&n<32;)r.key!=null&&e.unshift(String(r.key)),r=r.parent,n++;return e.join(" > ")},fo=t=>t?{key:t.key!=null?String(t.key):null,name:t.__name||t.name||null,path:wL(t),tag:t.tag||null,component:t.component||null,route:t.context?.routerOptions?.currentRoute||null}:null;var js=t=>t?.context?.analyze,SL={init:{category:"lifecycle",type:"lifecycle",level:"debug"},create:{category:"lifecycle",type:"lifecycle",level:"debug"},render:{category:"lifecycle",type:"lifecycle",level:"debug"},beforeRemove:{category:"lifecycle",type:"lifecycle",level:"debug"},remove:{category:"lifecycle",type:"lifecycle",level:"debug"}},kL=(t,{category:e,type:r,level:n})=>o=>{let s=js(o);!s||!s.shouldCapture(e)||s.emit(tt(r,n,{hook:t,element:fo(o)}))},ME=t=>(e,r)=>{let n=js(e);!n||!n.shouldCapture("state")||n.emit(tt("state","debug",{hook:t,element:fo(e),changedKeys:r?.changedKeys||null}))},Bs={name:"analyze",error(t,e){let r=js(t);if(!r||r.config.enabled===!1||!r.shouldCapture("errors"))return;let n=e?.error||e?.err||(e instanceof Error?e:null);r.emit(tt("error","error",{hook:e?.hook||"error",element:fo(t),error:n,message:n?.message||(typeof e?.message=="string"?e.message:null)}))},renderRouter(t){let e=js(t);e&&(!e.shouldCapture("navigation")&&!e.shouldCapture("lifecycle")||e.emit(tt("navigation","info",{hook:"renderRouter",route:t.context?.routerOptions?.currentRoute||null})))},beforeUpdate(t){let e=js(t);!e||!e.shouldCapture("updates")||t.__ref&&(t.__ref.__analyzeUpdateStart=typeof performance<"u"?performance.now():Date.now())},update(t){let e=js(t);if(!e||!e.shouldCapture("updates"))return;let r=null;t.__ref?.__analyzeUpdateStart!=null&&(r=(typeof performance<"u"?performance.now():Date.now())-t.__ref.__analyzeUpdateStart,t.__ref.__analyzeUpdateStart=null),e.emit(tt("update","debug",{hook:"update",element:fo(t),durationMs:r}))},beforeStateUpdate:ME("beforeStateUpdate"),stateUpdate:ME("stateUpdate")};for(let[t,e]of Object.entries(SL))Bs[t]=kL(t,e);D();var Uc={error:0,warn:1,info:2,debug:3,trace:4};var ld=(t,e)=>{let r=Uc[t],n=Uc[e];return r==null||n==null?!0:r<=n},zc=t=>Uc[t]!=null?t:"warn";D();var fd=/password|token|secret|ssn|card|cvv|pin|apikey|api_key|auth|email|otp/i;var vL=(t,e)=>{for(let r of e)if(r instanceof RegExp){if(r.test(t))return!0}else if(typeof r=="string"&&t.toLowerCase().includes(r.toLowerCase()))return!0;return!1},CL=(t,e)=>{if(e!=="redact"){if(e==="hash"){let r=0,n=String(t);for(let o=0;o<n.length;o++)r=(r<<5)-r+n.charCodeAt(o)|0;return`#${(r>>>0).toString(36)}`}return"***"}},D_=(t,e,r,n)=>{if(n>6||t==null||typeof t!="object")return t;if(Array.isArray(t))return t.map(s=>D_(s,e,r,n+1));let o={};for(let s of Object.keys(t))if(vL(s,e)||fd.test(s)){let a=CL(t[s],r);a!==void 0&&(o[s]=a)}else o[s]=D_(t[s],e,r,n+1);return o},ud=(t=[],e="mask")=>{let r=Array.isArray(t)?t:[t];return n=>{if(!n)return n;let{id:o,ts:s,type:i,level:a,hook:c,error:l,message:f,durationMs:u,element:d,target:g,...p}=n,h=D_(p,r,e,0);return{id:o,ts:s,type:i,level:a,hook:c,error:l,message:f,durationMs:u,element:d,target:g,...h}}};var L_=t=>{let e=`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,8)}`,r=typeof navigator<"u"?navigator.userAgent:null,n=t.config.buildHash||null,o=t.config.appId||null;return s=>{if(!s)return s;let i=t.context?.routerOptions?.currentRoute||null,a=C,c=a&&a.innerWidth?{w:a.innerWidth,h:a.innerHeight}:null;return{...s,session:e,app:{id:o,build:n,route:i},meta:{ua:r,viewport:c}}}},I_=()=>t=>{if(!t)return t;if(t.element&&typeof t.element=="object"){let e=t.element;(e.node||e.parent||e.__ref)&&(t={...t,element:{key:e.key!=null?String(e.key):null,name:e.__name||e.name||null,tag:e.tag||null,component:e.component||null}})}return t.error instanceof Error&&(t={...t,error:{name:t.error.name,message:t.error.message,stack:t.error.stack}}),t},$_=(t=1e3,e=500)=>{let r=new Map;return n=>{if(!n)return n;let o=`${n.type}:${n.level}:${n.message||""}:${n.error?.message||""}`,s=r.get(o),i=n.ts||Date.now();if(s&&i-s<t)return null;if(r.set(o,i),r.size>e){let a=Math.ceil(e/10),c=0;for(let l of r.keys()){if(c++>=a)break;r.delete(l)}}return n}},M_=t=>e=>{if(!e)return e;let r=t[e.type];return r==null||r>=1?e:Math.random()>r?null:e},FE={redact:t=>ud(t.config.redact||[],t.config.maskStrategy),enrich:t=>L_(t),summarize:()=>I_(),dedupe:t=>$_(t.config.cache?.dedupeWindowMs||1e3),sample:t=>M_(t.config.sample||{})},EL=(t,e)=>{if(typeof t=="function")return t;if(typeof t=="string"){let r=FE[t];return r?r(e):null}return null},dd=t=>{let e=t.config,r=Array.isArray(e.transformers)?e.transformers.slice():[],n=r.findIndex(s=>s==="redact");n>=0&&r.splice(n,1);let o=[];e.redact!==!1&&o.push(FE.redact(t));for(let s of r){let i=EL(s,t);i&&o.push(i)}return s=>{let i=s;for(let a of o){if(i==null)return null;let c=a(i);if(c==null)return null;if(Array.isArray(c)){let l=o.slice(o.indexOf(a)+1),f=[];for(let u of c){let d=u,g=!1;for(let p of l)if(d=p(d),d==null){g=!0;break}!g&&d!=null&&f.push(d)}return f}i=c}return i}};D();D();var pd=typeof C<"u"&&typeof C.document<"u",AL=5e3,TL=50,OL=3,RL=1500,PL=1e3,N_=t=>t?t.level==="error"||t.type==="error"?"bug":t.type==="network"?"network":t.type==="console"?t.level==="error"||t.level==="warn"?"bug":"log":t.level==="warn"?"bug":t.level==="info"?"log":"verbose":"verbose",DL=t=>{try{return JSON.stringify(t)}catch{return null}},LL=()=>{try{return Intl.DateTimeFormat().resolvedOptions().timeZone||null}catch{return null}},IL=t=>{if(!t)return null;let e=String(t),r;return(r=e.match(/Edg\/([\d.]+)/))?{name:"Edge",version:r[1]}:(r=e.match(/OPR\/([\d.]+)/))?{name:"Opera",version:r[1]}:(r=e.match(/Firefox\/([\d.]+)/))?{name:"Firefox",version:r[1]}:/Chrome\/([\d.]+)/.test(e)&&/Safari\//.test(e)?(r=e.match(/Chrome\/([\d.]+)/),{name:"Chrome",version:r[1]}):(r=e.match(/Version\/([\d.]+).*Safari/))?{name:"Safari",version:r[1]}:{name:null,version:null}},$L=()=>{if(!pd)return null;try{let t=C.document?.documentElement?.getAttribute("data-theme")||null,e=typeof C.matchMedia=="function"?C.matchMedia("(prefers-color-scheme: dark)").matches:null;return{active:t||(e?"dark":e===!1?"light":null),forced:t||null,prefers:e==null?null:e?"dark":"light"}}catch{return null}},ML=()=>{if(!pd)return null;let t=C.location,e=typeof navigator<"u"?navigator:null,r=typeof screen<"u"?screen:null;return{url:t?.href||null,path:t?.pathname||null,referrer:C.document?.referrer||null,title:C.document?.title||null,ua:e?.userAgent||null,browser:IL(e?.userAgent),language:e?.language||null,languages:e?.languages||null,timezone:LL(),viewport:C.innerWidth?{w:C.innerWidth,h:C.innerHeight,dpr:C.devicePixelRatio||1}:null,screen:r?{w:r.width||null,h:r.height||null,availW:r.availWidth||null,availH:r.availHeight||null,colorDepth:r.colorDepth||null,orientation:r.orientation?.type||null}:null,theme:$L()}},hd=(t={})=>{let e=t.url,r=typeof t.transport=="function"?t.transport:null,n=typeof t.syncTransport=="function"?t.syncTransport:null;if(!e&&!r)return()=>{};let o=t.apiKey||null,s=t.appKey||t.appId||null,i=t.tenantKey||t.tenant||null,a=t.release||null,c=t.env||null,l=t.sdk||null,f=typeof t.getAuth=="function"?t.getAuth:null,u=typeof t.getContext=="function"?t.getContext:null,d=typeof t.classify=="function"?t.classify:N_,g=typeof t.beforeSend=="function"?t.beforeSend:null,p=t.debug===!0,h=typeof t.getDebug=="function"?t.getDebug:null,m=t.batchMs!=null?t.batchMs:AL,y=t.maxBatch||TL,x=t.maxRetries!=null?t.maxRetries:OL,b=t.backoffMs||RL,_=t.queueLimit||PL,w=t.sampleRate!=null?t.sampleRate:1,S=()=>typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`,E=t.sessionId||S(),O=[],L=[],T=null,M=null,U=()=>{T||!O.length||(T=setTimeout(F,m))},rt=G=>{if(M)return;let j=b*Math.pow(2,Math.max(0,G-1));M=setTimeout(()=>{if(M=null,!L.length)return;let nt=L.shift();mt(nt.envelope,nt.attempt)},j)},Rt=(G,j=!1)=>{let nt=u?F_(u):null,N={id:E,sentAt:Date.now()};j&&(N.endedAt=Date.now());let J={v:1,session:N,app:{key:s,release:a,env:c},tenant:i,sdk:l,page:ML(),user:nt?.user||null,traits:nt?.traits||null,tags:nt?.tags||null,events:G};if((h?F_(h)===!0:p)&&(J.app.debug=!0),g)try{return g(J)||null}catch{return J}return J},mt=async(G,j=1)=>{if(G)try{let nt=!0;if(r){let N=await r(G);nt=N!==!1&&N?.ok!==!1}else nt=await FL(e,G,{apiKey:o,getAuth:f});!nt&&j<x&&(L.push({envelope:G,attempt:j+1}),rt(j+1))}catch{j<x&&(L.push({envelope:G,attempt:j+1}),rt(j+1))}},F=(G=!1,j=!1)=>{if(T&&(clearTimeout(T),T=null),!O.length&&!j)return;let nt=O;O=[];let N=Rt(nt,j);if(N){if(G&&pd){if(typeof n=="function"&&F_(()=>n(N)))return;if(navigator.sendBeacon&&e){let J=DL(N);if(J)try{navigator.sendBeacon(e,new C.Blob([J],{type:"application/json"}));return}catch{}}}mt(N)}},W=!1,yt=()=>{W||(W=!0,F(!0,!0))};pd&&(C.addEventListener("pagehide",yt,{passive:!0}),C.addEventListener("beforeunload",yt,{passive:!0}),C.addEventListener("visibilitychange",()=>{C.document.visibilityState==="hidden"&&F(!0)},{passive:!0}));let St=G=>{if(!G||w<1&&Math.random()>w)return;W&&(W=!1);let j={...G,log_type:d(G)};O.push(j),O.length>_&&(O=O.slice(-_)),O.length>=y?F():U()},Pt=G=>(F(!1,!0),E=G||S(),W=!1,St.sessionId=E,E);return St.flush=()=>F(!1),St.endSession=yt,St.startNewSession=Pt,St.sessionId=E,St},F_=t=>{try{return t()}catch{return null}},FL=async(t,e,{apiKey:r,getAuth:n})=>{let o={"Content-Type":"application/json","X-Analyze-Beacon":"1"};if(r&&(o["X-Analyze-Key"]=r),n)try{let s=await n();s&&(o.Authorization=`Bearer ${s}`)}catch{}try{return(await fetch(t,{method:"POST",headers:o,body:JSON.stringify(e),keepalive:!0,credentials:"omit",mode:"cors"})).ok}catch{return!1}};var NL={error:"\x1B[31m",warn:"\x1B[33m",info:"\x1B[36m",debug:"\x1B[90m",trace:"\x1B[90m"},jL="\x1B[0m",gd=typeof C<"u"&&typeof C.document<"u",j_=(t={})=>{let e=t.minLevel||null,r=console.error.bind(console),n=console.warn.bind(console),o=console.log.bind(console);return s=>{if(!s)return;let i=s.level==="error"?r:s.level==="warn"?n:o,a=`[analyze:${s.type}]`;if(gd)i(a,s);else{let c=NL[s.level]||"";i(`${c}${a}${jL}`,s)}}},B_=(t,e={})=>{let r=e.max||t.config.cache?.max||500,n=new Array(r),o=0,s=0,i=a=>{n[o]=a,o=(o+1)%r,s<r&&s++};return t.__memory={push:i,snapshot:()=>{let a=new Array(s),c=(o-s+r)%r;for(let l=0;l<s;l++)a[l]=n[(c+l)%r];return a},query:(a={})=>{let c=t.__memory.snapshot(),l=a.sinceMs?Date.now()-a.sinceMs:0;return c.filter(f=>!(!f||a.level&&f.level!==a.level||a.type&&f.type!==a.type||l&&f.ts<l))},clear:()=>{o=0,s=0}},i},V_=(t={})=>{let e=t.url,r=t.batchMs!=null?t.batchMs:5e3,n=t.maxBatch||50;if(!e)return()=>{};let o=[],s=null,i=()=>{if(s&&(clearTimeout(s),s=null),!o.length)return;let c=JSON.stringify({events:o});o=[];let l=gd?new C.Blob([c],{type:"application/json"}):c;if(gd&&navigator.sendBeacon)try{navigator.sendBeacon(e,l);return}catch{}typeof fetch<"u"&&fetch(e,{method:"POST",headers:{"Content-Type":"application/json","X-Analyze-Beacon":"1"},body:c,keepalive:!0}).catch(()=>{})};gd&&(C.addEventListener("pagehide",i,{passive:!0}),C.addEventListener("beforeunload",i,{passive:!0}));let a=c=>{c&&(o.push(c),o.length>=n?i():s||(s=setTimeout(i,r)))};return a.flush=i,a},NE={console:j_,memory:B_,beacon:V_,remote:hd},jE=(t,e)=>e.getDebug!=null||e.debug!=null?e:{...e,getDebug:()=>t.config.debug===!0},md=t=>{let e=Array.isArray(t.config.sinks)?t.config.sinks:["console"],r=[];for(let n of e)if(typeof n=="function")r.push(n);else if(typeof n=="string"){let o=NE[n];if(!o)continue;r.push(n==="memory"?o(t,{}):o(n==="remote"?jE(t,{}):{}))}else if(n&&typeof n=="object"&&n.type){let o=NE[n.type];if(!o)continue;r.push(n.type==="memory"?o(t,n):o(n.type==="remote"?jE(t,n):n))}return r};D();var BL=typeof C<"u"&&typeof C.document<"u",VL=new Set(["password","hidden"]),BE=(t,e)=>{let r=0,n=null,o=null;return(...s)=>{let i=Date.now();i-r>=e?(r=i,t(...s)):(o=s,n||(n=setTimeout(()=>{r=Date.now(),n=null,o&&(t(...o),o=null)},e-(i-r))))}},U_="__analyzeKeyPath",Vs=t=>{let e=t.target;if(!e)return{selector:null,key:null,path:null};if(e[U_])return e[U_];let r=[],n=e,o=0,s=null;for(;n&&o<64;){if(n.getAttribute){let a=n.getAttribute("data-key");a&&(s==null&&(s=a),r.unshift(a))}n=n.parentNode,o++}let i;if(r.length)i={selector:null,key:s,path:r.join(" > "),tag:e.tagName?.toLowerCase()||null};else{let a=(e.tagName||"unknown").toLowerCase(),c=e.id?`#${e.id}`:"",l=e.className&&typeof e.className=="string"?"."+e.className.trim().split(/\s+/).slice(0,2).join("."):"";i={selector:`${a}${c}${l}`,key:null,path:null}}try{e[U_]=i}catch{}return i},UL=(t,e)=>{if(e==="mask")return"***";if(e!=="redact"){if(e==="hash"){let r=0,n=String(t||"");for(let o=0;o<n.length;o++)r=(r<<5)-r+n.charCodeAt(o)|0;return`#${(r>>>0).toString(36)}`}return"***"}},zL=t=>!!(!t||t.tagName==="INPUT"&&VL.has(t.type)||fd.test(t.name||"")||fd.test(t.id||"")||t.dataset?.analyze==="skip"),yd=t=>{if(!BL)return;let e=t.config.capture,r=t.config.throttle,n=t.__teardown,o=(s,i,a,c)=>{s.addEventListener(i,a,c),n.push(()=>s.removeEventListener(i,a,c))};if(e.errors&&(o(C,"error",s=>{t.emit(tt("error","error",{hook:"window.onerror",message:s.message||null,error:s.error||null,source:s.filename||null,line:s.lineno||null,col:s.colno||null}))}),o(C,"unhandledrejection",s=>{let i=s.reason,a=i instanceof Error?i:null;t.emit(tt("error","error",{hook:"unhandledrejection",message:a?.message||(typeof i=="string"?i:"Unhandled promise rejection"),error:a}))})),e.pointer){o(C,"click",i=>{t.emit(tt("pointer","info",{hook:"click",target:Vs(i),button:i.button,x:i.clientX,y:i.clientY,modifiers:VE(i)}))},{passive:!0,capture:!0}),o(C,"dblclick",i=>{t.emit(tt("pointer","info",{hook:"dblclick",target:Vs(i),x:i.clientX,y:i.clientY}))},{passive:!0,capture:!0}),o(C,"contextmenu",i=>{t.emit(tt("pointer","info",{hook:"contextmenu",target:Vs(i),x:i.clientX,y:i.clientY}))},{passive:!0,capture:!0});let s=BE(i=>{t.emit(tt("pointer","trace",{hook:"pointermove",x:i.clientX,y:i.clientY}))},r.pointermove);o(C,"pointermove",s,{passive:!0})}if(e.keyboard&&o(C,"keydown",s=>{t.emit(tt("keyboard","info",{hook:"keydown",code:s.code,key:s.key&&s.key.length===1?"\xB7":s.key,modifiers:VE(s),target:Vs(s)}))},{passive:!0,capture:!0}),e.forms){let s=i=>{let a=i.target;if(!a||!a.tagName||!["INPUT","TEXTAREA","SELECT"].includes(a.tagName))return;let l=zL(a),f=a.dataset?.analyze==="track",u=null;f&&!l?u=a.value:t.config.maskFormValues!==!1&&(u=UL(a.value,t.config.maskStrategy)),t.emit(tt("forms","info",{hook:i.type,target:Vs(i),field:{name:a.name||null,type:a.type||a.tagName.toLowerCase()},value:u}))};o(C,"input",s,{passive:!0,capture:!0}),o(C,"change",s,{passive:!0,capture:!0}),o(C,"submit",i=>{t.emit(tt("forms","info",{hook:"submit",target:Vs(i)}))},{passive:!0,capture:!0})}if(e.scroll){let s=BE(()=>{t.emit(tt("scroll","trace",{hook:"scroll",x:C.scrollX,y:C.scrollY}))},r.scroll);o(C,"scroll",s,{passive:!0,capture:!0})}if(e.viewport){let s=Oi(()=>{t.emit(tt("viewport","info",{hook:"resize",w:C.innerWidth,h:C.innerHeight,dpr:C.devicePixelRatio||1}))},r.resize);o(C,"resize",s,{passive:!0}),o(C,"orientationchange",()=>{t.emit(tt("viewport","info",{hook:"orientationchange",orientation:typeof screen<"u"&&screen.orientation?screen.orientation.type:null}))},{passive:!0}),o(C.document,"visibilitychange",()=>{t.emit(tt("viewport","info",{hook:"visibilitychange",hidden:C.document.hidden}))},{passive:!0}),t.emit(tt("viewport","info",{hook:"initial",w:C.innerWidth,h:C.innerHeight,dpr:C.devicePixelRatio||1}))}if(e.console)for(let s of["log","warn","error","debug"]){let i=console[s];console[s]=function(...a){try{t.emit(tt("console",s==="error"?"error":s==="warn"?"warn":"debug",{hook:`console.${s}`,args:a.map(UE)}))}catch{}return i.apply(console,a)},n.push(()=>{console[s]=i})}if(e.performance&&typeof PerformanceObserver<"u")try{let s=new PerformanceObserver(a=>{for(let c of a.getEntries())t.emit(tt("performance","info",{hook:c.entryType,name:c.name,startTime:c.startTime,duration:c.duration,value:c.value!=null?c.value:null}))}),i=["largest-contentful-paint","layout-shift","longtask","paint","first-input","event"];for(let a of i)try{s.observe({type:a,buffered:!0})}catch{}n.push(()=>s.disconnect())}catch{}},VE=t=>({shift:!!t.shiftKey,ctrl:!!t.ctrlKey,alt:!!t.altKey,meta:!!t.metaKey}),HL=t=>{let e={name:t.name||"Error",message:typeof t.message=="string"?t.message:String(t),stack:typeof t.stack=="string"?t.stack:null};return t.cause!==void 0&&(e.cause=UE(t.cause)),e},UE=t=>{if(t==null)return t;if(t instanceof Error)return HL(t);if(typeof t=="object")try{return JSON.parse(JSON.stringify(t))}catch{return String(t)}return t};D();var WL=typeof C<"u"&&typeof C.document<"u",zE=(t,e)=>{let r=t?.analyze;if(!r||!r.shouldCapture("network"))return;let n=e.phase==="error"?"error":"info";r.emit(tt("network",n,{hook:`fetch.${e.phase}`,source:"symbo-fetch",...e}))},Hc=t=>{if(WL&&t.config.capture.network&&!t.__networkListeners){if(t.__networkListeners=!0,t.__teardown.push(()=>{t.__networkListeners=!1}),typeof C.fetch=="function"){let e=C.fetch.bind(C),r=function(n,o){if(o?.headers?.["X-Analyze-Beacon"]||!t.shouldCapture("network"))return e(n,o);let s=typeof n=="string"?n:n&&n.url||"",i=(o?.method||typeof n=="object"&&n?.method||"GET").toUpperCase(),a=typeof performance<"u"?performance.now():Date.now();return t.emit(tt("network","info",{hook:"fetch.start",source:"window.fetch",url:s,method:i})),e(n,o).then(c=>{let l=(typeof performance<"u"?performance.now():Date.now())-a;return t.emit(tt("network",c.ok?"info":"warn",{hook:"fetch.success",source:"window.fetch",url:s,method:i,status:c.status,ok:c.ok,durationMs:l})),c}).catch(c=>{let l=(typeof performance<"u"?performance.now():Date.now())-a;throw t.emit(tt("network","error",{hook:"fetch.error",source:"window.fetch",url:s,method:i,error:c,durationMs:l})),c})};C.fetch=r,t.__teardown.push(()=>{C.fetch=e})}if(typeof C.XMLHttpRequest=="function"){let e=C.XMLHttpRequest,r=e.prototype.open,n=e.prototype.send;e.prototype.open=function(o,s){return this.__analyze={method:String(o).toUpperCase(),url:String(s)},r.apply(this,arguments)},e.prototype.send=function(o){let s=this.__analyze;if(!s||!t.shouldCapture("network"))return n.apply(this,arguments);let i=typeof performance<"u"?performance.now():Date.now();t.emit(tt("network","info",{hook:"xhr.start",source:"xhr",url:s.url,method:s.method}));let a=()=>{let l=(typeof performance<"u"?performance.now():Date.now())-i,f=this.status>=200&&this.status<400;t.emit(tt("network",f?"info":"warn",{hook:"xhr.success",source:"xhr",url:s.url,method:s.method,status:this.status,ok:f,durationMs:l}))},c=()=>{let l=(typeof performance<"u"?performance.now():Date.now())-i;t.emit(tt("network","error",{hook:"xhr.error",source:"xhr",url:s.url,method:s.method,status:this.status,durationMs:l}))};return this.addEventListener("loadend",a),this.addEventListener("error",c),n.apply(this,arguments)},t.__teardown.push(()=>{e.prototype.open=r,e.prototype.send=n})}}};var qL={errors:!0,warnings:!0,pointer:!1,keyboard:!1,forms:!1,scroll:!1,viewport:!1,network:!1,performance:!1,navigation:!1,console:!1,lifecycle:!1,state:!1,updates:!1,replay:!1,telemetry:!1},KL={errors:!0,warnings:!0,pointer:!0,keyboard:!0,forms:!0,scroll:!0,viewport:!0,navigation:!0,state:!0},GL={errors:!0,warnings:!0,pointer:!0,navigation:!0,performance:!0,viewport:!0},YL={errors:!0,warnings:!0,console:!0,network:!1,navigation:!0,performance:!0,viewport:!0,lifecycle:!1,state:!1,updates:!1},XL=t=>{let e={...qL,...t};return e.replay&&Object.assign(e,KL),e.telemetry&&Object.assign(e,GL),e.remote&&Object.assign(e,YL),Object.assign(e,t),e},ZL=64,JL=()=>{if(typeof C>"u"||!C.location)return null;try{let e=new URLSearchParams(C.location.search).get("analyze");return e||null}catch{return null}},bd=(t={})=>{let e=t===!0?{}:{...t};e.capture=XL(e.capture||{});let r=JL();(r==="debug"||e.debug)&&(e.level="debug",e.debug=!0,e.capture={...e.capture,lifecycle:!0,state:!0,updates:!0,console:!0,network:!0}),r==="off"&&(e.enabled=!1),e.level=zc(e.level||"warn"),e.cache={max:500,dedupeWindowMs:1e3,...e.cache||{}},e.throttle={pointermove:80,mousemove:80,scroll:100,resize:200,...e.throttle||{}},e.maskFormValues==null&&(e.maskFormValues=!0),e.maskStrategy||(e.maskStrategy="mask"),Array.isArray(e.sinks)||(e.sinks=["console","memory"]),Array.isArray(e.transformers)||(e.transformers=["enrich","summarize"]);let n={config:e,context:null,__ready:!1,__paused:!1,__preBuffer:[],__teardown:[],__pipeline:null,__sinks:null,__memory:null,__initialSnapshot:null},o=()=>{n.__pipeline||(n.__pipeline=dd(n),n.__sinks=md(n))};return n.shouldCapture=s=>n.config.enabled===!1?!1:!!n.config.capture[s],n.emit=s=>{if(s&&n.config.enabled!==!1&&!n.__paused&&ld(s.level,n.config.level)){if(!n.__ready){if(s.level!=="error"&&!n.config.captureDuringHydration)return;n.__preBuffer.length<ZL&&n.__preBuffer.push(s);return}o(),HE(n,s)}},n.activate=s=>{if(n.context==null&&(n.context=s||null),n.__ready)return;n.__ready=!0;let i=n.__preBuffer;if(n.__preBuffer=[],i.length){o();for(let a of i)HE(n,a)}try{yd(n)}catch(a){console.error("[analyze] browser attach error:",a)}try{Hc(n)}catch(a){console.error("[analyze] network attach error:",a)}for(let a of n.__onActivate||[])try{a(n)}catch(c){console.error("[analyze] onActivate error:",c)}},n.pause=()=>{n.__paused=!0},n.resume=()=>{n.__paused=!1},n.setLevel=s=>{n.config.level=zc(s)},n.setCapture=(s,i)=>{if(n.config.capture[s]=!!i,s==="network"&&i&&n.__ready)try{Hc(n)}catch(a){console.error("[analyze] network attach error:",a)}},n.query=s=>n.__memory?n.__memory.query(s):[],n.snapshot=()=>n.__memory?n.__memory.snapshot():[],n.emitNetwork=s=>{if(!n.shouldCapture("network"))return;let i=s?.phase,a=i==="error"?"error":i==="success"&&s.ok===!1?"warn":"info";n.emit({id:`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,6)}`,ts:Date.now(),type:"network",level:a,hook:`fetch.${i||"unknown"}`,...s})},n.flush=()=>{if(n.__sinks)for(let s of n.__sinks)typeof s.flush=="function"&&s.flush()},n.startNewSession=s=>{let i=s||(typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`),a=Array.isArray(n.config.sinks)?n.config.sinks:[];for(let c of a)c&&typeof c=="object"&&c.type==="remote"&&(c.sessionId=i);if(n.__sinks)for(let c of n.__sinks)typeof c.startNewSession=="function"&&c.startNewSession(i);return i},n.replay=()=>({initialSnapshot:n.__initialSnapshot,events:n.snapshot()}),n.destroy=()=>{for(let s of n.__teardown)try{s()}catch{}n.__teardown=[],n.__ready=!1,n.__paused=!0},n.__onActivate=[],n.onActivate=s=>{n.__onActivate.push(s)},n},HE=(t,e)=>{let r=t.__pipeline(e);if(r==null)return;let n=Array.isArray(r)?r:[r];for(let o of n){if(typeof t.config.onEvent=="function")try{t.config.onEvent(o)}catch{}for(let s of t.__sinks)try{s(o)}catch(i){console.error("[analyze] sink error:",i)}}};var q_={};$(q_,{Inspect:()=>_d,inspectPlugin:()=>W_});D();function WE(t){return k(t)?t:P(t)?t.find(e=>k(e)):""}function H_(t){if(!t)return;let e=t.__ref.__componentKey,r=t.extends&&WE(t.extends),n=t.parent&&t.parent.childExtends&&WE(t.parent.childExtends);return(e||r||n||"").split("_")[0].split(".")[0].split("+")[0]}function xd(t){if(!t||!t.__ref)return;let{components:e,pages:r,editor:n}=t.context,o=H_(t);return n&&n.onInitInspect&&!n.onInitInspect(o,t,t.state)?xd(t.parent):o&&(e[o]||r[o])?t:xd(t.parent)}var QL=(t,e,r)=>{let n=r.window||window;n.onkeydown=o=>{o.altKey&&o.shiftKey&&t.state.update({debugging:!0,preventSelect:!0},{preventUpdate:!0,preventContentUpdate:!0,preventRecursive:!0})},n.onkeyup=o=>{t.state.preventSelect&&(!o.altKey||!o.shiftKey)&&(t.state.replace({debugging:!1,preventSelect:!1},{preventUpdate:!0,preventContentUpdate:!0,preventRecursive:!0}),t.Inspector.state.update({area:!1}))}},_d={".preventSelect":{userSelect:"none"},"!preventSelect":{userSelect:"auto"},onInspect:QL,onMousemove:(t,e,r)=>{let n=t.target.ref,o=xd(n),s=e.Inspector.state;if(!o||!r.debugging||!o.__ref)return s.update({area:!1});let i=H_(o),a=l=>{s.update({area:l,focusKey:i})},c=()=>{if(t.altKey&&t.shiftKey){let{x:l,y:f,width:u,height:d}=o.node.getBoundingClientRect(),g={x:l,y:f,width:u,height:d};if(!s.area)return a(g);s.area.x!==g.x&&a(g)}else s.area&&s.update({area:!1})};window.requestAnimationFrame(()=>{c(),window.requestAnimationFrame(c)})},onMousedown:(t,e,r)=>{if(!r.debugging)return;let n=t.target.ref,o=xd(n);if(!o)return;let s=H_(o);if(!s)return;let i=n.context.editor;if(i&&i.onInspect)return i.onInspect(s,n,n.state,{allowRouterWhileInspect:!0});let a=JSON.stringify({componentKey:`${s}`});return n.context.socket?.emit&&n.context.socket.emit("route",a),t.preventDefault(),t.stopPropagation(),!1},Inspector:{state:{},transition:"all, defaultBezier, X",position:"fixed",hide:(t,e)=>!(e.area&&e.parent.debugging),style:{boxShadow:"0 0 10px #3686F733, 0 0 0 3px #3686F766, 0 0 100vmax 100vmax #000A",zIndex:"9999999",borderRadius:"10px",pointerEvents:"none"},Span:{position:"absolute",margin:"A2 0",fontSize:"Z",color:"text",zIndex:"99999999",transition:"all, defaultBezier, X",textDecoration:"underline",fontWeight:"500",top:"100%",style:{boxShadow:"0 25px 10px 35px black",textShadow:"0 0 10px black"},text:"{{ focusKey }}"},onInit:({context:t})=>{let{components:e}=t;if(v(e)){let{Content:r,...n}=e;for(let o in n)Rs[o]||(n[o].__ref||(n[o].__ref={}),n[o].__ref.__componentKey||(n[o].__ref.__componentKey=o))}},onBeforeUpdate:(t,e,r)=>{let{area:n}=r,o=r.area&&r.parent.debugging,s;if(!o)s="display: none !important";else if(n){let{x:i,y:a,width:c,height:l}=n;s=`
91
91
  display: block !important;
92
92
  top: ${a-6}px;
93
93
  left: ${i-6}px;
94
94
  width: ${c+12}px;
95
95
  height: ${l+12}px;
96
- `}return e.node.style=s,e.Span.node.innerText=r.focusKey,!1}}},j_={name:"inspect",beforeCreate(t,e){Array.isArray(t.extends)?t.extends.push(yd):t.extends?t.extends=[t.extends,yd]:t.extends=[yd]}};var U_={};$(U_,{apiUrl:()=>V_,channelByApiUrl:()=>UL,channelNames:()=>BL,channels:()=>ae,currentChannel:()=>pn,defaultChannel:()=>XL,deployTarget:()=>KL,isKnownChannel:()=>YL,mermaidUrl:()=>qL,normalizeOwnerSegment:()=>ZL,normalizeProjectKey:()=>QL,normalizeProjectSlug:()=>JL,parseSymboLsHost:()=>tI,previewProjectUrl:()=>WL,previewUrl:()=>jE,resolveChannel:()=>uo,screenshotCdnHost:()=>BE,screenshotCdnUrl:()=>GL,setChannel:()=>VL,shellUrl:()=>HL,socketUrl:()=>zL});var ae={channels:{local:{api:"http://localhost:8080",socket:"http://localhost:8080",shell:"http://my.localhost:1355",preview:"http://preview.localhost:1355",mermaidApex:"localhost:1355",deploy:{}},development:{api:"https://dev.api.symbols.app",socket:"https://dev.api.symbols.app",shell:"https://dev.my.symbols.app",preview:"https://dev.preview.symbols.app",mermaidApex:"dev.symbo.ls",deploy:{shellBucket:"smbls-my-dev",previewWorker:"smbls-preview-dev",mermaidWorker:"mermaid-dev"}},"demo-dev":{api:"https://dev.api.symbols.app",socket:"https://dev.api.symbols.app",shell:"https://dev.demo.symbols.app",preview:"https://dev.preview.symbols.app",mermaidApex:"dev.symbo.ls",deploy:{shellBucket:"smbls-my-demo-dev",previewWorker:"smbls-preview-dev",mermaidWorker:"mermaid-dev"}},next:{api:"https://next.api.symbols.app",socket:"https://next.api.symbols.app",shell:"https://next.my.symbols.app",preview:"https://next.preview.symbols.app",mermaidApex:"next.symbo.ls",deploy:{shellBucket:"smbls-my-next",previewWorker:"smbls-preview-next",mermaidWorker:"mermaid-next"}},test:{api:"https://test.api.symbols.app",socket:"https://test.api.symbols.app",shell:"https://test.my.symbols.app",preview:"https://test.preview.symbols.app",mermaidApex:"test.symbo.ls",deploy:{shellBucket:"smbls-my-test",previewWorker:"smbls-preview-test",mermaidWorker:"mermaid-test"}},upcoming:{api:"https://upcoming.api.symbols.app",socket:"https://upcoming.api.symbols.app",shell:"https://upcoming.my.symbols.app",preview:"https://upcoming.preview.symbols.app",mermaidApex:"upcoming.symbo.ls",deploy:{shellBucket:"smbls-my-upcoming",previewWorker:"smbls-preview-upcoming",mermaidWorker:"mermaid-upcoming"}},staging:{api:"https://staging.api.symbols.app",socket:"https://staging.api.symbols.app",shell:"https://staging.my.symbols.app",preview:"https://staging.preview.symbols.app",mermaidApex:"staging.symbo.ls",deploy:{shellBucket:"smbls-my-staging",previewWorker:"smbls-preview-staging",mermaidWorker:"mermaid-staging"}},demo:{api:"https://api.symbols.app",socket:"https://api.symbols.app",shell:"https://demo.symbols.app",preview:"https://preview.symbols.app",mermaidApex:"at.symbo.ls",deploy:{shellBucket:"smbls-my-demo",previewWorker:"smbls-preview",mermaidWorker:"mermaid"}},production:{api:"https://api.symbols.app",socket:"https://api.symbols.app",shell:"https://my.symbols.app",preview:"https://preview.symbols.app",mermaidApex:"at.symbo.ls",deploy:{shellBucket:"smbls-my-prod",previewWorker:"smbls-preview",mermaidWorker:"mermaid"}}},defaultChannel:"production",screenshotCdn:"screenshots.api.symbols.app"};var BL=Object.keys(ae.channels),Ar=t=>!!(t&&ae.channels[t]),uo=t=>Ar(t)?ae.channels[t]:ae.channels[ae.defaultChannel],VL=t=>{typeof globalThis>"u"||(globalThis.__SYMBOLS_CHANNEL__=Ar(t)?t:null,Bs=void 0)},Bs,zc=t=>typeof process<"u"&&process.env&&process.env[t]||null,pn=()=>{if(Bs!==void 0)return Bs;let t=typeof globalThis<"u"?globalThis.__SYMBOLS_CHANNEL__:null,e=zc("SYMBOLS_CHANNEL"),r=zc("NODE_ENV");return Bs=Ar(t)&&t||Ar(e)&&e||Ar(r)&&r||ae.defaultChannel,Bs===ae.defaultChannel&&!Ar(t)&&!Ar(e)&&!Ar(r)&&typeof process<"u"&&process.versions&&process.versions.node&&console.warn(`[channels] no channel configured (NODE_ENV=${r||"unset"}, __SYMBOLS_CHANNEL__ unset) \u2014 falling back to "${ae.defaultChannel}". Outbound URLs (shellUrl/apiUrl) will target production; set SYMBOLS_CHANNEL (preferred), NODE_ENV, or globalThis.__SYMBOLS_CHANNEL__ to a known channel.`),Bs},ME=["production","staging","upcoming","next","test","development","local","demo","demo-dev"],FE=t=>{let e=ME.indexOf(t);return e===-1?ME.length:e},UL=t=>{if(!t)return null;let e=Object.keys(ae.channels).filter(r=>ae.channels[r].api===t);return e.length===0?null:e.length===1?e[0]:e.sort((r,n)=>FE(r)-FE(n))[0]},V_=(t=pn())=>zc("SYMBOLS_API_URL")||uo(t).api,zL=(t=pn())=>zc("SYMBOLS_SOCKET_URL")||uo(t).socket,HL=(t=pn())=>uo(t).shell||null,jE=(t=pn())=>uo(t).preview||null,WL=({owner:t,key:e,env:r="production"}={},n=pn())=>{let o=jE(n);if(!o||!t||!e)return null;let s=o.match(/^(https?:\/\/)(.+)$/);if(!s)return null;let[,i,a]=s,c=`${encodeURIComponent(t)}--${encodeURIComponent(e)}`,l=`${i}${c}.${a}/`;return!r||r==="production"||r==="prod"?l:`${l}?env=${encodeURIComponent(r)}`},qL=({owner:t,key:e,env:r="production"}={},n=pn())=>{let o=uo(n).mermaidApex;if(!o||!t||!e)return null;let i=!r||r==="production"||r==="prod"?"":`--${encodeURIComponent(r)}`,a=`${encodeURIComponent(t)}--${encodeURIComponent(e)}${i}`;return`${o.startsWith("localhost")?"http":"https"}://${a}.${o}`},KL=(t=pn())=>uo(t).deploy||{},BE=()=>zc("SYMBOLS_SCREENSHOT_CDN")||ae.screenshotCdn,GL=({owner:t,key:e,page:r="root",componentKey:n,env:o="production",width:s}={})=>{if(!t||!e)return null;let i=n?`component/${encodeURIComponent(n)}`:encodeURIComponent(String(r||"root").replace(/^\/+/,"").replace(/\//g,"-")||"root"),a=[];o&&o!=="production"&&a.push(`env=${encodeURIComponent(o)}`),s&&a.push(`w=${Number(s)}`);let c=a.length?`?${a.join("&")}`:"";return`https://${BE()}/${encodeURIComponent(t)}/${encodeURIComponent(e)}/${i}.webp${c}`},YL=Ar,XL=ae.defaultChannel,ZL=t=>t==null||typeof t!="string"?"":String(t).toLowerCase().trim().replace(/[^a-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-+|-+$/g,"").slice(0,32)||"",JL=t=>t==null||typeof t!="string"?"":String(t).toLowerCase().trim().replace(/[^a-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-+|-+$/g,"").slice(0,48)||"",QL=(t,e={})=>{let r=String(t||"").trim();if(!r)return"";/\.symbo\.ls$/iu.test(r)&&(r=r.replace(/\.symbo\.ls$/iu,"")),r.includes("/")&&(r=r.split("/").pop());let n=typeof e.owner=="string"?e.owner.trim():"";return n&&r.startsWith(`${n}--`)?r=r.slice(n.length+2):!n&&r.includes("--")&&(r=r.slice(r.indexOf("--")+2)),r},NE={at:"production",prod:"production",production:"production",dev:"development",development:"development",next:"next",upcoming:"upcoming",test:"test",staging:"staging"},tI=t=>{if(typeof t!="string"||!t)return null;let e=t.toLowerCase().replace(/^www\./,"").replace(/\/$/,"");if(!e.endsWith(".symbo.ls"))return null;let r=e.split(".");if(r.length<4||r.slice(-2).join(".")!=="symbo.ls")return null;if(r.length===4){let s=r[1],i=r[0],a=NE[s];if(a&&i.includes("--")){let c=i.split("--");if(c.length===2||c.length===3){let[l,f,u]=c;if(l&&f){let d=u?NE[u]||u:null;return{projectKey:f,owner:l,env:d||a,sysEnv:a}}}}}if(r.length>=5)return{projectKey:r[1],owner:r[2],env:r[0]};let n=r[1],o=r[0];if(o.includes("--")){let[s,i]=o.split("--",2);return!s||!i?null:{projectKey:s,owner:n,env:i}}return{projectKey:o,owner:n,env:"production"}};var W_={};$(W_,{BUILD_DOMQL_SYSTEM_PROMPT:()=>JE,DEFAULT_MAX_TOKENS:()=>vd,DEFAULT_MODEL:()=>hn,DEFAULT_PROVIDER:()=>qc,DEFAULT_TEMPERATURE:()=>kd,MODEL_TIER_ALIASES:()=>H_,PROVIDER_MODELS:()=>Wc,SIMONE_BASE_URL:()=>Hc,SIMONE_CHAT_PATH:()=>_d,SIMONE_CODE_PATH:()=>wd,SIMONE_CODE_SYMBOLS_PATH:()=>xd,SIMONE_HEALTH_PATH:()=>Sd,SIMONE_TOOLS_PATH:()=>VE,WORKSPACE_SYSTEM_PROMPT:()=>ZE,buildMessages:()=>qE,chat:()=>Kc,health:()=>WE,parseSimoneResponse:()=>YE,resolveModel:()=>QE,streamChat:()=>Kc,streamCode:()=>zE,streamCodeSymbols:()=>HE,toLegacyEnvelope:()=>XE});var Hc="https://symbols-service-production.up.railway.app",_d="/api/chat",wd="/api/code",xd="/api/code-symbols",Sd="/api/health",VE="/api/tools",Wc={"openai-compatible":["claude-sonnet-4-6","claude-opus-4-6","gpt-4o","gpt-4o-mini","deepseek-chat"],anthropic:["claude-sonnet-4-6","claude-sonnet-4-5-20250929","claude-opus-4-1-20250805","claude-haiku-4-5-20251001"],openrouter:["google/gemini-3-pro-preview"],gemini:["gemini-2.5-pro","gemini-3.1-pro-preview"]},qc="gemini",hn=Wc[qc][0],kd=.7,vd=4096;function eI(t){if(!t)return null;for(let[e,r]of Object.entries(Wc))if(r.includes(t))return e;return null}function UE(t,e){return t?t.replace(/\/$/,"")+e:e}function rI(t){if(!t.startsWith("data: "))return null;let e=t.slice(6);if(e==="[DONE]")return{done:!0};try{return{chunk:JSON.parse(e)}}catch{return{raw:e}}}async function Kc(t,e={},r){let{baseUrl:n=Hc,path:o=_d,model:s=hn,provider:i=eI(s)||qc,temperature:a=kd,maxTokens:c=vd,effort:l,apiKeys:f,signal:u,headers:d}=e;if(!Array.isArray(t)||t.length===0)throw new TypeError("simone: messages must be a non-empty array");let g={messages:t,provider:i,model:s,temperature:a,maxTokens:c};l&&(g.effort=l),f&&(g.apiKeys=f);let p=await fetch(UE(n,o),{method:"POST",headers:{"Content-Type":"application/json",Accept:"text/event-stream",...d},body:JSON.stringify(g),signal:u});if(!p.ok){let b=p.statusText;try{let S=await p.text();try{let C=JSON.parse(S);b=C.error||C.detail||b}catch{b=S||b}}catch{}let w=new Error(`simone: HTTP ${p.status} \u2014 ${b}`);throw w.status=p.status,w}if(!p.body||typeof p.body.getReader!="function"){let b=await p.text();return r&&r(b),{text:b,errors:[]}}let h=p.body.getReader(),m=new TextDecoder,_=[],x=[],y="";try{for(;;){let{done:b,value:w}=await h.read();if(b)break;y+=m.decode(w,{stream:!0});let S=y.indexOf(`
97
- `);for(;S!==-1;){let C=y.slice(0,S).trim();if(y=y.slice(S+1),C){let O=rI(C);if(O?.done)return{text:_.join(""),errors:x};let L=O?.chunk;L?.delta&&(_.push(L.delta),r&&r(L.delta)),L?.error&&x.push(L.error)}S=y.indexOf(`
98
- `)}}return{text:_.join(""),errors:x}}finally{h.cancel().catch(()=>{})}}function zE(t,e={},r){return Kc(t,{...e,path:wd},r)}function HE(t,e={},r){return Kc(t,{...e,path:xd},r)}async function WE(t={}){let{baseUrl:e=Hc,signal:r,headers:n}=t,o=await fetch(UE(e,Sd),{method:"GET",headers:n,signal:r});if(!o.ok)throw new Error(`simone health: HTTP ${o.status}`);return o.json()}function qE({system:t,history:e=[],user:r,context:n}){let o=[];t&&o.push({role:"system",content:t});for(let s of e)!s||!s.role||typeof s.content!="string"||!s.content||o.push({role:s.role,content:s.content});if(r){let s=r;if(n!=null){let i=typeof n=="string"?n:JSON.stringify(n,null,2);s=`${s}
96
+ `}return e.node.style=s,e.Span.node.innerText=r.focusKey,!1}}},W_={name:"inspect",beforeCreate(t,e){Array.isArray(t.extends)?t.extends.push(_d):t.extends?t.extends=[t.extends,_d]:t.extends=[_d]}};var G_={};$(G_,{apiUrl:()=>K_,channelByApiUrl:()=>nI,channelNames:()=>eI,channels:()=>ae,currentChannel:()=>un,defaultChannel:()=>uI,deployTarget:()=>cI,isKnownChannel:()=>fI,mermaidUrl:()=>aI,normalizeOwnerSegment:()=>dI,normalizeProjectKey:()=>hI,normalizeProjectSlug:()=>pI,parseSymboLsHost:()=>gI,previewProjectUrl:()=>iI,previewUrl:()=>YE,resolveChannel:()=>uo,screenshotCdnHost:()=>XE,screenshotCdnUrl:()=>lI,setChannel:()=>rI,shellUrl:()=>sI,socketUrl:()=>oI});var ae={channels:{local:{api:"http://localhost:8080",socket:"http://localhost:8080",shell:"http://my.localhost:1355",preview:"http://preview.localhost:1355",mermaidApex:"localhost:1355",deploy:{}},development:{api:"https://dev.api.symbols.app",socket:"https://dev.api.symbols.app",shell:"https://dev.my.symbols.app",preview:"https://dev.preview.symbols.app",mermaidApex:"dev.symbo.ls",deploy:{shellBucket:"smbls-my-dev",previewWorker:"smbls-preview-dev",mermaidWorker:"mermaid-dev"}},"demo-dev":{api:"https://dev.api.symbols.app",socket:"https://dev.api.symbols.app",shell:"https://dev.demo.symbols.app",preview:"https://dev.preview.symbols.app",mermaidApex:"dev.symbo.ls",deploy:{shellBucket:"smbls-my-demo-dev",previewWorker:"smbls-preview-dev",mermaidWorker:"mermaid-dev"}},next:{api:"https://next.api.symbols.app",socket:"https://next.api.symbols.app",shell:"https://next.my.symbols.app",preview:"https://next.preview.symbols.app",mermaidApex:"next.symbo.ls",deploy:{shellBucket:"smbls-my-next",previewWorker:"smbls-preview-next",mermaidWorker:"mermaid-next"}},test:{api:"https://test.api.symbols.app",socket:"https://test.api.symbols.app",shell:"https://test.my.symbols.app",preview:"https://test.preview.symbols.app",mermaidApex:"test.symbo.ls",deploy:{shellBucket:"smbls-my-test",previewWorker:"smbls-preview-test",mermaidWorker:"mermaid-test"}},upcoming:{api:"https://upcoming.api.symbols.app",socket:"https://upcoming.api.symbols.app",shell:"https://upcoming.my.symbols.app",preview:"https://upcoming.preview.symbols.app",mermaidApex:"upcoming.symbo.ls",deploy:{shellBucket:"smbls-my-upcoming",previewWorker:"smbls-preview-upcoming",mermaidWorker:"mermaid-upcoming"}},staging:{api:"https://staging.api.symbols.app",socket:"https://staging.api.symbols.app",shell:"https://staging.my.symbols.app",preview:"https://staging.preview.symbols.app",mermaidApex:"staging.symbo.ls",deploy:{shellBucket:"smbls-my-staging",previewWorker:"smbls-preview-staging",mermaidWorker:"mermaid-staging"}},demo:{api:"https://api.symbols.app",socket:"https://api.symbols.app",shell:"https://demo.symbols.app",preview:"https://preview.symbols.app",mermaidApex:"at.symbo.ls",deploy:{shellBucket:"smbls-my-demo",previewWorker:"smbls-preview",mermaidWorker:"mermaid"}},production:{api:"https://api.symbols.app",socket:"https://api.symbols.app",shell:"https://my.symbols.app",preview:"https://preview.symbols.app",mermaidApex:"at.symbo.ls",deploy:{shellBucket:"smbls-my-prod",previewWorker:"smbls-preview",mermaidWorker:"mermaid"}}},defaultChannel:"production",screenshotCdn:"screenshots.api.symbols.app"};var eI=Object.keys(ae.channels),Tr=t=>!!(t&&ae.channels[t]),uo=t=>Tr(t)?ae.channels[t]:ae.channels[ae.defaultChannel],rI=t=>{typeof globalThis>"u"||(globalThis.__SYMBOLS_CHANNEL__=Tr(t)?t:null,Us=void 0)},Us,Wc=t=>typeof process<"u"&&process.env&&process.env[t]||null,un=()=>{if(Us!==void 0)return Us;let t=typeof globalThis<"u"?globalThis.__SYMBOLS_CHANNEL__:null,e=Wc("SYMBOLS_CHANNEL"),r=Wc("NODE_ENV");return Us=Tr(t)&&t||Tr(e)&&e||Tr(r)&&r||ae.defaultChannel,Us===ae.defaultChannel&&!Tr(t)&&!Tr(e)&&!Tr(r)&&typeof process<"u"&&process.versions&&process.versions.node&&console.warn(`[channels] no channel configured (NODE_ENV=${r||"unset"}, __SYMBOLS_CHANNEL__ unset) \u2014 falling back to "${ae.defaultChannel}". Outbound URLs (shellUrl/apiUrl) will target production; set SYMBOLS_CHANNEL (preferred), NODE_ENV, or globalThis.__SYMBOLS_CHANNEL__ to a known channel.`),Us},qE=["production","staging","upcoming","next","test","development","local","demo","demo-dev"],KE=t=>{let e=qE.indexOf(t);return e===-1?qE.length:e},nI=t=>{if(!t)return null;let e=Object.keys(ae.channels).filter(r=>ae.channels[r].api===t);return e.length===0?null:e.length===1?e[0]:e.sort((r,n)=>KE(r)-KE(n))[0]},K_=(t=un())=>Wc("SYMBOLS_API_URL")||uo(t).api,oI=(t=un())=>Wc("SYMBOLS_SOCKET_URL")||uo(t).socket,sI=(t=un())=>uo(t).shell||null,YE=(t=un())=>uo(t).preview||null,iI=({owner:t,key:e,env:r="production"}={},n=un())=>{let o=YE(n);if(!o||!t||!e)return null;let s=o.match(/^(https?:\/\/)(.+)$/);if(!s)return null;let[,i,a]=s,c=`${encodeURIComponent(t)}--${encodeURIComponent(e)}`,l=`${i}${c}.${a}/`;return!r||r==="production"||r==="prod"?l:`${l}?env=${encodeURIComponent(r)}`},aI=({owner:t,key:e,env:r="production"}={},n=un())=>{let o=uo(n).mermaidApex;if(!o||!t||!e)return null;let i=!r||r==="production"||r==="prod"?"":`--${encodeURIComponent(r)}`,a=`${encodeURIComponent(t)}--${encodeURIComponent(e)}${i}`;return`${o.startsWith("localhost")?"http":"https"}://${a}.${o}`},cI=(t=un())=>uo(t).deploy||{},XE=()=>Wc("SYMBOLS_SCREENSHOT_CDN")||ae.screenshotCdn,lI=({owner:t,key:e,page:r="root",componentKey:n,env:o="production",width:s}={})=>{if(!t||!e)return null;let i=n?`component/${encodeURIComponent(n)}`:encodeURIComponent(String(r||"root").replace(/^\/+/,"").replace(/\//g,"-")||"root"),a=[];o&&o!=="production"&&a.push(`env=${encodeURIComponent(o)}`),s&&a.push(`w=${Number(s)}`);let c=a.length?`?${a.join("&")}`:"";return`https://${XE()}/${encodeURIComponent(t)}/${encodeURIComponent(e)}/${i}.webp${c}`},fI=Tr,uI=ae.defaultChannel,dI=t=>t==null||typeof t!="string"?"":String(t).toLowerCase().trim().replace(/[^a-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-+|-+$/g,"").slice(0,32)||"",pI=t=>t==null||typeof t!="string"?"":String(t).toLowerCase().trim().replace(/[^a-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-+|-+$/g,"").slice(0,48)||"",hI=(t,e={})=>{let r=String(t||"").trim();if(!r)return"";/\.symbo\.ls$/iu.test(r)&&(r=r.replace(/\.symbo\.ls$/iu,"")),r.includes("/")&&(r=r.split("/").pop());let n=typeof e.owner=="string"?e.owner.trim():"";return n&&r.startsWith(`${n}--`)?r=r.slice(n.length+2):!n&&r.includes("--")&&(r=r.slice(r.indexOf("--")+2)),r},GE={at:"production",prod:"production",production:"production",dev:"development",development:"development",next:"next",upcoming:"upcoming",test:"test",staging:"staging"},gI=t=>{if(typeof t!="string"||!t)return null;let e=t.toLowerCase().replace(/^www\./,"").replace(/\/$/,"");if(!e.endsWith(".symbo.ls"))return null;let r=e.split(".");if(r.length<4||r.slice(-2).join(".")!=="symbo.ls")return null;if(r.length===4){let s=r[1],i=r[0],a=GE[s];if(a&&i.includes("--")){let c=i.split("--");if(c.length===2||c.length===3){let[l,f,u]=c;if(l&&f){let d=u?GE[u]||u:null;return{projectKey:f,owner:l,env:d||a,sysEnv:a}}}}}if(r.length>=5)return{projectKey:r[1],owner:r[2],env:r[0]};let n=r[1],o=r[0];if(o.includes("--")){let[s,i]=o.split("--",2);return!s||!i?null:{projectKey:s,owner:n,env:i}}return{projectKey:o,owner:n,env:"production"}};var Z_={};$(Z_,{BUILD_DOMQL_SYSTEM_PROMPT:()=>c1,DEFAULT_MAX_TOKENS:()=>Ed,DEFAULT_MODEL:()=>dn,DEFAULT_PROVIDER:()=>Gc,DEFAULT_TEMPERATURE:()=>Cd,MODEL_TIER_ALIASES:()=>X_,PROVIDER_MODELS:()=>Kc,SIMONE_BASE_URL:()=>qc,SIMONE_CHAT_PATH:()=>wd,SIMONE_CODE_PATH:()=>Sd,SIMONE_CODE_SYMBOLS_PATH:()=>kd,SIMONE_HEALTH_PATH:()=>vd,SIMONE_TOOLS_PATH:()=>ZE,WORKSPACE_SYSTEM_PROMPT:()=>a1,buildMessages:()=>r1,chat:()=>Yc,health:()=>e1,parseSimoneResponse:()=>s1,resolveModel:()=>l1,streamChat:()=>Yc,streamCode:()=>QE,streamCodeSymbols:()=>t1,toLegacyEnvelope:()=>i1});var qc="https://symbols-service-production.up.railway.app",wd="/api/chat",Sd="/api/code",kd="/api/code-symbols",vd="/api/health",ZE="/api/tools",Kc={"openai-compatible":["claude-sonnet-4-6","claude-opus-4-6","gpt-4o","gpt-4o-mini","deepseek-chat"],anthropic:["claude-sonnet-4-6","claude-sonnet-4-5-20250929","claude-opus-4-1-20250805","claude-haiku-4-5-20251001"],openrouter:["google/gemini-3-pro-preview"],gemini:["gemini-2.5-pro","gemini-3.1-pro-preview"]},Gc="gemini",dn=Kc[Gc][0],Cd=.7,Ed=4096;function mI(t){if(!t)return null;for(let[e,r]of Object.entries(Kc))if(r.includes(t))return e;return null}function JE(t,e){return t?t.replace(/\/$/,"")+e:e}function yI(t){if(!t.startsWith("data: "))return null;let e=t.slice(6);if(e==="[DONE]")return{done:!0};try{return{chunk:JSON.parse(e)}}catch{return{raw:e}}}async function Yc(t,e={},r){let{baseUrl:n=qc,path:o=wd,model:s=dn,provider:i=mI(s)||Gc,temperature:a=Cd,maxTokens:c=Ed,effort:l,apiKeys:f,signal:u,headers:d}=e;if(!Array.isArray(t)||t.length===0)throw new TypeError("simone: messages must be a non-empty array");let g={messages:t,provider:i,model:s,temperature:a,maxTokens:c};l&&(g.effort=l),f&&(g.apiKeys=f);let p=await fetch(JE(n,o),{method:"POST",headers:{"Content-Type":"application/json",Accept:"text/event-stream",...d},body:JSON.stringify(g),signal:u});if(!p.ok){let _=p.statusText;try{let S=await p.text();try{let E=JSON.parse(S);_=E.error||E.detail||_}catch{_=S||_}}catch{}let w=new Error(`simone: HTTP ${p.status} \u2014 ${_}`);throw w.status=p.status,w}if(!p.body||typeof p.body.getReader!="function"){let _=await p.text();return r&&r(_),{text:_,errors:[]}}let h=p.body.getReader(),m=new TextDecoder,y=[],x=[],b="";try{for(;;){let{done:_,value:w}=await h.read();if(_)break;b+=m.decode(w,{stream:!0});let S=b.indexOf(`
97
+ `);for(;S!==-1;){let E=b.slice(0,S).trim();if(b=b.slice(S+1),E){let O=yI(E);if(O?.done)return{text:y.join(""),errors:x};let L=O?.chunk;L?.delta&&(y.push(L.delta),r&&r(L.delta)),L?.error&&x.push(L.error)}S=b.indexOf(`
98
+ `)}}return{text:y.join(""),errors:x}}finally{h.cancel().catch(()=>{})}}function QE(t,e={},r){return Yc(t,{...e,path:Sd},r)}function t1(t,e={},r){return Yc(t,{...e,path:kd},r)}async function e1(t={}){let{baseUrl:e=qc,signal:r,headers:n}=t,o=await fetch(JE(e,vd),{method:"GET",headers:n,signal:r});if(!o.ok)throw new Error(`simone health: HTTP ${o.status}`);return o.json()}function r1({system:t,history:e=[],user:r,context:n}){let o=[];t&&o.push({role:"system",content:t});for(let s of e)!s||!s.role||typeof s.content!="string"||!s.content||o.push({role:s.role,content:s.content});if(r){let s=r;if(n!=null){let i=typeof n=="string"?n:JSON.stringify(n,null,2);s=`${s}
99
99
 
100
100
  ---
101
101
  Context:
102
102
  \`\`\`json
103
103
  ${i}
104
- \`\`\``}o.push({role:"user",content:s})}return o}var GE=/```(?<lang>[a-zA-Z0-9_+-]*)\n(?<code>[\s\S]*?)```/g,nI=new Set(["component","components","page","pages","function","method","state","theme","color","font","icon"]);function oI(t){let e=[];for(let r of t.matchAll(GE))e.push({lang:(r.groups?.lang||"").toLowerCase(),code:r.groups?.code??""});return e}function sI(t){return t.replace(GE,"").trim()}function z_(t){if(!t||!/[{[]/.test(t))return null;try{return JSON.parse(t)}catch{}try{return JSON.parse(t.replace(/,\s*([}\]])/g,"$1"))}catch{}return null}function KE(t){return!!t&&typeof t=="object"&&typeof t.type=="string"&&nI.has(t.type)}function YE(t){let e=(typeof t=="string"?t:"").trim();if(!e)return{kind:"text",text:"",message:""};let r=oI(e),n=r.filter(i=>/^(js|javascript|ts|typescript|jsx|tsx)$/.test(i.lang)),o=r.filter(i=>i.lang==="json"),s=sI(e);for(let i of o){let a=z_(i.code);if(KE(a))return{kind:"asset",text:s||a.description||"",asset:a,message:a.description||s||`Generated ${a.type}: ${a.title||a.key||""}`.trim()}}if(n.length>0){let i=n[0].code,a=z_("["+i+"]");return Array.isArray(a)&&a.length>1?{kind:"multi",text:s,assets:a,code:i,message:s||`Generated ${a.length} items`}:{kind:"component",text:s,code:i,message:s||"Generated a component"}}if(e.startsWith("{")){let i=z_(e);if(KE(i))return{kind:"asset",text:i.description||"",asset:i,message:i.description||`Generated ${i.type}: ${i.title||i.key||""}`.trim()}}return{kind:"text",text:e,message:e}}function XE(t){if(!t)return{code_response:{type:"error",content:"Empty response from assistant"}};switch(t.kind){case"asset":return{code_response:{type:"json_response",data:t.asset}};case"multi":return{code_response:{type:"symbols_component_code",component_code:t.code}};case"component":return{code_response:{type:"symbols_component_code",component_code:t.code,analysis_text:t.text}};default:return{code_response:{type:"plain_text_response",content:t.text||t.message||""}}}}var ZE=["You are Simone, the Symbols.app assistant.","You help users build DOMQL v3 components, pages, and design-system entries.",'When the user asks for a component or page, return a single ```json fenced block whose body is one asset object with shape { type, key, title, description, value }. type is one of "component", "page", "function", "state", "color", "font", "icon", "theme".',"For multiple assets, return one ```js fenced block with comma-separated asset objects.","For general questions, reply with prose only."].join(" "),JE=["You are a DOMQL v3.14 code generator for the Symbols workspace.","Output EXECUTABLE DOMQL v3.14 for the requested page(s)/component(s) \u2014 never a description, never a plan, never an explanation.","Author data-first object schemas: child elements are UPPERCASE keys; styling lives in flat element props (NO attr/props/on wrappers); use design-system tokens (color/typography/spacing keys), never raw px/rem/hex/rgba; `extends` and `childExtends` are quoted strings; event handlers are flat (onClick, onInit) \u2014 never on:{} or props:{} wrappers.","OUTPUT FORMAT \u2014 pick ONE:","- SINGLE page/component: emit exactly one ```js fenced code block whose body is a single DOMQL object literal (an expression \u2014 start with `{`, no `export`, no variable assignment, no surrounding prose).",'- MULTIPLE pages/components: emit exactly one ```json fenced code block whose body is an object of the shape { "pages": { "PageKey": "<DOMQL object-literal source string>" }, "components": { "CompKey": "<DOMQL object-literal source string>" } }. Include only the sections you produce; each value is the DOMQL source for that key.',"Keys are PascalCase. Default to a single page unless the request clearly needs several distinct pages/components.","Emit ONLY the single fenced block. No text before or after it."].join(`
105
- `),H_={Starter:hn,Free:hn,Pro:"claude-opus-4-6"};function QE(t){return t?H_[t]||t:hn}var t1={"@symbo.ls/signal":Ep,"@symbo.ls/scratch":ay,"@symbo.ls/element":mb,"@symbo.ls/css":by,"@symbo.ls/utils":Wo,"@symbo.ls/state":Zy,"@symbo.ls/router":Cc,"@symbo.ls/polyglot":m_,"@symbo.ls/helmet":h_,"@symbo.ls/fetch":df,"@symbo.ls/capsize":b_,"@symbo.ls/shorthand":C_,"@symbo.ls/analyze":F_,"@symbo.ls/inspect":B_,"@symbo.ls/channels":U_,"@symbo-ls/simone-server":W_},e1=(t,e)=>{let r=t||(typeof globalThis<"u"?globalThis:{}),n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in t1)n[o]||(n[o]=t1[o]);if(e)for(let o in e)n[o]||(n[o]=e[o]);return n},r1=(t,e)=>{let r=t||(typeof globalThis<"u"?globalThis:null);if(!r||!e||typeof e!="object")return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in e){let s=e[o];if(typeof s!="function"||Object.prototype.hasOwnProperty.call(n,o))continue;let i=a=>(Object.defineProperty(n,o,{configurable:!0,enumerable:!0,writable:!0,value:a}),a);Object.defineProperty(n,o,{configurable:!0,enumerable:!0,get:()=>i(s()),set:i})}return n},n1=["@symbo.ls/sdk"],o1=(t,e)=>{let r=e||(typeof globalThis<"u"?globalThis:null);if(!r||!t||typeof t!="object")return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in t){let s=t[o];!s||typeof s!="object"&&typeof s!="function"||n[o]||(n[o]=s)}return n},iI=/^@symbo[-.]ls\//,aI=t=>t.includes("/")?t.slice(t.indexOf("/")+1):t,s1=(t,e)=>{let r=e||(typeof globalThis<"u"?globalThis:null);if(!r||!Array.isArray(t))return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o of t){let s=o&&o.library?o.library:o;if(!s||typeof s!="object"||s.__isStub)continue;let i=s.key||s.name||s.__libraryKey,a=[];for(let c of[s.key,s.name,s.__libraryKey,s.__libraryName]){if(typeof c!="string"||!c||c!==i&&!iI.test(c))continue;let l=aI(c);l&&!a.includes(l)&&a.push(l)}for(let c of a)for(let l of[`@symbo-ls/${c}`,`@symbo.ls/${c}`])n[l]||(n[l]=s)}return n};D();var i1=t=>{let e={faces:0,links:0};if(!t)return e;for(let r in t){let n=t[r];if(!n||!n.fontFace)continue;let o=Array.isArray(n.fontFace)?n.fontFace:[n.fontFace];for(let s of o){if(a1(s)){let i=lI(s);i&&fI(i)&&e.links++;continue}if(cI(s)){wt(s.trim()),e.faces++;continue}typeof s=="string"&&s.includes("font-family")&&(wt(`@font-face { ${s} }`),e.faces++)}}return e},a1=t=>typeof t=="string"&&t.trim().startsWith("@import"),cI=t=>typeof t=="string"&&t.trim().startsWith("@font-face"),lI=t=>{if(!a1(t))return null;let e=String(t).match(/url\(\s*['"]?([^'")]+)['"]?\s*\)/);return e?e[1].trim():null},fI=(t,e)=>{if(typeof t!="string"||!t)return null;let r=e||Jn();if(!r||!r.head)return null;let n="data-smbls-font",o=r.head.querySelectorAll(`link[rel="stylesheet"][${n}]`);for(let i=0;i<o.length;i++)if(o[i].getAttribute(n)===t)return o[i];let s=r.createElement("link");return s.setAttribute("rel","stylesheet"),s.setAttribute("href",t),s.setAttribute(n,t),r.head.appendChild(s),s};var u1=t=>{let e=typeof window<"u"?window:globalThis||{};e.document||(e.document={body:{}});let r=typeof document<"u"?document:e.document;t.document=t.document||r;let n=t.window;return n&&n!==e&&typeof n.URL!="function"?(typeof console<"u"&&console.warn&&!globalThis.__smblsRouterUrlWarned&&(globalThis.__smblsRouterUrlWarned=!0,console.warn("[smbls/router] context.window lacks URL, falling back to globalThis \u2014 passed-in window may be a stub (warned once; applies to every embed app this session)")),t.window=e):t.window=n||e,t.window},c1=(t="smbls")=>{let e={};for(let r in oo)Object.prototype.hasOwnProperty.call(oo,r)&&(Xe(r)?e[`smbls.${r}`]=oo[r]:e[r]=oo[r]);return e},d1=t=>t.components?{...c1(),...t.components}:c1(),p1=t=>({...Ac,...Cc,...Gr,...t.utils,...t.snippets,...t.functions}),h1=t=>({...t.methods||{},require:t.utils.require,requireOnDemand:t.utils.requireOnDemand,router:t.utils.router});var g1=t=>typeof globalThis<"u"&&globalThis.__SMBLS_PKGS__&&globalThis.__SMBLS_PKGS__[t]||null,uI=3e3,dI=(t,e,r=n=>import(n))=>{if(typeof globalThis>"u")return Promise.resolve(null);try{let n=globalThis.__SMBLS_PKGS__||(globalThis.__SMBLS_PKGS__={});if(n[t])return Promise.resolve(n[t]);let o=Promise.resolve().then(()=>r(e)).then(i=>(i&&!n[t]&&(n[t]=i),n[t]||null)).catch(()=>null);return new Promise(i=>{let a=setTimeout(()=>i(null),uI);o.then(c=>{clearTimeout(a),i(c)})})}catch{return Promise.resolve(null)}},l1={},Y_=async({dependencies:t,dependenciesOnDemand:e,document:r,preventCaching:n=!1,cdnProvider:o,packageManager:s,symbolsConfig:i,registerDependency:a=dI})=>{if(o||(o=zr[s]||Bo(i)||"esmsh"),!t)return null;if(!$n(t))return console.warn(`[smbls] dependencies is ${Array.isArray(t)?"an ARRAY":`a ${typeof t}`}, not a package-name-keyed object \u2014 skipping the CDN fetch loop. This usually means a project's config.js declares its own "dependencies" field that collides with the platform package map once context.js spreads them together.`),null;let c=!1;for(let d in t){c=!0;break}if(!c)return null;let l=Br()&&n?`?${Math.random()}`:"",f=async(d,g)=>{let p=Me(d,g,o)+l;try{await Promise.race([Vo(p,{document:r,type:"module"}),new Promise((h,m)=>setTimeout(()=>m(new Error(`Timeout loading ${d}`)),1e4))]),await a(d,p)}catch(h){if(console.error(`Failed to load ${d} from ${o}:`,h),o!=="symbols")try{let m=Me(d,g,"symbols")+l;await Promise.race([Vo(m,{document:r,type:"module"}),new Promise((_,x)=>setTimeout(()=>x(new Error(`Timeout fallback ${d}`)),2e4))]),console.log(`Successfully loaded ${d} from fallback (symbols.ls)`),await a(d,m)}catch(m){console.error(`Failed to load ${d} from fallback:`,m)}}},u=[];for(let d in t){let g=t[d];if(!(e&&e[d])&&!l1[d]&&(l1[d]=!0,!Hr(d))){if(In(d)){console.warn(`[smbls] dependency "${d}" looks like an un-interpolated template placeholder, not a real package specifier \u2014 skipping the CDN fetch (this is a bug upstream of the dependency loader, not a network failure).`);continue}g1(d)||u.push(f(d,g))}}return u.length&&await Promise.allSettled(u),t},f1=/\[smbls\] runtime dependency "([^"]+)" is not registered on globalThis\.__SMBLS_PKGS__/g,pI=t=>{if(typeof t=="string")return t;if(typeof t=="function")try{return typeof Le=="function"?Le(t):Function.prototype.toString.call(t)}catch{return""}return""},hI=t=>{let e=new Set;if(!t)return e;let r=[t.globalScope,t.functions,t.methods,t.snippets];for(let n=0;n<r.length;n++){let o=r[n];if(!o||typeof o!="object")continue;let s=Object.keys(o);for(let i=0;i<s.length;i++){let a;try{a=o[s[i]]}catch{continue}let c=pI(a);if(!c||c.indexOf("__SMBLS_PKGS__")===-1)continue;f1.lastIndex=0;let l;for(;(l=f1.exec(c))!==null;)e.add(l[1])}}return e},gI=t=>{let e=new Set;if(!t||typeof t.querySelectorAll!="function")return e;let r;try{r=t.querySelectorAll('script[type="importmap"]')}catch{return e}for(let n=0;n<r.length;n++){let o;try{o=JSON.parse(r[n].textContent||"")}catch{continue}let s=o&&typeof o=="object"?o.imports:null;if(s&&typeof s=="object"){let i=Object.keys(s);for(let a=0;a<i.length;a++)e.add(i[a])}}return e},mI=(t,e)=>{if(!e||!e.size)return!1;if(e.has(t))return!0;for(let r of e)if(r.length>1&&r.endsWith("/")&&t.length>r.length&&t.startsWith(r))return!0;return!1},m1=(t,{syncRead:e=hI(t),runtimeDocument:r=typeof document<"u"?document:null,importMap:n=gI(r)}={})=>{let o=t&&t.dependencies;if(!$n(o))return null;let s=!t.document||t.document===r,i=t.dependenciesOnDemand,a=null,c=null;for(let l in o)s&&!(i&&i[l])&&!e.has(l)&&mI(l,n)?(c||(c={}))[l]=o[l]:(a||(a={}))[l]=o[l];return{blocking:a,deferred:c}},yI=t=>import(t),q_={},bI=(t,e)=>{if(!e||typeof globalThis>"u")return;let r=globalThis.__SMBLS_PKGS__||(globalThis.__SMBLS_PKGS__={});r[t]||(r[t]=e)},_I=(t,{importModule:e=yI}={})=>{let r=[];if(!t)return Promise.resolve([]);for(let n in t)Hr(n)||In(n)||g1(n)||(q_[n]||(q_[n]=Promise.resolve().then(()=>e(n)).then(o=>(bI(n,o),o||null),()=>null)),r.push(q_[n]));return Promise.all(r)},wI=2e3,xI=3e3,y1=(t,{win:e=typeof window<"u"?window:null,importModule:r,loadTimeoutMs:n=xI}={})=>t?new Promise(o=>{let s=()=>{_I(t,{importModule:r}).then(o,o)},i=()=>{e&&typeof e.requestIdleCallback=="function"?e.requestIdleCallback(s,{timeout:wI}):setTimeout(s,0)},a=e&&e.document;if(a&&a.readyState&&a.readyState!=="complete"&&typeof e.addEventListener=="function"){let c=!0,l=null,f=()=>{c&&(c=!1,clearTimeout(l),typeof e.removeEventListener=="function"&&e.removeEventListener("load",f),i())};e.addEventListener("load",f,{once:!0}),l=setTimeout(f,n)}else i()}):null,b1=async(t,e)=>{let r=e.window||window,n=e.cdnProvider||Bo(e.symbolsConfig)||"esmsh",o=async i=>async(a,c)=>{let f=(i.window||window).packages[a];return typeof f=="function"?f():f},s=async i=>async(a,c=n)=>{let{dependenciesOnDemand:l}=i,f=i.document||document,u=i.window||window;if(!u.packages[a]&&Hr(a))return await u.require(a,c);if(!u.packages[a]){let d=Br()?`?${Math.random()}`:"";if(l&&l[a]){let g=l[a],p=Me(a,g,c)+d;try{await i.utils.loadRemoteScript(p,{window:u,document:f})}catch(h){if(console.error(`Failed to load ${a} from ${c}:`,h),c!=="symbols"){let m=Me(a,g,"symbols")+d;await i.utils.loadRemoteScript(m,{window:u,document:f})}}}else{let g=Me(a,"latest",c)+d;try{await i.utils.loadRemoteScript(g,{window:u,document:f})}catch(p){if(console.error(`Failed to load ${a} from ${c}:`,p),c!=="symbols"){let h=Me(a,"latest","symbols")+d;await i.utils.loadRemoteScript(h,{window:u,document:f})}}u.packages[a]="loadedOnDeman"}}return await u.require(a,c)};r.packages?r.packages=bt(r.packages,t):r.packages=t,r.require||(e.utils.require=await o(e),r.require=e.utils.require),r.requireOnDemand||(e.utils.requireOnDemand=await s(e),r.requireOnDemand=e.utils.requireOnDemand)},SI=/\s+/g,_1=(t,e)=>typeof t=="function"?t(e,e?.state,e?.context):t,kI=(t,e)=>{let r="";for(let n in t){let o=t[n];typeof o=="boolean"&&o?r+=` ${n}`:typeof o=="string"?r+=` ${o}`:typeof o=="function"&&(r+=` ${_1(o,e)}`)}return r},vI=(t,e,r)=>{if(!t)return;let{key:n}=e;t===!0&&(t=e.classlist={key:n}),typeof t=="string"&&(t=e.classlist={default:t}),t!==null&&typeof t=="object"&&!Array.isArray(t)&&(t=kI(t,e));let o=t.replace(SI," ").trim();if(r&&typeof r.setAttribute=="function")r.setAttribute("class",o);else if(r)try{r.className=o}catch{}return o},CI=()=>(t,e,r)=>{let n=_1(t,e);if(t){let{__ref:o}=e;o.__class.style=n}w1()(e.classlist,e,e.state,!0)},w1=()=>(t,e,r,n)=>{if(e.style&&!n)return;let{__ref:o}=e,{__class:s,__classNames:i}=o;if(!(t===null||typeof t!="object"||Array.isArray(t))){e.class&&(i.classProps=e.class),e.attr?.class&&(i.class=e.attr.class);for(let a in s){let c=s[a];if(!c){delete i[a];continue}let l;typeof c=="string"||typeof c=="number"?l=c:typeof c=="boolean"?l=e.key:l=he(c),i[a]=l}for(let a in i)a==="classProps"||a==="class"||s[a]===void 0&&delete i[a];e.node&&vI(i,e,e.node)}},EI=()=>({style:CI(),classlist:w1()}),AI=["useReset","useVariable","useFontImport","useIconSprite","useSvgSprite","useDocumentTheme","useDefaultIcons","useDefaultConfig","verbose","globalTheme"],K_=new WeakSet,G_=!1,TI=t=>!!t&&typeof t=="object",x1=(t,e)=>{let r=e.document||(e.parent&&e.parent.documentElement?e.parent:null)||document,n=e.initOptions||{},o=e.registry||EI(),s=e.designSystem?at(lt(e.designSystem),lt(kc),ue):lt(kc),i={};for(let h of AI)e[h]!==void 0&&(i[h]=e[h]);let a,c=TI(r),f=c&&K_.has(r)&&!e.skipDesignSystemInit,u=!f&&!G_,d=f?`[data-smbls-app="${t}"]`:":root";if(e.scopeSelector=d,e.skipDesignSystemInit){if(a=A(t)||A(),a&&(a.__domDocument=r),a?.CSS_VARS){ct(a);try{wt({[d]:a.CSS_VARS}),a.CSS_MEDIA_VARS&&wt(Ju(a.CSS_MEDIA_VARS,d));let h=Yn(a.cssSkinVars,a.cssSkinFallback,d);Object.keys(h).length&&wt(h)}finally{it()}}}else if(u){let h=A();h&&(h.__domDocument=r),a=Er(s,{key:t,document:r,files:e.files,assets:e.assets,scopeSelector:d,...ed,...i,...n}),a&&a!==h&&(a.__domDocument=r),c&&K_.add(r),G_=!0}else{let h=Ra(t,s,{cleanBase:!0});for(let m in i)h[m]=i[m];if(h.__domDocument=r,f){let m=t.replace(/[^a-zA-Z0-9]/g,"").substring(0,6);e.cssPrefix=m,h.varPrefix=m}ct(h);try{a=Er(h,{key:t,document:r,files:e.files,assets:e.assets,scopeSelector:d,...ed,...i,...n})}finally{it()}c&&K_.add(r),G_=!0}let g=a?.CONFIG||a,p=g?.font;if(p){ct(g);try{i1(p)}finally{it()}}return[a,o]},S1=(t,e)=>{let r={};e.state&&at(r,e.state),t&&t.state&&at(r,t.state);let n=e.polyglot;if(n?.translations){let o=null;try{typeof localStorage<"u"&&(o=localStorage.getItem(n.storageLangKey||"smbls_lang")||localStorage.getItem("lang"))}catch{}let s=o||r.lang||n.defaultLang||"en";o&&o!==r.lang&&(r.lang=o);let i=new Set,a=new Set,c=(u,d)=>{if(!a.has(u)){if(!Pn(e,u,r)){i.add(u);return}r[u]=d,a.add(u),Ze(e,u,d)}},l=n.translations[s];if(l&&typeof l=="object")for(let u in l)c(u,l[u]);let f=new Set(n.languages||[]);for(let u in n.translations)f.has(u)||c(u,n.translations[u]);i.size&&n.verbose!==!1&&e.verbose!==!1&&console.warn(`[polyglot] ${i.size} translation key${i.size===1?"":"s"} collide${i.size===1?"s":""} with a declared root-state key (${[...i].join(", ")}) \u2014 the declared value wins and the translation is NOT seeded into state. Rename the translation key, or read it with \`{{ key | polyglot }}\` instead of a bare \`{{ key }}\`.`)}return r.isRootState=!0,lt(r)},k1=(t,e)=>{v(t.routes)&&v(e.pages)&&bt(t.routes,e.pages);let r=t.routes||e.pages||{},n=[];for(let o in r){if(o.charCodeAt(0)===47)continue;let i="/"+(o==="index"?"":o);Object.prototype.hasOwnProperty.call(r,i)?n.push(`${o} -> ${i}`):r[i]=r[o],delete r[o]}return n.length&&e&&e.verbose!==!1&&console.warn(`[smbls] preparePages kept ${n.length} explicitly declared route${n.length===1?"":"s"} over a same-named page key (${n.join(", ")}). A bare page NAME never overwrites a declared '/route'. This usually means a shared library ships a page under its export name that collides with one of your routes \u2014 add it to that library's ignoreList if you did not intend the collision.`),r},v1=t=>{ya(t,t.sharedLibraries)};var Gc={polyglot:Dc,getLocalStateLang:Mc,getActiveLang:un,getLang:un,setLang:Ic,getLanguages:Pc,loadTranslations:Lc,upsertTranslation:$c};Ji();var He=Object.create(null);He.open="0";He.close="1";He.ping="2";He.pong="3";He.message="4";He.upgrade="5";He.noop="6";var Yc=Object.create(null);Object.keys(He).forEach(t=>{Yc[He[t]]=t});var Xc={type:"error",data:"parser error"};var A1=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",T1=typeof ArrayBuffer=="function",O1=t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t&&t.buffer instanceof ArrayBuffer,Zc=({type:t,data:e},r,n)=>A1&&e instanceof Blob?r?n(e):C1(e,n):T1&&(e instanceof ArrayBuffer||O1(e))?r?n(e):C1(new Blob([e]),n):n(He[t]+(e||"")),C1=(t,e)=>{let r=new FileReader;return r.onload=function(){let n=r.result.split(",")[1];e("b"+(n||""))},r.readAsDataURL(t)};function E1(t){return t instanceof Uint8Array?t:t instanceof ArrayBuffer?new Uint8Array(t):new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}var X_;function R1(t,e){if(A1&&t.data instanceof Blob)return t.data.arrayBuffer().then(E1).then(e);if(T1&&(t.data instanceof ArrayBuffer||O1(t.data)))return e(E1(t.data));Zc(t,!1,r=>{X_||(X_=new TextEncoder),e(X_.encode(r))})}var P1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Jc=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let t=0;t<P1.length;t++)Jc[P1.charCodeAt(t)]=t;var D1=t=>{let e=t.length*.75,r=t.length,n,o=0,s,i,a,c;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);let l=new ArrayBuffer(e),f=new Uint8Array(l);for(n=0;n<r;n+=4)s=Jc[t.charCodeAt(n)],i=Jc[t.charCodeAt(n+1)],a=Jc[t.charCodeAt(n+2)],c=Jc[t.charCodeAt(n+3)],f[o++]=s<<2|i>>4,f[o++]=(i&15)<<4|a>>2,f[o++]=(a&3)<<6|c&63;return l};var OI=typeof ArrayBuffer=="function",Qc=(t,e)=>{if(typeof t!="string")return{type:"message",data:L1(t,e)};let r=t.charAt(0);return r==="b"?{type:"message",data:RI(t.substring(1),e)}:Yc[r]?t.length>1?{type:Yc[r],data:t.substring(1)}:{type:Yc[r]}:Xc},RI=(t,e)=>{if(OI){let r=D1(t);return L1(r,e)}else return{base64:!0,data:t}},L1=(t,e)=>e==="blob"?t instanceof Blob?t:new Blob([t]):t instanceof ArrayBuffer?t:t.buffer;var I1="",$1=(t,e)=>{let r=t.length,n=new Array(r),o=0;t.forEach((s,i)=>{Zc(s,!1,a=>{n[i]=a,++o===r&&e(n.join(I1))})})},M1=(t,e)=>{let r=t.split(I1),n=[];for(let o=0;o<r.length;o++){let s=Qc(r[o],e);if(n.push(s),s.type==="error")break}return n};function F1(){return new TransformStream({transform(t,e){R1(t,r=>{let n=r.length,o;if(n<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,n);else if(n<65536){o=new Uint8Array(3);let s=new DataView(o.buffer);s.setUint8(0,126),s.setUint16(1,n)}else{o=new Uint8Array(9);let s=new DataView(o.buffer);s.setUint8(0,127),s.setBigUint64(1,BigInt(n))}t.data&&typeof t.data!="string"&&(o[0]|=128),e.enqueue(o),e.enqueue(r)})}})}var Z_;function Cd(t){return t.reduce((e,r)=>e+r.length,0)}function Ed(t,e){if(t[0].length===e)return t.shift();let r=new Uint8Array(e),n=0;for(let o=0;o<e;o++)r[o]=t[0][n++],n===t[0].length&&(t.shift(),n=0);return t.length&&n<t[0].length&&(t[0]=t[0].slice(n)),r}function N1(t,e){Z_||(Z_=new TextDecoder);let r=[],n=0,o=-1,s=!1;return new TransformStream({transform(i,a){for(r.push(i);;){if(n===0){if(Cd(r)<1)break;let c=Ed(r,1);s=(c[0]&128)===128,o=c[0]&127,o<126?n=3:o===126?n=1:n=2}else if(n===1){if(Cd(r)<2)break;let c=Ed(r,2);o=new DataView(c.buffer,c.byteOffset,c.length).getUint16(0),n=3}else if(n===2){if(Cd(r)<8)break;let c=Ed(r,8),l=new DataView(c.buffer,c.byteOffset,c.length),f=l.getUint32(0);if(f>Math.pow(2,21)-1){a.enqueue(Xc);break}o=f*Math.pow(2,32)+l.getUint32(4),n=3}else{if(Cd(r)<o)break;let c=Ed(r,o);a.enqueue(Qc(s?c:Z_.decode(c),e)),n=0}if(o===0||o>t){a.enqueue(Xc);break}}}})}var J_=4;function ht(t){if(t)return PI(t)}function PI(t){for(var e in ht.prototype)t[e]=ht.prototype[e];return t}ht.prototype.on=ht.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+t]=this._callbacks["$"+t]||[]).push(e),this};ht.prototype.once=function(t,e){function r(){this.off(t,r),e.apply(this,arguments)}return r.fn=e,this.on(t,r),this};ht.prototype.off=ht.prototype.removeListener=ht.prototype.removeAllListeners=ht.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var r=this._callbacks["$"+t];if(!r)return this;if(arguments.length==1)return delete this._callbacks["$"+t],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===e||n.fn===e){r.splice(o,1);break}return r.length===0&&delete this._callbacks["$"+t],this};ht.prototype.emit=function(t){this._callbacks=this._callbacks||{};for(var e=new Array(arguments.length-1),r=this._callbacks["$"+t],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,e)}return this};ht.prototype.emitReserved=ht.prototype.emit;ht.prototype.listeners=function(t){return this._callbacks=this._callbacks||{},this._callbacks["$"+t]||[]};ht.prototype.hasListeners=function(t){return!!this.listeners(t).length};var Tr=typeof Promise=="function"&&typeof Promise.resolve=="function"?e=>Promise.resolve().then(e):(e,r)=>r(e,0),Yt=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),j1="arraybuffer";function Ad(t,...e){return e.reduce((r,n)=>(t.hasOwnProperty(n)&&(r[n]=t[n]),r),{})}var DI=Yt.setTimeout,LI=Yt.clearTimeout;function Or(t,e){e.useNativeTimers?(t.setTimeoutFn=DI.bind(Yt),t.clearTimeoutFn=LI.bind(Yt)):(t.setTimeoutFn=Yt.setTimeout.bind(Yt),t.clearTimeoutFn=Yt.clearTimeout.bind(Yt))}var II=1.33;function B1(t){return typeof t=="string"?$I(t):Math.ceil((t.byteLength||t.size)*II)}function $I(t){let e=0,r=0;for(let n=0,o=t.length;n<o;n++)e=t.charCodeAt(n),e<128?r+=1:e<2048?r+=2:e<55296||e>=57344?r+=3:(n++,r+=4);return r}function Td(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function V1(t){let e="";for(let r in t)t.hasOwnProperty(r)&&(e.length&&(e+="&"),e+=encodeURIComponent(r)+"="+encodeURIComponent(t[r]));return e}function U1(t){let e={},r=t.split("&");for(let n=0,o=r.length;n<o;n++){let s=r[n].split("=");e[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}return e}var Od=class extends Error{constructor(e,r,n){super(e),this.description=r,this.context=n,this.type="TransportError"}},Rr=class extends ht{constructor(e){super(),this.writable=!1,Or(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,r,n){return super.emitReserved("error",new Od(e,r,n)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(e){this.readyState==="open"&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){let r=Qc(e,this.socket.binaryType);this.onPacket(r)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,r={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(r)}_hostname(){let e=this.opts.hostname;return e.indexOf(":")===-1?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(e){let r=V1(e);return r.length?"?"+r:""}};var tl=class extends Rr{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";let r=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let n=0;this._polling&&(n++,this.once("pollComplete",function(){--n||r()})),this.writable||(n++,this.once("drain",function(){--n||r()}))}else r()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){let r=n=>{if(this.readyState==="opening"&&n.type==="open"&&this.onOpen(),n.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(n)};M1(e,this.socket.binaryType).forEach(r),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){let e=()=>{this.write([{type:"close"}])};this.readyState==="open"?e():this.once("open",e)}write(e){this.writable=!1,$1(e,r=>{this.doWrite(r,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){let e=this.opts.secure?"https":"http",r=this.query||{};return this.opts.timestampRequests!==!1&&(r[this.opts.timestampParam]=Td()),!this.supportsBinary&&!r.sid&&(r.b64=1),this.createUri(e,r)}};var z1=!1;try{z1=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}var H1=z1;function MI(){}var Q_=class extends tl{constructor(e){if(super(e),typeof location<"u"){let r=location.protocol==="https:",n=location.port;n||(n=r?"443":"80"),this.xd=typeof location<"u"&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,r){let n=this.request({method:"POST",data:e});n.on("success",r),n.on("error",(o,s)=>{this.onError("xhr post error",o,s)})}doPoll(){let e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(r,n)=>{this.onError("xhr poll error",r,n)}),this.pollXhr=e}},gn=class t extends ht{constructor(e,r,n){super(),this.createRequest=e,Or(this,n),this._opts=n,this._method=n.method||"GET",this._uri=r,this._data=n.data!==void 0?n.data:null,this._create()}_create(){var e;let r=Ad(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");r.xdomain=!!this._opts.xd;let n=this._xhr=this.createRequest(r);try{n.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){n.setDisableHeaderCheck&&n.setDisableHeaderCheck(!0);for(let o in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(o)&&n.setRequestHeader(o,this._opts.extraHeaders[o])}}catch{}if(this._method==="POST")try{n.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{n.setRequestHeader("Accept","*/*")}catch{}(e=this._opts.cookieJar)===null||e===void 0||e.addCookies(n),"withCredentials"in n&&(n.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(n.timeout=this._opts.requestTimeout),n.onreadystatechange=()=>{var o;n.readyState===3&&((o=this._opts.cookieJar)===null||o===void 0||o.parseCookies(n.getResponseHeader("set-cookie"))),n.readyState===4&&(n.status===200||n.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof n.status=="number"?n.status:0)},0))},n.send(this._data)}catch(o){this.setTimeoutFn(()=>{this._onError(o)},0);return}typeof document<"u"&&(this._index=t.requestsCount++,t.requests[this._index]=this)}_onError(e){this.emitReserved("error",e,this._xhr),this._cleanup(!0)}_cleanup(e){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=MI,e)try{this._xhr.abort()}catch{}typeof document<"u"&&delete t.requests[this._index],this._xhr=null}}_onLoad(){let e=this._xhr.responseText;e!==null&&(this.emitReserved("data",e),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};gn.requestsCount=0;gn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",W1);else if(typeof addEventListener=="function"){let t="onpagehide"in Yt?"pagehide":"unload";addEventListener(t,W1,!1)}}function W1(){for(let t in gn.requests)gn.requests.hasOwnProperty(t)&&gn.requests[t].abort()}var FI=(function(){let t=q1({xdomain:!1});return t&&t.responseType!==null})(),mn=class extends Q_{constructor(e){super(e);let r=e&&e.forceBase64;this.supportsBinary=FI&&!r}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new gn(q1,this.uri(),e)}};function q1(t){let e=t.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!e||H1))return new XMLHttpRequest}catch{}if(!e)try{return new Yt[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}var K1=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative",ew=class extends Rr{get name(){return"websocket"}doOpen(){let e=this.uri(),r=this.opts.protocols,n=K1?{}:Ad(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,r,n)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let r=0;r<e.length;r++){let n=e[r],o=r===e.length-1;Zc(n,this.supportsBinary,s=>{try{this.doWrite(n,s)}catch{}o&&Tr(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?"wss":"ws",r=this.query||{};return this.opts.timestampRequests&&(r[this.opts.timestampParam]=Td()),this.supportsBinary||(r.b64=1),this.createUri(e,r)}},tw=Yt.WebSocket||Yt.MozWebSocket,yn=class extends ew{createSocket(e,r,n){return K1?new tw(e,r,n):r?new tw(e,r):new tw(e)}doWrite(e,r){this.ws.send(r)}};var Vs=class extends Rr{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved("error",e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let r=N1(Number.MAX_SAFE_INTEGER,this.socket.binaryType),n=e.readable.pipeThrough(r).getReader(),o=F1();o.readable.pipeTo(e.writable),this._writer=o.writable.getWriter();let s=()=>{n.read().then(({done:a,value:c})=>{a||(this.onPacket(c),s())}).catch(a=>{})};s();let i={type:"open"};this.query.sid&&(i.data=`{"sid":"${this.query.sid}"}`),this._writer.write(i).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let r=0;r<e.length;r++){let n=e[r],o=r===e.length-1;this._writer.write(n).then(()=>{o&&Tr(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)===null||e===void 0||e.close()}};var rw={websocket:yn,webtransport:Vs,polling:mn};var NI=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,jI=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Us(t){if(t.length>8e3)throw"URI too long";let e=t,r=t.indexOf("["),n=t.indexOf("]");r!=-1&&n!=-1&&(t=t.substring(0,r)+t.substring(r,n).replace(/:/g,";")+t.substring(n,t.length));let o=NI.exec(t||""),s={},i=14;for(;i--;)s[jI[i]]=o[i]||"";return r!=-1&&n!=-1&&(s.source=e,s.host=s.host.substring(1,s.host.length-1).replace(/;/g,":"),s.authority=s.authority.replace("[","").replace("]","").replace(/;/g,":"),s.ipv6uri=!0),s.pathNames=BI(s,s.path),s.queryKey=VI(s,s.query),s}function BI(t,e){let r=/\/{2,9}/g,n=e.replace(r,"/").split("/");return(e.slice(0,1)=="/"||e.length===0)&&n.splice(0,1),e.slice(-1)=="/"&&n.splice(n.length-1,1),n}function VI(t,e){let r={};return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(n,o,s){o&&(r[o]=s)}),r}var nw=typeof addEventListener=="function"&&typeof removeEventListener=="function",Rd=[];nw&&addEventListener("offline",()=>{Rd.forEach(t=>t())},!1);var po=class t extends ht{constructor(e,r){if(super(),this.binaryType=j1,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&typeof e=="object"&&(r=e,e=null),e){let n=Us(e);r.hostname=n.host,r.secure=n.protocol==="https"||n.protocol==="wss",r.port=n.port,n.query&&(r.query=n.query)}else r.host&&(r.hostname=Us(r.host).host);Or(this,r),this.secure=r.secure!=null?r.secure:typeof location<"u"&&location.protocol==="https:",r.hostname&&!r.port&&(r.port=this.secure?"443":"80"),this.hostname=r.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=r.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},r.transports.forEach(n=>{let o=n.prototype.name;this.transports.push(o),this._transportsByName[o]=n}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},r),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=U1(this.opts.query)),nw&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Rd.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){let r=Object.assign({},this.opts.query);r.EIO=J_,r.transport=e,this.id&&(r.sid=this.id);let n=Object.assign({},this.opts,{query:r,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let e=this.opts.rememberUpgrade&&t.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";let r=this.createTransport(e);r.open(),this.setTransport(r)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",r=>this._onClose("transport close",r))}onOpen(){this.readyState="open",t.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(e){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",e),this.emitReserved("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":let r=new Error("server error");r.code=e.data,this._onError(r);break;case"message":this.emitReserved("data",e.data),this.emitReserved("message",e.data);break}}onHandshake(e){this.emitReserved("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let r=1;for(let n=0;n<this.writeBuffer.length;n++){let o=this.writeBuffer[n].data;if(o&&(r+=B1(o)),n>0&&r>this._maxPayload)return this.writeBuffer.slice(0,n);r+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,Tr(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),e}write(e,r,n){return this._sendPacket("message",e,r,n),this}send(e,r,n){return this._sendPacket("message",e,r,n),this}_sendPacket(e,r,n,o){if(typeof r=="function"&&(o=r,r=void 0),typeof n=="function"&&(o=n,n=null),this.readyState==="closing"||this.readyState==="closed")return;n=n||{},n.compress=n.compress!==!1;let s={type:e,data:r,options:n};this.emitReserved("packetCreate",s),this.writeBuffer.push(s),o&&this.once("flush",o),this.flush()}close(){let e=()=>{this._onClose("forced close"),this.transport.close()},r=()=>{this.off("upgrade",r),this.off("upgradeError",r),e()},n=()=>{this.once("upgrade",r),this.once("upgradeError",r)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(e){if(t.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",e),this._onClose("transport error",e)}_onClose(e,r){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),nw&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){let n=Rd.indexOf(this._offlineEventListener);n!==-1&&Rd.splice(n,1)}this.readyState="closed",this.id=null,this.emitReserved("close",e,r),this.writeBuffer=[],this._prevBufferLen=0}}};po.protocol=J_;var Pd=class extends po{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let r=this.createTransport(e),n=!1;po.priorWebsocketSuccess=!1;let o=()=>{n||(r.send([{type:"ping",data:"probe"}]),r.once("packet",u=>{if(!n)if(u.type==="pong"&&u.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",r),!r)return;po.priorWebsocketSuccess=r.name==="websocket",this.transport.pause(()=>{n||this.readyState!=="closed"&&(f(),this.setTransport(r),r.send([{type:"upgrade"}]),this.emitReserved("upgrade",r),r=null,this.upgrading=!1,this.flush())})}else{let d=new Error("probe error");d.transport=r.name,this.emitReserved("upgradeError",d)}}))};function s(){n||(n=!0,f(),r.close(),r=null)}let i=u=>{let d=new Error("probe error: "+u);d.transport=r.name,s(),this.emitReserved("upgradeError",d)};function a(){i("transport closed")}function c(){i("socket closed")}function l(u){r&&u.name!==r.name&&s()}let f=()=>{r.removeListener("open",o),r.removeListener("error",i),r.removeListener("close",a),this.off("close",c),this.off("upgrading",l)};r.once("open",o),r.once("error",i),r.once("close",a),this.once("close",c),this.once("upgrading",l),this._upgrades.indexOf("webtransport")!==-1&&e!=="webtransport"?this.setTimeoutFn(()=>{n||r.open()},200):r.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let r=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&r.push(e[n]);return r}},zs=class extends Pd{constructor(e,r={}){let n=typeof e=="object"?e:r;(!n.transports||n.transports&&typeof n.transports[0]=="string")&&(n.transports=(n.transports||["polling","websocket","webtransport"]).map(o=>rw[o]).filter(o=>!!o)),super(e,n)}};var cz=zs.protocol;function G1(t,e="",r){let n=t;r=r||typeof location<"u"&&location,t==null&&(t=r.protocol+"//"+r.host),typeof t=="string"&&(t.charAt(0)==="/"&&(t.charAt(1)==="/"?t=r.protocol+t:t=r.host+t),/^(https?|wss?):\/\//.test(t)||(typeof r<"u"?t=r.protocol+"//"+t:t="https://"+t),n=Us(t)),n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443")),n.path=n.path||"/";let s=n.host.indexOf(":")!==-1?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+s+":"+n.port+e,n.href=n.protocol+"://"+s+(r&&r.port===n.port?"":":"+n.port),n}var fw={};$(fw,{Decoder:()=>cw,Encoder:()=>aw,PacketType:()=>H,isPacketValid:()=>c$,protocol:()=>sA});var zI=typeof ArrayBuffer=="function",HI=t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer,Y1=Object.prototype.toString,WI=typeof Blob=="function"||typeof Blob<"u"&&Y1.call(Blob)==="[object BlobConstructor]",qI=typeof File=="function"||typeof File<"u"&&Y1.call(File)==="[object FileConstructor]";function rl(t){return zI&&(t instanceof ArrayBuffer||HI(t))||WI&&t instanceof Blob||qI&&t instanceof File}function el(t,e){if(!t||typeof t!="object")return!1;if(Array.isArray(t)){for(let r=0,n=t.length;r<n;r++)if(el(t[r]))return!0;return!1}if(rl(t))return!0;if(t.toJSON&&typeof t.toJSON=="function"&&arguments.length===1)return el(t.toJSON(),!0);for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&el(t[r]))return!0;return!1}function X1(t){let e=[],r=t.data,n=t;return n.data=ow(r,e),n.attachments=e.length,{packet:n,buffers:e}}function ow(t,e){if(!t)return t;if(rl(t)){let r={_placeholder:!0,num:e.length};return e.push(t),r}else if(Array.isArray(t)){let r=new Array(t.length);for(let n=0;n<t.length;n++)r[n]=ow(t[n],e);return r}else if(typeof t=="object"&&!(t instanceof Date)){let r={};for(let n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=ow(t[n],e));return r}return t}function Z1(t,e){return t.data=sw(t.data,e),delete t.attachments,t}function sw(t,e){if(!t)return t;if(t&&t._placeholder===!0){if(typeof t.num=="number"&&t.num>=0&&t.num<e.length)return e[t.num];throw new Error("illegal attachments")}else if(Array.isArray(t))for(let r=0;r<t.length;r++)t[r]=sw(t[r],e);else if(typeof t=="object")for(let r in t)Object.prototype.hasOwnProperty.call(t,r)&&(t[r]=sw(t[r],e));return t}var nA=eT(rA(),1),iw=(0,nA.default)("socket.io-parser"),oA=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],sA=5,H;(function(t){t[t.CONNECT=0]="CONNECT",t[t.DISCONNECT=1]="DISCONNECT",t[t.EVENT=2]="EVENT",t[t.ACK=3]="ACK",t[t.CONNECT_ERROR=4]="CONNECT_ERROR",t[t.BINARY_EVENT=5]="BINARY_EVENT",t[t.BINARY_ACK=6]="BINARY_ACK"})(H||(H={}));var aw=class{constructor(e){this.replacer=e}encode(e){return iw("encoding packet %j",e),(e.type===H.EVENT||e.type===H.ACK)&&el(e)?this.encodeAsBinary({type:e.type===H.EVENT?H.BINARY_EVENT:H.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let r=""+e.type;return(e.type===H.BINARY_EVENT||e.type===H.BINARY_ACK)&&(r+=e.attachments+"-"),e.nsp&&e.nsp!=="/"&&(r+=e.nsp+","),e.id!=null&&(r+=e.id),e.data!=null&&(r+=JSON.stringify(e.data,this.replacer)),iw("encoded %j as %s",e,r),r}encodeAsBinary(e){let r=X1(e),n=this.encodeAsString(r.packet),o=r.buffers;return o.unshift(n),o}},cw=class t extends ht{constructor(e){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof e=="function"?{reviver:e}:e)}add(e){let r;if(typeof e=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");r=this.decodeString(e);let n=r.type===H.BINARY_EVENT;n||r.type===H.BINARY_ACK?(r.type=n?H.EVENT:H.ACK,this.reconstructor=new lw(r),r.attachments===0&&super.emitReserved("decoded",r)):super.emitReserved("decoded",r)}else if(rl(e)||e.base64)if(this.reconstructor)r=this.reconstructor.takeBinaryData(e),r&&(this.reconstructor=null,super.emitReserved("decoded",r));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+e)}decodeString(e){let r=0,n={type:Number(e.charAt(0))};if(H[n.type]===void 0)throw new Error("unknown packet type "+n.type);if(n.type===H.BINARY_EVENT||n.type===H.BINARY_ACK){let s=r+1;for(;e.charAt(++r)!=="-"&&r!=e.length;);let i=e.substring(s,r);if(i!=Number(i)||e.charAt(r)!=="-")throw new Error("Illegal attachments");let a=Number(i);if(!iA(a)||a<0)throw new Error("Illegal attachments");if(a>this.opts.maxAttachments)throw new Error("too many attachments");n.attachments=a}if(e.charAt(r+1)==="/"){let s=r+1;for(;++r&&!(e.charAt(r)===","||r===e.length););n.nsp=e.substring(s,r)}else n.nsp="/";let o=e.charAt(r+1);if(o!==""&&Number(o)==o){let s=r+1;for(;++r;){let i=e.charAt(r);if(i==null||Number(i)!=i){--r;break}if(r===e.length)break}n.id=Number(e.substring(s,r+1))}if(e.charAt(++r)){let s=this.tryParse(e.substr(r));if(t.isPayloadValid(n.type,s))n.data=s;else throw new Error("invalid payload")}return iw("decoded %s as %j",e,n),n}tryParse(e){try{return JSON.parse(e,this.opts.reviver)}catch{return!1}}static isPayloadValid(e,r){switch(e){case H.CONNECT:return Id(r);case H.DISCONNECT:return r===void 0;case H.CONNECT_ERROR:return typeof r=="string"||Id(r);case H.EVENT:case H.BINARY_EVENT:return Array.isArray(r)&&(typeof r[0]=="number"||typeof r[0]=="string"&&oA.indexOf(r[0])===-1);case H.ACK:case H.BINARY_ACK:return Array.isArray(r)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}},lw=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let r=Z1(this.reconPack,this.buffers);return this.finishedReconstruction(),r}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function s$(t){return typeof t=="string"}var iA=Number.isInteger||function(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t};function i$(t){return t===void 0||iA(t)}function Id(t){return Object.prototype.toString.call(t)==="[object Object]"}function a$(t,e){switch(t){case H.CONNECT:return e===void 0||Id(e);case H.DISCONNECT:return e===void 0;case H.EVENT:return Array.isArray(e)&&(typeof e[0]=="number"||typeof e[0]=="string"&&oA.indexOf(e[0])===-1);case H.ACK:return Array.isArray(e);case H.CONNECT_ERROR:return typeof e=="string"||Id(e);default:return!1}}function c$(t){return s$(t.nsp)&&i$(t.id)&&a$(t.type,t.data)}function ye(t,e,r){return t.on(e,r),function(){t.off(e,r)}}var l$=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),Ks=class extends ht{constructor(e,r,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=r,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[ye(e,"open",this.onopen.bind(this)),ye(e,"packet",this.onpacket.bind(this)),ye(e,"error",this.onerror.bind(this)),ye(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...r){var n,o,s;if(l$.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(r.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(r),this;let i={type:H.EVENT,data:r};if(i.options={},i.options.compress=this.flags.compress!==!1,typeof r[r.length-1]=="function"){let f=this.ids++,u=r.pop();this._registerAckCallback(f,u),i.id=f}let a=(o=(n=this.io.engine)===null||n===void 0?void 0:n.transport)===null||o===void 0?void 0:o.writable,c=this.connected&&!(!((s=this.io.engine)===null||s===void 0)&&s._hasPingExpired());return this.flags.volatile&&!a||(c?(this.notifyOutgoingListeners(i),this.packet(i)):this.sendBuffer.push(i)),this.flags={},this}_registerAckCallback(e,r){var n;let o=(n=this.flags.timeout)!==null&&n!==void 0?n:this._opts.ackTimeout;if(o===void 0){this.acks[e]=r;return}let s=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let a=0;a<this.sendBuffer.length;a++)this.sendBuffer[a].id===e&&this.sendBuffer.splice(a,1);r.call(this,new Error("operation has timed out"))},o),i=(...a)=>{this.io.clearTimeoutFn(s),r.apply(this,a)};i.withError=!0,this.acks[e]=i}emitWithAck(e,...r){return new Promise((n,o)=>{let s=(i,a)=>i?o(i):n(a);s.withError=!0,r.push(s),this.emit(e,...r)})}_addToQueue(e){let r;typeof e[e.length-1]=="function"&&(r=e.pop());let n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((o,...s)=>(this._queue[0],o!==null?n.tryCount>this._opts.retries&&(this._queue.shift(),r&&r(o)):(this._queue.shift(),r&&r(null,...s)),n.pending=!1,this._drainQueue())),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let r=this._queue[0];r.pending&&!e||(r.pending=!0,r.tryCount++,this.flags=r.flags,this.emit.apply(this,r.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth=="function"?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:H.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,r){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,r),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(n=>String(n.id)===e)){let n=this.acks[e];delete this.acks[e],n.withError&&n.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case H.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case H.EVENT:case H.BINARY_EVENT:this.onevent(e);break;case H.ACK:case H.BINARY_ACK:this.onack(e);break;case H.DISCONNECT:this.ondisconnect();break;case H.CONNECT_ERROR:this.destroy();let n=new Error(e.data.message);n.data=e.data.data,this.emitReserved("connect_error",n);break}}onevent(e){let r=e.data||[];e.id!=null&&r.push(this.ack(e.id)),this.connected?this.emitEvent(r):this.receiveBuffer.push(Object.freeze(r))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let r=this._anyListeners.slice();for(let n of r)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]=="string"&&(this._lastOffset=e[e.length-1])}ack(e){let r=this,n=!1;return function(...o){n||(n=!0,r.packet({type:H.ACK,id:e,data:o}))}}onack(e){let r=this.acks[e.id];typeof r=="function"&&(delete this.acks[e.id],r.withError&&e.data.unshift(null),r.apply(this,e.data))}onconnect(e,r){this.id=e,this.recovered=r&&this._pid===r,this._pid=r,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved("connect")}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:H.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let r=this._anyListeners;for(let n=0;n<r.length;n++)if(e===r[n])return r.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let r=this._anyOutgoingListeners;for(let n=0;n<r.length;n++)if(e===r[n])return r.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let r=this._anyOutgoingListeners.slice();for(let n of r)n.apply(this,e.data)}}};function go(t){t=t||{},this.ms=t.min||100,this.max=t.max||1e4,this.factor=t.factor||2,this.jitter=t.jitter>0&&t.jitter<=1?t.jitter:0,this.attempts=0}go.prototype.duration=function(){var t=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var e=Math.random(),r=Math.floor(e*this.jitter*t);t=(Math.floor(e*10)&1)==0?t-r:t+r}return Math.min(t,this.max)|0};go.prototype.reset=function(){this.attempts=0};go.prototype.setMin=function(t){this.ms=t};go.prototype.setMax=function(t){this.max=t};go.prototype.setJitter=function(t){this.jitter=t};var Gs=class extends ht{constructor(e,r){var n;super(),this.nsps={},this.subs=[],e&&typeof e=="object"&&(r=e,e=void 0),r=r||{},r.path=r.path||"/socket.io",this.opts=r,Or(this,r),this.reconnection(r.reconnection!==!1),this.reconnectionAttempts(r.reconnectionAttempts||1/0),this.reconnectionDelay(r.reconnectionDelay||1e3),this.reconnectionDelayMax(r.reconnectionDelayMax||5e3),this.randomizationFactor((n=r.randomizationFactor)!==null&&n!==void 0?n:.5),this.backoff=new go({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(r.timeout==null?2e4:r.timeout),this._readyState="closed",this.uri=e;let o=r.parser||fw;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=r.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var r;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(r=this.backoff)===null||r===void 0||r.setMin(e),this)}randomizationFactor(e){var r;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(r=this.backoff)===null||r===void 0||r.setJitter(e),this)}reconnectionDelayMax(e){var r;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(r=this.backoff)===null||r===void 0||r.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new zs(this.uri,this.opts);let r=this.engine,n=this;this._readyState="opening",this.skipReconnect=!1;let o=ye(r,"open",function(){n.onopen(),e&&e()}),s=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),e?e(a):this.maybeReconnectOnOpen()},i=ye(r,"error",s);if(this._timeout!==!1){let a=this._timeout,c=this.setTimeoutFn(()=>{o(),s(new Error("timeout")),r.close()},a);this.opts.autoUnref&&c.unref(),this.subs.push(()=>{this.clearTimeoutFn(c)})}return this.subs.push(o),this.subs.push(i),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let e=this.engine;this.subs.push(ye(e,"ping",this.onping.bind(this)),ye(e,"data",this.ondata.bind(this)),ye(e,"error",this.onerror.bind(this)),ye(e,"close",this.onclose.bind(this)),ye(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(r){this.onclose("parse error",r)}}ondecoded(e){Tr(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,r){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new Ks(this,e,r),this.nsps[e]=n),n}_destroy(e){let r=Object.keys(this.nsps);for(let n of r)if(this.nsps[n].active)return;this._close()}_packet(e){let r=this.encoder.encode(e);for(let n=0;n<r.length;n++)this.engine.write(r[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,r){var n;this.cleanup(),(n=this.engine)===null||n===void 0||n.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,r),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{let r=this.backoff.duration();this._reconnecting=!0;let n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),!e.skipReconnect&&e.open(o=>{o?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",o)):e.onreconnect()}))},r);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}};var nl={};function Ys(t,e){typeof t=="object"&&(e=t,t=void 0),e=e||{};let r=G1(t,e.path||"/socket.io"),n=r.source,o=r.id,s=r.path,i=nl[o]&&s in nl[o].nsps,a=e.forceNew||e["force new connection"]||e.multiplex===!1||i,c;return a?c=new Gs(n,e):(nl[o]||(nl[o]=new Gs(n,e)),c=nl[o]),r.query&&!e.query&&(e.query=r.queryKey),c.socket(r.path,e)}Object.assign(Ys,{Manager:Gs,Socket:Ks,io:Ys,connect:Ys});D();D();var $d=new Set(["__proto__","constructor","prototype"]),uw=t=>{if(!Array.isArray(t))return!1;for(let e=0;e<t.length;e++)if($d.has(t[e]))return!1;return!0},aA=(t,e)=>{!t||!uw(e)||e.reduce((r,n,o,s)=>{if(r&&n in r){if(o!==s.length-1)return r[n];delete r[n]}},t)},cA=(t,e,r,n=!1)=>{!t||!uw(e)||e.reduce((o,s,i,a)=>{if(o){if(i!==a.length-1)return!o[s]&&n&&(o[s]={}),o[s];o[s]=r}},t)},Md=(t,e)=>{let r=new Set;if(!Array.isArray(e))return r;for(let[n,o,s]of e)if(!(!Array.isArray(o)||!o.length))switch(r.add(o[0]),n){case"delete":aA(t,o);break;case"update":case"set":cA(t,o,s,!0);break;default:break}return r},lA=(t,e)=>{if(!e||typeof e!="object"||Array.isArray(e))return null;let r=t&&(t.__raw||t)||{},n=null;for(let o of Object.keys(e))$d.has(o)||Object.prototype.hasOwnProperty.call(r,o)||(n||(n={}),n[o]=e[o]);return n},ol=(t,e)=>{!t||!e||typeof e!="object"||(t.__rawDesignSystem=JSON.parse(JSON.stringify(e)))},fA=(t,e,r,n="designSystem")=>{for(let o in e){if($d.has(o))continue;let s=`${n}/${o}`;if(r.has(s))continue;let i=e[o],a=t[o];if(i&&typeof i=="object"&&!Array.isArray(i)){if(!a||typeof a!="object"||Array.isArray(a)){if(o in t)continue;t[o]={}}fA(t[o],i,r,s)}else o in t||(t[o]=Array.isArray(i)?JSON.parse(JSON.stringify(i)):i)}},dw=(t,e)=>{if(!t||!t.__rawDesignSystem)return null;if(Array.isArray(e)&&e.length){let o={designSystem:t.__rawDesignSystem};Md(o,e)}let r=JSON.parse(JSON.stringify(t.__rawDesignSystem)),n=Array.isArray(t.sharedLibraries)?t.sharedLibraries:[];for(let o of n){let s=Qe(o),i=s?o.library:o,a=i&&i.designSystem;if(!a||typeof a!="object")continue;let c=Wr(i.sharedLibIgnore);if(s)for(let l of Wr(o.ignoreList))c.add(l);c.has("designSystem")||fA(r,a,c)}return r};D();var uA=(t,e,r)=>{let n=!1;return(o={})=>{let{data:s}=o,{schema:i}=o;s&&(s=t.call("deepDestringifyFunctions",s,Array.isArray(s)?[]:{}),Object.entries(s).forEach(([a,c])=>{if(r[a]&&typeof r[a]=="object")if(a==="designSystem"){if(ol(r,c),n){let l=dw(r);l&&Er(l)}}else Tn(r[a],c);else r[a]=c}),n=!0,i&&(r.schema=i))}},dA=(t,e,r)=>(n={})=>{let{changes:o}=n;if(!o||!Array.isArray(o)||!o.length)return;o=t.call("deepDestringifyFunctions",o,Array.isArray(o)?[]:{});let s=o.filter(c=>Array.isArray(c)&&Array.isArray(c[1])&&c[1][0]==="designSystem"),i=s.length?o.filter(c=>!s.includes(c)):o,a=Md(r,i);if(s.length&&a.add("designSystem"),a.has("designSystem")){let c=dw(r,s);c?Er(c):r.__warnedNoRawDesignSystem||(r.__warnedNoRawDesignSystem=!0,console.warn("[sync] design-system op ignored: no raw design system was seeded on this client. Re-initing from the processed config would corrupt every token, so the update is skipped \u2014 reload to pick it up. Seed it at boot with seedRawDesignSystem(ctx, ds)."))}if(a.has("state")){let c=lA(e,r.state);if(c){let l=typeof e.$update=="function"?e.$update:e.update;typeof l=="function"&&l.call(e,c)}}if(["pages","components","snippets","functions","assets"].some(c=>a.has(c))){let{pathname:c,search:l,hash:f}=r.window.location;t.call("router",c+l+f,t.__ref.root,{},{scrollToTop:!1,force:!0})}};var f$={success:"green",error:"red",warning:"yellow"},pA=(t,e,r)=>{if(t.symbols){if(!r.connected){r.notifications.connected={title:"Connected",message:"to the Symbols live server"},r.update({connected:!0});let n=setTimeout(()=>{delete r.notifications.connected,e.notifications.content.connected.update({animation:"fadeOutDown"}),r.update({connected:!0}),clearTimeout(n)},3e3)}}else if(r.connected){r.notifications.connected={title:"Disconnected",type:"error"},r.update({connected:!1});let n=setTimeout(()=>{delete r.notifications.connected,e.notifications.content.connected&&e.notifications.content.connected.update({animation:"fadeOutDown"}),r.update({connected:!0}),clearTimeout(n)},3e3)}},hA={state:{notifications:[]},Notifications:{position:"fixed",left:"A2",bottom:"Z2",zIndex:"999",childExtends:"Notification",childProps:({state:t})=>({animationDuration:"C",background:f$[t.type||"success"],icon:null,Flex:{Title:{text:"{{ title }}"},P:{text:"{{ title }}"}},onRender:(e,r,n)=>{r.update({animation:"fadeInUp"})},onClick:(e,r,n)=>{delete n.notifications[r.key],r.update({animation:"fadeOutDown"}),n.onClose&&n.onClose(e,r,n)}}),IconText:null,childrenAs:"state",children:({state:t})=>t.notifications}};var u$=!1,d$=()=>u$?"http://localhost:8080":"https://api.symbols.app",p$=t=>{let e=t&&t.editor&&t.editor.socketUrl||t&&t.settings&&t.settings.socketUrl;return typeof e=="string"&&e?{mode:"collab",baseUrl:e}:t&&t.editor&&t.editor.runtime==="runner"?{mode:"runner",baseUrl:null}:{mode:null,baseUrl:null}},h$=async t=>{try{let e=t||d$(),r=await E.fetch(`${e}/service-token`,{method:"GET"}),n;try{let o=await r.clone().json();if(o&&typeof o.token=="string")return o.token.trim();n=await r.text()}catch{n=await r.text()}return(n||"").replace(/\s+/gu,"")||void 0}catch(e){console.error("[sync] Failed to fetch service-token",e)}},yA=(t,e,r,n)=>{t.on("snapshot",uA(e,r,n)),t.on("ops",dA(e,r,n)),t.on("clients",o=>{n.editor?.verbose&&pA(o,e,r)}),t.on("disconnect",o=>{n.editor?.verbose&&console.info("[sync] disconnected",o)})},g$=async(t,e,r,n)=>{let o=await h$(n);if(!o)return console.warn("[sync] no service token \u2014 collab disabled"),null;let s=r.key;if(!s)return console.warn("[sync] ctx.key missing \u2014 collab cannot authenticate"),null;let i=r.editor?.projectId||null,a=Ys(n,{path:"/collab-socket",transports:["websocket"],auth:{token:o,projectId:i,projectKey:s,branch:"main",live:!0,clientType:"platform"},reconnectionAttempts:1/0,reconnectionDelayMax:4e3});return a.on("connect",()=>{r.editor?.verbose&&console.info("[sync] connected (collab)")}),yA(a,t,e,r),a},m$=(t,e,r)=>{let n=Ys({transports:["websocket","polling"],reconnectionAttempts:1/0,reconnectionDelayMax:4e3});return n.on("connect",()=>{r.editor?.verbose!==!1&&console.info("[sync] connected (runner)")}),yA(n,t,e,r),n.on("reload",()=>{typeof E<"u"&&E.location&&E.location.reload()}),n},y$=async(t,e,r)=>{let{mode:n,baseUrl:o}=p$(r);return n?n==="collab"?g$(t,e,r,o):n==="runner"?m$(t,e,r):null:null},b$={onInit:y$};var bA=t=>typeof t>"u",gA=t=>!!(t?.editor?.socketUrl||t?.settings?.socketUrl),mA=t=>t?.editor?.runtime==="runner",_A=(t,e)=>{Array.isArray(t.extends)?t.extends.push(e):t.extends?t.extends=[t.extends,e]:t.extends=[e]},wA={name:"sync",beforeCreate(t,e){let r=e&&e.editor;(r&&!bA(r.liveSync)?r.liveSync:gA(e)||mA(e))&&(gA(e)&&!mA(e)&&!e?.key||_A(t,b$))}},xA={name:"notifications",beforeCreate(t,e){if(!e)return;let r=bA(e.notifications)?null:e.notifications,n=e.editor&&e.editor.verbose===!0;(r===!0||r!==!1&&n)&&_A(t,hA)}};var gw={};$(gw,{AlertTemplate:()=>Kd,ConfirmTemplate:()=>qd,CustomTemplate:()=>Yd,ModalLayer:()=>Wd,ModalRoot:()=>Hd,PromptTemplate:()=>Gd,windowsComponents:()=>hw});var pw={};$(pw,{alertDialog:()=>Ud,closeAllModals:()=>Bd,closeModal:()=>Nd,confirmDialog:()=>Vd,getLayer:()=>Fd,openModal:()=>jd,promptDialog:()=>zd,windowsFunctions:()=>Pr});function et(t){let e=t;for(;e;){if(e.layer!==void 0)return e.layer;e=e.parent}return null}function Xs(t){let e=t;for(;e;){if(e.key==="ModalRoot")return e;if(e.ModalRoot&&e.ModalRoot.__ref)return e.ModalRoot;e=e.parent}let r=t?.getRoot?.();return r?.ModalRoot?r.ModalRoot:typeof globalThis<"u"&&globalThis.__SMBLS_WINDOWS_MODAL_ROOT__?.__ref?globalThis.__SMBLS_WINDOWS_MODAL_ROOT__:null}function Fd(){return et(this)}var _$=(t,e)=>{let r=t&&t["ModalLayer_"+e],n=r?.node||r?.__ref?.node;!n||typeof n.style?.setProperty!="function"||(n.style.setProperty("display","none","important"),n.style.setProperty("opacity","0","important"),n.style.setProperty("visibility","hidden","important"),n.style.setProperty("pointer-events","none","important"))},SA=(t,e)=>{let r=t&&t["ModalLayer_"+e],n=r?.node||r?.__ref?.node;!n||typeof n.style?.removeProperty!="function"||(n.style.removeProperty("display"),n.style.removeProperty("opacity"),n.style.removeProperty("visibility"),n.style.removeProperty("pointer-events"))};function Nd(t){let e=Xs(this);if(!e)return;let r=e.state?.stack||[];if(!r.length)return;let n,o,s;if(t){if(s=[],n=r.filter((i,a)=>{let c=i.id!==t;return c||s.push(a),c}),n.length===r.length)return;o=r.filter(i=>i.id===t)}else n=r.slice(0,-1),o=r.slice(-1),s=[r.length-1];e.state.update({stack:n});for(let i of s)_$(e,i);for(let i of o)if(typeof i.onClose=="function")try{i.onClose()}catch(a){console.warn("[windows] onClose threw:",a)}}function jd(t={}){let e=Xs(this);if(!e)return console.warn("[windows] openModal: ModalRoot is not mounted on the app root. Add `ModalRoot: {}` to your shell tree and import windowsComponents into context."),null;e.__modalIdCounter=(e.__modalIdCounter||0)+1;let r=t.id||`modal_${e.__modalIdCounter}_${Date.now().toString(36)}`,n={id:r,template:t.template||"custom",title:t.title,message:t.message,icon:t.icon,confirmText:t.confirmText,cancelText:t.cancelText,okText:t.okText,confirmTheme:t.confirmTheme,placeholder:t.placeholder,defaultValue:t.defaultValue,dismissOnBackdrop:t.dismissOnBackdrop,content:t.content,width:t.width,maxWidth:t.maxWidth,maxHeight:t.maxHeight,onConfirm:t.onConfirm,onCancel:t.onCancel,onOk:t.onOk,onClose:t.onClose},o=e.state?.stack||[];if(o.length>=5)return console.warn("[windows] openModal: stack already at the 5-layer maximum, dropping the new layer. Close some modals first."),null;let s=o.length;return SA(e,s),e.state.update({stack:[...o,n]}),r}function Bd(){let t=Xs(this);!t||!t.state?.stack?.length||t.state.update({stack:[]})}function Vd(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"confirm"})}function Ud(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"alert"})}function zd(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"prompt"})}var Pr={openModal:jd,closeModal:Nd,closeAllModals:Bd,confirmDialog:Vd,alertDialog:Ud,promptDialog:zd,getLayer:Fd};var w$=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),kA=t=>{if(!t?.querySelectorAll)return[];let e=t.querySelectorAll(w$),r=[];for(let n=0;n<e.length;n++){let o=e[n];(o.offsetParent!==null||o===document.activeElement)&&r.push(o)}return r},vA=t=>{let e=t.state?.stack||[];if(!e.length)return null;let r=t["ModalLayer_"+(e.length-1)];return r?.node||r?.__ref?.node||null},Hd={tag:"div",position:"fixed",inset:"0",zIndex:"2000",pointerEvents:"none",state:{stack:[]},subscribeTo:["stack"],ModalLayer_0:{__slotIndex:0,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[0]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_1:{__slotIndex:1,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[1]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_2:{__slotIndex:2,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[2]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_3:{__slotIndex:3,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[3]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_4:{__slotIndex:4,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[4]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},onInit:(t,e)=>{if(typeof window>"u")return;globalThis.__SMBLS_WINDOWS_MODAL_ROOT__=t;let r=t.context;if(r){r.functions||(r.functions={});for(let a in Pr)a in r.functions||(r.functions[a]=Pr[a])}t.__modalOpeners=t.__modalOpeners||[],t.__prevStackLen=t.state&&t.state.stack&&t.state.stack.length||0;let n=()=>{let a=t.state?.stack||[];if(!a.length)return;let c=a.length-1,l=a[c];t.state.update({stack:a.slice(0,-1)});let f=t["ModalLayer_"+c],u=f?.node||f?.__ref?.node;if(u?.style?.setProperty&&(u.style.setProperty("display","none","important"),u.style.setProperty("opacity","0","important"),u.style.setProperty("visibility","hidden","important"),u.style.setProperty("pointer-events","none","important")),typeof l?.onClose=="function")try{l.onClose()}catch(d){console.warn("[windows] onClose threw:",d)}},o=a=>{let c=t.state?.stack;if(c?.length){if(a.key==="Tab"){let l=vA(t);if(!l)return;let f=kA(l);if(!f.length){a.preventDefault();let p=l.querySelector?.('[role="dialog"]')||l;try{p.focus?.()}catch{}return}let u=f[0],d=f[f.length-1],g=document.activeElement;if(!l.contains(g)){a.preventDefault();try{u.focus()}catch{}return}if(a.shiftKey&&g===u){a.preventDefault();try{d.focus()}catch{}}else if(!a.shiftKey&&g===d){a.preventDefault();try{u.focus()}catch{}}return}a.key!=="Escape"||a.defaultPrevented||c[c.length-1]?.dismissOnBackdrop!==!1&&(a.preventDefault(),n())}};window.addEventListener("keydown",o),t.__escHandler=o;let s=a=>{let c=t.state?.stack||[];if(a<0||a>=c.length)return;let l=c[a];t.state.update({stack:c.filter((d,g)=>g!==a)});let f=t["ModalLayer_"+a],u=f?.node||f?.__ref?.node;if(u?.style?.setProperty&&(u.style.setProperty("display","none","important"),u.style.setProperty("opacity","0","important"),u.style.setProperty("visibility","hidden","important"),u.style.setProperty("pointer-events","none","important")),typeof l?.onClose=="function")try{l.onClose()}catch(d){console.warn("[windows] onClose threw:",d)}},i=a=>{let c=t.state?.stack||[];if(!c.length)return;let l=a.target?.closest?.('[data-key="Close"]');if(l){for(let f=c.length-1;f>=0;f--){let u=t["ModalLayer_"+f],d=u?.node||u?.__ref?.node;if(d&&d.contains(l)){a.preventDefault(),a.stopPropagation(),s(f);return}}return}for(let f=c.length-1;f>=0;f--){let u=t["ModalLayer_"+f];if((u?.node||u?.__ref?.node)===a.target){if(c[f]?.dismissOnBackdrop===!1)return;a.preventDefault(),a.stopPropagation(),s(f);return}}};document.addEventListener("click",i,!0),t.__clickDelegate=i},onUpdate:t=>{if(typeof window>"u")return;let e=(t.state&&t.state.stack||[]).length,r=t.__prevStackLen||0;if(e!==r)if(t.__prevStackLen=e,t.__modalOpeners=t.__modalOpeners||[],e>r)t.__modalOpeners[e]=document.activeElement&&document.activeElement!==document.body?document.activeElement:t.__modalOpeners[e]||null,typeof requestAnimationFrame=="function"&&requestAnimationFrame(()=>{let n=vA(t);if(!n)return;let o=kA(n)[0]||n.querySelector&&n.querySelector('[role="dialog"]')||n;try{o.focus&&o.focus()}catch{}});else{let n=null;for(let o=r;o>e;o--)t.__modalOpeners[o]&&(n=n||t.__modalOpeners[o]),t.__modalOpeners[o]=null;if(n&&typeof n.focus=="function"&&n.isConnected!==!1)try{n.focus()}catch{}}},onDestroy:t=>{typeof window>"u"||(globalThis.__SMBLS_WINDOWS_MODAL_ROOT__===t&&(globalThis.__SMBLS_WINDOWS_MODAL_ROOT__=null),t.__escHandler&&(window.removeEventListener("keydown",t.__escHandler),delete t.__escHandler),t.__clickDelegate&&(document.removeEventListener("click",t.__clickDelegate,!0),delete t.__clickDelegate))}};var Wd={tag:"div",position:"fixed",inset:"0",alignItems:"center",justifyContent:"center",padding:"A",theme:"backdrop",transition:"opacity C defaultBezier",zIndex:(t,e)=>`${2e3+(t.__slotIndex||0)*10}`,display:(t,e)=>t.layer?"flex":"none",opacity:(t,e)=>t.layer?"1":"0",visibility:(t,e)=>t.layer?"visible":"hidden",pointerEvents:(t,e)=>t.layer?"auto":"none",ModalWindow:{attr:{role:"dialog","aria-modal":"true",tabindex:"-1","aria-labelledby":t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}},width:t=>et(t)?.width||"H",maxWidth:t=>et(t)?.maxWidth||"90vw",flow:"y",maxHeight:t=>et(t)?.maxHeight||"100%",animation:"modalIn",animationDuration:"D",animationTimingFunction:"springBezier",onClick:t=>t.stopPropagation(),onMousedown:t=>t.stopPropagation(),ModalHeader:{display:"none"},overflow:"visible",ConfirmTemplate:{hide:t=>et(t)?.template!=="confirm"},AlertTemplate:{hide:t=>et(t)?.template!=="alert"},PromptTemplate:{hide:t=>et(t)?.template!=="prompt"},CustomTemplate:{hide:t=>et(t)?.template!=="custom"}}};var Zs=(t,e,r)=>et(t)?.[e]||r,x$=t=>{let e=et(t)?.icon;return e===null||e===!1},qd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",ModalHeader:{Hgroup:{H:{text:t=>Zs(t,"title","Are you sure?"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}},Icons:{hide:t=>x$(t),Indicator:{extends:"Icon",opacity:".7",icon:t=>Zs(t,"icon","warning")}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",P:{tag:"p",margin:"0",text:t=>Zs(t,"message","This action cannot be undone."),color:"dim"}},ModalFooter:{flow:"x",gap:"Z1",align:"center end",flexShrink:"0",CancelBtn:{extends:"CancelButton",text:t=>Zs(t,"cancelText","Cancel"),onClick:(t,e,r)=>{let n=et(e);if(n?.onCancel)try{n.onCancel()}catch(o){console.warn("[windows] confirm.onCancel threw:",o)}e.call("closeModal",n?.id)}},ConfirmBtn:{extends:"Button",theme:t=>Zs(t,"confirmTheme","primary"),text:t=>Zs(t,"confirmText","Confirm"),onClick:(t,e,r)=>{let n=et(e);if(n?.onConfirm)try{n.onConfirm()}catch(o){console.warn("[windows] confirm.onConfirm threw:",o)}e.call("closeModal",n?.id)}}}};var sl=(t,e,r)=>et(t)?.[e]||r,Kd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",ModalHeader:{Hgroup:{H:{text:t=>sl(t,"title","Notice"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}},Icons:{Indicator:{extends:"Icon",opacity:".7",icon:t=>sl(t,"icon","info")}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",hide:t=>!sl(t,"message",""),P:{tag:"p",margin:"0",text:t=>sl(t,"message",""),color:"dim"}},ModalFooter:{flow:"x",align:"center end",flexShrink:"0",OkBtn:{extends:"Button",theme:"primary",text:t=>sl(t,"okText","OK"),onClick:(t,e,r)=>{let n=et(e);if(n?.onOk)try{n.onOk()}catch(o){console.warn("[windows] alert.onOk threw:",o)}e.call("closeModal",n?.id)}}}};var Js=(t,e,r)=>et(t)?.[e]||r,Gd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",scope:{value:""},onRender:(t,e)=>{let r=et(t);if(!r||t.scope._seededLayerId===r.id)return;t.scope._seededLayerId=r.id,t.scope.value=r.defaultValue||"";let n=t.InputRow&&t.InputRow.node;n&&(n.value=t.scope.value)},onUpdate:(t,e)=>{let r=et(t);if(!r||t.scope._seededLayerId===r.id)return;t.scope._seededLayerId=r.id,t.scope.value=r.defaultValue||"";let n=t.InputRow&&t.InputRow.node;n&&(n.value=t.scope.value)},ModalHeader:{Hgroup:{H:{text:t=>Js(t,"title","Enter a value"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",hide:t=>!Js(t,"message",""),P:{tag:"p",margin:"0",text:t=>Js(t,"message",""),color:"dim"}},InputRow:{extends:"Input",flexShrink:"0",autofocus:!0,placeholder:t=>Js(t,"placeholder",""),value:(t,e)=>t.parent.scope?.value||"",onInput:(t,e,r)=>{e.parent.scope.value=t.target.value},onKeydown:(t,e,r)=>{if(t.key!=="Enter")return;t.preventDefault();let n=et(e),o=e.parent.scope?.value||"";if(n?.onConfirm)try{n.onConfirm(o)}catch(s){console.warn("[windows] prompt.onConfirm threw:",s)}e.call("closeModal",n?.id)}},ModalFooter:{flow:"x",gap:"Z1",align:"center end",flexShrink:"0",CancelBtn:{extends:"CancelButton",text:t=>Js(t,"cancelText","Cancel"),onClick:(t,e,r)=>{let n=et(e);if(n?.onCancel)try{n.onCancel()}catch(o){console.warn("[windows] prompt.onCancel threw:",o)}e.call("closeModal",n?.id)}},ConfirmBtn:{extends:"Button",theme:"primary",text:t=>Js(t,"confirmText","OK"),onClick:(t,e,r)=>{let n=et(e),o=e.parent.parent.scope?.value||"";if(n?.onConfirm)try{n.onConfirm(o)}catch(s){console.warn("[windows] prompt.onConfirm threw:",s)}e.call("closeModal",n?.id)}}}};var Yd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",Title:{tag:"h2",text:t=>et(t)?.title||"",hide:t=>!et(t)?.title,position:"absolute",width:"1px",height:"1px",margin:"-1px",padding:"0",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0",attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},Slot:{tag:"div",flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",onInit:t=>{let e=Y(()=>{let r=et(t),n=r?.content||null,o=r?.id||null;if(!n){t.__lastLayerId!=null&&(t.removeContent(),t.__lastLayerId=null);return}if(t.__lastLayerId!==o){t.__lastLayerId=o;try{t.set(n);let s=t.content?.context;if(s){s.functions||(s.functions={});for(let i in Pr)i in s.functions||(s.functions[i]=Pr[i])}}catch(s){console.warn("[windows] custom.content set failed:",s)}}});t.__ref&&t.__ref.__effects.push(e)}}};var CA={extends:"Button",theme:"tertiary"};var hw={ModalRoot:Hd,ModalLayer:Wd,ConfirmTemplate:qd,AlertTemplate:Kd,PromptTemplate:Gd,CustomTemplate:Yd,"smbls.CancelButton":CA};var xw={};$(xw,{Dropdown:()=>ep,DropdownList:()=>rp,DropdownParent:()=>np,DropdownParentFocus:()=>op,DropdownRoot:()=>Qd,DropdownSiblingFocus:()=>sp,DropdownTrigger:()=>tp,dropdownComponents:()=>ww});var EA=(t,e,r)=>({bottom:r-t.bottom,top:t.top,right:e-t.right,left:t.left}),S$=(t,e,r,n)=>{let o=EA(t,r,n),s=i=>o[i]>=e.height+8;return s("bottom")?"bottom":s("top")?"top":o.bottom>=o.top?"bottom":"top"},k$=(t,e,r,n,o)=>{let s=EA(e,n,o),i=t==="top"||t==="bottom"?r.height+8:r.width+8;if(s[t]>=i)return t;let a={top:"bottom",bottom:"top",left:"right",right:"left"}[t];return a&&s[a]>=i||a&&s[a]>s[t]?a:t};var mw=(t,e,r)=>{let n;return t==="bottom"?n=r-e.bottom-16:t==="top"?n=e.top-16:n=r-16,Math.max(40,Math.floor(n))},Xd=(t,e,r)=>Math.max(e,Math.min(r,t)),Dr=(t,e,r="auto")=>{if(!t){let p=typeof window<"u"?window.innerHeight:768;return{left:0,top:0,side:"bottom",align:"start",maxHeight:mw("center",null,p)}}let n=typeof window<"u"?window.innerWidth:1024,o=typeof window<"u"?window.innerHeight:768,s={width:Math.max(120,e?.width||0),height:Math.max(40,e?.height||0)};if(r==="center"){let p=mw("center",t,o),h=Math.min(s.height,p),m=Xd((n-s.width)/2,8,Math.max(8,n-s.width-8)),_=Xd((o-h)/2,8,Math.max(8,o-h-8));return{left:m,top:_,side:"center",align:"center",maxHeight:p}}let i,a;if(r==="auto")i=S$(t,s,n,o),a="start";else{let p=r.split("-");i=p[0],a=p[1]||"start",i=k$(i,t,s,n,o)}let c=mw(i,t,o),l=Math.min(s.height,c),f,u;i==="bottom"||i==="top"?(a==="start"?f=t.left:a==="end"?f=t.right-s.width:f=t.left+(t.width-s.width)/2,u=i==="bottom"?t.bottom+8:t.top-l-8):(a==="start"?u=t.top:a==="end"?u=t.bottom-l:u=t.top+(t.height-l)/2,f=i==="right"?t.right+8:t.left-s.width-8);let d=Math.max(8,n-s.width-8),g=Math.max(8,o-l-8);return f=Xd(f,8,d),u=Xd(u,8,g),{left:f,top:u,side:i,align:a,maxHeight:c}},Qs=t=>{switch(t){case"bottom":return"translateY(-6px)";case"top":return"translateY(6px)";case"left":return"translateX(6px)";case"right":return"translateX(-6px)";case"center":return"translateY(0px)";default:return"translateY(-6px)"}};var bn={placement:"auto",trigger:"click",offset:8,minWidth:"180px",maxWidth:"90vw",maxHeight:null},v$=t=>{if(!t||typeof t.getBoundingClientRect!="function")return null;let e=t.getBoundingClientRect();return{left:e.left,top:e.top,right:e.right,bottom:e.bottom,width:e.width,height:e.height}},yw=t=>t?.getRoot?.()?.DropdownRoot||null,C$=0,E$=()=>`dropdown_${++C$}_${Date.now().toString(36)}`;function Zd(t={}){let e=yw(this);if(!e)return console.warn("[dropdown] openDropdown: DropdownRoot is not mounted on the app root. Add `DropdownRoot: {}` to your shell tree and import dropdown components into context."),null;let r=t.anchorEl?.node||t.anchorEl,n=t.anchorRect||v$(r);if(!n)return console.warn("[dropdown] openDropdown: no anchor element/rect provided \u2014 pass anchorEl or anchorRect."),null;let o=t.id||E$(),s=t.restoreEl?.node||t.restoreEl||r||(typeof document<"u"?document.activeElement:null),i={id:o,content:t.content||null,anchor:n,placement:t.placement||bn.placement,trigger:t.trigger||bn.trigger,offset:t.offset??bn.offset,minWidth:t.minWidth||bn.minWidth,maxWidth:t.maxWidth||bn.maxWidth,maxHeight:t.maxHeight||bn.maxHeight,theme:t.theme||null,shadow:t.shadow||null,background:t.background||null,round:t.round||null,role:t.role||null,ariaLabel:t.ariaLabel||null,ariaLabelledby:t.ariaLabelledby||null,focusIn:!!t.focusIn,onOpen:t.onOpen,onClose:t.onClose,restoreEl:s},a=e.state?.layer;if(a?.onClose)try{a.onClose(a)}catch(c){console.warn("[dropdown] prev onClose threw:",c)}if(e.state.update({layer:i}),typeof i.onOpen=="function")try{i.onOpen(i)}catch(c){console.warn("[dropdown] onOpen threw:",c)}return o}function Jd(t){let e=yw(this);if(!e)return;let r=e.state?.layer;r&&e.state.update({layer:{...r,inert:!!t}})}function mo(t){let e=yw(this);if(!e)return;let r=e.state?.layer;if(!r)return;let n=typeof t=="string"?t:t?.id;if(n&&r.id&&n!==r.id)return;let o=r.onClose,s=r.restoreEl,i=typeof document<"u"?document:null,a=i?i.activeElement:null,c=e.node?.querySelector?.('[data-smbls-dropdown="panel"]'),l=!a||a===i?.body,f=!!(c&&a&&c.contains(a)),u=l||f;if(e.state.update({layer:null}),u&&s&&typeof s.focus=="function")try{s.focus()}catch(d){console.warn("[dropdown] focus restore threw:",d)}if(typeof o=="function")try{o(r)}catch(d){console.warn("[dropdown] onClose threw:",d)}}var bw=(t,e)=>{let r=`${e.maxHeight}px`;return t?.maxHeight?`min(${t.maxHeight}, ${r})`:r},AA=t=>{let e=t.getBoundingClientRect();return{width:e.width,height:Math.max(e.height,t.scrollHeight||0)}},A$=`
104
+ \`\`\``}o.push({role:"user",content:s})}return o}var o1=/```(?<lang>[a-zA-Z0-9_+-]*)\n(?<code>[\s\S]*?)```/g,bI=new Set(["component","components","page","pages","function","method","state","theme","color","font","icon"]);function _I(t){let e=[];for(let r of t.matchAll(o1))e.push({lang:(r.groups?.lang||"").toLowerCase(),code:r.groups?.code??""});return e}function xI(t){return t.replace(o1,"").trim()}function Y_(t){if(!t||!/[{[]/.test(t))return null;try{return JSON.parse(t)}catch{}try{return JSON.parse(t.replace(/,\s*([}\]])/g,"$1"))}catch{}return null}function n1(t){return!!t&&typeof t=="object"&&typeof t.type=="string"&&bI.has(t.type)}function s1(t){let e=(typeof t=="string"?t:"").trim();if(!e)return{kind:"text",text:"",message:""};let r=_I(e),n=r.filter(i=>/^(js|javascript|ts|typescript|jsx|tsx)$/.test(i.lang)),o=r.filter(i=>i.lang==="json"),s=xI(e);for(let i of o){let a=Y_(i.code);if(n1(a))return{kind:"asset",text:s||a.description||"",asset:a,message:a.description||s||`Generated ${a.type}: ${a.title||a.key||""}`.trim()}}if(n.length>0){let i=n[0].code,a=Y_("["+i+"]");return Array.isArray(a)&&a.length>1?{kind:"multi",text:s,assets:a,code:i,message:s||`Generated ${a.length} items`}:{kind:"component",text:s,code:i,message:s||"Generated a component"}}if(e.startsWith("{")){let i=Y_(e);if(n1(i))return{kind:"asset",text:i.description||"",asset:i,message:i.description||`Generated ${i.type}: ${i.title||i.key||""}`.trim()}}return{kind:"text",text:e,message:e}}function i1(t){if(!t)return{code_response:{type:"error",content:"Empty response from assistant"}};switch(t.kind){case"asset":return{code_response:{type:"json_response",data:t.asset}};case"multi":return{code_response:{type:"symbols_component_code",component_code:t.code}};case"component":return{code_response:{type:"symbols_component_code",component_code:t.code,analysis_text:t.text}};default:return{code_response:{type:"plain_text_response",content:t.text||t.message||""}}}}var a1=["You are Simone, the Symbols.app assistant.","You help users build DOMQL v3 components, pages, and design-system entries.",'When the user asks for a component or page, return a single ```json fenced block whose body is one asset object with shape { type, key, title, description, value }. type is one of "component", "page", "function", "state", "color", "font", "icon", "theme".',"For multiple assets, return one ```js fenced block with comma-separated asset objects.","For general questions, reply with prose only."].join(" "),c1=["You are a DOMQL v3.14 code generator for the Symbols workspace.","Output EXECUTABLE DOMQL v3.14 for the requested page(s)/component(s) \u2014 never a description, never a plan, never an explanation.","Author data-first object schemas: child elements are UPPERCASE keys; styling lives in flat element props (NO attr/props/on wrappers); use design-system tokens (color/typography/spacing keys), never raw px/rem/hex/rgba; `extends` and `childExtends` are quoted strings; event handlers are flat (onClick, onInit) \u2014 never on:{} or props:{} wrappers.","OUTPUT FORMAT \u2014 pick ONE:","- SINGLE page/component: emit exactly one ```js fenced code block whose body is a single DOMQL object literal (an expression \u2014 start with `{`, no `export`, no variable assignment, no surrounding prose).",'- MULTIPLE pages/components: emit exactly one ```json fenced code block whose body is an object of the shape { "pages": { "PageKey": "<DOMQL object-literal source string>" }, "components": { "CompKey": "<DOMQL object-literal source string>" } }. Include only the sections you produce; each value is the DOMQL source for that key.',"Keys are PascalCase. Default to a single page unless the request clearly needs several distinct pages/components.","Emit ONLY the single fenced block. No text before or after it."].join(`
105
+ `),X_={Starter:dn,Free:dn,Pro:"claude-opus-4-6"};function l1(t){return t?X_[t]||t:dn}var f1={"@symbo.ls/signal":Tp,"@symbo.ls/scratch":dy,"@symbo.ls/element":wb,"@symbo.ls/css":ky,"@symbo.ls/utils":qo,"@symbo.ls/state":rb,"@symbo.ls/router":Ac,"@symbo.ls/polyglot":S_,"@symbo.ls/helmet":x_,"@symbo.ls/fetch":hf,"@symbo.ls/capsize":v_,"@symbo.ls/shorthand":P_,"@symbo.ls/analyze":z_,"@symbo.ls/inspect":q_,"@symbo.ls/channels":G_,"@symbo-ls/simone-server":Z_},u1=(t,e)=>{let r=t||(typeof globalThis<"u"?globalThis:{}),n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in f1)n[o]||(n[o]=f1[o]);if(e)for(let o in e)n[o]||(n[o]=e[o]);return n},d1=(t,e)=>{let r=t||(typeof globalThis<"u"?globalThis:null);if(!r||!e||typeof e!="object")return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in e){let s=e[o];if(typeof s!="function"||Object.prototype.hasOwnProperty.call(n,o))continue;let i=a=>(Object.defineProperty(n,o,{configurable:!0,enumerable:!0,writable:!0,value:a}),a);Object.defineProperty(n,o,{configurable:!0,enumerable:!0,get:()=>i(s()),set:i})}return n},p1=["@symbo.ls/sdk"],h1=(t,e)=>{let r=e||(typeof globalThis<"u"?globalThis:null);if(!r||!t||typeof t!="object")return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o in t){let s=t[o];!s||typeof s!="object"&&typeof s!="function"||n[o]||(n[o]=s)}return n},wI=/^@symbo[-.]ls\//,SI=t=>t.includes("/")?t.slice(t.indexOf("/")+1):t,g1=(t,e)=>{let r=e||(typeof globalThis<"u"?globalThis:null);if(!r||!Array.isArray(t))return null;let n=r.__SMBLS_PKGS__||(r.__SMBLS_PKGS__={});for(let o of t){let s=o&&o.library?o.library:o;if(!s||typeof s!="object"||s.__isStub)continue;let i=s.key||s.name||s.__libraryKey,a=[];for(let c of[s.key,s.name,s.__libraryKey,s.__libraryName]){if(typeof c!="string"||!c||c!==i&&!wI.test(c))continue;let l=SI(c);l&&!a.includes(l)&&a.push(l)}for(let c of a)for(let l of[`@symbo-ls/${c}`,`@symbo.ls/${c}`])n[l]||(n[l]=s)}return n};D();var m1=t=>{let e={faces:0,links:0};if(!t)return e;for(let r in t){let n=t[r];if(!n||!n.fontFace)continue;let o=Array.isArray(n.fontFace)?n.fontFace:[n.fontFace];for(let s of o){if(y1(s)){let i=vI(s);i&&CI(i)&&e.links++;continue}if(kI(s)){xt(s.trim()),e.faces++;continue}typeof s=="string"&&s.includes("font-family")&&(xt(`@font-face { ${s} }`),e.faces++)}}return e},y1=t=>typeof t=="string"&&t.trim().startsWith("@import"),kI=t=>typeof t=="string"&&t.trim().startsWith("@font-face"),vI=t=>{if(!y1(t))return null;let e=String(t).match(/url\(\s*['"]?([^'")]+)['"]?\s*\)/);return e?e[1].trim():null},CI=(t,e)=>{if(typeof t!="string"||!t)return null;let r=e||Jn();if(!r||!r.head)return null;let n="data-smbls-font",o=r.head.querySelectorAll(`link[rel="stylesheet"][${n}]`);for(let i=0;i<o.length;i++)if(o[i].getAttribute(n)===t)return o[i];let s=r.createElement("link");return s.setAttribute("rel","stylesheet"),s.setAttribute("href",t),s.setAttribute(n,t),r.head.appendChild(s),s};var w1=t=>{let e=typeof window<"u"?window:globalThis||{};e.document||(e.document={body:{}});let r=typeof document<"u"?document:e.document;t.document=t.document||r;let n=t.window;return n&&n!==e&&typeof n.URL!="function"?(typeof console<"u"&&console.warn&&!globalThis.__smblsRouterUrlWarned&&(globalThis.__smblsRouterUrlWarned=!0,console.warn("[smbls/router] context.window lacks URL, falling back to globalThis \u2014 passed-in window may be a stub (warned once; applies to every embed app this session)")),t.window=e):t.window=n||e,t.window},b1=(t="smbls")=>{let e={};for(let r in oo)Object.prototype.hasOwnProperty.call(oo,r)&&(Ze(r)?e[`smbls.${r}`]=oo[r]:e[r]=oo[r]);return e},S1=t=>t.components?{...b1(),...t.components}:b1(),k1=t=>({...Oc,...Ac,...Kr,...t.utils,...t.snippets,...t.functions}),v1=t=>({...t.methods||{},require:t.utils.require,requireOnDemand:t.utils.requireOnDemand,router:t.utils.router});var C1=t=>typeof globalThis<"u"&&globalThis.__SMBLS_PKGS__&&globalThis.__SMBLS_PKGS__[t]||null,EI=3e3,AI=(t,e,r=n=>import(n))=>{if(typeof globalThis>"u")return Promise.resolve(null);try{let n=globalThis.__SMBLS_PKGS__||(globalThis.__SMBLS_PKGS__={});if(n[t])return Promise.resolve(n[t]);let o=Promise.resolve().then(()=>r(e)).then(i=>(i&&!n[t]&&(n[t]=i),n[t]||null)).catch(()=>null);return new Promise(i=>{let a=setTimeout(()=>i(null),EI);o.then(c=>{clearTimeout(a),i(c)})})}catch{return Promise.resolve(null)}},_1={},ex=async({dependencies:t,dependenciesOnDemand:e,document:r,preventCaching:n=!1,cdnProvider:o,packageManager:s,symbolsConfig:i,registerDependency:a=AI})=>{if(o||(o=Ur[s]||Vo(i)||"esmsh"),!t)return null;if(!Ln(t))return console.warn(`[smbls] dependencies is ${Array.isArray(t)?"an ARRAY":`a ${typeof t}`}, not a package-name-keyed object \u2014 skipping the CDN fetch loop. This usually means a project's config.js declares its own "dependencies" field that collides with the platform package map once context.js spreads them together.`),null;let c=!1;for(let d in t){c=!0;break}if(!c)return null;let l=jr()&&n?`?${Math.random()}`:"",f=async(d,g)=>{let p=Me(d,g,o)+l;try{await Promise.race([Uo(p,{document:r,type:"module"}),new Promise((h,m)=>setTimeout(()=>m(new Error(`Timeout loading ${d}`)),1e4))]),await a(d,p)}catch(h){if(console.error(`Failed to load ${d} from ${o}:`,h),o!=="symbols")try{let m=Me(d,g,"symbols")+l;await Promise.race([Uo(m,{document:r,type:"module"}),new Promise((y,x)=>setTimeout(()=>x(new Error(`Timeout fallback ${d}`)),2e4))]),console.log(`Successfully loaded ${d} from fallback (symbols.ls)`),await a(d,m)}catch(m){console.error(`Failed to load ${d} from fallback:`,m)}}},u=[];for(let d in t){let g=t[d];if(!(e&&e[d])&&!_1[d]&&(_1[d]=!0,!zr(d))){if(Dn(d)){console.warn(`[smbls] dependency "${d}" looks like an un-interpolated template placeholder, not a real package specifier \u2014 skipping the CDN fetch (this is a bug upstream of the dependency loader, not a network failure).`);continue}C1(d)||u.push(f(d,g))}}return u.length&&await Promise.allSettled(u),t},x1=/\[smbls\] runtime dependency "([^"]+)" is not registered on globalThis\.__SMBLS_PKGS__/g,TI=t=>{if(typeof t=="string")return t;if(typeof t=="function")try{return typeof Le=="function"?Le(t):Function.prototype.toString.call(t)}catch{return""}return""},OI=t=>{let e=new Set;if(!t)return e;let r=[t.globalScope,t.functions,t.methods,t.snippets];for(let n=0;n<r.length;n++){let o=r[n];if(!o||typeof o!="object")continue;let s=Object.keys(o);for(let i=0;i<s.length;i++){let a;try{a=o[s[i]]}catch{continue}let c=TI(a);if(!c||c.indexOf("__SMBLS_PKGS__")===-1)continue;x1.lastIndex=0;let l;for(;(l=x1.exec(c))!==null;)e.add(l[1])}}return e},RI=t=>{let e=new Set;if(!t||typeof t.querySelectorAll!="function")return e;let r;try{r=t.querySelectorAll('script[type="importmap"]')}catch{return e}for(let n=0;n<r.length;n++){let o;try{o=JSON.parse(r[n].textContent||"")}catch{continue}let s=o&&typeof o=="object"?o.imports:null;if(s&&typeof s=="object"){let i=Object.keys(s);for(let a=0;a<i.length;a++)e.add(i[a])}}return e},PI=(t,e)=>{if(!e||!e.size)return!1;if(e.has(t))return!0;for(let r of e)if(r.length>1&&r.endsWith("/")&&t.length>r.length&&t.startsWith(r))return!0;return!1},E1=(t,{syncRead:e=OI(t),runtimeDocument:r=typeof document<"u"?document:null,importMap:n=RI(r)}={})=>{let o=t&&t.dependencies;if(!Ln(o))return null;let s=!t.document||t.document===r,i=t.dependenciesOnDemand,a=null,c=null;for(let l in o)s&&!(i&&i[l])&&!e.has(l)&&PI(l,n)?(c||(c={}))[l]=o[l]:(a||(a={}))[l]=o[l];return{blocking:a,deferred:c}},DI=t=>import(t),J_={},LI=(t,e)=>{if(!e||typeof globalThis>"u")return;let r=globalThis.__SMBLS_PKGS__||(globalThis.__SMBLS_PKGS__={});r[t]||(r[t]=e)},II=(t,{importModule:e=DI}={})=>{let r=[];if(!t)return Promise.resolve([]);for(let n in t)zr(n)||Dn(n)||C1(n)||(J_[n]||(J_[n]=Promise.resolve().then(()=>e(n)).then(o=>(LI(n,o),o||null),()=>null)),r.push(J_[n]));return Promise.all(r)},$I=2e3,MI=3e3,A1=(t,{win:e=typeof window<"u"?window:null,importModule:r,loadTimeoutMs:n=MI}={})=>t?new Promise(o=>{let s=()=>{II(t,{importModule:r}).then(o,o)},i=()=>{e&&typeof e.requestIdleCallback=="function"?e.requestIdleCallback(s,{timeout:$I}):setTimeout(s,0)},a=e&&e.document;if(a&&a.readyState&&a.readyState!=="complete"&&typeof e.addEventListener=="function"){let c=!0,l=null,f=()=>{c&&(c=!1,clearTimeout(l),typeof e.removeEventListener=="function"&&e.removeEventListener("load",f),i())};e.addEventListener("load",f,{once:!0}),l=setTimeout(f,n)}else i()}):null,T1=async(t,e)=>{let r=e.window||window,n=e.cdnProvider||Vo(e.symbolsConfig)||"esmsh",o=async i=>async(a,c)=>{let f=(i.window||window).packages[a];return typeof f=="function"?f():f},s=async i=>async(a,c=n)=>{let{dependenciesOnDemand:l}=i,f=i.document||document,u=i.window||window;if(!u.packages[a]&&zr(a))return await u.require(a,c);if(!u.packages[a]){let d=jr()?`?${Math.random()}`:"";if(l&&l[a]){let g=l[a],p=Me(a,g,c)+d;try{await i.utils.loadRemoteScript(p,{window:u,document:f})}catch(h){if(console.error(`Failed to load ${a} from ${c}:`,h),c!=="symbols"){let m=Me(a,g,"symbols")+d;await i.utils.loadRemoteScript(m,{window:u,document:f})}}}else{let g=Me(a,"latest",c)+d;try{await i.utils.loadRemoteScript(g,{window:u,document:f})}catch(p){if(console.error(`Failed to load ${a} from ${c}:`,p),c!=="symbols"){let h=Me(a,"latest","symbols")+d;await i.utils.loadRemoteScript(h,{window:u,document:f})}}u.packages[a]="loadedOnDeman"}}return await u.require(a,c)};r.packages?r.packages=bt(r.packages,t):r.packages=t,r.require||(e.utils.require=await o(e),r.require=e.utils.require),r.requireOnDemand||(e.utils.requireOnDemand=await s(e),r.requireOnDemand=e.utils.requireOnDemand)},FI=/\s+/g,O1=(t,e)=>typeof t=="function"?t(e,e?.state,e?.context):t,NI=(t,e)=>{let r="";for(let n in t){let o=t[n];typeof o=="boolean"&&o?r+=` ${n}`:typeof o=="string"?r+=` ${o}`:typeof o=="function"&&(r+=` ${O1(o,e)}`)}return r},jI=(t,e,r)=>{if(!t)return;let{key:n}=e;t===!0&&(t=e.classlist={key:n}),typeof t=="string"&&(t=e.classlist={default:t}),t!==null&&typeof t=="object"&&!Array.isArray(t)&&(t=NI(t,e));let o=t.replace(FI," ").trim();if(r&&typeof r.setAttribute=="function")r.setAttribute("class",o);else if(r)try{r.className=o}catch{}return o},BI=()=>(t,e,r)=>{let n=O1(t,e);if(t){let{__ref:o}=e;o.__class.style=n}R1()(e.classlist,e,e.state,!0)},R1=()=>(t,e,r,n)=>{if(e.style&&!n)return;let{__ref:o}=e,{__class:s,__classNames:i}=o;if(!(t===null||typeof t!="object"||Array.isArray(t))){e.class&&(i.classProps=e.class),e.attr?.class&&(i.class=e.attr.class);for(let a in s){let c=s[a];if(!c){delete i[a];continue}let l;typeof c=="string"||typeof c=="number"?l=c:typeof c=="boolean"?l=e.key:l=he(c),i[a]=l}for(let a in i)a==="classProps"||a==="class"||s[a]===void 0&&delete i[a];e.node&&jI(i,e,e.node)}},VI=()=>({style:BI(),classlist:R1()}),UI=["useReset","useVariable","useFontImport","useIconSprite","useSvgSprite","useDocumentTheme","useDefaultIcons","useDefaultConfig","verbose","globalTheme"],Q_=new WeakSet,tx=!1,zI=t=>!!t&&typeof t=="object",P1=(t,e)=>{let r=e.document||(e.parent&&e.parent.documentElement?e.parent:null)||document,n=e.initOptions||{},o=e.registry||VI(),s=e.designSystem?at(lt(e.designSystem),lt(Cc),ue):lt(Cc),i={};for(let h of UI)e[h]!==void 0&&(i[h]=e[h]);let a,c=zI(r),f=c&&Q_.has(r)&&!e.skipDesignSystemInit,u=!f&&!tx,d=f?`[data-smbls-app="${t}"]`:":root";if(e.scopeSelector=d,e.skipDesignSystemInit){if(a=A(t)||A(),a&&(a.__domDocument=r),a?.CSS_VARS){ct(a);try{xt({[d]:a.CSS_VARS}),a.CSS_MEDIA_VARS&&xt(td(a.CSS_MEDIA_VARS,d));let h=Yn(a.cssSkinVars,a.cssSkinFallback,d);Object.keys(h).length&&xt(h)}finally{it()}}}else if(u){let h=A();h&&(h.__domDocument=r),a=Ar(s,{key:t,document:r,files:e.files,assets:e.assets,scopeSelector:d,...nd,...i,...n}),a&&a!==h&&(a.__domDocument=r),c&&Q_.add(r),tx=!0}else{let h=Da(t,s,{cleanBase:!0});for(let m in i)h[m]=i[m];if(h.__domDocument=r,f){let m=t.replace(/[^a-zA-Z0-9]/g,"").substring(0,6);e.cssPrefix=m,h.varPrefix=m}ct(h);try{a=Ar(h,{key:t,document:r,files:e.files,assets:e.assets,scopeSelector:d,...nd,...i,...n})}finally{it()}c&&Q_.add(r),tx=!0}let g=a?.CONFIG||a,p=g?.font;if(p){ct(g);try{m1(p)}finally{it()}}return[a,o]},D1=(t,e)=>{let r={};e.state&&at(r,e.state),t&&t.state&&at(r,t.state);let n=e.polyglot;if(n?.translations){let o=null;try{typeof localStorage<"u"&&(o=localStorage.getItem(n.storageLangKey||"smbls_lang")||localStorage.getItem("lang"))}catch{}let s=o||r.lang||n.defaultLang||"en";o&&o!==r.lang&&(r.lang=o);let i=new Set,a=new Set,c=(u,d)=>{if(!a.has(u)){if(!On(e,u,r)){i.add(u);return}r[u]=d,a.add(u),Je(e,u,d)}},l=n.translations[s];if(l&&typeof l=="object")for(let u in l)c(u,l[u]);let f=new Set(n.languages||[]);for(let u in n.translations)f.has(u)||c(u,n.translations[u]);i.size&&n.verbose!==!1&&e.verbose!==!1&&console.warn(`[polyglot] ${i.size} translation key${i.size===1?"":"s"} collide${i.size===1?"s":""} with a declared root-state key (${[...i].join(", ")}) \u2014 the declared value wins and the translation is NOT seeded into state. Rename the translation key, or read it with \`{{ key | polyglot }}\` instead of a bare \`{{ key }}\`.`)}return r.isRootState=!0,lt(r)},L1=(t,e)=>{v(t.routes)&&v(e.pages)&&bt(t.routes,e.pages);let r=t.routes||e.pages||{},n=[];for(let o in r){if(o.charCodeAt(0)===47)continue;let i="/"+(o==="index"?"":o);Object.prototype.hasOwnProperty.call(r,i)?n.push(`${o} -> ${i}`):r[i]=r[o],delete r[o]}return n.length&&e&&e.verbose!==!1&&console.warn(`[smbls] preparePages kept ${n.length} explicitly declared route${n.length===1?"":"s"} over a same-named page key (${n.join(", ")}). A bare page NAME never overwrites a declared '/route'. This usually means a shared library ships a page under its export name that collides with one of your routes \u2014 add it to that library's ignoreList if you did not intend the collision.`),r},I1=t=>{ba(t,t.sharedLibraries)};var Xc={polyglot:Ic,getLocalStateLang:Nc,getActiveLang:ln,getLang:ln,setLang:Mc,getLanguages:Lc,loadTranslations:$c,upsertTranslation:Fc};Qi();var He=Object.create(null);He.open="0";He.close="1";He.ping="2";He.pong="3";He.message="4";He.upgrade="5";He.noop="6";var Zc=Object.create(null);Object.keys(He).forEach(t=>{Zc[He[t]]=t});var Jc={type:"error",data:"parser error"};var F1=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",N1=typeof ArrayBuffer=="function",j1=t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t&&t.buffer instanceof ArrayBuffer,Qc=({type:t,data:e},r,n)=>F1&&e instanceof Blob?r?n(e):$1(e,n):N1&&(e instanceof ArrayBuffer||j1(e))?r?n(e):$1(new Blob([e]),n):n(He[t]+(e||"")),$1=(t,e)=>{let r=new FileReader;return r.onload=function(){let n=r.result.split(",")[1];e("b"+(n||""))},r.readAsDataURL(t)};function M1(t){return t instanceof Uint8Array?t:t instanceof ArrayBuffer?new Uint8Array(t):new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}var rx;function B1(t,e){if(F1&&t.data instanceof Blob)return t.data.arrayBuffer().then(M1).then(e);if(N1&&(t.data instanceof ArrayBuffer||j1(t.data)))return e(M1(t.data));Qc(t,!1,r=>{rx||(rx=new TextEncoder),e(rx.encode(r))})}var V1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",tl=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let t=0;t<V1.length;t++)tl[V1.charCodeAt(t)]=t;var U1=t=>{let e=t.length*.75,r=t.length,n,o=0,s,i,a,c;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);let l=new ArrayBuffer(e),f=new Uint8Array(l);for(n=0;n<r;n+=4)s=tl[t.charCodeAt(n)],i=tl[t.charCodeAt(n+1)],a=tl[t.charCodeAt(n+2)],c=tl[t.charCodeAt(n+3)],f[o++]=s<<2|i>>4,f[o++]=(i&15)<<4|a>>2,f[o++]=(a&3)<<6|c&63;return l};var HI=typeof ArrayBuffer=="function",el=(t,e)=>{if(typeof t!="string")return{type:"message",data:z1(t,e)};let r=t.charAt(0);return r==="b"?{type:"message",data:WI(t.substring(1),e)}:Zc[r]?t.length>1?{type:Zc[r],data:t.substring(1)}:{type:Zc[r]}:Jc},WI=(t,e)=>{if(HI){let r=U1(t);return z1(r,e)}else return{base64:!0,data:t}},z1=(t,e)=>e==="blob"?t instanceof Blob?t:new Blob([t]):t instanceof ArrayBuffer?t:t.buffer;var H1="",W1=(t,e)=>{let r=t.length,n=new Array(r),o=0;t.forEach((s,i)=>{Qc(s,!1,a=>{n[i]=a,++o===r&&e(n.join(H1))})})},q1=(t,e)=>{let r=t.split(H1),n=[];for(let o=0;o<r.length;o++){let s=el(r[o],e);if(n.push(s),s.type==="error")break}return n};function K1(){return new TransformStream({transform(t,e){B1(t,r=>{let n=r.length,o;if(n<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,n);else if(n<65536){o=new Uint8Array(3);let s=new DataView(o.buffer);s.setUint8(0,126),s.setUint16(1,n)}else{o=new Uint8Array(9);let s=new DataView(o.buffer);s.setUint8(0,127),s.setBigUint64(1,BigInt(n))}t.data&&typeof t.data!="string"&&(o[0]|=128),e.enqueue(o),e.enqueue(r)})}})}var nx;function Ad(t){return t.reduce((e,r)=>e+r.length,0)}function Td(t,e){if(t[0].length===e)return t.shift();let r=new Uint8Array(e),n=0;for(let o=0;o<e;o++)r[o]=t[0][n++],n===t[0].length&&(t.shift(),n=0);return t.length&&n<t[0].length&&(t[0]=t[0].slice(n)),r}function G1(t,e){nx||(nx=new TextDecoder);let r=[],n=0,o=-1,s=!1;return new TransformStream({transform(i,a){for(r.push(i);;){if(n===0){if(Ad(r)<1)break;let c=Td(r,1);s=(c[0]&128)===128,o=c[0]&127,o<126?n=3:o===126?n=1:n=2}else if(n===1){if(Ad(r)<2)break;let c=Td(r,2);o=new DataView(c.buffer,c.byteOffset,c.length).getUint16(0),n=3}else if(n===2){if(Ad(r)<8)break;let c=Td(r,8),l=new DataView(c.buffer,c.byteOffset,c.length),f=l.getUint32(0);if(f>Math.pow(2,21)-1){a.enqueue(Jc);break}o=f*Math.pow(2,32)+l.getUint32(4),n=3}else{if(Ad(r)<o)break;let c=Td(r,o);a.enqueue(el(s?c:nx.decode(c),e)),n=0}if(o===0||o>t){a.enqueue(Jc);break}}}})}var ox=4;function ht(t){if(t)return qI(t)}function qI(t){for(var e in ht.prototype)t[e]=ht.prototype[e];return t}ht.prototype.on=ht.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+t]=this._callbacks["$"+t]||[]).push(e),this};ht.prototype.once=function(t,e){function r(){this.off(t,r),e.apply(this,arguments)}return r.fn=e,this.on(t,r),this};ht.prototype.off=ht.prototype.removeListener=ht.prototype.removeAllListeners=ht.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var r=this._callbacks["$"+t];if(!r)return this;if(arguments.length==1)return delete this._callbacks["$"+t],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===e||n.fn===e){r.splice(o,1);break}return r.length===0&&delete this._callbacks["$"+t],this};ht.prototype.emit=function(t){this._callbacks=this._callbacks||{};for(var e=new Array(arguments.length-1),r=this._callbacks["$"+t],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,e)}return this};ht.prototype.emitReserved=ht.prototype.emit;ht.prototype.listeners=function(t){return this._callbacks=this._callbacks||{},this._callbacks["$"+t]||[]};ht.prototype.hasListeners=function(t){return!!this.listeners(t).length};var Or=typeof Promise=="function"&&typeof Promise.resolve=="function"?e=>Promise.resolve().then(e):(e,r)=>r(e,0),Yt=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),Y1="arraybuffer";function Od(t,...e){return e.reduce((r,n)=>(t.hasOwnProperty(n)&&(r[n]=t[n]),r),{})}var KI=Yt.setTimeout,GI=Yt.clearTimeout;function Rr(t,e){e.useNativeTimers?(t.setTimeoutFn=KI.bind(Yt),t.clearTimeoutFn=GI.bind(Yt)):(t.setTimeoutFn=Yt.setTimeout.bind(Yt),t.clearTimeoutFn=Yt.clearTimeout.bind(Yt))}var YI=1.33;function X1(t){return typeof t=="string"?XI(t):Math.ceil((t.byteLength||t.size)*YI)}function XI(t){let e=0,r=0;for(let n=0,o=t.length;n<o;n++)e=t.charCodeAt(n),e<128?r+=1:e<2048?r+=2:e<55296||e>=57344?r+=3:(n++,r+=4);return r}function Rd(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Z1(t){let e="";for(let r in t)t.hasOwnProperty(r)&&(e.length&&(e+="&"),e+=encodeURIComponent(r)+"="+encodeURIComponent(t[r]));return e}function J1(t){let e={},r=t.split("&");for(let n=0,o=r.length;n<o;n++){let s=r[n].split("=");e[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}return e}var Pd=class extends Error{constructor(e,r,n){super(e),this.description=r,this.context=n,this.type="TransportError"}},Pr=class extends ht{constructor(e){super(),this.writable=!1,Rr(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,r,n){return super.emitReserved("error",new Pd(e,r,n)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(e){this.readyState==="open"&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){let r=el(e,this.socket.binaryType);this.onPacket(r)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,r={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(r)}_hostname(){let e=this.opts.hostname;return e.indexOf(":")===-1?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(e){let r=Z1(e);return r.length?"?"+r:""}};var rl=class extends Pr{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";let r=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let n=0;this._polling&&(n++,this.once("pollComplete",function(){--n||r()})),this.writable||(n++,this.once("drain",function(){--n||r()}))}else r()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){let r=n=>{if(this.readyState==="opening"&&n.type==="open"&&this.onOpen(),n.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(n)};q1(e,this.socket.binaryType).forEach(r),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){let e=()=>{this.write([{type:"close"}])};this.readyState==="open"?e():this.once("open",e)}write(e){this.writable=!1,W1(e,r=>{this.doWrite(r,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){let e=this.opts.secure?"https":"http",r=this.query||{};return this.opts.timestampRequests!==!1&&(r[this.opts.timestampParam]=Rd()),!this.supportsBinary&&!r.sid&&(r.b64=1),this.createUri(e,r)}};var Q1=!1;try{Q1=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}var tA=Q1;function ZI(){}var sx=class extends rl{constructor(e){if(super(e),typeof location<"u"){let r=location.protocol==="https:",n=location.port;n||(n=r?"443":"80"),this.xd=typeof location<"u"&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,r){let n=this.request({method:"POST",data:e});n.on("success",r),n.on("error",(o,s)=>{this.onError("xhr post error",o,s)})}doPoll(){let e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(r,n)=>{this.onError("xhr poll error",r,n)}),this.pollXhr=e}},pn=class t extends ht{constructor(e,r,n){super(),this.createRequest=e,Rr(this,n),this._opts=n,this._method=n.method||"GET",this._uri=r,this._data=n.data!==void 0?n.data:null,this._create()}_create(){var e;let r=Od(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");r.xdomain=!!this._opts.xd;let n=this._xhr=this.createRequest(r);try{n.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){n.setDisableHeaderCheck&&n.setDisableHeaderCheck(!0);for(let o in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(o)&&n.setRequestHeader(o,this._opts.extraHeaders[o])}}catch{}if(this._method==="POST")try{n.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{n.setRequestHeader("Accept","*/*")}catch{}(e=this._opts.cookieJar)===null||e===void 0||e.addCookies(n),"withCredentials"in n&&(n.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(n.timeout=this._opts.requestTimeout),n.onreadystatechange=()=>{var o;n.readyState===3&&((o=this._opts.cookieJar)===null||o===void 0||o.parseCookies(n.getResponseHeader("set-cookie"))),n.readyState===4&&(n.status===200||n.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof n.status=="number"?n.status:0)},0))},n.send(this._data)}catch(o){this.setTimeoutFn(()=>{this._onError(o)},0);return}typeof document<"u"&&(this._index=t.requestsCount++,t.requests[this._index]=this)}_onError(e){this.emitReserved("error",e,this._xhr),this._cleanup(!0)}_cleanup(e){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=ZI,e)try{this._xhr.abort()}catch{}typeof document<"u"&&delete t.requests[this._index],this._xhr=null}}_onLoad(){let e=this._xhr.responseText;e!==null&&(this.emitReserved("data",e),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};pn.requestsCount=0;pn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",eA);else if(typeof addEventListener=="function"){let t="onpagehide"in Yt?"pagehide":"unload";addEventListener(t,eA,!1)}}function eA(){for(let t in pn.requests)pn.requests.hasOwnProperty(t)&&pn.requests[t].abort()}var JI=(function(){let t=rA({xdomain:!1});return t&&t.responseType!==null})(),hn=class extends sx{constructor(e){super(e);let r=e&&e.forceBase64;this.supportsBinary=JI&&!r}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new pn(rA,this.uri(),e)}};function rA(t){let e=t.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!e||tA))return new XMLHttpRequest}catch{}if(!e)try{return new Yt[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}var nA=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative",ax=class extends Pr{get name(){return"websocket"}doOpen(){let e=this.uri(),r=this.opts.protocols,n=nA?{}:Od(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,r,n)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let r=0;r<e.length;r++){let n=e[r],o=r===e.length-1;Qc(n,this.supportsBinary,s=>{try{this.doWrite(n,s)}catch{}o&&Or(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?"wss":"ws",r=this.query||{};return this.opts.timestampRequests&&(r[this.opts.timestampParam]=Rd()),this.supportsBinary||(r.b64=1),this.createUri(e,r)}},ix=Yt.WebSocket||Yt.MozWebSocket,gn=class extends ax{createSocket(e,r,n){return nA?new ix(e,r,n):r?new ix(e,r):new ix(e)}doWrite(e,r){this.ws.send(r)}};var zs=class extends Pr{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved("error",e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let r=G1(Number.MAX_SAFE_INTEGER,this.socket.binaryType),n=e.readable.pipeThrough(r).getReader(),o=K1();o.readable.pipeTo(e.writable),this._writer=o.writable.getWriter();let s=()=>{n.read().then(({done:a,value:c})=>{a||(this.onPacket(c),s())}).catch(a=>{})};s();let i={type:"open"};this.query.sid&&(i.data=`{"sid":"${this.query.sid}"}`),this._writer.write(i).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let r=0;r<e.length;r++){let n=e[r],o=r===e.length-1;this._writer.write(n).then(()=>{o&&Or(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)===null||e===void 0||e.close()}};var cx={websocket:gn,webtransport:zs,polling:hn};var QI=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,t$=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Hs(t){if(t.length>8e3)throw"URI too long";let e=t,r=t.indexOf("["),n=t.indexOf("]");r!=-1&&n!=-1&&(t=t.substring(0,r)+t.substring(r,n).replace(/:/g,";")+t.substring(n,t.length));let o=QI.exec(t||""),s={},i=14;for(;i--;)s[t$[i]]=o[i]||"";return r!=-1&&n!=-1&&(s.source=e,s.host=s.host.substring(1,s.host.length-1).replace(/;/g,":"),s.authority=s.authority.replace("[","").replace("]","").replace(/;/g,":"),s.ipv6uri=!0),s.pathNames=e$(s,s.path),s.queryKey=r$(s,s.query),s}function e$(t,e){let r=/\/{2,9}/g,n=e.replace(r,"/").split("/");return(e.slice(0,1)=="/"||e.length===0)&&n.splice(0,1),e.slice(-1)=="/"&&n.splice(n.length-1,1),n}function r$(t,e){let r={};return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(n,o,s){o&&(r[o]=s)}),r}var lx=typeof addEventListener=="function"&&typeof removeEventListener=="function",Dd=[];lx&&addEventListener("offline",()=>{Dd.forEach(t=>t())},!1);var po=class t extends ht{constructor(e,r){if(super(),this.binaryType=Y1,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&typeof e=="object"&&(r=e,e=null),e){let n=Hs(e);r.hostname=n.host,r.secure=n.protocol==="https"||n.protocol==="wss",r.port=n.port,n.query&&(r.query=n.query)}else r.host&&(r.hostname=Hs(r.host).host);Rr(this,r),this.secure=r.secure!=null?r.secure:typeof location<"u"&&location.protocol==="https:",r.hostname&&!r.port&&(r.port=this.secure?"443":"80"),this.hostname=r.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=r.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},r.transports.forEach(n=>{let o=n.prototype.name;this.transports.push(o),this._transportsByName[o]=n}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},r),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=J1(this.opts.query)),lx&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Dd.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){let r=Object.assign({},this.opts.query);r.EIO=ox,r.transport=e,this.id&&(r.sid=this.id);let n=Object.assign({},this.opts,{query:r,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let e=this.opts.rememberUpgrade&&t.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";let r=this.createTransport(e);r.open(),this.setTransport(r)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",r=>this._onClose("transport close",r))}onOpen(){this.readyState="open",t.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(e){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",e),this.emitReserved("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":let r=new Error("server error");r.code=e.data,this._onError(r);break;case"message":this.emitReserved("data",e.data),this.emitReserved("message",e.data);break}}onHandshake(e){this.emitReserved("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let r=1;for(let n=0;n<this.writeBuffer.length;n++){let o=this.writeBuffer[n].data;if(o&&(r+=X1(o)),n>0&&r>this._maxPayload)return this.writeBuffer.slice(0,n);r+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,Or(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),e}write(e,r,n){return this._sendPacket("message",e,r,n),this}send(e,r,n){return this._sendPacket("message",e,r,n),this}_sendPacket(e,r,n,o){if(typeof r=="function"&&(o=r,r=void 0),typeof n=="function"&&(o=n,n=null),this.readyState==="closing"||this.readyState==="closed")return;n=n||{},n.compress=n.compress!==!1;let s={type:e,data:r,options:n};this.emitReserved("packetCreate",s),this.writeBuffer.push(s),o&&this.once("flush",o),this.flush()}close(){let e=()=>{this._onClose("forced close"),this.transport.close()},r=()=>{this.off("upgrade",r),this.off("upgradeError",r),e()},n=()=>{this.once("upgrade",r),this.once("upgradeError",r)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(e){if(t.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",e),this._onClose("transport error",e)}_onClose(e,r){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),lx&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){let n=Dd.indexOf(this._offlineEventListener);n!==-1&&Dd.splice(n,1)}this.readyState="closed",this.id=null,this.emitReserved("close",e,r),this.writeBuffer=[],this._prevBufferLen=0}}};po.protocol=ox;var Ld=class extends po{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let r=this.createTransport(e),n=!1;po.priorWebsocketSuccess=!1;let o=()=>{n||(r.send([{type:"ping",data:"probe"}]),r.once("packet",u=>{if(!n)if(u.type==="pong"&&u.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",r),!r)return;po.priorWebsocketSuccess=r.name==="websocket",this.transport.pause(()=>{n||this.readyState!=="closed"&&(f(),this.setTransport(r),r.send([{type:"upgrade"}]),this.emitReserved("upgrade",r),r=null,this.upgrading=!1,this.flush())})}else{let d=new Error("probe error");d.transport=r.name,this.emitReserved("upgradeError",d)}}))};function s(){n||(n=!0,f(),r.close(),r=null)}let i=u=>{let d=new Error("probe error: "+u);d.transport=r.name,s(),this.emitReserved("upgradeError",d)};function a(){i("transport closed")}function c(){i("socket closed")}function l(u){r&&u.name!==r.name&&s()}let f=()=>{r.removeListener("open",o),r.removeListener("error",i),r.removeListener("close",a),this.off("close",c),this.off("upgrading",l)};r.once("open",o),r.once("error",i),r.once("close",a),this.once("close",c),this.once("upgrading",l),this._upgrades.indexOf("webtransport")!==-1&&e!=="webtransport"?this.setTimeoutFn(()=>{n||r.open()},200):r.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let r=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&r.push(e[n]);return r}},Ws=class extends Ld{constructor(e,r={}){let n=typeof e=="object"?e:r;(!n.transports||n.transports&&typeof n.transports[0]=="string")&&(n.transports=(n.transports||["polling","websocket","webtransport"]).map(o=>cx[o]).filter(o=>!!o)),super(e,n)}};var kz=Ws.protocol;function oA(t,e="",r){let n=t;r=r||typeof location<"u"&&location,t==null&&(t=r.protocol+"//"+r.host),typeof t=="string"&&(t.charAt(0)==="/"&&(t.charAt(1)==="/"?t=r.protocol+t:t=r.host+t),/^(https?|wss?):\/\//.test(t)||(typeof r<"u"?t=r.protocol+"//"+t:t="https://"+t),n=Hs(t)),n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443")),n.path=n.path||"/";let s=n.host.indexOf(":")!==-1?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+s+":"+n.port+e,n.href=n.protocol+"://"+s+(r&&r.port===n.port?"":":"+n.port),n}var mx={};$(mx,{Decoder:()=>hx,Encoder:()=>px,PacketType:()=>H,isPacketValid:()=>k$,protocol:()=>gA});var o$=typeof ArrayBuffer=="function",s$=t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer,sA=Object.prototype.toString,i$=typeof Blob=="function"||typeof Blob<"u"&&sA.call(Blob)==="[object BlobConstructor]",a$=typeof File=="function"||typeof File<"u"&&sA.call(File)==="[object FileConstructor]";function ol(t){return o$&&(t instanceof ArrayBuffer||s$(t))||i$&&t instanceof Blob||a$&&t instanceof File}function nl(t,e){if(!t||typeof t!="object")return!1;if(Array.isArray(t)){for(let r=0,n=t.length;r<n;r++)if(nl(t[r]))return!0;return!1}if(ol(t))return!0;if(t.toJSON&&typeof t.toJSON=="function"&&arguments.length===1)return nl(t.toJSON(),!0);for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&nl(t[r]))return!0;return!1}function iA(t){let e=[],r=t.data,n=t;return n.data=fx(r,e),n.attachments=e.length,{packet:n,buffers:e}}function fx(t,e){if(!t)return t;if(ol(t)){let r={_placeholder:!0,num:e.length};return e.push(t),r}else if(Array.isArray(t)){let r=new Array(t.length);for(let n=0;n<t.length;n++)r[n]=fx(t[n],e);return r}else if(typeof t=="object"&&!(t instanceof Date)){let r={};for(let n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=fx(t[n],e));return r}return t}function aA(t,e){return t.data=ux(t.data,e),delete t.attachments,t}function ux(t,e){if(!t)return t;if(t&&t._placeholder===!0){if(typeof t.num=="number"&&t.num>=0&&t.num<e.length)return e[t.num];throw new Error("illegal attachments")}else if(Array.isArray(t))for(let r=0;r<t.length;r++)t[r]=ux(t[r],e);else if(typeof t=="object")for(let r in t)Object.prototype.hasOwnProperty.call(t,r)&&(t[r]=ux(t[r],e));return t}var pA=uT(dA(),1),dx=(0,pA.default)("socket.io-parser"),hA=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],gA=5,H;(function(t){t[t.CONNECT=0]="CONNECT",t[t.DISCONNECT=1]="DISCONNECT",t[t.EVENT=2]="EVENT",t[t.ACK=3]="ACK",t[t.CONNECT_ERROR=4]="CONNECT_ERROR",t[t.BINARY_EVENT=5]="BINARY_EVENT",t[t.BINARY_ACK=6]="BINARY_ACK"})(H||(H={}));var px=class{constructor(e){this.replacer=e}encode(e){return dx("encoding packet %j",e),(e.type===H.EVENT||e.type===H.ACK)&&nl(e)?this.encodeAsBinary({type:e.type===H.EVENT?H.BINARY_EVENT:H.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let r=""+e.type;return(e.type===H.BINARY_EVENT||e.type===H.BINARY_ACK)&&(r+=e.attachments+"-"),e.nsp&&e.nsp!=="/"&&(r+=e.nsp+","),e.id!=null&&(r+=e.id),e.data!=null&&(r+=JSON.stringify(e.data,this.replacer)),dx("encoded %j as %s",e,r),r}encodeAsBinary(e){let r=iA(e),n=this.encodeAsString(r.packet),o=r.buffers;return o.unshift(n),o}},hx=class t extends ht{constructor(e){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof e=="function"?{reviver:e}:e)}add(e){let r;if(typeof e=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");r=this.decodeString(e);let n=r.type===H.BINARY_EVENT;n||r.type===H.BINARY_ACK?(r.type=n?H.EVENT:H.ACK,this.reconstructor=new gx(r),r.attachments===0&&super.emitReserved("decoded",r)):super.emitReserved("decoded",r)}else if(ol(e)||e.base64)if(this.reconstructor)r=this.reconstructor.takeBinaryData(e),r&&(this.reconstructor=null,super.emitReserved("decoded",r));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+e)}decodeString(e){let r=0,n={type:Number(e.charAt(0))};if(H[n.type]===void 0)throw new Error("unknown packet type "+n.type);if(n.type===H.BINARY_EVENT||n.type===H.BINARY_ACK){let s=r+1;for(;e.charAt(++r)!=="-"&&r!=e.length;);let i=e.substring(s,r);if(i!=Number(i)||e.charAt(r)!=="-")throw new Error("Illegal attachments");let a=Number(i);if(!mA(a)||a<0)throw new Error("Illegal attachments");if(a>this.opts.maxAttachments)throw new Error("too many attachments");n.attachments=a}if(e.charAt(r+1)==="/"){let s=r+1;for(;++r&&!(e.charAt(r)===","||r===e.length););n.nsp=e.substring(s,r)}else n.nsp="/";let o=e.charAt(r+1);if(o!==""&&Number(o)==o){let s=r+1;for(;++r;){let i=e.charAt(r);if(i==null||Number(i)!=i){--r;break}if(r===e.length)break}n.id=Number(e.substring(s,r+1))}if(e.charAt(++r)){let s=this.tryParse(e.substr(r));if(t.isPayloadValid(n.type,s))n.data=s;else throw new Error("invalid payload")}return dx("decoded %s as %j",e,n),n}tryParse(e){try{return JSON.parse(e,this.opts.reviver)}catch{return!1}}static isPayloadValid(e,r){switch(e){case H.CONNECT:return Md(r);case H.DISCONNECT:return r===void 0;case H.CONNECT_ERROR:return typeof r=="string"||Md(r);case H.EVENT:case H.BINARY_EVENT:return Array.isArray(r)&&(typeof r[0]=="number"||typeof r[0]=="string"&&hA.indexOf(r[0])===-1);case H.ACK:case H.BINARY_ACK:return Array.isArray(r)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}},gx=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let r=aA(this.reconPack,this.buffers);return this.finishedReconstruction(),r}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function x$(t){return typeof t=="string"}var mA=Number.isInteger||function(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t};function w$(t){return t===void 0||mA(t)}function Md(t){return Object.prototype.toString.call(t)==="[object Object]"}function S$(t,e){switch(t){case H.CONNECT:return e===void 0||Md(e);case H.DISCONNECT:return e===void 0;case H.EVENT:return Array.isArray(e)&&(typeof e[0]=="number"||typeof e[0]=="string"&&hA.indexOf(e[0])===-1);case H.ACK:return Array.isArray(e);case H.CONNECT_ERROR:return typeof e=="string"||Md(e);default:return!1}}function k$(t){return x$(t.nsp)&&w$(t.id)&&S$(t.type,t.data)}function ye(t,e,r){return t.on(e,r),function(){t.off(e,r)}}var v$=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),Ys=class extends ht{constructor(e,r,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=r,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[ye(e,"open",this.onopen.bind(this)),ye(e,"packet",this.onpacket.bind(this)),ye(e,"error",this.onerror.bind(this)),ye(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...r){var n,o,s;if(v$.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(r.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(r),this;let i={type:H.EVENT,data:r};if(i.options={},i.options.compress=this.flags.compress!==!1,typeof r[r.length-1]=="function"){let f=this.ids++,u=r.pop();this._registerAckCallback(f,u),i.id=f}let a=(o=(n=this.io.engine)===null||n===void 0?void 0:n.transport)===null||o===void 0?void 0:o.writable,c=this.connected&&!(!((s=this.io.engine)===null||s===void 0)&&s._hasPingExpired());return this.flags.volatile&&!a||(c?(this.notifyOutgoingListeners(i),this.packet(i)):this.sendBuffer.push(i)),this.flags={},this}_registerAckCallback(e,r){var n;let o=(n=this.flags.timeout)!==null&&n!==void 0?n:this._opts.ackTimeout;if(o===void 0){this.acks[e]=r;return}let s=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let a=0;a<this.sendBuffer.length;a++)this.sendBuffer[a].id===e&&this.sendBuffer.splice(a,1);r.call(this,new Error("operation has timed out"))},o),i=(...a)=>{this.io.clearTimeoutFn(s),r.apply(this,a)};i.withError=!0,this.acks[e]=i}emitWithAck(e,...r){return new Promise((n,o)=>{let s=(i,a)=>i?o(i):n(a);s.withError=!0,r.push(s),this.emit(e,...r)})}_addToQueue(e){let r;typeof e[e.length-1]=="function"&&(r=e.pop());let n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((o,...s)=>(this._queue[0],o!==null?n.tryCount>this._opts.retries&&(this._queue.shift(),r&&r(o)):(this._queue.shift(),r&&r(null,...s)),n.pending=!1,this._drainQueue())),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let r=this._queue[0];r.pending&&!e||(r.pending=!0,r.tryCount++,this.flags=r.flags,this.emit.apply(this,r.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth=="function"?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:H.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,r){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,r),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(n=>String(n.id)===e)){let n=this.acks[e];delete this.acks[e],n.withError&&n.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case H.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case H.EVENT:case H.BINARY_EVENT:this.onevent(e);break;case H.ACK:case H.BINARY_ACK:this.onack(e);break;case H.DISCONNECT:this.ondisconnect();break;case H.CONNECT_ERROR:this.destroy();let n=new Error(e.data.message);n.data=e.data.data,this.emitReserved("connect_error",n);break}}onevent(e){let r=e.data||[];e.id!=null&&r.push(this.ack(e.id)),this.connected?this.emitEvent(r):this.receiveBuffer.push(Object.freeze(r))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let r=this._anyListeners.slice();for(let n of r)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]=="string"&&(this._lastOffset=e[e.length-1])}ack(e){let r=this,n=!1;return function(...o){n||(n=!0,r.packet({type:H.ACK,id:e,data:o}))}}onack(e){let r=this.acks[e.id];typeof r=="function"&&(delete this.acks[e.id],r.withError&&e.data.unshift(null),r.apply(this,e.data))}onconnect(e,r){this.id=e,this.recovered=r&&this._pid===r,this._pid=r,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved("connect")}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:H.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let r=this._anyListeners;for(let n=0;n<r.length;n++)if(e===r[n])return r.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let r=this._anyOutgoingListeners;for(let n=0;n<r.length;n++)if(e===r[n])return r.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let r=this._anyOutgoingListeners.slice();for(let n of r)n.apply(this,e.data)}}};function go(t){t=t||{},this.ms=t.min||100,this.max=t.max||1e4,this.factor=t.factor||2,this.jitter=t.jitter>0&&t.jitter<=1?t.jitter:0,this.attempts=0}go.prototype.duration=function(){var t=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var e=Math.random(),r=Math.floor(e*this.jitter*t);t=(Math.floor(e*10)&1)==0?t-r:t+r}return Math.min(t,this.max)|0};go.prototype.reset=function(){this.attempts=0};go.prototype.setMin=function(t){this.ms=t};go.prototype.setMax=function(t){this.max=t};go.prototype.setJitter=function(t){this.jitter=t};var Xs=class extends ht{constructor(e,r){var n;super(),this.nsps={},this.subs=[],e&&typeof e=="object"&&(r=e,e=void 0),r=r||{},r.path=r.path||"/socket.io",this.opts=r,Rr(this,r),this.reconnection(r.reconnection!==!1),this.reconnectionAttempts(r.reconnectionAttempts||1/0),this.reconnectionDelay(r.reconnectionDelay||1e3),this.reconnectionDelayMax(r.reconnectionDelayMax||5e3),this.randomizationFactor((n=r.randomizationFactor)!==null&&n!==void 0?n:.5),this.backoff=new go({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(r.timeout==null?2e4:r.timeout),this._readyState="closed",this.uri=e;let o=r.parser||mx;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=r.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var r;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(r=this.backoff)===null||r===void 0||r.setMin(e),this)}randomizationFactor(e){var r;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(r=this.backoff)===null||r===void 0||r.setJitter(e),this)}reconnectionDelayMax(e){var r;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(r=this.backoff)===null||r===void 0||r.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new Ws(this.uri,this.opts);let r=this.engine,n=this;this._readyState="opening",this.skipReconnect=!1;let o=ye(r,"open",function(){n.onopen(),e&&e()}),s=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),e?e(a):this.maybeReconnectOnOpen()},i=ye(r,"error",s);if(this._timeout!==!1){let a=this._timeout,c=this.setTimeoutFn(()=>{o(),s(new Error("timeout")),r.close()},a);this.opts.autoUnref&&c.unref(),this.subs.push(()=>{this.clearTimeoutFn(c)})}return this.subs.push(o),this.subs.push(i),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let e=this.engine;this.subs.push(ye(e,"ping",this.onping.bind(this)),ye(e,"data",this.ondata.bind(this)),ye(e,"error",this.onerror.bind(this)),ye(e,"close",this.onclose.bind(this)),ye(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(r){this.onclose("parse error",r)}}ondecoded(e){Or(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,r){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new Ys(this,e,r),this.nsps[e]=n),n}_destroy(e){let r=Object.keys(this.nsps);for(let n of r)if(this.nsps[n].active)return;this._close()}_packet(e){let r=this.encoder.encode(e);for(let n=0;n<r.length;n++)this.engine.write(r[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,r){var n;this.cleanup(),(n=this.engine)===null||n===void 0||n.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,r),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{let r=this.backoff.duration();this._reconnecting=!0;let n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),!e.skipReconnect&&e.open(o=>{o?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",o)):e.onreconnect()}))},r);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}};var sl={};function Zs(t,e){typeof t=="object"&&(e=t,t=void 0),e=e||{};let r=oA(t,e.path||"/socket.io"),n=r.source,o=r.id,s=r.path,i=sl[o]&&s in sl[o].nsps,a=e.forceNew||e["force new connection"]||e.multiplex===!1||i,c;return a?c=new Xs(n,e):(sl[o]||(sl[o]=new Xs(n,e)),c=sl[o]),r.query&&!e.query&&(e.query=r.queryKey),c.socket(r.path,e)}Object.assign(Zs,{Manager:Xs,Socket:Ys,io:Zs,connect:Zs});D();D();var Fd=new Set(["__proto__","constructor","prototype"]),yx=t=>{if(!Array.isArray(t))return!1;for(let e=0;e<t.length;e++)if(Fd.has(t[e]))return!1;return!0},yA=(t,e)=>{!t||!yx(e)||e.reduce((r,n,o,s)=>{if(r&&n in r){if(o!==s.length-1)return r[n];delete r[n]}},t)},bA=(t,e,r,n=!1)=>{!t||!yx(e)||e.reduce((o,s,i,a)=>{if(o){if(i!==a.length-1)return!o[s]&&n&&(o[s]={}),o[s];o[s]=r}},t)},Nd=(t,e)=>{let r=new Set;if(!Array.isArray(e))return r;for(let[n,o,s]of e)if(!(!Array.isArray(o)||!o.length))switch(r.add(o[0]),n){case"delete":yA(t,o);break;case"update":case"set":bA(t,o,s,!0);break;default:break}return r},_A=(t,e)=>{if(!e||typeof e!="object"||Array.isArray(e))return null;let r=t&&(t.__raw||t)||{},n=null;for(let o of Object.keys(e))Fd.has(o)||Object.prototype.hasOwnProperty.call(r,o)||(n||(n={}),n[o]=e[o]);return n},il=(t,e)=>{!t||!e||typeof e!="object"||(t.__rawDesignSystem=JSON.parse(JSON.stringify(e)))},xA=(t,e,r,n="designSystem")=>{for(let o in e){if(Fd.has(o))continue;let s=`${n}/${o}`;if(r.has(s))continue;let i=e[o],a=t[o];if(i&&typeof i=="object"&&!Array.isArray(i)){if(!a||typeof a!="object"||Array.isArray(a)){if(o in t)continue;t[o]={}}xA(t[o],i,r,s)}else o in t||(t[o]=Array.isArray(i)?JSON.parse(JSON.stringify(i)):i)}},bx=(t,e)=>{if(!t||!t.__rawDesignSystem)return null;if(Array.isArray(e)&&e.length){let o={designSystem:t.__rawDesignSystem};Nd(o,e)}let r=JSON.parse(JSON.stringify(t.__rawDesignSystem)),n=Array.isArray(t.sharedLibraries)?t.sharedLibraries:[];return _a(r,n,xA)};D();var wA=(t,e,r)=>{let n=!1;return(o={})=>{let{data:s}=o,{schema:i}=o;s&&(s=t.call("deepDestringifyFunctions",s,Array.isArray(s)?[]:{}),Object.entries(s).forEach(([a,c])=>{if(r[a]&&typeof r[a]=="object")if(a==="designSystem"){if(il(r,c),n){let l=bx(r);l&&Ar(l)}}else En(r[a],c);else r[a]=c}),n=!0,i&&(r.schema=i))}},SA=(t,e,r)=>(n={})=>{let{changes:o}=n;if(!o||!Array.isArray(o)||!o.length)return;o=t.call("deepDestringifyFunctions",o,Array.isArray(o)?[]:{});let s=o.filter(c=>Array.isArray(c)&&Array.isArray(c[1])&&c[1][0]==="designSystem"),i=s.length?o.filter(c=>!s.includes(c)):o,a=Nd(r,i);if(s.length&&a.add("designSystem"),a.has("designSystem")){let c=bx(r,s);c?Ar(c):r.__warnedNoRawDesignSystem||(r.__warnedNoRawDesignSystem=!0,console.warn("[sync] design-system op ignored: no raw design system was seeded on this client. Re-initing from the processed config would corrupt every token, so the update is skipped \u2014 reload to pick it up. Seed it at boot with seedRawDesignSystem(ctx, ds)."))}if(a.has("state")){let c=_A(e,r.state);if(c){let l=typeof e.$update=="function"?e.$update:e.update;typeof l=="function"&&l.call(e,c)}}if(["pages","components","snippets","functions","assets"].some(c=>a.has(c))){let{pathname:c,search:l,hash:f}=r.window.location;t.call("router",c+l+f,t.__ref.root,{},{scrollToTop:!1,force:!0})}};var C$={success:"green",error:"red",warning:"yellow"},kA=(t,e,r)=>{if(t.symbols){if(!r.connected){r.notifications.connected={title:"Connected",message:"to the Symbols live server"},r.update({connected:!0});let n=setTimeout(()=>{delete r.notifications.connected,e.notifications.content.connected.update({animation:"fadeOutDown"}),r.update({connected:!0}),clearTimeout(n)},3e3)}}else if(r.connected){r.notifications.connected={title:"Disconnected",type:"error"},r.update({connected:!1});let n=setTimeout(()=>{delete r.notifications.connected,e.notifications.content.connected&&e.notifications.content.connected.update({animation:"fadeOutDown"}),r.update({connected:!0}),clearTimeout(n)},3e3)}},vA={state:{notifications:[]},Notifications:{position:"fixed",left:"A2",bottom:"Z2",zIndex:"999",childExtends:"Notification",childProps:({state:t})=>({animationDuration:"C",background:C$[t.type||"success"],icon:null,Flex:{Title:{text:"{{ title }}"},P:{text:"{{ title }}"}},onRender:(e,r,n)=>{r.update({animation:"fadeInUp"})},onClick:(e,r,n)=>{delete n.notifications[r.key],r.update({animation:"fadeOutDown"}),n.onClose&&n.onClose(e,r,n)}}),IconText:null,childrenAs:"state",children:({state:t})=>t.notifications}};var E$=!1,A$=()=>E$?"http://localhost:8080":"https://api.symbols.app",T$=t=>{let e=t&&t.editor&&t.editor.socketUrl||t&&t.settings&&t.settings.socketUrl;return typeof e=="string"&&e?{mode:"collab",baseUrl:e}:t&&t.editor&&t.editor.runtime==="runner"?{mode:"runner",baseUrl:null}:{mode:null,baseUrl:null}},O$=async t=>{try{let e=t||A$(),r=await C.fetch(`${e}/service-token`,{method:"GET"}),n;try{let o=await r.clone().json();if(o&&typeof o.token=="string")return o.token.trim();n=await r.text()}catch{n=await r.text()}return(n||"").replace(/\s+/gu,"")||void 0}catch(e){console.error("[sync] Failed to fetch service-token",e)}},AA=(t,e,r,n)=>{t.on("snapshot",wA(e,r,n)),t.on("ops",SA(e,r,n)),t.on("clients",o=>{n.editor?.verbose&&kA(o,e,r)}),t.on("disconnect",o=>{n.editor?.verbose&&console.info("[sync] disconnected",o)})},R$=async(t,e,r,n)=>{let o=await O$(n);if(!o)return console.warn("[sync] no service token \u2014 collab disabled"),null;let s=r.key;if(!s)return console.warn("[sync] ctx.key missing \u2014 collab cannot authenticate"),null;let i=r.editor?.projectId||null,a=Zs(n,{path:"/collab-socket",transports:["websocket"],auth:{token:o,projectId:i,projectKey:s,branch:"main",live:!0,clientType:"platform"},reconnectionAttempts:1/0,reconnectionDelayMax:4e3});return a.on("connect",()=>{r.editor?.verbose&&console.info("[sync] connected (collab)")}),AA(a,t,e,r),a},P$=(t,e,r)=>{let n=Zs({transports:["websocket","polling"],reconnectionAttempts:1/0,reconnectionDelayMax:4e3});return n.on("connect",()=>{r.editor?.verbose!==!1&&console.info("[sync] connected (runner)")}),AA(n,t,e,r),n.on("reload",()=>{typeof C<"u"&&C.location&&C.location.reload()}),n},D$=async(t,e,r)=>{let{mode:n,baseUrl:o}=T$(r);return n?n==="collab"?R$(t,e,r,o):n==="runner"?P$(t,e,r):null:null},L$={onInit:D$};var TA=t=>typeof t>"u",CA=t=>!!(t?.editor?.socketUrl||t?.settings?.socketUrl),EA=t=>t?.editor?.runtime==="runner",OA=(t,e)=>{Array.isArray(t.extends)?t.extends.push(e):t.extends?t.extends=[t.extends,e]:t.extends=[e]},RA={name:"sync",beforeCreate(t,e){let r=e&&e.editor;(r&&!TA(r.liveSync)?r.liveSync:CA(e)||EA(e))&&(CA(e)&&!EA(e)&&!e?.key||OA(t,L$))}},PA={name:"notifications",beforeCreate(t,e){if(!e)return;let r=TA(e.notifications)?null:e.notifications,n=e.editor&&e.editor.verbose===!0;(r===!0||r!==!1&&n)&&OA(t,vA)}};var wx={};$(wx,{AlertTemplate:()=>Yd,ConfirmTemplate:()=>Gd,CustomTemplate:()=>Zd,ModalLayer:()=>Kd,ModalRoot:()=>qd,PromptTemplate:()=>Xd,windowsComponents:()=>xx});var _x={};$(_x,{alertDialog:()=>Hd,closeAllModals:()=>Ud,closeModal:()=>Bd,confirmDialog:()=>zd,getLayer:()=>jd,openModal:()=>Vd,promptDialog:()=>Wd,windowsFunctions:()=>Dr});function et(t){let e=t;for(;e;){if(e.layer!==void 0)return e.layer;e=e.parent}return null}function Js(t){let e=t;for(;e;){if(e.key==="ModalRoot")return e;if(e.ModalRoot&&e.ModalRoot.__ref)return e.ModalRoot;e=e.parent}let r=t?.getRoot?.();return r?.ModalRoot?r.ModalRoot:typeof globalThis<"u"&&globalThis.__SMBLS_WINDOWS_MODAL_ROOT__?.__ref?globalThis.__SMBLS_WINDOWS_MODAL_ROOT__:null}function jd(){return et(this)}var I$=(t,e)=>{let r=t&&t["ModalLayer_"+e],n=r?.node||r?.__ref?.node;!n||typeof n.style?.setProperty!="function"||(n.style.setProperty("display","none","important"),n.style.setProperty("opacity","0","important"),n.style.setProperty("visibility","hidden","important"),n.style.setProperty("pointer-events","none","important"))},DA=(t,e)=>{let r=t&&t["ModalLayer_"+e],n=r?.node||r?.__ref?.node;!n||typeof n.style?.removeProperty!="function"||(n.style.removeProperty("display"),n.style.removeProperty("opacity"),n.style.removeProperty("visibility"),n.style.removeProperty("pointer-events"))};function Bd(t){let e=Js(this);if(!e)return;let r=e.state?.stack||[];if(!r.length)return;let n,o,s;if(t){if(s=[],n=r.filter((i,a)=>{let c=i.id!==t;return c||s.push(a),c}),n.length===r.length)return;o=r.filter(i=>i.id===t)}else n=r.slice(0,-1),o=r.slice(-1),s=[r.length-1];e.state.update({stack:n});for(let i of s)I$(e,i);for(let i of o)if(typeof i.onClose=="function")try{i.onClose()}catch(a){console.warn("[windows] onClose threw:",a)}}function Vd(t={}){let e=Js(this);if(!e)return console.warn("[windows] openModal: ModalRoot is not mounted on the app root. Add `ModalRoot: {}` to your shell tree and import windowsComponents into context."),null;e.__modalIdCounter=(e.__modalIdCounter||0)+1;let r=t.id||`modal_${e.__modalIdCounter}_${Date.now().toString(36)}`,n={id:r,template:t.template||"custom",title:t.title,message:t.message,icon:t.icon,confirmText:t.confirmText,cancelText:t.cancelText,okText:t.okText,confirmTheme:t.confirmTheme,placeholder:t.placeholder,defaultValue:t.defaultValue,dismissOnBackdrop:t.dismissOnBackdrop,content:t.content,width:t.width,maxWidth:t.maxWidth,maxHeight:t.maxHeight,onConfirm:t.onConfirm,onCancel:t.onCancel,onOk:t.onOk,onClose:t.onClose},o=e.state?.stack||[];if(o.length>=5)return console.warn("[windows] openModal: stack already at the 5-layer maximum, dropping the new layer. Close some modals first."),null;let s=o.length;return DA(e,s),e.state.update({stack:[...o,n]}),r}function Ud(){let t=Js(this);!t||!t.state?.stack?.length||t.state.update({stack:[]})}function zd(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"confirm"})}function Hd(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"alert"})}function Wd(t){let e=typeof t=="string"?{message:t}:t||{};return this.call("openModal",{...e,template:"prompt"})}var Dr={openModal:Vd,closeModal:Bd,closeAllModals:Ud,confirmDialog:zd,alertDialog:Hd,promptDialog:Wd,getLayer:jd};var $$=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),LA=t=>{if(!t?.querySelectorAll)return[];let e=t.querySelectorAll($$),r=[];for(let n=0;n<e.length;n++){let o=e[n];(o.offsetParent!==null||o===document.activeElement)&&r.push(o)}return r},IA=t=>{let e=t.state?.stack||[];if(!e.length)return null;let r=t["ModalLayer_"+(e.length-1)];return r?.node||r?.__ref?.node||null},qd={tag:"div",position:"fixed",inset:"0",zIndex:"2000",pointerEvents:"none",state:{stack:[]},subscribeTo:["stack"],ModalLayer_0:{__slotIndex:0,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[0]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_1:{__slotIndex:1,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[1]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_2:{__slotIndex:2,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[2]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_3:{__slotIndex:3,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[3]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},ModalLayer_4:{__slotIndex:4,subscribeTo:["stack"],layer:(t,e)=>e?.stack?.[4]||null,opacity:t=>t.layer?"1":"0",visibility:t=>t.layer?"visible":"hidden",pointerEvents:t=>t.layer?"auto":"none"},onInit:(t,e)=>{if(typeof window>"u")return;globalThis.__SMBLS_WINDOWS_MODAL_ROOT__=t;let r=t.context;if(r){r.functions||(r.functions={});for(let a in Dr)a in r.functions||(r.functions[a]=Dr[a])}t.__modalOpeners=t.__modalOpeners||[],t.__prevStackLen=t.state&&t.state.stack&&t.state.stack.length||0;let n=()=>{let a=t.state?.stack||[];if(!a.length)return;let c=a.length-1,l=a[c];t.state.update({stack:a.slice(0,-1)});let f=t["ModalLayer_"+c],u=f?.node||f?.__ref?.node;if(u?.style?.setProperty&&(u.style.setProperty("display","none","important"),u.style.setProperty("opacity","0","important"),u.style.setProperty("visibility","hidden","important"),u.style.setProperty("pointer-events","none","important")),typeof l?.onClose=="function")try{l.onClose()}catch(d){console.warn("[windows] onClose threw:",d)}},o=a=>{let c=t.state?.stack;if(c?.length){if(a.key==="Tab"){let l=IA(t);if(!l)return;let f=LA(l);if(!f.length){a.preventDefault();let p=l.querySelector?.('[role="dialog"]')||l;try{p.focus?.()}catch{}return}let u=f[0],d=f[f.length-1],g=document.activeElement;if(!l.contains(g)){a.preventDefault();try{u.focus()}catch{}return}if(a.shiftKey&&g===u){a.preventDefault();try{d.focus()}catch{}}else if(!a.shiftKey&&g===d){a.preventDefault();try{u.focus()}catch{}}return}a.key!=="Escape"||a.defaultPrevented||c[c.length-1]?.dismissOnBackdrop!==!1&&(a.preventDefault(),n())}};window.addEventListener("keydown",o),t.__escHandler=o;let s=a=>{let c=t.state?.stack||[];if(a<0||a>=c.length)return;let l=c[a];t.state.update({stack:c.filter((d,g)=>g!==a)});let f=t["ModalLayer_"+a],u=f?.node||f?.__ref?.node;if(u?.style?.setProperty&&(u.style.setProperty("display","none","important"),u.style.setProperty("opacity","0","important"),u.style.setProperty("visibility","hidden","important"),u.style.setProperty("pointer-events","none","important")),typeof l?.onClose=="function")try{l.onClose()}catch(d){console.warn("[windows] onClose threw:",d)}},i=a=>{let c=t.state?.stack||[];if(!c.length)return;let l=a.target?.closest?.('[data-key="Close"]');if(l){for(let f=c.length-1;f>=0;f--){let u=t["ModalLayer_"+f],d=u?.node||u?.__ref?.node;if(d&&d.contains(l)){a.preventDefault(),a.stopPropagation(),s(f);return}}return}for(let f=c.length-1;f>=0;f--){let u=t["ModalLayer_"+f];if((u?.node||u?.__ref?.node)===a.target){if(c[f]?.dismissOnBackdrop===!1)return;a.preventDefault(),a.stopPropagation(),s(f);return}}};document.addEventListener("click",i,!0),t.__clickDelegate=i},onUpdate:t=>{if(typeof window>"u")return;let e=(t.state&&t.state.stack||[]).length,r=t.__prevStackLen||0;if(e!==r)if(t.__prevStackLen=e,t.__modalOpeners=t.__modalOpeners||[],e>r)t.__modalOpeners[e]=document.activeElement&&document.activeElement!==document.body?document.activeElement:t.__modalOpeners[e]||null,typeof requestAnimationFrame=="function"&&requestAnimationFrame(()=>{let n=IA(t);if(!n)return;let o=LA(n)[0]||n.querySelector&&n.querySelector('[role="dialog"]')||n;try{o.focus&&o.focus()}catch{}});else{let n=null;for(let o=r;o>e;o--)t.__modalOpeners[o]&&(n=n||t.__modalOpeners[o]),t.__modalOpeners[o]=null;if(n&&typeof n.focus=="function"&&n.isConnected!==!1)try{n.focus()}catch{}}},onDestroy:t=>{typeof window>"u"||(globalThis.__SMBLS_WINDOWS_MODAL_ROOT__===t&&(globalThis.__SMBLS_WINDOWS_MODAL_ROOT__=null),t.__escHandler&&(window.removeEventListener("keydown",t.__escHandler),delete t.__escHandler),t.__clickDelegate&&(document.removeEventListener("click",t.__clickDelegate,!0),delete t.__clickDelegate))}};var Kd={tag:"div",position:"fixed",inset:"0",alignItems:"center",justifyContent:"center",padding:"A",theme:"backdrop",transition:"opacity C defaultBezier",zIndex:(t,e)=>`${2e3+(t.__slotIndex||0)*10}`,display:(t,e)=>t.layer?"flex":"none",opacity:(t,e)=>t.layer?"1":"0",visibility:(t,e)=>t.layer?"visible":"hidden",pointerEvents:(t,e)=>t.layer?"auto":"none",ModalWindow:{attr:{role:"dialog","aria-modal":"true",tabindex:"-1","aria-labelledby":t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}},width:t=>et(t)?.width||"H",maxWidth:t=>et(t)?.maxWidth||"90vw",flow:"y",maxHeight:t=>et(t)?.maxHeight||"100%",animation:"modalIn",animationDuration:"D",animationTimingFunction:"springBezier",onClick:t=>t.stopPropagation(),onMousedown:t=>t.stopPropagation(),ModalHeader:{display:"none"},overflow:"visible",ConfirmTemplate:{hide:t=>et(t)?.template!=="confirm"},AlertTemplate:{hide:t=>et(t)?.template!=="alert"},PromptTemplate:{hide:t=>et(t)?.template!=="prompt"},CustomTemplate:{hide:t=>et(t)?.template!=="custom"}}};var Qs=(t,e,r)=>et(t)?.[e]||r,M$=t=>{let e=et(t)?.icon;return e===null||e===!1},Gd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",ModalHeader:{Hgroup:{H:{text:t=>Qs(t,"title","Are you sure?"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}},Icons:{hide:t=>M$(t),Indicator:{extends:"Icon",opacity:".7",icon:t=>Qs(t,"icon","warning")}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",P:{tag:"p",margin:"0",text:t=>Qs(t,"message","This action cannot be undone."),color:"dim"}},ModalFooter:{flow:"x",gap:"Z1",align:"center end",flexShrink:"0",CancelBtn:{extends:"CancelButton",text:t=>Qs(t,"cancelText","Cancel"),onClick:(t,e,r)=>{let n=et(e);if(n?.onCancel)try{n.onCancel()}catch(o){console.warn("[windows] confirm.onCancel threw:",o)}e.call("closeModal",n?.id)}},ConfirmBtn:{extends:"Button",theme:t=>Qs(t,"confirmTheme","primary"),text:t=>Qs(t,"confirmText","Confirm"),onClick:(t,e,r)=>{let n=et(e);if(n?.onConfirm)try{n.onConfirm()}catch(o){console.warn("[windows] confirm.onConfirm threw:",o)}e.call("closeModal",n?.id)}}}};var al=(t,e,r)=>et(t)?.[e]||r,Yd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",ModalHeader:{Hgroup:{H:{text:t=>al(t,"title","Notice"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}},Icons:{Indicator:{extends:"Icon",opacity:".7",icon:t=>al(t,"icon","info")}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",hide:t=>!al(t,"message",""),P:{tag:"p",margin:"0",text:t=>al(t,"message",""),color:"dim"}},ModalFooter:{flow:"x",align:"center end",flexShrink:"0",OkBtn:{extends:"Button",theme:"primary",text:t=>al(t,"okText","OK"),onClick:(t,e,r)=>{let n=et(e);if(n?.onOk)try{n.onOk()}catch(o){console.warn("[windows] alert.onOk threw:",o)}e.call("closeModal",n?.id)}}}};var ti=(t,e,r)=>et(t)?.[e]||r,Xd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",scope:{value:""},onRender:(t,e)=>{let r=et(t);if(!r||t.scope._seededLayerId===r.id)return;t.scope._seededLayerId=r.id,t.scope.value=r.defaultValue||"";let n=t.InputRow&&t.InputRow.node;n&&(n.value=t.scope.value)},onUpdate:(t,e)=>{let r=et(t);if(!r||t.scope._seededLayerId===r.id)return;t.scope._seededLayerId=r.id,t.scope.value=r.defaultValue||"";let n=t.InputRow&&t.InputRow.node;n&&(n.value=t.scope.value)},ModalHeader:{Hgroup:{H:{text:t=>ti(t,"title","Enter a value"),attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},P:{if:()=>!1}}},ModalBody:{flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",hide:t=>!ti(t,"message",""),P:{tag:"p",margin:"0",text:t=>ti(t,"message",""),color:"dim"}},InputRow:{extends:"Input",flexShrink:"0",autofocus:!0,placeholder:t=>ti(t,"placeholder",""),value:(t,e)=>t.parent.scope?.value||"",onInput:(t,e,r)=>{e.parent.scope.value=t.target.value},onKeydown:(t,e,r)=>{if(t.key!=="Enter")return;t.preventDefault();let n=et(e),o=e.parent.scope?.value||"";if(n?.onConfirm)try{n.onConfirm(o)}catch(s){console.warn("[windows] prompt.onConfirm threw:",s)}e.call("closeModal",n?.id)}},ModalFooter:{flow:"x",gap:"Z1",align:"center end",flexShrink:"0",CancelBtn:{extends:"CancelButton",text:t=>ti(t,"cancelText","Cancel"),onClick:(t,e,r)=>{let n=et(e);if(n?.onCancel)try{n.onCancel()}catch(o){console.warn("[windows] prompt.onCancel threw:",o)}e.call("closeModal",n?.id)}},ConfirmBtn:{extends:"Button",theme:"primary",text:t=>ti(t,"confirmText","OK"),onClick:(t,e,r)=>{let n=et(e),o=e.parent.parent.scope?.value||"";if(n?.onConfirm)try{n.onConfirm(o)}catch(s){console.warn("[windows] prompt.onConfirm threw:",s)}e.call("closeModal",n?.id)}}}};var Zd={tag:"div",flow:"y",gap:"B",flex:"1 1 auto",minHeight:"0",Title:{tag:"h2",text:t=>et(t)?.title||"",hide:t=>!et(t)?.title,position:"absolute",width:"1px",height:"1px",margin:"-1px",padding:"0",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0",attr:{id:t=>{let e=et(t)?.id;return e?"modal-title-"+e:null}}},Slot:{tag:"div",flex:"1 1 auto",minHeight:"0",overflowY:"auto",overscrollBehavior:"contain",onInit:t=>{let e=Y(()=>{let r=et(t),n=r?.content||null,o=r?.id||null;if(!n){t.__lastLayerId!=null&&(t.removeContent(),t.__lastLayerId=null);return}if(t.__lastLayerId!==o){t.__lastLayerId=o;try{t.set(n);let s=t.content?.context;if(s){s.functions||(s.functions={});for(let i in Dr)i in s.functions||(s.functions[i]=Dr[i])}}catch(s){console.warn("[windows] custom.content set failed:",s)}}});t.__ref&&t.__ref.__effects.push(e)}}};var $A={extends:"Button",theme:"tertiary"};var xx={ModalRoot:qd,ModalLayer:Kd,ConfirmTemplate:Gd,AlertTemplate:Yd,PromptTemplate:Xd,CustomTemplate:Zd,"smbls.CancelButton":$A};var Ax={};$(Ax,{Dropdown:()=>np,DropdownList:()=>op,DropdownParent:()=>sp,DropdownParentFocus:()=>ip,DropdownRoot:()=>ep,DropdownSiblingFocus:()=>ap,DropdownTrigger:()=>rp,dropdownComponents:()=>Ex});var MA=(t,e,r)=>({bottom:r-t.bottom,top:t.top,right:e-t.right,left:t.left}),F$=(t,e,r,n)=>{let o=MA(t,r,n),s=i=>o[i]>=e.height+8;return s("bottom")?"bottom":s("top")?"top":o.bottom>=o.top?"bottom":"top"},N$=(t,e,r,n,o)=>{let s=MA(e,n,o),i=t==="top"||t==="bottom"?r.height+8:r.width+8;if(s[t]>=i)return t;let a={top:"bottom",bottom:"top",left:"right",right:"left"}[t];return a&&s[a]>=i||a&&s[a]>s[t]?a:t};var Sx=(t,e,r)=>{let n;return t==="bottom"?n=r-e.bottom-16:t==="top"?n=e.top-16:n=r-16,Math.max(40,Math.floor(n))},Jd=(t,e,r)=>Math.max(e,Math.min(r,t)),Lr=(t,e,r="auto")=>{if(!t){let p=typeof window<"u"?window.innerHeight:768;return{left:0,top:0,side:"bottom",align:"start",maxHeight:Sx("center",null,p)}}let n=typeof window<"u"?window.innerWidth:1024,o=typeof window<"u"?window.innerHeight:768,s={width:Math.max(120,e?.width||0),height:Math.max(40,e?.height||0)};if(r==="center"){let p=Sx("center",t,o),h=Math.min(s.height,p),m=Jd((n-s.width)/2,8,Math.max(8,n-s.width-8)),y=Jd((o-h)/2,8,Math.max(8,o-h-8));return{left:m,top:y,side:"center",align:"center",maxHeight:p}}let i,a;if(r==="auto")i=F$(t,s,n,o),a="start";else{let p=r.split("-");i=p[0],a=p[1]||"start",i=N$(i,t,s,n,o)}let c=Sx(i,t,o),l=Math.min(s.height,c),f,u;i==="bottom"||i==="top"?(a==="start"?f=t.left:a==="end"?f=t.right-s.width:f=t.left+(t.width-s.width)/2,u=i==="bottom"?t.bottom+8:t.top-l-8):(a==="start"?u=t.top:a==="end"?u=t.bottom-l:u=t.top+(t.height-l)/2,f=i==="right"?t.right+8:t.left-s.width-8);let d=Math.max(8,n-s.width-8),g=Math.max(8,o-l-8);return f=Jd(f,8,d),u=Jd(u,8,g),{left:f,top:u,side:i,align:a,maxHeight:c}},ei=t=>{switch(t){case"bottom":return"translateY(-6px)";case"top":return"translateY(6px)";case"left":return"translateX(6px)";case"right":return"translateX(-6px)";case"center":return"translateY(0px)";default:return"translateY(-6px)"}};var mn={placement:"auto",trigger:"click",offset:8,minWidth:"180px",maxWidth:"90vw",maxHeight:null},j$=t=>{if(!t||typeof t.getBoundingClientRect!="function")return null;let e=t.getBoundingClientRect();return{left:e.left,top:e.top,right:e.right,bottom:e.bottom,width:e.width,height:e.height}},kx=t=>t?.getRoot?.()?.DropdownRoot||null,B$=0,V$=()=>`dropdown_${++B$}_${Date.now().toString(36)}`;function Qd(t={}){let e=kx(this);if(!e)return console.warn("[dropdown] openDropdown: DropdownRoot is not mounted on the app root. Add `DropdownRoot: {}` to your shell tree and import dropdown components into context."),null;let r=t.anchorEl?.node||t.anchorEl,n=t.anchorRect||j$(r);if(!n)return console.warn("[dropdown] openDropdown: no anchor element/rect provided \u2014 pass anchorEl or anchorRect."),null;let o=t.id||V$(),s=t.restoreEl?.node||t.restoreEl||r||(typeof document<"u"?document.activeElement:null),i={id:o,content:t.content||null,anchor:n,placement:t.placement||mn.placement,trigger:t.trigger||mn.trigger,offset:t.offset??mn.offset,minWidth:t.minWidth||mn.minWidth,maxWidth:t.maxWidth||mn.maxWidth,maxHeight:t.maxHeight||mn.maxHeight,theme:t.theme||null,shadow:t.shadow||null,background:t.background||null,round:t.round||null,role:t.role||null,ariaLabel:t.ariaLabel||null,ariaLabelledby:t.ariaLabelledby||null,focusIn:!!t.focusIn,onOpen:t.onOpen,onClose:t.onClose,restoreEl:s},a=e.state?.layer;if(a?.onClose)try{a.onClose(a)}catch(c){console.warn("[dropdown] prev onClose threw:",c)}if(e.state.update({layer:i}),typeof i.onOpen=="function")try{i.onOpen(i)}catch(c){console.warn("[dropdown] onOpen threw:",c)}return o}function tp(t){let e=kx(this);if(!e)return;let r=e.state?.layer;r&&e.state.update({layer:{...r,inert:!!t}})}function mo(t){let e=kx(this);if(!e)return;let r=e.state?.layer;if(!r)return;let n=typeof t=="string"?t:t?.id;if(n&&r.id&&n!==r.id)return;let o=r.onClose,s=r.restoreEl,i=typeof document<"u"?document:null,a=i?i.activeElement:null,c=e.node?.querySelector?.('[data-smbls-dropdown="panel"]'),l=!a||a===i?.body,f=!!(c&&a&&c.contains(a)),u=l||f;if(e.state.update({layer:null}),u&&s&&typeof s.focus=="function")try{s.focus()}catch(d){console.warn("[dropdown] focus restore threw:",d)}if(typeof o=="function")try{o(r)}catch(d){console.warn("[dropdown] onClose threw:",d)}}var vx=(t,e)=>{let r=`${e.maxHeight}px`;return t?.maxHeight?`min(${t.maxHeight}, ${r})`:r},FA=t=>{let e=t.getBoundingClientRect();return{width:e.width,height:Math.max(e.height,t.scrollHeight||0)}},U$=`
106
106
  @keyframes smbls-dropdown-fade-in {
107
107
  from { opacity: 0; transform: var(--smbls-dropdown-from, translateY(-6px)) scale(0.98); }
108
108
  to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
@@ -169,4 +169,4 @@ ${i}
169
169
  [data-smbls-dropdown="panel"]:not([data-smbls-shadowed]) {
170
170
  box-shadow: none !important;
171
171
  }
172
- `,T$=()=>{if(typeof document>"u"||document.getElementById("smbls-dropdown-css"))return;let t=document.createElement("style");t.id="smbls-dropdown-css",t.textContent=A$,document.head.appendChild(t)},TA=(t,e)=>{if(!t.node)return;let r=e?.background;if(!r)t.node.removeAttribute("data-smbls-surface");else{let n=/^[a-z][\w.+-]*$/i.test(r)?`var(--color-${r})`:r;t.node.style.setProperty("--smbls-dropdown-surface",n),t.node.setAttribute("data-smbls-surface","")}e?.theme?t.node.setAttribute("data-smbls-themed",""):t.node.removeAttribute("data-smbls-themed"),e?.shadow||t.scope?.bodyShadow?t.node.setAttribute("data-smbls-shadowed",""):t.node.removeAttribute("data-smbls-shadowed")},O$=t=>{if(!t)return null;let e=typeof t.shadow=="function"?t.shadow(t,t.state):t.shadow;return typeof e=="string"&&e?e:null},R$=t=>{t.node&&(t.node.removeAttribute("data-smbls-open"),t.node.offsetWidth,t.node.setAttribute("data-smbls-open","true"))},P$=[["role","role"],["aria-label","ariaLabel"],["aria-labelledby","ariaLabelledby"]],OA=(t,e)=>{if(!t.node)return;let r=new Set;for(let[n,o]of P$){let s=e?.[o];s&&(t.node.setAttribute(n,s),r.add(n))}if(t.__a11yAttrs)for(let n of t.__a11yAttrs)r.has(n)||t.node.removeAttribute(n);t.__a11yAttrs=r,t.__panelTabindex&&(t.node.removeAttribute("tabindex"),t.__panelTabindex=!1)},D$='a[href], button, input:not([type="hidden"]), select, textarea, summary, [tabindex], [contenteditable]:not([contenteditable="false"])',L$=t=>{let e=t.node;if(e){for(let r of e.querySelectorAll(D$)){if(r.matches(":disabled"))continue;let n=r.getAttribute("tabindex");if(!(n!==null&&parseInt(n,10)<0)&&(r.focus({preventScroll:!0}),e.ownerDocument.activeElement===r))return}e.setAttribute("tabindex","-1"),t.__panelTabindex=!0,e.focus({preventScroll:!0})}},Qd={tag:"div",attr:{"data-smbls-dropdown-root":"true"},position:"fixed",inset:"0",zIndex:"1500",pointerEvents:"none",state:{layer:null},onInit:t=>{if(T$(),typeof window>"u")return;let e=n=>{n.key!=="Escape"||n.defaultPrevented||t.state?.layer&&(n.preventDefault(),mo.call(t))};window.addEventListener("keydown",e),t.__dropdownEscHandler=e;let r=n=>{let o=t.state?.layer;if(!o)return;let s=t.node?.querySelector('[data-smbls-dropdown="panel"]');if(s&&s.contains(n.target))return;let i=o.anchor;if(i){let a=n.clientX,c=n.clientY;if(a>=i.left&&a<=i.right&&c>=i.top&&c<=i.bottom)return}mo.call(t)};document.addEventListener("mousedown",r,!0),t.__dropdownClickHandler=r},onRemove:t=>{typeof window>"u"||(t.__dropdownEscHandler&&window.removeEventListener("keydown",t.__dropdownEscHandler),t.__dropdownClickHandler&&document.removeEventListener("mousedown",t.__dropdownClickHandler,!0))},PanelHost:{tag:"div",position:"fixed",inset:"0",pointerEvents:"none",subscribeTo:["layer"],layer:(t,e)=>e?.layer||null,Panel:{tag:"div",attr:{"data-smbls-dropdown":"panel"},position:"fixed",subscribeTo:["layer"],left:t=>{let e=t.parent?.layer;if(!e?.anchor)return"-9999px";let r=t._lastSize||{width:280,height:200};return Dr(e.anchor,r,e.placement).left+"px"},top:t=>{let e=t.parent?.layer;if(!e?.anchor)return"-9999px";let r=t._lastSize||{width:280,height:200};return Dr(e.anchor,r,e.placement).top+"px"},style:t=>{let e=t.parent?.layer;if(!e?.anchor)return{};let r=t._lastSize||{width:280,height:200};return{"--smbls-dropdown-from":Qs(Dr(e.anchor,r,e.placement).side)}},minWidth:t=>t.parent?.layer?.minWidth||"180px",maxWidth:t=>t.parent?.layer?.maxWidth||"90vw",maxHeight:t=>{let e=t.parent?.layer;if(!e?.anchor)return"none";let r=t._lastSize||{width:280,height:200};return bw(e,Dr(e.anchor,r,e.placement))},overflow:"auto",overscrollBehavior:"contain",padding:"0",round:t=>t.parent?.layer?.round||"radiusCard",theme:t=>t.parent?.layer?.theme||null,border:"none",borderWidth:"0",shadow:t=>t.parent?.layer?.shadow||t.scope?.bodyShadow||null,scope:{bodyShadow:null},animationDuration:"B",animationTimingFunction:"defaultBezier",pointerEvents:t=>{let e=t.parent?.layer;return e?e.inert?"none":"auto":"none"},opacity:t=>t.parent?.layer?"1":"0",onClick:t=>t.stopPropagation(),onInit:t=>{let e=Y(()=>{let r=t.parent?.layer,n=r?.content||null,o=r?.id||null;if(!n){if(t.__lastLayerId!=null){try{t.removeContent?.()}catch{}t.__lastLayerId=null,OA(t,null),t.node?.removeAttribute("data-smbls-open"),t.scope&&(t.scope.bodyShadow=null)}return}if(t.__lastLayerId!==o){t.__lastLayerId=o;try{t.set(n)}catch(s){console.warn("[dropdown] content set failed:",s)}t.scope&&(t.scope.bodyShadow=O$(t.content)),TA(t,r),OA(t,r),R$(t),r.focusIn&&L$(t),!(typeof requestAnimationFrame>"u")&&requestAnimationFrame(()=>{if(!t.node)return;TA(t,r);let s=t.parent?.layer;if(!s?.anchor)return;let i=AA(t.node);t._lastSize=i;let a=Dr(s.anchor,i,s.placement);t.node.style.maxHeight=bw(s,a),t.node.style.left=a.left+"px",t.node.style.top=a.top+"px",t.node.style.setProperty("--smbls-dropdown-from",Qs(a.side))})}});t.__ref&&t.__ref.__effects?.push(e)},onRender:t=>{if(!t?.node)return;let e=t.parent?.layer;if(!e?.anchor)return;let r=AA(t.node),n=t._lastSize;(!n||Math.abs(n.width-r.width)>1||Math.abs(n.height-r.height)>1)&&(t._lastSize=r);let o=Dr(e.anchor,r,e.placement);t.node.style.maxHeight=bw(e,o),t.node.style.left=o.left+"px",t.node.style.top=o.top+"px",t.node.style.setProperty("--smbls-dropdown-from",Qs(o.side))}}}};var _w=t=>{let e=t?.getRoot?.()?.DropdownRoot?.state?.layer;if(e&&t.dropdownId&&e.id===t.dropdownId){t.call("closeDropdown");return}let r={anchorEl:t,trigger:t.dropdownTrigger||"click",placement:t.dropdownPlacement||"auto",content:t.dropdownContent||null,minWidth:t.dropdownMinWidth,maxWidth:t.dropdownMaxWidth,maxHeight:t.dropdownMaxHeight,theme:t.dropdownTheme,offset:t.dropdownOffset,id:t.dropdownId,onOpen:t.onDropdownOpen,onClose:t.onDropdownClose};for(let n in r)r[n]===void 0&&delete r[n];t.call("openDropdown",r)},tp={position:"relative",onClick:(t,e)=>{(e.dropdownTrigger||"click")==="click"&&(t.preventDefault(),t.stopPropagation(),_w(e))},onFocus:(t,e)=>{e.dropdownTrigger==="focus"&&_w(e)},onMouseenter:(t,e)=>{e.dropdownTrigger==="hover"&&(e._hoverTimer&&clearTimeout(e._hoverTimer),e._hoverTimer=setTimeout(()=>_w(e),120))},onMouseleave:(t,e)=>{e.dropdownTrigger==="hover"&&(e._hoverTimer&&(clearTimeout(e._hoverTimer),e._hoverTimer=null),e._closeTimer=setTimeout(()=>e.call("closeDropdown"),250))}};var ep={attr:{dropdown:!0},position:"absolute",top:"100%",left:"0",zIndex:1e3,theme:"quaternary",padding:"Y",round:"Z2",flow:"column",gap:"X",transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},rp={display:"flex",attr:{dropdown:!0},padding:"0 Y",maxHeight:"G",flow:"column",theme:"quaternary",overflow:"hidden auto",style:{listStyleType:"none"},transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",children:t=>t.options||[],childrenAs:"props",".hidden":{transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},childExtends:{extends:"Button",state:{},isActive:({key:t,state:e})=>e.active===t,position:"relative",round:"0",align:"center flex-end",flow:"row-reverse",padding:"Z2 C Z2 Y2",margin:"0",gap:"Y2",theme:"quaternary .child",":hover":{style:{svg:{opacity:"0.5"}}},Icon:{isActive:({key:t,state:e})=>e.active===t,name:"checkmark",opacity:"0.1",".active":{opacity:"1"}},":not(:first-child)":{"@dark":{border:"solid gray4.65"},"@light":{border:"solid gray11"},borderWidth:"1px 0 0"}}},np={position:"relative",zIndex:999,":hover":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}}},op={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}},Dropdown:{onClick:()=>{document.activeElement?.blur()}}},sp={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& ~ [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}}};var ww={DropdownRoot:Qd,DropdownTrigger:tp,Dropdown:ep,DropdownList:rp,DropdownParent:np,DropdownParentFocus:op,DropdownSiblingFocus:sp};var kw={};$(kw,{DROPDOWN_DEFAULTS:()=>bn,closeDropdown:()=>mo,computePosition:()=>Dr,dropdownFunctions:()=>Sw,fadeInTransform:()=>Qs,openDropdown:()=>Zd,setDropdownInert:()=>Jd});var Sw={openDropdown:Zd,closeDropdown:mo,setDropdownInert:Jd};var I$=(t,e,r)=>({bottom:r-t.bottom,top:t.top,right:e-t.right,left:t.left}),$$=(t,e,r,n,o)=>{let s=I$(e,n,o),i=t==="top"||t==="bottom"?r.height+6:r.width+6;if(s[t]>=i)return t;let a={top:"bottom",bottom:"top",left:"right",right:"left"}[t];return a&&s[a]>=i?a:t},RA=(t,e,r)=>Math.max(e,Math.min(r,t)),PA=(t,e,r="bottom")=>{if(!t)return{left:0,top:0,side:"bottom"};let n=typeof window<"u"?window.innerWidth:1024,o=typeof window<"u"?window.innerHeight:768,s=$$(r,t,e,n,o),i,a;return s==="bottom"||s==="top"?(i=t.left+(t.width-e.width)/2,a=s==="bottom"?t.bottom+6:t.top-e.height-6):(a=t.top+(t.height-e.height)/2,i=s==="right"?t.right+6:t.left-e.width-6),i=RA(i,6,n-e.width-6),a=RA(a,6,o-e.height-6),{left:i,top:a,side:s}},DA=t=>{switch(t){case"bottom":return"translate3d(0, -10%, 0)";case"top":return"translate3d(0, 10%, 0)";case"left":return"translate3d(10%, 0, 0)";case"right":return"translate3d(-10%, 0, 0)";default:return"translate3d(0, -10%, 0)"}};var ip={placement:"bottom",theme:"dialog",delay:250,hideDelay:100},M$=t=>{if(!t||typeof t.getBoundingClientRect!="function")return null;let e=t.getBoundingClientRect();return{left:e.left,top:e.top,right:e.right,bottom:e.bottom,width:e.width,height:e.height}},LA=t=>t?.getRoot?.()?.TooltipRoot||null,IA=t=>{let e=t?.state?.tip;return e?typeof e.$parse=="function"?e.$parse():{...e}:null},$A=(t,e,r=0)=>{let n=IA(t);if(!n||n.id!==e||n.open===!1)return;let o=t.Panel?.node;if(!o||typeof o.getBoundingClientRect!="function")return;if(o.textContent!==(n.text||"")){r<3&&setTimeout(()=>$A(t,e,r+1),0);return}let s=o.getBoundingClientRect();t.state.update({tip:{...n,size:{width:s.width,height:s.height}}})},F$=t=>{typeof queueMicrotask=="function"?queueMicrotask(t):Promise.resolve().then(t)},N$=0,j$=()=>`tooltip_${++N$}_${Date.now().toString(36)}`;function MA(t={}){let e=LA(this);if(!e)return console.warn("[tooltip] openTooltip: TooltipRoot is not mounted on the app root. Add `TooltipRoot: {}` to your shell tree and import tooltip components into context."),null;let r=t.anchorEl?.node||t.anchorEl,n=t.anchorRect||M$(r);if(!n)return console.warn("[tooltip] openTooltip: no anchor element/rect provided."),null;let o=t.id||j$(),s={id:o,text:t.text||"",anchor:n,placement:t.placement||ip.placement,theme:t.theme||ip.theme,open:!0,size:null};return e.state.update({tip:s}),F$(()=>$A(e,o)),o}function FA(t){let e=LA(this);if(!e)return;let r=IA(e);if(!r||r.open===!1)return;let n=typeof t=="string"?t:t?.id;n&&r.id&&n!==r.id||e.state.update({tip:{...r,open:!1}})}var vw=t=>{let e=t.tip;return e?.anchor?PA(e.anchor,e.size||{width:0,height:0},e.placement):null},ap=t=>{let e=t.tip;return!!(e&&e.open!==!1&&e.size)},NA={tag:"div",attr:{"data-smbls-tooltip-root":"true"},position:"fixed",inset:"0",zIndex:"2500",pointerEvents:"none",state:{tip:null},Panel:{tag:"div",attr:{"data-smbls-tooltip":"panel"},role:"tooltip",position:"fixed",tip:(t,e)=>e?.tip||null,left:t=>{let e=vw(t);return e?e.left+"px":"-9999px"},top:t=>{let e=vw(t);return e?e.top+"px":"-9999px"},text:t=>t.tip?.text||"",theme:t=>t.tip?.theme||ip.theme,width:"max-content",maxWidth:"280px",padding:"Y2 Z",round:"Z",fontSize:"Y2",lineHeight:"1.35",whiteSpace:"normal",pointerEvents:"none",opacity:t=>ap(t)?"1":"0",visibility:t=>ap(t)?"visible":"hidden",transform:t=>{if(ap(t))return"none";let e=vw(t);return DA(e?e.side:"bottom")},transition:t=>{let e=ap(t)?"A":"Z";return`${e} opacity defaultBezier, ${e} transform defaultBezier, ${e} visibility defaultBezier`}}};var Cw=t=>{if(!t.tooltipText)return;let e=t.node;e&&e.hasAttribute&&e.hasAttribute("title")&&e.removeAttribute("title")},B$=t=>{t.tooltipText&&(Cw(t),t.call("openTooltip",{anchorEl:t,text:t.tooltipText,placement:t.tooltipPlacement||"bottom",theme:t.tooltipTheme,id:t.tooltipId||t.key}))},jA=t=>{t._tooltipHideTimer&&(clearTimeout(t._tooltipHideTimer),t._tooltipHideTimer=null),!t._tooltipShowTimer&&(t._tooltipShowTimer=setTimeout(()=>{t._tooltipShowTimer=null,B$(t)},t.tooltipDelay??250))},BA=t=>{t._tooltipShowTimer&&(clearTimeout(t._tooltipShowTimer),t._tooltipShowTimer=null),!t._tooltipHideTimer&&(t._tooltipHideTimer=setTimeout(()=>{t._tooltipHideTimer=null,t.call("closeTooltip",t.tooltipId||t.key)},t.tooltipHideDelay??100))},VA={onMouseenter:(t,e)=>jA(e),onMouseleave:(t,e)=>BA(e),onFocus:(t,e)=>jA(e),onBlur:(t,e)=>BA(e),onMouseover:(t,e)=>Cw(e),onFocusin:(t,e)=>Cw(e)};var UA={display:"flex",theme:"dialog",flow:"column",shape:"tooltip",shapeDirection:"left",padding:"Z1 A",round:"Y2",width:"fit-content",minWidth:"D2",maxWidth:"F2",gap:"X",textAlign:"center",attr:{tooltip:!0},Title:{if:t=>t.call("isDefined",t.parent.title)||t.parent.title,width:"fit-content",fontWeight:500,color:"currentColor",text:t=>t.parent.title},P:{if:(t,e)=>t.call("isDefined",t.call("exec",t.parent.description,t))||t.text,width:"fit-content",fontSize:"Z2",margin:"0",color:"currentColor",fontWeight:"400",text:(t,e)=>t.call("exec",t.parent.description,t)}},zA={extends:"Tooltip",position:"absolute",pointerEvents:"none",opacity:"0",visibility:"hidden",transition:"C defaultBezier opacity, C defaultBezier visibility, B defaultBezier transform",onInit:t=>{let e=!t.shapeDirection||t.shapeDirection==="top"?{top:"112%",left:"50%",transform:"translate3d(-50%,10%,0)",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="right"?{transform:"translate3d(10%,-50%,0)",left:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="bottom"?{transform:"translate3d(-50%,-10%,0)",bottom:"112%",left:"50%",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="left"?{transform:"translate3d(10%,-50%,0)",right:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:{};Object.assign(t,e)},style:t=>{if(!t.scope||!t.scope.tooltipOpen)return{opacity:"",visibility:"",transform:""};let e=t.shapeDirection;return{opacity:"1",visibility:"visible",transform:e==="left"||e==="right"?"translate3d(0%,-50%,0)":"translate3d(-50%,0,0)"}},styleDeps:[t=>t.scope&&t.scope.tooltipOpen]},HA={position:"relative",zIndex:999,scope:{tooltipOpen:!1},onInit:t=>{let{Tooltip:e,TooltipHidden:r}=t,n=e||r;if(!n)return;let o=n&&n[".isActive"];Object.assign(t,{":hover, &:focus-visible":{zIndex:1e3,"& [tooltip]":o||{transform:"translate3d(-50%, 0, 0)",opacity:1,visibility:"visible"}}})},onPointerdown:(t,e)=>{t.pointerType!=="touch"||!e.scope||(e.scope.tooltipOpen=!e.scope.tooltipOpen)},onDocumentKeydown:(t,e)=>{t.key!=="Escape"||!e.scope||!e.scope.tooltipOpen||(e.scope.tooltipOpen=!1)},onDocumentPointerdown:(t,e)=>{!e.scope||!e.scope.tooltipOpen||e.node&&e.node.contains(t.target)||(e.scope.tooltipOpen=!1)}};var WA={TooltipRoot:NA,TooltipTrigger:VA,Tooltip:UA,TooltipHidden:zA,TooltipParent:HA};var qA={openTooltip:MA,closeTooltip:FA};var KA=t=>!!(t&&typeof t=="object"&&t.__isStub===!0),GA=t=>Qe(t)?t.library!==void 0?t.library:t.key??t.name:t,V$=(t,e)=>{let r=e?.sharedLibraries,n=Array.isArray(r)?r.map(i=>typeof i=="string"?i:i?.key||i?.name):r&&typeof r=="object"?Object.keys(r):null,o=0,s=i=>{let a=o++;if(typeof i.__libraryKey=="string"&&i.__libraryKey)return i.__libraryKey;if(n&&n[a])return n[a];if(typeof i.__stubId=="string"){let c=i.__stubId.match(/^@symbo[-.]ls\/([^/]+)/);if(c)return c[1]}return null};return t.map(i=>{let a=GA(i);if(!KA(a))return i;let c=s(a);return c?Qe(i)?{...i,library:c}:c:null}).filter(Boolean)},Aw=new WeakMap,U$={lazy:!0,window:globalThis},Ew=t=>{let e=Aw.get(t);e&&(Aw.delete(t),y1(e))},z$=async(t,e={})=>{let r=e.symbolsConfig,n=r?.owner&&r?.key?`${r.owner}--${r.key}`:r?.key,o=e.key=e.key||n||(k(t)?t:"smblsapp");if(e.define=e.define||Is,e.cssPropsRegistry=xt,e.window=u1(e),e.sharedLibraries&&e.sharedLibraries.length){if(e.sharedLibraries.some(p=>{let h=GA(p);return typeof h=="string"||KA(h)})){e.sharedLibraries=V$(e.sharedLibraries,e.symbolsConfig);let{resolveSharedLibraries:p}=await Promise.resolve().then(()=>(D(),Wo));e.sharedLibraries=await p(e.sharedLibraries,{apiBaseUrl:V_()})}s1(e.sharedLibraries),v1(e)}ol(e,e.designSystem);let[s,i]=x1(o,e);e.designSystem=s,e.registry=i,e.cases||(e.cases={}),e.shorthand&&jc.prepareContext(e);let a=S1(t,e);if(e.state=a,ra(a),e.pages=k1(t,e),e.components=d1(e),e.utils=p1(e),zr[e.packageManager]){let g=m1(e);g&&g.deferred?(g.blocking&&await Y_({...e,dependencies:g.blocking}),Aw.set(e,g.deferred)):e.dependencies=await Y_(e)}if(e.methods=h1(e),e.routerOptions=JC(t,e),e.defaultExtends=[Wu],e.snippets=e.snippets||{},e.functions=e.functions||{},e.plugins=e.plugins||[],e.plugins.some(g=>!g||typeof g!="object")){let g=e.plugins.filter(p=>!p||typeof p!="object");e.plugins=e.plugins.filter(p=>p&&typeof p=="object"),e.verbose!==!1&&console.warn(`[smbls] context.plugins carried ${g.length} non-plugin entr${g.length===1?"y":"ies"} (${g.map(p=>JSON.stringify(p)).join(", ")}) \u2014 dropped. A published project that imports a framework plugin it does not declare ships a stub phantom here; the runtime registers polyglot/helmet/fetch/... itself from the context config, so remove the import instead.`)}e.globalScope&&v(e.globalScope)&&(e.globalScope=Si(e.globalScope));let c=(g,p)=>{let h=p?g[p]:g;if(!v(h))return;let m=be(h,{},U$);try{Object.assign(h,m)}catch(_){if(p)g[p]=m;else throw _}};c(t),c(e,"components"),c(e,"pages"),c(e,"functions"),c(e,"methods"),c(e,"snippets"),c(e,"app");let l=g=>g&&typeof g.select=="function";e.fetch?.__resolved&&!l(e.fetch.__resolved)&&delete e.fetch.__resolved,e.db?.__resolved&&!l(e.db.__resolved)&&delete e.db.__resolved;let f=g=>e.plugins.some(p=>p&&p.name===g);if(e.polyglot&&!f("polyglot")){e.plugins.push(Ms);for(let g in Gc)typeof e.functions[g]!="function"&&(e.functions[g]=Gc[g])}if(f("helmet")||e.plugins.push(p_),e.fetch&&!f("fetch")&&e.plugins.push(xg),e.designSystem?.typography?.useCapsize!==!1&&!f("capsize")&&(e.plugins.push(sd),e.cssPropsRegistry.useCapsize=y_),e.shorthand&&!f("shorthand")&&e.plugins.push(jc),e.analyze&&!f("analyze")){let g=e.analyze===!0?{}:e.analyze;e.analyze=md(g),e.plugins.push(Ns)}e.sync!==!1&&!f("sync")&&e.plugins.push(wA),e.inspect&&!f("inspect")&&e.plugins.push(j_),(e.notifications===!0||e.editor&&e.editor.verbose===!0)&&e.notifications!==!1&&!f("notifications")&&e.plugins.push(xA);let d=(g,p,h)=>{if(e[g]!==!1){for(let m in p)v(e.components[m])||(e.components[m]=p[m]);for(let m in h)typeof e.functions[m]!="function"&&(e.functions[m]=h[m])}};return d("windows",hw,Pr),d("dropdown",ww,Sw),d("tooltip",WA,qA),e},Tw=async(t,e)=>{v(e)||(e={}),dr(t)?(t={},e.parent=t):k(t)?(t={},e.key=t):v(t)||(t={});let r=e.window||(typeof window<"u"?window:null),n=r?.__BRENDER__,o=null;if(n){let c=e.document||(typeof document<"u"?document:null);c&&(o=Array.from(c.head.querySelectorAll("style")))}if(await z$(t,e),e.useReset!==!1){let c=e.document||(typeof document<"u"?document:null);if(c){let l=c.head.querySelector("style[data-smbls]");l||(l=c.createElement("style"),l.setAttribute("data-smbls",""),c.head.appendChild(l));let f=l.sheet;if(f){try{f.insertRule("*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }",0)}catch{}try{f.insertRule("h1, h2, h3, h4, h5, h6 { font-size: inherit; font-weight: inherit; }",1)}catch{}}}}if(e.app&&v(e.app))for(let c in e.app)t[c]===void 0&&(t[c]=e.app[c]);t.extends=fE(t,e),e.router!==!1&&(t.routes=e.pages),t.state=e.state,t.context=e,t.data=t.data||{},e.skipDesignSystemInit||await b1({functions:e.functions,utils:e.utils,snippets:e.snippets,...e.files},e);for(let c of e.plugins)if(typeof c.beforeCreate=="function")try{c.beforeCreate(t,e)}catch(l){console.error(`[smbls] plugin "${c.name||"?"}" beforeCreate error:`,l)}let s=e.document;if(!s||!s.createElement)return Ew(e),t;let i=e.parent||s.body;if(n){let c=H$(ne,t,i,e,r,o);return Ew(e),c}let a=ne(t,i,e.key,{verbose:e.verbose,context:e,...e.domqlOptions});return Ew(e),typeof window<"u"&&!e.document&&(window.__smblsApp=a),a},H$=async(t,e,r,n,o,s)=>{let i=r.ownerDocument||document;s&&s.forEach(l=>{l.parentNode&&l.remove()});let a=[];for(let l of r.childNodes){if(l.nodeType===1){let f=l.tagName.toLowerCase();if(f==="script"||f==="link"||f==="style"||f==="svg"&&l.id)continue}a.push(l)}a.forEach(l=>l.remove()),i.querySelectorAll("[data-br]").forEach(l=>l.removeAttribute("data-br"));let c=t(e,r,n.key,{verbose:n.verbose,context:n,...n.domqlOptions});return W$(o),c},W$=t=>{t&&(delete t.__BRENDER__,delete t.__BR_REGISTRY__)};var Ow=(t,e)=>at(t,v(e)?e:{}),q$=t=>{if(typeof document>"u")return;let e=t.themeRoot||t.document&&t.document.documentElement||document.documentElement;if(!e||typeof e.setAttribute!="function")return;let r=t.globalTheme||"auto";try{if(typeof window<"u"&&window.location){let s=new URLSearchParams(window.location.search).get("globalTheme");s&&(r=s)}}catch{}let n=t.themeStorageKey;if(r==="auto"&&n&&typeof localStorage<"u")try{let s=localStorage.getItem(n);s&&(r=s)}catch{}let o=r==="auto"?(()=>{try{return typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}catch{return"light"}})():r;e.setAttribute("data-theme",o),t.globalTheme=r,t.themeRoot=e},K$=()=>{if(typeof document>"u")return null;try{let t=document.querySelector('meta[name="symbols-runtime"]'),e=t&&t.getAttribute("content");return typeof e=="string"&&e?e:null}catch{return null}},YA=t=>{let e=K$();e&&(t.editor||(t.editor={}),t.editor.runtime||(t.editor.runtime=e),e==="runner"&&typeof t.editor.livesync>"u"&&(t.editor.livesync=!0))},Rw=(t,e=fn,r)=>{let n={...fn,...Ow(e,r)};return YA(n),q$(n),Tw(t,n).then(s=>{if(f_(s,n),s.destroy=()=>Oc(s),s.navigate=(i,a={})=>{let c=s,l=s.context&&s.context.routerOptions;if(l&&l.customRouterElement){let f=Tc(s,l.customRouterElement);f&&(c=f)}return c.call("router",i,c,a.state||{},{pushState:!0,...a})},s.onCreate&&!s.__ref&&s.onCreate(s,s.state,s.context,n),s.context?.analyze?.activate)try{s.context.analyze.activate(s.context)}catch(i){console.error("[analyze] activate error:",i)}return s}).catch(s=>{throw console.error("[smbls] create error:",s),s})},G$=(t,e=fn,r)=>{let n=Rw(t,e,r),o={...fn,...Ow(e,r)},s=o.key;return rE(n,s,{utils:Ac,...o}),n},Y$=async(t,e=fn,r)=>{let n={...fn,...Ow(e,r)};YA(n);let o=e.key;await eE(o,n);let s=await Tw(t,n);return f_(s,n),s.destroy=()=>Oc(s),s.navigate=(i,a={})=>{let c=s,l=s.context&&s.context.routerOptions;if(l&&l.customRouterElement){let f=Tc(s,l.customRouterElement);f&&(c=f)}return c.call("router",i,c,a.state||{},{pushState:!0,...a})},n.onCreate&&await n.onCreate(s,s.state,s.context,n),s},X$=(t={},e=fn,r)=>Rw({deps:{isUndefined:Lt},...t},at({domqlOptions:{onlyResolveExtends:!0}},e),r);Zu(ic);e1(void 0,{smbls:Pw});r1(void 0,{"@symbo.ls/windows":()=>({...gw,...pw}),"@symbo.ls/dropdown":()=>({...xw,...kw})});
172
+ `,z$=()=>{if(typeof document>"u"||document.getElementById("smbls-dropdown-css"))return;let t=document.createElement("style");t.id="smbls-dropdown-css",t.textContent=U$,document.head.appendChild(t)},NA=(t,e)=>{if(!t.node)return;let r=e?.background;if(!r)t.node.removeAttribute("data-smbls-surface");else{let n=/^[a-z][\w.+-]*$/i.test(r)?`var(--color-${r})`:r;t.node.style.setProperty("--smbls-dropdown-surface",n),t.node.setAttribute("data-smbls-surface","")}e?.theme?t.node.setAttribute("data-smbls-themed",""):t.node.removeAttribute("data-smbls-themed"),e?.shadow||t.scope?.bodyShadow?t.node.setAttribute("data-smbls-shadowed",""):t.node.removeAttribute("data-smbls-shadowed")},H$=t=>{if(!t)return null;let e=typeof t.shadow=="function"?t.shadow(t,t.state):t.shadow;return typeof e=="string"&&e?e:null},W$=t=>{t.node&&(t.node.removeAttribute("data-smbls-open"),t.node.offsetWidth,t.node.setAttribute("data-smbls-open","true"))},q$=[["role","role"],["aria-label","ariaLabel"],["aria-labelledby","ariaLabelledby"]],jA=(t,e)=>{if(!t.node)return;let r=new Set;for(let[n,o]of q$){let s=e?.[o];s&&(t.node.setAttribute(n,s),r.add(n))}if(t.__a11yAttrs)for(let n of t.__a11yAttrs)r.has(n)||t.node.removeAttribute(n);t.__a11yAttrs=r,t.__panelTabindex&&(t.node.removeAttribute("tabindex"),t.__panelTabindex=!1)},K$='a[href], button, input:not([type="hidden"]), select, textarea, summary, [tabindex], [contenteditable]:not([contenteditable="false"])',G$=t=>{let e=t.node;if(e){for(let r of e.querySelectorAll(K$)){if(r.matches(":disabled"))continue;let n=r.getAttribute("tabindex");if(!(n!==null&&parseInt(n,10)<0)&&(r.focus({preventScroll:!0}),e.ownerDocument.activeElement===r))return}e.setAttribute("tabindex","-1"),t.__panelTabindex=!0,e.focus({preventScroll:!0})}},ep={tag:"div",attr:{"data-smbls-dropdown-root":"true"},position:"fixed",inset:"0",zIndex:"1500",pointerEvents:"none",state:{layer:null},onInit:t=>{if(z$(),typeof window>"u")return;let e=n=>{n.key!=="Escape"||n.defaultPrevented||t.state?.layer&&(n.preventDefault(),mo.call(t))};window.addEventListener("keydown",e),t.__dropdownEscHandler=e;let r=n=>{let o=t.state?.layer;if(!o)return;let s=t.node?.querySelector('[data-smbls-dropdown="panel"]');if(s&&s.contains(n.target))return;let i=o.anchor;if(i){let a=n.clientX,c=n.clientY;if(a>=i.left&&a<=i.right&&c>=i.top&&c<=i.bottom)return}mo.call(t)};document.addEventListener("mousedown",r,!0),t.__dropdownClickHandler=r},onRemove:t=>{typeof window>"u"||(t.__dropdownEscHandler&&window.removeEventListener("keydown",t.__dropdownEscHandler),t.__dropdownClickHandler&&document.removeEventListener("mousedown",t.__dropdownClickHandler,!0))},PanelHost:{tag:"div",position:"fixed",inset:"0",pointerEvents:"none",subscribeTo:["layer"],layer:(t,e)=>e?.layer||null,Panel:{tag:"div",attr:{"data-smbls-dropdown":"panel"},position:"fixed",subscribeTo:["layer"],left:t=>{let e=t.parent?.layer;if(!e?.anchor)return"-9999px";let r=t._lastSize||{width:280,height:200};return Lr(e.anchor,r,e.placement).left+"px"},top:t=>{let e=t.parent?.layer;if(!e?.anchor)return"-9999px";let r=t._lastSize||{width:280,height:200};return Lr(e.anchor,r,e.placement).top+"px"},style:t=>{let e=t.parent?.layer;if(!e?.anchor)return{};let r=t._lastSize||{width:280,height:200};return{"--smbls-dropdown-from":ei(Lr(e.anchor,r,e.placement).side)}},minWidth:t=>t.parent?.layer?.minWidth||"180px",maxWidth:t=>t.parent?.layer?.maxWidth||"90vw",maxHeight:t=>{let e=t.parent?.layer;if(!e?.anchor)return"none";let r=t._lastSize||{width:280,height:200};return vx(e,Lr(e.anchor,r,e.placement))},overflow:"auto",overscrollBehavior:"contain",padding:"0",round:t=>t.parent?.layer?.round||"radiusCard",theme:t=>t.parent?.layer?.theme||null,border:"none",borderWidth:"0",shadow:t=>t.parent?.layer?.shadow||t.scope?.bodyShadow||null,scope:{bodyShadow:null},animationDuration:"B",animationTimingFunction:"defaultBezier",pointerEvents:t=>{let e=t.parent?.layer;return e?e.inert?"none":"auto":"none"},opacity:t=>t.parent?.layer?"1":"0",onClick:t=>t.stopPropagation(),onInit:t=>{let e=Y(()=>{let r=t.parent?.layer,n=r?.content||null,o=r?.id||null;if(!n){if(t.__lastLayerId!=null){try{t.removeContent?.()}catch{}t.__lastLayerId=null,jA(t,null),t.node?.removeAttribute("data-smbls-open"),t.scope&&(t.scope.bodyShadow=null)}return}if(t.__lastLayerId!==o){t.__lastLayerId=o;try{t.set(n)}catch(s){console.warn("[dropdown] content set failed:",s)}t.scope&&(t.scope.bodyShadow=H$(t.content)),NA(t,r),jA(t,r),W$(t),r.focusIn&&G$(t),!(typeof requestAnimationFrame>"u")&&requestAnimationFrame(()=>{if(!t.node)return;NA(t,r);let s=t.parent?.layer;if(!s?.anchor)return;let i=FA(t.node);t._lastSize=i;let a=Lr(s.anchor,i,s.placement);t.node.style.maxHeight=vx(s,a),t.node.style.left=a.left+"px",t.node.style.top=a.top+"px",t.node.style.setProperty("--smbls-dropdown-from",ei(a.side))})}});t.__ref&&t.__ref.__effects?.push(e)},onRender:t=>{if(!t?.node)return;let e=t.parent?.layer;if(!e?.anchor)return;let r=FA(t.node),n=t._lastSize;(!n||Math.abs(n.width-r.width)>1||Math.abs(n.height-r.height)>1)&&(t._lastSize=r);let o=Lr(e.anchor,r,e.placement);t.node.style.maxHeight=vx(e,o),t.node.style.left=o.left+"px",t.node.style.top=o.top+"px",t.node.style.setProperty("--smbls-dropdown-from",ei(o.side))}}}};var Cx=t=>{let e=t?.getRoot?.()?.DropdownRoot?.state?.layer;if(e&&t.dropdownId&&e.id===t.dropdownId){t.call("closeDropdown");return}let r={anchorEl:t,trigger:t.dropdownTrigger||"click",placement:t.dropdownPlacement||"auto",content:t.dropdownContent||null,minWidth:t.dropdownMinWidth,maxWidth:t.dropdownMaxWidth,maxHeight:t.dropdownMaxHeight,theme:t.dropdownTheme,offset:t.dropdownOffset,id:t.dropdownId,onOpen:t.onDropdownOpen,onClose:t.onDropdownClose};for(let n in r)r[n]===void 0&&delete r[n];t.call("openDropdown",r)},rp={position:"relative",onClick:(t,e)=>{(e.dropdownTrigger||"click")==="click"&&(t.preventDefault(),t.stopPropagation(),Cx(e))},onFocus:(t,e)=>{e.dropdownTrigger==="focus"&&Cx(e)},onMouseenter:(t,e)=>{e.dropdownTrigger==="hover"&&(e._hoverTimer&&clearTimeout(e._hoverTimer),e._hoverTimer=setTimeout(()=>Cx(e),120))},onMouseleave:(t,e)=>{e.dropdownTrigger==="hover"&&(e._hoverTimer&&(clearTimeout(e._hoverTimer),e._hoverTimer=null),e._closeTimer=setTimeout(()=>e.call("closeDropdown"),250))}};var np={attr:{dropdown:!0},position:"absolute",top:"100%",left:"0",zIndex:1e3,theme:"quaternary",padding:"Y",round:"Z2",flow:"column",gap:"X",transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},op={display:"flex",attr:{dropdown:!0},padding:"0 Y",maxHeight:"G",flow:"column",theme:"quaternary",overflow:"hidden auto",style:{listStyleType:"none"},transition:"B defaultBezier",transitionProperty:"transform, opacity, visibility",children:t=>t.options||[],childrenAs:"props",".hidden":{transform:"translate3d(0,10%,0)",opacity:0,visibility:"hidden"},childExtends:{extends:"Button",state:{},isActive:({key:t,state:e})=>e.active===t,position:"relative",round:"0",align:"center flex-end",flow:"row-reverse",padding:"Z2 C Z2 Y2",margin:"0",gap:"Y2",theme:"quaternary .child",":hover":{style:{svg:{opacity:"0.5"}}},Icon:{isActive:({key:t,state:e})=>e.active===t,name:"checkmark",opacity:"0.1",".active":{opacity:"1"}},":not(:first-child)":{"@dark":{border:"solid gray4.65"},"@light":{border:"solid gray11"},borderWidth:"1px 0 0"}}},sp={position:"relative",zIndex:999,":hover":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}}},ip={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}},Dropdown:{onClick:()=>{document.activeElement?.blur()}}},ap={position:"relative",tabindex:"0",":focus-within":{zIndex:1e3,"& ~ [dropdown]":{transform:"translate3d(0,0,0)",opacity:1,visibility:"visible"}},Input_trigger:{type:"checkbox",opacity:"0",position:"absolute",inset:"0",width:"100%",height:"100%",cursor:"pointer",onClick:(t,e)=>{e.node===document.activeElement&&e.node.blur()}}};var Ex={DropdownRoot:ep,DropdownTrigger:rp,Dropdown:np,DropdownList:op,DropdownParent:sp,DropdownParentFocus:ip,DropdownSiblingFocus:ap};var Ox={};$(Ox,{DROPDOWN_DEFAULTS:()=>mn,closeDropdown:()=>mo,computePosition:()=>Lr,dropdownFunctions:()=>Tx,fadeInTransform:()=>ei,openDropdown:()=>Qd,setDropdownInert:()=>tp});var Tx={openDropdown:Qd,closeDropdown:mo,setDropdownInert:tp};var Y$=(t,e,r)=>({bottom:r-t.bottom,top:t.top,right:e-t.right,left:t.left}),X$=(t,e,r,n,o)=>{let s=Y$(e,n,o),i=t==="top"||t==="bottom"?r.height+6:r.width+6;if(s[t]>=i)return t;let a={top:"bottom",bottom:"top",left:"right",right:"left"}[t];return a&&s[a]>=i?a:t},BA=(t,e,r)=>Math.max(e,Math.min(r,t)),VA=(t,e,r="bottom")=>{if(!t)return{left:0,top:0,side:"bottom"};let n=typeof window<"u"?window.innerWidth:1024,o=typeof window<"u"?window.innerHeight:768,s=X$(r,t,e,n,o),i,a;return s==="bottom"||s==="top"?(i=t.left+(t.width-e.width)/2,a=s==="bottom"?t.bottom+6:t.top-e.height-6):(a=t.top+(t.height-e.height)/2,i=s==="right"?t.right+6:t.left-e.width-6),i=BA(i,6,n-e.width-6),a=BA(a,6,o-e.height-6),{left:i,top:a,side:s}},UA=t=>{switch(t){case"bottom":return"translate3d(0, -10%, 0)";case"top":return"translate3d(0, 10%, 0)";case"left":return"translate3d(10%, 0, 0)";case"right":return"translate3d(-10%, 0, 0)";default:return"translate3d(0, -10%, 0)"}};var cp={placement:"bottom",theme:"dialog",delay:250,hideDelay:100},Z$=t=>{if(!t||typeof t.getBoundingClientRect!="function")return null;let e=t.getBoundingClientRect();return{left:e.left,top:e.top,right:e.right,bottom:e.bottom,width:e.width,height:e.height}},zA=t=>t?.getRoot?.()?.TooltipRoot||null,HA=t=>{let e=t?.state?.tip;return e?typeof e.$parse=="function"?e.$parse():{...e}:null},WA=(t,e,r=0)=>{let n=HA(t);if(!n||n.id!==e||n.open===!1)return;let o=t.Panel?.node;if(!o||typeof o.getBoundingClientRect!="function")return;if(o.textContent!==(n.text||"")){r<3&&setTimeout(()=>WA(t,e,r+1),0);return}let s=o.getBoundingClientRect();t.state.update({tip:{...n,size:{width:s.width,height:s.height}}})},J$=t=>{typeof queueMicrotask=="function"?queueMicrotask(t):Promise.resolve().then(t)},Q$=0,tM=()=>`tooltip_${++Q$}_${Date.now().toString(36)}`;function qA(t={}){let e=zA(this);if(!e)return console.warn("[tooltip] openTooltip: TooltipRoot is not mounted on the app root. Add `TooltipRoot: {}` to your shell tree and import tooltip components into context."),null;let r=t.anchorEl?.node||t.anchorEl,n=t.anchorRect||Z$(r);if(!n)return console.warn("[tooltip] openTooltip: no anchor element/rect provided."),null;let o=t.id||tM(),s={id:o,text:t.text||"",anchor:n,placement:t.placement||cp.placement,theme:t.theme||cp.theme,open:!0,size:null};return e.state.update({tip:s}),J$(()=>WA(e,o)),o}function KA(t){let e=zA(this);if(!e)return;let r=HA(e);if(!r||r.open===!1)return;let n=typeof t=="string"?t:t?.id;n&&r.id&&n!==r.id||e.state.update({tip:{...r,open:!1}})}var Rx=t=>{let e=t.tip;return e?.anchor?VA(e.anchor,e.size||{width:0,height:0},e.placement):null},lp=t=>{let e=t.tip;return!!(e&&e.open!==!1&&e.size)},GA={tag:"div",attr:{"data-smbls-tooltip-root":"true"},position:"fixed",inset:"0",zIndex:"2500",pointerEvents:"none",state:{tip:null},Panel:{tag:"div",attr:{"data-smbls-tooltip":"panel"},role:"tooltip",position:"fixed",tip:(t,e)=>e?.tip||null,left:t=>{let e=Rx(t);return e?e.left+"px":"-9999px"},top:t=>{let e=Rx(t);return e?e.top+"px":"-9999px"},text:t=>t.tip?.text||"",theme:t=>t.tip?.theme||cp.theme,width:"max-content",maxWidth:"280px",padding:"Y2 Z",round:"Z",fontSize:"Y2",lineHeight:"1.35",whiteSpace:"normal",pointerEvents:"none",opacity:t=>lp(t)?"1":"0",visibility:t=>lp(t)?"visible":"hidden",transform:t=>{if(lp(t))return"none";let e=Rx(t);return UA(e?e.side:"bottom")},transition:t=>{let e=lp(t)?"A":"Z";return`${e} opacity defaultBezier, ${e} transform defaultBezier, ${e} visibility defaultBezier`}}};var Px=t=>{if(!t.tooltipText)return;let e=t.node;e&&e.hasAttribute&&e.hasAttribute("title")&&e.removeAttribute("title")},eM=t=>{t.tooltipText&&(Px(t),t.call("openTooltip",{anchorEl:t,text:t.tooltipText,placement:t.tooltipPlacement||"bottom",theme:t.tooltipTheme,id:t.tooltipId||t.key}))},YA=t=>{t._tooltipHideTimer&&(clearTimeout(t._tooltipHideTimer),t._tooltipHideTimer=null),!t._tooltipShowTimer&&(t._tooltipShowTimer=setTimeout(()=>{t._tooltipShowTimer=null,eM(t)},t.tooltipDelay??250))},XA=t=>{t._tooltipShowTimer&&(clearTimeout(t._tooltipShowTimer),t._tooltipShowTimer=null),!t._tooltipHideTimer&&(t._tooltipHideTimer=setTimeout(()=>{t._tooltipHideTimer=null,t.call("closeTooltip",t.tooltipId||t.key)},t.tooltipHideDelay??100))},ZA={onMouseenter:(t,e)=>YA(e),onMouseleave:(t,e)=>XA(e),onFocus:(t,e)=>YA(e),onBlur:(t,e)=>XA(e),onMouseover:(t,e)=>Px(e),onFocusin:(t,e)=>Px(e)};var JA={display:"flex",theme:"dialog",flow:"column",shape:"tooltip",shapeDirection:"left",padding:"Z1 A",round:"Y2",width:"fit-content",minWidth:"D2",maxWidth:"F2",gap:"X",textAlign:"center",attr:{tooltip:!0},Title:{if:t=>t.call("isDefined",t.parent.title)||t.parent.title,width:"fit-content",fontWeight:500,color:"currentColor",text:t=>t.parent.title},P:{if:(t,e)=>t.call("isDefined",t.call("exec",t.parent.description,t))||t.text,width:"fit-content",fontSize:"Z2",margin:"0",color:"currentColor",fontWeight:"400",text:(t,e)=>t.call("exec",t.parent.description,t)}},QA={extends:"Tooltip",position:"absolute",pointerEvents:"none",opacity:"0",visibility:"hidden",transition:"C defaultBezier opacity, C defaultBezier visibility, B defaultBezier transform",onInit:t=>{let e=!t.shapeDirection||t.shapeDirection==="top"?{top:"112%",left:"50%",transform:"translate3d(-50%,10%,0)",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="right"?{transform:"translate3d(10%,-50%,0)",left:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="bottom"?{transform:"translate3d(-50%,-10%,0)",bottom:"112%",left:"50%",".isActive":{transform:"translate3d(-50%,0,0)",opacity:1,visibility:"visible"}}:t.shapeDirection==="left"?{transform:"translate3d(10%,-50%,0)",right:"112%",top:"50%",".isActive":{transform:"translate3d(0%,-50%,0)",opacity:1,visibility:"visible"}}:{};Object.assign(t,e)},style:t=>{if(!t.scope||!t.scope.tooltipOpen)return{opacity:"",visibility:"",transform:""};let e=t.shapeDirection;return{opacity:"1",visibility:"visible",transform:e==="left"||e==="right"?"translate3d(0%,-50%,0)":"translate3d(-50%,0,0)"}},styleDeps:[t=>t.scope&&t.scope.tooltipOpen]},tT={position:"relative",zIndex:999,scope:{tooltipOpen:!1},onInit:t=>{let{Tooltip:e,TooltipHidden:r}=t,n=e||r;if(!n)return;let o=n&&n[".isActive"];Object.assign(t,{":hover, &:focus-visible":{zIndex:1e3,"& [tooltip]":o||{transform:"translate3d(-50%, 0, 0)",opacity:1,visibility:"visible"}}})},onPointerdown:(t,e)=>{t.pointerType!=="touch"||!e.scope||(e.scope.tooltipOpen=!e.scope.tooltipOpen)},onDocumentKeydown:(t,e)=>{t.key!=="Escape"||!e.scope||!e.scope.tooltipOpen||(e.scope.tooltipOpen=!1)},onDocumentPointerdown:(t,e)=>{!e.scope||!e.scope.tooltipOpen||e.node&&e.node.contains(t.target)||(e.scope.tooltipOpen=!1)}};var eT={TooltipRoot:GA,TooltipTrigger:ZA,Tooltip:JA,TooltipHidden:QA,TooltipParent:tT};var rT={openTooltip:qA,closeTooltip:KA};var nT=t=>!!(t&&typeof t=="object"&&t.__isStub===!0),oT=t=>Hr(t)?t.library!==void 0?t.library:t.key??t.name:t,rM=(t,e)=>{let r=e?.sharedLibraries,n=Array.isArray(r)?r.map(i=>typeof i=="string"?i:i?.key||i?.name):r&&typeof r=="object"?Object.keys(r):null,o=0,s=i=>{let a=o++;if(typeof i.__libraryKey=="string"&&i.__libraryKey)return i.__libraryKey;if(n&&n[a])return n[a];if(typeof i.__stubId=="string"){let c=i.__stubId.match(/^@symbo[-.]ls\/([^/]+)/);if(c)return c[1]}return null};return t.map(i=>{let a=oT(i);if(!nT(a))return i;let c=s(a);return c?Hr(i)?{...i,library:c}:c:null}).filter(Boolean)},Lx=new WeakMap,nM={lazy:!0,window:globalThis},Dx=t=>{let e=Lx.get(t);e&&(Lx.delete(t),A1(e))},oM=async(t,e={})=>{let r=e.symbolsConfig,n=r?.owner&&r?.key?`${r.owner}--${r.key}`:r?.key,o=e.key=e.key||n||(k(t)?t:"smblsapp");if(e.define=e.define||Ms,e.cssPropsRegistry=wt,e.window=w1(e),e.sharedLibraries&&e.sharedLibraries.length){if(e.sharedLibraries.some(p=>{let h=oT(p);return typeof h=="string"||nT(h)})){e.sharedLibraries=rM(e.sharedLibraries,e.symbolsConfig);let{resolveSharedLibraries:p}=await Promise.resolve().then(()=>(D(),qo));e.sharedLibraries=await p(e.sharedLibraries,{apiBaseUrl:K_()})}g1(e.sharedLibraries),I1(e)}il(e,e.designSystem);let[s,i]=P1(o,e);e.designSystem=s,e.registry=i,e.cases||(e.cases={}),e.shorthand&&Vc.prepareContext(e);let a=D1(t,e);if(e.state=a,na(a),e.pages=L1(t,e),e.components=S1(e),e.utils=k1(e),Ur[e.packageManager]){let g=E1(e);g&&g.deferred?(g.blocking&&await ex({...e,dependencies:g.blocking}),Lx.set(e,g.deferred)):e.dependencies=await ex(e)}if(e.methods=v1(e),e.routerOptions=cE(t,e),e.defaultExtends=[Ku],e.snippets=e.snippets||{},e.functions=e.functions||{},e.plugins=e.plugins||[],e.plugins.some(g=>!g||typeof g!="object")){let g=e.plugins.filter(p=>!p||typeof p!="object");e.plugins=e.plugins.filter(p=>p&&typeof p=="object"),e.verbose!==!1&&console.warn(`[smbls] context.plugins carried ${g.length} non-plugin entr${g.length===1?"y":"ies"} (${g.map(p=>JSON.stringify(p)).join(", ")}) \u2014 dropped. A published project that imports a framework plugin it does not declare ships a stub phantom here; the runtime registers polyglot/helmet/fetch/... itself from the context config, so remove the import instead.`)}e.globalScope&&v(e.globalScope)&&(e.globalScope=vi(e.globalScope));let c=(g,p)=>{let h=p?g[p]:g;if(!v(h))return;let m=be(h,{},nM);try{Object.assign(h,m)}catch(y){if(p)g[p]=m;else throw y}};c(t),c(e,"components"),c(e,"pages"),c(e,"functions"),c(e,"methods"),c(e,"snippets"),c(e,"app");let l=g=>g&&typeof g.select=="function";e.fetch?.__resolved&&!l(e.fetch.__resolved)&&delete e.fetch.__resolved,e.db?.__resolved&&!l(e.db.__resolved)&&delete e.db.__resolved;let f=g=>e.plugins.some(p=>p&&p.name===g);if(e.polyglot&&!f("polyglot")){e.plugins.push(Ns);for(let g in Xc)typeof e.functions[g]!="function"&&(e.functions[g]=Xc[g])}if(f("helmet")||e.plugins.push(__),e.fetch&&!f("fetch")&&e.plugins.push(kg),e.designSystem?.typography?.useCapsize!==!1&&!f("capsize")&&(e.plugins.push(ad),e.cssPropsRegistry.useCapsize=k_),e.shorthand&&!f("shorthand")&&e.plugins.push(Vc),e.analyze&&!f("analyze")){let g=e.analyze===!0?{}:e.analyze;e.analyze=bd(g),e.plugins.push(Bs)}e.sync!==!1&&!f("sync")&&e.plugins.push(RA),e.inspect&&!f("inspect")&&e.plugins.push(W_),(e.notifications===!0||e.editor&&e.editor.verbose===!0)&&e.notifications!==!1&&!f("notifications")&&e.plugins.push(PA);let d=(g,p,h)=>{if(e[g]!==!1){for(let m in p)v(e.components[m])||(e.components[m]=p[m]);for(let m in h)typeof e.functions[m]!="function"&&(e.functions[m]=h[m])}};return d("windows",xx,Dr),d("dropdown",Ex,Tx),d("tooltip",eT,rT),e},Ix=async(t,e)=>{v(e)||(e={}),pr(t)?(t={},e.parent=t):k(t)?(t={},e.key=t):v(t)||(t={});let r=e.window||(typeof window<"u"?window:null),n=r?.__BRENDER__,o=null;if(n){let c=e.document||(typeof document<"u"?document:null);c&&(o=Array.from(c.head.querySelectorAll("style")))}if(await oM(t,e),e.useReset!==!1){let c=e.document||(typeof document<"u"?document:null);if(c){let l=c.head.querySelector("style[data-smbls]");l||(l=c.createElement("style"),l.setAttribute("data-smbls",""),c.head.appendChild(l));let f=l.sheet;if(f){try{f.insertRule("*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }",0)}catch{}try{f.insertRule("h1, h2, h3, h4, h5, h6 { font-size: inherit; font-weight: inherit; }",1)}catch{}}}}if(e.app&&v(e.app))for(let c in e.app)t[c]===void 0&&(t[c]=e.app[c]);t.extends=xE(t,e),e.router!==!1&&(t.routes=e.pages),t.state=e.state,t.context=e,t.data=t.data||{},e.skipDesignSystemInit||await T1({functions:e.functions,utils:e.utils,snippets:e.snippets,...e.files},e);for(let c of e.plugins)if(typeof c.beforeCreate=="function")try{c.beforeCreate(t,e)}catch(l){console.error(`[smbls] plugin "${c.name||"?"}" beforeCreate error:`,l)}let s=e.document;if(!s||!s.createElement)return Dx(e),t;let i=e.parent||s.body;if(n){let c=sM(ne,t,i,e,r,o);return Dx(e),c}let a=ne(t,i,e.key,{verbose:e.verbose,context:e,...e.domqlOptions});return Dx(e),typeof window<"u"&&!e.document&&(window.__smblsApp=a),a},sM=async(t,e,r,n,o,s)=>{let i=r.ownerDocument||document;s&&s.forEach(l=>{l.parentNode&&l.remove()});let a=[];for(let l of r.childNodes){if(l.nodeType===1){let f=l.tagName.toLowerCase();if(f==="script"||f==="link"||f==="style"||f==="svg"&&l.id)continue}a.push(l)}a.forEach(l=>l.remove()),i.querySelectorAll("[data-br]").forEach(l=>l.removeAttribute("data-br"));let c=t(e,r,n.key,{verbose:n.verbose,context:n,...n.domqlOptions});return iM(o),c},iM=t=>{t&&(delete t.__BRENDER__,delete t.__BR_REGISTRY__)};var $x=(t,e)=>at(t,v(e)?e:{}),aM=t=>{if(typeof document>"u")return;let e=t.themeRoot||t.document&&t.document.documentElement||document.documentElement;if(!e||typeof e.setAttribute!="function")return;let r=t.globalTheme||"auto";try{if(typeof window<"u"&&window.location){let s=new URLSearchParams(window.location.search).get("globalTheme");s&&(r=s)}}catch{}let n=t.themeStorageKey;if(r==="auto"&&n&&typeof localStorage<"u")try{let s=localStorage.getItem(n);s&&(r=s)}catch{}let o=r==="auto"?(()=>{try{return typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}catch{return"light"}})():r;e.setAttribute("data-theme",o),t.globalTheme=r,t.themeRoot=e},cM=()=>{if(typeof document>"u")return null;try{let t=document.querySelector('meta[name="symbols-runtime"]'),e=t&&t.getAttribute("content");return typeof e=="string"&&e?e:null}catch{return null}},sT=t=>{let e=cM();e&&(t.editor||(t.editor={}),t.editor.runtime||(t.editor.runtime=e),e==="runner"&&typeof t.editor.livesync>"u"&&(t.editor.livesync=!0))},Mx=(t,e=cn,r)=>{let n={...cn,...$x(e,r)};return sT(n),aM(n),Ix(t,n).then(s=>{if(g_(s,n),s.destroy=()=>Pc(s),s.navigate=(i,a={})=>{let c=s,l=s.context&&s.context.routerOptions;if(l&&l.customRouterElement){let f=Rc(s,l.customRouterElement);f&&(c=f)}return c.call("router",i,c,a.state||{},{pushState:!0,...a})},s.onCreate&&!s.__ref&&s.onCreate(s,s.state,s.context,n),s.context?.analyze?.activate)try{s.context.analyze.activate(s.context)}catch(i){console.error("[analyze] activate error:",i)}return s}).catch(s=>{throw console.error("[smbls] create error:",s),s})},lM=(t,e=cn,r)=>{let n=Mx(t,e,r),o={...cn,...$x(e,r)},s=o.key;return dE(n,s,{utils:Oc,...o}),n},fM=async(t,e=cn,r)=>{let n={...cn,...$x(e,r)};sT(n);let o=e.key;await uE(o,n);let s=await Ix(t,n);return g_(s,n),s.destroy=()=>Pc(s),s.navigate=(i,a={})=>{let c=s,l=s.context&&s.context.routerOptions;if(l&&l.customRouterElement){let f=Rc(s,l.customRouterElement);f&&(c=f)}return c.call("router",i,c,a.state||{},{pushState:!0,...a})},n.onCreate&&await n.onCreate(s,s.state,s.context,n),s},uM=(t={},e=cn,r)=>Mx({deps:{isUndefined:Lt},...t},at({domqlOptions:{onlyResolveExtends:!0}},e),r);Qu(cc);u1(void 0,{smbls:Fx});d1(void 0,{"@symbo.ls/windows":()=>({...wx,..._x}),"@symbo.ls/dropdown":()=>({...Ax,...Ox})});