window.fgData={"offers":[],"settings":{"gift_format":"same_as_original_products","auto_add_gift":true,"sync_quantity":false,"cal_gift_discount":"current_price","using_draft_order":false,"select_one_gift_price":false,"manual_input_inventory":false,"compare_gift_price_with_product":false,"delete_gift_after_turn_off_offer":true,"not_show_gift_if_already_on_cart":false},"appearance":{"gift_slider":{"general":{"gift_popup_title":"Select your free gift!","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_variants","number_product_slider":3},"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":"#7367f0"},"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":true,"size":"50"},"gift_thumbnail":{"status":true,"size":"100","title":"Free Gift"}},"collection_page":{"status":true,"size":"50"}},"promotion_message":{"show_on_cart_page":true,"text_color":"#ffffff","background_color":"#F72119"}}};/* END_FG_DATA */ const _0x232bc1=_0x3133;function _0x3133($,x){let t=_0x3dcd();return(_0x3133=function($,x){return t[$-=153]})($,x)}function _0x3dcd(){let $=["formatter","parentNode","\n ","money","appendChild","product_type","-sca_clone_freegift","fit-content","total_spend_on_order_history","hasDoneProcessCheckout","removeItem","innerHTML","#fg-gift-thumbnail-title","sca_add_url","sca-is-visible-fg","prepend","not_show_gift_if_already_on_cart",'\n \n
\n
\n\n
\n
\n \n
\n
\n \n
\n
\n
\n ',"others","type","50%","specific_link_address",".btn-add-to-cart.sca-fg-out-stock",".gift-price","giftsAvailable","setAttribute","renderPromotionMessage","GET","stringify",'\n ","icartUpdateCartEvent","&width=480&height=480","FGSECOMAPP_HIDDEN_GIFT_POPUP","arrOfferAdded","condition_result","secomappGetCartRunning","variantId",'\n \n \n
\n \n
\n \n
\n ',"/cart/update","fgCallback","gift_products","\n ","freegiftProxy","error",'" target="_blank">\n \n
\n
\n ',"hidden","final_price","join","value","icartAddToCartEvent","redirected","function",'\n \n ',"min_amount","show_variant_title","max","end","className","type_customer_tags","Default Title","show_pagination","parentElement","giftsAdded","hasOwnProperty","replace","sca-gift-icon","\n ","getCart","variants_quantity","sca_fg_form_checkbox_button_query","sca_fg_main_promotion_message_query","set","do_not_add_freegift_attribute","compare_at_price",'\n
\n \n \n \n \n \n ',"getTime",'
\n ',"Loading...","concat",".gift-original-url","some","https://geoip.secomtech.com/?json","format","stopImmediatePropagation","value_customer_locations","dataset","currentTarget","#freegifts-main-popup-container [data-close]","appearance","prepareDataForDisplayWidgetByRule","en-US","startsWith","isUpdateCart","sca-fg-form-icon-product-page","div","6px 0","customGiftImgSize","/cart/add","#82868b","\n
\n ","style","arrGiftsAdd","handle","Free Gift","product_id",'\n \n \n \n \n \n ',"#7367f0","display","sca_root_checkout","country_code","split","gift_should_the_same","data-template","URL","add_to_cart_btn_color","[data-open]","scaCountRenderEventCheckout","variants_has_gift","cookie","&sca_shop_name=","Add gift to cart successfully!","sca_fg_title_product_gift_icon_query","childElementCount","json","5420552pWmibO","classList",'\n
\n
\n ',"visibility","getItem","relative","100","currency",'\n
\n
\n
\n \n ',"keys","Update cart.attributes ",'\n ","variants_ids","#fg-gift-items .dropdown > .dropdown-menu > li",'\n
\n
\n
\n {let $=_0x232bc1,x=FGSECOMAPP.fgAppearance?.[$(618)],t=x?.[$(512)]?.[$(625)],e=!h(x)&&void 0!==t&&!t;return e?$(343):""},t=()=>{let $=_0x232bc1,x=FGSECOMAPP[$(242)]?.gift_slider,t=x?.disable_slider_checkbox??{};return document[$(617)]($(635))?.checked&&localStorage.setItem($(544),""+Date[$(187)]()),t?.[$(164)]?'\n
\n \n \n
\n ":""},{fetch:e}=window,a=()=>{let $=_0x232bc1;document[$(617)]($(303))?.getAttribute("data-template")!==$(640)&&(window[$(183)]=async(...x)=>{let t=$;try{if(x[0].includes(t(388))){i(x[1]);let a=200,r=await e(...x)[t(622)]($=>{let x=t;return(a=$[x(275)],$[x(341)])?$:$[x(414)]()})[t(486)]($=>{console.error($)});if(x[1].headers?.sca_add_gift&&200!==a){let c=JSON[t(478)](x[1].body)?.id,n=document[t(617)](t(648)+c+'"]');return n[t(537)]="Out of stock",n[t(416)][t(524)](t(616))||n[t(416)][t(204)](t(616)),n[t(637)]=!0,n.style[t(593)]=t(389),document[t(594)](t(619))[t(325)]($=>{let x=t;parseInt($[x(287)]("data-variant"))===c||$[x(416)][x(524)](x(616))||($[x(637)]=!1,$[x(391)][x(593)]=FGSECOMAPP[x(242)]?.[x(618)]?.[x(197)]?.[x(405)]??x(397))}),!1}return await $$([t(388),...x[t(277)](1)]),await _(x,r),new Response(JSON[t(522)](r))}if(!(x[0][t(231)](t(425))||x[0][t(231)](t(315))))return setTimeout(function(){$d()},1e3),await e(...x);{i(x[1]);let o=200,s=await e(...x)[t(622)]($=>{let x=t;return(o=$.status,$[x(341)])?$:$.json()})[t(486)]($=>{console.error($)});if(x[1][t(588)]?.[t(260)]&&200!==o)return!1;if(await $$([x[0][t(231)](t(425))?t(425):t(315),...x.slice(1)]),x[1]?.[t(588)]?.[t(260)])return new Response(JSON.stringify(s));let l=FGSECOMAPP.SHOPIFY_CART??s??{};return await _(x,s,l),new Response(JSON.stringify(l))}}catch(d){return await e(...x)}})};FGSECOMAPP[_0x232bc1(330)]=()=>{let $=_0x232bc1;try{if(Shopify?.[$(177)]||typeof Shopify?.getCart!==$(342))return;Shopify[$(358)]=async function(x){let t=$;if(!FGSECOMAPP[t(547)]){FGSECOMAPP[t(547)]=!0,await $$(t(434));let e=await J(t(276));typeof x===t(342)&&(0>FGSECOMAPP[t(316)].indexOf(x)&&FGSECOMAPP[t(316)][t(179)](x),x(e)),FGSECOMAPP[t(547)]=!1}FGSECOMAPP[t(609)]()},typeof ShopifyAPI!==$(310)&&typeof ShopifyAPI.getCart!==$(310)&&(ShopifyAPI.getCart=Shopify?.getCart),void 0!==Shopify?.[$(464)]&&typeof Shopify?.api[$(358)]!==$(310)&&(Shopify.api[$(358)]=Shopify?.[$(358)])}catch(x){console[$(320)](x)}};let i=$=>{let x=_0x232bc1;try{let t=$?.[x(469)];t instanceof FormData?FGSECOMAPP[x(282)]={sections:t[x(574)]("sections"),sections_url:t[x(574)](x(448))}:typeof t===x(202)&&(t=JSON[x(478)](t),FGSECOMAPP[x(282)]={sections:t?.[x(482)],sections_url:t?.[x(448)]})}catch(e){FGSECOMAPP.sections_cart={}}},r=async()=>{let $=_0x232bc1;if(Shopify[$(363)])return;let x={freegift_attributes:""};if(!h(FGSECOMAPP[$(545)])){let t=[$(211)];for(let a of FGSECOMAPP[$(545)]){let i=FGSECOMAPP[$(578)][$(201)](x=>x.id===a[$(566)])?.[$(595)]?.[$(515)];h(i)||t[$(179)](i)}x={freegift_attributes:t[$(304)]()}}try{await e($(589),{method:"POST",headers:{"X-Requested-With":"XMLHttpRequest","Content-Type":$(251)},body:JSON[$(522)]({attributes:x})})}catch(r){console[$(320)]($(455)+r.message)}},_=async($,x,t)=>{let a=_0x232bc1;try{if($[1]?.[a(588)]?.sca_process_gifts)return;let i={},r=Object.keys(x[a(482)]??{})?.[a(219)]($=>h(FGSECOMAPP[a(282)][$]))??[];if(r&&r[a(643)]&&FGSECOMAPP.isUpdateCart&&(i=await e(a(255)+r[a(338)](","))[a(622)]($=>$.json())),FGSECOMAPP[a(383)]=!1,i={...FGSECOMAPP[a(282)],...i},h(i))return;x[a(482)]={...x[a(482)],...i},h(t)||(t[a(482)]={...x[a(482)]})}catch(_){}},c=async($,x,t)=>{let e=_0x232bc1;t=t?.[e(304)]();let a=document[e(594)]("#fg-gift-items .btn-add-to-cart");a[e(325)](x=>{let t=e;x[t(637)]=!0;let a=x[t(287)]("data-variant")-0;a===$&&(x[t(391)].padding="6px 0",x.innerHTML=t(396)),x[t(391)].backgroundColor=t(389)});let i=FGSECOMAPP[e(545)][e(201)](x=>t===x[e(566)]?.[e(304)]()&&$===x.variantId);i?i[e(600)]+=x:FGSECOMAPP[e(545)][e(528)]({variantId:$,belongs_to_offer:t,quantity:x}),localStorage[e(289)](e(161),LZString[e(312)](JSON.stringify(FGSECOMAPP[e(545)])));let r=await fetch((Shopify?.[e(507)]??"/cart/add.js")+"?sca_add_gift",{method:e(610),headers:{Accept:e(433),"Content-Type":e(433),sca_add_gift:!0},body:JSON[e(522)]({quantity:x,id:$})}),_=await r.json();if(r.ok)return a.forEach(x=>{let t=e;x[t(637)]=!0;let a=x[t(287)](t(263))-0;a===$&&(x.style[t(540)]=t(386),x.innerHTML='\n \n \n \n '),x[t(391)].backgroundColor=""}),$x(),_},n=$=>{let x=_0x232bc1,t=x(500);return!h($)&&(typeof $===x(530)&&($[x(393)]?.[x(231)](t)||$.tags?.includes(x(591)))||"string"==typeof $&&$[x(231)](t))},o=$=>{let{selling_plan_allocation:x}=$;return!h(x)&&!h(x?.selling_plan)},s=async($,x)=>{let t=_0x232bc1;try{if(h($)&&h(x))return;let e={};if(FGSECOMAPP[t(440)]?.[t(219)]($=>n($))?.[t(325)]($=>{let x=t;e[$[x(533)]]=$.quantity}),($=$?.[t(219)]($=>!h($[t(533)])))?.[t(325)]($=>{let x=t;e[$.variant_id]=(e[$.variant_id]??0)+($[x(600)]??1)}),Object[t(454)](e)?.[t(325)]($=>{e[$]=e[$]>=0?e[$]:0}),h(Object.keys(e)))return;$?.[t(325)]($=>{let x=t,e=FGSECOMAPP.arrOfferAdded.find(t=>$.offer_id?.[x(304)]()===t[x(566)]?.[x(304)]()&&$[x(533)]===t[x(548)]);e?e.quantity+=$.quantity:FGSECOMAPP[x(545)][x(528)]({variantId:$[x(533)],belongs_to_offer:$[x(224)]?.[x(304)](),quantity:$[x(600)]})}),localStorage.setItem("sca_offers_added",LZString[t(312)](JSON[t(522)](FGSECOMAPP.arrOfferAdded))),FGSECOMAPP[t(383)]=!0,await fetch((Shopify?.[t(168)]??"/cart/update")+"?sca_process_gifts",{method:t(610),headers:{Accept:t(433),"Content-Type":t(433),sca_process_gifts:!0},body:JSON.stringify({updates:e,...FGSECOMAPP.sections_cart})})[t(622)](e=>{let a=t;return e.ok&&$[a(643)]&&!x[a(643)]&&$x(),e[a(414)]()})[t(622)]($=>{let x=t;FGSECOMAPP[x(282)]=$.sections}),document[t(617)](t(303))?.[t(287)](t(403))===t(640)&&location.reload()}catch(a){console[t(320)](a)}},l=0,d=()=>{let $=_0x232bc1,e=document[$(457)]($(288));if(e)e[$(505)]=$(417)+(FGSECOMAPP[$(278)][$(645)]??"Select your free gift!")+$(511)+x()+$(173);else{let a=localStorage[$(419)]($(544))-0,i=FGSECOMAPP[$(242)]?.[$(618)]?.disable_slider_checkbox??{},r=(i?.[$(583)]??0)*6e4,_=!isNaN(a)&&a+r>Date.now();if(_||(localStorage[$(504)]("FGSECOMAPP_HIDDEN_GIFT_POPUP"),!(e=document[$(457)]("freegifts-main-popup-container"))))return;e[$(505)]='
\n \n
\n '+(FGSECOMAPP[$(278)][$(645)]??$(623))+$(314)+t()+$(357)+x()+$(318),e[$(416)][$(204)]($(508)),l++}},f=($,x)=>{let t=_0x232bc1;return $[t(465)]($=>t(225)+($.thumbnail??x)+t(479)+$[t(628)]+'" data-original-id="'+$[t(174)]+'"\n data-price="'+u($)+t(160)+b($)+'">\n '+$[t(269)]+t(584))[t(338)](" \n")},u=$=>{let x=_0x232bc1;return FGSECOMAPP[x(494)][x(373)](y($?.[x(229)]))},b=$=>{let x=_0x232bc1,t=FGSECOMAPP?.[x(611)]?.[x(458)]===x(364)?$?.[x(264)]??$?.[x(438)]:$?.[x(438)];return FGSECOMAPP.formatter[x(373)](y(t??0))},p=($,x)=>{let t=_0x232bc1;return h(Shopify?.[t(157)][$])?x??"#":Shopify?.[t(157)][$][t(393)]},g=($,x)=>{let t=_0x232bc1;return FGSECOMAPP[t(278)][t(431)]?h(Shopify?.[t(157)][$])?x.replace("\xbb","")[t(355)](/\(\d*% off\)/,"")??"":Shopify?.[t(157)][$][t(532)]:""},h=$=>{let x=_0x232bc1;if(0===$)return!0;if(typeof $==x(597)||typeof $==x(238))return!1;if(typeof $==x(310)||null===$)return!0;if(typeof $[x(643)]!=x(310))return 0===$[x(643)];let t=0;for(let e in $)$[x(354)](e)&&t++;return 0===t},m=$=>{let x=_0x232bc1;try{let t={...FGSECOMAPP[x(552)]},e=t[$];if(e=e?e[x(576)]():null,!h(e)&&e.length>0)try{return document[x(617)](e),", "+e}catch(a){}return""}catch(i){return""}},v=()=>{let $=_0x232bc1;try{FGSECOMAPP[$(494)]=new Intl[$(444)](Shopify?.sca_locale??Shopify?.[$(539)],{style:$(422),currency:Shopify?.currency?.active??$(214)})}catch(x){FGSECOMAPP.formatter=new Intl[$(444)]($(381),{style:$(422),currency:Shopify?.[$(422)]?.[$(232)]??$(214)})}},y=$=>{let x=_0x232bc1;$=$??0;let t=Shopify?.[x(422)]?.[x(638)]??1;return 1===parseFloat(t)?$:($*t)[x(472)](Shopify?.[x(247)]??2)},w=$=>{let x=_0x232bc1;return $.filter($=>void 0===$[x(244)]||!0===$[x(244)])[x(252)](($,t)=>$+t[x(600)]*(t[x(337)]??t[x(229)]),0)/100},k=$=>{let x=_0x232bc1;return $.filter($=>void 0===$.cal_gift_for_other_rules||$.cal_gift_for_other_rules)[x(252)](($,t)=>$+t[x(600)],0)},C=($,x,t)=>{let e=_0x232bc1,a=x.product_narrow;return t?.is_only&&($=$.filter($=>o($))),h(a)?$:$[e(219)]($=>{let x=e;return!a[x(465)](t=>{let e=x;switch(t[e(513)]){case e(475):return Object[e(299)](t.value)[e(465)]($=>$[e(236)])[e(257)]().map($=>$.id)[e(231)]($[e(533)]);case e(460):return Object[e(454)](t[e(339)]).includes($.product_type);case"product_vendors":return Object[e(454)](t[e(339)]).includes($[e(259)]);case"product_collections":let a=Object[e(454)](t.value),i=$.collections?.[e(465)]($=>$.id+"")?.[e(219)]($=>a[e(231)]($));return!h(i);default:return!1}})[x(231)](!1)})},A=($,x)=>$?.map($=>{let t=_0x3133;if(typeof $.cal_gift_for_other_rules!==t(310)){let e=FGSECOMAPP[t(545)]?.[t(219)](x=>x[t(548)]===$[t(533)]),a=e?.[t(252)](($,x)=>$+x[t(600)],0);if(a===$.quantity){let i=e?.[t(219)](e=>{let a=t;if(e[a(566)]?.[a(304)]()===x[a(304)]())return!1;let i=FGSECOMAPP[a(578)]?.[a(201)]($=>$.id?.[a(304)]()===e[a(566)]?.[a(304)]()),r=i[a(432)]??{};return r[a(244)]&&$[a(337)]>0})?.[t(252)](($,x)=>$+x.quantity,0);return{...$,cal_gift_for_other_rules:i>0,quantity:i??0}}return{...$,cal_gift_for_other_rules:!1,quantity:0}}return{...$}})??[],S=($,x,t,e)=>{let a=_0x232bc1,i=0,r=C(x,$,e);r=A(r,$[a(224)]);let _;return $[a(327)]===a(497)?_=w(r):$[a(327)]===a(186)&&(_=k(r)),_>=$.min_amount&&(null===$[a(292)]||_<=$[a(292)])&&(i=t[a(556)],$[a(606)]&&(i=Math[a(246)](_/$.min_amount)*i)),i},T=($,x,t,e)=>{let a=_0x232bc1,i={},r=[],_=0;return x[a(465)](x=>{let i=a,c=S(x,$,t,e);0!==c&&(_=c),r[i(179)](c>0)}),i.max_gifts_can_get=_,i.condition_result=r,i},q=($,x)=>{let t=_0x232bc1,e=!1;return 1===$[t(643)]?e=$[0]:2===$[t(643)]&&("and"===x&&(e=$[0]&&$[1]),"or"===x&&(e=$[0]||$[1])),e},E=($,x)=>{let t=_0x232bc1,e=$?.[t(465)]($=>$[t(533)]);FGSECOMAPP[t(545)]=FGSECOMAPP[t(545)][t(219)]($=>e?.[t(231)]($[t(548)]));let a=x[t(262)].map($=>$[t(628)]),i=FGSECOMAPP.arrOfferAdded[t(219)]($=>$[t(566)]?.[t(304)]()===x.id?.toString())?.[t(465)]($=>$.variantId),r=$[t(219)]($=>{let x=t;return n($)&&($[x(244)]=!1),a.includes($[x(533)])&&i.includes($[x(533)])}),_=r.map($=>{let e=t,a=x[e(432)];$[e(244)]=a[e(244)],$[e(566)]=x.id?.[e(304)]();let i=FGSECOMAPP[e(545)]?.[e(219)](t=>t[e(566)]?.[e(304)]()!==x.id?.[e(304)]()&&$[e(533)]===t[e(548)])?.[e(252)](($,x)=>$+x[e(600)],0);return{...$,quantity:$.quantity-i}});return _[t(219)]($=>{let e=t;return $.belongs_to_offer?.[e(304)]()===x.id?.[e(304)]()})},L=$=>{let x=_0x232bc1,t=$[x(353)][x(219)](t=>t[x(566)]?.toString()!==$.id?.toString()).map($=>$[x(395)]);return Object[x(299)]($[x(317)])[x(219)]($=>!t[x(231)]($[x(218)]))},P=($,x)=>{let t=_0x232bc1,e=E($,x),a=T($,x[t(220)],x[t(432)],x[t(595)]?.[t(632)]),i=q(a[t(546)],x[t(235)]);if(i){let r=e[t(219)]($=>$[t(566)]?.[t(304)]()===x.id?.[t(304)]()).reduce(($,x)=>$+x.quantity,0);a[t(624)]=a[t(624)]-r,x[t(353)]=e,x[t(518)]=a[t(624)]}else x[t(353)]=e,x[t(518)]=0;return"number"==typeof FGSECOMAPP[t(551)]&&x.priority>FGSECOMAPP[t(551)]&&(i=!1),i||!x[t(162)]||FGSECOMAPP[t(551)]!==x.priority||h(e)||(FGSECOMAPP[t(551)]=null),x[t(567)]=i,x.stop_lower_priority&&i&&(null==FGSECOMAPP[t(551)]||x[t(159)]<=FGSECOMAPP[t(551)])&&FGSECOMAPP[t(551)]!==x.priority&&(FGSECOMAPP[t(551)]=x[t(159)]),x},I=$=>{let x=_0x232bc1,t=$+"=",e=document[x(409)][x(401)](";");for(let a=0;a{let t=_0x232bc1,e=!0,a=!0,i=!0,r=!0;if(!h($.sub_conditions?.[t(515)])){let _=I("sca_fg_codes");e=_&&JSON[t(478)](_)[t(231)]($.sub_conditions.specific_link_address)}if(!h($[t(595)]?.customer_tags)){let{customer_tags:c}=$.sub_conditions,n=c?.[t(169)]?.some($=>x[t(163)].tags?.[t(231)]($));a=c?.[t(349)]===t(582)?n:!n}if(!h($[t(595)]?.[t(176)])){let{customer_locations:o}=$.sub_conditions,s=o?.[t(375)]?.[t(231)](FGSECOMAPP.customerLocation);r=o?.[t(483)]===t(582)?s:!s}if(!h($[t(595)]?.[t(308)])){let l=!0,d=$[t(595)][t(308)],f=x[t(163)][t(553)]??[];if(d[t(580)]){let u=Date.parse(d[t(580)])/1e3;f=f[t(219)]($=>$.created_at>=u)}if(!h(d?.[t(575)])&&(0!==d.total_spend_on_order_history.min_amount||0!==d.total_spend_on_order_history[t(292)])){let b=d.total_spend_on_order_history.min_amount,p=d[t(502)][t(292)],g=f[t(252)](($,x)=>$+x[t(441)],0)/100;l&=(g>=b||!b)&&(g<=p||!p)}if(!h(d?.[t(165)])&&(0!==d[t(165)].min_amount||0!==d[t(165)].max_amount)){let m=x.customer[t(550)]/100,v=d.total_spent_on_last_order.min_amount,y=d[t(165)][t(292)];l&=(m>=v||!v)&&(m<=y||!y)}if(!h(d?.number_of_order)){let w=!(0!==d[t(612)][t(344)]||0!==d[t(612)][t(292)]),k=f[t(643)],C=d[t(612)][t(344)],A=d[t(612)][t(292)];l&=w?h(f):(k>=C||!C)&&(k<=A||!A)}if(d?.have_not_got_gift_from_this_offer){let S=x[t(163)][t(591)]??[],T=$[t(262)]?.[t(371)]($=>S.includes($.variant_shopify_id))||$[t(262)]?.[t(371)]($=>S[t(231)]($[t(174)]+"_"+($[t(438)]-$[t(229)])*100));l&=!T}i=l}return e&&a&&i&&r},M=($,x,t)=>{let e=_0x232bc1,a=[],i=[],r=[],_=[];for(let c of x){let o=P($,c);if(!o.isReachConditions){o[e(353)][e(643)]>0&&o[e(353)].forEach($=>{let x=e;i[x(179)]({variant_id:$[x(533)],quantity:$[x(600)],offer_id:c.id})});continue}if(o.giftsAvailable<0){o[e(353)].forEach($=>{let x=e;i[x(179)]({variant_id:$[x(533)],quantity:$[x(600)],offer_id:c.id})});continue}0!==o.giftsAvailable&&(c[e(595)]?F(c,SECOMAPP)&&a[e(179)](c):a.push(c))}if($?.[e(325)]($=>{let x=e;h($[x(566)])&&n($)&&i.push({variant_id:$[x(533)],quantity:$[x(600)],offer_id:$.belongs_to_offer?.[x(304)]()})}),t||h(i)){let s=a[e(465)]($=>{let x=e;return{id:$.id,offerName:$[x(172)],offerPriority:$[x(159)],stopLowerPriority:$[x(162)],gifts:L($),giftsAvailable:$.giftsAvailable,giftsAdded:$[x(353)],isReachConditions:$[x(567)]}});if(!h(s)){let l={};for(let d of s){let f=H(FGSECOMAPP.fgSettings,d);f?.[e(643)]>0?r=r[e(369)]([...f]):d[e(442)][e(465)]($=>{let x=e;l[$[x(218)]]={...$,belongs_to_offer:d.id?.[x(304)]()}})}_=Object[e(299)](l)??[]}}return{arrGiftsAdd:r,arrGiftsRemove:i,arrGiftsData:_}},O=($,x)=>{let t=_0x232bc1,e=new Set;return $?.[t(325)]($=>e[t(204)]($[t(224)])),e[t(325)]($=>{let x=t,e=FGSECOMAPP[x(578)]?.find(t=>t.id?.[x(304)]()===$?.[x(304)]());if(h(e)||!e.isReachConditions){FGSECOMAPP[x(545)]=FGSECOMAPP[x(545)]?.[x(219)](t=>t[x(566)]?.[x(304)]()!==$?.toString());return}if(e[x(518)]>=0)return;let a=[],i=FGSECOMAPP[x(545)]?.[x(219)](t=>t[x(566)]?.[x(304)]()===$?.[x(304)]())??[];if(e?.gift_settings?.[x(459)])a=a[x(369)]([...i]),e[x(518)]=0;else for(let r of i){if(e[x(518)]>=0)break;e[x(518)]+=r.quantity,e[x(518)]<=0?a.push({...r}):(r[x(600)]=e.giftsAvailable,e[x(518)]=0)}a?.[x(325)]($=>{let t=x;FGSECOMAPP[t(545)]=FGSECOMAPP.arrOfferAdded?.filter(x=>$[t(548)]!==x[t(548)]||$[t(566)]?.[t(304)]()!==x[t(566)]?.toString())})}),x?.[t(219)]($=>{let x=t;return n($)&&($[x(600)]=FGSECOMAPP.arrOfferAdded?.[x(219)](t=>$[x(533)]===t.variantId)?.[x(252)](($,t)=>$+t[x(600)],0)??0),$[x(600)]>0})??[]},G=async($,x)=>{let t=_0x232bc1,{arrGiftsAdd:e,arrGiftsRemove:a,arrGiftsData:i}=M($,x,!1),_=O(a,$);if(!h(a)){let c=M(_,x,!0);O(c?.[t(200)],$),e=c?.[t(392)],a=a?.concat(c?.arrGiftsRemove)??[],i=c?.arrGiftsData}return await s(e,a),r()[t(622)](),i},H=($,x)=>{let t=_0x232bc1,e=[];if($[t(285)]){let a=x[t(442)],i=a.reduce(($,x)=>$+x[t(155)][t(643)],0),r=FGSECOMAPP[t(578)][t(219)]($=>$.id===x.id),_=r[0][t(432)][t(459)],c=r[0][t(402)];if(1===i||_||c[t(275)]){if($[t(510)]&&!N(a)||$?.[t(473)]&&!z(a))return!1;if(c[t(275)]){if(c[t(513)]===t(236)){let n=FGSECOMAPP[t(440)];n=n.filter($=>{let x=t;return $[x(395)]===a[0][x(209)]});let o=a[0][t(155)][t(219)]($=>{let x=t;return n[0][x(533)]===$[x(174)]})[0];if(0===o.price)return e.push({variant_id:o[t(628)],quantity:x.giftsAvailable,offer_id:x.id}),e}else if(_){let s=a?.reduce(($,x)=>($+x?.[t(155)]?.[t(643)])??0,0);if(!s)return!1;let l=(x?.[t(518)]??0)/s;for(let d of a)for(let f of d[t(155)])e[t(179)]({variant_id:f.variant_shopify_id,quantity:l,offer_id:x.id});return e}}else{if(_){let u=a?.[t(252)](($,x)=>($+x?.[t(155)]?.[t(643)])??0,0);if(!u)return!1;let b=(x?.giftsAvailable??0)/u;for(let p of a)for(let g of p[t(155)])e[t(179)]({variant_id:g.variant_shopify_id,quantity:b,offer_id:x.id});return e}{let h=a[0].variants[0];if(0===h.price)return console[t(535)](t(426)+a[0][t(155)][0][t(628)]+" "+a[0].variants[0][t(269)]),e[t(179)]({variant_id:h.variant_shopify_id,quantity:x.giftsAvailable,offer_id:x.id}),e}}}}return!1},R=$=>{let x=_0x232bc1;return $===x(350)},D=$=>{let x=_0x232bc1;try{let t=Shopify[x(387)]??FGSECOMAPP[x(242)]?.[x(618)]?.[x(512)]?.gift_img_size??x(543),e=new URL($),a=new URLSearchParams(t);return a[x(325)](($,t)=>e[x(222)][x(362)](t,$)),e.toString()}catch(i){return $}},j=$=>{let x=_0x232bc1,t=$;if(FGSECOMAPP[x(278)].show_gift_for_customer===x(309))for(let e of(t=[],$)){let a=e.variants;a&&a.length&&a[x(325)]($=>t[x(179)]({...e,thumbnail:$[x(428)],variants:[$]}))}let i=document[x(457)](x(323));i&&(i[x(505)]=t[x(465)]($=>{let t=x,e=$?.[t(155)][0]??{};return t(477)+p($[t(209)],$[t(329)])+t(321)+D($[t(428)])+t(579)+g($[t(209)],$[t(532)])+"

\n "+(FGSECOMAPP.fgAppearanceGiftSlider[t(192)]===t(309)&&FGSECOMAPP.fgAppearanceGiftSlider[t(345)]?t(621)+(1===$[t(155)][t(643)]?t(423)+(R(e[t(269)])?t(646):"")+t(647)+e[t(269)]+t(474):t(604)+(FGSECOMAPP[t(278)][t(182)]??"Select variant")+t(300))+t(541):"")+t(453)+b(e)+'\n \n '+u(e)+t(390)+(FGSECOMAPP[t(278)][t(192)]!==t(309)?t(306)+(1===$[t(155)][t(643)]?t(423)+(R(e[t(269)])?"sca-d-none":"")+'">'+e.variant_title+t(300):''+(FGSECOMAPP[t(278)][t(182)]??t(563))+"")+'\n \n
\n \n
":"")+t(549)+$[t(566)]+'"\n data-variant="'+(1===$.variants.length?e.variant_shopify_id:"")+t(641)+(FGSECOMAPP[t(278)].add_to_cart_btn_title??t(560))+"\n \n
\n
\n
"})[x(338)](" \n"),new Glider(document[x(617)](x(463)),{slidesToShow:1,slidesToScroll:1,draggable:!1,dots:FGSECOMAPP[x(278)][x(351)]?x(212):null,arrows:{prev:x(293),next:x(217)},responsive:[{breakpoint:1024,settings:{slidesToShow:FGSECOMAPP.fgAppearanceGiftSlider.number_product_slider??4,slidesToScroll:1}},{breakpoint:768,settings:{slidesToShow:3,slidesToScroll:1}},{breakpoint:576,settings:{slidesToShow:2,slidesToScroll:1}}]}))},B=async()=>{let $=_0x232bc1;try{let x=window[$(631)]?.[$(578)]??[];for(let t in await $u(),Shopify?.products)h(Shopify?.products[t]?.id)&&delete Shopify?.products[t];let e=[];return x.forEach(x=>{let t=$,a=JSON[t(478)](JSON.stringify(x));if(x[t(402)][t(275)]){let i=x[t(220)][0][t(565)],r=i[0].value,_=[...a.gift_items],c=[...a[t(317)]];if("variant"===x[t(402)].type)for(let n in r){let o=r[n]?.[t(236)]??[];for(let s of o){a[t(220)][0][t(565)]=[{type:i[0][t(513)],value:{[n]:{...r[n],variant:[{...s}]}}}],a[t(262)]=_[t(219)]($=>$[t(209)]+""===n&&s.id===$[t(174)]),a.gift_products=c.filter($=>$.original_product_shopify_id+""===n),a[t(317)][0][t(155)]=[...a.gift_items];let l=a.gift_settings[t(556)],d=a[t(432)].auto_add_all_gifts;a[t(432)][t(459)]&&(l=a.gift_items[t(643)]),1===a[t(262)].length&&0===a[t(262)][0][t(229)]&&(d=!0),e[t(179)](JSON.parse(JSON[t(522)]({...a,gift_settings:{...a.gift_settings,number_of_gift_can_receive:l,auto_add_all_gifts:d},id:a.id+"_"+r[n][t(393)]+"_"+s.id})))}}else if(x[t(402)][t(513)]===t(573))for(let f in r){a.offer_conditions[0].product_narrow=[{type:i[0][t(513)],value:{[f]:r[f]}}],a[t(262)]=_[t(219)]($=>$[t(209)]+""===f),a[t(317)]=c[t(219)]($=>$[t(209)]+""===f);let u=a[t(432)][t(556)],b=a[t(432)][t(459)];a[t(432)][t(459)]&&(u=a.gift_items[t(643)]),1===a[t(262)].length&&0===a.gift_items[0][t(229)]&&(b=!0),e[t(179)](JSON[t(478)](JSON.stringify({...a,gift_settings:{...a.gift_settings,number_of_gift_can_receive:u,auto_add_all_gifts:b},id:a.id+"_"+r[f][t(393)]})))}}}),(x=(x=(x=x?.[$(219)](x=>!x?.[$(402)]?.[$(275)])?.concat(e))?.[$(465)](x=>{let t=$;return{...x,id:x.id[t(304)]()}}))?.[$(219)](x=>{let t=$;if(!X(x.start_time,x.end_time))return!1;let e=!h(x[t(595)]?.[t(308)]||x[t(595)]?.customer_tags);if(x[t(595)]&&(!F(x,SECOMAPP)||e&&h(SECOMAPP[t(163)].email)))return!1;let a={...Shopify?.[t(157)]},i=!1;if(FGSECOMAPP[t(611)].sync_quantity===t(629)){x[t(262)]=x?.[t(262)][t(219)]($=>{let x=t,e=a[$[x(209)]]?.[x(359)]??{};return e[$[x(174)]]>0})??[];let r=x[t(262)]?.[t(465)]($=>$[t(628)]);x[t(317)]=x?.[t(317)]?.filter($=>{let x=t;return $.variants=$?.[x(155)]?.[x(219)]($=>{let t=x;return r?.[t(231)]($[t(628)])}),$?.[x(155)]?.[x(643)]>0}),i=!0}else if(FGSECOMAPP.fgSettings[t(265)]){x[t(262)]=x?.[t(262)][t(219)]($=>{let x=t,e=a[$[x(218)]]?.[x(359)]??{};return e[$[x(628)]]>0});let _=x[t(262)]?.map($=>$.variant_shopify_id);x[t(317)]=x?.[t(317)]?.filter($=>{let x=t;return $[x(155)]=$?.variants?.[x(219)]($=>{let t=x;return _?.[t(231)]($.variant_shopify_id)}),$?.variants?.length>0}),i=!0}return i&&x[t(432)]?.[t(459)]&&(x[t(432)][t(556)]=x[t(262)]?.[t(643)]),!i||x.gift_items&&x[t(262)][t(643)]>0}))?.map(x=>{let t=$,e=x[t(262)][t(465)]($=>$[t(209)]);return x[t(317)]=x[t(317)]?.[t(219)]($=>{let x=t;return e[x(231)]($.original_product_shopify_id)}),x[t(220)]?.[t(325)]($=>{let x=t;$[x(327)]===x(497)&&($[x(344)]=y($[x(344)]),$.max_amount=h($.max_amount)?$[x(292)]:y($[x(292)]))}),x})}catch(a){return console[$(320)](a),[]}},N=$=>{let x=_0x232bc1;for(let t of FGSECOMAPP.cartItems){let e=t.product_id;if($[0][x(209)]===e)return!1}return!0},z=$=>{let x=_0x232bc1;for(let t of FGSECOMAPP[x(440)]){let e=$[0][x(155)][0][x(438)];if(FGSECOMAPP.fgSettings[x(473)]===x(364)&&(e=$[0][x(155)][0].original_compare_at_price),e>t[x(229)]/100)return!1}return!0},U=async()=>{let $=_0x232bc1;try{let x=[];window[$(631)]?.[$(578)]?.forEach(t=>{let e=$,a=[];t[e(317)][e(325)]($=>{let x=e;a[x(179)]($[x(226)],$[x(329)])}),x=[...x,...a]}),await $l(x=(x=[...new Set(x)])[$(219)](x=>h(FGSECOMAPP[$(297)][x]))),Object[$(299)](FGSECOMAPP[$(297)])?.[$(325)]($=>{let{info:x}=$;h(x)||h(x?.id)||(Shopify.products[x.id]={...x})})}catch(t){console.error(t)}},W=async $=>{let x=_0x232bc1;v(),FGSECOMAPP.fetchCheckoutEvents(),(FGSECOMAPP?.[x(611)]?.sync_quantity===x(629)||FGSECOMAPP?.[x(611)]?.[x(265)])&&await U(),FGSECOMAPP[x(578)]=await B(),FGSECOMAPP[x(330)](),a();try{h($)?(FGSECOMAPP[x(545)]=[],localStorage[x(289)](x(161),LZString.compressToBase64(JSON[x(522)](FGSECOMAPP[x(545)])))):FGSECOMAPP.arrOfferAdded=JSON.parse(LZString[x(630)](localStorage[x(419)]("sca_offers_added")))}catch(t){FGSECOMAPP.arrOfferAdded=[],localStorage[x(289)](x(161),LZString[x(312)](JSON.stringify(FGSECOMAPP.arrOfferAdded)))}let e={};FGSECOMAPP[x(578)]?.forEach($=>{let t=x;e[$.id]=$?.gift_items?.[t(465)]($=>$[t(628)])});let i=Object[x(454)](e);FGSECOMAPP[x(545)]=FGSECOMAPP[x(545)]?.[x(219)]($=>i?.[x(231)]($.belongs_to_offer?.[x(304)]())&&e[$[x(566)]?.[x(304)]()][x(231)]($[x(548)]));let r={};FGSECOMAPP[x(545)]?.[x(325)]($=>{let t=x,e=r[$.belongs_to_offer+"_"+$[t(548)]]??{};r[$[t(566)]+"_"+$.variantId]={...$,belongs_to_offer:$[t(566)]?.[t(304)](),quantity:(e?.quantity??0)+($?.[t(600)]??0)}}),FGSECOMAPP.arrOfferAdded=Object.values(r),localStorage[x(289)](x(161),LZString[x(312)](JSON.stringify(FGSECOMAPP[x(545)])));let _=await G($,FGSECOMAPP.offers);await V(_),$f(),$8(),$d()},Y=function(){let $=_0x232bc1,x=document[$(594)]($(406)),e=document[$(594)]($(378)),a=$(508),i=document[$(594)]($(598)),r=i.length;for(let _=0;_{let e=$;x[e(331)]===document[e(617)](e(450))&&(document[e(617)]("#freegifts-main-popup-container.sca-modal-fg.sca-is-visible-fg")[e(416)][e(561)](a),t())}),document[$(435)]("keyup",x=>{let e=$;x[e(273)]===e(488)&&document.querySelector(e(450))&&(document[e(617)](e(450))[e(416)].remove(a),t())}),document[$(594)]($(427))[$(325)](x=>x.addEventListener($(286),function(){let x=$;this.setAttribute(x(557),1),this[x(191)](),this[x(416)][x(332)](x(232)),this.querySelector(x(307))[x(416)][x(332)](x(311))})),document[$(594)]($(427))[$(325)](x=>document[$(435)]($(286),function(t){let e=$,a=x.contains(t[e(331)]);a||(x.classList.remove("active"),x[e(617)](e(307)).classList[e(561)](e(311))),document.querySelectorAll(e(516))[e(325)]($=>{let x=e;$[x(637)]=!0,$[x(391)].backgroundColor="#82868b"})})),document[$(594)]($(476))[$(325)](x=>{let t=$;x[t(435)](t(286),function(){let $=t,x=this[$(287)]("id"),e=this[$(287)]("data-img"),a=this[$(287)]($(171)),i=this[$(287)]("data-original-price"),r=this[$(287)]("data-original-id"),_=this[$(352)][$(352)][$(352)][$(352)];_[$(617)]($(181))[$(519)]("src",e);let c=new URL(_[$(617)]($(370))[$(301)]);c[$(222)][$(362)]($(236),r),_[$(617)](".gift-original-url").href=c.toString();let n=this.parentElement[$(352)][$(352)];n[$(617)](".original-price del").textContent=i,n[$(617)]($(517))[$(620)]=a;let o=n?.[$(617)]($(619));o[$(519)]("data-variant",x),o[$(637)]=!1,o[$(391)]="";let s=this[$(352)][$(352)][$(617)](".selected-variant");s[$(416)][$(204)]("active"),s.innerHTML=this.innerText})}),document.querySelectorAll($(598)).forEach(x=>x.addEventListener($(286),async function(){let x=$,t=this[x(287)]("data-variant")-0,e=this[x(287)](x(216));try{await c(t,1,e);let i=document[x(617)](x(450));i&&(FGSECOMAPP[x(274)]=!0,await new Promise($=>setTimeout($,800)),i[x(416)][x(561)](a)),window[x(644)].href.includes(x(449))?location[x(571)]():typeof Shopify?.[x(358)]===x(342)&&await Shopify?.getCart(0===FGSECOMAPP[x(316)][x(643)]?function(){}:FGSECOMAPP[x(316)][0])}catch(r){console[x(320)](r)}}))},X=($,x)=>{let t=_0x232bc1;if($){let e=new Date,a=e[t(366)](),i=new Date($)[t(366)]();if(!x)return a>=i;{let r=new Date(x)[t(366)]();return a>=i&&a<=r}}return!1},V=async $=>{let x=_0x232bc1;if(FGSECOMAPP[x(611)]?.[x(239)])for(let t of FGSECOMAPP.cartItems)n(t)&&($=$[x(219)]($=>$[x(218)]!==t[x(395)]));if(FGSECOMAPP[x(611)]?.[x(510)])for(let e of FGSECOMAPP[x(440)])$=$[x(219)]($=>$[x(209)]!==e.product_id);if(FGSECOMAPP[x(611)]?.[x(473)])for(let a of FGSECOMAPP[x(440)])$=$.filter($=>{let t=x;return $.variants=$[t(155)][t(219)]($=>{let x=t,e=$[x(438)];return FGSECOMAPP[x(611)]?.compare_gift_price_with_product===x(364)&&(e=$.original_compare_at_price),e<=a.price/100}),!h($[t(155)])});$&&$.length>0&&(FGSECOMAPP[x(274)]?(await new Promise($=>setTimeout($,1500)),FGSECOMAPP[x(274)]=!1,d(),j($)):(d(),j($))),Y(),FGSECOMAPP[x(609)](),FGSECOMAPP.renderPromotionMessage(FGSECOMAPP.offers),Q=[]},Z=async $=>{let x=_0x232bc1;Q=[];let t=new URL(window[x(644)][x(301)]);t[x(222)].set(x(294),""),e(t[x(304)](),{method:x(521)})[x(622)]($=>$.text()).then($=>{let t=x,e=new DOMParser,a=e.parseFromString($,t(536)),i=t(223)+m(t(178)),r=t(462)+m(t(603)),_=document[t(617)](i),c=!1;_&&(c=!0,_.innerHTML=a[t(617)](i)?.[t(505)]??_[t(505)]);let n=document[t(617)](r);n||(n=document.querySelector(t(227))),n&&(c=!0,n[t(505)]=a.querySelector(r)?.[t(505)]??a[t(617)](t(437))?.innerHTML??n[t(505)]),c||console.log(t(615))}),"function"==typeof FGSECOMAPP?.[x(489)]&&await FGSECOMAPP.reRenderCartCustom(),setTimeout(function(){V($)},800)},J=async $=>{let x=_0x232bc1,t=await e("/cart.js?sca_fetch&"+($??""),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json"}})[x(622)]($=>$[x(414)]()),a=t[x(333)];return FGSECOMAPP.SHOPIFY_CART=t,FGSECOMAPP[x(440)]=a?.[x(465)]($=>{let t=x;return{...FGSECOMAPP.cartItems?.[t(201)](x=>x.id===$.id),...$}})??[],t},K=async()=>{let $=_0x232bc1,x=FGSECOMAPP[$(188)];try{await e(SECOMAPP.freegiftProxy,{method:"GET",headers:{"Content-Type":$(585)}})[$(622)](async t=>{let e=$,a=await t[e(414)]();FGSECOMAPP[e(440)]=a?.[e(305)]?.[e(465)]($=>{let x=e;return{...FGSECOMAPP[x(440)]?.[x(201)](x=>x.id===$.id),...$.product,collections:$[x(608)],tags:$[x(581)]}})??[],FGSECOMAPP[e(188)]=a?.[e(261)]??{},x=FGSECOMAPP[e(188)]})[$(486)](async t=>{let e=$;console[e(320)]("failed to parse cart section "+t.message),x=await J()})}catch(t){console.error($(633),t[$(569)]),x=await J()}return x},Q=[],$$=async $=>{let x=_0x232bc1;try{$===x(434)?Q[x(179)](x(492)):Q[x(179)]($[0]),await K();let t=await G(FGSECOMAPP.cartItems,FGSECOMAPP.offers);FGSECOMAPP.renderPromotionMessage(FGSECOMAPP.offers);let e=!1;return $[0].startsWith("/cart/add")&&JSON[x(522)]($[1][x(588)]??[])[x(231)]("sca_add_gift")?(console[x(535)](x(328),[...Q]),await Z(t),e=!0):$[0][x(382)](x(315))&&JSON[x(522)]($[1].headers??[]).includes(x(260))?(console.log("event auto process gifts with cart",[...Q]),await Z(t),e=!0):(console[x(535)](x(313),[...Q]),await V(t)),e&&(window[x(644)][x(301)][x(231)](x(449))||document.querySelector(x(303))?.[x(287)](x(403))===x(640))&&(Q=[],location.reload()),FGSECOMAPP[x(440)]}catch(a){console[x(320)](a)}},$x=()=>{let $=_0x232bc1;if(!Shopify?.[$(206)])return;let x=document.querySelector($(626));if(!x)return;x[$(505)]="";let t=Shopify?.sca_text_notify_success??$(411),e=document[$(534)]("li");e[$(348)]=$(429),e[$(505)]=$(296)+t+$(365),x[$(498)](e),e[$(154)]=setTimeout(()=>$0(e),3e3),document[$(617)]($(586))?.addEventListener($(286),()=>$0(e))},$0=$=>{let x=_0x232bc1;$.classList[x(204)](x(158)),$[x(154)]&&clearTimeout($[x(154)]),setTimeout(()=>$.remove(),500)},$t=($,{value:x,innerHTML:t})=>{let e=_0x232bc1;try{let a=FGSECOMAPP[e(611)]?.[e(424)],i=a===e(175)?$[e(331)]:$.currentTarget??$.target;if(i?.hasAttribute(e(250))||(i=document[e(617)]("#sca-spinner-checkout")?.parentNode),i[e(339)]=x,i[e(505)]=t,i[e(637)]=!1,i[e(525)]("click",$e),i.removeAttribute(e(250)),a===e(272)){i[e(495)].querySelector("[sca_root_checkout]")[e(286)]();return}a===e(175)&&window.removeEventListener(e(286),$a,!0),i.click()}catch(r){window[e(644)][e(355)]((Shopify?.[e(487)]?.[e(639)]??"/")+e(196)),console.error(r.message)}},$e=async $=>{let x=_0x232bc1;try{$.preventDefault(),$.stopPropagation(),$[x(374)]();let t=FGSECOMAPP[x(611)]?.[x(424)],a=t===x(175)?$[x(331)]:$.currentTarget??$[x(331)],{form:i}=a,r="",_="";if(a&&(a[x(637)]=!0,r=a.innerHTML,_=a[x(339)],typeof FGSECOMAPP?.[x(245)]===x(342)?await FGSECOMAPP[x(245)]("start"):(a[x(339)]=x(368),a.innerHTML=x(295))),FGSECOMAPP.checkIsBlockCheckout)return!1;FGSECOMAPP[x(436)]=!0;try{await e(x(254),{method:x(610),body:new FormData(i)})}catch(c){console[x(535)]("not type checkout btn")}if(h(FGSECOMAPP[x(578)])&&h(FGSECOMAPP[x(440)]?.[x(201)]($=>n($))))return console[x(535)](x(326)),$t($,{value:_,innerHTML:r}),!1;await K();let o=[...FGSECOMAPP[x(440)]],s=!1;for(let l of FGSECOMAPP.offers)if(l[x(353)]&&l[x(353)][x(643)]){let d=P(o,l),f=X(l[x(564)],l[x(248)]);!f&&d.giftsAdded[x(643)]>0&&(s=!0),d[x(567)]||(s=!0),d[x(518)]<0&&(s=!0),l[x(595)]&&!F(l,SECOMAPP)&&(s=!0)}if(await G(o,FGSECOMAPP.offers),s)location[x(571)]();else try{FGSECOMAPP[x(611)].using_draft_order&&!h(FGSECOMAPP.cartItems?.[x(201)]($=>n($)))?await e(SECOMAPP.freegiftProxy+x(410)+Shopify?.shop,{method:"GET",headers:{"Content-Type":x(585)}})[x(622)](async $=>{let t=x,a=await $.json();a[t(305)]=(a[t(305)]??[]).map($=>{let x=t;return $[x(573)][x(608)]=$.collections?.[x(465)]($=>({id:$.id})),$[x(573)][x(581)]=$[x(581)],{id:$[x(573)].id,variant_id:$[x(573)][x(533)],title:$[x(573)][x(532)],handle:$[x(573)][x(393)],price:$[x(573)][x(337)]??$[x(573)][x(229)],quantity:$[x(573)].quantity,product_type:$[x(573)][x(499)],vendor:$[x(573)][x(259)],tags:$[x(573)][x(581)],collections:$[x(573)][x(608)],selling_plan_allocation:$.product[x(590)]}}),a.others={arr_offer_added:FGSECOMAPP[t(545)],secomapp:{customer:SECOMAPP?.[t(163)]??{},fg_codes:SECOMAPP?.fg_codes??[],fgSettings:FGSECOMAPP[t(611)]},cookie_fg_code:I("sca_fg_codes"),shopify_currency:Shopify?.[t(422)]},await e(SECOMAPP[t(319)]+t(334)+LZString[t(480)](a=JSON[t(522)](a)),{method:t(521),headers:{"Content-Type":t(585)}})[t(622)](async $=>{let x=t,e=await $[x(414)]();try{FGSECOMAPP[x(436)]=!1,e[x(322)]&&(window[x(644)][x(301)]=e[x(322)].invoice_url)}catch(a){console[x(320)](a)}})}):(console[x(535)](x(445)),FGSECOMAPP[x(436)]=!1,$t($,{value:_,innerHTML:r}))}catch(u){FGSECOMAPP[x(436)]=!1,$t(u,{value:_,innerHTML:r})}(a=t===x(175)?$.target:$[x(377)]??$[x(331)])&&(typeof FGSECOMAPP?.[x(245)]===x(342)?await FGSECOMAPP.scaCustomLoadingCheckout(x(347)):(a[x(339)]=_,a[x(505)]=r),a[x(637)]=!1)}catch(b){"function"==typeof FGSECOMAPP?.[x(245)]&&await FGSECOMAPP.scaCustomLoadingCheckout(x(347)),console[x(320)](b)}},$a=async $=>{let x=_0x232bc1;$[x(331)]?.[x(602)]("sca_handle_checkout")&&await $e($)},$i=()=>{let $=_0x232bc1,x=FGSECOMAPP.fgSettings?.mode_override_checkout,t=$(170)+m($(360));document.querySelectorAll(t)[$(325)](t=>{let e=$,a=t.hasAttribute(e(399)),i=t[e(602)](e(241)),r=t.hasAttribute(e(250));if("clone_checkout"===x){if(a)return;if(!i&&!r){let _=t[e(221)](!0);_[e(435)](e(286),$e),_[e(519)](e(250),""),_[e(519)](e(241),""),t[e(391)].display=e(237),t[e(391)][e(418)]=e(336),t[e(391)][e(446)]="0",t[e(519)](e(399),""),t[e(495)]?.[e(498)](_)}i&&!r&&(t[e(435)]("click",$e),t[e(519)](e(250),""))}else x===e(175)?t[e(519)](e(250),""):r||(t[e(435)]("click",$e),t[e(519)](e(250),""));FGSECOMAPP.hasDoneProcessCheckout=!0}),x===$(175)&&window[$(435)]($(286),$a,!0)};FGSECOMAPP.fetchCheckoutEvents=()=>{FGSECOMAPP.scaCountRenderEventCheckout=0;let $=setInterval(()=>{let x=_0x3133;$i(),FGSECOMAPP.scaCountRenderEventCheckout++,(FGSECOMAPP[x(407)]>10||FGSECOMAPP.hasDoneProcessCheckout)&&(FGSECOMAPP[x(407)]=0,clearInterval($))},400)};let $r=$=>{let x=_0x232bc1;try{let t={},e={},a=FGSECOMAPP[x(578)];if(h($)){$=[],h(Shopify?.[x(324)])||$[x(179)]({...Shopify?.[x(324)]});let i={...Shopify?.[x(467)],...Shopify?.current_collection?.[x(157)]};Object[x(299)](FGSECOMAPP[x(297)])?.[x(219)]($=>!h($[x(194)])&&(h($?.[x(185)])||$?.[x(185)]&&!$?.positions?.[x(284)]($=>$?.classList?.[x(524)](x(468)))))?.forEach($=>{let t=x;i[$[t(194)].id]={...$[t(194)]}}),$=$[x(369)]([...Object[x(299)](i)])}for(let r in $?.[x(325)]($=>{let t=x,e=FGSECOMAPP[t(297)][$[t(393)]];FGSECOMAPP[t(297)][$.handle]={...e,info:{...$},product_has_icon:!!h(a)&&void 0}}),a?.[x(325)](a=>{let i=x,r=a[i(220)];if(1===r.length&&r[0].unit===i(186)&&"boolean"==typeof r[0].is_multiply){let _,c=r[0][i(565)];c?.[i(325)](x=>{let t=i;switch(x[t(513)]){case"variants_ids":_=Object[t(299)](x[t(339)]);break;case t(460):let e=Object[t(454)](x[t(339)]);e.length>0&&(_=(void 0===_?$:_)?.[t(219)]($=>e[t(231)]($.type))??[]);break;case t(601):let a=Object[t(454)](x[t(339)]);a[t(643)]>0&&(_=(void 0===_?$:_)?.[t(219)]($=>a.includes($.vendor))??[]);break;case t(270):let r=Object[t(454)](x[t(339)]);r.length>0&&(_=(void 0===_?$:_)?.[t(219)]($=>{let x=t,e=$.collections?.[x(465)]($=>$.id+""),a=e?.filter($=>r[x(231)]($));return!h(a)})??[])}}),_?.forEach($=>{let x=i,r=$.handle;if(t[r]){let _=t[r]?.map($=>$.original_product_shopify_id),c=a[x(317)]?.[x(219)]($=>!_?.[x(231)]($[x(209)]));t[r]=t[r][x(369)](c)}else t[r]=a.gift_products;let n=$[x(236)]?.[x(465)]($=>$.id)??[];e[r]=n[x(369)](e[r]??[]),e[r]=[...new Set(e[r])]})}}),t){let _=FGSECOMAPP.productsInPage[r];FGSECOMAPP[x(297)][r]={..._,gifts_will_receive:[...t[r]],product_has_icon:!0,variants_has_gift:[...e[r]]}}return Object.entries(t)?.[x(643)]?t:{}}catch(c){return console[x(320)](c),null}},$_=$=>{let x=_0x232bc1,t=FGSECOMAPP[x(634)][x(461)]??{};if(!t.gift_thumbnail?.[x(275)])return;let e=x(587)+(t[x(253)]?.[x(532)]??x(394))+x(335)+$?.[x(465)]($=>x(266)+p($[x(209)],$[x(329)])+x(190)+$.thumbnail+'" alt="">\n \n
')[x(338)]("")+"\n
\n \n "+($?.[x(643)]>=4?x(280):"")+'\n
\n
\n
\n ',a=".fg-secomapp-handle-add-to-cart "+m(x(302)),i=document[x(617)](a)??document[x(617)]("[type='submit'][name='add'], [type='button'][name='add'], [data-add-to-cart], [data-action='add-to-cart']");if(!i)return;i[x(495)][x(391)].width=x(298),i[x(495)][x(391)][x(439)]=x(614),i[x(495)]?.[x(348)]?.[x(231)](x(267))||i[x(495)]?.[x(416)]?.[x(204)](x(267));let r=i[x(495)][x(617)]("#sca-gift-thumbnail");if(r)r[x(505)]=e;else{(r=document.createElement(x(385))).setAttribute("id",x(271));let _=new DOMParser()[x(538)](e,x(536));r[x(505)]=_[x(469)][x(505)],i[x(495)][x(180)](r,i)}i[x(495)][x(180)](r,i);let c=document[x(617)](x(506));if(c)switch(t.gift_thumbnail?.[x(234)]){case"32":c[x(391)][x(470)]=x(514);break;case"50":c[x(391)][x(470)]=x(243);break;case x(421):c.style.maxWidth="70%";break;case x(156):c[x(391)][x(470)]=x(184);break;case x(636):c[x(391)][x(470)]=x(298);break;default:c[x(391)][x(470)]=x(243)}if($?.[x(643)]>=4)new Glider(document[x(617)](x(558)),{slidesToShow:3,slidesToScroll:1,draggable:!0,dots:".dots-thumbnail",arrows:{prev:x(443),next:x(215)}});else{c&&(c[x(391)][x(470)]=x(298));let n=document.querySelector(".sca-list-gift-thumbnail");n&&(n[x(391)][x(398)]=x(529))}},$c=()=>{let $=_0x232bc1;if(!(FGSECOMAPP[$(634)][$(461)]??{}).gift_icon?.[$(275)])return;let x=$(456)+FGSECOMAPP[$(634)][$(559)]+$(195),t=$(153)+m($(412)),e=document[$(617)](t)??document[$(617)]($(451));if(!e)return;e.style[$(193)]=$(420),e[$(391)][$(205)]=$(501),e[$(348)]?.[$(231)]($(384))||e[$(416)]?.[$(204)]($(384));let a=e.querySelector("#sca-gift-icon");if(a)a[$(505)]=x;else{(a=document[$(534)]($(385)))[$(519)]("id",$(356));let i=new DOMParser().parseFromString(x,$(536));a[$(505)]=i[$(469)].innerHTML,e.appendChild(a)}},$n=()=>{let $=_0x232bc1,x=[],t=$(554)+m("sca_fg_img_collection_gift_icon_query");return document.querySelectorAll(t)[$(325)](t=>{let e=$,a=t[e(617)](e(452)),i=a?.[e(287)](e(301))?.[e(401)]("/")??[],r=i?.[e(233)](e(157)),_=r>=0?i[r+1]??null:null;if(_=_?.split("?")?.[e(466)](),n(_)){t[e(561)]();return}let c=t[e(617)](e(210));if(c){t.remove();return}if(h(_))return;let o=decodeURI(_);h(FGSECOMAPP[e(297)][o]?.[e(194)])&&x[e(179)](o);let s=(FGSECOMAPP[e(297)][o]?.[e(596)]??[])[e(219)]($=>!t[e(166)]($));s.push(t),FGSECOMAPP[e(297)][o]={...FGSECOMAPP.productsInPage[o],positions:[...s]}}),x},$o=$=>{Object.keys($)?.forEach($=>{let x=_0x3133,t=FGSECOMAPP[x(297)][$]?.[x(596)]??[];if(h(t)||!Array.isArray(t))return;if(!(FGSECOMAPP.fgAppearanceGiftIcon[x(268)]??{}).status)return;let e=x(523)+FGSECOMAPP[x(634)][x(559)]+'" alt="free-gift-icon" class="sca-gift-icon-collection-img" />\n ';t[x(325)]($=>{let t=x;$[t(391)][t(193)]=t(420),$.className?.includes(t(642))||$[t(416)]?.[t(204)]("sca-fg-icon-collection-page");let a=$[t(617)](t(256));if(a)a.innerHTML=e;else{(a=document[t(534)](t(385)))[t(519)](t(279),t(468));let i=new DOMParser()[t(538)](e,t(536));a.innerHTML=i[t(469)][t(505)],$[t(498)](a)}})})},$s=async $=>{let x=_0x232bc1;await e(SECOMAPP[x(319)]+x(447)+LZString[x(480)](JSON[x(522)]($)),{method:"GET",headers:{"Content-Type":"application/liquid"}})[x(622)](async $=>{let t=x,e=await $[t(414)](),a=[];e?.[t(157)]?.[t(325)]($=>{let x=t;h($?.products?.id)||a[x(179)]({...$[x(157)],collections:$[x(608)],variants_quantity:$[x(359)]})});let i=$r(a);$o(i)})[x(486)]($=>{let t=x;console[t(320)]($)})},$l=async $=>{let x=_0x232bc1,t=[];for(let[e,a]of $[x(555)]())h(FGSECOMAPP[x(297)][a]?.[x(194)])&&t[x(179)](a),20===t.length&&(await $s([...t]),t=[]),e===$[x(643)]-1&&t[x(643)]>0&&(await $s([...t]),t=[])},$d=()=>{let $=$n(),x=$r();$o(x),$l($).then()},$f=()=>{let $=_0x232bc1;Shopify?.[$(599)]&&document[$(435)]($(613),function(){let x=$,t=new URL(document[x(404)]),e=parseInt(t[x(222)][x(574)](x(236)));$8(isNaN(e)?void 0:e)})},$8=$=>{let x=_0x232bc1;if(!location[x(301)][x(231)](x(291)))return;document[x(617)](x(189))?.[x(561)](),document[x(617)]("#sca-gift-thumbnail")?.[x(561)]();let t=$r();if(h(t))return;let e=location.pathname[x(401)]("/"),a=e?.[x(233)](x(157)),i=decodeURI(a>=0?e[a+1]??null:null);if(!Object[x(454)](t)?.[x(231)](i))return;let r=t[i],_=FGSECOMAPP[x(297)][i]?.[x(408)]??[];!(Shopify?.[x(599)]&&(!h($)&&!_.includes($)||h($)&&!h(Shopify?.current_product?.[x(213)])&&!_[x(231)](Shopify?.current_product?.[x(213)]?.id)))&&($_(r),$c(r))};FGSECOMAPP[_0x232bc1(520)]=$=>{let x=_0x232bc1;try{h($)&&($=[...FGSECOMAPP[x(578)]]);let t=location[x(301)].includes(x(449)),e=[];if($?.forEach($=>{let t=x;if($[t(567)]||h($[t(607)])||!h(FGSECOMAPP[t(551)])&&!$[t(567)]&&$[t(162)]&&$[t(159)]>FGSECOMAPP[t(551)])return;let a=$.promotion_message;$.offer_conditions?.forEach($=>{let x=t,e=C(FGSECOMAPP[x(440)],$);e=A(e,$[x(224)]);let i=0,r=null,_=0;$[x(327)]===x(497)?(i=w(e),r="{{sca_min_total}}",_=Shopify?.sca_amount_fixed??2):$[x(327)]===x(186)&&(i=k(e),r="{{sca_min_quantity}}",_=0);let c=Math[x(346)]($[x(344)]-i,0).toFixed(_);a=a[x(167)](r,c)}),e[t(179)](a)}),h(e)){document[x(594)](x(605))[x(325)]($=>$[x(505)]="");return}let a="",i=x(367)+e?.[x(465)]($=>x(592)+$+x(199))[x(338)]("")+x(496);FGSECOMAPP.fgAppearancePromotionMessage[x(491)]&&(a=i);let r=document.querySelector("#MainContent, #mainContent, #main, .main-content"),_=r?.[x(617)](x(208)),c=document[x(594)](x(281)+m(x(361))),n=document[x(594)](x(605));h(n)||n[x(325)]($=>$[x(505)]=a),(n=document.createElement("div"))[x(519)]("id",x(493)),n[x(416)][x(204)](x(493));let o=new DOMParser()[x(538)](a,x(536));n.innerHTML=o[x(469)].innerHTML,h(c)?!r?.[x(617)](x(605))&&(o=new DOMParser()[x(538)](a,x(536)),n.innerHTML=o[x(469)][x(505)],r&&_&&t?_[x(509)](n):r&&t&&r.prepend(n)):c?.[x(325)]($=>{let t=x;if($[t(617)](t(605)))return;let e=n[t(221)](!0);$[t(509)](e)});try{document[x(594)](x(572))[x(325)]($=>{let x=new Glider($);(($,x)=>{let t=_0x3133,e=$.track[t(413)],a=null,i=1;function r(){a=setTimeout(()=>{let x=_0x3133;i>=e&&(i=0),$[x(228)](i++)},3e3)}$.ele[t(435)]("glider-animated",function(){window[t(283)](a),r()}),r()})(x,3e3)})}catch(s){console[x(320)](s)}}catch(l){console[x(320)](l)}};let $u=async()=>{let $=_0x232bc1;try{let x=await e($(372)),t=await x.json();FGSECOMAPP[$(485)]=t?.[$(400)]}catch(a){console.log($(430))}},$b=function(){let $=_0x232bc1;try{typeof window[$(380)]===$(342)&&(FGSECOMAPP.reRenderCartCustom=async()=>{await window[$(380)]()}),window[$(435)]($(340),function(x){let t=$;typeof FGSECOMAPP[t(489)]!==t(342)&&typeof window[t(380)]===t(342)&&(FGSECOMAPP[t(489)]=async()=>{await window[t(380)]()}),$$(t(434))[t(622)](()=>{window.prepareDataForDisplayWidgetByRule()})}),window[$(435)]($(542),function(x){let t=$;"function"!=typeof FGSECOMAPP[t(489)]&&typeof window[t(380)]===t(342)&&(FGSECOMAPP[t(489)]=async()=>{await window.prepareDataForDisplayWidgetByRule()}),$$("/cart.js").then(()=>{window[t(380)]()})})}catch(x){console.error(x)}};W(FGSECOMAPP[_0x232bc1(440)]).then(()=>{$b()})}}catch($1){console[_0x232bc1(535)](_0x232bc1(490),$1)}