PageSourceSearch

https://sonance.com/cdn/shop/t/8/assets/index.js?v=178914091797787030331790197733

js sonance.com collected 2026-10-02 16:30:19 UTC 176,509 bytes, 97 lines download raw bytes

1var Es=Object.defineProperty,As=(n,t,e)=>t in n?Es(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e,qt=(n,t,e)=>(As(n,typeof t!="symbol"?t+"":t,e),e),pr=(n,t,e)=>{if(!t.has(n))throw TypeError("Cannot "+e)},l=(n,t,e)=>(pr(n,t,"read from private field"),e?e.call(n):t.get(n)),S=(n,t,e)=>{if(t.has(n))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(n):t.set(n,e)},D=(n,t,e,i)=>(pr(n,t,"write to private field"),i?i.call(n,e):t.set(n,e),e),C=(n,t,e)=>(pr(n,t,"access private method"),e),ge=class{static error(t,...e){console.trace("%c"+t,this.styleError,...e)}static info(t,...e){console.info("%c"+t,this.styleSubdued,...e)}static log(t,...e){console.log("%c"+t,this.styleBold,...e)}};qt(ge,"NAME","Logger"),qt(ge,"styleBold",["color: white","font-weight: bold"].join(";")),qt(ge,"styleError",["color: red","text-align: left"].join(";")),qt(ge,"styleSubdued",["color: gray","font-weight: normal"].join(";")),ge.info(`${ge.NAME} > init`);var h=ge,K={on(n,t){this._eventHandlers||(this._eventHandlers={}),this._eventHandlers[n]||(this._eventHandlers[n]=[]),this._eventHandlers[n].push(t)},off(n,t){let e=this._eventHandlers?.[n];if(e)for(let i=0;i<e.length;i++)e[i]===t&&e.splice(i--,1)},trigger(n,...t){!this._eventHandlers?.[n]||this._eventHandlers[n].forEach(e=>e.apply(this,t))}};function sn(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable})),e.push.apply(e,i)}return e}function on(n){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?arguments[t]:{};t%2?sn(Object(e),!0).forEach(function(i){Pi(n,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):sn(Object(e)).forEac
vendor: 4,676 bytes, line 1
1h(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(e,i))})}return n}function X(){X=function(){return n};var n={},t=Object.prototype,e=t.hasOwnProperty,i=Object.defineProperty||function(P,y,g){P[y]=g.value},r=typeof Symbol=="function"?Symbol:{},s=r.iterator||"@@iterator",o=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function u(P,y,g){return Object.defineProperty(P,y,{value:g,enumerable:!0,configurable:!0,writable:!0}),P[y]}try{u({},"")}catch{u=function(y,g,E){return y[g]=E}}function c(P,y,g,E){var v=y&&y.prototype instanceof f?y:f,_=Object.create(v.prototype),$=new O(E||[]);return i(_,"_invoke",{value:I(P,g,$)}),_}function d(P,y,g){try{return{type:"normal",arg:P.call(y,g)}}catch(E){return{type:"throw",arg:E}}}n.wrap=c;var A={};function f(){}function p(){}function m(){}var x={};u(x,s,function(){return this});var L=Object.getPrototypeOf,T=L&&L(L(V([])));T&&T!==t&&e.call(T,s)&&(x=T);var w=m.prototype=f.prototype=Object.create(x);function b(P){["next","throw","return"].forEach(function(y){u(P,y,function(g){return this._invoke(y,g)})})}function M(P,y){function g(v,_,$,B){var F=d(P[v],P,_);if(F.type!=="throw"){var R=F.arg,z=R.value;return z&&typeof z=="object"&&e.call(z,"__await")?y.resolve(z.__await).then(function(U){g("next",U,$,B)},function(U){g("throw",U,$,B)}):y.resolve(z).then(function(U){R.value=U,$(R)},function(U){return g("throw",U,$,B)})}B(F.arg)}var E;i(this,"_invoke",{value:function(v,_){function $(){return new y(function(B,F){g(v,_,B,F)})}return E=E?E.then($,$):$()}})}function I(P,y,g){var E="suspendedStart";return function(v,_){if(E==="executing")throw new Error("Generator is already running");if(E==="completed"){if(v==="throw")throw _;return W()}for(g.method=v,g.arg=_;;){var $=g.delegate;if($){var B=N($,g);if(B){if(B===A)continue;return B}}if(g.method==="next")g.sent=g._sent=g.arg;else if(g.method==="throw"){if(E==="suspendedStart")throw E="completed",g.arg;g.dispatchException(g.arg)}else g.method==="return"&&g.abrupt("return",g.arg);E="executing";var F=d(P,y,g);if(F.type==="normal"){if(E=g.done?"completed":"suspendedYield",F.arg===A)continue;return{value:F.arg,done:g.done}}F.type==="throw"&&(E="completed",g.method="throw",g.arg=F.arg)}}}function N(P,y){var g=y.method,E=P.iterator[g];if(E===void 0)return y.delegate=null,g==="throw"&&P.iterator.return&&(y.method="return",y.arg=void 0,N(P,y),y.method==="throw")||g!=="return"&&(y.method="throw",y.arg=new TypeError("The iterator does not provide a '"+g+"' method")),A;var v=d(E,P.iterator,y.arg);if(v.type==="throw")return y.method="throw",y.arg=v.arg,y.delegate=null,A;var _=v.arg;return _?_.done?(y[P.resultName]=_.value,y.next=P.nextLoc,y.method!=="return"&&(y.method="next",y.arg=void 0),y.delegate=null,A):_:(y.method="throw",y.arg=new TypeError("iterator result is not an object"),y.delegate=null,A)}function q(P){var y={tryLoc:P[0]};1 in P&&(y.catchLoc=P[1]),2 in P&&(y.finallyLoc=P[2],y.afterLoc=P[3]),this.tryEntries.push(y)}function k(P){var y=P.completion||{};y.type="normal",delete y.arg,P.completion=y}function O(P){this.tryEntries=[{tryLoc:"root"}],P.forEach(q,this),this.reset(!0)}function V(P){if(P){var y=P[s];if(y)return y.call(P);if(typeof P.next=="function")return P;if(!isNaN(P.length)){var g=-1,E=function v(){for(;++g<P.length;)if(e.call(P,g))return v.value=P[g],v.done=!1,v;return v.value=void 0,v.done=!0,v};return E.next=E}}return{next:W}}function W(){return{value:void 0,done:!0}}return p.prototype=m,i(w,"constructor",{value:m,configurable:!0}),i(m,"constructor",{value:p,configurable:!0}),p.displayName=u(m,a,"GeneratorFunction"),n.isGeneratorFunction=function(P){var y=typeof P=="function"&&P.constructor;return!!y&&(y===p||(y.displayName||y.name)==="GeneratorFunction")},n.mark=function(P){return Object.setPrototypeOf?Object.setPrototypeOf(P,m):(P.__proto__=m,u(P,a,"GeneratorFunction")),P.prototype=Object.create(w),P},n.awrap=function(P){return{__await:P}},b(M.prototype),u(M.prototype,o,function(){return this}),n.AsyncIterator=M,n.async=function(P,y,g,E,v){v===void 0&&(v=Promise);var _=new M(c(P,y,g,E),v);return n.isGeneratorFunction(y)?_:_.next().then(function($){return $.done?$.value:_.next()})},b(w),u(w,a,"Generator"),u(w,s,function(){return this}),u(w,"toString",function(){return"[object Generator]"}),n.keys=function(P){var y=Object(P),g=[];for(var E in y)g.push(E);return g.reverse(),function v(){for(;g.length;){var _=g.pop();if(_ in y)return v.value=_,v.done=!1,v}return v.done=!0,v}},n.values=V,O.prototype={constructor:O,reset:function(P){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEac
1h(k),!P)for(var y in this)y.charAt(0)==="t"&&e.call(this,y)&&!isNaN(+y.slice(1))&&(this[y]=void 0)},stop:function(){this.done=!0;var P=this.tryEntries[0].completion;if(P.type==="throw")throw P.arg;return this.rval},dispatchException:function(P){if(this.done)throw P;var y=this;function g(F,R){return _.type="throw",_.arg=P,y.next=F,R&&(y.method="next",y.arg=void 0),!!R}for(var E=this.tryEntries.length-1;E>=0;--E){var v=this.tryEntries[E],_=v.completion;if(v.tryLoc==="root")return g("end");if(v.tryLoc<=this.prev){var $=e.call(v,"catchLoc"),B=e.call(v,"finallyLoc");if($&&B){if(this.prev<v.catchLoc)return g(v.catchLoc,!0);if(this.prev<v.finallyLoc)return g(v.finallyLoc)}else if($){if(this.prev<v.catchLoc)return g(v.catchLoc,!0)}else{if(!B)throw new Error("try statement without catch or finally");if(this.prev<v.finallyLoc)return g(v.finallyLoc)}}}},abrupt:function(P,y){for(var g=this.tryEntries.length-1;g>=0;--g){var E=this.tryEntries[g];if(E.tryLoc<=this.prev&&e.call(E,"finallyLoc")&&this.prev<E.finallyLoc){var v=E;break}}v&&(P==="break"||P==="continue")&&v.tryLoc<=y&&y<=v.finallyLoc&&(v=null);var _=v?v.completion:{};return _.type=P,_.arg=y,v?(this.method="next",this.next=v.finallyLoc,A):this.complete(_)},complete:function(P,y){if(P.type==="throw")throw P.arg;return P.type==="break"||P.type==="continue"?this.next=P.arg:P.type==="return"?(this.rval=this.arg=P.arg,this.method="return",this.next="end"):P.type==="normal"&&y&&(this.next=y),A},finish:function(P){for(var y=this.tryEntries.length-1;y>=0;--y){var g=this.tryEntries[y];if(g.finallyLoc===P)return this.complete(g.completion,g.afterLoc),k(g),A}},catch:function(P){for(var y=this.tryEntries.length-1;y>=0;--y){var g=this.tryEntries[y];if(g.tryLoc===P){var E=g.completion;if(E.type==="throw"){var v=E.arg;k(g)}return v}}throw new Error("illegal catch attempt")},delegateYield:function(P,y,g){return this.delegate={iterator:V(P),resultName:y,nextLoc:g},this.method==="next"&&(this.arg=void 0),A}},n}function an(n,t,e,i,r,s,o){try{var a=n[s](o),u=a.value}catch(c){e(c);return}a.done?t(u):Promise.resolve(u).then(i,r)}function Ve(n){return function(){var t=this,e=arguments;return new Promise(function(i,r){var s=n.apply(t,e);function o(u){an(s,i,r,o,a,"next",u)}function a(u){an(s,i,r,o,a,"throw",u)}o(void 0)})}}function dn(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function")}function ln(n,t){for(var e=0;e<t.length;e++){var i=t[e];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,mn(i.key),i)}}function hn(n,t,e){return t&&ln(n.prototype,t),e&&ln(n,e),Object.defineProperty(n,"prototype",{writable:!1}),n}function Pi(n,t,e){return t=mn(t),t in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}function Ss(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");n.prototype=Object.create(t&&t.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),Object.defineProperty(n,"prototype",{writable:!1}),t&&Vt(n,t)}function Ft(n){return Ft=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Ft(n)}function Vt(n,t){return Vt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,r){return i.__proto__=r,i},Vt(n,t)}function fn(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ci(n,t,e){return fn()?Ci=Reflect.construct.bind():Ci=function(r,s,o){var a=[null];a.push.apply(a,s);var u=Function.bind.apply(r,a),c=new u;return o&&Vt(c,o.prototype),c},Ci.apply(null,arguments)}function ks(n){return Function.toString.call(n).indexOf("[native code]")!==-1}function vr(n){var t=typeof Map=="function"?new Map:void 0;return vr=function(i){if(i===null||!ks(i))return i;if(typeof i!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(i))return t.get(i);t.set(i,r)}function r(){return Ci(i,arguments,Ft(this).constructor)}return r.prototype=Object.create(i.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Vt(r,i)},vr(n)}function Mi(n){if(n===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n}function Ps(n,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Mi(n)}function Cs(n){var t=fn();return function(){var i=Ft(n),r;if(t){var s=Ft(this).constructor;r=Reflect.construct(i,arguments,s)}else r=i.apply(this,arguments);return Ps(this,r)}}function Ms(n,t){if(typeof n!="object"||n===null)return n;var e=n[Symbol.toPrimitive];if(e!==void 0){var i=e.call(n,t||"default");if(typeof i!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(n)}function mn(n){var t=Ms(n,"string");return typeof t=="symbol"?t:String(t)}var pn=typeof global<"u"&&{}.toString.call(global)==="[object global]";function cn(n,t){return n.indexOf(t.toLowerCase())===0?n:"".concat(t.toLowerCase()).concat(n.substr(0,1).toUpperCase()).concat(n.substr(1))}function xs(n){return!!(n&&n.nodeType===1&&"nodeName"in n&&n.ownerDocument&&n.ownerDocument.defaultView)}function Ls(n){return!isNaN(parseFloat(n))&&isFinite(n)&&Math.floor(n)==n}function Re(n){return/^(https?:)?\/\/((((player|www)\.)?vimeo\.com)|((player\.)?[a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))(?=$|\/)/.test(n)}function yn(n){var t=/^https:\/\/player\.((vimeo\.com)|([a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))\/video\/\d+/;return t.test(n)}function Ts(n){for(var t=(n||"").match(/^(?:https?:)?(?:\/\/)?([^/?]+)/),e=(t&&t[1]||"").replace("player.",""),i=[".videoji.hk",".vimeo.work",".videoji.cn"],r=0,s=i;r<s.length;r++){var o=s[r];if(e.endsWith(o))return e}return"vimeo.com"}function vn(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=n.id,e=n.url,i=t||e;if(!i)throw new Error("An id or url must be passed, either in an options object or as a data-vimeo-id or data-vimeo-url attribute.");if(Ls(i))return"https://vimeo.com/".concat(i);if(Re(i))return i.replace("http:","https:");throw t?new TypeError("\u201C".concat(t,"\u201D is not a valid video id.")):new TypeError("\u201C".concat(i,"\u201D is not a vimeo.com url."))}
1var un=function(t,e,i){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"addEventListener",s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"removeEventListener",o=typeof e=="string"?[e]:e;return o.forEach(function(a){t[r](a,i)}),{cancel:function(){return o.forEach(function(u){return t[s](u,i)})}}},Is=typeof Array.prototype.indexOf<"u",Ds=typeof window<"u"&&typeof window.postMessage<"u";if(!pn&&(!Is||!Ds))throw new Error("Sorry, the Vimeo Player API is not available in this browser.");var at=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function _s(n,t){return t={exports:{}},n(t,t.exports),t.exports}(function(n){if(n.WeakMap)return;var t=Object.prototype.hasOwnProperty,e=Object.defineProperty&&(function(){try{return Object.defineProperty({},"x",{value:1}).x===1}catch{}})(),i=function(s,o,a){e?Object.defineProperty(s,o,{configurable:!0,writable:!0,value:a}):s[o]=a};n.WeakMap=(function(){function s(){if(this===void 0)throw new TypeError("Constructor WeakMap requires 'new'");if(i(this,"_id",a("_WeakMap")),arguments.length>0)throw new TypeError("WeakMap iterable is not supported")}i(s.prototype,"delete",function(c){if(o(this,"delete"),!r(c))return!1;var d=c[this._id];return d&&d[0]===c?(delete c[this._id],!0):!1}),i(s.prototype,"get",function(c){if(o(this,"get"),!!r(c)){var d=c[this._id];if(d&&d[0]===c)return d[1]}}),i(s.prototype,"has",function(c){if(o(this,"has"),!r(c))return!1;var d=c[this._id];return!!(d&&d[0]===c)}),i(s.prototype,"set",function(c,d){if(o(this,"set"),!r(c))throw new TypeError("Invalid value used as weak map key");var A=c[this._id];return A&&A[0]===c?(A[1]=d,this):(i(c,this._id,[c,d]),this)});function o(c,d){if(!r(c)||!t.call(c,"_id"))throw new TypeError(d+" method called on incompatible receiver "+typeof c)}function a(c){return c+"_"+u()+"."+u()}function u(){return Math.random().toString().substring(2)}return i(s,"_polyfill",!0),s})();function r(s){return Object(s)===s}})(typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:at);var Z=_s(function(n){(function(e,i,r){i[e]=i[e]||r(),n.exports&&(n.exports=i[e])})("Promise",at,function(){var e,i,r,s=Object.prototype.toString,o=typeof setImmediate<"u"?function(b){return setImmediate(b)}:setTimeout;try{Object.defineProperty({},"x",{}),e=function(b,M,I,N){return Object.defineProperty(b,M,{value:I,writable:!0,configurable:N!==!1})}}catch{e=function(M,I,N){return M[I]=N,M}}r=(function(){var b,M,I;function N(q,k){this.fn=q,this.self=k,this.next=void 0}return{add:function(k,O){I=new N(k,O),M?M.next=I:b=I,M=I,I=void 0},drain:function(){var k=b;for(b=M=i=void 0;k;)k.fn.call(k.self),k=k.next}}})();function a(w,b){r.add(w,b),i||(i=o(r.drain))}function u(w){var b,M=typeof w;return w!=null&&(M=="object"||M=="function")&&(b=w.then),typeof b=="function"?b:!1}function c(){for(var w=0;w<this.chain.length;w++)d(this,this.state===1?this.chain[w].success:this.chain[w].failure,this.chain[w]);this.chain.length=0}function d(w,b,M){var I,N;try{b===!1?M.reject(w.msg):(b===!0?I=w.msg:I=b.call(void 0,w.msg),I===M.promise?M.reject(TypeError("Promise-chain cycle")):(N=u(I))?N.call(I,M.resolve,M.reject):M.resolve(I))}catch(q){M.reject(q)}}function A(w){var b,M=this;if(!M.triggered){M.triggered=!0,M.def&&(M=M.def);try{(b=u(w))?a(function(){var I=new m(M);try{b.call(w,function(){A.apply(I,arguments)},function(){f.apply(I,arguments)})}catch(N){f.call(I,N)}}):(M.msg=w,M.state=1,M.chain.length>0&&a(c,M))}catch(I){f.call(new m(M),I)}}}function f(w){var b=this;b.triggered||(b.triggered=!0,b.def&&(b=b.def),b.msg=w,b.state=2,b.chain.length>0&&a(c,b))}function p(w,b,M,I){for(var N=0;N<b.length;N++)(function(k){w.resolve(b[k]).then(function(V){M(k,V)},I)})(N)}function m(w){this.def=w,this.triggered=!1}function x(w){this.promise=w,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function L(w){if(typeof w!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var b=new x(this);this.then=function(I,N){var q={success:typeof I=="function"?I:!0,failure:typeof N=="function"?N:!1};return q.promise=new this.constructor(function(O,V){if(typeof O!="function"||typeof V!="function")throw TypeError("Not a function");q.resolve=O,q.reject=V}),b.chain.push(q),b.state!==0&&a(c,b),q.promise},this.catch=function(I){return this.then(void 0,I)};try{w.call(void 0,function(I){A.call(b,I)},function(I){f.call(b,I)})}catch(M){f.call(b,M)}}var T=e({},"constructor",L,!1);return L.prototype=T,e(T,"__NPO__",0,!1),e(L,"resolve",function(b){var M=this;return b&&typeof b=="object"&&b.__NPO__===1?b:new M(function(N,q){if(typeof N!="function"||typeof q!="function")throw TypeError("Not a function");N(b)})}
1),e(L,"reject",function(b){return new this(function(I,N){if(typeof I!="function"||typeof N!="function")throw TypeError("Not a function");N(b)})}),e(L,"all",function(b){var M=this;return s.call(b)!="[object Array]"?M.reject(TypeError("Not an array")):b.length===0?M.resolve([]):new M(function(N,q){if(typeof N!="function"||typeof q!="function")throw TypeError("Not a function");var k=b.length,O=Array(k),V=0;p(M,b,function(P,y){O[P]=y,++V===k&&N(O)},q)})}),e(L,"race",function(b){var M=this;return s.call(b)!="[object Array]"?M.reject(TypeError("Not an array")):new M(function(N,q){if(typeof N!="function"||typeof q!="function")throw TypeError("Not a function");p(M,b,function(O,V){N(V)},q)})}),L})}),be=new WeakMap;function Ot(n,t,e){var i=be.get(n.element)||{};t in i||(i[t]=[]),i[t].push(e),be.set(n.element,i)}function xi(n,t){var e=be.get(n.element)||{};return e[t]||[]}function Li(n,t,e){var i=be.get(n.element)||{};if(!i[t])return!0;if(!e)return i[t]=[],be.set(n.element,i),!0;var r=i[t].indexOf(e);return r!==-1&&i[t].splice(r,1),be.set(n.element,i),i[t]&&i[t].length===0}function Ns(n,t){var e=xi(n,t);if(e.length<1)return!1;var i=e.shift();return Li(n,t,i),i}function $s(n,t){var e=be.get(n);be.set(t,e),be.delete(n)}function Ti(n){if(typeof n=="string")try{n=JSON.parse(n)}catch(t){return console.warn(t),{}}return n}function Fe(n,t,e){if(!(!n.element.contentWindow||!n.element.contentWindow.postMessage)){var i={method:t};e!==void 0&&(i.value=e);var r=parseFloat(navigator.userAgent.toLowerCase().replace(/^.*msie (\d+).*$/,"$1"));r>=8&&r<10&&(i=JSON.stringify(i)),n.element.contentWindow.postMessage(i,n.origin)}}function Bs(n,t){t=Ti(t);var e=[],i;if(t.event){if(t.event==="error"){var r=xi(n,t.data.method);r.forEach(function(o){var a=new Error(t.data.message);a.name=t.data.name,o.reject(a),Li(n,t.data.method,o)})}e=xi(n,"event:".concat(t.event)),i=t.data}else if(t.method){var s=Ns(n,t.method);s&&(e.push(s),i=t.value)}e.forEach(function(o){try{if(typeof o=="function"){o.call(n,i);return}o.resolve(i)}catch{}})}var qs=["airplay","audio_tracks","audiotrack","autopause","autoplay","background","byline","cc","chapter_id","chapters","chromecast","color","colors","controls","dnt","end_time","fullscreen","height","id","initial_quality","interactive_params","keyboard","loop","maxheight","max_quality","maxwidth","min_quality","muted","play_button_position","playsinline","portrait","progress_bar","quality","quality_selector","responsive","skipping_forward","speed","start_time","texttrack","title","transcript","transparent","unmute_button","url","vimeo_logo","volume","watch_full_video","width"];function gn(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return qs.reduce(function(e,i){var r=n.getAttribute("data-vimeo-".concat(i));return(r||r==="")&&(e[i]=r===""?1:r),e},t)}function gr(n,t){var e=n.html;if(!t)throw new TypeError("An element must be provided");if(t.getAttribute("data-vimeo-initialized")!==null)return t.querySelector("iframe");var i=document.createElement("div");return i.innerHTML=e,t.appendChild(i.firstChild),t.setAttribute("data-vimeo-initialized","true"),t.querySelector("iframe")}function bn(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=arguments.length>2?arguments[2]:void 0;return new Promise(function(i,r){if(!Re(n))throw new TypeError("\u201C".concat(n,"\u201D is not a vimeo.com url."));var s=Ts(n),o="https://".concat(s,"/api/oembed.json?url=").concat(encodeURIComponent(n));for(var a in t)t.hasOwnProperty(a)&&(o+="&".concat(a,"=").concat(encodeURIComponent(t[a])));var u="XDomainRequest"in window?new XDomainRequest:new XMLHttpRequest;u.open("GET",o,!0),u.onload=function(){if(u.status===404){r(new Error("\u201C".concat(n,"\u201D was not found.")));return}if(u.status===403){r(new Error("\u201C".concat(n,"\u201D is not embeddable.")));return}try{var c=JSON.parse(u.responseText);if(c.domain_status_code===403){gr(c,e),r(new Error("\u201C".concat(n,"\u201D is not embeddable.")));return}i(c)}catch(d){r(d)}},u.onerror=function(){var c=u.status?" (".concat(u.status,")"):"";r(new Error("There was an error fetching the embed code from Vimeo".concat(c,".")))},u.send()})}function Os(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document,t=[].slice.call(n.querySelectorAll("[data-vimeo-id], [data-vimeo-url]")),e=function(r){"console"in window&&console.error&&console.error("There was an error creating an embed: ".concat(r))};t.forEach(function(i){try{if(i.getAttribute("data-vimeo-defer")!==null)return;var r=gn(i),s=vn(r);bn(s,r,i).then(function(o){return gr(o,i)}).catch(e)}catch(o){e(o)}})}function Fs(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoPlayerResizeEmbeds_){window.VimeoPlayerResizeEmbeds_=!0;var t=function(i){if(Re(i.origin)&&!(!i.data||i.data.event!=="spacechange")){for(var r=n.querySelectorAll("iframe"),s=0;s<r.length;s++)if(r[s].contentWindow===i.source){var o=r[s].parentElement;o.style.paddingBottom="".concat(i.data.data[0].bottom,"px");break}}};window.addEventListener("message",t)}}function Vs(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoSeoMetadataAppended){window.VimeoSeoMetadataAppended=!0;var t=function(i){if(Re(i.origin)){var r=Ti(i.data);if(!(!r||r.event!=="ready"))for(var s=n.querySelectorAll("iframe"),o=0;o<s.length;o++){var a=s[o],u=a.contentWindow===i.source;if(yn(a.src)&&u){var c=new br(a);c.callMethod("appendVideoMetadata",window.location.href)}}}};window.addEventListener("message",t)}}function Rs(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:document;if(!window.VimeoCheckedUrlTimeParam){window.VimeoCheckedUrlTimeParam
1=!0;var t=function(r){"console"in window&&console.error&&console.error("There was an error getting video Id: ".concat(r))},e=function(r){if(Re(r.origin)){var s=Ti(r.data);if(!(!s||s.event!=="ready"))for(var o=n.querySelectorAll("iframe"),a=function(){var d=o[u],A=d.contentWindow===r.source;if(yn(d.src)&&A){var f=new br(d);f.getVideoId().then(function(p){var m=new RegExp("[?&]vimeo_t_".concat(p,"=([^&#]*)")).exec(window.location.href);if(m&&m[1]){var x=decodeURI(m[1]);f.setCurrentTime(x)}}).catch(t)}},u=0;u<o.length;u++)a()}};window.addEventListener("message",e)}}function zs(){var n=(function(){for(var i,r=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],s=0,o=r.length,a={};s<o;s++)if(i=r[s],i&&i[1]in document){for(s=0;s<i.length;s++)a[r[0][s]]=i[s];return a}return!1})(),t={fullscreenchange:n.fullscreenchange,fullscreenerror:n.fullscreenerror},e={request:function(r){return new Promise(function(s,o){var a=function c(){e.off("fullscreenchange",c),s()};e.on("fullscreenchange",a),r=r||document.documentElement;var u=r[n.requestFullscreen]();u instanceof Promise&&u.then(a).catch(o)})},exit:function(){return new Promise(function(r,s){if(!e.isFullscreen){r();return}var o=function u(){e.off("fullscreenchange",u),r()};e.on("fullscreenchange",o);var a=document[n.exitFullscreen]();a instanceof Promise&&a.then(o).catch(s)})},on:function(r,s){var o=t[r];o&&document.addEventListener(o,s)},off:function(r,s){var o=t[r];o&&document.removeEventListener(o,s)}};return Object.defineProperties(e,{isFullscreen:{get:function(){return!!document[n.fullscreenElement]}},element:{enumerable:!0,get:function(){return document[n.fullscreenElement]}},isEnabled:{enumerable:!0,get:function(){return!!document[n.fullscreenEnabled]}}}),e}var Hs={role:"viewer",autoPlayMuted:!0,allowedDrift:.3,maxAllowedDrift:1,minCheckInterval:.1,maxRateAdjustment:.2,maxTimeToCatchUp:1},js=(function(n){Ss(e,n);var t=Cs(e);function e(i,r){var s,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},a=arguments.length>3?arguments[3]:void 0;return dn(this,e),s=t.call(this),Pi(Mi(s),"logger",void 0),Pi(Mi(s),"speedAdjustment",0),Pi(Mi(s),"adjustSpeed",(function(){var u=Ve(X().mark(function c(d,A){var f;return X().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:if(s.speedAdjustment!==A){m.next=2;break}return m.abrupt("return");case 2:return m.next=4,d.getPlaybackRate();case 4:return m.t0=m.sent,m.t1=s.speedAdjustment,m.t2=m.t0-m.t1,m.t3=A,f=m.t2+m.t3,s.log("New playbackRate:  ".concat(f)),m.next=12,d.setPlaybackRate(f);case 12:s.speedAdjustment=A;case 13:case"end":return m.stop()}},c)}));return function(c,d){return u.apply(this,arguments)}})()),s.logger=a,s.init(r,i,on(on({},Hs),o)),s}return hn(e,[{key:"disconnect",value:function(){this.dispatchEvent(new Event("disconnect"))}},{key:"init",value:(function(){var i=Ve(X().mark(function s(o,a,u){var c=this,d,A,f;return X().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return m.next=2,this.waitForTOReadyState(o,"open");case 2:if(u.role!=="viewer"){m.next=10;break}return m.next=5,this.updatePlayer(o,a,u);case 5:d=un(o,"change",function(){return c.updatePlayer(o,a,u)}),A=this.maintainPlaybackPosition(o,a,u),this.addEventListener("disconnect",function(){A.cancel(),d.cancel()}),m.next=14;break;case 10:return m.next=12,this.updateTimingObject(o,a);case 12:f=un(a,["seeked","play","pause","ratechange"],function(){return c.updateTimingObject(o,a)},"on","off"),this.addEventListener("disconnect",function(){return f.cancel()});case 14:case"end":return m.stop()}},s,this)}));function r(s,o,a){return i.apply(this,arguments)}return r})()},{key:"updateTimingObject",value:(function(){var i=Ve(X().mark(function s(o,a){return X().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.t0=o,c.next=3,a.getCurrentTime();case 3:return c.t1=c.sent,c.next=6,a.getPaused();case 6:if(!c.sent){c.next=10;break}c.t2=0,c.next=13;break;case 10:return c.next=12,a.getPlaybackRate();case 12:c.t2=c.sent;case 13:c.t3=c.t2,c.t4={position:c.t1,velocity:c.t3},c.t0.update.call(c.t0,c.t4);case 16:case"end":return c.stop()}},s)}));function r(s,o){return i.apply(this,arguments)}return r})()},{key:"updatePlayer",value:(function(){var i=Ve(X().mark(function s(o,a,u){var c,d,A;return X().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:if(c=o.query(),d=c.position,A=c.velocity,typeof d=="number"&&a.setCurrentTime(d),typeof A!="number"){p.next=25;break}if(A!==0){p.next=11;break}return p.next=6,a.getPaused();case 6:if(p.t0=p.sent,p.t0!==!1){p.next=9;break}a.pause();case 9:p.next=25;break;case 11:if(!(A>0)){p.next=25;break}return p.next=14,a.getPaused();case 14:if(p.t1=p.sent,p.t1!==!0){p.next=19;break}return p.next=18,a.play().catch((function(){var m=Ve(X().mark(function x(L){return X().wrap(function(w){for(;;)switch(w.prev=w.next){case 0:if(!(L.name==="NotAllowedError"&&u.autoPlayMuted)){w.next=5;break}return w.next=3,a.setMuted(!0);case 3:return w.next=5,a.play().catch(function(b){return console.error("Couldn't play the video from TimingSrcConnector. Error:",b)});case 5:case"end":return w.stop()}},x)}));return function(x){return m.apply(this,arguments)}})());case 18:this.updatePlayer(o,a,u);case 19:return p.next=21,a.getPlaybackRate();
1case 21:if(p.t2=p.sent,p.t3=A,p.t2===p.t3){p.next=25;break}a.setPlaybackRate(A);case 25:case"end":return p.stop()}},s,this)}));function r(s,o,a){return i.apply(this,arguments)}return r})()},{key:"maintainPlaybackPosition",value:function(r,s,o){var a=this,u=o.allowedDrift,c=o.maxAllowedDrift,d=o.minCheckInterval,A=o.maxRateAdjustment,f=o.maxTimeToCatchUp,p=Math.min(f,Math.max(d,c))*1e3,m=(function(){var L=Ve(X().mark(function T(){var w,b,M,I,N;return X().wrap(function(k){for(;;)switch(k.prev=k.next){case 0:if(k.t0=r.query().velocity===0,k.t0){k.next=6;break}return k.next=4,s.getPaused();case 4:k.t1=k.sent,k.t0=k.t1===!0;case 6:if(!k.t0){k.next=8;break}return k.abrupt("return");case 8:return k.t2=r.query().position,k.next=11,s.getCurrentTime();case 11:if(k.t3=k.sent,w=k.t2-k.t3,b=Math.abs(w),a.log("Drift: ".concat(w)),!(b>c)){k.next=22;break}return k.next=18,a.adjustSpeed(s,0);case 18:s.setCurrentTime(r.query().position),a.log("Resync by currentTime"),k.next=29;break;case 22:if(!(b>u)){k.next=29;break}return M=b/f,I=A,N=M<I?(I-M)/2:I,k.next=28,a.adjustSpeed(s,N*Math.sign(w));case 28:a.log("Resync by playbackRate");case 29:case"end":return k.stop()}},T)}));return function(){return L.apply(this,arguments)}})(),x=setInterval(function(){return m()},p);return{cancel:function(){return clearInterval(x)}}}},{key:"log",value:function(r){var s;(s=this.logger)===null||s===void 0||s.call(this,"TimingSrcConnector: ".concat(r))}},{key:"waitForTOReadyState",value:function(r,s){return new Promise(function(o){var a=function u(){r.readyState===s?o():r.addEventListener("readystatechange",u,{once:!0})};a()})}}]),e})(vr(EventTarget)),ot=new WeakMap,yr=new WeakMap,Q={},br=(function(){function n(t){var e=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(dn(this,n),window.jQuery&&t instanceof jQuery&&(t.length>1&&window.console&&console.warn&&console.warn("A jQuery object with multiple elements was passed, using the first element."),t=t[0]),typeof document<"u"&&typeof t=="string"&&(t=document.getElementById(t)),!xs(t))throw new TypeError("You must pass either a valid element or a valid id.");if(t.nodeName!=="IFRAME"){var r=t.querySelector("iframe");r&&(t=r)}if(t.nodeName==="IFRAME"&&!Re(t.getAttribute("src")||""))throw new Error("The player element passed isn\u2019t a Vimeo embed.");if(ot.has(t))return ot.get(t);this._window=t.ownerDocument.defaultView,this.element=t,this.origin="*";var s=new Z(function(a,u){if(e._onMessage=function(A){if(!(!Re(A.origin)||e.element.contentWindow!==A.source)){e.origin==="*"&&(e.origin=A.origin);var f=Ti(A.data),p=f&&f.event==="error",m=p&&f.data&&f.data.method==="ready";if(m){var x=new Error(f.data.message);x.name=f.data.name,u(x);return}var L=f&&f.event==="ready",T=f&&f.method==="ping";if(L||T){e.element.setAttribute("data-ready","true"),a();return}Bs(e,f)}},e._window.addEventListener("message",e._onMessage),e.element.nodeName!=="IFRAME"){var c=gn(t,i),d=vn(c);bn(d,c,t).then(function(A){var f=gr(A,t);return e.element=f,e._originalElement=t,$s(t,f),ot.set(e.element,e),A}).catch(u)}});if(yr.set(this,s),ot.set(this.element,this),this.element.nodeName==="IFRAME"&&Fe(this,"ping"),Q.isEnabled){var o=function(){return Q.exit()};this.fullscreenchangeHandler=function(){Q.isFullscreen?Ot(e,"event:exitFullscreen",o):Li(e,"event:exitFullscreen",o),e.ready().then(function(){Fe(e,"fullscreenchange",Q.isFullscreen)})},Q.on("fullscreenchange",this.fullscreenchangeHandler)}return this}return hn(n,[{key:"callMethod",value:function(e){for(var i=this,r=arguments.length,s=new Array(r>1?r-1:0),o=1;o<r;o++)s[o-1]=arguments[o];if(e==null)throw new TypeError("You must pass a method name.");return new Z(function(a,u){return i.ready().then(function(){Ot(i,e,{resolve:a,reject:u}),Fe(i,e,s)}).catch(u)})}},{key:"get",value:function(e){var i=this;return new Z(function(r,s){return e=cn(e,"get"),i.ready().then(function(){Ot(i,e,{resolve:r,reject:s}),Fe(i,e)}).catch(s)})}},{key:"set",value:function(e,i){var r=this;return new Z(function(s,o){if(e=cn(e,"set"),i==null)throw new TypeError("There must be a value to set.");return r.ready().then(function(){Ot(r,e,{resolve:s,reject:o}),Fe(r,e,i)}).catch(o)})}},{key:"on",value:function(e,i){if(!e)throw new TypeError("You must pass an event name.");if(!i)throw new TypeError("You must pass a callback function.");
1if(typeof i!="function")throw new TypeError("The callback must be a function.");var r=xi(this,"event:".concat(e));r.length===0&&this.callMethod("addEventListener",e).catch(function(){}),Ot(this,"event:".concat(e),i)}},{key:"off",value:function(e,i){if(!e)throw new TypeError("You must pass an event name.");if(i&&typeof i!="function")throw new TypeError("The callback must be a function.");var r=Li(this,"event:".concat(e),i);r&&this.callMethod("removeEventListener",e).catch(function(s){})}},{key:"loadVideo",value:function(e){return this.callMethod("loadVideo",e)}},{key:"ready",value:function(){var e=yr.get(this)||new Z(function(i,r){r(new Error("Unknown player. Probably unloaded."))});return Z.resolve(e)}},{key:"addCuePoint",value:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.callMethod("addCuePoint",{time:e,data:i})}},{key:"removeCuePoint",value:function(e){return this.callMethod("removeCuePoint",e)}},{key:"enableTextTrack",value:function(e,i){if(!e)throw new TypeError("You must pass a language.");return this.callMethod("enableTextTrack",{language:e,kind:i})}},{key:"disableTextTrack",value:function(){return this.callMethod("disableTextTrack")}},{key:"pause",value:function(){return this.callMethod("pause")}},{key:"play",value:function(){return this.callMethod("play")}},{key:"requestFullscreen",value:function(){return Q.isEnabled?Q.request(this.element):this.callMethod("requestFullscreen")}},{key:"exitFullscreen",value:function(){return Q.isEnabled?Q.exit():this.callMethod("exitFullscreen")}},{key:"getFullscreen",value:function(){return Q.isEnabled?Z.resolve(Q.isFullscreen):this.get("fullscreen")}},{key:"requestPictureInPicture",value:function(){return this.callMethod("requestPictureInPicture")}},{key:"exitPictureInPicture",value:function(){return this.callMethod("exitPictureInPicture")}},{key:"getPictureInPicture",value:function(){return this.get("pictureInPicture")}},{key:"remotePlaybackPrompt",value:function(){return this.callMethod("remotePlaybackPrompt")}},{key:"unload",value:function(){return this.callMethod("unload")}},{key:"destroy",value:function(){var e=this;return new Z(function(i){if(yr.delete(e),ot.delete(e.element),e._originalElement&&(ot.delete(e._originalElement),e._originalElement.removeAttribute("data-vimeo-initialized")),e.element&&e.element.nodeName==="IFRAME"&&e.element.parentNode&&(e.element.parentNode.parentNode&&e._originalElement&&e._originalElement!==e.element.parentNode?e.element.parentNode.parentNode.removeChild(e.element.parentNode):e.element.parentNode.removeChild(e.element)),e.element&&e.element.nodeName==="DIV"&&e.element.parentNode){e.element.removeAttribute("data-vimeo-initialized");var r=e.element.querySelector("iframe");r&&r.parentNode&&(r.parentNode.parentNode&&e._originalElement&&e._originalElement!==r.parentNode?r.parentNode.parentNode.removeChild(r.parentNode):r.parentNode.removeChild(r))}e._window.removeEventListener("message",e._onMessage),Q.isEnabled&&Q.off("fullscreenchange",e.fullscreenchangeHandler),i()})}},{key:"getAutopause",value:function(){return this.get("autopause")}},{key:"setAutopause",value:function(e){return this.set("autopause",e)}},{key:"getBuffered",value:function(){return this.get("buffered")}},{key:"getCameraProps",value:function(){return this.get("cameraProps")}},{key:"setCameraProps",value:function(e){return this.set("cameraProps",e)}},{key:"getChapters",value:function(){return this.get("chapters")}},{key:"getCurrentChapter",value:function(){return this.get("currentChapter")}},{key:"getColor",value:function(){return this.get("color")}},{key:"getColors",value:function(){return Z.all([this.get("colorOne"),this.get("colorTwo"),this.get("colorThree"),this.get("colorFour")])}},{key:"setColor",value:function(e){return this.set("color",e)}},{key:"setColors",value:function(e){if(!Array.isArray(e))return new Z(function(s,o){return o(new TypeError("Argument must be an array."))});var i=new Z(function(s){return s(null)}),r=[e[0]?this.set("colorOne",e[0]):i,e[1]?this.set("colorTwo",e[1]):i,e[2]?this.set("colorThree",e[2]):i,e[3]?this.set("colorFour",e[3]):i];return Z.all(r)}},{key:"getCuePoints",value:function(){return this.get("cuePoints")}},{key:"getCurrentTime",value:function(){return this.get("currentTime")}},{key:"setCurrentTime",value:function(e){return this.set("currentTime",e)}
1},{key:"getDuration",value:function(){return this.get("duration")}},{key:"getEnded",value:function(){return this.get("ended")}},{key:"getLoop",value:function(){return this.get("loop")}},{key:"setLoop",value:function(e){return this.set("loop",e)}},{key:"setMuted",value:function(e){return this.set("muted",e)}},{key:"getMuted",value:function(){return this.get("muted")}},{key:"getPaused",value:function(){return this.get("paused")}},{key:"getPlaybackRate",value:function(){return this.get("playbackRate")}},{key:"setPlaybackRate",value:function(e){return this.set("playbackRate",e)}},{key:"getPlayed",value:function(){return this.get("played")}},{key:"getQualities",value:function(){return this.get("qualities")}},{key:"getQuality",value:function(){return this.get("quality")}},{key:"setQuality",value:function(e){return this.set("quality",e)}},{key:"getRemotePlaybackAvailability",value:function(){return this.get("remotePlaybackAvailability")}},{key:"getRemotePlaybackState",value:function(){return this.get("remotePlaybackState")}},{key:"getSeekable",value:function(){return this.get("seekable")}},{key:"getSeeking",value:function(){return this.get("seeking")}},{key:"getTextTracks",value:function(){return this.get("textTracks")}},{key:"getVideoEmbedCode",value:function(){return this.get("videoEmbedCode")}},{key:"getVideoId",value:function(){return this.get("videoId")}},{key:"getVideoTitle",value:function(){return this.get("videoTitle")}},{key:"getVideoWidth",value:function(){return this.get("videoWidth")}},{key:"getVideoHeight",value:function(){return this.get("videoHeight")}},{key:"getVideoUrl",value:function(){return this.get("videoUrl")}},{key:"getVolume",value:function(){return this.get("volume")}},{key:"setVolume",value:function(e){return this.set("volume",e)}},{key:"setTimingSrc",value:(function(){var t=Ve(X().mark(function i(r,s){var o=this,a;return X().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:if(r){c.next=2;break}throw new TypeError("A Timing Object must be provided.");case 2:return c.next=4,this.ready();case 4:return a=new js(this,r,s),Fe(this,"notifyTimingObjectConnect"),a.addEventListener("disconnect",function(){return Fe(o,"notifyTimingObjectDisconnect")}),c.abrupt("return",a);case 8:case"end":return c.stop()}},i,this)}));function e(i,r){return t.apply(this,arguments)}return e})()}]),n})();pn||(Q=zs(),Os(),Fs(),Vs(),Rs());var xe=br,Ii,Us=new Uint8Array(16);function wr(){if(!Ii&&(Ii=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ii))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ii(Us)}var Y=[];for(let n=0;n<256;++n)Y.push((n+256).toString(16).slice(1));function wn(n,t=0){return Y[n[t+0]]+Y[n[t+1]]+Y[n[t+2]]+Y[n[t+3]]+"-"+Y[n[t+4]]+Y[n[t+5]]+"-"+Y[n[t+6]]+Y[n[t+7]]+"-"+Y[n[t+8]]+Y[n[t+9]]+"-"+Y[n[t+10]]+Y[n[t+11]]+Y[n[t+12]]+Y[n[t+13]]+Y[n[t+14]]+Y[n[t+15]]}var Ws=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Er={randomUUID:Ws};function Ks(n,t,e){if(Er.randomUUID&&!t&&!n)return Er.randomUUID();n=n||{};let i=n.random||(n.rng||wr)();if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,t){e=e||0;for(let r=0;r<16;++r)t[e+r]=i[r];return t}return wn(i)}var me=Ks,lt=class{constructor(t){this.NAME="ThemeBannerHero",this.dom=t,this.videoDom=t.querySelector("[data-theme-banner-hero-video]");let e=me();this.videoDom?.setAttribute("id",e),this.autoplay=this.videoDom?.getAttribute("data-theme-banner-hero-video-autoplay"),this.buttonArrowDom=this.dom.querySelector("[data-theme-banner-hero-button-arrow]"),this.placeholderImageDoms=t.querySelectorAll("[data-theme-banner-hero-placeholder-image]"),this.placeholderImageDomHiddenClass="theme-banner-hero__image--hidden",this.vimeoPosterDom=t.querySelector("[data-theme-banner-hero-vimeo-poster]"),this.playButtonDom=t.querySelector("theme-play-button"),this.vimeoIdDesktop=this.videoDom?.getAttribute("data-theme-banner-hero-video"),this.vimeoIdMobile=this.videoDom?.getAttribute("data-theme-banner-hero-video-mobile"),this.videoPlayer=null,this.thresholdDom=this.dom.querySelector("[data-theme-banner-hero-threshold]"),this.thresholdDomId=`theme-banner-hero-video-${e}`,this.thresholdDom.setAttribute("id",this.thresholdDomId)}init(){h.info(`${this.NAME} > init`);let t=this;this.loadVimeoPoster(),this.videoDom&&new IntersectionObserver(i=>
1{i.forEach(r=>{r.isIntersecting&&!this.videoPlayer&&t.initializeVideoPlayer()})}).observe(this.videoDom),this.buttonArrowDom?.addEventListener("click",e=>{e.preventDefault(),t.thresholdDom.scrollIntoView(!0)})}async loadVimeoPoster(){if(!this.vimeoPosterDom)return;let t=this.getVimeoIdForScreenSize(),e=this.vimeoPosterDom.querySelector("img");try{let i=await fetch(`https://vimeo.com/api/oembed.json?url=https://vimeo.com/${encodeURIComponent(t)}&width=1920`);if(!i.ok)throw new Error(`Vimeo oEmbed request failed: ${i.status}`);let r=await i.json();r.thumbnail_url&&e&&(e.src=r.thumbnail_url,e.alt=r.title||"")}catch(i){h.error(`${this.NAME} > loadVimeoPoster`,i)}}getVimeoIdForScreenSize(){return h.info(`${this.NAME} > hidePlayButton`),window.innerWidth>1024?this.vimeoIdDesktop:this.vimeoIdMobile?this.vimeoIdMobile:this.vimeoIdDesktop}hidePlayButton(){h.info(`${this.NAME} > hidePlayButton`),this.playButtonDom&&(this.playButtonDom.dataset.playing="true")}initializeVideoPlayer(){h.info(`${this.NAME} > initializeVideoPlayer`);let t=this,e=this.getVimeoIdForScreenSize();this.videoPlayer=new xe(this.videoDom.getAttribute("id"),{id:e,controls:!1,title:!1,responsive:!0}),this.videoPlayer.on("ended",function(){t.showPlayButton(),t.videoPlayer.setCurrentTime(0)}),this.videoPlayer.on("play",function(){t.hidePlayButton(),t.hidePlaceholderImages()}),this.videoPlayer.on("pause",function(){t.showPlayButton()}),this.playButtonDom&&this.playButtonDom.addEventListener("click",r=>{r.preventDefault();let s=this.videoPlayer.getPaused().then(o=>{o?t.playVideo():t.pauseVideo()})}),this.autoplay==="true"?(h.info(`${this.NAME} > initializeVideoPlayer > autoplay`),this.playVideo()):this.showPlayButton(),window.onresize=this.loadVideoForScreenSize.bind(this)}hidePlaceholderImages(){h.info(`${this.NAME} > hidePlaceholderImages`),this.placeholderImageDoms.forEach(t=>{t.classList.add(this.placeholderImageDomHiddenClass)})}async loadVideoForScreenSize(){h.info(`${this.NAME} > loadVideoForScreenSize`);let t=await this.videoPlayer?.getVideoId(),e=this.getVimeoIdForScreenSize();parseInt(t)!==parseInt(e)&&(h.info(`${this.NAME} > loadVideoForScreenSize > switching video`),this.loadVideo(e))}async loadVideo(t){h.info(`${this.NAME} > loadVideo`),await this.videoPlayer?.loadVideo(t),this.playVideo()}muteVideo(){h.info(`${this.NAME} > muteVideo`),this.videoPlayer?.setVolume(0)}playVideo(){h.info(`${this.NAME} > playVideo`),this.hidePlayButton(),this.muteVideo(),this.videoPlayer?.play()}pauseVideo(){h.info(`${this.NAME} > pauseVideo`),this.videoPlayer?.pause()}showPlaceholderImages(){h.info(`${this.NAME} > showPlaceholderImages`),this.placeholderImageDoms.forEach(t=>{t.classList.remove(this.placeholderImageDomHiddenClass)})}showPlayButton(){h.info(`${this.NAME} > showPlayButton`),this.playButtonDom&&(this.playButtonDom.dataset.playing="false")}};Object.assign(lt.prototype,K);var ct=function(){return ct=Object.assign||function(n){for(var t,e=1,i=arguments.length;e<i;e++)for(var r in t=arguments[e])Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n},ct.apply(this,arguments)};function Pn(n,t,e){if(e||arguments.length===2)for(var i,r=0,s=t.length;r<s;r++)!i&&r in t||(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return n.concat(i||Array.prototype.slice.call(t))}function En(n){return Array.prototype.slice.call(n)}function An(n,t){var e=Math.floor(n);return e===t||e+1===t?n:t}function Sn(){return Date.now()}function Ar(n,t,e){if(t="data-keen-slider-"+t,e===null)return n.removeAttribute(t);n.setAttribute(t,e||"")}function Di(n,t){return t=t||document,typeof n=="function"&&(n=n(t)),Array.isArray(n)?n:typeof n=="string"?En(t.querySelectorAll(n)):n instanceof HTMLElement?[n]:n instanceof NodeList?En(n):[]}function Rt(n){n.raw&&(n=n.raw),n.cancelable&&!n.defaultPrevented&&n.preventDefault()}function zt(n){n.raw&&(n=n.raw),n.stopPropagation&&n.stopPropagation()}function Cn(){var n=[];return{add:function(t,e,i,r){t.addListener?t.addListener(i):t.addEventListener(e,i,r),n.push([t,e,i,r])},input:function(t,e,i,r){this.add(t,e,(function(s){return function(o){o.nativeEvent&&(o=o.nativeEvent);var a=o.changedTouches||[],u=o.targetTouches||[],c=o.detail&&o.detail.x?o.detail:null;return s({id:c?c.identifier?c.identifier:"i":u[0]?u[0]?u[0].identifier:"e":"d",idChanged:c?c.identifier?c.identifier:"i":a[0]?a[0]?a[0].identifier:"e":"d",raw:o,x:c&&c.x?c.x:u[0]?u[0].screenX:c?c.x:o.pageX,y:c&&c.y?c.y:u[0]?u[0].screenY:c?c.y:o.pageY})}})(i),r)}
1,purge:function(){n.forEach(function(t){t[0].removeListener?t[0].removeListener(t[2]):t[0].removeEventListener(t[1],t[2],t[3])}),n=[]}}}function Sr(n,t,e){return Math.min(Math.max(n,t),e)}function ae(n){return(n>0?1:0)-(n<0?1:0)||+n}function kn(n){var t=n.getBoundingClientRect();return{height:An(t.height,n.offsetHeight),width:An(t.width,n.offsetWidth)}}function J(n,t,e,i){var r=n&&n[t];return r==null?e:i&&typeof r=="function"?r():r}function ee(n){return Math.round(1e6*n)/1e6}function Gs(n){var t,e,i,r,s,o;function a(f){o||(o=f),u(!0);var p=f-o;p>i&&(p=i);var m=r[e];if(m[3]<p)return e++,a(f);var x=m[2],L=m[4],T=m[0],w=m[1]*(0,m[5])(L===0?1:(p-x)/L);if(w&&n.track.to(T+w),p<i)return d();o=null,u(!1),c(null),n.emit("animationEnded")}function u(f){t.active=f}function c(f){t.targetIdx=f}function d(){var f;f=a,s=window.requestAnimationFrame(f)}function A(){var f;f=s,window.cancelAnimationFrame(f),u(!1),c(null),o&&n.emit("animationStopped"),o=null}return t={active:!1,start:function(f){if(A(),n.track.details){var p=0,m=n.track.details.position;e=0,i=0,r=f.map(function(x){var L,T=Number(m),w=(L=x.earlyExit)!==null&&L!==void 0?L:x.duration,b=x.easing,M=x.distance*b(w/x.duration)||0;m+=M;var I=i;return i+=w,p+=M,[T,x.distance,I,i,x.duration,b]}),c(n.track.distToIdx(p)),d(),n.emit("animationStarted")}},stop:A,targetIdx:null}}function Ys(n){var t,e,i,r,s,o,a,u,c,d,A,f,p,m,x=1/0,L=[],T=null,w=0;function b(g){P(w+g)}function M(g){var E=I(w+g).abs;return k(E)?E:null}function I(g){var E=Math.floor(Math.abs(ee(g/e))),v=ee((g%e+e)%e);v===e&&(v=0);var _=ae(g),$=a.indexOf(Pn([],a,!0).reduce(function(F,R){return Math.abs(R-v)<Math.abs(F-v)?R:F})),B=$;return _<0&&E++,$===o&&(B=0,E+=_>0?1:-1),{abs:B+E*o*_,origin:$,rel:B}}function N(g,E,v){var _;if(E||!V())return q(g,v);if(!k(g))return null;var $=I(v??w),B=$.abs,F=g-$.rel,R=B+F;_=q(R);var z=q(R-o*ae(F));return(z!==null&&Math.abs(z)<Math.abs(_)||_===null)&&(_=z),ee(_)}function q(g,E){if(E==null&&(E=ee(w)),!k(g)||g===null)return null;g=Math.round(g);var v=I(E),_=v.abs,$=v.rel,B=v.origin,F=W(g),R=(E%e+e)%e,z=a[B],U=Math.floor((g-(_-$))/o)*e;return ee(z-R-z+a[F]+U+(B===o?e:0))}function k(g){return O(g)===g}function O(g){return Sr(g,c,d)}function V(){return r.loop}function W(g){return(g%o+o)%o}function P(g){var E;E=g-w,L.push({distance:E,timestamp:Sn()}),L.length>6&&(L=L.slice(-6)),w=ee(g);var v=y().abs;if(v!==T){var _=T!==null;T=v,_&&n.emit("slideChanged")}}function y(g){var E=g?null:(function(){if(o){var v=V(),_=v?(w%e+e)%e:w,$=(v?w%e:w)-s[0][2],B=0-($<0&&v?e-Math.abs($):$),F=0,R=I(w),z=R.abs,U=R.rel,Si=s[U][2],ki=s.map(function(fe,bs){var G=B+F;(G<0-fe[0]||G>1)&&(G+=(Math.abs(G)>e-1&&v?e:0)*ae(-G));var tn=bs-U,rn=ae(tn),Bt=tn+z;v&&(rn===-1&&G>Si&&(Bt+=o),rn===1&&G<Si&&(Bt-=o),A!==null&&Bt<A&&(G+=e),f!==null&&Bt>f&&(G-=e));var nn=G+fe[0]+fe[1],ws=Math.max(G>=0&&nn<=1?1:nn<0||G>1?0:G<0?Math.min(1,(fe[0]+G)/fe[0]):(1-G)/fe[0],0);return F+=fe[0]+fe[1],{abs:Bt,distance:r.rtl?-1*G+1-fe[0]:G,portion:ws,size:fe[0]}});return z=O(z),U=W(z),{abs:O(z),length:i,max:m,maxIdx:d,min:p,minIdx:c,position:w,progress:v?_/e:w/i,rel:U,slides:ki,slidesLength:e}}})();return t.details=E,n.emit("detailsChanged"),E}return t={absToRel:W,add:b,details:null,distToIdx:M,idxToDist:N,init:function(g){if((function(){if(r=n.options,s=(r.trackConfig||[]).map(function($){return[J($,"size",1),J($,"spacing",0),J($,"origin",0)]}),o=s.length){e=ee(s.reduce(function($,B){return $+B[0]+B[1]},0));var v,_=o-1;i=ee(e+s[0][2]-s[_][0]-s[_][2]-s[_][1]),a=s.reduce(function($,B){if(!$)return[0];var F=s[$.length-1],R=$[$.length-1]+(F[0]+F[2])+F[1];return R-=B[2],$[$.length-1]>R&&(R=$[$.length-1]),R=ee(R),$.push(R),(!v||v<R)&&(u=$.length-1),v=R,$},null),i===0&&(u=0),a.push(ee(e))}})(),!o)return y(!0);var E;(function(){var v=n.options.range,_=n.options.loop;A=c=_?J(_,"min",-1/0):0,f=d=_?J(_,"max",x):u;var $=J(v,"min",null),B=J(v,"max",null);$!==null&&(c=$),B!==null&&(d=B),p=c===-1/0?c:n.track.idxToDist(c||0,!0,0),m=d===x?d:N(d,!0,0),B===null&&(f=d),J(v,"align",!1)&&d!==x&&s[W(d)][2]===0&&(m-=1-s[W(d)][0],d=M(m-w)),p=ee(p),m=ee(m)})(),E=g,Number(E)===E?b(q(O(g))):y()},to:P,velocity:function(){var g=Sn(),E=L.reduce(function(v,_){var $=_.distance,B=_.timestamp;return g-B>200||(ae($)!==ae(v.distance)&&v.distance&&(v={distance:0,lastTimestamp:0,time:0}),v.time&&(v.distance+=$),v.lastTimestamp&&(v.time+=B-v.lastTimestamp),v.lastTimestamp=B),v},{distance:0,lastTimestamp:0,time:0});return E.distance/E.time||0}}}function Xs(n){var t,e,i,r,s,o,a,u;function c(T){return 2*T}function d(T){return Sr(T,a,u)}function A(T){return 1-Math.pow(1-T,3)}function f(){return i?n.track.velocity():0}function p(){L();var T=n.options.mode==="free-snap",w=n.track,b=f();r=ae(b);var M=n.track.details,I=[];if(b||!T){var N=m(b),q=N.dist,k=N.dur;if(k=c(k),q*=r,T){var O=w.idxToDist(w.distToIdx(q),!0);O&&(q=O)}I.push({distance:q,duration:k,easing:A});var V=M.position,W=V+q;if(W<s||W>o){var P=W<s?s-V:o-V,y=0,g=b;if(ae(P)===r){var E=Math.min(Math.abs(P)/Math.abs(q),1),v=(function(B){return 1-Math.pow(1-B,1/3)})(E)*k;I[0].earlyExit=v,g=b*(1-E)}else I[0].earlyExit=0,y+=P;var _=m(g,100),$=_.dist*r;n.options.rubberband&&(I.push({distance:$,duration:c(_.dur),easing:A}),I.push({distance:-$+y,duration:500,easing:A}))}n.animator.start(I)}else n.moveToIdx(d(M.abs),!0,{duration:500,easing:function(B){return 1+--B*B*B*B*B}})}
1function m(T,w){w===void 0&&(w=1e3);var b=147e-9+(T=Math.abs(T))/w;return{dist:Math.pow(T,2)/b,dur:T/b}}function x(){var T=n.track.details;T&&(s=T.min,o=T.max,a=T.minIdx,u=T.maxIdx)}function L(){n.animator.stop()}n.on("updated",x),n.on("optionsChanged",x),n.on("created",x),n.on("dragStarted",function(){i=!1,L(),t=e=n.track.details.abs}),n.on("dragChecked",function(){i=!0}),n.on("dragEnded",function(){var T=n.options.mode;T==="snap"&&(function(){var w=n.track,b=n.track.details,M=b.position,I=ae(f());(M>o||M<s)&&(I=0);var N=t+I;b.slides[w.absToRel(N)].portion===0&&(N-=I),t!==e&&(N=e),ae(w.idxToDist(N,!0))!==I&&(N+=I),N=d(N);var q=w.idxToDist(N,!0);n.animator.start([{distance:q,duration:500,easing:function(k){return 1+--k*k*k*k*k}}])})(),T!=="free"&&T!=="free-snap"||p()}),n.on("dragged",function(){e=n.track.details.abs})}function Js(n){var t,e,i,r,s,o,a,u,c,d,A,f,p,m,x,L,T,w,b=Cn();function M(y){if(o&&u===y.id){var g=k(y);if(c){if(!q(y))return N(y);d=g,c=!1,n.emit("dragChecked")}if(L)return d=g;Rt(y);var E=(function(_){if(T===-1/0&&w===1/0)return _;var $=n.track.details,B=$.length,F=$.position,R=Sr(_,T-F,w-F);if(B===0)return 0;if(!n.options.rubberband)return R;if(F<=w&&F>=T||F<T&&e>0||F>w&&e<0)return _;var z=(F<T?F-T:F-w)/B,U=r*B,Si=Math.abs(z*U),ki=Math.max(0,1-Si/s*2);return ki*ki*_})(a(d-g)/r*i);e=ae(E);var v=n.track.details.position;(v>T&&v<w||v===T&&e>0||v===w&&e<0)&&zt(y),A+=E,!f&&Math.abs(A*r)>5&&(f=!0),n.track.add(E),d=g,n.emit("dragged")}}function I(y){!o&&n.track.details&&n.track.details.length&&(A=0,o=!0,f=!1,c=!0,u=y.id,q(y),d=k(y),n.emit("dragStarted"))}function N(y){o&&u===y.idChanged&&(o=!1,n.emit("dragEnded"))}function q(y){var g=O(),E=g?y.y:y.x,v=g?y.x:y.y,_=p!==void 0&&m!==void 0&&Math.abs(m-v)<=Math.abs(p-E);return p=E,m=v,_}function k(y){return O()?y.y:y.x}function O(){return n.options.vertical}function V(){r=n.size,s=O()?window.innerHeight:window.innerWidth;var y=n.track.details;y&&(T=y.min,w=y.max)}function W(y){f&&(zt(y),Rt(y))}function P(){if(b.purge(),n.options.drag&&!n.options.disabled){var y;y=n.options.dragSpeed||1,a=typeof y=="function"?y:function(E){return E*y},i=n.options.rtl?-1:1,V(),t=n.container,(function(){var E="data-keen-slider-clickable";Di("[".concat(E,"]:not([").concat(E,"=false])"),t).map(function(v){b.add(v,"dragstart",zt),b.add(v,"mousedown",zt),b.add(v,"touchstart",zt)})})(),b.add(t,"dragstart",function(E){Rt(E)}),b.add(t,"click",W,{capture:!0}),b.input(t,"ksDragStart",I),b.input(t,"ksDrag",M),b.input(t,"ksDragEnd",N),b.input(t,"mousedown",I),b.input(t,"mousemove",M),b.input(t,"mouseleave",N),b.input(t,"mouseup",N),b.input(t,"touchstart",I,{passive:!0}),b.input(t,"touchmove",M,{passive:!1}),b.input(t,"touchend",N),b.input(t,"touchcancel",N),b.add(window,"wheel",function(E){o&&Rt(E)});var g="data-keen-slider-scrollable";Di("[".concat(g,"]:not([").concat(g,"=false])"),n.container).map(function(E){return(function(v){var _;b.input(v,"touchstart",function($){_=k($),L=!0,x=!0},{passive:!0}),b.input(v,"touchmove",function($){var B=O(),F=B?v.scrollHeight-v.clientHeight:v.scrollWidth-v.clientWidth,R=_-k($),z=B?v.scrollTop:v.scrollLeft,U=B&&v.style.overflowY==="scroll"||!B&&v.style.overflowX==="scroll";if(_=k($),(R<0&&z>0||R>0&&z<F)&&x&&U)return L=!0;x=!1,Rt($),L=!1}),b.input(v,"touchend",function(){L=!1})})(E)})}}n.on("updated",V),n.on("optionsChanged",P),n.on("created",P),n.on("destroyed",b.purge)}function Qs(n){var t,e,i=null;function r(p,m,x){n.animator.active?o(p,m,x):requestAnimationFrame(function(){return o(p,m,x)})}function s(){r(!1,!1,e)}function o(p,m,x){var L=0,T=n.size,w=n.track.details;if(w&&t){var b=w.slides;t.forEach(function(M,I){if(p)!i&&m&&u(M,null,x),c(M,null,x);else{if(!b[I])return;var N=b[I].size*T;!i&&m&&u(M,N,x),c(M,b[I].distance*T-L,x),L+=N}})}}function a(p){return n.options.renderMode==="performance"?Math.round(p):p}function u(p,m,x){var L=x?"height":"width";m!==null&&(m=a(m)+"px"),p.style["min-"+L]=m,p.style["max-"+L]=m}function c(p,m,x){if(m!==null){m=a(m);var L=x?m:0;m="translate3d(".concat(x?0:m,"px, ").concat(L,"px, 0)")}p.style.transform=m,p.style["-webkit-transform"]=m}
1function d(){t&&(o(!0,!0,e),t=null),n.on("detailsChanged",s,!0)}function A(){r(!1,!0,e)}function f(){d(),e=n.options.vertical,n.options.disabled||n.options.renderMode==="custom"||(i=J(n.options.slides,"perView",null)==="auto",n.on("detailsChanged",s),(t=n.slides).length&&A())}n.on("created",f),n.on("optionsChanged",f),n.on("beforeOptionsChanged",function(){d()}),n.on("updated",A),n.on("destroyed",d)}function Zs(n,t){return function(e){var i,r,s,o,a,u,c=Cn();function d(k){var O;Ar(e.container,"reverse",(O=e.container,window.getComputedStyle(O,null).getPropertyValue("direction")!=="rtl"||k?null:"")),Ar(e.container,"v",e.options.vertical&&!k?"":null),Ar(e.container,"disabled",e.options.disabled&&!k?"":null)}function A(){f()&&T()}function f(){var k=null;if(o.forEach(function(V){V.matches&&(k=V.__media)}),k===i)return!1;i||e.emit("beforeOptionsChanged"),i=k;var O=k?s.breakpoints[k]:s;return e.options=ct(ct({},s),O),d(),N(),q(),b(),!0}function p(k){var O=kn(k);return(e.options.vertical?O.height:O.width)/e.size||1}function m(){return e.options.trackConfig.length}function x(k){for(var O in i=!1,s=ct(ct({},t),k),c.purge(),r=e.size,o=[],s.breakpoints||[]){var V=window.matchMedia(O);V.__media=O,o.push(V),c.add(V,"change",A)}c.add(window,"orientationchange",I),c.add(window,"resize",M),f()}function L(k){e.animator.stop();var O=e.track.details;e.track.init(k??(O?O.abs:0))}function T(k){L(k),e.emit("optionsChanged")}function w(k,O){if(k)return x(k),void T(O);N(),q();var V=m();b(),m()!==V?T(O):L(O),e.emit("updated")}function b(){var k=e.options.slides;if(typeof k=="function")return e.options.trackConfig=k(e.size,e.slides);for(var O=e.slides,V=O.length,W=typeof k=="number"?k:J(k,"number",V,!0),P=[],y=J(k,"perView",1,!0),g=J(k,"spacing",0,!0)/e.size||0,E=y==="auto"?g:g/y,v=J(k,"origin","auto"),_=0,$=0;$<W;$++){var B=y==="auto"?p(O[$]):1/y-g+E,F=v==="center"?.5-B/2:v==="auto"?0:v;P.push({origin:F,size:B,spacing:g}),_+=B}if(_+=g*(W-1),v==="auto"&&!e.options.loop&&y!==1){var R=0;P.map(function(z){var U=_-R;return R+=z.size+g,U>=1||(z.origin=1-U-(_>1?0:1-_)),z})}e.options.trackConfig=P}function M(){N();var k=e.size;e.options.disabled||k===r||(r=k,w())}function I(){M(),setTimeout(M,500),setTimeout(M,2e3)}function N(){var k=kn(e.container);e.size=(e.options.vertical?k.height:k.width)||1}function q(){e.slides=Di(e.options.selector,e.container)}e.container=(u=Di(n,a||document)).length?u[0]:null,e.destroy=function(){c.purge(),e.emit("destroyed"),d(!0)},e.prev=function(){e.moveToIdx(e.track.details.abs-1,!0)},e.next=function(){e.moveToIdx(e.track.details.abs+1,!0)},e.update=w,x(e.options)}}var ut=function(n,t,e){try{return(function(i,r){var s,o={};return s={emit:function(a){o[a]&&o[a].forEach(function(c){c(s)});var u=s.options&&s.options[a];u&&u(s)},moveToIdx:function(a,u,c){var d=s.track.idxToDist(a,u);if(d){var A=s.options.defaultAnimation;s.animator.start([{distance:d,duration:J(c||A,"duration",500),easing:J(c||A,"easing",function(f){return 1+--f*f*f*f*f})}])}},on:function(a,u,c){c===void 0&&(c=!1),o[a]||(o[a]=[]);var d=o[a].indexOf(u);d>-1?c&&delete o[a][d]:c||o[a].push(u)},options:i},(function(){if(s.track=Ys(s),s.animator=Gs(s),r)for(var a=0,u=r;a<u.length;a++)(0,u[a])(s);s.track.init(s.options.initial||0),s.emit("created")})(),s})(t,Pn([Zs(n,{drag:!0,mode:"snap",renderMode:"precision",rubberband:!0,selector:".keen-slider__slide"}),Qs,Js,Xs],e||[],!0))}catch(i){console.error(i)}},dt=class{constructor(t){this.NAME="ThemeCarouselBanner",this.dom=t,this.dotAttribute="data-theme-carousel-dot",this.arrowAttribute="data-theme-carousel-arrow",this.dotDomActiveClass="theme-carousel-banner__dot--active",this.dotDoms=this.dom.querySelectorAll(`[${this.dotAttribute}]`),this.arrowDoms=this.dom.querySelectorAll(`[${this.arrowAttribute}]`),this.slidesContainerDom=this.dom.querySelector("[data-theme-carousel-banner-slides]"),this.autoplayEnabled=this.dom.dataset.themeCarouselAutoplay=="true",this.autoplayInterval=parseInt(this.dom.dataset.themeCarouselAutoplayInterval,10)*1e3||5e3,this.slider}init(){h.info(`${this.NAME} > init`);let t=this;new IntersectionObserver(i=>
1{i.forEach(r=>{r.isIntersecting&&!this.slider&&t.initializeCarousel()})}).observe(this.dom)}initializeCarousel(){if(h.info(`${this.NAME} > initializeCarousel`),this.slider||!this.slidesContainerDom)return;let t=this;this.slider=new ut(this.slidesContainerDom,{selector:".theme-carousel-banner__slide",loop:!0},[e=>{let i,r=!1,s=()=>{clearTimeout(i)},o=()=>{s(),!(!t.autoplayEnabled||r)&&(i=setTimeout(()=>{e.next()},t.autoplayInterval))};e.on("created",()=>{h.info(`${this.NAME} > init > created`),t.dotDoms.forEach(a=>{a.addEventListener("click",u=>{u.preventDefault();let c=a.getAttribute(t.dotAttribute);e.moveToIdx(parseInt(c))})}),t.arrowDoms.forEach(a=>{a.addEventListener("click",u=>{u.preventDefault(),a.getAttribute(t.arrowAttribute)=="next"?e.next():e.prev()})}),t.autoplayEnabled&&(t.dom.addEventListener("mouseover",()=>{r=!0,s()}),t.dom.addEventListener("mouseout",()=>{r=!1,o()})),t.updateClasses(e),o()}),e.on("slideChanged",()=>{h.info(`${this.NAME} > init > slideChanged`),t.updateClasses(e)}),e.on("dragStarted",s),e.on("animationEnded",o),e.on("updated",o)}])}updateClasses(t){h.info(`${this.NAME} > updateClasses`);let e=this,i=t.track.details.rel;e.dotDoms.forEach(r=>{let s=parseInt(r.getAttribute(this.dotAttribute))==i;s?r.classList.add(e.dotDomActiveClass):r.classList.remove(e.dotDomActiveClass),r.setAttribute("aria-selected",s?"true":"false")})}};Object.assign(dt.prototype,K);var Mn="max-width: 1023px",Ht=class{constructor(t){this.NAME="ProfessionalImageCarousel",this.dom=t,this.slidesContainerDom=t.querySelector("[data-professional-image-carousel-slides]"),this.dotsContainerDom=t.querySelector("[data-professional-image-carousel-dots]"),this.previousButtonDom=t.querySelector("[data-professional-image-carousel-previous]"),this.nextButtonDom=t.querySelector("[data-professional-image-carousel-next]"),this.slider=null,this.intersectionObserver=null}init(){if(h.info(`${this.NAME} > init`),!this.slidesContainerDom||!this.slidesContainerDom.querySelectorAll(".professional-image-carousel__slide").length)return;this.previousButtonDom?.addEventListener("click",()=>this.slider?.prev()),this.nextButtonDom?.addEventListener("click",()=>this.slider?.next());let e=this;this.intersectionObserver=new IntersectionObserver(i=>{i.forEach(r=>{r.isIntersecting&&e.initializeCarousel()})}),this.intersectionObserver.observe(this.dom)}initializeCarousel(){if(h.info(`${this.NAME} > initializeCarousel`),this.slider)return;let t=Math.max(1,parseInt(this.dom.getAttribute("data-columns-desktop"),10)||3),e=Math.max(1,parseInt(this.dom.getAttribute("data-columns-mobile"),10)||1),i=this;this.slider=new ut(this.slidesContainerDom,{selector:".professional-image-carousel__slide",loop:!1,slides:{perView:t,spacing:16},breakpoints:{[`(${Mn})`]:{slides:{perView:e===1?1.15:e,spacing:8}}
1},created(r){h.info("ProfessionalImageCarousel > created"),i.intersectionObserver&&(i.intersectionObserver.disconnect(),i.intersectionObserver=null),i.slider=r,i.buildDots(),i.updateDots(),i.updateArrows()},slideChanged(r){i.slider=r,i.updateDots(),i.updateArrows()},optionsChanged(r){i.slider=r,i.buildDots(),i.updateDots(),i.updateArrows()}})}buildDots(){if(!this.dotsContainerDom||!this.slider)return;let t=this.slider.track.details;if(!t)return;let e=(t.maxIdx!=null?t.maxIdx:t.slides.length-1)+1;if(this.dotsContainerDom.innerHTML="",!(e<=1))for(let i=0;i<e;i++){let r=document.createElement("button");r.type="button",r.className="professional-image-carousel__dot",r.setAttribute("aria-label",`Go to slide ${i+1}`),r.addEventListener("click",()=>{this.slider.moveToIdx(i)}),this.dotsContainerDom.appendChild(r)}}updateDots(){if(!this.dotsContainerDom||!this.slider)return;let t=this.slider.track.details;if(!t)return;let e=t.rel;this.dotsContainerDom.querySelectorAll(".professional-image-carousel__dot").forEach((r,s)=>{r.classList.toggle("professional-image-carousel__dot--active",s===e)})}updateArrows(){if(!this.previousButtonDom||!this.nextButtonDom||!this.slider)return;let t=this.slider.track.details;if(!t)return;let e=t.maxIdx>t.minIdx;this.previousButtonDom.hidden=!e,this.nextButtonDom.hidden=!e,this.previousButtonDom.disabled=t.rel<=t.minIdx,this.nextButtonDom.disabled=t.rel>=t.maxIdx}},eo="[data-professional-video-animation-video]",to="[data-professional-video-animation-video-mobile]",io="[data-professional-video-animation-poster]",kr="[data-professional-video-animation-dot]",ro=".professional-video-animation__timeline-track",xn="(min-width: 1024px)",no=1e3,so=150,oo=48,jt=class{constructor(t){this.NAME="ProfessionalVideoAnimation",this.dom=t,this._videoDesktop=t.querySelector(eo),this._videoMobile=t.querySelector(to),this.videoEl=null,this.posterEl=null,this.dotEls=t.querySelectorAll(kr),this.sequenceEls=t.querySelectorAll(".professional-video-animation__sequence[data-sequence-index]"),this._trackEl=t.querySelector(ro),this.scrubInit=!1,this.observer=null,this._scrubRafId=null,this._lastScrubSeekApply=0,this._mql=null,this._primedVideos=new WeakSet,this._needsUserPrime=!1,this._hasInteracted=!1,this.onMetadataBound=this.onLoadedMetadata.bind(this),this.onDotClickBound=this.onDotClick.bind(this),this._onMqlChangeBound=this._onMqlChange.bind(this)}_resolveVideo(){this._videoMobile&&!window.matchMedia(xn).matches?this.videoEl=this._videoMobile:this.videoEl=this._videoDesktop,this.posterEl=this.videoEl?.parentElement?.querySelector(io)||null}_onMqlChange(){let t=this.videoEl,e=t?t.currentTime:0;this._resolveVideo(),this.videoEl&&this.videoEl!==t&&(this.scrubInit=!1,this.cancelScrubAnimation(),this.videoEl.addEventListener("loadedmetadata",this.onMetadataBound,{once:!0}),Number.isFinite(this.videoEl.duration)&&this.videoEl.duration>0&&(this.videoEl.currentTime=e),this.tryInitAfterMetadata().catch(()=>{}))}init(){h.info(`${this.NAME} > init`),this._resolveVideo(),this._videoDesktop&&this._videoMobile&&(this._mql=window.matchMedia(xn),this._mql.addEventListener("change",this._onMqlChangeBound)),!(!this.videoEl||!this.dotEls.length)&&(this.observer=new IntersectionObserver(t=>{t.forEach(e=>{e.isIntersecting&&(this.attach(),this.observer&&(this.observer.disconnect(),this.observer=null))})},{rootMargin:"80px"}),this.observer.observe(this.dom))}attach(){h.info(`${this.NAME} > attach`),this.videoEl.addEventListener("loadedmetadata",this.onMetadataBound,{once:!0}),this.tryInitAfterMetadata().catch(()=>{}),this.dotEls.forEach(t=>{t.addEventListener("click",this.onDotClickBound)})}onLoadedMetadata(){this.tryInitAfterMetadata().catch(()=>{})}async tryInitAfterMetadata(){let t=this.videoEl.duration;!Number.isFinite(t)||t<=0||this.scrubInit||(this.scrubInit=!0,this.dotEls.forEach(e=>{e.removeAttribute("disabled")}),this._needsUserPrime=!this._primedVideos.has(this.videoEl),this._hasInteracted?this.posterEl&&(this.posterEl.hidden=!0):this.showPoster(),this.updateChrome(0))}async _primeVideoForScrubbing(t){if(!t)return!1;if(this._primedVideos.has(t))return!0;try{let e=t.play();return e&&typeof e.then=="function"&&await e,await new Promise(i=>requestAnimationFrame(i)),t.pause(),this._primedVideos.add(t),this._needsUserPrime=!1,!0}catch(e){return h.info(`${this.NAME} > prime play() rejected, deferring to user gesture`,e),this._needsUserPrime=!0,!1}}async onDotClick(t){let e=t.currentTarget,i=this.videoEl.duration;if(!Number.isFinite(i)||i<=0)return;let r=parseInt(e.getAttribute("data-sequence-index"),10);if(!Number.isNaN(r)){if(this._needsUserPrime&&!await this._primeVideoForScrubbing(this.videoEl)){this.updateChrome(r);return}this._hasInteracted=!0,this.revealVideoWhenFrameReady(),this.activateIndex(r,i,{instant:!1})}}showPoster(){this.posterEl&&(this.posterEl.hidden=!1)}revealVideoWhenFrameReady(){if(!this.posterEl||!this.videoEl)return;let t=this.posterEl,e=()=>{t.hidden=!0};typeof this.videoEl.requestVideoFrameCallback=="function"?this.videoEl.requestVideoFrameCallback(e):this.videoEl.addEventListener("seeked",e,{once:!0})}cancelScrubAnimation(){this._scrubRafId!=null&&(cancelAnimationFrame(this._scrubRafId),this._scrubRafId=null),this._lastScrubSeekApply=0}targetTimeForIndex(t,e){let r=this.dom.querySelector(`${kr}[data-sequence-index="${t}"]`);if(!r)return 0;let s=parseFloat(r.getAttribute("data-seek-percent")),o=Number.isFinite(s)?Math.min(100,Math.max(0,s)):0,a=o/100*e;return o>=100&&(a=Math.max(0,e-.04)),a}_seekPercentForIndex(t){let e=this.dom.querySelector(`${kr}[data-sequence-index="${t}"]`);if(!e)return 0;let i=parseFloat(e.getAttribute("data-seek-percent"));return Number.isFinite(i)?Math.min(100,Math.max(0,i)):0}_visualFractionForIndex(t){let e=this.dotEls.length;return e<=1?0:t/(e-1)}_currentVisualFraction(t,e){if(e<=0)return 0;let i=t/e*100,r=0;for(let f=0;f<this.dotEls.length;f++)this._seekPercentForIndex(f)<=i&&(r=f);let s=Math.min(r+1,this.dotEls.length-1);if(r===s)return this._visualFractionForIndex(r);let o=this._seekPercentForIndex(r),u=this._seekPercentForIndex(s)-o,c=u>0?(i-o)/u:0,d=this._visualFractionForIndex(r),A=this._visualFractionForIndex(s);return d+(A-d)*c}_updateProgress(t){this._trackEl&&this._trackEl.style.setProperty("--pva-progress",t)}
1updateChrome(t){this.dotEls.forEach(e=>{let i=parseInt(e.getAttribute("data-sequence-index"),10),r=i===t,s=i===0||i<=t;e.classList.toggle("professional-video-animation__dot--active",r),e.classList.toggle("professional-video-animation__dot--passed",s),e.setAttribute("aria-selected",r?"true":"false")}),this.sequenceEls.forEach(e=>{let r=parseInt(e.getAttribute("data-sequence-index"),10)===t;e.classList.toggle("professional-video-animation__sequence--active",r),e.setAttribute("aria-hidden",r?"false":"true")}),this._updateProgress(this._visualFractionForIndex(t))}prefersReducedMotion(){return typeof window>"u"||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}activateIndex(t,e,i={}){let r=i.instant===!0,s=this.targetTimeForIndex(t,e),o=this._visualFractionForIndex(t);if(this.updateChrome(t),this.cancelScrubAnimation(),r||this.prefersReducedMotion()){this.videoEl.currentTime=s,this._updateProgress(o);return}let a=this.videoEl.currentTime;if(Math.abs(a-s)<.02){this.videoEl.currentTime=s,this._updateProgress(o);return}let u=this._currentVisualFraction(a,e),c=Math.abs(s-a),d=Math.max(so,c*no),A=performance.now();this._lastScrubSeekApply=0;let f=p=>{let m=p-A,x=Math.min(1,m/d),L=a+(s-a)*x,T=u+(o-u)*x,w=x>=1;(w||this._lastScrubSeekApply===0||p-this._lastScrubSeekApply>=oo)&&(this.videoEl.currentTime=w?s:L,this._lastScrubSeekApply=p),this._updateProgress(w?o:T),w?(this._scrubRafId=null,this.videoEl.currentTime=s):this._scrubRafId=requestAnimationFrame(f)};this._scrubRafId=requestAnimationFrame(f)}},Ut=class{constructor(t){this.NAME="ProfessionalSimpleDspSetup",this.dom=t,this.openBtns=t.querySelectorAll("[data-professional-simple-dsp-setup-open]"),this.modal=t.querySelector("[data-professional-simple-dsp-setup-modal]"),this.backdrop=t.querySelector("[data-professional-simple-dsp-setup-backdrop]"),this.closeBtn=t.querySelector("[data-professional-simple-dsp-setup-close]"),this.iframe=t.querySelector("[data-professional-simple-dsp-setup-iframe]"),this.onEscBound=this.onEsc.bind(this),this.lastTrigger=null,this.scrollY=0}init(){h.info(`${this.NAME} > init`),!(!this.modal||!this.iframe)&&(this.openBtns.forEach(t=>{t.addEventListener("click",e=>{e.preventDefault(),this.openFrom(t)})}),this.closeBtn?.addEventListener("click",t=>{t.preventDefault(),this.close(!0)}),this.backdrop?.addEventListener("click",()=>{this.close(!0)}))}openFrom(t){let e=t.getAttribute("data-iframe-url");if(!e)return;let i=t.getAttribute("data-iframe-title")||"Blaze dashboard";this.lastTrigger=t,this.iframe.setAttribute("title",i),this.iframe.src=e,this.scrollY=window.scrollY,document.body.style.top=`-${this.scrollY}px`,document.body.style.paddingRight="15px",document.body.style.position="fixed",document.body.style.width="100%",document.body.style.zIndex="0",this.modal.removeAttribute("hidden"),this.modal.setAttribute("aria-hidden","false"),document.addEventListener("keydown",this.onEscBound),this.closeBtn?.focus()}close(t){this.modal.setAttribute("hidden",""),this.modal.setAttribute("aria-hidden","true"),this.iframe.src="",document.body.style.paddingRight="",document.body.style.position="",document.body.style.width="",document.body.style.top="",document.body.style.zIndex="";let e=this.scrollY;document.removeEventListener("keydown",this.onEscBound),t&&typeof window.scrollTo=="function"?window.scrollTo({top:e,behavior:"instant"}):window.scrollTo(0,e),this.lastTrigger&&(this.lastTrigger.focus(),this.lastTrigger=null)}onEsc(t){t.key==="Escape"&&this.close(!0)}},Wt=class{constructor(t){this.NAME="ProfessionalMediaTextSoftwareModal",this.dom=t,this.configs=t.querySelectorAll("[data-professional-media-text-software-modal-config]"),this.modal=t.querySelector("[data-professional-media-text-software-modal]"),this.backdrop=t.querySelector("[data-professional-media-text-software-modal-backdrop]"),this.closeBtn=t.querySelector("[data-professional-media-text-software-modal-close]"),this.iframe=t.querySelector("[data-professional-media-text-software-modal-iframe]"),this.onEscBound=this.onEsc.bind(this),this.onHashChangeBound=this.onHashChange.bind(this),this.scrollY=0,this.activeModalId=null}init(){h.info(`${this.NAME} > init`),!(!this.configs.length||!this.modal||!this.iframe)&&(this.closeBtn?.addEventListener("click",t=>{t.preventDefault(),this.close(!0)}),this.backdrop?.addEventListener("click",()=>{this.close(!0)}),window.addEventListener("hashchange",this.onHashChangeBound),this.onHashChange())}onHashChange(){let t=window.location.hash.replace(/^#/,"");try{t=decodeURIComponent(t)}catch{return}let e=Array.from(this.configs).find(r=>r.getAttribute("data-modal-id")===t);if(!e){this.activeModalId&&this.close(!0,!1);return}let i=e.getAttribute("data-iframe-url");!i||this.open(t,i,e.getAttribute("data-iframe-title")||"Software")}open(t,e,i){if(this.activeModalId===t&&!this.modal.hasAttribute("hidden"))return;let r=!this.modal.hasAttribute("hidden");this.activeModalId=t,this.iframe.setAttribute("title",i),this.iframe.src=e,r||(this.scrollY=window.scrollY,document.body.style.top=`-${this.scrollY}px`,document.body.style.paddingRight="15px",document.body.style.position="fixed",document.body.style.width="100%",document.body.style.zIndex="0"),this.modal.removeAttribute("hidden"),this.modal.setAttribute("aria-hidden","false"),document.addEventListener("keydown",this.onEscBound),this.closeBtn?.focu
1s()}close(t,e=!0){if(this.modal.hasAttribute("hidden"))return;let i=this.activeModalId;this.activeModalId=null,this.modal.setAttribute("hidden",""),this.modal.setAttribute("aria-hidden","true"),this.iframe.src="",document.body.style.paddingRight="",document.body.style.position="",document.body.style.width="",document.body.style.top="",document.body.style.zIndex="";let r=this.scrollY;document.removeEventListener("keydown",this.onEscBound),t&&typeof window.scrollTo=="function"?window.scrollTo({top:r,behavior:"instant"}):window.scrollTo(0,r),e&&i&&window.location.hash===`#${i}`&&history.replaceState(null,document.title,`${window.location.pathname}${window.location.search}`)}onEsc(t){t.key==="Escape"&&this.close(!0)}},Kt=class{constructor(t){this.NAME="ProfessionalSystemCalculator",this.dom=t,this.iframe=t.querySelector("[data-professional-system-calculator-iframe]"),this.expectedOrigin=t.getAttribute("data-iframe-origin")||"",this.onMessageBound=this.onMessage.bind(this)}init(){h.info(`${this.NAME} > init`),!(!this.iframe||!this.expectedOrigin)&&(window.removeEventListener("message",this.onMessageBound),window.addEventListener("message",this.onMessageBound))}onMessage(t){if(t.origin!==this.expectedOrigin||!this.iframe||t.source!==this.iframe.contentWindow)return;let e=t.data;!e||e.type!=="ssc-resize"||typeof e.height!="number"||!isFinite(e.height)||(this.iframe.style.height=`${e.height}px`)}},ht=class{constructor(t,e){let i=this;this.NAME="ThemeMobileNav",this.dom=t,this.loader=e||null,this.siteLogo=this.dom.querySelector(".theme-header-main__logo"),this.mainHamburgerDom=this.dom.querySelector("[data-theme-header-hamburger]"),this.mainCloseBtnDom=this.dom.querySelector("[data-theme-header-close-btn]"),this.mobileNavDom=this.dom.querySelector("[data-theme-header-mobile-nav]"),this.mobileNavBackBtn=this.dom.querySelector("[data-mobile-nav-back-btn]"),this.currentMenu=this.dom.querySelector("[data-mobile-nav-current-menu]"),this.menusWrapper=this.dom.querySelector("[data-mobile-nav-menus-wrapper]"),this.menus=this.dom.querySelector("[data-mobile-nav-menus]"),this.menusWidth=this.menusWrapper.getBoundingClientRect().width,this.navPos=0,this.breadCrumbs=[]}init(){h.info(`${this.NAME} > init`),this.initMainHamburger(),this.initMainCloseBtn(),window.addEventListener("resize",this.onResize.bind(this)),this.initBackBtn(),this.initMenuItems()}onResize(){this.menusWidth=this.menusWrapper.getBoundingClientRect().width}initMainHamburger(){h.info(`${this.NAME} > initMainHamburger`);let t=this;this.mainHamburgerDom?.addEventListener("click",e=>{e.preventDefault(),t.showMobileNav()})}initMainCloseBtn(){h.info(`${this.NAME} > initMainCloseBtn`);let t=this;this.mainCloseBtnDom?.addEventListener("click",e=>{e.preventDefault(),t.hideMobileNav()})}showMobileNav(){h.info(`${this.NAME} > showMobileNav`),this.mainHamburgerDom.classList.add("menu-open"),this.mainCloseBtnDom.classList.add("menu-open"),this.mobileNavDom.classList.add("open"),document.body.style.top=`-${window.scrollY}px`,document.body.style.position="fixed",document.body.style.width="100%",document.body.style.zIndex="0",document.body.addEventListener("keydown",this.handleEscKey.bind(this))}hideMobileNav(){h.info(`${this.NAME} > hideMobileNav`),this.mainHamburgerDom.classList.remove("menu-open"),this.mainCloseBtnDom.classList.remove("menu-open"),this.mobileNavDom.classList.remove("open"),this.menus.classList.remove("level-"+this.navPos.toString()),this.menus.querySelectorAll(".mobile-nav__submenu.visible").forEach(i=>{i.classList.remove("visible")}),this.navPos=0,this.breadCrumbs=[],this.mobileNavBackBtn.classList.remove("visible"),this.currentMenu.innerHTML="",this.siteLogo.classList.remove("hide-mobile");let e=document.body.style.top;document.body.style.paddingRight="",document.body.style.position="",document.body.style.width="",document.body.style.top="",document.body.style.zIndex="",window.scrollTo(0,parseInt(e||"0")*-1),document.body.removeEventListener("keydown",this.handleEscKey.bind(this))}handleEscKey(t){h.info(`${this.NAME} > handleEscKey`),t.key==="Escape"&&this.hideMobileNav()}initMenuItems(){h.info(`${this.NAME} > initMenuItems`);let t=this,e=["[data-menu-item]","[data-submenu-1-item]","[data-submenu-2-item]","[data-submenu-3-item]","[data-submenu-4-item]"].join(",");this.menus.addEventListener("click",i=>{if(!(i.target instanceof Element))return;let r=i.target.closest(e);
1if(!r||!t.menus.contains(r))return;let s=i.target.closest("a[href]");if(s&&r.contains(s))return;let o=0;r.hasAttribute("data-submenu-1-item")?o=1:r.hasAttribute("data-submenu-2-item")?o=2:r.hasAttribute("data-submenu-3-item")?o=3:r.hasAttribute("data-submenu-4-item")&&(o=4);let a=r.querySelector(`[data-submenu-${o+1}]`);if(!a)return;t.loader&&(a.hasAttribute("data-menu-lazy-panel")?t.loader.loadPanel(a):a.hasAttribute("data-menu-lazy-products")&&t.loader.loadProducts(a),t.loader.warmNextLevelProducts(a)),a.classList.add("visible");let u=r.querySelector(".menu-item__title, .submenu-item__title"),c=u?u.textContent.trim():"";t.updateNavPosition(c,o+1)})}initBackBtn(){h.info(`${this.NAME} > initBackBtn`),this.mobileNavBackBtn.addEventListener("click",()=>{this.menus.classList.remove("level-"+this.navPos.toString());let t=this.menus.querySelectorAll(`[data-submenu-${this.navPos.toString()}]`);setTimeout(()=>{t.forEach(e=>{e.classList.remove("visible")})},500),this.navPos--,this.breadCrumbs.pop(),this.currentMenu.innerHTML=this.breadCrumbs[this.navPos-1],this.menus.classList.add("level-"+this.navPos.toString()),this.navPos==0&&(this.mobileNavBackBtn.classList.remove("visible"),this.currentMenu.innerHTML="",this.siteLogo.classList.remove("hide-mobile")),this.menusWrapper.scrollTo({top:0,behavior:"smooth"})})}updateNavPosition(t,e){h.info(`${this.NAME} > updateNavPosition ${e}`),this.menus.classList.remove("level-"+this.navPos.toString()),this.navPos=e,this.menus.classList.add("level-"+this.navPos.toString()),this.breadCrumbs.push(t),this.currentMenu.innerHTML=this.breadCrumbs[this.navPos-1],this.navPos>0?(this.mobileNavBackBtn.classList.add("visible"),this.siteLogo.classList.add("hide-mobile")):(this.mobileNavBackBtn.classList.remove("visible"),this.siteLogo.classList.remove("hide-mobile")),this.menusWrapper.scrollTo({top:0,behavior:"smooth"})}};Object.assign(ht.prototype,K);var ao="api-menu-panel",Ln={d:"api-menu-products",m:"api-menu-products-mobile"},Gt="menu-hover-active",lo="menu-has-hover-panel",Tn=":scope > .collection-lists, :scope > .product-list, :scope > .product, :scope > .submenu__resources",co=220,uo=160,Yt=class{constructor(t){this.NAME="MegaMenuLoader",this.dom=t,this.panelBaseUrl=t.getAttribute("data-menu-panel-url")||"/collections/all",this.cache=new Map,this.desktopMedia=window.matchMedia("(min-width: 1024px)")}init(){h.info(`${this.NAME} > init`),this.initDesktopHoverFetch(),this.initMobilePrefetch(),this.prefetchAllPanels()}fetchSection(t){if(!this.cache.has(t)){let e=fetch(t,{headers:{Accept:"text/html"}}).then(i=>{if(!i.ok)throw new Error(`${this.NAME} > fetchSection ${i.status} for ${t}`);return i.text()}).then(i=>this.extractSectionInner(i)).catch(i=>{throw this.cache.delete(t),i});this.cache.set(t,e)}return this.cache.get(t)}extractSectionInner(t){let e=document.createElement("template");e.innerHTML=t;let i=e.content.querySelector(".shopify-section");return i?i.innerHTML:t}panelUrl(t){let e=this.panelBaseUrl.indexOf("?")>-1?"&":"?";return`${this.panelBaseUrl}${e}section_id=${ao}`}selectPanelHtml(t,e){let i=e.getAttribute("data-menu-mode")||"d",r=e.getAttribute("data-menu-slug")||"-",s=(e.getAttribute("data-menu-handles")||"").split(",").filter(Boolean),o=document.createElement("template");o.innerHTML=t;let a=new Map,u=new Map;o.content.querySelectorAll("[data-menu-panel-item]").forEach(d=>{d.getAttribute("data-menu-mode")===i&&a.set(d.getAttribute("data-menu-handle"),d)}),o.content.querySelectorAll("[data-menu-panel-tail]").forEach(d=>{d.getAttribute("data-menu-mode")===i&&u.set(d.getAttribute("data-menu-handle"),d)});let c=document.createElement("div");return s.forEach(d=>{let A=a.get(d);if(A)for(;A.firstChild;)c.appendChild(A.firstChild)}),s.forEach(d=>{let A=u.get(d);if(A)for(;A.firstChild;)c.appendChild(A.firstChild)}),i==="m"&&c.querySelectorAll("[data-menu-category]").forEach(d=>{d.getAttribute("data-menu-category")!==r&&d.remove()}),c.innerHTML}loadPanel(t){return!t||t.hasAttribute("data-menu-loaded")?Promise.resolve():this.fetchSection(this.panelUrl(t)).then(e=>{t.hasAttribute("data-menu-loaded")||(t.innerHTML=this.selectPanelHtml(e,t),t.setAttribute("data-menu-loaded",""),this.afterInject(t))}).catch(e=>{h.info(`${this.NAME} > loadPanel failed: ${e.message}`)})}loadProducts(t){if(!t||t.hasAttribute("data-menu-loaded"))return Promise.resolve();let e=this.productsUrl(t);return e?this.fetchSection(e).then(i=>{if(!t.hasAttribute("data-menu-loaded")){if(i.replace(/\s/g,"")===""){this.renderProductsFallback(t);return}t.innerHTML=i,t.setAttribute("data-menu-loaded",""),this.initDesktopHoverIntent(t)}}).catch(i=>{h.info(`${this.NAME} > loadProducts failed: ${i.message}`),this.renderProductsFallback(t)}):Promise.resolve()}renderProductsFallback(t){if(t.hasAttribute("data-menu-loaded"))return;let e=t.getAttribute("data-collection-url"),i=t.getAttribute("data-menu-products-mode")||"d";if(t.innerHTML="",t.setAttribute("data-menu-loaded",""),!e)return;let r=document.createElement("a");if(r.setAttribute("href",e),r.textContent="View All",i==="m"){let s=document.createElement("div");s.className="submenu-item",s.setAttribute("data-submenu-4-item",""),r.className="submenu-item__title",s.appendChild(r),t.appendChild(s)}else{let s=document.createElement("p");s.className="product-list__title",s.textContent="Models";let o=document.createElement("ul");o.className="product-list__products";let a=document.createElement("li");r.className="submenu__link",a.appendChild(r),o.appendChild(a),t.appendChild(s),t.appendChild(o)}}afterInject(t){this.initDesktopHoverIntent(t),t.querySelectorAll(".js-resources-submenus").forEach(e
1=>{if(e.hasAttribute("data-menu-resources-bound"))return;e.setAttribute("data-menu-resources-bound","");let i=e.querySelectorAll(".initially-active");e.addEventListener("pointerenter",()=>{i.forEach(r=>{r.classList.remove("initially-active")})}),e.addEventListener("pointerleave",()=>{i.forEach(r=>{r.classList.add("initially-active")})})})}initDesktopHoverIntent(t){let e=".submenu-content, .submenu__categories, .collection-list__collections, .product-list__products, .column-menu > ul",i=Array.prototype.slice.call(t.querySelectorAll(e));t.matches(e)&&i.unshift(t),i.forEach(r=>this.bindHoverIntentGroup(r))}bindHoverIntentGroup(t){if(t.hasAttribute("data-menu-hover-intent-bound"))return;let e=Array.prototype.filter.call(t.children,f=>f instanceof HTMLElement?t.classList.contains("submenu-content")?f.classList.contains("submenu"):f.matches("li:not(.submenu__list-title)"):!1);if(!e.length)return;t.setAttribute("data-menu-hover-intent-bound",""),e.forEach(f=>{f.classList.toggle(lo,!!f.querySelector(Tn))});let i=e.find(f=>f.classList.contains("initially-active")),r=i,s=null,o=null,a=[],u=()=>{s!==null&&(window.clearTimeout(s),s=null)},c=()=>{o!==null&&(window.clearTimeout(o),o=null)},d=f=>{e.forEach(p=>{p.classList.remove("initially-active"),p.classList.toggle(Gt,p===f)}),this.fitProductPanel(f),r=f,s=null},A=(f,p=null,m=!1)=>{if(u(),c(),!(r===f&&f.classList.contains(Gt))){if(!(!m&&r&&r!==f&&r.classList.contains(Gt)&&this.isPointerHeadingToSubmenu(r,p,a))){d(f);return}s=window.setTimeout(()=>d(f),co)}};e.forEach(f=>{f.addEventListener("pointerenter",p=>A(f,p)),f.addEventListener("focusin",()=>A(f,null,!0))}),t.addEventListener("pointerenter",c),t.addEventListener("pointermove",f=>{a.push({x:f.clientX,y:f.clientY,time:f.timeStamp}),a=a.filter(p=>f.timeStamp-p.time<=140).slice(-12)}),t.addEventListener("pointerleave",()=>{u(),c(),o=window.setTimeout(()=>{e.forEach(f=>f.classList.remove(Gt)),i&&i.classList.add("initially-active"),r=i,a=[],o=null},uo)}),t.addEventListener("focusout",()=>{window.setTimeout(()=>{t.contains(document.activeElement)||(e.forEach(f=>f.classList.remove(Gt)),i&&i.classList.add("initially-active"),r=i)},0)})}isPointerHeadingToSubmenu(t,e,i){if(!e||i.length<2)return!1;let r=t.querySelector(Tn);if(!(r instanceof HTMLElement))return!1;let s=i[0],o={x:e.clientX,y:e.clientY},a=o.x-s.x,u=r.getBoundingClientRect();if(a<6||u.left<=o.x)return!1;let c=s.y+(o.y-s.y)*(u.left-s.x)/a;return c>=u.top-24&&c<=u.bottom+24}fitProductPanel(t){let e=t.querySelector(":scope > .product");if(!(e instanceof HTMLElement))return;let i=e.getBoundingClientRect().left,r=document.documentElement.clientWidth,s=window.innerWidth>=1340?64:20,o=r-i-s;e.style.width=`${Math.min(730,Math.max(280,o))}px`}initDesktopHoverFetch(){h.info(`${this.NAME} > initDesktopHoverFetch`);let t=this,e=i=>{if(!(i.target instanceof Element))return;let r=i.target.closest(".theme-header-nav__list-item--has-submenu");if(r){let a=r.querySelector("[data-menu-lazy-panel]");a&&t.loadPanel(a)}let s=i.target.closest("li");if(s&&t.dom.contains(s)){let a=s.querySelector(":scope > [data-menu-lazy-products]");a&&t.loadProducts(a);let u=s.querySelector(":scope > .collection-lists");u&&t.warmNextLevelProducts(u)}let o=i.target.closest("[data-menu-lazy-products]");o&&t.loadProducts(o)};this.dom.addEventListener("pointerover",e),this.dom.addEventListener("focusin",e)}initMobilePrefetch(){h.info(`${this.NAME} > initMobilePrefetch`);let t=this;this.dom.querySelector("[data-theme-header-hamburger]")?.addEventListener("click",()=>{t.prefetchPanels("m")})}productsUrl(t){let e=t.getAttribute("data-collection-url");if(!e)return!1;let i=t.getAttribute("data-menu-products-mode")||"d",r=Ln[i]||Ln.d,s=e.indexOf("?")>-1?"&":"?";return`${e}${s}section_id=${r}`}warmProducts(t){if(!t||t.hasAttribute("data-menu-loaded"))return Promise.resolve();let e=this.productsUrl(t);return e?this.fetchSection(e).catch(i=>{h.info(`${this.NAME} > warmProducts failed: ${i.message}`)}):Promise.resolve()}warmNextLevelProducts(t){let e=this;t.querySelectorAll("[data-menu-lazy-products]").forEach(i=>{(i.parentElement?i.parentElement.closest(".mobile-nav__submenu, .collection-lists, [data-menu-lazy-panel]"):null)===t&&e.warmProducts(i)})}warmPanel(t){return!t||t.hasAttribute("data-menu-loaded")?Promise.resolve():this.fetchSection(this.panelUrl(t)).catch(e=>{h.info(`${this.NAME} > warmPanel failed: ${e.message}`)})}prefetchAllPanels(){h.info(`${this.NAME} > prefetchAllPanels`);let t=this,e=this.desktopMedia.matches?"d":"m",i=e==="d"?"m":"d";this.prefetchPanels(e).then(()=>t.prefetchPanels(i))}prefetchPanels(t){h.info(`${this.NAME} > prefetchPanels (${t})`);let e=this.dom.querySelectorAll(`[data-menu-lazy-panel][data-menu-mode="${t}"]`);return Promise.all(Array.prototype.map.call(e,i=>this.warmPanel(i)))}},ft=class{constructor(t){this.NAME="ThemePopupGalleryGrid",this.dom=t,this.gridItemDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-grid-item]"),this.gridItemOpenActionDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-grid-item-open-action]"),this.overlayDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-grid-overlay]"),this.overlayCloseButtonDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-grid-overlay-close-button]"),this.overlayActiveClass="theme-popup-gallery-grid-overlay--active",this.overlayThumbnailDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-grid-overlay-thumbnail]"),this.overlayArrowBtnDoms=this.dom.querySelectorAll("[data-theme-popup-gallery-btn]"),this.overlayThumbnailDomActiveClass="theme-popup-gallery-grid-overlay__thumbnail--active",this.slider}init(){h.info(`${this.NAME} > init`);let t=this;this.initCloseButtons(),this.initGridItems(),this.initOverlayThumbnails(),this.initOverlayArrowBtns()}closeAllOverlays(t){h.info(`${this.NAME} >
1 closeAllOverlays`),this.overlayDoms.forEach(i=>{i.classList.remove(this.overlayActiveClass)}),this.slider&&(this.slider.destroy(),this.slider=null);let e=document.body.style.top;document.body.style.paddingRight="",document.body.style.position="",document.body.style.width="",document.body.style.top="",document.body.style.zIndex="",t?window.scrollTo({top:parseInt(e||"0")*-1,behavior:"instant"}):window.scrollTo(0,parseInt(e||"0")*-1),document.body.removeEventListener("keydown",this.handleEscKey.bind(this))}handleEscKey(t){h.info(`${this.NAME} > handleEscKey`),t.key==="Escape"&&this.closeAllOverlays(!0)}initCloseButtons(){h.info(`${this.NAME} > initCloseButtons`);let t=this;this.overlayCloseButtonDoms.forEach(e=>{console.log(e),e.addEventListener("click",i=>{console.log(i),i.preventDefault(),t.closeAllOverlays(!0)})})}initGridItems(){h.info(`${this.NAME} > initGridItems`);let t=this;this.gridItemOpenActionDoms.forEach(e=>{e.addEventListener("click",i=>{i.preventDefault();let r=e.closest("[data-theme-popup-gallery-grid-item]");t.showOverlayForGridItem(r)})})}initOverlayThumbnails(){h.info(`${this.NAME} > initOverlayThumbnails`);let t=this;this.overlayThumbnailDoms.forEach(e=>{e.addEventListener("click",i=>{if(i.preventDefault(),!t.slider)return;let r=e.getAttribute("data-theme-popup-gallery-grid-overlay-thumbnail");t.slider.moveToIdx(parseInt(r))})})}initOverlayArrowBtns(){h.info(`${this.NAME} > initOverlayArrowBtns`);let t=this;this.overlayArrowBtnDoms.forEach(e=>{e.addEventListener("click",i=>{i.preventDefault(),t.slider&&(e.dataset.dir=="right"?t.slider.next():t.slider.prev())})})}showOverlayForGridItem(t){h.info(`${this.NAME} > showOverlayForGridItem`);let e=this;this.closeAllOverlays();let i=t.querySelector("[data-theme-popup-gallery-grid-overlay]");if(!i||(i.classList.add(this.overlayActiveClass),this.slider))return;let r=i.querySelector("[data-theme-popup-gallery-grid-overlay-slides]");this.slider=new ut(r,{selector:".theme-popup-gallery-grid-overlay__slide",loop:!0},[s=>{s.on("animationStarted",()=>{h.info(`${this.NAME} > showOverlayForGridItem > animationStarted`),e.dom.querySelectorAll(".theme-popup-gallery-grid-overlay__slide").forEach(a=>{a.classList.add("theme-popup-gallery-grid-overlay__slide--preview-image")})}),s.on("created",()=>{h.info(`${this.NAME} > showOverlayForGridItem > created`),e.updateClasses(s)}),s.on("slideChanged",()=>{h.info(`${this.NAME} > showOverlayForGridItem > slideChanged`),e.updateClasses(s)})}]),document.body.style.top=`-${window.scrollY}px`,document.body.style.paddingRight="15px",document.body.style.position="fixed",document.body.style.width="100%",document.body.style.zIndex="0",document.body.addEventListener("keydown",this.handleEscKey.bind(this))}updateClasses(t){h.info(`${this.NAME} > updateClasses`,t);let e=this;if(!t)return;let i=t.track.details.rel;e.overlayThumbnailDoms.forEach(r=>{parseInt(r.getAttribute("data-theme-popup-gallery-grid-overlay-thumbnail"))==i?r.classList.add(e.overlayThumbnailDomActiveClass):r.classList.remove(e.overlayThumbnailDomActiveClass)}),setTimeout(()=>{e.dom.querySelectorAll(".theme-popup-gallery-grid-overlay__slide").forEach(s=>{s.classList.remove("theme-popup-gallery-grid-overlay__slide--preview-image")})},1e3)}};Object.assign(ft.prototype,K);var mt=class{constructor(t){this.NAME="ThemeRevealableElement",this.dom=t,this.isRevealed=!1,this.isRevealedDataAttribute="data-theme-revealable-element",this.isRevealedDataAttributeValue="revealed"}init(){h.info(`${this.NAME} > init`);let t=this;new IntersectionObserver(i=>{i.forEach(r=>{r.isIntersecting&&!this.isRevealed&&t.reveal()})}).observe(this.dom)}reveal(){h.info(`${this.NAME} > reveal`),this.dom.setAttribute(this.isRevealedDataAttribute,this.isRevealedDataAttributeValue),this.isRevealed=!0}};Object.assign(mt.prototype,K);var Xt=class{constructor(){this.NAME="ImageLoader",h.info(`${this.NAME} > constructor`)}loadImage(t,e){return new Promise((i,r)=>{e||(e=new Image),e.src=t;try{e.onload=()=>{i(e)}}catch(s){r(s)}})}loadArray(t){h.info(`${this.NAME} > loadArray`);let e=[];return t.forEach(i=>{e.push(this.loadImage(i))}),Promise.all(e)}async loadDictionary(t){h.info(`${this.NAME} > loadDictionary`);let e=[],i={};return Object.keys(t).forEach(r=>{let s=new Image;i[r]=s,e.push(this.loadImage(t[r],s))}),await Promise.all(e),i}},_i=class extends HTMLElement{constructor(){super();let t=`
2      <style>
3        :host {
4          width: 100%;
5          height: 100%;
6          display: grid;
7          cursor: pointer;
8        }
9        :host([hidden]) {
10          display: none !important;
11        }
12        div {
13          justify-self: center;
14          align-self: center;
15          width: 60px;
16          height: 60px;
17          opacity: 1;
18          transform: scale(1);
19          transition: all .3s ease-out;
20        }
21        div[data-show="false"] {
22          opacity: 0;
23          transform: scale(0.8);
24        }
25        svg {
26          pointer-events: none;
27        }
28        @media (min-width: 720px) {
29          div {
30            width: 104px;
31            height: 104px;
32          }
33        }
34      </style>
35
36      <div data-show="true">
37        <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 104.44 104.44">
38          <circle cx="52.22" cy="52.22" r="52.22" fill="#fff"/>
39          <path d="M36.86 28.03v48.28l40.1-24.08-40.1-24.2Z" fill="#333f48"/>
40        </svg>
41      </div>
42    `,e=new DOMParser().parseFromString(t,"text/html");this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=e.documentElement.innerHTML,this.div=this.shadowRoot.querySelector("div"),this.svg=this.shadowRoot.querySelector("svg"),this.circle=this.shadowRoot.querySelector("circle"),this.playing=this.dataset.playing==="true",this.div.dataset.show=this.playing?"false":"true",this.setAttribute("title",this.playing?"press to pause":"press to play")}static get observedAttributes(){return["data-playing","fill"]}attributeChangedCallback(t,e,i){t==="data-playing"&&(this.playing=i==="true",this.div.dataset.show=!this.playing,this.setAttribute("title",this.playing?"press to pause":"press to play")),t==="fill"&&this.circle.setAttribute("fill",i)}};customElements.define("theme-play-button",_i);var Ni=class extends HTMLElement{constructor(){super();let t=`
43      <style>
44        @keyframes rotate {
45          100% {
46            transform:rotate(360deg);
47          }
48        }
49        :host {
50          width: 100%;
51          height: 100%;
52          display: grid;
53          pointer-events: none;
54        }
55        div {
56          justify-self: center;
57          align-self: center;
58          width: 60px;
59          height: 60px;
60          opacity: 1;
61          visibility: visible;
62          transition: all 0.3s ease-out;
63        }
64        div[data-show="false"] {
65          opacity: 0;
66          visibility: hidden;
67        }
68        svg {
69          transform-origin: center;
70          animation: rotate .6s linear infinite;
71        }
72        @media (min-width: 720px) {
73          div {
74            width: 104px;
75            height: 104px;
76          }
77        }
78      </style>
79
80      <div data-show="true">
81        <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
82          <path d="M2,12A11.2,11.2,0,0,1,13,1.05C12.67,1,12.34,1,12,1a11,11,0,0,0,0,22c.34,0,.67,0,1-.05C6,23,2,17.74,2,12Z"/>
83        </svg>
84      </div>
85    `,e=new DOMParser().parseFromString(t,"text/html");this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=e.documentElement.innerHTML,this.div=this.shadowRoot.querySelector("div"),this.svg=this.shadowRoot.querySelector("svg"),this.loading=!0}static get observedAttributes(){return["data-loading","fill"]}attributeChangedCallback(t,e,i){t==="data-loading"&&(this.loading=i==="true",this.div.dataset.show=this.loading),t==="fill"&&this.svg.setAttribute("fill",i)}};customElements.define("theme-loading-anim",Ni);var $i=class extends HTMLElement{constructor(){super(),this.NAME="ThemeScrubber",this.INDEX_PLACEHOLDER="$NUM",this.loader=new Xt,this.observer,this.dpr=window.devicePixelRatio,this.rect,this.isPlaying=!1,this.autoplay=!1,this.autoplayInterval,this.fps=30,this.intervalTime=1e3/this.fps,this.currentFrame=0,this.progress=0,this.hasUserInteracted=!1,this.frames,this.canvas=this.querySelector("canvas"),this.ctx=this.canvas.getContext("2d",{alpha:!0}),this.placeholderDom=this.querySelector("[data-scrubber-placeholder-image]"),this.sliderDom=this.querySelector('input[type="range"]'),this.playBtn=this.querySelector("[data-theme-scrubber-play-button]")||this.querySelector(".theme-scrubber__controls theme-play-button"),this.restartPlayBtn=this.querySelector("[data-theme-scrubber-restart-play-button]"),this.loadingAnim=this.querySelector("theme-loading-anim"),this.hasRestartOverlay=!!this.closest(".theme-scrubber-content-module"),h.info(`${this.NAME} > constructor`)}connectedCallback(){h.info(`${this.NAME} > connectedCallback`),this.abortController=new AbortController,this.init()}disconnectedCallback(){h.info(`${this.NAME} > disconnectedCallback`),this.abortController.abort(),this.abortController=null,this.observer&&this.observer.unobserve(this)}static get observedAttributes(){return["fps","autoplay"]}attributeChangedCallback(t,e,i){if(h.info(`${this.NAME} > attributeChangedCallback, ${t} ${i}`),t==="fps"){let r=parseInt(i);isNaN(r)||(this.fps=r,this.intervalTime=1e3/this.fps)}t==="autoplay"&&(this.autoplay=i==="true")}
85async init(){h.info(`${this.NAME} > init`),await this.loadImages(),this.loadingAnim.dataset.loading=!1,window.addEventListener("resize",()=>{this.scaleCanvas(),this.update(this.currentFrame)},{signal:this.abortController.signal}),this.autoplay&&(this.isPlaying=!0),this.scaleCanvas(),this.update(this.currentFrame),this.placeholderDom&&(this.placeholderDom.dataset.show="false"),this.initControls(),this.syncPlayButtons(),this.observer=new IntersectionObserver(t=>{t.forEach(e=>{e.isIntersecting&&this.isPlaying&&this.autoplay&&this.play(),!e.isIntersecting&&this.isPlaying&&this.pause(!this.autoplay)})}),this.observer.observe(this)}async loadImages(){let t=this.querySelectorAll("[data-scrubber-image-set]"),e=[];t.forEach(i=>{let r=i.dataset.url,s=parseInt(i.dataset.startingFrame),o=parseInt(i.dataset.endingFrame);for(let a=s;a<=o;a++)e.push(r.replace(this.INDEX_PLACEHOLDER,a))}),this.sliderDom.max=e.length-1,this.frames=await this.loader.loadArray(e)}scaleCanvas(){this.rect=this.getBoundingClientRect(),this.canvas.width=this.rect.width*this.dpr,this.canvas.height=this.rect.height*this.dpr,this.ctx.scale(this.dpr,this.dpr),this.canvas.style.width=`${this.rect.width}px`,this.canvas.style.height=`${this.rect.height}px`}update(t){!this.frames[t]||(this.ctx.drawImage(this.frames[t],0,0,this.rect.width,this.rect.height),this.progress=t/this.sliderDom.max*100,this.progress+=this.progress<50?.3:-.3,this.sliderDom.style.setProperty("--progress",`${this.progress}%`),this.currentFrame=t,this.syncPlayButtons())}play(){h.info(`${this.NAME} > play`);let t;this.isPlaying=!0,this.syncPlayButtons(),this.autoplayInterval=setInterval(()=>{t=this.currentFrame+1,t>=this.frames.length&&(t=0),requestAnimationFrame(()=>{this.update(t),this.sliderDom.value=t})},this.intervalTime)}pause(t=!0){h.info(`${this.NAME} > pause`),t&&(this.isPlaying=!1),this.autoplayInterval&&(clearInterval(this.autoplayInterval),this.autoplayInterval=null),this.syncPlayButtons()}syncPlayButtons(){if(this.playBtn&&(this.playBtn.dataset.playing=this.isPlaying?"true":"false"),this.restartPlayBtn){let t=this.hasRestartOverlay&&this.hasUserInteracted&&!this.isPlaying&&this.currentFrame===0;this.restartPlayBtn.dataset.playing=this.isPlaying?"true":"false",this.restartPlayBtn.dataset.show=t?"true":"false",this.restartPlayBtn.hidden=!t}}initControls(){h.info(`${this.NAME} > initControls`);let t,{signal:e}=this.abortController.signal;this.sliderDom.addEventListener("touchmove",i=>!1,{signal:e,passive:!1}),this.sliderDom.addEventListener("input",()=>{t=parseInt(this.sliderDom.value),this.hasUserInteracted=!0,this.isPlaying&&this.pause(),this.update(t)},{signal:e}),this.sliderDom.addEventListener("pointerup",()=>{this.syncPlayButtons()},{signal:e}),this.playBtn&&this.playBtn.addEventListener("click",()=>{this.hasUserInteracted=!0,this.isPlaying?this.pause():this.play()},{signal:e}),this.restartPlayBtn&&this.restartPlayBtn.addEventListener("click",()=>{this.hasUserInteracted=!0,this.play()},{signal:e})}};customElements.define("theme-scrubber",$i);var ho="[data-professional-before-after]",In=".professional-case-study__compare-track",fo=".professional-case-study__compare-handle",Pr="ProfessionalBeforeAfter";function te(...n){console.log(`[${Pr}]`,...n)}function mo(n){if(!n){te("bind skipped (no host)");return}if(n.dataset.beforeAfterBound==="true"){te("bind skipped (already bound)",n);return}let t=n.querySelector(In),e=n.querySelector(fo);if(!t){console.warn(`[${Pr}] bind failed: missing track`,In,n);return}n.dataset.beforeAfterBound="true",te("binding",{hasHandle:!!e});let i=new AbortController,{signal:r}=i,s=!1;function o(m){let x=Math.max(0,Math.min(100,m)),L=`${x}%`;n.style.setProperty("--split",L),t.style.setProperty("--split",L),e&&e.setAttribute("aria-valuenow",String(Math.round(x)))}function a(m){let x=t.getBoundingClientRect();return x.width<=0?50:(m-x.left)/x.width*100}function u(m){if(te("pointerdown",{button:m.button,pointerId:m.pointerId,pointerType:m.pointerType,target:m.target&&m.target.className,clientX:m.clientX}),m.button!==void 0&&m.button!==0)return;s=!0;try{t.setPointerCapture(m.pointerId),te("pointer capture OK",m.pointerId)}catch(L){te("pointer capture failed (using document listeners)",L)}let x=a(m.clientX);o(x),te("applied split from pointerdown",{pct:x})}function c(m){!s||(m.preventDefault(),o(a(m.clientX)))}function d(m){if(s){s=!1,te("pointerup / drag end",{pointerId:m.pointerId});try{t.releasePointerCapture(m.pointerId)}catch{}}}function A(m){let x=m.shiftKey?10:3,L=n.style.getPropertyValue("--split").trim(),T=parseFloat(L);switch(Number.isFinite(T)||(T=parseFloat(n.dataset.initialSplit),Number.isFinite(T)||(T=50)),m.key){case"ArrowLeft":m.preventDefault(),o(T-x);break;case"ArrowRight":m.preventDefault(),o(T+x);break;case"Home":m.preventDefault(),o(0);break;case"End":m.preventDefault(),o(100);break;default:break}}let f=parseFloat(n.dataset.initialSplit),p=Number.isFinite(f)?f:50;o(p),t.addEventListener("pointerdown",u,{signal:r}),document.addEventListener("pointermove",c,{signal:r}),document.addEventListener("pointerup",d,{signal:r}),document.addEventListener("pointercancel",d,{signal:r}),e&&e.addEventListener("keydown",A,{signal:r}),te("bound")}function Cr(n){let t=n&&n.querySelectorAll?n:document,e=t===document?"document":t.id||t.className||t.nodeName;try{let i=t.querySelectorAll(ho);te("init",{scope:e,hostCount:i.length,readyState:document.readyState}
85),i.forEach(mo)}catch(i){console.error(`[${Pr}] init failed`,i)}}function po(n){let t=n.detail&&n.detail.sectionId,e=t?document.getElementById(`shopify-section-${t}`):null;Cr(e||document)}document.addEventListener("shopify:section:load",po),te("module loaded",{readyState:document.readyState,script:document.currentScript&&document.currentScript.src});function Dn(n){te("boot retry:",n),Cr(document)}Cr(document),document.readyState==="loading"&&document.addEventListener("DOMContentLoaded",()=>Dn("DOMContentLoaded"),{once:!0}),window.addEventListener("load",()=>Dn("window load"),{once:!0});var Mr=class extends HTMLElement{constructor(){super(),this.NAME="ThemeMosaic",this.abortController,this.container=this.querySelector("[data-mosaic-container]"),this.lightbox=this.querySelector("[data-mosaic-lightbox]"),this.closeBtn=this.querySelector("[data-mosaic-lightbox-close-btn]"),this.areas=this.querySelectorAll("[data-area-clickable]"),this.directionalBtns=this.querySelectorAll("[data-carousel-btn][data-dir]"),this.carousel=this.querySelector("simple-carousel"),this.max=this.areas.length,this.breakpoint=960,h.info(`${this.NAME} > constructor`)}connectedCallback(){h.info(`${this.NAME} > connectedCallback`),this.init()}disconnectedCallback(){h.info(`${this.NAME} > disconnectedCallback`),this.abortController.abort(),this.abortController=null}static get observedAttributes(){return["carousel-breakpoint"]}attributeChangedCallback(t,e,i){if(h.info(`${this.NAME} > attributeChangedCallback, ${t} ${i}`),t==="carousel-breakpoint"){let r=parseInt(i);isNaN(r)||(this.breakpoint=r)}}init(){this.abortController=new AbortController;let{signal:t}=this.abortController.signal;this.areas.forEach(e=>{e.addEventListener("click",()=>{this.curIndex=parseInt(e.dataset.area),this.lightbox.dataset.activeItem=e.dataset.area,this.lightbox.dataset.show="true"},{signal:t})}),this.addEventListener("click",e=>{(e.target===this.container||e.target===this.lightbox)&&(this.lightbox.dataset.show="false")},{signal:t}),this.closeBtn.addEventListener("click",()=>{this.lightbox.dataset.show="false"},{signal:t}),this.directionalBtns.forEach(e=>{e.addEventListener("click",i=>{this.onDirBtn(i.target.dataset.dir)},{signal:t})}),window.addEventListener("resize",()=>this.onResize(),{signal:t}),this.onResize()}onDirBtn(t){let e=t==="right"?this.curIndex+1:this.curIndex-1;e=e>this.max?1:e<1?this.max:e,this.curIndex=e,this.lightbox.dataset.activeItem=this.curIndex}onResize(){window.innerWidth>this.breakpoint&&this.carousel.parentNode?this.carousel.remove():window.innerWidth<=this.breakpoint&&!this.carousel.parentNode&&this.container.appendChild(this.carousel)}};customElements.define("theme-mosaic",Mr);var xr=class extends HTMLElement{constructor(){super(),this.NAME="SimpleCarousel";let e=document.getElementById("simple-carousel-template").content;this.abortController,this.slides=this.querySelectorAll('[slot^="slide-"]'),this.slides.forEach(r=>r.style.visibility="hidden"),this.style.visibility="hidden",this.length=this.slides.length,this.maxVisible=3,this.max=this.length-1,this.indexBtns=[],this.curIndex=0,this.duration=400,this.timeThreshhold=100,this.swipeThreshhold=50,this.swipeStart=0,this.swipeTimeBegin=0,this.swiping=!1,this.showDirectionalBtns=!0,this.showIndexBtns=!1,this.smallIndexBtns=!1,this.mobileWidthImportant="!important",this.noClones=this.hasAttribute("no-clones");let i=this.getAttribute("slides-align");if(!this.noClones&&this.length>1){this.clones=[this.slides[0].cloneNode(!0),this.slides[1].cloneNode(!0),i==="left"&&this.slides[2]?this.slides[2].cloneNode(!0):null,i==="left"&&this.slides[3]?this.slides[3].cloneNode(!0):null,this.slides[this.max].cloneNode(!0),this.slides[this.max-1]?this.slides[this.max-1].cloneNode(!0):null],this.clones=this.clones.filter(o=>o);let r=i==="left"&&this.length>=4?4:2,s=i==="left"&&this.length>=4?this.length+5:this.length+3;this.clones[r].style.transform=`translateX(${s*-100}%)`,this.clones[r+1].style.transform=`translateX(${(s+2)*-100}%)`,this.clones.forEach((o,a)=>{o.setAttribute("slot",`slide-clone-${a+1}`),this.appendChild(o)})}this.attachShadow({mode:"open"}),this.shadowRoot.appendChild(e.cloneNode(!0)),this.main=this.shadowRoot.querySelector("main"),this.containerShadowDom=this.shadowRoot.querySelector("[data-carousel-container]"),this.containerShadowDom.style.width=`${100/this.maxVisible}%`,this.hasAttribute("mobile-width-important")&&this.containerShadowDom.setAttribute("mobile-width-important","true"),this.slidesShadowDom=this.shadowRoot.querySelector("[data-carousel-slides]"),this.directionalBtns=this.shadowRoot.querySelectorAll("[data-carousel-btn][data-dir]"),this.directionalBtnContainer=this.directionalBtns[0].parentElement,this.customButtons=this.querySelectorAll('[slot="custom-btns"] [data-carousel-btn][data-dir]'),this.indexBtnContainer=this.shadowRoot.querySelector("[data-carousel-index-btns]"),h.info(`${this.NAME} > constructor`)}connectedCallback(){h.info(`${this.NAME} > connectedCallback`),this.init()}disconnectedCallback(){h.info(`${this.NAME} > disconnectedCallback`),this.kill()}static get observedAttributes(){return["duration","max-visible","show-index-buttons","small-index-buttons","show-directional-buttons","row-gap","data-cur-index","slides-align","theme"]}attributeChangedCallback(t,e,i){if(h.info(`${this.NAME} > attributeChangedCallback, ${t} ${i}`),t==="duration"){let r=parseInt(i);isNaN(r)||(this.duration=r)}if(t==="max-visible"){let r=parseInt(i);isNaN(r)||(this.maxVisible=r,this.main.dataset.maxVisible=r,this.containerShadowDom.style.width=`${100/this.maxVisible}%`,this.maxVisible%2?this.shadowRoot.querySelectorAll('[slot^="slide-"]').forEach(s=>s.style.transform=null):this.shadowRoot.querySelectorAll('[slot^="slide-"]').forEach(s=>s.style.transform="translateX(-50%)"))}if(t==="show-index-buttons"&&(this.showIndexBtns=i!=="false"||i!=="",this.indexBtnContainer.dataset.show=this.showIndexBtns,this.indexBtnContainer.dataset.showFor=i),t==="small-index-buttons"&&(this.smallIndexBtns=i==="true",this.indexBtnContainer.dataset.show=this.showIndexBtns),t==="show-directional-buttons"&&(this.showDirectionalBtns=i==="true",this.directionalBtnContainer.dataset.show=this.showDirectionalBtns),t==="row-gap"&&(this.main.style.rowGap=i),t==="data-cur-index"){let r=parseInt(i);!isNaN(r)&&r!==this.curIndex&&this.onIndexBtn(r)}t==="slides-align"&&(this.containerShadowDom.dataset.align=i),t==="theme"&&(this.main.dataset.theme=i)}init(){h.info(`${this.NAME} > init`),this.abortController=new AbortController;let{signal:t}=this.abortController;
85this.querySelectorAll('[slot^="slide-"]').forEach(e=>e.style.visibility=null),this.style.visibility=null,this.duration&&(this.slidesShadowDom.style.transition=`transform ${this.duration}ms ease-out`,this.slidesShadowDom.style.transform="translate3d(0%,0%,0)"),this.showDirectionalBtns&&this.directionalBtns.forEach(e=>{e.addEventListener("click",i=>this.onDirBtn(i.target.dataset.dir),{signal:t})}),this.customButtons&&(this.shadowRoot.querySelector('[name="custom-btns"]').dataset.show="true",this.customButtons.forEach(e=>{e.addEventListener("click",i=>this.onDirBtn(i.target.dataset.dir),{signal:t})})),this.showIndexBtns&&this.slides.forEach((e,i)=>{let r=document.createElement("BUTTON");r.dataset.carouselDot="true",r.dataset.index=i,r.dataset.active=i?"false":"true",r.title=`go to slide ${i+1}`,r.addEventListener("click",s=>this.onIndexBtn(parseInt(s.target.dataset.index),{signal:t})),this.smallIndexBtns&&(r.dataset.small="true"),this.indexBtnContainer.appendChild(r),this.indexBtns.push(r)}),this.hasAttribute("no-swipe")||(this.addEventListener("touchstart",e=>this.onTouchStart(e.changedTouches[0].clientX,e.timeStamp),{signal:t}),this.addEventListener("touchend",e=>this.onTouchEnd(e.changedTouches[0].clientX,e.timeStamp),{signal:t}),this.addEventListener("touchmove",e=>{this.onTouchMove(e.changedTouches[0].clientX),e.preventDefault()},{signal:t,passive:!1}))}onDirBtn(t){if(this.slidesShadowDom.style.transitionDuration==="0s")return;let e=t==="right"?this.curIndex+1:this.curIndex-1,i=e>this.max?0:e<0?this.max:e;this.updateIndexBtns(i,t),e>this.max&&this.clones?setTimeout(()=>{this.curIndex=0,this.slidesShadowDom.style.transitionDuration="0s",this.slidesShadowDom.style.transform="translate3d(0%,0%,0)",setTimeout(()=>{this.slidesShadowDom.style.transitionDuration=`${this.duration}ms`},40)},this.duration):e===-1&&setTimeout(()=>{this.curIndex=this.max,this.slidesShadowDom.style.transitionDuration="0s",this.slidesShadowDom.style.transform=`translate3d(${this.curIndex*-100}%,0,0)`,setTimeout(()=>{this.slidesShadowDom.style.transitionDuration=`${this.duration}ms`},40)},this.duration),this.curIndex=e,this.clones&&(this.slidesShadowDom.style.transform=`translate3d(${this.curIndex*-100}%,0,0)`)}onIndexBtn(t){this.curIndex=t,this.updateIndexBtns(this.curIndex),this.clones&&(this.slidesShadowDom.style.transform=`translate3d(${this.curIndex*-100}%,0,0)`)}updateIndexBtns(t,e){this.indexBtns.length&&(this.indexBtns.forEach(i=>i.dataset.active="false"),this.indexBtns[t].dataset.active="true"),this.dispatchEvent(new CustomEvent("index-change",{detail:{index:t,direction:e}}))}onTouchStart(t,e){this.containerShadowDom.style.transitionDuration="0s",this.swipeStart=t,this.swipeTimeBegin=e,this.swiping=!0}onTouchEnd(t,e){this.swiping=!1,this.containerShadowDom.style.transitionDuration="0.24s",this.containerShadowDom.style.transform="translate3d(0%,0,0)";let i=this.swipeStart-t;e-this.swipeTimeBegin>this.timeThreshhold&&Math.abs(i)>=this.swipeThreshhold&&(this.onDirBtn(i>0?"right":"left"),this.swipeStart=0,this.swipeTimeBegin=0)}onTouchMove(t){if(this.swiping){let e=Math.round(this.swipeStart-t)/10;this.containerShadowDom.style.transform=`translate3d(${-e}%,0,0)`}}kill(){h.info(`${this.NAME} > kill`),this.curIndex=0,this.abortController.abort(),this.abortController=null,this.indexBtns.forEach(t=>t.parentElement.removeChild(t)),this.slidesShadowDom.style=void 0,this.containerShadowDom.style.transform=null,this.containerShadowDom.style.transitionDuration=null}};customElements.define("simple-carousel",xr);var Lr=class extends HTMLElement{constructor(){super(),this.items=Array.from(this.querySelectorAll("[data-theme-popup-scrubber-item]")),this.templates=this.items.map(t=>
85t.querySelector("template")),this.templates.forEach(t=>t.remove())}connectedCallback(){this.abortController=new AbortController;let{signal:t}=this.abortController;this.items.forEach((e,i)=>{let r=e.querySelector("[data-theme-popup-scrubber-overlay]"),s=e.querySelectorAll("[data-theme-popup-scrubber-item-open-action]"),o=e.querySelector("[data-theme-popup-scrubber-overlay-close-button]"),a=r.lastElementChild.firstElementChild,u=()=>{a.firstElementChild||(a.innerHTML=this.templates[i].innerHTML),r.classList.add("theme-popup-scrubber-overlay--active"),r.dataset.autoplay=="true"&&a.firstElementChild.play(),document.body.style.top=`-${window.scrollY}px`,document.body.style.paddingRight="15px",document.body.style.position="fixed",document.body.style.width="100%",document.body.style.zIndex="0"};s.forEach(c=>{c.addEventListener("click",u,{signal:t})}),o.addEventListener("click",()=>{let c=document.body.style.top;document.body.style.paddingRight="",document.body.style.position="",document.body.style.width="",document.body.style.top="",document.body.style.zIndex="",window.scrollTo({top:parseInt(c||"0")*-1,behavior:"instant"}),r.classList.remove("theme-popup-scrubber-overlay--active"),a.firstElementChild.pause()},{signal:t})})}disconnectedCallback(){this.abortController.abort(),this.abortController=null}};customElements.define("theme-popup-scrubber",Lr);var pt=class{constructor(t){this.NAME="TheneSideOpenAccordion",this.dom=t,this.buttonDoms=this.dom.querySelectorAll("[data-theme-side-open-accordion-button]"),this.buttonDomActiveClass="theme-side-open-accordion__button--active",this.buttonDomInactiveClass="theme-side-open-accordion__button--inactive",this.drawerDomAttribute="data-theme-side-open-accordion-drawer",this.drawerDoms=this.dom.querySelectorAll(`[${this.drawerDomAttribute}]`),this.drawerDomActiveClass="theme-side-open-accordion__drawer--active",this.closeBtnDoms=this.dom.querySelectorAll(".theme-side-open-accordion__close-btn")}init(){h.info(`${this.NAME} > init`);let t=this;this.buttonDoms.length&&this.openDrawer(this.buttonDoms[0]),this.buttonDoms.forEach(e=>{e.addEventListener("click",i=>{i.preventDefault(),t.openDrawer(e)})}),this.closeBtnDoms.forEach(e=>{e.addEventListener("click",()=>{t.buttonDoms.forEach(i=>{i.classList.remove(t.buttonDomInactiveClass),i.classList.remove(t.buttonDomActiveClass)}),t.drawerDoms.forEach(i=>{i.classList.remove(t.drawerDomActiveClass)})})})}openDrawer(t){this.buttonDoms.forEach(r=>{r==t?(r.classList.add(this.buttonDomActiveClass),r.classList.remove(this.buttonDomInactiveClass)):(r.classList.remove(this.buttonDomActiveClass),r.classList.add(this.buttonDomInactiveClass))}),this.drawerDoms.forEach(r=>{r.classList.remove(this.drawerDomActiveClass)}),t.closest("[data-theme-side-open-accordion-list-item]")?.querySelector(`[${this.drawerDomAttribute}]`)?.classList.add(this.drawerDomActiveClass)}};Object.assign(pt.prototype,K);var yt=class{constructor(t){if(this.NAME="ThemeVideoBaner",this.nativeVideoDom=t.querySelector("[data-theme-video-banner-native]"),this.vimeoDom=t.querySelector("[data-theme-video-banner-video]"),this.youtubeDom=t.querySelector("[data-theme-video-banner-youtube]"),this.videoDom=this.nativeVideoDom||this.vimeoDom||this.youtubeDom,!!this.videoDom){if(this.vimeoDom&&!this.nativeVideoDom){let e=me();this.vimeoDom.setAttribute("id",e),this.vimeoId=this.vimeoDom.getAttribute("data-theme-video-banner-video")?.trim(),this.vimeoUrl=/^https?:\/\//i.test(this.vimeoId)?this.vimeoId:`https://vimeo.com/${this.vimeoId}`}this.youtubeDom&&(this.youtubeId=this.youtubeDom.getAttribute("data-theme-video-banner-youtube"),this.youtubePlaying=!1,this.youtubeIframe=null,this.youtubeMessageHandler=null),this.autoplay=this.videoDom.getAttribute("data-theme-video-banner-video-autoplay"),this.showPlayerControls=this.videoDom.getAttribute("data-theme-video-banner-player-controls")==="true",this.placeholderImageDom=t.querySelector("[data-theme-video-banner-placeholder-image]"),this.placeholderImageDomHiddenClass="theme-video-banner__image--hidden",this.vimeoPosterDom=t.querySelector("[data-theme-video-banner-vimeo-poster]"),this.youtubePosterImageDom=t.querySelector("[data-theme-video-banner-youtube-poster]"),this.playButtonDom=t.querySelector("theme-play-button"),this.muteButtonDom=t.querySelector("[data-theme-video-banner-mute-button]"),this.videoContainerDom=t.querySelector(".theme-video-banner__video-container"),this.videoPlayer=null,this.playerInitialized=!1}}init(){if(h.info(`${this.NAME} > init`),!this.videoDom)return;let t=this,e=this.autoplay==="true";if(this.vimeoPosterPromise=this.loadVimeoPoster(),this.loadYouTubePoster(),!e){this.showPlayButton();let r=async s=>{s.target.closest?.("[data-theme-video-banner-mute-button]")||this.playerInitialized||(s.preventDefault(),this.videoContainerDom.removeEventListener("click",r),this.playerInitialized=!0,await this.vimeoPosterPromise,t.nativeVideoDom?t.initializeNativePlayer(!0):t.y
85outubeDom?t.initializeYouTubePlayer(!0):t.initializeVideoPlayer(!0))};this.videoContainerDom.addEventListener("click",r);return}new IntersectionObserver(r=>{r.forEach(async s=>{s.isIntersecting&&!this.playerInitialized&&(this.playerInitialized=!0,await this.vimeoPosterPromise,t.nativeVideoDom?t.initializeNativePlayer():t.youtubeDom?t.initializeYouTubePlayer():t.initializeVideoPlayer())})}).observe(this.videoDom)}async loadVimeoPoster(){if(!this.vimeoPosterDom||!this.vimeoId)return;let t=this.vimeoPosterDom.querySelector("img");try{let e=await fetch(`https://vimeo.com/api/oembed.json?url=${encodeURIComponent(this.vimeoUrl)}&width=1920`);if(!e.ok)throw new Error(`Vimeo oEmbed request failed: ${e.status}`);let i=await e.json();i.thumbnail_url&&t&&(t.src=i.thumbnail_url,t.alt=i.title||"",typeof t.decode=="function"&&await t.decode())}catch(e){h.error(`${this.NAME} > loadVimeoPoster`,e)}}loadYouTubePoster(){if(!this.youtubePosterImageDom)return;let t=this.youtubePosterImageDom,e=t.dataset.maxresSrc,i=t.dataset.fallbackSrc,r=new Image,s=()=>{t.src=i};r.addEventListener("load",()=>{t.src=r.naturalWidth>=640?e:i},{once:!0}),r.addEventListener("error",s,{once:!0}),r.src=e}hidePlayButton(){h.info(`${this.NAME} > hidePlayButton`),this.playButtonDom&&(this.playButtonDom.dataset.playing="true",this.showPlayerControls&&this.playerInitialized&&this.playButtonDom.setAttribute("hidden",""))}initializeNativePlayer(t=!1){h.info(`${this.NAME} > initializeNativePlayer`);let e=this,i=this.nativeVideoDom;if(this.muteButtonDom?.removeAttribute("hidden"),this.muteButtonDom?.addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),i.muted=!i.muted,e.updateMuteButton(i.muted)}),i.addEventListener("volumechange",function(){e.updateMuteButton(i.muted||i.volume===0)}),i.addEventListener("ended",function(){e.showPlayButton(),e.showPlaceholderImage(),i.currentTime=0}),i.addEventListener("play",function(){e.hidePlayButton(),e.hidePlaceholderImage()}),i.addEventListener("pause",function(){e.showPlayButton()}),this.autoplay==="true"){h.info(`${this.NAME} > initializeNativePlayer > autoplay`),this.hidePlayButton(),i.muted=!0;let s=i.play();s&&s.catch&&s.catch(()=>e.showPlayButton())}else t?i.play().catch(()=>e.showPlayButton()):(i.preload="metadata",this.showPlayButton())}initializeVideoPlayer(t=!1){h.info(`${this.NAME} > initializeVideoPlayer`);let e=this,i=this.autoplay==="true";this.muteButtonDom?.removeAttribute("hidden"),this.videoPlayer=new xe(this.vimeoDom.getAttribute("id"),{url:this.vimeoUrl,controls:this.showPlayerControls,title:!1,responsive:!0,background:!1,byline:!1,portrait:!1,playsinline:!0,autopause:!1,muted:i}),this.muteButtonDom?.addEventListener("click",async r=>{r.preventDefault(),r.stopPropagation();let s=this.muteButtonDom.dataset.muted==="true";try{typeof this.videoPlayer.setMuted=="function"?await this.videoPlayer.setMuted(!s):await this.videoPlayer.setVolume(s?1:0),e.updateMuteButton(!s)}catch(o){h.error(`${this.NAME} > toggleMute`,o)}}),this.videoPlayer.on("volumechange",function(r){e.updateMuteButton(r.muted===!0||r.volume===0)}),this.videoPlayer.on("ended",function(){e.showPlayButton(),e.showPlaceholderImage(),e.videoPlayer.setCurrentTime(0)}),this.videoPlayer.on("play",function(){e.hidePlayButton(),e.hidePlaceholderImage()}),this.videoPlayer.on("pause",function(){e.showPlayButton()}),i?(h.info(`${this.NAME} > initializeVideoPlayer > autoplay`),this.hidePlayButton(),this.muteVideo(),this.playVideo()):t?(this.hidePlayButton(),this.playVideo()):this.showPlayButton()}initializeYouTubePlayer(t=!1){h.info(`${this.NAME} > initializeYouTubePlayer`);let e=this.autoplay==="true",i=e||t;this.muteButtonDom?.removeAttribute("hidden");let r=new URLSearchParams({autoplay:i?"1":"0",controls:this.showPlayerControls?"1":"0",enablejsapi:"1",playsinline:"1",rel:"0",mute:e?"1":"0",origin:window.location.origin}),s=document.createElement("iframe");s.id=me(),s.src=`https://www.youtube-nocookie.com/embed/${encodeURIComponent(this.youtubeId)}?${r.toString()}`,s.title="YouTube video player",s.allow="autoplay; encrypted-media; picture-in-picture; fullscreen",s.allowFullscreen=!0,s.setAttribute("frameborder","0"),this.youtubeDom.appendChild(s),this.youtubeIframe=s,this.youtubePlaying=i;let o=(a,u=[])=>{s.contentWindow?.postMessage(JSON.stringify({event:"command",func:a,args:u}),"*")};s.addEventListener("load",()=>{s.contentWindow?.postMessage(JSON.stringify({event:"listening",id:s.id}),"*"),i?(e&&o("mute"),o("playVideo"),this.hidePlayButton(),this.hidePlaceholderImage()):this.showPlayButton()}),this.youtubeMessageHandler=a=>{if(a.source!==s.contentWindow)return;let u=a.data;if(typeof u=="string")try{u=JSON.parse(u)}catch{return}u?.event==="onStateChange"&&(u.info===1?(this.youtubePlaying=!0,this.hidePlayButton(),this.hidePlaceholderImage()):(u.info===0||u.info===2)&&(this.youtubePlaying=!1,this.showPlayButton(),u.info===0&&(o("seekTo",[0,!0]),this.showPlaceholderImage())))},window.addEventListener("message",this.youtubeMessageHandler),this.muteButtonDom?.addEventListener("click",a=>{a.preventDefault(),a.stopPropagation();let u=this.muteButtonDom.dataset.muted==="true";o(u?"unMute":"mute"),this.updateMuteButton(!u)})}hidePlaceholderImage(){h.info(`${this.NAME} > hidePlaceholderImage`),this.placeholderImageDom?.classList.add(this.placeholderImageDomHiddenClass)}muteVideo(){h.info(`${this.NAME} > muteVideo`),typeof this.videoPlayer?.setMuted=="function"?this.videoPlayer.setMuted(!0):this.videoPlayer?.setVolume(0),this.updateMuteButton(!0)}updateMuteButton(t){!this.muteButtonDom||(this.muteButtonDom.dataset.muted=t?"true":"false",this.muteButtonDom.setAttribute("aria-pressed",t?"true":"false"),this.muteButtonDom.setAttribute("aria-label",t?"Unmute video":"Mute video"))}playVideo(){h.info(`${this.NAME} > playVideo`),this.videoPlayer?.play()}pauseVideo(){h.info(`${this.NAME} > pauseVideo`),this.videoPlayer?.pause()}showPlaceholderImage(){h.info(`${this.NAME} > showPlaceholderImage`),this.placeholderImageDom?.classList.remove(this.placeholderImageDomHiddenClass)}showPlayButton(){if(h.info(`${this.NAME} > showPlayButton`),!!this.playButtonDom){if(this.showPlayerControls&&this.playerInitialized){this.playButtonDom.setAttribute("hidden","");return}this.playButtonDom.removeAttribute("hidden"),this.playButtonDom.dataset.playing="false"}}};Object.assign(yt.prototype,K);var vt=class{constructor(t){this.NAME="ThemeVideoContentModule",this.videoDom=t.querySelector("[data-theme-video-content-module-video]");let e=me();this.videoDom.setAttribute("id",e),this.playButtonDom=t.querySelector("theme-play-button"),this.vimeoId=this.videoDom?.getAttribute("data-theme-video-content-module-video"),this.videoPlayer=null}init(){h.info(`${this.NAME} > init`);let t=this;new IntersectionObserver(i=>
85{i.forEach(r=>{r.isIntersecting&&!this.videoPlayer&&t.initializeVideoPlayer()})}).observe(this.videoDom)}hidePlayButton(){h.info(`${this.NAME} > hidePlayButton`),this.playButtonDom.dataset.playing="true"}initializeVideoPlayer(){h.info(`${this.NAME} > initializeVideoPlayer`);let t=this;this.videoPlayer=new xe(this.videoDom.getAttribute("id"),{id:this.vimeoId,controls:!0,title:!1}),this.videoPlayer.on("ended",function(){t.showPlayButton(),this.videoPlayer.setCurrentTime(0)}),this.videoPlayer.on("play",function(){t.hidePlayButton()}),this.videoPlayer.on("pause",function(){t.showPlayButton()}),this.playButtonDom.addEventListener("click",e=>{e.preventDefault();let i=this.videoPlayer.getPaused().then(r=>{r?t.playVideo():t.pauseVideo()})})}playVideo(){h.info(`${this.NAME} > playVideo`),this.videoPlayer?.play()}pauseVideo(){h.info(`${this.NAME} > pauseVideo`),this.videoPlayer?.pause()}showPlayButton(){h.info(`${this.NAME} > showPlayButton`),this.playButtonDom.dataset.playing="false"}};Object.assign(vt.prototype,K);var bt,j,Qt,wt,le,we,Et,Le,ze,Ee,At,St,Te,Zt,ei,Ir,qi,_n,ti,Dr,ii,_r,ri,Nr,kt,Bi,Oi,Nn,Fi,$n,Ie,gt,He,Jt,Vi,Bn,Ri,qn,Tr=class extends HTMLElement{constructor(){super(),S(this,ei),S(this,qi),S(this,ti),S(this,ii),S(this,ri),S(this,kt),S(this,Oi),S(this,Fi),S(this,Ie),S(this,He),S(this,Vi),S(this,Ri),S(this,bt,void 0),S(this,j,void 0),S(this,Qt,void 0),S(this,wt,void 0),S(this,le,void 0),S(this,we,void 0),S(this,Et,void 0),S(this,Le,void 0),S(this,ze,void 0),S(this,Ee,void 0),S(this,At,void 0),S(this,St,void 0),S(this,Te,new Map),S(this,Zt,void 0),D(this,bt,this.querySelector("[data-theme-search-bar-btn]")),D(this,j,this.querySelector("[data-theme-search-bar-input]")),D(this,Qt,this.querySelector("[data-theme-search-bar-close]")),D(this,wt,this.querySelector("[data-theme-search-bar-form]")),D(this,le,this.querySelector("[data-theme-search-bar-suggestions]")),D(this,we,this.querySelector("[data-theme-search-bar-suggestions-list]")),D(this,Et,this.querySelector("[data-theme-search-bar-status]")),D(this,Le,this.querySelector("[data-theme-search-bar-all-results]"))}connectedCallback(){D(this,ze,new AbortController);let{signal:e}=l(this,ze);l(this,bt).addEventListener("click",()=>{this.dataset.showInput="true",requestAnimationFrame(()=>l(this,j).focus())},{signal:e}),l(this,Qt).addEventListener("click",()=>{this.dataset.showInput="false",C(this,Ie,gt).call(this),l(this,bt).focus()},{signal:e}),l(this,wt).addEventListener("submit",i=>C(this,Ri,qn).call(this,i),{signal:e}),l(this,St)==="default"&&l(this,le)&&(l(this,j).addEventListener("input",()=>C(this,ei,Ir).call(this),{signal:e}),l(this,j).addEventListener("focus",()=>C(this,ei,Ir).call(this),{signal:e}),this.addEventListener("keydown",i=>C(this,Vi,Bn).call(this,i),{signal:e}),document.addEventListener("click",i=>{this.contains(i.target)||C(this,Ie,gt).call(this)},{signal:e}))}disconnectedCallback(){clearTimeout(l(this,At)),l(this,Ee)?.abort(),l(this,ze).abort(),D(this,ze,null)}static get observedAttributes(){return["data-show-input","data-search-type"]}attributeChangedCallback(e,i,r){e==="data-show-input"&&r==="false"&&(l(this,j).value="",C(this,Ie,gt).call(this)),e==="data-search-type"&&D(this,St,r)}};bt=new WeakMap,j=new WeakMap,Qt=new WeakMap,wt=new WeakMap,le=new WeakMap,we=new WeakMap,Et=new WeakMap,Le=new WeakMap,ze=new WeakMap,Ee=new WeakMap,At=new WeakMap,St=new WeakMap,Te=new WeakMap,Zt=new WeakMap,ei=new WeakSet,Ir=function(){clearTimeout(l(this,At));let e=l(this,j).value.trim();if(e.length<2){l(this,Ee)?.abort(),C(this,Ie,gt).call(this);return}let i=e.toLowerCase(),r=l(this,Te).get(i);if(r){l(this,Ee)?.abort(),C(this,ti,Dr).call(this,r,e),C(this,kt,Bi).call(this,e,r.length?"results":"empty",r.length);return}l(this,Ee)?.abort(),C(this,Oi,Nn).call(this),D(this,At,window.setTimeout(()=>C(this,qi,_n).call(this,e),100))},qi=new WeakSet,_n=async function(e){l(this,Ee)?.abort();let i=new AbortController,r=!1,s=window.setTimeout(()=>{r=!0,i.abort()},8e3);D(this,Ee,i),C(this,He,Jt).call(this,"Loading suggestions");let o=this.dataset.predictiveUrl||"/search/suggest",a=o.endsWith(".json")?o:`${o}
85.json`,u=new URL(a,window.location.origin);u.searchParams.set("q",e),u.searchParams.set("resources[type]","product,collection,page,article"),u.searchParams.set("resources[limit]","6"),u.searchParams.set("resources[options][unavailable_products]","show");try{let c=await fetch(u,{headers:{Accept:"application/json"},signal:i.signal});if(!c.ok)throw new Error(`Predictive search failed: ${c.status}`);let d=await c.json();if(e!==l(this,j).value.trim())return;let A=d.resources?.results||{},f=[...(A.collections||[]).map(p=>({...p,resultType:"Collection"})),...(A.products||[]).map(p=>({...p,resultType:"Product"})),...(A.pages||[]).map(p=>({...p,resultType:"Page"})),...(A.articles||[]).map(p=>({...p,resultType:"Article"}))].slice(0,6);l(this,Te).set(e.toLowerCase(),f),l(this,Te).size>20&&l(this,Te).delete(l(this,Te).keys().next().value),C(this,ti,Dr).call(this,f,e),C(this,kt,Bi).call(this,e,f.length?"results":"empty",f.length)}catch(c){if(c.name==="AbortError"&&!r||e!==l(this,j).value.trim())return;C(this,ii,_r).call(this,"Suggestions unavailable",e),C(this,kt,Bi).call(this,e,"unavailable",0)}finally{clearTimeout(s)}},ti=new WeakSet,Dr=function(e,i){if(l(this,we).replaceChildren(),e.forEach((r,s)=>{let o=document.createElement("li"),a=document.createElement("a"),u=document.createElement("span"),c=document.createElement("span"),d=document.createElement("span"),A=C(this,Fi,$n).call(this,r);if(o.className="theme-search-bar__suggestion",o.setAttribute("role","none"),a.className="theme-search-bar__suggestion-link",a.href=r.url,a.id=`${l(this,we).id}-option-${s}`,a.setAttribute("role","option"),A){let f=document.createElement("span"),p=document.createElement("img");f.className="theme-search-bar__suggestion-media",p.src=A,p.alt="",p.loading="lazy",f.append(p),a.append(f)}else a.classList.add("theme-search-bar__suggestion-link--text-only");u.className="theme-search-bar__suggestion-text",c.className="theme-search-bar__suggestion-title",c.textContent=r.title,d.className="theme-search-bar__suggestion-type",d.textContent=r.resultType,u.append(c,d),a.append(u),o.append(a),l(this,we).append(o)}),!e.length){C(this,ii,_r).call(this,"No results found.",i);return}C(this,ri,Nr).call(this,i),l(this,Le).hidden=!1,l(this,le).hidden=!1,l(this,j).setAttribute("aria-expanded","true"),C(this,He,Jt).call(this,`${e.length} search suggestions available`)},ii=new WeakSet,_r=function(e,i){let r=document.createElement("li");r.className="theme-search-bar__response-state",r.textContent=e,l(this,we).replaceChildren(r),C(this,ri,Nr).call(this,i),l(this,Le).hidden=!1,l(this,le).hidden=!1,l(this,j).setAttribute("aria-expanded","true"),C(this,He,Jt).call(this,e)},ri=new WeakSet,Nr=function(e){let i=new URL(l(this,wt).action,window.location.origin);i.searchParams.set("q",e),i.searchParams.set("options[prefix]","last"),i.searchParams.set("options[unavailable_products]","show"),l(this,Le).href=`${i.pathname}${i.search}`},kt=new WeakSet,Bi=function(e,i,r){let s=e.trim(),o=`${s.toLowerCase()}:${i}:${r}`;if(!s||o===l(this,Zt))return;let a=window.Shopify?.analytics?.publish;if(typeof a!="function")return;D(this,Zt,o);let u=this.closest(".main-search__search-bar-wrap")?"search-page":"header";Promise.resolve(a.call(window.Shopify.analytics,"sonance:predictive_search",{query:s,status:i,suggestionCount:r,source:u})).catch(()=>{})},Oi=new WeakSet,Nn=function(){let e=document.createElement("li"),i=document.createElement("span"),r=document.createElement("span");e.className="theme-search-bar__loading",i.className="theme-search-bar__loading-spinner",i.setAttribute("aria-hidden","true"),r.textContent="Searching\u2026",e.append(i,r),l(this,we).replaceChildren(e),l(this,Le).hidden=!0,l(this,le).hidden=!1,l(this,j).setAttribute("aria-expanded","true"),C(this,He,Jt).call(this,"Loading suggestions")},Fi=new WeakSet,$n=function(e){let i=e.image||e.featured_image||e.featured_media?.preview_image;return typeof i=="string"?i:i?.url||i?.src||""},Ie=new WeakSet,gt=function(){!l(this,le)||(l(this,le).hidden=!0,l(this,j).setAttribute("aria-expanded","false"))},He=new WeakSet,Jt=function(e){l(this,Et)&&(l(this,Et).textContent=e)},Vi=new WeakSet,Bn=function(e){let i=Array.from(this.querySelectorAll(".theme-search-bar__suggestion-link"));if(e.key==="Escape"){C(this,Ie,gt).call(this),l(this,j).focus();return}if(l(this,le).hidden||!i.length)return;let r=i.indexOf(document.activeElement);e.key==="ArrowDown"?(e.preventDefault(),i[r<i.length-1?r+1:0].focus()):e.key==="ArrowUp"&&(e.preventDefault(),r<=0?l(this,j).focus():i[r-1].focus())},Ri=new WeakSet,qn=function(e){switch(e.preventDefault(),l(this,St)){case"video":if(l(this,j).value&&l(this,j).value!==""){let i=new URL(window.location.href),r=i.searchParams.get("other_filter")?.split(",")||[],s=l(this,j).value.split(",").map(a=>a.toLowerCase().trim().replaceAll(" ","")),o=[...r,...s].join(",");i.searchParams.set("other_filter",o),i.hash="#library",window.location.href=i.href}break;default:if(l(this,j).value&&l(this,j).value.trim()!==""){let i=new URL("/search",window.location.origin);i.searchParams.set("q",l(this,j).value.trim()),i.searchParams.set("options[prefix]","last"),i.searchParams.set("options[unavailable_products]","show"),window.location.href=`${i.pathname}${i.search}`}break}},customElements.define("theme-search-bar",Tr);var zi=n=>n.replace(/[\W_]+/g," ").trim().replaceAll(" ","-").toLowerCase(),ce,je,ie,pe,
85Ue,De,_e,ye,ue,si,Br,We,ni,Hi,On,ji,Fn,oi,qr,Ui,Vn,ai,Or,$r=class extends HTMLElement{constructor(){super(),S(this,si),S(this,We),S(this,Hi),S(this,ji),S(this,oi),S(this,Ui),S(this,ai),S(this,ce,"ThemeCompareModels"),S(this,je,void 0),S(this,ie,void 0),S(this,pe,void 0),S(this,Ue,void 0),S(this,De,void 0),S(this,_e,[]),S(this,ye,void 0),S(this,ue,void 0),h.info(`${l(this,ce)} > constructor`),D(this,ie,this.querySelector("form#models-form")),D(this,Ue,this.querySelector("#compare-container")),D(this,pe,this.querySelector("form#compare-grid-form")),D(this,De,new URLSearchParams(window.location.search))}connectedCallback(){h.info(`${l(this,ce)} > connectedCallback`),D(this,je,new AbortController);let{signal:e}=l(this,je);l(this,ie).addEventListener("change",i=>C(this,si,Br).call(this,l(this,ie),i),{signal:e}),l(this,ie).addEventListener("click",i=>C(this,Ui,Vn).call(this,i),{signal:e}),l(this,pe).addEventListener("change",i=>C(this,si,Br).call(this,l(this,pe),i),{signal:e}),this.querySelectorAll(".theme-compare-models__container__grid__image-wrap__hover").forEach(i=>{i.addEventListener("mouseover",()=>{l(this,ye)&&(clearTimeout(l(this,ye)),D(this,ye,null))},{signal:e})}),window.addEventListener("resize",()=>C(this,We,ni).call(this,!0),{signal:e}),window.addEventListener("hashchange",()=>C(this,ai,Or).call(this),{signal:e})}disconnectedCallback(){l(this,je).abort(),D(this,je,null),l(this,ue)&&(clearTimeout(l(this,ue)),D(this,ue,null))}static get observedAttributes(){return["data-json"]}attributeChangedCallback(e,i,r){h.info(`${l(this,ce)} > attributeChangedCallback > name: ${e}`),e==="data-json"&&(D(this,_e,JSON.parse(r)),h.info(`${l(this,ce)} > #data >`,l(this,_e)),C(this,We,ni).call(this,!0),C(this,ai,Or).call(this))}};ce=new WeakMap,je=new WeakMap,ie=new WeakMap,pe=new WeakMap,Ue=new WeakMap,De=new WeakMap,_e=new WeakMap,ye=new WeakMap,ue=new WeakMap,si=new WeakSet,Br=function(e,i){h.info(`${l(this,ce)} > #onFormChange`);let r=Array.from(new FormData(e).keys());l(this,De).set("checked",r.join(",")),C(this,We,ni).call(this),e===l(this,ie)&&C(this,ji,Fn).call(this,i),!r.length&&e===l(this,pe)?l(this,ie).scrollIntoView({behavior:"smooth",block:"start"}):r.length&&e===l(this,ie)&&(l(this,ye)&&(clearTimeout(l(this,ye)),D(this,ye,null)),D(this,ye,setTimeout(()=>{l(this,Ue).scrollIntoView({behavior:"smooth",block:"start"})},2500)))},We=new WeakSet,ni=function(e=!1){let i={};for(let[o,a]of l(this,De).entries())i[o]=a;let r=l(this,De).toString(),s=`${window.location.pathname}${r?`?${r}`:""}${window.location.hash}`;e?history.replaceState(i,"",s):history.pushState(i,"",s),C(this,Hi,On).call(this,i)},Hi=new WeakSet,On=function(e){h.info(`${l(this,ce)} > #onStateChange`,e);let i=e.checked?.split(",").filter(d=>d!="")||[],r="";[...Array.from(l(this,ie).querySelectorAll("input")),...Array.from(l(this,pe).querySelectorAll("input"))].forEach(d=>{d.checked=i.includes(d.name)});let s=window.innerWidth,o=l(this,_e).filter(d=>i.includes(d.id));l(this,Ue).dataset.show=o.length?"true":"false";let a=`${s<720?"":"blank-top-legend "}${o.map(d=>`head-${d.id}`).join(" ")}`,u=`${s<720?"":"blank-bottom-legend "}${o.map(d=>`label-${d.id}`).join(" ")}`,c=o[0]?.features.length||0;r=r.concat(`"${a}"`);for(let d=0;d<c;d++){let A=zi(o[0].features[d].feature),f=`${s<720?"":`${A}-legend `}${o.map(p=>`${A}-${p.id}`).join(" ")}`;r=r.concat(` "${f}"`)}r=r.concat(` "${u}"`),l(this,pe).style.gridTemplateAreas=r,Array.from(l(this,pe).children).forEach(d=>{d.dataset.legend||(d.dataset.show=i.includes(d.dataset.id))})},ji=new WeakSet,Fn=function(e){let i=e?.target;if(!(i instanceof HTMLInputElement)||i.type!=="checkbox"||!i.checked)return;try{if(window.localStorage.getItem(C(this,oi,qr).call(this)))return}catch(o){h.info(`${l(this,ce)} > #maybeShowCompareTip > localStorage unavailable`,o)}let r=i.closest("label");if(!r)return;let s=r.querySelector("[data-compare-tip]");s||(s=document.createElement("span"),s.className="theme-compare-models__compare-tip",s.dataset.compareTip="true",s.textContent="Scroll down to compare models",r.appendChild(s)),l(this,ue)&&(clearTimeout(l(this,ue)),D(this,ue,null)),s.dataset.show="true";try{window.localStorage.setItem(C(this,oi,qr).call(this),"true")}catch(o){h.info(`${l(this,ce)} > #maybeShowCompareTip > could not persist state`,o)}
85D(this,ue,setTimeout(()=>{s.dataset.show="false",D(this,ue,null)},2e3))},oi=new WeakSet,qr=function(){return`theme-compare-models-tip-seen:${window.location.pathname}`},Ui=new WeakSet,Vn=function(e){let i=e.target.closest(".theme-compare-models__container__grid__image-wrap[href]");if(!(!i||!l(this,ie).contains(i))&&!e.defaultPrevented){if(e.metaKey||e.ctrlKey){window.open(i.href,"_blank","noopener"),e.preventDefault();return}e.shiftKey||e.altKey||e.button!==0||(e.preventDefault(),window.location.assign(i.href))}},ai=new WeakSet,Or=function(){if(!this.id||window.location.hash!==`#${this.id}`||!l(this,_e).length)return;let e=l(this,_e).map(i=>i.id).join(",");l(this,De).set("checked",e),C(this,We,ni).call(this,!0),requestAnimationFrame(()=>{l(this,Ue).scrollIntoView({behavior:"smooth",block:"start"})}),history.replaceState(history.state,"",window.location.pathname+window.location.search)},customElements.define("theme-compare-models",$r);var Ke=(n="")=>String(n).split("||").map(t=>t.trim()).filter(Boolean),Fr=(n="")=>zi(String(n||"").trim()),Rn=({collections:n=[],statuses:t=[],features:e=[]}={})=>{let i=new Map,r=new Map,s=new Map;return n.forEach(o=>{let a=String(o||"").trim(),u=Fr(a);a&&u&&!i.has(u)&&i.set(u,a)}),t.forEach(o=>{let a=String(o||"").trim(),u=Fr(a);a&&u&&!r.has(u)&&r.set(u,a)}),e.forEach(o=>{let a=String(o||"").trim(),u=Fr(a);a&&u&&!s.has(u)&&s.set(u,a)}),{series:Array.from(i.entries()).map(([o,a])=>({value:o,label:a})),statuses:Array.from(r.entries()).map(([o,a])=>({value:o,label:a})),features:Array.from(s.entries()).map(([o,a])=>({value:o,label:a}))}},zn=(n=[])=>{let t=new Map,e=new Map,i=new Map;n.forEach(s=>{(s.series||[]).forEach(o=>{o.value&&o.label&&!t.has(o.value)&&t.set(o.value,o.label)}),(s.statuses||[]).forEach(o=>{o.value&&o.label&&!e.has(o.value)&&e.set(o.value,o.label)}),(s.features||[]).forEach(o=>{o.value&&o.label&&!i.has(o.value)&&i.set(o.value,o.label)})});let r=s=>Array.from(s.entries()).sort((o,a)=>o[1].localeCompare(a[1]));return{series:r(t),statuses:r(e),features:r(i)}},Wi=(n,t,e,i="")=>{if(!n)return;let r=String(i||""),s=e.map(([o,a])=>`<option value="${o}"${o===r?" selected":""}>${a}</option>`).join("");n.innerHTML=`<option value="">${t}</option>${s}`},li,Ge,Se,Ye,Ct,Mt,Xe,re,ne,se,oe,Ki,Hn,Gi,jn,Yi,Un,Ne,Pt,de,Ae,Vr=class extends HTMLElement{constructor(){super(),S(this,Ki),S(this,Gi),S(this,Yi),S(this,Ne),S(this,de),S(this,li,"ThemeProductGrid"),S(this,Ge,void 0),S(this,Se,void 0),S(this,Ye,[]),S(this,Ct,[]),S(this,Mt,void 0),S(this,Xe,void 0),S(this,re,void 0),S(this,ne,void 0),S(this,se,void 0),S(this,oe,void 0),h.info(`${l(this,li)} > constructor`),D(this,Se,this.querySelector("[data-filter-root]")),D(this,Ct,Array.from(this.querySelectorAll("[data-filter-status]"))),D(this,Mt,this.querySelector("[data-product-filters-empty]")),D(this,Xe,this.querySelector("[data-filter-reset]")),D(this,oe,this.querySelector("[data-filter-form]")),D(this,re,this.querySelector('[data-filter-control="series"]')),D(this,ne,this.querySelector('[data-filter-control="status"]')),D(this,se,this.querySelector('[data-filter-control="features"]'))}connectedCallback(){h.info(`${l(this,li)} > connectedCallback`),D(this,Ge,new AbortController);let{signal:e}=l(this,Ge);C(this,Ki,Hn).call(this,e),C(this,Yi,Un).call(this,e),C(this,Gi,jn).call(this,e)}disconnectedCallback(){l(this,Ge)?.abort(),D(this,Ge,null)}};li=new WeakMap,Ge=new WeakMap,Se=new WeakMap,Ye=new WeakMap,Ct=new WeakMap,Mt=new WeakMap,Xe=new WeakMap,re=new WeakMap,ne=new WeakMap,se=new WeakMap,oe=new WeakMap,Ki=new WeakSet,Hn=function(e){let i=this.querySelector("[data-filter-toggle]"),r=this.querySelector("[data-filter-panel]");!i||!r||i.addEventListener("click",()=>{let s=r.dataset.open==="true";r.dataset.open=s?"false":"true",i.setAttribute("aria-expanded",s?"false":"true")},{signal:e})},Gi=new WeakSet,jn=function(e){if(!l(this,Se))return;if(!l(this,re)&&!l(this,ne)&&!l(this,se)){C(this,de,Ae).call(this);return}D(this,Ye,Array.from(this.querySelectorAll("[data-product-filter-item]")).map(u=>{let c=Rn({collections:Ke(u.dataset.collections),statuses:Ke(u.dataset.statuses),features:Ke(u.dataset.features)});
85return u.dataset.filterSeries=c.series.map(d=>d.value).join("||"),u.dataset.filterStatuses=c.statuses.map(d=>d.value).join("||"),u.dataset.filterFeatures=c.features.map(d=>d.value).join("||"),{element:u,series:c.series,statuses:c.statuses,features:c.features}}));let i=zn(l(this,Ye)),r=i.series.length>1,s=i.statuses.length>1,o=i.features.length>1;if(!(r||s||o)){l(this,Se).hidden=!0;return}l(this,re)&&(l(this,re).closest(".theme-product-filters__field")?.toggleAttribute("hidden",!r),Wi(l(this,re),"All",i.series),l(this,re).addEventListener("change",()=>{C(this,de,Ae).call(this),C(this,Ne,Pt).call(this)},{signal:e})),l(this,ne)&&(l(this,ne).closest(".theme-product-filters__field")?.toggleAttribute("hidden",!s),Wi(l(this,ne),"All",i.statuses),l(this,ne).addEventListener("change",()=>{C(this,de,Ae).call(this),C(this,Ne,Pt).call(this)},{signal:e})),l(this,se)&&(l(this,se).closest(".theme-product-filters__field")?.toggleAttribute("hidden",!o),Wi(l(this,se),"All",i.features),l(this,se).addEventListener("change",()=>{C(this,de,Ae).call(this),C(this,Ne,Pt).call(this)},{signal:e})),l(this,Xe)?.addEventListener("click",()=>{l(this,re)&&(l(this,re).value=""),l(this,ne)&&(l(this,ne).value=""),l(this,se)&&(l(this,se).value=""),C(this,de,Ae).call(this),C(this,Ne,Pt).call(this)},{signal:e}),C(this,de,Ae).call(this),C(this,Ne,Pt).call(this)},Yi=new WeakSet,Un=function(e){if(!l(this,oe))return;C(this,de,Ae).call(this);let i=l(this,Ct),r=i[0]?.textContent?.trim()||"";l(this,oe).hasAttribute("data-loading-status")&&l(this,oe).addEventListener("submit",()=>{l(this,oe).dataset.loading="true",l(this,oe).setAttribute("aria-busy","true"),i.forEach(s=>{s.textContent="Updating..."})},{signal:e}),l(this,oe).querySelectorAll("select").forEach(s=>
85{s.dataset.filterControl||s.addEventListener("change",()=>{C(this,de,Ae).call(this),l(this,oe).hasAttribute("data-loading-status")&&(i.forEach(o=>{o.textContent=r}),l(this,oe).requestSubmit())},{signal:e})})},Ne=new WeakSet,Pt=function(){if(!l(this,Se)||!l(this,Ye).length)return;let e=l(this,re)?.value||"",i=l(this,ne)?.value||"",r=l(this,se)?.value||"",s=0;l(this,Ye).forEach(a=>{let u=a.element,c=u.closest(".theme-compare-models__container__grid__item")||u,d=Ke(u.dataset.filterSeries),A=Ke(u.dataset.filterStatuses),f=Ke(u.dataset.filterFeatures),p=!e||d.includes(e),m=!i||A.includes(i),x=!r||f.includes(r),L=p&&m&&x;c.hidden=!L,c.style.display=L?"":"none",L&&(s+=1)});let o=!!(e||i||r);l(this,Xe)&&(l(this,Xe).hidden=!o),l(this,Mt)&&(l(this,Mt).hidden=s>0),l(this,Ct).forEach(a=>{a.textContent=`Showing ${s} product${s===1?"":"s"}`})},de=new WeakSet,Ae=function(){if(!l(this,Se))return;let i=document.createElement("canvas").getContext("2d");!i||l(this,Se).querySelectorAll("select").forEach(r=>{let o=r.options[r.selectedIndex]?.textContent?.trim()||"",a=window.getComputedStyle(r);i.font=`${a.fontWeight} ${a.fontSize} ${a.fontFamily}`;let u=i.measureText(o).width;r.style.width=`${Math.ceil(u+18)}px`})},customElements.define("theme-product-grid",Vr);var yo="__filtering__";function Rr(n){return`${yo}${n}`}function Wn(n){if(n==null)return null;if(typeof n=="boolean")return n?"Yes":"No";if(Array.isArray(n)){let e=n.flatMap(i=>{let r=Wn(i);return Array.isArray(r)?r:[r]}).filter(i=>typeof i=="string"&&i.length>0);return e.length?[...new Set(e)]:null}if(typeof n=="number")return Number.isFinite(n)?String(n):null;if(typeof n!="string")return null;let t=n.split(";").map(e=>e.trim().replace(/\s+/g," ")).filter(Boolean);return t.length===0?null:t.length===1?t[0]:[...new Set(t)]}function Kn(n){let t={};if(!n||typeof n!="object"||Array.isArray(n))return t;for(let[e,i]of Object.entries(n)){let r=e.trim();if(!r)continue;let s=Wn(i);s!=null&&(t[Rr(r)]=s)}return t}var zr="ProductSpecGrid",vo=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"}),Lt={product_type:"__shopify_product_type__",vendor:"__shopify_vendor__",tag:"__shopify_tag__",category:"__shopify_category__"},go={product_type:"Type",vendor:"Vendor",tag:"Tag",category:"Category"},bo="__metafield__";function Xn(n,t){return`${bo}${n}.${t}`}function wo(n){return n.replace(/[_-]+/g," ").replace(/\b\w/g,t=>t.toUpperCase()).trim()}function Ce(n){if(n==null||n==="")return null;if(typeof n=="boolean")return n?String(n):null;if(typeof n=="number")return Number.isFinite(n)?String(n):null;if(typeof n=="string"){let t=n.trim().replace(/\s+/g," ");return t===""?null:t}try{return JSON.stringify(n)}catch{return null}}function Eo(n){let t={};if(!n||typeof n!="object"||Array.isArray(n))return t;for(let[e,i]of Object.entries(n)){let r=e.trim();if(!r)continue;let s=Ce(i);s!=null&&(t[r]=s)}return t}function Jn(n){if(n==null)return null;if(Array.isArray(n)){let t=[];for(let e of n){let i=Jn(e);typeof i=="string"?t.push(i):Array.isArray(i)&&t.push(...i)}return t.length?t:null}return typeof n=="object"?typeof n.title=="string"?Ce(n.title):typeof n.name=="string"?Ce(n.name):typeof n.value=="string"?Ce(n.value):typeof n.handle=="string"?Ce(n.handle):null:Ce(n)}function Gn(n){let t={...Eo(n?.specs),...Kn(n?.filtering)},e=Ce(n?.productType);e&&(t[Lt.product_type]=e);let i=Ce(n?.vendor);if(i&&(t[Lt.vendor]=i),Array.isArray(n?.tags)){let r=n.tags.map(s=>Ce(s)).filter(s=>typeof s=="string"&&s.length>0);if(r.length){t[Lt.tag]=r;let s=r.filter(o=>o.toLowerCase().startsWith("category:")).map(o=>o.slice(9).trim()).filter(o=>o.length>0);s.length&&(t[Lt.category]=s)}}if(n?.metafields&&typeof n.metafields=="object"&&!Array.isArray(n.metafields))for(let[r,s]of Object.entries(n.metafields)){let o=Jn(s);if(o==null)continue;
85let[a,...u]=r.split("."),c=u.join(".");!a||!c||(t[Xn(a,c)]=o)}return t}function Yn(n,t,e){for(let[i,r]of t){if(e&&i===e||!r||r.size===0)continue;let s=n[i];if(s==null)return!1;if(Array.isArray(s)){if(!s.some(a=>r.has(a)))return!1}else if(!r.has(s))return!1}return!0}var Je,he,ci,ke,Pe,$e,Tt,ui,di,Ji,Qn,Qi,Zn,Zi,es,Be,xt,er,ts,hi,jr,tr,is,It,Xi,Ur=class extends HTMLElement{constructor(){super(...arguments),S(this,Ji),S(this,Qi),S(this,Zi),S(this,Be),S(this,er),S(this,hi),S(this,tr),S(this,It),S(this,Je,void 0),S(this,he,[]),S(this,ci,new Map),S(this,ke,new Map),S(this,Pe,[]),S(this,$e,null),S(this,Tt,{facetBlocks:[]}),S(this,ui,()=>{}),S(this,di,()=>{})}connectedCallback(){h.info(`${zr} connected`);let e=this.querySelector("[data-product-spec-grid-json]"),i=this.querySelector("[data-product-spec-grid-config]");try{let u=e?.textContent?.trim()||"[]";D(this,he,JSON.parse(u)),Array.isArray(l(this,he))||D(this,he,[])}catch(u){h.error(`${zr} product JSON parse failed`,u),D(this,he,[])}try{let u=i?.textContent?.trim()?JSON.parse(i.textContent.trim()):{},c=[];if(Array.isArray(u.facetBlocks))for(let d of u.facetBlocks){if(!d||typeof d!="object")continue;let A=typeof d.label=="string"&&d.label.trim()!==""?d.label.trim():null,f=d.collapsedDefault===!0;if(d.kind==="shopify"){let m=typeof d.field=="string"?d.field.trim():"";if(!Object.prototype.hasOwnProperty.call(Lt,m))continue;c.push({kind:"shopify",field:m,label:A,collapsedDefault:f});continue}if(d.kind==="metafield"){let m=typeof d.namespace=="string"?d.namespace.trim():"",x=typeof d.key=="string"?d.key.trim():"";if(!m||!x)continue;c.push({kind:"metafield",namespace:m,key:x,label:A,collapsedDefault:f});continue}if(d.kind==="filtering"){let m=typeof d.filterKey=="string"?d.filterKey.trim():"";if(!m)continue;c.push({kind:"filtering",filterKey:m,label:A,collapsedDefault:f});continue}let p=typeof d.specKey=="string"?d.specKey.trim():"";!p||c.push({kind:"spec",specKey:p,label:A,collapsedDefault:f})}D(this,Tt,{facetBlocks:c})}catch{D(this,Tt,{facetBlocks:[]})}this.querySelectorAll("[data-product-id]").forEach(u=>{let c=Number.parseInt(u.getAttribute("data-product-id"),10);Number.isFinite(c)&&l(this,ci).set(c,u)}),D(this,Pe,Ur.buildFacetModel({products:l(this,he).filter(u=>u&&typeof u.id=="number"),facetBlocks:l(this,Tt).facetBlocks})),D(this,Je,new AbortController);let{signal:s}=l(this,Je);D(this,$e,this.querySelector("[data-spec-filter-mount]")),l(this,$e)instanceof HTMLElement&&l(this,Pe).length>0&&C(this,Ji,Qn).call(this,s),C(this,Qi,Zn).call(this,s),C(this,tr,is).call(this,s);let o=this.querySelector(".product-spec-grid__sidebar"),a=this.querySelector("[data-filter-toggle]");l(this,Pe).length===0?(o instanceof HTMLElement&&(o.hidden=!0),a instanceof HTMLElement&&(a.hidden=!0),this.classList.add("product-spec-grid--no-filters")):(o instanceof HTMLElement&&(o.hidden=!1),a instanceof HTMLElement&&(a.hidden=!1),this.classList.remove("product-spec-grid--no-filters")),C(this,It,Xi).call(this),h.info(`${zr} facets ${l(this,Pe).length}`)}disconnectedCallback(){l(this,Je)?.abort(),D(this,Je,null),l(this,ke).clear(),C(this,hi,jr).call(this)}static buildFacetModel({products:e,facetBlocks:i}){let r=new Map;for(let a of e){let u=Gn(a);for(let[c,d]of Object.entries(u)){r.has(c)||r.set(c,new Set);let A=r.get(c);Array.isArray(d)?d.forEach(f=>A.add(f)):A.add(d)}}let s=[],o=new Set;for(let a of i){let u,c;if(a.kind==="shopify"?(u=Lt[a.field],c=go[a.field]||a.field):a.kind==="metafield"?(u=Xn(a.namespace,a.key),c=wo(a.key)):a.kind==="filtering"?(u=Rr(a.filterKey),c=a.filterKey):(u=a.specKey,c=a.specKey),!u||o.has(u)||!r.has(u))continue;o.add(u);let d=a.label&&a.label.trim()!==""?a.label.trim():c;s.push({facetKey:u,label:d,collapsedDefault:a.collapsedDefault===!0})}return s.map(({facetKey:a,label:u,collapsedDefault:c})=>({facetKey:a,label:u,collapsedDefault:c,values:[...r.get(a)||[]].sort((d,A)=>vo.compare(d,A)).map(d=>({canonical:d,label:d}))}))}},Hr=Ur;Je=new WeakMap,he=new WeakMap,ci=new WeakMap,ke=new WeakMap,Pe=new WeakMap,$e=new WeakMap,Tt=new WeakMap,ui=new WeakMap,di=new WeakMap,Ji=new WeakSet,Qn=function(e){let i=l(this,$e),r=l(this,Pe),s=l(this,ke);if(!i||!r.length)return;i.textContent="";let o=`${this.dataset.sectionId||"psg"}-facet-`;r.forEach((a,u)=>{let c=document.createElement("details");c.className="product-spec-grid__facet",c.dataset.facetGroup=a.facetKey,c.open=!a.collapsedDefault;let d=document.createElement("summary");d.className="product-spec-grid__facet-summary";let A=document.createElement("span");A.className="product-spec-grid__facet-legend",A.textContent=a.label,d.append(A);let f=document.createElement("div");f.className="product-spec-grid__facet-body",c.append(d,f),a.values.forEac
85h(({canonical:p},m)=>{let x=`${o}-${u}-${m}`,L=document.createElement("label");L.className="product-spec-grid__facet-label",L.htmlFor=x;let T=document.createElement("input");T.type="checkbox",T.id=x,T.value=p,T.dataset.facetKey=a.facetKey,T.dataset.facetValue=p;let w=document.createElement("span");w.className="product-spec-grid__facet-value",w.textContent=p;let b=document.createElement("span");b.className="product-spec-grid__facet-count",b.dataset.facetCount="",b.textContent="0",L.append(T,w,b),f.append(L),T.addEventListener("change",()=>{let M=s.get(a.facetKey);M||(M=new Set,s.set(a.facetKey,M)),T.checked?M.add(p):M.delete(p),M.size===0?s.delete(a.facetKey):s.set(a.facetKey,M),C(this,It,Xi).call(this)},{signal:e})}),i.append(c)})},Qi=new WeakSet,Zn=function(e){let i=this.querySelector("[data-filter-toggle]"),r=this.querySelector("[data-filter-backdrop]"),s=this.querySelectorAll("[data-filter-close]"),o=this.querySelector("[data-filter-root]");!i||!o||(i.addEventListener("click",()=>{this.classList.contains("product-spec-grid--drawer-open")?C(this,Be,xt).call(this):C(this,Zi,es).call(this)},{signal:e}),s.forEach(a=>{a.addEventListener("click",()=>C(this,Be,xt).call(this),{signal:e})}),r?.addEventListener("click",()=>C(this,Be,xt).call(this),{signal:e}),D(this,ui,a=>{a.key==="Escape"&&this.classList.contains("product-spec-grid--drawer-open")&&C(this,Be,xt).call(this)}),document.addEventListener("keydown",l(this,ui),{signal:e}),D(this,di,()=>{window.innerWidth>=1024&&this.classList.contains("product-spec-grid--drawer-open")&&C(this,Be,xt).call(this)}),window.addEventListener("resize",l(this,di),{signal:e}))},Zi=new WeakSet,es=function(){this.classList.add("product-spec-grid--drawer-open");let e=this.querySelector("[data-filter-toggle]"),i=this.querySelector("[data-filter-backdrop]"),r=this.querySelector("[data-filter-root]");e&&e.setAttribute("aria-expanded","true"),i instanceof HTMLElement&&(i.hidden=!1),r instanceof HTMLElement&&r.setAttribute("aria-modal","true"),C(this,er,ts).call(this)},Be=new WeakSet,xt=function(){this.classList.remove("product-spec-grid--drawer-open");let e=this.querySelector("[data-filter-toggle]"),i=this.querySelector("[data-filter-backdrop]"),r=this.querySelector("[data-filter-root]");e&&e.setAttribute("aria-expanded","false"),i instanceof HTMLElement&&(i.hidden=!0),r instanceof HTMLElement&&r.setAttribute("aria-modal","false"),C(this,hi,jr).call(this)},er=new WeakSet,ts=function(){window.innerWidth>=1024||(document.documentElement.classList.add("product-spec-grid-drawer-lock"),document.body.classList.add("product-spec-grid-drawer-lock"))},hi=new WeakSet,jr=function(){document.documentElement.classList.remove("product-spec-grid-drawer-lock"),document.body.classList.remove("product-spec-grid-drawer-lock")},tr=new WeakSet,is=function(e){this.querySelectorAll("[data-filter-reset]").forEach(r=>{r.addEventListener("click",()=>{l(this,ke).clear(),l(this,$e)?.querySelectorAll('input[type="checkbox"]').forEach(s=>{s.checked=!1}),C(this,It,Xi).call(this)},{signal:e})})},It=new WeakSet,Xi=function(){let e=this.querySelector("[data-filter-results]"),i=this.querySelector("[data-filter-active-summary]"),r=this.querySelector("[data-filter-mobile-count]"),s=this.querySelector("[data-filter-apply-label]"),o=this.querySelector("[data-product-filters-empty]"),a={};l(this,he).forEach(p=>{typeof p.id=="number"&&(a[p.id]=Gn(p))});let u=0;for(let p of l(this,he)){let m=a[p.id]||{},x=Yn(m,l(this,ke),null),L=l(this,ci).get(p.id);L&&(L.hidden=!x,L.style.display=x?"":"none"),x&&(u+=1)}if(e instanceof HTMLElement){let p=e.querySelector(".product-spec-grid__results-count"),m=e.querySelector(".product-spec-grid__results-label");p instanceof HTMLElement&&(p.textContent=String(u)),m instanceof HTMLElement&&(m.textContent=u===1?"result":"results")}s instanceof HTMLElement&&(s.textContent=`Show ${u} ${u===1?"result":"results"}`);let c=0;if(l(this,ke).forEach(p=>{c+=p.size}),i instanceof HTMLElement)if(c===0)i.textContent="",i.hidden=!0;else{i.hidden=!1;let p=c===1?"filter":"filters";i.textContent=`${c} ${p} active`}r instanceof HTMLElement&&(c===0?(r.textContent="",r.hidden=!0):(r.hidden=!1,r.textContent=String(c)));let d=c>0;this.querySelectorAll("[data-filter-reset]").forEach(p=>{p.disabled=!d,p.setAttribute("aria-disabled",d?"false":"true"),p.hasAttribute("data-filter-reset-persistent")||(p.hidden=!d)}),o instanceof HTMLElement&&(o.hidden=u>0);let f=l(this,$e);l(this,Pe).forEach(p=>{let m=p.facetKey;
85p.values.forEach(({canonical:x})=>{if(!f)return;let L=[...f.querySelectorAll('input[type="checkbox"][data-facet-key]')].find(I=>{let N=I;return N.dataset.facetKey===p.facetKey&&N.dataset.facetValue===x})||null,w=L?.closest(".product-spec-grid__facet-label")?.querySelector("[data-facet-count]");if(!L||!w)return;let b=0;l(this,he).forEach(I=>{let N=a[I.id]||{};if(!Yn(N,l(this,ke),m))return;let q=N[p.facetKey];q!=null&&(Array.isArray(q)?q.includes(x)&&(b+=1):q===x&&(b+=1))}),w.textContent=String(b),L.disabled=b===0&&!L.checked;let M=L.closest(".product-spec-grid__facet-label");M instanceof HTMLElement&&(M.dataset.disabled=L.disabled?"true":"false")})})},customElements.define("product-spec-grid",Hr);var Qe,Ze,Dt,pi,_t,et,ir,rs,rr,ns,yi,Kr,tt,fi,vi,Gr,nr,ss,sr,os,or,as,ar,ls,lr,cs,cr,us,ur,ds,dr,hs,hr,fs,gi,Yr,fr,ms,mi=class extends HTMLElement{constructor(){super(),S(this,ir),S(this,rr),S(this,yi),S(this,tt),S(this,vi),S(this,nr),S(this,sr),S(this,or),S(this,ar),S(this,lr),S(this,cr),S(this,ur),S(this,dr),S(this,hr),S(this,gi),S(this,fr),S(this,Qe,void 0),S(this,Ze,void 0),S(this,Dt,void 0),S(this,pi,void 0),S(this,_t,void 0),S(this,et,void 0)}connectedCallback(){D(this,Qe,new AbortController);let{signal:e}=l(this,Qe);this.addEventListener("click",async()=>{if(this.dataset.downloading==="true")return;if(l(this,_t)?.length){try{C(this,yi,Kr).call(this,!0),await C(this,ir,rs).call(this),C(this,tt,fi).call(this,"Download Ready"),setTimeout(()=>C(this,vi,Gr).call(this),1600)}catch{C(this,tt,fi).call(this,"Download Failed"),setTimeout(()=>C(this,vi,Gr).call(this),2200)}finally{C(this,yi,Kr).call(this,!1)}return}let i=l(this,pi)||[];i.length?i.forEach(r=>{C(this,gi,Yr).call(this,r.url,r.name)}):l(this,Ze)&&C(this,gi,Yr).call(this,l(this,Ze),l(this,Dt)||"file")},{signal:e})}disconnectedCallback(){l(this,Qe).abort(),D(this,Qe,null)}static get observedAttributes(){return["href","file-name","files","zip-groups"]}attributeChangedCallback(e,i,r){e==="href"&&r&&D(this,Ze,r),e==="file-name"&&r&&D(this,Dt,r),e==="files"&&r&&D(this,pi,JSON.parse(r)),e==="zip-groups"&&D(this,_t,r?JSON.parse(r):null)}},Wr=mi;Qe=new WeakMap,Ze=new WeakMap,Dt=new WeakMap,pi=new WeakMap,_t=new WeakMap,et=new WeakMap,ir=new WeakSet,rs=async function(){for(let e of l(this,_t)){let i=e.files||[],r=await C(this,rr,ns).call(this,i);if(!r.length)continue;C(this,tt,fi).call(this,"Zipping Files");let s=await C(this,nr,ss).call(this,r);C(this,hr,fs).call(this,s,e.fileName||"downloads.zip")}},rr=new WeakSet,ns=async function(e){let i=[];for(let[r,s]of e.entries())try{C(this,tt,fi).call(this,"Preparing");let o=await fetch(s.url);if(!o.ok)continue;let a=await o.blob();i.push({name:s.name,blob:a})}catch{}return i},yi=new WeakSet,Kr=function(e){this.dataset.downloading=e?"true":"false",this.toggleAttribute("aria-busy",e)},tt=new WeakSet,fi=function(e){l(this,et)||D(this,et,this.innerHTML);let i=this.querySelector(".elementor-button-text");if(i){i.textContent=e;return}this.textContent=e},vi=new WeakSet,Gr=function(){l(this,et)&&(this.innerHTML=l(this,et))},nr=new WeakSet,ss=async function(e){let i=new TextEncoder,r=[],s=[],o=0;for(let c of e){let d=C(this,sr,os).call(this,c.name),A=i.encode(d),f=new Uint8Array(await c.blob.arrayBuffer()),p=C(this,ur,ds).call(this,f),m=C(this,or,as).call(this,A,f.length,p);r.push(m,A,f),s.push(C(this,ar,ls).call(this,A,f.length,p,o)),o+=m.length+A.length+f.length}let a=s.reduce((c,d)=>c+d.length,0),u=C(this,lr,cs).call(this,s.length,a,o);return new Blob([...r,...s,u],{type:"application/zip"})},sr=new WeakSet,os=function(e){return e.replace(/[\\/:*?"<>|]/g,"-")},or=new WeakSet,as=function(e,i,r){let s=new DataView(new ArrayBuffer(30));return s.setUint32(0,67324752,!0),s.setUint16(4,20,!0),s.setUint16(6,0,!0),s.setUint16(8,0,!0),s.setUint16(10,0,!0),s.setUint16(12,0,!0),s.setUint32(14,r,!0),s.setUint32(18,i,!0),s.setUint32(22,i,!0),s.setUint16(26,e.length,!0),s.setUint16(28,0,!0),new Uint8Array(s.buffer)},ar=new WeakSet,ls=function(e,i,r,s){let o=new DataView(new ArrayBuffer(46));return o.setUint32(0,33639248,!0),o.setUint16(4,20,!0),o.setUint16(6,20,!0),o.setUint16(8,0,!0),o.setUint16(10,0,!0),o.setUint16(12,0,!0),o.setUint16(14,0,!0),o.setUint32(16,r,!0),o.setUint32(20,i,!0),o.setUint32(24,i,!0),o.setUint16(28,e.length,!0),o.setUint16(30,0,!0),o.setUint16(32,0,!0),o.setUint16(34,0,!0),o.setUint16(36,0,!0),o.setUint32(38,0,!0),o.setUint32(42,s,!0),C(this,cr,us).call(this,new Uint8Array(o.buffer),e)},lr=new WeakSet,cs=function(e,i,r){let s=new DataView(new ArrayBuffer(22));return s.setUint32(0,101010256,!0),s.setUint16(4,0,!0),s.setUint16(6,0,!0),s.setUint16(8,e,!0),s.setUint16(10,e,!0),s.setUint32(12,i,!0),s.setUint32(16,r,!0),s.setUint16(20,0,!0),new Uint8Array(s.buffer)},cr=new WeakSet,us=function(...e){let i=e.reduce((o,a)=>
85o+a.length,0),r=new Uint8Array(i),s=0;return e.forEach(o=>{r.set(o,s),s+=o.length}),r},ur=new WeakSet,ds=function(e){let i=-1;for(let r=0;r<e.length;r+=1)i=i>>>8^l(this,dr,hs)[(i^e[r])&255];return(i^-1)>>>0},dr=new WeakSet,hs=function(){if(!mi.crcTable){let e=new Uint32Array(256);for(let i=0;i<256;i+=1){let r=i;for(let s=0;s<8;s+=1)r=r&1?3988292384^r>>>1:r>>>1;e[i]=r>>>0}mi.crcTable=e}return mi.crcTable},hr=new WeakSet,fs=function(e,i){let r=window.URL.createObjectURL(e),s=document.createElement("a");s.href=r,s.download=i,document.body.appendChild(s),s.click(),window.URL.revokeObjectURL(r),s.remove()},gi=new WeakSet,Yr=function(e,i){fetch(e).then(r=>{if(!r.ok)throw new Error(`Download failed: ${r.status}`);return r.blob()}).then(r=>{let s=window.URL.createObjectURL(r),o=document.createElement("a");o.href=s,o.download=i,document.body.appendChild(o),o.click(),window.URL.revokeObjectURL(s),o.remove()}).catch(()=>C(this,fr,ms).call(this,e,i))},fr=new WeakSet,ms=function(e=l(this,Ze),i=l(this,Dt)){if(!e)return;let r=document.createElement("a");r.href=e,r.target="_blank",i&&(r.download=i),document.body.appendChild(r),r.click(),r.remove()},customElements.define("download-button",Wr);var ys=n=>{let t=n.trim();if(!t)return Promise.reject();if(navigator.clipboard?.writeText)return navigator.clipboard.writeText(t);let e=document.createElement("textarea");e.value=t,e.setAttribute("readonly",""),e.style.position="fixed",e.style.top="-9999px",document.body.appendChild(e),e.select();let i=document.execCommand("copy");return e.remove(),i?Promise.resolve():Promise.reject()},vs=n=>n instanceof Element?n.closest("[data-copy-text]"):null,ps=(n,t)=>{let e=n.getAttribute("aria-label"),i=n.querySelector(".main-product-specs__copy-value");n.dataset.copied=t?"true":"false",n.setAttribute("aria-label",t?"Copied":"Copy failed"),i&&(i.dataset.copyState=t?"success":"error"),setTimeout(()=>{delete n.dataset.copied,i&&delete i.dataset.copyState,e?n.setAttribute("aria-label",e):n.removeAttribute("aria-label")},1500)},Ao=n=>{let t=vs(n.target);!t||ys(t.dataset.copyValue||t.textContent).then(()=>ps(t,!0),()=>ps(t,!1))},So=n=>{if(n.key!=="Enter"&&n.key!==" ")return;let t=vs(n.target);!t||(n.preventDefault(),t.click())};document.addEventListener("click",Ao),document.addEventListener("keydown",So);var ko=n=>{let t=Array.from(n.querySelectorAll("[data-copy-text]"));return t.length?t.map(e=>{let i=e.previousElementSibling?.textContent?.trim(),r=e.dataset.copyValue||e.textContent;return[i,r.trim()].filter(Boolean).join(`
86`)}).join(`
87
88`):n.textContent},Nt,$t,bi,Jr,Xr=class extends HTMLElement{constructor(){super(),S(this,bi),S(this,Nt,void 0),S(this,$t,void 0)}connectedCallback(){D(this,$t,this.textContent),this.addEventListener("click",C(this,bi,Jr))}disconnectedCallback(){this.removeEventListener("click",C(this,bi,Jr))}static get observedAttributes(){return["data-target-selector"]}attributeChangedCallback(e,i,r){e==="data-target-selector"&&r&&D(this,Nt,document.querySelector(r))}};Nt=new WeakMap,$t=new WeakMap,bi=new WeakSet,Jr=function(){l(this,Nt)&&ys(ko(l(this,Nt))).then(()=>{this.style.minWidth=this.clientWidth+"px",this.textContent="Copied",setTimeout(()=>{this.style.minWidth=null,this.textContent=l(this,$t)},1500)},()=>{this.style.minWidth=this.clientWidth+"px",this.textContent="Copy Failed!",setTimeout(()=>{this.style.minWidth=null,this.textContent=l(this,$t)},1500)})},customElements.define("copy-button",Xr);var it,Me,rt,ve,qe,nt,H,wi,Oe,Ei,Zr,Ai,en,Qr=class extends HTMLElement{constructor(){super(),S(this,Ei),S(this,Ai),S(this,it,"ShopifyHostedVideoPlayer"),S(this,Me,void 0),S(this,rt,void 0),S(this,ve,void 0),S(this,qe,void 0),S(this,nt,void 0),S(this,H,void 0),S(this,wi,void 0),S(this,Oe,!1),h.info(`${l(this,it)} > constructor`),D(this,ve,this.querySelector("theme-play-button")),D(this,qe,this.querySelector("video.desktop")),D(this,nt,this.querySelector("video.mobile")),D(this,wi,this.querySelector(".theme-banner-hero__video")),D(this,H,l(this,qe))}connectedCallback(){h.info(`${l(this,it)} > connectedCallback`),l(this,H).autoplay&&D(this,Oe,!0),C(this,Ei,Zr).call(this),D(this,rt,new IntersectionObserver(e=>{e.forEach(i=>
88{i.isIntersecting?l(this,H).paused&&l(this,Oe)&&l(this,H).play():l(this,H).paused||(l(this,H).pause(),D(this,Oe,!0))})})),l(this,rt).observe(this)}disconnectedCallback(){l(this,Me)?.abort(),D(this,Me,null),l(this,rt)?.disconnect(),D(this,rt,null)}};it=new WeakMap,Me=new WeakMap,rt=new WeakMap,ve=new WeakMap,qe=new WeakMap,nt=new WeakMap,H=new WeakMap,wi=new WeakMap,Oe=new WeakMap,Ei=new WeakSet,Zr=function(){h.info(`${l(this,it)} > #addListeners`),l(this,Me)?.abort(),D(this,Me,null),D(this,Me,new AbortController);let{signal:e}=l(this,Me);l(this,ve)&&l(this,ve).addEventListener("click",()=>{l(this,H).paused?l(this,H).play():l(this,H).pause()},{signal:e}),l(this,H).addEventListener("playing",()=>{l(this,ve)&&(l(this,ve).dataset.playing="true")},{signal:e}),l(this,H).addEventListener("pause",()=>{l(this,ve)&&(l(this,ve).dataset.playing="false")},{signal:e}),l(this,H).addEventListener("ended",()=>{l(this,H).currentTime=0,l(this,Oe)&&l(this,H).play()},{signal:e}),l(this,H).autoplay&&l(this,H).paused&&l(this,Oe)&&l(this,H).play(),l(this,nt)&&(window.addEventListener("resize",()=>C(this,Ai,en).call(this),{signal:e}),C(this,Ai,en).call(this))},Ai=new WeakSet,en=function(){h.info(`${l(this,it)} > #onResize`);let e=window.innerWidth>=1024?l(this,qe):l(this,nt),i=e===l(this,qe)?l(this,nt):l(this,qe);if(i.pause(),i.remove(),l(this,H)===e)return;let r=l(this,H).readyState>0?l(this,H).currentTime:0;e.parentElement||l(this,wi).appendChild(e),D(this,H,e),r>0&&e.readyState>0&&(e.currentTime=r),C(this,Ei,Zr).call(this)},customElements.define("shopify-hosted-video-player",Qr);function gs(){let n="Global";h.info(`${n} > loading`);let t=document.querySelectorAll("[data-theme-banner-hero]"),e=document.querySelector("[data-theme-header]"),i=document.querySelectorAll("[data-professional-image-carousel]"),r=document.querySelectorAll("[data-professional-video-animation]"),s=document.querySelectorAll("[data-professional-simple-dsp-setup]"),o=document.querySelectorAll("[data-professional-media-text]"),a=document.querySelectorAll("[data-professional-system-calculator]"),u=document.querySelectorAll("[data-theme-popup-gallery-grid]"),c=document.querySelectorAll("[data-theme-revealable-element]"),d=document.querySelectorAll("[data-theme-scrubber-banner]"),A=document.querySelectorAll("[data-theme-side-open-accordion]"),f=document.querySelectorAll("[data-theme-video-banner]"),p=document.querySelectorAll("[data-theme-video-content-module]"),m=null;function x(){h.info(`${n} > init`),k(),O(),L(),T(),b(),M(),I(),N(),q(),V(),W(),P(),y(),g()}function L(){h.info(`${n} > initThemeBannerHeros`),t.forEach(E=>{new lt(E).init()})}function T(){h.info(`${n} > initThemeCarouselBanners`),document.querySelectorAll("[data-theme-carousel-banner]").forEach(w)}function w(E){!E||E.dataset.themeCarouselBannerInitialized==="true"||(E.dataset.themeCarouselBannerInitialized="true",new dt(E).init())}function b(){h.info(`${n} > initProfessionalImageCarousels`),i.forEach(E=>{new Ht(E).init()})}function M(){h.info(`${n} > initProfessionalVideoAnimations`),r.forEach(E=>{new jt(E).init()})}function I(){h.info(`${n} > initProfessionalSimpleDspSetups`),s.forEach(E=>{new Ut(E).init()})}function N(){h.info(`${n} > initProfessionalMediaTextSoftwareModals`),o.forEach(E=>{new Wt(E).init()})}function q(){h.info(`${n} > initProfessionalSystemCalculators`),a.forEach(E=>{new Kt(E).init()})}function k(){h.info(`${n} > initMegaMenuLoader`),e&&(m=new Yt(e),m.init())}function O(){h.info(`${n} > initThemeMobileNav`),e&&new ht(e,m).init()}function V(){h.info(`${n} > initThemePopupGalleryGridDoms`),u.forEach(E=>{new ft(E).init()})}function W(){h.info(`${n} > initRevealableElements`),c.forEach(E=>{new mt(E).init()})}function P(){h.info(`${n} > initThemeSideOpenAccordions`),A.forEach(E=>{new pt(E).init()})}function y(){h.info(`${n} > initThemeVideoBanners`),f.forEach(E=>{new yt(E).init()})}function g(){h.info(`${n} > initThemeVideoContentModules`),p.forEach(E=>{new vt(E).init()})}h.info(`${n} > loaded`),x(),document.addEventListener("shopify:section:load",E=>{let v=E.target.querySelector("[data-theme-carousel-banner]");!v||(h.info(`${n} > shopify:section:load > re-initializing carousel banner`),w(v))})}var st=class{constructor(t){this.NAME="IndexSplitExperiencesGrid",this.dom=t,this.experienceDoms=this.dom.querySelectorAll("[data-index-split-experiences-experience]"),this.videoPlayers={},this.videoPlayersAreInitialized=!1,this.videoPlayerDomActiveClass="index-split-experiences-experience__video--active",this.experienceDomPlayingClass="index-split-experiences-experience--v
88ideo-playing"}init(){h.info(`${this.NAME} > init`);let t=this;new IntersectionObserver(i=>{i.forEach(r=>{r.isIntersecting&&!this.videoPlayersAreInitialized&&t.initializeVideoPlayers()})}).observe(this.dom)}initializeVideoPlayers(){h.info(`${this.NAME} > initializeVideoPlayers`);let t=this;this.experienceDoms.forEach(e=>{let i=e.querySelector("[data-index-split-experiences-experience-native]");if(i){t.initializeNativeVideo(e,i);return}let r=e.querySelector("[data-index-split-experiences-experience-video]");if(!r)return;let s=r.getAttribute("data-index-split-experiences-experience-video"),o=me();r.setAttribute("id",o);let a=new xe(r.getAttribute("id"),{id:s,controls:!1,title:!1,background:!0,byline:!1,portrait:!1,loop:!0,playsinline:!0,muted:!0,autopause:!0});a.on("play",function(u){r.classList.add(t.videoPlayerDomActiveClass)}),t.videoPlayers[o]=a,e.addEventListener("mouseover",u=>{t.playVideo(a)}),e.addEventListener("mouseleave",u=>{t.pauseVideo(a)})}),this.videoPlayersAreInitialized=!0}initializeNativeVideo(t,e){h.info(`${this.NAME} > initializeNativeVideo`);let i=this;e.muted=!0,e.addEventListener("playing",function(){e.classList.add(i.videoPlayerDomActiveClass),t.classList.add(i.experienceDomPlayingClass)}),e.addEventListener("pause",function(){t.classList.remove(i.experienceDomPlayingClass)}),new IntersectionObserver(s=>{s.forEach(o=>{e.dataset.sonanceInView=o.isIntersecting?"1":"",o.isIntersecting?i.playNativeVideo(e):e.pause()})}).observe(e),document.addEventListener("visibilitychange",function(){document.visibilityState==="visible"&&e.dataset.sonanceInView==="1"&&i.playNativeVideo(e)})}playNativeVideo(t){let e=t.play();e&&e.catch&&e.catch(()=>{})}playVideo(t){h.info(`${this.NAME} > playVideo`),t?.play()}playAllVideos(){h.info(`${this.NAME} > playAllVideos`);for(let t in this.videoPlayers)this.playVideo(this.videoPlayers[t])}pauseVideo(t){h.info(`${this.NAME} > pauseVideo`),t?.pause()}};Object.assign(st.prototype,K);var mr="Index",Po=document.querySelectorAll("[data-index-split-experiences-grid]"),Co=()=>{h.info(`${mr} > init`),Mo()},Mo=()=>{h.info(`${mr} > initSplitExperiencesGrid`),Po.forEach(n=>{new st(n).init()})};gs(),Co(),document.addEventListener("shopify:section:load",n=>{let t=n.target.querySelector("[data-index-split-experiences-grid]");t&&(h.info(`${mr} > shopify:section:load > re-initializing grid`),new st(t).init())}),h.log(`${mr} > loaded`);/*!
89 * weakmap-polyfill v2.0.4 - ECMAScript6 WeakMap polyfill
90 * https://github.com/polygonplanet/weakmap-polyfill
91 * Copyright (c) 2015-2021 polygonplanet <[email protected]>
92 * @license MIT
93 *//*! @vimeo/player v2.27.1 | (c) 2025 Vimeo | MIT License | https://github.com/vimeo/player.js *//*! Native Promise Only
94    v0.8.1 (c) Kyle Simpson
95    MIT License: http://getify.mit-license.org
96*/
97//# sourceMappingURL=/cdn/shop/t/8/assets/index.js.map?v=178914091797787030331790197733

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.