(function(g,h,Y){function jb(a,b,c,d){function e(a){var b=(new Date).getTime();a&&b<a&&(da+=a-b+20);f.setTimeout(function(){e(b)},20,"timeCorrector")}function m(){var a=(new Date).getTime()+da;a<aa&&(a=aa+10);return aa=a}function l(){return Math.round((m()-ca)/50)}function ia(a,b){b=Math.max(0,Math.min(b,65535));f.mergeArrays(a,[b>>8,b&255])}function q(a,b){f.mergeArrays(a,[b&255])}function p(a,b){for(b=Math.max(0,b|0);127<b;)f.mergeArrays(a,[b&127|128]),b>>=7;f.mergeArrays(a,[b])}function r(a,b){255<
b.length&&(b=b.substr(0,255));f.mergeArrays(a,[b.length]);for(var c=0;c<b.length;c++)ia(a,b.charCodeAt(c))}function E(a,b){p(a,b.length);for(var c=0;c<b.length;c++)p(a,b.charCodeAt(c))}function A(a,b,c,d,e,f){for(var u;c&&(u=n.getElementSize(c))&&(!u[0]||!u[1]);)c=n.getElementParent(c);if(!c)return null;u=c[F];if(!u||0>u)return null;var m={mousemove:2,click:32,dblclick:33,mousedown:4,mouseup:30,touch:12}[b];if(!m)return null;var La=n.getElementXY(c);c=[];q(c,m);p(c,a);p(c,u);p(c,Math.max(0,d[0]-La[0]));
p(c,Math.max(0,d[1]-La[1]));/^mouse(up|down)|click$/.test(b)&&(a=e||f,q(c,2>a?1:a==(e?2:4)?4:2));return c}function Da(a,b,c,d){b=b[F];if(!b||0>b)return null;var e=[];q(e,31);p(e,a);p(e,b);p(e,c[0]);p(e,c[1]);q(e,0);q(e,0);q(e,d);return e}function K(a,b){var c=[];q(c,3);p(c,a);p(c,b[0]);p(c,b[1]);return c}function J(a,b,c){var d=[];c=c[F];if(!c||0>c)return null;q(d,16);p(d,a);p(d,b[0]);p(d,b[1]);p(d,c);return d}function Z(a,b,c){var d=[];q(d,28);p(d,a);p(d,b[0]);p(d,b[1]);p(d,c[0]);p(d,c[1]);return d}
function N(a,b,c,d){var e=[];q(e,5);p(e,a);ia(e,b);q(e,c);a=d[F];if(!a||0>a)a=0;p(e,a);return e}function P(a,b){var c,d;0==b.length?d=c="":100>=b.length?(c=b,d=""):200>=b.length?(c=b.substr(0,100),d=b.substr(100)):(c=b.substr(0,97),d=b.substr(b.length-97));var e=[];q(e,29);p(e,a);E(e,c);E(e,d);return e}function I(a){var b=[];q(b,27);p(b,a);return b}function x(a){var b=[];q(b,14);p(b,a);return b}function Y(a){var b=[];q(b,15);p(b,a);return b}function fa(a,b){var c=[];q(c,17);p(c,a);p(c,b[F]);return c}
function ha(a,b){var c=[];q(c,18);p(c,a);p(c,b[F]);return c}function L(a,b,c){var d=[];q(d,19);p(d,a);p(d,b[F]);r(d,String(c));return d}function ba(a){var b=a[F];if(!b||0>b||!/^INPUT|SELECT|TEXTAREA$/.test(a.nodeName)||!a.form||ja(a.form))return null;var c=n.getFormNumber(a.form);if(0>c)return null;var d;d="INPUT"==a.nodeName?{text:0,color:0,date:0,datetime:0,"datetime-local":0,email:0,number:0,range:0,search:0,tel:0,time:0,url:0,month:0,week:0,password:2,radio:3,checkbox:4,file:6,image:7}[a.type]:
{SELECT:1,TEXTAREA:5}[a.nodeName];if("number"!=typeof d)return null;for(var e=-1,u=a.form.elements,f=u.length,m=0,l=0;m<f;m++)if(u[m].name==a.name){if(u[m]==a){e=l;break}l++}if(0>e)return null;u=[];q(u,7);p(u,b);p(u,c);p(u,d);E(u,a.name||"");p(u,e);return u}function W(a,b){var c=n.getFormNumber(b);if(0>c)return null;for(var d=b.elements,e=d.length,u=[],m=0;m<e;m++)if(!n.isEmptyField(d[m])){var l=d[m][F];l&&0<l&&f.mergeArrays(u,[l])}d=[];q(d,11);p(d,a);p(d,c);p(d,u.length);for(c=0;c<u.length;c++)p(d,
u[c]);return d}function ma(){var a=[];q(a,13);return a}function w(a,b,c){a=a.apply(g,b);oa.append(a,c)}function G(a){if(a[F])a:{var b=l(),c=a[F];if(0<c){var d=[];a=n.getElementRegion(a);var e=wa[c],m=a[0]+"x"+a[1],f=a[2]+"x"+a[3];m!=e.pos&&(e.pos=m,q(d,9),p(d,b),p(d,c),p(d,a[0]),p(d,a[1]));f!=e.size&&(e.size=f,q(d,10),p(d,b),p(d,c),p(d,a[2]),p(d,a[3]));if(d.length){a=d;break a}}a=null}else{(c=n.getElementParent(a))&&G(c);a[F]=T;wa[T]={};T++;if(a.nodeName)if(c=+a[F],!isFinite(c)||0>=c)b=null;else{var d=
64,e=0,u=n.getElementParent(a),m=u&&u[F]?u[F]:0;0>m&&(m=0);var f=a.nodeName.toUpperCase(),g=lb[f];g||(d|=2);var h=n.getElementNeighborPosition(a);h||(d|=4);var v=n.getElementRegion(a);(u=u?n.getElementRegion(u):null)&&v[0]==u[0]&&v[1]==u[1]&&v[2]==u[2]&&v[3]==u[3]&&(d|=8);wa[c].pos=v[0]+"x"+v[1];wa[c].size=v[2]+"x"+v[3];a.id&&"string"==typeof a.id&&(d|=32);(u=n.calcTextChecksum(a))&&(d|=16);var z=n.calcAttribChecksum(a);z&&(e|=2);var k;b:{k=n.getElementChildren(n.getElementParent(a),a.tagName);for(var B=
0;B<k.length;B++)if((!k[B].id||"string"!=typeof k[B].id)&&n.calcAttribChecksum(k[B])==z&&n.calcTextChecksum(k[B])==u){k=!0;break b}k=!1}k&&(d|=1,b=n.calcChildrenChecksum(a));k=[];q(k,1);p(k,c);q(k,d);p(k,m);g?q(k,g):r(k,f);h&&p(k,h);d&8||(p(k,v[0]),p(k,v[1]),p(k,v[2]),p(k,v[3]));d&32&&r(k,a.id);u&&ia(k,u);d&1&&ia(k,b);q(k,e);z&&ia(k,z);b=k}else a[F]=-1,b=null;oa.append(b,void 0);a=ba(a)}oa.append(a,void 0)}function pa(a,b){var c=a&&n.classNameExists(a,"(ym-disable-keys|-metrika-nokeys)");b&&a&&(c=
c||!!n.getElementsByClassName("(ym-disable-keys|-metrika-nokeys)",a).length);return c}function ja(a){return a&&n.classNameExists(a,"(ym-disable-submit|-metrika-noform)")}function ka(a){var b=D.getTarget(a);if(b&&"SCROLLBAR"!=b.nodeName){if(/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(b.tagName))if(b[F])G(b);else{var c=b.form;if(c)for(var c=c.elements,d=c.length,e=0;e<d;e++)/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(c[e].tagName)&&!c[e][F]&&G(c[e]);else G(b)}else G(b);w(A,[l(),a.type,b,D.getPos(a),a.which,a.button])}}
function O(a){ka(a);a:{var b,c;if(g.getSelection){try{var d=g.getSelection()}catch(kb){break a}b=d.toString();c=d.anchorNode}else h.selection&&h.selection.createRange&&(a=h.selection.createRange(),b=a.text,c=a.parentElement());if("string"==typeof b){try{for(;c&&1!=c.nodeType;)c=c.parentNode}catch(kb){break a}c&&Ea(c)||pa(c,!0)||b==X||(X=b,w(P,[l(),b]))}}}function z(a){var b=m(),c=b-ea;if(!(10>c)){var d=D.getPos(a),e=Q[0]-d[0],f=Q[1]-d[1],e=e*e+f*f;0>=e||16>e&&100>c||20>c&&256>e||(ea=b,Q=d,ka(a))}}
function v(){var a=n.getDocumentScroll(),b=m();10>b-U||10>Math.abs(a[0]-R[0])&&10>Math.abs(a[1]-R[1])||(U=b,R=a,w(K,[l(),a]))}function B(a){if(a=D.getTarget(a)){var b=Math.random(),c=[a.scrollLeft,a.scrollTop];if(a.localId){if(b=M[a.localId],!b||10>Math.abs(c[0]-b[0])&&10>Math.abs(c[1]-b[1]))return}else{for(;M[b];)b=Math.random();a.localId=b}M[a.localId]=c;a!==h&&(G(a),w(J,[l(),c,a]))}}function H(){w(Z,[l(),n.getViewportSize(),n.getDocumentSize()])}function C(){w(ma,[],!0)}function la(a){return(a.shiftKey?
2:0)|(a.ctrlKey?4:0)|(a.altKey?1:0)|(a.metaKey?8:0)|(a.ctrlKey||a.altKey?16:0)}function Ea(a){return"INPUT"==a.tagName?"password"==a.type||a.name&&na.test(a.name)||a.id&&na.test(a.id):!1}function Ma(a,b,c){!(a=D.getTarget(a))||Ea(a)||pa(a)||(G(a),w(N,[l(),b,c,a]))}function Na(a){var b=a.keyCode,c=la(a);if({3:1,8:1,9:1,13:1,16:1,17:1,18:1,19:1,20:1,27:1,33:1,34:1,35:1,36:1,37:1,38:1,39:1,40:1,45:1,46:1,91:1,92:1,93:1,106:1,110:1,111:1,144:1,145:1}[b]||112<=b&&123>=b||96<=b&&105>=b||c&16)19==b&&4==
(c&-17)&&(b=144),Ma(a,b,c|16),ga=!1,f.setTimeout(function(){ga=!0},1),!(67==b&&c&4)||c&1||c&2||Fa()}function Oa(a){ga&&!V&&0!==a.which&&(Ma(a,a.charCode||a.keyCode,la(a)),V=!0,f.setTimeout(function(){V=!1},1))}function Fa(){S||(S=!0,X&&w(I,[l()]),f.setTimeout(function(){S=!1},1))}function Ga(){ra||(ra=!0,w(x,[l()]))}function sa(){ra&&(ra=!1,w(Y,[l()]))}function Pa(a){(!ra||a&&!a.fromElement)&&Ga()}function Qa(a){a&&!a.toElement&&sa()}function xa(a){if((a=D.getTarget(a))&&/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(a.tagName)){if(a[F])G(a);
else{var b=a.form;if(b)for(var b=b.elements,c=b.length,d=0;d<c;d++)/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(b[d].tagName)&&!b[d][F]&&G(b[d]);else G(a)}w(fa,[l(),a])}}function ya(a){(a=D.getTarget(a))&&/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(a.tagName)&&(G(a),w(ha,[l(),a]))}function za(a){if((a=D.getTarget(a))&&!Ea(a)&&!pa(a)&&/^INPUT|SELECT|TEXTAREA$/.test(a.tagName)){var b=/^(checkbox|radio)$/.test(a.type)?a.checked:a.value;G(a);w(L,[l(),a,b])}}function ta(a){if((a=D.getTarget(a))&&!ja(a)&&"FORM"==a.nodeName){for(var b=
a.elements,c=0;c<b.length;c++)n.isEmptyField(b[c])||G(b[c]);w(W,[l(),a],!0)}}function Ha(a){v();if(a.touches&&a.touches.length){var b=D.getTarget(a);if(b&&b!=h){G(b);for(var c=0;c<a.touches.length;c++)w(A,[l(),"touch",b,[a.touches[c].pageX,a.touches[c].pageY],0,0])}}}function Aa(a){var b=D.getTarget(a);if(b){var c;"wheel"==a.type?c=0<a.deltaY?1:0>a.deltaY?2:0:"mousewheel"==a.type&&(c=0<a.wheelDelta?2:0>a.wheelDelta?1:0);c&&(G(b),w(Da,[l(),b,D.getPos(a),c]))}}function Ra(a){(a=D.getTarget(a))&&"BODY"==
a.tagName&&oa.append([],!0)}var oa=new Ba({protocol:a,counterId:b,counterType:c,meta:{url:y().href,hitId:d,timezone:ua,timestamp:va}}),lb={A:1,ABBR:2,ACRONYM:3,ADDRESS:4,APPLET:5,AREA:6,B:7,BASE:8,BASEFONT:9,BDO:10,BIG:11,BLOCKQUOTE:12,BODY:13,BR:14,BUTTON:15,CAPTION:16,CENTER:17,CITE:18,CODE:19,COL:20,COLGROUP:21,DD:22,DEL:23,DFN:24,DIR:25,DIV:26,DL:27,DT:28,EM:29,FIELDSET:30,FONT:31,FORM:32,FRAME:33,FRAMESET:34,H1:35,H2:36,H3:37,H4:38,H5:39,H6:40,HEAD:41,HR:42,HTML:43,I:44,IFRAME:45,IMG:46,INPUT:47,
INS:48,ISINDEX:49,KBD:50,LABEL:51,LEGEND:52,LI:53,LINK:54,MAP:55,MENU:56,META:57,NOFRAMES:58,NOSCRIPT:59,OBJECT:60,OL:61,OPTGROUP:62,OPTION:63,P:64,PARAM:65,PRE:66,Q:67,S:68,SAMP:69,SCRIPT:70,SELECT:71,SMALL:72,SPAN:73,STRIKE:74,STRONG:75,STYLE:76,SUB:77,SUP:78,TABLE:79,TBODY:80,TD:81,TEXTAREA:82,TFOOT:83,TH:84,THEAD:85,TITLE:86,TR:87,TT:88,U:89,UL:90,VAR:91,NOINDEX:100},da=0,aa=0;e(0);var T=1,ea=0,Q=[0,0],U=0,R=[0,0],M={},na=/^(password|passwd|pswd)$/,ga=!0,V=!1,X="",S=!1,ra=!0,ca=m(),F="metrikaId_"+
Math.random(),wa={},Ca=":submit"+Math.random();if(!f.isMetrikaPlayer()){k.on(h,"mousemove",z);k.on(h,"click,dblclick,mousedown",ka);k.on(h,"mouseup",O);k.on(g,"scroll",v);if("onmousewheel"in h)k.on(h,"mousewheel",Aa);else k.on(h,"wheel",Aa);k.on(g,"beforeunload",C);if(!mb)k.on(g,"unload",C);k.on(g,"resize",H);k.on(h,"keydown",Na);k.on(h,"keypress",Oa);k.on(h,"copy",Fa);k.on(h,"touchmove,touchstart",Ha);if(h.body)k.on(h,"mouseleave",Ra);h.attachEvent&&!g.opera?(k.on(h,"focusin",Pa),k.on(h,"focusout",
Qa)):(k.on(g,"focus",Ga),k.on(g,"blur",sa),k.on(h,"blur",sa));h.addEventListener?(k.on(h,"scroll",B),k.on(h,"focus",xa),k.on(h,"blur",ya),k.on(h,"change",za),k.on(h,"submit",ta)):h.attachEvent&&(k.on(h,"focusin",xa),k.on(h,"focusout",ya),function(){for(var a=h.getElementsByTagName("form"),b=0;b<a.length;b++){for(var c=a[b].getElementsByTagName("*"),d=0;d<c.length;d++)if(/^INPUT|SELECT|TEXTAREA$/.test(c[d].tagName))k.on(c[d],"change",za);k.on(a[b],"submit",ta)}}());(function(){var a=h.getElementsByTagName("form");
if(a.length)for(var b=0;b<a.length;b++){var c=a[b].submit;if("function"==typeof c||"object"==typeof c&&/^\s*function submit\(\)/.test(String(c)))a[b][Ca]=c,a[b].submit=function(){ta({target:this});return this[Ca]()}}})();"0:0"!=n.getDocumentScroll().join(":")&&v();H()}return{start:function(){oa.activate()},stop:function(){oa.clear();k.un(h,"mousemove",z);k.un(h,"click,dblclick,mousedown",ka);k.un(h,"mouseup",O);k.un(h,"mousewheel",Aa);k.un(h,"wheel",Aa);k.un(g,"scroll",v);k.un(g,"beforeunload",C);
k.un(g,"unload",C);k.un(g,"resize",H);k.un(h,"keydown",Na);k.un(h,"keypress",Oa);k.un(h,"copy",Fa);k.un(h,"touchmove",Ha);k.un(h,"touchstart",Ha);h.body&&k.un(h,"mouseleave",Ra);k.un(h,"focusin",Pa);k.un(h,"focusout",Qa);k.un(g,"focus",Ga);k.un(g,"blur",sa);k.un(h,"blur",sa);h.removeEventListener?(k.un(h,"scroll",B),k.un(h,"focus",xa),k.un(h,"blur",ya),k.un(h,"change",za),k.un(h,"submit",ta)):h.detachEvent&&(k.un(h,"focusin",xa),k.un(h,"focusout",ya),function(){for(var a=h.getElementsByTagName("form"),
b=0;b<a.length;b++){for(var c=a[b].getElementsByTagName("*"),d=0;d<c.length;d++)/^INPUT|SELECT|TEXTAREA$/.test(c[d].tagName)&&k.un(c[d],"change",za);k.un(a[b],"submit",ta)}}());(function(){for(var a=h.getElementsByTagName("form"),b=0;b<a.length;b++)a[b][Ca]&&(a[b].submit=a[b][Ca])})()},uploadPages:function(a,b){function c(){k.un(h,"DOMContentLoaded",c);k.un(g,"load",c);for(var e=a.split(/\n/),m=y().href,f=/regexp:/,l=0;l<e.length;l++){var p=e[l];if(p)if(f.test(p)){p=Sa(p.replace(f,""));try{var v=
new RegExp(p)}catch(Hb){}if(v&&v.test(m)){d.uploadPage(b);break}}else if(-1!==m.indexOf(p)){d.uploadPage(b);break}}}var d=this;"complete"==h.readyState?c():(k.on(h,"DOMContentLoaded",c),k.on(g,"load",c))},uploadPage:t(function(e){if("function"==typeof g.toStaticHTML&&-1<g.toStaticHTML.toString().indexOf("NoScript"))return!1;var m=h.documentElement;if(m&&19E4<(""+m.innerHTML).length)return!1;var f=g.XMLHttpRequest?new g.XMLHttpRequest:new ActiveXObject("Msxml2.XMLHTTP"),l=n.getDocumentCharset(),p=
"text/html"+(l?";charset="+l:""),v=new nb({protocol:a,counterId:b,counterType:c});if("html"==e)return e=RegExp("<script [^>]*?//mc\\.yandex\\.ru/watch/.*?\x3c/script>","gi"),v.sendContent(n.getDocumentHTML().replace(e,""),p,d,ua,va),!0;f&&(f.open("get",y().href,!0),f.onreadystatechange=t(function(){if(4==f.readyState){var a=f.getResponseHeader("content-type")||"";l&&-1===a.indexOf("charset=")&&(a=p);v.sendContent(f.responseText,a,d,ua,va)}},"updatePage.1"),f.overrideMimeType&&l&&f.overrideMimeType(p),
f.send(null));return!0},"uploadPage")}}function t(a,b,c){return function(){try{return a.apply(this,arguments)}catch(d){c||Ta(d,b)}}}function Ta(a,b){var c;if(.01>Math.random())try{(new Q).log("jserrs",U,a.message,b,E.href,"","string"==typeof a.stack&&a.stack.replace(/\n/g,"\\n"))}catch(d){c=["cp: "+b,a.name+": "+a.message,"debug: ","code: "+U,"stack: "+a.stack],(new Image).src="//an.yandex.ru/jserr/101500?cnt-class=100&errmsg="+encodeURIComponent(c.join("; ").replace(/\r?\n/g,"\\n"))}}function ob(a,
b,c){return g.setTimeout(t(a,c||"setTimeout"),b)}function y(){for(var a={},b="hash host hostname href pathname port protocol search".split(" "),c=b.length,d=c,e,f;d--;)a[b[d]]="";try{for(e=g.location,d=c;d--;)f=b[d],a[f]=""+e[f]}catch(l){E&&(a=E)}return a}function Sa(a){return a?(""+a).replace(/^\s+/,"").replace(/\s+$/,""):""}function Ua(){return-1!=y().hostname.search(/(?:^|\.)(?:ya|yandex)\.(?:\w+|com\.\w+)$/)}function V(a){return-1!==(""+g.navigator.userAgent).toLowerCase().search(a)}function Va(a){return Sa(a&&
a.innerHTML&&a.innerHTML.replace(/<\/?[^>]+>/gi,""))}function Wa(a,b){var c,d;if(!a||!b)return!1;c=[];for(d=0;d<b.length;d++)c.push(b[d].replace(/\^/g,"\\^").replace(/\$/g,"\\$").replace(/\./g,"\\.").replace(/\[/g,"\\[").replace(/\]/g,"\\]").replace(/\|/g,"\\|").replace(/\(/g,"\\(").replace(/\)/g,"\\)").replace(/\?/g,"\\?").replace(/\*/g,"\\*").replace(/\+/g,"\\+").replace(/\{/g,"\\{").replace(/\}/g,"\\}"));return(new RegExp("\\.("+c.join("|")+")$","i")).test(a)}function pb(a){a=a.target||a.srcElement;
var b;if(!a)return!1;3==a.nodeType&&(a=a.parentNode);for(b=a&&a.nodeName&&a.nodeName.toString().toLowerCase();a&&a.parentNode&&a.parentNode.nodeName&&("a"!=b&&"area"!=b||!a.href);)b=(a=a.parentNode)&&a.nodeName&&a.nodeName.toString().toLowerCase();return a.href?a:!1}function qb(a,b){return(a?a.replace(/^www\./,""):"")==(b?b.replace(/^www\./,""):"")}function rb(a,b){function c(a){a=a.split(":");a=a[1]||"";a=a.replace(/^\/*/,"").replace(/^www\./,"");return a.split("/")[0]}return a&&b?c(a)==c(b):a||
b?!1:!0}function Xa(){var a=g.performance||g.webkitPerformance,b,c=[];if(a=a&&a.timing)if(b=a.navigationStart)for(c=[a.domainLookupEnd-a.domainLookupStart,a.connectEnd-a.connectStart,a.responseStart-a.requestStart,a.responseEnd-a.responseStart,a.fetchStart-b,a.redirectEnd-a.redirectStart,a.redirectCount],c.push(a.domInteractive&&a.domLoading?a.domInteractive-a.domLoading:null),c.push(a.domContentLoadedEventStart&&a.domContentLoadedEventEnd?a.domContentLoadedEventEnd-a.domContentLoadedEventStart:null),
c.push(a.domComplete?a.domComplete-b:null),c.push(a.loadEventStart?a.loadEventStart-b:null),c.push(a.loadEventStart&&a.loadEventEnd?a.loadEventEnd-a.loadEventStart:null),c.push(a.domContentLoadedEventStart?a.domContentLoadedEventStart-b:null),a=0;a<c.length;a++)b=c[a],null!==b&&(0>b||36E5<b)&&(c[a]=null);return c}function sb(a){var b=[],c=a._lastPerformanceTiming,d=Xa(),e,f;if(c)for(e=0,f=c.length;e<f;e++)null===d[e]?b.push(d[e]):b.push(c[e]===d[e]?"":d[e]);else b=d;a._lastPerformanceTiming=d;return b.join(",")}
function tb(){var a;if("object"==typeof g.chrome&&g.chrome.loadTimes){if(a=g.chrome.loadTimes(),a.requestTime&&a.firstPaintTime)return~~(1E3*(a.firstPaintTime-a.requestTime))}else if(g.performance&&g.performance.timing&&(a=g.performance.timing,a.navigationStart&&a.msFirstPaint))return a.msFirstPaint-a.navigationStart;return null}function ub(a){var b=h.referrer||"",c,d,e,m,l;if((new RegExp("^https?://"+E.host+"/")).test(b))return!1;c=a.patterns;for(m=0;m<c.length;m++)if(d=new RegExp(c[m],"i"),b.match(d))if(d=
a.params||[],d.length)for(e=f.safeDecodeURIComponent((RegExp.$1||"").replace(/\+/g,"%20")),l=0;l<d.length;l++){if(e==f.safeDecodeURIComponent(d[l]))return!0}else return!0;return!1}function Za(a,b){var c=!1,d,e,f,l;if(a&&"string"!=typeof a&&a.length)for(l=0;l<a.length;l++)if(d=a[l].selector,e=a[l].text,f=d.charAt(0),d=d.slice(1),"#"==f){if(f=h.getElementById(d))c=!0,b&&W.unshift([f,f.innerHTML]),f.innerHTML=e}else if("."==f)for(f=n.getElementsByClassName(d),d=0;d<f.length;d++){var c=!0,g=f[d],k=e;
b&&W.unshift([g,g.innerHTML]);g.innerHTML=k}return c}function $a(){var a;for(a=0;a<W.length;a++)W[a][0].innerHTML=W[a][1]}function vb(a,b){var c,d,e="",m,l,g;a=a&&a.replace(/^\?/,"");b=b&&b.replace(/^#/,"")||"";if(a)for(d=a.split("&"),c=0;c<d.length;c++)g=d[c].split("="),"_openstat"===g[0]&&(e=g[1]);m=b.split("?");for(c=0;c<m.length;c++)for(l=m[c].split("&"),d=0;d<l.length;d++)g=l[d].split("="),"_openstat"===g[0]&&(e=g[1]);e&&(e=-1<e.indexOf(";")?f.safeDecodeURIComponent(e):R.decode(J.decode(e.replace(/[-*_]/g,
function(a){return{"*":"+","-":"/",_:"="}[a]||a}))));return e&&(c=e.split(";"),4==c.length)?{service:c[0],campaign:c[1],ad:c[2],source:c[3]}:null}var f={mixin:function(a){var b,c;for(b=1;b<arguments.length;b++)if(arguments[b]){for(c in arguments[b])arguments[b].hasOwnProperty(c)&&(a[c]=arguments[b][c]);arguments[b].hasOwnProperty("toString")&&(a.toString=arguments[b].toString)}return a}},A=function(a){a=a||{};f.mixin(this,a);this._initComponent()};A.prototype._initComponent=function(){};A.inherit=
function(a){var b,c;a=a||{};b="function"==typeof this?this:Object;a.hasOwnProperty("constructor")||(a.constructor=function(){b.apply(this,arguments)});c=function(){};c.prototype=b.prototype;a.constructor.prototype=new c;f.mixin(a.constructor.prototype,a);a.constructor.prototype.constructor=a.constructor;a.constructor.superclass=b.prototype;a.constructor.inherit=A.inherit;return a.constructor};f.isArray=function(a){return"function"==typeof Array.isArray?Array.isArray(a):"[object Array]"==Object.prototype.toString.call(a)};
f.mergeArrays=function(a){var b,c,d=arguments.length,e;for(b=1;b<d;b++)if(e=arguments[b],f.isArray(e)||e&&"[object Arguments]"===e.toString())for(c=0;c<e.length;c++)a[a.length]=e[c];return a};f.getNativeFunction=function(a,b){var c;b=b||g;return(c=b.constructor&&b.constructor.prototype&&b.constructor.prototype[a]||b[a])&&"apply"in c?function(){return c.apply(b,arguments)}:function(){}};f.setTimeout=function(a,b,c){return f.getNativeFunction("setTimeout")(t(a,c||"setTimeout"),b)};f.defer=function(a,
b,c,d,e){return f.setTimeout(function(){a.apply(c,d||[])},b,e)};f.throttle=function(a,b,c,d){var e,m,l;return function(){m=arguments;l=this;e||function(){e=null;m&&(a.apply(c||l,m),m=null,e=f.setTimeout(arguments.callee,b,d))}()}};var ab=A.inherit({storage:null,storageKey:"dataBuffer",maxBufferSize:255,flushTimeout:1E4,active:!0,meta:null,onFlush:function(){},onFlushCtx:null,bufferExpireTime:864E5,_initComponent:function(){var a;ab.superclass._initComponent.apply(this,arguments);this._data=[];this._packetNumber=
0;this._flushTID=null;this._saveToStorageThrottled=f.throttle(this._saveToStorage,300,this,"DataBuffer._saveToStorage");this.storage&&((a=this.storage.get(this.storageKey))&&a.data&&a.meta&&a.time&&a.time+this.bufferExpireTime>+new Date&&this.onFlush.call(this.onFlushCtx||this,a.data,a.meta,a.pnum),this.clear())},append:function(a,b){f.mergeArrays(this._data,a);this._saveToStorageThrottled();this.active&&((b||this._data.length>=this.maxBufferSize)&&this._flush(),this._flushTID||(this._flushTID=f.defer(this._flush,
this.flushTimeout,this,[],"DataBuffer._flush")))},activate:function(){this.active||(this.active=!0,this.append([]))},clear:function(){this._data.length=0;this._flushTID=null;this.storage&&this.storage.remove(this.storageKey)},_flush:function(){this.onFlush.call(this.onFlushCtx||this,this._data,this.meta,this._packetNumber);this._packetNumber++;this.clear()},_saveToStorage:function(){this.storage&&this._data.length&&this.storage.set(this.storageKey,{data:this._data,meta:this.meta,pnum:this._packetNumber,
time:+new Date})}}),X=A.inherit({transports:[],postParams:[],dontSendRequests:!1,send:function(a,b,c,d){c=c||function(){};this.dontSendRequests?c.call(d):function m(f){var l;if(f<this.transports.length)try{l=new this.transports[f]({postParams:this.postParams}),l.request(a,b,function(a,b,l){a?c.call(d,b,l):m.call(this,f+1)},this)}catch(q){Ta(q,"send by "+(l&&l.id)),m.call(this,f+1)}}.call(this,0)}}),ma={stringify:function(a){var b=[],c,d,e;for(c in a)if(a.hasOwnProperty(c))if(d=a[c],f.isArray(d))for(e=
0;e<d.length;e++)b.push(encodeURIComponent(c)+"="+encodeURIComponent(String(d[e])));else b.push(encodeURIComponent(c)+"="+encodeURIComponent(String(d)));return b.join("&")}};f.forEachKey=function(a,b,c){for(var d in a)a.hasOwnProperty(d)&&b.call(c,d,a[d],a)};f.inArray=function(a,b){var c;for(c=0;c<a.length;c++)if(a[c]==b)return!0;return!1};var M=A.inherit({postParams:[],_buildUrl:function(a,b){var c=ma.stringify(b);return a+(-1<a.indexOf("?")?"&":c?"?":"")+c},_splitParams:function(a){var b={},c={};
f.forEachKey(a,function(a,e){f.inArray(this.postParams,a)?c[a]=e:b[a]=e},this);return{get:b,post:c}}}),S=M.inherit({id:"XHR",method:"POST",withCredentials:!0,request:function(a,b,c,d){var e,f;if(/[^a-z0-9.:-]/.test(E.host)&&g.opera&&"function"==typeof g.opera.version&&(e=g.opera.version(),"string"==typeof e&&"12"==e.split(".")[0]))return c.call(d,!1);if(g.XMLHttpRequest&&(f=new XMLHttpRequest,"withCredentials"in f)){b=this._splitParams(b);a=this._buildUrl(a,b.get);try{f.open(this.method,a,!0)}catch(l){return c.call(d,
!1)}f.withCredentials=this.withCredentials;this._setHeaders(f);f.send(this._preparePostParams(b));f.onreadystatechange=function(){4==f.readyState&&c.call(d,200==f.status,f.responseText)};return}c.call(d,!1)},setMethod:function(a){this.method=a},_preparePostParams:function(a){return ma.stringify(a.post)},_setHeaders:function(a){a.setRequestHeader("Content-Type","application/x-www-form-urlencoded")}});f.random=function(a,b){2>arguments.length&&(b=a,a=0);1>arguments.length&&(b=1073741824);return Math.floor(Math.random()*
(b-a))+a};var O=M.inherit({id:"form",enctype:"application/x-www-form-urlencoded",htmlfileOnly:!1,_initComponent:function(){O.superclass._initComponent.apply(this,arguments);"_htmlfile"in O.prototype||(O.prototype._htmlfile=this._createHtmlfile());this._doc=this._htmlfile||(this.htmlfileOnly?null:h)},request:function(a,b,c,d){var e=this._doc,m,l,g,h;if(!e)return c.call(d,!1);b=this._splitParams(b);m="ifr"+f.random();l=e.createElement("div");l.style.position="absolute";l.style.left="-99999px";l.style.top=
"-99999px";g=['<iframe name="',m,'"></iframe>','<form action="',this._buildUrl(a,b.get),'" method="post" target="',m,'" enctype="',this.enctype,'">'];f.forEachKey(b.post,function(a){f.mergeArrays(g,['<input type="hidden" autocomplete="off" autocorrect="off"',' autocapitalize="off" spellcheck="false" name="',a,'"/>'])});f.mergeArrays(g,["</form>"]);l.innerHTML=g.join("");e.body.appendChild(l);h=l.getElementsByTagName("form")[0];f.forEachKey(b.post,function(a,b){h[a].value=b});h.submit();f.setTimeout(function(){e.body.removeChild(l)},
1E4,"TransportForm.request.2");return c.call(d,!0)},_createHtmlfile:function(){var a;try{if(g.ActiveXObject)return a=new ActiveXObject("htmlfile"),a.open(),a.write("<html><body></body></html>"),a.close(),a}catch(b){}return null}}),wb=O.inherit({id:"htmlfile",htmlfileOnly:!0}),ca=M.inherit({id:"img",request:function(a,b,c,d){a=this._buildUrl(a,b);b=h.createElement("img");c=c||function(){};b.onload=t(function(){c.call(d,!0)},"TransportImage.request");b.onerror=t(function(){c.call(d,!1)},"TransportImage.request");
b.src=a}}),da={stringify:function(a){try{return JSON.stringify(a)}catch(b){return"null"}}};f.toJSON=function(a){var b,c,d;if(a===Y)return"";if(null===a)return"null";switch(a.constructor){case Boolean:return a.toString();case Number:return isFinite(a)?a.toString():"null";case String:return'"'+a.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r")+'"';case Array:b=[];c=0;for(d=a.length;c<d;c++)b[b.length]=f.toJSON(a[c]);return"["+b.join(",")+"]";case Object:b=[];for(c in a)a.hasOwnProperty(c)&&
a[c]!==Y&&(b[b.length]=f.toJSON(c)+":"+f.toJSON(a[c]));return"{"+b.join(",")+"}";default:da.stringify(a)}};var N=A.inherit({counterId:"",_initComponent:function(){N.superclass._initComponent.apply(this,arguments);this._ls=null;try{this._ls=g.localStorage}catch(a){}},set:function(a,b){if(this.isEnabled())try{!b||b&&f.isArray(b)&&!b.length?this.remove(a):this._ls.setItem(this._getLsKey(a),f.toJSON(b))}catch(c){}},get:function(a){if(this.isEnabled())try{return JSON.parse(this._ls.getItem(this._getLsKey(a)))}catch(b){}return null},
remove:function(a){if(this.isEnabled())try{this._ls.removeItem(this._getLsKey(a))}catch(b){}},isEnabled:function(){return this._ls&&g.JSON&&"object"==typeof this._ls&&"object"==typeof g.JSON},getStorageId:function(){var a=this.get("lsid");a||(a=Math.round(Math.random()*new Date),this.set("lsid",a));return a},clearStorageId:function(){this.remove("lsid")},_getLsKey:function(a){return"_ym"+this.counterId+"_"+a}}),P=A.inherit({counterId:"",onlyCurrentDomain:!1,skipPrefix:!1,_initComponent:function(){var a,
b;P.superclass._initComponent.apply(this,arguments);this._domain=null;if(!this.onlyCurrentDomain)for(a=E.host.split("."),b=2;;)if(b<=a.length){if(this._domain="."+a.slice(-b).join("."),b++,this.isEnabled())break}else{this._domain=null;break}},create:function(a,b,c){a=[this._prepareName(a)+"="+encodeURIComponent(b)];c&&(b=new Date,b.setTime(b.getTime()+6E4*c),a.push("expires="+b.toGMTString()));this._domain&&a.push("domain="+this._domain);a.push("path=/");try{h.cookie=a.join(";")}catch(d){}},read:function(a){var b;
try{b=h.cookie}catch(c){}return b&&b.match(new RegExp("(?:^|;\\s*)"+this._prepareName(a)+"=([^;]*)"))?decodeURIComponent(RegExp.$1):null},erase:function(a){this.create(a,"",-1)},isEnabled:function(){var a;this.create("metrika_enabled","1",60);a=!!this.read("metrika_enabled");this.erase("metrika_enabled");return a},_prepareName:function(a){return(this.skipPrefix?"":"_ym_")+a+(this.counterId?"_"+this.counterId:"")}});P.isEnabled=function(){return(new P({onlyCurrentDomain:!0})).isEnabled()};var K=X.inherit({protocol:"",
host:"mc.yandex.ru",resource:"",counterId:"",counterType:0,retry:!1,transports:[S,ca,wb],_initComponent:function(){K.superclass._initComponent.apply(this,arguments);this.retry&&(this._storage=new N)},send:function(a,b,c,d){var e=this._registerRequest(a,b);this._sendSavedRequest(e,a,b,c,d)},_sendSavedRequest:function(a,b,c,d,e){var m=g.Ya._metrika.firstReqStatus,l,h;if("process"==m)g.Ya._metrika.firstReqCallbacks=f.mergeArrays(g.Ya._metrika.firstReqCallbacks||[],[[this,arguments]]);else return m||
(g.Ya._metrika.firstReqStatus="process"),m={},this.counterType&&(m["cnt-class"]=this.counterType),f.mixin(m,b),c.st=Math.round((new Date).getTime()/1E3),c.u=K._userID,l=[this.protocol,"//",this.host,"/"+this.resource+"/"+this.counterId].join(""),h=[],c&&(f.forEachKey(c,function(a,b){"t"!=a&&f.mergeArrays(h,[a,b])}),c.t&&f.mergeArrays(h,["t",c.t])),h.length&&(m["browser-info"]=h.join(":")),K.superclass.send.call(this,l,m,function(){var b,c;g.Ya._metrika.firstReqStatus="complete";this._unregisterRequest(a);
b=g.Ya._metrika.firstReqCallbacks;g.Ya._metrika.firstReqCallbacks=null;if(b)for(c=0;c<b.length;c++)b[c][0]._sendSavedRequest.apply(b[c][0],b[c][1]);d&&d.apply(e,arguments)},this)},_isRetryEnabled:function(){return this.retry&&this._storage&&this._storage.isEnabled()},_registerRequest:function(a,b){var c,d;if(this._isRetryEnabled()){b.rqnl=b.rqnl||0;b.rqnl++;c=this._storage.get("retryReqs")||{};for(d=1;c[d];)d++;c[d]={protocol:this.protocol,host:this.host,resource:this.resource,counterId:this.counterId,
counterType:this.counterType,postParams:this.postParams,params:a,browserInfo:b,ghid:Ya._globalMetrikaHitId,time:+new Date};this._storage.set("retryReqs",c);return d}},_unregisterRequest:function(a){var b;a&&this._isRetryEnabled()&&(b=this._storage.get("retryReqs")||{},b[a]&&(delete b[a],this._storage.set("retryReqs",b)))}});K.initCookie=function(){var a=new P,b=a.read("uid");b||(b=Math.round((new Date).getTime()/1E3),b=b+""+f.random(),a.create("uid",b,1036800));K._userID=b};K.retransmit=function(){var a=
new N,b=a.get("retryReqs")||{},c;a.remove("retryReqs");f.forEachKey(b,function(a,b){g.Ya._metrika.firstReqStatus||(g.Ya._metrika.firstReqStatus="complete");b.ghid&&b.ghid!=Ya._globalMetrikaHitId&&b.time&&b.time+864E5>+new Date&&2>=b.browserInfo.rqnl&&(c=new K({protocol:b.protocol,host:b.host,resource:b.resource,counterId:b.counterId,counterType:b.counterType,postParams:b.postParams||[],retry:!0}),c.send(b.params,b.browserInfo))})};f.fletcher=function(a){for(var b=a.length,c=0,d=255,e=255,f,l,g;b;){f=
21<b?21:b;b-=f;do l="string"==typeof a?a.charCodeAt(c):a[c],c++,255<l&&(g=l>>8,l&=255,l^=g),d+=l,e+=d;while(--f);d=(d&255)+(d>>8);e=(e&255)+(e>>8)}a=(d&255)+(d>>8)<<8|(e&255)+(e>>8);return 65535==a?0:a};var J={abc:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",tail:"+/=",tailSafe:"*-_",encode:function(a,b){var c=(J.abc+(b?J.tailSafe:J.tail)).split(""),d=a.length,e=[],m=d-d%3,l,g;for(g=0;g<m;g+=3)l=(a[g]<<16)+(a[g+1]<<8)+a[g+2],f.mergeArrays(e,[c[l>>18&63],c[l>>12&63],c[l>>6&63],
c[l&63]]);switch(d-m){case 1:l=a[m]<<4;f.mergeArrays(e,[c[l>>6&63],c[l&63],c[64],c[64]]);break;case 2:l=(a[m]<<10)+(a[m+1]<<2),f.mergeArrays(e,[c[l>>12&63],c[l>>6&63],c[l&63],c[64]])}return e.join("")}};f.trim=function(a,b){a=String(a).replace(/^\s+|\s+$/g,"");b&&a.length>b&&(a=a.substr(0,b));return a};f.isFunction=function(a){return"function"===typeof a};f.isString=function(a){return"[object String]"==Object.prototype.toString.call(a)};f.arrayIndexOf=function(a,b){var c;for(c=0;c<a.length;c++)if(a[c]===
b)return c;return-1};f._playerRegexp=/^.+\.mtproxy\.yandex\.net$/;f.isMetrikaPlayer=function(){return"MetrikaPlayer"==g.name||this._playerRegexp.test(g.location.hostname)};var n={getDocumentCharset:function(){return(""+(h.characterSet||h.charset||"")).toLowerCase()},getRootElement:function(){var a=h.documentElement;return"CSS1Compat"==h.compatMode?a:h.body||a},getViewportSize:function(){var a=n.getRootElement();return[a.clientWidth,a.clientHeight]},getDocumentTitle:function(){var a=h.title;"string"!=
typeof a&&(a=(a=h.getElementsByTagName("title"))&&a.length?a[0].innerHTML:"");return a}},r={_silverlightVersion:"",getSilverlightVersion:function(){var a,b,c,d;if(!r._silverlightVersion)if(g.ActiveXObject)try{c=new ActiveXObject("AgControl.AgControl"),a=function(a,c,d,f){for(;b(a,c);)c[d]+=f;c[d]-=f},b=function(a,b){return a.isVersionSupported(b[0]+"."+b[1]+"."+b[2]+"."+b[3])},d=[1,0,0,0],a(c,d,0,1),a(c,d,1,1),a(c,d,2,1E4),a(c,d,2,1E3),a(c,d,2,100),a(c,d,2,10),a(c,d,2,1),a(c,d,3,1),r._silverlightVersion=
d.join(".")}catch(e){}else if(a=g.navigator,a=a.plugins&&a.plugins["Silverlight Plug-In"])r._silverlightVersion=a.description;return r._silverlightVersion||""},_flashVersion:0,getFlashVersion:function(){var a,b,c;if(!r._flashVersion)if(a=g.navigator,"undefined"!=typeof a.plugins&&"object"==typeof a.plugins["Shockwave Flash"]){if(b=a.plugins["Shockwave Flash"],c=b.version,(b=b.description)||c)if(a=a.mimeTypes,"undefined"==typeof a||!a["application/x-shockwave-flash"]||a["application/x-shockwave-flash"].enabledPlugin)c?
r._flashVersion=c:b&&(r._flashVersion=b.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,"."))}else if("undefined"!=typeof g.ActiveXObject)try{if(c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash"),b=c.GetVariable("$version"))r._flashVersion=b.split(" ")[1].replace(/,/g,".").replace(/[^.\d]/g,"")}catch(d){}return r._flashVersion},getLanguage:function(){return(g.navigator?navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage:"").toLowerCase()},getJavaEnabled:function(){try{return navigator.javaEnabled()}catch(a){return!1}}};
f.fnv32a=function(a){var b=2166136261,c,d;c=0;for(d=a.length;c<d;++c)b^=a.charCodeAt(c),b+=(b<<1)+(b<<4)+(b<<7)+(b<<8)+(b<<24);return b>>>0};r.getFingerPrint=function(){var a=[],b,c;if(navigator.plugins&&navigator.plugins.length)for(c=0;c<navigator.plugins.length;c++)b=navigator.plugins[c],f.mergeArrays(a,[b.name,b.version,b.description,b.filename]);if(navigator.mimeTypes&&navigator.mimeTypes.length)for(c=0;c<navigator.mimeTypes.length;c++)b=navigator.mimeTypes[c],f.mergeArrays(a,[b.type,b.description,
b.suffixes]);return f.fnv32a(a.join(";"))+"01"};r.getPlatform=function(){var a="";try{a=""+navigator.platform}catch(b){}return a};r.getNotificationPermission=function(){var a;try{a=Notification.permission}catch(b){}switch(a){case "denied":return 1;case "granted":return 2}};r.isIframe=function(){try{return g.top!=g.self}catch(a){return!1}};r._nMap={other:"0",none:"1",unknown:"2",wifi:"3",ethernet:"4",bluetooth:"5",cellular:"6",wimax:"7",mixed:"8"};r.netType=function(){var a=(navigator.connection||
{type:""}).type;return r._nMap[a]||a};r.isSafari=function(){try{return navigator.vendor&&-1<navigator.vendor.indexOf("Apple")&&navigator.userAgent&&!navigator.userAgent.match("CriOS")}catch(a){}return!1};n.removeNode=function(a){var b=a&&a.parentNode;b&&b.removeChild(a)};var bb={url:"https://mc.yandex.ru/metrika/",_value:null,init:function(){var a=this._getLs().read("isad");a?this._set(a):this._getReqStatus()||this._send()},getVal:function(){return this._value},_set:function(a){this._value="1"==a||
"2"==a?a:null},_send:function(){var a=h.createElement("img"),b=this;a.onload=function(){b._saveReq(!1);n.removeNode(this)};a.onerror=function(){b._saveReq(!0);n.removeNode(this)};this._setReqStatus("process");a.src=this.url+String.fromCharCode(97,100,118,101,114,116,46,103,105,102);r.isSafari()&&(a.style.position="absolute",a.style.visibility="hidden",a.style.width="0px",a.style.height="0px",n.getRootElement().appendChild(a))},_saveReq:function(a){this._value=a=a?"1":"2";this._setReqStatus("complete");
this._getLs().create("isad",a,1200)},_setReqStatus:function(a){try{g.Ya._metrika.adStatus=a}catch(b){}},_getReqStatus:function(){try{return g.Ya._metrika.adStatus}catch(a){return"complete"}},_getLs:function(){this._ls||(this._ls=new P);return this._ls}},R={encode:function(a){var b=[],c,d,e;c=0;for(e=a.length;c<e;c++)d=a.charCodeAt(c),128>d?b.push(d):(127<d&&2048>d?b.push(d>>6|192):(b.push(d>>12|224),b.push(d>>6&63|128)),b.push(d&63|128));return b},decode:function(a){for(var b="",c=0,d,e,f;c<a.length;)d=
a.charCodeAt(c),128>d?(b+=String.fromCharCode(d),c++):191<d&&224>d?(e=a.charCodeAt(c+1),b+=String.fromCharCode((d&31)<<6|e&63),c+=2):(e=a.charCodeAt(c+1),f=a.charCodeAt(c+2),b+=String.fromCharCode((d&15)<<12|(e&63)<<6|f&63),c+=3);return b}};J.decode=function(a,b){for(var c=J.abc+(b?J.tailSafe:J.tail),d=0,e="",f,g,h,k,p;a.length%4;)a+="=";do{f=c.indexOf(a.charAt(d++));g=c.indexOf(a.charAt(d++));k=c.indexOf(a.charAt(d++));p=c.indexOf(a.charAt(d++));if(0>f||0>g||0>k||0>p)return null;h=f<<18|g<<12|k<<
6|p;f=h>>16&255;g=h>>8&255;h&=255;e=64==k?e+String.fromCharCode(f):64==p?e+String.fromCharCode(f,g):e+String.fromCharCode(f,g,h)}while(d<a.length);return e};var aa=K.inherit({hitId:0,trackHash:!1,trimParams:!1,webvisor:!1,counter:null,counterNum:0,resource:"watch",retry:!0,postParams:["site-info"],countersNoTitle:"22836271 1143050 29626870 9928105 26128362 29850769".split(" "),fake:!1,sendTitle:!0,_initComponent:function(){aa.superclass._initComponent.apply(this,arguments);this._trackHash=this.trackHash;
"0"===""+this.counterType&&(this.sendTitle=-1===f.arrayIndexOf(this.countersNoTitle,""+this.counterId))},setTrackHash:function(a){this._trackHash=a},sendHit:function(a){this._hitExt({url:a.url,title:a.title,referrer:a.referrer,vParams:a.vParams,modes:{ar:!0,saveRef:!0,pv:!0},callback:a.callback,ctx:a.ctx})},sendExperiments:function(a){this._hitExt({url:y().href,title:"",referrer:"",modes:{ex:!0,ar:!0},experiments:a.experiments,callback:a.callback,ctx:a.ctx})},sendPrerenderHit:function(a){this._hitExt({url:a.url,
title:a.title,referrer:a.referrer,modes:{ar:!0,pq:!0}})},sendAjaxHit:function(a){this._hitExt({url:a.url,title:a.title,referrer:a.referrer,modes:a.modes})},sendParams:function(a,b,c){this._hitExt({url:y().href,title:"",referrer:"",vParams:a,modes:{ar:!0,pa:!0,onlyData:!0},callback:b,ctx:c})},sendGoal:function(a,b){var c,d,e;/[\/&=?#]/.test(a)||(c=a?"goal://"+y().hostname+"/"+encodeURIComponent(a):y().href,d=n.getDocumentTitle(),e=a?y().href:h.referrer,this._hitExt({url:c,title:d,referrer:e,vParams:b.vParams,
modes:{ar:!0},callback:b.callback,ctx:b.ctx}))},sendClickLink:function(a){this._hitExt({url:a.url,title:a.title,referrer:y().href,modes:a.modes})},sendExtLink:function(a){this._hitExt({url:a.url,title:a.title||"",referrer:y().href,vParams:a.vParams,modes:{ar:!0,ln:!0,ut:Ia},callback:a.callback,ctx:a.ctx})},sendFileUpload:function(a){this._hitExt({url:a.url,title:a.title||"",referrer:y().href,vParams:a.vParams,modes:{ar:!0,ln:!0,dl:!0},callback:a.callback,ctx:a.ctx})},sendNotBounce:function(a,b){this._hitExt({url:y().href,
title:"",referrer:"",modes:{cl:a,ar:!0,nb:!0,onlyData:!0},callback:b.callback,ctx:b.ctx})},sendDevice:function(a){this._hitExt({browserInfo:{di:a.data,dip:a.port},callback:a.callback,ctx:a.ctx})},_hitExt:function(a){function b(a,b){b&&(h[a]=b)}var c,d,e,g,l,h,k;f.isMetrikaPlayer()||(c=a.modes||{},d=a.browserInfo||{},g="undefined"!=typeof a.referrer?a.referrer:na.lastReferrer,l=a.url||"",h={},c.ar&&!c.onlyData&&(g=null===g||""===g?"":this._prepareHitUrl(g),l=this._prepareHitUrl(a.url)),b("page-ref",
f.trim(g,qa)),b("page-url",f.trim(l,qa)),Ua()?b("ut",Ia):"undefined"!=typeof c.ut&&b("ut",f.trim(c.ut,xb)),b("exp",a.experiments),a.vParams&&(l=f.toJSON(a.vParams),this.trimParams&&l.length>yb?k=!0:b("site-info",l)),c.saveRef&&(na.lastReferrer=g),this.fake||(e=this._getTechInfo(a.title,c,this.counterId,a.ts,a.tz,this._trackHash,this.hitId,this.webvisor,this.counter)),f.mixin(d,e,{}),this.send(h,d,function(){k&&this.counter.params(a.vParams);a.userParams&&this.counter.userParams(a.userParams);f.isFunction(a.callback)&&
a.callback.apply(a.ctx,arguments)},this))},_prepareHitUrl:function(a){var b=y(),c=b.host,b=b.href,d;if(!f.isString(a))return b;if(-1!=a.search(/^\w+:\/\//))return a;d=a.charAt(0);if("?"==d)return d=b.search(/\?/),-1==d?b+a:b.substr(0,d)+a;if("#"==d)return d=b.search(/#/),-1==d?b+a:b.substr(0,d)+a;if("/"==d){if(d=b.search(c),-1!=d)return b.substr(0,d+c.length)+a}else return c=b.split("/"),c[c.length-1]=a,c.join("/");return a},_getTechInfo:function(a,b,c,d,e,h,l,k,q){function m(a,b){a&&b&&(t[a]=b)}
function ia(a){b[a]&&m(a,"1")}var t={},y;b=b||{};d=d||I.getTimestamp();e=e||I.getTimezone();m("j",r.getJavaEnabled()?"1":"");m("nt",r.netType());T&&m("s",T.width+"x"+T.height+"x"+(T.colorDepth||T.pixelDepth));g.devicePixelRatio&&m("sk",g.devicePixelRatio);r.isIframe()&&m("ifr","1");m("adb",bb.getVal());m("f",r.getFlashVersion());m("l",r.getSilverlightVersion());m("fpr",r.getFingerPrint());m("cn",this.counterNum);b.pa||(y=n.getViewportSize(),m("w",y[0]+"x"+y[1]));m("z",e);m("i",d);m("et",Math.round((new Date).getTime()/
1E3));m("en",n.getDocumentCharset());m("v",U);m("c",navigator.cookieEnabled?"1":"");m("la",r.getLanguage());m("ntf",r.getNotificationPermission());f.random(100)||m("np",J.encode(R.encode(f.trim(r.getPlatform(),100))));h&&m("wh","1");e="ar ln dl ad nb pa pq pv ex".split(" ");for(d=0;d<e.length;d++)ia(e[d]);e=["va","vt","sn","sa","he"];b.nb&&e.push("cl");for(d=0;d<e.length;d++)h=e[d],m(h,b[h]);e=new N({counterId:c});e.isEnabled()&&(c=e.getStorageId(),(d=e.get("reqNum"))?d++:d=1,e.set("reqNum",d),e.get("reqNum")==
d?(m("ls",c),m("rqn",d)):(e.remove("reqNum"),e.clearStorageId(),1<d&&(m("ls",c),m("rqn",0))));m("rn",f.random());m("hid",l);m("ds",sb(q));q._firstPaint||(q._firstPaint=tb(),m("fp",q._firstPaint));if(k){g.name||(g.name=Math.round(65535*Math.random()));if(l=+g.name)0>l&&(l*=-1),l%=65535;m("wn",l||f.fletcher(g.name));try{g.history&&m("hl",String(g.history.length))}catch(Da){}}l="";this.sendTitle&&(l=this._getTitle(a));m("t",l);return t},_getTitle:function(a){a="undefined"==typeof a?(a=n.getDocumentTitle())?
f.trim(a,cb):"":f.trim(a,cb);return a}});f.array2Props=function(a){var b=a.length,c={},d=c,e,f;for(e=0;e<b-1;e++)f=a[e],d[f]={},e<b-2&&(d=d[f]);d[f]=a[b-1];return c};var Q=A.inherit({sampling:1,counterId:26302566,_initComponent:function(){Q.superclass._initComponent.apply(this,arguments);this._sender=new aa({protocol:"https:",counterId:this.counterId,retry:!1,counter:{}})},log:function(){this.logParams(f.array2Props(arguments))},logParams:function(a){Math.random()<this.sampling&&this._sender.sendHit({url:E.href,
title:"",referrer:"",vParams:a})}}),zb=K.inherit({resource:"webvisor",retry:!0,postParams:["wv-data"],sendPacket:function(a,b,c,d,e,m,h,k){var l,p;if(!a||!a.length)return!1;l=J.encode(a,!0);0==l.indexOf("AAAAAAAAADw")&&g.Error&&(p=Error(),"string"==typeof p.stack&&(new Q({sampling:.1})).log("bad visor packet 5",1));a={rn:f.random(),"page-url":b,wmode:0,"wv-type":0,"wv-hit":c,"wv-part":d+1,"wv-check":f.fletcher(a),"wv-data":l};return this.send(a,{z:e,i:m},h,k)}}),Ba=ab.inherit({protocol:"",counterId:"",
counterType:"",meta:null,maxBufferSize:7500,flushTimeout:3E4,storageKey:"visorbuff",active:!1,_initComponent:function(){this.storage=new N({counterId:this.counterId});this._sender=new zb({protocol:this.protocol,counterId:this.counterId,counterType:this.counterType});Ba.superclass._initComponent.apply(this,arguments)},onFlush:function(a,b,c){this._sender.sendPacket(a,b.url,b.hitId,c,b.timezone,b.timestamp)}}),nb=K.inherit({resource:"webvisor",transports:[S,O],postParams:["wv-data"],sendContent:function(a,
b,c,d,e,f,g){if(!a)return!1;-1<a.indexOf("\r")&&(a=a.replace(/\r\n/g,"\n"));a={"wv-type":1,"page-url":y().href,"wv-hit":c,"wv-data":J.encode(R.encode(a))};return 245E3<a["wv-data"].length?!1:this.send(a,{z:d,i:e,pct:b||""},f,g)}});f.isEqual=function(a,b){var c=!0;f.forEachKey(a,function(a,e){b.hasOwnProperty(a)&&b[a]===e||(c=!1)});if(!c)return c;f.forEachKey(b,function(b,e){a.hasOwnProperty(b)&&a[b]===e||(c=!1)});return c};var k=A.inherit({_initComponent:function(){k.superclass._initComponent.apply(this,
arguments);this._listeners=[]},on:function(a,b,c,d,e){e=k._getOpts(e);b=b.split(",");var f=b.length,h=this._listeners,n,q,p;for(p=0;p<f;p++)n=b[p],q=t(function(a){c.call(d||this,a||g.event)},"on"+n),h[h.length]=[a,n,c,d,e,q],a.addEventListener?a.addEventListener(n,q,k._prepOpts(e)):a.attachEvent&&a.attachEvent("on"+n,q)},un:function(a,b,c,d,e){e=k._getOpts(e);var g=this._listeners,h=g.length,n,q;for(n=0;n<h;n++)if(q=g[n],q[0]==a&&q[1]==b&&q[2]==c&&q[3]==d&&f.isEqual(q[4],e)){g.splice(n,1);this._removeListener(a,
b,q[5],e);break}},unAll:function(){var a=this._listeners,b=a.length,c,d;for(d=0;d<b;d++)c=a[d],this._removeListener(c[0],c[1],c[5],c[4]);a.length=0},_removeListener:function(a,b,c,d){a.removeEventListener?a.removeEventListener(b,c,k._prepOpts(d)):a.detachEvent&&a.detachEvent("on"+b,c)}});k.supportsPassive=function(){var a;if(k._supportsPassive!==Y)return k._supportsPassive;k._supportsPassive=!1;try{a=Object.defineProperty({},"passive",{get:function(){k._supportsPassive=!0}}),g.addEventListener("test",
null,a)}catch(b){}return k._supportsPassive};k._getOpts=function(a){return f.mixin({capture:!0,passive:!0},a||{})};k._prepOpts=function(a){return k.supportsPassive()?a:!!a.capture};k.on=function(){k._instance||(k._instance=new k);k._instance.on.apply(k._instance,arguments)};k.un=function(){k._instance&&k._instance.un.apply(k._instance,arguments)};n.getDocumentHTML=function(){var a,b="";a=h.documentElement;var c=a.outerHTML,d,e,f;if(c)a=c;else{c=a.attributes;d="";for(e=0;e<c.length;e++)(f=c[e])&&(d+=
" "+f.name+'="'+(f.value||"")+'"');a="<html"+d+">"+a.innerHTML+"</html>"}if(c=h.doctype)b=c.publicId?' PUBLIC "'+c.publicId+'"':"",d=c.systemId?' "'+c.systemId+'"':"",b="<!DOCTYPE "+c.name+b+d+">\n";return b+a};n.getDocumentScroll=function(){return[g.pageXOffset||h.documentElement&&h.documentElement.scrollLeft||h.body&&h.body.scrollLeft||0,g.pageYOffset||h.documentElement&&h.documentElement.scrollTop||h.body&&h.body.scrollTop||0]};n.getElementParent=function(a){var b;if(!a||a==h.documentElement)return null;
if(a==h.body)return h.documentElement;b=null;try{b=a.parentNode}catch(c){}return b};n.getElementChildren=function(a,b){var c=[],d,e,g,h,k;if(a&&(d=a.childNodes))for(h=0,k=d.length;h<k;h++)e=d[h],(g="INPUT"==e.nodeName&&e.type&&"hidden"==e.type.toLocaleLowerCase())||b&&e.nodeName!=b||f.mergeArrays(c,[e]);return c};n.getElementNeighborPosition=function(a){var b=n.getElementParent(a),c,d,e,f;if(b)for(e=0,b=b.childNodes,d=a&&a.nodeName,f=0;f<b.length;f++)if(c=b[f]&&b[f].nodeName,d==c){if(a==b[f])return e;
e++}return 0};n.getElementXY=function(a){var b,c;if(!a||!a.ownerDocument||"PARAM"==a.tagName||a==h.body||a==h.documentElement)return[0,0];if(a.getBoundingClientRect)return a=a.getBoundingClientRect(),b=n.getDocumentScroll(),[Math.round(a.left+b[0]),Math.round(a.top+b[1])];for(c=b=0;a;)b+=a.offsetLeft,c+=a.offsetTop,a=a.offsetParent;return[b,c]};n.getDocumentSize=function(){var a=n.getRootElement(),b=n.getViewportSize();return[Math.max(a.scrollWidth,b[0]),Math.max(a.scrollHeight,b[1])]};n.getElementSize=
function(a){var b;return a==h.body||a==h.documentElement?n.getDocumentSize():(b=a.getBoundingClientRect&&a.getBoundingClientRect())?[b.width,b.height]:[a.offsetWidth,a.offsetHeight]};n.getElementRegion=function(a){var b=n.getElementXY(a);a=n.getElementSize(a);return[b[0],b[1],a[0],a[1]]};n.calcChildrenChecksum=function(a){return f.fletcher((a.innerHTML||"").replace(/(<[^>]*>|[\u0000-\u0020])/g,""))};n.getFormNumber=function(a){var b=h.getElementsByTagName("form"),c,d;c=0;for(d=b.length;c<d;c++)if(b[c]==
a)return c;return-1};n.isEmptyField=function(a){return"INPUT"==a.nodeName&&"submit"!=a.type&&"image"!=a.type&&"hidden"!=a.type?"radio"==a.type||"checkbox"==a.type?!a.checked:!a.value:"TEXTAREA"==a.nodeName?!a.value:"SELECT"==a.nodeName?0>a.selectedIndex:!0};n.calcTextChecksum=function(a){var b="";a=a.childNodes;var c,d;c=0;for(d=a.length;c<d;c++)a[c]&&3==a[c].nodeType&&(b+=a[c].nodeValue);return f.fletcher(b.replace(/[\u0000-\u0020]+/g,""))};n.calcAttribChecksum=function(a){var b="",c="width height align title alt name".split(" "),
d;"IMG"==a.tagName&&(b+=a.src.toLowerCase());"A"==a.tagName&&(b+=a.href.toLowerCase());b+=String(a.className||"").toLowerCase();for(d=0;d<c.length;d++)a.getAttribute&&(b+=String(a.getAttribute(c[d])||"").toLowerCase());return f.fletcher(b.replace(/[\u0000-\u0020]+/g,""))};n.classNameExists=function(a,b){try{return(new RegExp("(?:^|\\s)"+b+"(?:\\s|$)")).test(a.className)}catch(c){return!1}};n.getElementsByClassName=function(a,b){var c,d,e;b=b||h;c=b.getElementsByTagName("*");d=[];for(e=0;e<c.length;e++)n.classNameExists(c[e],
a)&&d.push(c[e]);return d};var mb=!V(/webkit/)&&V(/gecko/),db=A.inherit({hid:0,tz:0,ts:0,counterId:0,counterType:0,url:"",protocol:"",enabled:!1,_initComponent:function(){var a,b;if(this.isEnabled()){a=this._getStorage();b=a.read("visorc");"b"!=b&&"w"!=b&&(b="");if(!a.isEnabled()||V("opera mini"))b="b";this._vc=b;"b"!=b&&(this._recorder=new jb(this.protocol,this.counterId,this.counterType,this.hid,this.counter));db.superclass._initComponent.apply(this,arguments)}},start:function(a){var b,c;if(this.isEnabled()&&
this._recorder){a=a||{};b=+a.recp;if(!isFinite(b)||0>b||1<b)c="w";c||(c=this.hid%1E4/1E4<b?"w":"b");this._getStorage().create("visorc",c,30);"w"==c?(this._recorder.start(),b=a.arch_type,(a=a.urls)&&b&&"none"!=b&&this._recorder.uploadPages(a,b)):this._recorder.stop()}},isEnabled:function(){return this.enabled},getVc:function(){return this._vc},_getStorage:function(){this._storage||(this._storage=new P({counterId:this.counterId}));return this._storage}}),eb=S.inherit({id:"RawBodyXHR",postParams:["body"],
_setHeaders:function(){},_preparePostParams:function(a){return a.post.body||""}});f.arrayFilter=function(a,b,c){var d=[],e;for(e=0;e<a.length;e++)b.call(c,a[e],e,a)&&d.push(a[e]);return d};f.arrDiff=function(a,b){return f.arrayFilter(a,function(a){return-1===f.arrayIndexOf(b,a)})};da.parse=function(a){try{return JSON.parse(a)}catch(b){return null}};f.getTld=function(){var a;this._tld||(a=E.hostname.split("."),this._tld=a[a.length-1]);return this._tld};var X=M.inherit({id:"script",request:function(a,
b,c,d){var e,k=f.getNativeFunction("createElement",h)("script");if(!k)return c.call(d,!1),!1;e="_ymjsp"+f.random();g[e]=t(function(){try{delete g[e]}catch(l){g[e]=Y}c.apply(d,f.mergeArrays([!0],arguments));k.parentNode&&k.parentNode.removeChild(k)},"transport.script");k.type="text/javascript";k.src=this._buildUrl(a,f.mixin({wmode:5,callback:e},b));a=h.getElementsByTagName("head")[0];a||(a=h.createElement("head"),h.documentElement.appendChild(a));a.insertBefore(k,a.firstChild);return!0}}),Ja=aa.inherit({transports:[X],
trimParams:!0,_initComponent:function(){Ja.superclass._initComponent.apply(this,arguments);this._ilStorage=new N({counterId:this.counterId})},sendHit:function(a){var b={},c=this._ilStorage.get("il");a.visitColor&&(b.vc=a.visitColor);a.hasPrerender&&(b.pr=1);c&&(this._ilStorage.remove("il"),b.ilt=J.encode(R.encode(f.trim(c,fb))));this._hitExt({url:a.url,title:a.title,referrer:a.referrer,vParams:a.vParams,userParams:a.userParams,experiments:a.experiments,modes:a.modes,browserInfo:b,ts:a.ts,tz:a.tz,
callback:a.callback,ctx:a.ctx})}}),Ab=A.inherit({cid:3,cnt:0,_initComponent:function(){this._storage=new N},hit:function(a){var b=this,c=this._storage.get("wasSynced");c&&c.time+864E5>+new Date||g.Ya._metrika.fakeHit?a():(g.Ya._metrika.fakeHit=!0,this._getSender().sendHit({callback:function(){b._storage.set("wasSynced",{time:+new Date});a()}}))},_getSender:function(){this._sender||(this._sender=new Ja({protocol:"https:",counterType:this.cnt,counterId:this.cid,sendTitle:!1,dontSendRequests:this.dontSendRequests,
fake:!0}));return this._sender}}),Bb=A.inherit({baseUrl:"https://mc.yandex.",baseTld:"ru",syncTlds:["ua","by","kz","com.tr"],langToDomain:{uk:"ua",be:"by",tr:"com.tr",kk:"kz"},sync:function(a){var b=this,c=this._need();!this._is()&&c?(this._setStatus(!0),Ua()?this._getCn().hit(function(){b._sync(c,a)}):a(function(){b._sync(c)})):a()},_is:function(){try{return!!g.Ya._metrika.startSync}catch(a){return!1}},_setStatus:function(a){try{g.Ya._metrika.startSync=a}catch(b){}},_need:function(){var a=this._getDomainByLang(),
b=this._getTld(),c,d=[];-1!=f.arrayIndexOf(this.syncTlds,a)&&d.push(a);-1!=f.arrayIndexOf(this.syncTlds,b)&&-1==f.arrayIndexOf(d,b)&&d.push(b);c=this._getLs().get("synced")||{};d=f.arrayFilter(d,function(a){return(c[a]||1)+864E5<+new Date});return d.length&&d||!1},_sync:function(a,b){var c,d,e=this;a.length?(d=new eb({method:"GET"}),b=b||function(){},d.request(this.baseUrl+this.baseTld+"/sync_cookie_get",null,function(g,h){var k,l,m,n=0,r=0,t;if(g){k=da.parse(h);try{l=k.sync_token,t=k.sync_ok}catch(Da){return b(),
!1}d.setMethod("POST");c=f.arrDiff(a,t);if(n=c.length)for(m=e._getLs(),k=0;k<c.length;k++)(function(a){d.request(e.baseUrl+a+"/sync_cookie_decide",{body:l},function(c,f){c?d.request(e.baseUrl+e.baseTld+"/sync_cookie_decide_ok",{body:f},function(c){r++;n===r&&b();c&&(c=m.get("synced")||{},c[a]=+new Date,m.set("synced",c))}):(r++,n===r&&b())})})(c[k]);else b()}else b()})):b()},_getCn:function(){this._cn||(this._cn=new Ab({fake:!0,dontSendRequests:this.dontSendRequests}));return this._cn},_getLs:function(){this._ls||
(this._ls=new N);return this._ls},_getTld:function(){var a=f.getTld();return{tr:"com.tr","\u0443\u043a\u0440":"ua","xn--j1amh":"ua","\u0431\u0435\u043b":"by","xn--90ais":"by"}[a]||a},_getDomainByLang:function(){var a;if(!g.navigator)return"ru";try{a=navigator.languages?navigator.languages[0]:r.getLanguage()}catch(b){}a=(a||"").toLowerCase().split("-")[0];return this.langToDomain[a]||"ru"}});r.isAndroid=t(function(){var a=navigator.userAgent.toLowerCase();return-1<a.indexOf("android")&&-1<a.indexOf("mobile")},
"",!0);var I={getMinutes:function(){return Math.floor(+new Date/1E3/60)}},ea={_url:"https://mc.yandex.ru/user_storage_set?",init:function(a){this._params=a||{}},save:function(a,b){this._getReq().request(this._url+ma.stringify({key:a,value:f.toJSON(b)}));this._getLs().set(a,b)},get:function(a){return{remote:this._params[a],local:this._getLs().get(a)}},getNum:function(a){a=this.get(a);return Math.max(+a.remote||0,+a.local||0)},_getLs:function(){this._ls||(this._ls=new N);return this._ls},_getReq:function(){this._req||
(this._req=new ca);return this._req}},Cb={sync:t(function(){var a=["29009","30102"],b={t:'UV|L7,!"T[rwe&D_>ZIb\\aW#98Y.PC6k'},c,d;this._enabled()&&(this._setStatus(!0),c=new eb({method:"GET",withCredentials:!1}),d=a.length,function m(f){var g=a[f];f<d?c.request("http://127.0.0.1:"+g+"/p",b,function(a,b){a?this._save(a,b,g):m.call(this,f+1)},this):this._save(!1)}.call(this,0))},"ds"),_save:function(a,b,c){a&&(new aa({protocol:"https:",counterType:0,counterId:3,sendTitle:!1,fake:!0})).sendDevice({data:f.trim(b),
port:c});ea.save("ds",I.getMinutes())},_is:function(){try{return!!g.Ya._metrika.dSync}catch(a){return!1}},_enabled:function(){var a=60<I.getMinutes()-ea.getNum("ds");return r.isAndroid()&&0==y().hostname.search(/^(.*\.)?((ya|yandex(\-team)?)\.(com\.)?\w+|(auto|kinopoisk)\.ru|yadi\.sk|yastatic\.net)$/)&&a&&!this._is()},_setStatus:function(a){try{g.Ya._metrika.dSync=a}catch(b){}}},D={getPos:function(a){var b=n.getRootElement(),c=n.getDocumentScroll();return[a.pageX||a.clientX+c[0]-(b.clientLeft||0)||
0,a.pageY||a.clientY+c[1]-(b.clientTop||0)||0]},getTarget:function(a){var b=null;try{(b=a.target||a.srcElement)&&!b.ownerDocument&&b.documentElement&&(b=b.documentElement)}catch(c){}return b},getMouseButton:function(a){return a.which||a.button==Y?a.which:a.button&1?1:a.button&2?3:a.button&4?2:0},prevent:function(a){a=a||g.event;a.preventDefault?a.preventDefault():a.returnValue=!1}};D.dispatchCustomEvent=t(function(a,b){var c;b=b||h;if(c=f.getNativeFunction("createEvent",h)("Event"))c.initEvent(a,
!1,!1),f.getNativeFunction("dispatchEvent",b)(c)},"evt.dispatch");k.ready=function(a){var b=g.performance,c;"object"==typeof b&&b.timing&&b.timing.domContentLoadedEventStart?a():(c=function(){k.un(h,"DOMContentLoaded",c);k.un(g,"load",c);a()},k.on(h,"DOMContentLoaded",c),k.on(g,"load",c))};var na={lastReferrer:null};f.isObject=function(a){try{return a&&null!==a&&"[object Object]"==Object.prototype.toString.call(a)}catch(b){return!1}};f.isNumber=function(a){return isFinite(a)&&!isNaN(a)&&"[object Number]"==
Object.prototype.toString.call(a)};f.clearTimeout=function(a){return f.getNativeFunction("clearTimeout")(a)};f._urlParser=null;f.parseUrl=function(a){if(!this._urlParser)try{this._urlParser=h.createElement("a")}catch(b){}return this._urlParser?(this._urlParser.href=a,{protocol:this._urlParser.protocol,host:this._urlParser.host,port:this._urlParser.port,hostname:this._urlParser.hostname,hash:this._urlParser.hash,search:this._urlParser.search,query:this._urlParser.search.replace(/^\?/,""),pathname:this._urlParser.pathname||
"/",path:(this._urlParser.pathname||"/")+this._urlParser.search,href:this._urlParser.href}):{}};r.isIE=function(){return h&&!h.addEventListener||!1};var fa={};fa._cookie=new P({onlyCurrentDomain:!0});fa.log=t(function(){var a=-1<E.href.indexOf("_ym_debug=1")||g._ym_debug;a&&this._cookie.create("debug","1");g.console&&console.log&&(a||"1"===this._cookie.read("debug"))&&console.log.apply(console,arguments)},"DebugConsole.log");var Db=K.inherit({resource:"clmap",retry:!0,transports:[ca],sendClick:function(a,
b,c,d){this.send({"page-url":a,"pointer-click":b},{},c,d)}}),Eb=A.inherit({filter:null,ignoreTags:[],quota:0,isTrackHash:!1,protocol:"",counterId:0,counterType:0,startTime:0,dontSendRequests:!1,MAX_LEN_PATH:128,TIMEOUT_CLICK:50,TIMEOUT_SAME_CLICKS:1E3,DELTA_SAME_CLICKS:2,tags:"A B BIG BODY BUTTON DD DIV DL DT EM FIELDSET FORM H1 H2 H3 H4 H5 H6 HR I IMG INPUT LI OL P PRE SELECT SMALL SPAN STRONG SUB SUP TABLE TBODY TD TEXTAREA TFOOT TH THEAD TR U UL ABBR AREA BLOCKQUOTE CAPTION CENTER CITE CODE CANVAS DFN EMBED FONT INS KBD LEGEND LABEL MAP OBJECT Q S SAMP STRIKE TT ARTICLE AUDIO ASIDE FOOTER HEADER MENU METER NAV PROGRESS SECTION TIME VIDEO NOINDEX NOBR MAIN".split(" "),
_initComponent:function(){var a,b,c;this._lastClick=null;this.hasQuota=!!this.quota;this._quota=this.quota;this._ignoreTags=[];if(this.ignoreTags)for(a=0;a<this.ignoreTags.length;a++)this.ignoreTags[a]&&f.mergeArrays(this._ignoreTags,[String(this.ignoreTags[a]).toUpperCase()]);this._cacheTags={};a=59;b=String.fromCharCode;for(c=0;c<this.tags.length;c++)this._cacheTags[this.tags[c]]=b(a),b(a),a++;this._sender=new Db({dontSendRequests:this.dontSendRequests,protocol:this.protocol,counterId:this.counterId,
counterType:this.counterType});this._start=!1;this.start()},destroy:function(){this.stop()},start:function(){if(!this._start)k.on(h,"click",this._handler,this);this._start=!0},stop:function(){this._start&&k.un(h,"click",this._handler,this);this._start=!1},setTrackHash:function(a){this.isTrackHash=a},_isIgnore:function(a){return n.classNameExists(a,"(ym-disable-clickmap|ym-clickmap-ignore)")},_handler:function(a){a={el:D.getTarget(a),pos:D.getPos(a),button:D.getMouseButton(a),time:+new Date};var b,
c;this._isTrackingClick(a)&&(b=n.getElementSize(a.el),c=n.getElementXY(a.el),b=["rn",f.random(),"x",Math.floor(65535*(a.pos[0]-c[0])/(b[0]||1)),"y",Math.floor(65535*(a.pos[1]-c[1])/(b[1]||1)),"t",Math.floor((a.time-this.startTime)/100),"p",this._getElPath(a.el)],c=y().href,this.isTrackHash?f.mergeArrays(b,["wh","1"]):c=c.split("#")[0],this._sender.sendClick(f.trim(c,qa),b.join(":")),this._lastClick=a)},_isTrackingClick:function(a){var b,c,d;if(g.ymDisabledClickmap||f.isMetrikaPlayer()||!a.el)return!1;
b=a.el.tagName;if((2==a.button||3==a.button)&&"A"!=b||this.filter&&!this.filter(a.el,b))return!1;for(c=0;c<this._ignoreTags.length;c++)if(this._ignoreTags[c]==b)return!1;for(b=a.el;b;){if(this._isIgnore(b))return!1;b=b.parentNode}if(this._lastClick){if(a.time-this._lastClick.time<this.TIMEOUT_CLICK)return!1;b=Math.abs(this._lastClick.pos[0]-a.pos[0]);c=Math.abs(this._lastClick.pos[1]-a.pos[1]);d=a.time-this._lastClick.time;if(this._lastClick.el==a.el&&b<this.DELTA_SAME_CLICKS&&c<this.DELTA_SAME_CLICKS&&
d<this.TIMEOUT_SAME_CLICKS)return!1}if(this.hasQuota){if(!this._quota)return!1;this._quota--}return!0},_getElPath:function(a){for(var b="";a&&a.parentNode&&"BODY"!=a.tagName&&"HTML"!=a.tagName;)b+=this._cacheTags[a.tagName]||"*",b+=n.getElementNeighborPosition(a)||"",a=a.parentNode;return f.trim(b,this.MAX_LEN_PATH)}});n.loadScript=function(a,b){b=b||g;var c=f.mixin({type:"text/javascript",charset:"utf-8",async:!0},a),d=b.document,e=f.getNativeFunction("createElement",d),h=e("script"),k,n;if(h){h.type=
c.type;h.charset=c.charset;h.src=c.src;c.async&&(h.async=!0);try{return k=d.getElementsByTagName("head")[0],k||(n=d.getElementsByTagName("html")[0],k=e("head"),n&&n.appendChild(k)),k.insertBefore(h,k.firstChild),h}catch(q){}}};var gb=A.inherit({_initComponent:function(){gb.superclass._initComponent.apply(this,arguments);this._executedMsgs={};k.on(g,"message",this._onMessage,this)},_buildRemoteIframe:function(a){var b=f.getNativeFunction("createElement",h)("div"),c=h.body||h.documentElement,d;c&&(b.innerHTML=
'<iframe name="RemoteIframe" allowtransparency="true" style="position: absolute; left: -999px; top: -999px; width: 1px; height: 1px;"></iframe>',d=b.firstChild,d.onload=function(){n.loadScript({src:a},d.contentWindow)},g._ym__remoteIframeEl=d,b.createShadowRoot||b.webkitCreateShadowRoot?(c.appendChild(b),b.removeChild(d),(c=b.createShadowRoot?b.createShadowRoot():b.webkitCreateShadowRoot())&&c.appendChild(d),g._ym__remoteIframeContainer=b):(c.appendChild(d),g._ym__remoteIframeContainer=d))},_isAllowedLang:function(a){return-1!==
f.arrayIndexOf(["ru","uk","en","tr"],a)},_isAllowedOrigin:function(a){return/^http:\/\/(.+\.)?webvisor\.com\/?$/.test(a)},_isAllowedStatic:function(a){return/^https?:\/\/(((.+\.)?dev\.webvisor\.com)|(yastatic\.net))(\/.*)?$/.test(a)},_onMessage:function(a){var b;try{b=a.origin}catch(c){}b&&this._isAllowedOrigin(b)&&(b=da.parse(a.data))&&"appendremote"===b.action&&this._isAllowedStatic(b.domain)&&this._isAllowedLang(b.lang)&&!this._executedMsgs[b.id]&&(this._executedMsgs[b.id]=!0,g._ym__postMessageEvent=
a,g._ym__inpageMode=b.inpageMode,g._ym__initMessage=b.initMessage,this._buildRemoteIframe(b.domain+"/cdn/inpage-remote/inpage-remote."+b.lang+".js"))}});f.pad=function(a){return(10>a?"0":"")+a};I.getTimestamp=function(){var a=new Date,a=[a.getFullYear(),a.getMonth()+1,a.getDate(),a.getHours(),a.getMinutes(),a.getSeconds()],b="",c;for(c=0;c<a.length;c++)b+=f.pad(a[c]);return b};I.getTimezone=function(){return-(new Date).getTimezoneOffset()};f.bind=function(a,b){return function(){return a.apply(b||
this,arguments)}};var hb=A.inherit({counter:null,prefsEcommerce:null,dataLayerName:"dataLayer",allowedEvents:["add","delete","remove","purchase","detail"],_initComponent:function(){var a="customArr";hb.superclass._initComponent.apply(this,arguments);this._overridePush(this.prefsEcommerce)||(f.isString(this.prefsEcommerce)&&(this.dataLayerName=this.prefsEcommerce),a=this.dataLayerName,this._tryTimeout=f.bind(this._tryTimeout,this),this._tryTimeout());this.counter._ecommerce=a},_overridePush:function(a){var b,
c;return a&&"function"==typeof a.push?(b=this,b._send(a),c=a.push,a.push=function(){b._send([].slice.call(arguments,0));c.apply(this,arguments)},!0):!1},_tryTimeout:function(){this._overridePush(g[this.dataLayerName])||f.setTimeout(this._tryTimeout,1E3,"dlObserver")},_send:function(a){var b=[],c=this.allowedEvents,d,e,g,h,k;d=0;for(k=a.length;d<k;d++)(e=a[d])&&e.ecommerce&&(g={},h=!1,f.forEachKey(e.ecommerce,function(a,b){0<=f.arrayIndexOf(c,a)&&(h=!0,g[a]=b)}),h&&b.push(g));b.length&&this.counter.params({__ym:{ecommerce:b}})}}),
Fb={match:function(){this.enabled()&&k.ready(function(){var a=f.getNativeFunction("createElement",h)("iframe");a.onload=function(){ea.save("cm",I.getMinutes());n.removeNode(a)};a.setAttribute("style","position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden;visibility:hidden");a.src="https://mc.yandex.ru/metrika/watch_match.html";h.documentElement.appendChild(a)})},enabled:function(){return 1440<I.getMinutes()-ea.getNum("cm")&&"tr"==f.getTld()}};f.safeDecodeURIComponent=function(a){try{return decodeURIComponent(a)}catch(b){return""}};
ma.parse=function(a,b){var c={},d,e,g,h;a=a&&a.replace(/^\?/,"")||"";if(a.length)for(d=a.split("&"),h=0;h<d.length;h++)d[h]&&(e=d[h].split("="),e[0]&&(g=f.safeDecodeURIComponent(e[0]),e=f.safeDecodeURIComponent((e[1]||"").replace(/\+/g,"%20")),b&&g in c?f.isArray(c[g])?c[g].push(e):c[g]=[c[g],e]:c[g]=e));return c};var W=[],E=y(),ua=I.getTimezone(),va=I.getTimestamp(),T=g.screen,U="774",xb=64,qa=r.isIE()?512:2048,yb=r.isIE()?512:2048,cb=r.isIE()?100:400,fb=100,Ia="noindex",ib=/\.(3gp|7z|aac|ac3|acs|ai|avi|ape|apk|asf|bmp|bz2|cab|cdr|crc32|css|csv|cue|divx|dmg|djvu?|doc(x|m|b)?|emf|eps|exe|flac?|flv|iso|swf|gif|t?gz|jpe?g?|js|m3u8?|m4a|mp(3|4|e?g?)|m4v|md5|mkv|mov|msi|ods|og(g|m|v)|psd|rar|rss|rtf|sea|sfv|sit|sha1|svg|tar|tif?f|torrent|ts|txt|vob|wave?|wma|wmv|wmf|webm|ppt(x|m|b)?|xls(x|m|b)?|pdf|phps|png|xpi|g?zip)$/i,
Gb=+new Date,Ka,ga,ha;g.Ya=g.Ya||{};Ya._metrika=Ya._metrika||{};Ya._metrika.counters=Ya._metrika.counters||{};Ya._metrika.hitParam=Ya._metrika.hitParam||{};Ya._metrika.counterNum=Ya._metrika.counterNum||0;Ya._metrika.hitId=Ya._metrika.hitId||f.random();Ya._globalMetrikaHitId=f.random();Ya._metrika.v=U;ha=!!Ya._metrika.oo;g.Ya.Metrika=function(a,b,c,d){var e=this;return t(function(){function m(z){var v=!1,m,H;if(Ya._metrika.hitParam[Z]){if(1!=c||Ya._metrika.counters[Z])return!1;v=!0}Ya._metrika.counters[Z]=
e;Ya._metrika.hitParam[Z]=1;e._webvisor=!d&&!ha&&(x&&x.webvisor||!1);e._directCampaign=x&&x.directCampaign;x&&x.trackHash&&Q(!0);d||v||(m=new db({protocol:"https:",counterId:a,counterType:c,hid:ja,tz:ua,ts:va,url:E.href,enabled:e._webvisor}),e.replacePhones(),v=new Bb({dontSendRequests:ha}),H=function(d){var v=new Ja({protocol:"https:",counterType:c,counterId:a,trackHash:w,hitId:ja,webvisor:e._webvisor,counter:e,dontSendRequests:ha,counterNum:S}),l={ut:O,he:x?~~x.httpError:0,ad:1==c&&g.Ya&&g.Ya.Direct,
pv:!0,saveRef:!0};Ka=+new Date;v.sendHit({url:E.href,title:n.getDocumentTitle(),referrer:h.referrer,vParams:b,userParams:V,experiments:U,modes:l,visitColor:m.getVc(),hasPrerender:z,ts:va,tz:ua,callback:function(c,v){ea.init(v);Fb.match();fa.log("PageView. Counter ",a,". URL: ",E.href,". Referrer: "+h.referrer,". Params: ",b);ga||(ga=+new Date);c=c||{};m.start(c.webvisor);var l=c.mp2,z,n;n=new P({counterId:a});n.erase("mp2_substs");if(l){b:{z=l.conditions;var p;if(z&&z.length)for(p=0;p<z.length;p++){var B;
B=z[p];if("ref"==B.type)B=ub(B);else if("adv"==B.type){var H,q,r,t,C;H=B;t=Ya._metrika.counter._directCampaign;q=H.ServiceNamePattern;var la=H.RefererPattern;B=t?H.direct_orders:H.direct_camp;var y=h.referrer,x=ma.parse(E.search),w=vb(E.search,E.hash),A={};r=["source","medium","campaign","term","content"];for(C=0;C<r.length;C++)x["utm_"+r[C]]&&(A[r[C]]=x["utm_"+r[C]]);var D=t?"direct.yandex.ru":w&&w.service||A.source;C=!1;if(!C&&q&&q.length)for(r=0;r<q.length;r++)if((new RegExp(q[r],"i")).test(D)){C=
!0;break}if(!C&&!H.yandex_direct&&la&&la.length)for(q=0;q<la.length;q++)if((new RegExp(la[q],"i")).test(y)){C=!0;break}!C&&H.google_adwords&&x.gclid&&(C=!0);if(C&&B&&B.length&&(C=!1,t=t||w&&w.campaign||A&&A.campaign))for(H=0;H<B.length;H++)if(B[H]==t){C=!0;break}B=C}else B=!1;if(B){z[p].track_id&&n.create("mp2_track",z[p].track_id,43200);break b}}}z=n.read("mp2_track");l=l.substs&&l.substs[z];z&&l?(n.create("mp2_substs",f.toJSON(l)),n=Za(l),e.params("__ym",n?"mp_trackid":"mp_trackid_bad",z)):$a()}else $a();
k.on(g,"load",e.replacePhones,e);e._inited=!0;d&&d()}})},v.sync(H));A();x&&(x.enableAll?(l(!0),p(!0),I()):(x.clickmap&&p(x.clickmap),x.trackLinks&&l(x.trackLinks),x.accurateTrackBounce&&I(x.accurateTrackBounce)),(x.ecommerce||x.useDataLayer)&&new hb({counter:e,prefsEcommerce:x.ecommerce}),x.triggerEvent&&ob(function(){D.dispatchCustomEvent("yacounter"+a+"inited")},0))}function l(a){var b={};switch(typeof a){case "string":b.on=!0;break;case "object":b.on=!0;break;case "boolean":b.on=a;break;default:return}e._trackLinks=
b}function A(){l(!1);k.on(h,"click",function(a){e._trackLinks&&e._trackLinks.on&&q(a)})}function q(a){var b=pb(a),c,d,e,g;if(b){a=!1;d=(c=""+b.href)?c.split(/\?/)[0]:"";e=function(a){var d=Va(b);L.sendClickLink({url:c,title:c==d?"":d,modes:a})};if(ib.test(d)||ib.test(c)||Wa(c,ba)||Wa(d,ba))a=!0;g=n.classNameExists(b,"ym-disable-tracklink");d=n.classNameExists(b,"ym-external-link");g||(g={ln:!0,dl:a},d?e(g):(d=b.hostname||f.parseUrl(b.href).hostname||"",qb(y().hostname,d)?a?(g.ln=!1,e(g)):(a=Va(b))&&
a!=c&&qa.set("il",f.trim(a,fb)):c&&-1!=c.search(/^ *(data|javascript):/i)||(g.ut=Ia,e(g))))}}function p(b){"undefined"==typeof b&&(b=!0);!0===b&&(b={});e._clickmap&&e._clickmap.destroy();b&&(e._clickmap=new Eb({dontSendRequests:ha,filter:b.filter,ignoreTags:b.ignoreTags,quota:b.quota,isTrackHash:b.isTrackHash,protocol:"https:",counterId:a,counterType:c,startTime:Gb}))}function J(a,b){function c(){var c;q||(p&&f.clearTimeout(p),c=m?n:n+ +new Date-z,c=b-c,0>c&&(c=0),p=f.setTimeout(function(){q=!0;e(!1);
a()},c,"trackUserTime"))}function d(){v||(l=!0,m=!1,v=!0,c())}function e(a){var b;for(b=0;b<t.length;b+=3)if(a)k.on(t[b],t[b+1],t[b+2]);else k.un(t[b],t[b+1],t[b+2])}var l=!1,v=!1,m=!0,n=0,z=+new Date,p=null,q=!1,t;r.isIE()?f.setTimeout(a,b,"trackUserTime"):(t=[g,"blur",function(){m=l=v=!0;n+=+new Date-z;z=+new Date;c()},g,"focus",function(){l||v||(n=0);z=+new Date;l=v=!0;m=!1;c()},h,"click",d,h,"mousemove",d,h,"keydown",d,h,"scroll",d],e(!0),c())}function I(b){var c,d;"number"!=typeof b&&(b=15E3);
e._isAccurateTrackBounce||(e._isAccurateTrackBounce=!0,c=new N({counterId:a}),d=c.get("lastHit"),c.set("lastHit",+new Date),((c=c.get("lastHit"))&&(!d||d<c-18E5)||!rb(h.referrer,y().href)||.1>Math.random())&&J(function(){e.notBounce()},b))}function T(a){var b=function(){var a=y().hash.split("#")[1],b;if("undefined"==typeof a)return!1;b=a.indexOf("?");0<b&&(a=a.substring(0,b));return a},c;c=b();(function C(){var d=b();d!==c&&(a(),c=d);ka=f.setTimeout(C,200,"trackHash")})()}function Q(a){if(!1===a)w&&
("onhashchange"in g?k.un(g,"hashchange",R):f.clearTimeout(ka),w=!1);else if(a=R,!w){if("onhashchange"in g)k.on(g,"hashchange",a);else T(a);w=!0}L.setTrackHash(w);e._trackHash=w}function R(){var a={ut:O,ad:1==c&&g.Ya&&g.Ya.Direct,wh:!0,saveRef:!0,pv:!0};W=na.lastReferrer=X;L.sendAjaxHit({url:y().href,title:n.getDocumentTitle(),referrer:W,modes:a});X=y().href}function M(a,b,c){a=Ba.parseValidate(a,b);b=[];a&&(b.push(a),c=c||{},f.isFunction(c.callback)&&(b.push(c.callback),c.ctx&&b.push(c.ctx)));b.length&&
e.params.apply(e,b)}var Z,O="",U,V,x,W="",X=na.lastReferrer=E.href,S,L,ba,ca,qa,w,G,pa,ja;Ya._metrika.counter||(Ya._metrika.counter=e);"object"==typeof a&&(x=a,d=a.defer,O=a.ut,c=a.type,b=a.params,V=a.userParams,U=x.experiments,pa=x.nck,a=a.id);a=a||0;/^\d+$/.test(a)||(a=0);c=c||0;Z=a+":"+c;if(Ya._metrika.counters[Z])return Ya._metrika.counters[Z];ja=Ya._metrika.hitId;Ya._metrika.counterNum++;S=Ya._metrika.counterNum;pa||(K.initCookie(),bb.init());K.retransmit();L=new aa({protocol:"https:",counterType:c,
counterId:a,hitId:ja,counter:e,dontSendRequests:ha,counterNum:S});e.replacePhones=t(function(){var b,c;try{(b=(new P({counterId:a})).read("mp2_substs"))&&(c=da.parse(b))&&Za(c,!0)}catch(B){}return e},"counter.replacePhones");e.reachGoal=t(function(b,c,d,f){2<=arguments.length&&"function"===typeof c&&(f=d,d=c,c=Y);fa.log("Reach goal. Counter: "+a+". Goal id: "+b+". Params: ",c);L.sendGoal(b,{vParams:c,callback:d,ctx:f});return e},"counter.reachGoal");e.trackLinks=t(function(a){l(a);return e},"counter.trackLinks");
qa=new N({counterId:a});e.hit=t(function(b,c,d,g,h,k){b&&(f.isObject(c)&&(d=c.referer,g=c.params,h=c.callback,k=c.ctx,c=c.title),fa.log("PageView. Counter "+a,". URL: "+b,". Referrer: "+d,". Params: ",g),L.sendHit({url:b,title:c,referrer:d,vParams:g,callback:h,ctx:k}));return e},"counter.hit");e.params=t(function(b){var c=arguments.length,d=c,g,h,k=[].slice.call(arguments,0);b&&(1<arguments.length&&(f.isFunction(arguments[c-1])?(g=arguments[c-1],d=c-1):f.isFunction(arguments[c-2])&&(g=arguments[c-
2],h=arguments[c-1],d=c-2),k=[].slice.call(k,0,d),1<k.length&&(k=[f.array2Props(k)])),fa.log("User params. Counter "+a+". Params: ",k[0]),L.sendParams(k[0],g,h));return e},"counter.params");e.file=t(function(a,b){a&&(b=b||{},L.sendFileUpload({url:a,title:b.title,vParams:b.params,callback:b.callback,ctx:b.ctx}));return e},"counter.file");e.extLink=t(function(a,b){a&&(b=b||{},L.sendExtLink({url:a,title:b.title,vParams:b.params,callback:b.callback,ctx:b.ctx}));return e},"counter.extLink");e.notBounce=
t(function(a){var b=0;a=a||{};Ka&&ga&&(b=ga-Ka);L.sendNotBounce(b,{callback:a.callback,ctx:a.ctx});return e},"counter.notBounce");ba=[];e.addFileExtension=function(a){"string"==typeof a?ba.push(a):ba=ba.concat(a);return e};e.clickmap=function(a){p(a);return e};e.accurateTrackBounce=function(a){I(a);return e};var ka=null;w=!1;e.trackHash=function(a){Q(a);return e};f.arrayEvery=function(a,b,c){var d;for(d=0;d<a.length;d++)if(!b.call(c,a[d],d,a))return!1;return!0};var Ba={requiredEcommerceFields:["currency",
"goods"],parseValidate:function(a,b){var c=this.validate(a,b),d;if(!c.isValid)return console&&console.log(c.message),!1;c={};c[a]={};b.currency&&(c.currencyCode=b.currency);b.goods&&(c[a].products=b.goods);for(d in b)b.hasOwnProperty(d)&&-1===f.arrayIndexOf(this.requiredEcommerceFields,d)&&(c[a].actionField||(c[a].actionField={}),c[a].actionField[d]=b[d]);return{__ym:{ecommerce:[c]}}},validate:function(a,b){var c=!1,d="";if(f.isObject(b))switch(a){case "detail":case "add":case "remove":f.isArray(b.goods)&&
b.goods.length?(c=f.arrayEvery(b.goods,function(a){return f.isObject(a)&&(f.isString(a.id)||f.isNumber(a.id)||f.isString(a.name)||f.isString(a.name))}))||(d="All items in 'goods' should be objects and contain 'id' or 'name' field"):d="Ecommerce data should contain 'goods' non-empty array";break;case "purchase":f.isNumber(b.id)||f.isString(b.id)?c=!0:d="Purchase object should contain string or number 'id' field"}else d="Ecommerce data should be an object";return{isValid:c,message:d}}};e.ecommerceDetail=
t(function(a,b){M("detail",a,b);return e},"ecommerce.detail");e.ecommerceAdd=t(function(a,b){M("add",a,b);return e},"ecommerce.add");e.ecommerceRemove=t(function(a,b){M("remove",a,b);return e},"ecommerce.remove");e.ecommercePurchase=t(function(a,b){M("purchase",a,b);return e},"ecommerce.purchase");e.userParams=t(function(a,b,c){f.isObject(a)&&e.params({__ymu:a},b||function(){},c);return e},"uparams");e.experiments=t(function(a,b,c){L.sendExperiments({callback:b,ctx:c,experiments:a});return e},"exps");
e.id=e.setUserID=t(function(a,b,c){(f.isString(a)||f.isNumber(a))&&e.params({__ym:{user_id:a}},b||function(){},c);return e},"id");ca=new P;e.getClientID=t(function(){return ca.read("uid")},"guid");e.enableAll=function(){l(!0);p(!0);I();return e};e.ds=t(function(){Cb.sync()});e.uploadPage=function(){};e._performanceTiming=Xa;a&&("prerender"==h.webkitVisibilityState?(L.sendPrerenderHit({url:E.href,title:n.getDocumentTitle(),referrer:h.referrer}),G=function(){"prerender"!=h.webkitVisibilityState&&(k.un(h,
"webkitvisibilitychange",G),m(!0))},k.on(h,"webkitvisibilitychange",G)):m(!1))},"init")()};(function(){if(g.performance&&"function"===typeof performance.getEntries){var a={2343947156:1,1996539654:1,2065498185:1,823651274:1,12282461:1,1555719328:1,1417229093:1,138396985:1},b=performance.getEntries(),c={},d,e,h,k;for(k=0;k<b.length;k++)d=b[k],e=d.name.replace(/^https?:\/\//,"").split("?")[0],h=f.fnv32a(e),a[h]&&!c[e]&&0<d.duration&&(c[e]={dns:Math.round(d.domainLookupEnd-d.domainLookupStart),tcp:Math.round(d.connectEnd-
d.connectStart),duration:Math.round(d.duration),response:Math.round(d.responseEnd-d.requestStart),pages:E.href});(new Q({sampling:.001})).logParams({timings8:c})}})();g.Ya._metrika.remoteCtrlInited||(g.Ya._metrika.remoteCtrlInited=!0,new gb);g.Ya.Metrika||(g.Ya.Metrika=function(){});g.Ya.Metrika.counters=function(){var a=[];f.forEachKey(g.Ya._metrika.counters,function(b,c){var d=b.split(":");a.push({id:+d[0],type:+d[1],accurateTrackBounce:c._isAccurateTrackBounce,clickmap:c._clickmap&&c._clickmap._start,
oldCode:!!g.ya_cid,trackHash:!!c._trackHash,trackLinks:c._trackLinks&&c._trackLinks.on,webvisor:!!c._webvisor})});return a};g.ya_cid&&new Ya.Metrika(g.ya_cid,g.ya_params,g.ya_class);g.ya_cid&&!g.ya_hit&&(g.ya_hit=function(a,b){Ya._metrika.counter&&Ya._metrika.counter.reachGoal(a,b)});(function(){function a(a){try{delete g[a]}catch(m){g[a]=Y}}var b=g.yandex_metrika_callback,c=g.yandex_metrika_callbacks,d;"function"==typeof b&&b();if("object"==typeof c)for(b=0;b<c.length;b++)if(d=c[b])c[b]=null,d();
a("yandex_metrika_callback");a("yandex_metrika_callbacks")})();g.Ya.Metrika.informer=function(a){var b=!!Ya.Metrika._informer;Ya.Metrika._informer=a;b||n.loadScript({src:"https://informer.yandex.ru/metrika/informer.js"})};k.on(h,"click",t(function(a){var b=D.getTarget(a),c,d;b&&"ym-advanced-informer"==b.className&&(c=b.getAttribute("data-lang"),d=b.getAttribute("data-cid"),Ya.Metrika.informer({i:b,id:+d,lang:c}),D.prevent(a))},"adv-inf"),null,{passive:!1})})(this,this.document);
