window.isMobile=!1;if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){window.isMobile=!0}
window.browserLang=(window.navigator.userLanguage||window.navigator.language).toUpperCase().slice(0,2);window.tildaBrowserLang=window.browserLang;function t_throttle(fn,threshhold,scope){var last;var deferTimer;threshhold||(threshhold=250);return function(){var context=scope||this;var now=+new Date();var args=arguments;if(last&&now<last+threshhold){clearTimeout(deferTimer);deferTimer=setTimeout(function(){last=now;fn.apply(context,args)},threshhold)}else{last=now;fn.apply(context,args)}}}
function t228__init(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var menuBlock=rec.querySelector('.t228');var mobileMenu=rec.querySelector('.t228__mobile');var menuSubLinkItems=rec.querySelectorAll('.t-menusub__link-item');var rightBtn=rec.querySelector('.t228__right_buttons_but .t-btn');var mobileMenuPosition=mobileMenu?mobileMenu.style.position||window.getComputedStyle(mobileMenu).position:'';var mobileMenuDisplay=mobileMenu?mobileMenu.style.display||window.getComputedStyle(mobileMenu).display:'';var isFixedMobileMenu=mobileMenuPosition==='fixed'&&mobileMenuDisplay==='block';var overflowEvent=document.createEvent('Event');var noOverflowEvent=document.createEvent('Event');overflowEvent.initEvent('t228_overflow',!0,!0);noOverflowEvent.initEvent('t228_nooverflow',!0,!0);if(menuBlock){menuBlock.addEventListener('t228_overflow',function(){t228_checkOverflow(recid)});menuBlock.addEventListener('t228_nooverflow',function(){t228_checkNoOverflow(recid)})}
rec.addEventListener('click',function(e){var targetLink=e.target.closest('.t-menusub__target-link');if(targetLink&&window.isMobile&&window.innerWidth<=980){if(targetLink.classList.contains('t-menusub__target-link_active')){if(menuBlock)menuBlock.dispatchEvent(overflowEvent)}else{if(menuBlock)menuBlock.dispatchEvent(noOverflowEvent)}}
var currentLink=e.target.closest('.t-menu__link-item:not(.tooltipstered):not(.t-menusub__target-link):not(.t794__tm-link):not(.t966__tm-link):not(.t978__tm-link):not(.t978__menu-link)');if(currentLink&&mobileMenu&&isFixedMobileMenu)mobileMenu.click()});Array.prototype.forEach.call(menuSubLinkItems,function(linkItem){linkItem.addEventListener('click',function(){if(mobileMenu&&isFixedMobileMenu)mobileMenu.click()})});if(rightBtn){rightBtn.addEventListener('click',function(){if(mobileMenu&&isFixedMobileMenu)mobileMenu.click()})}
if(menuBlock){menuBlock.addEventListener('showME601a',function(){var menuLinks=rec.querySelectorAll('.t966__menu-link');Array.prototype.forEach.call(menuLinks,function(menuLink){menuLink.addEventListener('click',function(){if(mobileMenu&&isFixedMobileMenu)mobileMenu.click()})})})}}
function t228_checkOverflow(recid){var rec=document.getElementById('rec'+recid);var menu=rec?rec.querySelector('.t228'):null;if(!menu)return;var mobileContainer=document.querySelector('.t228__mobile_container');var mobileContainerHeight=t228_getFullHeight(mobileContainer);var windowHeight=document.documentElement.clientHeight;var menuPosition=menu.style.position||window.getComputedStyle(menu).position;if(menuPosition==='fixed'){menu.classList.add('t228__overflow');menu.style.setProperty('height',(windowHeight-mobileContainerHeight)+'px','important')}}
function t228_checkNoOverflow(recid){var rec=document.getElementById('rec'+recid);if(!rec)return!1;var menu=rec.querySelector('.t228');var menuPosition=menu?menu.style.position||window.getComputedStyle(menu).position:'';if(menuPosition==='fixed'){if(menu)menu.classList.remove('t228__overflow');if(menu)menu.style.height='auto'}}
function t228_setWidth(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var menuCenterSideList=rec.querySelectorAll('.t228__centerside');Array.prototype.forEach.call(menuCenterSideList,function(menuCenterSide){menuCenterSide.classList.remove('t228__centerside_hidden')});if(window.innerWidth<=980)return;var menuBlocks=rec.querySelectorAll('.t228');Array.prototype.forEach.call(menuBlocks,function(menu){var maxWidth;var centerWidth=0;var paddingWidth=40;var leftSide=menu.querySelector('.t228__leftside');var rightSide=menu.querySelector('.t228__rightside');var menuList=menu.querySelector('.t228__list');var mainContainer=menu.querySelector('.t228__maincontainer');var leftContainer=menu.querySelector('.t228__leftcontainer');var rightContainer=menu.querySelector('.t228__rightcontainer');var centerContainer=menu.querySelector('.t228__centercontainer');var centerContainerLi=centerContainer?centerContainer.querySelectorAll('li'):[];var leftContainerWidth=t228_getFullWidth(leftContainer);var rightContainerWidth=t228_getFullWidth(rightContainer);var mainContainerWidth=mainContainer?mainContainer.offsetWidth:0;var dataAlign=menu.getAttribute('data-menu-items-align');var isDataAlignCenter=dataAlign==='center'||dataAlign===null;maxWidth=leftContainerWidth>=rightContainerWidth?leftContainerWidth:rightContainerWidth;maxWidth=Math.ceil(maxWidth);Array.prototype.forEach.call(centerContainerLi,function(li){centerWidth+=t228_getFullWidth(li)});if(mainContainerWidth-(maxWidth*2+paddingWidth*2)>centerWidth+20){if(isDataAlignCenter){if(leftSide)leftSide.style.minWidth=maxWidth+'px';if(rightSide)rightSide.style.minWidth=maxWidth+'px'}}else{if(leftSide)leftSide.style.minWidth=maxWidth+'';if(rightSide)rightSide.style.minWidth=maxWidth+''}
if(menuList&&menuList.classList.contains('t228__list_hidden'))menuList.classList.remove('t228__list_hidden')})}
function t228_getFullWidth(el){if(!el)return 0;var marginLeft=el.style.marginLeft||window.getComputedStyle(el).marginLeft;var marginRight=el.style.marginRight||window.getComputedStyle(el).marginRight;marginLeft=parseInt(marginLeft,10)||0;marginRight=parseInt(marginRight,10)||0;return el.offsetWidth+marginLeft+marginRight}
function t228_getFullHeight(el){if(!el)return 0;var marginTop=el.style.marginTop||window.getComputedStyle(el).marginTop;var marginBottom=el.style.marginBottom||window.getComputedStyle(el).marginBottom;marginTop=parseInt(marginTop,10)||0;marginBottom=parseInt(marginBottom,10)||0;return el.offsetHeight+marginTop+marginBottom}
function t450_showMenu(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var menu=rec.querySelector('.t450');var overlay=rec.querySelector('.t450__overlay');var menuElements=rec.querySelectorAll('.t450__overlay, .t450__close, a[href*="#"]');if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupShowed');document.body.classList.add('t450__body_menushowed');if(menu)menu.classList.add('t450__menu_show');if(overlay)overlay.classList.add('t450__menu_show');if(menu){menu.addEventListener('clickedAnchorInTooltipMenu',function(){t450_closeMenu(menu,overlay)})}
Array.prototype.forEach.call(menuElements,function(element){element.addEventListener('click',function(){if(element.closest('.tooltipstered, .t-menusub__target-link, .t794__tm-link, .t966__tm-link, .t978__tm-link'))return;if(element.href&&(element.href.substring(0,7)==='#price:'||element.href.substring(0,9)==='#submenu:'))return;t450_closeMenu(menu,overlay)})});document.addEventListener('keydown',function(e){if(e.keyCode===27){document.body.classList.remove('t390__body_popupshowed');var popups=document.querySelectorAll('.t390');Array.prototype.forEach.call(popups,function(popup){popup.classList.remove('t390__popup_show')})}});rec.addEventListener('click',function(e){if(e.target.closest('.t966__tm-link, .t978__tm-link')){t450_checkSize(recid);if(e.target.closest('.t978__tm-link')){setTimeout(function(){var hookLink=e.target.closest('.t978__tm-link');var menuBlock=hookLink.nextElementSibling;var submenuLinks=menuBlock?menuBlock.querySelectorAll('.t978__menu-link'):[];Array.prototype.forEach.call(submenuLinks,function(link){link.addEventListener('click',function(){t450_checkSize(recid)})})},300)}}});menu.addEventListener('menuOverflow',function(){t450_checkSize(recid)});t450_highlight(recid)}
function t450_closeMenu(menu,overlay){if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupHidden');document.body.classList.remove('t450__body_menushowed');if(menu)menu.classList.remove('t450__menu_show');if(overlay)overlay.classList.remove('t450__menu_show')}
function t450_checkSize(recid){var rec=document.getElementById('rec'+recid);var menu=rec?rec.querySelector('.t450'):null;if(!menu)return;var container=menu.querySelector('.t450__container');var topContainer=menu.querySelector('.t450__top');var rightContainer=menu.querySelector('.t450__rightside');setTimeout(function(){var topContainerHeight=topContainer?topContainer.offsetHeight:0;var rightContainerHeight=rightContainer?rightContainer.offsetHeight:0;var containerPaddingTop=container?window.getComputedStyle(container).paddingTop:'0';var containerPaddingBottom=container?window.getComputedStyle(container).paddingBottom:'0';containerPaddingTop=parseInt(containerPaddingTop,10);containerPaddingBottom=parseInt(containerPaddingBottom,10);if(topContainerHeight+rightContainerHeight+containerPaddingTop+containerPaddingBottom>document.documentElement.clientHeight){menu.classList.add('t450__overflowed')}else{menu.classList.remove('t450__overflowed')}})}
function t450_appearMenu(recid){var rec=document.getElementById('rec'+recid);var burger=rec?rec.querySelector('.t450__menu__content'):null;if(!burger)return;var burgerAppearOffset=burger?burger.getAttribute('data-appearoffset'):'';var burgerHideOffset=burger?burger.getAttribute('data-hideoffset'):'';if(burgerAppearOffset){burgerAppearOffset=t450_appearMenuParseNumber(burgerAppearOffset);if(window.pageYOffset>=burgerAppearOffset){if(burger.classList.contains('t450__beforeready')){burger.classList.remove('t450__beforeready')}}else{burger.classList.add('t450__beforeready')}}
if(burgerHideOffset){burgerHideOffset=t450_appearMenuParseNumber(burgerHideOffset);var scrollHeight=Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight);if(window.pageYOffset+window.innerHeight>=scrollHeight-burgerHideOffset){if(!burger.classList.contains('t450__beforeready')){burger.classList.add('t450__beforeready')}}else if(burgerAppearOffset){if(window.pageYOffset>=burgerAppearOffset){burger.classList.remove('t450__beforeready')}}else{burger.classList.remove('t450__beforeready')}}}
function t450_appearMenuParseNumber(string){if(string.indexOf('vh')>-1){string=Math.floor((window.innerHeight*(parseInt(string)/100)))}
return parseInt(string,10)}
function t450_initMenu(recid){var rec=document.getElementById('rec'+recid);var menu=rec?rec.querySelector('.t450'):null;var overlay=rec?rec.querySelector('.t450__overlay'):null;var burger=rec?rec.querySelector('.t450__burger_container'):null;var menuLinks=rec?rec.querySelectorAll('.t-menu__link-item.t450__link-item_submenu'):[];var hook=menu?menu.getAttribute('data-tooltip-hook'):'';if(hook){document.addEventListener('click',function(e){if(e.target.closest('a[href="'+hook+'"]')){e.preventDefault();t450_closeMenu(menu,overlay);t450_showMenu(recid);t450_checkSize(recid)}})}
if(burger){burger.addEventListener('click',function(){t450_closeMenu(menu,overlay);t450_showMenu(recid);t450_checkSize(recid)})}
window.addEventListener('resize',function(){t450_checkSize(recid)});if(!window.isMobile)return;Array.prototype.forEach.call(menuLinks,function(link){link.addEventListener('click',function(){t450_checkSize(recid)})})}
function t450_highlight(recid){var url=window.location.href;var pathname=window.location.pathname;var hash=window.location.hash;if(url.substr(url.length-1)==='/'){url=url.slice(0,-1)}
if(pathname.substr(pathname.length-1)==='/'){pathname=pathname.slice(0,-1)}
if(pathname.charAt(0)==='/'){pathname=pathname.slice(1)}
if(pathname===''){pathname='/'}
var shouldBeActiveElements=document.querySelectorAll('.t450__menu a[href=\''+url+'\'], '+'.t450__menu a[href=\''+url+'/\'], '+'.t450__menu a[href=\''+pathname+'\'], '+'.t450__menu a[href=\'/'+pathname+'\'], '+'.t450__menu a[href=\''+pathname+'/\'], '+'.t450__menu a[href=\'/'+pathname+'/\']'+(hash?', .t450__menu a[href=\''+hash+'\']':''));var rec=document.getElementById('rec'+recid);var menuLinks=rec?rec.querySelectorAll('.t450__menu a'):[];Array.prototype.forEach.call(menuLinks,function(link){if(link.getAttribute('data-highlighted-by-user')!=='y')link.classList.remove('t-active')});Array.prototype.forEach.call(shouldBeActiveElements,function(link){link.classList.add('t-active')})}
function t923_init(recId){var rec=document.getElementById('rec'+recId);if(!rec)return;var container=rec.querySelector('.t923');if(!container)return;t923_unifyHeights(recId);window.addEventListener('resize',t_throttle(function(){t923_unifyHeights(recId)}));container.addEventListener('displayChanged',function(){t923_unifyHeights(recId)});window.addEventListener('load',function(){t923_unifyHeights(recId)});t_onFuncLoad('t_card__moveClickOnCard',function(){t_card__moveClickOnCard(recId)});t_onFuncLoad('t_card__addFocusOnTab',function(){t_card__addFocusOnTab(recId)})}
function t923_unifyHeights(recId){var rec=document.getElementById('rec'+recId);if(!rec)return;var container=rec.querySelector('.t923');if(!container)return;var cols=rec.querySelectorAll('.t923__col');var img=container.querySelector('.t923__imgwrapper');var imgHeight=img?img.offsetHeight:0;var maxContentHeight=0;for(var i=0;i<cols.length;i++){var col=cols[i];var colWrapper=col.closest('.t-card__col');var isInactive=!1;if(colWrapper.classList.contains('t-slds__item-innactive')){colWrapper.classList.remove('t-slds__item-innactive');isInactive=!0}
var colText=col.querySelector('.t923__textwrapper');var colBtn=col.querySelectorAll('.t-card__btn-wrapper, .t-card__btntext-wrapper')[0];var colContentHeight=colText.offsetHeight+(colBtn?colBtn.offsetHeight:0);if(isInactive){colWrapper.classList.add('t-slds__item-innactive');isInactive=!1}
if(colContentHeight>maxContentHeight)maxContentHeight=colContentHeight}
for(var i=0;i<cols.length;i++){cols[i].querySelector('.t923__content').style.height=0}
for(var i=0;i<cols.length;i++){var image=cols[i].querySelector('.t923__imgwrapper');var contentHeight=image?maxContentHeight:maxContentHeight+imgHeight;cols[i].querySelector('.t923__content').style.height=contentHeight+'px'}
t_onFuncLoad('t_slds_updateSlider',function(){t_slds_updateSlider(recId)})}
var t778_POPUP_SHOWED_EVENT_NAME='catalog:popupShowed';var t778_POPUP_CLOSED_EVENT_NAME='catalog:popupClosed';function t778__init(recid){t_onFuncLoad('t_prod__init',function(){t_prod__init(recid)});t778_initPopup(recid);t778__hoverZoom_init(recid);t778__updateLazyLoad(recid);t778__alignButtons_init(recid);var rec=document.getElementById('rec'+recid);if(!rec)return;var quantityBtns=rec.querySelectorAll('.t778__col .t-store__prod__quantity, .t778__product-full .t-store__prod__quantity');if(quantityBtns.length){t_onFuncLoad('t_store_addProductQuantityEvents',function(){t778_initProductQuantity(recid)})}
var event=document.createEvent('HTMLEvents');event.initEvent('twishlist_addbtn',!0,!1);document.body.dispatchEvent(event)}
function t778_initProductQuantity(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var productList=rec.querySelectorAll('.t778__col, .t778__product-full');Array.prototype.forEach.call(productList,function(product){t_store_addProductQuantityEvents(product)})}
function t778__showMore(recid){var rec=document.querySelector('#rec'+recid+' .t778');if(!rec)return;var cardsShowLimit=parseInt(rec.getAttribute('data-show-count'),10);if(isNaN(cardsShowLimit)||cardsShowLimit<=0)return;var showMoreButton=rec.querySelector('.t778__showmore');if(!showMoreButton)return;if(!showMoreButton.querySelector('td').textContent){showMoreButton.querySelector('td').textContent=t778__dict()}
showMoreButton.style.display='inline-block';var allProductCards=rec.querySelectorAll('.t778__col');Array.prototype.forEach.call(allProductCards,function(productCard){productCard.style.display='none'});var cardsNumber=allProductCards.length;t778__showSeparator(rec,cardsShowLimit);for(var i=0;i<cardsShowLimit;i++){if(allProductCards[i]){allProductCards[i].style.display='inline-block'}}
showMoreButton.addEventListener('click',function(){var currentColumns=rec.querySelectorAll('.t778__col');var currentColumnsShowed=0;Array.prototype.forEach.call(currentColumns,function(column){if(column.style.display==='inline-block'){++currentColumnsShowed}});for(var i=0;i<cardsShowLimit+currentColumnsShowed;i++){if(allProductCards[i]){allProductCards[i].style.display='inline-block'}}
t778__alignButtons(recid);var event=document.createEvent('HTMLEvents');event.initEvent('displayChanged',!0,!1);rec.dispatchEvent(event);if(cardsShowLimit+currentColumnsShowed>=cardsNumber){showMoreButton.style.display='none'}
t778__showSeparator(rec,cardsShowLimit+currentColumnsShowed);if(window.lazy==='y'||document.getElementById('allrecords').getAttribute('data-tilda-lazy')==='yes'){t_onFuncLoad('t_lazyload_update',function(){t_lazyload_update()})}})}
function t778__showSeparator(rec,cardsShowLimit){if(window.jQuery&&rec instanceof jQuery){rec=rec.get(0)}
var allSeparators=rec.querySelectorAll('.t778__separator_number');Array.prototype.forEach.call(allSeparators,function(separator){separator.classList.add('t778__separator_hide');if(separator.getAttribute('data-product-separator-number')<=cardsShowLimit){separator.classList.remove('t778__separator_hide')}})}
function t778__dict(){var dictionary={EN:'Load more',RU:'Загрузить еще',FR:'Charger plus',DE:'Mehr laden',ES:'Carga más',PT:'Carregue mais',UK:'Завантажити ще',JA:'もっと読み込む',ZH:'裝載更多',};var language=window.browserLang;return dictionary[language]?dictionary[language]:dictionary.EN}
function t778__hoverZoom_init(recid){if(window.isMobile)return;var rec=document.getElementById('rec'+recid);if(!rec)return;try{if(!rec.querySelector('[data-hover-zoom]')){return}
var hoverScript='https://static.tildacdn.com/js/tilda-hover-zoom-1.0.min.js';if(document.querySelector("script[src^='"+hoverScript+"']")){t_onFuncLoad('t_hoverZoom_init',function(){t_hoverZoom_init(recid)})}else{var script=document.createElement('script');script.type='text/javascript';script.src=hoverScript;script.onload=function(){setTimeout(function(){t_hoverZoom_init(recid)},500)};script.onerror=function(error){console.log('Upload script error: ',error)};document.head.appendChild(script)}}catch(error){console.log('Zoom image init error: '+error.message)}}
function t778__updateLazyLoad(recid){var scrollContainer=document.querySelector('#rec'+recid+' .t778__container_mobile-flex');var tRecords=document.querySelector('.t-records');if(!tRecords)return;var currentMode=tRecords.getAttribute('data-tilda-mode');var colFixed=document.querySelector('#rec'+recid+' .t778__col_fixed');var allRecords=document.getElementById('allrecords');var scrollFunc=t_throttle(function(){if(window.lazy==='y'||(allRecords&&allRecords.getAttribute('data-tilda-lazy')==='yes')){t_onFuncLoad('t_lazyload_update',function(){t_lazyload_update()})}});if(currentMode!=='edit'&&currentMode!=='preview'){if(scrollContainer)scrollContainer.addEventListener('scroll',scrollFunc);if(colFixed){var popup=document.querySelector('#rec'+recid+' .t-popup');if(popup)popup.addEventListener('scroll',scrollFunc)}}}
function t778__alignButtons_init(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;if(!rec.querySelector('[data-buttons-v-align]')){return}
try{t778__alignButtons(recid);if(document.querySelector('.t-records').getAttribute('data-tilda-mode')==='edit'){setInterval(function(){t778__alignButtons(recid)},200)}
window.addEventListener('resize',t_throttle(function(){if(window.noAdaptive&&window.noAdaptive&&window.isMobile){return}
t778__alignButtons(recid)}));var wrapperBlock=rec.querySelector('.t778');if(wrapperBlock){wrapperBlock.addEventListener('displayChanged',function(){t778__alignButtons(recid)})}
if(window.isMobile){window.addEventListener('orientationchange',function(){t778__alignButtons(recid)})}}catch(error){console.log('buttons-v-align error: '+error.message)}}
function t778__alignButtons(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var contents=rec.querySelectorAll('.t778__content');var maxHeight=0;var maxHeightBtns=0;var container=rec.querySelector('.t-container');if(container){var itemsInRow=parseInt(container.getAttribute('data-blocks-per-row'),10)}
var mobileView=window.innerWidth<=480;var tableView=window.innerWidth<=960&&window.innerWidth>480;var mobileOneRow=window.innerWidth<=960&&rec.querySelector('.t778__container_mobile-flex');var mobileTwoItemsInRow=window.innerWidth<=480&&rec.querySelector('.t778 .mobile-two-columns');if(mobileView){itemsInRow=1}
if(tableView){itemsInRow=2}
if(mobileTwoItemsInRow){itemsInRow=2}
if(mobileOneRow){itemsInRow=999999}
var count=1;var textWrappersInRow=[];var btnWrappersInRow=[];Array.prototype.forEach.call(contents,function(content){var textWrapper=content.querySelector('.t778__textwrapper');if(textWrapper){textWrapper.style.height='auto';if(itemsInRow===1){textWrapper.style.height='auto'}else{textWrappersInRow.push(textWrapper);if(textWrapper.offsetHeight>maxHeight){maxHeight=textWrapper.offsetHeight}
if(maxHeight>0){Array.prototype.forEach.call(textWrappersInRow,function(textWrapper){textWrapper.style.height=maxHeight+'px'})}}}
var btnWrapper=content.querySelector('.t778__btn-wrapper');if(btnWrapper){btnWrapper.style.marginTop='';if(itemsInRow===1){btnWrapper.style.marginTop=''}else{btnWrappersInRow.push(btnWrapper);if(btnWrapper.offsetHeight>maxHeightBtns){maxHeightBtns=btnWrapper.offsetHeight}
Array.prototype.forEach.call(btnWrappersInRow,function(buttonWrapper){if(maxHeightBtns>buttonWrapper.offsetHeight){buttonWrapper.style.marginTop=maxHeightBtns-buttonWrapper.offsetHeight+'px'}})}}
if(count===itemsInRow){count=0;maxHeight=0;textWrappersInRow=[];maxHeightBtns=0;btnWrappersInRow=[]}
count++})}
function t778_initPopup(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var allPopupLinks=rec.querySelectorAll('[href^="#prodpopup"]');if(!allPopupLinks.length)return;var popup=rec.querySelector('.t-popup');popup.addEventListener('mousedown',function(event){var windowWidth=window.innerWidth;var maxScrollBarWidth=17;var windowWithoutScrollBar=windowWidth-maxScrollBarWidth;if(event.clientX>windowWithoutScrollBar){return}
if(event.target===this){t778_closePopup(document.body,popup)}});Array.prototype.forEach.call(allPopupLinks,function(popupLink){var product=popupLink.closest('.js-product');var productLid=product.getAttribute('data-product-lid');var productLinks=document.querySelectorAll('.r a[href$="#!/tproduct/'+recid+'-'+productLid+'"]');Array.prototype.forEach.call(productLinks,function(productLink){productLink.addEventListener('click',function(){if(rec.querySelector('[data-product-lid="'+productLid+'"]')){var linkToPopup=product.querySelector('[href^="#prodpopup"]');if(linkToPopup){var event=document.createEvent('HTMLEvents');event.initEvent('click',!0,!1);linkToPopup.dispatchEvent(event)}}})});popupLink.addEventListener('click',clickOnceHandler,{once:!0});function clickOnceHandler(event){event.preventDefault();t_onFuncLoad('t_sldsInit',function(){t_sldsInit(recid+' #t778__product-'+productLid)});popupLink.removeEventListener('click',clickOnceHandler,!1)}
popupLink.addEventListener('click',function(event){event.preventDefault();if(event.target.classList.contains('t1002__addBtn')||event.target.parentNode.classList.contains('t1002__addBtn')){return}
t778_showPopup(recid);Array.prototype.forEach.call(popup.querySelectorAll('.js-product'),function(product){product.style.display='none'});var productFull=popup.querySelector('.js-product[data-product-lid="'+productLid+'"]');if(productFull){productFull.style.display='block'}
var analitics=popup.getAttribute('data-track-popup');if(analitics&&productFull&&window.Tilda){var productName=productFull.querySelector('.js-product-name');if(productName){var virtualTitle=productName.textContent;if(!virtualTitle){virtualTitle='prod'+productLid}
Tilda.sendEventToStatistics(analitics,virtualTitle)}}
var currentUrl=window.location.href;if(currentUrl.indexOf('#!/tproduct/')===-1&&currentUrl.indexOf('%23!/tproduct/')===-1){if(history.replaceState){window.history.replaceState('','',window.location.href+'#!/tproduct/'+recid+'-'+productLid)}}
t778_updateSlider(recid+' #t778__product-'+productLid);setTimeout(function(){if(window.lazy==='y'||document.getElementById('allrecords').getAttribute('data-tilda-lazy')==='yes'){t_onFuncLoad('t_lazyload_update',function(){t_lazyload_update()})}},500)})});if(!document.getElementById('record'+recid)){t778_checkUrl(recid)}
if(popup&&popup.hasAttribute('data-fixed-button')){t778_fixedPopupButton(recid)}}
function t778_checkUrl(recid){var currentUrl=window.location.href;var tprodIndex=(currentUrl.indexOf('#!/tproduct/')+1||currentUrl.indexOf('%23!/tproduct/')+1||currentUrl.indexOf('#%21%2Ftproduct%2F')+1||currentUrl.indexOf('#!%2Ftproduct%2F')+1||currentUrl.indexOf('%23%21%2Ftproduct%2F')+1)-1;if(tprodIndex!==-1){var currentUrl=currentUrl.substring(tprodIndex,currentUrl.length);var curProdLid=currentUrl.substring(currentUrl.indexOf('-')+1,currentUrl.length);if(curProdLid){var curProdLidMatch=curProdLid.match(/([0-9]+)/g);if(curProdLidMatch){curProdLid=curProdLidMatch[0]}}
if(currentUrl.indexOf(recid)===-1)return;var rec=document.getElementById('rec'+recid);if(!rec)return;if(currentUrl.indexOf(recid)!==0&&rec.querySelector('[data-product-lid="'+curProdLid+'"]')){var currentLink=rec.querySelector('[data-product-lid="'+curProdLid+'"] [href^="#prodpopup"]');var event=document.createEvent('HTMLEvents');event.initEvent('click',!0,!1);if(currentLink){currentLink.dispatchEvent(event)}}}}
function t778_updateSlider(recid){var rec=document.querySelector('#rec'+recid);if(!rec)return;t_onFuncLoad('t_slds_SliderWidth',function(){t_slds_SliderWidth(recid)});var sliderWrapper=rec.querySelector('.t-slds__items-wrapper');var slider=rec.querySelector('.t-slds__container');var paddingLeft=parseInt(slider.style.paddingLeft,10)||0;var paddingRight=parseInt(slider.style.paddingRight,10)||0;var sliderWidth=slider.clientWidth-(paddingLeft+paddingRight);var position=parseInt(sliderWrapper.getAttribute('data-slider-pos'),10);sliderWrapper.style.transform='translate3d(-'+sliderWidth*position+'px, 0, 0)';t_onFuncLoad('t_slds_UpdateSliderHeight',function(){t_slds_UpdateSliderHeight(recid)});t_onFuncLoad('t_slds_UpdateSliderArrowsHeight',function(){t_slds_UpdateSliderArrowsHeight(recid)})}
function t778_showPopup(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var popup=rec.querySelector('.t-popup');popup.style.display='block';setTimeout(function(){popup.querySelector('.t-popup__container').classList.add('t-popup__container-animated');popup.classList.add('t-popup_show');t_triggerEvent(popup,t778_POPUP_SHOWED_EVENT_NAME)},50);setTimeout(function(){if(window.lazy==='y'||document.getElementById('allrecords').getAttribute('data-tilda-lazy')==='yes'){t_onFuncLoad('t_lazyload_update',function(){t_lazyload_update()})}},300);if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupShowed');document.body.classList.add('t-body_popupshowed');var event=document.createEvent('HTMLEvents');event.initEvent('twishlist_addbtn',!0,!1);document.body.dispatchEvent(event);var closeButtons=document.querySelectorAll('.t-popup__close, .t778__close-text');Array.prototype.forEach.call(closeButtons,function(closeButton){closeButton.addEventListener('click',function(){t778_closePopup(document.body,popup)})});document.addEventListener('keydown',function(event){var isGalleryShowedOldLib=document.body.classList.contains('t-zoomer__show');if(isGalleryShowedOldLib)return;var isGalleryShowedNewLib=document.body.classList.contains('t-zoomer__active');if(isGalleryShowedNewLib)return;var isPopupShowed=document.body.classList.contains('t-body_popupshowed');if(!isPopupShowed)return;if(popup&&popup.classList.contains('t-popup_show')){if(event.key==='Escape'){t778_closePopup(document.body,popup)}}})}
function t778_closePopup(body,popup){if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupHidden');body.classList.remove('t-body_popupshowed');popup.classList.remove('t-popup_show');var event=document.createEvent('HTMLEvents');event.initEvent('twishlist_addbtn',!0,!1);body.dispatchEvent(event);var currentUrl=window.location.href;var indexToRemove=currentUrl.indexOf('#!/tproduct/');if(/iPhone|iPad|iPod/i.test(navigator.userAgent)&&indexToRemove!==-1){indexToRemove=currentUrl.indexOf('%23!/tproduct/')}
currentUrl=currentUrl.substring(0,indexToRemove);setTimeout(function(){popup.scrollTop=0;popup.style.display='none';if(history.replaceState){window.history.replaceState('','',currentUrl)}},300);t_triggerEvent(popup,t778_POPUP_CLOSED_EVENT_NAME)}
function t778__unifyHeights(recid){var rec=document.getElementById('rec'+recid);if(!rec)return;var container=rec.querySelector('.t778__container');if(!container)return;var blockPerRow=container.getAttribute('data-blocks-per-row');var cards=container.querySelectorAll('.t778__col .t778__wrapper');var mobileScroll=container.querySelectorAll('.t778__scroll-icon-wrapper').length;if(window.innerWidth<=480&&mobileScroll===0){Array.prototype.forEach.call(cards,function(card){card.style.height='auto'});return}
var perRow=parseInt(blockPerRow,10);if(window.innerWidth<=960&&mobileScroll>0){perRow=cards.length}else{if(window.innerWidth<=960){var perRow=2}}
for(var i=0;i<cards.length;i+=perRow){var maxHeight=0;for(var j=0;j<perRow;j++){if(cards[i+j]){var card=cards[i+j].querySelector('.t778__content');var txt=card.querySelector('.t778__textwrapper');var btns=card.querySelector('.t778__btn-wrapper');var height=0;if(txt){height+=txt.offsetHeight}
if(btns){height+=btns.offsetHeight}
if(height>maxHeight){maxHeight=height}}}
if(!maxHeight)continue;for(var j=0;j<perRow;j++){if(cards[i+j]){var card=cards[i+j].querySelector('.t778__content');card.style.height=maxHeight+'px'}}}}
function t778_fixedPopupButton(recId){var rec=document.getElementById('rec'+recId);if(!rec)return;var MOBILE_MAX_WIDTH=560;var popup=rec.querySelector('.t-popup');var popupContainer=popup.querySelector('.t-popup__container');var btnWrappers=rec.querySelectorAll('.t778__btn-wrapper');Array.prototype.forEach.call(btnWrappers,function(el){el.classList.add('t778__btn-wrapper-fixed')});function addStyle(){popupContainer.style.paddingBottom='90px';popupContainer.style.cssText+=';transform:none !important;'}
function resetStyle(){popupContainer.style.paddingBottom='';popupContainer.style.transform=''}
function handleResize(){if(window.innerWidth>MOBILE_MAX_WIDTH){resetStyle();return}
addStyle()}
if(window.isMobile){window.addEventListener('orientationchange',handleResize)}
popup.addEventListener(t778_POPUP_SHOWED_EVENT_NAME,function(){setTimeout(function(){handleResize()})});popup.addEventListener(t778_POPUP_CLOSED_EVENT_NAME,function(){resetStyle()});window.addEventListener('resize',handleResize)}
function t331_initPopup(recId){var rec=document.getElementById('rec'+recId);if(!rec)return!1;rec.setAttribute('data-animationappear','off');rec.style.opacity='1';var currentBlock=rec.querySelector('.t-popup');var currentHook=currentBlock?currentBlock.getAttribute('data-tooltip-hook'):'';var currentAnalitics=currentBlock?currentBlock.getAttribute('data-track-popup'):'';if(!currentHook)return!1;t_onFuncLoad('t_popup__addAttributesForAccessibility',function(){t_popup__addAttributesForAccessibility(currentHook)});document.addEventListener('click',function(e){var href=e.target.closest('a[href="'+currentHook+'"]');if(href){e.preventDefault();t331_showPopup(recId);t_onFuncLoad('t_popup__resizePopup',function(){t_popup__resizePopup(recId)});if(currentAnalitics){var virtTitle=currentHook;if(virtTitle.substring(0,7)==='#popup:')virtTitle=virtTitle.substring(7);Tilda.sendEventToStatistics(currentAnalitics,virtTitle)}}});t_onFuncLoad('t_popup__addClassOnTriggerButton',function(){t_popup__addClassOnTriggerButton(document,currentHook)})}
function t331_showPopup(recid){var rec=document.getElementById('rec'+recid);if(!rec)return!1;var popup=rec.querySelector('.t-popup');var video=rec.querySelector('.t-video-lazyload');var videoIframe=video.querySelector('iframe');if(!videoIframe){t_onFuncLoad('t_video_lazyload__addVideo',function(){t_video_lazyload__addVideo(video)})}
if(popup)popup.style.display='block';t331_setHeight(recid);setTimeout(function(){var popupContainer=popup?popup.querySelector('.t-popup__container'):null;if(popupContainer)popupContainer.classList.add('t-popup__container-animated');if(popup)popup.classList.add('t-popup_show');popup.focus();t_onFuncLoad('t_popup__trapFocus',function(){t_popup__trapFocus(popup)})},50);if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupShowed');document.body.classList.add('t-body_popupshowed');document.body.classList.add('t331__body_popupshowed');if(popup){popup.addEventListener('click',function(e){if(e.target===popup)t331_popup_close(recid)})}
var popupClose=popup?popup.querySelector('.t-popup__close'):null;if(popupClose){popupClose.addEventListener('click',function(){t331_popup_close(recid)})}
document.addEventListener('keydown',function(e){if(e.keyCode===27)t331_popup_close(recid)})}
function t331_popup_close(recid){if(typeof t_triggerEvent==='function')t_triggerEvent(document.body,'popupHidden');document.body.classList.remove('t-body_popupshowed');document.body.classList.remove('t331__body_popupshowed');var rec=document.getElementById('rec'+recid);if(!rec)return!1;var popup=rec.querySelector('.t-popup');if(popup)popup.classList.remove('t-popup_show');t_onFuncLoad('t_popup__addFocusOnTriggerButton',function(){t_popup__addFocusOnTriggerButton()});setTimeout(function(){var video=rec.querySelector('.t-video-lazyload');if(video){t_onFuncLoad('t_video_lazyload__removeVideo',function(){t_video_lazyload__removeVideo(video)})}
if(popup&&!popup.classList.contains('t-popup_show')){popup.style.display='none'}},300)}
function t331_setHeight(recid){var rec=document.getElementById('rec'+recid);if(!rec)return!1;var videoWrap=rec.querySelector('.t331__wrap-video');var videoLazy=rec.querySelector('.t-video-lazyload');var dataVideoWidth=videoWrap.getAttribute('data-video-width');var dataVideoHeight=videoWrap.getAttribute('data-video-height');var calculatedHeight=videoLazy.offsetWidth*0.5625;if(dataVideoHeight){if(dataVideoHeight.indexOf('vh')!==-1){dataVideoHeight=parseInt(dataVideoHeight,10)*window.innerHeight/100;var ratio=dataVideoHeight/(parseInt(dataVideoWidth,10)||1);var videoCurrentWidth=videoLazy.offsetWidth;calculatedHeight=videoCurrentWidth*ratio}else{calculatedHeight=parseInt(dataVideoHeight,10)}}
videoWrap.style.height=calculatedHeight+'px';videoLazy.style.height=calculatedHeight+'px'}
function t331_sendPopupEventToStatistics(popupname){var virtPage='/tilda/popup/';var virtTitle='Popup: ';if(popupname.substring(0,7)==='#popup:'){popupname=popupname.substring(7)}
virtPage+=popupname;virtTitle+=popupname;if(ga){if(window.mainTracker!=='tilda'){ga('send',{'hitType':'pageview','page':virtPage,'title':virtTitle})}}
if(window.mainMetrika>''&&window[window.mainMetrika]){window[window.mainMetrika].hit(virtPage,{title:virtTitle,referer:window.location.href})}}
function t959__init(recId){var rec=document.getElementById('rec'+recId);if(!rec)return;var container=rec.querySelector('.t959');if(!container)return;t959__updateLazyLoad(recId);t959_unifyHeights(recId);window.addEventListener('resize',t_throttle(function(){t959_unifyHeights(recId)}));window.addEventListener('load',function(){t959_unifyHeights(recId)});container.addEventListener('displayChanged',t_throttle(function(){t959_unifyHeights(recId)}));t_onFuncLoad('t_card__moveClickOnCard',function(){t_card__moveClickOnCard(recId)});t_onFuncLoad('t_card__addFocusOnTab',function(){t_card__addFocusOnTab(recId)})}
function t959__updateLazyLoad(recId){var allRecords=document.getElementById('allrecords');var container=document.querySelector('#rec'+recId+' .t959__container_mobile-flex');var mode=allRecords.getAttribute('data-tilda-mode');if(container&&mode!=='edit'&&mode!=='preview'&&window.isMobile){if(window.lazy==='y'||allRecords.getAttribute('data-tilda-lazy')==='yes'){t_onFuncLoad('t_lazyload_update',function(){container.addEventListener('touchmove',t_throttle(function(){t_lazyload_update()}))})}}}
function t959_unifyHeights(recId){var rec=document.getElementById('rec'+recId);if(!rec)return;var main=rec.querySelector('.t959');if(!main)return;var containers=main.querySelectorAll('.t959__container');for(var i=0;i<containers.length;i++){var container=containers[i];var cardsContent=container.querySelectorAll('.t959__card-content');var cards=container.querySelectorAll('.t959__card-inner');if(!cards.length){return}
var cardStyle=getComputedStyle(cards[0],null);var cardPaddingLeft=parseInt(cardStyle.paddingLeft)||0;var cardPaddingRight=parseInt(cardStyle.paddingRight)||0;var cardWidth=cards[0].clientWidth-(cardPaddingLeft+cardPaddingRight);var maxHeight=0;var ratio=container.getAttribute('data-ratio');var minHeightFromRatio=0;switch(ratio){case '16_9':minHeightFromRatio=cardWidth*0.5625;break;case '4_3':minHeightFromRatio=cardWidth*0.75;break;case '3_2':minHeightFromRatio=cardWidth*0.6666;break;case '1_1':minHeightFromRatio=cardWidth;break;case '2_3':minHeightFromRatio=cardWidth*1.5;break;case '3_4':minHeightFromRatio=cardWidth*1.3333;break;case '9_16':minHeightFromRatio=cardWidth*1.7777;break}
for(var j=0;j<cardsContent.length;j++){var cardContent=cardsContent[j];var titleHeight=t959_outerHeight(cardContent.querySelector('.t-card__title'));var descHeight=t959_outerHeight(cardContent.querySelector('.t-card__descr'));var colHeight=titleHeight+descHeight;if(colHeight>maxHeight)maxHeight=colHeight}
if(maxHeight>minHeightFromRatio){for(var j=0;j<cards.length;j++){cards[j].style.paddingBottom=maxHeight+'px'}}else{for(var j=0;j<cards.length;j++){cards[j].style.paddingBottom=null}}}}
function t959_outerHeight(element){if(!element)return 0;var height=element.offsetHeight;var style=getComputedStyle(element);height+=parseInt(style.marginTop)+parseInt(style.marginBottom);return height}
window.requestAnimationFrame=(function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(callback){window.setTimeout(callback,1000/60)}})();function t270_scroll(hash,offset){if(!hash)return;t270_checkLoad(hash,offset);if(hash.indexOf('#!/tproduct/')!==-1||hash.indexOf('#!/tab/')!==-1){return!0}
var isHistoryChangeAllowed=window.location.hash!==hash;var wrapperBlock=document.querySelector('.t270');var dontChangeHistory=wrapperBlock?Boolean(wrapperBlock.getAttribute('data-history-disabled')):!1;t270_scrollToEl(hash,offset);if(!dontChangeHistory&&isHistoryChangeAllowed){if(history.pushState){history.pushState(null,null,hash)}else{window.location.hash=hash}
isHistoryChangeAllowed=!1}
return!0}
function t270_checkLoad(hash,offset){if(window.t270_loadChecked)return;var sliderWrappers=document.body.querySelectorAll('.t-slds__items-wrapper');if(!sliderWrappers.length)return;var lastWrapper=sliderWrappers[sliderWrappers.length-1];var sliderImgs=lastWrapper?lastWrapper.querySelectorAll('.t-slds__bgimg'):[];var lastImg=sliderImgs[sliderImgs.length-1];var imageUrl=lastImg?window.getComputedStyle(lastImg).backgroundImage:'';imageUrl=imageUrl.substring(5,imageUrl.length-2);var preloaderImg=document.createElement('img');preloaderImg.src=imageUrl?imageUrl:'';preloaderImg.addEventListener('load',function(){t270_scroll(hash,offset);window.t270_loadChecked=!0})}
function t270_scrollToEl(hash,offset){if(document.body.getAttribute('data-scroll'))return;var scrollTargetY=t270_getTarget(hash,offset);if(isNaN(scrollTargetY))return;var body=document.body;var canSmoothScroll=window.CSS&&window.CSS.supports('scroll-behavior','smooth');if(window.isMobile&&canSmoothScroll&&'scrollBehavior' in document.documentElement.style){body.setAttribute('data-scroll','true');window.scrollTo({left:0,top:scrollTargetY,behavior:'smooth'});setTimeout(function(){body.removeAttribute('data-scroll')},500)}else{var html=document.querySelector('html');var documentHeight=Math.max(body.scrollHeight,body.offsetHeight,body.clientHeight,html.offsetHeight);var scrollY=window.scrollY||document.documentElement.scrollTop;var speed=2000;var time=Math.max(.1,Math.min(Math.abs(scrollY-scrollTargetY)/speed,.8));var currentTime=0;function t270_easeInQuad(pos){return Math.pow(pos,2)}
function t270_animationScroll(){currentTime+=1/60;var newDocumentHeight=Math.max(body.scrollHeight,body.offsetHeight,body.clientHeight,html.offsetHeight);if(documentHeight<newDocumentHeight){documentHeight=newDocumentHeight;scrollTargetY=t270_getTarget(hash,offset);scrollY=window.scrollY||document.documentElement.scrollTop;time=Math.max(.1,Math.min(Math.abs(scrollY-scrollTargetY)/speed,.8))}
var difference=currentTime/time;var animation=t270_easeInQuad(difference);if(difference<1){requestAnimationFrame(t270_animationScroll);window.scrollTo(0,scrollY+((scrollTargetY-scrollY)*animation))}else{body.removeAttribute('data-scroll');body.removeAttribute('data-scrollable');window.scrollTo(0,scrollTargetY)}}
body.setAttribute('data-scroll','true');body.setAttribute('data-scrollable','true');t270_animationScroll()}}
function t270_getTarget(hash,offset){var target;try{if(hash.substring(0,1)==='#'){target=document.getElementById(hash.substring(1))}else{target=document.querySelector(hash)}}catch(event){console.log('Exception t270: '+event.message);return}
if(!target){target=document.querySelector('a[name="'+hash.substr(1)+'"], div[id="'+hash.substr(1)+'"]');if(!target)return}
target=parseInt((target.getBoundingClientRect().top+window.pageYOffset)-offset,10);target=Math.max(target,0);return target}