(function(){var b=[[549,512],[549,512]],t=[549,512],n=[];var q=this,B=document,j=q.location,l=j.protocol,s=false,A=Math.round,a=Math.random,o=1000000,k=25,z="//an.yandex.ru/resource/",y="yandex_log_errors",r="setAttribute",p="insertBefore",u="createElement",i="getElementsByTagName";q.yandex_ad_is_displayed=false;q.y5_iR=q.y5_iR||A(a()*o);q.y5_iTestR=q.y5_iTestR||A(a()*o);q.y5_escape=d;q.y5_isEntry=m;q.y5_addScript=f;q.y5_linkStyle=c;if(!s){h();s=true}else{try{Ya.Context.init()}catch(x){}}function h(){var F=(q.yandex_partner_id||0)*1,I=j.href.match(/yandex_test_code=(\d+)/)||!(A(a()*o)%k)&&(!n.length||m(F,n)),E=t;if(I&&I.length){E=b[(I[1]-1)]}else{if(I){E=a()<0.5?b[0]:b[1]}}var J=l+z+"context_static_r"+E[0]+".js",D=l+z+"context_r"+E[1]+".css",e=q.navigator||{};e.y5_ver=E;if(q[y]===undefined&&I){q[y]=true}if(q.yandex_context_callbacks){var H=B[u]("script"),C=B[u]("link"),G=B[i]("head")[0];H[r]("type","text/javascript");H[r]("src",J);C[r]("rel","stylesheet");C[r]("type","text/css");C[r]("href",D);G[p](H,G.firstChild);G[p](C,G.firstChild)}else{setTimeout(function(){var K=B[i]("script"),L=K?K[K.length-1]:null;if(L&&(!q.Ya||!q.Ya.Context)&&L.getAttribute("yandex_load_check")=="yes"){L.parentNode.removeChild(L);g()}},8000);if(!v()){c(D);f(J)}}}function w(){return(new Date()).getTime()}function g(){if(!q.name){q.name='{"yandex_timeout":'+w()+"}"}}function v(){var e=(q.name+"").match(/"yandex_timeout":(\d+)/);if(e){return e[1]+1>w()-900000}}function m(E,C){for(var D=0,e=C.length;D<e;D++){if(E==C[D]){return true}}return false}function c(e){B.write('<link rel="stylesheet" type="text/css" href="'+e+'" />')}function f(e){B.write('<script type="text/javascript" src="'+e+'" yandex_load_check=yes><\/script>')}function d(C,e){if(!C){return""}C=C.substr(0,e||256);return encodeURIComponent(C)}})();