1/* 2@license 3 Streamline by Archetype Themes (https://archetypethemes.co) 4 Access unminified JS in assets/theme.js 5 6 Use our custom event listeners to tap into common functions. 7 Documentation - https://archetypethemes.co/blogs/streamline/javascript-events-for-developers 8 9 document.addEventListener('page:loaded', function() { 10 // Stylesheet and theme scripts have loaded 11 }); 12*/ 13window.theme=window.theme||{},window.Shopify=window.Shopify||{},theme.bp={},theme.config={cssLoaded:!1,bpSmall:!1,hasSessionStorage:!0,mediaQuerySmall:"screen and (max-width: 768px)",youTubeReady:!1,vimeoReady:!1,vimeoLoading:!1,isSafari:!!navigator.userAgent.match(/Version\/[\d\.]+.*Safari/),isTouch:!!("ontouchstart"in window||window.DocumentTouch&&window.document instanceof DocumentTouch||window.navigator.maxTouchPoints||window.navigator.msMaxTouchPoints),rtl:"rtl"==document.documentElement.getAttribute("dir")},console&&console.log&&console.log("Streamline theme ("+theme.settings.themeVersion+") by ARCHÎTYPE | Learn more at https://archetypethemes.co"),window.lazySizesConfig=window.lazySizesConfig||{},lazySizesConfig.expFactor=4,theme.config.bpSmall=matchMedia(theme.config.mediaQuerySmall).matches,matchMedia(theme.config.mediaQuerySmall).addListener((function(e){e.matches?(theme.config.bpSmall=!0,document.dispatchEvent(new CustomEvent("matchSmall"))):(theme.config.bpSmall=!1,document.dispatchEvent(new CustomEvent("unmatchSmall")))})),function(){"use strict";var e,t,i,n,s,o,a,r,c,d,l,h;if(theme.delegate={on:function(e,t,i){return this.namespaces||(this.namespaces={}),this.namespaces[e]=t,i=i||!1,this.addEventListener(e.split(".")[0],t,i),this},off:function(e){if(this.namespaces)return this.removeEventListener(e.split(".")[0],this.namespaces[e]),delete this.namespaces[e],this}},window.on=Element.prototype.on=theme.delegate.on,window.off=Element.prototype.off=theme.delegate.off,theme.utils={defaultTo:function(e,t){return null==e||e!=e?t:e},wrap:function(e,t){e.parentNode.insertBefore(t,e),t.appendChild(e)},debounce:function(e,t,i){var n;return function(){var s=this,o=arguments,a=function(){n=null,i||t.apply(s,o)},r=i&&!n;clearTimeout(n),n=setTimeout(a,e),r&&t.apply(s,o)}},throttle:function(e,t){var i=!1;return function(){i||(t.apply(this,arguments),i=!0,setTimeout((function(){i=!1}),e))}},prepareTransition:function(e,t){e.addEventListener("transitionend",(function t(i){e.classList.remove("is-transitioning"),e.removeEventListener("transitionend",t)})),e.classList.add("is-transitioning"),e.offsetWidth,"function"==typeof t&&t()},compact:function(e){for(var t=-1,i=null==e?0:e.length,n=0,s=[];++t<i;){var o=e[t];o&&(s[n++]=o)}return s},serialize:function(e){var t=[];return Array.prototype.slice.call(e.elements).forEach((function(e){!e.name||e.disabled||["file","reset","submit","button"].indexOf(e.type)>-1||("select-multiple"!==e.type?["checkbox","radio"].indexOf(e.type)>-1&&!e.checked||t.push(encodeURIComponent(e.name)+"="+encodeURIComponent(e.value)):Array.prototype.slice.call(e.options).forEach((function(i){i.selected&&t.push(encodeURIComponent(e.name)+"="+encodeURIComponent(i.value))})))})),t.join("&")}},theme.a11y={trapFocus:function(e){var t={focusin:e.namespace?"focusin."+e.namespace:"focusin",focusout:e.namespace?"focusout."+e.namespace:"focusout",keydown:e.namespace?"keydown."+e.namespace:"keydown.handleFocus"},i=e.container.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex^="-"])'),n=[].slice.call(i).filter(e=>null!==e.offsetParent),s=n[0],o=n[n.length-1];e.elementToFocus||(e.elementToFocus=e.container),e.container.setAttribute("tabindex","-1"),e.elementToFocus.focus(),document.documentElement.off("focusin"),document.documentElement.on(t.focusout,(function(){document.documentElement.off(t.keydown)})),document.documentElement.on(t.focusin,(function(e){e.target!==o&&e.target!==s||document.documentElement.on(t.keydown,(function(e){!function(e){if(9!==e.keyCode)return;e.target===s&&e.shiftKey&&(e.preventDefault(),o.focus())}(e)}))}))},removeTrapFocus:function(e){var t=e.namespace?"focusin."+e.namespace:"focusin";e.container&&e.container.removeAttribute("tabindex"),document.documentElement.off(t)},lockMobileScrolling:function(e,t){var i=t||document.documentElement;document.documentElement.classList.add("lock-scroll"),i.on("touchmove"+e,(function(){return!0}))},unlockMobileScrolling:function(e,t){document.documentElement.classList.remove("lock-scroll"),(t||document.documentElement).off("touchmove"+e)}},document.documentElement.on("keyup.tab",(function(e){9===e.keyCode&&(document.documentElement.classList.add("tab-outline"),document.documentElement.off("keyup.tab"))})),theme.Sections=function(){this.constructors={},this.instances=[],document.addEventListener("shopify:section:load",this._onSectionLoad.bind(this)),document.addEventListener("shopify:section:unload",this._onSectionUnload.bind(this)),document.addEventListener("shopify:section:select",this._onSelect.bind(this)),document.addEventListener("shopify:section:deselect",this._onDeselect.bind(this)),document.addEventListener("shopify:block:select",this._onBlockSelect.bind(this)),document.addEventListener("shopify:block:deselect",this._onBlockDeselect.bind(this))},theme.Sections.prototype=Object.assign({},theme.Sections.prototype,{_createInstance:function(e,t,i){var n=e.getAttribute("data-section-id"),s=e.getAttribute("data-section-type");if(void 0!==(t=t||this.constructors[s])){if(i)this._findInstance(n)&&this._removeInstance(n);try{var o=Object.assign(new t(e),{id:n,type:s,container:e});this.instances.push(o)}catch(e){console.error(e)}}},_findInstance:function(e){for(var t=0;t<this.instances.length;t++)if(this.instances[t].id===e)return this.instances[t]},_removeInstance:function(e){for(var t,i=this.instances.length;i--;)if(this.instances[i].id===e){t=this.instances[i],this.instances.splice(i,1);break}return t},_onSectionLoad:function(e,t,i){window.AOS&&AOS.refreshHard(),theme&&theme.initGlobals&&theme.initGlobals();var n=t||e.target,s=t||e.target.querySelector("[data-section-id]");if(s){this._createInstance(s);var o=t?i:this._findInstance(e.detail.sectionId);n.querySelectorAll("[data-subsection]").length&&this.loadSubSections(n),o&&"function"==typeof o.onLoad&&o.onLoad(e),setTimeout((function(){window.dispatchEvent(new Event("scroll"))}),200)}},_onSectionUnload:function(e){this.instances=this.instances.filter((function(t){var i=t.id===e.detail.sectionId;return i&&"function"==typeof t.onUnload&&t.onUnload(e),!i}))},loadSubSections:function(e){e&&e.querySelectorAll("[data-section-id]").forEach(e
13=>{this._onSectionLoad(null,e,e.dataset.sectionId)})},_onSelect:function(e){var t=this._findInstance(e.detail.sectionId);void 0!==t&&"function"==typeof t.onSelect&&t.onSelect(e)},_onDeselect:function(e){var t=this._findInstance(e.detail.sectionId);void 0!==t&&"function"==typeof t.onDeselect&&t.onDeselect(e)},_onBlockSelect:function(e){var t=this._findInstance(e.detail.sectionId);void 0!==t&&"function"==typeof t.onBlockSelect&&t.onBlockSelect(e)},_onBlockDeselect:function(e){var t=this._findInstance(e.detail.sectionId);void 0!==t&&"function"==typeof t.onBlockDeselect&&t.onBlockDeselect(e)},register:function(e,t,i){this.constructors[e]=t;var n=document.querySelectorAll('[data-section-type="'+e+'"]');i&&(n=i.querySelectorAll('[data-section-type="'+e+'"]')),n.forEach(function(e){this._createInstance(e,t,i)}.bind(this))},reinit:function(e){for(var t=0;t<this.instances.length;t++){var i=this.instances[t];i.type===e&&"function"==typeof i.forceReload&&i.forceReload()}}}),theme.Currency=(e=theme&&theme.settings&&theme.settings.superScriptPrice,{formatMoney:function(t,i){i||(i=theme.settings.moneyFormat),"string"==typeof t&&(t=t.replace(".",""));var n="",s=/\{\{\s*(\w+)\s*\}\}/,o=i||"${{amount}}";function a(e,t,i,n){if(t=theme.utils.defaultTo(t,2),i=theme.utils.defaultTo(i,","),n=theme.utils.defaultTo(n,"."),isNaN(e)||null==e)return 0;var s=(e=(e/100).toFixed(t)).split(".");return s[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+i)+(s[1]?n+s[1]:"")}switch(o.match(s)[1]){case"amount":n=a(t,2),e&&n&&n.includes(".")&&(n=n.replace(".","<sup>")+"</sup>");break;case"amount_no_decimals":n=a(t,0);break;case"amount_with_comma_separator":n=a(t,2,".",","),e&&n&&n.includes(".")&&(n=n.replace(",","<sup>")+"</sup>");break;case"amount_no_decimals_with_comma_separator":n=a(t,0,".",",");break;case"amount_no_decimals_with_space_separator":n=a(t,0," ")}return o.replace(s,n)},getBaseUnit:function(e){if(e&&e.unit_price_measurement&&e.unit_price_measurement.reference_value)return 1===e.unit_price_measurement.reference_value?e.unit_price_measurement.reference_unit:e.unit_price_measurement.reference_value+e.unit_price_measurement.reference_unit}}),theme.Images={imageSize:function(e){if(!e)return"620x";var t=e.match(/.+_((?:pico|icon|thumb|small|compact|medium|large|grande)|\d{1,4}x\d{0,4}|x\d{1,4})[_\.@]/);return null!==t?t[1]:null},getSizedImageUrl:function(e,t){if(!e)return e;if(null==t)return e;if("master"===t)return this.removeProtocol(e);var i=e.match(/\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?$/i);if(null!=i){var n=e.split(i[0]),s=i[0];return this.removeProtocol(n[0]+"_"+t+s)}return null},removeProtocol:function(e){return e.replace(/http(s)?:/,"")},lazyloadImagePath:function(e){var t;return null!==e&&(t=e.replace(/(\.[^.]*)$/,"_{width}x$1")),t}},theme.loadImageSection=function(e){function t(){e.classList.remove("loading","loading--delayed"),e.classList.add("loaded")}function i(){return e.querySelector(".lazyloaded")}if(e.querySelector("svg"))t();else if(i())t();else var n=setInterval((function(){i()&&(clearInterval(n),t())}),25)},theme.initWhenVisible=function(e){var t=e.threshold?e.threshold:0;new IntersectionObserver((t,i)=>{t.forEach(t=>{t.isIntersecting&&"function"==typeof e.callback&&(e.callback(),i.unobserve(t.target))})},{rootMargin:"0px 0px "+t+"px 0px"}).observe(e.element)},theme.Variants=function(){function e(e){this.container=e.container,this.variants=e.variants,this.singleOptionSelector=e.singleOptionSelector,this.originalSelectorId=e.originalSelectorId,this.enableHistoryState=e.enableHistoryState,this.currentVariant=this._getVariantFromOptions(),this.container.querySelectorAll(this.singleOptionSelector).forEach(e=>{e.addEventListener("change",this._onSelectChange.bind(this))})}return e.prototype=Object.assign({},e.prototype,{_getCurrentOptions:function(){var e=[];return this.container.querySelectorAll(this.singleOptionSelector).forEach(t=>{var i=t.getAttribute("type");"radio"===i||"checkbox"===i?t.checked&&e.push({value:t.value,index:t.dataset.index}):e.push({value:t.value,index:t.dataset.index})}),e=theme.utils.compact(e)},_getVariantFromOptions:function(){var e=this._getCurrentOptions(),t=this.variants,i=!1;return t.forEach((function(t){var n=!0;t.options;e.forEach((function(e){n&&(n=t[e.index]===e.value)})),n&&(i=t)})),i||null},_onSelectChange:function(){var e=this._getVariantFromOptions();
13this.container.dispatchEvent(new CustomEvent("variantChange",{detail:{variant:e}})),document.dispatchEvent(new CustomEvent("variant:change",{detail:{variant:e}})),e&&(this._updateMasterSelect(e),this._updateImages(e),this._updatePrice(e),this._updateUnitPrice(e),this._updateSKU(e),this.currentVariant=e,this.enableHistoryState&&this._updateHistoryState(e))},_updateImages:function(e){var t=e.featured_image||{},i=this.currentVariant.featured_image||{};e.featured_image&&t.src!==i.src&&this.container.dispatchEvent(new CustomEvent("variantImageChange",{detail:{variant:e}}))},_updatePrice:function(e){e.price===this.currentVariant.price&&e.compare_at_price===this.currentVariant.compare_at_price||this.container.dispatchEvent(new CustomEvent("variantPriceChange",{detail:{variant:e}}))},_updateUnitPrice:function(e){e.unit_price!==this.currentVariant.unit_price&&this.container.dispatchEvent(new CustomEvent("variantUnitPriceChange",{detail:{variant:e}}))},_updateSKU:function(e){e.sku!==this.currentVariant.sku&&this.container.dispatchEvent(new CustomEvent("variantSKUChange",{detail:{variant:e}}))},_updateHistoryState:function(e){if(history.replaceState&&e){var t=window.location.protocol+"//"+window.location.host+window.location.pathname+"?variant="+e.id;window.history.replaceState({path:t},"",t)}},_updateMasterSelect:function(e){this.container.querySelector(this.originalSelectorId).value=e.id,this.container.querySelector(this.originalSelectorId).dispatchEvent(new Event("change",{bubbles:!0}))}}),e}(),theme.rteInit=function(){function e(e){e.src=e.src;var t=document.createElement("div");t.classList.add("video-wrapper"),theme.utils.wrap(e,t)}document.querySelectorAll(".rte table").forEach(e=>{var t=document.createElement("div");t.classList.add("table-wrapper"),theme.utils.wrap(e,t)}),document.querySelectorAll('.rte iframe[src*="youtube.com/embed"]').forEach(t=>{e(t)}),document.querySelectorAll('.rte iframe[src*="player.vimeo"]').forEach(t=>{e(t)}),document.querySelectorAll(".rte a img").forEach(e=>{e.parentNode.classList.add("rte__image")})},theme.LibraryLoader=(n="requested",s="loaded",a={youtubeSdk:{tagId:"youtube-sdk",src:"https://www.youtube.com/iframe_api",type:i="script"},vimeo:{tagId:"vimeo-api",src:"https://player.vimeo.com/api/player.js",type:i},shopifyXr:{tagId:"shopify-model-viewer-xr",src:(o="https://cdn.shopify.com/shopifycloud/")+"shopify-xr-js/assets/v1.0/shopify-xr.en.js",type:i},modelViewerUi:{tagId:"shopify-model-viewer-ui",src:o+"model-viewer-ui/assets/v1.0/model-viewer-ui.en.js",type:i},modelViewerUiStyles:{tagId:"shopify-model-viewer-ui-styles",src:o+"model-viewer-ui/assets/v1.0/model-viewer-ui.css",type:t="link"}},{load:function(e,o){var r=a[e];if(r&&r.status!==n)if(o=o||function(){},r.status!==s){var c;switch(r.status=n,r.type){case i:c=function(e,t){var i=document.createElement("script");return i.src=e.src,i.addEventListener("load",(function(){e.status=s,t()})),i}(r,o);break;case t:c=function(e,t){var i=document.createElement("link");return i.href=e.src,i.rel="stylesheet",i.type="text/css",i.addEventListener("load",(function(){e.status=s,t()})),i}(r,o)}c.id=r.tagId,r.element=c;var d=document.getElementsByTagName(r.type)[0];d.parentNode.insertBefore(c,d)}else o()}}),window.vimeoApiReady=function(){var e,t;theme.config.vimeoLoading=!0,new Promise((i,n)=>{e=setInterval((function(){Vimeo&&(clearInterval(e),clearTimeout(t),i())}),500),t=setTimeout((function(){clearInterval(e),n()}),4e3)}).then((function(){theme.config.vimeoReady=!0,theme.config.vimeoLoading=!1,document.dispatchEvent(new CustomEvent("vimeoReady"))}))},theme.VimeoPlayer=function(){var e="loading",t="loaded",i="video-interactable",n={background:!0,byline:!1,controls:!1,loop:!0,muted:!0,playsinline:!0,portrait:!1,title:!1};function s(e,t,i){this.divId=e,this.el=document.getElementById(e),this.videoId=t,this.iframe=null,this.options=i,this.options&&this.options.videoParent&&(this.parent=this.el.closest(this.options.videoParent)),this.setAsLoading(),theme.config.vimeoReady?this.init():(theme.LibraryLoader.load("vimeo",window.vimeoApiReady),document.addEventListener("vimeoReady",this.init.bind(this)))}return s.prototype=Object.assign({},s.prototype,{init:function(){var e=n;e.id=this.videoId,this.videoPlayer=new Vimeo.Player(this.el,e),this.videoPlayer.ready().then(this.playerReady.bind(this))},playerReady:function(){this.iframe=this.el.querySelector("iframe"),this.iframe.setAttribute("tabindex","-1"),this.videoPlayer.setMuted(!0),this.setAsLoaded(),new IntersectionObserver((e,t)=>
13{e.forEach(e=>{e.isIntersecting?this.play():this.pause()})},{rootMargin:"0px 0px 50px 0px"}).observe(this.iframe)},setAsLoading:function(){this.parent&&this.parent.classList.add(e)},setAsLoaded:function(){this.parent&&(this.parent.classList.remove(e),this.parent.classList.add(t),Shopify&&Shopify.designMode&&window.AOS&&AOS.refreshHard())},enableInteraction:function(){this.parent&&this.parent.classList.add(i)},play:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.play&&this.videoPlayer.play()},pause:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.pause&&this.videoPlayer.pause()},destroy:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.destroy&&this.videoPlayer.destroy()}}),s}(),window.onYouTubeIframeAPIReady=function(){theme.config.youTubeReady=!0,document.dispatchEvent(new CustomEvent("youTubeReady"))},theme.YouTube=function(){var e="loading",t="loaded",i="video-interactable",n={width:1280,height:720,playerVars:{autohide:0,autoplay:1,cc_load_policy:0,controls:0,fs:0,iv_load_policy:3,modestbranding:1,playsinline:1,rel:0}};function s(e,t){this.divId=e,this.iframe=null,this.attemptedToPlay=!1,n.events={onReady:this.onVideoPlayerReady.bind(this),onStateChange:this.onVideoStateChange.bind(this)},this.options=Object.assign({},n,t),this.options&&(this.options.videoParent&&(this.parent=document.getElementById(this.divId).closest(this.options.videoParent)),this.options.autoplay||(this.options.playerVars.autoplay=this.options.autoplay),"sound"===this.options.style&&(this.options.playerVars.controls=1,this.options.playerVars.autoplay=0)),this.setAsLoading(),theme.config.youTubeReady?this.init():(theme.LibraryLoader.load("youtubeSdk"),document.addEventListener("youTubeReady",this.init.bind(this)))}return s.prototype=Object.assign({},s.prototype,{init:function(){this.videoPlayer=new YT.Player(this.divId,this.options)},onVideoPlayerReady:function(e){this.iframe=document.getElementById(this.divId),this.iframe.setAttribute("tabindex","-1"),"sound"!==this.options.style&&e.target.mute(),new IntersectionObserver((e,t)=>{e.forEach(e=>{e.isIntersecting?this.play():this.pause()})},{rootMargin:"0px 0px 50px 0px"}).observe(this.iframe)},onVideoStateChange:function(e){switch(e.data){case-1:this.attemptedToPlay&&(this.setAsLoaded(),this.enableInteraction());break;case 0:this.play(e);break;case 1:this.setAsLoaded();break;case 3:this.attemptedToPlay=!0}},setAsLoading:function(){this.parent&&this.parent.classList.add(e)},setAsLoaded:function(){this.parent&&(this.parent.classList.remove(e),this.parent.classList.add(t),Shopify&&Shopify.designMode&&window.AOS&&AOS.refreshHard())},enableInteraction:function(){this.parent&&this.parent.classList.add(i)},play:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.playVideo&&this.videoPlayer.playVideo()},pause:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.pauseVideo&&this.videoPlayer.pauseVideo()},destroy:function(){this.videoPlayer&&"function"==typeof this.videoPlayer.destroy&&this.videoPlayer.destroy()}}),s}(),r=Flickity.prototype.resize,c=window.innerWidth,Flickity.prototype.resize=function(){window.innerWidth!==c&&(c=window.innerWidth,r.apply(this,arguments))},l=!1,document.body.addEventListener("touchstart",(function(e){if(!e.target.closest(".flickity-slider"))return l=!1;l=!0,d={x:e.touches[0].pageX,y:e.touches[0].pageY}})),document.body.addEventListener("touchmove",(function(e){if(l&&e.cancelable){var t={x:e.touches[0].pageX-d.x,y:e.touches[0].pageY-d.y};Math.abs(t.x)>Flickity.defaults.dragThreshold&&e.preventDefault()}}),{passive:!1}),theme.AjaxRenderer=function(){function e({sections:e,preserveParams:t,onReplace:i,debug:n}={}){this.sections=e||[],this.preserveParams=t||[],this.cachedSections=[],this.onReplace=i,this.debug=Boolean(n)}return e.prototype=Object.assign({},e.prototype,{renderPage:function(e,t,i=!0){t&&this.appendPreservedParams(t);const n=this.sections.map(i=>{const n=`${e}?section_id=${i.sectionId}&${t}`,s=e=>e.url===n;return this.cachedSections.some(s)?this.renderSectionFromCache(s,i):this.renderSectionFromFetch(n,i)});return i&&this.updateURLHash(t),Promise.all(n)}
13,renderSectionFromCache:function(e,t){const i=this.cachedSections.find(e);return this.log("[AjaxRenderer] rendering from cache: url="+i.url),this.renderSection(i.html,t),Promise.resolve(t)},renderSectionFromFetch:function(e,t){return this.log("[AjaxRenderer] redering from fetch: url="+e),new Promise((i,n)=>{fetch(e).then(e=>e.text()).then(n=>{const s=n;this.cachedSections=[...this.cachedSections,{html:s,url:e}],this.renderSection(s,t),i(t)}).catch(e=>n(e))})},renderSection:function(e,t){this.log("[AjaxRenderer] rendering section: section="+JSON.stringify(t));const i=(new DOMParser).parseFromString(e,"text/html");return this.onReplace?this.onReplace(i,t):"string"==typeof t.nodeId?document.getElementById(t.nodeId).innerHTML=i.getElementById(t.nodeId).innerHTML:t.nodeId.forEach(e=>{document.getElementById(e).innerHTML=i.getElementById(e).innerHTML}),t},appendPreservedParams:function(e){this.preserveParams.forEach(t=>{const i=new URLSearchParams(window.location.search).get(t);i&&(this.log(`[AjaxRenderer] Preserving ${t} param`),e.append(t,i))})},updateURLHash:function(e){history.pushState({},"",`${window.location.pathname}${e&&"?".concat(e)}`)},log:function(...e){this.debug&&console.log(...e)}}),e}(),theme.cart={getCart:function(){var e="".concat(theme.routes.cart,"?t=").concat(Date.now());return fetch(e,{credentials:"same-origin",method:"GET"}).then(e=>e.json())},getCartProductMarkup:function(){var e="".concat(theme.routes.cartPage,"?t=").concat(Date.now());return e=-1===e.indexOf("?")?e+"?view=ajax":e+"&view=ajax",fetch(e,{credentials:"same-origin",method:"GET"}).then((function(e){return e.text()}))},changeItem:function(e,t){return this._updateCart({url:"".concat(theme.routes.cartChange,"?t=").concat(Date.now()),data:JSON.stringify({id:e,quantity:t})})},_updateCart:function(e){return fetch(e.url,{method:"POST",body:e.data,credentials:"same-origin",headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest"}}).then(e=>e.json()).then((function(e){return e}))},updateAttribute:function(e,t){return this._updateCart({url:"/cart/update.js",data:JSON.stringify({attributes:{[e]:theme.cart.attributeToString(t)}})})},updateNote:function(e){return this._updateCart({url:"/cart/update.js",data:JSON.stringify({note:theme.cart.attributeToString(e)})})},attributeToString:function(e){return"string"!=typeof e&&"undefined"===(e+="")&&(e=""),e.trim()}},theme.CartForm=function(){var e="[data-products]",t=".js-qty__wrapper",i="[data-discounts]",n="[data-savings]",s="[data-subtotal]",o=".cart-link__bubble",a='[name="note"]',r=".cart__terms-checkbox",c=".cart__checkout",d="btn--loading",l={requiresTerms:!1};function h(t){t&&(this.form=t,this.wrapper=t.parentNode,this.location=t.dataset.location,this.namespace=".cart-"+this.location,this.products=t.querySelector(e),this.submitBtn=t.querySelector(c),this.discounts=t.querySelector(i),this.savings=t.querySelector(n),this.subtotal=t.querySelector(s),this.termsCheckbox=t.querySelector(r),this.noteInput=t.querySelector(a),this.termsCheckbox&&(l.requiresTerms=!0),this.init())}return h.prototype=Object.assign({},h.prototype,{init:function(){this.initQtySelectors(),document.addEventListener("cart:quantity"+this.namespace,this.quantityChanged.bind(this)),this.form.on("submit"+this.namespace,this.onSubmit.bind(this)),this.noteInput&&this.noteInput.addEventListener("change",(function(){var e=this.value;theme.cart.updateNote(e)})),document.addEventListener("cart:build",function(){this.buildCart()}.bind(this))},reInit:function(){this.initQtySelectors()},onSubmit:function(e){if(this.submitBtn.classList.add(d),l.requiresTerms&&!this.termsCheckbox.checked)return alert(theme.strings.cartTermsConfirmation),this.submitBtn.classList.remove(d),e.preventDefault(),!1},_parseProductHTML:function(e){var t=(new DOMParser).parseFromString(e,"text/html");return{items:t.querySelector(".cart__items"),discounts:t.querySelector(".cart__discounts")}},buildCart:function(){theme.cart.getCartProductMarkup().then(this.cartMarkup.bind(this))},cartMarkup:function(e){var t=this._parseProductHTML(e),i=t.items,n=parseInt(i.dataset.count),s=i.dataset.cartSubtotal,o=i.dataset.cartSavings;this.updateCartDiscounts(t.discounts),this.updateSavings(o),n>0?this.wrapper.classList.remove("is-empty"):this.wrapper.classList.add("is-empty"),this.updateCount(n),this.products.innerHTML="",this.products.append(i),this.subtotal.innerHTML=theme.Currency.formatMoney(s,theme.settings.moneyFormat),this.reInit(),window.AOS&&AOS.refreshHard(),Shopify&&Shopify.StorefrontExpressButtons&&Shopify.StorefrontExpressButtons.initialize()},updateCartDiscounts:function(e){this.discounts&&(this.discounts.innerHTML="",this.discounts.append(e))},initQtySelectors:function(){this.form.querySelectorAll(t).forEach(e
13=>{new theme.QtySelector(e,{namespace:this.namespace,isCart:!0})})},quantityChanged:function(e){var t=e.detail[0],i=e.detail[1],n=e.detail[2];t&&i&&(n&&n.classList.add("is-loading"),theme.cart.changeItem(t,i).then(function(e){e.item_count>0?this.wrapper.classList.remove("is-empty"):this.wrapper.classList.add("is-empty"),this.buildCart(),document.dispatchEvent(new CustomEvent("cart:updated",{detail:{cart:e}}))}.bind(this)).catch((function(e){})))},updateSubtotal:function(e){this.form.querySelector(s).innerHTML=theme.Currency.formatMoney(e,theme.settings.moneyFormat)},updateSavings:function(e){if(this.savings)if(e>0){var t=theme.Currency.formatMoney(e,theme.settings.moneyFormat);this.savings.classList.remove("hide"),this.savings.innerHTML=theme.strings.cartSavings.replace("[savings]",t)}else this.savings.classList.add("hide")},updateCount:function(e){var t=document.querySelectorAll(".cart-link__bubble-num");t.length&&t.forEach(t=>{t.innerText=e});var i=document.querySelectorAll(o);i.length&&(e>0?i.forEach(e=>{e.classList.add("cart-link__bubble--visible")}):i.forEach(e=>{e.classList.remove("cart-link__bubble--visible")}))}}),h}(),theme.collapsibles=function(){var e=".collapsible-trigger",t=".collapsible-content",i=".collapsible-content__inner",n=".collapsible-trigger--tab",s="hide",o="is-open",a="collapsible--auto-height",r="collapsible-trigger--tab",c=!1;function d(e){if(!c){c=!0;var s=e.currentTarget,d=s.classList.contains(o),h=s.classList.contains(r),u=s.getAttribute("aria-controls"),m=document.getElementById(u);if(u||(u=s.dataset.controls),u){if(!m)document.querySelectorAll('[data-id="'+u+'"]').length>0&&(m=s.parentNode.querySelector('[data-id="'+u+'"]'));if(m){var p=m.querySelector(i).offsetHeight,f=m.classList.contains(a),v=m.parentNode.closest(t),g=p;if(h){if(d)return void(c=!1);document.querySelectorAll(n+'[data-id="'+s.dataset.id+'"]').forEach(e=>{e.classList.remove(o),l(document.querySelector("#"+e.getAttribute("aria-controls")),0,!0)})}if(d&&f&&setTimeout((function(){l(m,p=0,d,f)}),0),d&&!f&&(p=0),s.setAttribute("aria-expanded",!d),d?s.classList.remove(o):s.classList.add(o),l(m,p,d,f),v)l(v,d?v.offsetHeight-g:p+v.offsetHeight,!1,!1);if(window.SPR){var y=m.querySelector(".spr-summary-actions-newreview");if(!y)return;y.off("click.collapsible"),y.on("click.collapsible",(function(){p=m.querySelector(i).offsetHeight,l(m,p,d,f)}))}}else c=!1}}}function l(e,t,i,n){if(e.classList.remove(s),theme.utils.prepareTransition(e,(function(){e.style.height=t+"px",i?e.classList.remove(o):e.classList.add(o)})),!i&&n){var a=e;window.setTimeout((function(){a.css("height","auto"),c=!1}),500)}else c=!1}return{init:function(t){(t||document).querySelectorAll(e).forEach(e=>{var t=e.classList.contains(o);e.setAttribute("aria-expanded",t),e.off("click.collapsible"),e.on("click.collapsible",d)})}}}(),theme.Disclosure=function(){var e="[data-disclosure-form]",t="[data-disclosure-list]",i="[data-disclosure-toggle]",n="[data-disclosure-input]",s="[data-disclosure-option]",o="disclosure-list--visible";function a(e){this.container=e,this._cacheSelectors(),this._setupListeners()}return a.prototype=Object.assign({},a.prototype,{_cacheSelectors:function(){this.cache={disclosureForm:this.container.closest(e),disclosureList:this.container.querySelector(t),disclosureToggle:this.container.querySelector(i),disclosureInput:this.container.querySelector(n),disclosureOptions:this.container.querySelectorAll(s)}},_setupListeners:function(){this.eventHandlers=this._setupEventHandlers(),this.cache.disclosureToggle.addEventListener("click",this.eventHandlers.toggleList),this.cache.disclosureOptions.forEach((function(e){e.addEventListener("click",this.eventHandlers.connectOptions)}),this),this.container.addEventListener("keyup",this.eventHandlers.onDisclosureKeyUp),this.cache.disclosureList.addEventListener("focusout",this.eventHandlers.onDisclosureListFocusOut),this.cache.disclosureToggle.addEventListener("focusout",this.eventHandlers.onDisclosureToggleFocusOut),document.body.addEventListener("click",this.eventHandlers.onBodyClick)},_setupEventHandlers:function(){return{connectOptions:this._connectOptions.bind(this),toggleList:this._toggleList.bind(this),onBodyClick:this._onBodyClick.bind(this),onDisclosureKeyUp:this._onDisclosureKeyUp.bind(this),onDisclosureListFocusOut:this._onDisclosureListFocusOut.bind(this),onDisclosureToggleFocusOut:this._onDisclosureToggleFocusOut.bind(this)}},_connectOptions:function(e){e.preventDefault(),this._submitForm(e.currentTarget.dataset.value)},_onDisclosureToggleFocusOut:function(e){!1===this.container.contains(e.relatedTarget)&&this._hideList()},_onDisclosureListFocusOut:function(e){var t=e.currentTarget.contains(e.relatedTarget);this.cache.disclosureList.classList.contains(o)&&!t&&this._hideList()},_onDisclosureKeyUp:function(e){27===e.which&&(this._hideList(),this.cache.disclosureToggle.focus())},_onBodyClick:function(e){var t=this.container.contains(e.target);this.cache.disclosureList.classList.contains(o)&&!t&&this._hideList()},_submitForm:function(e){this.cache.disclosureInput.value=e,this.cache.disclosureForm.submit()},_hideList:function(){this.cache.disclosureList.classList.remove(o),this.cache.disclosureToggle.setAttribute("aria-expanded",!1)},_toggleList:function(){var e="true"===this.cache.disclosureToggle.getAttribute("aria-expanded");this.cache.disclosureList.classList.toggle(o),this.cache.disclosureToggle.setAttribute("aria-expanded",!e)},destroy:function(){this.cache.disclosureToggle.removeEventListener("click",this.eventHandlers.toggleList),this.cache.disclosureOptions.forEach((function(e){e.removeEventListener("click",this.eventHandlers.connectOptions)}),this),this.container.removeEventListener("keyup",this.eventHandlers.onDisclosureKeyUp),this.cache.disclosureList.removeEventListener("focusout",this.eventHandlers.onDisclosureListFocusOut),this.cache.disclosureToggle.removeEventListener("focusout",this.eventHandlers.onDisclosureToggleFocusOut),document.body.removeEventListener("click",this.eventHandlers.onBodyClick)}}),a}(),theme.Drawers=function(){function e(e,t){this.config={id:e,close:".js-drawer-close",open:".js-drawer-open-"+t,openClass:"js-drawer-open",closingClass:"js-drawer-closing",activeDrawer:"drawer--is-open",namespace:".drawer-"+t},this.nodes={page:document.querySelector("#MainContent")},this.drawer=document.querySelector("#"+e),this.isOpen=!1,this.drawer&&this.init()}return e.prototype=Object.assign({},e.prototype,{init:function(){document.querySelectorAll(this.config.open).forEac
13h(e=>{e.setAttribute("aria-expanded","false"),e.addEventListener("click",this.open.bind(this))}),this.drawer.querySelector(this.config.close).addEventListener("click",this.close.bind(this)),document.addEventListener("modalOpen",function(){this.close()}.bind(this))},open:function(e,t){e&&e.preventDefault(),this.isOpen||(e&&e.stopPropagation?(e.stopPropagation(),e.currentTarget.setAttribute("aria-expanded","true"),this.activeSource=e.currentTarget):t&&(t.setAttribute("aria-expanded","true"),this.activeSource=t),theme.utils.prepareTransition(this.drawer,function(){this.drawer.classList.add(this.config.activeDrawer)}.bind(this)),document.documentElement.classList.add(this.config.openClass),this.isOpen=!0,theme.a11y.trapFocus({container:this.drawer,namespace:"drawer_focus"}),document.dispatchEvent(new CustomEvent("drawerOpen")),document.dispatchEvent(new CustomEvent("drawerOpen."+this.config.id)),this.bindEvents())},close:function(e){if(this.isOpen){if(e)if(e.target.closest(".js-drawer-close"));else if(e.target.closest(".drawer"))return;document.activeElement.blur(),theme.utils.prepareTransition(this.drawer,function(){this.drawer.classList.remove(this.config.activeDrawer)}.bind(this)),document.documentElement.classList.remove(this.config.openClass),document.documentElement.classList.add(this.config.closingClass),window.setTimeout(function(){document.documentElement.classList.remove(this.config.closingClass),this.activeSource&&this.activeSource.getAttribute("aria-expanded")&&(this.activeSource.setAttribute("aria-expanded","false"),this.activeSource.focus())}.bind(this),500),this.isOpen=!1,theme.a11y.removeTrapFocus({container:this.drawer,namespace:"drawer_focus"}),this.unbindEvents()}},bindEvents:function(){window.on("click"+this.config.namespace,function(e){this.close(e)}.bind(this)),window.on("keyup"+this.config.namespace,function(e){27===e.keyCode&&this.close()}.bind(this)),theme.a11y.lockMobileScrolling(this.config.namespace,this.nodes.page)},unbindEvents:function(){window.off("click"+this.config.namespace),window.off("keyup"+this.config.namespace),theme.a11y.unlockMobileScrolling(this.config.namespace,this.nodes.page)}}),e}(),theme.Modals=function(){function e(e,t,i){var n={close:".js-modal-close",open:".js-modal-open-"+t,openClass:"modal--is-active",closingClass:"modal--is-closing",bodyOpenClass:["modal-open"],bodyOpenSolidClass:"modal-open--solid",bodyClosingClass:"modal-closing",closeOffContentClick:!0};if(this.id=e,this.modal=document.getElementById(e),!this.modal)return!1;this.modalContent=this.modal.querySelector(".modal__inner"),this.config=Object.assign(n,i),this.modalIsOpen=!1,this.focusOnOpen=this.config.focusIdOnOpen?document.getElementById(this.config.focusIdOnOpen):this.modal,this.isSolid=this.config.solid,this.init()}return e.prototype.init=function(){document.querySelectorAll(this.config.open).forEach(e=>{e.setAttribute("aria-expanded","false"),e.addEventListener("click",this.open.bind(this))}),this.modal.querySelectorAll(this.config.close).forEach(e=>{e.addEventListener("click",this.close.bind(this))}),document.addEventListener("drawerOpen",function(){this.close()}.bind(this))},e.prototype.open=function(e){var t=!1;this.modalIsOpen||(e?e.preventDefault():t=!0,e&&e.stopPropagation&&(e.stopPropagation(),this.activeSource=e.currentTarget.setAttribute("aria-expanded","true")),this.modalIsOpen&&!t&&this.close(),this.modal.classList.add(this.config.openClass),document.documentElement.classList.add(...this.config.bodyOpenClass),this.isSolid&&document.documentElement.classList.add(this.config.bodyOpenSolidClass),this.modalIsOpen=!0,theme.a11y.trapFocus({container:this.modal,elementToFocus:this.focusOnOpen,namespace:"modal_focus"}),document.dispatchEvent(new CustomEvent("modalOpen")),document.dispatchEvent(new CustomEvent("modalOpen."+this.id)),this.bindEvents())},e.prototype.close=function(e){if(this.modalIsOpen){if(e)if(e.target.closest(".js-modal-close"));else if(e.target.closest(".modal__inner"))return;document.activeElement.blur(),this.modal.classList.remove(this.config.openClass),this.modal.classList.add(this.config.closingClass),document.documentElement.classList.remove(...this.config.bodyOpenClass),document.documentElement.classList.add(this.config.bodyClosingClass),window.setTimeout(function(){document.documentElement.classList.remove(this.config.bodyClosingClass),this.modal.classList.remove(this.config.closingClass),this.activeSource&&this.activeSource.getAttribute("aria-expanded")&&this.activeSource.setAttribute("aria-expanded","fal
13se").focus()}.bind(this),500),this.isSolid&&document.documentElement.classList.remove(this.config.bodyOpenSolidClass),this.modalIsOpen=!1,theme.a11y.removeTrapFocus({container:this.modal,namespace:"modal_focus"}),document.dispatchEvent(new CustomEvent("modalClose."+this.id)),this.unbindEvents()}},e.prototype.bindEvents=function(){window.on("keyup.modal",function(e){27===e.keyCode&&this.close()}.bind(this)),this.config.closeOffContentClick&&this.modal.on("click.modal",this.close.bind(this))},e.prototype.unbindEvents=function(){document.documentElement.off(".modal"),this.config.closeOffContentClick&&this.modal.off(".modal")},e}(),void 0===window.noUiSlider)throw new Error("theme.PriceRange is missing vendor noUiSlider: // =require vendor/nouislider.js");theme.PriceRange=function(){var e=".price-range__slider",t=".price-range__input-min",i=".price-range__input-max",n=".price-range__display-min",s=".price-range__display-max";function o(e,{onChange:t,onUpdate:i,...n}={}){return this.container=e,this.onChange=t,this.onUpdate=i,this.sliderOptions=n||{},this.init()}return o.prototype=Object.assign({},o.prototype,{init:function(){if(!this.container.classList.contains("price-range"))throw new Error("You must instantiate PriceRange with a valid container");return this.formEl=this.container.closest("form"),this.sliderEl=this.container.querySelector(e),this.inputMinEl=this.container.querySelector(t),this.inputMaxEl=this.container.querySelector(i),this.displayMinEl=this.container.querySelector(n),this.displayMaxEl=this.container.querySelector(s),this.minRange=parseFloat(this.container.dataset.min)||0,this.minValue=parseFloat(this.container.dataset.minValue)||0,this.maxRange=parseFloat(this.container.dataset.max)||100,this.maxValue=parseFloat(this.container.dataset.maxValue)||this.maxRange,this.createPriceRange()},createPriceRange:function(){this.sliderEl&&this.sliderEl.noUiSlider&&"function"==typeof this.sliderEl.noUiSlider.destroy&&this.sliderEl.noUiSlider.destroy();var e=noUiSlider.create(this.sliderEl,{connect:!0,step:10,...this.sliderOptions,start:[this.minValue,this.maxValue],range:{min:this.minRange,max:this.maxRange}});return e.on("update",e=>{this.displayMinEl.innerHTML=theme.Currency.formatMoney(e[0],theme.settings.moneyFormat),this.displayMaxEl.innerHTML=theme.Currency.formatMoney(e[1],theme.settings.moneyFormat),this.onUpdate&&this.onUpdate(e)}),e.on("change",e=>{if(this.inputMinEl.value=e[0],this.inputMaxEl.value=e[1],this.onChange){const e=new FormData(this.formEl);this.onChange(e)}}),e}}),o}(),theme.AjaxProduct=function(){var e={loading:!1};function t(e,t,i){this.form=e,this.args=i;var n=t||".add-to-cart";this.form&&(this.addToCart=e.querySelector(n),this.form.addEventListener("submit",this.addItemFromForm.bind(this)))}return t.prototype=Object.assign({},t.prototype,{addItemFromForm:function(t,i){if(t.preventDefault(),!e.loading){this.addToCart.classList.add("btn--loading"),e.loading=!0;var n=theme.utils.serialize(this.form);fetch(theme.routes.cartAdd,{method:"POST",body:n,credentials:"same-origin",headers:{"Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest"}}).then(e=>e.json()).then(function(t){if(422===t.status)this.error(t);else{var i=t;this.success(i)}e.loading=!1,this.addToCart.classList.remove("btn--loading"),document.body.classList.contains("template-cart")&&(window.scrollTo(0,0),location.reload())}.bind(this))}},success:function(e){var t=this.form.querySelector(".errors");t&&t.remove(),document.dispatchEvent(new CustomEvent("ajaxProduct:added",{detail:{product:e,addToCartBtn:this.addToCart}})),this.args&&this.args.scopedEventId&&document.dispatchEvent(new CustomEvent("ajaxProduct:added:"+this.args.scopedEventId,{detail:{product:e,addToCartBtn:this.addToCart}}))},error:function(e){if(e.description){var t=this.form.querySelector(".errors");t&&t.remove();var i=document.createElement("div");i.classList.add("errors","text-center"),i.textContent=e.description,this.form.append(i),document.dispatchEvent(new CustomEvent("ajaxProduct:error",{detail:{errorMessage:e.description}})),this.args&&this.args.scopedEventId&&document.dispatchEvent(new CustomEvent("ajaxProduct:error:"+this.args.scopedEventId,{detail:{errorMessage:e.description}}))}else console.warn(e)}}),t}(),theme.ProductMedia=function(){var e={},t={},i={},n="[data-product-single-media-group]",s="[data-shopify-xr]";function o(t){if(!t)if(window.ShopifyXR){for(var i in e)if(e.hasOwnProperty(i)){var n=e[i];if(n.loaded)continue;var s=document.querySelector("#ModelJson-"+i);window.ShopifyXR.addModels(JSON.parse(s.innerHTML)),n.loaded=!0}window.ShopifyXR.setupXRElements()}else document.addEventListener("shopify_xr_initialized",(function(){o()}))}function a(e){if(!e)for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];!n.modelViewerUi&&Shopify&&(n.modelViewerUi=new Shopify.ModelViewerUI(n.element)),r(n)}}function r(e){var t=i[e.sectionId];e.container.addEventListener("mediaVisible",(function(){t.element.setAttribute("data-shopify-model3d-id",e.modelId),theme.config.isTouch||e.modelViewerUi.play()})),e.container.addEventListener("mediaHidden",(function(){t.element.setAttribute("data-shopify-model3d-id",t.defaultId),e.modelViewerUi.pause()})),e.container.addEventListener("xrLaunch",(function(){e.modelViewerUi.pause()}))}return{init:function(r,c){e[c]={loaded:!1},r.forEach((function(e,o){var a=e.dataset.mediaId,r=e.querySelector("model-viewer"),d=r.dataset.modelId;if(0===o){var l=e.closest(n).querySelector(s);i[c]={element:l,defaultId:d}}t[a]={modelId:d,sectionId:c,container:e,element:r}})),window.Shopify.loadFeatures([{name:"shopify-xr",version:"1.0",onLoad:o}
13,{name:"model-viewer-ui",version:"1.0",onLoad:a}]),theme.LibraryLoader.load("modelViewerUiStyles")},removeSectionModels:function(i){for(var n in t){if(t.hasOwnProperty(n))t[n].sectionId===i&&delete t[n]}delete e[i]}}}(),theme.QtySelector=function(){var e=".js-qty__num",t=".js-qty__adjust--plus",i=".js-qty__adjust--minus";function n(n,s){this.wrapper=n,this.plus=n.querySelector(t),this.minus=n.querySelector(i),this.input=n.querySelector(e),this.minValue=this.input.getAttribute("min")||1;var o={namespace:null,isCart:!1,key:this.input.dataset.id};this.options=Object.assign({},o,s),this.init()}return n.prototype=Object.assign({},n.prototype,{init:function(){this.plus.addEventListener("click",function(){var e=this._getQty();this._change(e+1)}.bind(this)),this.minus.addEventListener("click",function(){var e=this._getQty();this._change(e-1)}.bind(this)),this.input.addEventListener("change",function(e){this._change(this._getQty())}.bind(this))},_getQty:function(){var e=this.input.value;return(parseFloat(e)!=parseInt(e)||isNaN(e))&&(e=1),parseInt(e)},_change:function(e){e<=this.minValue&&(e=this.minValue),this.input.value=e,this.options.isCart&&document.dispatchEvent(new CustomEvent("cart:quantity"+this.options.namespace,{detail:[this.options.key,e,this.wrapper]}))}}),n}(),theme.Slideshow=function(){var e="animate-out",t="is-paused",i="is-active",n=".slideshow__slide",s=".is-selected",o=".slideshow-wrapper",a=".slideshow__pause",r=".product__thumb-item:not(.hide)",c=".product__thumb-item:not(.hide) a",d=".product__thumb-arrow",l={adaptiveHeight:!1,autoPlay:!1,avoidReflow:!1,childNav:null,childNavScroller:null,childVertical:!1,dragThreshold:7,fade:!1,friction:.8,initialIndex:0,pageDots:!1,pauseAutoPlayOnHover:!1,prevNextButtons:!1,rightToLeft:theme.config.rtl,selectedAttraction:.14,setGallerySize:!0,wrapAround:!0};function h(e,t){if(this.el=e,this.args=Object.assign({},l,t),this.args.on={ready:this.init.bind(this),change:this.slideChange.bind(this),settle:this.afterChange.bind(this)},this.args.childNav&&(this.childNavEls=this.args.childNav.querySelectorAll(r),this.childNavLinks=this.args.childNav.querySelectorAll(c),this.arrows=this.args.childNav.querySelectorAll(d),this.childNavLinks.length&&this.initChildNav()),this.args.avoidReflow&&function(e){if(!e.id)return;var t=e.firstChild;for(;null!=t&&3==t.nodeType;)t=t.nextSibling;var i=document.createElement("style");i.innerHTML=`#${e.id} .flickity-viewport{height:${t.offsetHeight}px}`,document.head.appendChild(i)}(e),this.slideshow=new Flickity(e,this.args),this.args.autoPlay){var i=e.closest(o);this.pauseBtn=i.querySelector(a),this.pauseBtn&&this.pauseBtn.addEventListener("click",this._togglePause.bind(this))}window.on("resize",theme.utils.debounce(300,function(){this.resize()}.bind(this)))}return h.prototype=Object.assign({},h.prototype,{init:function(e){this.currentSlide=this.el.querySelector(s),this.args.callbacks&&this.args.callbacks.onInit&&"function"==typeof this.args.callbacks.onInit&&this.args.callbacks.onInit(this.currentSlide),window.AOS&&AOS.refresh()},slideChange:function(t){this.args.fade&&this.currentSlide&&(this.currentSlide.classList.add(e),this.currentSlide.addEventListener("transitionend",function(){this.currentSlide.classList.remove(e)}.bind(this))),this.args.childNav&&this.childNavGoTo(t),this.args.callbacks&&this.args.callbacks.onChange&&"function"==typeof this.args.callbacks.onChange&&this.args.callbacks.onChange(t),this.arrows&&this.arrows.length&&(this.arrows[0].classList.toggle("hide",0===t),this.arrows[1].classList.toggle("hide",t===this.childNavLinks.length-1))},afterChange:function(t){this.args.fade&&this.el.querySelectorAll(n).forEach(t=>{t.classList.remove(e)}),this.currentSlide=this.el.querySelector(s),this.args.childNav&&this.childNavGoTo(this.slideshow.selectedIndex)},destroy:function(){this.args.childNav&&this.childNavLinks.length&&this.childNavLinks.forEach(e=>{e.classList.remove(i)}),this.slideshow.destroy()},_togglePause:function(){this.pauseBtn.classList.contains(t)?(this.pauseBtn.classList.remove(t),this.slideshow.playPlayer()):(this.pauseBtn.classList.add(t),this.slideshow.pausePlayer())},resize:function(){this.slideshow.resize()},play:function(){this.slideshow.playPlayer()},pause:function(){this.slideshow.pausePlayer()},goToSlide:function(e){this.slideshow.select(e)},setDraggable:function(e){this.slideshow.options.draggable=e,this.slideshow.updateDraggable()}
13,initChildNav:function(){this.childNavLinks[this.args.initialIndex].classList.add("is-active"),this.childNavLinks.forEach((e,t)=>{e.setAttribute("data-index",t),e.addEventListener("click",function(e){e.preventDefault(),this.goToSlide(this.getChildIndex(e.currentTarget))}.bind(this)),e.addEventListener("focus",function(e){this.goToSlide(this.getChildIndex(e.currentTarget))}.bind(this)),e.addEventListener("keydown",function(e){13===e.keyCode&&this.goToSlide(this.getChildIndex(e.currentTarget))}.bind(this))}),this.arrows.length&&this.arrows.forEach(e=>{e.addEventListener("click",this.arrowClick.bind(this))})},getChildIndex:function(e){return parseInt(e.dataset.index)},childNavGoTo:function(e){this.childNavLinks.forEach(e=>{e.classList.remove(i)});var t=this.childNavLinks[e];if(t.classList.add(i),this.args.childNavScroller)if(this.args.childVertical){var n=t.offsetTop;this.args.childNavScroller.scrollTop=n-100}else{var s=t.offsetLeft;this.args.childNavScroller.scrollLeft=s-100}},arrowClick:function(e){e.currentTarget.classList.contains("product__thumb-arrow--prev")?this.slideshow.previous():this.slideshow.next()}}),h}(),theme.VariantAvailability=function(){var e="disabled";function t(e){this.type=e.type,this.variantsObject=e.variantsObject,this.currentVariantObject=e.currentVariantObject,this.container=e.container,this.namespace=e.namespace,this.init()}return t.prototype=Object.assign({},t.prototype,{init:function(){this.container.on("variantChange"+this.namespace,this.setAvailability.bind(this)),this.setAvailability(null,this.currentVariantObject)},setAvailability:function(e,t){if(e)t=e.detail.variant;var i={option1:[],option2:[],option3:[]},n=this.variantsObject.filter((function(e){return!(!t||t.id===e.id)&&(t.option2===e.option2&&t.option3===e.option3||(t.option1===e.option1&&t.option3===e.option3||(t.option1===e.option1&&t.option2===e.option2||void 0)))})),s=Object.assign({},{variant:t},n);for(var o in this.container.querySelectorAll(".variant-input-wrap").forEach(e=>{this.disableVariantGroup(e)}),s)if(s.hasOwnProperty(o)){var a=s[o];if(!a)return;var r=a.option1,c=a.option2,d=a.option3,l=!1===a.available;r&&i.option1.push({value:r,soldOut:l}),c&&i.option2.push({value:c,soldOut:l}),d&&i.option3.push({value:d,soldOut:l})}for(var[h,u]of Object.entries(i))this.manageOptionState(h,u)},manageOptionState:function(e,t){var i=this.container.querySelector('.variant-input-wrap[data-index="'+e+'"]');t.forEach(e=>{this.enableVariantOption(i,e)})},enableVariantOptionByValue:function(e,t){for(var i=this.container.querySelector('.variant-input-wrap[data-index="'+t+'"]'),n=0;n<e.length;n++)this.enableVariantOption(i,e[n])},enableVariantOption:function(t,i){var n=i.value.replace(/([ #;&,.+*~\':"!^$[\]()=>|\/@])/g,"\\$1");if("dropdown"===this.type)t.querySelector('option[value="'+n+'"]').disabled=!1;else{var s=t.querySelector('.variant-input[data-value="'+n+'"]'),o=s.querySelector("input"),a=s.querySelector("label");o.classList.remove(e),a.classList.remove(e),i.soldOut&&(o.classList.add(e),a.classList.add(e))}},disableVariantGroup:function(t){"dropdown"===this.type?t.querySelectorAll("option").forEach(e=>{e.disabled=!0}):(t.querySelectorAll("input").forEach(t=>{t.classList.add(e)}),t.querySelectorAll("label").forEach(t=>{t.classList.add(e)}))}}),t}(),theme.videoModal=function(){var e,t='a[href*="youtube.com/watch"], a[href*="youtu.be/"]',i=".product-video-trigger--mp4",n=".product-video-mp4-sound",s=document.querySelectorAll(t),o=document.querySelectorAll(i);if(s.length||o.length){var a=document.getElementById("VideoHolder");s.length&&theme.LibraryLoader.load("youtubeSdk");var r=new theme.Modals("VideoModal","video-modal",{closeOffContentClick:!0,bodyOpenClass:["modal-open","video-modal-open"],solid:!0});s.forEach(e=>{e.addEventListener("click",c)}),o.forEach(e=>{e.addEventListener("click",d)}),document.addEventListener("modalClose.VideoModal",(function(){e&&"function"==typeof e.destroy?e.destroy():h()}))}function c(t){if(theme.config.youTubeReady){t.preventDefault(),h(),r.open(t);var i,n,s=(i=t.currentTarget.getAttribute("href"),!(!(n=i.match(/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/))||11!=n[7].length)&&n[7]);e=new theme.YouTube("VideoHolder",{videoId:s,style:"sound",events:{onReady:l}})}}function d(e){h();var t=e.currentTarget.parentNode.querySelector(n).cloneNode(!0);t.classList.remove("hide"),a.append(t),r.open(e),a.querySelector("video").play()}function l(e){e.target.unMute(),e.target.playVideo()}function h(){a.innerHTML=""}},theme.ProductScreen=function(){var e=document.title,t="productscreen",i=0,n=(document.getElementById("MainContent"),{close:".js-screen-close",openClass:"screen-layer--is-active",closeSlideAnimate:["screen-layer--is-sliding"],bodyOpenClass:"screen-layer-open",bodyClosingClass:["screen-layer-closing"],bodyCloseAnimate:["screen-layer-closing","screen-layer-animating"],loaderStart:200,pullToCloseThreshold:-100});function s(e,t){this.id=e,this.screen=document.getElementById(e),this.screen&&(this.nodes={loader:document.getElementById("OverscrollLoader").querySelector(".icon-loader__path"),screenContent:this.screen.querySelector(".screen-layer__inner"),photoswipe:document.querySelector(".pswp")},this.title=this.screen.dataset.productTitle,this.openBtnClass=".js-screen-open-"+t,this.initialized=!1,this.isOpen=!1,this.focusOnOpen=n.focusOnOpen?this.screen.querySelector(n.focusOnOpen):this.screen,this.init())}return s.prototype=Object.assign({},s.prototype,{init:function(){document.querySelectorAll(this.openBtnClass).forEac
13h(e=>{e.setAttribute("aria-expanded","false"),e.addEventListener("click",this.open.bind(this))}),this.screen.querySelectorAll(n.close).forEach(e=>{e.on("click."+t,function(e){this.close(!1,{noAnimate:!0,back:!0})}.bind(this))}),"sticky"===theme.settings.cartType&&(document.addEventListener("ajaxProduct:added:"+this.id,function(){theme.headerNav.toggleThumbMenu(!1,!0);this.close(!1,{back:!0})}.bind(this)),document.addEventListener("ajaxProduct:error:"+this.id,function(){this.initialized&&this.open()}.bind(this)))},open:function(e,s){this.screen=document.getElementById(this.id);var o=!1,a={updateCurrentPath:!s||s.updateCurrentPath};if(!this.isOpen){e?e.preventDefault():o=!0,e&&e.stopPropagation&&(e.stopPropagation(),this.activeSource=e.currentTarget),this.isOpen&&!o&&this.close(),i=window.scrollY,theme.utils.prepareTransition(this.screen,function(){this.screen.classList.add(n.openClass)}.bind(this)),document.documentElement.classList.add(n.bodyOpenClass),document.body.classList.add(n.bodyOpenClass),this.nodes.screenContent.scrollTo(0,0),window.scrollTo(0,0),theme.a11y.trapFocus({container:this.screen,elementToFocus:this.focusOnOpen,namespace:t}),this.activeSource&&this.activeSource.hasAttribute("aria-expanded")&&this.activeSource.setAttribute("aria-expanded","true");var r=this.activeSource.dataset.url;document.dispatchEvent(new CustomEvent("productModalOpen."+this.id)),document.dispatchEvent(new CustomEvent("newPopstate",{detail:{screen:this,url:r,updateCurrentPath:a.updateCurrentPath}})),this.initialized=!0,this.isOpen=!0,document.title=this.title,window.ga&&ga("send","pageview",{page:r}),this.bindEvents()}},close:function(s,o){var a=o||(s?s.data:null),r=!!a&&a.back,c=!(!a||!a.noAnimate);document.body.removeAttribute("style"),this.nodes.loader.style.strokeDashoffset=n.loaderStart,r&&document.dispatchEvent(new CustomEvent("newPopstate",{detail:{screen:this,back:!0}}));var d=c?[]:n.closeSlideAnimate,l=c?n.bodyClosingClass:n.bodyCloseAnimate;this.isOpen&&(document.activeElement.blur(),theme.utils.prepareTransition(this.screen,function(){this.screen.classList.remove(n.openClass),this.screen.classList.add(...d),this.screen.classList.remove("is-transitioning")}.bind(this)),document.documentElement.classList.remove(n.bodyOpenClass),document.body.classList.remove(n.bodyOpenClass),document.documentElement.classList.add(...l),document.body.classList.add(...l),window.setTimeout(function(){this.screen.classList.remove(...d),document.documentElement.classList.remove(...l),document.body.classList.remove(...l),window.scrollTo(0,i)}.bind(this),500),theme.a11y.removeTrapFocus({container:this.screen,namespace:t}),this.activeSource&&this.activeSource.hasAttribute("aria-expanded")&&(this.activeSource.setAttribute("aria-expanded","false"),this.activeSource.focus()),document.body.dispatchEvent(new CustomEvent("productModalClose")),document.body.dispatchEvent(new CustomEvent("productModalClose."+this.id)),window.scrollTo(0,i),this.isOpen=!1,document.title=e,window.ga&&ga("send","pageview"),this.unbindEvents())},bindEvents:function(){window.on("keyup."+t,function(e){if(27===e.keyCode){if(this.nodes.photoswipe.classList.contains("pswp--open"))return;if(document.body.classList.contains("js-drawer-open"))return;this.close(!1,{back:!0})}}.bind(this));var e=0,i=0;window.on("touchmove."+t,theme.utils.throttle(15,function(){var t=window.scrollY;t>=0||(e=-t/100,document.body.style.background="rgba(0,0,0,"+e+")",i=n.loaderStart+2*t,t<=n.pullToCloseThreshold&&(i=0),this.nodes.loader.style.strokeDashoffset=i)}.bind(this))),window.on("touchend."+t,function(){if(window.scrollY<n.pullToCloseThreshold){this.close(!1,{back:!0})}}.bind(this))},unbindEvents:function(){window.off("keyup."+t),window.off("touchmove."+t),window.off("touchend."+t)}}),s}(),theme.QuickShopScreens=function(){var e=window.location.pathname,t=e,i=null;"scrollRestoration"in history&&(history.scrollRestoration="manual");var n="#ProductScreens",s=".quick-product__btn",o=[];function a(e){e.close(),i=null,window.dispatchEvent(new Event("resize"))}function r(e){var t=[];return(e?e.querySelectorAll(s):document.querySelectorAll(s)).forEac
13h(e=>{var i=e.dataset.productId;if(t.indexOf(i)>-1){var n=document.querySelector('.screen-layer--product[data-product-id="'+i+'"]');n&&n.parentNode.removeChild(n)}else t.push(i)}),t}function c(e){for(var t,i,s=document.createDocumentFragment(),a=0;a<e.length;a++)-1===o.indexOf(e[a])&&(t="ProductScreen-"+e[a],(i=document.getElementById(t))&&(s.appendChild(i),o.push(e[a])));document.querySelector(n).appendChild(s);for(a=0;a<o.length;a++)t="ProductScreen-"+o[a],new theme.ProductScreen(t,"product-"+o[a])}return{init:function(n){theme.settings.quickView&&(c(r()),function(){if(Shopify.designMode)return;document.addEventListener("newPopstate",(function(n){if(n.detail){var s=n.detail;i=s.screen,s.back&&(location.pathname,t=e,history.pushState({},"",e)),s.url&&s.updateCurrentPath&&(location.pathname,t=s.url,history.pushState({},"",s.url))}})),window.addEventListener("popstate",function(n){var s=!1;if(t,location.pathname!==t)if(t,t=location.pathname,location.pathname!==e)if(-1===location.pathname.indexOf("/products/")){if(n.originalEvent&&n.originalEvent.state){if(i&&i.isOpen)return a(i),void history.replaceState({},"",e);s=!0}else if(i){if(i.isOpen)return void a(i)}else s=!0;s&&(window.location.href=location.href)}else{i?i.open():document.querySelector('.quick-product__btn[href="'+location.pathname+'"]').dispatchEvent(new Event("click"),{updateCurrentPath:!1})}else i&&i.isOpen&&a(i)}.bind(this))}())},unload:function(e){if(theme.settings.quickView){for(var t,i=[],n=r(e),o=document.querySelectorAll(s),a=(t=[],o.forEach(e=>{var i=e.dataset.productId;t.push(i)}),t),c=0;c<n.length;c++){var d=n[c];-1===a.indexOf(d)&&i.push(d)}for(c=0;c<i.length;c++)sections._removeInstance(i[c])}},reInit:function(e){if(theme.settings.quickView){var t=r(e);!function(e,t){for(var i=0;i<e.length;i++){var n=t.querySelector('.screen-layer--product[data-product-id="'+e[i]+'"]');n&&n.parentNode.removeChild(n)}}(t,e),c(t);var i=document.getElementById("ProductScreens");theme.sections.register("product-template",theme.Product,i)}}}}(),theme.HoverProductGrid=function(){var e=".grid-product",t=".product-slider";function i(t){this.container=t,this.sectionId=this.container.getAttribute("data-section-id"),this.namespace=".product-image-slider-"+this.sectionId,this.activeIds=[],this.allSliders={},theme.settings.hoverProductGrid&&(this.products=t.querySelectorAll(e),this.slidersMobile=t.dataset.productSlidersMobile,0!==this.products.length&&theme.promiseStylesheet().then(function(){this.init()}.bind(this)))}return i.prototype=Object.assign({},i.prototype,{init:function(){this.destroyAllSliders(),this.setupEventType(),this.listnerSetup()},setupEventType:function(){this.products.forEach(e=>{e.off("mouseenter"+this.namespace),e.off("mouseout"+this.namespace)}),window.off("scroll"+this.namespace),theme.config.bpSmall?this.slidersMobile&&this.inViewSliderInit():this.mouseSliderInit()},listnerSetup:function(){document.addEventListener("matchSmall",function(){this.destroyAllSliders(),this.setupEventType()}.bind(this)),document.addEventListener("unmatchSmall",function(){this.destroyAllSliders(),this.setupEventType()}.bind(this))},inViewSliderInit:function(){this.products.forEach(e=>{new IntersectionObserver((i,n)=>{i.forEach(i=>{var n=e.querySelector(t);theme.config.bpSmall&&(i.isIntersecting?this.initSlider(n):this.destroySlider(n))})},{threshold:1}).observe(e)})},mouseSliderInit:function(){this.products.forEach(e=>{var i=e.querySelector(t);e.on("mouseenter"+this.namespace,function(){this.initSlider(i)}.bind(this)),e.on("mouseleave"+this.namespace,function(e){this.destroySlider(i)}.bind(this))})},initSlider:function(e){!e.dataset||e.dataset.imageCount<2||-1===this.activeIds.indexOf(e.dataset.id)&&(e.classList.add("product-slider--init"),this.allSliders[e.dataset.id]=new theme.Slideshow(e,{autoPlay:1050,fade:!0,avoidReflow:!0}),this.activeIds.push(e.dataset.id))},destroySlider:function(e){if(e.dataset&&!(e.dataset.imageCount<2)){var t=this.activeIds.indexOf(e.dataset.id);if(-1!==t){this.activeIds.splice(t,1);var i=this.allSliders[e.dataset.id];i&&"function"==typeof i.destroy&&i.destroy()}}}
13,destroyAllSliders:function(){this.products.forEach(e=>{var i=e.querySelector(t);this.destroySlider(i)})}}),i}(),theme.slideNav=function(){var e,t,i,n,s,o,a="#PageContainer",r=".slide-nav__overflow",c="#SlideNav",d=".js-toggle-slide-nav",l=".js-toggle-submenu",h=".site-nav__thumb-button",u="slide-nav__return-btn",m="is-active",p="js-menu--is-open",f="sub-nav--is-open",v="third-nav--is-open",g=!0,y=1,S=null;function b(e){(S=e.currentTarget).classList.contains(m)?w():function(e){if(s.forEach(e=>{e.classList.add(m)}),theme.utils.prepareTransition(n,(function(){n.classList.add(p)})),g){var t=document.querySelector(r).clientHeight;i.style.transform="translate3d(0, "+t+"px, 0)"}n.setAttribute("tabindex","-1"),n.focus(),window.on("keyup.slideNav",(function(e){27===e.keyCode&&w()}))}()}function w(){s.forEach(e=>{e.classList.remove(m)}),theme.utils.prepareTransition(n,(function(){n.classList.remove(p)})),g&&i.removeAttribute("style"),S.focus(),S=null,window.off("keyup.slideNav")}function L(s){if(!e){var o=s.currentTarget,a=o.classList.contains(u);if(e=!0,a){document.querySelectorAll(l+'[data-level="'+(y-1)+'"]').forEach(e=>{e.classList.remove(m)}),document.querySelectorAll('.slide-nav__dropdown[data-level="'+y+'"]').forEach(e=>{theme.utils.prepareTransition(e,(function(){e.classList.remove(m)}))}),t&&t.classList.remove(m)}else{o.classList.add(m);var r=o.nextElementSibling;theme.utils.prepareTransition(r,(function(){r.classList.add(m)}))}t=o,function(t){var s=t?document.querySelector('.slide-nav__dropdown[data-parent="'+t+'"]'):document.querySelector(c);y=s.dataset.level?parseInt(s.dataset.level):1,s;var o=s.clientHeight,a=y>2?v:f;n.style.height=o+"px",n.classList.remove(v),n.classList.add(a),t||(n.classList.remove(v),n.classList.remove(f));e=!1,g&&(i.style.transform="translate3d(0, "+o+"px, 0)")}(o.dataset.target)}}return{init:function(){document.querySelector(h)&&(g=!1),i=document.querySelector(a),n=document.querySelector(r),s=document.querySelectorAll(d),o=document.querySelectorAll(l),s.forEach(e=>{e.on("click.slideNav",b)}),o.forEach(e=>{e.on("click.slideNav",L)})},unload:function(){window.off(".slideNav")}}}(),theme.promiseStylesheet=function(e){var t=e||theme.stylesheet;return void 0===this.stylesheetPromise&&(this.stylesheetPromise=new Promise((function(e){var i=document.querySelector('link[href="'+t+'"]');i.loaded?e():(i.addEventListener("load",(function(){setTimeout(e,0)})),setTimeout(e,1))}))),this.stylesheetPromise},window.onpageshow=function(e){e.persisted&&(document.body.classList.remove("unloading"),document.querySelectorAll(".cart__checkout").forEach(e=>{e.classList.remove("btn--loading")}),document.querySelectorAll("#StickySubmit").forEach(e=>{e.classList.remove("btn--loading")})),(event.persisted||void 0!==window.performance&&window.performance.navigation&&2===window.performance.navigation.type)&&theme.resetScrollPosition()},theme.resetScrollPosition=function(){if(theme.config.hasSessionStorage){var e=document.location.pathname;sessionStorage["scrollPosition_"+e]&&window.scrollTo(0,sessionStorage.getItem("scrollPosition_"+e))}},theme.storeScrollPositionOnUnload=function(){if(theme.config.hasSessionStorage){var e=theme.config.isSafari?"pagehide":"beforeunload";window.addEventListener(e,(function(e){var t=window.scrollY;sessionStorage.setItem("scrollPosition_"+document.location.pathname,t.toString())}))}},theme.pageTransitions=function(){"true"===document.body.dataset.transitions&&(theme.config.isSafari&&document.querySelectorAll("a").forEach(e=>{window.setTimeout((function(){document.body.classList.remove("unloading")}),1200)}),document.querySelectorAll('a[href^="mailto:"], a[href^="#"], a[target="_blank"], a[href*="youtube.com/watch"], a[href*="youtu.be/"], a[download]').forEach(e=>{e.classList.add("js-no-transition")}),document.querySelectorAll("a:not(.js-no-transition)").forEach(e=>{e.addEventListener("click",(function(t){if(t.metaKey)return!0;var i=e.getAttribute("href");if(i.indexOf(location.pathname)>=0&&i.indexOf("#")>=0)return!0;t.preventDefault(),document.body.classList.add("unloading"),window.setTimeout((function(){location.href=i}),50)}))}))},theme.headerNav=function(){var e,t,i=".header-wrapper",n=".site-header",s=".site-header__logo img",o=".site-nav__item",a=".site-nav__link",r=".site-nav__link--has-dropdown",c=".site-nav__dropdown-link--second-level",d=".site-nav__thumb-menu",l="site-nav--has-dropdown",h="site-nav__deep-dropdown-trigger",u="is-focused",m="body--sticky-cart-open",p="is-light",f="site-nav__thumb-menu--inactive",v="site-header--sticky",g="header-wrapper--sticky",y="site-header--opening",S={namespace:".siteNav",overlayHeader:!1,stickyActive:!1,forceStickyOnMobile:!1,forceCloseThumbNav:!1};function b(){E(),function(){if(document.body.classList.contains(m))return;theme.config.bpSmall&&"product"!==theme.template&&setTimeout((function(){S.forceStickyOnMobile=!0,C(!0)}),25)}(),"bar"===S.headerStyle&&function(){var e=document.createElement("div");if(e.classList.add("site-header-sticky"),theme.utils.wrap(t,e),theme.settings.overlayHeader)return;I(),setTimeout((function(){I(),0===document.querySelector(".site-header-sticky").offsetHeight&&setTimeout((function(){window.dispatchEvent(new Event("resize"))}),500)}),200)}()}function w(){E(),L(),"bar"===S.headerStyle&&I()}function L(){theme.config.bpSmall?S.headerStyle="button":S.headerStyle=e.dataset.headerStyle,S.stickyThreshold="button"===S.headerStyle?100:250,"button"!==S.headerStyle&&C(!1)}
13function E(){document.querySelectorAll(s).forEach(e=>{var t=e.clientWidth,i=e.closest(".header-item").clientWidth;t>i?e.style.maxWidth=i:e.removeAttribute("style")})}function I(){var e=document.querySelector(".site-header-sticky");if(e){var i=t.offsetHeight;e.style.height=i+"px"}}function k(e){if(window.scrollY>S.stickyThreshold){if(S.forceStickyOnMobile&&(S.forceStickyOnMobile=!1),S.stickyActive)return;"button"===S.headerStyle?C(!0):"bar"===S.headerStyle&&_(!0)}else{if(S.forceStickyOnMobile)return;if(!S.stickyActive)return;"button"===S.headerStyle?theme.config.bpSmall||C(!1):"bar"===S.headerStyle&&_(!1),theme.settings.overlayHeader||I()}}function C(e,t){if(S.forceCloseThumbNav)return;if(document.querySelector(".slide-nav__overflow--thumb").classList.contains("js-menu--is-open"))return;const i=document.querySelector(d);i&&i.classList.toggle(f,!e),S.stickyActive=e,S.forceCloseThumbNav=t}function _(i){"bar"===S.headerStyle&&(i?(t.classList.add(v),theme.settings.overlayHeader&&(e.classList.remove(p),e.classList.add(g)),setTimeout((function(){t.classList.add(y)}),100)):(t.classList.remove(y),t.classList.remove(v),theme.settings.overlayHeader&&(e.classList.add(p),e.classList.remove(g))),S.stickyActive=i)}return{init:function(){e=document.querySelector(i),t=document.querySelector(n),theme.settings.overlayHeader="true"===t.dataset.overlay,S.stickyActive=!1,function(){var e=!1,t=!1,i=!1;theme.config.isTouch&&document.querySelectorAll(r).forEach(e=>{e.on("touchend"+S.namespace,(function(e){e.currentTarget.parentNode.classList.contains(u)?window.location.replace(e.currentTarget.getAttribute("href")):(e.preventDefault(),m(),s(e.currentTarget))}))});function n(i){e&&p(),t&&f(),s(i.currentTarget)}function s(t){var n=t.parentNode;if(n.classList.contains(l)&&(n.classList.add(u),e=!0),!theme.config.isTouch&&!i){var s=theme.config.isTouch?"touchend":"click";i=!0,document.documentElement.on(s+S.namespace,function(){m(),document.documentElement.off(s+S.namespace),i=!1}.bind(this))}}function d(e,i){var n=e.parentNode;(n.classList.contains(h)||i)&&(n.classList.add(u),t=!0)}function m(){p(),f()}function p(){document.querySelectorAll(o).forEach(e=>{e.classList.remove(u)})}function f(){document.querySelectorAll(c).forEach(e=>{e.parentNode.classList.remove(u)})}document.querySelectorAll(a).forEach(e=>{e.on("focusin"+S.namespace,n),e.on("mouseover"+S.namespace,n),e.on("mouseleave"+S.namespace,m)}),document.querySelectorAll(c).forEach(e=>{theme.config.isTouch&&e.on("touchend"+S.namespace,(function(e){var t=e.currentTarget.parentNode;t.classList.contains(h)?t.classList.contains(u)?window.location.replace(e.currentTarget.getAttribute("href")):(e.preventDefault(),f(),d(e.currentTarget)):window.location.replace(e.currentTarget.getAttribute("href"))})),e.on("focusin"+S.namespace,(function(e){f(),d(e.currentTarget,!0)}))})}(),new theme.Modals("SearchModal","search-modal",{closeOffContentClick:!1,focusIdOnOpen:"SearchModalInput"}),window.on("resize"+S.namespace,theme.utils.debounce(150,w)),window.on("load"+S.namespace,b),L(),window.on("scroll"+S.namespace,theme.utils.throttle(150,k)),window.on("scroll"+S.namespace,theme.utils.debounce(150,k)),Shopify.designMode&&window.dispatchEvent(new Event("resize"))},disableOverlayHeader:function(){e.classList.remove(S.overlayEnabledClass),e.classList.remove(S.overlayedClass),theme.settings.overlayHeader=!1},toggleThumbMenu:C,unload:function(){window.off(S.namespace)}}}(),theme.articleImages=function(){var e=document.querySelectorAll(".rte--indented-images");e.length&&e.forEach(e=>{e.querySelectorAll("img").forEach(t=>{var i=t.getAttribute("style");i&&"float: none;"!=i||t.width<e.offsetWidth&&t.classList.add("rte__no-indent")})})},theme.customerTemplates=function(){function e(){document.getElementById("RecoverPasswordForm").classList.toggle("hide"),document.getElementById("CustomerLoginForm").classList.toggle("hide")}"#recover"===window.location.hash&&e(),function(){var t=document.getElementById("RecoverPassword");t&&t.addEventListener("click",(function(t){t.preventDefault(),e()}));var i=document.getElementById("HideRecoverPasswordLink");i&&i.addEventListener("click",(function(t){t.preventDefault(),e()}))}(),function(){if(!document.querySelector(".reset-password-success"))return;document.getElementById("ResetSuccess").classList.remove("hide")}(),function(){var e=document.getElementById("AddressNewForm"),t=document.querySelectorAll(".js-address-form");if(!e||!t.length)return;setTimeout((function(){document.querySelectorAll(".js-address-country").forEach(e
13=>{var t=e.dataset.countryId,i=e.dataset.provinceId,n=e.dataset.provinceContainerId;new Shopify.CountryProvinceSelector(t,i,{hideElement:n})})}),1e3),document.querySelectorAll(".address-new-toggle").forEach(t=>{t.addEventListener("click",(function(){e.classList.toggle("hide")}))}),document.querySelectorAll(".address-edit-toggle").forEach(e=>{e.addEventListener("click",(function(e){var t=e.currentTarget.dataset.formId;document.getElementById("EditAddress_"+t).classList.toggle("hide")}))}),document.querySelectorAll(".address-delete").forEach(e=>{e.addEventListener("click",(function(e){var t=e.currentTarget.dataset.formId,i=e.currentTarget.dataset.confirmMessage;confirm(i||"Are you sure you wish to delete this address?")&&Shopify&&Shopify.postLink("/account/addresses/"+t,{parameters:{_method:"delete"}})}))})}()},theme.CartDrawer=function(){var e="#CartDrawerForm";function t(){this.form=document.querySelector(e),this.drawer=new theme.Drawers("CartDrawer","cart"),this.init()}return t.prototype=Object.assign({},t.prototype,{init:function(){this.cartForm=new theme.CartForm(this.form),this.cartForm.buildCart(),document.addEventListener("ajaxProduct:added",function(e){document.body.classList.add("cart-has-items"),this.cartForm.buildCart(),this.open()}.bind(this)),document.addEventListener("cart:open",this.open.bind(this)),document.addEventListener("cart:close",this.close.bind(this))},open:function(){this.drawer.open()},close:function(){this.drawer.close()}}),t}(),theme.refreshCart=function(){"sticky"===theme.settings.cartType&&theme.StickyCart&&theme.cart.getCart().then((function(e){theme.StickyCart.refresh(e)}))},theme.StickyCart=function(){var e="#StickyCart",t="#StickyItems",i="#StickySubtotal",n="#StickySubmit",s="template-cart",o="sticky-cart--open",a="body--sticky-cart-open";function r(){this.status={loaded:!1,loading:!1,open:document.body.classList.contains(a)},document.querySelector(e)&&this.initEventListeners()}return r.prototype=Object.assign({},r.prototype,{initEventListeners:function(){var e=document.querySelector(n);e.addEventListener("click",(function(){e.classList.add("btn--loading")})),document.addEventListener("ajaxProduct:added",function(){this.hideCart(),theme.cart.getCart().then(function(e){this.buildCart(e,!0)}.bind(this))}.bind(this))},hideCart:function(){document.body.classList.remove(a),document.querySelector(e).classList.remove(o)},showCart:function(n,s){n&&(document.querySelector(t).innerText=theme.strings.cartItems.replace("[count]",n)),s&&(document.querySelector(i).innerHTML=theme.Currency.formatMoney(s,theme.settings.moneyFormat)),document.body.classList.add(a),document.querySelector(e).classList.add(o),this.status.open=!0},buildCart:function(e,t){this.loading(!0),this.status.loaded=!0,this.loading(!1),!0===t&&this.showCart(e.item_count,e.total_price)},loading:function(t){this.status.loading=t,t?document.querySelector(e).classList.add("is-loading"):document.querySelector(e).classList.remove("is-loading")},updateError:function(e){e.responseJSON&&e.responseJSON.description&&console.warn(e.responseJSON.description)}}),{init:r,refresh:function(n){document.body.classList.contains(s)||(n.item_count>0?(document.body.classList.add(a),document.querySelector(e).classList.add(o)):(document.body.classList.remove(a),document.querySelector(e).classList.remove(o)),document.querySelector(t).innerText=theme.strings.cartItems.replace("[count]",n.item_count),document.querySelector(i).innerHTML=theme.Currency.formatMoney(n.total_price,theme.settings.moneyFormat))}}}(),theme.Product=function(){var e={},t="sale-price",i="disabled",n="is-modal",s="hide",o="visually-invisible",a="thumb--current",r={variantsJson:"[data-variant-json]",currentVariantJson:"[data-current-variant-json]",imageContainer:"[data-product-images]",mainSlider:"[data-product-photos]",thumbSlider:"[data-product-thumbs]",thumbScroller:"[data-product-thumbs-scroller]",photo:"[data-product-photo]",photoThumbs:"[data-product-thumb]",photoThumbItem:"[data-product-thumb-item]",zoomButton:".product__photo-zoom",priceWrapper:"[data-price-wrapper]",price:"[data-product-price]",comparePrice:"[data-product-price-compare]",priceA
1311y:"[data-price-a11y]",comparePriceA11y:"[data-compare-a11y]",sku:"[data-sku]",inventory:"[data-product-inventory]",incomingInventory:"[data-product-incoming-inventory]",unitWrapper:"[data-product-unit-wrapper]",addToCart:"[data-add-to-cart]",addToCartText:"[data-add-to-cart-text]",variantType:".variant-wrapper",originalSelectorId:"[data-product-select]",singleOptionSelector:"[data-variant-input]",variantColorSwatch:"[data-color-swatch]",productImageMain:".product-image-main",productVideo:"[data-product-video]",videoParent:".product__video-wrapper",slide:".product-main-slide",currentSlide:".is-selected",startingSlide:".starting-slide",media:"[data-product-media-type-model]",closeMedia:".product-single__close-media",blocks:"[data-product-blocks]",blocksHolder:"[data-blocks-holder]",formContainer:".product-single__form",availabilityContainer:"[data-store-availability]"};function c(e){this.container=e,this.sectionId=e.getAttribute("data-section-id"),this.productId=e.getAttribute("data-product-id"),this.inModal="true"===e.dataset.modal,this.modal,this.namespace=".product-"+this.sectionId,this.namespaceImages=".product-image-"+this.sectionId,this.settings={enableHistoryState:"true"===e.dataset.history||!1,namespace:".product-"+this.sectionId,inventory:!1,inventoryThreshold:10,modalInit:!1,hasImages:!0,hasVideos:e.querySelectorAll(r.productVideo).length||!1,videoStyle:e.dataset.videoStyle,has3d:!1,imageSetName:null,imageSetIndex:null,currentImageSet:null,stackedImages:e.dataset.imagesStacked||!1,stackedCurrent:0,stackedImagePositions:[],imageSize:"620x",currentSlideIndex:0,videoLooping:e.dataset.videoLooping},this.videos={},this.inModal&&(this.settings.enableHistoryState=!1,this.namespace=".product-"+this.sectionId+"-modal",this.modal=document.getElementById("ProductScreen-"+this.sectionId)),this.init()}return c.prototype=Object.assign({},c.prototype,{init:function(){this.mainSlider=this.container.querySelector(r.mainSlider),this.thumbSlider=this.container.querySelector(r.thumbSlider),this.firstProductImage=this.mainSlider.querySelector("img"),this.firstProductImage||(this.settings.hasImages=!1);var e=this.mainSlider.querySelector("[data-set-name]");this.settings.imageSetName=!!e&&e.dataset.setName,this.inModal&&(this.container.classList.add(n),document.removeEventListener("productModalOpen.ProductScreen-"+this.sectionId,this.openModalProduct.bind(this)),document.removeEventListener("productModalClose.ProductScreen-"+this.sectionId,this.openModalProduct.bind(this)),document.addEventListener("productModalOpen.ProductScreen-"+this.sectionId,this.openModalProduct.bind(this)),document.addEventListener("productModalClose.ProductScreen-"+this.sectionId,this.closeModalProduct.bind(this))),this.inModal||(this.formSetup(),this.preImageSetup(),this.videoSetup(),this.initProductSlider())},formSetup:function(){this.initAjaxProductForm(),this.availabilitySetup(),this.initVariants(),this.settings.imageSetName&&this.updateImageSet()},availabilitySetup:function(){var e=this.container.querySelector(r.availabilityContainer);e&&(this.storeAvailability=new theme.StoreAvailability(e))},initVariants:function(){var e=this.container.querySelector(r.variantsJson);if(e){this.variantsObject=JSON.parse(e.innerHTML);var t={container:this.container,enableHistoryState:this.settings.enableHistoryState,singleOptionSelector:r.singleOptionSelector,originalSelectorId:r.originalSelectorId,variants:this.variantsObject},i=this.container.querySelectorAll(r.variantColorSwatch);if(i.length&&i.forEach(e=>{e.addEventListener("change",function(t){var i=e.dataset.colorName,n=e.dataset.colorIndex;this.updateColorName(i,n)}.bind(this))}),this.variants=new theme.Variants(t),this.storeAvailability){var n=this.variants.currentVariant?this.variants.currentVariant.id:this.variants.variants[0].id;this.storeAvailability.updateContent(n),this.container.on("variantChange"+this.settings.namespace,this.updateAvailability.bind(this))}this.container.on("variantChange"+this.namespace,this.updateCartButton.bind(this)),this.container.on("variantImageChange"+this.settings.namespace,this.updateV
13ariantImage.bind(this)),this.container.on("variantPriceChange"+this.settings.namespace,this.updatePrice.bind(this)),this.container.on("variantUnitPriceChange"+this.settings.namespace,this.updateUnitPrice.bind(this)),this.container.querySelectorAll(r.sku).length&&this.container.on("variantSKUChange"+this.settings.namespace,this.updateSku.bind(this));var s=this.container.querySelector(r.inventory);if(s&&(this.settings.inventory=!0,this.settings.inventoryThreshold=s.dataset.threshold,this.container.on("variantChange"+this.settings.namespace,this.updateInventory.bind(this))),theme.settings.dynamicVariantsEnable){var o=this.container.querySelector(r.currentVariantJson);if(o){var a=this.container.querySelector(r.variantType);a&&new theme.VariantAvailability({container:this.container,namespace:this.settings.namespace,type:a.dataset.type,variantsObject:this.variantsObject,currentVariantObject:JSON.parse(o.innerHTML),form:this.container.querySelector(r.formContainer)})}}if(this.settings.imageSetName){var c=this.container.querySelector('.variant-input-wrap[data-handle="'+this.settings.imageSetName+'"]');c?(this.settings.imageSetIndex=c.dataset.index,this.container.on("variantChange"+this.settings.namespace,this.updateImageSet.bind(this))):this.settings.imageSetName=null}}},initAjaxProductForm:function(){if("drawer"===theme.settings.cartType||"sticky"===theme.settings.cartType){var e=this.container.querySelector(r.formContainer);new theme.AjaxProduct(e,r.addToCart,{scopedEventId:"ProductScreen-"+this.sectionId})}},updateColorName:function(e,t){var i=this.container.querySelector('[data-color-label][data-color-label-index="'+t+'"]');i&&(i.textContent=e)},updateCartButton:function(e){var t=e.detail.variant,n=this.container.querySelector(r.addToCart),s=this.container.querySelector(r.addToCartText);if(t)if(t.available){n.classList.remove(i),n.disabled=!1;var o=s.dataset.defaultText;s.textContent=o}else n.classList.add(i),n.disabled=!0,s.textContent=theme.strings.soldOut;else n.classList.add(i),n.disabled=!0,s.textContent=theme.strings.unavailable},updatePrice:function(e){var i=e.detail.variant;i&&(this.container.querySelector(r.price).innerHTML=theme.Currency.formatMoney(i.price,theme.settings.moneyFormat),i.compare_at_price>i.price?(this.container.querySelector(r.comparePrice).innerHTML=theme.Currency.formatMoney(i.compare_at_price,theme.settings.moneyFormat),this.container.querySelector(r.priceWrapper).classList.remove(s),this.container.querySelector(r.price).classList.add(t),this.container.querySelector(r.comparePriceA11y).setAttribute("aria-hidden","false"),this.container.querySelector(r.priceA11y).setAttribute("aria-hidden","false")):(this.container.querySelector(r.priceWrapper).classList.add(s),this.container.querySelector(r.price).classList.remove(t),this.container.querySelector(r.comparePriceA11y).setAttribute("aria-hidden","true"),this.container.querySelector(r.priceA11y).setAttribute("aria-hidden","true")))},updateUnitPrice:function(e){var t=e.detail.variant;if(t&&t.unit_price){var i=theme.Currency.formatMoney(t.unit_price,theme.settings.moneyFormat),n=theme.Currency.getBaseUnit(t),a=this.container.querySelector(r.unitWrapper);a.innerHTML=i+"/"+n,a.classList.remove(s,o)}else this.container.querySelector(r.unitWrapper).classList.add(o)},imageSetArguments:function(e){if(e=e||(this.variants?this.variants.currentVariant:null)){var t=this.settings.currentImageSet=this.getImageSetName(e[this.settings.imageSetIndex]),i=this.settings.imageSetName+"_"+t;return this.settings.currentSlideIndex=0,{cellSelector:'[data-group="'+i+'"]',imageSet:i,initialIndex:this.settings.currentSlideIndex}}},updateImageSet:function(e,t){var i=e?e.detail.variant:this.variants?this.variants.currentVariant:null;if(i){var n=this.getImageSetName(i[this.settings.imageSetIndex]),o=this.settings.imageSetName+"_"+n;if(this.settings.currentImageSet!==n)return!theme.config.bpSmall&&this.settings.stackedImages?(this.container.querySelectorAll("[data-group]").forEach(e=>{e.classList.add(s),e.dataset.group&&e.dataset.group===o&&e.classList.remove(s)}),this.stackedImagePositions(),AOS.refresh(),void(this.settings.currentImageSet=n)):(theme.config.bpSmall&&this.settings.stackedImages&&this.container.querySelectorAll("[data-group]").forEach(e
13=>{e.classList.remove(s)}),void this.initProductSlider(i))}},updateImageSetThumbs:function(e){this.settings.stackedImages||this.thumbSlider.querySelectorAll(".product__thumb-item").forEach(t=>{t.classList.toggle(s,t.dataset.group!==e)})},getImageSetName:function(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/-$/,"").replace(/^-/,"")},updateSku:function(e){var t=e.detail.variant,i="",n=!0;t&&(t.sku&&(i=t.sku,n=!1),this.container.querySelectorAll(r.sku).forEach(e=>{e.classList.toggle(s,n),e.textContent=i}))},updateInventory:function(e){var t=e.detail.variant;if(!t||!t.inventory_management||"continue"===t.inventory_policy)return this.toggleInventoryQuantity(t,!1),void this.toggleIncomingInventory(!1);if("shopify"===t.inventory_management&&window.inventories&&window.inventories[this.productId]){var i=window.inventories[this.productId][t.id];if("continue"===i.policy)return this.toggleInventoryQuantity(t,!1),void this.toggleIncomingInventory(!1);var n=i.quantity,s=!0,o=!1;(n<=0||n>this.settings.inventoryThreshold)&&(s=!1),this.toggleInventoryQuantity(t,s,n),!s&&"true"===i.incoming&&n<=this.settings.inventoryThreshold&&(o=!0),this.toggleIncomingInventory(o,t.available,i.next_incoming_date)}},updateAvailability:function(e){var t=e.detail.variant;t&&this.storeAvailability.updateContent(t.id)},toggleInventoryQuantity:function(e,t,i){this.settings.inventory;var n=this.container.querySelector(r.inventory),o=n.closest(".product-block");parseInt(i)<=parseInt(this.settings.inventoryThreshold)?(n.parentNode.classList.add("inventory--low"),n.textContent=theme.strings.stockLabel.replace("[count]",i)):(n.parentNode.classList.remove("inventory--low"),n.textContent=theme.strings.inStockLabel),e&&e.available?(n.parentNode.classList.remove(s),o&&o.classList.remove(s)):(n.parentNode.classList.add(s),o&&o.classList.add(s))},toggleIncomingInventory:function(e,t,i){var n=this.container.querySelector(r.incomingInventory),o=n.closest(".product-block");if(n){var a=n.querySelector(".js-incoming-text");if(e){var c=t?theme.strings.willNotShipUntil.replace("[date]",i):theme.strings.willBeInStockAfter.replace("[date]",i);i||(c=theme.strings.waitingForStock),n.classList.remove(s),o&&o.classList.remove(s),a.textContent=c}else n.classList.add(s)}},videoSetup:function(){var e=this.mainSlider.querySelectorAll(r.productVideo);if(!e.length)return!1;e.forEach(e=>{var t=e.dataset.videoType;"youtube"===t?this.initYoutubeVideo(e):"mp4"===t&&this.initMp4Video(e)})},initYoutubeVideo:function(t){e[t.id]=new theme.YouTube(t.id,{videoId:t.dataset.youtubeId,videoParent:r.videoParent,autoplay:!1,style:t.dataset.videoStyle,loop:t.dataset.videoLoop,events:{onReady:this.youtubePlayerReady.bind(this),onStateChange:this.youtubePlayerStateChange.bind(this)}})},youtubePlayerReady:function(t){var i=t.target.getIframe().id;if(e[i]){var n=e[i],s=n.videoPlayer;"sound"!==n.options.style&&s.mute(),n.parent.classList.remove("loading"),n.parent.classList.add("loaded"),this._isFirstSlide(i)&&"sound"!==n.options.style&&s.playVideo()}},_isFirstSlide:function(e){return this.mainSlider.querySelector(r.startingSlide+" #"+e)},youtubePlayerStateChange:function(t){var i=t.target.getIframe().id,n=e[i];switch(t.data){case-1:n.attemptedToPlay&&n.parent.classList.add("video-interactable");break;case 0:n&&"true"===n.options.loop&&n.videoPlayer.playVideo();break;case 3:n.attemptedToPlay=!0}},initMp4Video:function(t){e[t.id]={id:t.id,type:"mp4"},this._isFirstSlide(t.id)&&this.playMp4Video(t.id)},stopVideos:function(){for(var[t,i]of Object.entries(e))i.videoPlayer?"function"==typeof i.videoPlayer.stopVideo&&i.videoPlayer.stopVideo():"mp4"===i.type&&this.stopMp4Video(i.id)},_getVideoType:function(e){return e.getAttribute("data-video-type")},_getVideoDivId:function(e){return e.id},playMp4Video:function(e){var t=this.container.querySelector("#"+e),i=t.play();t.setAttribute("controls",""),t.focus(),t.addEventListener("focusout",this.returnFocusToThumbnail.bind(this)),void 0!==i&&i.then((function(){})).catch((function(e){t.setAttribute("controls",""),t.closest(r.videoParent).setAttribute("data-video-style","unmuted")}))},stopMp4Video:function(e){var t=this.container.querySelector("#"+e);t.removeEventListener("focusout",this.returnFocusToThumbnail.bind(this)),t&&"function"==typeof t.pause&&(t.removeAttribute("controls"),t.pause())},returnFocusToThumbnail:function(){var e=this.container.querySelector('.product__thumb-item[data-index="'+this.settings.currentSlideIndex+'"] a');e&&e.focus()},preImageSetup:function(){this.setImageSizes(),this.initImageSwitch(),this.initImageZoom(),this.customMediaListners(),this.initModelViewerLibraries(),this.initShopifyXrLaunch(),theme.collapsibles.init(this.container),window.SPR&&(SPR.initDomEls(),SPR.loadBadges())},initProductSlider:function(e){if(this.mainSlider.querySelectorAll(r.slide).length<=1){var t=this.mainSlider.querySelector(r.slide);t&&t.classList.add("is-selected")}else{if(this.settings.has3d=this.container.querySelectorAll(r.media).length,"muted"!==this.settings.videoStyle&&theme.videoModal(!0),!e){var i=this.mainSlider.querySelector(r.startingSlide);this.settings.currentSlideIndex=this._slideIndex(i)}var n={adaptiveHeight:!0,avoidReflow:!0,initialIndex:this.settings.currentSlideIndex,childNav:this.thumbSlider,childNavScroller:this.container.querySelector(r.thumbScroller),childVertical:"beside"===this.thumbSlider.dataset.position,fade:!this.settings.stackedImages,pageDots:!0,wrapAround:!0,callbacks:{onInit:this.onSliderInit.bind(this),onChange:this.onSlideChange.bind(this)}};if(this.settings.imageSetName){var s=this.imageSetArguments(e);n=Object.assign({},n,s),this.updateImageSetThumbs(n.imageSet)}this.initSliders(n),document.addEventListener("matchSmall",function(){this.initSliders(n,!0)}.bind(this)),document.addEventListener("unmatchSmall",function(){this.initSliders(n,!0)}.bind(this))}},onSliderInit:function(e){this.settings.imageSetName&&this.prepMediaOnSlide(e),0===this.mainSlider.offsetHeight&&setTimeout((function(){window.dispatchEvent(new Event("resize"))}),250)},onSlideChange:function(e){if(this.flickity){var t=this.mainSlider.querySelector('.product-main-slide[data-index="'+this.settings.currentSlideIndex+'"]'),i=this.settings.imageSetName?this.mainSlider.querySelectorAll(".flickity-slider .product-main-slide")[e]:this.mainSlider.querySelector('.product-main-slide[data-index="'+e+'"]');t.setAttribute("tabindex","-1"),i.setAttribute("tabindex",0),this.stopMediaOnSlide(t),this.prepMediaOnSlide(i),this.settings.currentSlideIndex=e}},stopMediaOnSlide(t){var i=t.querySelector(r.productVideo);if(i){var n=this._getVideoType(i),s=this._getVideoDivId(i);if("youtube"===n){if(e[s].videoPlayer)return void e[s].videoPlayer.stopVideo()}else if("mp4"===n)return void this.stopMp4Video(s)}var o=t.querySelector(r.media);o&&o.dispatchEvent(new CustomEvent("mediaHidden",{bubbles:!0,cancelable:!0}))},prepMediaOnSlide(t){var i=t.querySelector(r.productVideo);if(i){var n=this._getVideoType(i),s=this._getVideoDivId(i);
13if("youtube"===n){if(e[s].videoPlayer&&"sound"!==e[s].options.style)return void e[s].videoPlayer.playVideo()}else"mp4"===n&&this.playMp4Video(s)}var o=t.querySelector(r.media);o&&(o.dispatchEvent(new CustomEvent("mediaVisible",{bubbles:!0,cancelable:!0})),t.querySelector(".shopify-model-viewer-ui__button").setAttribute("tabindex",0),t.querySelector(".product-single__close-media").setAttribute("tabindex",0)),this.hideZoomOverlay(o)},_slideIndex:function(e){return e.getAttribute("data-index")},initImageZoom:function(){var e=this.container.querySelector(r.imageContainer);if(e){new theme.Photoswipe(e,this.sectionId);e.addEventListener("photoswipe:afterChange",function(e){this.flickity&&this.flickity.goToSlide(e.detail.index)}.bind(this))}},getThumbIndex:function(e){return e.dataset.index},setImageSizes:function(){if(this.settings.hasImages){var e=this.firstProductImage.currentSrc;e&&(this.settings.imageSize=theme.Images.imageSize(e))}},updateVariantImage:function(e){var t=e.detail.variant,i=(theme.Images.getSizedImageUrl(t.featured_media.preview_image.src,this.settings.imageSize),this.container.querySelector('.product-main-slide[data-id="'+t.featured_media.id+'"]')),n=this.getThumbIndex(i);void 0!==n&&(!theme.config.bpSmall&&this.settings.stackedImages?this.stackedScrollTo(n):this.flickity&&this.flickity.goToSlide(n))},initImageSwitch:function(){var e=this.container.querySelectorAll(r.photoThumbs);e.length&&e.forEach(e=>{e.addEventListener("click",function(t){if(t.preventDefault(),!theme.config.bpSmall&&this.settings.stackedImages){var i=this.getThumbIndex(e);this.stackedScrollTo(i)}}.bind(this)),e.addEventListener("focus",function(t){var i=this.getThumbIndex(e);theme.config.bpSmall||(this.settings.stackedImages?(this.container.querySelectorAll(r.photoThumbItem).forEach(e=>{e.classList.remove(a)}),this.stackedScrollTo(i)):this.flickity&&this.flickity.goToSlide(i))}.bind(this)),e.addEventListener("keydown",function(e){13===e.keyCode&&this.container.querySelector(r.currentSlide).focus()}.bind(this))})},stackedImagesInit:function(){window.off(this.namespaceImages),this.stackedImagePositions(),this.inModal?setTimeout(function(){this.stackedActive(this.settings.stackedCurrent)}.bind(this),1e3):this.stackedActive(this.settings.stackedCurrent),window.on("resize"+this.namespaceImages,theme.utils.debounce(200,this.stackedImagePositions.bind(this))),window.on("scroll"+this.namespaceImages,theme.utils.throttle(200,function(){var e=window.scrollY,t=this.settings.stackedImagePositions.reduce((function(t,i){return Math.abs(i-e)<Math.abs(t-e)?i:t})),i=this.settings.stackedImagePositions.indexOf(t);this.settings.stackedCurrent!==i&&this.stackedActive(i)}.bind(this)))},stackedImagePositions:function(){var e=[];this.container.querySelectorAll(r.photo).forEach(t=>{e.push(Math.round(t.offsetTop))}),this.settings.stackedImagePositions=e},stackedScrollTo:function(e){var t=this.container.querySelectorAll(r.photo)[e];if(t){var i=t.offsetTop;window.scroll({top:i,behavior:"smooth"})}},stackedActive:function(t){this.container.querySelectorAll(r.photoThumbItem).forEach(e=>{e.classList.remove(a),e.classList.remove("is-active")});var i=this.container.querySelectorAll(r.photoThumbItem)[t];if(i&&(i.classList.add(a),this.settings.currentSlideIndex=i.dataset.index),this.settings.hasVideos){this.stopVideos();var n=this.container.querySelectorAll(r.photo)[t].querySelector(".product__video");if(n){var s=this._getVideoType(n),o=this._getVideoDivId(n);if("youtube"===s){if(e[o].videoPlayer&&"sound"!==e[o].options.style)return void e[o].videoPlayer.playVideo()}else"mp4"===s&&this.playMp4Video(o)}}if(this.settings.has3d){var c=this.container.querySelectorAll(r.media);c.length&&c.forEach(e=>{e.dispatchEvent(new CustomEvent("mediaHidden"))});var d=this.container.querySelectorAll(r.photo)[t].querySelector(r.media);d&&d.dispatchEvent(new CustomEvent("mediaVisible"))}this.settings.stackedCurrent=t},initSliders:function(e,t){this.destroyImageCarousels(),!theme.config.bpSmall&&this.settings.stackedImages?this.stackedImagesInit():theme.promiseStylesheet().then(function(){this.flickity=new theme.Slideshow(this.mainSlider,e)}.bind(this))},destroyImageCarousels:function(){this.flickity&&"function"==typeof this.flickity.destroy&&this.flickity.destroy()},hideZoomOverlay:function(e){var t=this.container.querySelector(r.zoomButton);e?t&&t.classList.add(s):t&&t.classList.remove(s)},openModalProduct:function(){var e=!1;if(this.settings.modalInit)e=!0,!theme.config.bpSmall&&this.settings.stackedImages&&this.stackedActive(0);else{this.blocksHolder=this.container.querySelector(r.blocksHolder);var t=this.blocksHolder.dataset.url;fetch(t).then((function(e){return e.text()})).then(function(e){var t=(new DOMParser).parseFromString(e,"text/html"),i=t.querySelector(r.blocks);
13i.querySelectorAll("[id]").forEach(e=>{var t=e.getAttribute("id");e.setAttribute("id",t+"-modal");var n=i.querySelector(`[for="${t}"]`);n&&n.setAttribute("for",t+"-modal");var s=i.querySelector(`[aria-controls="${t}"]`);s&&s.setAttribute("aria-controls",t+"-modal")});var n=i.querySelector(r.formContainer).getAttribute("id");i.querySelectorAll("[form]").forEach(e=>{e.setAttribute("form",n)}),this.blocksHolder.innerHTML="",this.blocksHolder.append(i),this.formSetup(),this.updateModalProductInventory(),Shopify&&Shopify.PaymentButton&&Shopify.PaymentButton.init(),theme.collapsibles.init(this.container);var s=t.querySelectorAll("#MainContent .shopify-section:not(.shopify-section__product)");s.length&&this.loadProductSections(s);var o=t.querySelector(".index-section.social-section");o&&this.loadSocialSection(o),window.SPR&&(SPR.initDomEls(),SPR.loadBadges()),theme.sections.loadSubSections(this.modal),document.dispatchEvent(new CustomEvent("quickview:loaded",{detail:{productId:this.sectionId}})),this.preImageSetup(),this.initProductSlider(),this.settings.modalInit=!0}.bind(this))}document.dispatchEvent(new CustomEvent("quickview:open",{detail:{initialized:e,productId:this.sectionId}}))},updateModalProductInventory:function(){window.inventories=window.inventories||{},this.container.querySelectorAll(".js-product-inventory-data").forEach(e=>{var t=e.dataset.productId;window.inventories[t]={},e.querySelectorAll(".js-variant-inventory-data").forEach(e=>{window.inventories[t][e.dataset.id]={quantity:e.dataset.quantity,policy:e.dataset.policy,incoming:e.dataset.incoming,next_incoming_date:e.dataset.date}})})},closeModalProduct:function(){this.stopVideos(),window.off(this.namespace)},loadProductSections:function(e){var t=document.querySelector("#ProductSectionsHolder-"+this.productId);t&&(t.innerHTML="",t.append(...e),theme.collapsibles.init(t))},loadSocialSection:function(e){var t=document.querySelector("#SocialSectionHolder-"+this.productId);t&&t.replaceWith(e)},initModelViewerLibraries:function(){var e=this.container.querySelectorAll(r.media);e.length<1||theme.ProductMedia.init(e,this.sectionId)},initShopifyXrLaunch:function(){document.addEventListener("shopify_xr_launch",function(){this.container.querySelector(r.productMediaWrapper+":not(."+self.classes.hidden+")").dispatchEvent(new CustomEvent("xrLaunch",{bubbles:!0,cancelable:!0}))}.bind(this))},customMediaListners:function(){this.container.querySelectorAll(r.closeMedia).forEach(e=>{e.addEventListener("click",function(){if(this.settings.stackedImages)var e=this.mainSlider.querySelector('.product-main-slide[data-index="'+this.settings.currentSlideIndex+'"]');else e=this.mainSlider.querySelector(r.currentSlide);var t=e.querySelector(r.media);t&&t.dispatchEvent(new CustomEvent("mediaHidden",{bubbles:!0,cancelable:!0}))}.bind(this))});var e=this.container.querySelectorAll("model-viewer");e.length&&e.forEach(e=>{e.addEventListener("shopify_model_viewer_ui_toggle_play",function(e){this.mediaLoaded(e)}.bind(this)),e.addEventListener("shopify_model_viewer_ui_toggle_pause",function(e){this.mediaUnloaded(e)}.bind(this))})},mediaLoaded:function(e){this.container.querySelectorAll(r.closeMedia).forEach(e=>{e.classList.remove(s)}),this.flickity&&this.flickity.setDraggable(!1)},mediaUnloaded:function(e){this.container.querySelectorAll(r.closeMedia).forEach(e=>{e.classList.add(s)}),this.flickity&&this.flickity.setDraggable(!0)},onUnload:function(){window.off(this.namespace),this.container.off(this.namespace),this.destroyImageCarousels(),theme.ProductMedia.removeSectionModels(this.sectionId),AOS&&AOS.refresh()}}),c}(),theme.Blog=function(){function e(e){this.tagFilters()}return e.prototype=Object.assign({},e.prototype,{tagFilters:function(){var e=document.getElementById("BlogTagFilter");e&&e.addEventListener("change",(function(){location.href=e.value}))}}),e}(),theme.HeaderSection=function(){function e(e){this.initDrawers(),theme.headerNav.init(),theme.slideNav.init(),Shopify&&Shopify.designMode&&(theme.sections.reinit("slideshow-section"),setTimeout((function(){window.dispatchEvent(new Event("resize"))}),500))}return e.prototype=Object.assign({},e.prototype,{initDrawers:function(){"drawer"===theme.settings.cartType&&(document.body.classList.contains("template-cart")||new theme.CartDrawer)},onUnload:function(){theme.headerNav.unload(),theme.slideNav.unload()}}),e}(),theme.FooterSection=function(){var e="[data-disclosure-locale]",t="[data-disclosure-currency
13]";function i(e){this.container=e,this.localeDisclosure=null,this.currencyDisclosure=null,theme.initWhenVisible({element:this.container,callback:this.init.bind(this),threshold:1e3})}return i.prototype=Object.assign({},i.prototype,{init:function(){var i=this.container.querySelector(e),n=this.container.querySelector(t);i&&(this.localeDisclosure=new theme.Disclosure(i)),n&&(this.currencyDisclosure=new theme.Disclosure(n))},onUnload:function(){this.localeDisclosure&&this.localeDisclosure.destroy(),this.currencyDisclosure&&this.currencyDisclosure.destroy()}}),i}(),theme.Collection=function(){var e="#SortBy";function t(e){this.container=e,this.sectionId=e.getAttribute("data-section-id"),this.namespace=".collection-"+this.sectionId,document.querySelector(".collection-hero")?this.checkIfNeedReload():theme.settings.overlayHeader&&theme.headerNav.disableOverlayHeader(),this.init()}return t.prototype=Object.assign({},t.prototype,{init:function(){this.container=this.container,this.sectionId=this.container.getAttribute("data-section-id"),this.sortSelect=document.querySelector(e),this.sortSelect&&(this.sortSelect.on("change",this.onSortChange.bind(this)),this.defaultSort=this.getDefaultSortValue()),new theme.HoverProductGrid(this.container),this.initParams(),this.sortTags(),this.bindBackButton()},initParams:function(){if(this.queryParams={},location.search.length)for(var e,t=location.search.substr(1).split("&"),i=0;i<t.length;i++)(e=t[i].split("=")).length>1&&(this.queryParams[decodeURIComponent(e[0])]=decodeURIComponent(e[1]))},getSortValue:function(){return this.sortSelect.value||this.defaultSort},getDefaultSortValue:function(){return this.sortSelect.dataset.sortBy},onSortChange:function(){this.queryParams.sort_by=this.getSortValue(),this.queryParams.page&&delete this.queryParams.page,window.location.search=decodeURIComponent(new URLSearchParams(Object.entries(this.queryParams)))},sortTags:function(){var e=document.getElementById("SortTags");e&&e.on("change",(function(t){location.href=e.value}))},bindBackButton:function(){window.off("popstate"+this.namespace),window.on("popstate"+this.namespace,e=>{if(e){if(location.href.indexOf(location.pathname)>=0)return!0;const e=new URL(window.location.href);theme.CollectionAjaxFilter(e,!1).then(()=>{!1,this.initPriceRange()})}})},checkIfNeedReload:function(){Shopify.designMode&&(theme.settings.overlayHeader&&(document.querySelector(".header-wrapper").classList.contains("header-wrapper--overlay")||location.reload()))},forceReload:function(){this.onUnload(),this.init()},onUnload:function(){window.off(this.namespace),this.container.off(this.namespace)}}),t}(),theme.CollectionFilter=function(){var e=!1,t=".tag-list--active-tags",i=".tag-list a",n=".price-range",s=".filter-form",o="tag--active",a="tag--remove";function r(e){this.container=e,this.sectionId=e.getAttribute("data-section-id"),this.namespace=".collection-filter-"+this.sectionId,this.init()}return r.prototype=Object.assign({},r.prototype,{init:function(){document.querySelectorAll(i).forEach(e=>{e.on("click"+this.namespace,this.onTagClick.bind(this))}),document.querySelectorAll(s).forEach(e=>{e.addEventListener("input",this.onFormSubmit.bind(this))}),this.initPriceRange()},initPriceRange:function(){document.querySelectorAll(n).forEach(e=>new theme.PriceRange(e,{onChange:this.renderFromFormData.bind(this)}))},onTagClick:function(t){var i=t.currentTarget;if(i.classList.contains("no-ajax"))return;if(t.preventDefault(),e)return;e=!0;const n=i.parentNode,s=new URL(i.href);this.renderActiveTag(n,i),this.startLoading(),this.renderCollectionPage(s.searchParams)},onFormSubmit:function(t){const i=t.target;if(i.classList.contains("no-ajax"))return;if(t.preventDefault(),e)return;e=!0;const n=i.closest("li"),s=i.closest("form"),o=new FormData(s);this.renderActiveTag(n,i),this.startLoading(),this.renderFromFormData(o)},renderCollectionPage:function(t){theme.CollectionAjaxFilter(t).then(()=>{e=!1,this.initPriceRange()})},renderFromFormData:function(e){const t=new URLSearchParams(e);this.renderCollectionPage(t)},renderActiveTag:function(e,i){const n=e.querySelector(".tag__text");if(e.classList.contains(o))e.classList.remove(o);else{if(i.closest("li").classList.contains(a))e.remove();else{const e=document.createElement("li");e.classList.add("tag","tag--remove");const i=document.createElement("a");i.classList.add("btn","btn--small","js-no-transition"),i.innerText=n.innerText,e.appendChild(i);const s=document.querySelector(t);s&&s.append(e)}e.classList.add(o)}},startLoading:function(){document.querySelectorAll(".grid-product").forEach(e
13=>{e.classList.add("unload")})},forceReload:function(){this.init()}}),r}(),theme.CollectionAjaxFilter=function(e,t=!0){const i="CollectionFiltersSection",n="CollectionSection",s="CollectionAjaxContent",o=document.getElementById(i),a=document.getElementById(n);return new theme.AjaxRenderer({sections:[{sectionId:o.dataset.sectionId,nodeId:i},{sectionId:a.dataset.sectionId,nodeId:s}],preserveParams:["sort_by"]}).renderPage(window.location.pathname,e,t).then(()=>{theme.sections.reinit("collection-template"),theme.sections.reinit("collection-filter");const e=document.getElementById(s);theme.reinitProductGridItem(e),theme.QuickShopScreens.reInit(e)})},theme.FeaturedCollection=function(){var e="[data-pagination-wrapper]",t="[data-product-container]",i="[data-collection-container]",n="[data-arrow]",s="collection-loading",o="overflow-scroller__arrow--left",a="overflow-scroller--disable-left",r="overflow-scroller--disable-right";function c(t){this.container=t,this.sectionId=this.container.getAttribute("data-section-id"),this.scrollWrap=this.container.querySelector(e),this.scrollArrows=this.container.querySelectorAll(n),this.namespace=".featured-collection-"+this.sectionId,this.options={scrollable:this.container.dataset.scrollable,paginate:this.container.dataset.paginate};var i=this.container.dataset.paginateBy,s=this.container.dataset.collectionCount;this.settings={url:this.container.dataset.collectionUrl,page:1,pageCount:this.options.paginate?Math.ceil(s/i):0,itemsToScroll:3,gridItemWidth:this.container.dataset.gridItemWidth},this.state={isInit:!1,loading:!1,scrollerEnabled:!1,loadedAllProducts:!1,scrollable:this.options.scrollable,scrollInterval:null,scrollSpeed:3},this.sizing={scroller:0,itemWidth:0},theme.promiseStylesheet().then(function(){theme.initWhenVisible({element:this.container,callback:this.init.bind(this)})}.bind(this))}return c.prototype=Object.assign({},c.prototype,{init:function(){new theme.HoverProductGrid(this.container),this.state.scrollable&&(this.sizing=this.getScrollWidths(),window.on("resize"+this.namespace,theme.utils.debounce(200,this.handleResize.bind(this))),this.toggleScrollListener(this.state.scrollable),this.arrowListeners(this.state.scrollable),this.state.isInit=!0)},reInit:function(){new theme.HoverProductGrid(this.container),this.state.scrollable&&(this.sizing=this.getScrollWidths(),this.toggleScrollListener(this.state.scrollable)),theme.reinitProductGridItem()},loadingState:function(e){this.state.loading=e,this.container.classList.toggle(s,e)},getScrollWidths:function(){var e=this.scrollWrap.offsetWidth,t=this.scrollWrap.scrollWidth,i=this.scrollWrap.querySelector(".grid__item").offsetWidth;return this.state.isInit||(t-=200),t<=e&&this.disableArrow(null,!0),{scroller:t,scrollSize:t-e,itemWidth:i}},handleResize:function(){this.state.scrollable&&(this.sizing=this.getScrollWidths()),this.toggleScrollListener(this.state.scrollable),this.arrowListeners(this.state.scrollable)},toggleScrollListener:function(e){if(e){if(this.state.scrollerEnabled)return;this.scrollWrap.on("scroll"+this.namespace,theme.utils.throttle(250,this.scrollCheck.bind(this))),this.state.scrollerEnabled=!0}else this.scrollWrap.off("scroll"+this.namespace),this.state.scrollerEnabled=!1},scrollCheck:function(e){if(this.state.loading)this.toggleScrollListener(!1);else{0===this.sizing.scrollSize&&(this.sizing=this.getScrollWidths());var t=e.currentTarget.scrollLeft?e.currentTarget.scrollLeft:0,i=Math.floor(t/this.sizing.scrollSize*100);this.sizing.scrollSize;this.options.paginate&&!this.state.loadedAllProducts&&i>50&&this.getNewProducts(),i||(i=0),this.disableArrow(i)}},arrowListeners:function(e){this.scrollArrows.forEach(t=>{t.off("click"+this.namespace),e?(t.classList.remove("hide"),t.on("click"+this.namespace,this.arrowScroll.bind(this))):t.classList.add("hide")})},arrowScroll:function(e){var t=e.currentTarget.classList.contains(o)?"left":"right",i=theme.config.bpSmall?1:2;if("mouseenter"===e.type)this.state.scrollInterval=setInterval(function(){var e=this.scrollWrap.scrollLeft,n="left"===t?e-i:e+i;this.scrollWrap.scrollLeft=n}.bind(this),this.state.scrollSpeed);else if("mouseleave"===e.type)clearInterval(this.state.scrollInterval);else if("click"===e.type){clearInterval(this.state.scrollInterval);var n=this.scrollWrap.scrollLeft,s=this.sizing.itemWidth*this.settings.itemsToScroll,a="left"===t?n-s:n+s;this.scrollWrap.scroll({left:a,behavior:"smooth"})}a<=0&&this.disableArrow(a)},disableArrow:function(e,t){this.scrollArrows.forEach(i=>
13{if(i.classList.remove(r),i.classList.remove(a),t)return i.classList.add(r),void i.classList.add(a);e<=10?i.classList.add(a):e>=96&&i.classList.add(r)})},getNewProducts:function(){this.loadingState(!0);var e=this.settings.page+1,n=this.settings.gridItemWidth;if(e>this.settings.pageCount)return this.loadingState(!1),void(this.state.loadedAllProducts=!0);var s=this.settings.url+"?page="+e;fetch(s).then((function(e){return e.text()})).then(function(e){var s=(new DOMParser).parseFromString(e,"text/html").querySelectorAll(i+" .grid-product"),o=document.createDocumentFragment();s.forEach(e=>{e.classList.add(n),o.appendChild(e)}),this.container.querySelector(t).appendChild(o),this.ajaxSuccess()}.bind(this))},ajaxSuccess:function(){this.loadingState(!1),this.settings.page=this.settings.page+1,this.reInit()},forceReload:function(){this.onUnload(),this.init()},onLoad:function(){theme.QuickShopScreens.reInit(this.container)},onUnload:function(){window.off(this.namespace),window.dispatchEvent(new Event("resize")),this.scrollWrap.off(this.namespace),theme.QuickShopScreens.unload(this.container)}}),c}(),theme.Testimonials=function(){var e={adaptiveHeight:!1,avoidReflow:!0,pageDots:!0,prevNextButtons:!1,wrapAround:!0};function t(e){this.container=e;var t=e.getAttribute("data-section-id");this.slideshow=e.querySelector("#Testimonials-"+t),this.slideshow&&theme.promiseStylesheet().then(function(){theme.initWhenVisible({element:this.container,callback:this.init.bind(this),threshold:600})}.bind(this))}return t.prototype=Object.assign({},t.prototype,{init:function(t,i){this.slideshow.dataset.count<=3&&(e.wrapAround=!1,e.contain=!0),this.flickity=new theme.Slideshow(this.slideshow,e),this.flickity.resize()},onUnload:function(){this.flickity&&"function"==typeof this.flickity.destroy&&this.flickity.destroy()},onDeselect:function(){this.flickity&&"function"==typeof this.flickity.play&&this.flickity.play()},onBlockSelect:function(e){var t=this.slideshow.querySelector(".testimonials-slide--"+e.detail.blockId),i=parseInt(t.dataset.index);clearTimeout(this.timeout),this.flickity&&"function"==typeof this.flickity.pause&&(this.flickity.goToSlide(i),this.flickity.pause())},onBlockDeselect:function(){this.flickity&&"function"==typeof this.flickity.play&&this.flickity.play()}}),t}(),theme.HeroAnimated=function(){var e="animated__slide--active",t="animated__slide--inactive";function i(e){this.container=e;var t=e.dataset.count,i=e.querySelector(".hero");i&&theme.loadImageSection(i),this.allImages=e.querySelectorAll(".animated__slide"),this.state={activeIndex:0},1!==t?(this.interval,this.intervalSpeed=e.dataset.interval,this.maxIndex=t-1,theme.promiseStylesheet().then(function(){theme.initWhenVisible({element:this.container,callback:this.initInterval.bind(this)})}.bind(this))):this.setFades(!0)}return i.prototype=Object.assign({},i.prototype,{initInterval:function(){this.setFades(!0),this.interval=setInterval(function(){this.setFades()}.bind(this),this.intervalSpeed)},setFades:function(i){var n=this.state.activeIndex===this.maxIndex?0:this.state.activeIndex+1;if(i&&(n=this.state.activeIndex),!i){var s=this.allImages[this.state.activeIndex];s.classList.remove(e),s.classList.add(t)}var o=this.allImages[n];o.classList.remove(t),o.classList.add(e),this.state.activeIndex=n},onUnload:function(){clearInterval(this.interval)}}),i}(),theme.Maps=function(){var e=14,t=null,i=[],n={},s='[data-section-type="map"]',o="[data-map]",a=".map-section__overlay";function r(e){this.container=e,this.sectionId=this.container.getAttribute("data-section-id"),this.namespace=".map-"+this.sectionId,this.map=e.querySelector(o),this.key=this.map.dataset.apiKey,n={addressNoResults:theme.strings.addressNoResults,addressQueryLimit:theme.strings.addressQueryLimit,addressError:theme.strings.addressError,authError:theme.strings.authError},this.key&&theme.initWhenVisible({element:this.container,callback:this.prepMapApi.bind(this),threshold:20})}return window.gm_authFailure=function(){Shopify.designMode&&(document.querySelectorAll(s).forEach(e=>{e.classList.add("map-section--load-error")}
13),document.querySelectorAll(o).forEach(e=>{e.parentNode.removeChild(e)}),window.mapError(theme.strings.authError))},window.mapError=function(e){var t=document.createElement("div");t.classList.add("map-section__error","errors","text-center"),t.innerHTML=e,document.querySelectorAll(a).forEach(e=>{e.parentNode.prepend(t)}),document.querySelectorAll(".map-section__link").forEach(e=>{e.classList.add("hide")})},r.prototype=Object.assign({},r.prototype,{prepMapApi:function(){if("loaded"===t)this.createMap();else if(i.push(this),"loading"!==t&&(t="loading",void 0===window.google||void 0===window.google.maps)){var e=document.createElement("script");e.onload=function(){t="loaded",i.forEach(e=>{e.createMap()})},e.src="https://maps.googleapis.com/maps/api/js?key="+this.key,document.head.appendChild(e)}},createMap:function(){var t=this.map;return function(e){var t=new google.maps.Geocoder;if(e){var i=e.dataset.addressSetting;return new Promise((e,n)=>{t.geocode({address:i},(function(t,i){i!==google.maps.GeocoderStatus.OK&&n(i),e(t)}))})}}(t).then(function(i){var n={zoom:e,backgroundColor:"none",center:i[0].geometry.location,draggable:!1,clickableIcons:!1,scrollwheel:!1,disableDoubleClickZoom:!0,disableDefaultUI:!0},s=this.map=new google.maps.Map(t,n),o=this.center=s.getCenter();new google.maps.Marker({map:s,position:s.getCenter()});google.maps.event.addDomListener(window,"resize",theme.utils.debounce(250,(function(){google.maps.event.trigger(s,"resize"),s.setCenter(o),t.removeAttribute("style")}))),Shopify.designMode&&window.AOS&&AOS.refreshHard()}.bind(this)).catch((function(e){var t;switch(e){case"ZERO_RESULTS":t=n.addressNoResults;break;case"OVER_QUERY_LIMIT":t=n.addressQueryLimit;break;case"REQUEST_DENIED":t=n.authError;break;default:t=n.addressError}Shopify.designMode&&window.mapError(t)}))},onUnload:function(){0!==this.map.length&&google&&google.maps&&google.maps.event&&google.maps.event.clearListeners(this.map,"resize")}}),r}(),theme.SlideshowSection=function(){var e=".parallax-container";function t(e){this.container=e;var t=e.getAttribute("data-section-id");if(this.slideshow=e.querySelector("#Slideshow-"+t),this.namespace="."+t,this.initialIndex=0,this.slideshow){var i=e.parentElement;0===[].indexOf.call(i.parentElement.children,i)?this.init():theme.initWhenVisible({element:this.container,callback:this.init.bind(this)})}}return t.prototype=Object.assign({},t.prototype,{init:function(){var t=this.slideshow.querySelectorAll(".slideshow__slide");if(this.container.hasAttribute("data-immediate-load")?(this.slideshow.classList.remove("loading","loading--delayed"),this.slideshow.classList.add("loaded")):theme.loadImageSection(this.slideshow),t.length>1){var i={prevNextButtons:this.slideshow.hasAttribute("data-arrows"),pageDots:this.slideshow.hasAttribute("data-dots"),fade:!0,setGallerySize:!1,initialIndex:this.initialIndex,autoPlay:"true"===this.slideshow.dataset.autoplay&&parseInt(this.slideshow.dataset.speed)};this.flickity=new theme.Slideshow(this.slideshow,i)}else t[0].classList.add("is-selected");this.container.hasAttribute("data-parallax")&&this.container.querySelectorAll(e).forEach(function(e,t){new theme.Parallax(e,{namespace:this.namespace+"-parallax-"+t})}.bind(this))},forceReload:function(){this.onUnload(),this.init()},onUnload:function(){this.flickity&&"function"==typeof this.flickity.destroy&&this.flickity.destroy()},onDeselect:function(){this.flickity&&"function"==typeof this.flickity.play&&this.flickity.play()},onBlockSelect:function(e){var t=this.slideshow.querySelector(".slideshow__slide--"+e.detail.blockId),i=parseInt(t.dataset.index);this.flickity&&"function"==typeof this.flickity.pause?(this.flickity.goToSlide(i),this.flickity.pause()):(this.initialIndex=i,setTimeout(function(){this.flickity&&"function"==typeof this.flickity.pause&&this.flickity.pause()}.bind(this),1e3))},onBlockDeselect:function(){this.flickity&&"function"==typeof this.flickity.play&&this.flickity.args.autoPlay&&this.flickity.play()}}),t}(),theme.NewsletterPopup=function(){function e(e){this.container=e;var t=this.container.getAttribute("data-section-id");this.cookieName="newsletter-"+t,e&&"/challenge"!==window.location.pathname&&"/password"!==window.location.pathname&&(this.data={secondsBeforeShow:e.dataset.delaySeconds,daysBeforeReappear:e.dataset.delayDays,cookie
13:Cookies.get(this.cookieName),testMode:e.dataset.testMode},this.modal=new theme.Modals("NewsletterPopup-"+t,"newsletter-popup-modal"),(e.querySelector(".errors")||e.querySelector(".note--success"))&&this.modal.open(),e.querySelector(".note--success")?this.closePopup(!0):(document.addEventListener("modalClose."+e.id,this.closePopup.bind(this)),this.data.cookie&&"true"!==this.data.testMode||this.initPopupDelay()))}return e.prototype=Object.assign({},e.prototype,{initPopupDelay:function(){Shopify&&Shopify.designMode||setTimeout(function(){this.modal.open()}.bind(this),1e3*this.data.secondsBeforeShow)},closePopup:function(e){if("true"!==this.data.testMode){var t=e?200:this.data.daysBeforeReappear;Cookies.set(this.cookieName,"opened",{path:"/",expires:t})}else Cookies.remove(this.cookieName,{path:"/"})},onLoad:function(){this.modal.open()},onSelect:function(){this.modal.open()},onDeselect:function(){this.modal.close()}}),e}(),theme.PasswordHeader=function(){function e(){this.init()}return e.prototype=Object.assign({},e.prototype,{init:function(){if(document.querySelector("#LoginModal")){var e=new theme.Modals("LoginModal","login-modal",{focusIdOnOpen:"password",solid:!0});document.querySelectorAll(".errors").length&&e.open()}}}),e}(),theme.Photoswipe=function(){var e=".js-photoswipe__zoom",t=".photoswipe__image",i=".flickity-viewport ",n=".is-selected";function s(e,t){this.container=e,this.sectionId=t,this.namespace=".photoswipe-"+this.sectionId,this.gallery,this.images,this.items,this.inSlideshow=!1,e&&"false"!==e.dataset.zoom&&("true"===e.dataset.hasSlideshow&&(this.inSlideshow=!0),this.init())}return s.prototype=Object.assign({},s.prototype,{init:function(){this.container.querySelectorAll(e).forEach(e=>{e.on("click"+this.namespace,this.triggerClick.bind(this))})},triggerClick:function(e){this.items=this.getImageData();var t=this.inSlideshow?this.container.querySelector(n):e.currentTarget,i=this.inSlideshow?this.getChildIndex(t):t.dataset.index;this.initGallery(this.items,i)},getChildIndex:function(e){for(var t=0;null!=(e=e.previousSibling);)t++;return t+1},getImageData:function(){this.images=this.inSlideshow?this.container.querySelectorAll(i+t):this.container.querySelectorAll(t);var e=[];return this.images.forEach(t=>{var i={msrc:t.currentSrc||t.src,src:t.getAttribute("data-photoswipe-src"),w:t.getAttribute("data-photoswipe-width"),h:t.getAttribute("data-photoswipe-height"),el:t,initialZoomLevel:.5};e.push(i)}),e},initGallery:function(e,t){var i=document.querySelectorAll(".pswp")[0],n={allowPanToNext:!1,captionEl:!1,closeOnScroll:!1,counterEl:!1,history:!1,index:t-1,pinchToClose:!1,preloaderEl:!1,scaleMode:"zoom",shareEl:!1,tapToToggleControls:!1,getThumbBoundsFn:function(t){var i=window.pageYOffset||document.documentElement.scrollTop,n=e[t].el.getBoundingClientRect();return{x:n.left,y:n.top+i,w:n.width}}};this.gallery=new PhotoSwipe(i,PhotoSwipeUI_Default,e,n),this.gallery.listen("afterChange",this.afterChange.bind(this)),this.gallery.init(),this.preventiOS15Scrolling()},afterChange:function(){var e=this.gallery.getCurrentIndex();this.container.dispatchEvent(new CustomEvent("photoswipe:afterChange",{detail:{index:e}}))},syncHeight:function(){document.documentElement.style.setProperty("--window-inner-height",window.innerHeight+"px")},preventiOS15Scrolling:function(){let e;/iPhone|iPad|iPod/i.test(window.navigator.userAgent)&&(this.syncHeight(),e=window.scrollY,document.documentElement.classList.add("pswp-open-in-ios"),window.addEventListener("resize",this.syncHeight),this.gallery.listen("destroy",()=>{document.documentElement.classList.remove("pswp-open-in-ios"),window.scrollTo(0,e)}))}}),s}(),theme.Recommendations=function(){var e={placeholder:".product-recommendations-placeholder",sectionClass:" .product-recommendations",productResults:".grid-product"};function t(t){this.container=t,this.sectionId=t.getAttribute("data-section-id"),this.url=t.dataset.url,e.recommendations="Recommendations-"+this.sectionId,theme.initWhenVisible({element:t,callback:this.init.bind(this),threshold:500})}return t.prototype=Object.assign({},t.prototype,{init:function(){var t=document.getElementById(e.recommendations);if(t&&"false"!==t.dataset.enable){var i=t.dataset.productId,n=t.dataset.limit,s=this.url+"?section_id=product-recommendations&limit="+n+"&product_id="+i;if(Shopify.designMode){var o=t.querySelector(e.sectionClass);o&&(o.innerHTML="")}fetch(s).then((function(e){return e.text()})).then(function(i){var n=(new DOMParser).parseFromString(i,"text/html").querySelector(e.sectionClass),s=t.querySelector(e.placeholder);if(s){if(s.innerHTML="",!n)return this.container.classList.add("hide"),void(AOS&&AOS.refreshHard());s.appendChild(n),theme.reinitProductGridItem(t),document.dispatchEvent(new CustomEvent("recommendations:loaded",{detail:{section:t}})),0===n.querySelectorAll(e.productResults).length&&this.container.classList.add("hide")}}.bind(this))}}}),t}(),theme.StoreAvailability=function(){var e=".js-drawer-open-availability",t=".js-modal-open-availability",i="[data-availability-product-title]";function n(e){this.container=e,this.baseUrl=e.dataset.baseUrl,this.productTitle=e.dataset.productName}return n.prototype=Object.assign({},n.prototype,{updateContent:function(n){var s=this.baseUrl+"/variants/"+n+"/?section_id=store-availability",o=this;fetch(s).then((function(e){return e.text()})).then((function(n){if(""!==n.trim()){o.container.innerHTML=n,o.container.innerHTML=o.container.firstElementChild.innerHTML,o.container.querySelector(e)&&(o.drawer=new theme.Drawers("StoreAvailabilityDrawer","availability")),o.container.querySelector(t)&&(o.modal=new theme.Modals("StoreAvailabilityModal","availability"));var s=o.container.querySelector(i);s&&(s.textContent=o.productTitle)}else this.container.innerHTML=""}))}}),n}(),theme.VideoSection=function(){var e=".video-parent-section";function t(e){this.container=e,this.sectionId=e.getAttribute("data-section-id"),this.namespace=".video-"+this.sectionId,this.videoObject,theme.initWhenVisible({element:this.container,callback:this.init.bind(this),threshold:500})}return t.prototype=Object.assign({},t.prototype,{init:function(){var e=this.container.querySelector(".video-div");if(e)switch(e.dataset.type){case"youtube":var t=e.dataset.videoId;this.initYoutubeVideo(t);break;case"vimeo":t=e.dataset.videoId;this.initVimeoVideo(t);break;case"mp4":this.initMp4Video()}}
13,initYoutubeVideo:function(t){this.videoObject=new theme.YouTube("YouTubeVideo-"+this.sectionId,{videoId:t,videoParent:e})},initVimeoVideo:function(t){this.videoObject=new theme.VimeoPlayer("Vimeo-"+this.sectionId,t,{videoParent:e})},initMp4Video:function(){var t="Mp4Video-"+this.sectionId,i=document.getElementById(t),n=i.closest(e);if(i){n.classList.add("loaded");var s=document.querySelector("#"+t).play();void 0!==s&&s.then((function(){})).catch((function(){i.setAttribute("controls",""),n.classList.add("video-interactable")}))}},onUnload:function(e){e.target.id.replace("shopify-section-","");this.videoObject&&"function"==typeof this.videoObject.destroy&&this.videoObject.destroy()}}),t}(),theme.isStorageSupported=function(e){if(window.self!==window.top)return!1;var t;"session"===e&&(t=window.sessionStorage),"local"===e&&(t=window.localStorage);try{return t.setItem("test","1"),t.removeItem("test"),!0}catch(e){return!1}},theme.reinitProductGridItem=function(){AOS&&AOS.refreshHard(),window.SPR&&(SPR.initDomEls(),SPR.loadBadges()),theme.collapsibles.init()},theme.reviewAppLinkListener=function(){document.addEventListener("click",(function(e){if(window.SPR){var t=e.target.parentNode,i=null;(t.matches(".spr-pagination-next")||t.matches(".spr-pagination-page"))&&(i=t.closest(".spr-reviews")),i&&i.scrollTo(0,0)}}))},theme.checkForAnchorLink=function(){if(window.location.hash){var e=document.querySelector(window.location.hash);e&&window.scrollTo(0,e.offsetTop-100)}},theme.init=function(){theme.QuickShopScreens.init(),theme.rteInit(),theme.articleImages(),theme.collapsibles.init(),"sticky"===theme.settings.cartType&&new theme.StickyCart.init,theme.videoModal(),window.addEventListener("pageshow",(function(e){e.persisted&&theme.refreshCart()})),performance&&2===performance.navigation.type&&theme.refreshCart()},theme.initSecondary=function(){document.body.classList.add("js-animate"),AOS.init({easing:"ease-out-quad",once:!1,mirror:!0,offset:100,disableMutationObserver:!0}),document.addEventListener("lazyloaded",(function(e){var t=e.target;t&&t.parentNode.classList.add("loaded")})),theme.storeScrollPositionOnUnload(),theme.reviewAppLinkListener(),theme.checkForAnchorLink()},theme.config.hasSessionStorage=theme.isStorageSupported("session"),theme.config.hasLocalStorage=theme.isStorageSupported("local"),h=function(){if(theme.promiseStylesheet().then((function(){theme.initSecondary(),document.dispatchEvent(new CustomEvent("page:loaded"))})),theme.sections=new theme.Sections,theme.init(),theme.settings.isCustomerTemplate&&theme.customerTemplates(),theme.sections.register("slideshow-section",theme.SlideshowSection),theme.sections.register("header-section",theme.HeaderSection),theme.sections.register("hero-animated",theme.HeroAnimated),theme.sections.register("video-section",theme.VideoSection),theme.sections.register("product",theme.Product),theme.sections.register("product-recommendations",theme.Recommendations),theme.sections.register("password-header",theme.PasswordHeader),theme.sections.register("product-template",theme.Product),theme.sections.register("featured-collection",theme.FeaturedCollection),theme.sections.register("collection-template",theme.Collection),theme.sections.register("collection-filter",theme.CollectionFilter),theme.sections.register("testimonials",theme.Testimonials),theme.sections.register("newsletter-popup",theme.NewsletterPopup),theme.sections.register("map",theme.Maps),theme.sections.register("blog",theme.Blog),theme.sections.register("footer-section",theme.FooterSection),theme.sections.register("store-availability",theme.StoreAvailability),document.body.classList.contains("template-cart")){var e=document.getElementById("CartPageForm");e&&new theme.CartForm(e)}theme.pageTransitions()},"loading"!=document.readyState?h():document.addEventListener("DOMContentLoaded",h)}();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.