function wpae_add_honeypot_field(){
const selectors=[
'form.mc4wp-form',
'form.quform-form',
'form.avia_ajax_form',
'.nf-form-layout form',
'#edd-blocks-form__register',
'form.brxe-form',
'form.forminator-custom-form',
'form.wpmtst-submission-form',
'form.fc-form',
'form#order_review',
'form.mailpoet_form',
'form.wsf-form',
'form.jet-form-builder',
'form.brxe-brf-pro-forms',
'form.sib_signup_form',
'form.youzify-membership-login-form',
'form.fl-contact-form',
'form.srfm-form',
'form.everest-form',
'.bit-form form'
];
document.querySelectorAll(selectors.join(', ')).forEach(form=> {
form.insertAdjacentHTML('beforeend', wpa_hidden_field);
});
document.querySelectorAll('input.wpae_initiator').forEach(input=> {
input.insertAdjacentHTML('afterend', wpa_hidden_field);
});
const wooCommerceCheckoutForm=document.querySelector('form.woocommerce-checkout');
if(wooCommerceCheckoutForm&&!wooCommerceCheckoutForm.querySelector('input#wpae_initiator')){
wooCommerceCheckoutForm.insertAdjacentHTML('beforeend', wpa_hidden_field);
}}
document.addEventListener('DOMContentLoaded', function(){
document.addEventListener('gform_post_render', function(event, form_id, current_page){
wpae_reinitalize_after_form_load();
});
document.addEventListener('edd_gateway_loaded', function(gateway){
wpae_reinitalize_after_form_load();
});
document.addEventListener('nfFormReady', function(){
wpae_reinitalize_after_form_load();
});
if(typeof nfRadio!=='undefined'){
nfRadio.channel("forms").on("before:submit", function(e){
const honeypotInput=document.querySelector('input[name="' + wpa_field_name + '"]');
if(honeypotInput){
const extra=e.get('extra');
extra.wpa_field_name=wpa_field_name;
extra.wpa_field_value=honeypotInput.value;
extra.alt_s=document.querySelector('input[name="alt_s"]').value;
e.set('extra', extra);
}});
}
if(typeof MailPoet!=='undefined'&&typeof MailPoet.Ajax!=='undefined'&&typeof MailPoet.Ajax.getParams==='function'){
const wapeMailpoetGetParams=MailPoet.Ajax.getParams;
MailPoet.Ajax.getParams=function(){
const wapeMailpoetParams=wapeMailpoetGetParams.call(this);
wapeMailpoetParams[wpa_field_name]=document.querySelector('input[name="' + wpa_field_name + '"]').value;
wapeMailpoetParams.alt_s=document.querySelector('input[name="alt_s"]').value;
return wapeMailpoetParams;
};}
document.addEventListener('wsf-rendered', function(e, form, form_id, instance_id){
wpae_reinitalize_after_form_load();
});
document.addEventListener('yith_welrp_popup_template_loaded', function(event, popup, context){
const yithForm=document.querySelector('form.yith-welrp-form');
if(yithForm){
yithForm.insertAdjacentHTML('beforeend', wpa_hidden_field);
}});
});
(function(){
const originalFetch=window.fetch;
window.fetch=function(...args){
let [url, options]=args;
if(options&&options.body&&typeof options.body==='string'&&options.body.includes('action=fl_builder_email')){
const wpaFieldName=wpa_field_name;
const wpaFieldValue=document.querySelector('input[name="' + wpaFieldName + '"]').value;
const altSValue=document.querySelector('input[name="alt_s"]').value;
options.body +='&' + encodeURIComponent(wpaFieldName) + '=' + encodeURIComponent(wpaFieldValue);
options.body +='&alt_s=' + encodeURIComponent(altSValue);
}
return originalFetch.apply(this, args);
};})();
document.addEventListener('DOMContentLoaded', function(){
const observer=new MutationObserver((mutationsList, observer)=> {
for (const mutation of mutationsList){
if(mutation.type==='childList'){
mutation.addedNodes.forEach(node=> {
if(node.nodeType===1&&node.querySelector('form')){
wpae_reinitalize_after_form_load();
}});
}}
});
observer.observe(document.body, { childList: true, subtree: true });
});
function wpae_reinitalize_after_form_load(){
document.querySelectorAll('.wpa_hidden_field, #altEmail_container, .altEmail_container').forEach(el=> el.remove());
if(typeof wpa_add_honeypot_field==='function'){
wpa_add_honeypot_field();
}
if(typeof wpae_add_honeypot_field==='function'){
wpae_add_honeypot_field();
}
if(wpa_add_test==='yes'&&typeof wpa_add_test_block==='function'){
wpa_add_test_block();
}};
!function(t){function n(e){if(r[e])return r[e].exports;var o=r[e]={i:e,l:!1,exports:{}};return t[e].call(o.exports,o,o.exports,n),o.l=!0,o.exports}var r={};n.m=t,n.c=r,n.d=function(t,r,e){n.o(t,r)||Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:e})},n.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(r,"a",r),r},n.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},n.p="",n(n.s=121)}([function(t,n,r){var e=r(59)("wks"),o=r(60),i=r(1).Symbol,u="function"==typeof i;(t.exports=function(t){return e[t]||(e[t]=u&&i[t]||(u?i:o)("Symbol."+t))}).store=e},function(t,n){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},function(t,n){var r=t.exports={version:"2.6.1"};"number"==typeof __e&&(__e=r)},function(t,n){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},function(t,n,r){var e=r(21),o=r(37);t.exports=r(15)?function(t,n,r){return e.f(t,n,o(1,r))}:function(t,n,r){return t[n]=r,t}},function(t,n,r){var e=r(45)("wks"),o=r(24),i=r(3).Symbol,u="function"==typeof i;(t.exports=function(t){return e[t]||(e[t]=u&&i[t]||(u?i:o)("Symbol."+t))}).store=e},function(t,n,r){var e=r(9),o=r(18);t.exports=r(7)?function(t,n,r){return e.f(t,n,o(1,r))}:function(t,n,r){return t[n]=r,t}},function(t,n,r){t.exports=!r(17)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,n){t.exports={}},function(t,n,r){var e=r(10),o=r(53),i=r(54),u=Object.defineProperty;n.f=r(7)?Object.defineProperty:function(t,n,r){if(e(t),n=i(n,!0),e(r),o)try{return u(t,n,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(t[n]=r.value),t}},function(t,n,r){var e=r(11);t.exports=function(t){if(!e(t))throw TypeError(t+" is not an object!");return t}},function(t,n){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,n){var r={}.hasOwnProperty;t.exports=function(t,n){return r.call(t,n)}},function(t,n,r){var e=r(1),o=r(2),i=r(28),u=r(6),c=r(12),a=function(t,n,r){var s,f,p,l=t&a.F,v=t&a.G,h=t&a.S,y=t&a.P,d=t&a.B,m=t&a.W,x=v?o:o[n]||(o[n]={}),b=x.prototype,g=v?e:h?e[n]:(e[n]||{}).prototype;v&&(r=n);for(s in r)(f=!l&&g&&void 0!==g[s])&&c(x,s)||(p=f?g[s]:r[s],x[s]=v&&"function"!=typeof g[s]?r[s]:d&&f?i(p,e):m&&g[s]==p?function(t){var n=function(n,r,e){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(n);case 2:return new t(n,r)}return new t(n,r,e)}return t.apply(this,arguments)};return n.prototype=t.prototype,n}(p):y&&"function"==typeof p?i(Function.call,p):p,y&&((x.virtual||(x.virtual={}))[s]=p,t&a.R&&b&&!b[s]&&u(b,s,p)))};a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,t.exports=a},function(t,n){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,n,r){t.exports=!r(35)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,n){var r={}.hasOwnProperty;t.exports=function(t,n){return r.call(t,n)}},function(t,n){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,n){t.exports=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}}},function(t,n){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on  "+t);return t}},function(t,n){var r=t.exports={version:"2.6.1"};"number"==typeof __e&&(__e=r)},function(t,n,r){var e=r(22),o=r(67),i=r(68),u=Object.defineProperty;n.f=r(15)?Object.defineProperty:function(t,n,r){if(e(t),n=i(n,!0),e(r),o)try{return u(t,n,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(t[n]=r.value),t}},function(t,n,r){var e=r(14);t.exports=function(t){if(!e(t))throw TypeError(t+" is not an object!");return t}},function(t,n,r){var e=r(3),o=r(4),i=r(16),u=r(24)("src"),c=Function.toString,a=(""+c).split("toString");r(20).inspectSource=function(t){return c.call(t)},(t.exports=function(t,n,r,c){var s="function"==typeof r;s&&(i(r,"name")||o(r,"name",n)),t[n]!==r&&(s&&(i(r,u)||o(r,u,t[n]?""+t[n]:a.join(String(n)))),t===e?t[n]=r:c?t[n]?t[n]=r:o(t,n,r):(delete t[n],o(t,n,r)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[u]||c.call(this)})},function(t,n){var r=0,e=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++r+e).toString(36))}},function(t,n){t.exports={}},function(t,n,r){var e=r(39),o=r(42);t.exports=function(t){return e(o(t))}},function(t,n,r){var e=r(45)("keys"),o=r(24);t.exports=function(t){return e[t]||(e[t]=o(t))}},function(t,n,r){var e=r(52);t.exports=function(t,n,r){if(e(t),void 0===n)return t;switch(r){case 1:return function(r){return t.call(n,r)};case 2:return function(r,e){return t.call(n,r,e)};case 3:return function(r,e,o){return t.call(n,r,e,o)}}return function(){return t.apply(n,arguments)}}},function(t,n,r){var e=r(11),o=r(1).document,i=e(o)&&e(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,n){var r={}.toString;t.exports=function(t){return r.call(t).slice(8,-1)}},function(t,n){var r=Math.ceil,e=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?e:r)(t)}},function(t,n,r){var e=r(101),o=r(19);t.exports=function(t){return e(o(t))}},function(t,n,r){var e=r(59)("keys"),o=r(60);t.exports=function(t){return e[t]||(e[t]=o(t))}},function(t,n,r){var e=r(3),o=r(20),i=r(4),u=r(23),c=r(38),a=function(t,n,r){var s,f,p,l,v=t&a.F,h=t&a.G,y=t&a.S,d=t&a.P,m=t&a.B,x=h?e:y?e[n]||(e[n]={}):(e[n]||{}).prototype,b=h?o:o[n]||(o[n]={}),g=b.prototype||(b.prototype={});h&&(r=n);for(s in r)f=!v&&x&&void 0!==x[s],p=(f?x:r)[s],l=m&&f?c(p,e):d&&"function"==typeof p?c(Function.call,p):p,x&&u(x,s,p,t&a.U),b[s]!=p&&i(b,s,l),d&&g[s]!=p&&(g[s]=p)};e.core=o,a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,t.exports=a},function(t,n){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,n,r){var e=r(14),o=r(3).document,i=e(o)&&e(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,n){t.exports=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}}},function(t,n,r){var e=r(69);t.exports=function(t,n,r){if(e(t),void 0===n)return t;switch(r){case 1:return function(r){return t.call(n,r)};case 2:return function(r,e){return t.call(n,r,e)};case 3:return function(r,e,o){return t.call(n,r,e,o)}}return function(){return t.apply(n,arguments)}}},function(t,n,r){var e=r(40);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==e(t)?t.split(""):Object(t)}},function(t,n){var r={}.toString;t.exports=function(t){return r.call(t).slice(8,-1)}},function(t,n,r){var e=r(42);t.exports=function(t){return Object(e(t))}},function(t,n){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on  "+t);return t}},function(t,n,r){var e=r(44),o=Math.min;t.exports=function(t){return t>0?o(e(t),9007199254740991):0}},function(t,n){var r=Math.ceil,e=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?e:r)(t)}},function(t,n,r){var e=r(20),o=r(3),i=o["__core-js_shared__"]||(o["__core-js_shared__"]={});(t.exports=function(t,n){return i[t]||(i[t]=void 0!==n?n:{})})("versions",[]).push({version:e.version,mode:r(46)?"pure":"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"})},function(t,n){t.exports=!1},function(t,n,r){var e=r(5)("unscopables"),o=Array.prototype;void 0==o[e]&&r(4)(o,e,{}),t.exports=function(t){o[e][t]=!0}},function(t,n,r){"use strict";var e=r(47),o=r(75),i=r(25),u=r(26);t.exports=r(76)(Array,"Array",function(t,n){this._t=u(t),this._i=0,this._k=n},function(){var t=this._t,n=this._k,r=this._i++;return!t||r>=t.length?(this._t=void 0,o(1)):"keys"==n?o(0,r):"values"==n?o(0,t[r]):o(0,[r,t[r]])},"values"),i.Arguments=i.Array,e("keys"),e("values"),e("entries")},function(t,n,r){var e=r(80),o=r(50);t.exports=Object.keys||function(t){return e(t,o)}},function(t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,n,r){var e=r(21).f,o=r(16),i=r(5)("toStringTag");t.exports=function(t,n,r){t&&!o(t=r?t:t.prototype,i)&&e(t,i,{configurable:!0,value:n})}},function(t,n){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,n,r){t.exports=!r(7)&&!r(17)(function(){return 7!=Object.defineProperty(r(29)("div"),"a",{get:function(){return 7}}).a})},function(t,n,r){var e=r(11);t.exports=function(t,n){if(!e(t))return t;var r,o;if(n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;if("function"==typeof(r=t.valueOf)&&!e(o=r.call(t)))return o;if(!n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,n,r){"use strict";var e=r(94)(!0);r(56)(String,"String",function(t){this._t=String(t),this._i=0},function(){var t,n=this._t,r=this._i;return r>=n.length?{value:void 0,done:!0}:(t=e(n,r),this._i+=t.length,{value:t,done:!1})})},function(t,n,r){"use strict";var e=r(57),o=r(13),i=r(95),u=r(6),c=r(8),a=r(96),s=r(62),f=r(105),p=r(0)("iterator"),l=!([].keys&&"next"in[].keys()),v=function(){return this};t.exports=function(t,n,r,h,y,d,m){a(r,n,h);var x,b,g,S=function(t){if(!l&&t in j)return j[t];switch(t){case"keys":case"values":return function(){return new r(this,t)}}return function(){return new r(this,t)}},w=n+" Iterator",_="values"==y,O=!1,j=t.prototype,L=j[p]||j["@@iterator"]||y&&j[y],A=L||S(y),T=y?_?S("entries"):A:void 0,P="Array"==n?j.entries||L:L;if(P&&(g=f(P.call(new t)))!==Object.prototype&&g.next&&(s(g,w,!0),e||"function"==typeof g[p]||u(g,p,v)),_&&L&&"values"!==L.name&&(O=!0,A=function(){return L.call(this)}),e&&!m||!l&&!O&&j[p]||u(j,p,A),c[n]=A,c[w]=v,y)if(x={values:_?A:S("values"),keys:d?A:S("keys"),entries:T},m)for(b in x)b in j||i(j,b,x[b]);else o(o.P+o.F*(l||O),n,x);return x}},function(t,n){t.exports=!0},function(t,n,r){var e=r(31),o=Math.min;t.exports=function(t){return t>0?o(e(t),9007199254740991):0}},function(t,n,r){var e=r(2),o=r(1),i=o["__core-js_shared__"]||(o["__core-js_shared__"]={});(t.exports=function(t,n){return i[t]||(i[t]=void 0!==n?n:{})})("versions",[]).push({version:e.version,mode:r(57)?"pure":"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"})},function(t,n){var r=0,e=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++r+e).toString(36))}},function(t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,n,r){var e=r(9).f,o=r(12),i=r(0)("toStringTag");t.exports=function(t,n,r){t&&!o(t=r?t:t.prototype,i)&&e(t,i,{configurable:!0,value:n})}},function(t,n,r){var e=r(19);t.exports=function(t){return Object(e(t))}},function(t,n,r){var e=r(30),o=r(0)("toStringTag"),i="Arguments"==e(function(){return arguments}()),u=function(t,n){try{return t[n]}catch(t){}};t.exports=function(t){var n,r,c;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(r=u(n=Object(t),o))?r:i?e(n):"Object"==(c=e(n))&&"function"==typeof n.callee?"Arguments":c}},function(t,n,r){"use strict";var e=r(66),o=(r.n(e),r(74)),i=(r.n(o),r(48)),u=(r.n(i),r(85)),c=r.n(u),a=window,s=a.jQuery;s(function(){function t(){s(".mphbr-expand-comment-text:not([data-inited])").attr("data-inited","1").on("click",function(t){t.preventDefault();var n=s(this),r=n.parents(".mphbr-comment-excerpt");return r.siblings(".mphbr-comment-full-text").toggle(),r.remove(),!1})}s("body").on("click",".mphbr-rating-parameter-wrapper p.mphbr-stars a",function(){var t=s(this),n=s(this).closest(".mphbr-rating-parameter-wrapper").find(".mphb-rating-picker"),r=s(this).closest(".mphbr-stars");return n.val(t.text()),t.siblings("a").removeClass("active"),t.addClass("active"),r.addClass("selected"),!1}),function(t){t.each(function(t,n){n=s(n);var r=n.val(),e=c()(Array(5).keys()).map(function(t){++t;var n=r==t?" active":"";return'<a class="mphbr-star-'.concat(t," dashicons dashicons-star-filled").concat(n,'" href="#">').concat(t,"</a>")}),o=r?" selected":"",i='<p class="mphbr-stars'.concat(o,'"><span>').concat(e.join(""),"</span></p>");n.before(i)})}(s(".mphb-rating-picker")),s(".mphbr-review-form").on("submit",function(t){if(!this.checkValidity())return this.reportValidity(),!1}),s(".mphb-reviews .mphbr-new-review-box").hide().removeClass("mphb-hide"),s(".mphb-reviews").find(".comment-notes").insertBefore(".mphbr-rating-wrapper"),s(".mphbr-add-review").on("click",function(){return s(this).parents(".mphb-reviews").find(".mphbr-new-review-box").toggle(),!1}),t(),s(".mphbr-load-more").each(function(t,n){var r=s(n).parents(".mphb-reviews"),e=r.find(".mphbr-reviews-list"),o=r.data("accommodation-id"),i=e.children().length;n.mphbr={list:e,accommodation_id:o,offset:i,per_page:i}}).on("click",function(){var n=s(this),r=this.mphbr;n.prop("disabled",!0).addClass("mphbr-loading"),n.siblings(".mphb-preloader").removeClass("mphb-hide"),s.ajax({url:MPHBR.settings.ajaxUrl,type:"GET",dataType:"json",data:{action:"mphbr_load_more",nonce:MPHBR.nonce.mphbr_load_more,accommodation_id:r.accommodation_id,offset:r.offset,per_page:r.per_page},success:function(e){e.success&&e.data&&(e.data.count&&(r.offset+=e.data.count),e.data.items&&(r.list.append(e.data.items),t()),void 0==e.data.hasMore||e.data.hasMore||n.hide())},complete:function(){n.prop("disabled",!1).removeClass("mphbr-loading"),n.siblings(".mphb-preloader").addClass("mphb-hide")}})})})},function(t,n,r){"use strict";var e=r(34),o=r(70)(5),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),e(e.P+e.F*i,"Array",{find:function(t){return o(this,t,arguments.length>1?arguments[1]:void 0)}}),r(47)("find")},function(t,n,r){t.exports=!r(15)&&!r(35)(function(){return 7!=Object.defineProperty(r(36)("div"),"a",{get:function(){return 7}}).a})},function(t,n,r){var e=r(14);t.exports=function(t,n){if(!e(t))return t;var r,o;if(n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;if("function"==typeof(r=t.valueOf)&&!e(o=r.call(t)))return o;if(!n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,n){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,n,r){var e=r(38),o=r(39),i=r(41),u=r(43),c=r(71);t.exports=function(t,n){var r=1==t,a=2==t,s=3==t,f=4==t,p=6==t,l=5==t||p,v=n||c;return function(n,c,h){for(var y,d,m=i(n),x=o(m),b=e(c,h,3),g=u(x.length),S=0,w=r?v(n,g):a?v(n,0):void 0;g>S;S++)if((l||S in x)&&(y=x[S],d=b(y,S,m),t))if(r)w[S]=d;else if(d)switch(t){case 3:return!0;case 5:return y;case 6:return S;case 2:w.push(y)}else if(f)return!1;return p?-1:s||f?f:w}}},function(t,n,r){var e=r(72);t.exports=function(t,n){return new(e(t))(n)}},function(t,n,r){var e=r(14),o=r(73),i=r(5)("species");t.exports=function(t){var n;return o(t)&&(n=t.constructor,"function"!=typeof n||n!==Array&&!o(n.prototype)||(n=void 0),e(n)&&null===(n=n[i])&&(n=void 0)),void 0===n?Array:n}},function(t,n,r){var e=r(40);t.exports=Array.isArray||function(t){return"Array"==e(t)}},function(t,n,r){for(var e=r(48),o=r(49),i=r(23),u=r(3),c=r(4),a=r(25),s=r(5),f=s("iterator"),p=s("toStringTag"),l=a.Array,v={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},h=o(v),y=0;y<h.length;y++){var d,m=h[y],x=v[m],b=u[m],g=b&&b.prototype;if(g&&(g[f]||c(g,f,l),g[p]||c(g,p,m),a[m]=l,x))for(d in e)g[d]||i(g,d,e[d],!0)}},function(t,n){t.exports=function(t,n){return{value:n,done:!!t}}},function(t,n,r){"use strict";var e=r(46),o=r(34),i=r(23),u=r(4),c=r(25),a=r(77),s=r(51),f=r(84),p=r(5)("iterator"),l=!([].keys&&"next"in[].keys()),v=function(){return this};t.exports=function(t,n,r,h,y,d,m){a(r,n,h);var x,b,g,S=function(t){if(!l&&t in j)return j[t];switch(t){case"keys":case"values":return function(){return new r(this,t)}}return function(){return new r(this,t)}},w=n+" Iterator",_="values"==y,O=!1,j=t.prototype,L=j[p]||j["@@iterator"]||y&&j[y],A=L||S(y),T=y?_?S("entries"):A:void 0,P="Array"==n?j.entries||L:L;if(P&&(g=f(P.call(new t)))!==Object.prototype&&g.next&&(s(g,w,!0),e||"function"==typeof g[p]||u(g,p,v)),_&&L&&"values"!==L.name&&(O=!0,A=function(){return L.call(this)}),e&&!m||!l&&!O&&j[p]||u(j,p,A),c[n]=A,c[w]=v,y)if(x={values:_?A:S("values"),keys:d?A:S("keys"),entries:T},m)for(b in x)b in j||i(j,b,x[b]);else o(o.P+o.F*(l||O),n,x);return x}},function(t,n,r){"use strict";var e=r(78),o=r(37),i=r(51),u={};r(4)(u,r(5)("iterator"),function(){return this}),t.exports=function(t,n,r){t.prototype=e(u,{next:o(1,r)}),i(t,n+" Iterator")}},function(t,n,r){var e=r(22),o=r(79),i=r(50),u=r(27)("IE_PROTO"),c=function(){},a=function(){var t,n=r(36)("iframe"),e=i.length;for(n.style.display="none",r(83).appendChild(n),n.src="javascript:",t=n.contentWindow.document,t.open(),t.write("<script>document.F=Object<\/script>"),t.close(),a=t.F;e--;)delete a.prototype[i[e]];return a()};t.exports=Object.create||function(t,n){var r;return null!==t?(c.prototype=e(t),r=new c,c.prototype=null,r[u]=t):r=a(),void 0===n?r:o(r,n)}},function(t,n,r){var e=r(21),o=r(22),i=r(49);t.exports=r(15)?Object.defineProperties:function(t,n){o(t);for(var r,u=i(n),c=u.length,a=0;c>a;)e.f(t,r=u[a++],n[r]);return t}},function(t,n,r){var e=r(16),o=r(26),i=r(81)(!1),u=r(27)("IE_PROTO");t.exports=function(t,n){var r,c=o(t),a=0,s=[];for(r in c)r!=u&&e(c,r)&&s.push(r);for(;n.length>a;)e(c,r=n[a++])&&(~i(s,r)||s.push(r));return s}},function(t,n,r){var e=r(26),o=r(43),i=r(82);t.exports=function(t){return function(n,r,u){var c,a=e(n),s=o(a.length),f=i(u,s);if(t&&r!=r){for(;s>f;)if((c=a[f++])!=c)return!0}else for(;s>f;f++)if((t||f in a)&&a[f]===r)return t||f||0;return!t&&-1}}},function(t,n,r){var e=r(44),o=Math.max,i=Math.min;t.exports=function(t,n){return t=e(t),t<0?o(t+n,0):i(t,n)}},function(t,n,r){var e=r(3).document;t.exports=e&&e.documentElement},function(t,n,r){var e=r(16),o=r(41),i=r(27)("IE_PROTO"),u=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=o(t),e(t,i)?t[i]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?u:null}},function(t,n,r){function e(t){return o(t)||i(t)||u()}var o=r(86),i=r(91),u=r(119);t.exports=e},function(t,n,r){function e(t){if(o(t)){for(var n=0,r=new Array(t.length);n<t.length;n++)r[n]=t[n];return r}}var o=r(87);t.exports=e},function(t,n,r){t.exports=r(88)},function(t,n,r){r(89),t.exports=r(2).Array.isArray},function(t,n,r){var e=r(13);e(e.S,"Array",{isArray:r(90)})},function(t,n,r){var e=r(30);t.exports=Array.isArray||function(t){return"Array"==e(t)}},function(t,n,r){function e(t){if(i(Object(t))||"[object Arguments]"===Object.prototype.toString.call(t))return o(t)}var o=r(92),i=r(112);t.exports=e},function(t,n,r){t.exports=r(93)},function(t,n,r){r(55),r(106),t.exports=r(2).Array.from},function(t,n,r){var e=r(31),o=r(19);t.exports=function(t){return function(n,r){var i,u,c=String(o(n)),a=e(r),s=c.length;return a<0||a>=s?t?"":void 0:(i=c.charCodeAt(a),i<55296||i>56319||a+1===s||(u=c.charCodeAt(a+1))<56320||u>57343?t?c.charAt(a):i:t?c.slice(a,a+2):u-56320+(i-55296<<10)+65536)}}},function(t,n,r){t.exports=r(6)},function(t,n,r){"use strict";var e=r(97),o=r(18),i=r(62),u={};r(6)(u,r(0)("iterator"),function(){return this}),t.exports=function(t,n,r){t.prototype=e(u,{next:o(1,r)}),i(t,n+" Iterator")}},function(t,n,r){var e=r(10),o=r(98),i=r(61),u=r(33)("IE_PROTO"),c=function(){},a=function(){var t,n=r(29)("iframe"),e=i.length;for(n.style.display="none",r(104).appendChild(n),n.src="javascript:",t=n.contentWindow.document,t.open(),t.write("<script>document.F=Object<\/script>"),t.close(),a=t.F;e--;)delete a.prototype[i[e]];return a()};t.exports=Object.create||function(t,n){var r;return null!==t?(c.prototype=e(t),r=new c,c.prototype=null,r[u]=t):r=a(),void 0===n?r:o(r,n)}},function(t,n,r){var e=r(9),o=r(10),i=r(99);t.exports=r(7)?Object.defineProperties:function(t,n){o(t);for(var r,u=i(n),c=u.length,a=0;c>a;)e.f(t,r=u[a++],n[r]);return t}},function(t,n,r){var e=r(100),o=r(61);t.exports=Object.keys||function(t){return e(t,o)}},function(t,n,r){var e=r(12),o=r(32),i=r(102)(!1),u=r(33)("IE_PROTO");t.exports=function(t,n){var r,c=o(t),a=0,s=[];for(r in c)r!=u&&e(c,r)&&s.push(r);for(;n.length>a;)e(c,r=n[a++])&&(~i(s,r)||s.push(r));return s}},function(t,n,r){var e=r(30);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==e(t)?t.split(""):Object(t)}},function(t,n,r){var e=r(32),o=r(58),i=r(103);t.exports=function(t){return function(n,r,u){var c,a=e(n),s=o(a.length),f=i(u,s);if(t&&r!=r){for(;s>f;)if((c=a[f++])!=c)return!0}else for(;s>f;f++)if((t||f in a)&&a[f]===r)return t||f||0;return!t&&-1}}},function(t,n,r){var e=r(31),o=Math.max,i=Math.min;t.exports=function(t,n){return t=e(t),t<0?o(t+n,0):i(t,n)}},function(t,n,r){var e=r(1).document;t.exports=e&&e.documentElement},function(t,n,r){var e=r(12),o=r(63),i=r(33)("IE_PROTO"),u=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=o(t),e(t,i)?t[i]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?u:null}},function(t,n,r){"use strict";var e=r(28),o=r(13),i=r(63),u=r(107),c=r(108),a=r(58),s=r(109),f=r(110);o(o.S+o.F*!r(111)(function(t){Array.from(t)}),"Array",{from:function(t){var n,r,o,p,l=i(t),v="function"==typeof this?this:Array,h=arguments.length,y=h>1?arguments[1]:void 0,d=void 0!==y,m=0,x=f(l);if(d&&(y=e(y,h>2?arguments[2]:void 0,2)),void 0==x||v==Array&&c(x))for(n=a(l.length),r=new v(n);n>m;m++)s(r,m,d?y(l[m],m):l[m]);else for(p=x.call(l),r=new v;!(o=p.next()).done;m++)s(r,m,d?u(p,y,[o.value,m],!0):o.value);return r.length=m,r}})},function(t,n,r){var e=r(10);t.exports=function(t,n,r,o){try{return o?n(e(r)[0],r[1]):n(r)}catch(n){var i=t.return;throw void 0!==i&&e(i.call(t)),n}}},function(t,n,r){var e=r(8),o=r(0)("iterator"),i=Array.prototype;t.exports=function(t){return void 0!==t&&(e.Array===t||i[o]===t)}},function(t,n,r){"use strict";var e=r(9),o=r(18);t.exports=function(t,n,r){n in t?e.f(t,n,o(0,r)):t[n]=r}},function(t,n,r){var e=r(64),o=r(0)("iterator"),i=r(8);t.exports=r(2).getIteratorMethod=function(t){if(void 0!=t)return t[o]||t["@@iterator"]||i[e(t)]}},function(t,n,r){var e=r(0)("iterator"),o=!1;try{var i=[7][e]();i.return=function(){o=!0},Array.from(i,function(){throw 2})}catch(t){}t.exports=function(t,n){if(!n&&!o)return!1;var r=!1;try{var i=[7],u=i[e]();u.next=function(){return{done:r=!0}},i[e]=function(){return u},t(i)}catch(t){}return r}},function(t,n,r){t.exports=r(113)},function(t,n,r){r(114),r(55),t.exports=r(118)},function(t,n,r){r(115);for(var e=r(1),o=r(6),i=r(8),u=r(0)("toStringTag"),c="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),a=0;a<c.length;a++){var s=c[a],f=e[s],p=f&&f.prototype;p&&!p[u]&&o(p,u,s),i[s]=i.Array}},function(t,n,r){"use strict";var e=r(116),o=r(117),i=r(8),u=r(32);t.exports=r(56)(Array,"Array",function(t,n){this._t=u(t),this._i=0,this._k=n},function(){var t=this._t,n=this._k,r=this._i++;return!t||r>=t.length?(this._t=void 0,o(1)):"keys"==n?o(0,r):"values"==n?o(0,t[r]):o(0,[r,t[r]])},"values"),i.Arguments=i.Array,e("keys"),e("values"),e("entries")},function(t,n){t.exports=function(){}},function(t,n){t.exports=function(t,n){return{value:n,done:!!t}}},function(t,n,r){var e=r(64),o=r(0)("iterator"),i=r(8);t.exports=r(2).isIterable=function(t){var n=Object(t);return void 0!==n[o]||"@@iterator"in n||i.hasOwnProperty(e(n))}},function(t,n){function r(){throw new TypeError("Invalid attempt to spread non-iterable instance")}t.exports=r},,function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var e=r(122);r.n(e),r(65)},function(t,n){}]);
(()=>{"use strict";var e={n:t=>{var a=t&&t.__esModule?()=>t.default:()=>t;return e.d(a,{a}),a},d:(t,a)=>{for(var o in a)e.o(a,o)&&!e.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:a[o]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=window.wp.domReady;var a=e.n(t);const o=()=>{try{return window.self!==window.top}catch(e){return!0}},r="starter-templates-iframe-preview-data",n=()=>{let e="";const t=document.querySelector(".site-logo-img img");return t&&(e=t.src),e};let s=n();const l=(e,t)=>{if(!e)return"";if(e){const a=e.match(/'([^']+)'/);return a?a[1]:"inherit"===e?t:e}return t||void 0},i=e=>{switch(e.value.param){case"siteLogo":const t=document.querySelectorAll(".site-logo-img img");""===s&&(s=n());let a=e.value.data.url||s;if(a=e.value.data.dataUri||a,0===t.length&&""!==a){const t=document.createElement("span");t.classList.add("site-logo-img");const o=document.createElement("a");o.setAttribute("class","custom-logo-link"),o.setAttribute("href","#"),o.setAttribute("aria-current","page"),t.appendChild(o);const r=document.createElement("img");r.classList.add("custom-logo"),r.setAttribute("src",a),o.appendChild(r);const n=document.getElementById("ast-desktop-header").querySelectorAll(".ast-site-identity")[0],s=n.querySelectorAll(".ast-site-title-wrap")[0];n.insertBefore(t,s);const l=e.value.data.width||"";""!==l&&(r.style.width=l+"px",r.style.maxWidth=l+"px")}else if(""!==a)for(const[o,r]of Object.entries(t)){r.removeAttribute("srcset"),r.setAttribute("src",a);const t=e.value.data.width;""!==t&&(r.style.width=t+"px",r.style.maxWidth=t+"px")}break;case"colorPalette":const o=e.value.data.colors||[],r=astraTemplateExporterPreview.AstColorPaletteVarPrefix,i=astraTemplateExporterPreview.AstEleColorPaletteVarPrefix;if(0===o.length){document.querySelector("body").classList.remove("starter-templates-preview-palette");const e=document.getElementsByClassName("starter-templates-preview-palette");return void(e.length>0&&e[0].remove())}document.querySelector("body").classList.add("starter-templates-preview-palette");const d=Object.entries(o).map((e,t)=>[`--e-global-color-${i[t].replace(/-/g,"")}: ${e[1]};`,`${r}${t}: ${e[1]};`]).map(e=>e.join("")).join("");let c=document.getElementById("starter-templates-preview-palette-css");c||(c=document.createElement("style"),c.id="starter-templates-preview-palette-css",c.setAttribute("rel","stylesheet"),document.head.appendChild(c)),c.innerHTML=`.starter-templates-preview-palette{ ${d}}`;break;case"siteTypography":if(!Object.keys(e.value.data).length){const e=document.getElementById("starter-templates-typography");return void(e&&e.remove())}(e=>{if(!e)return;if(!document.getElementById("google-fonts-domain")){const e=document.createElement("link");e.id="google-fonts-domain",e.setAttribute("rel","preconnect"),e.setAttribute("href","https://fonts.gstatic.com"),document.head.appendChild(e)}let t=document.getElementById("st-previw-google-fonts-url");t||(t=document.createElement("link"),t.id="st-previw-google-fonts-url",t.setAttribute("rel","stylesheet"),document.head.appendChild(t));const a=[];let o=e["body-font-family"]||"",r=parseInt(e["body-font-weight"])||"";r&&(r=`:wght@${r}`),o&&(o=l(o),o=o.replace(" ","+"),a.push(`family=${o}${r}`));let n=e["headings-font-family"]||"",s=parseInt(e["headings-font-weight"])||"";s&&(s=`:wght@${s}`),n&&(n=l(n,o),n=n.replace(" ","+"),a.push(`family=${n}${s}`));const i=`https://fonts.googleapis.com/css2?${a.join("&")}&display=swap`;t.setAttribute("href",i)})(e.value.data),(e=>{if(!e)return;let t=document.getElementById("starter-templates-typography");t||(t=document.createElement("style"),t.id="starter-templates-typography",t.setAttribute("rel","stylesheet"),document.head.appendChild(t));let a="";a+="body, button, input, select, textarea, .ast-button, .ast-custom-button {",a+="\tfont-family: "+e["body-font-family"]+";",a+="\tfont-weight: "+e["body-font-weight"]+";",a+="\tfont-size: "+e["font-size-body"].desktop+e["font-size-body"]["desktop-unit"]+";",a+="\tline-height: "+e["body-line-height"]+";",a+="}",a+="h1, .entry-content h1, h2, .entry-content h2, h3, .entry-content h3, h4, .entry-content h4, h5, .entry-content h5, h6, .entry-content h6, .site-title, .site-title a {",a+="\tfont-family: "+e["headings-font-family"]+";",a+="\tline-height: "+e["headings-line-height"]+";",a+="\tfont-weight: "+e["headings-font-weight"]+";",a+="}",["h1","h2","h3","h4","h5","h6"].forEach(t=>{const o="inherit"===e["font-family-"+t]?e["headings-font-family"]:e["font-family-"+t],r="inherit"===e["font-weight-"+t]?e["headings-font-weight"]:e["font-weight-"+t];let n="";void 0!==o&&""!==o&&(n+=`${t}, .entry-content ${t} {`,n+="\tfont-family: "+o+";"),void 0!==e["line-height-"+t]&&""!==e["line-height-"+t]&&(n+="\tline-height: "+e["line-height-"+t]+";"),void 0!==r&&""!==r&&(n+="\tfont-weight: "+r+";"),a+=""!==n?n+"}":""}),t.innerHTML=a})(e.value.data);break;case"siteTitle":(e=>{const t=document.getElementById("ast-desktop-header"),a=t&&t.querySelectorAll(".ast-site-identity")[0],o=a&&a.querySelectorAll(".ast-site-title-wrap")[0];o&&(o.style.display=e?"block":"none")})(e.value.data);break;case"clearPreviewAssets":const m=document.getElementById("starter-templates-typography");m&&m.remove(),document.querySelector("body").classList.remove("starter-templates-preview-palette");const p=document.getElementsByClassName("starter-templates-preview-palette");p.length>0&&p[0].remove();break;case"completeOnboarding":localStorage.removeItem("starter-templates-iframe-preview-data")}};window.addEventListener("message",function(e){if(o()&&(console.log("addEventListener message: ",e),"object"==typeof e.data&&"starterTemplatePreviewDispatch"===e.data.call)){const t=e.data;let a=JSON.parse(localStorage.getItem(r));null===a&&(a={},a.data={}),a.data[t.value.param]=t.value.data,delete a.data.clearPreviewAssets,t.url=window.location.origin,a.url=window.location.origin,"cleanStorage"===t.value.param?(delete a.data.cleanStorage,a.data.siteLogo=t.value.data,a.data.colorPalette={},a.data.siteTypography={},Object.keys(a.data).map(e=>i({value:{param:e,data:a.data[e]}}))):i(t),localStorage.setItem(r,JSON.stringify(a))}},!1),a()(()=>{if(!o())return;const e=document.createElement("style");e.id="starter-templates-logo-css",document.getElementsByTagName("head")[0].appendChild(e),e.innerHTML=".site-logo-img img { transition: unset; } #wpadminbar { display: none; } html{  margin-top: 0 !important; }}";const t=(a=r,JSON.parse(localStorage.getItem(a)));var a;t&&Object.keys(t.data).map(e=>i({value:{param:e,data:t.data[e]}}))})})();
!function(c){c.idleTimer=function(e,n){var i;"object"==typeof e?(i=e,e=null):"number"==typeof e&&(i={timeout:e},e=null),n=n||document,i=c.extend({idle:!1,timeout:3e4,events:"mousemove keydown wheel DOMMouseScroll mousewheel mousedown touchstart touchmove MSPointerDown MSPointerMove"},i);function t(e){var i=c.data(n,"idleTimerObj")||{};i.idle=!i.idle,i.olddate=+new Date;var t=c.Event((i.idle?"idle":"active")+".idleTimer");c(n).trigger(t,[n,c.extend({},i),e])}function r(e){var i=c.data(n,"idleTimerObj")||{};if(("storage"!==e.type||e.originalEvent.key===i.timerSyncId)&&null==i.remaining){if("mousemove"===e.type){if(e.pageX===i.pageX&&e.pageY===i.pageY)return;if(void 0===e.pageX&&void 0===e.pageY)return;if(new Date-i.olddate<200)return}clearTimeout(i.tId),i.idle&&t(e),i.lastActive=+new Date,i.pageX=e.pageX,i.pageY=e.pageY,"storage"!==e.type&&i.timerSyncId&&"undefined"!=typeof localStorage&&localStorage.setItem(i.timerSyncId,i.lastActive),i.tId=setTimeout(t,i.timeout)}}function l(){var e=c.data(n,"idleTimerObj")||{};e.idle=e.idleBackup,e.olddate=+new Date,e.lastActive=e.olddate,e.remaining=null,clearTimeout(e.tId),e.idle||(e.tId=setTimeout(t,e.timeout))}var a,d,o,u=c(n),m=u.data("idleTimerObj")||{};if(null===e&&void 0!==m.idle)return l(),u;if(null!==e){if(null!==e&&void 0===m.idle)return!1;if("destroy"===e)return o=c.data(n,"idleTimerObj")||{},clearTimeout(o.tId),u.removeData("idleTimerObj"),u.off("._idleTimer"),u;if("pause"===e)return null==(d=c.data(n,"idleTimerObj")||{}).remaining&&(d.remaining=d.timeout-(new Date-d.olddate),clearTimeout(d.tId)),u;if("resume"===e)return null!=(a=c.data(n,"idleTimerObj")||{}).remaining&&(a.idle||(a.tId=setTimeout(t,a.remaining)),a.remaining=null),u;if("reset"===e)return l(),u;if("getRemainingTime"===e)return function(){var e=c.data(n,"idleTimerObj")||{};if(e.idle)return 0;if(null!=e.remaining)return e.remaining;var i=e.timeout-(new Date-e.lastActive);return i<0&&(i=0),i}();if("getElapsedTime"===e)return new Date-m.olddate;if("getLastActiveTime"===e)return m.lastActive;if("isIdle"===e)return m.idle}return u.on((i.events+" ").split(" ").join("._idleTimer ").trim(),function(e){r(e)}),i.timerSyncId&&c(window).on("storage",r),(m=c.extend({},{olddate:+new Date,lastActive:+new Date,idle:i.idle,idleBackup:i.idle,timeout:i.timeout,remaining:null,timerSyncId:i.timerSyncId,tId:null,pageX:null,pageY:null})).idle||(m.tId=setTimeout(t,m.timeout)),c.data(n,"idleTimerObj",m),u},c.fn.idleTimer=function(e){return this[0]?c.idleTimer(e,this[0]):this}}(jQuery);
(function($){
$(function (){
var all_networks_opened=0;
et_pb_fix_gallery_wrapper();
$('body').on('click', '.et_social_share', function(){
var $this_el=$(this),
social_type=$this_el.data('social_type'),
social_network=$this_el.data('social_name'),
share_link='media'==social_type ? $this_el.data('social_link'):$this_el.prop('href');
update_stats_table(social_network, $this_el);
if('like'===social_network){
return false;
}
var left=($(window).width()/2) -(550/2);
var top=($(window).height()/2) -(450/2);
var new_window=window.open(share_link, '', 'scrollbars=1, height=450, width=550, left=' + left + ', top=' + top);
if(window.focus){
new_window.focus();
}
return false;
});
$('.et_social_follow').on('click', function(){
var $this_el=$(this),
social_network=$this_el.data('social_name');
update_stats_table(social_network, $this_el);
if('like'===social_network){
return false;
}});
$('body').on('click', '.et_social_share_pinterest', function(){
if($(this).hasClass('et_social_pin_all') ){
var left=($(window).width()/2) -(550/2),
top=($(window).height()/2) -(450/2),
share_link=$(this).attr('href'),
new_window=window.open(share_link, '', 'scrollbars=1, height=450, width=550, left=' + left + ', top=' + top);
if(window.focus){
new_window.focus();
}}else{
$('.et_social_pin_images_outer').fadeToggle(400);
}
return false;
});
function get_url_parameter(param_name){
var page_url=window.location.search.substring(1);
var url_variables=page_url.split('&');
for(var i=0; i < url_variables.length; i++){
var curr_param_name=url_variables[i].split('=');
if(curr_param_name[0]==param_name){
return curr_param_name[1];
}}
}
function update_stats_table($social_network, $this_el){
var action=$this_el.data('social_type'),
media_url='media'==action ? $this_el.closest('.et_social_media_wrapper').find('img').attr('src'):'',
post_id=$this_el.data('post_id'),
location=$this_el.data('location'),
stats_data='';
stats_data=JSON.stringify({
'action':action,
'network':$social_network,
'media_url':media_url,
'post_id':post_id,
'location':location
});
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'add_stats_record_db',
stats_data_array:stats_data,
add_stats_nonce:monarchSettings.stats_nonce
},
success: function(data){
if(true==data){
if('like'===action){
update_single_shares($this_el, '', post_id, $social_network, 'like');
}
if('media'===action){
update_total_media_shares($this_el.closest('.et_social_media_wrapper') );
update_single_shares($this_el, media_url, post_id, $social_network, 'media');
}}
}});
}
function append_share_counts($current_network){
var network=$current_network.data('social_name'),
min_count=$current_network.data('min_count'),
post_id=$current_network.data('post_id'),
url=monarchSettings.pageurl!=='' ? monarchSettings.pageurl:window.location.href,
label_div=$current_network.find('.et_social_network_label'),
append_to=(0!=(label_div.length) ) ? label_div:$current_network;
$share_count_data=JSON.stringify({ 'network':network, 'min_count':min_count, 'post_id':post_id, 'url':url });
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_shares_count',
share_count_array:$share_count_data,
get_share_counts_nonce:monarchSettings.share_counts
},
beforeSend: function(data){
append_to.append('<span class="et_social_placeholder"></span>');
},
success: function(data){
$current_network.find('span.et_social_placeholder').remove();
append_to.append(data);
}});
}
function append_total_shares($current_area){
var post_id=$current_area.data('post_id'),
url=monarchSettings.pageurl!=='' ? monarchSettings.pageurl:window.location.href,
append_to=$current_area;
$share_total_count_data=JSON.stringify({ 'post_id':post_id, 'url':url });
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_total_shares',
share_total_count_array:$share_total_count_data,
get_total_counts_nonce:monarchSettings.total_counts
},
beforeSend: function(data){
append_to.append('<span class="et_social_placeholder"></span>');
},
success: function(data){
append_to.find('span.et_social_placeholder').remove();
append_to.append(data);
}});
}
function append_follow_counts($current_area){
var network=$current_area.data('network'),
min_count=$current_area.data('min_count'),
index=$current_area.data('index'),
append_to=$current_area;
$follow_count_data=JSON.stringify({ 'network':network, 'min_count':min_count, 'index':index });
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_follow_counts',
follow_count_array:$follow_count_data,
get_follow_counts_nonce:monarchSettings.follow_counts
},
beforeSend: function(data){
append_to.append('<span class="et_social_placeholder"></span>');
},
success: function(data){
$current_area.find('span.et_social_placeholder').remove();
append_to.append(data);
}});
}
function append_total_follows($current_area){
var append_to=$current_area;
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_follow_total',
get_total_counts_nonce:monarchSettings.total_counts
},
beforeSend: function(data){
append_to.append('<span class="et_social_placeholder"></span>');
},
success: function(data){
append_to.find('span.et_social_placeholder').remove();
append_to.append(data);
}});
}
if($('.et_social_display_follow_counts').length){
$('.et_social_display_follow_counts').each(function(){
append_follow_counts($(this));
});
}
if($('.et_social_follow_total').length){
$('.et_social_follow_total').each(function(){
append_total_follows($(this));
});
}
if($('.et_social_total_share').length){
$('.et_social_total_share').each(function(){
append_total_shares($(this));
});
}
if($('.et_social_display_count').length){
$('.et_social_display_count').each(function(){
append_share_counts($(this));
});
}
if($('.et_social_media_wrapper').length&&$('.et_social_media_wrapper .et_social_totalcount').length){
$('.et_social_media_wrapper').each(function(){
update_total_media_shares($(this) );
});
}
if($('.et_social_media_wrapper').length&&$('.et_social_media_wrapper .et_social_withcounts').length){
$('.et_social_media_wrapper .et_social_share').each(function(){
var this_el=$(this),
media_url=this_el.closest('.et_social_media_wrapper').find('img').attr('src'),
post_id=this_el.data('post_id'),
social_network=this_el.data('social_name');
update_single_shares(this_el, media_url, post_id, social_network, 'media');
});
}
function update_total_media_shares($element){
if($('.et_social_totalcount').length){
var this_el=$element,
media_url=this_el.find('img').attr('src'),
post_id=this_el.find('.et_social_share').first().data('post_id'),
media_data=JSON.stringify({ 'media_url':media_url, 'post_id':post_id });
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_media_shares_total',
media_total:media_data,
get_media_shares_total_nonce:monarchSettings.media_total
},
success: function(data){
this_el.find('.et_social_totalcount_count').empty().append(data);
}});
}}
function update_single_shares($this_el, $media_url, $post_id, $network, $action){
if($('.et_social_withcounts').length){
var media_data=JSON.stringify({ 'media_url':$media_url, 'post_id':$post_id, 'network':$network, 'action':$action });
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'get_shares_single',
media_single:media_data,
get_media_shares_nonce:monarchSettings.media_single
},
success: function(data){
$this_el.find('.et_social_count span').not('.et_social_count_label').empty().append(data);
}});
}}
function setCookieExpire(days){
var ms=days*24*60*60*1000;
var date=new Date();
date.setTime(date.getTime() + ms);
return "; expires=" + date.toUTCString();
}
function checkCookieValue(cookieName, value){
return parseCookies()[cookieName]===value;
}
function parseCookies(){
var cookies=document.cookie.split('; ');
var ret={};
for (var i=cookies.length - 1; i >=0; i--){
var el=cookies[i].split('=');
ret[el[0]]=el[1];
}
return ret;
}
function set_cookie($expire){
cookieExpire=setCookieExpire($expire);
document.cookie='etSocialCookie=true' + cookieExpire;
}
function make_popup_visible($popup, $delay){
setTimeout(function(){
$popup.addClass('et_social_visible et_social_animated');
if($('.et_social_resize').length){
$('.et_social_resize').each(function(){
define_popup_position($(this) );
});
}}, $delay);
}
function auto_popup(this_el, delay){
var $current_popup_auto=this_el;
if(! $current_popup_auto.hasClass('et_social_animated') ){
var $cookies_expire_auto=$current_popup_auto.data('cookie_duration') ? $current_popup_auto.data('cookie_duration'):false,
$delay=delay;
if(( false!==$cookies_expire_auto&&! checkCookieValue('etSocialCookie', 'true') )||false==$cookies_expire_auto){
make_popup_visible($current_popup_auto, $delay);
if(false!==$cookies_expire_auto){
set_cookie($cookies_expire_auto);
}}
}}
if('true'==get_url_parameter('et_monarch_popup') ){
$('.et_social_after_comment').each(function(){
var $current_popup=$(this);
auto_popup($current_popup, 0);
});
}
if($('.et_social_auto_popup').length){
$('.et_social_auto_popup').each(function(){
var $current_popup_auto=$(this);
auto_popup($current_popup_auto, ''!==$current_popup_auto.data('delay') ? $current_popup_auto.data('delay') * 1000:0);
});
}
$('.et_social_pinterest_window .et_social_close').on('click', function(){
$('.et_social_pin_images_outer').fadeToggle(400);
});
$('body').on('click', '.et_social_icon_cancel', function(){
var this_el=$(this);
if(this_el.parent().hasClass('et_social_flyin') ){
$popup=this_el.parent();
}else{
$popup=this_el.parent().parent();
if($popup.hasClass('et_social_all_networks_popup') ){
all_networks_opened=0;
}}
$popup.addClass('et_social_fadeout');
setTimeout(function(){
$popup.remove();
}, 800);
return false;
});
if($('.et_monarch_after_order').length){
$('.et_social_after_purchase').each(function(){
var $current_popup=$(this);
if(! $current_popup.hasClass('et_social_animated') ){
var $cookies_expire=$current_popup.data('cookie_duration') ? $current_popup.data('cookie_duration'):false,
$delay=0;
if(( false!==$cookies_expire&&! checkCookieValue('etSocialCookie', 'true') )||false==$cookies_expire){
make_popup_visible($current_popup, $delay);
if(false!==$cookies_expire){
set_cookie($cookies_expire);
}}
}});
}
if($('.et_social_trigger_bottom').length){
$('.et_social_trigger_bottom').each(function(){
scroll_trigger($(this), true);
});
}
if($('.et_social_scroll').length){
$('.et_social_scroll').each(function(){
scroll_trigger($(this), false);
});
}
function scroll_trigger(this_el, is_bottom_trigger){
var current_popup_bottom=this_el;
if(! current_popup_bottom.hasClass('et_social_animated') ){
var	cookies_expire_bottom=current_popup_bottom.data('cookie_duration') ? current_popup_bottom.data('cookie_duration'):false;
if(true==is_bottom_trigger){
var scroll_trigger=$('.et_social_bottom_trigger').length ? $('.et_social_bottom_trigger').offset().top:$(document).height() - 500;
}else{
var scroll_pos=this_el.data('scroll_pos') > 100 ? 100:this_el.data('scroll_pos'),
scroll_trigger=100==scroll_pos ? $(document).height() - 10:$(document).height() * scroll_pos / 100;
}
$(window).on('scroll', function(){
if(( false!==cookies_expire_bottom&&! checkCookieValue('etSocialCookie', 'true') )||false==cookies_expire_bottom){
if($(window).scrollTop() + $(window).height() > scroll_trigger){
current_popup_bottom.addClass('et_social_visible et_social_animated');
if($('.et_social_resize').length){
$('.et_social_resize').each(function(){
define_popup_position($(this) );
});
}
if(false!==cookies_expire_bottom){
set_cookie(cookies_expire_bottom);
}}
}});
}}
if($('.et_social_trigger_idle').length){
$('.et_social_trigger_idle').each(function(){
var this_el=$(this);
if(! this_el.hasClass('et_social_animated') ){
var $cookies_expire_idle=this_el.data('cookie_duration') ? this_el.data('cookie_duration'):false,
$idle_timeout=''!==this_el.data('idle_timeout') ? this_el.data('idle_timeout') * 1000:30000;
if(( false!==$cookies_expire_idle&&! checkCookieValue('etSocialCookie', 'true') )||false==$cookies_expire_idle){
$(document).idleTimer($idle_timeout);
$(document).on("idle.idleTimer", function(){
make_popup_visible(this_el, 0);
});
if(false!==$cookies_expire_idle){
set_cookie($cookies_expire_idle);
}}
}});
}
$('.et_social_heading, .et_social_mobile_button').on('click', function(){
$this_mobile_div=$('.et_social_mobile');
$this_mobile_div.css({'display':'block' });
$('.et_social_mobile_button').removeClass('et_social_active_button');
if($this_mobile_div.hasClass('et_social_opened') ){
$this_mobile_div.find('.et_social_networks').slideToggle(600);
$this_mobile_div.removeClass('et_social_opened').addClass('et_social_closed');
$('.et_social_mobile_overlay').removeClass('et_social_visible_overlay');
$('.et_social_mobile_overlay').fadeToggle(600);
}else{
$this_mobile_div.removeClass('et_social_closed').addClass('et_social_opened');
$this_mobile_div.find('.et_social_networks').slideToggle(600);
$('.et_social_mobile_overlay').addClass('et_social_visible_overlay').css({ 'display':'block' });
}});
$('.et_social_mobile .et_social_close').on('click', function(){
$mobile_div=$('.et_social_mobile');
$mobile_div.fadeToggle(600);
$('.et_social_mobile_button').addClass('et_social_active_button');
if($mobile_div.hasClass('et_social_opened') ){
$('.et_social_mobile_overlay').fadeToggle(600);
$mobile_div.removeClass('et_social_opened');
$mobile_div.find('.et_social_networks').fadeToggle(600);
}});
if($('.et_social_inline').length){
if($('body').hasClass('et_pb_pagebuilder_layout') ){
var top_inline=$('.et_social_inline_top'),
bottom_inline=$('.et_social_inline_bottom'),
divi_container='<div class="et_pb_row"><div class="et_pb_column et_pb_column_4_4"></div></div>';
if($('.et-l--post').first().length > 0){
var $sections=$('.et-l--post .et_pb_section').not('.et_pb_fullwidth_section');
}else{
var $sections=$('.et_pb_section:not(.et-l .et_pb_section)').not('.et_pb_fullwidth_section');
}
if($sections.length > 0&&top_inline.length){
$sections.first().prepend(divi_container).find('.et_pb_row').first().find('.et_pb_column').append(top_inline);
}
if($sections.length > 0&&bottom_inline.length){
$sections.last().append(divi_container).find('.et_pb_row').last().find('.et_pb_column').append(bottom_inline);
}}
}
function define_popup_position($this_popup){
setTimeout(function(){
var this_popup=$this_popup,
networks_div=this_popup.find('.et_social_networks'),
header_height=this_popup.find('.et_social_header').outerHeight()||0,
total_count_height=this_popup.find('.et_social_totalcount').height(),
extra_height=0 < total_count_height ? 20:0;
this_popup.height(this_popup.find('.et_social_icons_container').innerHeight() + header_height + total_count_height + 20 + extra_height);
var	popup_max_height=this_popup.hasClass('et_social_popup_content') ? $(window).height():$(window).height() - 60;
if(this_popup.hasClass('et_social_popup_content')&&768 < $(window).width()){
popup_max_height=popup_max_height - 50;
}
this_popup.css({ 'max-height':popup_max_height + 'px' });
if(this_popup.hasClass('et_social_popup_content') ){
var top_position=$(window).height() / 2 - this_popup.innerHeight() / 2;
this_popup.css({ 'top':top_position + 'px' });
}
var networks_div_height=this_popup.height() - header_height + total_count_height - extra_height;
networks_div.height(networks_div_height);
}, 400);
}
function set_mobile_sidebar_height(){
setTimeout(function(){
var	mobile_div=$('.et_social_mobile');
if(!mobile_div.hasClass('et_social_opened') ){
$('.et_social_mobile .et_social_networks').css({'display':'block'});
}
if($('.et_social_active_button').length){
mobile_div.css({'display':'block'});
}
var inner_contatiner_height=mobile_div.find('.et_social_icons_container').innerHeight() + 45;
if(!mobile_div.hasClass('et_social_opened') ){
$('.et_social_mobile .et_social_networks').css({'display':'none'});
}
if($('.et_social_active_button').length){
mobile_div.css({'display':'none'});
}
mobile_div.find('.et_social_networks').css({ 'max-height':inner_contatiner_height + 'px', 'height':inner_contatiner_height + 'px' });
if($(window).height() < inner_contatiner_height){
var inner_height=$(window).height() - mobile_div.find('.et_social_heading').innerHeight() + 10;
mobile_div.find('.et_social_networks').css({ 'height':inner_height + 'px' });
}}, 400);
}
function set_sidebar_position(){
if($('.et_social_sidebar_networks').length){
var this_sidebar=$('.et_social_sidebar_networks'),
top_position=$(window).height() / 2 - this_sidebar.innerHeight() / 2;
top_position=0 > top_position ? 0:top_position;
this_sidebar.css({ 'top':top_position + 'px' });
}}
function set_media_wrapper_size(){
if($('.et_social_media_wrapper').length){
$('.et_social_media_wrapper').each(function(){
var this_wrapper=$(this),
this_wrapper_media=this_wrapper.find('.et_social_media'),
this_image=this_wrapper.find('img'),
image_position=this_image.position(),
image_left_offset=typeof image_position!=='undefined' ? image_position.left:0,
this_image_height=this_image.height(),
this_image_width=this_image.width(),
this_wrapper_networks_height=this_wrapper.find('.et_social_networks').innerHeight();
this_wrapper.addClass(this_image.attr('class') );
this_wrapper_media.css({ 'max-height':this_image_height + 'px' });
this_wrapper_media.css({ 'height':(this_wrapper_networks_height + 50) + 'px' });
this_wrapper_media.width(this_image_width - 80);
if(0!==image_left_offset){
this_wrapper_media.css({ 'left':(image_left_offset + 20) + 'px' });
}});
et_pb_fix_gallery_slider_icons_size();
}}
function et_pb_fix_gallery_wrapper(){
var $media_wrappers_inside_gallery=$('.et_pb_gallery_grid .et_social_media_wrapper');
if(0 > $media_wrappers_inside_gallery.length){
return;
}
$media_wrappers_inside_gallery.each(function(){
var $this_wrapper=$(this);
var $gallery_item=$this_wrapper.closest('.et_pb_gallery_image');
var $gallery_overlay=$gallery_item.find('.et_overlay');
if(0 < $gallery_overlay.length){
$this_wrapper.append($gallery_overlay);
}});
}
function et_pb_fix_gallery_slider_icons_size(){
var $gallery_slider_icons=$('.et_pb_gallery_fullwidth .et_social_media_wrapper');
if(0 > $gallery_slider_icons.length){
return;
}
var $all_galleries=$('.et_pb_gallery_fullwidth');
$all_galleries.each(function(){
var $this_gallery=$(this);
var $this_gallery_media=$this_gallery.find('.et_social_media_wrapper .et_social_media');
if(0 > $this_gallery_media.length){
return;
}
var $first_icon_wrapper=$this_gallery_media.first();
var icons_width=$first_icon_wrapper.width();
var icons_height=$first_icon_wrapper.css('height');
var icons_max_height=$first_icon_wrapper.css('max-height');
$this_gallery_media.width(icons_width - 80);
$this_gallery_media.height(icons_height);
$this_gallery_media.css({ 'max-height':icons_max_height + 'px' });
});
}
$('body').on('click', '.et_social_open_all', function(){
all_networks_opened++;
if(1==all_networks_opened){
var this_button=$(this),
page_id=this_button.data('page_id'),
permalink=this_button.data('permalink'),
title=this_button.data('title'),
media=typeof this_button.data('media')!=='undefined' ? this_button.data('media'):'',
is_popup='popup'==this_button.data('location') ? 'true':'false';
$.ajax({
type: 'POST',
url: monarchSettings.ajaxurl,
data: {
action:'generate_all_networks_popup',
all_networks_page_id:page_id,
all_networks_link:permalink,
all_networks_title:title,
all_networks_media:media,
is_popup:is_popup,
generate_all_window_nonce:monarchSettings.generate_all_window_nonce
},
success: function(data){
if('false'==is_popup){
$('body').append(data);
make_popup_visible($('.et_social_all_networks_popup'), 1);
}else{
var popup_container=this_button.parent().closest('.et_social_popup_content');
this_button.parent().replaceWith(data);
define_popup_position(popup_container);
all_networks_opened=0;
}}
});
}
return false;
});
set_mobile_sidebar_height();
set_sidebar_position();
$(window).on('resize', ()=> {
if($('.et_social_resize').length){
$('.et_social_resize').each(function(){
define_popup_position($(this) );
});
}
if($('.et_social_mobile')){
set_mobile_sidebar_height();
}
if($('.et_social_sidebar_networks').length){
set_sidebar_position();
}
set_media_wrapper_size();
});
$('.et_social_hide_sidebar').on('click', function(){
$('.et_social_hide_sidebar').toggleClass('et_social_hidden_sidebar');
$('.et_social_sidebar_networks').toggleClass('et_social_hidden_sidebar et_social_visible_sidebar');
});
$(window).on('load', function(){
set_media_wrapper_size();
if($('.et_social_pin_images').length&&($('.et_social_all_button').length||$('.et_social_pinterest').length) ){
var pin_container=$('.et_social_pin_images'),
permalink=pin_container.data('permalink'),
title=pin_container.data('title'),
post_id=pin_container.data('post_id'),
$i=0;
$('img').each(function(){
if(! $(this).hasClass('avatar') ){
var this_img=$(this).attr('src'),
this_alt=$(this).attr('alt');
if(''!=this_img){
var	pin_link='http://www.pinterest.com/pin/create/button/?url=' + permalink + '&media=' + this_img + '&description=' + title,
this_img_container='<div class="et_social_pin_image"><a href="' + pin_link + '" rel="nofollow" class="et_social_icon et_social_share" data-social_name="pinterest" data-post_id="' + post_id + '" data-social_type="share"><img src="' + this_img + '" alt="' + this_alt + '"/><span class="et_social_pin_overlay et_social_icon"></span></a></div>';
$('.et_social_pin_images').append(this_img_container);
$i++;
}}
});
if(0==$i){
$('.et_social_pin_images').append(monarchSettings.no_img_message);
}}
});
});
})(jQuery);
const UAGBBlockPositioning={init(t,e){const s=document.querySelector(e);s?.classList.contains("uagb-position__sticky")&&UAGBBlockPositioning.handleSticky(s,t)},handleSticky(t,e){var s=()=>{return document.querySelector("#wpadminbar")?.offsetHeight||0},p=()=>{"undefined"!=typeof AOS&&e?.UAGAnimationType&&(t.dataset.aos=e?.UAGAnimationType,t.dataset.aosDuration=e?.UAGAnimationTime,t.dataset.aosDelay=e?.UAGAnimationDelay,t.dataset.aosEasing=e?.UAGAnimationEasing,t.dataset.aosOnce=!0,setTimeout(()=>{AOS.refreshHard()},100))};const o=t.getBoundingClientRect(),y=e?.isBlockRootParent?null:t.parentElement,i=((t,e,s)=>{const o=document.createElement("div"),i=(o.style.height=e.height+"px",o.style.boxSizing="border-box",window.getComputedStyle(t));return s?(o.style.width="100%",o.style.maxWidth=i.getPropertyValue("max-width")||e.width+"px",o.style.padding=i.getPropertyValue("padding")||0,o.style.margin=i.getPropertyValue("margin")||0,o.style.border=i.getPropertyValue("border")||0,o.style.borderColor="transparent"):(o.style.width=e.width+"px",o.style.margin=i.getPropertyValue("margin")||0),o})(t,o,y);let n,a,l,r;const c={top:0,bottom:0},d={top:0,right:0,bottom:0,left:0};if(e?.UAGStickyRestricted){r=y.getBoundingClientRect();const g=window.getComputedStyle(y);d.top=parseInt(g.getPropertyValue("padding-top")||0,10),d.bottom=parseInt(g.getPropertyValue("padding-bottom")||0,10),c.top=r.top+(window.pageYOffset||0)+d.top,c.bottom=r.bottom+(window.pageYOffset||0)-d.bottom-o.height-s()-(e?.UAGStickyOffset||0)}"bottom"===e?.UAGStickyLocation?(n=o.top+(window.pageYOffset||0)-window.innerHeight+o.height+(e?.UAGStickyOffset||0),a=`${e?.UAGStickyOffset||0}px`,(l=void 0!==window.pageYOffset?window.pageYOffset:document.body.scrollTop)<=n&&!t.classList.contains("uagb-position__sticky--stuck")&&(t.parentNode.insertBefore(i,t),t.classList.add("uagb-position__sticky--stuck"),t.style.bottom=`calc(${a} - ${window.innerHeight}px)`,t.style.left=o.left+"px",t.style.width=o.width+"px",t.style.zIndex="999",setTimeout(()=>{t.style.bottom=a},50)),p(),window.addEventListener("scroll",()=>{(l=void 0!==window.pageYOffset?window.pageYOffset:document.body.scrollTop)<=n?t.classList.contains("uagb-position__sticky--stuck")||(t.parentNode.insertBefore(i,t),t.classList.add("uagb-position__sticky--stuck"),t.style.bottom=a,t.style.left=o.left+"px",t.style.width=o.width+"px",t.style.zIndex="999"):l>n&&t.classList.contains("uagb-position__sticky--stuck")&&(t.parentNode.removeChild(i),t.classList.remove("uagb-position__sticky--stuck"),t.style.bottom="",t.style.left="",t.style.width="",t.style.zIndex="")})):(n=o.top+(window.pageYOffset||0)-s()-(e?.UAGStickyOffset||0),a=s()+(e?.UAGStickyOffset||0)+"px",(l=void 0!==window.pageYOffset?window.pageYOffset:document.body.scrollTop)>=n&&!t.classList.contains("uagb-position__sticky--stuck")&&(t.parentNode.insertBefore(i,t),t.classList.add("uagb-position__sticky--stuck"),e?.UAGStickyRestricted&&l>=c.bottom?(t.classList.remove("uagb-position__sticky--stuck"),t.classList.add("uagb-position__sticky--restricted"),t.style.top="",t.style.bottom=d.bottom+"px",t.style.left=`${i?.offsetLeft||0}px`):(t.style.top=`calc(${a} - ${window.innerHeight}px)`,t.style.left=o.left+"px",t.style.top=a),t.style.width=o.width+"px",t.style.zIndex="999"),p(),window.addEventListener("scroll",()=>{(l=void 0!==window.pageYOffset?window.pageYOffset:document.body.scrollTop)>=n?t.classList.contains("uagb-position__sticky--stuck")||t.classList.contains("uagb-position__sticky--restricted")?e?.UAGStickyRestricted&&!t.classList.contains("uagb-position__sticky--restricted")&&l>=c.bottom?(t.classList.remove("uagb-position__sticky--stuck"),t.classList.add("uagb-position__sticky--restricted"),t.style.top="",t.style.bottom=d.bottom+"px",t.style.left=`${i?.offsetLeft||0}px`):t.classList.contains("uagb-position__sticky--restricted")&&l<c.bottom&&(t.classList.remove("uagb-position__sticky--restricted"),t.classList.add("uagb-position__sticky--stuck"),t.style.top=a,t.style.bottom="",t.style.left=o.left+"px",t.style.width=o.width+"px",t.style.zIndex="999"):(t.parentNode.insertBefore(i,t),t.classList.add("uagb-position__sticky--stuck"),t.style.top=a,t.style.left=o.left+"px",t.style.width=o.width+"px",t.style.zIndex="999"):l<n&&t.classList.contains("uagb-position__sticky--stuck")&&(t.parentNode.removeChild(i),t.classList.remove("uagb-position__sticky--stuck"),t.style.top="",t.style.left="",t.style.width="",t.style.zIndex="")}))}};
UAGBButtonChild={init(e){const t=document.querySelector(e);t&&(t.addEventListener("focusin",()=>{document.addEventListener("keydown",this.handleKeyDown)}),t.addEventListener("focusout",()=>{document.removeEventListener("keydown",this.handleKeyDown)}))},handleKeyDown(e){" "!==e.key&&"Spacebar"!==e.key||"A"===e.target.tagName&&e.target.classList.contains("uagb-buttons-repeater")&&(e.preventDefault(),e.target.click())}};
document.addEventListener("DOMContentLoaded", function(){ window.addEventListener('load', function(){
UAGBButtonChild.init('.uagb-block-53f39a62');
});
window.addEventListener('load', function(){
UAGBButtonChild.init('.uagb-block-9f5d84bb');
});
window.addEventListener('load', function(){
UAGBButtonChild.init('.uagb-block-1d3a2cf2');
});
window.addEventListener('load', function(){
UAGBButtonChild.init('.uagb-block-3accd50b');
});
window.addEventListener('load', function(){
UAGBButtonChild.init('.uagb-block-d2bc7916');
});
});
astraSyncMobileMenuState=function(e){for(var t=document.querySelectorAll("#masthead #ast-mobile-header, #ast-fixed-header #ast-mobile-header"),o=0;o<t.length;o++){var a=t[o].querySelector(".main-header-bar-navigation"),s=t[o].querySelector(".main-header-menu-toggle");a&&(a.classList.toggle("toggle-on",e),a.style.display=e?"block":""),s&&(s.classList.toggle("toggled",e),s.setAttribute("aria-expanded",e?"true":"false"))}document.body.classList.toggle("ast-main-header-nav-open",e)},astraToggleSetupPro=function(e,t,o){var a,s,n,r=!1;if(0<(a="off-canvas"===e||"full-width"===e?(s=document.querySelectorAll("#ast-mobile-popup, #ast-mobile-header"),(n=t.classList.contains("ast-header-break-point")?document.querySelectorAll("#ast-mobile-header .main-header-menu-toggle"):document.querySelectorAll("#ast-desktop-header .main-header-menu-toggle")).length):t.classList.contains("ast-header-break-point")?(s=document.querySelectorAll("#ast-mobile-header"),(r=!(0<(a=(n=document.querySelectorAll("#ast-mobile-header .main-header-menu-toggle")).length)))?1:a):(s=document.querySelectorAll("#ast-desktop-header"),(n=document.querySelectorAll("#ast-desktop-header .main-header-menu-toggle")).length))||r)for(var i=0;i<a;i++)if(r||(n[i].setAttribute("data-index",i),o[i])||(o[i]=n[i],n[i].removeEventListener("click",astraNavMenuToggle),n[i].addEventListener("click",astraNavMenuToggle,!1)),void 0!==s[i])for(var l,c=0;c<s.length;c++)if(0<(l=document.querySelector("header.site-header").classList.contains("ast-builder-menu-toggle-link")?s[c].querySelectorAll("ul.main-header-menu .menu-item-has-children > .menu-link, ul.main-header-menu .ast-menu-toggle"):s[c].querySelectorAll("ul.main-header-menu .ast-menu-toggle")).length)for(var d=0;d<l.length;d++)l[d].removeEventListener("click",AstraToggleSubMenu),l[d].addEventListener("click",AstraToggleSubMenu,!1)},astraNavMenuTogglePro=function(e,t,o,a){e.preventDefault();var s=e.target.closest("#ast-desktop-header"),n=document.querySelector("#masthead > #ast-desktop-header .ast-desktop-header-content"),r=(s=null!=s&&""!==s?s.querySelector(".main-header-menu-toggle"):document.querySelector("#masthead > #ast-desktop-header .main-header-menu-toggle"),document.querySelector("#masthead > #ast-desktop-header .ast-desktop-header-content .main-header-bar-navigation"));if("desktop"===e.currentTarget.trigger_type)null!==r&&""!==r&&void 0!==r&&(astraToggleClass(r,"toggle-on"),r.classList.contains("toggle-on")?r.style.display="block":r.style.display=""),astraToggleClass(s,"toggled"),s.classList.contains("toggled")?(t.classList.add("ast-main-header-nav-open"),"dropdown"===o&&(n.style.display="block")):(t.classList.remove("ast-main-header-nav-open"),n.style.display="none");else{e=a.closest("#ast-fixed-header")||document.getElementById("masthead");if(e)for(var i=e.querySelectorAll("#ast-mobile-header .main-header-bar-navigation .menu-item-has-children"),l=0;l<i.length;l++){i[l].classList.remove("ast-submenu-expanded");for(var c=i[l].querySelectorAll(".sub-menu"),d=0;d<c.length;d++)c[d].style.display="none"}-1!==(a.getAttribute("class")||"").indexOf("main-header-menu-toggle")&&(r=!a.classList.contains("toggled"),astraSyncMobileMenuState(r))}};let accountMenuToggle=function(){let n=astraAddon.hf_account_action_type&&"menu"===astraAddon.hf_account_action_type,r=n&&astraAddon.hf_account_show_menu_on&&"click"===astraAddon.hf_account_show_menu_on;var e=document.querySelectorAll(".ast-header-account-wrap");e&&e.forEach(t=>{let o=t.querySelector(".ast-account-nav-menu");function e(e){(r||n&&document.querySelector("body").classList.contains("ast-header-break-point"))&&o&&!t.contains(e.target)&&(o.style.right="",o.style.left="")}t._accountPointerUpHandler||(t._accountPointerUpHandler=e,document.addEventListener("pointerup",e));var a,s=t.querySelector(".ast-header-account-link");s&&(a=function(e){(r||n&&document.querySelector("body").classList.contains("ast-header-break-point"))&&(headerSelectionPosition=e.target.closest(".site-header-section"))&&(headerSelectionPosition.classList.contains("site-header-section-left")?(o.style.left=""===o.style.left?"-100%":"",o.style.right=""===o.style.right?"auto":""):(o.style.right=""===o.style.right?"-100%":"",o.style.left=""===o.style.left?"auto":""))},s._accountClickHandler||(s._accountClickHandler=a,s.addEventListener("click",a)))})},astraColorSwitcher={...astraAddon?.colorSwitcher,init:function(){this?.isInit&&(this.switcherButtons=document.querySelectorAll(".ast-builder-color-switcher .ast-switcher-button"),this.switcherButtons?.length)&&(this.switcherButtons?.forEach(e=>{e?.addEventListener("click",this.toggle)}),this.isDarkPalette&&"system"===this.defaultMode&&this.detectSystemColorScheme(),this.isSwitched)&&this.switchLogo()},detectSystemColorScheme:function(){null===this.getCookie("astraColorSwitcherState")&&window.matchMedia("(prefers-color-scheme: dark)").matches&&!this.isSwitched&&this.toggle()},toggle:function(e){e?.preventDefault();e=astraColorSwitcher;e.isSwitched=!e.isSwitched,e.setCookie("astraColorSwitcherState",e.isSwitched,90),e?.forceReload?window.location.reload():(e.switchPaletteColors(),e.switchIcon(),e.switchLogo(),e.isDarkPalette&&e.handleDarkModeCompatibility())},switchPaletteColors:function(){(this.isSwitched?this?.palettes?.switched:this?.palettes?.default)?.forEach((e,t)=>{document.documentElement.style.setProperty("--ast-global-color-"+t,e),astraAddon?.is_elementor_active&&document.documentElement.style.setProperty("--e-global-color-astglobalcolor"+t,e)})},switchIcon:function(){this.switcherButtons?.forEach(o=>{var[a,s]=o?.querySelectorAll(".ast-switcher-icon");if(a&&s){let[e,t]=this.isSwitched?[s,a]:[a,s];o?.classList.add("ast-animate"),setTimeout(()=>{e?.classList.add("ast-current"),t?.classList.remove("ast-current")},100),setTimeout(()=>o?.classList.remove("ast-animate"),200)}a=this.isSwitched?"defaultText":"switchedText";o?.setAttribute("aria-label",o?.dataset?.[a]||"Switch color palette.")})},switchLogo:function(){this.isDarkPalette&&this?.logos?.switched&&this?.logos?.default&&this.switchColorSwitcherLogo()},switchColorSwitcherLogo:function(){var e,t;let o=[];for(e of[".custom-logo-link:not(.sticky-custom-logo):not(.transparent-custom-logo) .custom-logo",".site-branding .site-logo-img img:not(.ast-sticky-header-logo)",".ast-site-identity .site-logo-img img:not(.ast-sticky-header-logo)"]){var a=document.querySelectorAll(e);if(0<a.length&&0<(o=Array.from(a).filter(e=>!(e.closest(".ast-sticky-header-logo")||e.closest(".sticky-custom-logo")||e.closest(".transparent-custom-logo")||e.classList.contains("ast-sticky-header-logo")))).length)break}o.length&&(t=this.isSwitched?this.logos.switched:this.logos.default)&&this.updateLogoImages(o,t)},updateLogoImages:function(e,o){e.forEach(e=>{var t;e&&e.src!==o&&((t=new Image).onload=function(){e.src=o,e.hasAttribute("srcset")&&e.removeAttribute("srcset"),e.hasAttribute("data-src")&&e.setAttribute("data-src",o)},t.onerror=function(){e.src=o},t.src=o)})},handleDarkModeCompatibility:function(){document.body.classList.toggle("astra-dark-mode-enable")},setCookie:(e,t,o)=>{var a=new Date;a.setTime(a.getTime()+24*o*60*60*1e3),document.cookie=`${e}=${t}; expires=${a.toUTCString()}; path=/`},getCookie:e=>{var t;for(t of document.cookie.split("; ")){var[o,a]=t.split("=");if(o===e)return a}return null}};var accountPopupTrigger=function(){if("undefined"!=typeof astraAddon&&"login"===astraAddon.hf_account_logout_action){var e,o=document.querySelectorAll(".ast-account-action-login");if(o.length){let t=document.querySelector("#ast-hb-account-login-wrap");t&&(e=document.querySelector("#ast-hb-login-close"),o.forEach(function(e){e.addEventListener("click",function(e){e.preventDefault(),t.classList.add("show")})}),e)&&e.addEventListener("click",function(e){e.preventDefault(),t.classList.remove("show")})}}};document.addEventListener("astPartialContentRendered",function(){accountMenuToggle(),accountPopupTrigger()}),window.addEventListener("load",function(){accountMenuToggle(),accountPopupTrigger(),astraColorSwitcher.init()}),document.addEventListener("astLayoutWidthChanged",function(){accountMenuToggle(),accountPopupTrigger()}),document.addEventListener("click",function(e){var t,e=e.target.closest("a");e&&(t=e.getAttribute("href"))&&-1!==t.indexOf("#")&&e.closest("#masthead #ast-mobile-header, #ast-fixed-header #ast-mobile-header")&&setTimeout(function(){astraSyncMobileMenuState(!1)},20)});((o,r)=>{var s="astHookExtSticky",i=r.document,a=(jQuery(r).outerWidth(),jQuery(r).width()),n={dependent:[],max_width:"",site_layout:"",break_point:920,admin_bar_height_lg:32,admin_bar_height_sm:46,admin_bar_height_xs:0,stick_upto_scroll:0,gutter:0,wrap:"<div></div>",body_padding_support:!0,html_padding_support:!0,active_shrink:!1,shrink:{padding_top:"",padding_bottom:""},sticky_on_device:"desktop",header_style:"none",hide_on_scroll:"no"};function e(t,e){this.element=t,this.options=o.extend({},n,e),this._defaults=n,this._name=s,"1"==this.options.hide_on_scroll&&(this.navbarHeight=o(t).outerHeight()),this.lastScrollTop=0,this.delta=5,this.should_stick=!0,this.hideScrollInterval="",this.init()}e.prototype.stick_me=function(t,e){var o=jQuery(t.element),s=jQuery(r).outerWidth(),i=parseInt(t.options.stick_upto_scroll),a=parseInt(o.parent().attr("data-stick-maxwidth")),n=parseInt(o.parent().attr("data-stick-gutter"));"enabled"==(astraAddon.hook_sticky_header||"")&&(!("desktop"==t.options.sticky_on_device&&astraAddon.hook_custom_header_break_point>s||"mobile"==t.options.sticky_on_device&&astraAddon.hook_custom_header_break_point<=s)&&jQuery(r).scrollTop()>i?"none"==t.options.header_style&&("enabled"==t.options.active_shrink?(t.hasShrink(t,"stick"),i="none",o.hasClass("ast-custom-header")||(i=n),o.parent().css("min-height",o.outerHeight()),o.addClass("ast-header-sticky-active").stop().css({"max-width":a,top:i,"padding-top":t.options.shrink.padding_top,"padding-bottom":t.options.shrink.padding_bottom})):(t.hasShrink(t,"stick"),o.parent().css("min-height",o.outerHeight()),o.addClass("ast-header-sticky-active").stop().css({"max-width":a,top:n,"padding-top":t.options.shrink.padding_top,"padding-bottom":t.options.shrink.padding_bottom})),o.addClass("ast-sticky-shrunk").stop()):t.stickRelease(t)),"enabled"==(astraAddon.hook_sticky_footer||"")&&("desktop"==t.options.sticky_on_device&&astraAddon.hook_custom_footer_break_point>s||"mobile"==t.options.sticky_on_device&&astraAddon.hook_custom_footer_break_point<=s?t.stickRelease(t):(jQuery("body").addClass("ast-footer-sticky-active"),o.parent().css("min-height",o.outerHeight()),o.stop().css({"max-width":a})))},e.prototype.update_attrs=function(){var o,t=this,e=jQuery(t.element),s=parseInt(t.options.gutter),i=t.options.max_width;"none"==t.options.header_style&&(o=e.offset().top||0),"ast-box-layout"!=t.options.site_layout&&(i=jQuery("body").width()),t.options.dependent&&jQuery.each(t.options.dependent,function(t,e){jQuery(e).length&&"on"==jQuery(e).parent().attr("data-stick-support")&&(dependent_height=jQuery(e).outerHeight(),s+=parseInt(dependent_height),o-=parseInt(dependent_height))}),t.options.admin_bar_height_lg&&jQuery("#wpadminbar").length&&782<a&&(s+=parseInt(t.options.admin_bar_height_lg),o-=parseInt(t.options.admin_bar_height_lg)),t.options.admin_bar_height_sm&&jQuery("#wpadminbar").length&&600<=a&&a<=782&&(s+=parseInt(t.options.admin_bar_height_sm),o-=parseInt(t.options.admin_bar_height_sm)),t.options.admin_bar_height_xs&&jQuery("#wpadminbar").length&&(s+=parseInt(t.options.admin_bar_height_xs),o-=parseInt(t.options.admin_bar_height_xs)),t.options.body_padding_support&&(s+=parseInt(jQuery("body").css("padding-top"),10),o-=parseInt(jQuery("body").css("padding-top"),10)),t.options.html_padding_support&&(s+=parseInt(jQuery("html").css("padding-top"),10),o-=parseInt(jQuery("html").css("padding-top"),10)),t.options.stick_upto_scroll=o,"none"==t.options.header_style&&e.parent().css("min-height",e.outerHeight()).attr("data-stick-gutter",parseInt(s)).attr("data-stick-maxwidth",parseInt(i))},e.prototype.hasShrink=function(t,e){o(r).scrollTop()>jQuery(t.element).outerHeight()?jQuery("body").addClass("ast-shrink-custom-header"):jQuery("body").removeClass("ast-shrink-custom-header")},e.prototype.stickRelease=function(t){var e=jQuery(t.element);"enabled"==(astraAddon.hook_sticky_header||"")&&"none"==t.options.header_style&&(e.removeClass("ast-header-sticky-active").stop().css({"max-width":"",top:"",padding:""}),e.parent().css("min-height",""),e.removeClass("ast-sticky-shrunk").stop()),"enabled"==(astraAddon.hook_sticky_footer||"")&&jQuery("body").removeClass("ast-footer-sticky-active")},e.prototype.init=function(){var e,t;jQuery(this.element)&&(e=this,t=jQuery(e.element),parseInt(e.options.gutter),t.position().top,"none"==e.options.header_style&&t.wrap(e.options.wrap).parent().css("min-height",t.outerHeight()).attr("data-stick-support","on").attr("data-stick-maxwidth",parseInt(e.options.max_width)),e.update_attrs(),jQuery(r).on("resize",function(){e.stickRelease(e),e.update_attrs(),e.stick_me(e)}),jQuery(r).on("scroll",function(){e.stick_me(e,"scroll")}),jQuery(i).ready(function(t){e.stick_me(e)}))},o.fn[s]=function(t){return this.each(function(){o.data(this,"plugin_"+s)||o.data(this,"plugin_"+s,new e(this,t))})};var d=jQuery("body").width(),_=astraAddon.site_layout||"",h=astraAddon.hook_sticky_header||"",p=astraAddon.hook_shrink_header||"";sticky_header_on_devices=astraAddon.hook_sticky_header_on_devices||"desktop",site_layout_box_width=astraAddon.site_layout_box_width||1200,hook_sticky_footer=astraAddon.hook_sticky_footer||"",sticky_footer_on_devices=astraAddon.hook_sticky_footer_on_devices||"desktop","ast-box-layout"===_&&(d=parseInt(site_layout_box_width)),jQuery(i).ready(function(t){"enabled"==h&&jQuery(".ast-custom-header").astHookExtSticky({sticky_on_device:sticky_header_on_devices,header_style:"none",site_layout:_,max_width:d,active_shrink:p}),"enabled"==hook_sticky_footer&&jQuery(".ast-custom-footer").astHookExtSticky({sticky_on_device:sticky_footer_on_devices,max_width:d,site_layout:_,header_style:"none"})})})(jQuery,window);((n,h)=>{var a="astExtSticky",l=h.document,r=jQuery(h).width(),c=astraAddon.header_builder_active,s={dependent:[],max_width:"",site_layout:"",break_point:920,admin_bar_height_lg:32,admin_bar_height_sm:46,admin_bar_height_xs:0,stick_upto_scroll:0,gutter:0,wrap:"<div></div>",body_padding_support:!0,html_padding_support:!0,shrink:{padding_top:"",padding_bottom:""},sticky_on_device:"desktop",header_style:"none",hide_on_scroll:"no"},i=0,p=null!==l.querySelector("#ast-hb-account-login-wrap");function t(e,t){this.element=e,this.options=n.extend({},s,t),this._defaults=s,this._name=a,"1"==this.options.hide_on_scroll&&(this.navbarHeight=n(e).outerHeight()),this.lastScrollTop=0,this.delta=5,this.should_stick=!0,this.hideScrollInterval="",this.init()}t.prototype.stick_me=function(e,t){var a,s,i,d,r,o=jQuery(e.element);h.innerWidth;stick_upto_scroll=parseInt(e.options.stick_upto_scroll),max_width=parseInt(o.parent().attr("data-stick-maxwidth")),gutter=parseInt(o.parent().attr("data-stick-gutter")),aboveHeaderSelectorValue=gutter,c&&astraAddon.header_main_shrink&&((o.hasClass("ast-stick-primary-below-wrapper")||o.hasClass("ast-primary-header"))&&1==astraAddon.header_above_stick&&0<gutter&&(gutter-=10),a=l.querySelector(".ast-above-header-bar"),"1"===astraAddon.header_above_stick)&&null!==a&&(a=a.getBoundingClientRect().height+parseInt(a.parentNode.getAttribute("data-stick-gutter")),o.hasClass("ast-stick-primary-below-wrapper")||o.hasClass("ast-primary-header"))&&0<gutter&&(gutter=a),"desktop"===e.options.sticky_on_device&&jQuery("body").hasClass("ast-header-break-point")||"mobile"===e.options.sticky_on_device&&!jQuery("body").hasClass("ast-header-break-point")?e.stickRelease(e):(stick_upto_scroll<0&&(stick_upto_scroll=0),a=0<l.getElementsByClassName("elementor-motion-effects-parent").length,jQuery(h).scrollTop()>stick_upto_scroll?(s=o,c&&(r=o.closest(".ast-mobile-header-wrap"),i=o.closest("#ast-desktop-header"),r=0===r.length?o.find(".ast-mobile-header-wrap"):r,i=0===i.length?o.find("#ast-desktop-header"):i,r.find(".ast-mobile-header-content").css("top",o.outerHeight()+gutter),"ast-box-layout"==e.options.site_layout?(d=jQuery("body").width(),r.find(".ast-mobile-header-content").css("width",d)):r.find(".ast-mobile-header-content").css("width",max_width),i.find(".ast-desktop-header-content").css("top",o.outerHeight()+gutter),i.find(".ast-desktop-header-content").css("width",max_width)),"1"===e.options.hide_on_scroll?e.hasScrolled(e,"stick"):"none"==e.options.header_style?(a||o.parent().css("min-height",o.outerHeight()),l.querySelector("body").classList.contains("fl-builder-edit")||o.addClass("ast-sticky-active").stop().css({top:gutter}),o.addClass("ast-sticky-active").stop().css({"max-width":max_width,"padding-top":e.options.shrink.padding_top,"padding-bottom":e.options.shrink.padding_bottom}),(o.hasClass("ast-stick-primary-below-wrapper")||o.hasClass("ast-primary-header"))&&1==astraAddon.header_above_stick&&o.closest("#ast-desktop-header").find(".ast-above-header-bar").outerHeight()<70&&o.parent().css("min-height",o.outerHeight()),o.addClass("ast-sticky-shrunk").stop(),n(l).trigger("addStickyClass"),s.addClass("ast-header-sticked")):"slide"==e.options.header_style?(s.css({top:gutter}),s.addClass("ast-header-slide"),s.css("visibility","visible"),s.addClass("ast-sticky-active").stop().css({transform:p?"none":"translateY(0)"}),n("html").addClass("ast-header-stick-slide-active"),n(l).trigger("addStickyClass"),s.addClass("ast-header-sticked")):"fade"==e.options.header_style&&(s.css({top:gutter}),s.addClass("ast-header-fade"),s.css("visibility","visible"),s.addClass("ast-sticky-active").stop().css({opacity:"1"}),n("html").addClass("ast-header-stick-fade-active"),n(l).trigger("addStickyClass"),s.addClass("ast-header-sticked"))):(e.stickRelease(e),c&&(r=0===(r=o.closest(".ast-mobile-header-wrap")).length?o.find(".ast-mobile-header-wrap"):r,jQuery("body").hasClass("ast-primary-sticky-header-active")&&jQuery("body").hasClass("ast-above-sticky-header-active")&&jQuery("body").hasClass("ast-below-sticky-header-active")||r.find(".ast-mobile-header-content").removeAttr("style"))))},t.prototype.update_attrs=function(){var e,a,t=this,s=jQuery(t.element),i=parseInt(t.options.gutter),d=t.options.max_width;"none"!=t.options.header_style||jQuery("body").hasClass("ast-sticky-toggled-off")?n("#masthead").length&&(e=n("#masthead"),a=("none"==t.options.header_style?e.offset().top:e.offset().top+e.outerHeight()+100)||0):a=s.offset().top||0,"ast-box-layout"!=t.options.site_layout&&(d=jQuery("body").width()),t.options.dependent&&jQuery.each(t.options.dependent,function(e,t){jQuery(t).length&&"on"==jQuery(t).parent().attr("data-stick-support")&&(dependent_height=jQuery(t).outerHeight(),i+=parseInt(dependent_height),a-=parseInt(dependent_height))}),t.options.admin_bar_height_lg&&jQuery("#wpadminbar").length&&782<r&&(i+=parseInt(t.options.admin_bar_height_lg),a-=parseInt(t.options.admin_bar_height_lg)),t.options.admin_bar_height_sm&&jQuery("#wpadminbar").length&&600<=r&&r<=782&&(i+=parseInt(t.options.admin_bar_height_sm),a-=parseInt(t.options.admin_bar_height_sm)),t.options.admin_bar_height_xs&&jQuery("#wpadminbar").length&&(i+=parseInt(t.options.admin_bar_height_xs),a-=parseInt(t.options.admin_bar_height_xs)),t.options.body_padding_support&&(i+=parseInt(jQuery("body").css("padding-top"),10),a-=parseInt(jQuery("body").css("padding-top"),10)),t.options.html_padding_support&&(i+=parseInt(jQuery("html").css("padding-top"),10),a-=parseInt(jQuery("html").css("padding-top"),10)),C&&a--,t.options.stick_upto_scroll=a,"none"==t.options.header_style?s.parent().css("min-height",s.outerHeight()).attr("data-stick-gutter",parseInt(i)).attr("data-stick-maxwidth",parseInt(d)):(s.parent().attr("data-stick-gutter",parseInt(i)).attr("data-stick-maxwidth",parseInt(d)),"ast-padded-layout"===t.options.site_layout&&s.css("max-width",parseInt(d)))},t.prototype.hasScrolled=function(e,t){var a,s=n(h).scrollTop();Math.abs(i-s)<=5||(a=jQuery(e.element),i<s&&0<s?jQuery(e.element).removeClass("ast-nav-down").addClass("ast-nav-up"):s+n(h).height()<n(l).height()&&jQuery(e.element).removeClass("ast-nav-up").addClass("ast-nav-down"),i=s,n(e.element).hasClass("ast-nav-up")||"stick"!=t?(a.css({transform:"translateY(-100%)"}).stop(),setTimeout(function(){a.removeClass("ast-sticky-active")},300),a.css({visibility:"hidden",top:""}),n(l).trigger("removeStickyClass"),n("html").removeClass("ast-header-stick-scroll-active"),a.removeClass("ast-header-sticked")):(a.css({top:gutter}),a.addClass("ast-header-sticked"),a.addClass("ast-header-slide"),a.css("visibility","visible"),a.addClass("ast-sticky-active").stop().css({transform:"translateY(0)"}),n(l).trigger("addStickyClass"),n("html").addClass("ast-header-stick-scroll-active")))},t.prototype.stickRelease=function(e){var t=jQuery(e.element),a=t;"1"===e.options.hide_on_scroll?e.hasScrolled(e,"release"):"none"==e.options.header_style?(t.removeClass("ast-sticky-active").stop().css({"max-width":"",top:"",padding:""}),t.parent().css("min-height",""),n(l).trigger("removeStickyClass"),a.removeClass("ast-header-sticked"),t.removeClass("ast-sticky-shrunk").stop()):"slide"==e.options.header_style?(a.removeClass("ast-sticky-active").stop().css({transform:p?"translateY(-100vh)":"translateY(-100%)"}),a.css({visibility:"hidden",top:""}),n("html").removeClass("ast-header-stick-slide-active"),n(l).trigger("removeStickyClass"),a.removeClass("ast-header-sticked")):"fade"==e.options.header_style&&(a.removeClass("ast-sticky-active").stop().css({opacity:"0"}),a.css({visibility:"hidden"}),a.removeClass("ast-header-sticked"),n(l).trigger("removeStickyClass"),n("html").removeClass("ast-header-stick-fade-active"))},t.prototype.init=function(){var t,e;jQuery(this.element)&&(t=this,e=jQuery(t.element),("none"==t.options.header_style?e.wrap(t.options.wrap).parent().css("min-height",e.outerHeight()):e.wrap(t.options.wrap)).attr("data-stick-support","on").attr("data-stick-maxwidth",parseInt(t.options.max_width)),t.update_attrs(),jQuery(h).on("resize",function(){t.stickRelease(t),t.update_attrs(),t.stick_me(t)}),jQuery(h).on("scroll",function(){t.stick_me(t,"scroll"),jQuery("body").hasClass("ast-sticky-toggled-off")&&(t.update_attrs(),t.stick_me(t,"scroll"))}),jQuery(l).ready(function(e){t.stick_me(t),setTimeout(()=>t.stick_me(t),0)}))},n.fn[a]=function(e){return this.each(function(){n.data(this,"plugin_"+a)||n.data(this,"plugin_"+a,new t(this,e))})};var e,d,o=jQuery("body"),y=o.width(),_=astraAddon.stick_header_meta||"default",m=astraAddon.header_main_stick||"",u=astraAddon.header_main_shrink||"",k=astraAddon.header_above_stick||"",b=astraAddon.header_below_stick||"",g=astraAddon.site_layout||"",v=astraAddon.site_layout_box_width||1200,w=astraAddon.sticky_header_on_devices||"desktop",j=astraAddon.sticky_header_style||"none",Q=astraAddon.sticky_hide_on_scroll||"",f=astraAddon.header_logo_width||"",x=astraAddon.responsive_header_logo_width||"",C=astraAddon.stick_origin_position||"",S=astraAddon.tablet_break_point||768,I=astraAddon.mobile_break_point||544;function A(){var e;"1"==Q?("1"==u&&jQuery("#ast-fixed-header").addClass("ast-sticky-shrunk").stop(),"1"!=k&&"on"!=k&&"disabled"!=k&&jQuery("#ast-fixed-header .ast-above-header").hide(),"1"!=m&&"on"!=m&&"disabled"!=m&&jQuery("#ast-fixed-header .main-header-bar").hide(),"1"!=b&&"on"!=b&&"disabled"!=b&&jQuery("#ast-fixed-header .ast-below-header").hide(),jQuery("#ast-fixed-header").astExtSticky({max_width:y,site_layout:g,sticky_on_device:w,header_style:"slide",hide_on_scroll:Q})):"none"==j?c?("both"===w?["desktop","mobile"]:[w]).forEach(function(e){var t;"1"!=k&&"on"!=k&&"disabled"!=k||jQuery("#masthead #ast-"+e+"-header .ast-above-header").astExtSticky({max_width:y,site_layout:g,sticky_on_device:w,header_style:j,hide_on_scroll:Q}),"1"!=m&&"on"!=m&&"disabled"!=m||"1"!=b&&"on"!=b&&"disabled"!=b?("1"!=m&&"on"!=m&&"disabled"!=m||(t=u?{padding_top:"",padding_bottom:""}:"",jQuery("#masthead #ast-"+e+"-header .main-header-bar").astExtSticky({dependent:["#masthead #ast-"+e+"-header .ast-above-header"],max_width:y,site_layout:g,shrink:t,sticky_on_device:w,header_style:j,hide_on_scroll:Q}),jQuery("#masthead #ast-"+e+"-header .ast-custom-header").astExtSticky({max_width:y,site_layout:g,shrink:t,sticky_on_device:w,header_style:j,hide_on_scroll:Q})),"1"!=b&&"on"!=b&&"disabled"!=b||jQuery("#masthead #ast-"+e+"-header .ast-below-header").astExtSticky({dependent:["#masthead #ast-"+e+"-header .main-header-bar","#masthead #ast-"+e+"-header .ast-above-header"],max_width:y,site_layout:g,sticky_on_device:w,header_style:j,hide_on_scroll:Q})):((jQuery("#masthead #ast-"+e+"-header .main-header-bar-wrap").length?jQuery("#masthead #ast-"+e+"-header .main-header-bar-wrap"):jQuery("#masthead #ast-"+e+"-header .ast-below-header-wrap")).wrap('<div class="ast-stick-primary-below-wrapper"></div>'),jQuery("#masthead #ast-"+e+"-header .ast-below-header-wrap").prependTo("#masthead #ast-"+e+"-header .ast-stick-primary-below-wrapper"),jQuery("#masthead #ast-"+e+"-header .main-header-bar-wrap").prependTo("#masthead #ast-"+e+"-header .ast-stick-primary-below-wrapper"),jQuery("#masthead #ast-"+e+"-header .ast-stick-primary-below-wrapper").astExtSticky({dependent:["#masthead #ast-"+e+"-header .ast-above-header"],max_width:y,site_layout:g,shrink:t,sticky_on_device:w,header_style:j,hide_on_scroll:Q}))}):("1"!=k&&"on"!=k&&"disabled"!=k||jQuery("#masthead .ast-above-header").astExtSticky({max_width:y,site_layout:g,sticky_on_device:w,header_style:j,hide_on_scroll:Q}),"1"!=m&&"on"!=m&&"disabled"!=m||"1"!=b&&"on"!=b&&"disabled"!=b?("1"!=m&&"on"!=m&&"disabled"!=m||(e=u?{padding_top:"",padding_bottom:""}:"",jQuery("#masthead .main-header-bar").astExtSticky({dependent:["#masthead .ast-above-header"],max_width:y,site_layout:g,shrink:e,sticky_on_device:w,header_style:j,hide_on_scroll:Q}),jQuery("#masthead .ast-custom-header").astExtSticky({max_width:y,site_layout:g,shrink:e,sticky_on_device:w,header_style:j,hide_on_scroll:Q})),"1"!=b&&"on"!=b&&"disabled"!=b||jQuery("#masthead .ast-below-header").astExtSticky({dependent:["#masthead .main-header-bar","#masthead .ast-above-header"],max_width:y,site_layout:g,sticky_on_device:w,header_style:j,hide_on_scroll:Q})):(jQuery("#masthead .main-header-bar-wrap").wrap('<div class="ast-stick-primary-below-wrapper"></div>'),jQuery("#masthead .ast-below-header-wrap").prependTo(".ast-stick-primary-below-wrapper"),jQuery("#masthead .main-header-bar-wrap").prependTo(".ast-stick-primary-below-wrapper"),jQuery("#masthead .ast-stick-primary-below-wrapper").astExtSticky({dependent:["#masthead .ast-above-header"],max_width:y,site_layout:g,shrink:e,sticky_on_device:w,header_style:j,hide_on_scroll:Q}))):(jQuery("#ast-fixed-header").addClass("ast-sticky-shrunk").stop(),"1"!=k&&"on"!=k&&"disabled"!=k&&jQuery("#ast-fixed-header .ast-above-header").hide(),"1"!=m&&"on"!=m&&"disabled"!=m&&jQuery("#ast-fixed-header .main-header-bar").hide(),"1"!=b&&"on"!=b&&"disabled"!=b&&jQuery("#ast-fixed-header .ast-below-header").hide(),"1"!=k&&"on"!=k&&"disabled"!=k&&"1"!=m&&"on"!=m&&"disabled"!=m&&"1"!=b&&"on"!=b&&"disabled"!=b||(e=u?{padding_top:"",padding_bottom:""}:"",jQuery("#ast-fixed-header").astExtSticky({max_width:y,site_layout:g,shrink:e,sticky_on_device:w,header_style:j,hide_on_scroll:Q}))),"mobile"!=w&&"both"!=w||(jQuery("#masthead .main-header-menu-toggle").click(function(e){var t,a;jQuery("#masthead .main-header-menu-toggle").hasClass("toggled")?(o.addClass("ast-sticky-toggled-off"),"none"==s.header_style&&(jQuery("#masthead .main-header-bar").hasClass("ast-sticky-active")||jQuery("#masthead .ast-stick-primary-below-wrapper").hasClass("ast-sticky-active"))&&(t=jQuery(h).height(),a=0,jQuery("#masthead .ast-above-header")&&jQuery("#masthead .ast-above-header").length&&(a=jQuery("#masthead .ast-above-header").height()),"1"==Q&&jQuery("html").css({overflow:"hidden"}),("1"!=u||"1"!=m&&"on"!=m&&"disabled"!=m||"1"!=b&&"on"!=b&&"disabled"!=b?jQuery("#masthead .main-header-bar.ast-sticky-active"):jQuery("#masthead .ast-stick-primary-below-wrapper")).css({"max-height":t-a+"px","overflow-y":"auto"}))):(o.addClass("ast-sticky-toggled-off"),jQuery("html").css({overflow:""}),("1"!=u||"1"!=m&&"on"!=m&&"disabled"!=m||"1"!=b&&"on"!=b&&"disabled"!=b?jQuery("#masthead .main-header-bar.ast-sticky-active"):jQuery("#masthead .ast-stick-primary-below-wrapper")).css({"max-height":"","overflow-y":""}))}),jQuery("#ast-fixed-header .main-header-menu-toggle").click(function(e){var t;jQuery("#ast-fixed-header .main-header-menu-toggle").hasClass("toggled")?(t=jQuery(h).height(),"1"==Q&&jQuery("html").css({overflow:"auto"}),jQuery("#ast-fixed-header").css({"max-height":t+"px","overflow-y":"auto"})):(jQuery("html").css({overflow:""}),jQuery("#ast-fixed-header").css({"max-height":"","overflow-y":""}))}))}"disabled"!=_&&("enabled"===_&&(m=astraAddon.header_main_stick_meta||"",k=astraAddon.header_above_stick_meta||"",b=astraAddon.header_below_stick_meta||""),0<n("header .site-logo-img img").length&&(-1===(e=0==(e=void 0===(e=(_=n("header .site-logo-img img")).attr("height"))?_.height():e)?"":e).toString().indexOf("%")&&(e+="px"),""!=x.desktop||""!=x.tablet||""!=x.mobile?d="<style type='text/css' id='ast-site-identity-img' class='ast-site-identity-img' > #masthead .ast-header-sticked .site-logo-img .astra-logo-svg { width: "+x.desktop+"px; } @media (max-width: "+S+"px){ #masthead .ast-header-sticked .site-logo-img .astra-logo-svg { width: "+x.tablet+"px; }} @media (max-width: "+I+"px){ #masthead .ast-header-sticked .site-logo-img .astra-logo-svg{ width: "+x.mobile+"px; }} </style>":""!=f&&(d="<style type='text/css' id='ast-site-identity-img' class='ast-site-identity-img' > #masthead .ast-header-sticked .site-logo-img .astra-logo-svg { width: "+f+"px; } #masthead .ast-header-sticked .site-logo-img img { max-height: "+e+"; width: auto; } </style>"),n("head").append(d)),m||k||b)&&(n(l).on("addStickyClass",function(){var e="";"1"!=m&&"on"!=m&&"disabled"!=m||(e+=" ast-primary-sticky-header-active"),"1"!=k&&"on"!=k&&"disabled"!=k||(e+=" ast-above-sticky-header-active"),"1"!=b&&"on"!=b&&"disabled"!=b||(e+=" ast-below-sticky-header-active"),n("body").addClass(e)}),n(l).on("removeStickyClass",function(){var e="";"1"!=m&&"on"!=m&&"disabled"!=m||(e+=" ast-primary-sticky-header-active"),"1"!=k&&"on"!=k&&"disabled"!=k||(e+=" ast-above-sticky-header-active"),"1"!=b&&"on"!=b&&"disabled"!=b||(e+=" ast-below-sticky-header-active"),n("body").removeClass(e)}),"ast-box-layout"===g&&(y=parseInt(v)),jQuery(function(e){A()}),jQuery(l).on("astLayoutWidthChanged",function(e){(parseInt(m)||parseInt(b)||parseInt(k))&&(jQuery("div.ast-stick-primary-below-wrapper").children().unwrap(),jQuery('div[data-stick-support="on"]').children().unwrap(),A())}))})(jQuery,window);function display_mega_menu_on_load(){var e=document.querySelectorAll(".content-width-mega");if(0<e.length)for(var t=0;t<e.length;t++)"hover"===(e[t].getAttribute("data-megamenu-trigger")||"hover")&&e[t].addEventListener("mouseenter",function(e){e=e.target.querySelector(".astra-mega-menu-width-content");null!==e&&e.classList.remove("ast-hidden")});var a=document.querySelectorAll(".menu-container-width-mega");if(0<a.length)for(t=0;t<a.length;t++)"hover"===(a[t].getAttribute("data-megamenu-trigger")||"hover")&&a[t].addEventListener("mouseenter",function(e){e=e.target.querySelector(".astra-mega-menu-width-menu-container");null!==e&&e.classList.remove("ast-hidden")});var s=document.querySelectorAll(".full-width-mega");if(0<s.length)for(t=0;t<s.length;t++)"hover"===(s[t].getAttribute("data-megamenu-trigger")||"hover")&&s[t].addEventListener("mouseenter",function(e){var t=e.target.querySelector(".astra-full-megamenu-wrapper"),e=e.target.querySelector(".astra-mega-menu-width-full");null!==t&&t.classList.remove("ast-hidden"),null!==e&&e.classList.remove("ast-hidden")});var r=document.querySelectorAll(".full-stretched-width-mega");if(0<r.length)for(t=0;t<r.length;t++)"hover"===(r[t].getAttribute("data-megamenu-trigger")||"hover")&&r[t].addEventListener("mouseenter",function(e){var t=e.target.querySelector(".astra-full-megamenu-wrapper"),e=e.target.querySelector(".astra-mega-menu-width-full-stretched");null!==t&&t.classList.remove("ast-hidden"),null!==e&&e.classList.remove("ast-hidden")});var n=document.querySelectorAll(".custom-width-mega");if(0<n.length)for(t=0;t<n.length;t++)"hover"===(n[t].getAttribute("data-megamenu-trigger")||"hover")&&n[t].addEventListener("mouseenter",function(e){e=e.target.querySelector(".astra-mega-menu-width-custom");null!==e&&e.classList.remove("ast-hidden")})}document.addEventListener("DOMContentLoaded",display_mega_menu_on_load),document.addEventListener("astPartialContentRendered",display_mega_menu_on_load);var items=document.getElementsByClassName("astra-megamenu-li");function apply_megamenu_width_styles(){[].slice.call(items).forEach(g=>{function s(){var e,t,a,s,r,n,i,d,u,l=(m=jQuery(g).parents(".ast-container")).children(),m=m.parent(),o=jQuery(g);(o.hasClass("full-width-mega")||o.hasClass("full-stretched-width-mega"))&&(l=jQuery(l).closest(".ast-container")),parseInt(window.innerWidth)>parseInt(astra.break_point)&&"ast-hf-mobile-menu"!==o.parent().attr("id")&&"ast-desktop-toggle-menu"!==o.parent().attr("id")?(e=l.width(),t=l.offset(),l=(a=o.offset()).left-(t.left+parseFloat(l.css("paddingLeft"))),d=e-(a.left+t.left)+130,s=m.width(),r=m.offset(),r=a.left-(r.left+parseFloat(m.css("paddingLeft"))),o.hasClass("custom-width-mega")&&(i=(i=window.getComputedStyle(o.find(".astra-mega-menu-width-custom")[0],"::before").getPropertyValue("content")||1200).replace(/[^0-9]/g,""),(i=parseInt(i))<=e?(u=parseInt(e-i),n=parseInt(l-u),t.left):(u=parseInt(i-e),n=parseInt(l+u),t.left)),o.hasClass("menu-container-width-mega")&&(u=jQuery(g).parents(".main-navigation"),m.hasClass("ast-above-header")?u=jQuery(".ast-above-header-navigation"):m.hasClass("ast-below-header")&&(u=jQuery(".ast-below-header-actual-nav")),e=($target_container=u.length?u:o.parent("ul")).width()+"px",m=jQuery(window).width()-($target_container.offset().left+$target_container.outerWidth()),u=o.offset(),m=jQuery(window).width()-m-u.left,l=parseInt($target_container.width()-m),d=parseInt(e)-o.outerWidth()-parseInt($target_container.width()-m)),o.hasClass("full-width-mega")?(o.find(".astra-full-megamenu-wrapper").css({left:"-"+r+"px",width:s}),o.find(".astra-megamenu").css({width:e})):o.hasClass("full-stretched-width-mega")?o.find(".astra-full-megamenu-wrapper").css({left:"-"+r+"px",width:s}):o.hasClass("custom-width-mega")?astra.isRtl?o.find(".astra-mega-menu-width-custom").css({width:i+"px"}):o.find(".astra-mega-menu-width-custom").css({left:"-"+n+"px",width:i+"px"}):o.hasClass("content-width-mega")?astra.isRtl?(u=t.left+e-(a.left+o.outerWidth()),o.find(".astra-megamenu").css({right:"-"+u+"px",width:e}).data("astra-hover-right",u)):o.find(".astra-megamenu").css({left:"-"+l+"px",width:e}):astra.isRtl?(o.find(".astra-megamenu").css({right:"-"+d+"px",width:e}),o.data("astra-hover-right",d)):o.find(".astra-megamenu").css({left:"-"+l+"px",width:e})):astra.isRtl?(o.find(".astra-megamenu").css({right:"",width:"","background-image":""}),o.find(".astra-full-megamenu-wrapper").css({right:"",width:"","background-image":""})):(o.find(".astra-megamenu").css({left:"",width:"","background-image":""}),o.find(".astra-full-megamenu-wrapper").css({left:"",width:"","background-image":""}))}"click"===(jQuery(g).data("megamenu-trigger")||"hover")?(jQuery(g).find("> a").on("click",function(e){var t=jQuery(g),a=t.hasClass("megamenu-active");jQuery(".astra-megamenu-li.megamenu-active").removeClass("megamenu-active"),a||(e.preventDefault(),t.addClass("megamenu-active"),t.find(".ast-hidden").removeClass("ast-hidden"),s())}),jQuery(document).on("click",function(e){jQuery(e.target).closest(".astra-megamenu-li").length||jQuery(".astra-megamenu-li.megamenu-active").removeClass("megamenu-active")})):(jQuery(g).hover(s),jQuery(g).mouseenter(function(){document.dispatchEvent(new CustomEvent("astra_mega_menu_on_hover",{detail:{}}))}))})}apply_megamenu_width_styles(),document.addEventListener("astMenuHoverStyleChanged",function(){apply_megamenu_width_styles()}),[].slice.call(items).forEach(function(h){var e=jQuery(h).parents(".ast-container"),f=e.children(),c=e.parent(),p=jQuery(h);(p.hasClass("full-width-mega")||p.hasClass("full-stretched-width-mega"))&&(f=jQuery(f).closest(".ast-container"),p.find(".astra-full-megamenu-wrapper").removeClass("ast-hidden")),p.find(".menu-link").focusin(function(e){var t,a,s,r,n,i,d,u,l,m,o,g;astra.is_header_footer_builder_active||(p.find(".sub-menu").addClass("astra-megamenu-focus"),p.find(".astra-full-megamenu-wrapper").addClass("astra-megamenu-wrapper-focus")),p.find(".sub-menu").removeClass("ast-hidden"),parseInt(jQuery(window).width())>parseInt(astra.break_point)&&"ast-hf-mobile-menu"!==p.parent().attr("id")&&"ast-desktop-toggle-menu"!==p.parent().attr("id")?(t=f.width(),a=f.offset(),u=(s=p.offset()).left-(a.left+parseFloat(f.css("paddingLeft"))),l=t-(s.left+a.left)+130,r=c.width(),g=c.offset(),g=s.left-(g.left+parseFloat(c.css("paddingLeft"))),p.hasClass("custom-width-mega")&&(d=(d=window.getComputedStyle(p.find(".astra-mega-menu-width-custom")[0],"::before").getPropertyValue("content")||1200).replace(/[^0-9]/g,""),i=(d=parseInt(d))<=t?(i=parseInt(t-d),n=parseInt(u-i),a.left-n):(i=parseInt(d-t),n=parseInt(u+i),a.left+n)),p.hasClass("menu-container-width-mega")&&(o=jQuery(h).parents(".main-navigation"),c.hasClass("ast-above-header")?o=jQuery(".ast-above-header-navigation"):c.hasClass("ast-below-header")&&(o=jQuery(".ast-below-header-actual-nav")),t=($target_container=o.length?o:p.parent("ul")).width()+"px",o=jQuery(window).width()-($target_container.offset().left+$target_container.outerWidth()),m=p.offset(),o=jQuery(window).width()-o-m.left,u=parseInt($target_container.width()-o),l=parseInt(t)-p.outerWidth()-parseInt($target_container.width()-o)),p.hasClass("full-width-mega")?(p.find(".astra-full-megamenu-wrapper").css({left:"-"+g+"px",width:r}),p.find(".astra-megamenu").css({width:t})):p.hasClass("full-stretched-width-mega")?p.find(".astra-full-megamenu-wrapper").css({left:"-"+g+"px",width:r}):p.hasClass("custom-width-mega")?astra.isRtl?p.find(".astra-mega-menu-width-custom").css({right:"-"+i+"px",width:d+"px"}):p.find(".astra-mega-menu-width-custom").css({left:"-"+n+"px",width:d+"px"}):p.hasClass("content-width-mega")?astra.isRtl?(m=a.left+t-(s.left+p.outerWidth()),p.find(".astra-megamenu").css({right:"-"+m+"px",width:t}).data("astra-hover-right",m)):p.find(".astra-megamenu").css({left:"-"+u+"px",width:t}):(g=void 0!==(o=p.data("astra-hover-right"))?o:l,astra.isRtl?p.find(".astra-megamenu").css({right:"-"+g+"px",width:t}).data("astra-hover-right",g):p.find(".astra-megamenu").css({left:"-"+u+"px",width:t}))):astra.isRtl?(p.find(".astra-megamenu").css({right:"",width:"","background-image":""}),p.find(".astra-full-megamenu-wrapper").css({right:"",width:"","background-image":""})):(p.find(".astra-megamenu").css({left:"",width:"","background-image":""}),p.find(".astra-full-megamenu-wrapper").css({left:"",width:"","background-image":""}))}),astra.is_header_footer_builder_active||(p.find(".menu-link").keydown(function(e){9==e.which&&e.shiftKey&&(p.find(".sub-menu").removeClass("astra-megamenu-focus"),p.find(".astra-full-megamenu-wrapper").removeClass("astra-megamenu-wrapper-focus"))}),jQuery(h).find(".sub-menu .menu-item").last().focusout(function(){p.find(".sub-menu").removeClass("astra-megamenu-focus"),p.find(".astra-full-megamenu-wrapper").removeClass("astra-megamenu-wrapper-focus")}),jQuery(window).click(function(){p.find(".sub-menu").removeClass("astra-megamenu-focus"),p.find(".astra-full-megamenu-wrapper").removeClass("astra-megamenu-wrapper-focus")})),p.click(function(e){jQuery(e.target).hasClass("menu-item")&&e.stopImmediatePropagation()})});(()=>{var e;function o(e){var t=(t=document.body.className).replace(e,"");document.body.className=t}function d(e){e.style.display="block",setTimeout(function(){e.style.opacity=1},1)}function n(e){e.style.opacity="",setTimeout(function(){e.style.display=""},200)}r="iPhone"==navigator.userAgent.match(/iPhone/i)?"iphone":"",e="iPod"==navigator.userAgent.match(/iPod/i)?"ipod":"",document.body.className+=" "+r,document.body.className+=" "+e;for(var t=document.querySelectorAll("a.astra-search-icon:not(.slide-search)"),a=0;t.length>a;a++)t[a].onclick=function(e){var t,a,o,n;if(e.preventDefault(),e=e||window.event,this.classList.contains("header-cover"))for(var s=document.querySelectorAll(".ast-search-box.header-cover"),c=astraAddon.is_header_builder_active||!1,r=0;r<s.length;r++)for(var l=s[r].parentNode.querySelectorAll("a.astra-search-icon"),i=0;i<l.length;i++)l[i]==this&&(d(s[r]),s[r].querySelector("input.search-field").focus(),c?(t=s[r],n=o=a=void 0,document.body.classList.contains("ast-header-break-point")&&(n=document.querySelector(".main-navigation"),a=document.querySelector(".main-header-bar"),o=document.querySelector(".ast-mobile-header-wrap"),null!==a)&&null!==n&&(n=n.offsetHeight,a=a.offsetHeight,o=o.offsetHeight,n=n&&!document.body.classList.contains("ast-no-toggle-menu-enable")?parseFloat(n)-parseFloat(a):parseFloat(a),t.parentNode.classList.contains("ast-mobile-header-wrap")&&(n=parseFloat(o)),t.style.maxHeight=Math.abs(n)+"px")):(a=s[r],t=o=void 0,document.body.classList.contains("ast-header-break-point")&&(t=document.querySelector(".main-navigation"),null!==(o=document.querySelector(".main-header-bar")))&&null!==t&&(t=t.offsetHeight,o=o.offsetHeight,t=t&&!document.body.classList.contains("ast-no-toggle-menu-enable")?parseFloat(t)-parseFloat(o):parseFloat(o),a.style.maxHeight=Math.abs(t)+"px")));else this.classList.contains("full-screen")&&(e=document.getElementById("ast-seach-full-screen-form")).classList.contains("full-screen")&&(d(e),document.body.className+=" full-screen",e.querySelector("input.search-field").focus())};for(var s=document.querySelectorAll(".ast-search-box .close"),a=0,c=s.length;a<c;++a)s[a].onclick=function(e){e=e||window.event;for(var t=this;;){if(t.parentNode.classList.contains("ast-search-box")){n(t.parentNode),o("full-screen");break}if(t.parentNode.classList.contains("site-header"))break;t=t.parentNode}};document.onkeydown=function(e){if(27==e.keyCode)for(var e=document.getElementById("ast-seach-full-screen-form"),t=(null!=e&&(n(e),o("full-screen")),document.querySelectorAll(".ast-search-box.header-cover")),a=0;a<t.length;a++)n(t[a])},window.addEventListener("resize",function(){if("BODY"===document.activeElement.tagName&&"INPUT"!=document.activeElement.tagName){var e=document.querySelectorAll(".ast-search-box.header-cover");if(!document.body.classList.contains("ast-header-break-point"))for(var t=0;t<e.length;t++)e[t].style.maxHeight="",e[t].style.opacity="",e[t].style.display=""}});var r=document.getElementById("close");r&&r.addEventListener("keydown",function(e){"Enter"===e.key?(e.preventDefault(),this.click()):"Tab"===e.key&&e.preventDefault()})})();
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).DOMPurify=t()}(this,function(){"use strict";function e(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}function t(t,n){return function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o,r,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t);else for(;!(c=(o=i.call(n)).done)&&(l.push(o.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw r}}return l}}(t,n)||function(t,n){if(t){if("string"==typeof t)return e(t,n);var o={}.toString.call(t).slice(8,-1);return"Object"===o&&t.constructor&&(o=t.constructor.name),"Map"===o||"Set"===o?Array.from(t):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?e(t,n):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const n=Object.entries,o=Object.setPrototypeOf,r=Object.isFrozen,i=Object.getPrototypeOf,a=Object.getOwnPropertyDescriptor;let l=Object.freeze,c=Object.seal,s=Object.create,u="undefined"!=typeof Reflect&&Reflect,f=u.apply,p=u.construct;l||(l=function(e){return e}),c||(c=function(e){return e}),f||(f=function(e,t){for(var n=arguments.length,o=new Array(n>2?n-2:0),r=2;r<n;r++)o[r-2]=arguments[r];return e.apply(t,o)}),p||(p=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return new e(...n)});const m=L(Array.prototype.forEach),d=L(Array.prototype.lastIndexOf),h=L(Array.prototype.pop),g=L(Array.prototype.push),y=L(Array.prototype.splice),T=Array.isArray,b=L(String.prototype.toLowerCase),S=L(String.prototype.toString),E=L(String.prototype.match),A=L(String.prototype.replace),N=L(String.prototype.indexOf),_=L(String.prototype.trim),w=L(Number.prototype.toString),O=L(Boolean.prototype.toString),v="undefined"==typeof BigInt?null:L(BigInt.prototype.toString),D="undefined"==typeof Symbol?null:L(Symbol.prototype.toString),R=L(Object.prototype.hasOwnProperty),C=L(Object.prototype.toString),I=L(RegExp.prototype.test),k=(x=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return p(x,t)});var x;function L(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return f(e,t,o)}}function M(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:b;if(o&&o(e,null),!T(t))return e;let i=t.length;for(;i--;){let o=t[i];if("string"==typeof o){const e=n(o);e!==o&&(r(t)||(t[i]=e),o=e)}e[o]=!0}return e}function z(e){for(let t=0;t<e.length;t++){R(e,t)||(e[t]=null)}return e}function P(e){const o=s(null);for(const i of n(e)){var r=t(i,2);const n=r[0],a=r[1];R(e,n)&&(T(a)?o[n]=z(a):a&&"object"==typeof a&&a.constructor===Object?o[n]=P(a):o[n]=a)}return o}function U(e,t){for(;null!==e;){const n=a(e,t);if(n){if(n.get)return L(n.get);if("function"==typeof n.value)return L(n.value)}e=i(e)}return function(){return null}}const F=l(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),H=l(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),j=l(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),B=l(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),G=l(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),W=l(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Y=l(["#text"]),q=l(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),X=l(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),$=l(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),K=l(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),V=c(/{{[\w\W]*|^[\w\W]*}}/g),Z=c(/<%[\w\W]*|^[\w\W]*%>/g),J=c(/\${[\w\W]*/g),Q=c(/^data-[\-\w.\u00B7-\uFFFF]+$/),ee=c(/^aria-[\-\w]+$/),te=c(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ne=c(/^(?:\w+script|data):/i),oe=c(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),re=c(/^html$/i),ie=c(/^[a-z][.\w]*(-[.\w]+)+$/i),ae=c(/<[/\w!]/g),le=c(/<[/\w]/g),ce=c(/<\/no(script|embed|frames)/i),se=c(/\/>/i),ue=1,fe=3,pe=7,me=8,de=9,he=11,ge=function(){return"undefined"==typeof window?null:window},ye=function(e,t,n,o){return R(e,t)&&T(e[t])?M(o.base?P(o.base):{},e[t],o.transform):n};var Te=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ge();const o=t=>e(t);if(o.version="3.4.11",o.removed=[],!t||!t.document||t.document.nodeType!==de||!t.Element)return o.isSupported=!1,o;let r=t.document;const i=r,a=i.currentScript;t.DocumentFragment;const u=t.HTMLTemplateElement,f=t.Node,p=t.Element,x=t.NodeFilter,L=t.NamedNodeMap;void 0===L&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const z=t.DOMParser,Te=t.trustedTypes,be=p.prototype,Se=U(be,"cloneNode"),Ee=U(be,"remove"),Ae=U(be,"nextSibling"),Ne=U(be,"childNodes"),_e=U(be,"parentNode"),we=U(be,"shadowRoot"),Oe=U(be,"attributes"),ve=f&&f.prototype?U(f.prototype,"nodeType"):null,De=f&&f.prototype?U(f.prototype,"nodeName"):null;if("function"==typeof u){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let Re,Ce,Ie="",ke=!1,xe=0;const Le=function(){if(xe>0)throw k('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},Me=function(e){Le(),xe++;try{return Re.createHTML(e)}finally{xe--}},ze=function(){return ke||(Ce=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const o="data-tt-policy-suffix";t&&t.hasAttribute(o)&&(n=t.getAttribute(o));const r="dompurify"+(n?"#"+n:"");try{return e.createPolicy(r,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+r+" could not be created."),null}}(Te,a),ke=!0),Ce},Pe=r,Ue=Pe.implementation,Fe=Pe.createNodeIterator,He=Pe.createDocumentFragment,je=Pe.getElementsByTagName,Be=i.importNode;let Ge={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};o.isSupported="function"==typeof n&&"function"==typeof _e&&Ue&&void 0!==Ue.createHTMLDocument;const We=V,Ye=Z,qe=J,Xe=Q,$e=ee,Ke=ne,Ve=oe,Ze=ie;let Je=te,Qe=null;const et=M({},[...F,...H,...j,...G,...Y]);let tt=null;const nt=M({},[...q,...X,...$,...K]);let ot=Object.seal(s(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),rt=null,it=null;const at=Object.seal(s(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let lt=!0,ct=!0,st=!1,ut=!0,ft=!1,pt=!0,mt=!1,dt=!1,ht=null,gt=null,yt=!1,Tt=!1,bt=!1,St=!1,Et=!0,At=!1;const Nt="user-content-";let _t=!0,wt=!1,Ot={},vt=null;const Dt=M({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let Rt=null;const Ct=M({},["audio","video","img","source","image","track"]);let It=null;const kt=M({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),xt="http://www.w3.org/1998/Math/MathML",Lt="http://www.w3.org/2000/svg",Mt="http://www.w3.org/1999/xhtml";let zt=Mt,Pt=!1,Ut=null;const Ft=M({},[xt,Lt,Mt],S),Ht=l(["mi","mo","mn","ms","mtext"]);let jt=M({},Ht);const Bt=l(["annotation-xml"]);let Gt=M({},Bt);const Wt=M({},["title","style","font","a","script"]);let Yt=null;const qt=["application/xhtml+xml","text/html"];let Xt=null,$t=null;const Kt=r.createElement("form"),Vt=function(e){return e instanceof RegExp||e instanceof Function},Zt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if($t&&$t===e)return;e&&"object"==typeof e||(e={}),e=P(e),Yt=-1===qt.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,Xt="application/xhtml+xml"===Yt?S:b,Qe=ye(e,"ALLOWED_TAGS",et,{transform:Xt}),tt=ye(e,"ALLOWED_ATTR",nt,{transform:Xt}),Ut=ye(e,"ALLOWED_NAMESPACES",Ft,{transform:S}),It=ye(e,"ADD_URI_SAFE_ATTR",kt,{transform:Xt,base:kt}),Rt=ye(e,"ADD_DATA_URI_TAGS",Ct,{transform:Xt,base:Ct}),vt=ye(e,"FORBID_CONTENTS",Dt,{transform:Xt}),rt=ye(e,"FORBID_TAGS",P({}),{transform:Xt}),it=ye(e,"FORBID_ATTR",P({}),{transform:Xt}),Ot=!!R(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"==typeof e.USE_PROFILES?P(e.USE_PROFILES):e.USE_PROFILES),lt=!1!==e.ALLOW_ARIA_ATTR,ct=!1!==e.ALLOW_DATA_ATTR,st=e.ALLOW_UNKNOWN_PROTOCOLS||!1,ut=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,ft=e.SAFE_FOR_TEMPLATES||!1,pt=!1!==e.SAFE_FOR_XML,mt=e.WHOLE_DOCUMENT||!1,Tt=e.RETURN_DOM||!1,bt=e.RETURN_DOM_FRAGMENT||!1,St=e.RETURN_TRUSTED_TYPE||!1,yt=e.FORCE_BODY||!1,Et=!1!==e.SANITIZE_DOM,At=e.SANITIZE_NAMED_PROPS||!1,_t=!1!==e.KEEP_CONTENT,wt=e.IN_PLACE||!1,Je=function(e){try{return I(e,""),!0}catch(e){return!1}}(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:te,zt="string"==typeof e.NAMESPACE?e.NAMESPACE:Mt,jt=R(e,"MATHML_TEXT_INTEGRATION_POINTS")&&e.MATHML_TEXT_INTEGRATION_POINTS&&"object"==typeof e.MATHML_TEXT_INTEGRATION_POINTS?P(e.MATHML_TEXT_INTEGRATION_POINTS):M({},Ht),Gt=R(e,"HTML_INTEGRATION_POINTS")&&e.HTML_INTEGRATION_POINTS&&"object"==typeof e.HTML_INTEGRATION_POINTS?P(e.HTML_INTEGRATION_POINTS):M({},Bt);const t=R(e,"CUSTOM_ELEMENT_HANDLING")&&e.CUSTOM_ELEMENT_HANDLING&&"object"==typeof e.CUSTOM_ELEMENT_HANDLING?P(e.CUSTOM_ELEMENT_HANDLING):s(null);if(ot=s(null),R(t,"tagNameCheck")&&Vt(t.tagNameCheck)&&(ot.tagNameCheck=t.tagNameCheck),R(t,"attributeNameCheck")&&Vt(t.attributeNameCheck)&&(ot.attributeNameCheck=t.attributeNameCheck),R(t,"allowCustomizedBuiltInElements")&&"boolean"==typeof t.allowCustomizedBuiltInElements&&(ot.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),c(ot),ft&&(ct=!1),bt&&(Tt=!0),Ot&&(Qe=M({},Y),tt=s(null),!0===Ot.html&&(M(Qe,F),M(tt,q)),!0===Ot.svg&&(M(Qe,H),M(tt,X),M(tt,K)),!0===Ot.svgFilters&&(M(Qe,j),M(tt,X),M(tt,K)),!0===Ot.mathMl&&(M(Qe,G),M(tt,$),M(tt,K))),at.tagCheck=null,at.attributeCheck=null,R(e,"ADD_TAGS")&&("function"==typeof e.ADD_TAGS?at.tagCheck=e.ADD_TAGS:T(e.ADD_TAGS)&&(Qe===et&&(Qe=P(Qe)),M(Qe,e.ADD_TAGS,Xt))),R(e,"ADD_ATTR")&&("function"==typeof e.ADD_ATTR?at.attributeCheck=e.ADD_ATTR:T(e.ADD_ATTR)&&(tt===nt&&(tt=P(tt)),M(tt,e.ADD_ATTR,Xt))),R(e,"ADD_URI_SAFE_ATTR")&&T(e.ADD_URI_SAFE_ATTR)&&M(It,e.ADD_URI_SAFE_ATTR,Xt),R(e,"FORBID_CONTENTS")&&T(e.FORBID_CONTENTS)&&(vt===Dt&&(vt=P(vt)),M(vt,e.FORBID_CONTENTS,Xt)),R(e,"ADD_FORBID_CONTENTS")&&T(e.ADD_FORBID_CONTENTS)&&(vt===Dt&&(vt=P(vt)),M(vt,e.ADD_FORBID_CONTENTS,Xt)),_t&&(Qe["#text"]=!0),mt&&M(Qe,["html","head","body"]),Qe.table&&(M(Qe,["tbody"]),delete rt.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw k('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw k('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=Re;Re=e.TRUSTED_TYPES_POLICY;try{Ie=Me("")}catch(e){throw Re=t,e}}else null===e.TRUSTED_TYPES_POLICY?(Re=void 0,Ie=""):(void 0===Re&&(Re=ze()),Re&&"string"==typeof Ie&&(Ie=Me("")));l&&l(e),$t=e},Jt=M({},[...H,...j,...B]),Qt=M({},[...G,...W]),en=function(e){let t=_e(e);t&&t.tagName||(t={namespaceURI:zt,tagName:"template"});const n=b(e.tagName),o=b(t.tagName);return!!Ut[e.namespaceURI]&&(e.namespaceURI===Lt?function(e,t,n){return t.namespaceURI===Mt?"svg"===e:t.namespaceURI===xt?"svg"===e&&("annotation-xml"===n||jt[n]):Boolean(Jt[e])}(n,t,o):e.namespaceURI===xt?function(e,t,n){return t.namespaceURI===Mt?"math"===e:t.namespaceURI===Lt?"math"===e&&Gt[n]:Boolean(Qt[e])}(n,t,o):e.namespaceURI===Mt?function(e,t,n){return!(t.namespaceURI===Lt&&!Gt[n])&&!(t.namespaceURI===xt&&!jt[n])&&!Qt[e]&&(Wt[e]||!Jt[e])}(n,t,o):!("application/xhtml+xml"!==Yt||!Ut[e.namespaceURI]))},tn=function(e){g(o.removed,{element:e});try{_e(e).removeChild(e)}catch(t){if(Ee(e),!_e(e))throw k("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},nn=function(e){const t=Ne(e);if(t){const e=[];m(t,t=>{g(e,t)}),m(e,e=>{try{Ee(e)}catch(e){}})}const n=Oe(e);if(n)for(let t=n.length-1;t>=0;--t){const o=n[t],r=o&&o.name;if("string"==typeof r)try{e.removeAttribute(r)}catch(e){}}},on=function(e,t){try{g(o.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){g(o.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(Tt||bt)try{tn(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},rn=function(e){const t=Oe(e);if(t)for(let n=t.length-1;n>=0;--n){const o=t[n],r=o&&o.name;if("string"==typeof r&&!tt[Xt(r)])try{e.removeAttribute(r)}catch(e){}}},an=function(e){let t=null,n=null;if(yt)e="<remove></remove>"+e;else{const t=E(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===Yt&&zt===Mt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const o=Re?Me(e):e;if(zt===Mt)try{t=(new z).parseFromString(o,Yt)}catch(e){}if(!t||!t.documentElement){t=Ue.createDocument(zt,"template",null);try{t.documentElement.innerHTML=Pt?Ie:o}catch(e){}}const i=t.body||t.documentElement;return e&&n&&i.insertBefore(r.createTextNode(n),i.childNodes[0]||null),zt===Mt?je.call(t,mt?"html":"body")[0]:mt?t.documentElement:i},ln=function(e){return Fe.call(e.ownerDocument||e,e,x.SHOW_ELEMENT|x.SHOW_COMMENT|x.SHOW_TEXT|x.SHOW_PROCESSING_INSTRUCTION|x.SHOW_CDATA_SECTION,null)},cn=function(e){return e=A(e,We," "),e=A(e,Ye," "),e=A(e,qe," ")},sn=function(e){var t;e.normalize();const n=Fe.call(e.ownerDocument||e,e,x.SHOW_TEXT|x.SHOW_COMMENT|x.SHOW_CDATA_SECTION|x.SHOW_PROCESSING_INSTRUCTION,null);let o=n.nextNode();for(;o;)o.data=cn(o.data),o=n.nextNode();const r=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");r&&m(r,e=>{fn(e.content)&&sn(e.content)})},un=function(e){const t=De?De(e):null;return"string"==typeof t&&("form"===Xt(t)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||e.attributes!==Oe(e)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes||e.nodeType!==ve(e)||e.childNodes!==Ne(e)))},fn=function(e){if(!ve||"object"!=typeof e||null===e)return!1;try{return ve(e)===he}catch(e){return!1}},pn=function(e){if(!ve||"object"!=typeof e||null===e)return!1;try{return"number"==typeof ve(e)}catch(e){return!1}};function mn(e,t,n){0!==e.length&&m(e,e=>{e.call(o,t,n,$t)})}const dn=function(e){if(mn(Ge.beforeSanitizeElements,e,null),un(e))return tn(e),!0;const t=Xt(De?De(e):e.nodeName);if(mn(Ge.uponSanitizeElement,e,{tagName:t,allowedTags:Qe}),function(e,t){return!!(pt&&e.hasChildNodes()&&!pn(e.firstElementChild)&&I(ae,e.textContent)&&I(ae,e.innerHTML))||!(!pt||e.namespaceURI!==Mt||"style"!==t||!pn(e.firstElementChild))||e.nodeType===pe||!(!pt||e.nodeType!==me||!I(le,e.data))}(e,t))return tn(e),!0;if(rt[t]||!(at.tagCheck instanceof Function&&at.tagCheck(t))&&!Qe[t])return function(e,t){if(!rt[t]&&yn(t)){if(ot.tagNameCheck instanceof RegExp&&I(ot.tagNameCheck,t))return!1;if(ot.tagNameCheck instanceof Function&&ot.tagNameCheck(t))return!1}if(_t&&!vt[t]){const t=_e(e),n=Ne(e);if(n&&t)for(let o=n.length-1;o>=0;--o){const r=wt?n[o]:Se(n[o],!0);t.insertBefore(r,Ae(e))}}return tn(e),!0}(e,t);if((ve?ve(e):e.nodeType)===ue&&!en(e))return tn(e),!0;if(("noscript"===t||"noembed"===t||"noframes"===t)&&I(ce,e.innerHTML))return tn(e),!0;if(ft&&e.nodeType===fe){const t=cn(e.textContent);e.textContent!==t&&(g(o.removed,{element:e.cloneNode()}),e.textContent=t)}return mn(Ge.afterSanitizeElements,e,null),!1},hn=function(e,t,n){if(it[t])return!1;if(Et&&("id"===t||"name"===t)&&(n in r||n in Kt))return!1;const o=tt[t]||at.attributeCheck instanceof Function&&at.attributeCheck(t,e);if(ct&&I(Xe,t));else if(lt&&I($e,t));else if(o)if(It[t]);else if(I(Je,A(n,Ve,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==N(n,"data:")||!Rt[e]){if(st&&!I(Ke,A(n,Ve,"")));else if(n)return!1}else;else if(!(yn(e)&&(ot.tagNameCheck instanceof RegExp&&I(ot.tagNameCheck,e)||ot.tagNameCheck instanceof Function&&ot.tagNameCheck(e))&&(ot.attributeNameCheck instanceof RegExp&&I(ot.attributeNameCheck,t)||ot.attributeNameCheck instanceof Function&&ot.attributeNameCheck(t,e))||"is"===t&&ot.allowCustomizedBuiltInElements&&(ot.tagNameCheck instanceof RegExp&&I(ot.tagNameCheck,n)||ot.tagNameCheck instanceof Function&&ot.tagNameCheck(n))))return!1;return!0},gn=M({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),yn=function(e){return!gn[b(e)]&&I(Ze,e)},Tn=function(e,t,n,o){if(Re&&"object"==typeof Te&&"function"==typeof Te.getAttributeType&&!n)switch(Te.getAttributeType(e,t)){case"TrustedHTML":return Me(o);case"TrustedScriptURL":return function(e){Le(),xe++;try{return Re.createScriptURL(e)}finally{xe--}}(o)}return o},bn=function(e,t,n,r){try{n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),un(e)?tn(e):h(o.removed)}catch(n){on(t,e)}},Sn=function(e){mn(Ge.beforeSanitizeAttributes,e,null);const t=e.attributes;if(!t||un(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:tt,forceKeepAttr:void 0};let o=t.length;const r=Xt(e.nodeName);for(;o--;){const i=t[o],a=i.name,l=i.namespaceURI,c=i.value,s=Xt(a),u=c;let f="value"===a?u:_(u);n.attrName=s,n.attrValue=f,n.keepAttr=!0,n.forceKeepAttr=void 0,mn(Ge.uponSanitizeAttribute,e,n),f=n.attrValue,!At||"id"!==s&&"name"!==s||0===N(f,Nt)||(on(a,e),f=Nt+f),pt&&I(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)?on(a,e):"attributename"===s&&E(f,"href")?on(a,e):n.forceKeepAttr||(n.keepAttr&&(ut||!I(se,f))?(ft&&(f=cn(f)),hn(r,s,f)?(f=Tn(r,s,l,f),f!==u&&bn(e,a,l,f)):on(a,e)):on(a,e))}mn(Ge.afterSanitizeAttributes,e,null)},En=function(e){let t=null;const n=ln(e);for(mn(Ge.beforeSanitizeShadowDOM,e,null);t=n.nextNode();){mn(Ge.uponSanitizeShadowNode,t,null),dn(t),Sn(t),fn(t.content)&&En(t.content);if((ve?ve(t):t.nodeType)===ue){const e=we(t);fn(e)&&(An(e),En(e))}}mn(Ge.afterSanitizeShadowDOM,e,null)},An=function(e){const t=[{node:e,shadow:null}];for(;t.length>0;){const e=t.pop();if(e.shadow){En(e.shadow);continue}const n=e.node,o=(ve?ve(n):n.nodeType)===ue,r=Ne(n);if(r)for(let e=r.length-1;e>=0;--e)t.push({node:r[e],shadow:null});if(o){const e=De?De(n):null;if("string"==typeof e&&"template"===Xt(e)){const e=n.content;fn(e)&&t.push({node:e,shadow:null})}}if(o){const e=we(n);fn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return o.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null,r=null,a=null,l=null;if(Pt=!e,Pt&&(e="\x3c!--\x3e"),"string"!=typeof e&&!pn(e)&&"string"!=typeof(e=function(e){switch(typeof e){case"string":return e;case"number":return w(e);case"boolean":return O(e);case"bigint":return v?v(e):"0";case"symbol":return D?D(e):"Symbol()";case"undefined":default:return C(e);case"function":case"object":{if(null===e)return C(e);const t=e,n=U(t,"toString");if("function"==typeof n){const e=n(t);return"string"==typeof e?e:C(e)}return C(e)}}}(e)))throw k("dirty is not a string, aborting");if(!o.isSupported)return e;dt?(Qe=ht,tt=gt):Zt(t),(Ge.uponSanitizeElement.length>0||Ge.uponSanitizeAttribute.length>0)&&(Qe=P(Qe)),Ge.uponSanitizeAttribute.length>0&&(tt=P(tt)),o.removed=[];const c=wt&&"string"!=typeof e&&pn(e);if(c){const t=De?De(e):e.nodeName;if("string"==typeof t){const e=Xt(t);if(!Qe[e]||rt[e])throw k("root node is forbidden and cannot be sanitized in-place")}if(un(e))throw k("root node is clobbered and cannot be sanitized in-place");try{An(e)}catch(t){throw nn(e),t}}else if(pn(e))n=an("\x3c!----\x3e"),r=n.ownerDocument.importNode(e,!0),r.nodeType===ue&&"BODY"===r.nodeName||"HTML"===r.nodeName?n=r:n.appendChild(r),An(r);else{if(!Tt&&!ft&&!mt&&-1===e.indexOf("<"))return Re&&St?Me(e):e;if(n=an(e),!n)return Tt?null:St?Ie:""}n&&yt&&tn(n.firstChild);const s=ln(c?e:n);try{for(;a=s.nextNode();)dn(a),Sn(a),fn(a.content)&&En(a.content)}catch(t){throw c&&nn(e),t}if(c)return m(o.removed,e=>{e.element&&function(e){const t=[e];for(;t.length>0;){const e=t.pop();(ve?ve(e):e.nodeType)===ue&&rn(e);const n=Ne(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}}(e.element)}),ft&&sn(e),e;if(Tt){if(ft&&sn(n),bt)for(l=He.call(n.ownerDocument);n.firstChild;)l.appendChild(n.firstChild);else l=n;return(tt.shadowroot||tt.shadowrootmode)&&(l=Be.call(i,l,!0)),l}let u=mt?n.outerHTML:n.innerHTML;return mt&&Qe["!doctype"]&&n.ownerDocument&&n.ownerDocument.doctype&&n.ownerDocument.doctype.name&&I(re,n.ownerDocument.doctype.name)&&(u="<!DOCTYPE "+n.ownerDocument.doctype.name+">\n"+u),ft&&(u=cn(u)),Re&&St?Me(u):u},o.setConfig=function(){Zt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),dt=!0,ht=Qe,gt=tt},o.clearConfig=function(){$t=null,dt=!1,ht=null,gt=null,Re=Ce,Ie=""},o.isValidAttribute=function(e,t,n){$t||Zt({});const o=Xt(e),r=Xt(t);return hn(o,r,n)},o.addHook=function(e,t){"function"==typeof t&&R(Ge,e)&&g(Ge[e],t)},o.removeHook=function(e,t){if(R(Ge,e)){if(void 0!==t){const n=d(Ge[e],t);return-1===n?void 0:y(Ge[e],n,1)[0]}return h(Ge[e])}},o.removeHooks=function(e){R(Ge,e)&&(Ge[e]=[])},o.removeAllHooks=function(){Ge={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},o}();return Te});
!function(){"use strict";jQuery(".mphbmc-menu-currency-switcher-item a").on("click",function(e){var t;e.preventDefault(),e.stopPropagation(),e.currentTarget.parentElement.classList.contains("mphbmc-menu-currency-switcher-item-selected")||e.currentTarget.parentElement.parentElement.classList.contains("mphbmc-menu-currency-switcher-item-selected")||((t=new Date).setTime(t.getTime()+864e6),document.cookie="mphbmc_selected_currency="+encodeURIComponent(e.currentTarget.title)+"; expires="+t.toUTCString()+"; path="+MPHBMCMenuData.baseUrlPath+"; SameSite=Lax",location.reload())})}();
(()=>{"use strict";const e=window.wp.element,t=window.wp.hooks,o=window.ReactJSXRuntime,r=e=>{const{fill:t="#0FA961",...r}=e;return(0,o.jsxs)("svg",{width:"25",height:"25",viewBox:"0 0 256 256",fill:"none",xmlns:"http://www.w3.org/2000/svg",...r,children:[(0,o.jsx)("path",{d:"M97.0156 9.74499C120.404 0.0570803 146.141 -2.47884 170.971 2.45983C195.8 7.39873 218.609 19.59 236.51 37.4911L200.307 73.6942C189.566 62.9535 175.88 55.64 160.982 52.6766C146.085 49.7134 130.643 51.233 116.609 57.0458C102.576 62.8586 90.5814 72.7032 82.1426 85.3329C73.7038 97.9625 69.1992 112.811 69.1992 128.001C69.1992 140.594 72.2983 152.952 78.166 164.007C78.2596 164.006 78.3534 164.001 78.4473 164.001C89.4146 164.001 98.5033 172.026 100.17 182.524C105.185 179.335 111.141 177.497 117.525 177.518C133.572 177.572 146.835 189.36 149.221 204.729C153.155 204.564 157.087 204.1 160.982 203.325C175.88 200.362 189.566 193.046 200.307 182.306L236.51 218.511C218.609 236.412 195.8 248.603 170.971 253.542C146.141 258.48 120.404 255.945 97.0156 246.257C73.6273 236.569 53.6369 220.163 39.5723 199.114C25.5075 178.065 18 153.317 18 128.001C18 102.685 25.5074 77.9371 39.5723 56.8876C53.6369 35.8385 73.6272 19.433 97.0156 9.74499Z",fill:t}),(0,o.jsx)("path",{d:"M164 140.001C170.627 140.001 176 145.373 176 152.001C176 158.628 170.627 164.001 164 164.001C157.373 164.001 152 158.628 152 152.001C152 145.373 157.373 140.001 164 140.001Z",fill:t}),(0,o.jsx)("path",{d:"M108 108.001C114.627 108.001 120 113.373 120 120.001C120 126.628 114.627 132.001 108 132.001C101.373 132.001 96.0004 126.628 96 120.001C96 113.373 101.373 108.001 108 108.001Z",fill:t}),(0,o.jsx)("path",{d:"M152 76.0008C158.627 76.0008 164 81.3734 164 88.0008C164 94.6279 158.627 100.001 152 100.001C145.373 100.001 140 94.6279 140 88.0008C140 81.3734 145.373 76.0008 152 76.0008Z",fill:t})]})},n=window.wp.i18n,s=window.React,i=e=>{const t=(e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,o)=>o?o.toUpperCase():t.toLowerCase()))(e);return t.charAt(0).toUpperCase()+t.slice(1)},a=(...e)=>e.filter((e,t,o)=>Boolean(e)&&""!==e.trim()&&o.indexOf(e)===t).join(" ").trim(),c=e=>{for(const t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0};var l={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const d=(0,s.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:o=2,absoluteStrokeWidth:r,className:n="",children:i,iconNode:d,...u},b)=>(0,s.createElement)("svg",{ref:b,...l,width:t,height:t,stroke:e,strokeWidth:r?24*Number(o)/Number(t):o,className:a("lucide",n),...!i&&!c(u)&&{"aria-hidden":"true"},...u},[...d.map(([e,t])=>(0,s.createElement)(e,t)),...Array.isArray(i)?i:[i]])),u=(e,t)=>{const o=(0,s.forwardRef)(({className:o,...r},n)=>{return(0,s.createElement)(d,{ref:n,iconNode:t,className:a(`lucide-${c=i(e),c.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...r});var c});return o.displayName=i(e),o},b=u("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),h=u("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),k=u("globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),p=u("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]),g=e=>{const t=/^#?([a-f\d]{3}|[a-f\d]{6})$/i.exec(e||"");if(!t)return!1;const o=3===t[1].length?t[1].replace(/(.)/g,"$1$1"):t[1];return(.299*parseInt(o.slice(0,2),16)+.587*parseInt(o.slice(2,4),16)+.114*parseInt(o.slice(4,6),16))/255<.5},m=(e,{source:t="surecookie_plugin",medium:o="wordpress_plugin",campaign:r="core_plugin",content:n}={})=>{if(!e)return e;try{const s=new URL(e);return s.searchParams.set("utm_source",t),s.searchParams.set("utm_medium",o),s.searchParams.set("utm_campaign",r),n&&s.searchParams.set("utm_content",n),s.toString()}catch(t){return e}},f=window?.surecookieAdminData?.cookieCategories,_=(Array.isArray(f),window?.surecookieAdminData?.colorPalettes||{}),w=(Object.values(_),m("https://surecookie.com/share-usage-data/",{content:"usage_optin"}),(e,t="")=>{const o=window?.surecookieAdminData||window?.surecookieOnboardingData||window?.surecookiePublicSettings;return e&&o?.website_links?.[e]?o.website_links[e]:m(`https://surecookie.com/${t}`,{content:e})}),y=((0,n.__)("30 days","surecookie"),(0,n.__)("60 days","surecookie"),(0,n.__)("90 days","surecookie"),(0,n.__)("365 days","surecookie"),(0,n.__)("Never","surecookie"),new Set(["a","strong","em","b","i","u","s","br","hr","p","ul","ol","li","span","h1","h2","h3","h4","h5","h6","blockquote","pre"])),v={a:new Set(["href","title","target","rel"]),span:new Set(["style"]),strong:new Set,em:new Set,b:new Set,i:new Set,u:new Set,br:new Set,hr:new Set,p:new Set(["style"]),ul:new Set,ol:new Set,li:new Set},x=e=>{if(!e)return!1;const t=e.trim();if(t.startsWith("/")||t.startsWith("#")||t.startsWith("?"))return!0;try{const e=new URL(t,window.location.origin);return["http:","https:","mailto:","tel:"].includes(e.protocol)}catch{return!1}},C=(e,t)=>{if(1!==e.nodeType)return;const o=e.tagName.toLowerCase();if(!y.has(o)){const o=t.createDocumentFragment();for(;e.firstChild;)o.appendChild(e.firstChild);return void e.replaceWith(o)}for(const t of[...e.attributes]){const r=t.name.toLowerCase();(v[o]||new Set).has(r)?"a"!==o||"href"!==r||x(t.value)?"a"===o&&"target"===r&&"_blank"!==t.value&&e.removeAttribute("target"):e.removeAttribute("href"):e.removeAttribute(t.name)}if("a"===o){const t=e.getAttribute("rel")||"",o=new Set(t.split(/\s+/).map(e=>e.trim().toLowerCase()).filter(Boolean));"_blank"===e.getAttribute("target")&&(o.add("noopener"),o.add("noreferrer")),o.add("nofollow"),e.setAttribute("rel",[...o].join(" "))}for(const o of[...e.childNodes])C(o,t)},S=e=>{if(!e)return"";if("undefined"==typeof window||"undefined"==typeof DOMParser)return"";const t=String(e),o=(new DOMParser).parseFromString(`<div>${t}</div>`,"text/html"),r=o.body.firstElementChild;if(!r)return"";for(const e of[...r.childNodes])C(e,o);return r.innerHTML},j=e=>String(e??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;"),N=({modalDescription:e,cookiePolicyUrl:t,cookiePolicyTitle:o})=>{const r=S(e||"");if(!r.includes("{cookie_policy_link}"))return r;if(!t)return r.replace(/\s*\{cookie_policy_link\}\s*/g," ").replace(/\s+/g," ").trim();const s='<a href="'+j(t)+'" target="_blank" rel="noopener noreferrer" class="surecookie-modal-policy-link">'+j(o||(0,n.__)("Cookie Policy","surecookie"))+"</a>";return r.split("{cookie_policy_link}").join(s)},E=({isOpen:t,onClose:s,onSave:i,settings:a={},isPreview:c=!1})=>{const[l,d]=(0,e.useState)({}),[u,g]=(0,e.useState)([]),[m,f]=(0,e.useState)([]),[_,y]=(0,e.useState)([]),[v,x]=(0,e.useState)([]),[C,j]=(0,e.useState)(!0),[E,A]=(0,e.useState)(""),[O,P]=(0,e.useState)(window.innerWidth<=768),[D,M]=(0,e.useState)("cookies"),[I,L]=(0,e.useState)(!1),T=(0,e.useRef)(null),B=(0,e.useRef)(null),R=(0,e.useRef)(null);(0,e.useEffect)(()=>{t&&R.current&&(B.current=R.current.ownerDocument.activeElement)},[t]),(0,e.useEffect)(()=>{!t&&B.current&&(B.current.focus?.(),B.current=null)},[t]),(0,e.useEffect)(()=>{const e=window.matchMedia("(max-width: 768px)"),t=e=>P(e.matches);return e.addEventListener("change",t),()=>e.removeEventListener("change",t)},[]),(0,e.useEffect)(()=>{const e=window.surecookiePublicSettings?.cookie_categories||{},t=a.cookie_categories&&Object.keys(a.cookie_categories).length?Object.values(a.cookie_categories):Object.values(e);g(t);const o=Object.values(a?.custom_cookies||{});f(o);const r={};t.forEach(e=>{r[e.id]="essential"===e.id});const n=localStorage.getItem("surecookie_preferences");if(n)try{const e=JSON.parse(n);t.forEach(t=>{"essential"===t.id?r[t.id]=!0:void 0!==e[t.id]&&(r[t.id]=e[t.id])}),d(r)}catch(e){d(r)}else d(r);j(!1)},[a.cookie_categories,a.custom_cookies,t]),(0,e.useEffect)(()=>{t||(y([]),M("cookies"),L(!1))},[t]);const q=Boolean(a.consent_forwarding_enabled??window?.surecookiePublicSettings?.consent_forwarding_enabled),$=Boolean(a.consent_forwarding_show_sites??window?.surecookiePublicSettings?.consent_forwarding_show_sites),W=a.consent_forwarding_partner_sites??window?.surecookiePublicSettings?.consent_forwarding_partner_sites,z=Array.isArray(W)?W:W&&"object"==typeof W?Object.values(W):[],J=[...new Set(z.filter(e=>"string"==typeof e&&/^https?:\/\//i.test(e)&&e.replace(/\/+$/,"")!==window.location.origin))],U=a.consent_forwarding_description??window?.surecookiePublicSettings?.consent_forwarding_description??"",F=(0,e.useMemo)(()=>S(U||""),[U]),K=q&&$;(0,e.useEffect)(()=>{if(t&&T.current){const e=setTimeout(()=>{T.current.focus()},100);return()=>clearTimeout(e)}},[t]);const H=(0,e.useCallback)(e=>e?Array.from(e.querySelectorAll('button:not([disabled]), a[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])')):[],[]),G=(0,e.useCallback)(e=>{if(!t)return;if("Escape"===e.key)return e.preventDefault(),void s();if("Tab"!==e.key)return;const o=H(T.current);if(0===o.length)return;const r=o[0],n=o[o.length-1];e.shiftKey?T.current.ownerDocument.activeElement===r&&(e.preventDefault(),n.focus()):T.current.ownerDocument.activeElement===n&&(e.preventDefault(),r.focus())},[t,s,H]);(0,e.useEffect)(()=>(document.addEventListener("keydown",G),()=>document.removeEventListener("keydown",G)),[G]);const Z=()=>{const e={};u.forEach(t=>{e[t.id]=!0}),d(e),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"accepted"),A((0,n.__)("All cookies accepted.","surecookie")),i(e)},X=()=>{const e={};u.forEach(t=>{"essential"===t.id?e[t.id]=!0:e[t.id]=!1}),d(e),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"declined"),A((0,n.__)("Non-essential cookies rejected.","surecookie")),i(e)},Y=()=>{localStorage.setItem("surecookie_preferences",JSON.stringify(l)),window.surecookieManager&&window.surecookieManager.saveConsent(l,"partially_accepted"),A((0,n.__)("Preferences saved successfully.","surecookie")),i(l)},V=a.cookie_policy_page_url||window?.surecookiePublicSettings?.cookie_policy_page_url||"",Q=a.cookie_policy_page_title||window?.surecookiePublicSettings?.cookie_policy_page_title||"",ee=a.preferences_modal_heading||window?.surecookiePublicSettings?.preferences_modal_heading||"",te=a.preferences_modal_description||window?.surecookiePublicSettings?.preferences_modal_description||"",oe=a.text_color||"var(--surecookie-banner-text-color, #374151)",re=a.text_color||"var(--surecookie-banner-text-color, #ffffff)",ne=a.banner_bg_color||"var(--surecookie-banner-background-color, #111827)",se="#37415126",ie=(0,o.jsx)("div",{"aria-live":"polite","aria-atomic":"true",className:"surecookie-sr-only",children:E});return t?(0,o.jsxs)("div",{ref:R,children:[ie,(0,o.jsx)("div",{className:"surecookie-modal-backdrop",onClick:s,children:(0,o.jsx)("div",{className:"surecookie-modal-wrapper",children:(0,o.jsxs)("div",{ref:T,role:"dialog","aria-modal":"true","aria-labelledby":"surecookie-modal-title","aria-describedby":"surecookie-modal-description",className:"surecookie-preferences-modal",style:{backgroundColor:ne,color:oe,...a.banner_bg_color&&{"--surecookie-banner-background-color":a.banner_bg_color},...a.text_color&&{"--surecookie-banner-text-color":a.text_color},...a.accept_btn_color&&{"--surecookie-banner-primary-color":a.accept_btn_color},...a.decline_btn_color&&{"--surecookie-banner-secondary-color":a.decline_btn_color}},onClick:e=>e.stopPropagation(),tabIndex:"-1",children:[(0,o.jsxs)("div",{className:"surecookie-modal-header",children:[(0,o.jsxs)("div",{className:"surecookie-modal-header-text",children:[(0,o.jsx)("h2",{id:"surecookie-modal-title",className:"surecookie-modal-title",children:ee}),(0,o.jsx)("div",{id:"surecookie-modal-description",className:"surecookie-modal-description",dangerouslySetInnerHTML:{__html:N({modalDescription:te,cookiePolicyUrl:V,cookiePolicyTitle:Q})}})]}),(0,o.jsx)("button",{type:"button",className:"surecookie-modal-close-btn",onClick:s,"aria-label":(0,n.__)("Close privacy preferences dialog","surecookie"),children:(0,o.jsx)(b,{size:20,"aria-hidden":"true"})})]}),K&&(0,o.jsxs)("div",{className:"surecookie-modal-tabs",role:"tablist","aria-label":(0,n.__)("Preference sections","surecookie"),tabIndex:-1,onKeyDown:e=>{let t=null;"ArrowRight"===e.key||"ArrowLeft"===e.key?t="cookies"===D?"forwarding":"cookies":"Home"===e.key?t="cookies":"End"===e.key&&(t="forwarding"),t&&t!==D&&(e.preventDefault(),M(t),T.current?.ownerDocument?.getElementById(`surecookie-tab-btn-${t}`)?.focus())},children:[(0,o.jsx)("button",{type:"button",role:"tab","aria-selected":"cookies"===D,"aria-controls":"surecookie-tab-cookies",id:"surecookie-tab-btn-cookies",tabIndex:"cookies"===D?0:-1,className:"surecookie-modal-tab "+("cookies"===D?"active":""),onClick:()=>M("cookies"),children:(0,n.__)("Cookies","surecookie")}),(0,o.jsx)("button",{type:"button",role:"tab","aria-selected":"forwarding"===D,"aria-controls":"surecookie-tab-forwarding",id:"surecookie-tab-btn-forwarding",tabIndex:"forwarding"===D?0:-1,className:"surecookie-modal-tab "+("forwarding"===D?"active":""),onClick:()=>M("forwarding"),children:(0,n.__)("Consent Forwarding","surecookie")})]}),K&&(0,o.jsxs)("div",{id:"surecookie-tab-forwarding",role:"tabpanel","aria-labelledby":"surecookie-tab-btn-forwarding",className:"surecookie-forwarding-panel",hidden:"forwarding"!==D,children:[F&&(0,o.jsx)("div",{className:"surecookie-forwarding-description",dangerouslySetInnerHTML:{__html:F}}),J.length>0?(0,o.jsxs)("div",{className:"surecookie-forwarding-accordion",children:[(0,o.jsxs)("button",{type:"button",className:"surecookie-forwarding-toggle","aria-expanded":I,"aria-controls":"surecookie-forwarding-sites-list",onClick:()=>L(e=>!e),children:[(0,o.jsx)("span",{className:"surecookie-forwarding-count",children:(0,n.sprintf)( 
(0,n.__)("%d connected site(s)","surecookie"),J.length)}),(0,o.jsx)("span",{className:"surecookie-forwarding-chevron "+(I?"expanded":""),"aria-hidden":"true",children:(0,o.jsx)(h,{size:14,strokeWidth:2.5,focusable:"false"})})]}),(0,o.jsx)("ul",{id:"surecookie-forwarding-sites-list",className:"surecookie-forwarding-sites",hidden:!I,"aria-label":(0,n.__)("Sites that will receive your consent","surecookie"),children:I&&J.map(e=>(0,o.jsx)("li",{className:"surecookie-forwarding-site",children:(0,o.jsxs)("a",{href:e,target:"_blank",rel:"noopener noreferrer",className:"surecookie-forwarding-site-link",children:[(0,o.jsx)(k,{size:13,"aria-hidden":"true",focusable:"false",className:"surecookie-forwarding-site-globe"}),(0,o.jsx)("span",{className:"surecookie-forwarding-site-url",children:e}),(0,o.jsx)(p,{size:11,"aria-hidden":"true",focusable:"false",className:"surecookie-forwarding-site-ext"})]})},e))})]}):(0,o.jsx)("p",{className:"surecookie-forwarding-note",children:(0,n.__)("No partner sites configured.","surecookie")})]}),(0,o.jsx)("div",{id:"surecookie-tab-cookies",role:K?"tabpanel":void 0,"aria-labelledby":K?"surecookie-tab-btn-cookies":void 0,hidden:K&&"cookies"!==D,className:"surecookie-categories-wrapper",children:(0,o.jsx)("div",{className:"surecookie-categories-scroll",children:(0,o.jsxs)("div",{className:"surecookie-categories-list",role:"status","aria-live":"polite","aria-busy":C,children:[C&&[1,2,3,4].map(e=>(0,o.jsx)("div",{className:"surecookie-category-item",style:{borderBottomColor:se},children:(0,o.jsxs)("div",{className:"surecookie-category-header",children:[(0,o.jsxs)("div",{className:"surecookie-category-trigger",children:[(0,o.jsx)("span",{className:"surecookie-skeleton surecookie-skeleton-icon"}),(0,o.jsx)("span",{className:"surecookie-skeleton surecookie-skeleton-title"})]}),1===e?(0,o.jsx)("span",{className:"surecookie-skeleton surecookie-skeleton-badge"}):(0,o.jsx)("span",{className:"surecookie-skeleton surecookie-skeleton-toggle"})]})},e)),!C&&u.map(e=>{const t=l[e.id],r=(s=e.id,m.filter(e=>e.category===s));var s;const i=_.includes(e.id),a=`surecookie-category-details-${e.id}`,c=`surecookie-cookie-table-${e.id}`;return(0,o.jsxs)("div",{className:"surecookie-category-item",style:{borderBottomColor:se},children:[(0,o.jsxs)("div",{className:"surecookie-category-header",children:[(0,o.jsxs)("button",{type:"button",className:"surecookie-category-trigger",onClick:()=>(e=>{y(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])})(e.id),"aria-expanded":i,"aria-controls":a,children:[(0,o.jsx)("span",{className:"surecookie-expand-icon "+(i?"expanded":""),style:{color:oe},"aria-hidden":"true",children:(0,o.jsx)(h,{size:18,strokeWidth:2.5,focusable:"false"})}),(0,o.jsx)("span",{className:"surecookie-category-name",style:{color:re},children:e.name})]}),(0,o.jsxs)("div",{className:"surecookie-category-controls",children:["essential"===e.id&&(0,o.jsx)("span",{className:"surecookie-always-active","aria-hidden":"true",children:(0,n.__)("Always Active","surecookie")}),(0,o.jsx)("button",{type:"button",className:"surecookie-toggle-btn",role:"switch","aria-checked":t?"true":"false","aria-label":"essential"===e.id?(0,n.sprintf)( 
(0,n.__)("%s: always active, cannot be disabled","surecookie"),e.name):e.name,onClick:()=>(e=>{const t=u.find(t=>t.id===e);t&&"essential"===t.id||d(t=>({...t,[e]:!t[e]}))})(e.id),"aria-disabled":"essential"===e.id,style:{backgroundColor:t?"var(--surecookie-banner-primary-color, #2563eb)":"#D1D5DB"},children:(0,o.jsx)("span",{className:"surecookie-toggle-knob "+(t?"checked":""),"aria-hidden":"true"})})]})]}),(0,o.jsx)("div",{id:a,className:"surecookie-category-details",hidden:!i,children:i&&(0,o.jsxs)(o.Fragment,{children:[e.description&&(0,o.jsx)("p",{className:"surecookie-category-desc",children:e.description}),r.length>0&&(0,o.jsxs)(o.Fragment,{children:[(0,o.jsxs)("button",{type:"button",className:"surecookie-cookie-table-toggle",onClick:t=>{t.stopPropagation(),(e=>{x(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])})(e.id)},"aria-expanded":v.includes(e.id),"aria-controls":c,children:[(0,o.jsx)("span",{className:"surecookie-cookie-table-label",children:(0,n.__)("View Cookies","surecookie")}),(0,o.jsx)("span",{className:"surecookie-table-chevron "+(v.includes(e.id)?"expanded":""),"aria-hidden":"true",children:(0,o.jsx)(h,{size:16,strokeWidth:2.5,focusable:"false"})})]}),(0,o.jsx)("div",{id:c,className:"surecookie-cookie-table-wrapper",hidden:!v.includes(e.id),children:v.includes(e.id)&&(0,o.jsxs)("table",{className:"surecookie-cookie-table","aria-label":(0,n.sprintf)( 
(0,n.__)("%s cookies details","surecookie"),e.name),children:[(0,o.jsx)("thead",{children:(0,o.jsxs)("tr",{children:[(0,o.jsx)("th",{scope:"col",children:(0,n.__)("Name","surecookie")}),(0,o.jsx)("th",{scope:"col",children:(0,n.__)("Provider","surecookie")}),(0,o.jsx)("th",{scope:"col",children:(0,n.__)("Duration","surecookie")}),(0,o.jsx)("th",{scope:"col",children:(0,n.__)("Expiry","surecookie")})]})}),(0,o.jsx)("tbody",{children:r.map(e=>(0,o.jsxs)("tr",{children:[(0,o.jsx)("td",{children:e.name}),(0,o.jsx)("td",{children:e.provider||"-"}),(0,o.jsx)("td",{children:e.duration||"-"}),(0,o.jsx)("td",{children:e.expires||"-"})]},e.id||`${e.category}-${e.name}`))})]})})]})]})})]},e.id)})]})})}),(0,o.jsx)("div",{className:"surecookie-modal-footer",children:O?(0,o.jsxs)(o.Fragment,{children:[(0,o.jsxs)("div",{style:{display:"flex",gap:"8px"},children:[(0,o.jsx)("button",{type:"button",className:"surecookie-btn-outline surecookie-btn-sm",onClick:c?void 0:Z,"aria-disabled":c?"true":void 0,children:(0,n.__)("Accept All","surecookie")}),(0,o.jsx)("button",{type:"button",className:"surecookie-btn-outline-secondary surecookie-btn-sm",onClick:c?void 0:X,"aria-disabled":c?"true":void 0,children:(0,n.__)("Reject All","surecookie")})]}),(0,o.jsx)("button",{type:"button",className:"surecookie-btn-primary surecookie-btn-sm",onClick:c?void 0:Y,"aria-disabled":c?"true":void 0,children:(0,n.__)("Confirm My Choices","surecookie")})]}):(0,o.jsxs)(o.Fragment,{children:[(0,o.jsxs)("div",{className:"surecookie-footer-actions",children:[(0,o.jsx)("button",{type:"button",className:"surecookie-btn-outline",onClick:c?void 0:Z,"aria-disabled":c?"true":void 0,children:(0,n.__)("Accept All","surecookie")}),(0,o.jsx)("button",{type:"button",className:"surecookie-btn-outline-secondary",onClick:c?void 0:X,"aria-disabled":c?"true":void 0,children:(0,n.__)("Reject All","surecookie")})]}),(0,o.jsx)("button",{type:"button",className:"surecookie-btn-primary",onClick:c?void 0:Y,"aria-disabled":c?"true":void 0,children:(0,n.__)("Confirm My Choices","surecookie")})]})}),!a.remove_branding&&(0,o.jsx)("div",{className:"surecookie-modal-footer-branding",style:{borderTopColor:"#37415126",justifyContent:"flex-end"},children:(0,o.jsxs)("a",{href:w("preferences_modal_branding"),target:"_blank",rel:"noopener noreferrer",className:"surecookie-modal-branding-content","aria-label":(0,n.__)("Powered by SureCookie (opens in new tab)","surecookie"),children:[(0,o.jsx)("span",{"aria-hidden":"true",children:(0,n.__)("Powered by","surecookie")}),(0,o.jsx)(r,{width:"10",height:"12","aria-hidden":!0,focusable:"false"}),(0,o.jsx)("span",{"aria-hidden":"true",children:"SureCookie"})]})})]})})})]}):ie};class A extends e.Component{constructor(e){super(e),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(e){console.warn("SureCookie: floating widget crashed and was disabled.",e)}render(){return this.state.hasError?null:this.props.children}}const O=({publicSettings:e,showBanner:o,bannerEnabled:r})=>(0,t.applyFilters)("surecookie.floatingWidget",null,{publicSettings:e,showBanner:o,bannerEnabled:r}),P=()=>{const s=(0,e.useMemo)(()=>window.surecookiePublicSettings||{},[]),i=(0,e.useMemo)(()=>{const e=(0,t.applyFilters)("surecookie.publicSettingsResolvers",[]);return Array.isArray(e)?e.filter(e=>"function"==typeof e):[]},[]),[a,c]=(0,e.useState)(s),[l,d]=(0,e.useState)(!1),[u,b]=(0,e.useState)(!1),h=(0,e.useRef)(null),k=(0,e.useRef)(null),p=(0,e.useRef)(null),[m,f]=(0,e.useState)(0===i.length),_=(0,e.useMemo)(()=>void 0===a.show_settings_btn_enabled||Boolean(a.show_settings_btn_enabled),[a.show_settings_btn_enabled]),y=Boolean(s?.is_banner_visibility_hidden),v=Boolean(s?.banner_enabled||s?.enable_banner),[x,C]=(0,e.useState)(!y&&(a.banner_enabled||a.enable_banner||!1)),j=y||v&&!x,N=a.message_heading||"",P=a.message_description??(0,n.__)("This website uses cookies to enhance your browsing experience, personalize content, provide social media features, and analyze our traffic. You can review and manage your cookie settings at any time, or accept all cookies to proceed.","surecookie"),D=(0,e.useMemo)(()=>S(P),[P]),M=!!a.consent_forwarding_enabled,I=a.consent_forwarding_description||"",L=(0,e.useMemo)(()=>S(I),[I]),T=a.notice_type||"banner",B=a.notice_position||"bottom",R=a.banner_width||"650",q=!!a.banner_overlay_enabled,$=(0,e.useMemo)(()=>a.locale?a.locale.replace("_","-"):document.documentElement.lang||void 0,[a.locale]),W="var(--surecookie-banner-text-color, #374151)",z=a.banner_logo||"",J=(e=>{const t=e?.accept_all_enabled;return!0===t||1===t||"1"===t})(a),U=a.banner_animation||"fade",F=a.active_law_id,K="opt-out"===(a.consent_model||"opt-in"),H=(0,e.useMemo)(()=>({accept:(0,n.__)("Only Essential","surecookie"),accept_all:(0,n.__)("Accept All","surecookie"),decline:(0,n.__)("Decline","surecookie"),preferences:(0,n.__)("Preferences","surecookie")}),[]),G=(e,t)=>{if(a.button_labels?.[e])return a.button_labels[e];const o=a.law_default_labels?.[e];return F&&o?o:t||H[e]||""},Z=G("accept",a.accept_btn_text),X=G("accept_all",a.accept_all_btn_text),Y=G("decline",a.decline_btn_text),V=G("preferences",a.preferences_btn_text),Q=(0,e.useMemo)(()=>{let e;return e=a.button_config&&Array.isArray(a.button_config)?a.button_config:K&&!a.button_config?["accept","decline"]:a.button_order||"accept_all,accept,preferences,decline",((e,{acceptAllEnabled:t})=>{const o=Array.isArray(e)?e.slice():String(e||"").split(",").map(e=>e.trim()).filter(Boolean);return t?o:o.filter(e=>"accept_all"!==e)})(e,{acceptAllEnabled:J})},[a.button_order,a.button_config,K,J]),ee=(0,e.useMemo)(()=>Object.values(a.cookie_categories||{}),[a.cookie_categories]),te=(0,e.useMemo)(()=>Object.values(a.custom_cookies||{}),[a.custom_cookies]),oe=(0,e.useMemo)(()=>a.scanned_cookies||[],[a.scanned_cookies]),re=(0,e.useMemo)(()=>{const e=new Set(te.map(e=>e.name)),t=oe.filter(t=>!e.has(t.name));return[...te,...t]},[te,oe]);(0,e.useEffect)(()=>{if(m||0===i.length)return;let e=!1;const t=(t={})=>{e||(Object.keys(t).length>0&&(c(e=>({...e,...t})),y?C(!1):void 0!==t.banner_enabled?C(Boolean(t.banner_enabled)):void 0!==t.enable_banner&&C(Boolean(t.enable_banner))),f(!0))};(async()=>{let e={};for(const t of i)try{const o=await t({...s,...e});o&&"object"==typeof o&&(e={...e,...o})}catch(e){}t(e)})();const o=setTimeout(()=>{e||t()},4e3);return()=>{e=!0,clearTimeout(o)}},[s,m,i]),(0,e.useEffect)(()=>{if(!m)return;if(!x)return void d(!1);(()=>{if(window.surecookieManager&&window.surecookieManager.hasConsent()){if(ne())return void d(!0);d(!1)}else d(!0)})();const e=()=>{!document.hidden&&x&&window.surecookieManager&&window.surecookieManager.hasConsent()&&ne()&&d(!0)};return document.addEventListener("visibilitychange",e),()=>{document.removeEventListener("visibilitychange",e)}},[x,te,_,m]),(0,e.useEffect)(()=>{const e=e=>{e.detail?d(!1):x&&d(!0)};return window.addEventListener("surecookie_changed",e),()=>{window.removeEventListener("surecookie_changed",e)}},[x]),(0,e.useEffect)(()=>{const e=e=>{e.detail&&"object"==typeof e.detail&&(c(t=>({...t,...e.detail})),void 0!==e.detail.banner_enabled&&C(!y&&Boolean(e.detail.banner_enabled)))};return window.addEventListener("surecookie_settings_changed",e),()=>{window.removeEventListener("surecookie_settings_changed",e)}},[]),(0,e.useEffect)(()=>{const e=()=>{j||(h.current=k.current?.ownerDocument?.activeElement??null,K&&x?(b(!1),d(!0)):(d(!1),b(!0)))},t=t=>{document.querySelector("[data-surecookie-reconsent]")&&t.target.closest("[data-surecookie-reconsent]")&&(t.preventDefault(),e())},o=t=>{" "===t.key&&document.querySelector("[data-surecookie-reconsent]")&&t.target.closest("[data-surecookie-reconsent]")&&(t.preventDefault(),e())};return document.addEventListener("surecookie_open_preferences",e),document.addEventListener("click",t),document.addEventListener("keydown",o),()=>{document.removeEventListener("surecookie_open_preferences",e),document.removeEventListener("click",t),document.removeEventListener("keydown",o)}},[K,x,j]),(0,e.useEffect)(()=>{if(!l)return;const e=e=>{if("Escape"===e.key){if(e.preventDefault(),q)return;return void d(!1)}if("Tab"!==e.key)return;const t=Array.from(p.current?.querySelectorAll('button:not([disabled]), a[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])')??[]);if(0===t.length)return;const o=t[0],r=t[t.length-1],n=p.current?.ownerDocument?.activeElement;e.shiftKey?n!==o&&p.current?.contains(n)||(e.preventDefault(),r.focus()):n!==r&&p.current?.contains(n)||(e.preventDefault(),o.focus())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[l,q]),(0,e.useEffect)(()=>{if(!l||!p.current)return;const e=setTimeout(()=>{const e=p.current?.querySelector("button:not([disabled])");e?e.focus():p.current?.focus()},100);return()=>clearTimeout(e)},[l]),(0,e.useEffect)(()=>{const e=k.current;if(!e)return;const t=e.ownerDocument||document,o=Array.from(t.body.children),r=e.closest("#surecookie-public-root");return o.forEach(e=>{e===r||e.contains(r)||(u||l&&q?(e.setAttribute("inert",""),e.setAttribute("aria-hidden","true")):l?(e.removeAttribute("inert"),e.setAttribute("aria-hidden","true")):(e.removeAttribute("inert"),e.removeAttribute("aria-hidden")))}),()=>{o.forEach(e=>{e.removeAttribute("inert"),e.removeAttribute("aria-hidden")})}},[l,u,q]),(0,e.useEffect)(()=>{if(!(q&&l&&x||u))return;const{body:e}=document,t=e.style.overflow;return e.style.overflow="hidden",()=>{e.style.overflow=t}},[q,l,x,u]);const ne=()=>{if(!te||0===te.length)return!1;const e=window.surecookieManager.getConsent();if(!e||!e.preferences)return!1;const t=e.timestamp?new Date(e.timestamp):null,o=new Date;for(const r of te)if(r.expires){const n=new Date(r.expires);if(n<o&&(!t||n>t)&&e.preferences[r.category])return!0}return!1},se=(0,e.useCallback)(()=>{const e={};K?(ee&&ee.length>0?ee.forEach(t=>{e[t.id]=!0}):(e.essential=!0,e.functional=!0,e.analytics=!0,e.marketing=!0,e.uncategorized=!0),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"accepted")):(ee&&ee.length>0?ee.forEach(t=>{e[t.id]="essential"===t.id}):(e.essential=!0,e.functional=!1,e.analytics=!1,e.marketing=!1,e.uncategorized=!1),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"partially_accepted")),d(!1)},[ee,_,K]),ie=(0,e.useCallback)(()=>{if(!J)return;const e={};ee&&ee.length>0?ee.forEach(t=>{e[t.id]=!0}):(e.essential=!0,e.functional=!0,e.analytics=!0,e.marketing=!0,e.uncategorized=!0),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"accepted"),d(!1)},[J,ee,_]),ae=(0,e.useCallback)(()=>{const e={};ee&&ee.length>0?ee.forEach(t=>{"essential"===t.id?e[t.id]=!0:e[t.id]=!1}):(e.essential=!0,e.functional=!1,e.analytics=!1,e.marketing=!1,e.uncategorized=!1),localStorage.setItem("surecookie_preferences",JSON.stringify(e)),window.surecookieManager&&window.surecookieManager.saveConsent(e,"declined"),d(!1)},[ee,_]),ce=(0,e.useCallback)(e=>{e.preventDefault(),e.stopPropagation(),h.current=k.current?.ownerDocument?.activeElement??null,d(!1),b(!0)},[]),le=(0,e.useCallback)(()=>{b(!1),h.current&&(h.current.focus(),h.current=null),window.surecookieManager&&window.surecookieManager.hasConsent()||!x||d(!0)},[x]),de=(0,e.useCallback)(()=>{b(!1),d(!1)},[_]),ue=(e,t)=>({color:e,...t&&{borderColor:t}});return(0,o.jsxs)("div",{ref:k,className:"surecookie-public-banner-wrapper surecookie-styles",style:{...a.banner_bg_color&&{"--surecookie-banner-background-color":a.banner_bg_color},...a.text_color&&{"--surecookie-banner-text-color":a.text_color},...a.accept_btn_color&&{"--surecookie-banner-primary-color":a.accept_btn_color},...a.accept_btn_hover_color&&{"--surecookie-banner-primary-hover-color":a.accept_btn_hover_color},...a.decline_btn_color&&{"--surecookie-banner-secondary-color":a.decline_btn_color}},children:[x&&l&&q&&(0,o.jsx)("div",{className:"surecookie-banner-overlay","data-overlay":"true","aria-hidden":"true"}),x&&l&&(0,o.jsx)("div",{ref:p,role:"dialog","aria-modal":"true",lang:$,tabIndex:"-1","aria-labelledby":N?"surecookie-banner-heading":void 0,"aria-label":N?void 0:(0,n.__)("Cookie Consent","surecookie"),"aria-describedby":"surecookie-banner-description",style:{backgroundColor:"var(--surecookie-banner-background-color, #111827)",color:W,..."box"===T&&{width:`${R}px`}},className:`surecookie-public-banner surecookie-banner surecookie-container-mobile surecookie-banner-container ${"banner"===T?"surecookie-banner-container-banner":z?"surecookie-banner-container-box-with-logo":"surecookie-banner-container-box"} ${(()=>{if("banner"===T)return"top"===B?"surecookie-banner-position-top":"surecookie-banner-position-bottom";if("box"===T){const e="surecookie-banner-position-box-base";switch(B){case"bottom-left":return`${e} surecookie-banner-position-bottom-left`;case"bottom-center":return"surecookie-banner-position-bottom-center";case"bottom-right":default:return`${e} surecookie-banner-position-bottom-right`;case"middle":return"surecookie-banner-position-middle"}}return"surecookie-banner-position-bottom"})()} ${"slide"===U?"surecookie-banner-animation-slide":"surecookie-banner-animation-fade"}`,"data-banner":"true","data-dark-mode":g(a.banner_bg_color)||!a.banner_bg_color?"true":"false",children:(0,o.jsxs)("div",{className:"surecookie-banner-inner "+("box"===T?"surecookie-banner-inner-box":"surecookie-banner-inner-banner"),style:{..."box"===T&&{maxWidth:`${R}px`}},children:[z&&(0,o.jsx)("div",{className:"surecookie-banner-logo-wrapper",children:(0,o.jsx)("img",{src:z,alt:(0,n.__)("Banner logo","surecookie"),className:"surecookie-banner-logo"})}),(0,o.jsxs)("div",{className:"surecookie-content-mobile surecookie-banner-content "+("box"===T?"surecookie-banner-content-box":"surecookie-banner-content-banner"),children:[(0,o.jsxs)("div",{className:"surecookie-banner-text-wrapper",children:[N&&(0,o.jsx)("h3",{id:"surecookie-banner-heading",className:"surecookie-banner-heading",style:{color:W},children:N}),(0,o.jsxs)("div",{id:"surecookie-banner-description",className:"surecookie-banner-description",style:{color:W},children:[(0,o.jsx)("div",{dangerouslySetInnerHTML:{__html:D}}),M&&L&&(0,o.jsx)("div",{className:"surecookie-forwarding-description",dangerouslySetInnerHTML:{__html:L}})]}),"banner"===T&&!a.remove_branding&&(0,o.jsxs)("a",{href:w("banner_branding"),target:"_blank",rel:"noopener noreferrer",className:"surecookie-branding-mobile surecookie-branding",tabIndex:"-1","aria-label":(0,n.__)("Powered by SureCookie (opens in new tab)","surecookie"),children:[(0,o.jsx)("span",{"aria-hidden":"true",children:a.branding_powered_by||"Powered by"}),(0,o.jsx)(r,{width:"10",height:"12","aria-hidden":!0,focusable:"false"}),(0,o.jsx)("span",{"aria-hidden":"true",children:"SureCookie"})]})]}),(0,o.jsx)("div",{className:"surecookie-buttons-mobile surecookie-banner-buttons "+("box"===T?"surecookie-banner-buttons-box":"surecookie-banner-buttons-banner"),children:(()=>{const e={decline:(0,o.jsx)("button",{type:"button",className:"surecookie-decline-btn surecookie-button-mobile surecookie-btn-base",onClick:ae,"aria-label":(0,n.__)("Decline all non-essential cookies","surecookie"),style:ue("#ffffff"),children:Y},"decline"),preferences:(0,o.jsx)("button",{type:"button",className:"surecookie-preferences-btn surecookie-button-mobile surecookie-btn-base surecookie-btn-transparent surecookie-btn-font-semibold",onClick:ce,"aria-label":(0,n.__)("Manage cookie preferences","surecookie"),style:ue("var(--surecookie-banner-text-color, "+W+")"),children:V},"preferences"),accept:(0,o.jsx)("button",{type:"button",className:"surecookie-accept-btn surecookie-button-mobile surecookie-btn-base",onClick:se,"aria-label":(0,n.__)("Accept only essential cookies","surecookie"),style:ue("#ffffff"),children:Z},"accept"),accept_all:J?(0,o.jsx)("button",{type:"button",className:"surecookie-accept-all-btn surecookie-button-mobile surecookie-btn-base",onClick:ie,"aria-label":(0,n.__)("Accept all cookies","surecookie"),style:ue("#ffffff"),children:X},"accept_all"):null},t=Q.map(t=>e[t]).filter(Boolean);return"banner"===T||a.remove_branding?t:[...t,(0,o.jsxs)("a",{href:w("preferences_modal_branding"),target:"_blank",rel:"noopener noreferrer",className:"surecookie-branding-mobile surecookie-branding","aria-label":(0,n.__)("Powered by SureCookie (opens in new tab)","surecookie"),children:[(0,o.jsx)("span",{"aria-hidden":"true",children:(0,n.__)("Powered by","surecookie")}),(0,o.jsx)(r,{width:"10",height:"12","aria-hidden":!0,focusable:"false"}),(0,o.jsx)("span",{"aria-hidden":"true",children:"SureCookie"})]},"branding")]})()})]})]})}),m&&x&&(0,o.jsx)(A,{children:(0,o.jsx)(O,{publicSettings:a,showBanner:l,bannerEnabled:x})}),(0,o.jsx)(E,{isOpen:u,onClose:le,onSave:de,settings:{banner_bg_color:a.banner_bg_color,text_color:a.text_color,accept_btn_color:a.accept_btn_color,accept_btn_text_color:"#ffffff",decline_btn_color:a.decline_btn_color,decline_btn_text_color:"#ffffff",preferences_btn_text_color:a.text_color,decline_btn_border_color:a.decline_btn_border_color,cookie_categories:ee,custom_cookies:re,remove_branding:a.remove_branding,consent_forwarding_enabled:a.consent_forwarding_enabled,consent_forwarding_mode:a.consent_forwarding_mode,consent_forwarding_partner_sites:a.consent_forwarding_partner_sites,consent_forwarding_description:a.consent_forwarding_description,consent_forwarding_show_sites:a.consent_forwarding_show_sites}})]})},D=(e,t)=>{console.warn(`SureCookie: consent log request failed (HTTP ${e}).`);const o=new Error(t?.message||`Consent log request failed with status ${e}.`);throw o.status=e,t?.code&&(o.code=t.code),o},M=new Set(["text/javascript","module","application/javascript","application/ecmascript","text/ecmascript","importmap","speculationrules"]);function I(e,t){const o=e.getAttribute(t);if(!o||"none"===o)return null;const r=o.toLowerCase().trim();return M.has(r)?r:null}"undefined"!=typeof window&&(window.surecookieManager=new class{constructor(){this.CONSENT_COOKIE_NAME="surecookie_user_consent",this.SESSION_COOKIE_NAME="surecookie_session_id",this.CONSENT_COOKIE_EXPIRY=365,this.SESSION_COOKIE_EXPIRY=365,this.consentData=null,this.sessionId=null,this.dynamicObserver=null,this.loadConsent(),this.loadOrCreateSessionId()}loadOrCreateSessionId(){const e=this.getCookie(this.SESSION_COOKIE_NAME);return e?this.sessionId=e:(this.sessionId=this.generateUUID(),this.setCookie(this.SESSION_COOKIE_NAME,this.sessionId,this.SESSION_COOKIE_EXPIRY)),this.sessionId}generateUUID(){return"undefined"!=typeof crypto&&crypto.randomUUID?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.floor(16*Math.random());return("x"===e?t:t%4+8).toString(16)})}getSessionId(){return this.sessionId}loadConsent(){const e=this.getCookie(this.CONSENT_COOKIE_NAME);if(e)try{this.consentData=JSON.parse(decodeURIComponent(e))}catch(e){this.consentData=null}if(this.consentData&&this.isRenewalRequired()){this.deleteCookie(this.CONSENT_COOKIE_NAME),this.consentData=null;try{"undefined"!=typeof localStorage&&localStorage.removeItem("surecookie_preferences")}catch(e){}}}isRenewalRequired(){const e=parseInt(window.surecookiePublicSettings?.consent_renewed_at,10)||0;if(!e||!this.consentData)return!1;const t=Date.parse(this.consentData.timestamp);return isNaN(t)||t<1e3*e}saveConsent(e,t="custom"){const o=this.determineAction(e,t),r=this.consentData?JSON.stringify(this.consentData.preferences):null,n=this.consentData?this.consentData.action:null,s=null!==r&&r===JSON.stringify(e)&&n===o,i={preferences:e,action:o,timestamp:(new Date).toISOString()};this.consentData=i;const a=this.getConsentDuration(),c=encodeURIComponent(JSON.stringify(i));return this.setCookie(this.CONSENT_COOKIE_NAME,c,a),s||this.saveToDatabase(e,o),this.deleteDeclinedCookies(e),this.applyConsent(),this.updateGoogleConsent(e),this.updateWpConsentApi(e),setTimeout(()=>{this.triggerConsentChange(i)},0),i}updateGoogleConsent(e){if(!window.surecookiePublicSettings?.gcm_enabled||"function"!=typeof window.gtag)return;const t={ad_storage:e.marketing?"granted":"denied",ad_user_data:e.marketing?"granted":"denied",ad_personalization:e.marketing?"granted":"denied",personalization_storage:e.marketing?"granted":"denied",analytics_storage:e.analytics?"granted":"denied",functionality_storage:e.functional?"granted":"denied",security_storage:"granted"};window.gtag("consent","update",t),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"surecookie_consent_updated",consentState:t,surecookiePreferences:e}),window.dispatchEvent(new CustomEvent("surecookie_gcm_updated",{detail:{consentState:t,preferences:e,timestamp:Date.now()}}))}updateWpConsentApi(e){if("function"==typeof window.wp_set_consent)try{const t=window.surecookiePublicSettings?.wpConsentCategoryMap||{essential:"functional",functional:"preferences",analytics:"statistics",marketing:"marketing"},o=new Set;Object.entries(t).forEach(([t,r])=>{if(!(t in e))return;const n="essential"===t||e[t]?"allow":"deny";o.has(r)||(window.wp_set_consent(r,n),o.add(r))}),Object.keys(e).forEach(r=>{if(t[r])return;const n="marketing",s=e[r]?"allow":"deny";o.has(n)||(window.wp_set_consent(n,s),o.add(n))})}catch(e){console.error("SureCookie: WP Consent API sync failed",e)}}hasGlobalPrivacyControl(){return!0===navigator.globalPrivacyControl}getConsentDuration(){if(window.surecookiePublicSettings&&void 0!==window.surecookiePublicSettings.consent_duration_days){const e=parseInt(window.surecookiePublicSettings.consent_duration_days,10);if(!isNaN(e)&&e>=1&&e<=3650)return e}return 365}saveToDatabase(e,t){window.surecookiePublicSettings&&window.surecookiePublicSettings.consent_logging_enabled&&((e,t,o)=>{const r=window.surecookiePublicSettings?.api?.create_log||"/?rest_route=/surecookie/v1/consent-logs/create-log",n=n=>fetch(r,{method:"POST",credentials:"same-origin",headers:{"Content-Type":"application/json"},body:JSON.stringify({preferences:JSON.stringify(e),action_type:t,session_id:o,consent_log_token:n})}),s=window.surecookiePublicSettings?.consent_log_token??"",i=e=>e.json().catch(()=>({})).then(t=>D(e.status,t));return n(s).then(e=>e.ok?e.json():403!==e.status?i(e):e.json().catch(()=>({})).then(t=>s&&"surecookie_invalid_token"===t?.code?(e=>{const t=window.surecookiePublicSettings?.api?.token||"/?rest_route=/surecookie/v1/consent-logs/token";return fetch(t,{method:"POST",credentials:"same-origin",headers:{"Content-Type":"application/json"},body:JSON.stringify({stale_token:e})}).then(e=>e.ok?e.json():Promise.reject(new Error(`Token exchange failed (HTTP ${e.status}).`))).then(e=>{const t=e?.token;if(!t)throw new Error("Token exchange returned no token.");return window.surecookiePublicSettings&&(window.surecookiePublicSettings.consent_log_token=t),t})})(s).catch(()=>D(e.status,t)).then(e=>n(e)).then(e=>e.ok?e.json():i(e)):D(e.status,t))).catch(e=>{throw e.status||console.warn("SureCookie: consent log request failed (network error)."),e})})(e,t,this.sessionId).then(e=>{if(!e.success)throw e}).catch(e=>{})}getConsent(){return this.consentData}hasConsent(){return null!==this.consentData}isAllowed(e){if("quarantine"===e)return!1;const t=window.surecookiePublicSettings?.consent_model||"opt-in";return this.consentData?!0===this.consentData.preferences[e]:"opt-out"===t||"essential"===e}acceptAll(e){const t={};return e.forEach(e=>{t[e.id]=!0}),this.saveConsent(t,"accepted")}declineAll(e){const t={};return e.forEach(e=>{"essential"===e.id?t[e.id]=!0:t[e.id]=!1}),this.saveConsent(t,"declined")}saveCustomPreferences(e){return this.saveConsent(e,"partially_accepted")}clearConsent(){this.deleteCookie(this.CONSENT_COOKIE_NAME),this.consentData=null,this.triggerConsentChange(null)}applyConsent(){const e=window.surecookiePublicSettings?.consent_model||"opt-in";this.reflowCollapsedPlaceholders(),this.matchPlaceholderSizes(),this.consentData||"opt-out"===e?(document.querySelectorAll("script[data-consent]").forEach(e=>{const t=e.getAttribute("data-consent");this.isAllowed(t)&&this.executeScript(e)}),document.querySelectorAll('script[type="text/plain"][data-surecookie-category]').forEach(e=>{const t=e.getAttribute("data-surecookie-category");this.isAllowed(t)&&this.executeBlockedScript(e)}),document.querySelectorAll("iframe[data-surecookie-src], embed[data-surecookie-src]").forEach(e=>{const t=e.getAttribute("data-surecookie-category");this.isAllowed(t)&&this.loadBlockedSrcElement(e)}),document.querySelectorAll("object[data-surecookie-data]").forEach(e=>{const t=e.getAttribute("data-surecookie-category");this.isAllowed(t)&&this.loadBlockedObject(e)}),this.showPendingPlaceholders(),window.dispatchEvent(new CustomEvent("surecookie_applied",{detail:this.consentData}))):this.showPendingPlaceholders()}startDynamicObserver(){if(this.dynamicObserver)return;const e=e=>{1===e.nodeType&&("SCRIPT"===e.tagName&&"text/plain"===e.getAttribute("type")?.toLowerCase()&&e.hasAttribute("data-surecookie-category")?this.isAllowed(e.getAttribute("data-surecookie-category"))&&this.executeBlockedScript(e):"SCRIPT"===e.tagName&&e.hasAttribute("data-consent")?this.isAllowed(e.getAttribute("data-consent"))&&this.executeScript(e):"IFRAME"!==e.tagName&&"EMBED"!==e.tagName||!e.hasAttribute("data-surecookie-src")||!this.isAllowed(e.getAttribute("data-surecookie-category"))?"OBJECT"===e.tagName&&e.hasAttribute("data-surecookie-data")&&this.isAllowed(e.getAttribute("data-surecookie-category"))&&this.loadBlockedObject(e):this.loadBlockedSrcElement(e))};this.dynamicObserver=new MutationObserver(t=>{for(const o of t)for(const t of o.addedNodes)1===t.nodeType&&(t.classList?.contains("surecookie-placeholder")?(this.reflowCollapsedPlaceholders(t.parentNode||document),this.matchPlaceholderSizes(t.parentNode||document)):(this.reflowCollapsedPlaceholders(t),this.matchPlaceholderSizes(t)),e(t),t.querySelectorAll?.("script[data-surecookie-category], script[data-consent], iframe[data-surecookie-src], embed[data-surecookie-src], object[data-surecookie-data]")?.forEach(e),this.restorePrestoPlaceholders(t));this.hasConsent()&&this.areAllCategoriesAllowed()&&this.stopDynamicObserver()}),this.dynamicObserver.observe(document.documentElement,{childList:!0,subtree:!0}),window.addEventListener("pagehide",()=>this.stopDynamicObserver(),{once:!0})}stopDynamicObserver(){this.dynamicObserver&&(this.dynamicObserver.disconnect(),this.dynamicObserver=null)}areAllCategoriesAllowed(){const e=window.surecookiePublicSettings?.cookie_categories||{},t=Object.values(e).map(e=>e.id);return 0!==t.length&&t.every(e=>this.isAllowed(e))}loadBlockedSrcElement(e){const t=e.getAttribute("data-surecookie-src");if(!t)return;e.setAttribute("src",t),e.style.display="",e.removeAttribute("data-surecookie-src"),e.removeAttribute("data-surecookie-name"),e.removeAttribute("data-surecookie-category");const o=e.closest(".surecookie-placeholder");o&&o.parentNode&&o.replaceWith(e)}loadBlockedObject(e){const t=e.getAttribute("data-surecookie-data");if(!t)return;e.querySelectorAll("param[data-surecookie-param-name]").forEach(e=>{const t=e.getAttribute("data-surecookie-param-name");t&&(e.setAttribute("name",t),e.removeAttribute("data-surecookie-param-name"))}),e.setAttribute("data",t),e.removeAttribute("data-surecookie-data"),e.removeAttribute("data-surecookie-name"),e.removeAttribute("data-surecookie-category"),e.style.display="";const o=e.cloneNode(!0),r=e.closest(".surecookie-placeholder");r&&r.parentNode?r.replaceWith(o):e.parentNode?.replaceChild(o,e)}showPendingPlaceholders(){document.querySelectorAll(".surecookie-placeholder").forEach(e=>{e.classList.add("surecookie-pending")})}restorePrestoPlaceholders(e=document){const t=[];e.matches?.(".surecookie-placeholder-presto")&&t.push(e),e.querySelectorAll?.(".surecookie-placeholder-presto")?.forEach(e=>t.push(e)),t.forEach(e=>{const t=e.getAttribute("data-surecookie-category");if(!t||!this.isAllowed(t))return;const o=e.querySelector("template.surecookie-presto-restore");if(!o)return;const r=o.content.cloneNode(!0);r.querySelectorAll("script").forEach(e=>{const t=document.createElement("script");Array.from(e.attributes).forEach(e=>{t.setAttribute(e.name,e.value)}),t.textContent=e.textContent,e.parentNode.replaceChild(t,e)}),e.replaceWith(r)})}reflowCollapsedPlaceholders(e=document){const t=e.querySelectorAll?.(".surecookie-placeholder:not(.surecookie-reflowed)");if(!t||0===t.length)return;const o=[];t.forEach(e=>{const t=e.parentElement;if(!t||null===t.offsetParent)return;if(t.getBoundingClientRect().height>0)return;const r=parseInt(e.getAttribute("data-surecookie-width")||"0",10),n=parseInt(e.getAttribute("data-surecookie-height")||"0",10);!Number.isFinite(r)||!Number.isFinite(n)||r<=0||n<=0||o.push({ph:e,w:r,h:n})}),o.forEach(({ph:e,w:t,h:o})=>{e.style.position="relative",e.style.width="100%",e.style.maxWidth=t+"px",e.style.height="auto",e.style.aspectRatio=t+" / "+o,e.classList.add("surecookie-reflowed")})}matchPlaceholderSizes(e=document){const t=e.querySelectorAll?.(".surecookie-placeholder");t&&0!==t.length&&t.forEach(e=>{if(null===e.offsetParent)return;const t=e.querySelector("[data-surecookie-src], [data-surecookie-data]");if(!t)return;const o=t.style.display,r=t.style.visibility;t.style.visibility="hidden",t.style.display="";const n=t.offsetHeight;t.style.display=o,t.style.visibility=r,150!==n||t.hasAttribute("height")?n>0&&150!==n&&(e.style.height=n+"px",e.style.aspectRatio="auto"):(e.style.height="auto",e.style.aspectRatio="16 / 9")})}acceptCategoryFromPlaceholder(e){if(!e)return;const t=window.surecookiePublicSettings?.cookie_categories||{},o=this.consentData?.preferences||{},r=window.surecookiePublicSettings?.consent_model||"opt-in",n={};let s="partially_accepted";"opt-out"===r?(Object.values(t).forEach(e=>{n[e.id]=!0}),s="accepted"):Object.values(t).forEach(t=>{"essential"===t.id||t.id===e?n[t.id]=!0:n[t.id]=o[t.id]||!1}),localStorage.setItem("surecookie_preferences",JSON.stringify(n)),this.saveConsent(n,s)}executeScript(e){const t=document.createElement("script");Array.from(e.attributes).forEach(e=>{"data-consent"!==e.name&&"type"!==e.name&&t.setAttribute(e.name,e.value)}),e.textContent&&(t.textContent=e.textContent);const o=I(e,"data-original-type");null!==o&&t.setAttribute("type",o),e.parentNode.replaceChild(t,e)}executeBlockedScript(e){const t=document.createElement("script");Array.from(e.attributes).forEach(e=>{"type"===e.name||e.name.startsWith("data-surecookie")||t.setAttribute(e.name,e.value)});const o=I(e,"data-surecookie-original-type");null!==o&&t.setAttribute("type",o);const r=e.getAttribute("data-surecookie-src");r?t.src=r:e.textContent&&(t.textContent=e.textContent),e.parentNode.replaceChild(t,e)}triggerConsentChange(e){window.dispatchEvent(new CustomEvent("surecookie_changed",{detail:e}))}setCookie(e,t,o){const r=new Date;r.setTime(r.getTime()+24*o*60*60*1e3);let n=`${e}=${t};expires=${r.toUTCString()};path=/;SameSite=Lax`;"https:"===window.location.protocol&&(n+=";Secure"),document.cookie=n}getCookie(e){const t=e+"=",o=document.cookie.split(";");for(let e=0;e<o.length;e++){let r=o[e];for(;" "===r.charAt(0);)r=r.substring(1,r.length);if(0===r.indexOf(t))return r.substring(t.length,r.length)}return null}deleteCookie(e){document.cookie=`${e}=;expires=Thu, 01 Jan 1970 00:00:00 UTC;path=/;`}deleteDeclinedCookies(e){const t=window.surecookiePublicSettings?.custom_cookies;if(!t)return;const o=Array.isArray(t)?t:Object.values(t);Object.keys(e).forEach(t=>{e[t]||"essential"===t||o.filter(e=>e.category===t).forEach(e=>{this.deleteCookie(e.name)})})}getConsentSummary(){if(!this.consentData)return"No consent given";const{action:e,timestamp:t,preferences:o}=this.consentData;return{action:e,timestamp:t,allowed:Object.keys(o).filter(e=>o[e]),preferences:o}}determineAction(e,t){if("accepted"===t||"declined"===t||"partially_accepted"===t||"custom"===t)return t;const o=Object.values(e);if(o.every(e=>!0===e))return"accepted";const r=o.every(e=>!1===e),n=Object.keys(e).every(t=>"essential"===t?!0===e[t]:!1===e[t]);return r||n?"declined":"partially_accepted"}initOnLoad(){this.applyConsent();const e=this.getConsent();if(e&&(this.updateGoogleConsent(e.preferences),this.updateWpConsentApi(e.preferences)),this.hasGlobalPrivacyControl()){const e={essential:!0,functional:!1,analytics:!1,marketing:!1};this.updateGoogleConsent(e),this.updateWpConsentApi(e)}this.startDynamicObserver()}},document.addEventListener("click",e=>{const t=e.target;if(!t||"function"!=typeof t.closest)return;const o=t.closest(".surecookie-placeholder-button");if(!o)return;const r=o.getAttribute("data-surecookie-category");r&&window.surecookieManager.acceptCategoryFromPlaceholder(r)}),window.addEventListener("surecookie_applied",()=>{window.surecookieManager.restorePrestoPlaceholders()}),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>{window.surecookieManager.initOnLoad()}):window.surecookieManager.initOnLoad());const L=()=>{const t=document.getElementById("surecookie-public-root");t&&(0,e.createRoot)(t).render((0,o.jsx)(P,{}))};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",L):L()})();
(function($){
$(function(){
var user_agent=navigator.userAgent;
var is_opera_edge;
var browser=user_agent.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))/i)||[];
var browser_name='';
var browser_class='';
if(/trident/i.test(browser[0]) ){
browser_name='ie';
}else if(browser[0]==='Chrome'){
is_opera_edge=user_agent.match(/\b(OPR|Edge)/);
if(is_opera_edge!==null){
browser_name=is_opera_edge[0].replace('OPR', 'opera');
}}
if(''===browser_name){
if('standalone' in window.navigator&&!window.navigator.standalone){
browser_name='uiwebview';
}else{
browser_name=browser[0]&&''!==browser[0] ? browser[0]:navigator.appName;
}}
browser_name=browser_name.toLowerCase();
switch(browser_name){
case 'msie' :
browser_class='ie';
break;
case 'firefox' :
browser_class='gecko';
break;
default :
browser_class=browser_name;
break;
}
if(user_agent.match(/iPhone/)){
browser_class +=' iphone';
}
$('body').addClass(browser_class);
});
})(jQuery);