!function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){!function(e,t,r){function o(t){var n=e[t];return e[t]=r,n}function a(e,t){return o("yandex_"+(t?t+"_":"")+e)}function i(e,t,n){for(var r=0;r<t.length;r++)e[t[r]]=a(t[r],n)}var c=n(1),s=n(2),d=e.Ya=e.Ya||{};d.loaderVer||(d.codeVer=new c(s.code).getId(),d.loaderVer=s.loader,d.matchVer=s.match,d.confirmVer=s.confirm),d.Context||(d.Context={_callbacks:[],_asyncIdCounter:0,_asyncModeOn:!1,initTime:Number(new Date),longExp:new c([{id:"CONTROL",percent:5},{id:"CONFIRM_BY_CLICK",percent:10},{id:"VIDEO_MANUAL",percent:5},{id:"VIDEO_AUTOPLAY",percent:5},{id:"APP_RATING",percent:5},{id:"APP_BUTTON",percent:5}]),LOG_DIRECT:c.isPercent(1)},d.Direct={insertInto:function(e,t,n,r){d.Context._asyncModeOn||(d.Context._asyncModeOn=!0),d.Context.AdvManager?d.Context.AdvManager.renderDirect(e,t,n,r):d.Context._callbacks.push(function(){d.Context.AdvManager.renderDirect(e,t,n,r)})}});for(var _=["yandex_context_callbacks","yandexContextAsyncCallbacks"],l=0;l<_.length;l++){var u=o(_[l]);if(u){d.Context._asyncModeOn||(d.Context._asyncModeOn=!0);for(var f=0;f<u.length;f++)d.Context._callbacks.push(u[f])}}if(e.yandexContextSyncCallbacks)for(var u=o("yandexContextSyncCallbacks"),l=0;l<u.length;l++)d.Context._callbacks.push(u[l]);var x=["ad_format","site_bg_color","font_size","font_family","stat_id","no_sitelinks","search_text","search_page_number","lang"],p=["type","border_type","bg_color","border_radius","border_color","header_bg_color","title_color","text_color","url_color","hover_color","sitelinks_color","links_underline","limit","place","favicon","title_font_size","grab","c11n","geo_lat","geo_long","width","height"];if(e.yandex_ad_format){var h={};i(h,x),i(h,p,h.ad_format);var v=h.place;v&&t.getElementById(v)||(v="Ya_sync_"+d.Context._asyncIdCounter++,t.write('<div id="'+v+'"></div>'));var g=a("partner_id");d.Context._callbacks.push(function(){d.Context.AdvManager.renderDirect(g,v,h)})}var C="an.yandex.ru/resource/context_static_r"+d.codeVer+".js";if(t.getElementById(C)&&d.Context._init)return void d.Context._init();var y="https://"+C;if(d.Context._asyncModeOn){var m=t.createElement("script"),b=t.getElementsByTagName("script")[0];m.id=C,m.src=y,b.parentNode.insertBefore(m,b)}else t.write('<script type="text/javascript" src="'+y+'" id="'+C+'"></script>')}(window,window.document)},function(e,t,n){function r(e){this._coin=Math.random(),this._versions=this._prepare(e)}function o(e){return Number(e.toFixed(a))}var a=2;r.prototype={getId:function(){return this._get("id")},getExtra:function(){return this._get("extra")},_get:function(e){var t=this._choose();return t?t[e]:null},_prepare:function(e){for(var t,n=[],a=0,i=0;i<e.length;i++)t=o(r.toFraction(e[i].percent)+a),a=t,n.push({id:e[i].id,extra:e[i].extra,threshold:t});return n},_choose:function(){for(var e=0;e<this._versions.length;e++)if(this._coin<this._versions[e].threshold)return this._versions[e]}},r.toFraction=function(e){return o(e/100)},r.isPercent=function(e){return Math.random()<r.toFraction(e)},e.exports=r},function(e,t){e.exports={loader:1197,code:[{id:1197,percent:5},{id:1195,percent:95}],confirm:1071,match:1103}}]);