function initSlideShow(){jQuery(".slideshow").fadeGallery({slides:".slide",btnPrev:".btn-prev",btnNext:".btn-next",pagerLinks:".pagination li",event:"click",autoRotation:!1,autoHeight:!0,switchTime:3e3,animSpeed:500})}$(document).ready(function(){function s(){let t=$("#main-image").attr("src").replace("/large/","/xl/"),i=$("#main-image").attr("alt");$("#detail-image").attr("src",t).attr("alt",i);$("#detail-image").removeClass("hidden");$("#detail-page").addClass("hidden");var n="scale(1.2)";document.body.style.webkitTransform=n;document.body.style.msTransform=n;document.body.style.transform=n;console.log(document.body.style.webkitTransform)}function h(n){n.src.includes("svg+xml")&&(n.src=n.dataset.src)}var n=$("#ColorId").length>0,t=$("#SizeId").length>0,r,i,o;$("body").on("click","#add-to-cart",function(i){var o,f,u,s;i.preventDefault();var u=$("#ColorId").val(),f=$("#SizeId").val(),e=!1;n&&u.length>0&&t&&f.length>0?e=!0:n&&u.length>0&&!t?e=!0:t&&f.length>0&&!n?e=!0:n||t||(e=!0);e?(o=$(this),o.addClass("disabled").attr("disabled","disabled"),f=$("#SizeId").val(),f===null&&(f=0),u=$("#ColorId").val(),u===null&&(u=0),s="/cart/add-to-cart/"+productId+"/"+f+"/"+u,window.location=s):r()});r=function(){var i=$("#ColorId").val(),r=$("#SizeId").val();n&&i.length==0?$(".color-select-error").removeClass("hide"):n&&i.length>0&&$(".color-select-error").addClass("hide");t&&r.length==0?$(".size-select-error").removeClass("hide"):t&&r.length>0&&$(".size-select-error").addClass("hide");n&&i.length==0?$("html, body").animate({scrollTop:$("#color-selection-display").offset().top-200},500):t&&r.length==0&&$("html, body").animate({scrollTop:$("#size-selection-display").offset().top-200},500)};$("body").on("click","#toggle-wish-list",function(n){n.preventDefault();var i=$(this),t=parseInt($("#wishlist-count-big").html());i.is(".on")?(i.removeClass("on"),$.get("/cart/remove-from-wish-list/"+productId,function(){$("#wishlist-count-big").html(t-1);$("#wishlist-count-small").html(t-1);$("#wishlist-text").html("Save To Fav")})):(i.addClass("on"),$.get("/cart/add-to-wish-list/"+productId,function(){$("#wishlist-count-big").html(t+1);$("#wishlist-count-small").html(t+1);$("#wishlist-text").html("Remove Fav")}))});$(".thumb-hold a").on("click",function(){var n=$(this);$(".thumb-hold li.active").removeClass("active");n.parents("li").first().addClass("active");$("#image-name").html(n.data("colorname"));$(".thumbs-indicator-mobile .active").removeClass("active");$('.thumbs-indicator-mobile .mobile-thumb[data-index="'+n.data("index")+'"]').addClass("active");$("#current-thumb").html(parseInt(n.data("index"))+1);n.hasClass("video-thumb")?($("#main-image").addClass("hidden"),$("#main-video").removeClass("hidden")):($("#main-image").attr("alt",n.data("colorname")).attr("src",n.data("url")).removeClass("hidden"),$("#main-video").addClass("hidden"))});$("#main-image").on("swipeone",function(n,t){var i=$("ul.thumb-hold li.active"),r,u;t.direction.lastX<0?(r=i.next(":not(.video-thumb-container)"),r.length==0&&(r=$("ul.thumb-hold li").first()),i.removeClass("active"),r.find("a").click()):(u=i.prev(":not(.video-thumb-container)"),u.length==0&&(u=$("ul.thumb-hold li:not(.video-thumb-container)").last()),i.removeClass("active"),u.find("a").click())});$(".mobile-thumb-arrow").on("click tap",function(){var n=$("ul.thumb-hold li.active"),t,i;$(this).data("direction")=="prev"?(t=n.prev(":not(.video-thumb-container)"),t.length==0&&(t=$("ul.thumb-hold li:not(.video-thumb-container)").last()),n.removeClass("active"),t.find("a").click()):(i=n.next(":not(.video-thumb-container)"),i.length==0&&(i=$("ul.thumb-hold li").first()),n.removeClass("active"),i.find("a").click())});$("body").on("click",".color-selection-list-item",function(){var n=$(this),t,i;$(".color-selection-list-item").removeClass("selected");n.addClass("selected");$(".color-select-error").addClass("hide");t=n.data("colorid");i=n.data("colorname");$("#image-name").html(i);f(t,i);c(t);a(t);v(n.data("colornamesafe"));e()});$("body").on("click",".size-selection-list-item",function(){var n=$(this),t,r,i;$(".size-selection-list-item").removeClass("selected");n.addClass("selected");$(".size-select-error").addClass("hide");t=n.data("sizeid");r=n.data("sizename");l(t);u(t,r);e();i=parseFloat(n.data("price-adjustment"));i>0?$("#price-adjustment").html(" (+$"+i+")"):$("#price-adjustment").html("")});var c=function(n){var i=$.grep(Inventory,function(t){return t.ColorId===n}),f=$(".size-selection-list-item"),t,r;f.addClass("unavailable");$.each(i,function(n,t){$('.size-selection-list-item[data-sizeid="'+t.SizeId+'"]').removeClass("unavailable")});t=!1;r=parseInt($("#SizeId").val());$.each(i,function(n,i){i.SizeId===r&&(t=!0)});t||(u("",""),$("#size-selection-display").html(""),$(".color-selection-list-item").removeClass("unavailable"),$(".size-selection-list-item").removeClass("selected"))},l=function(n){var i=$.grep(Inventory,function(t){return t.SizeId===n}),t,r;$(".color-selection-list-item").addClass("unavailable");$.each(i,function(n,t){$('.color-selection-list-item[data-colorid="'+t.ColorId+'"]').removeClass("unavailable")});t=!1;r=parseInt($("#ColorId").val());$.each(i,function(n,i){i.ColorId===r&&(t=!0)});t||(f("",""),$("#color-selection-display").html(""),$(".size-selection-list-item").removeClass("unavailable"),$(".color-selection-list-item").removeClass("selected"))},a=function(n){$("#swatches img.selected").removeClass("selected");$("#swatches #swatch-color-id-"+n).addClass("selected")},v=function(n){$('.thumb-hold li a[data-colornamesafe="'+n+'"]').first().length===0?($("#main-image").attr("alt",n).attr("src","//d23gkft280ngn0.cloudfront.net/regular/nophoto.jpg"),$(".thumb-hold li").removeClass("active"),$(".thumb-hold li a").removeClass("gallery-active")):$('.thumb-hold li a[data-colornamesafe="'+n+'"]').first().click()},u=function(n,t){$("#SizeId").val(n);ColorsLoadedForSizeId=n;$("#size-selection-display").html(t)},f=function(n,t){$("#ColorId").val(n);SizesLoadedForColorId=n;$("#color-selection-display").html(t)},e=function(){var n=$("#ColorId").val(),t=$("#SizeId").val(),i;n.length>0&&t.length>0?(i="/cart/get-inventory-message/"+productId+"/"+n+"/"+t,$.get(i,function(n){$(".inventory-message").html(n.Message).removeClass("hide")})):$(".inventory-message").addClass("hide")},y=function(){var t=window.innerWidth,n;t>=768&&(n=$("#detail-title-mobile"),$("#detail-title-desktop").html(n.html()),$("#detail-title-mobile").remove())};y();i=function(n){var t=$(n);t.length==1&&t.first().click()};o=function(){i(".color-selection-list-item");i(".size-selection-list-item");var n=$("#main-image")};o();$("#open-sezzle-modal").on("click",function(){$.get("/info/getsezzlemodal",function(n){$("#sezzle-container").html(n);$("#product-detail-sezzle-modal").modal("show")})});$("#enlarge-photo").on("click",function(){s()});$("#main-image").on("click",function(){s()});$("#detail-image").on("click",function(){$(this).addClass("hidden");$("#detail-page").removeClass("hidden");var n="scale(1)";document.body.style.webkitTransform=n;document.body.style.msTransform=n;document.body.style.transform=n});let p=200;window.lazyLoadImages=function(){let n=[...document.querySelectorAll(".lazy-load")];n.forEach(n=>{n.offsetTop li",activeClass:"active",disabledClass:"disabled",btnPrev:"a.btn-prev",btnNext:"a.btn-next",generatePagination:!1,pagerList:"