astraToggleSetupPro=function(e,t,a){var n,l,o,s=!1;if(0<(n="off-canvas"===e||"full-width"===e?(l=document.querySelectorAll("#ast-mobile-popup, #ast-mobile-header"),(o=t.classList.contains("ast-header-break-point")?document.querySelectorAll("#ast-mobile-header .main-header-menu-toggle"):document.querySelectorAll("#ast-desktop-header .main-header-menu-toggle")).length):t.classList.contains("ast-header-break-point")?(l=document.querySelectorAll("#ast-mobile-header"),(s=!(0<(n=(o=document.querySelectorAll("#ast-mobile-header .main-header-menu-toggle")).length)))?1:n):(l=document.querySelectorAll("#ast-desktop-header"),(o=document.querySelectorAll("#ast-desktop-header .main-header-menu-toggle")).length))||s)for(var r=0;r .menu-link, ul.main-header-menu .ast-menu-toggle"):l[i].querySelectorAll("ul.main-header-menu .ast-menu-toggle")).length)for(var c=0;c #ast-desktop-header .ast-desktop-header-content"),s=(l=null!=l&&""!==l?l.querySelector(".main-header-menu-toggle"):document.querySelector("#masthead > #ast-desktop-header .main-header-menu-toggle"),document.querySelector("#masthead > #ast-desktop-header .ast-desktop-header-content .main-header-bar-navigation"));if("desktop"===e.currentTarget.trigger_type)null!==s&&""!==s&&void 0!==s&&(astraToggleClass(s,"toggle-on"),s.classList.contains("toggle-on")?s.style.display="block":s.style.display=""),astraToggleClass(l,"toggled"),l.classList.contains("toggled")?(t.classList.add("ast-main-header-nav-open"),"dropdown"===a&&(o.style.display="block")):(t.classList.remove("ast-main-header-nav-open"),o.style.display="none");else{e=document.querySelectorAll("#masthead > #ast-mobile-header .main-header-bar-navigation"),s=(menu_toggle_all=document.querySelectorAll("#masthead > #ast-mobile-header .main-header-menu-toggle"),"0"),l=!1;if(null!==n.closest("#ast-fixed-header")&&(e=document.querySelectorAll("#ast-fixed-header > #ast-mobile-header .main-header-bar-navigation"),menu_toggle_all=document.querySelectorAll("#ast-fixed-header .main-header-menu-toggle"),s="0",l=!0),void 0===e[s])return!1;for(var r=e[s].querySelectorAll(".menu-item-has-children"),d=0;d{const a=t.querySelector(".ast-account-nav-menu");document.addEventListener("pointerup",function(e){(l||n&&document.querySelector("body").classList.contains("ast-header-break-point"))&&!t.contains(e.target)&&(a.style.right="",a.style.left="")});var e=t.querySelector(".ast-header-account-link");e&&e.addEventListener("click",function(e){(l||n&&document.querySelector("body").classList.contains("ast-header-break-point"))&&(headerSelectionPosition=e.target.closest(".site-header-section"))&&(headerSelectionPosition.classList.contains("site-header-section-left")?(a.style.left=""===a.style.left?"-100%":"",a.style.right=""===a.style.right?"auto":""):(a.style.right=""===a.style.right?"-100%":"",a.style.left=""===a.style.left?"auto":""))})})};document.addEventListener("astPartialContentRendered",function(){accountMenuToggle()}),window.addEventListener("load",function(){accountMenuToggle()}),document.addEventListener("astLayoutWidthChanged",function(){accountMenuToggle()});!function(o,r){var s="astHookExtSticky",i=r.document,a=(jQuery(r).outerWidth(),jQuery(r).width()),n={dependent:[],max_width:"",site_layout:"",break_point:920,admin_bar_height_lg:32,admin_bar_height_sm:46,admin_bar_height_xs:0,stick_upto_scroll:0,gutter:0,wrap:"
",body_padding_support:!0,html_padding_support:!0,active_shrink:!1,shrink:{padding_top:"",padding_bottom:""},sticky_on_device:"desktop",header_style:"none",hide_on_scroll:"no"};function e(t,e){this.element=t,this.options=o.extend({},n,e),this._defaults=n,this._name=s,"1"==this.options.hide_on_scroll&&(this.navbarHeight=o(t).outerHeight()),this.lastScrollTop=0,this.delta=5,this.should_stick=!0,this.hideScrollInterval="",this.init()}e.prototype.stick_me=function(t,e){var o=jQuery(t.element),s=jQuery(r).outerWidth(),i=parseInt(t.options.stick_upto_scroll),a=parseInt(o.parent().attr("data-stick-maxwidth")),n=parseInt(o.parent().attr("data-stick-gutter"));"enabled"==(astraAddon.hook_sticky_header||"")&&(!("desktop"==t.options.sticky_on_device&&astraAddon.hook_custom_header_break_point>s)&&!("mobile"==t.options.sticky_on_device&&astraAddon.hook_custom_header_break_point<=s)&&jQuery(r).scrollTop()>i?"none"==t.options.header_style&&("enabled"==t.options.active_shrink?(t.hasShrink(t,"stick"),i="none",o.hasClass("ast-custom-header")||(i=n),o.parent().css("min-height",o.outerHeight()),o.addClass("ast-header-sticky-active").stop().css({"max-width":a,top:i,"padding-top":t.options.shrink.padding_top,"padding-bottom":t.options.shrink.padding_bottom})):(t.hasShrink(t,"stick"),o.parent().css("min-height",o.outerHeight()),o.addClass("ast-header-sticky-active").stop().css({"max-width":a,top:n,"padding-top":t.options.shrink.padding_top,"padding-bottom":t.options.shrink.padding_bottom})),o.addClass("ast-sticky-shrunk").stop()):t.stickRelease(t)),"enabled"==(astraAddon.hook_sticky_footer||"")&&("desktop"==t.options.sticky_on_device&&astraAddon.hook_custom_footer_break_point>s||"mobile"==t.options.sticky_on_device&&astraAddon.hook_custom_footer_break_point<=s?t.stickRelease(t):(jQuery("body").addClass("ast-footer-sticky-active"),o.parent().css("min-height",o.outerHeight()),o.stop().css({"max-width":a})))},e.prototype.update_attrs=function(){var o,t=this,e=jQuery(t.element),s=parseInt(t.options.gutter),i=t.options.max_width;"none"==t.options.header_style&&(o=e.offset().top||0),"ast-box-layout"!=t.options.site_layout&&(i=jQuery("body").width()),t.options.dependent&&jQuery.each(t.options.dependent,function(t,e){jQuery(e).length&&"on"==jQuery(e).parent().attr("data-stick-support")&&(dependent_height=jQuery(e).outerHeight(),s+=parseInt(dependent_height),o-=parseInt(dependent_height))}),t.options.admin_bar_height_lg&&jQuery("#wpadminbar").length&&782jQuery(t.element).outerHeight()?jQuery("body").addClass("ast-shrink-custom-header"):jQuery("body").removeClass("ast-shrink-custom-header")},e.prototype.stickRelease=function(t){var e=jQuery(t.element);"enabled"==(astraAddon.hook_sticky_header||"")&&"none"==t.options.header_style&&(e.removeClass("ast-header-sticky-active").stop().css({"max-width":"",top:"",padding:""}),e.parent().css("min-height",""),e.removeClass("ast-sticky-shrunk").stop()),"enabled"==(astraAddon.hook_sticky_footer||"")&&jQuery("body").removeClass("ast-footer-sticky-active")},e.prototype.init=function(){var e,t;jQuery(this.element)&&(e=this,t=jQuery(e.element),parseInt(e.options.gutter),t.position().top,"none"==e.options.header_style&&t.wrap(e.options.wrap).parent().css("min-height",t.outerHeight()).attr("data-stick-support","on").attr("data-stick-maxwidth",parseInt(e.options.max_width)),e.update_attrs(),jQuery(r).on("resize",function(){e.stickRelease(e),e.update_attrs(),e.stick_me(e)}),jQuery(r).on("scroll",function(){e.stick_me(e,"scroll")}),jQuery(i).ready(function(t){e.stick_me(e)}))},o.fn[s]=function(t){return this.each(function(){o.data(this,"plugin_"+s)||o.data(this,"plugin_"+s,new e(this,t))})};var d=jQuery("body").width(),_=astraAddon.site_layout||"",h=astraAddon.hook_sticky_header||"",p=astraAddon.hook_shrink_header||"";sticky_header_on_devices=astraAddon.hook_sticky_header_on_devices||"desktop",site_layout_box_width=astraAddon.site_layout_box_width||1200,hook_sticky_footer=astraAddon.hook_sticky_footer||"",sticky_footer_on_devices=astraAddon.hook_sticky_footer_on_devices||"desktop","ast-box-layout"===_&&(d=parseInt(site_layout_box_width)),jQuery(i).ready(function(t){"enabled"==h&&jQuery(".ast-custom-header").astHookExtSticky({sticky_on_device:sticky_header_on_devices,header_style:"none",site_layout:_,max_width:d,active_shrink:p}),"enabled"==hook_sticky_footer&&jQuery(".ast-custom-footer").astHookExtSticky({sticky_on_device:sticky_footer_on_devices,max_width:d,site_layout:_,header_style:"none"})})}(jQuery,window);function dynamicImageResize(e,t){var r=document.querySelector("#ast-vertical-thumbnail-wrapper"),a=t.getElementsByTagName("div")[0],e=(a&&r&&(e.rowHeight=a.offsetHeight,a=e.numVisible*e.rowHeight+"px",t.style.height=a,r.style.height=a,t.style.visibility="visible"),document.querySelector(".woocommerce-product-gallery__wrapper"));if(e){const i=r.clientHeight;a=e.querySelectorAll("a img");a&&a.forEach(e=>{e.style.height=i-10+"px"})}}function MoveSlide(t,r,a){var i=document.querySelector("#ast-vertical-slider-inner");if(i){var l=i.querySelector("img").clientHeight+10;let e=parseInt(i.getAttribute("ast-translate"));l&&("next"===t?enableDisableNavigationArrows(r,a,e+=l,l):0{e.addEventListener("click",function(e){var t=e.currentTarget.getAttribute("data-slide-number");r.forEach(e=>{e.classList.remove("flex-active-slide")}),e.currentTarget.classList.add("flex-active-slide"),jQuery(".woocommerce-product-gallery").data("flexslider").flexAnimate(parseInt(t))})})}function enableDisableNavigationArrows(e,t,r=0,a=0){var i,l,s=document.querySelectorAll("#ast-vertical-slider-inner .ast-woocommerce-product-gallery__image");s&&(i=(s=s.length)-4,l="flex-disabled",(parseInt(r)<1||parseInt(r) div")&&(e=document.querySelector("#ast-gallery-thumbnails").clientWidth)&&(t=document.querySelector(".woocommerce div.product.ast-product-gallery-layout-vertical-slider > span.onsale, .woocommerce div.product.ast-product-gallery-layout-vertical-slider > span.ast-onsale-card"))&&(r=t.classList.contains("ast-onsale-card")?25:15,t.style.left=e+r+"px")}function scrollToSlideVariableProduct(i,l){const s=document.querySelector(".woocommerce-product-gallery .woocommerce-product-gallery__image"),t=document.querySelectorAll(".woocommerce-product-gallery .ast-woocommerce-product-gallery__image img");s&&t&&(observer=new MutationObserver(e=>{e.forEach(e=>{e.attributeName&&e.attributeName.includes("data-thumb")&&t.forEach(e=>{var t,r,a;e.getAttribute("srcset")&&e.getAttribute("srcset").includes(s.getAttribute("data-thumb"))&&(e.click(),t=document.querySelector("#ast-vertical-slider-inner"))&&(r=t.querySelector("img").clientHeight+10,e=e.closest(".ast-woocommerce-product-gallery__image").getAttribute("data-slide-number"),r)&&e&&(a=4*r,4<(e=parseInt(e)+1)?(t.style.transform=`translate3d( 0, -${e=r*e-a}px, 0 )`,t.setAttribute("ast-translate",e)):(t.setAttribute("ast-translate",0),t.style.transform="translate3d( 0, 0px, 0 )"),enableDisableNavigationArrows(i,l,t.getAttribute("ast-translate"),r),t.style.transition=".3s")})})})).observe(s,{attributes:!0})}document.addEventListener("DOMContentLoaded",function(){var e=document.querySelector("#ast-vertical-slider-inner"),e=(e&&e.setAttribute("ast-translate",0),document.querySelector("#ast-gallery-thumbnails")),t=document.querySelector(".ast-product-gallery-layout-vertical-slider");if(!e||t.classList.contains("ast-product-gallery-with-no-image"))return!1;const r={width:e.clientWidth,numVisible:4},a=r.carousel=document.querySelector("#ast-vertical-slider-inner");if(!a)return!1;var t=document.querySelector("#ast-vertical-navigation-prev"),e=document.querySelector("#ast-vertical-navigation-next"),i=(dynamicImageResize(r,a),verticalSliderNavigationArrows(t,e),focusSlideOnClick(),document.querySelector(".ast-article-single"));i&&i.classList.contains("ast-product-single-variable")&&scrollToSlideVariableProduct(t,e),enableDisableNavigationArrows(t,e),saleBadgeAlignment();let l;window.onresize=function(){clearTimeout(l),l=setTimeout(function(){dynamicImageResize(r,a),saleBadgeAlignment()},400)}});function triggerFirstSlide(){const t=document.querySelector(".woocommerce-product-gallery-thumbnails__wrapper div");var e=jQuery(".single_variation_wrap");e&&t&&e.on("show_variation",function(e,r){t.click()})}document.addEventListener("DOMContentLoaded",function(){triggerFirstSlide()});const productVariation=i=>{var t=document.querySelectorAll(".ast-single-variation"),e=document.querySelector(".reset_variations");e&&e.addEventListener("click",t=>{document.querySelectorAll(".ast-single-variation").forEach(t=>{t.classList.remove("active"),t.style.opacity="1",t.style.pointerEvents="inherit"})}),t&&t.forEach(t=>{t.addEventListener("click",t=>{var e=t.target.closest(".ast-variation-button-group"),e=(e&&(e=e.querySelectorAll(".ast-single-variation"))&&e.forEach(t=>{t.classList.remove("active")}),document.querySelector(".ast-product-single-variable form .variations")),e=(e&&(allVariationSelector=e.querySelectorAll("select"),allVariationButton=e.querySelectorAll(".ast-variation-button-group"),allVariationSelector)&&allVariationButton&&setTimeout(()=>{allVariationSelector.forEach(t=>{var e=t.querySelectorAll("option");const a=[];e.forEach(t=>{a.push(t.getAttribute("value"))});e=t.nextElementSibling;const i=null!==e?e.querySelectorAll(".ast-single-variation"):null;null!==i&&i.forEach(t=>{i.forEach(t=>{a.includes(t.getAttribute("data-slug"))?(t.style.opacity="1",t.style.pointerEvents="inherit"):(t.style.opacity=".5",t.style.pointerEvents="none")})})})},100),t.target.getAttribute("data-slug")),a=t.target.closest("td").querySelector("select");e&&a&&(t.target.classList.add("active"),a.value=e,a.dispatchEvent(new Event("change",{bubbles:!0}))),null!=i&&i.flexslider(0)})})};document.addEventListener("DOMContentLoaded",function(t){productVariation()}),document.addEventListener("astUpdateSingleProductVariations",function(){productVariation()}),jQuery(".composite_data").on("wc-composite-initializing",function(t,e){e.actions.add_action("component_scripts_initialized",function(){productVariation()},100)});function CartCrossSellsSummaryHeight(){var e=document.querySelector("body"),t=document.querySelector(".cross-sells");e.classList.contains("woocommerce-cart")&&t&&(e=t.querySelectorAll(".products > li"))&&e.forEach(e=>{e&&(e=e.querySelectorAll(".astra-shop-summary-wrap"))&&e.forEach(e=>{var t=e.querySelector(".price"),r=e.querySelector("a.button"),o=e.querySelector("a.ast-quick-view-button");(t||r)&&(t=(t?t.clientHeight:0)+(r?r.clientHeight:0)+(o?o.clientHeight:0)+15)&&(e.style.minHeight=t+"px")})})}function CartCrossSellsSummaryHeightResize(){let t;window.addEventListener("resize",function(e){clearTimeout(t),t=setTimeout(function(){CartCrossSellsSummaryHeight()},500)})}window.addEventListener("DOMContentLoaded",e=>{CartCrossSellsSummaryHeight()}),CartCrossSellsSummaryHeightResize();function customCoupon(){var e=document.querySelector("div.woocommerce"),o=document.querySelector("body");if(e&&(o.classList.contains("woocommerce-checkout")||o.classList.contains("woocommerce-cart"))){const t=e=>{var o=document.querySelector("#coupon_code"),t=document.querySelector('button[name="apply_coupon"]'),c=document.querySelector("#ast-coupon-code"),n=document.querySelector("#ast-checkout-coupon .coupon");n&&e.target&&"ast-coupon-trigger"===e.target.id&&(n.style.display="flex",e.target.style.display="none"),o&&t&&c&&e.target&&"ast-apply-coupon"===e.target.id&&(o.value=c.value,t.click())};e.addEventListener("click",function(e){t(e)}),e.addEventListener("keypress",function(e){13===(e.which||e.keyCode)&&t(e)})}}window.addEventListener("DOMContentLoaded",e=>{customCoupon()});!function(){var e;function o(e){var t=(t=document.body.className).replace(e,"");document.body.className=t}function d(e){e.style.display="block",setTimeout(function(){e.style.opacity=1},1)}function n(e){e.style.opacity="",setTimeout(function(){e.style.display=""},200)}r="iPhone"==navigator.userAgent.match(/iPhone/i)?"iphone":"",e="iPod"==navigator.userAgent.match(/iPod/i)?"ipod":"",document.body.className+=" "+r,document.body.className+=" "+e;for(var t=document.querySelectorAll("a.astra-search-icon:not(.slide-search)"),a=0;t.length>a;a++)t[a].onclick=function(e){var t,a,o,n;if(e.preventDefault(),e=e||window.event,this.classList.contains("header-cover"))for(var s=document.querySelectorAll(".ast-search-box.header-cover"),c=astraAddon.is_header_builder_active||!1,r=0;r