webim-adapter 2.9.4 → 2.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4818,47 +4818,51 @@ function Ui({ tabs: e = [], linked: t, style: n, nodeRef: r }) {
4818
4818
  }, e.key))]
4819
4819
  });
4820
4820
  }
4821
- function Wi({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i, padY: a, headerBg: s, headerColor: l, openBg: u, openColor: f, borderColor: p, style: m, nodeRef: _ }) {
4822
- let [v, y] = d(() => new Set(e.length ? [e[0].key] : [])), { locale: b } = o(X), x = c();
4821
+ function Wi({ items: e = [], linked: t, multiple: n = !1, startOpen: r = "first", icon: i = "", padX: a, padY: l, headerBg: u, headerColor: f, openBg: p, openColor: m, borderColor: _, style: v, nodeRef: y }) {
4822
+ let b = () => !e.length || r === "none" ? /* @__PURE__ */ new Set() : r === "all" && n ? new Set(e.map((e) => e.key)) : /* @__PURE__ */ new Set([e[0].key]), [x, S] = d(b), { locale: C } = o(X);
4823
+ s(() => {
4824
+ S(b());
4825
+ }, [r, n]);
4826
+ let w = c();
4823
4827
  if (!e.length) return null;
4824
- let S = ot(b), C = (e, t) => typeof e == "string" && e ? e : t, w = (e, t) => {
4828
+ let T = ot(C), E = (e, t) => typeof e == "string" && e ? e : t, D = (e, t) => {
4825
4829
  let n = Number(e);
4826
4830
  return e === "" || e == null || !Number.isFinite(n) ? t : n;
4827
- }, T = ki[r], E = (e) => y((t) => {
4831
+ }, O = ki[i], k = (e) => S((t) => {
4828
4832
  let r = new Set(n ? t : []);
4829
4833
  return t.has(e) ? r.delete(e) : r.add(e), r;
4830
4834
  });
4831
4835
  return /* @__PURE__ */ h("div", {
4832
- ref: _,
4836
+ ref: y,
4833
4837
  style: {
4834
4838
  width: "100%",
4835
- ...G(m)
4839
+ ...G(v)
4836
4840
  },
4837
4841
  children: e.map((n, r) => {
4838
- let o = v.has(n.key);
4842
+ let i = x.has(n.key);
4839
4843
  return /* @__PURE__ */ g("div", {
4840
- ...Z("item", o && "item-open"),
4841
- style: { borderBottom: r < e.length - 1 ? `1px solid ${C(p, "rgba(148, 163, 184, 0.35)")}` : "none" },
4844
+ ...Z("item", i && "item-open"),
4845
+ style: { borderBottom: r < e.length - 1 ? `1px solid ${E(_, "rgba(148, 163, 184, 0.35)")}` : "none" },
4842
4846
  children: [/* @__PURE__ */ g("button", {
4843
4847
  type: "button",
4844
- ...Z("header", o && "header-open"),
4845
- id: `${x}-h-${n.key}`,
4846
- "aria-expanded": o,
4847
- "aria-controls": `${x}-b-${n.key}`,
4848
- onClick: () => E(n.key),
4848
+ ...Z("header", i && "header-open"),
4849
+ id: `${w}-h-${n.key}`,
4850
+ "aria-expanded": i,
4851
+ "aria-controls": `${w}-b-${n.key}`,
4852
+ onClick: () => k(n.key),
4849
4853
  style: {
4850
4854
  width: "100%",
4851
4855
  display: "flex",
4852
4856
  alignItems: "center",
4853
4857
  justifyContent: "space-between",
4854
4858
  gap: 12,
4855
- background: o ? C(u, C(s, "transparent")) : C(s, "transparent"),
4859
+ background: i ? E(p, E(u, "transparent")) : E(u, "transparent"),
4856
4860
  border: 0,
4857
- padding: `${w(a, 14)}px ${w(i, 4)}px`,
4861
+ padding: `${D(l, 14)}px ${D(a, 4)}px`,
4858
4862
  fontSize: 15,
4859
4863
  fontWeight: 600,
4860
4864
  fontFamily: "inherit",
4861
- color: o ? C(f, C(l, "inherit")) : C(l, "inherit"),
4865
+ color: i ? E(m, E(f, "inherit")) : E(f, "inherit"),
4862
4866
  textAlign: "left",
4863
4867
  cursor: "pointer",
4864
4868
  transition: "background 180ms, color 180ms"
@@ -4871,7 +4875,7 @@ function Wi({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i,
4871
4875
  gap: 10,
4872
4876
  minWidth: 0
4873
4877
  },
4874
- children: [T ? /* @__PURE__ */ h("svg", {
4878
+ children: [O ? /* @__PURE__ */ h("svg", {
4875
4879
  ...Z("icon"),
4876
4880
  viewBox: "0 0 24 24",
4877
4881
  width: 16,
@@ -4883,27 +4887,27 @@ function Wi({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i,
4883
4887
  strokeLinejoin: "round",
4884
4888
  "aria-hidden": "true",
4885
4889
  style: { flexShrink: 0 },
4886
- children: /* @__PURE__ */ h("path", { d: T })
4887
- }) : null, n.title || S("item", { n: r + 1 })]
4890
+ children: /* @__PURE__ */ h("path", { d: O })
4891
+ }) : null, n.title || T("item", { n: r + 1 })]
4888
4892
  }), /* @__PURE__ */ h("span", {
4889
4893
  "aria-hidden": "true",
4890
4894
  ...Z("chevron"),
4891
4895
  style: {
4892
4896
  fontSize: 12,
4893
4897
  opacity: .6,
4894
- transform: o ? "rotate(180deg)" : "none",
4898
+ transform: i ? "rotate(180deg)" : "none",
4895
4899
  transition: "transform 180ms"
4896
4900
  },
4897
4901
  children: "▼"
4898
4902
  })]
4899
4903
  }), /* @__PURE__ */ h("div", {
4900
4904
  ...Z("body"),
4901
- id: `${x}-b-${n.key}`,
4905
+ id: `${w}-b-${n.key}`,
4902
4906
  role: "region",
4903
- "aria-labelledby": `${x}-h-${n.key}`,
4904
- hidden: !o,
4907
+ "aria-labelledby": `${w}-h-${n.key}`,
4908
+ hidden: !i,
4905
4909
  style: {
4906
- display: o ? "flex" : "none",
4910
+ display: i ? "flex" : "none",
4907
4911
  flexDirection: "column"
4908
4912
  },
4909
4913
  children: t?.[n.key] ?? null
@@ -21,7 +21,7 @@ Error generating stack: `+e.message+`
21
21
  `),n=null;return t.map(e=>{let t=Bt.exec(e);return n?(t&&t[1].startsWith(n[0])&&t[1].length>=n.length&&(n=null),e):t?(n=t[1],e):e.replace(/^[ \t]+/,e=>e.replace(/\t/g,` `))})}function tn(e,t){let n=[],r=0;for(;r<e.length;){let i=e[r];if(zt.test(i)){r+=1;continue}let a=Bt.exec(i);if(a){let t=[],i=r+1;for(;i<e.length;){let n=Bt.exec(e[i]);if(n&&n[1][0]===a[1][0]&&n[1].length>=a[1].length&&!n[2])break;t.push(e[i]),i+=1}n.push({type:`code`,lang:a[2]||``,text:t.join(`
22
22
  `)}),r=i+1;continue}let o=Vt.exec(i);if(o){let e=(o[2]??``).replace(/[ \t]+#+[ \t]*$/,``);n.push({type:`h${o[1].length}`,parts:Rt(e,t)}),r+=1;continue}if(Ht.test(i)){n.push({type:`divider`}),r+=1;continue}if(Ut.test(i)){let i=[];for(;r<e.length;){let t=Ut.exec(e[r]);if(t)i.push(t[1]);else if(!zt.test(e[r])&&i.length&&!zt.test(i[i.length-1]))i.push(e[r]);else break;r+=1}let a=tn(i,t);n.push(a.length===1&&a[0].type===`p`?{type:`quote`,parts:a[0].parts}:{type:`quote`,blocks:a});continue}if(Xt(i)){r=nn(e,r,n,t);continue}if(i.includes(`|`)&&r+1<e.length&&Jt.test(e[r+1])){let a=Zt(i),o=Zt(e[r+1]).map(Qt),s=[a.map(e=>Rt(e,t))],c=r+2;for(;c<e.length&&!zt.test(e[c])&&e[c].includes(`|`);){let n=Zt(e[c]);s.push(a.map((e,r)=>Rt(n[r]??``,t))),c+=1}let l={};o.forEach((e,t)=>{e&&s.forEach((n,r)=>l[`${r}:${t}`]={align:e})}),n.push({type:`table`,header:!0,rows:s,cellStyles:l}),r=c;continue}let s=[i];for(r+=1;r<e.length&&!zt.test(e[r]);){let i=e[r],a=Kt.exec(i);if(a){n.push({type:a[1][0]===`=`?`h1`:`h2`,parts:Rt(s.join(`
23
23
  `),t)}),r+=1,s.length=0;break}if(Bt.test(i)||Vt.test(i)||Ht.test(i)||Ut.test(i)||Xt(i))break;s.push(i),r+=1}s.length&&n.push(...$t(Rt(s.join(`
24
- `),t)))}return n}function nn(e,t,n,r){let i=Xt(e[t]),a=i.indent,o=[],s=null,c=t;for(;c<e.length;){let t=e[c],n=Xt(t);if(n&&n.indent<=a+1){if(n.ordered!==i.ordered)break;s={lines:[n.text]},o.push(s),c+=1;continue}if(zt.test(t)){let t=c;for(;t<e.length&&zt.test(e[t]);)t+=1;if(!(t<e.length&&(Yt(e[t])>=a+2||Xt(e[t])&&Xt(e[t]).ordered===i.ordered)))break;s?.lines.push(``),c=t;continue}if(!s)break;if(Yt(t)>=a+2)s.lines.push(t.slice(Math.min(t.length-t.trimStart().length,a+2)));else if(!n)s.lines.push(t.trim());else break;c+=1}return n.push({type:i.ordered?`ol`:`ul`,...i.ordered&&i.start!==1?{start:i.start}:null,items:o.map(e=>{let t=qt.exec(e.lines[0]??``);t&&(e.lines[0]=t[2]);let n=tn(e.lines,r),i=n[0]?.type===`p`?n.shift():null;return{parts:i?i.parts:[],...n.length?{blocks:n}:null,...t?{task:t[1].toLowerCase()===`x`}:null}})}),c}function rn(e,t={}){return String(e??``).trim()?tn(en(e),t):[]}function an(e,t){let n={data:e,depth:0,parent:null,children:null},r=[n];for(;r.length;){let e=r.pop(),n=t(e.data);if(n?.length){e.children=n.map(t=>({data:t,depth:e.depth+1,parent:e,children:null}));for(let t=e.children.length-1;t>=0;--t)r.push(e.children[t])}}return n}function on(e,t){let n=[e];for(;n.length;){let e=n.pop();if(t(e),e.children)for(let t=e.children.length-1;t>=0;--t)n.push(e.children[t])}}function sn(e,t){let n=[e],r=[];for(;n.length;){let e=n.pop();if(r.push(e),e.children)for(let t of e.children)n.push(t)}for(;r.length;)t(r.pop())}function cn(e,[t,n],r){let i=(e,t)=>({_:e,parent:null,children:null,A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:t}),a=i(e,0);a.a=a,on(a,e=>{e._.children&&(e.children=e._.children.map((t,n)=>{let r=i(t,n);return r.a=r,r.parent=e,r}))}),a.parent=i(null,0),a.parent.a=a.parent,a.parent.children=[a];let o=e=>e.children?e.children[0]:e.t,s=e=>e.children?e.children[e.children.length-1]:e.t,c=(e,t,n)=>{let r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n},l=e=>{let t=0,n=0;for(let r=e.children.length-1;r>=0;--r){let i=e.children[r];i.z+=t,i.m+=t,t+=i.s+(n+=i.c)}},u=(e,t,n)=>e.a.parent===t.parent?e.a:n,d=(e,t,n)=>{if(!t)return n;let i=e,a=e,l=t,d=i.parent.children[0],f=i.m,p=a.m,m=l.m,h=d.m;for(;l=s(l),i=o(i),l&&i;){d=o(d),a=s(a),a.a=e;let t=l.z+m-i.z-f+r(l._,i._);t>0&&(c(u(l,e,n),e,t),f+=t,p+=t),m+=l.m,f+=i.m,h+=d.m,p+=a.m}return l&&!s(a)&&(a.t=l,a.m+=m-p),i&&!o(d)&&(d.t=i,d.m+=f-h,n=e),n};return sn(a,e=>{let t=e.parent.children,n=e.i?t[e.i-1]:null;if(e.children){l(e);let t=(e.children[0].z+e.children[e.children.length-1].z)/2;n?(e.z=n.z+r(e._,n._),e.m=e.z-t):e.z=t}else n&&(e.z=n.z+r(e._,n._));e.parent.A=d(e,n,e.parent.A||t[0])}),a.parent.m=-a.z,on(a,e=>{e._.x=e.z+e.parent.m,e.m+=e.parent.m}),on(e,e=>{e.x*=t,e.y=e.depth*n}),e}var ln=20,un={S:{width:200,height:80},M:{width:240,height:80},L:{width:280,height:100},XL:{width:320,height:120}},dn={across:20,down:80,stack:20},fn=dn.across/2,pn={pad:20,header:40},mn=2*dn.stack,hn=`__root__`,gn=20,_n=e=>Math.round(e/ln)*ln;function vn(e){let{people:t,direction:n}=e,r=un[e.cardSize]??un.M,i=n===`right`,a=new Map;for(let e of t){let t=e.parent??hn;a.has(t)||a.set(t,[]),a.get(t).push(e)}let o=i?r.height+dn.across:r.width+dn.across,s=i?r.width+dn.down:r.height+dn.down,c=e=>e.id===hn||!e.collapsed?a.get(e.id)??[]:[],l=e=>e.kind===`group`,u=e=>c(e).filter(e=>e.placement!==`below`),d=e=>c(e).filter(e=>e.placement===`below`),f=(e,t)=>e.memberTeams===`inside`?c(t):[],p=e=>u(e).flatMap(t=>e.memberTeams===`inside`?f(e,t):[t]),m=e=>{let t=u(e).length,n=i||e.memberTeams===`inside`,r=Math.max(1,Math.min(t,e.memberColumns||(n?t:1)));return{cols:r,rows:Math.ceil(t/r)}},h=(e,t)=>{let n=f(e,t).length;return r.height+(n?mn+n*(r.height+dn.stack)-dn.stack:0)},g=e=>{let t=u(e),{cols:n,rows:i}=m(e),a=[],o=pn.header;for(let r=0;r<i;r+=1)a.push(o),o+=Math.max(...t.slice(r*n,(r+1)*n).map(t=>h(e,t)))+dn.stack;return{width:(t.length?n*(r.width+dn.across)-dn.across:r.width)+2*pn.pad,height:(t.length?o-dn.stack:pn.header)+pn.pad,tops:a}},_=(e,t=c(e))=>{if(i||e.id===hn)return t;let n=[],r=[],a=()=>{r.length>1?n.push({id:`${r[0].id}:stack`,people:r,line:e.columns}):n.push(...r),r=[]};for(let e of t)c(e).length||l(e)?(a(),n.push(e)):r.push(e);return a(),n},v=(e,t,n)=>{let r=n;for(let n=Math.ceil(t/s);n>0;--n)r=[{id:`${e}:${n}`,spacer:!0,below:r}];return r},y=i?r.width:r.height,b=an({id:hn},e=>{if(e.people)return v(e.id,(e.people.length-1)*(r.height+dn.stack),[]);if(e.spacer)return e.below;if(l(e)){let t=p(e).flatMap(e=>_(e)),n=_(e,d(e)),r=i?[...n,...t]:[...t,...n],a=i?g(e).width:g(e).height;return v(`${e.id}:frame`,a-y,r)}return _(e)}),x=e=>{if(!l(e.data))return 0;let t=g(e.data);return(i?t.height-r.height:t.width-r.width)/o};cn(b,[o,s],(e,t)=>(e.parent===t.parent?1:1+2*ln/o)+(x(e)+x(t))/2);let S=new Map,C=[],w=[],T=[],E=new Map([[hn,{x:0,y:0}]]),D=new Map,O=(e,t,a,o,s=null)=>{let c=E.get(t??hn),u={x:c.x+(e.dx||0),y:c.y+(e.dy||0)},d=l(e)?g(e):null,f={person:e,x:_n(a.x)+u.x,y:_n(a.y)+u.y,width:d?d.width:r.width,height:d?d.height:r.height};if(E.set(e.id,u),S.set(e.id,f),(d?w:C).push(f),o?.inner)T.push(o.line===`center`?{kind:`straight`,source:o.above?.id??e.parent,target:e.id,from:`bottom`,to:`top`}:{kind:`rail`,source:e.parent,target:e.id,from:`bottom`,to:o.line===`right`?`right`:`left`,side:o.line===`right`?`right`:`left`,drop:mn/2});else if(e.parent&&!s){let t=D.get(e.parent);t!==void 0&&!e.lineFrom&&!e.lineTo&&!(o?.line===`center`&&o.above)?T.push({kind:`exit`,source:e.parent,target:e.id,from:i?`right`:`bottom`,to:o?.line===`left`||i?`left`:`top`,exit:t,into:o?.line===`left`?`side`:`top`,level:o?.line===`left`?_n(o.top)+c.y-dn.down/2:null}):T.push(yn(e,o,n))}};on(b,e=>{let t=e.data;if(t.id===hn||t.spacer)return;let n=e.y-s;if(t.people){t.people.forEach((i,a)=>O(i,i.parent,{x:e.x-r.width/2,y:n+a*(r.height+dn.stack)},{line:t.line,above:t.people[a-1],top:n}));return}if(l(t)){let a=g(t),o=i?{x:n,y:e.x-a.height/2}:{x:e.x-a.width/2,y:n};O(t,t.parent,o,null);let s=E.get(t.id);p(t).forEach(e=>D.set(e.id,i?_n(o.y)+s.y+a.height+fn:_n(o.x)+s.x-fn));let{cols:c}=m(t);u(t).forEach((e,n)=>{let i={x:o.x+pn.pad+n%c*(r.width+dn.across),y:o.y+a.tops[Math.floor(n/c)]},s=f(t,e);O(e,t.id,i,null,t),s.forEach((n,a)=>O(n,e.id,{x:i.x,y:i.y+r.height+mn+a*(r.height+dn.stack)},{line:e.columns,above:s[a-1],inner:!0},t))});return}O(t,t.parent,i?{x:n,y:e.x-r.height/2}:{x:e.x-r.width/2,y:n},null)});let k=[...w,...C],A=Math.min(...k.map(e=>e.x))-gn,j=Math.min(...k.map(e=>e.y))-gn;for(let e of k)e.x-=A,e.y-=j;let M=T.map(e=>Sn(e,S,i)).filter(Boolean),N=[...k.flatMap(e=>[e.x+e.width]),...M.flatMap(e=>e.points.map(e=>e.x))],P=[...k.flatMap(e=>[e.y+e.height]),...M.flatMap(e=>e.points.map(e=>e.y))];return{cards:C,frames:w,links:M,width:Math.ceil(Math.max(...N)+gn),height:Math.ceil(Math.max(...P)+gn),size:r}}function yn(e,t,n){let r=n===`right`,i=r?`right`:`bottom`,a=r?`left`:`top`;return(e.lineTo===`left`||e.lineTo===`right`)&&!r&&(!e.lineFrom||e.lineFrom===`bottom`)?{kind:`elbow`,source:e.parent,target:e.id,from:`bottom`,to:e.lineTo,side:e.lineTo}:e.lineFrom||e.lineTo?{kind:`step`,source:e.parent,target:e.id,from:e.lineFrom||i,to:e.lineTo||a}:t?t.line===`center`?t.above?{kind:`straight`,source:t.above.id,target:e.id,from:i,to:a}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}:t.line===`right`?{kind:`rail`,source:e.parent,target:e.id,from:i,to:`right`,side:`right`}:{kind:`rail`,source:e.parent,target:e.id,from:i,to:`left`,side:`left`}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}}function bn(e,t){return t===`top`?{x:e.x+e.width/2,y:e.y}:t===`bottom`?{x:e.x+e.width/2,y:e.y+e.height}:t===`left`?{x:e.x,y:e.y+e.height/2}:{x:e.x+e.width,y:e.y+e.height/2}}var xn={top:{x:0,y:-1},bottom:{x:0,y:1},left:{x:-1,y:0},right:{x:1,y:0}};function Sn(e,t,n){let r=t.get(e.source),i=t.get(e.target);if(!r||!i)return null;let a=bn(r,e.from),o=bn(i,e.to),s;if(e.kind===`straight`)s=[a,o];else if(e.kind===`rail`){let t=a.y+(e.drop??dn.down/2),n=e.side===`right`?o.x+fn:o.x-fn;s=[a,{x:a.x,y:t},{x:n,y:t},{x:n,y:o.y},o]}else if(e.kind===`exit`){let{exit:t,into:r,level:i}=e;if(n){let e=a.x+dn.across/2;s=[a,{x:e,y:a.y},{x:e,y:t},{x:o.x-dn.down/2,y:t},{x:o.x-dn.down/2,y:o.y},o]}else{let e=a.y+dn.stack/2;s=r===`side`?[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:i},{x:o.x-fn,y:i},{x:o.x-fn,y:o.y},o]:[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:o.y-dn.down/2},{x:o.x,y:o.y-dn.down/2},o]}}else if(e.kind===`elbow`){let t=e.side===`right`?a.x<o.x+fn:a.x>o.x-fn,n=e.side===`right`?o.x+fn:o.x-fn;return s=t?[a,{x:a.x,y:a.y+dn.down/2},{x:n,y:a.y+dn.down/2},{x:n,y:o.y},o]:[a,{x:a.x,y:o.y},o],{points:wn(s),square:!t}}else s=Cn(a,e.from,o,e.to);return{points:wn(s)}}function Cn(e,t,n,r){let i=e=>e===`top`||e===`bottom`;if(t===`bottom`&&r===`top`&&n.y>e.y){let t=(e.y+n.y)/2;return[e,{x:e.x,y:t},{x:n.x,y:t},n]}if(t===`right`&&r===`left`&&n.x>e.x){let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}let a={x:e.x+xn[t].x*20,y:e.y+xn[t].y*20},o={x:n.x+xn[r].x*20,y:n.y+xn[r].y*20};return[e,a,i(t)?{x:a.x,y:o.y}:{x:o.x,y:a.y},o,n]}var wn=e=>e.filter((e,t,n)=>t===0||e.x!==n[t-1].x||e.y!==n[t-1].y);function Tn(e,t=10){let{points:n}=e,r=e.square?0:t,i=`M ${n[0].x} ${n[0].y}`;for(let e=1;e<n.length-1;e+=1){let[t,a,o]=[n[e-1],n[e],n[e+1]],s=Math.min(r,Math.hypot(a.x-t.x,a.y-t.y)/2,Math.hypot(o.x-a.x,o.y-a.y)/2),c=(e,t)=>{let n=Math.hypot(t.x-e.x,t.y-e.y)||1;return{x:e.x+(t.x-e.x)/n*s,y:e.y+(t.y-e.y)/n*s}},l=c(a,t),u=c(a,o);i+=` L ${l.x} ${l.y} Q ${a.x} ${a.y} ${u.x} ${u.y}`}let a=n.at(-1);return`${i} L ${a.x} ${a.y}`}var En=`#4f46e5`,Dn={S:.85,M:1,L:1.15,XL:1.3},On={name:14,title:12.5,unit:13.5,department:11,band:12.5},kn=1.3,An={classic:12,band:6},jn={left:`flex-start`,center:`center`,right:`flex-end`},Mn={card:`var(--page-bg, #ffffff)`,text:`var(--page-text, #111827)`,border:`rgba(148, 163, 184, 0.45)`,line:`rgba(148, 163, 184, 0.8)`},Nn=e=>String(e).replace(/[&<>"']/g,e=>({"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`})[e]),Pn=e=>Object.entries(e).filter(([,e])=>e!=null).map(([e,t])=>`${e}:${t}`).join(`;`),Fn=e=>({display:`-webkit-box`,"-webkit-line-clamp":e,"-webkit-box-orient":`vertical`,overflow:`hidden`,"overflow-wrap":`anywhere`}),In=e=>`#${[1,3,5].map(t=>Math.round(parseInt(e.slice(t,t+2),16)*.55).toString(16).padStart(2,`0`)).join(``)}`,Ln=e=>e.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0].toUpperCase()).join(``)||`?`;function Rn(e,t,n,r){let i=e=>On[e]*n*kn,a=(e,t,n)=>Math.max(1,Math.min(n,Math.floor((e+.5)/i(t)))),o=e.height-An.classic-(r.department?On.department*n*1.4:0),s=r.title?t?a(o-i(`title`),`name`,2):1:a(o,`name`,t?20:2),c=e.height*.55-An.band;return{name:s,title:a(o-s*i(`name`),`title`,t?20:2),unit:a(o,`unit`,t?20:3),top:a(c,`band`,t?20:2),bottom:a(e.height-c-2*An.band,`band`,t?20:1),single:a(e.height-An.band,`band`,t?20:3)}}function zn(e,t,n,r){let i=Dn[e.textSize||t.textSize]??1,a=e.textAlign||t.textAlign||`left`,o=e.color||En,s=Rn(n,t.wrapText,i,e),c={"box-sizing":`border-box`,width:`100%`,height:`100%`,overflow:`hidden`,position:`relative`,"font-family":`inherit`,"line-height":kn};if(t.cardStyle===`banded`){let n={display:`flex`,"align-items":`center`,"justify-content":jn[a],"text-align":a,padding:`0 10px`,color:`#fff`,"font-weight":600,"font-size":`${On.band*i}px`,"min-height":0},r=e.title||e.name,l=e.color2||In(o),u=(e.bandFill||t.bandFill)===`gradient`,d=`linear-gradient(${o}, ${l})`;return r&&!(e.title&&e.name)?`<div style="${Pn({...c,...n,"border-radius":`10px`,background:u?d:`linear-gradient(${o} 50%, ${l} 50%)`})}"><div style="${Pn(Fn(s.single))}">${Nn(r)}</div></div>`:`<div style="${Pn({...c,display:`flex`,"flex-direction":`column`,"border-radius":`10px`,background:u?d:l})}"><div style="${Pn({...n,flex:`0 0 55%`,background:u?null:o})}"><div style="${Pn(Fn(s.top))}">${Nn(e.title)}</div></div><div style="${Pn({...n,"flex-grow":1})}"><div style="${Pn(Fn(s.bottom))}">${Nn(e.name)}</div></div></div>`}let l=!!(e.photo||e.name),u=n.height>=120?56:n.height>=100?48:40,d=[];e.showPhoto&&l&&d.push(`<div style="${Pn({flex:`none`,width:`${u}px`,height:`${u}px`,"border-radius":`50%`,overflow:`hidden`,background:o,color:`#fff`,display:`flex`,"align-items":`center`,"justify-content":`center`,"font-weight":600,"font-size":`${u*.38}px`})}">`+(e.photo?`<img src="${e.photo}" alt="" style="width:100%;height:100%;object-fit:cover;display:block"/>`:Nn(Ln(e.name)))+`</div>`);let f=[];return l&&e.name&&f.push(`<div style="${Pn({...Fn(s.name),"font-weight":600,"font-size":`${On.name*i}px`})}">${Nn(e.name)}</div>`),e.title&&f.push(`<div style="${Pn({...Fn(l?s.title:s.unit),"font-size":`${(l?On.title:On.unit)*i}px`,"font-weight":l?400:600,opacity:l?.7:1})}">${Nn(e.title)}</div>`),e.department&&f.push(`<div style="${Pn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-size":`${On.department*i}px`,"line-height":1.4,color:o,"font-weight":600,"letter-spacing":`0.2px`})}">${Nn(e.department)}</div>`),d.push(`<div style="${Pn({"min-width":0,"flex-grow":1,"max-height":`100%`,overflow:`hidden`,padding:`6px 0`,"box-sizing":`border-box`,"text-align":a})}">${f.join(``)}</div>`),`<div style="${Pn({...c,display:`flex`,"align-items":`center`,gap:`10px`,padding:`0 10px 0 14px`,border:`1px solid ${r.border}`,"border-radius":`25px`,background:r.card,color:r.text})}"><div style="${Pn({position:`absolute`,left:0,top:0,bottom:0,width:`5px`,background:o})}"></div>${d.join(``)}</div>`}function Bn(e,t){let n=e.color||En;return`<div style="${Pn({"box-sizing":`border-box`,width:`100%`,height:`100%`,"border-radius":`30px`,border:`2px ${t?`solid`:`dashed`} ${n}`,background:`${n}14`,"font-family":`inherit`})}"><div style="${Pn({height:`${pn.header}px`,display:`flex`,"align-items":`center`,padding:`0 16px`})}"><div style="${Pn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-weight":700,"font-size":`14px`,color:n})}">${Nn(e.name)}</div></div></div>`}var Vn=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),G=e(((e,t)=>{t.exports=Vn()}))(),K=(0,l.createContext)({tenant:``,apiUrl:`/api`,locale:``,settings:null,revision:0}),Hn=(0,l.createContext)(null),Un=e=>{let t=Number(e?.__page);if(Number.isFinite(t)&&t>=1)return Math.floor(t);if(typeof window>`u`)return 1;let n=Number(new URLSearchParams(window.location.search).get(`page`));return Number.isFinite(n)&&n>=1?Math.floor(n):1},Wn=()=>{if(typeof window>`u`)return{};let e={};return new URLSearchParams(window.location.search).forEach((t,n)=>{n.startsWith(`f_`)&&n.length>2&&t!==``&&(e[n.slice(2)]=t)}),e},Gn=e=>{let t={...e&&typeof e==`object`&&!Array.isArray(e)?e:{},...Wn()};return Object.fromEntries(Object.entries(t).filter(([,e])=>typeof e==`string`&&e.trim()!==``))},Kn=(0,l.createContext)(null),q=(...e)=>({"data-wb-part":e.filter(Boolean).join(` `)}),qn=(0,l.createContext)(null);function Jn(e,t){if(!t)return[];let n=tr(e?.data,t);return(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id:e).filter(e=>e!=null&&e!==``).map(String)}function Yn(e,t,n){if(!t||!n||!Array.isArray(e))return[];let r=String(n.id??``);return r?e.filter(e=>Jn(e,t).includes(r)):[]}function Xn(e,t,n){return!e||!t?[]:vo(tr(e.data,t)).map((r,i)=>({...e,id:`${e.id??`entry`}:${t}:${i}`,data:{...e.data??{},[t]:wo(r,n?.[r],i)}}))}var Zn=e=>rr(e).trim().toLowerCase();function Qn(e,t){let n=Array.isArray(e?.rules)?e.rules.filter(e=>e&&e.op):[];if(!n.length||!t?.entry)return!0;let r=e=>{if(e.op===`children`||e.op===`nochildren`){let n=Yn(t.all,t.parentField,t.entry).length>0;return e.op===`children`?n:!n}let n=tr(t.entry.data,e.field),r=Zn(n),i=String(e.value??``).trim().toLowerCase(),a=(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id??e.code:null).filter(e=>e!=null).map(e=>String(e).toLowerCase()),o=Array.isArray(n)?n.length>0:r!==``;switch(e.op){case`set`:return o;case`empty`:return!o;case`eq`:return r===i||a.includes(i);case`neq`:return r!==i&&!a.includes(i);case`contains`:return i===``||r.includes(i);default:return!0}};return e.match===`any`?n.some(r):n.every(r)}function $n({showWhen:e,children:t}){return Qn(e,(0,l.useContext)(qn))?t:null}var er=e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);function tr(e,t){if(t)return t.includes(`.`)?t.split(`.`).reduce((e,t)=>e&&typeof e==`object`?e[t]:void 0,e):e?.[t]}var nr=e=>{let t=[];for(let[n,r]of Object.entries(e??{})){if(!/^[\w-]+$/.test(n))continue;t.push(n);let e=Array.isArray(r)?r[0]:r,i=Array.isArray(r)?`${n}.0`:n;if(e&&typeof e==`object`&&!Array.isArray(e))for(let n of Object.keys(e))/^[\w-]+$/.test(n)&&t.push(`${i}.${n}`)}return t};function rr(e){return e==null?``:typeof e==`string`||typeof e==`number`||typeof e==`boolean`?String(e):typeof e==`object`&&!Array.isArray(e)&&(`label`in e||`name`in e||`slug`in e)?String(e.label??e.name??e.slug??``):typeof e==`object`&&!Array.isArray(e)&&Number.isFinite(Number(e.lat))&&Number.isFinite(Number(e.lng))?`${e.lat}, ${e.lng}`:Array.isArray(e)?e.map(e=>typeof e==`string`?e:Array.isArray(e?.parts)?e.parts.map(e=>e?.text??``).join(``):Array.isArray(e?.items)?e.items.map(e=>e?.text??``).join(` `):e&&(e.label!=null||e.name!=null||e.slug!=null)?String(e.label??e.name??e.slug):``).filter(Boolean).join(` `):``}var ir=new Set([`href`,`src`,`poster`,`backgroundImage`]),ar=[`created_at`,`updated_at`,`publish_at`],or=[`date`,`short`,`iso`,`datetime`,`time`],sr={date:{dateStyle:`long`},short:{day:`2-digit`,month:`2-digit`,year:`numeric`},datetime:{dateStyle:`long`,timeStyle:`short`},time:{timeStyle:`short`}},cr=e=>String(e).padStart(2,`0`);function lr(e,t=`date`,n){if(typeof e!=`string`&&!(e instanceof Date))return``;let r=typeof e==`string`?e.match(/^(\d{4})-(\d{2})-(\d{2})$/):null,i=r?new Date(Number(r[1]),Number(r[2])-1,Number(r[3])):new Date(e);if(Number.isNaN(i.getTime()))return``;if(t===`iso`)return`${i.getFullYear()}-${cr(i.getMonth()+1)}-${cr(i.getDate())}`;try{return new Intl.DateTimeFormat(n||void 0,sr[t]??sr.date).format(i)}catch{return i.toISOString()}}function ur(e,t,n){let r=t?.data??{},i=nr(r),a=[...or].sort((e,t)=>t.length-e.length).join(`|`),o=[...i.map(er).map(e=>`${e}(?:\\.(?:${a}))?`),...ar.filter(e=>!i.includes(e)).map(e=>`${e}(?:\\.(?:${a}))?`)],s=RegExp(`:(${o.sort((e,t)=>t.length-e.length).join(`|`)})`,`g`),c=e=>{if(i.includes(e))return rr(tr(r,e));let[,o,s]=e.match(RegExp(`^(.*?)(?:\\.(${a}))?$`));if(!i.includes(o)&&ar.includes(o))return lr(t?.[o],s||`date`,n);let c=tr(r,o);return s?lr(c,s,n):rr(c)},l=e=>{let t=e.match(RegExp(`^:(${o.sort((e,t)=>t.length-e.length).join(`|`)})$`)),n=t?tr(r,t[1]):void 0;return Array.isArray(n)&&n.length?rr(n[0]):e.replace(s,(e,t)=>c(t))},u=(e,t)=>typeof e==`string`&&ir.has(t)?l(e):typeof e==`string`?e.replace(s,(e,t)=>c(t)):Array.isArray(e)?e.map(e=>u(e)):e&&typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,u(t,e)])):e;return u(e)}var dr=[`Top`,`Right`,`Bottom`,`Left`],fr=[`TopLeft`,`TopRight`,`BottomRight`,`BottomLeft`];function pr(e){let t={},n=(n,r)=>{n in e||(t[n]=r)};for(let[r,i]of Object.entries(e))if(r===`margin`||r===`padding`){let[e,t=e,a=e,o=t]=typeof i==`number`?[i]:String(i).trim().split(/\s+/);[e,t,a,o].forEach((e,t)=>n(`${r}${dr[t]}`,e))}else if(r===`borderRadius`&&(typeof i==`number`||!/\s|\//.test(String(i))))fr.forEach(e=>n(`border${e}Radius`,i));else if(r===`border`){let[e,t,...r]=String(i).trim().split(/\s+/);dr.forEach(i=>{n(`border${i}Width`,e),n(`border${i}Style`,t),n(`border${i}Color`,r.join(` `))})}else r===`background`&&!/(gradient|url)\(/i.test(String(i))?n(`backgroundColor`,i):t[r]=i;return t}var mr=pr({margin:0,fontWeight:700,lineHeight:1.2,fontFamily:`var(--page-heading-font, inherit)`}),hr=Ie,gr=e=>`var(--page-${e}, ${Ie[e]??Ie.h2}px)`,_r=pr({margin:0,fontSize:`var(--page-body-size, 16px)`}),vr={display:`inline-block`,textDecoration:`none`,cursor:`pointer`,backgroundColor:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},yr={flexGrow:1,display:`flex`,flexDirection:`column`,position:`relative`},br={display:`flex`,flexDirection:`column`};function xr({style:e}){let t=e?.backgroundVideo;if(!t)return null;let n={position:`absolute`,inset:0,width:`100%`,height:`100%`,zIndex:-1,pointerEvents:`none`},r=e?.overlayColor?`color-mix(in srgb, ${e.overlayColor} ${e.overlayOpacity??50}%, transparent)`:null;return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`video`,{src:t,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{...n,objectFit:`cover`}}),r&&(0,G.jsx)(`div`,{style:{...n,background:r}})]})}var Sr=(e,t)=>e?.backgroundVideo?{position:`relative`,...t,...z(e)}:{...t,...z(e)};function Cr({style:e,nodeRef:t,children:n}){return(0,G.jsxs)(`div`,{ref:t,style:{...yr,...z(e)},children:[(0,G.jsx)(xr,{style:e}),n]})}function wr({style:e,nodeRef:t,children:n}){return(0,G.jsxs)(`section`,{ref:t,style:Sr(e,br),children:[(0,G.jsx)(xr,{style:e}),n]})}function Tr({style:e,freeLayout:t,nodeRef:n,children:r}){let i=t?{position:`relative`,minHeight:240}:null;return(0,G.jsxs)(`div`,{ref:n,style:i?{...i,...Sr(e)}:Sr(e),children:[(0,G.jsx)(xr,{style:e}),r]})}function Er({href:e,target:t,style:n,nodeRef:r,children:i}){return(0,G.jsxs)(`a`,{ref:r,href:e||`#`,target:t||void 0,rel:t===`_blank`?`noopener noreferrer`:void 0,style:{...qr,...Sr(n)},children:[(0,G.jsx)(xr,{style:n}),i]})}function Dr({text:e,parts:t,tag:n=`h2`,style:r,linked:i,nodeRef:a}){return(0,G.jsx)(n,{ref:a,style:{...mr,fontSize:gr(n),...z(r)},children:jr(t,e,i)})}var Or={fontFamily:ze.mono.value,background:`rgba(148, 163, 184, 0.18)`,padding:`1px 5px`,borderRadius:4,fontSize:`0.9em`},kr=pr({fontFamily:ze.mono.value,background:`rgba(148, 163, 184, 0.16)`,border:`1px solid rgba(148, 163, 184, 0.3)`,borderRadius:6,padding:`12px 14px`,fontSize:`0.875em`,lineHeight:1.55,overflowX:`auto`,whiteSpace:`pre`});function Ar(e,t=[],n,r,i=!1){let a=e;return t.includes(`sup`)?a=(0,G.jsx)(`sup`,{children:a}):t.includes(`sub`)&&(a=(0,G.jsx)(`sub`,{children:a})),t.includes(`code`)&&(a=(0,G.jsx)(`code`,{style:Or,children:a})),t.includes(`strike`)&&(a=(0,G.jsx)(`s`,{children:a})),t.includes(`underline`)&&(a=(0,G.jsx)(`u`,{children:a})),t.includes(`italic`)&&(a=(0,G.jsx)(`em`,{children:a})),t.includes(`bold`)&&(a=(0,G.jsx)(`strong`,{children:a})),n?a=(0,G.jsx)(`a`,{href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":i?void 0:``,style:{...i&&{color:`inherit`},...t.includes(`nounderline`)&&{textDecoration:`none`}},children:a}):t.includes(`nounderline`)&&(a=(0,G.jsx)(`span`,{style:{textDecoration:`none`},children:a})),a}function jr(e,t,n){return e?.length?e.map((e,t)=>{if(e.slot)return(0,G.jsx)(l.Fragment,{children:n?.[e.slot]??null},t);if(e.parts)return(0,G.jsx)(l.Fragment,{children:jr(e.parts,``,n)},t);if(e.br)return(0,G.jsx)(`br`,{},t);let r=e.text;return e.image&&(r=(0,G.jsx)(`img`,{src:e.image.src,alt:e.image.alt||``,title:e.image.title||void 0,style:{maxWidth:`100%`,verticalAlign:`middle`}})),e.sup?r=(0,G.jsx)(`sup`,{children:r}):e.sub&&(r=(0,G.jsx)(`sub`,{children:r})),e.code&&(r=(0,G.jsx)(`code`,{style:Or,children:r})),e.strike&&(r=(0,G.jsx)(`s`,{children:r})),e.underline&&(r=(0,G.jsx)(`u`,{children:r})),e.italic&&(r=(0,G.jsx)(`em`,{children:r})),e.bold&&(r=(0,G.jsx)(`strong`,{children:r})),(e.color||e.background)&&(r=(0,G.jsx)(`span`,{style:{...e.color&&{color:e.color},...e.background&&{backgroundColor:e.background}},children:r})),e.href?r=(0,G.jsx)(`a`,{href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":``,style:{...e.color&&{color:e.color},...e.nounderline&&{textDecoration:`none`}},children:r}):e.nounderline&&(r=(0,G.jsx)(`span`,{style:{textDecoration:`none`},children:r})),(0,G.jsx)(l.Fragment,{children:r},t)}):t}function Mr({parts:e,text:t,marks:n,href:r,target:i,style:a}){return(0,G.jsx)(`span`,{style:z(a),children:e?.length?jr(e,t):Ar(t,n,r,i,!!z(a)?.color)})}var Nr=[`left`,`center`,`right`,`justify`];function Pr(e,t,n){let r=e&&e.cellStyles;if(!r||typeof r!=`object`||Array.isArray(r))return{};let i=r[`${t}:${n}`];return i&&typeof i==`object`&&!Array.isArray(i)?i:{}}function Fr(e,t){let n=e||{},r=typeof n.bold==`boolean`?n.bold:!!t;return{textAlign:Nr.includes(n.align)?n.align:`left`,fontWeight:r?700:400,fontStyle:n.italic?`italic`:void 0,color:typeof n.color==`string`&&n.color?n.color:void 0,backgroundColor:typeof n.bg==`string`&&n.bg?n.bg:void 0}}function Ir({align:e=`center`,width:t,wrap:n}={}){let r=t?`${t}%`:void 0;if(e===`full`)return{width:`100%`};let i=e===`left`||e===`right`;return i&&(n??!0)?{float:e,width:r??`50%`,maxWidth:`100%`,marginTop:`4px`,marginBottom:`12px`,...e===`left`?{marginRight:`20px`,marginLeft:0}:{marginLeft:`20px`,marginRight:0}}:i?{width:r??`fit-content`,maxWidth:`100%`,...e===`left`?{marginLeft:0,marginRight:`auto`}:{marginLeft:`auto`,marginRight:0}}:{width:r??`fit-content`,maxWidth:`100%`,marginLeft:`auto`,marginRight:`auto`}}var Lr={red:`#e03131`,orange:`#e8590c`,yellow:`#c98a00`,blue:`#1c7ed6`,purple:`#7048e8`,pink:`#d6336c`,green:`#2f9e44`,grey:`#868e96`},Rr={red:`rgba(224, 49, 49, 0.12)`,orange:`rgba(232, 89, 12, 0.12)`,yellow:`rgba(201, 138, 0, 0.15)`,blue:`rgba(28, 126, 214, 0.12)`,purple:`rgba(112, 72, 232, 0.12)`,pink:`rgba(214, 51, 108, 0.12)`,green:`rgba(47, 158, 68, 0.12)`,grey:`rgba(134, 142, 150, 0.16)`};function zr(e){let t=Lr[e?.color]??(e?.color||``),n=Rr[e?.background]??(e?.background||``);return{...t&&{color:t},...n&&{backgroundColor:n,padding:`8px 12px`,borderRadius:`8px`}}}function Br(e=[],t,n){let r=n??((e,n)=>jr(e,n,t));return e.map((n,i)=>{let a={marginTop:0,marginBottom:i===e.length-1?0:14};if(n.type===`image`){if(!n.src)return null;let e=(0,G.jsx)(`img`,{...q(`image`),src:n.src,alt:n.alt||``,style:{width:`100%`,display:`block`,borderRadius:6}});return(0,G.jsxs)(`figure`,{...q(`figure`),style:{marginLeft:0,marginRight:0,...a,...Ir(n)},children:[n.href?(0,G.jsx)(`a`,{href:n.href,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`},children:e}):e,n.caption&&(0,G.jsx)(`figcaption`,{...q(`caption`),style:{fontSize:13,opacity:.65,marginTop:6,textAlign:`center`},children:n.caption})]},i)}if(n.type===`video`)return ti(n.url)?(0,G.jsx)(`div`,{...q(`video`),style:{...a,...Ir({align:n.align,wrap:n.wrap,width:n.width??100})},children:(0,G.jsx)(ni,{url:n.url,autoplay:n.autoplay,muted:n.muted,loop:n.loop,controls:n.controls??!0,start:n.start})},i):null;if(n.type===`button`){if(!(typeof n.label==`string`&&n.label.trim()))return null;let e=Number.isFinite(Number(n.radius))?Number(n.radius):8,t=[`center`,`right`].includes(n.align)?n.align:`left`;return(0,G.jsx)(`div`,{style:{...a,textAlign:t},children:(0,G.jsx)(`table`,{role:`presentation`,cellPadding:0,cellSpacing:0,style:{borderCollapse:`separate`,display:`inline-table`},children:(0,G.jsx)(`tbody`,{children:(0,G.jsx)(`tr`,{children:(0,G.jsx)(`td`,{style:{backgroundColor:n.bg||`var(--page-accent, #4f46e5)`,borderRadius:e},children:(0,G.jsx)(`a`,{...q(`button`),href:n.href||`#`,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`inline-block`,padding:`13px 24px`,color:n.color||`#ffffff`,fontSize:15,fontWeight:600,lineHeight:1.2,textDecoration:`none`,borderRadius:e},children:n.label})})})})})},i)}if(n.type===`divider`)return(0,G.jsx)(`hr`,{...q(`divider`),style:{...a,border:0,borderTop:`1px solid rgba(148, 163, 184, 0.4)`}},i);if(n.type===`table`){let e=Array.isArray(n.rows)?n.rows.filter(Array.isArray):[];if(!e.length)return null;let t=n.header!==!1,o=n.borders===!1?void 0:`1px solid rgba(148, 163, 184, 0.4)`,s=Number.isFinite(n.padX)?Math.max(0,n.padX):10,c=Number.isFinite(n.padY)?Math.max(0,n.padY):6,l=Math.max(0,Number(n.spacing)||0),u={border:o,padding:`${c}px ${s}px`,verticalAlign:`top`},d=Array.isArray(n.heights)?n.heights:null,f=e=>{let t=Number(d?.[e]);return Number.isFinite(t)&&t>0?{height:`${t}px`}:void 0},p=t?e.slice(1):e,m=Array.isArray(n.widths)?n.widths:null,h=(e,t,r)=>({...u,...Fr(Pr(n,e,t),r)}),g=n.spans&&typeof n.spans==`object`?n.spans:null,_=new Set;g&&e.forEach((e,t)=>e.forEach((e,n)=>{let r=g[`${t}:${n}`];if(!r)return;let i=Math.max(1,Number(r.c)||1),a=Math.max(1,Number(r.r)||1);for(let e=0;e<a;e+=1)for(let r=0;r<i;r+=1)(e||r)&&_.add(`${t+e}:${n+r}`)}));let v=(e,t)=>{let n=g?.[`${e}:${t}`],r=Math.max(1,Number(n?.c)||1),i=Math.max(1,Number(n?.r)||1);return{colSpan:r>1?r:void 0,rowSpan:i>1?i:void 0}};return(0,G.jsxs)(`table`,{...q(`table`),style:{...a,borderCollapse:l?`separate`:`collapse`,borderSpacing:l?`${l}px`:void 0,width:`100%`,fontSize:_r.fontSize,tableLayout:m?`fixed`:void 0},children:[typeof n.caption==`string`&&n.caption.trim()?(0,G.jsx)(`caption`,{...q(`caption`),style:{captionSide:`top`,textAlign:`left`,fontWeight:600,padding:`0 0 6px`},children:n.caption}):null,m&&(0,G.jsx)(`colgroup`,{children:m.map((e,t)=>(0,G.jsx)(`col`,{style:{width:`${e}%`}},t))}),t&&(0,G.jsx)(`thead`,{children:(0,G.jsx)(`tr`,{...q(`header-row`),style:f(0),children:e[0].map((e,t)=>_.has(`0:${t}`)?null:(0,G.jsx)(`th`,{...q(`header-cell`),scope:`col`,style:h(0,t,!0),...v(0,t),children:Array.isArray(e)?r(e):e},t))})}),(0,G.jsx)(`tbody`,{children:p.map((e,n)=>(0,G.jsx)(`tr`,{...q(`row`),style:f(t?n+1:n),children:e.map((e,i)=>{let a=t?n+1:n;return _.has(`${a}:${i}`)?null:(0,G.jsx)(`td`,{...q(`cell`),style:h(a,i,!1),...v(a,i),children:Array.isArray(e)?r(e):e},i)})},n))})]},i)}if(n.type===`ul`||n.type===`ol`){let e=n.type;return(0,G.jsx)(e,{...q(`list`,n.type===`ol`&&`list-ordered`),style:{fontSize:_r.fontSize,...a,...zr(n),paddingLeft:n.background?34:24},start:n.type===`ol`?n.start:void 0,children:(n.items??[]).map((e,n)=>{let i=typeof e.task==`boolean`;return(0,G.jsxs)(`li`,{...q(`list-item`),style:{marginBottom:4,...i&&{listStyleType:`none`,marginLeft:-18}},children:[i&&(0,G.jsx)(`span`,{style:{marginRight:6},children:e.task?`☑`:`☐`}),r(e.parts,e.text),e.blocks?.length?Br(e.blocks,t,r):null]},n)})},i)}if(n.type===`quote`)return(0,G.jsx)(`blockquote`,{...q(`quote`),style:{...Ur,fontSize:_r.fontSize,...a,...zr(n),...n.background&&{paddingLeft:20}},children:n.blocks?.length?Br(n.blocks,t,r):r(n.parts,n.text)},i);if(n.type===`code`)return(0,G.jsx)(`pre`,{...q(`code`),"data-lang":n.lang||void 0,style:{...a,...kr},children:(0,G.jsx)(`code`,{style:{fontFamily:`inherit`},children:n.text})},i);if(hr[n.type]){let e=n.type;return(0,G.jsx)(e,{...q(`heading`,`heading-${n.type}`),style:{...mr,fontSize:gr(n.type),...a,...zr(n)},children:r(n.parts,n.text)},i)}return(0,G.jsx)(`p`,{...q(`paragraph`),style:{..._r,...a,...zr(n)},children:r(n.parts,n.text)},i)})}function Vr({content:e,style:t,linked:n,nodeRef:r}){return(0,G.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(t)},children:Br(e,n)})}function Hr({markdown:e,newTab:t,style:n,nodeRef:r}){let i=(0,l.useMemo)(()=>rn(e,{newTab:t}),[e,t]);return(0,G.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(n)},children:Br(i)})}var Ur=pr({margin:0,padding:`8px 0 8px 20px`,borderLeftWidth:`4px`,borderLeftStyle:`solid`,borderLeftColor:`var(--page-accent, rgba(148, 163, 184, 0.6))`});function Wr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,G.jsx)(`blockquote`,{ref:i,style:{...Ur,...z(n)},children:jr(t,e,r)})}function Gr({ordered:e,items:t=[],style:n,nodeRef:r}){return(0,G.jsx)(e?`ol`:`ul`,{ref:r,style:{margin:0,paddingLeft:24,...z(n)},children:t.map((e,t)=>(0,G.jsx)(`li`,{...q(`item`),style:{marginBottom:4},children:jr(e.parts,e.text)},t))})}function Kr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,G.jsx)(`p`,{ref:i,style:{..._r,...z(n)},children:jr(t,e,r)})}var qr={display:`block`,color:`inherit`,textDecoration:`none`,cursor:`pointer`},Jr={textUnderlineOffset:3,cursor:`pointer`};function Yr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,G.jsx)(`a`,{ref:o,"data-wb-link":``,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...Jr,...z(i)},children:jr(t,e,a)})}function Xr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,G.jsx)(`a`,{ref:o,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...vr,...z(i)},children:jr(t,e,a)})}function Zr({src:e,alt:t,decorative:n,style:r,nodeRef:i}){return e?(0,G.jsx)(`img`,{ref:i,src:e,alt:n?``:t||``,role:n?`presentation`:void 0,style:{display:`block`,maxWidth:`100%`,...z(r)}}):null}function Qr({text:e,locale:t}){let n=String(e??``).trim();return n?(0,G.jsxs)(`details`,{...q(`transcript`),style:{marginTop:8,fontSize:14},children:[(0,G.jsx)(`summary`,{...q(`transcript-toggle`),style:{cursor:`pointer`,fontWeight:600},children:at(t)(`transcript`)}),(0,G.jsx)(`div`,{...q(`transcript-text`),style:{marginTop:8,lineHeight:1.6},children:n.split(/\n\s*\n/).map((e,t)=>(0,G.jsx)(`p`,{style:{margin:`0 0 8px`,whiteSpace:`pre-line`},children:e},t))})]}):null}var $r=e=>(Array.isArray(e)?e:[]).filter(e=>typeof e?.src==`string`&&e.src.trim());function ei({src:e,poster:t,controls:n=!0,autoplay:r=!1,loop:i=!1,muted:a=!1,title:o=``,tracks:s,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(K);if(!e)return null;let p=$r(s),m=typeof o==`string`&&o.trim()?o.trim():void 0,h=typeof c==`string`&&c.trim(),g=(0,G.jsx)(`video`,{ref:h?void 0:d,...h?{"data-wb-self":``}:{},src:e,poster:t||void 0,controls:n,"aria-label":m,autoPlay:r,muted:a||r,loop:i,playsInline:!0,crossOrigin:p.length?`anonymous`:void 0,style:{display:`block`,width:`100%`,maxWidth:`100%`,...z(u)},children:p.map((e,t)=>(0,G.jsx)(`track`,{kind:e.kind===`captions`?`captions`:`subtitles`,src:e.src,srcLang:e.srclang||void 0,label:e.label||e.srclang||void 0,default:e.default?!0:void 0},e.key??t))});return h?(0,G.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[g,(0,G.jsx)(Qr,{text:c,locale:f})]}):g}var ti=(e=``)=>(e.match(/(?:youtu\.be\/|v=|embed\/|shorts\/|live\/)([\w-]{11})/)||e.match(/^([\w-]{11})$/))?.[1];function ni({url:e,autoplay:t=!1,muted:n=!1,loop:r=!1,controls:i=!0,start:a,title:o=``,captions:s=!1,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(K),p=ti(e);if(!p)return null;let m=new URLSearchParams({rel:`0`});if(t&&m.set(`autoplay`,`1`),(n||t)&&m.set(`mute`,`1`),i||m.set(`controls`,`0`),r&&(m.set(`loop`,`1`),m.set(`playlist`,p)),Number(a)>0&&m.set(`start`,String(Math.floor(Number(a)))),s){m.set(`cc_load_policy`,`1`);let e=String(f||``).split(/[-_]/)[0];e&&m.set(`cc_lang_pref`,e)}let h=(0,G.jsx)(`iframe`,{...q(`frame`),src:`https://www.youtube-nocookie.com/embed/${p}?${m}`,title:typeof o==`string`&&o.trim()?o.trim():at(f)(`video`),allow:`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share`,allowFullScreen:!0,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,border:0}});return typeof c==`string`&&c.trim()?(0,G.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[(0,G.jsx)(`div`,{"data-wb-self":``,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h}),(0,G.jsx)(Qr,{text:c,locale:f})]}):(0,G.jsx)(`div`,{ref:d,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h})}function ri({src:e,title:t,allowFullscreen:n=!0,style:r,nodeRef:i}){let{locale:a}=(0,l.useContext)(K);return e?(0,G.jsx)(`iframe`,{ref:i,src:e,title:t||at(a)(`frame`),loading:`lazy`,allowFullScreen:n,style:{display:`block`,width:`100%`,height:300,border:0,...z(r)}}):null}function ii(e,{toolbar:t=!0,page:n,zoom:r}={}){let i=Et(e);if(!i)return``;let a=[];return t===!1&&a.push(`toolbar=0&navpanes=0`),Number(n)>1&&a.push(`page=${Number(n)}`),r&&r!==`auto`&&a.push(`zoom=${r}`),a.length?`${i.split(`#`)[0]}#${a.join(`&`)}`:i}function ai({src:e,title:t,toolbar:n=!0,page:r,zoom:i=`auto`,link:a=!0,linkLabel:o,fallbackText:s,style:c,nodeRef:l}){let u=Et(e);if(!u)return null;let d=o||`Open the PDF`,f=t||`PDF document`;return(0,G.jsxs)(`div`,{ref:l,style:{display:`flex`,flexDirection:`column`,width:`100%`,height:600,...z(c)},children:[(0,G.jsx)(`object`,{data:ii(u,{toolbar:n,page:r,zoom:i}),type:`application/pdf`,"aria-label":f,...q(`document`),style:{display:`block`,flex:`1 1 auto`,minHeight:0,width:`100%`,border:0},children:(0,G.jsxs)(`div`,{...q(`fallback`),style:{display:`grid`,placeItems:`center`,gap:8,height:`100%`,padding:16,textAlign:`center`},children:[(0,G.jsx)(`p`,{style:{..._r,opacity:.75},children:s||`This browser can’t show the PDF here.`}),!a&&(0,G.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, inherit)`},children:d})]})},ii(u,{toolbar:n,page:r,zoom:i})),a&&(0,G.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,...q(`link`),style:{flexShrink:0,marginTop:8,color:`var(--page-accent, inherit)`,fontSize:14},children:d})]})}var oi=/(^|[\s,>+~{}])(:root|html|body)(?=$|[\s,{.:#[>+~])/g;function si(e){return`@scope ([data-wb-embed]) {\n${e.replace(oi,`$1:scope`)}\n}`}function ci({code:e,runScripts:t=!0,scopeStyles:n=!1,style:r,nodeRef:i}){let[a,o]=(0,l.useState)(null);return(0,l.useEffect)(()=>{a&&(a.innerHTML=e||``,n?(a.setAttribute(`data-wb-embed`,``),a.querySelectorAll(`style`).forEach(e=>{e.textContent=si(e.textContent||``)})):a.removeAttribute(`data-wb-embed`),t&&a.querySelectorAll(`script`).forEach(e=>{let t=document.createElement(`script`);for(let{name:n,value:r}of e.attributes)t.setAttribute(n,r);t.text=e.textContent,e.replaceWith(t)}))},[a,e,t,n]),(0,G.jsx)(`div`,{ref:e=>{o(e),i&&i(e)},style:z(r)})}function li({height:e,style:t,nodeRef:n}){return(0,G.jsx)(`div`,{ref:n,style:{height:e||32,flexShrink:0,alignSelf:`stretch`,...z(t)}})}function ui({style:e,nodeRef:t}){return(0,G.jsx)(`div`,{ref:t,style:{height:1,alignSelf:`stretch`,flexShrink:0,...z(e)}})}function di({style:e,nodeRef:t}){return(0,G.jsx)(`div`,{ref:t,style:{flexShrink:0,...z(e)}})}var fi={position:`absolute`,top:`50%`,transform:`translateY(-50%)`,width:36,height:36,borderRadius:`50%`,border:0,cursor:`pointer`,background:`rgba(17, 24, 39, 0.45)`,color:`#fff`,fontSize:20,lineHeight:1,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:0},pi={bottom:{inset:`auto 0 0 0`,padding:`40px 24px 20px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.55))`},top:{inset:`0 0 auto 0`,padding:`20px 24px 40px`,background:`linear-gradient(rgba(0, 0, 0, 0.55), transparent)`},middle:{inset:0,display:`flex`,flexDirection:`column`,justifyContent:`center`,padding:24,textShadow:`0 2px 12px rgba(0, 0, 0, 0.6)`}},mi=48;function hi({count:e,renderSlide:t,autoplay:n=!0,interval:r=5,height:i=320,swipe:a=!0,style:o,nodeRef:s}){let[c,u]=(0,l.useState)(0),[d,f]=(0,l.useState)(!1),[p,m]=(0,l.useState)(!1),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(null),{locale:y}=(0,l.useContext)(K),b=e?Math.min(c,e-1):0;if((0,l.useEffect)(()=>{window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches&&g(!0)},[]),(0,l.useEffect)(()=>{if(!n||h||d||p||_||e<2)return;let t=setInterval(()=>u(t=>(t+1)%e),Math.max(2,Number(r)||5)*1e3);return()=>clearInterval(t)},[n,h,d,p,_,r,e]),!e)return null;let x=at(y),S=t=>u((t+e)%e),C=()=>{if(!_)return;let{dx:e}=_;v(null),e<-48?S(b+1):e>mi&&S(b-1)};return(0,G.jsxs)(`div`,{ref:s,role:`region`,"aria-roledescription":`carousel`,onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1),onFocus:()=>m(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||m(!1)},onPointerDown:a&&e>1?e=>{e.pointerType===`mouse`&&e.button!==0||e.target.closest(`button`)||(e.currentTarget.setPointerCapture(e.pointerId),v({startX:e.clientX,dx:0}))}:void 0,onPointerMove:_?e=>v(t=>t&&{...t,dx:e.clientX-t.startX}):void 0,onPointerUp:C,onPointerCancel:C,style:{position:`relative`,overflow:`hidden`,width:`100%`,height:i,touchAction:`pan-y`,userSelect:_?`none`:void 0,cursor:_?`grabbing`:void 0,...z(o)},children:[(0,G.jsx)(`div`,{...q(`track`),style:{display:`flex`,height:`100%`,transform:`translateX(calc(${-b*100}% + ${_?.dx??0}px))`,transition:_?`none`:`transform 450ms ease`},children:Array.from({length:e},(n,r)=>(0,G.jsx)(`div`,{...q(`slide`,r===b&&`slide-active`),role:`group`,"aria-roledescription":`slide`,"aria-label":x(`slide`,{n:r+1,total:e}),"aria-hidden":r!==b||void 0,inert:r!==b||void 0,style:{position:`relative`,width:`100%`,flexShrink:0,overflow:`hidden`},children:t(r)},r))}),e>1&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`button`,{type:`button`,...q(`arrow`,`arrow-prev`),"aria-label":x(`prevSlide`),style:{...fi,left:12},onClick:()=>S(b-1),children:`‹`}),(0,G.jsx)(`button`,{type:`button`,...q(`arrow`,`arrow-next`),"aria-label":x(`nextSlide`),style:{...fi,right:12},onClick:()=>S(b+1),children:`›`}),(0,G.jsx)(`div`,{...q(`dots`),style:{position:`absolute`,bottom:10,left:0,right:0,display:`flex`,justifyContent:`center`,gap:6},children:Array.from({length:e},(e,t)=>(0,G.jsx)(`button`,{type:`button`,"aria-label":x(`goToSlide`,{n:t+1}),"aria-current":t===b?`true`:void 0,...q(`dot`,t===b&&`dot-active`),onClick:()=>S(t),style:{width:8,height:8,borderRadius:`50%`,border:0,padding:0,cursor:`pointer`,background:t===b?`#ffffff`:`rgba(255, 255, 255, 0.45)`}},t))}),n&&(0,G.jsx)(`button`,{type:`button`,...q(`pause`,h&&`pause-stopped`),"aria-label":x(h?`play`:`pause`),onClick:()=>g(!h),style:{...fi,top:`auto`,bottom:8,right:12,transform:`none`,width:28,height:28},children:(0,G.jsx)(`svg`,{viewBox:`0 0 24 24`,width:14,height:14,fill:`currentColor`,"aria-hidden":`true`,children:(0,G.jsx)(`path`,{d:h?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})})]})]})}var gi=(e,t)=>({position:`absolute`,inset:0,backgroundImage:e?`url(${e})`:`none`,backgroundColor:t||(e?void 0:`rgba(148, 163, 184, 0.25)`),backgroundSize:`cover`,backgroundPosition:`center`});function _i({slides:e=[],captionPosition:t=`bottom`,captionAlign:n=`left`,...r}){return e.length?(0,G.jsx)(hi,{...r,count:e.length,renderSlide:r=>{let i=e[r];return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`div`,{...q(`slide-image`),style:gi(i.image)}),(i.title||i.text)&&(0,G.jsxs)(`div`,{...q(`caption`),style:{position:`absolute`,color:`#fff`,textAlign:n,...pi[t]??pi.bottom},children:[i.title&&(0,G.jsx)(`div`,{...q(`caption-title`),style:{fontSize:22,fontWeight:700},children:i.title}),i.text&&(0,G.jsx)(`div`,{...q(`caption-text`),style:{fontSize:14,opacity:.9,marginTop:4},children:i.text})]})]})}}):null}function vi({slides:e=[],linked:t,...n}){return e.length?(0,G.jsx)(hi,{...n,count:e.length,renderSlide:n=>{let r=e[n];return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`div`,{...q(`slide-background`),style:gi(r.image,r.color)}),(0,G.jsx)(`div`,{...q(`slide-content`),style:{position:`absolute`,inset:0,display:`flex`,flexDirection:`column`},children:t?.[r.key]??null})]})}}):null}var yi=256,bi=e=>Math.log(Math.tan(Math.PI/4+Math.max(-85,Math.min(85,e))*Math.PI/360)),xi=(e,t,n)=>{let r=yi*2**n;return{x:(Number(t)+180)/360*r,y:(.5-bi(Number(e))/(2*Math.PI))*r}},Si=(e,t)=>{if(e===``||e==null)return null;let n=Number(e);return Number.isFinite(n)&&Math.abs(n)<=t?n:null},Ci=e=>!!e&&Si(e.lat,90)!==null&&Si(e.lng,180)!==null;function wi(e,t,n=`directions`,r=``){let i=`${e},${t}`;return n===`place`?`https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(i)}${r?`&query_place_id=`:``}`:`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(i)}`}var Ti=`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,J=e=>{let t=String(e??``).trim();return/^https?:\/\//i.test(t)&&t.includes(`{z}`)&&t.includes(`{x}`)&&t.includes(`{y}`)?t:Ti},Ei=e=>{try{return new URL(e.replace(/[{}]/g,``)).host}catch{return e}},Di=(e,t,n=13)=>`https://www.openstreetmap.org/?mlat=${e}&mlon=${t}#map=${Math.round(Number(n)||13)}/${e}/${t}`;function Oi({markers:e,lat:t,lng:n,zoom:r=``,height:i=320,pinSize:a=22,pinLink:o=`directions`,link:s=!1,label:c=``,tileUrl:u=``,tileError:d=``,style:f,nodeRef:p,inert:m}){let h=(0,l.useRef)(null),[g,_]=(0,l.useState)(1200),v=J(u),[y,b]=(0,l.useState)({key:``,failed:0,loaded:0});(0,l.useEffect)(()=>{let e=h.current;if(!e||typeof ResizeObserver>`u`)return;let t=()=>_(t=>e.clientWidth&&e.clientWidth!==t?e.clientWidth:t);t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]);let x=(Array.isArray(e)?e:[]).filter(Ci),S=Ci({lat:t,lng:n})?{lat:Si(t,90),lng:Si(n,180)}:x.length?{lat:x.reduce((e,t)=>e+Si(t.lat,90),0)/x.length,lng:x.reduce((e,t)=>e+Si(t.lng,180),0)/x.length}:null,C=Math.max(80,Number(i)||320),w=Si(r,19)?Math.min(Math.max(Math.round(Number(r)),1),19):(()=>{if(x.length<2)return 13;for(let e=19;e>=1;e--){let t=x.map(t=>xi(Si(t.lat,90),Si(t.lng,180),e)),n=Math.max(...t.map(e=>e.x))-Math.min(...t.map(e=>e.x)),r=Math.max(...t.map(e=>e.y))-Math.min(...t.map(e=>e.y));if(n<=g*.8&&r<=C*.7)return e}return 1})(),T={width:`100%`,...z(f)};if(!S)return(0,G.jsx)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:{...T,minHeight:80,display:`grid`,placeItems:`center`,fontSize:13,opacity:.6,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:8},children:`Set the coordinates in Settings`});let E=xi(S.lat,S.lng,w),D={x:E.x-g/2,y:E.y-C/2},O=[],k=[];for(let e=Math.floor(D.x/yi);e<=Math.floor((D.x+g)/yi);e++)O.push(e);for(let e=Math.floor(D.y/yi);e<=Math.floor((D.y+C)/yi);e++)k.push(e);let A=2**w,j=`${v}|${w}`,M=y.key===j?y:{key:j,failed:0,loaded:0},N=e=>b(t=>{let n=t.key===j?t:{key:j,failed:0,loaded:0};return{...n,[e]:n[e]+1}}),P=M.failed>0&&M.loaded===0;return(0,G.jsxs)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:T,children:[(0,G.jsxs)(`div`,{role:`img`,"aria-label":c||`Map`,...q(`map`),style:{position:`relative`,height:C,overflow:`hidden`,borderRadius:`inherit`,background:`var(--page-surface, #e5e7eb)`},children:[k.map(e=>O.map(t=>{let n=(t%A+A)%A;return e<0||e>=A?null:(0,G.jsx)(`img`,{src:v.replace(`{z}`,w).replace(`{x}`,n).replace(`{y}`,e),alt:``,onLoad:()=>N(`loaded`),onError:e=>{e.currentTarget.style.visibility=`hidden`,N(`failed`)},width:yi,height:yi,loading:`lazy`,style:{position:`absolute`,left:Math.round(t*yi-D.x),top:Math.round(e*yi-D.y),width:yi,height:yi,userSelect:`none`,pointerEvents:`none`}},`${j}:${t}-${e}`)})),P&&m&&d?(0,G.jsx)(`div`,{style:{...Fe,position:`absolute`,left:12,right:12,top:12,padding:`8px 12px`,borderRadius:8,background:`rgba(15, 23, 42, 0.78)`,color:`#fff`,fontSize:12,lineHeight:1.45},children:d.replace(`{host}`,Ei(v))}):null,x.map((e,t)=>{let n=xi(Si(e.lat,90),Si(e.lng,180),w),r=n.x-D.x,i=n.y-D.y,s=e.color||`var(--page-accent, #dc2626)`,c=o===`none`||m?null:wi(Si(e.lat,90),Si(e.lng,180),o,e.title);return(0,G.jsxs)(c?`a`:`span`,{...q(`pin`),href:c||void 0,target:c?`_blank`:void 0,rel:c?`noopener noreferrer`:void 0,title:c&&e.title||void 0,style:{position:`absolute`,left:r,top:i,transform:`translate(-50%, -100%)`,cursor:c?`pointer`:`default`,textDecoration:`none`,color:`inherit`},children:[e.title?(0,G.jsx)(`span`,{...q(`pin-label`),style:{position:`absolute`,left:`50%`,bottom:`100%`,transform:`translateX(-50%)`,marginBottom:4,padding:`3px 7px`,borderRadius:6,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.5))`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.25)`,fontSize:12,lineHeight:1.35,whiteSpace:`nowrap`},children:e.title}):null,(0,G.jsxs)(`svg`,{width:Math.max(10,Number(a)||22),height:Math.max(10,Number(a)||22),viewBox:`0 0 24 24`,fill:s,style:{display:`block`},children:[(0,G.jsx)(`path`,{d:`M12 22s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11z`}),ki[e.icon]?(0,G.jsx)(`path`,{d:ki[e.icon],transform:`translate(12 10.5) scale(0.46) translate(-12 -12)`,fill:`none`,stroke:`#fff`,strokeWidth:4,strokeLinecap:`round`,strokeLinejoin:`round`}):(0,G.jsx)(`circle`,{cx:`12`,cy:`10.5`,r:`2.6`,fill:`#fff`})]})]},t)}),(0,G.jsx)(`a`,{href:`https://www.openstreetmap.org/copyright`,target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...q(`credit`),style:{position:`absolute`,right:4,bottom:3,padding:`1px 5px`,borderRadius:4,background:`rgba(255, 255, 255, 0.75)`,color:`#334155`,fontSize:10,textDecoration:`none`},children:`© OpenStreetMap`})]}),s?(0,G.jsx)(`a`,{href:Di(S.lat,S.lng,w),target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...q(`link`),style:{display:`inline-block`,marginTop:6,fontSize:12,color:`var(--page-accent, inherit)`},children:`View larger map`}):null]})}var ki={check:`M4 12l5 5L20 6`,close:`M6 6l12 12M18 6L6 18`,plus:`M12 5v14M5 12h14`,minus:`M5 12h14`,"arrow-right":`M4 12h16M13 5l7 7-7 7`,"arrow-left":`M20 12H4M11 5l-7 7 7 7`,"arrow-up":`M12 20V4M5 11l7-7 7 7`,"arrow-down":`M12 4v16M5 13l7 7 7-7`,"chevron-right":`M9 5l7 7-7 7`,"chevron-left":`M15 5l-7 7 7 7`,"chevron-down":`M5 9l7 7 7-7`,"chevron-up":`M5 15l7-7 7 7`,menu:`M4 7h16M4 12h16M4 17h16`,star:`M12 3.5l2.6 5.3 5.9.9-4.3 4.1 1 5.8-5.2-2.7-5.2 2.7 1-5.8L3.5 9.7l5.9-.9z`,heart:`M12 20s-7-4.4-7-9a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 4.6-7 9-7 9z`,home:`M4 11l8-7 8 7M6 10v9h12v-9`,user:`M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM4 20c0-3.3 3.6-5 8-5s8 1.7 8 5`,mail:`M3 6h18v12H3zM3 6l9 7 9-7`,phone:`M6 3h4l2 5-3 2a12 12 0 0 0 5 5l2-3 5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 4 5a2 2 0 0 1 2-2z`,search:`M11 4a7 7 0 1 0 0 14 7 7 0 0 0 0-14zM20 20l-4.2-4.2`,clock:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 7v5l3 2`,calendar:`M4 6h16v14H4zM4 10h16M8 3v4M16 3v4`,download:`M12 4v10M8 11l4 4 4-4M4 19h16`,upload:`M12 20V10M8 13l4-4 4 4M4 5h16`,play:`M8 5l11 7-11 7z`,pause:`M9 5v14M15 5v14`,info:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 11v5M12 8h.01`,alert:`M12 4l9 16H3zM12 10v4M12 17h.01`,lock:`M6 11h12v9H6zM9 11V8a3 3 0 0 1 6 0v3`,chat:`M4 5h16v11H9l-5 4z`,"map-pin":`M12 21s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11zM12 12a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5z`,camera:`M4 8h4l2-2h4l2 2h4v12H4zM12 17a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z`,image:`M4 5h16v14H4zM8 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM6 17l5-5 4 4 2-2 3 3`,file:`M7 3h7l4 4v14H7zM14 3v5h4`,link:`M10 14a4 4 0 0 0 6 .5l2-2a4 4 0 0 0-6-6l-1 1M14 10a4 4 0 0 0-6-.5l-2 2a4 4 0 0 0 6 6l1-1`,external:`M14 4h6v6M20 4l-9 9M18 14v5H5V6h5`,trash:`M4 7h16M9 7V5h6v2M6 7l1 13h10l1-13`,edit:`M4 20h4L19 9l-4-4L4 16z`,filter:`M3 5h18l-7 8v6l-4-2v-4z`,refresh:`M20 12a8 8 0 1 1-2.3-5.7M20 4v5h-5`,globe:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM3 12h18M12 3c2.5 3 2.5 15 0 18M12 3c-2.5 3-2.5 15 0 18`,bell:`M6 16V11a6 6 0 1 1 12 0v5l2 3H4zM10 22h4`,tag:`M4 4h7l9 9-7 7-9-9zM8.5 8.5h.01`,cart:`M4 5h2l2 10h10l2-7H7M9 20h.01M18 20h.01`,card:`M3 6h18v12H3zM3 10h18`,shield:`M12 3l8 3v6c0 5-4 8-8 9-4-1-8-4-8-9V6z`,sun:`M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zM12 2v2M12 20v2M4 12H2M22 12h-2M5 5l1.5 1.5M17.5 17.5L19 19M19 5l-1.5 1.5M6.5 17.5L5 19`,moon:`M20 14a8 8 0 1 1-10-10 7 7 0 0 0 10 10z`,settings:`M12 9.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM12 2l1 2.6 2.7-.6 1 2.5 2.6 1-.6 2.7L21 12l-2.3 1.8.6 2.7-2.6 1-1 2.5-2.7-.6L12 22l-1-2.6-2.7.6-1-2.5-2.6-1 .6-2.7L3 12l2.3-1.8-.6-2.7 2.6-1 1-2.5 2.7.6z`,eye:`M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7zM12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z`,"eye-off":`M4 4l16 16M9.5 9.6A3 3 0 0 0 12 15c.8 0 1.5-.3 2.1-.8M6.6 6.7C3.9 8.3 2 12 2 12s4 7 10 7c1.9 0 3.5-.5 4.9-1.2M14.1 5.4C13.4 5.1 12.7 5 12 5`,share:`M8 12a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 6a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 18a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM7.8 10.8l8.4-3.6M7.8 13.2l8.4 3.6`,send:`M21 3L3 10l7 3 3 7z`,paperclip:`M20 11l-8.5 8.5a5 5 0 0 1-7-7L13 4a3.5 3.5 0 0 1 5 5l-8.5 8.5a2 2 0 0 1-3-3L15 6`,video:`M3 7h11v10H3zM14 11l6-3v8l-6-3`,music:`M9 18V6l10-2v12M9 18a2.5 2.5 0 1 1-2.5-2.5H9M19 16a2.5 2.5 0 1 1-2.5-2.5H19`,mic:`M12 3a3 3 0 0 1 3 3v5a3 3 0 0 1-6 0V6a3 3 0 0 1 3-3zM5 11a7 7 0 0 0 14 0M12 18v3`,headphones:`M4 15v-3a8 8 0 1 1 16 0v3M4 15h3v5H5a1 1 0 0 1-1-1zM20 15h-3v5h2a1 1 0 0 0 1-1z`,book:`M5 4h14v16H7a2 2 0 0 1-2-2zM7 4v14h12`,bookmark:`M7 4h10v16l-5-4-5 4z`,folder:`M4 6h5l2 2h9v10H4z`,cloud:`M7 18a4 4 0 0 1 .5-8 5.5 5.5 0 0 1 10.4 1.5A3.5 3.5 0 0 1 17.5 18z`,database:`M12 3c4.4 0 8 1.3 8 3s-3.6 3-8 3-8-1.3-8-3 3.6-3 8-3zM4 6v12c0 1.7 3.6 3 8 3s8-1.3 8-3V6M4 12c0 1.7 3.6 3 8 3s8-1.3 8-3`,server:`M4 4h16v6H4zM4 14h16v6H4zM8 7h.01M8 17h.01`,code:`M9 8l-5 4 5 4M15 8l5 4-5 4`,terminal:`M4 5h16v14H4zM8 10l3 2-3 2M13 14h4`,wifi:`M5 12a10 10 0 0 1 14 0M8 15a6 6 0 0 1 8 0M12 19h.01`,battery:`M3 8h15v8H3zM21 11v2`,printer:`M7 8V4h10v4M7 16H4V8h16v8h-3M7 13h10v7H7z`,gift:`M4 10h16v10H4zM3 6h18v4H3zM12 6v14M12 6c-2 0-4-1-4-2.5S9 2 10 3s2 3 2 3zM12 6c2 0 4-1 4-2.5S15 2 14 3s-2 3-2 3z`,key:`M15 4a5 5 0 1 0-4.6 7L9 12.4V15H6.5L4 17.5V20h4l7-7A5 5 0 0 0 15 4z`,compass:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM15 9l-2 5-5 2 2-5z`,flag:`M5 21V4h13l-2 4 2 4H5`,award:`M12 4a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM9 13l-1 7 4-2 4 2-1-7`,chart:`M4 20V4M4 20h16M8 16v-5M12 16V8M16 16v-8`,pie:`M12 3a9 9 0 1 0 9 9h-9z`,trending:`M3 17l6-6 4 4 8-8M15 7h6v6`,dollar:`M12 3v18M16 7.5C16 6 14.2 5 12 5S8 6 8 7.5 9.5 10 12 10.5s4 1.5 4 3-1.8 2.5-4 2.5-4-1-4-2.5`,percent:`M5 19L19 5M7.5 5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM16.5 14a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5z`,truck:`M3 6h11v9H3zM14 9h4l3 3v3h-7zM7.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM17.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3z`,package:`M12 3l8 4v10l-8 4-8-4V7zM4 7l8 4 8-4M12 11v10`,store:`M4 9h16v11H4zM4 9l1.5-5h13L20 9M9 20v-6h6v6`,building:`M5 21V4h9v17M14 9h5v12M8 8h3M8 12h3M8 16h3M17 12h.01M17 16h.01`,users:`M9 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM2 20c0-3.3 3.1-5 7-5s7 1.7 7 5M17 5a4 4 0 0 1 0 7.9M22 20c0-2.6-1.6-4.2-4-4.8`,"thumbs-up":`M7 21V10h3l3-6a2 2 0 0 1 2 2v4h4l-2 11z`,smile:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9 10h.01M15 10h.01M8.5 14.5a5 5 0 0 0 7 0`,help:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9.5 9.5a2.5 2.5 0 1 1 3.5 2.3c-.6.3-1 .9-1 1.7M12 17h.01`,checkbox:`M4 4h16v16H4zM8 12l3 3 5-5`,list:`M8 6h13M8 12h13M8 18h13M3.5 6h.01M3.5 12h.01M3.5 18h.01`,grid:`M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z`,apps:`M4.5 4.5h2v2h-2zM11 4.5h2v2h-2zM17.5 4.5h2v2h-2zM4.5 11h2v2h-2zM11 11h2v2h-2zM17.5 11h2v2h-2zM4.5 17.5h2v2h-2zM11 17.5h2v2h-2zM17.5 17.5h2v2h-2z`,layers:`M12 3l9 5-9 5-9-5zM3 13l9 5 9-5`,zap:`M13 3L5 14h6l-1 7 8-11h-6z`,flame:`M12 21a6 6 0 0 0 6-6c0-4-4-6-4-10 0 0-3 1.5-3 5 0 1.5-1 2-1.5 1.5C8 10 7.5 9 7.5 9A7.5 7.5 0 0 0 6 15a6 6 0 0 0 6 6z`,droplet:`M12 3s6 6.4 6 10.5a6 6 0 0 1-12 0C6 9.4 12 3 12 3z`,leaf:`M4 20c0-8 6-14 16-14 0 10-6 14-12 14H4zM8 16c2-4 5-6 8-7`};function Ai({name:e=`star`,paths:t,fill:n=!1,size:r=24,stroke:i=2,color:a=``,href:o=``,target:s=``,label:c=``,style:l,nodeRef:u,inert:d}){let f=Array.isArray(t)?t.filter(e=>typeof e==`string`&&e.trim()):[],p=n&&f.length>0,m=f.length?f:[ki[e]??ki.star],h=Math.min(Math.max(Number(r)||24,8),240),g=a===`accent`?`var(--page-accent, currentColor)`:a||`currentColor`,_=(0,G.jsx)(`svg`,{...q(`glyph`),viewBox:`0 0 24 24`,width:h,height:h,fill:p?g:`none`,stroke:p?`none`:g,strokeWidth:p?void 0:Math.min(Math.max(Number(i)||2,.5),4),strokeLinecap:p?void 0:`round`,strokeLinejoin:p?void 0:`round`,role:c?`img`:void 0,"aria-label":c||void 0,"aria-hidden":c?void 0:`true`,style:{display:`block`},children:m.map((e,t)=>(0,G.jsx)(`path`,{d:e},t))}),v={display:`inline-flex`,lineHeight:0,...z(l)};return o?(0,G.jsx)(`a`,{ref:u,href:o,onClick:d?e=>e.preventDefault():void 0,target:s||void 0,rel:s===`_blank`?`noopener noreferrer`:void 0,style:{...v,color:`inherit`},children:_}):(0,G.jsx)(`span`,{ref:u,style:v,children:_})}function ji(e,t={},n=0){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],i=e=>e==null?``:rr(e),a=Math.max(0,Number(n)||0),o=[];for(let e of r){let n=e.data??e,r=tr(n,t.imageField),s=(Array.isArray(r)?r:[r]).map(e=>e&&typeof e==`object`?e.url??e.src??``:e).filter(e=>typeof e==`string`&&e.trim()),c=t.nameField?i(tr(n,t.nameField)):i(n.name),l=t.hrefField?i(tr(n,t.hrefField)):``;for(let e of s)if(o.push({src:e,name:c,alt:c,href:l}),a&&o.length>=a)return o}return o}function Mi({images:e=[],source:t=``,entry:n=``,imageField:r=``,nameField:i=``,hrefField:a=``,limit:o=0,emptyText:s=``,columns:c=3,gap:u=8,showNames:d=!1,lightbox:f=!0,style:p,nodeRef:m,inert:h}){let{tenant:g,apiUrl:_,revision:v}=(0,l.useContext)(K),y=(0,l.useContext)(Hn)?.[t],[b,x]=(0,l.useState)(null),[S,C]=(0,l.useState)(()=>new Set);(0,l.useEffect)(()=>{if(!t||y)return;let e=!0;return fetch(`${_}/dynamic/${encodeURIComponent(t)}`,{headers:g?{"x-tenant":g}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&x(n)}).catch(()=>e&&x([])),()=>{e=!1}},[v,t,g,_,y]);let w=y??b??[],T=n?w.filter(e=>e?.id===n||e?.data?.slug===n||e?.slug===n):w,E=Math.max(0,Number(o)||0),D=t?(()=>{let e=ji(T,{imageField:r,nameField:i,hrefField:a},0).filter(e=>!S.has(e.src));return E?e.slice(0,E):e})():null,O=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],k=D??O,A=!!t&&!y&&b===null,j=Math.max(0,Number(u)||0),M=h?e=>e.preventDefault():void 0,[N,P]=(0,l.useState)(null),F=f&&!h&&N!==null&&k[N];(0,l.useEffect)(()=>{if(!F)return;let e=e=>{e.key===`Escape`&&P(null),e.key===`ArrowRight`&&P(e=>(e+1)%k.length),e.key===`ArrowLeft`&&P(e=>(e-1+k.length)%k.length)};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[F,k.length]);let I=e=>{if(typeof e.name==`string`&&e.name.trim())return e.name;if(typeof e.alt==`string`&&e.alt.trim())return e.alt;try{let t=String(e.src).split(`?`)[0].split(`/`).pop();return decodeURIComponent(t??``)}catch{return``}};return(0,G.jsxs)(`div`,{ref:m,style:{columnCount:Math.min(Math.max(Number(c)||3,1),8),columnGap:j,width:`100%`,...z(p)},children:[k.map((e,n)=>{let r=(0,G.jsxs)(`span`,{style:{position:`relative`,display:`block`,borderRadius:`inherit`,overflow:`hidden`},children:[(0,G.jsx)(`img`,{...q(`image`),src:e.src,alt:e.alt??``,onError:t?()=>C(t=>new Set(t).add(e.src)):void 0,style:{width:`100%`,display:`block`,borderRadius:`inherit`}}),d&&I(e)&&(0,G.jsx)(`span`,{...q(`caption`),style:{position:`absolute`,insetInline:0,bottom:0,padding:`14px 10px 8px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.65))`,color:`#fff`,fontSize:12,lineHeight:1.3,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`},children:I(e)})]}),i=e.href?(0,G.jsx)(`a`,{href:e.href,onClick:M,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`,borderRadius:`inherit`},children:r}):f&&!h?(0,G.jsx)(`span`,{role:`button`,tabIndex:0,onClick:()=>P(n),onKeyDown:e=>(e.key===`Enter`||e.key===` `)&&P(n),style:{display:`block`,borderRadius:`inherit`,cursor:`zoom-in`},children:r}):r;return(0,G.jsx)(`div`,{...q(`tile`),style:{breakInside:`avoid`,marginBottom:j,borderRadius:`inherit`,overflow:`hidden`},children:i},n)}),!k.length&&!A&&(0,G.jsx)(`div`,{...q(`empty`),style:{padding:`24px 12px`,fontSize:13,opacity:.55,textAlign:`center`,columnSpan:`all`},children:t?s||`No images yet`:`Pick images in Settings to fill the gallery`}),F&&(0,G.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,onClick:()=>P(null),style:{position:`fixed`,inset:0,zIndex:1400,background:`rgba(0, 0, 0, 0.86)`,display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,padding:24},children:[(0,G.jsx)(`img`,{src:k[N].src,alt:k[N].alt??``,onClick:e=>e.stopPropagation(),style:{maxWidth:`92vw`,maxHeight:`84vh`,borderRadius:8,boxShadow:`0 12px 48px rgba(0,0,0,0.5)`}}),I(k[N])&&(0,G.jsx)(`div`,{style:{color:`#fff`,fontSize:14,marginTop:12,opacity:.85},children:I(k[N])}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:()=>P(null),style:{position:`absolute`,top:16,right:20,background:`transparent`,border:0,color:`#fff`,fontSize:28,lineHeight:1,cursor:`pointer`},children:`×`}),k.length>1&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`button`,{type:`button`,"aria-label":`Previous`,onClick:e=>{e.stopPropagation(),P(e=>(e-1+k.length)%k.length)},style:{position:`absolute`,left:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`‹`}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Next`,onClick:e=>{e.stopPropagation(),P(e=>(e+1)%k.length)},style:{position:`absolute`,right:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`›`})]})]})]})}var Ni=e=>{let t=Array.isArray(e)?e[0]:e;return t&&typeof t==`object`?String(t.url??t.href??t.link??``):t==null?``:String(t)},Pi=e=>String(e??``).trim().toLowerCase().split(/[-_]/)[0];function Fi(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=Pi(t.language),i=n.filter(e=>!t.langField||!r||Pi(rr(e.data?.[t.langField]))===r),a=e=>String(e.data?.slug??e.slug??``),o=e=>{if(!t.parentField)return``;let n=e.data?.[t.parentField],r=Array.isArray(n)?n[0]:n;return r&&typeof r==`object`?String(r.id??r.slug??``):r==null?``:String(r)},s=e=>{let n=Number(t.orderField?rr(e.data?.[t.orderField]):NaN);return Number.isFinite(n)?n:1/0},c=(e,t)=>s(e)-s(t)||a(e).localeCompare(a(t),void 0,{numeric:!0}),l=new Map;for(let e of i)l.set(String(e.id),e),a(e)&&l.set(a(e),e);let u=new Map;for(let e of i){let t=l.get(o(e)),n=t&&t!==e?t.id:``;u.has(n)||u.set(n,[]),u.get(n).push(e)}let d=[];if(t.root===`parent`){let e=t.rootEntry?l.get(String(t.rootEntry)):null;d=e?u.get(e.id)??[]:[]}else{let e=e=>!t.groupField||rr(e.data?.[t.groupField])===String(t.groupValue??``);d=i.filter(t=>{if(!e(t))return!1;let n=l.get(o(t));return!n||n===t||!e(n)})}let f=Math.max(0,Number(t.depth)||0),p=new Set,m=(e,n)=>{if(p.has(e.id))return null;p.add(e.id);let r=f===0||n<f?u.get(e.id)??[]:[];return{key:e.id,label:rr(e.data?.[t.labelField||`name`])||rr(e.data?.name)||`Untitled`,href:Et(t.hrefField?Ni(e.data?.[t.hrefField]):``),icon:t.iconField?rr(e.data?.[t.iconField]).trim():``,children:[...r].sort(c).map(e=>m(e,n+1)).filter(Boolean)}};return[...d].sort(c).map(e=>m(e,1)).filter(Boolean)}var Ii=(e,t)=>{if(!e||!t||!e.startsWith(`/`))return!1;let n=e=>e.length>1?e.replace(/\/+$/,``):e,r=n(e.split(/[?#]/)[0]),i=n(t);return r===i||r.length>1&&i.endsWith(r)&&i.charAt(i.length-r.length-1)===`/`},Li=pr({display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:8,padding:`10px 16px`,color:`inherit`,textDecoration:`none`});function Ri({source:e=``,labelField:t=``,hrefField:n=``,parentField:r=``,orderField:i=``,langField:a=``,root:o=`group`,groupField:s=``,groupValue:c=``,rootEntry:u=``,depth:d=0,expand:f=`current`,toggleOnClick:p=!0,indent:m=16,lines:h=`none`,lineColor:g=``,iconField:_=``,branchIcon:v=``,leafIcon:y=``,toggleIcon:b=`caret`,toggleSize:x=16,dividers:S=`none`,dividerColor:C=``,dividerWidth:w=1,linkColor:T=``,hoverBg:E=``,hoverColor:D=``,currentBg:O=``,currentColor:k=``,placeholder:A=``,style:j,nodeRef:M}){let{tenant:N,apiUrl:P,revision:F,locale:I}=(0,l.useContext)(K),L=(0,l.useContext)(Hn)?.[e],R=Number(m)||0,B=(h===`solid`||h===`dotted`)&&R>=8,ee=B?`1px ${h} ${g||`currentColor`}`:``,V=g?1:.5,H=e=>16+(e-2)*R+6,U=`wb-mt-${(0,l.useId)().replace(/[^a-zA-Z0-9_-]/g,``)}`,te=[`solid`,`dashed`,`dotted`].includes(S)?`${Math.min(Math.max(Number(w)||1,1),8)}px ${S} ${C||`rgba(148, 163, 184, 0.35)`}`:``,ne=[te&&`.${U} [data-wb-part~="link"]{border-top:${te};}.${U} > [data-wb-part~="item"]:first-of-type > [data-wb-part~="link"]{border-top:0;}`,T&&`.${U} a{color:${T} !important;}`,(E||D)&&`.${U} a:hover{${E?`background-color:${E} !important;`:``}${D?`color:${D} !important;`:``}}`,(O||k)&&`.${U} a[aria-current="page"]{${O?`background-color:${O} !important;`:``}${k?`color:${k} !important;`:``}}`].filter(Boolean).join(``),re=e=>{let t=e.icon||(e.children.length>0?v:y);return t?/^(https?:)?\/\/|^\//.test(t)?(0,G.jsx)(`img`,{...q(`icon`),src:t,alt:``,style:{width:18,height:18,objectFit:`contain`,flexShrink:0}}):ki[t]?(0,G.jsx)(`svg`,{...q(`icon`),viewBox:`0 0 24 24`,width:`18`,height:`18`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{flexShrink:0,opacity:.8},children:(0,G.jsx)(`path`,{d:ki[t]})}):null:null},ie=Math.min(Math.max(Number(x)||16,8),40),ae=e=>b===`plus`?(0,G.jsx)(`path`,{d:e?ki.minus:ki.plus}):b===`chevron`?(0,G.jsx)(`path`,{d:ki[`chevron-right`]}):null,[oe,se]=(0,l.useState)(null),[ce,le]=(0,l.useState)(``),[ue,de]=(0,l.useState)({});(0,l.useEffect)(()=>{le(window.location.pathname)},[]),(0,l.useEffect)(()=>{if(!e||L)return;let t=!0,n=new URLSearchParams({all:`1`});return I&&n.set(`locale`,I),fetch(`${P}/dynamic/${encodeURIComponent(e)}?${n}`,{headers:N?{"x-tenant":N}:{}}).then(e=>e.json()).then(e=>{let n=Array.isArray(e?.payload)?e.payload:Array.isArray(e?.payload?.data)?e.payload.data:[];t&&se(n)}).catch(()=>t&&se([])),()=>{t=!1}},[F,e,N,P,I,L]);let fe=(0,l.useMemo)(()=>Fi(L??oe??[],{labelField:t,hrefField:n,parentField:r,orderField:i,langField:a,language:I,root:o,groupField:s,groupValue:c,rootEntry:u,depth:d,iconField:_}),[L,oe,t,n,r,i,a,I,o,s,c,u,d,_]),pe=(0,l.useMemo)(()=>{let e=new Set,t=(n,r)=>n.some(n=>Ii(n.href,ce)?([...r,n.key].forEach(t=>e.add(t)),!0):t(n.children,[...r,n.key]));return t(fe,[]),e},[fe,ce]),me=e=>e.key in ue?ue[e.key]:f===`all`||f===`current`&&pe.has(e.key),he=e=>de(t=>({...t,[e.key]:!me(e)})),ge=(e,t)=>({position:`absolute`,left:H(e),pointerEvents:`none`,opacity:V,borderLeft:ee,...t}),_e=(e,t,n)=>!B||e<2?null:(0,G.jsxs)(G.Fragment,{children:[t.map((e,t)=>e?(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:ge(t+2,{top:0,bottom:0})},t):null),(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:ge(e,n?{top:0,height:`50%`}:{top:0,bottom:0})}),(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:{position:`absolute`,left:H(e),top:`50%`,width:Math.max(4,R-8),pointerEvents:`none`,opacity:V,borderTop:ee}})]}),ve=(e,t,n=[])=>e.map((r,i)=>{let a=r.children.length>0,o=a&&me(r),s=Ii(r.href,ce),c=B&&t>1,l=i===e.length-1;return(0,G.jsxs)(`div`,{...q(`item`,o&&`item-open`),children:[(0,G.jsxs)(`a`,{...q(`link`,s&&`link-current`),href:r.href||`#`,"aria-current":s?`page`:void 0,"aria-expanded":a?o:void 0,onClick:a&&(p||!r.href)?e=>{e.preventDefault(),he(r)}:void 0,style:{...Li,paddingLeft:16+(t-1)*R,fontWeight:s?600:void 0,...c?{position:`relative`}:null},children:[_e(t,n,l),(0,G.jsxs)(`span`,{style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[re(r),(0,G.jsx)(`span`,{...q(`label`),children:r.label})]}),a?(0,G.jsx)(`span`,{role:`button`,tabIndex:-1,"aria-label":o?`Collapse`:`Expand`,onClick:e=>{e.preventDefault(),e.stopPropagation(),he(r)},style:{flexShrink:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,margin:`-8px -8px -8px 0`,padding:8,cursor:`pointer`},children:b===`plus`||b===`chevron`?(0,G.jsx)(`svg`,{...q(`toggle`),viewBox:`0 0 24 24`,width:ie+2,height:ie+2,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{transition:`transform .2s`,transform:b===`chevron`&&o?`rotate(90deg)`:`none`},children:ae(o)}):(0,G.jsx)(`svg`,{...q(`toggle`),viewBox:`0 0 24 24`,width:ie,height:ie,"aria-hidden":!0,style:{transition:`transform .2s`,transform:o?`rotate(180deg)`:`none`},children:(0,G.jsx)(`path`,{d:`M5 8.5h14L12 17z`,fill:`currentColor`})})}):null]}),o?(0,G.jsx)(`div`,{...q(`children`),children:ve(r.children,t+1,t>1?[...n,!l]:n)}):null]},r.key)});return(0,G.jsxs)(`nav`,{ref:M,"aria-label":`Menu`,className:ne?U:void 0,style:{...z(j)},children:[ne?(0,G.jsx)(`style`,{children:ne}):null,fe.length?ve(fe,1):A?(0,G.jsx)(`div`,{...q(`empty`),style:{padding:`10px 16px`,opacity:.6,fontSize:14},children:A}):null]})}var zi={color:`inherit`,textDecoration:`none`,fontSize:14,opacity:.85},Bi=pr({background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.25)`,boxShadow:`0 16px 40px rgba(15, 23, 42, 0.16)`,zIndex:60});function Vi(e,t={},n=`dropdown`){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],i=e=>Array.isArray(e)?e[0]:e,a=e=>e==null?``:rr(e),o=r.map(e=>{let n=e.data??{},r=t.parentField?i(n[t.parentField]):null;return{key:e.id,parent:(r&&typeof r==`object`?r.id:r)||null,label:a(n[t.labelField||`name`])||a(n.name)||`Untitled`,href:t.hrefField?a(n[t.hrefField]):``,image:t.imageField&&i(n[t.imageField])||``,desc:t.descField?a(n[t.descField]):``}}),s=new Map(o.map(e=>[e.key,e])),c=e=>{let t=new Set,n=e;for(;n.parent&&s.has(n.parent)&&!t.has(n.key);)t.add(n.key),n=s.get(n.parent);return n},l=[],u=new Map;for(let e of o){if(c(e)!==e)continue;let t={key:e.key,label:e.label,href:e.href,image:e.image,children:[]};u.set(e.key,t),l.push(t)}for(let e of o){let t=c(e);t!==e&&u.get(t.key)?.children.push({key:e.key,label:e.label,href:e.href,image:e.image,desc:e.desc})}return l.map(e=>({...e,type:e.children.length?n:`link`}))}function Hi({brand:e,logo:t,brandHref:n,brandTarget:r,links:i=[],style:a,nodeRef:o,menu:s=`auto`,breakpoint:c=768,source:u=``,labelField:d=``,hrefField:f=``,imageField:p=``,descField:m=``,parentField:h=``,submenu:g=`dropdown`}){let[_,v]=(0,l.useState)(null),[y,b]=(0,l.useState)(!1),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(null),{tenant:T,apiUrl:E,revision:D,locale:O}=(0,l.useContext)(K),k=at(O),A=(0,l.useId)(),j=(0,l.useContext)(Hn)?.[u],[M,N]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!u||j)return;let e=!0;return fetch(`${E}/dynamic/${encodeURIComponent(u)}`,{headers:T?{"x-tenant":T}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&N(n)}).catch(()=>e&&N([])),()=>{e=!1}},[D,u,T,E,j]),(0,l.useEffect)(()=>{if(!_)return;let e=new ResizeObserver(()=>b(_.offsetWidth<c));return e.observe(_),()=>e.disconnect()},[_,c]);let P=u?Vi(j??M??[],{labelField:d,hrefField:f,imageField:p,descField:m,parentField:h},g):i,F=s===`hamburger`||s===`auto`&&y,I=(e,t,n=!1)=>{let r=e.image?(0,G.jsx)(`img`,{...q(`sublink-image`),src:e.image,alt:``,style:n?{width:`100%`,aspectRatio:`16 / 9`,objectFit:`cover`,borderRadius:6,display:`block`,marginBottom:8}:{width:22,height:22,objectFit:`cover`,borderRadius:4,display:`block`,flexShrink:0}}):null;return(0,G.jsxs)(`a`,{...q(`sublink`,n&&`sublink-card`),href:e.href||`#`,style:{...zi,display:n?`block`:`flex`,alignItems:n?void 0:`center`,gap:n?void 0:10,...t},children:[r,(0,G.jsxs)(`span`,{...q(`sublink-label`),style:{display:`block`,minWidth:0},children:[e.label,e.desc&&(0,G.jsx)(`span`,{...q(`sublink-desc`),style:{display:`block`,fontSize:12,opacity:.6,marginTop:2},children:e.desc})]})]},e.key)};return(0,G.jsxs)(`nav`,{ref:e=>{v(e),o&&o(e)},style:{display:`flex`,alignItems:`center`,gap:24,flexWrap:`wrap`,padding:`14px 24px`,width:`100%`,position:`relative`,...z(a)},children:[(t||e)&&(()=>{let i=(0,G.jsxs)(G.Fragment,{children:[t&&(0,G.jsx)(`img`,{...q(`logo`),src:t,alt:e||`Logo`,style:{height:28,display:`block`}}),e&&(0,G.jsx)(`span`,{...q(`brand-name`),style:{fontWeight:700,fontSize:18,fontFamily:`var(--page-heading-font, inherit)`},children:e})]}),a={display:`flex`,alignItems:`center`,gap:10,color:`inherit`,textDecoration:`none`};return n?(0,G.jsx)(`a`,{...q(`brand`),href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:a,children:i}):(0,G.jsx)(`div`,{...q(`brand`),style:a,children:i})})(),(0,G.jsx)(`div`,{style:{flexGrow:1}}),F?(0,G.jsx)(`button`,{type:`button`,...q(`menu-button`),"aria-label":k(x?`closeMenu`:`openMenu`),"aria-expanded":x,"aria-controls":x?`${A}-menu`:void 0,onClick:()=>S(!x),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4},children:x?`✕`:`☰`}):(0,G.jsx)(`div`,{...q(`links`),style:{display:`flex`,gap:20,alignItems:`center`,flexWrap:`wrap`},children:P.map(e=>{let t=e.children??[];if(!t.length)return(0,G.jsx)(`a`,{...q(`link`),href:e.href||`#`,style:zi,children:e.label},e.key);let n=e.type===`mega`,r=`${A}-${e.key}`;return(0,G.jsxs)(`span`,{style:{position:n?`static`:`relative`,display:`inline-flex`},onMouseEnter:()=>w(e.key),onMouseLeave:()=>w(null),onFocus:t=>{t.currentTarget.contains(t.relatedTarget)||w(e.key)},onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||w(null)},onKeyDown:t=>{let n=t.currentTarget;t.key===`Escape`&&C===e.key?(t.stopPropagation(),w(null),n.querySelector(`a`)?.focus()):t.key===`ArrowDown`&&C!==e.key&&(t.preventDefault(),w(e.key),setTimeout(()=>n.querySelectorAll(`a`)[1]?.focus(),0))},children:[(0,G.jsxs)(`a`,{...q(`link`),href:e.href||`#`,"aria-haspopup":`true`,"aria-expanded":C===e.key,"aria-controls":C===e.key?r:void 0,style:{...zi,cursor:`pointer`},children:[e.label,` `,(0,G.jsx)(`span`,{...q(`chevron`),"aria-hidden":`true`,style:{fontSize:9,opacity:.6},children:`▼`})]}),C===e.key&&(n?(0,G.jsx)(`div`,{id:r,...q(`mega-panel`),style:{...Bi,position:`absolute`,left:0,right:0,top:`100%`,padding:24,display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(170px, 1fr))`,gap:16},children:t.map(e=>I(e,{padding:8,borderRadius:8},!0))}):(0,G.jsx)(`div`,{id:r,...q(`dropdown-panel`),style:{...Bi,position:`absolute`,top:`100%`,left:0,minWidth:190,borderRadius:8,padding:8,display:`flex`,flexDirection:`column`},children:t.map(e=>I(e,{padding:`8px 12px`,borderRadius:6}))}))]},e.key)})}),F&&x&&(0,G.jsx)(`div`,{id:`${A}-menu`,...q(`mobile-menu`),style:{flexBasis:`100%`,width:`100%`,display:`flex`,flexDirection:`column`,paddingTop:10},children:P.map(e=>(0,G.jsxs)(l.Fragment,{children:[(0,G.jsx)(`a`,{...q(`mobile-link`),href:e.href||`#`,style:{...zi,padding:`10px 4px`,fontWeight:(e.children??[]).length?600:400,opacity:1},children:e.label}),(e.children??[]).map(e=>I(e,{padding:`8px 4px 8px 22px`}))]},e.key))})]})}function Ui({tabs:e=[],linked:t,style:n,nodeRef:r}){let[i,a]=(0,l.useState)(0),{locale:o}=(0,l.useContext)(K),s=(0,l.useId)(),c=(0,l.useRef)(null),u=e.length?Math.min(i,e.length-1):0;if(!e.length)return null;let d=at(o),f=t=>{let n=e.length-1,r={ArrowRight:(u+1)%e.length,ArrowLeft:(u-1+e.length)%e.length,Home:0,End:n}[t.key];r!==void 0&&(t.preventDefault(),a(r),c.current?.querySelectorAll(`[role="tab"]`)[r]?.focus())};return(0,G.jsxs)(`div`,{ref:r,style:{width:`100%`,...z(n)},children:[(0,G.jsx)(`div`,{ref:c,role:`tablist`,...q(`tab-list`),onKeyDown:f,style:{display:`flex`,gap:4,borderBottom:`1px solid rgba(148, 163, 184, 0.35)`},children:e.map((e,t)=>(0,G.jsx)(`button`,{...q(`tab`,t===u&&`tab-active`),type:`button`,role:`tab`,id:`${s}-tab-${e.key}`,"aria-selected":t===u,"aria-controls":`${s}-panel-${e.key}`,tabIndex:t===u?0:-1,onClick:()=>a(t),style:{background:`transparent`,border:0,padding:`10px 16px`,fontSize:14,fontFamily:`inherit`,color:`inherit`,cursor:`pointer`,opacity:t===u?1:.6,fontWeight:t===u?600:500,boxShadow:t===u?`inset 0 -2px 0 var(--page-accent, #111827)`:`none`},children:e.label||d(`tab`,{n:t+1})},e.key))}),e.map((e,n)=>(0,G.jsx)(`div`,{...q(`panel`),role:`tabpanel`,id:`${s}-panel-${e.key}`,"aria-labelledby":`${s}-tab-${e.key}`,tabIndex:0,hidden:n!==u,style:{display:n===u?`flex`:`none`,flexDirection:`column`},children:t?.[e.key]??null},e.key))]})}function Wi({items:e=[],linked:t,multiple:n=!1,icon:r=``,padX:i,padY:a,headerBg:o,headerColor:s,openBg:c,openColor:u,borderColor:d,style:f,nodeRef:p}){let[m,h]=(0,l.useState)(()=>new Set(e.length?[e[0].key]:[])),{locale:g}=(0,l.useContext)(K),_=(0,l.useId)();if(!e.length)return null;let v=at(g),y=(e,t)=>typeof e==`string`&&e?e:t,b=(e,t)=>{let n=Number(e);return e===``||e==null||!Number.isFinite(n)?t:n},x=ki[r],S=e=>h(t=>{let r=new Set(n?t:[]);return t.has(e)?r.delete(e):r.add(e),r});return(0,G.jsx)(`div`,{ref:p,style:{width:`100%`,...z(f)},children:e.map((n,r)=>{let l=m.has(n.key);return(0,G.jsxs)(`div`,{...q(`item`,l&&`item-open`),style:{borderBottom:r<e.length-1?`1px solid ${y(d,`rgba(148, 163, 184, 0.35)`)}`:`none`},children:[(0,G.jsxs)(`button`,{type:`button`,...q(`header`,l&&`header-open`),id:`${_}-h-${n.key}`,"aria-expanded":l,"aria-controls":`${_}-b-${n.key}`,onClick:()=>S(n.key),style:{width:`100%`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:12,background:l?y(c,y(o,`transparent`)):y(o,`transparent`),border:0,padding:`${b(a,14)}px ${b(i,4)}px`,fontSize:15,fontWeight:600,fontFamily:`inherit`,color:l?y(u,y(s,`inherit`)):y(s,`inherit`),textAlign:`left`,cursor:`pointer`,transition:`background 180ms, color 180ms`},children:[(0,G.jsxs)(`span`,{...q(`title`),style:{display:`flex`,alignItems:`center`,gap:10,minWidth:0},children:[x?(0,G.jsx)(`svg`,{...q(`icon`),viewBox:`0 0 24 24`,width:16,height:16,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,style:{flexShrink:0},children:(0,G.jsx)(`path`,{d:x})}):null,n.title||v(`item`,{n:r+1})]}),(0,G.jsx)(`span`,{"aria-hidden":`true`,...q(`chevron`),style:{fontSize:12,opacity:.6,transform:l?`rotate(180deg)`:`none`,transition:`transform 180ms`},children:`▼`})]}),(0,G.jsx)(`div`,{...q(`body`),id:`${_}-b-${n.key}`,role:`region`,"aria-labelledby":`${_}-h-${n.key}`,hidden:!l,style:{display:l?`flex`:`none`,flexDirection:`column`},children:t?.[n.key]??null})]},n.key)})})}var Gi={display:`flex`,flexDirection:`column`,gap:`12px`},Ki={fontSize:`14px`,fontWeight:500,color:`var(--page-text, #111827)`},qi=pr({padding:`10px 12px`,border:`1px solid var(--page-border, #d1d5db)`,borderRadius:`6px`,fontSize:`14px`,fontFamily:`inherit`,width:`100%`,boxSizing:`border-box`,backgroundColor:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`}),Ji={display:`flex`,alignItems:`center`,gap:`8px`,fontSize:`14px`,color:`var(--page-text, #111827)`},Yi=e=>e?{readOnly:!0,tabIndex:-1,onMouseDown:e=>e.preventDefault()}:{};function Xi(e,t){if(!e)return!0;let n=t[e.field],r=n==null||n===``?``:String(n),i=e.value??``;switch(e.op){case`eq`:return r===i;case`neq`:return r!==i;case`contains`:return r.toLowerCase().includes(i.toLowerCase());case`gt`:return Number(r)>Number(i);case`lt`:return Number(r)<Number(i);case`empty`:return r===``;case`notEmpty`:return r!==``;default:return!1}}var Zi={display:`flex`,flexDirection:`column`,gap:6},Qi=`#dc2626`,$i={fontSize:13,fontWeight:500,color:Qi},ea=pr({font:`inherit`,fontSize:15,padding:`10px 12px`,borderRadius:8,border:`1px solid rgba(148, 163, 184, 0.55)`,background:`transparent`,color:`inherit`,width:`100%`,boxSizing:`border-box`});function ta(e,t){let n=Array.isArray(e?.options)?e.options:[];if(!e?.parentField)return n;let r=t?.[e.parentField];return r?n.filter(e=>typeof e==`string`?!1:!e.parent||e.parent===r):[]}var na=`g-recaptcha-response`,ra=e=>e?.type===`recaptcha`?na:e?.name,ia=[[/^(full_?name|name|ad_?soyad|adsoyad|isim)$/,`name`],[/^(first_?name|given_?name|ad|adi|adiniz)$/,`given-name`],[/^(last_?name|family_?name|surname|soyad|soyadi|soyadiniz)$/,`family-name`],[/^(e_?mail|e_?posta|eposta|mail)$/,`email`],[/^(phone|tel|telephone|mobile|gsm|telefon|cep)$/,`tel`],[/^(company|organization|organisation|firma|sirket|kurum)$/,`organization`],[/^(address|street|adres|sokak)$/,`street-address`],[/^(city|town|sehir|il)$/,`address-level2`],[/^(district|ilce)$/,`address-level3`],[/^(zip|zip_?code|postal_?code|postcode|posta_?kodu)$/,`postal-code`],[/^(country|ulke)$/,`country-name`],[/^(website|web|url|site)$/,`url`]];function aa(e){if(typeof e.autocomplete==`string`&&e.autocomplete)return e.autocomplete;let t={email:`email`,phone:`tel`,link:`url`}[e.type];if(t)return t;let n=String(e.name??``).toLowerCase();return ia.find(([e])=>e.test(n))?.[1]}function oa({field:e,value:t,onChange:n,inert:r,values:i,error:a,idBase:o}){let s=at((0,l.useContext)(K).locale),c=`${o}-${e.name}`,u=e.help?`${c}-help`:null,d=a?`${c}-error`:null,f=(0,G.jsxs)(`label`,{...q(`label`),htmlFor:c,style:{...Ki,fontSize:14},children:[e.label,e.required?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,children:` *`}),(0,G.jsxs)(`span`,{style:ot,children:[` (`,s(`required`),`)`]})]}):null]}),p=[u,d].filter(Boolean).join(` `)||void 0,m={id:c,"aria-invalid":a?!0:void 0,"aria-describedby":p},h={...q(`input`),...m,name:e.name,required:e.required||void 0,placeholder:e.placeholder||void 0,disabled:r||void 0,autoComplete:aa(e),style:a?{...ea,borderTopColor:Qi,borderRightColor:Qi,borderBottomColor:Qi,borderLeftColor:Qi}:ea,value:t??``,onChange:t=>n(e.name,t.target.value)};return e.type===`display`?(0,G.jsx)(e.variant&&e.variant!==`p`?e.variant:`p`,{...q(`text`),style:{margin:0,color:e.color||`inherit`,fontSize:{h1:32,h2:26,h3:21,h4:18,h5:16,h6:14,p:15}[e.variant]??16,fontWeight:e.variant===`p`?400:700,lineHeight:1.35},children:e.label}):e.type===`image`?e.src?(0,G.jsx)(`img`,{...q(`image`),src:e.src,alt:e.label??``,style:{width:`100%`,borderRadius:8,display:`block`}}):null:e.type===`recaptcha`?(0,G.jsxs)(`div`,{...q(`field`),id:c,tabIndex:-1,style:Zi,children:[(0,G.jsx)(pa,{theme:e.captchaTheme,size:e.captchaSize,inert:r,onChange:e=>n(na,e)}),a&&(0,G.jsx)(`span`,{...q(`error`),id:d,style:$i,children:a})]}):e.type===`video`?e.src?/youtube\.com|youtu\.be|vimeo\.com/i.test(e.src)?(0,G.jsx)(ni,{url:e.src,style:{width:`100%`}}):(0,G.jsx)(`video`,{...q(`video`),src:e.src,controls:!0,style:{width:`100%`,borderRadius:8,display:`block`}}):null:(0,G.jsxs)(`div`,{...q(`field`),style:Zi,children:[f,e.type===`textarea`||e.multiline?(0,G.jsx)(`textarea`,{...h,...q(`textarea`),rows:4,style:{...ea,resize:`vertical`}}):e.type===`select`?(0,G.jsxs)(`select`,{...h,...q(`select`),disabled:h.disabled||!!e.parentField&&!i?.[e.parentField],children:[(0,G.jsx)(`option`,{value:``,children:e.placeholder||`—`}),ta(e,i).map((e,t)=>(0,G.jsx)(`option`,{value:typeof e==`string`?e:e.value,children:typeof e==`string`?e:e.label??e.value},t))]}):e.type===`checkbox`?(0,G.jsx)(`input`,{type:`checkbox`,...q(`checkbox`),...m,name:e.name,required:e.required||void 0,disabled:r||void 0,checked:!!t,onChange:t=>n(e.name,t.target.checked),style:{width:18,height:18}}):e.type===`upload`?(0,G.jsx)(`input`,{type:`file`,...q(`file`),...m,name:e.name,accept:e.accept||void 0,required:e.required||void 0,disabled:r||void 0,onChange:t=>n(e.name,t.target.files?.[0]?.name??``),style:{font:`inherit`,fontSize:14}}):(0,G.jsx)(`input`,{...h,type:{email:`email`,number:`number`,date:`date`,datetime:`datetime-local`,phone:`tel`,link:`url`}[e.type]??`text`}),e.help&&(0,G.jsx)(`span`,{...q(`help`),id:u,style:{fontSize:12,opacity:.65},children:e.help}),a&&(0,G.jsx)(`span`,{...q(`error`),id:d,style:$i,children:a})]})}function sa(e,t){if(!e||typeof e!=`object`)return e;let n=String(t??``).split(`-`)[0].toLowerCase(),r=(t,r)=>{let i=e[t]&&typeof e[t]==`object`?e[t][n]:null;return typeof i==`string`&&i.trim()?i:r};return{...e,label:r(`labels`,e.label),help:r(`helps`,e.help),placeholder:r(`placeholders`,e.placeholder),prefix:r(`prefixes`,e.prefix),suffix:r(`suffixes`,e.suffix),errorMessage:r(`errorMessages`,e.errorMessage)}}var ca=(e,t)=>typeof e?.errorMessage==`string`&&e.errorMessage.trim()?e.errorMessage:t;function la({style:e,action:t,method:n,name:r,enctype:i,formSlug:a,auto:o,submitLabel:s,nodeRef:c,inert:u,children:d,linked:f,show:p}){let{tenant:m,apiUrl:h,locale:g}=(0,l.useContext)(K),[_,v]=(0,l.useState)(`form`),[y,b]=(0,l.useState)(null),[x,S]=(0,l.useState)({}),[C,w]=(0,l.useState)(0),[T,E]=(0,l.useState)({}),[D,O]=(0,l.useState)(``),k=(0,l.useId)(),A=(0,l.useRef)(null),j=(0,l.useRef)(null),M=u?p||`form`:_,N=at(g);(0,l.useEffect)(()=>{if(!o||!a)return;let e=!0;return fetch(`${h||`/api`}/forms/${encodeURIComponent(a)}`,{headers:m?{"x-tenant":m}:{}}).then(e=>e.json()).then(t=>e&&b(t?.payload&&typeof t.payload==`object`?t.payload:null)).catch(()=>e&&b(null)),()=>{e=!1}},[o,a,m,h]);let P=[{section:null,fields:[]}];for(let e of(Array.isArray(y?.fields)?y.fields:[]).map(e=>sa(e,g)))e.type===`section`?P.push({section:e,fields:[]}):P[P.length-1].fields.push(e);let F=P.filter(e=>e.section||e.fields.length),I=F.filter(e=>!e.section||Xi(e.section.condition,x)).map(e=>({...e,fields:e.fields.filter(e=>Xi(e.condition,x))})),L=F.length>1,R=Math.min(C,Math.max(0,I.length-1)),B=L?I[R]?.fields??[]:I.flatMap(e=>e.fields),ee=B.filter(e=>{let t=x[ra(e)];return e.required&&(t==null||t===``||t===!1)}),V=R>=I.length-1,H=(e,t)=>{E(t=>{let n=e===`g-recaptcha-response`?(Array.isArray(y?.fields)?y.fields:[]).find(e=>e?.type===`recaptcha`)?.name:e;if(!n||!t[n])return t;let r={...t};return delete r[n],r}),S(n=>{let r={...n,[e]:t};for(let t of Array.isArray(y?.fields)?y.fields:[])t?.parentField===e&&delete r[t.name];return r})},U=()=>{let e={};for(let t of B){if(t.type===`recaptcha`){t.required&&!x[`g-recaptcha-response`]&&(e[t.name]=ca(t,N(`fieldRequired`)));continue}let n=A.current?.querySelector(`[name="${CSS.escape(String(t.name??``))}"]`);!n?.validity||n.validity.valid||(e[t.name]=ca(t,n.validity.valueMissing?N(`fieldRequired`):n.validationMessage||N(`invalid`)))}E(e);let t=B.find(t=>e[t.name]);return t&&setTimeout(()=>document.getElementById(`${k}-${t.name}`)?.focus(),0),!t},te=e=>{v(e),O(N(e===`success`?`submitted`:`submitFailed`)),e===`success`&&setTimeout(()=>j.current?.focus(),0)};return(0,G.jsxs)(`div`,{ref:c,style:z(e),children:[(0,G.jsx)(`form`,{ref:A,action:t||void 0,method:n||`post`,name:r||void 0,encType:i||void 0,noValidate:o&&a?!0:void 0,onSubmit:async e=>{if(e.preventDefault(),!u&&!(o&&a&&!U())){if(a){let t={};if(o)for(let[e,n]of Object.entries(x))n!=null&&n!==``&&(t[e]=n);else for(let[n,r]of new FormData(e.currentTarget).entries())typeof r==`string`&&(t[n]=r===`on`||r);try{let e=await fetch(`${h||`/api`}/forms/${a}/submit`,{method:`post`,headers:{"content-type":`application/json`,...m?{"x-tenant":m}:{}},body:JSON.stringify(t)}),n=await e.json().catch(()=>null),r=n?.error,i=r?.details?.field;if(o&&typeof i==`string`&&B.some(e=>e.name===i)){E({[i]:ca(B.find(e=>e.name===i),typeof r.message==`string`&&r.message||N(`invalid`))}),O(N(`submitFailed`)),setTimeout(()=>document.getElementById(`${k}-${i}`)?.focus(),0);return}te(e.ok&&n?.success!==!1?`success`:`error`)}catch{te(`error`)}return}if(!t){te(`success`);return}try{let r=await fetch(t,{method:n||`post`,body:new FormData(e.currentTarget)});te(r.ok?`success`:`error`)}catch{te(`error`)}}},style:{...Gi,display:M===`success`?`none`:`flex`},children:o&&a?(0,G.jsxs)(G.Fragment,{children:[L&&(0,G.jsx)(Ga,{steps:I.map(e=>({label:e.section?.label??N(`start`)})),active:R+1,style:{marginBottom:8}}),L&&I[R]?.section?.help&&(0,G.jsx)(`p`,{...q(`step-help`),style:{margin:0,fontSize:14,opacity:.7},children:I[R].section.help}),B.some(e=>e.required)&&(0,G.jsx)(`p`,{...q(`required-note`),style:{margin:0,fontSize:13,opacity:.7},children:N(`requiredNote`)}),B.map(e=>(0,G.jsx)(oa,{field:e,value:x[ra(e)],values:x,onChange:H,inert:u,error:T[e.name],idBase:k},e.name)),(0,G.jsxs)(`div`,{...q(`actions`),style:{display:`flex`,gap:10,alignItems:`center`,marginTop:4},children:[L&&R>0&&(0,G.jsx)(`button`,{type:`button`,...q(`back-button`),disabled:u||void 0,onClick:()=>{E({}),w(R-1)},style:{...vr,background:`transparent`,color:`inherit`,border:0,padding:`10px 16px`,cursor:`pointer`},children:N(`back`)}),L&&!V?(0,G.jsx)(`button`,{type:`button`,...q(`next-button`),disabled:u||void 0,onClick:()=>{U()&&w(R+1)},style:{...vr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:ee.length?.75:1},children:N(`next`)}):(0,G.jsx)(`button`,{type:`submit`,...q(`submit-button`),disabled:u||void 0,style:{...vr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`},children:s||N(`submit`)})]})]}):d}),(0,G.jsx)(`div`,{ref:j,tabIndex:-1,style:{display:M===`success`?`block`:`none`,outline:`none`},children:f?.success??null}),(0,G.jsx)(`div`,{style:{display:M===`error`?`block`:`none`,marginTop:12},children:f?.error??null}),!u&&(0,G.jsx)(`div`,{role:`status`,"aria-live":`polite`,style:ot,children:D})]})}var ua=null,da=null,fa=e=>{let t=typeof e==`string`&&e.trim()?e.trim():``;if(ua&&da===t)return ua;if(ua&&typeof window<`u`){for(let e of[`grecaptcha`,`___grecaptcha_cfg`])try{delete window[e]}catch{window[e]=void 0}document.querySelectorAll(`script[src*="recaptcha"]`).forEach(e=>e.remove())}return da=t,ua=new Promise(e=>{if(typeof window>`u`)return;if(window.grecaptcha?.render)return e(window.grecaptcha);window.__webimRecaptchaReady=()=>e(window.grecaptcha);let n=document.createElement(`script`);n.src=`https://www.google.com/recaptcha/api.js?onload=__webimRecaptchaReady&render=explicit${t?`&hl=${encodeURIComponent(t)}`:``}`,n.async=!0,document.head.appendChild(n)}),ua};function pa({siteKey:e,theme:t,size:n,hl:r,style:i,nodeRef:a,inert:o,onChange:s}){let c=(0,l.useContext)(K),u=c?.settings&&typeof c.settings==`object`?c.settings[`google.recaptchaKey`]:``,d=typeof e==`string`&&e.trim()||(typeof u==`string`?u.trim():``),f=(0,l.useRef)(null),p=(0,l.useRef)(s);if(p.current=s,(0,l.useEffect)(()=>{if(o||!d||!f.current)return;let e=!0,i=t=>{e&&typeof p.current==`function`&&p.current(t)};return fa(r).then(r=>{if(!(!e||!f.current||!r?.render)){f.current.innerHTML=``,i(``);try{r.render(f.current,{sitekey:d,theme:t===`dark`?`dark`:`light`,size:n===`compact`?`compact`:`normal`,callback:e=>i(typeof e==`string`?e:``),"expired-callback":()=>i(``),"error-callback":()=>i(``)})}catch{}}}),()=>{e=!1}},[o,d,t,n,r]),o){let e=t===`dark`;return(0,G.jsxs)(`div`,{ref:a,style:z(i),children:[(0,G.jsxs)(`div`,{style:{width:n===`compact`?164:302,boxSizing:`border-box`,padding:`12px 14px`,display:`flex`,alignItems:`center`,gap:12,borderRadius:4,border:`1px solid ${e?`#52565b`:`#d3d3d3`}`,background:e?`#222528`:`#f9f9f9`,color:e?`#f1f1f1`:`#282828`,fontSize:14,fontFamily:`Roboto, Arial, sans-serif`},children:[(0,G.jsx)(`span`,{style:{width:24,height:24,flexShrink:0,borderRadius:3,border:`2px solid ${e?`#8a8f94`:`#c1c1c1`}`,background:e?`#2f3337`:`#fff`}}),(0,G.jsx)(`span`,{style:{flexGrow:1},children:`I'm not a robot`}),(0,G.jsx)(`span`,{style:{fontSize:9,opacity:.6,textAlign:`center`,lineHeight:1.3},children:`reCAPTCHA`})]}),!d&&(0,G.jsx)(`div`,{style:{marginTop:6,fontSize:11,color:`#b45309`},children:`Set the google.recaptchaKey tenant setting (or a site key in Settings) to activate it.`})]})}return d?(0,G.jsx)(`div`,{ref:a,style:z(i),children:(0,G.jsx)(`div`,{ref:f})}):null}var ma=e=>typeof e==`string`&&e.trim()?`wb-field-${e.trim()}`:void 0;function ha({text:e,parts:t,htmlFor:n,style:r,nodeRef:i,linked:a}){return(0,G.jsx)(`label`,{ref:i,htmlFor:n||void 0,style:{...Ki,...z(r)},children:jr(t,e,a)})}function ga({type:e=`text`,name:t,placeholder:n,required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsx)(`input`,{ref:a,id:ma(t),type:e,name:t||void 0,autoComplete:aa({name:t,type:{email:`email`,tel:`phone`,url:`link`}[e]}),placeholder:n,required:!o&&!!r,style:{...qi,...z(i)},...Yi(o)})}function _a({name:e,placeholder:t,rows:n=4,required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsx)(`textarea`,{ref:a,id:ma(e),name:e||void 0,placeholder:t,rows:n,required:!o&&!!r,style:{...qi,resize:`vertical`,...z(i)},...Yi(o)})}function va({kind:e=`checkbox`,label:t,name:n,value:r,required:i,style:a,nodeRef:o,inert:s}){return(0,G.jsxs)(`label`,{ref:o,style:{...Ji,...z(a)},children:[(0,G.jsx)(`input`,{type:e,...q(`control`),name:n||void 0,value:r||void 0,required:!s&&!!i,onClick:s?e=>e.preventDefault():void 0,tabIndex:s?-1:void 0,style:{margin:0,accentColor:`var(--page-accent, #111827)`}}),t]})}function ya({name:e,placeholder:t,options:n=[],required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsxs)(`select`,{ref:a,id:ma(e),name:e||void 0,autoComplete:aa({name:e}),required:!o&&!!r,defaultValue:``,onMouseDown:o?e=>e.preventDefault():void 0,tabIndex:o?-1:void 0,style:{...qi,appearance:`auto`,...z(i)},children:[t!==``&&(0,G.jsx)(`option`,{value:``,disabled:!0,children:t??`Select…`}),n.map((e,t)=>(0,G.jsx)(`option`,{value:e,children:e},t))]})}function ba({name:e,accept:t,required:n,text:r=`Choose a file…`,style:i,nodeRef:a,inert:o}){let[s,c]=(0,l.useState)(null);return(0,G.jsxs)(`label`,{ref:a,className:`wb-file`,style:{...qi,display:`flex`,alignItems:`center`,gap:`8px`,cursor:o?`default`:`pointer`,borderStyle:`dashed`,color:s?`#111827`:`#6b7280`,...z(i)},children:[(0,G.jsx)(`input`,{type:`file`,name:e||void 0,accept:t||void 0,required:!o&&!!n,disabled:!!o,onChange:e=>c(e.target.files?.[0]?.name??null),style:ot}),(0,G.jsx)(`span`,{"aria-hidden":!0,...q(`icon`),children:`📎`}),s??r]})}function xa({legend:e=``,style:t,nodeRef:n,children:r}){return(0,G.jsxs)(`fieldset`,{ref:n,style:{...pr({border:`0 none`,margin:`0`,padding:`0`}),minWidth:0,display:`flex`,flexDirection:`column`,gap:`10px`,...z(t)},children:[typeof e==`string`&&e.trim()?(0,G.jsx)(`legend`,{...q(`legend`),style:{...Ki,padding:0,marginBottom:6},children:e}):null,r]})}function Sa({text:e=`Submit`,style:t,nodeRef:n,inert:r}){return(0,G.jsx)(`button`,{ref:n,type:r?`button`:`submit`,style:{...vr,border:0,cursor:`pointer`,alignSelf:`flex-start`,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,lineHeight:1.4,fontFamily:`inherit`,...z(t)},children:e})}function Ca({cols:e=2,rows:t=1,style:n,nodeRef:r,linked:i}){let a=Math.max(1,(Number(e)||1)*(Number(t)||1));return(0,G.jsx)(`div`,{ref:r,style:{display:`grid`,gridTemplateColumns:`repeat(${Math.max(1,Number(e)||1)}, minmax(0, 1fr))`,gap:16,width:`100%`,...z(n)},children:Array.from({length:a},(e,t)=>(0,G.jsx)(`div`,{style:{minWidth:0},children:i?.[`cell-${t}`]??null},t))})}function wa(e,t){if(e===``||e==null)return t;let n=Number(e);return Number.isFinite(n)&&n>=0?n:t}function Ta({collection:e,limit:t=6,layout:n=`grid`,columns:r=3,imageField:i,titleField:a=`name`,textField:o,custom:s,templateId:c,renderTemplate:u,paged:d,filters:f,parentField:p,topLevel:m,childrenOf:h,itemsOf:g,gap:_,style:v,nodeRef:y}){let{tenant:b,apiUrl:x,revision:S,locale:C}=(0,l.useContext)(K),w=(0,l.useContext)(Kn),T=(0,l.useContext)(Hn),E=(0,l.useContext)(qn),D=typeof g==`string`&&g?g:null,O=Co(D?vo(tr(E?.entry?.data,D)):null),k=h||D?null:e,A=!!p&&!h&&!D,[,j]=(0,l.useState)(0);(0,l.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>j(e=>e+1);return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]);let M=Gn(f),N=JSON.stringify(M),P=N!==`{}`&&!k?.startsWith?.(`api:`),F=P||!k?null:T?.[k],I=d?Un(T):1,[L,R]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!k||F)return;let e=!0,n=k,r=new URLSearchParams;if(C&&r.set(`locale`,C),P&&r.set(`data_filter`,N),A&&!n.startsWith(`api:`))r.set(`all`,`1`);else if(d&&!n.startsWith(`api:`)){let e=Math.max(1,Number(t)||6);r.set(`offset`,String((I-1)*e)),r.set(`limit`,String(e))}let i=r.toString(),a=n.startsWith(`api:`)?`${x}/data/${encodeURIComponent(n.slice(4))}`:`${x}/dynamic/${encodeURIComponent(n)}${i?`?${i}`:``}`;return fetch(a,{headers:b?{"x-tenant":b}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&R(n.filter(e=>e&&typeof e==`object`))}).catch(()=>e&&R([])),()=>{e=!1}},[S,k,b,x,C,F,d,I,t,P,N,A]),!k&&!h&&!D)return null;let B=Math.max(1,Number(t)||6),ee=D?[]:h?E?.all??[]:F??L??[],V=D?null:h?E?.parentField:p,H=D?null:h?E?.collection:k,U=D?Xn(E?.entry,D,O):h?Yn(ee,V,E?.entry):A&&m?ee.filter(e=>Jn(e,p).length===0):ee,te=d&&(F||h||D||A||k.startsWith(`api:`))?U.slice((I-1)*B,I*B):U.slice(0,B),ne=Math.min(Math.max(Number(r)||3,1),6),re=n===`list`?{display:`flex`,flexDirection:`column`,gap:wa(_,20)}:{display:`grid`,gridTemplateColumns:`repeat(${ne}, minmax(0, 1fr))`,gap:wa(_,24)},ie=u??(c&&w?.render?e=>w.render(c,e):null);return s&&ie?(0,G.jsx)(`div`,{ref:y,style:{width:`100%`,...re,...z(v)},children:te.map(e=>(0,G.jsx)(`div`,{style:{minWidth:0},children:(0,G.jsx)(qn.Provider,{value:{entry:e,all:ee,parentField:V,collection:H},children:ie(t=>ur(t,e,C))})},e.id??e?.data?.slug))}):(0,G.jsx)(`div`,{ref:y,style:{width:`100%`,...re,...z(v)},children:te.map(e=>{let t=i?tr(e?.data,i):null,r=Array.isArray(t)?t[0]:t,s=typeof r==`string`?r:typeof r?.url==`string`?r.url:null,c=a?rr(tr(e?.data,a)):null,l=o?tr(e?.data,o):null,u=Array.isArray(l)?l:null,d=u||l==null?null:rr(l),f=n===`list`;return(0,G.jsxs)(`div`,{...q(`card`),style:{display:`flex`,flexDirection:f?`row`:`column`,gap:f?20:12,alignItems:f?`center`:`stretch`,minWidth:0},children:[s&&(0,G.jsx)(`img`,{...q(`image`),src:s,alt:c??``,style:{width:f?160:`100%`,aspectRatio:`3 / 2`,objectFit:`cover`,borderRadius:10,flexShrink:0,display:`block`}}),(0,G.jsxs)(`div`,{...q(`body`),style:{minWidth:0},children:[c&&(0,G.jsx)(`h3`,{...q(`title`),style:{margin:0,fontSize:18,fontWeight:700},children:c}),d&&(0,G.jsx)(`p`,{...q(`text`),style:{margin:`6px 0 0`,fontSize:14,lineHeight:1.55,opacity:.75},children:d}),u&&(0,G.jsx)(`div`,{...q(`text`),style:{marginTop:6,fontSize:14,lineHeight:1.55,opacity:.85},children:Br(u)})]})]},e.id??e?.data?.slug)})})}function Ea({fields:e=[],buttonLabel:t=`Search`,style:n,nodeRef:r,inert:i}){let a=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&typeof e.name==`string`&&e.name):[],o=i?{}:Wn(),s={height:34,padding:`0 12px`,borderRadius:8,border:`1px solid var(--page-border, rgba(100, 116, 139, 0.4))`,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,fontSize:13,fontFamily:`inherit`,outline:`none`,minWidth:140,flex:`0 1 auto`,boxSizing:`border-box`},c=e=>{let t=e&&typeof e==`object`?e.value:e,n=e&&typeof e==`object`?e.label??e.value:e;return{value:String(t??``),label:String(n??``)}};return(0,G.jsxs)(`form`,{ref:r,method:`get`,onSubmit:e=>{if(i){e.preventDefault();return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);for(let e of[...t.keys()])(e.startsWith(`f_`)||e===`page`)&&t.delete(e);for(let[n,r]of new FormData(e.currentTarget).entries())n.startsWith(`f_`)&&typeof r==`string`&&r.trim()!==``&&t.set(n,r);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`))},style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,width:`100%`,...z(n)},children:[a.map(e=>Array.isArray(e.options)&&e.options.length>0||e.type===`option`||e.type===`select`?(0,G.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...q(`select`),style:s,...Yi(i),children:[(0,G.jsx)(`option`,{value:``,children:e.label||e.name}),(Array.isArray(e.options)?e.options:[]).map(e=>{let t=c(e);return(0,G.jsx)(`option`,{value:t.value,children:t.label},t.value)})]},e.name):e.type===`switch`?(0,G.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...q(`select`),style:s,...Yi(i),children:[(0,G.jsx)(`option`,{value:``,children:e.label||e.name}),(0,G.jsx)(`option`,{value:`true`,children:`Yes`}),(0,G.jsx)(`option`,{value:`false`,children:`No`})]},e.name):(0,G.jsx)(`input`,{type:`text`,name:`f_${e.name}`,defaultValue:o[e.name]??``,placeholder:e.label||e.name,...q(`input`),style:s,...Yi(i)},e.name)),(0,G.jsx)(`button`,{type:`submit`,...q(`button`),style:{...s,minWidth:0,padding:`0 18px`,border:`none`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,fontWeight:600,cursor:i?`default`:`pointer`},...Yi(i),children:t})]})}function Da({items:e=[],separator:t=`/`,style:n,nodeRef:r}){return e.length?(0,G.jsx)(`nav`,{ref:r,"aria-label":`Breadcrumb`,style:{...z(n)},children:(0,G.jsx)(`ol`,{...q(`list`),style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,listStyle:`none`,margin:0,padding:0,fontSize:14},children:e.map((n,r)=>{let i=r===e.length-1;return(0,G.jsxs)(`li`,{...q(`item`),style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[r>0&&(0,G.jsx)(`span`,{...q(`separator`),style:{opacity:.4},"aria-hidden":!0,children:t}),i||!n.href?(0,G.jsx)(`span`,{...q(`crumb`,i&&`crumb-current`),style:{fontWeight:i?600:400,opacity:i?1:.7},"aria-current":i?`page`:void 0,children:n.label}):(0,G.jsx)(`a`,{...q(`crumb`),href:n.href,style:{color:`inherit`,opacity:.7,textDecoration:`none`},children:n.label})]},r)})})}):null}function Oa({pages:e=5,current:t=1,prevNext:n=!0,href:r=`#`,source:i,pageSize:a=6,align:o,hideEmpty:s,inert:c,style:u,nodeRef:d}){let{tenant:f,apiUrl:p,revision:m}=(0,l.useContext)(K),h=(0,l.useContext)(Hn),[g,_]=(0,l.useState)(null),v=i?Number(h?.[`${i}:total`]):NaN;(0,l.useEffect)(()=>{if(!i||Number.isFinite(v))return;let e=!0,t=i.startsWith(`api:`)?`${p}/data/${encodeURIComponent(i.slice(4))}`:`${p}/dynamic/${encodeURIComponent(i)}?limit=1`;return fetch(t,{headers:f?{"x-tenant":f}:{}}).then(e=>e.json()).then(t=>{if(!e)return;let n=t?.payload,r=Array.isArray(n)?n.length:Number(n?.total?.filtered??n?.total?.all??(Array.isArray(n?.data)?n.data.length:0));_(Number.isFinite(r)?r:0)}).catch(()=>e&&_(0)),()=>{e=!1}},[m,i,f,p,v]);let y=Math.max(1,Number(a)||6),b=Number.isFinite(v)?v:g;if(i&&b===null||i&&s&&!(b>0))return null;let x=Math.min(Math.max(i?Math.ceil(b/y):Number(e)||1,1),50),S=Math.min(Math.max(i?Un(h):Number(t)||1,1),x),C=e=>{if(i){if(typeof window<`u`){let t=new URLSearchParams(window.location.search);return t.set(`page`,String(e)),`?${t.toString()}`}return`?page=${e}`}return r&&r!==`#`?r.replace(`{page}`,String(e)):`#`},w=o===`center`?`center`:o===`right`?`flex-end`:`flex-start`,T=c?e=>e.preventDefault():void 0,E=e=>({display:`inline-flex`,alignItems:`center`,justifyContent:`center`,minWidth:36,height:36,padding:`0 8px`,borderRadius:8,fontSize:14,textDecoration:`none`,color:e?`var(--page-accent-text, #ffffff)`:`inherit`,background:e?`var(--page-accent, #111827)`:`transparent`,border:e?`1px solid transparent`:`1px solid rgba(148, 163, 184, 0.4)`});return(0,G.jsxs)(`nav`,{ref:d,"aria-label":`Pagination`,style:{display:`flex`,flexWrap:`wrap`,gap:8,alignItems:`center`,justifyContent:w,...z(u)},children:[n&&(0,G.jsx)(`a`,{...q(`page`,`page-arrow`),href:S>1?C(S-1):`#`,onClick:T,"aria-label":`Previous`,style:{...E(!1),opacity:S>1?1:.4},children:`‹`}),Array.from({length:x},(e,t)=>t+1).map(e=>(0,G.jsx)(`a`,{...q(`page`,e===S&&`page-active`),href:C(e),onClick:T,"aria-current":e===S?`page`:void 0,style:E(e===S),children:e},e)),n&&(0,G.jsx)(`a`,{...q(`page`,`page-arrow`),href:S<x?C(S+1):`#`,onClick:T,"aria-label":`Next`,style:{...E(!1),opacity:S<x?1:.4},children:`›`})]})}var ka=`webim.page_mode`,Aa=()=>{if(typeof window>`u`)return`auto`;try{let e=window.localStorage.getItem(ka);return e===`light`||e===`dark`?e:`auto`}catch{return`auto`}},ja=e=>{let t={width:16,height:16,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0};return e===`light`?(0,G.jsxs)(`svg`,{...t,children:[(0,G.jsx)(`circle`,{cx:`12`,cy:`12`,r:`4`}),(0,G.jsx)(`path`,{d:`M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4`})]}):e===`dark`?(0,G.jsx)(`svg`,{...t,children:(0,G.jsx)(`path`,{d:`M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z`})}):(0,G.jsxs)(`svg`,{...t,children:[(0,G.jsx)(`rect`,{x:`2`,y:`3`,width:`20`,height:`14`,rx:`2`}),(0,G.jsx)(`path`,{d:`M8 21h8M12 17v4`})]})},Ma={light:`Light theme`,dark:`Dark theme`,auto:`Follow the device theme`};function Na({variant:e,showSystem:t,style:n,nodeRef:r,inert:i}){let[a,o]=(0,l.useState)(i?`auto`:Aa),s=(0,l.useRef)(null),c=e=>{s.current=e,typeof r==`function`&&r(e)};(0,l.useEffect)(()=>{if(i)return;let e=s.current?.closest?.(`.webim-page`);e&&(a===`light`||a===`dark`?e.setAttribute(`data-webim-mode`,a):e.removeAttribute(`data-webim-mode`));try{a===`auto`?window.localStorage.removeItem(ka):window.localStorage.setItem(ka,a)}catch{}},[a,i]);let u=t===!1?[`light`,`dark`]:[`light`,`dark`,`auto`],d=u.includes(a)?a:u[0],f={appearance:`none`,border:0,margin:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,background:`transparent`,color:`inherit`,font:`inherit`,cursor:i?`default`:`pointer`,borderRadius:999};if(e===`buttons`)return(0,G.jsx)(`div`,{ref:c,role:`group`,"aria-label":`Theme`,style:{display:`inline-flex`,alignItems:`center`,gap:2,padding:3,borderRadius:999,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:u.map(e=>(0,G.jsx)(`button`,{...q(`option`,e===d&&`option-active`),type:`button`,title:Ma[e],"aria-label":Ma[e],"aria-pressed":e===d,onClick:i?void 0:()=>o(e),style:{...f,width:28,height:28,color:e===d?`var(--page-accent-text, #ffffff)`:`inherit`,background:e===d?`var(--page-accent, #111827)`:`transparent`,opacity:e===d?1:.7},children:ja(e)},e))});let p=u[(u.indexOf(d)+1)%u.length];return(0,G.jsx)(`button`,{ref:c,type:`button`,title:Ma[d],"aria-label":`Theme: ${Ma[d]} — switch to ${Ma[p]}`,onClick:i?void 0:()=>o(p),style:{...f,width:36,height:36,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:ja(d)})}function Pa(e){let t=e?.parentElement;for(;t&&t!==document.body;){let e=getComputedStyle(t).overflowY;if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t;t=t.parentElement}return window}var Fa=e=>e===window?window.scrollY:e.scrollTop,Ia={"bottom-right":e=>({right:e,bottom:e}),"bottom-left":e=>({left:e,bottom:e}),"bottom-center":e=>({left:`50%`,bottom:e,transform:`translateX(-50%)`})},La={linear:e=>e,out:e=>1-(1-e)**3,inout:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2},Ra=e=>{let t=e.getBoundingClientRect(),n=e.parentElement;for(;n&&n!==document.body;){let e=getComputedStyle(n);if(/(auto|scroll)/.test(e.overflowY)&&n.scrollHeight>n.clientHeight)break;n=n.parentElement}return!n||n===document.body?Math.max(document.documentElement.scrollHeight-(t.bottom+window.scrollY),0):Math.max(n.scrollHeight-(t.bottom-n.getBoundingClientRect().top+n.scrollTop),0)},za=(e,t)=>{let n=typeof e==`number`?e:parseFloat(e);return Number.isFinite(n)?n:t};function Ba(e,{locale:t,decimals:n=0,separator:r=`auto`}={}){let i=Math.min(Math.max(Math.round(za(n,0)),0),6);try{return new Intl.NumberFormat(t||void 0,{minimumFractionDigits:i,maximumFractionDigits:i,useGrouping:r!==`none`}).format(e)}catch{return e.toFixed(i)}}function Va({from:e,to:t,duration:n,delay:r,decimals:i,prefix:a,suffix:o,separator:s,easing:c,trigger:u,offset:d,once:f,label:p,align:m,style:h,nodeRef:g,inert:_}){let{locale:v}=(0,l.useContext)(K),y=Math.max(za(d,0),0),b=za(e,0),x=za(t,100),[S,C]=(0,l.useState)(x),w=(0,l.useRef)(null),[T,E]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=w.current;if(_||!T||!e){C(x);return}C(b);let t=Math.max(za(n,2e3),0),i=Math.max(za(r,0),0),a=La[c]||La.out,o=typeof window<`u`&&window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,s=0,l=0,d=!1,p=()=>{if(cancelAnimationFrame(s),clearTimeout(l),o||t===0){C(x);return}l=setTimeout(()=>{let e=performance.now(),n=r=>{let i=Math.min((r-e)/t,1);C(b+(x-b)*a(i)),i<1&&(s=requestAnimationFrame(n))};s=requestAnimationFrame(n)},i)};if(u===`load`||typeof IntersectionObserver>`u`)return p(),()=>{cancelAnimationFrame(s),clearTimeout(l)};let m=new IntersectionObserver(e=>{let t=e.some(e=>e.isIntersecting);t&&(!d||f===!1)?(d=!0,p()):!t&&f===!1&&(cancelAnimationFrame(s),clearTimeout(l),C(b))},{rootMargin:`0px 0px -${Math.min(y,Math.floor(Ra(e)))}px 0px`,threshold:y>0?0:.3});return m.observe(e),()=>{m.disconnect(),cancelAnimationFrame(s),clearTimeout(l)}},[T,_,b,x,n,r,c,u,y,f]),(0,G.jsxs)(`div`,{ref:e=>{w.current=e,e&&E(!0),typeof g==`function`&&g(e)},"data-wb-counter":``,style:{display:`flex`,flexDirection:`column`,alignItems:m===`left`?`flex-start`:m===`right`?`flex-end`:`center`,gap:4,fontSize:48,fontWeight:700,lineHeight:1.1,textAlign:m===`left`?`left`:m===`right`?`right`:`center`,...z(h)},children:[(0,G.jsxs)(`span`,{...q(`number`),style:{fontVariantNumeric:`tabular-nums`,whiteSpace:`nowrap`},children:[a||``,Ba(S,{locale:v,decimals:i,separator:s}),o||``]}),p?(0,G.jsx)(`span`,{...q(`label`),style:{fontSize:`0.3em`,fontWeight:400,lineHeight:1.4,opacity:.72},children:p}):null]})}function Ha({variant:e,label:t,position:n,offset:r,showAfter:i,smooth:a,bg:o,fg:s,style:c,nodeRef:u,inert:d,frame:f,builder:p}){let[m,h]=(0,l.useState)(!!d),[g,_]=(0,l.useState)(null),v=e=>{_(e),typeof u==`function`&&u(e)};(0,l.useEffect)(()=>{if(d){h(!0);return}if(!g)return;let e=Number(i)>=0?Number(i):300,t=()=>{let t=Pa(g),n=p&&!(t===window?document.documentElement.scrollHeight>window.innerHeight:t.scrollHeight>t.clientHeight);h(n||Fa(t)>e)};return t(),document.addEventListener(`scroll`,t,{capture:!0,passive:!0}),()=>document.removeEventListener(`scroll`,t,{capture:!0})},[d,g,i,p]);let y=()=>{if(d)return;let e=Pa(g),t=window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,n=a===!1||t?`auto`:`smooth`;e===window?window.scrollTo({top:0,behavior:n}):e.scrollTo({top:0,behavior:n})},b=Number(r)>=0?Number(r):24,x=e===`pill`,S=t||`Top`,C=Ia[n]?n:`bottom-right`,w=f?{position:`fixed`,zIndex:5,bottom:(f.bottom??0)+b,...C===`bottom-left`?{left:(f.left??0)+b}:null,...C===`bottom-right`?{right:(f.right??0)+b}:null,...C===`bottom-center`?{left:(f.left??0)+(f.width??0)/2,transform:`translateX(-50%)`}:null}:{position:`fixed`,zIndex:2147482e3,...Ia[C](b)};return(0,G.jsxs)(`button`,{ref:v,type:`button`,title:S,"aria-label":S,"aria-hidden":!m,tabIndex:m?0:-1,onClick:y,style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,gap:x?8:0,appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,width:x?`auto`:44,height:44,padding:x?`0 18px`:0,borderRadius:999,border:`1px solid transparent`,background:o||`var(--page-accent, #111827)`,color:s||`var(--page-accent-text, #ffffff)`,boxShadow:`0 6px 20px rgba(15, 23, 42, 0.25)`,cursor:d?`default`:`pointer`,opacity:+!!m,pointerEvents:m?`auto`:`none`,transition:`opacity 160ms ease, transform 160ms ease`,...w,...z(c),...w.transform?{transform:w.transform}:null},children:[(0,G.jsx)(`svg`,{...q(`icon`),width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":`true`,children:(0,G.jsx)(`path`,{d:`M12 19V5M12 5l-7 7M12 5l7 7`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`})}),x?(0,G.jsx)(`span`,{...q(`label`),children:S}):null]})}var Ua={facebook:{label:`Facebook`,color:`#1877f2`,d:`M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z`},instagram:{label:`Instagram`,color:`#e4405f`,d:`M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24 12 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06zm0 5.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z`},x:{label:`X (Twitter)`,color:`#000000`,d:`M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z`},linkedin:{label:`LinkedIn`,color:`#0a66c2`,d:`M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z`},youtube:{label:`YouTube`,color:`#ff0000`,d:`M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z`},tiktok:{label:`TikTok`,color:`#000000`,d:`M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z`},whatsapp:{label:`WhatsApp`,color:`#25d366`,d:`M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z`},telegram:{label:`Telegram`,color:`#26a5e4`,d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`},pinterest:{label:`Pinterest`,color:`#bd081c`,d:`M12 0C5.373 0 0 5.372 0 12c0 5.084 3.163 9.426 7.627 11.174-.105-.949-.2-2.405.042-3.441.218-.937 1.407-5.965 1.407-5.965s-.359-.719-.359-1.782c0-1.668.967-2.914 2.171-2.914 1.023 0 1.518.769 1.518 1.69 0 1.03-.655 2.569-.994 3.995-.283 1.194.599 2.169 1.777 2.169 2.133 0 3.772-2.249 3.772-5.495 0-2.873-2.064-4.882-5.012-4.882-3.414 0-5.418 2.561-5.418 5.207 0 1.031.397 2.138.893 2.738a.36.36 0 01.083.345l-.333 1.36c-.053.22-.174.267-.402.161-1.499-.698-2.436-2.889-2.436-4.649 0-3.785 2.75-7.262 7.929-7.262 4.163 0 7.398 2.967 7.398 6.931 0 4.136-2.607 7.464-6.227 7.464-1.216 0-2.359-.631-2.75-1.378l-.748 2.853c-.271 1.043-1.002 2.35-1.492 3.146C9.57 23.812 10.763 24 12 24c6.627 0 12-5.373 12-12 0-6.628-5.373-12-12-12z`},github:{label:`GitHub`,color:`#181717`,d:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`},discord:{label:`Discord`,color:`#5865f2`,d:`M20.317 4.37a19.791 19.791 0 00-4.885-1.515.074.074 0 00-.079.037c-.21.375-.444.865-.608 1.25a18.27 18.27 0 00-5.487 0 12.64 12.64 0 00-.617-1.25.077.077 0 00-.079-.037A19.736 19.736 0 003.677 4.37a.07.07 0 00-.032.027C.533 9.046-.32 13.58.099 18.058a.082.082 0 00.031.056 19.9 19.9 0 005.993 3.03.078.078 0 00.084-.028c.462-.63.873-1.295 1.226-1.994a.076.076 0 00-.041-.106 13.107 13.107 0 01-1.872-.892.077.077 0 01-.008-.128c.126-.094.252-.192.372-.291a.074.074 0 01.077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 01.078.009c.12.099.246.198.373.292a.077.077 0 01-.006.127 12.299 12.299 0 01-1.873.892.077.077 0 00-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 00.084.028 19.839 19.839 0 006.002-3.03.077.077 0 00.032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 00-.031-.03zM8.02 15.331c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z`},email:{label:`E-mail`,color:`#64748b`,d:`M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z`},website:{label:`Website`,color:`#64748b`,d:`M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z`}};function Wa({links:e=[],variant:t,color:n,size:r,gap:i,newTab:a,style:o,nodeRef:s,inert:c}){let l=Array.isArray(e)?e.filter(e=>e&&Ua[e.network]):[];if(!l.length)return null;let u=Math.min(Math.max(Number(r)||18,10),64),d=Math.round(u*1.9),f=Number.isFinite(Number(i))?Number(i):10,p=e=>n===`accent`?`var(--page-accent, #111827)`:n===`inherit`?`currentColor`:e.color,m=c?e=>e.preventDefault():void 0;return(0,G.jsx)(`div`,{ref:s,style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:f,...z(o)},children:l.map((e,r)=>{let i=Ua[e.network],o=t!==`outline`&&t!==`plain`,s=o?n===`accent`?`var(--page-accent-text, #ffffff)`:n===`inherit`?`var(--page-bg, #ffffff)`:`#ffffff`:p(i);return(0,G.jsx)(`a`,{...q(`link`,/^[a-z]+$/.test(e.network??``)&&`link-${e.network}`),href:e.url||`#`,onClick:m,"aria-label":e.label||i.label,title:e.label||i.label,...a!==!1&&!c?{target:`_blank`,rel:`noopener noreferrer`}:{},style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,width:t===`plain`?u:d,height:t===`plain`?u:d,borderRadius:`50%`,background:o?p(i):`transparent`,border:t===`outline`?`1px solid ${p(i)}`:`none`,color:`inherit`,textDecoration:`none`},children:(0,G.jsx)(`svg`,{...q(`icon`),width:u,height:u,viewBox:`0 0 24 24`,fill:s,"aria-hidden":!0,children:(0,G.jsx)(`path`,{d:i.d})})},`${e.network}-${r}`)})})}function Ga({steps:e=[],active:t=1,vertical:n=!1,style:r,nodeRef:i}){if(!e.length)return null;let a=Math.min(Math.max(Number(t)||1,1),e.length),o=e=>({width:32,height:32,borderRadius:`50%`,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:14,fontWeight:600,flexShrink:0,color:e===`todo`?`inherit`:`var(--page-accent-text, #ffffff)`,background:e===`todo`?`transparent`:`var(--page-accent, #111827)`,border:e===`todo`?`1px solid rgba(148, 163, 184, 0.5)`:`1px solid transparent`,opacity:e===`todo`?.6:1,boxShadow:e===`active`?`0 0 0 4px rgba(99, 102, 241, 0.2)`:`none`}),s=e=>({flexGrow:1,alignSelf:`center`,background:e?`var(--page-accent, #111827)`:`rgba(148, 163, 184, 0.4)`,...n?{width:2,minHeight:24,marginLeft:15,alignSelf:`auto`}:{height:2,minWidth:24}});return(0,G.jsx)(`div`,{ref:i,style:{display:`flex`,flexDirection:n?`column`:`row`,alignItems:n?`stretch`:`flex-start`,gap:n?4:8,...z(r)},children:e.map((e,t)=>{let r=t+1,i=r<a?`done`:r===a?`active`:`todo`;return(0,G.jsxs)(l.Fragment,{children:[t>0&&(0,G.jsx)(`div`,{...q(`step-line`,r<=a&&`step-line-done`),style:s(r<=a),"aria-hidden":!0}),(0,G.jsxs)(`div`,{...q(`step`,`step-${i}`),style:{display:`flex`,flexDirection:n?`row`:`column`,alignItems:`center`,gap:8,minWidth:0,textAlign:n?`left`:`center`},children:[(0,G.jsx)(`div`,{...q(`step-circle`,`step-circle-${i}`),style:o(i),children:i===`done`?`✓`:r}),(0,G.jsxs)(`div`,{style:{minWidth:0},children:[(0,G.jsx)(`div`,{...q(`step-label`,`step-label-${i}`),style:{fontSize:13,fontWeight:i===`active`?700:500,opacity:i===`todo`?.6:1},children:e.label}),e.description&&(0,G.jsx)(`div`,{...q(`step-description`),style:{fontSize:12,opacity:.6},children:e.description})]})]})]},t)})})}var Ka={small:{w:132,h:46,name:11.5,title:10,avatar:28},medium:{w:168,h:56,name:13,title:11,avatar:36},large:{w:210,h:70,name:15.5,title:12.5,avatar:46}},qa=e=>Ka[e]??Ka.medium;Ka.medium.w,Ka.medium.h;var Ja=e=>String(e?.group??``).trim(),Ya=e=>{let t=[],n=new Map;return e.forEach((e,r)=>{let i=Ja(e)||`#${r}`;n.has(i)||(n.set(i,[]),t.push(i)),n.get(i).push(e)}),t.flatMap(e=>n.get(e))},Xa=20,Za=12,Qa=[`left`,`center`,`right`],$a=e=>e.points.map((e,t)=>`${t?`L`:`M`} ${e.x} ${e.y}`).join(` `);function eo(e,{size:t=`medium`,horizontal:n=!1,groupTitles:r=`top`,columns:i=`off`}={}){let a=qa(t),o=n?a.h:a.w,s=n?16:20,c=(n?a.w:a.h)+(n?56:48),l=Array.isArray(e)?e.filter(e=>e&&e.id):[],u=new Set(l.map(e=>e.id)),d=new Map,f=[];for(let e of l)e.parent&&u.has(e.parent)&&e.parent!==e.id?(d.has(e.parent)||d.set(e.parent,[]),d.get(e.parent).push(e)):f.push(e);f=Ya(f);for(let[e,t]of d)d.set(e,Ya(t));let p=!n&&Qa.includes(i),m=e=>Qa.includes(e?.columns)?e.columns:i,h=e=>{let t=d.get(e.id)??[];if(!p)return t.map(e=>({nodes:[e]}));let n=[],r=[],i=()=>{r.length>1?n.push({nodes:r,line:m(e)}):r.forEach(e=>n.push({nodes:[e]})),r=[]};for(let e of t){let t=!(d.get(e.id)??[]).length;r.length&&(!t||Ja(r[0])!==Ja(e))&&i(),t?r.push(e):n.push({nodes:[e]})}return i(),n},g=(e,t)=>s+(Ja(e)!==Ja(t)&&(Ja(e)||Ja(t))?24:0),_=(e,t)=>g(e.nodes.at(-1),t.nodes[0]),v=e=>o+(e.line===`center`?0:Xa),y=new Map,b=(e,t)=>{if(t.has(e.id))return 0;t.add(e.id);let n=h(e),r=n.reduce((e,r,i)=>{let a=r.line?v(r):b(r.nodes[0],t);return r.line&&r.nodes.forEach(e=>t.add(e.id)),e+a+(i?_(n[i-1],r):0)},0),i=Math.max(o,r);return y.set(e.id,i),i};f.forEach(e=>b(e,new Set));let x=[],S=[],C=new Map,w=0,T=(e,t,r)=>{x.push({node:e,x:t,y:r});let i=Ja(e);if(i){let n=`${e.parent&&u.has(e.parent)&&e.parent!==e.id?e.parent:``}|${i}`;C.has(n)||C.set(n,{title:i,color:``,members:[]});let a=C.get(n);!a.color&&e.groupColor&&(a.color=e.groupColor),a.members.push({x:t,y:r})}w=Math.max(w,n?t+a.w:r+a.h)},E=(e,t,n,r)=>{let i=t+(e.line===`left`?Xa:0),o=n*c,s=r.y+(o-r.y)/2,l=e.line===`left`?i-Xa/2:i+a.w+Xa/2;e.nodes.forEach((t,n)=>{let c=o+n*(a.h+Za),u=c+a.h/2;if(T(t,i,c),e.line===`center`)S.push(n?{points:[{x:i+a.w/2,y:c-Za},{x:i+a.w/2,y:c}]}:{points:[r,{x:r.x,y:s},{x:i+a.w/2,y:s},{x:i+a.w/2,y:c}]});else{let t=e.line===`left`?i:i+a.w;S.push({points:[r,{x:r.x,y:s},{x:l,y:s},{x:l,y:u},{x:t,y:u}]})}})},D=(e,t,r,i)=>{if(i.has(e.id))return;i.add(e.id);let s=t+((y.get(e.id)??o)-o)/2,l=r*c;T(e,n?l:s,n?s:l);let u=t,d=h(e),f=n?{x:l+a.w,y:s+a.h/2}:{x:s+a.w/2,y:l+a.h};d.forEach((e,t)=>{if(t&&(u+=_(d[t-1],e)),e.line){E(e,u,r+1,f),e.nodes.forEach(e=>i.add(e.id)),u+=v(e);return}let a=e.nodes[0],s=u+((y.get(a.id)??o)-o)/2+o/2,l=(r+1)*c;S.push({points:n?[f,{x:(f.x+l)/2,y:f.y},{x:(f.x+l)/2,y:s},{x:l,y:s}]:[f,{x:f.x,y:(f.y+l)/2},{x:s,y:(f.y+l)/2},{x:s,y:l}]}),D(a,u,r+1,i),u+=y.get(a.id)??o})},O=0,k=new Set;f.forEach((e,t)=>{t&&(O+=g(f[t-1],e)),D(e,O,0,k),O+=y.get(e.id)??o});let A=Math.max(O,o),j=r===`hidden`?0:22,M=[...C.values()].map(e=>{let t=Math.min(...e.members.map(e=>e.x))-12,n=Math.max(...e.members.map(e=>e.x))+a.w+12,i=Math.min(...e.members.map(e=>e.y))-12-(r===`bottom`?0:j),o=Math.max(...e.members.map(e=>e.y))+a.h+12+(r===`bottom`?j:0);return{x:t,y:i,width:n-t,height:o-i,title:e.title,color:e.color}}),N=n?Math.max(w,a.w):A,P=n?A:Math.max(w,a.h),F=Math.max(0,...M.map(e=>-e.x)),I=Math.max(0,...M.map(e=>-e.y));if(M.length&&(N=Math.max(N,...M.map(e=>e.x+e.width))+F,P=Math.max(P,...M.map(e=>e.y+e.height))+I,F||I)){for(let e of x)e.x+=F,e.y+=I;for(let e of S)e.points=e.points.map(e=>({x:e.x+F,y:e.y+I}));for(let e of M)e.x+=F,e.y+=I}return{boxes:x,links:S,groups:M,width:N,height:P,horizontal:n}}var to=(e,t)=>{let n=String(e??``);return n.length>t?`${n.slice(0,t-1)}…`:n},no=e=>{let t=/^#([0-9a-f]{6}|[0-9a-f]{3})$/i.exec(String(e??``).trim());if(!t)return`#ffffff`;let n=t[1];n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=parseInt(n,16);return .299*(r>>16&255)+.587*(r>>8&255)+.114*(r&255)>150?`#111827`:`#ffffff`},ro=e=>!!(e?.cv?.trim?.()||e?.photo||e?.profilePhoto||e?.profile?.length);function Y(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:rr(e);return n.map(e=>{let n=e.data??{},a=r(n[t.parentField]),o=a&&typeof a==`object`?a.id??null:a||null;return{id:e.id,name:i(n[t.nameField||`name`])||i(n.name)||`Untitled`,title:t.titleField?i(n[t.titleField]):``,photo:t.photoField&&r(n[t.photoField])||``,parent:t.parentField?o:null,cv:t.cvField?i(n[t.cvField]):``,href:t.hrefField?i(n[t.hrefField]):``,group:t.groupField?i(n[t.groupField]):``}})}var io=/^(https?:\/\/[^\s"<>]+|mailto:[^\s"<>]+|tel:[+\d][\d\s().-]*|\/(?!\/)[^\s"<>]*)$/i,ao=e=>{let t=String(e??``).trim();return io.test(t)?t:``},oo=e=>{e.startsWith(`/`)?window.location.assign(e):window.open(e,`_blank`,`noopener,noreferrer`)},so={size:36,pad:10};function co({node:e,onClose:t}){(0,l.useEffect)(()=>{let e=e=>e.key===`Escape`&&t();return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let n=e.profile?.length?e.profile:null,r=n?``:e.profilePhoto||e.photo,i=e.title||e.name,a=e.title&&e.name?e.name:``,o=!!(n||r&&e.cv),s=ao(e.href);return(0,G.jsx)(`div`,{onClick:t,role:`dialog`,"aria-modal":`true`,"aria-label":i,style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(2, 6, 23, 0.6)`,backdropFilter:`blur(4px)`,WebkitBackdropFilter:`blur(4px)`,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:16},children:(0,G.jsxs)(`div`,{onClick:e=>e.stopPropagation(),style:{background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.35)`,borderRadius:14,maxWidth:o?900:440,width:`100%`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,overflow:`hidden`,boxShadow:`0 24px 64px rgba(2, 6, 23, 0.5)`},children:[(0,G.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:12,padding:`18px 20px 14px 24px`,borderBottom:`1px solid rgba(148, 163, 184, 0.3)`},children:[(0,G.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,G.jsx)(`div`,{style:{fontSize:18,fontWeight:700,lineHeight:1.35},children:i}),a&&(0,G.jsx)(`div`,{style:{fontSize:14,opacity:.7,marginTop:2},children:a})]}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:t,style:{flexShrink:0,width:32,height:32,border:0,borderRadius:8,background:`transparent`,color:`inherit`,fontSize:20,lineHeight:1,cursor:`pointer`,opacity:.6},children:`×`})]}),(0,G.jsxs)(`div`,{style:{overflowY:`auto`,padding:24,display:`flex`,flexWrap:`wrap`,gap:24,alignItems:`flex-start`},children:[r&&(0,G.jsx)(`img`,{src:r,alt:e.name||i,style:o?{flex:`1 1 220px`,maxWidth:340,width:`100%`,height:`auto`,borderRadius:10,objectFit:`cover`}:{width:96,height:96,borderRadius:`50%`,objectFit:`cover`}}),(n||e.cv||s)&&(0,G.jsxs)(`div`,{style:{flex:`2 1 320px`,minWidth:0},children:[n&&(0,G.jsx)(`div`,{style:{display:`flow-root`,marginBottom:s?12:0},children:Br(n)}),!n&&e.cv&&String(e.cv).split(/\n+/).map((e,t)=>(0,G.jsx)(`p`,{style:{fontSize:15,lineHeight:1.65,margin:`0 0 12px`},children:e},t)),s&&(0,G.jsx)(`a`,{href:s,target:`_blank`,rel:`noopener noreferrer`,style:{display:`inline-block`,marginTop:6,padding:`8px 14px`,borderRadius:8,fontSize:13,fontWeight:600,textDecoration:`none`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:`Open profile ↗`})]})]})]})})}function lo(e){return e.chart?.people?.length?(0,G.jsx)(uo,{...e}):(0,G.jsx)(fo,{...e})}function uo({chart:e,profiles:t,style:n,nodeRef:r,interactive:i=!0}){let[a,o]=(0,l.useState)(null),s=(0,l.useMemo)(()=>vn(e),[e]),c=(0,l.useMemo)(()=>new Set(e.people.map(e=>e.parent)),[e]);return(0,G.jsxs)(`div`,{ref:r,style:{maxWidth:`100%`,overflowX:`auto`,...z(n)},children:[(0,G.jsxs)(`svg`,{viewBox:`0 0 ${s.width} ${s.height}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:s.width,height:`auto`,margin:`0 auto`},children:[s.frames.map(({person:e,x:t,y:n,width:r,height:i})=>(0,G.jsx)(`foreignObject`,{x:t,y:n,width:r,height:i,children:(0,G.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:Bn(e,c.has(e.id))}})},e.id)),s.links.map((e,t)=>(0,G.jsx)(`path`,{d:Tn(e),fill:`none`,stroke:Mn.line,strokeWidth:`1.5`},t)),s.cards.map(({person:n,x:r,y:a,width:c,height:l})=>{let u=Array.isArray(t?.[n.id])&&t[n.id].length?t[n.id]:null,d={id:n.id,name:n.name,title:n.title,cv:n.description,photo:n.photo,profilePhoto:n.photo,href:n.link,profile:u},f=ao(n.link),p=i&&(f||ro(d)),m=()=>f?oo(f):o(d);return(0,G.jsx)(`g`,{onClick:p?m:void 0,onKeyDown:p?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),m())}:void 0,tabIndex:p?0:void 0,style:p?{cursor:`pointer`}:void 0,role:p?f?`link`:`button`:void 0,"aria-label":p?f?`${n.name||n.title} — open link`:`Open ${n.name||n.title}'s profile`:void 0,children:(0,G.jsx)(`foreignObject`,{x:r,y:a,width:c,height:l,children:(0,G.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:zn(n,e,s.size,Mn)}})})},n.id)})]}),a&&(0,G.jsx)(co,{node:a,onClose:()=>o(null)})]})}function fo({nodes:e=[],source:t,nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c,groupTitles:u=`top`,groupBg:d=``,size:f=`medium`,horizontal:p=!1,columns:m=`off`,style:h,nodeRef:g,interactive:_=!0}){let v=(0,l.useId)(),[y,b]=(0,l.useState)(null),{tenant:x,apiUrl:S,revision:C}=(0,l.useContext)(K),w=(0,l.useContext)(Hn)?.[t],[T,E]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[C,t,x,S,w]);let D=t?Y(w??T??[],{nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c}):e,O=qa(f),{boxes:k,links:A,groups:j,width:M,height:N}=eo(D,{size:f,horizontal:p,groupTitles:u,columns:m});if(!k.length)return!_&&t?(0,G.jsxs)(`div`,{ref:g,style:{padding:18,border:`1px dashed rgba(148, 163, 184, 0.6)`,borderRadius:10,fontSize:13,opacity:.7,textAlign:`center`,...z(h)},children:[`Org Chart — no published entries in “`,t,`” yet`]}):null;let P=new Set(k.filter(e=>e.node.parent==null||e.node.parent===``).map(e=>e.node.id));return(0,G.jsxs)(`div`,{ref:g,style:{maxWidth:`100%`,overflowX:`auto`,...z(h)},children:[(0,G.jsxs)(`svg`,{viewBox:`0 0 ${M} ${N}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:M,height:`auto`,margin:`0 auto`},children:[j.map((e,t)=>{let n=e.color||d||`rgba(148, 163, 184, 0.16)`,r=!!(e.color||d);return(0,G.jsxs)(`g`,{children:[(0,G.jsx)(`rect`,{x:e.x,y:e.y,width:e.width,height:e.height,rx:`16`,fill:n}),u!==`hidden`&&e.title&&(0,G.jsx)(`text`,{x:e.x+e.width/2,y:u===`bottom`?e.y+e.height-22*.42:e.y+22*.78,textAnchor:`middle`,fontSize:O.title+1,fontWeight:`600`,opacity:`0.55`,fill:r?no(e.color||d):`var(--page-text, #111827)`,children:to(e.title,Math.floor(e.width/7))})]},`group-${t}`)}),A.map((e,t)=>(0,G.jsx)(`path`,{d:$a(e),fill:`none`,stroke:`rgba(148, 163, 184, 0.7)`,strokeWidth:`1.5`},t)),k.map(({node:e,x:t,y:n})=>{let r=P.has(e.id),i=!!e.color2,a=!!e.color||r||i,o=e.color||(r?`var(--page-accent, #4f46e5)`:`var(--page-bg, #ffffff)`),s=e.color?no(e.color):r?`var(--page-accent-text, #ffffff)`:`var(--page-text, #111827)`,c=i?no(e.color2):s,l=ao(e.href),u=_&&(l||ro(e)),d=()=>l?oo(l):b(e),f=e.photo?t+so.pad+O.avatar+8:t+O.w/2,p=e.photo?`start`:`middle`,m=e.photo?Math.floor((O.w-O.avatar-26)/7):Math.floor(O.w/7.6),h=O.h/2,g=[e.name,e.title].map(e=>String(e??``).trim()).filter(Boolean);return(0,G.jsxs)(`g`,{onClick:u?d:void 0,onKeyDown:u?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),d())}:void 0,tabIndex:u?0:void 0,style:u?{cursor:`pointer`}:void 0,role:u?l?`link`:`button`:void 0,"aria-label":u?l?`${e.name||e.title} — open link`:`Open ${e.name||e.title}'s profile`:void 0,children:[i&&e.gradient?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(`linearGradient`,{id:`${v}-${e.id}-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,G.jsx)(`stop`,{offset:`0%`,stopColor:e.color||`var(--page-accent, #4f46e5)`}),(0,G.jsx)(`stop`,{offset:`100%`,stopColor:e.color2})]}),(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:`url(#${v}-${e.id}-grad)`})]}):i?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`clipPath`,{id:`${v}-${e.id}-box`,children:(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`})}),(0,G.jsxs)(`g`,{clipPath:`url(#${v}-${e.id}-box)`,children:[(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:h,fill:o}),(0,G.jsx)(`rect`,{x:t,y:n+h,width:O.w,height:O.h-h,fill:e.color2})]})]}):(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:o,stroke:a?`none`:`var(--page-accent, #4f46e5)`,strokeWidth:a?0:1.5}),e.photo&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`clipPath`,{id:`${v}-${e.id}`,children:(0,G.jsx)(`circle`,{cx:t+so.pad+O.avatar/2,cy:n+O.h/2,r:O.avatar/2})}),(0,G.jsx)(`image`,{href:e.photo,x:t+so.pad,y:n+(O.h-O.avatar)/2,width:O.avatar,height:O.avatar,preserveAspectRatio:`xMidYMid slice`,clipPath:`url(#${v}-${e.id})`})]}),i&&!e.gradient?(0,G.jsxs)(G.Fragment,{children:[e.title&&(0,G.jsx)(`text`,{x:f,y:n+h/2+O.title*.35,textAnchor:p,fontSize:O.title,fontWeight:`600`,fill:s,children:to(e.title,m+4)}),e.name&&(0,G.jsx)(`text`,{x:f,y:n+h+h/2+O.name*.35,textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:c,children:to(e.name,m)})]}):(0,G.jsxs)(G.Fragment,{children:[g[0]&&(0,G.jsx)(`text`,{x:f,y:n+(g[1]?O.h*.43:O.h*.57),textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:s,children:to(g[0],m)}),g[1]&&(0,G.jsx)(`text`,{x:f,y:n+O.h*.73,textAnchor:p,fontSize:O.title,opacity:`0.7`,fill:s,children:to(g[1],m+4)})]})]},e.id)})]}),y&&(0,G.jsx)(co,{node:y,onClose:()=>b(null)})]})}function po({value:e,onCommit:t,style:n,hint:r}){let[i,a]=(0,l.useState)(!1),o=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!i||!o.current)return;let e=o.current,t=document.createRange();e.focus(),t.selectNodeContents(e),t.collapse(!1);let n=window.getSelection();n.removeAllRanges(),n.addRange(t)},[i]),(0,G.jsx)(`span`,{ref:o,contentEditable:i,suppressContentEditableWarning:!0,title:i?void 0:r||`Double-click to edit`,onDoubleClick:()=>a(!0),onBlur:i?e=>{a(!1),t(e.currentTarget.textContent)}:void 0,onKeyDown:i?t=>{t.stopPropagation(),t.key===`Escape`&&(t.currentTarget.textContent=e??``,t.currentTarget.blur()),t.key===`Enter`&&(t.preventDefault(),t.currentTarget.blur())}:void 0,style:{display:`block`,minHeight:`1em`,outline:`none`,cursor:i?`text`:`inherit`,...n},children:e??``})}var mo=360,ho=`
24
+ `),t)))}return n}function nn(e,t,n,r){let i=Xt(e[t]),a=i.indent,o=[],s=null,c=t;for(;c<e.length;){let t=e[c],n=Xt(t);if(n&&n.indent<=a+1){if(n.ordered!==i.ordered)break;s={lines:[n.text]},o.push(s),c+=1;continue}if(zt.test(t)){let t=c;for(;t<e.length&&zt.test(e[t]);)t+=1;if(!(t<e.length&&(Yt(e[t])>=a+2||Xt(e[t])&&Xt(e[t]).ordered===i.ordered)))break;s?.lines.push(``),c=t;continue}if(!s)break;if(Yt(t)>=a+2)s.lines.push(t.slice(Math.min(t.length-t.trimStart().length,a+2)));else if(!n)s.lines.push(t.trim());else break;c+=1}return n.push({type:i.ordered?`ol`:`ul`,...i.ordered&&i.start!==1?{start:i.start}:null,items:o.map(e=>{let t=qt.exec(e.lines[0]??``);t&&(e.lines[0]=t[2]);let n=tn(e.lines,r),i=n[0]?.type===`p`?n.shift():null;return{parts:i?i.parts:[],...n.length?{blocks:n}:null,...t?{task:t[1].toLowerCase()===`x`}:null}})}),c}function rn(e,t={}){return String(e??``).trim()?tn(en(e),t):[]}function an(e,t){let n={data:e,depth:0,parent:null,children:null},r=[n];for(;r.length;){let e=r.pop(),n=t(e.data);if(n?.length){e.children=n.map(t=>({data:t,depth:e.depth+1,parent:e,children:null}));for(let t=e.children.length-1;t>=0;--t)r.push(e.children[t])}}return n}function on(e,t){let n=[e];for(;n.length;){let e=n.pop();if(t(e),e.children)for(let t=e.children.length-1;t>=0;--t)n.push(e.children[t])}}function sn(e,t){let n=[e],r=[];for(;n.length;){let e=n.pop();if(r.push(e),e.children)for(let t of e.children)n.push(t)}for(;r.length;)t(r.pop())}function cn(e,[t,n],r){let i=(e,t)=>({_:e,parent:null,children:null,A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:t}),a=i(e,0);a.a=a,on(a,e=>{e._.children&&(e.children=e._.children.map((t,n)=>{let r=i(t,n);return r.a=r,r.parent=e,r}))}),a.parent=i(null,0),a.parent.a=a.parent,a.parent.children=[a];let o=e=>e.children?e.children[0]:e.t,s=e=>e.children?e.children[e.children.length-1]:e.t,c=(e,t,n)=>{let r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n},l=e=>{let t=0,n=0;for(let r=e.children.length-1;r>=0;--r){let i=e.children[r];i.z+=t,i.m+=t,t+=i.s+(n+=i.c)}},u=(e,t,n)=>e.a.parent===t.parent?e.a:n,d=(e,t,n)=>{if(!t)return n;let i=e,a=e,l=t,d=i.parent.children[0],f=i.m,p=a.m,m=l.m,h=d.m;for(;l=s(l),i=o(i),l&&i;){d=o(d),a=s(a),a.a=e;let t=l.z+m-i.z-f+r(l._,i._);t>0&&(c(u(l,e,n),e,t),f+=t,p+=t),m+=l.m,f+=i.m,h+=d.m,p+=a.m}return l&&!s(a)&&(a.t=l,a.m+=m-p),i&&!o(d)&&(d.t=i,d.m+=f-h,n=e),n};return sn(a,e=>{let t=e.parent.children,n=e.i?t[e.i-1]:null;if(e.children){l(e);let t=(e.children[0].z+e.children[e.children.length-1].z)/2;n?(e.z=n.z+r(e._,n._),e.m=e.z-t):e.z=t}else n&&(e.z=n.z+r(e._,n._));e.parent.A=d(e,n,e.parent.A||t[0])}),a.parent.m=-a.z,on(a,e=>{e._.x=e.z+e.parent.m,e.m+=e.parent.m}),on(e,e=>{e.x*=t,e.y=e.depth*n}),e}var ln=20,un={S:{width:200,height:80},M:{width:240,height:80},L:{width:280,height:100},XL:{width:320,height:120}},dn={across:20,down:80,stack:20},fn=dn.across/2,pn={pad:20,header:40},mn=2*dn.stack,hn=`__root__`,gn=20,_n=e=>Math.round(e/ln)*ln;function vn(e){let{people:t,direction:n}=e,r=un[e.cardSize]??un.M,i=n===`right`,a=new Map;for(let e of t){let t=e.parent??hn;a.has(t)||a.set(t,[]),a.get(t).push(e)}let o=i?r.height+dn.across:r.width+dn.across,s=i?r.width+dn.down:r.height+dn.down,c=e=>e.id===hn||!e.collapsed?a.get(e.id)??[]:[],l=e=>e.kind===`group`,u=e=>c(e).filter(e=>e.placement!==`below`),d=e=>c(e).filter(e=>e.placement===`below`),f=(e,t)=>e.memberTeams===`inside`?c(t):[],p=e=>u(e).flatMap(t=>e.memberTeams===`inside`?f(e,t):[t]),m=e=>{let t=u(e).length,n=i||e.memberTeams===`inside`,r=Math.max(1,Math.min(t,e.memberColumns||(n?t:1)));return{cols:r,rows:Math.ceil(t/r)}},h=(e,t)=>{let n=f(e,t).length;return r.height+(n?mn+n*(r.height+dn.stack)-dn.stack:0)},g=e=>{let t=u(e),{cols:n,rows:i}=m(e),a=[],o=pn.header;for(let r=0;r<i;r+=1)a.push(o),o+=Math.max(...t.slice(r*n,(r+1)*n).map(t=>h(e,t)))+dn.stack;return{width:(t.length?n*(r.width+dn.across)-dn.across:r.width)+2*pn.pad,height:(t.length?o-dn.stack:pn.header)+pn.pad,tops:a}},_=(e,t=c(e))=>{if(i||e.id===hn)return t;let n=[],r=[],a=()=>{r.length>1?n.push({id:`${r[0].id}:stack`,people:r,line:e.columns}):n.push(...r),r=[]};for(let e of t)c(e).length||l(e)?(a(),n.push(e)):r.push(e);return a(),n},v=(e,t,n)=>{let r=n;for(let n=Math.ceil(t/s);n>0;--n)r=[{id:`${e}:${n}`,spacer:!0,below:r}];return r},y=i?r.width:r.height,b=an({id:hn},e=>{if(e.people)return v(e.id,(e.people.length-1)*(r.height+dn.stack),[]);if(e.spacer)return e.below;if(l(e)){let t=p(e).flatMap(e=>_(e)),n=_(e,d(e)),r=i?[...n,...t]:[...t,...n],a=i?g(e).width:g(e).height;return v(`${e.id}:frame`,a-y,r)}return _(e)}),x=e=>{if(!l(e.data))return 0;let t=g(e.data);return(i?t.height-r.height:t.width-r.width)/o};cn(b,[o,s],(e,t)=>(e.parent===t.parent?1:1+2*ln/o)+(x(e)+x(t))/2);let S=new Map,C=[],w=[],T=[],E=new Map([[hn,{x:0,y:0}]]),D=new Map,O=(e,t,a,o,s=null)=>{let c=E.get(t??hn),u={x:c.x+(e.dx||0),y:c.y+(e.dy||0)},d=l(e)?g(e):null,f={person:e,x:_n(a.x)+u.x,y:_n(a.y)+u.y,width:d?d.width:r.width,height:d?d.height:r.height};if(E.set(e.id,u),S.set(e.id,f),(d?w:C).push(f),o?.inner)T.push(o.line===`center`?{kind:`straight`,source:o.above?.id??e.parent,target:e.id,from:`bottom`,to:`top`}:{kind:`rail`,source:e.parent,target:e.id,from:`bottom`,to:o.line===`right`?`right`:`left`,side:o.line===`right`?`right`:`left`,drop:mn/2});else if(e.parent&&!s){let t=D.get(e.parent);t!==void 0&&!e.lineFrom&&!e.lineTo&&!(o?.line===`center`&&o.above)?T.push({kind:`exit`,source:e.parent,target:e.id,from:i?`right`:`bottom`,to:o?.line===`left`||i?`left`:`top`,exit:t,into:o?.line===`left`?`side`:`top`,level:o?.line===`left`?_n(o.top)+c.y-dn.down/2:null}):T.push(yn(e,o,n))}};on(b,e=>{let t=e.data;if(t.id===hn||t.spacer)return;let n=e.y-s;if(t.people){t.people.forEach((i,a)=>O(i,i.parent,{x:e.x-r.width/2,y:n+a*(r.height+dn.stack)},{line:t.line,above:t.people[a-1],top:n}));return}if(l(t)){let a=g(t),o=i?{x:n,y:e.x-a.height/2}:{x:e.x-a.width/2,y:n};O(t,t.parent,o,null);let s=E.get(t.id);p(t).forEach(e=>D.set(e.id,i?_n(o.y)+s.y+a.height+fn:_n(o.x)+s.x-fn));let{cols:c}=m(t);u(t).forEach((e,n)=>{let i={x:o.x+pn.pad+n%c*(r.width+dn.across),y:o.y+a.tops[Math.floor(n/c)]},s=f(t,e);O(e,t.id,i,null,t),s.forEach((n,a)=>O(n,e.id,{x:i.x,y:i.y+r.height+mn+a*(r.height+dn.stack)},{line:e.columns,above:s[a-1],inner:!0},t))});return}O(t,t.parent,i?{x:n,y:e.x-r.height/2}:{x:e.x-r.width/2,y:n},null)});let k=[...w,...C],A=Math.min(...k.map(e=>e.x))-gn,j=Math.min(...k.map(e=>e.y))-gn;for(let e of k)e.x-=A,e.y-=j;let M=T.map(e=>Sn(e,S,i)).filter(Boolean),N=[...k.flatMap(e=>[e.x+e.width]),...M.flatMap(e=>e.points.map(e=>e.x))],P=[...k.flatMap(e=>[e.y+e.height]),...M.flatMap(e=>e.points.map(e=>e.y))];return{cards:C,frames:w,links:M,width:Math.ceil(Math.max(...N)+gn),height:Math.ceil(Math.max(...P)+gn),size:r}}function yn(e,t,n){let r=n===`right`,i=r?`right`:`bottom`,a=r?`left`:`top`;return(e.lineTo===`left`||e.lineTo===`right`)&&!r&&(!e.lineFrom||e.lineFrom===`bottom`)?{kind:`elbow`,source:e.parent,target:e.id,from:`bottom`,to:e.lineTo,side:e.lineTo}:e.lineFrom||e.lineTo?{kind:`step`,source:e.parent,target:e.id,from:e.lineFrom||i,to:e.lineTo||a}:t?t.line===`center`?t.above?{kind:`straight`,source:t.above.id,target:e.id,from:i,to:a}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}:t.line===`right`?{kind:`rail`,source:e.parent,target:e.id,from:i,to:`right`,side:`right`}:{kind:`rail`,source:e.parent,target:e.id,from:i,to:`left`,side:`left`}:{kind:`step`,source:e.parent,target:e.id,from:i,to:a}}function bn(e,t){return t===`top`?{x:e.x+e.width/2,y:e.y}:t===`bottom`?{x:e.x+e.width/2,y:e.y+e.height}:t===`left`?{x:e.x,y:e.y+e.height/2}:{x:e.x+e.width,y:e.y+e.height/2}}var xn={top:{x:0,y:-1},bottom:{x:0,y:1},left:{x:-1,y:0},right:{x:1,y:0}};function Sn(e,t,n){let r=t.get(e.source),i=t.get(e.target);if(!r||!i)return null;let a=bn(r,e.from),o=bn(i,e.to),s;if(e.kind===`straight`)s=[a,o];else if(e.kind===`rail`){let t=a.y+(e.drop??dn.down/2),n=e.side===`right`?o.x+fn:o.x-fn;s=[a,{x:a.x,y:t},{x:n,y:t},{x:n,y:o.y},o]}else if(e.kind===`exit`){let{exit:t,into:r,level:i}=e;if(n){let e=a.x+dn.across/2;s=[a,{x:e,y:a.y},{x:e,y:t},{x:o.x-dn.down/2,y:t},{x:o.x-dn.down/2,y:o.y},o]}else{let e=a.y+dn.stack/2;s=r===`side`?[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:i},{x:o.x-fn,y:i},{x:o.x-fn,y:o.y},o]:[a,{x:a.x,y:e},{x:t,y:e},{x:t,y:o.y-dn.down/2},{x:o.x,y:o.y-dn.down/2},o]}}else if(e.kind===`elbow`){let t=e.side===`right`?a.x<o.x+fn:a.x>o.x-fn,n=e.side===`right`?o.x+fn:o.x-fn;return s=t?[a,{x:a.x,y:a.y+dn.down/2},{x:n,y:a.y+dn.down/2},{x:n,y:o.y},o]:[a,{x:a.x,y:o.y},o],{points:wn(s),square:!t}}else s=Cn(a,e.from,o,e.to);return{points:wn(s)}}function Cn(e,t,n,r){let i=e=>e===`top`||e===`bottom`;if(t===`bottom`&&r===`top`&&n.y>e.y){let t=(e.y+n.y)/2;return[e,{x:e.x,y:t},{x:n.x,y:t},n]}if(t===`right`&&r===`left`&&n.x>e.x){let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}let a={x:e.x+xn[t].x*20,y:e.y+xn[t].y*20},o={x:n.x+xn[r].x*20,y:n.y+xn[r].y*20};return[e,a,i(t)?{x:a.x,y:o.y}:{x:o.x,y:a.y},o,n]}var wn=e=>e.filter((e,t,n)=>t===0||e.x!==n[t-1].x||e.y!==n[t-1].y);function Tn(e,t=10){let{points:n}=e,r=e.square?0:t,i=`M ${n[0].x} ${n[0].y}`;for(let e=1;e<n.length-1;e+=1){let[t,a,o]=[n[e-1],n[e],n[e+1]],s=Math.min(r,Math.hypot(a.x-t.x,a.y-t.y)/2,Math.hypot(o.x-a.x,o.y-a.y)/2),c=(e,t)=>{let n=Math.hypot(t.x-e.x,t.y-e.y)||1;return{x:e.x+(t.x-e.x)/n*s,y:e.y+(t.y-e.y)/n*s}},l=c(a,t),u=c(a,o);i+=` L ${l.x} ${l.y} Q ${a.x} ${a.y} ${u.x} ${u.y}`}let a=n.at(-1);return`${i} L ${a.x} ${a.y}`}var En=`#4f46e5`,Dn={S:.85,M:1,L:1.15,XL:1.3},On={name:14,title:12.5,unit:13.5,department:11,band:12.5},kn=1.3,An={classic:12,band:6},jn={left:`flex-start`,center:`center`,right:`flex-end`},Mn={card:`var(--page-bg, #ffffff)`,text:`var(--page-text, #111827)`,border:`rgba(148, 163, 184, 0.45)`,line:`rgba(148, 163, 184, 0.8)`},Nn=e=>String(e).replace(/[&<>"']/g,e=>({"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`})[e]),Pn=e=>Object.entries(e).filter(([,e])=>e!=null).map(([e,t])=>`${e}:${t}`).join(`;`),Fn=e=>({display:`-webkit-box`,"-webkit-line-clamp":e,"-webkit-box-orient":`vertical`,overflow:`hidden`,"overflow-wrap":`anywhere`}),In=e=>`#${[1,3,5].map(t=>Math.round(parseInt(e.slice(t,t+2),16)*.55).toString(16).padStart(2,`0`)).join(``)}`,Ln=e=>e.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0].toUpperCase()).join(``)||`?`;function Rn(e,t,n,r){let i=e=>On[e]*n*kn,a=(e,t,n)=>Math.max(1,Math.min(n,Math.floor((e+.5)/i(t)))),o=e.height-An.classic-(r.department?On.department*n*1.4:0),s=r.title?t?a(o-i(`title`),`name`,2):1:a(o,`name`,t?20:2),c=e.height*.55-An.band;return{name:s,title:a(o-s*i(`name`),`title`,t?20:2),unit:a(o,`unit`,t?20:3),top:a(c,`band`,t?20:2),bottom:a(e.height-c-2*An.band,`band`,t?20:1),single:a(e.height-An.band,`band`,t?20:3)}}function zn(e,t,n,r){let i=Dn[e.textSize||t.textSize]??1,a=e.textAlign||t.textAlign||`left`,o=e.color||En,s=Rn(n,t.wrapText,i,e),c={"box-sizing":`border-box`,width:`100%`,height:`100%`,overflow:`hidden`,position:`relative`,"font-family":`inherit`,"line-height":kn};if(t.cardStyle===`banded`){let n={display:`flex`,"align-items":`center`,"justify-content":jn[a],"text-align":a,padding:`0 10px`,color:`#fff`,"font-weight":600,"font-size":`${On.band*i}px`,"min-height":0},r=e.title||e.name,l=e.color2||In(o),u=(e.bandFill||t.bandFill)===`gradient`,d=`linear-gradient(${o}, ${l})`;return r&&!(e.title&&e.name)?`<div style="${Pn({...c,...n,"border-radius":`10px`,background:u?d:`linear-gradient(${o} 50%, ${l} 50%)`})}"><div style="${Pn(Fn(s.single))}">${Nn(r)}</div></div>`:`<div style="${Pn({...c,display:`flex`,"flex-direction":`column`,"border-radius":`10px`,background:u?d:l})}"><div style="${Pn({...n,flex:`0 0 55%`,background:u?null:o})}"><div style="${Pn(Fn(s.top))}">${Nn(e.title)}</div></div><div style="${Pn({...n,"flex-grow":1})}"><div style="${Pn(Fn(s.bottom))}">${Nn(e.name)}</div></div></div>`}let l=!!(e.photo||e.name),u=n.height>=120?56:n.height>=100?48:40,d=[];e.showPhoto&&l&&d.push(`<div style="${Pn({flex:`none`,width:`${u}px`,height:`${u}px`,"border-radius":`50%`,overflow:`hidden`,background:o,color:`#fff`,display:`flex`,"align-items":`center`,"justify-content":`center`,"font-weight":600,"font-size":`${u*.38}px`})}">`+(e.photo?`<img src="${e.photo}" alt="" style="width:100%;height:100%;object-fit:cover;display:block"/>`:Nn(Ln(e.name)))+`</div>`);let f=[];return l&&e.name&&f.push(`<div style="${Pn({...Fn(s.name),"font-weight":600,"font-size":`${On.name*i}px`})}">${Nn(e.name)}</div>`),e.title&&f.push(`<div style="${Pn({...Fn(l?s.title:s.unit),"font-size":`${(l?On.title:On.unit)*i}px`,"font-weight":l?400:600,opacity:l?.7:1})}">${Nn(e.title)}</div>`),e.department&&f.push(`<div style="${Pn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-size":`${On.department*i}px`,"line-height":1.4,color:o,"font-weight":600,"letter-spacing":`0.2px`})}">${Nn(e.department)}</div>`),d.push(`<div style="${Pn({"min-width":0,"flex-grow":1,"max-height":`100%`,overflow:`hidden`,padding:`6px 0`,"box-sizing":`border-box`,"text-align":a})}">${f.join(``)}</div>`),`<div style="${Pn({...c,display:`flex`,"align-items":`center`,gap:`10px`,padding:`0 10px 0 14px`,border:`1px solid ${r.border}`,"border-radius":`25px`,background:r.card,color:r.text})}"><div style="${Pn({position:`absolute`,left:0,top:0,bottom:0,width:`5px`,background:o})}"></div>${d.join(``)}</div>`}function Bn(e,t){let n=e.color||En;return`<div style="${Pn({"box-sizing":`border-box`,width:`100%`,height:`100%`,"border-radius":`30px`,border:`2px ${t?`solid`:`dashed`} ${n}`,background:`${n}14`,"font-family":`inherit`})}"><div style="${Pn({height:`${pn.header}px`,display:`flex`,"align-items":`center`,padding:`0 16px`})}"><div style="${Pn({"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`,"font-weight":700,"font-size":`14px`,color:n})}">${Nn(e.name)}</div></div></div>`}var Vn=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),G=e(((e,t)=>{t.exports=Vn()}))(),K=(0,l.createContext)({tenant:``,apiUrl:`/api`,locale:``,settings:null,revision:0}),Hn=(0,l.createContext)(null),Un=e=>{let t=Number(e?.__page);if(Number.isFinite(t)&&t>=1)return Math.floor(t);if(typeof window>`u`)return 1;let n=Number(new URLSearchParams(window.location.search).get(`page`));return Number.isFinite(n)&&n>=1?Math.floor(n):1},Wn=()=>{if(typeof window>`u`)return{};let e={};return new URLSearchParams(window.location.search).forEach((t,n)=>{n.startsWith(`f_`)&&n.length>2&&t!==``&&(e[n.slice(2)]=t)}),e},Gn=e=>{let t={...e&&typeof e==`object`&&!Array.isArray(e)?e:{},...Wn()};return Object.fromEntries(Object.entries(t).filter(([,e])=>typeof e==`string`&&e.trim()!==``))},Kn=(0,l.createContext)(null),q=(...e)=>({"data-wb-part":e.filter(Boolean).join(` `)}),qn=(0,l.createContext)(null);function Jn(e,t){if(!t)return[];let n=tr(e?.data,t);return(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id:e).filter(e=>e!=null&&e!==``).map(String)}function Yn(e,t,n){if(!t||!n||!Array.isArray(e))return[];let r=String(n.id??``);return r?e.filter(e=>Jn(e,t).includes(r)):[]}function Xn(e,t,n){return!e||!t?[]:vo(tr(e.data,t)).map((r,i)=>({...e,id:`${e.id??`entry`}:${t}:${i}`,data:{...e.data??{},[t]:wo(r,n?.[r],i)}}))}var Zn=e=>rr(e).trim().toLowerCase();function Qn(e,t){let n=Array.isArray(e?.rules)?e.rules.filter(e=>e&&e.op):[];if(!n.length||!t?.entry)return!0;let r=e=>{if(e.op===`children`||e.op===`nochildren`){let n=Yn(t.all,t.parentField,t.entry).length>0;return e.op===`children`?n:!n}let n=tr(t.entry.data,e.field),r=Zn(n),i=String(e.value??``).trim().toLowerCase(),a=(Array.isArray(n)?n:[n]).map(e=>e&&typeof e==`object`?e.id??e.code:null).filter(e=>e!=null).map(e=>String(e).toLowerCase()),o=Array.isArray(n)?n.length>0:r!==``;switch(e.op){case`set`:return o;case`empty`:return!o;case`eq`:return r===i||a.includes(i);case`neq`:return r!==i&&!a.includes(i);case`contains`:return i===``||r.includes(i);default:return!0}};return e.match===`any`?n.some(r):n.every(r)}function $n({showWhen:e,children:t}){return Qn(e,(0,l.useContext)(qn))?t:null}var er=e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);function tr(e,t){if(t)return t.includes(`.`)?t.split(`.`).reduce((e,t)=>e&&typeof e==`object`?e[t]:void 0,e):e?.[t]}var nr=e=>{let t=[];for(let[n,r]of Object.entries(e??{})){if(!/^[\w-]+$/.test(n))continue;t.push(n);let e=Array.isArray(r)?r[0]:r,i=Array.isArray(r)?`${n}.0`:n;if(e&&typeof e==`object`&&!Array.isArray(e))for(let n of Object.keys(e))/^[\w-]+$/.test(n)&&t.push(`${i}.${n}`)}return t};function rr(e){return e==null?``:typeof e==`string`||typeof e==`number`||typeof e==`boolean`?String(e):typeof e==`object`&&!Array.isArray(e)&&(`label`in e||`name`in e||`slug`in e)?String(e.label??e.name??e.slug??``):typeof e==`object`&&!Array.isArray(e)&&Number.isFinite(Number(e.lat))&&Number.isFinite(Number(e.lng))?`${e.lat}, ${e.lng}`:Array.isArray(e)?e.map(e=>typeof e==`string`?e:Array.isArray(e?.parts)?e.parts.map(e=>e?.text??``).join(``):Array.isArray(e?.items)?e.items.map(e=>e?.text??``).join(` `):e&&(e.label!=null||e.name!=null||e.slug!=null)?String(e.label??e.name??e.slug):``).filter(Boolean).join(` `):``}var ir=new Set([`href`,`src`,`poster`,`backgroundImage`]),ar=[`created_at`,`updated_at`,`publish_at`],or=[`date`,`short`,`iso`,`datetime`,`time`],sr={date:{dateStyle:`long`},short:{day:`2-digit`,month:`2-digit`,year:`numeric`},datetime:{dateStyle:`long`,timeStyle:`short`},time:{timeStyle:`short`}},cr=e=>String(e).padStart(2,`0`);function lr(e,t=`date`,n){if(typeof e!=`string`&&!(e instanceof Date))return``;let r=typeof e==`string`?e.match(/^(\d{4})-(\d{2})-(\d{2})$/):null,i=r?new Date(Number(r[1]),Number(r[2])-1,Number(r[3])):new Date(e);if(Number.isNaN(i.getTime()))return``;if(t===`iso`)return`${i.getFullYear()}-${cr(i.getMonth()+1)}-${cr(i.getDate())}`;try{return new Intl.DateTimeFormat(n||void 0,sr[t]??sr.date).format(i)}catch{return i.toISOString()}}function ur(e,t,n){let r=t?.data??{},i=nr(r),a=[...or].sort((e,t)=>t.length-e.length).join(`|`),o=[...i.map(er).map(e=>`${e}(?:\\.(?:${a}))?`),...ar.filter(e=>!i.includes(e)).map(e=>`${e}(?:\\.(?:${a}))?`)],s=RegExp(`:(${o.sort((e,t)=>t.length-e.length).join(`|`)})`,`g`),c=e=>{if(i.includes(e))return rr(tr(r,e));let[,o,s]=e.match(RegExp(`^(.*?)(?:\\.(${a}))?$`));if(!i.includes(o)&&ar.includes(o))return lr(t?.[o],s||`date`,n);let c=tr(r,o);return s?lr(c,s,n):rr(c)},l=e=>{let t=e.match(RegExp(`^:(${o.sort((e,t)=>t.length-e.length).join(`|`)})$`)),n=t?tr(r,t[1]):void 0;return Array.isArray(n)&&n.length?rr(n[0]):e.replace(s,(e,t)=>c(t))},u=(e,t)=>typeof e==`string`&&ir.has(t)?l(e):typeof e==`string`?e.replace(s,(e,t)=>c(t)):Array.isArray(e)?e.map(e=>u(e)):e&&typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,u(t,e)])):e;return u(e)}var dr=[`Top`,`Right`,`Bottom`,`Left`],fr=[`TopLeft`,`TopRight`,`BottomRight`,`BottomLeft`];function pr(e){let t={},n=(n,r)=>{n in e||(t[n]=r)};for(let[r,i]of Object.entries(e))if(r===`margin`||r===`padding`){let[e,t=e,a=e,o=t]=typeof i==`number`?[i]:String(i).trim().split(/\s+/);[e,t,a,o].forEach((e,t)=>n(`${r}${dr[t]}`,e))}else if(r===`borderRadius`&&(typeof i==`number`||!/\s|\//.test(String(i))))fr.forEach(e=>n(`border${e}Radius`,i));else if(r===`border`){let[e,t,...r]=String(i).trim().split(/\s+/);dr.forEach(i=>{n(`border${i}Width`,e),n(`border${i}Style`,t),n(`border${i}Color`,r.join(` `))})}else r===`background`&&!/(gradient|url)\(/i.test(String(i))?n(`backgroundColor`,i):t[r]=i;return t}var mr=pr({margin:0,fontWeight:700,lineHeight:1.2,fontFamily:`var(--page-heading-font, inherit)`}),hr=Ie,gr=e=>`var(--page-${e}, ${Ie[e]??Ie.h2}px)`,_r=pr({margin:0,fontSize:`var(--page-body-size, 16px)`}),vr={display:`inline-block`,textDecoration:`none`,cursor:`pointer`,backgroundColor:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`},yr={flexGrow:1,display:`flex`,flexDirection:`column`,position:`relative`},br={display:`flex`,flexDirection:`column`};function xr({style:e}){let t=e?.backgroundVideo;if(!t)return null;let n={position:`absolute`,inset:0,width:`100%`,height:`100%`,zIndex:-1,pointerEvents:`none`},r=e?.overlayColor?`color-mix(in srgb, ${e.overlayColor} ${e.overlayOpacity??50}%, transparent)`:null;return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`video`,{src:t,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{...n,objectFit:`cover`}}),r&&(0,G.jsx)(`div`,{style:{...n,background:r}})]})}var Sr=(e,t)=>e?.backgroundVideo?{position:`relative`,...t,...z(e)}:{...t,...z(e)};function Cr({style:e,nodeRef:t,children:n}){return(0,G.jsxs)(`div`,{ref:t,style:{...yr,...z(e)},children:[(0,G.jsx)(xr,{style:e}),n]})}function wr({style:e,nodeRef:t,children:n}){return(0,G.jsxs)(`section`,{ref:t,style:Sr(e,br),children:[(0,G.jsx)(xr,{style:e}),n]})}function Tr({style:e,freeLayout:t,nodeRef:n,children:r}){let i=t?{position:`relative`,minHeight:240}:null;return(0,G.jsxs)(`div`,{ref:n,style:i?{...i,...Sr(e)}:Sr(e),children:[(0,G.jsx)(xr,{style:e}),r]})}function Er({href:e,target:t,style:n,nodeRef:r,children:i}){return(0,G.jsxs)(`a`,{ref:r,href:e||`#`,target:t||void 0,rel:t===`_blank`?`noopener noreferrer`:void 0,style:{...qr,...Sr(n)},children:[(0,G.jsx)(xr,{style:n}),i]})}function Dr({text:e,parts:t,tag:n=`h2`,style:r,linked:i,nodeRef:a}){return(0,G.jsx)(n,{ref:a,style:{...mr,fontSize:gr(n),...z(r)},children:jr(t,e,i)})}var Or={fontFamily:ze.mono.value,background:`rgba(148, 163, 184, 0.18)`,padding:`1px 5px`,borderRadius:4,fontSize:`0.9em`},kr=pr({fontFamily:ze.mono.value,background:`rgba(148, 163, 184, 0.16)`,border:`1px solid rgba(148, 163, 184, 0.3)`,borderRadius:6,padding:`12px 14px`,fontSize:`0.875em`,lineHeight:1.55,overflowX:`auto`,whiteSpace:`pre`});function Ar(e,t=[],n,r,i=!1){let a=e;return t.includes(`sup`)?a=(0,G.jsx)(`sup`,{children:a}):t.includes(`sub`)&&(a=(0,G.jsx)(`sub`,{children:a})),t.includes(`code`)&&(a=(0,G.jsx)(`code`,{style:Or,children:a})),t.includes(`strike`)&&(a=(0,G.jsx)(`s`,{children:a})),t.includes(`underline`)&&(a=(0,G.jsx)(`u`,{children:a})),t.includes(`italic`)&&(a=(0,G.jsx)(`em`,{children:a})),t.includes(`bold`)&&(a=(0,G.jsx)(`strong`,{children:a})),n?a=(0,G.jsx)(`a`,{href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":i?void 0:``,style:{...i&&{color:`inherit`},...t.includes(`nounderline`)&&{textDecoration:`none`}},children:a}):t.includes(`nounderline`)&&(a=(0,G.jsx)(`span`,{style:{textDecoration:`none`},children:a})),a}function jr(e,t,n){return e?.length?e.map((e,t)=>{if(e.slot)return(0,G.jsx)(l.Fragment,{children:n?.[e.slot]??null},t);if(e.parts)return(0,G.jsx)(l.Fragment,{children:jr(e.parts,``,n)},t);if(e.br)return(0,G.jsx)(`br`,{},t);let r=e.text;return e.image&&(r=(0,G.jsx)(`img`,{src:e.image.src,alt:e.image.alt||``,title:e.image.title||void 0,style:{maxWidth:`100%`,verticalAlign:`middle`}})),e.sup?r=(0,G.jsx)(`sup`,{children:r}):e.sub&&(r=(0,G.jsx)(`sub`,{children:r})),e.code&&(r=(0,G.jsx)(`code`,{style:Or,children:r})),e.strike&&(r=(0,G.jsx)(`s`,{children:r})),e.underline&&(r=(0,G.jsx)(`u`,{children:r})),e.italic&&(r=(0,G.jsx)(`em`,{children:r})),e.bold&&(r=(0,G.jsx)(`strong`,{children:r})),(e.color||e.background)&&(r=(0,G.jsx)(`span`,{style:{...e.color&&{color:e.color},...e.background&&{backgroundColor:e.background}},children:r})),e.href?r=(0,G.jsx)(`a`,{href:e.href,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,"data-wb-link":``,style:{...e.color&&{color:e.color},...e.nounderline&&{textDecoration:`none`}},children:r}):e.nounderline&&(r=(0,G.jsx)(`span`,{style:{textDecoration:`none`},children:r})),(0,G.jsx)(l.Fragment,{children:r},t)}):t}function Mr({parts:e,text:t,marks:n,href:r,target:i,style:a}){return(0,G.jsx)(`span`,{style:z(a),children:e?.length?jr(e,t):Ar(t,n,r,i,!!z(a)?.color)})}var Nr=[`left`,`center`,`right`,`justify`];function Pr(e,t,n){let r=e&&e.cellStyles;if(!r||typeof r!=`object`||Array.isArray(r))return{};let i=r[`${t}:${n}`];return i&&typeof i==`object`&&!Array.isArray(i)?i:{}}function Fr(e,t){let n=e||{},r=typeof n.bold==`boolean`?n.bold:!!t;return{textAlign:Nr.includes(n.align)?n.align:`left`,fontWeight:r?700:400,fontStyle:n.italic?`italic`:void 0,color:typeof n.color==`string`&&n.color?n.color:void 0,backgroundColor:typeof n.bg==`string`&&n.bg?n.bg:void 0}}function Ir({align:e=`center`,width:t,wrap:n}={}){let r=t?`${t}%`:void 0;if(e===`full`)return{width:`100%`};let i=e===`left`||e===`right`;return i&&(n??!0)?{float:e,width:r??`50%`,maxWidth:`100%`,marginTop:`4px`,marginBottom:`12px`,...e===`left`?{marginRight:`20px`,marginLeft:0}:{marginLeft:`20px`,marginRight:0}}:i?{width:r??`fit-content`,maxWidth:`100%`,...e===`left`?{marginLeft:0,marginRight:`auto`}:{marginLeft:`auto`,marginRight:0}}:{width:r??`fit-content`,maxWidth:`100%`,marginLeft:`auto`,marginRight:`auto`}}var Lr={red:`#e03131`,orange:`#e8590c`,yellow:`#c98a00`,blue:`#1c7ed6`,purple:`#7048e8`,pink:`#d6336c`,green:`#2f9e44`,grey:`#868e96`},Rr={red:`rgba(224, 49, 49, 0.12)`,orange:`rgba(232, 89, 12, 0.12)`,yellow:`rgba(201, 138, 0, 0.15)`,blue:`rgba(28, 126, 214, 0.12)`,purple:`rgba(112, 72, 232, 0.12)`,pink:`rgba(214, 51, 108, 0.12)`,green:`rgba(47, 158, 68, 0.12)`,grey:`rgba(134, 142, 150, 0.16)`};function zr(e){let t=Lr[e?.color]??(e?.color||``),n=Rr[e?.background]??(e?.background||``);return{...t&&{color:t},...n&&{backgroundColor:n,padding:`8px 12px`,borderRadius:`8px`}}}function Br(e=[],t,n){let r=n??((e,n)=>jr(e,n,t));return e.map((n,i)=>{let a={marginTop:0,marginBottom:i===e.length-1?0:14};if(n.type===`image`){if(!n.src)return null;let e=(0,G.jsx)(`img`,{...q(`image`),src:n.src,alt:n.alt||``,style:{width:`100%`,display:`block`,borderRadius:6}});return(0,G.jsxs)(`figure`,{...q(`figure`),style:{marginLeft:0,marginRight:0,...a,...Ir(n)},children:[n.href?(0,G.jsx)(`a`,{href:n.href,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`},children:e}):e,n.caption&&(0,G.jsx)(`figcaption`,{...q(`caption`),style:{fontSize:13,opacity:.65,marginTop:6,textAlign:`center`},children:n.caption})]},i)}if(n.type===`video`)return ti(n.url)?(0,G.jsx)(`div`,{...q(`video`),style:{...a,...Ir({align:n.align,wrap:n.wrap,width:n.width??100})},children:(0,G.jsx)(ni,{url:n.url,autoplay:n.autoplay,muted:n.muted,loop:n.loop,controls:n.controls??!0,start:n.start})},i):null;if(n.type===`button`){if(!(typeof n.label==`string`&&n.label.trim()))return null;let e=Number.isFinite(Number(n.radius))?Number(n.radius):8,t=[`center`,`right`].includes(n.align)?n.align:`left`;return(0,G.jsx)(`div`,{style:{...a,textAlign:t},children:(0,G.jsx)(`table`,{role:`presentation`,cellPadding:0,cellSpacing:0,style:{borderCollapse:`separate`,display:`inline-table`},children:(0,G.jsx)(`tbody`,{children:(0,G.jsx)(`tr`,{children:(0,G.jsx)(`td`,{style:{backgroundColor:n.bg||`var(--page-accent, #4f46e5)`,borderRadius:e},children:(0,G.jsx)(`a`,{...q(`button`),href:n.href||`#`,target:n.target||void 0,rel:n.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`inline-block`,padding:`13px 24px`,color:n.color||`#ffffff`,fontSize:15,fontWeight:600,lineHeight:1.2,textDecoration:`none`,borderRadius:e},children:n.label})})})})})},i)}if(n.type===`divider`)return(0,G.jsx)(`hr`,{...q(`divider`),style:{...a,border:0,borderTop:`1px solid rgba(148, 163, 184, 0.4)`}},i);if(n.type===`table`){let e=Array.isArray(n.rows)?n.rows.filter(Array.isArray):[];if(!e.length)return null;let t=n.header!==!1,o=n.borders===!1?void 0:`1px solid rgba(148, 163, 184, 0.4)`,s=Number.isFinite(n.padX)?Math.max(0,n.padX):10,c=Number.isFinite(n.padY)?Math.max(0,n.padY):6,l=Math.max(0,Number(n.spacing)||0),u={border:o,padding:`${c}px ${s}px`,verticalAlign:`top`},d=Array.isArray(n.heights)?n.heights:null,f=e=>{let t=Number(d?.[e]);return Number.isFinite(t)&&t>0?{height:`${t}px`}:void 0},p=t?e.slice(1):e,m=Array.isArray(n.widths)?n.widths:null,h=(e,t,r)=>({...u,...Fr(Pr(n,e,t),r)}),g=n.spans&&typeof n.spans==`object`?n.spans:null,_=new Set;g&&e.forEach((e,t)=>e.forEach((e,n)=>{let r=g[`${t}:${n}`];if(!r)return;let i=Math.max(1,Number(r.c)||1),a=Math.max(1,Number(r.r)||1);for(let e=0;e<a;e+=1)for(let r=0;r<i;r+=1)(e||r)&&_.add(`${t+e}:${n+r}`)}));let v=(e,t)=>{let n=g?.[`${e}:${t}`],r=Math.max(1,Number(n?.c)||1),i=Math.max(1,Number(n?.r)||1);return{colSpan:r>1?r:void 0,rowSpan:i>1?i:void 0}};return(0,G.jsxs)(`table`,{...q(`table`),style:{...a,borderCollapse:l?`separate`:`collapse`,borderSpacing:l?`${l}px`:void 0,width:`100%`,fontSize:_r.fontSize,tableLayout:m?`fixed`:void 0},children:[typeof n.caption==`string`&&n.caption.trim()?(0,G.jsx)(`caption`,{...q(`caption`),style:{captionSide:`top`,textAlign:`left`,fontWeight:600,padding:`0 0 6px`},children:n.caption}):null,m&&(0,G.jsx)(`colgroup`,{children:m.map((e,t)=>(0,G.jsx)(`col`,{style:{width:`${e}%`}},t))}),t&&(0,G.jsx)(`thead`,{children:(0,G.jsx)(`tr`,{...q(`header-row`),style:f(0),children:e[0].map((e,t)=>_.has(`0:${t}`)?null:(0,G.jsx)(`th`,{...q(`header-cell`),scope:`col`,style:h(0,t,!0),...v(0,t),children:Array.isArray(e)?r(e):e},t))})}),(0,G.jsx)(`tbody`,{children:p.map((e,n)=>(0,G.jsx)(`tr`,{...q(`row`),style:f(t?n+1:n),children:e.map((e,i)=>{let a=t?n+1:n;return _.has(`${a}:${i}`)?null:(0,G.jsx)(`td`,{...q(`cell`),style:h(a,i,!1),...v(a,i),children:Array.isArray(e)?r(e):e},i)})},n))})]},i)}if(n.type===`ul`||n.type===`ol`){let e=n.type;return(0,G.jsx)(e,{...q(`list`,n.type===`ol`&&`list-ordered`),style:{fontSize:_r.fontSize,...a,...zr(n),paddingLeft:n.background?34:24},start:n.type===`ol`?n.start:void 0,children:(n.items??[]).map((e,n)=>{let i=typeof e.task==`boolean`;return(0,G.jsxs)(`li`,{...q(`list-item`),style:{marginBottom:4,...i&&{listStyleType:`none`,marginLeft:-18}},children:[i&&(0,G.jsx)(`span`,{style:{marginRight:6},children:e.task?`☑`:`☐`}),r(e.parts,e.text),e.blocks?.length?Br(e.blocks,t,r):null]},n)})},i)}if(n.type===`quote`)return(0,G.jsx)(`blockquote`,{...q(`quote`),style:{...Ur,fontSize:_r.fontSize,...a,...zr(n),...n.background&&{paddingLeft:20}},children:n.blocks?.length?Br(n.blocks,t,r):r(n.parts,n.text)},i);if(n.type===`code`)return(0,G.jsx)(`pre`,{...q(`code`),"data-lang":n.lang||void 0,style:{...a,...kr},children:(0,G.jsx)(`code`,{style:{fontFamily:`inherit`},children:n.text})},i);if(hr[n.type]){let e=n.type;return(0,G.jsx)(e,{...q(`heading`,`heading-${n.type}`),style:{...mr,fontSize:gr(n.type),...a,...zr(n)},children:r(n.parts,n.text)},i)}return(0,G.jsx)(`p`,{...q(`paragraph`),style:{..._r,...a,...zr(n)},children:r(n.parts,n.text)},i)})}function Vr({content:e,style:t,linked:n,nodeRef:r}){return(0,G.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(t)},children:Br(e,n)})}function Hr({markdown:e,newTab:t,style:n,nodeRef:r}){let i=(0,l.useMemo)(()=>rn(e,{newTab:t}),[e,t]);return(0,G.jsx)(`div`,{ref:r,style:{display:`flow-root`,...z(n)},children:Br(i)})}var Ur=pr({margin:0,padding:`8px 0 8px 20px`,borderLeftWidth:`4px`,borderLeftStyle:`solid`,borderLeftColor:`var(--page-accent, rgba(148, 163, 184, 0.6))`});function Wr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,G.jsx)(`blockquote`,{ref:i,style:{...Ur,...z(n)},children:jr(t,e,r)})}function Gr({ordered:e,items:t=[],style:n,nodeRef:r}){return(0,G.jsx)(e?`ol`:`ul`,{ref:r,style:{margin:0,paddingLeft:24,...z(n)},children:t.map((e,t)=>(0,G.jsx)(`li`,{...q(`item`),style:{marginBottom:4},children:jr(e.parts,e.text)},t))})}function Kr({text:e,parts:t,style:n,linked:r,nodeRef:i}){return(0,G.jsx)(`p`,{ref:i,style:{..._r,...z(n)},children:jr(t,e,r)})}var qr={display:`block`,color:`inherit`,textDecoration:`none`,cursor:`pointer`},Jr={textUnderlineOffset:3,cursor:`pointer`};function Yr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,G.jsx)(`a`,{ref:o,"data-wb-link":``,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...Jr,...z(i)},children:jr(t,e,a)})}function Xr({text:e,parts:t,href:n,target:r,style:i,linked:a,nodeRef:o}){return(0,G.jsx)(`a`,{ref:o,href:n||`#`,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:{...vr,...z(i)},children:jr(t,e,a)})}function Zr({src:e,alt:t,decorative:n,style:r,nodeRef:i}){return e?(0,G.jsx)(`img`,{ref:i,src:e,alt:n?``:t||``,role:n?`presentation`:void 0,style:{display:`block`,maxWidth:`100%`,...z(r)}}):null}function Qr({text:e,locale:t}){let n=String(e??``).trim();return n?(0,G.jsxs)(`details`,{...q(`transcript`),style:{marginTop:8,fontSize:14},children:[(0,G.jsx)(`summary`,{...q(`transcript-toggle`),style:{cursor:`pointer`,fontWeight:600},children:at(t)(`transcript`)}),(0,G.jsx)(`div`,{...q(`transcript-text`),style:{marginTop:8,lineHeight:1.6},children:n.split(/\n\s*\n/).map((e,t)=>(0,G.jsx)(`p`,{style:{margin:`0 0 8px`,whiteSpace:`pre-line`},children:e},t))})]}):null}var $r=e=>(Array.isArray(e)?e:[]).filter(e=>typeof e?.src==`string`&&e.src.trim());function ei({src:e,poster:t,controls:n=!0,autoplay:r=!1,loop:i=!1,muted:a=!1,title:o=``,tracks:s,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(K);if(!e)return null;let p=$r(s),m=typeof o==`string`&&o.trim()?o.trim():void 0,h=typeof c==`string`&&c.trim(),g=(0,G.jsx)(`video`,{ref:h?void 0:d,...h?{"data-wb-self":``}:{},src:e,poster:t||void 0,controls:n,"aria-label":m,autoPlay:r,muted:a||r,loop:i,playsInline:!0,crossOrigin:p.length?`anonymous`:void 0,style:{display:`block`,width:`100%`,maxWidth:`100%`,...z(u)},children:p.map((e,t)=>(0,G.jsx)(`track`,{kind:e.kind===`captions`?`captions`:`subtitles`,src:e.src,srcLang:e.srclang||void 0,label:e.label||e.srclang||void 0,default:e.default?!0:void 0},e.key??t))});return h?(0,G.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[g,(0,G.jsx)(Qr,{text:c,locale:f})]}):g}var ti=(e=``)=>(e.match(/(?:youtu\.be\/|v=|embed\/|shorts\/|live\/)([\w-]{11})/)||e.match(/^([\w-]{11})$/))?.[1];function ni({url:e,autoplay:t=!1,muted:n=!1,loop:r=!1,controls:i=!0,start:a,title:o=``,captions:s=!1,transcript:c=``,style:u,nodeRef:d}){let{locale:f}=(0,l.useContext)(K),p=ti(e);if(!p)return null;let m=new URLSearchParams({rel:`0`});if(t&&m.set(`autoplay`,`1`),(n||t)&&m.set(`mute`,`1`),i||m.set(`controls`,`0`),r&&(m.set(`loop`,`1`),m.set(`playlist`,p)),Number(a)>0&&m.set(`start`,String(Math.floor(Number(a)))),s){m.set(`cc_load_policy`,`1`);let e=String(f||``).split(/[-_]/)[0];e&&m.set(`cc_lang_pref`,e)}let h=(0,G.jsx)(`iframe`,{...q(`frame`),src:`https://www.youtube-nocookie.com/embed/${p}?${m}`,title:typeof o==`string`&&o.trim()?o.trim():at(f)(`video`),allow:`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share`,allowFullScreen:!0,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,border:0}});return typeof c==`string`&&c.trim()?(0,G.jsxs)(`div`,{ref:d,"data-wb-redirect":``,style:{width:`100%`},children:[(0,G.jsx)(`div`,{"data-wb-self":``,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h}),(0,G.jsx)(Qr,{text:c,locale:f})]}):(0,G.jsx)(`div`,{ref:d,style:{position:`relative`,width:`100%`,paddingTop:`56.25%`,...z(u)},children:h})}function ri({src:e,title:t,allowFullscreen:n=!0,style:r,nodeRef:i}){let{locale:a}=(0,l.useContext)(K);return e?(0,G.jsx)(`iframe`,{ref:i,src:e,title:t||at(a)(`frame`),loading:`lazy`,allowFullScreen:n,style:{display:`block`,width:`100%`,height:300,border:0,...z(r)}}):null}function ii(e,{toolbar:t=!0,page:n,zoom:r}={}){let i=Et(e);if(!i)return``;let a=[];return t===!1&&a.push(`toolbar=0&navpanes=0`),Number(n)>1&&a.push(`page=${Number(n)}`),r&&r!==`auto`&&a.push(`zoom=${r}`),a.length?`${i.split(`#`)[0]}#${a.join(`&`)}`:i}function ai({src:e,title:t,toolbar:n=!0,page:r,zoom:i=`auto`,link:a=!0,linkLabel:o,fallbackText:s,style:c,nodeRef:l}){let u=Et(e);if(!u)return null;let d=o||`Open the PDF`,f=t||`PDF document`;return(0,G.jsxs)(`div`,{ref:l,style:{display:`flex`,flexDirection:`column`,width:`100%`,height:600,...z(c)},children:[(0,G.jsx)(`object`,{data:ii(u,{toolbar:n,page:r,zoom:i}),type:`application/pdf`,"aria-label":f,...q(`document`),style:{display:`block`,flex:`1 1 auto`,minHeight:0,width:`100%`,border:0},children:(0,G.jsxs)(`div`,{...q(`fallback`),style:{display:`grid`,placeItems:`center`,gap:8,height:`100%`,padding:16,textAlign:`center`},children:[(0,G.jsx)(`p`,{style:{..._r,opacity:.75},children:s||`This browser can’t show the PDF here.`}),!a&&(0,G.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,style:{color:`var(--page-accent, inherit)`},children:d})]})},ii(u,{toolbar:n,page:r,zoom:i})),a&&(0,G.jsx)(`a`,{href:u,target:`_blank`,rel:`noopener noreferrer`,...q(`link`),style:{flexShrink:0,marginTop:8,color:`var(--page-accent, inherit)`,fontSize:14},children:d})]})}var oi=/(^|[\s,>+~{}])(:root|html|body)(?=$|[\s,{.:#[>+~])/g;function si(e){return`@scope ([data-wb-embed]) {\n${e.replace(oi,`$1:scope`)}\n}`}function ci({code:e,runScripts:t=!0,scopeStyles:n=!1,style:r,nodeRef:i}){let[a,o]=(0,l.useState)(null);return(0,l.useEffect)(()=>{a&&(a.innerHTML=e||``,n?(a.setAttribute(`data-wb-embed`,``),a.querySelectorAll(`style`).forEach(e=>{e.textContent=si(e.textContent||``)})):a.removeAttribute(`data-wb-embed`),t&&a.querySelectorAll(`script`).forEach(e=>{let t=document.createElement(`script`);for(let{name:n,value:r}of e.attributes)t.setAttribute(n,r);t.text=e.textContent,e.replaceWith(t)}))},[a,e,t,n]),(0,G.jsx)(`div`,{ref:e=>{o(e),i&&i(e)},style:z(r)})}function li({height:e,style:t,nodeRef:n}){return(0,G.jsx)(`div`,{ref:n,style:{height:e||32,flexShrink:0,alignSelf:`stretch`,...z(t)}})}function ui({style:e,nodeRef:t}){return(0,G.jsx)(`div`,{ref:t,style:{height:1,alignSelf:`stretch`,flexShrink:0,...z(e)}})}function di({style:e,nodeRef:t}){return(0,G.jsx)(`div`,{ref:t,style:{flexShrink:0,...z(e)}})}var fi={position:`absolute`,top:`50%`,transform:`translateY(-50%)`,width:36,height:36,borderRadius:`50%`,border:0,cursor:`pointer`,background:`rgba(17, 24, 39, 0.45)`,color:`#fff`,fontSize:20,lineHeight:1,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:0},pi={bottom:{inset:`auto 0 0 0`,padding:`40px 24px 20px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.55))`},top:{inset:`0 0 auto 0`,padding:`20px 24px 40px`,background:`linear-gradient(rgba(0, 0, 0, 0.55), transparent)`},middle:{inset:0,display:`flex`,flexDirection:`column`,justifyContent:`center`,padding:24,textShadow:`0 2px 12px rgba(0, 0, 0, 0.6)`}},mi=48;function hi({count:e,renderSlide:t,autoplay:n=!0,interval:r=5,height:i=320,swipe:a=!0,style:o,nodeRef:s}){let[c,u]=(0,l.useState)(0),[d,f]=(0,l.useState)(!1),[p,m]=(0,l.useState)(!1),[h,g]=(0,l.useState)(!1),[_,v]=(0,l.useState)(null),{locale:y}=(0,l.useContext)(K),b=e?Math.min(c,e-1):0;if((0,l.useEffect)(()=>{window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches&&g(!0)},[]),(0,l.useEffect)(()=>{if(!n||h||d||p||_||e<2)return;let t=setInterval(()=>u(t=>(t+1)%e),Math.max(2,Number(r)||5)*1e3);return()=>clearInterval(t)},[n,h,d,p,_,r,e]),!e)return null;let x=at(y),S=t=>u((t+e)%e),C=()=>{if(!_)return;let{dx:e}=_;v(null),e<-48?S(b+1):e>mi&&S(b-1)};return(0,G.jsxs)(`div`,{ref:s,role:`region`,"aria-roledescription":`carousel`,onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1),onFocus:()=>m(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||m(!1)},onPointerDown:a&&e>1?e=>{e.pointerType===`mouse`&&e.button!==0||e.target.closest(`button`)||(e.currentTarget.setPointerCapture(e.pointerId),v({startX:e.clientX,dx:0}))}:void 0,onPointerMove:_?e=>v(t=>t&&{...t,dx:e.clientX-t.startX}):void 0,onPointerUp:C,onPointerCancel:C,style:{position:`relative`,overflow:`hidden`,width:`100%`,height:i,touchAction:`pan-y`,userSelect:_?`none`:void 0,cursor:_?`grabbing`:void 0,...z(o)},children:[(0,G.jsx)(`div`,{...q(`track`),style:{display:`flex`,height:`100%`,transform:`translateX(calc(${-b*100}% + ${_?.dx??0}px))`,transition:_?`none`:`transform 450ms ease`},children:Array.from({length:e},(n,r)=>(0,G.jsx)(`div`,{...q(`slide`,r===b&&`slide-active`),role:`group`,"aria-roledescription":`slide`,"aria-label":x(`slide`,{n:r+1,total:e}),"aria-hidden":r!==b||void 0,inert:r!==b||void 0,style:{position:`relative`,width:`100%`,flexShrink:0,overflow:`hidden`},children:t(r)},r))}),e>1&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`button`,{type:`button`,...q(`arrow`,`arrow-prev`),"aria-label":x(`prevSlide`),style:{...fi,left:12},onClick:()=>S(b-1),children:`‹`}),(0,G.jsx)(`button`,{type:`button`,...q(`arrow`,`arrow-next`),"aria-label":x(`nextSlide`),style:{...fi,right:12},onClick:()=>S(b+1),children:`›`}),(0,G.jsx)(`div`,{...q(`dots`),style:{position:`absolute`,bottom:10,left:0,right:0,display:`flex`,justifyContent:`center`,gap:6},children:Array.from({length:e},(e,t)=>(0,G.jsx)(`button`,{type:`button`,"aria-label":x(`goToSlide`,{n:t+1}),"aria-current":t===b?`true`:void 0,...q(`dot`,t===b&&`dot-active`),onClick:()=>S(t),style:{width:8,height:8,borderRadius:`50%`,border:0,padding:0,cursor:`pointer`,background:t===b?`#ffffff`:`rgba(255, 255, 255, 0.45)`}},t))}),n&&(0,G.jsx)(`button`,{type:`button`,...q(`pause`,h&&`pause-stopped`),"aria-label":x(h?`play`:`pause`),onClick:()=>g(!h),style:{...fi,top:`auto`,bottom:8,right:12,transform:`none`,width:28,height:28},children:(0,G.jsx)(`svg`,{viewBox:`0 0 24 24`,width:14,height:14,fill:`currentColor`,"aria-hidden":`true`,children:(0,G.jsx)(`path`,{d:h?`M8 5v14l11-7z`:`M7 5h4v14H7zM13 5h4v14h-4z`})})})]})]})}var gi=(e,t)=>({position:`absolute`,inset:0,backgroundImage:e?`url(${e})`:`none`,backgroundColor:t||(e?void 0:`rgba(148, 163, 184, 0.25)`),backgroundSize:`cover`,backgroundPosition:`center`});function _i({slides:e=[],captionPosition:t=`bottom`,captionAlign:n=`left`,...r}){return e.length?(0,G.jsx)(hi,{...r,count:e.length,renderSlide:r=>{let i=e[r];return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`div`,{...q(`slide-image`),style:gi(i.image)}),(i.title||i.text)&&(0,G.jsxs)(`div`,{...q(`caption`),style:{position:`absolute`,color:`#fff`,textAlign:n,...pi[t]??pi.bottom},children:[i.title&&(0,G.jsx)(`div`,{...q(`caption-title`),style:{fontSize:22,fontWeight:700},children:i.title}),i.text&&(0,G.jsx)(`div`,{...q(`caption-text`),style:{fontSize:14,opacity:.9,marginTop:4},children:i.text})]})]})}}):null}function vi({slides:e=[],linked:t,...n}){return e.length?(0,G.jsx)(hi,{...n,count:e.length,renderSlide:n=>{let r=e[n];return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`div`,{...q(`slide-background`),style:gi(r.image,r.color)}),(0,G.jsx)(`div`,{...q(`slide-content`),style:{position:`absolute`,inset:0,display:`flex`,flexDirection:`column`},children:t?.[r.key]??null})]})}}):null}var yi=256,bi=e=>Math.log(Math.tan(Math.PI/4+Math.max(-85,Math.min(85,e))*Math.PI/360)),xi=(e,t,n)=>{let r=yi*2**n;return{x:(Number(t)+180)/360*r,y:(.5-bi(Number(e))/(2*Math.PI))*r}},Si=(e,t)=>{if(e===``||e==null)return null;let n=Number(e);return Number.isFinite(n)&&Math.abs(n)<=t?n:null},Ci=e=>!!e&&Si(e.lat,90)!==null&&Si(e.lng,180)!==null;function wi(e,t,n=`directions`,r=``){let i=`${e},${t}`;return n===`place`?`https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(i)}${r?`&query_place_id=`:``}`:`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(i)}`}var Ti=`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,J=e=>{let t=String(e??``).trim();return/^https?:\/\//i.test(t)&&t.includes(`{z}`)&&t.includes(`{x}`)&&t.includes(`{y}`)?t:Ti},Ei=e=>{try{return new URL(e.replace(/[{}]/g,``)).host}catch{return e}},Di=(e,t,n=13)=>`https://www.openstreetmap.org/?mlat=${e}&mlon=${t}#map=${Math.round(Number(n)||13)}/${e}/${t}`;function Oi({markers:e,lat:t,lng:n,zoom:r=``,height:i=320,pinSize:a=22,pinLink:o=`directions`,link:s=!1,label:c=``,tileUrl:u=``,tileError:d=``,style:f,nodeRef:p,inert:m}){let h=(0,l.useRef)(null),[g,_]=(0,l.useState)(1200),v=J(u),[y,b]=(0,l.useState)({key:``,failed:0,loaded:0});(0,l.useEffect)(()=>{let e=h.current;if(!e||typeof ResizeObserver>`u`)return;let t=()=>_(t=>e.clientWidth&&e.clientWidth!==t?e.clientWidth:t);t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[]);let x=(Array.isArray(e)?e:[]).filter(Ci),S=Ci({lat:t,lng:n})?{lat:Si(t,90),lng:Si(n,180)}:x.length?{lat:x.reduce((e,t)=>e+Si(t.lat,90),0)/x.length,lng:x.reduce((e,t)=>e+Si(t.lng,180),0)/x.length}:null,C=Math.max(80,Number(i)||320),w=Si(r,19)?Math.min(Math.max(Math.round(Number(r)),1),19):(()=>{if(x.length<2)return 13;for(let e=19;e>=1;e--){let t=x.map(t=>xi(Si(t.lat,90),Si(t.lng,180),e)),n=Math.max(...t.map(e=>e.x))-Math.min(...t.map(e=>e.x)),r=Math.max(...t.map(e=>e.y))-Math.min(...t.map(e=>e.y));if(n<=g*.8&&r<=C*.7)return e}return 1})(),T={width:`100%`,...z(f)};if(!S)return(0,G.jsx)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:{...T,minHeight:80,display:`grid`,placeItems:`center`,fontSize:13,opacity:.6,border:`1px dashed var(--page-border, rgba(148, 163, 184, 0.4))`,borderRadius:8},children:`Set the coordinates in Settings`});let E=xi(S.lat,S.lng,w),D={x:E.x-g/2,y:E.y-C/2},O=[],k=[];for(let e=Math.floor(D.x/yi);e<=Math.floor((D.x+g)/yi);e++)O.push(e);for(let e=Math.floor(D.y/yi);e<=Math.floor((D.y+C)/yi);e++)k.push(e);let A=2**w,j=`${v}|${w}`,M=y.key===j?y:{key:j,failed:0,loaded:0},N=e=>b(t=>{let n=t.key===j?t:{key:j,failed:0,loaded:0};return{...n,[e]:n[e]+1}}),P=M.failed>0&&M.loaded===0;return(0,G.jsxs)(`div`,{ref:e=>{h.current=e,typeof p==`function`&&p(e)},style:T,children:[(0,G.jsxs)(`div`,{role:`img`,"aria-label":c||`Map`,...q(`map`),style:{position:`relative`,height:C,overflow:`hidden`,borderRadius:`inherit`,background:`var(--page-surface, #e5e7eb)`},children:[k.map(e=>O.map(t=>{let n=(t%A+A)%A;return e<0||e>=A?null:(0,G.jsx)(`img`,{src:v.replace(`{z}`,w).replace(`{x}`,n).replace(`{y}`,e),alt:``,onLoad:()=>N(`loaded`),onError:e=>{e.currentTarget.style.visibility=`hidden`,N(`failed`)},width:yi,height:yi,loading:`lazy`,style:{position:`absolute`,left:Math.round(t*yi-D.x),top:Math.round(e*yi-D.y),width:yi,height:yi,userSelect:`none`,pointerEvents:`none`}},`${j}:${t}-${e}`)})),P&&m&&d?(0,G.jsx)(`div`,{style:{...Fe,position:`absolute`,left:12,right:12,top:12,padding:`8px 12px`,borderRadius:8,background:`rgba(15, 23, 42, 0.78)`,color:`#fff`,fontSize:12,lineHeight:1.45},children:d.replace(`{host}`,Ei(v))}):null,x.map((e,t)=>{let n=xi(Si(e.lat,90),Si(e.lng,180),w),r=n.x-D.x,i=n.y-D.y,s=e.color||`var(--page-accent, #dc2626)`,c=o===`none`||m?null:wi(Si(e.lat,90),Si(e.lng,180),o,e.title);return(0,G.jsxs)(c?`a`:`span`,{...q(`pin`),href:c||void 0,target:c?`_blank`:void 0,rel:c?`noopener noreferrer`:void 0,title:c&&e.title||void 0,style:{position:`absolute`,left:r,top:i,transform:`translate(-50%, -100%)`,cursor:c?`pointer`:`default`,textDecoration:`none`,color:`inherit`},children:[e.title?(0,G.jsx)(`span`,{...q(`pin-label`),style:{position:`absolute`,left:`50%`,bottom:`100%`,transform:`translateX(-50%)`,marginBottom:4,padding:`3px 7px`,borderRadius:6,background:`var(--page-surface, #ffffff)`,color:`var(--page-text, #111827)`,border:`1px solid var(--page-border, rgba(148, 163, 184, 0.5))`,boxShadow:`0 2px 8px rgba(15, 23, 42, 0.25)`,fontSize:12,lineHeight:1.35,whiteSpace:`nowrap`},children:e.title}):null,(0,G.jsxs)(`svg`,{width:Math.max(10,Number(a)||22),height:Math.max(10,Number(a)||22),viewBox:`0 0 24 24`,fill:s,style:{display:`block`},children:[(0,G.jsx)(`path`,{d:`M12 22s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11z`}),ki[e.icon]?(0,G.jsx)(`path`,{d:ki[e.icon],transform:`translate(12 10.5) scale(0.46) translate(-12 -12)`,fill:`none`,stroke:`#fff`,strokeWidth:4,strokeLinecap:`round`,strokeLinejoin:`round`}):(0,G.jsx)(`circle`,{cx:`12`,cy:`10.5`,r:`2.6`,fill:`#fff`})]})]},t)}),(0,G.jsx)(`a`,{href:`https://www.openstreetmap.org/copyright`,target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...q(`credit`),style:{position:`absolute`,right:4,bottom:3,padding:`1px 5px`,borderRadius:4,background:`rgba(255, 255, 255, 0.75)`,color:`#334155`,fontSize:10,textDecoration:`none`},children:`© OpenStreetMap`})]}),s?(0,G.jsx)(`a`,{href:Di(S.lat,S.lng,w),target:`_blank`,rel:`noopener noreferrer`,onClick:m?e=>e.preventDefault():void 0,...q(`link`),style:{display:`inline-block`,marginTop:6,fontSize:12,color:`var(--page-accent, inherit)`},children:`View larger map`}):null]})}var ki={check:`M4 12l5 5L20 6`,close:`M6 6l12 12M18 6L6 18`,plus:`M12 5v14M5 12h14`,minus:`M5 12h14`,"arrow-right":`M4 12h16M13 5l7 7-7 7`,"arrow-left":`M20 12H4M11 5l-7 7 7 7`,"arrow-up":`M12 20V4M5 11l7-7 7 7`,"arrow-down":`M12 4v16M5 13l7 7 7-7`,"chevron-right":`M9 5l7 7-7 7`,"chevron-left":`M15 5l-7 7 7 7`,"chevron-down":`M5 9l7 7 7-7`,"chevron-up":`M5 15l7-7 7 7`,menu:`M4 7h16M4 12h16M4 17h16`,star:`M12 3.5l2.6 5.3 5.9.9-4.3 4.1 1 5.8-5.2-2.7-5.2 2.7 1-5.8L3.5 9.7l5.9-.9z`,heart:`M12 20s-7-4.4-7-9a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 4.6-7 9-7 9z`,home:`M4 11l8-7 8 7M6 10v9h12v-9`,user:`M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM4 20c0-3.3 3.6-5 8-5s8 1.7 8 5`,mail:`M3 6h18v12H3zM3 6l9 7 9-7`,phone:`M6 3h4l2 5-3 2a12 12 0 0 0 5 5l2-3 5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 4 5a2 2 0 0 1 2-2z`,search:`M11 4a7 7 0 1 0 0 14 7 7 0 0 0 0-14zM20 20l-4.2-4.2`,clock:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 7v5l3 2`,calendar:`M4 6h16v14H4zM4 10h16M8 3v4M16 3v4`,download:`M12 4v10M8 11l4 4 4-4M4 19h16`,upload:`M12 20V10M8 13l4-4 4 4M4 5h16`,play:`M8 5l11 7-11 7z`,pause:`M9 5v14M15 5v14`,info:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM12 11v5M12 8h.01`,alert:`M12 4l9 16H3zM12 10v4M12 17h.01`,lock:`M6 11h12v9H6zM9 11V8a3 3 0 0 1 6 0v3`,chat:`M4 5h16v11H9l-5 4z`,"map-pin":`M12 21s7-6 7-11a7 7 0 1 0-14 0c0 5 7 11 7 11zM12 12a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5z`,camera:`M4 8h4l2-2h4l2 2h4v12H4zM12 17a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z`,image:`M4 5h16v14H4zM8 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM6 17l5-5 4 4 2-2 3 3`,file:`M7 3h7l4 4v14H7zM14 3v5h4`,link:`M10 14a4 4 0 0 0 6 .5l2-2a4 4 0 0 0-6-6l-1 1M14 10a4 4 0 0 0-6-.5l-2 2a4 4 0 0 0 6 6l1-1`,external:`M14 4h6v6M20 4l-9 9M18 14v5H5V6h5`,trash:`M4 7h16M9 7V5h6v2M6 7l1 13h10l1-13`,edit:`M4 20h4L19 9l-4-4L4 16z`,filter:`M3 5h18l-7 8v6l-4-2v-4z`,refresh:`M20 12a8 8 0 1 1-2.3-5.7M20 4v5h-5`,globe:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM3 12h18M12 3c2.5 3 2.5 15 0 18M12 3c-2.5 3-2.5 15 0 18`,bell:`M6 16V11a6 6 0 1 1 12 0v5l2 3H4zM10 22h4`,tag:`M4 4h7l9 9-7 7-9-9zM8.5 8.5h.01`,cart:`M4 5h2l2 10h10l2-7H7M9 20h.01M18 20h.01`,card:`M3 6h18v12H3zM3 10h18`,shield:`M12 3l8 3v6c0 5-4 8-8 9-4-1-8-4-8-9V6z`,sun:`M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zM12 2v2M12 20v2M4 12H2M22 12h-2M5 5l1.5 1.5M17.5 17.5L19 19M19 5l-1.5 1.5M6.5 17.5L5 19`,moon:`M20 14a8 8 0 1 1-10-10 7 7 0 0 0 10 10z`,settings:`M12 9.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM12 2l1 2.6 2.7-.6 1 2.5 2.6 1-.6 2.7L21 12l-2.3 1.8.6 2.7-2.6 1-1 2.5-2.7-.6L12 22l-1-2.6-2.7.6-1-2.5-2.6-1 .6-2.7L3 12l2.3-1.8-.6-2.7 2.6-1 1-2.5 2.7.6z`,eye:`M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7zM12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z`,"eye-off":`M4 4l16 16M9.5 9.6A3 3 0 0 0 12 15c.8 0 1.5-.3 2.1-.8M6.6 6.7C3.9 8.3 2 12 2 12s4 7 10 7c1.9 0 3.5-.5 4.9-1.2M14.1 5.4C13.4 5.1 12.7 5 12 5`,share:`M8 12a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 6a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM21 18a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0zM7.8 10.8l8.4-3.6M7.8 13.2l8.4 3.6`,send:`M21 3L3 10l7 3 3 7z`,paperclip:`M20 11l-8.5 8.5a5 5 0 0 1-7-7L13 4a3.5 3.5 0 0 1 5 5l-8.5 8.5a2 2 0 0 1-3-3L15 6`,video:`M3 7h11v10H3zM14 11l6-3v8l-6-3`,music:`M9 18V6l10-2v12M9 18a2.5 2.5 0 1 1-2.5-2.5H9M19 16a2.5 2.5 0 1 1-2.5-2.5H19`,mic:`M12 3a3 3 0 0 1 3 3v5a3 3 0 0 1-6 0V6a3 3 0 0 1 3-3zM5 11a7 7 0 0 0 14 0M12 18v3`,headphones:`M4 15v-3a8 8 0 1 1 16 0v3M4 15h3v5H5a1 1 0 0 1-1-1zM20 15h-3v5h2a1 1 0 0 0 1-1z`,book:`M5 4h14v16H7a2 2 0 0 1-2-2zM7 4v14h12`,bookmark:`M7 4h10v16l-5-4-5 4z`,folder:`M4 6h5l2 2h9v10H4z`,cloud:`M7 18a4 4 0 0 1 .5-8 5.5 5.5 0 0 1 10.4 1.5A3.5 3.5 0 0 1 17.5 18z`,database:`M12 3c4.4 0 8 1.3 8 3s-3.6 3-8 3-8-1.3-8-3 3.6-3 8-3zM4 6v12c0 1.7 3.6 3 8 3s8-1.3 8-3V6M4 12c0 1.7 3.6 3 8 3s8-1.3 8-3`,server:`M4 4h16v6H4zM4 14h16v6H4zM8 7h.01M8 17h.01`,code:`M9 8l-5 4 5 4M15 8l5 4-5 4`,terminal:`M4 5h16v14H4zM8 10l3 2-3 2M13 14h4`,wifi:`M5 12a10 10 0 0 1 14 0M8 15a6 6 0 0 1 8 0M12 19h.01`,battery:`M3 8h15v8H3zM21 11v2`,printer:`M7 8V4h10v4M7 16H4V8h16v8h-3M7 13h10v7H7z`,gift:`M4 10h16v10H4zM3 6h18v4H3zM12 6v14M12 6c-2 0-4-1-4-2.5S9 2 10 3s2 3 2 3zM12 6c2 0 4-1 4-2.5S15 2 14 3s-2 3-2 3z`,key:`M15 4a5 5 0 1 0-4.6 7L9 12.4V15H6.5L4 17.5V20h4l7-7A5 5 0 0 0 15 4z`,compass:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM15 9l-2 5-5 2 2-5z`,flag:`M5 21V4h13l-2 4 2 4H5`,award:`M12 4a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM9 13l-1 7 4-2 4 2-1-7`,chart:`M4 20V4M4 20h16M8 16v-5M12 16V8M16 16v-8`,pie:`M12 3a9 9 0 1 0 9 9h-9z`,trending:`M3 17l6-6 4 4 8-8M15 7h6v6`,dollar:`M12 3v18M16 7.5C16 6 14.2 5 12 5S8 6 8 7.5 9.5 10 12 10.5s4 1.5 4 3-1.8 2.5-4 2.5-4-1-4-2.5`,percent:`M5 19L19 5M7.5 5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM16.5 14a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5z`,truck:`M3 6h11v9H3zM14 9h4l3 3v3h-7zM7.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM17.5 18a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3z`,package:`M12 3l8 4v10l-8 4-8-4V7zM4 7l8 4 8-4M12 11v10`,store:`M4 9h16v11H4zM4 9l1.5-5h13L20 9M9 20v-6h6v6`,building:`M5 21V4h9v17M14 9h5v12M8 8h3M8 12h3M8 16h3M17 12h.01M17 16h.01`,users:`M9 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM2 20c0-3.3 3.1-5 7-5s7 1.7 7 5M17 5a4 4 0 0 1 0 7.9M22 20c0-2.6-1.6-4.2-4-4.8`,"thumbs-up":`M7 21V10h3l3-6a2 2 0 0 1 2 2v4h4l-2 11z`,smile:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9 10h.01M15 10h.01M8.5 14.5a5 5 0 0 0 7 0`,help:`M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18zM9.5 9.5a2.5 2.5 0 1 1 3.5 2.3c-.6.3-1 .9-1 1.7M12 17h.01`,checkbox:`M4 4h16v16H4zM8 12l3 3 5-5`,list:`M8 6h13M8 12h13M8 18h13M3.5 6h.01M3.5 12h.01M3.5 18h.01`,grid:`M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z`,apps:`M4.5 4.5h2v2h-2zM11 4.5h2v2h-2zM17.5 4.5h2v2h-2zM4.5 11h2v2h-2zM11 11h2v2h-2zM17.5 11h2v2h-2zM4.5 17.5h2v2h-2zM11 17.5h2v2h-2zM17.5 17.5h2v2h-2z`,layers:`M12 3l9 5-9 5-9-5zM3 13l9 5 9-5`,zap:`M13 3L5 14h6l-1 7 8-11h-6z`,flame:`M12 21a6 6 0 0 0 6-6c0-4-4-6-4-10 0 0-3 1.5-3 5 0 1.5-1 2-1.5 1.5C8 10 7.5 9 7.5 9A7.5 7.5 0 0 0 6 15a6 6 0 0 0 6 6z`,droplet:`M12 3s6 6.4 6 10.5a6 6 0 0 1-12 0C6 9.4 12 3 12 3z`,leaf:`M4 20c0-8 6-14 16-14 0 10-6 14-12 14H4zM8 16c2-4 5-6 8-7`};function Ai({name:e=`star`,paths:t,fill:n=!1,size:r=24,stroke:i=2,color:a=``,href:o=``,target:s=``,label:c=``,style:l,nodeRef:u,inert:d}){let f=Array.isArray(t)?t.filter(e=>typeof e==`string`&&e.trim()):[],p=n&&f.length>0,m=f.length?f:[ki[e]??ki.star],h=Math.min(Math.max(Number(r)||24,8),240),g=a===`accent`?`var(--page-accent, currentColor)`:a||`currentColor`,_=(0,G.jsx)(`svg`,{...q(`glyph`),viewBox:`0 0 24 24`,width:h,height:h,fill:p?g:`none`,stroke:p?`none`:g,strokeWidth:p?void 0:Math.min(Math.max(Number(i)||2,.5),4),strokeLinecap:p?void 0:`round`,strokeLinejoin:p?void 0:`round`,role:c?`img`:void 0,"aria-label":c||void 0,"aria-hidden":c?void 0:`true`,style:{display:`block`},children:m.map((e,t)=>(0,G.jsx)(`path`,{d:e},t))}),v={display:`inline-flex`,lineHeight:0,...z(l)};return o?(0,G.jsx)(`a`,{ref:u,href:o,onClick:d?e=>e.preventDefault():void 0,target:s||void 0,rel:s===`_blank`?`noopener noreferrer`:void 0,style:{...v,color:`inherit`},children:_}):(0,G.jsx)(`span`,{ref:u,style:v,children:_})}function ji(e,t={},n=0){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`):[],i=e=>e==null?``:rr(e),a=Math.max(0,Number(n)||0),o=[];for(let e of r){let n=e.data??e,r=tr(n,t.imageField),s=(Array.isArray(r)?r:[r]).map(e=>e&&typeof e==`object`?e.url??e.src??``:e).filter(e=>typeof e==`string`&&e.trim()),c=t.nameField?i(tr(n,t.nameField)):i(n.name),l=t.hrefField?i(tr(n,t.hrefField)):``;for(let e of s)if(o.push({src:e,name:c,alt:c,href:l}),a&&o.length>=a)return o}return o}function Mi({images:e=[],source:t=``,entry:n=``,imageField:r=``,nameField:i=``,hrefField:a=``,limit:o=0,emptyText:s=``,columns:c=3,gap:u=8,showNames:d=!1,lightbox:f=!0,style:p,nodeRef:m,inert:h}){let{tenant:g,apiUrl:_,revision:v}=(0,l.useContext)(K),y=(0,l.useContext)(Hn)?.[t],[b,x]=(0,l.useState)(null),[S,C]=(0,l.useState)(()=>new Set);(0,l.useEffect)(()=>{if(!t||y)return;let e=!0;return fetch(`${_}/dynamic/${encodeURIComponent(t)}`,{headers:g?{"x-tenant":g}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&x(n)}).catch(()=>e&&x([])),()=>{e=!1}},[v,t,g,_,y]);let w=y??b??[],T=n?w.filter(e=>e?.id===n||e?.data?.slug===n||e?.slug===n):w,E=Math.max(0,Number(o)||0),D=t?(()=>{let e=ji(T,{imageField:r,nameField:i,hrefField:a},0).filter(e=>!S.has(e.src));return E?e.slice(0,E):e})():null,O=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.src):[],k=D??O,A=!!t&&!y&&b===null,j=Math.max(0,Number(u)||0),M=h?e=>e.preventDefault():void 0,[N,P]=(0,l.useState)(null),F=f&&!h&&N!==null&&k[N];(0,l.useEffect)(()=>{if(!F)return;let e=e=>{e.key===`Escape`&&P(null),e.key===`ArrowRight`&&P(e=>(e+1)%k.length),e.key===`ArrowLeft`&&P(e=>(e-1+k.length)%k.length)};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[F,k.length]);let I=e=>{if(typeof e.name==`string`&&e.name.trim())return e.name;if(typeof e.alt==`string`&&e.alt.trim())return e.alt;try{let t=String(e.src).split(`?`)[0].split(`/`).pop();return decodeURIComponent(t??``)}catch{return``}};return(0,G.jsxs)(`div`,{ref:m,style:{columnCount:Math.min(Math.max(Number(c)||3,1),8),columnGap:j,width:`100%`,...z(p)},children:[k.map((e,n)=>{let r=(0,G.jsxs)(`span`,{style:{position:`relative`,display:`block`,borderRadius:`inherit`,overflow:`hidden`},children:[(0,G.jsx)(`img`,{...q(`image`),src:e.src,alt:e.alt??``,onError:t?()=>C(t=>new Set(t).add(e.src)):void 0,style:{width:`100%`,display:`block`,borderRadius:`inherit`}}),d&&I(e)&&(0,G.jsx)(`span`,{...q(`caption`),style:{position:`absolute`,insetInline:0,bottom:0,padding:`14px 10px 8px`,background:`linear-gradient(transparent, rgba(0, 0, 0, 0.65))`,color:`#fff`,fontSize:12,lineHeight:1.3,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`},children:I(e)})]}),i=e.href?(0,G.jsx)(`a`,{href:e.href,onClick:M,target:e.target||void 0,rel:e.target===`_blank`?`noopener noreferrer`:void 0,style:{display:`block`,borderRadius:`inherit`},children:r}):f&&!h?(0,G.jsx)(`span`,{role:`button`,tabIndex:0,onClick:()=>P(n),onKeyDown:e=>(e.key===`Enter`||e.key===` `)&&P(n),style:{display:`block`,borderRadius:`inherit`,cursor:`zoom-in`},children:r}):r;return(0,G.jsx)(`div`,{...q(`tile`),style:{breakInside:`avoid`,marginBottom:j,borderRadius:`inherit`,overflow:`hidden`},children:i},n)}),!k.length&&!A&&(0,G.jsx)(`div`,{...q(`empty`),style:{padding:`24px 12px`,fontSize:13,opacity:.55,textAlign:`center`,columnSpan:`all`},children:t?s||`No images yet`:`Pick images in Settings to fill the gallery`}),F&&(0,G.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,onClick:()=>P(null),style:{position:`fixed`,inset:0,zIndex:1400,background:`rgba(0, 0, 0, 0.86)`,display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,padding:24},children:[(0,G.jsx)(`img`,{src:k[N].src,alt:k[N].alt??``,onClick:e=>e.stopPropagation(),style:{maxWidth:`92vw`,maxHeight:`84vh`,borderRadius:8,boxShadow:`0 12px 48px rgba(0,0,0,0.5)`}}),I(k[N])&&(0,G.jsx)(`div`,{style:{color:`#fff`,fontSize:14,marginTop:12,opacity:.85},children:I(k[N])}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:()=>P(null),style:{position:`absolute`,top:16,right:20,background:`transparent`,border:0,color:`#fff`,fontSize:28,lineHeight:1,cursor:`pointer`},children:`×`}),k.length>1&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`button`,{type:`button`,"aria-label":`Previous`,onClick:e=>{e.stopPropagation(),P(e=>(e-1+k.length)%k.length)},style:{position:`absolute`,left:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`‹`}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Next`,onClick:e=>{e.stopPropagation(),P(e=>(e+1)%k.length)},style:{position:`absolute`,right:16,top:`50%`,transform:`translateY(-50%)`,background:`transparent`,border:0,color:`#fff`,fontSize:36,cursor:`pointer`,padding:12},children:`›`})]})]})]})}var Ni=e=>{let t=Array.isArray(e)?e[0]:e;return t&&typeof t==`object`?String(t.url??t.href??t.link??``):t==null?``:String(t)},Pi=e=>String(e??``).trim().toLowerCase().split(/[-_]/)[0];function Fi(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=Pi(t.language),i=n.filter(e=>!t.langField||!r||Pi(rr(e.data?.[t.langField]))===r),a=e=>String(e.data?.slug??e.slug??``),o=e=>{if(!t.parentField)return``;let n=e.data?.[t.parentField],r=Array.isArray(n)?n[0]:n;return r&&typeof r==`object`?String(r.id??r.slug??``):r==null?``:String(r)},s=e=>{let n=Number(t.orderField?rr(e.data?.[t.orderField]):NaN);return Number.isFinite(n)?n:1/0},c=(e,t)=>s(e)-s(t)||a(e).localeCompare(a(t),void 0,{numeric:!0}),l=new Map;for(let e of i)l.set(String(e.id),e),a(e)&&l.set(a(e),e);let u=new Map;for(let e of i){let t=l.get(o(e)),n=t&&t!==e?t.id:``;u.has(n)||u.set(n,[]),u.get(n).push(e)}let d=[];if(t.root===`parent`){let e=t.rootEntry?l.get(String(t.rootEntry)):null;d=e?u.get(e.id)??[]:[]}else{let e=e=>!t.groupField||rr(e.data?.[t.groupField])===String(t.groupValue??``);d=i.filter(t=>{if(!e(t))return!1;let n=l.get(o(t));return!n||n===t||!e(n)})}let f=Math.max(0,Number(t.depth)||0),p=new Set,m=(e,n)=>{if(p.has(e.id))return null;p.add(e.id);let r=f===0||n<f?u.get(e.id)??[]:[];return{key:e.id,label:rr(e.data?.[t.labelField||`name`])||rr(e.data?.name)||`Untitled`,href:Et(t.hrefField?Ni(e.data?.[t.hrefField]):``),icon:t.iconField?rr(e.data?.[t.iconField]).trim():``,children:[...r].sort(c).map(e=>m(e,n+1)).filter(Boolean)}};return[...d].sort(c).map(e=>m(e,1)).filter(Boolean)}var Ii=(e,t)=>{if(!e||!t||!e.startsWith(`/`))return!1;let n=e=>e.length>1?e.replace(/\/+$/,``):e,r=n(e.split(/[?#]/)[0]),i=n(t);return r===i||r.length>1&&i.endsWith(r)&&i.charAt(i.length-r.length-1)===`/`},Li=pr({display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:8,padding:`10px 16px`,color:`inherit`,textDecoration:`none`});function Ri({source:e=``,labelField:t=``,hrefField:n=``,parentField:r=``,orderField:i=``,langField:a=``,root:o=`group`,groupField:s=``,groupValue:c=``,rootEntry:u=``,depth:d=0,expand:f=`current`,toggleOnClick:p=!0,indent:m=16,lines:h=`none`,lineColor:g=``,iconField:_=``,branchIcon:v=``,leafIcon:y=``,toggleIcon:b=`caret`,toggleSize:x=16,dividers:S=`none`,dividerColor:C=``,dividerWidth:w=1,linkColor:T=``,hoverBg:E=``,hoverColor:D=``,currentBg:O=``,currentColor:k=``,placeholder:A=``,style:j,nodeRef:M}){let{tenant:N,apiUrl:P,revision:F,locale:I}=(0,l.useContext)(K),L=(0,l.useContext)(Hn)?.[e],R=Number(m)||0,B=(h===`solid`||h===`dotted`)&&R>=8,ee=B?`1px ${h} ${g||`currentColor`}`:``,V=g?1:.5,H=e=>16+(e-2)*R+6,U=`wb-mt-${(0,l.useId)().replace(/[^a-zA-Z0-9_-]/g,``)}`,te=[`solid`,`dashed`,`dotted`].includes(S)?`${Math.min(Math.max(Number(w)||1,1),8)}px ${S} ${C||`rgba(148, 163, 184, 0.35)`}`:``,ne=[te&&`.${U} [data-wb-part~="link"]{border-top:${te};}.${U} > [data-wb-part~="item"]:first-of-type > [data-wb-part~="link"]{border-top:0;}`,T&&`.${U} a{color:${T} !important;}`,(E||D)&&`.${U} a:hover{${E?`background-color:${E} !important;`:``}${D?`color:${D} !important;`:``}}`,(O||k)&&`.${U} a[aria-current="page"]{${O?`background-color:${O} !important;`:``}${k?`color:${k} !important;`:``}}`].filter(Boolean).join(``),re=e=>{let t=e.icon||(e.children.length>0?v:y);return t?/^(https?:)?\/\/|^\//.test(t)?(0,G.jsx)(`img`,{...q(`icon`),src:t,alt:``,style:{width:18,height:18,objectFit:`contain`,flexShrink:0}}):ki[t]?(0,G.jsx)(`svg`,{...q(`icon`),viewBox:`0 0 24 24`,width:`18`,height:`18`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{flexShrink:0,opacity:.8},children:(0,G.jsx)(`path`,{d:ki[t]})}):null:null},ie=Math.min(Math.max(Number(x)||16,8),40),ae=e=>b===`plus`?(0,G.jsx)(`path`,{d:e?ki.minus:ki.plus}):b===`chevron`?(0,G.jsx)(`path`,{d:ki[`chevron-right`]}):null,[oe,se]=(0,l.useState)(null),[ce,le]=(0,l.useState)(``),[ue,de]=(0,l.useState)({});(0,l.useEffect)(()=>{le(window.location.pathname)},[]),(0,l.useEffect)(()=>{if(!e||L)return;let t=!0,n=new URLSearchParams({all:`1`});return I&&n.set(`locale`,I),fetch(`${P}/dynamic/${encodeURIComponent(e)}?${n}`,{headers:N?{"x-tenant":N}:{}}).then(e=>e.json()).then(e=>{let n=Array.isArray(e?.payload)?e.payload:Array.isArray(e?.payload?.data)?e.payload.data:[];t&&se(n)}).catch(()=>t&&se([])),()=>{t=!1}},[F,e,N,P,I,L]);let fe=(0,l.useMemo)(()=>Fi(L??oe??[],{labelField:t,hrefField:n,parentField:r,orderField:i,langField:a,language:I,root:o,groupField:s,groupValue:c,rootEntry:u,depth:d,iconField:_}),[L,oe,t,n,r,i,a,I,o,s,c,u,d,_]),pe=(0,l.useMemo)(()=>{let e=new Set,t=(n,r)=>n.some(n=>Ii(n.href,ce)?([...r,n.key].forEach(t=>e.add(t)),!0):t(n.children,[...r,n.key]));return t(fe,[]),e},[fe,ce]),me=e=>e.key in ue?ue[e.key]:f===`all`||f===`current`&&pe.has(e.key),he=e=>de(t=>({...t,[e.key]:!me(e)})),ge=(e,t)=>({position:`absolute`,left:H(e),pointerEvents:`none`,opacity:V,borderLeft:ee,...t}),_e=(e,t,n)=>!B||e<2?null:(0,G.jsxs)(G.Fragment,{children:[t.map((e,t)=>e?(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:ge(t+2,{top:0,bottom:0})},t):null),(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:ge(e,n?{top:0,height:`50%`}:{top:0,bottom:0})}),(0,G.jsx)(`span`,{...q(`line`),"aria-hidden":!0,style:{position:`absolute`,left:H(e),top:`50%`,width:Math.max(4,R-8),pointerEvents:`none`,opacity:V,borderTop:ee}})]}),ve=(e,t,n=[])=>e.map((r,i)=>{let a=r.children.length>0,o=a&&me(r),s=Ii(r.href,ce),c=B&&t>1,l=i===e.length-1;return(0,G.jsxs)(`div`,{...q(`item`,o&&`item-open`),children:[(0,G.jsxs)(`a`,{...q(`link`,s&&`link-current`),href:r.href||`#`,"aria-current":s?`page`:void 0,"aria-expanded":a?o:void 0,onClick:a&&(p||!r.href)?e=>{e.preventDefault(),he(r)}:void 0,style:{...Li,paddingLeft:16+(t-1)*R,fontWeight:s?600:void 0,...c?{position:`relative`}:null},children:[_e(t,n,l),(0,G.jsxs)(`span`,{style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[re(r),(0,G.jsx)(`span`,{...q(`label`),children:r.label})]}),a?(0,G.jsx)(`span`,{role:`button`,tabIndex:-1,"aria-label":o?`Collapse`:`Expand`,onClick:e=>{e.preventDefault(),e.stopPropagation(),he(r)},style:{flexShrink:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,margin:`-8px -8px -8px 0`,padding:8,cursor:`pointer`},children:b===`plus`||b===`chevron`?(0,G.jsx)(`svg`,{...q(`toggle`),viewBox:`0 0 24 24`,width:ie+2,height:ie+2,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,style:{transition:`transform .2s`,transform:b===`chevron`&&o?`rotate(90deg)`:`none`},children:ae(o)}):(0,G.jsx)(`svg`,{...q(`toggle`),viewBox:`0 0 24 24`,width:ie,height:ie,"aria-hidden":!0,style:{transition:`transform .2s`,transform:o?`rotate(180deg)`:`none`},children:(0,G.jsx)(`path`,{d:`M5 8.5h14L12 17z`,fill:`currentColor`})})}):null]}),o?(0,G.jsx)(`div`,{...q(`children`),children:ve(r.children,t+1,t>1?[...n,!l]:n)}):null]},r.key)});return(0,G.jsxs)(`nav`,{ref:M,"aria-label":`Menu`,className:ne?U:void 0,style:{...z(j)},children:[ne?(0,G.jsx)(`style`,{children:ne}):null,fe.length?ve(fe,1):A?(0,G.jsx)(`div`,{...q(`empty`),style:{padding:`10px 16px`,opacity:.6,fontSize:14},children:A}):null]})}var zi={color:`inherit`,textDecoration:`none`,fontSize:14,opacity:.85},Bi=pr({background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.25)`,boxShadow:`0 16px 40px rgba(15, 23, 42, 0.16)`,zIndex:60});function Vi(e,t={},n=`dropdown`){let r=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],i=e=>Array.isArray(e)?e[0]:e,a=e=>e==null?``:rr(e),o=r.map(e=>{let n=e.data??{},r=t.parentField?i(n[t.parentField]):null;return{key:e.id,parent:(r&&typeof r==`object`?r.id:r)||null,label:a(n[t.labelField||`name`])||a(n.name)||`Untitled`,href:t.hrefField?a(n[t.hrefField]):``,image:t.imageField&&i(n[t.imageField])||``,desc:t.descField?a(n[t.descField]):``}}),s=new Map(o.map(e=>[e.key,e])),c=e=>{let t=new Set,n=e;for(;n.parent&&s.has(n.parent)&&!t.has(n.key);)t.add(n.key),n=s.get(n.parent);return n},l=[],u=new Map;for(let e of o){if(c(e)!==e)continue;let t={key:e.key,label:e.label,href:e.href,image:e.image,children:[]};u.set(e.key,t),l.push(t)}for(let e of o){let t=c(e);t!==e&&u.get(t.key)?.children.push({key:e.key,label:e.label,href:e.href,image:e.image,desc:e.desc})}return l.map(e=>({...e,type:e.children.length?n:`link`}))}function Hi({brand:e,logo:t,brandHref:n,brandTarget:r,links:i=[],style:a,nodeRef:o,menu:s=`auto`,breakpoint:c=768,source:u=``,labelField:d=``,hrefField:f=``,imageField:p=``,descField:m=``,parentField:h=``,submenu:g=`dropdown`}){let[_,v]=(0,l.useState)(null),[y,b]=(0,l.useState)(!1),[x,S]=(0,l.useState)(!1),[C,w]=(0,l.useState)(null),{tenant:T,apiUrl:E,revision:D,locale:O}=(0,l.useContext)(K),k=at(O),A=(0,l.useId)(),j=(0,l.useContext)(Hn)?.[u],[M,N]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!u||j)return;let e=!0;return fetch(`${E}/dynamic/${encodeURIComponent(u)}`,{headers:T?{"x-tenant":T}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&N(n)}).catch(()=>e&&N([])),()=>{e=!1}},[D,u,T,E,j]),(0,l.useEffect)(()=>{if(!_)return;let e=new ResizeObserver(()=>b(_.offsetWidth<c));return e.observe(_),()=>e.disconnect()},[_,c]);let P=u?Vi(j??M??[],{labelField:d,hrefField:f,imageField:p,descField:m,parentField:h},g):i,F=s===`hamburger`||s===`auto`&&y,I=(e,t,n=!1)=>{let r=e.image?(0,G.jsx)(`img`,{...q(`sublink-image`),src:e.image,alt:``,style:n?{width:`100%`,aspectRatio:`16 / 9`,objectFit:`cover`,borderRadius:6,display:`block`,marginBottom:8}:{width:22,height:22,objectFit:`cover`,borderRadius:4,display:`block`,flexShrink:0}}):null;return(0,G.jsxs)(`a`,{...q(`sublink`,n&&`sublink-card`),href:e.href||`#`,style:{...zi,display:n?`block`:`flex`,alignItems:n?void 0:`center`,gap:n?void 0:10,...t},children:[r,(0,G.jsxs)(`span`,{...q(`sublink-label`),style:{display:`block`,minWidth:0},children:[e.label,e.desc&&(0,G.jsx)(`span`,{...q(`sublink-desc`),style:{display:`block`,fontSize:12,opacity:.6,marginTop:2},children:e.desc})]})]},e.key)};return(0,G.jsxs)(`nav`,{ref:e=>{v(e),o&&o(e)},style:{display:`flex`,alignItems:`center`,gap:24,flexWrap:`wrap`,padding:`14px 24px`,width:`100%`,position:`relative`,...z(a)},children:[(t||e)&&(()=>{let i=(0,G.jsxs)(G.Fragment,{children:[t&&(0,G.jsx)(`img`,{...q(`logo`),src:t,alt:e||`Logo`,style:{height:28,display:`block`}}),e&&(0,G.jsx)(`span`,{...q(`brand-name`),style:{fontWeight:700,fontSize:18,fontFamily:`var(--page-heading-font, inherit)`},children:e})]}),a={display:`flex`,alignItems:`center`,gap:10,color:`inherit`,textDecoration:`none`};return n?(0,G.jsx)(`a`,{...q(`brand`),href:n,target:r||void 0,rel:r===`_blank`?`noopener noreferrer`:void 0,style:a,children:i}):(0,G.jsx)(`div`,{...q(`brand`),style:a,children:i})})(),(0,G.jsx)(`div`,{style:{flexGrow:1}}),F?(0,G.jsx)(`button`,{type:`button`,...q(`menu-button`),"aria-label":k(x?`closeMenu`:`openMenu`),"aria-expanded":x,"aria-controls":x?`${A}-menu`:void 0,onClick:()=>S(!x),style:{background:`transparent`,border:0,color:`inherit`,cursor:`pointer`,fontSize:20,lineHeight:1,padding:4},children:x?`✕`:`☰`}):(0,G.jsx)(`div`,{...q(`links`),style:{display:`flex`,gap:20,alignItems:`center`,flexWrap:`wrap`},children:P.map(e=>{let t=e.children??[];if(!t.length)return(0,G.jsx)(`a`,{...q(`link`),href:e.href||`#`,style:zi,children:e.label},e.key);let n=e.type===`mega`,r=`${A}-${e.key}`;return(0,G.jsxs)(`span`,{style:{position:n?`static`:`relative`,display:`inline-flex`},onMouseEnter:()=>w(e.key),onMouseLeave:()=>w(null),onFocus:t=>{t.currentTarget.contains(t.relatedTarget)||w(e.key)},onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||w(null)},onKeyDown:t=>{let n=t.currentTarget;t.key===`Escape`&&C===e.key?(t.stopPropagation(),w(null),n.querySelector(`a`)?.focus()):t.key===`ArrowDown`&&C!==e.key&&(t.preventDefault(),w(e.key),setTimeout(()=>n.querySelectorAll(`a`)[1]?.focus(),0))},children:[(0,G.jsxs)(`a`,{...q(`link`),href:e.href||`#`,"aria-haspopup":`true`,"aria-expanded":C===e.key,"aria-controls":C===e.key?r:void 0,style:{...zi,cursor:`pointer`},children:[e.label,` `,(0,G.jsx)(`span`,{...q(`chevron`),"aria-hidden":`true`,style:{fontSize:9,opacity:.6},children:`▼`})]}),C===e.key&&(n?(0,G.jsx)(`div`,{id:r,...q(`mega-panel`),style:{...Bi,position:`absolute`,left:0,right:0,top:`100%`,padding:24,display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(170px, 1fr))`,gap:16},children:t.map(e=>I(e,{padding:8,borderRadius:8},!0))}):(0,G.jsx)(`div`,{id:r,...q(`dropdown-panel`),style:{...Bi,position:`absolute`,top:`100%`,left:0,minWidth:190,borderRadius:8,padding:8,display:`flex`,flexDirection:`column`},children:t.map(e=>I(e,{padding:`8px 12px`,borderRadius:6}))}))]},e.key)})}),F&&x&&(0,G.jsx)(`div`,{id:`${A}-menu`,...q(`mobile-menu`),style:{flexBasis:`100%`,width:`100%`,display:`flex`,flexDirection:`column`,paddingTop:10},children:P.map(e=>(0,G.jsxs)(l.Fragment,{children:[(0,G.jsx)(`a`,{...q(`mobile-link`),href:e.href||`#`,style:{...zi,padding:`10px 4px`,fontWeight:(e.children??[]).length?600:400,opacity:1},children:e.label}),(e.children??[]).map(e=>I(e,{padding:`8px 4px 8px 22px`}))]},e.key))})]})}function Ui({tabs:e=[],linked:t,style:n,nodeRef:r}){let[i,a]=(0,l.useState)(0),{locale:o}=(0,l.useContext)(K),s=(0,l.useId)(),c=(0,l.useRef)(null),u=e.length?Math.min(i,e.length-1):0;if(!e.length)return null;let d=at(o),f=t=>{let n=e.length-1,r={ArrowRight:(u+1)%e.length,ArrowLeft:(u-1+e.length)%e.length,Home:0,End:n}[t.key];r!==void 0&&(t.preventDefault(),a(r),c.current?.querySelectorAll(`[role="tab"]`)[r]?.focus())};return(0,G.jsxs)(`div`,{ref:r,style:{width:`100%`,...z(n)},children:[(0,G.jsx)(`div`,{ref:c,role:`tablist`,...q(`tab-list`),onKeyDown:f,style:{display:`flex`,gap:4,borderBottom:`1px solid rgba(148, 163, 184, 0.35)`},children:e.map((e,t)=>(0,G.jsx)(`button`,{...q(`tab`,t===u&&`tab-active`),type:`button`,role:`tab`,id:`${s}-tab-${e.key}`,"aria-selected":t===u,"aria-controls":`${s}-panel-${e.key}`,tabIndex:t===u?0:-1,onClick:()=>a(t),style:{background:`transparent`,border:0,padding:`10px 16px`,fontSize:14,fontFamily:`inherit`,color:`inherit`,cursor:`pointer`,opacity:t===u?1:.6,fontWeight:t===u?600:500,boxShadow:t===u?`inset 0 -2px 0 var(--page-accent, #111827)`:`none`},children:e.label||d(`tab`,{n:t+1})},e.key))}),e.map((e,n)=>(0,G.jsx)(`div`,{...q(`panel`),role:`tabpanel`,id:`${s}-panel-${e.key}`,"aria-labelledby":`${s}-tab-${e.key}`,tabIndex:0,hidden:n!==u,style:{display:n===u?`flex`:`none`,flexDirection:`column`},children:t?.[e.key]??null},e.key))]})}function Wi({items:e=[],linked:t,multiple:n=!1,startOpen:r=`first`,icon:i=``,padX:a,padY:o,headerBg:s,headerColor:c,openBg:u,openColor:d,borderColor:f,style:p,nodeRef:m}){let h=()=>!e.length||r===`none`?new Set:r===`all`&&n?new Set(e.map(e=>e.key)):new Set([e[0].key]),[g,_]=(0,l.useState)(h),{locale:v}=(0,l.useContext)(K);(0,l.useEffect)(()=>{_(h())},[r,n]);let y=(0,l.useId)();if(!e.length)return null;let b=at(v),x=(e,t)=>typeof e==`string`&&e?e:t,S=(e,t)=>{let n=Number(e);return e===``||e==null||!Number.isFinite(n)?t:n},C=ki[i],w=e=>_(t=>{let r=new Set(n?t:[]);return t.has(e)?r.delete(e):r.add(e),r});return(0,G.jsx)(`div`,{ref:m,style:{width:`100%`,...z(p)},children:e.map((n,r)=>{let i=g.has(n.key);return(0,G.jsxs)(`div`,{...q(`item`,i&&`item-open`),style:{borderBottom:r<e.length-1?`1px solid ${x(f,`rgba(148, 163, 184, 0.35)`)}`:`none`},children:[(0,G.jsxs)(`button`,{type:`button`,...q(`header`,i&&`header-open`),id:`${y}-h-${n.key}`,"aria-expanded":i,"aria-controls":`${y}-b-${n.key}`,onClick:()=>w(n.key),style:{width:`100%`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:12,background:i?x(u,x(s,`transparent`)):x(s,`transparent`),border:0,padding:`${S(o,14)}px ${S(a,4)}px`,fontSize:15,fontWeight:600,fontFamily:`inherit`,color:i?x(d,x(c,`inherit`)):x(c,`inherit`),textAlign:`left`,cursor:`pointer`,transition:`background 180ms, color 180ms`},children:[(0,G.jsxs)(`span`,{...q(`title`),style:{display:`flex`,alignItems:`center`,gap:10,minWidth:0},children:[C?(0,G.jsx)(`svg`,{...q(`icon`),viewBox:`0 0 24 24`,width:16,height:16,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":`true`,style:{flexShrink:0},children:(0,G.jsx)(`path`,{d:C})}):null,n.title||b(`item`,{n:r+1})]}),(0,G.jsx)(`span`,{"aria-hidden":`true`,...q(`chevron`),style:{fontSize:12,opacity:.6,transform:i?`rotate(180deg)`:`none`,transition:`transform 180ms`},children:`▼`})]}),(0,G.jsx)(`div`,{...q(`body`),id:`${y}-b-${n.key}`,role:`region`,"aria-labelledby":`${y}-h-${n.key}`,hidden:!i,style:{display:i?`flex`:`none`,flexDirection:`column`},children:t?.[n.key]??null})]},n.key)})})}var Gi={display:`flex`,flexDirection:`column`,gap:`12px`},Ki={fontSize:`14px`,fontWeight:500,color:`var(--page-text, #111827)`},qi=pr({padding:`10px 12px`,border:`1px solid var(--page-border, #d1d5db)`,borderRadius:`6px`,fontSize:`14px`,fontFamily:`inherit`,width:`100%`,boxSizing:`border-box`,backgroundColor:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`}),Ji={display:`flex`,alignItems:`center`,gap:`8px`,fontSize:`14px`,color:`var(--page-text, #111827)`},Yi=e=>e?{readOnly:!0,tabIndex:-1,onMouseDown:e=>e.preventDefault()}:{};function Xi(e,t){if(!e)return!0;let n=t[e.field],r=n==null||n===``?``:String(n),i=e.value??``;switch(e.op){case`eq`:return r===i;case`neq`:return r!==i;case`contains`:return r.toLowerCase().includes(i.toLowerCase());case`gt`:return Number(r)>Number(i);case`lt`:return Number(r)<Number(i);case`empty`:return r===``;case`notEmpty`:return r!==``;default:return!1}}var Zi={display:`flex`,flexDirection:`column`,gap:6},Qi=`#dc2626`,$i={fontSize:13,fontWeight:500,color:Qi},ea=pr({font:`inherit`,fontSize:15,padding:`10px 12px`,borderRadius:8,border:`1px solid rgba(148, 163, 184, 0.55)`,background:`transparent`,color:`inherit`,width:`100%`,boxSizing:`border-box`});function ta(e,t){let n=Array.isArray(e?.options)?e.options:[];if(!e?.parentField)return n;let r=t?.[e.parentField];return r?n.filter(e=>typeof e==`string`?!1:!e.parent||e.parent===r):[]}var na=`g-recaptcha-response`,ra=e=>e?.type===`recaptcha`?na:e?.name,ia=[[/^(full_?name|name|ad_?soyad|adsoyad|isim)$/,`name`],[/^(first_?name|given_?name|ad|adi|adiniz)$/,`given-name`],[/^(last_?name|family_?name|surname|soyad|soyadi|soyadiniz)$/,`family-name`],[/^(e_?mail|e_?posta|eposta|mail)$/,`email`],[/^(phone|tel|telephone|mobile|gsm|telefon|cep)$/,`tel`],[/^(company|organization|organisation|firma|sirket|kurum)$/,`organization`],[/^(address|street|adres|sokak)$/,`street-address`],[/^(city|town|sehir|il)$/,`address-level2`],[/^(district|ilce)$/,`address-level3`],[/^(zip|zip_?code|postal_?code|postcode|posta_?kodu)$/,`postal-code`],[/^(country|ulke)$/,`country-name`],[/^(website|web|url|site)$/,`url`]];function aa(e){if(typeof e.autocomplete==`string`&&e.autocomplete)return e.autocomplete;let t={email:`email`,phone:`tel`,link:`url`}[e.type];if(t)return t;let n=String(e.name??``).toLowerCase();return ia.find(([e])=>e.test(n))?.[1]}function oa({field:e,value:t,onChange:n,inert:r,values:i,error:a,idBase:o}){let s=at((0,l.useContext)(K).locale),c=`${o}-${e.name}`,u=e.help?`${c}-help`:null,d=a?`${c}-error`:null,f=(0,G.jsxs)(`label`,{...q(`label`),htmlFor:c,style:{...Ki,fontSize:14},children:[e.label,e.required?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,children:` *`}),(0,G.jsxs)(`span`,{style:ot,children:[` (`,s(`required`),`)`]})]}):null]}),p=[u,d].filter(Boolean).join(` `)||void 0,m={id:c,"aria-invalid":a?!0:void 0,"aria-describedby":p},h={...q(`input`),...m,name:e.name,required:e.required||void 0,placeholder:e.placeholder||void 0,disabled:r||void 0,autoComplete:aa(e),style:a?{...ea,borderTopColor:Qi,borderRightColor:Qi,borderBottomColor:Qi,borderLeftColor:Qi}:ea,value:t??``,onChange:t=>n(e.name,t.target.value)};return e.type===`display`?(0,G.jsx)(e.variant&&e.variant!==`p`?e.variant:`p`,{...q(`text`),style:{margin:0,color:e.color||`inherit`,fontSize:{h1:32,h2:26,h3:21,h4:18,h5:16,h6:14,p:15}[e.variant]??16,fontWeight:e.variant===`p`?400:700,lineHeight:1.35},children:e.label}):e.type===`image`?e.src?(0,G.jsx)(`img`,{...q(`image`),src:e.src,alt:e.label??``,style:{width:`100%`,borderRadius:8,display:`block`}}):null:e.type===`recaptcha`?(0,G.jsxs)(`div`,{...q(`field`),id:c,tabIndex:-1,style:Zi,children:[(0,G.jsx)(pa,{theme:e.captchaTheme,size:e.captchaSize,inert:r,onChange:e=>n(na,e)}),a&&(0,G.jsx)(`span`,{...q(`error`),id:d,style:$i,children:a})]}):e.type===`video`?e.src?/youtube\.com|youtu\.be|vimeo\.com/i.test(e.src)?(0,G.jsx)(ni,{url:e.src,style:{width:`100%`}}):(0,G.jsx)(`video`,{...q(`video`),src:e.src,controls:!0,style:{width:`100%`,borderRadius:8,display:`block`}}):null:(0,G.jsxs)(`div`,{...q(`field`),style:Zi,children:[f,e.type===`textarea`||e.multiline?(0,G.jsx)(`textarea`,{...h,...q(`textarea`),rows:4,style:{...ea,resize:`vertical`}}):e.type===`select`?(0,G.jsxs)(`select`,{...h,...q(`select`),disabled:h.disabled||!!e.parentField&&!i?.[e.parentField],children:[(0,G.jsx)(`option`,{value:``,children:e.placeholder||`—`}),ta(e,i).map((e,t)=>(0,G.jsx)(`option`,{value:typeof e==`string`?e:e.value,children:typeof e==`string`?e:e.label??e.value},t))]}):e.type===`checkbox`?(0,G.jsx)(`input`,{type:`checkbox`,...q(`checkbox`),...m,name:e.name,required:e.required||void 0,disabled:r||void 0,checked:!!t,onChange:t=>n(e.name,t.target.checked),style:{width:18,height:18}}):e.type===`upload`?(0,G.jsx)(`input`,{type:`file`,...q(`file`),...m,name:e.name,accept:e.accept||void 0,required:e.required||void 0,disabled:r||void 0,onChange:t=>n(e.name,t.target.files?.[0]?.name??``),style:{font:`inherit`,fontSize:14}}):(0,G.jsx)(`input`,{...h,type:{email:`email`,number:`number`,date:`date`,datetime:`datetime-local`,phone:`tel`,link:`url`}[e.type]??`text`}),e.help&&(0,G.jsx)(`span`,{...q(`help`),id:u,style:{fontSize:12,opacity:.65},children:e.help}),a&&(0,G.jsx)(`span`,{...q(`error`),id:d,style:$i,children:a})]})}function sa(e,t){if(!e||typeof e!=`object`)return e;let n=String(t??``).split(`-`)[0].toLowerCase(),r=(t,r)=>{let i=e[t]&&typeof e[t]==`object`?e[t][n]:null;return typeof i==`string`&&i.trim()?i:r};return{...e,label:r(`labels`,e.label),help:r(`helps`,e.help),placeholder:r(`placeholders`,e.placeholder),prefix:r(`prefixes`,e.prefix),suffix:r(`suffixes`,e.suffix),errorMessage:r(`errorMessages`,e.errorMessage)}}var ca=(e,t)=>typeof e?.errorMessage==`string`&&e.errorMessage.trim()?e.errorMessage:t;function la({style:e,action:t,method:n,name:r,enctype:i,formSlug:a,auto:o,submitLabel:s,nodeRef:c,inert:u,children:d,linked:f,show:p}){let{tenant:m,apiUrl:h,locale:g}=(0,l.useContext)(K),[_,v]=(0,l.useState)(`form`),[y,b]=(0,l.useState)(null),[x,S]=(0,l.useState)({}),[C,w]=(0,l.useState)(0),[T,E]=(0,l.useState)({}),[D,O]=(0,l.useState)(``),k=(0,l.useId)(),A=(0,l.useRef)(null),j=(0,l.useRef)(null),M=u?p||`form`:_,N=at(g);(0,l.useEffect)(()=>{if(!o||!a)return;let e=!0;return fetch(`${h||`/api`}/forms/${encodeURIComponent(a)}`,{headers:m?{"x-tenant":m}:{}}).then(e=>e.json()).then(t=>e&&b(t?.payload&&typeof t.payload==`object`?t.payload:null)).catch(()=>e&&b(null)),()=>{e=!1}},[o,a,m,h]);let P=[{section:null,fields:[]}];for(let e of(Array.isArray(y?.fields)?y.fields:[]).map(e=>sa(e,g)))e.type===`section`?P.push({section:e,fields:[]}):P[P.length-1].fields.push(e);let F=P.filter(e=>e.section||e.fields.length),I=F.filter(e=>!e.section||Xi(e.section.condition,x)).map(e=>({...e,fields:e.fields.filter(e=>Xi(e.condition,x))})),L=F.length>1,R=Math.min(C,Math.max(0,I.length-1)),B=L?I[R]?.fields??[]:I.flatMap(e=>e.fields),ee=B.filter(e=>{let t=x[ra(e)];return e.required&&(t==null||t===``||t===!1)}),V=R>=I.length-1,H=(e,t)=>{E(t=>{let n=e===`g-recaptcha-response`?(Array.isArray(y?.fields)?y.fields:[]).find(e=>e?.type===`recaptcha`)?.name:e;if(!n||!t[n])return t;let r={...t};return delete r[n],r}),S(n=>{let r={...n,[e]:t};for(let t of Array.isArray(y?.fields)?y.fields:[])t?.parentField===e&&delete r[t.name];return r})},U=()=>{let e={};for(let t of B){if(t.type===`recaptcha`){t.required&&!x[`g-recaptcha-response`]&&(e[t.name]=ca(t,N(`fieldRequired`)));continue}let n=A.current?.querySelector(`[name="${CSS.escape(String(t.name??``))}"]`);!n?.validity||n.validity.valid||(e[t.name]=ca(t,n.validity.valueMissing?N(`fieldRequired`):n.validationMessage||N(`invalid`)))}E(e);let t=B.find(t=>e[t.name]);return t&&setTimeout(()=>document.getElementById(`${k}-${t.name}`)?.focus(),0),!t},te=e=>{v(e),O(N(e===`success`?`submitted`:`submitFailed`)),e===`success`&&setTimeout(()=>j.current?.focus(),0)};return(0,G.jsxs)(`div`,{ref:c,style:z(e),children:[(0,G.jsx)(`form`,{ref:A,action:t||void 0,method:n||`post`,name:r||void 0,encType:i||void 0,noValidate:o&&a?!0:void 0,onSubmit:async e=>{if(e.preventDefault(),!u&&!(o&&a&&!U())){if(a){let t={};if(o)for(let[e,n]of Object.entries(x))n!=null&&n!==``&&(t[e]=n);else for(let[n,r]of new FormData(e.currentTarget).entries())typeof r==`string`&&(t[n]=r===`on`||r);try{let e=await fetch(`${h||`/api`}/forms/${a}/submit`,{method:`post`,headers:{"content-type":`application/json`,...m?{"x-tenant":m}:{}},body:JSON.stringify(t)}),n=await e.json().catch(()=>null),r=n?.error,i=r?.details?.field;if(o&&typeof i==`string`&&B.some(e=>e.name===i)){E({[i]:ca(B.find(e=>e.name===i),typeof r.message==`string`&&r.message||N(`invalid`))}),O(N(`submitFailed`)),setTimeout(()=>document.getElementById(`${k}-${i}`)?.focus(),0);return}te(e.ok&&n?.success!==!1?`success`:`error`)}catch{te(`error`)}return}if(!t){te(`success`);return}try{let r=await fetch(t,{method:n||`post`,body:new FormData(e.currentTarget)});te(r.ok?`success`:`error`)}catch{te(`error`)}}},style:{...Gi,display:M===`success`?`none`:`flex`},children:o&&a?(0,G.jsxs)(G.Fragment,{children:[L&&(0,G.jsx)(Ga,{steps:I.map(e=>({label:e.section?.label??N(`start`)})),active:R+1,style:{marginBottom:8}}),L&&I[R]?.section?.help&&(0,G.jsx)(`p`,{...q(`step-help`),style:{margin:0,fontSize:14,opacity:.7},children:I[R].section.help}),B.some(e=>e.required)&&(0,G.jsx)(`p`,{...q(`required-note`),style:{margin:0,fontSize:13,opacity:.7},children:N(`requiredNote`)}),B.map(e=>(0,G.jsx)(oa,{field:e,value:x[ra(e)],values:x,onChange:H,inert:u,error:T[e.name],idBase:k},e.name)),(0,G.jsxs)(`div`,{...q(`actions`),style:{display:`flex`,gap:10,alignItems:`center`,marginTop:4},children:[L&&R>0&&(0,G.jsx)(`button`,{type:`button`,...q(`back-button`),disabled:u||void 0,onClick:()=>{E({}),w(R-1)},style:{...vr,background:`transparent`,color:`inherit`,border:0,padding:`10px 16px`,cursor:`pointer`},children:N(`back`)}),L&&!V?(0,G.jsx)(`button`,{type:`button`,...q(`next-button`),disabled:u||void 0,onClick:()=>{U()&&w(R+1)},style:{...vr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`,opacity:ee.length?.75:1},children:N(`next`)}):(0,G.jsx)(`button`,{type:`submit`,...q(`submit-button`),disabled:u||void 0,style:{...vr,border:0,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,cursor:`pointer`},children:s||N(`submit`)})]})]}):d}),(0,G.jsx)(`div`,{ref:j,tabIndex:-1,style:{display:M===`success`?`block`:`none`,outline:`none`},children:f?.success??null}),(0,G.jsx)(`div`,{style:{display:M===`error`?`block`:`none`,marginTop:12},children:f?.error??null}),!u&&(0,G.jsx)(`div`,{role:`status`,"aria-live":`polite`,style:ot,children:D})]})}var ua=null,da=null,fa=e=>{let t=typeof e==`string`&&e.trim()?e.trim():``;if(ua&&da===t)return ua;if(ua&&typeof window<`u`){for(let e of[`grecaptcha`,`___grecaptcha_cfg`])try{delete window[e]}catch{window[e]=void 0}document.querySelectorAll(`script[src*="recaptcha"]`).forEach(e=>e.remove())}return da=t,ua=new Promise(e=>{if(typeof window>`u`)return;if(window.grecaptcha?.render)return e(window.grecaptcha);window.__webimRecaptchaReady=()=>e(window.grecaptcha);let n=document.createElement(`script`);n.src=`https://www.google.com/recaptcha/api.js?onload=__webimRecaptchaReady&render=explicit${t?`&hl=${encodeURIComponent(t)}`:``}`,n.async=!0,document.head.appendChild(n)}),ua};function pa({siteKey:e,theme:t,size:n,hl:r,style:i,nodeRef:a,inert:o,onChange:s}){let c=(0,l.useContext)(K),u=c?.settings&&typeof c.settings==`object`?c.settings[`google.recaptchaKey`]:``,d=typeof e==`string`&&e.trim()||(typeof u==`string`?u.trim():``),f=(0,l.useRef)(null),p=(0,l.useRef)(s);if(p.current=s,(0,l.useEffect)(()=>{if(o||!d||!f.current)return;let e=!0,i=t=>{e&&typeof p.current==`function`&&p.current(t)};return fa(r).then(r=>{if(!(!e||!f.current||!r?.render)){f.current.innerHTML=``,i(``);try{r.render(f.current,{sitekey:d,theme:t===`dark`?`dark`:`light`,size:n===`compact`?`compact`:`normal`,callback:e=>i(typeof e==`string`?e:``),"expired-callback":()=>i(``),"error-callback":()=>i(``)})}catch{}}}),()=>{e=!1}},[o,d,t,n,r]),o){let e=t===`dark`;return(0,G.jsxs)(`div`,{ref:a,style:z(i),children:[(0,G.jsxs)(`div`,{style:{width:n===`compact`?164:302,boxSizing:`border-box`,padding:`12px 14px`,display:`flex`,alignItems:`center`,gap:12,borderRadius:4,border:`1px solid ${e?`#52565b`:`#d3d3d3`}`,background:e?`#222528`:`#f9f9f9`,color:e?`#f1f1f1`:`#282828`,fontSize:14,fontFamily:`Roboto, Arial, sans-serif`},children:[(0,G.jsx)(`span`,{style:{width:24,height:24,flexShrink:0,borderRadius:3,border:`2px solid ${e?`#8a8f94`:`#c1c1c1`}`,background:e?`#2f3337`:`#fff`}}),(0,G.jsx)(`span`,{style:{flexGrow:1},children:`I'm not a robot`}),(0,G.jsx)(`span`,{style:{fontSize:9,opacity:.6,textAlign:`center`,lineHeight:1.3},children:`reCAPTCHA`})]}),!d&&(0,G.jsx)(`div`,{style:{marginTop:6,fontSize:11,color:`#b45309`},children:`Set the google.recaptchaKey tenant setting (or a site key in Settings) to activate it.`})]})}return d?(0,G.jsx)(`div`,{ref:a,style:z(i),children:(0,G.jsx)(`div`,{ref:f})}):null}var ma=e=>typeof e==`string`&&e.trim()?`wb-field-${e.trim()}`:void 0;function ha({text:e,parts:t,htmlFor:n,style:r,nodeRef:i,linked:a}){return(0,G.jsx)(`label`,{ref:i,htmlFor:n||void 0,style:{...Ki,...z(r)},children:jr(t,e,a)})}function ga({type:e=`text`,name:t,placeholder:n,required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsx)(`input`,{ref:a,id:ma(t),type:e,name:t||void 0,autoComplete:aa({name:t,type:{email:`email`,tel:`phone`,url:`link`}[e]}),placeholder:n,required:!o&&!!r,style:{...qi,...z(i)},...Yi(o)})}function _a({name:e,placeholder:t,rows:n=4,required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsx)(`textarea`,{ref:a,id:ma(e),name:e||void 0,placeholder:t,rows:n,required:!o&&!!r,style:{...qi,resize:`vertical`,...z(i)},...Yi(o)})}function va({kind:e=`checkbox`,label:t,name:n,value:r,required:i,style:a,nodeRef:o,inert:s}){return(0,G.jsxs)(`label`,{ref:o,style:{...Ji,...z(a)},children:[(0,G.jsx)(`input`,{type:e,...q(`control`),name:n||void 0,value:r||void 0,required:!s&&!!i,onClick:s?e=>e.preventDefault():void 0,tabIndex:s?-1:void 0,style:{margin:0,accentColor:`var(--page-accent, #111827)`}}),t]})}function ya({name:e,placeholder:t,options:n=[],required:r,style:i,nodeRef:a,inert:o}){return(0,G.jsxs)(`select`,{ref:a,id:ma(e),name:e||void 0,autoComplete:aa({name:e}),required:!o&&!!r,defaultValue:``,onMouseDown:o?e=>e.preventDefault():void 0,tabIndex:o?-1:void 0,style:{...qi,appearance:`auto`,...z(i)},children:[t!==``&&(0,G.jsx)(`option`,{value:``,disabled:!0,children:t??`Select…`}),n.map((e,t)=>(0,G.jsx)(`option`,{value:e,children:e},t))]})}function ba({name:e,accept:t,required:n,text:r=`Choose a file…`,style:i,nodeRef:a,inert:o}){let[s,c]=(0,l.useState)(null);return(0,G.jsxs)(`label`,{ref:a,className:`wb-file`,style:{...qi,display:`flex`,alignItems:`center`,gap:`8px`,cursor:o?`default`:`pointer`,borderStyle:`dashed`,color:s?`#111827`:`#6b7280`,...z(i)},children:[(0,G.jsx)(`input`,{type:`file`,name:e||void 0,accept:t||void 0,required:!o&&!!n,disabled:!!o,onChange:e=>c(e.target.files?.[0]?.name??null),style:ot}),(0,G.jsx)(`span`,{"aria-hidden":!0,...q(`icon`),children:`📎`}),s??r]})}function xa({legend:e=``,style:t,nodeRef:n,children:r}){return(0,G.jsxs)(`fieldset`,{ref:n,style:{...pr({border:`0 none`,margin:`0`,padding:`0`}),minWidth:0,display:`flex`,flexDirection:`column`,gap:`10px`,...z(t)},children:[typeof e==`string`&&e.trim()?(0,G.jsx)(`legend`,{...q(`legend`),style:{...Ki,padding:0,marginBottom:6},children:e}):null,r]})}function Sa({text:e=`Submit`,style:t,nodeRef:n,inert:r}){return(0,G.jsx)(`button`,{ref:n,type:r?`button`:`submit`,style:{...vr,border:0,cursor:`pointer`,alignSelf:`flex-start`,padding:`10px 22px`,borderRadius:8,fontSize:15,fontWeight:600,lineHeight:1.4,fontFamily:`inherit`,...z(t)},children:e})}function Ca({cols:e=2,rows:t=1,style:n,nodeRef:r,linked:i}){let a=Math.max(1,(Number(e)||1)*(Number(t)||1));return(0,G.jsx)(`div`,{ref:r,style:{display:`grid`,gridTemplateColumns:`repeat(${Math.max(1,Number(e)||1)}, minmax(0, 1fr))`,gap:16,width:`100%`,...z(n)},children:Array.from({length:a},(e,t)=>(0,G.jsx)(`div`,{style:{minWidth:0},children:i?.[`cell-${t}`]??null},t))})}function wa(e,t){if(e===``||e==null)return t;let n=Number(e);return Number.isFinite(n)&&n>=0?n:t}function Ta({collection:e,limit:t=6,layout:n=`grid`,columns:r=3,imageField:i,titleField:a=`name`,textField:o,custom:s,templateId:c,renderTemplate:u,paged:d,filters:f,parentField:p,topLevel:m,childrenOf:h,itemsOf:g,gap:_,style:v,nodeRef:y}){let{tenant:b,apiUrl:x,revision:S,locale:C}=(0,l.useContext)(K),w=(0,l.useContext)(Kn),T=(0,l.useContext)(Hn),E=(0,l.useContext)(qn),D=typeof g==`string`&&g?g:null,O=Co(D?vo(tr(E?.entry?.data,D)):null),k=h||D?null:e,A=!!p&&!h&&!D,[,j]=(0,l.useState)(0);(0,l.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>j(e=>e+1);return window.addEventListener(`popstate`,e),window.addEventListener(`webim:urlchange`,e),()=>{window.removeEventListener(`popstate`,e),window.removeEventListener(`webim:urlchange`,e)}},[]);let M=Gn(f),N=JSON.stringify(M),P=N!==`{}`&&!k?.startsWith?.(`api:`),F=P||!k?null:T?.[k],I=d?Un(T):1,[L,R]=(0,l.useState)(null);if((0,l.useEffect)(()=>{if(!k||F)return;let e=!0,n=k,r=new URLSearchParams;if(C&&r.set(`locale`,C),P&&r.set(`data_filter`,N),A&&!n.startsWith(`api:`))r.set(`all`,`1`);else if(d&&!n.startsWith(`api:`)){let e=Math.max(1,Number(t)||6);r.set(`offset`,String((I-1)*e)),r.set(`limit`,String(e))}let i=r.toString(),a=n.startsWith(`api:`)?`${x}/data/${encodeURIComponent(n.slice(4))}`:`${x}/dynamic/${encodeURIComponent(n)}${i?`?${i}`:``}`;return fetch(a,{headers:b?{"x-tenant":b}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];return e&&R(n.filter(e=>e&&typeof e==`object`))}).catch(()=>e&&R([])),()=>{e=!1}},[S,k,b,x,C,F,d,I,t,P,N,A]),!k&&!h&&!D)return null;let B=Math.max(1,Number(t)||6),ee=D?[]:h?E?.all??[]:F??L??[],V=D?null:h?E?.parentField:p,H=D?null:h?E?.collection:k,U=D?Xn(E?.entry,D,O):h?Yn(ee,V,E?.entry):A&&m?ee.filter(e=>Jn(e,p).length===0):ee,te=d&&(F||h||D||A||k.startsWith(`api:`))?U.slice((I-1)*B,I*B):U.slice(0,B),ne=Math.min(Math.max(Number(r)||3,1),6),re=n===`list`?{display:`flex`,flexDirection:`column`,gap:wa(_,20)}:{display:`grid`,gridTemplateColumns:`repeat(${ne}, minmax(0, 1fr))`,gap:wa(_,24)},ie=u??(c&&w?.render?e=>w.render(c,e):null);return s&&ie?(0,G.jsx)(`div`,{ref:y,style:{width:`100%`,...re,...z(v)},children:te.map(e=>(0,G.jsx)(`div`,{style:{minWidth:0},children:(0,G.jsx)(qn.Provider,{value:{entry:e,all:ee,parentField:V,collection:H},children:ie(t=>ur(t,e,C))})},e.id??e?.data?.slug))}):(0,G.jsx)(`div`,{ref:y,style:{width:`100%`,...re,...z(v)},children:te.map(e=>{let t=i?tr(e?.data,i):null,r=Array.isArray(t)?t[0]:t,s=typeof r==`string`?r:typeof r?.url==`string`?r.url:null,c=a?rr(tr(e?.data,a)):null,l=o?tr(e?.data,o):null,u=Array.isArray(l)?l:null,d=u||l==null?null:rr(l),f=n===`list`;return(0,G.jsxs)(`div`,{...q(`card`),style:{display:`flex`,flexDirection:f?`row`:`column`,gap:f?20:12,alignItems:f?`center`:`stretch`,minWidth:0},children:[s&&(0,G.jsx)(`img`,{...q(`image`),src:s,alt:c??``,style:{width:f?160:`100%`,aspectRatio:`3 / 2`,objectFit:`cover`,borderRadius:10,flexShrink:0,display:`block`}}),(0,G.jsxs)(`div`,{...q(`body`),style:{minWidth:0},children:[c&&(0,G.jsx)(`h3`,{...q(`title`),style:{margin:0,fontSize:18,fontWeight:700},children:c}),d&&(0,G.jsx)(`p`,{...q(`text`),style:{margin:`6px 0 0`,fontSize:14,lineHeight:1.55,opacity:.75},children:d}),u&&(0,G.jsx)(`div`,{...q(`text`),style:{marginTop:6,fontSize:14,lineHeight:1.55,opacity:.85},children:Br(u)})]})]},e.id??e?.data?.slug)})})}function Ea({fields:e=[],buttonLabel:t=`Search`,style:n,nodeRef:r,inert:i}){let a=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&typeof e.name==`string`&&e.name):[],o=i?{}:Wn(),s={height:34,padding:`0 12px`,borderRadius:8,border:`1px solid var(--page-border, rgba(100, 116, 139, 0.4))`,background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,fontSize:13,fontFamily:`inherit`,outline:`none`,minWidth:140,flex:`0 1 auto`,boxSizing:`border-box`},c=e=>{let t=e&&typeof e==`object`?e.value:e,n=e&&typeof e==`object`?e.label??e.value:e;return{value:String(t??``),label:String(n??``)}};return(0,G.jsxs)(`form`,{ref:r,method:`get`,onSubmit:e=>{if(i){e.preventDefault();return}if(typeof window>`u`||!window.history?.pushState)return;e.preventDefault();let t=new URLSearchParams(window.location.search);for(let e of[...t.keys()])(e.startsWith(`f_`)||e===`page`)&&t.delete(e);for(let[n,r]of new FormData(e.currentTarget).entries())n.startsWith(`f_`)&&typeof r==`string`&&r.trim()!==``&&t.set(n,r);let n=t.toString();window.history.pushState({},``,`${window.location.pathname}${n?`?${n}`:``}`),window.dispatchEvent(new Event(`webim:urlchange`))},style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,width:`100%`,...z(n)},children:[a.map(e=>Array.isArray(e.options)&&e.options.length>0||e.type===`option`||e.type===`select`?(0,G.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...q(`select`),style:s,...Yi(i),children:[(0,G.jsx)(`option`,{value:``,children:e.label||e.name}),(Array.isArray(e.options)?e.options:[]).map(e=>{let t=c(e);return(0,G.jsx)(`option`,{value:t.value,children:t.label},t.value)})]},e.name):e.type===`switch`?(0,G.jsxs)(`select`,{name:`f_${e.name}`,defaultValue:o[e.name]??``,...q(`select`),style:s,...Yi(i),children:[(0,G.jsx)(`option`,{value:``,children:e.label||e.name}),(0,G.jsx)(`option`,{value:`true`,children:`Yes`}),(0,G.jsx)(`option`,{value:`false`,children:`No`})]},e.name):(0,G.jsx)(`input`,{type:`text`,name:`f_${e.name}`,defaultValue:o[e.name]??``,placeholder:e.label||e.name,...q(`input`),style:s,...Yi(i)},e.name)),(0,G.jsx)(`button`,{type:`submit`,...q(`button`),style:{...s,minWidth:0,padding:`0 18px`,border:`none`,background:`var(--page-accent, #111827)`,color:`var(--page-accent-text, #ffffff)`,fontWeight:600,cursor:i?`default`:`pointer`},...Yi(i),children:t})]})}function Da({items:e=[],separator:t=`/`,style:n,nodeRef:r}){return e.length?(0,G.jsx)(`nav`,{ref:r,"aria-label":`Breadcrumb`,style:{...z(n)},children:(0,G.jsx)(`ol`,{...q(`list`),style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:8,listStyle:`none`,margin:0,padding:0,fontSize:14},children:e.map((n,r)=>{let i=r===e.length-1;return(0,G.jsxs)(`li`,{...q(`item`),style:{display:`flex`,alignItems:`center`,gap:8,minWidth:0},children:[r>0&&(0,G.jsx)(`span`,{...q(`separator`),style:{opacity:.4},"aria-hidden":!0,children:t}),i||!n.href?(0,G.jsx)(`span`,{...q(`crumb`,i&&`crumb-current`),style:{fontWeight:i?600:400,opacity:i?1:.7},"aria-current":i?`page`:void 0,children:n.label}):(0,G.jsx)(`a`,{...q(`crumb`),href:n.href,style:{color:`inherit`,opacity:.7,textDecoration:`none`},children:n.label})]},r)})})}):null}function Oa({pages:e=5,current:t=1,prevNext:n=!0,href:r=`#`,source:i,pageSize:a=6,align:o,hideEmpty:s,inert:c,style:u,nodeRef:d}){let{tenant:f,apiUrl:p,revision:m}=(0,l.useContext)(K),h=(0,l.useContext)(Hn),[g,_]=(0,l.useState)(null),v=i?Number(h?.[`${i}:total`]):NaN;(0,l.useEffect)(()=>{if(!i||Number.isFinite(v))return;let e=!0,t=i.startsWith(`api:`)?`${p}/data/${encodeURIComponent(i.slice(4))}`:`${p}/dynamic/${encodeURIComponent(i)}?limit=1`;return fetch(t,{headers:f?{"x-tenant":f}:{}}).then(e=>e.json()).then(t=>{if(!e)return;let n=t?.payload,r=Array.isArray(n)?n.length:Number(n?.total?.filtered??n?.total?.all??(Array.isArray(n?.data)?n.data.length:0));_(Number.isFinite(r)?r:0)}).catch(()=>e&&_(0)),()=>{e=!1}},[m,i,f,p,v]);let y=Math.max(1,Number(a)||6),b=Number.isFinite(v)?v:g;if(i&&b===null||i&&s&&!(b>0))return null;let x=Math.min(Math.max(i?Math.ceil(b/y):Number(e)||1,1),50),S=Math.min(Math.max(i?Un(h):Number(t)||1,1),x),C=e=>{if(i){if(typeof window<`u`){let t=new URLSearchParams(window.location.search);return t.set(`page`,String(e)),`?${t.toString()}`}return`?page=${e}`}return r&&r!==`#`?r.replace(`{page}`,String(e)):`#`},w=o===`center`?`center`:o===`right`?`flex-end`:`flex-start`,T=c?e=>e.preventDefault():void 0,E=e=>({display:`inline-flex`,alignItems:`center`,justifyContent:`center`,minWidth:36,height:36,padding:`0 8px`,borderRadius:8,fontSize:14,textDecoration:`none`,color:e?`var(--page-accent-text, #ffffff)`:`inherit`,background:e?`var(--page-accent, #111827)`:`transparent`,border:e?`1px solid transparent`:`1px solid rgba(148, 163, 184, 0.4)`});return(0,G.jsxs)(`nav`,{ref:d,"aria-label":`Pagination`,style:{display:`flex`,flexWrap:`wrap`,gap:8,alignItems:`center`,justifyContent:w,...z(u)},children:[n&&(0,G.jsx)(`a`,{...q(`page`,`page-arrow`),href:S>1?C(S-1):`#`,onClick:T,"aria-label":`Previous`,style:{...E(!1),opacity:S>1?1:.4},children:`‹`}),Array.from({length:x},(e,t)=>t+1).map(e=>(0,G.jsx)(`a`,{...q(`page`,e===S&&`page-active`),href:C(e),onClick:T,"aria-current":e===S?`page`:void 0,style:E(e===S),children:e},e)),n&&(0,G.jsx)(`a`,{...q(`page`,`page-arrow`),href:S<x?C(S+1):`#`,onClick:T,"aria-label":`Next`,style:{...E(!1),opacity:S<x?1:.4},children:`›`})]})}var ka=`webim.page_mode`,Aa=()=>{if(typeof window>`u`)return`auto`;try{let e=window.localStorage.getItem(ka);return e===`light`||e===`dark`?e:`auto`}catch{return`auto`}},ja=e=>{let t={width:16,height:16,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0};return e===`light`?(0,G.jsxs)(`svg`,{...t,children:[(0,G.jsx)(`circle`,{cx:`12`,cy:`12`,r:`4`}),(0,G.jsx)(`path`,{d:`M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4`})]}):e===`dark`?(0,G.jsx)(`svg`,{...t,children:(0,G.jsx)(`path`,{d:`M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z`})}):(0,G.jsxs)(`svg`,{...t,children:[(0,G.jsx)(`rect`,{x:`2`,y:`3`,width:`20`,height:`14`,rx:`2`}),(0,G.jsx)(`path`,{d:`M8 21h8M12 17v4`})]})},Ma={light:`Light theme`,dark:`Dark theme`,auto:`Follow the device theme`};function Na({variant:e,showSystem:t,style:n,nodeRef:r,inert:i}){let[a,o]=(0,l.useState)(i?`auto`:Aa),s=(0,l.useRef)(null),c=e=>{s.current=e,typeof r==`function`&&r(e)};(0,l.useEffect)(()=>{if(i)return;let e=s.current?.closest?.(`.webim-page`);e&&(a===`light`||a===`dark`?e.setAttribute(`data-webim-mode`,a):e.removeAttribute(`data-webim-mode`));try{a===`auto`?window.localStorage.removeItem(ka):window.localStorage.setItem(ka,a)}catch{}},[a,i]);let u=t===!1?[`light`,`dark`]:[`light`,`dark`,`auto`],d=u.includes(a)?a:u[0],f={appearance:`none`,border:0,margin:0,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,background:`transparent`,color:`inherit`,font:`inherit`,cursor:i?`default`:`pointer`,borderRadius:999};if(e===`buttons`)return(0,G.jsx)(`div`,{ref:c,role:`group`,"aria-label":`Theme`,style:{display:`inline-flex`,alignItems:`center`,gap:2,padding:3,borderRadius:999,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:u.map(e=>(0,G.jsx)(`button`,{...q(`option`,e===d&&`option-active`),type:`button`,title:Ma[e],"aria-label":Ma[e],"aria-pressed":e===d,onClick:i?void 0:()=>o(e),style:{...f,width:28,height:28,color:e===d?`var(--page-accent-text, #ffffff)`:`inherit`,background:e===d?`var(--page-accent, #111827)`:`transparent`,opacity:e===d?1:.7},children:ja(e)},e))});let p=u[(u.indexOf(d)+1)%u.length];return(0,G.jsx)(`button`,{ref:c,type:`button`,title:Ma[d],"aria-label":`Theme: ${Ma[d]} — switch to ${Ma[p]}`,onClick:i?void 0:()=>o(p),style:{...f,width:36,height:36,border:`1px solid rgba(148, 163, 184, 0.4)`,...z(n)},children:ja(d)})}function Pa(e){let t=e?.parentElement;for(;t&&t!==document.body;){let e=getComputedStyle(t).overflowY;if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t;t=t.parentElement}return window}var Fa=e=>e===window?window.scrollY:e.scrollTop,Ia={"bottom-right":e=>({right:e,bottom:e}),"bottom-left":e=>({left:e,bottom:e}),"bottom-center":e=>({left:`50%`,bottom:e,transform:`translateX(-50%)`})},La={linear:e=>e,out:e=>1-(1-e)**3,inout:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2},Ra=e=>{let t=e.getBoundingClientRect(),n=e.parentElement;for(;n&&n!==document.body;){let e=getComputedStyle(n);if(/(auto|scroll)/.test(e.overflowY)&&n.scrollHeight>n.clientHeight)break;n=n.parentElement}return!n||n===document.body?Math.max(document.documentElement.scrollHeight-(t.bottom+window.scrollY),0):Math.max(n.scrollHeight-(t.bottom-n.getBoundingClientRect().top+n.scrollTop),0)},za=(e,t)=>{let n=typeof e==`number`?e:parseFloat(e);return Number.isFinite(n)?n:t};function Ba(e,{locale:t,decimals:n=0,separator:r=`auto`}={}){let i=Math.min(Math.max(Math.round(za(n,0)),0),6);try{return new Intl.NumberFormat(t||void 0,{minimumFractionDigits:i,maximumFractionDigits:i,useGrouping:r!==`none`}).format(e)}catch{return e.toFixed(i)}}function Va({from:e,to:t,duration:n,delay:r,decimals:i,prefix:a,suffix:o,separator:s,easing:c,trigger:u,offset:d,once:f,label:p,align:m,style:h,nodeRef:g,inert:_}){let{locale:v}=(0,l.useContext)(K),y=Math.max(za(d,0),0),b=za(e,0),x=za(t,100),[S,C]=(0,l.useState)(x),w=(0,l.useRef)(null),[T,E]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=w.current;if(_||!T||!e){C(x);return}C(b);let t=Math.max(za(n,2e3),0),i=Math.max(za(r,0),0),a=La[c]||La.out,o=typeof window<`u`&&window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,s=0,l=0,d=!1,p=()=>{if(cancelAnimationFrame(s),clearTimeout(l),o||t===0){C(x);return}l=setTimeout(()=>{let e=performance.now(),n=r=>{let i=Math.min((r-e)/t,1);C(b+(x-b)*a(i)),i<1&&(s=requestAnimationFrame(n))};s=requestAnimationFrame(n)},i)};if(u===`load`||typeof IntersectionObserver>`u`)return p(),()=>{cancelAnimationFrame(s),clearTimeout(l)};let m=new IntersectionObserver(e=>{let t=e.some(e=>e.isIntersecting);t&&(!d||f===!1)?(d=!0,p()):!t&&f===!1&&(cancelAnimationFrame(s),clearTimeout(l),C(b))},{rootMargin:`0px 0px -${Math.min(y,Math.floor(Ra(e)))}px 0px`,threshold:y>0?0:.3});return m.observe(e),()=>{m.disconnect(),cancelAnimationFrame(s),clearTimeout(l)}},[T,_,b,x,n,r,c,u,y,f]),(0,G.jsxs)(`div`,{ref:e=>{w.current=e,e&&E(!0),typeof g==`function`&&g(e)},"data-wb-counter":``,style:{display:`flex`,flexDirection:`column`,alignItems:m===`left`?`flex-start`:m===`right`?`flex-end`:`center`,gap:4,fontSize:48,fontWeight:700,lineHeight:1.1,textAlign:m===`left`?`left`:m===`right`?`right`:`center`,...z(h)},children:[(0,G.jsxs)(`span`,{...q(`number`),style:{fontVariantNumeric:`tabular-nums`,whiteSpace:`nowrap`},children:[a||``,Ba(S,{locale:v,decimals:i,separator:s}),o||``]}),p?(0,G.jsx)(`span`,{...q(`label`),style:{fontSize:`0.3em`,fontWeight:400,lineHeight:1.4,opacity:.72},children:p}):null]})}function Ha({variant:e,label:t,position:n,offset:r,showAfter:i,smooth:a,bg:o,fg:s,style:c,nodeRef:u,inert:d,frame:f,builder:p}){let[m,h]=(0,l.useState)(!!d),[g,_]=(0,l.useState)(null),v=e=>{_(e),typeof u==`function`&&u(e)};(0,l.useEffect)(()=>{if(d){h(!0);return}if(!g)return;let e=Number(i)>=0?Number(i):300,t=()=>{let t=Pa(g),n=p&&!(t===window?document.documentElement.scrollHeight>window.innerHeight:t.scrollHeight>t.clientHeight);h(n||Fa(t)>e)};return t(),document.addEventListener(`scroll`,t,{capture:!0,passive:!0}),()=>document.removeEventListener(`scroll`,t,{capture:!0})},[d,g,i,p]);let y=()=>{if(d)return;let e=Pa(g),t=window.matchMedia?.(`(prefers-reduced-motion: reduce)`).matches,n=a===!1||t?`auto`:`smooth`;e===window?window.scrollTo({top:0,behavior:n}):e.scrollTo({top:0,behavior:n})},b=Number(r)>=0?Number(r):24,x=e===`pill`,S=t||`Top`,C=Ia[n]?n:`bottom-right`,w=f?{position:`fixed`,zIndex:5,bottom:(f.bottom??0)+b,...C===`bottom-left`?{left:(f.left??0)+b}:null,...C===`bottom-right`?{right:(f.right??0)+b}:null,...C===`bottom-center`?{left:(f.left??0)+(f.width??0)/2,transform:`translateX(-50%)`}:null}:{position:`fixed`,zIndex:2147482e3,...Ia[C](b)};return(0,G.jsxs)(`button`,{ref:v,type:`button`,title:S,"aria-label":S,"aria-hidden":!m,tabIndex:m?0:-1,onClick:y,style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,gap:x?8:0,appearance:`none`,font:`inherit`,fontSize:14,fontWeight:600,width:x?`auto`:44,height:44,padding:x?`0 18px`:0,borderRadius:999,border:`1px solid transparent`,background:o||`var(--page-accent, #111827)`,color:s||`var(--page-accent-text, #ffffff)`,boxShadow:`0 6px 20px rgba(15, 23, 42, 0.25)`,cursor:d?`default`:`pointer`,opacity:+!!m,pointerEvents:m?`auto`:`none`,transition:`opacity 160ms ease, transform 160ms ease`,...w,...z(c),...w.transform?{transform:w.transform}:null},children:[(0,G.jsx)(`svg`,{...q(`icon`),width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":`true`,children:(0,G.jsx)(`path`,{d:`M12 19V5M12 5l-7 7M12 5l7 7`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`})}),x?(0,G.jsx)(`span`,{...q(`label`),children:S}):null]})}var Ua={facebook:{label:`Facebook`,color:`#1877f2`,d:`M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z`},instagram:{label:`Instagram`,color:`#e4405f`,d:`M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24 12 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06zm0 5.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z`},x:{label:`X (Twitter)`,color:`#000000`,d:`M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z`},linkedin:{label:`LinkedIn`,color:`#0a66c2`,d:`M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z`},youtube:{label:`YouTube`,color:`#ff0000`,d:`M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z`},tiktok:{label:`TikTok`,color:`#000000`,d:`M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z`},whatsapp:{label:`WhatsApp`,color:`#25d366`,d:`M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z`},telegram:{label:`Telegram`,color:`#26a5e4`,d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`},pinterest:{label:`Pinterest`,color:`#bd081c`,d:`M12 0C5.373 0 0 5.372 0 12c0 5.084 3.163 9.426 7.627 11.174-.105-.949-.2-2.405.042-3.441.218-.937 1.407-5.965 1.407-5.965s-.359-.719-.359-1.782c0-1.668.967-2.914 2.171-2.914 1.023 0 1.518.769 1.518 1.69 0 1.03-.655 2.569-.994 3.995-.283 1.194.599 2.169 1.777 2.169 2.133 0 3.772-2.249 3.772-5.495 0-2.873-2.064-4.882-5.012-4.882-3.414 0-5.418 2.561-5.418 5.207 0 1.031.397 2.138.893 2.738a.36.36 0 01.083.345l-.333 1.36c-.053.22-.174.267-.402.161-1.499-.698-2.436-2.889-2.436-4.649 0-3.785 2.75-7.262 7.929-7.262 4.163 0 7.398 2.967 7.398 6.931 0 4.136-2.607 7.464-6.227 7.464-1.216 0-2.359-.631-2.75-1.378l-.748 2.853c-.271 1.043-1.002 2.35-1.492 3.146C9.57 23.812 10.763 24 12 24c6.627 0 12-5.373 12-12 0-6.628-5.373-12-12-12z`},github:{label:`GitHub`,color:`#181717`,d:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`},discord:{label:`Discord`,color:`#5865f2`,d:`M20.317 4.37a19.791 19.791 0 00-4.885-1.515.074.074 0 00-.079.037c-.21.375-.444.865-.608 1.25a18.27 18.27 0 00-5.487 0 12.64 12.64 0 00-.617-1.25.077.077 0 00-.079-.037A19.736 19.736 0 003.677 4.37a.07.07 0 00-.032.027C.533 9.046-.32 13.58.099 18.058a.082.082 0 00.031.056 19.9 19.9 0 005.993 3.03.078.078 0 00.084-.028c.462-.63.873-1.295 1.226-1.994a.076.076 0 00-.041-.106 13.107 13.107 0 01-1.872-.892.077.077 0 01-.008-.128c.126-.094.252-.192.372-.291a.074.074 0 01.077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 01.078.009c.12.099.246.198.373.292a.077.077 0 01-.006.127 12.299 12.299 0 01-1.873.892.077.077 0 00-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 00.084.028 19.839 19.839 0 006.002-3.03.077.077 0 00.032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 00-.031-.03zM8.02 15.331c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z`},email:{label:`E-mail`,color:`#64748b`,d:`M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z`},website:{label:`Website`,color:`#64748b`,d:`M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z`}};function Wa({links:e=[],variant:t,color:n,size:r,gap:i,newTab:a,style:o,nodeRef:s,inert:c}){let l=Array.isArray(e)?e.filter(e=>e&&Ua[e.network]):[];if(!l.length)return null;let u=Math.min(Math.max(Number(r)||18,10),64),d=Math.round(u*1.9),f=Number.isFinite(Number(i))?Number(i):10,p=e=>n===`accent`?`var(--page-accent, #111827)`:n===`inherit`?`currentColor`:e.color,m=c?e=>e.preventDefault():void 0;return(0,G.jsx)(`div`,{ref:s,style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:f,...z(o)},children:l.map((e,r)=>{let i=Ua[e.network],o=t!==`outline`&&t!==`plain`,s=o?n===`accent`?`var(--page-accent-text, #ffffff)`:n===`inherit`?`var(--page-bg, #ffffff)`:`#ffffff`:p(i);return(0,G.jsx)(`a`,{...q(`link`,/^[a-z]+$/.test(e.network??``)&&`link-${e.network}`),href:e.url||`#`,onClick:m,"aria-label":e.label||i.label,title:e.label||i.label,...a!==!1&&!c?{target:`_blank`,rel:`noopener noreferrer`}:{},style:{display:`inline-flex`,alignItems:`center`,justifyContent:`center`,width:t===`plain`?u:d,height:t===`plain`?u:d,borderRadius:`50%`,background:o?p(i):`transparent`,border:t===`outline`?`1px solid ${p(i)}`:`none`,color:`inherit`,textDecoration:`none`},children:(0,G.jsx)(`svg`,{...q(`icon`),width:u,height:u,viewBox:`0 0 24 24`,fill:s,"aria-hidden":!0,children:(0,G.jsx)(`path`,{d:i.d})})},`${e.network}-${r}`)})})}function Ga({steps:e=[],active:t=1,vertical:n=!1,style:r,nodeRef:i}){if(!e.length)return null;let a=Math.min(Math.max(Number(t)||1,1),e.length),o=e=>({width:32,height:32,borderRadius:`50%`,display:`flex`,alignItems:`center`,justifyContent:`center`,fontSize:14,fontWeight:600,flexShrink:0,color:e===`todo`?`inherit`:`var(--page-accent-text, #ffffff)`,background:e===`todo`?`transparent`:`var(--page-accent, #111827)`,border:e===`todo`?`1px solid rgba(148, 163, 184, 0.5)`:`1px solid transparent`,opacity:e===`todo`?.6:1,boxShadow:e===`active`?`0 0 0 4px rgba(99, 102, 241, 0.2)`:`none`}),s=e=>({flexGrow:1,alignSelf:`center`,background:e?`var(--page-accent, #111827)`:`rgba(148, 163, 184, 0.4)`,...n?{width:2,minHeight:24,marginLeft:15,alignSelf:`auto`}:{height:2,minWidth:24}});return(0,G.jsx)(`div`,{ref:i,style:{display:`flex`,flexDirection:n?`column`:`row`,alignItems:n?`stretch`:`flex-start`,gap:n?4:8,...z(r)},children:e.map((e,t)=>{let r=t+1,i=r<a?`done`:r===a?`active`:`todo`;return(0,G.jsxs)(l.Fragment,{children:[t>0&&(0,G.jsx)(`div`,{...q(`step-line`,r<=a&&`step-line-done`),style:s(r<=a),"aria-hidden":!0}),(0,G.jsxs)(`div`,{...q(`step`,`step-${i}`),style:{display:`flex`,flexDirection:n?`row`:`column`,alignItems:`center`,gap:8,minWidth:0,textAlign:n?`left`:`center`},children:[(0,G.jsx)(`div`,{...q(`step-circle`,`step-circle-${i}`),style:o(i),children:i===`done`?`✓`:r}),(0,G.jsxs)(`div`,{style:{minWidth:0},children:[(0,G.jsx)(`div`,{...q(`step-label`,`step-label-${i}`),style:{fontSize:13,fontWeight:i===`active`?700:500,opacity:i===`todo`?.6:1},children:e.label}),e.description&&(0,G.jsx)(`div`,{...q(`step-description`),style:{fontSize:12,opacity:.6},children:e.description})]})]})]},t)})})}var Ka={small:{w:132,h:46,name:11.5,title:10,avatar:28},medium:{w:168,h:56,name:13,title:11,avatar:36},large:{w:210,h:70,name:15.5,title:12.5,avatar:46}},qa=e=>Ka[e]??Ka.medium;Ka.medium.w,Ka.medium.h;var Ja=e=>String(e?.group??``).trim(),Ya=e=>{let t=[],n=new Map;return e.forEach((e,r)=>{let i=Ja(e)||`#${r}`;n.has(i)||(n.set(i,[]),t.push(i)),n.get(i).push(e)}),t.flatMap(e=>n.get(e))},Xa=20,Za=12,Qa=[`left`,`center`,`right`],$a=e=>e.points.map((e,t)=>`${t?`L`:`M`} ${e.x} ${e.y}`).join(` `);function eo(e,{size:t=`medium`,horizontal:n=!1,groupTitles:r=`top`,columns:i=`off`}={}){let a=qa(t),o=n?a.h:a.w,s=n?16:20,c=(n?a.w:a.h)+(n?56:48),l=Array.isArray(e)?e.filter(e=>e&&e.id):[],u=new Set(l.map(e=>e.id)),d=new Map,f=[];for(let e of l)e.parent&&u.has(e.parent)&&e.parent!==e.id?(d.has(e.parent)||d.set(e.parent,[]),d.get(e.parent).push(e)):f.push(e);f=Ya(f);for(let[e,t]of d)d.set(e,Ya(t));let p=!n&&Qa.includes(i),m=e=>Qa.includes(e?.columns)?e.columns:i,h=e=>{let t=d.get(e.id)??[];if(!p)return t.map(e=>({nodes:[e]}));let n=[],r=[],i=()=>{r.length>1?n.push({nodes:r,line:m(e)}):r.forEach(e=>n.push({nodes:[e]})),r=[]};for(let e of t){let t=!(d.get(e.id)??[]).length;r.length&&(!t||Ja(r[0])!==Ja(e))&&i(),t?r.push(e):n.push({nodes:[e]})}return i(),n},g=(e,t)=>s+(Ja(e)!==Ja(t)&&(Ja(e)||Ja(t))?24:0),_=(e,t)=>g(e.nodes.at(-1),t.nodes[0]),v=e=>o+(e.line===`center`?0:Xa),y=new Map,b=(e,t)=>{if(t.has(e.id))return 0;t.add(e.id);let n=h(e),r=n.reduce((e,r,i)=>{let a=r.line?v(r):b(r.nodes[0],t);return r.line&&r.nodes.forEach(e=>t.add(e.id)),e+a+(i?_(n[i-1],r):0)},0),i=Math.max(o,r);return y.set(e.id,i),i};f.forEach(e=>b(e,new Set));let x=[],S=[],C=new Map,w=0,T=(e,t,r)=>{x.push({node:e,x:t,y:r});let i=Ja(e);if(i){let n=`${e.parent&&u.has(e.parent)&&e.parent!==e.id?e.parent:``}|${i}`;C.has(n)||C.set(n,{title:i,color:``,members:[]});let a=C.get(n);!a.color&&e.groupColor&&(a.color=e.groupColor),a.members.push({x:t,y:r})}w=Math.max(w,n?t+a.w:r+a.h)},E=(e,t,n,r)=>{let i=t+(e.line===`left`?Xa:0),o=n*c,s=r.y+(o-r.y)/2,l=e.line===`left`?i-Xa/2:i+a.w+Xa/2;e.nodes.forEach((t,n)=>{let c=o+n*(a.h+Za),u=c+a.h/2;if(T(t,i,c),e.line===`center`)S.push(n?{points:[{x:i+a.w/2,y:c-Za},{x:i+a.w/2,y:c}]}:{points:[r,{x:r.x,y:s},{x:i+a.w/2,y:s},{x:i+a.w/2,y:c}]});else{let t=e.line===`left`?i:i+a.w;S.push({points:[r,{x:r.x,y:s},{x:l,y:s},{x:l,y:u},{x:t,y:u}]})}})},D=(e,t,r,i)=>{if(i.has(e.id))return;i.add(e.id);let s=t+((y.get(e.id)??o)-o)/2,l=r*c;T(e,n?l:s,n?s:l);let u=t,d=h(e),f=n?{x:l+a.w,y:s+a.h/2}:{x:s+a.w/2,y:l+a.h};d.forEach((e,t)=>{if(t&&(u+=_(d[t-1],e)),e.line){E(e,u,r+1,f),e.nodes.forEach(e=>i.add(e.id)),u+=v(e);return}let a=e.nodes[0],s=u+((y.get(a.id)??o)-o)/2+o/2,l=(r+1)*c;S.push({points:n?[f,{x:(f.x+l)/2,y:f.y},{x:(f.x+l)/2,y:s},{x:l,y:s}]:[f,{x:f.x,y:(f.y+l)/2},{x:s,y:(f.y+l)/2},{x:s,y:l}]}),D(a,u,r+1,i),u+=y.get(a.id)??o})},O=0,k=new Set;f.forEach((e,t)=>{t&&(O+=g(f[t-1],e)),D(e,O,0,k),O+=y.get(e.id)??o});let A=Math.max(O,o),j=r===`hidden`?0:22,M=[...C.values()].map(e=>{let t=Math.min(...e.members.map(e=>e.x))-12,n=Math.max(...e.members.map(e=>e.x))+a.w+12,i=Math.min(...e.members.map(e=>e.y))-12-(r===`bottom`?0:j),o=Math.max(...e.members.map(e=>e.y))+a.h+12+(r===`bottom`?j:0);return{x:t,y:i,width:n-t,height:o-i,title:e.title,color:e.color}}),N=n?Math.max(w,a.w):A,P=n?A:Math.max(w,a.h),F=Math.max(0,...M.map(e=>-e.x)),I=Math.max(0,...M.map(e=>-e.y));if(M.length&&(N=Math.max(N,...M.map(e=>e.x+e.width))+F,P=Math.max(P,...M.map(e=>e.y+e.height))+I,F||I)){for(let e of x)e.x+=F,e.y+=I;for(let e of S)e.points=e.points.map(e=>({x:e.x+F,y:e.y+I}));for(let e of M)e.x+=F,e.y+=I}return{boxes:x,links:S,groups:M,width:N,height:P,horizontal:n}}var to=(e,t)=>{let n=String(e??``);return n.length>t?`${n.slice(0,t-1)}…`:n},no=e=>{let t=/^#([0-9a-f]{6}|[0-9a-f]{3})$/i.exec(String(e??``).trim());if(!t)return`#ffffff`;let n=t[1];n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=parseInt(n,16);return .299*(r>>16&255)+.587*(r>>8&255)+.114*(r&255)>150?`#111827`:`#ffffff`},ro=e=>!!(e?.cv?.trim?.()||e?.photo||e?.profilePhoto||e?.profile?.length);function Y(e,t={}){let n=Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.id):[],r=e=>Array.isArray(e)?e[0]:e,i=e=>e==null?``:rr(e);return n.map(e=>{let n=e.data??{},a=r(n[t.parentField]),o=a&&typeof a==`object`?a.id??null:a||null;return{id:e.id,name:i(n[t.nameField||`name`])||i(n.name)||`Untitled`,title:t.titleField?i(n[t.titleField]):``,photo:t.photoField&&r(n[t.photoField])||``,parent:t.parentField?o:null,cv:t.cvField?i(n[t.cvField]):``,href:t.hrefField?i(n[t.hrefField]):``,group:t.groupField?i(n[t.groupField]):``}})}var io=/^(https?:\/\/[^\s"<>]+|mailto:[^\s"<>]+|tel:[+\d][\d\s().-]*|\/(?!\/)[^\s"<>]*)$/i,ao=e=>{let t=String(e??``).trim();return io.test(t)?t:``},oo=e=>{e.startsWith(`/`)?window.location.assign(e):window.open(e,`_blank`,`noopener,noreferrer`)},so={size:36,pad:10};function co({node:e,onClose:t}){(0,l.useEffect)(()=>{let e=e=>e.key===`Escape`&&t();return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let n=e.profile?.length?e.profile:null,r=n?``:e.profilePhoto||e.photo,i=e.title||e.name,a=e.title&&e.name?e.name:``,o=!!(n||r&&e.cv),s=ao(e.href);return(0,G.jsx)(`div`,{onClick:t,role:`dialog`,"aria-modal":`true`,"aria-label":i,style:{position:`fixed`,inset:0,zIndex:1e3,background:`rgba(2, 6, 23, 0.6)`,backdropFilter:`blur(4px)`,WebkitBackdropFilter:`blur(4px)`,display:`flex`,alignItems:`center`,justifyContent:`center`,padding:16},children:(0,G.jsxs)(`div`,{onClick:e=>e.stopPropagation(),style:{background:`var(--page-surface, #f2f2f2)`,color:`var(--page-text, #111827)`,border:`1px solid rgba(148, 163, 184, 0.35)`,borderRadius:14,maxWidth:o?900:440,width:`100%`,maxHeight:`85vh`,display:`flex`,flexDirection:`column`,overflow:`hidden`,boxShadow:`0 24px 64px rgba(2, 6, 23, 0.5)`},children:[(0,G.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:12,padding:`18px 20px 14px 24px`,borderBottom:`1px solid rgba(148, 163, 184, 0.3)`},children:[(0,G.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,G.jsx)(`div`,{style:{fontSize:18,fontWeight:700,lineHeight:1.35},children:i}),a&&(0,G.jsx)(`div`,{style:{fontSize:14,opacity:.7,marginTop:2},children:a})]}),(0,G.jsx)(`button`,{type:`button`,"aria-label":`Close`,onClick:t,style:{flexShrink:0,width:32,height:32,border:0,borderRadius:8,background:`transparent`,color:`inherit`,fontSize:20,lineHeight:1,cursor:`pointer`,opacity:.6},children:`×`})]}),(0,G.jsxs)(`div`,{style:{overflowY:`auto`,padding:24,display:`flex`,flexWrap:`wrap`,gap:24,alignItems:`flex-start`},children:[r&&(0,G.jsx)(`img`,{src:r,alt:e.name||i,style:o?{flex:`1 1 220px`,maxWidth:340,width:`100%`,height:`auto`,borderRadius:10,objectFit:`cover`}:{width:96,height:96,borderRadius:`50%`,objectFit:`cover`}}),(n||e.cv||s)&&(0,G.jsxs)(`div`,{style:{flex:`2 1 320px`,minWidth:0},children:[n&&(0,G.jsx)(`div`,{style:{display:`flow-root`,marginBottom:s?12:0},children:Br(n)}),!n&&e.cv&&String(e.cv).split(/\n+/).map((e,t)=>(0,G.jsx)(`p`,{style:{fontSize:15,lineHeight:1.65,margin:`0 0 12px`},children:e},t)),s&&(0,G.jsx)(`a`,{href:s,target:`_blank`,rel:`noopener noreferrer`,style:{display:`inline-block`,marginTop:6,padding:`8px 14px`,borderRadius:8,fontSize:13,fontWeight:600,textDecoration:`none`,background:`var(--page-accent, #4f46e5)`,color:`var(--page-accent-text, #ffffff)`},children:`Open profile ↗`})]})]})]})})}function lo(e){return e.chart?.people?.length?(0,G.jsx)(uo,{...e}):(0,G.jsx)(fo,{...e})}function uo({chart:e,profiles:t,style:n,nodeRef:r,interactive:i=!0}){let[a,o]=(0,l.useState)(null),s=(0,l.useMemo)(()=>vn(e),[e]),c=(0,l.useMemo)(()=>new Set(e.people.map(e=>e.parent)),[e]);return(0,G.jsxs)(`div`,{ref:r,style:{maxWidth:`100%`,overflowX:`auto`,...z(n)},children:[(0,G.jsxs)(`svg`,{viewBox:`0 0 ${s.width} ${s.height}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:s.width,height:`auto`,margin:`0 auto`},children:[s.frames.map(({person:e,x:t,y:n,width:r,height:i})=>(0,G.jsx)(`foreignObject`,{x:t,y:n,width:r,height:i,children:(0,G.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:Bn(e,c.has(e.id))}})},e.id)),s.links.map((e,t)=>(0,G.jsx)(`path`,{d:Tn(e),fill:`none`,stroke:Mn.line,strokeWidth:`1.5`},t)),s.cards.map(({person:n,x:r,y:a,width:c,height:l})=>{let u=Array.isArray(t?.[n.id])&&t[n.id].length?t[n.id]:null,d={id:n.id,name:n.name,title:n.title,cv:n.description,photo:n.photo,profilePhoto:n.photo,href:n.link,profile:u},f=ao(n.link),p=i&&(f||ro(d)),m=()=>f?oo(f):o(d);return(0,G.jsx)(`g`,{onClick:p?m:void 0,onKeyDown:p?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),m())}:void 0,tabIndex:p?0:void 0,style:p?{cursor:`pointer`}:void 0,role:p?f?`link`:`button`:void 0,"aria-label":p?f?`${n.name||n.title} — open link`:`Open ${n.name||n.title}'s profile`:void 0,children:(0,G.jsx)(`foreignObject`,{x:r,y:a,width:c,height:l,children:(0,G.jsx)(`div`,{style:{width:`100%`,height:`100%`},dangerouslySetInnerHTML:{__html:zn(n,e,s.size,Mn)}})})},n.id)})]}),a&&(0,G.jsx)(co,{node:a,onClose:()=>o(null)})]})}function fo({nodes:e=[],source:t,nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c,groupTitles:u=`top`,groupBg:d=``,size:f=`medium`,horizontal:p=!1,columns:m=`off`,style:h,nodeRef:g,interactive:_=!0}){let v=(0,l.useId)(),[y,b]=(0,l.useState)(null),{tenant:x,apiUrl:S,revision:C}=(0,l.useContext)(K),w=(0,l.useContext)(Hn)?.[t],[T,E]=(0,l.useState)(null);(0,l.useEffect)(()=>{if(!t||w)return;let e=!0;return fetch(`${S}/dynamic/${encodeURIComponent(t)}`,{headers:x?{"x-tenant":x}:{}}).then(e=>e.json()).then(t=>{let n=Array.isArray(t?.payload)?t.payload:Array.isArray(t?.payload?.data)?t.payload.data:[];e&&E(n)}).catch(()=>e&&E([])),()=>{e=!1}},[C,t,x,S,w]);let D=t?Y(w??T??[],{nameField:n,titleField:r,photoField:i,parentField:a,cvField:o,hrefField:s,groupField:c}):e,O=qa(f),{boxes:k,links:A,groups:j,width:M,height:N}=eo(D,{size:f,horizontal:p,groupTitles:u,columns:m});if(!k.length)return!_&&t?(0,G.jsxs)(`div`,{ref:g,style:{padding:18,border:`1px dashed rgba(148, 163, 184, 0.6)`,borderRadius:10,fontSize:13,opacity:.7,textAlign:`center`,...z(h)},children:[`Org Chart — no published entries in “`,t,`” yet`]}):null;let P=new Set(k.filter(e=>e.node.parent==null||e.node.parent===``).map(e=>e.node.id));return(0,G.jsxs)(`div`,{ref:g,style:{maxWidth:`100%`,overflowX:`auto`,...z(h)},children:[(0,G.jsxs)(`svg`,{viewBox:`0 0 ${M} ${N}`,role:`img`,"aria-label":`Organization chart`,style:{display:`block`,width:`100%`,maxWidth:M,height:`auto`,margin:`0 auto`},children:[j.map((e,t)=>{let n=e.color||d||`rgba(148, 163, 184, 0.16)`,r=!!(e.color||d);return(0,G.jsxs)(`g`,{children:[(0,G.jsx)(`rect`,{x:e.x,y:e.y,width:e.width,height:e.height,rx:`16`,fill:n}),u!==`hidden`&&e.title&&(0,G.jsx)(`text`,{x:e.x+e.width/2,y:u===`bottom`?e.y+e.height-22*.42:e.y+22*.78,textAnchor:`middle`,fontSize:O.title+1,fontWeight:`600`,opacity:`0.55`,fill:r?no(e.color||d):`var(--page-text, #111827)`,children:to(e.title,Math.floor(e.width/7))})]},`group-${t}`)}),A.map((e,t)=>(0,G.jsx)(`path`,{d:$a(e),fill:`none`,stroke:`rgba(148, 163, 184, 0.7)`,strokeWidth:`1.5`},t)),k.map(({node:e,x:t,y:n})=>{let r=P.has(e.id),i=!!e.color2,a=!!e.color||r||i,o=e.color||(r?`var(--page-accent, #4f46e5)`:`var(--page-bg, #ffffff)`),s=e.color?no(e.color):r?`var(--page-accent-text, #ffffff)`:`var(--page-text, #111827)`,c=i?no(e.color2):s,l=ao(e.href),u=_&&(l||ro(e)),d=()=>l?oo(l):b(e),f=e.photo?t+so.pad+O.avatar+8:t+O.w/2,p=e.photo?`start`:`middle`,m=e.photo?Math.floor((O.w-O.avatar-26)/7):Math.floor(O.w/7.6),h=O.h/2,g=[e.name,e.title].map(e=>String(e??``).trim()).filter(Boolean);return(0,G.jsxs)(`g`,{onClick:u?d:void 0,onKeyDown:u?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),d())}:void 0,tabIndex:u?0:void 0,style:u?{cursor:`pointer`}:void 0,role:u?l?`link`:`button`:void 0,"aria-label":u?l?`${e.name||e.title} — open link`:`Open ${e.name||e.title}'s profile`:void 0,children:[i&&e.gradient?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(`linearGradient`,{id:`${v}-${e.id}-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,G.jsx)(`stop`,{offset:`0%`,stopColor:e.color||`var(--page-accent, #4f46e5)`}),(0,G.jsx)(`stop`,{offset:`100%`,stopColor:e.color2})]}),(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:`url(#${v}-${e.id}-grad)`})]}):i?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`clipPath`,{id:`${v}-${e.id}-box`,children:(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`})}),(0,G.jsxs)(`g`,{clipPath:`url(#${v}-${e.id}-box)`,children:[(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:h,fill:o}),(0,G.jsx)(`rect`,{x:t,y:n+h,width:O.w,height:O.h-h,fill:e.color2})]})]}):(0,G.jsx)(`rect`,{x:t,y:n,width:O.w,height:O.h,rx:`10`,fill:o,stroke:a?`none`:`var(--page-accent, #4f46e5)`,strokeWidth:a?0:1.5}),e.photo&&(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`clipPath`,{id:`${v}-${e.id}`,children:(0,G.jsx)(`circle`,{cx:t+so.pad+O.avatar/2,cy:n+O.h/2,r:O.avatar/2})}),(0,G.jsx)(`image`,{href:e.photo,x:t+so.pad,y:n+(O.h-O.avatar)/2,width:O.avatar,height:O.avatar,preserveAspectRatio:`xMidYMid slice`,clipPath:`url(#${v}-${e.id})`})]}),i&&!e.gradient?(0,G.jsxs)(G.Fragment,{children:[e.title&&(0,G.jsx)(`text`,{x:f,y:n+h/2+O.title*.35,textAnchor:p,fontSize:O.title,fontWeight:`600`,fill:s,children:to(e.title,m+4)}),e.name&&(0,G.jsx)(`text`,{x:f,y:n+h+h/2+O.name*.35,textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:c,children:to(e.name,m)})]}):(0,G.jsxs)(G.Fragment,{children:[g[0]&&(0,G.jsx)(`text`,{x:f,y:n+(g[1]?O.h*.43:O.h*.57),textAnchor:p,fontSize:O.name,fontWeight:`600`,fill:s,children:to(g[0],m)}),g[1]&&(0,G.jsx)(`text`,{x:f,y:n+O.h*.73,textAnchor:p,fontSize:O.title,opacity:`0.7`,fill:s,children:to(g[1],m+4)})]})]},e.id)})]}),y&&(0,G.jsx)(co,{node:y,onClose:()=>b(null)})]})}function po({value:e,onCommit:t,style:n,hint:r}){let[i,a]=(0,l.useState)(!1),o=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!i||!o.current)return;let e=o.current,t=document.createRange();e.focus(),t.selectNodeContents(e),t.collapse(!1);let n=window.getSelection();n.removeAllRanges(),n.addRange(t)},[i]),(0,G.jsx)(`span`,{ref:o,contentEditable:i,suppressContentEditableWarning:!0,title:i?void 0:r||`Double-click to edit`,onDoubleClick:()=>a(!0),onBlur:i?e=>{a(!1),t(e.currentTarget.textContent)}:void 0,onKeyDown:i?t=>{t.stopPropagation(),t.key===`Escape`&&(t.currentTarget.textContent=e??``,t.currentTarget.blur()),t.key===`Enter`&&(t.preventDefault(),t.currentTarget.blur())}:void 0,style:{display:`block`,minHeight:`1em`,outline:`none`,cursor:i?`text`:`inherit`,...n},children:e??``})}var mo=360,ho=`
25
25
  .wb-tedit-btn {
26
26
  cursor: pointer;
27
27
  border-radius: 4px;
@@ -4775,47 +4775,51 @@ function Hi({ tabs: e = [], linked: t, style: n, nodeRef: r }) {
4775
4775
  }, e.key))]
4776
4776
  });
4777
4777
  }
4778
- function Ui({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i, padY: a, headerBg: o, headerColor: c, openBg: u, openColor: d, borderColor: p, style: m, nodeRef: h }) {
4779
- let [v, y] = f(() => new Set(e.length ? [e[0].key] : [])), { locale: b } = s(X), x = l();
4778
+ function Ui({ items: e = [], linked: t, multiple: n = !1, startOpen: r = "first", icon: i = "", padX: a, padY: o, headerBg: u, headerColor: d, openBg: p, openColor: m, borderColor: h, style: v, nodeRef: y }) {
4779
+ let b = () => !e.length || r === "none" ? /* @__PURE__ */ new Set() : r === "all" && n ? new Set(e.map((e) => e.key)) : /* @__PURE__ */ new Set([e[0].key]), [x, S] = f(b), { locale: C } = s(X);
4780
+ c(() => {
4781
+ S(b());
4782
+ }, [r, n]);
4783
+ let w = l();
4780
4784
  if (!e.length) return null;
4781
- let S = lt(b), C = (e, t) => typeof e == "string" && e ? e : t, w = (e, t) => {
4785
+ let T = lt(C), E = (e, t) => typeof e == "string" && e ? e : t, D = (e, t) => {
4782
4786
  let n = Number(e);
4783
4787
  return e === "" || e == null || !Number.isFinite(n) ? t : n;
4784
- }, T = Oi[r], E = (e) => y((t) => {
4788
+ }, O = Oi[i], k = (e) => S((t) => {
4785
4789
  let r = new Set(n ? t : []);
4786
4790
  return t.has(e) ? r.delete(e) : r.add(e), r;
4787
4791
  });
4788
4792
  return /* @__PURE__ */ g("div", {
4789
- ref: h,
4793
+ ref: y,
4790
4794
  style: {
4791
4795
  width: "100%",
4792
- ...q(m)
4796
+ ...q(v)
4793
4797
  },
4794
4798
  children: e.map((n, r) => {
4795
- let s = v.has(n.key);
4799
+ let i = x.has(n.key);
4796
4800
  return /* @__PURE__ */ _("div", {
4797
- ...Z("item", s && "item-open"),
4798
- style: { borderBottom: r < e.length - 1 ? `1px solid ${C(p, "rgba(148, 163, 184, 0.35)")}` : "none" },
4801
+ ...Z("item", i && "item-open"),
4802
+ style: { borderBottom: r < e.length - 1 ? `1px solid ${E(h, "rgba(148, 163, 184, 0.35)")}` : "none" },
4799
4803
  children: [/* @__PURE__ */ _("button", {
4800
4804
  type: "button",
4801
- ...Z("header", s && "header-open"),
4802
- id: `${x}-h-${n.key}`,
4803
- "aria-expanded": s,
4804
- "aria-controls": `${x}-b-${n.key}`,
4805
- onClick: () => E(n.key),
4805
+ ...Z("header", i && "header-open"),
4806
+ id: `${w}-h-${n.key}`,
4807
+ "aria-expanded": i,
4808
+ "aria-controls": `${w}-b-${n.key}`,
4809
+ onClick: () => k(n.key),
4806
4810
  style: {
4807
4811
  width: "100%",
4808
4812
  display: "flex",
4809
4813
  alignItems: "center",
4810
4814
  justifyContent: "space-between",
4811
4815
  gap: 12,
4812
- background: s ? C(u, C(o, "transparent")) : C(o, "transparent"),
4816
+ background: i ? E(p, E(u, "transparent")) : E(u, "transparent"),
4813
4817
  border: 0,
4814
- padding: `${w(a, 14)}px ${w(i, 4)}px`,
4818
+ padding: `${D(o, 14)}px ${D(a, 4)}px`,
4815
4819
  fontSize: 15,
4816
4820
  fontWeight: 600,
4817
4821
  fontFamily: "inherit",
4818
- color: s ? C(d, C(c, "inherit")) : C(c, "inherit"),
4822
+ color: i ? E(m, E(d, "inherit")) : E(d, "inherit"),
4819
4823
  textAlign: "left",
4820
4824
  cursor: "pointer",
4821
4825
  transition: "background 180ms, color 180ms"
@@ -4828,7 +4832,7 @@ function Ui({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i,
4828
4832
  gap: 10,
4829
4833
  minWidth: 0
4830
4834
  },
4831
- children: [T ? /* @__PURE__ */ g("svg", {
4835
+ children: [O ? /* @__PURE__ */ g("svg", {
4832
4836
  ...Z("icon"),
4833
4837
  viewBox: "0 0 24 24",
4834
4838
  width: 16,
@@ -4840,27 +4844,27 @@ function Ui({ items: e = [], linked: t, multiple: n = !1, icon: r = "", padX: i,
4840
4844
  strokeLinejoin: "round",
4841
4845
  "aria-hidden": "true",
4842
4846
  style: { flexShrink: 0 },
4843
- children: /* @__PURE__ */ g("path", { d: T })
4844
- }) : null, n.title || S("item", { n: r + 1 })]
4847
+ children: /* @__PURE__ */ g("path", { d: O })
4848
+ }) : null, n.title || T("item", { n: r + 1 })]
4845
4849
  }), /* @__PURE__ */ g("span", {
4846
4850
  "aria-hidden": "true",
4847
4851
  ...Z("chevron"),
4848
4852
  style: {
4849
4853
  fontSize: 12,
4850
4854
  opacity: .6,
4851
- transform: s ? "rotate(180deg)" : "none",
4855
+ transform: i ? "rotate(180deg)" : "none",
4852
4856
  transition: "transform 180ms"
4853
4857
  },
4854
4858
  children: "▼"
4855
4859
  })]
4856
4860
  }), /* @__PURE__ */ g("div", {
4857
4861
  ...Z("body"),
4858
- id: `${x}-b-${n.key}`,
4862
+ id: `${w}-b-${n.key}`,
4859
4863
  role: "region",
4860
- "aria-labelledby": `${x}-h-${n.key}`,
4861
- hidden: !s,
4864
+ "aria-labelledby": `${w}-h-${n.key}`,
4865
+ hidden: !i,
4862
4866
  style: {
4863
- display: s ? "flex" : "none",
4867
+ display: i ? "flex" : "none",
4864
4868
  flexDirection: "column"
4865
4869
  },
4866
4870
  children: t?.[n.key] ?? null
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "webim-adapter",
3
- "version": "2.9.4",
3
+ "version": "2.10.1",
4
4
  "description": "Render Web-IM builder pages inside any React app",
5
5
  "author": "Orhan POLAT",
6
6
  "license": "ISC",