window.fgData={"offers":[],"settings":{"auto_add_gift":true,"compare_gift_price_with_product":"compare_at_price","cal_gift_discount":"compare_at_price","select_one_gift_price":false,"not_show_gift_if_already_on_cart":false,"sync_quantity":false,"manual_input_inventory":false,"using_draft_order":false,"delete_gift_after_turn_off_offer":true,"gift_format":"same_as_original_products","admin_api_access_token":null,"notify_via_email":{"status":false},"barcode":"blank","type_seo":"number_integer","mode_override_checkout":"default"},"appearance":{"gift_slider":{"general":{"gift_popup_title":"Select Your FREE BOGO Product!","add_to_cart_btn_title":"Add to cart","running_text":"","select_gift_btn":"Select variants","show_product_title":true,"show_variant_title":true,"show_pagination":true,"show_gift_for_customer":"by_products","number_product_slider":4},"color":{"gift_slider_title_color":"#121212","product_title_color":"#000000","original_price_color":"#121212","discounted_price_color":"#ea5455","add_to_cart_color":"#FFFFFF","add_to_cart_btn_color":"#4ebcf4"},"others":{"hidden_brand_mark":true,"gift_img_size":"&width=480&height=480"},"disable_slider_checkbox":{"enable":false,"time":10,"text":"Don't show this offer again"}},"gift_icon":{"gift_icon_path":"images\/fg-icons\/fg-icon-red.png","shopify_gift_icon_path":"fg-icon-red.png","product_page":{"gift_icon":{"status":false,"size":"100"},"gift_thumbnail":{"status":false,"size":"100","title":"Free Gift With Purchase:"}},"collection_page":{"status":false,"size":"100"}},"promotion_message":{"show_on_cart_page":false,"text_color":"#ffffff","background_color":"#F72119"},"today_offer":{"widget_icon_path":"images\/widget-icons\/widget-icon-6.png","shopify_widget_icon_path":"widget-icon-6.png","widget_info":{"show_widget":true,"widget_position":"bottom_right","widget_title":"Get Vitamin D3 Free!","widget_subtitle":"Get one D3 spray free with your order of any Dr. Spray's product.","widget_icon_style":"icon_and_title","icon_widget_title":"Free D3 Promo!"},"widget_color":{"header_background_color":"#FFFFFF","body_background_color":"#FFFFFF","widget_title_color":"#5E5873","widget_subtitle_color":"#b9b9c3","offer_title_color":"#82868b","offer_default_color":"#ebe9f1","offer_success_color":"#69CE82"}}},"integration":{"transcy":{"install":false}}};/* END_FG_DATA */
const _0x18b8a3=_0x2f7f;function _0x3e9e(){let $=["?sca_attr_cart","/cart/update","widget_icon_path","url","&width=480&height=480",'\n
\n ',"Select variant","parentNode","cart/add","clone_checkout","innerText","filter_option","sca_fg_innerHTML","args","hasDoneProcessCheckout","width","isDelayShowAdded","div","giftsAdded","currency","sub_conditions","number_of_gift_can_receive","160","textContent","prepend",".fg-secomapp-cart-drawer","#fg-gift-items","sca_checkout_form","product_type","/cart/add.js","not_show_gift_if_already_on_cart",' ',"sca_locale","widget_title","#sca_fg_cart_message_items_section","TODAY_OFFER_SECTION","Can not fetch all body","block","sca-fg-out-stock","keys","gift_items","Add to cart","Error listening XHR send","focus","condition_result","Select your free gift!","NumberFormat","sca_add_gift","concat","flat","cartItems",'\n
\n
\n
\n
\n \n {{ fg_original_price }}\n \n {{ fg_gift_price }} \n
\n \n
\n
\n \n {{ fg_variant_title }}\n \n \n
\n \n
\n \n
\n {{ fg_add_to_cart }}\n \n
\n
\n
',"SHOW_GIFT_SLIDER","button.new_checkout_button, input[value='Checkout'], input[value='Checkout'], input[value='Check out']",".sca-fg-icon-success","#sca_fg_gift_thumbnail_section","gift_products","order_created_from","widget_info","disabled","TODAY_OFFER_SECTION_ID","sca_fg_btn_gift_thumbnail_query","Monster Cart","mouseleave","icon",".btn-add-to-cart","push","undefined","variant_title",".product-item-thumbnail","Don't show this offer again","childElementCount","fg-gifts:updated","checkIsBlockCheckout","appearance",".selected-variant","FG_OVERRIDE_XHR_OPEN","application/liquid","#sca_fg_cart_section_gifts_slider","100","createElement","opacity","END_VALIDATE_CHECKOUT","fg-cart:auto-updated","Slide Cart - Heysenior","monster_refresh","ele","secomappGetCartRunning","forEach","SATCB","(Discount)","/cart/add","fgAppearance","indexOf","dataset","sca-today-offer-right","fit-content","HS_SLIDE_CART_CLOSE","#UpcartPopup:has(#CartPopup[class*='styles_active'])","GIFT_ITEM_SECTION","sca-hide","fg-today-offer:success","customize.disable_slider_text","variants_has_gift","cart_attributes","T4SThemeSP","add_to_cart_btn_color","height","maxWidth","customer_tags","specific_link_address","number_gifts_thumbnail","TODAY_OFFER_WIDGET_ID","#82868b","using_draft_order","#sca_fg_cart_message_section","GIFT_SELECT_SECTION","240","drawer-component#Drawer-Cart cart-drawer","fgData","decompressFromBase64","promotion_message","fg-checkout:start","#sca-gift-icon","variantId","fg-app:start","&sca_products_handle=",".freegifts-main-container .glider-prev","auto add all gifts from {","gift_icon_path","en-US","cal_gift_price","formatter","sca-is-visible-fg","&sca_shop_name=","data-fg-checkout-btn","other_products","sca-gift-icon","hidden_brand_mark","/products/","MinimogEvents","fg-messages:render","location","2735298ZVPsrk","compressToEncodedURIComponent","disable_override_xhr","cal_gift_for_other_rules","bogos-gift","thumbnail","style",".sca-fg-tooltip","number_product_slider","type_customer_locations","icartSideCartOpenEvent","product_shopify_id","variant","backgroundColor","className","hasAttribute",'a[href*="/collections/sca_fg"]',"money","Shopify.getCart","GIFT_THUMBNAIL_SECTION","keyup","variant_id",'\n \n \n \n \n \n ',"customer_order_history","#CartPopup .styles_CartPreview__card__KX-WB, #qikify-stickycart-v2-app .qsc2-drawer-wrapper > div:nth-child(2)","price_max","test","sca_fg_title_product_gift_icon_query","clearInterval","fg-gifts:added","sort","type_customer_tags",".gift-original-url","upcartRegisterAddToCart","disableShopify_getCart","SHOPIFY_CART","variants_ids","then","application/json;","sca_handle_checkout",".gift-price","Theme FoxEcom","pageY","offer.offer_title_","add_to_cart_btn_title","#secomapp_freegifts_version",'\n
\n {{ fg_slider_title }}\n
\n
\n
\n
\n ❮ \n
\n
\n ❯ \n
\n
\n
\n \n {{ sca_fg_disable_slider_section }}\n
',"#close-fg-toast","function","send","#sca_fg_section_gifts_popup","set","substring","MinimogTheme","compare_gift_price_with_product","sca_root_checkout","522222qROJNQ","updateCart","-5px","mousemove","PRODUCT_HAS_GIFTS","compressToBase64","SLIDECART_OPEN","customerLocation","renderPromotionMessage",'\n {{ fg_variant_title }}\n ',"Out of stock","total_spent_on_last_order","src","reduce","customize.gift_slider_title",".product_name, .product-title, .product__title, .product-single__title, .tt-title, .ProductMeta__Title","fgAppearanceTodayOffer","max","partially_paid","Widgets","total_spend_on_order_history","/cart/change","current_product","integration","sca_offers_added","#fg-gift-items .btn-add-to-cart","fetch","CART_AUTO_UPDATED","sca_clone_checkout","call","parseFromString","sca-fg-today-offer-widget-with-title","gifts_valid","XMLHttpRequest","shop",'\n
✕ \n
\n {{ fg_slider_title }}\n
\n
\n
\n
\n ❮ \n
\n
\n ❯ \n
\n
\n
\n \n {{ sca_fg_disable_slider_section }}\n
',"value_customer_locations","current_collection","price","fgAppearancePromotionMessage","sca-fg-form-thumbnail-product-page","hasDiscount","length","widget_subtitle",".freegifts-main-container .glider-next","#sca_fg_today_offer_section","auto","email","DISABLE_SLIDER_SECTION","readystatechange","enable_process_offer_loading","START_VALIDATE_CHECKOUT","mode_override_checkout","data-price","rate","#freegifts-main-popup-container [data-close]","variants_quantity","trigger_body","isUpdateCart","scaCustomLoadingCheckout","Sticky Cart - Codeinero","offer_id","title","Add gift to cart successfully!","discounts","classList","split","sca_link_checkout","prepareDataForDisplayWidgetByRule","event add gift to cart from popup","data-original-price","info",".satcb-cs-checkout-btn, .hs-checkout-purchase","disable_async_process_fg","max_gifts_can_get","track","charAt","scaCountRenderEventCheckout","GIFT_THUMBNAIL_ITEMS_SECTION","TODAY_OFFER_WIDGET","{{sca_min_total}}","gift_popup_title","disable_slider_checkbox","dispatchEvent","getToFetch","productsByID","json",' \n {{ sca-fg-title-icon-widget-content }} \n ',"value_customer_tags","data-fg-offer-id","sca-show","selling_plan_allocation","show_on_cart_page","6505525RInyKl","sca-fg-icon-collection-page","fgCallback","RENDER_CART_MESSAGE","sca_process_gifts","open","string","preventDefault","show_product_title","[type='submit'][name='add'], [type='button'][name='add'], [data-add-to-cart], [data-action='add-to-cart']","by_variants","collection_page","freegifts","auto add gift: {",".freegifts-main-container .slide-container #sca-hidden-gift-popup .sca-disable-checkbox","sca_catch","offer_root","/cart","sca_fg_value_checkout",".sca-list-gift-thumbnail","glider-animated","product_narrow","FoxKitV2","rebuy:smartcart.show","reload","customer","Cannot define custom loading with type: ","freegiftProxy","display","POST","floor","#fg-gift-thumbnail-title .glider-prev","#sca_fg_gift_thumbnail_items_section","#7367f0","fg_codes","offers","$","default","sca_update_url",".sca-promotion-glider","getElementById","GIFT_UPDATED","FGSECOMAPP_HIDDEN_GIFT_POPUP","GIFT_SELECT_SECTION_ID","Claim these exclusive offers today","GET","data-img","https://geoip.secomtech.com/?json","#fg-gift-thumbnail-title",".icart-inner .icartContain, .rebuy-cart__flyout-body, #slidecarthq .slidecarthq","top","freegifts-main-popup-container","visibility","not type checkout btn","products","selling_plan",'',"find","13758192BjOeFa","getAttribute","gifts_id","fg-checkout","original_product_handle","parse","sca_amount_fixed","every","apply","widget_position","boolean","customize.select_variant_button_text","enable_toast_added","getItem","map","?sca_process_gifts","END_PROCESS_CART","join","product_vendors","$$$$",".cc-product-list .product-block, .collection-list.grid .grid__item, .collection-grid.grid .grid__item","discount_type","collections","[data-open]","original_product_shopify_id","and","cal_gift_discount","have_not_got_gift_from_this_offer","60%","100%","6px 0","-sca_clone_freegift","Failed to get customer location","giftsAvailable","#sca-spinner-checkout","type",".sca_handle_button_checkout","sca-promotion-message-layout","arrGiftsData","Rivets Cart","arrGiftsRemove","Slide Cart - qikify","GIFT_THUMBNAIL_ITEMS_SECTION_ID","SLIDECART_CLOSE","sca-fg-toast sca-fg-success","tabindex","fetchCheckoutEvents","enable_check_variants_has_gift","fg_decimal",".sca-fg-notifications","{{sca_min_quantity}}",".satcb-cs .satcb-cs-top-container, #monster-upsell-cart #monster-cart-wrapper div[class*=custom_scrollbar]","#fg-gift-items .dropdown","routes","?sca_add_gift",".sca-promotion-message-layout","gift_settings","do_not_add_freegift_attribute","discounted_price","stopPropagation","toggle","80%","#fg-gift-items .dropdown > .dropdown-menu > li","sca_transcy_locale","sca_fg_form_checkbox_button_query","sca-gift-thumbnail","freegift_attributes","#freegifts-main-popup-container.sca-modal-fg.sca-is-visible-fg","QUERY_SELECTOR",".dots","sca_deplay_cart_msg","gift_icon","icon_and_title","#sca-fg-today-offer-widget","sca_fg_main_promotion_message_query","Cart","quantity","show_pagination","FG_OVERRIDE_FETCH",'{{ fg_gift_thumbnail_title }}
\n\n \n
\n
\n {{ sca_fg_gift_thumbnail_items_section }}\n
\n \n
\n \xab \n \xbb \n
\n
\n
\n
',"searchParams","GIFT_ICON_SECTION","subscribe","remove","customize.product_page_message","insertBefore","color","time","fg-gifts:show-slider","fg-gift-items","original_variant_shopify_id","getTime","tool","current_variant","querySelectorAll","value","Today offer","3ZvWmcK","UpCart - AfterSell","fg-today-offer:render","get",'',"} {","start","fg-fetch:override","end","input[value='Check Out'] a.checkout-link","paid","/cart.js?sca_fetch&","stop_offer","some","#sca_fg_today_offer_item_section","size","maxOfferPriority","variants","last_total","fgAppearanceGiftSlider","api","70%","shopify_widget_icon_path","count_down_quantity","FGSECOMAPP","timeoutId","min_amount","sections_cart","add","catch","#sca-fg-today-offer-iframe","entries","belongs_to_offer","/?sections=","arrOfferAdded","handle","replaceAll","max_amount","vendor","end_time","compare_gift_price","sca-today-offer-widget-left","available","cloneNode",".fg-secomapp-handle-add-to-cart","iCart","sca-today-offer-widget-right","is_only","shift","STICKY_CART_OPEN","show_gift_for_customer","number_of_products","fg-app:end","root","arrGiftsAdd","customize.widget_icon_title","padding","data-offer","prototype","change","gift_thumbnail","Rebuy","pageX","offer.cart_message_","appendChild","positions","icon_widget_title","Unicart","6460592AxSGKu","filter",".icartCheckoutBtn, .rebuy-cart__checkout-button, .qsc2-checkout-button, #mu-checkout-button","querySelector","country_code",'',"clone_product_handle","original_compare_at_price","parentElement","enable","subscription_products","fgAppearanceGiftIcon","TODAY_OFFER_CHANGE","product_types","fg-checkout:end","is_multiply","click","gifts","#sca-fg-today-offer-iframe .sca-fg-body .sca-fg-offers .sca-fg-offer","left","include","redirected","trim","values","FoxTheme","not have orders and gifts","variant_shopify_id","#sca_fg_disable_slider_section","status","cookie","product_has_icon","SLIDECART_OPENED","includes","sca-d-none","now","addGiftToCart","contains","sca_slidecart_tcc","sections","tags","replace",'\n \n \n \n \n \n \n ',"data-template",".fg-secomapp-cart-icon","body","failed to parse cart section ","SLIDECART - HQ","giftsAddedInvalid","#sca-fg-today-offer-widget .sca-fg-count-offers","HS_SLIDE_CART_UPDATE","addEventListener","start_time","SLIDECART_UPDATE","text/html","log","41978439EloHMj","TODAY OFFER","#upCartStickyButton .upcart-sticky-cart-quantity-icon-text","currentTarget","sca_price","hide","compare_at_price","items","application/json","action","active ","auto_add_all_gifts","fetchCart","error","freegifts-main-page-container","number_of_order","gift_slider","sca_add_url","customLoadingCheckout",'a[href*="/products/"]',"removeEventListener",".product-card, #product-grid .grid__item, .product-grid .grid__item, .card-list .card-list__column","active","pubSubEvents","pathname","CART_MSG_SECTION","upcartOnCartOpened","data-sca-fg-today-offer-title-tooltip","fg-cart:end-process","START_PROCESS_CART","CartSlider","cart","flex","USD","href","sync_quantity","stringify","setAttribute",".f\\:featured-collection .f\\:featured-collection-block .f\\:column","readyState","openDrawer","this is others","getCart","today_offer","sca_fg_codes","others","count_down_value","none","target","isReachConditions",'\n {{ fg_cart_message }}\n
',"product","message","sca-offer-archived","#sca-fg-today-offer-iframe .sca-fg-body .sca-fg-offers",'\n {{ sca_fg_cart_message_items_section }}\n
',".dropdown-menu","openSlider","setItem","free-gift-icon","relative","CUSTOM_EVENTS","startsWith","productsInPage","product_id","#shopify-section-header #cart-icon-bubble, .shopify-section.section-header #cart-icon-bubble","innerHTML","bottom_right","locale",".m-product-form--wrapper","object","offer","scaHandleConfigValue","offer_conditions","number","final_price","initializeForXHR","gift_should_the_same","headers","data-variant","text","closeCart","original_price","fgSettings","financial_status","select_one_gift_price","154151flwrHc","condition_relationship","#sca-gift-thumbnail","d-block","unshift","transcy","product_page","7egozWz","input[name='goto_gc'], button[name='goto_gc'], a[href$='checkout'], form[action='/checkout'] input[type='submit']","toString","cart-drawer .mini-cart__inner .mini-cart__empty, cart-drawer .mini-cart__inner .mini-cart__main","unit","stop_lower_priority","sca-gift-icon-collection-page","format","TODAY_OFFER_ITEM_SECTION","offer_name","slice","customGiftImgSize","STICKY_CART_UPDATE","priority","manual_input_inventory","inventory_management","add_cart_discounts","position","reRenderCartCustom",'\n \n \n \n ',"toFixed","div[class*=hs-cart-drawer] .hs-site-cart-popup-layout, #MinimogCartDrawer m-cart-drawer-items, #CartDrawer > .drawer__inner","sections_url"];return(_0x3e9e=function(){return $})()}function _0x2f7f($,x){let t=_0x3e9e();return(_0x2f7f=function($,x){return t[$-=230]})($,x)}if(!function($,x){let t=_0x2f7f,e=$();for(;;)try{let a=parseInt(t(637))/1+parseInt(t(866))/2*(parseInt(t(428))/3)+-parseInt(t(496))/4+-parseInt(t(273))/5+-parseInt(t(810))/6*(-parseInt(t(644))/7)+-parseInt(t(331))/8+parseInt(t(551))/9;if(899389===a)break;e.push(e.shift())}catch(i){e.push(e.shift())}}(_0x3e9e,899389),window[_0x18b8a3(786)]?.[_0x18b8a3(741)]?.[_0x18b8a3(402)]?.[_0x18b8a3(796)]&&"string"==typeof fgGiftIcon&&(window[_0x18b8a3(786)][_0x18b8a3(741)].gift_icon[_0x18b8a3(796)]=fgGiftIcon),window.fgData?.[_0x18b8a3(741)]?.[_0x18b8a3(594)]?.shopify_widget_icon_path&&fgWidgetIconsObj){let $=window[_0x18b8a3(786)][_0x18b8a3(741)][_0x18b8a3(594)][_0x18b8a3(450)];window[_0x18b8a3(786)][_0x18b8a3(741)].today_offer[_0x18b8a3(669)]=fgWidgetIconsObj[$]??$}!function $(){let x=_0x18b8a3;window[x(452)]={},FGSECOMAPP[x(444)]=null,FGSECOMAPP[x(717)]=Object[x(519)](Shopify?.[x(717)]??{}),FGSECOMAPP.offers=[],FGSECOMAPP[x(634)]=window[x(786)]?.settings??{},FGSECOMAPP[x(759)]=window[x(786)]?.[x(741)]??{},FGSECOMAPP.fgIntegration=window.fgData?.integration??{},FGSECOMAPP[x(447)]=FGSECOMAPP[x(759)]?.[x(567)]?.general,FGSECOMAPP[x(507)]=FGSECOMAPP.fgAppearance?.[x(402)],FGSECOMAPP[x(905)]=FGSECOMAPP[x(759)]?.[x(788)],FGSECOMAPP.fgAppearanceTodayOffer=FGSECOMAPP[x(759)]?.today_offer,FGSECOMAPP[x(275)]=[],FGSECOMAPP[x(754)]=!1,FGSECOMAPP[x(462)]=[],FGSECOMAPP[x(257)]=0,FGSECOMAPP[x(740)]=!1,FGSECOMAPP[x(623)]={...Shopify?.[x(623)]},FGSECOMAPP[x(662)]=Shopify?.[x(662)]??void 0,FGSECOMAPP[x(239)]=Shopify?.[x(239)]??void 0,FGSECOMAPP[x(614)]={},FGSECOMAPP.productsByID={},FGSECOMAPP.hasDoneProcessCheckout=!1,FGSECOMAPP[x(455)]={},FGSECOMAPP[x(238)]=!1,FGSECOMAPP[x(845)]={},FGSECOMAPP[x(555)]=Shopify?.sca_fg_price??x(389),FGSECOMAPP[x(333)]=[],FGSECOMAPP[x(612)]={SHOW_GIFT_SLIDER:x(419),PRODUCT_HAS_GIFTS:"fg-gifts:gift-icon",GIFT_UPDATED:x(739),GIFT_ADDED:x(839),CART_AUTO_UPDATED:x(750),START_PROCESS_CART:"fg-cart:start-process",END_PROCESS_CART:x(579),START_VALIDATE_CHECKOUT:x(789),END_VALIDATE_CHECKOUT:x(510),START_RENDER_APP:x(792),END_RENDER_APP:x(480),FG_OVERRIDE_FETCH:x(435),FG_OVERRIDE_XHR_OPEN:"fg-xhr:open",FG_OVERRIDE_XHR_SEND:"fg-xhr:send",RENDER_TODAY_OFFER:x(430),TODAY_OFFER_CHANGE:x(768),RENDER_CART_MESSAGE:x(808)};let t={GIFTS_CART_SECTION_ID:x(745),GIFTS_CART_SECTION:x(856),GIFTS_POPUP_SECTION_ID:x(860),GIFTS_POPUP_SECTION:x(901),GIFT_ITEM_SECTION_ID:"#sca_fg_section_gift_item",GIFT_ITEM_SECTION:x(718),GIFT_SELECT_SECTION_ID:"#sca_fg_variant_select_section",GIFT_SELECT_SECTION:x(875),DISABLE_SLIDER_SECTION_ID:x(523),DISABLE_SLIDER_SECTION:x(329),CART_MSG_SECTION_ID:x(782),CART_MSG_SECTION:x(606),CART_MSG_ITEM_SECTION_ID:x(701),CART_MSG_ITEM_SECTION:x(601),GIFT_THUMBNAIL_SECTION_ID:x(722),GIFT_THUMBNAIL_SECTION:x(410),GIFT_THUMBNAIL_ITEMS_SECTION_ID:x(305),GIFT_THUMBNAIL_ITEMS_SECTION:x(432),GIFT_ICON_SECTION_ID:"#sca_fg_gift_icon_section",GIFT_ICON_SECTION:x(698),TODAY_OFFER_SECTION_ID:x(911),TODAY_OFFER_SECTION:x(501),TODAY_OFFER_ITEM_SECTION_ID:x(442),TODAY_OFFER_ITEM_SECTION:'\n
\n
\n
{{ sca_fg_offer_title }} \n
\n
\n \n \n \n \n \n
',TODAY_OFFER_WIDGET_ID:"#sca_fg_today_offer_widget",TODAY_OFFER_WIDGET:x(267)},e=()=>{let $=x,t=FGSECOMAPP[$(759)]?.[$(567)],e=t?.others?.[$(805)],a=!C(t)&&void 0!==e&&!e;return a?$(672):""},a=()=>{let $=x,e=FGSECOMAPP.fgAppearance?.gift_slider,a=e?.[$(262)]??{};document[$(499)]($(287))?.checked&&localStorage[$(609)]($(315),""+Date[$(530)]());let i=document[$(499)](t.DISABLE_SLIDER_SECTION_ID)?.[$(617)]??t[$(914)];return a?.[$(505)]?i.replaceAll(/{{\s*fg_text_disable_slider\s*}}/gm,h(b(a[$(631)]??$(737),$(769)))):""},{fetch:i}=window,r=()=>{let $=x;document.querySelector($(855))?.[$(332)]($(538))!==$(334)&&(window[$(892)]=async(...x)=>{let t=$;try{let e=x[0];if(!(e?.[t(528)]("/cart/add")||e?.[t(528)]("/cart/change")||e?.[t(528)](t(668))))return setTimeout(function(){$y()},1e3),await i(...x);{let a=e?.[t(528)](t(758)),r=e?.[t(528)](t(887))||e?.includes(t(668));f(x[1]);let c=200,o=null,s=await i(...x)[t(847)]($=>{let x=t;return(o=$,c=$[x(524)],$.redirected)?$:$[x(266)]()})[t(457)]($=>{console[t(564)]($)});if(document[t(263)](new CustomEvent(FGSECOMAPP[t(612)].FG_OVERRIDE_FETCH,{detail:{args:x,response:o}})),a&&x[1][t(629)]?.[t(714)]&&200!==c){let l=JSON[t(336)](x[1][t(540)])?.id,_=document[t(499)]('.btn-add-to-cart[data-variant="'+l+'"]');_[t(677)]=t(876),_[t(245)][t(532)](t(705))||_[t(245)].add("sca-fg-out-stock"),_[t(726)]=!0,_.style[t(484)]="",_[t(816)].backgroundColor=t(780),document[t(425)](t(732))[t(755)]($=>{let x=t;parseInt($[x(332)](x(630)))===l||$[x(245)][x(532)](x(705))||($[x(726)]=!1,$[x(816)][x(823)]=FGSECOMAPP[x(759)]?.[x(567)]?.[x(417)]?.[x(773)]??x(306))})}if(200!==c&&(a&&x[1][t(629)]?.[t(714)]||r&&x[1][t(629)]?.[t(277)]))return n(s,o);if(Shopify?.[t(253)])return $s([e,...x[t(654)](1)])[t(847)](),n(s,o);if(await $s([e,...x[t(654)](1)]),r&&x[1]?.[t(629)]?.[t(277)])return n(s,o);let g=r?FGSECOMAPP.SHOPIFY_CART??s??{}:s;return await d(x,s,g),n(g,o)}}catch(u){return await i(...x)}})},c=window[x(899)].prototype[x(278)],o=window[x(899)][x(486)][x(859)],s=()=>{let $=x;Shopify?.[$(812)]||(window[$(899)].prototype[$(278)]=function(x,t){let e=$;try{document.dispatchEvent(new CustomEvent(FGSECOMAPP[e(612)].FG_OVERRIDE_XHR_OPEN,{detail:{fgXHR:this}}))}catch(a){console[e(564)]("Error listening XHR open",a)}finally{c[e(339)](this,arguments)}},window[$(899)][$(486)].send=function(x){let t=$;try{document[t(263)](new CustomEvent(FGSECOMAPP[t(612)][t(743)],{detail:{fgXHR:this}}));let{_url:e}=this;(e?.[t(528)](t(758))||e?.includes(t(887))||e?.[t(528)](t(668)))&&this[t(546)](t(915),function(){let $=t;this[$(590)]===XMLHttpRequest.DONE&&200===this[$(524)]&&$s([e,{}])[$(847)]()})}catch(a){console[t(564)](t(709),a)}finally{o[t(895)](this,x)}})};FGSECOMAPP[x(627)]=()=>{let $=x;try{if(Shopify?.[$(844)]||typeof Shopify?.getCart!==$(858))return;Shopify.getCart=async function(x){let t=$;if(!FGSECOMAPP[t(754)]){FGSECOMAPP[t(754)]=!0,await $s([t(828),{}]);let e=await $r("sca_cart_xhr");typeof x===t(858)&&(0>FGSECOMAPP[t(275)][t(760)](x)&&FGSECOMAPP[t(275)][t(733)](x),x(e)),FGSECOMAPP[t(754)]=!1}FGSECOMAPP[t(377)]()},typeof ShopifyAPI!==$(734)&&typeof ShopifyAPI.getCart!==$(734)&&(ShopifyAPI[$(593)]=Shopify?.getCart),typeof Shopify?.[$(448)]!==$(734)&&typeof Shopify?.[$(448)][$(593)]!==$(734)&&(Shopify[$(448)][$(593)]=Shopify?.[$(593)])}catch(t){console[$(564)](t)}};let f=$=>{let t=x;try{let e=$?.[t(540)];e instanceof FormData?FGSECOMAPP[t(455)]={sections:e.get("sections"),sections_url:e.get("sections_url")}:typeof e===t(279)&&(e=JSON.parse(e),FGSECOMAPP[t(455)]={sections:e?.[t(534)],sections_url:e?.[t(666)]})}catch(a){FGSECOMAPP[t(455)]={}}},n=($,t)=>{let e=x;try{let a=Shopify?.fg_fetch_attributes??[e(670),e(366),e(517),"ok"],i=new Response(JSON.stringify($),t);for(let r of a)Object.defineProperty(i,r,{value:t[r]});return i}catch(c){return new Response(JSON[e(587)]($))}},l=async()=>{let $=x;if(Shopify[$(388)])return;let t=[];if(!C(FGSECOMAPP[$(462)]))for(let e of(t[$(733)]("SECOMAPP_FREEGIFT"),FGSECOMAPP[$(462)])){let a=FGSECOMAPP[$(308)][$(330)](x=>x.id===e[$(460)])?.[$(687)]?.[$(777)];C(a)||t[$(733)](a)}if(t.sort(),t[$(646)]()!==FGSECOMAPP?.[$(845)]?.attributes?.[$(397)])try{await i((Shopify?.[$(311)]??$(668))+$(667),{method:$(302),headers:{"X-Requested-With":"XMLHttpRequest","Content-Type":$(848)},body:JSON[$(587)]({attributes:{freegift_attributes:t[$(646)]()}})})}catch(r){console[$(564)]("Update cart.attributes "+r[$(603)])}},d=async($,t,e)=>{let a=x;try{if($[1]?.[a(629)]?.[a(277)])return;let r={},c=Object[a(706)](t[a(534)]??{})?.[a(497)]($=>C(FGSECOMAPP.sections_cart[$]))??[];if(c&&c[a(908)]&&FGSECOMAPP.isUpdateCart&&(r=await i(a(461)+c.join(","))[a(847)]($=>$[a(266)]())),FGSECOMAPP.isUpdateCart=!1,r={...FGSECOMAPP.sections_cart,...r},C(r))return;t[a(534)]={...t[a(534)],...r},C(e)||(e[a(534)]={...t.sections})}catch(o){}};FGSECOMAPP[x(531)]=async($,t,e)=>{let a=x;try{let i=FGSECOMAPP[a(462)][a(330)](x=>e===x[a(460)]?.toString()&&$===x.variantId);i?i[a(407)]+=t:FGSECOMAPP[a(462)][a(641)]({variantId:$,belongs_to_offer:e,quantity:t}),localStorage[a(609)](a(890),LZString[a(871)](JSON[a(587)](FGSECOMAPP[a(462)]))),p("start");let r=await fetch((Shopify?.[a(568)]??a(696))+a(385),{method:a(302),headers:{Accept:a(559),"Content-Type":a(559),sca_add_gift:"1"},body:JSON[a(587)]({quantity:t,id:$})});return await r[a(266)]()}catch(c){return!1}};let _=async($,t,e)=>{let a=x;e=e?.[a(646)]();let i=document.querySelectorAll(a(891));i.forEach(x=>{let t=a;x[t(726)]=!0;let e=x[t(332)]("data-variant")-0;e===$&&(x[t(816)][t(484)]=t(361),x[t(617)]=t(832)),x.style[t(823)]=t(780)});let r=await FGSECOMAPP.addGiftToCart($,t,e);r&&(i[a(755)](x=>{let t=a;x[t(726)]=!0;let e=x[t(332)](t(630))-0;e===$&&(x[t(816)][t(484)]="6px 0",x[t(617)]=t(663)),x[t(816)][t(823)]=""}),$f()),document.dispatchEvent(new CustomEvent(FGSECOMAPP[a(612)].GIFT_ADDED,{detail:{gift:r}}))},g=$=>{let t=x,e=t(362);return!C($)&&(typeof $===t(621)&&($[t(463)]?.[t(528)](e)||$[t(535)]?.includes(t(814))||FGSECOMAPP[t(333)]?.[t(528)]($[t(831)]))||typeof $===t(279)&&$[t(528)](e))},u=$=>{let{selling_plan_allocation:t}=$;return!C(t)&&!C(t?.[x(328)])},p=$=>{let t=x;try{if(!Shopify?.[t(230)])return;let{checkout_btn_query:e}=FGSECOMAPP[t(399)],a=[...e?.[t(423)],...e?.integration,...e?.[t(310)]][t(497)](Boolean).join(",");document[t(425)](a)[t(755)](x=>{let e=t;FGSECOMAPP[e(569)]($,x)[e(847)]()})}catch(i){}},m=async($,t)=>{let e=x;try{if(C($)&&C(t))return;let a={};if(FGSECOMAPP[e(717)]?.[e(497)]($=>g($))?.[e(755)]($=>{let x=e;a[$[x(831)]]=$[x(407)]}),($=$?.filter($=>!C($.variant_id)))?.forEach($=>{let x=e;a[$[x(831)]]=(a[$[x(831)]]??0)+($[x(407)]??1)}),Object.keys(a)?.[e(755)]($=>{a[$]=a[$]>=0?a[$]:0}),C(Object.keys(a)))return;$?.[e(755)]($=>{let x=e,t=FGSECOMAPP[x(462)][x(330)](t=>$[x(241)]?.toString()===t[x(460)]?.toString()&&$[x(831)]===t[x(791)]);t?t[x(407)]+=$[x(407)]:FGSECOMAPP[x(462)][x(641)]({variantId:$[x(831)],belongs_to_offer:$[x(241)]?.[x(646)](),quantity:$[x(407)]})}),localStorage[e(609)](e(890),LZString[e(871)](JSON[e(587)](FGSECOMAPP[e(462)]))),FGSECOMAPP.isUpdateCart=!0,p(e(434)),await fetch((Shopify?.sca_update_url??"/cart/update")+e(346),{method:e(302),headers:{Accept:e(559),"Content-Type":"application/json",sca_process_gifts:"1"},body:JSON.stringify({updates:a,...FGSECOMAPP[e(455)]})})[e(847)](x=>{let a=e;return x.ok&&$[a(908)]&&!t[a(908)]&&$f(),x[a(266)]()})[e(847)]($=>{let x=e;FGSECOMAPP[x(455)]=$[x(534)]}),document[e(263)](new CustomEvent(FGSECOMAPP[e(612)][e(893)],{detail:{arrGiftsAdd:$,arrGiftsRemove:t}})),document.querySelector(e(855))?.getAttribute(e(538))===e(334)&&location[e(297)]()}catch(i){p(e(436)),console[e(564)](i)}},b=($,t)=>{let e=x;try{let a=FGSECOMAPP.fgIntegration?.[e(642)],i=Shopify?.[e(394)]??Shopify?.[e(619)];return a.enable?a?.[i]?.[t]??$:$}catch(r){return $}},h=($,t=!1)=>(""+$).replaceAll(/\$/g,x(t?350:309)),y=()=>{let $=x,i=document.getElementById($(565));if(i){let r=document[$(499)](t.GIFTS_CART_SECTION_ID)?.[$(617)]??t.GIFTS_CART_SECTION;i[$(617)]=r[$(464)](/{{\s*fg_slider_title\s*}}/gm,h(b(FGSECOMAPP[$(447)][$(261)]??$(712),$(880))))[$(464)](/{{\s*sca_fg_disable_slider_section\s*}}/gm,h(e()))}else{let c=localStorage[$(344)]($(315))-0,o=FGSECOMAPP[$(759)]?.[$(567)]?.[$(262)]??{},s=(o?.[$(418)]??0)*6e4,f=!isNaN(c)&&c+s>Date[$(530)]();if(f||(localStorage.removeItem($(315)),!(i=document[$(313)]($(324)))))return;let n=document[$(499)](t.GIFTS_POPUP_SECTION_ID)?.[$(617)]??t.GIFTS_POPUP_SECTION;i[$(617)]=n[$(464)](/{{\s*fg_slider_title\s*}}/gm,h(b(FGSECOMAPP[$(447)].gift_popup_title??$(712),$(880))))[$(464)](/{{\s*sca_fg_disable_slider_section\s*}}/gm,h(a()+" "+e())),i.classList[$(456)]($(800))}},v=($,e)=>{let a=x,i=document[a(499)](t[a(316)])?.innerHTML??t[a(783)];return $[a(345)]($=>i[a(464)](/{{\s*fg_variant_img\s*}}/gm,h(K($[a(815)]??e),!0))[a(464)](/{{\s*fg_variant_id\s*}}/gm,h($[a(522)]))[a(464)](/{{\s*fg_original_variant_id\s*}}/gm,h($[a(421)]))[a(464)](/{{\s*fg_variant_price\s*}}/gm,h(T($)))[a(464)](/{{\s*fg_original_variant_price\s*}}/gm,h(E($)))[a(464)](/{{\s*fg_variant_title\s*}}/gm,h($[a(735)])))[a(348)](" \n")},T=$=>{let t=x;return FGSECOMAPP[t(799)][t(651)]($?.price)},E=$=>{let t=x;return FGSECOMAPP[t(799)][t(651)]($?.[t(798)]??0)},w=($,t)=>C(FGSECOMAPP.productsByID[$])?t??"#":FGSECOMAPP.productsByID[$][x(463)],S=($,t)=>{let e=x;return FGSECOMAPP[e(447)][e(281)]?C(FGSECOMAPP[e(265)][$])?t.replace("\xbb","")[e(536)]("\uD83C\uDF81","")[e(536)](/\(\d*% off\)/,"")[e(536)](e(757),"")??"":FGSECOMAPP[e(265)][$][e(242)]:""},C=$=>{let t=x;if(0===$)return!0;if(typeof $==t(625)||"boolean"==typeof $)return!1;if(typeof $==t(734)||null===$)return!0;if(void 0!==$[t(908)])return 0===$.length;let e=0;for(let a in $)$.hasOwnProperty(a)&&e++;return 0===e},I=$=>{let t=x;try{let e={...FGSECOMAPP[t(623)]},a=e[$];if(a=a?a[t(518)]():null,!C(a)&&a[t(908)]>0)try{return document[t(499)](a),a}catch(i){}return""}catch(r){return""}},A=()=>{let $=x;try{FGSECOMAPP[$(799)]=new Intl[$(713)](Shopify?.[$(699)]??Shopify?.[$(619)],{style:$(686),currency:Shopify?.[$(686)]?.active??$(584)})}catch(t){FGSECOMAPP.formatter=new Intl[$(713)]($(797),{style:$(686),currency:Shopify?.[$(686)]?.[$(573)]??$(584)})}},O=$=>{let t=x;$=$??0;let e=Shopify?.[t(686)]?.[t(234)]??1;return parseFloat(1===parseFloat(e)?$:($*e)?.[t(664)](Shopify?.[t(379)]??2))},k=$=>{let t=x;try{return $[FGSECOMAPP[t(555)]]??$?.[t(626)]??$?.[t(904)]}catch(e){return $?.[t(626)]??$?.[t(904)]}},D=$=>{let t=x;return $[t(497)]($=>void 0===$[t(813)]||!0===$.cal_gift_for_other_rules).reduce(($,x)=>$+x[t(407)]*k(x),0)/100},R=$=>{let t=x;return $[t(497)]($=>void 0===$[t(813)]||$[t(813)])[t(879)](($,x)=>$+x[t(407)],0)},F=($,t,e)=>{let a=x,i=t[a(294)];return e?.[a(475)]===!0?$=$[a(497)]($=>u($)):e?.[a(475)]===!1&&($=$[a(497)]($=>!u($))),C(i)?$:$.filter($=>{let x=a,t=i[0]?.[x(678)]??x(516),e=i.map(t=>{let e=x;switch(t[e(366)]){case e(846):return Object[e(519)](t[e(426)])[e(345)]($=>$[e(822)])[e(716)]()[e(345)]($=>$.id)[e(528)]($[e(831)]);case e(509):return Object.values(t[e(426)])[e(528)]($.product_type);case e(349):return Object.values(t[e(426)])[e(528)]($[e(466)]);case"product_collections":let a=Object[e(706)](t[e(426)]),i=$[e(353)]?.[e(345)]($=>$.id+"")?.filter($=>a.includes($));return!C(i);default:return!1}});return t===x(516)?!e[x(528)](!1):e[x(528)](!1)})},N=($,t)=>{let e=x;return $?.[e(345)]($=>{let x=e;if(typeof $[x(813)]!==x(734)){let a=FGSECOMAPP[x(462)]?.[x(497)](t=>t[x(791)]===$[x(831)]),i=a?.[x(879)](($,t)=>$+t[x(407)],0);if(i===$.quantity){let r=a?.filter(e=>{let a=x;if(e[a(460)]?.toString()===t[a(646)]())return!1;let i=FGSECOMAPP.offers?.[a(330)]($=>$.id?.[a(646)]()===e[a(460)]?.[a(646)]()),r=i[a(387)]??{},c=k($);return r[a(813)]&&c>0})?.[x(879)](($,t)=>$+t[x(407)],0);return{...$,cal_gift_for_other_rules:r>0,quantity:r??0}}return{...$,cal_gift_for_other_rules:!1,quantity:0}}return{...$}})??[]},L=($,t)=>{let e=x,a=FGSECOMAPP[e(634)]?.[e(864)],i=FGSECOMAPP[e(634)]?.[e(697)],r=$,c=r;if(a){r=$.sort(($,x)=>k($)-k(x));let o=t.gift_items[e(345)]($=>$?.compare_gift_price??0);r=r.filter($=>o[e(441)](x=>x<=k($)/100)),c=JSON[e(336)](JSON[e(587)](r));let s=t.giftsAdded[e(840)](($,x)=>x?.[e(468)]-$?.[e(468)])[e(345)]($=>({...$}));c.filter($=>$[e(407)]>0).forEach($=>{let x=e,t=k($)/100;s[x(497)]($=>$.quantity>0)[x(497)]($=>$?.[x(468)]<=t)[x(755)](t=>{let e=x,a=$.quantity-t.quantity;t[e(407)]-=a>=0?t[e(407)]:$[e(407)],$[e(407)]=Math[e(883)](a,0)})}),t[e(543)]=s[e(497)]($=>$.quantity>0),c=c[e(497)]($=>$[e(407)]>0)}r=r[e(497)]($=>$[e(407)]>0);let f=FGSECOMAPP[e(717)].map($=>$[e(615)]),n=t[e(723)]?.[e(345)]($=>$[e(355)]);if(i){let l=n.filter($=>r[e(338)](x=>x[e(615)]!==$));r=l.length?r[e(497)]($=>!l?.[e(528)]($[e(615)])):[]}let d=[];return FGSECOMAPP[e(634)]?.[e(636)]&&(d=FGSECOMAPP[e(717)][e(497)]($=>g($))[e(345)]($=>$.variant_id)),t[e(898)]=JSON[e(336)](JSON.stringify(t[e(723)]))?.[e(497)]($=>{let x=e;return $.variants=$[x(445)][x(497)]($=>!d[x(528)]($[x(522)])),!(i&&f?.[x(528)]($.original_product_shopify_id))&&(a&&($[x(445)]=$.variants[x(497)]($=>{let t=x;return c[t(441)](x=>$[t(468)]<=k(x)/100)})),!C($[x(445)]))}),r},q=($,t,e)=>{let a=x,i=0,r=F(t,$,e[a(687)]?.[a(506)]);r=N(r,$[a(241)]),r=L(r,e);let c=0;return $.unit===a(827)?(c=D(r),e[a(597)]=Math[a(883)]($.min_amount-c,0)):"number_of_products"===$[a(648)]&&(c=R(r),e.count_down_quantity=Math[a(883)]($[a(454)]-c,0)),c>=$[a(454)]&&(null===$.max_amount||c<=$[a(465)])&&(i=e[a(387)][a(688)]*($.is_multiply?Math[a(303)](c/$[a(454)]):1)),i},G=($,t)=>{let e=x,a={},i=[],r=0;return t[e(624)][e(345)](x=>{let a=q(x,$,t);0!==a&&(r=a),i[e(733)](a>0)}),a[e(254)]=r,a[e(711)]=i,a},P=($,t)=>{let e=x,a=!1;return 1===$.length?a=$[0]:2===$[e(908)]&&(t===e(356)&&(a=$[0]&&$[1]),"or"===t&&(a=$[0]||$[1])),a},M=($,t)=>{let e=x,a=$?.[e(345)]($=>$[e(831)]);FGSECOMAPP[e(462)]=FGSECOMAPP[e(462)][e(497)]($=>a?.[e(528)]($[e(791)]));let i=t[e(707)][e(345)]($=>$[e(522)]),r={};t[e(707)][e(497)]($=>r[$[e(522)]]={fg_original_compare_at_price:$[e(503)],fg_original_price:$[e(633)],compare_gift_price:$.compare_gift_price});let c=FGSECOMAPP.arrOfferAdded[e(497)]($=>$.belongs_to_offer?.[e(646)]()===t.id?.[e(646)]())?.map($=>$.variantId),o=$[e(497)]($=>{let x=e;return g($)&&($.cal_gift_for_other_rules=!1),i[x(528)]($.variant_id)&&c[x(528)]($[x(831)])}),s=o[e(345)]($=>{let x=e,a=t[x(387)];$.cal_gift_for_other_rules=a[x(813)],$.belongs_to_offer=t.id?.[x(646)]();let i=FGSECOMAPP[x(462)]?.[x(497)](e=>e[x(460)]?.[x(646)]()!==t.id?.[x(646)]()&&$[x(831)]===e.variantId)?.[x(879)](($,t)=>$+t[x(407)],0);return{...$,quantity:$.quantity-i,...r[$[x(831)]]}});return s[e(497)]($=>{let x=e;return $[x(460)]?.[x(646)]()===t.id?.toString()})},H=$=>{let t=x,e=$.giftsAdded.filter(x=>x[t(460)]?.toString()!==$.id?.[t(646)]())[t(345)]($=>$.product_id);return Object[t(519)]($[t(898)]).filter($=>!e[t(528)]($[t(821)]))},U=($,t)=>{let e=x,a=M($,t);t[e(685)]=a;let i=G($,t),r=P(i.condition_result,t[e(638)]);if(r){let c=a[e(497)]($=>$[e(460)]?.toString()===t.id?.[e(646)]())[e(879)](($,x)=>$+x[e(407)],0);i[e(254)]=i.max_gifts_can_get-c,t[e(685)]=a,t[e(364)]=i.max_gifts_can_get}else t.giftsAdded=a,t[e(364)]=0;return!C(FGSECOMAPP.maxOfferPriority)&&t.priority>FGSECOMAPP[e(444)]&&(r=!1),t.stop_lower_priority&&r?FGSECOMAPP[e(444)]=t[e(657)]:!t[e(649)]||r||C(a)||t[e(657)]!==FGSECOMAPP[e(444)]||(FGSECOMAPP.maxOfferPriority=null),t[e(600)]=r,t},B=$=>{let t=x,e=$+"=",a=document[t(525)].split(";");for(let i=0;i{let e=x,a=!0,i=!0,r=!0,c=!0;if(!C($[e(687)]?.[e(777)])){let o=B("sca_fg_codes");a=o&&JSON[e(336)](o)[e(528)]($.sub_conditions[e(777)])}if(!C($[e(687)]?.[e(776)])){let{customer_tags:s}=$[e(687)],f=s?.[e(268)]?.[e(441)]($=>t[e(298)].tags?.includes($));i=s?.[e(841)]===e(516)?f:!f}if(!C($[e(687)]?.customer_locations)){let{customer_locations:n}=$.sub_conditions,l=n?.[e(902)]?.[e(528)](FGSECOMAPP[e(873)]);c=n?.[e(819)]==="include"?l:!l}if(!C($.sub_conditions?.[e(833)])){let d=!0,_=$[e(687)].customer_order_history,g=t[e(298)].orders??[];if(_[e(724)]){let u=Date[e(336)](_[e(724)])/1e3;g=g.filter($=>$.created_at>=u&&[e(438),e(884)][e(528)]($[e(635)]))}if(!C(_?.[e(886)])&&(0!==_[e(886)][e(454)]||0!==_[e(886)][e(465)])){let p=_.total_spend_on_order_history[e(454)],m=_.total_spend_on_order_history[e(465)],b=g.reduce(($,x)=>$+x.total_price,0)/100;d&=(b>=p||!p)&&(b<=m||!m)}if(!C(_?.[e(877)])&&(0!==_[e(877)][e(454)]||0!==_[e(877)][e(465)])){let h=(t.customer[e(446)]??0)/100,y=_.total_spent_on_last_order[e(454)],v=_[e(877)][e(465)];d&=g[e(908)]>0&&(h>=y||!y)&&(h<=v||!v)}if(!C(_?.[e(566)])){let T=!(0!==_.number_of_order[e(454)]||0!==_[e(566)][e(465)]),E=g.length,w=_.number_of_order[e(454)],S=_[e(566)][e(465)];d&=T?C(g):(E>=w||!w)&&(E<=S||!S)}if(_?.[e(358)]){let I=t[e(298)][e(285)]??[],A=$[e(707)]?.[e(441)]($=>I[e(528)]($[e(522)]))||$[e(707)]?.[e(441)]($=>I[e(528)]($[e(421)]+"_"+($[e(633)]-$[e(904)])*100)||I[e(528)]($[e(421)]+"_"+($[e(503)]-$[e(904)])*100));d&=!A}r=d}return a&&i&&r&&c},j=($,t,e)=>{let a=x,i=[],r=[],c=[],o=[];for(let s of t){let f=U($,s);if(!f[a(600)]){if(!f.giftsAdded.length)continue;f[a(685)][a(755)]($=>{let x=a;r[x(733)]({variant_id:$.variant_id,quantity:$.quantity,offer_id:s.id})});continue}if(f[a(364)]<0){f.giftsAdded[a(755)]($=>{let x=a;r[x(733)]({variant_id:$[x(831)],quantity:$[x(407)],offer_id:s.id})});continue}if(0===f[a(364)]){f.giftsAdded[a(755)]($=>{let x=a,t=FGSECOMAPP[x(462)][x(330)](t=>s.id?.[x(646)]()===t[x(460)]?.toString()&&$[x(831)]===t[x(791)]);t&&(t[x(407)]=$.quantity)});continue}(s[a(687)]&&Y(s,SECOMAPP)||C(s[a(687)]))&&i[a(733)](s)}if($?.[a(497)]($=>g($))[a(755)]($=>{let x=a,t=0,e=FGSECOMAPP[x(462)]?.[x(497)](t=>$[x(831)]===t.variantId)?.[x(879)](($,t)=>$+t[x(407)],0)??0;e<$[x(407)]&&(t=$[x(407)]-e),C($.belongs_to_offer)&&(t=$[x(407)]),t>0&&r[x(733)]({variant_id:$[x(831)],quantity:t,offer_id:$[x(460)]?.toString()})}),e||C(r)){let n=i.map($=>{let x=a;return{id:$.id,offerName:$.offer_name,offerPriority:$[x(657)],stopLowerPriority:$.stop_lower_priority,gifts:H($),giftsAvailable:$[x(364)],giftsAdded:$[x(685)],isReachConditions:$[x(600)],offer:$}});if(!C(n)){let l={};for(let d of n){let _=W(FGSECOMAPP[a(634)],d);_?.[a(908)]>0?c=c.concat([..._]):d[a(513)].map($=>{let x=a;l[$[x(821)]]={...$,belongs_to_offer:d.id?.[x(646)]()}})}o=Object[a(519)](l)??[]}}return{arrGiftsAdd:c,arrGiftsRemove:r,arrGiftsData:o}},z=($,t)=>{let e=x,a=new Set;return $?.[e(755)]($=>a[e(456)]($[e(241)])),a[e(755)]($=>{let x=e,t=FGSECOMAPP.offers?.[x(330)](t=>t.id?.toString()===$?.[x(646)]());if(C(t)||!t[x(600)]){FGSECOMAPP[x(462)]=FGSECOMAPP[x(462)]?.[x(497)](t=>t[x(460)]?.[x(646)]()!==$?.[x(646)]());return}if(t[x(364)]>=0)return;let a=[],i=FGSECOMAPP[x(462)]?.[x(497)](t=>t[x(460)]?.[x(646)]()===$?.[x(646)]())??[];if(t?.[x(387)]?.auto_add_all_gifts)a=a[x(715)]([...i]),t.giftsAvailable=0;else for(let r of(FGSECOMAPP[x(634)]?.[x(864)]&&!C(t[x(543)])&&t[x(543)].forEach($=>{let e=x,i=FGSECOMAPP[e(462)].find(x=>x.belongs_to_offer?.[e(646)]()===t.id?.[e(646)]()&&$.variant_id===x.variantId);if(C(i))return;let r=i[e(407)]-$[e(407)];t[e(364)]+=$[e(407)],r>0?i[e(407)]=r:(i[e(407)]=0,a.push({...i}))}),i)){if(t[x(364)]>=0)break;t[x(364)]+=r[x(407)],t[x(364)]<=0?a[x(733)]({...r}):(r[x(407)]=t[x(364)],t[x(364)]=0)}a?.[x(755)]($=>{let t=x;FGSECOMAPP[t(462)]=FGSECOMAPP[t(462)]?.[t(497)](x=>$[t(791)]!==x.variantId||$[t(460)]?.[t(646)]()!==x[t(460)]?.toString())})}),t?.[e(497)]($=>{let x=e;return g($)&&($[x(407)]=FGSECOMAPP[x(462)]?.[x(497)](t=>$[x(831)]===t[x(791)])?.[x(879)](($,x)=>$+x.quantity,0)??0),$.quantity>0})??[]},V=async($,t)=>{let e=x,{arrGiftsAdd:a,arrGiftsRemove:i,arrGiftsData:r}=j($,t,!1),c=z(i,$);if(!C(i)){let o=j(c,t,!0);z(o?.[e(371)],$),a=o?.[e(482)],i=i?.[e(715)](o?.[e(371)])??[],r=o?.[e(369)]}return await m(a,i),l()[e(847)](),r},W=($,t)=>{let e=x;try{let a=[],i=t[e(513)],r=i[e(879)](($,x)=>$+x.variants[e(908)],0);if(!$.auto_add_gift||r<=0)return[];let c=t[e(622)]?.[e(387)]?.[e(562)],o=t[e(622)]?.[e(628)]??{};if(o.status&&o.type===e(822)){let s=i[0].variants[0];0===s[e(904)]&&(a.push({variant_id:s[e(522)],quantity:t.giftsAvailable,offer_id:t.id}),console[e(550)]("track variant auto add gift: {"+s[e(522)]+e(433)+s.variant_title+e(433)+t.id+"}"))}else if(c){let f=(t?.giftsAvailable??0)/r;i[e(755)]($=>$[e(445)]?.[e(755)]($=>a[e(733)]({variant_id:$[e(522)],quantity:f,offer_id:t.id}))),console[e(550)](e(795)+t.id+"}")}else if(1===r){let n=i[0].variants[0];0===n.price&&(a[e(733)]({variant_id:n[e(522)],quantity:t[e(364)],offer_id:t.id}),console[e(550)](e(286)+n[e(522)]+e(433)+n[e(735)]+"} {"+t.id+"}"))}return a}catch(l){return console[e(564)](l),[]}},X=$=>"Default Title"===$,K=$=>{let t=x;try{let e=Shopify?.[t(655)]??FGSECOMAPP[t(759)]?.gift_slider?.others?.gift_img_size??t(671),a=new URL($),i=new URLSearchParams(e);return i[t(755)](($,x)=>a.searchParams.set(x,$)),a[t(646)]()}catch(r){return $}},Q=$=>{let e=x,a=$;if(FGSECOMAPP[e(447)][e(478)]===e(283))for(let i of(a=[],$)){let r=i[e(445)];r&&r[e(908)]&&r[e(755)]($=>a[e(733)]({...i,thumbnail:$[e(815)],variants:[$]}))}let c=document[e(313)](e(420));c&&(c[e(617)]=a[e(345)]($=>{let x=e,a=$?.[x(445)][0]??{},i=X(a[x(735)]),r=$[x(445)]?.[x(908)],c=h(S($.original_product_shopify_id,$[x(242)])),o=FGSECOMAPP[x(447)]?.[x(478)]===x(283),s=document[x(499)](t.GIFT_ITEM_SECTION_ID)?.[x(617)]??t[x(766)];return s[x(464)](/{{\s*fg_product_handle\s*}}/gm,h(w($[x(355)],$[x(335)]),!0)).replaceAll(/{{\s*fg_product_img\s*}}/gm,h(K($[x(815)]),!0))[x(464)](/{{\s*fg_product_img_alt\s*}}/gm,c).replaceAll(/{{\s*fg_product_title\s*}}/gm,c)[x(464)](/{{\s*fg_gifts_check_show_by_variants\s*}}/gm,h(o&&FGSECOMAPP[x(447)].show_variant_title?"":"sca-d-none"))[x(464)](/{{\s*fg_gifts_check_show_by_products\s*}}/gm,o?x(529):"")[x(464)](/{{\s*fg_check_selected_variant\s*}}/gm,1===r?x(561)+(i?"sca-d-none":""):"")[x(464)](/{{\s*fg_variant_title\s*}}/gm,h(1!==r?b(FGSECOMAPP[x(447)].select_gift_btn??x(673),x(342)):a[x(735)]))[x(464)](/{{\s*fg_original_price\s*}}/gm,h(E(a)))[x(464)](/{{\s*fg_gift_price\s*}}/gm,h(T(a)))[x(464)](/{{\s*sca_fg_variant_select_section\s*}}/gm,h(v($.variants,$[x(815)]))).replaceAll(/{{\s*fg_product_belongs_to_offer\s*}}/gm,$[x(460)])[x(464)](/{{\s*fg_variant_id\s*}}/gm,h(1===r?a[x(522)]:""))[x(464)](/{{\s*fg_add_to_cart\s*}}/gm,h(b(FGSECOMAPP.fgAppearanceGiftSlider?.[x(854)]??x(708),"customize.add_to_cart_button")))}).join(" \n"),new Glider(document.querySelector(e(693)),{slidesToShow:1,slidesToScroll:1,draggable:!1,dots:FGSECOMAPP[e(447)][e(408)]?e(400):null,arrows:{prev:e(794),next:e(910)},responsive:[{breakpoint:1024,settings:{slidesToShow:FGSECOMAPP[e(447)][e(818)]??4,slidesToScroll:1}},{breakpoint:768,settings:{slidesToShow:3,slidesToScroll:1}},{breakpoint:576,settings:{slidesToShow:2,slidesToScroll:1}}]}),document[e(263)](new CustomEvent(FGSECOMAPP[e(612)][e(719)],{detail:{addGiftToCartFunc:FGSECOMAPP.addGiftToCart,gifts:$6(a)}})))},J=async()=>{let $=x;try{let t=window.fgData?.[$(308)]??[];for(let e in await $2(),FGSECOMAPP[$(265)])C(FGSECOMAPP[$(265)][e]?.id)&&delete FGSECOMAPP[$(265)][e];let a=[];t[$(755)](x=>{let t=$;FGSECOMAPP[t(333)]=FGSECOMAPP.gifts_id.concat(x[t(707)][t(345)]($=>$.variant_shopify_id));try{let e=JSON[t(336)](JSON[t(587)](x));if(x[t(628)][t(524)]){let i=x[t(624)][0][t(294)],r=i[0][t(426)],c=[...e[t(707)]],o=[...e[t(723)]];if(x[t(628)].type===t(822))for(let s in r){let f=r[s]?.[t(822)]??[];for(let n of f){e.offer_conditions[0][t(294)]=[{type:i[0][t(366)],value:{[s]:{...r[s],variant:[{...n}]}}}],e[t(707)]=c[t(497)]($=>$[t(355)]+""===s&&n.id===$[t(421)]),e.gift_products=o[t(497)]($=>$[t(355)]+""===s),e.gift_products[0][t(445)]=[...e[t(707)]];let l=e[t(387)].number_of_gift_can_receive,d=e[t(387)].auto_add_all_gifts;e.gift_settings.auto_add_all_gifts&&(l=e[t(707)].length),1===e[t(707)][t(908)]&&0===e.gift_items[0].price&&(d=!0),a[t(733)](JSON[t(336)](JSON[t(587)]({...e,gift_settings:{...e[t(387)],number_of_gift_can_receive:l,auto_add_all_gifts:d},id:e.id+"_"+r[s][t(463)]+"_"+n.id,offer_root:""+e.id})))}}else if(x.gift_should_the_same[t(366)]===t(602))for(let _ in r){e[t(624)][0][t(294)]=[{type:i[0][t(366)],value:{[_]:r[_]}}],e[t(707)]=c.filter($=>$[t(355)]+""===_),e[t(723)]=o.filter($=>$[t(355)]+""===_);let g=e[t(387)][t(688)],u=e[t(387)][t(562)];e[t(387)][t(562)]&&(g=e.gift_items[t(908)]),1===e[t(707)].length&&0===e.gift_items[0].price&&(u=!0),a[t(733)](JSON[t(336)](JSON[t(587)]({...e,gift_settings:{...e[t(387)],number_of_gift_can_receive:g,auto_add_all_gifts:u},id:e.id+"_"+r[_][t(463)],offer_root:""+e.id})))}}}catch(p){console[t(564)](p)}}),FGSECOMAPP[$(333)]=[...new Set(FGSECOMAPP[$(333)])],t=(t=(t=t?.[$(497)](x=>!x?.gift_should_the_same?.[$(524)])?.concat(a))?.[$(345)](x=>({...x,id:x.id.toString(),offer_root:(x.offer_root??x.id)[$(646)]()})))?.[$(497)](x=>{let t=$;if(!$e(x[t(547)],x[t(467)]))return!1;let e=!C(x.sub_conditions?.customer_order_history||x[t(687)]?.[t(776)]);if(x[t(687)]&&(!Y(x,SECOMAPP)||e&&C(SECOMAPP[t(298)][t(913)])))return!1;let a={...FGSECOMAPP[t(265)]},i=!1;if(FGSECOMAPP[t(634)][t(586)]===t(440)){x[t(707)]=x?.gift_items[t(497)]($=>{let x=t,e=a[$.original_product_shopify_id]??{},i=e?.[x(236)]??{},r=e?.variants?.[x(330)](x=>x.id===$.variant_shopify_id)??{};return i[$[x(421)]]>0||C(r[x(659)])&&r[x(470)]})??[];let r=x[t(707)]?.map($=>$[t(522)]);x.gift_products=x?.[t(723)]?.[t(497)]($=>{let x=t;return $.variants=$?.[x(445)]?.[x(497)]($=>{let t=x;return r?.[t(528)]($[t(522)])}),$?.[x(445)]?.[x(908)]>0}),i=!0}else if(FGSECOMAPP[t(634)][t(658)]){x[t(707)]=x?.[t(707)][t(497)]($=>(a[$[t(821)]]?.variants?.find(x=>x.id===$[t(522)])?.available??!1)||a[$[t(821)]]?.[t(236)]?.[$[t(522)]]>0);let c=x[t(707)]?.[t(345)]($=>$[t(522)]);x.gift_products=x?.gift_products?.filter($=>{let x=t;return $.variants=$?.[x(445)]?.[x(497)]($=>c?.[x(528)]($.variant_shopify_id)),$?.[x(445)]?.[x(908)]>0}),i=!0}return i&&x[t(387)]?.auto_add_all_gifts&&(x[t(387)].number_of_gift_can_receive=x[t(707)]?.[t(908)]),!i||x[t(707)]&&x[t(707)][t(908)]>0});let i=FGSECOMAPP?.[$(634)]?.[$(357)]==="compare_at_price"?$(503):$(633),r=FGSECOMAPP[$(634)]?.[$(864)],c=r===$(557)?$(503):"original_price";return t?.map(x=>{let t=$,e=x.gift_items[t(345)]($=>{let x=t;return $[x(904)]=O($.price),$[x(798)]=O(C($[i])?$?.[x(633)]:$[i]),r&&($.compare_gift_price=O(C($[c])?$?.[x(633)]:$[c])),$[x(355)]});return x[t(723)]=x.gift_products?.[t(497)]($=>{let x=t;return $[x(445)]?.[x(755)]($=>{let t=x;$[t(904)]=O($[t(904)]),$[t(798)]=O(C($[i])?$?.[t(633)]:$[i]),r&&($[t(468)]=O(C($[c])?$?.[t(633)]:$[c]))}),e.includes($[x(355)])}),x[t(624)]?.[t(755)]($=>{let x=t;$[x(648)]===x(827)&&($[x(454)]=O($.min_amount),$[x(465)]=C($[x(465)])?$[x(465)]:O($[x(465)]))}),x})?.sort((x,t)=>x.priority-t[$(657)])}catch(o){return console[$(564)](o),[]}},Z=async()=>{let $=x;try{let t=[];window[$(786)]?.[$(308)]?.forEach(x=>{let e=$,a=[];x[e(723)][e(755)]($=>{let x=e,t=FGSECOMAPP?.fgSettings?.[x(586)]===x(440)?$[x(335)]??null:FGSECOMAPP?.[x(634)]?.manual_input_inventory?$[x(502)]??null:null;C(t)||a[x(733)](t)}),t=[...t,...a]}),await $h(t=(t=[...new Set(t)])[$(497)](x=>C(FGSECOMAPP[$(614)][x]))),Object.values(FGSECOMAPP.productsInPage)?.[$(755)](x=>{let t=$,{info:e}=x;C(e)||C(e?.id)||(FGSECOMAPP[t(265)][e.id]={...e})})}catch(e){console.error(e)}},$$=$=>{let t=x;try{C($)?(FGSECOMAPP[t(462)]=[],localStorage[t(609)](t(890),LZString.compressToBase64(JSON[t(587)](FGSECOMAPP[t(462)])))):FGSECOMAPP[t(462)]=JSON[t(336)](LZString[t(787)](localStorage[t(344)](t(890))))}catch(e){FGSECOMAPP.arrOfferAdded=[],localStorage.setItem(t(890),LZString[t(871)](JSON[t(587)](FGSECOMAPP[t(462)])))}let a={};FGSECOMAPP.offers?.[t(755)]($=>{let x=t;a[$.id]=$?.[x(707)]?.[x(345)]($=>$[x(522)])});let i=Object.keys(a);FGSECOMAPP[t(462)]=FGSECOMAPP[t(462)]?.[t(497)]($=>i?.[t(528)]($[t(460)]?.[t(646)]())&&a[$[t(460)]?.[t(646)]()][t(528)]($[t(791)]));let r={};FGSECOMAPP.arrOfferAdded?.[t(755)]($=>{let x=t,e=r[$[x(460)]+"_"+$[x(791)]]??{};r[$[x(460)]+"_"+$[x(791)]]={...$,belongs_to_offer:$[x(460)]?.toString(),quantity:(e?.[x(407)]??0)+($?.[x(407)]??0)}}),FGSECOMAPP[t(462)]=Object[t(519)](r),localStorage[t(609)](t(890),LZString[t(871)](JSON[t(587)](FGSECOMAPP[t(462)])))},$x=()=>{let $=x;FGSECOMAPP[$(399)]={cart_drawer_query:{tool:[$(692),I("sca_fg_cart_drawer_query")]},cart_icon_query:{default:[$(616)],tool:[$(539),I("sca_fg_cart_icon_query")]},gift_icon_product_query:{default:[$(881)],integration:[".f-product-single__title, .m-product-title"],tool:[".fg-secomapp-product-title",I($(837))]},gift_icon_collection_query:{default:[$(572),$(351)],integration:[".m-product-item, .m-product-list .swiper-slide, .f-grid .f-column",$(589)],tool:[".fg-secomapp-collection-img",I("sca_fg_img_collection_gift_icon_query")]},gift_thumbnail_query:{default:[$(282)],integration:[$(620)],tool:[$(472),I($(728))]},cart_message_query:{default:["#MainContent, #mainContent, #main, .main-content"],integration:[$(322),$(834),$(382),$(665),$(647)],tool:[".fg-secomapp-cart-item-promotion",I($(405))]},checkout_btn_query:{default:["input[name='checkout'], button[name='checkout'], input[name='goto_pp'], button[name='goto_pp']",$(645),$(720),$(437)],integration:[$(498),$(252)],tool:[$(367),I($(395))]}}},$0=async $=>{let t=x;document.dispatchEvent(new CustomEvent(FGSECOMAPP[t(612)].START_RENDER_APP,{detail:{}})),$x(),A(),FGSECOMAPP[t(377)](),(FGSECOMAPP?.fgSettings?.sync_quantity===t(440)||FGSECOMAPP?.[t(634)]?.[t(658)])&&await Z(),FGSECOMAPP[t(308)]=await J(),FGSECOMAPP[t(627)](),r(),s(),$$($);let e=await V($,FGSECOMAPP.offers);await $a(e),$v(),$4(),$3(),$y(),document[t(263)](new CustomEvent(FGSECOMAPP[t(612)].END_RENDER_APP,{detail:{}}))},$t=function(){let $=x,t=document.querySelectorAll($(354)),e=document.querySelectorAll($(235)),i="sca-is-visible-fg",r=document[$(425)]($(891)),c=r[$(908)];for(let o=0;o{let t=$;x[t(599)]===document[t(499)](t(398))&&(document.querySelector(t(398)).classList[t(414)](i),a())}),document.addEventListener($(830),x=>{let t=$;"Escape"===x.key&&document[t(499)]("#freegifts-main-popup-container.sca-modal-fg.sca-is-visible-fg")&&(document[t(499)](t(398))[t(245)][t(414)](i),a())}),document[$(425)]($(383)).forEach(x=>x[$(546)]("click",function(){let x=$;this[x(588)](x(376),1),this[x(710)](),this[x(245)][x(391)]("active"),this[x(499)](".dropdown-menu").classList.toggle(x(640))})),document[$(425)]($(383)).forEach(x=>document[$(546)]($(512),function(t){let e=$,a=x[e(532)](t.target);a||(x.classList[e(414)](e(573)),x.querySelector(e(607))[e(245)][e(414)](e(640))),document[e(425)](".btn-add-to-cart.sca-fg-out-stock")[e(755)]($=>{let x=e;$[x(726)]=!0,$[x(816)][x(823)]=x(780)})})),document[$(425)]($(393))[$(755)](x=>{let t=$;x[t(546)](t(512),function(){let $=t,x=this[$(332)]("id"),e=this.getAttribute($(319)),a=this[$(332)]($(233)),i=this[$(332)]($(250)),r=this[$(332)]("data-original-id"),c=this[$(504)][$(504)][$(504)][$(504)];c[$(499)]($(736)).setAttribute($(878),e);let o=new URL(c[$(499)]($(842))[$(585)]);o[$(411)][$(861)]($(822),r),c[$(499)](".gift-original-url")[$(585)]=o.toString();let s=this[$(504)][$(504)][$(504)];s[$(499)](".original-price del")[$(690)]=i,s.querySelector($(850))[$(690)]=a;let f=s?.[$(499)](".btn-add-to-cart");f.setAttribute($(630),x),f[$(726)]=!1,f[$(816)]="";let n=this[$(504)][$(504)][$(499)]($(742));n[$(245)][$(456)]($(573)),n[$(617)]=this[$(677)]})}),document[$(425)]("#fg-gift-items .btn-add-to-cart").forEach(x=>x[$(546)]("click",async function(){let x=$,t=this[x(332)](x(630))-0,e=this[x(332)](x(485));try{await _(t,1,e);let a=document[x(499)]("#freegifts-main-popup-container.sca-modal-fg.sca-is-visible-fg");a&&(FGSECOMAPP[x(683)]=!0,await new Promise($=>setTimeout($,800)),a[x(245)].remove(i)),window[x(809)][x(585)].includes("/cart")?location[x(297)]():typeof Shopify?.[x(593)]===x(858)&&await Shopify?.getCart(0===FGSECOMAPP[x(275)][x(908)]?function(){}:FGSECOMAPP.fgCallback[0])}catch(r){console[x(564)](r)}}))},$e=($,t)=>{let e=x;if($){let a=new Date,i=a.getTime(),r=new Date($)[e(422)]();if(!t)return i>=r;{let c=new Date(t)[e(422)]();return i>=r&&i<=c}}return!1},$a=async $=>{let t=x;if($&&$.length>0)FGSECOMAPP.isDelayShowAdded?(await new Promise($=>setTimeout($,1500)),FGSECOMAPP[t(683)]=!1,y(),Q($)):(y(),Q($));else{let e=document.getElementById("freegifts-main-page-container");e&&(e.innerHTML="")}$t(),FGSECOMAPP[t(377)](),FGSECOMAPP[t(874)](FGSECOMAPP[t(308)]),$o=[]},$i=async $=>{let t=x;$o=[];let e=new URL(window[t(809)][t(585)]);e[t(411)][t(861)]("sca_fetch_cart",""),i(e[t(646)]())[t(847)]($=>$[t(631)]())[t(847)]($=>{let x=t,e=new DOMParser,a=e[x(896)]($,"text/html"),{cart_drawer_query:i,cart_icon_query:r}=FGSECOMAPP.QUERY_SELECTOR,c=[...i?.tool][x(497)](Boolean).join(","),o=[...r?.tool][x(497)](Boolean).join(","),s=[...r?.[x(310)]].filter(Boolean)[x(348)](","),f=document[x(499)](c),n=!1;f&&(n=!0,f.innerHTML=a[x(499)](c)?.innerHTML??f[x(617)]);let l=document[x(499)](o);l||(l=document.querySelector(s)),l&&(n=!0,l[x(617)]=a[x(499)](o)?.[x(617)]??a.querySelector(s)?.[x(617)]??l[x(617)]),n||console[x(550)](x(703))}),typeof FGSECOMAPP?.[t(662)]===t(858)&&await FGSECOMAPP[t(662)](),document[t(263)](new CustomEvent(FGSECOMAPP.CUSTOM_EVENTS.GIFT_UPDATED,{detail:{}})),p(t(436)),setTimeout(function(){$a($)},800)},$r=async $=>{let t=x,e=await i(t(439)+($??""),{method:"GET",headers:{Accept:t(559),"Content-Type":t(559)}})[t(847)]($=>$[t(266)]()),a=e[t(558)];return FGSECOMAPP[t(845)]=e,FGSECOMAPP[t(717)]=a?.map($=>{let x=t;return{...FGSECOMAPP[x(717)]?.[x(330)](x=>x.id===$.id),...$}})??[],e},$c=async()=>{let $=x,t=FGSECOMAPP[$(845)];try{await i(SECOMAPP.freegiftProxy,{method:"GET",headers:{"Content-Type":"application/liquid"}})[$(847)](async x=>{let e=$,a=await x.json();FGSECOMAPP[e(717)]=a?.[e(582)]?.[e(345)]($=>{let x=e;return{...FGSECOMAPP[x(717)]?.[x(330)](x=>x.id===$.id),...$[x(602)],collections:$[x(353)],tags:$[x(535)]}})??[],FGSECOMAPP[e(845)]=a?.shopify_cart??{},t=FGSECOMAPP[e(845)]})[$(457)](async x=>{let e=$;console[e(564)](e(541)+x[e(603)]),t=await $r()})}catch(e){console.error($(288),e[$(603)]),t=await $r()}return t},$o=[],$s=async $=>{let t=x;try{$o[t(733)]($[0]),document[t(263)](new CustomEvent(FGSECOMAPP[t(612)][t(580)],{detail:{events:$o}})),await $c();let e=await V(FGSECOMAPP.cartItems,FGSECOMAPP[t(308)]);FGSECOMAPP.renderPromotionMessage(FGSECOMAPP[t(308)]);let a=!1;return $[0][t(613)](t(758))&&JSON.stringify($[1].headers??[])[t(528)](t(714))?(console.log(t(249),[...$o]),await $i(e),a=!0):$[0][t(613)](t(668))&&JSON[t(587)]($[1][t(629)]??[])[t(528)]("sca_process_gifts")?(console[t(550)]("event auto process gifts with cart",[...$o]),await $i(e),a=!0):(console.log(t(592),[...$o]),await $a(e)),$5(),a&&(window[t(809)][t(585)].includes(t(290))||document.querySelector(t(855))?.getAttribute(t(538))===t(334))&&($o=[],location[t(297)]()),document[t(263)](new CustomEvent(FGSECOMAPP[t(612)][t(347)],{detail:{events:$o}})),FGSECOMAPP.cartItems}catch(i){console[t(564)](i)}},$f=()=>{let $=x;if(!Shopify?.[$(343)])return;let t=document[$(499)]($(380));if(!t)return;t[$(617)]="";let e=Shopify?.sca_text_notify_success??$(243),a=document[$(747)]("li");a[$(824)]=$(375),a.innerHTML='\n
\n \n \n \n \n \n
'+e+$(537),t[$(492)](a),a.timeoutId=setTimeout(()=>$n(a),3e3),document[$(499)]($(857))?.[$(546)]($(512),()=>$n(a))},$n=$=>{let t=x;$[t(245)][t(456)](t(556)),$.timeoutId&&clearTimeout($[t(453)]),setTimeout(()=>$[t(414)](),500)},$l=$=>{let t=x;try{let e=FGSECOMAPP[t(634)]?.[t(232)],a=e===t(237)?$[t(599)]:$[t(554)]??$[t(599)];a?.hasAttribute(t(849))||(a=document.querySelector(t(365))?.[t(674)]);let i=JSON[t(336)](a[t(332)](t(802)));if(a[t(426)]=i?.[t(426)]??"",a[t(617)]=i?.[t(617)]??"",a[t(726)]=!1,a[t(571)](t(512),$d),a.removeAttribute(t(849)),e===t(676)){a.parentNode[t(499)]("[sca_root_checkout]")[t(512)]();return}e===t(237)&&window[t(571)](t(512),$_,!0),a[t(512)]()}catch(r){window[t(809)][t(536)]((Shopify?.[t(384)]?.[t(481)]??"/")+"checkout"),console[t(564)](r.message)}};FGSECOMAPP[x(569)]=async($,t)=>{let e=x;if($===e(434)&&t)t[e(726)]=!0,t[e(588)](e(802),JSON[e(587)]({innerHTML:t[e(617)],value:t[e(426)]})),"function"==typeof FGSECOMAPP?.scaCustomLoadingCheckout?await FGSECOMAPP.scaCustomLoadingCheckout($):(t[e(426)]=Shopify?.[e(291)]??"Loading...",t[e(617)]=Shopify?.[e(679)]??'\n Loading... \n
');else if($===e(436)&&t){if(typeof FGSECOMAPP?.[e(239)]===e(858))await FGSECOMAPP[e(239)]($);else{let a=JSON[e(336)](t.getAttribute("data-fg-checkout-btn"));t.value=a?.[e(426)]??"",t[e(617)]=a?.[e(617)]??""}t.disabled=!1}else $===e(564)?(typeof FGSECOMAPP?.[e(239)]===e(858)&&await FGSECOMAPP[e(239)]($),window.location[e(536)]((Shopify?.routes?.[e(481)]??"/")+"checkout")):console[e(564)](e(299),$)};let $d=async $=>{let t=x;try{$[t(280)](),$[t(390)](),$.stopImmediatePropagation();let e=FGSECOMAPP.fgSettings?.[t(232)],a=e===t(237)?$[t(599)]:$[t(554)]??$.target,{form:r}=a;if(await FGSECOMAPP[t(569)](t(434),a),document.dispatchEvent(new CustomEvent(FGSECOMAPP.CUSTOM_EVENTS[t(231)],{detail:{}})),FGSECOMAPP[t(740)])return!1;FGSECOMAPP[t(740)]=!0;try{if(!Shopify?.disable_fetch_cart_checkout){let c=new URL(r[t(560)]);c[t(411)].append(t(694),""),await i(c.toString(),{method:"POST",body:new FormData(r)})}}catch(o){console[t(550)](t(326))}if(C(FGSECOMAPP[t(308)])&&C(FGSECOMAPP[t(717)]?.[t(330)]($=>g($))))return console[t(550)](t(521)),$l($),!1;await $c();let s=[...FGSECOMAPP.cartItems],{arrGiftsRemove:f}=j(s,FGSECOMAPP[t(308)],!1);if(await V(s,FGSECOMAPP.offers),f?.[t(908)]>0)location[t(297)]();else try{FGSECOMAPP[t(634)][t(781)]&&!C(FGSECOMAPP[t(717)]?.[t(330)]($=>g($)))?await i(SECOMAPP[t(300)]+t(801)+Shopify?.[t(900)],{method:"GET",headers:{"Content-Type":t(744)}})[t(847)](async $=>{let x=t,e=await $[x(266)](),a=[];Shopify?.add_cart_attributes&&(a=Object.entries(e.cart[0]?.[x(771)])[x(345)](([$,x])=>({key:$,value:x}))),e[x(582)]=(e[x(582)]??[])[x(345)]($=>{let t=x;$[t(602)].collections=$.collections?.[t(345)]($=>({id:$.id})),$[t(602)][t(535)]=$[t(535)];let e=Shopify?.[t(660)]?$[t(602)][t(244)]:[];return{id:$[t(602)].id,variant_id:$.product.variant_id,title:$[t(602)].title,handle:$.product.handle,price:k($[t(602)]),quantity:$[t(602)][t(407)],product_type:$.product[t(695)],vendor:$.product[t(466)],tags:$[t(602)][t(535)],collections:$[t(602)][t(353)],selling_plan_allocation:$[t(602)][t(271)],discounts:e}}),e[x(596)]={arr_offer_added:FGSECOMAPP[x(462)],secomapp:{customer:SECOMAPP?.customer??{},fg_codes:SECOMAPP?.[x(307)]??[],fgSettings:FGSECOMAPP[x(634)]},cookie_fg_code:B(x(595)),shopify_currency:Shopify?.currency,customer_location:FGSECOMAPP.customerLocation,cart_attributes:a},await i(SECOMAPP[x(300)]+"&data_checkout="+LZString[x(811)](e=JSON[x(587)](e)),{method:x(318),headers:{"Content-Type":x(744)}})[x(847)](async $=>{let t=x,e=await $[t(266)]();try{FGSECOMAPP.checkIsBlockCheckout=!1,e[t(247)]&&(window[t(809)].href=e[t(247)].invoice_url)}catch(a){console.error(a)}})}):(console.log("not using draft order"),FGSECOMAPP[t(740)]=!1,$l($))}catch(n){FGSECOMAPP[t(740)]=!1,$l(n)}await FGSECOMAPP[t(569)]("end",a=e===t(237)?$[t(599)]:$[t(554)]??$[t(599)]),document[t(263)](new CustomEvent(FGSECOMAPP.CUSTOM_EVENTS[t(749)],{detail:{status:"done"}}))}catch(l){await FGSECOMAPP[t(569)](t(564)),document[t(263)](new CustomEvent(FGSECOMAPP[t(612)].END_VALIDATE_CHECKOUT,{detail:{status:t(564)}})),console.error(l)}},$_=async $=>{let t=x;$.target?.[t(825)](t(849))&&await $d($)},$8=()=>{let $=x,t=FGSECOMAPP.fgSettings?.[$(232)],{checkout_btn_query:e}=FGSECOMAPP[$(399)],a=[...e?.[$(423)],...e?.integration,...e?.[$(310)]][$(497)](Boolean)[$(348)](",");document.querySelectorAll(a)[$(755)](x=>{let e=$,a=x[e(825)](e(865)),i=x[e(825)](e(894)),r=x[e(825)](e(849));if("clone_checkout"===t){if(a)return;if(!i&&!r){let c=x[e(471)](!0);c.addEventListener("click",$d),c[e(588)]("sca_handle_checkout",""),c[e(588)](e(894),""),x[e(816)][e(301)]=e(598),x[e(816)][e(325)]="hidden",x[e(816)][e(748)]="0",x[e(588)](e(865),""),x.parentNode?.[e(492)](c)}i&&!r&&(x.addEventListener("click",$d),x[e(588)](e(849),""))}else"trigger_body"===t?x[e(588)](e(849),""):r||(x[e(546)]("click",$d),x[e(588)]("sca_handle_checkout",""));FGSECOMAPP[e(681)]=!0}),t===$(237)&&window.addEventListener("click",$_,!0)};FGSECOMAPP[x(377)]=()=>{let $=x;FGSECOMAPP[$(257)]=0;let t=setInterval(()=>{let x=$;$8(),FGSECOMAPP.scaCountRenderEventCheckout++,(FGSECOMAPP[x(257)]>10||FGSECOMAPP[x(681)])&&(FGSECOMAPP[x(257)]=0,clearInterval(t))},400)};let $g=$=>{let t=x;try{let e={},a={},i=FGSECOMAPP[t(308)];if(C($)){$=[],C(Shopify?.[t(888)])||$[t(733)]({...Shopify?.current_product});let r={...Shopify?.[t(803)],...Shopify?.[t(903)]?.products};Object[t(519)](FGSECOMAPP[t(614)])?.[t(497)]($=>!C($[t(251)])&&(C($?.[t(526)])||$?.[t(526)]&&!$?.[t(493)]?.every($=>$?.[t(245)]?.[t(532)](t(650)))))?.[t(755)]($=>{let x=t;r[$[x(251)].id]={...$[x(251)]}}),$=$[t(715)]([...Object.values(r)])}$?.[t(755)]($=>{let x=t,e=FGSECOMAPP.productsInPage[$[x(463)]];FGSECOMAPP[x(614)][$.handle]={...e,info:{...$},product_has_icon:!!C(i)&&void 0}});let c=FGSECOMAPP[t(634)]?.[t(864)];for(let o in i?.[t(755)](x=>{let i=t,r=x[i(624)];if(1===r[i(908)]&&r[0][i(648)]===i(479)&&typeof r[0][i(511)]===i(341)){let o,s=r[0][i(294)];s?.[i(755)](x=>{let t=i;switch(x.type){case t(846):o=Object[t(519)](x[t(426)]);break;case t(509):let e=Object.keys(x[t(426)]);e.length>0&&(o=(void 0===o?$:o)?.[t(497)]($=>e[t(528)]($.type))??[]);break;case t(349):let a=Object[t(706)](x[t(426)]);a[t(908)]>0&&(o=(void 0===o?$:o)?.[t(497)]($=>a[t(528)]($[t(466)]))??[]);break;case"product_collections":let r=Object[t(706)](x.value);r[t(908)]>0&&(o=(void 0===o?$:o)?.[t(497)]($=>{let x=t,e=$.collections?.map($=>$.id+""),a=e?.[x(497)]($=>r[x(528)]($));return!C(a)})??[])}}),o?.forEach($=>{let t=i,r=$[t(463)],o=JSON[t(336)](JSON[t(587)](x.gift_products)),s=FGSECOMAPP[t(614)][r]?.[t(251)]??{};if(FGSECOMAPP.fgSettings?.[t(697)]&&(o=o.filter($=>$[t(355)]!==s?.id)),c&&(o=o.filter($=>{let x=t;return $[x(445)][x(441)]($=>$?.compare_gift_price<=s?.[x(835)]/100)}),C(o)))return;if(e[r]){let f=e[r];o?.[t(755)]($=>{let e=t,a=f[e(330)](x=>x[e(355)]===$[e(355)]);if(C(a)){f[e(733)]({...$,belongs_to_offer:[x[e(289)]]});return}let i=$[e(445)].map($=>$[e(421)]);a[e(460)]?.includes(x[e(289)])||a[e(460)]?.push(x[e(289)]),a[e(445)]=a?.[e(445)]?.[e(497)]($=>!i[e(528)]($.original_variant_shopify_id))??[],a[e(445)]=[...a[e(445)],...$.variants]}),e[r]=f}else e[r]=o?.[t(345)]($=>({...$,belongs_to_offer:[x[t(289)]]}));let n=($[t(445)]??$[t(822)])?.[t(345)]($=>$.id)??[];a[r]={},FGSECOMAPP[t(614)][r]?.[t(251)]?.[t(445)]?.[t(497)]($=>n.includes($.id))?.[t(755)]($=>{let x=t;a[r][$.id]=o[x(497)](t=>{let e=x,a=t.variants;return c&&(a=a[e(497)](x=>x?.compare_gift_price<=$[e(904)]/100)),!C(a)})})})}}),e){let s=FGSECOMAPP[t(614)][o];FGSECOMAPP.productsInPage[o]={...s,gifts_will_receive:[...e[o]],product_has_icon:!0,variants_has_gift:{...a[o]}}}return Object[t(459)](e)?.length?e:{}}catch(f){return console[t(564)](f),null}},$1=$=>{let e=x,a=FGSECOMAPP[e(507)][e(643)]??{};if(!a[e(488)]?.[e(524)])return!1;let i=document[e(499)](t[e(373)])?.[e(617)]??t[e(258)],r=$?.[e(345)]($=>i.replaceAll(/{{\s*fg_product_handle\s*}}/gm,h(w($[e(355)],$[e(335)]),!0))[e(464)](/{{\s*fg_product_img\s*}}/gm,h(K($[e(815)]),!0)).replaceAll(/{{\s*fg_product_img_alt\s*}}/gm,h(S($[e(355)],$[e(242)]))))[e(348)](""),c=document[e(499)](t.GIFT_THUMBNAIL_SECTION_ID)?.[e(617)]??t[e(829)],o=c.replaceAll(/{{\s*fg_gift_thumbnail_title\s*}}/gm,h(b(a[e(488)]?.[e(242)]??"Free Gift",e(415)))).replaceAll(/{{\s*sca_fg_gift_thumbnail_items_section\s*}}/gm,r)[e(464)](/{{\s*fg_check_show_narrow\s*}}/gm,$?.[e(908)]>=4?"":e(529)),{gift_thumbnail_query:s}=FGSECOMAPP[e(399)]??{},f=[...s?.[e(423)]].filter(Boolean)[e(348)](","),n=[...s?.[e(889)],...s?.[e(310)]][e(497)](Boolean)[e(348)](","),l=document[e(499)](f)??document[e(499)](n);if(!l)return;l.parentNode[e(816)][e(682)]=e(360),l.parentNode[e(816)][e(774)]=e(912),l[e(674)]?.[e(824)]?.[e(528)](e(906))||l[e(674)]?.classList?.[e(456)](e(906));let d=l[e(674)].querySelector(e(639));if(d)d[e(617)]=o;else{(d=document[e(747)](e(684)))[e(588)]("id",e(396));let _=new DOMParser()[e(896)](o,e(549));d[e(617)]=_[e(540)][e(617)],l[e(674)][e(416)](d,l)}l.parentNode[e(416)](d,l);let g=document[e(499)](e(321));if(g)switch(a[e(488)]?.[e(443)]){case"32":g.style[e(775)]="50%";break;case"50":g[e(816)][e(775)]=e(359);break;case e(746):g[e(816)][e(775)]=e(449);break;case e(689):g[e(816)][e(775)]=e(392);break;case e(784):g.style[e(775)]="100%";break;default:g.style[e(775)]="60%"}if($?.[e(908)]>=(Shopify?.[e(778)]??4))new Glider(document[e(499)](e(292)),{slidesToShow:(Shopify?.number_gifts_thumbnail??4)-1,slidesToScroll:1,draggable:!0,dots:".dots-thumbnail",arrows:{prev:e(304),next:"#fg-gift-thumbnail-title .glider-next"}});else{g&&(g[e(816)][e(775)]="100%");let u=document.querySelector(".sca-list-gift-thumbnail");u&&(u.style.display=e(583))}return $},$u=()=>{let $=x;if(!(FGSECOMAPP.fgAppearanceGiftIcon[$(643)]??{})[$(402)]?.[$(524)])return!1;let e=document[$(499)](t.GIFT_ICON_SECTION_ID)?.[$(617)]??t[$(412)],a=e[$(464)](/{{\s*fg_gift_icon\s*}}/gm,FGSECOMAPP[$(507)][$(796)])[$(464)](/{{\s*fg_gift_icon_alt\s*}}/gm,$(610))[$(464)](/{{\s*fg_class_product_or_collection_page\s*}}/gm,"sca-gift-icon-img"),{gift_icon_product_query:i}=FGSECOMAPP[$(399)],r=[...i?.[$(423)]][$(497)](Boolean)[$(348)](","),c=[...i?.[$(310)],...i?.integration][$(497)](Boolean).join(","),o=document.querySelector(r)??document.querySelector(c);if(!o)return;o[$(816)].position=$(611),o[$(816)][$(682)]=$(763),o[$(824)]?.[$(528)]("sca-fg-form-icon-product-page")||o.classList?.add("sca-fg-form-icon-product-page");let s=o.querySelector($(790));if(s)s.innerHTML=a;else{(s=document[$(747)]($(684))).setAttribute("id",$(804));let f=new DOMParser()[$(896)](a,$(549));s.innerHTML=f[$(540)].innerHTML,o[$(492)](s)}return FGSECOMAPP.fgAppearanceGiftIcon[$(796)]},$p=()=>{let $=x,t=[],{gift_icon_collection_query:e}=FGSECOMAPP[$(399)],a=[...e?.[$(423)],...e?.[$(889)],...e?.[$(310)]][$(497)](Boolean)[$(348)](",");return document[$(425)](a)[$(755)](x=>{let e=$,a=x[e(499)](e(570)),i=a?.getAttribute("href")?.[e(246)]("/")??[],r=i?.indexOf("products"),c=r>=0?i[r+1]??null:null;if(c=c?.[e(246)]("?")?.[e(476)](),g(c)){x[e(414)]();return}let o=x[e(499)](e(826));if(o){x[e(414)]();return}if(C(c))return;let s=decodeURI(c);C(FGSECOMAPP[e(614)][s]?.[e(251)])&&t[e(733)](s);let f=(FGSECOMAPP[e(614)][s]?.positions??[]).filter($=>!x.isSameNode($));f[e(733)](x),FGSECOMAPP[e(614)][s]={...FGSECOMAPP[e(614)][s],positions:[...f]}}),t},$m=$=>{let e=x;Object[e(706)]($)?.[e(755)]($=>{let x=e,a=FGSECOMAPP[x(614)][$]?.positions??[];if(C(a)||!Array.isArray(a))return;if(!(FGSECOMAPP[x(507)][x(284)]??{})[x(524)])return;let i=document[x(499)](t.GIFT_ICON_SECTION_ID)?.innerHTML??t[x(412)],r=i.replaceAll(/{{\s*fg_gift_icon\s*}}/gm,FGSECOMAPP[x(507)][x(796)])[x(464)](/{{\s*fg_gift_icon_alt\s*}}/gm,x(610))[x(464)](/{{\s*fg_class_product_or_collection_page\s*}}/gm,"sca-gift-icon-collection-img");a.forEach($=>{let t=x;$[t(816)][t(661)]=t(611),$[t(824)]?.[t(528)](t(274))||$[t(245)]?.add(t(274));let e=$[t(499)](".sca-gift-icon-collection-page");if(e)e.innerHTML=r;else{(e=document[t(747)]("div"))[t(588)]("class","sca-gift-icon-collection-page");let a=new DOMParser()[t(896)](r,"text/html");e[t(617)]=a[t(540)][t(617)],$.appendChild(e)}})})},$b=async $=>{let t=x;await i(SECOMAPP.freegiftProxy+t(793)+LZString[t(811)](JSON[t(587)]($)),{method:t(318),headers:{"Content-Type":"application/liquid"}})[t(847)](async $=>{let x=t,e=await $.json(),a=[];e?.[x(327)]?.[x(755)]($=>{let t=x;C($?.[t(327)]?.id)||a[t(733)]({...$.products,collections:$[t(353)],variants_quantity:$.variants_quantity})});let i=$g(a);$m(i)})[t(457)]($=>{console.error($)})},$h=async $=>{let t=x,e=[];for(let[a,i]of $[t(459)]())C(FGSECOMAPP[t(614)][i]?.info)&&e[t(733)](i),20===e[t(908)]&&(await $b([...e]),e=[]),a===$[t(908)]-1&&e.length>0&&(await $b([...e]),e=[])},$y=()=>{let $=$p(),t=$g();$m(t),$h($)[x(847)]()},$4=()=>{let $=x;Shopify?.[$(378)]&&document[$(546)]($(487),function(){let x=$,t=new URL(document.URL),e=parseInt(t.searchParams[x(431)](x(822)));$3(isNaN(e)?void 0:e)})},$3=$=>{let t=x;if(!location[t(585)][t(528)](t(806)))return;document[t(499)]("#sca-gift-icon")?.[t(414)](),document[t(499)](t(639))?.[t(414)]();let e=$g();if(C(e))return;let a=location[t(575)][t(246)]("/"),i=a?.indexOf(t(327)),r=decodeURI(i>=0?a[i+1]??null:null);if(!Object.keys(e)?.[t(528)](r))return;let c=e[r],o=FGSECOMAPP[t(614)][r]?.[t(770)]??{},s=Object[t(706)](o),f=!0;Shopify?.enable_check_variants_has_gift&&(C($)||s[t(528)](""+$)||(f=!1),!C($)||C(Shopify?.[t(888)]?.[t(424)])||s.includes(Shopify?.[t(888)]?.current_variant?.id?.[t(646)]())||(f=!1),c=o[$??Shopify?.current_product?.[t(424)]?.id]??[]),document[t(263)](new CustomEvent(FGSECOMAPP[t(612)][t(870)],{detail:{icon:FGSECOMAPP.fgAppearanceGiftIcon.gift_icon_path,gifts:$6(c),product:{handle:r,variant:$??Shopify?.[t(888)]?.[t(424)]?.id}}})),f&&($1(c),$u(c))};FGSECOMAPP[x(874)]=$=>{let e=x;try{if(!FGSECOMAPP[e(905)][e(272)])return;C($)&&($=[...FGSECOMAPP[e(308)]]);let a=location.href[e(528)](e(290)),i=[];if($?.[e(755)]($=>{let x=e;$[x(600)]||C($[x(788)])||!C(FGSECOMAPP.maxOfferPriority)&&!$[x(600)]&&$[x(657)]>FGSECOMAPP[x(444)]||C(($[x(597)]??0)+($[x(451)]??0))&&/({{sca_min_total}})|({{sca_min_quantity}})/gm[x(836)]($[x(788)])||i[x(733)]({value:b($.promotion_message,x(491)+$[x(289)])[x(464)](x(260),$[x(597)]?.[x(664)](Shopify?.[x(337)]??2))[x(464)](x(381),$[x(451)]),offer_root:$[x(289)]})}),document[e(263)](new CustomEvent(FGSECOMAPP[e(612)][e(276)],{detail:{data:i}})),C(i)){document[e(425)](".sca-promotion-message-layout").forEach($=>$[e(617)]="");return}let r=document[e(499)](t.CART_MSG_ITEM_SECTION_ID)?.[e(617)]??t.CART_MSG_ITEM_SECTION,c=i[e(345)]($=>r[e(464)](/{{\s*fg_cart_message\s*}}/gm,h($[e(426)])))[e(348)](""),o=document[e(499)](t.CART_MSG_SECTION_ID)?.[e(617)]??t[e(576)],s=o[e(464)](/{{\s*sca_fg_cart_message_items_section\s*}}/gm,c),{cart_message_query:f}=FGSECOMAPP.QUERY_SELECTOR,n=document[e(499)]([...f?.[e(310)]][e(497)](Boolean).join(",")),l=document.querySelectorAll([...f?.tool,...f?.[e(889)]].filter(Boolean).join(",")),d=document[e(425)](e(386));C(d)||d[e(755)]($=>$[e(617)]=s),(d=document[e(747)](e(684)))[e(588)]("id","sca-promotion-message-layout"),d[e(245)][e(456)](e(368));let _=new DOMParser()[e(896)](s,e(549));d[e(617)]=_[e(540)][e(617)],C(l)||l?.[e(755)]($=>{let x=e;if($.querySelector(".sca-promotion-message-layout"))return;let t=d[x(471)](!0);$[x(691)](t)}),!n?.[e(499)](e(386))&&(_=new DOMParser().parseFromString(s,"text/html"),d[e(617)]=_[e(540)][e(617)],n&&a&&n.prepend(d));try{document[e(425)](e(312))[e(755)]($=>{let x=new Glider($);(($,x)=>{let t=_0x2f7f,e=$[t(255)][t(738)],a=null,i=1;function r(){a=setTimeout(()=>{i>=e&&(i=0),$.scrollItem(i++)},x)}$[t(753)][t(546)](t(293),function(){window[t(838)](a),r()}),r()})(x,Shopify?.[e(401)]??3e3)})}catch(g){console[e(564)](g)}}catch(u){console.error(u)}};let $2=async()=>{let $=x;try{let t=await i($(320)),e=await t[$(266)]();FGSECOMAPP[$(873)]=e?.[$(500)]}catch(a){console[$(550)]($(363))}},$6=($,t)=>{let e=x;return $?.[e(345)]($=>{let x=e;return{id:$.product_shopify_id,title:S($.original_product_shopify_id,$[x(242)]),handle:$[x(335)],thumbnail:$.thumbnail,belongs_to_offer:$.belongs_to_offer??""+t,variants:$[x(445)][x(345)]($=>{let t=x;return{id:$[t(522)],title:$[t(735)],price:$.price,original_price:$[t(798)],thumbnail:$[t(815)],discount_type:$[t(352)],discount_value:$.discount_value}})}})??[]},$v=()=>{let $=x;if(!FGSECOMAPP[$(882)]?.widget_info?.show_widget||!FGSECOMAPP[$(308)][$(908)])return;let e=document[$(499)]($(404)),a=document[$(499)]($(458));if(!e||!a)return;let i=document[$(499)](t[$(727)])?.[$(617)]??t[$(702)],r=document.querySelector(t.TODAY_OFFER_ITEM_SECTION_ID)?.innerHTML??t[$(652)],c=document.querySelector(t[$(779)])?.[$(617)]??t[$(259)],o={};FGSECOMAPP[$(308)][$(755)]($=>{o[$.offer_root]=$});let s=Object[$(519)](o);s.sort((x,t)=>{let e=$;return new Date(x[e(547)])-new Date(t[e(547)])}),e[$(617)]=c[$(464)](/{{\s*sca_fg_today_offer_widget\s*}}/gm,h(FGSECOMAPP[$(882)].widget_icon_path))[$(464)](/{{\s*sca-fg-title-icon-widget-content\s*}}/gm,h(b(FGSECOMAPP?.fgAppearanceTodayOffer?.[$(725)]?.[$(494)]??$(427),$(483)))),FGSECOMAPP[$(882)]?.[$(725)]?.widget_icon_style===$(403)&&(e[$(245)].add($(897)),document[$(499)]("#sca-fg-today-offer-widget .sca-fg-count-offers")[$(816)].right=$(868)),FGSECOMAPP[$(882)]?.[$(725)]?.widget_icon_style!==$(731)&&FGSECOMAPP[$(882)]?.[$(725)]?.widget_icon_style||(e[$(245)][$(414)]($(897)),document[$(499)]("#sca-fg-today-offer-widget .sca-fg-title-icon-widget")?.classList[$(456)]($(767))),"bottom_left"===FGSECOMAPP[$(882)]?.widget_info[$(340)]&&(e[$(245)][$(456)]($(469)),a[$(245)][$(456)]("sca-today-offer-left")),FGSECOMAPP[$(882)]?.[$(725)][$(340)]===$(618)&&(e.classList.add($(474)),a[$(245)][$(456)]($(762))),a.innerHTML=i.replaceAll(/{{\s*sca_fg_today_offer_title\s*}}/gm,h(b(FGSECOMAPP[$(882)][$(725)][$(700)]??$(552),"customize.widget_title")))[$(464)](/{{\s*sca_fg_today_offer_subtitle\s*}}/gm,h(b(FGSECOMAPP[$(882)][$(725)][$(909)]??$(317),"customize.widget_subtitle"))),document.querySelector($(605)).innerHTML=s[$(345)](x=>r[$(464)](/{{\s*sca_fg_offer_id\s*}}/gm,h(x[$(289)]))[$(464)](/{{\s*sca_fg_offer_title\s*}}/gm,h(b(x[$(653)],$(853)+x.offer_root)))[$(464)](/{{\s*sca_fg_offer_title_tooltip\s*}}/gm,h(b(x[$(653)],$(853)+x.offer_root)))[$(464)](/{{\s*sca_fg_offer_img\s*}}/gm,h(x[$(723)][0].thumbnail,!0)))[$(348)]("\n"),document.querySelector($(544))[$(617)]=s.length[$(646)]();let f=()=>{let x=$,t=document[x(499)](x(458));t?.[x(245)][x(391)](x(270));let e=document.querySelectorAll(x(721));e[x(755)]($=>{let t=x;$.classList[t(391)](t(767))})};document[$(499)](".sca-fg-close-today-offer")[$(546)]($(512),f),document.querySelector("#sca-fg-today-offer-widget")[$(546)]($(512),f),document[$(263)](new CustomEvent(FGSECOMAPP[$(612)].RENDER_TODAY_OFFER,{detail:{todayOffers:s[$(345)](x=>{let t=$,e=fgData.offers[t(330)]($=>$.id.toString()===x[t(289)]);return{id:""+e.id,title:b(x[t(653)],t(853)+x[t(289)]),gifts:$6(e[t(723)],e.id),success:x[t(600)]??!1}})}})),$5();let n=(x,t,e)=>{let a=$,i=document[a(747)]("p");i.className="sca-fg-tooltip",i[a(690)]=x,document[a(540)][a(492)](i),i[a(816)][a(323)]=e+"px",i[a(816)][a(515)]=t+"px",i[a(816)][a(301)]=a(704)},l=()=>{let x=$,t=document[x(499)](x(817));t&&t[x(674)].removeChild(t)},d=x=>{let t=$,e=document[t(499)](t(817));e&&(e[t(816)][t(323)]=x.pageY+"px",e.style[t(515)]=x[t(490)]+5+"px")},_=document.querySelectorAll(".sca-offer-title");_[$(755)](function(x){let t=$;x.addEventListener("mouseenter",function($){let t=_0x2f7f,e=x.getAttribute(t(578));n(e,$[t(490)]+5,$[t(852)]+5)}),x[t(546)](t(730),function(){l()}),x[t(546)](t(869),d)})},$5=()=>{let $=x,t=[...new Set(FGSECOMAPP[$(308)]?.[$(497)](x=>x[$(600)])?.map($=>$.offer_root))];document[$(263)](new CustomEvent(FGSECOMAPP.CUSTOM_EVENTS[$(508)],{detail:{idOffersSuccess:t}}));let e=document[$(425)]($(514));e[$(755)](x=>{let e=$;t.includes(x[e(332)](e(269)))?x[e(245)][e(456)]("sca-offer-archived"):x[e(245)].remove(e(604))})},$7=function(){let $=x;try{document.addEventListener(FGSECOMAPP[$(612)][$(314)],async()=>{let x=$;try{window.unicart&&(unicart.dispatchEvent("Show"),console[x(550)](x(495)))}catch(t){console.error(x(495),t)}try{window[x(248)]&&(await window[x(248)](),console[x(550)]("iCart"))}catch(e){console[x(564)](x(473),e)}try{window[x(489)]?.[x(406)]?.[x(563)]&&window[x(489)][x(406)][x(563)]()}catch(a){console.error(x(489),a)}try{window[x(548)]&&(await $r(x(533)).then($=>{let t=x;window[t(548)]($),window[t(872)]()}),console[x(550)]("SLIDECART - HQ"))}catch(i){console[x(564)](x(542),i)}try{let r=document[x(499)](x(553));window[x(843)]&&(await window[x(843)](),console[x(550)](x(429)),r&&(r[x(617)]=FGSECOMAPP?.[x(845)]?.item_count??0))}catch(c){console[x(564)](x(429),c)}try{window[x(656)]&&(await window[x(656)](),window[x(477)](),console[x(550)](x(372)))}catch(o){console[x(564)](x(372),o)}try{window?.[x(756)]?.[x(885)]?.CartSlider?.[x(608)]&&(await window.SATCB.Widgets[x(581)][x(608)](),console.log(x(240)))}catch(s){console[x(564)](x(240),s)}try{window[x(752)]&&(await window[x(752)](),window.openCart(),console.log(x(729)))}catch(f){console[x(564)](x(729),f)}try{window[x(545)]&&await (window[x(545)](),window.HS_SLIDE_CART_OPEN(),console[x(550)](x(751)))}catch(n){console.error(x(729),n)}try{let l=document[x(499)]("m-cart-drawer"),d=document[x(499)](x(785));window[x(863)]&&l&&(await l?.onCartDrawerUpdate(!window[x(295)]?.[x(907)]),l?.open()),window[x(520)]&&d&&(await d?.[x(867)](),d?.cartDrawer?.[x(591)]())}catch(_){console[x(564)](x(851),_)}try{window.CartJS&&await (CartJS?.[x(593)](),console[x(550)](x(370)))}catch(g){console.error(x(370),g)}try{window[x(772)]?.[x(406)]?.[x(264)]&&await (T4SThemeSP[x(406)][x(264)](),console.log(x(772)))}catch(u){console[x(564)](x(772),u)}}),window.addEventListener($(820),function(){let x=$;FGSECOMAPP[x(874)](),FGSECOMAPP[x(377)]()}),document[$(546)]($(296),()=>{let x=$;FGSECOMAPP[x(874)](),FGSECOMAPP[x(377)]()}),window[$(527)]=function(){let x=$;FGSECOMAPP[x(874)](),FGSECOMAPP[x(377)]()},window[$(577)]=()=>{let x=$;FGSECOMAPP[x(874)](),FGSECOMAPP[x(377)]()},window[$(807)]?.[$(413)]&&window[$(807)].subscribe(window.MinimogTheme?.[$(574)]?.openCartDrawer??"open-cart-drawer",function(){let x=$;FGSECOMAPP[x(874)](),FGSECOMAPP[x(377)]()}),document[$(546)](FGSECOMAPP.CUSTOM_EVENTS[$(719)],()=>{let x=$;try{typeof window.HS_SLIDE_CART_CLOSE===x(858)&&window[x(764)](),typeof window[x(632)]===x(858)&&window.closeCart(),typeof window[x(374)]===x(858)&&window.SLIDECART_CLOSE(),document[x(499)](".satcb-cs-close")?.[x(512)]()}catch(t){console[x(564)](t)}}),document[$(546)](FGSECOMAPP[$(612)][$(409)],x=>{let t=$;try{!Shopify?.disabled_integration_Rebuy&&window[t(489)]?.[t(406)]?.[t(563)]&&window[t(489)][t(406)].fetchCart(),x.detail[t(680)]?.[0]?.[t(528)](t(675))&&!document[t(499)](t(765))&&window[t(843)]&&window[t(843)]()}catch(e){console[t(564)](e)}})}catch(t){console[$(564)](t)}};$0(FGSECOMAPP[x(717)])[x(847)](()=>{$7()})}();