(function(g,h,ba){function v(a,b,c){return function(){try{return a.apply(this,arguments)}catch(d){c||ra(d,b)}}}function ra(a,b){var c;if(.01>Math.random())try{(new Y).log("jserrs",M,a.message,b,C.href,"","string"==typeof a.stack&&a.stack.replace(/\n/g,"\\n"))}catch(d){c=["cp: "+b,a.name+": "+a.message,"debug: ","code: "+M,"stack: "+a.stack],(new Image).src="//an.yandex.ru/jserr/101500?cnt-class=100&errmsg="+encodeURIComponent(c.join("; ").replace(/\r?\n/g,"\\n"))}}function jb(a,b,c){return g.setTimeout(v(a,
c||"setTimeout"),b)}function x(){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(n){C&&(a=C)}return a}function sa(a){return a?(""+a).replace(/^\s+/,"").replace(/\s+$/,""):""}function xa(){return-1!=x().hostname.search(/(?:^|\.)(?:ya|yandex)\.(?:\w+|com\.\w+)$/)}function la(a){return-1!==(""+g.navigator.userAgent).toLowerCase().search(a)}function Na(a){return sa(a&&a.innerHTML&&
a.innerHTML.replace(/<\/?[^>]+>/gi,""))}function Oa(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 kb(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 lb(a,b){return(a?a.replace(/^www\./,""):"")==(b?b.replace(/^www\./,""):"")}function mb(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 Pa(){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 nb(a){var b=[],c=a._lastPerformanceTiming,d=Pa(),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 ob(){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 pb(a){var b=h.referrer||"",c,d,e,k,n;if((new RegExp("^https?://"+C.host+"/")).test(b))return!1;c=a.patterns;for(k=0;k<c.length;k++)if(d=new RegExp(c[k],"i"),b.match(d))if(d=a.params||
[],d.length)for(e=f.safeDecodeURIComponent((RegExp.$1||"").replace(/\+/g,"%20")),n=0;n<d.length;n++){if(e==f.safeDecodeURIComponent(d[n]))return!0}else return!0;return!1}function Qa(a,b){var c=!1,d,e,f,n;if(a&&"string"!=typeof a&&a.length)for(n=0;n<a.length;n++)if(d=a[n].selector,e=a[n].text,f=d.charAt(0),d=d.slice(1),"#"==f){if(f=h.getElementById(d))c=!0,b&&P.unshift([f,f.innerHTML]),f.innerHTML=e}else if("."==f)for(f=m.getElementsByClassName(d),d=0;d<f.length;d++){var c=!0,g=f[d],l=e;b&&P.unshift([g,
g.innerHTML]);g.innerHTML=l}return c}function Ra(){var a;for(a=0;a<P.length;a++)P[a][0].innerHTML=P[a][1]}function qb(a,b){var c,d,e="",k,g,h;a=a&&a.replace(/^\?/,"");b=b&&b.replace(/^#/,"")||"";if(a)for(d=a.split("&"),c=0;c<d.length;c++)h=d[c].split("="),"_openstat"===h[0]&&(e=h[1]);k=b.split("?");for(c=0;c<k.length;c++)for(g=k[c].split("&"),d=0;d<g.length;d++)h=g[d].split("="),"_openstat"===h[0]&&(e=h[1]);e&&(e=-1<e.indexOf(";")?f.safeDecodeURIComponent(e):T.decode(H.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}function Sa(a){try{delete g[a]}catch(b){g[a]=ba}}function rb(a,b,c,d,e){function k(a){var b=(new Date).getTime();a&&b<a&&(ia+=a-b+20);f.setTimeout(function(){k(b)},20,"timeCorrector")}function n(){var a=(new Date).getTime()+ia;a<S&&(a=S+10);return S=a}function G(){return Math.round((n()-wa)/50)}function N(a,b){b=Math.max(0,Math.min(b,65535));f.mergeArrays(a,[b>>8,b&255])}function t(a,
b){f.mergeArrays(a,[b&255])}function q(a,b){for(b=Math.max(0,b|0);127<b;)f.mergeArrays(a,[b&127|128]),b>>=7;f.mergeArrays(a,[b])}function p(a,b){255<b.length&&(b=b.substr(0,255));f.mergeArrays(a,[b.length]);for(var c=0;c<b.length;c++)N(a,b.charCodeAt(c))}function r(a,b){q(a,b.length);for(var c=0;c<b.length;c++)q(a,b.charCodeAt(c))}function C(a,b,c,d,e,f){for(var y;c&&(y=m.getElementSize(c))&&(!y[0]||!y[1]);)c=m.getElementParent(c);if(!c)return null;y=c[D];if(!y||0>y)return null;var Ta={mousemove:2,
click:32,dblclick:33,mousedown:4,mouseup:30,touch:12}[b];if(!Ta)return null;var k=m.getElementXY(c);c=[];t(c,Ta);q(c,a);q(c,y);q(c,Math.max(0,d[0]-k[0]));q(c,Math.max(0,d[1]-k[1]));/^mouse(up|down)|click$/.test(b)&&(a=e||f,t(c,2>a?1:a==(e?2:4)?4:2));return c}function F(a,b,c,d){b=b[D];if(!b||0>b)return null;var e=[];t(e,31);q(e,a);q(e,b);q(e,c[0]);q(e,c[1]);t(e,0);t(e,0);t(e,d);return e}function J(a,b){var c=[];t(c,3);q(c,a);q(c,b[0]);q(c,b[1]);return c}function ca(a,b,c){var d=[];c=c[D];if(!c||0>
c)return null;t(d,16);q(d,a);q(d,b[0]);q(d,b[1]);q(d,c);return d}function H(a,b,c){var d=[];t(d,28);q(d,a);q(d,b[0]);q(d,b[1]);q(d,c[0]);q(d,c[1]);return d}function O(a,b,c,d){var e=[];t(e,5);q(e,a);N(e,b);t(e,c);a=d[D];if(!a||0>a)a=0;q(e,a);return e}function L(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=[];t(e,29);q(e,a);r(e,c);r(e,d);return e}function z(a){var b=[];t(b,27);q(b,a);return b}
function W(a){var b=[];t(b,14);q(b,a);return b}function ba(a){var b=[];t(b,15);q(b,a);return b}function R(a,b){var c=[];t(c,17);q(c,a);q(c,b[D]);return c}function K(a,b){var c=[];t(c,18);q(c,a);q(c,b[D]);return c}function ma(a,b,c){var d=[];t(d,19);q(d,a);q(d,b[D]);p(d,String(c));return d}function fa(a){var b=a[D];if(!b||0>b||!/^INPUT|SELECT|TEXTAREA$/.test(a.nodeName)||!a.form||ga(a.form))return null;var c=m.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,y=a.form.elements,f=y.length,k=0,g=0;k<f;k++)if(y[k].name==a.name){if(y[k]==a){e=g;break}g++}if(0>e)return null;y=[];t(y,7);q(y,b);q(y,c);q(y,d);r(y,a.name||"");q(y,e);return y}function ha(a,b){var c=m.getFormNumber(b);if(0>c)return null;for(var d=b.elements,e=d.length,
y=[],k=0;k<e;k++)if(!m.isEmptyField(d[k])){var g=d[k][D];g&&0<g&&f.mergeArrays(y,[g])}d=[];t(d,11);q(d,a);q(d,c);q(d,y.length);for(c=0;c<y.length;c++)q(d,y[c]);return d}function ja(){var a=[];t(a,13);return a}function A(a,b,c){a=a.apply(g,b);pa.append(a,c)}function E(a){if(a[D])a:{var b=G(),c=a[D];if(0<c){var d=[];a=m.getElementRegion(a);var e=ya[c],f=a[0]+"x"+a[1],y=a[2]+"x"+a[3];f!=e.pos&&(e.pos=f,t(d,9),q(d,b),q(d,c),q(d,a[0]),q(d,a[1]));y!=e.size&&(e.size=y,t(d,10),q(d,b),q(d,c),q(d,a[2]),q(d,
a[3]));if(d.length){a=d;break a}}a=null}else{(c=m.getElementParent(a))&&E(c);a[D]=da;ya[da]={};da++;if(a.nodeName)if(c=+a[D],!isFinite(c)||0>=c)b=null;else{var d=64,e=0,k=m.getElementParent(a),f=k&&k[D]?k[D]:0;0>f&&(f=0);var y=a.nodeName.toUpperCase(),g=ub[y];g||(d|=2);var h=m.getElementNeighborPosition(a);h||(d|=4);var n=m.getElementRegion(a);(k=k?m.getElementRegion(k):null)&&n[0]==k[0]&&n[1]==k[1]&&n[2]==k[2]&&n[3]==k[3]&&(d|=8);ya[c].pos=n[0]+"x"+n[1];ya[c].size=n[2]+"x"+n[3];a.id&&"string"==typeof a.id&&
(d|=32);(k=m.calcTextChecksum(a))&&(d|=16);var w=m.calcAttribChecksum(a);w&&(e|=2);var u;b:{u=m.getElementChildren(m.getElementParent(a),a.tagName);for(var l=0;l<u.length;l++)if((!u[l].id||"string"!=typeof u[l].id)&&m.calcAttribChecksum(u[l])==w&&m.calcTextChecksum(u[l])==k){u=!0;break b}u=!1}u&&(d|=1,b=m.calcChildrenChecksum(a));u=[];t(u,1);q(u,c);t(u,d);q(u,f);g?t(u,g):p(u,y);h&&q(u,h);d&8||(q(u,n[0]),q(u,n[1]),q(u,n[2]),q(u,n[3]));d&32&&p(u,a.id);k&&N(u,k);d&1&&N(u,b);t(u,e);w&&N(u,w);b=u}else a[D]=
-1,b=null;pa.append(b,void 0);a=fa(a)}pa.append(a,void 0)}function aa(a,b){var c=a&&m.classNameExists(a,"(ym-disable-keys|-metrika-nokeys)");b&&a&&(c=c||!!m.getElementsByClassName("(ym-disable-keys|-metrika-nokeys)",a).length);return c}function ga(a){return a&&m.classNameExists(a,"(ym-disable-submit|-metrika-noform)")}function na(a){var b=B.getTarget(a);if(b&&"SCROLLBAR"!=b.nodeName){if(/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(b.tagName))if(b[D])E(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][D]&&E(c[e]);else E(b)}else E(b);A(C,[G(),a.type,b,B.getPos(a),a.which,a.button])}}function P(a){na(a);a:{var b,c;if(g.getSelection){try{var d=g.getSelection()}catch(tb){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(tb){break a}c&&Ha(c)||aa(c,!0)||b==Z||(Z=b,A(L,[G(),
b]))}}}function u(a){var b=n(),c=b-X;if(!(10>c)){var d=B.getPos(a),e=ea[0]-d[0],f=ea[1]-d[1],e=e*e+f*f;0>=e||16>e&&100>c||20>c&&256>e||(X=b,ea=d,na(a))}}function w(){var a=m.getDocumentScroll(),b=n();10>b-Y||10>Math.abs(a[0]-M[0])&&10>Math.abs(a[1]-M[1])||(Y=b,M=a,A(J,[G(),a]))}function Q(a){if(a=B.getTarget(a)){var b=Math.random(),c=[a.scrollLeft,a.scrollTop];if(a.localId){if(b=T[a.localId],!b||10>Math.abs(c[0]-b[0])&&10>Math.abs(c[1]-b[1]))return}else{for(;T[b];)b=Math.random();a.localId=b}T[a.localId]=
c;a!==h&&(E(a),A(ca,[G(),c,a]))}}function I(){A(H,[G(),m.getViewportSize(),m.getDocumentSize()])}function U(){A(ja,[],!0)}function za(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 Ha(a){return"INPUT"==a.tagName?"password"==a.type||a.name&&oa.test(a.name)||a.id&&oa.test(a.id):!1}function Ua(a,b,c){!(a=B.getTarget(a))||Ha(a)||aa(a)||(E(a),A(O,[G(),b,c,a]))}function Va(a){var b=a.keyCode,c=za(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),Ua(a,b,c|16),ka=!1,f.setTimeout(function(){ka=!0},1),!(67==b&&c&4)||c&1||c&2||Ia()}function Wa(a){ka&&!la&&0!==a.which&&(Ua(a,a.charCode||a.keyCode,za(a)),la=!0,f.setTimeout(function(){la=!1},1))}function Ia(){V||(V=!0,Z&&A(z,[G()]),f.setTimeout(function(){V=!1},1))}function Ja(){ta||(ta=!0,A(W,[G()]))}function ua(){ta&&(ta=!1,A(ba,
[G()]))}function Xa(a){(!ta||a&&!a.fromElement)&&Ja()}function Za(a){a&&!a.toElement&&ua()}function Aa(a){if((a=B.getTarget(a))&&/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(a.tagName)){if(a[D])E(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][D]&&E(b[d]);else E(a)}A(R,[G(),a])}}function Ba(a){(a=B.getTarget(a))&&/^INPUT|SELECT|TEXTAREA|BUTTON$/.test(a.tagName)&&(E(a),A(K,[G(),a]))}function Ca(a){if((a=B.getTarget(a))&&!Ha(a)&&
!aa(a)&&/^INPUT|SELECT|TEXTAREA$/.test(a.tagName)){var b=/^(checkbox|radio)$/.test(a.type)?a.checked:a.value;E(a);A(ma,[G(),a,b])}}function va(a){if((a=B.getTarget(a))&&!ga(a)&&"FORM"==a.nodeName){for(var b=a.elements,c=0;c<b.length;c++)m.isEmptyField(b[c])||E(b[c]);A(ha,[G(),a],!0)}}function Ka(a){w();if(a.touches&&a.touches.length){var b=B.getTarget(a);if(b&&b!=h){E(b);for(var c=0;c<a.touches.length;c++)A(C,[G(),"touch",b,[a.touches[c].pageX,a.touches[c].pageY],0,0])}}}function Da(a){var b=B.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&&(E(b),A(F,[G(),b,B.getPos(a),c]))}}function $a(a){(a=B.getTarget(a))&&"BODY"==a.tagName&&pa.append([],!0)}var pa=new ab({protocol:a,counterId:b,counterType:c,meta:{url:x().href,hitId:d,timezone:Ea,timestamp:Fa}}),ub={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},ia=0,S=0;k(0);var da=1,X=0,ea=[0,0],Y=0,M=[0,0],T={},oa=/^(password|passwd|pswd)$/,ka=!0,la=!1,Z="",V=!1,ta=!0,wa=n(),D="metrikaId_"+Math.random(),ya={},Ga=":submit"+Math.random();if(!f.isMetrikaPlayer()){l.on(h,"mousemove",u);l.on(h,"click,dblclick,mousedown",na);l.on(h,"mouseup",P);l.on(g,"scroll",w);if("onmousewheel"in h)l.on(h,"mousewheel",Da);else l.on(h,"wheel",Da);l.on(g,"beforeunload",U);if(!vb)l.on(g,"unload",U);l.on(g,"resize",
I);l.on(h,"keydown",Va);l.on(h,"keypress",Wa);l.on(h,"copy",Ia);l.on(h,"touchmove,touchstart",Ka);if(h.body)l.on(h,"mouseleave",$a);h.attachEvent&&!g.opera?(l.on(h,"focusin",Xa),l.on(h,"focusout",Za)):(l.on(g,"focus",Ja),l.on(g,"blur",ua),l.on(h,"blur",ua));h.addEventListener?(l.on(h,"scroll",Q),l.on(h,"focus",Aa),l.on(h,"blur",Ba),l.on(h,"change",Ca),l.on(h,"submit",va)):h.attachEvent&&(l.on(h,"focusin",Aa),l.on(h,"focusout",Ba),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))l.on(c[d],"change",Ca);l.on(a[b],"submit",va)}}());(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][Ga]=c,a[b].submit=function(){va({target:this});return this[Ga]()}}})();"0:0"!=m.getDocumentScroll().join(":")&&w();I();e.uploadPage=v(function(e){if("function"==
typeof g.toStaticHTML&&-1<g.toStaticHTML.toString().indexOf("NoScript"))return!1;var f=h.documentElement;if(f&&19E4<(""+f.innerHTML).length)return!1;var k=g.XMLHttpRequest?new g.XMLHttpRequest:new ActiveXObject("Msxml2.XMLHTTP"),n=m.getDocumentCharset(),u="text/html"+(n?";charset="+n:""),w=new wb({protocol:a,counterId:b,counterType:c});if("html"==e)return e=RegExp("<script [^>]*?//mc\\.yandex\\.ru/watch/.*?\x3c/script>","gi"),w.sendContent(m.getDocumentHTML().replace(e,""),u,d,Ea,Fa),!0;k&&(k.open("get",
x().href,!0),k.onreadystatechange=v(function(){if(4==k.readyState){var a=k.getResponseHeader("content-type")||"";n&&-1===a.indexOf("charset=")&&(a=u);w.sendContent(k.responseText,a,d,Ea,Fa)}},"updatePage.1"),k.overrideMimeType&&n&&k.overrideMimeType(u),k.send(null));return!0},"uploadPage")}return{start:function(){pa.activate()},stop:function(){pa.clear();l.un(h,"mousemove",u);l.un(h,"click,dblclick,mousedown",na);l.un(h,"mouseup",P);l.un(h,"mousewheel",Da);l.un(h,"wheel",Da);l.un(g,"scroll",w);l.un(g,
"beforeunload",U);l.un(g,"unload",U);l.un(g,"resize",I);l.un(h,"keydown",Va);l.un(h,"keypress",Wa);l.un(h,"copy",Ia);l.un(h,"touchmove",Ka);l.un(h,"touchstart",Ka);h.body&&l.un(h,"mouseleave",$a);l.un(h,"focusin",Xa);l.un(h,"focusout",Za);l.un(g,"focus",Ja);l.un(g,"blur",ua);l.un(h,"blur",ua);h.removeEventListener?(l.un(h,"scroll",Q),l.un(h,"focus",Aa),l.un(h,"blur",Ba),l.un(h,"change",Ca),l.un(h,"submit",va)):h.detachEvent&&(l.un(h,"focusin",Aa),l.un(h,"focusout",Ba),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)&&l.un(c[d],"change",Ca);l.un(a[b],"submit",va)}}());(function(){for(var a=h.getElementsByTagName("form"),b=0;b<a.length;b++)a[b][Ga]&&(a[b].submit=a[b][Ga])})()},uploadPages:function(a,b){function c(){l.un(h,"DOMContentLoaded",c);l.un(g,"load",c);for(var d=a.split(/\n/),f=x().href,k=/regexp:/,n=0;n<d.length;n++){var u=d[n];if(u)if(k.test(u)){u=sa(u.replace(k,""));try{var w=
new RegExp(u)}catch(Jb){}if(w&&w.test(f)){e.uploadPage(b);break}}else if(-1!==f.indexOf(u)){e.uploadPage(b);break}}}"complete"==h.readyState?c():(l.on(h,"DOMContentLoaded",c),l.on(g,"load",c))}}}var vb=!la(/webkit/)&&la(/gecko/),m={getDocumentCharset:function(){return(""+(h.characterSet||h.charset||"")).toLowerCase()},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},getRootElement:function(){var a=h.documentElement;return"CSS1Compat"==h.compatMode?a:h.body||a},getViewportSize:function(){var a=m.getRootElement();return[a.clientWidth,a.clientHeight]},getDocumentSize:function(){var a=m.getRootElement(),b=m.getViewportSize();return[Math.max(a.scrollWidth,b[0]),Math.max(a.scrollHeight,
b[1])]},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]},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=m.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]},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}},f={isArray:function(a){return"function"==typeof Array.isArray?Array.isArray(a):"[object Array]"==Object.prototype.toString.call(a)},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}};m.getElementChildren=function(a,b){var c=[],d,e,k,n,g;if(a&&(d=a.childNodes))for(n=0,g=d.length;n<g;n++)e=d[n],(k="INPUT"==e.nodeName&&e.type&&"hidden"==e.type.toLocaleLowerCase())||b&&e.nodeName!=b||f.mergeArrays(c,[e]);return c};m.getElementNeighborPosition=function(a){var b=m.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};m.getElementSize=function(a){var b;return a==h.body||
a==h.documentElement?m.getDocumentSize():(b=a.getBoundingClientRect&&a.getBoundingClientRect())?[b.width,b.height]:[a.offsetWidth,a.offsetHeight]};m.getElementRegion=function(a){var b=m.getElementXY(a);a=m.getElementSize(a);return[b[0],b[1],a[0],a[1]]};f.fletcher=function(a){for(var b=a.length,c=0,d=255,e=255,f,g,h;b;){f=21<b?21:b;b-=f;do g="string"==typeof a?a.charCodeAt(c):a[c],c++,255<g&&(h=g>>8,g&=255,g^=h),d+=g,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};m.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,""))};m.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,""))};m.calcChildrenChecksum=function(a){return f.fletcher((a.innerHTML||"").replace(/(<[^>]*>|[\u0000-\u0020])/g,""))};m.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};m.classNameExists=function(a,b){try{return(new RegExp("(?:^|\\s)"+b+"(?:\\s|$)")).test(a.className)}catch(c){return!1}};m.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};m.getElementsByClassName=function(a,b){var c,d,e;b=b||h;c=b.getElementsByTagName("*");d=[];for(e=0;e<c.length;e++)m.classNameExists(c[e],a)&&d.push(c[e]);return d};m.getDocumentTitle=function(){var a=h.title;"string"!=typeof a&&(a=(a=h.getElementsByTagName("title"))&&a.length?a[0].innerHTML:"");return a};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};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(){}};m.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),k=e("script"),n,h;if(!k)return!1;k.type=c.type;k.charset=c.charset;k.src=c.src;c.async&&(k.async=!0);try{return n=d.getElementsByTagName("head")[0],n||(h=d.getElementsByTagName("html")[0],h.appendChild(e("head"))),n.insertBefore(k,n.firstChild),k}catch(N){return!1}};m.removeNode=function(a){var b=a&&a.parentNode;b&&b.removeChild(a)};var F=function(a){a=a||{};f.mixin(this,a);this._initComponent()};F.prototype._initComponent=function(){};F.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=F.inherit;return a.constructor};var ha={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 R=F.inherit({postParams:[],_buildUrl:function(a,b){var c=ha.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}}}),Z=R.inherit({id:"XHR",method:"POST",withCredentials:!0,request:function(a,b,c,d){var e,f;if(/[^a-z0-9.:-]/.test(C.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(n){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 ha.stringify(a.post)},_setHeaders:function(a){a.setRequestHeader("Content-Type","application/x-www-form-urlencoded")}}),bb=Z.inherit({id:"RawBodyXHR",postParams:["body"],_setHeaders:function(){},_preparePostParams:function(a){return a.post.body||
""}}),ia={stringify:function(a){try{return JSON.stringify(a)}catch(b){return"null"}}};f.toJSON=function(a){var b,c,d;if(a===ba)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]!==ba&&(b[b.length]=f.toJSON(c)+":"+f.toJSON(a[c]));return"{"+b.join(",")+"}";default:ia.stringify(a)}};var O=F.inherit({counterId:"",_initComponent:function(){O.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}});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.arrayIndexOf=function(a,b){var c;for(c=0;c<a.length;c++)if(a[c]===b)return c;return-1};f.arrDiff=function(a,b){return f.arrayFilter(a,function(a){return-1===f.arrayIndexOf(b,a)})};var p={getLanguage:function(){return(g.navigator?r.language||r.userLanguage||r.browserLanguage||r.systemLanguage:"").toLowerCase()}};ia.parse=function(a){try{return JSON.parse(a)}catch(b){return null}};f.getTld=function(){var a;this._tld||(a=C.hostname.split("."),this._tld=a[a.length-1]);return this._tld};var xb=
F.inherit({transports:[],postParams:[],dontSendRequests:!1,send:function(a,b,c,d){c=c||function(){};this.dontSendRequests?c.call(d):function k(f){var g;if(f<this.transports.length)try{g=new this.transports[f]({postParams:this.postParams}),g.request(a,b,function(a,b,g){a?c.call(d,b,g):k.call(this,f+1)},this)}catch(N){ra(N,"send by "+(g&&g.id)),k.call(this,f+1)}}.call(this,0)}});R.inherit({id:"beacon",request:function(a,b,c,d){"function"==typeof r.sendBeacon?(b=this._splitParams(b),c.call(d,r.sendBeacon(this._buildUrl(a,
b.get),ha.stringify(b.post)))):c.call(d,!1)}});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};f.setTimeout=function(a,b,c){return f.getNativeFunction("setTimeout")(v(a,c||"setTimeout"),b)};var S=R.inherit({id:"form",enctype:"application/x-www-form-urlencoded",htmlfileOnly:!1,_initComponent:function(){S.superclass._initComponent.apply(this,arguments);"_htmlfile"in S.prototype||(S.prototype._htmlfile=this._createHtmlfile());
this._doc=this._htmlfile||(this.htmlfileOnly?null:h)},request:function(a,b,c,d){var e=this._doc,g,h,l,m;if(!e)return c.call(d,!1);b=this._splitParams(b);g="ifr"+f.random();h=e.createElement("div");h.style.position="absolute";h.style.left="-99999px";h.style.top="-99999px";l=['<iframe name="',g,'"></iframe>','<form action="',this._buildUrl(a,b.get),'" method="post" target="',g,'" enctype="',this.enctype,'">'];f.forEachKey(b.post,function(a){f.mergeArrays(l,['<input type="hidden" autocomplete="off" autocorrect="off"',
' autocapitalize="off" spellcheck="false" name="',a,'"/>'])});f.mergeArrays(l,["</form>"]);h.innerHTML=l.join("");e.body.appendChild(h);m=h.getElementsByTagName("form")[0];f.forEachKey(b.post,function(a,b){m[a].value=b});m.submit();f.setTimeout(function(){e.body.removeChild(h)},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}}),
yb=S.inherit({id:"htmlfile",htmlfileOnly:!0}),V=R.inherit({id:"img",request:function(a,b,c,d){a=this._buildUrl(a,b);b=h.createElement("img");c=c||function(){};b.onload=v(function(){c.call(d,!0)},"TransportImage.request");b.onerror=v(function(){c.call(d,!1)},"TransportImage.request");b.src=a}}),W=F.inherit({counterId:"",onlyCurrentDomain:!1,skipPrefix:!1,_initComponent:function(){var a,b;W.superclass._initComponent.apply(this,arguments);this._domain=null;if(!this.onlyCurrentDomain)for(a=C.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:"")}});W.isEnabled=function(){return(new W({onlyCurrentDomain:!0})).isEnabled()};f.defer=function(a,b,c,d,e){return f.setTimeout(function(){a.apply(c,d||[])},b,e)};var J=xb.inherit({protocol:"",host:"mc.yandex.ru",resource:"",
counterId:"",counterType:0,retry:!1,transports:[Z,V,yb],_initComponent:function(){J.superclass._initComponent.apply(this,arguments);this.retry&&(this._storage=new O)},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 k=g.Ya._metrika.firstReqStatus,h,l;if("process"==k)g.Ya._metrika.firstReqCallbacks=f.mergeArrays(g.Ya._metrika.firstReqCallbacks||[],[[this,arguments]]);else return k||(g.Ya._metrika.firstReqStatus="process"),
k={},this.counterType&&(k["cnt-class"]=this.counterType),f.mixin(k,b),c.st=Math.round((new Date).getTime()/1E3),c.u=J._userID,h=[this.protocol,"//",this.host,"/"+this.resource+"/"+this.counterId].join(""),l=[],c&&(f.forEachKey(c,function(a,b){"t"!=a&&f.mergeArrays(l,[a,b])}),c.t&&f.mergeArrays(l,["t",c.t])),l.length&&(k["browser-info"]=l.join(":")),J.superclass.send.call(this,h,k,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)))}});J.initCookie=function(){var a=new W,b=a.read("uid");b||(b=Math.round((new Date).getTime()/1E3),b=b+""+f.random(),a.create("uid",b,1036800));J._userID=b};J.retransmit=function(){var a=new O,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 J({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.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._playerRegexp=/^.+\.mtproxy\.yandex\.net$/;f.isMetrikaPlayer=function(){return"MetrikaPlayer"==g.name||this._playerRegexp.test(g.location.hostname)};p._silverlightVersion="";p.getSilverlightVersion=function(){var a,b,c,d;if(!p._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),p._silverlightVersion=d.join(".")}catch(e){}else if(a=g.navigator,a=a.plugins&&a.plugins["Silverlight Plug-In"])p._silverlightVersion=a.description;return p._silverlightVersion||""};p._flashVersion=0;p.getFlashVersion=function(){var a,b,c;if(!p._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?p._flashVersion=c:b&&(p._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"))p._flashVersion=b.split(" ")[1].replace(/,/g,
".").replace(/[^.\d]/g,"")}catch(d){}return p._flashVersion};p.getJavaEnabled=function(){try{return r.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};p.getFingerPrint=function(){var a=[],b,c;if(r.plugins&&r.plugins.length)for(c=0;c<r.plugins.length;c++)b=r.plugins[c],f.mergeArrays(a,[b.name,b.version,b.description,b.filename]);if(r.mimeTypes&&r.mimeTypes.length)for(c=0;c<
r.mimeTypes.length;c++)b=r.mimeTypes[c],f.mergeArrays(a,[b.type,b.description,b.suffixes]);return f.fnv32a(a.join(";"))+"01"};p.getPlatform=function(){var a="";try{a=""+r.platform}catch(b){}return a};p.getNotificationPermission=function(){var a;try{a=Notification.permission}catch(b){}switch(a){case "denied":return 1;case "granted":return 2}};p.isIframe=function(){try{return g.top!=g.self}catch(a){return!1}};p._nMap={other:"0",none:"1",unknown:"2",wifi:"3",ethernet:"4",bluetooth:"5",cellular:"6",wimax:"7",
mixed:"8"};p.netType=function(){var a=(r.connection||{type:""}).type;return p._nMap[a]||a};p.isSafari=function(){try{return r.vendor&&-1<r.vendor.indexOf("Apple")&&r.userAgent&&!r.userAgent.match("CriOS")}catch(a){}return!1};var cb={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);m.removeNode(this)};a.onerror=function(){b._saveReq(!0);m.removeNode(this)};this._setReqStatus("process");a.src=this.url+String.fromCharCode(97,100,118,101,114,116,46,103,105,102);p.isSafari()&&(a.style.position="absolute",a.style.visibility="hidden",a.style.width="0px",a.style.height="0px",m.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 W);return this._ls}},T={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}},H={abc:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",tail:"+/=",tailSafe:"*-_",encode:function(a,b){var c=(H.abc+(b?H.tailSafe:H.tail)).split(""),d=a.length,e=[],g=d-d%3,h,l;for(l=0;l<g;l+=3)h=(a[l]<<16)+(a[l+1]<<8)+a[l+2],f.mergeArrays(e,[c[h>>18&63],c[h>>12&63],c[h>>6&63],c[h&63]]);switch(d-g){case 1:h=a[g]<<4;f.mergeArrays(e,
[c[h>>6&63],c[h&63],c[64],c[64]]);break;case 2:h=(a[g]<<10)+(a[g+1]<<2),f.mergeArrays(e,[c[h>>12&63],c[h>>6&63],c[h&63],c[64]])}return e.join("")},decode:function(a,b){for(var c=H.abc+(b?H.tailSafe:H.tail),d=0,e="",f,g,h,l,t;a.length%4;)a+="=";do{f=c.indexOf(a.charAt(d++));g=c.indexOf(a.charAt(d++));l=c.indexOf(a.charAt(d++));t=c.indexOf(a.charAt(d++));if(0>f||0>g||0>l||0>t)return null;h=f<<18|g<<12|l<<6|t;f=h>>16&255;g=h>>8&255;h&=255;e=64==l?e+String.fromCharCode(f):64==t?e+String.fromCharCode(f,
g):e+String.fromCharCode(f,g,h)}while(d<a.length);return e}},da=J.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(){da.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:x().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:x().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://"+x().hostname+"/"+encodeURIComponent(a):x().href,d=m.getDocumentTitle(),e=a?x().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:x().href,modes:a.modes})},sendExtLink:function(a){this._hitExt({url:a.url,title:a.title||"",referrer:x().href,vParams:a.vParams,modes:{ar:!0,ln:!0,ut:wa},callback:a.callback,ctx:a.ctx})},sendFileUpload:function(a){this._hitExt({url:a.url,title:a.title||"",referrer:x().href,vParams:a.vParams,modes:{ar:!0,ln:!0,dl:!0},callback:a.callback,ctx:a.ctx})},sendNotBounce:function(a,b){this._hitExt({url:x().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&&(l[a]=b)}var c,d,e,g,h,l,m;f.isMetrikaPlayer()||(c=a.modes||{},d=a.browserInfo||{},g="undefined"!=typeof a.referrer?a.referrer:oa.lastReferrer,h=a.url||"",l={},c.ar&&!c.onlyData&&(g=null===g||""===g?"":this._prepareHitUrl(g),h=this._prepareHitUrl(a.url)),b("page-ref",f.trim(g,qa)),b("page-url",f.trim(h,qa)),xa()?b("ut",wa):"undefined"!=typeof c.ut&&
b("ut",f.trim(c.ut,zb)),b("exp",a.experiments),a.vParams&&(h=f.toJSON(a.vParams),this.trimParams&&h.length>Ab?m=!0:b("site-info",h)),c.saveRef&&(oa.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(l,d,function(){m&&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=
x(),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,G,N){function k(a,b){a&&b&&(v[a]=b)}function n(a){b[a]&&k(a,"1")}var v={},x;b=b||{};d=d||L.getTimestamp();e=e||L.getTimezone();
k("j",p.getJavaEnabled()?"1":"");k("nt",p.netType());X&&k("s",X.width+"x"+X.height+"x"+(X.colorDepth||X.pixelDepth));g.devicePixelRatio&&k("sk",g.devicePixelRatio);p.isIframe()&&k("ifr","1");k("adb",cb.getVal());k("f",p.getFlashVersion());k("l",p.getSilverlightVersion());k("fpr",p.getFingerPrint());k("cn",this.counterNum);b.pa||(x=m.getViewportSize(),k("w",x[0]+"x"+x[1]));k("z",e);k("i",d);k("et",Math.round((new Date).getTime()/1E3));k("en",m.getDocumentCharset());k("v",M);k("c",r.cookieEnabled?"1":
"");k("la",p.getLanguage());k("ntf",p.getNotificationPermission());f.random(100)||k("np",H.encode(T.encode(f.trim(p.getPlatform(),100))));h&&k("wh","1");e="ar ln dl ad nb pa pq pv ex".split(" ");for(d=0;d<e.length;d++)n(e[d]);e=["va","vt","sn","sa","he"];b.nb&&e.push("cl");for(d=0;d<e.length;d++)h=e[d],k(h,b[h]);e=new O({counterId:c});e.isEnabled()&&(c=e.getStorageId(),(d=e.get("reqNum"))?d++:d=1,e.set("reqNum",d),e.get("reqNum")==d?(k("ls",c),k("rqn",d)):(e.remove("reqNum"),e.clearStorageId(),1<
d&&(k("ls",c),k("rqn",0))));k("rn",f.random());k("hid",l);k("ds",nb(N));N._firstPaint||(N._firstPaint=ob(),k("fp",N._firstPaint));if(G){g.name||(g.name=Math.round(65535*Math.random()));if(l=+g.name)0>l&&(l*=-1),l%=65535;k("wn",l||f.fletcher(g.name));try{g.history&&k("hl",String(g.history.length))}catch(sb){}}l="";this.sendTitle&&(l=this._getTitle(a));k("t",l);return v},_getTitle:function(a){a="undefined"==typeof a?(a=m.getDocumentTitle())?f.trim(a,db):"":f.trim(a,db);return a}}),R=R.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]=v(function(){try{delete g[e]}catch(n){g[e]=ba}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}}),La=da.inherit({transports:[R],trimParams:!0,_initComponent:function(){La.superclass._initComponent.apply(this,arguments);this._ilStorage=new O({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=H.encode(T.encode(f.trim(c,eb))));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})}}),Bb=F.inherit({cid:3,cnt:0,_initComponent:function(){this._storage=new O},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 La({protocol:"https:",counterType:this.cnt,counterId:this.cid,sendTitle:!1,
dontSendRequests:this.dontSendRequests,fake:!0}));return this._sender}}),Cb=F.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),xa()?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 bb({method:"GET"}),b=b||function(){},d.request(this.baseUrl+this.baseTld+"/sync_cookie_get",null,function(g,h){var k,l,n,m=0,p=0,v;if(g){k=
ia.parse(h);try{l=k.sync_token,v=k.sync_ok}catch(sb){return b(),!1}d.setMethod("POST");c=f.arrDiff(a,v);if(m=c.length)for(n=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){p++;m===p&&b();c&&(c=n.get("synced")||{},c[a]=+new Date,n.set("synced",c))}):(p++,m===p&&b())})})(c[k]);else b()}else b()})):b()},_getCn:function(){this._cn||(this._cn=new Bb({fake:!0,dontSendRequests:this.dontSendRequests}));
return this._cn},_getLs:function(){this._ls||(this._ls=new O);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=r.languages?r.languages[0]:p.getLanguage()}catch(b){}a=(a||"").toLowerCase().split("-")[0];return this.langToDomain[a]||"ru"}});p.isAndroid=v(function(){var a=r.userAgent.toLowerCase();return-1<a.indexOf("android")&&
-1<a.indexOf("mobile")},"",!0);var L={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+ha.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 O);return this._ls},
_getReq:function(){this._req||(this._req=new V);return this._req}},Db={sync:v(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 bb({method:"GET",withCredentials:!1}),d=a.length,function k(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):k.call(this,f+1)},this):this._save(!1)}.call(this,0))},"ds"),_save:function(a,b,c){a&&(new da({protocol:"https:",counterType:0,counterId:3,sendTitle:!1,
fake:!0})).sendDevice({data:f.trim(b),port:c});ea.save("ds",L.getMinutes())},_is:function(){try{return!!g.Ya._metrika.dSync}catch(a){return!1}},_enabled:function(){var a=60<L.getMinutes()-ea.getNum("ds");return p.isAndroid()&&0==x().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){}}},B={getPos:function(a){var b=m.getRootElement(),c=m.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==ba?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}};B.dispatchCustomEvent=v(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");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 l=F.inherit({_initComponent:function(){l.superclass._initComponent.apply(this,arguments);this._listeners=[]},on:function(a,b,c,d,e){e=l._getOpts(e);b=b.split(",");var f=b.length,h=this._listeners,m,p,t;for(t=0;t<
f;t++)m=b[t],p=v(function(a){c.call(d||this,a||g.event)},"on"+m),h[h.length]=[a,m,c,d,e,p],a.addEventListener?a.addEventListener(m,p,l._prepOpts(e)):a.attachEvent&&a.attachEvent("on"+m,p)},un:function(a,b,c,d,e){e=l._getOpts(e);var g=this._listeners,h=g.length,m,p;for(m=0;m<h;m++)if(p=g[m],p[0]==a&&p[1]==b&&p[2]==c&&p[3]==d&&f.isEqual(p[4],e)){g.splice(m,1);this._removeListener(a,b,p[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,l._prepOpts(d)):a.detachEvent&&a.detachEvent("on"+b,c)}});l.supportsPassive=function(){var a;if(l._supportsPassive!==ba)return l._supportsPassive;l._supportsPassive=!1;try{a=Object.defineProperty({},"passive",{get:function(){l._supportsPassive=!0}}),g.addEventListener("test",null,a)}catch(b){}return l._supportsPassive};l._getOpts=function(a){return f.mixin({capture:!0,passive:!0},a||{})};
l._prepOpts=function(a){return l.supportsPassive()?a:!!a.capture};l.on=function(){l._instance||(l._instance=new l);l._instance.on.apply(l._instance,arguments)};l.un=function(){l._instance&&l._instance.un.apply(l._instance,arguments)};l.ready=function(a){var b=g.performance,c;"object"==typeof b&&b.timing&&b.timing.domContentLoadedEventStart?a():(c=function(){l.un(h,"DOMContentLoaded",c);l.un(g,"load",c);a()},l.on(h,"DOMContentLoaded",c),l.on(g,"load",c))};var oa={lastReferrer:null},wb=J.inherit({resource:"webvisor",
transports:[Z,S],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":x().href,"wv-hit":c,"wv-data":H.encode(T.encode(a))};return 245E3<a["wv-data"].length?!1:this.send(a,{z:d,i:e,pct:b||""},f,g)}});f.throttle=function(a,b,c,d){var e,g,h;return function(){g=arguments;h=this;e||function(){e=null;g&&(a.apply(c||h,g),g=null,e=f.setTimeout(arguments.callee,b,d))}()}};var fb=F.inherit({storage:null,storageKey:"dataBuffer",
maxBufferSize:255,flushTimeout:1E4,active:!0,meta:null,onFlush:function(){},onFlushCtx:null,bufferExpireTime:864E5,_initComponent:function(){var a;fb.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})}});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 Y=F.inherit({sampling:1,counterId:26302566,_initComponent:function(){Y.superclass._initComponent.apply(this,arguments);this._sender=
new da({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:C.href,title:"",referrer:"",vParams:a})}}),Eb=J.inherit({resource:"webvisor",retry:!0,postParams:["wv-data"],sendPacket:function(a,b,c,d,e,h,l,m){var k,n;if(!a||!a.length)return!1;k=H.encode(a,!0);0==k.indexOf("AAAAAAAAADw")&&g.Error&&(n=Error(),"string"==typeof n.stack&&(new Y({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":k};return this.send(a,{z:e,i:h},l,m)}}),ab=fb.inherit({protocol:"",counterId:"",counterType:"",meta:null,maxBufferSize:7500,flushTimeout:3E4,storageKey:"visorbuff",active:!1,_initComponent:function(){this.storage=new O({counterId:this.counterId});this._sender=new Eb({protocol:this.protocol,counterId:this.counterId,counterType:this.counterType});ab.superclass._initComponent.apply(this,
arguments)},onFlush:function(a,b,c){this._sender.sendPacket(a,b.url,b.hitId,c,b.timezone,b.timestamp)}});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}):{}};p.isIE=function(){return h&&!h.addEventListener||!1};var ja={};ja._cookie=new W({onlyCurrentDomain:!0});ja.log=v(function(){var a=
-1<C.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 Fb=J.inherit({resource:"clmap",retry:!0,transports:[V],sendClick:function(a,b,c,d){this.send({"page-url":a,"pointer-click":b},{},c,d)}}),Gb=F.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 Fb({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)l.on(h,"click",this._handler,this);this._start=!0},stop:function(){this._start&&l.un(h,"click",this._handler,this);this._start=!1},setTrackHash:function(a){this.isTrackHash=a},_isIgnore:function(a){return m.classNameExists(a,"(ym-disable-clickmap|ym-clickmap-ignore)")},_handler:function(a){a={el:B.getTarget(a),pos:B.getPos(a),button:B.getMouseButton(a),time:+new Date};var b,c;this._isTrackingClick(a)&&(b=m.getElementSize(a.el),
c=m.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=x().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+=m.getElementNeighborPosition(a)||"",a=a.parentNode;return f.trim(b,this.MAX_LEN_PATH)}}),gb=F.inherit({_initComponent:function(){gb.superclass._initComponent.apply(this,arguments);this._executedMsgs={};l.on(g,"message",this._onMessage,this)},_buildRemoteIframe:function(a){var b=f.getNativeFunction("createElement",h)("div"),c=h.body||h.documentElement,
d;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(){m.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=ia.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};L.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};L.getTimezone=function(){return-(new Date).getTimezoneOffset()};f.bind=function(a,b){return function(){return a.apply(b||
this,arguments)}};var hb=F.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,l;d=0;for(l=a.length;d<l;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}})}}),
Hb={match:function(){this.enabled()&&l.ready(function(){var a=f.getNativeFunction("createElement",h)("iframe");a.onload=function(){ea.save("cm",L.getMinutes());m.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<L.getMinutes()-ea.getNum("cm")&&"tr"==f.getTld()}};f.safeDecodeURIComponent=function(a){try{return decodeURIComponent(a)}catch(b){return""}};
ha.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 P=[],C=x(),Ea=L.getTimezone(),Fa=L.getTimestamp(),r=g.navigator,X=g.screen,M="759",zb=64,qa=p.isIE()?512:2048,Ab=p.isIE()?512:2048,db=p.isIE()?100:400,eb=100,wa="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,
Ib=+new Date,Ma,ka,aa;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=M;aa=!!Ya._metrika.oo;g.Ya.Metrika=function(a,b,c,d){var e=this;return v(function(){function k(u){var k=!1,Q,I,p;if(Ya._metrika.hitParam[ca]){if(1!=c||Ya._metrika.counters[ca])return!1;k=!0}Ya._metrika.counters[ca]=
e;Ya._metrika.hitParam[ca]=1;e._webvisor=!d&&(z&&z.webvisor||!1);e._directCampaign=z&&z.directCampaign;z&&z.trackHash&&R(!0);if(!d&&!k){e.replacePhones();Q=new W({counterId:a});I=Q.read("visorc");"b"!=I&&"w"!=I&&(I="");if(!Q.isEnabled()||la("opera mini"))I="b";k=new Cb({dontSendRequests:aa});p=function(d){var k=new La({protocol:"https:",counterType:c,counterId:a,trackHash:A,hitId:ga,webvisor:e._webvisor,counter:e,dontSendRequests:aa,counterNum:V}),w={ut:P,he:z?~~z.httpError:0,ad:1==c&&g.Ya&&g.Ya.Direct,
pv:!0,saveRef:!0};Ma=+new Date;k.sendHit({url:C.href,title:m.getDocumentTitle(),referrer:h.referrer,vParams:b,userParams:X,experiments:T,modes:w,visitColor:I,hasPrerender:u,ts:Fa,tz:Ea,callback:function(c,u){var k,w;ea.init(u);Hb.match();ja.log("PageView. Counter ",a,". URL: ",C.href,". Referrer: "+h.referrer,". Params: ",b);ka||(ka=+new Date);c=c||{};w=c.webvisor||{};if(ma){k=+w.recp;if(!isFinite(k)||0>k||1<k)I="w";I||(I=ga%1E4/1E4<k?"w":"b");Q.create("visorc",I,30);"w"==I?(ma.start(),k=w.arch_type,
(w=w.urls)&&k&&"none"!=k&&ma.uploadPages(w,k)):ma.stop()}w=c.mp2;Q.erase("mp2_substs");if(w){b:{k=w.conditions;var m;if(k&&k.length)for(m=0;m<k.length;m++){var n;n=k[m];if("ref"==n.type)n=pb(n);else if("adv"==n.type){var p,q,t,v,r;p=n;v=Ya._metrika.counter._directCampaign;q=p.ServiceNamePattern;var U=p.RefererPattern;n=v?p.direct_orders:p.direct_camp;var za=h.referrer,x=ha.parse(C.search),z=qb(C.search,C.hash),A={};t=["source","medium","campaign","term","content"];for(r=0;r<t.length;r++)x["utm_"+
t[r]]&&(A[t[r]]=x["utm_"+t[r]]);var B=v?"direct.yandex.ru":z&&z.service||A.source;r=!1;if(!r&&q&&q.length)for(t=0;t<q.length;t++)if((new RegExp(q[t],"i")).test(B)){r=!0;break}if(!r&&!p.yandex_direct&&U&&U.length)for(q=0;q<U.length;q++)if((new RegExp(U[q],"i")).test(za)){r=!0;break}!r&&p.google_adwords&&x.gclid&&(r=!0);if(r&&n&&n.length&&(r=!1,v=v||z&&z.campaign||A&&A.campaign))for(p=0;p<n.length;p++)if(n[p]==v){r=!0;break}n=r}else n=!1;if(n){k[m].track_id&&Q.create("mp2_track",k[m].track_id,43200);
break b}}}k=Q.read("mp2_track");w=w.substs&&w.substs[k];k&&w?(Q.create("mp2_substs",f.toJSON(w)),w=Qa(w),e.params("__ym",w?"mp_trackid":"mp_trackid_bad",k)):Ra()}else Ra();l.on(g,"load",e.replacePhones,e);e._inited=!0;d&&d()}})};k.sync(p)}r();z&&(z.enableAll?(n(!0),t(!0),H()):(z.clickmap&&t(z.clickmap),z.trackLinks&&n(z.trackLinks),z.accurateTrackBounce&&H(z.accurateTrackBounce)),(z.ecommerce||z.useDataLayer)&&new hb({counter:e,prefsEcommerce:z.ecommerce}),z.triggerEvent&&jb(function(){B.dispatchCustomEvent("yacounter"+
a+"inited")},0));e._webvisor&&!aa&&(ma=new rb("https:",a,c,ga,e))}function n(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 r(){n(!1);l.on(h,"click",function(a){e._trackLinks&&e._trackLinks.on&&F(a)})}function F(a){var b=kb(a),c,d,e,g;if(b){a=!1;d=(c=""+b.href)?c.split(/\?/)[0]:"";e=function(a){var d=Na(b);K.sendClickLink({url:c,title:c==d?"":d,modes:a})};if(ib.test(d)||ib.test(c)||Oa(c,fa)||
Oa(d,fa))a=!0;g=m.classNameExists(b,"ym-disable-tracklink");d=m.classNameExists(b,"ym-external-link");g||(g={ln:!0,dl:a},d?e(g):(d=b.hostname||f.parseUrl(b.href).hostname||"",lb(x().hostname,d)?a?(g.ln=!1,e(g)):(a=Na(b))&&a!=c&&ra.set("il",f.trim(a,eb)):c&&-1!=c.search(/^ *(data|javascript):/i)||(g.ut=wa,e(g))))}}function t(b){"undefined"==typeof b&&(b=!0);!0===b&&(b={});e._clickmap&&e._clickmap.destroy();b&&(e._clickmap=new Gb({dontSendRequests:aa,filter:b.filter,ignoreTags:b.ignoreTags,quota:b.quota,
isTrackHash:b.isTrackHash,protocol:"https:",counterId:a,counterType:c,startTime:Ib}))}function q(a,b){function c(){var c;t||(q&&f.clearTimeout(q),c=u?m:m+ +new Date-n,c=b-c,0>c&&(c=0),q=f.setTimeout(function(){t=!0;e(!1);a()},c,"trackUserTime"))}function d(){w||(k=!0,u=!1,w=!0,c())}function e(a){var b;for(b=0;b<r.length;b+=3)if(a)l.on(r[b],r[b+1],r[b+2]);else l.un(r[b],r[b+1],r[b+2])}var k=!1,w=!1,u=!0,m=0,n=+new Date,q=null,t=!1,r;p.isIE()?f.setTimeout(a,b,"trackUserTime"):(r=[g,"blur",function(){u=
k=w=!0;m+=+new Date-n;n=+new Date;c()},g,"focus",function(){k||w||(m=0);n=+new Date;k=w=!0;u=!1;c()},h,"click",d,h,"mousemove",d,h,"keydown",d,h,"scroll",d],e(!0),c())}function H(b){var c,d;"number"!=typeof b&&(b=15E3);e._isAccurateTrackBounce||(e._isAccurateTrackBounce=!0,c=new O({counterId:a}),d=c.get("lastHit"),c.set("lastHit",+new Date),((c=c.get("lastHit"))&&(!d||d<c-18E5)||!mb(h.referrer,x().href)||.1>Math.random())&&q(function(){e.notBounce()},b))}function L(a){var b=function(){var a=x().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 U(){var d=b();d!==c&&(a(),c=d);na=f.setTimeout(U,200,"trackHash")})()}function R(a){if(!1===a)A&&("onhashchange"in g?l.un(g,"hashchange",S):f.clearTimeout(na),A=!1);else if(a=S,!A){if("onhashchange"in g)l.on(g,"hashchange",a);else L(a);A=!0}K.setTrackHash(A);e._trackHash=A}function S(){var a={ut:P,ad:1==c&&g.Ya&&g.Ya.Direct,wh:!0,saveRef:!0,pv:!0};Y=oa.lastReferrer=Z;K.sendAjaxHit({url:x().href,
title:m.getDocumentTitle(),referrer:Y,modes:a});Z=x().href}function M(a,b,c){a=xa.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 ca,P="",T,X,z,Y="",Z=oa.lastReferrer=C.href,V,K,ma,fa,qa,ra,A,E,sa,ga;Ya._metrika.counter||(Ya._metrika.counter=e);"object"==typeof a&&(z=a,d=a.defer,P=a.ut,c=a.type,b=a.params,X=a.userParams,T=z.experiments,sa=z.nck,a=a.id);a=a||0;/^\d+$/.test(a)||(a=0);c=c||0;ca=a+":"+
c;if(Ya._metrika.counters[ca])return Ya._metrika.counters[ca];ga=Ya._metrika.hitId;Ya._metrika.counterNum++;V=Ya._metrika.counterNum;sa||(J.initCookie(),cb.init());J.retransmit();K=new da({protocol:"https:",counterType:c,counterId:a,hitId:ga,counter:e,dontSendRequests:aa,counterNum:V});e.replacePhones=v(function(){var b,c;try{(b=(new W({counterId:a})).read("mp2_substs"))&&(c=ia.parse(b))&&Qa(c,!0)}catch(Q){}return e},"counter.replacePhones");e.reachGoal=v(function(b,c,d,f){2<=arguments.length&&"function"===
typeof c&&(f=d,d=c,c=ba);ja.log("Reach goal. Counter: "+a+". Goal id: "+b+". Params: ",c);K.sendGoal(b,{vParams:c,callback:d,ctx:f});return e},"counter.reachGoal");e.trackLinks=v(function(a){n(a);return e},"counter.trackLinks");ra=new O({counterId:a});e.hit=v(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),ja.log("PageView. Counter "+a,". URL: "+b,". Referrer: "+d,". Params: ",g),K.sendHit({url:b,title:c,referrer:d,vParams:g,callback:h,ctx:k}));return e},
"counter.hit");e.params=v(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)])),ja.log("User params. Counter "+a+". Params: ",k[0]),K.sendParams(k[0],g,h));return e},"counter.params");e.file=v(function(a,b){a&&(b=b||{},K.sendFileUpload({url:a,title:b.title,vParams:b.params,
callback:b.callback,ctx:b.ctx}));return e},"counter.file");e.extLink=v(function(a,b){a&&(b=b||{},K.sendExtLink({url:a,title:b.title,vParams:b.params,callback:b.callback,ctx:b.ctx}));return e},"counter.extLink");e.notBounce=v(function(a){var b=0;a=a||{};Ma&&ka&&(b=ka-Ma);K.sendNotBounce(b,{callback:a.callback,ctx:a.ctx});return e},"counter.notBounce");fa=[];e.addFileExtension=function(a){"string"==typeof a?fa.push(a):fa=fa.concat(a);return e};e.clickmap=function(a){t(a);return e};e.accurateTrackBounce=
function(a){H(a);return e};var na=null;A=!1;e.trackHash=function(a){R(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 xa={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=v(function(a,b){M("detail",a,b);return e},"ecommerce.detail");e.ecommerceAdd=v(function(a,b){M("add",a,b);return e},"ecommerce.add");e.ecommerceRemove=v(function(a,b){M("remove",a,b);return e},"ecommerce.remove");e.ecommercePurchase=v(function(a,b){M("purchase",a,b);return e},"ecommerce.purchase");
e.userParams=v(function(a,b,c){f.isObject(a)&&e.params({__ymu:a},b||function(){},c);return e},"uparams");e.experiments=v(function(a,b,c){K.sendExperiments({callback:b,ctx:c,experiments:a});return e},"exps");e.id=e.setUserID=v(function(a,b,c){(f.isString(a)||f.isNumber(a))&&e.params({__ym:{user_id:a}},b||function(){},c);return e},"id");qa=new W;e.getClientID=v(function(){return qa.read("uid")},"guid");e.enableAll=function(){n(!0);t(!0);H();return e};e.ds=v(function(){Db.sync()});e.uploadPage=function(){};
e._performanceTiming=Pa;a&&("prerender"==h.webkitVisibilityState?(K.sendPrerenderHit({url:C.href,title:m.getDocumentTitle(),referrer:h.referrer}),E=function(){"prerender"!=h.webkitVisibilityState&&(l.un(h,"webkitvisibilitychange",E),k(!0))},l.on(h,"webkitvisibilitychange",E)):k(!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,l;for(l=0;l<b.length;l++)d=b[l],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:C.href});(new Y({sampling:.001})).logParams({timings8:c})}})();g.Ya._metrika.remoteCtrlInited||(g.Ya._metrika.remoteCtrlInited=!0,new gb);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(){var a=g.yandex_metrika_callback,
b=g.yandex_metrika_callbacks,c;"function"==typeof a&&a();if("object"==typeof b)for(a=0;a<b.length;a++)if(c=b[a])b[a]=null,c();Sa("yandex_metrika_callback");Sa("yandex_metrika_callbacks")})();g.Ya.Metrika.informer=function(a){var b=!!Ya.Metrika._informer;Ya.Metrika._informer=a;b||m.loadScript({src:"https://informer.yandex.ru/metrika/informer.js"})};l.on(h,"click",v(function(a){var b=B.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}),B.prevent(a))},"adv-inf"),null,{passive:!1})})(this,this.document);
