<!--[if mso]>
<v:image xmlns:v="urn:schemas-microsoft-com:vml" fill="true" stroke="false" style=" border: 0;display: inline-block; width: 600px; height: 210px;" src="/bg-main.jpg" />
<v:rect xmlns:v="urn:schemas-microsoft-com:vml" fill="true" stroke="false" style=" border: 0;display: inline-block;position: absolute; width: 600px; height: 210px;">
<v:fill opacity="0%" color="#000000" />
<v:textbox inset="0,0,0,0">
<![endif]-->
let hash = window.location.hash.substring(1);
// перевод хэша
let decode = decodeURI(hash);
var $findOption = $('.js-select-hash').children().filter(function () {
return $(this).text().trim() === decode;
});
if ($findOption.length) {
var $select = $findOption.parent();
$select.val(decode);
$select.trigger('change');
}
weight.on("click", function() {
var dataPrice = $(this).attr('data-price');
$(this).parents('.js-product-item').find(price).fadeOut(500, function (){
$(this).html(dataPrice);
$(this).fadeIn(500);
});
$(this).parents('.js-product-item').find('.js-price').removeClass('active-link');
$(this).addClass('active-link');
var src = $(this).attr('data-image');
$(this).parents('.js-product-item').find('.js-weight-img').fadeOut(300, function (){
$(this).attr('src', src );
$(this).fadeIn(300);
});
});
$(document).ready(function(){
$('.js-open-popup').bind("click", function(){
$(".js-popup-wrapper").fadeIn().addClass('active');
$(this).parent().addClass("active");
$(".js-popup-item[data-id='"+parseInt($(this).attr("data-id"))+"']").fadeIn().addClass('active');
});
$('.js-close-popup').bind("click", function(){
$(".js-popup-wrapper").fadeOut().removeClass('active');
$('.b-advantage__plus').removeClass('active');
$(".js-popup-item").fadeOut().removeClass('active');
});
});