| Server IP : 127.0.1.1 / Your IP : 127.0.0.1 Web Server : Apache/2.4.52 (Ubuntu) System : Linux sealall 5.15.0-179-generic #189-Ubuntu SMP Tue May 5 18:20:56 UTC 2026 x86_64 User : devops ( 1000) PHP Version : 8.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/domains/sealall.ca/wp-content/litespeed/js/ |
Upload File : |
(()=>{const c=acss.color_mode,f=acss.enable_client_color_preference==="true",i=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light",r="color-scheme--alt",m="active",l=localStorage.getItem("acss-color-scheme"),a=()=>{document.documentElement.classList.add(r)},d=()=>{document.documentElement.classList.remove(r)},h=(e,o)=>{e.forEach(s=>{s.classList.add(m)}),o.forEach(s=>{s.classList.remove(m)})},g=()=>{document.documentElement.classList.contains(r)?(d(),localStorage.setItem("acss-color-scheme",c)):(a(),localStorage.setItem("acss-color-scheme",c==="dark"?"light":"dark"))},u=()=>{l?(l==="dark"&&c==="light"||l==="light"&&c==="dark")&&a():f&&(c==="dark"&&i==="light"&&l!=="dark"||c==="light"&&i==="dark"&&l!=="light")&&a()},n=e=>{!e||e.tagName==="INPUT"||(e.setAttribute("role","button"),e.setAttribute("tabindex","0"))};document.addEventListener("DOMContentLiteSpeedLoaded",()=>{const e=document.querySelectorAll('[data-acss-color-scheme="alt"]'),o=document.querySelectorAll('[data-acss-color-scheme="main"]'),s=document.querySelectorAll('[data-acss-color-scheme="toggle"]');e.forEach(t=>n(t)),o.forEach(t=>n(t)),s.forEach(t=>n(t)),e&&e.forEach(t=>{t.addEventListener("click",()=>{a(),document.documentElement.classList.contains(r)?localStorage.setItem("acss-color-scheme",c==="dark"?"light":"dark"):localStorage.setItem("acss-color-scheme",c),h(e,o)})}),o&&o.forEach(t=>{t.addEventListener("click",()=>{d(),localStorage.setItem("acss-color-scheme",c),h(o,e)})}),s&&s.forEach(t=>{t.addEventListener("click",()=>{g()})})}),u()})();
;function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}var _excluded=["name","url"];function _slicedToArray(e,t){return _arrayWithHoles(e)||_iterableToArrayLimit(e,t)||_unsupportedIterableToArray(e,t)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArrayLimit(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],c=!0,l=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}function _arrayWithHoles(e){if(Array.isArray(e))return e}function _objectWithoutProperties(e,t){if(null==e)return{};var n,r,i=_objectWithoutPropertiesLoose(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function _objectWithoutPropertiesLoose(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}function ownKeys(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(n),!0).forEach(function(t){_defineProperty(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ownKeys(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function _toConsumableArray(e){return _arrayWithoutHoles(e)||_iterableToArray(e)||_unsupportedIterableToArray(e)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArray(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function _arrayWithoutHoles(e){if(Array.isArray(e))return _arrayLikeToArray(e)}function _callSuper(e,t,n){return t=_getPrototypeOf(t),_possibleConstructorReturn(e,_isNativeReflectConstruct()?Reflect.construct(t,n||[],_getPrototypeOf(e).constructor):t.apply(e,n))}function _possibleConstructorReturn(e,t){if(t&&("object"==_typeof(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(e)}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _isNativeReflectConstruct(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(_isNativeReflectConstruct=function(){return!!e})()}function _getPrototypeOf(e){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},_getPrototypeOf(e)}function _inherits(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_setPrototypeOf(e,t)}function _setPrototypeOf(e,t){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_setPrototypeOf(e,t)}function _createForOfIteratorHelper(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=_unsupportedIterableToArray(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function _defineProperty(e,t,n){return(t=_toPropertyKey(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,_toPropertyKey(r.key),r)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return"symbol"==_typeof(t)?t:t+""}function _toPrimitive(e,t){if("object"!=_typeof(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=_typeof(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var BricksIntersect=_createClass(function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};_classCallCheck(this,e);var n=t.element||!1,r=t.callback||!1,i=!t.hasOwnProperty("once")||t.once,o=!!t.hasOwnProperty("trigger")&&t.trigger;if("IntersectionObserver"in window){var a=!1,s=new IntersectionObserver(function(e,t){e.forEach(function(e){var s="leaveView"===o?!e.isIntersecting&&a:e.isIntersecting;"leaveView"===o&&e.isIntersecting&&(a=!0),s&&(n&&r&&r(e.target),i&&t.unobserve(e.target))})},{threshold:t.threshold||0,root:t.root||null,rootMargin:(null==t?void 0:t.rootMargin)||"0px"});n instanceof Element&&s.observe(n)}else{var c=!1,l=function(){!1===c&&(c=!0,n.getBoundingClientRect().top<=window.innerHeight&&n.getBoundingClientRect().bottom>=0&&"none"!==window.getComputedStyle(n).display&&n&&r&&r(n),c=!1)};l(),document.addEventListener("scroll",l),window.addEventListener("resize",l),window.addEventListener("orientationchange",l)}});function BricksIsInViewport(e){var t=e.getBoundingClientRect();return t.top>=0&&t.left>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)}function bricksQuerySelectorAll(e,t){if(Array.isArray(t)){var n=[];return t.forEach(function(t){n=n.concat(Array.prototype.slice.apply(e.querySelectorAll(t)))}),n}return Array.prototype.slice.apply(e.querySelectorAll(t))}var bricksUtils={subscribeEvents:function(e,t,n){t.forEach(function(t){e.addEventListener(t,function(e){n(e)})})},subscribejQueryEvents:function(e,t,n){"undefined"!=typeof jQuery&&t.forEach(function(t){jQuery(e).on(t,function(e){n(e)})})},maybeRunOnceInteractions:function(e,t){var n=window.bricksData.interactions.findIndex(function(e){return e===t});-1!==n&&(null!=t&&t.runOnce&&window.bricksData.interactions.splice(n,1),bricksInteractionCallbackExecution(e,t))},hideOrShowLoadMoreButtons:function(e){var t=window.bricksData.queryLoopInstances[e]||!1;if(t||"all"===e){if("all"===e)for(var n in window.bricksData.queryLoopInstances)window.bricksData.queryLoopInstances.hasOwnProperty(n)&&bricksUtils.hideOrShowLoadMoreButtons(n);var r=window.bricksData.interactions.filter(function(t){return"loadMore"===t.action&&t.loadMoreQuery===e});if(r.length){var i=parseInt(t.page)<parseInt(t.maxPages);r.forEach(function(e){i?e.el.classList.remove("brx-load-more-hidden"):e.el.classList.add("brx-load-more-hidden")})}}},updateIsotopeInstance:function(e){var t,n,r,i=window.bricksData.isotopeInstances[e]||!1;if(i){if("masonry-element"===i.elementName){var o=i.instance.items.filter(function(e){return!e.element.isConnected});o.length>0&&i.instance.remove(o),i.instance.layout();var a=i.instance.element.querySelectorAll(":scope > *:not(.bricks-isotope-sizer):not(.bricks-gutter-sizer)");return a.length>0&&a.forEach(function(e){i.instance.items.find(function(t){return t.element===e})||i.instance.appended(e)}),void bricksUtils.updateIsotopeOnImageLoad(e)}null===(t=i.instance)||void 0===t||t.reloadItems(),null===(n=i.instance)||void 0===n||n.layout(),null===(r=i.instance)||void 0===r||r.arrange(),bricksUtils.updateIsotopeOnImageLoad(e)}},updateIsotopeOnImageLoad:function(e){if(document.body.classList.contains("bricks-is-frontend")){var t=window.bricksData.isotopeInstances[e]||!1;if(t){var n=Array.from(t.instance.element.querySelectorAll("img")).filter(function(e){return!e.complete||0===e.naturalHeight});if(0!==n.length){var r=0,i=!1,o=function(){i||(i=!0,requestAnimationFrame(function(){t.instance.layout(),i=!1}))},a=Math.min(3,Math.max(1,Math.ceil(n.length/5))),s=Date.now();n.forEach(function(e){var i=function(){r++;var c=Date.now();r%a===0||c-s>500||r===n.length?(t.instance.layout(),s=c):o(),e.removeEventListener("load",i),e.removeEventListener("error",i)};e.complete&&0!==e.naturalHeight?(r++,o()):(e.addEventListener("load",i),e.addEventListener("error",i))})}else t.instance.layout()}}},toggleAction:function(e){var t,n,r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=(null===(t=e.dataset)||void 0===t?void 0:t.selector)||".brxe-offcanvas",a=(null===(n=e.dataset)||void 0===n?void 0:n.attribute)||"class",s=(null===(r=e.dataset)||void 0===r?void 0:r.value)||"brx-open";i&&(o=(null==i?void 0:i.selector)||o,a=(null==i?void 0:i.attribute)||a,s=(null==i?void 0:i.value)||s);var c=!!o&&document.querySelector(o);if(c||(c=e.closest(".brxe-nav-nested")),c||(c=e.closest(".brxe-offcanvas")),c){document.querySelector(".brx-has-megamenu")&&(e.closest('[data-effect="offset"]')||bricksSubmenuPosition(0));var l,d,u,p,b=!1;if(b="class"===a?c.classList.contains(s):c.getAttribute(a)===s,e.setAttribute("aria-expanded",!b),b)e.classList.remove("is-active");else if(e.classList.add("is-active"),null!==(l=e.dataset)&&void 0!==l&&l.scriptId||null!==(d=e.dataset)&&void 0!==d&&d.interactionId)c.dataset.toggleScriptId=(null===(u=e.dataset)||void 0===u?void 0:u.scriptId)||(null===(p=e.dataset)||void 0===p?void 0:p.interactionId);var v="off";"class"===a?e.closest(".brxe-nav-nested")&&"brx-open"===s&&c.classList.contains("brx-open")?(v="on",c.classList.add("brx-closing"),setTimeout(function(){c.classList.remove("brx-closing"),c.classList.remove("brx-open")},200)):(v=c.classList.contains(s)?"on":"off",c.classList.toggle(s)):c.getAttribute(a)?(v="on",c.removeAttribute(a)):(v="off",c.setAttribute(a,s));var f,m=!1;if(c.classList.contains("brxe-offcanvas"))m="true"===(null===(f=c.dataset)||void 0===f?void 0:f.noAutoFocus)||!1,c.classList.remove("brx-closing");c.classList.contains("brxe-nav-nested")&&(m=!0),m||"off"!==v||bricksFocusOnFirstFocusableElement(c)}},debounce:function(e,t,n){var r;return function(){var i=this,o=arguments,a=n&&!r;clearTimeout(r),r=setTimeout(function(){r=null,n||e.apply(i,o)},t),a&&e.apply(i,o)}},maybeAbortXhr:function(e){var t=window.bricksData.queryLoopInstances[e]||!1;return t?(t.xhr&&(t.xhr.abort(),t.xhrAborted=!0),t.xhrAborted):t.xhrAborted},getPageNumberFromUrl:function(e){var t,n=1,r=new URL(e);if(r.searchParams.has("paged"))n=parseInt(r.searchParams.get("paged"));else if(e===(null===(t=window.bricksData)||void 0===t?void 0:t.baseUrl))n=1;else{var i=r.pathname.split("/").filter(function(e){return""!==e});n=i[i.length-1],isNaN(n)&&(n=1)}return n=parseInt(n)},updateQueryResultStats:function(e,t,n){var r={count:0,start:0,end:0};if("dom"===t){var i=n.querySelector('span[data-brx-qr-count="'.concat(e,'"]'));i&&(r.count=i.innerHTML);var o=n.querySelector('.brxe-query-results-summary[data-brx-qr-stats="'.concat(e,'"]'));if(o){var a,s=(null===(a=o.dataset)||void 0===a?void 0:a.brxQrStatsData)||!1;if(s){var c=JSON.parse(s);void 0!==(null==c?void 0:c.start)&&(r.start=c.start),void 0!==(null==c?void 0:c.end)&&(r.end=c.end),void 0!==(null==c?void 0:c.count)&&(r.count=c.count)}}}else void 0!==(null==n?void 0:n.count)&&(r.count=n.count),void 0!==(null==n?void 0:n.start)&&(r.start=n.start),void 0!==(null==n?void 0:n.end)&&(r.end=n.end);if(void 0!==(null==r?void 0:r.count)){var l=parseInt(r.count||0),d=parseInt(r.start||0),u=parseInt(r.end||0);document.querySelectorAll('span[data-brx-qr-count="'.concat(e,'"]')).forEach(function(e){e.innerHTML=l}),document.querySelectorAll('.brxe-query-results-summary[data-brx-qr-stats="'.concat(e,'"]')).forEach(function(e){var t,n=(null===(t=e.dataset)||void 0===t?void 0:t.brxQrStatsData)||!1;if(n){var r=JSON.parse(n),i=(null==r?void 0:r.statsFormat)||!1,o=(null==r?void 0:r.oneResultText)||!1,a=(null==r?void 0:r.noResultsText)||!1;if(l<1)e.innerHTML=a;else if(1===l)e.innerHTML=o;else{var s=i.replace("%start%",d).replace("%end%",u).replace("%total%",l);e.innerHTML=s}}})}},toggleMapInfoBox:function(e){var t,n;if(window.google&&window.google.maps){var r=e.el,i=e.action;if(r){var o=(null===(t=r.dataset)||void 0===t?void 0:t.brxInfoboxOpen)||!1,a=(null===(n=r.dataset)||void 0===n?void 0:n.brxInfoboxMapId)||!1;if(o&&a){var s=window.bricksData.googleMapInstances[a];if(s){var c=s.locations.find(function(e){return e.id===o});if(c&&c.marker){var l=c.infoBox;"openAddress"===i?l&&null!=l&&l.div_||google.maps.event.trigger(c.marker,"click"):l&&null!=l&&l.div_&&(google.maps.event.trigger(l,"closeclick"),l.close())}}}}}},closeAllSubmenus:function(e){var t=e.closest(".open"),n=e.closest(".brx-has-multilevel");if(t&&!n){var r=t.querySelector(".brx-submenu-toggle button[aria-expanded]");r&&(bricksSubmenuToggle(r,"remove"),r&&r.focus())}else{bricksQuerySelectorAll(document,'.brx-submenu-toggle > button[aria-expanded="true"]').forEach(function(e){e&&bricksSubmenuToggle(e,"remove")})}}},BricksFunction=function(){return _createClass(function e(t){var n,r,i,o,a=this;_classCallCheck(this,e),_defineProperty(this,"_customRun",null),_defineProperty(this,"_customEachElement",null),_defineProperty(this,"_customListenerHandler",null),_defineProperty(this,"_customAddEventListeners",null),_defineProperty(this,"_settings",{}),_defineProperty(this,"_initializedElements",new Set);var s={parentNode:document,selector:"",subscribeEvents:["bricks/ajax/pagination/completed","bricks/ajax/load_page/completed","bricks/ajax/popup/loaded","bricks/ajax/query_result/displayed"],subscribejQueryEvents:[],forceReinit:!1,frontEndOnly:!1,windowVariableCheck:[],additionalActions:[]};Object.assign(s,t),this._settings=s,this._customRun=null!==(n=null==t?void 0:t.run)&&void 0!==n?n:null,this._customEachElement=null!==(r=null==t?void 0:t.eachElement)&&void 0!==r?r:null,this._customListenerHandler=null!==(i=null==t?void 0:t.listenerHandler)&&void 0!==i?i:null,this._customAddEventListeners=null!==(o=null==t?void 0:t.addEventListeners)&&void 0!==o?o:null,this.cleanUpInitElements=this.cleanUpInitElements.bind(this),this.run=this.run.bind(this),this.eachElement=this.eachElement.bind(this),this.listenerHandler=this.listenerHandler.bind(this),this.addEventListeners=this.addEventListeners.bind(this),document.addEventListener("DOMContentLiteSpeedLoaded",function(){if(a.addEventListeners(),a._settings.additionalActions.length){var e,t=_createForOfIteratorHelper(a._settings.additionalActions);try{for(t.s();!(e=t.n()).done;){var n=e.value;"function"==typeof n&&n.call(a)}}catch(e){t.e(e)}finally{t.f()}}}),window.bricksFunctions||(window.bricksFunctions=[]),window.bricksFunctions.push(this)},[{key:"functionCanRun",value:function(){if(this._settings.frontEndOnly&&!document.body.classList.contains("bricks-is-frontend"))return!1;if(this._settings.windowVariableCheck.length){var e,t=_createForOfIteratorHelper(this._settings.windowVariableCheck);try{for(t.s();!(e=t.n()).done;){var n,r=e.value.split("."),i=window,o=_createForOfIteratorHelper(r);try{for(o.s();!(n=o.n()).done;){var a=n.value;if(!i.hasOwnProperty(a)){i=!1;break}i=i[a]}}catch(e){o.e(e)}finally{o.f()}if(!i)return!1}}catch(e){t.e(e)}finally{t.f()}}return!0}},{key:"cleanUpInitElements",value:function(){var e,t=_createForOfIteratorHelper(this._initializedElements);try{for(t.s();!(e=t.n()).done;){var n=e.value;n.isConnected||this._initializedElements.delete(n)}}catch(e){t.e(e)}finally{t.f()}}},{key:"eachElement",value:function(e){this._customEachElement&&"function"==typeof this._customEachElement&&this._customEachElement.call(this,e)}},{key:"run",value:function(e){var t=this;if(this.functionCanRun())if(this.cleanUpInitElements(),this._customRun&&"function"==typeof this._customRun)this._customRun.call(this,e);else{var n=Object.assign({},this._settings);e&&Object.keys(e).forEach(function(t){n.hasOwnProperty(t)&&(n[t]=e[t])});var r=bricksQuerySelectorAll(n.parentNode,n.selector);r.length&&r.forEach(function(e,r){if(n.forceReinit&&("function"==typeof n.forceReinit?n.forceReinit.call(t,e,r):n.forceReinit))return void t.eachElement(e,r);if(t._initializedElements.has(e)){var i=Array.from(t._initializedElements).find(function(t){return t===e});i.isConnected||(t._initializedElements.delete(i),t._initializedElements.add(e,r),t.eachElement(e,r))}else t._initializedElements.add(e),t.eachElement(e,r)})}}},{key:"listenerHandler",value:function(e){this._customListenerHandler&&"function"==typeof this._customListenerHandler?this._customListenerHandler.call(this,e):null!=e&&e.type&&(e.type,this.run())}},{key:"addEventListeners",value:function(){this.functionCanRun()&&(this._customAddEventListeners&&"function"==typeof this._customAddEventListeners?this._customAddEventListeners.call(this):(this._settings.subscribeEvents.length&&bricksUtils.subscribeEvents(document,this._settings.subscribeEvents,this.listenerHandler),this._settings.subscribejQueryEvents.length&&bricksUtils.subscribejQueryEvents(document,this._settings.subscribejQueryEvents,this.listenerHandler)))}}])}();function reinitBricksFunctions(){window.bricksFunctionInstances&&window.bricksFunctionInstances.forEach(function(e){e&&"function"==typeof e.run&&e.run()})}if("undefined"!=typeof window){window.bricksFunctionInstances=window.bricksFunctionInstances||[];var OriginalBricksFunction=BricksFunction;window.BricksFunction=function(){function e(t){var n;return _classCallCheck(this,e),n=_callSuper(this,e,[t]),window.bricksFunctionInstances.push(n),n}return _inherits(e,OriginalBricksFunction),_createClass(e)}(),Object.setPrototypeOf(window.BricksFunction.prototype,OriginalBricksFunction.prototype),Object.setPrototypeOf(window.BricksFunction,OriginalBricksFunction),void 0!==BricksFunction&&(BricksFunction=window.BricksFunction)}function bricksBlockEditorIntegration(){if(document.body.classList.contains("block-editor-page")){var e=function(){var t=document.querySelector(".wp-block-post-content");t?(new MutationObserver(function(){clearTimeout(window.bricksReinitTimeout),window.bricksReinitTimeout=setTimeout(reinitBricksFunctions,300)}).observe(t,{childList:!0,subtree:!0}),setTimeout(reinitBricksFunctions,200)):setTimeout(e,100)};"loading"===document.readyState?document.addEventListener("DOMContentLiteSpeedLoaded",e):e()}}var bricksLazyLoadFn=new BricksFunction({parentNode:document,selector:".bricks-lazy-hidden",subscribejQueryEvents:["updated_cart_totals"],eachElement:function(e){var t=window.bricksData.offsetLazyLoad||300;new BricksIntersect({element:e,callback:function(e){!function(e){if(e.classList.add("wait"),e.dataset.src&&(e.src=e.dataset.src,delete e.dataset.src,e.closest(".bricks-masonry"))){var t,n=null!==(t=e.closest(".bricks-masonry").getAttribute("data-script-id"))&&void 0!==t&&t;n&&e.addEventListener("load",function(){bricksUtils.updateIsotopeInstance(n)})}if(e.dataset.sizes&&(e.sizes=e.dataset.sizes,delete e.dataset.sizes),e.dataset.srcset&&(e.srcset=e.dataset.srcset,delete e.dataset.srcset),e.dataset.style){var r=e.getAttribute("style")||"";r+=e.dataset.style,e.setAttribute("style",r),e.classList.contains("splide__slide")||delete e.dataset.style}e.classList.remove("bricks-lazy-hidden"),e.classList.remove("wait"),e.classList.contains("bricks-lazy-load-isotope")&&bricksIsotope()}(e)},rootMargin:"".concat(t,"px")})},listenerHandler:function(e){setTimeout(function(){bricksLazyLoadFn.run()},100)}});function bricksLazyLoad(){bricksLazyLoadFn.run()}var bricksAnimationFn=new BricksFunction({parentNode:document,selector:".brx-animated",removeAfterMs:3e3,eachElement:function(e){new BricksIntersect({element:e,callback:function(e){var t=e.dataset.animation;t&&(e.classList.add("brx-animate-".concat(t)),e.removeAttribute("data-animation"),e.addEventListener("animationend",function(){var n;if(e.classList.remove("brx-animate-".concat(t)),e.classList.contains("brx-popup-content")&&t.includes("Out")){var r=e.closest(".brx-popup");r&&bricksClosePopup(r)}var i=null===(n=e.dataset)||void 0===n?void 0:n.animationId;if(e.style.animationDuration="",i){var o=new CustomEvent("bricks/animation/end/".concat(i),{detail:{el:e}});document.dispatchEvent(o)}},{once:!0}))}})},run:function(e){var t=bricksAnimationFn,n=(null==e?void 0:e.elementsToAnimate)||bricksQuerySelectorAll(t._settings.parentNode,t._settings.selector);t.removeAfterMs=(null==e?void 0:e.removeAfterMs)||t.removeAfterMs,n.forEach(function(e){t.eachElement(e)})}});function bricksAnimation(){bricksAnimationFn.run()}var bricksInitQueryLoopInstancesFn=new BricksFunction({parentNode:document,selector:".brx-query-trail",subscribeEvents:["bricks/ajax/load_page/completed"],eachElement:function(e){var t,n,r,i,o,a,s,c,l,d=(null===(t=e.dataset)||void 0===t?void 0:t.observerMargin)||"1px",u=(null===(n=e.dataset)||void 0===n?void 0:n.observerDelay)||0,p=(null===(r=e.dataset)||void 0===r?void 0:r.queryComponentId)||!1,b=null===(i=e.dataset)||void 0===i?void 0:i.queryElementId,v=null===(o=e.dataset)||void 0===o?void 0:o.queryVars,f=(null===(a=e.dataset)||void 0===a?void 0:a.originalQueryVars)||"[]",m=e.classList.contains("bricks-isotope-sizer"),g=e.classList.contains("brx-infinite-scroll"),y=null===(s=e.dataset)||void 0===s?void 0:s.brxAjaxLoader,w=null===(c=e.dataset)||void 0===c?void 0:c.brxLiveSearch,k=null===(l=e.dataset)||void 0===l?void 0:l.brxDisableUrlParams,h=document.querySelector('[data-brx-loop-start="'.concat(b,'"]'));h?(null==h||h.insertAdjacentHTML("beforebegin","\x3c!--brx-loop-start-".concat(b,"--\x3e")),h.removeAttribute("data-brx-loop-start")):e.insertAdjacentHTML("beforebegin","\x3c!--brx-loop-start-".concat(b,"--\x3e"));var x=(null==h?void 0:h.parentNode)||e.parentNode;window.bricksData.queryLoopInstances[b]={componentId:p,start:e.dataset.start,end:e.dataset.end,page:e.dataset.page,maxPages:e.dataset.maxPages,queryVars:v,originalQueryVars:f,observerMargin:d,observerDelay:u,infiniteScroll:g,isPostsElement:m,ajaxLoader:y,isLiveSearch:w,disableUrlParams:k,resultsContainer:x,xhr:null,xhrAborted:!1};var S=p||b;S.includes("-")&&(S=S.split("-")[0]);var L=m?e.previousElementSibling:Array.from(x.querySelectorAll(".brxe-".concat(S,":not(.brx-popup)"))).pop();e.removeAttribute("data-query-vars"),e.removeAttribute("data-original-query-vars"),m||e.remove(),L&&g&&(L.dataset.queryElementId=b,new BricksIntersect({element:L,callback:function(e){return bricksQueryLoadPage(e)},once:1,rootMargin:d}))}});function bricksInitQueryLoopInstances(){bricksInitQueryLoopInstancesFn.run()}function bricksAjaxLoader(){var e=function(e){var t="";switch(e){case"default":t='<div class="brx-loading-default"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>';break;case"ellipsis":t='<div class="brx-loading-ellipsis"><div></div><div></div><div></div><div></div></div>';break;case"ring":t='<div class="brx-loading-ring"><div></div><div></div><div></div><div></div></div>';break;case"dual-ring":t='<div class="brx-loading-dual-ring"></div>';break;case"facebook":t='<div class="brx-loading-facebook"><div></div><div></div><div></div></div>';break;case"roller":t='<div class="brx-loading-roller"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>';break;case"ripple":t='<div class="brx-loading-ripple"><div></div><div></div></div>';break;case"spinner":t='<div class="brx-loading-spinner"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>'}return t};document.addEventListener("bricks/ajax/start",function(t){var n=t.detail.queryId||!1;if(n){var r=window.bricksData.queryLoopInstances[n]||!1;if(r){var i=JSON.parse((null==r?void 0:r.ajaxLoader)||!1),o=(null==i?void 0:i.animation)||!1;if(o){var a,s,c=!(null==i||!i.selector)&&document.querySelector(i.selector);if(!c)c=null!==(a=Array.from(null===(s=r.resultsContainer)||void 0===s?void 0:s.querySelectorAll(".brxe-".concat(n,":not(.brx-popup)"))).pop())&&void 0!==a?a:r.resultsContainer;if(c){var l=c.nodeName.toLowerCase(),d=document.createElement(l);d.classList.add("brx-loading-animation"),d.dataset.ajaxLoaderQueryId=n,null!=i&&i.color&&d.style.setProperty("--brx-loader-color",i.color),null!=i&&i.scale&&(d.style.transform="scale(".concat(i.scale,")")),d.innerHTML=e(o),c.insertAdjacentElement(null!=i&&i.selector?"beforeend":"afterend",d)}}}}}),document.addEventListener("bricks/ajax/end",function(e){var t;(null!=e&&null!==(t=e.detail)&&void 0!==t&&t.queryId?document.querySelectorAll('.brx-loading-animation[data-ajax-loader-query-id="'.concat(e.detail.queryId,'"]')):[]).forEach(function(e){return e.remove()})}),document.addEventListener("bricks/ajax/popup/start",function(t){var n,r=t.detail.popupElement||!1;if(r){var i=JSON.parse((null===(n=r.dataset)||void 0===n?void 0:n.brxAjaxLoader)||!1),o=(null==i?void 0:i.animation)||!1;if(o){var a=!(null==i||!i.selector)&&document.querySelector(i.selector);if(a||(a=r.querySelector(".brx-popup-content")),a){var s=a.nodeName.toLowerCase(),c=document.createElement(s);c.classList.add("brx-loading-animation"),c.dataset.ajaxLoaderPopupId=r.dataset.popupId,null!=i&&i.color&&c.style.setProperty("--brx-loader-color",i.color),null!=i&&i.scale&&(c.style.transform="scale(".concat(i.scale,")")),c.innerHTML=e(o),a.insertAdjacentElement("afterbegin",c)}}}}),document.addEventListener("bricks/ajax/popup/end",function(e){var t;(null!=e&&null!==(t=e.detail)&&void 0!==t&&t.popupId?document.querySelectorAll('.brx-loading-animation[data-ajax-loader-popup-id="'.concat(e.detail.popupId,'"]')):[]).forEach(function(e){return e.remove()})})}function bricksQueryLoadPage(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise(function(r,i){var o,a=e.dataset.queryElementId,s=null===(o=window.bricksData.queryLoopInstances)||void 0===o?void 0:o[a];if(s&&(null==s||!s.isLoading||n)){var c=(null==s?void 0:s.componentId)||!1,l=parseInt(s.page||1)+1,d=parseInt(s.maxPages||1);if(l>d)r({page:l,maxPages:d});else{var u=window.bricksData.restApiUrl.concat("load_query_page"),p={postId:window.bricksData.postId,queryElementId:a,componentId:c,queryVars:s.queryVars,page:l,nonce:window.bricksData.nonce,lang:window.bricksData.language||!1,mainQueryId:window.bricksData.mainQueryId||!1};if("1"===window.bricksData.useQueryFilter&&"function"==typeof window.bricksUtils.getFiltersForQuery&&"function"==typeof window.bricksUtils.getSelectedFiltersForQuery){var b=[];if(window.bricksData.filterInstances&&Object.keys(window.bricksData.filterInstances).length>0)b=Object.values(window.bricksData.filterInstances).filter(function(e){return e.targetQueryId===a}).map(function(e){return e.filterId});if(b.length){var v=window.bricksUtils.getFiltersForQuery(a,"filterId"),f=window.bricksUtils.getSelectedFiltersForQuery(a),m=window.bricksUtils.getDynamicTagsForParse(a),g="[]"===(null==s?void 0:s.originalQueryVars)?null==s?void 0:s.queryVars:null==s?void 0:s.originalQueryVars;p={postId:window.bricksData.postId,queryElementId:a,originalQueryVars:g,pageFilters:window.bricksData.pageFilters||!1,filters:v,infinitePage:l,selectedFilters:f,afTags:m,nonce:window.bricksData.nonce,baseUrl:window.bricksData.baseUrl,lang:window.bricksData.language||!1,mainQueryId:window.bricksData.mainQueryId||!1},u=window.bricksData.restApiUrl.concat("query_result")}}window.bricksData.queryLoopInstances[a].isLoading=1,n||document.dispatchEvent(new CustomEvent("bricks/ajax/start",{detail:{queryId:a}})),"wpml"!==window.bricksData.multilangPlugin||!window.location.search.includes("lang=")&&3==window.bricksData.wpmlUrlFormat||(u=u.concat("?lang="+window.bricksData.language));var y=new XMLHttpRequest;y.open("POST",u,!0),y.setRequestHeader("Content-Type","application/json; charset=UTF-8"),y.setRequestHeader("X-WP-Nonce",window.bricksData.wpRestNonce),y.onreadystatechange=function(){if(y.readyState===XMLHttpRequest.DONE){var t,o,u=y.status;try{o=JSON.parse(y.response)}catch(e){o=null}if(0===u||u>=200&&u<400){var p,b,v,f,m=(null===(p=o)||void 0===p?void 0:p.html)||!1,g=(null===(b=o)||void 0===b?void 0:b.styles)||!1,w=(null===(v=o)||void 0===v?void 0:v.popups)||!1,k=(null===(f=o)||void 0===f?void 0:f.updated_query)||!1;m&&(m=m.replace(/<!--brx-loop-start-.*?-->/g,""),e.insertAdjacentHTML("afterend",m)),w&&document.body.insertAdjacentHTML("beforeend",w),document.dispatchEvent(new CustomEvent("bricks/ajax/nodes_added",{detail:{queryId:a}})),g&&document.body.insertAdjacentHTML("beforeend",g),k&&(k.start=parseInt(s.start),bricksUtils.updateQueryResultStats(a,"query",k)),window.bricksData.queryLoopInstances[a].page=l,void 0!==(null==k?void 0:k.max_num_pages)&&(window.bricksData.queryLoopInstances[a].maxPages=parseInt(k.max_num_pages))}else{if(403===u&&"rest_cookie_invalid_nonce"===(null===(t=o)||void 0===t?void 0:t.code)&&!n)return void bricksRegenerateNonceAndRetryQueryLoadPage(e).then(r).catch(i);console.error("Request failed with status ".concat(u))}window.bricksData.queryLoopInstances[a].isLoading=0,r({page:l,maxPages:d}),bricksUtils.hideOrShowLoadMoreButtons(a),document.dispatchEvent(new CustomEvent("bricks/ajax/end",{detail:{queryId:a}})),setTimeout(function(){var e,t,n=c&&!s.isPostsElement?Array.from(null===(e=s.resultsContainer)||void 0===e?void 0:e.querySelectorAll(".brxe-".concat(c,":not(.brx-popup)"))).pop():Array.from(null===(t=s.resultsContainer)||void 0===t?void 0:t.querySelectorAll(".brxe-".concat(a,":not(.brx-popup)"))).pop();document.dispatchEvent(new CustomEvent("bricks/ajax/load_page/completed",{detail:{queryTrailElement:n,queryId:a}})),s.infiniteScroll&&(n.dataset.queryElementId=a,BricksIsInViewport(n)?bricksQueryLoadPage(n):new BricksIntersect({element:n,callback:function(e){return bricksQueryLoadPage(e)},once:!0,rootMargin:s.observerMargin}))},250)}},t?y.send(JSON.stringify(p)):setTimeout(function(){y.send(JSON.stringify(p))},parseInt(s.observerDelay))}}})}function bricksRegenerateNonceAndRetryQueryLoadPage(e){return new Promise(function(t,n){var r=new XMLHttpRequest;r.open("POST",window.bricksData.ajaxUrl,!0),r.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),r.onreadystatechange=function(){if(r.readyState===XMLHttpRequest.DONE)if(r.status>=200&&r.status<400){var i;try{i=JSON.parse(r.responseText)}catch(e){return void n("Invalid response from server when regenerating nonce")}i.success&&i.data?(window.bricksData.nonce=i.data.bricks_nonce,window.bricksData.wpRestNonce=i.data.rest_nonce,bricksQueryLoadPage(e,!0,!0).then(t).catch(n)):n("Failed to regenerate nonces: Invalid response structure")}else n("Failed to regenerate nonce")},r.send("action=bricks_regenerate_query_nonce")})}var bricksQueryPaginationFn=new BricksFunction({parentNode:document,selector:".brx-ajax-pagination a",subscribeEvents:["bricks/ajax/pagination/completed","bricks/ajax/query_result/displayed"],eachElement:function(e){var t;null!==(t=e.dataset)&&void 0!==t&&t.ajaxPagination||(e.dataset.ajaxPagination=1,e.addEventListener("click",function(e){var t,n=e.currentTarget,r=n.getAttribute("href"),i=n.closest(".brx-ajax-pagination"),o=null==i||null===(t=i.dataset)||void 0===t?void 0:t.queryElementId;if(function(e){var t,n=!0;if(!window.bricksData.useQueryFilter||"function"!=typeof window.bricksUtils.getFiltersForQuery)return n;var r=e.closest(".brx-ajax-pagination"),i=(null==r||null===(t=r.dataset)||void 0===t?void 0:t.queryElementId)||!1;if(i){var o=bricksUtils.getFiltersForQuery(i);(o=o.filter(function(e){return"pagination"!==e.filterType})).length>0&&(n=!1)}return n}(i)){var a=parseInt(bricksUtils.getPageNumberFromUrl(r));a<1||(e.preventDefault(),bricksAjaxPagination(n,o,a))}}))}});function bricksAjaxPagination(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return new Promise(function(i,o){if(t){var a=e.getAttribute("href"),s=window.bricksData.queryLoopInstances[t]||!1,c=e.closest(".brx-ajax-pagination"),l=(null==s?void 0:s.componentId)||!1,d=(null==s?void 0:s.resultsContainer)||!1;if(s&&d){var u=window.bricksData.restApiUrl.concat("load_query_page"),p={postId:window.bricksData.postId,queryElementId:t,componentId:s.componentId||!1,queryVars:s.queryVars,page:n,nonce:window.bricksData.nonce,paginationId:c.dataset.paginationId,baseUrl:window.bricksData.baseUrl,lang:window.bricksData.language||!1,mainQueryId:window.bricksData.mainQueryId||!1};r||document.dispatchEvent(new CustomEvent("bricks/ajax/start",{detail:{queryId:t}})),"wpml"!==window.bricksData.multilangPlugin||!window.location.search.includes("lang=")&&3==window.bricksData.wpmlUrlFormat||(u=u.concat("?lang="+window.bricksData.language));var b=new XMLHttpRequest;b.open("POST",u,!0),b.setRequestHeader("Content-Type","application/json; charset=UTF-8"),b.setRequestHeader("X-WP-Nonce",window.bricksData.wpRestNonce),b.onreadystatechange=function(){if(this.readyState===XMLHttpRequest.DONE){var s,u,p=this.status;try{u=JSON.parse(b.response)}catch(e){u=null}if(0===p||p>=200&&p<400){var v,f,m,g,y,w=(null===(v=u)||void 0===v?void 0:v.html)||!1,k=(null===(f=u)||void 0===f?void 0:f.styles)||!1,h=(null===(m=u)||void 0===m?void 0:m.popups)||!1,x=(null===(g=u)||void 0===g?void 0:g.pagination)||!1,S=(null===(y=u)||void 0===y?void 0:y.updated_query)||!1,L=l||t;L.includes("-")&&(L=L.split("-")[0]);var E=d.querySelector(".bricks-gutter-sizer"),I=d.querySelector(".bricks-isotope-sizer"),A=d.querySelectorAll(".brxe-".concat(L,", .bricks-posts-nothing-found")),T=document.createNodeIterator(d,NodeFilter.SHOW_COMMENT,{acceptNode:function(e){return e.nodeValue==="brx-loop-start-".concat(t)}}).nextNode(),q=A.length>0||T;if(q&&d.querySelectorAll(".brxe-".concat(L,", .bricks-posts-nothing-found")).forEach(function(e){return e.remove()}),w)if(q){if(T){var F=w.match(/<\s*([a-z0-9]+)([^>]+)?>/i),C=null;(C=!F||"td"!==F[1]&&"tr"!==F[1]?document.createElement("div"):document.createElement("tbody")).innerHTML=w;var P=Array.from(C.childNodes);P.reverse(),P.forEach(function(e){var t,n;T.nextSibling?null===(t=T.parentNode)||void 0===t||t.insertBefore(e,T.nextSibling):null===(n=T.parentNode)||void 0===n||n.appendChild(e)}),C.remove()}}else d.insertAdjacentHTML("beforeend",w);if(E&&d.appendChild(E),I&&d.appendChild(I),document.querySelectorAll('.brx-popup[data-popup-loop="'.concat(t,'"]')).forEach(function(e){return e.remove()}),h&&document.body.insertAdjacentHTML("beforeend",h),x){var D=(new DOMParser).parseFromString(x,"text/html").querySelector(".bricks-pagination");D&&(c.innerHTML="",c.appendChild(D))}if(document.dispatchEvent(new CustomEvent("bricks/ajax/nodes_added",{detail:{queryId:t}})),k){var _=document.querySelector("#brx-query-styles-".concat(t));_||((_=document.createElement("style")).id="brx-query-styles-".concat(t),document.body.appendChild(_)),_.innerHTML=k}S&&(void 0!==(null==S?void 0:S.start)&&(window.bricksData.queryLoopInstances[t].start=parseInt(S.start)),bricksUtils.updateQueryResultStats(t,"query",S)),window.bricksData.queryLoopInstances[t].page=n,window.history.pushState({},"",a)}else{if(403===p&&"rest_cookie_invalid_nonce"===(null===(s=u)||void 0===s?void 0:s.code)&&!r)return void bricksRegenerateNonceAndRetryAjaxPagination(e,t,n).then(i).catch(o);console.error("Request failed with status ".concat(p))}i(),document.dispatchEvent(new CustomEvent("bricks/ajax/end",{detail:{queryId:t}})),document.dispatchEvent(new CustomEvent("bricks/ajax/pagination/completed",{detail:{queryId:t}})),bricksUtils.hideOrShowLoadMoreButtons(t)}},b.send(JSON.stringify(p))}else o("Query instance not found")}else o("Query ID is missing")})}function bricksRegenerateNonceAndRetryAjaxPagination(e,t,n){return new Promise(function(r,i){var o=new XMLHttpRequest;o.open("POST",window.bricksData.ajaxUrl,!0),o.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),o.onreadystatechange=function(){if(o.readyState===XMLHttpRequest.DONE)if(o.status>=200&&o.status<400){var a;try{a=JSON.parse(o.responseText)}catch(e){return void i("Invalid response from server when regenerating nonce")}a.success&&a.data?(window.bricksData.nonce=a.data.bricks_nonce,window.bricksData.wpRestNonce=a.data.rest_nonce,bricksAjaxPagination(e,t,n,!0).then(r).catch(i)):i("Failed to regenerate nonces: Invalid response structure")}else i("Failed to regenerate nonce")},o.send("action=bricks_regenerate_query_nonce")})}function bricksQueryPagination(){bricksQueryPaginationFn.run()}function bricksStickyHeader(){var e=document.querySelector("#brx-header.brx-sticky");if(e){var t,n,r=document.querySelector(".bricks-site-logo"),i=-1,o=e.hasAttribute("data-slide-up-after")?e.getAttribute("data-slide-up-after"):0;r&&(t=r.getAttribute("data-bricks-logo"),n=r.getAttribute("data-bricks-logo-inverse"));var a=function(){if(!document.body.classList.contains("no-scroll")){var a=window.scrollY;a>0?(e.classList.add("scrolling"),r&&n&&r.src!==n&&(r.src=n,r.srcset="")):(e.classList.remove("scrolling"),r&&t&&r.src!==t&&(r.src=t)),o&&!document.querySelector(".bricks-search-overlay.show")&&(a>i&&i>=0?a>o&&(e.classList.contains("slide-up")||e.classList.add("sliding"),e.classList.add("slide-up")):(e.classList.contains("slide-up")&&e.classList.add("sliding"),e.classList.remove("slide-up"))),i=a}};e.addEventListener("transitionend",function(t){"transform"===t.propertyName&&e.classList.remove("sliding")}),window.addEventListener("scroll",a),a()}}function bricksOnePageNavigation(){var e=document.getElementById("bricks-one-page-navigation");if(bricksIsFrontend&&e){var t=bricksQuerySelectorAll(document,"#brx-content > *"),n=[],r="",i="",o="";t&&(t.forEach(function(t){(r=t.getAttribute("id"))&&(n.push(r),o=document.createElement("li"),(i=document.createElement("a")).classList.add("bricks-one-page-".concat(r)),i.setAttribute("href","#".concat(r)),o.appendChild(i),e.appendChild(o))}),window.addEventListener("load",a),window.addEventListener("resize",a),document.addEventListener("scroll",a))}function a(){var e=window.scrollY;n.forEach(function(t){var n=document.getElementById(t),r=n.offsetTop,i=r+n.offsetHeight;e>=r-1&&e<i-1?document.querySelector(".bricks-one-page-".concat(t)).classList.add("active"):document.querySelector(".bricks-one-page-".concat(t)).classList.remove("active")})}}function bricksSearchToggle(){bricksQuerySelectorAll(document,".brxe-search").forEach(function(e){var t=e.querySelector(".toggle"),n=e.querySelector(".bricks-search-overlay");if(t&&n){var r=n.previousElementSibling;document.addEventListener("keyup",function(e){"Escape"===e.key&&("visible"===window.getComputedStyle(n).visibility&&(n.classList.remove("show"),r.focus(),r.setAttribute("aria-expanded",!1)))}),t.addEventListener("click",function(){n.classList.toggle("show"),t.setAttribute("aria-expanded","false"===t.getAttribute("aria-expanded")),setTimeout(function(){e.querySelector("input[type=search]").focus()},200)}),n.querySelector(".close").addEventListener("click",function(){n.classList.remove("show"),r.focus(),r.setAttribute("aria-expanded",!1)})}})}var bricksAlertDismissFn=new BricksFunction({parentNode:document,selector:".brxe-alert svg",eachElement:function(e){e.addEventListener("click",function(){e.closest(".brxe-alert").remove()})}});function bricksAlertDismiss(){bricksAlertDismissFn.run()}var bricksTabsFn=new BricksFunction({parentNode:document,selector:".brxe-tabs, .brxe-tabs-nested",forceReinit:function(e,t){return!bricksIsFrontend},eachElement:function(e){var t=window.location.hash,n=e.getAttribute("data-open-on")||"click",r=e.querySelector(".tab-title"),i=r?Array.from(r.parentNode.children).filter(function(e){return e.classList.contains("tab-title")}):[],o=e.querySelector(".tab-pane"),a=o?Array.from(o.parentNode.children).filter(function(e){return e.classList.contains("tab-pane")}):[];if(i.length&&a.length){i.forEach(function(t,r){t.addEventListener(n,function(){var n=null,o=null;i.forEach(function(e,i){i===r?(e.classList.add("brx-open"),e.setAttribute("aria-selected","true"),e.setAttribute("tabindex","0"),n=t):(e.classList.remove("brx-open"),e.setAttribute("aria-selected","false"),e.setAttribute("tabindex","-1"))}),a.forEach(function(e,t){t===r?(e.classList.add("brx-open"),o=e):e.classList.remove("brx-open")});var s=null==t||!t.id||t.id.startsWith("brxe-")||t.id.startsWith("brx-")?"":"#".concat(t.id);s?history.replaceState(null,null,s):history.replaceState(null,null," "),document.dispatchEvent(new CustomEvent("bricks/tabs/changed",{detail:{elementId:e.getAttribute("data-script-id"),activeIndex:r,activeTitle:n,activePane:o}}))}),t.addEventListener("keydown",function(e){var t;if("ArrowRight"===e.key)t=r+1===i.length?0:r+1;else if("ArrowLeft"===e.key)t=r-1<0?i.length-1:r-1;else if("Home"===e.key)e.preventDefault(),t=0;else{if("End"!==e.key)return;e.preventDefault(),t=i.length-1}i[t].focus(),i[t].click()})});var s=e.getAttribute("data-open-tab")||0;if(t){var c=i.findIndex(function(e){return(null==e?void 0:e.id)&&!e.id.startsWith("brxe-")&&e.id===t.replace("#","")});s=-1!==c?c:0}i[s]?i[s].classList.add("brx-open"):i[0].classList.add("brx-open"),a[s]?a[s].classList.add("brx-open"):a[0].classList.add("brx-open"),i.forEach(function(e){e.classList.contains("brx-open")?(e.setAttribute("aria-selected","true"),e.setAttribute("tabindex","0")):(e.setAttribute("aria-selected","false"),e.setAttribute("tabindex","-1"))}),bricksTabsAccordionLayoutOnMobile()}}});function bricksTabsAccordionLayoutOnMobile(){bricksQuerySelectorAll(document,".brxe-tabs, .brxe-tabs-nested").forEach(function(e){var t=parseInt(e.getAttribute("data-accordion-breakpoint"),10),n=e.querySelector(".tab-menu");if(t&&window.innerWidth<t){n&&(n.style.display="none"),e.querySelectorAll('.tab-title:not([data-brx-tab-mode="accordion"])').forEach(function(t,n){var r=e.querySelectorAll('[data-brx-tab-mode="accordion"]')[n];if(!t.hasAttribute("data-transferred")){var i=t.querySelector("span");i&&(r.insertBefore(i.cloneNode(!0),r.firstChild),i.remove(),t.classList.contains("brx-open")?r.classList.add("brx-open"):r.classList.remove("brx-open")),t.setAttribute("data-transferred","true")}}),e.querySelectorAll('[data-brx-tab-mode="accordion"]').forEach(function(e){return e.style.display="block"}),e.querySelectorAll(".tab-pane").forEach(function(e){e.removeAttribute("tabindex")});var r=e.querySelectorAll('[data-brx-tab-mode="accordion"]'),i=e.querySelector(".tab-pane");!function(e,t){e.forEach(function(n,r){n.addEventListener("click",function(){e.forEach(function(e,t){t===r?(n.classList.add("brx-open"),n.classList.contains("accordion-title")&&e.setAttribute("aria-expanded","true")):(e.classList.remove("brx-open"),e.classList.contains("accordion-title")&&e.setAttribute("aria-expanded","false"))}),t.forEach(function(e,t){t===r?e.classList.add("brx-open"):e.classList.remove("brx-open")});var i=null!=n&&n.id&&!n.id.startsWith("brxe-")?"#".concat(n.id):"";i?history.pushState("",document.title,window.location.pathname+i):history.pushState("",document.title,window.location.pathname+window.location.search)}),n.classList.contains("accordion-title")&&n.addEventListener("keydown",function(n){"Enter"!==n.key&&" "!==n.key||(n.preventDefault(),e.forEach(function(e,t){t===r?(e.classList.add("brx-open"),e.setAttribute("aria-expanded","true")):(e.classList.remove("brx-open"),e.setAttribute("aria-expanded","false"))}),t.forEach(function(e,t){t===r?e.classList.add("brx-open"):e.classList.remove("brx-open")}))})})}(r,i?Array.from(i.parentNode.children).filter(function(e){return e.classList.contains("tab-pane")}):[])}else{n&&(n.style.display=""),e.querySelectorAll('[data-brx-tab-mode="accordion"]').forEach(function(t,n){var r=e.querySelectorAll('.tab-title:not([data-brx-tab-mode="accordion"])')[n];if(r.hasAttribute("data-transferred")){var i=t.querySelector("span");i&&(r.insertBefore(i.cloneNode(!0),r.firstChild),i.remove(),t.classList.contains("brx-open")?r.classList.add("brx-open"):r.classList.remove("brx-open")),r.removeAttribute("data-transferred")}r.style.display="block"}),e.querySelectorAll('[data-brx-tab-mode="accordion"]').forEach(function(e){return e.style.display="none"}),e.querySelectorAll(".tab-pane").forEach(function(e){e.setAttribute("tabindex","0")});var o=e.querySelectorAll('[data-brx-tab-mode="accordion"]');o.forEach(function(e){var t=e.cloneNode(!0);e.parentNode.replaceChild(t,e)})}})}function bricksTabs(){bricksTabsFn.run()}var bricksVideoOverlayClickDetectorFn=new BricksFunction({parentNode:document,selector:".bricks-video-overlay, .bricks-video-overlay-icon, .bricks-video-preview-image",frontEndOnly:!0,eachElement:function(e){var t=function(e){var t=e.target.closest(".brxe-video");if(t){var n=t.querySelector(".bricks-video-preview-image");if(n){var r=document.createElement("iframe");_toConsumableArray(n.attributes).forEach(function(e){"class"!==e.name&&"style"!==e.name&&("data-iframe-src"!==e.name?r.setAttribute(e.name,e.value):r.setAttribute("src",e.value))}),n.replaceWith(r)}var i=t.querySelector("iframe");i&&i.getAttribute("src")&&(i.src+="&autoplay=1"),i&&i.removeAttribute("tabindex");var o=t.querySelector("video");o&&(o.play(),o.removeAttribute("tabindex"),setTimeout(function(){o.focus()},0))}};e.addEventListener("click",t),e.addEventListener("keydown",function(e){" "!==e.key&&"Enter"!==e.key||(e.preventDefault(),t(e))})}});function bricksVideoOverlayClickDetector(){bricksVideoOverlayClickDetectorFn.run()}var bricksBackgroundVideoInitFn=new BricksFunction({parentNode:document,selector:".bricks-background-video-wrapper",forceReinit:function(e,t){return!bricksIsFrontend},eachElement:function(e){if(!e.classList.contains("loaded")){var t,n=e.getAttribute("data-background-video-url");if(n&&!n.includes("http")){/^[a-zA-Z0-9_-]{11}$/.test(n)?n="https://www.youtube.com/watch?v=".concat(n):/^[0-9]{6,10}$/.test(n)&&(n="https://vimeo.com/".concat(n))}if(n){var r=parseInt(e.getAttribute("data-background-video-show-at-breakpoint"));if(!(r&&window.innerWidth<r)){var i=e.getAttribute("data-background-video-scale"),o=e.getAttribute("data-background-video-ratio")||"16:9",a=parseInt(o.split(":")[0]||16),s=parseInt(o.split(":")[1]||9),c=parseInt(e.getAttribute("data-background-video-start"))||0,l=parseInt(e.getAttribute("data-background-video-end"))||0,d=1==e.getAttribute("data-background-video-loop"),u=e.getAttribute("data-background-video-poster"),p=e.getAttribute("data-background-video-poster-yt-size");l<c&&(l=0);var b=!1,v=!1,f=!1;if(-1!==n.indexOf("youtube.com")||-1!==n.indexOf("youtu.be")){b=!0,v=!0;var m=bricksGetYouTubeVideoLinkData(n);t=m.id,n=m.url}-1!==n.indexOf("vimeo.com")&&-1===n.indexOf("/progressive_redirect/")&&(b=!0,f=!0,-1===n.indexOf("player.vimeo.com/video")&&(n=n.replace("vimeo.com","player.vimeo.com/video")));var g,y=function(){var e=document.createElement("img");e.classList.add("bricks-video-poster-image");var n=!1;return v&&(p?(e.src="https://img.youtube.com/vi/".concat(t,"/").concat(p,".jpg"),n=!0):u&&(e.src=u,n=!0)),f&&u&&(e.src=u,n=!0),!!n&&e},w=function(){var t=e.querySelector(".bricks-video-poster-image");t&&t.remove()};if(b){if(v){if(!document.querySelector('script[src="https://www.youtube.com/iframe_api"]')){var k,h=document.createElement("script");!bricksIsFrontend&&null!==(k=window.bricksData)&&void 0!==k&&k.builderCloudflareRocketLoader&&h.setAttribute("data-cfasync","false"),h.src="https://www.youtube.com/iframe_api";var x=document.getElementsByTagName("script")[0];x.parentNode.insertBefore(h,x)}g=document.createElement("div"),bricksIsFrontend&&e.querySelector("video")&&e.removeChild(e.querySelector("video")),e.appendChild(g);var S=y();S&&e.appendChild(S);var L=setInterval(function(){if(window.YT&&YT.Player){clearInterval(L);var e=new YT.Player(g,{width:"640",height:"360",videoId:t,playerVars:{autoplay:1,controls:0,start:c||void 0,mute:1,rel:0,showinfo:0,modestbranding:1,cc_load_policy:0,iv_load_policy:3,autohide:0,loop:0,playlist:t,enablejsapi:1},events:{onReady:function(t){if(l)var n=setInterval(function(){e.getCurrentTime()>=l&&(d?e.seekTo(c||0,!0):(e.pauseVideo(),clearInterval(n)))},1e3)},onStateChange:function(t){d&&t.data==YT.PlayerState.ENDED&&e.seekTo(c||0,!0),t.data==YT.PlayerState.PLAYING&&w()}}})}},100)}if(f){if(!document.querySelector('script[src="https://player.vimeo.com/api/player.js"]')){var E,I=document.createElement("script");!bricksIsFrontend&&null!==(E=window.bricksData)&&void 0!==E&&E.builderCloudflareRocketLoader&&I.setAttribute("data-cfasync","false"),I.src="https://player.vimeo.com/api/player.js";var A=document.getElementsByTagName("script")[0];A.parentNode.insertBefore(I,A)}bricksIsFrontend&&e.querySelector("video")&&e.removeChild(e.querySelector("video")),g=document.createElement("div");var T=y();T&&e.appendChild(T),e.appendChild(g);var q=n.split("/").pop(),F=setInterval(function(){if(window.Vimeo&&Vimeo.Player){clearInterval(F);var e=new Vimeo.Player(g,{id:q,width:640,autoplay:!0,controls:!1,background:!0,loop:d&&!c});T&&e.on("play",function(){w()}),c&&e.on("loaded",function(){e.setCurrentTime(c)}),l&&e.on("timeupdate",function(t){t.seconds>=l&&(d?(e.setCurrentTime(c||0),e.play()):e.pause())}),e.on("ended",function(){d&&e.setCurrentTime(c||0).then(function(t){e.play()})})}},100)}}else if(g=e.querySelector("video")){var C,P,D=null===(C=g.closest("[data-script-id]"))||void 0===C?void 0:C.getAttribute("data-script-id");d?g.hasAttribute("loop")||g.setAttribute("loop",""):g.removeAttribute("loop"),bricksIsFrontend||(g.currentTime=c||0),null!==(P=window.bricksData.videoInstances)&&void 0!==P&&P[D]||(window.bricksData.videoInstances[D]={}),window.bricksData.videoInstances[D].startTime=c,window.bricksData.videoInstances[D].endTime=l,window.bricksData.videoInstances[D].videoLoop=d;g.classList.contains("listening")||!c&&!l||(g.classList.add("listening"),g.addEventListener("loadedmetadata",function(){window.bricksData.videoInstances[D].startTime&&(this.currentTime=window.bricksData.videoInstances[D].startTime,this.play())}),g.addEventListener("timeupdate",function(){this.currentTime>=(window.bricksData.videoInstances[D].endTime||this.duration)-.25&&(window.bricksData.videoInstances[D].videoLoop?(this.currentTime=window.bricksData.videoInstances[D].startTime,g.paused&&this.play()):this.pause())}),g.addEventListener("ended",function(){window.bricksData.videoInstances[D].videoLoop&&window.bricksData.videoInstances[D].startTime&&(this.currentTime=window.bricksData.videoInstances[D].startTime,this.play())}))}i&&(g.style.transform="translate(-50%, -50%) scale(".concat(i,")")),bricksIsFrontend?e.classList.contains("bricks-lazy-video")&&new BricksIntersect({element:e,callback:function(e){e.classList.remove("bricks-lazy-video"),b?e.appendChild(g):g.src=n}}):b?e.appendChild(g):g.src=n,e.classList.add("loaded"),new ResizeObserver(function(t){var n,r=_createForOfIteratorHelper(t);try{for(r.s();!(n=r.n()).done;){var i=n.value,o=void 0;if(i.contentBoxSize)o=(Array.isArray(i.contentBoxSize)?i.contentBoxSize[0]:i.contentBoxSize).inlineSize;else o=i.contentRect.width;var c=e.clientHeight,l=o*s/a;l<c&&(l=c,o=c*a/s),g.style.width="".concat(o,"px"),g.style.height="".concat(l,"px")}}catch(e){r.e(e)}finally{r.f()}}).observe(e)}}}}});function bricksBackgroundVideoInit(){bricksBackgroundVideoInitFn.run()}var bricksPhotoswipeFn=new BricksFunction({parentNode:document,selector:".bricks-lightbox",windowVariableCheck:["PhotoSwipeLightbox"],eachElement:function(e){var t=e,n="A"===e.tagName?"":"a",r=e.getAttribute("data-pswp-id")||e.getAttribute("data-lightbox-id"),i=e.getAttribute("data-animation-type")||"zoom";r&&(n=bricksQuerySelectorAll(document,'[data-pswp-id="'.concat(r,'"]')));var o={mainClass:"brx",gallery:t,counter:!t.classList.contains("brxe-carousel"),children:n,pswpModule:PhotoSwipe5,closeSVG:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></svg>',showHideAnimationType:i},a=null,s=null,c=null;r?n.forEach(function(e){if(e.classList.contains("has-lightbox-thumbnails"))a=e;else{var t=e.closest(".has-lightbox-thumbnails");t&&(a=t)}if(e.getAttribute("data-lightbox-padding"))s=e;else{var n=e.closest("[data-lightbox-padding]");n&&(s=n)}if(e.classList.contains("has-lightbox-caption"))c=e;else{var r=e.closest(".has-lightbox-caption");r&&(c=r)}}):e.classList.contains("has-lightbox-thumbnails")&&(a=e);var l=(a||s||e).getAttribute("data-lightbox-padding");l&&(o.padding=JSON.parse(l));var d=e.getAttribute("data-lightbox-image-click");d&&(o.imageClickAction=d);var u=new PhotoSwipeLightbox(o);if("none"===i&&u.addFilter("useContentPlaceholder",function(e,t){return!1}),"undefined"!=typeof PhotoSwipeDynamicCaption&&(c||e).classList.contains("has-lightbox-caption"))new PhotoSwipeDynamicCaption(u,{type:"below",captionContent:function(e){return e.data.element.getAttribute("data-lightbox-caption")}});if(a&&(u.on("uiRegister",function(){u.pswp.ui.registerElement({name:"thumbnail-navigation",className:"pswp__thumbnail-nav-wrapper",appendTo:"wrapper",onInit:function(n,i){var s=document.createElement("div");s.className="pswp__thumbnail-nav";var c=[];c=r?bricksQuerySelectorAll(document,'[data-pswp-id="'.concat(r,'"][data-pswp-src]')):e.querySelectorAll("a[data-pswp-src]");var l=[];c.forEach(function(e){if(!e.parentNode.classList.contains("swiper-slide-duplicate")){var t=e.getAttribute("href");t&&!l.includes(t)&&l.push(t)}}),l.forEach(function(e,t){var n=document.createElement("img");n.src=e,n.dataset.index=t;var r=a.getAttribute("data-lightbox-thumbnail-size");r&&(n.style.width=isNaN(r)?r:r+"px"),s.appendChild(n)}),n.appendChild(s),s.addEventListener("click",function(e){var n=parseInt(e.target.getAttribute("data-index"));if(Number.isInteger(n)){if(s.setAttribute("data-active-index",n),null!=o&&o.loop&&(n+=2),t.classList.contains("brxe-carousel")){var r=t.getAttribute("data-script-id"),a=bricksData.swiperInstances[r].slides.map(function(e,t){return{slide:e,index:t,pswpIndex:Number(e.dataset.swiperSlideIndex)}}).filter(function(e){return!e.slide.classList.contains("swiper-slide-duplicate")&&e.pswpIndex===n});a.length&&(n=a[0].index)}i.goTo(n)}})}})}),u.on("change",function(){var e=document.querySelector(".pswp__thumbnail-nav");if(e){var t=e.querySelector(".active");t&&t.classList.remove("active");var n=u.pswp.currSlide.data.element.dataset.pswpIndex||u.pswp.currIndex;if(t=e.querySelector('img[data-index="'.concat(n,'"'))){t.classList.add("active");var r=t.getBoundingClientRect(),i=e.offsetWidth/2-t.offsetLeft-r.width/2;i+=(window.innerWidth-e.offsetWidth)/2,e.style.transform="translateX("+i+"px)"}}})),u.on("itemData",function(t){var n=document.querySelector(".brx .pswp__container"),r=e.getAttribute("data-pswp-video-url"),i=e.getAttribute("data-pswp-width"),o=e.getAttribute("data-pswp-height"),a=1==e.getAttribute("data-no-controls")?0:1,s=1==e.getAttribute("data-muted");if(i&&(i.includes("%")||i.includes("vw"))&&(i=window.innerWidth*(parseInt(i)/100)),o&&(o.includes("%")||o.includes("vh"))&&(o=window.innerHeight*(parseInt(o)/100)),i||(i=1280),o&&720!=o||(o=Math.round(i/16*9)),!n&&r){var c=bricksGetLightboxVideoNode(r,a,s);t.itemData={html:c.outerHTML,width:i,height:o}}}),u.on("contentAppend",function(e){var t=e.content;if(t.element){var n=t.element.querySelector("video");n&&n.play()}}),t.classList.contains("brxe-carousel")){var p,b=t.getAttribute("data-script-id");null!==(p=bricksData.swiperInstances)&&void 0!==p&&null!==(p=p[b])&&void 0!==p&&p.loopedSlides&&(u.addFilter("numItems",function(e,t){if(t.gallery){var n=0;t.gallery.classList.contains("brxe-carousel")&&(n=t.gallery.querySelectorAll(".swiper-slide-duplicate").length),e=e>n?e-n:e}return e}),u.addFilter("clickedIndex",function(e,t){var n=t.target.closest(".swiper-slide");if(n){var r=bricksData.swiperInstances[b].slides.map(function(e,t){return{slide:e,index:t}}).filter(Boolean);if(r.length){var i=parseInt(n.dataset.swiperSlideIndex),o=r.filter(function(e){return e.slide.dataset.swiperSlideIndex==i});o.length&&(e=o[0].index)}}return e}))}u.init()}});function bricksPhotoswipe(){bricksPhotoswipeFn.run()}function bricksGetLightboxVideoNode(e,t,n){if(e){hasContent=!0;var r=!1;if(-1!==e.indexOf("youtube.com")||-1!==e.indexOf("youtu.be")){r=!0;var i=bricksGetYouTubeVideoLinkData(e);if(e=i.url,i.id){var o=-1!==e.indexOf("?")?"&":"?";e+=o+"autoplay=1",e+="&rel=0",t||(e+="&controls=0"),n&&(e+="&mute=1")}}if(-1!==e.indexOf("vimeo.com")&&(r=!0,-1===e.indexOf("/progressive_redirect/")&&(-1===e.indexOf("player.vimeo.com/video")&&(e=e.replace("vimeo.com","player.vimeo.com/video")),e+="?autoplay=1",t||(e+="&controls=0"))),r){var a=document.createElement("iframe");return a.setAttribute("src",e),a.setAttribute("allow","autoplay"),a.setAttribute("allowfullscreen",1),a}var s=document.createElement("video");return s.setAttribute("src",e),t&&s.setAttribute("controls",1),s.setAttribute("playsinline",1),s}}var bricksAccordionFn=new BricksFunction({parentNode:document,selector:".brxe-accordion, .brxe-accordion-nested",forceReinit:!0,eachElement:function(e){var t,n,r=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200;t.style.display="block",t.style.transitionProperty="height, margin, padding",t.style.transitionDuration="".concat(n,"ms"),t.style.height="".concat(t.offsetHeight,"px"),t.offsetHeight,t.style.overflow="hidden",t.style.height=0,t.style.paddingTop=0,t.style.paddingBottom=0,t.style.marginTop=0,t.style.marginBottom=0;var r=t.parentNode;r.classList.remove("brx-open"),window.setTimeout(function(){t.style.display="none",t.style.removeProperty("height"),t.style.removeProperty("padding-top"),t.style.removeProperty("padding-bottom"),t.style.removeProperty("margin-top"),t.style.removeProperty("margin-bottom"),t.style.removeProperty("overflow"),t.style.removeProperty("transition-duration"),t.style.removeProperty("transition-property"),document.dispatchEvent(new CustomEvent("bricks/accordion/close",{detail:{elementId:e.getAttribute("data-script-id"),closeItem:r}}))},n)},i=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200;return"none"===window.getComputedStyle(t).display?function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200;t.style.removeProperty("display");var r=window.getComputedStyle(t).display;"none"===r&&(r="block"),t.style.display=r;var i=t.offsetHeight;t.style.overflow="hidden",t.style.height=0,t.style.paddingTop=0,t.style.paddingBottom=0,t.style.marginTop=0,t.style.marginBottom=0,t.offsetHeight,t.style.transitionProperty="height, margin, padding",t.style.transitionDuration="".concat(n,"ms"),t.style.height="".concat(i,"px"),t.style.removeProperty("padding-top"),t.style.removeProperty("padding-bottom"),t.style.removeProperty("margin-top"),t.style.removeProperty("margin-bottom");var o=t.parentNode;o.classList.add("brx-open"),window.setTimeout(function(){t.style.removeProperty("height"),t.style.removeProperty("overflow"),t.style.removeProperty("transition-duration"),t.style.removeProperty("transition-property"),document.dispatchEvent(new CustomEvent("bricks/accordion/open",{detail:{elementId:e.getAttribute("data-script-id"),openItem:o}}))},n)}(t,n):r(t,n)},o=function(e){var t;e.classList.add("brx-open");var n=null!==(t=e.querySelector(".accordion-title-wrapper"))&&void 0!==t&&t;n&&n.setAttribute("aria-expanded","true")},a=Array.from(e.children),s=e.hasAttribute("data-transition")?isNaN(e.dataset.transition)?0:e.dataset.transition:200,c=null===(t=e.dataset.scriptArgs)||void 0===t?void 0:t.includes("expandFirstItem"),l=null===(n=e.dataset.scriptArgs)||void 0===n?void 0:n.includes("independentToggle"),d=!!c&&["0"];!1===d&&e.hasAttribute("data-expand-item")&&(d=e.getAttribute("data-expand-item").split(","));var u=window.location.hash||"";(a=a.filter(function(e){return e.classList.contains("brxe-section")||e.classList.contains("brxe-container")||e.classList.contains("brxe-block")||e.classList.contains("brxe-div")||e.classList.contains("accordion-item")})).forEach(function(t,n){d&&d.includes(n.toString())&&o(t);var a=null!=t&&t.id&&!t.id.startsWith("brxe-")?"#".concat(t.id):"";if(a&&a===u&&o(t),!t.classList.contains("listening")){t.classList.add("listening"),t.addEventListener("click",function(t){var n=t.target.closest(".accordion-title-wrapper");if(n){var o=n.parentNode;if(o){var c=o.querySelector(".accordion-content-wrapper");if(c)if(!t.target.closest(".bricks-active-selector-detector")){if(t.stopPropagation(),!l){var d=e.querySelectorAll(":scope > .brx-open");d.length&&d.forEach(function(e){var t=e.querySelector(".accordion-content-wrapper");t&&t!==c&&(r(t,s),t.previousElementSibling.setAttribute("aria-label",window.bricksData.i18n.openAccordion),t.previousElementSibling.setAttribute("aria-expanded","false"))})}var u=!o.classList.contains("brx-open");a&&u?history.replaceState(null,null,a):history.replaceState(null,null," "),i(c,s),o.classList.contains("brx-open")?n.setAttribute("aria-expanded","true"):n.setAttribute("aria-expanded","false")}}}});var c=t.querySelector(".accordion-title-wrapper")||t;"button"===c.getAttribute("role")&&c.addEventListener("keydown",function(e){"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),c.click())})}})}});function bricksAccordion(){bricksAccordionFn.run()}var bricksAnimatedTypingFn=new BricksFunction({parentNode:document,selector:".brxe-animated-typing",windowVariableCheck:["Typed"],eachElement:function(e){var t,n=e.dataset.scriptId;try{t=JSON.parse(e.dataset.scriptArgs)}catch(e){return!1}var r=e.querySelector(".typed");if(r&&(window.bricksData.animatedTypingInstances[n]&&!e.closest(".brxe-slider-nested.splide")&&window.bricksData.animatedTypingInstances[n].destroy(),t.hasOwnProperty("strings")&&t.strings&&(!Array.isArray(t.strings)||t.strings.toString()))){Array.isArray(t.strings)&&(t.strings=t.strings.map(function(e){return e.replace(/&/g,"&")})),window.bricksData.animatedTypingInstances[n]=new Typed(r,t);var i=e.closest(".brx-popup:not([data-popup-ajax])");i&&document.addEventListener("bricks/popup/open",function(e){e.detail.popupElement===i&&window.bricksData.animatedTypingInstances[n].reset()})}}});function bricksAnimatedTyping(){bricksAnimatedTypingFn.run()}var bricksAudioFn=new BricksFunction({parentNode:document,selector:".brxe-audio",windowVariableCheck:["MediaElementPlayer"],eachElement:function(e){var t=e.querySelector("audio");if(t)new MediaElementPlayer(t)}});function bricksAudio(){bricksAudioFn.run()}var bricksPostReadingTimeFn=new BricksFunction({parentNode:document,selector:".brxe-post-reading-time",eachElement:function(e){var t=e.getAttribute("data-wpm"),n=e.getAttribute("data-cpm");if(t||n){var r=e.dataset.contentSelector||".brxe-post-content",i=e.closest("[data-query-loop-index]"),o=i?i.querySelector(r):document.querySelector(r);if(o||(o=document.querySelector("#brx-content")),o){var a,s=e.getAttribute("data-prefix")||"",c=e.getAttribute("data-suffix")||"",l=o.textContent,d=1.5,u=2.5;if(n){var p=l.replace(/\s+/g,"").length;a=Math.ceil(p/parseInt(n))}else{var b=function(e){var t,n=0,r=0,i="",o=_createForOfIteratorHelper(e);try{for(o.s();!(t=o.n()).done;){var a=t.value,s=v(a);"chinese"===s?n++:"japanese"===s?r++:i+=a}}catch(e){o.e(e)}finally{o.f()}var c=n/d,l=r/u;return i=function(e,t){var n=new RegExp("\\S{".concat(15,",}"),"g");return e.replace(n,function(e){return e.match(new RegExp(".{1,".concat(t,"}"),"g")).join(" ")})}(i,5),c+l+i.split(/\s+/).filter(function(e){return e.length>0}).length}(l);a=Math.ceil(b/parseInt(t))}e.textContent=s+a+c}}function v(e){return/[\u4e00-\u9fa5]/.test(e)?"chinese":/[\u3040-\u30FF]/.test(e)?"japanese":"other"}}});function bricksPostReadingTime(){bricksPostReadingTimeFn.run()}var bricksCountdownFn=new BricksFunction({parentNode:document,selector:".brxe-countdown",eachElement:function(e){countdown=function(e,t,n){var r=6e4*(("+"===t.timezone[3]?1:-1)*(60*parseInt(t.timezone.substring(4,6))+parseInt(t.timezone.substring(7,9)))),i=6e4*-(new Date).getTimezoneOffset(),o=t.date.replace(" ","T"),a=new Date(o).getTime()+i-r-(new Date).getTime();if(a<=0){if(clearInterval(e.dataset.bricksCountdownId),"hide"===t.action)return void(e.innerHTML="");if("text"===t.action)return void(e.innerHTML=t.actionText)}n&&(e.innerHTML="",t.fields.forEach(function(t){if(t.format){var n=document.createElement("div");if(n.classList.add("field"),t.prefix){var r=document.createElement("span");r.classList.add("prefix"),r.innerHTML=t.prefix,n.appendChild(r)}var i=document.createElement("span");if(i.classList.add("format"),n.appendChild(i),t.suffix){var o=document.createElement("span");o.classList.add("suffix"),o.innerHTML=t.suffix,n.appendChild(o)}e.appendChild(n)}}));var s=bricksQuerySelectorAll(e,".field"),c=Math.floor(a/864e5),l=Math.floor(a%864e5/36e5),d=Math.floor(a%36e5/6e4),u=Math.floor(a%6e4/1e3);t.fields.forEach(function(e,t){if(e.format&&s[t]){var n=e.format.toLowerCase();n.includes("%d")?(e.format.includes("%D")&&c<=9&&(c="0".concat(c)),s[t].querySelector(".format").innerHTML=n.replace("%d",a<=0?0:c)):n.includes("%h")?(e.format.includes("%H")&&l<=9&&(l="0".concat(l)),s[t].querySelector(".format").innerHTML=n.replace("%h",a<=0?0:l)):n.includes("%m")?(e.format.includes("%M")&&d<=9&&(d="0".concat(d)),s[t].querySelector(".format").innerHTML=n.replace("%m",a<=0?0:d)):n.includes("%s")&&(e.format.includes("%S")&&u<=9&&(u="0".concat(u)),s[t].querySelector(".format").innerHTML=n.replace("%s",a<=0?0:u))}})};var t=e.dataset.bricksCountdownOptions;try{t=JSON.parse(t)}catch(e){return!1}if(t.hasOwnProperty("date")&&t.hasOwnProperty("fields")){var n=e.dataset.bricksCountdownId;n&&clearInterval(n),countdown(e,t,!0),n=setInterval(countdown,1e3,e,t,!1),e.dataset.bricksCountdownId=n}}});function bricksCountdown(){bricksCountdownFn.run()}var bricksCounterFn=new BricksFunction({parentNode:document,selector:".brxe-counter",subscribeEvents:["bricks/popup/open","bricks/ajax/pagination/completed","bricks/ajax/load_page/completed","bricks/ajax/query_result/displayed"],forceReinit:function(e,t){return e.closest(".brx-popup")},eachElement:function(e){var t,n=e.dataset.bricksCounterOptions;try{n=JSON.parse(n)}catch(e){return!1}var r=e.querySelector(".count"),i=n.hasOwnProperty("countFrom")?parseInt(n.countFrom):0,o=n.hasOwnProperty("countTo")?parseInt(n.countTo):100,a=n.hasOwnProperty("duration")?parseInt(n.duration):1e3,s=null===(t=n)||void 0===t?void 0:t.separator;a<500&&(a=500);var c=a/(o-i),l=1;c<16&&(l=Math.ceil(16/c),c=16);var d=function(){var e=r.innerText.replace(/\D/g,""),t=(e=isNaN(e)?i:parseInt(e))+l<o?e+l:o;if(e>=o)return clearInterval(r.dataset.counterId),void delete r.dataset.counterId;n.thousands&&s?r.innerText=t.toLocaleString("en-US").replaceAll(",",s):n.thousands?r.innerText=t.toLocaleString():r.innerText=t},u=function(){r.innerText=i,null==r.dataset.counterId&&(r.dataset.counterId=setInterval(d,c))},p=r.closest(".brx-popup");p?p.classList.contains("hide")||u():new BricksIntersect({element:e,callback:u})},listenerHandler:function(e){var t;if(null!=e&&e.type)if("bricks/popup/open"===e.type){var n={parentNode:null!==(t=e.details)&&void 0!==t&&t.popupElement?e.details.popupElement:document};bricksCounterFn.run(n)}else bricksCounterFn.run()}});function bricksCounter(){bricksCounterFn.run()}var bricksTableOfContentsFn=new BricksFunction({parentNode:document,selector:".brxe-post-toc",forceReinit:!0,eachElement:function(e){if(null!==e.offsetParent&&!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length))n(e);else{var t=new IntersectionObserver(function(r){r.forEach(function(r){r.isIntersecting&&(n(e),t.disconnect())})},{threshold:.1});t.observe(e)}function n(e){window.tocbot&&window.tocbot.destroy();var t=e.dataset.scriptId,n=e.dataset.contentSelector||".brxe-post-content",r=document.querySelector(n);if(r||(r=document.querySelector("#brx-content"))&&(n="#brx-content"),r){var i=e.dataset.headingSelectors||"h2, h3",o=r.querySelectorAll(i),a={};o.forEach(function(e){if(!e.id||a[e.id]){var n=function(e,t){var n=e.trim().toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/[!@#$%^&*()=:;,.„“"'`]/gi,"").replace(/\//gi,"-").split(" ").join("-");if(/^\d/.test(n))return"".concat(t,"-").concat(n);return n}(e.textContent,t);a[n]?(a[n]++,n="".concat(n,"-").concat(a[n])):a[n]=1,e.id=n}else a[e.id]=1});var s=parseInt(e.dataset.headingsOffset)||0,c=e.hasAttribute("data-smooth-scroll"),l={tocSelector:'.brxe-post-toc[data-script-id="'.concat(t,'"]'),contentSelector:n,headingSelector:i,ignoreSelector:e.dataset.ignoreSelector||".toc-ignore",hasInnerContainers:!1,linkClass:"toc-link",extraLinkClasses:"",activeLinkClass:"is-active-link",listClass:"toc-list",extraListClasses:"",isCollapsedClass:"is-collapsed",collapsibleClass:"is-collapsible",listItemClass:"toc-list-item",activeListItemClass:"is-active-li",collapseDepth:e.dataset.collapseInactive?0:6,scrollSmooth:s,scrollSmoothDuration:c&&s?420:0,scrollSmoothOffset:s?-s:0,headingsOffset:s,throttleTimeout:0,positionFixedSelector:null,positionFixedClass:"is-position-fixed",fixedSidebarOffset:"auto",includeHtml:!1,includeTitleTags:!1,orderedList:!1,scrollContainer:null,skipRendering:!1,headingLabelCallback:!1,ignoreHiddenElements:!1,headingObjectCallback:null,basePath:"",disableTocScrollSync:!1,tocScrollOffset:0};window.tocbot.init(l)}}}});function bricksTableOfContents(){bricksTableOfContentsFn.run()}var bricksFormFn=new BricksFunction({parentNode:document,selector:".brxe-form",eachElement:function(e){var t=e.getAttribute("data-element-id"),n=JSON.parse(e.getAttribute("data-validation-disabled-on"))||[];function r(e,t){e.addEventListener("dragstart",function(t){e.classList.add("dragging"),e.style.opacity="0.5",t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/html",e.innerHTML)}),e.addEventListener("dragend",function(n){e.style.opacity="1",e.classList.remove("dragging"),function(e){var t=e.parentNode.querySelector('input[type="hidden"]');if(!t)return;var n=e.querySelectorAll(".image-preview"),r=[];n.forEach(function(e){var t=e.querySelector("img");t&&t.dataset.attachmentId&&r.push(t.dataset.attachmentId)}),t.value=r.join(",")}(t)}),e.addEventListener("dragover",function(n){n.preventDefault(),n.dataTransfer.dropEffect="move";var r=t.querySelector(".dragging");if(r&&r!==e){var i=Array.from(t.querySelectorAll(".image-preview"));i.indexOf(r)<i.indexOf(e)?t.insertBefore(r,e.nextSibling):t.insertBefore(r,e)}}),e.addEventListener("drop",function(e){e.preventDefault(),e.stopPropagation()})}function i(e,t){e.addEventListener("click",function(n){n.preventDefault();var r,i=e.dataset.attachmentId,o=e.closest(".image-preview"),a=t.classList.contains("gallery-preview");if(r=a?t.parentNode.querySelector('input[type="hidden"]'):o.parentNode.querySelector('input[type="hidden"]'),a&&r){var s=r.value,c=s?s.split(",").map(function(e){return e.trim()}):[];c=c.filter(function(e){return e!==i}),r.value=c.join(",")}else r&&(r.value="");o&&o.remove()})}function o(e,t,n){t.on("select",function(){var o=t.state().get("selection").map(function(e){return e.toJSON()});if(n){var a=e.parentNode.querySelector(".gallery-preview"),s=e.parentNode.querySelector('input[type="hidden"]');if(!a)return;a.querySelectorAll(".image-preview").forEach(function(e){return e.remove()});var c=[];o.forEach(function(e){var t,n=function(e,t){var n=document.createElement("div");n.classList.add("image-preview");var o=t.classList.contains("gallery-preview");o&&(n.setAttribute("draggable","true"),n.style.cursor="move");var a=document.createElement("img");a.src=e.url,a.alt=e.alt||"",a.title=e.title||"",a.style="max-height: 150px",a.dataset.attachmentId=e.id;var s=document.createElement("button");return s.type="button",s.classList.add("choose-files","remove"),s.dataset.action="media-library",s.dataset.attachmentId=e.id,s.textContent=window.bricksData.i18n.remove,i(s,t),n.appendChild(a),n.appendChild(s),o&&r(n,t),n}(_objectSpread(_objectSpread({},e),{},{url:(null===(t=e.sizes)||void 0===t||null===(t=t.thumbnail)||void 0===t?void 0:t.url)||e.url}),a);a.appendChild(n),c.push(String(e.id))}),s&&(s.value=c.join(","))}else{var l=e.parentNode.querySelector(".image-preview"),d=e.parentNode.querySelector('input[type="hidden"]');if(!o[0])return;var u=o[0];if(l){var p=l.querySelector("img");p&&p.remove();var b=document.createElement("img");b.src=u.url,b.alt=u.alt||"",b.title=u.title||"",b.style="max-height: 150px",l.insertBefore(b,l.firstChild)}d&&(d.value=u.id)}})}bricksQuerySelectorAll(e,'input[type="checkbox"]').forEach(function(t){t.required&&t.addEventListener("click",function(n){var r=t.getAttribute("name"),i=bricksQuerySelectorAll(e,'input[name="'.concat(r,'"]')),o=!1;i.forEach(function(e){!0===e.checked&&(o=!0)}),o?i.forEach(function(e){e.required=!1}):i.forEach(function(e){e.required=!0})})}),bricksQuerySelectorAll(e,".choose-files.image").forEach(function(e){e.addEventListener("click",function(t){t.preventDefault();var n=e.classList.contains("multiple"),r=window.wp.media({multiple:n,library:{type:"image"}});o(e,r,n);var i=e.parentNode.querySelector('input[type="hidden"]');if(i&&i.value){var a=i.value.split(",").map(function(e){return e.trim()});a.length>0&&r.on("open",function(){var e=r.state().get("selection");a.forEach(function(t){var n=wp.media.attachment(t);n.fetch(),e.add(n)})})}r.open()})}),bricksQuerySelectorAll(e,".choose-files.remove").forEach(function(e){var t=e.closest(".gallery-preview")||e.closest(".image-preview");if(t){if(!e.dataset.attachmentId){var n=e.parentNode.querySelector("img");n&&n.dataset.attachmentId&&(e.dataset.attachmentId=n.dataset.attachmentId)}i(e,t)}}),bricksQuerySelectorAll(e,".gallery-preview").forEach(function(e){e.querySelectorAll(".image-preview").forEach(function(t){t.setAttribute("draggable","true"),t.style.cursor="move",r(t,e)})});var a=e.querySelectorAll('input:not([type="hidden"]):not([type="file"]), textarea');function s(e){var t=e.value.trim(),n=e.getAttribute("data-error-message"),r=e.closest(".form-group"),i=!1;if(e.hasAttribute("required")&&!t&&(i=!0),"number"===e.type){var o=parseFloat(e.getAttribute("min")),a=parseFloat(e.getAttribute("max")),s=parseFloat(t);(null!==o&&s<o||null!==a&&s>a)&&(i=!0)}"email"===e.type&&(i=!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)),"url"===e.type&&(i=!/^(https?:\/\/)?([\w.-]+)\.([a-z.]{2,6})([\/\w.-]*)*\/?$/.test(t)),e.hasAttribute("required")||""!=t||(i=!1);var c=r.querySelector(".form-group-error-message");return c||((c=document.createElement("div")).classList.add("form-group-error-message"),r.appendChild(c)),i?(c.innerText=n,c.classList.add("show")):(c.innerText="",c.classList.remove("show")),!i}a.forEach(function(e){e.getAttribute("data-error-message")&&bricksIsFrontend&&(n.includes("input")||e.addEventListener("input",window.bricksUtils.debounce(function(){s(e)},300)),n.includes("blur")||e.addEventListener("blur",window.bricksUtils.debounce(function(){s(e)},300)))}),e.querySelectorAll(".password-toggle").forEach(function(e){var t=e.previousElementSibling;t&&t.type.match(/password|text/)&&e.addEventListener("click",function(){var n="password"===t.type;t.type=n?"text":"password",e.setAttribute("aria-label",n?window.bricksData.i18n.hidePassword:window.bricksData.i18n.showPassword),e.querySelector(".show-password").classList.toggle("hide"),e.querySelector(".hide-password").classList.toggle("hide")})}),bricksQuerySelectorAll(e,".flatpickr").forEach(function(e){var t=e.dataset.bricksDatepickerOptions;t&&((t=JSON.parse(t)).disableMobile=!0,t.onReady=function(e,t,n){if(n.altInput){var r=n.altInput.previousElementSibling?n.altInput.previousElementSibling.getAttribute("aria-label"):"Date";n.altInput.setAttribute("aria-label",r||"Date")}},flatpickr(e,t))});var c={};bricksQuerySelectorAll(e,"input[type=file]").forEach(function(t){var n=t.getAttribute("data-files-ref"),r=t.getAttribute("data-maxsize")||!1,i=t.getAttribute("data-limit")||!1;r=!!r&&1024*parseInt(r)*1024,t.addEventListener("change",function(o){var a=o.target.files,s=a.length,l=t.getAttribute("name");if(s)for(var d=e.querySelector('.file-result[data-files-ref="'.concat(n,'"]')),u=function(){var e=a[p],n=!1,o=d.cloneNode(!0);if(i&&c.hasOwnProperty(l)&&c[l].length>=i&&(n="limit"),r&&e.size>r&&(n="size"),o.classList.add("show"),n){o.classList.add("danger"),o.querySelector(".text").remove(),o.querySelector(".remove").remove();var s=o.querySelector("svg"),u=o.getAttribute("data-error-".concat(n)).replace("%s",e.name);o.insertAdjacentHTML("afterbegin",u),s.addEventListener("click",function(){o.remove()})}else{c.hasOwnProperty(l)||(c[l]=[]),c[l].push(e);var b=o.querySelector(".text"),v=o.querySelector(".remove");o.querySelector("svg").remove(),b.innerHTML=e.name,v.setAttribute("data-name",e.name),v.setAttribute("data-field",l),v.addEventListener("click",function(e){for(var n=e.target.getAttribute("data-name"),r=e.target.getAttribute("data-field"),i=c[r],a=0;a<i.length;a++)if(i[a].name===n){c[l].splice(a,1);break}o.remove();for(var s=new DataTransfer,d=0;d<t.files.length;d++){var u=t.files[d];u.name!==n&&s.items.add(u)}t.files=s.files})}d.parentNode.insertBefore(o,d.nextSibling)},p=0;p<s;p++)u()})}),e.addEventListener("submit",function(n){var r;if(n.preventDefault(),bricksIsFrontend){var i=!0;if(a.forEach(function(e){e.getAttribute("data-error-message")&&bricksIsFrontend&&(i=i&&s(e))}),i){var o=e.querySelector("[data-hcaptcha-widget-id]"),l=o?o.getAttribute("data-hcaptcha-widget-id"):"";if("function"==typeof(null===(r=window)||void 0===r||null===(r=r.hcaptcha)||void 0===r?void 0:r.execute)&&document.querySelector('.h-captcha[data-size="invisible"]'))hcaptcha.execute(l,{async:!0}).then(function(){bricksSubmitForm(t,e,c,null)}).catch(function(e){console.warn(e)});else{var d=e.querySelector(".cf-turnstile");if(d&&void 0!==window.turnstile){var u=d.querySelector("iframe"),p=u?u.id:null,b=p?turnstile.getResponse(p):null;if(!b){var v=d.querySelector('input[name="cf-turnstile-response"]');b=v?v.value:null}if(!b)return void(window.bricksPendingTurnstileSubmission={elementId:t,form:e,files:c})}var f=document.getElementById("recaptcha-".concat(t)),m=e.querySelector(".recaptcha-error");if(f){var g=f.getAttribute("data-key");if(g)try{grecaptcha.ready(function(){try{grecaptcha.execute(g,{action:"bricks_form_submit"}).then(function(n){m.classList.remove("show"),bricksSubmitForm(t,e,c,n)}).catch(function(t){m.classList.add("show"),e.querySelector(".alert").innerText="Google reCaptcha ".concat(t)})}catch(t){m.classList.add("show"),e.querySelector(".alert").innerText="Google reCaptcha ".concat(t)}})}catch(t){m.classList.add("show"),e.querySelector(".alert").innerText="Google reCaptcha ".concat(t)}else m.classList.add("show")}else bricksSubmitForm(t,e,c,null)}}}})}});function bricksForm(){bricksFormFn.run()}function bricksSubmitForm(e,t,n,r,i){var o,a;if(t.action&&t.action.includes("action=postpass"))t.submit();else if("true"!==(null===(o=t.dataset)||void 0===o?void 0:o.submitting)){var s=t.querySelector("button[type=submit]");s.classList.add("sending"),s.disabled=!0,t.dataset.submitting="true";var c=t.dataset.loopObjectId?t.dataset.loopObjectId:window.bricksData.postId,l=new FormData(t);l.append("action","bricks_form_submit"),l.append("loopId",c),l.append("postId",window.bricksData.postId),l.append("formId",e),l.append("recaptchaToken",r||""),l.append("nonce",window.bricksData.formNonce),l.append("referrer",location.toString());var d=null!==(a=t.getAttribute("data-component-id"))&&void 0!==a&&a;d&&l.append("componentId",d);var u=JSON.parse(t.getAttribute("data-notice")),p={};window.location.search.substring(1).split("&").forEach(function(e){var t=e.split("=");p[t[0]]=decodeURIComponent(t[1])}),l.append("urlParams",JSON.stringify(p));var b=t.getAttribute("data-global-id");b&&l.append("globalId",b);var v=function(e){n[e].forEach(function(t){l.append("".concat(e,"[]"),t,t.name)})};for(var f in n)v(f);document.dispatchEvent(new CustomEvent("bricks/form/submit",{detail:{elementId:e,formData:l}}));var m=window.bricksData.ajaxUrl,g=new XMLHttpRequest;g.open("POST",m,!0),g.onreadystatechange=function(){var o,a,c,d,p,b,v,f=function(e){try{return JSON.parse(e)}catch(e){return null}}(g.response);if(window.bricksData.debug&&console.warn("bricks_form_submit",g,f),f||(s.classList.remove("sending"),s.disabled=!1,t.dataset.submitting="false"),f&&4==(null==g?void 0:g.readyState)){var m,y,w;if("invalid_nonce"===(null==f||null===(o=f.data)||void 0===o?void 0:o.code)){if(!i)return t.dataset.submitting="false",void bricksRegenerateNonceAndResubmit(e,t,n,r)}else f.success&&"success"===(null===(y=f.data)||void 0===y?void 0:y.type)?m="bricks/form/success":f.success&&"error"!==(null===(w=f.data)||void 0===w?void 0:w.type)||(m="bricks/form/error");m&&document.dispatchEvent(new CustomEvent(m,{detail:{elementId:e,formData:l,res:f}})),!f.success||"mailchimp"!==(null===(a=f.data)||void 0===a?void 0:a.action)&&"sendgrid"!==(null===(c=f.data)||void 0===c?void 0:c.action)||(window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"bricksNewsletterSignup"}));var k,h=!0;if(f.success&&null!==(d=f.data)&&void 0!==d&&d.redirectTo)h=!1,setTimeout(function(){window.location.href=f.data.redirectTo},parseInt(null===(k=f.data)||void 0===k?void 0:k.redirectTimeout)||0);else f.success&&null!==(p=f.data)&&void 0!==p&&p.refreshPage&&(h=!1,setTimeout(function(){window.location.reload()},1e3));t.querySelector(".message")&&t.querySelector(".message").remove();var x=document.createElement("div");x.classList.add("message");var S,L=document.createElement("div");if(L.classList.add("text"),null!==(b=f.data)&&void 0!==b&&b.message)if(null!==(S=f.data.message)&&void 0!==S&&S.errors){var E=f.data.message.errors;Object.keys(E).forEach(function(e){L.innerHTML+=E[e][0]+"<br>"})}else L.innerHTML=f.data.message;if(x.appendChild(L),null!==(v=f.data)&&void 0!==v&&v.info){var I=document.createElement("div"),A=document.createElement("div");A.innerHTML=f.data.info.join("<br>"),x.appendChild(I),I.appendChild(A)}else x.classList.add(f.data.type);if(u){var T=function(){x.classList.add("closing"),setTimeout(function(){null==x||x.remove()},200)};if(u.closeButton){var q=document.createElement("button");q.classList.add("close"),q.innerHTML='<svg version="1.1" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g stroke-linecap="round" stroke-width="2" stroke="currentcolor" fill="none" stroke-linejoin="round"><path d="M0.5,0.5l23,23"></path><path d="M23.5,0.5l-23,23"></path></g><path fill="none" d="M0,0h24v24h-24Z"></path></svg>',x.appendChild(q),q.addEventListener("click",function(e){e.preventDefault(),T()})}var F=null==u?void 0:u.closeAfter;F&&setTimeout(function(){T()},parseInt(F))}if(t.appendChild(x),s.classList.remove("sending"),h&&(s.disabled=!1,t.dataset.submitting="false"),f.success){var C;if(0!=(null==f||null===(C=f.data)||void 0===C?void 0:C.reset)){for(var P in t.reset(),n)delete n[P];var D=bricksQuerySelectorAll(t,".file-result.show");null!==D&&D.forEach(function(e){e.remove()}),bricksQuerySelectorAll(t,".image-preview .remove").forEach(function(e){e.click()})}if(window.top!=window.self&&!t.querySelector('input[name="brx_pp_temp_id"]')){var _=window.top.document.querySelector("button.wp-auth-check-close");_&&_.click()}}else{var O=t.querySelector(".cf-turnstile"),N=O?O.querySelector("iframe"):null,M=N?N.id:null;M&&turnstile.reset(M);var j=bricksQuerySelectorAll(t,".file-result.show.danger");null!==j&&j.forEach(function(e){e.remove()})}}},g.send(l)}}function bricksRegenerateNonceAndResubmit(e,t,n,r){var i=new XMLHttpRequest;i.open("POST",window.bricksData.ajaxUrl+"?t="+(new Date).getTime(),!0),i.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),i.onreadystatechange=function(){if(i.readyState===XMLHttpRequest.DONE){var o=i.responseText;window.bricksData.formNonce=o,bricksSubmitForm(e,t,n,r,!0)}},i.send("action=bricks_regenerate_form_nonce")}window.bricksTurnstileCallback=function(e){if(window.bricksPendingTurnstileSubmission){var t=window.bricksPendingTurnstileSubmission;window.bricksPendingTurnstileSubmission=null,bricksSubmitForm(t.elementId,t.form,t.files,null)}},window.bricksTurnstileErrorCallback=function(e){if(window.bricksPendingTurnstileSubmission){var t=window.bricksPendingTurnstileSubmission;window.bricksPendingTurnstileSubmission=null,bricksSubmitForm(t.elementId,t.form,t.files,null)}};var bricksTinyMCEFn=new BricksFunction({parentNode:document,selector:".brxe-form .form-field-richtext",windowVariableCheck:["tinymce"],eachElement:function(e){var t=e.getAttribute("data-tinymce-settings");t=t?JSON.parse(t):{},(window.tinymce8||window.tinymce).init(_objectSpread(_objectSpread({},t),{},{selector:"#".concat(e.id),suffix:".min",license_key:"gpl",setup:function(e){e.ui.registry.addButton("bricks_add_media",{text:"Add Media",icon:"image",onAction:function(){var t=window.wp.media({title:"Insert Media",button:{text:"Insert"},multiple:!1});t.on("select",function(){var n=t.state().get("selection").first().toJSON();e.insertContent('<img src="'.concat(n.url,'" alt="').concat(n.alt,'" title="').concat(n.title,'" />'))}),t.open()}}),e.on("change",function(){e.save()})}}))}});function bricksTinyMCE(){bricksTinyMCEFn.run()}var bricksIsotopeFn=new BricksFunction({parentNode:document,selector:".bricks-layout-wrapper.isotope",forceReinit:!0,windowVariableCheck:["Isotope"],eachElement:function(e){var t=!1,n="";if(e.classList.contains("bricks-masonry"))t=e.getAttribute("data-script-id"),n="masonry-element";else if(e.classList.contains("brxe-image-gallery"))t=e.getAttribute("data-script-id"),n="image-gallery";else{var r;t=null===(r=e.closest(".brxe-posts"))||void 0===r?void 0:r.getAttribute("data-script-id"),n="posts"}if(t&&n){if(bricksIsFrontend&&window.bricksData.isotopeInstances[t]){var i;if(null!==(i=window.bricksData.isotopeInstances[t].element)&&void 0!==i&&i.isConnected)return void bricksUtils.updateIsotopeInstance(t);window.bricksData.isotopeInstances[t].instance.destroy(),delete window.bricksData.isotopeInstances[t]}else window.bricksData.isotopeInstances[t]&&(window.bricksData.isotopeInstances[t].instance.destroy(),delete window.bricksData.isotopeInstances[t]);var o={},a=e.getAttribute("data-layout");if("masonry-element"===n){var s,c,l;a="masonry";var d=e.getAttribute("data-brx-masonry-json")||"{}",u={};try{u=JSON.parse(d)}catch(e){console.error("Bricks: Invalid JSON data for Masonry element")}var p=(null===(s=u)||void 0===s?void 0:s.transitionDuration)||"0.4s",b=(null===(c=u)||void 0===c?void 0:c.transitionMode)||"scale";if(o={itemSelector:".bricks-masonry > *:not(.bricks-isotope-sizer):not(.bricks-gutter-sizer)",percentPosition:!0,masonry:{columnWidth:".bricks-isotope-sizer",gutter:".bricks-gutter-sizer",horizontalOrder:(null===(l=u)||void 0===l?void 0:l.horizontalOrder)||!1},transitionDuration:p},"0s"===p||"0"===p)o.hiddenStyle={opacity:1},o.visibleStyle={opacity:1},o.instantLayout=!0;else switch(b){case"fade":o.hiddenStyle={opacity:0},o.visibleStyle={opacity:1};break;case"slideLeft":o.hiddenStyle={opacity:0,transform:"translateX(-50%)"},o.visibleStyle={opacity:1,transform:"translateX(0)"};break;case"slideRight":o.hiddenStyle={opacity:0,transform:"translateX(50%)"},o.visibleStyle={opacity:1,transform:"translateX(0)"};break;case"skew":o.hiddenStyle={opacity:0,transform:"skew(20deg)"},o.visibleStyle={opacity:1,transform:"skew(0)"}}}else o={itemSelector:".bricks-layout-item",percentPosition:!0},"grid"===a?(o.layoutMode="fitRows",o.fitRows={gutter:".bricks-gutter-sizer"}):"masonry"!==a&&"metro"!==a||(o.masonry={columnWidth:".bricks-isotope-sizer",gutter:".bricks-gutter-sizer"});var v=new Isotope(e,o);setTimeout(function(){e.classList.remove("isotope-before-init")},250);var f=e.parentNode.querySelector(".bricks-isotope-filters");f&&f.addEventListener("click",function(e){var t=e.target.getAttribute("data-filter"),n=f.querySelector("li.active");t&&bricksIsFrontend&&(n&&n.classList.remove("active"),e.target.classList.add("active"),v.arrange({filter:t}))}),window.bricksData.isotopeInstances[t]={elementId:t,instance:v,layout:a,filters:f,options:o,element:e,elementName:n},bricksUtils.updateIsotopeOnImageLoad(t)}},listenerHandler:function(e){setTimeout(function(){bricksIsotopeFn.run()},100)}});function bricksIsotope(){bricksIsotopeFn.run()}function bricksIsotopeListeners(){document.addEventListener("bricks/tabs/changed",function(e){var t,n=(null===(t=e.detail)||void 0===t?void 0:t.activePane)||!1;if(n){var r=n.querySelectorAll(".bricks-layout-wrapper.isotope[data-script-id]");r.length&&r.forEach(function(e){var t=e.getAttribute("data-script-id");setTimeout(function(){bricksUtils.updateIsotopeInstance(t)},0)})}}),document.addEventListener("bricks/accordion/open",function(e){var t,n=(null===(t=e.detail)||void 0===t?void 0:t.openItem)||!1;if(n){var r=n.querySelectorAll(".bricks-layout-wrapper.isotope[data-script-id]");r.length&&r.forEach(function(e){var t=e.getAttribute("data-script-id");setTimeout(function(){bricksUtils.updateIsotopeInstance(t)},0)})}}),document.addEventListener("bricks/ajax/nodes_added",function(e){var t,n,r=null==e||null===(t=e.detail)||void 0===t?void 0:t.queryId;if(r){var i,o=window.bricksData.queryLoopInstances[r]||!1;if(o)if((null===(n=o.resultsContainer)||void 0===n||null===(n=n.classList)||void 0===n?void 0:n.contains("bricks-masonry"))||window.bricksData.isotopeInstances[r])if(window.bricksData.isotopeInstances[r])bricksUtils.updateIsotopeInstance(r);else bricksUtils.updateIsotopeInstance(null===(i=o.resultsContainer)||void 0===i?void 0:i.getAttribute("data-script-id"))}}),document.addEventListener("bricks/megamenu/repositioned",function(e){var t,n=(null===(t=e.detail)||void 0===t?void 0:t.submenu)||!1;if(n){var r=n.querySelectorAll(".bricks-layout-wrapper.isotope[data-script-id]");r.length&&r.forEach(function(e){var t=e.getAttribute("data-script-id");setTimeout(function(){bricksUtils.updateIsotopeInstance(t)},0)})}}),window.addEventListener("load",function(){bricksIsotope()})}var bricksMapFn=new BricksFunction({parentNode:document,selector:".brxe-map",eachElement:function(e,t){setTimeout(function(){var t=function(){var t=e.dataset.bricksMapOptions;if(!t)return!1;try{return JSON.parse(t)}catch(e){return!1}}();if(t){var n=Array.isArray(null==t?void 0:t.addresses)?t.addresses:[{address:"Berlin, Germany"}],r=[],i={};null!=t&&t.marker&&(i.icon={url:t.marker},null!=t&&t.markerHeight&&null!=t&&t.markerWidth&&(i.icon.scaledSize=new google.maps.Size(parseInt(t.markerWidth),parseInt(t.markerHeight))));var o={};null!=t&&t.markerActive&&(o={url:t.markerActive},null!=t&&t.markerActiveHeight&&null!=t&&t.markerActiveWidth&&(o.scaledSize=new google.maps.Size(parseInt(t.markerActiveWidth),parseInt(t.markerActiveHeight))));var a=[],s=new google.maps.LatLngBounds,c="auto";t.draggable?t.scrollwheel&&t.draggable?c="cooperative":!t.scrollwheel&&t.draggable&&(c="greedy"):c="none",t.disableDefaultUI&&(t.fullscreenControl=!1,t.mapTypeControl=!1,t.streetViewControl=!1,t.zoomControl=!1);var l=t.zoom?parseInt(t.zoom):12,d={zoom:l,gestureHandling:c,fullscreenControl:t.fullscreenControl,mapTypeControl:t.mapTypeControl,streetViewControl:t.streetViewControl,zoomControl:t.zoomControl,disableDefaultUI:t.disableDefaultUI};if(null!=t&&t.styles)try{d.styles=JSON.parse(t.styles)}catch(e){console.warn("Error parsing map styles:",e)}t.zoomControl&&(null!=t&&t.maxZoom&&(d.maxZoom=parseInt(t.maxZoom)),null!=t&&t.minZoom&&(d.minZoom=parseInt(t.minZoom)));for(var u=new google.maps.Map(e,d),p=0;p<n.length;p++){var b=n[p];if(null!=b&&b.latitude&&null!=b&&b.longitude)f(b,{lat:parseFloat(b.latitude),lng:parseFloat(b.longitude)});else if(null!=b&&b.address){(new google.maps.Geocoder).geocode({address:b.address},v(b))}}null!=t&&t.type&&u.setMapTypeId(t.type)}function v(e){return function(t,n){if("OK"===n){var r=t[0].geometry.location;f(e,r)}else console.warn("Geocode error:",n)}}function f(e,t){i.map=u,i.position=t;var c=new google.maps.Marker(i);if(c.setMap(u),r.push(c),google.maps.event.addListener(c,"click",function(){!function(e){var l;null!=i&&i.icon&&r.forEach(function(e){e.setIcon(i.icon)});a.forEach(function(e){e.hide()}),null!==(l=o)&&void 0!==l&&l.url&&c.setIcon(o);var d,p="",b=(null==e?void 0:e.infoTitle)||!1,v=(null==e?void 0:e.infoSubtitle)||!1,f=(null==e?void 0:e.infoOpeningHours)||!1,m=(null==e?void 0:e.infoImages)||{};Array.isArray(m)||(m=Array.isArray(null===(d=m)||void 0===d?void 0:d.images)?m.images:[]);b&&(p+='<h3 class="title">'.concat(b,"</h3>"));v&&(p+='<p class="subtitle">'.concat(v,"</p>"));f&&(p+='<ul class="content">',(f=f.split("\n")).length&&f.forEach(function(e){p+="<li>".concat(e,"</li>")}),p+="</ul>");m.length&&(p+='<ul class="images bricks-lightbox">',m.forEach(function(t){p+="<li>",t.thumbnail&&t.src&&(p+='<a\n\t\t\t\t\t\t\t\t\tdata-pswp-src="'.concat(t.src,'"\n\t\t\t\t\t\t\t\t\tdata-pswp-width="').concat((null==t?void 0:t.width)||376,'"\n\t\t\t\t\t\t\t\t\tdata-pswp-height="').concat((null==t?void 0:t.height)||376,'"\n\t\t\t\t\t\t\t\t\tdata-pswp-id="').concat(e.id,'">'),p+='<img src="'.concat(t.thumbnail,'"/>'),p+="</a>"),p+="</li>"}),p+="</ul>");if(p){var g=parseInt(null==e?void 0:e.infoWidth)||300,y={content:p,disableAutoPan:!0,pixelOffset:new google.maps.Size(0,0),alignBottom:!1,infoBoxClearance:new google.maps.Size(20,20),enableEventPropagation:!1,zIndex:1001,boxStyle:{opacity:1,zIndex:999,top:0,left:0,width:"".concat(g,"px")}};void 0!==window.jQuery&&(y.closeBoxURL="",y.content+='<span class="close">×</span>');var w=new InfoBox(y);w.open(u,c),a.push(w),setTimeout(function(){var e=w.div_.offsetHeight,t=u.getProjection().fromLatLngToPoint(c.getPosition()),n=u.getProjection().fromPointToLatLng(new google.maps.Point(t.x,t.y-e*function(){var e=u.getCenter(),t=u.getZoom(),n=1,r=u.getProjection().fromLatLngToPoint(new google.maps.LatLng(e.lat()-n/Math.pow(2,t),e.lng()-n/Math.pow(2,t))),i=u.getProjection().fromLatLngToPoint(new google.maps.LatLng(e.lat()+n/Math.pow(2,t),e.lng()+n/Math.pow(2,t)));return Math.abs(i.x-r.x)}()/2));u.panTo(n)},100),google.maps.event.addListener(w,"domready",function(e){m.length&&bricksPhotoswipe(),void 0!==window.jQuery&&jQuery(".close").on("click",function(){w.close(),null!=i&&i.icon&&c.setIcon(i.icon),n.length>1&&(s.extend(t),u.fitBounds(s),u.panToBounds(s))})})}}(e)}),s.extend(t),u.fitBounds(s),u.panToBounds(s),1===n.length)var d=google.maps.event.addListener(u,"idle",function(){u.setZoom(l),google.maps.event.removeListener(d)})}},1e3*t)}});function bricksMap(){bricksMapFn.run()}var bricksMapLeafletFn=new BricksFunction({parentNode:document,selector:".brxe-map-leaflet",eachElement:function(e,t){var n=JSON.parse(e.dataset.mapOptions),r=function(){var e=[];return n.layers.forEach(function(t){var n=t.name,r=t.url,i=_objectWithoutProperties(t,_excluded);e[n]=L.tileLayer(r,i)}),e}(),i=Object.values(r);i.length&&(n.map.layers=i[0]);var o=L.map(e,n.map);i.length>1&&L.control.layers(r).addTo(o),function(){for(var e=0;e<n.markers.length;e++){var t=n.markers[e],r={};t.icon&&(r.icon=L.icon(t.icon));var i=L.marker([t.lat,t.lng],r).addTo(o);t.popupText&&i.bindPopup(t.popupText)}}()}});function bricksMapLeaflet(){document.querySelector(".brxe-map-leaflet")&&function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:500,r=window.setInterval(function(){window[e]&&(window.clearInterval(r),t(window[e]))},n)}("L",function(){setTimeout(function(){bricksMapLeafletFn.run()},bricksIsFrontend?0:1e3)})}var bricksPieChartFn=new BricksFunction({parentNode:document,selector:".brxe-pie-chart",windowVariableCheck:["EasyPieChart"],eachElement:function(e){new BricksIntersect({element:e,callback:function(e){var t=e.getElementsByTagName("canvas");t.length&&t[0].remove();var n=function(t){var n=t.match(/var\((--[^)]+)\)/);if(n){var r=n[1];return getComputedStyle(e).getPropertyValue(r).trim()}return t},r=n(e.dataset.barColor),i=n(e.dataset.trackColor);new EasyPieChart(e,{size:e.dataset.size&&e.dataset.size>0?e.dataset.size:160,lineWidth:e.dataset.lineWidth,barColor:r,trackColor:i,lineCap:e.dataset.lineCap,scaleColor:e.dataset.scaleColor,scaleLength:e.dataset.scaleLength,rotate:0})},threshold:1})}});function bricksPieChart(){bricksPieChartFn.run()}var bricksPricingTablesFn=new BricksFunction({parentNode:document,selector:".brxe-pricing-tables",eachElement:function(e){var t=bricksQuerySelectorAll(e,".tab"),n=bricksQuerySelectorAll(e,".pricing-table");t.forEach(function(e){e.classList.contains("listening")||(e.classList.add("listening"),e.addEventListener("click",function(){e.classList.contains("active")||(n.forEach(function(e){e.classList.toggle("active")}),t.forEach(function(e){e.classList.remove("active")}),e.classList.add("active"))}))})}});function bricksPricingTables(){bricksPricingTablesFn.run()}var bricksPostReadingProgressBarFn=new BricksFunction({parentNode:document,selector:".brxe-post-reading-progress-bar",eachElement:function(e){var t=!!e.dataset.contentSelector&&document.querySelector(e.dataset.contentSelector);window.addEventListener("scroll",function(){var n=window.scrollY,r=document.documentElement.scrollHeight-document.documentElement.clientHeight;if(t){var i=t.getBoundingClientRect();r=i.height,n=i.top>0?0:-i.top}e.setAttribute("value",Math.ceil(n/r*100))})}});function bricksPostReadingProgressBar(){bricksPostReadingProgressBarFn.run()}var bricksProgressBarFn=new BricksFunction({parentNode:document,selector:".brxe-progress-bar .bar span",eachElement:function(e){new BricksIntersect({element:e,callback:function(){e.dataset.width&&setTimeout(function(){e.style.width=e.dataset.width},"slow")},threshold:1})}});function bricksProgressBar(){bricksProgressBarFn.run()}var bricksSplideFn=new BricksFunction({parentNode:document,selector:".brxe-slider-nested.splide",windowVariableCheck:["Splide"],forceReinit:function(e,t){return!bricksIsFrontend},eachElement:function(e){var t,n=bricksQuerySelectorAll(e,[".splide__list > .brxe-container",".splide__list > .brxe-block",".splide__list > .brxe-div"]);n.forEach(function(e){e.classList.add("splide__slide"),e.dataset.id=e.id});var r=e.dataset.scriptId;window.bricksData.splideInstances.hasOwnProperty(r)&&window.bricksData.splideInstances[r].destroy();var i=new Splide(e);i.mount();var o={};try{(o=JSON.parse(e.dataset.splide)).i18n={prev:window.bricksData.i18n.prevSlide,next:window.bricksData.i18n.nextSlide,first:window.bricksData.i18n.firstSlide,last:window.bricksData.i18n.lastSlide,slideX:window.bricksData.i18n.slideX,pageX:window.bricksData.i18n.slideX,play:window.bricksData.i18n.play,pause:window.bricksData.i18n.pause,carousel:window.bricksData.i18n.splide.carousel,select:window.bricksData.i18n.splide.select,slide:window.bricksData.i18n.splide.slide,slideLabel:window.bricksData.i18n.splide.slideLabel}}catch(e){console.warn("bricksSplide: Error parsing JSON of data-script-args",r)}if(null!==(t=o)&&void 0!==t&&t.autoHeight){var a=function(){try{var e,t=null==i||null===(e=i.Components)||void 0===e?void 0:e.Slides;if(!t)return void console.error("Slides component is undefined:",r);var o=t.getAt(i.index),a=null==o?void 0:o.slide;if(!a)return void console.error("Slide is undefined:",r);var s=a.parentElement;if(!s)return void console.error("Parent element is undefined:",r);var c=0;n.forEach(function(e){e.classList.contains("is-visible")&&e.offsetHeight>c&&(c=e.offsetHeight)}),c||(c=a.offsetHeight),s.style.height="".concat(c,"px")}catch(e){console.error("An error occurred while updating the height:",e,r)}};i?(a(),"function"==typeof i.on?(i.on("move resize",a),i.on("moved",a)):console.error("splideInstance.on is not a function")):console.error("splideInstance is undefined")}window.bricksData.splideInstances[r]=i,n.forEach(function(t,n){if(t.dataset.id){t.id=t.dataset.id;var r=e.querySelector(".splide__pagination");if(r){var i=r.querySelector("li:nth-child(".concat(n+1,") .splide__pagination__page"));i&&i.setAttribute("aria-controls",t.id)}}if(!t.classList.contains("bricks-lazy-hidden")){var o=t.getAttribute("style")||"";t.dataset.style&&(o+=t.dataset.style,t.setAttribute("style",o))}}),e.closest(".tab-pane")&&document.addEventListener("bricks/tabs/changed",function(e){i.refresh()})}});function bricksSplide(){bricksSplideFn.run()}var bricksSwiperFn=new BricksFunction({parentNode:document,selector:".bricks-swiper-container",windowVariableCheck:["Swiper"],forceReinit:function(e,t){return!bricksIsFrontend},eachElement:function(e){var t;try{t=JSON.parse(e.dataset.scriptArgs)}catch(n){console.warn("bricksSwiper: Error parsing JSON of data-script-args",e),t={}}var n=e.classList.contains("[class*=brxe-]")?e:e.closest("[class*=brxe-]");if(n){bricksQuerySelectorAll(e,[".splide__list > .brxe-container",".splide__list > .brxe-block",".splide__list > .brxe-div"]).forEach(function(e){return e.classList.add("swiper-slide")});var r=n.dataset.scriptId,i=window.bricksData.swiperInstances.hasOwnProperty(r)?window.bricksData.swiperInstances[r]:void 0;i&&i.destroy(),t.observer=!1,t.observeParents=!0,t.resizeObserver=!0,t.slidesToShow=t.hasOwnProperty("slidesToShow")?t.slidesToShow:1,t.slidesPerGroup=t.hasOwnProperty("slidesPerGroup")?t.slidesPerGroup:1,t.speed=t.hasOwnProperty("speed")?parseInt(t.speed):300,t.effect=t.hasOwnProperty("effect")?t.effect:"slide",t.spaceBetween=t.hasOwnProperty("spaceBetween")?t.spaceBetween:0,t.initialSlide=t.hasOwnProperty("initialSlide")?t.initialSlide:0,t.keyboard={enabled:bricksIsFrontend,onlyInViewport:!0,pageUpDown:!1},t.watchOverflow=!0,t.hasOwnProperty("effect")&&"flip"===t.effect&&(t.flipEffect={slideShadows:!1}),t.hasOwnProperty("effect")&&"fade"===t.effect&&(t.fadeEffect={crossFade:!0}),t.navigation&&(t.navigation={prevEl:n.querySelector(".bricks-swiper-button-prev"),nextEl:n.querySelector(".bricks-swiper-button-next")}),t.pagination&&(t.pagination={el:n.querySelector(".swiper-pagination"),type:"bullets",clickable:!0},1==t.dynamicBullets&&(delete t.dynamicBullets,t.pagination.dynamicBullets=!0)),t.a11y={prevSlideMessage:window.bricksData.i18n.prevSlide,nextSlideMessage:window.bricksData.i18n.nextSlide,firstSlideMessage:window.bricksData.i18n.firstSlide,lastSlideMessage:window.bricksData.i18n.lastSlide,paginationBulletMessage:window.bricksData.i18n.slideX,slideLabelMessage:window.bricksData.i18n.swiper.slideLabelMessage},i=new Swiper(e,t),window.bricksData.swiperInstances[r]=i}}});function bricksSwiper(){bricksSwiperFn.run()}var bricksVideoFn=new BricksFunction({parentNode:document,selector:".brxe-video",eachElement:function(e){if(bricksIsFrontend){var t=function(){var t=e.querySelector(".bricks-video-overlay"),n=e.querySelector(".bricks-video-overlay-icon");t&&t.remove(),n&&n.remove()};e.addEventListener("click",t),e.addEventListener("keydown",function(n){"Enter"!==n.key&&" "!==n.key||t(),e.querySelector("video")||"Enter"!==n.key&&" "!==n.key||n.preventDefault()})}var n=e.querySelector("video");if(n){if(window.hasOwnProperty("Plyr")){var r,i=e.dataset.scriptId,o=e.querySelector(".bricks-plyr"),a=(null===(r=window.bricksData)||void 0===r||null===(r=r.videoInstances)||void 0===r?void 0:r[i])||void 0;a&&a.destroy(),o&&(a=new Plyr(o)),window.bricksData.videoInstances[i]=a}n.hasAttribute("autoplay")&&n.setAttribute("playsinline",!0)}}});function bricksVideo(){bricksVideoFn.run()}function bricksFacebookSDK(){if(document.querySelector(".brxe-facebook-page")){var e=window.bricksData.hasOwnProperty("locale")?window.bricksData.locale:"en_US",t=window.bricksData.hasOwnProperty("facebookAppId")?window.bricksData.facebookAppId:null,n="https://connect.facebook.net/".concat(e,"/sdk.js"),r=new XMLHttpRequest;r.open("GET",n),r.onreadystatechange=function(){if(4==this.readyState&&200==this.status){var e,n=document.createElement("script");!bricksIsFrontend&&null!==(e=window.bricksData)&&void 0!==e&&e.builderCloudflareRocketLoader&&n.setAttribute("data-cfasync","false"),n.type="text/javascript",n.id="bricks-facebook-page-sdk",n.appendChild(document.createTextNode(r.responseText)),document.body.appendChild(n),FB.init({appId:t,version:"v3.3",xfbml:!0})}},r.send()}}var bricksPrettifyFn=new BricksFunction({parentNode:document,selector:".prettyprint.prettyprinted",run:function(){if(window.hasOwnProperty("PR")){PR.prettyPrint();var e=bricksQuerySelectorAll(document,".prettyprint.prettyprinted");!bricksIsFrontend&&e.length&&e.forEach(function(e){e.classList.remove("prettyprinted"),PR.prettyPrint()})}}});function bricksPrettify(){bricksPrettifyFn.run()}function bricksSkipLinks(){var e=bricksQuerySelectorAll(document,".skip-link");e&&e.forEach(function(e){e.addEventListener("click",function(t){t.preventDefault();var n=document.getElementById(e.href.split("#")[1]);n&&(n.setAttribute("tabindex","-1"),n.addEventListener("blur",function(){n.removeAttribute("tabindex")},{once:!0}),n.focus())})})}var bricksInteractionsFn=new BricksFunction({parentNode:document,selector:"[data-interactions]",frontEndOnly:!0,eachElement:function(e){var t,n=[];try{n=JSON.parse(e.dataset.interactions)}catch(e){return console.info("error:bricksInteractions",e),!1}var r=(null===(t=e.dataset)||void 0===t?void 0:t.interactionId)||!1;n&&r&&(n.forEach(function(t){var n,i=!1;if(null!=t&&t.trigger){if("scroll"===t.trigger){var o=0;if(null!=t&&t.scrollOffset)if((o=null==t?void 0:t.scrollOffset.replace("px","")).includes("%"))o=Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight)/100*parseInt(o);else o.includes("vh")&&(o=window.innerHeight/100*parseInt(o));t.scrollOffset=o}else"mouseleaveWindow"===t.trigger&&(t.trigger="mouseleave",i=!0);if(e)switch(t.el=e,t.groupId=i?"document":r,null!==(n=window.bricksData)&&void 0!==n&&n.interactions||(window.bricksData.interactions=[]),window.bricksData.interactions.push(t),t.trigger){case"click":case"mouseover":case"mouseenter":case"mouseleave":case"focus":case"blur":(i?document.documentElement:e).addEventListener(t.trigger,function(e){return bricksInteractionCallback(e,t)},{once:null==t?void 0:t.runOnce});break;case"animationEnd":var a=(null==t?void 0:t.animationId)||!1;if(!a){var s=window.bricksData.interactions.filter(function(e){return e.groupId===r&&"startAnimation"===e.action&&e.id!==t.id});s.length&&(a=s[s.length-1].id)}a&&a!==t.id&&document.addEventListener("bricks/animation/end/".concat(a),function(n){bricksInteractionCallbackExecution(e,t)},{once:null==t?void 0:t.runOnce});break;case"contentLoaded":var c=(null==t?void 0:t.delay)||0;c&&c.includes("ms")?c=parseInt(c):c&&c.includes("s")&&(c=1e3*parseFloat(c)),setTimeout(function(){bricksInteractionCallbackExecution(e,t)},c);break;case"enterView":new BricksIntersect({element:e,callback:function(e){return bricksInteractionCallbackExecution(e,t)},once:null==t?void 0:t.runOnce,trigger:null==t?void 0:t.trigger,rootMargin:null==t?void 0:t.rootMargin});break;case"leaveView":new BricksIntersect({element:e,callback:function(e){return bricksInteractionCallbackExecution(e,t)},once:null==t?void 0:t.runOnce,trigger:null==t?void 0:t.trigger});break;case"showPopup":case"hidePopup":var l="showPopup"===t.trigger?"bricks/popup/open":"bricks/popup/close";document.addEventListener(l,function(n){var r,i=(null===(r=n.detail)||void 0===r?void 0:r.popupElement)||!1;i&&i===e&&bricksUtils.maybeRunOnceInteractions(e,t)});break;case"ajaxStart":case"ajaxEnd":var d="ajaxStart"===t.trigger?"bricks/ajax/start":"bricks/ajax/end",u=(null==t?void 0:t.ajaxQueryId)||!1;if(!u)return;document.addEventListener(d,function(n){var r,i=(null===(r=n.detail)||void 0===r?void 0:r.queryId)||!1;i&&i===u&&bricksUtils.maybeRunOnceInteractions(e,t)});break;case"formSubmit":case"formSuccess":case"formError":var p=null==t?void 0:t.formId;if(!p)return;var b="bricks/form/".concat(t.trigger.replace("form","").toLowerCase());document.addEventListener(b,function(n){var r,i=null===(r=n.detail)||void 0===r?void 0:r.elementId;i&&i===(p=(p=p.replace("#","")).replace("brxe-",""))&&bricksUtils.maybeRunOnceInteractions(e,t)});break;case"filterOptionEmpty":case"filterOptionNotEmpty":var v=(null==t?void 0:t.filterElementId)||!1;if(!v)return;v=(v=v.replace("#","")).replace("brxe-","");var f="bricks/filter/option/".concat(t.trigger.replace("filterOption","").toLowerCase());document.addEventListener(f,function(n){var r,i=(null===(r=n.detail)||void 0===r?void 0:r.filterElementIds)||[];i.length&&i.includes(v)&&bricksUtils.maybeRunOnceInteractions(e,t)});break;case"wooAddedToCart":case"wooAddingToCart":case"wooRemovedFromCart":case"wooUpdateCart":case"wooCouponApplied":case"wooCouponRemoved":if("undefined"==typeof jQuery)return;var m=null;"wooAddedToCart"===t.trigger?m="added_to_cart":"wooAddingToCart"===t.trigger?m="adding_to_cart":"wooRemovedFromCart"===t.trigger?m="item_removed_from_classic_cart":"wooUpdateCart"===t.trigger?m="updated_cart_totals":"wooCouponApplied"===t.trigger?m="applied_coupon applied_coupon_in_checkout":"wooCouponRemoved"===t.trigger&&(m="removed_coupon removed_coupon_in_checkout"),m&&jQuery(document.body).on(m,function(n){bricksUtils.maybeRunOnceInteractions(e,t)})}}}),bricksUtils.hideOrShowLoadMoreButtons("all"))}});function bricksInteractions(){bricksInteractionsFn.run()}function bricksTrapFocus(e,t){if("Tab"===e.key){var n=bricksGetVisibleFocusables(t),r=n[0],i=n[n.length-1];e.shiftKey?document.activeElement===r&&(i.focus(),e.preventDefault()):document.activeElement===i&&(r.focus(),e.preventDefault())}}function bricksFocusOnFirstFocusableElement(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=bricksGetFocusables(e)[0];if(n)if(t){var r=0;requestAnimationFrame(function e(){!function(e){var t=window.getComputedStyle(e);if("none"===t.display||"visible"!==t.visibility||parseFloat(t.opacity)<.1)return!1;var n=e.getBoundingClientRect();return 0!==n.width&&0!==n.height&&!(n.bottom<0||n.top>window.innerHeight||n.right<0||n.left>window.innerWidth)}(n)?r++<60?requestAnimationFrame(e):console.warn("Element never became focusable:",n):n.focus()})}else n.focus()}function bricksPopups(){var e=null;document.addEventListener("bricks/popup/open",function(t){var n,r,i,o,a=(null===(n=t.detail)||void 0===n?void 0:n.popupElement)||!1;if(a&&bricksIsFrontend&&!a.classList.contains("brx-infobox-popup")){var s,c=(null===(r=a.dataset)||void 0===r?void 0:r.popupCloseOn)||"backdrop-esc";if(c.includes("esc")){var l=function(e){return function(e,t){"Escape"===e.key&&bricksClosePopup(t)}(e,a)};document.addEventListener("keyup",l),document.addEventListener("bricks/popup/close",function(){document.removeEventListener("keyup",l)})}if(c.includes("backdrop")){var d=function(e){return function(e,t){(e.target.classList.contains("brx-popup-backdrop")||e.target.classList.contains("brx-popup"))&&bricksClosePopup(t)}(e,a)};document.addEventListener("click",d),document.addEventListener("bricks/popup/close",function(){document.removeEventListener("click",d)})}if(e=document.activeElement,null!==(i=a.dataset)&&void 0!==i&&i.popupScrollToTop)null===(s=a.querySelector(".brx-popup-content"))||void 0===s||s.scrollTo(0,0);if(null===(o=a.dataset)||void 0===o||!o.popupDisableAutoFocus){var u=bricksGetFocusables(a),p=u.length>0?u[0]:null;if(p){var b;null===(b=a.querySelector(".brx-popup-content"))||void 0===b||b.scrollTo(0,0);var v=p.getBoundingClientRect(),f=a.querySelector(".brx-popup-content").getBoundingClientRect(),m=v.top-f.top+a.scrollTop-10;a.querySelector(".brx-popup-content").scrollTo({top:m})}}setTimeout(function(){var e,t,n;(null!==(e=a.dataset)&&void 0!==e&&e.popupDisableAutoFocus||bricksFocusOnFirstFocusableElement(a),null!==(t=a.dataset)&&void 0!==t&&t.popupScrollToTop)&&(null===(n=a.querySelector(".brx-popup-content"))||void 0===n||n.scrollTo({top:0,left:0,behavior:"smooth"}))},100);var g=function(e){return bricksTrapFocus(e,a)};document.addEventListener("keydown",g),document.addEventListener("bricks/popup/close",function(){document.removeEventListener("keydown",g),e&&e.focus()})}})}function bricksScrollInteractions(){var e,t=Array.isArray(null===(e=window.bricksData)||void 0===e?void 0:e.interactions)?window.bricksData.interactions:[],n=window.scrollY,r=[];t.forEach(function(e,t){"scroll"===(null==e?void 0:e.trigger)&&n>=e.scrollOffset&&(bricksInteractionCallbackExecution(e.el,e),null!=e&&e.runOnce&&r.push(e.id))}),r.forEach(function(e){window.bricksData.interactions=window.bricksData.interactions.filter(function(t){return t.id!==e})})}function bricksInteractionCallback(e,t){if("click"===(null==e?void 0:e.type)){var n;if("A"===e.target.tagName&&"#"!==e.target.getAttribute("href")&&null!==(n=e.target.getAttribute("href"))&&void 0!==n&&n.startsWith("#"))return;null!=t&&t.disablePreventDefault||e.preventDefault()}bricksInteractionCallbackExecution(t.el,t)}function bricksInteractionCallbackExecution(e,t){var n,r,i;switch((null==t?void 0:t.target)||"self"){case"custom":null!=t&&t.targetSelector&&(i=bricksQuerySelectorAll(document,t.targetSelector));break;case"popup":var o;if(null!=t&&t.templateId)null!==(o=e.dataset)&&void 0!==o&&o.interactionLoopId&&(i=bricksQuerySelectorAll(document,'.brx-popup[data-popup-id="'.concat(t.templateId,'"][data-popup-loop-id="').concat(e.dataset.interactionLoopId,'"]'))),i&&i.length||(i=bricksQuerySelectorAll(document,'.brx-popup[data-popup-id="'.concat(t.templateId,'"]')));break;case"offcanvas":null!=t&&t.offCanvasSelector&&(i=e);break;default:i=e}if(i)if(i=Array.isArray(i)?i:[i],bricksInteractionCheckConditions(t))switch(null==t?void 0:t.action){case"show":case"hide":i.forEach(function(n){if(null!=n&&n.classList.contains("brx-popup"))if("show"===t.action){var r,i={};null!=t&&t.popupContextId&&(i.popupContextId=t.popupContextId),null!=t&&t.popupContextType&&(i.popupContextType=t.popupContextType),null!==(r=e.dataset)&&void 0!==r&&r.interactionLoopId&&(i.loopId=e.dataset.interactionLoopId),bricksOpenPopup(n,0,i)}else"hide"===t.action&&bricksClosePopup(n);else"hide"===t.action?n.style.display="none":"none"===n.style.display?(n.style.display=null,"none"===window.getComputedStyle(n).display&&(n.style.display="block")):n.style.display="block"});break;case"setAttribute":case"removeAttribute":case"toggleAttribute":var a=null==t?void 0:t.actionAttributeKey;a&&i.forEach(function(e){var n=(null==t?void 0:t.actionAttributeValue)||"";"class"===a?(n?n.split(" "):[]).forEach(function(n){"setAttribute"===t.action?e.classList.add(n):"removeAttribute"===t.action?e.classList.remove(n):e.classList.toggle(n)}):"setAttribute"===t.action?e.setAttribute(a,n):"removeAttribute"===t.action||e.hasAttribute(a)?e.removeAttribute(a):e.setAttribute(a,n)});break;case"scrollTo":var s=i[0];if(!s||!s.scrollIntoView)return;var c=(null==t?void 0:t.scrollToOffset)||0,l=(null==t?void 0:t.scrollToDelay)||1;setTimeout(function(){"string"==typeof c&&(c=c.replace("px",""));var e=s.getBoundingClientRect().top;window.scrollBy(0,e-parseInt(c))},parseInt(l));break;case"clearForm":var d=null==t?void 0:t.targetFormSelector,u=null;if(["formSubmit","formSuccess","formError"].includes(t.trigger)){var p=null==t?void 0:t.formId;p=(p=p.replace("#","")).replace("brxe-",""),u=document.querySelectorAll('.brxe-form[data-element-id="'.concat(p,'"]'))}else u=d?document.querySelectorAll(d):document.querySelectorAll("form");u&&u.length&&u.forEach(function(e){e.querySelectorAll("input, textarea, select").forEach(function(e){"SELECT"===e.tagName?e.selectedIndex=0:"TEXTAREA"===e.tagName?e.value="":"checkbox"===e.type||"radio"===e.type?e.checked=!1:e.value=""}),e.querySelectorAll(".file-result.show > .bricks-button.remove").forEach(function(e){e.click()})});break;case"click":i&&i.length&&i.forEach(function(e){e.click()});break;case"storageAdd":case"storageRemove":case"storageCount":var b=null==t?void 0:t.storageType,v=null==t?void 0:t.actionAttributeKey,f=t.hasOwnProperty("actionAttributeValue")?t.actionAttributeValue:0;if(b&&v)if("storageAdd"===t.action)bricksStorageSetItem(b,v,f);else if("storageRemove"===t.action)bricksStorageRemoveItem(b,v);else if("storageCount"===t.action){var m=bricksStorageGetItem(b,v);bricksStorageSetItem(b,v,(m=m?parseInt(m):0)+1)}break;case"startAnimation":var g=null==t?void 0:t.animationType;if(g){var y=0;null!=t&&t.animationDelay&&(t.animationDelay.includes("ms")?y=parseInt(t.animationDelay):t.animationDelay.includes("s")&&(y=1e3*parseFloat(t.animationDelay))),setTimeout(function(){i.forEach(function(n){var r,i=1e3,o=null===(r=n)||void 0===r?void 0:r.classList.contains("brx-popup");if(o&&(n=n.querySelector(".brx-popup-content")),null!=t&&t.animationDuration&&(n.style.animationDuration=t.animationDuration,t.animationDuration.includes("ms")?i=parseInt(t.animationDuration):t.animationDuration.includes("s")&&(i=1e3*parseFloat(t.animationDuration))),null!=t&&t.animationDelay&&(i+=y),o&&"showPopup"!==t.trigger&&"hidePopup"!==t.trigger){var a,s=n.parentNode,c={};null!==(a=e.dataset)&&void 0!==a&&a.interactionLoopId&&(c.loopId=e.dataset.interactionLoopId),g.includes("In")&&bricksOpenPopup(s,i,c)}n.classList.add("brx-animated"),n.setAttribute("data-animation",g),n.setAttribute("data-animation-id",t.id||""),bricksAnimationFn.run({elementsToAnimate:[n],removeAfterMs:i})})},y)}break;case"loadMore":var w=null==t?void 0:t.loadMoreQuery,k=null===(n=window.bricksData.queryLoopInstances)||void 0===n?void 0:n[w];if(!k)return;var h=(null==k?void 0:k.componentId)||!1,x=h||w;x.includes("-")&&(x=x.split("-")[0]);var S=Array.from(null===(r=k.resultsContainer)||void 0===r?void 0:r.querySelectorAll(".brxe-".concat(x,":not(.brx-popup)"))).pop();S&&(e.classList.contains("is-loading")||(e.classList.add("is-loading"),S.dataset.queryElementId=w,h&&(S.dataset.queryComponentId=h),bricksQueryLoadPage(S,!0).then(function(t){e.classList.remove("is-loading"),bricksUtils.hideOrShowLoadMoreButtons(w)})));break;case"javascript":if(null!=t&&t.jsFunction){var L,E=null!==(L=window[t.jsFunction])&&void 0!==L&&L;if(t.jsFunction.includes(".")){var I=t.jsFunction.split("."),A=window;I.forEach(function(e){A=A[e]}),"function"==typeof A&&(E=A)}if(E&&"function"==typeof E){var T={source:e,targets:i},q={};null!=t&&t.jsFunctionArgs&&Array.isArray(t.jsFunctionArgs)&&t.jsFunctionArgs.forEach(function(e,t){if(null!=e&&e.jsFunctionArg&&null!=e&&e.id){var n=e.id,r=e.jsFunctionArg;"%brx%"===e.jsFunctionArg&&(n=e.jsFunctionArg,r=T),q[n]=r}}),i.forEach(function(e){null!=q&&q["%brx%"]&&(q["%brx%"].target=e),Object.keys(q).length?E.apply(void 0,_toConsumableArray(Object.keys(q).map(function(e){return q[e]}))):E()})}else console.error('Bricks interaction: Custom JavaScript function "'.concat(t.jsFunction,'" not found.'))}break;case"toggleOffCanvas":var F=(null==t?void 0:t.offCanvasSelector)||!1;if(!F)return;bricksUtils.toggleAction(e,{selector:F});break;case"openAddress":case"closeAddress":i.forEach(function(e){bricksUtils.toggleMapInfoBox(t)})}else if("startAnimation"===(null==t?void 0:t.action))i.forEach(function(e){e.removeAttribute("data-interaction-hidden-on-load")})}function bricksOpenPopup(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(bricksIsFrontend&&(e&&(e.nodeType===Node.ELEMENT_NODE?t=e:e&&(t=document.querySelector('.brx-popup[data-popup-id="'.concat(e,'"]')))),t)){var i=t.dataset.popupId;bricksPopupCheckLimit(t)&&bricksPopupCheckBreakpoint(t)&&(t.classList.remove("hide"),t.dataset.popupBodyScroll||document.body.classList.add("no-scroll"),bricksSetVh(),bricksFetchPopupContent(t,r).then(function(e){if(""!==e){t.querySelector(".brx-popup-content").innerHTML=e;var r=new CustomEvent("bricks/ajax/popup/loaded",{detail:{popupId:i,popupElement:t}});document.dispatchEvent(r)}var o=new CustomEvent("bricks/popup/open",{detail:{popupId:i,popupElement:t}});document.dispatchEvent(o),setTimeout(function(){bricksCounter()},n),bricksPopupCounter(t)}))}}function bricksFetchPopupContent(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise(function(r,i){var o;if((null===(o=e.dataset)||void 0===o?void 0:o.popupAjax)||!1){e.querySelector(".brx-popup-content").innerHTML="";var a=e.dataset.popupId,s={postId:window.bricksData.postId,popupId:a,nonce:window.bricksData.nonce,popupContextId:!1,popupContextType:"post",isLooping:!1,popupLoopId:!1,queryElementId:!1,lang:window.bricksData.language||!1,mainQueryId:window.bricksData.mainQueryId||!1};if(null!=t&&t.loopId&&(s.isLooping=!0),null!=t&&t.popupContextId&&(s.popupContextId=t.popupContextId,null!=t&&t.popupContextType&&(s.popupContextType=t.popupContextType)),null!=t&&t.loopId&&!s.popupContextId){var c=t.loopId.split(":");c.length>=4&&c[0].length>=6&&(s.queryElementId=c[0],s.popupLoopId=t.loopId)}var l,d=window.bricksData.restApiUrl.concat("load_popup_content");if("wpml"!==window.bricksData.multilangPlugin||!window.location.search.includes("lang=")&&3==window.bricksData.wpmlUrlFormat||(d=d.concat("?lang="+window.bricksData.language)),document.dispatchEvent(new CustomEvent("bricks/ajax/popup/start",{detail:{popupId:a,popupElement:e}})),s.isLooping)null===(l=e.querySelector(".brx-popup-backdrop"))||void 0===l||l.removeAttribute("data-query-loop-index");var u=new XMLHttpRequest;u.open("POST",d,!0),u.setRequestHeader("Content-Type","application/json; charset=UTF-8"),u.setRequestHeader("X-WP-Nonce",window.bricksData.wpRestNonce),u.onreadystatechange=function(){if(u.readyState===XMLHttpRequest.DONE){var o,c,l=u.status,d="";try{c=JSON.parse(u.response)}catch(e){console.error("Error parsing response:",e)}if(0===l||l>=200&&l<400){var p,b,v,f,m,g,y=(null===(p=c)||void 0===p?void 0:p.html)||!1,w=(null===(b=c)||void 0===b?void 0:b.styles)||!1,k=(null===(v=c)||void 0===v?void 0:v.popups)||!1,h=(null===(f=c)||void 0===f?void 0:f.error)||!1,x=(null===(m=c)||void 0===m?void 0:m.contentClasses)||!1;if(h&&console.error("error:bricksFetchPopupContent",h),y&&(d=y),w&&(d+=w),x){var S=e.querySelector(".brx-popup-content.brx-woo-quick-view");if(S){var L,E=["brx-popup-content","brxe-container","brx-woo-quick-view"];S.classList.forEach(function(e){E.includes(e)||S.classList.remove(e)}),(L=S.classList).add.apply(L,_toConsumableArray(x)),document.body.classList.contains("woocommerce")||S.classList.add("woocommerce")}}if(k&&Object.keys(k).length&&Object.entries(k).forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];document.querySelector('.brx-popup[data-popup-id="'.concat(n,'"]'))||document.body.insertAdjacentHTML("beforeend",r)}),s.isLooping)null===(g=e.querySelector(".brx-popup-backdrop"))||void 0===g||g.setAttribute("data-query-loop-index",0)}else if("rest_cookie_invalid_nonce"===(null===(o=c)||void 0===o?void 0:o.code)&&!n)return void bricksRegenerateNonceAndRetryPopup(e,t).then(r).catch(i);r(d),document.dispatchEvent(new CustomEvent("bricks/ajax/popup/end",{detail:{popupId:a,popupElement:e}}))}},u.send(JSON.stringify(s))}else r("")})}function bricksRegenerateNonceAndRetryPopup(e,t){return new Promise(function(n,r){var i=new XMLHttpRequest;i.open("POST",window.bricksData.ajaxUrl,!0),i.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),i.onreadystatechange=function(){if(i.readyState===XMLHttpRequest.DONE)if(i.status>=200&&i.status<400){var o;try{o=JSON.parse(i.responseText)}catch(e){return void r("Invalid response from server when regenerating nonce")}o.success&&o.data?(window.bricksData.nonce=o.data.bricks_nonce,window.bricksData.wpRestNonce=o.data.rest_nonce,bricksFetchPopupContent(e,t,!0).then(n).catch(r)):r("Failed to regenerate nonces: Invalid response structure")}else r("Failed to regenerate nonce")},i.send("action=bricks_regenerate_query_nonce")})}function bricksClosePopup(e){var t;if(bricksIsFrontend&&(e&&(e.nodeType===Node.ELEMENT_NODE?t=e:e&&(t=document.querySelector('.brx-popup[data-popup-id="'.concat(e,'"]')))),t)){var n=t.dataset.popupId;t.classList.add("hide"),t.dataset.popupBodyScroll||document.querySelectorAll(".brx-popup:not(.hide):not([data-popup-body-scroll])").length||document.body.classList.remove("no-scroll");var r=new CustomEvent("bricks/popup/close",{detail:{popupId:n,popupElement:t}});document.dispatchEvent(r)}}function bricksPopupCheckLimit(e){var t,n,r=null==e||null===(t=e.dataset)||void 0===t?void 0:t.popupLimits,i=null==e||null===(n=e.dataset)||void 0===n?void 0:n.popupId;if(!r)return!0;try{r=JSON.parse(r)}catch(e){return console.info("error:bricksPopupCheckLimit",e),!0}var o=!1,a=Date.now();return Object.entries(r).forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];if("timeStorageInHours"===n){var s=parseInt(bricksStorageGetItem("localStorage","brx_popup_".concat(i,"_lastShown")));a<s+36e5*r&&(o=!0)}else{var c=bricksStorageGetItem(n,"brx_popup_".concat(i,"_total"));c=c?parseInt(c):0,o=o||c>=r}}),!o&&r.timeStorageInHours&&bricksStorageSetItem("localStorage","brx_popup_".concat(i,"_lastShown"),a.toString()),!o}function bricksPopupCheckBreakpoint(e){var t;if(null==e||null===(t=e.classList)||void 0===t||!t.contains("brx-popup"))return!1;var n=parseInt(e.getAttribute("data-popup-show-at"));if(n&&window.innerWidth<n)return!1;var r=e.getAttribute("data-popup-show-on-widths"),i=r?r.split(","):[];if(i.length&&!i.some(function(e){var t=_slicedToArray(e.split("-").map(function(e){var t=Number(e);return isNaN(t)?(console.error("Invalid width value: ".concat(e)),0):t}),2),n=t[0],r=t[1];return window.innerWidth>=n&&window.innerWidth<=r}))return!1;return!0}function bricksPopupCounter(e){var t,n,r=null==e||null===(t=e.dataset)||void 0===t?void 0:t.popupLimits,i=null==e||null===(n=e.dataset)||void 0===n?void 0:n.popupId;if(r){try{r=JSON.parse(r)}catch(e){return console.info("error:bricksPopupCounter",e),!0}Object.entries(r).forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=(t[1],bricksStorageGetItem(n,"brx_popup_".concat(i,"_total")));r=r?parseInt(r):0,bricksStorageSetItem(n,"brx_popup_".concat(i,"_total"),r+1)})}}function bricksInteractionCheckConditions(e){if(!Array.isArray(null==e?void 0:e.interactionConditions))return!0;var t=(null==e?void 0:e.interactionConditionsRelation)||"and",n="and"===t,r=function(e){return isNaN(e)?0:parseFloat(e)};return e.interactionConditions.forEach(function(e){var i=null==e?void 0:e.conditionType,o=(null==e?void 0:e.storageKey)||!1,a=!1;if(i&&o){var s=(null==e?void 0:e.storageCompare)||"exists",c=null==e?void 0:e.storageCompareValue,l=bricksStorageGetItem(i,o);switch(s){case"exists":a=null!==l;break;case"notExists":a=null===l;break;case"==":a=l==c;break;case"!=":a=l!=c;break;case">=":a=r(l)>=r(c);break;case"<=":a=r(l)<=r(c);break;case">":a=r(l)>r(c);break;case"<":a=r(l)<r(c)}}else a=!0;n="and"===t?n&&a:n||a}),n}function bricksStorageGetItem(e,t){if(t){var n;try{switch(e){case"windowStorage":n=window.hasOwnProperty(t)?window[t]:null;break;case"sessionStorage":n=sessionStorage.getItem(t);break;case"localStorage":n=localStorage.getItem(t)}}catch(e){console.info("error:bricksStorageGetItem",e)}return n}}function bricksStorageSetItem(e,t,n){if(t)try{switch(e){case"windowStorage":window[t]=n;break;case"sessionStorage":sessionStorage.setItem(t,n);break;case"localStorage":localStorage.setItem(t,n)}}catch(e){console.info("error:bricksStorageSetItem",e)}}function bricksStorageRemoveItem(e,t){if(t)try{switch(e){case"windowStorage":delete window[t];break;case"sessionStorage":sessionStorage.removeItem(t);break;case"localStorage":localStorage.removeItem(t)}}catch(e){console.info("error:bricksStorageRemoveItem",e)}}function bricksNavNested(){if(bricksIsFrontend){var e=new MutationObserver(function(e){e.forEach(function(e){if("attributes"===e.type&&"class"===e.attributeName){var t=e.target;if(t.classList.contains("brx-open")&&!t.classList.contains("brx-closing")){bricksSetVh();var n=t.querySelector(".brx-nav-nested-items");n&&n.addEventListener("keydown",function(e){return bricksTrapFocus(e,n)}),document.body.classList.add("no-scroll");var r=t.querySelector(".brx-nav-nested-items button.brxe-toggle");r?setTimeout(function(){r.classList.add("is-active"),r.setAttribute("aria-expanded",!0),r.focus()},100):bricksFocusOnFirstFocusableElement(t,!1)}else{document.body.classList.remove("no-scroll");var i=t.dataset.toggleScriptId,o=document.querySelector('button[data-script-id="'.concat(i,'"],[data-interaction-id="').concat(i,'"][data-brx-toggle-offcanvas]'));o&&(o.setAttribute("aria-expanded",!1),o.classList.remove("is-active"),o.focus())}}})}),t=bricksQuerySelectorAll(document,".brxe-nav-nested");t.length&&(t.forEach(function(t){e.observe(t,{attributes:!0,attributeFilter:["class"]}),t.addEventListener("keydown",function(e){var t=document.activeElement;bricksHandleMenuKeyNavigation(e,{isTopLevel:null!==t.closest(".brx-nav-nested-items > li, .brx-nav-nested-items > .brxe-dropdown"),isInDropdown:null!==t.closest(".brx-dropdown-content"),isInSubmenuToggle:null!==t.closest(".brx-submenu-toggle"),getNextFocusable:bricksGetNextMenuFocusableInSubmenuToggle,getPreviousFocusable:bricksGetPreviousMenuFocusableInSubmenuToggle,getLastFocusableInSubmenuToggle:bricksMenuGetLastFocusableInSubmenuToggle,focusNextElement:function(e){return bricksMenuFocusNextElement(e,".brx-nav-nested-items")},focusPreviousElement:function(e){return bricksMenuFocusPreviousElement(e,".brx-nav-nested-items")},focusFirstElement:bricksMenuFocusFirstElement,focusLastElement:bricksMenuFocusLastElement,closeSubmenu:function(e){return bricksSubmenuToggle(e,"remove")}})})}),document.addEventListener("keyup",function(e){"Escape"===e.key&&bricksNavNestedClose()}),document.addEventListener("click",function(e){var t=e.target.closest(".brxe-nav-nested"),n=e.target.closest(".brxe-toggle");t||n||bricksNavNestedClose()}))}}function bricksNavNestedClose(){bricksQuerySelectorAll(document,".brxe-nav-nested.brx-open").forEach(function(e){e.classList.add("brx-closing"),setTimeout(function(){e.classList.remove("brx-closing"),e.classList.remove("brx-open")},200)})}var bricksNavMenuFn=new BricksFunction({parentNode:document,selector:".brxe-nav-menu",eachElement:function(e){e.addEventListener("keydown",function(e){var t=document.activeElement;bricksHandleMenuKeyNavigation(e,{isTopLevel:null!==t.closest(".bricks-nav-menu > li"),isInDropdown:null!==t.closest(".sub-menu"),isInSubmenuToggle:null!==t.closest(".brx-submenu-toggle"),getNextFocusable:bricksGetNextMenuFocusableInSubmenuToggle,getPreviousFocusable:bricksGetPreviousMenuFocusableInSubmenuToggle,getLastFocusableInSubmenuToggle:bricksMenuGetLastFocusableInSubmenuToggle,focusNextElement:function(e){return bricksMenuFocusNextElement(e,".bricks-nav-menu")},focusPreviousElement:function(e){return bricksMenuFocusPreviousElement(e,".bricks-nav-menu")},focusFirstElement:bricksMenuFocusFirstElement,focusLastElement:bricksMenuFocusLastElement,closeSubmenu:function(e){e.setAttribute("aria-expanded","false"),e.closest(".menu-item-has-children").classList.remove("open")}})})}});function bricksNavMenu(){bricksNavMenuFn.run()}function bricksHandleMenuKeyNavigation(e,t){var n=t.isTopLevel,r=t.isInDropdown,i=t.isInSubmenuToggle,o=t.getNextFocusable,a=t.getPreviousFocusable,s=t.getLastFocusableInSubmenuToggle,c=t.focusNextElement,l=t.focusPreviousElement,d=t.focusFirstElement,u=t.focusLastElement,p=(t.closeSubmenu,e.key),b=document.activeElement;["ArrowDown","ArrowRight","ArrowUp","ArrowLeft","Home","End"].includes(p)&&e.preventDefault();var v="rtl"===document.dir||"rtl"===document.documentElement.dir||null!==b.closest('[dir="rtl"]');switch(p){case"ArrowDown":if(n)if(i){var f=b.closest(".brx-submenu-toggle"),m=f.nextElementSibling,g=f.querySelector("button[aria-expanded]");if(m&&(m.classList.contains("brx-dropdown-content")||m.classList.contains("sub-menu"))&&g&&"true"===g.getAttribute("aria-expanded")){var y=m.querySelector("a, button");y&&y.focus()}else c(b)}else c(b);else r&&c(b);break;case v?"ArrowLeft":"ArrowRight":if(n)if(i){var w=o(b,v);w?w.focus():c(b.closest(".brxe-dropdown, .menu-item"))}else c(b);break;case"ArrowUp":if(n)l(b);else if(r){if(!l(b)){var k=b.closest(".brxe-dropdown").querySelector(".brx-submenu-toggle");if(k){var h=s(k,v);h&&h.focus()}}}break;case v?"ArrowRight":"ArrowLeft":if(n)if(i){var x=a(b,v);x?x.focus():l(b.closest(".brxe-dropdown, .menu-item"))}else l(b);else if(r){if(!l(b)){var S=b.closest(".brxe-dropdown").querySelector(".brx-submenu-toggle");if(S){var L=s(S,v);L&&L.focus()}}}break;case"Home":d(r?b.closest(".sub-menu, .brx-dropdown-content"):b.closest(".bricks-nav-menu, .brx-nav-nested-items"));break;case"End":u(r?b.closest(".sub-menu, .brx-dropdown-content"):b.closest(".bricks-nav-menu, .brx-nav-nested-items"))}}function bricksMenuFocusNextElement(e,t){if(!e)return null;var n=e.closest("ul")||e.closest(t);if(!n)return null;var r,i=Array.from(n.children).filter(function(e){return e.querySelector("a, button, .brx-submenu-toggle")}),o=i.findIndex(function(t){return t.contains(e)}),a=i[o+1];if(!a)return null;if(a.querySelector(".brx-submenu-toggle")){var s=a.querySelector(".brx-submenu-toggle"),c=s.querySelector("a"),l=s.querySelector("button");r=c||l}else r=a.querySelector("a")||a.querySelector("button");return r&&r.focus(),r}function bricksMenuFocusPreviousElement(e,t){if(!e)return null;var n=e.closest("ul")||e.closest(t);if(!n)return null;var r,i=Array.from(n.children).filter(function(e){return e.querySelector("a, button, .brx-submenu-toggle")}),o=i.findIndex(function(t){return t.contains(e)}),a=i[o-1];return a?((r=a.querySelector(".brx-submenu-toggle")?a.querySelector(".brx-submenu-toggle button")||a.querySelector(".brx-submenu-toggle a"):a.querySelector("a")||a.querySelector("button")||a.querySelector(".brx-submenu-toggle"))&&r.focus(),r):null}function bricksMenuFocusFirstElement(e){var t=bricksGetFocusables(e);if(t.length>0){var n=t[0];if(n.classList.contains("brx-submenu-toggle")){var r=n.querySelector("a, button");r&&r.focus()}else n.focus()}}function bricksMenuFocusLastElement(e){var t=bricksGetFocusables(e);if(t.length>0)for(var n=t.length-1;n>=0;n--){var r=t[n];if(bricksIsElementVisible(r)){if(!r.classList.contains("brx-submenu-toggle"))return void r.focus();var i=r.querySelector("button")||r.querySelector("a");if(i&&bricksIsElementVisible(i))return void i.focus()}}}function bricksGetNextMenuFocusableInSubmenuToggle(e,t){var n=e.closest(".brx-submenu-toggle"),r=Array.from(n.querySelectorAll("a, button"));return"a"===e.tagName.toLowerCase()?r[1]:null}function bricksGetPreviousMenuFocusableInSubmenuToggle(e,t){var n=e.closest(".brx-submenu-toggle"),r=Array.from(n.querySelectorAll("a, button"));return"button"===e.tagName.toLowerCase()&&r.find(function(e){return"a"===e.tagName.toLowerCase()})||null}function bricksMenuGetLastFocusableInSubmenuToggle(e,t){var n=Array.from(e.querySelectorAll("a, button"));return t?n[0]:n[n.length-1]}function bricksIsElementVisible(e){var t=e.getBoundingClientRect(),n=window.getComputedStyle(e);return t.width>0&&t.height>0&&"hidden"!==n.visibility&&"none"!==n.display}function bricksOffcanvas(){if(bricksIsFrontend){var e=bricksQuerySelectorAll(document,".brxe-offcanvas");if(e.length){var t=e.some(function(e){return e.classList.contains("brx-open")&&"offset"===e.dataset.effect}),n=function(e){var n=e.querySelector(".brx-offcanvas-inner"),r=n?r=1e3*parseFloat(window.getComputedStyle(n).getPropertyValue("transition-duration")):200;if(e.classList.contains("brx-open")){var i,o;if(bricksSetVh(),"offset"===e.dataset.effect&&n){var a=e.getAttribute("data-direction"),s=window.getComputedStyle(n).getPropertyValue("transition");document.body.style.margin="0",t||(document.body.style.transition=s.replace("transform","margin"));var c="rtl"===document.dir||"rtl"===document.documentElement.dir;"top"===a?document.body.style.marginTop="".concat(n.offsetHeight,"px"):"bottom"===a?document.body.style.marginTop="-".concat(n.offsetHeight,"px"):"left"===a?(c?document.body.style.marginRight="-".concat(n.offsetWidth,"px"):document.body.style.marginLeft="".concat(n.offsetWidth,"px"),document.body.style.overflowX="hidden"):"right"===a&&(c?document.body.style.marginRight="".concat(n.offsetWidth,"px"):document.body.style.marginLeft="-".concat(n.offsetWidth,"px"),document.body.style.overflowX="hidden"),t&&setTimeout(function(){document.body.style.transition=s.replace("transform","margin")},0),t=!1}if(e.addEventListener("keydown",function(t){return bricksTrapFocus(t,e)}),e.dataset.noScroll&&document.body.classList.add("no-scroll"),"true"!==(null===(i=e.dataset)||void 0===i?void 0:i.noAutoFocus)&&bricksFocusOnFirstFocusableElement(e),"true"===(null===(o=e.dataset)||void 0===o?void 0:o.scrollToTop)){var l=e.querySelector(".brx-offcanvas-inner");l&&(l.scrollTop=0)}var d=e.querySelectorAll('.brx-offcanvas-inner button.brxe-toggle, .brx-offcanvas-inner [data-brx-toggle-offcanvas="true"]');d.length&&d.forEach(function(t){var n,r=!1,i=(null===(n=t.dataset)||void 0===n?void 0:n.selector)||".brxe-offcanvas";if(i){var o=document.querySelectorAll(i)||[];r=Array.from(o).includes(e)}else r=!0;r&&(t.classList.add("is-active"),t.setAttribute("aria-expanded",!0))})}else{e.classList.add("brx-closing");var u=e.dataset.toggleScriptId,p=document.querySelector('button[data-script-id="'.concat(u,'"], [data-interaction-id="').concat(u,'"][data-brx-toggle-offcanvas]'));p&&(p.setAttribute("aria-expanded",!1),p.classList.remove("is-active"),p.focus()),"offset"===e.dataset.effect&&(document.body.style.marginTop&&(document.body.style.margin="0"),setTimeout(function(){document.body.style.margin=null,document.body.style.overflow=null,document.body.style.transition=null},r)),setTimeout(function(){e.classList.remove("brx-closing"),e.dataset.noScroll&&(document.body.classList.remove("no-scroll"),bricksSubmenuPosition())},r)}},r=new MutationObserver(function(e){e.forEach(function(e){if("attributes"===e.type&&"class"===e.attributeName){var t=e.oldValue||"",r=e.target.classList,i=t.split(" "),o=Array.from(r);if(i.includes("brx-closing")||o.includes("brx-closing"))return;n(e.target)}})});e.forEach(function(e){r.observe(e,{attributes:!0,attributeFilter:["class"],attributeOldValue:!0});var t=e.querySelector(".brx-offcanvas-backdrop");t&&t.addEventListener("click",function(e){bricksOffcanvasClose("backdrop")}),e.classList.contains("brx-open")&&n(e)}),document.addEventListener("keyup",function(e){"Escape"===e.key&&bricksOffcanvasClose("esc")})}}}function bricksOffcanvasClose(e){bricksQuerySelectorAll(document,".brxe-offcanvas.brx-open").forEach(function(t){var n;(((null===(n=t.dataset)||void 0===n?void 0:n.closeOn)||"backdrop-esc").includes(e)||"force"===e)&&t.classList.remove("brx-open");var r=t.querySelectorAll('.brx-offcanvas-inner > button.brxe-toggle, .brx-offcanvas-inner > [data-brx-toggle-offcanvas="true"]');r.length&&r.forEach(function(e){e.classList.remove("is-active"),e.setAttribute("aria-expanded",!1)})})}function bricksToggleDisplay(){var e=bricksQuerySelectorAll(document,".brxe-toggle");e.length&&e.forEach(function(e){!e.closest(".brx-nav-nested-items")||e.parentNode.classList.contains("brx-nav-nested-items")||e.parentNode.classList.contains("brx-toggle-div")||("none"===window.getComputedStyle(e).display?(e.parentNode.style.display="none",bricksNavNestedClose()):e.parentNode.style.display=null)})}function bricksNavMenuMobileToggleDisplay(){bricksQuerySelectorAll(document,".bricks-mobile-menu-toggle").forEach(function(e){e.parentNode.classList.contains("show-mobile-menu")&&("none"===window.getComputedStyle(e).display&&e.click())})}var bricksToggleFn=new BricksFunction({parentNode:document,selector:".brxe-toggle",frontEndOnly:!0,eachElement:function(e){e.addEventListener("click",function(t){t.preventDefault(),bricksUtils.toggleAction(e)})}});function bricksToggle(){bricksIsFrontend&&(bricksToggleDisplay(),bricksToggleFn.run())}function bricksSubmenuToggle(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"toggle",n=!!e.parentNode.classList.contains("brx-submenu-toggle")&&e.parentNode.parentNode;if(n){if(e.closest(".brx-has-multilevel")){var r=n.parentNode.closest(".active");r&&!r.classList.contains("brx-has-megamenu")&&r.classList.remove("active"),setTimeout(function(){var e=n.querySelector("ul")||n.querySelector(".brx-dropdown-content");e&&bricksFocusOnFirstFocusableElement(e)},100)}if("add"===t?(n.classList.add("open"),n.classList.add("active")):"remove"===t?(n.classList.remove("open"),n.classList.remove("active")):n.classList.toggle("open"),n.classList.contains("brxe-dropdown")){var i=n.querySelector(".brx-dropdown-content");if(i&&n.classList.contains("open")){var o=function(e){if(null==e||!e.propertyName||!["color","background-color","border-color","box-shadow","visibility","opacity","filter"].includes(e.propertyName)){var t=n.getBoundingClientRect(),r=i.getBoundingClientRect(),o=parseFloat(window.getComputedStyle(i).borderTopWidth),a=r.top+o-t.bottom;n.style.setProperty("--brx-dropdown-height-before","".concat(a,"px"))}};n.style.getPropertyValue("--brx-dropdown-height-before")||i.addEventListener("transitionend",o),o()}}e.setAttribute("aria-expanded",n.classList.contains("open"))}}var bricksSubmenuListenersFn=new BricksFunction({parentNode:document,selector:".bricks-nav-menu .menu-item-has-children, .brxe-dropdown",eachElement:function(e){e.closest("[data-static]")||e.closest(".brx-has-multilevel")||e.classList.contains("active")||(e.addEventListener("mouseenter",function(t){if(!e.closest(".show-mobile-menu")&&!e.closest(".brxe-nav-nested.brx-open")&&"click"!==e.getAttribute("data-toggle")){var n=t.target.querySelector('[aria-expanded="false"]');n&&(n.closest(".brxe-dropdown.open")||n.closest(".bricks-menu-item.open")||bricksUtils.closeAllSubmenus(n),bricksSubmenuToggle(n))}}),e.addEventListener("mouseleave",function(t){if(!e.closest(".show-mobile-menu")&&!e.closest(".brxe-nav-nested.brx-open")&&"click"!==e.getAttribute("data-toggle")){var n=t.target.querySelector('[aria-expanded="true"]');if(n){var r=n.closest(".menu-item");if(r||(r=n.closest(".brxe-dropdown")),r&&r.classList.contains("active"))return;bricksSubmenuToggle(n)}}}))}});function bricksSubmenuListeners(){function e(e,t,n){var r="hover";if(e.hasAttribute("data-toggle"))r=e.getAttribute("data-toggle");else{var i=e.closest("[data-toggle]");i&&(r=i.getAttribute("data-toggle"))}e.closest(".brxe-nav-menu.show-mobile-menu")&&(r="click"),e.closest(".brxe-nav-nested.brx-open")&&(r="click");var o="hover"===r?t.target.closest("[aria-expanded]"):e.querySelector(n?".brx-submenu-toggle button[aria-expanded]":"button[aria-expanded]");if(0===t.detail||"click"===r||"both"===r||(o=null),o){bricksSubmenuToggle(o);var a=n?e:e.parentNode;a.classList.toggle("active"),setTimeout(function(){a.classList.contains("active")&&a.classList.add("open"),o.setAttribute("aria-expanded",a.classList.contains("open"))},0)}}bricksSubmenuListenersFn.run(),document.addEventListener("keyup",function(e){"Escape"===e.key?bricksUtils.closeAllSubmenus(e.target):"Tab"===e.key&&setTimeout(function(){bricksQuerySelectorAll(document,'[aria-expanded="true"]').forEach(function(e){var t=e.closest(".menu-item");t||(t=e.closest(".brxe-dropdown")),(t&&!t.contains(document.activeElement)||"BODY"===document.activeElement.tagName)&&bricksSubmenuToggle(e,"remove")})},0)}),document.addEventListener("click",function(t){var n=t.target,r=null;if(n&&"A"!==n.nodeName&&(n=n.closest("a[href]")),n&&(r=n.getAttribute("href")),r&&r.includes("#"))if("#"===r||"/#"===r)t.preventDefault();else{var i=r.split("#")[1];if(t.target.closest(".brxe-offcanvas")&&bricksOffcanvasClose("force"),t.target.closest(".brxe-nav-nested.brx-open")){bricksNavNestedClose();var o=document.getElementById(i);o&&setTimeout(function(){o.scrollIntoView()},200)}var a=document.getElementById(i);if(a){var s=a.classList.contains("woocommerce-Tabs-panel"),c=a.firstChild&&a.firstChild.classList&&a.firstChild.classList.contains("accordion-title-wrapper")?a.firstChild:null;if(c&&!s)return void c.click();var l=a.closest(".tab-title");l&&!s&&l.click();var d=t.target.closest(".brx-popup");d&&!d.contains(a)&&bricksClosePopup(d)}}var u=t.target.closest(".brx-submenu-toggle"),p=t.target.closest(".brxe-dropdown"),b=t.target.closest(".brx-dropdown-content");!p||b&&b.parentNode===p?u&&e(u,t,!1):e(p,t,!0),bricksQuerySelectorAll(document,'.brx-submenu-toggle > button[aria-expanded="true"]').forEach(function(e){var n=e.closest("li");n||(n=e.closest(".brxe-dropdown")),n&&!n.contains(t.target)&&(bricksSubmenuToggle(e),n.classList.remove("active"))})}),bricksQuerySelectorAll(document,".brx-submenu-toggle").forEach(function(e){var t=e.parentNode,n=t.querySelector(".brx-megamenu")||t.querySelector(".brx-dropdown-content")||t.querySelector("ul");n&&n.querySelector('[aria-current="page"]')&&e.classList.add("aria-current")})}var bricksSubmenuPositionFn=new BricksFunction({parentNode:document,selector:".brx-submenu-toggle",forceReinit:!0,eachElement:function(e){var t=e.parentNode,n=t.querySelector(".brx-megamenu")||t.querySelector(".brx-dropdown-content")||t.querySelector("ul");if(n&&(n.classList.add("brx-submenu-positioned"),!t.hasAttribute("data-static"))){var r=document.body.clientWidth;if(t.classList.contains("brx-has-megamenu")){var i=t.dataset.megaMenu,o=t.dataset.megaMenuVertical,a=document.body;if(i){var s=document.querySelector(i);s&&(a=s)}var c=t.getBoundingClientRect(),l=a.getBoundingClientRect();if(n.style.left="-".concat(c.left-l.left,"px"),n.style.minWidth="".concat(l.width,"px"),o){var d=document.querySelector(o);if(d){var u=d.getBoundingClientRect();n.style.top="".concat(c.height+u.bottom-c.bottom,"px")}}bricksIsFrontend&&document.dispatchEvent(new CustomEvent("bricks/megamenu/repositioned",{detail:{menuItem:t,submenu:n}}))}else{n.classList.contains("brx-multilevel-overflow-right")&&n.classList.remove("brx-multilevel-overflow-right"),n.classList.contains("brx-submenu-overflow-right")&&n.classList.remove("brx-submenu-overflow-right"),n.classList.contains("brx-sub-submenu-overflow-right")&&n.classList.remove("brx-sub-submenu-overflow-right");var p=!t.parentNode.closest(".menu-item")&&!t.parentNode.closest(".brxe-dropdown"),b=n.getBoundingClientRect(),v=b.width,f=b.right,m=Math.ceil(b.left);if(v>r)n.style.left="-".concat(m,"px"),n.style.minWidth="".concat(r,"px");else if(f>r){n.closest(".brx-has-multilevel")?n.classList.add("brx-multilevel-overflow-right"):p?n.classList.add("brx-submenu-overflow-right"):n.classList.add("brx-sub-submenu-overflow-right")}else m<0&&(n.style.left=p?"0":"100%",n.style.right="auto")}}}});function bricksSubmenuPosition(){setTimeout(function(){bricksSubmenuPositionFn.run()},arguments.length>0&&void 0!==arguments[0]?arguments[0]:0)}function bricksSubmenuWindowResizeHandler(){var e,t,n,r=function(){var r=window.innerWidth,i=window.innerHeight,o=document.body.clientWidth;r===e&&o===n||(clearTimeout(t),bricksQuerySelectorAll(document,".brx-submenu-toggle").forEach(function(e){var t=e.parentNode,n=t.querySelector(".brx-megamenu")||t.querySelector(".brx-dropdown-content")||t.querySelector("ul");n&&n.classList.remove("brx-submenu-positioned")}),t=setTimeout(bricksSubmenuPosition,250),e=r,n=o)},i=function(){var t=window.innerWidth,o=window.innerHeight;requestAnimationFrame(function(){t===window.innerWidth&&o===window.innerHeight?(e=t,n=document.body.clientWidth,window.addEventListener("resize",r)):i()})};i(),window.bricksData&&!window.bricksData.bodyResizeObserver&&(window.bricksData.bodyResizeObserver=new ResizeObserver(function(e){var t,i=_createForOfIteratorHelper(e);try{for(i.s();!(t=i.n()).done;){t.value.contentRect.width!==n&&r()}}catch(e){i.e(e)}finally{i.f()}}),window.bricksData.bodyResizeObserver.observe(document.body))}function bricksMultilevelMenu(){bricksQuerySelectorAll(document,".brxe-nav-nested.multilevel").forEach(function(e){var t=e.getAttribute("data-back-text");e.querySelectorAll(".brxe-dropdown").forEach(function(e){e.classList.add("brx-has-multilevel"),e.setAttribute("data-toggle","click"),e.setAttribute("data-back-text",t)})}),bricksQuerySelectorAll(document,".brx-has-multilevel").forEach(function(e){var t=e.getAttribute("data-back-text")||"Back";bricksQuerySelectorAll(e,"ul").forEach(function(e,n){if(0!==n){var r=document.createElement("a");r.classList.add("brx-multilevel-back"),r.setAttribute("href","#"),r.innerText=t;var i=document.createElement("li");i.classList.add("menu-item"),i.appendChild(r),e.insertBefore(i,e.firstChild),r.addEventListener("click",function(e){e.preventDefault();var t=e.target.closest(".active");if(t){t.classList.remove("open"),t.classList.remove("active");var n=t.querySelector(".brx-submenu-toggle > button");n&&n.setAttribute("aria-expanded",!1);var r=t.parentNode.closest(".open");if(r){r.classList.add("active");var i=r.querySelector("ul");i&&bricksFocusOnFirstFocusableElement(i)}}})}})})}function bricksNavMenuMobile(){var e=bricksQuerySelectorAll(document,".bricks-mobile-menu-toggle");if(e.length){var t=new MutationObserver(function(e){bricksSetVh(),e.forEach(function(e){e.target.classList.contains("show-mobile-menu")?document.body.classList.add("no-scroll"):document.body.classList.remove("no-scroll")})});e.forEach(function(e){var n=e.closest(".brxe-nav-menu");t.observe(n,{attributes:!0,attributeFilter:["class"]})});var n=null;document.addEventListener("click",function(e){var t=e.target.closest(".bricks-mobile-menu-toggle");if(t){var r=t.closest(".brxe-nav-menu");r.classList.toggle("show-mobile-menu");var i=r.classList.contains("show-mobile-menu"),o=i?window.bricksData.i18n.closeMobileMenu:window.bricksData.i18n.openMobileMenu;t.setAttribute("aria-expanded",i),t.setAttribute("aria-label",o),i?(n=document.activeElement,setTimeout(function(){var e=r.querySelector(".bricks-mobile-menu-wrapper");bricksFocusOnFirstFocusableElement(e),e.addEventListener("keydown",function(t){return bricksTrapFocus(t,e)})},100)):n&&n.focus()}}),document.addEventListener("click",function(e){var t=e.target.closest(".brxe-nav-menu");if(t){var n=t.querySelector(".bricks-mobile-menu-toggle");if(e.target.classList.contains("bricks-mobile-menu-overlay"))t.classList.remove("show-mobile-menu"),t.querySelector(".bricks-mobile-menu-toggle").setAttribute("aria-expanded",!1),n.setAttribute("aria-expanded",!1),n.setAttribute("aria-label",window.bricksData.i18n.openMobileMenu);else if(e.target.closest(".bricks-mobile-menu-wrapper")){var r="A"===e.target.tagName?e.target.getAttribute("href"):"";r.length>1&&r.includes("#")&&(t.classList.remove("show-mobile-menu"),n.setAttribute("aria-expanded",!1),n.setAttribute("aria-label",window.bricksData.i18n.openMobileMenu))}}}),document.addEventListener("keyup",function(e){if("Escape"===e.key){var t=document.querySelector(".brxe-nav-menu.show-mobile-menu");if(t){t.classList.remove("show-mobile-menu");var n=t.querySelector(".bricks-mobile-menu-toggle");n&&(n.setAttribute("aria-expanded",!1),n.setAttribute("aria-label",window.bricksData.i18n.openMobileMenu),setTimeout(function(){n.focus()},10))}}})}}var bricksBackToTopFn=new BricksFunction({parentNode:document,selector:".brxe-back-to-top",eachElement:function(e){e.addEventListener("click",function(t){t.preventDefault(),window.scrollTo({top:0,behavior:e.hasAttribute("data-smooth-scroll")?"smooth":"auto"})});var t=e.dataset.visibleAfter||0,n=e.classList.contains("up");if(t||n){var r=0;window.addEventListener("scroll",function(){var i=document.documentElement.scrollTop,o=!0;n&&(o=!(i>r),r=i),(o=!!(window.scrollY>t&&o))?e.classList.add("visible"):e.classList.remove("visible")})}}});function bricksBackToTop(){bricksBackToTopFn.run()}function bricksGetFocusables(e){var t=e.querySelectorAll('a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])');return Array.prototype.filter.call(t,function(e){return!e.hasAttribute("inert")&&!e.closest("[inert]")&&"none"!==window.getComputedStyle(e).display})}function bricksGetVisibleFocusables(e){return bricksGetFocusables(e).filter(function(e){return e.offsetWidth>0||e.offsetHeight>0})}var bricksIsFrontend,bricksPauseMediaFn=new BricksFunction({parentNode:document,selector:'video, audio, iframe[src*="youtube"], iframe[src*="vimeo"]',subscribeEvents:["bricks/popup/close"],forceReinit:!0,eachElement:function(e){if("VIDEO"!==e.tagName&&"AUDIO"!==e.tagName||!e.pause||"function"!=typeof e.pause){if("IFRAME"===e.tagName){var t=e.getAttribute("src"),n=t.includes("youtube"),r=n?{event:"command",func:"pauseVideo",args:""}:{method:"pause"};if(t.includes("vimeo")||n)return void e.contentWindow.postMessage(JSON.stringify(r),"*")}}else e.pause()},listenerHandler:function(e){var t;if(null!=e&&e.type&&"bricks/popup/close"===e.type){var n=null==e||null===(t=e.detail)||void 0===t?void 0:t.popupElement;n&&bricksPauseMediaFn.run({parentNode:n})}}}),bricksAnchorLinksFn=new BricksFunction({parentNode:document,selector:'a[data-brx-anchor][href*="#"]',frontEndOnly:!0,eachElement:function(e){var t=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=e.closest(".menu-item")||!1;t?(e.setAttribute("aria-current","page"),n&&e.closest(".menu-item").classList.add("current-menu-item")):(e.removeAttribute("aria-current"),n&&e.closest(".menu-item").classList.remove("current-menu-item"))},n=window.location.hash||!1;if(n&&n.length>1){var r=e.getAttribute("href").split("#")[1]||!1;if(r&&r===n.substring(1)){var i=e.closest(".bricks-nav-menu, .brxe-nav-nested")||!1;if(i)i.querySelectorAll(".menu-item").forEach(function(e){var t=e.querySelectorAll("a:not([data-brx-anchor])");t.length>0&&(e.classList.remove("current-menu-item"),t.forEach(function(e){e.removeAttribute("aria-current")}))});t(e)}}e.addEventListener("click",function(n){var r=e.closest(".bricks-nav-menu, .brxe-nav-nested")||!1;r&&r.querySelectorAll(".menu-item").forEach(function(e){e.classList.remove("current-menu-item"),e.querySelectorAll('a[aria-current="page"]').forEach(function(e){e.removeAttribute("aria-current")})});t(e)})}});function bricksAnchorLinks(){bricksAnchorLinksFn.run()}function bricksGetQueryResult(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise(function(r,i){if(e)if("function"==typeof window.bricksUtils.getFiltersForQuery){var o=window.bricksData.queryLoopInstances[e]||!1;if(o){n||bricksUtils.maybeAbortXhr(e);var a=window.bricksData.restApiUrl.concat("query_result"),s=window.bricksUtils.getFiltersForQuery(e,"filterId"),c=window.bricksUtils.getSelectedFiltersForQuery(e),l=window.bricksUtils.getDynamicTagsForParse(e),d="[]"===(null==o?void 0:o.originalQueryVars)?null==o?void 0:o.queryVars:null==o?void 0:o.originalQueryVars,u={postId:window.bricksData.postId,queryElementId:e,originalQueryVars:d,pageFilters:window.bricksData.pageFilters||!1,filters:s,selectedFilters:c,afTags:l,nonce:window.bricksData.nonce,baseUrl:window.bricksData.baseUrl,lang:window.bricksData.language||!1,mainQueryId:window.bricksData.mainQueryId||!1};"wpml"!==window.bricksData.multilangPlugin||!window.location.search.includes("lang=")&&3==window.bricksData.wpmlUrlFormat||(a=a.concat("?lang="+window.bricksData.language)),window.bricksData.queryLoopInstances[e].isLoading=1,n||window.bricksData.queryLoopInstances[e].xhrAborted||document.dispatchEvent(new CustomEvent("bricks/ajax/start",{detail:{queryId:e,isPopState:t}}));var p=new XMLHttpRequest;window.bricksData.queryLoopInstances[e].xhr=p,p.open("POST",a,!0),p.setRequestHeader("Content-Type","application/json; charset=UTF-8"),p.setRequestHeader("X-WP-Nonce",window.bricksData.wpRestNonce),p.onreadystatechange=function(){if(p.readyState===XMLHttpRequest.DONE){var t;window.bricksData.queryLoopInstances[e].xhr===p&&(window.bricksData.queryLoopInstances[e].xhr=null,window.bricksData.queryLoopInstances[e].xhrAborted=!1);var o,a=p.status;try{o=JSON.parse(p.response)}catch(e){return void i("Invalid response from server")}if(0===a||a>=200&&a<400){var s;window.bricksData.queryLoopInstances[e].isLoading=0;var c=(null===(s=o)||void 0===s?void 0:s.error)||!1;c?(console.error("error: bricksGetQueryResult",c),i(c)):r(o),document.dispatchEvent(new CustomEvent("bricks/ajax/end",{detail:{queryId:e}})),document.dispatchEvent(new CustomEvent("bricks/ajax/query_result/completed",{detail:{queryId:e}}))}else"rest_cookie_invalid_nonce"===(null===(t=o)||void 0===t?void 0:t.code)?n?i("Nonce verification failed after refresh"):bricksRegenerateNonceAndRetryQuery(e).then(r).catch(i):i("Request failed with status ".concat(a))}},p.send(JSON.stringify(u))}else i("Query instance not found")}else i("Query filters JS not loaded");else i("No queryId provided")})}function bricksRegenerateNonceAndRetryQuery(e){return new Promise(function(t,n){var r=new XMLHttpRequest;r.open("POST",window.bricksData.ajaxUrl,!0),r.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),r.onreadystatechange=function(){if(r.readyState===XMLHttpRequest.DONE)if(r.status>=200&&r.status<400){var i;try{i=JSON.parse(r.responseText)}catch(e){return void n("Invalid response from server when regenerating nonce")}if(i.success&&i.data){window.bricksData.nonce=i.data.bricks_nonce,window.bricksData.wpRestNonce=i.data.rest_nonce;bricksGetQueryResult(e,!1,!0).then(t).catch(n)}else n("Failed to regenerate nonces: Invalid response structure")}else n("Failed to regenerate nonce")},r.send("action=bricks_regenerate_query_nonce")})}function bricksDisplayQueryResult(e,t){var n,r=(null==t?void 0:t.html)||!1,i=(null==t?void 0:t.styles)||!1,o=(null==t?void 0:t.popups)||!1,a=(null==t?void 0:t.updated_query)||!1,s=(null==t?void 0:t.updated_filters)||!1,c=(null==t?void 0:t.parsed_af_tags)||!1,l=window.bricksData.queryLoopInstances[e]||!1,d=(null==l?void 0:l.resultsContainer)||!1;if(l&&d){var u=(null==l?void 0:l.componentId)||!1,p=u||e,b=d.querySelector(".bricks-gutter-sizer"),v=d.querySelector(".bricks-isotope-sizer"),f=d.querySelectorAll(".brxe-".concat(e,", .bricks-posts-nothing-found")),m=document.createNodeIterator(d,NodeFilter.SHOW_COMMENT,{acceptNode:function(t){return t.nodeValue==="brx-loop-start-".concat(e)}}).nextNode(),g=f.length>0||m;if(g&&d.querySelectorAll(".brxe-".concat(p,", .bricks-posts-nothing-found")).forEach(function(e){return e.remove()}),r)if(g){if(m){var y=r.match(/<\s*([a-z0-9]+)([^>]+)?>/i),w=null;(w=!y||"td"!==y[1]&&"tr"!==y[1]?document.createElement("div"):document.createElement("tbody")).innerHTML=r;var k=Array.from(w.childNodes);k.reverse(),k.forEach(function(e){var t,n;m.nextSibling?null===(t=m.parentNode)||void 0===t||t.insertBefore(e,m.nextSibling):null===(n=m.parentNode)||void 0===n||n.appendChild(e)}),w.remove()}}else d.insertAdjacentHTML("beforeend",r);if(b&&d.appendChild(b),v&&d.appendChild(v),document.querySelectorAll('.brx-popup[data-popup-loop="'.concat(e,'"]')).forEach(function(e){return e.remove()}),o&&document.body.insertAdjacentHTML("beforeend",o),document.dispatchEvent(new CustomEvent("bricks/ajax/nodes_added",{detail:{queryId:e}})),i){var h=document.querySelector("#brx-query-styles-".concat(e));h||((h=document.createElement("style")).id="brx-query-styles-".concat(e),document.body.appendChild(h)),h.innerHTML=i}if(a&&bricksUtils.updateQueryResultStats(e,"query",a),c&&window.bricksUtils.updateParsedDynamicTags(e,c),void 0!==(null==a||null===(n=a.query_vars)||void 0===n?void 0:n.paged)&&(window.bricksData.queryLoopInstances[e].page=parseInt(a.query_vars.paged)),void 0!==(null==a?void 0:a.max_num_pages)&&(window.bricksData.queryLoopInstances[e].maxPages=parseInt(a.max_num_pages)),void 0!==(null==a?void 0:a.start)&&(window.bricksData.queryLoopInstances[e].start=parseInt(a.start)),void 0!==(null==a?void 0:a.end)&&(window.bricksData.queryLoopInstances[e].end=parseInt(a.end)),s)for(var x in s){var S=s[x],L=window.bricksData.filterInstances[x]||!1;if(L&&"search"!==L.filterType){var E=document.createElement("div");E.innerHTML=S;var I=E.childNodes[0];L.filterElement.replaceWith(I),L.filterElement=I,E.remove()}}bricksUtils.hideOrShowLoadMoreButtons(e),document.dispatchEvent(new CustomEvent("bricks/ajax/query_result/displayed",{detail:{queryId:e}})),l.infiniteScroll&&setTimeout(function(){var t,n=Array.from(null===(t=l.resultsContainer)||void 0===t?void 0:t.querySelectorAll(".brxe-".concat(p,":not(.brx-popup)"))).pop();n&&(n.dataset.queryElementId=e,BricksIsInViewport(n)?bricksQueryLoadPage(n):new BricksIntersect({element:n,callback:function(e){return bricksQueryLoadPage(e)},once:!0,rootMargin:l.observerMargin}))},250)}}function bricksGetYouTubeVideoLinkData(e){if(!e)return{url:"",id:null};var t=e.match(/(?:youtube(?:-nocookie)?\.com\/(?:[^\/]+\/.+\/|(?:v|e(?:mbed)?)\/|shorts\/|live\/|.*[?&]v=)|youtu\.be\/)([^"&?\/ ]{11})/i);if(t&&t[1]){var n=t[1],r="https://www.youtube.com/embed/".concat(n);try{var i=new URL(e),o=new URLSearchParams(i.search);o.delete("v");var a=o.toString();a&&(r+="?"+a)}catch(e){console.warn("Failed to parse URL parameters:",e)}return{url:r,id:n}}return{url:e,id:null}}function bricksSetVh(){var e=.01*window.innerHeight;document.documentElement.style.setProperty("--bricks-vh","".concat(e,"px"))}function bricksRunAllFunctions(){window.bricksFunctions&&window.bricksFunctions.forEach(function(e){e.run&&"function"==typeof e.run&&e.run()})}var bricksTimeouts={};document.addEventListener("DOMContentLiteSpeedLoaded",function(e){bricksIsFrontend=document.body.classList.contains("bricks-is-frontend"),bricksBlockEditorIntegration(),bricksNavMenu(),bricksMultilevelMenu(),bricksNavMenuMobile(),bricksStickyHeader(),bricksOnePageNavigation(),bricksSkipLinks(),bricksFacebookSDK(),bricksSearchToggle(),bricksPopups(),bricksSwiper(),bricksSplide(),bricksPhotoswipe(),bricksTinyMCE(),bricksPrettify(),bricksAccordion(),bricksAnimatedTyping(),bricksAudio(),bricksCountdown(),bricksCounter(),bricksTableOfContents(),bricksPricingTables(),bricksVideo(),bricksLazyLoad(),bricksAnimation(),bricksPieChart(),bricksPostReadingProgressBar(),bricksProgressBar(),bricksForm(),bricksInitQueryLoopInstances(),bricksQueryPagination(),bricksInteractions(),bricksAlertDismiss(),bricksTabs(),bricksVideoOverlayClickDetector(),bricksBackgroundVideoInit(),bricksPostReadingTime(),bricksBackToTop(),bricksMapLeaflet(),bricksNavNested(),bricksOffcanvas(),bricksToggle(),bricksSubmenuListeners(),bricksSubmenuPosition(250),bricksAjaxLoader(),bricksAnchorLinks(),bricksIsotope(),bricksIsotopeListeners(),window.addEventListener("load",bricksSubmenuWindowResizeHandler),window.addEventListener("resize",function(){Object.keys(bricksTimeouts).forEach(function(e){clearTimeout(bricksTimeouts[e])}),bricksIsFrontend?bricksTimeouts.bricksVh=setTimeout(bricksSetVh,250):(bricksTimeouts.bricksSwiper=setTimeout(bricksSwiper,250),bricksTimeouts.bricksSplide=setTimeout(bricksSplide,250)),bricksTimeouts.tabsAdjustLayoutOnMobile=setTimeout(bricksTabsAccordionLayoutOnMobile,250),bricksTimeouts.bricksToggleDisplay=setTimeout(bricksToggleDisplay,100),bricksTimeouts.bricksNavMenuMobileToggleDisplay=setTimeout(bricksNavMenuMobileToggleDisplay,100)}),setTimeout(function(){var e;(Array.isArray(null===(e=window.bricksData)||void 0===e?void 0:e.interactions)?window.bricksData.interactions:[]).find(function(e){return"scroll"===(null==e?void 0:e.trigger)})&&document.addEventListener("scroll",bricksScrollInteractions)},100)});
;/*!
* PhotoSwipe 5.4.4 - https://photoswipe.com
* (c) 2024 Dmytro Semenov
*/
!function(t,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i():"function"==typeof define&&define.amd?define(i):(t="undefined"!=typeof globalThis?globalThis:t||self).PhotoSwipe5=i()}(this,(function(){"use strict";function t(t,i,s){const h=document.createElement(i);return t&&(h.className=t),s&&s.appendChild(h),h}function i(t,i){return t.x=i.x,t.y=i.y,void 0!==i.id&&(t.id=i.id),t}function s(t){t.x=Math.round(t.x),t.y=Math.round(t.y)}function h(t,i){const s=Math.abs(t.x-i.x),h=Math.abs(t.y-i.y);return Math.sqrt(s*s+h*h)}function e(t,i){return t.x===i.x&&t.y===i.y}function n(t,i,s){return Math.min(Math.max(t,i),s)}function o(t,i,s){let h=`translate3d(${t}px,${i||0}px,0)`;return void 0!==s&&(h+=` scale3d(${s},${s},1)`),h}function r(t,i,s,h){t.style.transform=o(i,s,h)}function a(t,i,s,h){t.style.transition=i?`${i} ${s}ms ${h||"cubic-bezier(.4,0,.22,1)"}`:"none"}function l(t,i,s){t.style.width="number"==typeof i?`${i}px`:i,t.style.height="number"==typeof s?`${s}px`:s}const c="idle",d="loading",u="loaded",p="error";function m(){return!(!navigator.vendor||!navigator.vendor.match(/apple/i))}let v=!1;try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>{v=!0}}))}catch(t){}class f{constructor(){this.t=[]}add(t,i,s,h){this.i(t,i,s,h)}remove(t,i,s,h){this.i(t,i,s,h,!0)}removeAll(){this.t.forEach((t=>{this.i(t.target,t.type,t.listener,t.passive,!0,!0)})),this.t=[]}i(t,i,s,h,e,n){if(!t)return;const o=e?"removeEventListener":"addEventListener";i.split(" ").forEach((i=>{if(i){n||(e?this.t=this.t.filter((h=>h.type!==i||h.listener!==s||h.target!==t)):this.t.push({target:t,type:i,listener:s,passive:h}));const r=!!v&&{passive:h||!1};t[o](i,s,r)}}))}}function w(t,i){if(t.getViewportSizeFn){const s=t.getViewportSizeFn(t,i);if(s)return s}return{x:document.documentElement.clientWidth,y:window.innerHeight}}function g(t,i,s,h,e){let n=0;if(i.paddingFn)n=i.paddingFn(s,h,e)[t];else if(i.padding)n=i.padding[t];else{const s="padding"+t[0].toUpperCase()+t.slice(1);i[s]&&(n=i[s])}return Number(n)||0}function y(t,i,s,h){return{x:i.x-g("left",t,i,s,h)-g("right",t,i,s,h),y:i.y-g("top",t,i,s,h)-g("bottom",t,i,s,h)}}class _{constructor(t){this.slide=t,this.currZoomLevel=1,this.center={x:0,y:0},this.max={x:0,y:0},this.min={x:0,y:0}}update(t){this.currZoomLevel=t,this.slide.width?(this.o("x"),this.o("y"),this.slide.pswp.dispatch("calcBounds",{slide:this.slide})):this.reset()}o(t){const{pswp:i}=this.slide,s=this.slide["x"===t?"width":"height"]*this.currZoomLevel,h=g("x"===t?"left":"top",i.options,i.viewportSize,this.slide.data,this.slide.index),e=this.slide.panAreaSize[t];this.center[t]=Math.round((e-s)/2)+h,this.max[t]=s>e?Math.round(e-s)+h:this.center[t],this.min[t]=s>e?h:this.center[t]}reset(){this.center.x=0,this.center.y=0,this.max.x=0,this.max.y=0,this.min.x=0,this.min.y=0}correctPan(t,i){return n(i,this.max[t],this.min[t])}}class x{constructor(t,i,s,h){this.pswp=h,this.options=t,this.itemData=i,this.index=s,this.panAreaSize=null,this.elementSize=null,this.fit=1,this.fill=1,this.vFill=1,this.initial=1,this.secondary=1,this.max=1,this.min=1}update(t,i,s){const h={x:t,y:i};this.elementSize=h,this.panAreaSize=s;const e=s.x/h.x,n=s.y/h.y;this.fit=Math.min(1,e<n?e:n),this.fill=Math.min(1,e>n?e:n),this.vFill=Math.min(1,n),this.initial=this.l(),this.secondary=this.u(),this.max=Math.max(this.initial,this.secondary,this.p()),this.min=Math.min(this.fit,this.initial,this.secondary),this.pswp&&this.pswp.dispatch("zoomLevelsUpdate",{zoomLevels:this,slideData:this.itemData})}m(t){const i=t+"ZoomLevel",s=this.options[i];if(s)return"function"==typeof s?s(this):"fill"===s?this.fill:"fit"===s?this.fit:Number(s)}u(){let t=this.m("secondary");return t||(t=Math.min(1,3*this.fit),this.elementSize&&t*this.elementSize.x>4e3&&(t=4e3/this.elementSize.x),t)}l(){return this.m("initial")||this.fit}p(){return this.m("max")||Math.max(1,4*this.fit)}}class b{constructor(i,s,h){this.data=i,this.index=s,this.pswp=h,this.isActive=s===h.currIndex,this.currentResolution=0,this.panAreaSize={x:0,y:0},this.pan={x:0,y:0},this.isFirstSlide=this.isActive&&!h.opener.isOpen,this.zoomLevels=new x(h.options,i,s,h),this.pswp.dispatch("gettingData",{slide:this,data:this.data,index:s}),this.content=this.pswp.contentLoader.getContentBySlide(this),this.container=t("pswp__zoom-wrap","div"),this.holderElement=null,this.currZoomLevel=1,this.width=this.content.width,this.height=this.content.height,this.heavyAppended=!1,this.bounds=new _(this),this.prevDisplayedWidth=-1,this.prevDisplayedHeight=-1,this.pswp.dispatch("slideInit",{slide:this})}setIsActive(t){t&&!this.isActive?this.activate():!t&&this.isActive&&this.deactivate()}append(t){this.holderElement=t,this.container.style.transformOrigin="0 0",this.data&&(this.calculateSize(),this.load(),this.updateContentSize(),this.appendHeavy(),this.holderElement.appendChild(this.container),this.zoomAndPanToInitial(),this.pswp.dispatch("firstZoomPan",{slide:this}),this.applyCurrentZoomPan(),this.pswp.dispatch("afterSetContent",{slide:this}),this.isActive&&this.activate())}load(){this.content.load(!1),this.pswp.dispatch("slideLoad",{slide:this})}appendHeavy(){const{pswp:t}=this;!this.heavyAppended&&t.opener.isOpen&&!t.mainScroll.isShifted()&&(this.isActive,1)&&(this.pswp.dispatch("appendHeavy",{slide:this}).defaultPrevented||(this.heavyAppended=!0,this.content.append(),this.pswp.dispatch("appendHeavyContent",{slide:this})))}activate(){this.isActive=!0,this.appendHeavy(),this.content.activate(),this.pswp.dispatch("slideActivate",{slide:this})}deactivate(){this.isActive=!1,this.content.deactivate(),this.currZoomLevel!==this.zoomLevels.initial&&this.calculateSize(),this.currentResolution=0,this.zoomAndPanToInitial(),this.applyCurrentZoomPan(),this.updateContentSize(),this.pswp.dispatch("slideDeactivate",{slide:this})}destroy(){this.content.hasSlide=!1,this.content.remove(),this.container.remove(),this.pswp.dispatch("slideDestroy",{slide:this})}resize(){this.currZoomLevel!==this.zoomLevels.initial&&this.isActive?(this.calculateSize(),this.bounds.update(this.currZoomLevel),this.panTo(this.pan.x,this.pan.y)):(this.calculateSize(),this.currentResolution=0,this.zoomAndPanToInitial(),this.applyCurrentZoomPan(),this.updateContentSize())}updateContentSize(t){const i=this.currentResolution||this.zoomLevels.initial;if(!i)return;const s=Math.round(this.width*i)||this.pswp.viewportSize.x,h=Math.round(this.height*i)||this.pswp.viewportSize.y;(this.sizeChanged(s,h)||t)&&this.content.setDisplayedSize(s,h)}sizeChanged(t,i){return(t!==this.prevDisplayedWidth||i!==this.prevDisplayedHeight)&&(this.prevDisplayedWidth=t,this.prevDisplayedHeight=i,!0)}getPlaceholderElement(){var t;return null===(t=this.content.placeholder)||void 0===t?void 0:t.element}zoomTo(t,i,h,e){const{pswp:o}=this;if(!this.isZoomable()||o.mainScroll.isShifted())return;o.dispatch("beforeZoomTo",{destZoomLevel:t,centerPoint:i,transitionDuration:h}),o.animations.stopAllPan();const r=this.currZoomLevel;e||(t=n(t,this.zoomLevels.min,this.zoomLevels.max)),this.setZoomLevel(t),this.pan.x=this.calculateZoomToPanOffset("x",i,r),this.pan.y=this.calculateZoomToPanOffset("y",i,r),s(this.pan);const a=()=>{this.v(t),this.applyCurrentZoomPan()};h?o.animations.startTransition({isPan:!0,name:"zoomTo",target:this.container,transform:this.getCurrentTransform(),onComplete:a,duration:h,easing:o.options.easing}):a()}toggleZoom(t){this.zoomTo(this.currZoomLevel===this.zoomLevels.initial?this.zoomLevels.secondary:this.zoomLevels.initial,t,this.pswp.options.zoomAnimationDuration)}setZoomLevel(t){this.currZoomLevel=t,this.bounds.update(this.currZoomLevel)}calculateZoomToPanOffset(t,i,s){if(0===this.bounds.max[t]-this.bounds.min[t])return this.bounds.center[t];i||(i=this.pswp.getViewportCenterPoint()),s||(s=this.zoomLevels.initial);const h=this.currZoomLevel/s;return this.bounds.correctPan(t,(this.pan[t]-i[t])*h+i[t])}panTo(t,i){this.pan.x=this.bounds.correctPan("x",t),this.pan.y=this.bounds.correctPan("y",i),this.applyCurrentZoomPan()}isPannable(){return Boolean(this.width)&&this.currZoomLevel>this.zoomLevels.fit}isZoomable(){return Boolean(this.width)&&this.content.isZoomable()}applyCurrentZoomPan(){this.g(this.pan.x,this.pan.y,this.currZoomLevel),this===this.pswp.currSlide&&this.pswp.dispatch("zoomPanUpdate",{slide:this})}zoomAndPanToInitial(){this.currZoomLevel=this.zoomLevels.initial,this.bounds.update(this.currZoomLevel),i(this.pan,this.bounds.center),this.pswp.dispatch("initialZoomPan",{slide:this})}g(t,i,s){s/=this.currentResolution||this.zoomLevels.initial,r(this.container,t,i,s)}calculateSize(){const{pswp:t}=this;i(this.panAreaSize,y(t.options,t.viewportSize,this.data,this.index)),this.zoomLevels.update(this.width,this.height,this.panAreaSize),t.dispatch("calcSlideSize",{slide:this})}getCurrentTransform(){const t=this.currZoomLevel/(this.currentResolution||this.zoomLevels.initial);return o(this.pan.x,this.pan.y,t)}v(t){t!==this.currentResolution&&(this.currentResolution=t,this.updateContentSize(),this.pswp.dispatch("resolutionChanged"))}}class S{constructor(t){this.gestures=t,this.pswp=t.pswp,this.startPan={x:0,y:0}}start(){this.pswp.currSlide&&i(this.startPan,this.pswp.currSlide.pan),this.pswp.animations.stopAll()}change(){const{p1:t,prevP1:i,dragAxis:h}=this.gestures,{currSlide:e}=this.pswp;if("y"===h&&this.pswp.options.closeOnVerticalDrag&&e&&e.currZoomLevel<=e.zoomLevels.fit&&!this.gestures.isMultitouch){const s=e.pan.y+(t.y-i.y);if(!this.pswp.dispatch("verticalDrag",{panY:s}).defaultPrevented){this._("y",s,.6);const t=1-Math.abs(this.S(e.pan.y));this.pswp.applyBgOpacity(t),e.applyCurrentZoomPan()}}else{this.M("x")||(this.M("y"),e&&(s(e.pan),e.applyCurrentZoomPan()))}}end(){const{velocity:t}=this.gestures,{mainScroll:i,currSlide:s}=this.pswp;let h=0;if(this.pswp.animations.stopAll(),i.isShifted()){const s=(i.x-i.getCurrSlideX())/this.pswp.viewportSize.x;t.x<-.5&&s<0||t.x<.1&&s<-.5?(h=1,t.x=Math.min(t.x,0)):(t.x>.5&&s>0||t.x>-.1&&s>.5)&&(h=-1,t.x=Math.max(t.x,0)),i.moveIndexBy(h,!0,t.x)}s&&s.currZoomLevel>s.zoomLevels.max||this.gestures.isMultitouch?this.gestures.zoomLevels.correctZoomPan(!0):(this.P("x"),this.P("y"))}P(t){const{velocity:i}=this.gestures,{currSlide:s}=this.pswp;if(!s)return;const{pan:h,bounds:e}=s,o=h[t],r=this.pswp.bgOpacity<1&&"y"===t,a=o+function(t,i){return t*i/(1-i)}(i[t],.995);if(r){const t=this.S(o),i=this.S(a);if(t<0&&i<-.4||t>0&&i>.4)return void this.pswp.close()}const l=e.correctPan(t,a);if(o===l)return;const c=l===a?1:.82,d=this.pswp.bgOpacity,u=l-o;this.pswp.animations.startSpring({name:"panGesture"+t,isPan:!0,start:o,end:l,velocity:i[t],dampingRatio:c,onUpdate:i=>{if(r&&this.pswp.bgOpacity<1){const t=1-(l-i)/u;this.pswp.applyBgOpacity(n(d+(1-d)*t,0,1))}h[t]=Math.floor(i),s.applyCurrentZoomPan()}})}M(t){const{p1:i,dragAxis:s,prevP1:h,isMultitouch:e}=this.gestures,{currSlide:n,mainScroll:o}=this.pswp,r=i[t]-h[t],a=o.x+r;if(!r||!n)return!1;if("x"===t&&!n.isPannable()&&!e)return o.moveTo(a,!0),!0;const{bounds:l}=n,c=n.pan[t]+r;if(this.pswp.options.allowPanToNext&&"x"===s&&"x"===t&&!e){const i=o.getCurrSlideX(),s=o.x-i,h=r>0,e=!h;if(c>l.min[t]&&h){if(l.min[t]<=this.startPan[t])return o.moveTo(a,!0),!0;this._(t,c)}else if(c<l.max[t]&&e){if(this.startPan[t]<=l.max[t])return o.moveTo(a,!0),!0;this._(t,c)}else if(0!==s){if(s>0)return o.moveTo(Math.max(a,i),!0),!0;if(s<0)return o.moveTo(Math.min(a,i),!0),!0}else this._(t,c)}else"y"===t&&(o.isShifted()||l.min.y===l.max.y)||this._(t,c);return!1}S(t){var i,s;return(t-(null!==(i=null===(s=this.pswp.currSlide)||void 0===s?void 0:s.bounds.center.y)&&void 0!==i?i:0))/(this.pswp.viewportSize.y/3)}_(t,i,s){const{currSlide:h}=this.pswp;if(!h)return;const{pan:e,bounds:n}=h;if(n.correctPan(t,i)!==i||s){const h=Math.round(i-e[t]);e[t]+=h*(s||.35)}else e[t]=i}}function z(t,i,s){return t.x=(i.x+s.x)/2,t.y=(i.y+s.y)/2,t}class M{constructor(t){this.gestures=t,this.C={x:0,y:0},this.T={x:0,y:0},this.A={x:0,y:0},this.D=!1,this.I=1}start(){const{currSlide:t}=this.gestures.pswp;t&&(this.I=t.currZoomLevel,i(this.C,t.pan)),this.gestures.pswp.animations.stopAllPan(),this.D=!1}change(){const{p1:t,startP1:i,p2:s,startP2:e,pswp:n}=this.gestures,{currSlide:o}=n;if(!o)return;const r=o.zoomLevels.min,a=o.zoomLevels.max;if(!o.isZoomable()||n.mainScroll.isShifted())return;z(this.T,i,e),z(this.A,t,s);let l=1/h(i,e)*h(t,s)*this.I;if(l>o.zoomLevels.initial+o.zoomLevels.initial/15&&(this.D=!0),l<r)if(n.options.pinchToClose&&!this.D&&this.I<=o.zoomLevels.initial){const t=1-(r-l)/(r/1.2);n.dispatch("pinchClose",{bgOpacity:t}).defaultPrevented||n.applyBgOpacity(t)}else l=r-.15*(r-l);else l>a&&(l=a+.05*(l-a));o.pan.x=this.L("x",l),o.pan.y=this.L("y",l),o.setZoomLevel(l),o.applyCurrentZoomPan()}end(){const{pswp:t}=this.gestures,{currSlide:i}=t;(!i||i.currZoomLevel<i.zoomLevels.initial)&&!this.D&&t.options.pinchToClose?t.close():this.correctZoomPan()}L(t,i){const s=i/this.I;return this.A[t]-(this.T[t]-this.C[t])*s}correctZoomPan(t){const{pswp:s}=this.gestures,{currSlide:h}=s;if(null==h||!h.isZoomable())return;0===this.A.x&&(t=!0);const o=h.currZoomLevel;let r,a=!0;o<h.zoomLevels.initial?r=h.zoomLevels.initial:o>h.zoomLevels.max?r=h.zoomLevels.max:(a=!1,r=o);const l=s.bgOpacity,c=s.bgOpacity<1,d=i({x:0,y:0},h.pan);let u=i({x:0,y:0},d);t&&(this.A.x=0,this.A.y=0,this.T.x=0,this.T.y=0,this.I=o,i(this.C,d)),a&&(u={x:this.L("x",r),y:this.L("y",r)}),h.setZoomLevel(r),u={x:h.bounds.correctPan("x",u.x),y:h.bounds.correctPan("y",u.y)},h.setZoomLevel(o);const p=!e(u,d);if(!p&&!a&&!c)return h.v(r),void h.applyCurrentZoomPan();s.animations.stopAllPan(),s.animations.startSpring({isPan:!0,start:0,end:1e3,velocity:0,dampingRatio:1,naturalFrequency:40,onUpdate:t=>{if(t/=1e3,p||a){if(p&&(h.pan.x=d.x+(u.x-d.x)*t,h.pan.y=d.y+(u.y-d.y)*t),a){const i=o+(r-o)*t;h.setZoomLevel(i)}h.applyCurrentZoomPan()}c&&s.bgOpacity<1&&s.applyBgOpacity(n(l+(1-l)*t,0,1))},onComplete:()=>{h.v(r),h.applyCurrentZoomPan()}})}}function P(t){return!!t.target.closest(".pswp__container")}class C{constructor(t){this.gestures=t}click(t,i){const s=i.target.classList,h=s.contains("pswp__img"),e=s.contains("pswp__item")||s.contains("pswp__zoom-wrap");h?this.k("imageClick",t,i):e&&this.k("bgClick",t,i)}tap(t,i){P(i)&&this.k("tap",t,i)}doubleTap(t,i){P(i)&&this.k("doubleTap",t,i)}k(t,i,s){var h;const{pswp:e}=this.gestures,{currSlide:n}=e,o=t+"Action",r=e.options[o];if(!e.dispatch(o,{point:i,originalEvent:s}).defaultPrevented)if("function"!=typeof r)switch(r){case"close":case"next":e[r]();break;case"zoom":null==n||n.toggleZoom(i);break;case"zoom-or-close":null!=n&&n.isZoomable()&&n.zoomLevels.secondary!==n.zoomLevels.initial?n.toggleZoom(i):e.options.clickToCloseNonZoomable&&e.close();break;case"toggle-controls":null===(h=this.gestures.pswp.element)||void 0===h||h.classList.toggle("pswp--ui-visible")}else r.call(e,i,s)}}class T{constructor(t){this.pswp=t,this.dragAxis=null,this.p1={x:0,y:0},this.p2={x:0,y:0},this.prevP1={x:0,y:0},this.prevP2={x:0,y:0},this.startP1={x:0,y:0},this.startP2={x:0,y:0},this.velocity={x:0,y:0},this.Z={x:0,y:0},this.B={x:0,y:0},this.F=0,this.O=[],this.R="ontouchstart"in window,this.N=!!window.PointerEvent,this.supportsTouch=this.R||this.N&&navigator.maxTouchPoints>1,this.F=0,this.U=0,this.V=!1,this.isMultitouch=!1,this.isDragging=!1,this.isZooming=!1,this.raf=null,this.G=null,this.supportsTouch||(t.options.allowPanToNext=!1),this.drag=new S(this),this.zoomLevels=new M(this),this.tapHandler=new C(this),t.on("bindEvents",(()=>{t.events.add(t.scrollWrap,"click",this.$.bind(this)),this.N?this.q("pointer","down","up","cancel"):this.R?(this.q("touch","start","end","cancel"),t.scrollWrap&&(t.scrollWrap.ontouchmove=()=>{},t.scrollWrap.ontouchend=()=>{})):this.q("mouse","down","up")}))}q(t,i,s,h){const{pswp:e}=this,{events:n}=e,o=h?t+h:"";n.add(e.scrollWrap,t+i,this.onPointerDown.bind(this)),n.add(window,t+"move",this.onPointerMove.bind(this)),n.add(window,t+s,this.onPointerUp.bind(this)),o&&n.add(e.scrollWrap,o,this.onPointerUp.bind(this))}onPointerDown(t){const s="mousedown"===t.type||"mouse"===t.pointerType;if(s&&t.button>0)return;const{pswp:h}=this;h.opener.isOpen?h.dispatch("pointerDown",{originalEvent:t}).defaultPrevented||(s&&(h.mouseDetected(),this.H(t,"down")),h.animations.stopAll(),this.K(t,"down"),1===this.F&&(this.dragAxis=null,i(this.startP1,this.p1)),this.F>1?(this.W(),this.isMultitouch=!0):this.isMultitouch=!1):t.preventDefault()}onPointerMove(t){this.H(t,"move"),this.F&&(this.K(t,"move"),this.pswp.dispatch("pointerMove",{originalEvent:t}).defaultPrevented||(1!==this.F||this.isDragging?this.F>1&&!this.isZooming&&(this.j(),this.isZooming=!0,this.X(),this.zoomLevels.start(),this.Y(),this.J()):(this.dragAxis||this.tt(),this.dragAxis&&!this.isDragging&&(this.isZooming&&(this.isZooming=!1,this.zoomLevels.end()),this.isDragging=!0,this.W(),this.X(),this.U=Date.now(),this.V=!1,i(this.B,this.p1),this.velocity.x=0,this.velocity.y=0,this.drag.start(),this.Y(),this.J()))))}j(){this.isDragging&&(this.isDragging=!1,this.V||this.it(!0),this.drag.end(),this.dragAxis=null)}onPointerUp(t){this.F&&(this.K(t,"up"),this.pswp.dispatch("pointerUp",{originalEvent:t}).defaultPrevented||(0===this.F&&(this.Y(),this.isDragging?this.j():this.isZooming||this.isMultitouch||this.st(t)),this.F<2&&this.isZooming&&(this.isZooming=!1,this.zoomLevels.end(),1===this.F&&(this.dragAxis=null,this.X()))))}J(){(this.isDragging||this.isZooming)&&(this.it(),this.isDragging?e(this.p1,this.prevP1)||this.drag.change():e(this.p1,this.prevP1)&&e(this.p2,this.prevP2)||this.zoomLevels.change(),this.ht(),this.raf=requestAnimationFrame(this.J.bind(this)))}it(t){const s=Date.now(),h=s-this.U;h<50&&!t||(this.velocity.x=this.et("x",h),this.velocity.y=this.et("y",h),this.U=s,i(this.B,this.p1),this.V=!0)}st(t){const{mainScroll:s}=this.pswp;if(s.isShifted())return void s.moveIndexBy(0,!0);if(t.type.indexOf("cancel")>0)return;if("mouseup"===t.type||"mouse"===t.pointerType)return void this.tapHandler.click(this.startP1,t);const e=this.pswp.options.doubleTapAction?300:0;this.G?(this.W(),h(this.Z,this.startP1)<25&&this.tapHandler.doubleTap(this.startP1,t)):(i(this.Z,this.startP1),this.G=setTimeout((()=>{this.tapHandler.tap(this.startP1,t),this.W()}),e))}W(){this.G&&(clearTimeout(this.G),this.G=null)}et(t,i){const s=this.p1[t]-this.B[t];return Math.abs(s)>1&&i>5?s/i:0}Y(){this.raf&&(cancelAnimationFrame(this.raf),this.raf=null)}H(t,i){this.pswp.applyFilters("preventPointerEvent",!0,t,i)&&t.preventDefault()}K(t,s){if(this.N){const h=t,e=this.O.findIndex((t=>t.id===h.pointerId));"up"===s&&e>-1?this.O.splice(e,1):"down"===s&&-1===e?this.O.push(this.nt(h,{x:0,y:0})):e>-1&&this.nt(h,this.O[e]),this.F=this.O.length,this.F>0&&i(this.p1,this.O[0]),this.F>1&&i(this.p2,this.O[1])}else{const i=t;this.F=0,i.type.indexOf("touch")>-1?i.touches&&i.touches.length>0&&(this.nt(i.touches[0],this.p1),this.F++,i.touches.length>1&&(this.nt(i.touches[1],this.p2),this.F++)):(this.nt(t,this.p1),"up"===s?this.F=0:this.F++)}}ht(){i(this.prevP1,this.p1),i(this.prevP2,this.p2)}X(){i(this.startP1,this.p1),i(this.startP2,this.p2),this.ht()}tt(){if(this.pswp.mainScroll.isShifted())this.dragAxis="x";else{const t=Math.abs(this.p1.x-this.startP1.x)-Math.abs(this.p1.y-this.startP1.y);if(0!==t){const i=t>0?"x":"y";Math.abs(this.p1[i]-this.startP1[i])>=10&&(this.dragAxis=i)}}}nt(t,i){return i.x=t.pageX-this.pswp.offset.x,i.y=t.pageY-this.pswp.offset.y,"pointerId"in t?i.id=t.pointerId:void 0!==t.identifier&&(i.id=t.identifier),i}$(t){this.pswp.mainScroll.isShifted()&&(t.preventDefault(),t.stopPropagation())}}class A{constructor(t){this.pswp=t,this.x=0,this.slideWidth=0,this.ot=0,this.rt=0,this.lt=-1,this.itemHolders=[]}resize(t){const{pswp:i}=this,s=Math.round(i.viewportSize.x+i.viewportSize.x*i.options.spacing),h=s!==this.slideWidth;h&&(this.slideWidth=s,this.moveTo(this.getCurrSlideX())),this.itemHolders.forEach(((i,s)=>{h&&r(i.el,(s+this.lt)*this.slideWidth),t&&i.slide&&i.slide.resize()}))}resetPosition(){this.ot=0,this.rt=0,this.slideWidth=0,this.lt=-1}appendHolders(){this.itemHolders=[];for(let i=0;i<3;i++){const s=t("pswp__item","div",this.pswp.container);s.setAttribute("role","group"),s.setAttribute("aria-roledescription","slide"),s.setAttribute("aria-hidden","true"),s.style.display=1===i?"block":"none",this.itemHolders.push({el:s})}}canBeSwiped(){return this.pswp.getNumItems()>1}moveIndexBy(t,i,s){const{pswp:h}=this;let e=h.potentialIndex+t;const n=h.getNumItems();if(h.canLoop()){e=h.getLoopedIndex(e);const i=(t+n)%n;t=i<=n/2?i:i-n}else e<0?e=0:e>=n&&(e=n-1),t=e-h.potentialIndex;h.potentialIndex=e,this.ot-=t,h.animations.stopMainScroll();const o=this.getCurrSlideX();if(i){h.animations.startSpring({isMainScroll:!0,start:this.x,end:o,velocity:s||0,naturalFrequency:30,dampingRatio:1,onUpdate:t=>{this.moveTo(t)},onComplete:()=>{this.updateCurrItem(),h.appendHeavy()}});let t=h.potentialIndex-h.currIndex;if(h.canLoop()){const i=(t+n)%n;t=i<=n/2?i:i-n}Math.abs(t)>1&&this.updateCurrItem()}else this.moveTo(o),this.updateCurrItem();return Boolean(t)}getCurrSlideX(){return this.slideWidth*this.ot}isShifted(){return this.x!==this.getCurrSlideX()}updateCurrItem(){var t;const{pswp:i}=this,s=this.rt-this.ot;if(!s)return;this.rt=this.ot,i.currIndex=i.potentialIndex;let h,e=Math.abs(s);e>=3&&(this.lt+=s+(s>0?-3:3),e=3,this.itemHolders.forEach((t=>{var i;null===(i=t.slide)||void 0===i||i.destroy(),t.slide=void 0})));for(let t=0;t<e;t++)s>0?(h=this.itemHolders.shift(),h&&(this.itemHolders[2]=h,this.lt++,r(h.el,(this.lt+2)*this.slideWidth),i.setContent(h,i.currIndex-e+t+2))):(h=this.itemHolders.pop(),h&&(this.itemHolders.unshift(h),this.lt--,r(h.el,this.lt*this.slideWidth),i.setContent(h,i.currIndex+e-t-2)));Math.abs(this.lt)>50&&!this.isShifted()&&(this.resetPosition(),this.resize()),i.animations.stopAllPan(),this.itemHolders.forEach(((t,i)=>{t.slide&&t.slide.setIsActive(1===i)})),i.currSlide=null===(t=this.itemHolders[1])||void 0===t?void 0:t.slide,i.contentLoader.updateLazy(s),i.currSlide&&i.currSlide.applyCurrentZoomPan(),i.dispatch("change")}moveTo(t,i){if(!this.pswp.canLoop()&&i){let i=(this.slideWidth*this.ot-t)/this.slideWidth;i+=this.pswp.currIndex;const s=Math.round(t-this.x);(i<0&&s>0||i>=this.pswp.getNumItems()-1&&s<0)&&(t=this.x+.35*s)}this.x=t,this.pswp.container&&r(this.pswp.container,t),this.pswp.dispatch("moveMainScroll",{x:t,dragging:null!=i&&i})}}const D={Escape:27,z:90,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Tab:9},I=(t,i)=>i?t:D[t];class E{constructor(t){this.pswp=t,this.ct=!1,t.on("bindEvents",(()=>{t.options.trapFocus&&(t.options.initialPointerPos||this.dt(),t.events.add(document,"focusin",this.ut.bind(this))),t.events.add(document,"keydown",this.vt.bind(this))}));const i=document.activeElement;t.on("destroy",(()=>{t.options.returnFocus&&i&&this.ct&&i.focus()}))}dt(){!this.ct&&this.pswp.element&&(this.pswp.element.focus(),this.ct=!0)}vt(t){const{pswp:i}=this;if(i.dispatch("keydown",{originalEvent:t}).defaultPrevented)return;if(function(t){return"button"in t&&1===t.button||t.ctrlKey||t.metaKey||t.altKey||t.shiftKey}(t))return;let s,h,e=!1;const n="key"in t;switch(n?t.key:t.keyCode){case I("Escape",n):i.options.escKey&&(s="close");break;case I("z",n):s="toggleZoom";break;case I("ArrowLeft",n):h="x";break;case I("ArrowUp",n):h="y";break;case I("ArrowRight",n):h="x",e=!0;break;case I("ArrowDown",n):e=!0,h="y";break;case I("Tab",n):this.dt()}if(h){t.preventDefault();const{currSlide:n}=i;i.options.arrowKeys&&"x"===h&&i.getNumItems()>1?s=e?"next":"prev":n&&n.currZoomLevel>n.zoomLevels.fit&&(n.pan[h]+=e?-80:80,n.panTo(n.pan.x,n.pan.y))}s&&(t.preventDefault(),i[s]())}ut(t){const{template:i}=this.pswp;i&&document!==t.target&&i!==t.target&&!i.contains(t.target)&&i.focus()}}const L="cubic-bezier(.4,0,.22,1)";class k{constructor(t){var i;this.props=t;const{target:s,onComplete:h,transform:e,onFinish:n=(()=>{}),duration:o=333,easing:r=L}=t;this.onFinish=n;const l=e?"transform":"opacity",c=null!==(i=t[l])&&void 0!==i?i:"";this.ft=s,this.wt=h,this.gt=!1,this.yt=this.yt.bind(this),this._t=setTimeout((()=>{a(s,l,o,r),this._t=setTimeout((()=>{s.addEventListener("transitionend",this.yt,!1),s.addEventListener("transitioncancel",this.yt,!1),this._t=setTimeout((()=>{this.xt()}),o+500),s.style[l]=c}),30)}),0)}yt(t){t.target===this.ft&&this.xt()}xt(){this.gt||(this.gt=!0,this.onFinish(),this.wt&&this.wt())}destroy(){this._t&&clearTimeout(this._t),a(this.ft),this.ft.removeEventListener("transitionend",this.yt,!1),this.ft.removeEventListener("transitioncancel",this.yt,!1),this.gt||this.xt()}}class Z{constructor(t,i,s){this.velocity=1e3*t,this.bt=i||.75,this.St=s||12,this.zt=this.St,this.bt<1&&(this.zt*=Math.sqrt(1-this.bt*this.bt))}easeFrame(t,i){let s,h=0;i/=1e3;const e=Math.E**(-this.bt*this.St*i);if(1===this.bt)s=this.velocity+this.St*t,h=(t+s*i)*e,this.velocity=h*-this.St+s*e;else if(this.bt<1){s=1/this.zt*(this.bt*this.St*t+this.velocity);const n=Math.cos(this.zt*i),o=Math.sin(this.zt*i);h=e*(t*n+s*o),this.velocity=h*-this.St*this.bt+e*(-this.zt*t*o+this.zt*s*n)}return h}}class B{constructor(t){this.props=t,this.Mt=0;const{start:i,end:s,velocity:h,onUpdate:e,onComplete:n,onFinish:o=(()=>{}),dampingRatio:r,naturalFrequency:a}=t;this.onFinish=o;const l=new Z(h,r,a);let c=Date.now(),d=i-s;const u=()=>{this.Mt&&(d=l.easeFrame(d,Date.now()-c),Math.abs(d)<1&&Math.abs(l.velocity)<50?(e(s),n&&n(),this.onFinish()):(c=Date.now(),e(d+s),this.Mt=requestAnimationFrame(u)))};this.Mt=requestAnimationFrame(u)}destroy(){this.Mt>=0&&cancelAnimationFrame(this.Mt),this.Mt=0}}class F{constructor(){this.activeAnimations=[]}startSpring(t){this.Pt(t,!0)}startTransition(t){this.Pt(t)}Pt(t,i){const s=i?new B(t):new k(t);return this.activeAnimations.push(s),s.onFinish=()=>this.stop(s),s}stop(t){t.destroy();const i=this.activeAnimations.indexOf(t);i>-1&&this.activeAnimations.splice(i,1)}stopAll(){this.activeAnimations.forEach((t=>{t.destroy()})),this.activeAnimations=[]}stopAllPan(){this.activeAnimations=this.activeAnimations.filter((t=>!t.props.isPan||(t.destroy(),!1)))}stopMainScroll(){this.activeAnimations=this.activeAnimations.filter((t=>!t.props.isMainScroll||(t.destroy(),!1)))}isPanRunning(){return this.activeAnimations.some((t=>t.props.isPan))}}class O{constructor(t){this.pswp=t,t.events.add(t.element,"wheel",this.Ct.bind(this))}Ct(t){t.preventDefault();const{currSlide:i}=this.pswp;let{deltaX:s,deltaY:h}=t;if(i&&!this.pswp.dispatch("wheel",{originalEvent:t}).defaultPrevented)if(t.ctrlKey||this.pswp.options.wheelToZoom){if(i.isZoomable()){let s=-h;1===t.deltaMode?s*=.05:s*=t.deltaMode?1:.002,s=2**s;const e=i.currZoomLevel*s;i.zoomTo(e,{x:t.clientX,y:t.clientY})}}else i.isPannable()&&(1===t.deltaMode&&(s*=18,h*=18),i.panTo(i.pan.x-s,i.pan.y-h))}}class R{constructor(i,s){var h;const e=s.name||s.className;let n=s.html;if(!1===i.options[e])return;"string"==typeof i.options[e+"SVG"]&&(n=i.options[e+"SVG"]),i.dispatch("uiElementCreate",{data:s});let o="";s.isButton?(o+="pswp__button ",o+=s.className||`pswp__button--${s.name}`):o+=s.className||`pswp__${s.name}`;let r=s.isButton?s.tagName||"button":s.tagName||"div";r=r.toLowerCase();const a=t(o,r);if(s.isButton){"button"===r&&(a.type="button");let{title:t}=s;const{ariaLabel:h}=s;"string"==typeof i.options[e+"Title"]&&(t=i.options[e+"Title"]),t&&(a.title=t);const n=h||t;n&&a.setAttribute("aria-label",n)}a.innerHTML=function(t){if("string"==typeof t)return t;if(!t||!t.isCustomSVG)return"";const i=t;let s='<svg aria-hidden="true" class="pswp__icn" viewBox="0 0 %d %d" width="%d" height="%d">';return s=s.split("%d").join(i.size||32),i.outlineID&&(s+='<use class="pswp__icn-shadow" xlink:href="#'+i.outlineID+'"/>'),s+=i.inner,s+="</svg>",s}(n),s.onInit&&s.onInit(a,i),s.onClick&&(a.onclick=t=>{"string"==typeof s.onClick?i[s.onClick]():"function"==typeof s.onClick&&s.onClick(t,a,i)});const l=s.appendTo||"bar";let c=i.element;"bar"===l?(i.topBar||(i.topBar=t("pswp__top-bar pswp__hide-on-close","div",i.scrollWrap)),c=i.topBar):(a.classList.add("pswp__hide-on-close"),"wrapper"===l&&(c=i.scrollWrap)),null===(h=c)||void 0===h||h.appendChild(i.applyFilters("uiElement",a,s))}}function N(t,i,s){t.classList.add("pswp__button--arrow"),t.setAttribute("aria-controls","pswp__items"),i.on("change",(()=>{i.options.loop||(t.disabled=s?!(i.currIndex<i.getNumItems()-1):!(i.currIndex>0))}))}const U={name:"arrowPrev",className:"pswp__button--arrow--prev",title:"Previous",order:10,isButton:!0,appendTo:"wrapper",html:{isCustomSVG:!0,size:60,inner:'<path d="M29 43l-3 3-16-16 16-16 3 3-13 13 13 13z" id="pswp__icn-arrow"/>',outlineID:"pswp__icn-arrow"},onClick:"prev",onInit:N},V={name:"arrowNext",className:"pswp__button--arrow--next",title:"Next",order:11,isButton:!0,appendTo:"wrapper",html:{isCustomSVG:!0,size:60,inner:'<use xlink:href="#pswp__icn-arrow"/>',outlineID:"pswp__icn-arrow"},onClick:"next",onInit:(t,i)=>{N(t,i,!0)}},G={name:"close",title:"Close",order:20,isButton:!0,html:{isCustomSVG:!0,inner:'<path d="M24 10l-2-2-6 6-6-6-2 2 6 6-6 6 2 2 6-6 6 6 2-2-6-6z" id="pswp__icn-close"/>',outlineID:"pswp__icn-close"},onClick:"close"},$={name:"zoom",title:"Zoom",order:10,isButton:!0,html:{isCustomSVG:!0,inner:'<path d="M17.426 19.926a6 6 0 1 1 1.5-1.5L23 22.5 21.5 24l-4.074-4.074z" id="pswp__icn-zoom"/><path fill="currentColor" class="pswp__zoom-icn-bar-h" d="M11 16v-2h6v2z"/><path fill="currentColor" class="pswp__zoom-icn-bar-v" d="M13 12h2v6h-2z"/>',outlineID:"pswp__icn-zoom"},onClick:"toggleZoom"},q={name:"preloader",appendTo:"bar",order:7,html:{isCustomSVG:!0,inner:'<path fill-rule="evenodd" clip-rule="evenodd" d="M21.2 16a5.2 5.2 0 1 1-5.2-5.2V8a8 8 0 1 0 8 8h-2.8Z" id="pswp__icn-loading"/>',outlineID:"pswp__icn-loading"},onInit:(t,i)=>{let s,h=null;const e=i=>{var h,e;s!==i&&(s=i,h="active",e=i,t.classList.toggle("pswp__preloader--"+h,e))},n=()=>{var t;if(null===(t=i.currSlide)||void 0===t||!t.content.isLoading())return e(!1),void(h&&(clearTimeout(h),h=null));h||(h=setTimeout((()=>{var t;e(Boolean(null===(t=i.currSlide)||void 0===t?void 0:t.content.isLoading())),h=null}),i.options.preloaderDelay))};i.on("change",n),i.on("loadComplete",(t=>{i.currSlide===t.slide&&n()})),i.ui&&(i.ui.updatePreloaderVisibility=n)}},H={name:"counter",order:5,onInit:(t,i)=>{i.on("change",(()=>{t.innerText=i.currIndex+1+i.options.indexIndicatorSep+i.getNumItems()}))}};function K(t,i){t.classList.toggle("pswp--zoomed-in",i)}class W{constructor(t){this.pswp=t,this.isRegistered=!1,this.uiElementsData=[],this.items=[],this.updatePreloaderVisibility=()=>{},this.Tt=void 0}init(){const{pswp:t}=this;this.isRegistered=!1,this.uiElementsData=[G,U,V,$,q,H],t.dispatch("uiRegister"),this.uiElementsData.sort(((t,i)=>(t.order||0)-(i.order||0))),this.items=[],this.isRegistered=!0,this.uiElementsData.forEach((t=>{this.registerElement(t)})),t.on("change",(()=>{var i;null===(i=t.element)||void 0===i||i.classList.toggle("pswp--one-slide",1===t.getNumItems())})),t.on("zoomPanUpdate",(()=>this.At()))}registerElement(t){this.isRegistered?this.items.push(new R(this.pswp,t)):this.uiElementsData.push(t)}At(){const{template:t,currSlide:i,options:s}=this.pswp;if(this.pswp.opener.isClosing||!t||!i)return;let{currZoomLevel:h}=i;if(this.pswp.opener.isOpen||(h=i.zoomLevels.initial),h===this.Tt)return;this.Tt=h;const e=i.zoomLevels.initial-i.zoomLevels.secondary;if(Math.abs(e)<.01||!i.isZoomable())return K(t,!1),void t.classList.remove("pswp--zoom-allowed");t.classList.add("pswp--zoom-allowed");K(t,(h===i.zoomLevels.initial?i.zoomLevels.secondary:i.zoomLevels.initial)<=h),"zoom"!==s.imageClickAction&&"zoom-or-close"!==s.imageClickAction||t.classList.add("pswp--click-to-zoom")}}class j{constructor(t,i){this.type=t,this.defaultPrevented=!1,i&&Object.assign(this,i)}preventDefault(){this.defaultPrevented=!0}}class X{constructor(i,s){if(this.element=t("pswp__img pswp__img--placeholder",i?"img":"div",s),i){const t=this.element;t.decoding="async",t.alt="",t.src=i,t.setAttribute("role","presentation")}this.element.setAttribute("aria-hidden","true")}setDisplayedSize(t,i){this.element&&("IMG"===this.element.tagName?(l(this.element,250,"auto"),this.element.style.transformOrigin="0 0",this.element.style.transform=o(0,0,t/250)):l(this.element,t,i))}destroy(){var t;null!==(t=this.element)&&void 0!==t&&t.parentNode&&this.element.remove(),this.element=null}}class Y{constructor(t,i,s){this.instance=i,this.data=t,this.index=s,this.element=void 0,this.placeholder=void 0,this.slide=void 0,this.displayedImageWidth=0,this.displayedImageHeight=0,this.width=Number(this.data.w)||Number(this.data.width)||0,this.height=Number(this.data.h)||Number(this.data.height)||0,this.isAttached=!1,this.hasSlide=!1,this.isDecoding=!1,this.state=c,this.data.type?this.type=this.data.type:this.data.src?this.type="image":this.type="html",this.instance.dispatch("contentInit",{content:this})}removePlaceholder(){this.placeholder&&!this.keepPlaceholder()&&setTimeout((()=>{this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0)}),1e3)}load(i,s){if(this.slide&&this.usePlaceholder())if(this.placeholder){const t=this.placeholder.element;t&&!t.parentElement&&this.slide.container.prepend(t)}else{const t=this.instance.applyFilters("placeholderSrc",!(!this.data.msrc||!this.slide.isFirstSlide)&&this.data.msrc,this);this.placeholder=new X(t,this.slide.container)}this.element&&!s||this.instance.dispatch("contentLoad",{content:this,isLazy:i}).defaultPrevented||(this.isImageContent()?(this.element=t("pswp__img","img"),this.displayedImageWidth&&this.loadImage(i)):(this.element=t("pswp__content","div"),this.element.innerHTML=this.data.html||""),s&&this.slide&&this.slide.updateContentSize(!0))}loadImage(t){var i,s;if(!this.isImageContent()||!this.element||this.instance.dispatch("contentLoadImage",{content:this,isLazy:t}).defaultPrevented)return;const h=this.element;this.updateSrcsetSizes(),this.data.srcset&&(h.srcset=this.data.srcset),h.src=null!==(i=this.data.src)&&void 0!==i?i:"",h.alt=null!==(s=this.data.alt)&&void 0!==s?s:"",this.state=d,h.complete?this.onLoaded():(h.onload=()=>{this.onLoaded()},h.onerror=()=>{this.onError()})}setSlide(t){this.slide=t,this.hasSlide=!0,this.instance=t.pswp}onLoaded(){this.state=u,this.slide&&this.element&&(this.instance.dispatch("loadComplete",{slide:this.slide,content:this}),this.slide.isActive&&this.slide.heavyAppended&&!this.element.parentNode&&(this.append(),this.slide.updateContentSize(!0)),this.state!==u&&this.state!==p||this.removePlaceholder())}onError(){this.state=p,this.slide&&(this.displayError(),this.instance.dispatch("loadComplete",{slide:this.slide,isError:!0,content:this}),this.instance.dispatch("loadError",{slide:this.slide,content:this}))}isLoading(){return this.instance.applyFilters("isContentLoading",this.state===d,this)}isError(){return this.state===p}isImageContent(){return"image"===this.type}setDisplayedSize(t,i){if(this.element&&(this.placeholder&&this.placeholder.setDisplayedSize(t,i),!this.instance.dispatch("contentResize",{content:this,width:t,height:i}).defaultPrevented&&(l(this.element,t,i),this.isImageContent()&&!this.isError()))){const s=!this.displayedImageWidth&&t;this.displayedImageWidth=t,this.displayedImageHeight=i,s?this.loadImage(!1):this.updateSrcsetSizes(),this.slide&&this.instance.dispatch("imageSizeChange",{slide:this.slide,width:t,height:i,content:this})}}isZoomable(){return this.instance.applyFilters("isContentZoomable",this.isImageContent()&&this.state!==p,this)}updateSrcsetSizes(){if(!this.isImageContent()||!this.element||!this.data.srcset)return;const t=this.element,i=this.instance.applyFilters("srcsetSizesWidth",this.displayedImageWidth,this);(!t.dataset.largestUsedSize||i>parseInt(t.dataset.largestUsedSize,10))&&(t.sizes=i+"px",t.dataset.largestUsedSize=String(i))}usePlaceholder(){return this.instance.applyFilters("useContentPlaceholder",this.isImageContent(),this)}lazyLoad(){this.instance.dispatch("contentLazyLoad",{content:this}).defaultPrevented||this.load(!0)}keepPlaceholder(){return this.instance.applyFilters("isKeepingPlaceholder",this.isLoading(),this)}destroy(){this.hasSlide=!1,this.slide=void 0,this.instance.dispatch("contentDestroy",{content:this}).defaultPrevented||(this.remove(),this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0),this.isImageContent()&&this.element&&(this.element.onload=null,this.element.onerror=null,this.element=void 0))}displayError(){if(this.slide){var i,s;let h=t("pswp__error-msg","div");h.innerText=null!==(i=null===(s=this.instance.options)||void 0===s?void 0:s.errorMsg)&&void 0!==i?i:"",h=this.instance.applyFilters("contentErrorElement",h,this),this.element=t("pswp__content pswp__error-msg-container","div"),this.element.appendChild(h),this.slide.container.innerText="",this.slide.container.appendChild(this.element),this.slide.updateContentSize(!0),this.removePlaceholder()}}append(){if(this.isAttached||!this.element)return;if(this.isAttached=!0,this.state===p)return void this.displayError();if(this.instance.dispatch("contentAppend",{content:this}).defaultPrevented)return;const t="decode"in this.element;this.isImageContent()?t&&this.slide&&(!this.slide.isActive||m())?(this.isDecoding=!0,this.element.decode().catch((()=>{})).finally((()=>{this.isDecoding=!1,this.appendImage()}))):this.appendImage():this.slide&&!this.element.parentNode&&this.slide.container.appendChild(this.element)}activate(){!this.instance.dispatch("contentActivate",{content:this}).defaultPrevented&&this.slide&&(this.isImageContent()&&this.isDecoding&&!m()?this.appendImage():this.isError()&&this.load(!1,!0),this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","false"))}deactivate(){this.instance.dispatch("contentDeactivate",{content:this}),this.slide&&this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","true")}remove(){this.isAttached=!1,this.instance.dispatch("contentRemove",{content:this}).defaultPrevented||(this.element&&this.element.parentNode&&this.element.remove(),this.placeholder&&this.placeholder.element&&this.placeholder.element.remove())}appendImage(){this.isAttached&&(this.instance.dispatch("contentAppendImage",{content:this}).defaultPrevented||(this.slide&&this.element&&!this.element.parentNode&&this.slide.container.appendChild(this.element),this.state!==u&&this.state!==p||this.removePlaceholder()))}}function J(t,i,s){const h=i.createContentFromData(t,s);let e;const{options:n}=i;if(n){let o;e=new x(n,t,-1),o=i.pswp?i.pswp.viewportSize:w(n,i);const r=y(n,o,t,s);e.update(h.width,h.height,r)}return h.lazyLoad(),e&&h.setDisplayedSize(Math.ceil(h.width*e.initial),Math.ceil(h.height*e.initial)),h}class Q{constructor(t){this.pswp=t,this.limit=Math.max(t.options.preload[0]+t.options.preload[1]+1,5),this.Dt=[]}updateLazy(t){const{pswp:i}=this;if(i.dispatch("lazyLoad").defaultPrevented)return;const{preload:s}=i.options,h=void 0===t||t>=0;let e;for(e=0;e<=s[1];e++)this.loadSlideByIndex(i.currIndex+(h?e:-e));for(e=1;e<=s[0];e++)this.loadSlideByIndex(i.currIndex+(h?-e:e))}loadSlideByIndex(t){const i=this.pswp.getLoopedIndex(t);let s=this.getContentByIndex(i);s||(s=function(t,i){const s=i.getItemData(t);if(!i.dispatch("lazyLoadSlide",{index:t,itemData:s}).defaultPrevented)return J(s,i,t)}(i,this.pswp),s&&this.addToCache(s))}getContentBySlide(t){let i=this.getContentByIndex(t.index);return i||(i=this.pswp.createContentFromData(t.data,t.index),this.addToCache(i)),i.setSlide(t),i}addToCache(t){if(this.removeByIndex(t.index),this.Dt.push(t),this.Dt.length>this.limit){const t=this.Dt.findIndex((t=>!t.isAttached&&!t.hasSlide));if(-1!==t){this.Dt.splice(t,1)[0].destroy()}}}removeByIndex(t){const i=this.Dt.findIndex((i=>i.index===t));-1!==i&&this.Dt.splice(i,1)}getContentByIndex(t){return this.Dt.find((i=>i.index===t))}destroy(){this.Dt.forEach((t=>t.destroy())),this.Dt=[]}}const tt=.003;class it{constructor(t){this.pswp=t,this.isClosed=!0,this.isOpen=!1,this.isClosing=!1,this.isOpening=!1,this.It=void 0,this.Et=!1,this.Lt=!1,this.kt=!1,this.Zt=!1,this.Bt=void 0,this.Ft=void 0,this.Ot=void 0,this.Rt=void 0,this.Nt=void 0,this.Ut=this.Ut.bind(this),t.on("firstZoomPan",this.Ut)}open(){this.Ut(),this.Pt()}close(){if(this.isClosed||this.isClosing||this.isOpening)return;const t=this.pswp.currSlide;this.isOpen=!1,this.isOpening=!1,this.isClosing=!0,this.It=this.pswp.options.hideAnimationDuration,t&&t.currZoomLevel*t.width>=this.pswp.options.maxWidthToAnimate&&(this.It=0),this.Vt(),setTimeout((()=>{this.Pt()}),this.Lt?30:0)}Ut(){if(this.pswp.off("firstZoomPan",this.Ut),!this.isOpening){const t=this.pswp.currSlide;this.isOpening=!0,this.isClosing=!1,this.It=this.pswp.options.showAnimationDuration,t&&t.zoomLevels.initial*t.width>=this.pswp.options.maxWidthToAnimate&&(this.It=0),this.Vt()}}Vt(){const{pswp:t}=this,i=this.pswp.currSlide,{options:s}=t;var h,e;("fade"===s.showHideAnimationType?(s.showHideOpacity=!0,this.Nt=void 0):"none"===s.showHideAnimationType?(s.showHideOpacity=!1,this.It=0,this.Nt=void 0):this.isOpening&&t.Gt?this.Nt=t.Gt:this.Nt=this.pswp.getThumbBounds(),this.Bt=null==i?void 0:i.getPlaceholderElement(),t.animations.stopAll(),this.Et=Boolean(this.It&&this.It>50),this.$t=Boolean(this.Nt)&&(null==i?void 0:i.content.usePlaceholder())&&(!this.isClosing||!t.mainScroll.isShifted()),this.$t)?this.kt=null!==(h=s.showHideOpacity)&&void 0!==h&&h:(this.kt=!0,this.isOpening&&i&&(i.zoomAndPanToInitial(),i.applyCurrentZoomPan()));if(this.Zt=!this.kt&&this.pswp.options.bgOpacity>tt,this.Ft=this.kt?t.element:t.bg,!this.Et)return this.It=0,this.$t=!1,this.Zt=!1,this.kt=!0,void(this.isOpening&&(t.element&&(t.element.style.opacity=String(tt)),t.applyBgOpacity(1)));this.$t&&this.Nt&&this.Nt.innerRect?(this.Lt=!0,this.Ot=this.pswp.container,this.Rt=null===(e=this.pswp.currSlide)||void 0===e?void 0:e.holderElement,t.container&&(t.container.style.overflow="hidden",t.container.style.width=t.viewportSize.x+"px")):this.Lt=!1;this.isOpening?(this.kt?(t.element&&(t.element.style.opacity=String(tt)),t.applyBgOpacity(1)):(this.Zt&&t.bg&&(t.bg.style.opacity=String(tt)),t.element&&(t.element.style.opacity="1")),this.$t&&(this.qt(),this.Bt&&(this.Bt.style.willChange="transform",this.Bt.style.opacity=String(tt)))):this.isClosing&&(t.mainScroll.itemHolders[0]&&(t.mainScroll.itemHolders[0].el.style.display="none"),t.mainScroll.itemHolders[2]&&(t.mainScroll.itemHolders[2].el.style.display="none"),this.Lt&&0!==t.mainScroll.x&&(t.mainScroll.resetPosition(),t.mainScroll.resize()))}Pt(){this.isOpening&&this.Et&&this.Bt&&"IMG"===this.Bt.tagName?new Promise((t=>{let i=!1,s=!0;var h;(h=this.Bt,"decode"in h?h.decode().catch((()=>{})):h.complete?Promise.resolve(h):new Promise(((t,i)=>{h.onload=()=>t(h),h.onerror=i}))).finally((()=>{i=!0,s||t(!0)})),setTimeout((()=>{s=!1,i&&t(!0)}),50),setTimeout(t,250)})).finally((()=>this.Ht())):this.Ht()}Ht(){var t,i;null===(t=this.pswp.element)||void 0===t||t.style.setProperty("--pswp-transition-duration",this.It+"ms"),this.pswp.dispatch(this.isOpening?"openingAnimationStart":"closingAnimationStart"),this.pswp.dispatch("initialZoom"+(this.isOpening?"In":"Out")),null===(i=this.pswp.element)||void 0===i||i.classList.toggle("pswp--ui-visible",this.isOpening),this.isOpening?(this.Bt&&(this.Bt.style.opacity="1"),this.Kt()):this.isClosing&&this.Wt(),this.Et||this.jt()}jt(){const{pswp:t}=this;if(this.isOpen=this.isOpening,this.isClosed=this.isClosing,this.isOpening=!1,this.isClosing=!1,t.dispatch(this.isOpen?"openingAnimationEnd":"closingAnimationEnd"),t.dispatch("initialZoom"+(this.isOpen?"InEnd":"OutEnd")),this.isClosed)t.destroy();else if(this.isOpen){var i;this.$t&&t.container&&(t.container.style.overflow="visible",t.container.style.width="100%"),null===(i=t.currSlide)||void 0===i||i.applyCurrentZoomPan()}}Kt(){const{pswp:t}=this;this.$t&&(this.Lt&&this.Ot&&this.Rt&&(this.Xt(this.Ot,"transform","translate3d(0,0,0)"),this.Xt(this.Rt,"transform","none")),t.currSlide&&(t.currSlide.zoomAndPanToInitial(),this.Xt(t.currSlide.container,"transform",t.currSlide.getCurrentTransform()))),this.Zt&&t.bg&&this.Xt(t.bg,"opacity",String(t.options.bgOpacity)),this.kt&&t.element&&this.Xt(t.element,"opacity","1")}Wt(){const{pswp:t}=this;this.$t&&this.qt(!0),this.Zt&&t.bgOpacity>.01&&t.bg&&this.Xt(t.bg,"opacity","0"),this.kt&&t.element&&this.Xt(t.element,"opacity","0")}qt(t){if(!this.Nt)return;const{pswp:s}=this,{innerRect:h}=this.Nt,{currSlide:e,viewportSize:n}=s;if(this.Lt&&h&&this.Ot&&this.Rt){const i=-n.x+(this.Nt.x-h.x)+h.w,s=-n.y+(this.Nt.y-h.y)+h.h,e=n.x-h.w,a=n.y-h.h;t?(this.Xt(this.Ot,"transform",o(i,s)),this.Xt(this.Rt,"transform",o(e,a))):(r(this.Ot,i,s),r(this.Rt,e,a))}e&&(i(e.pan,h||this.Nt),e.currZoomLevel=this.Nt.w/e.width,t?this.Xt(e.container,"transform",e.getCurrentTransform()):e.applyCurrentZoomPan())}Xt(t,i,s){if(!this.It)return void(t.style[i]=s);const{animations:h}=this.pswp,e={duration:this.It,easing:this.pswp.options.easing,onComplete:()=>{h.activeAnimations.length||this.jt()},target:t};e[i]=s,h.startTransition(e)}}const st={allowPanToNext:!0,spacing:.1,loop:!0,pinchToClose:!0,closeOnVerticalDrag:!0,hideAnimationDuration:333,showAnimationDuration:333,zoomAnimationDuration:333,escKey:!0,arrowKeys:!0,trapFocus:!0,returnFocus:!0,maxWidthToAnimate:4e3,clickToCloseNonZoomable:!0,imageClickAction:"zoom-or-close",bgClickAction:"close",tapAction:"toggle-controls",doubleTapAction:"zoom",indexIndicatorSep:" / ",preloaderDelay:2e3,bgOpacity:.8,index:0,errorMsg:"The image cannot be loaded",preload:[1,2],easing:"cubic-bezier(.4,0,.22,1)"};return class extends class extends class{constructor(){this.Yt={},this.Jt={},this.pswp=void 0,this.options=void 0}addFilter(t,i,s=100){var h,e,n;this.Jt[t]||(this.Jt[t]=[]),null===(h=this.Jt[t])||void 0===h||h.push({fn:i,priority:s}),null===(e=this.Jt[t])||void 0===e||e.sort(((t,i)=>t.priority-i.priority)),null===(n=this.pswp)||void 0===n||n.addFilter(t,i,s)}removeFilter(t,i){this.Jt[t]&&(this.Jt[t]=this.Jt[t].filter((t=>t.fn!==i))),this.pswp&&this.pswp.removeFilter(t,i)}applyFilters(t,...i){var s;return null===(s=this.Jt[t])||void 0===s||s.forEach((t=>{i[0]=t.fn.apply(this,i)})),i[0]}on(t,i){var s,h;this.Yt[t]||(this.Yt[t]=[]),null===(s=this.Yt[t])||void 0===s||s.push(i),null===(h=this.pswp)||void 0===h||h.on(t,i)}off(t,i){var s;this.Yt[t]&&(this.Yt[t]=this.Yt[t].filter((t=>i!==t))),null===(s=this.pswp)||void 0===s||s.off(t,i)}dispatch(t,i){var s;if(this.pswp)return this.pswp.dispatch(t,i);const h=new j(t,i);return null===(s=this.Yt[t])||void 0===s||s.forEach((t=>{t.call(this,h)})),h}}{getNumItems(){var t;let i=0;const s=null===(t=this.options)||void 0===t?void 0:t.dataSource;s&&"length"in s?i=s.length:s&&"gallery"in s&&(s.items||(s.items=this.Qt(s.gallery)),s.items&&(i=s.items.length));const h=this.dispatch("numItems",{dataSource:s,numItems:i});return this.applyFilters("numItems",h.numItems,s)}createContentFromData(t,i){return new Y(t,this,i)}getItemData(t){var i;const s=null===(i=this.options)||void 0===i?void 0:i.dataSource;let h={};Array.isArray(s)?h=s[t]:s&&"gallery"in s&&(s.items||(s.items=this.Qt(s.gallery)),h=s.items[t]);let e=h;e instanceof Element&&(e=this.ti(e));const n=this.dispatch("itemData",{itemData:e||{},index:t});return this.applyFilters("itemData",n.itemData,t)}Qt(t){var i,s;return null!==(i=this.options)&&void 0!==i&&i.children||null!==(s=this.options)&&void 0!==s&&s.childSelector?function(t,i,s=document){let h=[];if(t instanceof Element)h=[t];else if(t instanceof NodeList||Array.isArray(t))h=Array.from(t);else{const e="string"==typeof t?t:i;e&&(h=Array.from(s.querySelectorAll(e)))}return h}(this.options.children,this.options.childSelector,t)||[]:[t]}ti(t){const i={element:t},s="A"===t.tagName?t:t.querySelector("a");if(s){i.src=s.dataset.pswpSrc||s.href,s.dataset.pswpSrcset&&(i.srcset=s.dataset.pswpSrcset),i.width=s.dataset.pswpWidth?parseInt(s.dataset.pswpWidth,10):0,i.height=s.dataset.pswpHeight?parseInt(s.dataset.pswpHeight,10):0,i.w=i.width,i.h=i.height,s.dataset.pswpType&&(i.type=s.dataset.pswpType);const e=t.querySelector("img");var h;if(e)i.msrc=e.currentSrc||e.src,i.alt=null!==(h=e.getAttribute("alt"))&&void 0!==h?h:"";(s.dataset.pswpCropped||s.dataset.cropped)&&(i.thumbCropped=!0)}return this.applyFilters("domItemData",i,t,s)}lazyLoadData(t,i){return J(t,this,i)}}{constructor(t){super(),this.options=this.ii(t||{}),this.offset={x:0,y:0},this.si={x:0,y:0},this.viewportSize={x:0,y:0},this.bgOpacity=1,this.currIndex=0,this.potentialIndex=0,this.isOpen=!1,this.isDestroying=!1,this.hasMouse=!1,this.hi={},this.Gt=void 0,this.topBar=void 0,this.element=void 0,this.template=void 0,this.container=void 0,this.scrollWrap=void 0,this.currSlide=void 0,this.events=new f,this.animations=new F,this.mainScroll=new A(this),this.gestures=new T(this),this.opener=new it(this),this.keyboard=new E(this),this.contentLoader=new Q(this)}init(){if(this.isOpen||this.isDestroying)return!1;this.isOpen=!0,this.dispatch("init"),this.dispatch("beforeOpen"),this.ei();let t="pswp--open";return this.gestures.supportsTouch&&(t+=" pswp--touch"),this.options.mainClass&&(t+=" "+this.options.mainClass),this.element&&(this.element.className+=" "+t),this.currIndex=this.options.index||0,this.potentialIndex=this.currIndex,this.dispatch("firstUpdate"),this.scrollWheel=new O(this),(Number.isNaN(this.currIndex)||this.currIndex<0||this.currIndex>=this.getNumItems())&&(this.currIndex=0),this.gestures.supportsTouch||this.mouseDetected(),this.updateSize(),this.offset.y=window.pageYOffset,this.hi=this.getItemData(this.currIndex),this.dispatch("gettingData",{index:this.currIndex,data:this.hi,slide:void 0}),this.Gt=this.getThumbBounds(),this.dispatch("initialLayout"),this.on("openingAnimationEnd",(()=>{const{itemHolders:t}=this.mainScroll;t[0]&&(t[0].el.style.display="block",this.setContent(t[0],this.currIndex-1)),t[2]&&(t[2].el.style.display="block",this.setContent(t[2],this.currIndex+1)),this.appendHeavy(),this.contentLoader.updateLazy(),this.events.add(window,"resize",this.ni.bind(this)),this.events.add(window,"scroll",this.oi.bind(this)),this.dispatch("bindEvents")})),this.mainScroll.itemHolders[1]&&this.setContent(this.mainScroll.itemHolders[1],this.currIndex),this.dispatch("change"),this.opener.open(),this.dispatch("afterInit"),!0}getLoopedIndex(t){const i=this.getNumItems();return this.options.loop&&(t>i-1&&(t-=i),t<0&&(t+=i)),n(t,0,i-1)}appendHeavy(){this.mainScroll.itemHolders.forEach((t=>{var i;null===(i=t.slide)||void 0===i||i.appendHeavy()}))}goTo(t){this.mainScroll.moveIndexBy(this.getLoopedIndex(t)-this.potentialIndex)}next(){this.goTo(this.potentialIndex+1)}prev(){this.goTo(this.potentialIndex-1)}zoomTo(...t){var i;null===(i=this.currSlide)||void 0===i||i.zoomTo(...t)}toggleZoom(){var t;null===(t=this.currSlide)||void 0===t||t.toggleZoom()}close(){this.opener.isOpen&&!this.isDestroying&&(this.isDestroying=!0,this.dispatch("close"),this.events.removeAll(),this.opener.close())}destroy(){var t;if(!this.isDestroying)return this.options.showHideAnimationType="none",void this.close();this.dispatch("destroy"),this.Yt={},this.scrollWrap&&(this.scrollWrap.ontouchmove=null,this.scrollWrap.ontouchend=null),null===(t=this.element)||void 0===t||t.remove(),this.mainScroll.itemHolders.forEach((t=>{var i;null===(i=t.slide)||void 0===i||i.destroy()})),this.contentLoader.destroy(),this.events.removeAll()}refreshSlideContent(t){this.contentLoader.removeByIndex(t),this.mainScroll.itemHolders.forEach(((i,s)=>{var h,e;let n=(null!==(h=null===(e=this.currSlide)||void 0===e?void 0:e.index)&&void 0!==h?h:0)-1+s;var o;(this.canLoop()&&(n=this.getLoopedIndex(n)),n===t)&&(this.setContent(i,t,!0),1===s&&(this.currSlide=i.slide,null===(o=i.slide)||void 0===o||o.setIsActive(!0)))})),this.dispatch("change")}setContent(t,i,s){if(this.canLoop()&&(i=this.getLoopedIndex(i)),t.slide){if(t.slide.index===i&&!s)return;t.slide.destroy(),t.slide=void 0}if(!this.canLoop()&&(i<0||i>=this.getNumItems()))return;const h=this.getItemData(i);t.slide=new b(h,i,this),i===this.currIndex&&(this.currSlide=t.slide),t.slide.append(t.el)}getViewportCenterPoint(){return{x:this.viewportSize.x/2,y:this.viewportSize.y/2}}updateSize(t){if(this.isDestroying)return;const s=w(this.options,this);!t&&e(s,this.si)||(i(this.si,s),this.dispatch("beforeResize"),i(this.viewportSize,this.si),this.oi(),this.dispatch("viewportSize"),this.mainScroll.resize(this.opener.isOpen),!this.hasMouse&&window.matchMedia("(any-hover: hover)").matches&&this.mouseDetected(),this.dispatch("resize"))}applyBgOpacity(t){this.bgOpacity=Math.max(t,0),this.bg&&(this.bg.style.opacity=String(this.bgOpacity*this.options.bgOpacity))}mouseDetected(){var t;this.hasMouse||(this.hasMouse=!0,null===(t=this.element)||void 0===t||t.classList.add("pswp--has_mouse"))}ni(){this.updateSize(),/iPhone|iPad|iPod/i.test(window.navigator.userAgent)&&setTimeout((()=>{this.updateSize()}),500)}oi(){this.setScrollOffset(0,window.pageYOffset)}setScrollOffset(t,i){this.offset.x=t,this.offset.y=i,this.dispatch("updateScrollOffset")}ei(){this.element=t("pswp","div"),this.element.setAttribute("tabindex","-1"),this.element.setAttribute("role","dialog"),this.template=this.element,this.bg=t("pswp__bg","div",this.element),this.scrollWrap=t("pswp__scroll-wrap","section",this.element),this.container=t("pswp__container","div",this.scrollWrap),this.scrollWrap.setAttribute("aria-roledescription","carousel"),this.container.setAttribute("aria-live","off"),this.container.setAttribute("id","pswp__items"),this.mainScroll.appendHolders(),this.ui=new W(this),this.ui.init(),(this.options.appendToEl||document.body).appendChild(this.element)}getThumbBounds(){return function(t,i,s){const h=s.dispatch("thumbBounds",{index:t,itemData:i,instance:s});if(h.thumbBounds)return h.thumbBounds;const{element:e}=i;let n,o;if(e&&!1!==s.options.thumbSelector){const t=s.options.thumbSelector||"img";o=e.matches(t)?e:e.querySelector(t)}return o=s.applyFilters("thumbEl",o,i,t),o&&(n=i.thumbCropped?function(t,i,s){const h=t.getBoundingClientRect(),e=h.width/i,n=h.height/s,o=e>n?e:n,r=(h.width-i*o)/2,a=(h.height-s*o)/2,l={x:h.left+r,y:h.top+a,w:i*o};return l.innerRect={w:h.width,h:h.height,x:r,y:a},l}(o,i.width||i.w||0,i.height||i.h||0):function(t){const i=t.getBoundingClientRect();return{x:i.left,y:i.top,w:i.width}}(o)),s.applyFilters("thumbBounds",n,i,t)}(this.currIndex,this.currSlide?this.currSlide.data:this.hi,this)}canLoop(){return this.options.loop&&this.getNumItems()>2}ii(t){return window.matchMedia("(prefers-reduced-motion), (update: slow)").matches&&(t.showHideAnimationType="none",t.zoomAnimationDuration=0),{...st,...t}}}}));
;/*!
* PhotoSwipe Lightbox 5.4.4 - https://photoswipe.com
* (c) 2024 Dmytro Semenov
*/
!function(t,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i():"function"==typeof define&&define.amd?define(i):(t="undefined"!=typeof globalThis?globalThis:t||self).PhotoSwipeLightbox=i()}(this,(function(){"use strict";function t(t,i,s){const h=document.createElement(i);return t&&(h.className=t),s&&s.appendChild(h),h}function i(t,i,s){t.style.width="number"==typeof i?`${i}px`:i,t.style.height="number"==typeof s?`${s}px`:s}const s="idle",h="loading",e="loaded",n="error";function o(t,i,s=document){let h=[];if(t instanceof Element)h=[t];else if(t instanceof NodeList||Array.isArray(t))h=Array.from(t);else{const e="string"==typeof t?t:i;e&&(h=Array.from(s.querySelectorAll(e)))}return h}function r(){return!(!navigator.vendor||!navigator.vendor.match(/apple/i))}class l{constructor(t,i){this.type=t,this.defaultPrevented=!1,i&&Object.assign(this,i)}preventDefault(){this.defaultPrevented=!0}}class a{constructor(i,s){if(this.element=t("pswp__img pswp__img--placeholder",i?"img":"div",s),i){const t=this.element;t.decoding="async",t.alt="",t.src=i,t.setAttribute("role","presentation")}this.element.setAttribute("aria-hidden","true")}setDisplayedSize(t,s){this.element&&("IMG"===this.element.tagName?(i(this.element,250,"auto"),this.element.style.transformOrigin="0 0",this.element.style.transform=function(t,i,s){let h=`translate3d(${t}px,${i||0}px,0)`;return void 0!==s&&(h+=` scale3d(${s},${s},1)`),h}(0,0,t/250)):i(this.element,t,s))}destroy(){var t;null!==(t=this.element)&&void 0!==t&&t.parentNode&&this.element.remove(),this.element=null}}class d{constructor(t,i,h){this.instance=i,this.data=t,this.index=h,this.element=void 0,this.placeholder=void 0,this.slide=void 0,this.displayedImageWidth=0,this.displayedImageHeight=0,this.width=Number(this.data.w)||Number(this.data.width)||0,this.height=Number(this.data.h)||Number(this.data.height)||0,this.isAttached=!1,this.hasSlide=!1,this.isDecoding=!1,this.state=s,this.data.type?this.type=this.data.type:this.data.src?this.type="image":this.type="html",this.instance.dispatch("contentInit",{content:this})}removePlaceholder(){this.placeholder&&!this.keepPlaceholder()&&setTimeout((()=>{this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0)}),1e3)}load(i,s){if(this.slide&&this.usePlaceholder())if(this.placeholder){const t=this.placeholder.element;t&&!t.parentElement&&this.slide.container.prepend(t)}else{const t=this.instance.applyFilters("placeholderSrc",!(!this.data.msrc||!this.slide.isFirstSlide)&&this.data.msrc,this);this.placeholder=new a(t,this.slide.container)}this.element&&!s||this.instance.dispatch("contentLoad",{content:this,isLazy:i}).defaultPrevented||(this.isImageContent()?(this.element=t("pswp__img","img"),this.displayedImageWidth&&this.loadImage(i)):(this.element=t("pswp__content","div"),this.element.innerHTML=this.data.html||""),s&&this.slide&&this.slide.updateContentSize(!0))}loadImage(t){var i,s;if(!this.isImageContent()||!this.element||this.instance.dispatch("contentLoadImage",{content:this,isLazy:t}).defaultPrevented)return;const e=this.element;this.updateSrcsetSizes(),this.data.srcset&&(e.srcset=this.data.srcset),e.src=null!==(i=this.data.src)&&void 0!==i?i:"",e.alt=null!==(s=this.data.alt)&&void 0!==s?s:"",this.state=h,e.complete?this.onLoaded():(e.onload=()=>{this.onLoaded()},e.onerror=()=>{this.onError()})}setSlide(t){this.slide=t,this.hasSlide=!0,this.instance=t.pswp}onLoaded(){this.state=e,this.slide&&this.element&&(this.instance.dispatch("loadComplete",{slide:this.slide,content:this}),this.slide.isActive&&this.slide.heavyAppended&&!this.element.parentNode&&(this.append(),this.slide.updateContentSize(!0)),this.state!==e&&this.state!==n||this.removePlaceholder())}onError(){this.state=n,this.slide&&(this.displayError(),this.instance.dispatch("loadComplete",{slide:this.slide,isError:!0,content:this}),this.instance.dispatch("loadError",{slide:this.slide,content:this}))}isLoading(){return this.instance.applyFilters("isContentLoading",this.state===h,this)}isError(){return this.state===n}isImageContent(){return"image"===this.type}setDisplayedSize(t,s){if(this.element&&(this.placeholder&&this.placeholder.setDisplayedSize(t,s),!this.instance.dispatch("contentResize",{content:this,width:t,height:s}).defaultPrevented&&(i(this.element,t,s),this.isImageContent()&&!this.isError()))){const i=!this.displayedImageWidth&&t;this.displayedImageWidth=t,this.displayedImageHeight=s,i?this.loadImage(!1):this.updateSrcsetSizes(),this.slide&&this.instance.dispatch("imageSizeChange",{slide:this.slide,width:t,height:s,content:this})}}isZoomable(){return this.instance.applyFilters("isContentZoomable",this.isImageContent()&&this.state!==n,this)}updateSrcsetSizes(){if(!this.isImageContent()||!this.element||!this.data.srcset)return;const t=this.element,i=this.instance.applyFilters("srcsetSizesWidth",this.displayedImageWidth,this);(!t.dataset.largestUsedSize||i>parseInt(t.dataset.largestUsedSize,10))&&(t.sizes=i+"px",t.dataset.largestUsedSize=String(i))}usePlaceholder(){return this.instance.applyFilters("useContentPlaceholder",this.isImageContent(),this)}lazyLoad(){this.instance.dispatch("contentLazyLoad",{content:this}).defaultPrevented||this.load(!0)}keepPlaceholder(){return this.instance.applyFilters("isKeepingPlaceholder",this.isLoading(),this)}destroy(){this.hasSlide=!1,this.slide=void 0,this.instance.dispatch("contentDestroy",{content:this}).defaultPrevented||(this.remove(),this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0),this.isImageContent()&&this.element&&(this.element.onload=null,this.element.onerror=null,this.element=void 0))}displayError(){if(this.slide){var i,s;let h=t("pswp__error-msg","div");h.innerText=null!==(i=null===(s=this.instance.options)||void 0===s?void 0:s.errorMsg)&&void 0!==i?i:"",h=this.instance.applyFilters("contentErrorElement",h,this),this.element=t("pswp__content pswp__error-msg-container","div"),this.element.appendChild(h),this.slide.container.innerText="",this.slide.container.appendChild(this.element),this.slide.updateContentSize(!0),this.removePlaceholder()}}append(){if(this.isAttached||!this.element)return;if(this.isAttached=!0,this.state===n)return void this.displayError();if(this.instance.dispatch("contentAppend",{content:this}).defaultPrevented)return;const t="decode"in this.element;this.isImageContent()?t&&this.slide&&(!this.slide.isActive||r())?(this.isDecoding=!0,this.element.decode().catch((()=>{})).finally((()=>{this.isDecoding=!1,this.appendImage()}))):this.appendImage():this.slide&&!this.element.parentNode&&this.slide.container.appendChild(this.element)}activate(){!this.instance.dispatch("contentActivate",{content:this}).defaultPrevented&&this.slide&&(this.isImageContent()&&this.isDecoding&&!r()?this.appendImage():this.isError()&&this.load(!1,!0),this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","false"))}deactivate(){this.instance.dispatch("contentDeactivate",{content:this}),this.slide&&this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","true")}remove(){this.isAttached=!1,this.instance.dispatch("contentRemove",{content:this}).defaultPrevented||(this.element&&this.element.parentNode&&this.element.remove(),this.placeholder&&this.placeholder.element&&this.placeholder.element.remove())}appendImage(){this.isAttached&&(this.instance.dispatch("contentAppendImage",{content:this}).defaultPrevented||(this.slide&&this.element&&!this.element.parentNode&&this.slide.container.appendChild(this.element),this.state!==e&&this.state!==n||this.removePlaceholder()))}}function c(t,i,s,h,e){let n=0;if(i.paddingFn)n=i.paddingFn(s,h,e)[t];else if(i.padding)n=i.padding[t];else{const s="padding"+t[0].toUpperCase()+t.slice(1);i[s]&&(n=i[s])}return Number(n)||0}class u{constructor(t,i,s,h){this.pswp=h,this.options=t,this.itemData=i,this.index=s,this.panAreaSize=null,this.elementSize=null,this.fit=1,this.fill=1,this.vFill=1,this.initial=1,this.secondary=1,this.max=1,this.min=1}update(t,i,s){const h={x:t,y:i};this.elementSize=h,this.panAreaSize=s;const e=s.x/h.x,n=s.y/h.y;this.fit=Math.min(1,e<n?e:n),this.fill=Math.min(1,e>n?e:n),this.vFill=Math.min(1,n),this.initial=this.t(),this.secondary=this.i(),this.max=Math.max(this.initial,this.secondary,this.o()),this.min=Math.min(this.fit,this.initial,this.secondary),this.pswp&&this.pswp.dispatch("zoomLevelsUpdate",{zoomLevels:this,slideData:this.itemData})}l(t){const i=t+"ZoomLevel",s=this.options[i];if(s)return"function"==typeof s?s(this):"fill"===s?this.fill:"fit"===s?this.fit:Number(s)}i(){let t=this.l("secondary");return t||(t=Math.min(1,3*this.fit),this.elementSize&&t*this.elementSize.x>4e3&&(t=4e3/this.elementSize.x),t)}t(){return this.l("initial")||this.fit}o(){return this.l("max")||Math.max(1,4*this.fit)}}function p(t,i,s){const h=i.createContentFromData(t,s);let e;const{options:n}=i;if(n){let o;e=new u(n,t,-1),o=i.pswp?i.pswp.viewportSize:function(t,i){if(t.getViewportSizeFn){const s=t.getViewportSizeFn(t,i);if(s)return s}return{x:document.documentElement.clientWidth,y:window.innerHeight}}(n,i);const r=function(t,i,s,h){return{x:i.x-c("left",t,i,s,h)-c("right",t,i,s,h),y:i.y-c("top",t,i,s,h)-c("bottom",t,i,s,h)}}(n,o,t,s);e.update(h.width,h.height,r)}return h.lazyLoad(),e&&h.setDisplayedSize(Math.ceil(h.width*e.initial),Math.ceil(h.height*e.initial)),h}return class extends class extends class{constructor(){this.u={},this.p={},this.pswp=void 0,this.options=void 0}addFilter(t,i,s=100){var h,e,n;this.p[t]||(this.p[t]=[]),null===(h=this.p[t])||void 0===h||h.push({fn:i,priority:s}),null===(e=this.p[t])||void 0===e||e.sort(((t,i)=>t.priority-i.priority)),null===(n=this.pswp)||void 0===n||n.addFilter(t,i,s)}removeFilter(t,i){this.p[t]&&(this.p[t]=this.p[t].filter((t=>t.fn!==i))),this.pswp&&this.pswp.removeFilter(t,i)}applyFilters(t,...i){var s;return null===(s=this.p[t])||void 0===s||s.forEach((t=>{i[0]=t.fn.apply(this,i)})),i[0]}on(t,i){var s,h;this.u[t]||(this.u[t]=[]),null===(s=this.u[t])||void 0===s||s.push(i),null===(h=this.pswp)||void 0===h||h.on(t,i)}off(t,i){var s;this.u[t]&&(this.u[t]=this.u[t].filter((t=>i!==t))),null===(s=this.pswp)||void 0===s||s.off(t,i)}dispatch(t,i){var s;if(this.pswp)return this.pswp.dispatch(t,i);const h=new l(t,i);return null===(s=this.u[t])||void 0===s||s.forEach((t=>{t.call(this,h)})),h}}{getNumItems(){var t;let i=0;const s=null===(t=this.options)||void 0===t?void 0:t.dataSource;s&&"length"in s?i=s.length:s&&"gallery"in s&&(s.items||(s.items=this.v(s.gallery)),s.items&&(i=s.items.length));const h=this.dispatch("numItems",{dataSource:s,numItems:i});return this.applyFilters("numItems",h.numItems,s)}createContentFromData(t,i){return new d(t,this,i)}getItemData(t){var i;const s=null===(i=this.options)||void 0===i?void 0:i.dataSource;let h={};Array.isArray(s)?h=s[t]:s&&"gallery"in s&&(s.items||(s.items=this.v(s.gallery)),h=s.items[t]);let e=h;e instanceof Element&&(e=this.m(e));const n=this.dispatch("itemData",{itemData:e||{},index:t});return this.applyFilters("itemData",n.itemData,t)}v(t){var i,s;return null!==(i=this.options)&&void 0!==i&&i.children||null!==(s=this.options)&&void 0!==s&&s.childSelector?o(this.options.children,this.options.childSelector,t)||[]:[t]}m(t){const i={element:t},s="A"===t.tagName?t:t.querySelector("a");if(s){i.src=s.dataset.pswpSrc||s.href,s.dataset.pswpSrcset&&(i.srcset=s.dataset.pswpSrcset),i.width=s.dataset.pswpWidth?parseInt(s.dataset.pswpWidth,10):0,i.height=s.dataset.pswpHeight?parseInt(s.dataset.pswpHeight,10):0,i.w=i.width,i.h=i.height,s.dataset.pswpType&&(i.type=s.dataset.pswpType);const e=t.querySelector("img");var h;if(e)i.msrc=e.currentSrc||e.src,i.alt=null!==(h=e.getAttribute("alt"))&&void 0!==h?h:"";(s.dataset.pswpCropped||s.dataset.cropped)&&(i.thumbCropped=!0)}return this.applyFilters("domItemData",i,t,s)}lazyLoadData(t,i){return p(t,this,i)}}{constructor(t){super(),this.options=t||{},this.g=0,this.shouldOpen=!1,this._=void 0,this.onThumbnailsClick=this.onThumbnailsClick.bind(this)}init(){o(this.options.gallery,this.options.gallerySelector).forEach((t=>{t.addEventListener("click",this.onThumbnailsClick,!1)}))}onThumbnailsClick(t){if(function(t){return"button"in t&&1===t.button||t.ctrlKey||t.metaKey||t.altKey||t.shiftKey}(t)||window.pswp)return;let i={x:t.clientX,y:t.clientY};i.x||i.y||(i=null);let s=this.getClickedIndex(t);s=this.applyFilters("clickedIndex",s,t,this);const h={gallery:t.currentTarget};s>=0&&(t.preventDefault(),this.loadAndOpen(s,h,i))}getClickedIndex(t){if(this.options.getClickedIndexFn)return this.options.getClickedIndexFn.call(this,t);const i=t.target,s=o(this.options.children,this.options.childSelector,t.currentTarget).findIndex((t=>t===i||t.contains(i)));return-1!==s?s:this.options.children||this.options.childSelector?-1:0}loadAndOpen(t,i,s){if(window.pswp||!this.options)return!1;if(!i&&this.options.gallery&&this.options.children){const t=o(this.options.gallery);t[0]&&(i={gallery:t[0]})}return this.options.index=t,this.options.initialPointerPos=s,this.shouldOpen=!0,this.preload(t,i),!0}preload(t,i){const{options:s}=this;i&&(s.dataSource=i);const h=[],e=typeof s.pswpModule;if("function"==typeof(n=s.pswpModule)&&n.prototype&&n.prototype.goTo)h.push(Promise.resolve(s.pswpModule));else{if("string"===e)throw new Error("pswpModule as string is no longer supported");if("function"!==e)throw new Error("pswpModule is not valid");h.push(s.pswpModule())}var n;"function"==typeof s.openPromise&&h.push(s.openPromise()),!1!==s.preloadFirstSlide&&t>=0&&(this._=function(t,i){const s=i.getItemData(t);if(!i.dispatch("lazyLoadSlide",{index:t,itemData:s}).defaultPrevented)return p(s,i,t)}(t,this));const o=++this.g;Promise.all(h).then((t=>{if(this.shouldOpen){const i=t[0];this.I(i,o)}}))}I(t,i){if(i!==this.g&&this.shouldOpen)return;if(this.shouldOpen=!1,window.pswp)return;const s="object"==typeof t?new t.default(this.options):new t(this.options);this.pswp=s,window.pswp=s,Object.keys(this.u).forEach((t=>{var i;null===(i=this.u[t])||void 0===i||i.forEach((i=>{s.on(t,i)}))})),Object.keys(this.p).forEach((t=>{var i;null===(i=this.p[t])||void 0===i||i.forEach((i=>{s.addFilter(t,i.fn,i.priority)}))})),this._&&(s.contentLoader.addToCache(this._),this._=void 0),s.on("destroy",(()=>{this.pswp=void 0,delete window.pswp})),s.init()}destroy(){var t;null===(t=this.pswp)||void 0===t||t.destroy(),this.shouldOpen=!1,this.u={},o(this.options.gallery,this.options.gallerySelector).forEach((t=>{t.removeEventListener("click",this.onThumbnailsClick,!1)}))}}}));
;function t(t,i,e){return Math.max(t,Math.min(i,e))}var i=class{isRunning=!1;value=0;from=0;to=0;currentTime=0;lerp;duration;easing;onUpdate;advance(i){if(!this.isRunning)return;let e=!1;if(this.duration&&this.easing){this.currentTime+=i;const s=t(0,this.currentTime/this.duration,1);e=s>=1;const o=e?1:this.easing(s);this.value=this.from+(this.to-this.from)*o}else this.lerp?(this.value=function(t,i,e,s){return function(t,i,e){return(1-e)*t+e*i}(t,i,1-Math.exp(-e*s))}(this.value,this.to,60*this.lerp,i),Math.round(this.value)===this.to&&(this.value=this.to,e=!0)):(this.value=this.to,e=!0);e&&this.stop(),this.onUpdate?.(this.value,e)}stop(){this.isRunning=!1}fromTo(t,i,{lerp:e,duration:s,easing:o,onStart:n,onUpdate:r}){this.from=this.value=t,this.to=i,this.lerp=e,this.duration=s,this.easing=o,this.currentTime=0,this.isRunning=!0,n?.(),this.onUpdate=r}};var e=class{constructor(t,i,{autoResize:e=!0,debounce:s=250}={}){this.wrapper=t,this.content=i,e&&(this.debouncedResize=function(t,i){let e;return function(...s){let o=this;clearTimeout(e),e=setTimeout((()=>{e=void 0,t.apply(o,s)}),i)}}(this.resize,s),this.wrapper instanceof Window?window.addEventListener("resize",this.debouncedResize,!1):(this.wrapperResizeObserver=new ResizeObserver(this.debouncedResize),this.wrapperResizeObserver.observe(this.wrapper)),this.contentResizeObserver=new ResizeObserver(this.debouncedResize),this.contentResizeObserver.observe(this.content)),this.resize()}width=0;height=0;scrollHeight=0;scrollWidth=0;debouncedResize;wrapperResizeObserver;contentResizeObserver;destroy(){this.wrapperResizeObserver?.disconnect(),this.contentResizeObserver?.disconnect(),this.wrapper===window&&this.debouncedResize&&window.removeEventListener("resize",this.debouncedResize,!1)}resize=()=>{this.onWrapperResize(),this.onContentResize()};onWrapperResize=()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)};onContentResize=()=>{this.wrapper instanceof Window?(this.scrollHeight=this.content.scrollHeight,this.scrollWidth=this.content.scrollWidth):(this.scrollHeight=this.wrapper.scrollHeight,this.scrollWidth=this.wrapper.scrollWidth)};get limit(){return{x:this.scrollWidth-this.width,y:this.scrollHeight-this.height}}},s=class{events={};emit(t,...i){let e=this.events[t]||[];for(let t=0,s=e.length;t<s;t++)e[t]?.(...i)}on(t,i){return this.events[t]?.push(i)||(this.events[t]=[i]),()=>{this.events[t]=this.events[t]?.filter((t=>i!==t))}}off(t,i){this.events[t]=this.events[t]?.filter((t=>i!==t))}destroy(){this.events={}}},o=100/6,n={passive:!1},r=class{constructor(t,i={wheelMultiplier:1,touchMultiplier:1}){this.element=t,this.options=i,window.addEventListener("resize",this.onWindowResize,!1),this.onWindowResize(),this.element.addEventListener("wheel",this.onWheel,n),this.element.addEventListener("touchstart",this.onTouchStart,n),this.element.addEventListener("touchmove",this.onTouchMove,n),this.element.addEventListener("touchend",this.onTouchEnd,n)}touchStart={x:0,y:0};lastDelta={x:0,y:0};window={width:0,height:0};emitter=new s;on(t,i){return this.emitter.on(t,i)}destroy(){this.emitter.destroy(),window.removeEventListener("resize",this.onWindowResize,!1),this.element.removeEventListener("wheel",this.onWheel,n),this.element.removeEventListener("touchstart",this.onTouchStart,n),this.element.removeEventListener("touchmove",this.onTouchMove,n),this.element.removeEventListener("touchend",this.onTouchEnd,n)}onTouchStart=t=>{const{clientX:i,clientY:e}=t.targetTouches?t.targetTouches[0]:t;this.touchStart.x=i,this.touchStart.y=e,this.lastDelta={x:0,y:0},this.emitter.emit("scroll",{deltaX:0,deltaY:0,event:t})};onTouchMove=t=>{const{clientX:i,clientY:e}=t.targetTouches?t.targetTouches[0]:t,s=-(i-this.touchStart.x)*this.options.touchMultiplier,o=-(e-this.touchStart.y)*this.options.touchMultiplier;this.touchStart.x=i,this.touchStart.y=e,this.lastDelta={x:s,y:o},this.emitter.emit("scroll",{deltaX:s,deltaY:o,event:t})};onTouchEnd=t=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:t})};onWheel=t=>{let{deltaX:i,deltaY:e,deltaMode:s}=t;i*=1===s?o:2===s?this.window.width:1,e*=1===s?o:2===s?this.window.height:1,i*=this.options.wheelMultiplier,e*=this.options.wheelMultiplier,this.emitter.emit("scroll",{deltaX:i,deltaY:e,event:t})};onWindowResize=()=>{this.window={width:window.innerWidth,height:window.innerHeight}}},Lenis=class{_isScrolling=!1;_isStopped=!1;_isLocked=!1;_preventNextNativeScrollEvent=!1;_resetVelocityTimeout=null;__rafID=null;isTouching;time=0;userData={};lastVelocity=0;velocity=0;direction=0;options;targetScroll;animatedScroll;animate=new i;emitter=new s;dimensions;virtualScroll;constructor({wrapper:t=window,content:i=document.documentElement,eventsTarget:s=t,smoothWheel:o=!0,syncTouch:n=!1,syncTouchLerp:l=.075,touchInertiaMultiplier:h=35,duration:a,easing:c=t=>Math.min(1,1.001-Math.pow(2,-10*t)),lerp:p=.1,infinite:d=!1,orientation:u="vertical",gestureOrientation:m="vertical",touchMultiplier:v=1,wheelMultiplier:S=1,autoResize:w=!0,prevent:g,virtualScroll:f,overscroll:y=!0,autoRaf:E=!1,anchors:T=!1,__experimental__naiveDimensions:z=!1}={}){window.lenisVersion="1.1.19",t&&t!==document.documentElement||(t=window),this.options={wrapper:t,content:i,eventsTarget:s,smoothWheel:o,syncTouch:n,syncTouchLerp:l,touchInertiaMultiplier:h,duration:a,easing:c,lerp:p,infinite:d,gestureOrientation:m,orientation:u,touchMultiplier:v,wheelMultiplier:S,autoResize:w,prevent:g,virtualScroll:f,overscroll:y,autoRaf:E,anchors:T,__experimental__naiveDimensions:z},this.dimensions=new e(t,i,{autoResize:w}),this.updateClassName(),this.targetScroll=this.animatedScroll=this.actualScroll,this.options.wrapper.addEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.addEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.anchors&&this.options.wrapper===window&&this.options.wrapper.addEventListener("click",this.onClick,!1),this.options.wrapper.addEventListener("pointerdown",this.onPointerDown,!1),this.virtualScroll=new r(s,{touchMultiplier:v,wheelMultiplier:S}),this.virtualScroll.on("scroll",this.onVirtualScroll),this.options.autoRaf&&(this.__rafID=requestAnimationFrame(this.raf))}destroy(){this.emitter.destroy(),this.options.wrapper.removeEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.removeEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.wrapper.removeEventListener("pointerdown",this.onPointerDown,!1),this.options.anchors&&this.options.wrapper===window&&this.options.wrapper.removeEventListener("click",this.onClick,!1),this.virtualScroll.destroy(),this.dimensions.destroy(),this.cleanUpClassName(),this.__rafID&&cancelAnimationFrame(this.__rafID)}on(t,i){return this.emitter.on(t,i)}off(t,i){return this.emitter.off(t,i)}onScrollEnd=t=>{t instanceof CustomEvent||"smooth"!==this.isScrolling&&!1!==this.isScrolling||t.stopPropagation()};dispatchScrollendEvent=()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))};setScroll(t){this.isHorizontal?this.options.wrapper.scrollTo({left:t,behavior:"instant"}):this.options.wrapper.scrollTo({top:t,behavior:"instant"})}onClick=t=>{const i=t.composedPath().find((t=>t instanceof HTMLAnchorElement&&t.getAttribute("href")?.startsWith("#")));if(i){const t=i.getAttribute("href");if(t){const i="object"==typeof this.options.anchors&&this.options.anchors?this.options.anchors:void 0;this.scrollTo(t,i)}}};onPointerDown=t=>{1===t.button&&this.reset()};onVirtualScroll=t=>{if("function"==typeof this.options.virtualScroll&&!1===this.options.virtualScroll(t))return;const{deltaX:i,deltaY:e,event:s}=t;if(this.emitter.emit("virtual-scroll",{deltaX:i,deltaY:e,event:s}),s.ctrlKey)return;if(s.lenisStopPropagation)return;const o=s.type.includes("touch"),n=s.type.includes("wheel");this.isTouching="touchstart"===s.type||"touchmove"===s.type;const r=0===i&&0===e;if(this.options.syncTouch&&o&&"touchstart"===s.type&&r&&!this.isStopped&&!this.isLocked)return void this.reset();const l="vertical"===this.options.gestureOrientation&&0===e||"horizontal"===this.options.gestureOrientation&&0===i;if(r||l)return;let h=s.composedPath();h=h.slice(0,h.indexOf(this.rootElement));const a=this.options.prevent;if(h.find((t=>t instanceof HTMLElement&&("function"==typeof a&&a?.(t)||t.hasAttribute?.("data-lenis-prevent")||o&&t.hasAttribute?.("data-lenis-prevent-touch")||n&&t.hasAttribute?.("data-lenis-prevent-wheel")))))return;if(this.isStopped||this.isLocked)return void s.preventDefault();if(!(this.options.syncTouch&&o||this.options.smoothWheel&&n))return this.isScrolling="native",this.animate.stop(),void(s.lenisStopPropagation=!0);let c=e;"both"===this.options.gestureOrientation?c=Math.abs(e)>Math.abs(i)?e:i:"horizontal"===this.options.gestureOrientation&&(c=i),(!this.options.overscroll||this.options.infinite||this.options.wrapper!==window&&(this.animatedScroll>0&&this.animatedScroll<this.limit||0===this.animatedScroll&&e>0||this.animatedScroll===this.limit&&e<0))&&(s.lenisStopPropagation=!0),s.preventDefault();const p=o&&this.options.syncTouch,d=o&&"touchend"===s.type&&Math.abs(c)>5;d&&(c=this.velocity*this.options.touchInertiaMultiplier),this.scrollTo(this.targetScroll+c,{programmatic:!1,...p?{lerp:d?this.options.syncTouchLerp:1}:{lerp:this.options.lerp,duration:this.options.duration,easing:this.options.easing}})};resize(){this.dimensions.resize(),this.animatedScroll=this.targetScroll=this.actualScroll,this.emit()}emit(){this.emitter.emit("scroll",this)}onNativeScroll=()=>{if(null!==this._resetVelocityTimeout&&(clearTimeout(this._resetVelocityTimeout),this._resetVelocityTimeout=null),this._preventNextNativeScrollEvent)this._preventNextNativeScrollEvent=!1;else if(!1===this.isScrolling||"native"===this.isScrolling){const t=this.animatedScroll;this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity,this.velocity=this.animatedScroll-t,this.direction=Math.sign(this.animatedScroll-t),this.isStopped||(this.isScrolling="native"),this.emit(),0!==this.velocity&&(this._resetVelocityTimeout=setTimeout((()=>{this.lastVelocity=this.velocity,this.velocity=0,this.isScrolling=!1,this.emit()}),400))}};reset(){this.isLocked=!1,this.isScrolling=!1,this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity=0,this.animate.stop()}start(){this.isStopped&&(this.reset(),this.isStopped=!1)}stop(){this.isStopped||(this.reset(),this.isStopped=!0)}raf=t=>{const i=t-(this.time||t);this.time=t,this.animate.advance(.001*i),this.options.autoRaf&&(this.__rafID=requestAnimationFrame(this.raf))};scrollTo(i,{offset:e=0,immediate:s=!1,lock:o=!1,duration:n=this.options.duration,easing:r=this.options.easing,lerp:l=this.options.lerp,onStart:h,onComplete:a,force:c=!1,programmatic:p=!0,userData:d}={}){if(!this.isStopped&&!this.isLocked||c){if("string"==typeof i&&["top","left","start"].includes(i))i=0;else if("string"==typeof i&&["bottom","right","end"].includes(i))i=this.limit;else{let t;if("string"==typeof i?t=document.querySelector(i):i instanceof HTMLElement&&i?.nodeType&&(t=i),t){if(this.options.wrapper!==window){const t=this.rootElement.getBoundingClientRect();e-=this.isHorizontal?t.left:t.top}const s=t.getBoundingClientRect();i=(this.isHorizontal?s.left:s.top)+this.animatedScroll}}if("number"==typeof i){if(i+=e,i=Math.round(i),this.options.infinite?p&&(this.targetScroll=this.animatedScroll=this.scroll):i=t(0,i,this.limit),i===this.targetScroll)return h?.(this),void a?.(this);if(this.userData=d??{},s)return this.animatedScroll=this.targetScroll=i,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),a?.(this),this.userData={},void requestAnimationFrame((()=>{this.dispatchScrollendEvent()}));p||(this.targetScroll=i),this.animate.fromTo(this.animatedScroll,i,{duration:n,easing:r,lerp:l,onStart:()=>{o&&(this.isLocked=!0),this.isScrolling="smooth",h?.(this)},onUpdate:(t,i)=>{this.isScrolling="smooth",this.lastVelocity=this.velocity,this.velocity=t-this.animatedScroll,this.direction=Math.sign(this.velocity),this.animatedScroll=t,this.setScroll(this.scroll),p&&(this.targetScroll=t),i||this.emit(),i&&(this.reset(),this.emit(),a?.(this),this.userData={},requestAnimationFrame((()=>{this.dispatchScrollendEvent()})),this.preventNextNativeScrollEvent())}})}}}preventNextNativeScrollEvent(){this._preventNextNativeScrollEvent=!0,requestAnimationFrame((()=>{this._preventNextNativeScrollEvent=!1}))}get rootElement(){return this.options.wrapper===window?document.documentElement:this.options.wrapper}get limit(){return this.options.__experimental__naiveDimensions?this.isHorizontal?this.rootElement.scrollWidth-this.rootElement.clientWidth:this.rootElement.scrollHeight-this.rootElement.clientHeight:this.dimensions.limit[this.isHorizontal?"x":"y"]}get isHorizontal(){return"horizontal"===this.options.orientation}get actualScroll(){const t=this.options.wrapper;return this.isHorizontal?t.scrollX??t.scrollLeft:t.scrollY??t.scrollTop}get scroll(){return this.options.infinite?(t=this.animatedScroll,i=this.limit,(t%i+i)%i):this.animatedScroll;var t,i}get progress(){return 0===this.limit?1:this.scroll/this.limit}get isScrolling(){return this._isScrolling}set isScrolling(t){this._isScrolling!==t&&(this._isScrolling=t,this.updateClassName())}get isStopped(){return this._isStopped}set isStopped(t){this._isStopped!==t&&(this._isStopped=t,this.updateClassName())}get isLocked(){return this._isLocked}set isLocked(t){this._isLocked!==t&&(this._isLocked=t,this.updateClassName())}get isSmooth(){return"smooth"===this.isScrolling}get className(){let t="lenis";return this.isStopped&&(t+=" lenis-stopped"),this.isLocked&&(t+=" lenis-locked"),this.isScrolling&&(t+=" lenis-scrolling"),"smooth"===this.isScrolling&&(t+=" lenis-smooth"),t}updateClassName(){this.cleanUpClassName(),this.rootElement.className=`${this.rootElement.className} ${this.className}`.trim()}cleanUpClassName(){this.rootElement.className=this.rootElement.className.replace(/lenis(-\w+)?/g,"").trim()}};globalThis.Lenis=Lenis,globalThis.Lenis.prototype=Lenis.prototype;//# sourceMappingURL=lenis.min.js.map
;window.lenisInstance=new Lenis({autoRaf:true,lerp:0.1,duration:1.2,wheelMultiplier:1,easing:x=>Math.min(1,1.001-Math.pow(2,-10*x))})
;