var GP=function(t){"use strict";let e=t=>{let e;let o=new Set,i=(t,i)=>{let n="function"==typeof t?t(e):t;if(!Object.is(n,e)){let t=e;e=(null!=i?i:"object"!=typeof n)?n:Object.assign({},e,n),o.forEach(o=>o(e,t))}},n=()=>e,r={setState:i,getState:n,subscribe:t=>(o.add(t),()=>o.delete(t)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),o.clear()}};return e=t(i,n,r),r},o=t=>t?e(t):e,i=({query:t,container:e})=>{let o=null;try{o=(e||document).querySelector(t||"")}catch(t){console.info("querySelector error",t)}return o};function n(t,e){let o=t.getBoundingClientRect().top+window.pageYOffset,i=window.pageYOffset,n=o-i,r=null;requestAnimationFrame(function t(o){var s;null===r&&(r=o);let a=o-r,l=(s=a/(e/2))<1?n/2*s*s+i:-n/2*(--s*(s-2)-1)+i;window.scrollTo(0,l),a(t.startsWith("#el-")?t.replace("#el-","#"):t).substring(1),s=(t,e)=>{if(t){if(e){n(t,e);return}a(t)}},a=t=>{t&&t.scrollIntoView({behavior:"smooth"})},l=(t,e,o,i)=>{try{if(t&&"DIALOG"===t.tagName){let e=null==t?void 0:t.parentNode;e&&e.openModal()}"scroll-to-top"===e&&c(o),i&&(s(i,o),setTimeout(()=>{let t=new URL(window.location.toString());t.hash=`#${e}`,history.replaceState(null,"",t.toString())},300))}catch(t){console.info("Handle link clicked error",t)}},c=t=>{let e=document.documentElement;if(t){n(e,t);return}window.scrollTo({top:0,behavior:"smooth"})};function u(t,e){var o=function(t,e,o){if(!e.has(t))throw TypeError("attempted to get private field on non-instance");return e.get(t)}(t,e,0);return o.get?o.get.call(t):o.value}function d(t,e,o){return e in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}window.gpYouTubeIframeLoader={src:"https://www.youtube.com/iframe_api",loading:!1,loaded:!1,listeners:[],load:function(t){let e=this;if(this.listeners.push(t),this.loaded){setTimeout(function(){e.done()});return}if(this.loading)return;this.loading=!0,window.onYouTubeIframeAPIReady=function(){e.loaded=!0,e.done()};let o=document.createElement("script");o.type="text/javascript",o.src=this.src,document.body.appendChild(o)},done:function(){for(;this.listeners.length;)this.listeners.pop()(window.YT)}},(()=>{let t=window.location.hash;if(t){window.history.scrollRestoration="manual";let e=()=>{let o=i({query:`[id='${r(t)}']`});setTimeout(()=>a(o),100),document.removeEventListener("DOMContentLoaded",e)};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",e):e()}})(),(()=>{let t=document.querySelectorAll('a[href^="#"]');t.forEach(t=>{let e=t.getAttribute("href");if(!e||"#"===e)return;let o=r(e),n=i({query:`[data-gp-dialog-id='${o}']`}),s=i({query:`[id='${o}']`}),a=Number(t.getAttribute("data-scroll-speed"));t.addEventListener("click",t=>{t.preventDefault(),l(n,o,a,s)})})})(),window.Shopify=window.Shopify||{},window.Shopify.formatMoney||(window.Shopify.formatMoney=function(t,e){let o="",i=/\{\{\s*(\w+)\s*\}\}/,n=e||this.money_format;function r(t,e){return void 0===t?e:t}function s(t,e,o,i){var n;if(e=r(e,2),o=r(o,","),i=r(i,"."),isNaN(t)||null==t)return 0;t=(t/100).toFixed(Number(e));let s=t.split("."),a=null===(n=s[0])||void 0===n?void 0:n.replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+o),l=s[1]?i+s[1]:"";return a+l}switch("string"==typeof t&&(t=t.replace(".","")),n.match(i)[1]){case"amount":o=s(t,2);break;case"amount_no_decimals":o=s(t,0);break;case"amount_with_comma_separator":o=s(t,2,".",",");break;case"amount_no_decimals_with_comma_separator":o=s(t,0,".",",");break;case"amount_with_apostrophe_separator":o=s(t,2,"'",".");break;case"amount_no_decimals_with_space_separator":o=s(t,0," ");break;case"amount_with_space_separator":o=s(t,2," ",",");break;case"amount_with_period_and_space_separator":o=s(t,2," ",".")}return n.replace(i,o)});var h=new WeakMap;class p extends HTMLElement{constructor(){super(),d(this,"context",void 0),d(this,"store",void 0),function(t,e){if(e.has(t))throw TypeError("Cannot initialize the same private elements twice on an object")}(this,h),h.set(this,{writable:!0,value:t=>{if(!t)return{};try{var e;let o=null!==(e=JSON.parse(t))&&void 0!==e?e:{};return o}catch(t){return{}}}}),d(this,"getState",t=>{let e=this.store.getState();return t?e[t]:e}),d(this,"setState",(t,e)=>{this.store.setState({[t]:e})}),d(this,"subscribeState",t=>this.store.subscribe(t)),d(this,"subscribe",this.subscribeState),d(this,"getStoreContext",()=>this.context),d(this,"getContext",t=>{let e=this.context.getState();return t?e[t]:e}),d(this,"setContext",(t,e)=>{this.context.setState({[t]:e})}),d(this,"subscribeContext",t=>this.context.subscribe(t)),d(this,"trigger",({event:t,data:e})=>{let o=this.getState("uid"),i=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:{uid:o,data:e}});this.dispatchEvent(i)}),d(this,"onTrigger",({event:t},e)=>{this.addEventListener(t,t=>{let o=t.detail;e&&e(o)})});let t=this.getAttribute("gp-data"),e=this.getAttribute("gp-context");if(this.store=o(()=>u(this,h).call(this,t)),e)this.context=o(()=>u(this,h).call(this,e));else{let t=this.closest("[gp-context]");t&&t.getStoreContext?this.context=t.getStoreContext():this.context=o(()=>({}))}}}return t.Component=p,t}({}); const gpGlobalLoaded = new CustomEvent('gp-global-loaded');window.dispatchEvent(gpGlobalLoaded);window.gpReadyState = 'completed';