function t937_init(e,t){var r=document.getElementById("rec"+e);if(r){var i=window.innerWidth,l=r.getAttribute("data-screen-min"),n=r.getAttribute("data-screen-max");if(l&&iparseInt(n,10))return!1;var o=r.querySelector(".t937__playlist-wrap"),a=r.querySelector(".t937__col_video"),s=t937_parseData(e),d,c=t937_getUrlParametrs(e).activeVideoId;t937_setSizes(e,t),t937_renderVideoCount(s,e,t),t937_renderPlaylist(s,c,e,t),t937_renderVideoFrame(s,c,e,t),a&&(a.style.height=""),o&&(o.style.visibility="visible"),t937_addEvents(e,t)}}function t937_getUrlParametrs(e){var t,r,i=window.location.hash;if(i&&-1===i.indexOf("#tlection="))t=e,r=1;else{var l=i.replace("#tlection=","").split("_");r=+e==+(t=l[0])?l[1]:1}return{activeRecId:t,activeVideoId:r}}function t937_parseData(e){var t=document.getElementById("rec"+e);if(t){var r=t?t.querySelector(".t937__data"):null,i=r?r.innerHTML:"",l=[];if(i)for(var n=(i=i.replace(/&/gi,"&")).split("\n"),o=0;o=960?(o&&(o.style.width=s+"px"),i&&(i.style.height=d+"px"),i&&(i.style.maxHeight=""),t.playlistWidth.length&&n&&(n.style.width=parseInt(t.playlistWidth,10)+"px")):(i&&(i.style.maxHeight=d+"px"),i&&(i.style.height=""),n&&(n.style.width=""),o&&(o.style.width=""))}function t937_translate(e){var t=[];t.videoTitle={RU:"Без названия",EN:"Untitled video",FR:"Vidéo sans titre",DE:"Video ohne Titel",ES:"Video sin título",PT:"Bez tytułu wideo",UK:"Відео без назви",JA:"無題の動画",ZH:"无标题的视频",PL:"Bez tytułu"},t.videoPart={RU:"видео",EN:"videos",FR:"vidéos",DE:"videos",ES:"videos",PT:"filmy",UK:"відео",JA:"ビデオ",ZH:"影片",PL:"video"},t.noData={RU:"Пожалуйста, добавьте хотя бы одно видео в плейлист",EN:"Please add at least one video to the playlist",UK:"Будь ласка, додайте хоча б одне відео в плейлист",PL:"Proszę dodać jeden filmik do listy"},t.wrongFormat={RU:"Пожалуйста, проверьте корректность заполненных данных",EN:"Please check that the data is filled in correctly",UK:"Будь ласка, перевірте коректність заповнених даних",PL:"Sprawdź poprawność danych"};var r=(window.navigator.userLanguage||window.navigator.language).toUpperCase().slice(0,2),i=document.getElementById("allrecords");if(i){var l=i.getAttribute("data-tilda-project-lang");l&&(r=l)}return void 0!==t[e]?void 0!==t[e][r]&&""!==t[e][r]?t[e][r]:t[e].EN:"Text not found #"+e}function t937_hex2rgb(e,t){var r,i=/var\((--uc-color-color-[a-zA-Z0-9]+),\s*([a-fA-F0-9#]+)\)/.exec(e),l=e;if(i&&i[1]){var n=i[1],o;l=window.getComputedStyle(document.body).getPropertyValue(n)||i[2]}var a=/^#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})$/i.exec(l),s;return a?"rgba("+a.slice(1).map((function(e){return parseInt(e,16)||0})).join(",")+","+t+")":"rgba(0,0,0,"+t+")"}function t937_addEvents(e,t){if(window.addEventListener("resize",t_throttle((function(){t937_setSizes(e,t)}))),"undefined"!=typeof jQuery)$(".t937").bind("displayChanged",(function(){t937_setSizes(e,t)}));else{var r=document.querySelectorAll(".t937");Array.prototype.forEach.call(r,(function(r){r.addEventListener("displayChanged",(function(){t937_setSizes(e,t)}))}))}var i=document.getElementById("rec"+e),l=i?i.querySelector(".t937__playlist-wrap"):null,n=i?i.querySelector(".t937__playlist-fade"):null;l&&l.addEventListener("scroll",(function(){var r,i,o,a;l.offsetHeight+l.scrollTop>=l.scrollHeight-30?n&&(n.style.backgroundImage=""):t937_renderFade(e,t.bgColor)}))}function t937_onVideoClick(e,t){var r=document.getElementById("rec"+t),i=r?r.querySelector(".t937__playlist"):null,l=i?i.dataVideoContent:null,n=i?i.dataPlaylistStyles:null;window.location.hash="tlection="+t+"_"+e,t937_renderPlaylist(l,e,t,n),t937_renderVideoFrame(l,e,t,n),t937_playVideo(t)}function t937_playVideo(e){var t=document.getElementById("rec"+e),r=t?t.querySelector(".t937__video-frame"):null;r&&r.classList.contains("t937__video-frame_youtube")&&r.addEventListener("load",(function(){var e="playVideo";r.contentWindow.postMessage('{"event":"command","func":"'+e+'","args":""}',"*")}))}"loading"!==document.readyState?document.body&&(document.body.style["-webkit-text-size-adjust"]="100%"):document.addEventListener("DOMContentLoaded",(function(){document.body&&(document.body.style["-webkit-text-size-adjust"]="100%")}));