var yandex_ad_is_displayed=false,y5_iTestR=window.y5_iTestR||Math.round(Math.random()*1000000),y5_iR=window.y5_iR||Math.round(Math.random()*1000000),y5_aCheckVisibilityOff=[];if(!window.y5_isInit){var y5_isInit=false}if(typeof window.yandex_log_errors=="undefined"){window.yandex_log_errors=true}(function(){var C=[404,270],I=[243,243],A=[31235,20865,50157,47572,7412,27380,1452,50347,36098,45798,19636,6304,10808,13486,42392,50079,51704,49452,51292,45539,44969,48652,35739,29212,49674,38960,38913,43333,28969,12660,44052,21069,13260,4722,30292,25445,34044,51419,50580,17877,29923,41824,7149,19626,14786,46120,4866,24317,47166,40348,27013,28856,35011,26729,22436,36782,1993,2668,38452,26992,3721,37316,28599,36099,35414,18080,38941,30611,24166,17482,41236,29407,3569,41376,49354,31485,44634,2869,34160,44081,35526,21850,44415,30803,6498,37564,43556,31838,35738,24980,28655,16353,30107,40366,24134,23322,10141,50379,17908,2429,6588];oDocument=document,oWindow=window,oLocation=oWindow.location;function G(){var J='{"yandex_timeout":'+B()+"}";if(!oWindow.name){oWindow.name=J}}function E(){var J=oWindow.name.match(/"yandex_timeout":(\d+)/);if(J){return(J[1]*1)>B()-900000}return false}function B(){return(new Date()).getTime()}function F(){var N,J=oDocument.getElementsByTagName("meta");if(J&&J.length>0){for(var L=0,K=J.length;L<K;L++){if(J[L].content){var M=J[L].content.match(/charset=(.*)/);if(M){N=M[1];break}}}}else{N=oDocument.characterSet||oDocument.charset}return N}function D(){var O=(oWindow.yandex_partner_id)?parseInt(yandex_partner_id):0,M=(oWindow.yandex_stat_id)?parseInt(yandex_stat_id):0,P=(M!=0)?"&stat-id="+M:"",K=(oWindow.yandex_site_charset)?yandex_site_charset.toString():F(),N=(oWindow.y5_isTransform)?(oWindow.yandex_direct_limit?"&direct-limit="+parseInt(yandex_direct_limit):""):"&direct-limit=9",J=(oWindow.y5_isTransform&&oWindow.yandex_market_limit)?"&market-limit="+parseInt(yandex_market_limit):"",L=!(y5_iTestR%500)&&(!A.length||y5_isEntry(O,A));iFileStaticVersion=(L&&C[0])||I[0],iFileCssVersion=(L&&C[1])||I[1],sProtocol=oLocation.protocol,sFilePath=sProtocol+"//an.yandex.ru/resource/",sFileStaticUrl=sFilePath+"context_static_r"+iFileStaticVersion+".js",sFileCssUrl=sFilePath+"context_r"+iFileCssVersion+".css";setTimeout(function(){var Q=oDocument.getElementsByTagName("script"),R=Q?Q[Q.length-1]:null;if(R&&typeof (oWindow.yandex_isAdShowen)=="undefined"){R.parentNode.removeChild(R);G()}},8000);if(!E()){yandex_partner_id_old=O;if(L){y5_linkStyle(sFileCssUrl);y5_addScript(sFileStaticUrl)}else{y5_linkStyle(sFileCssUrl);y5_addScript(sFileStaticUrl);y5_addScript(sProtocol+"//an.yandex.ru/code/"+O+"?rnd="+y5_iR+P+N+J+"&charset="+K+"&block-origin=2&page-ref="+y5_escape(oDocument.referrer,512)+"&target-ref="+y5_escape(oLocation.href,512))}}}if((!oWindow.Ya||!oWindow.Ya.Context)&&!y5_isInit){D();y5_isInit=true}else{if(oWindow.Ya&&oWindow.Ya.Context){try{Ya.Context.init()}catch(H){}}else{if(oWindow.y5_sLinkHead){if(oWindow.yandex_partner_id==oWindow.yandex_partner_id_old){y5_defAdFormat()}}}}})();function y5_isEntry(D,A){for(var C=0,B=A.length;C<B;C++){if(D==A[C]){return true}}return false}function y5_linkStyle(A){document.write('<link rel="stylesheet" type="text/css" href="'+A+'" />')}function y5_addScript(A){document.write('<script type="text/javascript" src="'+A+'"><\/script>')}function y5_escape(B,A){if(!A){A=256}if(B==null){return""}if(B.length>A){B=B.substr(0,A)}return escape(B).replace(/\+/g,"%2B")};
