PageSourceSearch

https://greenmast.ru/bitrix/cache/js/s1/gvozdevsoft_profigs_s1/tem…bebff7cbde4ec1feb1c0_v1.js?1790151767517319

js greenmast.ru collected 2026-10-05 00:27:48 UTC 517,319 bytes, 5,881 lines download raw bytes

1
2; /* Start:"a:4:{s:4:"full";s:79:"/local/templates/gvozdevsoft_profigs_s1/lib/jquery-3.3.1.min.js?173827436886927";s:6:"source";s:63:"/local/templates/gvozdevsoft_profigs_s1/lib/jquery-3.3.1.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
3/*! jQuery v3.3.1 | (c) JS Foundation and other contributors | jquery.org/license */�
vendor: 86,843 bytes, lines 3-4
3
4!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){"use strict";var n=[],r=e.document,i=Object.getPrototypeOf,o=n.slice,a=n.concat,s=n.push,u=n.indexOf,l={},c=l.toString,f=l.hasOwnProperty,p=f.toString,d=p.call(Object),h={},g=function e(t){return"function"==typeof t&&"number"!=typeof t.nodeType},y=function e(t){return null!=t&&t===t.window},v={type:!0,src:!0,noModule:!0};function m(e,t,n){var i,o=(t=t||r).createElement("script");if(o.text=e,n)for(i in v)n[i]&&(o[i]=n[i]);t.head.appendChild(o).parentNode.removeChild(o)}function x(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?l[c.call(e)]||"object":typeof e}var b="3.3.1",w=function(e,t){return new w.fn.init(e,t)},T=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;w.fn=w.prototype={jquery:"3.3.1",constructor:w,length:0,toArray:function(){return o.call(this)},get:function(e){return null==e?o.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=w.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return w.each(this,e)},map:function(e){return this.pushStack(w.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(o.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:s,sort:n.sort,splice:n.splice},w.extend=w.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||g(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)n=a[t],a!==(r=e[t])&&(l&&r&&(w.isPlainObject(r)||(i=Array.isArray(r)))?(i?(i=!1,o=n&&Array.isArray(n)?n:[]):o=n&&w.isPlainObject(n)?n:{},a[t]=w.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},w.extend({expando:"jQuery"+("3.3.1"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==c.call(e))&&(!(t=i(e))||"function"==typeof(n=f.call(t,"constructor")&&t.constructor)&&p.call(n)===d)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e){m(e)},each:function(e,t){var n,r=0;if(C(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},trim:function(e){return null==e?"":(e+"").replace(T,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(C(Object(e))?w.merge(n,"string"==typeof e?[e]:e):s.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:u.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r,i=[],o=0,a=e.length,s=!n;o<a;o++)(r=!t(e[o],o))!==s&&i.push(e[o]);return i},map:function(e,t,n){var r,i,o=0,s=[];if(C(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&s.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&s.push(i);return a.apply([],s)},guid:1,support:h}),"function"==typeof Symbol&&(w.fn[Symbol.iterator]=n[Symbol.iterator]),w.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){l["[object "+t+"]"]=t.toLowerCase()});function C(e){var t=!!e&&"length"in e&&e.length,n=x(e);return!g(e)&&!y(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}var E=function(e){var t,n,r,i,o,a,s,u,l,c,f,p,d,h,g,y,v,m,x,b="sizzle"+1*new Date,w=e.document,T=0,C=0,E=ae(),k=ae(),S=ae(),D=function(e,t){return e===t&&(f=!0),0},N={}.hasOwnProperty,A=[],j=A.pop,q=A.push,L=A.push,H=A.slice,O=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},P="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",I="\\["+M+"*("+R+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+R+"))|)"+M+"*\\]",W=":("+R+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+I+")*)|.*)\\)|)",$=new RegExp(M+"+","g"),B=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),F=new RegExp("^"+M+"*,"+M+"*"),_=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),z=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),X=new RegExp(W),U=new RegExp("^"+R+"$"),V={ID:new RegExp("^#("+R+")"),CLASS:new RegExp("^\\.("+R+")"),TAG:new RegExp("^("+R+"|[*])"),ATTR:new RegExp("^"+I),PSEUDO:new RegExp("^"+W),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+P+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},G=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Q=/^[^{]+\{\s*\[native \w/,J=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,K=/[+~]/,Z=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),ee=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},te=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ne=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},re=function(){p()},ie=me(function(e){return!0===e.disabled&&("form"in e||"label"in e)},{dir:"parentNode",next:"legend"});try{L.apply(A=H.call(w.childNodes),w.childNodes),A[w.childNodes.length].nodeType}catch(e){L={apply:A.length?function(e,t){q.apply(e,H.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function oe(e,t,r,i){var o,s,l,c,f,h,v,m=t&&t.ownerDocument,T=t?t.nodeType:9;if(r=r||[],"string"!=typeof e||!e||1!==T&&9!==T&&11!==T)return r;if(!i&&((t?t.ownerDocument||t:w)!==d&&p(t),t=t||d,g)){if(11!==T&&(f=J.exec(e)))if(o=f[1]){if(9===T){if(!(l=t.getElementById(o)))return r;if(l.id===o)return r.push(l),r}else if(m&&(l=m.getElementById(o))&&x(t,l)&&l.id===o)return r.push(l),r}else{if(f[2])return L.apply(r,t.getElementsByTagName(e)),r;if((o=f[3])&&n.getElementsByClassName&&t.getElementsByClassName)return L.apply(r,t.getElementsByClassName(o)),r}if(n.qsa&&!S[e+" "]&&(!y||!y.test(e))){if(1!==T)m=t,v=e;else if("object"!==t.nodeName.toLowerCase()){(c=t.getAttribute("id"))?c=c.replace(te,ne):t.setAttribute("id",c=b),s=(h=a(e)).length;while(s--)h[s]="#"+c+" "+ve(h[s]);v=h.join(","),m=K.test(e)&&ge(t.parentNode)||t}if(v)try{return L.apply(r,m.querySelectorAll(v)),r}catch(e){}finally{c===b&&t.removeAttribute("id")}}}return u(e.replace(B,"$1"),t,r,i)}function ae(){var e=[];function t(n,i){return e.push(n+" ")>r.cacheLength&&delete t[e.shift()],t[n+" "]=i}return t}function se(e){return e[b]=!0,e}function ue(e){var t=d.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function le(e,t){var n=e.split("|"),i=n.length;while(i--)r.attrHandle[n[i]]=t}function ce(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function fe(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function pe(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function de(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&ie(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function he(e){return se(function(t){return t=+t,se(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function ge(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}n=oe.support={},o=oe.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},p=oe.setDocument=function(e){var t,i,a=e?e.ownerDocument||e:w;return a!==d&&9===a.nodeType&&a.documentElement?(d=a,h=d.documentElement,g=!o(d),w!==d&&(i=d.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",re,!1):i.attachEvent&&i.attachEvent("onunload",re)),n.attributes=ue(function(e){return e.className="i",!e.getAttribute("className")}),n.getElementsByTagName=ue(function(e){return e.appendChild(d.createComment("")),!e.getElementsByTagName("*").length}),n.getElementsByClassName=Q.test(d.getElementsByClassName),n.getById=ue(function(e){return h.appendChild(e).id=b,!d.getElementsByName||!d.getElementsByName(b).length}),n.getById?(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){return e.getAttribute("id")===t}},r.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&g){var n=t.getElementById(e);return n?[n]:[]}}):(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},r.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&g){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),r.find.TAG=n.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&g)return t.getElementsByClassName(e)},v=[],y=[],(n.qsa=Q.test(d.querySelectorAll))&&(ue(function(e){h.appendChild(e).innerHTML="<a id='"+b+"'></a><select id='"+b+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&y.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||y.push("\\["+M+"*(?:value|"+P+")"),e.querySelectorAll("[id~="+b+"-]").length||y.push("~="),e.querySelectorAll(":checked").length||y.push(":checked"),e.querySelectorAll("a#"+b+"+*").length||y.push(".#.+[+~]")}),ue(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=d.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&y.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&y.push(":enabled",":disabled"),h.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&y.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),y.push(",.*:")})),(n.matchesSelector=Q.test(m=h.matches||h.webkitMatchesSelector||h.mozMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&ue(function(e){n.disconnectedMatch=m.call(e,"*"),m.call(e,"[s!='']:x"),v.push("!=",W)}),y=y.length&&new RegExp(y.join("|")),v=v.length&&new RegExp(v.join("|")),t=Q.test(h.compareDocumentPosition),x=t||Q.test(h.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return f=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e===d||e.ownerDocument===w&&x(w,e)?-1:t===d||t.ownerDocument===w&&x(w,t)?1:c?O(c,e)-O(c,t):0:4&r?-1:1)}:function(e,t){if(e===t)return f=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===d?-1:t===d?1:i?-1:o?1:c?O(c,e)-O(c,t):0;if(i===o)return ce(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?ce(a[r],s[r]):a[r]===w?-1:s[r]===w?1:0},d):d},oe.matches=function(e,t){return oe(e,null,null,t)},oe.matchesSelector=function(e,t){if((e.ownerDocument||e)!==d&&p(e),t=t.replace(z,"='$1']"),n.matchesSelector&&g&&!S[t+" "]&&(!v||!v.test(t))&&(!y||!y.test(t)))try{var r=m.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return oe(t,d,null,[e]).length>0},oe.contains=function(e,t){return(e.ownerDocument||e)!==d&&p(e),x(e,t)},oe.attr=function(e,t){(e.ownerDocument||e)!==d&&p(e);var i=r.attrHandle[t.toLowerCase()],o=i&&N.call(r.attrHandle,t.toLowerCase())?i(e,t,!g):void 0;return void 0!==o?o:n.attributes||!g?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},oe.escape=function(e){return(e+"").replace(te,ne)},oe.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},oe.uniqueSort=function(e){var t,r=[],i=0,o=0;if(f=!n.detectDuplicates,c=!n.sortStable&&e.slice(0),e.sort(D),f){while(t=e[o++])t===e[o]&&(i=r.push(o));while(i--)e.splice(r[i],1)}return c=null,e},i=oe.getText=function(e){var t,n="",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=i(e)}else if(3===o||4===o)return e.nodeValue}else while(t=e[r++])n+=i(t);return n},(r=oe.selectors={cacheLength:50,createPseudo:se,match:V,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(Z,ee),e[3]=(e[3]||e[4]||e[5]||"").replace(Z,ee),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||oe.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&oe.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return V.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=a(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(Z,ee).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=E[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&E(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=oe.attr(r,e);return null==i?"!="===t:!t||(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i.replace($," ")+" ").indexOf(n)>-1:"|="===t&&(i===n||i.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,f,p,d,h,g=o!==a?"nextSibling":"previousSibling",y=t.parentNode,v=s&&t.nodeName.toLowerCase(),m=!u&&!s,x=!1;if(y){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===v:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?y.firstChild:y.lastChild],a&&m){x=(d=(l=(c=(f=(p=y)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1])&&l[2],p=d&&y.childNodes[d];while(p=++d&&p&&p[g]||(x=d=0)||h.pop())if(1===p.nodeType&&++x&&p===t){c[e]=[T,d,x];break}}else if(m&&(x=d=(l=(c=(f=(p=t)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1]),!1===x)while(p=++d&&p&&p[g]||(x=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===v:1===p.nodeType)&&++x&&(m&&((c=(f=p[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]=[T,x]),p===t))break;return(x-=i)===r||x%r==0&&x/r>=0}}},PSEUDO:function(e,t){var n,i=r.pseudos[e]||r.setFilters[e.toLowerCase()]||oe.error("unsupported pseudo: "+e);return i[b]?i(t):i.length>1?(n=[e,e,"",t],r.setFilters.hasOwnProperty(e.toLowerCase())?se(function(e,n){var r,o=i(e,t),a=o.length;while(a--)e[r=O(e,o[a])]=!(n[r]=o[a])}):function(e){return i(e,0,n)}):i}},pseudos:{not:se(function(e){var t=[],n=[],r=s(e.replace(B,"$1"));return r[b]?se(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}}),has:se(function(e){return function(t){return oe(e,t).length>0}}),contains:se(function(e){return e=e.replace(Z,ee),function(t){return(t.textContent||t.innerText||i(t)).indexOf(e)>-1}}),lang:se(function(e){return U.test(e||"")||oe.error("unsupported lang: "+e),e=e.replace(Z,ee).toLowerCase(),function(t){var n;do{if(n=g?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===h},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:de(!1),disabled:de(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!r.pseudos.empty(e)},header:function(e){return Y.test(e.nodeName)},input:function(e){return G.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:he(function(){return[0]}),last:he(function(e,t){return[t-1]}),eq:he(function(e,t,n){return[n<0?n+t:n]}),even:he(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:he(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:he(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:he(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=r.pseudos.eq;for(t in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[t]=fe(t);for(t in{submit:!0,reset:!0})r.pseudos[t]=pe(t);function ye(){}ye.prototype=r.filters=r.pseudos,r.setFilters=new ye,a=oe.tokenize=function(e,t){var n,i,o,a,s,u,l,c=k[e+" "];if(c)return t?0:c.slice(0);s=e,u=[],l=r.preFilter;while(s){n&&!(i=F.exec(s))||(i&&(s=s.slice(i[0].length)||s),u.push(o=[])),n=!1,(i=_.exec(s))&&(n=i.shift(),o.push({value:n,type:i[0].replace(B," ")}),s=s.slice(n.length));for(a in r.filter)!(i=V[a].exec(s))||l[a]&&!(i=l[a](i))||(n=i.shift(),o.push({value:n,type:a,matches:i}),s=s.slice(n.length));if(!n)break}return t?s.length:s?oe.error(e):k(e,u).slice(0)};function ve(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function me(e,t,n){var r=t.dir,i=t.next,o=i||r,a=n&&"parentNode"===o,s=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||a)return e(t,n,i);return!1}:function(t,n,u){var l,c,f,p=[T,s];if(u){while(t=t[r])if((1===t.nodeType||a)&&e(t,n,u))return!0}else while(t=t[r])if(1===t.nodeType||a)if(f=t[b]||(t[b]={}),c=f[t.uniqueID]||(f[t.uniqueID]={}),i&&i===t.nodeName.toLowerCase())t=t[r]||t;else{if((l=c[o])&&l[0]===T&&l[1]===s)return p[2]=l[2];if(c[o]=p,p[2]=e(t,n,u))return!0}return!1}}function xe(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function be(e,t,n){for(var r=0,i=t.length;r<i;r++)oe(e,t[r],n);return n}function we(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Te(e,t,n,r,i,o){return r&&!r[b]&&(r=Te(r)),i&&!i[b]&&(i=Te(i,o)),se(function(o,a,s,u){var l,c,f,p=[],d=[],h=a.length,g=o||be(t||"*",s.nodeType?[s]:s,[]),y=!e||!o&&t?g:we(g,p,e,s,u),v=n?i||(o?e:h||r)?[]:a:y;if(n&&n(y,v,s,u),r){l=we(v,d),r(l,[],s,u),c=l.length;while(c--)(f=l[c])&&(v[d[c]]=!(y[d[c]]=f))}if(o){if(i||e){if(i){l=[],c=v.length;while(c--)(f=v[c])&&l.push(y[c]=f);i(null,v=[],l,u)}c=v.length;while(c--)(f=v[c])&&(l=i?O(o,f):p[c])>-1&&(o[l]=!(a[l]=f))}}else v=we(v===a?v.splice(h,v.length):v),i?i(null,a,v,u):L.apply(a,v)})}function Ce(e){for(var t,n,i,o=e.length,a=r.relative[e[0].type],s=a||r.relative[" "],u=a?1:0,c=me(function(e){return e===t},s,!0),f=me(function(e){return O(t,e)>-1},s,!0),p=[function(e,n,r){var i=!a&&(r||n!==l)||((t=n).nodeType?c(e,n,r):f(e,n,r));return t=null,i}];u<o;u++)if(n=r.relative[e[u].type])p=[me(xe(p),n)];else{if((n=r.filter[e[u].type].apply(null,e[u].matches))[b]){for(i=++u;i<o;i++)if(r.relative[e[i].type])break;return Te(u>1&&xe(p),u>1&&ve(e.slice(0,u-1).concat({value:" "===e[u-2].type?"*":""})).replace(B,"$1"),n,u<i&&Ce(e.slice(u,i)),i<o&&Ce(e=e.slice(i)),i<o&&ve(e))}p.push(n)}return xe(p)}function Ee(e,t){var n=t.length>0,i=e.length>0,o=function(o,a,s,u,c){var f,h,y,v=0,m="0",x=o&&[],b=[],w=l,C=o||i&&r.find.TAG("*",c),E=T+=null==w?1:Math.random()||.1,k=C.length;for(c&&(l=a===d||a||c);m!==k&&null!=(f=C[m]);m++){if(i&&f){h=0,a||f.ownerDocument===d||(p(f),s=!g);while(y=e[h++])if(y(f,a||d,s)){u.push(f);break}c&&(T=E)}n&&((f=!y&&f)&&v--,o&&x.push(f))}if(v+=m,n&&m!==v){h=0;while(y=t[h++])y(x,b,a,s);if(o){if(v>0)while(m--)x[m]||b[m]||(b[m]=j.call(u));b=we(b)}L.apply(u,b),c&&!o&&b.length>0&&v+t.length>1&&oe.uniqueSort(u)}return c&&(T=E,l=w),x};return n?se(o):o}return s=oe.compile=function(e,t){var n,r=[],i=[],o=S[e+" "];if(!o){t||(t=a(e)),n=t.length;while(n--)(o=Ce(t[n]))[b]?r.push(o):i.push(o);(o=S(e,Ee(i,r))).selector=e}return o},u=oe.select=function(e,t,n,i){var o,u,l,c,f,p="function"==typeof e&&e,d=!i&&a(e=p.selector||e);if(n=n||[],1===d.length){if((u=d[0]=d[0].slice(0)).length>2&&"ID"===(l=u[0]).type&&9===t.nodeType&&g&&r.relative[u[1].type]){if(!(t=(r.find.ID(l.matches[0].replace(Z,ee),t)||[])[0]))return n;p&&(t=t.parentNode),e=e.slice(u.shift().value.length)}o=V.needsContext.test(e)?0:u.length;while(o--){if(l=u[o],r.relative[c=l.type])break;if((f=r.find[c])&&(i=f(l.matches[0].replace(Z,ee),K.test(u[0].type)&&ge(t.parentNode)||t))){if(u.splice(o,1),!(e=i.length&&ve(u)))return L.apply(n,i),n;break}}}return(p||s(e,d))(i,t,!g,n,!t||K.test(e)&&ge(t.parentNode)||t),n},n.sortStable=b.split("").sort(D).join("")===b,n.detectDuplicates=!!f,p(),n.sortDetached=ue(function(e){return 1&e.compareDocumentPosition(d.createElement("fieldset"))}),ue(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||le("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),n.attributes&&ue(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||le("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ue(function(e){return null==e.getAttribute("disabled")})||le(P,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),oe}(e);w.find=E,w.expr=E.selectors,w.expr[":"]=w.expr.pseudos,w.uniqueSort=w.unique=E.uniqueSort,w.text=E.getText,w.isXMLDoc=E.isXML,w.contains=E.contains,w.escapeSelector=E.escape;var k=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&w(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},D=w.expr.match.needsContext;function N(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var A=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,t,n){return g(t)?w.grep(e,function(e,r){return!!t.call(e,r,e)!==n}):t.nodeType?w.grep(e,function(e){return e===t!==n}):"string"!=typeof t?w.grep(e,function(e){return u.call(t,e)>-1!==n}):w.filter(t,e,n)}w.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?w.find.matchesSelector(r,e)?[r]:[]:w.find.matches(e,w.grep(t,function(e){return 1===e.nodeType}))},w.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(w(e).filter(function(){for(t=0;t<r;t++)if(w.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)w.find(e,i[t],n);return r>1?w.uniqueSort(n):n},filter:function(e){return this.pushStack(j(this,e||[],!1))},not:function(e){return this.pushStack(j(this,e||[],!0))},is:function(e){return!!j(this,"string"==typeof e&&D.test(e)?w(e):e||[],!1).length}});var q,L=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(w.fn.init=function(e,t,n){var i,o;if(!e)return this;if(n=n||q,"string"==typeof e){if(!(i="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:L.exec(e))||!i[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(i[1]){if(t=t instanceof w?t[0]:t,w.merge(this,w.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:r,!0)),A.test(i[1])&&w.isPlainObject(t))for(i in t)g(this[i])?this[i](t[i]):this.attr(i,t[i]);return this}return(o=r.getElementById(i[2]))&&(this[0]=o,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):g(e)?void 0!==n.ready?n.ready(e):e(w):w.makeArray(e,this)}).prototype=w.fn,q=w(r);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};w.fn.extend({has:function(e){var t=w(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(w.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&w(e);if(!D.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&w.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?w.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?u.call(w(e),this[0]):u.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(w.uniqueSort(w.merge(this.get(),w(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}w.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return k(e,"parentNode")},parentsUntil:function(e,t,n){return k(e,"parentNode",n)},next:function(e){return P(e,"nextSibling")},prev:function(e){return P(e,"previousSibling")},nextAll:function(e){return k(e,"nextSibling")},prevAll:function(e){return k(e,"previousSibling")},nextUntil:function(e,t,n){return k(e,"nextSibling",n)},prevUntil:function(e,t,n){return k(e,"previousSibling",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return N(e,"iframe")?e.contentDocument:(N(e,"template")&&(e=e.content||e),w.merge([],e.childNodes))}},function(e,t){w.fn[e]=function(n,r){var i=w.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=w.filter(r,i)),this.length>1&&(O[e]||w.uniqueSort(i),H.test(e)&&i.reverse()),this.pushStack(i)}});var M=/[^\x20\t\r\n\f]+/g;function R(e){var t={};return w.each(e.match(M)||[],function(e,n){t[n]=!0}),t}w.Callbacks=function(e){e="string"==typeof e?R(e):w.extend({},e);var t,n,r,i,o=[],a=[],s=-1,u=function(){for(i=i||e.once,r=t=!0;a.length;s=-1){n=a.shift();while(++s<o.length)!1===o[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=o.length,n=!1)}e.memory||(n=!1),t=!1,i&&(o=n?[]:"")},l={add:function(){return o&&(n&&!t&&(s=o.length-1,a.push(n)),function t(n){w.each(n,function(n,r){g(r)?e.unique&&l.has(r)||o.push(r):r&&r.length&&"string"!==x(r)&&t(r)})}(arguments),n&&!t&&u()),this},remove:function(){return w.each(arguments,function(e,t){var n;while((n=w.inArray(t,o,n))>-1)o.splice(n,1),n<=s&&s--}),this},has:function(e){return e?w.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=a=[],n||t||(o=n=""),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||u()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!r}};return l};function I(e){return e}function W(e){throw e}function $(e,t,n,r){var i;try{e&&g(i=e.promise)?i.call(e).done(t).fail(n):e&&g(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}w.extend({Deferred:function(t){var n=[["notify","progress",w.Callbacks("memory"),w.Callbacks("memory"),2],["resolve","done",w.Callbacks("once memory"),w.Callbacks("once memory"),0,"resolved"],["reject","fail",w.Callbacks("once memory"),w.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},"catch":function(e){return i.then(null,e)},pipe:function(){var e=arguments;return w.Deferred(function(t){w.each(n,function(n,r){var i=g(e[r[4]])&&e[r[4]];o[r[1]](function(){var e=i&&i.apply(this,arguments);e&&g(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+"With"](this,i?[e]:arguments)})}),e=null}).promise()},then:function(t,r,i){var o=0;function a(t,n,r,i){return function(){var s=this,u=arguments,l=function(){var e,l;if(!(t<o)){if((e=r.apply(s,u))===n.promise())throw new TypeError("Thenable self-resolution");l=e&&("object"==typeof e||"function"==typeof e)&&e.then,g(l)?i?l.call(e,a(o,n,I,i),a(o,n,W,i)):(o++,l.call(e,a(o,n,I,i),a(o,n,W,i),a(o,n,I,n.notifyWith))):(r!==I&&(s=void 0,u=[e]),(i||n.resolveWith)(s,u))}},c=i?l:function(){try{l()}catch(e){w.Deferred.exceptionHook&&w.Deferred.exceptionHook(e,c.stackTrace),t+1>=o&&(r!==W&&(s=void 0,u=[e]),n.rejectWith(s,u))}};t?c():(w.Deferred.getStackHook&&(c.stackTrace=w.Deferred.getStackHook()),e.setTimeout(c))}}return w.Deferred(function(e){n[0][3].add(a(0,e,g(i)?i:I,e.notifyWith)),n[1][3].add(a(0,e,g(t)?t:I)),n[2][3].add(a(0,e,g(r)?r:W))}).promise()},promise:function(e){return null!=e?w.extend(e,i):i}},o={};return w.each(n,function(e,t){var a=t[2],s=t[5];i[t[1]]=a.add,s&&a.add(function(){r=s},n[3-e][2].disable,n[3-e][3].disable,n[0][2].lock,n[0][3].lock),a.add(t[3].fire),o[t[0]]=function(){return o[t[0]+"With"](this===o?void 0:this,arguments),this},o[t[0]+"With"]=a.fireWith}),i.promise(o),t&&t.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),i=o.call(arguments),a=w.Deferred(),s=function(e){return function(n){r[e]=this,i[e]=arguments.length>1?o.call(arguments):n,--t||a.resolveWith(r,i)}};if(t<=1&&($(e,a.done(s(n)).resolve,a.reject,!t),"pending"===a.state()||g(i[n]&&i[n].then)))return a.then();while(n--)$(i[n],s(n),a.reject);return a.promise()}});var B=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;w.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&B.test(t.name)&&e.console.warn("jQuery.Deferred exception: "+t.message,t.stack,n)},w.readyException=function(t){e.setTimeout(function(){throw t})};var F=w.Deferred();w.fn.ready=function(e){return F.then(e)["catch"](function(e){w.readyException(e)}),this},w.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--w.readyWait:w.isReady)||(w.isReady=!0,!0!==e&&--w.readyWait>0||F.resolveWith(r,[w]))}}),w.ready.then=F.then;function _(){r.removeEventListener("DOMContentLoaded",_),e.removeEventListener("load",_),w.ready()}"complete"===r.readyState||"loading"!==r.readyState&&!r.documentElement.doScroll?e.setTimeout(w.ready):(r.addEventListener("DOMContentLoaded",_),e.addEventListener("load",_));var z=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===x(n)){i=!0;for(s in n)z(e,t,s,n[s],!0,o,a)}else if(void 0!==r&&(i=!0,g(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(w(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},X=/^-ms-/,U=/-([a-z])/g;function V(e,t){return t.toUpperCase()}function G(e){return e.replace(X,"ms-").replace(U,V)}var Y=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Q(){this.expando=w.expando+Q.uid++}Q.uid=1,Q.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Y(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[G(t)]=n;else for(r in t)i[G(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][G(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(G):(t=G(t))in r?[t]:t.match(M)||[]).length;while(n--)delete r[t[n]]}(void 0===t||w.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!w.isEmptyObject(t)}};var J=new Q,K=new Q,Z=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,ee=/[A-Z]/g;function te(e){return"true"===e||"false"!==e&&("null"===e?null:e===+e+""?+e:Z.test(e)?JSON.parse(e):e)}function ne(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(ee,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n=te(n)}catch(e){}K.set(e,t,n)}else n=void 0;return n}w.extend({hasData:function(e){return K.hasData(e)||J.hasData(e)},data:function(e,t,n){return K.access(e,t,n)},removeData:function(e,t){K.remove(e,t)},_data:function(e,t,n){return J.access(e,t,n)},_removeData:function(e,t){J.remove(e,t)}}),w.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=K.get(o),1===o.nodeType&&!J.get(o,"hasDataAttrs"))){n=a.length;while(n--)a[n]&&0===(r=a[n].name).indexOf("data-")&&(r=G(r.slice(5)),ne(o,r,i[r]));J.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof e?this.each(function(){K.set(this,e)}):z(this,function(t){var n;if(o&&void 0===t){if(void 0!==(n=K.get(o,e)))return n;if(void 0!==(n=ne(o,e)))return n}else this.each(function(){K.set(this,e,t)})},null,t,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){K.remove(this,e)})}}),w.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=J.get(e,t),n&&(!r||Array.isArray(n)?r=J.access(e,t,w.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=w.queue(e,t),r=n.length,i=n.shift(),o=w._queueHooks(e,t),a=function(){w.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return J.get(e,n)||J.access(e,n,{empty:w.Callbacks("once memory").add(function(){J.remove(e,[t+"queue",n])})})}}),w.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?w.queue(this[0],e):void 0===t?this:this.each(function(){var n=w.queue(this,e,t);w._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&w.dequeue(this,e)})},dequeue:function(e){return this.each(function(){w.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=w.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=J.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var re=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ie=new RegExp("^(?:([+-])=|)("+re+")([a-z%]*)$","i"),oe=["Top","Right","Bottom","Left"],ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&w.contains(e.ownerDocument,e)&&"none"===w.css(e,"display")},se=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i};function ue(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return w.css(e,t,"")},u=s(),l=n&&n[3]||(w.cssNumber[t]?"":"px"),c=(w.cssNumber[t]||"px"!==l&&+u)&&ie.exec(w.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)w.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,w.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var le={};function ce(e){var t,n=e.ownerDocument,r=e.nodeName,i=le[r];return i||(t=n.body.appendChild(n.createElement(r)),i=w.css(t,"display"),t.parentNode.removeChild(t),"none"===i&&(i="block"),le[r]=i,i)}function fe(e,t){for(var n,r,i=[],o=0,a=e.length;o<a;o++)(r=e[o]).style&&(n=r.style.display,t?("none"===n&&(i[o]=J.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&ae(r)&&(i[o]=ce(r))):"none"!==n&&(i[o]="none",J.set(r,"display",n)));for(o=0;o<a;o++)null!=i[o]&&(e[o].style.display=i[o]);return e}w.fn.extend({show:function(){return fe(this,!0)},hide:function(){return fe(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?w(this).show():w(this).hide()})}});var pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,he=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ge.optgroup=ge.option,ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td;function ye(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&N(e,t)?w.merge([e],n):n}function ve(e,t){for(var n=0,r=e.length;n<r;n++)J.set(e[n],"globalEval",!t||J.get(t[n],"globalEval"))}var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===x(o))w.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+w.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;w.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&w.inArray(o,r)>-1)i&&i.push(o);else if(l=w.contains(o.ownerDocument,o),a=ye(f.appendChild(o),"script"),l&&ve(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}!function(){var e=r.createDocumentFragment().appendChild(r.createElement("div")),t=r.createElement("input");t.setAttribute("type","radio"),t.setAttribute("checked","checked"),t.setAttribute("name","t"),e.appendChild(t),h.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML="<textarea>x</textarea>",h.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue}();var be=r.documentElement,we=/^key/,Te=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ce=/^([^.]*)(?:\.(.+)|)/;function Ee(){return!0}function ke(){return!1}function Se(){try{return r.activeElement}catch(e){}}function De(e,t,n,r,i,o){var a,s;if("object"==typeof t){"string"!=typeof n&&(r=r||n,n=void 0);for(s in t)De(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=ke;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return w().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=w.guid++)),e.each(function(){w.event.add(this,t,i,r,n)})}w.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,y=J.get(e);if(y){n.handler&&(n=(o=n).handler,i=o.selector),i&&w.find.matchesSelector(be,i),n.guid||(n.guid=w.guid++),(u=y.events)||(u=y.events={}),(a=y.handle)||(a=y.handle=function(t){return"undefined"!=typeof w&&w.event.triggered!==t.type?w.event.dispatch.apply(e,arguments):void 0}),l=(t=(t||"").match(M)||[""]).length;while(l--)d=g=(s=Ce.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=w.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=w.event.special[d]||{},c=w.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&w.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(e,r,h,a)||e.addEventListener&&e.addEventListener(d,a)),f.add&&(f.add.call(e,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),w.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,y=J.hasData(e)&&J.get(e);if(y&&(u=y.events)){l=(t=(t||"").match(M)||[""]).length;while(l--)if(s=Ce.exec(t[l])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){f=w.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,y.handle)||w.removeEvent(e,d,y.handle),delete u[d])}else for(d in u)w.event.remove(e,d+t[l],n,r,!0);w.isEmptyObject(u)&&J.remove(e,"handle events")}},dispatch:function(e){var t=w.event.fix(e),n,r,i,o,a,s,u=new Array(arguments.length),l=(J.get(this,"events")||{})[t.type]||[],c=w.event.special[t.type]||{};for(u[0]=t,n=1;n<arguments.length;n++)u[n]=arguments[n];if(t.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,t)){s=w.event.handlers.call(this,t,l),n=0;while((o=s[n++])&&!t.isPropagationStopped()){t.currentTarget=o.elem,r=0;while((a=o.handlers[r++])&&!t.isImmediatePropagationStopped())t.rnamespace&&!t.rnamespace.test(a.namespace)||(t.handleObj=a,t.data=a.data,void 0!==(i=((w.event.special[a.origType]||{}).handle||a.handler).apply(o.elem,u))&&!1===(t.result=i)&&(t.preventDefault(),t.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,t),t.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&e.button>=1))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?w(i,this).index(l)>-1:w.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(e,t){Object.defineProperty(w.Event.prototype,e,{enumerable:!0,configurable:!0,get:g(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]},set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(e){return e[w.expando]?e:new w.Event(e)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==Se()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===Se()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&N(this,"input"))return this.click(),!1},_default:function(e){return N(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},w.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},w.Event=function(e,t){if(!(this instanceof w.Event))return new w.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ee:ke,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&w.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[w.expando]=!0},w.Event.prototype={constructor:w.Event,isDefaultPrevented:ke,isPropagationStopped:ke,isImmediatePropagationStopped:ke,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ee,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ee,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ee,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},w.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&we.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Te.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},w.event.addProp),w.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){w.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return i&&(i===r||w.contains(r,i))||(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),w.fn.extend({on:function(e,t,n,r){return De(this,e,t,n,r)},one:function(e,t,n,r){return De(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,w(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=ke),this.each(function(){w.event.remove(this,e,n,t)})}});var Ne=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,Ae=/<script|<style|<link/i,je=/checked\s*(?:[^=]|=\s*.checked.)/i,qe=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function Le(e,t){return N(e,"table")&&N(11!==t.nodeType?t:t.firstChild,"tr")?w(e).children("tbody")[0]||e:e}function He(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Oe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Pe(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(J.hasData(e)&&(o=J.access(e),a=J.set(t,o),l=o.events)){delete a.handle,a.events={};for(i in l)for(n=0,r=l[i].length;n<r;n++)w.event.add(t,i,l[i][n])}K.hasData(e)&&(s=K.access(e),u=w.extend({},s),K.set(t,u))}}function Me(e,t){var n=t.nodeName.toLowerCase();"input"===n&&pe.test(e.type)?t.checked=e.checked:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}function Re(e,t,n,r){t=a.apply([],t);var i,o,s,u,l,c,f=0,p=e.length,d=p-1,y=t[0],v=g(y);if(v||p>1&&"string"==typeof y&&!h.checkClone&&je.test(y))return e.each(function(i){var o=e.eq(i);v&&(t[0]=y.call(this,i,o.html())),Re(o,t,n,r)});if(p&&(i=xe(t,e[0].ownerDocument,!1,e,r),o=i.firstChild,1===i.childNodes.length&&(i=o),o||r)){for(u=(s=w.map(ye(i,"script"),He)).length;f<p;f++)l=i,f!==d&&(l=w.clone(l,!0,!0),u&&w.merge(s,ye(l,"script"))),n.call(e[f],l,f);if(u)for(c=s[s.length-1].ownerDocument,w.map(s,Oe),f=0;f<u;f++)l=s[f],he.test(l.type||"")&&!J.access(l,"globalEval")&&w.contains(c,l)&&(l.src&&"module"!==(l.type||"").toLowerCase()?w._evalUrl&&w._evalUrl(l.src):m(l.textContent.replace(qe,""),c,l))}return e}function Ie(e,t,n){for(var r,i=t?w.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||w.cleanData(ye(r)),r.parentNode&&(n&&w.contains(r.ownerDocument,r)&&ve(ye(r,"script")),r.parentNode.removeChild(r));return e}w.extend({htmlPrefilter:function(e){return e.replace(Ne,"<$1></$2>")},clone:function(e,t,n){var r,i,o,a,s=e.cloneNode(!0),u=w.contains(e.ownerDocument,e);if(!(h.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||w.isXMLDoc(e)))for(a=ye(s),r=0,i=(o=ye(e)).length;r<i;r++)Me(o[r],a[r]);if(t)if(n)for(o=o||ye(e),a=a||ye(s),r=0,i=o.length;r<i;r++)Pe(o[r],a[r]);else Pe(e,s);return(a=ye(s,"script")).length>0&&ve(a,!u&&ye(e,"script")),s},cleanData:function(e){for(var t,n,r,i=w.event.special,o=0;void 0!==(n=e[o]);o++)if(Y(n)){if(t=n[J.expando]){if(t.events)for(r in t.events)i[r]?w.event.remove(n,r):w.removeEvent(n,r,t.handle);n[J.expando]=void 0}n[K.expando]&&(n[K.expando]=void 0)}}}),w.fn.extend({detach:function(e){return Ie(this,e,!0)},remove:function(e){return Ie(this,e)},text:function(e){return z(this,function(e){return void 0===e?w.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Re(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Le(this,e).appendChild(e)})},prepend:function(){return Re(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Le(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Re(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Re(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(w.cleanData(ye(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return w.clone(this,e,t)})},html:function(e){return z(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ae.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(w.cleanData(ye(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return Re(this,arguments,function(t){var n=this.parentNode;w.inArray(this,e)<0&&(w.cleanData(ye(this)),n&&n.replaceChild(t,this))},e)}}),w.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){w.fn[e]=function(e){for(var n,r=[],i=w(e),o=i.length-1,a=0;a<=o;a++)n=a===o?this:this.clone(!0),w(i[a])[t](n),s.apply(r,n.get());return this.pushStack(r)}});var We=new RegExp("^("+re+")(?!px)[a-z%]+$","i"),$e=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},Be=new RegExp(oe.join("|"),"i");!function(){function t(){if(c){l.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",c.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",be.appendChild(l).appendChild(c);var t=e.getComputedStyle(c);i="1%"!==t.top,u=12===n(t.marginLeft),c.style.right="60%",s=36===n(t.right),o=36===n(t.width),c.style.position="absolute",a=36===c.offsetWidth||"absolute",be.removeChild(l),c=null}}function n(e){return Math.round(parseFloat(e))}var i,o,a,s,u,l=r.createElement("div"),c=r.createElement("div");c.style&&(c.style.backgroundClip="content-box",c.cloneNode(!0).style.backgroundClip="",h.clearCloneStyle="content-box"===c.style.backgroundClip,w.extend(h,{boxSizingReliable:function(){return t(),o},pixelBoxStyles:function(){return t(),s},pixelPosition:function(){return t(),i},reliableMarginLeft:function(){return t(),u},scrollboxSize:function(){return t(),a}}))}();function Fe(e,t,n){var r,i,o,a,s=e.style;return(n=n||$e(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||w.contains(e.ownerDocument,e)||(a=w.style(e,t)),!h.pixelBoxStyles()&&We.test(a)&&Be.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function _e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}var ze=/^(none|table(?!-c[ea]).+)/,Xe=/^--/,Ue={position:"absolute",visibility:"hidden",display:"block"},Ve={letterSpacing:"0",fontWeight:"400"},Ge=["Webkit","Moz","ms"],Ye=r.createElement("div").style;function Qe(e){if(e in Ye)return e;var t=e[0].toUpperCase()+e.slice(1),n=Ge.length;while(n--)if((e=Ge[n]+t)in Ye)return e}function Je(e){var t=w.cssProps[e];return t||(t=w.cssProps[e]=Qe(e)||e),t}function Ke(e,t,n){var r=ie.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ze(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=w.css(e,n+oe[a],!0,i)),r?("content"===n&&(u-=w.css(e,"padding"+oe[a],!0,i)),"margin"!==n&&(u-=w.css(e,"border"+oe[a]+"Width",!0,i))):(u+=w.css(e,"padding"+oe[a],!0,i),"padding"!==n?u+=w.css(e,"border"+oe[a]+"Width",!0,i):s+=w.css(e,"border"+oe[a]+"Width",!0,i));return!r&&o>=0&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))),u}function et(e,t,n){var r=$e(e),i=Fe(e,t,r),o="border-box"===w.css(e,"boxSizing",!1,r),a=o;if(We.test(i)){if(!n)return i;i="auto"}return a=a&&(h.boxSizingReliable()||i===e.style[t]),("auto"===i||!parseFloat(i)&&"inline"===w.css(e,"display",!1,r))&&(i=e["offset"+t[0].toUpperCase()+t.slice(1)],a=!0),(i=parseFloat(i)||0)+Ze(e,t,n||(o?"border":"content"),a,r,i)+"px"}w.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Fe(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=G(t),u=Xe.test(t),l=e.style;if(u||(t=Je(s)),a=w.cssHooks[t]||w.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"==(o=typeof n)&&(i=ie.exec(n))&&i[1]&&(n=ue(e,t,i),o="number"),null!=n&&n===n&&("number"===o&&(n+=i&&i[3]||(w.cssNumber[s]?"":"px")),h.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=G(t);return Xe.test(t)||(t=Je(s)),(a=w.cssHooks[t]||w.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Fe(e,t,r)),"normal"===i&&t in Ve&&(i=Ve[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),w.each(["height","width"],function(e,t){w.cssHooks[t]={get:function(e,n,r){if(n)return!ze.test(w.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?et(e,t,r):se(e,Ue,function(){return et(e,t,r)})},set:function(e,n,r){var i,o=$e(e),a="border-box"===w.css(e,"boxSizing",!1,o),s=r&&Ze(e,t,r,a,o);return a&&h.scrollboxSize()===o.position&&(s-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-Ze(e,t,"border",!1,o)-.5)),s&&(i=ie.exec(n))&&"px"!==(i[3]||"px")&&(e.style[t]=n,n=w.css(e,t)),Ke(e,n,s)}}}),w.cssHooks.marginLeft=_e(h.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Fe(e,"marginLeft"))||e.getBoundingClientRect().left-se(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),w.each({margin:"",padding:"",border:"Width"},function(e,t){w.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[e+oe[r]+t]=o[r]||o[r-2]||o[0];return i}},"margin"!==e&&(w.cssHooks[e+t].set=Ke)}),w.fn.extend({css:function(e,t){return z(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=$e(e),i=t.length;a<i;a++)o[t[a]]=w.css(e,t[a],!1,r);return o}return void 0!==n?w.style(e,t,n):w.css(e,t)},e,t,arguments.length>1)}});function tt(e,t,n,r,i){return new tt.prototype.init(e,t,n,r,i)}w.Tween=tt,tt.prototype={constructor:tt,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||w.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(w.cssNumber[n]?"":"px")},cur:function(){var e=tt.propHooks[this.prop];return e&&e.get?e.get(this):tt.propHooks._default.get(this)},run:function(e){var t,n=tt.propHooks[this.prop];return this.options.duration?this.pos=t=w.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):tt.propHooks._default.set(this),this}},tt.prototype.init.prototype=tt.prototype,tt.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=w.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){w.fx.step[e.prop]?w.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[w.cssProps[e.prop]]&&!w.cssHooks[e.prop]?e.elem[e.prop]=e.now:w.style(e.elem,e.prop,e.now+e.unit)}}},tt.propHooks.scrollTop=tt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},w.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},w.fx=tt.prototype.init,w.fx.step={};var nt,rt,it=/^(?:toggle|show|hide)$/,ot=/queueHooks$/;function at(){rt&&(!1===r.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(at):e.setTimeout(at,w.fx.interval),w.fx.tick())}function st(){return e.setTimeout(function(){nt=void 0}),nt=Date.now()}function ut(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=oe[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function lt(e,t,n){for(var r,i=(pt.tweeners[t]||[]).concat(pt.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ct(e,t,n){var r,i,o,a,s,u,l,c,f="width"in t||"height"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),y=J.get(e,"fxshow");n.queue||(null==(a=w._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,w.queue(e,"fx").length||a.empty.fire()})}));for(r in t)if(i=t[r],it.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!y||void 0===y[r])continue;g=!0}d[r]=y&&y[r]||w.style(e,r)}if((u=!w.isEmptyObject(t))||!w.isEmptyObject(d)){f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=y&&y.display)&&(l=J.get(e,"display")),"none"===(c=w.css(e,"display"))&&(l?c=l:(fe([e],!0),l=e.style.display||l,c=w.css(e,"display"),fe([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===w.css(e,"float")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l="none"===c?"":c)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1;for(r in d)u||(y?"hidden"in y&&(g=y.hidden):y=J.access(e,"fxshow",{display:l}),o&&(y.hidden=!g),g&&fe([e],!0),p.done(function(){g||fe([e]),J.remove(e,"fxshow");for(r in d)w.style(e,r,d[r])})),u=lt(g?y[r]:0,r,p),r in y||(y[r]=u.start,g&&(u.end=u.start,u.start=0))}}function ft(e,t){var n,r,i,o,a;for(n in e)if(r=G(n),i=t[r],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=w.cssHooks[r])&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function pt(e,t,n){var r,i,o=0,a=pt.prefilters.length,s=w.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var t=nt||st(),n=Math.max(0,l.startTime+l.duration-t),r=1-(n/l.duration||0),o=0,a=l.tweens.length;o<a;o++)l.tweens[o].run(r);return s.notifyWith(e,[l,r,n]),r<1&&a?n:(a||s.notifyWith(e,[l,1,0]),s.resolveWith(e,[l]),!1)},l=s.promise({elem:e,props:w.extend({},t),opts:w.extend(!0,{specialEasing:{},easing:w.easing._default},n),originalProperties:t,originalOptions:n,startTime:nt||st(),duration:n.duration,tweens:[],createTween:function(t,n){var r=w.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(r),r},stop:function(t){var n=0,r=t?l.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)l.tweens[n].run(1);return t?(s.notifyWith(e,[l,1,0]),s.resolveWith(e,[l,t])):s.rejectWith(e,[l,t]),this}}),c=l.props;for(ft(c,l.opts.specialEasing);o<a;o++)if(r=pt.prefilters[o].call(l,e,c,l.opts))return g(r.stop)&&(w._queueHooks(l.elem,l.opts.queue).stop=r.stop.bind(r)),r;return w.map(c,lt,l),g(l.opts.start)&&l.opts.start.call(e,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),w.fx.timer(w.extend(u,{elem:e,anim:l,queue:l.opts.queue})),l}w.Animation=w.extend(pt,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return ue(n.elem,e,ie.exec(t),n),n}]},tweener:function(e,t){g(e)?(t=e,e=["*"]):e=e.match(M);for(var n,r=0,i=e.length;r<i;r++)n=e[r],pt.tweeners[n]=pt.tweeners[n]||[],pt.tweeners[n].unshift(t)},prefilters:[ct],prefilter:function(e,t){t?pt.prefilters.unshift(e):pt.prefilters.push(e)}}),w.speed=function(e,t,n){var r=e&&"object"==typeof e?w.extend({},e):{complete:n||!n&&t||g(e)&&e,duration:e,easing:n&&t||t&&!g(t)&&t};return w.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in w.fx.speeds?r.duration=w.fx.speeds[r.duration]:r.duration=w.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){g(r.old)&&r.old.call(this),r.queue&&w.dequeue(this,r.queue)},r},w.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=w.isEmptyObject(e),o=w.speed(t,n,r),a=function(){var t=pt(this,w.extend({},e),o);(i||J.get(this,"finish"))&&t.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&!1!==e&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=w.timers,a=J.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&ot.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));!t&&n||w.dequeue(this,e)})},finish:function(e){return!1!==e&&(e=e||"fx"),this.each(function(){var t,n=J.get(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=w.timers,a=r?r.length:0;for(n.finish=!0,w.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;t<a;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),w.each(["toggle","show","hide"],function(e,t){var n=w.fn[t];w.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ut(t,!0),e,r,i)}}),w.each({slideDown:ut("show"),slideUp:ut("hide"),slideToggle:ut("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){w.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),w.timers=[],w.fx.tick=function(){var e,t=0,n=w.timers;for(nt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||w.fx.stop(),nt=void 0},w.fx.timer=function(e){w.timers.push(e),w.fx.start()},w.fx.interval=13,w.fx.start=function(){rt||(rt=!0,at())},w.fx.stop=function(){rt=null},w.fx.speeds={slow:600,fast:200,_default:400},w.fn.delay=function(t,n){return t=w.fx?w.fx.speeds[t]||t:t,n=n||"fx",this.queue(n,function(n,r){var i=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(i)}})},function(){var e=r.createElement("input"),t=r.createElement("select").appendChild(r.createElement("option"));e.type="checkbox",h.checkOn=""!==e.value,h.optSelected=t.selected,(e=r.createElement("input")).value="t",e.type="radio",h.radioValue="t"===e.value}();var dt,ht=w.expr.attrHandle;w.fn.extend({attr:function(e,t){return z(this,w.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){w.removeAttr(this,e)})}}),w.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?w.prop(e,t,n):(1===o&&w.isXMLDoc(e)||(i=w.attrHooks[t.toLowerCase()]||(w.expr.match.bool.test(t)?dt:void 0)),void 0!==n?null===n?void w.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=w.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!h.radioValue&&"radio"===t&&N(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(M);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),dt={set:function(e,t,n){return!1===t?w.removeAttr(e,n):e.setAttribute(n,n),n}},w.each(w.expr.match.bool.source.match(/\w+/g),function(e,t){var n=ht[t]||w.find.attr;ht[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=ht[a],ht[a]=i,i=null!=n(e,t,r)?a:null,ht[a]=o),i}});var gt=/^(?:input|select|textarea|button)$/i,yt=/^(?:a|area)$/i;w.fn.extend({prop:function(e,t){return z(this,w.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[w.propFix[e]||e]})}}),w.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&w.isXMLDoc(e)||(t=w.propFix[t]||t,i=w.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=w.find.attr(e,"tabindex");return t?parseInt(t,10):gt.test(e.nodeName)||yt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),h.optSelected||(w.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),w.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){w.propFix[this.toLowerCase()]=this});function vt(e){return(e.match(M)||[]).join(" ")}function mt(e){return e.getAttribute&&e.getAttribute("class")||""}function xt(e){return Array.isArray(e)?e:"string"==typeof e?e.match(M)||[]:[]}w.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,u=0;if(g(e))return this.each(function(t){w(this).addClass(e.call(this,t,mt(this)))});if((t=xt(e)).length)while(n=this[u++])if(i=mt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=t[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,u=0;if(g(e))return this.each(function(t){w(this).removeClass(e.call(this,t,mt(this)))});if(!arguments.length)return this.attr("class","");if((t=xt(e)).length)while(n=this[u++])if(i=mt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=t[a++])while(r.indexOf(" "+o+" ")>-1)r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(e,t){var n=typeof e,r="string"===n||Array.isArray(e);return"boolean"==typeof t&&r?t?this.addClass(e):this.removeClass(e):g(e)?this.each(function(n){w(this).toggleClass(e.call(this,n,mt(this),t),t)}):this.each(function(){var t,i,o,a;if(r){i=0,o=w(this),a=xt(e);while(t=a[i++])o.hasClass(t)?o.removeClass(t):o.addClass(t)}else void 0!==e&&"boolean"!==n||((t=mt(this))&&J.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===e?"":J.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&(" "+vt(mt(n))+" ").indexOf(t)>-1)return!0;return!1}});var bt=/\r/g;w.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=g(e),this.each(function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,w(this).val()):e)?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=w.map(i,function(e){return null==e?"":e+""})),(t=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))});if(i)return(t=w.valHooks[i.type]||w.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:"string"==typeof(n=i.value)?n.replace(bt,""):null==n?"":n}}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,"value");return null!=t?t:vt(w.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!N(n.parentNode,"optgroup"))){if(t=w(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=w.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=w.inArray(w.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),w.each(["radio","checkbox"],function(){w.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=w.inArray(w(e).val(),t)>-1}},h.checkOn||(w.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),h.focusin="onfocusin"in e;var wt=/^(?:focusinfocus|focusoutblur)$/,Tt=function(e){e.stopPropagation()};w.extend(w.event,{trigger:function(t,n,i,o){var a,s,u,l,c,p,d,h,v=[i||r],m=f.call(t,"type")?t.type:t,x=f.call(t,"namespace")?t.namespace.split("."):[];if(s=h=u=i=i||r,3!==i.nodeType&&8!==i.nodeType&&!wt.test(m+w.event.triggered)&&(m.indexOf(".")>-1&&(m=(x=m.split(".")).shift(),x.sort()),c=m.indexOf(":")<0&&"on"+m,t=t[w.expando]?t:new w.Event(m,"object"==typeof t&&t),t.isTrigger=o?2:3,t.namespace=x.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+x.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=i),n=null==n?[t]:w.makeArray(n,[t]),d=w.event.special[m]||{},o||!d.trigger||!1!==d.trigger.apply(i,n))){if(!o&&!d.noBubble&&!y(i)){for(l=d.delegateType||m,wt.test(l+m)||(s=s.parentNode);s;s=s.parentNode)v.push(s),u=s;u===(i.ownerDocument||r)&&v.push(u.defaultView||u.parentWindow||e)}a=0;while((s=v[a++])&&!t.isPropagationStopped())h=s,t.type=a>1?l:d.bindType||m,(p=(J.get(s,"events")||{})[t.type]&&J.get(s,"handle"))&&p.apply(s,n),(p=c&&s[c])&&p.apply&&Y(s)&&(t.result=p.apply(s,n),!1===t.result&&t.preventDefault());return t.type=m,o||t.isDefaultPrevented()||d._default&&!1!==d._default.apply(v.pop(),n)||!Y(i)||c&&g(i[m])&&!y(i)&&((u=i[c])&&(i[c]=null),w.event.triggered=m,t.isPropagationStopped()&&h.addEventListener(m,Tt),i[m](),t.isPropagationStopped()&&h.removeEventListener(m,Tt),w.event.triggered=void 0,u&&(i[c]=u)),t.result}},simulate:function(e,t,n){var r=w.extend(new w.Event,n,{type:e,isSimulated:!0});w.event.trigger(r,null,t)}}),w.fn.extend({trigger:function(e,t){return this.each(function(){w.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return w.event.trigger(e,t,n,!0)}}),h.focusin||w.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){w.event.simulate(t,e.target,w.event.fix(e))};w.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=J.access(r,t);i||r.addEventListener(e,n,!0),J.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=J.access(r,t)-1;i?J.access(r,t,i):(r.removeEventListener(e,n,!0),J.remove(r,t))}}});var Ct=e.location,Et=Date.now(),kt=/\?/;w.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,"text/xml")}catch(e){n=void 0}return n&&!n.getElementsByTagName("parsererror").length||w.error("Invalid XML: "+t),n};var St=/\[\]$/,Dt=/\r?\n/g,Nt=/^(?:submit|button|image|reset|file)$/i,At=/^(?:input|select|textarea|keygen)/i;function jt(e,t,n,r){var i;if(Array.isArray(t))w.each(t,function(t,i){n||St.test(e)?r(e,i):jt(e+"["+("object"==typeof i&&null!=i?t:"")+"]",i,n,r)});else if(n||"object"!==x(t))r(e,t);else for(i in t)jt(e+"["+i+"]",t[i],n,r)}w.param=function(e,t){var n,r=[],i=function(e,t){var n=g(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(Array.isArray(e)||e.jquery&&!w.isPlainObject(e))w.each(e,function(){i(this.name,this.value)});else for(n in e)jt(n,e[n],t,i);return r.join("&")},w.fn.extend({serialize:function(){return w.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=w.prop(this,"elements");return e?w.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!w(this).is(":disabled")&&At.test(this.nodeName)&&!Nt.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=w(this).val();return null==n?null:Array.isArray(n)?w.map(n,function(e){return{name:t.name,value:e.replace(Dt,"\r\n")}}):{name:t.name,value:n.replace(Dt,"\r\n")}}).get()}});var qt=/%20/g,Lt=/#.*$/,Ht=/([?&])_=[^&]*/,Ot=/^(.*?):[ \t]*([^\r\n]*)$/gm,Pt=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Mt=/^(?:GET|HEAD)$/,Rt=/^\/\//,It={},Wt={},$t="*/".concat("*"),Bt=r.createElement("a");Bt.href=Ct.href;function Ft(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(M)||[];if(g(n))while(r=o[i++])"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function _t(e,t,n,r){var i={},o=e===Wt;function a(s){var u;return i[s]=!0,w.each(e[s]||[],function(e,s){var l=s(t,n,r);return"string"!=typeof l||o||i[l]?o?!(u=l):void 0:(t.dataTypes.unshift(l),a(l),!1)}),u}return a(t.dataTypes[0])||!i["*"]&&a("*")}function zt(e,t){var n,r,i=w.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&w.extend(!0,e,r),e}function Xt(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}function Ut(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}w.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ct.href,type:"GET",isLocal:Pt.test(Ct.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":$t,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":w.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?zt(zt(e,w.ajaxSettings),t):zt(w.ajaxSettings,e)},ajaxPrefilter:Ft(It),ajaxTransport:Ft(Wt),ajax:function(t,n){"object"==typeof t&&(n=t,t=void 0),n=n||{};var i,o,a,s,u,l,c,f,p,d,h=w.ajaxSetup({},n),g=h.context||h,y=h.context&&(g.nodeType||g.jquery)?w(g):w.event,v=w.Deferred(),m=w.Callbacks("once memory"),x=h.statusCode||{},b={},T={},C="canceled",E={readyState:0,getResponseHeader:function(e){var t;if(c){if(!s){s={};while(t=Ot.exec(a))s[t[1].toLowerCase()]=t[2]}t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return c?a:null},setRequestHeader:function(e,t){return null==c&&(e=T[e.toLowerCase()]=T[e.toLowerCase()]||e,b[e]=t),this},overrideMimeType:function(e){return null==c&&(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(c)E.always(e[E.status]);else for(t in e)x[t]=[x[t],e[t]];return this},abort:function(e){var t=e||C;return i&&i.abort(t),k(0,t),this}};if(v.promise(E),h.url=((t||h.url||Ct.href)+"").replace(Rt,Ct.protocol+"//"),h.type=n.method||n.type||h.method||h.type,h.dataTypes=(h.dataType||"*").toLowerCase().match(M)||[""],null==h.crossDomain){l=r.createElement("a");try{l.href=h.url,l.href=l.href,h.crossDomain=Bt.protocol+"//"+Bt.host!=l.protocol+"//"+l.host}catch(e){h.crossDomain=!0}}if(h.data&&h.processData&&"string"!=typeof h.data&&(h.data=w.param(h.data,h.traditional)),_t(It,h,n,E),c)return E;(f=w.event&&h.global)&&0==w.active++&&w.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Mt.test(h.type),o=h.url.replace(Lt,""),h.hasContent?h.data&&h.processData&&0===(h.contentType||"").indexOf("application/x-www-form-urlencoded")&&(h.data=h.data.replace(qt,"+")):(d=h.url.slice(o.length),h.data&&(h.processData||"string"==typeof h.data)&&(o+=(kt.test(o)?"&":"?")+h.data,delete h.data),!1===h.cache&&(o=o.replace(Ht,"$1"),d=(kt.test(o)?"&":"?")+"_="+Et+++d),h.url=o+d),h.ifModified&&(w.lastModified[o]&&E.setRequestHeader("If-Modified-Since",w.lastModified[o]),w.etag[o]&&E.setRequestHeader("If-None-Match",w.etag[o])),(h.data&&h.hasContent&&!1!==h.contentType||n.contentType)&&E.setRequestHeader("Content-Type",h.contentType),E.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+$t+"; q=0.01":""):h.accepts["*"]);for(p in h.headers)E.setRequestHeader(p,h.headers[p]);if(h.beforeSend&&(!1===h.beforeSend.call(g,E,h)||c))return E.abort();if(C="abort",m.add(h.complete),E.done(h.success),E.fail(h.error),i=_t(Wt,h,n,E)){if(E.readyState=1,f&&y.trigger("ajaxSend",[E,h]),c)return E;h.async&&h.timeout>0&&(u=e.setTimeout(function(){E.abort("timeout")},h.timeout));try{c=!1,i.send(b,k)}catch(e){if(c)throw e;k(-1,e)}}else k(-1,"No Transport");function k(t,n,r,s){var l,p,d,b,T,C=n;c||(c=!0,u&&e.clearTimeout(u),i=void 0,a=s||"",E.readyState=t>0?4:0,l=t>=200&&t<300||304===t,r&&(b=Xt(h,E,r)),b=Ut(h,b,E,l),l?(h.ifModified&&((T=E.getResponseHeader("Last-Modified"))&&(w.lastModified[o]=T),(T=E.getResponseHeader("etag"))&&(w.etag[o]=T)),204===t||"HEAD"===h.type?C="nocontent":304===t?C="notmodified":(C=b.state,p=b.data,l=!(d=b.error))):(d=C,!t&&C||(C="error",t<0&&(t=0))),E.status=t,E.statusText=(n||C)+"",l?v.resolveWith(g,[p,C,E]):v.rejectWith(g,[E,C,d]),E.statusCode(x),x=void 0,f&&y.trigger(l?"ajaxSuccess":"ajaxError",[E,h,l?p:d]),m.fireWith(g,[E,C]),f&&(y.trigger("ajaxComplete",[E,h]),--w.active||w.event.trigger("ajaxStop")))}return E},getJSON:function(e,t,n){return w.get(e,t,n,"json")},getScript:function(e,t){return w.get(e,void 0,t,"script")}}),w.each(["get","post"],function(e,t){w[t]=function(e,n,r,i){return g(n)&&(i=i||r,r=n,n=void 0),w.ajax(w.extend({url:e,type:t,dataType:i,data:n,success:r},w.isPlainObject(e)&&e))}}),w._evalUrl=function(e){return w.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},w.fn.extend({wrapAll:function(e){var t;return this[0]&&(g(e)&&(e=e.call(this[0])),t=w(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(e){return g(e)?this.each(function(t){w(this).wrapInner(e.call(this,t))}):this.each(function(){var t=w(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=g(e);return this.each(function(n){w(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(e){return this.parent(e).not("body").each(function(){w(this).replaceWith(this.childNodes)}),this}}),w.expr.pseudos.hidden=function(e){return!w.expr.pseudos.visible(e)},w.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},w.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var Vt={0:200,1223:204},Gt=w.ajaxSettings.xhr();h.cors=!!Gt&&"withCredentials"in Gt,h.ajax=Gt=!!Gt,w.ajaxTransport(function(t){var n,r;if(h.cors||Gt&&!t.crossDomain)return{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");for(a in i)s.setRequestHeader(a,i[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o(Vt[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=s.ontimeout=n("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout(function(){n&&r()})},n=n("abort");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}}),w.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),w.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return w.globalEval(e),e}}}),w.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),w.ajaxTransport("script",function(e){if(e.crossDomain){var t,n;return{send:function(i,o){t=w("<script>").prop({charset:e.scriptCharset,src:e.url}).on("load error",n=function(e){t.remove(),n=null,e&&o("error"===e.type?404:200,e.type)}),r.head.appendChild(t[0])},abort:function(){n&&n()}}}});var Yt=[],Qt=/(=)\?(?=&|$)|\?\?/;w.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Yt.pop()||w.expando+"_"+Et++;return this[e]=!0,e}}),w.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=!1!==t.jsonp&&(Qt.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Qt.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return i=t.jsonpCallback=g(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Qt,"$1"+i):!1!==t.jsonp&&(t.url+=(kt.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||w.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){void 0===o?w(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,Yt.push(i)),a&&g(o)&&o(a[0]),a=o=void 0}),"script"}),h.createHTMLDocument=function(){var e=r.implementation.createHTMLDocument("").body;return e.innerHTML="<form></form><form></form>",2===e.childNodes.length}(),w.parseHTML=function(e,t,n){if("string"!=typeof e)return[];"boolean"==typeof t&&(n=t,t=!1);var i,o,a;return t||(h.createHTMLDocument?((i=(t=r.implementation.createHTMLDocument("")).createElement("base")).href=r.location.href,t.head.appendChild(i)):t=r),o=A.exec(e),a=!n&&[],o?[t.createElement(o[1])]:(o=xe([e],t,a),a&&a.length&&w(a).remove(),w.merge([],o.childNodes))},w.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return s>-1&&(r=vt(e.slice(s)),e=e.slice(0,s)),g(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),a.length>0&&w.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?w("<div>").append(w.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},w.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){w.fn[t]=function(e){return this.on(t,e)}}),w.expr.pseudos.animated=function(e){return w.grep(w.timers,function(t){return e===t.elem}).length},w.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l,c=w.css(e,"position"),f=w(e),p={};"static"===c&&(e.style.position="relative"),s=f.offset(),o=w.css(e,"top"),u=w.css(e,"left"),(l=("absolute"===c||"fixed"===c)&&(o+u).indexOf("auto")>-1)?(a=(r=f.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),g(t)&&(t=t.call(e,n,w.extend({},s))),null!=t.top&&(p.top=t.top-s.top+a),null!=t.left&&(p.left=t.left-s.left+i),"using"in t?t.using.call(e,p):f.css(p)}},w.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){w.offset.setOffset(this,e,t)});var t,n,r=this[0];if(r)return r.getClientRects().length?(t=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:t.top+n.pageYOffset,left:t.left+n.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===w.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===w.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=w(e).offset()).top+=w.css(e,"borderTopWidth",!0),i.left+=w.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-w.css(r,"marginTop",!0),left:t.left-i.left-w.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===w.css(e,"position"))e=e.offsetParent;return e||be})}}),w.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n="pageYOffset"===t;w.fn[e]=function(r){return z(this,function(e,r,i){var o;if(y(e)?o=e:9===e.nodeType&&(o=e.defaultView),void 0===i)return o?o[t]:e[r];o?o.scrollTo(n?o.pageXOffset:i,n?i:o.pageYOffset):e[r]=i},e,r,arguments.length)}}),w.each(["top","left"],function(e,t){w.cssHooks[t]=_e(h.pixelPosition,function(e,n){if(n)return n=Fe(e,t),We.test(n)?w(e).position()[t]+"px":n})}),w.each({Height:"height",Width:"width"},function(e,t){w.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){w.fn[r]=function(i,o){var a=arguments.length&&(n||"boolean"!=typeof i),s=n||(!0===i||!0===o?"margin":"border");return z(this,function(t,n,i){var o;return y(t)?0===r.indexOf("outer")?t["inner"+e]:t.document.documentElement["client"+e]:9===t.nodeType?(o=t.documentElement,Math.max(t.body["scroll"+e],o["scroll"+e],t.body["offset"+e],o["offset"+e],o["client"+e])):void 0===i?w.css(t,n,s):w.style(t,n,i,s)},t,a?i:void 0,a)}})}),w.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,t){w.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),w.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),w.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),w.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),g(e))return r=o.call(arguments,2),i=function(){return e.apply(t||this,r.concat(o.call(arguments)))},i.guid=e.guid=e.guid||w.guid++,i},w.holdReady=function(e){e?w.readyWait++:w.ready(!0)},w.isArray=Array.isArray,w.parseJSON=JSON.parse,w.nodeName=N,w.isFunction=g,w.isWindow=y,w.camelCase=G,w.type=x,w.now=Date.now,w.isNumeric=function(e){var t=w.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},"function"==typeof define&&define.amd&&define("jquery",[],function(){return w});var Jt=e.jQuery,Kt=e.$;return w.noConflict=function(t){return e.$===w&&(e.$=Kt),t&&e.jQuery===w&&(e.jQuery=Jt),w},t||(e.jQuery=e.$=w),w});
5/* End */
6;
7; /* Start:"a:4:{s:4:"full";s:97:"/local/templates/gvozdevsoft_profigs_s1/lib/owl-carousel-2/js/owl.carousel.min.js?173827436844342";s:6:"source";s:81:"/local/templates/gvozdevsoft_profigs_s1/lib/owl-carousel-2/js/owl.carousel.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
vendor: 36,085 bytes, lines 8-14
8/**
9 * Owl Carousel v2.3.4
10 * Copyright 2013-2018 David Deutsch
11 * Licensed under: SEE LICENSE IN https://github.com/OwlCarousel2/OwlCarousel2/blob/master/LICENSE
12 */
13!function(a,b,c,d){function e(b,c){this.settings=null,this.options=a.extend({},e.Defaults,c),this.$element=a(b),this._handlers={},this._plugins={},this._supress={},this._current=null,this._speed=null,this._coordinates=[],this._breakpoint=null,this._width=null,this._items=[],this._clones=[],this._mergers=[],this._widths=[],this._invalidated={},this._pipe=[],this._drag={time:null,target:null,pointer:null,stage:{start:null,current:null},direction:null},this._states={current:{},tags:{initializing:["busy"],animating:["busy"],dragging:["interacting"]}},a.each(["onResize","onThrottledResize"],a.proxy(function(b,c){this._handlers[c]=a.proxy(this[c],this)},this)),a.each(e.Plugins,a.proxy(function(a,b){this._plugins[a.charAt(0).toLowerCase()+a.slice(1)]=new b(this)},this)),a.each(e.Workers,a.proxy(function(b,c){this._pipe.push({filter:c.filter,run:a.proxy(c.run,this)})},this)),this.setup(),this.initialize()}e.Defaults={items:3,loop:!1,center:!1,rewind:!1,checkVisibility:!0,mouseDrag:!0,touchDrag:!0,pullDrag:!0,freeDrag:!1,margin:0,stagePadding:0,merge:!1,mergeFit:!0,autoWidth:!1,startPosition:0,rtl:!1,smartSpeed:250,fluidSpeed:!1,dragEndSpeed:!1,responsive:{},responsiveRefreshRate:200,responsiveBaseElement:b,fallbackEasing:"swing",slideTransition:"",info:!1,nestedItemSelector:!1,itemElement:"div",stageElement:"div",refreshClass:"owl-refresh",loadedClass:"owl-loaded",loadingClass:"owl-loading",rtlClass:"owl-rtl",responsiveClass:"owl-responsive",dragClass:"owl-drag",itemClass:"owl-item",stageClass:"owl-stage",stageOuterClass:"owl-stage-outer",grabClass:"owl-grab"},e.Width={Default:"default",Inner:"inner",Outer:"outer"},e.Type={Event:"event",State:"state"},e.Plugins={},e.Workers=[{filter:["width","settings"],run:function(){this._width=this.$element.width()}},{filter:["width","items","settings"],run:function(a){a.current=this._items&&this._items[this.relative(this._current)]}},{filter:["items","settings"],run:function(){this.$stage.children(".cloned").remove()}},{filter:["width","items","settings"],run:function(a){var b=this.settings.margin||"",c=!this.settings.autoWidth,d=this.settings.rtl,e={width:"auto","margin-left":d?b:"","margin-right":d?"":b};!c&&this.$stage.children().css(e),a.css=e}},{filter:["width","items","settings"],run:function(a){var b=(this.width()/this.settings.items).toFixed(3)-this.settings.margin,c=null,d=this._items.length,e=!this.settings.autoWidth,f=[];for(a.items={merge:!1,width:b};d--;)c=this._mergers[d],c=this.settings.mergeFit&&Math.min(c,this.settings.items)||c,a.items.merge=c>1||a.items.merge,f[d]=e?b*c:this._items[d].width();this._widths=f}},{filter:["items","settings"],run:function(){var b=[],c=this._items,d=this.settings,e=Math.max(2*d.items,4),f=2*Math.ceil(c.length/2),g=d.loop&&c.length?d.rewind?e:Math.max(e,f):0,h="",i="";for(g/=2;g>0;)b.push(this.normalize(b.length/2,!0)),h+=c[b[b.length-1]][0].outerHTML,b.push(this.normalize(c.length-1-(b.length-1)/2,!0)),i=c[b[b.length-1]][0].outerHTML+i,g-=1;this._clones=b,a(h).addClass("cloned").appendTo(this.$stage),a(i).addClass("cloned").prependTo(this.$stage)}},{filter:["width","items","settings"],run:function(){for(var a=this.settings.rtl?1:-1,b=this._clones.length+this._items.length,c=-1,d=0,e=0,f=[];++c<b;)d=f[c-1]||0,e=this._widths[this.relative(c)]+this.settings.margin,f.push(d+e*a);this._coordinates=f}},{filter:["width","items","settings"],run:function(){var a=this.settings.stagePadding,b=this._coordinates,c={width:Math.ceil(Math.abs(b[b.length-1]))+2*a,"padding-left":a||"","padding-right":a||""};this.$stage.css(c)}},{filter:["width","items","settings"],run:function(a){var b=this._coordinates.length,c=!this.settings.autoWidth,d=this.$stage.children();if(c&&a.items.merge)for(;b--;)a.css.width=this._widths[this.relative(b)],d.eq(b).css(a.css);else c&&(a.css.width=a.items.width,d.css(a.css))}},{filter:["items"],run:function(){this._coordinates.length<1&&this.$stage.removeAttr("style")}},{filter:["width","items","settings"],run:function(a){a.current=a.current?this.$stage.children().index(a.current):0,a.current=Math.max(this.minimum(),Math.min(this.maximum(),a.current)),this.reset(a.current)}},{filter:["position"],run:function(){this.animate(this.coordinates(this._current))}},{filter:["width","position","items","settings"],run:function(){var a,b,c,d,e=this.settings.rtl?1:-1,f=2*this.settings.stagePadding,g=this.coordinates(this.current())+f,h=g+this.width()*e,i=[];for(c=0,d=this._coordinates.length;c<d;c++)a=this._coordinates[c-1]||0,b=Math.abs(this._coordinates[c])+f*e,(this.op(a,"<=",g)&&this.op(a,">",h)||this.op(b,"<",g)&&this.op(b,">",h))&&i.push(c);this.$stage.children(".active").removeClass("active"),this.$stage.children(":eq("+i.join("), :eq(")+")").addClass("active"),this.$stage.children(".center").removeClass("center"),this.settings.center&&this.$stage.children().eq(this.current()).addClass("center")}}],e.prototype.initializeStage=function(){this.$stage=this.$element.find("."+this.settings.stageClass),this.$stage.length||(this.$element.addClass(this.options.loadingClass),this.$stage=a("<"+this.settings.stageElement+">",{class:this.settings.stageClass}).wrap(a("<div/>",{class:this.settings.stageOuterClass})),this.$element.append(this.$stage.parent()))},e.prototype.initializeItems=function(){var b=this.$element.find(".owl-item");if(b.length)return this._items=b.get().map(function(b){return a(b)}),this._mergers=this._items.map(function(){return 1}),void this.refresh();this.replace(this.$element.children().not(this.$stage.parent())),this.isVisible()?this.refresh():this.invalidate("width"),this.$element.removeClass(this.options.loadingClass).addClass(this.options.loadedClass)},e.prototype.initialize=function(){if(this.enter("initializing"),this.trigger("initialize"),this.$element.toggleClass(this.settings.rtlClass,this.settings.rtl),this.settings.autoWidth&&!this.is("pre-loading")){var a,b,c;a=this.$element.find("img"),b=this.settings.nestedItemSelector?"."+this.settings.nestedItemSelector:d,c=this.$element.children(b).width(),a.length&&c<=0&&this.preloadAutoWidthImages(a)}this.initializeStage(),this.initializeItems(),this.registerEventHandlers(),this.leave("initializing"),this.trigger("initialized")},e.prototype.isVisible=function(){return!this.settings.checkVisibility||this.$element.is(":visible")},e.prototype.setup=function(){var b=this.viewport(),c=this.options.responsive,d=-1,e=null;c?(a.each(c,function(a){a<=b&&a>d&&(d=Number(a))}),e=a.extend({},this.options,c[d]),"function"==typeof e.stagePadding&&(e.stagePadding=e.stagePadding()),delete e.responsive,e.responsiveClass&&this.$element.attr("class",this.$element.attr("class").replace(new RegExp("("+this.options.responsiveClass+"-)\\S+\\s","g"),"$1"+d))):e=a.extend({},this.options),this.trigger("change",{property:{name:"settings",value:e}}),this._breakpoint=d,this.settings=e,this.invalidate("settings"),this.trigger("changed",{property:{name:"settings",value:this.settings}})},e.prototype.optionsLogic=function(){this.settings.autoWidth&&(this.settings.stagePadding=!1,this.settings.merge=!1)},e.prototype.prepare=function(b){var c=this.trigger("prepare",{content:b});return c.data||(c.data=a("<"+this.settings.itemElement+"/>").addClass(this.options.itemClass).append(b)),this.trigger("prepared",{content:c.data}),c.data},e.prototype.update=function(){for(var b=0,c=this._pipe.length,d=a.proxy(function(a){return this[a]},this._invalidated),e={};b<c;)(this._invalidated.all||a.grep(this._pipe[b].filter,d).length>0)&&this._pipe[b].run(e),b++;this._invalidated={},!this.is("valid")&&this.enter("valid")},e.prototype.width=function(a){switch(a=a||e.Width.Default){case e.Width.Inner:case e.Width.Outer:return this._width;default:return this._width-2*this.settings.stagePadding+this.settings.margin}},e.prototype.refresh=function(){this.enter("refreshing"),this.trigger("refresh"),this.setup(),this.optionsLogic(),this.$element.addClass(this.options.refreshClass),this.update(),this.$element.removeClass(this.options.refreshClass),this.leave("refreshing"),this.trigger("refreshed")},e.prototype.onThrottledResize=function(){b.clearTimeout(this.resizeTimer),this.resizeTimer=b.setTimeout(this._handlers.onResize,this.settings.responsiveRefreshRate)},e.prototype.onResize=function(){return!!this._items.length&&(this._width!==this.$element.width()&&(!!this.isVisible()&&(this.enter("resizing"),this.trigger("resize").isDefaultPrevented()?(this.leave("resizing"),!1):(this.invalidate("width"),this.refresh(),this.leave("resizing"),void this.trigger("resized")))))},e.prototype.registerEventHandlers=function(){a.support.transition&&this.$stage.on(a.support.transition.end+".owl.core",a.proxy(this.onTransitionEnd,this)),!1!==this.settings.responsive&&this.on(b,"resize",this._handlers.onThrottledResize),this.settings.mouseDrag&&(this.$element.addClass(this.options.dragClass),this.$stage.on("mousedown.owl.core",a.proxy(this.onDragStart,this)),this.$stage.on("dragstart.owl.core selectstart.owl.core",function(){return!1})),this.settings.touchDrag&&(this.$stage.on("touchstart.owl.core",a.proxy(this.onDragStart,this)),this.$stage.on("touchcancel.owl.core",a.proxy(this.onDragEnd,this)))},e.prototype.onDragStart=function(b){var d=null;3!==b.which&&(a.support.transform?(d=this.$stage.css("transform").replace(/.*\(|\)| /g,"").split(","),d={x:d[16===d.length?12:4],y:d[16===d.length?13:5]}):(d=this.$stage.position(),d={x:this.settings.rtl?d.left+this.$stage.width()-this.width()+this.settings.margin:d.left,y:d.top}),this.is("animating")&&(a.support.transform?this.animate(d.x):this.$stage.stop(),this.invalidate("position")),this.$element.toggleClass(this.options.grabClass,"mousedown"===b.type),this.speed(0),this._drag.time=(new Date).getTime(),this._drag.target=a(b.target),this._drag.stage.start=d,this._drag.stage.current=d,this._drag.pointer=this.pointer(b),a(c).on("mouseup.owl.core touchend.owl.core",a.proxy(this.onDragEnd,this)),a(c).one("mousemove.owl.core touchmove.owl.core",a.proxy(function(b){var d=this.difference(this._drag.pointer,this.pointer(b));a(c).on("mousemove.owl.core touchmove.owl.core",a.proxy(this.onDragMove,this)),Math.abs(d.x)<Math.abs(d.y)&&this.is("valid")||(b.preventDefault(),this.enter("dragging"),this.trigger("drag"))},this)))},e.prototype.onDragMove=function(a){var b=null,c=null,d=null,e=this.difference(this._drag.pointer,this.pointer(a)),f=this.difference(this._drag.stage.start,e);this.is("dragging")&&(a.preventDefault(),this.settings.loop?(b=this.coordinates(this.minimum()),c=this.coordinates(this.maximum()+1)-b,f.x=((f.x-b)%c+c)%c+b):(b=this.settings.rtl?this.coordinates(this.maximum()):this.coordinates(this.minimum()),c=this.settings.rtl?this.coordinates(this.minimum()):this.coordinates(this.maximum()),d=this.settings.pullDrag?-1*e.x/5:0,f.x=Math.max(Math.min(f.x,b+d),c+d)),this._drag.stage.current=f,this.animate(f.x))},e.prototype.onDragEnd=function(b){var d=this.difference(this._drag.pointer,this.pointer(b)),e=this._drag.stage.current,f=d.x>0^this.settings.rtl?"left":"right";a(c).off(".owl.core"),this.$element.removeClass(this.options.grabClass),(0!==d.x&&this.is("dragging")||!this.is("valid"))&&(this.speed(this.settings.dragEndSpeed||this.settings.smartSpeed),this.current(this.closest(e.x,0!==d.x?f:this._drag.direction)),this.invalidate("position"),this.update(),this._drag.direction=f,(Math.abs(d.x)>3||(new Date).getTime()-this._drag.time>300)&&this._drag.target.one("click.owl.core",function(){return!1})),this.is("dragging")&&(this.leave("dragging"),this.trigger("dragged"))},e.prototype.closest=function(b,c){var e=-1,f=30,g=this.width(),h=this.coordinates();return this.settings.freeDrag||a.each(h,a.proxy(function(a,i){return"left"===c&&b>i-f&&b<i+f?e=a:"right"===c&&b>i-g-f&&b<i-g+f?e=a+1:this.op(b,"<",i)&&this.op(b,">",h[a+1]!==d?h[a+1]:i-g)&&(e="left"===c?a+1:a),-1===e},this)),this.settings.loop||(this.op(b,">",h[this.minimum()])?e=b=this.minimum():this.op(b,"<",h[this.maximum()])&&(e=b=this.maximum())),e},e.prototype.animate=function(b){var c=this.speed()>0;this.is("animating")&&this.onTransitionEnd(),c&&(this.enter("animating"),this.trigger("translate")),a.support.transform3d&&a.support.transition?this.$stage.css({transform:"translate3d("+b+"px,0px,0px)",transition:this.speed()/1e3+"s"+(this.settings.slideTransition?" "+this.settings.slideTransition:"")}):c?this.$stage.animate({left:b+"px"},this.speed(),this.settings.fallbackEasing,a.proxy(this.onTransitionEnd,this)):this.$stage.css({left:b+"px"})},e.prototype.is=function(a){return this._states.current[a]&&this._states.current[a]>0},e.prototype.current=function(a){if(a===d)return this._current;if(0===this._items.length)return d;if(a=this.normalize(a),this._current!==a){var b=this.trigger("change",{property:{name:"position",value:a}});b.data!==d&&(a=this.normalize(b.data)),this._current=a,this.invalidate("position"),this.trigger("changed",{property:{name:"position",value:this._current}})}return this._current},e.prototype.invalidate=function(b){return"string"===a.type(b)&&(this._invalidated[b]=!0,this.is("valid")&&this.leave("valid")),a.map(this._invalidated,function(a,b){return b})},e.prototype.reset=function(a){(a=this.normalize(a))!==d&&(this._speed=0,this._current=a,this.suppress(["translate","translated"]),this.animate(this.coordinates(a)),this.release(["translate","translated"]))},e.prototype.normalize=function(a,b){var c=this._items.length,e=b?0:this._clones.length;return!this.isNumeric(a)||c<1?a=d:(a<0||a>=c+e)&&(a=((a-e/2)%c+c)%c+e/2),a},e.prototype.relative=function(a){return a-=this._clones.length/2,this.normalize(a,!0)},e.prototype.maximum=function(a){var b,c,d,e=this.settings,f=this._coordinates.length;if(e.loop)f=this._clones.length/2+this._items.length-1;else if(e.autoWidth||e.merge){if(b=this._items.length)for(c=this._items[--b].width(),d=this.$element.width();b--&&!((c+=this._items[b].width()+this.settings.margin)>d););f=b+1}else f=e.center?this._items.length-1:this._items.length-e.items;return a&&(f-=this._clones.length/2),Math.max(f,0)},e.prototype.minimum=function(a){return a?0:this._clones.length/2},e.prototype.items=function(a){return a===d?this._items.slice():(a=this.normalize(a,!0),this._items[a])},e.prototype.mergers=function(a){return a===d?this._mergers.slice():(a=this.normalize(a,!0),this._mergers[a])},e.prototype.clones=function(b){var c=this._clones.length/2,e=c+this._items.length,f=function(a){return a%2==0?e+a/2:c-(a+1)/2};return b===d?a.map(this._clones,function(a,b){return f(b)}):a.map(this._clones,function(a,c){return a===b?f(c):null})},e.prototype.speed=function(a){return a!==d&&(this._speed=a),this._speed},e.prototype.coordinates=function(b){var c,e=1,f=b-1;return b===d?a.map(this._coordinates,a.proxy(function(a,b){return this.coordinates(b)},this)):(this.settings.center?(this.settings.rtl&&(e=-1,f=b+1),c=this._coordinates[b],c+=(this.width()-c+(this._coordinates[f]||0))/2*e):c=this._coordinates[f]||0,c=Math.ceil(c))},e.prototype.duration=function(a,b,c){return 0===c?0:Math.min(Math.max(Math.abs(b-a),1),6)*Math.abs(c||this.settings.smartSpeed)},e.prototype.to=function(a,b){var c=this.current(),d=null,e=a-this.relative(c),f=(e>0)-(e<0),g=this._items.length,h=this.minimum(),i=this.maximum();this.settings.loop?(!this.settings.rewind&&Math.abs(e)>g/2&&(e+=-1*f*g),a=c+e,(d=((a-h)%g+g)%g+h)!==a&&d-e<=i&&d-e>0&&(c=d-e,a=d,this.reset(c))):this.settings.rewind?(i+=1,a=(a%i+i)%i):a=Math.max(h,Math.min(i,a)),this.speed(this.duration(c,a,b)),this.current(a),this.isVisible()&&this.update()},e.prototype.next=function(a){a=a||!1,this.to(this.relative(this.current())+1,a)},e.prototype.prev=function(a){a=a||!1,this.to(this.relative(this.current())-1,a)},e.prototype.onTransitionEnd=function(a){if(a!==d&&(a.stopPropagation(),(a.target||a.srcElement||a.originalTarget)!==this.$stage.get(0)))return!1;this.leave("animating"),this.trigger("translated")},e.prototype.viewport=function(){var d;return this.options.responsiveBaseElement!==b?d=a(this.options.responsiveBaseElement).width():b.innerWidth?d=b.innerWidth:c.documentElement&&c.documentElement.clientWidth?d=c.documentElement.clientWidth:console.warn("Can not detect viewport width."),d},e.prototype.replace=function(b){this.$stage.empty(),this._items=[],b&&(b=b instanceof jQuery?b:a(b)),this.settings.nestedItemSelector&&(b=b.find("."+this.settings.nestedItemSelector)),b.filter(function(){return 1===this.nodeType}).each(a.proxy(function(a,b){b=this.prepare(b),this.$stage.append(b),this._items.push(b),this._mergers.push(1*b.find("[data-merge]").addBack("[data-merge]").attr("data-merge")||1)},this)),this.reset(this.isNumeric(this.settings.startPosition)?this.settings.startPosition:0),this.invalidate("items")},e.prototype.add=function(b,c){var e=this.relative(this._current);c=c===d?this._items.length:this.normalize(c,!0),b=b instanceof jQuery?b:a(b),this.trigger("add",{content:b,position:c}),b=this.prepare(b),0===this._items.length||c===this._items.length?(0===this._items.length&&this.$stage.append(b),0!==this._items.length&&this._items[c-1].after(b),this._items.push(b),this._mergers.push(1*b.find("[data-merge]").addBack("[data-merge]").attr("data-merge")||1)):(this._items[c].before(b),this._items.splice(c,0,b),this._mergers.splice(c,0,1*b.find("[data-merge]").addBack("[data-merge]").attr("data-merge")||1)),this._items[e]&&this.reset(this._items[e].index()),this.invalidate("items"),this.trigger("added",{content:b,position:c})},e.prototype.remove=function(a){(a=this.normalize(a,!0))!==d&&(this.trigger("remove",{content:this._items[a],position:a}),this._items[a].remove(),this._items.splice(a,1),this._mergers.splice(a,1),this.invalidate("items"),this.trigger("removed",{content:null,position:a}))},e.prototype.preloadAutoWidthImages=function(b){b.each(a.proxy(function(b,c){this.enter("pre-loading"),c=a(c),a(new Image).one("load",a.proxy(function(a){c.attr("src",a.target.src),c.css("opacity",1),this.leave("pre-loading"),!this.is("pre-loading")&&!this.is("initializing")&&this.refresh()},this)).attr("src",c.attr("src")||c.attr("data-src")||c.attr("data-src-retina"))},this))},e.prototype.destroy=function(){this.$element.off(".owl.core"),this.$stage.off(".owl.core"),a(c).off(".owl.core"),!1!==this.settings.responsive&&(b.clearTimeout(this.resizeTimer),this.off(b,"resize",this._handlers.onThrottledResize));for(var d in this._plugins)this._plugins[d].destroy();this.$stage.children(".cloned").remove(),this.$stage.unwrap(),this.$stage.children().contents().unwrap(),this.$stage.children().unwrap(),this.$stage.remove(),this.$element.removeClass(this.options.refreshClass).removeClass(this.options.loadingClass).removeClass(this.options.loadedClass).removeClass(this.options.rtlClass).removeClass(this.options.dragClass).removeClass(this.options.grabClass).attr("class",this.$element.attr("class").replace(new RegExp(this.options.responsiveClass+"-\\S+\\s","g"),"")).removeData("owl.carousel")},e.prototype.op=function(a,b,c){var d=this.settings.rtl;switch(b){case"<":return d?a>c:a<c;case">":return d?a<c:a>c;case">=":return d?a<=c:a>=c;case"<=":return d?a>=c:a<=c}},e.prototype.on=function(a,b,c,d){a.addEventListener?a.addEventListener(b,c,d):a.attachEvent&&a.attachEvent("on"+b,c)},e.prototype.off=function(a,b,c,d){a.removeEventListener?a.removeEventListener(b,c,d):a.detachEvent&&a.detachEvent("on"+b,c)},e.prototype.trigger=function(b,c,d,f,g){var h={item:{count:this._items.length,index:this.current()}},i=a.camelCase(a.grep(["on",b,d],function(a){return a}).join("-").toLowerCase()),j=a.Event([b,"owl",d||"carousel"].join(".").toLowerCase(),a.extend({relatedTarget:this},h,c));return this._supress[b]||(a.each(this._plugins,function(a,b){b.onTrigger&&b.onTrigger(j)}),this.register({type:e.Type.Event,name:b}),this.$element.trigger(j),this.settings&&"function"==typeof this.settings[i]&&this.settings[i].call(this,j)),j},e.prototype.enter=function(b){a.each([b].concat(this._states.tags[b]||[]),a.proxy(function(a,b){this._states.current[b]===d&&(this._states.current[b]=0),this._states.current[b]++},this))},e.prototype.leave=function(b){a.each([b].concat(this._states.tags[b]||[]),a.proxy(function(a,b){this._states.current[b]--},this))},e.prototype.register=function(b){if(b.type===e.Type.Event){if(a.event.special[b.name]||(a.event.special[b.name]={}),!a.event.special[b.name].owl){var c=a.event.special[b.name]._default;a.event.special[b.name]._default=function(a){return!c||!c.apply||a.namespace&&-1!==a.namespace.indexOf("owl")?a.namespace&&a.namespace.indexOf("owl")>-1:c.apply(this,arguments)},a.event.special[b.name].owl=!0}}else b.type===e.Type.State&&(this._states.tags[b.name]?this._states.tags[b.name]=this._states.tags[b.name].concat(b.tags):this._states.tags[b.name]=b.tags,this._states.tags[b.name]=a.grep(this._states.tags[b.name],a.proxy(function(c,d){return a.inArray(c,this._states.tags[b.name])===d},this)))},e.prototype.suppress=function(b){a.each(b,a.proxy(function(a,b){this._supress[b]=!0},this))},e.prototype.release=function(b){a.each(b,a.proxy(function(a,b){delete this._supress[b]},this))},e.prototype.pointer=function(a){var c={x:null,y:null};return a=a.originalEvent||a||b.event,a=a.touches&&a.touches.length?a.touches[0]:a.changedTouches&&a.changedTouches.length?a.changedTouches[0]:a,a.pageX?(c.x=a.pageX,c.y=a.pageY):(c.x=a.clientX,c.y=a.clientY),c},e.prototype.isNumeric=function(a){return!isNaN(parseFloat(a))},e.prototype.difference=function(a,b){return{x:a.x-b.x,y:a.y-b.y}},a.fn.owlCarousel=function(b){var c=Array.prototype.slice.call(arguments,1);return this.each(function(){var d=a(this),f=d.data("owl.carousel");f||(f=new e(this,"object"==typeof b&&b),d.data("owl.carousel",f),a.each(["next","prev","to","destroy","refresh","replace","add","remove"],function(b,c){f.register({type:e.Type.Event,name:c}),f.$element.on(c+".owl.carousel.core",a.proxy(function(a){a.namespace&&a.relatedTarget!==this&&(this.suppress([c]),f[c].apply(this,[].slice.call(arguments,1)),this.release([c]))},f))})),"string"==typeof b&&"_"!==b.charAt(0)&&f[b].apply(f,c)})},a.fn.owlCarousel.Constructor=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(b){this._core=b,this._interval=null,this._visible=null,this._handlers={"initialized.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.autoRefresh&&this.watch()},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this._core.$element.on(this._handlers)};e.Defaults={autoRefresh:!0,autoRefreshInterval:500},e.prototype.watch=function(){this._interval||(this._visible=this._core.isVisible(),this._interval=b.setInterval(a.proxy(this.refresh,this),this._core.settings.autoRefreshInterval))},e.prototype.refresh=function(){this._core.isVisible()!==this._visible&&(this._visible=!this._visible,this._core.$element.toggleClass("owl-hidden",!this._visible),this._visible&&this._core.invalidate("width")&&this._core.refresh())},e.prototype.destroy=function(){var a,c;b.clearInterval(this._interval);for(a in this._handlers)this._core.$element.off(a,this._handlers[a]);for(c in Object.getOwnPropertyNames(this))"function"!=typeof this[c]&&(this[c]=null)},a.fn.owlCarousel.Constructor.Plugins.AutoRefresh=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(b){this._core=b,this._loaded=[],this._handlers={"initialized.owl.carousel change.owl.carousel resized.owl.carousel":a.proxy(function(b){if(b.namespace&&this._core.settings&&this._core.settings.lazyLoad&&(b.property&&"position"==b.property.name||"initialized"==b.type)){var c=this._core.settings,e=c.center&&Math.ceil(c.items/2)||c.items,f=c.center&&-1*e||0,g=(b.property&&b.property.value!==d?b.property.value:this._core.current())+f,h=this._core.clones().length,i=a.proxy(function(a,b){this.load(b)},this);for(c.lazyLoadEager>0&&(e+=c.lazyLoadEager,c.loop&&(g-=c.lazyLoadEager,e++));f++<e;)this.load(h/2+this._core.relative(g)),h&&a.each(this._core.clones(this._core.relative(g)),i),g++}},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this._core.$element.on(this._handlers)};e.Defaults={lazyLoad:!1,lazyLoadEager:0},e.prototype.load=function(c){var d=this._core.$stage.children().eq(c),e=d&&d.find(".owl-lazy");!e||a.inArray(d.get(0),this._loaded)>-1||(e.each(a.proxy(function(c,d){var e,f=a(d),g=b.devicePixelRatio>1&&f.attr("data-src-retina")||f.attr("data-src")||f.attr("data-srcset");this._core.trigger("load",{element:f,url:g},"lazy"),f.is("img")?f.one("load.owl.lazy",a.proxy(function(){f.css("opacity",1),this._core.trigger("loaded",{element:f,url:g},"lazy")},this)).attr("src",g):f.is("source")?f.one("load.owl.lazy",a.proxy(function(){this._core.trigger("loaded",{element:f,url:g},"lazy")},this)).attr("srcset",g):(e=new Image,e.onload=a.proxy(function(){f.css({"background-image":'url("'+g+'")',opacity:"1"}),this._core.trigger("loaded",{element:f,url:g},"lazy")},this),e.src=g)},this)),this._loaded.push(d.get(0)))},e.prototype.destroy=function(){var a,b;for(a in this.handlers)this._core.$element.off(a,this.handlers[a]);for(b in Object.getOwnPropertyNames(this))"function"!=typeof this[b]&&(this[b]=null)},a.fn.owlCarousel.Constructor.Plugins.Lazy=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(c){this._core=c,this._previousHeight=null,this._handlers={"initialized.owl.carousel refreshed.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.autoHeight&&this.update()},this),"changed.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.autoHeight&&"position"===a.property.name&&this.update()},this),"loaded.owl.lazy":a.proxy(function(a){a.namespace&&this._core.settings.autoHeight&&a.element.closest("."+this._core.settings.itemClass).index()===this._core.current()&&this.update()},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this._core.$element.on(this._handlers),this._intervalId=null;var d=this;a(b).on("load",function(){d._core.settings.autoHeight&&d.update()}),a(b).resize(function(){d._core.settings.autoHeight&&(null!=d._intervalId&&clearTimeout(d._intervalId),d._intervalId=setTimeout(function(){d.update()},250))})};e.Defaults={autoHeight:!1,autoHeightClass:"owl-height"},e.prototype.update=function(){var b=this._core._current,c=b+this._core.settings.items,d=this._core.settings.lazyLoad,e=this._core.$stage.children().toArray().slice(b,c),f=[],g=0;a.each(e,function(b,c){f.push(a(c).height())}),g=Math.max.apply(null,f),g<=1&&d&&this._previousHeight&&(g=this._previousHeight),this._previousHeight=g,this._core.$stage.parent().height(g).addClass(this._core.settings.autoHeightClass)},e.prototype.destroy=function(){var a,b;for(a in this._handlers)this._core.$element.off(a,this._handlers[a]);for(b in Object.getOwnPropertyNames(this))"function"!=typeof this[b]&&(this[b]=null)},a.fn.owlCarousel.Constructor.Plugins.AutoHeight=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(b){this._core=b,this._videos={},this._playing=null,this._handlers={"initialized.owl.carousel":a.proxy(function(a){a.namespace&&this._core.register({type:"state",name:"playing",tags:["interacting"]})},this),"resize.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.video&&this.isInFullScreen()&&a.preventDefault()},this),"refreshed.owl.carousel":a.proxy(function(a){a.namespace&&this._core.is("resizing")&&this._core.$stage.find(".cloned .owl-video-frame").remove()},this),"changed.owl.carousel":a.proxy(function(a){a.namespace&&"position"===a.property.name&&this._playing&&this.stop()},this),"prepared.owl.carousel":a.proxy(function(b){if(b.namespace){var c=a(b.content).find(".owl-video");c.length&&(c.css("display","none"),this.fetch(c,a(b.content)))}},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this._core.$element.on(this._handlers),this._core.$element.on("click.owl.video",".owl-video-play-icon",a.proxy(function(a){this.play(a)},this))};e.Defaults={video:!1,videoHeight:!1,videoWidth:!1},e.prototype.fetch=function(a,b){var c=function(){return a.attr("data-vimeo-id")?"vimeo":a.attr("data-vzaar-id")?"vzaar":"youtube"}(),d=a.attr("data-vimeo-id")||a.attr("data-youtube-id")||a.attr("data-vzaar-id"),e=a.attr("data-width")||this._core.settings.videoWidth,f=a.attr("data-height")||this._core.settings.videoHeight,g=a.attr("href");if(!g)throw new Error("Missing video URL.");if(d=g.match(/(http:|https:|)\/\/(player.|www.|app.)?(vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com|be\-nocookie\.com)|vzaar\.com)\/(video\/|videos\/|embed\/|channels\/.+\/|groups\/.+\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(\&\S+)?/),d[3].indexOf("youtu")>-1)c="youtube";else if(d[3].indexOf("vimeo")>-1)c="vimeo";else{if(!(d[3].indexOf("vzaar")>-1))throw new Error("Video URL not supported.");c="vzaar"}d=d[6],this._videos[g]={type:c,id:d,width:e,height:f},b.attr("data-video",g),this.thumbnail(a,this._videos[g])},e.prototype.thumbnail=function(b,c){var d,e,f,g=c.width&&c.height?"width:"+c.width+"px;height:"+c.height+"px;":"",h=b.find("img"),i="src",j="",k=this._core.settings,l=function(c){e='<div class="owl-video-play-icon"></div>',d=k.lazyLoad?a("<div/>",{class:"owl-video-tn "+j,srcType:c}):a("<div/>",{class:"owl-video-tn",style:"opacity:1;background-image:url("+c+")"}),b.after(d),b.after(e)};if(b.wrap(a("<div/>",{class:"owl-video-wrapper",style:g})),this._core.settings.lazyLoad&&(i="data-src",j="owl-lazy"),h.length)return l(h.attr(i)),h.remove(),!1;"youtube"===c.type?(f="//img.youtube.com/vi/"+c.id+"/hqdefault.jpg",l(f)):"vimeo"===c.type?a.ajax({type:"GET",url:"//vimeo.com/api/v2/video/"+c.id+".json",jsonp:"callback",dataType:"jsonp",success:function(a){f=a[0].thumbnail_large,l(f)}}):"vzaar"===c.type&&a.ajax({type:"GET",url:"//vzaar.com/api/videos/"+c.id+".json",jsonp:"callback",dataType:"jsonp",success:function(a){f=a.framegrab_url,l(f)}})},e.prototype.stop=function(){this._core.trigger("stop",null,"video"),this._playing.find(".owl-video-frame").remove(),this._playing.removeClass("owl-video-playing"),this._playing=null,this._core.leave("playing"),this._core.trigger("stopped",null,"video")},e.prototype.play=function(b){var c,d=a(b.target),e=d.closest("."+this._core.settings.itemClass),f=this._videos[e.attr("data-video")],g=f.width||"100%",h=f.height||this._core.$stage.height();this._playing||(this._core.enter("playing"),this._core.trigger("play",null,"video"),e=this._core.items(this._core.relative(e.index())),this._core.reset(e.index()),c=a('<iframe frameborder="0" allowfullscreen mozallowfullscreen webkitAllowFullScreen ></iframe>'),c.attr("height",h),c.attr("width",g),"youtube"===f.type?c.attr("src","//www.youtube.com/embed/"+f.id+"?autoplay=1&rel=0&v="+f.id):"vimeo"===f.type?c.attr("src","//player.vimeo.com/video/"+f.id+"?autoplay=1"):"vzaar"===f.type&&c.attr("src","//view.vzaar.com/"+f.id+"/player?autoplay=true"),a(c).wrap('<div class="owl-video-frame" />').insertAfter(e.find(".owl-video")),this._playing=e.addClass("owl-video-playing"))},e.prototype.isInFullScreen=function(){var b=c.fullscreenElement||c.mozFullScreenElement||c.webkitFullscreenElement;return b&&a(b).parent().hasClass("owl-video-frame")},e.prototype.destroy=function(){var a,b;this._core.$element.off("click.owl.video");for(a in this._handlers)this._core.$element.off(a,this._handlers[a]);for(b in Object.getOwnPropertyNames(this))"function"!=typeof this[b]&&(this[b]=null)},a.fn.owlCarousel.Constructor.Plugins.Video=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(b){this.core=b,this.core.options=a.extend({},e.Defaults,this.core.options),this.swapping=!0,this.previous=d,this.next=d,this.handlers={"change.owl.carousel":a.proxy(function(a){a.namespace&&"position"==a.property.name&&(this.previous=this.core.current(),this.next=a.property.value)},this),"drag.owl.carousel dragged.owl.carousel translated.owl.carousel":a.proxy(function(a){a.namespace&&(this.swapping="translated"==a.type)},this),"translate.owl.carousel":a.proxy(function(a){a.namespace&&this.swapping&&(this.core.options.animateOut||this.core.options.animateIn)&&this.swap()},this)},this.core.$element.on(this.handlers)};e.Defaults={animateOut:!1,
14animateIn:!1},e.prototype.swap=function(){if(1===this.core.settings.items&&a.support.animation&&a.support.transition){this.core.speed(0);var b,c=a.proxy(this.clear,this),d=this.core.$stage.children().eq(this.previous),e=this.core.$stage.children().eq(this.next),f=this.core.settings.animateIn,g=this.core.settings.animateOut;this.core.current()!==this.previous&&(g&&(b=this.core.coordinates(this.previous)-this.core.coordinates(this.next),d.one(a.support.animation.end,c).css({left:b+"px"}).addClass("animated owl-animated-out").addClass(g)),f&&e.one(a.support.animation.end,c).addClass("animated owl-animated-in").addClass(f))}},e.prototype.clear=function(b){a(b.target).css({left:""}).removeClass("animated owl-animated-out owl-animated-in").removeClass(this.core.settings.animateIn).removeClass(this.core.settings.animateOut),this.core.onTransitionEnd()},e.prototype.destroy=function(){var a,b;for(a in this.handlers)this.core.$element.off(a,this.handlers[a]);for(b in Object.getOwnPropertyNames(this))"function"!=typeof this[b]&&(this[b]=null)},a.fn.owlCarousel.Constructor.Plugins.Animate=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){var e=function(b){this._core=b,this._call=null,this._time=0,this._timeout=0,this._paused=!0,this._handlers={"changed.owl.carousel":a.proxy(function(a){a.namespace&&"settings"===a.property.name?this._core.settings.autoplay?this.play():this.stop():a.namespace&&"position"===a.property.name&&this._paused&&(this._time=0)},this),"initialized.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.autoplay&&this.play()},this),"play.owl.autoplay":a.proxy(function(a,b,c){a.namespace&&this.play(b,c)},this),"stop.owl.autoplay":a.proxy(function(a){a.namespace&&this.stop()},this),"mouseover.owl.autoplay":a.proxy(function(){this._core.settings.autoplayHoverPause&&this._core.is("rotating")&&this.pause()},this),"mouseleave.owl.autoplay":a.proxy(function(){this._core.settings.autoplayHoverPause&&this._core.is("rotating")&&this.play()},this),"touchstart.owl.core":a.proxy(function(){this._core.settings.autoplayHoverPause&&this._core.is("rotating")&&this.pause()},this),"touchend.owl.core":a.proxy(function(){this._core.settings.autoplayHoverPause&&this.play()},this)},this._core.$element.on(this._handlers),this._core.options=a.extend({},e.Defaults,this._core.options)};e.Defaults={autoplay:!1,autoplayTimeout:5e3,autoplayHoverPause:!1,autoplaySpeed:!1},e.prototype._next=function(d){this._call=b.setTimeout(a.proxy(this._next,this,d),this._timeout*(Math.round(this.read()/this._timeout)+1)-this.read()),this._core.is("interacting")||c.hidden||this._core.next(d||this._core.settings.autoplaySpeed)},e.prototype.read=function(){return(new Date).getTime()-this._time},e.prototype.play=function(c,d){var e;this._core.is("rotating")||this._core.enter("rotating"),c=c||this._core.settings.autoplayTimeout,e=Math.min(this._time%(this._timeout||c),c),this._paused?(this._time=this.read(),this._paused=!1):b.clearTimeout(this._call),this._time+=this.read()%c-e,this._timeout=c,this._call=b.setTimeout(a.proxy(this._next,this,d),c-e)},e.prototype.stop=function(){this._core.is("rotating")&&(this._time=0,this._paused=!0,b.clearTimeout(this._call),this._core.leave("rotating"))},e.prototype.pause=function(){this._core.is("rotating")&&!this._paused&&(this._time=this.read(),this._paused=!0,b.clearTimeout(this._call))},e.prototype.destroy=function(){var a,b;this.stop();for(a in this._handlers)this._core.$element.off(a,this._handlers[a]);for(b in Object.getOwnPropertyNames(this))"function"!=typeof this[b]&&(this[b]=null)},a.fn.owlCarousel.Constructor.Plugins.autoplay=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){"use strict";var e=function(b){this._core=b,this._initialized=!1,this._pages=[],this._controls={},this._templates=[],this.$element=this._core.$element,this._overrides={next:this._core.next,prev:this._core.prev,to:this._core.to}
vendor: 5,569 bytes, line 14
14,this._handlers={"prepared.owl.carousel":a.proxy(function(b){b.namespace&&this._core.settings.dotsData&&this._templates.push('<div class="'+this._core.settings.dotClass+'">'+a(b.content).find("[data-dot]").addBack("[data-dot]").attr("data-dot")+"</div>")},this),"added.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.dotsData&&this._templates.splice(a.position,0,this._templates.pop())},this),"remove.owl.carousel":a.proxy(function(a){a.namespace&&this._core.settings.dotsData&&this._templates.splice(a.position,1)},this),"changed.owl.carousel":a.proxy(function(a){a.namespace&&"position"==a.property.name&&this.draw()},this),"initialized.owl.carousel":a.proxy(function(a){a.namespace&&!this._initialized&&(this._core.trigger("initialize",null,"navigation"),this.initialize(),this.update(),this.draw(),this._initialized=!0,this._core.trigger("initialized",null,"navigation"))},this),"refreshed.owl.carousel":a.proxy(function(a){a.namespace&&this._initialized&&(this._core.trigger("refresh",null,"navigation"),this.update(),this.draw(),this._core.trigger("refreshed",null,"navigation"))},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this.$element.on(this._handlers)};e.Defaults={nav:!1,navText:['<span aria-label="Previous">&#x2039;</span>','<span aria-label="Next">&#x203a;</span>'],navSpeed:!1,navElement:'button type="button" role="presentation"',navContainer:!1,navContainerClass:"owl-nav",navClass:["owl-prev","owl-next"],slideBy:1,dotClass:"owl-dot",dotsClass:"owl-dots",dots:!0,dotsEach:!1,dotsData:!1,dotsSpeed:!1,dotsContainer:!1},e.prototype.initialize=function(){var b,c=this._core.settings;this._controls.$relative=(c.navContainer?a(c.navContainer):a("<div>").addClass(c.navContainerClass).appendTo(this.$element)).addClass("disabled"),this._controls.$previous=a("<"+c.navElement+">").addClass(c.navClass[0]).html(c.navText[0]).prependTo(this._controls.$relative).on("click",a.proxy(function(a){this.prev(c.navSpeed)},this)),this._controls.$next=a("<"+c.navElement+">").addClass(c.navClass[1]).html(c.navText[1]).appendTo(this._controls.$relative).on("click",a.proxy(function(a){this.next(c.navSpeed)},this)),c.dotsData||(this._templates=[a('<button role="button">').addClass(c.dotClass).append(a("<span>")).prop("outerHTML")]),this._controls.$absolute=(c.dotsContainer?a(c.dotsContainer):a("<div>").addClass(c.dotsClass).appendTo(this.$element)).addClass("disabled"),this._controls.$absolute.on("click","button",a.proxy(function(b){var d=a(b.target).parent().is(this._controls.$absolute)?a(b.target).index():a(b.target).parent().index();b.preventDefault(),this.to(d,c.dotsSpeed)},this));for(b in this._overrides)this._core[b]=a.proxy(this[b],this)},e.prototype.destroy=function(){var a,b,c,d,e;e=this._core.settings;for(a in this._handlers)this.$element.off(a,this._handlers[a]);for(b in this._controls)"$relative"===b&&e.navContainer?this._controls[b].html(""):this._controls[b].remove();for(d in this.overides)this._core[d]=this._overrides[d];for(c in Object.getOwnPropertyNames(this))"function"!=typeof this[c]&&(this[c]=null)},e.prototype.update=function(){var a,b,c,d=this._core.clones().length/2,e=d+this._core.items().length,f=this._core.maximum(!0),g=this._core.settings,h=g.center||g.autoWidth||g.dotsData?1:g.dotsEach||g.items;if("page"!==g.slideBy&&(g.slideBy=Math.min(g.slideBy,g.items)),g.dots||"page"==g.slideBy)for(this._pages=[],a=d,b=0,c=0;a<e;a++){if(b>=h||0===b){if(this._pages.push({start:Math.min(f,a-d),end:a-d+h-1}),Math.min(f,a-d)===f)break;b=0,++c}b+=this._core.mergers(this._core.relative(a))}},e.prototype.draw=function(){var b,c=this._core.settings,d=this._core.items().length<=c.items,e=this._core.relative(this._core.current()),f=c.loop||c.rewind;this._controls.$relative.toggleClass("disabled",!c.nav||d),c.nav&&(this._controls.$previous.toggleClass("disabled",!f&&e<=this._core.minimum(!0)),this._controls.$next.toggleClass("disabled",!f&&e>=this._core.maximum(!0))),this._controls.$absolute.toggleClass("disabled",!c.dots||d),c.dots&&(b=this._pages.length-this._controls.$absolute.children().length,c.dotsData&&0!==b?this._controls.$absolute.html(this._templates.join("")):b>0?this._controls.$absolute.append(new Array(b+1).join(this._templates[0])):b<0&&this._controls.$absolute.children().slice(b).remove(),this._controls.$absolute.find(".active").removeClass("active"),this._controls.$absolute.children().eq(a.inArray(this.current(),this._pages)).addClass("active"))},e.prototype.onTrigger=function(b){var c=this._core.settings;b.page={index:a.inArray(this.current(),this._pages),count:this._pages.length,size:c&&(c.center||c.autoWidth||c.dotsData?1:c.dotsEach||c.items)}},e.prototype.current=function(){var b=this._core.relative(this._core.current());return a.grep(this._pages,a.proxy(function(a,c){return a.start<=b&&a.end>=b},this)).pop()},e.prototype.getPosition=function(b){var c,d,e=this._core.settings;return"page"==e.slideBy?(c=a.inArray(this.current(),this._pages),d=this._pages.length,b?++c:--c,c=this._pages[(c%d+d)%d].start):(c=this._core.relative(this._core.current()),d=this._core.items().length,b?c+=e.slideBy:c-=e.slideBy),c},e.prototype.next=function(b){a.proxy(this._overrides.to,this._core)(this.getPosition(!0),b)},e.prototype.prev=function(b){a.proxy(this._overrides.to,this._core)(this.getPosition(!1),b)},e.prototype.to=function(b,c,d){var e;!d&&this._pages.length?(e=this._pages.length,a.proxy(this._overrides.to,this._core)(this._pages[(b%e+e)%e].start,c)):a.proxy(this._overrides.to,this._core)(b,c)},a.fn.owlCarousel.Constructor.Plugins.Navigation=e}(
vendor: 3,328 bytes, lines 14-28
14window.Zepto||window.jQuery,window,document),function(a,b,c,d){"use strict";var e=function(c){this._core=c,this._hashes={},this.$element=this._core.$element,this._handlers={"initialized.owl.carousel":a.proxy(function(c){c.namespace&&"URLHash"===this._core.settings.startPosition&&a(b).trigger("hashchange.owl.navigation")},this),"prepared.owl.carousel":a.proxy(function(b){if(b.namespace){var c=a(b.content).find("[data-hash]").addBack("[data-hash]").attr("data-hash");if(!c)return;this._hashes[c]=b.content}},this),"changed.owl.carousel":a.proxy(function(c){if(c.namespace&&"position"===c.property.name){var d=this._core.items(this._core.relative(this._core.current())),e=a.map(this._hashes,function(a,b){return a===d?b:null}).join();if(!e||b.location.hash.slice(1)===e)return;b.location.hash=e}},this)},this._core.options=a.extend({},e.Defaults,this._core.options),this.$element.on(this._handlers),a(b).on("hashchange.owl.navigation",a.proxy(function(a){var c=b.location.hash.substring(1),e=this._core.$stage.children(),f=this._hashes[c]&&e.index(this._hashes[c]);f!==d&&f!==this._core.current()&&this._core.to(this._core.relative(f),!1,!0)},this))};e.Defaults={URLhashListener:!1},e.prototype.destroy=function(){var c,d;a(b).off("hashchange.owl.navigation");for(c in this._handlers)this._core.$element.off(c,this._handlers[c]);for(d in Object.getOwnPropertyNames(this))"function"!=typeof this[d]&&(this[d]=null)},a.fn.owlCarousel.Constructor.Plugins.Hash=e}(window.Zepto||window.jQuery,window,document),function(a,b,c,d){function e(b,c){var e=!1,f=b.charAt(0).toUpperCase()+b.slice(1);return a.each((b+" "+h.join(f+" ")+f).split(" "),function(a,b){if(g[b]!==d)return e=!c||b,!1}),e}function f(a){return e(a,!0)}var g=a("<support>").get(0).style,h="Webkit Moz O ms".split(" "),i={transition:{end:{WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd",transition:"transitionend"}},animation:{end:{WebkitAnimation:"webkitAnimationEnd",MozAnimation:"animationend",OAnimation:"oAnimationEnd",animation:"animationend"}}},j={csstransforms:function(){return!!e("transform")},csstransforms3d:function(){return!!e("perspective")},csstransitions:function(){return!!e("transition")},cssanimations:function(){return!!e("animation")}};j.csstransitions()&&(a.support.transition=new String(f("transition")),a.support.transition.end=i.transition.end[a.support.transition]),j.cssanimations()&&(a.support.animation=new String(f("animation")),a.support.animation.end=i.animation.end[a.support.animation]),j.csstransforms()&&(a.support.transform=new String(f("transform")),a.support.transform3d=j.csstransforms3d())}(window.Zepto||window.jQuery,window,document);
15/* End */
16;
17; /* Start:"a:4:{s:4:"full";s:91:"/local/templates/gvozdevsoft_profigs_s1/lib/fancybox/jquery.fancybox.min.js?173827436866400";s:6:"source";s:75:"/local/templates/gvozdevsoft_profigs_s1/lib/fancybox/jquery.fancybox.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
18// ==================================================
19// fancyBox v3.5.7
20//
21// Licensed GPLv3 for open source use
22// or fancyBox Commercial License for commercial use
23//
24// http://fancyapps.com/fancybox/
25// Copyright 2022 fancyApps
26//
27// ==================================================
28!function(t,e,n,o){"use strict";if(t.console=t.console||{info:function(t){}}
vendor: 14,211 bytes, line 28
28,n)if(n.fn.fancybox)console.info("fancyBox already initialized");else{var i,s,a={closeExisting:!1,loop:!1,gutter:50,keyboard:!0,preventCaptionOverlap:!0,arrows:!0,infobar:!0,smallBtn:"auto",toolbar:"auto",buttons:["zoom","slideShow","thumbs","close"],idleTime:3,protect:!1,modal:!1,image:{preload:!1},ajax:{settings:{data:{fancybox:!0}}},iframe:{tpl:'<iframe id="fancybox-frame{rnd}" name="fancybox-frame{rnd}" class="fancybox-iframe" allowfullscreen="allowfullscreen" allow="autoplay; fullscreen" src=""></iframe>',preload:!0,css:{},attr:{scrolling:"auto"}},video:{tpl:'<video class="fancybox-video" controls controlsList="nodownload" poster="{{poster}}"><source src="{{src}}" type="{{format}}" />Sorry, your browser doesn\'t support embedded videos, <a href="{{src}}">download</a> and watch with your favorite video player!</video>',format:"",autoStart:!0},defaultType:"image",animationEffect:"zoom",animationDuration:366,zoomOpacity:"auto",transitionEffect:"fade",transitionDuration:366,slideClass:"",baseClass:"",baseTpl:'<div class="fancybox-container" role="dialog" tabindex="-1"><div class="fancybox-bg"></div><div class="fancybox-inner"><div class="fancybox-infobar"><span data-fancybox-index></span>&nbsp;/&nbsp;<span data-fancybox-count></span></div><div class="fancybox-toolbar">{{buttons}}</div><div class="fancybox-navigation">{{arrows}}</div><div class="fancybox-stage"></div><div class="fancybox-caption"><div class="fancybox-caption__body"></div></div></div></div>',spinnerTpl:'<div class="fancybox-loading"></div>',errorTpl:'<div class="fancybox-error"><p>{{ERROR}}</p></div>',btnTpl:{download:'<a download data-fancybox-download class="fancybox-button fancybox-button--download" title="{{DOWNLOAD}}" href="javascript:;"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M18.62 17.09V19H5.38v-1.91zm-2.97-6.96L17 11.45l-5 4.87-5-4.87 1.36-1.32 2.68 2.64V5h1.92v7.77z"/></svg></a>',zoom:'<button data-fancybox-zoom class="fancybox-button fancybox-button--zoom" title="{{ZOOM}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M18.7 17.3l-3-3a5.9 5.9 0 0 0-.6-7.6 5.9 5.9 0 0 0-8.4 0 5.9 5.9 0 0 0 0 8.4 5.9 5.9 0 0 0 7.7.7l3 3a1 1 0 0 0 1.3 0c.4-.5.4-1 0-1.5zM8.1 13.8a4 4 0 0 1 0-5.7 4 4 0 0 1 5.7 0 4 4 0 0 1 0 5.7 4 4 0 0 1-5.7 0z"/></svg></button>',close:'<button data-fancybox-close class="fancybox-button fancybox-button--close" title="{{CLOSE}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 10.6L6.6 5.2 5.2 6.6l5.4 5.4-5.4 5.4 1.4 1.4 5.4-5.4 5.4 5.4 1.4-1.4-5.4-5.4 5.4-5.4-1.4-1.4-5.4 5.4z"/></svg></button>',arrowLeft:'<button data-fancybox-prev class="fancybox-button fancybox-button--arrow_left" title="{{PREV}}"><div><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M11.28 15.7l-1.34 1.37L5 12l4.94-5.07 1.34 1.38-2.68 2.72H19v1.94H8.6z"/></svg></div></button>',arrowRight:'<button data-fancybox-next class="fancybox-button fancybox-button--arrow_right" title="{{NEXT}}"><div><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M15.4 12.97l-2.68 2.72 1.34 1.38L19 12l-4.94-5.07-1.34 1.38 2.68 2.72H5v1.94z"/></svg></div></button>',smallBtn:'<button type="button" data-fancybox-close class="fancybox-button fancybox-close-small" title="{{CLOSE}}"><svg xmlns="http://www.w3.org/2000/svg" version="1" viewBox="0 0 24 24"><path d="M13 12l5-5-1-1-5 5-5-5-1 1 5 5-5 5 1 1 5-5 5 5 1-1z"/></svg></button>'},parentEl:"body",hideScrollbar:!0,autoFocus:!0,backFocus:!0,trapFocus:!0,fullScreen:{autoStart:!1},touch:{vertical:!0,momentum:!0},hash:null,media:{},slideShow:{autoStart:!1,speed:3e3},thumbs:{autoStart:!1,hideOnClose:!0,parentEl:".fancybox-container",axis:"y"},wheel:"auto",onInit:n.noop,beforeLoad:n.noop,afterLoad:n.noop,beforeShow:n.noop,afterShow:n.noop,beforeClose:n.noop,afterClose:n.noop,onActivate:n.noop,onDeactivate:n.noop,clickContent:function(t,e){return"image"===t.type&&"zoom"},clickSlide:"close",clickOutside:"close",dblclickContent:!1,dblclickSlide:!1,dblclickOutside:!1,mobile:{preventCaptionOverlap:!1,idleTime:!1,clickContent:function(t,e){return"image"===t.type&&"toggleControls"},clickSlide:function(t,e){return"image"===t.type?"toggleControls":"close"},dblclickContent:function(t,e){return"image"===t.type&&"zoom"},dblclickSlide:function(t,e){return"image"===t.type&&"zoom"}},lang:"en",i18n:{en:{CLOSE:"Close",NEXT:"Next",PREV:"Previous",ERROR:"The requested content cannot be loaded. <br/> Please try again later.",PLAY_START:"Start slideshow",PLAY_STOP:"Pause slideshow",FULL_SCREEN:"Full screen",THUMBS:"Thumbnails",DOWNLOAD:"Download",SHARE:"Share",ZOOM:"Zoom"},de:{CLOSE:"Schlie&szlig;en",NEXT:"Weiter",PREV:"Zur&uuml;ck",ERROR:"Die angeforderten Daten konnten nicht geladen werden. <br/> Bitte versuchen Sie es sp&auml;ter nochmal.",PLAY_START:"Diaschau starten",PLAY_STOP:"Diaschau beenden",FULL_SCREEN:"Vollbild",THUMBS:"Vorschaubilder",DOWNLOAD:"Herunterladen",SHARE:"Teilen",ZOOM:"Vergr&ouml;&szlig;ern"}}},r=n(t),c=n(e),l=0,h=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||function(e){return t.setTimeout(e,1e3/60)},d=t.cancelAnimationFrame||t.webkitCancelAnimationFrame||t.mozCancelAnimationFrame||t.oCancelAnimationFrame||function(e){t.clearTimeout(e)},u=function(){var t,n=e.createElement("fakeelement"),o={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(t in o)if(void 0!==n.style[t])return o[t];return"transitionend"}(),f=function(t){return t&&t.length&&t[0].offsetHeight},p=function(t,e){var o=n.extend(!0,{},t,e);return n.each(e,function(t,e){n.isArray(e)&&(o[t]=e)}),o},g=function(t,e,o){this.opts=p({index:o},n.fancybox.defaults),n.isPlainObject(e)&&(this.opts=p(this.opts,e)),n.fancybox.isMobile&&(this.opts=p(this.opts,this.opts.mobile)),this.id=this.opts.id||++l,this.currIndex=parseInt(this.opts.index,10)||0,this.prevIndex=null,this.prevPos=null,this.currPos=0,this.firstRun=!0,this.group=[],this.slides={},this.addContent(t),this.group.length&&this.init()};n.extend(g.prototype,{init:function(){var o,i,s=this,a=s.group[s.currIndex].opts;a.closeExisting&&n.fancybox.close(!0),n("body").addClass("fancybox-active"),!n.fancybox.getInstance()&&!1!==a.hideScrollbar&&!n.fancybox.isMobile&&e.body.scrollHeight>t.innerHeight&&(n("head").append('<style id="fancybox-style-noscroll" type="text/css">.compensate-for-scrollbar{margin-right:'+(t.innerWidth-e.documentElement.clientWidth)+"px;}</style>"),n("body").addClass("compensate-for-scrollbar")),i="",n.each(a.buttons,function(t,e){i+=a.btnTpl[e]||""}),o=n(s.translate(s,a.baseTpl.replace("{{buttons}}",i).replace("{{arrows}}",a.btnTpl.arrowLeft+a.btnTpl.arrowRight))).attr("id","fancybox-container-"+s.id).addClass(a.baseClass).data("FancyBox",s).appendTo(a.parentEl),s.$refs={container:o},["bg","inner","infobar","toolbar","stage","caption","navigation"].forEach(function(t){s.$refs[t]=o.find(".fancybox-"+t)}),s.trigger("onInit"),s.activate(),s.jumpTo(s.currIndex)},translate:function(t,e){var n=t.opts.i18n[t.opts.lang]||t.opts.i18n.en;return e.replace(/\{\{(\w+)\}\}/g,function(t,e){return void 0===n[e]?t:n[e]})},addContent:function(t){var e,o=this,i=n.makeArray(t);n.each(i,function(t,e){var i,s,a,r,c,l={},h={};n.isPlainObject(e)?(l=e,h=e.opts||e):"object"===n.type(e)&&n(e).length?(h=(i=n(e)).data()||{},(h=n.extend(!0,{},h,h.options)).$orig=i,l.src=o.opts.src||h.src||i.attr("href"),l.type||l.src||(l.type="inline",l.src=e)):l={type:"html",src:e+""},l.opts=n.extend(!0,{},o.opts,h),n.isArray(h.buttons)&&(l.opts.buttons=h.buttons),n.fancybox.isMobile&&l.opts.mobile&&(l.opts=p(l.opts,l.opts.mobile)),s=l.type||l.opts.type,r=l.src||"",!s&&r&&((a=r.match(/\.(mp4|mov|ogv|webm)((\?|#).*)?$/i))?(s="video",l.opts.video.format||(l.opts.video.format="video/"+("ogv"===a[1]?"ogg":a[1]))):r.match(/(^data:image\/[a-z0-9+\/=]*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg|ico)((\?|#).*)?$)/i)?s="image":r.match(/\.(pdf)((\?|#).*)?$/i)?(s="iframe",l=n.extend(!0,l,{contentType:"pdf",opts:{iframe:{preload:!1}}})):"#"===r.charAt(0)&&(s="inline")),s?l.type=s:o.trigger("objectNeedsType",l),l.contentType||(l.contentType=n.inArray(l.type,["html","inline","ajax"])>-1?"html":l.type),l.index=o.group.length,"auto"==l.opts.smallBtn&&(l.opts.smallBtn=n.inArray(l.type,["html","inline","ajax"])>-1),"auto"===l.opts.toolbar&&(l.opts.toolbar=!l.opts.smallBtn),l.$thumb=l.opts.$thumb||null,l.opts.$trigger&&l.index===o.opts.index&&(l.$thumb=l.opts.$trigger.find("img:first"),l.$thumb.length&&(l.opts.$orig=l.opts.$trigger)),l.$thumb&&l.$thumb.length||!l.opts.$orig||(l.$thumb=l.opts.$orig.find("img:first")),l.$thumb&&!l.$thumb.length&&(l.$thumb=null),l.thumb=l.opts.thumb||(l.$thumb?l.$thumb[0].src:null),"function"===n.type(l.opts.caption)&&(l.opts.caption=l.opts.caption.apply(e,[o,l])),"function"===n.type(o.opts.caption)&&(l.opts.caption=o.opts.caption.apply(e,[o,l])),l.opts.caption instanceof n||(l.opts.caption=void 0===l.opts.caption?"":l.opts.caption+""),"ajax"===l.type&&(c=r.split(/\s+/,2)).length>1&&(l.src=c.shift(),l.opts.filter=c.shift()),l.opts.modal&&(l.opts=n.extend(!0,l.opts,{trapFocus:!0,infobar:0,toolbar:0,smallBtn:0,keyboard:0,slideShow:0,fullScreen:0,thumbs:0,touch:0,clickContent:!1,clickSlide:!1,clickOutside:!1,dblclickContent:!1,dblclickSlide:!1,dblclickOutside:!1})),o.group.push(l)}),Object.keys(o.slides).length&&(o.updateControls(),(e=o.Thumbs)&&e.isActive&&(e.create(),e.focus()))},addEvents:function(){var e=this;e.removeEvents(),e.$refs.container.on("click.fb-close","[data-fancybox-close]",function(t){t.stopPropagation(),t.preventDefault(),e.close(t)}).on("touchstart.fb-prev click.fb-prev","[data-fancybox-prev]",function(t){t.stopPropagation(),t.preventDefault(),e.previous()}).on("touchstart.fb-next click.fb-next","[data-fancybox-next]",function(t){t.stopPropagation(),t.preventDefault(),e.next()}).on("click.fb","[data-fancybox-zoom]",function(t){e[e.isScaledDown()?"scaleToActual":"scaleToFit"]()}),r.on("orientationchange.fb resize.fb",function(t){t&&t.originalEvent&&"resize"===t.originalEvent.type?(e.requestId&&d(e.requestId),e.requestId=h(function(){e.update(t)})):(e.current&&"iframe"===e.current.type&&e.$refs.stage.hide(),setTimeout(function(){e.$refs.stage.show(),e.update(t)},n.fancybox.isMobile?600:250))}),c.on("keydown.fb",function(t){var o=(n.fancybox?n.fancybox.getInstance():null).current,i=t.keyCode||t.which;if(9!=i){if(!(!o.opts.keyboard||t.ctrlKey||t.altKey||t.shiftKey||n(t.target).is("input,textarea,video,audio,select")))return 8===i||27===i?(t.preventDefault(),void e.close(t)):37===i||38===i?(t.preventDefault(),void e.previous()):39===i||40===i?(t.preventDefault(),void e.next()):void e.trigger("afterKeydown",t,i)}else o.opts.trapFocus&&e.focus(t)}),e.group[e.currIndex].opts.idleTime&&(e.idleSecondsCounter=0,c.on("mousemove.fb-idle mouseleave.fb-idle mousedown.fb-idle touchstart.fb-idle touchmove.fb-idle scroll.fb-idle keydown.fb-idle",function(t){e.idleSecondsCounter=0,e.isIdle&&e.showControls(),e.isIdle=!1}),e.idleInterval=t.setInterval(function(){e.idleSecondsCounter++,e.idleSecondsCounter>=e.group[e.currIndex].opts.idleTime&&!e.isDragging&&(e.isIdle=!0,e.idleSecondsCounter=0,e.hideControls())},1e3))},removeEvents:function(){r.off("orientationchange.fb resize.fb"),c.off("keydown.fb .fb-idle"),this.$refs.container.off(".fb-close .fb-prev .fb-next"),this.idleInterval&&(t.clearInterval(this.idleInterval),this.idleInterval=null)},previous:function(t){return this.jumpTo(this.currPos-1,t)},next:function(t){return this.jumpTo(this.currPos+1,t)},jumpTo:function(t,e){var o,i,s,a,r,c,l,h,d,u=this,p=u.group.length;if(!(u.isDragging||u.isClosing||u.isAnimating&&u.firstRun)){if(t=parseInt(t,10),!(s=u.current?u.current.opts.loop:u.opts.loop)&&(t<0||t>=p))return!1;if(o=u.firstRun=!Object.keys(u.slides).length,r=u.current,u.prevIndex=u.currIndex,u.prevPos=u.currPos,a=u.createSlide(t),p>1&&((s||a.index<p-1)&&u.createSlide(t+1),(s||a.index>0)&&u.createSlide(t-1)),u.current=a,u.currIndex=a.index,u.currPos=a.pos,u.trigger("beforeShow",o),u.updateControls(),a.forcedDuration=void 0,n.isNumeric(e)?a.forcedDuration=e:e=a.opts[o?"animationDuration":"transitionDuration"],e=parseInt(e,10),i=u.isMoved(a),a.$slide.addClass("fancybox-slide--current"),o)return a.opts.animationEffect&&e&&u.$refs.container.css("transition-duration",e+"ms"),u.$refs.container.addClass("fancybox-is-open").trigger("focus"),u.loadSlide(a),void u.preload("image");c=n.fancybox.getTranslate(r.$slide),l=n.fancybox.getTranslate(u.$refs.stage),n.each(u.slides,function(t,e){n.fancybox.stop(e.$slide,!0)}),r.pos!==a.pos&&(r.isComplete=!1),r.$slide.removeClass("fancybox-slide--complete fancybox-slide--current"),i?(d=c.left-(r.pos*c.width+r.pos*r.opts.gutter),n.each(u.slides,function(t,o){o.$slide.removeClass("fancybox-animated").removeClass(function(t,e){return(e.match(/(^|\s)fancybox-fx-\S+/g)||[]).join(" ")});var i=o.pos*c.width+o.pos*o.opts.gutter;n.fancybox.setTranslate(o.$slide,{top:0,left:i-l.left+d}),o.pos!==a.pos&&o.$slide.addClass("fancybox-slide--"+(o.pos>a.pos?"next":"previous")),f(o.$slide),n.fancybox.animate(o.$slide,{top:0,left:(o.pos-a.pos)*c.width+(o.pos-a.pos)*o.opts.gutter},e,function(){o.$slide.css({transform:"",opacity:""}).removeClass("fancybox-slide--next fancybox-slide--previous"),o.pos===u.currPos&&u.complete()})})):e&&a.opts.transitionEffect&&(h="fancybox-animated fancybox-fx-"+a.opts.transitionEffect,r.$slide.addClass("fancybox-slide--"+(r.pos>a.pos?"next":"previous")),n.fancybox.animate(r.$slide,h,e,function(){r.$slide.removeClass(h).removeClass("fancybox-slide--next fancybox-slide--previous")},!1)),a.isLoaded?u.revealContent(a):u.loadSlide(a),u.preload("image")}},createSlide:function(t){var e,o;return o=(o=t%this.group.length)<0?this.group.length+o:o,!this.slides[t]&&this.group[o]&&(e=n('<div class="fancybox-slide"></div>').appendTo(this.$refs.stage),this.slides[t]=n.extend(!0,{},this.group[o],{pos:t,$slide:e,isLoaded:!1}),this.updateSlide(this.slides[t])),this.slides[t]},scaleToActual:function(t,e,o){var i,s,a,r,c,l=this,h=l.current,d=h.$content,u=n.fancybox.getTranslate(h.$slide).width,f=n.fancybox.getTranslate(h.$slide).height,p=h.width,g=h.height;
28l.isAnimating||l.isMoved()||!d||"image"!=h.type||!h.isLoaded||h.hasError||(l.isAnimating=!0,n.fancybox.stop(d),t=void 0===t?.5*u:t,e=void 0===e?.5*f:e,(i=n.fancybox.getTranslate(d)).top-=n.fancybox.getTranslate(h.$slide).top,i.left-=n.fancybox.getTranslate(h.$slide).left,r=p/i.width,c=g/i.height,s=.5*u-.5*p,a=.5*f-.5*g,p>u&&((s=i.left*r-(t*r-t))>0&&(s=0),s<u-p&&(s=u-p)),g>f&&((a=i.top*c-(e*c-e))>0&&(a=0),a<f-g&&(a=f-g)),l.updateCursor(p,g),n.fancybox.animate(d,{top:a,left:s,scaleX:r,scaleY:c},o||366,function(){l.isAnimating=!1}),l.SlideShow&&l.SlideShow.isActive&&l.SlideShow.stop())},scaleToFit:function(t){var e,o=this,i=o.current,s=i.$content;o.isAnimating||o.isMoved()||!s||"image"!=i.type||!i.isLoaded||i.hasError||(o.isAnimating=!0,n.fancybox.stop(s),e=o.getFitPos(i),o.updateCursor(e.width,e.height),n.fancybox.animate(s,{top:e.top,left:e.left,scaleX:e.width/s.width(),scaleY:e.height/s.height()},t||366,function(){o.isAnimating=!1}))},getFitPos:function(t){var e,o,i,s,a=t.$content,r=t.$slide,c=t.width||t.opts.width,l=t.height||t.opts.height,h={};return!!(t.isLoaded&&a&&a.length)&&(e=n.fancybox.getTranslate(this.$refs.stage).width,o=n.fancybox.getTranslate(this.$refs.stage).height,e-=parseFloat(r.css("paddingLeft"))+parseFloat(r.css("paddingRight"))+parseFloat(a.css("marginLeft"))+parseFloat(a.css("marginRight")),o-=parseFloat(r.css("paddingTop"))+parseFloat(r.css("paddingBottom"))+parseFloat(a.css("marginTop"))+parseFloat(a.css("marginBottom")),c&&l||(c=e,l=o),(c*=i=Math.min(1,e/c,o/l))>e-.5&&(c=e),(l*=i)>o-.5&&(l=o),"image"===t.type?(h.top=Math.floor(.5*(o-l))+parseFloat(r.css("paddingTop")),h.left=Math.floor(.5*(e-c))+parseFloat(r.css("paddingLeft"))):"video"===t.contentType&&(l>c/(s=t.opts.width&&t.opts.height?c/l:t.opts.ratio||16/9)?l=c/s:c>l*s&&(c=l*s)),h.width=c,h.height=l,h)},update:function(t){var e=this;n.each(e.slides,function(n,o){e.updateSlide(o,t)})},updateSlide:function(t,e){var o=t&&t.$content,i=t.width||t.opts.width,s=t.height||t.opts.height,a=t.$slide;this.adjustCaption(t),o&&(i||s||"video"===t.contentType)&&!t.hasError&&(n.fancybox.stop(o),n.fancybox.setTranslate(o,this.getFitPos(t)),t.pos===this.currPos&&(this.isAnimating=!1,this.updateCursor())),this.adjustLayout(t),a.length&&(a.trigger("refresh"),t.pos===this.currPos&&this.$refs.toolbar.add(this.$refs.navigation.find(".fancybox-button--arrow_right")).toggleClass("compensate-for-scrollbar",a.get(0).scrollHeight>a.get(0).clientHeight)),this.trigger("onUpdate",t,e)},centerSlide:function(t){var e=this,o=e.current,i=o.$slide;!e.isClosing&&o&&(i.siblings().css({transform:"",opacity:""}),i.parent().children().removeClass("fancybox-slide--previous fancybox-slide--next"),n.fancybox.animate(i,{top:0,left:0,opacity:1},void 0===t?0:t,function(){i.css({transform:"",opacity:""}),o.isComplete||e.complete()},!1))},isMoved:function(t){var e,o,i=t||this.current;return!!i&&(o=n.fancybox.getTranslate(this.$refs.stage),e=n.fancybox.getTranslate(i.$slide),!i.$slide.hasClass("fancybox-animated")&&(Math.abs(e.top-o.top)>.5||Math.abs(e.left-o.left)>.5))},updateCursor:function(t,e){var o,i,s=this.current,a=this.$refs.container;s&&!this.isClosing&&this.Guestures&&(a.removeClass("fancybox-is-zoomable fancybox-can-zoomIn fancybox-can-zoomOut fancybox-can-swipe fancybox-can-pan"),i=!!(o=this.canPan(t,e))||this.isZoomable(),a.toggleClass("fancybox-is-zoomable",i),n("[data-fancybox-zoom]").prop("disabled",!i),o?a.addClass("fancybox-can-pan"):i&&("zoom"===s.opts.clickContent||n.isFunction(s.opts.clickContent)&&"zoom"==s.opts.clickContent(s))?a.addClass("fancybox-can-zoomIn"):s.opts.touch&&(s.opts.touch.vertical||this.group.length>1)&&"video"!==s.contentType&&a.addClass("fancybox-can-swipe"))},isZoomable:function(){var t,e=this.current;if(e&&!this.isClosing&&"image"===e.type&&!e.hasError){if(!e.isLoaded)return!0;if((t=this.getFitPos(e))&&(e.width>t.width||e.height>t.height))return!0}return!1},isScaledDown:function(t,e){var o=!1,i=this.current,s=i.$content;return void 0!==t&&void 0!==e?o=t<i.width&&e<i.height:s&&(o=(o=n.fancybox.getTranslate(s)).width<i.width&&o.height<i.height),o}
vendor: 11,383 bytes, line 28
28,canPan:function(t,e){var o=this.current,i=null,s=!1;return"image"===o.type&&(o.isComplete||t&&e)&&!o.hasError&&(s=this.getFitPos(o),void 0!==t&&void 0!==e?i={width:t,height:e}:o.isComplete&&(i=n.fancybox.getTranslate(o.$content)),i&&s&&(s=Math.abs(i.width-s.width)>1.5||Math.abs(i.height-s.height)>1.5)),s},loadSlide:function(t){var e,o,i,s=this;if(!t.isLoading&&!t.isLoaded){if(t.isLoading=!0,!1===s.trigger("beforeLoad",t))return t.isLoading=!1,!1;switch(e=t.type,(o=t.$slide).off("refresh").trigger("onReset").addClass(t.opts.slideClass),e){case"image":s.setImage(t);break;case"iframe":s.setIframe(t);break;case"html":s.setContent(t,t.src||t.content);break;case"video":s.setContent(t,t.opts.video.tpl.replace(/\{\{src\}\}/gi,t.src).replace("{{format}}",t.opts.videoFormat||t.opts.video.format||"").replace("{{poster}}",t.thumb||""));break;case"inline":n(t.src).length?s.setContent(t,n(t.src)):s.setError(t);break;case"ajax":s.showLoading(t),i=n.ajax(n.extend({},t.opts.ajax.settings,{url:t.src,success:function(e,n){"success"===n&&s.setContent(t,e)},error:function(e,n){e&&"abort"!==n&&s.setError(t)}})),o.one("onReset",function(){i.abort()});break;default:s.setError(t)}return!0}},setImage:function(t){var o,i=this;setTimeout(function(){var e=t.$image;i.isClosing||!t.isLoading||e&&e.length&&e[0].complete||t.hasError||i.showLoading(t)},50),i.checkSrcset(t),t.$content=n('<div class="fancybox-content"></div>').addClass("fancybox-is-hidden").appendTo(t.$slide.addClass("fancybox-slide--image")),!1!==t.opts.preload&&t.opts.width&&t.opts.height&&t.thumb&&(t.width=t.opts.width,t.height=t.opts.height,(o=e.createElement("img")).onerror=function(){n(this).remove(),t.$ghost=null},o.onload=function(){i.afterLoad(t)},t.$ghost=n(o).addClass("fancybox-image").appendTo(t.$content).attr("src",t.thumb)),i.setBigImage(t)},checkSrcset:function(e){var n,o,i,s,a=e.opts.srcset||e.opts.image.srcset;if(a){i=t.devicePixelRatio||1,s=t.innerWidth*i,(o=a.split(",").map(function(t){var e={};return t.trim().split(/\s+/).forEach(function(t,n){var o=parseInt(t.substring(0,t.length-1),10);if(0===n)return e.url=t;o&&(e.value=o,e.postfix=t[t.length-1])}),e})).sort(function(t,e){return t.value-e.value});for(var r=0;r<o.length;r++){var c=o[r];if("w"===c.postfix&&c.value>=s||"x"===c.postfix&&c.value>=i){n=c;break}}!n&&o.length&&(n=o[o.length-1]),n&&(e.src=n.url,e.width&&e.height&&"w"==n.postfix&&(e.height=e.width/e.height*n.value,e.width=n.value),e.opts.srcset=a)}},setBigImage:function(t){var o=this,i=e.createElement("img"),s=n(i);t.$image=s.one("error",function(){o.setError(t)}).one("load",function(){var e;t.$ghost||(o.resolveImageSlideSize(t,this.naturalWidth,this.naturalHeight),o.afterLoad(t)),o.isClosing||(t.opts.srcset&&((e=t.opts.sizes)&&"auto"!==e||(e=(t.width/t.height>1&&r.width()/r.height()>1?"100":Math.round(t.width/t.height*100))+"vw"),s.attr("sizes",e).attr("srcset",t.opts.srcset)),t.$ghost&&setTimeout(function(){t.$ghost&&!o.isClosing&&t.$ghost.hide()},Math.min(300,Math.max(1e3,t.height/1600))),o.hideLoading(t))}).addClass("fancybox-image").attr("src",t.src).appendTo(t.$content),(i.complete||"complete"==i.readyState)&&s.naturalWidth&&s.naturalHeight?s.trigger("load"):i.error&&s.trigger("error")},resolveImageSlideSize:function(t,e,n){var o=parseInt(t.opts.width,10),i=parseInt(t.opts.height,10);t.width=e,t.height=n,o>0&&(t.width=o,t.height=Math.floor(o*n/e)),i>0&&(t.width=Math.floor(i*e/n),t.height=i)},setIframe:function(t){var e,o=this,i=t.opts.iframe,s=t.$slide;t.$content=n('<div class="fancybox-content'+(i.preload?" fancybox-is-hidden":"")+'"></div>').css(i.css).appendTo(s),s.addClass("fancybox-slide--"+t.contentType),t.$iframe=e=n(i.tpl.replace(/\{rnd\}/g,(new Date).getTime())).attr(i.attr).appendTo(t.$content),i.preload?(o.showLoading(t),e.on("load.fb error.fb",function(e){this.isReady=1,t.$slide.trigger("refresh"),o.afterLoad(t)}),s.on("refresh.fb",function(){var n,o=t.$content,a=i.css.width,r=i.css.height;if(1===e[0].isReady){try{n=e.contents().find("body")}catch(t){}n&&n.length&&n.children().length&&(s.css("overflow","visible"),o.css({width:"100%","max-width":"100%",height:"9999px"}),void 0===a&&(a=Math.ceil(Math.max(n[0].clientWidth,n.outerWidth(!0)))),o.css("width",a||"").css("max-width",""),void 0===r&&(r=Math.ceil(Math.max(n[0].clientHeight,n.outerHeight(!0)))),o.css("height",r||""),s.css("overflow","auto")),o.removeClass("fancybox-is-hidden")}})):o.afterLoad(t),e.attr("src",t.src),s.one("onReset",function(){try{n(this).find("iframe").hide().unbind().attr("src","//about:blank")}catch(t){}n(this).off("refresh.fb").empty(),t.isLoaded=!1,t.isRevealed=!1})},setContent:function(t,e){var o;this.isClosing||(this.hideLoading(t),t.$content&&n.fancybox.stop(t.$content),t.$slide.empty(),(o=e)&&o.hasOwnProperty&&o instanceof n&&e.parent().length?((e.hasClass("fancybox-content")||e.parent().hasClass("fancybox-content"))&&e.parents(".fancybox-slide").trigger("onReset"),t.$placeholder=n("<div>").hide().insertAfter(e),e.css("display","inline-block")):t.hasError||("string"===n.type(e)&&(e=n("<div>").append(n.trim(e)).contents()),t.opts.filter&&(e=n("<div>").html(e).find(t.opts.filter))),t.$slide.one("onReset",function(){n(this).find("video,audio").trigger("pause"),t.$placeholder&&(t.$placeholder.after(e.removeClass("fancybox-content").hide()).remove(),t.$placeholder=null),t.$smallBtn&&(t.$smallBtn.remove(),t.$smallBtn=null),t.hasError||(n(this).empty(),t.isLoaded=!1,t.isRevealed=!1)}),n(e).appendTo(t.$slide),n(e).is("video,audio")&&(n(e).addClass("fancybox-video"),n(e).wrap("<div></div>"),t.contentType="video",t.opts.width=t.opts.width||n(e).attr("width"),t.opts.height=t.opts.height||n(e).attr("height")),t.$content=t.$slide.children().filter("div,form,main,video,audio,article,.fancybox-content").first(),t.$content.siblings().hide(),t.$content.length||(t.$content=t.$slide.wrapInner("<div></div>").children().first()),t.$content.addClass("fancybox-content"),t.$slide.addClass("fancybox-slide--"+t.contentType),this.afterLoad(t))},setError:function(t){t.hasError=!0,t.$slide.trigger("onReset").removeClass("fancybox-slide--"+t.contentType).addClass("fancybox-slide--error"),t.contentType="html",this.setContent(t,this.translate(t,t.opts.errorTpl)),t.pos===this.currPos&&(this.isAnimating=!1)},showLoading:function(t){(t=t||this.current)&&!t.$spinner&&(t.$spinner=n(this.translate(this,this.opts.spinnerTpl)).appendTo(t.$slide).hide().fadeIn("fast"))},hideLoading:function(t){(t=t||this.current)&&t.$spinner&&(t.$spinner.stop().remove(),delete t.$spinner)},afterLoad:function(t){this.isClosing||(t.isLoading=!1,t.isLoaded=!0,this.trigger("afterLoad",t),this.hideLoading(t),!t.opts.smallBtn||t.$smallBtn&&t.$smallBtn.length||(t.$smallBtn=n(this.translate(t,t.opts.btnTpl.smallBtn)).appendTo(t.$content)),t.opts.protect&&t.$content&&!t.hasError&&(t.$content.on("contextmenu.fb",function(t){return 2==t.button&&t.preventDefault(),!0}),"image"===t.type&&n('<div class="fancybox-spaceball"></div>').appendTo(t.$content)),this.adjustCaption(t),this.adjustLayout(t),t.pos===this.currPos&&this.updateCursor(),this.revealContent(t))},adjustCaption:function(t){var e,n=t||this.current,o=n.opts.caption,i=n.opts.preventCaptionOverlap,s=this.$refs.caption,a=!1;s.toggleClass("fancybox-caption--separate",i),i&&o&&o.length&&(n.pos!==this.currPos?((e=s.clone().appendTo(s.parent())).children().eq(0).empty().html(o),a=e.outerHeight(!0),e.empty().remove()):this.$caption&&(a=this.$caption.outerHeight(!0)),n.$slide.css("padding-bottom",a||""))},adjustLayout:function(t){var e,n,o,i,s=t||this.current;s.isLoaded&&!0!==s.opts.disableLayoutFix&&(s.$content.css("margin-bottom",""),s.$content.outerHeight()>s.$slide.height()+.5&&(o=s.$slide[0].style["padding-bottom"],i=s.$slide.css("padding-bottom"),parseFloat(i)>0&&(e=s.$slide[0].scrollHeight,s.$slide.css("padding-bottom",0),Math.abs(e-s.$slide[0].scrollHeight)<1&&(n=i),s.$slide.css("padding-bottom",o))),s.$content.css("margin-bottom",n))},revealContent:function(t){var e,o,i,s,a=this,r=t.$slide,c=!1,l=!1,h=a.isMoved(t),d=t.isRevealed;return t.isRevealed=!0,e=t.opts[a.firstRun?"animationEffect":"transitionEffect"],i=t.opts[a.firstRun?"animationDuration":"transitionDuration"],i=parseInt(void 0===t.forcedDuration?i:t.forcedDuration,10),!h&&t.pos===a.currPos&&i||(e=!1),"zoom"===e&&(t.pos===a.currPos&&i&&"image"===t.type&&!t.hasError&&(l=a.getThumbPos(t))?c=a.getFitPos(t):e="fade"),"zoom"===e?(a.isAnimating=!0,c.scaleX=c.width/l.width,c.scaleY=c.height/l.height,"auto"==(s=t.opts.zoomOpacity)&&(s=Math.abs(t.width/t.height-l.width/l.height)>.1),s&&(l.opacity=.1,c.opacity=1),n.fancybox.setTranslate(t.$content.removeClass("fancybox-is-hidden"),l),f(t.$content),void n.fancybox.animate(t.$content,c,i,function(){a.isAnimating=!1,a.complete()})):(a.updateSlide(t),e?(n.fancybox.stop(r),o="fancybox-slide--"+(t.pos>=a.prevPos?"next":"previous")+" fancybox-animated fancybox-fx-"+e,r.addClass(o).removeClass("fancybox-slide--current"),t.$content.removeClass("fancybox-is-hidden"),f(r),"image"!==t.type&&t.$content.hide().show(0),void n.fancybox.animate(r,"fancybox-slide--current",i,function(){r.removeClass(o).css({transform:"",opacity:""}),t.pos===a.currPos&&a.complete()},!0)):(t.$content.removeClass("fancybox-is-hidden"),d||!h||"image"!==t.type||t.hasError||t.$content.hide().fadeIn("fast"),void(t.pos===a.currPos&&a.complete())))},getThumbPos:function(t){var o,i,s,a,r,c,l=t.$thumb;return!(!l||!function(t){var o,i;return!(!t||t.ownerDocument!==e)&&(n(".fancybox-container").css("pointer-events","none"),o={x:t.getBoundingClientRect().left+t.offsetWidth/2,y:t.getBoundingClientRect().top+t.offsetHeight/2},i=e.elementFromPoint(o.x,o.y)===t,n(".fancybox-container").css("pointer-events",""),i)}(l[0]))&&(i=n.fancybox.getTranslate(l),s=parseFloat(l.css("border-top-width")||0),a=parseFloat(l.css("border-right-width")||0),r=parseFloat(l.css("border-bottom-width")||0),c=parseFloat(l.css("border-left-width")||0),o={top:i.top+s,left:i.left+c,width:i.width-a-c,height:i.height-s-r,scaleX:1,scaleY:1},i.width>0&&i.height>0&&o)},complete:function(){var t,e=this,o=e.current,i={};!e.isMoved()&&o.isLoaded&&(o.isComplete||(o.isComplete=!0,o.$slide.siblings().trigger("onReset"),e.preload("inline"),f(o.$slide),o.$slide.addClass("fancybox-slide--complete"),n.each(e.slides,function(t,o){o.pos>=e.currPos-1&&o.pos<=e.currPos+1?i[o.pos]=o:o&&(n.fancybox.stop(o.$slide),o.$slide.off().remove())}),e.slides=i),e.isAnimating=!1,e.updateCursor(),e.trigger("afterShow"),o.opts.video.autoStart&&o.$slide.find("video,audio").filter(":visible:first").trigger("play").one("ended",function(){Document.exitFullscreen?Document.exitFullscreen():this.webkitExitFullscreen&&this.webkitExitFullscreen(),e.next()}),o.opts.autoFocus&&"html"===o.contentType&&((t=o.$content.find("input[autofocus]:enabled:visible:first")).length?t.trigger("focus"):e.focus(null,!0)),o.$slide.scrollTop(0).scrollLeft(0))},preload:function(t){var e,n;this.group.length<2||(n=this.slides[this.currPos+1],(e=this.slides[this.currPos-1])&&e.type===t&&this.loadSlide(e),n&&n.type===t&&this.loadSlide(n))},focus:function(t,o){var i,s,a=["a[href]","area[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden])","iframe","object","embed","video","audio","[contenteditable]",'[tabindex]:not
28([tabindex^="-"])'].join(",");this.isClosing||((i=(i=!t&&this.current&&this.current.isComplete?this.current.$slide.find("*:visible"+(o?":not(.fancybox-close-small)":"")):this.$refs.container.find("*:visible")).filter(a).filter(function(){return"hidden"!==n(this).css("visibility")&&!n(this).hasClass("disabled")})).length?(s=i.index(e.activeElement),t&&t.shiftKey?(s<0||0==s)&&(t.preventDefault(),i.eq(i.length-1).trigger("focus")):(s<0||s==i.length-1)&&(t&&t.preventDefault(),i.eq(0).trigger("focus"))):this.$refs.container.trigger("focus"))},activate:function(){var t=this;n(".fancybox-container").each(function(){var e=n(this).data("FancyBox");e&&e.id!==t.id&&!e.isClosing&&(e.trigger("onDeactivate"),e.removeEvents(),e.isVisible=!1)}),t.isVisible=!0,(t.current||t.isIdle)&&(t.update(),t.updateControls()),t.trigger("onActivate"),t.addEvents()},close:function(t,e){var o,i,s,a,r,c,l,d=this,u=d.current,p=function(){d.cleanUp(t)};return!d.isClosing&&(d.isClosing=!0,!1===d.trigger("beforeClose",t)?(d.isClosing=!1,h(function(){d.update()}),!1):(d.removeEvents(),s=u.$content,o=u.opts.animationEffect,i=n.isNumeric(e)?e:o?u.opts.animationDuration:0,u.$slide.removeClass("fancybox-slide--complete fancybox-slide--next fancybox-slide--previous fancybox-animated"),!0!==t?n.fancybox.stop(u.$slide):o=!1,u.$slide.siblings().trigger("onReset").remove(),i&&d.$refs.container.removeClass("fancybox-is-open").addClass("fancybox-is-closing").css("transition-duration",i+"ms"),d.hideLoading(u),d.hideControls(!0),d.updateCursor(),"zoom"!==o||s&&i&&"image"===u.type&&!d.isMoved()&&!u.hasError&&(l=d.getThumbPos(u))||(o="fade"),"zoom"===o?(n.fancybox.stop(s),c={top:(a=n.fancybox.getTranslate(s)).top,left:a.left,scaleX:a.width/l.width,scaleY:a.height/l.height,width:l.width,height:l.height},"auto"==(r=u.opts.zoomOpacity)&&(r=Math.abs(u.width/u.height-l.width/l.height)>.1),r&&(l.opacity=0),n.fancybox.setTranslate(s,c),f(s),n.fancybox.animate(s,l,i,p),!0):(o&&i?n.fancybox.animate(u.$slide.addClass("fancybox-slide--previous").removeClass("fancybox-slide--current"),"fancybox-animated fancybox-fx-"+o,i,p):!0===t?setTimeout(p,i):p(),!0)))},cleanUp:function(e){var o,i,s,a=this.current.opts.$orig;this.current.$slide.trigger("onReset"),this.$refs.container.empty().remove(),this.trigger("afterClose",e),this.current.opts.backFocus&&(a&&a.length&&a.is(":visible")||(a=this.$trigger),a&&a.length&&(i=t.scrollX,s=t.scrollY,a.trigger("focus"),n("html, body").scrollTop(s).scrollLeft(i))),this.current=null,(o=n.fancybox.getInstance())?o.activate():(n("body").removeClass("fancybox-active compensate-for-scrollbar"),n("#fancybox-style-noscroll").remove())},trigger:function(t,e){var o,i=Array.prototype.slice.call(arguments,1),s=e&&e.opts?e:this.current;if(s?i.unshift(s):s=this,i.unshift(this),n.isFunction(s.opts[t])&&(o=s.opts[t].apply(s,i)),!1===o)return o;"afterClose"!==t&&this.$refs?this.$refs.container.trigger(t+".fb",i):c.trigger(t+".fb",i)},updateControls:function(){var t=this.current,o=t.index,i=this.$refs.container,s=this.$refs.caption,a=t.opts.caption;t.$slide.trigger("refresh"),a&&a.length?(this.$caption=s,s.children().eq(0).html(a)):this.$caption=null,this.hasHiddenControls||this.isIdle||this.showControls(),i.find("[data-fancybox-count]").html(this.group.length),i.find("[data-fancybox-index]").html(o+1),i.find("[data-fancybox-prev]").prop("disabled",!t.opts.loop&&o<=0),i.find("[data-fancybox-next]").prop("disabled",!t.opts.loop&&o>=this.group.length-1),"image"===t.type?i.find("[data-fancybox-zoom]").show().end().find("[data-fancybox-download]").attr("href",t.opts.image.src||t.src).show():t.opts.toolbar&&i.find("[data-fancybox-download],[data-fancybox-zoom]").hide(),n(e.activeElement).is(":hidden,[disabled]")&&this.$refs.container.trigger("focus")},hideControls:function(t){var e=["infobar","toolbar","nav"];!t&&this.current.opts.preventCaptionOverlap||e.push("caption"),this.$refs.container.removeClass(e.map(function(t){return"fancybox-show-"+t}).join(" ")),this.hasHiddenControls=!0},showControls:function(){var t=this.current?this.current.opts:this.opts,e=this.$refs.container;
28this.hasHiddenControls=!1,this.idleSecondsCounter=0,e.toggleClass("fancybox-show-toolbar",!(!t.toolbar||!t.buttons)).toggleClass("fancybox-show-infobar",!!(t.infobar&&this.group.length>1)).toggleClass("fancybox-show-caption",!!this.$caption).toggleClass("fancybox-show-nav",!!(t.arrows&&this.group.length>1)).toggleClass("fancybox-is-modal",!!t.modal)},toggleControls:function(){this.hasHiddenControls?this.showControls():this.hideControls()}}),n.fancybox={version:"3.5.7",defaults:a,getInstance:function(t){var e=n('.fancybox-container:not(".fancybox-is-closing"):last').data("FancyBox"),o=Array.prototype.slice.call(arguments,1);return e instanceof g&&("string"===n.type(t)?e[t].apply(e,o):"function"===n.type(t)&&t.apply(e,o),e)},open:function(t,e,n){return new g(t,e,n)},close:function(t){var e=this.getInstance();e&&(e.close(),!0===t&&this.close(t))},destroy:function(){this.close(!0),c.add("body").off("click.fb-start","**")},isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),use3d:(i=e.createElement("div"),t.getComputedStyle&&t.getComputedStyle(i)&&t.getComputedStyle(i).getPropertyValue("transform")&&!(e.documentMode&&e.documentMode<11)),getTranslate:function(t){var e;return!(!t||!t.length)&&{top:(e=t[0].getBoundingClientRect()).top||0,left
vendor: 5,745 bytes, line 28
28:e.left||0,width:e.width,height:e.height,opacity:parseFloat(t.css("opacity"))}},setTranslate:function(t,e){var n="",o={};if(t&&e)return void 0===e.left&&void 0===e.top||(n=(void 0===e.left?t.position().left:e.left)+"px, "+(void 0===e.top?t.position().top:e.top)+"px",n=this.use3d?"translate3d("+n+", 0px)":"translate("+n+")"),void 0!==e.scaleX&&void 0!==e.scaleY?n+=" scale("+e.scaleX+", "+e.scaleY+")":void 0!==e.scaleX&&(n+=" scaleX("+e.scaleX+")"),n.length&&(o.transform=n),void 0!==e.opacity&&(o.opacity=e.opacity),void 0!==e.width&&(o.width=e.width),void 0!==e.height&&(o.height=e.height),t.css(o)},animate:function(t,e,o,i,s){var a,r=this;n.isFunction(o)&&(i=o,o=null),r.stop(t),a=r.getTranslate(t),t.on(u,function(c){(!c||!c.originalEvent||t.is(c.originalEvent.target)&&"z-index"!=c.originalEvent.propertyName)&&(r.stop(t),n.isNumeric(o)&&t.css("transition-duration",""),n.isPlainObject(e)?void 0!==e.scaleX&&void 0!==e.scaleY&&r.setTranslate(t,{top:e.top,left:e.left,width:a.width*e.scaleX,height:a.height*e.scaleY,scaleX:1,scaleY:1}):!0!==s&&t.removeClass(e),n.isFunction(i)&&i(c))}),n.isNumeric(o)&&t.css("transition-duration",o+"ms"),n.isPlainObject(e)?(void 0!==e.scaleX&&void 0!==e.scaleY&&(delete e.width,delete e.height,t.parent().hasClass("fancybox-slide--image")&&t.parent().addClass("fancybox-is-scaling")),n.fancybox.setTranslate(t,e)):t.addClass(e),t.data("timer",setTimeout(function(){t.trigger(u)},o+33))},stop:function(t,e){t&&t.length&&(clearTimeout(t.data("timer")),e&&t.trigger(u),t.off(u).css("transition-duration",""),t.parent().removeClass("fancybox-is-scaling"))}},n.fn.fancybox=function(t){var e;return(e=(t=t||{}).selector||!1)?n("body").off("click.fb-start",e).on("click.fb-start",e,{options:t},b):this.off("click.fb-start").on("click.fb-start",{items:this,options:t},b),this},c.on("click.fb-start","[data-fancybox]",b),c.on("click.fb-start","[data-fancybox-trigger]",function(t){n('[data-fancybox="'+n(this).attr("data-fancybox-trigger")+'"]').eq(n(this).attr("data-fancybox-index")||0).trigger("click.fb-start",{$trigger:n(this)})}),s=null,c.on("mousedown mouseup focus blur",".fancybox-button",function(t){switch(t.type){case"mousedown":s=n(this);break;case"mouseup":s=null;break;case"focusin":n(".fancybox-button").removeClass("fancybox-focus"),n(this).is(s)||n(this).is("[disabled]")||n(this).addClass("fancybox-focus");break;case"focusout":n(".fancybox-button").removeClass("fancybox-focus")}})}function b(t,e){var o,i,s,a=[],r=0;t&&t.isDefaultPrevented()||(t.preventDefault(),e=e||{},t&&t.data&&(e=p(t.data.options,e)),o=e.$target||n(t.currentTarget).trigger("blur"),(s=n.fancybox.getInstance())&&s.$trigger&&s.$trigger.is(o)||(a=e.selector?n(e.selector):(i=o.attr("data-fancybox")||"")?(a=t.data?t.data.items:[]).length?a.filter('[data-fancybox="'+i+'"]'):n('[data-fancybox="'+i+'"]'):[o],(r=n(a).index(o))<0&&(r=0),(s=n.fancybox.open(a,e,r)).$trigger=o))}}(window,document,jQuery),function(t){"use strict";var e={youtube:{matcher:/(youtube\.com|youtu\.be|youtube\-nocookie\.com)\/(watch\?(.*&)?v=|v\/|u\/|embed\/?)?(videoseries\?list=(.*)|[\w-]{11}|\?listType=(.*)&list=(.*))(.*)/i,params:{autoplay:1,autohide:1,fs:1,rel:0,hd:1,wmode:"transparent",enablejsapi:1,html5:1},paramPlace:8,type:"iframe",url:"https://www.youtube-nocookie.com/embed/$4",thumb:"https://img.youtube.com/vi/$4/hqdefault.jpg"},vimeo:{matcher:/^.+vimeo.com\/(.*\/)?([\d]+)(.*)?/,params:{autoplay:1,hd:1,show_title:1,show_byline:1,show_portrait:0,fullscreen:1},paramPlace:3,type:"iframe",url:"//player.vimeo.com/video/$2"},rutube:{matcher:/^.+rutube.ru\/.*\/(.*\/)?([\w]+)(.*)\/?/,params:{frameBorder:0},paramPlace:1,type:"iframe",url:"//rutube.ru/play/embed/$2",thumb:"https://rutube.ru/api/video/$2/thumbnail/?redirect=1"},vk:{matcher:/^.+(vk.com).+video(?:\?z=video|)(-?\d+)_(\d+)/,params:{autoplay:1,hd:2,js_api:1,frameBorder:0},paramPlace:1,type:"iframe",url:"https://vk.com/video_ext.php?oid=$2&id=$3"},instagram:{matcher:/(instagr\.am|instagram\.com)\/p\/([a-zA-Z0-9_\-]+)\/?/i,type:"image",url:"//$1/p/$2/media/?size=l"},gmap_place:{matcher:/(maps\.)?google\.([a-z]{2,3}(\.[a-z]{2})?)\/(((maps\/(place\/(.*)\/)?\@(.*),(\d+.?\d+?)z))|(\?ll=))(.*)?/i,type:"iframe",url:function(t){return"//maps.google."+t[2]+"/?ll="+(t[9]?t[9]+"&z="+Math.floor(t[10])+(t[12]?t[12].replace(/^\//,"&"):""):t[12]+"").replace(/\?/,"&")+"&output="+(t[12]&&t[12].indexOf("layer=c")>0?"svembed":"embed")}},gmap_search:{matcher:/(maps\.)?google\.([a-z]{2,3}(\.[a-z]{2})?)\/(maps\/search\/)(.*)/i,type:"iframe",url:function(t){return"//maps.google."+t[2]+"/maps?q="+t[5].replace("query=","q=").replace("api=1","")+"&output=embed"}}},n=function(e,n,o){if(e)return o=o||"","object"===t.type(o)&&(o=t.param(o,!0)),t.each(n,function(t,n){e=e.replace("$"+t,n||"")}),o.length&&(e+=(e.indexOf("?")>0?"&":"?")+o),e};t(document).on("objectNeedsType.fb",function(o,i,s){var a,r,c,l,h,d,u,f=s.src||"",p=!1;a=t.extend(!0,{},e,s.opts.media),t.each(a,function(e,o){if(c=f.match(o.matcher)){if(p=o.type,u=e,d={},o.paramPlace&&c[o.paramPlace]){"?"==(h=c[o.paramPlace])[0]&&(h=h.substring(1)),h=h.split("&");for(var i=0;i<h.length;++i){var a=h[i].split("=",2);2==a.length&&(d[a[0]]=decodeURIComponent(a[1].replace(/\+/g," ")))}}return l=t.extend(!0,{},o.params,s.opts[e],d),f="function"===t.type(o.url)?o.url.call(this,c,l,s):n(o.url,c,l),r="function"===t.type(o.thumb)?o.thumb.call(this,c,l,s):n(o.thumb,c),"youtube"===e?f=f.replace(/&t=((\d+)m)?(\d+)s/,function(t,e,n,o){return"&start="+((n?60*parseInt(n,10):0)+parseInt(o,10))}):"vimeo"===e?f=f.replace("&%23","#"):"rutube"===e&&(f=f.replace("&%23","#")),!1}}),p?(s.opts.thumb||s.opts.$thumb&&s.opts.$thumb.length||(s.opts.thumb=r),"iframe"===p&&(s.opts=t.extend(!0,s.opts,{iframe:{preload:!1,attr:{scrolling:"no"}}}
28)),t.extend(s,{type:p,src:f,origSrc:s.src,contentSource:u,contentType:"image"===p?"image":"gmap_place"==u||"gmap_search"==u?"map":"video"})):f&&(s.type=s.opts.defaultType)});var o={youtube:{src:"https://www.youtube.com/iframe_api",class:"YT",loading:!1,loaded:!1},vimeo:{src:"https://player.vimeo.com/api/player.js",class:"Vimeo",loading:!1,loaded:!1},rutube:{src:"https://static.rutube.ru/static/player_sdk/hls.min.js",class:"Rutube",loading:!1,loaded:!1},vk:{src:"https://vk.com/js/api/videoplayer.js",class:"VK",loading:!1,loaded:!1},load:function(t){var e,n=this;this[t].loaded?setTimeout(function(){n.done(t)}):this[t].loading||(this[t].loading=!0,(e=document.createElement("script")).type="text/javascript",e.src=this[t].src,"youtube"===t?window.onYouTubeIframeAPIReady=function(){n[t].loaded=!0,n.done(t)}:e.onload=function(){n[t].loaded=!0,n.done(t)},document.body.appendChild(e))},done:function(e){var n,o;"youtube"===e&&delete window.onYouTubeIframeAPIReady,(n=t.fancybox.getInstance())&&(o=n.current.$content.find("iframe"),"youtube"===e&&void 0!==YT&&YT?new YT.Player(o.attr("id"),{events:{onStateChange:function(t){0==t.data&&n.next()}}}):"vimeo"===e&&void 0!==Vimeo&&Vimeo&&new Vimeo.Player(o).on("ended",function(){n.next()}))}};t(document).on({"afterShow.fb":function(t,e,n){e.group.length>1&&("youtube"===n.contentSource||"vimeo"===n.contentSource||"rutube"===n.contentSource||"vk"===n.contentSource)&&o.load(n.contentSource)}})}(jQuery),function(t,e,n){"use strict";var o=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||function(e){return t.setTimeout(e,1e3/60)},i=t.cancelAnimationFrame||t.webkitCancelAnimationFrame||t.mozCancelAnimationFrame||t.oCancelAnimationFrame||function(e){t.clearTimeout(e)},s=function(e){var n=[];for(var o in e=(e=e.originalEvent||e||t.e).touches&&e.touches.length?e.touches:e.changedTouches&&e.changedTouches.length?e.changedTouches:[e])e[o].pageX?n.push({x:e[o].pageX,y:e[o].pageY}):e[o].clientX&&n.push({x:e[o].clientX,y:e[o].clientY});return n},a=function(t,e,n){return e&&t?"x"===n?t.x-e.x:"y"===n?t.y-e.y:Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)):0},r=function(t){if(t.is('a,area,button,[role="button"],input,label,select,summary,textarea,video,audio,iframe')||n.isFunction(t.get(0).onclick)||t.data("selectable"))return!0;for(var e=0,o=t[0].attributes,i=o.length;e<i;e++)if("data-fancybox-"===o[e].nodeName.substr(0,14))return!0;return!1},c=function(e){for(var n,o,i,s,a,r=!1;n=e.get(0),o=void 0,i=void 0,s=void 0,a=void 0,o=t.getComputedStyle(n)["overflow-y"],i=t.getComputedStyle(n)["overflow-x"],s=("scroll"===o||"auto"===o)&&n.scrollHeight>n.clientHeight,a=("scroll"===i||"auto"===i)&&n.scrollWidth>n.clientWidth,!(r=s||a)&&(e=e.parent()).length&&!e.hasClass("fancybox-stage")&&!e.is("body"););return r},l=function(t){this.instance=t,this.$bg=t.$refs.bg,this.$stage=t.$refs.stage,this.$container=t.$refs.container,this.destroy(),this.$container.on("touchstart.fb.touch mousedown.fb.touch",n.proxy(this,"ontouchstart"))};l.prototype.destroy=function(){this.$container.off(".fb.touch"),n(e).off(".fb.touch"),this.requestId&&(i(this.requestId),this.requestId=null),this.tapped&&(clearTimeout(this.tapped),this.tapped=null)},l.prototype.ontouchstart=function(o){var i=n(o.target),l=this.instance,h=l.current,d=h.$slide,u=h.$content,f="touchstart"==o.type;if(f&&this.$container.off("mousedown.fb.touch"),(!o.originalEvent||2!=o.originalEvent.button)&&d.length&&i.length&&!r(i)&&!r(i.parent())&&(i.is("img")||!(o.originalEvent.clientX>i[0].clientWidth+i.offset().left))){if(!h||l.isAnimating||h.$slide.hasClass("fancybox-animated"))return o.stopPropagation(),void o.preventDefault();this.realPoints=this.startPoints=s(o),this.startPoints.length&&(h.touch&&o.stopPropagation(),this.startEvent=o,this.canTap=!0,this.$target=i,this.$content=u,this.opts=h.opts.touch,this.isPanning=!1,this.isSwiping=!1,this.isZooming=!1,this.isScrolling=!1,this.canPan=l.canPan(),this.startTime=(new Date).getTime(),this.distanceX=this.distanceY=this.distance=0,this.canvasWidth=Math.round(d[0].clientWidth),this.canvasHeight=Math.round(d[0].clientHeight),this.contentLastPos=null,this.contentStartPos=n.fancybox.getTranslate(this.$content)||{top:0,left:0},this.sliderStartPos=n.fancybox.getTranslate(d),this.stagePos=n.fancybox.getTranslate(l.$refs.stage),this.sliderStartPos.top-=this.stagePos.top,this.sliderStartPos.left-=this.stagePos.left,this.contentStartPos.top-=this.stagePos.top,this.contentStartPos.left-=this.stagePos.left,n(e).off(".fb.touch").on(f?"touchend.fb.touch touchcancel.fb.touch":"mouseup.fb.touch mouseleave.fb.touch",n.proxy(this,"ontouchend")).on(f?"touchmove.fb.touch":"mousemove.fb.touch",n.proxy(this,"ontouchmove")),n.fancybox.isMobile&&e.addEventListener("scroll",this.onscroll,!0),((this.opts||this.canPan)&&(i.is(this.$stage)||this.$stage.find(i).length)||(i.is(".fancybox-image")&&o.preventDefault(),n.fancybox.isMobile&&i.parents(".fancybox-caption").length))&&(this.isScrollable=c(i)||c(i.parent()),n.fancybox.isMobile&&this.isScrollable||o.preventDefault(),(1===this.startPoints.length||h.hasError)&&(this.canPan?(n.fancybox.stop(this.$content),this.isPanning=!0):this.isSwiping=!0,this.$container.addClass("fancybox-is-grabbing")),2===this.startPoints.length&&"image"===h.type&&(h.isLoaded||h.$ghost)&&(this.canTap=!1,this.isSwiping=!1,this.isPanning=!1,this.isZooming=!0,n.fancybox.stop(this.$content),this.centerPointStartX=.5*(this.startPoints[0].x+this.startPoints[1].x)-n(t).scrollLeft(),this.centerPointStartY=.5*(this.startPoints[0].y+this.startPoints[1].y)-n(t).scrollTop(),this.percentageOfImageAtPinchPointX=(this.centerPointStartX-this.contentStartPos.left)/this.contentStartPos.width,this.percentageOfImageAtPinchPointY=(this.centerPointStartY-this.contentStartPos.top)/this.contentStartPos.height,this.startDistanceBetweenFingers=a(this.startPoints[0],this.startPoints[1]))))}},l.prototype.onscroll=function(t){this.isScrolling=!0,e.removeEventListener("scroll",this.onscroll,!0)},l.prototype.ontouchmove=function(t){void 0===t.originalEvent.buttons||0!==t.originalEvent.buttons?this.isScrolling?this.canTap=!1:(this.newPoints=s(t),(this.opts||this.canPan)&&this.newPoints.length&&this.newPoints.length&&(this.isSwiping&&!0===this.isSwiping||t.preventDefault(),this.distanceX=a(this.newPoints[0],this.startPoints[0],"x"),this.distanceY=a(this.newPoints[0],this.startPoints[0],"y"),this.distance=a(this.newPoints[0],this.startPoints[0]),this.distance>0&&(this.isSwiping?this.onSwipe(t):this.isPanning?this.onPan():this.isZooming&&this.onZoom()))):this.ontouchend(t)},l.prototype.onSwipe=function(e){var s,a=this,r=a.instance,c=a.isSwiping,l=a.sliderStartPos.left||0;if(!0!==c)"x"==c&&(a.distanceX>0&&(a.instance.group.length<2||0===a.instance.current.index&&!a.instance.current.opts.loop)?l+=Math.pow(a.distanceX,.8):a.distanceX<0&&(a.instance.group.length<2||a.instance.current.index===a.instance.group.length-1&&!a.instance.current.opts.loop)?l-=Math.pow(-a.distanceX,.8):l+=a.distanceX),a.sliderLastPos={top:"x"==c?0:a.sliderStartPos.top+a.distanceY,left:l},a.requestId&&(i(a.requestId),a.requestId=null),a.requestId=o(function(){a.sliderLastPos&&(n.each(a.instance.slides,function(t,e){var o=e.pos-a.instance.currPos;
28n.fancybox.setTranslate(e.$slide,{top:a.sliderLastPos.top,left:a.sliderLastPos.left+o*a.canvasWidth+o*e.opts.gutter})}),a.$container.addClass("fancybox-is-sliding"))});else if(Math.abs(a.distance)>10){if(a.canTap=!1,r.group.length<2&&a.opts.vertical?a.isSwiping="y":r.isDragging||!1===a.opts.vertical||"auto"===a.opts.vertical&&n(t).width()>800?a.isSwiping="x":(s=Math.abs(180*Math.atan2(a.distanceY,a.distanceX)/Math.PI),a.isSwiping=s>45&&s<135?"y":"x"),"y"===a.isSwiping&&n.fancybox.isMobile&&a.isScrollable)return void(a.isScrolling=!0);r.isDragging=a.isSwiping,a.startPoints=a.newPoints,n.each(r.slides,function(t,e){var o,i;n.fancybox.stop(e.$slide),o=n.fancybox.getTranslate(e.$slide),i=n.fancybox.getTranslate(r.$refs.stage),e.$slide.css({transform:"",opacity:"","transition-duration":""}).removeClass("fancybox-animated").removeClass(function(t,e){return(e.match(/(^|\s)fancybox-fx-\S+/g)||[]).join(" ")}),e.pos===r.current.pos&&(a.sliderStartPos.top=o.top-i.top,a.sliderStartPos.left=o.left-i.left),n.fancybox.setTranslate(e.$slide,{top:o.top-i.top,left:o.left-i.left})}),r.SlideShow&&r.SlideShow.isActive&&r.SlideShow.stop()}},l.prototype.onPan=function(){var t=this;a(t.newPoints[0],t.realPoints[0])<(n.fancybox.isMobile?10:5)?t.startPoints=t.newPoints:(t.canTap=!1,t.contentLastPos=t.limitMovement(),t.requestId&&i(t.requestId),t.requestId=o(function(){n.fancybox.setTranslate(t.$content,t.contentLastPos)}))},l.prototype.limitMovement=function(){var t,e,n,o,i,s,a=this.canvasWidth,r=this.canvasHeight,c=this.distanceX,l=this.distanceY,h=this.contentStartPos,d=h.left,u=h.top,f=h.width,p=h.height;return i=f>a?d+c:d,s=u+l,t=Math.max(0,.5*a-.5*f),e=Math.max(0,.5*r-.5*p),n=Math.min(a-f,.5*a-.5*f),o=Math.min(r-p,.5*r-.5*p),c>0&&i>t&&(i=t-1+Math.pow(-t+d+c,.8)||0),c<0&&i<n&&(i=n+1-Math.pow(n-d-c,.8)||0),l>0&&s>e&&(s=e-1+Math.pow(-e+u+l,.8)||0),l<0&&s<o&&(s=o+1-Math.pow(o-u-l,.8)||0),{top:s,left:i}},l.prototype.limitPosition=function(t,e,n,o){var i=this.canvasWidth,s=this.canvasHeight;return t=n>i?(t=t>0?0:t)<i-n?i-n:t:Math.max(0,i/2-n/2),{top:e=o>s?(e=e>0?0:e)<s-o?s-o:e:Math.max(0,s/2-o/2),left:t}},l.prototype.onZoom=function(){var e=this,s=e.contentStartPos,r=s.width,c=s.height,l=s.left,h=s.top,d=a(e.newPoints[0],e.newPoints[1])/e.startDistanceBetweenFingers,u=Math.floor(r*d),f=Math.floor(c*d),p=(r-u)*e.percentageOfImageAtPinchPointX,g=(c-f)*e.percentageOfImageAtPinchPointY,b=(e.newPoints[0].x+e.newPoints[1].x)/2-n(t).scrollLeft(),m=(e.newPoints[0].y+e.newPoints[1].y)/2-n(t).scrollTop(),v=b-e.centerPointStartX,y={top:h+(g+(m-e.centerPointStartY)),left:l+(p+v),scaleX:d,scaleY:d};e.canTap=!1,e.newWidth=u,e.newHeight=f,e.contentLastPos=y,e.requestId&&i(e.requestId),e.requestId=o(function(){n.fancybox.setTranslate(e.$content,e.contentLastPos)})},l.prototype.ontouchend=function(t){var o=this.isSwiping,a=this.isPanning,r=this.isZooming,c=this.isScrolling;if(this.endPoints=s(t),this.dMs=Math.max((new Date).getTime()-this.startTime,1),this.$container.removeClass("fancybox-is-grabbing"),n(e).off(".fb.touch"),e.removeEventListener("scroll",this.onscroll,!0),this.requestId&&(i(this.requestId),this.requestId=null),this.isSwiping=!1,this.isPanning=!1,this.isZooming=!1,this.isScrolling=!1,this.instance.isDragging=!1,this.canTap)return this.onTap(t);this.speed=100,this.velocityX=this.distanceX/this.dMs*.5,this.velocityY=this.distanceY/this.dMs*.5,a?this.endPanning():r?this.endZooming():this.endSwiping(o,c)},l.prototype.endSwiping=function(t,e){var o=!1,i=this.instance.group.length,s=Math.abs(this.distanceX),a="x"==t&&i>1&&(this.dMs>130&&s>10||s>50);this.sliderLastPos=null,"y"==t&&!e&&Math.abs(this.distanceY)>50?(n.fancybox.animate(this.instance.current.$slide,{top:this.sliderStartPos.top+this.distanceY+150*this.velocityY,opacity:0},200),o=this.instance.close(!0,250)):a&&this.distanceX>0?o=this.instance.previous(300):a&&this.distanceX<0&&(o=this.instance.next(300)),!1!==o||"x"!=t&&"y"!=t||this.instance.centerSlide(200),this.$container.removeClass("fancybox-is-sliding")},l.prototype.endPanning=function(){var t,e,o;this.contentLastPos&&(!1===this.opts.momentum||this.dMs>350?(t=this.contentLastPos.left,e=this.contentLastPos.top):(t=this.contentLastPos.left+500*this.velocityX,e=this.contentLastPos.top+500*this.velocityY),(o=this.limitPosition(t,e,this.contentStartPos.width,this.contentStartPos.height)).width=this.contentStartPos.width,o.height=this.contentStartPos.height,n.fancybox.animate(this.$content,o,366))},l.prototype.endZooming=function(){var t,e,o,i,s=this.instance.current,a=this.newWidth,r=this.newHeight;this.contentLastPos&&(t=this.contentLastPos.left,i={top:e=this.contentLastPos.top,left
28:t,width:a,height:r,scaleX:1,scaleY:1},n.fancybox.setTranslate(this.$content,i),a<this.canvasWidth&&r<this.canvasHeight?this.instance.scaleToFit(150):a>s.width||r>s.height?this.instance.scaleToActual(this.centerPointStartX,this.centerPointStartY,150):(o=this.limitPosition(t,e,a,r),n.fancybox.animate(this.$content,o,150)))},l.prototype.onTap=function(e){var o,i=this,a=n(e.target),r=i.instance,c=r.current,l=e&&s(e)||i.startPoints,h=l[0]?l[0].x-n(t).scrollLeft()-i.stagePos.left:0,d=l[0]?l[0].y-n(t).scrollTop()-i.stagePos.top:0,u=function(t){var o=c.opts[t];if(n.isFunction(o)&&(o=o.apply(r,[c,e])),o)switch(o){case"close":r.close(i.startEvent);break;case"toggleControls":r.toggleControls();break;case"next":r.next();break;case"nextOrClose":r.group.length>1?r.next():r.close(i.startEvent);break;case"zoom":"image"==c.type&&(c.isLoaded||c.$ghost)&&(r.canPan()?r.scaleToFit():r.isScaledDown()?r.scaleToActual(h,d):r.group.length<2&&r.close(i.startEvent))}};if((!e.originalEvent||2!=e.originalEvent.button)&&(a.is("img")||!(h>a[0].clientWidth+a.offset().left))){if(a.is(".fancybox-bg,.fancybox-inner,.fancybox-outer,.fancybox-container"))o="Outside";else if(a.is(".fancybox-slide"))o="Slide";else{if(!r.current.$content||!r.current.$content.find(a).addBack().filter(a).length)return;o="Content"}if(i.tapped){if(clearTimeout(i.tapped),i.tapped=null,Math.abs(h-i.tapX)>50||Math.abs(d-i.tapY)>50)return this;u("dblclick"+o)}else i.tapX=h,i.tapY=d,c.opts["dblclick"+o]&&c.opts["dblclick"+o]!==c.opts["click"+o]?i.tapped=setTimeout(function(){i.tapped=null,r.isAnimating||u("click"+o)},500):u("click"+o);return this}},n(e).on("onActivate.fb",function(t,e){e&&!e.Guestures&&(e.Guestures=new l(e))}).on("beforeClose.fb",function(t,e){e&&e.Guestures&&e.Guestures.destroy()})}(window,document,jQuery),function(t,e){"use strict";e.extend(!0,e.fancybox.defaults,{btnTpl:{slideShow:'<button data-fancybox-play class="fancybox-button fancybox-button--play" title="{{PLAY_START}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M6.5 5.4v13.2l11-6.6z"/></svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M8.33 5.75h2.2v12.5h-2.2V5.75zm5.15 0h2.2v12.5h-2.2V5.75z"/></svg></button>'},slideShow:{autoStart:!1,speed:3e3,progress:!0}});var n=function(t){this.instance=t,this.init()};e.extend(n.prototype,{timer:null,isActive:!1,$button:null,init:function(){var t=this,n=t.instance,o=n.group[n.currIndex].opts.slideShow;t.$button=n.$refs.toolbar.find("[data-fancybox-play]").on("click",function(){t.toggle()}),n.group.length<2||!o?t.$button.hide():o.progress&&(t.$progress=e('<div class="fancybox-progress"></div>').appendTo(n.$refs.inner))},set:function(t){var n=this.instance,o=n.current;o&&(!0===t||o.opts.loop||n.currIndex<n.group.length-1)?this.isActive&&"video"!==o.contentType&&(this.$progress&&e.fancybox.animate(this.$progress.show(),{scaleX:1},o.opts.slideShow.speed),this.timer=setTimeout(function(){n.current.opts.loop||n.current.index!=n.group.length-1?n.next():n.jumpTo(0)},o.opts.slideShow.speed)):(this.stop(),n.idleSecondsCounter=0,n.showControls())},clear:function(){clearTimeout(this.timer),this.timer=null,this.$progress&&this.$progress.removeAttr("style").hide()},start:function(){var t=this.instance.current;t&&(this.$button.attr("title",(t.opts.i18n[t.opts.lang]||t.opts.i18n.en).PLAY_STOP).removeClass("fancybox-button--play").addClass("fancybox-button--pause"),this.isActive=!0,t.isComplete&&this.set(!0),this.instance.trigger("onSlideShowChange",!0))},stop:function(){var t=this.instance.current;this.clear(),this.$button.attr("title",(t.opts.i18n[t.opts.lang]||t.opts.i18n.en).PLAY_START).removeClass("fancybox-button--pause").addClass("fancybox-button--play"),this.isActive=!1,this.instance.trigger("onSlideShowChange",!1),this.$progress&&this.$progress.removeAttr("style").hide()},toggle:function(){this.isActive?this.stop():this.start()}}),e(t).on({"onInit.fb":function(t,e){e&&!e.SlideShow&&(e.SlideShow=new n(e))},"beforeShow.fb":function(t,e,n,o){var i=e&&e.SlideShow;o?i&&n.opts.slideShow.autoStart&&i.start():i&&i.isActive&&i.clear()},"afterShow.fb":function(t,e,n){var o=e&&e.SlideShow;o&&o.isActive&&o.set()},"afterKeydown.fb":function(n,o,i,s,a){var r=o&&o.SlideShow;!r||!i.opts.slideShow||80!==a&&32!==a||e(t.activeElement).is("button,a,input")||(s.preventDefault(),r.toggle(
vendor: 4,124 bytes, line 28
28))},"beforeClose.fb onDeactivate.fb":function(t,e){var n=e&&e.SlideShow;n&&n.stop()}}),e(t).on("visibilitychange",function(){var n=e.fancybox.getInstance(),o=n&&n.SlideShow;o&&o.isActive&&(t.hidden?o.clear():o.set())})}(document,jQuery),function(t,e){"use strict";var n=function(){for(var e=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],n={},o=0;o<e.length;o++){var i=e[o];if(i&&i[1]in t){for(var s=0;s<i.length;s++)n[e[0][s]]=i[s];return n}}return!1}();if(n){var o={request:function(e){(e=e||t.documentElement)[n.requestFullscreen](e.ALLOW_KEYBOARD_INPUT)},exit:function(){t[n.exitFullscreen]()},toggle:function(e){e=e||t.documentElement,this.isFullscreen()?this.exit():this.request(e)},isFullscreen:function(){return Boolean(t[n.fullscreenElement])},enabled:function(){return Boolean(t[n.fullscreenEnabled])}};e.extend(!0,e.fancybox.defaults,{btnTpl:{fullScreen:'<button data-fancybox-fullscreen class="fancybox-button fancybox-button--fsenter" title="{{FULL_SCREEN}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"/></svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M5 16h3v3h2v-5H5zm3-8H5v2h5V5H8zm6 11h2v-3h3v-2h-5zm2-11V5h-2v5h5V8z"/></svg></button>'},fullScreen:{autoStart:!1}}),e(t).on(n.fullscreenchange,function(){var t=o.isFullscreen(),n=e.fancybox.getInstance();n&&(n.current&&"image"===n.current.type&&n.isAnimating&&(n.isAnimating=!1,n.update(!0,!0,0),n.isComplete||n.complete()),n.trigger("onFullscreenChange",t),n.$refs.container.toggleClass("fancybox-is-fullscreen",t),n.$refs.toolbar.find("[data-fancybox-fullscreen]").toggleClass("fancybox-button--fsenter",!t).toggleClass("fancybox-button--fsexit",t))})}e(t).on({"onInit.fb":function(t,e){n?e&&e.group[e.currIndex].opts.fullScreen?(e.$refs.container.on("click.fb-fullscreen","[data-fancybox-fullscreen]",function(t){t.stopPropagation(),t.preventDefault(),o.toggle()}),e.opts.fullScreen&&!0===e.opts.fullScreen.autoStart&&o.request(),e.FullScreen=o):e&&e.$refs.toolbar.find("[data-fancybox-fullscreen]").hide():e.$refs.toolbar.find("[data-fancybox-fullscreen]").remove()},"afterKeydown.fb":function(t,e,n,o,i){e&&e.FullScreen&&70===i&&(o.preventDefault(),e.FullScreen.toggle())},"beforeClose.fb":function(t,e){e&&e.FullScreen&&e.$refs.container.hasClass("fancybox-is-fullscreen")&&o.exit()}})}(document,jQuery),function(t,e){"use strict";var n="fancybox-thumbs";e.fancybox.defaults=e.extend(!0,{btnTpl:{thumbs:'<button data-fancybox-thumbs class="fancybox-button fancybox-button--thumbs" title="{{THUMBS}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M14.59 14.59h3.76v3.76h-3.76v-3.76zm-4.47 0h3.76v3.76h-3.76v-3.76zm-4.47 0h3.76v3.76H5.65v-3.76zm8.94-4.47h3.76v3.76h-3.76v-3.76zm-4.47 0h3.76v3.76h-3.76v-3.76zm-4.47 0h3.76v3.76H5.65v-3.76zm8.94-4.47h3.76v3.76h-3.76V5.65zm-4.47 0h3.76v3.76h-3.76V5.65zm-4.47 0h3.76v3.76H5.65V5.65z"/></svg></button>'},thumbs:{autoStart:!1,hideOnClose:!0,parentEl:".fancybox-container",axis:"y"}},e.fancybox.defaults);var o=function(t){this.init(t)};e.extend(o.prototype,{$button:null,$grid:null,$list:null,isVisible:!1,isActive:!1,init:function(t){var e=this,n=t.group,o=0;e.instance=t,e.opts=n[t.currIndex].opts.thumbs,t.Thumbs=e,e.$button=t.$refs.toolbar.find("[data-fancybox-thumbs]");for(var i=0,s=n.length;i<s&&(n[i].thumb&&o++,!(o>1));i++);o>1&&e.opts?(e.$button.removeAttr("style").on("click",function(){e.toggle(
28)}),e.isActive=!0):e.$button.hide()},create:function(){var t,o=this.instance,i=this.opts.parentEl,s=[];this.$grid||(this.$grid=e('<div class="'+n+" "+n+"-"+this.opts.axis+'"></div>').appendTo(o.$refs.container.find(i).addBack().filter(i)),this.$grid.on("click","a",function(){o.jumpTo(e(this).attr("data-index"))})),this.$list||(this.$list=e('<div class="'+n+'__list">').appendTo(this.$grid)),e.each(o.group,function(e,n){(t=n.thumb)||"image"!==n.type||(t=n.src),s.push('<a href="javascript:;" tabindex="0" data-index="'+e+'"'+(t&&t.length?' style="background-image:url('+t+')"':'class="fancybox-thumbs-missing"')+"></a>")}),this.$list[0].innerHTML=s.join(""),"x"===this.opts.axis&&this.$list.width(parseInt(this.$grid.css("padding-right"),10)+o.group.length*this.$list.children().eq(0).outerWidth(!0))},focus:function(t){var e,n,o=this.$list,i=this.$grid;this.instance.current&&(n=(e=o.children().removeClass("fancybox-thumbs-active").filter('[data-index="'+this.instance.current.index+'"]').addClass("fancybox-thumbs-active")).position(),"y"===this.opts.axis&&(n.top<0||n.top>o.height()-e.outerHeight())?o.stop().animate({scrollTop:o.scrollTop()+n.top},t):"x"===this.opts.axis&&(n.left<i.scrollLeft()||n.left>i.scrollLeft()+(i.width()-e.outerWidth()))&&o.parent().stop().animate({scrollLeft:n.left},t))},update:function(){this.instance.$refs.container.toggleClass("fancybox-show-thumbs",this.isVisible),this.isVisible?(this.$grid||this.create(),this.instance.trigger("onThumbsShow"),this.focus(0)):this.$grid&&this.instance.trigger("onThumbsHide"),this.instance.update()},hide:function(){this.isVisible=!1,this.update()},show:function(){this.isVisible=!0,this.update()},toggle:function(){this.isVisible=!this.isVisible,this.update()}}),e(t).on({"onInit.fb":function(t,e){var n;e&&!e.Thumbs&&(n=new o(e)).isActive&&!0===n.opts.autoStart&&n.show()},"beforeShow.fb":function(t,e,n,o){var i=e&&e.Thumbs;i&&i.isVisible&&i.focus(o?0:250)},"afterKeydown.fb":function(t,e,n,o,i){var s=e&&e.Thumbs;s&&s.isActive&&71===i&&(o.preventDefault(),s.toggle())},"beforeClose.fb":function(t,e){var n=e&&e.Thumbs;n&&n.isVisible&&!1!==n.opts.hideOnClose&&n.$grid.hide()}})}(document,jQuery),function(t,e,n){"use strict";function o(){var e=t.location.hash.substr(1),n=e.split("-"),o=n.length>1&&/^\+?\d+$/.test(n[n.length-1])&&parseInt(n.pop(-1),10)||1;return{hash:e,index:o<1?1:o,gallery:n.join("-")}}function i(t){""!==t.gallery&&n("[data-fancybox='"+n.escapeSelector(t.gallery)+"']").eq(t.index-1).focus().trigger("click.fb-start")}function s(t){var e,n;return!!t&&(""!==(n=(e=t.current?t.current.opts:t.opts).hash||(e.$orig?e.$orig.data("fancybox")||e.$orig.data("fancybox-trigger"):""))&&n)}n.escapeSelector||(n.escapeSelector=function(t){return(t+"").replace(/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g,function(t,e){return e?"\0"===t?"�":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t})}),n(function(){!1!==n.fancybox.defaults.hash&&(n(e).on({"onInit.fb":function(t,e){var n,i;!1!==e.group[e.currIndex].opts.hash&&(n=o(),(i=s(e))&&n.gallery&&i==n.gallery&&(e.currIndex=n.index-1))},"beforeShow.fb":function(n,o,i,a){var r;i&&!1!==i.opts.hash&&(r=s(o))&&(o.currentHash=r+(o.group.length>1?"-"+(i.index+1):""),t.location.hash!=="#"+o.currentHash&&(a&&!o.origHash&&(o.origHash=t.location.hash),o.hashTimer&&clearTimeout(o.hashTimer),o.hashTimer=setTimeout(function(){"replaceState"in t.history?(t.history[a?"pushState":"replaceState"]({},e.title,t.location.pathname+t.location.search+"#"+o.currentHash),a&&(o.hasCreatedHistory=!0)):t.location.hash=o.currentHash,o.hashTimer=null},300)))},"beforeClose.fb":function(n,o,i){i&&!1!==i.opts.hash&&(clearTimeout(o.hashTimer),o.currentHash&&o.hasCreatedHistory?t.history.back():o.currentHash&&("replaceState"in t.history?t.history.replaceState({},e.title,t.location.pathname+t.location.search+(o.origHash||"")):t.location.hash=o.origHash),o.currentHash=null)}}),n(t).on("hashchange.fb",function(){var t=o(),e=null;n.each(n(".fancybox-container").get().reverse(),function(t,o){var i=n(o).data("FancyBox");if(i&&i.currentHash)return e=i,!1}),e?e.currentHash===t.gallery+"-"+t.index||1===t.index&&e.currentHash==t.gallery||(e.currentHash=null,e.close()):""!==t.gallery&&i(t)}),setTimeout(function(){n.fancybox.getInstance()||i(o())},50))})}(window,document,jQuery),function(t,e){"use strict";var n=(new Date).getTime();e(t).on({"onInit.fb":function(t,e,o){e.$refs.stage.on("mousewheel DOMMouseScroll wheel MozMousePixelScroll",function(t){var o=e.current,i=(new Date).getTime();e.group.length<2||!1===o.opts.wheel||"auto"===o.opts.wheel&&"image"!==o.type||(t.preventDefault(),t.stopPropagation(),o.$slide.hasClass("fancybox-animated")||(t=t.originalEvent||t,i-n<250||(n=i,e[(-t.deltaY||-t.deltaX||t.wheelDelta||-t.detail)<0?"next":"previous"]())))})}})}(document,jQuery);
29/* End */
30;
31; /* Start:"a:4:{s:4:"full";s:75:"/local/templates/gvozdevsoft_profigs_s1/lib/flmenu/flmenu.js?17382743683602";s:6:"source";s:60:"/local/templates/gvozdevsoft_profigs_s1/lib/flmenu/flmenu.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
32var minwidth=769;
33var flgmini=false;
34window.onresize = CheckLis;
35
36jQuery(document).ready(function() {
37	var lastli = "<li id='fllast'><a>. . .</a><ul></ul></li>";
38	jQuery("#flvmenu > ul").append(lastli);
39	jQuery("#flvmenu").prepend("<div class='minmenu'><i class='fa fa-bars'></i><a>&#1052;&#1045;&#1053;&#1070;</a></div>");
40	jQuery("#flvmenu > ul li ul").before("<a class='flarr'></a>");
41	//scrwdth=scrlbarWidth();
42	CheckLis();
43	Setmini();
44});
45
46function CheckLis() {
47	var navw;
48	var lastli;
49	var allw=0;
50	var navItems;
51	var wdoc=window.innerWidth;
52
53	if(wdoc > minwidth) {
54		lastli = jQuery("#fllast").width();
55		var fllastlng = jQuery("#fllast > ul > li").length;
56		if(fllastlng == 0) lastli = 0;
57		navw = jQuery("#flvmenu").width();
58		jQuery('#flvmenu > ul > li').last().before(jQuery("#fllast > ul > li"));
59		jQuery("#flvmenu > ul > li:not(#fllast)").each(function() { allw += this.clientWidth; });
60		navItems = jQuery('#flvmenu > ul > li:not(#fllast)');
61		if(fllastlng == 1 && allw <= navw) lastli = 0;
62
63		while((allw+lastli) > navw) {
64			allw -= navItems.last().width();
65			navItems.last().prependTo('#fllast > ul');
66			navItems.splice(-1,1);
67			if(fllastlng == 0) lastli = jQuery("#fllast").width();
68		}
69		jQuery("#fllast").css("display","none");
70		if(jQuery("#fllast > ul > li").length > 0) jQuery("#fllast").css("display","inline-block");
71		jQuery(".flarr").html("");
72		jQuery('#flvmenu > ul > li ul').css("height","auto");
73		jQuery("#flvmenu > ul").css("display","block");
74		SetAlignBl(wdoc);
75		if(flgmini) {flgmini = false; CheckLis();}
76	} else {
77		if(!flgmini) {
78			jQuery('#flvmenu > ul > li').last().before(jQuery("#fllast > ul > li"));
79			jQuery("#fllast").css("display","none");
80			jQuery('#flvmenu > ul > li ul').css("height","0").css("right","auto").css("left","auto");
81			jQuery(".flarr").html("<i class='fa fa-plus'></i>");
82			jQuery("#flvmenu > ul").css("display","none");
83			flgmini = true;
84		}
85	}
86}
87
88function Setmini() {
89	jQuery(".flarr").click(function() {
90		var wdoc=document.documentElement.clientWidth;
91		if(minwidth > wdoc) {
92			var par = this.parentElement;
93			var chldul = par.getElementsByTagName('ul')[0];
94			var chght = chldul.style.height; 
95			if(chght == "0px") {
96				jQuery(this).html("<i class='fa fa-minus'></i>");
97				chldul.style.height = "auto";
98			} else {
99				jQuery(this).html("<i class='fa fa-plus'></i>");
100				chldul.style.height = "0px";
101			}
102		}
103	});
104	jQuery(".minmenu").click(function() {
105		var disp = jQuery("#flvmenu > ul").css("display");
106		if(disp == "block") jQuery("#flvmenu > ul").css("display","none");
107			else jQuery("#flvmenu > ul").css("display","block");
108	});
109}
110function SetAlignBl(wdoc){
111	jQuery("#flvmenu > ul > li > ul").each(
112		function(){
113			jQuery(this).css("left","0");
114			jQuery(this).css("right","auto");
115			var chldel = this.firstElementChild;
116			var chlwth=0;
117			if(chldel != null) chlwth = jQuery(chldel).width();
118			var setel = getLeftSet(this) + chlwth;
119			if(setel > wdoc) {
120				jQuery(this).css("left","auto");
121				jQuery(this).css("right","0");
122			}
123	});
124	jQuery("#flvmenu > ul > li > ul > li > ul").each(
125		function(){
126			jQuery(this).css("left","100%");
127			jQuery(this).css("right","auto");
128			var chldel = this.firstElementChild;
129			var chlwth=0;
130			if(chldel != null) chlwth = jQuery(chldel).width();
131			var setel = getLeftSet(this) + jQuery(this.parentElement).width() + chlwth;
132			if(setel > wdoc) jQuery(this).css("left","-100%");
133	});
134}
135function getLeftSet(elem) {
136    var left=0;
137    while(elem) {
138        left = left + parseFloat(elem.offsetLeft);
139        elem = elem.parentElement;
140    }
141	return Math.round(left);
142}
143/* End */
144;
145; /* Start:"a:4:{s:4:"full";s:82:"/local/templates/gvozdevsoft_profigs_s1/lib/sticky/jquery.sticky.js?17382743683836";s:6:"source";s:67:"/local/templates/gvozdevsoft_profigs_s1/lib/sticky/jquery.sticky.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
146/*
147 * Sticky Plugin v1.0.0 for jQuery
148 * Free to use and abuse under the MIT license.
149 */
150
151(function($) {
152  var defaults = {
153      topSpacing: 0,
154      bottomSpacing: 650,
155      className: 'is-sticky',
156      wrapperClassName: 'sticky-wrapper',
157      center: false,
158      getWidthFrom: ''
159    },
160    $window = $(window),
161    $document = $(document),
162    sticked = [],
163    windowHeight = $window.height(),
164    scroller = function() {
165      var scrollTop = $window.scrollTop(),
166        documentHeight = $document.height(),
167        dwh = documentHeight - windowHeight,
168        extra = (scrollTop > dwh) ? dwh - scrollTop : 0;
169
170      for (var i = 0; i < sticked.length; i++) {
171        var s = sticked[i],
172          elementTop = s.stickyWrapper.offset().top,
173          etse = elementTop - s.topSpacing - extra;
174
175        if (scrollTop <= etse) {
176          if (s.currentTop !== null) {
177            s.stickyElement
178			.css('position', '')
179              .css('top', '');
180            s.stickyElement.parent().removeClass(s.className);
181            s.currentTop = null;
182          }
183        }
184        else {
185          var newTop = documentHeight - s.stickyElement.outerHeight()
186            - s.topSpacing - s.bottomSpacing - scrollTop - extra;
187          if (newTop < 0) {
188            newTop = newTop + s.topSpacing;
189          } else {
190            newTop = s.topSpacing;
191          }
192          if (s.currentTop != newTop) {
193            s.stickyElement
194              .css('position', 'fixed')
195              .css('top', newTop);
196
197            if (typeof s.getWidthFrom !== 'undefined') {
198              s.stickyElement.css('width', $(s.getWidthFrom).width());
199            }
200
201            s.stickyElement.parent().addClass(s.className);
202            s.currentTop = newTop;
203          }
204        }
205      }
206    },
207    resizer = function() {
208      windowHeight = $window.height();
209    },
210    methods = {
211      init: function(options) {
212        var o = $.extend(defaults, options);
213        return this.each(function() {
214          var stickyElement = $(this);
215
216          var stickyId = stickyElement.attr('id');
217          var wrapper = $('<div></div>')
218            .attr('id', stickyId + '-sticky-wrapper')
219            .addClass(o.wrapperClassName);
220          stickyElement.wrapAll(wrapper);
221
222          if (o.center) {
223            stickyElement.parent().css({width:stickyElement.outerWidth(),marginLeft:"auto",marginRight:"auto"});
224          }
225
226          if (stickyElement.css("float") == "right") {
227            stickyElement.css({"float":"none"}).parent().css({"float":"right"});
228          }
229
230          var stickyWrapper = stickyElement.parent();
231          stickyWrapper.css('height', stickyElement.outerHeight());
232          sticked.push({
233            topSpacing: o.topSpacing,
234            bottomSpacing: o.bottomSpacing,
235            stickyElement: stickyElement,
236            currentTop: null,
237            stickyWrapper: stickyWrapper,
238            className: o.className,
239            getWidthFrom: o.getWidthFrom
240          });
241        });
242      },
243      update: scroller
244    };
245
246  // should be more efficient than using $window.scroll(scroller) and $window.resize(resizer):
247  if (window.addEventListener) {
248    window.addEventListener('scroll', scroller, false);
249    window.addEventListener('resize', resizer, false);
250  } else if (window.attachEvent) {
251    window.attachEvent('onscroll', scroller);
252    window.attachEvent('onresize', resizer);
253  }
254
255  $.fn.sticky = function(method) {
256    if (methods[method]) {
257      return methods[method].apply(this, Array.prototype.slice.call(arguments, 1));
258    } else if (typeof method === 'object' || !method ) {
259      return methods.init.apply( this, arguments );
260    } else {
261      $.error('Method ' + method + ' does not exist on jQuery.sticky');
262    }
263  };
264  $(function() {
265    setTimeout(scroller, 0);
266  });
267})(jQuery);
268
269
270/* End */
271;
272; /* Start:"a:4:{s:4:"full";s:80:"/local/templates/gvozdevsoft_profigs_s1/lib/accordion/accordion.js?1738274368311";s:6:"source";s:66:"/local/templates/gvozdevsoft_profigs_s1/lib/accordion/accordion.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
273$(document).ready(function(i) {
274	var o, n;
275	i(".title_block").on("click", function() {
276		o = i(this).parents(".accordion_item"), 
277		n = o.find(".info"),
278		o.hasClass("active_block") ? (o.removeClass("active_block"),
279		n.slideUp()) : (o.addClass("active_block"), 
280		n.stop(!0, !0).slideDown())
281	})
282});
283
284/* End */
285;
286; /* Start:"a:4:{s:4:"full";s:70:"/local/templates/gvozdevsoft_profigs_s1/lib/tabs/tabs.js?1738274368751";s:6:"source";s:56:"/local/templates/gvozdevsoft_profigs_s1/lib/tabs/tabs.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
287$(document).ready(function() {
288	jQuery.fn.lightTabs = function(options){
289
290		var createTabs = function(){
291			var tabs = this;
292			var i = 0;
293
294			var showPage = function(i){
295				$(tabs).children("div").children("div").hide();
296				$(tabs).children("div").children("div").eq(i).show();
297				$(tabs).children("ul").children("li").removeClass("active");
298				$(tabs).children("ul").children("li").eq(i).addClass("active");
299			}
300
301			showPage(0);
302
303			$(tabs).children("ul").children("li").each(function(index, element){
304				$(element).attr("data-page", i);
305				i++;
306			});
307
308			$(tabs).children("ul").children("li").click(function(){
309				showPage(parseInt($(this).attr("data-page")));
310			});
311		};
312		return this.each(createTabs);
313	};
314});
315/* End */
316;
317; /* Start:"a:4:{s:4:"full";s:72:"/local/templates/gvozdevsoft_profigs_s1/lib/arrup/arrup.js?1738274368423";s:6:"source";s:58:"/local/templates/gvozdevsoft_profigs_s1/lib/arrup/arrup.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
318jQuery(document).ready(function() {
319	jQuery("body").append('<a id="arrup"><i class="fa fa-angle-up"></i></a>');
320	
321	jQuery(window).scroll(function(){
322		if (jQuery(this).scrollTop() > 200) {
323			jQuery('#arrup').addClass("arvis");
324		} else {
325			jQuery('#arrup').removeClass("arvis");
326		}
327	});
328	 
329	jQuery('#arrup').click(function(){
330		jQuery("html, body").animate({ scrollTop: 0 }, 800);
331		return false;
332	});
333});
334/* End */
335;
336; /* Start:"a:4:{s:4:"full";s:72:"/local/templates/gvozdevsoft_profigs_s1/lib/hdfix/hdfix.js?1738274368230";s:6:"source";s:58:"/local/templates/gvozdevsoft_profigs_s1/lib/hdfix/hdfix.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
337jQuery(document).ready(function() {
338	jQuery(window).scroll(function(){
339		if (jQuery(this).scrollTop() > 180) {
340			jQuery('.head_slide').css("top","0px");
341		} else {
342			jQuery('.head_slide').css("top","-50px");
343		}
344	});
345});
346/* End */
347;
348; /* Start:"a:4:{s:4:"full";s:78:"/local/templates/gvozdevsoft_profigs_s1/lib/img-zoom/img-zoom.js?1738274368220";s:6:"source";s:64:"/local/templates/gvozdevsoft_profigs_s1/lib/img-zoom/img-zoom.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
349$(document).ready(function(){
350	$(".img_zoom a").append("<span></span>");
351	$(".img_zoom a").hover(function(){
352		$(this).children("span").fadeIn(0);
353		},function(){
354		$(this).children("span").fadeOut(0);
355	});
356});			
357/* End */
358;
359; /* Start:"a:4:{s:4:"full";s:104:"/local/templates/gvozdevsoft_profigs_s1/lib/flex-gallery/jquery.justified-gallery.min.js?173827436818510";s:6:"source";s:88:"/local/templates/gvozdevsoft_profigs_s1/lib/flex-gallery/jquery.justified-gallery.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
360/*!
361 * justifiedGallery - v3.7.0
362 * http://miromannino.github.io/Justified-Gallery/
363 * Copyright (c) 2018 Miro Mannino
364 * Licensed under the MIT license.
365 */
366
367!function(e){"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof module&&module.exports?module.exports=function(t,i){return void 0===i&&(i="undefined"!=typeof window?require("jquery"):require("jquery")(t)),e(i),i}:e(jQuery)}(function(g){var r=function(t,i){this.settings=i,this.checkSettings(),this.imgAnalyzerTimeout=null,this.entries=null,this.buildingRow={entriesBuff:[],width:0,height:0,aspectRatio:0},this.lastFetchedEntry=null,this.lastAnalyzedIndex=-1,this.yield={every:2,flushed:0},this.border=0<=i.border?i.border:i.margins,this.maxRowHeight=this.retrieveMaxRowHeight(),this.suffixRanges=this.retrieveSuffixRanges(),this.offY=this.border,this.rows=0,this.spinner={phase:0,timeSlot:150,$el:g('<div class="spinner"><span></span><span></span><span></span></div>'),intervalId:null},this.scrollBarOn=!1,this.checkWidthIntervalId=null,this.galleryWidth=t.width(),this.$gallery=t};r.prototype.getSuffix=function(t,i){var e,s;for(e=i<t?t:i,s=0;s<this.suffixRanges.length;s++)if(e<=this.suffixRanges[s])return this.settings.sizeRangeSuffixes[this.suffixRanges[s]];return this.settings.sizeRangeSuffixes[this.suffixRanges[s-1]]},r.prototype.removeSuffix=function(t,i){return t.substring(0,t.length-i.length)},r.prototype.endsWith=function(t,i){return-1!==t.indexOf(i,t.length-i.length)},r.prototype.getUsedSuffix=function(t){for(var i in this.settings.sizeRangeSuffixes)if(this.settings.sizeRangeSuffixes.hasOwnProperty(i)){if(0===this.settings.sizeRangeSuffixes[i].length)continue;
vendor: 13,782 bytes, line 367
367if(this.endsWith(t,this.settings.sizeRangeSuffixes[i]))return this.settings.sizeRangeSuffixes[i]}return""},r.prototype.newSrc=function(t,i,e,s){var n;if(this.settings.thumbnailPath)n=this.settings.thumbnailPath(t,i,e,s);else{var r=t.match(this.settings.extension),o=null!==r?r[0]:"";n=t.replace(this.settings.extension,""),n=this.removeSuffix(n,this.getUsedSuffix(n)),n+=this.getSuffix(i,e)+o}return n},r.prototype.showImg=function(t,i){this.settings.cssAnimation?(t.addClass("entry-visible"),i&&i()):(t.stop().fadeTo(this.settings.imagesAnimationDuration,1,i),t.find(this.settings.imgSelector).stop().fadeTo(this.settings.imagesAnimationDuration,1,i))},r.prototype.extractImgSrcFromImage=function(t){var i=void 0!==t.data("safe-src")?t.data("safe-src"):t.attr("src");return t.data("jg.originalSrc",i),i},r.prototype.imgFromEntry=function(t){var i=t.find(this.settings.imgSelector);return 0===i.length?null:i},r.prototype.captionFromEntry=function(t){var i=t.find("> .caption");return 0===i.length?null:i},r.prototype.displayEntry=function(t,i,e,s,n,r){t.width(s),t.height(r),t.css("top",e),t.css("left",i);var o=this.imgFromEntry(t);if(null!==o){o.css("width",s),o.css("height",n),o.css("margin-left",-s/2),o.css("margin-top",-n/2);var a=o.attr("src"),h=this.newSrc(a,s,n,o[0]);o.one("error",function(){o.attr("src",o.data("jg.originalSrc"))});var l=function(){a!==h&&o.attr("src",h)};"skipped"===t.data("jg.loaded")?this.onImageEvent(a,g.proxy(function(){this.showImg(t,l),t.data("jg.loaded",!0)},this)):this.showImg(t,l)}else this.showImg(t);this.displayEntryCaption(t)},r.prototype.displayEntryCaption=function(t){var i=this.imgFromEntry(t);if(null!==i&&this.settings.captions){var e=this.captionFromEntry(t);if(null===e){var s=i.attr("alt");this.isValidCaption(s)||(s=t.attr("title")),this.isValidCaption(s)&&(e=g('<div class="caption">'+s+"</div>"),t.append(e),t.data("jg.createdCaption",!0))}null!==e&&(this.settings.cssAnimation||e.stop().fadeTo(0,this.settings.captionSettings.nonVisibleOpacity),this.addCaptionEventsHandlers(t))}else this.removeCaptionEventsHandlers(t)},r.prototype.isValidCaption=function(t){return void 0!==t&&0<t.length},r.prototype.onEntryMouseEnterForCaption=function(t){var i=this.captionFromEntry(g(t.currentTarget));this.settings.cssAnimation?i.addClass("caption-visible").removeClass("caption-hidden"):i.stop().fadeTo(this.settings.captionSettings.animationDuration,this.settings.captionSettings.visibleOpacity)},r.prototype.onEntryMouseLeaveForCaption=function(t){var i=this.captionFromEntry(g(t.currentTarget));this.settings.cssAnimation?i.removeClass("caption-visible").removeClass("caption-hidden"):i.stop().fadeTo(this.settings.captionSettings.animationDuration,this.settings.captionSettings.nonVisibleOpacity)},r.prototype.addCaptionEventsHandlers=function(t){var i=t.data("jg.captionMouseEvents");void 0===i&&(i={mouseenter:g.proxy(this.onEntryMouseEnterForCaption,this),mouseleave:g.proxy(this.onEntryMouseLeaveForCaption,this)},t.on("mouseenter",void 0,void 0,i.mouseenter),t.on("mouseleave",void 0,void 0,i.mouseleave),t.data("jg.captionMouseEvents",i))},r.prototype.removeCaptionEventsHandlers=function(t){var i=t.data("jg.captionMouseEvents");void 0!==i&&(t.off("mouseenter",void 0,i.mouseenter),t.off("mouseleave",void 0,i.mouseleave),t.removeData("jg.captionMouseEvents"))},r.prototype.clearBuildingRow=function(){this.buildingRow.entriesBuff=[],this.buildingRow.aspectRatio=0,this.buildingRow.width=0},r.prototype.prepareBuildingRow=function(t){var i,e,s,n,r,o=!0,a=0,h=this.galleryWidth-2*this.border-(this.buildingRow.entriesBuff.length-1)*this.settings.margins,l=h/this.buildingRow.aspectRatio,g=this.settings.rowHeight,u=this.buildingRow.width/h>this.settings.justifyThreshold;if(t&&"hide"===this.settings.lastRow&&!u){for(i=0;i<this.buildingRow.entriesBuff.length;i++)e=this.buildingRow.entriesBuff[i],this.settings.cssAnimation?e.removeClass("entry-visible"):(e.stop().fadeTo(0,.1),e.find("> img, > a > img").fadeTo(0,0));return-1}for(t&&!u&&"justify"!==this.settings.lastRow&&"hide"!==this.settings.lastRow&&(o=!1,0<this.rows&&(o=(g=(this.offY-this.border-this.settings.margins*this.rows)/this.rows)*this.buildingRow.aspectRatio/h>this.settings.justifyThreshold)),i=0;i<this.buildingRow.entriesBuff.length;i++)s=(e=this.buildingRow.entriesBuff[i]).data("jg.width")/e.data("jg.height"),o?(n=i===this.buildingRow.entriesBuff.length-1?h:l*s,r=l):(n=g*s,r=g),h-=Math.round(n),e.data("jg.jwidth",Math.round(n)),e.data("jg.jheight",Math.ceil(r)),(0===i||r<a)&&(a=r);return this.buildingRow.height=a,o},r.prototype.flushRow=function(t){var i,e,s,n=this.settings,r=this.border;if(e=this.prepareBuildingRow(t),t&&"hide"===n.lastRow&&-1===e)this.clearBuildingRow();else{if(this.maxRowHeight&&this.maxRowHeight<this.buildingRow.height&&(this.buildingRow.height=this.maxRowHeight),t&&("center"===n.lastRow||"right"===n.lastRow)){var o=this.galleryWidth-2*this.border-(this.buildingRow.entriesBuff.length-1)*n.margins;for(s=0;s<this.buildingRow.entriesBuff.length;s++)o-=(i=this.buildingRow.entriesBuff[s]).data("jg.jwidth");"center"===n.lastRow?r+=o/2:"right"===n.lastRow&&(r+=o)}var a=this.buildingRow.entriesBuff.length-1;for(s=0;s<=a;s++)i=this.buildingRow.entriesBuff[this.settings.rtl?a-s:s],this.displayEntry(i,r,this.offY,i.data("jg.jwidth"),i.data("jg.jheight"),this.buildingRow.height),r+=i.data("jg.jwidth")+n.margins;this.galleryHeightToSet=this.offY+this.buildingRow.height+this.border,this.setGalleryTempHeight(this.galleryHeightToSet+this.getSpinnerHeight()),(!t||this.buildingRow.height<=n.rowHeight&&e)&&(this.offY+=this.buildingRow.height+n.margins,this.rows+=1,this.clearBuildingRow(),this.settings.triggerEvent.call(this,"jg.rowflush"))}};var i=0;function e(){return g("body").height()>g(window).height()}r.prototype.rememberGalleryHeight=function(){i=this.$gallery.height(),this.$gallery.height(i)},r.prototype.setGalleryTempHeight=function(t){i=Math.max(t,i),this.$gallery.height(i)},r.prototype.setGalleryFinalHeight=function(t){i=t,this.$gallery.height(t)},r.prototype.checkWidth=function(){this.checkWidthIntervalId=setInterval(g.proxy(function(){if(this.$gallery.is(":visible")){var t=parseFloat(this.$gallery.width());e()===this.scrollBarOn?Math.abs(t-this.galleryWidth)>this.settings.refreshSensitivity&&(this.galleryWidth=t,this.rewind(),this.rememberGalleryHeight(),this.startImgAnalyzer(!0)):(this.scrollBarOn=e(),this.galleryWidth=t)}},this),this.settings.refreshTime)},r.prototype.isSpinnerActive=function(){return null!==this.spinner.intervalId},r.prototype.getSpinnerHeight=function(){return this.spinner.$el.innerHeight()},r.prototype.stopLoadingSpinnerAnimation=function(){clearInterval(this.spinner.intervalId),this.spinner.intervalId=null,this.setGalleryTempHeight(this.$gallery.height()-this.getSpinnerHeight()),this.spinner.$el.detach()},r.prototype.startLoadingSpinnerAnimation=function(){var t=this.spinner,i=t.$el.find("span");clearInterval(t.intervalId),this.$gallery.append(t.$el),this.setGalleryTempHeight(this.offY+this.buildingRow.height+this.getSpinnerHeight()),t.intervalId=setInterval(function(){t.phase<i.length?i.eq(t.phase).fadeTo(t.timeSlot,1):i.eq(t.phase-i.length).fadeTo(t.timeSlot,0),t.phase=(t.phase+1)%(2*i.length)},t.timeSlot)},r.prototype.rewind=function(){this.lastFetchedEntry=null,this.lastAnalyzedIndex=-1,this.offY=this.border,this.rows=0,this.clearBuildingRow()},r.prototype.updateEntries=function(t){var i;return t&&null!=this.lastFetchedEntry?i=g(this.lastFetchedEntry).nextAll(this.settings.selector).toArray():(this.entries=[],i=this.$gallery.children(this.settings.selector).toArray()),0<i.length&&(g.isFunction(this.settings.sort)?i=this.sortArray(i):this.settings.randomize&&(i=this.shuffleArray(i)),this.lastFetchedEntry=i[i.length-1],this.settings.filter?i=this.filterArray(i):this.resetFilters(i)),this.entries=this.entries.concat(i),!0},r.prototype.insertToGallery=function(t){var i=this;g.each(t,function(){g(this).appendTo(i.$gallery)})},r.prototype.shuffleArray=function(t){var i,e,s;for(i=t.length-1;0<i;i--)e=Math.floor(Math.random()*(i+1)),s=t[i],t[i]=t[e],t[e]=s;return this.insertToGallery(t),t},r.prototype.sortArray=function(t){return t.sort(this.settings.sort),this.insertToGallery(t),t},r.prototype.resetFilters=function(t){for(var i=0;i<t.length;i++)g(t[i]).removeClass("jg-filtered")},r.prototype.filterArray=function(t){var e=this.settings;if("string"===g.type(e.filter))return t.filter(function(t){var i=g(t);return i.is(e.filter)?(i.removeClass("jg-filtered"),!0):(i.addClass("jg-filtered").removeClass("jg-visible"),!1)});if(g.isFunction(e.filter)){for(var i=t.filter(e.filter),s=0;s<t.length;s++)-1===i.indexOf(t[s])?g(t[s]).addClass("jg-filtered").removeClass("jg-visible"):g(t[s]).removeClass("jg-filtered");return i}},r.prototype.destroy=function(){clearInterval(this.checkWidthIntervalId),g.each(this.entries,g.proxy(function(t,i){var e=g(i);e.css("width",""),e.css("height",""),e.css("top",""),e.css("left",""),e.data("jg.loaded",void 0),e.removeClass("jg-entry");var s=this.imgFromEntry(e);s.css("width",""),s.css("height",""),s.css("margin-left",""),s.css("margin-top",""),s.attr("src",s.data("jg.originalSrc")),s.data("jg.originalSrc",void 0),this.removeCaptionEventsHandlers(e);var n=this.captionFromEntry(e);e.data("jg.createdCaption")?(e.data("jg.createdCaption",void 0),null!==n&&n.remove()):null!==n&&n.fadeTo(0,1)},this)),this.$gallery.css("height",""),this.$gallery.removeClass("justified-gallery"),this.$gallery.data("jg.controller",void 0)},r.prototype.analyzeImages=function(t){for(var i=this.lastAnalyzedIndex+1;i<this.entries.length;i++){var e=g(this.entries[i]);if(!0===e.data("jg.loaded")||"skipped"===e.data("jg.loaded")){var s=this.galleryWidth-2*this.border-(this.buildingRow.entriesBuff.length-1)*this.settings.margins,n=e.data("jg.width")/e.data("jg.height");if(s/(this.buildingRow.aspectRatio+n)<this.settings.rowHeight&&(this.flushRow(!1),++this.yield.flushed>=this.yield.every))return void this.startImgAnalyzer(t);this.buildingRow.entriesBuff.push(e),this.buildingRow.aspectRatio+=n,this.buildingRow.width+=n*this.settings.rowHeight,this.lastAnalyzedIndex=i}else if("error"!==e.data("jg.loaded"))return}0<this.buildingRow.entriesBuff.length&&this.flushRow(!0),this.isSpinnerActive()&&this.stopLoadingSpinnerAnimation(),this.stopImgAnalyzerStarter(),this.settings.triggerEvent.call(this,t?"jg.resize":"jg.complete"),this.setGalleryFinalHeight(this.galleryHeightToSet)},r.prototype.stopImgAnalyzerStarter=function(){this.yield.flushed=0,null!==this.imgAnalyzerTimeout&&(clearTimeout(this.imgAnalyzerTimeout),this.imgAnalyzerTimeout=null)},r.prototype.startImgAnalyzer=function(t){var i=this;this.stopImgAnalyzerStarter(),this.imgAnalyzerTimeout=setTimeout(function(){i.analyzeImages(t)},.001)},r.prototype.onImageEvent=function(t,i,e){if(i||e){var s=new Image,n=g(s);i&&n.one("load",function(){n.off("load error"),i(s)}),e&&n.one("error",function(){n.off("load error"),e(s)}),s.src=t}},r.prototype.init=function(){var a=!1,h=!1,l=this;g.each(this.entries,function(t,i){var e=g(i),s=l.imgFromEntry(e);if(e.addClass("jg-entry"),!0!==e.data("jg.loaded")&&"skipped"!==e.data("jg.loaded"))if(null!==l.settings.rel&&e.attr("rel",l.settings.rel),null!==l.settings.target&&e.attr("target",l.settings.target),null!==s){var n=l.extractImgSrcFromImage(s);if(s.attr("src",n),!1===l.settings.waitThumbnailsLoad){var r=parseFloat(s.prop("width")),o=parseFloat(s.prop("height"));if(!isNaN(r)&&!isNaN(o))return e.data("jg.width",r),e.data("jg.height",o),e.data("jg.loaded","skipped"),h=!0,l.startImgAnalyzer(!1),!0}e.data("jg.loaded",!1),a=!0,l.isSpinnerActive()||l.startLoadingSpinnerAnimation(),l.onImageEvent(n,function(t){e.data("jg.width",t.width),e.data("jg.height",t.height),e.data("jg.loaded",!0),l.startImgAnalyzer(!1)},function(){e.data("jg.loaded","error"),l.startImgAnalyzer(!1)})}else e.data("jg.loaded",!0),e.data("jg.width",e.width()|parseFloat(e.css("width"))|1),e.data("jg.height",e.height()|parseFloat(e.css("height"))|1)}),a||h||this.startImgAnalyzer(!1),this.checkWidth()},r.prototype.checkOrConvertNumber=function(t,i){if("string"===g.type(t[i])&&(t[i]=parseFloat(t[i])),"number"!==g.type(t[i]))throw i+" must be a number";if(isNaN(t[i]))throw"invalid number for "+i},r.prototype.checkSizeRangesSuffixes=function(){if("object"!==g.type(this.settings.sizeRangeSuffixes))throw"sizeRangeSuffixes must be defined and must be an object";var t=[];for(var i in this.settings.sizeRangeSuffixes)this.settings.sizeRangeSuffixes.hasOwnProperty(i)&&t.push(i);for(var e={0:""},s=0;s<t.length;s++)if("string"===g.type(t[s]))try{e[parseInt(t[s].replace(/^[a-z]+/,""),10)]=this.settings.sizeRangeSuffixes[t[s]]}catch(t){throw"sizeRangeSuffixes keys must contains correct numbers ("+t+")"}else e[t[s]]=this.settings.sizeRangeSuffixes[t[s]];this.settings.sizeRangeSuffixes=e},r.prototype.retrieveMaxRowHeight=function(){var t=null,i=this.settings.rowHeight;if("string"===g.type(this.settings.maxRowHeight))t=this.settings.maxRowHeight.match(/^[0-9]+%$/)?i*parseFloat(this.settings.maxRowHeight.match(/^([0-9]+)%$/)[1])/100:parseFloat(this.settings.maxRowHeight);else{if("number"!==g.type(this.settings.maxRowHeight)){if(!1===this.settings.maxRowHeight||null==this.settings.maxRowHeight)return null;throw"maxRowHeight must be a number or a percentage"}t=this.settings.maxRowHeight}if(isNaN(t))throw"invalid number for maxRowHeight";return t<i&&(t=i),t},r.prototype.checkSettings=function(){this.checkSizeRangesSuffixes(),this.checkOrConvertNumber(this.settings,"rowHeight"),this.checkOrConvertNumber(this.settings,"margins"),this.checkOrConvertNumber(this.settings,"border");var t=["justify","nojustify","left","center","right","hide"];if(-1===t.indexOf(this.settings.lastRow))throw"lastRow must be one of: "+t.join(", ");
367if(this.checkOrConvertNumber(this.settings,"justifyThreshold"),this.settings.justifyThreshold<0||1<this.settings.justifyThreshold)throw"justifyThreshold must be in the interval [0,1]";if("boolean"!==g.type(this.settings.cssAnimation))throw"cssAnimation must be a boolean";if("boolean"!==g.type(this.settings.captions))throw"captions must be a boolean";if(this.checkOrConvertNumber(this.settings.captionSettings,"animationDuration"),this.checkOrConvertNumber(this.settings.captionSettings,"visibleOpacity"),this.settings.captionSettings.visibleOpacity<0||1<this.settings.captionSettings.visibleOpacity)throw"captionSettings.visibleOpacity must be in the interval [0, 1]";if(this.checkOrConvertNumber(this.settings.captionSettings,"nonVisibleOpacity"),this.settings.captionSettings.nonVisibleOpacity<0||1<this.settings.captionSettings.nonVisibleOpacity)throw"captionSettings.nonVisibleOpacity must be in the interval [0, 1]";if(this.checkOrConvertNumber(this.settings,"imagesAnimationDuration"),this.checkOrConvertNumber(this.settings,"refreshTime"),this.checkOrConvertNumber(this.settings,"refreshSensitivity"),"boolean"!==g.type(this.settings.randomize))throw"randomize must be a boolean";if("string"!==g.type(this.settings.selector))throw"selector must be a string";if(!1!==this.settings.sort&&!g.isFunction(this.settings.sort))throw"sort must be false or a comparison function";if(!1!==this.settings.filter&&!g.isFunction(this.settings.filter)&&"string"!==g.type(this.settings.filter))throw"filter must be false, a string or a filter function"},r.prototype.retrieveSuffixRanges=function(){var t=[];for(var i in this.settings.sizeRangeSuffixes)this.settings.sizeRangeSuffixes.hasOwnProperty(i)&&t.push(parseInt(i,10));return t.sort(function(t,i){return i<t?1:t<i?-1:0}),t},r.prototype.updateSettings=function(t){this.settings=g.extend({},this.settings,t),this.checkSettings(),this.border=0<=this.settings.border?this.settings.border:this.settings.margins,this.maxRowHeight=this.retrieveMaxRowHeight(),this.suffixRanges=this.retrieveSuffixRanges()},r.prototype.defaults={sizeRangeSuffixes:{},thumbnailPath:void 0,rowHeight:120,maxRowHeight:!1,margins:1,border:-1,lastRow:"nojustify",justifyThreshold:.9,waitThumbnailsLoad:!0,captions:!0,cssAnimation:!0,imagesAnimationDuration:500,captionSettings:{animationDuration:500,visibleOpacity:.7,nonVisibleOpacity:0},rel:null,target:null,extension:/\.[^.\\/]+$/,refreshTime:200,refreshSensitivity:0,randomize:!1,rtl:!1,sort:!1,filter:!1,selector:"a, div:not(.spinner)",imgSelector:"> img, > a > img",triggerEvent:function(t){this.$gallery.trigger(t)}},g.fn.justifiedGallery=function(n){return this.each(function(t,i){var e=g(i);e.addClass("justified-gallery");var s=e.data("jg.controller");if(void 0===s){if(null!=n&&"object"!==g.type(n)){if("destroy"===n)return;throw"The argument must be an object"}s=new r(e,g.extend({},r.prototype.defaults,n)),e.data("jg.controller",s)}else if("norewind"===n);else{if("destroy"===n)return void s.destroy();s.updateSettings(n),s.rewind()}s.updateEntries("norewind"===n)&&s.init()})}});
368/* End */
369;
370; /* Start:"a:4:{s:4:"full";s:40:"/lib/feedback/feedback.js?17901517438936";s:6:"source";s:25:"/lib/feedback/feedback.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
371
372$(document).ready(function () {
373
374    // ==========================================
375    // 1. ВЫБОР ФАЙЛОВ
376    // ==========================================
377
378    $('.feedback-file__box').on('click', function () {
379
380        $(this)
381            .closest('form')
382            .find('input[type="file"]')
383            .trigger('click');
384
385    });
386
387
388    $('input[type="file"]').on('change', function () {
389
390        var form = $(this).closest('form');
391
392        var count = this.files ? this.files.length : 0;
393
394        form.find('.feedback-file__text').text(
395            'Выбрано ' + count + ' файл(ов)'
396        );
397
398    });
399
400
401    // ==========================================
402    // 2. ОКНО БЛАГОДАРНОСТИ
403    // ==========================================
404
405    function showThankYouModal() {
406
407        var modal = $('#thankYouModal');
408
409        if (!modal.length) {
410            return;
411        }
412
413        modal.fadeIn();
414
415    }
416
417
418    // Закрытие окна по кнопке.
419
420    $('#thankYouModal .thank-you-close').on('click', function () {
421
422        $('#thankYouModal').fadeOut();
423
424    });
425
426
427    // Закрытие окна при нажатии на фон.
428
429    $('#thankYouModal').on('click', function (event) {
430
431        if (event.target === this) {
432
433            $(this).fadeOut();
434
435        }
436
437    });
438
439
440    // ==========================================
441    // 3. ОТПРАВКА ФОРМЫ
442    // ==========================================
443
444    $('.feedback').on('submit', function (event) {
445
446        event.preventDefault();
447
448        var fb = $(this);
449
450        var errorBox = fb.find(
451            '.feedback-garant__mess-error'
452        );
453
454        var submitButton = fb.find(
455            'button[type="submit"], input[type="submit"]'
456        );
457
458
459        // Не допускаем повторную отправку,
460        // если заявка уже отправлена.
461
462        if (fb.data('submitted')) {
463            return;
464        }
465
466
467        // Не допускаем повторное нажатие,
468        // пока выполняется AJAX-запрос.
469
470        if (fb.data('sending')) {
471            return;
472        }
473
474
475        // Очищаем предыдущее сообщение об ошибке.
476
477        errorBox.text('');
478
479
480        // ======================================
481        // 4. ПРОВЕРКА СОГЛАСИЯ
482        // ======================================
483
484        if (
485            !fb.find('.feedback-garant__checkbox')
486                .prop('checked')
487        ) {
488
489            errorBox.text(
490                'Необходимо дать согласие'
491            );
492
493            return;
494
495        }
496
497
498        // ======================================
499        // 5. ПРОВЕРКА ИМЕНИ И ТЕЛЕФОНА
500        // ======================================
501
502        var nameField = fb.find(
503            '[name="form_name"]'
504        );
505
506        var phoneField = fb.find(
507            '[name="form_phone"]'
508        );
509
510
511        // Проверяем наличие обязательных полей.
512
513        if (!nameField.length || !phoneField.length) {
514
515            errorBox.text(
516                'Ошибка формы: отсутствуют поля имени или телефона'
517            );
518
519            return;
520
521        }
522
523
524        // Получаем значения полей.
525
526        var name = String(
527            nameField.val() || ''
528        ).trim();
529
530        var phone = String(
531            phoneField.val() || ''
532        ).trim();
533
534
535        // Имя не должно быть пустым.
536
537        if (name === '') {
538
539            errorBox.text(
540                'Укажите ваше имя'
541            );
542
543            nameField.trigger('focus');
544
545            return;
546
547        }
548
549
550        // Телефон не должен быть пустым.
551
552        if (phone === '') {
553
554            errorBox.text(
555                'Укажите номер телефона'
556            );
557
558            phoneField.trigger('focus');
559
560            return;
561
562        }
563
564
565        // ======================================
566        // 6. ПОДГОТОВКА ДАННЫХ
567        // ======================================
568
569        var formData = new FormData(this);
570
571
572        // Блокируем кнопку на время отправки.
573
574        fb.data('sending', true);
575
576        submitButton.prop('disabled', true);
577
578
579        // ======================================
580        // 7. AJAX-ЗАПРОС
581        // ======================================
582
583        $.ajax({
584
585            url: '/lib/feedback/mail-form.php',
586
587            type: 'POST',
588
589            data: formData,
590
591            dataType: 'text',
592
593            cache: false,
594
595            contentType: false,
596
597            processData: false,
598
599
600            // ==================================
601            // ОТВЕТ СЕРВЕРА
602            // ==================================
603
604            success: function (response) {
605
606                // Убираем пробелы по краям ответа.
607
608                response = response.trim();
609
610
611                // ==================================
612                // УСПЕШНАЯ ОТПРАВКА
613                // ==================================
614
615                // Только этот точный ответ означает,
616                // что сервер подтвердил создание заявки.
617
618                if (
619                    response ===
620                    'success#Спасибо! Ваша заявка отправлена'
621                ) {
622
623                    fb.data('submitted', true);
624
625                    errorBox.text('');
626
627
628                    // Показываем сообщение внутри формы.
629
630                    fb.find('.feedback-garant').html(
631                        '<div class="feedback-send-message">' +
632                        'Спасибо! Ваша заявка отправлена' +
633                        '</div>'
634                    );
635
636
637                    // Показываем окно благодарности.
638
639                    showThankYouModal();
640
641                    return;
642
643                }
644
645
646                // ==================================
647                // СЕРВЕР ОТКЛОНИЛ ЗАЯВКУ
648                // ==================================
649
650                if (response.startsWith('error#')) {
651
652                    var errorMessage = response
653                        .substring(6)
654                        .split(/\r?\n/)[0];
655
656                    errorBox.text(
657                        errorMessage || 'Заявка не отправлена'
658                    );
659
660                    return;
661
662                }
663
664
665                // ==================================
666                // НЕОЖИДАННЫЙ ОТВЕТ СЕРВЕРА
667                // ==================================
668
669                // Например:
670                // Ошибка PHP
671                // Ошибка Битрикса
672                // Ошибка запуска сессии
673                // HTML вместо ответа обработчика
674
675                console.error(
676                    'Неожиданный ответ mail-form.php:',
677                    response
678                );
679
680                errorBox.text(
681                    'Не удалось подтвердить отправку заявки. ' +
682                    'Пожалуйста, свяжитесь с нами.'
683                );
684
685            },
686
687
688            // ==================================
689            // ОШИБКА AJAX-ЗАПРОСА
690            // ==================================
691
692            error: function (xhr, textStatus, errorThrown) {
693
694                console.error(
695                    'Ошибка отправки заявки:',
696                    xhr.status,
697                    textStatus,
698                    errorThrown,
699                    xhr.responseText
700                );
701
702                errorBox.text(
703                    'Ошибка отправки заявки. ' +
704                    'Пожалуйста, попробуйте позже.'
705                );
706
707            },
708
709
710            // ==================================
711            // ЗАВЕРШЕНИЕ AJAX-ЗАПРОСА
712            // ==================================
713
714            complete: function () {
715
716                fb.data('sending', false);
717
718
719                // Если сервер не подтвердил успех,
720                // снова разрешаем отправку.
721
722                if (!fb.data('submitted')) {
723
724                    submitButton.prop(
725                        'disabled',
726                        false
727                    );
728
729                }
730
731            }
732
733        });
734
735    });
736
737});
738/* End */
739;
740; /* Start:"a:4:{s:4:"full";s:36:"/lib/calc/js/calc.js?173827436851268";s:6:"source";
740s:20:"/lib/calc/js/calc.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
741/*
742	* Calc_Remont v.1.0
743	* Copyright (c) 2016 GVOZDEVSOFT
744	* http://www.gvozdevsoft.ru
745	*/
746	$(document).ready(function(){
747
748	//
749	//RASCHET POMESHCHENIYA
750	//
751	
752	//VHODNYE DANNYE NEOBHODIMO IZMENIT V ZAVISIMOSTI OT CEN V VAShEJ KOMPANNII
753	//Klass remonta
754	var calc_kosm = 2500; //kosmeticheskij remont, rub/m2
755	var calc_kap = 4000; //kapital'nyj remont, rub/m2
756	var calc_evro = 6500; //evroremont, rub/m2
757	//Kojefficienty
758	var calc_kvartira = 1; //kvartira
759	var calc_kottedzh = 0.9; //kottedzh
760	var calc_ofis = 0.7; //ofis
761	var calc_novostroy = 1; //novostrojka
762	var calc_vtorichka = 1.2; //vtorichka
763	//Chernovye materialy
764	var calc_ch_mat = 0.6; //chernovye materialy 60% ot stoimosti rabot
765	
766	
767	//RASChET
768	//
769	//main page calc
770	var calc3_itog;
771	var calc3_repair_val;
772	var calc3_building_val;
773	var calc3_s_val = parseInt($("#calc3_s").val());
774	var calc3_type_room_val = parseInt($("select#calc3_type_room").val());
775	switch(calc3_type_room_val){
776		case 1: calc3_type_room_val = 0; break;
777		case 2: calc3_type_room_val = calc_kvartira; break;
778		case 3: calc3_type_room_val = calc_kottedzh; break;
779		case 4: calc3_type_room_val = calc_ofis; break;
780	}
781	if($("#calc3_kap").prop("checked") == true){
782		calc3_repair_val = calc_kap; 
783	};
784	if($("#calc3_kosm").prop("checked") == true){
785		calc3_repair_val = calc_kosm; 
786	};
787	if($("#calc3_evro").prop("checked") == true){
788		calc3_repair_val = calc_evro; 
789	};
790
791	if($("#calc3_novostroy").prop("checked") == true){
792		calc3_building_val = calc_novostroy; 
793	};
794	if($("#calc3_vtorichka").prop("checked") == true){
795		calc3_building_val = calc_vtorichka; 
796	};
797	calc3_itog = parseInt(calc3_s_val * calc3_type_room_val * calc3_repair_val * calc3_building_val);
798	calc3_itog = calc3_itog.toLocaleString();
799	$("#calc3_itog").html(calc3_itog);
800	//
801	$("#calc3_s").on("input", function() {
802		var calc3_s_val = parseInt($("#calc3_s").val());
803		var calc3_type_room_val = parseInt($("select#calc3_type_room").val());
804		switch(calc3_type_room_val){
805			case 1: calc3_type_room_val = 0; break;
806			case 2: calc3_type_room_val = calc_kvartira; break;
807			case 3: calc3_type_room_val = calc_kottedzh; break;
808			case 4: calc3_type_room_val = calc_ofis; break;
809		}
810		if($("#calc3_kap").prop("checked") == true){
811			calc3_repair_val = calc_kap; 
812		};
813		if($("#calc3_kosm").prop("checked") == true){
814			calc3_repair_val = calc_kosm; 
815		};
816		if($("#calc3_evro").prop("checked") == true){
817			calc3_repair_val = calc_evro; 
818		};
819
820		if($("#calc3_novostroy").prop("checked") == true){
821			calc3_building_val = calc_novostroy; 
822		};
823		if($("#calc3_vtorichka").prop("checked") == true){
824			calc3_building_val = calc_vtorichka; 
825		};
826		calc3_itog = parseInt(calc3_s_val * calc3_type_room_val * calc3_repair_val * calc3_building_val);
827		calc3_itog = calc3_itog.toLocaleString();
828		$("#calc3_itog").html(calc3_itog);
829	});
830	$("select#calc3_type_room, input[type='radio']").change(function(){
831		var calc3_s_val = parseInt($("#calc3_s").val());
832		var calc3_type_room_val = parseInt($("select#calc3_type_room").val());
833		switch(calc3_type_room_val){
834			case 1: calc3_type_room_val = 0; break;
835			case 2: calc3_type_room_val = calc_kvartira; break;
836			case 3: calc3_type_room_val = calc_kottedzh; break;
837			case 4: calc3_type_room_val = calc_ofis; break;
838		}
839		if($("#calc3_kap").prop("checked") == true){
840			calc3_repair_val = calc_kap; 
841		};
842		if($("#calc3_kosm").prop("checked") == true){
843			calc3_repair_val = calc_kosm; 
844		};
845		if($("#calc3_evro").prop("checked") == true){
846			calc3_repair_val = calc_evro; 
847		};
848
849		if($("#calc3_novostroy").prop("checked") == true){
850			calc3_building_val = calc_novostroy; 
851		};
852		if($("#calc3_vtorichka").prop("checked") == true){
853			calc3_building_val = calc_vtorichka; 
854		};
855		calc3_itog = parseInt(calc3_s_val * calc3_type_room_val * calc3_repair_val * calc3_building_val);
856		calc3_itog = calc3_itog.toLocaleString();
857		$("#calc3_itog").html(calc3_itog);
858	});
859	//
860	//
861	var calc_s_val = parseInt($("#calc_s").val());
862	var calc_class_remonta;
863	var calc_tip_doma;
864	var calc_tip_pom;
865	var calc_raboty;
866	var calc_material;
867	var calc_itog;
868	if($("#calc_kosm").prop("checked") == true){calc_class_remonta = calc_kosm};
869	if($("#calc_kap").prop("checked") == true){calc_class_remonta = calc_kap};
870	if($("#calc_evro").prop("checked") == true){calc_class_remonta = calc_evro};
871	if($("#calc_kvartira").prop("checked") == true){calc_tip_pom = calc_kvartira};
872	if($("#calc_kottedzh").prop("checked") == true){calc_tip_pom = calc_kottedzh};
873	if($("#calc_ofis").prop("checked") == true){calc_tip_pom = calc_ofis};
874	if($("#calc_novostroy").prop("checked") == true){calc_tip_doma = calc_novostroy};
875	if($("#calc_vtorichka").prop("checked") == true){calc_tip_doma = calc_vtorichka};
876	calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
877	calc_material = parseInt(calc_raboty * calc_ch_mat);
878	calc_itog = parseInt(calc_raboty + calc_material);
879	$("#calc_raboty").html(calc_raboty);
880	$("#calc_material").html(calc_material);
881	$("#calc_itog").html(calc_itog);
882	$("#calc_kosm").change(function(){
883		calc_class_remonta = calc_kosm; 
884		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
885		calc_material = parseInt(calc_raboty * calc_ch_mat);
886		calc_itog = parseInt(calc_raboty + calc_material);
887		$("#calc_raboty").html(calc_raboty);
888		$("#calc_material").html(calc_material);
889		$("#calc_itog").html(calc_itog);
890	});
891	$("#calc_kap").change(function(){
892		calc_class_remonta = calc_kap; 
893		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
894		calc_material = parseInt(calc_raboty * calc_ch_mat);
895		calc_itog = parseInt(calc_raboty + calc_material);
896		$("#calc_raboty").html(calc_raboty);
897		$("#calc_material").html(calc_material);
898		$("#calc_itog").html(calc_itog);
899	});
900	$("#calc_evro").change(function(){
901		calc_class_remonta = calc_evro; 
902		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
903		calc_material = parseInt(calc_raboty * calc_ch_mat);
904		calc_itog = parseInt(calc_raboty + calc_material);
905		$("#calc_raboty").html(calc_raboty);
906		$("#calc_material").html(calc_material);
907		$("#calc_itog").html(calc_itog);
908	});
909	$("#calc_kvartira").change(function(){
910		calc_tip_pom = calc_kvartira;
911		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
912		calc_material = parseInt(calc_raboty * calc_ch_mat);
913		calc_itog = parseInt(calc_raboty + calc_material);
914		$("#calc_raboty").html(calc_raboty);
915		$("#calc_material").html(calc_material);
916		$("#calc_itog").html(calc_itog);
917	});
918	$("#calc_kottedzh").change(function(){
919		calc_tip_pom = calc_kottedzh;
920		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
921		calc_material = parseInt(calc_raboty * calc_ch_mat);
922		calc_itog = parseInt(calc_raboty + calc_material);
923		$("#calc_raboty").html(calc_raboty);
924		$("#calc_material").html(calc_material);
925		$("#calc_itog").html(calc_itog);
926	});
927	$("#calc_ofis").change(function(){
928		calc_tip_pom = calc_ofis;
929		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
930		calc_material = parseInt(calc_raboty * calc_ch_mat);
931		calc_itog = parseInt(calc_raboty + calc_material);
932		$("#calc_raboty").html(calc_raboty);
933		$("#calc_material").html(calc_material);
934		$("#calc_itog").html(calc_itog);
935	});
936	$("#calc_novostroy").change(function(){
937		calc_tip_doma = calc_novostroy;
938		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
939		calc_material = parseInt(calc_raboty * calc_ch_mat);
940		calc_itog = parseInt(calc_raboty + calc_material);
941		$("#calc_raboty").html(calc_raboty);
942		$("#calc_material").html(calc_material);
943		$("#calc_itog").html(calc_itog);
944	});
945	$("#calc_vtorichka").change(function(){
946		calc_tip_doma = calc_vtorichka;
947		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
948		calc_material = parseInt(calc_raboty * calc_ch_mat);
949		calc_itog = parseInt(calc_raboty + calc_material);
950		$("#calc_raboty").html(calc_raboty);
951		$("#calc_material").html(calc_material);
952		$("#calc_itog").html(calc_itog);
953	});
954	$("#calc_s").on("input", function(){
955		calc_s_val = parseFloat($("#calc_s").val());
956		calc_raboty = parseInt(calc_s_val * calc_class_remonta * calc_tip_pom * calc_tip_doma);
957		calc_material = parseInt(calc_raboty * calc_ch_mat);
958		calc_itog = parseInt(calc_raboty + calc_material);
959		$("#calc_raboty").html(calc_raboty);
960		$("#calc_material").html(calc_material);
961		$("#calc_itog").html(calc_itog);
962	});
963	
964	/*
965		* Calc_Remont v.1.0
966		* Copyright (c) 2016 GVOZDEVSOFT
967		* http://www.gvozdevsoft.ru
968		*/
969
970	//
971	//RASChET KOMNATY
972	//
973	
974	//VHODNYE DANNYE NEOBHODIMO IZMENIT V ZAVISIMOSTI OT CEN V VAShEJ KOMPANNII
975	//Vyravnivanie potolka
976	var calc2_potolok_rovno;
977	var calc2_potolok_rovno_sh = 350;
978	var calc2_potolok_rovno_no = 0;
979	//Otdelka potolka
980	var select_otdelka_potolka;
981	var calc2_otdelka_potolka;
982	var calc2_potolok_nat = 250;
983	var calc2_potolok_glk = 550;
984	var calc2_potolok_mglk = 760;
985	var calc2_potolok_glk_nat = 650;
986	var calc2_potolok_reech = 360;
987	var calc2_potolok_arm = 310;
988	var calc2_potolok_pokr = 240;
989	//Vyravnivanie pola
990	var calc2_pol_rovno;
991	var calc2_pol_rovno_styzhka = 320;
992	var calc2_pol_rovno_lagi = 270;
993	var calc2_pol_rovno_no = 0;
994	//Teplye poly
995	var calc2_teplyy_pol;
996	var calc2_teplyy_pol_voda = 450;
997	var calc2_teplyy_pol_electro = 265;
998	var calc2_teplyy_pol_infro = 300;
999	var calc2_teplyy_pol_mat = 230;
1000	var calc2_teplyy_pol_no = 0;
1001	//Otdelka pola
1002	var select_otdelka_pol;
1003	var calc2_otdelka_pol;
1004	var calc2_pol_lam = 300;
1005	var calc2_pol_kovr = 260;
1006	var calc2_pol_lin = 250;
1007	var calc2_pol_par_dos = 310;
1008	var calc2_pol_par = 1200;
1009	var calc2_pol_ker_pl = 650;
1010	var calc2_pol_keramo = 700;
1011	var calc2_pol_probka = 450;
1012	var calc2_pol_naliv = 345;
1013	//Vyravnivanie sten
1014	var calc2_steny_rovno;
1015	var calc2_steny_rovno_shukaturka = 360;
1016	var calc2_steny_rovno_glk = 540;
1017	var calc2_steny_rovno_no = 0;
1018	//Otdelka sten
1019	var select_otdelka_sten;
1020	var calc2_otdelka_sten;
1021	var calc2_steny_sh_oboi = 220;
1022	var calc2_steny_oboi_pokr = 240;
1023	var calc2_steny_sh_pokr = 260;
1024	var calc2_steny_dec_sh = 560;
1025	var calc2_steny_pvkh = 250;
1026	var calc2_steny_kep_pl = 675;
1027	var calc2_steny_moz = 1500;
1028	var calc2_steny_vag = 230;
1029	//Ustanovka okna
1030	var select_ust_okna;
1031	var calc2_ust_okna;
1032	var calc2_okna_met = 2500;
1033	var calc2_okna_der = 3500;
1034	var calc2_okna_komb = 3000;
1035	//Ustanovka dverej
1036	var select_ust_dver;
1037	var calc2_ust_dver;
1038	var calc2_ust_dver_m_sh = 2500;
1039	var calc2_ust_dver_m_m = 3000;
1040	var calc2_ust_dver_vkh = 4000;
1041	//Chernovye materialy
1042	var calc2_ch_mat = 0.7; //chernovye materialy 70% ot stoimosti rabot
1043	
1044	
1045	//RASChET
1046	var calc2_d_val = parseFloat($("#calc2_d").val());
1047	var calc2_sh_val = parseFloat($("#calc2_sh").val());
1048	var calc2_v_val = parseFloat($("#calc2_v").val());
1049	if($("#calc2_potolok_rovno_sh").prop("checked") == true){calc2_potolok_rovno = calc2_potolok_rovno_sh;};
1050	if($("#calc2_potolok_rovno_no").prop("checked") == true){calc2_potolok_rovno = calc2_potolok_rovno_no;};
1051	select_otdelka_potolka = parseInt($("select#calc2_otdelka_potolka").val());
1052	switch(select_otdelka_potolka){
1053		case 1: calc2_otdelka_potolka = calc2_potolok_nat; break;
1054		case 2: calc2_otdelka_potolka = calc2_potolok_glk; break;
1055		case 3: calc2_otdelka_potolka = calc2_potolok_mglk; break;
1056		case 4: calc2_otdelka_potolka = calc2_potolok_glk_nat; break;
1057		case 5: calc2_otdelka_potolka = calc2_potolok_reech; break;
1058		case 6: calc2_otdelka_potolka = calc2_potolok_arm; break;
1059		case 7: calc2_otdelka_potolka = calc2_potolok_pokr; break;
1060	}
1061	if($("#calc2_pol_rovno_styzhka").prop("checked") == true){calc2_pol_rovno = calc2_pol_rovno_styzhka;};
1062	if($("#calc2_pol_rovno_lagi").prop("checked") == true){calc2_pol_rovno = calc2_pol_rovno_lagi;};
1063	if($("#calc2_pol_rovno_no").prop("checked") == true){calc2_pol_rovno = calc2_pol_rovno_no;};
1064	if($("#calc2_teplyy_pol_voda").prop("checked") == true){calc2_teplyy_pol = calc2_teplyy_pol_voda;};
1065	if($("#calc2_teplyy_pol_electro").prop("checked") == true){calc2_teplyy_pol = calc2_teplyy_pol_electro;};
1066	if($("#calc2_teplyy_pol_infro").prop("checked") == true){calc2_teplyy_pol = calc2_teplyy_pol_infro;};
1067	if($("#calc2_teplyy_pol_mat").prop("checked") == true){calc2_teplyy_pol = calc2_teplyy_pol_mat;};
1068	if($("#calc2_teplyy_pol_no").prop("checked") == true){calc2_teplyy_pol = calc2_teplyy_pol_no;};
1069	select_otdelka_pol = parseInt($("select#calc2_otdelka_pol").val());
1070	switch(select_otdelka_pol){
1071		case 1: calc2_otdelka_pol = calc2_pol_lam; break;
1072		case 2: calc2_otdelka_pol = calc2_pol_kovr; break;
1073		case 3: calc2_otdelka_pol = calc2_pol_lin; break;
1074		case 4: calc2_otdelka_pol = calc2_pol_par_dos; break;
1075		case 5: calc2_otdelka_pol = calc2_pol_par; break;
1076		case 6: calc2_otdelka_pol = calc2_pol_ker_pl; break;
1077		case 7: calc2_otdelka_pol = calc2_pol_keramo; break;
1078		case 8: calc2_otdelka_pol = calc2_pol_probka; break;
1079		case 9: calc2_otdelka_pol = calc2_pol_naliv; break;
1080	}
1081	if($("#calc2_steny_rovno_shukaturka").prop("checked") == true){calc2_steny_rovno = calc2_steny_rovno_shukaturka;};
1082	if($("#calc2_steny_rovno_glk").prop("checked") == true){calc2_steny_rovno = calc2_steny_rovno_glk;};
1083	if($("#calc2_steny_rovno_no").prop("checked") == true){calc2_steny_rovno = calc2_steny_rovno_no;};
1084	select_otdelka_sten = parseInt($("select#calc2_otdelka_sten").val());
1085	switch(select_otdelka_sten){
1086		case 1: calc2_otdelka_sten = calc2_steny_sh_oboi; break;
1087		case 2: calc2_otdelka_sten = calc2_steny_oboi_pokr; break;
1088		case 3: calc2_otdelka_sten = calc2_steny_sh_pokr; break;
1089		case 4: calc2_otdelka_sten = calc2_steny_dec_sh; break;
1090		case 5: calc2_otdelka_sten = calc2_steny_pvkh; break;
1091		case 6: calc2_otdelka_sten = calc2_steny_kep_pl; break;
1092		case 7: calc2_otdelka_sten = calc2_steny_moz; break;
1093		case 8: calc2_otdelka_sten = calc2_steny_vag; break;
1094	}
1095	var calc2_okna_kol;
1096	var calc2_okna_kol_1 = 1;
1097	var calc2_okna_kol_2 = 2;
1098	var calc2_okna_kol_3 = 3;
1099	var calc2_okna_kol_4 = 4;
1100	var calc2_okna_kol_no = 0;
1101	if($("#calc2_okna_kol_1").prop("checked") == true){calc2_okna_kol = calc2_okna_kol_1;};
1102	if($("#calc2_okna_kol_2").prop("checked") == true){calc2_okna_kol = calc2_okna_kol_2;};
1103	if($("#calc2_okna_kol_3").prop("checked") == true){calc2_okna_kol = calc2_okna_kol_3;};
1104	if($("#calc2_okna_kol_4").prop("checked") == true){calc2_okna_kol = calc2_okna_kol_4;};
1105	if($("#calc2_okna_kol_no").prop("checked") == true){calc2_okna_kol = calc2_okna_kol_no;};
1106	select_ust_okna = parseInt($("select#calc2_ust_okna").val());
1107	switch(select_ust_okna){
1108		case 1: calc2_ust_okna = calc2_okna_met; break;
1109		case 2: calc2_ust_okna = calc2_okna_der; break;
1110		case 3: calc2_ust_okna = calc2_okna_komb; break;
1111	}
1112	var calc2_dveri_kol;
1113	var calc2_dveri_kol_1 = 1;
1114	var calc2_dveri_kol_2 = 2;
1115	var calc2_dveri_kol_3 = 3;
1116	var calc2_dveri_kol_4 = 4;
1117	var calc2_dveri_kol_no = 0;
1118	if($("#calc2_dveri_kol_1").prop("checked") == true){calc2_dveri_kol = calc2_dveri_kol_1;};
1119	if($("#calc2_dveri_kol_2").prop("checked") == true){calc2_dveri_kol = calc2_dveri_kol_2;};
1120	if($("#calc2_dveri_kol_3").prop("checked") == true){calc2_dveri_kol = calc2_dveri_kol_3;};
1121	if($("#calc2_dveri_kol_4").prop("checked") == true){calc2_dveri_kol = calc2_dveri_kol_4;};
1122	if($("#calc2_dveri_kol_no").prop("checked") == true){calc2_dveri_kol = calc2_dveri_kol_no;};
1123	select_ust_dver = parseInt($("select#calc2_ust_dver").val());
1124	switch(select_ust_dver){
1125		case 1: calc2_ust_dver = calc2_ust_dver_m_sh; break;
1126		case 2: calc2_ust_dver = calc2_ust_dver_m_m; break;
1127		case 3: calc2_ust_dver = calc2_ust_dver_vkh; break;
1128	}
1129	var calc2_s_sten;
1130	var calc2_s_potolok;
1131	var calc2_s_pol;
1132	calc2_s_sten = (2 * (calc2_d_val + calc2_sh_val) * calc2_v_val).toFixed(1);
1133	calc2_s_potolok = (calc2_d_val * calc2_sh_val).toFixed(1);
1134	calc2_s_pol = (calc2_d_val * calc2_sh_val).toFixed(1);
1135	var calc2_raboty_potolok;
1136	calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1137	var calc2_raboty_pol;
1138	calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1139	var calc2_raboty_stena;
1140	calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1141	var calc2_raboty_okno;
1142	calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1143	var calc2_raboty_dver;
1144	calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1145	var calc2_raboty;
1146	var calc2_material;
1147	var calc2_itog;
1148	calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1149	calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1150	calc2_itog = parseInt(calc2_raboty + calc2_material);
1151	$("#calc2_rez_s_stena").html(calc2_s_sten);
1152	$("#calc2_rez_s_pol").html(calc2_s_pol);
1153	$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1154	$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1155	$("#calc2_raboty_pol").html(calc2_raboty_pol);
1156	$("#calc2_raboty_stena").html(calc2_raboty_stena);
1157	$("#calc2_raboty_okno").html(calc2_raboty_okno);
1158	$("#calc2_raboty_dver").html(calc2_raboty_dver);
1159	$("#calc2_raboty").html(calc2_raboty);
1160	$("#calc2_material").html(calc2_material);
1161	$("#calc2_itog").html(calc2_itog);
1162	$("#calc2_sh").on("input", function(){
1163		calc2_sh_val = parseFloat($("#calc2_sh").val());
1164		calc2_s_sten = (2 * (calc2_d_val + calc2_sh_val) * calc2_v_val).toFixed(1);
1165		calc2_s_potolok = (calc2_d_val * calc2_sh_val).toFixed(1);
1166		calc2_s_pol = (calc2_d_val * calc2_sh_val).toFixed(1);
1167		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1168		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1169		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1170		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1171		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1172		calc2_itog = parseInt(calc2_raboty + calc2_material);
1173		$("#calc2_rez_s_stena").html(calc2_s_sten);
1174		$("#calc2_rez_s_pol").html(calc2_s_pol);
1175		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1176		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1177		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1178		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1179		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1180		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1181		$("#calc2_raboty").html(calc2_raboty);
1182		$("#calc2_material").html(calc2_material);
1183		$("#calc2_itog").html(calc2_itog);
1184	});
1185	$("#calc2_d").on("input", function(){
1186		calc2_d_val = parseFloat($("#calc2_d").val());
1187		calc2_s_sten = (2 * (calc2_d_val + calc2_sh_val) * calc2_v_val).toFixed(1);
1188		calc2_s_potolok = (calc2_d_val * calc2_sh_val).toFixed(1);
1189		calc2_s_pol = (calc2_d_val * calc2_sh_val).toFixed(1);
1190		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1191		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1192		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1193		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1194		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1195		calc2_itog = parseInt(calc2_raboty + calc2_material);
1196		$("#calc2_rez_s_stena").html(calc2_s_sten);
1197		$("#calc2_rez_s_pol").html(calc2_s_pol);
1198		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1199		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1200		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1201		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1202		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1203		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1204		$("#calc2_raboty").html(calc2_raboty);
1205		$("#calc2_material").html(calc2_material);
1206		$("#calc2_itog").html(calc2_itog);
1207	});
1208	$("#calc2_v").on("input", function(){
1209		calc2_v_val = parseFloat($("#calc2_v").val());
1210		calc2_s_sten = (2 * (calc2_d_val + calc2_sh_val) * calc2_v_val).toFixed(1);
1211		calc2_s_potolok = (calc2_d_val * calc2_sh_val).toFixed(1);
1212		calc2_s_pol = (calc2_d_val * calc2_sh_val).toFixed(1);
1213		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1214		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1215		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1216		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1217		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1218		calc2_itog = parseInt(calc2_raboty + calc2_material);
1219		$("#calc2_rez_s_stena").html(calc2_s_sten);
1220		$("#calc2_rez_s_pol").html(calc2_s_pol);
1221		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1222		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1223		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1224		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1225		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1226		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1227		$("#calc2_raboty").html(calc2_raboty);
1228		$("#calc2_material").html(calc2_material);
1229		$("#calc2_itog").html(calc2_itog);
1230	});
1231	$("#calc2_potolok_rovno_sh").change(function(){
1232		calc2_potolok_rovno = calc2_potolok_rovno_sh;
1233		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1234		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1235		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1236		calc2_itog = parseInt(calc2_raboty + calc2_material);
1237		$("#calc2_rez_s_stena").html(calc2_s_sten);
1238		$("#calc2_rez_s_pol").html(calc2_s_pol);
1239		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1240		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1241		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1242		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1243		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1244		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1245		$("#calc2_raboty").html(calc2_raboty);
1246		$("#calc2_material").html(calc2_material);
1247		$("#calc2_itog").html(calc2_itog);
1248	});
1249	$("#calc2_potolok_rovno_no").change(function(){
1250		calc2_potolok_rovno = calc2_potolok_rovno_no;
1251		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1252		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1253		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1254		calc2_itog = parseInt(calc2_raboty + calc2_material);
1255		$("#calc2_rez_s_stena").html(calc2_s_sten);
1256		$("#calc2_rez_s_pol").html(calc2_s_pol);
1257		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1258		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1259		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1260		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1261		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1262		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1263		$("#calc2_raboty").html(calc2_raboty);
1264		$("#calc2_material").html(calc2_material);
1265		$("#calc2_itog").html(calc2_itog);
1266	});
1267	$("#calc2_otdelka_potolka").change(function(){
1268		select_otdelka_potolka = parseInt($("select#calc2_otdelka_potolka").val());
1269		switch(select_otdelka_potolka){
1270			case 1: calc2_otdelka_potolka = calc2_potolok_nat; break;
1271			case 2: calc2_otdelka_potolka = calc2_potolok_glk; break;
1272			case 3: calc2_otdelka_potolka = calc2_potolok_mglk; break;
1273			case 4: calc2_otdelka_potolka = calc2_potolok_glk_nat; break;
1274			case 5: calc2_otdelka_potolka = calc2_potolok_reech; break;
1275			case 6: calc2_otdelka_potolka = calc2_potolok_arm; break;
1276			case 7: calc2_otdelka_potolka = calc2_potolok_pokr; break;
1277		}
1278		calc2_raboty_potolok = parseInt(calc2_s_potolok * (calc2_potolok_rovno + calc2_otdelka_potolka));
1279		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1280		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1281		calc2_itog = parseInt(calc2_raboty + calc2_material);
1282		$("#calc2_rez_s_stena").html(calc2_s_sten);
1283		$("#calc2_rez_s_pol").html(calc2_s_pol);
1284		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1285		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1286		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1287		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1288		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1289		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1290		$("#calc2_raboty").html(calc2_raboty);
1291		$("#calc2_material").html(calc2_material);
1292		$("#calc2_itog").html(calc2_itog);
1293	});
1294	$("#calc2_pol_rovno_styzhka").change(function(){
1295		calc2_pol_rovno = calc2_pol_rovno_styzhka;
1296		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1297		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1298		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1299		calc2_itog = parseInt(calc2_raboty + calc2_material);
1300		$("#calc2_rez_s_stena").html(calc2_s_sten);
1301		$("#calc2_rez_s_pol").html(calc2_s_pol);
1302		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1303		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1304		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1305		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1306		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1307		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1308		$("#calc2_raboty").html(calc2_raboty);
1309		$("#calc2_material").html(calc2_material);
1310		$("#calc2_itog").html(calc2_itog);
1311	});
1312	$("#calc2_pol_rovno_lagi").change(function(){
1313		calc2_pol_rovno = calc2_pol_rovno_lagi;
1314		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1315		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1316		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1317		calc2_itog = parseInt(calc2_raboty + calc2_material);
1318		$("#calc2_rez_s_stena").html(calc2_s_sten);
1319		$("#calc2_rez_s_pol").html(calc2_s_pol);
1320		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1321		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1322		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1323		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1324		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1325		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1326		$("#calc2_raboty").html(calc2_raboty);
1327		$("#calc2_material").html(calc2_material);
1328		$("#calc2_itog").html(calc2_itog);
1329	});
1330	$("#calc2_pol_rovno_no").change(function(){
1331		calc2_pol_rovno = calc2_pol_rovno_no;
1332		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1333		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1334		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1335		calc2_itog = parseInt(calc2_raboty + calc2_material);
1336		$("#calc2_rez_s_stena").html(calc2_s_sten);
1337		$("#calc2_rez_s_pol").html(calc2_s_pol);
1338		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1339		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1340		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1341		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1342		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1343		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1344		$("#calc2_raboty").html(calc2_raboty);
1345		$("#calc2_material").html(calc2_material);
1346		$("#calc2_itog").html(calc2_itog);
1347	});
1348	$("#calc2_teplyy_pol_voda").change(function(){
1349		calc2_teplyy_pol = calc2_teplyy_pol_voda;
1350		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1351		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1352		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1353		calc2_itog = parseInt(calc2_raboty + calc2_material);
1354		$("#calc2_rez_s_stena").html(calc2_s_sten);
1355		$("#calc2_rez_s_pol").html(calc2_s_pol);
1356		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1357		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1358		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1359		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1360		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1361		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1362		$("#calc2_raboty").html(calc2_raboty);
1363		$("#calc2_material").html(calc2_material);
1364		$("#calc2_itog").html(calc2_itog);
1365	});
1366	$("#calc2_teplyy_pol_electro").change(function(){
1367		calc2_teplyy_pol = calc2_teplyy_pol_electro;
1368		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1369		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1370		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1371		calc2_itog = parseInt(calc2_raboty + calc2_material);
1372		$("#calc2_rez_s_stena").html(calc2_s_sten);
1373		$("#calc2_rez_s_pol").html(calc2_s_pol);
1374		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1375		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1376		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1377		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1378		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1379		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1380		$("#calc2_raboty").html(calc2_raboty);
1381		$("#calc2_material").html(calc2_material);
1382		$("#calc2_itog").html(calc2_itog);
1383	});
1384	$("#calc2_teplyy_pol_infro").change(function(){
1385		calc2_teplyy_pol = calc2_teplyy_pol_infro;
1386		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1387		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1388		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1389		calc2_itog = parseInt(calc2_raboty + calc2_material);
1390		$("#calc2_rez_s_stena").html(calc2_s_sten);
1391		$("#calc2_rez_s_pol").html(calc2_s_pol);
1392		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1393		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1394		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1395		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1396		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1397		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1398		$("#calc2_raboty").html(calc2_raboty);
1399		$("#calc2_material").html(calc2_material);
1400		$("#calc2_itog").html(calc2_itog);
1401	});
1402	$("#calc2_teplyy_pol_mat").change(function(){
1403		calc2_teplyy_pol = calc2_teplyy_pol_mat;
1404		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1405		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1406		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1407		calc2_itog = parseInt(calc2_raboty + calc2_material);
1408		$("#calc2_rez_s_stena").html(calc2_s_sten);
1409		$("#calc2_rez_s_pol").html(calc2_s_pol);
1410		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1411		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1412		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1413		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1414		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1415		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1416		$("#calc2_raboty").html(calc2_raboty);
1417		$("#calc2_material").html(calc2_material);
1418		$("#calc2_itog").html(calc2_itog);
1419	});
1420	$("#calc2_teplyy_pol_no").change(function(){
1421		calc2_teplyy_pol = calc2_teplyy_pol_no;
1422		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1423		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1424		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1425		calc2_itog = parseInt(calc2_raboty + calc2_material);
1426		$("#calc2_rez_s_stena").html(calc2_s_sten);
1427		$("#calc2_rez_s_pol").html(calc2_s_pol);
1428		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1429		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1430		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1431		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1432		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1433		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1434		$("#calc2_raboty").html(calc2_raboty);
1435		$("#calc2_material").ht
1435ml(calc2_material);
1436		$("#calc2_itog").html(calc2_itog);
1437	});
1438	$("#calc2_otdelka_pol").change(function(){
1439		select_otdelka_pol = parseInt($("select#calc2_otdelka_pol").val());
1440		switch(select_otdelka_pol){
1441			case 1: calc2_otdelka_pol = calc2_pol_lam; break;
1442			case 2: calc2_otdelka_pol = calc2_pol_kovr; break;
1443			case 3: calc2_otdelka_pol = calc2_pol_lin; break;
1444			case 4: calc2_otdelka_pol = calc2_pol_par_dos; break;
1445			case 5: calc2_otdelka_pol = calc2_pol_par; break;
1446			case 6: calc2_otdelka_pol = calc2_pol_ker_pl; break;
1447			case 7: calc2_otdelka_pol = calc2_pol_keramo; break;
1448			case 8: calc2_otdelka_pol = calc2_pol_probka; break;
1449			case 9: calc2_otdelka_pol = calc2_pol_naliv; break;
1450		}
1451		calc2_raboty_pol = parseInt(calc2_s_pol * (calc2_pol_rovno + calc2_teplyy_pol + calc2_otdelka_pol));
1452		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1453		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1454		calc2_itog = parseInt(calc2_raboty + calc2_material);
1455		$("#calc2_rez_s_stena").html(calc2_s_sten);
1456		$("#calc2_rez_s_pol").html(calc2_s_pol);
1457		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1458		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1459		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1460		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1461		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1462		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1463		$("#calc2_raboty").html(calc2_raboty);
1464		$("#calc2_material").html(calc2_material);
1465		$("#calc2_itog").html(calc2_itog);
1466	});
1467	$("#calc2_steny_rovno_shukaturka").change(function(){
1468		calc2_steny_rovno = calc2_steny_rovno_shukaturka;
1469		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1470		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1471		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1472		calc2_itog = parseInt(calc2_raboty + calc2_material);
1473		$("#calc2_rez_s_stena").html(calc2_s_sten);
1474		$("#calc2_rez_s_pol").html(calc2_s_pol);
1475		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1476		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1477		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1478		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1479		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1480		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1481		$("#calc2_raboty").html(calc2_raboty);
1482		$("#calc2_material").html(calc2_material);
1483		$("#calc2_itog").html(calc2_itog);
1484	});
1485	$("#calc2_steny_rovno_glk").change(function(){
1486		calc2_steny_rovno = calc2_steny_rovno_glk;
1487		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1488		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1489		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1490		calc2_itog = parseInt(calc2_raboty + calc2_material);
1491		$("#calc2_rez_s_stena").html(calc2_s_sten);
1492		$("#calc2_rez_s_pol").html(calc2_s_pol);
1493		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1494		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1495		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1496		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1497		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1498		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1499		$("#calc2_raboty").html(calc2_raboty);
1500		$("#calc2_material").html(calc2_material);
1501		$("#calc2_itog").html(calc2_itog);
1502	});
1503	$("#calc2_steny_rovno_no").change(function(){
1504		calc2_steny_rovno = calc2_steny_rovno_no;
1505		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1506		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1507		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1508		calc2_itog = parseInt(calc2_raboty + calc2_material);
1509		$("#calc2_rez_s_stena").html(calc2_s_sten);
1510		$("#calc2_rez_s_pol").html(calc2_s_pol);
1511		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1512		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1513		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1514		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1515		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1516		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1517		$("#calc2_raboty").html(calc2_raboty);
1518		$("#calc2_material").html(calc2_material);
1519		$("#calc2_itog").html(calc2_itog);
1520	});
1521	$("#calc2_otdelka_sten").change(function(){
1522		select_otdelka_sten = parseInt($("select#calc2_otdelka_sten").val());
1523		switch(select_otdelka_sten){
1524			case 1: calc2_otdelka_sten = calc2_steny_sh_oboi; break;
1525			case 2: calc2_otdelka_sten = calc2_steny_oboi_pokr; break;
1526			case 3: calc2_otdelka_sten = calc2_steny_sh_pokr; break;
1527			case 4: calc2_otdelka_sten = calc2_steny_dec_sh; break;
1528			case 5: calc2_otdelka_sten = calc2_steny_pvkh; break;
1529			case 6: calc2_otdelka_sten = calc2_steny_kep_pl; break;
1530			case 7: calc2_otdelka_sten = calc2_steny_moz; break;
1531			case 8: calc2_otdelka_sten = calc2_steny_vag; break;
1532		}
1533		calc2_raboty_stena = parseInt(calc2_s_sten * (calc2_steny_rovno + calc2_otdelka_sten));
1534		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1535		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1536		calc2_itog = parseInt(calc2_raboty + calc2_material);
1537		$("#calc2_rez_s_stena").html(calc2_s_sten);
1538		$("#calc2_rez_s_pol").html(calc2_s_pol);
1539		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1540		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1541		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1542		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1543		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1544		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1545		$("#calc2_raboty").html(calc2_raboty);
1546		$("#calc2_material").html(calc2_material);
1547		$("#calc2_itog").html(calc2_itog);
1548	});
1549	$("#calc2_okna_kol_1").change(function(){
1550		calc2_okna_kol = calc2_okna_kol_1;
1551		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1552		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1553		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1554		calc2_itog = parseInt(calc2_raboty + calc2_material);
1555		$("#calc2_rez_s_stena").html(calc2_s_sten);
1556		$("#calc2_rez_s_pol").html(calc2_s_pol);
1557		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1558		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1559		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1560		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1561		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1562		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1563		$("#calc2_raboty").html(calc2_raboty);
1564		$("#calc2_material").html(calc2_material);
1565		$("#calc2_itog").html(calc2_itog);
1566	});
1567	$("#calc2_okna_kol_2").change(function(){
1568		calc2_okna_kol = calc2_okna_kol_2;
1569		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1570		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1571		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1572		calc2_itog = parseInt(calc2_raboty + calc2_material);
1573		$("#calc2_rez_s_stena").html(calc2_s_sten);
1574		$("#calc2_rez_s_pol").html(calc2_s_pol);
1575		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1576		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1577		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1578		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1579		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1580		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1581		$("#calc2_raboty").html(calc2_raboty);
1582		$("#calc2_material").html(calc2_material);
1583		$("#calc2_itog").html(calc2_itog);
1584	});
1585	$("#calc2_okna_kol_3").change(function(){
1586		calc2_okna_kol = calc2_okna_kol_3;
1587		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1588		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1589		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1590		calc2_itog = parseInt(calc2_raboty + calc2_material);
1591		$("#calc2_rez_s_stena").html(calc2_s_sten);
1592		$("#calc2_rez_s_pol").html(calc2_s_pol);
1593		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1594		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1595		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1596		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1597		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1598		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1599		$("#calc2_raboty").html(calc2_raboty);
1600		$("#calc2_material").html(calc2_material);
1601		$("#calc2_itog").html(calc2_itog);
1602	});
1603	$("#calc2_okna_kol_4").change(function(){
1604		calc2_okna_kol = calc2_okna_kol_4;
1605		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1606		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1607		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1608		calc2_itog = parseInt(calc2_raboty + calc2_material);
1609		$("#calc2_rez_s_stena").html(calc2_s_sten);
1610		$("#calc2_rez_s_pol").html(calc2_s_pol);
1611		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1612		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1613		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1614		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1615		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1616		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1617		$("#calc2_raboty").html(calc2_raboty);
1618		$("#calc2_material").html(calc2_material);
1619		$("#calc2_itog").html(calc2_itog);
1620	});
1621	$("#calc2_okna_kol_no").change(function(){
1622		calc2_okna_kol = calc2_okna_kol_no;
1623		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1624		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1625		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1626		calc2_itog = parseInt(calc2_raboty + calc2_material);
1627		$("#calc2_rez_s_stena").html(calc2_s_sten);
1628		$("#calc2_rez_s_pol").html(calc2_s_pol);
1629		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1630		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1631		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1632		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1633		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1634		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1635		$("#calc2_raboty").html(calc2_raboty);
1636		$("#calc2_material").html(calc2_material);
1637		$("#calc2_itog").html(calc2_itog);
1638	});
1639	$("#calc2_ust_okna").change(function(){
1640		select_ust_okna = parseInt($("select#calc2_ust_okna").val());
1641		switch(select_ust_okna){
1642			case 1: calc2_ust_okna = calc2_okna_met; break;
1643			case 2: calc2_ust_okna = calc2_okna_der; break;
1644			case 3: calc2_ust_okna = calc2_okna_komb; break;
1645		}
1646		calc2_raboty_okno = parseInt(calc2_okna_kol * calc2_ust_okna);
1647		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1648		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1649		calc2_itog = parseInt(calc2_raboty + calc2_material);
1650		$("#calc2_rez_s_stena").html(calc2_s_sten);
1651		$("#calc2_rez_s_pol").html(calc2_s_pol);
1652		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1653		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1654		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1655		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1656		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1657		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1658		$("#calc2_raboty").html(calc2_raboty);
1659		$("#calc2_material").html(calc2_material);
1660		$("#calc2_itog").html(calc2_itog);
1661	});
1662	$("#calc2_dveri_kol_1").change(function(){
1663		calc2_dveri_kol = calc2_dveri_kol_1;
1664		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1665		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1666		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1667		calc2_itog = parseInt(calc2_raboty + calc2_material);
1668		$("#calc2_rez_s_stena").html(calc2_s_sten);
1669		$("#calc2_rez_s_pol").html(calc2_s_pol);
1670		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1671		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1672		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1673		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1674		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1675		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1676		$("#calc2_raboty").html(calc2_raboty);
1677		$("#calc2_material").html(calc2_material);
1678		$("#calc2_itog").html(calc2_itog);
1679	});
1680	$("#calc2_dveri_kol_2").change(function(){
1681		calc2_dveri_kol = calc2_dveri_kol_2;
1682		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1683		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1684		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1685		calc2_itog = parseInt(calc2_raboty + calc2_material);
1686		$("#calc2_rez_s_stena").html(calc2_s_sten);
1687		$("#calc2_rez_s_pol").html(calc2_s_pol);
1688		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1689		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1690		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1691		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1692		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1693		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1694		$("#calc2_raboty").html(calc2_raboty);
1695		$("#calc2_material").html(calc2_material);
1696		$("#calc2_itog").html(calc2_itog);
1697	});
1698	$("#calc2_dveri_kol_3").change(function(){
1699		calc2_dveri_kol = calc2_dveri_kol_3;
1700		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1701		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1702		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1703		calc2_itog = parseInt(calc2_raboty + calc2_material);
1704		$("#calc2_rez_s_stena").html(calc2_s_sten);
1705		$("#calc2_rez_s_pol").html(calc2_s_pol);
1706		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1707		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1708		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1709		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1710		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1711		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1712		$("#calc2_raboty").html(calc2_raboty);
1713		$("#calc2_material").html(calc2_material);
1714		$("#calc2_itog").html(calc2_itog);
1715	});
1716	$("#calc2_dveri_kol_4").change(function(){
1717		calc2_dveri_kol = calc2_dveri_kol_4;
1718		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1719		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1720		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1721		calc2_itog = parseInt(calc2_raboty + calc2_material);
1722		$("#calc2_rez_s_stena").html(calc2_s_sten);
1723		$("#calc2_rez_s_pol").html(calc2_s_pol);
1724		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1725		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1726		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1727		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1728		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1729		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1730		$("#calc2_raboty").html(calc2_raboty);
1731		$("#calc2_material").html(calc2_material);
1732		$("#calc2_itog").html(calc2_itog);
1733	});
1734	$("#calc2_dveri_kol_no").change(function(){
1735		calc2_dveri_kol = calc2_dveri_kol_no;
1736		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1737		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1738		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1739		calc2_itog = parseInt(calc2_raboty + calc2_material);
1740		$("#calc2_rez_s_stena").html(calc2_s_sten);
1741		$("#calc2_rez_s_pol").html(calc2_s_pol);
1742		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1743		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1744		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1745		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1746		$("#calc2_raboty_okno").html(calc2_raboty_
1746okno);
1747		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1748		$("#calc2_raboty").html(calc2_raboty);
1749		$("#calc2_material").html(calc2_material);
1750		$("#calc2_itog").html(calc2_itog);
1751	});
1752	$("#calc2_ust_dver").change(function(){
1753		select_ust_dver = parseInt($("select#calc2_ust_dver").val());
1754		switch(select_ust_dver){
1755			case 1: calc2_ust_dver = calc2_ust_dver_m_sh; break;
1756			case 2: calc2_ust_dver = calc2_ust_dver_m_m; break;
1757			case 3: calc2_ust_dver = calc2_ust_dver_vkh; break;
1758		}
1759		calc2_raboty_dver = parseInt(calc2_dveri_kol * calc2_ust_dver);
1760		calc2_raboty = parseInt(calc2_raboty_potolok + calc2_raboty_pol + calc2_raboty_stena + calc2_raboty_okno + calc2_raboty_dver);
1761		calc2_material = parseInt(calc2_raboty * calc2_ch_mat);
1762		calc2_itog = parseInt(calc2_raboty + calc2_material);
1763		$("#calc2_rez_s_stena").html(calc2_s_sten);
1764		$("#calc2_rez_s_pol").html(calc2_s_pol);
1765		$("#calc2_rez_s_potolok").html(calc2_s_potolok);
1766		$("#calc2_raboty_potolok").html(calc2_raboty_potolok);
1767		$("#calc2_raboty_pol").html(calc2_raboty_pol);
1768		$("#calc2_raboty_stena").html(calc2_raboty_stena);
1769		$("#calc2_raboty_okno").html(calc2_raboty_okno);
1770		$("#calc2_raboty_dver").html(calc2_raboty_dver);
1771		$("#calc2_raboty").html(calc2_raboty);
1772		$("#calc2_material").html(calc2_material);
1773		$("#calc2_itog").html(calc2_itog);
1774	});
1775	
1776	//Change repair 
1777	$(".btn_work").click(function(){
1778		if($(this).text() == "Смотреть все работы"){$(this).text("Свернуть")}
1779			else{$(this).text("Смотреть все работы");}
1780	});
1781	$("#button_raboty_kosm").click(function(){$('#raboty_kosm_no').slideToggle('slow');});
1782	$("#button_raboty_kap").click(function(){$('#raboty_kap_no').slideToggle('slow');});
1783	$("#button_raboty_evro").click(function(){$('#raboty_evro_no').slideToggle('slow');});
1784});
1785/* End */
1786;
1787; /* Start:"a:4:{s:4:"full";s:90:"/local/templates/gvozdevsoft_profigs_s1/lib/inputmask/jquery.inputmask.js?1738274368220934";s:6:"source";s:73:"/local/templates/gvozdevsoft_profigs_s1/lib/inputmask/jquery.inputmask.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
1788/*!
1789* jquery.inputmask.bundle.js
1790* https://github.com/RobinHerbots/Inputmask
1791* Copyright (c) 2010 - 2019 Robin Herbots
1792* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
1793* Version: 4.0.6
1794*/
1795
1796(function(modules) {
1797    var installedModules = {};
1798    function __webpack_require__(moduleId) {
1799        if (installedModules[moduleId]) {
1800            return installedModules[moduleId].exports;
1801        }
1802        var module = installedModules[moduleId] = {
1803            i: moduleId,
1804            l: false,
1805            exports: {}
1806        };
1807        modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
1808        module.l = true;
1809        return module.exports;
1810    }
1811    __webpack_require__.m = modules;
1812    __webpack_require__.c = installedModules;
1813    __webpack_require__.d = function(exports, name, getter) {
1814        if (!__webpack_require__.o(exports, name)) {
1815            Object.defineProperty(exports, name, {
1816                enumerable: true,
1817                get: getter
1818            });
1819        }
1820    };
1821    __webpack_require__.r = function(exports) {
1822        if (typeof Symbol !== "undefined" && Symbol.toStringTag) {
1823            Object.defineProperty(exports, Symbol.toStringTag, {
1824                value: "Module"
1825            });
1826        }
1827        Object.defineProperty(exports, "__esModule", {
1828            value: true
1829        });
1830    };
1831    __webpack_require__.t = function(value, mode) {
1832        if (mode & 1) value = __webpack_require__(value);
1833        if (mode & 8) return value;
1834        if (mode & 4 && typeof value === "object" && value && value.__esModule) return value;
1835        var ns = Object.create(null);
1836        __webpack_require__.r(ns);
1837        Object.defineProperty(ns, "default", {
1838            enumerable: true,
1839            value: value
1840        });
1841        if (mode & 2 && typeof value != "string") for (var key in value) __webpack_require__.d(ns, key, function(key) {
1842            return value[key];
1843        }.bind(null, key));
1844        return ns;
1845    };
1846    __webpack_require__.n = function(module) {
1847        var getter = module && module.__esModule ? function getDefault() {
1848            return module["default"];
1849        } : function getModuleExports() {
1850            return module;
1851        };
1852        __webpack_require__.d(getter, "a", getter);
1853        return getter;
1854    };
1855    __webpack_require__.o = function(object, property) {
1856        return Object.prototype.hasOwnProperty.call(object, property);
1857    };
1858    __webpack_require__.p = "";
1859    return __webpack_require__(__webpack_require__.s = 0);
1860})([ function(module, exports, __webpack_require__) {
1861    "use strict";
1862    __webpack_require__(1);
1863    __webpack_require__(6);
1864    __webpack_require__(7);
1865    var _inputmask = __webpack_require__(2);
1866    var _inputmask2 = _interopRequireDefault(_inputmask);
1867    var _inputmask3 = __webpack_require__(3);
1868    var _inputmask4 = _interopRequireDefault(_inputmask3);
1869    var _jquery = __webpack_require__(4);
1870    var _jquery2 = _interopRequireDefault(_jquery);
1871    function _interopRequireDefault(obj) {
1872        return obj && obj.__esModule ? obj : {
1873            default: obj
1874        };
1875    }
1876    if (_inputmask4.default === _jquery2.default) {
1877        __webpack_require__(8);
1878    }
1879    window.Inputmask = _inputmask2.default;
1880}, function(module, exports, __webpack_require__) {
1881    "use strict";
1882    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
1883    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
1884        return typeof obj;
1885    } : function(obj) {
1886        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
1887    };
1888    (function(factory) {
1889        if (true) {
1890            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(2) ], __WEBPACK_AMD_DEFINE_FACTORY__ = factory, 
1891            __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
1892            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
1893        } else {}
1894    })(function(Inputmask) {
1895        Inputmask.extendDefinitions({
1896            A: {
1897                validator: "[A-Za-z\u0410-\u044f\u0401\u0451\xc0-\xff\xb5]",
1898                casing: "upper"
1899            },
1900            "&": {
1901                validator: "[0-9A-Za-z\u0410-\u044f\u0401\u0451\xc0-\xff\xb5]",
1902                casing: "upper"
1903            },
1904            "#": {
1905                validator: "[0-9A-Fa-f]",
1906                casing: "upper"
1907            }
1908        });
1909        Inputmask.extendAliases({
1910            cssunit: {
1911                regex: "[+-]?[0-9]+\\.?([0-9]+)?(px|em|rem|ex|%|in|cm|mm|pt|pc)"
1912            },
1913            url: {
1914                regex: "(https?|ftp)//.*",
1915                autoUnmask: false
1916            },
1917            ip: {
1918                mask: "i[i[i]].i[i[i]].i[i[i]].i[i[i]]",
1919                definitions: {
1920                    i: {
1921                        validator: function validator(chrs, maskset, pos, strict, opts) {
1922                            if (pos - 1 > -1 && maskset.buffer[pos - 1] !== ".") {
1923                                chrs = maskset.buffer[pos - 1] + chrs;
1924                                if (pos - 2 > -1 && maskset.buffer[pos - 2] !== ".") {
1925                                    chrs = maskset.buffer[pos - 2] + chrs;
1926                                } else chrs = "0" + chrs;
1927                            } else chrs = "00" + chrs;
1928                            return new RegExp("25[0-5]|2[0-4][0-9]|[01][0-9][0-9]").test(chrs);
1929                        }
1930                    }
1931                },
1932                onUnMask: function onUnMask(maskedValue, unmaskedValue, opts) {
1933                    return maskedValue;
1934                },
1935                inputmode: "numeric"
1936            },
1937            email: {
1938                mask: "*{1,64}[.*{1,64}][.*{1,64}][.*{1,63}]@-{1,63}.-{1,63}[.-{1,63}][.-{1,63}]",
1939                greedy: false,
1940                casing: "lower",
1941                onBeforePaste: function onBeforePaste(pastedValue, opts) {
1942                    pastedValue = pastedValue.toLowerCase();
1943                    return pastedValue.replace("mailto:", "");
1944                },
1945                definitions: {
1946                    "*": {
1947                        validator: "[0-9\uff11-\uff19A-Za-z\u0410-\u044f\u0401\u0451\xc0-\xff\xb5!#$%&'*+/=?^_`{|}~-]"
1948                    },
1949                    "-": {
1950                        validator: "[0-9A-Za-z-]"
1951                    }
1952                },
1953                onUnMask: function onUnMask(maskedValue, unmaskedValue, opts) {
1954                    return maskedValue;
1955                },
1956                inputmode: "email"
1957            },
1958            mac: {
1959                mask: "##:##:##:##:##:##"
1960            },
1961            vin: {
1962                mask: "V{13}9{4}",
1963                definitions: {
1964                    V: {
1965                        validator: "[A-HJ-NPR-Za-hj-npr-z\\d]",
1966                        casing: "upper"
1967                    }
1968                },
1969                clearIncomplete: true,
1970                autoUnmask: true
1971            }
1972        });
1973        return Inputmask;
1974    });
1975}, function(module, exports, __webpack_require__) {
1976    "use strict";
1977    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
1978    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
1979        return typeof obj;
1980    } : function(obj) {
1981        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
1982    };
1983    (function(factory) {
1984        if (true) {
1985            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(3), __webpack_require__(5) ], 
1986            __WEBPACK_AMD_DEFINE_FACTORY__ = factory, __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
1987            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
1988        } else {}
1989    })(function($, window, undefined) {
1990        var document = window.document, ua = navigator.userAgent, ie = ua.indexOf("MSIE ") > 0 || ua.indexOf("Trident/") > 0, mobile = isInputEventSupported("touchstart"), iemobile = /iemobile/i.test(ua), iphone = /iphone/i.test(ua) && !iemobile;
1991        function Inputmask(alias, options, internal) {
1992            if (!(this instanceof Inputmask)) {
1993                return new Inputmask(alias, options, internal);
1994            }
1995            this.el = undefined;
1996            this.events = {};
1997            this.maskset = undefined;
1998            this.refreshValue = false;
1999            if (internal !== true) {
2000                if ($.isPlainObject(alias)) {
2001                    options = alias;
2002                } else {
2003                    options = options || {};
2004                    if (alias) options.alias = alias;
2005                }
2006                this.opts = $.extend(true, {}, this.defaults, options);
2007                this.noMasksCache = options && options.definitions !== undefined;
2008                this.userOptions = options || {};
2009                this.isRTL = this.opts.numericInput;
2010                resolveAlias(this.opts.alias, options, this.opts);
2011            }
2012        }
2013        Inputmask.prototype = {
2014            dataAttribute: "data-inputmask",
2015            defaults: {
2016                placeholder: "_",
2017                optionalmarker: [ "[", "]" ],
2018                quantifiermarker: [ "{", "}" ],
2019                groupmarker: [ "(", ")" ],
2020                alternatormarker: "|",
2021                escapeChar: "\\",
2022                mask: null,
2023                regex: null,
2024                oncomplete: $.noop,
2025                onincomplete: $.noop,
2026                oncleared: $.noop,
2027                repeat: 0,
2028                greedy: false,
2029                autoUnmask: false,
2030                removeMaskOnSubmit: false,
2031                clearMaskOnLostFocus: true,
2032                insertMode: true,
2033                clearIncomplete: false,
2034                alias: null,
2035                onKeyDown: $.noop,
2036                onBeforeMask: null,
2037                onBeforePaste: function onBeforePaste(pastedValue, opts) {
2038                    return $.isFunction(opts.onBeforeMask) ? opts.onBeforeMask.call(this, pastedValue, opts) : pastedValue;
2039                },
2040                onBeforeWrite: null,
2041                onUnMask: null,
2042                showMaskOnFocus: true,
2043                showMaskOnHover: true,
2044                onKeyValidation: $.noop,
2045                skipOptionalPartCharacter: " ",
2046                numericInput: false,
2047                rightAlign: false,
2048                undoOnEscape: true,
2049                radixPoint: "",
2050                _radixDance: false,
2051                groupSeparator: "",
2052                keepStatic: null,
2053                positionCaretOnTab: true,
2054                tabThrough: false,
2055                supportsInputType: [ "text", "tel", "url", "password", "search" ],
2056                ignorables: [ 8, 9, 13, 19, 27, 33, 34, 35, 36, 37, 38, 39, 40, 45, 46, 93, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 0, 229 ],
2057                isComplete: null,
2058                preValidation: null,
2059                postValidation: null,
2060                staticDefinitionSymbol: undefined,
2061                jitMasking: false,
2062                nullable: true,
2063                inputEventOnly: false,
2064                noValuePatching: false,
2065                positionCaretOnClick: "lvp",
2066                casing: null,
2067                inputmode: "verbatim",
2068                colorMask: false,
2069                disablePredictiveText: false,
2070                importDataAttributes: true,
2071                shiftPositions: true
2072            },
2073            definitions: {
2074                9: {
2075                    validator: "[0-9\uff11-\uff19]",
2076                    definitionSymbol: "*"
2077                },
2078                a: {
2079                    validator: "[A-Za-z\u0410-\u044f\u0401\u0451\xc0-\xff\xb5]",
2080                    definitionSymbol: "*"
2081                },
2082                "*": {
2083                    validator: "[0-9\uff11-\uff19A-Za-z\u0410-\u044f\u0401\u0451\xc0-\xff\xb5]"
2084                }
2085            },
2086            aliases: {},
2087            masksCache: {},
2088            mask: function mask(elems) {
2089                var that = this;
2090                function importAttributeOptions(npt, opts, userOptions, dataAttribute) {
2091                    if (opts.importDataAttributes === true) {
2092                        var importOption = function importOption(option, optionData) {
2093                            optionData = optionData !== undefined ? optionData : npt.getAttribute(dataAttribute + "-" + option);
2094                            if (optionData !== null) {
2095                                if (typeof optionData === "string") {
2096                                    if (option.indexOf("on") === 0) optionData = window[optionData];
2096 else if (optionData === "false") optionData = false; else if (optionData === "true") optionData = true;
2097                                }
2098                                userOptions[option] = optionData;
2099                            }
2100                        };
2101                        var attrOptions = npt.getAttribute(dataAttribute), option, dataoptions, optionData, p;
2102                        if (attrOptions && attrOptions !== "") {
2103                            attrOptions = attrOptions.replace(/'/g, '"');
2104                            dataoptions = JSON.parse("{" + attrOptions + "}");
2105                        }
2106                        if (dataoptions) {
2107                            optionData = undefined;
2108                            for (p in dataoptions) {
2109                                if (p.toLowerCase() === "alias") {
2110                                    optionData = dataoptions[p];
2111                                    break;
2112                                }
2113                            }
2114                        }
2115                        importOption("alias", optionData);
2116                        if (userOptions.alias) {
2117                            resolveAlias(userOptions.alias, userOptions, opts);
2118                        }
2119                        for (option in opts) {
2120                            if (dataoptions) {
2121                                optionData = undefined;
2122                                for (p in dataoptions) {
2123                                    if (p.toLowerCase() === option.toLowerCase()) {
2124                                        optionData = dataoptions[p];
2125                                        break;
2126                                    }
2127                                }
2128                            }
2129                            importOption(option, optionData);
2130                        }
2131                    }
2132                    $.extend(true, opts, userOptions);
2133                    if (npt.dir === "rtl" || opts.rightAlign) {
2134                        npt.style.textAlign = "right";
2135                    }
2136                    if (npt.dir === "rtl" || opts.numericInput) {
2137                        npt.dir = "ltr";
2138                        npt.removeAttribute("dir");
2139                        opts.isRTL = true;
2140                    }
2141                    return Object.keys(userOptions).length;
2142                }
2143                if (typeof elems === "string") {
2144                    elems = document.getElementById(elems) || document.querySelectorAll(elems);
2145                }
2146                elems = elems.nodeName ? [ elems ] : elems;
2147                $.each(elems, function(ndx, el) {
2148                    var scopedOpts = $.extend(true, {}, that.opts);
2149                    if (importAttributeOptions(el, scopedOpts, $.extend(true, {}, that.userOptions), that.dataAttribute)) {
2150                        var maskset = generateMaskSet(scopedOpts, that.noMasksCache);
2151                        if (maskset !== undefined) {
2152                            if (el.inputmask !== undefined) {
2153                                el.inputmask.opts.autoUnmask = true;
2154                                el.inputmask.remove();
2155                            }
2156                            el.inputmask = new Inputmask(undefined, undefined, true);
2157                            el.inputmask.opts = scopedOpts;
2158                            el.inputmask.noMasksCache = that.noMasksCache;
2159                            el.inputmask.userOptions = $.extend(true, {}, that.userOptions);
2160                            el.inputmask.isRTL = scopedOpts.isRTL || scopedOpts.numericInput;
2161                            el.inputmask.el = el;
2162                            el.inputmask.maskset = maskset;
2163                            $.data(el, "_inputmask_opts", scopedOpts);
2164                            maskScope.call(el.inputmask, {
2165                                action: "mask"
2166                            });
2167                        }
2168                    }
2169                });
2170                return elems && elems[0] ? elems[0].inputmask || this : this;
2171            },
2172            option: function option(options, noremask) {
2173                if (typeof options === "string") {
2174                    return this.opts[options];
2175                } else if ((typeof options === "undefined" ? "undefined" : _typeof(options)) === "object") {
2176                    $.extend(this.userOptions, options);
2177                    if (this.el && noremask !== true) {
2178                        this.mask(this.el);
2179                    }
2180                    return this;
2181                }
2182            },
2183            unmaskedvalue: function unmaskedvalue(value) {
2184                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2185                return maskScope.call(this, {
2186                    action: "unmaskedvalue",
2187                    value: value
2188                });
2189            },
2190            remove: function remove() {
2191                return maskScope.call(this, {
2192                    action: "remove"
2193                });
2194            },
2195            getemptymask: function getemptymask() {
2196                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2197                return maskScope.call(this, {
2198                    action: "getemptymask"
2199                });
2200            },
2201            hasMaskedValue: function hasMaskedValue() {
2202                return !this.opts.autoUnmask;
2203            },
2204            isComplete: function isComplete() {
2205                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2206                return maskScope.call(this, {
2207                    action: "isComplete"
2208                });
2209            },
2210            getmetadata: function getmetadata() {
2211                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2212                return maskScope.call(this, {
2213                    action: "getmetadata"
2214                });
2215            },
2216            isValid: function isValid(value) {
2217                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2218                return maskScope.call(this, {
2219                    action: "isValid",
2220                    value: value
2221                });
2222            },
2223            format: function format(value, metadata) {
2224                this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache);
2225                return maskScope.call(this, {
2226                    action: "format",
2227                    value: value,
2228                    metadata: metadata
2229                });
2230            },
2231            setValue: function setValue(value) {
2232                if (this.el) {
2233                    $(this.el).trigger("setvalue", [ value ]);
2234                }
2235            },
2236            analyseMask: function analyseMask(mask, regexMask, opts) {
2237                var tokenizer = /(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?(?:\|[0-9\+\*]*)?\})|[^.?*+^${[]()|\\]+|./g, regexTokenizer = /\[\^?]?(?:[^\\\]]+|\\[\S\s]?)*]?|\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9][0-9]*|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|c[A-Za-z]|[\S\s]?)|\((?:\?[:=!]?)?|(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[()|\\]+|./g, escaped = false, currentToken = new MaskToken(), match, m, openenings = [], maskTokens = [], openingToken, currentOpeningToken, alternator, lastMatch, groupToken;
2238                function MaskToken(isGroup, isOptional, isQuantifier, isAlternator) {
2239                    this.matches = [];
2240                    this.openGroup = isGroup || false;
2241                    this.alternatorGroup = false;
2242                    this.isGroup = isGroup || false;
2243                    this.isOptional = isOptional || false;
2244                    this.isQuantifier = isQuantifier || false;
2245                    this.isAlternator = isAlternator || false;
2246                    this.quantifier = {
2247                        min: 1,
2248                        max: 1
2249                    };
2250                }
2251                function insertTestDefinition(mtoken, element, position) {
2252                    position = position !== undefined ? position : mtoken.matches.length;
2253                    var prevMatch = mtoken.matches[position - 1];
2254                    if (regexMask) {
2255                        if (element.indexOf("[") === 0 || escaped && /\\d|\\s|\\w]/i.test(element) || element === ".") {
2256                            mtoken.matches.splice(position++, 0, {
2257                                fn: new RegExp(element, opts.casing ? "i" : ""),
2258                                optionality: false,
2259                                newBlockMarker: prevMatch === undefined ? "master" : prevMatch.def !== element,
2260                                casing: null,
2261                                def: element,
2262                                placeholder: undefined,
2263                                nativeDef: element
2264                            });
2265                        } else {
2266                            if (escaped) element = element[element.length - 1];
2267                            $.each(element.split(""), function(ndx, lmnt) {
2268                                prevMatch = mtoken.matches[position - 1];
2269                                mtoken.matches.splice(position++, 0, {
2270                                    fn: null,
2271                                    optionality: false,
2272                                    newBlockMarker: prevMatch === undefined ? "master" : prevMatch.def !== lmnt && prevMatch.fn !== null,
2273                                    casing: null,
2274                                    def: opts.staticDefinitionSymbol || lmnt,
2275                                    placeholder: opts.staticDefinitionSymbol !== undefined ? lmnt : undefined,
2276                                    nativeDef: (escaped ? "'" : "") + lmnt
2277                                });
2278                            });
2279                        }
2280                        escaped = false;
2281                    } else {
2282                        var maskdef = (opts.definitions ? opts.definitions[element] : undefined) || Inputmask.prototype.definitions[element];
2283                        if (maskdef && !escaped) {
2284                            mtoken.matches.splice(position++, 0, {
2285                                fn: maskdef.validator ? typeof maskdef.validator == "string" ? new RegExp(maskdef.validator, opts.casing ? "i" : "") : new function() {
2286                                    this.test = maskdef.validator;
2287                                }() : new RegExp("."),
2288                                optionality: false,
2289                                newBlockMarker: prevMatch === undefined ? "master" : prevMatch.def !== (maskdef.definitionSymbol || element),
2290                                casing: maskdef.casing,
2291                                def: maskdef.definitionSymbol || element,
2292                                placeholder: maskdef.placeholder,
2293                                nativeDef: element
2294                            });
2295                        } else {
2296                            mtoken.matches.splice(position++, 0, {
2297                                fn: null,
2298                                optionality: false,
2299                                newBlockMarker: prevMatch === undefined ? "master" : prevMatch.def !== element && prevMatch.fn !== null,
2300                                casing: null,
2301                                def: opts.staticDefinitionSymbol || element,
2302                                placeholder: opts.staticDefinitionSymbol !== undefined ? element : undefined,
2303                                nativeDef: (escaped ? "'" : "") + element
2304                            });
2305                            escaped = false;
2306                        }
2307                    }
2308                }
2309                function verifyGroupMarker(maskToken) {
2310                    if (maskToken && maskToken.matches) {
2311                        $.each(maskToken.matches, function(ndx, token) {
2312                            var nextToken = maskToken.matches[ndx + 1];
2313                            if ((nextToken === undefined || nextToken.matches === undefined || nextToken.isQuantifier === false) && token && token.isGroup) {
2314                                token.isGroup = false;
2315                                if (!regexMask) {
2316                                    insertTestDefinition(token, opts.groupmarker[0], 0);
2317                                    if (token.openGroup !== true) {
2318                                        insertTestDefinition(token, opts.groupmarker[1]);
2319                                    }
2320                                }
2321                            }
2322                            verifyGroupMarker(token);
2323                        });
2324                    }
2325                }
2326                function defaultCase() {
2327                    if (openenings.length > 0) {
2328                        currentOpeningToken = openenings[openenings.length - 1];
2329                        insertTestDefinition(currentOpeningToken, m);
2330                        if (currentOpeningToken.isAlternator) {
2331                            alternator = openenings.pop();
2332                            for (var mndx = 0; mndx < alternator.matches.length; mndx++) {
2333                                if (alternator.matches[mndx].isGroup) alternator.matches[mndx].isGroup = false;
2334                            }
2335                            if (openenings.length > 0) {
2336                                currentOpeningToken = openenings[openenings.length - 1];
2337                                currentOpeningToken.matches.push(alternator);
2338                            } else {
2339                                currentToken.matches.push(alternator);
2340                            }
2341                        }
2342                    } else {
2343                        insertTestDefinition(currentToken, m);
2344                    }
2345                }
2346                function reverseTokens(maskToken) {
2347                    function reverseStatic(st) {
2348                        if (st === opts.optionalmarker[0]) st = opts.optionalmarker[1]; else if (st === opts.optionalmarker[1]) st = opts.optionalmarker[0]; else if (st === opts.groupmarker[0]) st = opts.groupmarker[1]; else if (st === opts.groupmarker[1]) st = opts.groupmarker[0];
2349                        return st;
2350                    }
2351                    maskToken.matches = maskToken.matches.reverse();
2352                    for (var match in maskToken.matches) {
2353                        if (maskToken.matches.hasOwnProperty(match)) {
2354                            var intMatch = parseInt(match);
2355                            if (maskToken.matches[match].isQuantifier && maskToken.matches[intMatch + 1] && maskToken.matches[intMatch + 1].isGroup) {
2356                                var qt = maskToken.matches[match];
2357                                maskToken.matches.splice(match, 1);
2358                                maskToken.matches.splice(intMatch + 1, 0, qt);
2359                            }
2360                            if (maskToken.matches[match].matches !== undefined) {
2361                                maskToken.matches[match] = reverseTokens(maskToken.matches[match]);
2362                            } else {
2363                                maskToken.matches[match] = reverseStatic(maskToken.matches[match]);
2364                            }
2365                        }
2366                    }
2367                    return maskToken;
2368                }
2369                function groupify(matches) {
2370                    var groupToken = new MaskToken(true);
2371                    groupToken.openGroup = false;
2372                    groupToken.matches = matches;
2373                    return groupToken;
2374                }
2375                if (regexMask) {
2376                    opts.optionalmarker[0] = undefined;
2377                    opts.optionalmarker[1] = undefined;
2378                }
2379                while (match = regexMask ? regexTokenizer.exec(mask) : tokenizer.exec(mask)) {
2380                    m = match[0];
2381                    if (regexMask) {
2382                        switch (m.charAt(0)) {
2383                          case "?":
2384                            m = "{0,1}";
2385                            break;
2386
2387                          case "+":
2388                          case "*":
2389                            m = "{" + m + "}";
2390                            break;
2391                        }
2392                    }
2393                    if (escaped) {
2394                        defaultCase();
2395                        continue;
2396                    }
2397                    switch (m.charAt(0)) {
2398                      case "(?=":
2399                        break;
2400
2401                      case "(?!":
2402                        break;
2403
2404                      case "(?<=":
2405                        break;
2406
2407                      case "(?<!":
2408                        break;
2409
2410                      case opts.escapeChar:
2411                        escaped = true;
2412                        if (regexMask) {
2413                            defaultCase();
2414                        }
2415                        break;
2416
2417                      case opts.optionalmarker[1]:
2418                      case opts.groupmarker[1]:
2419                        openingToken = openenings.pop();
2420                        openingToken.openGroup = false;
2421                        if (openingToken !== undefined) {
2422                            if (openenings.length > 0) {
2423                                currentOpeningToken = openenings[openenings.length - 1];
2424                                currentOpeningToken.matches.push(openingToken);
2425                                if (currentOpeningToken.isAlternator) {
2426                                    alternator = openenings.pop();
2427                                    for (var mndx = 0; mndx < alternator.matches.length; mndx++) {
2428                                        alternator.matches[mndx].isGroup = false;
2429                                        alternator.matches[mndx].alternatorGroup = false;
2430                                    }
2431                                    if (openenings.length > 0) {
2432                                        currentOpeningToken = openenings[openenings.length - 1];
2433                                        currentOpeningToken.matches.push(alternator);
2434                                    } else {
2435                                        currentToken.matches.push(alternator);
2436                                    }
2437                                }
2438                            } else {
2439                                currentToken.matches.push(openingToken);
2440                            }
2441                        } else defaultCase();
2442                        break;
2443
2444                      case opts.optionalmarker[0]:
2445                        openenings.push(new MaskToken(false, true));
2446                        break;
2447
2448                      case opts.groupmarker[0]:
2449                        openenings.push(new MaskToken(true));
2450                        break;
2451
2452                      case opts.quantifiermarker[0]:
2453                        var quantifier = new MaskToken(false, false, true);
2454                        m = m.replace(/[{}]/g, "");
2455                        var mqj = m.split("|"), mq = mqj[0].split(","), mq0 = isNaN(mq[0]) ? mq[0] : parseInt(mq[0]), mq1 = mq.length === 1 ? mq0 : isNaN(mq[1]) ? mq[1] : parseInt(mq[1]);
2456                        if (mq0 === "*" || mq0 === "+") {
2457                            mq0 = mq1 === "*" ? 0 : 1;
2458                        }
2459                        quantifier.quantifier = {
2460                            min: mq0,
2461                            max: mq1,
2462                            jit: mqj[1]
2463                        };
2464                        var matches = openenings.length > 0 ? openenings[openenings.length - 1].matches : currentToken.matches;
2465                        match = matches.pop();
2466                        if (match.isAlternator) {
2467                            matches.push(match);
2468                            matches = match.matches;
2469                            var groupToken = new MaskToken(true);
2470                            var tmpMatch = matches.pop();
2471                            matches.push(groupToken);
2472                            matches = groupToken.matches;
2473                            match = tmpMatch;
2474                        }
2475                        if (!match.isGroup) {
2476                            match = groupify([ match ]);
2477                        }
2478                        matches.push(match);
2479                        matches.push(quantifier);
2480                        break;
2481
2482                      case opts.alternatormarker:
2483                        var groupQuantifier = function groupQuantifier(matches) {
2484                            var lastMatch = matches.pop();
2485                            if (lastMatch.isQuantifier) {
2486                                lastMatch = groupify([ matches.pop(), lastMatch ]);
2487                            }
2488                            return lastMatch;
2489                        };
2490                        if (openenings.length > 0) {
2491                            currentOpeningToken = openenings[openenings.length - 1];
2492                            var subToken = currentOpeningToken.matches[currentOpeningToken.matches.length - 1];
2493                            if (currentOpeningToken.openGroup && (subToken.matches === undefined || subToken.isGroup === false && subToken.isAlternator === false)) {
2494                                lastMatch = openenings.pop();
2495                            } else {
2496                                lastMatch = groupQuantifier(currentOpeningToken.matches);
2497                            }
2498                        } else {
2499                            lastMatch = groupQuantifier(currentToken.matches);
2500                        }
2501                        if (lastMatch.isAlternator) {
2502                            openenings.push(lastMatch);
2503                        } else {
2504                            if (lastMatch.alternatorGroup) {
2505                                alternator = openenings.pop();
2506                                lastMatch.alternatorGroup = false;
2507                            } else {
2508                                alternator = new MaskToken(false, false, false, true);
2509                            }
2510                            alternator.matches.push(lastMatch);
2511                            openenings.push(alternator);
2512                            if (lastMatch.openGroup) {
2513                                lastMatch.openGroup = false;
2514                                var alternatorGroup = new MaskToken(true);
2515                                alternatorGroup.alternatorGroup = true;
2516                                openenings.push(alternatorGroup);
2517                            }
2518                        }
2519                        break;
2520
2521                      default:
2522                        defaultCase();
2523                    }
2524                }
2525                while (openenings.length > 0) {
2526                    openingToken = openenings.pop();
2527                    currentToken.matches.push(openingToken);
2528                }
2529                if (currentToken.matches.length > 0) {
2530                    verifyGroupMarker(currentToken);
2531                    maskTokens.push(currentToken);
2532                }
2533                if (opts.numericInput || opts.isRTL) {
2534                    reverseTokens(maskTokens[0]);
2535                }
2536                return maskTokens;
2537            }
2538        };
2539        Inputmask.extendDefaults = function(options) {
2540            $.extend(true, Inputmask.prototype.defaults, options);
2541        };
2542        Inputmask.extendDefinitions = function(definition) {
2543            $.extend(true, Inputmask.prototype.definitions, definition);
2544        };
2545        Inputmask.extendAliases = function(alias) {
2546            $.extend(true, Inputmask.prototype.aliases, alias);
2547        };
2548        Inputmask.format = function(value, options, metadata) {
2549            return Inputmask(options).format(value, metadata);
2550        };
2551        Inputmask.unmask = function(value, options) {
2552            return Inputmask(options).unmaskedvalue(value);
2553        };
2554        Inputmask.isValid = function(value, options) {
2555            return Inputmask(options).isValid(value);
2556        };
2557        Inputmask.remove = function(elems) {
2558            if (typeof elems === "string") {
2559                elems = document.getElementById(elems) || document.querySelectorAll(elems);
2560            }
2561            elems = elems.nodeName ? [ elems ] : elems;
2562            $.each(elems, function(ndx, el) {
2563                if (el.inputmask) el.inputmask.remove();
2564            });
2565        };
2566        Inputmask.setValue = function(elems, value) {
2567            if (typeof elems === "string") {
2568                elems = document.getElementById(elems) || document.querySelectorAll(elems);
2569            }
2570            elems = elems.nodeName ? [ elems ] : elems;
2571            $.each(elems, function(ndx, el) {
2572                if (el.inputmask) el.inputmask.setValue(value); else $(el).trigger("setvalue", [ value ]);
2573            });
2574        };
2575        Inputmask.escapeRegex = function(str) {
2576            var specials = [ "/", ".", "*", "+", "?", "|", "(", ")", "[", "]", "{", "}", "\\", "$", "^" ];
2577            return str.replace(new RegExp("(\\" + specials.join("|\\") + ")", "gim"), "\\$1");
2578        };
2579        Inputmask.keyCode = {
2580            BACKSPACE: 8,
2581            BACKSPACE_SAFARI: 127,
2582            DELETE: 46,
2583            DOWN: 40,
2584            END: 35,
2585            ENTER: 13,
2586            ESCAPE: 27,
2587            HOME: 36,
2588            INSERT: 45,
2589            LEFT: 37,
2590            PAGE_DOWN: 34,
2591            PAGE_UP: 33,
2592            RIGHT: 39,
2593            SPACE: 32,
2594            TAB: 9,
2595            UP: 38,
2596            X: 88,
2597            CONTROL: 17
2598        };
2599        Inputmask.dependencyLib = $;
2600        function resolveAlias(aliasStr, options, opts) {
2601            var aliasDefinition = Inputmask.prototype.aliases[aliasStr];
2602            if (aliasDefinition) {
2603                if (aliasDefinition.alias) resolveAlias(aliasDefinition.alias, undefined, opts);
2604                $.extend(true, opts, aliasDefinition);
2605                $.extend(true, opts, options);
2606                return true;
2607            } else if (opts.mask === null) {
2608                opts.mask = aliasStr;
2609            }
2610            return false;
2611        }
2612        function generateMaskSet(opts, nocache) {
2613            function generateMask(mask, metadata, opts) {
2614                var regexMask = false;
2615                if (mask === null || mask === "") {
2616                    regexMask = opts.regex !== null;
2617                    if (regexMask) {
2618                        mask = opts.regex;
2619                        mask = mask.replace(/^(\^)(.*)(\$)$/, "$2");
2620                    } else {
2621                        regexMask = true;
2622                        mask = ".*";
2623                    }
2624                }
2625                if (mask.length === 1 && opts.greedy === false && opts.repeat !== 0) {
2626                    opts.placeholder = "";
2627                }
2628                if (opts.repeat > 0 || opts.repeat === "*" || opts.repeat === "+") {
2629                    var repeatStart = opts.repeat === "*" ? 0 : opts.repeat === "+" ? 1 : opts.repeat;
2630                    mask = opts.groupmarker[0] + mask + opts.groupmarker[1] + opts.quantifiermarker[0] + repeatStart + "," + opts.repeat + opts.quantifiermarker[1];
2631                }
2632                var masksetDefinition, maskdefKey = regexMask ? "regex_" + opts.regex : opts.numericInput ? mask.split("").reverse().join("") : mask;
2633                if (Inputmask.prototype.masksCache[maskdefKey] === undefined || nocache === true) {
2634                    masksetDefinition = {
2635                        mask: mask,
2636                        maskToken: Inputmask.prototype.analyseMask(mask, regexMask, opts),
2637                        validPositions: {},
2638                        _buffer: undefined,
2639                        buffer: undefined,
2640                        tests: {},
2641                        excludes: {},
2642                        metadata: metadata,
2643                        maskLength: undefined,
2644                        jitOffset: {}
2645                    };
2646                    if (nocache !== true) {
2647                        Inputmask.prototype.masksCache[maskdefKey] = masksetDefinition;
2648                        masksetDefinition = $.extend(true, {}, Inputmask.prototype.masksCache[maskdefKey]);
2649                    }
2650                } else masksetDefinition = $.extend(true, {}, Inputmask.prototype.masksCache[maskdefKey]);
2651                return masksetDefinition;
2652            }
2653            var ms;
2654            if ($.isFunction(opts.mask)) {
2655                opts.mask = opts.mask(opts);
2656            }
2657            if ($.isArray(opts.mask)) {
2658                if (opts.mask.length > 1) {
2659                    if (opts.keepStatic === null) {
2660                        opts.keepStatic = "auto";
2661                        for (var i = 0; i < opts.mask.length; i++) {
2662                            if (opts.mask[i].charAt(0) !== opts.mask[0].charAt(0)) {
2663                                opts.keepStatic = true;
2664                                break;
2665                            }
2666                        }
2667                    }
2668                    var altMask = opts.groupmarker[0];
2669                    $.each(opts.isRTL ? opts.mask.reverse() : opts.mask, function(ndx, msk) {
2670                        if (altMask.length > 1) {
2671                            altMask += opts.groupmarker[1] + opts.alternatormarker + opts.groupmarker[0];
2672                        }
2673                        if (msk.mask !== undefined && !$.isFunction(msk.mask)) {
2674                            altMask += msk.mask;
2675                        } else {
2676                            altMask += msk;
2677                        }
2678                    });
2679                    altMask += opts.groupmarker[1];
2680                    return generateMask(altMask, opts.mask, opts);
2681                } else opts.mask = opts.mask.pop();
2682            }
2683            if (opts.mask && opts.mask.mask !== undefined && !$.isFunction(opts.mask.mask)) {
2684                ms = generateMask(opts.mask.mask, opts.mask, opts);
2685            } else {
2686                ms = generateMask(opts.mask, opts.mask, opts);
2687            }
2688            return ms;
2689        }
2690        function isInputEventSupported(eventName) {
2691            var el = document.createElement("input"), evName = "on" + eventName, isSupported = evName in el;
2692            if (!isSupported) {
2693                el.setAttribute(evName, "return;");
2694                isSupported = typeof el[evName] === "function";
2695            }
2696            el = null;
2697            return isSupported;
2698        }
2699        function maskScope(actionObj, maskset, opts) {
2700            maskset = maskset || this.maskset;
2701            opts = opts || this.opts;
2702            var inputmask = this, el = this.el, isRTL = this.isRTL, undoValue, $el, skipKeyPressEvent = false, skipInputEvent = false, ignorable = false, maxLength, mouseEnter = false, colorMask, originalPlaceholder;
2703            function getMaskTemplate(baseOnInput, minimalPos, includeMode, noJit, clearOptionalTail) {
2704                var greedy = opts.greedy;
2705                if (clearOptionalTail) opts.greedy = false;
2706                minimalPos = minimalPos || 0;
2707                var maskTemplate = [], ndxIntlzr, pos = 0, test, testPos, lvp = getLastValidPosition();
2708                do {
2709                    if (baseOnInput === true && getMaskSet().validPositions[pos]) {
2710                        testPos = clearOptionalTail && getMaskSet().validPositions[pos].match.optionality === true && getMaskSet().validPositions[pos + 1] === undefined && (getMaskSet().validPositions[pos].generatedInput === true || getMaskSet().validPositions[pos].input == opts.skipOptionalPartCharacter && pos > 0) ? determineTestTemplate(pos, getTests(pos, ndxIntlzr, pos - 1)) : getMaskSet().validPositions[pos];
2711                        test = testPos.match;
2712                        ndxIntlzr = testPos.locator.slice();
2713                        maskTemplate.push(includeMode === true ? testPos.input : includeMode === false ? test.nativeDef : getPlaceholder(pos, test));
2714                    } else {
2715                        testPos = getTestTemplate(pos, ndxIntlzr, pos - 1);
2716                        test = testPos.match;
2717                        ndxIntlzr = testPos.locator.slice();
2718                        var jitMasking = noJit === true ? false : opts.jitMasking !== false ? opts.jitMasking : test.jit;
2719                        if (jitMasking === false || jitMasking === undefined || typeof jitMasking === "number" && isFinite(jitMasking) && jitMasking > pos) {
2720                            maskTemplate.push(includeMode === false ? test.nativeDef : getPlaceholder(pos, test));
2721                        }
2722                    }
2723                    if (opts.keepStatic === "auto") {
2724                        if (test.newBlockMarker && test.fn !== null) {
2725                            opts.keepStatic = pos - 1;
2726                        }
2727                    }
2728                    pos++;
2729                } while ((maxLength === undefined || pos < maxLength) && (test.fn !== null || test.def !== "") || minimalPos > pos);
2730                if (maskTemplate[maskTemplate.length - 1] === "") {
2731                    maskTemplate.pop();
2732                }
2733                if (includeMode !== false || getMaskSet().maskLength === undefined) getMaskSet().maskLength = pos - 1;
2734                opts.greedy = greedy;
2735                return maskTemplate;
2736            }
2737            function getMaskSet() {
2738                return maskset;
2739            }
2740            function resetMaskSet(soft) {
2741                var maskset = getMaskSet();
2742                maskset.buffer = undefined;
2743                if (soft !== true) {
2744                    maskset.validPositions = {};
2745                    maskset.p = 0;
2746                }
2747            }
2748            function getLastValidPosition(closestTo, strict, validPositions) {
2749                var before = -1, after = -1, valids = validPositions || getMaskSet().validPositions;
2750                if (closestTo === undefined) closestTo = -1;
2751                for (var posNdx in valids) {
2752                    var psNdx = parseInt(posNdx);
2753                    if (valids[psNdx] && (strict || valids[psNdx].generatedInput !== true)) {
2754                        if (psNdx <= closestTo) before = psNdx;
2755                        if (psNdx >= closestTo) after = psNdx;
2756                    }
2757                }
2758                return before === -1 || before == closestTo ? after : after == -1 ? before : closestTo - before < after - closestTo ? before : after;
2759            }
2760            function getDecisionTaker(tst) {
2761                var decisionTaker = tst.locator[tst.alternation];
2762                if (typeof decisionTaker == "string" && decisionTaker.length > 0) {
2763                    decisionTaker = decisionTaker.split(",")[0];
2764                }
2765                return decisionTaker !== undefined ? decisionTaker.toString() : "";
2766            }
2767            function getLocator(tst, align) {
2768                var locator = (tst.alternation != undefined ? tst.mloc[getDecisionTaker(tst)] : tst.locator).join("");
2769                if (locator !== "") while (locator.length < align) {
2770                    locator += "0";
2771                }
2772                return locator;
2773            }
2774            function determineTestTemplate(pos, tests) {
2775                pos = pos > 0 ? pos - 1 : 0;
2776                var altTest = getTest(pos), targetLocator = getLocator(altTest), tstLocator, closest, bestMatch;
2777                for (var ndx = 0; ndx < tests.length; ndx++) {
2778                    var tst = tests[ndx];
2779                    tstLocator = getLocator(tst, targetLocator.length);
2780                    var distance = Math.abs(tstLocator - targetLocator);
2781                    if (closest === undefined || tstLocator !== "" && distance < closest || bestMatch && !opts.greedy && bestMatch.match.optionality && bestMatch.match.newBlockMarker === "master" && (!tst.match.optionality || !tst.match.newBlockMarker) || bestMatch && bestMatch.match.optionalQuantifier && !tst.match.optionalQuantifier) {
2782                        closest = distance;
2783                        bestMatch = tst;
2784                    }
2785                }
2786                return bestMatch;
2787            }
2788            function getTestTemplate(pos, ndxIntlzr, tstPs) {
2789                return getMaskSet().validPositions[pos] || determineTestTemplate(pos, getTests(pos, ndxIntlzr ? ndxIntlzr.slice() : ndxIntlzr, tstPs));
2790            }
2791            function getTest(pos, tests) {
2792                if (getMaskSet().validPositions[pos]) {
2793                    return getMaskSet().validPositions[pos];
2794                }
2795                return (tests || getTests(pos))[0];
2796            }
2797            function positionCanMatchDefinition(pos, def) {
2798                var valid = false, tests = getTests(pos);
2799                for (var tndx = 0; tndx < tests.length; tndx++) {
2800                    if (tests[tndx].match && tests[tndx].match.def === def) {
2801                        valid = true;
2802                        break;
2803                    }
2804                }
2805                return valid;
2806            }
2807            function getTests(pos, ndxIntlzr, tstPs) {
2808                var maskTokens = getMaskSet().maskToken, testPos = ndxIntlzr ? tstPs : 0, ndxInitializer = ndxIntlzr ? ndxIntlzr.slice() : [ 0 ], matches = [], insertStop = false, latestMatch, cacheDependency = ndxIntlzr ? ndxIntlzr.join("") : "";
2809                function resolveTestFromToken(maskToken, ndxInitializer, loopNdx, quantifierRecurse) {
2810                    function handleMatch(match, loopNdx, quantifierRecurse) {
2811                        function isFirstMatch(latestMatch, tokenGroup) {
2812                            var firstMatch = $.inArray(latestMatch, tokenGroup.matches) === 0;
2813                            if (!firstMatch) {
2814                                $.each(tokenGroup.matches, function(ndx, match) {
2815                                    if (match.isQuantifier === true) firstMatch = isFirstMatch(latestMatch, tokenGroup.matches[ndx - 1]); else if (match.hasOwnProperty("matches")) firstMatch = isFirstMatch(latestMatch, match);
2816                                    if (firstMatch) return false;
2817                                });
2818                            }
2819                            return firstMatch;
2820                        }
2821                        function resolveNdxInitializer(pos, alternateNdx, targetAlternation) {
2822                            var bestMatch, indexPos;
2823                            if (getMaskSet().tests[pos] || getMaskSet().validPositions[pos]) {
2824                                $.each(getMaskSet().tests[pos] || [ getMaskSet().validPositions[pos] ], function(ndx, lmnt) {
2825                                    if (lmnt.mloc[alternateNdx]) {
2826                                        bestMatch = lmnt;
2827                                        return false;
2828                                    }
2829                                    var alternation = targetAlternation !== undefined ? targetAlternation : lmnt.alternation, ndxPos = lmnt.locator[alternation] !== undefined ? lmnt.locator[alternation].toString().indexOf(alternateNdx) : -1;
2830                                    if ((indexPos === undefined || ndxPos < indexPos) && ndxPos !== -1) {
2831                                        bestMatch = lmnt;
2832                                        indexPos = ndxPos;
2833                                    }
2834                                });
2835                            }
2836                            if (bestMatch) {
2837                                var bestMatchAltIndex = bestMatch.locator[bestMatch.alternation];
2838                                var locator = bestMatch.mloc[alternateNdx] || bestMatch.mloc[bestMatchAltIndex] || bestMatch.locator;
2839                                return locator.slice((targetAlternation !== undefined ? targetAlternation : bestMatch.alternation) + 1);
2840                            } else {
2841                                return targetAlternation !== undefined ? resolveNdxInitializer(pos, alternateNdx) : undefined;
2842                            }
2843                        }
2844                        function isSubsetOf(source, target) {
2845                            function expand(pattern) {
2846                                var expanded = [], start, end;
2847                                for (var i = 0, l = pattern.length; i < l; i++) {
2848                                    if (pattern.charAt(i) === "-") {
2849                                        end = pattern.charCodeAt(i + 1);
2850                                        while (++start < end) {
2851                                            expanded.push(String.fromCharCode(start));
2852                                        }
2853                                    } else {
2854                                        start = pattern.charCodeAt(i);
2855                                        expanded.push(pattern.charAt(i));
2856                                    }
2857                                }
2858                                return expanded.join("");
2859                            }
2860                            if (opts.regex && source.match.fn !== null && target.match.fn !== null) {
2861                                return expand(target.match.def.replace(/[\[\]]/g, "")).indexOf(expand(source.match.def.replace(/[\[\]]/g, ""))) !== -1;
2862                            }
2863                            return source.match.def === target.match.nativeDef;
2864                        }
2865                        function staticCanMatchDefinition(source, target) {
2866                            var sloc = source.locator.slice(source.alternation).join(""), tloc = target.locator.slice(target.alternation).join(""), canMatch = sloc == tloc;
2867                            canMatch = canMatch && source.match.fn === null && target.match.fn !== null ? target.match.fn.test(source.match.def, getMaskSet(), pos, false, opts, false) : false;
2868                            return canMatch;
2869                        }
2870                        function setMergeLocators(targetMatch, altMatch) {
2871                            if (altMatch === undefined || targetMatch.alternation === altMatch.alternation && targetMatch.locator[targetMatch.alternation].toString().indexOf(altMatch.locator[altMatch.alternation]) === -1) {
2872                                targetMatch.mloc = targetMatch.mloc || {};
2873                                var locNdx = targetMatch.locator[targetMatch.alternation];
2874                                if (locNdx === undefined) targetMatch.alternation = undefined; else {
2875                                    if (typeof locNdx === "string") locNdx = locNdx.split(",")[0];
2876                                    if (targetMatch.mloc[locNdx] === undefined) targetMatch.mloc[locNdx] = targetMatch.locator.slice();
2877                                    if (altMatch !== undefined) {
2878                                        for (var ndx in altMatch.mloc) {
2879                                            if (typeof ndx === "string") ndx = ndx.split(",")[0];
2880                                            if (targetMatch.mloc[ndx] === undefined) targetMatch.mloc[ndx] = altMatch.mloc[ndx];
2881                                        }
2882                                        targetMatch.locator[targetMatch.alternation] = Object.keys(targetMatch.mloc).join(",");
2883                                    }
2884                                    return true;
2885                                }
2886                            }
2887                            return false;
2888                        }
2889                        if (testPos > 500 && quantifierRecurse !== undefined) {
2890                            throw "Inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. " + getMaskSet().mask;
2891                        }
2892                        if (testPos === pos && match.matches === undefined) {
2893                            matches.push({
2894                                match: match,
2895                                locator: loopNdx.reverse(),
2896                                cd: cacheDependency,
2897                                mloc: {}
2898                            });
2899                            return true;
2900                        } else if (match.matches !== undefined) {
2901                            if (match.isGroup && quantifierRecurse !== match) {
2902                                match = handleMatch(maskToken.matches[$.inArray(match, maskToken.matches) + 1], loopNdx, quantifierRecurse);
2903                                if (match) return true;
2904                            } else if (match.isOptional) {
2905                                var optionalToken = match;
2906                                match = resolveTestFromToken(match, ndxInitializer, loopNdx, quantifierRecurse);
2907                                if (match) {
2908                                    $.each(matches, function(ndx, mtch) {
2909                                        mtch.match.optionality = true;
2910                                    });
2911                                    latestMatch = matches[matches.length - 1].match;
2912                                    if (quantifierRecurse === undefined && isFirstMatch(latestMatch, optionalToken)) {
2913                                        insertStop = true;
2914                                        testPos = pos;
2915                                    } else return true;
2916                                }
2917                            } else if (match.isAlternator) {
2918                                var alternateToken = match, malternateMatches = [], maltMatches, currentMatches = matches.slice(), loopNdxCnt = loopNdx.length;
2919                                var altIndex = ndxInitializer.length > 0 ? ndxInitializer.shift() : -1;
2920                                if (altIndex === -1 || typeof altIndex === "string") {
2921                                    var currentPos = testPos, ndxInitializerClone = ndxInitializer.slice(), altIndexArr = [], amndx;
2922                                    if (typeof altIndex == "string") {
2923                                        altIndexArr = altIndex.split(",");
2924                                    } else {
2925                                        for (amndx = 0;
2925 amndx < alternateToken.matches.length; amndx++) {
2926                                            altIndexArr.push(amndx.toString());
2927                                        }
2928                                    }
2929                                    if (getMaskSet().excludes[pos]) {
2930                                        var altIndexArrClone = altIndexArr.slice();
2931                                        for (var i = 0, el = getMaskSet().excludes[pos].length; i < el; i++) {
2932                                            altIndexArr.splice(altIndexArr.indexOf(getMaskSet().excludes[pos][i].toString()), 1);
2933                                        }
2934                                        if (altIndexArr.length === 0) {
2935                                            getMaskSet().excludes[pos] = undefined;
2936                                            altIndexArr = altIndexArrClone;
2937                                        }
2938                                    }
2939                                    if (opts.keepStatic === true || isFinite(parseInt(opts.keepStatic)) && currentPos >= opts.keepStatic) altIndexArr = altIndexArr.slice(0, 1);
2940                                    var unMatchedAlternation = false;
2941                                    for (var ndx = 0; ndx < altIndexArr.length; ndx++) {
2942                                        amndx = parseInt(altIndexArr[ndx]);
2943                                        matches = [];
2944                                        ndxInitializer = typeof altIndex === "string" ? resolveNdxInitializer(testPos, amndx, loopNdxCnt) || ndxInitializerClone.slice() : ndxInitializerClone.slice();
2945                                        if (alternateToken.matches[amndx] && handleMatch(alternateToken.matches[amndx], [ amndx ].concat(loopNdx), quantifierRecurse)) match = true; else if (ndx === 0) {
2946                                            unMatchedAlternation = true;
2947                                        }
2948                                        maltMatches = matches.slice();
2949                                        testPos = currentPos;
2950                                        matches = [];
2951                                        for (var ndx1 = 0; ndx1 < maltMatches.length; ndx1++) {
2952                                            var altMatch = maltMatches[ndx1], dropMatch = false;
2953                                            altMatch.match.jit = altMatch.match.jit || unMatchedAlternation;
2954                                            altMatch.alternation = altMatch.alternation || loopNdxCnt;
2955                                            setMergeLocators(altMatch);
2956                                            for (var ndx2 = 0; ndx2 < malternateMatches.length; ndx2++) {
2957                                                var altMatch2 = malternateMatches[ndx2];
2958                                                if (typeof altIndex !== "string" || altMatch.alternation !== undefined && $.inArray(altMatch.locator[altMatch.alternation].toString(), altIndexArr) !== -1) {
2959                                                    if (altMatch.match.nativeDef === altMatch2.match.nativeDef) {
2960                                                        dropMatch = true;
2961                                                        setMergeLocators(altMatch2, altMatch);
2962                                                        break;
2963                                                    } else if (isSubsetOf(altMatch, altMatch2)) {
2964                                                        if (setMergeLocators(altMatch, altMatch2)) {
2965                                                            dropMatch = true;
2966                                                            malternateMatches.splice(malternateMatches.indexOf(altMatch2), 0, altMatch);
2967                                                        }
2968                                                        break;
2969                                                    } else if (isSubsetOf(altMatch2, altMatch)) {
2970                                                        setMergeLocators(altMatch2, altMatch);
2971                                                        break;
2972                                                    } else if (staticCanMatchDefinition(altMatch, altMatch2)) {
2973                                                        if (setMergeLocators(altMatch, altMatch2)) {
2974                                                            dropMatch = true;
2975                                                            malternateMatches.splice(malternateMatches.indexOf(altMatch2), 0, altMatch);
2976                                                        }
2977                                                        break;
2978                                                    }
2979                                                }
2980                                            }
2981                                            if (!dropMatch) {
2982                                                malternateMatches.push(altMatch);
2983                                            }
2984                                        }
2985                                    }
2986                                    matches = currentMatches.concat(malternateMatches);
2987                                    testPos = pos;
2988                                    insertStop = matches.length > 0;
2989                                    match = malternateMatches.length > 0;
2990                                    ndxInitializer = ndxInitializerClone.slice();
2991                                } else match = handleMatch(alternateToken.matches[altIndex] || maskToken.matches[altIndex], [ altIndex ].concat(loopNdx), quantifierRecurse);
2992                                if (match) return true;
2993                            } else if (match.isQuantifier && quantifierRecurse !== maskToken.matches[$.inArray(match, maskToken.matches) - 1]) {
2994                                var qt = match;
2995                                for (var qndx = ndxInitializer.length > 0 ? ndxInitializer.shift() : 0; qndx < (isNaN(qt.quantifier.max) ? qndx + 1 : qt.quantifier.max) && testPos <= pos; qndx++) {
2996                                    var tokenGroup = maskToken.matches[$.inArray(qt, maskToken.matches) - 1];
2997                                    match = handleMatch(tokenGroup, [ qndx ].concat(loopNdx), tokenGroup);
2998                                    if (match) {
2999                                        latestMatch = matches[matches.length - 1].match;
3000                                        latestMatch.optionalQuantifier = qndx >= qt.quantifier.min;
3001                                        latestMatch.jit = (qndx || 1) * tokenGroup.matches.indexOf(latestMatch) >= qt.quantifier.jit;
3002                                        if (latestMatch.optionalQuantifier && isFirstMatch(latestMatch, tokenGroup)) {
3003                                            insertStop = true;
3004                                            testPos = pos;
3005                                            break;
3006                                        }
3007                                        if (latestMatch.jit) {
3008                                            getMaskSet().jitOffset[pos] = tokenGroup.matches.indexOf(latestMatch);
3009                                        }
3010                                        return true;
3011                                    }
3012                                }
3013                            } else {
3014                                match = resolveTestFromToken(match, ndxInitializer, loopNdx, quantifierRecurse);
3015                                if (match) return true;
3016                            }
3017                        } else {
3018                            testPos++;
3019                        }
3020                    }
3021                    for (var tndx = ndxInitializer.length > 0 ? ndxInitializer.shift() : 0; tndx < maskToken.matches.length; tndx++) {
3022                        if (maskToken.matches[tndx].isQuantifier !== true) {
3023                            var match = handleMatch(maskToken.matches[tndx], [ tndx ].concat(loopNdx), quantifierRecurse);
3024                            if (match && testPos === pos) {
3025                                return match;
3026                            } else if (testPos > pos) {
3027                                break;
3028                            }
3029                        }
3030                    }
3031                }
3032                function mergeLocators(pos, tests) {
3033                    var locator = [];
3034                    if (!$.isArray(tests)) tests = [ tests ];
3035                    if (tests.length > 0) {
3036                        if (tests[0].alternation === undefined) {
3037                            locator = determineTestTemplate(pos, tests.slice()).locator.slice();
3038                            if (locator.length === 0) locator = tests[0].locator.slice();
3039                        } else {
3040                            $.each(tests, function(ndx, tst) {
3041                                if (tst.def !== "") {
3042                                    if (locator.length === 0) locator = t
3042st.locator.slice(); else {
3043                                        for (var i = 0; i < locator.length; i++) {
3044                                            if (tst.locator[i] && locator[i].toString().indexOf(tst.locator[i]) === -1) {
3045                                                locator[i] += "," + tst.locator[i];
3046                                            }
3047                                        }
3048                                    }
3049                                }
3050                            });
3051                        }
3052                    }
3053                    return locator;
3054                }
3055                if (pos > -1) {
3056                    if (ndxIntlzr === undefined) {
3057                        var previousPos = pos - 1, test;
3058                        while ((test = getMaskSet().validPositions[previousPos] || getMaskSet().tests[previousPos]) === undefined && previousPos > -1) {
3059                            previousPos--;
3060                        }
3061                        if (test !== undefined && previousPos > -1) {
3062                            ndxInitializer = mergeLocators(previousPos, test);
3063                            cacheDependency = ndxInitializer.join("");
3064                            testPos = previousPos;
3065                        }
3066                    }
3067                    if (getMaskSet().tests[pos] && getMaskSet().tests[pos][0].cd === cacheDependency) {
3068                        return getMaskSet().tests[pos];
3069                    }
3070                    for (var mtndx = ndxInitializer.shift(); mtndx < maskTokens.length; mtndx++) {
3071                        var match = resolveTestFromToken(maskTokens[mtndx], ndxInitializer, [ mtndx ]);
3072                        if (match && testPos === pos || testPos > pos) {
3073                            break;
3074                        }
3075                    }
3076                }
3077                if (matches.length === 0 || insertStop) {
3078                    matches.push({
3079                        match: {
3080                            fn: null,
3081                            optionality: false,
3082                            casing: null,
3083                            def: "",
3084                            placeholder: ""
3085                        },
3086                        locator: [],
3087                        mloc: {},
3088                        cd: cacheDependency
3089                    });
3090                }
3091                if (ndxIntlzr !== undefined && getMaskSet().tests[pos]) {
3092                    return $.extend(true, [], matches);
3093                }
3094                getMaskSet().tests[pos] = $.extend(true, [], matches);
3095                return getMaskSet().tests[pos];
3096            }
3097            function getBufferTemplate() {
3098                if (getMaskSet()._buffer === undefined) {
3099                    getMaskSet()._buffer = getMaskTemplate(false, 1);
3100                    if (getMaskSet().buffer === undefined) getMaskSet().buffer = getMaskSet()._buffer.slice();
3101                }
3102                return getMaskSet()._buffer;
3103            }
3104            function getBuffer(noCache) {
3105                if (getMaskSet().buffer === undefined || noCache === true) {
3106                    getMaskSet().buffer = getMaskTemplate(true, getLastValidPosition(), true);
3107                    if (getMaskSet()._buffer === undefined) getMaskSet()._buffer = getMaskSet().buffer.slice();
3108                }
3109                return getMaskSet().buffer;
3110            }
3111            function refreshFromBuffer(start, end, buffer) {
3112                var i, p;
3113                if (start === true) {
3114                    resetMaskSet();
3115                    start = 0;
3116                    end = buffer.length;
3117                } else {
3118                    for (i = start; i < end; i++) {
3119                        delete getMaskSet().validPositions[i];
3120                    }
3121                }
3122                p = start;
3123                for (i = start; i < end; i++) {
3124                    resetMaskSet(true);
3125                    if (buffer[i] !== opts.skipOptionalPartCharacter) {
3126                        var valResult = isValid(p, buffer[i], true, true);
3127                        if (valResult !== false) {
3128                            resetMaskSet(true);
3129                            p = valResult.caret !== undefined ? valResult.caret : valResult.pos + 1;
3130                        }
3131                    }
3132                }
3133            }
3134            function casing(elem, test, pos) {
3135                switch (opts.casing || test.casing) {
3136                  case "upper":
3137                    elem = elem.toUpperCase();
3138                    break;
3139
3140                  case "lower":
3141                    elem = elem.toLowerCase();
3142                    break;
3143
3144                  case "title":
3145                    var posBefore = getMaskSet().validPositions[pos - 1];
3146                    if (pos === 0 || posBefore && posBefore.input === String.fromCharCode(Inputmask.keyCode.SPACE)) {
3147                        elem = elem.toUpperCase();
3148                    } else {
3149                        elem = elem.toLowerCase();
3150                    }
3151                    break;
3152
3153                  default:
3154                    if ($.isFunction(opts.casing)) {
3155                        var args = Array.prototype.slice.call(arguments);
3156                        args.push(getMaskSet().validPositions);
3157                        elem = opts.casing.apply(this, args);
3158                    }
3159                }
3160                return elem;
3161            }
3162            function checkAlternationMatch(altArr1, altArr2, na) {
3163                var altArrC = opts.greedy ? altArr2 : altArr2.slice(0, 1), isMatch = false, naArr = na !== undefined ? na.split(",") : [], naNdx;
3164                for (var i = 0; i < naArr.length; i++) {
3165                    if ((naNdx = altArr1.indexOf(naArr[i])) !== -1) {
3166                        altArr1.splice(naNdx, 1);
3167                    }
3168                }
3169                for (var alndx = 0; alndx < altArr1.length; alndx++) {
3170                    if ($.inArray(altArr1[alndx], altArrC) !== -1) {
3171                        isMatch = true;
3172                        break;
3173                    }
3174                }
3175                return isMatch;
3176            }
3177            function alternate(pos, c, strict, fromSetValid, rAltPos) {
3178                var validPsClone = $.extend(true, {}, getMaskSet().validPositions), lastAlt, alternation, isValidRslt = false, altPos, prevAltPos, i, validPos, decisionPos, lAltPos = rAltPos !== undefined ? rAltPos : getLastValidPosition();
3179                if (lAltPos === -1 && rAltPos === undefined) {
3180                    lastAlt = 0;
3181                    prevAltPos = getTest(lastAlt);
3182                    alternation = prevAltPos.alternation;
3183                } else {
3184                    for (;lAltPos >= 0; lAltPos--) {
3185                        altPos = getMaskSet().validPositions[lAltPos];
3186                        if (altPos && altPos.alternation !== undefined) {
3187                            if (prevAltPos && prevAltPos.locator[altPos.alternation] !== altPos.locator[altPos.alternation]) {
3188                                break;
3189                            }
3190                            lastAlt = lAltPos;
3191                            alternation = getMaskSet().validPositions[lastAlt].alternation;
3192                            prevAltPos = altPos;
3193                        }
3194                    }
3195                }
3196                if (alternation !== undefined) {
3197                    decisionPos = parseInt(lastAlt);
3198                    getMaskSet().excludes[decisionPos] = getMaskSet().excludes[decisionPos] || [];
3199                    if (pos !== true) {
3200                        getMaskSet().excludes[decisionPos].push(getDecisionTaker(prevAltPos));
3201                    }
3202                    var validInputsClone = [], staticInputsBeforePos = 0;
3203                    for (i = decisionPos; i < getLastValidPosition(undefined, true) + 1; i++) {
3204                        validPos = getMaskSet().validPositions[i];
3205                        if (validPos && validPos.generatedInput !== true) {
3206                            validInputsClone.push(validPos.input);
3207                        } else if (i < pos) staticInputsBeforePos++;
3208                        delete getMaskSet().validPositions[i];
3209                    }
3210                    while (getMaskSet().excludes[decisionPos] && getMaskSet().excludes[decisionPos].length < 10) {
3211                        var posOffset = staticInputsBeforePos * -1, validInputs = validInputsClone.slice();
3212                        getMaskSet().tests[decisionPos] = undefined;
3213                        resetMaskSet(true);
3214                        isValidRslt = true;
3215                        while (validInputs.length > 0) {
3216                            var input = validInputs.shift();
3217                            if (!(isValidRslt = isValid(getLastValidPosition(undefined, true) + 1, input, false, fromSetValid, true))) {
3218                                break;
3219                            }
3220                        }
3221                        if (isValidRslt && c !== undefined) {
3222                            var targetLvp = getLastValidPosition(pos) + 1;
3223                            for (i = decisionPos; i < getLastValidPosition() + 1; i++) {
3224                                validPos = getMaskSet().validPositions[i];
3225                                if ((validPos === undefined || validPos.match.fn == null) && i < pos + posOffset) {
3226                                    posOffset++;
3227                                }
3228                            }
3229                            pos = pos + posOffset;
3230                            isValidRslt = isValid(pos > targetLvp ? targetLvp : pos, c, strict, fromSetValid, true);
3231                        }
3232                        if (!isValidRslt) {
3233                            resetMaskSet();
3234                            prevAltPos = getTest(decisionPos);
3235                            getMaskSet().validPositions = $.extend(true, {}, validPsClone);
3236                            if (getMaskSet().excludes[decisionPos]) {
3237                                var decisionTaker = getDecisionTaker(prevAltPos);
3238                                if (getMaskSet().excludes[decisionPos].indexOf(decisionTaker) !== -1) {
3239                                    isValidRslt = alternate(pos, c, strict, fromSetValid, decisionPos - 1);
3240                                    break;
3241                                }
3242                                getMaskSet().excludes[decisionPos].push(decisionTaker);
3243                                for (i = decisionPos; i < getLastValidPosition(undefined, true) + 1; i++) {
3244                                    delete getMaskSet().validPositions[i];
3245                                }
3246                            } else {
3247                                isValidRslt = alternate(pos, c, strict, fromSetValid, decisionPos - 1);
3248                                break;
3249                            }
3250                        } else break;
3251                    }
3252                }
3253                getMaskSet().excludes[decisionPos] = undefined;
3254                return isValidRslt;
3255            }
3256            function isValid(pos, c, strict, fromSetValid, fromAlternate, validateOnly) {
3257                function isSelection(posObj) {
3258                    return isRTL ? posObj.begin - posObj.end > 1 || posObj.begin - posObj.end === 1 : posObj.end - posObj.begin > 1 || posObj.end - posObj.begin === 1;
3259                }
3260                strict = strict === true;
3261                var maskPos = pos;
3262                if (pos.begin !== undefined) {
3263                    maskPos = isRTL ? pos.end : pos.begin;
3264                }
3265                function _isValid(position, c, strict) {
3266                    var rslt = false;
3267                    $.each(getTests(position), function(ndx, tst) {
3268                        var test = tst.match;
3269                        getBuffer(true);
3270                        rslt = test.fn != null ? test.fn.test(c, getMaskSet(), position, strict, opts, isSelection(pos)) : (c === test.def || c === opts.skipOptionalPartCharacter) && test.def !== "" ? {
3271                            c: getPlaceholder(position, test, true) || test.def,
3272                            pos: position
3273                        } : false;
3274                        if (rslt !== false) {
3275                            var elem = rslt.c !== undefined ? rslt.c : c, validatedPos = position;
3276                            elem = elem === opts.skipOptionalPartCharacter && test.fn === null ? getPlaceholder(position, test, true) || test.def : elem;
3277                            if (rslt.remove !== undefined) {
3278                                if (!$.isArray(rslt.remove)) rslt.remove = [ rslt.remove ];
3279                                $.each(rslt.remove.sort(function(a, b) {
3280                                    return b - a;
3281                                }), function(ndx, lmnt) {
3282                                    revalidateMask({
3283                                        begin: lmnt,
3284                                        end: lmnt + 1
3285                                    });
3286                                });
3287                            }
3288                            if (rslt.insert !== undefined) {
3289                                if (!$.isArray(rslt.insert)) rslt.insert = [ rslt.insert ];
3290                                $.each(rslt.insert.sort(function(a, b) {
3291                                    return a - b;
3292                                }), function(ndx, lmnt) {
3293                                    isValid(lmnt.pos, lmnt.c, true, fromSetValid);
3294                                });
3295                            }
3296                            if (rslt !== true && rslt.pos !== undefined && rslt.pos !== position) {
3297                                validatedPos = rslt.pos;
3298                            }
3299                            if (rslt !== true && rslt.pos === undefined && rslt.c === undefined) {
3300                                return false;
3301                            }
3302                            if (!revalidateMask(pos, $.extend({}, tst, {
3303                                input: casing(elem, test, validatedPos)
3304                            }), fromSetValid, validatedPos)) {
3305                                rslt = false;
3306                            }
3307                            return false;
3308                        }
3309                    });
3310                    return rslt;
3311                }
3312                var result = true, positionsClone = $.extend(true, {}, getMaskSet().validPositions);
3313                if ($.isFunction(opts.preValidation) && !strict && fromSetValid !== true && validateOnly !== true) {
3314                    result = opts.preValidation(getBuffer(), maskPos, c, isSelection(pos), opts, getMaskSet());
3315                }
3316                if (result === true) {
3317                    trackbackPositions(undefined, maskPos, true);
3318                    if (maxLength === undefined || maskPos < maxLength) {
3319                        result = _isValid(maskPos, c, strict);
3320                        if ((!strict || fromSetValid === true) && result === false && validateOnly !== true) {
3321                            var currentPosValid = getMaskSet().validPositions[maskPos];
3322                            if (currentPosValid && currentPosValid.match.fn === null && (currentPosValid.match.def === c || c === opts.skipOptionalPartCharacter)) {
3323                                result = {
3324                                    caret: seekNext(maskPos)
3325                                };
3326                            } else {
3327                                if ((opts.insertMode || getMaskSet().validPositions[seekNext(maskPos)] === undefined) && (!isMask(maskPos, true) || getMaskSet().jitOffset[maskPos])) {
3328                                    if (getMaskSet().jitOffset[maskPos] && getMaskSet().validPositions[seekNext(maskPos)] === undefined) {
3329                                        result = isValid(maskPos + getMaskSet().jitOffset[maskPos], c, strict);
3330                                        if (result !== false) result.caret = maskPos;
3331                                    } else for (var nPos = maskPos + 1, snPos = seekNext(maskPos); nPos <= snPos; nPos++) {
3332                                        result = _isValid(nPos, c, strict);
3333                                        if (result !== false) {
3334                                            result = trackbackPositions(maskPos, result.pos !== undefined ? result.pos : nPos) || result;
3335                                            maskPos = nPos;
3336                                            break;
3337                                        }
3338                                    }
3339                                }
3340                            }
3341                        }
3342                    }
3343                    if (result === false && opts.keepStatic !== false && (opts.regex == null || isComplete(getBuffer())) && !strict && fromAlternate !== true) {
3344                        result = alternate(maskPos, c, strict, fromSetValid);
3345                    }
3346                    if (result === true) {
3347                        result = {
3348                            pos: maskPos
3349                        };
3350                    }
3351                }
3352                if ($.isFunction(opts.postValidation) && result !== false && !strict && fromSetValid !== true && validateOnly !== true) {
3353                    var postResult = opts.postValidation(getBuffer(true), pos.begin !== undefined ? isRTL ? pos.end : pos.begin : pos, result, opts);
3354                    if (postResult !== undefined) {
3355                        if (postResult.refreshFromBuffer && postResult.buffer) {
3356                            var refresh = postResult.refreshFromBuffer;
3357                            refreshFromBuffer(refresh === true ? refresh : refresh.start, refresh.end, postResult.buffer);
3358                        }
3359                        result = postResult === true ? result : postResult;
3360                    }
3361                }
3362                if (result && result.pos === undefined) {
3363                    result.pos = maskPos;
3364                }
3365                if (result === false || validateOnly === true) {
3366                    resetMaskSet(true);
3367                    getMaskSet().validPositions = $.extend(true, {}, positionsClone);
3368                }
3369                return result;
3370            }
3371            function trackbackPositions(originalPos, newPos, fillOnly) {
3372                var result;
3373                if (originalPos === undefined) {
3374                    for (originalPos = newPos - 1; originalPos > 0; originalPos--) {
3375                        if (getMaskSet().validPositions[originalPos]) break;
3376                    }
3377                }
3378                for (var ps = originalPos; ps < newPos; ps++) {
3379                    if (getMaskSet().validPositions[ps] === undefined && !isMask(ps, true)) {
3380                        var vp = ps == 0 ? getTest(ps) : getMaskSet().validPositions[ps - 1];
3381                        if (vp) {
3382                            var tests = getTests(ps).slice();
3383                            if (tests[tests.length - 1].match.def === "") tests.pop();
3384                            var bestMatch = determineTestTemplate(ps, tests);
3385                            bestMatch = $.extend({}, bestMatch, {
3386                                input: getPlaceholder(ps, bestMatch.match, true) || bestMatch.match.def
3387                            });
3388                            bestMatch.generatedInput = true;
3389                            revalidateMask(ps, bestMatch, true);
3390                            if (fillOnly !== true) {
3391                                var cvpInput = getMaskSet().validPositions[newPos].input;
3392                                getMaskSet().validPositions[newPos] = undefined;
3393                                result = isValid(newPos, cvpInput, true, true);
3394                            }
3395                        }
3396                    }
3397                }
3398                return result;
3399            }
3400            function revalidateMask(pos, validTest, fromSetValid, validatedPos) {
3401                function IsEnclosedStatic(pos, valids, selection) {
3402                    var posMatch = valids[pos];
3403                    if (posMatch !== undefined && (posMatch.match.fn === null && posMatch.match.optionality !== true || posMatch.input === opts.radixPoint)) {
3404                        var prevMatch = selection.begin <= pos - 1 ? valids[pos - 1] && valids[pos - 1].match.fn === null && valids[pos - 1] : valids[pos - 1], nextMatch = selection.end > pos + 1 ? valids[pos + 1] && valids[pos + 1].match.fn === null && valids[pos + 1] : valids[pos + 1];
3405                        return prevMatch && nextMatch;
3406                    }
3407                    return false;
3408                }
3409                var begin = pos.begin !== undefined ? pos.begin : pos, end = pos.end !== undefined ? pos.end : pos;
3410                if (pos.begin > pos.end) {
3411                    begin = pos.end;
3412                    end = pos.begin;
3413                }
3414                validatedPos = validatedPos !== undefined ? validatedPos : begin;
3415                if (begin !== end || opts.insertMode && getMaskSet().validPositions[validatedPos] !== undefined && fromSetValid === undefined) {
3416                    var positionsClone = $.extend(true, {}, getMaskSet().validPositions), lvp = getLastValidPosition(undefined, true), i;
3417                    getMaskSet().p = begin;
3418                    for (i = lvp; i >= begin; i--) {
3419                        if (getMaskSet().validPositions[i] && getMaskSet().validPositions[i].match.nativeDef === "+") {
3420                            opts.isNegative = false;
3421                        }
3422                        delete getMaskSet().validPositions[i];
3423                    }
3424                    var valid = true, j = validatedPos, vps = getMaskSet().validPositions, needsValidation = false, posMatch = j, i = j;
3425                    if (validTest) {
3426                        getMaskSet().validPositions[validatedPos] = $.extend(true, {}, validTest);
3427                        posMatch++;
3428                        j++;
3429                        if (begin < end) i++;
3430                    }
3431                    for (;i <= lvp; i++) {
3432                        var t = positionsClone[i];
3433                        if (t !== undefined && (i >= end || i >= begin && t.generatedInput !== true && IsEnclosedStatic(i, positionsClone, {
3434                            begin: begin,
3435                            end: end
3436                        }))) {
3437                            while (getTest(posMatch).match.def !== "") {
3438                                if (needsValidation === false && positionsClone[posMatch] && positionsClone[posMatch].match.nativeDef === t.match.nativeDef) {
3439                                    getMaskSet().validPositions[posMatch] = $.extend(true, {}, positionsClone[posMatch]);
3440                                    getMaskSet().validPositions[posMatch].input = t.input;
3441                                    trackbackPositions(undefined, posMatch, true);
3442                                    j = posMatch + 1;
3443                                    valid = true;
3444                                } else if (opts.shiftPositions && positionCanMatchDefinition(posMatch, t.match.def)) {
3445                                    var result = isValid(posMatch, t.input, true, true);
3446                                    valid = result !== false;
3447                                    j = result.caret || result.insert ? getLastValidPosition() : posMatch + 1;
3448                                    needsValidation = true;
3449                                } else {
3450                                    valid = t.generatedInput === true || t.input === opts.radixPoint && opts.numericInput === true;
3451                                }
3452                                if (valid) break;
3453                                if (!valid && posMatch > end && isMask(posMatch, true) && (t.match.fn !== null || posMatch > getMaskSet().maskLength)) {
3454                                    break;
3455                                }
3456                                posMatch++;
3457                            }
3458                            if (getTest(posMatch).match.def == "") valid = false;
3459                            posMatch = j;
3460                        }
3461                        if (!valid) break;
3462                    }
3463                    if (!valid) {
3464                        getMaskSet().validPositions = $.extend(true, {}, positionsClone);
3465                        resetMaskSet(true);
3466                        return false;
3467                    }
3468                } else if (validTest) {
3469                    getMaskSet().validPositions[validatedPos] = $.extend(true, {}, validTest);
3470                }
3471                resetMaskSet(true);
3472                return true;
3473            }
3474            function isMask(pos, strict) {
3475                var test = getTestTemplate(pos).match;
3476                if (test.def === "") test = getTest(pos).match;
3477                if (test.fn != null) {
3478                    return test.fn;
3479                }
3480                if (strict !== true && pos > -1) {
3481                    var tests = getTests(pos);
3482                    return tests.length > 1 + (tests[tests.length - 1].match.def === "" ? 1 : 0);
3483                }
3484                return false;
3485            }
3486            function seekNext(pos, newBlock) {
3487                var position = pos + 1;
3488                while (getTest(position).match.def !== "" && (newBlock === true && (getTest(position).match.newBlockMarker !== true || !isMask(position)) || newBlock !== true && !isMask(position))) {
3489                    position++;
3490                }
3491                return position;
3492            }
3493            function seekPrevious(pos, newBlock) {
3494                var position = pos, tests;
3495                if (position <= 0) return 0;
3496                while (--position > 0 && (newBlock === true && getTest(position).match.newBlockMarker !== true || newBlock !== true && !isMask(position) && (tests = getTests(position), 
3497                tests.length < 2 || tests.length === 2 && tests[1].match.def === ""))) {}
3498                return position;
3499            }
3500            function writeBuffer(input, buffer, caretPos, event, triggerEvents) {
3501                if (event && $.isFunction(opts.onBeforeWrite)) {
3502                    var result = opts.onBeforeWrite.call(inputmask, event, buffer, caretPos, opts);
3503                    if (result) {
3504                        if (result.refreshFromBuffer) {
3505                            var refresh = result.refreshFromBuffer;
3506                            refreshFromBuffer(refresh === true ? refresh : refresh.start, refresh.end, result.buffer || buffer);
3507                            buffer = getBuffer(true);
3508                        }
3509                        if (caretPos !== undefined) caretPos = result.caret !== undefined ? result.caret : caretPos;
3510                    }
3511                }
3512                if (input !== undefined) {
3513                    input.inputmask._valueSet(buffer.join(""));
3514                    if (caretPos !== undefined && (event === undefined || event.type !== "blur")) {
3515                        caret(input, caretPos);
3516                    } else renderColorMask(input, caretPos, buffer.length === 0);
3517                    if (triggerEvents === true) {
3518                        var $input = $(input), nptVal = input.inputmask._valueGet();
3519                        skipInputEvent = true;
3520                        $input.trigger("input");
3521                        setTimeout(function() {
3522                            if (nptVal === getBufferTemplate().join("")) {
3523                                $input.trigger("cleared");
3524                            } else if (isComplete(buffer) === true) {
3525                                $input.trigger("complete");
3526                            }
3527                        }, 0);
3528                    }
3529                }
3530            }
3531            function getPlaceholder(pos, test, returnPL) {
3532                test = test || getTest(pos).match;
3533                if (test.placeholder !== undefined || returnPL === true) {
3534                    return $.isFunction(test.placeholder) ? test.placeholder(opts) : test.placeholder;
3535                } else if (test.fn === null) {
3536                    if (pos > -1 && getMaskSet().validPositions[pos] === undefined) {
3537                        var tests = getTests(pos), staticAlternations = [], prevTest;
3538                        if (tests.length > 1 + (tests[tests.length - 1].match.def === "" ? 1 : 0)) {
3539                            for (var i = 0; i < tests.length; i++) {
3540                                if (tests[i].match.optionality !== true && tests[i].match.optionalQuantifier !== true && (tests[i].match.fn === null || prevTest === undefined || tests[i].match.fn.test(prevTest.match.def, getMaskSet(), pos, true, opts) !== false)) {
3541                                    staticAlternations.push(tests[i]);
3542                                    if (tests[i].match.fn === null) prevTest = tests[i];
3543                                    if (staticAlternations.length > 1) {
3544                                        if (/[0-9a-bA-Z]/.test(staticAlternations[0].match.def)) {
3545                                            return opts.placeholder.charAt(pos % opts.placeholder.length);
3546                                        }
3547                                    }
3548                                }
3549                            }
3550                        }
3551                    }
3552                    return test.def;
3553                }
3554                return opts.placeholder.charAt(pos % opts.placeholder.length);
3555            }
3556            function HandleNativePlaceholder(npt, value) {
3557                if (ie) {
3558                    if (npt.inputmask._valueGet() !== value && (npt.placeholder !== value || npt.placeholder === "")) {
3559                        var buffer = getBuffer().slice(), nptValue = npt.inputmask._valueGet();
3560                        if (nptValue !== value) {
3561                            var lvp = getLastValidPosition();
3562                            if (lvp === -1 && nptValue === getBufferTemplate().join("")) {
3563                                buffer = [];
3564                            } else if (lvp !== -1) {
3565                                clearOptionalTail(buffer);
3566                            }
3567                            writeBuffer(npt, buffer);
3568                        }
3569                    }
3570                } else if (npt.placeholder !== value) {
3571                    npt.placeholder = value;
3572                    if (npt.placeholder === "") npt.removeAttribute("placeholder");
3573                }
3574            }
3575            var EventRuler = {
3576                on: function on(input, eventName, eventHandler) {
3577                    var ev = function ev(e) {
3578                        var that = this;
3579                        if (that.inputmask === undefined && this.nodeName !== "FORM") {
3580                            var imOpts = $.data(that, "_inputmask_opts");
3581                            if (imOpts) new Inputmask(imOpts).mask(that); else EventRuler.off(that);
3582                        } else if (e.type !== "setvalue" && this.nodeName !== "FORM" && (that.disabled || that.readOnly && !(e.type === "keydown" && e.ctrlKey && e.keyCode === 67 || opts.tabThrough === false && e.keyCode === Inputmask.keyCode.TAB))) {
3583                            e.preventDefault();
3584                        } else {
3585                            switch (e.type) {
3586                              case "input":
3587                                if (skipInputEvent === true) {
3588                                    skipInputEvent = false;
3589                                    return e.preventDefault();
3590                                }
3591                                if (mobile) {
3592                                    var args = arguments;
3593                                    setTimeout(function() {
3594                                        eventHandler.apply(that, args);
3595                                        caret(that, that.inputmask.caretPos, undefined, true);
3596                                    }, 0);
3597                                    return false;
3598                                }
3599                                break;
3600
3601                              case "keydown":
3602                                skipKeyPressEvent = false;
3603                                skipInputEvent = false;
3604                                break;
3605
3606                              case "keypress":
3607                                if (skipKeyPressEvent === true) {
3608                                    return e.preventDefault();
3609                                }
3610                                skipKeyPressEvent = true;
3611                                break;
3612
3613                              case "click":
3614                                if (iemobile || iphone) {
3615                                    var args = arguments;
3616                                    setTimeout(function() {
3617                                        eventHandler.apply(that, args);
3618                                    }, 0);
3619                                    return false;
3620                                }
3621                                break;
3622                            }
3623                            var returnVal = eventHandler.apply(that, arguments);
3624                            if (returnVal === false) {
3625                                e.preventDefault();
3626                                e.stopPropagation();
3627                            }
3628                            return returnVal;
3629                        }
3630                    };
3631                    input.inputmask.events[eventName] = input.inputmask.events[eventName] || [];
3632                    input.inputmask.events[eventName].push(ev);
3633                    if ($.inArray(eventName, [ "submit", "reset" ]) !== -1) {
3634                        if (input.form !== null) $(input.form).on(eventName, ev);
3635                    } else {
3636                        $(input).on(eventName, ev);
3637                    }
3638                },
3639                off: function off(input, event) {
3640                    if (input.inputmask && input.inputmask.events) {
3641                        var events;
3642                        if (event) {
3643                            events = [];
3644                            events[event] = input.inputmask.events[event];
3645                        } else {
3646                            events = input.inputmask.events;
3647                        }
3648                        $.each(events, function(eventName, evArr) {
3649                            while (evArr.length > 0) {
3650                                var ev = evArr.pop();
3651                                if ($.inArray(eventName, [ "submit", "reset" ]) !== -1) {
3652                                    if (input.form !== null) $(input.form).off(eventName, ev);
3653                                } else {
3654                                    $(input).off(eventName, ev);
3655                                }
3656                            }
3657                            delete input.inputmask.events[eventName];
3658                        });
3659                    }
3660                }
3661            };
3662            var EventHandlers = {
3663                keydownEvent: function keydownEvent(e) {
3664                    var input = this, $input = $(input), k = e.keyCode, pos = caret(input);
3665                    if (k === Inputmask.keyCode.BACKSPACE || k === Inputmask.keyCode.DELETE || iphone && k === Inputmask.keyCode.BACKSPACE_SAFARI || e.ctrlKey && k === Inputmask.keyCode.X && !isInputEventSupported("cut")) {
3666                        e.preventDefault();
3667                        handleRemove(input, k, pos);
3668                        writeBuffer(input, getBuffer(true), getMaskSet().p, e, input.inputmask._valueGet() !== getBuffer().join(""));
3669                    } else if (k === Inputmask.keyCode.END || k === Inputmask.keyCode.PAGE_DOWN) {
3670                        e.preventDefault();
3671                        var caretPos = seekNext(getLastValidPosition());
3672                        caret(input, e.shiftKey ? pos.begin : caretPos, caretPos, true);
3673                    } else if (k === Inputmask.keyCode.HOME && !e.shiftKey || k === Inputmask.keyCode.PAGE_UP) {
3674                        e.preventDefault();
3675                        caret(input, 0, e.shiftKey ? pos.begin : 0, true);
3676                    } else if ((opts.undoOnEscape && k === Inputmask.keyCode.ESCAPE || k === 90 && e.ctrlKey) && e.altKey !== true) {
3677                        checkVal(input, true, false, undoValue.split(""));
3678                        $input.trigger("click");
3679                    } else if (k === Inputmask.keyCode.INSERT && !(e.shiftKey || e.ctrlKey)) {
3680                        opts.insertMode = !opts.insertMode;
3681                        input.setAttribute("im-insert", opts.insertMode);
3682                    } else if (opts.tabThrough === true && k === Inputmask.keyCode.TAB) {
3683                        if (e.shiftKey === true) {
3684                            if (getTest(pos.begin).match.fn === null) {
3685                                pos.begin = seekNext(pos.begin);
3686                            }
3687                            pos.end = seekPrevious(pos.begin, true);
3688                            pos.begin = seekPrevious(pos.end, true);
3689                        } else {
3690                            pos.begin = seekNext(pos.begin, true);
3691                            pos.end = seekNext(pos.begin, true);
3692                            if (pos.end < getMaskSet().maskLength) pos.end--;
3693                        }
3694                        if (pos.begin < getMaskSet().maskLength) {
3695                            e.preventDefault();
3696                            caret(input, pos.begin, pos.end);
3697                        }
3698                    }
3699                    opts.onKeyDown.call(this, e, getBuffer(), caret(input).begin, opts);
3700                    ignorable = $.inArray(k, opts.ignorables) !== -1;
3701                },
3702                keypressEvent: function keypressEvent(e, checkval, writeOut, strict, ndx) {
3703                    var input = this, $input = $(input), k = e.which || e.charCode || e.keyCode;
3704                    if (checkval !== true && !(e.ctrlKey && e.altKey) && (e.ctrlKey || e.metaKey || ignorable)) {
3705                        if (k === Inputmask.keyCode.ENTER && undoValue !== getBuffer().join("")) {
3706                            undoValue = getBuffer().join("");
3707                            setTimeout(function() {
3708                                $input.trigger("change");
3709                            }, 0);
3710                        }
3711                        return true;
3712                    } else {
3713                        if (k) {
3714                            if (k === 46 && e.shiftKey === false && opts.radixPoint !== "") k = opts.radixPoint.charCodeAt(0);
3715                            var pos = checkval ? {
3716                                begin: ndx,
3717                                end: ndx
3718                            } : caret(input), forwardPosition, c = String.fromCharCode(k), offset = 0;
3719                            if (opts._radixDance && opts.numericInput) {
3720                                var caretPos = getBuffer().indexOf(opts.radixPoint.charAt(0)) + 1;
3721                                if (pos.begin <= caretPos) {
3722                                    if (k === opts.radixPoint.charCodeAt(0)) offset = 1;
3723                                    pos.begin -= 1;
3724                                    pos.end -= 1;
3725                                }
3726                            }
3727                            getMaskSet().writeOutBuffer = true;
3728                            var valResult = isValid(pos, c, strict);
3729                            if (valResult !== false) {
3730                                resetMaskSet(true);
3731                                forwardPosition = valResult.caret !== undefined ? valResult.caret : seekNext(valResult.pos.begin ? valResult.pos.begin : valResult.pos);
3732                                getMaskSet().p = forwardPosition;
3733                            }
3734                            forwardPosition = (opts.numericInput && valResult.caret === undefined ? seekPrevious(forwardPosition) : forwardPosition) + offset;
3735                            if (writeOut !== false) {
3736                                setTimeout(function() {
3737                                    opts.onKeyValidation.call(input, k, valResult, opts);
3738                                }, 0);
3739                                if (getMaskSet().writeOutBuffer && valResult !== false) {
3740                                    var buffer = getBuffer();
3741                                    writeBuffer(input, buffer, forwardPosition, e, checkval !== true);
3742                                }
3743                            }
3744                            e.preventDefault();
3745                            if (checkval) {
3746                                if (valResult !== false) valResult.forwardPosition = forwardPosition;
3747                                return valResult;
3748                            }
3749                        }
3750                    }
3751                },
3752                pasteEvent: function pasteEvent(e) {
3753                    var input = this, ev = e.originalEvent || e, $input = $(input), inputValue = input.inputmask._valueGet(true), caretPos = caret(input), tempValue;
3754                    if (isRTL) {
3755                        tempValue = caretPos.end;
3756                        caretPos.end = caretPos.begin;
3757                        caretPos.begin = tempValue;
3758                    }
3759                    var valueBeforeCaret = inputValue.substr(0, caretPos.begin), valueAfterCaret = inputValue.substr(caretPos.end, inputValue.length);
3760                    if (valueBeforeCaret === (isRTL ? getBufferTemplate().reverse() : getBufferTemplate()).slice(0, caretPos.begin).join("")) valueBeforeCaret = "";
3761                    if (valueAfterCaret === (isRTL ? getBufferTemplate().reverse() : getBufferTemplate()).slice(caretPos.end).join("")) valueAfterCaret = "";
3762                    if (window.clipboardData && window.clipboardData.getData) {
3763                        inputValue = valueBeforeCaret + window.clipboardData.getData("Text") + valueAfterCaret;
3764                    } else if (ev.clipboardData && ev.clipboardData.getData) {
3765                        inputValue = valueBeforeCaret + ev.clipboardData.getData("text/plain") + valueAfterCaret;
3766                    } else return true;
3767                    var pasteValue = inputValue;
3768                    if ($.isFunction(opts.onBeforePaste)) {
3769                        pasteValue = opts.onBeforePaste.call(inputmask, inputValue, opts);
3770                        if (pasteValue === false) {
3771                            return e.preventDefault();
3772                        }
3773                        if (!pasteValue) {
3774                            pasteValue = inputValue;
3775                        }
3776                    }
3777                    checkVal(input, false, false, pasteValue.toString().split(""));
3778                    writeBuffer(input, getBuffer(), seekNext(getLastValidPosition()), e, undoValue !== getBuffer().join(""));
3779                    return e.preventDefault();
3780                },
3781                inputFallBackEvent: function inputFallBackEvent(e) {
3782                    function radixPointHandler(input, inputValue, caretPos) {
3783                        if (inputValue.charAt(caretPos.begin - 1) === "." && opts.radixPoint !== "") {
3784                            inputValue = inputValue.split("");
3785                            inputValue[caretPos.begin - 1] = opts.radixPoint.charAt(0);
3786                            inputValue = inputValue.join("");
3787                        }
3788                        return inputValue;
3789                    }
3790                    function ieMobileHandler(input, inputValue, caretPos) {
3791                        if (iemobile) {
3792                            var inputChar = inputValue.replace(getBuffer().join(""), "");
3793                            if (inputChar.length === 1) {
3794                                var iv = inputValue.split("");
3795                                iv.splice(caretPos.begin, 0, inputChar);
3796                                inputValue = iv.join("");
3797                            }
3798                        }
3799                        return inputValue;
3800                    }
3801                    var input = this, inputValue = input.inputmask._valueGet();
3802                    if (getBuffer().join("") !== inputValue) {
3803                        var caretPos = caret(input);
3804                        inputValue = radixPointHandler(input, inputValue, caretPos);
3805                        inputValue = ieMobileHandler(input, inputValue, caretPos);
3806                        if (getBuffer().join("") !== inputValue) {
3807                            var buffer = getBuffer().join(""), offset = !opts.numericInput && inputValue.length > buffer.length ? -1 : 0, frontPart = inputValue.substr(0, caretPos.begin), backPart = inputValue.substr(caretPos.begin), frontBufferPart = buffer.substr(0, caretPos.begin + offset), backBufferPart = buffer.substr(caretPos.begin + offset);
3808                            var selection = caretPos, entries = "", isEntry = false;
3809                            if (frontPart !== frontBufferPart) {
3810                                var fpl = (isEntry = frontPart.length >= frontBufferPart.length) ? frontPart.length : frontBufferPart.length, i;
3811                                for (i = 0; frontPart.charAt(i) === frontBufferPart.charAt(i) && i < fpl; i++) {}
3812                                if (isEntry) {
3813                                    selection.begin = i - offset;
3814                                    entries += frontPart.slice(i, selection.end);
3815                                }
3816                            }
3817                            if (backPart !== backBufferPart) {
3818                                if (backPart.length > backBufferPart.length) {
3819                                    entries += backPart.slice(0, 1);
3820                                } else {
3821                                    if (backPart.length < backBufferPart.length) {
3822                                        selection.end += backBufferPart.length - backPart.length;
3823                                        if (!isEntry && opts.radixPoint !== "" && backPart === "" && frontPart.charAt(selection.begin + offset - 1) === opts.radixPoint) {
3824                                            selection.begin--;
3825                                            entries = opts.radixPoint;
3826                                        }
3827                                    }
3828                                }
3829                            }
3830                            writeBuffer(input, getBuffer(), {
3831                                begin: selection.begin + offset,
3832                                end: selection.end + offset
3833                            });
3834                            if (entries.length > 0) {
3835                                $.each(entries.split(""), function(ndx, entry) {
3836                                    var keypress = new $.Event("keypress");
3837                                    keypress.which = entry.charCodeAt(0);
3838                                    ignorable = false;
3839                                    EventHandlers.keypressEvent.call(input, keypress);
3840                                });
3841                            } else {
3842                                if (selection.begin === selection.end - 1) {
3843                                    selection.begin = seekPrevious(selection.begin + 1);
3844                                    if (selection.begin === selection.end - 1) {
3845                                        caret(input, selection.begin);
3846                                    } else {
3847                                        caret(input, selection.begin, selection.end);
3848                                    }
3849                                }
3850                                var keydown = new $.Event("keydown");
3851                                keydown.keyCode = opts.numericInput ? Inputmask.keyCode.BACKSPACE : Inputmask.keyCode.DELETE;
3852                                EventHandlers.keydownEvent.call(input, keydown);
3853                            }
3854                            e.preventDefault();
3855                        }
3856                    }
3857                },
3858                beforeInputEvent: function beforeInputEvent(e) {
3859                    if (e.cancelable) {
3860                        var input = this;
3861                        switch (e.inputType) {
3862                          case "insertText":
3863                            $.each(e.data.split(""), function(ndx, entry) {
3864                                var keypress = new $.Event("keypress");
3865                                keypress.which = entry.charCodeAt(0);
3866                                ignorable = false;
3867                                EventHandlers.keypressEvent.call(input, keypress);
3868                            });
3869                            return e.preventDefault();
3870
3871                          case "deleteContentBackward":
3872                            var keydown = new $.Event("keydown");
3873                            keydown.keyCode = Inputmask.keyCode.BACKSPACE;
3874                            EventHandlers.keydownEvent.call(input, keydown);
3875                            return e.preventDefault();
3876
3877                          case "deleteContentForward":
3878                            var keydown = new $.Event("keydown");
3879                            keydown.keyCode = Inputmask.keyCode.DELETE;
3880                            EventHandlers.keydownEvent.call(input, keydown);
3881                            return e.preventDefault();
3882                        }
3883                    }
3884                },
3885                setValueEvent: function setValueEvent(e) {
3886                    this.inputmask.refreshValue = false;
3887                    var input = this, value = e && e.detail ? e.detail[0] : arguments[1], value = value || input.inputmask._valueGet(true);
3888                    if ($.isFunction(opts.onBeforeMask)) value = opts.onBeforeMask.call(inputmask, value, opts) || value;
3889                    value = value.split("");
3890                    checkVal(input, true, false, value);
3891                    undoValue = getBuffer().join("");
3892                    if ((opts.clearMaskOnLostFocus || opts.clearIncomplete) && input.inputmask._valueGet() === getBufferTemplate().join("")) {
3893                        input.inputmask._valueSet("");
3894                    }
3895                },
3896                focusEvent: function focusEvent(e) {
3897                    var input = this, nptValue = input.inputmask._valueGet();
3898                    if (opts.showMaskOnFocus) {
3899                        if (nptValue !== getBuffer().join("")) {
3900                            writeBuffer(input, getBuffer(), seekNext(getLastValidPosition()));
3901                        } else if (mouseEnter === false) {
3902                            caret(input, seekNext(getLastValidPosition()));
3903                        }
3904                    }
3905                    if (opts.positionCaretOnTab === true && mouseEnter === false) {
3906                        EventHandlers.clickEvent.apply(input, [ e, true ]);
3907                    }
3908                    undoValue = getBuffer().join("");
3909                },
3910                mouseleaveEvent: function mouseleaveEvent(e) {
3911                    var input = this;
3912                    mouseEnter = false;
3913                    if (opts.clearMaskOnLostFocus && document.activeElement !== input) {
3914                        HandleNativePlaceholder(input, originalPlaceholder);
3915                    }
3916                },
3917                clickEvent: function clickEvent(e, tabbed) {
3918                    function doRadixFocus(clickPos) {
3919                        if (opts.radixPoint !== "") {
3920                            var vps = getMaskSet().validPositions;
3921                            if (vps[clickPos] === undefined || vps[clickPos].input === getPlaceholder(clickPos)) {
3922                                if (clickPos < seekNext(-1)) return true;
3923                                var radixPos = $.inArray(opts.radixPoint, getBuffer());
3924                                if (radixPos !== -1) {
3925                                    for (var vp in vps) {
3926                                        if (radixPos < vp && vps[vp].input !== getPlaceholder(vp)) {
3927                                            return false;
3928                                        }
3929                                    }
3930                                    return true;
3931                                }
3932                            }
3933                        }
3934                        return false;
3935                    }
3936                    var input = this;
3937                    setTimeout(function() {
3938                        if (document.activeElement === input) {
3939                            var selectedCaret = caret(input);
3940                            if (tabbed) {
3941                                if (isRTL) {
3942                                    selectedCaret.end = selectedCaret.begin;
3943                                } else {
3944                                    selectedCaret.begin = selectedCaret.end;
3945                                }
3946                            }
3947                            if (selectedCaret.begin === selectedCaret.end) {
3948                                switch (opts.positionCaretOnClick) {
3949                                  case "none":
3950                                    break;
3951
3952                                  case "select":
3953                                    caret(input, 0, getBuffer().length);
3954                                    break;
3955
3956                                  case "ignore":
3957                                    caret(input, seekNext(getLastValidPosition()));
3958                                    break;
3959
3960                                  case "radixFocus":
3961                                    if (doRadixFocus(selectedCaret.begin)) {
3962                                        var radixPos = getBuffer().join("").indexOf(opts.radixPoint);
3963                                        caret(input, opts.numericInput ? seekNext(radixPos) : radixPos);
3964                                        break;
3965                                    }
3966
3967                                  default:
3968                                    var clickPosition = selectedCaret.begin, lvclickPosition = getLastValidPosition(clickPosition, true), lastPosition = seekNext(lvclickPosition);
3969                                    if (clickPosition < lastPosition) {
3970                                        caret(input, !isMask(clickPosition, true) && !isMask(clickPosition - 1, true) ? seekNext(clickPosition) : clickPosition);
3971                                    } else {
3972                                        var lvp = getMaskSet().validPositions[lvclickPosition], tt = getTestTemplate(lastPosition, lvp ? lvp.match.locator : undefined, lvp), placeholder = getPlaceholder(lastPosition, tt.match);
3973                                        if (placeholder !== "" && getBuffer()[lastPosition] !== placeholder && tt.match.optionalQuantifier !== true && tt.match.newBlockMarker !== true || !isMask(lastPosition, opts.keepStatic) && tt.match.def === placeholder) {
3974                                            var newPos = seekNext(lastPosition);
3975                                            if (clickPosition >= newPos || clickPosition === lastPosition) {
3976                                                lastPosition = newPos;
3977                                            }
3978                                        }
3979                                        caret(input, lastPosition);
3980                                    }
3981                                    break;
3982                                }
3983                            }
3984                        }
3985                    }, 0);
3986                },
3987                cutEvent: function cutEvent(e) {
3988                    var input = this, $input = $(input), pos = caret(input), ev = e.originalEvent || e;
3989                    var clipboardData = window.clipboardData || ev.clipboardData, clipData = isRTL ? getBuffer().slice(pos.end, pos.begin) : getBuffer().slice(pos.begin, pos.end);
3990                    clipboardData.setData("text", isRTL ? clipData.reverse().join("") : clip
3990Data.join(""));
3991                    if (document.execCommand) document.execCommand("copy");
3992                    handleRemove(input, Inputmask.keyCode.DELETE, pos);
3993                    writeBuffer(input, getBuffer(), getMaskSet().p, e, undoValue !== getBuffer().join(""));
3994                },
3995                blurEvent: function blurEvent(e) {
3996                    var $input = $(this), input = this;
3997                    if (input.inputmask) {
3998                        HandleNativePlaceholder(input, originalPlaceholder);
3999                        var nptValue = input.inputmask._valueGet(), buffer = getBuffer().slice();
4000                        if (nptValue !== "" || colorMask !== undefined) {
4001                            if (opts.clearMaskOnLostFocus) {
4002                                if (getLastValidPosition() === -1 && nptValue === getBufferTemplate().join("")) {
4003                                    buffer = [];
4004                                } else {
4005                                    clearOptionalTail(buffer);
4006                                }
4007                            }
4008                            if (isComplete(buffer) === false) {
4009                                setTimeout(function() {
4010                                    $input.trigger("incomplete");
4011                                }, 0);
4012                                if (opts.clearIncomplete) {
4013                                    resetMaskSet();
4014                                    if (opts.clearMaskOnLostFocus) {
4015                                        buffer = [];
4016                                    } else {
4017                                        buffer = getBufferTemplate().slice();
4018                                    }
4019                                }
4020                            }
4021                            writeBuffer(input, buffer, undefined, e);
4022                        }
4023                        if (undoValue !== getBuffer().join("")) {
4024                            undoValue = buffer.join("");
4025                            $input.trigger("change");
4026                        }
4027                    }
4028                },
4029                mouseenterEvent: function mouseenterEvent(e) {
4030                    var input = this;
4031                    mouseEnter = true;
4032                    if (document.activeElement !== input && opts.showMaskOnHover) {
4033                        HandleNativePlaceholder(input, (isRTL ? getBuffer().slice().reverse() : getBuffer()).join(""));
4034                    }
4035                },
4036                submitEvent: function submitEvent(e) {
4037                    if (undoValue !== getBuffer().join("")) {
4038                        $el.trigger("change");
4039                    }
4040                    if (opts.clearMaskOnLostFocus && getLastValidPosition() === -1 && el.inputmask._valueGet && el.inputmask._valueGet() === getBufferTemplate().join("")) {
4041                        el.inputmask._valueSet("");
4042                    }
4043                    if (opts.clearIncomplete && isComplete(getBuffer()) === false) {
4044                        el.inputmask._valueSet("");
4045                    }
4046                    if (opts.removeMaskOnSubmit) {
4047                        el.inputmask._valueSet(el.inputmask.unmaskedvalue(), true);
4048                        setTimeout(function() {
4049                            writeBuffer(el, getBuffer());
4050                        }, 0);
4051                    }
4052                },
4053                resetEvent: function resetEvent(e) {
4054                    el.inputmask.refreshValue = true;
4055                    setTimeout(function() {
4056                        $el.trigger("setvalue");
4057                    }, 0);
4058                }
4059            };
4060            function checkVal(input, writeOut, strict, nptvl, initiatingEvent) {
4061                var inputmask = this || input.inputmask, inputValue = nptvl.slice(), charCodes = "", initialNdx = -1, result = undefined;
4062                function isTemplateMatch(ndx, charCodes) {
4063                    var charCodeNdx = getMaskTemplate(true, 0, false).slice(ndx, seekNext(ndx)).join("").replace(/'/g, "").indexOf(charCodes);
4064                    return charCodeNdx !== -1 && !isMask(ndx) && (getTest(ndx).match.nativeDef === charCodes.charAt(0) || getTest(ndx).match.fn === null && getTest(ndx).match.nativeDef === "'" + charCodes.charAt(0) || getTest(ndx).match.nativeDef === " " && (getTest(ndx + 1).match.nativeDef === charCodes.charAt(0) || getTest(ndx + 1).match.fn === null && getTest(ndx + 1).match.nativeDef === "'" + charCodes.charAt(0)));
4065                }
4066                resetMaskSet();
4067                if (!strict && opts.autoUnmask !== true) {
4068                    var staticInput = getBufferTemplate().slice(0, seekNext(-1)).join(""), matches = inputValue.join("").match(new RegExp("^" + Inputmask.escapeRegex(staticInput), "g"));
4069                    if (matches && matches.length > 0) {
4070                        inputValue.splice(0, matches.length * staticInput.length);
4071                        initialNdx = seekNext(initialNdx);
4072                    }
4073                } else {
4074                    initialNdx = seekNext(initialNdx);
4075                }
4076                if (initialNdx === -1) {
4077                    getMaskSet().p = seekNext(initialNdx);
4078                    initialNdx = 0;
4079                } else getMaskSet().p = initialNdx;
4080                inputmask.caretPos = {
4081                    begin: initialNdx
4082                };
4083                $.each(inputValue, function(ndx, charCode) {
4084                    if (charCode !== undefined) {
4085                        if (getMaskSet().validPositions[ndx] === undefined && inputValue[ndx] === getPlaceholder(ndx) && isMask(ndx, true) && isValid(ndx, inputValue[ndx], true, undefined, undefined, true) === false) {
4086                            getMaskSet().p++;
4087                        } else {
4088                            var keypress = new $.Event("_checkval");
4089                            keypress.which = charCode.charCodeAt(0);
4090                            charCodes += charCode;
4091                            var lvp = getLastValidPosition(undefined, true);
4092                            if (!isTemplateMatch(initialNdx, charCodes)) {
4093                                result = EventHandlers.keypressEvent.call(input, keypress, true, false, strict, inputmask.caretPos.begin);
4094                                if (result) {
4095                                    initialNdx = inputmask.caretPos.begin + 1;
4096                                    charCodes = "";
4097                                }
4098                            } else {
4099                                result = EventHandlers.keypressEvent.call(input, keypress, true, false, strict, lvp + 1);
4100                            }
4101                            if (result) {
4102                                writeBuffer(undefined, getBuffer(), result.forwardPosition, keypress, false);
4103                                inputmask.caretPos = {
4104                                    begin: result.forwardPosition,
4105                                    end: result.forwardPosition
4106                                };
4107                            }
4108                        }
4109                    }
4110                });
4111                if (writeOut) writeBuffer(input, getBuffer(), result ? result.forwardPosition : undefined, initiatingEvent || new $.Event("checkval"), initiatingEvent && initiatingEvent.type === "input");
4112            }
4113            function unmaskedvalue(input) {
4114                if (input) {
4115                    if (input.inputmask === undefined) {
4116                        return input.value;
4117                    }
4118                    if (input.inputmask && input.inputmask.refreshValue) {
4119                        EventHandlers.setValueEvent.call(input);
4120                    }
4121                }
4122                var umValue = [], vps = getMaskSet().validPositions;
4123                for (var pndx in vps) {
4124                    if (vps[pndx].match && vps[pndx].match.fn != null) {
4125                        umValue.push(vps[pndx].input);
4126                    }
4127                }
4128                var unmaskedValue = umValue.length === 0 ? "" : (isRTL ? umValue.reverse() : umValue).join("");
4129                if ($.isFunction(opts.onUnMask)) {
4130                    var bufferValue = (isRTL ? getBuffer().slice().reverse() : getBuffer()).join("");
4131                    unmaskedValue = opts.onUnMask.call(inputmask, bufferValue, unmaskedValue, opts);
4132                }
4133                return unmaskedValue;
4134            }
4135            function caret(input, begin, end, notranslate) {
4136                function translatePosition(pos) {
4137                    if (isRTL && typeof pos === "number" && (!opts.greedy || opts.placeholder !== "") && el) {
4138                        pos = el.inputmask._valueGet().length - pos;
4139                    }
4140                    return pos;
4141                }
4142                var range;
4143                if (begin !== undefined) {
4144                    if ($.isArray(begin)) {
4145                        end = isRTL ? begin[0] : begin[1];
4146                        begin = isRTL ? begin[1] : begin[0];
4147                    }
4148                    if (begin.begin !== undefined) {
4149                        end = isRTL ? begin.begin : begin.end;
4150                        begin = isRTL ? begin.end : begin.begin;
4151                    }
4152                    if (typeof begin === "number") {
4153                        begin = notranslate ? begin : translatePosition(begin);
4154                        end = notranslate ? end : translatePosition(end);
4155                        end = typeof end == "number" ? end : begin;
4156                        var scrollCalc = parseInt(((input.ownerDocument.defaultView || window).getComputedStyle ? (input.ownerDocument.defaultView || window).getComputedStyle(input, null) : input.currentStyle).fontSize) * end;
4157                        input.scrollLeft = scrollCalc > input.scrollWidth ? scrollCalc : 0;
4158                        input.inputmask.caretPos = {
4159                            begin: begin,
4160                            end: end
4161                        };
4162                        if (input === document.activeElement) {
4163                            if ("selectionStart" in input) {
4164                                input.selectionStart = begin;
4165                                input.selectionEnd = end;
4166                            } else if (window.getSelection) {
4167                                range = document.createRange();
4168                                if (input.firstChild === undefined || input.firstChild === null) {
4169                                    var textNode = document.createTextNode("");
4170                                    input.appendChild(textNode);
4171                                }
4172                                range.setStart(input.firstChild, begin < input.inputmask._valueGet().length ? begin : input.inputmask._valueGet().length);
4173                                range.setEnd(input.firstChild, end < input.inputmask._valueGet().length ? end : input.inputmask._valueGet().length);
4174                                range.collapse(true);
4175                                var sel = window.getSelection();
4176                                sel.removeAllRanges();
4177                                sel.addRange(range);
4178                            } else if (input.createTextRange) {
4179                                range = input.createTextRange();
4180                                range.collapse(true);
4181                                range.moveEnd("character", end);
4182                                range.moveStart("character", begin);
4183                                range.select();
4184                            }
4185                            renderColorMask(input, {
4186                                begin: begin,
4187                                end: end
4188                            });
4189                        }
4190                    }
4191                } else {
4192                    if ("selectionStart" in input) {
4193                        begin = input.selectionStart;
4194                        end = input.selectionEnd;
4195                    } else if (window.getSelection) {
4196                        range = window.getSelection().getRangeAt(0);
4197                        if (range.commonAncestorContainer.parentNode === input || range.commonAncestorContainer === input) {
4198                            begin = range.startOffset;
4199                            end = range.endOffset;
4200                        }
4201                    } else if (document.selection && document.selection.createRange) {
4202                        range = document.selection.createRange();
4203                        begin = 0 - range.duplicate().moveStart("character", -input.inputmask._valueGet().length);
4204                        end = begin + range.text.length;
4205                    }
4206                    return {
4207                        begin: notranslate ? begin : translatePosition(begin),
4208                        end: notranslate ? end : translatePosition(en
4208d)
4209                    };
4210                }
4211            }
4212            function determineLastRequiredPosition(returnDefinition) {
4213                var buffer = getMaskTemplate(true, getLastValidPosition(), true, true), bl = buffer.length, pos, lvp = getLastValidPosition(), positions = {}, lvTest = getMaskSet().validPositions[lvp], ndxIntlzr = lvTest !== undefined ? lvTest.locator.slice() : undefined, testPos;
4214                for (pos = lvp + 1; pos < buffer.length; pos++) {
4215                    testPos = getTestTemplate(pos, ndxIntlzr, pos - 1);
4216                    ndxIntlzr = testPos.locator.slice();
4217                    positions[pos] = $.extend(true, {}, testPos);
4218                }
4219                var lvTestAlt = lvTest && lvTest.alternation !== undefined ? lvTest.locator[lvTest.alternation] : undefined;
4220                for (pos = bl - 1; pos > lvp; pos--) {
4221                    testPos = positions[pos];
4222                    if ((testPos.match.optionality || testPos.match.optionalQuantifier && testPos.match.newBlockMarker || lvTestAlt && (lvTestAlt !== positions[pos].locator[lvTest.alternation] && testPos.match.fn != null || testPos.match.fn === null && testPos.locator[lvTest.alternation] && checkAlternationMatch(testPos.locator[lvTest.alternation].toString().split(","), lvTestAlt.toString().split(",")) && getTests(pos)[0].def !== "")) && buffer[pos] === getPlaceholder(pos, testPos.match)) {
4223                        bl--;
4224                    } else break;
4225                }
4226                return returnDefinition ? {
4227                    l: bl,
4228                    def: positions[bl] ? positions[bl].match : undefined
4229                } : bl;
4230            }
4231            function clearOptionalTail(buffer) {
4232                buffer.length = 0;
4233                var template = getMaskTemplate(true, 0, true, undefined, true), lmnt, validPos;
4234                while (lmnt = template.shift(), lmnt !== undefined) {
4235                    buffer.push(lmnt);
4236                }
4237                return buffer;
4238            }
4239            function isComplete(buffer) {
4240                if ($.isFunction(opts.isComplete)) return opts.isComplete(buffer, opts);
4241                if (opts.repeat === "*") return undefined;
4242                var complete = false, lrp = determineLastRequiredPosition(true), aml = seekPrevious(lrp.l);
4243                if (lrp.def === undefined || lrp.def.newBlockMarker || lrp.def.optionality || lrp.def.optionalQuantifier) {
4244                    complete = true;
4245                    for (var i = 0; i <= aml; i++) {
4246                        var test = getTestTemplate(i).match;
4247                        if (test.fn !== null && getMaskSet().validPositions[i] === undefined && test.optionality !== true && test.optionalQuantifier !== true || test.fn === null && buffer[i] !== getPlaceholder(i, test)) {
4248                            complete = false;
4249                            break;
4250                        }
4251                    }
4252                }
4253                return complete;
4254            }
4255            function handleRemove(input, k, pos, strict, fromIsValid) {
4256                if (opts.numericInput || isRTL) {
4257                    if (k === Inputmask.keyCode.BACKSPACE) {
4258                        k = Inputmask.keyCode.DELETE;
4259                    } else if (k === Inputmask.keyCode.DELETE) {
4260                        k = Inputmask.keyCode.BACKSPACE;
4261                    }
4262                    if (isRTL) {
4263                        var pend = pos.end;
4264                        pos.end = pos.begin;
4265                        pos.begin = pend;
4266                    }
4267                }
4268                if (k === Inputmask.keyCode.BACKSPACE && pos.end - pos.begin < 1) {
4269                    pos.begin = seekPrevious(pos.begin);
4270                    if (getMaskSet().validPositions[pos.begin] !== undefined && getMaskSet().validPositions[pos.begin].input === opts.groupSeparator) {
4271                        pos.begin--;
4272                    }
4273                } else if (k === Inputmask.keyCode.DELETE && pos.begin === pos.end) {
4274                    pos.end = isMask(pos.end, true) && getMaskSet().validPositions[pos.end] && getMaskSet().validPositions[pos.end].input !== opts.radixPoint ? pos.end + 1 : seekNext(pos.end) + 1;
4275                    if (getMaskSet().validPositions[pos.begin] !== undefined && getMaskSet().validPositions[pos.begin].input === opts.groupSeparator) {
4276                        pos.end++;
4277                    }
4278                }
4279                revalidateMask(pos);
4280                if (strict !== true && opts.keepStatic !== false || opts.regex !== null) {
4281                    var result = alternate(true);
4282                    if (result) {
4283                        var newPos = result.caret !== undefined ? result.caret : result.pos ? seekNext(result.pos.begin ? result.pos.begin : result.pos) : getLastValidPosition(-1, true);
4284                        if (k !== Inputmask.keyCode.DELETE || pos.begin > newPos) {
4285                            pos.begin == newPos;
4286                        }
4287                    }
4288                }
4289                var lvp = getLastValidPosition(pos.begin, true);
4290                if (lvp < pos.begin || pos.begin === -1) {
4291                    getMaskSet().p = seekNext(lvp);
4292                } else if (strict !== true) {
4293                    getMaskSet().p = pos.begin;
4294                    if (fromIsValid !== true) {
4295                        while (getMaskSet().p < lvp && getMaskSet().validPositions[getMaskSet().p] === undefined) {
4296                            getMaskSet().p++;
4297                        }
4298                    }
4299                }
4300            }
4301            function initializeColorMask(input) {
4302                var computedStyle = (input.ownerDocument.defaultView || window).getComputedStyle(input, null);
4303                function findCaretPos(clientx) {
4304                    var e = document.createElement("span"), caretPos;
4305                    for (var style in computedStyle) {
4306                        if (isNaN(style) && style.indexOf("font") !== -1) {
4307                            e.style[style] = computedStyle[style];
4308                        }
4309                    }
4310                    e.style.textTransform = computedStyle.textTransform;
4311                    e.style.letterSpacing = computedStyle.letterSpacing;
4312                    e.style.position = "absolute";
4313                    e.style.height = "auto";
4314                    e.style.width = "auto";
4315                    e.style.visibility = "hidden";
4316                    e.style.whiteSpace = "nowrap";
4317                    document.body.appendChild(e);
4318                    var inputText = input.inputmask._valueGet(), previousWidth = 0, itl;
4319                    for (caretPos = 0, itl = inputText.length; caretPos <= itl;
4319 caretPos++) {
4320                        e.innerHTML += inputText.charAt(caretPos) || "_";
4321                        if (e.offsetWidth >= clientx) {
4322                            var offset1 = clientx - previousWidth;
4323                            var offset2 = e.offsetWidth - clientx;
4324                            e.innerHTML = inputText.charAt(caretPos);
4325                            offset1 -= e.offsetWidth / 3;
4326                            caretPos = offset1 < offset2 ? caretPos - 1 : caretPos;
4327                            break;
4328                        }
4329                        previousWidth = e.offsetWidth;
4330                    }
4331                    document.body.removeChild(e);
4332                    return caretPos;
4333                }
4334                var template = document.createElement("div");
4335                template.style.width = computedStyle.width;
4336                template.style.textAlign = computedStyle.textAlign;
4337                colorMask = document.createElement("div");
4338                input.inputmask.colorMask = colorMask;
4339                colorMask.className = "im-colormask";
4340                input.parentNode.insertBefore(colorMask, input);
4341                input.parentNode.removeChild(input);
4342                colorMask.appendChild(input);
4343                colorMask.appendChild(template);
4344                input.style.left = template.offsetLeft + "px";
4345                $(colorMask).on("mouseleave", function(e) {
4346                    return EventHandlers.mouseleaveEvent.call(input, [ e ]);
4347                });
4348                $(colorMask).on("mouseenter", function(e) {
4349                    return EventHandlers.mouseenterEvent.call(input, [ e ]);
4350                });
4351                $(colorMask).on("click", function(e) {
4352                    caret(input, findCaretPos(e.clientX));
4353                    return EventHandlers.clickEvent.call(input, [ e ]);
4354                });
4355            }
4356            Inputmask.prototype.positionColorMask = function(input, template) {
4357                input.style.left = template.offsetLeft + "px";
4358            };
4359            function renderColorMask(input, caretPos, clear) {
4360                var maskTemplate = [], isStatic = false, test, testPos, ndxIntlzr, pos = 0;
4361                function setEntry(entry) {
4362                    if (entry === undefined) entry = "";
4363                    if (!isStatic && (test.fn === null || testPos.input === undefined)) {
4364                        isStatic = true;
4365                        maskTemplate.push("<span class='im-static'>" + entry);
4366                    } else if (isStatic && (test.fn !== null && testPos.input !== undefined || test.def === "")) {
4367                        isStatic = false;
4368                        var mtl = maskTemplate.length;
4369                        maskTemplate[mtl - 1] = maskTemplate[mtl - 1] + "</span>";
4370                        maskTemplate.push(entry);
4371                    } else maskTemplate.push(entry);
4372                }
4373                function setCaret() {
4374                    if (document.activeElement === input) {
4375                        maskTemplate.splice(caretPos.begin, 0, caretPos.begin === caretPos.end || caretPos.end > getMaskSet().maskLength ? '<mark class="im-caret" style="border-right-width: 1px;border-right-style: solid;">' : '<mark class="im-caret-select">');
4376                        maskTemplate.splice(caretPos.end + 1, 0, "</mark>");
4377                    }
4378                }
4379                if (colorMask !== undefined) {
4380                    var buffer = getBuffer();
4381                    if (caretPos === undefined) {
4382                        caretPos = caret(input);
4383                    } else if (caretPos.begin === undefined) {
4384                        caretPos = {
4385                            begin: caretPos,
4386                            end: caretPos
4387                        };
4388                    }
4389                    if (clear !== true) {
4390                        var lvp = getLastValidPosition();
4391                        do {
4392                            if (getMaskSet().validPositions[pos]) {
4393                                testPos = getMaskSet().validPositions[pos];
4394                                test = testPos.match;
4395                                ndxIntlzr = testPos.locator.slice();
4396                                setEntry(buffer[pos]);
4397                            } else {
4398                                testPos = getTestTemplate(pos, ndxIntlzr, pos - 1);
4399                                test = testPos.match;
4400                                ndxIntlzr = testPos.locator.slice();
4401                                if (opts.jitMasking === false || pos < lvp || typeof opts.jitMasking === "number" && isFinite(opts.jitMasking) && opts.jitMasking > pos) {
4402                                    setEntry(getPlaceholder(pos, test));
4403                                } else isStatic = false;
4404                            }
4405                            pos++;
4406                        } while ((maxLength === undefined || pos < maxLength) && (test.fn !== null || test.def !== "") || lvp > pos || isStatic);
4407                        if (isStatic) setEntry();
4408                        setCaret();
4409                    }
4410                    var template = colorMask.getElementsByTagName("div")[0];
4411                    template.innerHTML = maskTemplate.join("");
4412                    input.inputmask.positionColorMask(input, template);
4413                }
4414            }
4415            function mask(elem) {
4416                function isElementTypeSupported(input, opts) {
4417                    function patchValueProperty(npt) {
4418                        var valueGet;
4419                        var valueSet;
4420                        function patchValhook(type) {
4421                            if ($.valHooks && ($.valHooks[type] === undefined || $.valHooks[type].inputmaskpatch !== true)) {
4422                                var valhookGet = $.valHooks[type] && $.valHooks[type].get ? $.valHooks[type].get : function(elem) {
4423                                    return elem.value;
4424                                };
4425                                var valhookSet = $.valHooks[type] && $.valHooks[type].set ? $.valHooks[type].set : function(elem, value) {
4426                                    elem.value = value;
4427                                    return elem;
4428                                };
4429                                $.valHooks[type] = {
4430                                    get: function get(elem) {
4431                                        if (elem.inputmask) {
4432                                            if (elem.inputmask.opts.autoUnmask) {
4433                                                return elem.inputmask.unmaskedvalue();
4434                                            } else {
4435                                                var result = valhookGet(elem);
4436                                                return getLastValidPosition(undefined, undefined, elem.inputmask.maskset.validPositions) !== -1 || opts.nullable !== true ? result : "";
4437                                            }
4438                                        } else return valhookGet(elem);
4439                                    },
4440                                    set: function set(elem, value) {
4441                                        var $elem = $(elem), result;
4442                                        result = valhookSet(elem, value);
4443                                        if (elem.inputmask) {
4444                                            $elem.trigger("setvalue", [ value ]);
4445                                        }
4446                                        return result;
4447                                    },
4448                                    inputmaskpatch: true
4449                                };
4450                            }
4451                        }
4452                        function getter() {
4453                            if (this.inputmask) {
4454                                return this.inputmask.opts.autoUnmask ? this.inputmask.unmaskedvalue() : getLastValidPosition() !== -1 || opts.nullable !== true ? document.activeElement === this && opts.clearMaskOnLostFocus ? (isRTL ? clearOptionalTail(getBuffer().slice()).reverse() : clearOptionalTail(getBuffer().slice())).join("") : valueGet.call(this) : "";
4455                            } else return valueGet.call(this);
4456                        }
4457                        function setter(value) {
4458                            valueSet.call(this, value);
4459                            if (this.inputmask) {
4460                                $(this).trigger("setvalue", [ value ]);
4461                            }
4462                        }
4463                        function installNativeValueSetFallback(npt) {
4464                            EventRuler.on(npt, "mouseenter", function(event) {
4465                                var $input = $(this), input = this, value = input.inputmask._valueGet();
4466                                if (value !== getBuffer().join("")) {
4467                                    $input.trigger("setvalue");
4468                                }
4469                            });
4470                        }
4471                        if (!npt.inputmask.__valueGet) {
4472                            if (opts.noValuePatching !== true) {
4473                                if (Object.getOwnPropertyDescriptor) {
4474                                    if (typeof Object.getPrototypeOf 
4474!== "function") {
4475                                        Object.getPrototypeOf = _typeof("test".__proto__) === "object" ? function(object) {
4476                                            return object.__proto__;
4477                                        } : function(object) {
4478                                            return object.constructor.prototype;
4479                                        };
4480                                    }
4481                                    var valueProperty = Object.getPrototypeOf ? Object.getOwnPropertyDescriptor(Object.getPrototypeOf(npt), "value") : undefined;
4482                                    if (valueProperty && valueProperty.get && valueProperty.set) {
4483                                        valueGet = valueProperty.get;
4484                                        valueSet = valueProperty.set;
4485                                        Object.defineProperty(npt, "value", {
4486                                            get: getter,
4487                                            set: setter,
4488                                            configurable: true
4489                                        });
4490                                    } else if (npt.tagName !== "INPUT") {
4491                                        valueGet = function valueGet() {
4492                                            return this.textContent;
4493                                        };
4494                                        valueSet = function valueSet(value) {
4495                                            this.textContent = value;
4496                                        };
4497                                        Object.defineProperty(npt, "value", {
4498                                            get: getter,
4499                                            set: setter,
4500                                            configurable: true
4501                                        });
4502                                    }
4503                                } else if (document.__lookupGetter__ && npt.__lookupGetter__("value")) {
4504                                    valueGet = npt.__lookupGetter__("value");
4505                                    valueSet = npt.__lookupSetter__("value");
4506                                    npt.__defineGetter__("value", getter);
4507                                    npt.__defineSetter__("value", setter);
4508                                }
4509                                npt.inputmask.__valueGet = valueGet;
4510                                npt.inputmask.__valueSet = valueSet;
4511                            }
4512                            npt.inputmask._valueGet = function(overruleRTL) {
4513                                return isRTL && overruleRTL !== true ? valueGet.call(this.el).split("").reverse().join("") : valueGet.call(this.el);
4514                            };
4515                            npt.inputmask._valueSet = function(value, overruleRTL) {
4516                                valueSet.call(this.el, value === null || value === undefined ? "" : overruleRTL !== true && isRTL ? value.split("").reverse().join("") : value);
4517                            };
4518                            if (valueGet === undefined) {
4519                                valueGet = function valueGet() {
4520                                    return this.value;
4521                                };
4522                                valueSet = function valueSet(value) {
4523                                    this.value = value;
4524                                };
4525                                patchValhook(npt.type);
4526                                installNativeValueSetFallback(npt);
4527                            }
4528                        }
4529                    }
4530                    var elementType = input.getAttribute("type");
4531                    var isSupported = input.tagName === "INPUT" && $.inArray(elementType, opts.supportsInputType) !== -1 || input.isContentEditable || input.tagName === "TEXTAREA";
4532                    if (!isSupported) {
4533                        if (input.tagName === "INPUT") {
4534                            var el = document.createElement("input");
4535                            el.setAttribute("type", elementType);
4536                            isSupported = el.type === "text";
4537                            el = null;
4538                        } else isSupported = "partial";
4539                    }
4540                    if (isSupported !== false) {
4541                        patchValueProperty(input);
4542                    } else input.inputmask = undefined;
4543                    return isSupported;
4544                }
4545                EventRuler.off(elem);
4546                var isSupported = isElementTypeSupported(elem, opts);
4547                if (isSupported !== false) {
4548                    el = elem;
4549                    $el = $(el);
4550                    originalPlaceholder = el.placeholder;
4551                    maxLength = el !== undefined ? el.maxLength : undefined;
4552                    if (maxLength === -1) maxLength = undefined;
4553                    if (opts.colorMask === true) {
4554                        initializeColorMask(el);
4555                    }
4556                    if (mobile) {
4557                        if ("inputmode" in el) {
4558                            el.inputmode = opts.inputmode;
4559                            el.setAttribute("inputmode", opts.inputmode);
4560                        }
4561                        if (opts.disablePredictiveText === true) {
4562                            if ("autocorrect" in el) {
4563                                el.autocorrect = false;
4564                            } else {
4565                                if (opts.colorMask !== true) {
4566                                    initializeColorMask(el);
4567                                }
4568                                el.type = "password";
4569                            }
4570                        }
4571                    }
4572                    if (isSupported === true) {
4573                        el.setAttribute("im-insert", opts.insertMode);
4574                        EventRuler.on(el, "submit", EventHandlers.submitEvent);
4575                        EventRuler.on(el, "reset", EventHandlers.resetEvent);
4576                        EventRuler.on(el, "blur", EventHandlers.blurEvent);
4577                        EventRuler.on(el, "focus", EventHandlers.focusEvent);
4578                        if (opts.colorMask !== true) {
4579                            EventRuler.on(el, "click", EventHandlers.clickEvent);
4580                            EventRuler.on(el, "mouseleave", EventHandlers.mouseleaveEvent);
4581                            EventRuler.on(el, "mouseenter", EventHandlers.mouseenterEvent);
4582                        }
4583                        EventRuler.on(el, "paste", EventHandlers.pasteEvent);
4584                        EventRuler.on(el, "cut", EventHandlers.cutEvent);
4585                        EventRuler.on(el, "complete", opts.oncomplete);
4586                        EventRuler.on(el, "incomplete", opts.onincomplete);
4587                        EventRuler.on(el, "cleared", opts.oncleared);
4588                        if (!mobile && opts.inputEventOnly !== true) {
4589                            EventRuler.on(el, "keydown", EventHandlers.keydownEvent);
4590                            EventRuler.on(el, "keypress", EventHandlers.keypressEvent);
4591                        } else {
4592                            el.removeAttribute("maxLength");
4593                        }
4594                        EventRuler.on(el, "input", EventHandlers.inputFallBackEvent);
4595                        EventRuler.on(el, "beforeinput", EventHandlers.beforeInputEvent);
4596                    }
4597                    EventRuler.on(el, "setvalue", EventHandlers.setValueEvent);
4598                    undoValue = getBufferTemplate().join("");
4599                    if (el.inputmask._valueGet(true) !== "" || opts.clearMaskOnLostFocus === false || document.activeElement === el) {
4600                        var initialValue = $.isFunction(opts.onBeforeMask) ? opts.onBeforeMask.call(inputmask, el.inputmask._valueGet(true), opts) || el.inputmask._valueGet(true) : el.inputmask._valueGet(true);
4601                        if (initialValue !== "") checkVal(el, true, false, initialValue.split(""));
4602                        var buffer = getBuffer().slice();
4603                        undoValue = buffer.join("");
4604                        if (isComplete(buffer) === false) {
4605                            if (opts.clearIncomplete) {
4606                                resetMaskSet();
4607                            }
4608                        }
4609                        if (opts.clearMaskOnLostFocus && document.activeElement !== el) {
4610                            if (getLastValidPosition() === -1) {
4611                                buffer = [];
4612                            } else {
4613                                clearOptionalTail(buffer);
4614                            }
4615                        }
4616                        if (opts.clearMaskOnLostFocus === false || opts.showMaskOnFocus && document.activeElement === el || el.inputmask._valueGet(true) !== "") writeBuffer(el, buffer);
4617                        if (document.activeElement === el) {
4618                            caret(el, seekNext(getLastValidPosition()));
4619                        }
4620                    }
4621                }
4622            }
4623            var valueBuffer;
4624            if (actionObj !== undefined) {
4625                switch (actionObj.action) {
4626                  case "isComplete":
4627                    el = actionObj.el;
4628                    return isComplete(getBuffer());
4629
4630                  case "unmaskedvalue":
4631                    if (el === undefined || actionObj.value !== undefined) {
4632                        valueBuffer = actionObj.value;
4633                        valueBuffer = ($.isFunction(opts.onBeforeMask) ? opts.onBeforeMask.call(inputmask, valueBuffer, opts) || valueBuffer : valueBuffer).split("");
4634                        checkVal.call(this, undefined, false, false, valueBuffer);
4635                        if ($.isFunction(opts.onBeforeWrite)) opts.onBeforeWrite.call(inputmask, undefined, getBuffer(), 0, opts);
4636                    }
4637                    return unmaskedvalue(el);
4638
4639                  case "mask":
4640                    mask(el);
4641                    break;
4642
4643                  case "format":
4644                    valueBuffer = ($.isFunction(opts.onBeforeMask) ? opts.onBeforeMask.call(inputmask, actionObj.value, opts) || actionObj.value : actionObj.value).split("");
4645                    checkVal.call(this, undefined, true, false, valueBuffer);
4646                    if (actionObj.metadata) {
4647                        return {
4648                            value: isRTL ? getBuffer().slice().reverse().join("") : getBuffer().join(""),
4649                            metadata: maskScope.call(this, {
4650                                action: "getmetadata"
4651                            }, maskset, opts)
4652                        };
4653                    }
4654                    return isRTL ? getBuffer().slice().reverse().join("") : getBuffer().join("");
4655
4656                  case "isValid":
4657                    if (actionObj.value) {
4658                        valueBuffer = actionObj.value.split("");
4659                        checkVal.call(this, undefined, true, true, valueBuffer);
4660                    } else {
4661                        actionObj.value = getBuffer().join("");
4662                    }
4663                    var buffer = getBuffer();
4664                    var rl = determineLastRequiredPosition(), lmib = buffer.length - 1;
4665                    for (;lmib > rl; lmib--) {
4666                        if (isMask(lmib)) break;
4667                    }
4668                    buffer.splice(rl, lmib + 1 - rl);
4669                    return isComplete(buffer) && actionObj.value === getBuffer().join("");
4670
4671                  case "getemptymask":
4672                    return getBufferTemplate().join("");
4673
4674                  case "remove":
4675                    if (el && el.inputmask) {
4676                        $.data(el, "_inputmask_opts", null);
4677                        $el = $(el);
4678                        el.inputmask._valueSet(opts.autoUnmask ? unmaskedvalue(el) : el.inputmask._valueGet(true));
4679                        EventRuler.off(el);
4680                        if (el.inputmask.colorMask) {
4681                            colorMask = el.inputmask.colorMask;
4682                            colorMask.removeChild(el);
4683                            colorMask.parentNode.insertBefore(el, colorMask);
4684                            colorMask.parentNode.removeChild(colorMask);
4685                        }
4686                        var valueProperty;
4687                        if (Object.getOwnPropertyDescriptor && Ob
4687ject.getPrototypeOf) {
4688                            valueProperty = Object.getOwnPropertyDescriptor(Object.getPrototypeOf(el), "value");
4689                            if (valueProperty) {
4690                                if (el.inputmask.__valueGet) {
4691                                    Object.defineProperty(el, "value", {
4692                                        get: el.inputmask.__valueGet,
4693                                        set: el.inputmask.__valueSet,
4694                                        configurable: true
4695                                    });
4696                                }
4697                            }
4698                        } else if (document.__lookupGetter__ && el.__lookupGetter__("value")) {
4699                            if (el.inputmask.__valueGet) {
4700                                el.__defineGetter__("value", el.inputmask.__valueGet);
4701                                el.__defineSetter__("value", el.inputmask.__valueSet);
4702                            }
4703                        }
4704                        el.inputmask = undefined;
4705                    }
4706                    return el;
4707                    break;
4708
4709                  case "getmetadata":
4710                    if ($.isArray(maskset.metadata)) {
4711                        var maskTarget = getMaskTemplate(true, 0, false).join("");
4712                        $.each(maskset.metadata, function(ndx, mtdt) {
4713                            if (mtdt.mask === maskTarget) {
4714                                maskTarget = mtdt;
4715                                return false;
4716                            }
4717                        });
4718                        return maskTarget;
4719                    }
4720                    return maskset.metadata;
4721                }
4722            }
4723        }
4724        return Inputmask;
4725    });
4726}, function(module, exports, __webpack_require__) {
4727    "use strict";
4728    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
4729    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
4730        return typeof obj;
4731    } : function(obj) {
4732        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
4733    };
4734    (function(factory) {
4735        if (true) {
4736            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(4) ], __WEBPACK_AMD_DEFINE_FACTORY__ = factory, 
4737            __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
4738            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
4739        } else {}
4740    })(function($) {
4741        return $;
4742    });
4743}, function(module, exports) {
4744    module.exports = jQuery;
4745}, function(module, exports, __webpack_require__) {
4746    "use strict";
4747    var __WEBPACK_AMD_DEFINE_RESULT__;
4748    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
4749        return typeof obj;
4750    } : function(obj) {
4751        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
4752    };
4753    if (true) !(__WEBPACK_AMD_DEFINE_RESULT__ = function() {
4754        return typeof window !== "undefined" ? window : new (eval("require('jsdom').JSDOM"))("").window;
4755    }.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); else {}
4756}, function(module, exports, __webpack_require__) {
4757    "use strict";
4758    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
4759    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
4760        return typeof obj;
4761    } : function(obj) {
4762        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
4763    };
4764    (function(factory) {
4765        if (true) {
4766            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(2) ], __WEBPACK_AMD_DEFINE_FACTORY__ = factory, 
4767            __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
4768            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
4769        } else {}
4770    })(function(Inputmask) {
4771        var $ = Inputmask.dependencyLib;
4772        var formatCode = {
4773            d: [ "[1-9]|[12][0-9]|3[01]", Date.prototype.setDate, "day", Date.prototype.getDate ],
4774            dd: [ "0[1-9]|[12][0-9]|3[01]", Date.prototype.setDate, "day", function() {
4775                return pad(Date.prototype.getDate.call(this), 2);
4776            } ],
4777            ddd: [ "" ],
4778            dddd: [ "" ],
4779            m: [ "[1-9]|1[012]", Date.prototype.setMonth, "month", function() {
4780                return Date.prototype.getMonth.call(this) + 1;
4781            } ],
4782            mm: [ "0[1-9]|1[012]", Date.prototype.setMonth, "month", function() {
4783                return pad(Date.prototype.getMonth.call(this) + 1, 2);
4784            } ],
4785            mmm: [ "" ],
4786            mmmm: [ "" ],
4787            yy: [ "[0-9]{2}", Date.prototype.setFullYear, "year", function() {
4788                return pad(Date.prototype.getFullYear.call(this), 2);
4789            } ],
4790            yyyy: [ "[0-9]{4}", Date.prototype.setFullYear, "year", function() {
4791                return pad(Date.prototype.getFullYear.call(this), 4);
4792            } ],
4793            h: [ "[1-9]|1[0-2]", Date.prototype.setHours, "hours", Date.prototype.getHours ],
4794            hh: [ "0[1-9]|1[0-2]", Date.prototype.setHours, "hours", function() {
4795                return pad(Date.prototype.getHours.call(this), 2);
4796            } ],
4797            hhh: [ "[0-9]+", Date.prototype.setHours, "hours", Date.prototype.getHours ],
4798            H: [ "1?[0-9]|2[0-3]", Date.prototype.setHours, "hours", Date.prototype.getHours ],
4799            HH: [ "0[0-9]|1[0-9]|2[0-3]", Date.prototype.setHours, "hours", function() {
4800                return pad(Date.prototype.getHours.call(this), 2);
4801            } ],
4802            HHH: [ "[0-9]+", Date.prototype.setHours, "hours", Date.prototype.getHours ],
4803            M: [ "[1-5]?[0-9]", Date.prototype.setMinutes, "minutes", Date.prototype.getMinutes ],
4804            MM: [ "0[0-9]|1[0-9]|2[0-9]|3[0-9]|4[0-9]|5[0-9]", Date.prototype.setMinutes, "minutes", function() {
4805                return pad(Date.prototype.getMinutes.call(this), 2);
4806            } ],
4807            ss: [ "[0-5][0-9]", Date.prototype.setSeconds, "seconds", function() {
4808                return pad(Date.prototype.getSeconds.call(this), 2);
4809            } ],
4810            l: [ "[0-9]{3}", Date.prototype.setMilliseconds, "milliseconds", function() {
4811                return pad(Date.prototype.getMilliseconds.call(this), 3);
4812            } ],
4813            L: [ "[0-9]{2}", Date.prototype.setMilliseconds, "milliseconds", function() {
4814                return pad(Date.prototype.getMilliseconds.call(this), 2);
4815            } ],
4816            t: [ "[ap]" ],
4817            tt: [ "[ap]m" ],
4818            T: [ "[AP]" ],
4819            TT: [ "[AP]M" ],
4820            Z: [ "" ],
4821            o: [ "" ],
4822            S: [ "" ]
4823        }, formatAlias = {
4824            isoDate: "yyyy-mm-dd",
4825            isoTime: "HH:MM:ss",
4826            isoDateTime: "yyyy-mm-dd'T'HH:MM:ss",
4827            isoUtcDateTime: "UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"
4828        };
4829        function getTokenizer(opts) {
4830            if (!opts.tokenizer) {
4831                var tokens = [];
4832                for (var ndx in formatCode) {
4833                    if (tokens.indexOf(ndx[0]) === -1) tokens.push(ndx[0]);
4834                }
4835                opts.tokenizer = "(" + tokens.join("+|") + ")+?|.";
4836                opts.tokenizer = new RegExp(opts.tokenizer, "g");
4837            }
4838            return opts.tokenizer;
4839        }
4840        function isValidDate(dateParts, currentResult) {
4841            return !isFinite(dateParts.rawday) || dateParts.day == "29" && !isFinite(dateParts.rawyear) || new Date(dateParts.date.getFullYear(), isFinite(dateParts.rawmonth) ? dateParts.month : dateParts.date.getMonth() + 1, 0).getDate() >= dateParts.day ? currentResult : false;
4842        }
4843        function isDateInRange(dateParts, opts) {
4844            var result = true;
4845            if (opts.min) {
4846                if (dateParts["rawyear"]) {
4847                    var rawYear = dateParts["rawyear"].replace(/[^0-9]/g, ""), minYear = opts.min.year.substr(0, rawYear.length);
4848                    result = minYear <= rawYear;
4849                }
4850                if (dateParts["year"] === dateParts["rawyear"]) {
4851                    if (opts.min.date.getTime() === opts.min.date.getTime()) {
4852                        result = opts.min.date.getTime() <= dateParts.date.getTime();
4853                    }
4854                }
4855            }
4856            if (result && opts.max && opts.max.date.getTime() === opts.max.date.getTime()) {
4857                result = opts.max.date.getTime() >= dateParts.date.getTime();
4858            }
4859            return result;
4860        }
4861        function parse(format, dateObjValue, opts, raw) {
4862            var mask = "", match;
4863            while (match = getTokenizer(opts).exec(format)) {
4864                if (dateObjValue === undefined) {
4865                    if (formatCode[match[0]]) {
4866                        mask += "(" + formatCode[match[0]][0] + ")";
4867                    } else {
4868                        switch (match[0]) {
4869                          case "[":
4870                            mask += "(";
4871                            break;
4872
4873                          case "]":
4874                            mask += ")?";
4875                            break;
4876
4877                          default:
4878                            mask += Inputmask.escapeRegex(match[0]);
4879                        }
4880                    }
4881                } else {
4882                    if (formatCode[match[0]]) {
4883                        if (raw !== true && formatCode[match[0]][3]) {
4884                            var getFn = formatCode[match[0]][3];
4885                            mask += getFn.call(dateObjValue.date);
4886                        } else if (formatCode[match[0]][2]) mask += dateObjValue["raw" + formatCode[match[0]][2]]; else mask += match[0];
4887                    } else mask += match[0];
4888                }
4889            }
4890            return mask;
4891        }
4892        function pad(val, len) {
4893            val = String(val);
4894            len = len || 2;
4895            while (val.length < len) {
4896                val = "0" + val;
4897            }
4898            return val;
4899        }
4900        function analyseMask(maskString, format, opts) {
4901            var dateObj = {
4902                date: new Date(1, 0, 1)
4903            }, targetProp, mask = maskString, match, dateOperation, targetValidator;
4904            function extendProperty(value) {
4905                var correctedValue = value.replace(/[^0-9]/g, "0");
4906                if (correctedValue != value) {
4907                    var enteredPart = value.replace(/[^0-9]/g, ""), min = (opts.min && opts.min[targetProp] || value).toString(), max = (opts.max && opts.max[targetProp] || value).toString();
4908                    correctedValue = enteredPart + (enteredPart < min.slice(0, enteredPart.length) ? min.slice(enteredPart.length) : enteredPart > max.slice(0, enteredPart.length) ? max.slice(enteredPart.length) : correctedValue.toString().slice(enteredPart.length));
4909                }
4910                return correctedValue;
4911            }
4912            function setValue(dateObj, value, opts) {
4913                dateObj[targetProp] = extendProperty(value);
4914                dateObj["raw" + targetProp] = value;
4915                if (dateOperation !== undefined) dateOperation.call(dateObj.date, targetProp == "month" ? parseInt(dateObj[targetProp]) - 1 : dateObj[targetProp]);
4916            }
4917            if (typeof mask === "string") {
4918                while (match = getTokenizer(opts).exec(format)) {
4919                    var value = mask.slice(0, match[0].length);
4920                    if (formatCode.hasOwnProperty(match[0])) {
4921                        targetValidator = formatCode[match[0]][0];
4922                        targetProp = formatCode[match[0]][2];
4923                        dateOperation = formatCode[match[0]][1];
4924                        setValue(dateObj, value, opts);
4925                    }
4926                    mask = mask.slice(value.length);
4927                }
4928                return dateObj;
4929            } else if (mask && (typeof mask === "undefined" ? "undefined" : _typeof(mask)) === "object" && mask.hasOwnProperty("date")) {
4930                return mask;
4931            }
4932            return undefined;
4933        }
4934        Inputmask.extendAliases({
4935            datetime: {
4936                mask: function mask(opts) {
4937                    formatCode.S = opts.i18n.ordinalSuffix.join("|");
4938                    opts.inputFormat = formatAlias[opts.inputFormat] || opts.inputFormat;
4939                    opts.displayFormat = formatAlias[opts.displayFormat] || opts.displayFormat || opts.inputFormat;
4940                    opts.outputFormat = formatAlias[opts.outputFormat] || opts.outputFormat || opts.inputFormat;
4941                    opts.placeholder = opts.placeholder !== "" ? opts.placeholder : opts.inputFormat.replace(/[\[\]]/, "");
4942                    opts.regex = parse(opts.inputFormat, undefined, opts);
4943                    return null;
4944                },
4945                placeholder: "",
4946                inputFormat: "isoDateTime",
4947                displayFormat: undefined,
4948                outputFormat: undefined,
4949                min: null,
4950                max: null,
4951                i18n: {
4952                    dayNames: [ "Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday" ],
4953                    monthNames: [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "
4953November", "December" ],
4954                    ordinalSuffix: [ "st", "nd", "rd", "th" ]
4955                },
4956                postValidation: function postValidation(buffer, pos, currentResult, opts) {
4957                    opts.min = analyseMask(opts.min, opts.inputFormat, opts);
4958                    opts.max = analyseMask(opts.max, opts.inputFormat, opts);
4959                    var result = currentResult, dateParts = analyseMask(buffer.join(""), opts.inputFormat, opts);
4960                    if (result && dateParts.date.getTime() === dateParts.date.getTime()) {
4961                        result = isValidDate(dateParts, result);
4962                        result = result && isDateInRange(dateParts, opts);
4963                    }
4964                    if (pos && result && currentResult.pos !== pos) {
4965                        return {
4966                            buffer: parse(opts.inputFormat, dateParts, opts),
4967                            refreshFromBuffer: {
4968                                start: pos,
4969                                end: currentResult.pos
4970                            }
4971                        };
4972                    }
4973                    return result;
4974                },
4975                onKeyDown: function onKeyDown(e, buffer, caretPos, opts) {
4976                    var input = this;
4977                    if (e.ctrlKey && e.keyCode === Inputmask.keyCode.RIGHT) {
4978                        var today = new Date(), match, date = "";
4979                        while (match = getTokenizer(opts).exec(opts.inputFormat)) {
4980                            if (match[0].charAt(0) === "d") {
4981                                date += pad(today.getDate(), match[0].length);
4982                            } else if (match[0].charAt(0) === "m") {
4983                                date += pad(today.getMonth() + 1, match[0].length);
4984                            } else if (match[0] === "yyyy") {
4985                                date += today.getFullYear().toString();
4986                            } else if (match[0].charAt(0) === "y") {
4987                                date += pad(today.getYear(), match[0].length);
4988                            }
4989                        }
4990                        input.inputmask._valueSet(date);
4991                        $(input).trigger("setvalue");
4992                    }
4993                },
4994                onUnMask: function onUnMask(maskedValue, unmaskedValue, opts) {
4995                    return parse(opts.outputFormat, analyseMask(maskedValue, opts.inputFormat, opts), opts, true);
4996                },
4997                casing: function casing(elem, test, pos, validPositions) {
4998                    if (test.nativeDef.indexOf("[ap]") == 0) return elem.toLowerCase();
4999                    if (test.nativeDef.indexOf("[AP]") == 0) return elem.toUpperCase();
5000                    return elem;
5001                },
5002                insertMode: false,
5003                shiftPositions: false
5004            }
5005        });
5006        return Inputmask;
5007    });
5008}, function(module, exports, __webpack_require__) {
5009    "use strict";
5010    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
5011    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
5012        return typeof obj;
5013    } : function(obj) {
5014        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
5015    };
5016    (function(factory) {
5017        if (true) {
5018            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(2) ], __WEBPACK_AMD_DEFINE_FACTORY__ = factory, 
5019            __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
5020            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
5021        } else {}
5022    })(function(Inputmask) {
5023        var $ = Inputmask.dependencyLib;
5024        function autoEscape(txt, opts) {
5025            var escapedTxt = "";
5026            for (var i = 0; i < txt.length; i++) {
5027                if (Inputmask.prototype.definitions[txt.charAt(i)] || opts.definitions[txt.charAt(i)] || opts.optionalmarker.start === txt.charAt(i) || opts.optionalmarker.end === txt.charAt(i) || opts.quantifiermarker.start === txt.charAt(i) || opts.quantifiermarker.end === txt.charAt(i) || opts.groupmarker.start === txt.charAt(i) || opts.groupmarker.end === txt.charAt(i) || opts.alternatormarker === txt.charAt(i)) {
5028                    escapedTxt += "\\" + txt.charAt(i);
5029                } else escapedTxt += txt.charAt(i);
5030            }
5031            return escapedTxt;
5032        }
5033        function alignDigits(buffer, digits, opts) {
5034            if (digits > 0) {
5035                var radixPosition = $.inArray(opts.radixPoint, buffer);
5036                if (radixPosition === -1) {
5037                    buffer.push(opts.radixPoint);
5038                    radixPosition = buffer.length - 1;
5039                }
5040                for (var i = 1; i <= digits; i++) {
5041                    buffer[radixPosition + i] = buffer[radixPosition + i] || "0";
5042                }
5043            }
5044            return buffer;
5045        }
5046        Inputmask.extendAliases({
5047            numeric: {
5048                mask: function mask(opts) {
5049                    if (opts.repeat !== 0 && isNaN(opts.integerDigits)) {
5050                        opts.integerDigits = opts.repeat;
5051                    }
5052                    opts.repeat = 0;
5053                    if (opts.groupSeparator === opts.radixPoint && opts.digits && opts.digits !== "0") {
5054                        if (opts.radixPoint === ".") {
5055                            opts.groupSeparator = ",";
5056                        } else if (opts.radixPoint === ",") {
5057                            opts.groupSeparator = ".";
5058                        } else opts.groupSeparator = "";
5059                    }
5060                    if (opts.groupSeparator === " ") {
5061                        opts.skipOptionalPartCharacter = undefined;
5062                    }
5063                    opts.autoGroup = opts.autoGroup && opts.groupSeparator !== "";
5064                    if (opts.autoGroup) {
5065                        if (typeof opts.groupSize == "string" && isFinite(opts.groupSize)) opts.groupSize = parseInt(opts.groupSize);
5066                        if (isFinite(opts.integerDigits)) {
5067                            var seps = Math.floor(opts.integerDigits / opts.groupSize);
5068                            var mod = opts.integerDigits % opts.groupSize;
5069                            opts.integerDigits = parseInt(opts.integerDigits) + (mod === 0 ? seps - 1 : seps);
5070                            if (opts.integerDigits < 1) {
5071                                opts.integerDigits = "*";
5072                            }
5073                        }
5074                    }
5075                    if (opts.placeholder.length > 1) {
5076                        opts.placeholder = opts.placeholder.charAt(0);
5077                    }
5078                    if (opts.positionCaretOnClick === "radixFocus" && opts.placeholder === "" && opts.integerOptional === false) {
5079                        opts.positionCaretOnClick = "lvp";
5080                    }
5081                    opts.definitions[";"] = opts.definitions["~"];
5082                    opts.definitions[";"].definitionSymbol = "~";
5083                    if (opts.numericInput === true) {
5084                        opts.positionCaretOnClick = opts.positionCaretOnClick === "radixFocus" ? "lvp" : opts.positionCaretOnClick;
5085                        opts.digitsOptional = false;
5086                        if (isNaN(opts.digits)) opts.digits = 2;
5087                        opts.decimalProtect = false;
5088                    }
5089                    var mask = "[+]";
5090                    mask += autoEscape(opts.prefix, opts);
5091                    if (opts.integerOptional === true) {
5092                        mask += "~{1," + opts.integerDigits + "}";
5093                    } else mask += "~{" + opts.integerDigits + "}";
5094                    if (opts.digits !== undefined) {
5095                        var radixDef = opts.decimalProtect ? ":" : opts.radixPoint;
5096                        var dq = opts.digits.toString().split(",");
5097                        if (isFinite(dq[0]) && dq[1] && isFinite(dq[1])) {
5098                            mask += radixDef + ";{" + opts.digits + "}";
5099                        } else if (isNaN(opts.digits) || parseInt(opts.digits) > 0) {
5100                            if (opts.digitsOptional) {
5101                                mask += "[" + radixDef + ";{1," + opts.digits + "}]";
5102                            } else mask += radixDef + ";{" + opts.digits + "}";
5103                        }
5104                    }
5105                    mask += autoEscape(opts.suffix, opts);
5106                    mask += "[-]";
5107                    opts.greedy = false;
5108                    return mask;
5109                },
5110                placeholder: "",
5111                greedy: false,
5112                digits: "*",
5113                digitsOptional: true,
5114                enforceDigitsOnBlur: false,
5115                radixPoint: ".",
5116                positionCaretOnClick: "radixFocus",
5117                groupSize: 3,
5118                groupSeparator: "",
5119                autoGroup: false,
5120                allowMinus: true,
5121                negationSymbol: {
5122                    front: "-",
5123                    back: ""
5124                },
5125                integerDigits: "+",
5126                integerOptional: true,
5127                prefix: "",
5128                suffix: "",
5129                rightAlign: true,
5130                decimalProtect: true,
5131                min: null,
5132                max: null,
5133                step: 1,
5134                insertMode: true,
5135                autoUnmask: false,
5136                unmaskAsNumber: false,
5137                inputType: "text",
5138                inputmode: "numeric",
5139                preValidation: function preValidation(buffer, pos, c, isSelection, opts, maskset) {
5140                    if (c === "-" || c === opts.negationSymbol.front) {
5141                        if (opts.allowMinus !== true) return false;
5142                        opts.isNegative = opts.isNegative === undefined ? true : !opts.isNegative;
5143                        if (buffer.join("") === "") return true;
5144                        return {
5145                            caret: maskset.validPositions[pos] ? pos : undefined,
5146                            dopost: true
5147                        };
5148                    }
5149                    if (isSelection === false && c === opts.radixPoint && opts.digits !== undefined && (isNaN(opts.digits) || parseInt(opts.digits) > 0)) {
5150                        var radixPos = $.inArray(opts.radixPoint, buffer);
5151                        if (radixPos !== -1 && maskset.validPositions[radixPos] !== undefined) {
5152                            if (opts.numericInput === true) {
5153                                return pos === radixPos;
5154                            }
5155                            return {
5156                                caret: radixPos + 1
5157                            };
5158                        }
5159                    }
5160                    return true;
5161                },
5162                postValidation: function postValidation(buffer, pos, currentResult, opts) {
5163                    function buildPostMask(buffer, opts) {
5164                        var postMask = "";
5165                        postMask += "(" + opts.groupSeparator + "*{" + opts.groupSize + "}){*}";
5166                        if (opts.radixPoint !== "") {
5167                            var radixSplit = buffer.join("").split(opts.radixPoint);
5168                            if (radixSplit[1]) {
5169                                postMask += opts.radixPoint + "*{" + radixSplit[1].match(/^\d*\??\d*/)[0].length + "}";
5170                            }
5171                        }
5172                        return postMask;
5173                    }
5174                    var suffix = opts.suffix.split(""), prefix = opts.prefix.split("");
5175                    if (currentResult.pos === undefined && currentResult.caret !== undefined && currentResult.dopost !== true) return currentResult;
5176                    var caretPos = currentResult.caret !== undefined ? currentResult.caret : currentResult.pos;
5177                    var maskedValue = buffer.slice();
5178                    if (opts.numericInput) {
5179                        caretPos = maskedValue.length - caretPos - 1;
5180                        maskedValue = maskedValue.reverse();
5181                    }
5182                    var charAtPos = maskedValue[caretPos];
5183                    if (charAtPos === opts.groupSeparator) {
5184                        caretPos += 1;
5185                        charAtPos = maskedValue[caretPos];
5186                    }
5187                    if (caretPos === maskedValue.length - opts.suffix.length - 1 && charAtPos === opts.radixPoint) return currentResult;
5188                    if (charAtPos !== undefined) {
5189                        if (charAtPos !== opts.radixPoint && charAtPos !== opts.negationSymbol.front && charAtPos !== opts.negationSymbol.back) {
5190                            maskedValue[caretPos] = "?";
5191                            if (opts.prefix.length > 0 && caretPos >= (opts.isNegative === false ? 1 : 0) && caretPos < opts.prefix.length - 1 + (opts.isNegative === false ? 1 : 0)) {
5192                                prefix[caretPos - (opts.isNegative === false ? 1 : 0)] = "?";
5193                            } else if (opts.suffix.length > 0 && caretPos >= maskedValue.length - opts.suffix.length - (opts.isNegative === false ? 1 : 0)) {
5194                                suffix[caretPos - (maskedValue.length - opts.suffix.length - (opts.isNegative === false ? 1 : 0))] = "?";
5195                            }
5196                        }
5197                    }
5198                    prefix = prefix.join("");
5199                    suffix = suffix.join("");
5200                    var processValue = maskedValue.join("").replace(prefix, "");
5201                    processValue = processValue.replace(suffix, "");
5202                    processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator), "g"), "");
5203                    processValue = processValue.replace(new RegExp("[-" + Inputmask.escapeRegex(opts.negationSymbol.front) + "]", "g"), "");
5204                    processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.negationSymbol.back) + "$"), "");
5205                    if (isNaN(opts.placeholder)) {
5206                        processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.placeholder), "g"), "");
5207                    }
5208                    if (processValue.length > 1 && processValue.indexOf(opts.radixPoint) !== 1) {
5209                        if (charAtPos === "0") {
5210                            processValue = processValue.replace(/^\?/g, "");
5211                        }
5212                        processValue = processValue.replace(/^0/g, "");
5213                    }
5214                    if (processValue.charAt(0) === opts.radixPoint && opts.radixPoint !== "" && opts.numericInput !== true) {
5215                        processValue = "0" + processValue;
5216                    }
5217                    if (processValue !== "") {
5218                        processValue = processValue.split("");
5219                        if ((!opts.digitsOptional || opts.enforceDigitsOnBlur && currentResult.event === "blur") && isFinite(opts.digits)) {
5220                            var radixPosition = $.inArray(opts.radixPoint, processValue);
5221                            var rpb = $.inArray(opts.radixPoint, maskedValue);
5222                            if (radixPosition === -1) {
5223                                processValue.push(opts.radixPoint);
5224                                radixPosition = processValue.length - 1;
5225                            }
5226                            for (var i = 1; i <= opts.digits; i++) {
5227                                if ((!opts.digitsOptional || opts.enforceDigitsOnBlur && currentResult.event === "blur") && (processValue[radixPosition + i] === undefined || processValue[radixPosition + i] === opts.placeholder.charAt(0))) {
5228                                    processValue[radixPosition + i] = currentResult.placeholder || opts.placeholder.charAt(0);
5229                                } else if (rpb !== -1 && maskedValue[rpb + i] !== undefined) {
5230                                    processValue[radixPosition + i] = processValue[radixPosition + i] || maskedValue[rpb + i];
5231                                }
5232                            }
5233                        }
5234                        if (opts.autoGroup === true && opts.groupSeparator !== "" && (charAtPos !== opts.radixPoint || currentResult.pos !== undefined || currentResult.dopost)) {
5235                            var addRadix = processValue[processValue.length - 1] === opts.radixPoint && currentResult.c === opts.radixPoint;
5236                            processValue = Inputmask(buildPostMask(processValue, opts), {
5237                                numericInput: true,
5238                                jitMasking: true,
5239                                definitions: {
5240                                    "*": {
5241                                        validator: "[0-9?]",
5242                                        cardinality: 1
5243                                    }
5244                                }
5245                            }).format(processValue.join(""));
5246                            if (addRadix) processValue += opts.radixPoint;
5247                            if (processValue.charAt(0) === opts.groupSeparator) {
5248                                processValue.substr(1);
5249                            }
5250                        } else processValue = processValue.join("");
5251                    }
5252                    if (opts.isNegative && currentResult.event === "blur") {
5253                        opts.isNegative = processValue !== "0";
5254                    }
5255                    processValue = prefix + processValue;
5256                    processValue += suffix;
5257                    if (opts.isNegative) {
5258                        processValue = opts.negationSymbol.front + processValue;
5259                        processValue += opts.negationSymbol.back;
5260                    }
5261                    processValue = processValue.split("");
5262                    if (charAtPos !== undefined) {
5263                        if (charAtPos !== opts.radixPoint && charAtPos !== opts.negationSymbol.front && charAtPos !== opts.negationSymbol.back) {
5264                            caretPos = $.inArray("?", processValue);
5265                            if (caretPos > -1) {
5266                                processValue[caretPos] = charAtPos;
5267                            } else caretPos = currentResult.caret || 0;
5268                        } else if (charAtPos === opts.radixPoint || charAtPos === opts.negationSymbol.front || charAtPos === opts.negationSymbol.back) {
5269                            var newCaretPos = $.inArray(charAtPos, processValue);
5270                            if (newCaretPos !== -1) caretPos = newCaretPos;
5271                        }
5272                    }
5273                    if (opts.numericInput) {
5274                        caretPos = processValue.length - caretPos - 1;
5275                        processValue = processValue.reverse();
5276                    }
5277                    var rslt = {
5278                        caret: (charAtPos === undefined || currentResult.pos !== undefined) && caretPos !== undefined ? caretPos + (opts.numericInput ? -1 : 1) : caretPos,
5279                        buffer: processValue,
5280                        refreshFromBuffer: currentResult.dopost || buffer.join("") !== processValue.join("")
5281                    };
5282                    return rslt.refreshFromBuffer ? rslt : currentResult;
5283                },
5284                onBeforeWrite: function onBeforeWrite(e, buffer, caretPos, opts) {
5285                    function parseMinMaxOptions(opts) {
5286                        if (opts.parseMinMaxOptions === undefined) {
5287                            if (opts.min !== null) {
5288                                opts.min = opts.min.toString().replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator), "g"), "");
5289                                if (opts.radixPoint === ",") opts.min = opts.min.replace(opts.radixPoint, ".");
5290                                opts.min = isFinite(opts.min) ? parseFloat(opts.min) : NaN;
5291                                if (isNaN(opts.min)) opts.min = Number.MIN_VALUE;
5292                            }
5293                            if (opts.max !== null) {
5294                                opts.max = opts.max.toString().replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator), "g"), "");
5295                                if (opts.radixPoint === ",") opts.max = opts.max.replace(opts.radixPoint, ".");
5296                                opts.max = isFinite(opts.max) ? parseFloat(opts.max) : NaN;
5297                                if (isNaN(opts.max)) opts.max = Number.MAX_VALUE;
5298                            }
5299                            opts.parseMinMaxOptions = "done";
5300                        }
5301                    }
5302                    if (e) {
5303                        switch (e.type) {
5304                          case "keydown":
5305                            return opts.postValidation(buffer, caretPos, {
5306                                caret: caretPos,
5307                                dopost: true
5308                            }, opts);
5309
5310                          case "blur":
5311                          case "checkval":
5312                            var unmasked;
5313                            parseMinMaxOptions(opts);
5314                            if (opts.min !== null || opts.max !== null) {
5315                                unmasked = opts.onUnMask(buffer.join(""), undefined, $.extend({}, opts, {
5316                                    unmaskAsNumber: true
5317                                }));
5318                                if (opts.min !== null && unmasked < opts.min) {
5319                                    opts.isNegative = opts.min < 0;
5320                                    return opts.postValidation(opts.min.toString().replace(".", opts.radixPoint).split(""), caretPos, {
5321                                        caret: caretPos,
5322                                        dopost: true,
5323                                        placeholder: "0"
5324                                    }, opts);
5325                                } else if (opts.max !== null && unmasked > opts.max) {
5326                                    opts.isNegative = opts.max < 0;
5327                                    return opts.postValidation(opts.max.toString().replace(".", opts.radixPoint).split(""), caretPos, {
5328                                        caret: caretPos,
5329                                        dopost: true,
5330                                        placeholder: "0"
5331                                    }, opts);
5332                                }
5333                            }
5334                            return opts.postValidation(buffer, caretPos, {
5335                                caret: caretPos,
5336                                placeholder: "0",
5337                                event: "blur"
5338                            }, opts);
5339
5340                          case "_checkval":
5341                            return {
5342                                caret: caretPos
5343                            };
5344
5345                          default:
5346                            break;
5347                        }
5348                    }
5349                },
5350                regex: {
5351                    integerPart: function integerPart(opts, emptyCheck) {
5352                        return emptyCheck ? new RegExp("[" + Inputmask.escapeRegex(opts.negationSymbol.front) + "+]?") : new RegExp("[" + Inputmask.escapeRegex(opts.negationSymbol.front) + "+]?\\d+");
5353                    },
5354                    integerNPart: function integerNPart(opts) {
5355                        return new RegExp("[\\d" + Inputmask.escapeRegex(opts.
5355groupSeparator) + Inputmask.escapeRegex(opts.placeholder.charAt(0)) + "]+");
5356                    }
5357                },
5358                definitions: {
5359                    "~": {
5360                        validator: function validator(chrs, maskset, pos, strict, opts, isSelection) {
5361                            var isValid, l;
5362                            if (chrs === "k" || chrs === "m") {
5363                                isValid = {
5364                                    insert: [],
5365                                    c: 0
5366                                };
5367                                for (var i = 0, l = chrs === "k" ? 2 : 5; i < l; i++) {
5368                                    isValid.insert.push({
5369                                        pos: pos + i,
5370                                        c: 0
5371                                    });
5372                                }
5373                                isValid.pos = pos + l;
5374                                return isValid;
5375                            }
5376                            isValid = strict ? new RegExp("[0-9" + Inputmask.escapeRegex(opts.groupSeparator) + "]").test(chrs) : new RegExp("[0-9]").test(chrs);
5377                            if (isValid === true) {
5378                                if (opts.numericInput !== true && maskset.validPositions[pos] !== undefined && maskset.validPositions[pos].match.def === "~" && !isSelection) {
5379                                    var processValue = maskset.buffer.join("");
5380                                    processValue = processValue.replace(new RegExp("[-" + Inputmask.escapeRegex(opts.negationSymbol.front) + "]", "g"), "");
5381                                    processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.negationSymbol.back) + "$"), "");
5382                                    var pvRadixSplit = processValue.split(opts.radixPoint);
5383                                    if (pvRadixSplit.length > 1) {
5384                                        pvRadixSplit[1] = pvRadixSplit[1].replace(/0/g, opts.placeholder.charAt(0));
5385                                    }
5386                                    if (pvRadixSplit[0] === "0") {
5387                                        pvRadixSplit[0] = pvRadixSplit[0].replace(/0/g, opts.placeholder.charAt(0));
5388                                    }
5389                                    processValue = pvRadixSplit[0] + opts.radixPoint + pvRadixSplit[1] || "";
5390                                    var bufferTemplate = maskset._buffer.join("");
5391                                    if (processValue === opts.radixPoint) {
5392                                        processValue = bufferTemplate;
5393                                    }
5394                                    while (processValue.match(Inputmask.escapeRegex(bufferTemplate) + "$") === null) {
5395                                        bufferTemplate = bufferTemplate.slice(1);
5396                                    }
5397                                    processValue = processValue.replace(bufferTemplate, "");
5398                                    processValue = processValue.split("");
5399                                    if (processValue[pos] === undefined) {
5400                                        isValid = {
5401                                            pos: pos,
5402                                            remove: pos
5403                                        };
5404                                    } else {
5405                                        isValid = {
5406                                            pos: pos
5407                                        };
5408                                    }
5409                                }
5410                            } else if (!strict && chrs === opts.radixPoint && maskset.validPositions[pos - 1] === undefined) {
5411                                isValid = {
5412                                    insert: {
5413                                        pos: pos,
5414                                        c: 0
5415                                    },
5416                                    pos: pos + 1
5417                                };
5418                            }
5419                            return isValid;
5420                        },
5421                        cardinality: 1
5422                    },
5423                    "+": {
5424                        validator: function validator(chrs, maskset, pos, strict, opts) {
5425                            return opts.allowMinus && (chrs === "-" || chrs === opts.negationSymbol.front);
5426                        },
5427                        cardinality: 1,
5428                        placeholder: ""
5429                    },
5430                    "-": {
5431                        validator: function validator(chrs, maskset, pos, strict, opts) {
5432                            return opts.allowMinus && chrs === opts.negationSymbol.back;
5433                        },
5434                        cardinality: 1,
5435                        placeholder: ""
5436                    },
5437                    ":": {
5438                        validator: function validator(chrs, maskset, pos, strict, opts) {
5439                            var radix = "[" + Inputmask.escapeRegex(opts.radixPoint) + "]";
5440                            var isValid = new RegExp(radix).test(chrs);
5441                            if (isValid && maskset.validPositions[pos] && maskset.validPositions[pos].match.placeholder === opts.radixPoint) {
5442                                isValid = {
5443                                    caret: pos + 1
5444                                };
5445                            }
5446                            return isValid;
5447                        },
5448                        cardinality: 1,
5449                        placeholder: function placeholder(opts) {
5450                            return opts.radixPoint;
5451                        }
5452                    }
5453                },
5454                onUnMask: function onUnMask(maskedValue, unmaskedValue, opts) {
5455                    if (unmaskedValue === "" && opts.nullable === true) {
5456                        return unmaskedValue;
5457                    }
5458                    var processValue = maskedValue.replace(opts.prefix, "");
5459                    processValue = processValue.replace(opts.suffix, "");
5460                    processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator), "g"), "");
5461                    if (opts.placeholder.charAt(0) !== "") {
5462                        processValue = processValue.replace(new RegExp(opts.placeholder.charAt(0), "g"), "0");
5463                    }
5464                    if (opts.unmaskAsNumber) {
5465                        if (opts.radixPoint !== "" && processValue.indexOf(opts.radixPoint) !== -1) processValue = processValue.replace(Inputmask.escapeRegex.call(this, opts.radixPoint), ".");
5466                        processValue = processValue.replace(new RegExp("^" + Inputmask.escapeRegex(opts.negationSymbol.front)), "-");
5467                        processValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.negationSymbol.back) + "$"), "");
5468                        return Number(processValue);
5469                    }
5470                    return processValue;
5471                },
5472                isComplete: function isComplete(buffer, opts) {
5473                    var maskedValue = (opts.numericInput ? buffer.slice().reverse() : buffer).join("");
5474                    maskedValue = maskedValue.replace(new RegExp("^" + Inputmask.escapeRegex(opts.negationSymbol.front)), "-");
5475                    maskedValue = maskedValue.replace(new RegExp(Inputmask.escapeRegex(opts.negationSymbol.back) + "$"), "");
5476                    maskedValue = maskedValue.replace(opts.prefix, "");
5477                    maskedValue = maskedValue.replace(opts.suffix, "");
5478                    maskedValue = maskedValue.replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator) + "([0-9]{3})", "g"), "$1");
5479                    if (opts.radixPoint === ",") maskedValue = maskedValue.replace(Inputmask.escapeRegex(opts.radixPoint), ".");
5480                    return isFinite(maskedValue);
5481                },
5482                onBeforeMask: function onBeforeMask(initialValue, opts) {
5483                    opts.isNegative = undefined;
5484                    var radixPoint = opts.radixPoint || ",";
5485                    if ((typeof initialValue == "number" || opts.inputType === "number") && radixPoint !== "") {
5486                        initialValue = initialValue.toString().replace(".", radixPoint);
5487                    }
5488                    var valueParts = initialValue.split(radixPoint), integerPart = valueParts[0].replace(/[^\-0-9]/g, ""), decimalPart = valueParts.length > 1 ? valueParts[1].replace(/[^0-9]/g, "") : "";
5489                    initialValue = integerPart + (decimalPart !== "" ? radixPoint + decimalPart : decimalPart);
5490                    var digits = 0;
5491                    if (radixPoint !== "") {
5492                        digits = decimalPart.length;
5493                        if (decimalPart !== "") {
5494                            var digitsFactor = Math.pow(10, digits || 1);
5495                            if (isFinite(opts.digits)) {
5496                                digits = parseInt(opts.digits);
5497                                digitsFactor = Math.pow(10, digits);
5498                            }
5499                            initialValue = initialValue.replace(Inputmask.escapeRegex(radixPoint), ".");
5500                            if (isFinite(initialValue)) initialValue = Math.round(parseFloat(initialValue) * digitsFactor) / digitsFactor;
5501                            initialValue = initialValue.toString().replace(".", radixPoint);
5502                        }
5503                    }
5504                    if (opts.digits === 0 && initialValue.indexOf(Inputmask.escapeRegex(radixPoint)) !== -1) {
5505                        initialValue = initialValue.substring(0, initialValue.indexOf(Inputmask.escapeRegex(radixPoint)));
5506                    }
5507                    return alignDigits(initialValue.toString().split(""), digits, opts).join("");
5508                },
5509                onKeyDown: function onKeyDown(e, buffer, caretPos, opts) {
5510                    var $input = $(this);
5511                    if (e.ctrlKey) {
5512                        switch (e.keyCode) {
5513                          case Inputmask.keyCode.UP:
5514                            $input.val(parseFloat(this.inputmask.unmaskedvalue()) + parseInt(opts.step));
5515                            $input.trigger("setvalue");
5516                            break;
5517
5518                          case Inputmask.keyCode.DOWN:
5519                            $input.val(parseFloat(this.inputmask.unmaskedvalue()) - parseInt(opts.step));
5520                            $input.trigger("setvalue");
5521                            break;
5522                        }
5523                    }
5524                }
5525            },
5526            currency: {
5527                prefix: "$ ",
5528                groupSeparator: ",",
5529                alias: "numeric",
5530                placeholder: "0",
5531                autoGroup: true,
5532                digits: 2,
5533                digitsOptional: false,
5534                clearMaskOnLostFocus: false
5535            },
5536            decimal: {
5537                alias: "numeric"
5538            },
5539            integer: {
5540                alias: "numeric",
5541                digits: 0,
5542                radixPoint: ""
5543            },
5544            percentage: {
5545                alias: "numeric",
5546                digits: 2,
5547                digitsOptional: true,
5548                radixPoint: ".",
5549                placeholder: "0",
5550                autoGroup: false,
5551                min: 0,
5552                max: 100,
5553                suffix: " %",
5554                allowMinus: false
5555            }
5556        });
5557        return Inputmask;
5558    });
5559}, function(module, exports, __webpack_require__) {
5560    "use strict";
5561    var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
5562    var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
5563        return typeof obj;
5564    } : function(obj) {
5565        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
5566    };
5567    (function(factory) {
5568        if (true) {
5569            !(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(4), __webpack_require__(2) ], 
5570            __WEBPACK_AMD_DEFINE_FACTORY__ = factory, __WEBPACK_AMD_DEFINE_RESULT__ = typeof __WEBPACK_AMD_DEFINE_FACTORY__ === "function" ? __WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__) : __WEBPACK_AMD_DEFINE_FACTORY__, 
5571            __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
5572        } else {}
5573    })(function($, Inputmask) {
5574        if ($.fn.inputmask === undefined) {
5575            $.fn.inputmask = function(fn, options) {
5576                var nptmask, input = this[0];
5577                if (options === undefined) options = {};
5578                if (typeof fn === "string") {
5579                    switch (fn) {
5580                      case "unmaskedvalue":
5581                        return input && input.inputmask ? input.inputmask.unmaskedvalue() : $(input).val();
5582
5583                      case "remove":
5584                        return this.each(function() {
5585                            if (this.inputmask) this.inputmask.remove();
5586                        });
5587
5588                      case "getemptymask":
5589                        return input && input.inputmask ? input.inputmask.getemptymask() : "";
5590
5591                      case "hasMaskedValue":
5592                        return input && input.inputmask ? input.inputmask.hasMaskedValue() : false;
5593
5594                      case "isComplete":
5595                        return input && input.inputmask ? input.inputmask.isComplete() : true;
5596
5597                      case "getmetadata":
5598                        return input && input.inputmask ? input.inputmask.getmetadata() : undefined;
5599
5600                      case "setvalue":
5601                        Inputmask.setValue(input, options);
5602                        break;
5603
5604                      case "option":
5605                        if (typeof options === "string") {
5606                            if (input && input.inputmask !== undefined) {
5607                                return input.inputmask.option(options);
5608                            }
5609                        } else {
5610                            return this.each(function() {
5611                                if (this.inputmask !== undefined) {
5612                                    return this.inputmask.option(options);
5613                                }
5614                            });
5615                        }
5616                        break;
5617
5618                      default:
5619                        options.alias = fn;
5620                        nptmask = new Inputmask(options);
5621                        return this.each(function() {
5622                            nptmask.mask(this);
5623                        });
5624                    }
5625                } else if (Array.isArray(fn)) {
5626                    options.alias = fn;
5627                    nptmask = new Inputmask(options);
5628                    return this.each(function() {
5629                        nptmask.mask(this);
5630                    });
5631                } else if ((typeof fn === "undefined" ? "undefined" : _typeof(fn)) == "object") {
5632                    nptmask = new Inputmask(fn);
5633                    if (fn.mask === undefined && fn.alias === undefined) {
5634                        return this.each(function() {
5635                            if (this.inputmask !== undefined) {
5636                                return this.inputmask.option(fn);
5637                            } else nptmask.mask(this);
5638                        });
5639                    } else {
5640                        return this.each(function() {
5641                            nptmask.mask(this);
5642                        });
5643                    }
5644                } else if (fn === undefined) {
5645                    return this.each(function() {
5646                        nptmask = new Inputmask(options);
5647                        nptmask.mask(this);
5648                    });
5649                }
5650            };
5651        }
5652        return $.fn.inputmask;
5653    });
5654} ]);
5655/* End */
5656;
5657; /* Start:"a:4:{s:4:"full";s:65:"/local/templates/gvozdevsoft_profigs_s1/js/main.js?17483442504670";s:6:"source";s:50:"/local/templates/gvozdevsoft_profigs_s1/js/main.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
5658$(document).ready(function(){
5659
5660	$(".mygallery").justifiedGallery({
5661		rowHeight : 150,
5662		lastRow : 'nojustify',
5663		captions : false,
5664		border : 0,
5665		margins : 7
5666	});
5667
5668	$(".mygallery2").justifiedGallery({
5669		rowHeight : 200,
5670		lastRow : 'nojustify',
5671		captions : false,
5672		border : 0,
5673		margins : 7
5674	});
5675
5676	$(".mygallery-catalog").justifiedGallery({
5677		rowHeight : 70,
5678		lastRow : 'nojustify',
5679		captions : false,
5680		border : 0,
5681		margins : 7
5682	});
5683
5684	//Slider main page
5685	$(".header-slider").owlCarousel({
5686		items:1,
5687		loop:true,
5688		margin:0,
5689		nav:false,
5690		autoplay:true,
5691		autoplayTimeout:6000,
5692		smartSpeed:750,
5693		autoplayHoverPause:true
5694	});
5695
5696	//Slider section main page
5697	$(".section-slider").owlCarousel({
5698		items:4,
5699		loop:true,
5700		margin:30,
5701		nav:true,
5702		dots: false,
5703		autoplay:false,
5704		smartSpeed:750,
5705		autoplayHoverPause:false,
5706		responsive:{
5707			0:{
5708				items:1
5709			},
5710			768:{
5711				items:2
5712			},
5713			992:{
5714				items:4
5715			} 
5716		}
5717	});
5718
5719	//Slider section main page
5720	$(document).ready(function () {
5721		const $slider = $('.section-slider2');
5722		let originalItems = [];
5723
5724		// Клонируем исходные элементы один раз
5725		$slider.children('div').each(function () {
5726			originalItems.push($(this).clone());
5727		});
5728
5729		// Инициализация карусели при старте
5730		function initCarousel() {
5731			$slider.owlCarousel({
5732				items: 4,
5733				loop: false,
5734				margin: 30,
5735				nav: true,
5736				dots: false,
5737				autoplay: false,
5738				smartSpeed: 750,
5739				autoplayHoverPause: false,
5740				responsive: {
5741					0: { items: 1 },
5742					768: { items: 2 },
5743					992: { items: 4 }
5744				}
5745			});
5746		}
5747
5748		initCarousel(); // первый запуск
5749
5750		$('.bts-keys button').on('click', function () {
5751			let filter = $(this).data('filter');
5752
5753			// Убираем active с предыдущей кнопки и добавляем на текущую
5754			$('.bts-keys button').removeClass('active');
5755			$(this).addClass('active');
5756
5757			// Удаляем карусель и обёртки
5758			$slider.trigger('destroy.owl.carousel');
5759			$slider.removeClass('owl-carousel owl-loaded');
5760			$slider.find('.owl-stage-outer, .owl-stage').children().unwrap();
5761			$slider.empty(); // очищаем
5762
5763			// Фильтруем и добавляем нужные
5764			originalItems.forEach(function ($item) {
5765				let itemRazdel = $item.data('razdel');
5766				if (filter === 'all' || itemRazdel === filter) {
5767					$slider.append($item.clone());
5768				}
5769			});
5770
5771			// Переинициализация
5772			$slider.addClass('owl-carousel'); // обязательно!
5773			initCarousel();
5774		});
5775	});
5776
5777	//Slider section main page partners
5778	$(".section-slider-partners").owlCarousel({
5779		items:6,
5780		loop:true,
5781		margin:30,
5782		nav:false,
5783		dots: false,
5784		autoplay:true,
5785		smartSpeed:750,
5786		autoplayHoverPause:false,
5787		responsive:{
5788			0:{
5789				items:2
5790			},
5791			768:{
5792				items:3
5793			},
5794			992:{
5795				items:5
5796			} 
5797		}
5798	});
5799
5800	$(".section-slider .owl-next, .section-slider2 .owl-next").html("<i class='fa fa-angle-right nextarr' aria-hidden='true'></i>");
5801	$(".section-slider .owl-prev, .section-slider2 .owl-prev").html("<i class='fa fa-angle-left prevarr' aria-hidden='true'></i>");
5802
5803	// Fixed - sidebar
5804	$('#sidebar_fixed').sticky({topSpacing:70});
5805
5806	// Action - sidebar
5807	$(".sidebar-action").owlCarousel({
5808		items:1,
5809		loop:true,
5810		margin:0,
5811		nav:true,
5812		dots: false,
5813		autoplay:true,
5814		smartSpeed:750,
5815		autoplayHoverPause:false,
5816	});
5817
5818	// Review, portfolio - sidebar
5819	$(".sidebar-review, .sidebar-portfolio").owlCarousel({
5820		items:1,
5821		loop:true,
5822		margin:0,
5823		nav:true,
5824		dots: false,
5825		autoplay:false,
5826		smartSpeed:750,
5827		autoplayHoverPause:false,
5828	});
5829
5830	$("#sidebar .owl-next").html("<i class='fa fa-arrow-circle-right nextarr' aria-hidden='true'></i>");
5831	$("#sidebar .owl-prev").html("<i class='fa fa-arrow-circle-left prevarr' aria-hidden='true'></i>");
5832
5833	// Taby - calc
5834	$(".tabs").lightTabs();
5835	
5836	//Maska nomer phone
5837	$(".inputmask").inputmask(typeof window.inputMaskPattern !== 'undefined'?window.inputMaskPattern:"+7 (999) 999-99-99");
5838
5839	// Spaces in a prices
5840	$(".pricespace").each(function(){
5841		var price = $(this).html();
5842		var parts = (price + '').split('.');
5843		var main = parts[0];
5844		var len = main.length;
5845		var pricetxt = '';
5846		var i = len - 1;
5847		while(i >= 0) {
5848			pricetxt = main.charAt(i) + pricetxt;
5849			if ((len - i) % 3 === 0 && i > 0) {
5850				pricetxt = ' ' + pricetxt;
5851			}
5852			--i;
5853		}
5854		if (parts.length > 1) { pricetxt += '.' + parts[1]; }
5855		$(this).html(pricetxt);
5856	});
5857
5858});
5859/* End */
5860;
5861; /* Start:"a:4:{s:4:"full";s:104:"/local/templates/gvozdevsoft_profigs_s1/components/bitrix/menu/mn_flmenu_top/script.min.js?1738274368408";s:6:"source";s:86:"/local/templates/gvozdevsoft_profigs_s1/components/bitrix/menu/mn_flmenu_top/script.js";s:3:"min";s:90:"/local/templates/gvozdevsoft_profigs_s1/components/bitrix/menu/mn_flmenu_top/script.min.js";s:3:"map";s:90:"/local/templates/gvozdevsoft_profigs_s1/components/bitrix/menu/mn_flmenu_top/script.map.js";}"*/
5862var jshover=function(){var e=document.getElementById("horizontal-multilevel-menu");if(!e)return;var t=e.getElementsByTagName("li");for(var n=0;n<t.length;n++){t[n].onmouseover=function(){this.className+=" jshover"};t[n].onmouseout=function(){this.className=this.className.replace(new RegExp(" jshover\\b"),"")}}};if(window.attachEvent)window.attachEvent("onload",jshover);
5863/* End */
5864;; /* /local/templates/gvozdevsoft_profigs_s1/lib/jquery-3.3.1.min.js?173827436886927*/
5865; /* /local/templates/gvozdevsoft_profigs_s1/lib/owl-carousel-2/js/owl.carousel.min.js?173827436844342*/
5866; /* /local/templates/gvozdevsoft_profigs_s1/lib/fancybox/jquery.fancybox.min.js?173827436866400*/
5867; /* /local/templates/gvozdevsoft_profigs_s1/lib/flmenu/flmenu.js?17382743683602*/
5868; /* /local/templates/gvozdevsoft_profigs_s1/lib/sticky/jquery.sticky.js?17382743683836*/
5869; /* /local/templates/gvozdevsoft_profigs_s1/lib/accordion/accordion.js?1738274368311*/
5870; /* /local/templates/gvozdevsoft_profigs_s1/lib/tabs/tabs.js?1738274368751*/
5871; /* /local/templates/gvozdevsoft_profigs_s1/lib/arrup/arrup.js?1738274368423*/
5872; /* /local/templates/gvozdevsoft_profigs_s1/lib/hdfix/hdfix.js?1738274368230*/
5873; /* /local/templates/gvozdevsoft_profigs_s1/lib/img-zoom/img-zoom.js?1738274368220*/
5874; /* /local/templates/gvozdevsoft_profigs_s1/lib/flex-gallery/jquery.justified-gallery.min.js?173827436818510*/
5875; /* /lib/feedback/feedback.js?17901517438936*/
5876; /* /lib/calc/js/calc.js?173827436851268*/
5877; /* /local/templates/gvozdevsoft_profigs_s1/lib/inputmask/jquery.inputmask.js?1738274368220934*/
5878; /* /local/templates/gvozdevsoft_profigs_s1/js/main.js?17483442504670*/
5879; /* /local/templates/gvozdevsoft_profigs_s1/components/bitrix/menu/mn_flmenu_top/script.min.js?1738274368408*/
5880
5881//# sourceMappingURL=template_e092990c14d0bebff7cbde4ec1feb1c0.map.js

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.