jQuery(document).ready((function(t){"use strict";if("undefined"!=typeof yith_wacp){var e,a=t("#yith-wacp-popup"),n=a.find(".yith-wacp-overlay"),i=a.find(".yith-wacp-close"),o=void 0,c=function(){t("html").removeClass("yith_wacp_open"),a.removeClass("open mini_cart"),setTimeout((function(){e.destroy()}),1e3),t(document).trigger("yith_wacp_popup_after_closing")},r=function(){var e=a.find(".yith-wacp-wrapper"),n=t(window).width(),i=t(window).height(),o=n-60>yith_wacp.popup_size.width?yith_wacp.popup_size.width:n-60,c=i-120>yith_wacp.popup_size.height?yith_wacp.popup_size.height:i-120;e.css({left:n/2-o/2,top:i/2-c/2,width:o+"px",height:c+"px"})},p=function(){var e=t("#yith-wacp-mini-cart"),a=t(window).width(),n=t(window).height()*(yith_wacp.mini_cart_position.top/100)-e.innerHeight(),i=a*(yith_wacp.mini_cart_position.left/100)-e.innerWidth();e.css({left:i,top:n}).show()},d=function(n){var i=a.find(".yith-wacp-content");return void 0!==n&&i.html(n),a.hasClass("open")?("undefined"!=typeof PerfectScrollbar&&e.update(),i.scrollTop(0),t(document).trigger("yith_wacp_popup_changed",[a])):(t(document).trigger("yith_wacp_popup_before_opening",[a]),r(),"undefined"!=typeof PerfectScrollbar&&(e=new PerfectScrollbar(".yith-wacp-content",{suppressScrollX:!0})),yith_wacp.is_mobile&&t("html").addClass("yith_wacp_open"),a.addClass("open"),t(document).trigger("yith_wacp_popup_after_opening",[a])),yith_wacp.touchstart_on_popup_actions_buttons&&t(document).on("touchstart",".popup-actions a",(function(){var e=t(this);e.hasClass("continue-shopping")?c():window.location.href=e.attr("href")})),yith_wacp.touchstart_on_suggested_products&&t(document).on("touchstart",".yith-wacp-related-product > a",(function(){var e=t(this);window.location.href=e.attr("href")})),!1},_=function(){void 0!==o&&(a.addClass("mini_cart"),d(o))},s=function(e){e>0?t("#yith-wacp-mini-cart").removeClass("empty"):t("#yith-wacp-mini-cart").addClass("empty"),t(".yith-wacp-mini-cart-count").length&&t(".yith-wacp-mini-cart-count").html(e),t(document).trigger("yith_wacp_cart_counter_updated")},h=function(t){t.block({message:null,overlayCSS:{background:"#fff url("+yith_wacp.loader+") no-repeat center",opacity:.5,cursor:"none"}})},u=function(e,a,n){t(document).trigger("yith_wacp_adding_cart_single"),n.addClass("loading").removeClass("added"),t.ajax({url:window.location,data:e,contentType:!1,processData:!1,dataType:"json",type:"POST",success:function(e){void 0!==e.error?(a.parents("div.product").before(e.error),t("body, html").animate({scrollTop:0},500),a.find(".gfield input, .gfield textarea, .gfield select ").each((function(){t(this).val()||t(this).closest(".gfield").addClass("gfield_error")}))):void 0!==e.html?(d(e.html),o=e.cart_html,t(document.body).trigger("wc_fragment_refresh").trigger("wacp_single_added_to_cart"),s(e.items)):t(document.body).trigger("added_to_cart",[e.fragments,e.cart_hash,n])},complete:function(){n.removeAttr("disabled").removeClass("loading").addClass("added")}})};if(t("body").on("added_to_cart cleverswatch_after_add_to_cart",(function(e,n,i,c){void 0===n&&(n=t.parseJSON(sessionStorage.getItem(wc_cart_fragments_params.fragment_name))),void 0!==n.yith_wacp_message&&(yith_wacp.allow_automatic_popup&&d(a.hasClass("mini_cart")?n.yith_wacp_message_cart:n.yith_wacp_message),o=n.yith_wacp_message_cart,s(n.yith_wacp_cart_items))})),t(document).on("yith_wwraq_added_successfully",(function(t,e){void 0!==e.yith_wacp_raq&&d(e.yith_wacp_raq)})),a.on("click",".yith-wacp-remove-cart, .item-remove a.remove",(function(e){e.preventDefault();var n=t(this),i=n.data("item_key")?n.data("item_key"):function(t,e){var a,n,i=t.split("&");for(n=0;n