function t136_init(e,t){var o=document.getElementById("rec"+e);if(o){if(t){if(void 0===window.isMobile){var r=Date.now();setTimeout((function o(){var n=Date.now();"boolean"!=typeof window.isMobile?"complete"===document.readyState&&n-r>1e3&&"boolean"!=typeof window.isMobile||setTimeout(o,100):t136_init(e,t)}))}var n=o.querySelectorAll(".txt-holder");Array.prototype.forEach.call(n,(function(e){e.style.backgroundColor="transparent"})),!1===window.isMobile&&window.sequenceController.registerNewBlock(o)}else{var n=o.querySelectorAll(".txt-holder"),i=o.querySelectorAll(".t136__background");Array.prototype.forEach.call(n,(function(e){e.style.top="",e.style.position="relative"})),Array.prototype.forEach.call(i,(function(e){e.style.height=window.sequenceController.itemHeight+"px"}))}if(window.isMobile){var l=o.querySelectorAll('[data-hook="item-background"]'),c=o.querySelectorAll('[data-hook="sequence-item"]');Array.prototype.forEach.call(l,(function(e){e.style.backgroundImage="url("+e.getAttribute("data-image-src")+")"})),Array.prototype.forEach.call(c,(function(e){e.querySelector("[data-hook='item-background']").style.height=window.sequenceController.itemHeight+"px",e.querySelector(".txt-holder").style.position="relative",e.querySelector(".txt-holder").style.backgroundColor="#000",e.style.backgroundColor="#000"}))}else{var s=o.querySelectorAll("div[data-content-video-url-youtube]");Array.prototype.forEach.call(s,(function(e){t_onFuncLoad("processYoutubeVideo",(function(){var t=window.getComputedStyle(e).height;processYoutubeVideo(e,t)}))}))}}}function SequenceController(){this.setScrollCb(),this.itemHeight=screen.availHeight;var e=.25;this.itemTransitionTop=this.itemHeight*e,this.activeItemIndex=null,this.windowHeight=document.documentElement.clientHeight||window.innerHeight||screen.availHeight,this.topOffsetShift=-150,$(window).resize(jQuery.proxy(this.recalculateAllSequencesOffsets,this)),this._resizeInterval=setInterval(jQuery.proxy(this.scrollCb,this),500)}function t_onFuncLoadVideo(e){"function"==typeof $.fn.videoBG?e():setTimeout((function t(){if("function"!=typeof $.fn.videoBG){if("complete"===document.readyState&&"function"!=typeof $.fn.videoBG)throw new Error("$.fn.videoBG is undefined");setTimeout(t,100)}else e()}))}window.processVideo=function(e){var t=$(e).attr("data-content-video-url-mp4"),o=$(e).attr("data-content-video-url-webm");$(e).css("background-color","transparent"),$(e).css("background-image","");var r={mp4:t,webm:o,preload:"none",autoplay:!1,loop:!0,scale:!0,zIndex:0,width:"100%"};t_onFuncLoadVideo((function(){var t=$(e).videoBG(r);videoLoadProcessor.registerNewVideo(t,{isNeedStop:!1})}))},SequenceController.prototype.defaultConfig={orientation:"vertical",speedFactor:1,automated:!1},SequenceController.prototype.sequenceObjects=[],SequenceController.prototype.recalculateAllSequencesOffsets=function(){this._resizeTimeout&&clearTimeout(this._resizeTimeout),this._resizeInterval&&clearInterval(this._resizeInterval),this._resizeTimeout=setTimeout(jQuery.proxy((function(){this.scrollCb(),this._resizeInterval=setInterval(jQuery.proxy(this.scrollCb,this),500)}),this),10)},SequenceController.prototype.registerNewBlock=function(e){if(!(e instanceof HTMLElement))throw new Error("Wrong node type in registerNewBlock");for(var t=0,o=this.sequenceObjects.length;tthis.itemTransitionTop){o=l;break}if(null!=o){(i=s.top/this.itemTransitionTop)>1?i=1:i<0&&(i=0);for(var l=0,c=t.length;l0&&r.bottom>r.height-o.sequenceHeight-100?this.processSequence(o):this.stopSequence(o)}},SequenceController.prototype.setScrollCb=function(){this._scrollCb=jQuery.proxy(this.scrollCb,this),$(window).scroll(this._scrollCb)},window.sequenceController=new SequenceController;