PageSourceSearch

https://caiman.ru/bitrix/cache/js/c2/CAIMAN_2025/template_05723b39…7e159d80c149bc984b34_v1.js?1791066411786965

js caiman.ru collected 2026-10-03 23:48:10 UTC 786,965 bytes, 12,550 lines download raw bytes

vendor: 7,537 bytes, lines 1-15
1
2; /* Start:"a:4:{s:4:"full";s:80:"/local/templates/CAIMAN_2025/assets/vendor/parallax/rellax.min.js?17126615677634";s:6:"source";s:65:"/local/templates/CAIMAN_2025/assets/vendor/parallax/rellax.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
3(function(q,g){"function"===typeof define&&define.amd?define([],g):"object"===typeof module&&module.exports?module.exports=g():q.Rellax=g()})("undefined"!==typeof window?window:global,function(){var q=function(g,u){function C(){if(3===a.options.breakpoints.length&&Array.isArray(a.options.breakpoints)){var f=!0,c=!0,b;a.options.breakpoints.forEach(function(a){"number"!==typeof a&&(c=!1);null!==b&&a<b&&(f=!1);b=a});if(f&&c)return}a.options.breakpoints=[576,768,1201];console.warn("Rellax: You must pass an array of 3 numbers in ascending order to the breakpoints option. Defaults reverted")}
4    var a=Object.create(q.prototype),l=0,v=0,m=0,n=0,d=[],w=!0,A=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame||function(a){return setTimeout(a,1E3/60)},p=null,x=!1;try{var k=Object.defineProperty({},"passive",{get:function(){x=!0}});window.addEventListener("testPassive",null,k);window.removeEventListener("testPassive",null,k)}catch(f){}var D=window.cancelAnimationFrame||window.mozCancelAnimationFrame||
5        clearTimeout,E=window.transformProp||function(){var a=document.createElement("div");if(null===a.style.transform){var c=["Webkit","Moz","ms"],b;for(b in c)if(void 0!==a.style[c[b]+"Transform"])return c[b]+"Transform"}return"transform"}();a.options={speed:-2,verticalSpeed:null,horizontalSpeed:null,breakpoints:[576,768,1201],center:!1,wrapper:null,relativeToWrapper:!1,round:!0,vertical:!0,horizontal:!1,verticalScrollAxis:"y",horizontalScrollAxis:"x",callback:function(){}};u&&Object.keys(u).forEach(function(d){a.options[d]=
6        u[d]});u&&u.breakpoints&&C();g||(g=".rellax");k="string"===typeof g?document.querySelectorAll(g):[g];if(0<k.length){a.elems=k;if(a.options.wrapper&&!a.options.wrapper.nodeType)if(k=document.querySelector(a.options.wrapper))a.options.wrapper=k;else{console.warn("Rellax: The wrapper you're trying to use doesn't exist.");return}var F,B=function(){for(var f=0;f<d.length;f++)a.elems[f].style.cssText=d[f].style;d=[];v=window.innerHeight;n=window.innerWidth;f=a.options.breakpoints;F=n<f[0]?"xs":n>=f[0]&&n<
7    f[1]?"sm":n>=f[1]&&n<f[2]?"md":"lg";H();for(f=0;f<a.elems.length;f++){var c=void 0,b=a.elems[f],e=b.getAttribute("data-rellax-percentage"),y=b.getAttribute("data-rellax-speed"),t=b.getAttribute("data-rellax-xs-speed"),g=b.getAttribute("data-rellax-mobile-speed"),h=b.getAttribute("data-rellax-tablet-speed"),k=b.getAttribute("data-rellax-desktop-speed"),l=b.getAttribute("data-rellax-vertical-speed"),m=b.getAttribute("data-rellax-horizontal-speed"),p=b.getAttribute("data-rellax-vertical-scroll-axis"),
8        q=b.getAttribute("data-rellax-horizontal-scroll-axis"),u=b.getAttribute("data-rellax-zindex")||0,x=b.getAttribute("data-rellax-min"),A=b.getAttribute("data-rellax-max"),C=b.getAttribute("data-rellax-min-x"),D=b.getAttribute("data-rellax-max-x"),E=b.getAttribute("data-rellax-min-y"),L=b.getAttribute("data-rellax-max-y"),r=!0;t||g||h||k?c={xs:t,sm:g,md:h,lg:k}:r=!1;t=a.options.wrapper?a.options.wrapper.scrollTop:window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop;a.options.relativeToWrapper&&
9    (t=(window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop)-a.options.wrapper.offsetTop);var z=a.options.vertical?e||a.options.center?t:0:0,I=a.options.horizontal?e||a.options.center?a.options.wrapper?a.options.wrapper.scrollLeft:window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft:0:0;t=z+b.getBoundingClientRect().top;g=b.clientHeight||b.offsetHeight||b.scrollHeight;h=I+b.getBoundingClientRect().left;k=b.clientWidth||b.offsetWidth||b.scrollWidth;
10        z=e?e:(z-t+v)/(g+v);e=e?e:(I-h+n)/(k+n);a.options.center&&(z=e=.5);c=r&&null!==c[F]?Number(c[F]):y?y:a.options.speed;l=l?l:a.options.verticalSpeed;m=m?m:a.options.horizontalSpeed;p=p?p:a.options.verticalScrollAxis;q=q?q:a.options.horizontalScrollAxis;y=J(e,z,c,l,m);b=b.style.cssText;r="";if(e=/transform\s*:/i.exec(b))r=b.slice(e.index),r=(e=r.indexOf(";"))?" "+r.slice(11,e).replace(/\s/g,""):" "+r.slice(11).replace(/\s/g,"");d.push({baseX:y.x,baseY:y.y,top:t,left:h,height:g,width:k,speed:c,verticalSpeed:l,
11            horizontalSpeed:m,verticalScrollAxis:p,horizontalScrollAxis:q,style:b,transform:r,zindex:u,min:x,max:A,minX:C,maxX:D,minY:E,maxY:L})}K();w&&(window.addEventListener("resize",B),w=!1,G())},H=function(){var d=l,c=m;l=a.options.wrapper?a.options.wrapper.scrollTop:(document.documentElement||document.body.parentNode||document.body).scrollTop||window.pageYOffset;m=a.options.wrapper?a.options.wrapper.scrollLeft:(document.documentElement||document.body.parentNode||document.body).scrollLeft||window.pageXOffset;
12        a.options.relativeToWrapper&&(l=((document.documentElement||document.body.parentNode||document.body).scrollTop||window.pageYOffset)-a.options.wrapper.offsetTop);return d!=l&&a.options.vertical||c!=m&&a.options.horizontal?!0:!1},J=function(d,c,b,e,g){var f={};d=100*(g?g:b)*(1-d);c=100*(e?e:b)*(1-c);f.x=a.options.round?Math.round(d):Math.round(100*d)/100;f.y=a.options.round?Math.round(c):Math.round(100*c)/100;return f},h=function(){window.removeEventListener("resize",h);window.removeEventListener("orientationchange",
13        h);(a.options.wrapper?a.options.wrapper:window).removeEventListener("scroll",h);(a.options.wrapper?a.options.wrapper:document).removeEventListener("touchmove",h);p=A(G)},G=function(){H()&&!1===w?(K(),p=A(G)):(p=null,window.addEventListener("resize",h),window.addEventListener("orientationchange",h),(a.options.wrapper?a.options.wrapper:window).addEventListener("scroll",h,x?{passive:!0}:!1),(a.options.wrapper?a.options.wrapper:document).addEventListener("touchmove",h,x?{passive:!0}:!1))},K=function(){for(var f,
14                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       c=0;c<a.elems.length;c++){var b=d[c].verticalScrollAxis.toLowerCase(),e=d[c].horizontalScrollAxis.toLowerCase();f=-1!=b.indexOf("x")?l:0;b=-1!=b.indexOf("y")?l:0;var g=-1!=e.indexOf("x")?m:0;e=-1!=e.indexOf("y")?m:0;f=J((f+g-d[c].left+n)/(d[c].width+n),(b+e-d[c].top+v)/(d[c].height+v),d[c].speed,d[c].verticalSpeed,d[c].horizontalSpeed);e=f.y-d[c].baseY;b=f.x-d[c].baseX;null!==d[c].min&&(a.options.vertical&&!a.options.horizontal&&(e=e<=d[c].min?d[c].min:e),a.options.horizontal&&!a.options.vertical&&
15    (b=b<=d[c].min?d[c].min:b));null!=d[c].minY&&(e=e<=d[c].minY?d[c].minY:e);null!=d[c].minX&&(b=b<=d[c].minX?d[c].minX:b);null!==d[c].max&&(a.options.vertical&&!a.options.horizontal&&(e=e>=d[c].max?d[c].max:e),a.options.horizontal&&!a.options.vertical&&(b=b>=d[c].max?d[c].max:b));null!=d[c].maxY&&(e=e>=d[c].maxY?d[c].maxY:e);null!=d[c].maxX&&(b=b>=d[c].maxX?d[c].maxX:b);a.elems[c].style[E]="translate3d("+(a.options.horizontal?b:"0")+"px,"+(a.options.vertical?e:"
150")+"px,"+d[c].zindex+"px) "+d[c].transform}a.options.callback(f)};
16        a.destroy=function(){for(var f=0;f<a.elems.length;f++)a.elems[f].style.cssText=d[f].style;w||(window.removeEventListener("resize",B),w=!0);D(p);p=null};B();a.refresh=B;return a}console.warn("Rellax: The elements you're trying to select don't exist.")};return q});
17/* End */
18;
19; /* Start:"a:4:{s:4:"full";s:83:"/local/templates/CAIMAN_2025/assets/vendor/parallax/jarallax.min.js?171255500810514";s:6:"source";s:67:"/local/templates/CAIMAN_2025/assets/vendor/parallax/jarallax.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
20/*!
21 * Jarallax v2.1.4 (https://github.com/nk-o/jarallax)
22 * Copyright 2023 nK <https://nkdev.info>
23 * Licensed under MIT (https://github.com/nk-o/jarallax/blob/master/LICENSE)
24 */
25!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).jarallax=t()}(this,(function(){"use strict";function e(e){"complete"===document.readyState||"interactive"===document.readyState?e():document.addEventListener("DOMContentLoaded",e,{capture:!0,once:!0,passive:!0})}let t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};var i=t,o={type:"scroll",speed:.5,containerClass:"jarallax-container",imgSrc:null,imgElement:".jarallax-img",imgSize:"cover",imgPosition:"50% 50%",imgRepeat:"no-repeat",keepImg:!1,elementInViewport:null,zIndex:-100,disableParallax:!1,onScroll:null,onInit:null,onDestroy:null,onCoverImage:null,videoClass:"jarallax-video",videoSrc:null,videoStartTime:0,videoEndTime:0,videoVolume:0,videoLoop:!0,videoPlayOnlyVisible:!0,videoLazyLoading:!0,disableVideo:!1,onVideoInsert:null,onVideoWorkerInit:null};const{navigator:n}=i,a=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(n.userAgent);let s,l,r;function c(){s=i.innerWidth||document.documentElement.clientWidth,a?(!r&&document.body&&(r=document.createElement("div"),r.style.cssText="position: fixed; top: -9999px; left: 0; height: 100vh; width: 0;",document.body.appendChild(r)),l=(r?r.clientHeight:0)||i.innerHeight||document.documentElement.clientHeight):l=i.innerHeight||document.documentElement.clientHeight}function m(){return{width:s,height:l}}c(),i.addEventListener("resize",c),i.addEventListener("orientationchange",c),i.addEventListener("load",c),e((()=>{c()}));const p=[];function d(){if(!p.length)return;const{width:e,height:t}=m();p.forEach(((i,o)=>{const{instance:n,oldData:a}=i;if(!n.isVisible())return;const s=n.$item.getBoundingClientRect(),l={width:s.width,height:s.height,top:s.top,bottom:s.bottom,wndW:e,wndH:t},r=!a||a.wndW!==l.wndW||a.wndH!==l.wndH||a.width!==l.width||a.height!==l.height,c=r||!a||a.top!==l.top||a.bottom!==l.bottom;p[o].oldData=l,r&&n.onResize(),c&&n.onScroll()})),i.requestAnimationFrame(d)}const g=new i.IntersectionObserver((e=>{e.forEach((e=>{e.target.jarallax.isElementInViewport=e.isIntersecting}))}),{rootMargin:"50px"});const{navigator:u}=i;let f=0;class h{constructor(e,t){const i=this;i.instanceID=f,f+=1,i.$item=e,i.defaults={...o};const n=i.$item.dataset||{},a={};if(Object.keys(n).forEach((e=>{const t=e.substr(0,1).toLowerCase()+e.substr(1);t&&void 0!==i.defaults[t]&&(a[t]=n[e])})),i.options=i.extend({},i.defaults,a,t),i.pureOptions=i.extend({},i.options),Object.keys(i.options).forEach((e=>{"true"===i.options[e]?i.options[e]=!0:"false"===i.options[e]&&(i.options[e]=!1)})),i.options.speed=Math.min(2,Math.max(-1,parseFloat(i.options.speed))),"string"==typeof i.options.disableParallax&&(i.options.disableParallax=new RegExp(i.options.disableParallax)),i.options.disableParallax instanceof RegExp){const e=i.options.disableParallax;i.options.disableParallax=()=>e.test(u.userAgent)}if("function"!=typeof i.options.disableParallax&&(i.options.disableParallax=()=>!1),"string"==typeof i.options.disableVideo&&(i.options.disableVideo=new RegExp(i.options.disableVideo)),i.options.disableVideo instanceof RegExp){const e=i.options.disableVideo;i.options.disableVideo=()=>e.test(u.userAgent)}"function"!=typeof i.options.disableVideo&&(i.options.disableVideo=()=>!1);let s=i.options.elementInViewport;s&&"object"==typeof s&&void 0!==s.length&&([s]=s),s instanceof Element||(s=null),i.options.elementInViewport=s,i.image={src:i.options.imgSrc||null,$container:null,useImgTag:!1,position:"fixed"},i.initImg()&&i.canInitParallax()&&i.init()}css(e,t){return function(e,t){return"string"==typeof t?i.getComputedStyle(e).getPropertyValue(t):(Object.keys(t).forEach((i=>{e.style[i]=t[i]})),e)}(e,t)}extend(e,...t){return function(e,...t){return e=e||{},Object.keys(t).forEach((i=>
25{t[i]&&Object.keys(t[i]).forEach((o=>{e[o]=t[i][o]}))})),e}(e,...t)}getWindowData(){const{width:e,height:t}=m();return{width:e,height:t,y:document.documentElement.scrollTop}}initImg(){const e=this;let t=e.options.imgElement;return t&&"string"==typeof t&&(t=e.$item.querySelector(t)),t instanceof Element||(e.options.imgSrc?(t=new Image,t.src=e.options.imgSrc):t=null),t&&(e.options.keepImg?e.image.$item=t.cloneNode(!0):(e.image.$item=t,e.image.$itemParent=t.parentNode),e.image.useImgTag=!0),!!e.image.$item||(null===e.image.src&&(e.image.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",e.image.bgImage=e.css(e.$item,"background-image")),!(!e.image.bgImage||"none"===e.image.bgImage))}canInitParallax(){return!this.options.disableParallax()}init(){const e=this,t={position:"absolute",top:0,left:0,width:"100%",height:"100%",overflow:"hidden"};let o={pointerEvents:"none",transformStyle:"preserve-3d",backfaceVisibility:"hidden"};if(!e.options.keepImg){const t=e.$item.getAttribute("style");if(t&&e.$item.setAttribute("data-jarallax-original-styles",t),e.image.useImgTag){const t=e.image.$item.getAttribute("style");t&&e.image.$item.setAttribute("data-jarallax-original-styles",t)}}if("static"===e.css(e.$item,"position")&&e.css(e.$item,{position:"relative"}),"auto"===e.css(e.$item,"z-index")&&e.css(e.$item,{zIndex:0}),e.image.$container=document.createElement("div"),e.css(e.image.$container,t),e.css(e.image.$container,{"z-index":e.options.zIndex}),"fixed"===this.image.position&&e.css(e.image.$container,{"-webkit-clip-path":"polygon(0 0, 100% 0, 100% 100%, 0 100%)","clip-path":"polygon(0 0, 100% 0, 100% 100%, 0 100%)"}),e.image.$container.setAttribute("id",`jarallax-container-${e.instanceID}`),e.options.containerClass&&e.image.$container.setAttribute("class",e.options.containerClass),e.$item.appendChild(e.image.$container),e.image.useImgTag?o=e.extend({"object-fit":e.options.imgSize,"object-position":e.options.imgPosition,"max-width":"none"},t,o):(e.image.$item=document.createElement("div"),e.image.src&&(o=e.extend({"background-position":e.options.imgPosition,"background-size":e.options.imgSize,"background-repeat":e.options.imgRepeat,"background-image":e.image.bgImage||`url("${e.image.src}")`},t,o))),"opacity"!==e.options.type&&"scale"!==e.options.type&&"scale-opacity"!==e.options.type&&1!==e.options.speed||(e.image.position="absolute"),"fixed"===e.image.position){const t=function(e){const t=[];for(;null!==e.parentElement;)1===(e=e.parentElement).nodeType&&t.push(e);return t}(e.$item).filter((e=>{const t=i.getComputedStyle(e),o=t["-webkit-transform"]||t["-moz-transform"]||t.transform;return o&&"none"!==o||/(auto|scroll)/.test(t.overflow+t["overflow-y"]+t["overflow-x"])}));e.image.position=t.length?"absolute":"fixed"}var n;o.position=e.image.position,e.css(e.image.$item,o),e.image.$container.appendChild(e.image.$item),e.onResize(),e.onScroll(!0),e.o
25ptions.onInit&&e.options.onInit.call(e),"none"!==e.css(e.$item,"background-image")&&e.css(e.$item,{"background-image":"none"}),n=e,p.push({instance:n}),1===p.length&&i.requestAnimationFrame(d),g.observe(n.options.elementInViewport||n.$item)}destroy(){const e=this;var t;t=e,p.forEach(((e,i)=>{e.instance.instanceID===t.instanceID&&p.splice(i,1)})),g.unobserve(t.options.elementInViewport||t.$item);const i=e.$item.getAttribute("data-jarallax-original-styles");if(e.$item.removeAttribute("data-jarallax-original-styles"),i?e.$item.setAttribute("style",i):e.$item.removeAttribute("style"),e.image.useImgTag){const t=e.image.$item.getAttribute("data-jarallax-original-styles");e.image.$item.removeAttribute("data-jarallax-original-styles"),t?e.image.$item.setAttribute("style",i):e.image.$item.removeAttribute("style"),e.image.$itemParent&&e.image.$itemParent.appendChild(e.image.$item)}e.image.$container&&e.image.$container.parentNode.removeChild(e.image.$container),e.options.onDestroy&&e.options.onDestroy.call(e),delete e.$item.jarallax}coverImage(){const e=this,{height:t}=m(),i=e.image.$container.getBoundingClientRect(),o=i.height,{speed:n}=e.options,a="scroll"===e.options.type||"scroll-opacity"===e.options.type;let s=0,l=o,r=0;return a&&(n<0?(s=n*Math.max(o,t),t<o&&(s-=n*(o-t))):s=n*(o+t),n>1?l=Math.abs(s-t):n<0?l=s/n+Math.abs(s):l+=(t-o)*(1-n),s/=2),e.parallaxScrollDistance=s,r=a?(t-l)/2:(o-l)/2,e.css(e.image.$item,{height:`${l}px`,marginTop:`${r}px`,left:"fixed"===e.image.position?`${i.left}px`:"0",width:`${i.width}px`}),e.options.onCoverImage&&e.options.onCoverImage.call(e),{image:{height:l,marginTop:r},container:i}}isVisible(){return this.isElementInViewport||!1}onScroll(e){const t=this;if(!e&&!t.isVisible())return;const{height:i}=m(),o=t.$item.getBoundingClientRect(),n=o.top,a=o.height,s={},l=Math.max(0,n),r=Math.max(0,a+n),c=Math.max(0,-n),p=Math.max(0,n+a-i),d=Math.max(0,a-(n+a-i)),g=Math.max(0,-n+i-a),u=1-(i-n)/(i+a)*2;let f=1;if(a<i?f=1-(c||p)/a:r<=i?f=r/i:d<=i&&(f=d/i),"opacity"!==t.options.type&&"scale-opacity"!==t.options.type&&"scroll-opacity"!==t.options.type||(s.transform="translate3d(0,0,0)",s.opacity=f),"scale"===t.options.type||"scale-opacity"===t.options.type){let e=1;t.options.speed<0?e-=t.options.speed*f:e+=t.options.speed*(1-f),s.transform=`scale(${e}) translate3d(0,0,0)`}if("scroll"===t.options.type||"scroll-opacity"===t.options.type){let e=t.parallaxScrollDistance*u;"absolute"===t.image.position&&(e-=n),s.transform=`translate3d(0,${e}px,0)`}t.css(t.image.$item,s),t.options.onScroll&&t.options.onScroll.call(t,{section:o,beforeTop:l,beforeTopEnd:r,afterTop:c,beforeBottom:p,beforeBottomEnd:d,afterBottom:g,visiblePercent:f,fromViewportCenter:u})}onResize(){this.coverImage()}}const b=function(e,t,...i){("object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName)&&(e=[e]);const o=e.length;let n,a=0;for(;a<o;a+=1)if("object"==typeof t||void 0===t?e[a].jarallax||(e[a].jarallax=new h(e[a],t)):e[a].jarallax&&(n=e[a].jarallax[t].apply(e[a].jarallax,i)),void 0!==n)return n;return e};b.constructor=h;const y=i.jQuery;if(void 0!==y){const e=function(...e){Array.prototype.unshift.call(e,this);const t=b.apply(i,e);return"object"!=typeof t?t:this};e.constructor=b.constructor;const t=y.fn.jarallax;y.fn.jarallax=e,y.fn.jarallax.noConflict=function(){return y.fn.jarallax=t,this}}return e((()=>{b(document.querySelectorAll("[data-jarallax]"))})),b}));//# sourceMappingURL=jarallax.min.js.map
26/* End */
27;
28; /* Start:"a:4:{s:4:"full";s:83:"/local/templates/CAIMAN_2025/assets/vendor/parallax/parallax.min.js?171255502917313";s:6:"source";s:67:"/local/templates/CAIMAN_2025/assets/vendor/parallax/parallax.min.js";s:3:"min";s:67:"/local/templates/CAIMAN_2025/assets/vendor/parallax/parallax.min.js";s:3:"map";s:71:"/local/templates/CAIMAN_2025/assets/vendor/parallax/parallax.min.js.map";}"*/
vendor: 17,274 bytes, lines 29-30
29!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).Parallax=t()}}(function(){return function t(e,i,n){function o(r,a){if(!i[r]){if(!e[r]){var l="function"==typeof require&&require;if(!a&&l)return l(r,!0);if(s)return s(r,!0);var h=new Error("Cannot find module '"+r+"'");throw h.code="MODULE_NOT_FOUND",h}var u=i[r]={exports:{}};e[r][0].call(u.exports,function(t){var i=e[r][1][t];return o(i||t)},u,u.exports,t,e,i,n)}return i[r].exports}for(var s="function"==typeof require&&require,r=0;r<n.length;r++)o(n[r]);return o}({1:[function(t,e,i){"use strict";function n(t){if(null===t||void 0===t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}var o=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return!1;for(var e={},i=0;i<10;i++)e["_"+String.fromCharCode(i)]=i;if("0123456789"!==Object.getOwnPropertyNames(e).map(function(t){return e[t]}).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach(function(t){n[t]=t}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(t){return!1}}()?Object.assign:function(t,e){for(var i,a,l=n(t),h=1;h<arguments.length;h++){i=Object(arguments[h]);for(var u in i)s.call(i,u)&&(l[u]=i[u]);if(o){a=o(i);for(var c=0;c<a.length;c++)r.call(i,a[c])&&(l[a[c]]=i[a[c]])}}return l}},{}],2:[function(t,e,i){(function(t){(function(){var i,n,o,s,r,a;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:void 0!==t&&null!==t&&t.hrtime?(e.exports=function(){return(i()-r)/1e6},n=t.hrtime,s=(i=function(){var t;return 1e9*(t=n())[0]+t[1]})(),a=1e9*t.uptime(),r=s-a):Date.now?(e.exports=function(){return Date.now()-o},o=Date.now()):(e.exports=function(){return(new Date).getTime()-o},o=(new Date).getTime())}).call(this)}).call(this,t("_process"))},{_process:3}],3:[function(t,e,i){function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(t){if(c===setTimeout)return setTimeout(t,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(t,0);try{return c(t,0)}catch(e){try{return c.call(null,t,0)}catch(e){return c.call(this,t,0)}}}function r(t){if(d===clearTimeout)return clearTimeout(t);if((d===o||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(t);try{return d(t)}catch(e){try{return d.call(null,t)}catch(e){return d.call(this,t)}}}function a(){v&&p&&(v=!1,p.length?f=p.concat(f):y=-1,f.length&&l())}function l(){if(!v){var t=s(a);v=!0;for(var e=f.length;e;){for(p=f,f=[];++y<e;)p&&p[y].run();y=-1,e=f.length}p=null,v=!1,r(t)}}function h(t,e){this.fun=t,this.array=e}function u(){}var c,d,m=e.exports={};!function(){try{c="function"==typeof setTimeout?setTimeout:n}catch(t){c=n}try{d="function"==typeof clearTimeout?clearTimeout:o}catch(t){d=o}}();var p,f=[],v=!1,y=-1;m.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)e[i-1]=arguments[i];f.push(new h(t,e)),1!==f.length||v||s(l)},h.prototype.run=function(){this.fun.apply(null,this.array)},m.title="browser",m.browser=!0,m.env={},m.argv=[],m.version="",m.versions={},m.on=u,m.addListener=u,m.once=u,m.off=u,m.removeListener=u,m.removeAllListeners=u,m.emit=u,m.prependListener=u,m.prependOnceListener=u,m.listeners=function(t){return[]},m.binding=function(t){throw new Error("process.binding is not supported")},m.cwd=function(){return"/"},m.chdir=function(t){throw new Error("process.chdir is not supported")},m.umask=function(){return 0}},{}],4:[function(t,e,i){(function(i){for(var n=t("performance-now"),o="undefined"==typeof window?i:window,s=["moz","webkit"],r="AnimationFrame",a=o["request"+r],l=o["cancel"+r]||o["cancelRequest"+r],h=0;!a&&h<s.length;h++)a=o[s[h]+"Request"+r],l=o[s[h]+"Cancel"+r]||o[s[h]+"CancelRequest"+r];if(!a||!l){var u=0,c=0,d=[];a=function(t){if(0===d.length){var e=n(),i=Math.max(0,1e3/60-(e-u));u=i+e,setTimeout(function(){var t=d.slice(0);d.length=0;for(var e=0;e<t.length;e++)if(!t[e].cancelled)try{t[e].callback(u)}catch(t){setTimeout(function(){throw t},0)}},Math.round(i))}return d.push({handle:++c,callback:t,cancelled:!1}),c},l=function(t){for(var e=0;e<d.length;e++)d[e].handle===t&&(d[e].cancelled=!0)}}e.exports=function(t){return a.call(o,t)},e.exports.cancel=function(){l.apply(o,arguments)},e.exports.polyfill=function(){o.requestAnimationFrame=a,o.cancelAnimationFrame=l}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"performance-now":2}],5:[function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var o=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}(),s=t("raf"),r=t("object-assign"),a={propertyCache:{},vendors:[null,["-webkit-","webkit"],["-moz-","Moz"],["-o-","O"],["-ms-","ms"]],clamp:function(t,e,i){return e<i?t<e?e:t>i?i:t:t<i?i:t>e?e:t},data:function(t,e){return a.deserialize(t.getAttribute("data-"+e))},deserialize:function(t){return"true"===t||"false"!==t&&("null"===t?null:!isNaN(parseFloat(t))&&isFinite(t)?parseFloat(t):t)},camelCase:function(t){return t.replace(/-+(.)?/g,function(t,e){return e?e.toUpperCase():""})},accelerate:function(t){a.css(t,"transform","translate3d(0,0,0) rotate(0.0001deg)"),a.css(t,"transform-style","preserve-3d"),a.css(t,"backface-visibility","hidden")},transformSupport:function(t){for(var e=document.createElement("div"),i=!1,n=null,o=!1,s=null,r=null,l=0,h=a.vendors.length;l<h;l++)if(null!==a.vendors[l]?(s=a.vendors[l][0]+"transform",r=a.vendors[l][1]+"Transform"):(s="transform",r="transform"),void 0!==e.style[r]){i=!0;break}switch(t){case"2D":o=i;break;case"3D":if(i){var u=document.body||document.createElement("body"),c=document.documentElement,d=c.style.overflow,m=!1;document.body||(m=!0,c.style.overflow="hidden",c.appendChild(u),u.style.overflow="hidden",u.style.background=""),u.appendChild(e),e.style[r]="translate3d(1px,1px,1px)",o=void 0!==(n=window.getComputedStyle(e).getPropertyValue(s))&&n.length>0&&"none"!==n,c.style.overflow=d,u.removeChild(e),m&&(u.removeAttribute("style"),u.parentNode.removeChild(u))}}return o},css:function(t,e,i){var n=a.propertyCache[e];if(!n)for(var o=0,s=a.vendors.length;o<s;o++)if(n=null!==a.vendors[o]?a.camelCase(a.vendors[o][1]+"-"+e):e,void 0!==t.style[n]){a.propertyCache[e]=n;break}t.style[n]=i}},l={relativeInput:!1,clipRelativeInput:!1,inputElement:null,hoverOnly:!1,calibrationThreshold:100,calibrationDelay:500,supportDelay:500,calibrateX:!1,calibrateY:!0,invertX:!0,invertY:!0,limitX:!1,limitY:!1,scalarX:10,scalarY:10,frictionX:.1,frictionY:.1,originX:.5,originY:.5,pointerEvents:!1,precision:1,onReady:null,selector:null},h=function(){function t(e,i){n(this,t),this.element=e;var o={calibrateX:a.data(this.element,"calibrate-x"),calibrateY:a.data(this.element,"calibrate-y"),invertX:a.data(this.element,"invert-x"),invertY:a.data(this.element,"invert-y"),limitX:a.data(this.element,"limit-x"),limitY:a.data(this.element,"limit-y"),scalarX:a.data(this.element,"scalar-x"),scalarY:a.data(this.element,"scalar-y"),frictionX:a.data(this.element,"friction-x"),frictionY:a.data(this.element,"friction-y"),originX:a.data(this.element,"origin-x"),originY:a.data(this.element,"origin-y"),pointerEvents:a.data(this.element,"pointer-events"),precision:a.data(this.element,"precision"),relativeInput:a.data(this.element,"relative-input"),clipRelativeInput:a.data(this.element,"clip-relative-input"),hoverOnly:a.data(this.element,"hover-only"),inputElement:document.querySelector(a.data(this.element,"input-element")),selector:a.data(this.element,"selector")};for(var s in o)null===o[s]&&delete o[s];r(this,l,o,i),this.inputElement||(this.inputElement=this.element),this.calibrationTimer=null,this.calibrationFlag=!0,this.enabled=!1,this.depthsX=[],this.depthsY=[],this.raf=null,this.bounds=null,this.elementPositionX=0,this.elementPositionY=0,this.elementWidth=0,this.elementHeight=0,this.elementCenterX=0,this.elementCenterY=0,this.elementRangeX=0,this.elementRangeY=0,this.calibrationX=0,this.calibrationY=0,this.inputX=0,this.inputY=0,this.motionX=0,this.motionY=0,this.velocityX=0,this.velocityY=0,this.onMouseMove=this.onMouseMove.bind(this),this.onDeviceOrientation=this.onDeviceOrientation.bind(this),this.onDeviceMotion=this.onDeviceMotion.bind(this),this.onOrientationTimer=this.onOrientationTimer.bind(this),this.onMotionTimer=this.onMotionTimer.bind(this),this.onCalibrationTimer=this.onCalibrationTimer.bind(this),this.onAnimationFrame=this.onAnimationFrame.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.windowWidth=null,this.windowHeight=null,this.windowCenterX=null,this.windowCenterY=null,this.windowRadiusX=null,this.windowRadiusY=null,this.portrait=!1,this.desktop=!navigator.userAgent.match(/(iPhone|iPod|iPad|Android|BlackBerry|BB10|mobi|tablet|opera mini|nexus 7)/i),this.motionSupport=!!window.DeviceMotionEvent&&!this.desktop,this.orientationSupport=!!window.DeviceOrientationEvent&&!this.desktop,this.orientationStatus=0,this.motionStatus=0,this.initialise()}return o(t,[{key:"initialise",value:function(){void 0===this.transform2DSupport&&(this.transform2DSupport=a.transformSupport("2D"),this.transform3DSupport=a.transformSupport("3D")),this.transform3DSupport&&a.accelerate(this.element),"static"===window.getComputedStyle(this.element).getPropertyValue("position")&&(this.element.style.position="relative"),this.pointerEvents||(this.element.style.pointerEvents="none"),this.updateLayers(),this.updateDimensions(),this.enable(),this.queueCalibration(this.calibrationDelay)}},{key:"doReadyCallback",value:function(){this.onReady&&this.onReady()}},{key:"updateLayers",value:function(){this.selector?this.layers=this.element.querySelectorAll(this.selector):this.layers=this.element.children,this.layers.length||console.warn("ParallaxJS: Your scene does not have any layers."),this.depthsX=[],this.depthsY=[];for(var t=0;t<this.layers.length;t++){var e=this.layers[t];this.transform3DSupport&&a.accelerate(e),e.style.position=t?"absolute":"relative",e.style.display="block",e.style.left=0,e.style.top=0;var i=a.data(e,"depth")||0;this.depthsX.push(a.data(e,"depth-x")||i),this.depthsY.push(a.data(e,"depth-y")||i)}}},{key:"updateDimensions",value:function(){this.windowWidth=window.innerWidth,this.windowHeight=window.innerHeight,this.windowCenterX=this.windowWidth*this.originX,this.windowCenterY=this.windowHeight*this.originY,this.windowRadiusX=Math.max(this.windowCenterX,this.windowWidth-this.windowCenterX),this.windowRadiusY=Math.max(this.windowCenterY,this.windowHeight-this.windowCenterY)}},{key:"updateBounds",value:function(){this.bounds=this.inputElement.getBoundingClientRect(),this.elementPositionX=this.bounds.left,this.elementPositionY=this.bounds.top,this.elementWidth=this.bounds.width,this.elementHeight=this.bounds.height,this.elementCenterX=this.elementWidth*this.originX,this.elementCenterY=this.elementHeight*this.originY,this.elementRangeX=Math.max(this.elementCenterX,this.elementWidth-this.elementCenterX),this.elementRangeY=Math.max(this.elementCenterY,this.elementHeight-this.elementCenterY)}},{key:"queueCalibration",value:function(t){clearTimeout(this.calibrationTimer),this.calibrationTimer=setTimeout(this.onCalibrationTimer,t)}},{key:"enable",value:function(){this.enabled||(this.enabled=!0,this.orientationSupport?(this.portrait=!1,window.addEventListener("deviceorientation",this.onDeviceOrientation),this.detectionTimer=setTimeout(this.onOrientationTimer,this.supportDelay)):this.motionSupport?(this.portrait=!1,window.addEventListener("devicemotion",this.onDeviceMotion),this.detectionTimer=setTimeout(this.onMotionTimer,this.supportDelay)):(this.calibrationX=0,this.calibrationY=0,this.portrait=!1,window.addEventListener("mousemove",this.onMouseMove),this.doReadyCallback()),window.addEventListener("resize",this.onWindowResize),this.raf=s(this.onAnimationFrame))}},{key:"disable",value:function(){this.enabled&&(this.enabled=!1,this.orientationSupport?window.removeEventListener("deviceorientation",this.onDeviceOrientation):this.motionSupport?window.removeEventListener("devicemotion",this.onDeviceMotion):window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("resize",this.onWindowResize),s.cancel(this.raf))}},{key:"calibrate",value:function(t,e){this.calibrateX=void 0===t?this.calibrateX:t,this.calibrateY=void 0===e?this.calibrateY:e}},{key:"invert",value:function(t,e){this.invertX=void 0===t?this.invertX:t,this.invertY=void 0===e?this.invertY:e}},{key:"friction",value:function(t,e){this.frictionX=void 0===t?this.frictionX:t,this.frictionY=void 0===e?this.frictionY:e}},{key:"scalar",value:function(t,e){this.scalarX=void 0===t?this.scalarX:t,this.scalarY=void 0===e?this.scalarY:e}},{key:"limit",value:function(t,e){this.limitX=void 0===t?this.limitX:t,this.limitY=void 0===e?this.limitY:e}},{key:"origin",value:function(t,e){this.originX=void 0===t?this.originX:t,this.originY=void 0===e?this.originY:e}},{key:"setInputElement",value:function(t){this.inputElement=t,this.updateDimensions()}},{key:"setPosition",value:function(t,e,i){e=e.toFixed(this.precision)+"px",i=i.toFixed(this.precision)+"px",this.transform3DSupport?a.css(t,"transform","translate3d("+e+","+i+",0)"):this.transform2DSupport?a.css(t,"transform","translate("+e+","+i+")"):(t.style.left=e,t.style.top=i)}},{key:"onOrientationTimer",value:function(){this.orientationSupport&&0===this.orientationStatus?(this.disable(),this.orientationSupport=!1,this.enable()):this.doReadyCallback()}},{key:"onMotionTimer",value:function(){this.motionSupport&&0===this.motionStatus?(this.disable(),this.motionSupport=!1,this.enable()):this.doReadyCallback()}},{key:"onCalibrationTimer",value:function(){this.calibrationFlag=!0}},{key:"onWindowResize",value:function(){this.updateDimensions()}},{key:"onAnimationFrame",value:function(){this.updateBounds();var t=this.inputX-this.calibrationX,e=this.inputY-this.calibrationY;(Math.abs(t)>this.calibrationThreshold||Math.abs(e)>this.calibrationThreshold)&&this.queueCalibration(0),this.portrait?(this.motionX=this.calibrateX?e:this.inputY,this.motionY=this.calibrateY?t:this.inputX):(this.motionX=this.calibrateX?t:this.inputX,this.motionY=this.calibrateY?e:this.inputY),this.motionX*=this.elementWidth*(this.scalarX/100),this.motionY*=this.elementHeight*(this.scalarY/100),isNaN(parseFloat(this.limitX))||(this.motionX=a.clamp(this.motionX,-this.limitX,this.limitX)),isNaN(parseFloat(this.limitY))||(this.motionY=a.clamp(this.motionY,-this.limitY,this.limitY)),this.velocityX+=(this.motionX-this.velocityX)*this.frictionX,this.velocityY+=(this.motionY-this.velocityY)*this.frictionY;for(var i=0;i<this.layers.length;i++){var n=this.layers[i],o=this.depthsX[i],r=this.depthsY[i],l=this.velocityX*(o*(this.invertX?-1:1)),h=this.velocityY*(r*(this.invertY?-1:1));this.setPosition(n,l,h)}this.raf=s(this.onAnimationFrame)}},{key:"rotate",value:function(t,e){var i=(t||0)/30,n=(e||0)/30,o=this.windowHeight>this.windowWidth;this.portrait!==o&&(this.portrait=o,this.calibrationFlag=!0),this.calibrationFlag&&(this.calibrationFlag=!1,this.calibrationX=i,this.calibrationY=n),this.inputX=i,this.inputY=n}},{key:"onDeviceOrientation",value:function(t){var e=t.beta,i=t.gamma;null!==e&&null!==i&&(this.orientationStatus=1,this.rotate(e,i))}},{key:"onDeviceMotion",value:function(t){var e=t.rotationRate.beta,i=t.rotationRate.gamma;null!==e&&null!==i&&(this.motionStatus=1,this.rotate(e,i))}},{key:"onMouseMove",value:function(t){var e=t.clientX,i=t.clientY;if(this.hoverOnly&&(e<this.elementPositionX||e>this.elementPositionX+this.elementWidth||i<this.elementPositionY||i>this.elementPositionY+this.elementHeight))return this.inputX=0,void(this.inputY=0);this.relativeInput?(this.clipRelativeInput&&(e=Math.max(e,this.elementPositionX),e=Math.min(e,this.elementPositionX+this.elementWidth),i=Math.max(i,this.elementPositionY),i=Math.min(i,this.elementPositionY+this.elementHeight)),this.elementRangeX&&this.elementRangeY&&(this.inputX=(e-this.elementPositionX-this.elementCenterX)/this.elementRangeX,this.inputY=(i-this.elementPositionY-this.elementCenterY)/this.elementRangeY)):this.windowRadiusX&&this.windowRadiusY&&(this.inputX=(e-this.windowCenterX)/this.windowRadiusX,this.inputY=(i-this.windowCenterY)/this.windowRadiusY)}},{key:"destroy",value:function(){this.disable(),clearTimeout(this.calibrationTimer),clearTimeout(this.detectionTimer),this.element.removeAttribute("style");for(var t=0;t<this.layers.length;t++)this.layers[t].removeAttribute("style");delete this.element,delete this.layers}},{key:"version",value:function(){return"3.1.0"}}]),t}();e.exports=h},{"object-assign":1,raf:4}]},{},[5])(5)});
30/
30* End */
31;
32; /* Start:"a:4:{s:4:"full";s:87:"/local/templates/CAIMAN_2025/assets/vendor/swiper/swiper-bundle.min.js?1753855596143706";s:6:"source";s:70:"/local/templates/CAIMAN_2025/assets/vendor/swiper/swiper-bundle.min.js";s:3:"min";s:70:"/local/templates/CAIMAN_2025/assets/vendor/swiper/swiper-bundle.min.js";s:3:"map";s:74:"/local/templates/CAIMAN_2025/assets/vendor/swiper/swiper-bundle.min.js.map";}"*/
33/**
34 * Swiper 8.4.7
35 * Most modern mobile touch slider and framework with hardware accelerated transitions
36 * https://swiperjs.com
37 *
38 * Copyright 2014-2023 Vladimir Kharlampidi
39 *
40 * Released under the MIT License
41 *
42 * Released on: January 30, 2023
43 */
44
45!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).Swiper=t()}(this,(function(){"use strict";function e(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function t(s,a){void 0===s&&(s={}),void 0===a&&(a={}
vendor: 33,674 bytes, line 45
45),Object.keys(a).forEach((i=>{void 0===s[i]?s[i]=a[i]:e(a[i])&&e(s[i])&&Object.keys(a[i]).length>0&&t(s[i],a[i])}))}const s={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function a(){const e="undefined"!=typeof document?document:{};return t(e,s),e}const i={document:s,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function r(){const e="undefined"!=typeof window?window:{};return t(e,i),e}class n extends Array{constructor(e){"number"==typeof e?super(e):(super(...e||[]),function(e){const t=e.__proto__;Object.defineProperty(e,"__proto__",{get:()=>t,set(e){t.__proto__=e}})}(this))}}function l(e){void 0===e&&(e=[]);const t=[];return e.forEach((e=>{Array.isArray(e)?t.push(...l(e)):t.push(e)})),t}function o(e,t){return Array.prototype.filter.call(e,t)}function d(e,t){const s=r(),i=a();let l=[];if(!t&&e instanceof n)return e;if(!e)return new n(l);if("string"==typeof e){const s=e.trim();if(s.indexOf("<")>=0&&s.indexOf(">")>=0){let e="div";0===s.indexOf("<li")&&(e="ul"),0===s.indexOf("<tr")&&(e="tbody"),0!==s.indexOf("<td")&&0!==s.indexOf("<th")||(e="tr"),0===s.indexOf("<tbody")&&(e="table"),0===s.indexOf("<option")&&(e="select");const t=i.createElement(e);t.innerHTML=s;for(let e=0;e<t.childNodes.length;e+=1)l.push(t.childNodes[e])}else l=function(e,t){if("string"!=typeof e)return[e];const s=[],a=t.querySelectorAll(e);for(let e=0;e<a.length;e+=1)s.push(a[e]);return s}(e.trim(),t||i)}else if(e.nodeType||e===s||e===i)l.push(e);else if(Array.isArray(e)){if(e instanceof n)return e;l=e}return new n(function(e){const t=[];for(let s=0;s<e.length;s+=1)-1===t.indexOf(e[s])&&t.push(e[s]);return t}(l))}d.fn=n.prototype;const c={addClass:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];const a=l(t.map((e=>e.split(" "))));return this.forEach((e=>{e.classList.add(...a)})),this},removeClass:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];const a=l(t.map((e=>e.split(" "))));return this.forEach((e=>{e.classList.remove(...a)})),this},hasClass:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];const a=l(t.map((e=>e.split(" "))));return o(this,(e=>a.filter((t=>e.classList.contains(t))).length>0)).length>0},toggleClass:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];const a=l(t.map((e=>e.split(" "))));this.forEach((e=>{a.forEach((t=>{e.classList.toggle(t)}))}))},attr:function(e,t){if(1===arguments.length&&"string"==typeof e)return this[0]?this[0].getAttribute(e):void 0;for(let s=0;s<this.length;s+=1)if(2===arguments.length)this[s].setAttribute(e,t);else for(const t in e)this[s][t]=e[t],this[s].setAttribute(t,e[t]);return this},removeAttr:function(e){for(let t=0;t<this.length;t+=1)this[t].removeAttribute(e);return this},transform:function(e){for(let t=0;t<this.length;t+=1)this[t].style.transform=e;return this},transition:function(e){for(let t=0;t<this.length;t+=1)this[t].style.transitionDuration="string"!=typeof e?`${e}ms`:e;return this},on:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];let[a,i,r,n]=t;function l(e){const t=e.target;if(!t)return;const s=e.target.dom7EventData||[];if(s.indexOf(e)<0&&s.unshift(e),d(t).is(i))r.apply(t,s);else{const e=d(t).parents();for(let t=0;t<e.length;t+=1)d(e[t]).is(i)&&r.apply(e[t],s)}}function o(e){const t=e&&e.target&&e.target.dom7EventData||[];t.indexOf(e)<0&&t.unshift(e),r.apply(this,t)}"function"==typeof t[1]&&([a,r,n]=t,i=void 0),n||(n=!1);const c=a.split(" ");let p;for(let e=0;e<this.length;e+=1){const t=this[e];if(i)for(p=0;p<c.length;p+=1){const e=c[p];t.dom7LiveListeners||(t.dom7LiveListeners={}),t.dom7LiveListeners[e]||(t.dom7LiveListeners[e]=[]),t.dom7LiveListeners[e].push({listener:r,proxyListener:l}),t.addEventListener(e,l,n)}else for(p=0;p<c.length;p+=1){const e=c[p];t.dom7Listeners||(t.dom7Listeners={}),t.dom7Listeners[e]||(t.dom7Listeners[e]=[]),t.dom7Listeners[e].push({listener:r,proxyListener:o}),t.addEventListener(e,o,n)}}return this},off:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];let[a,i,r,n]=t;"function"==typeof t[1]&&([a,r,n]=t,i=void 0),n||(n=!1);const l=a.split(" ");for(let e=0;e<l.length;e+=1){const t=l[e];for(let e=0;e<this.length;e+=1){const s=this[e];let a;if(!i&&s.dom7Listeners?a=s.dom7Listeners[t]:i&&s.dom7LiveListeners&&(a=s.dom7LiveListeners[t]),a&&a.length)for(let e=a.length-1;e>=0;e-=1){const i=a[e];r&&i.listener===r||r&&i.listener&&i.listener.dom7proxy&&i.listener.dom7proxy===r?(s.removeEventListener(t,i.proxyListener,n),a.splice(e,1)):r||(s.removeEventListener(t,i.proxyListener,n),a.splice(e,1))}}}return this},trigger:function(){const e=r();for(var t=arguments.length,s=new Array(t),a=0;a<t;a++)s[a]=arguments[a];const i=s[0].split(" "),n=s[1];for(let t=0;t<i.length;t+=1){const a=i[t];for(let t=0;t<this.length;t+=1){const i=this[t];if(e.CustomEvent){const t=new e.CustomEvent(a,{detail:n,bubbles:!0,cancelable:!0});i.dom7EventData=s.filter(((e,t)=>t>0)),i.dispatchEvent(t),i.dom7EventData=[],delete i.dom7EventData}}}return this},transitionEnd:function(e){const t=this;return e&&t.on("transitionend",(function s(a){a.target===this&&(e.call(this,a),t.off("transitionend",s))})),this},outerWidth:function(e){if(this.length>0){if(e){const e=this.styles();return this[0].offsetWidth+parseFloat(e.getPropertyValue("margin-right"))+parseFloat(e.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(e){if(this.length>0){if(e){const e=this.styles();return this[0].offsetHeight+parseFloat(e.getPropertyValue("margin-top"))+parseFloat(e.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},styles:function(){const e=r();return this[0]?e.getComputedStyle(this[0],null):{}},offset:function(){if(this.length>0){const e=r(),t=a(),s=this[0],i=s.getBoundingClientRect(),n=t.body,l=s.clientTop||n.clientTop||0,o=s.clientLeft||n.clientLeft||0,d=s===e?e.scrollY:s.scrollTop,c=s===e?e.scrollX:s.scrollLeft;return{top:i.top+d-l,left:i.left+c-o}}return null},css:function(e,t){const s=r();let a;if(1===arguments.length){if("string"!=typeof e){for(a=0;a<this.length;a+=1)for(const t in e)this[a].style[t]=e[t];return this}if(this[0])return s.getComputedStyle(this[0],null).getPropertyValue(e)}if(2===arguments.length&&"string"==typeof e){for(a=0;a<this.length;a+=1)this[a].style[e]=t;return this}return this},each:function(e){return e?(this.forEach(((t,s)=>{e.apply(t,[t,s])})),this):this},html:function(e){if(void 0===e)return this[0]?this[0].innerHTML:null;for(let t=0;t<this.length;t+=1)this[t].innerHTML=e;return this},text:function(e){if(void 0===e)return this[0]?this[0].textContent.trim():null;for(let t=0;t<this.length;t+=1)this[t].textContent=e;return this},is:function(e){const t=r(),s=a(),i=this[0];let l,o;if(!i||void 0===e)return!1;if("string"==typeof e){if(i.matches)return i.matches(e);if(i.webkitMatchesSelector)return i.webkitMatchesSelector(e);if(i.msMatchesSelector)return i.msMatchesSelector(e);for(l=d(e),o=0;o<l.length;o+=1)if(l[o]===i)return!0;return!1}if(e===s)return i===s;if(e===t)return i===t;if(e.nodeType||e instanceof n){for(l=e.nodeType?[e]:e,o=0;o<l.length;o+=1)if(l[o]===i)return!0;return!1}return!1},index:function(){let e,t=this[0];if(t){for(e=0;null!==(t=t.previousSibling);)1===t.nodeType&&(e+=1);return e}},eq:function(e){if(void 0===e)return this;const t=this.length;if(e>t-1)return d([]);if(e<0){const s=t+e;return d(s<0?[]:[this[s]])}return d([this[e]])},append:function(){let e;const t=a();for(let s=0;s<arguments.length;s+=1){e=s<0||arguments.length<=s?void 0:arguments[s];for(let s=0;s<this.length;s+=1)if("string"==typeof e){const a=t.createElement("div");for(a.innerHTML=e;a.firstChild;)this[s].appendChild(a.firstChild)}else if(e instanceof n)for(let t=0;t<e.length;t+=1)this[s].appendChild(e[t]);else this[s].appendChild(e)}return this},prepend:function(e){const t=a();let s,i;for(s=0;s<this.length;s+=1)if("string"==typeof e){const a=t.createElement("div");for(a.innerHTML=e,i=a.childNodes.length-1;i>=0;i-=1)this[s].insertBefore(a.childNodes[i],this[s].childNodes[0])}else if(e instanceof n)for(i=0;i<e.length;i+=1)this[s].insertBefore(e[i],this[s].childNodes[0]);else this[s].insertBefore(e,this[s].childNodes[0]);return this},next:function(e){return this.length>0?e?this[0].nextElementSibling&&d(this[0].nextElementSibling).is(e)?d([this[0].nextElementSibling]):d([]):this[0].nextElementSibling?d([this[0].nextElementSibling]):d([]):d([])},nextAll:function(e){const t=[];let s=this[0];if(!s)return d([]);for(;s.nextElementSibling;){const a=s.nextElementSibling;e?d(a).is(e)&&t.push(a):t.push(a),s=a}return d(t)},prev:function(e){if(this.length>0){const t=this[0];return e?t.previousElementSibling&&d(t.previousElementSibling).is(e)?d([t.previousElementSibling]):d([]):t.previousElementSibling?d([t.previousElementSibling]):d([])}return d([])},prevAll:function(e){const t=[];let s=this[0];if(!s)return d([]);for(;s.previousElementSibling;){const a=s.previousElementSibling;e?d(a).is(e)&&t.push(a):t.push(a),s=a}return d(t)},parent:function(e){const t=[];for(let s=0;s<this.length;s+=1)null!==this[s].parentNode&&(e?d(this[s].parentNode).is(e)&&t.push(this[s].parentNode):t.push(this[s].parentNode));return d(t)},parents:function(e){const t=[];for(let s=0;s<this.length;s+=1){let a=this[s].parentNode;for(;a;)e?d(a).is(e)&&t.push(a):t.push(a),a=a.parentNode}return d(t)},closest:function(e){let t=this;return void 0===e?d([]):(t.is(e)||(t=t.parents(e).eq(0)),t)},find:function(e){const t=[];for(let s=0;s<this.length;s+=1){const a=this[s].querySelectorAll(e);for(let e=0;e<a.length;e+=1)t.push(a[e])}return d(t)},children:function(e){const t=[];for(let s=0;s<this.length;s+=1){const a=this[s].children;for(let s=0;s<a.length;s+=1)e&&!d(a[s]).is(e)||t.push(a[s])}return d(t)},filter:function(e){return d(o(this,e))},remove:function(){for(let e=0;e<this.length;e+=1)this[e].parentNode&&this[e].parentNode.removeChild(this[e]);return this}};function p(e,t){return void 0===t&&(t=0),setTimeout(e,t)}function u(){return Date.now()}function h(e,t){void 0===t&&(t="x");const s=r();let a,i,n;const l=function(e){const t=r();let s;return t.getComputedStyle&&(s=t.getComputedStyle(e,null)),!s&&e.currentStyle&&(s=e.currentStyle),s||(s=e.style),s}(e);return s.WebKitCSSMatrix?(i=l.transform||l.webkitTransform,i.split(",").length>6&&(i=i.split(", ").map((e=>e.replace(",","."))).join(", ")),n=new s.WebKitCSSMatrix("none"===i?"":i)):(n=l.MozTransform||l.OTransform||l.MsTransform||l.msTransform||l.transform||l.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),a=n.toString().split(",")),"x"===t&&(i=s.WebKitCSSMatrix?n.m41:16===a.length?parseFloat(a[12]):parseFloat(a[4])),"y"===t&&(i=s.WebKitCSSMatrix?n.m42:16===a.length?parseFloat(a[13]):parseFloat(a[5])),i||0}function m(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)}function f(e){return"undefined"!=typeof window&&void 0!==window.HTMLElement?e instanceof HTMLElement:e&&(1===e.nodeType||11===e.nodeType)}function g(){const e=Object(arguments.length<=0?void 0:arguments[0]),t=["__proto__","constructor","prototype"];for(let s=1;s<arguments.length;s+=1){const a=s<0||arguments.length<=s?void 0:arguments[s];if(null!=a&&!f(a)){const s=Object.keys(Object(a)).filter((e=>t.indexOf(e)<0));for(let t=0,i=s.length;t<i;t+=1){const i=s[t],r=Object.getOwnPropertyDescriptor(a,i);void 0!==r&&r.enumerable&&(m(e[i])&&m(a[i])?a[i].__swiper__?e[i]=a[i]:g(e[i],a[i]):!m(e[i])&&m(a[i])?(e[i]={},a[i].__swiper__?e[i]=a[i]:g(e[i],a[i])):e[i]=a[i])}}}return e}function v(e,t,s){e.style.setProperty(t,s)}function w(e){let{swiper:t,targetPosition:s,side:a}=e;const i=r(),n=-t.translate;let l,o=null;const d=t.params.speed;t.wrapperEl.style.scrollSnapType="none",i.cancelAnimationFrame(t.cssModeFrameID);const c=s>n?"next":"prev",p=(e,t)=>"next"===c&&e>=t||"prev"===c&&e<=t,u=()=>{l=(new Date).getTime(),null===o&&(o=l);const e=Math.max(Math.min((l-o)/d,1),0),r=.5-Math.cos(e*Math.PI)/2;let c=n+r*(s-n);if(p(c,s)&&(c=s),t.wrapperEl.scrollTo({[a]:c}),p(c,s))return t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.scrollSnapType="",setTimeout((()=>{t.wrapperEl.style.overflow="",t.wrapperEl.scrollTo({[a]:c})})),void i.cancelAnimationFrame(t.cssModeFrameID);t.cssModeFrameID=i.requestAnimationFrame(u)};u()}let b,x,y;function E(){return b||(b=function(){const e=r(),t=a();return{smoothScroll:t.documentElement&&"scrollBehavior"in t.documentElement.style,touch:!!("ontouchstart"in e||e.DocumentTouch&&t instanceof e.DocumentTouch),passiveListener:function(){let t=!1;try{const s=Object.defineProperty({},"passive",{get(){t=!0}});e.addEventListener("testPassiveListener",null,s)}catch(e){}return t}(),gestures:"ongesturestart"in e}}()),b}function C(e){return void 0===e&&(e={}),x||(x=function(e){let{userAgent:t}=void 0===e?{}:e;const s=E(),a=r(),i=a.navigator.platform,n=t||a.navigator.userAgent,l={ios:!1,android:!1},o=a.screen.width,d=a.screen.height,c=n.match(/(Android);?[\s\/]+([\d.]+)?/);let p=n.match(/(iPad).*OS\s([\d_]+)/);const u=n.match(/(iPod)(.*OS\s([\d_]+))?/),h=!p&&n.match(/(iPhone\sOS|iOS)\s([\d_]+)/),m="Win32"===i;let f="MacIntel"===i;return!p&&f&&s.touch&&["1024x1366","1366x1024","834x1194","1194x834","834x1112","1112x834","768x1024","1024x768","820x1180","1180x820","810x1080","1080x810"].indexOf(`${o}x${d}`)>=0&&(p=n.match(/(Version)\/([\d.]+)/),p||(p=[0,1,"13_0_0"]),f=!1),c&&!m&&(l.os="android",l.android=!0),(p||h||u)&&(l.os="ios",l.ios=!0),l}(e)),x}function T(){return y||(y=function(){const e=r();return{isSafari:function(){const t=e.navigator.userAgent.toLowerCase();return t.indexOf("safari")>=0&&t.indexOf("chrome")<0&&t.indexOf("android")<0}(),isWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(e.navigator.userAgent)}}()),y}Object.keys(c).forEach((e=>{Object.defineProperty(d.fn,e,{value:c[e],writable:!0})}));var $={on(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;const i=s?"unshift":"push";return e.split(" ").forEach((e=>{a.eventsListeners[e]||(a.eventsListeners[e]=[]),a.eventsListeners[e][i](t)})),a},once(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;function i(){a.off(e,i),i.__emitterProxy&&delete i.__emitterProxy;for(var s=arguments.length,r=new Array(s),n=0;n<s;n++)r[n]=arguments[n];t.apply(a,r)}return i.__emitterProxy=t,a.on(e,i,s)},onAny(e,t){const s=this;if(!s.eventsListeners||s.destroyed)return s;if("function"!=typeof e)return s;const a=t?"unshift":"push";return s.eventsAnyListeners.indexOf(e)<0&&s.eventsAnyListeners[a](e),s},offAny(e){const t=this;if(!t.eventsListeners||t.destroyed)return t;if(!t.eventsAnyListeners)return t;const s=t.eventsAnyListeners.indexOf(e);return s>=0&&t.eventsAnyListeners.splice(s,1),t},off(e,t){const s=this;return!s.eventsListeners||s.destroyed?s:s.eventsListeners?(e.split(" ").forEach((e=>{void 0===t?s.eventsListeners[e]=[]:s.eventsListeners[e]&&s.eventsListeners[e].forEach(((a,i)=>{(a===t||a.__emitterProxy&&a.__emitterProxy===t)&&s.eventsListeners[e].splice(i,1)}))})),s):s},emit(){const e=this;if(!e.eventsListeners||e.destroyed)return e;if(!e.eventsListeners)return e;let t,s,a;for(var i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];"string"==typeof r[0]||Array.isArray(r[0])?(t=r[0],s=r.slice(1,r.length),a=e):(t=r[0].events,s=r[0].data,a=r[0].context||e),s.unshift(a);return(Array.isArray(t)?t:t.split(" ")).forEach((t=>{e.eventsAnyListeners&&e.eventsAnyListeners.length&&e.eventsAnyListeners.forEach((e=>{e.apply(a,[t,...s])})),e.eventsListeners&&e.eventsListeners[t]&&e.eventsListeners[t].forEach((e=>{e.apply(a,s)}))})),e}};var S={updateSize:function(){const e=this;let t,s;const a=e.$el;t=void 0!==e.params.width&&null!==e.params.width?e.params.width:a[0].clientWidth,s=void 0!==e.params.height&&null!==e.params.height?e.params.height:a[0].clientHeight,0===t&&e.isHorizontal()||0===s&&e.isVertical()||(t=t-parseInt(a.css("padding-left")||0,10)-parseInt(a.css("padding-right")||0,10),s=s-parseInt(a.css("padding-top")||0,10)-parseInt(a.css("padding-bottom")||0,10),Number.isNaN(t)&&(t=0),Number.isNaN(s)&&(s=0),Object.assign(e,{width:t,height:s,size:e.isHorizontal()?t:s}))},updateSlides:function(){const e=this;function t(t){return e.isHorizontal()?t:{width:"height","margin-top":"margin-left","margin-bottom ":"margin-right","margin-left":"margin-top","margin-right":"margin-bottom","padding-left":"padding-top","padding-right":"padding-bottom",marginRight:"marginBottom"}[t]}function s(e,s){return parseFloat(e.getPropertyValue(t(s))||0)}const a=e.params,{$wrapperEl:i,size:r,rtlTranslate:n,wrongRTL:l}=e,o=e.virtual&&a.virtual.enabled,d=o?e.virtual.slides.length:e.slides.length,c=i.children(`.${e.params.slideClass}`),p=o?e.virtual.slides.length:c.length;let u=[];const h=[],m=[];let f=a.slidesOffsetBefore;"function"==typeof f&&(f=a.slidesOffsetBefore.call(e));let g=a.slidesOffsetAfter;"function"==typeof g&&(g=a.slidesOffsetAfter.call(e));const w=e.snapGrid.length,b=e.slidesGrid.length;let x=a.spaceBetween,y=-f,E=0,C=0;if(void 0===r)return;"string"==typeof x&&x.indexOf("%")>=0&&(x=parseFloat(x.replace("%",""))/100*r),e.virtualSize=-x,n?c.css({marginLeft:"",marginBottom:"",marginTop:""}):c.css({marginRight:"",marginBottom:"",marginTop:""}),a.centeredSlides&&a.cssMode&&(v(e.wrapperEl,"--swiper-centered-offset-before",""),v(e.wrapperEl,"--swiper-centered-offset-after",""));const T=a.grid&&a.grid.rows>1&&e.grid;let $;T&&e.grid.initSlides(p);const S="auto"===a.slidesPerView&&a.breakpoints&&Object.keys(a.breakpoints).filter((e=>void 0!==a.breakpoints[e].slidesPerView)).length>0;for(let i=0;i<p;i+=1){$=0;const n=c.eq(i);if(T&&e.grid.updateSlide(i,n,p,t),"none"!==n.css("display")){if("auto"===a.slidesPerView){S&&(c[i].style[t("width")]="");const r=getComputedStyle(n[0]),l=n[0].style.transform,o=n[0].style.webkitTransform;if(l&&(n[0].style.transform="none"),o&&(n[0].style.webkitTransform="none"),a.roundLengths)$=e.isHorizontal()?n.outerWidth(!0):n.outerHeight(!0);else{const e=s(r,"width"),t=s(r,"padding-left"),a=s(r,"padding-right"),i=s(r,"margin-left"),l=s(r,"margin-right"),o=r.getPropertyValue("box-sizing");if(o&&"border-box"===o)$=e+i+l;else{const{clientWidth:s,offsetWidth:r}=n[0];$=e+t+a+i+l+(r-s)}}l&&(n[0].style.transform=l),o&&(n[0].style.webkitTransform=o),a.roundLengths&&($=Math.floor($))}else $=(r-(a.slidesPerView-1)*x)/a.slidesPerView,a.roundLengths&&($=Math.floor($)),c[i]&&(c[i].style[t("width")]=`${$}px`);c[i]&&(c[i].swiperSlideSize=$),m.push($),a.centeredSlides?(y=y+$/2+E/2+x,0===E&&0!==i&&(y=y-r/2-x),0===i&&(y=y-r/2-x),Math.abs(y)<.001&&(y=0),a.roundLengths&&(y=Math.floor(y)),C%a.slidesPerGroup==0&&u.push(y),h.push(y)):(a.roundLengths&&(y=Math.floor(y)),(C-Math.min(e.params.slidesPerGroupSkip,C))%e.params.slidesPerGroup==0&&u.push(y),h.push(y),y=y+$+x),e.virtualSize+=$+x,E=$,C+=1}}if(e.virtualSize=Math.max(e.virtualSize,r)+g,n&&l&&("slide"===a.effect||"coverflow"===a.effect)&&i.css({width:`${e.virtualSize+a.spaceBetween}px`}),a.setWrapperSize&&i.css({[t("width")]:`${e.virtualSize+a.spaceBetween}px`}),T&&e.grid.updateWrapperSize($,u,t),!a.centeredSlides){const t=[];for(let s=0;s<u.length;s+=1){let i=u[s];a.roundLengths&&(i=Math.floor(i)),u[s]<=e.virtualSize-r&&t.push(i)}u=t,Math.floor(e.virtualSize-r)-Math.floor(u[u.length-1])>1&&u.push(e.virtualSize-r)}if(0===u.length&&(u=[0]),0!==a.spaceBetween){const s=e.isHorizontal()&&n?"marginLeft":t("marginRight");c.filter(((e,t)=>!a.cssMode||t!==c.length-1)).css({[s]:`${x}px`})}if(a.centeredSlides&&a.centeredSlidesBounds){let e=0;m.forEach((t=>{e+=t+(a.spaceBetween?a.spaceBetween:0)})),e-=a.spaceBetween;const t=e-r;u=u.map((e=>e<0?-f:e>t?t+g:e))}if(a.centerInsufficientSlides){let e=0;if(m.forEach((t=>{e+=t+(a.spaceBetween?a.spaceBetween:0)})),e-=a.spaceBetween,e<r){const t=(r-e)/2;u.forEach(((e,s)=>{u[s]=e-t})),h.forEach(((e,s)=>{h[s]=e+t}))}}if(Object.assign(e,{slides:c,snapGrid:u,slidesGrid:h,slidesSizesGrid:m}),a.centeredSlides&&a.cssMode&&!a.centeredSlidesBounds){v(e.wrapperEl,"--swiper-centered-offset-before",-u[0]+"px"),v(e.wrapperEl,"--swiper-centered-offset-after",e.size/2-m[m.length-1]/2+"px");const t=-e.snapGrid[0],s=-e.slidesGrid[0];e.snapGrid=e.snapGrid.map((e=>e+t)),e.slidesGrid=e.slidesGrid.map((e=>e+s))}if(p!==d&&e.emit("slidesLengthChange"),u.length!==w&&(e.params.watchOverflow&&e.checkOverflow(),e.emit("snapGridLengthChange")),h.length!==b&&e.emit("slidesGridLengthChange"),a.watchSlidesProgress&&e.updateSlidesOffset(),!(o||a.cssMode||"slide"!==a.effect&&"fade"!==a.effect)){const t=`${a.containerModifierClass}backface-hidden`,s=e.$el.hasClass(t);p<=a.maxBackfaceHiddenSlides?s||e.$el.addClass(t):s&&e.$el.removeClass(t)}},updateAutoHeight:function(e){const t=this,s=[],a=t.virtual&&t.params.virtual.enabled;let i,r=0;"number"==typeof e?t.setTransition(e):!0===e&&t.setTransition(t.params.speed);const n=e=>a?t.slides.filter((t=>parseInt(t.getAttribute("data-swiper-slide-index"),10)===e))[0]:t.slides.eq(e)[0];if("auto"!==t.params.slidesPerView&&t.params.slidesPerView>1)if(t.params.centeredSlides)(t.visibleSlides||d([])).each((e=>{s.push(e)}));else for(i=0;i<Math.ceil(t.params.slidesPerView);i+=1){const e=t.activeIndex+i;if(e>t.slides.length&&!a)break;s.push(n(e))}else s.push(n(t.activeIndex));for(i=0;i<s.length;i+=1)if(void 0!==s[i]){const e=s[i].offsetHeight;r=e>r?e:r}(r||0===r)&&t.$wrapperEl.css("height",`${r}px`)},updateSlidesOffset:function(){const e=this,t=e.slides;for(let s=0;s<t.length;s+=1)t[s].swiperSlideOffset=e.isHorizontal()?t[s].offsetLeft:t[s].offsetTop},updateSlidesProgress:function(e){void 0===e&&(e=this&&this.translate||0);const t=this,s=t.params,{slides:a,rtlTranslate:i,snapGrid:r}=t;if(0===a.length)return;void 0===a[0].swiperSlideOffset&&t.updateSlidesOffset();let n=-e;i&&(n=e),a.removeClass(s.slideVisibleClass),t.visibleSlidesIndexes=[],t.visibleSlides=[];for(let e=0;e<a.length;e+=1){const l=a[e];let o=l.swiperSlideOffset;s.cssMode&&s.centeredSlides&&(o-=a[0].swiperSlideOffset);const d=(n+(s.centeredSlides?t.minTranslate():0)-o)/(l.swiperSlideSize+s.spaceBetween),c=(n-r[0]+(s.centeredSlides?t.minTranslate():0)-o)/(l.swiperSlideSize+s.spaceBetween),p=-(n-o),u=p+t.slidesSizesGrid[e];(p>=0&&p<t.size-1||u>1&&u<=t.size||p<=0&&u>=t.size)&&(t.visibleSlides.push(l),t.visibleSlidesIndexes.push(e),a.eq(e).addClass(s.slideVisibleClass)),l.progress=i?-d:d,l.originalProgress=i?-c:c}t.visibleSlides=d(t.visibleSlides)},updateProgress:function(e){const t=this;if(void 0===e){const s=t.rtlTranslate?-1:1;e=t&&t.translate&&t.translate*s||0}const s=t.params,a=t.maxTranslate()-t.minTranslate();let{progress:i,isBeginning:r,isEnd:n}=t;const l=r,o=n;0===a?(i=0,r=!0,n=!0):(i=(e-t.minTranslate())/a,r=i<=0,n=i>=1),Object.assign(t,{progress:i,isBeginning:r,isEnd:n}),(s.watchSlidesProgress||s.centeredSlides&&s.autoHeight)&&t.updateSlidesProgress(e),r&&!l&&t.emit("reachBeginning toEdge"),n&&!o&&t.emit("reachEnd toEdge"),(l&&!r||o&&!n)&&t.emit("fromEdge"),t.emit("progress",i)},updateSlidesClasses:function(){const e=this,{slides:t,params:s,$wrapperEl:a,activeIndex:i,realIndex:r}=e,n=e.virtual&&s.virtual.enabled;let l;t.removeClass(`${s.slideActiveClass} ${s.slideNextClass} ${s.slidePrevClass} ${s.slideDuplicateActiveClass} ${s.slideDuplicateNextClass} ${s.slideDuplicatePrevClass}`),l=n?e.$wrapperEl.find(`.${s.slideClass}[data-swiper-slide-index="${i}"]`):t.eq(i),l.addClass(s.slideActiveClass),s.loop&&(l.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass));let o=l.nextAll(`.${s.slideClass}`).eq(0).addClass(s.slideNextClass);s.loop&&0===o.length&&(o=t.eq(0),o.addClass(s.slideNextClass));let d=l.prevAll(`.${s.slideClass}`).eq(0).addClass(s.slidePrevClass);s.loop&&0===d.length&&(d=t.eq(-1),d.addClass(s.slidePrevClass)),s.loop&&(o.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${o.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${o.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass),d.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${d.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${d.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass)),e.emitSlidesClasses()},updateActiveIndex:function(e){const t=this,s=t.rtlTranslate?t.translate:-t.translate,{slidesGrid:a,snapGrid:i,params:r,activeIndex:n,realIndex:l,snapIndex:o}=t;let d,c=e;if(void 0===c){for(let e=0;e<a.length;e+=1)void 0!==a[e+1]?s>=a[e]&&s<a[e+1]-(a[e+1]-a[e])/2?c=e:s>=a[e]&&s<a[e+1]&&(c=e+1):s>=a[e]&&(c=e);r.normalizeSlideIndex&&(c<0||void 0===c)&&(c=0)}if(i.indexOf(s)>=0)d=i.indexOf(s);else{const e=Math.min(r.slidesPerGroupSkip,c);d=e+Math.floor((c-e)/r.slidesPerGroup)}if(d>=i.length&&(d=i.length-1),c===n)return void(d!==o&&(t.snapIndex=d,t.emit("snapIndexChange")));const p=parseInt(t.slides.eq(c).attr("data-swiper-slide-index")||c,10);Object.assign(t,{snapIndex:d,realIndex:p,previousIndex:n,activeIndex:c}),t.emit("activeIndexChange"),t.emit("snapIndexChange"),l!==p&&t.emit("realIndexChange"),(t.initialized||t.params.runCallbacksOnInit)&&t.emit("slideChange")},updateClickedSlide:function(e){const t=this,s=t.params,a=d(e).closest(`.${s.slideClass}`)[0];let i,r=!1;if(a)for(let e=0;e<t.slides.length;e+=1)if(t.slides[e]===a){r=!0,i=e;break}if(!a||!r)return t.clickedSlide=void 0,void(t.clickedIndex=void 0);t.clickedSlide=a,t.virtual&&t.params.virtual.enabled?t.clickedIndex=parseInt(d(a).attr("data-swiper-slide-index"),10):t.clickedIndex=i,s.slideToClickedSlide&&void 0!==t.clickedIndex&&t.clickedIndex!==t.activeIndex&&t.slideToClickedSlide()}};var M={getTranslate:function(e){void 0===e&&(e=this.isHorizontal()?"x":"y");const{params:t,rtlTranslate:s,translate:a,$wrapperEl:i}=this;if(t.virtualTranslate)return s?-a:a;if(t.cssMode)return a;let r=h(i[0],e);return s&&(r=-r),r||0},setTranslate:function(e,t){const s=this,{rtlTranslate:a,params:i,$wrapperEl:r,wrapperEl:n,progress:l}=s;let o,d=0,c=0;s.isHorizontal()?d=a?-e:e:c=e,i.roundLengths&&(d=Math.floor(d),c=Math.floor(c)),i.cssMode?n[s.isHorizontal()?"scrollLeft":"scrollTop"]=s.isHorizontal()?-d:-c:i.virtualTranslate||r.transform(`translate3d(${d}px, ${c}px, 0px)`),s.previousTranslate=s.translate,s.translate=s.isHorizontal()?d:c;const p=s.maxTranslate()-s.minTranslate();o=0===p?0:(e-s.minTranslate())/p,o!==l&&s.updateProgress(e),s.emit("setTranslate",s.translate,t)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]},translateTo:function(e,t,s,a,i){void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),void 0===a&&(a=!0);const r=this,{params:n,wrapperEl:l}=r;if(r.animating&&n.preventInteractionOnTransition)return!1;const o=r.minTranslate(),d=r.maxTranslate();let c;if(c=a&&e>o?o:a&&e<d?d:e,r.updateProgress(c),n.cssMode){const e=r.isHorizontal();if(0===t)l[e?"scrollLeft":"scrollTop"]=-c;else{if(!r.support.smoothScroll)return w({swiper:r,targetPosition:-c,side:e?"left":"top"}),!0;l.scrollTo({[e?"left":"top"]:-c,behavior:"smooth"})}return!0}return 0===t?(r.setTransition(0),r.setTranslate(c),s&&(r.emit("beforeTransitionStart",t,i),r.emit("transitionEnd"))):(r.setTransition(t),r.setTranslate(c),s&&(r.emit("beforeTransitionStart",t,i),r.emit("transitionStart")),r.animating||(r.animating=!0,r.onTranslateToWrapperTransitionEnd||(r.onTranslateToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.$wrapperEl[0].removeEventListener("transitionend",r.onTranslateToWrapperTransitionEnd),r.$wrapperEl[0].removeEventListener("webkitTransitionEnd",r.onTranslateToWrapperTransitionEnd),r.onTranslateToWrapperTransitionEnd=null,delete r.onTranslateToWrapperTransitionEnd,s&&r.emit("transitionEnd"))}),r.$wrapperEl[0].addEventListener("transitionend",r.onTranslateToWrapperTransitionEnd),r.$wrapperEl[0].addEventListener("webkitTransitionEnd",r.onTranslateToWrapperTransitionEnd))),!0}};function P(e){let{swiper:t,runCallbacks:s,direction:a,step:i}=e;const{activeIndex:r,previousIndex:n}=t;let l=a;if(l||(l=r>n?"next":r<n?"prev":"reset"),t.emit(`transition${i}`),s&&r!==n){if("reset"===l)return void t.emit(`slideResetTransition${i}`);t.emit(`slideChangeTransition${i}`),"next"===l?t.emit(`slideNextTransition${i}`):t.emit(`slidePrevTransition${i}`)}}var k={slideTo:function(e,t,s,a,i){if(void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),"number"!=typeof e&&"string"!=typeof e)throw new Error(`The 'index' argument cannot have type other than 'number' or 'string'. [${typeof e}] given.`);if("string"==typeof e){const t=parseInt(e,10);if(!isFinite(t))throw new Error(`The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`);e=t}const r=this;let n=e;n<0&&(n=0);const{params:l,snapGrid:o,slidesGrid:d,previousIndex:c,activeIndex:p,rtlTranslate:u,wrapperEl:h,enabled:m}=r;if(r.animating&&l.preventInteractionOnTransition||!m&&!a&&!i)return!1;const f=Math.min(r.params.slidesPerGroupSkip,n);let g=f+Math.floor((n-f)/r.params.slidesPerGroup);g>=o.length&&(g=o.length-1);const v=-o[g];if(l.normalizeSlideIndex)for(let e=0;e<d.length;e+=1){const t=-Math.floor(100*v),s=Math.floor(100*d[e]),a=Math.floor(100*d[e+1]);void 0!==d[e+1]?t>=s&&t<a-(a-s)/2?n=e:t>=s&&t<a&&(n=e+1):t>=s&&(n=e)}if(r.initialized&&n!==p){if(!r.allowSlideNext&&v<r.translate&&v<r.minTranslate())return!1;if(!r.allowSlidePrev&&v>r.translate&&v>r.maxTranslate()&&(p||0)!==n)return!1}let b;if(n!==(c||0)&&s&&r.emit("beforeSlideChangeStart"),r.updateProgress(v),b=n>p?"next":n<p?"prev":"reset",u&&-v===r.translate||!u&&v===r.translate)return r.updateActiveIndex(n),l.autoHeight&&r.updateAutoHeight(),r.updateSlidesClasses(),"slide"!==l.effect&&r.setTranslate(v),"reset"!==b&&(r.transitionStart(s,b),r.transitionEnd(s,b)),!1;if(l.cssMode){const e=r.isHorizontal(),s=u?v:-v;if(0===t){const t=r.virtual&&r.params.virtual.enabled;t&&(r.wrapperEl.style.scrollSnapType="none",r._immediateVirtual=!0),h[e?"scrollLeft":"scrollTop"]=s,t&&requestAnimationFrame((()=>{r.wrapperEl.style.scrollSnapType="",r._swiperImmediateVirtual=!1}))}else{if(!r.support.smoothScroll)return w({swiper:r,targetPosition:s,side:e?"left":"top"}),!0;h.scrollTo({[e?"left":"top"]:s,behavior:"smooth"})}return!0}return r.setTransition(t),r.setTranslate(v),r.updateActiveIndex(n),r.updateSlidesClasses(),r.emit("beforeTransitionStart",t,a),r.transitionStart(s,b),0===t?r.transitionEnd(s,b):r.animating||(r.animating=!0,r.onSlideToWrapperTransitionEnd||(r.onSlideToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.$wrapperEl[0].removeEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].removeEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd),r.onSlideToWrapperTransitionEnd=null,delete r.onSlideToWrapperTransitionEnd,r.transitionEnd(s,b))}),r.$wrapperEl[0].addEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].addEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd)),!0},slideToLoop:function(e,t,s,a){if(void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),"string"==typeof e){const t=parseInt(e,10);if(!isFinite(t))throw new Error(`The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`);e=t}const i=this;let r=e;return i.params.loop&&(r+=i.loopedSlides),i.slideTo(r,t,s,a)},slideNext:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this,{animating:i,enabled:r,params:n}=a;if(!r)return a;let l=n.slidesPerGroup;"auto"===n.slidesPerView&&1===n.slidesPerGroup&&n.slidesPerGroupAuto&&(l=Math.max(a.slidesPerViewDynamic("current",!0),1));const o=a.activeIndex<n.slidesPerGroupSkip?1:l;if(n.loop){if(i&&n.loopPreventsSlide)return!1;a.loopFix(),a._clientLeft=a.$wrapperEl[0].clientLeft}return n.rewind&&a.isEnd?a.slideTo(0,e,t,s):a.slideTo(a.activeIndex+o,e,t,s)},slidePrev:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this,{params:i,animating:r,snapGrid:n,slidesGrid:l,rtlTranslate:o,enabled:d}=a;if(!d)return a;if(i.loop){if(r&&i.loopPreventsSlide)return!1;a.loopFix(),a._clientLeft=a.$wrapperEl[0].clientLeft}function c(e){return e<0?-Math.floor(Math.abs(e)):Math.floor(e)}const p=c(o?a.translate:-a.translate),u=n.map((e=>c(e)));let h=n[u.indexOf(p)-1];if(void 0===h&&i.cssMode){let e;
vendor: 8,012 bytes, line 45
45n.forEach(((t,s)=>{p>=t&&(e=s)})),void 0!==e&&(h=n[e>0?e-1:e])}let m=0;if(void 0!==h&&(m=l.indexOf(h),m<0&&(m=a.activeIndex-1),"auto"===i.slidesPerView&&1===i.slidesPerGroup&&i.slidesPerGroupAuto&&(m=m-a.slidesPerViewDynamic("previous",!0)+1,m=Math.max(m,0))),i.rewind&&a.isBeginning){const i=a.params.virtual&&a.params.virtual.enabled&&a.virtual?a.virtual.slides.length-1:a.slides.length-1;return a.slideTo(i,e,t,s)}return a.slideTo(m,e,t,s)},slideReset:function(e,t,s){return void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),this.slideTo(this.activeIndex,e,t,s)},slideToClosest:function(e,t,s,a){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),void 0===a&&(a=.5);const i=this;let r=i.activeIndex;const n=Math.min(i.params.slidesPerGroupSkip,r),l=n+Math.floor((r-n)/i.params.slidesPerGroup),o=i.rtlTranslate?i.translate:-i.translate;if(o>=i.snapGrid[l]){const e=i.snapGrid[l];o-e>(i.snapGrid[l+1]-e)*a&&(r+=i.params.slidesPerGroup)}else{const e=i.snapGrid[l-1];o-e<=(i.snapGrid[l]-e)*a&&(r-=i.params.slidesPerGroup)}return r=Math.max(r,0),r=Math.min(r,i.slidesGrid.length-1),i.slideTo(r,e,t,s)},slideToClickedSlide:function(){const e=this,{params:t,$wrapperEl:s}=e,a="auto"===t.slidesPerView?e.slidesPerViewDynamic():t.slidesPerView;let i,r=e.clickedIndex;if(t.loop){if(e.animating)return;i=parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"),10),t.centeredSlides?r<e.loopedSlides-a/2||r>e.slides.length-e.loopedSlides+a/2?(e.loopFix(),r=s.children(`.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`).eq(0).index(),p((()=>{e.slideTo(r)}))):e.slideTo(r):r>e.slides.length-a?(e.loopFix(),r=s.children(`.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`).eq(0).index(),p((()=>{e.slideTo(r)}))):e.slideTo(r)}else e.slideTo(r)}};var z={loopCreate:function(){const e=this,t=a(),{params:s,$wrapperEl:i}=e,r=i.children().length>0?d(i.children()[0].parentNode):i;r.children(`.${s.slideClass}.${s.slideDuplicateClass}`).remove();let n=r.children(`.${s.slideClass}`);if(s.loopFillGroupWithBlank){const e=s.slidesPerGroup-n.length%s.slidesPerGroup;if(e!==s.slidesPerGroup){for(let a=0;a<e;a+=1){const e=d(t.createElement("div")).addClass(`${s.slideClass} ${s.slideBlankClass}`);r.append(e)}n=r.children(`.${s.slideClass}`)}}"auto"!==s.slidesPerView||s.loopedSlides||(s.loopedSlides=n.length),e.loopedSlides=Math.ceil(parseFloat(s.loopedSlides||s.slidesPerView,10)),e.loopedSlides+=s.loopAdditionalSlides,e.loopedSlides>n.length&&e.params.loopedSlidesLimit&&(e.loopedSlides=n.length);const l=[],o=[];n.each(((e,t)=>{d(e).attr("data-swiper-slide-index",t)}));for(let t=0;t<e.loopedSlides;t+=1){const e=t-Math.floor(t/n.length)*n.length;o.push(n.eq(e)[0]),l.unshift(n.eq(n.length-e-1)[0])}for(let e=0;e<o.length;e+=1)r.append(d(o[e].cloneNode(!0)).addClass(s.slideDuplicateClass));for(let e=l.length-1;e>=0;e-=1)r.prepend(d(l[e].cloneNode(!0)).addClass(s.slideDuplicateClass))},loopFix:function(){const e=this;e.emit("beforeLoopFix");const{activeIndex:t,slides:s,loopedSlides:a,allowSlidePrev:i,allowSlideNext:r,snapGrid:n,rtlTranslate:l}=e;let o;e.allowSlidePrev=!0,e.allowSlideNext=!0;const d=-n[t]-e.getTranslate();if(t<a){o=s.length-3*a+t,o+=a;e.slideTo(o,0,!1,!0)&&0!==d&&e.setTranslate((l?-e.translate:e.translate)-d)}else if(t>=s.length-a){o=-s.length+t+a,o+=a;e.slideTo(o,0,!1,!0)&&0!==d&&e.setTranslate((l?-e.translate:e.translate)-d)}e.allowSlidePrev=i,e.allowSlideNext=r,e.emit("loopFix")},loopDestroy:function(){const{$wrapperEl:e,params:t,slides:s}=this;e.children(`.${t.slideClass}.${t.slideDuplicateClass},.${t.slideClass}.${t.slideBlankClass}`).remove(),s.removeAttr("data-swiper-slide-index")}};function L(e){const t=this,s=a(),i=r(),n=t.touchEventsData,{params:l,touches:o,enabled:c}=t;if(!c)return;if(t.animating&&l.preventInteractionOnTransition)return;!t.animating&&l.cssMode&&l.loop&&t.loopFix();let p=e;p.originalEvent&&(p=p.originalEvent);let h=d(p.target);if("wrapper"===l.touchEventsTarget&&!h.closest(t.wrapperEl).length)return;if(n.isTouchEvent="touchstart"===p.type,!n.isTouchEvent&&"which"in p&&3===p.which)return;if(!n.isTouchEvent&&"button"in p&&p.button>0)return;if(n.isTouched&&n.isMoved)return;const m=!!l.noSwipingClass&&""!==l.noSwipingClass,f=e.composedPath?e.composedPath():e.path;m&&p.target&&p.target.shadowRoot&&f&&(h=d(f[0]));const g=l.noSwipingSelector?l.noSwipingSelector:`.${l.noSwipingClass}`,v=!(!p.target||!p.target.shadowRoot);if(l.noSwiping&&(v?function(e,t){return void 0===t&&(t=this),function t(s){if(!s||s===a()||s===r())return null;s.assignedSlot&&(s=s.assignedSlot);const i=s.closest(e);return i||s.getRootNode?i||t(s.getRootNode().host):null}(t)}(g,h[0]):h.closest(g)[0]))return void(t.allowClick=!0);if(l.swipeHandler&&!h.closest(l.swipeHandler)[0])return;o.currentX="touchstart"===p.type?p.targetTouches[0].pageX:p.pageX,o.currentY="touchstart"===p.type?p.targetTouches[0].pageY:p.pageY;const w=o.currentX,b=o.currentY,x=l.edgeSwipeDetection||l.iOSEdgeSwipeDetection,y=l.edgeSwipeThreshold||l.iOSEdgeSwipeThreshold;if(x&&(w<=y||w>=i.innerWidth-y)){if("prevent"!==x)return;e.preventDefault()}if(Object.assign(n,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),o.startX=w,o.startY=b,n.touchStartTime=u(),t.allowClick=!0,t.updateSize(),t.swipeDirection=void 0,l.threshold>0&&(n.allowThresholdMove=!1),"touchstart"!==p.type){let e=!0;h.is(n.focusableElements)&&(e=!1,"SELECT"===h[0].nodeName&&(n.isTouched=!1)),s.activeElement&&d(s.activeElement).is(n.focusableElements)&&s.activeElement!==h[0]&&s.activeElement.blur();const a=e&&t.allowTouchMove&&l.touchStartPreventDefault;!l.touchStartForcePreventDefault&&!a||h[0].isContentEditable||p.preventDefault()}t.params.freeMode&&t.params.freeMode.enabled&&t.freeMode&&t.animating&&!l.cssMode&&t.freeMode.onTouchStart(),t.emit("touchStart",p)}function O(e){const t=a(),s=this,i=s.touchEventsData,{params:r,touches:n,rtlTranslate:l,enabled:o}=s;if(!o)return;let c=e;if(c.originalEvent&&(c=c.originalEvent),!i.isTouched)return void(i.startMoving&&i.isScrolling&&s.emit("touchMoveOpposite",c));if(i.isTouchEvent&&"touchmove"!==c.type)return;const p="touchmove"===c.type&&c.targetTouches&&(c.targetTouches[0]||c.changedTouches[0]),h="touchmove"===c.type?p.pageX:c.pageX,m="touchmove"===c.type?p.pageY:c.pageY;if(c.preventedByNestedSwiper)return n.startX=h,void(n.startY=m);if(!s.allowTouchMove)return d(c.target).is(i.focusableElements)||(s.allowClick=!1),void(i.isTouched&&(Object.assign(n,{startX:h,startY:m,currentX:h,currentY:m}),i.touchStartTime=u()));if(i.isTouchEvent&&r.touchReleaseOnEdges&&!r.loop)if(s.isVertical()){if(m<n.startY&&s.translate<=s.maxTranslate()||m>n.startY&&s.translate>=s.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else if(h<n.startX&&s.translate<=s.maxTranslate()||h>n.startX&&s.translate>=s.minTranslate())return;if(i.isTouchEvent&&t.activeElement&&c.target===t.activeElement&&d(c.target).is(i.focusableElements))return i.isMoved=!0,void(s.allowClick=!1);if(i.allowTouchCallbacks&&s.emit("touchMove",c),c.targetTouches&&c.targetTouches.length>1)return;n.currentX=h,n.currentY=m;const f=n.currentX-n.startX,g=n.currentY-n.startY;if(s.params.threshold&&Math.sqrt(f**2+g**2)<s.params.threshold)return;if(void 0===i.isScrolling){let e;s.isHorizontal()&&n.currentY===n.startY||s.isVertical()&&n.currentX===n.startX?i.isScrolling=!1:f*f+g*g>=25&&(e=180*Math.atan2(Math.abs(g),Math.abs(f))/Math.PI,i.isScrolling=s.isHorizontal()?e>r.touchAngle:90-e>r.touchAngle)}if(i.isScrolling&&s.emit("touchMoveOpposite",c),void 0===i.startMoving&&(n.currentX===n.startX&&n.currentY===n.startY||(i.startMoving=!0)),i.isScrolling)return void(i.isTouched=!1);if(!i.startMoving)return;s.allowClick=!1,!r.cssMode&&c.cancelable&&c.preventDefault(),r.touchMoveStopPropagation&&!r.nested&&c.stopPropagation(),i.isMoved||(r.loop&&!r.cssMode&&s.loopFix(),i.startTranslate=s.getTranslate(),s.setTransition(0),s.animating&&s.$wrapperEl.trigger("webkitTransitionEnd transitionend"),i.allowMomentumBounce
vendor: 1,100 bytes, line 45
45=!1,!r.grabCursor||!0!==s.allowSlideNext&&!0!==s.allowSlidePrev||s.setGrabCursor(!0),s.emit("sliderFirstMove",c)),s.emit("sliderMove",c),i.isMoved=!0;let v=s.isHorizontal()?f:g;n.diff=v,v*=r.touchRatio,l&&(v=-v),s.swipeDirection=v>0?"prev":"next",i.currentTranslate=v+i.startTranslate;let w=!0,b=r.resistanceRatio;if(r.touchReleaseOnEdges&&(b=0),v>0&&i.currentTranslate>s.minTranslate()?(w=!1,r.resistance&&(i.currentTranslate=s.minTranslate()-1+(-s.minTranslate()+i.startTranslate+v)**b)):v<0&&i.currentTranslate<s.maxTranslate()&&(w=!1,r.resistance&&(i.currentTranslate=s.maxTranslate()+1-(s.maxTranslate()-i.startTranslate-v)**b)),w&&(c.preventedByNestedSwiper=!0),!s.allowSlideNext&&"next"===s.swipeDirection&&i.currentTranslate<i.startTranslate&&(i.currentTranslate=i.startTranslate),!s.allowSlidePrev&&"prev"===s.swipeDirection&&i.currentTranslate>i.startTranslate&&(i.currentTranslate=i.startTranslate),s.allowSlidePrev||s.allowSlideNext||(i.currentTranslate=i.startTranslate),r.threshold>0){if(!(Math.abs(v)>r.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);
vendor: 17,582 bytes, line 45
45if(!i.allowThresholdMove)return i.allowThresholdMove=!0,n.startX=n.currentX,n.startY=n.currentY,i.currentTranslate=i.startTranslate,void(n.diff=s.isHorizontal()?n.currentX-n.startX:n.currentY-n.startY)}r.followFinger&&!r.cssMode&&((r.freeMode&&r.freeMode.enabled&&s.freeMode||r.watchSlidesProgress)&&(s.updateActiveIndex(),s.updateSlidesClasses()),s.params.freeMode&&r.freeMode.enabled&&s.freeMode&&s.freeMode.onTouchMove(),s.updateProgress(i.currentTranslate),s.setTranslate(i.currentTranslate))}function I(e){const t=this,s=t.touchEventsData,{params:a,touches:i,rtlTranslate:r,slidesGrid:n,enabled:l}=t;if(!l)return;let o=e;if(o.originalEvent&&(o=o.originalEvent),s.allowTouchCallbacks&&t.emit("touchEnd",o),s.allowTouchCallbacks=!1,!s.isTouched)return s.isMoved&&a.grabCursor&&t.setGrabCursor(!1),s.isMoved=!1,void(s.startMoving=!1);a.grabCursor&&s.isMoved&&s.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);const d=u(),c=d-s.touchStartTime;if(t.allowClick){const e=o.path||o.composedPath&&o.composedPath();t.updateClickedSlide(e&&e[0]||o.target),t.emit("tap click",o),c<300&&d-s.lastClickTime<300&&t.emit("doubleTap doubleClick",o)}if(s.lastClickTime=u(),p((()=>{t.destroyed||(t.allowClick=!0)})),!s.isTouched||!s.isMoved||!t.swipeDirection||0===i.diff||s.currentTranslate===s.startTranslate)return s.isTouched=!1,s.isMoved=!1,void(s.startMoving=!1);let h;if(s.isTouched=!1,s.isMoved=!1,s.startMoving=!1,h=a.followFinger?r?t.translate:-t.translate:-s.currentTranslate,a.cssMode)return;if(t.params.freeMode&&a.freeMode.enabled)return void t.freeMode.onTouchEnd({currentPos:h});let m=0,f=t.slidesSizesGrid[0];for(let e=0;e<n.length;e+=e<a.slidesPerGroupSkip?1:a.slidesPerGroup){const t=e<a.slidesPerGroupSkip-1?1:a.slidesPerGroup;void 0!==n[e+t]?h>=n[e]&&h<n[e+t]&&(m=e,f=n[e+t]-n[e]):h>=n[e]&&(m=e,f=n[n.length-1]-n[n.length-2])}let g=null,v=null;a.rewind&&(t.isBeginning?v=t.params.virtual&&t.params.virtual.enabled&&t.virtual?t.virtual.slides.length-1:t.slides.length-1:t.isEnd&&(g=0));const w=(h-n[m])/f,b=m<a.slidesPerGroupSkip-1?1:a.slidesPerGroup;if(c>a.longSwipesMs){if(!a.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&(w>=a.longSwipesRatio?t.slideTo(a.rewind&&t.isEnd?g:m+b):t.slideTo(m)),"prev"===t.swipeDirection&&(w>1-a.longSwipesRatio?t.slideTo(m+b):null!==v&&w<0&&Math.abs(w)>a.longSwipesRatio?t.slideTo(v):t.slideTo(m))}else{if(!a.shortSwipes)return void t.slideTo(t.activeIndex);t.navigation&&(o.target===t.navigation.nextEl||o.target===t.navigation.prevEl)?o.target===t.navigation.nextEl?t.slideTo(m+b):t.slideTo(m):("next"===t.swipeDirection&&t.slideTo(null!==g?g:m+b),"prev"===t.swipeDirection&&t.slideTo(null!==v?v:m))}}function A(){const e=this,{params:t,el:s}=e;if(s&&0===s.offsetWidth)return;t.breakpoints&&e.setBreakpoint();const{allowSlideNext:a,allowSlidePrev:i,snapGrid:r}=e;e.allowSlideNext=!0,e.allowSlidePrev=!0,e.updateSize(),e.updateSlides(),e.updateSlidesClasses(),("auto"===t.slidesPerView||t.slidesPerView>1)&&e.isEnd&&!e.isBeginning&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0),e.autoplay&&e.autoplay.running&&e.autoplay.paused&&e.autoplay.run(),e.allowSlidePrev=i,e.allowSlideNext=a,e.params.watchOverflow&&r!==e.snapGrid&&e.checkOverflow()}function D(e){const t=this;t.enabled&&(t.allowClick||(t.params.preventClicks&&e.preventDefault(),t.params.preventClicksPropagation&&t.animating&&(e.stopPropagation(),e.stopImmediatePropagation())))}function G(){const e=this,{wrapperEl:t,rtlTranslate:s,enabled:a}=e;if(!a)return;let i;e.previousTranslate=e.translate,e.isHorizontal()?e.translate=-t.scrollLeft:e.translate=-t.scrollTop,0===e.translate&&(e.translate=0),e.updateActiveIndex(),e.updateSlidesClasses();const r=e.maxTranslate()-e.minTranslate();i=0===r?0:(e.translate-e.minTranslate())/r,i!==e.progress&&e.updateProgress(s?-e.translate:e.translate),e.emit("setTranslate",e.translate,!1)}let N=!1;function B(){}const H=(e,t)=>{const s=a(),{params:i,touchEvents:r,el:n,wrapperEl:l,device:o,support:d}=e,c=!!i.nested,p="on"===t?"addEventListener":"removeEventListener",u=t;if(d.touch){const t=!("touchstart"!==r.start||!d.passiveListener||!i.passiveListeners)&&{passive:!0,capture:!1};n[p](r.start,e.onTouchStart,t),n[p](r.move,e.onTouchMove,d.passiveListener?{passive:!1,capture:c}:c),n[p](r.end,e.onTouchEnd,t),r.cancel&&n[p](r.cancel,e.onTouchEnd,t)}else n[p](r.start,e.onTouchStart,!1),s[p](r.move,e.onTouchMove,c),s[p](r.end,e.onTouchEnd,!1);(i.preventClicks||i.preventClicksPropagation)&&n[p]("click",e.onClick,!0),i.cssMode&&l[p]("scroll",e.onScroll),i.updateOnWindowResize?e[u](o.ios||o.android?"resize orientationchange observerUpdate":"resize observerUpdate",A,!0):e[u]("observerUpdate",A,!0)};var X={attachEvents:function(){const e=this,t=a(),{params:s,support:i}=e;e.onTouchStart=L.bind(e),e.onTouchMove=O.bind(e),e.onTouchEnd=I.bind(e),s.cssMode&&(e.onScroll=G.bind(e)),e.onClick=D.bind(e),i.touch&&!N&&(t.addEventListener("touchstart",B),N=!0),H(e,"on")},detachEvents:function(){H(this,"off")}};const Y=(e,t)=>e.grid&&t.grid&&t.grid.rows>1;var R={addClasses:function(){const e=this,{classNames:t,params:s,rtl:a,$el:i,device:r,support:n}=e,l=function(e,t){const s=[];return e.forEach((e=>{"object"==typeof e?Object.keys(e).forEach((a=>{e[a]&&s.push(t+a)})):"string"==typeof e&&s.push(t+e)})),s}(["initialized",s.direction,{"pointer-events":!n.touch},{"free-mode":e.params.freeMode&&s.freeMode.enabled},{autoheight:s.autoHeight},{rtl:a},{grid:s.grid&&s.grid.rows>1},{"grid-column":s.grid&&s.grid.rows>1&&"column"===s.grid.fill},{android:r.android},{ios:r.ios},{"css-mode":s.cssMode},{centered:s.cssMode&&s.centeredSlides},{"watch-progress":s.watchSlidesProgress}],s.containerModifierClass);t.push(...l),i.addClass([...t].join(" ")),e.emitContainerClasses()},removeClasses:function(){const{$el:e,classNames:t}=this;e.removeClass(t.join(" ")),this.emitContainerClasses()}};var W={init:!0,direction:"horizontal",touchEventsTarget:"wrapper",initialSlide:0,speed:300,cssMode:!1,updateOnWindowResize:!0,resizeObserver:!0,nested:!1,createElements:!1,enabled:!0,focusableElements:"input, select, option, textarea, button, video, label",width:null,height:null,preventInteractionOnTransition:!1,userAgent:null,url:null,edgeSwipeDetection:!1,edgeSwipeThreshold:20,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,breakpointsBase:"window",spaceBetween:0,slidesPerView:1,slidesPerGroup:1,slidesPerGroupSkip:0,slidesPerGroupAuto:!1,centeredSlides:!1,centeredSlidesBounds:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!0,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopedSlidesLimit:!0,loopFillGroupWithBlank:!1,loopPreventsSlide:!0,rewind:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,maxBackfaceHiddenSlides:10,containerModifierClass:"swiper-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0,_emitClasses:!1};function q(e,t){return function(s){void 0===s&&(s={});const a=Object.keys(s)[0],i=s[a];"object"==typeof i&&null!==i?(["navigation","pagination","scrollbar"].indexOf(a)>=0&&!0===e[a]&&(e[a]={auto:!0}),a in e&&"enabled"in i?(!0===e[a]&&(e[a]={enabled:!0}),"object"!=typeof e[a]||"enabled"in e[a]||(e[a].enabled=!0),e[a]||(e[a]={enabled:!1}),g(t,s)):g(t,s)):g(t,s)}}const j={eventsEmitter:$,update:S,translate:M,transition:{setTransition:function(e,t){const s=this;s.params.cssMode||s.$wrapperEl.transition(e),s.emit("setTransition",e,t)},transitionStart:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;a.cssMode||(a.autoHeight&&s.updateAutoHeight(),P({swiper:s,runCallbacks:e,direction:t,step:"Start"}))},transitionEnd:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;s.animating=!1,a.cssMode||(s.setTransition(0),P({swiper:s,runCallbacks:e,direction:t,step:"End"}))}},slide:k,loop:z,grabCursor:{setGrabCursor:function(e){const t=this;if(t.support.touch||!t.params.simulateTouch||t.params.watchOverflow&&t.isLocked||t.params.cssMode)return;const s="container"===t.params.touchEventsTarget?t.el:t.wrapperEl;s.style.cursor="move",s.style.cursor=e?"grabbing":"grab"},unsetGrabCursor:function(){const e=this;e.support.touch||e.params.watchOverflow&&e.isLocked||e.params.cssMode||(e["container"===e.params.touchEventsTarget?"el":"wrapperEl"].style.cursor="")}},events:X,breakpoints:{setBreakpoint:function(){const e=this,{activeIndex:t,initialized:s,loopedSlides:a=0,params:i,$el:r}=e,n=i.breakpoints;if(!n||n&&0===Object.keys(n).length)return;const l=e.getBreakpoint(n,e.params.breakpointsBase,e.el);if(!l||e.currentBreakpoint===l)return;const o=(l in n?n[l]:void 0)||e.originalParams,d=Y(e,i),c=Y(e,o),p=i.enabled;d&&!c?(r.removeClass(`${i.containerModifierClass}grid ${i.containerModifierClass}grid-column`),e.emitContainerClasses()):!d&&c&&(r.addClass(`${i.containerModifierClass}grid`),(o.grid.fill&&"column"===o.grid.fill||!o.grid.fill&&"column"===i.grid.fill)&&r.addClass(`${i.containerModifierClass}grid-column`),e.emitContainerClasses()),["navigation","pagination","scrollbar"].forEach((t=>{const s=i[t]&&i[t].enabled,a=o[t]&&o[t].enabled;s&&!a&&e[t].disable(),!s&&a&&e[t].enable()}));const u=o.direction&&o.direction!==i.direction,h=i.loop&&(o.slidesPerView!==i.slidesPerView||u);u&&s&&e.changeDirection(),g(e.params,o);const m=e.params.enabled;Object.assign(e,{allowTouchMove:e.params.allowTouchMove,allowSlideNext:e.params.allowSlideNext,allowSlidePrev:e.params.allowSlidePrev}),p&&!m?e.disable():!p&&m&&e.enable(),e.currentBreakpoint=l,e.emit("_beforeBreakpoint",o),h&&s&&(e.loopDestroy(),e.loopCreate(),e.updateSlides(),e.slideTo(t-a+e.loopedSlides,0,!1)),e.emit("breakpoint",o)},getBreakpoint:function(e,t,s){if(void 0===t&&(t="window"),!e||"container"===t&&!s)return;let a=!1;const i=r(),n="window"===t?i.innerHeight:s.clientHeight,l=Object.keys(e).map((e=>{if("string"==typeof e&&0===e.indexOf("@")){const t=parseFloat(e.substr(1));return{value:n*t,point:e}}return{value:e,point:e}}));l.sort(((e,t)=>parseInt(e.value,10)-parseInt(t.value,10)));for(let e=0;e<l.length;e+=1){const{point:r,value:n}=l[e];"window"===t?i.matchMedia(`(min-width: ${n}px)`).matches&&(a=r):n<=s.clientWidth&&(a=r)}return a||"max"}},checkOverflow:{checkOverflow:function(){const e=this,{isLocked:t,params:s}=e,{slidesOffsetBefore:a}=s;if(a){const t=e.slides.length-1,s=e.slidesGrid[t]+e.slidesSizesGrid[t]+2*a;e.isLocked=e.size>s}else e.isLocked=1===e.snapGrid.length;!0===s.allowSlideNext&&(e.allowSlideNext=!e.isLocked),!0===s.allowSlidePrev&&(e.allowSlidePrev=!e.isLocked),t&&t!==e.isLocked&&(e.isEnd=!1),t!==e.isLocked&&e.emit(e.isLocked?"lock":"unlock")}},classes:R,images:{loadImage:function(e,t,s,a,i,n){const l=r();let o;function c(){n&&n()}d(e).parent("picture")[0]||e.complete&&i?c():t?(o=new l.Image,o.onload=c,o.onerror=c,a&&(o.sizes=a),s&&(o.srcset=s),t&&(o.src=t)):c()},preloadImages:function(){const e=this;function t(){null!=e&&e&&!e.destroyed&&(void 0!==e.imagesLoaded&&(e.imagesLoaded+=1),e.imagesLoaded===e.imagesToLoad.length&&(e.params.updateOnImagesReady&&e.update(),e.emit("imagesReady")))}e.imagesToLoad=e.$el.find("img");for(let s=0;s<e.imagesToLoad.length;s+=1){const a=e.imagesToLoad[s];e.loadImage(a,a.currentSrc||a.getAttribute("src"),a.srcset||a.getAttribute("srcset"),a.sizes||a.getAttribute("sizes"),!0,t)}}}},_={};class V{constructor(){let e,t;for(var s=arguments.length,a=new Array(s),i=0;i<s;i++)a[i]=arguments[i];if(1===a.length&&a[0].constructor&&"Object"===Object.prototype.toString.call(a[0]).slice(8,-1)?t=a[0]:[e,t]=a,t||(t={}),t=g({},t),e&&!t.el&&(t.el=e),t.el&&d(t.el).length>1){const e=[];return d(t.el).each((s=>{const a=g({},t,{el:s});e.push(new V(a))})),e}const r=this;r.__swiper__=!0,r.support=E(),r.device=C({userAgent:t.userAgent}),r.browser=T(),r.eventsListeners={},r.eventsAnyListeners=[],r.modules=[...r.__modules__],t.modules&&Array.isArray(t.modules)&&r.modules.push(...t.modules);const n={};r.modules.forEach((e=>{e({swiper:r,extendParams:q(t,n),on:r.on.bind(r),once:r.once.bind(r),off:r.off.bind(r),emit:r.emit.bind(r)})}));const l=g({},W,n);return r.params=g({},l,_,t),r.originalParams=g({},r.params),r.passedParams=g({},t),r.params&&r.params.on&&Object.keys(r.params.on).forEach((e=>{r.on(e,r.params.on[e])})),r.params&&r.params.onAny&&r.onAny(r.params.onAny),r.$=d,Object.assign(r,{enabled:r.params.enabled,el:e,classNames:[],slides:d(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:()=>"horizontal"===r.params.direction,isVertical:()=>"vertical"===r.params.direction,activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,allowSlideNext:r.params.allowSlideNext,allowSlidePrev:r.params.allowSlidePrev,touchEvents:function(){const e=["touchstart","touchmove","touchend","touchcancel"],t=["pointerdown","pointermove","pointerup"];return r.touchEventsTouch={start:e[0],move:e[1],end:e[2],cancel:e[3]},r.touchEventsDesktop={start:t[0],move:t[1],end:t[2]},r.support.touch||!r.params.simulateTouch?r.touchEventsTouch:r.touchEventsDesktop}(),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,focusableElements:r.params.focusableElements,lastClickTime:u(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:r.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),r.emit("_swiper"),r.params.init&&r.init(),r}enable(){const e=this;e.enabled||(e.enabled=!0,e.params.grabCursor&&e.setGrabCursor(),e.emit("enable"))}disable(){const e=this;e.enabled&&(e.enabled=!1,e.params.grabCursor&&e.unsetGrabCursor(),e.emit("disable"))}setProgress(e,t){const s=this;e=Math.min(Math.max(e,0),1);const a=s.minTranslate(),i=(s.maxTranslate()-a)*e+a;s.translateTo(i,void 0===t?0:t),s.updateActiveIndex(),s.updateSlidesClasses()}emitContainerClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=e.el.className.split(" ").filter((t=>0===t.indexOf("swiper")||0===t.indexOf(e.params.containerModifierClass)));e.emit("_containerClasses",t.join(" "))}getSlideClasses(e){const t=this;return t.destroyed?"":e.className.split(" ").filter((e=>0===e.indexOf("swiper-slide")||0===e.indexOf(t.params.slideClass))).join(" ")}emitSlidesClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=[];e.slides.each((s=>{const a=e.getSlideClasses(s);t.push({slideEl:s,classNames:a}),e.emit("_slideClass",s,a)})),e.emit("_slideClasses",t)}slidesPerViewDynamic(e,t){void 0===e&&(e="current"),void 0===t&&(t=!1);const{params:s,slides:a,slidesGrid:i,slidesSizesGrid:r,size:n,activeIndex:l}=this;let o=1;if(s.centeredSlides){let e,t=a[l].swiperSlideSize;for(let s=l+1;s<a.length;s+=1)a[s]&&!e&&(t+=a[s].swiperSlideSize,o+=1,t>n&&(e=!0));for(let s=l-1;s>=0;s-=1)a[s]&&!e&&(t+=a[s].swiperSlideSize,o+=1,t>n&&(e=!0))}else if("current"===e)for(let e=l+1;e<a.length;e+=1){(t?i[e]+r[e]-i[l]<n:i[e]-i[l]<n)&&(o+=1)}else for(let e=l-1;e>=0;e-=1){i[l]-i[e]<n&&(o+=1)}return o}update(){const e=this;if(!e||e.destroyed)return;const{snapGrid:t,params:s}=e;function a(){const t=e.rtlTranslate?-1*e.translate:e.translate,s=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(s),e.updateActiveIndex(),e.updateSlidesClasses()}let i;s.breakpoints&&e.setBreakpoint(),e.updateSize(),e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),e.params.freeMode&&e.params.freeMode.enabled?(a(),e.params.autoHeight&&e.updateAutoHeight()):(i=("auto"===e.params.slidesPerView||e.params.slidesPerView>1)&&e.isEnd&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0),i||a()),s.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}changeDirection(e,t){void 0===t&&(t=!0);const s=this,a=s.params.direction;return e||(e="horizontal"===a?"vertical":"horizontal"),e===a||"horizontal"!==e&&"vertical"!==e||(s.$el.removeClass(`${s.params.containerModifierClass}${a}`).addClass(`${s.params.containerModifierClass}${e}`),s.emitContainerClasses(),s.params.direction=e,s.slides.each((t=>{"vertical"===e?t.style.width="":t.style.height=""})),s.emit("changeDirection"),t&&s.update()),s}changeLanguageDirection(e){const t=this;t.rtl&&"rtl"===e||!t.rtl&&"ltr"===e||(t.rtl="rtl"===e,t.rtlTranslate="horizontal"===t.params.direction&&t.rtl,t.rtl?(t.$el.addClass(`${t.params.containerModifierClass}rtl`),t.el.dir="rtl"):(t.$el.removeClass(`${t.params.containerModifierClass}
45rtl`),t.el.dir="ltr"),t.update())}mount(e){const t=this;if(t.mounted)return!0;const s=d(e||t.params.el);if(!(e=s[0]))return!1;e.swiper=t;const i=()=>`.${(t.params.wrapperClass||"").trim().split(" ").join(".")}`;let r=(()=>{if(e&&e.shadowRoot&&e.shadowRoot.querySelector){const t=d(e.shadowRoot.querySelector(i()));return t.children=e=>s.children(e),t}return s.children?s.children(i()):d(s).children(i())})();if(0===r.length&&t.params.createElements){const e=a().createElement("div");r=d(e),e.className=t.params.wrapperClass,s.append(e),s.children(`.${t.params.slideClass}`).each((e=>{r.append(e)}))}return Object.assign(t,{$el:s,el:e,$wrapperEl:r,wrapperEl:r[0],mounted:!0,rtl:"rtl"===e.dir.toLowerCase()||"rtl"===s.css("direction"),rtlTranslate:"horizontal"===t.params.direction&&("rtl"===e.dir.toLowerCase()||"rtl"===s.css("direction")),wrongRTL:"-webkit-box"===r.css("display")}),!0}init(e){const t=this;if(t.initialized)return t;return!1===t.mount(e)||(t.emit("beforeInit"),t.params.breakpoints&&t.setBreakpoint(),t.addClasses(),t.params.loop&&t.loopCreate(),t.updateSize(),t.updateSlides(),t.params.watchOverflow&&t.checkOverflow(),t.params.grabCursor&&t.enabled&&t.setGrabCursor(),t.params.preloadImages&&t.preloadImages(),t.params.loop?t.slideTo(t.params.initialSlide+t.loopedSlides,0,t.params.runCallbacksOnInit,!1,!0):t.slideTo(t.params.initialSlide,0,t.params.runCallbacksOnInit,!1,!0),t.attachEvents(),t.initialized=!0,t.emit("init"),t.emit("afterInit")),t}destroy(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);const s=this,{params:a,$el:i,$wrapperEl:r,slides:n}=s;return void 0===s.params||s.destroyed||(s.emit("beforeDestroy"),s.initialized=!1,s.detachEvents(),a.loop&&s.loopDestroy(),t&&(s.removeClasses(),i.removeAttr("style"),r.removeAttr("style"),n&&n.length&&n.removeClass([a.slideVisibleClass,a.slideActiveClass,a.slideNextClass,a.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index")),s.emit("destroy"),Object.keys(s.eventsListeners).forEach((e=>{s.off(e)})),!1!==e&&(s.$el[0].swiper=null,function(e){const t=e;Object.keys(t).forEach((e=>{try{t[e]=null}catch(e){}try{delete t[e]}catch(e){}}))}(s)),s.destroyed=!0),null}static extendDefaults(e){g(_,e)}static get extendedDefaults(){return _}static get defaults(){return W}static installModule(e){V.prototype.__modules__||(V.prototype.__modules__=[]);const t=V.prototype.__modules__;"function"==typeof e&&t.indexOf(e)<0&&t.push(e)}static use(e){return Array.isArray(e)?(e.forEach((e=>V.installModule(e))),V):(V.installModule(e),V)}}function F(e,t,s,i){const r=a();
vendor: 34,804 bytes, line 45
45return e.params.createElements&&Object.keys(i).forEach((a=>{if(!s[a]&&!0===s.auto){let n=e.$el.children(`.${i[a]}`)[0];n||(n=r.createElement("div"),n.className=i[a],e.$el.append(n)),s[a]=n,t[a]=n}})),s}function U(e){return void 0===e&&(e=""),`.${e.trim().replace(/([\.:!\/])/g,"\\$1").replace(/ /g,".")}`}function K(e){const t=this,{$wrapperEl:s,params:a}=t;if(a.loop&&t.loopDestroy(),"object"==typeof e&&"length"in e)for(let t=0;t<e.length;t+=1)e[t]&&s.append(e[t]);else s.append(e);a.loop&&t.loopCreate(),a.observer||t.update()}function Z(e){const t=this,{params:s,$wrapperEl:a,activeIndex:i}=t;s.loop&&t.loopDestroy();let r=i+1;if("object"==typeof e&&"length"in e){for(let t=0;t<e.length;t+=1)e[t]&&a.prepend(e[t]);r=i+e.length}else a.prepend(e);s.loop&&t.loopCreate(),s.observer||t.update(),t.slideTo(r,0,!1)}function Q(e,t){const s=this,{$wrapperEl:a,params:i,activeIndex:r}=s;let n=r;i.loop&&(n-=s.loopedSlides,s.loopDestroy(),s.slides=a.children(`.${i.slideClass}`));const l=s.slides.length;if(e<=0)return void s.prependSlide(t);if(e>=l)return void s.appendSlide(t);let o=n>e?n+1:n;const d=[];for(let t=l-1;t>=e;t-=1){const e=s.slides.eq(t);e.remove(),d.unshift(e)}if("object"==typeof t&&"length"in t){for(let e=0;e<t.length;e+=1)t[e]&&a.append(t[e]);o=n>e?n+t.length:n}else a.append(t);for(let e=0;e<d.length;e+=1)a.append(d[e]);i.loop&&s.loopCreate(),i.observer||s.update(),i.loop?s.slideTo(o+s.loopedSlides,0,!1):s.slideTo(o,0,!1)}function J(e){const t=this,{params:s,$wrapperEl:a,activeIndex:i}=t;let r=i;s.loop&&(r-=t.loopedSlides,t.loopDestroy(),t.slides=a.children(`.${s.slideClass}`));let n,l=r;if("object"==typeof e&&"length"in e){for(let s=0;s<e.length;s+=1)n=e[s],t.slides[n]&&t.slides.eq(n).remove(),n<l&&(l-=1);l=Math.max(l,0)}else n=e,t.slides[n]&&t.slides.eq(n).remove(),n<l&&(l-=1),l=Math.max(l,0);s.loop&&t.loopCreate(),s.observer||t.update(),s.loop?t.slideTo(l+t.loopedSlides,0,!1):t.slideTo(l,0,!1)}function ee(){const e=this,t=[];for(let s=0;s<e.slides.length;s+=1)t.push(s);e.removeSlide(t)}function te(e){const{effect:t,swiper:s,on:a,setTranslate:i,setTransition:r,overwriteParams:n,perspective:l,recreateShadows:o,getEffectParams:d}=e;let c;a("beforeInit",(()=>{if(s.params.effect!==t)return;s.classNames.push(`${s.params.containerModifierClass}${t}`),l&&l()&&s.classNames.push(`${s.params.containerModifierClass}3d`);const e=n?n():{};Object.assign(s.params,e),Object.assign(s.originalParams,e)})),a("setTranslate",(()=>{s.params.effect===t&&i()})),a("setTransition",((e,a)=>{s.params.effect===t&&r(a)})),a("transitionEnd",(()=>{if(s.params.effect===t&&o){if(!d||!d().slideShadows)return;s.slides.each((e=>{s.$(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").remove()})),o()}})),a("virtualUpdate",(()=>{s.params.effect===t&&(s.slides.length||(c=!0),requestAnimationFrame((()=>{c&&s.slides&&s.slides.length&&(i(),c=!1)})))}))}function se(e,t){return e.transformEl?t.find(e.transformEl).css({"backface-visibility":"hidden","-webkit-backface-visibility":"hidden"}):t}function ae(e){let{swiper:t,duration:s,transformEl:a,allSlides:i}=e;const{slides:r,activeIndex:n,$wrapperEl:l}=t;if(t.params.virtualTranslate&&0!==s){let e,s=!1;e=i?a?r.find(a):r:a?r.eq(n).find(a):r.eq(n),e.transitionEnd((()=>{if(s)return;if(!t||t.destroyed)return;s=!0,t.animating=!1;const e=["webkitTransitionEnd","transitionend"];for(let t=0;t<e.length;t+=1)l.trigger(e[t])}))}}function ie(e,t,s){const a="swiper-slide-shadow"+(s?`-${s}`:""),i=e.transformEl?t.find(e.transformEl):t;let r=i.children(`.${a}`);return r.length||(r=d(`<div class="swiper-slide-shadow${s?`-${s}`:""}"></div>`),i.append(r)),r}Object.keys(j).forEach((e=>{Object.keys(j[e]).forEach((t=>{V.prototype[t]=j[e][t]}))})),V.use([function(e){let{swiper:t,on:s,emit:a}=e;const i=r();let n=null,l=null;const o=()=>{t&&!t.destroyed&&t.initialized&&(a("beforeResize"),a("resize"))},d=()=>{t&&!t.destroyed&&t.initialized&&a("orientationchange")};s("init",(()=>{t.params.resizeObserver&&void 0!==i.ResizeObserver?t&&!t.destroyed&&t.initialized&&(n=new ResizeObserver((e=>{l=i.requestAnimationFrame((()=>{const{width:s,height:a}=t;let i=s,r=a;e.forEach((e=>{let{contentBoxSize:s,contentRect:a,target:n}=e;n&&n!==t.el||(i=a?a.width:(s[0]||s).inlineSize,r=a?a.height:(s[0]||s).blockSize)})),i===s&&r===a||o()}))})),n.observe(t.el)):(i.addEventListener("resize",o),i.addEventListener("orientationchange",d))})),s("destroy",(()=>{l&&i.cancelAnimationFrame(l),n&&n.unobserve&&t.el&&(n.unobserve(t.el),n=null),i.removeEventListener("resize",o),i.removeEventListener("orientationchange",d)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=[],l=r(),o=function(e,t){void 0===t&&(t={});const s=new(l.MutationObserver||l.WebkitMutationObserver)((e=>{if(1===e.length)return void i("observerUpdate",e[0]);const t=function(){i("observerUpdate",e[0])};l.requestAnimationFrame?l.requestAnimationFrame(t):l.setTimeout(t,0)}));s.observe(e,{attributes:void 0===t.attributes||t.attributes,childList:void 0===t.childList||t.childList,characterData:void 0===t.characterData||t.characterData}),n.push(s)};s({observer:!1,observeParents:!1,observeSlideChildren:!1}),a("init",(()=>{if(t.params.observer){if(t.params.observeParents){const e=t.$el.parents();for(let t=0;t<e.length;t+=1)o(e[t])}o(t.$el[0],{childList:t.params.observeSlideChildren}),o(t.$wrapperEl[0],{attributes:!1})}})),a("destroy",(()=>{n.forEach((e=>{e.disconnect()})),n.splice(0,n.length)}))}]);const re=[function(e){let t,{swiper:s,extendParams:a,on:i,emit:r}=e;function n(e,t){const a=s.params.virtual;if(a.cache&&s.virtual.cache[t])return s.virtual.cache[t];const i=a.renderSlide?d(a.renderSlide.call(s,e,t)):d(`<div class="${s.params.slideClass}" data-swiper-slide-index="${t}">${e}</div>`);return i.attr("data-swiper-slide-index")||i.attr("data-swiper-slide-index",t),a.cache&&(s.virtual.cache[t]=i),i}function l(e){const{slidesPerView:t,slidesPerGroup:a,centeredSlides:i}=s.params,{addSlidesBefore:l,addSlidesAfter:o}=s.params.virtual,{from:d,to:c,slides:p,slidesGrid:u,offset:h}=s.virtual;s.params.cssMode||s.updateActiveIndex();const m=s.activeIndex||0;let f,g,v;f=s.rtlTranslate?"right":s.isHorizontal()?"left":"top",i?(g=Math.floor(t/2)+a+o,v=Math.floor(t/2)+a+l):(g=t+(a-1)+o,v=a+l);const w=Math.max((m||0)-v,0),b=Math.min((m||0)+g,p.length-1),x=(s.slidesGrid[w]||0)-(s.slidesGrid[0]||0);function y(){s.updateSlides(),s.updateProgress(),s.updateSlidesClasses(),s.lazy&&s.params.lazy.enabled&&s.lazy.load(),r("virtualUpdate")}if(Object.assign(s.virtual,{from:w,to:b,offset:x,slidesGrid:s.slidesGrid}),d===w&&c===b&&!e)return s.slidesGrid!==u&&x!==h&&s.slides.css(f,`${x}px`),s.updateProgress(),void r("virtualUpdate");if(s.params.virtual.renderExternal)return s.params.virtual.renderExternal.call(s,{offset:x,from:w,to:b,slides:function(){const e=[];for(let t=w;t<=b;t+=1)e.push(p[t]);return e}()}),void(s.params.virtual.renderExternalUpdate?y():r("virtualUpdate"));const E=[],C=[];if(e)s.$wrapperEl.find(`.${s.params.slideClass}`).remove();else for(let e=d;e<=c;e+=1)(e<w||e>b)&&s.$wrapperEl.find(`.${s.params.slideClass}[data-swiper-slide-index="${e}"]`).remove();for(let t=0;t<p.length;t+=1)t>=w&&t<=b&&(void 0===c||e?C.push(t):(t>c&&C.push(t),t<d&&E.push(t)));C.forEach((e=>{s.$wrapperEl.append(n(p[e],e))})),E.sort(((e,t)=>t-e)).forEach((e=>{s.$wrapperEl.prepend(n(p[e],e))})),s.$wrapperEl.children(".swiper-slide").css(f,`${x}px`),y()}a({virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null,renderExternalUpdate:!0,addSlidesBefore:0,addSlidesAfter:0}}),s.virtual={cache:{},from:void 0,to:void 0,slides:[],offset:0,slidesGrid:[]},i("beforeInit",(()=>{s.params.virtual.enabled&&(s.virtual.slides=s.params.virtual.slides,s.classNames.push(`${s.params.containerModifierClass}virtual`),s.params.watchSlidesProgress=!0,s.originalParams.watchSlidesProgress=!0,s.params.initialSlide||l())})),i("setTranslate",(()=>{s.params.virtual.enabled&&(s.params.cssMode&&!s._immediateVirtual?(clearTimeout(t),t=setTimeout((()=>{l()}),100)):l())})),i("init update resize",(()=>{s.params.virtual.enabled&&s.params.cssMode&&v(s.wrapperEl,"--swiper-virtual-size",`${s.virtualSize}px`)})),Object.assign(s.virtual,{appendSlide:function(e){if("object"==typeof e&&"length"in e)for(let t=0;t<e.length;t+=1)e[t]&&s.virtual.slides.push(e[t]);else s.virtual.slides.push(e);l(!0)},prependSlide:function(e){const t=s.activeIndex;let a=t+1,i=1;if(Array.isArray(e)){for(let t=0;t<e.length;t+=1)e[t]&&s.virtual.slides.unshift(e[t]);a=t+e.length,i=e.length}else s.virtual.slides.unshift(e);if(s.params.virtual.cache){const e=s.virtual.cache,t={};Object.keys(e).forEach((s=>{const a=e[s],r=a.attr("data-swiper-slide-index");r&&a.attr("data-swiper-slide-index",parseInt(r,10)+i),t[parseInt(s,10)+i]=a})),s.virtual.cache=t}l(!0),s.slideTo(a,0)},removeSlide:function(e){if(null==e)return;let t=s.activeIndex;if(Array.isArray(e))for(let a=e.length-1;a>=0;a-=1)s.virtual.slides.splice(e[a],1),s.params.virtual.cache&&delete s.virtual.cache[e[a]],e[a]<t&&(t-=1),t=Math.max(t,0);else s.virtual.slides.splice(e,1),s.params.virtual.cache&&delete s.virtual.cache[e],e<t&&(t-=1),t=Math.max(t,0);l(!0),s.slideTo(t,0)},removeAllSlides:function(){s.virtual.slides=[],s.params.virtual.cache&&(s.virtual.cache={}),l(!0),s.slideTo(0,0)},update:l})},function(e){let{swiper:t,extendParams:s,on:i,emit:n}=e;const l=a(),o=r();function c(e){if(!t.enabled)return;const{rtlTranslate:s}=t;let a=e;a.originalEvent&&(a=a.originalEvent);const i=a.keyCode||a.charCode,r=t.params.keyboard.pageUpDown,d=r&&33===i,c=r&&34===i,p=37===i,u=39===i,h=38===i,m=40===i;if(!t.allowSlideNext&&(t.isHorizontal()&&u||t.isVertical()&&m||c))return!1;if(!t.allowSlidePrev&&(t.isHorizontal()&&p||t.isVertical()&&h||d))return!1;if(!(a.shiftKey||a.altKey||a.ctrlKey||a.metaKey||l.activeElement&&l.activeElement.nodeName&&("input"===l.activeElement.nodeName.toLowerCase()||"textarea"===l.activeElement.nodeName.toLowerCase()))){if(t.params.keyboard.onlyInViewport&&(d||c||p||u||h||m)){let e=!1;if(t.$el.parents(`.${t.params.slideClass}`).length>0&&0===t.$el.parents(`.${t.params.slideActiveClass}`).length)return;const a=t.$el,i=a[0].clientWidth,r=a[0].clientHeight,n=o.innerWidth,l=o.innerHeight,d=t.$el.offset();s&&(d.left-=t.$el[0].scrollLeft);const c=[[d.left,d.top],[d.left+i,d.top],[d.left,d.top+r],[d.left+i,d.top+r]];for(let t=0;t<c.length;t+=1){const s=c[t];if(s[0]>=0&&s[0]<=n&&s[1]>=0&&s[1]<=l){if(0===s[0]&&0===s[1])continue;e=!0}}if(!e)return}t.isHorizontal()?((d||c||p||u)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),((c||u)&&!s||(d||p)&&s)&&t.slideNext(),((d||p)&&!s||(c||u)&&s)&&t.slidePrev()):((d||c||h||m)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),(c||m)&&t.slideNext(),(d||h)&&t.slidePrev()),n("keyPress",i)}}function p(){t.keyboard.enabled||(d(l).on("keydown",c),t.keyboard.enabled=!0)}function u(){t.keyboard.enabled&&(d(l).off("keydown",c),t.keyboard.enabled=!1)}t.keyboard={enabled:!1},s({keyboard:{enabled:!1,onlyInViewport:!0,pageUpDown:!0}}),i("init",(()=>{t.params.keyboard.enabled&&p()})),i("destroy",(()=>{t.keyboard.enabled&&u()})),Object.assign(t.keyboard,{enable:p,disable:u})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();let l;s({mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarget:"container",thresholdDelta:null,thresholdTime:null}}),t.mousewheel={enabled:!1};let o,c=u();const h=[];function m(){t.enabled&&(t.mouseEntered=!0)}function f(){t.enabled&&(t.mouseEntered=!1)}function g(e){return!(t.params.mousewheel.thresholdDelta&&e.delta<t.params.mousewheel.thresholdDelta)&&(!(t.params.mousewheel.thresholdTime&&u()-c<t.params.mousewheel.thresholdTime)&&(e.delta>=6&&u()-c<60||(e.direction<0?t.isEnd&&!t.params.loop||t.animating||(t.slideNext(),i("scroll",e.raw)):t.isBeginning&&!t.params.loop||t.animating||(t.slidePrev(),i("scroll",e.raw)),c=(new n.Date).getTime(),!1)))}function v(e){let s=e,a=!0;if(!t.enabled)return;const r=t.params.mousewheel;t.params.cssMode&&s.preventDefault();let n=t.$el;if("container"!==t.params.mousewheel.eventsTarget&&(n=d(t.params.mousewheel.eventsTarget)),!t.mouseEntered&&!n[0].contains(s.target)&&!r.releaseOnEdges)return!0;s.originalEvent&&(s=s.originalEvent);let c=0;const m=t.rtlTranslate?-1:1,f=function(e){let t=0,s=0,a=0,i=0;return"detail"in e&&(s=e.detail),"wheelDelta"in e&&(s=-e.wheelDelta/120),"wheelDeltaY"in e&&(s=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=s,s=0),a=10*t,i=10*s,"deltaY"in e&&(i=e.deltaY),"deltaX"in e&&(a=e.deltaX),e.shiftKey&&!a&&(a=i,i=0),(a||i)&&e.deltaMode&&(1===e.deltaMode?(a*=40,i*=40):(a*=800,i*=800)),a&&!t&&(t=a<1?-1:1),i&&!s&&(s=i<1?-1:1),{spinX:t,spinY:s,pixelX:a,pixelY:i}}(s);if(r.forceToAxis)if(t.isHorizontal()){if(!(Math.abs(f.pixelX)>Math.abs(f.pixelY)))return!0;c=-f.pixelX*m}else{if(!(Math.abs(f.pixelY)>Math.abs(f.pixelX)))return!0;c=-f.pixelY}else c=Math.abs(f.pixelX)>Math.abs(f.pixelY)?-f.pixelX*m:-f.pixelY;if(0===c)return!0;r.invert&&(c=-c);let v=t.getTranslate()+c*r.sensitivity;if(v>=t.minTranslate()&&(v=t.minTranslate()),v<=t.maxTranslate()&&(v=t.maxTranslate()),a=!!t.params.loop||!(v===t.minTranslate()||v===t.maxTranslate()),a&&t.params.nested&&s.stopPropagation(),t.params.freeMode&&t.params.freeMode.enabled){const e={time:u(),delta:Math.abs(c),direction:Math.sign(c)},a=o&&e.time<o.time+500&&e.delta<=o.delta&&e.direction===o.direction;if(!a){o=void 0,t.params.loop&&t.loopFix();let n=t.getTranslate()+c*r.sensitivity;const d=t.isBeginning,u=t.isEnd;if(n>=t.minTranslate()&&(n=t.minTranslate()),n<=t.maxTranslate()&&(n=t.maxTranslate()),t.setTransition(0),t.setTranslate(n),t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses(),(!d&&t.isBeginning||!u&&t.isEnd)&&t.updateSlidesClasses(),t.params.freeMode.sticky){clearTimeout(l),l=void 0,h.length>=15&&h.shift();const s=h.length?h[h.length-1]:void 0,a=h[0];if(h.push(e),s&&(e.delta>s.delta||e.direction!==s.direction))h.splice(0);else if(h.length>=15&&e.time-a.time<500&&a.delta-e.delta>=1&&e.delta<=6){const s=c>0?.8:.2;o=e,h.splice(0),l=p((()=>{t.slideToClosest(t.params.speed,!0,void 0,s)}),0)}l||(l=p((()=>{o=e,h.splice(0),t.slideToClosest(t.params.speed,!0,void 0,.5)}),500))}if(a||i("scroll",s),t.params.autoplay&&t.params.autoplayDisableOnInteraction&&t.autoplay.stop(),n===t.minTranslate()||n===t.maxTranslate())return!0}}else{const s={time:u(),delta:Math.abs(c),direction:Math.sign(c),raw:e};h.length>=2&&h.shift();const a=h.length?h[h.length-1]:void 0;if(h.push(s),a?(s.direction!==a.direction||s.delta>a.delta||s.time>a.time+150)&&g(s):g(s),function(e){const s=t.params.mousewheel;if(e.direction<0){if(t.isEnd&&!t.params.loop&&s.releaseOnEdges)return!0}else if(t.isBeginning&&!t.params.loop&&s.releaseOnEdges)return!0;return!1}(s))return!0}return s.preventDefault?s.preventDefault():s.returnValue=!1,!1}function w(e){let s=t.$el;"container"!==t.params.mousewheel.eventsTarget&&(s=d(t.params.mousewheel.eventsTarget)),s[e]("mouseenter",m),s[e]("mouseleave",f),s[e]("wheel",v)}function b(){return t.params.cssMode?(t.wrapperEl.removeEventListener("wheel",v),!0):!t.mousewheel.enabled&&(w("on"),t.mousewheel.enabled=!0,!0)}function x(){return t.params.cssMode?(t.wrapperEl.addEventListener(event,v),!0):!!t.mousewheel.enabled&&(w("off"),t.mousewheel.enabled=!1,!0)}a("init",(()=>{!t.params.mousewheel.enabled&&t.params.cssMode&&x(),t.params.mousewheel.enabled&&b()})),a("destroy",(()=>{t.params.cssMode&&b(),t.mousewheel.enabled&&x()})),Object.assign(t.mousewheel,{enable:b,disable:x})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;function r(e){let s;return e&&(s=d(e),t.params.uniqueNavElements&&"string"==typeof e&&s.length>1&&1===t.$el.find(e).length&&(s=t.$el.find(e))),s}function n(e,s){const a=t.params.navigation;e&&e.length>0&&(e[s?"addClass":"removeClass"](a.disabledClass),e[0]&&"BUTTON"===e[0].tagName&&(e[0].disabled=s),t.params.watchOverflow&&t.enabled&&e[t.isLocked?"addClass":"removeClass"](a.lockClass))}function l(){if(t.params.loop)return;const{$nextEl:e,$prevEl:s}=t.navigation;n(s,t.isBeginning&&!t.params.rewind),n(e,t.isEnd&&!t.params.rewind)}function o(e){e.preventDefault(),(!t.isBeginning||t.params.loop||t.params.rewind)&&(t.slidePrev(),i("navigationPrev"))}function c(e){e.preventDefault(),(!t.isEnd||t.params.loop||t.params.rewind)&&(t.slideNext(),i("navigationNext"))}function p(){const e=t.params.navigation;if(t.params.navigation=F(t,t.originalParams.navigation,t.params.navigation,{nextEl:"swiper-button-next",prevEl:"swiper-button-prev"}),!e.nextEl&&!e.prevEl)return;const s=r(e.nextEl),a=r(e.prevEl);s&&s.length>0&&s.on("click",c),a&&a.length>0&&a.on("click",o),Object.assign(t.navigation,{$nextEl:s,nextEl:s&&s[0],$prevEl:a,prevEl:a&&a[0]}),t.enabled||(s&&s.addClass(e.lockClass),a&&a.addClass(e.lockClass))}function u(){const{$nextEl:e,$prevEl:s}=t.navigation;e&&e.length&&(e.off("click",c),e.removeClass(t.params.navigation.disabledClass)),s&&s.length&&(s.off("click",o),s.removeClass(t.params.navigation.disabledClass))}s({navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock",navigationDisabledClass:"swiper-navigation-disabled"}}),t.navigation={nextEl:null,$nextEl:null,prevEl:null,$prevEl:null},a("init",(()=>{!1===t.params.navigation.enabled?h():(p(),l())})),a("toEdge fromEdge lock unlock",(()=>{l()})),a("destroy",(()=>{u()})),a("enable disable",(()=>{const{$nextEl:e,$prevEl:s}=t.navigation;e&&e[t.enabled?"removeClass":"addClass"](t.params.navigation.lockClass),s&&s[t.enabled?"removeClass":"addClass"](t.params.navigation.lockClass)})),a("click",((e,s)=>{const{$nextEl:a,$prevEl:r}=t.navigation,n=s.target;if(t.params.navigation.hideOnClick&&!d(n).is(r)&&!d(n).is(a)){if(t.pagination&&t.params.pagination&&t.params.pagination.clickable&&(t.pagination.el===n||t.pagination.el.contains(n)))return;let e;a?e=a.hasClass(t.params.navigation.hiddenClass):r&&(e=r.hasClass(t.params.navigation.hiddenClass)),i(!0===e?"navigationShow":"navigationHide"),a&&a.toggleClass(t.params.navigation.hiddenClass),r&&r.toggleClass(t.params.navigation.hiddenClass)}}));const h=()=>{t.$el.addClass(t.params.navigation.navigationDisabledClass),u()};Object.assign(t.navigation,{enable:()=>{t.$el.removeClass(t.params.navigation.navigationDisabledClass),p(),l()},disable:h,update:l,init:p,destroy:u})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const r="swiper-pagination";let n;s({pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:e=>e,formatFractionTotal:e=>e,bulletClass:`${r}-bullet`,bulletActiveClass:`${r}-bullet-active`,modifierClass:`${r}-`,currentClass:`${r}-current`,totalClass:`${r}-total`,hiddenClass:`${r}-hidden`,progressbarFillClass:`${r}-progressbar-fill`,progressbarOppositeClass:`${r}-progressbar-opposite`,clickableClass:`${r}-clickable`,lockClass:`${r}-lock`,horizontalClass:`${r}-horizontal`,verticalClass:`${r}-vertical`,paginationDisabledClass:`${r}-disabled`}}),t.pagination={el:null,$el:null,bullets:[]};let l=0;function o(){return!t.params.pagination.el||!t.pagination.el||!t.pagination.$el||0===t.pagination.$el.length}function c(e,s){const{bulletActiveClass:a}=t.params.pagination;e[s]().addClass(`${a}-${s}`)[s]().addClass(`${a}-${s}-${s}`)}function p(){const e=t.rtl,s=t.params.pagination;if(o())return;const a=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,r=t.pagination.$el;let p;const u=t.params.loop?Math.ceil((a-2*t.loopedSlides)/t.params.slidesPerGroup):t.snapGrid.length;if(t.params.loop?(p=Math.ceil((t.activeIndex-t.loopedSlides)/t.params.slidesPerGroup),p>a-1-2*t.loopedSlides&&(p-=a-2*t.loopedSlides),p>u-1&&(p-=u),p<0&&"bullets"!==t.params.paginationType&&(p=u+p)):p=void 0!==t.snapIndex?t.snapIndex:t.activeIndex||0,"bullets"===s.type&&t.pagination.bullets&&t.pagination.bullets.length>0){const a=t.pagination.bullets;let i,o,u;if(s.dynamicBullets&&(n=a.eq(0)[t.isHorizontal()?"outerWidth":"outerHeight"](!0),r.css(t.isHorizontal()?"width":"height",n*(s.dynamicMainBullets+4)+"px"),s.dynamicMainBullets>1&&void 0!==t.previousIndex&&(l+=p-(t.previousIndex-t.loopedSlides||0),l>s.dynamicMainBullets-1?l=s.dynamicMainBullets-1:l<0&&(l=0)),i=Math.max(p-l,0),o=i+(Math.min(a.length,s.dynamicMainBullets)-1),u=(o+i)/2),a.removeClass(["","-next","-next-next","-prev","-prev-prev","-main"].map((e=>`${s.bulletActiveClass}${e}`)).join(" ")),r.length>1)a.each((e=>{const t=d(e),a=t.index();a===p&&t.addClass(s.bulletActiveClass),s.dynamicBullets&&(a>=i&&a<=o&&t.addClass(`${s.bulletActiveClass}-main`),a===i&&c(t,"prev"),a===o&&c(t,"next"))}));else{const e=a.eq(p),r=e.index();if(e.addClass(s.bulletActiveClass),s.dynamicBullets){const e=a.eq(i),n=a.eq(o);for(let e=i;e<=o;e+=1)a.eq(e).addClass(`${s.bulletActiveClass}-main`);if(t.params.loop)if(r>=a.length){for(let e=s.dynamicMainBullets;e>=0;e-=1)a.eq(a.length-e).addClass(`${s.bulletActiveClass}-main`);a.eq(a.length-s.dynamicMainBullets-1).addClass(`${s.bulletActiveClass}-prev`)}else c(e,"prev"),c(n,"next");else c(e,"prev"),c(n,"next")}}if(s.dynamicBullets){const i=Math.min(a.length,s.dynamicMainBullets+4),r=(n*i-n)/2-u*n,l=e?"right":"left";a.css(t.isHorizontal()?l:"top",`${r}px`)}}if("fraction"===s.type&&(r.find(U(s.currentClass)).text(s.formatFractionCurrent(p+1)),r.find(U(s.totalClass)).text(s.formatFractionTotal(u))),"progressbar"===s.type){let e;e=s.progressbarOpposite?t.isHorizontal()?"vertical":"horizontal":t.isHorizontal()?"horizontal":"vertical";const a=(p+1)/u;let i=1,n=1;"horizontal"===e?i=a:n=a,r.find(U(s.progressbarFillClass)).transform(`translate3d(0,0,0) scaleX(${i}) scaleY(${n})`).transition(t.params.speed)}"custom"===s.type&&s.renderCustom?(r.html(s.renderCustom(t,p+1,u)),i("paginationRender",r[0])):i("paginationUpdate",r[0]),t.params.watchOverflow&&t.enabled&&r[t.isLocked?"addClass":"removeClass"](s.lockClass)}function u(){const e=t.params.pagination;if(o())return;const s=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,a=t.pagination.$el;let r="";if("bullets"===e.type){let i=t.params.loop?Math.ceil((s-2*t.loopedSlides)/t.params.slidesPerGroup):t.snapGrid.length;t.params.freeMode&&t.params.freeMode.enabled&&!t.params.loop&&i>s&&(i=s);for(let s=0;s<i;s+=1)e.renderBullet?r+=e.renderBullet.call(t,s,e.bulletClass):r+=`<${e.bulletElement} class="${e.bulletClass}"></${e.bulletElement}>`;a.html(r),t.pagination.bullets=a.find(U(e.bulletClass))}"fraction"===e.type&&(r=e.renderFraction?e.renderFraction.call(t,e.currentClass,e.totalClass):`<span class="${e.currentClass}"></span> / <span class="${e.totalClass}"></span>`,a.html(r)),"progressbar"===e.type&&(r=e.renderProgressbar?e.renderProgressbar.call(t,e.progressbarFillClass):`<span class="${e.progressbarFillClass}"></span>`,a.html(r)),"custom"!==e.type&&i("paginationRender",t.pagination.$el[0])}function h(){t.params.pagination=F(t,t.originalParams.pagination,t.params.pagination,{el:"swiper-pagination"});const e=t.params.pagination;if(!e.el)return;let s=d(e.el);0!==s.length&&(t.params.uniqueNavElements&&"string"==typeof e.el&&s.length>1&&(s=t.$el.find(e.el),s.length>1&&(s=s.filter((e=>d(e).parents(".swiper")[0]===t.el)))),"bullets"===e.type&&e.clickable&&s.addClass(e.clickableClass),s.addClass(e.modifierClass+e.type),s.addClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),"bullets"===e.type&&e.dynamicBullets&&(s.addClass(`${e.modifierClass}${e.type}-dynamic`),l=0,e.dynamicMainBullets<1&&(e.dynamicMainBullets=1)),"progressbar"===e.type&&e.progressbarOpposite&&s.addClass(e.progressbarOppositeClass),e.clickable&&s.on("click",U(e.bulletClass),(function(e){e.preventDefault();let s=d(this).index()*t.params.slidesPerGroup;t.params.loop&&(s+=t.loopedSlides),t.slideTo(s)})),Object.assign(t.pagination,{$el:s,el:s[0]}),t.enabled||s.addClass(e.lockClass))}function m(){const e=t.params.pagination;if(o())return;const s=t.pagination.$el;s.removeClass(e.hiddenClass),s.removeClass(e.modifierClass+e.type),s.removeClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),t.pagination.bullets&&t.pagination.bullets.removeClass&&t.pagination.bullets.removeClass(e.bulletActiveClass),e.clickable&&s.off("click",U(e.bulletClass))}a("init",(()=>{!1===t.params.pagination.enabled?f():(h(),u(),p())})),a("activeIndexChange",(()=>{(t.params.loop||void 0===t.snapIndex)&&p()})),a("snapIndexChange",(()=>{t.params.loop||p()})),a("slidesLengthChange",(()=>{t.params.loop&&(u(),p())})),a("snapGridLengthChange",(()=>{t.params.loop||(u(),p())})),a("destroy",(()=>{m()})),a("enable disable",(()=>{const{$el:e}=t.pagination;e&&e[t.enabled?"removeClass":"addClass"](t.params.pagination.lockClass)})),a("lock unlock",(()=>{p()})),a("click",((e,s)=>{const a=s.target,{$el:r}=t.pagination;if(t.params.pagination.el&&t.params.pagination.hideOnClick&&r&&r.length>0&&!d(a).hasClass(t.params.pagination.bulletClass)){if(t.navigation&&(t.navigation.nextEl&&a===t.navigation.nextEl||t.navigation.prevEl&&a===t.navigation.prevEl))return;const e=r.hasClass(t.params.pagination.hiddenClass);i(!0===e?"paginationShow":"paginationHide"),r.toggleClass(t.params.pagination.hiddenClass)}}));const f=()=>{t.$el.addClass(t.params.pagination.paginationDisabledClass),t.pagination.$el&&t.pagination.$el.addClass(t.params.pagination.paginationDisabledClass),m()};Object.assign(t.pagination,{enable:()=>{t.$el.removeClass(t.params.pagination.paginationDisabledClass),t.pagination.$el&&t.pagination.$el.removeClass(t.params.pagination.paginationDisabledClass),h(),u(),p()},disable:f,render:u,update:p,init:h,destroy:m})},function(e){let{swiper:t,extendParams:s,on:i,emit:r}=e;const n=a();let l,o,c,u,h=!1,m=null,f=null;function g(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e,rtlTranslate:s,progress:a}=t,{$dragEl:i,$el:r}=e,n=t.params.scrollbar;let l=o,d=(c-o)*a;s?(d=-d,d>0?(l=o-d,d=0):-d+o>c&&(l=c+d)):d<0?(l=o+d,d=0):d+o>c&&(l=c-d),t.isHorizontal()?(i.transform(`translate3d(${d}px, 0, 0)`),i[0].style.width=`${l}px`):(i.transform(`translate3d(0px, ${d}px, 0)`),i[0].style.height=`${l}px`),n.hide&&(clearTimeout(m),r[0].style.opacity=1,m=setTimeout((()=>{r[0].style.opacity=0,r.transition(400)}),1e3))}function v(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e}=t,{$dragEl:s,$el:a}=e;s[0].style.width="",s[0].style.height="",c=t.isHorizontal()?a[0].offsetWidth:a[0].offsetHeight,u=t.size/(t.virtualSize+t.params.slidesOffsetBefore-(t.params.centeredSlides?t.snapGrid[0]:0)),o="auto"===t.params.scrollbar.dragSize?c*u:parseInt(t.params.scrollbar.dragSize,10),t.isHorizontal()?s[0].style.width=`${o}px`:s[0].style.height=`${o}px`,a[0].style.display=u>=1?"none":"",t.params.scrollbar.hide&&(a[0].style.opacity=0),t.params.watchOverflow&&t.enabled&&e.$el[t.isLocked?"addClass":"removeClass"](t.params.scrollbar.lockClass)}function w(e){return t.isHorizontal()?"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientX:e.clientX:"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientY:e.clientY}function b(e){const{scrollbar:s,rtlTranslate:a}=t,{$el:i}=s;let r;r=(w(e)-i.offset()[t.isHorizontal()?"left":"top"]-(null!==l?l:o/2))/(c-o),r=Math.max(Math.min(r,1),0),a&&(r=1-r);const n=t.minTranslate()+(t.maxTranslate()-t.minTranslate())*r;t.updateProgress(n),t.setTranslate(n),t.updateActiveIndex(),t.updateSlidesClasses()}function x(e){const s=t.params.scrollbar,{scrollbar:a,$wrapperEl:i}=t,{$el:n,$dragEl:o}=a;h=!0,l=e.target===o[0]||e.target===o?w(e)-e.target.getBoundingClientRect()[t.isHorizontal()?"left":"top"]:null,e.preventDefault(),e.stopPropagation(),i.transition(100),o.transition(100),b(e),clearTimeout(f),n.transition(0),s.hide&&n.css("opacity",1),t.params.cssMode&&t.$wrapperEl.css("scroll-snap-type","none"),r("scrollbarDragStart",e)}function y(e){const{scrollbar:s,$wrapperEl:a}=t,{$el:i,$dragEl:n}=s;h&&(e.preventDefault?e.preventDefault():e.returnValue=!1,b(e),a.transition(0),i.transition(0),n.transition(0),r("scrollbarDragMove",e))}function E(e){const s=t.params.scrollbar,{scrollbar:a,$wrapperEl:i}=t,{$el:n}=a;h&&(h=!1,t.params.cssMode&&(t.$wrapperEl.css("scroll-snap-type",""),i.transition("")),s.hide&&(clearTimeout(f),f=p((()=>{n.css("opacity",0),n.transition(400)}),1e3)),r("scrollbarDragEnd",e),s.snapOnRelease&&t.slideToClosest())}function C(e){const{scrollbar:s,touchEventsTouch:a,touchEventsDesktop:i,params:r,support:l}=t,o=s.$el;if(!o)return;const d=o[0],c=!(!l.passiveListener||!r.passiveListeners)&&{passive:!1,capture:!1},p=!(!l.passiveListener||!r.passiveListeners)&&{passive:!0,capture:!1};if(!d)return;const u="on"===e?"addEventListener":"removeEventListener";l.touch?(d[u](a.start,x,c),d[u](a.move,y,c),d[u](a.end,E,p)):(d[u](i.start,x,c),n[u](i.move,y,c),n[u](i.end,E,p))}function T(){const{scrollbar:e,$el:s}=t;t.params.scrollbar=F(t,t.originalParams.scrollbar,t.params.scrollbar,{el:"swiper-scrollbar"});const a=t.params.scrollbar;if(!a.el)return;let i=d(a.el);t.params.uniqueNavElements&&"string"==typeof a.el&&i.length>1&&1===s.find(a.el).length&&(i=s.find(a.el)),i.addClass(t.isHorizontal()?a.horizontalClass:a.verticalClass);let r=i.find(`.${t.params.scrollbar.dragClass}`);0===r.length&&(r=d(`<div class="${t.params.scrollbar.dragClass}"></div>`),i.append(r)),Object.assign(e,{$el:i,el:i[0],$dragEl:r,dragEl:r[0]}),a.draggable&&t.params.scrollbar.el&&t.scrollbar.el&&C("on"),i&&i[t.enabled?"removeClass":"addClass"](t.params.scrollbar.lockClass)}function $(){const e=t.params.scrollbar,s=t.scrollbar.$el;s&&s.removeClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),t.params.scrollbar.el&&t.scrollbar.el&&C("off")}s({scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag",scrollbarDisabledClass:"swiper-scrollbar-disabled",horizontalClass:"swiper-scrollbar-horizontal",verticalClass:"swiper-scrollbar-vertical"}}),t.scrollbar={el:null,dragEl:null,$el:null,$dragEl:null},i("init",(()=>{!1===t.params.scrollbar.enabled?S():(T(),v(),g())})),i("update resize observerUpdate lock unlock",(()=>{v()})),i("setTranslate",(()=>{g()})),i("setTransition",((e,s)=>{!function(e){t.params.scrollbar.el&&t.scrollbar.el&&t.scrollbar.$dragEl.transition(e)}(s)})),i("enable disable",(()=>{const{$el:e}=t.scrollbar;e&&e[t.enabled?"removeClass":"addClass"](t.params.scrollbar.lockClass)})),i("destroy",(()=>{$()}));const S=()=>{t.$el.addClass(t.params.scrollbar.scrollbarDisabledClass),t.scrollbar.$el&&t.scrollbar.$el.addClass(t.params.scrollbar.scrollbarDisabledClass),$()};Object.assign(t.scrollbar,{enable:()=>{t.$el.removeClass(t.params.scrollbar.scrollbarDisabledClass),t.scrollbar.$el&&t.scrollbar.$el.removeClass(t.params.scrollbar.scrollbarDisabledClass),T(),v(),g()},disable:S,updateSize:v,setTranslate:g,init:T,destroy:$})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({parallax:{enabled:!1}});const i=(e,s)=>{const{rtl:a}=t,i=d(e),r=a?-1:1,n=i.attr("data-swiper-parallax")||"0";let l=i.attr("data-swiper-parallax-x"),o=i.attr("data-swiper-parallax-y");const c=i.attr("data-swiper-parallax-scale"),p=i.attr("data-swiper-parallax-opacity");if(l||o?(l=l||"0",o=o||"0"):t.isHorizontal()?(l=n,o="0"):(o=n,l="0"),l=l.indexOf("%")>=0?parseInt(l,10)*s*r+"%":l*s*r+"px",o=o.indexOf("%")>=0?parseInt(o,10)*s+"%":o*s+"px",null!=p){const e=p-(p-1)*(1-Math.abs(s));i[0].style.opacity=e}if(null==c)i.transform(`translate3d(${l}, ${o}, 0px)`);else{const e=c-(c-1)*(1-Math.abs(s));i.transform(`translate3d(${l}, ${o}, 0px) scale(${e})`)}},r=()=>{const{$el:e,slides:s,progress:a,snapGrid:r}=t;e.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((e=>{i(e,a)})),s.each(((e,s)=>{let n=e.progress;t.params.slidesPerGroup>1&&"auto"!==t.params.slidesPerView&&(n+=Math.ceil(s/2)-a*(r.length-1)),n=Math.min(Math.max(n,-1),1),d(e).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((e=>{i(e,n)}))}))};a("beforeInit",(()=>{t.params.parallax.enabled&&(t.params.watchSlidesProgress=!0,t.originalParams.watchSlidesProgress=!0)})),a("init",(()=>{t.params.parallax.enabled&&r()})),a("setTranslate",(()=>{t.params.parallax.enabled&&r()})),a("setTransition",((e,s)=>{t.params.parallax.enabled&&function(e){void 0===e&&(e=t.params.speed);const{$el:s}=t;s.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((t=>{const s=d(t);let a=parseInt(s.attr("data-swiper-parallax-duration"),10)||e;0===e&&(a=0),s.transition(a)}))}(s)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();s({zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}}),t.zoom={enabled:!1};let l,o,c,p=1,u=!1;const m={$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},f={isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},g={x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0};let v=1;function w(e){if(e.targetTouches.length<2)return 1;const t=e.targetTouches[0].pageX,s=e.targetTouches[0].pageY,a=e.targetTouches[1].pageX,i=e.targetTouches[1].pageY;return Math.sqrt((a-t)**2+(i-s)**2)}function b(e){const s=t.support,a=t.params.zoom;if(o=!1,c=!1,!s.gestures){if("touchstart"!==e.type||"touchstart"===e.type&&e.targetTouches.length<2)return;o=!0,m.scaleStart=w(e)}m.$slideEl&&m.$slideEl.length||(m.$slideEl=d(e.target).closest(`.${t.params.slideClass}`),0===m.$slideEl.length&&(m.$slideEl=t.slides.eq(t.activeIndex)),m.$imageEl=m.$slideEl.find(`.${a.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${a.containerClass}`),m.maxRatio=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,0!==m.$imageWrapEl.length)?(m.$imageEl&&m.$imageEl.transition(0),u=!0):m.$imageEl=void 0}function x(e){const s=t.support,a=t.params.zoom,i=t.zoom;if(!s.gestures){if("touchmove"!==e.type||"touchmove"===e.type&&e.targetTouches.length<2)return;c=!0,m.scaleMove=w(e)}m.$imageEl&&0!==m.$imageEl.length?(s.gestures?i.scale=e.scale*p:i.scale=m.scaleMove/m.scaleStart*p,i.scale>m.maxRatio&&(i.scale=m.maxRatio-1+(i.scale-m.maxRatio+1)**.5),i.scale<a.minRatio&&(i.scale=a.minRatio+1-(a.minRatio-i.scale+1)**.5),m.$imageEl.transform(`translate3d(0,
450,0) scale(${i.scale})`)):"gesturechange"===e.type&&b(e)}function y(e){const s=t.device,a=t.support,i=t.params.zoom,r=t.zoom;if(!a.gestures){if(!o||!c)return;if("touchend"!==e.type||"touchend"===e.type&&e.changedTouches.length<2&&!s.android)return;o=!1,c=!1}m.$imageEl&&0!==m.$imageEl.length&&(r.scale=Math.max(Math.min(r.scale,m.maxRatio),i.minRatio),m.$imageEl.transition(t.params.speed).transform(`translate3d(0,0,0) scale(${r.scale})`),p=r.scale,u=!1,1===r.scale&&(m.$slideEl=void 0))}function E(e){const s=t.zoom;if(!m.$imageEl||0===m.$imageEl.length)return;if(t.allowClick=!1,!f.isTouched||!m.$slideEl)return;f.isMoved||(f.width=m.$imageEl[0].offsetWidth,f.height=m.$imageEl[0].offsetHeight,f.startX=h(m.$imageWrapEl[0],"x")||0,f.startY=h(m.$imageWrapEl[0],"y")||0,m.slideWidth=m.$slideEl[0].offsetWidth,m.slideHeight=m.$slideEl[0].offsetHeight,m.$imageWrapEl.transition(0));const a=f.width*s.scale,i=f.height*s.scale;if(!(a<m.slideWidth&&i<m.slideHeight)){if(f.minX=Math.min(m.slideWidth/2-a/2,0),f.maxX=-f.minX,f.minY=Math.min(m.slideHeight/2-i/2,0),f.maxY=-f.minY,f.touchesCurrent.x="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,f.touchesCurrent.y="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,!f.isMoved&&!u){if(t.isHorizontal()&&(Math.floor(f.minX)===Math.floor(f.startX)&&f.touchesCurrent.x<f.touchesStart.x||Math.floor(f.maxX)===Math.floor(f.startX)&&f.touchesCurrent.x>f.touchesStart.x))return void(f.isTouched=!1);if(!t.isHorizontal()&&(Math.floor(f.minY)===Math.floor(f.startY)&&f.touchesCurrent.y<f.touchesStart.y||Math.floor(f.maxY)===Math.floor(f.startY)&&f.touchesCurrent.y>f.touchesStart.y))return void(f.isTouched=!1)}e.cancelable&&e.preventDefault(),e.stopPropagation(),f.isMoved=!0,f.currentX=f.touchesCurrent.x-f.touchesStart.x+f.startX,f.currentY=f.touchesCurrent.y-f.touchesStart.y+f.startY,f.currentX<f.minX&&(f.currentX=f.minX+1-(f.minX-f.currentX+1)**.8),f.currentX>f.maxX&&(f.currentX=f.maxX-1+(f.currentX-f.maxX+1)**.8),f.currentY<f.minY&&(f.currentY=f.minY+1-(f.minY-f.currentY+1)**.8),f.currentY>f.maxY&&(f.currentY=f.maxY-1+(f.currentY-f.maxY+1)**.8),g.prevPositionX||(g.prevPositionX=f.touchesCurrent.x),g.prevPositionY||(g.prevPositionY=f.touchesCurrent.y),g.prevTime||(g.prevTime=Date.now()),g.x=(f.touchesCurrent.x-g.prevPositionX)/(Date.now()-g.prevTime)/2,g.y=(f.touchesCurrent.y-g.prevPositionY)/(Date.now()-g.prevTime)/2,Math.abs(f.touchesCurrent.x-g.prevPositionX)<2&&(g.x=0),Math.abs(f.touchesCurrent.y-g.prevPositionY)<2&&(g.y=0),g.prevPositionX=f.touchesCurrent.x,g.prevPositionY=f.touchesCurrent.y,g.prevTime=Date.now(),m.$imageWrapEl.transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`)}}function C(){const e=t.zoom;m.$slideEl&&t.previousIndex!==t.activeIndex&&(m.$imageEl&&m.$imageEl.transform("translate3d(0,0,0) scale(1)"),m.$imageWrapEl&&m.$imageWrapEl.transform("translate3d(0,0,0)"),e.scale=1,p=1,m.$slideEl=void 0,m.$imageEl=void 0,m.$imageWrapEl=void 0)}function T(e){const s=t.zoom,a=t.params.zoom;if(m.$slideEl||(e&&e.target&&(m.$slideEl=d(e.target).closest(`.${t.params.slideClass}`)),m.$slideEl||(t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.$slideEl=t.$wrapperEl.children(`.${t.params.slideActiveClass}`):m.$slideEl=t.slides.eq(t.activeIndex)),m.$imageEl=m.$slideEl.find(`.${a.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${a.containerClass}`)),!m.$imageEl||0===m.$imageEl.length||!m.$imageWrapEl||0===m.$imageWrapEl.length)return;let i,r,l,o,c,u,h,g,v,w,b,x,y,E,C,T,$,S;t.params.cssMode&&(t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.touchAction="none"),m.$slideEl.addClass(`${a.zoomedSlideClass}`),void 0===f.touchesStart.x&&e?(i="touchend"===e.type?e.changedTouches[0].pageX:e.pageX,r="touchend"===e.type?e.changedTouches[0].pageY:e.pageY):(i=f.touchesStart.x,r=f.touchesStart.y),s.scale=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,p=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,e?($=m.$slideEl[0].offsetWidth,S=m.$slideEl[0].offsetHeight,l=m.$slideEl.offset().left+n.scrollX,o=m.$slideEl.offset().top+n.scrollY,c=l+$/2-i,u=o+S/2-r,v=m.$imageEl[0].offsetWidth,w=m.$imageEl[0].offsetHeight,b=v*s.scale,x=w*s.scale,y=Math.min($/2-b/2,0),E=Math.min(S/2-x/2,0),C=-y,T=-E,h=c*s.scale,g=u*s.scale,h<y&&(h=y),h>C&&(h=C),g<E&&(g=E),g>T&&(g=T)):(h=0,g=0),m.$imageWrapEl.transition(300).transform(`translate3d(${h}px, ${g}
45px,0)`),m.$imageEl.transition(300).transform(`translate3d(0,0,0) scale(${s.scale})`)}function $(){const e=t.zoom,s=t.params.zoom;m.$slideEl||(t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.$slideEl=t.$wrapperEl.children(`.${t.params.slideActiveClass}`):m.$slideEl=t.slides.eq(t.activeIndex),m.$imageEl=m.$slideEl.find(`.${s.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${s.containerClass}`)),m.$imageEl&&0!==m.$imageEl.length&&m.$imageWrapEl&&0!==m.$imageWrapEl.length&&(t.params.cssMode&&(t.wrapperEl.style.overflow="",t.wrapperEl.style.touchAction=""),e.scale=1,p=1,m.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),m.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),m.$slideEl.removeClass(`${s.zoomedSlideClass}`),m.$slideEl=void 0)}function S(e){const s=t.zoom;s.scale&&1!==s.scale?$():T(e)}function M(){const e=t.support;return{passiveListener:!("touchstart"!==t.touchEvents.start||!e.passiveListener||!t.params.passiveListeners)&&{passive:!0,capture:!1},activeListenerWithCapture:!e.passiveListener||{passive:!1,capture:!0}}}function P(){return`.${t.params.slideClass}`}function k(e){const{passiveListener:s}=M(),a=P();t.$wrapperEl[e]("gesturestart",a,b,s),t.$wrapperEl[e]("gesturechange",a,x,s),t.$wrapperEl[e]("gestureend",a,y,s)}function z(){l||(l=!0,k("on"))}function L(){l&&(l=!1,k("off"))}function O(){const e=t.zoom;if(e.enabled)return;e.enabled=!0;const s=t.support,{passiveListener:a,activeListenerWithCapture:i}=M(),r=P();s.gestures?(t.$wrapperEl.on(t.touchEvents.start,z,a),t.$wrapperEl.on(t.touchEvents.end,L,a)):"touchstart"===t.touchEvents.start&&(t.$wrapperEl.on(t.touchEvents.start,r,b,a),t.$wrapperEl.on(t.touchEvents.move,r,x,i),t.$wrapperEl.on(t.touchEvents.end,r,y,a),t.touchEvents.cancel&&t.$wrapperEl.on(t.touchEvents.cancel,r,y,a)),t.$wrapperEl.on(t.touchEvents.move,`.${t.params.zoom.containerClass}`,E,i)}function I(){const e=t.zoom;if(!e.enabled)return;const s=t.support;e.enabled=!1;const{passiveListener:a,activeListenerWithCapture:i}=M(),r=P();s.gestures?(t.$wrapperEl.off(t.touchEvents.start,z,a),t.$wrapperEl.off(t.touchEvents.end,L,a)):"touchstart"===t.touchEvents.start&&(t.$wrapperEl.off(t.touchEvents.start,r,b,a),t.$wrapperEl.off(t.touchEvents.move,r,x,i),t.$wrapperEl.off(t.touchEvents.end,r,y,a),t.touchEvents.cancel&&t.$wrapperEl.off(t.touchEvents.cancel,r,y,a)),t.$wrapperEl.off(t.touchEvents.move,`.${t.params.zoom.containerClass}`,E,i)}Object.defineProperty(t.zoom,"scale",{get:()=>v,set(e){if(v!==e){const t=m.$imageEl?m.$imageEl[0]:void 0,s=m.$slideEl?m.$slideEl[0]:void 0;i("zoomChange",e,t,s)}v=e}}),a("init",(()=>{t.params.zoom.enabled&&O()})),a("destroy",(()=>{I()})),a("touchStart",((e,s)=>{t.zoom.enabled&&function(e){const s=t.device;m.$imageEl&&0!==m.$imageEl.length&&(f.isTouched||(s.android&&e.cancelable&&e.preventDefault(),f.isTouched=!0,f.touchesStart.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,f.touchesStart.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY))}(s)})),a("touchEnd",((e,s)=>{t.zoom.enabled&&function(){const e=t.zoom;if(!m.$imageEl||0===m.$imageEl.length)return;if(!f.isTouched||!f.isMoved)return f.isTouched=!1,void(f.isMoved=!1);f.isTouched=!1,f.isMoved=!1;let s=300,a=300;const i=g.x*s,r=f.currentX+i,n=g.y*a,l=f.currentY+n;0!==g.x&&(s=Math.abs((r-f.currentX)/g.x)),0!==g.y&&(a=Math.abs((l-f.currentY)/g.y));const o=Math.max(s,a);f.currentX=r,f.currentY=l;const d=f.width*e.scale,c=f.height*e.scale;f.minX=Math.min(m.slideWidth/2-d/2,0),f.maxX=-f.minX,f.minY=Math.min(m.slideHeight/2-c/2,0),f.maxY=-f.minY,f.currentX=Math.max(Math.min(f.currentX,f.maxX),f.minX),f.currentY=Math.max(Math.min(f.currentY,f.maxY),f.minY),m.$imageWrapEl.transition(o).transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`)}()})),a("doubleTap",((e,s)=>{!t.animating&&t.params.zoom.enabled&&t.zoom.enabled&&t.params.zoom.toggle&&S(s)})),a("transitionEnd",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&C()})),a("slideChange",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&t.params.cssMode&&C()})),Object.assign(t.zoom,{enable:O,disable:I,in:T,out:$,toggle:S})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;s({lazy:{checkInView:!1,enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,scrollingElement:"",elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}}),t.lazy={};let n=!1,l=!1;function o(e,s){void 0===s&&(s=!0);const a=t.params.lazy;if(void 0===e)return;if(0===t.slides.length)return;const r=t.virtual&&t.params.virtual.enabled?t.$wrapperEl.children(`.${t.params.slideClass}[data-swiper-slide-index="${e}"]`):t.slides.eq(e),n=r.find(`.${a.elementClass}:not(.${a.loadedClass}):not(.${a.loadingClass})`);!r.hasClass(a.elementClass)||r.hasClass(a.loadedClass)||r.hasClass(a.loadingClass)||n.push(r[0]),0!==n.length&&n.each((e=>{const n=d(e);n.addClass(a.loadingClass);const l=n.attr("data-background"),c=n.attr("data-src"),p=n.attr("data-srcset"),u=n.attr("data-sizes"),h=n.parent("picture");t.loadImage(n[0],c||l,p,u,!1,(()=>
vendor: 7,199 bytes, line 45
45{if(null!=t&&t&&(!t||t.params)&&!t.destroyed){if(l?(n.css("background-image",`url("${l}")`),n.removeAttr("data-background")):(p&&(n.attr("srcset",p),n.removeAttr("data-srcset")),u&&(n.attr("sizes",u),n.removeAttr("data-sizes")),h.length&&h.children("source").each((e=>{const t=d(e);t.attr("data-srcset")&&(t.attr("srcset",t.attr("data-srcset")),t.removeAttr("data-srcset"))})),c&&(n.attr("src",c),n.removeAttr("data-src"))),n.addClass(a.loadedClass).removeClass(a.loadingClass),r.find(`.${a.preloaderClass}`).remove(),t.params.loop&&s){const e=r.attr("data-swiper-slide-index");if(r.hasClass(t.params.slideDuplicateClass)){o(t.$wrapperEl.children(`[data-swiper-slide-index="${e}"]:not(.${t.params.slideDuplicateClass})`).index(),!1)}else{o(t.$wrapperEl.children(`.${t.params.slideDuplicateClass}[data-swiper-slide-index="${e}"]`).index(),!1)}}i("lazyImageReady",r[0],n[0]),t.params.autoHeight&&t.updateAutoHeight()}})),i("lazyImageLoad",r[0],n[0])}))}function c(){const{$wrapperEl:e,params:s,slides:a,activeIndex:i}=t,r=t.virtual&&s.virtual.enabled,n=s.lazy;let c=s.slidesPerView;function p(t){if(r){if(e.children(`.${s.slideClass}[data-swiper-slide-index="${t}"]`).length)return!0}else if(a[t])return!0;return!1}function u(e){return r?d(e).attr("data-swiper-slide-index"):d(e).index()}if("auto"===c&&(c=0),l||(l=!0),t.params.watchSlidesProgress)e.children(`.${s.slideVisibleClass}`).each((e=>{o(r?d(e).attr("data-swiper-slide-index"):d(e).index())}));else if(c>1)for(let e=i;e<i+c;e+=1)p(e)&&o(e);else o(i);if(n.loadPrevNext)if(c>1||n.loadPrevNextAmount&&n.loadPrevNextAmount>1){const e=n.loadPrevNextAmount,t=Math.ceil(c),s=Math.min(i+t+Math.max(e,t),a.length),r=Math.max(i-Math.max(t,e),0);for(let e=i+t;e<s;e+=1)p(e)&&o(e);for(let e=r;e<i;e+=1)p(e)&&o(e)}else{const t=e.children(`.${s.slideNextClass}`);t.length>0&&o(u(t));const a=e.children(`.${s.slidePrevClass}`);a.length>0&&o(u(a))}}function p(){const e=r();if(!t||t.destroyed)return;const s=t.params.lazy.scrollingElement?d(t.params.lazy.scrollingElement):d(e),a=s[0]===e,i=a?e.innerWidth:s[0].offsetWidth,l=a?e.innerHeight:s[0].offsetHeight,o=t.$el.offset(),{rtlTranslate:u}=t;let h=!1;u&&(o.left-=t.$el[0].scrollLeft);const m=[[o.left,o.top],[o.left+t.width,o.top],[o.left,o.top+t.height],[o.left+t.width,o.top+t.height]];for(let e=0;e<m.length;e+=1){const t=m[e];if(t[0]>=0&&t[0]<=i&&t[1]>=0&&t[1]<=l){if(0===t[0]&&0===t[1])continue;h=!0}}const f=!("touchstart"!==t.touchEvents.start||!t.support.passiveListener||!t.params.passiveListeners)&&{passive:!0,capture:!1};h?(c(),s.off("scroll",p,f)):n||(n=!0,s.on("scroll",p,f))}a("beforeInit",(()=>{t.params.lazy.enabled&&t.params.preloadImages&&(t.params.preloadImages=!1)})),a("init",(()=>{t.params.lazy.enabled&&(t.params.lazy.checkInView?p():c())})),a("scroll",(()=>{t.params.freeMode&&t.params.freeMode.enabled&&!t.params.freeMode.sticky&&c()})),a("scrollbarDragMove resize _freeModeNoMomentumRelease",(()=>{t.params.lazy.enabled&&(t.params.lazy.checkInView?p():c())})),a("transitionStart",(()=>{t.params.lazy.enabled&&(t.params.lazy.loadOnTransitionStart||!t.params.lazy.loadOnTransitionStart&&!l)&&(t.params.lazy.checkInView?p():c())})),a("transitionEnd",(()=>{t.params.lazy.enabled&&!t.params.lazy.loadOnTransitionStart&&(t.params.lazy.checkInView?p():c())})),a("slideChange",(()=>{const{lazy:e,cssMode:s,watchSlidesProgress:a,touchReleaseOnEdges:i,resistanceRatio:r}=t.params;e.enabled&&(s||a&&(i||0===r))&&c()})),a("destroy",(()=>{t.$el&&t.$el.find(`.${t.params.lazy.loadingClass}`).removeClass(t.params.lazy.loadingClass)})),Object.assign(t.lazy,{load:c,loadInSlide:o})},function(e){let{swiper:t,extendParams:s,on:a}=e;function i(e,t){const s=function(){let e,t,s;return(a,i)=>{for(t=-1,e=a.length;e-t>1;)s=e+t>>1,a[s]<=i?t=s:e=s;return e}}();let a,i;return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(i=s(this.x,e),a=i-1,(e-this.x[a])*(this.y[i]-this.y[a])/(this.x[i]-this.x[a])+this.y[a]):0},this}function r(){t.controller.control&&t.controller.spline&&(t.controller.spline=void 0,delete t.controller.spline)}s({controller:{control:void 0,inverse:!1,by:"slide"}}),t.controller={control:void 0},a("beforeInit",(()=>{t.controller.control=t.params.controller.control})),a("update",(()=>{r()})),a("resize",(()=>{r()})),a("observerUpdate",(()=>{r()})),a("setTranslate",((e,s,a)=>{t.controller.control&&t.controller.setTranslate(s,a)})),a("setTransition",((e,s,a)=>{t.controller.control&&t.controller.setTransition(s,a)})),Object.assign(t.controller,{setTranslate:function(e,s){const a=t.controller.control;let r,n;const l=t.constructor;function o(e){const s=t.rtlTranslate?-t.translate:t.translate;"slide"===t.params.controller.by&&(!function(e){t.controller.spline||(t.controller.spline=t.params.loop?new i(t.slidesGrid,e.slidesGrid):new i(t.snapGrid,e.snapGrid))}(e),n=-t.controller.spline.interpolate(-s)),n&&"container"!==t.params.controller.by||(r=(e.maxTranslate()-e.minTranslate())/(t.maxTranslate()-t.minTranslate()),n=(s-t.minTranslate())*r+e.minTranslate()),t.params.controller.inverse&&(n=e.maxTranslate()-n),e.updateProgress(n),e.setTranslate(n,t),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(a))for(let e=0;e<a.length;e+=1)a[e]!==s&&a[e]instanceof l&&o(a[e]);else a instanceof l&&s!==a&&o(a)},setTransition:function(e,s){const a=t.constructor,i=t.controller.control;let r;function n(s){s.setTransition(e,t),0!==e&&(s.transitionStart(),s.params.autoHeight&&p((()=>{s.updateAutoHeight()})),s.$wrapperEl.transitionEnd((()=>{i&&(s.params.loop&&"slide"===t.params.controller.by&&s.loopFix(),s.transitionEnd())})))}if(Array.isArray(i))for(r=0;r<i.length;r+=1)i[r]!==s&&i[r]instanceof a&&n(i[r]);else i instanceof a&&s!==i&&n(i)}})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}",slideLabelMessage:"{{index}} / {{slidesLength}}",containerMessage:null,containerRoleDescriptionMessage:null,itemRoleDescriptionMessage:null,slideRole:"group",id:null}}),t.a11y={clicked:!1};let i=null;function r(e){const t=i;0!==t.length&&(t.html(""),t.html(e))}function n(e){e.attr("tabIndex","0")}function l(e){e.attr("tabIndex","-1")}function o(e,t){e.attr("role",t)}function c(e,t){e.attr("aria-roledescription",t)}function p(e,t){e.attr("aria-label",t)}function u(e){e.attr("aria-disabled",!0)}function h(e){e.attr("aria-disabled",!1)}function m(e){if(13!==e.keyCode&&32!==e.keyCode)return;const s=t.params.a11y,a=d(e.target);t.navigation&&t.navigation.$nextEl&&a.is(t.navigation.$nextEl)&&(t.isEnd&&!t.params.loop||t.slideNext(),t.isEnd?r(s.lastSlideMessage):r(s.nextSlideMessage)),t.navigation&&t.navigation.$prevEl&&a.is(t.navigation.$prevEl)&&(t.isBeginning&&!t.params.loop||t.slidePrev(),t.isBeginning?r(s.firstSlideMessage):r(s.prevSlideMessage)),t.pagination&&a.is(U(t.params.pagination.bulletClass))&&a[0].click()}function f(){return t.pagination&&t.pagination.bullets&&t.pagination.bullets.length}function g(){return f()&&t.params.pagination.clickable}const v=(e,t,s)=>
45{n(e),"BUTTON"!==e[0].tagName&&(o(e,"button"),e.on("keydown",m)),p(e,s),function(e,t){e.attr("aria-controls",t)}(e,t)},w=()=>{t.a11y.clicked=!0},b=()=>{requestAnimationFrame((()=>{requestAnimationFrame((()=>{t.destroyed||(t.a11y.clicked=!1)}))}))},x=e=>{if(t.a11y.clicked)return;const s=e.target.closest(`.${t.params.slideClass}`);if(!s||!t.slides.includes(s))return;const a=t.slides.indexOf(s)===t.activeIndex,i=t.params.watchSlidesProgress&&t.visibleSlides&&t.visibleSlides.includes(s);a||i||e.sourceCapabilities&&e.sourceCapabilities.firesTouchEvents||(t.isHorizontal()?t.el.scrollLeft=0:t.el.scrollTop=0,t.slideTo(t.slides.indexOf(s),0))},y=()=>{const e=t.params.a11y;e.itemRoleDescriptionMessage&&c(d(t.slides),e.itemRoleDescriptionMessage),e.slideRole&&o(d(t.slides),e.slideRole);const s=t.params.loop?t.slides.filter((e=>!e.classList.contains(t.params.slideDuplicateClass))).length:t.slides.length;e.slideLabelMessage&&t.slides.each(((a,i)=>{const r=d(a),n=t.params.loop?parseInt(r.attr("data-swiper-slide-index"),10):i;p(r,e.slideLabelMessage.replace(/\{\{index\}\}/,n+1).replace(/\{\{slidesLength\}\}/,s))}))},E=()=>{const e=t.params.a11y;t.$el.append(i);const s=t.$el;e.containerRoleDescriptionMessage&&c(s,e.containerRoleDescriptionMessage),e.containerMessage&&p(s,e.containerMessage);const a=t.$wrapperEl,r=e.id||a.attr("id")||`swiper-wrapper-${n=16,void 0===n&&(n=16),"x".repeat(n).replace(/x/g,(()=>Math.round(16*Math.random()).toString(16)))}`;var n;const l=t.params.autoplay&&t.params.autoplay.enabled?"off":"polite";var o;let d,u;o=r,a.attr("id",o),function(e,t){e.attr("aria-live",t)}(a,l),y(),t.navigation&&t.navigation.$nextEl&&(d=t.navigation.$nextEl),t.navigation&&t.navigation.$prevEl&&(u=t.navigation.$prevEl),d&&d.length&&v(d,r,e.nextSlideMessage),u&&u.length&&v(u,r,e.prevSlideMessage),g()&&t.pagination.$el.on("keydown",U(t.params.pagination.bulletClass),m),t.$el.on("focus",x,!0),t.$el.on("pointerdown",w,!0),t.$el.on("pointerup",b,!0)};a("beforeInit",(()=>{i=d(`<span class="${t.params.a11y.notificationClass}" aria-live="assertive" aria-atomic="true"></span>`)})),a("afterInit",(()=>{t.params.a11y.enabled&&E()})),a("slidesLengthChange snapGridLengthChange slidesGridLengthChange",(()=>{t.params.a11y.enabled&&y()})),a("fromEdge toEdge afterInit lock unlock",(()=>{t.params.a11y.enabled&&function(){if(t.params.loop||t.params.rewind||!t.navigation)return;const{$nextEl:e,$prevEl:s}=t.navigation;s&&s.length>0&&(t.isBeginning?(u(s),l(s)):(h(s),n(s))),e&&e.length>0&&(t.isEnd?(u(e),l(e)):(h(e),n(e)))}()})),a("paginationUpdate",(()=>{t.params.a11y.enabled&&function(){const e=t.params.a11y;f()&&t.pagination.bullets.each((s=>{const a=d(s);t.params.pagination.clickable&&(n(a),t.params.pagination.renderBullet||(o(a,"button"),p(a,e.paginationBulletMessage.replace(/\{\{index\}\}/,a.index()+1)))),a.is(`.${t.params.pagination.bulletActiveClass}`)?a.attr("aria-current","true"):a.removeAttr("aria-current")}))}()})),a("destroy",(()=>{t.params.a11y.enabled&&function(){let e,s;i&&i.length>0&&i.remove(),t.navigation&&t.navigation.$nextEl&&(e=t.navigation.$nextEl),t.navigation&&t.navigation.$prevEl&&(s=t.navigation.$prevEl),e&&e.off("keydown",m),s&&s.off("keydown",m),g()&&t.pagination.$el.off("keydown",U(t.params.pagination.bulletClass),m),t.$el.off("focus",x,!0),t.$el.off("pointerdown",w,!0),t.$el.off("pointerup",b,!0)}()}))},function(e){let{swiper:t,extendParams:s,on:a}=e;s({history:{enabled:!1,root:"",replaceState:!1,key:"slides",keepQuery:!1}});let i=!1,n={};const l=e=>e.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,""),o=e=>{const t=r();let s;s=e?new URL(e):t.location;const a=s.pathname.slice(1).split("/").filter((e=>""!==e)),i=a.length;return{key:a[i-2],value:a[i-1]}},d=(e,s)=>{const a=r();if(!i||!t.params.history.enabled)return;let n;n=t.params.url?new URL(t.params.url):a.location;const o=t.slides.eq(s);let d=l(o.attr("data-history"));if(t.params.history.root.length>0){let s=t.params.history.root;"/"===s[s.length-1]&&(s=s.slice(0,s.length-1)),d=`${s}/${e}/${d}`}else n.pathname.includes(e)||(d=`${e}/${d}
45`);t.params.history.keepQuery&&(d+=n.search);const c=a.history.state;c&&c.value===d||(t.params.history.replaceState?a.history.replaceState({value:d},null,d):a.history.pushState({value:d},null,d))},c=(e,s,a)=>{if(s)for(let i=0,r=t.slides.length;i<r;i+=1){const r=t.slides.eq(i);if(l(r.attr("data-history"))===s&&!r.hasClass(t.params.slideDuplicateClass)){const s=r.index();t.slideTo(s,e,a)}}else t.slideTo(0,e,a)},p=()=>{n=o(t.params.url),c(t.params.speed,n.value,!1)};a("init",(()=>{t.params.history.enabled&&(()=>{const e=r();if(t.params.history){if(!e.history||!e.history.pushState)return t.params.history.enabled=!1,void(t.params.hashNavigation.enabled=!0);i=!0,n=o(t.params.url),(n.key||n.value)&&(c(0,n.value,t.params.runCallbacksOnInit),t.params.history.replaceState||e.addEventListener("popstate",p))}})()})),a("destroy",(()=>{t.params.history.enabled&&(()=>{const e=r();t.params.history.replaceState||e.removeEventListener("popstate",p)})()})),a("transitionEnd _freeModeNoMomentumRelease",(()=>{i&&d(t.params.history.key,t.activeIndex)})),a("slideChange",(()=>{i&&t.params.cssMode&&d(t.params.history.key,t.activeIndex)}))},function(e){let{swiper:t,extendParams:s,emit:i,on:n}=e,l=!1;const o=a(),c=r();s({hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}});const p=()=>{i("hashChange");const e=o.location.hash.replace("#","");if(e!==t.slides.eq(t.activeIndex).attr("data-hash")){const s=t.$wrapperEl.children(`.${t.params.slideClass}[data-hash="${e}"]`).index();if(void 0===s)return;t.slideTo(s)}},u=()=>{if(l&&t.params.hashNavigation.enabled)if(t.params.hashNavigation.replaceState&&c.history&&c.history.replaceState)c.history.replaceState(null,null,`#${t.slides.eq(t.activeIndex).attr("data-hash")}`||""),i("hashSet");else{const e=t.slides.eq(t.activeIndex),s=e.attr("data-hash")||e.attr("data-history");o.location.hash=s||"",i("hashSet")}};n("init",(()=>{t.params.hashNavigation.enabled&&(()=>{if(!t.params.hashNavigation.enabled||t.params.history&&t.params.history.enabled)return;l=!0;const e=o.location.hash.replace("#","");if(e){const s=0;for(let a=0,i=t.slides.length;a<i;a+=1){const i=t.slides.eq(a);if((i.attr("data-hash")||i.attr("data-history"))===e&&!i.hasClass(t.params.slideDuplicateClass)){const e=i.index();t.slideTo(e,s,t.params.runCallbacksOnInit,!0)}}}t.params.hashNavigation.watchState&&d(c).on("hashchange",p)})()})),n("destroy",(()=>{t.params.hashNavigation.enabled&&t.params.hashNavigation.watchState&&d(c).off("hashchange",p)})),n("transitionEnd _freeModeNoMomentumRelease",(()=>{l&&u()})),n("slideChange",(()=>{l&&t.params.cssMode&&u()}))},function(e){let t,{swiper:s,extendParams:i,on:r,emit:n}=e;function l(){if(!s.size)return s.autoplay.running=!1,void(s.autoplay.paused=!1);const e=s.slides.eq(s.activeIndex);let a=s.params.autoplay.delay;e.attr("data-swiper-autoplay")&&(a=e.attr("data-swiper-autoplay")||s.params.autoplay.delay),clearTimeout(t),t=p((()=>{let e;s.params.autoplay.reverseDirection?s.params.loop?(s.loopFix(),e=s.slidePrev(s.params.speed,!0,!0),n("autoplay")):s.isBeginning?s.params.autoplay.stopOnLastSlide?d():(e=s.slideTo(s.slides.length-1,s.params.speed,!0,!0),n("autoplay")):(e=s.slidePrev(s.params.speed,!0,!0),n("autoplay")):s.params.loop?(s.loopFix(),e=s.slideNext(s.params.speed,!0,!0),n("autoplay")):s.isEnd?s.params.autoplay.stopOnLastSlide?d():(e=s.slideTo(0,s.params.speed,!0,!0),n("autoplay")):(e=s.slideNext(s.params.speed,!0,!0),n("autoplay")),(s.params.cssMode&&s.autoplay.running||!1===e)&&l()}),a)}function o(){return void 0===t&&(!s.autoplay.running&&(s.autoplay.running=!0,n("autoplayStart"),l(),!0))}function d(){return!!s.autoplay.running&&(void 0!==t&&(t&&(clearTimeout(t),t=void 0),s.autoplay.running=!1,n("autoplayStop"),!0))}function c(e){s.autoplay.running&&(s.autoplay.paused||(t&&clearTimeout(t),s.autoplay.paused=!0,0!==e&&s.params.autoplay.waitForTransition?["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].addEventListener(e,h)})):(s.autoplay.paused=!1,l())))}function u(){const e=a();"hidden"===e.visibilityState&&s.autoplay.running&&c(),"visible"===e.visibilityState&&s.autoplay.paused&&(l(),s.autoplay.paused=!1)}function h(e){s&&!s.destroyed&&s.$wrapperEl&&e.target===s.$wrapperEl[0]&&(["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].removeEventListener(e,h)})),s.autoplay.paused=!1,s.autoplay.running?l():d())}function m(){s.params.autoplay.disableOnInteraction?d():(n("autoplayPause"),c()),["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].removeEventListener(e,h)}))}function f(){s.params.autoplay.disableOnInteraction||(s.autoplay.paused=!1,n("autoplayResume"),l())}s.autoplay={running:!1,paused:!1},i({autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1,pauseOnMouseEnter:!1}}),r("init",(()=>{if(s.params.autoplay.enabled){o();a().addEventListener("visibilitychange",u),s.params.autoplay.pauseOnMouseEnter&&(s.$el.on("mouseenter",m),s.$el.on("mouseleave",f))}})),r("beforeTransitionStart",((e,t,a)=>{s.autoplay.running&&(a||!s.params.autoplay.disableOnInteraction?s.autoplay.pause(t):d())})),r("sliderFirstMove",(()=>{s.autoplay.running&&(s.params.autoplay.disableOnInteraction?d():c())})),r("touchEnd",(()=>{s.params.cssMode&&s.autoplay.paused&&!s.params.autoplay.disableOnInteraction&&l()})),r("destroy",(()=>{s.$el.off("mouseenter",m),s.$el.off("mouseleave",f),s.autoplay.running&&d();a().removeEventListener("visibilitychange",u)})),Object.assign(s.autoplay,{pause:c,run:l,start:o,stop:d})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({thumbs:{swiper:null,multipleActiveThumbs:!0,autoScrollOffset:0,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-thumbs"}});let i=!1,r=!1;function n(){const e=t.thumbs.swiper;if(!e||e.destroyed)return;const s=e.clickedIndex,a=e.clickedSlide;if(a&&d(a).hasClass(t.params.thumbs.slideThumbActiveClass))return;if(null==s)return;let i;if(i=e.params.loop?parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"),10):s,t.params.loop){let e=t.activeIndex;t.slides.eq(e).hasClass(t.params.slideDuplicateClass)&&(t.loopFix(),t._clientLeft=t.$wrapperEl[0].clientLeft,e=t.activeIndex);const s=t.slides.eq(e).prevAll(`[data-swiper-slide-index="${i}"]`).eq(0).index(),a=t.slides.eq(e).nextAll(`[data-swiper-slide-index="${i}"]`).eq(0).index();i=void 0===s?a:void 0===a?s:a-e<e-s?a:s}t.slideTo(i)}function l(){const{thumbs:e}=t.params;if(i)return!1;i=!0;const s=t.constructor;if(e.swiper instanceof s)t.thumbs.swiper=e.swiper,Object.assign(t.thumbs.swiper.originalParams,{watchSlidesProgress:!0,slideToClickedSlide:!1}),Object.assign(t.thumbs.swiper.params,{watchSlidesProgress:!0,slideToClickedSlide:!1});else if(m(e.swiper)){const a=Object.assign({},e.swiper);Object.assign(a,{watchSlidesProgress:!0,slideToClickedSlide:!1}),t.thumbs.swiper=new s(a),r=!0}return t.thumbs.swiper.$el.addClass(t.params.thumbs.thumbsContainerClass),t.thumbs.swiper.on("tap",n),!0}function o(e){const s=t.thumbs.swiper;if(!s||s.destroyed)return;const a="auto"===s.params.slidesPerView?s.slidesPerViewDynamic():s.params.slidesPerView;let i=1;const r=t.params.thumbs.slideThumbActiveClass;if(t.params.slidesPerView>1&&!t.params.centeredSlides&&(i=t.params.slidesPerView),t.params.thumbs.multipleActiveThumbs||(i=1),i=Math.floor(i),s.slides.removeClass(r),s.params.loop||s.params.virtual&&s.params.virtual.enabled)for(let e=0;e<i;e+=1)s.$wrapperEl.children(`[data-swiper-slide-index="${t.realIndex+e}"]`).addClass(r);else for(let e=0;e<i;e+=1)s.slides.eq(t.realIndex+e).addClass(r);const n=t.params.thumbs.autoScrollOffset,l=n&&!s.params.loop;if(t.realIndex!==s.realIndex||l){let i,r,o=s.activeIndex;if(s.params.loop){s.slides.eq(o).hasClass(s.params.slideDuplicateClass)&&(s.loopFix(),s._clientLeft=s.$wrapperEl[0].clientLeft,o=s.activeIndex);const e=s.slides.eq(o).prevAll(`[data-swiper-slide-index="${t.realIndex}"]`).eq(0).index(),a=s.slides.eq(o).nextAll(`[data-swiper-slide-index="${t.realIndex}"]`).eq(0).index();i=void 0===e?a:void 0===a?e:a-o==o-e?s.params.slidesPerGroup>1?a:o:a-o<o-e?a:e,r=t.activeIndex>t.previousIndex?"next":"prev"}else i=t.realIndex,r=i>t.previousIndex?"next":"prev";l&&(i+="next"===r?n:-1*n),s.visibleSlidesIndexes&&s.visibleSlidesIndexes.indexOf(i)<0&&(s.params.centeredSlides?i=i>o?i-Math.floor(a/2)+1:i+Math.floor(a/2)-1:i>o&&s.params.slidesPerGroup,s.slideTo(i,e?0:void 0))}}t.thumbs={swiper:null},a("beforeInit",(()=>{const{thumbs:e}=t.params;e&&e.swiper&&(l(),o(!0))})),a("slideChange update resize observerUpdate",(()=>{o()})),a("setTransition",((e,s)=>{const a=t.thumbs.swiper;a&&!a.destroyed&&a.setTransition(s)})),a("beforeDestroy",(()=>{const e=t.thumbs.swiper;e&&!e.destroyed&&r&&e.destroy()})),Object.assign(t.thumbs,{init:l,update:o})},function(e){let{swiper:t,extendParams:s,emit:a,once:i}=e;s({freeMode:{enabled:!1,momentum:!0,momentumRatio:1,momentumBounce:!0,momentumBounceRatio:1,momentumVelocityRatio:1,sticky:!1,minimumVelocity:.02}}),Object.assign(t,{freeMode:{onTouchStart:function(){const e=t.getTranslate();t.setTranslate(e),t.setTransition(0),t.touchEventsData.velocities.length=0,t.freeMode.onTouchEnd({currentPos:t.rtl?t.translate:-t.translate})},onTouchMove:function(){const{touchEventsData:e,touches:s}=t;0===e.velocities.length&&e.velocities.push({position:s[t.isHorizontal()?"startX":"startY"],time:e.touchStartTime}),e.velocities.push({position:s[t.isHorizontal()?"currentX":"currentY"],time:u()})},onTouchEnd:function(e){let{currentPos:s}=e;const{params:r,$wrapperEl:n,rtlTranslate:l,snapGrid:o,touchEventsData:d}=t,c=u()-d.touchStartTime;if(s<-t.minTranslate())t.slideTo(t.activeIndex);else if(s>-t.maxTranslate())t.slides.length<o.length?t.slideTo(o.length-1):t.slideTo(t.slides.length-1);else{if(r.freeMode.momentum){if(d.velocities.length>1){const e=d.velocities.pop(),s=d.velocities.pop(),a=e.position-s.position,i=e.time-s.time;t.velocity=a/i,t.velocity/=2,Math.abs(t.velocity)<r.freeMode.minimumVelocity&&(t.velocity=0),(i>150||u()-e.time>300)&&(t.velocity=0)}else t.velocity=0;
vendor: 11,383 bytes, line 45
45t.velocity*=r.freeMode.momentumVelocityRatio,d.velocities.length=0;let e=1e3*r.freeMode.momentumRatio;const s=t.velocity*e;let c=t.translate+s;l&&(c=-c);let p,h=!1;const m=20*Math.abs(t.velocity)*r.freeMode.momentumBounceRatio;let f;if(c<t.maxTranslate())r.freeMode.momentumBounce?(c+t.maxTranslate()<-m&&(c=t.maxTranslate()-m),p=t.maxTranslate(),h=!0,d.allowMomentumBounce=!0):c=t.maxTranslate(),r.loop&&r.centeredSlides&&(f=!0);else if(c>t.minTranslate())r.freeMode.momentumBounce?(c-t.minTranslate()>m&&(c=t.minTranslate()+m),p=t.minTranslate(),h=!0,d.allowMomentumBounce=!0):c=t.minTranslate(),r.loop&&r.centeredSlides&&(f=!0);else if(r.freeMode.sticky){let e;for(let t=0;t<o.length;t+=1)if(o[t]>-c){e=t;break}c=Math.abs(o[e]-c)<Math.abs(o[e-1]-c)||"next"===t.swipeDirection?o[e]:o[e-1],c=-c}if(f&&i("transitionEnd",(()=>{t.loopFix()})),0!==t.velocity){if(e=l?Math.abs((-c-t.translate)/t.velocity):Math.abs((c-t.translate)/t.velocity),r.freeMode.sticky){const s=Math.abs((l?-c:c)-t.translate),a=t.slidesSizesGrid[t.activeIndex];e=s<a?r.speed:s<2*a?1.5*r.speed:2.5*r.speed}}else if(r.freeMode.sticky)return void t.slideToClosest();r.freeMode.momentumBounce&&h?(t.updateProgress(p),t.setTransition(e),t.setTranslate(c),t.transitionStart(!0,t.swipeDirection),t.animating=!0,n.transitionEnd((()=>{t&&!t.destroyed&&d.allowMomentumBounce&&(a("momentumBounce"),t.setTransition(r.speed),setTimeout((()=>{t.setTranslate(p),n.transitionEnd((()=>{t&&!t.destroyed&&t.transitionEnd()}))}),0))}))):t.velocity?(a("_freeModeNoMomentumRelease"),t.updateProgress(c),t.setTransition(e),t.setTranslate(c),t.transitionStart(!0,t.swipeDirection),t.animating||(t.animating=!0,n.transitionEnd((()=>{t&&!t.destroyed&&t.transitionEnd()})))):t.updateProgress(c),t.updateActiveIndex(),t.updateSlidesClasses()}else{if(r.freeMode.sticky)return void t.slideToClosest();r.freeMode&&a("_freeModeNoMomentumRelease")}(!r.freeMode.momentum||c>=r.longSwipesMs)&&(t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}}}})},function(e){let t,s,a,{swiper:i,extendParams:r}=e;r({grid:{rows:1,fill:"column"}}),i.grid={initSlides:e=>{const{slidesPerView:r}=i.params,{rows:n,fill:l}=i.params.grid;s=t/n,a=Math.floor(e/n),t=Math.floor(e/n)===e/n?e:Math.ceil(e/n)*n,"auto"!==r&&"row"===l&&(t=Math.max(t,r*n))},updateSlide:(e,r,n,l)=>{const{slidesPerGroup:o,spaceBetween:d}=i.params,{rows:c,fill:p}=i.params.grid;let u,h,m;if("row"===p&&o>1){const s=Math.floor(e/(o*c)),a=e-c*o*s,i=0===s?o:Math.min(Math.ceil((n-s*c*o)/c),o);m=Math.floor(a/i),h=a-m*i+s*o,u=h+m*t/c,r.css({"-webkit-order":u,order:u})}else"column"===p?(h=Math.floor(e/c),m=e-h*c,(h>a||h===a&&m===c-1)&&(m+=1,m>=c&&(m=0,h+=1))):(m=Math.floor(e/s),h=e-m*s);r.css(l("margin-top"),0!==m?d&&`${d}px`:"")},updateWrapperSize:(e,s,a)=>{const{spaceBetween:r,centeredSlides:n,roundLengths:l}=i.params,{rows:o}=i.params.grid;if(i.virtualSize=(e+r)*t,i.virtualSize=Math.ceil(i.virtualSize/o)-r,i.$wrapperEl.css({[a("width")]:`${i.virtualSize+r}px`}),n){s.splice(0,s.length);const e=[];for(let t=0;t<s.length;t+=1){let a=s[t];l&&(a=Math.floor(a)),s[t]<i.virtualSize+s[0]&&e.push(a)}s.push(...e)}}}},function(e){let{swiper:t}=e;Object.assign(t,{appendSlide:K.bind(t),prependSlide:Z.bind(t),addSlide:Q.bind(t),removeSlide:J.bind(t),removeAllSlides:ee.bind(t)})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({fadeEffect:{crossFade:!1,transformEl:null}}),te({effect:"fade",swiper:t,on:a,setTranslate:()=>{const{slides:e}=t,s=t.params.fadeEffect;for(let a=0;a<e.length;a+=1){const e=t.slides.eq(a);let i=-e[0].swiperSlideOffset;t.params.virtualTranslate||(i-=t.translate);let r=0;t.isHorizontal()||(r=i,i=0);const n=t.params.fadeEffect.crossFade?Math.max(1-Math.abs(e[0].progress),0):1+Math.min(Math.max(e[0].progress,-1),0);se(s,e).css({opacity:n}).transform(`translate3d(${i}px, ${r}px, 0px)`)}},setTransition:e=>{const{transformEl:s}=t.params.fadeEffect;(s?t.slides.find(s):t.slides).transition(e),ae({swiper:t,duration:e,transformEl:s,allSlides:!0})},overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}});const i=(e,t,s)=>{let a=s?e.find(".swiper-slide-shadow-left"):e.find(".swiper-slide-shadow-top"),i=s?e.find(".swiper-slide-shadow-right"):e.find(".swiper-slide-shadow-bottom");0===a.length&&(a=d(`<div class="swiper-slide-shadow-${s?"left":"top"}"></div>`),e.append(a)),0===i.length&&(i=d(`<div class="swiper-slide-shadow-${s?"right":"bottom"}"></div>`),e.append(i)),a.length&&(a[0].style.opacity=Math.max(-t,0)),i.length&&(i[0].style.opacity=Math.max(t,0))};te({effect:"cube",swiper:t,on:a,setTranslate:()=>{const{$el:e,$wrapperEl:s,slides:a,width:r,height:n,rtlTranslate:l,size:o,browser:c}=t,p=t.params.cubeEffect,u=t.isHorizontal(),h=t.virtual&&t.params.virtual.enabled;let m,f=0;p.shadow&&(u?(m=s.find(".swiper-cube-shadow"),0===m.length&&(m=d('<div class="swiper-cube-shadow"></div>'),s.append(m)),m.css({height:`${r}px`})):(m=e.find(".swiper-cube-shadow"),0===m.length&&(m=d('<div class="swiper-cube-shadow"></div>'),e.append(m))));for(let e=0;e<a.length;e+=1){const t=a.eq(e);let s=e;h&&(s=parseInt(t.attr("data-swiper-slide-index"),10));let r=90*s,n=Math.floor(r/360);l&&(r=-r,n=Math.floor(-r/360));const d=Math.max(Math.min(t[0].progress,1),-1);let c=0,m=0,g=0;s%4==0?(c=4*-n*o,g=0):(s-1)%4==0?(c=0,g=4*-n*o):(s-2)%4==0?(c=o+4*n*o,g=o):(s-3)%4==0&&(c=-o,g=3*o+4*o*n),l&&(c=-c),u||(m=c,c=0);const v=`rotateX(${u?0:-r}deg) rotateY(${u?r:0}deg) translate3d(${c}px, ${m}px, ${g}px)`;d<=1&&d>-1&&(f=90*s+90*d,l&&(f=90*-s-90*d)),t.transform(v),p.slideShadows&&i(t,d,u)}if(s.css({"-webkit-transform-origin":`50% 50% -${o/2}px`,"transform-origin":`50% 50% -${o/2}px`}),p.shadow)if(u)m.transform(`translate3d(0px, ${r/2+p.shadowOffset}px, ${-r/2}px) rotateX(90deg) rotateZ(0deg) scale(${p.shadowScale})`);else{const e=Math.abs(f)-90*Math.floor(Math.abs(f)/90),t=1.5-(Math.sin(2*e*Math.PI/360)/2+Math.cos(2*e*Math.PI/360)/2),s=p.shadowScale,a=p.shadowScale/t,i=p.shadowOffset;m.transform(`scale3d(${s}, 1, ${a}) translate3d(0px, ${n/2+i}px, ${-n/2/a}px) rotateX(-90deg)`)}const g=c.isSafari||c.isWebView?-o/2:0;s.transform(`translate3d(0px,0,${g}px) rotateX(${t.isHorizontal()?0:f}deg) rotateY(${t.isHorizontal()?-f:0}deg)`),s[0].style.setProperty("--swiper-cube-translate-z",`${g}px`)},setTransition:e=>{const{$el:s,slides:a}=t;a.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),t.params.cubeEffect.shadow&&!t.isHorizontal()&&s.find(".swiper-cube-shadow").transition(e)},recreateShadows:()=>{const e=t.isHorizontal();t.slides.each((t=>{const s=Math.max(Math.min(t.progress,1),-1);i(d(t),s,e)}))},getEffectParams:()=>t.params.cubeEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({flipEffect:{slideShadows:!0,limitRotation:!0,transformEl:null}});const i=(e,s,a)=>{let i=t.isHorizontal()?e.find(".swiper-slide-shadow-left"):e.find(".swiper-slide-shadow-top"),r=t.isHorizontal()?e.find(".swiper-slide-shadow-right"):e.find(".swiper-slide-shadow-bottom");0===i.length&&(i=ie(a,e,t.isHorizontal()?"left":"top")),0===r.length&&(r=ie(a,e,t.isHorizontal()?"right":"bottom")),i.length&&(i[0].style.opacity=Math.max(-s,0)),r.length&&(r[0].style.opacity=Math.max(s,0))};te({effect:"flip",swiper:t,on:a,setTranslate:()=>{const{slides:e,rtlTranslate:s}=t,a=t.params.flipEffect;for(let r=0;r<e.length;r+=1){const n=e.eq(r);let l=n[0].progress;t.params.flipEffect.limitRotation&&(l=Math.max(Math.min(n[0].progress,1),-1));const o=n[0].swiperSlideOffset;let d=-180*l,c=0,p=t.params.cssMode?-o-t.translate:-o,u=0;t.isHorizontal()?s&&(d=-d):(u=p,p=0,c=-d,d=0),n[0].style.zIndex=-Math.abs(Math.round(l))+e.length,a.slideShadows&&i(n,l,a);const h=`translate3d(${p}px, ${u}px, 0px) rotateX(${c}deg) rotateY(${d}deg)`;se(a,n).transform(h)}},setTransition:e=>{const{transformEl:s}=t.params.flipEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),ae({swiper:t,duration:e,transformEl:s})},recreateShadows:()=>{const e=t.params.flipEffect;t.slides.each((s=>{const a=d(s);let r=a[0].progress;t.params.flipEffect.limitRotation&&(r=Math.max(Math.min(s.progress,1),-1)),i(a,r,e)}))},getEffectParams:()=>t.params.flipEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({coverflowEffect:{rotate:50,stretch:0,depth:100,scale:1,modifier:1,slideShadows:!0,transformEl:null}}),te({effect:"coverflow",swiper:t,on:a,setTranslate:()=>{const{width:e,height:s,slides:a,slidesSizesGrid:i}=t,r=t.params.coverflowEffect,n=t.isHorizontal(),l=t.translate,o=n?e/2-l:s/2-l,d=n?r.rotate:-r.rotate,c=r.depth;for(let e=0,t=a.length;e<t;e+=1){const t=a.eq(e),s=i[e],l=(o-t[0].swiperSlideOffset-s/2)/s,p="function"==typeof r.modifier?r.modifier(l):l*r.modifier;let u=n?d*p:0,h=n?0:d*p,m=-c*Math.abs(p),f=r.stretch;"string"==typeof f&&-1!==f.indexOf("%")&&(f=parseFloat(r.stretch)/100*s);let g=n?0:f*p,v=n?f*p:0,w=1-(1-r.scale)*Math.abs(p);Math.abs(v)<.001&&(v=0),Math.abs(g)<.001&&(g=0),Math.abs(m)<.001&&(m=0),Math.abs(u)<.001&&(u=0),Math.abs(h)<.001&&(h=0),Math.abs(w)<.001&&(w=0);const b=`translate3d(${v}px,${g}px,${m}px)  rotateX(${h}deg) rotateY(${u}deg) scale(${w})`;if(se(r,t).transform(b),t[0].style.zIndex=1-Math.abs(Math.round(p)),r.slideShadows){let e=n?t.find(".swiper-slide-shadow-left"):t.find(".swiper-slide-shadow-top"),s=n?t.find(".swiper-slide-shadow-right"):t.find(".swiper-slide-shadow-bottom");0===e.length&&(e=ie(r,t,n?"left":"top")),0===s.length&&(s=ie(r,t,n?"right":"bottom")),e.length&&(e[0].style.opacity=p>0?p:0),s.length&&(s[0].style.opacity=-p>0?-p:0)}}},setTransition:e=>{const{transformEl:s}=t.params.coverflowEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({creativeEffect:{transformEl:null,limitProgress:1,shadowPerProgress:!1,progressMultiplier:1,perspective:!0,prev:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1},next:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1}}});const i=e=>"string"==typeof e?e:`${e}px`;te({effect:"creative",swiper:t,on:a,setTranslate:()=>{const{slides:e,$wrapperEl:s,slidesSizesGrid:a}=t,r=t.params.creativeEffect,{progressMultiplier:n}=r,l=t.params.centeredSlides;if(l){const e=a[0]/2-t.params.slidesOffsetBefore||0;s.transform(`translateX(calc(50% - ${e}px))`)}for(let s=0;s<e.length;s+=1){const a=e.eq(s),o=a[0].progress,d=Math.min(Math.max(a[0].progress,-r.limitProgress),r.limitProgress);let c=d;l||(c=Math.min(Math.max(a[0].originalProgress,-r.limitProgress),r.limitProgress));const p=a[0].swiperSlideOffset,u=[t.params.cssMode?-p-t.translate:-p,0,0],h=[0,0,0];let m=!1;t.isHorizontal()||(u[1]=u[0],u[0]=0);
45let f={translate:[0,0,0],rotate:[0,0,0],scale:1,opacity:1};d<0?(f=r.next,m=!0):d>0&&(f=r.prev,m=!0),u.forEach(((e,t)=>{u[t]=`calc(${e}px + (${i(f.translate[t])} * ${Math.abs(d*n)}))`})),h.forEach(((e,t)=>{h[t]=f.rotate[t]*Math.abs(d*n)})),a[0].style.zIndex=-Math.abs(Math.round(o))+e.length;const g=u.join(", "),v=`rotateX(${h[0]}deg) rotateY(${h[1]}deg) rotateZ(${h[2]}deg)`,w=c<0?`scale(${1+(1-f.scale)*c*n})`:`scale(${1-(1-f.scale)*c*n})`,b=c<0?1+(1-f.opacity)*c*n:1-(1-f.opacity)*c*n,x=`translate3d(${g}) ${v} ${w}`;if(m&&f.shadow||!m){let e=a.children(".swiper-slide-shadow");if(0===e.length&&f.shadow&&(e=ie(r,a)),e.length){const t=r.shadowPerProgress?d*(1/r.limitProgress):d;e[0].style.opacity=Math.min(Math.max(Math.abs(t),0),1)}}const y=se(r,a);y.transform(x).css({opacity:b}),f.origin&&y.css("transform-origin",f.origin)}},setTransition:e=>{const{transformEl:s}=t.params.creativeEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow").transition(e),ae({swiper:t,duration:e,transformEl:s,allSlides:!0})},perspective:()=>t.params.creativeEffect.perspective,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cardsEffect:{slideShadows:!0,transformEl:null,rotate:!0,perSlideRotate:2,perSlideOffset:8}}),te({effect:"cards",swiper:t,on:a,setTranslate:()=>{const{slides:e,activeIndex:s}=t,a=t.params.cardsEffect,{startTranslate:i,isTouched:r}=t.touchEventsData,n=t.translate;for(let l=0;l<e.length;l+=1){const o=e.eq(l),d=o[0].progress,c=Math.min(Math.max(d,-4),4);let p=o[0].swiperSlideOffset;t.params.centeredSlides&&!t.params.cssMode&&t.$wrapperEl.transform(`translateX(${t.minTranslate()}px)`),t.params.centeredSlides&&t.params.cssMode&&(p-=e[0].swiperSlideOffset);let u=t.params.cssMode?-p-t.translate:-p,h=0;const m=-100*Math.abs(c);let f=1,g=-a.perSlideRotate*c,v=a.perSlideOffset-.75*Math.abs(c);const w=t.virtual&&t.params.virtual.enabled?t.virtual.from+l:l,b=(w===s||w===s-1)&&c>0&&c<1&&(r||t.params.cssMode)&&n<i,x=(w===s||w===s+1)&&c<0&&c>-1&&(r||t.params.cssMode)&&n>i;if(b||x){const e=(1-Math.abs((Math.abs(c)-.5)/.5))**.5;g+=-28*c*e,f+=-.5*e,v+=96*e,h=-25*e*Math.abs(c)+"%"}if(u=c<0?`calc(${u}px + (${v*Math.abs(c)}%))`:c>0?`calc(${u}px + (-${v*Math.abs(c)}%))`:`${u}px`,!t.isHorizontal()){const e=h;h=u,u=e}const y=c<0?""+(1+(1-f)*c):""+(1-(1-f)*c),E=`\n        translate3d(${u}, ${h}, ${m}px)\n        rotateZ(${a.rotate?g:0}deg)\n        scale(${y})\n      `;if(a.slideShadows){let e=o.find(".swiper-slide-shadow");0===e.length&&(e=ie(a,o)),e.length&&(e[0].style.opacity=Math.min(Math.max((Math.abs(c)-.5)/.5,0),1))}o[0].style.zIndex=-Math.abs(Math.round(d))+e.length;se(a,o).transform(E)}},setTransition:e=>{const{transformEl:s}=t.params.cardsEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow").transition(e),ae({swiper:t,duration:e,transformEl:s})},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})}];return V.use(re),V}));
46/* End */
47;
48; /* Start:"a:4:{s:4:"full";s:91:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lightgallery.min.js?173495635047108";s:6:"source";s:75:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lightgallery.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
49/**
50 * lightgallery | 2.7.2 | September 20th 2023
51 * http://www.lightgalleryjs.com/
52 * Copyright (c) 2020 Sachin Neravath;
53 * @license GPLv3
54 */
55
56!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).lightGallery=e()}(this,(function(){"use strict";var t=function(){return(t=Object.assign||function(t){for(var e,i=1,s=arguments.length;i<s;i++)for(var n in e=arguments[i])Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}).apply(this,arguments)};var e="lgAfterAppendSlide",i="lgInit",s="lgHasVideo",n="lgContainerResize",o="lgUpdateSlides",r="lgAfterAppendSubHtml",l="lgBeforeOpen",a="lgAfterOpen",d="lgSlideItemLoad",g="lgBeforeSlide",h="lgAfterSlide",c="lgPosterClick",u="lgDragStart",m="lgDragMove",p="lgDragEnd",f="lgBeforeNextSlide",y="lgBeforePrevSlide",v="lgBeforeClose",b="lgAfterClose",I={mode:"lg-slide",easing:"ease",speed:400,licenseKey:"0000-0000-000-0000",height:"100%",width:"100%",addClass:"",startClass:"lg-start-zoom",backdropDuration:300,container:"",startAnimationDuration:400,zoomFromOrigin:!0,hideBarsDelay:0,showBarsAfter:1e4,slideDelay:0,supportLegacyBrowser:!0,allowMediaOverlap:!1,videoMaxSize:"1280-720",loadYouTubePoster:!0,defaultCaptionHeight:0,ariaLabelledby:"",ariaDescribedby:"",resetScrollPosition:!0,hideScrollbar:!1,closable:!0,swipeToClose:!0,closeOnTap:!0,showCloseIcon:!0,showMaximizeIcon:!1,loop:!0,escKey:!0,keyPress:!0,trapFocus:!0,controls:!0,slideEndAnimation:!0,hideControlOnEnd:!1,mousewheel:!1,getCaptionFromTitleOrAlt:!0,appendSubHtmlTo:".lg-sub-html",subHtmlSelectorRelative:!1,preload:2,numberOfSlideItemsInDom:10,selector:"",selectWithin:"",nextHtml:"",prevHtml:"",index:0,iframeWidth:"100%",iframeHeight:"100%",iframeMaxWidth:"100%",iframeMaxHeight:"100%",download:!0,counter:!0,appendCounterTo:".lg-toolbar",swipeThreshold:50,enableSwipe:!0,enableDrag:!0,dynamic:!1,dynamicEl:[],extraProps:[],exThumbImage:"",isMobile:void 0,mobileSettings:{controls:!1,showCloseIcon:!1,download:!1},plugins:[],strings:{closeGallery:"Close gallery",toggleMaximize:"Toggle maximize",previousSlide:"Previous slide",nextSlide:"Next slide",download:"Download",playVideo:"Play video",mediaLoadingFailed:"Oops... Failed to load content..."}};var C=function(){function t(t){return this.cssVenderPrefixes=["TransitionDuration","TransitionTimingFunction","Transform","Transition"],this.selector=this._getSelector(t),this.firstElement=this._getFirstEl(),this}return t.generateUUID=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)}))},t.prototype._getSelector=function(t,e){return void 0===e&&(e=document),"string"!=typeof t?t:(e=e||document,"#"===t.substring(0,1)?e.querySelector(t):e.querySelectorAll(t))},t.prototype._each=function(t){return this.selector?(void 0!==this.selector.length?[].forEach.call(this.selector,t):t(this.selector,0),this):this}
vendor: 12,690 bytes, line 56
56,t.prototype._setCssVendorPrefix=function(t,e,i){var s=e.replace(/-([a-z])/gi,(function(t,e){return e.toUpperCase()}));-1!==this.cssVenderPrefixes.indexOf(s)?(t.style[s.charAt(0).toLowerCase()+s.slice(1)]=i,t.style["webkit"+s]=i,t.style["moz"+s]=i,t.style["ms"+s]=i,t.style["o"+s]=i):t.style[s]=i},t.prototype._getFirstEl=function(){return this.selector&&void 0!==this.selector.length?this.selector[0]:this.selector},t.prototype.isEventMatched=function(t,e){var i=e.split(".");return t.split(".").filter((function(t){return t})).every((function(t){return-1!==i.indexOf(t)}))},t.prototype.attr=function(t,e){return void 0===e?this.firstElement?this.firstElement.getAttribute(t):"":(this._each((function(i){i.setAttribute(t,e)})),this)},t.prototype.find=function(t){return x(this._getSelector(t,this.selector))},t.prototype.first=function(){return this.selector&&void 0!==this.selector.length?x(this.selector[0]):x(this.selector)},t.prototype.eq=function(t){return x(this.selector[t])},t.prototype.parent=function(){return x(this.selector.parentElement)},t.prototype.get=function(){return this._getFirstEl()},t.prototype.removeAttr=function(t){var e=t.split(" ");return this._each((function(t){e.forEach((function(e){return t.removeAttribute(e)}))})),this},t.prototype.wrap=function(t){if(!this.firstElement)return this;var e=document.createElement("div");return e.className=t,this.firstElement.parentNode.insertBefore(e,this.firstElement),this.firstElement.parentNode.removeChild(this.firstElement),e.appendChild(this.firstElement),this},t.prototype.addClass=function(t){return void 0===t&&(t=""),this._each((function(e){t.split(" ").forEach((function(t){t&&e.classList.add(t)}))})),this},t.prototype.removeClass=function(t){return this._each((function(e){t.split(" ").forEach((function(t){t&&e.classList.remove(t)}))})),this},t.prototype.hasClass=function(t){return!!this.firstElement&&this.firstElement.classList.contains(t)},t.prototype.hasAttribute=function(t){return!!this.firstElement&&this.firstElement.hasAttribute(t)},t.prototype.toggleClass=function(t){return this.firstElement?(this.hasClass(t)?this.removeClass(t):this.addClass(t),this):this},t.prototype.css=function(t,e){var i=this;return this._each((function(s){i._setCssVendorPrefix(s,t,e)})),this},t.prototype.on=function(e,i){var s=this;return this.selector?(e.split(" ").forEach((function(e){Array.isArray(t.eventListeners[e])||(t.eventListeners[e]=[]),t.eventListeners[e].push(i),s.selector.addEventListener(e.split(".")[0],i)})),this):this},t.prototype.once=function(t,e){var i=this;return this.on(t,(function(){i.off(t),e(t)})),this},t.prototype.off=function(e){var i=this;return this.selector?(Object.keys(t.eventListeners).forEach((function(s){i.isEventMatched(e,s)&&(t.eventListeners[s].forEach((function(t){i.selector.removeEventListener(s.split(".")[0],t)})),t.eventListeners[s]=[])})),this):this},t.prototype.trigger=function(t,e){if(!this.firstElement)return this;var i=new CustomEvent(t.split(".")[0],{detail:e||null});return this.firstElement.dispatchEvent(i),this},t.prototype.load=function(t){var e=this;return fetch(t).then((function(t){return t.text()})).then((function(t){e.selector.innerHTML=t})),this},t.prototype.html=function(t){return void 0===t?this.firstElement?this.firstElement.innerHTML:"":(this._each((function(e){e.innerHTML=t})),this)},t.prototype.append=function(t){return this._each((function(e){"string"==typeof t?e.insertAdjacentHTML("beforeend",t):e.appendChild(t)})),this},t.prototype.prepend=function(t){return this._each((function(e){e.insertAdjacentHTML("afterbegin",t)})),this},t.prototype.remove=function(){return this._each((function(t){t.parentNode.removeChild(t)})),this},t.prototype.empty=function(){return this._each((function(t){t.innerHTML=""})),this},t.prototype.scrollTop=function(t){return void 0!==t?(document.body.scrollTop=t,document.documentElement.scrollTop=t,this):window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0},t.prototype.scrollLeft=function(t){return void 0!==t?(document.body.scrollLeft=t,document.documentElement.scrollLeft=t,this):window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0},t.prototype.offset=function(){if(!this.firstElement)return{left:0,top:0};var t=this.firstElement.getBoundingClientRect(),e=x("body").style().marginLeft;return{left:t.left-parseFloat(e)+this.scrollLeft(),top:t.top+this.scrollTop()}},t.prototype.style=function(){return this.firstElement?this.firstElement.currentStyle||window.getComputedStyle(this.firstElement):{}},t.prototype.width=function(){var t=this.style();return this.firstElement.clientWidth-parseFloat(t.paddingLeft)-parseFloat(t.paddingRight)},t.prototype.height=function(){var t=this.style();return this.firstElement.clientHeight-parseFloat(t.paddingTop)-parseFloat(t.paddingBottom)},t.eventListeners={},t}();function x(t){return function(){if("function"==typeof window.CustomEvent)return!1;window.CustomEvent=function(t,e){e=e||{bubbles:!1,cancelable:!1,detail:null};var i=document.createEvent("CustomEvent");return i.initCustomEvent(t,e.bubbles,e.cancelable,e.detail),i}}(),Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),new C(t)}var w=["src","sources","subHtml","subHtmlUrl","html","video","poster","slideName","responsive","srcset","sizes","iframe","downloadUrl","download","width","facebookShareUrl","tweetText","iframeTitle","twitterShareUrl","pinterestShareUrl","pinterestText","fbHtml","disqusIdentifier","disqusUrl"];function S(t){return"href"===t?"src":t=(t=(t=t.replace("data-","")).charAt(0).toLowerCase()+t.slice(1)).replace(/-([a-z])/g,(function(t){return t[1].toUpperCase()}))}var T=function(t,e,i,s){void 0===i&&(i=0);var n=x(t).attr("data-lg-size")||s;if(n){var o=n.split(",");if(o[1])for(var r=window.innerWidth,l=0;l<o.length;l++){var a=o[l];if(parseInt(a.split("-")[2],10)>r){n=a;break}l===o.length-1&&(n=a)}var d=n.split("-"),g=parseInt(d[0],10),h=parseInt(d[1],10),c=e.width(),u=e.height()-i,m=Math.min(c,g),p=Math.min(u,h),f=Math.min(m/g,p/h);return{width:g*f,height:h*f}}},E=function(t,e,i,s,n){if(n){var o=x(t).find("img").first();if(o.get()){var r=e.get().getBoundingClientRect(),l=r.width,a=e.height()-(i+s),d=o.width(),g=o.height(),h=o.style(),c=(l-d)/2-o.offset().left+(parseFloat(h.paddingLeft)||0)+(parseFloat(h.borderLeft)||0)+x(window).scrollLeft()+r.left,u=(a-g)/2-o.offset().top+(parseFloat(h.paddingTop)||0)+(parseFloat(h.borderTop)||0)+x(window).scrollTop()+i;return"translate3d("+(c*=-1)+"px, "+(u*=-1)+"px, 0) scale3d("+d/n.width+", "+g/n.height+", 1)"}}},O=function(t,e,i,s,n,o){return'<div class="lg-video-cont lg-has-iframe" style="width:'+t+"; max-width:"+i+"; height: "+e+"; max-height:"+s+'">\n                    <iframe class="lg-object" frameborder="0" '+(o?'title="'+o+'"':"")+' src="'+n+'"  allowfullscreen="true"></iframe>\n                </div>'},D=function(t,e,i,s,n,o){var r="<img "+i+" "+(s?'srcset="'+s+'"':"")+"  "+(n?'sizes="'+n+'"':"")+' class="lg-object lg-image" data-index="'+t+'" src="'+e+'" />',l="";o&&(l=("string"==typeof o?JSON.parse(o):o).map((function(t){var e="";return Object.keys(t).forEach((function(i){e+=" "+i+'="'+t[i]+'"'})),"<source "+e+"></source>"})));return""+l+r},L=function(t){for(var e=[],i=[],s="",n=0;n<t.length;n++){var o=t[n].split(" ");""===o[0]&&o.splice(0,1),i.push(o[0]),e.push(o[1])}for(var r=window.innerWidth,l=0;l<e.length;l++)if(parseInt(e[l],10)>r){s=i[l];break}return s},z=function(t){return!!t&&(!!t.complete&&0!==t.naturalWidth)},M=function(t,e,i,s,n){return'<div class="lg-video-cont '+(n&&n.youtube?"lg-has-youtube":n&&n.vimeo?"lg-has-vimeo":"lg-has-html5")+'" style="'+i+'">\n                <div class="lg-video-play-button">\n                <svg\n                    viewBox="0 0 20 20"\n                    preserveAspectRatio="xMidYMid"\n                    focusable="false"\n                    aria-labelledby="'+s+'"\n                    role="img"\n                    class="lg-video-play-icon"\n                >\n                    <title>'+s+'</title>\n                    <polygon class="lg-video-play-icon-inner" points="1,0 20,10 1,20"></polygon>\n                </svg>\n                <svg class="lg-video-play-icon-bg" viewBox="0 0 50 50" focusable="false">\n                    <circle cx="50%" cy="50%" r="20"></circle></svg>\n                <svg class="lg-video-play-icon-circle" viewBox="0 0 50 50" focusable="false">\n                    <circle cx="50%" cy="50%" r="20"></circle>\n                </svg>\n            </div>\n            '+(e||"")+'\n            <img class="lg-object lg-video-poster" src="'+t+'" />\n        </div>'},G=function(t){var e=t.querySelectorAll('a[href]:not([disabled]), button:not([disabled]), textarea:not([disabled]), input[type="text"]:not([disabled]), input[type="radio"]:not([disabled]), input[type="checkbox"]:not([disabled]), select:not([disabled])');return[].filter.call(e,(function(t){var e=window.getComputedStyle(t);return"none"!==e.display&&"hidden"!==e.visibility}))},k=function(t,e,i,s){var n=[],o=function(){for(var t=0,e=0,i=arguments.length;e<i;e++)t+=arguments[e].length;var s=Array(t),n=0;for(e=0;e<i;e++)for(var o=arguments[e],r=0,l=o.length;r<l;r++,n++)s[n]=o[r];return s}(w,e);return[].forEach.call(t,(function(t){for(var e={},r=0;r<t.attributes.length;r++){var l=t.attributes[r];if(l.specified){var a=S(l.name),d="";o.indexOf(a)>-1&&(d=a),d&&(e[d]=l.value)}}var g=x(t),h=g.find("img").first().attr("alt"),c=g.attr("title"),u=s?g.attr(s):g.find("img").first().attr("src");e.thumb=u,i&&!e.subHtml&&(e.subHtml=c||h||""),e.alt=h||c||"",n.push(e)})),n},A=function(){return/iPhone|iPad|iPod|Android/i.test(navigator.userAgent)},P=function(t,e,i){if(!t)return e?{html5:!0}:void console.error("lightGallery :- data-src is not provided on slide item "+(i+1)+". Please make sure the selector property is properly configured. More info - https://www.lightgalleryjs.com/demos/html-markup/");var s=t.match(/\/\/(?:www\.)?youtu(?:\.be|be\.com|be-nocookie\.com)\/(?:watch\?v=|embed\/)?([a-z0-9\-\_\%]+)([\&|?][\S]*)*/i),n=t.match(/\/\/(?:www\.)?(?:player\.)?vimeo.com\/(?:video\/)?([0-9a-z\-_]+)(.*)?/i),o=t.match(/https?:\/\/(.+)?(wistia\.com|wi\.st)\/(medias|embed)\/([0-9a-z\-_]+)(.*)/);return s?{youtube:s}:n?{vimeo:n}:o?{wistia:o}:void 0},B=0,F=function(){function w(t,e){if(this.lgOpened=!1,this.index=0,this.plugins=[],this.lGalleryOn=!1,this.lgBusy=!1,this.currentItemsInDom=[],this.prevScrollTop=0,this.bodyPaddingRight=0,this.isDummyImageRemoved=!1,this.dragOrSwipeEnabled=!1,this.mediaContainerPosition={top:0,bottom:0},!t)return this;if(B++,this.lgId=B,this.el=t,this.LGel=x(t),this.generateSettings(e),this.buildModules(),this.settings.dynamic&&void 0!==this.settings.dynamicEl&&!Array.isArray(this.settings.dynamicEl))throw"When using dynamic mode, you must also define dynamicEl as an Array.";return this.galleryItems=this.getItems(),this.normalizeSettings(),this.init(),this.validateLicense(),this}return w.prototype.generateSettings=function(e){if(this.settings=t(t({},I),e),this.settings.isMobile&&"function"==typeof this.settings.isMobile?this.settings.isMobile():A()){var i=t(t({},this.settings.mobileSettings),this.settings.mobileSettings);this.settings=t(t({},this.settings),i)}},w.prototype.normalizeSettings=function(){this.settings.slideEndAnimation&&(this.settings.hideControlOnEnd=!1),this.settings.closable||(this.settings.swipeToClose=!1),this.zoomFromOrigin=this.settings.zoomFromOrigin,this.settings.dynamic&&(this.zoomFromOrigin=!1),this.settings.container||(this.settings.container=document.body),this.settings.preload=Math.min(this.settings.preload,this.galleryItems.length)},w.prototype.init=function(){var t=this;this.addSlideVideoInfo(this.galleryItems),this.buildStructure(),this.LGel.trigger(i,{instance:this}),this.settings.keyPress&&this.keyPress(),setTimeout((function(){t.enableDrag(),t.enableSwipe(),t.triggerPosterClick()}),50),this.arrow(),this.settings.mousewheel&&this.mousewheel(),this.settings.dynamic||this.openGalleryOnItemClick()},w.prototype.openGalleryOnItemClick=function(){for(var t=this,e=function(e){var s=i.items[e],n=x(s),o=C.generateUUID();n.attr("data-lg-id",o).on("click.lgcustom-item-"+o,(function(i){i.preventDefault();var n=t.settings.index||e;t.openGallery(n,s)}))},i=this,s=0;s<this.items.length;s++)e(s)},w.prototype.buildModules=function(){var t=this;this.settings.plugins.forEach((function(e){t.plugins.push(new e(t,x))}))},w.prototype.validateLicense=function(){this.settings.licenseKey?"0000-0000-000-0000"===this.settings.licenseKey&&console.warn("lightGallery: "+this.settings.licenseKey+" license key is not val
56id for production use"):console.error("Please provide a valid license key")},w.prototype.getSlideItem=function(t){return x(this.getSlideItemId(t))},w.prototype.getSlideItemId=function(t){return"#lg-item-"+this.lgId+"-"+t},w.prototype.getIdName=function(t){return t+"-"+this.lgId},w.prototype.getElementById=function(t){return x("#"+this.getIdName(t))},w.prototype.manageSingleSlideClassName=function(){this.galleryItems.length<2?this.outer.addClass("lg-single-item"):this.outer.removeClass("lg-single-item")},w.prototype.buildStructure=function(){var t=this;if(!(this.$container&&this.$container.get())){var e="",i="";this.settings.controls&&(e='<button type="button" id="'+this.getIdName("lg-prev")+'" aria-label="'+this.settings.strings.previousSlide+'" class="lg-prev lg-icon"> '+this.settings.prevHtml+' </button>\n                <button type="button" id="'+this.getIdName("lg-next")+'" aria-label="'+this.settings.strings.nextSlide+'" class="lg-next lg-icon"> '+this.settings.nextHtml+" </button>"),".lg-item"!==this.settings.appendSubHtmlTo&&(i='<div class="lg-sub-html" role="status" aria-live="polite"></div>');var s="";this.settings.allowMediaOverlap&&(s+="lg-media-overlap ");var n=this.settings.ariaLabelledby?'aria-labelledby="'+this.settings.ariaLabelledby+'"':"",o=this.settings.ariaDescribedby?'aria-describedby="'+this.settings.ariaDescribedby+'"':"",r="lg-container "+this.settings.addClass+" "+(document.body!==this.settings.container?"lg-inline":""),l=this.settings.closable&&this.settings.showCloseIcon?'<button type="button" aria-label="'+this.settings.strings.closeGallery+'" id="'+this.getIdName("lg-close")+'" class="lg-close lg-icon"></button>':"",a=this.settings.showMaximizeIcon?'<button type="button" aria-label="'+this.settings.strings.toggleMaximize+'" id="'+this.getIdName("lg-maximize")+'" class="lg-maximize lg-icon"></button>':"",d='\n        <div class="'+r+'" id="'+this.getIdName("lg-container")+'" tabindex="-1" aria-modal="true" '+n+" "+o+' role="dialog"\n        >\n            <div id="'+this.getIdName("lg-backdrop")+'" class="lg-backdrop"></div>\n\n            <div id="'+this.getIdName("lg-outer")+'" class="lg-outer lg-use-css3 lg-css3 lg-hide-items '+s+' ">\n\n              <div id="'+this.getIdName("lg-content")+'" class="lg-content">\n                <div id="'+this.getIdName("lg-inner")+'" class="lg-inner">\n                </div>\n                '+e+'\n              </div>\n                <div id="'+this.getIdName("lg-toolbar")+'" class="lg-toolbar lg-group">\n                    '+a+"\n                    "+l+"\n                    </div>\n                    "+(".lg-outer"===this.settings.appendSubHtmlTo?i:"")+'\n                <div id="'+this.getIdName("lg-components")+'" class="lg-components">\n                    '+(".lg-sub-html"===this.settings.appendSubHtmlTo?i:"")+"\n                </div>\n            </div>\n        </div>\n        ";x(this.settings.container).append(d),document.body!==this.settings.container&&x(this.settings.container).css("position","relative"),this.outer=this.getElementById("lg-outer"),this.$lgComponents=this.getElementById("lg-components"),this.$backdrop=this.getElementById("lg-backdrop"),this.$container=this.getElementById("lg-container"),this.$inner=this.getElementById("lg-inner"),this.$content=this.getElementById("lg-content"),this.$toolbar=this.getElementById("lg-toolbar"),this.$backdrop.css("transition-duration",this.settings.backdropDuration+"ms");var g=this.settings.mode+" ";this.manageSingleSlideClassName(),this.settings.enableDrag&&(g+="lg-grab "),this.outer.addClass(g),this.$inner.css("transition-timing-function",this.settings.easing),this.$inner.css("transition-duration",this.settings.speed+"ms"),this.settings.download&&this.$toolbar.append('<a id="'+this.getIdName("lg-download")+'" target="_blank" rel="noopener" aria-label="'+this.settings.strings.download+'" download class="lg-download lg-icon"></a>'),this.counter(),x(window).on("resize.lg.global"+this.lgId+" orientationchange.lg.global"+this.lgId,(function(){t.refreshOnResize()})),this.hideBars(),this.manageCloseGallery(),this.toggleMaximize(),this.initModules()}},w.prototype.refreshOnResize=function(){if(this.lgOpened){var t=this.galleryItems[this.index].__slideVideoInfo;this.mediaContainerPosition=this.getMediaContainerPosition();var e=this.mediaContainerPosition,i=e.top,s=e.bottom;if(this.currentImageSize=T(this.items[this.index],this.outer,i+s,t&&this.settings.videoMaxSize),t&&this.resizeVideoSlide(this.index,this.currentImageSize),this.zoomFromOrigin&&!this.isDummyImageRemoved){var o=this.getDummyImgStyles(this.currentImageSize);this.outer.find(".lg-current .lg-dummy-img").first().attr("style",o)}this.LGel.trigger(n)}},w.prototype.resizeVideoSlide=function(t,e){var i=this.getVideoContStyle(e);
vendor: 4,417 bytes, line 56
56this.getSlideItem(t).find(".lg-video-cont").attr("style",i)},w.prototype.updateSlides=function(t,e){if(this.index>t.length-1&&(this.index=t.length-1),1===t.length&&(this.index=0),t.length){var i=this.galleryItems[e].src;this.galleryItems=t,this.updateControls(),this.$inner.empty(),this.currentItemsInDom=[];var s=0;this.galleryItems.some((function(t,e){return t.src===i&&(s=e,!0)})),this.currentItemsInDom=this.organizeSlideItems(s,-1),this.loadContent(s,!0),this.getSlideItem(s).addClass("lg-current"),this.index=s,this.updateCurrentCounter(s),this.LGel.trigger(o)}else this.closeGallery()},w.prototype.getItems=function(){if(this.items=[],this.settings.dynamic)return this.settings.dynamicEl||[];if("this"===this.settings.selector)this.items.push(this.el);else if(this.settings.selector)if("string"==typeof this.settings.selector)if(this.settings.selectWithin){var t=x(this.settings.selectWithin);this.items=t.find(this.settings.selector).get()}else this.items=this.el.querySelectorAll(this.settings.selector);else this.items=this.settings.selector;else this.items=this.el.children;return k(this.items,this.settings.extraProps,this.settings.getCaptionFromTitleOrAlt,this.settings.exThumbImage)},w.prototype.shouldHideScrollbar=function(){return this.settings.hideScrollbar&&document.body===this.settings.container},w.prototype.hideScrollbar=function(){if(this.shouldHideScrollbar()){this.bodyPaddingRight=parseFloat(x("body").style().paddingRight);var t=document.documentElement.getBoundingClientRect(),e=window.innerWidth-t.width;x(document.body).css("padding-right",e+this.bodyPaddingRight+"px"),x(document.body).addClass("lg-overlay-open")}},w.prototype.resetScrollBar=function(){this.shouldHideScrollbar()&&(x(document.body).css("padding-right",this.bodyPaddingRight+"px"),x(document.body).removeClass("lg-overlay-open"))},w.prototype.openGallery=function(t,e){var i=this;if(void 0===t&&(t=this.settings.index),!this.lgOpened){this.lgOpened=!0,this.outer.removeClass("lg-hide-items"),this.hideScrollbar(),this.$container.addClass("lg-show");var s=this.getItemsToBeInsertedToDom(t,t);this.currentItemsInDom=s;var n="";s.forEach((function(t){n=n+'<div id="'+t+'" class="lg-item"></div>'})),this.$inner.append(n),this.addHtml(t);var o="";this.mediaContainerPosition=this.getMediaContainerPosition();var r=this.mediaContainerPosition,d=r.top,g=r.bottom;this.settings.allowMediaOverlap||this.setMediaContainerPosition(d,g);var h=this.galleryItems[t].__slideVideoInfo;this.zoomFromOrigin&&e&&(this.currentImageSize=T(e,this.outer,d+g,h&&this.settings.videoMaxSize),o=E(e,this.outer,d,g,this.currentImageSize)),this.zoomFromOrigin&&o||(this.outer.addClass(this.settings.startClass),this.getSlideItem(t).removeClass("lg-complete"));var c=this.settings.zoomFromOrigin?100:this.settings.backdropDuration;setTimeout((function(){i.outer.addClass("lg-components-open")}),c),this.index=t,this.LGel.trigger(l),this.getSlideItem(t).addClass("lg-current"),this.lGalleryOn=!1,this.prevScrollTop=x(window).scrollTop(),setTimeout((function(){if(i.zoomFromOrigin&&o){var e=i.getSlideItem(t);e.css("transform",o),setTimeout((function(){e.addClass("lg-start-progress lg-start-end-progress").css("transition-duration",i.settings.startAnimationDuration+"ms"),i.outer.addClass("lg-zoom-from-image")})),setTimeout((function(){e.css("transform","translate3d(0, 0, 0)")}),100)}setTimeout((function(){i.$backdrop.addClass("in"),i.$container.addClass("lg-show-in")}),10),setTimeout((function(){i.settings.trapFocus&&document.body===i.settings.container&&i.trapFocus()}),i.settings.backdropDuration+50),i.zoomFromOrigin&&o||setTimeout((function(){i.outer.addClass("lg-visible")}),i.settings.backdropDuration),i.slide(t,!1,!1,!1),i.LGel.trigger(a)})),document.body===this.settings.container&&x("html").addClass("lg-on")}},w.prototype.getMediaContainerPosition=function(){if(this.settings.allowMediaOverlap)return{top:0,bottom:0};var t=this.$toolbar.get().clientHeight||0,e=this.outer.find(".lg-components .lg-sub-html").get(),i=this.settings.defaultCaptionHeight||e&&e.clientHeight||0,s=this.outer.find(".lg-thumb-outer").get();return{top:t,bottom:(s?s.clientHeight:0)+i}},w.prototype.setMediaContainerPosition=function(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.$content.css("top",t+"px").css("bottom",e+"px")},w.prototype.hideBars=function(){var t=this;setTimeout((function(){t.outer.removeClass("lg-hide-items"),t.settings.hideBarsDelay>
vendor: 5,799 bytes, line 56
560&&(t.outer.on("mousemove.lg click.lg touchstart.lg",(function(){t.outer.removeClass("lg-hide-items"),clearTimeout(t.hideBarTimeout),t.hideBarTimeout=setTimeout((function(){t.outer.addClass("lg-hide-items")}),t.settings.hideBarsDelay)})),t.outer.trigger("mousemove.lg"))}),this.settings.showBarsAfter)},w.prototype.initPictureFill=function(t){if(this.settings.supportLegacyBrowser)try{picturefill({elements:[t.get()]})}catch(t){console.warn("lightGallery :- If you want srcset or picture tag to be supported for older browser please include picturefil javascript library in your document.")}},w.prototype.counter=function(){if(this.settings.counter){var t='<div class="lg-counter" role="status" aria-live="polite">\n                <span id="'+this.getIdName("lg-counter-current")+'" class="lg-counter-current">'+(this.index+1)+' </span> /\n                <span id="'+this.getIdName("lg-counter-all")+'" class="lg-counter-all">'+this.galleryItems.length+" </span></div>";this.outer.find(this.settings.appendCounterTo).append(t)}},w.prototype.addHtml=function(t){var e,i;if(this.galleryItems[t].subHtmlUrl?i=this.galleryItems[t].subHtmlUrl:e=this.galleryItems[t].subHtml,!i)if(e){var s=e.substring(0,1);"."!==s&&"#"!==s||(e=this.settings.subHtmlSelectorRelative&&!this.settings.dynamic?x(this.items).eq(t).find(e).first().html():x(e).first().html())}else e="";if(".lg-item"!==this.settings.appendSubHtmlTo)i?this.outer.find(".lg-sub-html").load(i):this.outer.find(".lg-sub-html").html(e);else{var n=x(this.getSlideItemId(t));i?n.load(i):n.append('<div class="lg-sub-html">'+e+"</div>")}null!=e&&(""===e?this.outer.find(this.settings.appendSubHtmlTo).addClass("lg-empty-html"):this.outer.find(this.settings.appendSubHtmlTo).removeClass("lg-empty-html")),this.LGel.trigger(r,{index:t})},w.prototype.preload=function(t){for(var e=1;e<=this.settings.preload&&!(e>=this.galleryItems.length-t);e++)this.loadContent(t+e,!1);for(var i=1;i<=this.settings.preload&&!(t-i<0);i++)this.loadContent(t-i,!1)},w.prototype.getDummyImgStyles=function(t){return t?"width:"+t.width+"px;\n                margin-left: -"+t.width/2+"px;\n                margin-top: -"+t.height/2+"px;\n                height:"+t.height+"px":""},w.prototype.getVideoContStyle=function(t){return t?"width:"+t.width+"px;\n                height:"+t.height+"px":""},w.prototype.getDummyImageContent=function(t,e,i){var s;if(this.settings.dynamic||(s=x(this.items).eq(e)),s){var n=void 0;if(!(n=this.settings.exThumbImage?s.attr(this.settings.exThumbImage):s.find("img").first().attr("src")))return"";var o="<img "+i+' style="'+this.getDummyImgStyles(this.currentImageSize)+'" class="lg-dummy-img" src="'+n+'" />';return t.addClass("lg-first-slide"),this.outer.addClass("lg-first-slide-loading"),o}return""},w.prototype.setImgMarkup=function(t,e,i){var s=this.galleryItems[i],n=s.alt,o=s.srcset,r=s.sizes,l=s.sources,a=n?'alt="'+n+'"':"",d='<picture class="lg-img-wrap"> '+(this.isFirstSlideWithZoomAnimation()?this.getDummyImageContent(e,i,a):D(i,t,a,o,r,l))+"</picture>";e.prepend(d)},w.prototype.onSlideObjectLoad=function(t,e,i,s){var n=t.find(".lg-object").first();z(n.get())||e?i():(n.on("load.lg error.lg",(function(){i&&i()})),n.on("error.lg",(function(){s&&s()})))},w.prototype.onLgObjectLoad=function(t,e,i,s,n,o){var r=this;this.onSlideObjectLoad(t,o,(function(){r.triggerSlideItemLoad(t,e,i,s,n)}),(function(){t.addClass("lg-complete lg-complete_"),t.html('<span class="lg-error-msg">'+r.settings.strings.mediaLoadingFailed+"</span>")}))},w.prototype.triggerSlideItemLoad=function(t,e,i,s,n){var o=this,r=this.galleryItems[e],l=n&&"video"===this.getSlideType(r)&&!r.poster?s:0;setTimeout((function(){t.addClass("lg-complete lg-complete_"),o.LGel.trigger(d,{index:e,delay:i||0,isFirstSlide:n})}),l)},w.prototype.isFirstSlideWithZoomAnimation=function(){return!(this.lGalleryOn||!this.zoomFromOrigin||!this.currentImageSize)},w.prototype.addSlideVideoInfo=function(t){var e=this;t.forEach((function(t,i){t.__slideVideoInfo=P(t.src,!!t.video,i),t.__slideVideoInfo&&e.settings.loadYouTubePoster&&!t.poster&&t.__slideVideoInfo.youtube&&(t.poster="//img.youtube.com/vi/"+t.__slideVideoInfo.youtube[1]+"/maxresdefault.jpg")}))},w.prototype.loadContent=function(t,i){var n=this,o=this.galleryItems[t],r=x(this.getSlideItemId(t)),l=o.poster,a=o.srcset,d=o.sizes,g=o.sources,h=o.src,c=o.video,u=c&&"string"==typeof c?JSON.parse(c):c;if(o.responsive){var m=o.responsive.split(",");h=L(m)||h}var p=o.__slideVideoInfo,f="",y=!!o.iframe,v=!this.lGalleryOn,b=0;if(v&&(b=this.zoomFromOrigin&&this.currentImageSize?this.settings.startAnimationDuration+10:this.settings.backdropDuration+10),!r.hasClass("lg-loaded")){if(p){var I=this.mediaContainerPosition,C=I.top,w=I.bottom,S=T(this.items[t],this.outer,C+w,p&&this.settings.videoMaxSize);f=this.getVideoContStyle(S)}if(y){var E=O(this.settings.iframeWidth,this.settings.iframeHeight,this.settings.iframeMaxWidth,this.settings.iframeMaxHeight,h,o.iframeTitle);r.prepend(E)}else if(l){var z="";v&&this.zoomFromOrigin&&this.currentImageSize&&(z=this.getDummyImageContent(r,t,""));E=M(l,z||"",f,this.settings.strings.playVideo,p);r.prepend(E)}else if(p){E='<div class="lg-video-cont " style="'+f+'"></div>';r.prepend(E)}else if(this.setImgMarkup(h,r,t),a||g){var G=r.find(".lg-object");this.initPictureFill(G)}(l||p)&&this.LGel.trigger(s,{index:t,src:h,html5Video:u,hasPoster:!!l}),this.LGel.trigger(e,{index:t}),this.lGalleryOn&&".lg-item"===this.settings.appendSubHtmlTo&&this.addHtml(t)}var k=0;b&&!x(document.body).hasClass("lg-from-hash")&&(k=b),this.isFirstSlideWithZoomAnimation()&&(setTimeout((function(){r.removeClass("lg-start-end-progress lg-start-progress").removeAttr("style")}),this.settings.startAnimationDuration+100),r.hasClass("lg-loaded")||setTimeout((function(){if("image"===n.get
vendor: 3,929 bytes, line 56
56SlideType(o)){var e=o.alt,i=e?'alt="'+e+'"':"";if(r.find(".lg-img-wrap").append(D(t,h,i,a,d,o.sources)),a||g){var s=r.find(".lg-object");n.initPictureFill(s)}}("image"===n.getSlideType(o)||"video"===n.getSlideType(o)&&l)&&(n.onLgObjectLoad(r,t,b,k,!0,!1),n.onSlideObjectLoad(r,!(!p||!p.html5||l),(function(){n.loadContentOnFirstSlideLoad(t,r,k)}),(function(){n.loadContentOnFirstSlideLoad(t,r,k)})))}),this.settings.startAnimationDuration+100)),r.addClass("lg-loaded"),this.isFirstSlideWithZoomAnimation()&&("video"!==this.getSlideType(o)||l)||this.onLgObjectLoad(r,t,b,k,v,!(!p||!p.html5||l)),this.zoomFromOrigin&&this.currentImageSize||!r.hasClass("lg-complete_")||this.lGalleryOn||setTimeout((function(){r.addClass("lg-complete")}),this.settings.backdropDuration),this.lGalleryOn=!0,!0===i&&(r.hasClass("lg-complete_")?this.preload(t):r.find(".lg-object").first().on("load.lg error.lg",(function(){n.preload(t)})))},w.prototype.loadContentOnFirstSlideLoad=function(t,e,i){var s=this;setTimeout((function(){e.find(".lg-dummy-img").remove(),e.removeClass("lg-first-slide"),s.outer.removeClass("lg-first-slide-loading"),s.isDummyImageRemoved=!0,s.preload(t)}),i+300)},w.prototype.getItemsToBeInsertedToDom=function(t,e,i){var s=this;void 0===i&&(i=0);var n=[],o=Math.max(i,3);o=Math.min(o,this.galleryItems.length);var r="lg-item-"+this.lgId+"-"+e;if(this.galleryItems.length<=3)return this.galleryItems.forEach((function(t,e){n.push("lg-item-"+s.lgId+"-"+e)})),n;if(t<(this.galleryItems.length-1)/2){for(var l=t;l>t-o/2&&l>=0;l--)n.push("lg-item-"+this.lgId+"-"+l);var a=n.length;for(l=0;l<o-a;l++)n.push("lg-item-"+this.lgId+"-"+(t+l+1))}else{for(l=t;l<=this.galleryItems.length-1&&l<t+o/2;l++)n.push("lg-item-"+this.lgId+"-"+l);for(a=n.length,l=0;l<o-a;l++)n.push("lg-item-"+this.lgId+"-"+(t-l-1))}return this.settings.loop&&(t===this.galleryItems.length-1?n.push("lg-item-"+this.lgId+"-0"):0===t&&n.push("lg-item-"+this.lgId+"-"+(this.galleryItems.length-1))),-1===n.indexOf(r)&&n.push("lg-item-"+this.lgId+"-"+e),n},w.prototype.organizeSlideItems=function(t,e){var i=this,s=this.getItemsToBeInsertedToDom(t,e,this.settings.numberOfSlideItemsInDom);return s.forEach((function(t){-1===i.currentItemsInDom.indexOf(t)&&i.$inner.append('<div id="'+t+'" class="lg-item"></div>')})),this.currentItemsInDom.forEach((function(t){-1===s.indexOf(t)&&x("#"+t).remove()})),s},w.prototype.getPreviousSlideIndex=function(){var t=0;try{var e=this.outer.find(".lg-current").first().attr("id");t=parseInt(e.split("-")[3])||0}catch(e){t=0}return t},w.prototype.setDownloadValue=function(t){if(this.settings.download){var e=this.galleryItems[t];if(!1===e.downloadUrl||"false"===e.downloadUrl)this.outer.addClass("lg-hide-download");else{var i=this.getElementById("lg-download");this.outer.removeClass("lg-hide-download"),i.attr("href",e.downloadUrl||e.src),e.download&&i.attr("download",e.download)}}},w.prototype.makeSlideAnimation=function(t,e,i){var s=this;this.lGalleryOn&&i.addClass("lg-slide-progress"),setTimeout((function(){s.outer.addClass("lg-no-trans"),s.outer.find(".lg-item").removeClass("lg-prev-slide lg-next-slide"),"prev"===t?(e.addClass("lg-prev-slide"),i.addClass("lg-next-slide")):(e.addClass("lg-next-slide"),i.addClass("lg-prev-slide")),setTimeout((function(){s.outer.find(".lg-item").removeClass("lg-current"),e.addClass("lg-current"),s.outer.removeClass("lg-no-trans")}),50)}),this.lGalleryOn?this.settings.slideDelay:0)},w.prototype.slide=function(t,e,i,s){var n=this,o=this.getPreviousSlideIndex();if(this.currentItemsInDom=this.organizeSlideItems(t,o),!this.lGalleryOn||o!==t){var r=this.galleryItems.length;if(!this.lgBusy){this.settings.counter&&this.updateCurrentCounter(t);var l=this.getSlideItem(t),a=this.getSlideItem(o),d=this.galleryItems[t],c=d.__slideVideoInfo;if(this.outer.attr("data-lg-slide-type",this.getSlideType(d)),this.setDownloadValue(t),c){var u=this.mediaContainerPosition,m=u.top,p=u.bottom,f=T
vendor: 8,173 bytes, line 56
56(this.items[t],this.outer,m+p,c&&this.settings.videoMaxSize);this.resizeVideoSlide(t,f)}if(this.LGel.trigger(g,{prevIndex:o,index:t,fromTouch:!!e,fromThumb:!!i}),this.lgBusy=!0,clearTimeout(this.hideBarTimeout),this.arrowDisable(t),s||(t<o?s="prev":t>o&&(s="next")),e){this.outer.find(".lg-item").removeClass("lg-prev-slide lg-current lg-next-slide");var y=void 0,v=void 0;r>2?(y=t-1,v=t+1,(0===t&&o===r-1||t===r-1&&0===o)&&(v=0,y=r-1)):(y=0,v=1),"prev"===s?this.getSlideItem(v).addClass("lg-next-slide"):this.getSlideItem(y).addClass("lg-prev-slide"),l.addClass("lg-current")}else this.makeSlideAnimation(s,l,a);this.lGalleryOn?setTimeout((function(){n.loadContent(t,!0),".lg-item"!==n.settings.appendSubHtmlTo&&n.addHtml(t)}),this.settings.speed+50+(e?0:this.settings.slideDelay)):this.loadContent(t,!0),setTimeout((function(){n.lgBusy=!1,a.removeClass("lg-slide-progress"),n.LGel.trigger(h,{prevIndex:o,index:t,fromTouch:e,fromThumb:i})}),(this.lGalleryOn?this.settings.speed+100:100)+(e?0:this.settings.slideDelay))}this.index=t}},w.prototype.updateCurrentCounter=function(t){this.getElementById("lg-counter-current").html(t+1+"")},w.prototype.updateCounterTotal=function(){this.getElementById("lg-counter-all").html(this.galleryItems.length+"")},w.prototype.getSlideType=function(t){return t.__slideVideoInfo?"video":t.iframe?"iframe":"image"},w.prototype.touchMove=function(t,e,i){var s=e.pageX-t.pageX,n=e.pageY-t.pageY,o=!1;if(this.swipeDirection?o=!0:Math.abs(s)>15?(this.swipeDirection="horizontal",o=!0):Math.abs(n)>15&&(this.swipeDirection="vertical",o=!0),o){var r=this.getSlideItem(this.index);if("horizontal"===this.swipeDirection){null==i||i.preventDefault(),this.outer.addClass("lg-dragging"),this.setTranslate(r,s,0);var l=r.get().offsetWidth,a=15*l/100-Math.abs(10*s/100);this.setTranslate(this.outer.find(".lg-prev-slide").first(),-l+s-a,0),this.setTranslate(this.outer.find(".lg-next-slide").first(),l+s+a,0)}else if("vertical"===this.swipeDirection&&this.settings.swipeToClose){null==i||i.preventDefault(),this.$container.addClass("lg-dragging-vertical");var d=1-Math.abs(n)/window.innerHeight;this.$backdrop.css("opacity",d);var g=1-Math.abs(n)/(2*window.innerWidth);this.setTranslate(r,0,n,g,g),Math.abs(n)>100&&this.outer.addClass("lg-hide-items").removeClass("lg-components-open")}}},w.prototype.touchEnd=function(t,e,i){var s,n=this;"lg-slide"!==this.settings.mode&&this.outer.addClass("lg-slide"),setTimeout((function(){n.$container.removeClass("lg-dragging-vertical"),n.outer.removeClass("lg-dragging lg-hide-items").addClass("lg-components-open");var o=!0;if("horizontal"===n.swipeDirection){s=t.pageX-e.pageX;var r=Math.abs(t.pageX-e.pageX);s<0&&r>n.settings.swipeThreshold?(n.goToNextSlide(!0),o=!1):s>0&&r>n.settings.swipeThreshold&&(n.goToPrevSlide(!0),o=!1)}else if("vertical"===n.swipeDirection){if(s=Math.abs(t.pageY-e.pageY),n.settings.closable&&n.settings.swipeToClose&&s>100)return void n.closeGallery();n.$backdrop.css("opacity",1)}if(n.outer.find(".lg-item").removeAttr("style"),o&&Math.abs(t.pageX-e.pageX)<5){var l=x(i.target);n.isPosterElement(l)&&n.LGel.trigger(c)}n.swipeDirection=void 0})),setTimeout((function(){n.outer.hasClass("lg-dragging")||"lg-slide"===n.settings.mode||n.outer.removeClass("lg-slide")}),this.settings.speed+100)},w.prototype.enableSwipe=function(){var t=this,e={},i={},s=!1,n=!1;this.settings.enableSwipe&&(this.$inner.on("touchstart.lg",(function(i){t.dragOrSwipeEnabled=!0;var s=t.getSlideItem(t.index);!x(i.target).hasClass("lg-item")&&!s.get().contains(i.target)||t.outer.hasClass("lg-zoomed")||t.lgBusy||1!==i.touches.length||(n=!0,t.touchAction="swipe",t.manageSwipeClass(),e={pageX:i.touches[0].pageX,pageY:i.touches[0].pageY})})),this.$inner.on("touchmove.lg",(function(o){n&&"swipe"===t.touchAction&&1===o.touches.length&&(i={pageX:o.touches[0].pageX,pageY:o.touches[0].pageY},t.touchMove(e,i,o),s=!0)})),this.$inner.on("touchend.lg",(function(o){if("swipe"===t.touchAction){if(s)s=!1,t.touchEnd(i,e,o);else if(n){var r=x(o.target);t.isPosterElement(r)&&t.LGel.trigger(c)}t.touchAction=void 0,n=!1}})))},w.prototype.enableDrag=function(){var t=this,e={},i={},s=!1,n=!1;this.settings.enableDrag&&(this.outer.on("mousedown.lg",(function(i){t.dragOrSwipeEnabled=!0;var n=t.getSlideItem(t.index);(x(i.target).hasClass("lg-item")||n.get().contains(i.target))&&(t.outer.hasClass("lg-zoomed")||t.lgBusy||(i.preventDefault(),t.lgBusy||(t.manageSwipeClass(),e={pageX:i.pageX,pageY:i.pageY},s=!0,t.outer.get().scrollLeft+=1,t.outer.get().scrollLeft-=1,t.outer.removeClass("lg-grab").addClass("lg-grabbing"),t.LGel.trigger(u))))})),x(window).on("mousemove.lg.global"+this.lgId,(function(o){s&&t.lgOpened&&(n=!0,i={pageX:o.pageX,pageY:o.pageY},t.touchMove(e,i),t.LGel.trigger(m))})),x(window).on("mouseup.lg.global"+this.lgId,(function(o){if(t.lgOpened){var r=x(o.target);n?(n=!1,t.touchEnd(i,e,o),t.LGel.trigger(p)):t.isPosterElement(r)&&t.LGel.trigger(c),s&&(s=!1,t.outer.removeClass("lg-grabbing").addClass("lg-grab"))}})))},w.prototype.triggerPosterClick=function(){var t=this;this.$inner.on("click.lg",(function(e){!t.dragOrSwipeEnabled&&t.isPosterElement(x(e.target))&&t.LGel.trigger(c)}))},w.prototype.manageSwipeClass=function(){var t=this.index+1,e=this.index-1;this.settings.loop&&this.galleryItems.length>2&&(0===this.index?e=this.galleryItems.length-1:this.index===this.galleryItems.length-1&&(t=0)),this.outer.find(".lg-item").removeClass("lg-next-slide lg-prev-slide"),e>-1&&this.getSlideItem(e).addClass("lg-prev-slide"),this.getSlideItem(t).addClass("lg-next-slide")},w.prototype.goToNextSlide=function(t){var e=this,i=this.settings.loop;t&&this.galleryItems.length<3&&(i=!1),this.lgBusy||(this.index+1<this.galleryItems.length?(this.index++,this.LGel.trigger(f,{index:this.index}),this.slide(this.index,!!t,!1,"next")):i?(this.index=0,this.LGel.trigger(f,{index:this.index}),this.slide(this.index,!!t,!1,"next")):this.settings.slideEndAnimation&&!t&&(this.outer.addClass("lg-right-end"),setTimeout((function(){e.outer.removeClass("lg-right-end")}),400)))},w.prototype.goToPrevSlide=function(t){var e=this,i=this.settings.loop;t&&this.galleryItems.length<3&&(i=!1),this.lgBusy||(this.index>0?(this.index--,this.LGel.trigger(y,{index:this.index,fromTouch:t}),this.slide(this.index,!!t,!1,"prev")):i?(this.index=this.galleryItems.length-1,this.LGel.trigger(y,{index:this.index,fromTouch:t}),this.slide(this.index,!!t,!1,"prev")):this.settings.slideEndAnimation&&!t&&(this.outer.addClass("lg-left-end"),setTimeout((function(){e.outer.removeClass("lg-left-end")}),400)))},w.prototype.keyPress=function(){var t=this;x(window).on("keydown.lg.global"+this.lgId,(function(e){t.lgOpened&&!0===t.settings.escKey&&27===e.keyCode&&(e.preventDefault(),t.settings.allowMediaOverlap&&t.outer.hasClass("lg-can-toggle")&&t.outer.hasClass("lg-components-open")?t.outer.removeClass("lg-components-open"):t.closeGallery()),t.lgOpened&&t.galleryItems.length>1&&(37===e.keyCode&&(e.preventDefault(),t.goToPrevSlide()),39===e.keyCode&&(e.preventDefault(),t.goToNextSlide()))}))},w.prototype.arrow=function(){var t=this;this.getElementById("lg-prev").on("click.lg",(function(){t.goToPrevSlide()})),this.getElementById("lg-next").on("click.lg",(function(){t.goToNextSlide()}))},w.prototype.arrowDisable=function(t){if(!this.settings.loop&&this.settings.hideControlOnEnd){var e=this.getElementById("lg-prev"),i=this.getElementById("lg-next");t+1===this.galleryItems.length?i.attr("disabled","disabled").addClass("disabled"):i.removeAttr("disabled").removeClass("disabled"),0===t?e.attr("disabled","disabled").addClass("disabled"):e.removeAttr("disabled").removeClass("disabled")}},w.prototype.setTranslate=function(t,e,i,s,n){void 0===s&&(s=1),void 0===n&&(n=1),t.css("transform","translate3d("+e+"px, "+i+"px, 0px) scale3d("+s+", "+n+", 1)")},w.prototype.mousewheel=function(){var t=this,e=0;this.outer.on("wheel.lg",(function(i){if(i.deltaY&&!(t.galleryItems.length<2)){i.preventDefault();var s=(new Date).getTime();s-e<1e3||(e=s,i.deltaY>0?t.goToNextSlide():i.deltaY<0&&t.goToPrevSlide())}}))},w.prototype.isSlideElement=function(t){return t.hasClass("lg-outer")||t.hasClass("lg-item")||t.hasClass("lg-img-wrap")
vendor: 3,566 bytes, line 56
56},w.prototype.isPosterElement=function(t){var e=this.getSlideItem(this.index).find(".lg-video-play-button").get();return t.hasClass("lg-video-poster")||t.hasClass("lg-video-play-button")||e&&e.contains(t.get())},w.prototype.toggleMaximize=function(){var t=this;this.getElementById("lg-maximize").on("click.lg",(function(){t.$container.toggleClass("lg-inline"),t.refreshOnResize()}))},w.prototype.invalidateItems=function(){for(var t=0;t<this.items.length;t++){var e=x(this.items[t]);e.off("click.lgcustom-item-"+e.attr("data-lg-id"))}},w.prototype.trapFocus=function(){var t=this;this.$container.get().focus({preventScroll:!0}),x(window).on("keydown.lg.global"+this.lgId,(function(e){if(t.lgOpened&&("Tab"===e.key||9===e.keyCode)){var i=G(t.$container.get()),s=i[0],n=i[i.length-1];e.shiftKey?document.activeElement===s&&(n.focus(),e.preventDefault()):document.activeElement===n&&(s.focus(),e.preventDefault())}}))},w.prototype.manageCloseGallery=function(){var t=this;if(this.settings.closable){var e=!1;this.getElementById("lg-close").on("click.lg",(function(){t.closeGallery()})),this.settings.closeOnTap&&(this.outer.on("mousedown.lg",(function(i){var s=x(i.target);e=!!t.isSlideElement(s)})),this.outer.on("mousemove.lg",(function(){e=!1})),this.outer.on("mouseup.lg",(function(i){var s=x(i.target);t.isSlideElement(s)&&e&&(t.outer.hasClass("lg-dragging")||t.closeGallery())})))}},w.prototype.closeGallery=function(t){var e=this;if(!this.lgOpened||!this.settings.closable&&!t)return 0;this.LGel.trigger(v),this.settings.resetScrollPosition&&!this.settings.hideScrollbar&&x(window).scrollTop(this.prevScrollTop);var i,s=this.items[this.index];if(this.zoomFromOrigin&&s){var n=this.mediaContainerPosition,o=n.top,r=n.bottom,l=this.galleryItems[this.index],a=l.__slideVideoInfo,d=l.poster,g=T(s,this.outer,o+r,a&&d&&this.settings.videoMaxSize);i=E(s,this.outer,o,r,g)}this.zoomFromOrigin&&i?(this.outer.addClass("lg-closing lg-zoom-from-image"),this.getSlideItem(this.index).addClass("lg-start-end-progress").css("transition-duration",this.settings.startAnimationDuration+"ms").css("transform",i)):(this.outer.addClass("lg-hide-items"),this.outer.removeClass("lg-zoom-from-image")),this.destroyModules(),this.lGalleryOn=!1,this.isDummyImageRemoved=!1,this.zoomFromOrigin=this.settings.zoomFromOrigin,clearTimeout(this.hideBarTimeout),this.hideBarTimeout=!1,x("html").removeClass("lg-on"),this.outer.removeClass("lg-visible lg-components-open"),this.$backdrop.removeClass("in").css("opacity",0);var h=this.zoomFromOrigin&&i?Math.max(this.settings.startAnimationDuration,this.settings.backdropDuration):this.settings.backdropDuration;return this.$container.removeClass("lg-show-in"),setTimeout((function(){e.zoomFromOrigin&&i&&e.outer.removeClass("lg-zoom-from-image"),e.$container.removeClass("lg-show"),e.resetScrollBar(),e.$backdrop.removeAttr("style").css("transition-duration",e.settings.backdropDuration+"ms"),e.outer.removeClass("lg-closing "+e.settings.startClass),e.getSlideItem(e.index).removeClass("lg-start-end-progress"),e.$inner.empty(),e.lgOpened&&e.LGel.trigger(b,{instance:e}),e.$container.get()&&e.$container.get().blur(),e.lgOpened=!1}),h+100),h+100},w.prototype.initModules=function(){this.plugins.forEach((function(t){try{t.init()}catch(t){console.warn("lightGallery:- make sure lightGallery module is properly initiated")}}))},w.prototype.destroyModules=function(t){this.plugins.forEach((function(e){try{t?e.destroy():e.closeGallery&&e.closeGallery()}catch(t){console.warn("lightGallery:- make sure lightGallery module is properly destroyed")}}
56))},w.prototype.refresh=function(t){this.settings.dynamic||this.invalidateItems(),this.galleryItems=t||this.getItems(),this.updateControls(),this.openGalleryOnItemClick(),this.LGel.trigger(o)},w.prototype.updateControls=function(){this.addSlideVideoInfo(this.galleryItems),this.updateCounterTotal(),this.manageSingleSlideClassName()},w.prototype.destroyGallery=function(){this.destroyModules(!0),this.settings.dynamic||this.invalidateItems(),x(window).off(".lg.global"+this.lgId),this.LGel.off(".lg"),this.$container.remove()},w.prototype.destroy=function(){var t=this.closeGallery(!0);return t?setTimeout(this.destroyGallery.bind(this),t):this.destroyGallery(),t},w}();return function(t,e){return new F(t,e)}}));
57/* End */
58;
59; /* Start:"a:4:{s:4:"full";s:91:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-fullscreen.min.js?17319318082773";s:6:"source";s:76:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-fullscreen.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
60/**
61 * lightgallery | 2.7.2 | September 20th 2023
62 * http://www.lightgalleryjs.com/
63 * Copyright (c) 2020 Sachin Neravath;
64 * @license GPLv3
65 */
66
67!function(e,l){"object"==typeof exports&&"undefined"!=typeof module?module.exports=l():"function"==typeof define&&define.amd?define(l):(e="undefined"!=typeof globalThis?globalThis:e||self).lgFullscreen=l()}(this,(function(){"use strict";var e=function(){return(e=Object.assign||function(e){for(var l,n=1,t=arguments.length;n<t;n++)for(var c in l=arguments[n])Object.prototype.hasOwnProperty.call(l,c)&&(e[c]=l[c]);return e}).apply(this,arguments)},l={fullScreen:!0,fullscreenPluginStrings:{toggleFullscreen:"Toggle Fullscreen"}};return function(){function n(n,t){return this.core=n,this.$LG=t,this.settings=e(e({},l),this.core.settings),this}return n.prototype.init=function(){var e="";if(this.settings.fullScreen){if(!(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled))return;e='<button type="button" aria-label="'+this.settings.fullscreenPluginStrings.toggleFullscreen+'" class="lg-fullscreen lg-icon"></button>',this.core.$toolbar.append(e),this.fullScreen()}},n.prototype.isFullScreen=function(){return document.fullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement||document.msFullscreenElement},n.prototype.requestFullscreen=function(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.msRequestFullscreen?e.msRequestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullscreen&&e.webkitRequestFullscreen()},n.prototype.exitFullscreen=function(){document.exitFullscreen?document.exitFullscreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen&&document.webkitExitFullscreen()},n.prototype.fullScreen=function(){var e=this;this.$LG(document).on("fullscreenchange.lg.global"+this.core.lgId+" \n            webkitfullscreenchange.lg.global"+this.core.lgId+" \n            mozfullscreenchange.lg.global"+this.core.lgId+" \n            MSFullscreenChange.lg.global"+this.core.lgId,(function(){e.core.lgOpened&&e.core.outer.toggleClass("lg-fullscreen-on")})),this.core.outer.find(".lg-fullscreen").first().on("click.lg",(function(){e.isFullScreen()?e.exitFullscreen():e.requestFullscreen()}))},n.prototype.closeGallery=function(){this.isFullScreen()&&this.exitFullscreen()},n.prototype.destroy=function(){this.$LG(document).off("fullscreenchange.lg.global"+this.core.lgId+" \n            webkitfullscreenchange.lg.global"+this.core.lgId+" \n            mozfullscreenchange.lg.global"+this.core.lgId+" \n            MSFullscreenChange.lg.global"+this.core.lgId)},n}()}));
68/* End */
69;
70; /* Start:"a:4:{s:4:"full";s:86:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-zoom.min.js?173193187516518";s:6:"source";s:70:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-zoom.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
71/**
72 * lightgallery | 2.7.2 | September 20th 2023
73 * http://www.lightgalleryjs.com/
74 * Copyright (c) 2020 Sachin Neravath;
75 * @license GPLv3
76 */
77
78!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).lgZoom=t()}(this,(function(){"use strict";var e=function(){return(e=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var s in t=arguments[o])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)},t={scale:1,zoom:!0,infiniteZoom:!0,actualSize:!0,showZoomInOutIcons:!1,actualSizeIcons:{zoomIn:"lg-zoom-in",zoomOut:"lg-zoom-out"},enableZoomAfter:300,zoomPluginStrings:{zoomIn:"Zoom in",zoomOut:"Zoom out",viewActualSize:"View actual size"}},o="lgContainerResize",i="lgBeforeOpen",s="lgAfterOpen",a="lgSlideItemLoad",n="lgAfterSlide",r="lgRotateLeft",l="lgRotateRight",g="lgFlipHorizontal",c="lgFlipVertical";return function(){function h(o,i){return this.core=o,this.$LG=i,this.settings=e(e({},t),this.core.settings),this}return h.prototype.buildTemplates=function(){var e=this.settings.showZoomInOutIcons?'<button id="'+this.core.getIdName("lg-zoom-in")+'" type="button" aria-label="'+this.settings.zoomPluginStrings.zoomIn+'" class="lg-zoom-in lg-icon"></button><button id="'+this.core.getIdName("lg-zoom-out")+'" type="button" aria-label="'+this.settings.zoomPluginStrings.zoomIn+'" class="lg-zoom-out lg-icon"></button>':"";this.settings.actualSize&&(e+='<button id="'+this.core.getIdName("lg-actual-size")+'" t
vendor: 13,737 bytes, line 78
78ype="button" aria-label="'+this.settings.zoomPluginStrings.viewActualSize+'" class="'+this.settings.actualSizeIcons.zoomIn+' lg-icon"></button>'),this.core.outer.addClass("lg-use-transition-for-zoom"),this.core.$toolbar.first().append(e)},h.prototype.enableZoom=function(e){var t=this,o=this.settings.enableZoomAfter+e.detail.delay;this.$LG("body").first().hasClass("lg-from-hash")&&e.detail.delay?o=0:this.$LG("body").first().removeClass("lg-from-hash"),this.zoomableTimeout=setTimeout((function(){t.isImageSlide(t.core.index)&&(t.core.getSlideItem(e.detail.index).addClass("lg-zoomable"),e.detail.index===t.core.index&&t.setZoomEssentials())}),o+30)},h.prototype.enableZoomOnSlideItemLoad=function(){this.core.LGel.on(a+".zoom",this.enableZoom.bind(this))},h.prototype.getDragCords=function(e){return{x:e.pageX,y:e.pageY}},h.prototype.getSwipeCords=function(e){return{x:e.touches[0].pageX,y:e.touches[0].pageY}},h.prototype.getDragAllowedAxises=function(e,t){var o=this.core.getSlideItem(this.core.index).find(".lg-image").first().get(),i=0,s=0,a=o.getBoundingClientRect();e?(i=o.offsetHeight*e,s=o.offsetWidth*e):t?(i=a.height+t*a.height,s=a.width+t*a.width):(i=a.height,s=a.width);var n=i>this.containerRect.height;return{allowX:s>this.containerRect.width,allowY:n}},h.prototype.setZoomEssentials=function(){this.containerRect=this.core.$content.get().getBoundingClientRect()},h.prototype.zoomImage=function(e,t,o,i){if(!(Math.abs(t)<=0)){var s,a,n=this.containerRect.width/2+this.containerRect.left,r=this.containerRect.height/2+this.containerRect.top+this.scrollTop;1===e&&(this.positionChanged=!1);var l=this.getDragAllowedAxises(0,t),g=l.allowY,c=l.allowX;this.positionChanged&&(s=this.left/(this.scale-t),a=this.top/(this.scale-t),this.pageX=n-s,this.pageY=r-a,this.positionChanged=!1);var h,m,u=this.getPossibleSwipeDragCords(t),d=n-this.pageX,f=r-this.pageY;if(e-t>1){var p=(e-t)/Math.abs(t);h=(d=(t<0?-d:d)+this.left*(p+(t<0?-1:1)))/p,m=(f=(t<0?-f:f)+this.top*(p+(t<0?-1:1)))/p}else{h=d*(p=(e-t)*t),m=f*p}o&&(c?this.isBeyondPossibleLeft(h,u.minX)?h=u.minX:this.isBeyondPossibleRight(h,u.maxX)&&(h=u.maxX):e>1&&(h<u.minX?h=u.minX:h>u.maxX&&(h=u.maxX)),g?this.isBeyondPossibleTop(m,u.minY)?m=u.minY:this.isBeyondPossibleBottom(m,u.maxY)&&(m=u.maxY):e>1&&(m<u.minY?m=u.minY:m>u.maxY&&(m=u.maxY))),this.setZoomStyles({x:h,y:m,scale:e}),this.left=h,this.top=m,i&&this.setZoomImageSize()}},h.prototype.resetImageTranslate=function(e){if(this.isImageSlide(e)){var t=this.core.getSlideItem(e).find(".lg-image").first();this.imageReset=!1,t.removeClass("reset-transition reset-transition-y reset-transition-x"),this.core.outer.removeClass("lg-actual-size"),t.css("width","auto").css("height","auto"),setTimeout((function(){t.removeClass("no-transition")}),10)}},h.prototype.setZoomImageSize=function(){var e=this,t=this.core.getSlideItem(this.core.index).find(".lg-image").first();setTimeout((function(){var o=e.getCurrentImageActualSizeScale();e.scale>=o&&(t.addClass("no-transition"),e.imageReset=!0)}),500),setTimeout((function(){var o=e.getCurrentImageActualSizeScale();if(e.scale>=o){var i=e.getDragAllowedAxises(e.scale);t.css("width",t.get().naturalWidth+"px").css("height",t.get().naturalHeight+"px"),e.core.outer.addClass("lg-actual-size"),i.allowX&&i.allowY?t.addClass("reset-transition"):i.allowX&&!i.allowY?t.addClass("reset-transition-x"):!i.allowX&&i.allowY&&t.addClass("reset-transition-y")}}),550)},h.prototype.setZoomStyles=function(e){var t=this.core.getSlideItem(this.core.index).find(".lg-img-wrap").first(),o=this.core.getSlideItem(this.core.index).find(".lg-image").first(),i=this.core.outer.find(".lg-current .lg-dummy-img").first();this.scale=e.scale,o.css("transform","scale3d("+e.scale+", "+e.scale+", 1)"),i.css("transform","scale3d("+e.scale+", "+e.scale+", 1)");var s="translate3d("+e.x+"px, "+e.y+"px, 0)";t.css("transform",s)},h.prototype.setActualSize=function(e,t){var o=this;if(!this.zoomInProgress){this.zoomInProgress=!0;var i=this.core.galleryItems[this.core.index];this.resetImageTranslate(e),setTimeout((function(){if(i.src&&!o.core.outer.hasClass("lg-first-slide-loading")){var e=o.getCurrentImageActualSizeScale(),s=o.scale;o.core.outer.hasClass("lg-zoomed")?o.scale=1:o.scale=o.getScale(e),o.setPageCords(t),o.beginZoom(o.scale),o.zoomImage(o.scale,o.scale-s,!0,!0)}}),50),setTimeout((function(){o.core.outer.removeClass("lg-grabbing").addClass("lg-grab")}),60),setTimeout((function(){o.zoomInProgress=!1}),610)}},h.prototype.getNaturalWidth=function(e){var t=this.core.getSlideItem(e).find(".lg-image").first(),o=this.core.galleryItems[e].width;return o?parseFloat(o):t.get().naturalWidth},h.prototype.getActualSizeScale=function(e,t){return e>=t?e/t||2:1},h.prototype.getCurrentImageActualSizeScale=function(){var e=this.core.getSlideItem(this.core.index).find(".lg-image").first().get().offsetWidth,t=this.getNaturalWidth(this.core.index)||e;return this.getActualSizeScale(t,e)},h.prototype.getPageCords=function(e){var t={};if(e)t.x=e.pageX||e.touches[0].pageX,t.y=e.pageY||e.touches[0].pageY;else{var o=this.core.$content.get().getBoundingClientRect();t.x=o.width/2+o.left,t.y=o.height/2+this.scrollTop+o.top}return t},h.prototype.setPageCords=function(e){var t=this.getPageCords(e);this.pageX=t.x,this.pageY=t.y},h.prototype.manageActualPixelClassNames=function(){this.core.getElementById("lg-actual-size").removeClass(this.settings.actualSizeIcons.zoomIn).addClass(this.settings.actualSizeIcons.zoomOut)},h.prototype.beginZoom=function(e){return this.core.outer.removeClass("lg-zoom-drag-transition lg-zoom-dragging"),e>1?(this.core.outer.addClass("lg-zoomed"),this.manageActualPixelClassNames()):this.resetZoom(),e>1},h.prototype.getScale=function(e){var t=this.getCurrentImageActualSizeScale();return e<1?e=1:e>t&&(e=t),e},h.prototype.init=function(){var e=this;if(this.settings.zoom){this.buildTemplates(),this.enableZoomOnSlideItemLoad();var t=null;this.core.outer.on("dblclick.lg",(function(t){e.$LG(t.target).hasClass("lg-image")&&e.setActualSize(e.core.index,t)})),this.core.outer.on("touchstart.lg",(function(o){var i=e.$LG(o.target);1===o.touches.length&&i.hasClass("lg-image")&&(t?(clearTimeout(t),t=null,o.preventDefault(),e.setActualSize(e.core.index,o)):t=setTimeout((function(){t=null}),300))})),this.core.LGel.on(o+".zoom "+l+".zoom "+r+".zoom "+g+".zoom "+c+".zoom",(function(){if(e.core.lgOpened&&e.isImageSlide(e.core.index)&&!e.core.touchAction){var t=e.core.getSlideItem(e.core.index).find(".lg-img-wrap").first();e.top=0,e.left=0,e.setZoomEssentials(),e.setZoomSwipeStyles(t,{x:0,y:0}),e.positionChanged=!0}})),this.$LG(window).on("scroll.lg.zoom.global"+this.core.lgId,(function(){e.core.lgOpened&&(e.scrollTop=e.$LG(window).scrollTop())})),this.core.getElementById("lg-zoom-out").on("click.lg",(function(){if(e.isImageSlide(e.core.index)){var t=0;e.imageReset&&(e.resetImageTranslate(e.core.index),t=50),setTimeout((function(){var t=e.scale-e.settings.scale;t<1&&(t=1),e.beginZoom(t),e.zoomImage(t,-e.settings.scale,!0,!e.settings.infiniteZoom)}),t)}})),this.core.getElementById("lg-zoom-in").on("click.lg",(function(){e.zoomIn()})),this.core.getElementById("lg-actual-size").on("click.lg",(function(){e.setActualSize(e.core.index)})),this.core.LGel.on(i+".zoom",(function(){e.core.outer.find(".lg-item").removeClass("lg-zoomable")})),this.core.LGel.on(s+".zoom",(function(){e.scrollTop=e.$LG(window).scrollTop(),e.pageX=e.core.outer.width()/2,e.pageY=e.core.outer.height()/2+e.scrollTop,e.scale=1})),this.core.LGel.on(n+".zoom",(function(t){var o=t.detail.prevIndex;e.scale=1,e.positionChanged=!1,e.zoomInProgress=!1,e.resetZoom(o),e.resetImageTranslate(o),e.isImageSlide(e.core.index)&&e.setZoomEssentials()})),this.zoomDrag(),this.pinchZoom(),this.zoomSwipe(),this.zoomableTimeout=!1,this.positionChanged=!1,this.zoomInProgress=!1}},h.prototype.zoomIn=function(){if(this.isImageSlide(this.core.index)){var e=this.scale+this.settings.scale;this.settings.infiniteZoom||(e=this.getScale(e)),this.beginZoom(e),this.zoomImage(e,Math.min(this.settings.scale,e-this.scale),!0,!this.settings.infiniteZoom)}},h.prototype.resetZoom=function(e){this.core.outer.removeClass("lg-zoomed lg-zoom-drag-transition");var t=this.core.getElementById("lg-actual-size"),o=this.core.getSlideItem(void 0!==e?e:this.core.index);t.removeClass(this.settings.actualSizeIcons.zoomOut).addClass(this.settings.actualSizeIcons.zoomIn),o.find(".lg-img-wrap").first().removeAttr("style"),o.find(".lg-image").first().removeAttr("style"),this.scale=1,this.left=0,this.top=0,this.setPageCords()},h.prototype.getTouchDistance=function(e){return Math.sqrt((e.touches[0].pageX-e.touches[1].pageX)*(e.touches[0].pageX-e.touches[1].pageX)+(e.touches[0].pageY-e.touches[1].pageY)*(e.touches[0].pageY-e.touches[1].pageY))},h.prototype.pinchZoom=function(){var e=this,t=0,o=!1,i=1,s=0,a=this.core.getSlideItem(this.core.index);this.core.outer.on("touchstart.lg",(function(o){if(a=e.core.getSlideItem(e.core.index),e.isImageSlide(e.core.index)&&2===o.touches.length){if(o.preventDefault(),e.core.outer.hasClass("lg-first-slide-loading"))return;i=e.scale||1,e.core.outer.removeClass("lg-zoom-drag-transition lg-zoom-dragging"),e.setPageCords(o),e.resetImageTranslate(e.core.index),e.core.touchAction="pinch",t=e.getTouchDistance(o)}})),this.core.$inner.on("touchmove.lg",(function(n){if(2===n.touches.length&&"pinch"===e.core.touchAction&&(e.$LG(n.target).hasClass("lg-item")||a.get().contains(n.target))){n.preventDefault();var r=e.getTouchDistance(n),l=t-r;if(!o&&Math.abs(l)>5&&(o=!0),o){s=e.scale;var g=Math.max(1,i+.02*-l);e.scale=Math.round(100*(g+Number.EPSILON))/100;var c=e.scale-s;e.zoomImage(e.scale,Math.round(100*(c+Number.EPSILON))/100,!1,!1)}}})),this.core.$inner.on("touchend.lg",(function(i){if("pinch"===e.core.touchAction&&(e.$LG(i.target).hasClass("lg-item")||a.get().contains(i.target))){if(o=!1,t=0,e.scale<=1)e.resetZoom();else{var s=e.getCurrentImageActualSizeScale();if(e.scale>=s){var n=s-e.scale;0===n&&(n=.01),e.zoomImage(s,n,!1,!0)}e.manageActualPixelClassNames(),e.core.outer.addClass("lg-zoomed")}e.core.touchAction=void 0}}))},h.prototype.touchendZoom=function(e,t,o,i,s){var a=t.x-e.x,n=t.y-e.y,r=Math.abs(a)/s+1,l=Math.abs(n)/s+1;r>2&&(r+=1),l>2&&(l+=1),a*=r,n*=l;var g=this.core.getSlideItem(this.core.index).find(".lg-img-wrap").first(),c={};c.x=this.left+a,c.y=this.top+n;var h=this.getPossibleSwipeDragCords();(Math.abs(a)>15||Math.abs(n)>15)&&(i&&(this.isBeyondPossibleTop(c.y,h.minY)?c.y=h.minY:this.isBeyondPossibleBottom(c.y,h.maxY)&&(c.y=h.maxY)),o&&(this.isBeyondPossibleLeft(c.x,h.minX)?c.x=h.minX:this.isBeyondPossibleRight(c.x,h.maxX)&&(c.x=h.maxX)),i?this.top=c.y:c.y=this.top,o?this.left=c.x:c.x=this.left,this.setZoomSwipeStyles(g,c),this.positionChanged=!0)},h.prototype.getZoomSwipeCords=function(e,t,o,i,s){var a={};if(i){if(a.y=this.top+(t.y-e.y),this.isBeyondPossibleTop(a.y,s.minY)){var n=s.minY-a.y;a.y=s.minY-n/6}else if(this.isBeyondPossibleBottom(a.y,s.maxY)){var r=a.y-s.maxY;a.y=s.maxY+r/6}}else a.y=this.top;if(o){if(a.x=this.left+(t.x-e.x),this.isBeyondPossibleLeft(a.x,s.minX)){var l=s.minX-a.x;a.x=s.minX-l/6}else if(this.isBeyondPossibleRight(a.x,s.maxX)){var g=a.x-s.maxX;a.x=s.maxX+g/6}}else a.x=this.left;return a},h.prototype.isBeyondPossibleLeft=function(e,t){return e>=t},h.prototype.isBeyondPossibleRight=function(e,t){return e<=t},h.prototype.isBeyondPossibleTop=function(e,t){return e>=t},h.prototype.isBeyondPossibleBottom=function(e,t){return e<=t},h.prototype.isImageSlide=function(e){var t=this.core.galleryItems[e];return"image"===this.core.getSlideType(t)},h.prototype.getPossibleSwipeDragCords=function(e){var t=this.core.getSlideItem(this.core.index).find(".lg-image").first(),o=this.core.mediaContainerPosition.bottom,i=t.get().getBoundingClientRect(),s=i.height,a=i.width;return e&&(s+=e*s,a+=e*a),{minY:(s-this.containerRect.height)/2,maxY:(this.containerRect.height-s)/2+o,minX:(a-this.containerRect.width)/2,maxX:(this.containerRect.width-a)/2}},h.prototype.setZoomSwipeStyles=function(e,t){e.css("transform","translate3d("+t.x+"px, "+t.y+"px, 0)")},h.prototype.zoomSwipe=function(){var e,t,o=this,i={},s={},a=!1,n=!1,r=!1,l=new Date,g=(new Date,this.core.getSlideItem(this.core.index));this.core.$inner.on("touchstart.lg",(function(s){if(o.isImageSlide(o.core.index)&&(g=o.core.getSlideItem(o.core.index),(o.$LG(s.target).hasClass("lg-item")||g.get().contains(s.target))&&1===s.touches.length&&o.core.outer.hasClass("lg-zoomed"))){s.preventDefault(),l=new Date,o.core.touchAction="zoomSwipe",t=o.core.getSlideItem(o.core.index).find(".lg-img-wrap").first();var a=o.getDragAllowedAxises(0);r=a.allowY,((n=a.allowX)||r)&&(i=o.getSwipeCords(s)),e=o.getPossibleSwipeDragCords(),o.core.outer.addClass("lg-zoom-dragging lg-zoom-drag-transition")}})),this.core.$inner.on("touchmove.lg",(function(l){if(1===l.touches.length&&"zoomSwipe"===o.core.touchAction&&(o.$LG(l.target).hasClass("lg-item")||g.get().contains(l.target))){l.preventDefault(),o.core.touchAction="zoomSwipe",s=o.getSwipeCords(l);var c=o.getZoomSwipeCords(i,s,n,r,e);(Math.abs(s.x-i.x)>15||Math.abs(s.y-i.y)>15)&&(a=!0,o.setZoomSwipeStyles(t,c))}})),this.core.$inner.on("touchend.lg",(function(e){if("zoomSwipe"===o.core.touchAction&&(o.$LG(e.target).hasClass("lg-item")||g.get().contains(e.target))){if(e.preventDefault(),o.core.touchAction=void 0,o.core.outer.removeClass("lg-zoom-dragging"),!a)return;a=!1;var t=(new Date).valueOf()-l.valueOf();o.touchendZoom(i,s,n,r,t)}}))},h.prototype.zoomDrag=function(){var e,t,o,i,s=this,a={},n={},r=!1,l=!1,g=!1,c=!1;this.core.outer.on("mousedown.lg.zoom",(function(t){if(s.isImageSlide(s.core.index)){var n=s.core.getSlideItem(s.core.index);if(s.$LG(t.target).hasClass("lg-item")||n.get().contains(t.target)){e=ne
78w Date,i=s.core.getSlideItem(s.core.index).find(".lg-img-wrap").first();var l=s.getDragAllowedAxises(0);c=l.allowY,g=l.allowX,s.core.outer.hasClass("lg-zoomed")&&s.$LG(t.target).hasClass("lg-object")&&(g||c)&&(t.preventDefault(),a=s.getDragCords(t),o=s.getPossibleSwipeDragCords(),r=!0,s.core.outer.removeClass("lg-grab").addClass("lg-grabbing lg-zoom-drag-transition lg-zoom-dragging"))}}})),this.$LG(window).on("mousemove.lg.zoom.global"+this.core.lgId,(function(e){if(r){l=!0,n=s.getDragCords(e);var t=s.getZoomSwipeCords(a,n,g,c,o);s.setZoomSwipeStyles(i,t)}})),this.$LG(window).on("mouseup.lg.zoom.global"+this.core.lgId,(function(o){if(r){if(t=new Date,r=!1,s.core.outer.removeClass("lg-zoom-dragging"),l&&(a.x!==n.x||a.y!==n.y)){n=s.getDragCords(o);var i=t.valueOf()-e.valueOf();s.touchendZoom(a,n,g,c,i)}l=!1}s.core.outer.removeClass("lg-grabbing").addClass("lg-grab")}))},h.prototype.closeGallery=function(){this.resetZoom(),this.zoomInProgress=!1},h.prototype.destroy=function(){this.$LG(window).off(".lg.zoom.global"+this.core.lgId),this.core.LGel.off(".lg.zoom"),this.core.LGel.off(".zoom"),clearTimeout(this.zoomableTimeout),this.zoomableTimeout=!1},h}()}));
79/* End */
80;
81; /* Start:"a:4:{s:4:"full";s:86:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-video.min.js?17349563508341";s:6:"source";s:71:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-video.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
82/**
83 * lightgallery | 2.7.2 | September 20th 2023
84 * http://www.lightgalleryjs.com/
85 * Copyright (c) 2020 Sachin Neravath;
86 * @license GPLv3
87 */
88
89!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o():"function"==typeof define&&define.amd?define(o):(e="undefined"!=typeof globalThis?globalThis:e||self).lgVideo=o()}(this,(function(){"use strict";var e=function(){return(e=Object.assign||function(e){for(var o,i=1,t=arguments.length;i<t;i++)for(var s in o=arguments[i])Object.prototype.hasOwnProperty.call(o,s)&&(e[s]=o[s]);return e}).apply(this,arguments)},o={autoplayFirstVideo:!0,youTubePlayerParams:!1,vimeoPlayerParams:!1,wistiaPlayerParams:!1,gotoNextSlideOnVideoEnd:!0,autoplayVideoOnSlide:!1,videojs:!1,videojsTheme:"",videojsOptions:{}},i="lgHasVideo",t="lgSlideItemLoad",s="lgBeforeSlide",n="lgAfterSlide",l="lgPosterClick",r=function(e){return Object.keys(e).map((function(o){return encodeURIComponent(o)+"="+encodeURIComponent(e[o])})).join("&")},d=function(o,i){if(!o.youtube)return"";var t=o.youtube[2]?o.youtube[2].slice(1).split("&").map((function(e){return e.split("=")})).reduce((function(e,o){var i=o.map(decodeURIComponent),t=i[0],s=i[1];return e[t]=s,e}),{}):"",s=i||{},n=e(e(e({},{wmode:"opaque",autoplay:0,mute:1,enablejsapi:1}),s),t);return"?"+r(n)};return function(){function a(i){return this.core=i,this.settings=e(e({},o),this.core.settings),this}return a.prototype.init=function(){var e=this;this.core.LGel.on(i+".video",this.onHasVideo.bind(this)),this.core.LGel.on(l+".video",(function(){var o=e.core.getSlideItem(e.core.index);e.loadVideoOnPosterClick(o)})),this.core.LGel.on(t+".video",this.onSlideItemLoad.bind(this)),this.core.LGel.on(s+".video",this.onBeforeSlide.bind(this)),this.core.LGel.on(n+".video",this.onAfterSlide.bind(this))},a.prototype.onSlideItemLoad=function(e){var o=this,i=e.detail,t=i.isFirstSlide,s=i.index;this.settings.autoplayFirstVideo&&t&&s===this.core.index&&setTimeout((function(){o.loadAndPlayVideo(s)}),200),!t&&this.settings.autoplayVideoOnSlide&&s===this.core.index&&this.loadAndPlayVideo(s)},a.prototype.onHasVideo=function(e){var o=e.detail,i=o.index,t=o.src,s=o.html5Video;o.hasPoster||(this.appendVideos(this.core.getSlideItem(i),{src:t,addClass:"lg-object",index:i,html5Video:s}),this.gotoNextSlideOnVideoEnd(t,i))},a.prototype.onBeforeSlide=function(e){if(this.core.lGalleryOn){var o=e.detail.prevIndex;this.pauseVideo(o)}},a.prototype.onAfterSlide=function(e){var o=this,i=e.detail,t=i.index,s=i.prevIndex,n=this.core.getSlideItem(t);this.settings.autoplayVideoOnSlide&&t!==s&&n.hasClass("lg-complete")&&setTimeout((function(){o.loadAndPlayVideo(t)}),100)},a.prototype.loadAndPlayVideo=function(e){var o=this.core.getSlideItem(e);this.core.galleryItems[e].poster?this.loadVideoOnPosterClick(o,!0):this.playVideo(e)},a.prototype.playVideo=function(e){this.controlVideo(e,"play")},a.prototype.pauseVideo=function(e){this.controlVideo(e,"pause")},a.prototype.getVideoHtml=function(e,o,i,t){var s="",n=this.core.galleryItems[i].__slideVideoInfo||{},l=this.core.galleryItems[i],a=l.title||l.alt;a=a?'title="'+a+'"':"";var c='allowtransparency="true"\n            frameborder="0"\n            scrolling="no"\n            allowfullscreen\n            mozallowfullscreen\n            webkitallowfullscreen\n            oallowfullscreen\n            msallowfullscreen';if(n.youtube){var u="lg-youtube"+i,f=d(n,this.settings.youTubePlayerParams);s='<iframe allow="autoplay" id='+u+' class="lg-video-object lg-youtube '+o+'" '+a+' src="'+(e.includes("youtube-nocookie.com")?"//www.youtube-nocookie.com/":"//www.youtube.com/")+"embed/"+(n.youtube[1]+f)+'" '+c+"></iframe>"}else if(n.vimeo){u="lg-vimeo"+i;var h=function(e,o){if(!o||!o.vimeo)return"";var i=o.vimeo[2]||"",t=e&&0!==Object.keys(e).length?"&"+r(e):"",s=((o.vimeo[0].split("/").pop()||"").split("?")[0]||"").split("#")[0],n=o.vimeo[1]!==s;return n&&(i=i.replace("/"+s,"")),"?autoplay=0&muted=1"+(n?"&h="+s:"")+t+("?"==i[0]?"&"+i.slice(1):i||"")}(this.settings.vimeoPlayerParams,n);s='<iframe allow="autoplay" id='+u+' class="lg-video-object lg-vimeo '+o+'" '+a+' src="//player.vimeo.com/video/'+(n.vimeo[1]+h)+'" '+c+"></iframe>"}else if(n.wistia){var p="lg-wistia"+i;h=(h=r(this.settings.wistiaPlayerParams))?"?"+h:"",s='<iframe allow="autoplay" id="'+p+'" src="//fast.wistia.net/embed/iframe/'+(n.wistia[4]+h)+'" '+a+' class="wistia_embed lg-video-object lg-wistia '+o+'" name="wistia_embed" '+c+"></iframe>"}else if(n.html5){for(var y="",g=0;g<t.source.length;g++)y+='<source src="'+t.source[g].src+'" type="'+t.source[g].type+'">';if(t.tracks){var v=function(e){var o="",i=t.tracks[e];Object.keys(i||{}
vendor: 4,666 bytes, lines 89-100
89).forEach((function(e){o+=e+'="'+i[e]+'" '})),y+="<track "+o+">"};for(g=0;g<t.tracks.length;g++)v(g)}var m="",w=t.attributes||{};Object.keys(w||{}).forEach((function(e){m+=e+'="'+w[e]+'" '})),s='<video class="lg-video-object lg-html5 '+(this.settings.videojs&&this.settings.videojsTheme?this.settings.videojsTheme+" ":"")+" "+(this.settings.videojs?" video-js":"")+'" '+m+">\n                "+y+"\n                Your browser does not support HTML5 video.\n            </video>"}return s},a.prototype.appendVideos=function(e,o){var i,t=this.getVideoHtml(o.src,o.addClass,o.index,o.html5Video);e.find(".lg-video-cont").append(t);var s=e.find(".lg-video-object").first();if(o.html5Video&&s.on("mousedown.lg.video",(function(e){e.stopPropagation()})),this.settings.videojs&&(null===(i=this.core.galleryItems[o.index].__slideVideoInfo)||void 0===i?void 0:i.html5))try{return videojs(s.get(),this.settings.videojsOptions)}catch(e){console.error("lightGallery:- Make sure you have included videojs")}},a.prototype.gotoNextSlideOnVideoEnd=function(e,o){var i=this,t=this.core.getSlideItem(o).find(".lg-video-object").first(),s=this.core.galleryItems[o].__slideVideoInfo||{};if(this.settings.gotoNextSlideOnVideoEnd)if(s.html5)t.on("ended",(function(){i.core.goToNextSlide()}));else if(s.vimeo)try{new Vimeo.Player(t.get()).on("ended",(function(){i.core.goToNextSlide()}))}catch(e){console.error("lightGallery:- Make sure you have included //github.com/vimeo/player.js")}else if(s.wistia)try{window._wq=window._wq||[],window._wq.push({id:t.attr("id"),onReady:function(e){e.bind("end",(function(){i.core.goToNextSlide()}))}})}catch(e){console.error("lightGallery:- Make sure you have included //fast.wistia.com/assets/external/E-v1.js")}},a.prototype.controlVideo=function(e,o){var i=this.core.getSlideItem(e).find(".lg-video-object").first(),t=this.core.galleryItems[e].__slideVideoInfo||{};if(i.get())if(t.youtube)try{i.get().contentWindow.postMessage('{"event":"command","func":"'+o+'Video","args":""}',"*")}catch(e){console.error("lightGallery:- "+e)}else if(t.vimeo)try{new Vimeo.Player(i.get())[o]()}catch(e){console.error("lightGallery:- Make sure you have included //github.com/vimeo/player.js")}else if(t.html5)if(this.settings.videojs)try{videojs(i.get())[o]()}catch(e){console.error("lightGallery:- Make sure you have included videojs")}else i.get()[o]();else if(t.wistia)try{window._wq=window._wq||[],window._wq.push({id:i.attr("id"),onReady:function(e){e[o]()}})}catch(e){console.error("lightGallery:- Make sure you have included //fast.wistia.com/assets/external/E-v1.js")}},a.prototype.loadVideoOnPosterClick=function(e,o){var i=this;if(e.hasClass("lg-video-loaded"))o&&this.playVideo(this.core.index);else if(e.hasClass("lg-has-video"))this.playVideo(this.core.index);else{e.addClass("lg-has-video");var t=void 0,s=this.core.galleryItems[this.core.index].src,n=this.core.galleryItems[this.core.index].video;n&&(t="string"==typeof n?JSON.parse(n):n);var l=this.appendVideos(e,{src:s,addClass:"",index:this.core.index,html5Video:t});this.gotoNextSlideOnVideoEnd(s,this.core.index);var r=e.find(".lg-object").first().get();e.find(".lg-video-cont").first().append(r),e.addClass("lg-video-loading"),l&&l.ready((function(){l.on("loadedmetadata",(function(){i.onVideoLoadAfterPosterClick(e,i.core.index)}))})),e.find(".lg-video-object").first().on("load.lg error.lg loadedmetadata.lg",(function(){setTimeout((function(){i.onVideoLoadAfterPosterClick(e,i.core.index)}),50)}))}},a.prototype.onVideoLoadAfterPosterClick=function(e,o){e.addClass("lg-video-loaded"),this.playVideo(o)},a.prototype.destroy=function(){this.core.LGel.off(".lg.video"),this.core.LGel.off(".video")},a}()}));
90/* End */
91;
92; /* Start:"a:4:{s:4:"full";s:90:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-thumbnail.min.js?17349563509270";s:6:"source";s:75:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-thumbnail.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
93/**
94 * lightgallery | 2.7.2 | September 20th 2023
95 * http://www.lightgalleryjs.com/
96 * Copyright (c) 2020 Sachin Neravath;
97 * @license GPLv3
98 */
99
100!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).lgThumbnail=e()}(this,(function(){"use strict";var t=function(){return(t=Object.assign||function(t){for(var e,i=1,s=arguments.length;i<s;i++)for(var h in e=arguments[i])Object.prototype.hasOwnProperty.call(e,h)&&(t[h]=e[h]);return t}).apply(this,arguments)},e={thumbnail:!0,animateThumb:!0,currentPagerPosition:"middle",alignThumbnails:"middle",thumbWidth:100,thumbHe
vendor: 6,418 bytes, line 100
100ight:"80px",thumbMargin:5,appendThumbnailsTo:".lg-components",toggleThumb:!1,enableThumbDrag:!0,enableThumbSwipe:!0,thumbnailSwipeThreshold:10,loadYouTubeThumbnail:!0,youTubeThumbSize:1,thumbnailPluginStrings:{toggleThumbnails:"Toggle thumbnails"}},i="lgContainerResize",s="lgUpdateSlides",h="lgBeforeOpen",n="lgBeforeSlide";return function(){function o(t,e){return this.thumbOuterWidth=0,this.thumbTotalWidth=0,this.translateX=0,this.thumbClickable=!1,this.core=t,this.$LG=e,this}return o.prototype.init=function(){this.settings=t(t({},e),this.core.settings),this.thumbOuterWidth=0,this.thumbTotalWidth=this.core.galleryItems.length*(this.settings.thumbWidth+this.settings.thumbMargin),this.translateX=0,this.setAnimateThumbStyles(),this.core.settings.allowMediaOverlap||(this.settings.toggleThumb=!1),this.settings.thumbnail&&(this.build(),this.settings.animateThumb?(this.settings.enableThumbDrag&&this.enableThumbDrag(),this.settings.enableThumbSwipe&&this.enableThumbSwipe(),this.thumbClickable=!1):this.thumbClickable=!0,this.toggleThumbBar(),this.thumbKeyPress())},o.prototype.build=function(){var t=this;this.setThumbMarkup(),this.manageActiveClassOnSlideChange(),this.$lgThumb.first().on("click.lg touchend.lg",(function(e){var i=t.$LG(e.target);i.hasAttribute("data-lg-item-id")&&setTimeout((function(){if(t.thumbClickable&&!t.core.lgBusy){var e=parseInt(i.attr("data-lg-item-id"));t.core.slide(e,!1,!0,!1)}}),50)})),this.core.LGel.on(n+".thumb",(function(e){var i=e.detail.index;t.animateThumb(i)})),this.core.LGel.on(h+".thumb",(function(){t.thumbOuterWidth=t.core.outer.get().offsetWidth})),this.core.LGel.on(s+".thumb",(function(){t.rebuildThumbnails()})),this.core.LGel.on(i+".thumb",(function(){t.core.lgOpened&&setTimeout((function(){t.thumbOuterWidth=t.core.outer.get().offsetWidth,t.animateThumb(t.core.index),t.thumbOuterWidth=t.core.outer.get().offsetWidth}),50)}))},o.prototype.setThumbMarkup=function(){var t="lg-thumb-outer ";this.settings.alignThumbnails&&(t+="lg-thumb-align-"+this.settings.alignThumbnails);var e='<div class="'+t+'">\n        <div class="lg-thumb lg-group">\n        </div>\n        </div>';this.core.outer.addClass("lg-has-thumb"),".lg-components"===this.settings.appendThumbnailsTo?this.core.$lgComponents.append(e):this.core.outer.append(e),this.$thumbOuter=this.core.outer.find(".lg-thumb-outer").first(),this.$lgThumb=this.core.outer.find(".lg-thumb").first(),this.settings.animateThumb&&this.core.outer.find(".lg-thumb").css("transition-duration",this.core.settings.speed+"ms").css("width",this.thumbTotalWidth+"px").css("position","relative"),this.setThumbItemHtml(this.core.galleryItems)},o.prototype.enableThumbDrag=function(){var t=this,e={cords:{startX:0,endX:0},isMoved:!1,newTranslateX:0,startTime:new Date,endTime:new Date,touchMoveTime:0},i=!1;this.$thumbOuter.addClass("lg-grab"),this.core.outer.find(".lg-thumb").first().on("mousedown.lg.thumb",(function(s){t.thumbTotalWidth>t.thumbOuterWidth&&(s.preventDefault(),e.cords.startX=s.pageX,e.startTime=new Date,t.thumbClickable=!1,i=!0,t.core.outer.get().scrollLeft+=1,t.core.outer.get().scrollLeft-=1,t.$thumbOuter.removeClass("lg-grab").addClass("lg-grabbing"))})),this.$LG(window).on("mousemove.lg.thumb.global"+this.core.lgId,(function(s){t.core.lgOpened&&i&&(e.cords.endX=s.pageX,e=t.onThumbTouchMove(e))})),this.$LG(window).on("mouseup.lg.thumb.global"+this.core.lgId,(function(){t.core.lgOpened&&(e.isMoved?e=t.onThumbTouchEnd(e):t.thumbClickable=!0,i&&(i=!1,t.$thumbOuter.removeClass("lg-grabbing").addClass("lg-grab")))}))},o.prototype.enableThumbSwipe=function(){var t=this,e={cords:{startX:0,endX:0},isMoved:!1,newTranslateX:0,startTime:new Date,endTime:new Date,touchMoveTime:0};this.$lgThumb.on("touchstart.lg",(function(i){t.thumbTotalWidth>t.thumbOuterWidth&&(i.preventDefault(),e.cords.startX=i.targetTouches[0].pageX,t.thumbClickable=!1,e.startTime=new Date)})),this.$lgThumb.on("touchmove.lg",(function(i){t.thumbTotalWidth>t.thumbOuterWidth&&(i.preventDefault(),e.cords.endX=i.targetTouches[0].pageX,e=t.onThumbTouchMove(e))})),this.$lgThumb.on("touchend.lg",(function(){e.isMoved?e=t.onThumbTouchEnd(e):t.thumbClickable=!0}))},o.prototype.rebuildThumbnails=function(){var t=this;this.$thumbOuter.addClass("lg-rebuilding-thumbnails"),setTimeout((function(){t.thumbTotalWidth=t.core.galleryItems.length*(t.settings.thumbWidth+t.settings.thumbMargin),t.$lgThumb.css("width",t.thumbTotalWidth+"px"),t.$lgThumb.empty(),t.setThumbItemHtml(t.core.galleryItems),t.animateThumb(t.core.index)}),50),setTimeout((function(){t.$thumbOuter.removeClass("lg-rebuilding-thumbnails")}),200)},o.prototype.setTranslate=function(t){this.$lgThumb.css("transform","translate3d(-"+t+"px, 0px, 0px)")},o.prototype.getPossibleTransformX=function(t){return t>this.thumbTotalWidth-this.thumbOuterWidth&&(t=this.thumbTotalWidth-this.thumbOuterWidth),t<0&&(t=0),t},o.prototype.animateThumb=function(t){if(this.$lgThumb.css("transition-duration",this.core.settings.speed+"ms"),this.settings.animateThumb){var e=0;switch(this.settings.currentPagerPosition){case"left":e=0;break;case"middle":e=this.thumbOuterWidth/2-this.settings.thumbWidth/2;break;case"right":e=this.thumbOuterWidth-this.settings.thumbWidth}this.translateX=(this.settings.thumbWidth+this.settings.thumbMargin)*t-1-e,this.translateX>this.thumbTotalWidth-this.thumbOuterWidth&&(this.translateX=this.thumbTotalWidth-this.thumbOuterWidth),this.translateX<0&&(this.translateX=0),this.setTranslate(this.translateX)}},o.prototype.onThumbTouchMove=function(t){return t.newTranslateX=this.translateX,t.isMoved=!0,t.touchMoveTime=(new Date).valueOf(),t.newTranslateX-=t.cords.endX-t.cords.startX,t.newTranslateX=this.getPossibleTransformX(t.newTranslateX),this.setTranslate(t.newTranslateX),this.$thumbOuter.addClass("lg-dragging"),t},o.prototype.onThumbTouchEnd=function(t){t.isMoved=!1,t.endTime=new Date,this.$thumbOuter.removeClass("lg-dragging");var e=t.endTime.valueOf()-t.startTime.valueOf(),i=t.cords.endX-t.cords.startX,s=Math.abs(i)/e;return s>.15&&t.endTime.valueOf()-t.touchMoveTime<30?((s+=1)>2&&(s+=1),s+=s*(Math.abs(i)/this.thumbOuterWidth),this.$lgThumb.css("transition-duration",Math.min(s-1,2)+"settings"),i*=s,this.translateX=this.getPossibleTransformX(this.translateX-i),this.setTranslate(this.translateX)):this.translateX=t.newTranslateX,Math.abs(t.cords.endX-t.cords.startX)<this.settings.thumbnailSwipeThreshold&&(this.thumbClickable=!0),t}
100,o.prototype.getThumbHtml=function(t,e,i){var s,h=this.core.galleryItems[e].__slideVideoInfo||{};s=h.youtube&&this.settings.loadYouTubeThumbnail?"//img.youtube.com/vi/"+h.youtube[1]+"/"+this.settings.youTubeThumbSize+".jpg":t;var n=i?'alt="'+i+'"':"";return'<div data-lg-item-id="'+e+'" class="lg-thumb-item '+(e===this.core.index?" active":"")+'"\n        style="width:'+this.settings.thumbWidth+"px; height: "+this.settings.thumbHeight+";\n            margin-right: "+this.settings.thumbMargin+'px;">\n            <img '+n+' data-lg-item-id="'+e+'" src="'+s+'" />\n        </div>'},o.prototype.getThumbItemHtml=function(t){for(var e="",i=0;i<t.length;i++)e+=this.getThumbHtml(t[i].thumb,i,t[i].alt);return e},o.prototype.setThumbItemHtml=function(t){var e=this.getThumbItemHtml(t);this.$lgThumb.html(e)},o.prototype.setAnimateThumbStyles=function(){this.settings.animateThumb&&this.core.outer.addClass("lg-animate-thumb")},o.prototype.manageActiveClassOnSlideChange=function(){var t=this;this.core.LGel.on(n+".thumb",(function(e){var i=t.core.outer.find(".lg-thumb-item"),s=e.detail.index;i.removeClass("active"),i.eq(s).addClass("active")}))},o.prototype.toggleThumbBar=function(){var t=this;this.settings.toggleThumb&&(this.core.outer.addClass("lg-can-toggle"),this.core.$toolbar.append('<button type="button" aria-label="'+this.settings.thumbnailPluginStrings.toggleThumbnails+'" class="lg-toggle-thumb lg-icon"></button>'),this.core.outer.find(".lg-toggle-thumb").first().on("click.lg",(function(){t.core.outer.toggleClass("lg-components-open")})))},o.prototype.thumbKeyPress=function(){var t=this;this.$LG(window).on("keydown.lg.thumb.global"+this.core.lgId,(function(e){t.core.lgOpened&&t.settings.toggleThumb&&(38===e.keyCode?(e.preventDefault(),t.core.outer.addClass("lg-components-open")):40===e.keyCode&&(e.preventDefault(),t.core.outer.removeClass("lg-components-open")))}))},o.prototype.destroy=function(){this.settings.thumbnail&&(this.$LG(window).off(".lg.thumb.global"+this.core.lgId),this.core.LGel.off(".lg.thumb"),this.core.LGel.off(".thumb"),this.$thumbOuter.remove(),this.core.outer.removeClass("lg-has-thumb"))},o}()}));
101/* End */
102;
103; /* Start:"a:4:{s:4:"full";s:91:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/prism-toolbar.min.js?17319319811757";s:6:"source";s:76:"/local/templates/CAIMAN_2025/assets/vendor/lightgallery/prism-toolbar.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
104!function(){if("undefined"!=typeof Prism&&"undefined"!=typeof document){var e=[],t={},n=function(){};Prism.plugins.toolbar={};var a=Prism.plugins.toolbar.registerButton=function(n,a){var r;r="function"==typeof a?a:function(e){var t;return"function"==typeof a.onClick?((t=document.createElement("button")).type="button",t.addEventListener("click",(function(){a.onClick.call(this,e)}))):"string"==typeof a.url?(t=document.createElement("a")).href=a.url:t=document.createElement("span"),a.className&&t.classList.add(a.className),t.textContent=a.text,t},n in t?console.warn('There is a button with the key "'+n+'" registered already.'):e.push(t[n]=r)},r=Prism.plugins.toolbar.hook=function(a){var r=a.element.parentNode;if(r&&/pre/i.test(r.nodeName)&&!r.parentNode.classList.contains("code-toolbar")){var o=document.createElement("div");o.classList.add("code-toolbar"),r.parentNode.insertBefore(o,r),o.appendChild(r);var i=document.createElement("div");i.classList.add("toolbar");var l=e,d=function(e){for(;e;){var t=e.getAttribute("data-toolbar-order");if(null!=t)return(t=t.trim()).length?t.split(/\s*,\s*/g):[];e=e.parentElement}}(a.element);d&&(l=d.map((function(e){return t[e]||n}))),l.forEach((function(e){var t=e(a);if(t){var n=document.createElement("div");n.classList.add("toolbar-item"),n.appendChild(t),i.appendChild(n)}})),o.appendChild(i)}};a("label",(function(e){var t=e.element.parentNode;if(t&&/pre/i.test(t.nodeName)&&t.hasAttribute("data-label")){var n,a,r=t.getAttribute("data-label");try{a=document.querySelector("template#"+r)}catch(e){}return a?n=a.content:(t.hasAttribute("data-url")?(n=document.createElement("a")).href=t.getAttribute("data-url"):n=document.createElement("span"),n.textContent=r),n}})),Prism.hooks.add("complete",r)}}();
105/* End */
106;
107; /* Start:"a:4:{s:4:"full";s:87:"/local/templates/CAIMAN_2025/assets/jquery.inputmask/jquery.inputmask.js?17437605239265";s:6:"source";s:72:"/local/templates/CAIMAN_2025/assets/jquery.inputmask/jquery.inputmask.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
108BX.ready(function(){
109!function(a) {
110    "function" == typeof define && define.amd ? define(["jquery"], a) : a("object" == typeof exports ? require("jquery") : jQuery)
111}(function(a) {
112    var b, c = navigator.userAgent,
113        d = /iphone/i.test(c),
114        e = /chrome/i.test(c),
115        f = /android/i.test(c);
116    a.mask = {
117        definitions: {
118            9: "[0-9]",
119            a: "[A-Za-z]",
120            "*": "[A-Za-z0-9]"
121        },
122        autoclear: !0,
123        dataName: "rawMaskFn",
124        placeholder: "_"
125    }, a.fn.extend({
126        caret: function(a, b) {
127            var c;
128            if (0 !== this.length && !this.is(":hidden")) return "number" == typeof a ? (b = "number" == typeof b ? b : a, this.each(function() {
129                this.setSelectionRange ? this.setSelectionRange(a, b) : this.createTextRange && (c = this.createTextRange(), c.collapse(!0), c.moveEnd("character", b), c.moveStart("character", a), c.select())
130            })) : (this[0].setSelectionRange ? (a = this[0].selectionStart, b = this[0].selectionEnd) : document.selection && document.selection.createRange && (c = document.selection.createRange(), a = 0 - c.duplicate().moveStart("character", -1e5), b = a + c.text.length), {
131                begin: a,
132                end: b
133            })
134        },
135        unmask: function() {
136            return this.trigger("unmask")
137        },
138        mask: function(c, g) {
139            var h, i, j, k, l, m, n, o;
140            if (!c && this.length > 0) {
141                h = a(this[0]);
142                var p = h.data(a.mask.dataName);
143                return p ? p() : void 0
144            }
145            return g = a.extend({
146                autoclear: a.mask.autoclear,
147                placeholder: a.mask.placeholder,
148                completed: null
149            }, g), i = a.mask.definitions, j = [], k = n = c.length, l = null, a.each(c.split(""), function(a, b) {
150                "?" == b ? (n--, k = a) : i[b] ? (j.push(new RegExp(i[b])), null === l && (l = j.length - 1), k > a && (m = j.length - 1)) : j.push(null)
151            }), this.trigger("unmask").each(function() {
152                function h() {
153                    if (g.completed) {
154                        for (var a = l; m >= a; a++)
155                            if (j[a] && C[a] === p(a)) return;
156                        g.completed.call(B)
157                    }
158                }
159
160                function p(a) {
161                    return g.placeholder.charAt(a < g.placeholder.length ? a : 0)
162                }
163
164                function q(a) {
165                    for (; ++a < n && !j[a];);
166                    return a
167                }
168
169                function r(a) {
170                    for (; --a >= 0 && !j[a];);
171                    return a
172                }
173
174                function s(a, b) {
175                    var c, d;
176                    if (!(0 > a)) {
177                        for (c = a, d = q(b); n > c; c++)
178                            if (j[c]) {
179                                if (!(n > d && j[c].test(C[d]))) break;
180                                C[c] = C[d], C[d] = p(d), d = q(d)
181                            } z(), B.caret(Math.max(l, a))
182                    }
183                }
184
185                function t(a) {
186                    var b, c, d, e;
187                    for (b = a, c = p(a); n > b; b++)
188                        if (j[b]) {
189                            if (d = q(b), e = C[b], C[b] = c, !(n > d && j[d].test(e))) break;
190                            c = e
191                        }
192                }
193
194                function u() {
195                    var a = B.val(),
196                        b = B.caret();
197                    if (a.length < o.length) {
198                        for (A(!0); b.begin > 0 && !j[b.begin - 1];) b.begin--;
199                        if (0 === b.begin)
200                            for (; b.begin < l && !j[b.begin];) b.begin++;
201                        B.caret(b.begin, b.begin)
202                    } else {
203                        for (A(!0); b.begin < n && !j[b.begin];) b.begin++;
204                        B.caret(b.begin, b.begin)
205                    }
206                    h()
207                }
208
209                function v() {
210                    A(), B.val() != E && B.change()
211                }
212
213                function w(a) {
214                    if (!B.prop("readonly")) {
215                        var b, c, e, f = a.which || a.keyCode;
216                        o = B.val(), 8 === f || 46 === f || d && 127 === f ? (b = B.caret(), c = b.begin, e = b.end, e - c === 0 && (c = 46 !== f ? r(c) : e = q(c - 1), e = 46 === f ? q(e) : e), y(c, e), s(c, e - 1), a.preventDefault()) : 13 === f ? v.call(this, a) : 27 === f && (B.val(E), B.caret(0, A()), a.preventDefault())
217                    }
218                }
219
220                function x(b) {
221                    if (!B.prop("readonly")) {
222                        var c, d, e, g = b.which || b.keyCode,
223                            i = B.caret();
224                        if (!(b.ctrlKey || b.altKey || b.metaKey || 32 > g) && g && 13 !== g) {
225                            if (i.end - i.begin !== 0 && (y(i.begin, i.end), s(i.begin, i.end - 1)), c = q(i.begin - 1), n > c && (d = String.fromCharCode(g), j[c].test(d))) {
226                                if (t(c), C[c] = d, z(), e = q(c), f) {
227                                    var k = function() {
228                                        a.proxy(a.fn.caret, B, e)()
229                                    };
230                                    setTimeout(k, 0)
231                                } else B.caret(e);
232                                i.begin <= m && h()
233                            }
234                            b.preventDefault()
235                        }
236                    }
237                }
238
239                function y(a, b) {
240                    var c;
241                    for (c = a; b > c && n > c; c++) j[c] && (C[c] = p(c))
242                }
243
244                function z() {
245                    B.val(C.join(""))
246                }
247
248                function A(a) {
249                    var b, c, d, e = B.val(),
250                        f = -1;
251                    for (b = 0, d = 0; n > b; b++)
252                        if (j[b]) {
253                            for (C[b] = p(b); d++ < e.length;)
254                                if (c = e.charAt(d - 1), j[b].test(c)) {
255                                    C[b] = c, f = b;
256                                    break
257                                } if (d > e.length) {
258                                y(b + 1, n);
259                                break
260                            }
261                        } else C[b] === e.charAt(d) && d++, k > b && (f = b);
262                    return a ? z() : k > f + 1 ? g.autoclear || C.join("") === D ? (B.val() && B.val(""), y(0, n)) : z() : (z(), B.val(B.val().substring(0, f + 1))), k ? b : l
263                }
264                var B = a(this),
265                    C = a.map(c.split(""), function(a, b) {
266                        return "?" != a ? i[a] ? p(b) : a : void 0
267                    }),
268                    D = C.join(""),
269                    E = B.val();
270                B.data(a.mask.dataName, function() {
271                    return a.map(C, function(a, b) {
272                        return j[b] && a != p(b) ? a : null
273                    }).join("")
274                }), B.one("unmask", function() {
275                    B.off(".mask").removeData(a.mask.dataName)
276                }).on("focus.mask", function() {
277                    if (!B.prop("readonly")) {
278                        clearTimeout(b);
279                        var a;
280                        E = B.val(), a = A(), b = setTimeout(function() {
281                            z(), a == c.replace("?", "").length ? B.caret(0, a) : B.caret(a)
282                        }, 10)
283                    }
284                }).on("blur.mask", v).on("keydown.mask", w).on("keypress.mask", x).on("input.mask paste.mask", function() {
285                    B.prop("readonly") || setTimeout(function() {
286                        var a = A(!0);
287                        B.caret(a), h()
288                    }, 0)
289                }), e && f && B.off("input.mask").on("input.mask", u), A()
290            })
291        }
292    })
293});
294	
295	phoneFormat("ru");
296});
297
298
299function phoneFormat(f)
300{
301	/*
302		Данная маска иногда вызывает потерю клиента, некоторые люди не видят +7 и пишут 8903... 
303		в итоге теряется последняя цифра телефона. 
304		Лучше использовать другую маску $.mask.definitions['h'] c блокировкой первой цифры 8
305	*/
306	if(f=="by")
307	{
308
309		$('input[type=tel],input[rel=tel]').mask("+375 (99) 999-99-99");
310		$('input[type=tel],input[rel=tel]').attr("placeholder", "+375 (__) ___-__-__");
311	}
312	else
313	{
314		$.mask.definitions['h'] = "[0|1|3|4|5|6|9]";
315		$('input[type=tel],input[rel=tel]').mask("+7 (h99) 999-99-99");
316		$('input[type=tel],input[rel=tel]').attr("placeholder", "+7 (___) ___-__-__");
317	}
318}
319/* End */
320;
321; /* Start:"a:4:{s:4:"full";s:81:"/local/templates/CAIMAN_2025/assets/vendor/shuffle/shuffle.min.js?175749375316987";s:6:"source";s:65:"/local/templates/CAIMAN_2025/assets/vendor/shuffle/shuffle.min.js";s:3:"min";s:65:"/local/templates/CAIMAN_2025/assets/vendor/shuffle/shuffle.min.js";s:3:"map";s:69:"/local/templates/CAIMAN_2025/assets/vendor/shuffle/shuffle.min.js.map";}"*/
322!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).Shuffle=e()}(this,(function(){"use strict";var t={},e={get exports(){return t},set exports(e){t=e}};function i(){}
322i.prototype={on:function(t,e,i){var s=this.e||(this.e={});return(s[t]||(s[t]=[])).push({fn:e,ctx:i}),this},once:function(t,e,i){var s=this;function n(){s.off(t,n),e.apply(i,arguments)}return n._=e,this.on(t,n,i)},emit:function(t){for(var e=[].slice.call(arguments,1),i=((this.e||(this.e={}))[t]||[]).slice(),s=0,n=i.length;s<n;s++)i[s].fn.apply(i[s].ctx,e);return this},off:function(t,e){var i=this.e||(this.e={}),s=i[t],n=[];if(s&&e)for(var o=0,r=s.length;o<r;o++)s[o].fn!==e&&s[o].fn._!==e&&n.push(s[o]);return n.length?i[t]=n:delete i[t],this}},e.exports=i,t.TinyEmitter=i;function s(){}function n(t){return parseFloat(t)||0}var o=class{constructor(t,e){this.x=n(t),this.y=n(e)}static equals(t,e){return t.x===e.x&&t.y===e.y}};class r{constructor(t,e,i,s,n){this.id=n,this.left=t,this.top=e,this.width=i,this.height=s}static intersects(t,e){return t.left<e.left+e.width&&e.left<t.left+t.width&&t.top<e.top+e.height&&e.top<t.top+t.height}}var h={BASE:"shuffle",SHUFFLE_ITEM:"shuffle-item",VISIBLE:"shuffle-item--visible",HIDDEN:"shuffle-item--hidden"};let l=0;class a{constructor(t,e){l+=1,this.id=l,this.element=t,this.isRTL=e,this.isVisible=!0,this.isHidden=!1}show(){this.isVisible=!0,this.element.classList.remove(h.HIDDEN),this.element.classList.add(h.VISIBLE),this.element.removeAttribute("aria-hidden")}hide(){this.isVisible=!1,this.element.classList.remove(h.VISIBLE),this.element.classList.add(h.HIDDEN),this.element.setAttribute("aria-hidden",!0)}init(){this.addClasses([h.SHUFFLE_ITEM,h.VISIBLE]),this.applyCss(a.Css.INITIAL),this.applyCss(this.isRTL?a.Css.DIRECTION.rtl:a.Css.DIRECTION.ltr),this.scale=a.Scale.VISIBLE,this.point=new o}addClasses(t){t.forEach((t=>{this.element.classList.add(t)}))}removeClasses(t){t.forEach((t=>{this.element.classList.remove(t)}))}applyCss(t){Object.keys(t).forEach((e=>{this.element.style[e]=t[e]}))}dispose(){this.removeClasses([h.HIDDEN,h.VISIBLE,h.SHUFFLE_ITEM]),this.element.removeAttribute("style"),this.element=null}}a.Css={INITIAL:{position:"absolute",top:0,visibility:"visible",willChange:"transform"},DIRECTION:{ltr:{left:0},rtl:{right:0}},VISIBLE:{before:{opacity:1,visibility:"visible"},after:{transitionDelay:""}},HIDDEN:{before:{opacity:0},after:{visibility:"hidden",transitionDelay:""}}},a.Scale={VISIBLE:1,HIDDEN:.001};var d=a;let u=null;var m=()=>{if(null!==u)return u;const t=document.body||document.documentElement,e=document.createElement("div");e.style.cssText="width:10px;padding:2px;box-sizing:border-box;",t.appendChild(e);const{width:i}=window.getComputedStyle(e,null);return u=10===Math.round(n(i)),t.removeChild(e),u};function c(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:window.getComputedStyle(t,null),s=n(i[e]);return m()||"width"!==e?m()||"height"!==e||(s+=n(i.paddingTop)+n(i.paddingBottom)+n(i.borderTopWidth)+n(i.borderBottomWidth)):s+=n(i.paddingLeft)+n(i.paddingRight)+n(i.borderLeftWidth)+n(i.borderRightWidth),s}const p={reverse:!1,by:null,compare:null,randomize:!1,key:"element"};function f(t,e){const i={...p,...e},s=Array.from(t);let n=!1;return t.length?i.randomize?function(t){let e=t.length;for(;e;){e-=1;const i=Math.floor(Math.random()*(e+1)),s=t[i];t[i]=t[e],t[e]=s}return t}(t):("function"==typeof i.by?t.sort(((t,e)=>{if(n)return 0;const s=i.by(t[i.key]),o=i.by(e[i.key]);return void 0===s&&void 0===o?(n=!0,0):s<o||"sortFirst"===s||"sortLast"===o?-1:s>o||"sortLast"===s||"sortFirst"===o?1:0})):"function"==typeof i.compare&&t.sort(i.compare),n?s:(i.reverse&&t.reverse(),t)):[]}const g={},_="transitionend";let y=0;function I(t){return!!g[t]&&(g[t].element.removeEventListener(_,g[t].listener),g[t]=null,!0)}function E(t,e){const i=(y+=1,_+y),s=t=>{t.currentTarget===t.target&&(I(i),e(t))};return t.addEventListener(_,s),g[i]={element:t,listener:s},i}function v(t){return Math.max(...t)}function b(t,e,i,s){let n=t/e;return Math.abs(Math.round(n)-n)<s&&(n=Math.round(n)),Math.min(Math.ceil(n),i)}function T(t,e,i){if(1===e)return t;const s=[];for(let n=0;n<=i-e;n++)s.push(v(t.slice(n,n+e)));return s}function S(t,e){const i=(s=t,Math.min(...s));var s;for(let s=0,n=t.length;s<n;s++)if(t[s]>=i-e&&t[s]<=i+e)return s;return 0}function C(t,e){const i={};t.forEach((t=>{i[t.top]?i[t.top].push(t):i[t.top]=[t]}));let s=[];const n=[],h=[];
322return Object.keys(i).forEach((t=>{const o=i[t];n.push(o);const l=o[o.length-1],a=l.left+l.width,d=Math.round((e-a)/2);let u=o,m=!1;if(d>0){const t=[];m=o.every((e=>{const i=new r(e.left+d,e.top,e.width,e.height,e.id),n=!s.some((t=>r.intersects(i,t)));return t.push(i),n})),m&&(u=t)}if(!m){let t;if(o.some((e=>s.some((i=>{const s=r.intersects(e,i);return s&&(t=i),s}))))){const e=h.findIndex((e=>e.includes(t)));h.splice(e,1,n[e])}}s=s.concat(u),h.push(u)})),h.flat().sort(((t,e)=>t.id-e.id)).map((t=>new o(t.left,t.top)))}function L(t){return Array.from(new Set(t))}let w=0;class D extends t{constructor(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};super(),this.options={...D.options,...e},this.lastSort={},this.group=D.ALL_ITEMS,this.lastFilter=D.ALL_ITEMS,this.isEnabled=!0,this.isDestroyed=!1,this.isInitialized=!1,this._transitions=[],this.isTransitioning=!1,this._queue=[];const i=this._getElementOption(t);if(!i)throw new TypeError("Shuffle needs to be initialized with an element.");this.element=i,this.id=`shuffle_${w}`,w+=1,this._init(),this.isInitialized=!0}_init(){if(this.items=this._getItems(),this.sortedItems=this.items,this.options.sizer=this._getElementOption(this.options.sizer),this.element.classList.add(D.Classes.BASE),this._initItems(this.items),"complete"!==document.readyState){const t=this.layout.bind(this);window.addEventListener("load",(function e(){window.removeEventListener("load",e),t()}))}const t=window.getComputedStyle(this.element,null),e=D.getSize(this.element).width;this._validateStyles(t),this._setColumns(e),this.filter(this.options.group,this.options.initialSort),this._rafId=null,"ResizeObserver"in window&&(this._resizeObserver=new ResizeObserver(this._handleResizeCallback.bind(this)),this._resizeObserver.observe(this.element)),this.element.offsetWidth,this.setItemTransitions(this.items),this.element.style.transition=`height ${this.options.speed}ms ${this.options.easing}`}_getElementOption(t){return"string"==typeof t?this.element.querySelector(t):t&&t.nodeType&&1===t.nodeType?t:t&&t.jquery?t[0]:null}_validateStyles(t){"static"===t.position&&(this.element.style.position="relative"),"hidden"!==t.overflow&&(this.element.style.overflow="hidden")}_filter(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.lastFilter,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.items;const i=this._getFilteredSets(t,e);return this._toggleFilterClasses(i),this.lastFilter=t,"string"==typeof t&&(this.group=t),i}_getFilteredSets(t,e){let i=[];const s=[];return t===D.ALL_ITEMS?i=e:e.forEach((e=>{this._doesPassFilter(t,e.element)?i.push(e):s.push(e)})),{visible:i,hidden:s}}_doesPassFilter(t,e){if("function"==typeof t)return t.call(e,e,this);const i=e.dataset[D.FILTER_ATTRIBUTE_KEY],s=this.options.delimiter?i.split(this.options.delimiter):JSON.parse(i);function n(t){return s.includes(t)}return Array.isArray(t)?this.options.filterMode===D.FilterMode.ANY?t.some(n):t.every(n):s.includes(t)}_toggleFilterClasses(t){let{visible:e,hidden:i}=t;e.forEach((t=>{t.show()})),i.forEach((t=>{t.hide()}))}_initItems(t){t.forEach((t=>{t.init()}))}_disposeItems(t){t.forEach((t=>{t.dispose()}))}_updateItemCount(){this.visibleItems=this._getFilteredItems().length}setItemTransitions(t){const{speed:e,easing:i}=this.options,s=this.options.useTransforms?["transform"]:["top","left"],n=Object.keys(d.Css.HIDDEN.before).map((t=>t.replace(/([A-Z])/g,((t,e)=>`-${e.toLowerCase()}`)))),o=s.concat(n).join();t.forEach((t=>{t.element.style.transitionDuration=`${e}ms`,t.element.style.transitionTimingFunction=i,t.element.style.transitionProperty=o}))}_getItems(){return Array.from(this.element.children).filter((t=>t.matches(this.options.itemSelector))).map((t=>new d(t,this.options.isRTL)))}_mergeNewItems(t){const e=Array.from(this.element.children);return f(this.items.concat(t),{by:t=>e.indexOf(t)})}_getFilteredItems(){return this.items.filter((t=>t.isVisible))}_getConcealedItems(){return this.items.filter((t=>!t.isVisible))}_getColumnSize(t,e){let i;return i="function"==typeof this.options.columnWidth?this.options.columnWidth(t):this.options.sizer?D.getSize(this.options.sizer).width:this.options.columnWidth?this.options.columnWidth:this.items.length>0?D.getSize(this.items[0].element,!0).width:t,0===i&&(i=t),i+e}_getGutterSize(t){let e;return e="function"==typeof this.options.gutterWidth?this.options.gutterWidth(t):this.options.sizer?c(this.options.sizer,"marginLeft"):this.options.gutterWidth,e}_setColumns(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:D.getSize(this.element).width;const e=this._getGutterSize(t),i=this._getColumnSize(t,e);let s=(t+e)/i;Math.abs(Math.round(s)-s)<this.options.columnThreshold&&(s=Math.round(s)),this.cols=Math.max(Math.floor(s||0),1),this.containerWidth=t,this.colWidth=i}_setContainerSize(){this.element.style.height=`${this._getContainerSize()}px`}_getContainerSize(){return v(this.positions)}_getStaggerAmount(t){return Math.min(t*this.options.staggerAmount,this.options.staggerAmountMax)}_dispatch(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};
322this.isDestroyed||(e.shuffle=this,this.emit(t,e))}_resetCols(){let t=this.cols;for(this.positions=[];t;)t-=1,this.positions.push(0)}_layout(t){const e=this._getNextPositions(t);let i=0;t.forEach(((t,s)=>{function n(){t.applyCss(d.Css.VISIBLE.after)}if(o.equals(t.point,e[s])&&!t.isHidden)return t.applyCss(d.Css.VISIBLE.before),void n();t.point=e[s],t.scale=d.Scale.VISIBLE,t.isHidden=!1;const r=this.getStylesForTransition(t,d.Css.VISIBLE.before);r.transitionDelay=`${this._getStaggerAmount(i)}ms`,this._queue.push({item:t,styles:r,callback:n}),i+=1}))}_getNextPositions(t){if(this.options.isCentered){const e=t.map(((t,e)=>{const i=D.getSize(t.element,!0),s=this._getItemPosition(i);return new r(s.x,s.y,i.width,i.height,e)}));return this.getTransformedPositions(e,this.containerWidth)}return t.map((t=>this._getItemPosition(D.getSize(t.element,!0))))}_getItemPosition(t){return function(t){let{itemSize:e,positions:i,gridSize:s,total:n,threshold:r,buffer:h}=t;const l=b(e.width,s,n,r),a=T(i,l,n),d=S(a,h),u=new o(s*d,a[d]),m=a[d]+e.height;for(let t=0;t<l;t++)i[d+t]=m;return u}({itemSize:t,positions:this.positions,gridSize:this.colWidth,total:this.cols,threshold:this.options.columnThreshold,buffer:this.options.buffer})}getTransformedPositions(t,e){return C(t,e)}_shrink(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._getConcealedItems(),e=0;t.forEach((t=>{function i(){t.applyCss(d.Css.HIDDEN.after)}if(t.isHidden)return t.applyCss(d.Css.HIDDEN.before),void i();t.scale=d.Scale.HIDDEN,t.isHidden=!0;const s=this.getStylesForTransition(t,d.Css.HIDDEN.before);s.transitionDelay=`${this._getStaggerAmount(e)}ms`,this._queue.push({item:t,styles:s,callback:i}),e+=1}))}_handleResizeCallback(t){if(this.isEnabled&&!this.isDestroyed)for(const e of t)Math.round(e.contentRect.width)!==Math.round(this.containerWidth)&&(cancelAnimationFrame(this._rafId),this._rafId=requestAnimationFrame(this.update.bind(this)))}getStylesForTransition(t,e){const i={...e};if(this.options.useTransforms){const e=this.options.isRTL?"-":"",s=this.options.roundTransforms?Math.round(t.point.x):t.point.x,n=this.options.roundTransforms?Math.round(t.point.y):t.point.y;i.transform=`translate(${e}${s}px, ${n}px) scale(${t.scale})`}else this.options.isRTL?i.right=`${t.point.x}px`:i.left=`${t.point.x}px`,i.top=`${t.point.y}px`;return i}_whenTransitionDone(t,e,i){const s=E(t,(t=>{e(),i(null,t)}));this._transitions.push(s)}_getTransitionFunction(t){return e=>{t.item.applyCss(t.styles),this._whenTransitionDone(t.item.element,t.callback,e)}}_processQueue(){this.isTransitioning&&this._cancelMovement();const t=this.options.speed>0,e=this._queue.length>0;e&&t&&this.isInitialized?this._startTransitions(this._queue):e?(this._styleImmediately(this._queue),this._dispatch(D.EventType.LAYOUT)):this._dispatch(D.EventType.LAYOUT),this._queue.length=0}_startTransitions(t){this.isTransitioning=!0;!function(t,e,i){i||("function"==typeof e?(i=e,e=null):i=s);var n=t&&t.length;if(!n)return i(null,[]);var o=!1,r=new Array(n);function h(t){return function(e,s){if(!o){if(e)return i(e,r),void(o=!0);r[t]=s,--n||i(null,r)}}}t.forEach(e?function(t,i){t.call(e,h(i))}:function(t,e){t(h(e))})}(t.map((t=>this._getTransitionFunction(t))),this._movementFinished.bind(this))}_cancelMovement(){this._transitions.forEach(I),this._transitions.length=0,this.isTransitioning=!1}_styleImmediately(t){if(t.length){const e=t.map((t=>t.item.element));D._skipTransitions(e,(()=>{t.forEach((t=>{t.item.applyCss(t.styles),t.callback()}))}))}}_movementFinished(){this._transitions.length=0,this.isTransitioning=!1,this._dispatch(D.EventType.LAYOUT)}filter(t,e){this.isEnabled&&((!t||t&&0===t.length)&&(t=D.ALL_ITEMS),this._filter(t),this._shrink(),this._updateItemCount(),this.sort(e))}sort(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.lastSort;if(!this.isEnabled)return;this._resetCols();const e=f(this._getFilteredItems(),t);this.sortedItems=e,this._layout(e),this._processQueue(),this._setContainerSize(),this.lastSort=t}update(){let{recalculateSizes:t=!0,force:e=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(this.isEnabled||e)&&(t&&this._setColumns(),this.sort())}layout(){this.update({recalculateSizes:!0})}add(t){const e=L(t).map((t=>new d(t,this.options.isRTL)));this._initItems(e),this._resetCols();const i=f(this._mergeNewItems(e),this.lastSort),s=this._filter(this.lastFilter,i),n=t=>e.includes(t),o=t=>{t.scale=d.Scale.HIDDEN,t.isHidden=!0,t.applyCss(d.Css.HIDDEN.before),t.applyCss(d.Css.HIDDEN.after)},r=this._getNextPositions(s.visible);s.visible.forEach(((t,e)=>{n(t)&&(t.point=r[e],o(t),t.applyCss(this.getStylesForTransition(t,{})))}
322)),s.hidden.forEach((t=>{n(t)&&o(t)})),this.element.offsetWidth,this.setItemTransitions(e),this.items=this._mergeNewItems(e),this.filter(this.lastFilter)}disable(){this.isEnabled=!1}enable(){let t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.isEnabled=!0,t&&this.update()}remove(t){if(!t.length)return;const e=L(t),i=e.map((t=>this.getItemByElement(t))).filter((t=>!!t));this._toggleFilterClasses({visible:[],hidden:i}),this._shrink(i),this.sort(),this.items=this.items.filter((t=>!i.includes(t))),this._updateItemCount(),this.once(D.EventType.LAYOUT,(()=>{this._disposeItems(i),e.forEach((t=>{t.parentNode.removeChild(t)})),this._dispatch(D.EventType.REMOVED,{collection:e})}))}getItemByElement(t){return this.items.find((e=>e.element===t))}resetItems(){this._disposeItems(this.items),this.isInitialized=!1,this.items=this._getItems(),this._initItems(this.items),this.once(D.EventType.LAYOUT,(()=>{this.setItemTransitions(this.items),this.isInitialized=!0})),this.filter(this.lastFilter)}destroy(){this._cancelMovement(),this._resizeObserver&&(this._resizeObserver.unobserve(this.element),this._resizeObserver=null),this.element.classList.remove("shuffle"),this.element.removeAttribute("style"),this._disposeItems(this.items),this.items.length=0,this.sortedItems.length=0,this._transitions.length=0,this.options.sizer=null,this.element=null,this.isDestroyed=!0,this.isEnabled=!1}static getSize(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=window.getComputedStyle(t,null);let s=c(t,"width",i),n=c(t,"height",i);if(e){s+=c(t,"marginLeft",i)+c(t,"marginRight",i),n+=c(t,"marginTop",i)+c(t,"marginBottom",i)}return{width:s,height:n}}static _skipTransitions(t,e){const i=t.map((t=>{const{style:e}=t,i=e.transitionDuration,s=e.transitionDelay;return e.transitionDuration="0ms",e.transitionDelay="0ms",{duration:i,delay:s}}));e(),t[0].offsetWidth,t.forEach(((t,e)=>{t.style.transitionDuration=i[e].duration,t.style.transitionDelay=i[e].delay}))}}return D.ShuffleItem=d,D.ALL_ITEMS="all",D.FILTER_ATTRIBUTE_KEY="groups",D.EventType={LAYOUT:"shuffle:layout",REMOVED:"shuffle:removed"},D.Classes=h,D.FilterMode={ANY:"any",ALL:"all"},D.options={group:D.ALL_ITEMS,speed:250,easing:"cubic-bezier(0.4, 0.0, 0.2, 1)",itemSelector:"*",sizer:null,gutterWidth:0,columnWidth:0,delimiter:null,buffer:0,columnThreshold:.01,initialSort:null,staggerAmount:15,staggerAmountMax:150,useTransforms:!0,filterMode:D.FilterMode.ANY,isCentered:!1,isRTL:!1,roundTransforms:!0},D.Point=o,D.Rect=r,D.__sorter=f,D.__getColumnSpan=b,D.__getAvailablePositions=T,D.__getShortColumn=S,D.__getCenteredPositions=C,D}));
323/* End */
324;
325; /* Start:"a:4:{s:4:"full";s:101:"/local/templates/CAIMAN_2025/assets/vendor/comparison_slider/img-comparison-slider.js?178584953911452";s:6:"source";s:85:"/local/templates/CAIMAN_2025/assets/vendor/comparison_slider/img-comparison-slider.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
326(()=>{"use strict";var t={792:(t,e,i)=>{i.d(e,{Z:()=>n});var s=i(609),o=i.n(s)()((function(t){return t[1]}));o.push([t.id,':host{--divider-width: 1px;--divider-color: #fff;--divider-shadow: none;--default-handle-width: 50px;--default-handle-color: #fff;--default-handle-opacity: 1;--default-handle-shadow: none;--handle-position-start: 50%;position:relative;display:inline-block;overflow:hidden;line-height:0;direction:ltr}@media screen and (-webkit-min-device-pixel-ratio: 0)and (min-resolution: 0.001dpcm){:host{outline-offset:1px}}:host(:focus){outline:2px solid -webkit-focus-ring-color}::slotted(*){-webkit-user-drag:none;-khtml-user-drag:none;-moz-user-drag:none;-o-user-drag:none;user-drag:none;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.first{position:absolute;left:0;top:0;right:0;line-height:normal;font-size:100%;max-height:100%;height:100%;width:100%;--exposure: 50%;--keyboard-transition-time: 0ms;--default-transition-time: 0ms;--transition-time: var(--default-transition-time)}.first .first-overlay-container{position:relative;clip-path:inset(0 var(--exposure) 0 0);transition:clip-path var(--transition-time);height:100%}.first .first-overlay{overflow:hidden;height:100%}.first.focused{will-change:clip-path}.first.focused .first-overlay-container{will-change:clip-path}.second{position:relative}.handle-container{transform:translateX(50%);position:absolute;top:0;right:var(--exposure);height:100%;transition:right var(--transition-time),bottom var(--transition-time)}.focused .handle-container{will-change:right}.divider{position:absolute;height:100%;width:100%;left:0;top:0;display:flex;align-items:center;justify-content:center;flex-direction:column}.divider:after{content:" ";display:block;height:100%;
326border-left-width:var(--divider-width);border-left-style:solid;border-left-color:#000000;box-shadow:var(--divider-shadow)}.handle{position:absolute;top:var(--handle-position-start);pointer-events:none;box-sizing:border-box;margin-left:1px;transform:translate(calc(-50% - 0.5px), -50%);line-height:0}.default-handle{width:var(--default-handle-width);opacity:var(--default-handle-opacity);transition:all 1s;filter:drop-shadow(var(--default-handle-shadow))}.default-handle path{stroke:var(--default-handle-color)}.vertical .first-overlay-container{clip-path:inset(0 0 var(--exposure) 0)}.vertical .handle-container{transform:translateY(50%);height:auto;top:unset;bottom:var(--exposure);width:100%;left:0;flex-direction:row}.vertical .divider:after{height:1px;width:100%;border-top-width:var(--divider-width);border-top-style:solid;border-top-color:var(--divider-color);border-left:0}.vertical .handle{top:auto;left:var(--handle-position-start);transform:translate(calc(-50% - 0.5px), -50%) rotate(90deg)}',""]);const n=o},609:t=>{t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var i=t(e);return e[2]?"@media ".concat(e[2]," {").concat(i,"}"):i})).join("")},e.i=function(t,i,s){"string"==typeof t&&(t=[[null,t,""]]);var o={};if(s)for(var n=0;n<this.length;n++){var r=this[n][0];null!=r&&(o[r]=!0)}for(var a=0;a<t.length;a++){var d=[].concat(t[a]);s&&o[d[0]]||(i&&(d[2]?d[2]="".concat(i," and ").concat(d[2]):d[2]=i),e.push(d))}},e}}},e={};function i(s){var o=e[s];if(void 0!==o)return o.exports;var n=e[s]={id:s,exports:{}};return t[s](n,n.exports,i),n.exports}i.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return i.d(e,{a:e}),e},i.d=(t,e)=>{for(var s in e)i.o(e,s)&&!i.o(t,s)&&Object.defineProperty(t,s,{enumerable:!0,get:e[s]})},i.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),(()=>{var t=i(792);const e="rendered",s=(t,e)=>{const i=t.getBoundingClientRect();let s,o;return"mousedown"===e.type?(s=e.clientX,o=e.clientY):(s=e.touches[0].clientX,o=e.touches[0].clientY),s>=i.x&&s<=i.x+i.width&&o>=i.y&&o<=i.y+i.height};let o;const n={ArrowLeft:-1,ArrowRight:1},r=["horizontal","vertical"],a=t=>({x:t.touches[0].pageX,y:t.touches[0].pageY}),d=t=>({x:t.pageX,y:t.pageY}),h="undefined"!=typeof window&&(null===window||void 0===window?void 0:window.HTMLElement);"undefined"!=typeof window&&(window.document&&(o=document.createElement("template"),o.innerHTML='<div class="second" id="second"> <slot name="second"><slot name="before"></slot></slot> </div> <div class="first" id="first"> <div class="first-overlay"> <div class="first-overlay-container" id="firstImageContainer"> <slot name="first"><slot name="after"></slot></slot> </div> </div> <div class="handle-container"> <div class="divider"></div> <div class="handle" id="handle"> <slot name="handle"> <svg xmlns="http://www.w3.org/2000/svg" class="default-handle" viewBox="-8 -3 16 6"> <path d="M -5 -2 L -7 0 L -5 2 M 5 -2 L 7 0 L 5 2" fill="none" vector-effect="non-scaling-stroke"/> </svg> </slot> </div> </div> </div> '),window.customElements.define("img-comparison-slider",class extends h{constructor(){super(),this.exposure=this.hasAttribute("value")?parseFloat(this.getAttribute("value")):50,this.slideOnHover=!1,this.slideDirection="horizontal",this.keyboard="enabled",this.isMouseDown=!1,this.animationDirection=0,this.isFocused=!1,this.dragByHandle=!1,this.onMouseMove=t=>{if(this.isMouseDown||this.slideOnHover){const e=d(t);this.slideToPage(e)}},this.bodyUserSelectStyle="",this.bodyWebkitUserSelectStyle="",this.onMouseDown=t=>{if(this.slideOnHover)return;if(this.handle&&!s(this.handleElement,t))return;t.preventDefault(),window.addEventListener("mousemove",this.onMouseMove),window.addEventListener("mouseup",this.onWindowMouseUp),this.isMouseDown=!0,this.enableTransition();const e=d(t);this.slideToPage(e),this.focus(),this.bodyUserSelectStyle=window.document.body.style.userSelect,this.bodyWebkitUserSelectStyle=window.document.body.style.webkitUserSelect,window.document.body.style.userSelect="none",window.document.body.style.webkitUserSelect="none"},this.onWindowMouseUp=()=>{this.isMouseDown=!1,window.document.body.style.userSelect=this.bodyUserSelectStyle,window.document.body.style.webkitUserSelect=this.bodyWebkitUserSelectStyle,window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("mouseup",this.onWindowMouseUp)},this.touchStartPoint=null,this.isTouchComparing=!1,this.hasTouchMoved=!1,this.onTouchStart=t=>{this.dragByHandle&&!s(this.handleElement,t)||(this.touchStartPoint=a(t),this.isFocused&&(this.enableTransition(),this.slideToPage(this.touchStartPoint)))},this.onTouchMove=t=>{if(null===this.touchStartPoint)return;const e=a(t);if(this.isTouchComparing)return this.slideToPage(e),t.preventDefault(),!1;if(!this.hasTouchMoved){const i=Math.abs(e.y-this.touchStartPoint.y),s=Math.abs(e.x-this.touchStartPoint.x);if("horizontal"===this.slideDirection&&i<s||"vertical"===this.slideDirection&&i>s)return this.isTouchComparing=!0,this.focus(),this.slideToPage(e),t.preventDefault(),!1;this.hasTouchMoved=!0}
vendor: 4,844 bytes, lines 326-332
326},this.onTouchEnd=()=>{this.isTouchComparing=!1,this.hasTouchMoved=!1,this.touchStartPoint=null},this.onBlur=()=>{this.stopSlideAnimation(),this.isFocused=!1,this.firstElement.classList.remove("focused")},this.onFocus=()=>{this.isFocused=!0,this.firstElement.classList.add("focused")},this.onKeyDown=t=>{if("disabled"===this.keyboard)return;const e=n[t.key];this.animationDirection!==e&&void 0!==e&&(this.animationDirection=e,this.startSlideAnimation())},this.onKeyUp=t=>{if("disabled"===this.keyboard)return;const e=n[t.key];void 0!==e&&this.animationDirection===e&&this.stopSlideAnimation()},this.resetDimensions=()=>{this.imageWidth=this.offsetWidth,this.imageHeight=this.offsetHeight};const e=this.attachShadow({mode:"open"}),i=document.createElement("style");i.innerHTML=t.Z,this.getAttribute("nonce")&&i.setAttribute("nonce",this.getAttribute("nonce")),e.appendChild(i),e.appendChild(o.content.cloneNode(!0)),this.firstElement=e.getElementById("first"),this.handleElement=e.getElementById("handle")}set handle(t){this.dragByHandle="false"!==t.toString().toLowerCase()}get handle(){return this.dragByHandle}get value(){return this.exposure}set value(t){const e=parseFloat(t);e!==this.exposure&&(this.exposure=e,this.enableTransition(),this.setExposure())}get hover(){return this.slideOnHover}set hover(t){this.slideOnHover="false"!==t.toString().toLowerCase(),this.removeEventListener("mousemove",this.onMouseMove),this.slideOnHover&&this.addEventListener("mousemove",this.onMouseMove)}get direction(){return this.slideDirection}set direction(t){this.slideDirection=t.toString().toLowerCase(),this.slide(0),this.firstElement.classList.remove(...r),r.includes(this.slideDirection)&&this.firstElement.classList.add(this.slideDirection)}static get observedAttributes(){return["hover","direction"]}connectedCallback(){this.hasAttribute("tabindex")||(this.tabIndex=0),this.addEventListener("dragstart",(t=>(t.preventDefault(),!1))),new ResizeObserver(this.resetDimensions).observe(this),this.setExposure(0),this.keyboard=this.hasAttribute("keyboard")&&"disabled"===this.getAttribute("keyboard")?"disabled":"enabled",this.addEventListener("keydown",this.onKeyDown),this.addEventListener("keyup",this.onKeyUp),this.addEventListener("focus",this.onFocus),this.addEventListener("blur",this.onBlur),this.addEventListener("touchstart",this.onTouchStart,{passive:!0}),this.addEventListener("touchmove",this.onTouchMove,{passive:!1}),this.addEventListener("touchend",this.onTouchEnd),this.addEventListener("mousedown",this.onMouseDown),this.handle=this.hasAttribute("handle")?this.getAttribute("handle"):this.dragByHandle,this.hover=this.hasAttribute("hover")?this.getAttribute("hover"):this.slideOnHover,this.direction=this.hasAttribute("direction")?this.getAttribute("direction"):this.slideDirection,this.resetDimensions(),this.classList.contains(e)||this.classList.add(e)}disconnectedCallback(){this.transitionTimer&&window.clearTimeout(this.transitionTimer)}attributeChangedCallback(t,e,i){"hover"===t&&(this.hover=i),"direction"===t&&(this.direction=i),"keyboard"===t&&(this.keyboard="disabled"===i?"disabled":"enabled")}setExposure(t=0){var e;this.exposure=(100,(e=this.exposure+t)<0?0:e>100?100:e),this.firstElement.style.setProperty("--exposure",100-this.exposure+"%")}slide(t=0){this.setExposure(t);const e=new Event("slide");this.dispatchEvent(e)}slideToPage(t){"horizontal"===this.slideDirection&&this.slideToPageX(t.x),"vertical"===this.slideDirection&&this.slideToPageY(t.y)}slideToPageX(t){const e=t-this.getBoundingClientRect().left-window.scrollX;this.exposure=e/this.imageWidth*100,this.slide(0)}slideToPageY(t){const e=t-this.getBoundingClientRect().top-window.scrollY;this.exposure=e/this.imageHeight*100,this.slide(0)}enableTransition(){this.firstElement.style.setProperty("--transition-time","100ms"),this.transitionTimer=window.setTimeout((()=>{this.firstElement.style.setProperty("--transition-time","var(--default-transition-time)"),this.transitionTimer=null}),100)}startSlideAnimation(){let t=null,e=this.animationDirection;this.firstElement.style.setProperty("--transition-time","var(--keyboard-transition-time)");const i=s=>{if(0===this.animationDirection||e!==this.animationDirection)return;null===t&&(t=s);const o=(s-t)/16.666666666666668*this.animationDirection;this.slide(o),setTimeout((()=>window.requestAnimationFrame(i)),0),t=s};window.requestAnimationFrame(i)}stopSlideAnimation(){this.animationDirection=0,this.firstElement.style.setProperty("--transition-time","var(--default-transition-time)")}}))})()})();
327//# sourceMappingURL=index.js.map
328/* End */
329;
330; /* Start:"a:4:{s:4:"full";s:74:"/local/templates/CAIMAN_2025/assets/custom/js/videoreview.js?1761730821183";s:6:"source";s:60:"/local/templates/CAIMAN_2025/assets/custom/js/videoreview.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
331function getVidFrame(vid)
332{
vendor: 3,331 bytes, lines 333-415
333	$.post("/ajax/ajaxVideoreview.php", { vid_id: vid.dataset.vidid }, function(r){
334		$('#bodyvideos_'+vid.dataset.vidid).html(r.frame);
335	},
336	'json');
337}
338/* End */
339;
340; /* Start:"a:4:{s:4:"full";s:75:"/local/templates/CAIMAN_2025/assets/custom/js/theme.min.js?1743777573127571";s:6:"source";s:58:"/local/templates/CAIMAN_2025/assets/custom/js/theme.min.js";s:3:"min";s:58:"/local/templates/CAIMAN_2025/assets/custom/js/theme.min.js";s:3:"map";s:62:"/local/templates/CAIMAN_2025/assets/custom/js/theme.min.js.map";}"*/
341/**
342 * Silicon | Multipurpose Bootstrap 5 Template & UI Kit
343 * Copyright 2023 Createx Studio
344 * Theme scripts
345 *
346 * @author Createx Studio
347 * @version 1.6.0
348 */
349! function() {
350	"use strict";
351	/*!
352	 * Bootstrap v5.3.2 (https://getbootstrap.com/)
353	 * Copyright 2011-2023 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
354	 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
355	 */
356	var e, t;
357	! function(e, t) {
358		"object" == typeof exports && "undefined" != typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : (e = "undefined" != typeof globalThis ? globalThis : e || self).bootstrap = t()
359	}(void 0, (function() {
360		const e = new Map,
361			t = {
362				set(t, n, i) {
363					e.has(t) || e.set(t, new Map);
364					const s = e.get(t);
365					s.has(n) || 0 === s.size ? s.set(n, i) : console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)
366				},
367				get: (t, n) => e.has(t) && e.get(t).get(n) || null,
368				remove(t, n) {
369					if (!e.has(t)) return;
370					const i = e.get(t);
371					i.delete(n), 0 === i.size && e.delete(t)
372				}
373			},
374			n = "transitionend",
375			i = e => (e && window.CSS && window.CSS.escape && (e = e.replace(/#([^\s"#']+)/g, ((e, t) => `#${CSS.escape(t)}`))), e),
376			s = e => {
377				e.dispatchEvent(new Event(n))
378			},
379			o = e => !(!e || "object" != typeof e) && (void 0 !== e.jquery && (e = e[0]), void 0 !== e.nodeType),
380			r = e => o(e) ? e.jquery ? e[0] : e : "string" == typeof e && e.length > 0 ? document.querySelector(i(e)) : null,
381			a = e => {
382				if (!o(e) || 0 === e.getClientRects().length) return !1;
383				const t = "visible" === getComputedStyle(e).getPropertyValue("visibility"),
384					n = e.closest("details:not([open])");
385				if (!n) return t;
386				if (n !== e) {
387					const t = e.closest("summary");
388					if (t && t.parentNode !== n) return !1;
389					if (null === t) return !1
390				}
391				return t
392			},
393			l = e => !e || e.nodeType !== Node.ELEMENT_NODE || (!!e.classList.contains("disabled") || (void 0 !== e.disabled ? e.disabled : e.hasAttribute("disabled") && "false" !== e.getAttribute("disabled"))),
394			c = e => {
395				if (!document.documentElement.attachShadow) return null;
396				if ("function" == typeof e.getRootNode) {
397					const t = e.getRootNode();
398					return t instanceof ShadowRoot ? t : null
399				}
400				return e instanceof ShadowRoot ? e : e.parentNode ? c(e.parentNode) : null
401			},
402			u = () => {},
403			d = e => {
404				e.offsetHeight
405			},
406			h = () => window.jQuery && !document.body.hasAttribute("data-bs-no-jquery") ? window.jQuery : null,
407			f = [],
408			p = () => "rtl" === document.documentElement.dir,
409			m = e => {
410				var t;
411				t = () => {
412					const t = h();
413					if (t) {
414						const n = e.NAME,
415							i = t.fn[n];
vendor: 11,097 bytes, lines 416-762
416						t.fn[n] = e.jQueryInterface, t.fn[n].Constructor = e, t.fn[n].noConflict = () => (t.fn[n] = i, e.jQueryInterface)
417					}
418				}, "loading" === document.readyState ? (f.length || document.addEventListener("DOMContentLoaded", (() => {
419					for (const e of f) e()
420				})), f.push(t)) : t()
421			},
422			g = (e, t = [], n = e) => "function" == typeof e ? e(...t) : n,
423			_ = (e, t, i = !0) => {
424				if (!i) return void g(e);
425				const o = (e => {
426					if (!e) return 0;
427					let {
428						transitionDuration: t,
429						transitionDelay: n
430					} = window.getComputedStyle(e);
431					const i = Number.parseFloat(t),
432						s = Number.parseFloat(n);
433					return i || s ? (t = t.split(",")[0], n = n.split(",")[0], 1e3 * (Number.parseFloat(t) + Number.parseFloat(n))) : 0
434				})(t) + 5;
435				let r = !1;
436				const a = ({
437					target: i
438				}) => {
439					i === t && (r = !0, t.removeEventListener(n, a), g(e))
440				};
441				t.addEventListener(n, a), setTimeout((() => {
442					r || s(t)
443				}), o)
444			},
445			v = (e, t, n, i) => {
446				const s = e.length;
447				let o = e.indexOf(t);
448				return -1 === o ? !n && i ? e[s - 1] : e[0] : (o += n ? 1 : -1, i && (o = (o + s) % s), e[Math.max(0, Math.min(o, s - 1))])
449			},
450			b = /[^.]*(?=\..*)\.|.*/,
451			y = /\..*/,
452			w = /::\d+$/,
453			E = {};
454		let A = 1;
455		const T = {
456				mouseenter: "mouseover",
457				mouseleave: "mouseout"
458			},
459			C = new Set(["click", "dblclick", "mouseup", "mousedown", "contextmenu", "mousewheel", "DOMMouseScroll", "mouseover", "mouseout", "mousemove", "selectstart", "selectend", "keydown", "keypress", "keyup", "orientationchange", "touchstart", "touchmove", "touchend", "touchcancel", "pointerdown", "pointermove", "pointerup", "pointerleave", "pointercancel", "gesturestart", "gesturechange", "gestureend", "focus", "blur", "change", "reset", "select", "submit", "focusin", "focusout", "load", "unload", "beforeunload", "resize", "move", "DOMContentLoaded", "readystatechange", "error", "abort", "scroll"]);
460
461		function S(e, t) {
462			return t && `${t}::${A++}` || e.uidEvent || A++
463		}
464
465		function x(e) {
466			const t = S(e);
467			return e.uidEvent = t, E[t] = E[t] || {}, E[t]
468		}
469
470		function O(e, t, n = null) {
471			return Object.values(e).find((e => e.callable === t && e.delegationSelector === n))
472		}
473
474		function L(e, t, n) {
475			const i = "string" == typeof t,
476				s = i ? n : t || n;
477			let o = M(e);
478			return C.has(o) || (o = e), [i, s, o]
479		}
480
481		function k(e, t, n, i, s) {
482			if ("string" != typeof t || !e) return;
483			let [o, r, a] = L(t, n, i);
484			if (t in T) {
485				const e = e => function(t) {
486					if (!t.relatedTarget || t.relatedTarget !== t.delegateTarget && !t.delegateTarget.contains(t.relatedTarget)) return e.call(this, t)
487				};
488				r = e(r)
489			}
490			const l = x(e),
491				c = l[a] || (l[a] = {}),
492				u = O(c, r, o ? n : null);
493			if (u) return void(u.oneOff = u.oneOff && s);
494			const d = S(r, t.replace(b, "")),
495				h = o ? function(e, t, n) {
496					return function i(s) {
497						const o = e.querySelectorAll(t);
498						for (let {
499								target: r
500							} = s; r && r !== this; r = r.parentNode)
501							for (const a of o)
502								if (a === r) return P(s, {
503									delegateTarget: r
504								}), i.oneOff && $.off(e, s.type, t, n), n.apply(r, [s])
505					}
506				}(e, n, r) : function(e, t) {
507					return function n(i) {
508						return P(i, {
509							delegateTarget: e
510						}), n.oneOff && $.off(e, i.type, t), t.apply(e, [i])
511					}
512				}(e, r);
513			h.delegationSelector = o ? n : null, h.callable = r, h.oneOff = s, h.uidEvent = d, c[d] = h, e.addEventListener(a, h, o)
514		}
515
516		function D(e, t, n, i, s) {
517			const o = O(t[n], i, s);
518			o && (e.removeEventListener(n, o, Boolean(s)), delete t[n][o.uidEvent])
519		}
520
521		function I(e, t, n, i) {
522			const s = t[n] || {};
523			for (const [o, r] of Object.entries(s)) o.includes(i) && D(e, t, n, r.callable, r.delegationSelector)
524		}
525
526		function M(e) {
527			return e = e.replace(y, ""), T[e] || e
528		}
529		const $ = {
530			on(e, t, n, i) {
531				k(e, t, n, i, !1)
532			},
533			one(e, t, n, i) {
534				k(e, t, n, i, !0)
535			},
536			off(e, t, n, i) {
537				if ("string" != typeof t || !e) return;
538				const [s, o, r] = L(t, n, i), a = r !== t, l = x(e), c = l[r] || {}, u = t.startsWith(".");
539				if (void 0 === o) {
540					if (u)
541						for (const n of Object.keys(l)) I(e, l, n, t.slice(1));
542					for (const [n, i] of Object.entries(c)) {
543						const s = n.replace(w, "");
544						a && !t.includes(s) || D(e, l, r, i.callable, i.delegationSelector)
545					}
546				} else {
547					if (!Object.keys(c).length) return;
548					D(e, l, r, o, s ? n : null)
549				}
550			},
551			trigger(e, t, n) {
552				if ("string" != typeof t || !e) return null;
553				const i = h();
554				let s = null,
555					o = !0,
556					r = !0,
557					a = !1;
558				t !== M(t) && i && (s = i.Event(t, n), i(e).trigger(s), o = !s.isPropagationStopped(), r = !s.isImmediatePropagationStopped(), a = s.isDefaultPrevented());
559				const l = P(new Event(t, {
560					bubbles: o,
561					cancelable: !0
562				}), n);
563				return a && l.preventDefault(), r && e.dispatchEvent(l), l.defaultPrevented && s && s.preventDefault(), l
564			}
565		};
566
567		function P(e, t = {}) {
568			for (const [n, i] of Object.entries(t)) try {
569				e[n] = i
570			} catch (t) {
571				Object.defineProperty(e, n, {
572					configurable: !0,
573					get: () => i
574				})
575			}
576			return e
577		}
578
579		function N(e) {
580			if ("true" === e) return !0;
581			if ("false" === e) return !1;
582			if (e === Number(e).toString()) return Number(e);
583			if ("" === e || "null" === e) return null;
584			if ("string" != typeof e) return e;
585			try {
586				return JSON.parse(decodeURIComponent(e))
587			} catch (t) {
588				return e
589			}
590		}
591
592		function j(e) {
593			return e.replace(/[A-Z]/g, (e => `-${e.toLowerCase()}`))
594		}
595		const q = {
596			setDataAttribute(e, t, n) {
597				e.setAttribute(`data-bs-${j(t)}`, n)
598			},
599			removeDataAttribute(e, t) {
600				e.removeAttribute(`data-bs-${j(t)}`)
601			},
602			getDataAttributes(e) {
603				if (!e) return {};
604				const t = {},
605					n = Object.keys(e.dataset).filter((e => e.startsWith("bs") && !e.startsWith("bsConfig")));
606				for (const i of n) {
607					let n = i.replace(/^bs/, "");
608					n = n.charAt(0).toLowerCase() + n.slice(1, n.length), t[n] = N(e.dataset[i])
609				}
610				return t
611			},
612			getDataAttribute: (e, t) => N(e.getAttribute(`data-bs-${j(t)}`))
613		};
614		class F {
615			static get Default() {
616				return {}
617			}
618			static get DefaultType() {
619				return {}
620			}
621			static get NAME() {
622				throw new Error('You have to implement the static method "NAME", for each component!')
623			}
624			_getConfig(e) {
625				return e = this._mergeConfigObj(e), e = this._configAfterMerge(e), this._typeCheckConfig(e), e
626			}
627			_configAfterMerge(e) {
628				return e
629			}
630			_mergeConfigObj(e, t) {
631				const n = o(t) ? q.getDataAttribute(t, "config") : {};
632				return {
633					...this.constructor.Default,
634					..."object" == typeof n ? n : {},
635					...o(t) ? q.getDataAttributes(t) : {},
636					..."object" == typeof e ? e : {}
637				}
638			}
639			_typeCheckConfig(e, t = this.constructor.DefaultType) {
640				for (const [i, s] of Object.entries(t)) {
641					const t = e[i],
642						r = o(t) ? "element" : null == (n = t) ? `${n}` : Object.prototype.toString.call(n).match(/\s([a-z]+)/i)[1].toLowerCase();
643					if (!new RegExp(s).test(r)) throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${i}" provided type "${r}" but expected type "${s}".`)
644				}
645				var n
646			}
647		}
648		class H extends F {
649			constructor(e, n) {
650				super(), (e = r(e)) && (this._element = e, this._config = this._getConfig(n), t.set(this._element, this.constructor.DATA_KEY, this))
651			}
652			dispose() {
653				t.remove(this._element, this.constructor.DATA_KEY), $.off(this._element, this.constructor.EVENT_KEY);
654				for (const e of Object.getOwnPropertyNames(this)) this[e] = null
655			}
656			_queueCallback(e, t, n = !0) {
657				_(e, t, n)
658			}
659			_getConfig(e) {
660				return e = this._mergeConfigObj(e, this._element), e = this._configAfterMerge(e), this._typeCheckConfig(e), e
661			}
662			static getInstance(e) {
663				return t.get(r(e), this.DATA_KEY)
664			}
665			static getOrCreateInstance(e, t = {}) {
666				return this.getInstance(e) || new this(e, "object" == typeof t ? t : null)
667			}
668			static get VERSION() {
669				return "5.3.2"
670			}
671			static get DATA_KEY() {
672				return `bs.${this.NAME}`
673			}
674			static get EVENT_KEY() {
675				return `.${this.DATA_KEY}`
676			}
677			static eventName(e) {
678				return `${e}${this.EVENT_KEY}`
679			}
680		}
681		const R = e => {
682				let t = e.getAttribute("data-bs-target");
683				if (!t || "#" === t) {
684					let n = e.getAttribute("href");
685					if (!n || !n.includes("#") && !n.startsWith(".")) return null;
686					n.includes("#") && !n.startsWith("#") && (n = `#${n.split("#")[1]}`), t = n && "#" !== n ? i(n.trim()) : null
687				}
688				return t
689			},
690			B = {
691				find: (e, t = document.documentElement) => [].concat(...Element.prototype.querySelectorAll.call(t, e)),
692				findOne: (e, t = document.documentElement) => Element.prototype.querySelector.call(t, e),
693				children: (e, t) => [].concat(...e.children).filter((e => e.matches(t))),
694				parents(e, t) {
695					const n = [];
696					let i = e.parentNode.closest(t);
697					for (; i;) n.push(i), i = i.parentNode.closest(t);
698					return n
699				},
700				prev(e, t) {
701					let n = e.previousElementSibling;
702					for (; n;) {
703						if (n.matches(t)) return [n];
704						n = n.previousElementSibling
705					}
706					return []
707				},
708				next(e, t) {
709					let n = e.nextElementSibling;
710					for (; n;) {
711						if (n.matches(t)) return [n];
712						n = n.nextElementSibling
713					}
714					return []
715				},
716				focusableChildren(e) {
717					const t = ["a", "button", "input", "textarea", "select", "details", "[tabindex]", '[contenteditable="true"]'].map((e => `${e}:not([tabindex^="-"])`)).join(",");
718					return this.find(t, e).filter((e => !l(e) && a(e)))
719				},
720				getSelectorFromElement(e) {
721					const t = R(e);
722					return t && B.findOne(t) ? t : null
723				},
724				getElementFromSelector(e) {
725					const t = R(e);
726					return t ? B.findOne(t) : null
727				},
728				getMultipleElementsFromSelector(e) {
729					const t = R(e);
730					return t ? B.find(t) : []
731				}
732			},
733			W = (e, t = "hide") => {
734				const n = `click.dismiss${e.EVENT_KEY}`,
735					i = e.NAME;
736				$.on(document, n, `[data-bs-dismiss="${i}"]`, (function(n) {
737					if (["A", "AREA"].includes(this.tagName) && n.preventDefault(), l(this)) return;
738					const s = B.getElementFromSelector(this) || this.closest(`.${i}`);
739					e.getOrCreateInstance(s)[t]()
740				}))
741			},
742			z = ".bs.alert",
743			V = `close${z}`,
744			U = `closed${z}`;
745		class Q extends H {
746			static get NAME() {
747				return "alert"
748			}
749			close() {
750				if ($.trigger(this._element, V).defaultPrevented) return;
751				this._element.classList.remove("show");
752				const e = this._element.classList.contains("fade");
753				this._queueCallback((() => this._destroyElement()), this._element, e)
754			}
755			_destroyElement() {
756				this._element.remove(), $.trigger(this._element, U), this.dispose()
757			}
758			static jQueryInterface(e) {
759				return this.each((function() {
760					const t = Q.getOrCreateInstance(this);
761					if ("string" == typeof e) {
762						if (void 0 === t[e] || e.startsWith("_") || "constructor" === e) throw new TypeError(`No method n
762amed "${e}"`);
763						t[e](this)
764					}
765				}))
766			}
767		}
768		W(Q, "close"), m(Q);
769		const K = '[data-bs-toggle="button"]';
770		class Y extends H {
771			static get NAME() {
772				return "button"
773			}
774			toggle() {
775				this._element.setAttribute("aria-pressed", this._element.classList.toggle("active"))
776			}
777			static jQueryInterface(e) {
778				return this.each((function() {
779					const t = Y.getOrCreateInstance(this);
780					"toggle" === e && t[e]()
781				}))
782			}
783		}
784		$.on(document, "click.bs.button.data-api", K, (e => {
785			e.preventDefault();
786			const t = e.target.closest(K);
787			Y.getOrCreateInstance(t).toggle()
788		})), m(Y);
789		const X = ".bs.swipe",
790			J = `touchstart${X}`,
791			G = `touchmove${X}`,
792			Z = `touchend${X}`,
793			ee = `pointerdown${X}`,
794			te = `pointerup${X}`,
795			ne = {
796				endCallback: null,
797				leftCallback: null,
798				rightCallback: null
799			},
800			ie = {
801				endCallback: "(function|null)",
802				leftCallback: "(function|null)",
803				rightCallback: "(function|null)"
804			};
805		class se extends F {
806			constructor(e, t) {
807				super(), this._element = e, e && se.isSupported() && (this._config = this._getConfig(t), this._deltaX = 0, this._supportPointerEvents = Boolean(window.PointerEvent), this._initEvents())
808			}
809			static get Default() {
810				return ne
811			}
812			static get DefaultType() {
813				return ie
814			}
815			static get NAME() {
816				return "swipe"
817			}
818			dispose() {
819				$.off(this._element, X)
820			}
821			_start(e) {
822				this._supportPointerEvents ? this._eventIsPointerPenTouch(e) && (this._deltaX = e.clientX) : this._deltaX = e.touches[0].clientX
823			}
824			_end(e) {
825				this._eventIsPointerPenTouch(e) && (this._deltaX = e.clientX - this._deltaX), this._handleSwipe(), g(this._config.endCallback)
826			}
827			_move(e) {
828				this._deltaX = e.touches && e.touches.length > 1 ? 0 : e.touches[0].clientX - this._deltaX
829			}
830			_handleSwipe() {
831				const e = Math.abs(this._deltaX);
832				if (e <= 40) return;
833				const t = e / this._deltaX;
834				this._deltaX = 0, t && g(t > 0 ? this._config.rightCallback : this._config.leftCallback)
835			}
836			_initEvents() {
837				this._supportPointerEvents ? ($.on(this._element, ee, (e => this._start(e))), $.on(this._element, te, (e => this._end(e))), this._element.classList.add("pointer-event")) : ($.on(this._element, J, (e => this._start(e))), $.on(this._element, G, (e => this._move(e))), $.on(this._element, Z, (e => this._end(e))))
838			}
839			_eventIsPointerPenTouch(e) {
840				return this._supportPointerEvents && ("pen" === e.pointerType || "touch" === e.pointerType)
841			}
842			static isSupported() {
843				return "ontouchstart" in document.documentElement || navigator.maxTouchPoints > 0
844			}
845		}
846		const oe = ".bs.carousel",
847			re = ".data-api",
848			ae = "next",
849			le = "prev",
850			ce = "left",
851			ue = "right",
852			de = `slide${oe}`,
853			he = `slid${oe}`,
854			fe = `keydown${oe}`,
855			pe = `mouseenter${oe}`,
856			me = `mouseleave${oe}`,
857			ge = `dragstart${oe}`,
858			_e = `load${oe}${re}`,
859			ve = `click${oe}${re}`,
860			be = "carousel",
861			ye = "active",
862			we = ".active",
863			Ee = ".carousel-item",
864			Ae = we + Ee,
865			Te = {
866				ArrowLeft: ue,
867				ArrowRight: ce
868			},
869			Ce = {
870				interval: 5e3,
871				keyboard: !0,
872				pause: "hover",
873				ride: !1,
874				touch: !0,
875				wrap: !0
876			},
877			Se = {
878				interval: "(number|boolean)",
879				keyboard: "boolean",
880				pause: "(string|boolean)",
881				ride: "(boolean|string)",
882				touch: "boolean",
883				wrap: "boolean"
884			};
885		class xe extends H {
886			constructor(e, t) {
887				super(e, t), this._interval = null, this._activeElement = null, this._isSliding = !1, this.touchTimeout = null, this._swipeHelper = null, this._indicatorsElement = B.findOne(".carousel-indicators", this._element), this._addEventListeners(), this._config.ride === be && this.cycle()
888			}
889			static get Default() {
890				return Ce
891			}
892			static get DefaultType() {
893				return Se
894			}
895			static get NAME() {
896				return "carousel"
897			}
898			next() {
899				this._slide(ae)
900			}
901			nextWhenVisible() {
902				!document.hidden && a(this._element) && this.next()
903			}
904			prev() {
905				this._slide(le)
906			}
907			pause() {
908				this._isSliding && s(this._element), this._clearInterval()
909			}
910			cycle() {
911				this._clearInterval(), this._updateInterval(), this._interval = setInterval((() => this.nextWhenVisible()), this._config.interval)
912			}
913			_maybeEnableCycle() {
914				this._config.ride && (this._isSliding ? $.one(this._element, he, (() => this.cycle())) : this.cycle())
915			}
916			to(e) {
917				const t = this._getItems();
918				if (e > t.length - 1 || e < 0) return;
919				if (this._isSliding) return void $.one(this._element, he, (() => this.to(e)));
920				const n = this._getItemIndex(this._getActive());
921				if (n === e) return;
922				const i = e > n ? ae : le;
923				this._slide(i, t[e])
924			}
925			dispose() {
vendor: 10,004 bytes, lines 926-1202
926				this._swipeHelper && this._swipeHelper.dispose(), super.dispose()
927			}
928			_configAfterMerge(e) {
929				return e.defaultInterval = e.interval, e
930			}
931			_addEventListeners() {
932				this._config.keyboard && $.on(this._element, fe, (e => this._keydown(e))), "hover" === this._config.pause && ($.on(this._element, pe, (() => this.pause())), $.on(this._element, me, (() => this._maybeEnableCycle()))), this._config.touch && se.isSupported() && this._addTouchEventListeners()
933			}
934			_addTouchEventListeners() {
935				for (const e of B.find(".carousel-item img", this._element)) $.on(e, ge, (e => e.preventDefault()));
936				const e = {
937					leftCallback: () => this._slide(this._directionToOrder(ce)),
938					rightCallback: () => this._slide(this._directionToOrder(ue)),
939					endCallback: () => {
940						"hover" === this._config.pause && (this.pause(), this.touchTimeout && clearTimeout(this.touchTimeout), this.touchTimeout = setTimeout((() => this._maybeEnableCycle()), 500 + this._config.interval))
941					}
942				};
943				this._swipeHelper = new se(this._element, e)
944			}
945			_keydown(e) {
946				if (/input|textarea/i.test(e.target.tagName)) return;
947				const t = Te[e.key];
948				t && (e.preventDefault(), this._slide(this._directionToOrder(t)))
949			}
950			_getItemIndex(e) {
951				return this._getItems().indexOf(e)
952			}
953			_setActiveIndicatorElement(e) {
954				if (!this._indicatorsElement) return;
955				const t = B.findOne(we, this._indicatorsElement);
956				t.classList.remove(ye), t.removeAttribute("aria-current");
957				const n = B.findOne(`[data-bs-slide-to="${e}"]`, this._indicatorsElement);
958				n && (n.classList.add(ye), n.setAttribute("aria-current", "true"))
959			}
960			_updateInterval() {
961				const e = this._activeElement || this._getActive();
962				if (!e) return;
963				const t = Number.parseInt(e.getAttribute("data-bs-interval"), 10);
964				this._config.interval = t || this._config.defaultInterval
965			}
966			_slide(e, t = null) {
967				if (this._isSliding) return;
968				const n = this._getActive(),
969					i = e === ae,
970					s = t || v(this._getItems(), n, i, this._config.wrap);
971				if (s === n) return;
972				const o = this._getItemIndex(s),
973					r = t => $.trigger(this._element, t, {
974						relatedTarget: s,
975						direction: this._orderToDirection(e),
976						from: this._getItemIndex(n),
977						to: o
978					});
979				if (r(de).defaultPrevented) return;
980				if (!n || !s) return;
981				const a = Boolean(this._interval);
982				this.pause(), this._isSliding = !0, this._setActiveIndicatorElement(o), this._activeElement = s;
983				const l = i ? "carousel-item-start" : "carousel-item-end",
984					c = i ? "carousel-item-next" : "carousel-item-prev";
985				s.classList.add(c), d(s), n.classList.add(l), s.classList.add(l);
986				this._queueCallback((() => {
987					s.classList.remove(l, c), s.classList.add(ye), n.classList.remove(ye, c, l), this._isSliding = !1, r(he)
988				}), n, this._isAnimated()), a && this.cycle()
989			}
990			_isAnimated() {
991				return this._element.classList.contains("slide")
992			}
993			_getActive() {
994				return B.findOne(Ae, this._element)
995			}
996			_getItems() {
997				return B.find(Ee, this._element)
998			}
999			_clearInterval() {
1000				this._interval && (clearInterval(this._interval), this._interval = null)
1001			}
1002			_directionToOrder(e) {
1003				return p() ? e === ce ? le : ae : e === ce ? ae : le
1004			}
1005			_orderToDirection(e) {
1006				return p() ? e === le ? ce : ue : e === le ? ue : ce
1007			}
1008			static jQueryInterface(e) {
1009				return this.each((function() {
1010					const t = xe.getOrCreateInstance(this, e);
1011					if ("number" != typeof e) {
1012						if ("string" == typeof e) {
1013							if (void 0 === t[e] || e.startsWith("_") || "constructor" === e) throw new TypeError(`No method named "${e}"`);
1014							t[e]()
1015						}
1016					} else t.to(e)
1017				}))
1018			}
1019		}
1020		$.on(document, ve, "[data-bs-slide], [data-bs-slide-to]", (function(e) {
1021			const t = B.getElementFromSelector(this);
1022			if (!t || !t.classList.contains(be)) return;
1023			e.preventDefault();
1024			const n = xe.getOrCreateInstance(t),
1025				i = this.getAttribute("data-bs-slide-to");
1026			return i ? (n.to(i), void n._maybeEnableCycle()) : "next" === q.getDataAttribute(this, "slide") ? (n.next(), void n._maybeEnableCycle()) : (n.prev(), void n._maybeEnableCycle())
1027		})), $.on(window, _e, (() => {
1028			const e = B.find('[data-bs-ride="carousel"]');
1029			for (const t of e) xe.getOrCreateInstance(t)
1030		})), m(xe);
1031		const Oe = ".bs.collapse",
1032			Le = `show${Oe}`,
1033			ke = `shown${Oe}`,
1034			De = `hide${Oe}`,
1035			Ie = `hidden${Oe}`,
1036			Me = `click${Oe}.data-api`,
1037			$e = "show",
1038			Pe = "collapse",
1039			Ne = "collapsing",
1040			je = `:scope .${Pe} .${Pe}`,
1041			qe = '[data-bs-toggle="collapse"]',
1042			Fe = {
1043				parent: null,
1044				toggle: !0
1045			},
1046			He = {
1047				parent: "(null|element)",
1048				toggle: "boolean"
1049			};
1050		class Re extends H {
1051			constructor(e, t) {
1052				super(e, t), this._isTransitioning = !1, this._triggerArray = [];
1053				const n = B.find(qe);
1054				for (const e of n) {
1055					const t = B.getSelectorFromElement(e),
1056						n = B.find(t).filter((e => e === this._element));
1057					null !== t && n.length && this._triggerArray.push(e)
1058				}
1059				this._initializeChildren(), this._config.parent || this._addAriaAndCollapsedClass(this._triggerArray, this._isShown()), this._config.toggle && this.toggle()
1060			}
1061			static get Default() {
1062				return Fe
1063			}
1064			static get DefaultType() {
1065				return He
1066			}
1067			static get NAME() {
1068				return "collapse"
1069			}
1070			toggle() {
1071				this._isShown() ? this.hide() : this.show()
1072			}
1073			show() {
1074				if (this._isTransitioning || this._isShown()) return;
1075				let e = [];
1076				if (this._config.parent && (e = this._getFirstLevelChildren(".collapse.show, .collapse.collapsing").filter((e => e !== this._element)).map((e => Re.getOrCreateInstance(e, {
1077						toggle: !1
1078					})))), e.length && e[0]._isTransitioning) return;
1079				if ($.trigger(this._element, Le).defaultPrevented) return;
1080				for (const t of e) t.hide();
1081				const t = this._getDimension();
1082				this._element.classList.remove(Pe), this._element.classList.add(Ne), this._element.style[t] = 0, this._addAriaAndCollapsedClass(this._triggerArray, !0), this._isTransitioning = !0;
1083				const n = `scroll${t[0].toUpperCase()+t.slice(1)}`;
1084				this._queueCallback((() => {
1085					this._isTransitioning = !1, this._element.classList.remove(Ne), this._element.classList.add(Pe, $e), this._element.style[t] = "", $.trigger(this._element, ke)
1086				}), this._element, !0), this._element.style[t] = `${this._element[n]}px`
1087			}
1088			hide() {
1089				if (this._isTransitioning || !this._isShown()) return;
1090				if ($.trigger(this._element, De).defaultPrevented) return;
1091				const e = this._getDimension();
1092				this._element.style[e] = `${this._element.getBoundingClientRect()[e]}px`, d(this._element), this._element.classList.add(Ne), this._element.classList.remove(Pe, $e);
1093				for (const e of this._triggerArray) {
1094					const t = B.getElementFromSelector(e);
1095					t && !this._isShown(t) && this._addAriaAndCollapsedClass([e], !1)
1096				}
1097				this._isTransitioning = !0;
1098				this._element.style[e] = "", this._queueCallback((() => {
1099					this._isTransitioning = !1, this._element.classList.remove(Ne), this._element.classList.add(Pe), $.trigger(this._element, Ie)
1100				}), this._element, !0)
1101			}
1102			_isShown(e = this._element) {
1103				return e.classList.contains($e)
1104			}
1105			_configAfterMerge(e) {
1106				return e.toggle = Boolean(e.toggle), e.parent = r(e.parent), e
1107			}
1108			_getDimension() {
1109				return this._element.classList.contains("collapse-horizontal") ? "width" : "height"
1110			}
1111			_initializeChildren() {
1112				if (!this._config.parent) return;
1113				const e = this._getFirstLevelChildren(qe);
1114				for (const t of e) {
1115					const e = B.getElementFromSelector(t);
1116					e && this._addAriaAndCollapsedClass([t], this._isShown(e))
1117				}
1118			}
1119			_getFirstLevelChildren(e) {
1120				const t = B.find(je, this._config.parent);
1121				return B.find(e, this._config.parent).filter((e => !t.includes(e)))
1122			}
1123			_addAriaAndCollapsedClass(e, t) {
1124				if (e.length)
1125					for (const n of e) n.classList.toggle("collapsed", !t), n.setAttribute("aria-expanded", t)
1126			}
1127			static jQueryInterface(e) {
1128				const t = {};
1129				return "string" == typeof e && /show|hide/.test(e) && (t.toggle = !1), this.each((function() {
1130					const n = Re.getOrCreateInstance(this, t);
1131					if ("string" == typeof e) {
1132						if (void 0 === n[e]) throw new TypeError(`No method named "${e}"`);
1133						n[e]()
1134					}
1135				}))
1136			}
1137		}
1138		$.on(document, Me, qe, (function(e) {
1139			("A" === e.target.tagName || e.delegateTarget && "A" === e.delegateTarget.tagName) && e.preventDefault();
1140			for (const e of B.getMultipleElementsFromSelector(this)) Re.getOrCreateInstance(e, {
1141				toggle: !1
1142			}).toggle()
1143		})), m(Re);
1144		var Be = "top",
1145			We = "bottom",
1146			ze = "right",
1147			Ve = "left",
1148			Ue = "auto",
1149			Qe = [Be, We, ze, Ve],
1150			Ke = "start",
1151			Ye = "end",
1152			Xe = "clippingParents",
1153			Je = "viewport",
1154			Ge = "popper",
1155			Ze = "reference",
1156			et = Qe.reduce((function(e, t) {
1157				return e.concat([t + "-" + Ke, t + "-" + Ye])
1158			}), []),
1159			tt = [].concat(Qe, [Ue]).reduce((function(e, t) {
1160				return e.concat([t, t + "-" + Ke, t + "-" + Ye])
1161			}), []),
1162			nt = "beforeRead",
1163			it = "read",
1164			st = "afterRead",
1165			ot = "beforeMain",
1166			rt = "main",
1167			at = "afterMain",
1168			lt = "beforeWrite",
1169			ct = "write",
1170			ut = "afterWrite",
1171			dt = [nt, it, st, ot, rt, at, lt, ct, ut];
1172
1173		function ht(e) {
1174			return e ? (e.nodeName || "").toLowerCase() : null
1175		}
1176
1177		function ft(e) {
1178			if (null == e) return window;
1179			if ("[object Window]" !== e.toString()) {
1180				var t = e.ownerDocument;
1181				return t && t.defaultView || window
1182			}
1183			return e
1184		}
1185
1186		function pt(e) {
1187			return e instanceof ft(e).Element || e instanceof Element
1188		}
1189
1190		function mt(e) {
1191			return e instanceof ft(e).HTMLElement || e instanceof HTMLElement
1192		}
1193
1194		function gt(e) {
1195			return "undefined" != typeof ShadowRoot && (e instanceof ft(e).ShadowRoot || e instanceof ShadowRoot)
1196		}
1197		const _t = {
1198			name: "applyStyles",
1199			enabled: !0,
1200			phase: "write",
1201			fn: function(e) {
1202				var t = e.state;
vendor: 10,526 bytes, lines 1203-1596
1203				Object.keys(t.elements).forEach((function(e) {
1204					var n = t.styles[e] || {},
1205						i = t.attributes[e] || {},
1206						s = t.elements[e];
1207					mt(s) && ht(s) && (Object.assign(s.style, n), Object.keys(i).forEach((function(e) {
1208						var t = i[e];
1209						!1 === t ? s.removeAttribute(e) : s.setAttribute(e, !0 === t ? "" : t)
1210					})))
1211				}))
1212			},
1213			effect: function(e) {
1214				var t = e.state,
1215					n = {
1216						popper: {
1217							position: t.options.strategy,
1218							left: "0",
1219							top: "0",
1220							margin: "0"
1221						},
1222						arrow: {
1223							position: "absolute"
1224						},
1225						reference: {}
1226					};
1227				return Object.assign(t.elements.popper.style, n.popper), t.styles = n, t.elements.arrow && Object.assign(t.elements.arrow.style, n.arrow),
1228					function() {
1229						Object.keys(t.elements).forEach((function(e) {
1230							var i = t.elements[e],
1231								s = t.attributes[e] || {},
1232								o = Object.keys(t.styles.hasOwnProperty(e) ? t.styles[e] : n[e]).reduce((function(e, t) {
1233									return e[t] = "", e
1234								}), {});
1235							mt(i) && ht(i) && (Object.assign(i.style, o), Object.keys(s).forEach((function(e) {
1236								i.removeAttribute(e)
1237							})))
1238						}))
1239					}
1240			},
1241			requires: ["computeStyles"]
1242		};
1243
1244		function vt(e) {
1245			return e.split("-")[0]
1246		}
1247		var bt = Math.max,
1248			yt = Math.min,
1249			wt = Math.round;
1250
1251		function Et() {
1252			var e = navigator.userAgentData;
1253			return null != e && e.brands && Array.isArray(e.brands) ? e.brands.map((function(e) {
1254				return e.brand + "/" + e.version
1255			})).join(" ") : navigator.userAgent
1256		}
1257
1258		function At() {
1259			return !/^((?!chrome|android).)*safari/i.test(Et())
1260		}
1261
1262		function Tt(e, t, n) {
1263			void 0 === t && (t = !1), void 0 === n && (n = !1);
1264			var i = e.getBoundingClientRect(),
1265				s = 1,
1266				o = 1;
1267			t && mt(e) && (s = e.offsetWidth > 0 && wt(i.width) / e.offsetWidth || 1, o = e.offsetHeight > 0 && wt(i.height) / e.offsetHeight || 1);
1268			var r = (pt(e) ? ft(e) : window).visualViewport,
1269				a = !At() && n,
1270				l = (i.left + (a && r ? r.offsetLeft : 0)) / s,
1271				c = (i.top + (a && r ? r.offsetTop : 0)) / o,
1272				u = i.width / s,
1273				d = i.height / o;
1274			return {
1275				width: u,
1276				height: d,
1277				top: c,
1278				right: l + u,
1279				bottom: c + d,
1280				left: l,
1281				x: l,
1282				y: c
1283			}
1284		}
1285
1286		function Ct(e) {
1287			var t = Tt(e),
1288				n = e.offsetWidth,
1289				i = e.offsetHeight;
1290			return Math.abs(t.width - n) <= 1 && (n = t.width), Math.abs(t.height - i) <= 1 && (i = t.height), {
1291				x: e.offsetLeft,
1292				y: e.offsetTop,
1293				width: n,
1294				height: i
1295			}
1296		}
1297
1298		function St(e, t) {
1299			var n = t.getRootNode && t.getRootNode();
1300			if (e.contains(t)) return !0;
1301			if (n && gt(n)) {
1302				var i = t;
1303				do {
1304					if (i && e.isSameNode(i)) return !0;
1305					i = i.parentNode || i.host
1306				} while (i)
1307			}
1308			return !1
1309		}
1310
1311		function xt(e) {
1312			return ft(e).getComputedStyle(e)
1313		}
1314
1315		function Ot(e) {
1316			return ["table", "td", "th"].indexOf(ht(e)) >= 0
1317		}
1318
1319		function Lt(e) {
1320			return ((pt(e) ? e.ownerDocument : e.document) || window.document).documentElement
1321		}
1322
1323		function kt(e) {
1324			return "html" === ht(e) ? e : e.assignedSlot || e.parentNode || (gt(e) ? e.host : null) || Lt(e)
1325		}
1326
1327		function Dt(e) {
1328			return mt(e) && "fixed" !== xt(e).position ? e.offsetParent : null
1329		}
1330
1331		function It(e) {
1332			for (var t = ft(e), n = Dt(e); n && Ot(n) && "static" === xt(n).position;) n = Dt(n);
1333			return n && ("html" === ht(n) || "body" === ht(n) && "static" === xt(n).position) ? t : n || function(e) {
1334				var t = /firefox/i.test(Et());
1335				if (/Trident/i.test(Et()) && mt(e) && "fixed" === xt(e).position) return null;
1336				var n = kt(e);
1337				for (gt(n) && (n = n.host); mt(n) && ["html", "body"].indexOf(ht(n)) < 0;) {
1338					var i = xt(n);
1339					if ("none" !== i.transform || "none" !== i.perspective || "paint" === i.contain || -1 !== ["transform", "perspective"].indexOf(i.willChange) || t && "filter" === i.willChange || t && i.filter && "none" !== i.filter) return n;
1340					n = n.parentNode
1341				}
1342				return null
1343			}(e) || t
1344		}
1345
1346		function Mt(e) {
1347			return ["top", "bottom"].indexOf(e) >= 0 ? "x" : "y"
1348		}
1349
1350		function $t(e, t, n) {
1351			return bt(e, yt(t, n))
1352		}
1353
1354		function Pt(e) {
1355			return Object.assign({}, {
1356				top: 0,
1357				right: 0,
1358				bottom: 0,
1359				left: 0
1360			}, e)
1361		}
1362
1363		function Nt(e, t) {
1364			return t.reduce((function(t, n) {
1365				return t[n] = e, t
1366			}), {})
1367		}
1368		const jt = {
1369			name: "arrow",
1370			enabled: !0,
1371			phase: "main",
1372			fn: function(e) {
1373				var t, n = e.state,
1374					i = e.name,
1375					s = e.options,
1376					o = n.elements.arrow,
1377					r = n.modifiersData.popperOffsets,
1378					a = vt(n.placement),
1379					l = Mt(a),
1380					c = [Ve, ze].indexOf(a) >= 0 ? "height" : "width";
1381				if (o && r) {
1382					var u = function(e, t) {
1383							return Pt("number" != typeof(e = "function" == typeof e ? e(Object.assign({}, t.rects, {
1384								placement: t.placement
1385							})) : e) ? e : Nt(e, Qe))
1386						}(s.padding, n),
1387						d = Ct(o),
1388						h = "y" === l ? Be : Ve,
1389						f = "y" === l ? We : ze,
1390						p = n.rects.reference[c] + n.rects.reference[l] - r[l] - n.rects.popper[c],
1391						m = r[l] - n.rects.reference[l],
1392						g = It(o),
1393						_ = g ? "y" === l ? g.clientHeight || 0 : g.clientWidth || 0 : 0,
1394						v = p / 2 - m / 2,
1395						b = u[h],
1396						y = _ - d[c] - u[f],
1397						w = _ / 2 - d[c] / 2 + v,
1398						E = $t(b, w, y),
1399						A = l;
1400					n.modifiersData[i] = ((t = {})[A] = E, t.centerOffset = E - w, t)
1401				}
1402			},
1403			effect: function(e) {
1404				var t = e.state,
1405					n = e.options.element,
1406					i = void 0 === n ? "[data-popper-arrow]" : n;
1407				null != i && ("string" != typeof i || (i = t.elements.popper.querySelector(i))) && St(t.elements.popper, i) && (t.elements.arrow = i)
1408			},
1409			requires: ["popperOffsets"],
1410			requiresIfExists: ["preventOverflow"]
1411		};
1412
1413		function qt(e) {
1414			return e.split("-")[1]
1415		}
1416		var Ft = {
1417			top: "auto",
1418			right: "auto",
1419			bottom: "auto",
1420			left: "auto"
1421		};
1422
1423		function Ht(e) {
1424			var t, n = e.popper,
1425				i = e.popperRect,
1426				s = e.placement,
1427				o = e.variation,
1428				r = e.offsets,
1429				a = e.position,
1430				l = e.gpuAcceleration,
1431				c = e.adaptive,
1432				u = e.roundOffsets,
1433				d = e.isFixed,
1434				h = r.x,
1435				f = void 0 === h ? 0 : h,
1436				p = r.y,
1437				m = void 0 === p ? 0 : p,
1438				g = "function" == typeof u ? u({
1439					x: f,
1440					y: m
1441				}) : {
1442					x: f,
1443					y: m
1444				};
1445			f = g.x, m = g.y;
1446			var _ = r.hasOwnProperty("x"),
1447				v = r.hasOwnProperty("y"),
1448				b = Ve,
1449				y = Be,
1450				w = window;
1451			if (c) {
1452				var E = It(n),
1453					A = "clientHeight",
1454					T = "clientWidth";
1455				if (E === ft(n) && "static" !== xt(E = Lt(n)).position && "absolute" === a && (A = "scrollHeight", T = "scrollWidth"), s === Be || (s === Ve || s === ze) && o === Ye) y = We, m -= (d && E === w && w.visualViewport ? w.visualViewport.height : E[A]) - i.height, m *= l ? 1 : -1;
1456				if (s === Ve || (s === Be || s === We) && o === Ye) b = ze, f -= (d && E === w && w.visualViewport ? w.visualViewport.width : E[T]) - i.width, f *= l ? 1 : -1
1457			}
1458			var C, S = Object.assign({
1459					position: a
1460				}, c && Ft),
1461				x = !0 === u ? function(e, t) {
1462					var n = e.x,
1463						i = e.y,
1464						s = t.devicePixelRatio || 1;
1465					return {
1466						x: wt(n * s) / s || 0,
1467						y: wt(i * s) / s || 0
1468					}
1469				}({
1470					x: f,
1471					y: m
1472				}, ft(n)) : {
1473					x: f,
1474					y: m
1475				};
1476			return f = x.x, m = x.y, l ? Object.assign({}, S, ((C = {})[y] = v ? "0" : "", C[b] = _ ? "0" : "", C.transform = (w.devicePixelRatio || 1) <= 1 ? "translate(" + f + "px, " + m + "px)" : "translate3d(" + f + "px, " + m + "px, 0)", C)) : Object.assign({}, S, ((t = {})[y] = v ? m + "px" : "", t[b] = _ ? f + "px" : "", t.transform = "", t))
1477		}
1478		const Rt = {
1479			name: "computeStyles",
1480			enabled: !0,
1481			phase: "beforeWrite",
1482			fn: function(e) {
1483				var t = e.state,
1484					n = e.options,
1485					i = n.gpuAcceleration,
1486					s = void 0 === i || i,
1487					o = n.adaptive,
1488					r = void 0 === o || o,
1489					a = n.roundOffsets,
1490					l = void 0 === a || a,
1491					c = {
1492						placement: vt(t.placement),
1493						variation: qt(t.placement),
1494						popper: t.elements.popper,
1495						popperRect: t.rects.popper,
1496						gpuAcceleration: s,
1497						isFixed: "fixed" === t.options.strategy
1498					};
1499				null != t.modifiersData.popperOffsets && (t.styles.popper = Object.assign({}, t.styles.popper, Ht(Object.assign({}, c, {
1500					offsets: t.modifiersData.popperOffsets,
1501					position: t.options.strategy,
1502					adaptive: r,
1503					roundOffsets: l
1504				})))), null != t.modifiersData.arrow && (t.styles.arrow = Object.assign({}, t.styles.arrow, Ht(Object.assign({}, c, {
1505					offsets: t.modifiersData.arrow,
1506					position: "absolute",
1507					adaptive: !1,
1508					roundOffsets: l
1509				})))), t.attributes.popper = Object.assign({}, t.attributes.popper, {
1510					"data-popper-placement": t.placement
1511				})
1512			},
1513			data: {}
1514		};
1515		var Bt = {
1516			passive: !0
1517		};
1518		const Wt = {
1519			name: "eventListeners",
1520			enabled: !0,
1521			phase: "write",
1522			fn: function() {},
1523			effect: function(e) {
1524				var t = e.state,
1525					n = e.instance,
1526					i = e.options,
1527					s = i.scroll,
1528					o = void 0 === s || s,
1529					r = i.resize,
1530					a = void 0 === r || r,
1531					l = ft(t.elements.popper),
1532					c = [].concat(t.scrollParents.reference, t.scrollParents.popper);
1533				return o && c.forEach((function(e) {
1534						e.addEventListener("scroll", n.update, Bt)
1535					})), a && l.addEventListener("resize", n.update, Bt),
1536					function() {
1537						o && c.forEach((function(e) {
1538							e.removeEventListener("scroll", n.update, Bt)
1539						})), a && l.removeEventListener("resize", n.update, Bt)
1540					}
1541			},
1542			data: {}
1543		};
1544		var zt = {
1545			left: "right",
1546			right: "left",
1547			bottom: "top",
1548			top: "bottom"
1549		};
1550
1551		function Vt(e) {
1552			return e.replace(/left|right|bottom|top/g, (function(e) {
1553				return zt[e]
1554			}))
1555		}
1556		var Ut = {
1557			start: "end",
1558			end: "start"
1559		};
1560
1561		function Qt(e) {
1562			return e.replace(/start|end/g, (function(e) {
1563				return Ut[e]
1564			}))
1565		}
1566
1567		function Kt(e) {
1568			var t = ft(e);
1569			return {
1570				scrollLeft: t.pageXOffset,
1571				scrollTop: t.pageYOffset
1572			}
1573		}
1574
1575		function Yt(e) {
1576			return Tt(Lt(e)).left + Kt(e).scrollLeft
1577		}
1578
1579		function Xt(e) {
1580			var t = xt(e),
1581				n = t.overflow,
1582				i = t.overflowX,
1583				s = t.overflowY;
1584			return /auto|scroll|overlay|hidden/.test(n + s + i)
1585		}
1586
1587		function Jt(e) {
1588			return ["html", "body", "#document"].indexOf(ht(e)) >= 0 ? e.ownerDocument.body : mt(e) && Xt(e) ? e : Jt(kt(e))
1589		}
1590
1591		function Gt(e, t) {
1592			var n;
1593			void 0 === t && (t = []);
1594			var i = Jt(e),
1595				s = i === (null == (n = e.ownerDocument) ? void 0 : n.body),
1596				o = ft(i),
vendor: 4,201 bytes, lines 1597-1760
1597				r = s ? [o].concat(o.visualViewport || [], Xt(i) ? i : []) : i,
1598				a = t.concat(r);
1599			return s ? a : a.concat(Gt(kt(r)))
1600		}
1601
1602		function Zt(e) {
1603			return Object.assign({}, e, {
1604				left: e.x,
1605				top: e.y,
1606				right: e.x + e.width,
1607				bottom: e.y + e.height
1608			})
1609		}
1610
1611		function en(e, t, n) {
1612			return t === Je ? Zt(function(e, t) {
1613				var n = ft(e),
1614					i = Lt(e),
1615					s = n.visualViewport,
1616					o = i.clientWidth,
1617					r = i.clientHeight,
1618					a = 0,
1619					l = 0;
1620				if (s) {
1621					o = s.width, r = s.height;
1622					var c = At();
1623					(c || !c && "fixed" === t) && (a = s.offsetLeft, l = s.offsetTop)
1624				}
1625				return {
1626					width: o,
1627					height: r,
1628					x: a + Yt(e),
1629					y: l
1630				}
1631			}(e, n)) : pt(t) ? function(e, t) {
1632				var n = Tt(e, !1, "fixed" === t);
1633				return n.top = n.top + e.clientTop, n.left = n.left + e.clientLeft, n.bottom = n.top + e.clientHeight, n.right = n.left + e.clientWidth, n.width = e.clientWidth, n.height = e.clientHeight, n.x = n.left, n.y = n.top, n
1634			}(t, n) : Zt(function(e) {
1635				var t, n = Lt(e),
1636					i = Kt(e),
1637					s = null == (t = e.ownerDocument) ? void 0 : t.body,
1638					o = bt(n.scrollWidth, n.clientWidth, s ? s.scrollWidth : 0, s ? s.clientWidth : 0),
1639					r = bt(n.scrollHeight, n.clientHeight, s ? s.scrollHeight : 0, s ? s.clientHeight : 0),
1640					a = -i.scrollLeft + Yt(e),
1641					l = -i.scrollTop;
1642				return "rtl" === xt(s || n).direction && (a += bt(n.clientWidth, s ? s.clientWidth : 0) - o), {
1643					width: o,
1644					height: r,
1645					x: a,
1646					y: l
1647				}
1648			}(Lt(e)))
1649		}
1650
1651		function tn(e, t, n, i) {
1652			var s = "clippingParents" === t ? function(e) {
1653					var t = Gt(kt(e)),
1654						n = ["absolute", "fixed"].indexOf(xt(e).position) >= 0 && mt(e) ? It(e) : e;
1655					return pt(n) ? t.filter((function(e) {
1656						return pt(e) && St(e, n) && "body" !== ht(e)
1657					})) : []
1658				}(e) : [].concat(t),
1659				o = [].concat(s, [n]),
1660				r = o[0],
1661				a = o.reduce((function(t, n) {
1662					var s = en(e, n, i);
1663					return t.top = bt(s.top, t.top), t.right = yt(s.right, t.right), t.bottom = yt(s.bottom, t.bottom), t.left = bt(s.left, t.left), t
1664				}), en(e, r, i));
1665			return a.width = a.right - a.left, a.height = a.bottom - a.top, a.x = a.left, a.y = a.top, a
1666		}
1667
1668		function nn(e) {
1669			var t, n = e.reference,
1670				i = e.element,
1671				s = e.placement,
1672				o = s ? vt(s) : null,
1673				r = s ? qt(s) : null,
1674				a = n.x + n.width / 2 - i.width / 2,
1675				l = n.y + n.height / 2 - i.height / 2;
1676			switch (o) {
1677				case Be:
1678					t = {
1679						x: a,
1680						y: n.y - i.height
1681					};
1682					break;
1683				case We:
1684					t = {
1685						x: a,
1686						y: n.y + n.height
1687					};
1688					break;
1689				case ze:
1690					t = {
1691						x: n.x + n.width,
1692						y: l
1693					};
1694					break;
1695				case Ve:
1696					t = {
1697						x: n.x - i.width,
1698						y: l
1699					};
1700					break;
1701				default:
1702					t = {
1703						x: n.x,
1704						y: n.y
1705					}
1706			}
1707			var c = o ? Mt(o) : null;
1708			if (null != c) {
1709				var u = "y" === c ? "height" : "width";
1710				switch (r) {
1711					case Ke:
1712						t[c] = t[c] - (n[u] / 2 - i[u] / 2);
1713						break;
1714					case Ye:
1715						t[c] = t[c] + (n[u] / 2 - i[u] / 2)
1716				}
1717			}
1718			return t
1719		}
1720
1721		function sn(e, t) {
1722			void 0 === t && (t = {});
1723			var n = t,
1724				i = n.placement,
1725				s = void 0 === i ? e.placement : i,
1726				o = n.strategy,
1727				r = void 0 === o ? e.strategy : o,
1728				a = n.boundary,
1729				l = void 0 === a ? Xe : a,
1730				c = n.rootBoundary,
1731				u = void 0 === c ? Je : c,
1732				d = n.elementContext,
1733				h = void 0 === d ? Ge : d,
1734				f = n.altBoundary,
1735				p = void 0 !== f && f,
1736				m = n.padding,
1737				g = void 0 === m ? 0 : m,
1738				_ = Pt("number" != typeof g ? g : Nt(g, Qe)),
1739				v = h === Ge ? Ze : Ge,
1740				b = e.rects.popper,
1741				y = e.elements[p ? v : h],
1742				w = tn(pt(y) ? y : y.contextElement || Lt(e.elements.popper), l, u, r),
1743				E = Tt(e.elements.reference),
1744				A = nn({
1745					reference: E,
1746					element: b,
1747					strategy: "absolute",
1748					placement: s
1749				}),
1750				T = Zt(Object.assign({}, b, A)),
1751				C = h === Ge ? T : E,
1752				S = {
1753					top: w.top - C.top + _.top,
1754					bottom: C.bottom - w.bottom + _.bottom,
1755					left: w.left - C.left + _.left,
1756					right: C.right - w.right + _.right
1757				},
1758				x = e.modifiersData.offset;
1759			if (h === Ge && x) {
1760				var O = x[s];
vendor: 4,783 bytes, lines 1761-1947
1761				Object.keys(S).forEach((function(e) {
1762					var t = [ze, We].indexOf(e) >= 0 ? 1 : -1,
1763						n = [Be, We].indexOf(e) >= 0 ? "y" : "x";
1764					S[e] += O[n] * t
1765				}))
1766			}
1767			return S
1768		}
1769
1770		function on(e, t) {
1771			void 0 === t && (t = {});
1772			var n = t,
1773				i = n.placement,
1774				s = n.boundary,
1775				o = n.rootBoundary,
1776				r = n.padding,
1777				a = n.flipVariations,
1778				l = n.allowedAutoPlacements,
1779				c = void 0 === l ? tt : l,
1780				u = qt(i),
1781				d = u ? a ? et : et.filter((function(e) {
1782					return qt(e) === u
1783				})) : Qe,
1784				h = d.filter((function(e) {
1785					return c.indexOf(e) >= 0
1786				}));
1787			0 === h.length && (h = d);
1788			var f = h.reduce((function(t, n) {
1789				return t[n] = sn(e, {
1790					placement: n,
1791					boundary: s,
1792					rootBoundary: o,
1793					padding: r
1794				})[vt(n)], t
1795			}), {});
1796			return Object.keys(f).sort((function(e, t) {
1797				return f[e] - f[t]
1798			}))
1799		}
1800		const rn = {
1801			name: "flip",
1802			enabled: !0,
1803			phase: "main",
1804			fn: function(e) {
1805				var t = e.state,
1806					n = e.options,
1807					i = e.name;
1808				if (!t.modifiersData[i]._skip) {
1809					for (var s = n.mainAxis, o = void 0 === s || s, r = n.altAxis, a = void 0 === r || r, l = n.fallbackPlacements, c = n.padding, u = n.boundary, d = n.rootBoundary, h = n.altBoundary, f = n.flipVariations, p = void 0 === f || f, m = n.allowedAutoPlacements, g = t.options.placement, _ = vt(g), v = l || (_ === g || !p ? [Vt(g)] : function(e) {
1810							if (vt(e) === Ue) return [];
1811							var t = Vt(e);
1812							return [Qt(e), t, Qt(t)]
1813						}(g)), b = [g].concat(v).reduce((function(e, n) {
1814							return e.concat(vt(n) === Ue ? on(t, {
1815								placement: n,
1816								boundary: u,
1817								rootBoundary: d,
1818								padding: c,
1819								flipVariations: p,
1820								allowedAutoPlacements: m
1821							}) : n)
1822						}), []), y = t.rects.reference, w = t.rects.popper, E = new Map, A = !0, T = b[0], C = 0; C < b.length; C++) {
1823						var S = b[C],
1824							x = vt(S),
1825							O = qt(S) === Ke,
1826							L = [Be, We].indexOf(x) >= 0,
1827							k = L ? "width" : "height",
1828							D = sn(t, {
1829								placement: S,
1830								boundary: u,
1831								rootBoundary: d,
1832								altBoundary: h,
1833								padding: c
1834							}),
1835							I = L ? O ? ze : Ve : O ? We : Be;
1836						y[k] > w[k] && (I = Vt(I));
1837						var M = Vt(I),
1838							$ = [];
1839						if (o && $.push(D[x] <= 0), a && $.push(D[I] <= 0, D[M] <= 0), $.every((function(e) {
1840								return e
1841							}))) {
1842							T = S, A = !1;
1843							break
1844						}
1845						E.set(S, $)
1846					}
1847					if (A)
1848						for (var P = function(e) {
1849								var t = b.find((function(t) {
1850									var n = E.get(t);
1851									if (n) return n.slice(0, e).every((function(e) {
1852										return e
1853									}))
1854								}));
1855								if (t) return T = t, "break"
1856							}, N = p ? 3 : 1; N > 0; N--) {
1857							if ("break" === P(N)) break
1858						}
1859					t.placement !== T && (t.modifiersData[i]._skip = !0, t.placement = T, t.reset = !0)
1860				}
1861			},
1862			requiresIfExists: ["offset"],
1863			data: {
1864				_skip: !1
1865			}
1866		};
1867
1868		function an(e, t, n) {
1869			return void 0 === n && (n = {
1870				x: 0,
1871				y: 0
1872			}), {
1873				top: e.top - t.height - n.y,
1874				right: e.right - t.width + n.x,
1875				bottom: e.bottom - t.height + n.y,
1876				left: e.left - t.width - n.x
1877			}
1878		}
1879
1880		function ln(e) {
1881			return [Be, ze, We, Ve].some((function(t) {
1882				return e[t] >= 0
1883			}))
1884		}
1885		const cn = {
1886			name: "hide",
1887			enabled: !0,
1888			phase: "main",
1889			requiresIfExists: ["preventOverflow"],
1890			fn: function(e) {
1891				var t = e.state,
1892					n = e.name,
1893					i = t.rects.reference,
1894					s = t.rects.popper,
1895					o = t.modifiersData.preventOverflow,
1896					r = sn(t, {
1897						elementContext: "reference"
1898					}),
1899					a = sn(t, {
1900						altBoundary: !0
1901					}),
1902					l = an(r, i),
1903					c = an(a, s, o),
1904					u = ln(l),
1905					d = ln(c);
1906				t.modifiersData[n] = {
1907					referenceClippingOffsets: l,
1908					popperEscapeOffsets: c,
1909					isReferenceHidden: u,
1910					hasPopperEscaped: d
1911				}, t.attributes.popper = Object.assign({}, t.attributes.popper, {
1912					"data-popper-reference-hidden": u,
1913					"data-popper-escaped": d
1914				})
1915			}
1916		};
1917		const un = {
1918			name: "offset",
1919			enabled: !0,
1920			phase: "main",
1921			requires: ["popperOffsets"],
1922			fn: function(e) {
1923				var t = e.state,
1924					n = e.options,
1925					i = e.name,
1926					s = n.offset,
1927					o = void 0 === s ? [0, 0] : s,
1928					r = tt.reduce((function(e, n) {
1929						return e[n] = function(e, t, n) {
1930							var i = vt(e),
1931								s = [Ve, Be].indexOf(i) >= 0 ? -1 : 1,
1932								o = "function" == typeof n ? n(Object.assign({}, t, {
1933									placement: e
1934								})) : n,
1935								r = o[0],
1936								a = o[1];
1937							return r = r || 0, a = (a || 0) * s, [Ve, ze].indexOf(i) >= 0 ? {
1938								x: a,
1939								y: r
1940							} : {
1941								x: r,
1942								y: a
1943							}
1944						}(n, t.rects, o), e
1945					}), {}),
1946					a = r[t.placement],
1947					l = a.x,
vendor: 4,365 bytes, lines 1948-2110
1948					c = a.y;
1949				null != t.modifiersData.popperOffsets && (t.modifiersData.popperOffsets.x += l, t.modifiersData.popperOffsets.y += c), t.modifiersData[i] = r
1950			}
1951		};
1952		const dn = {
1953			name: "popperOffsets",
1954			enabled: !0,
1955			phase: "read",
1956			fn: function(e) {
1957				var t = e.state,
1958					n = e.name;
1959				t.modifiersData[n] = nn({
1960					reference: t.rects.reference,
1961					element: t.rects.popper,
1962					strategy: "absolute",
1963					placement: t.placement
1964				})
1965			},
1966			data: {}
1967		};
1968		const hn = {
1969			name: "preventOverflow",
1970			enabled: !0,
1971			phase: "main",
1972			fn: function(e) {
1973				var t = e.state,
1974					n = e.options,
1975					i = e.name,
1976					s = n.mainAxis,
1977					o = void 0 === s || s,
1978					r = n.altAxis,
1979					a = void 0 !== r && r,
1980					l = n.boundary,
1981					c = n.rootBoundary,
1982					u = n.altBoundary,
1983					d = n.padding,
1984					h = n.tether,
1985					f = void 0 === h || h,
1986					p = n.tetherOffset,
1987					m = void 0 === p ? 0 : p,
1988					g = sn(t, {
1989						boundary: l,
1990						rootBoundary: c,
1991						padding: d,
1992						altBoundary: u
1993					}),
1994					_ = vt(t.placement),
1995					v = qt(t.placement),
1996					b = !v,
1997					y = Mt(_),
1998					w = "x" === y ? "y" : "x",
1999					E = t.modifiersData.popperOffsets,
2000					A = t.rects.reference,
2001					T = t.rects.popper,
2002					C = "function" == typeof m ? m(Object.assign({}, t.rects, {
2003						placement: t.placement
2004					})) : m,
2005					S = "number" == typeof C ? {
2006						mainAxis: C,
2007						altAxis: C
2008					} : Object.assign({
2009						mainAxis: 0,
2010						altAxis: 0
2011					}, C),
2012					x = t.modifiersData.offset ? t.modifiersData.offset[t.placement] : null,
2013					O = {
2014						x: 0,
2015						y: 0
2016					};
2017				if (E) {
2018					if (o) {
2019						var L, k = "y" === y ? Be : Ve,
2020							D = "y" === y ? We : ze,
2021							I = "y" === y ? "height" : "width",
2022							M = E[y],
2023							$ = M + g[k],
2024							P = M - g[D],
2025							N = f ? -T[I] / 2 : 0,
2026							j = v === Ke ? A[I] : T[I],
2027							q = v === Ke ? -T[I] : -A[I],
2028							F = t.elements.arrow,
2029							H = f && F ? Ct(F) : {
2030								width: 0,
2031								height: 0
2032							},
2033							R = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : {
2034								top: 0,
2035								right: 0,
2036								bottom: 0,
2037								left: 0
2038							},
2039							B = R[k],
2040							W = R[D],
2041							z = $t(0, A[I], H[I]),
2042							V = b ? A[I] / 2 - N - z - B - S.mainAxis : j - z - B - S.mainAxis,
2043							U = b ? -A[I] / 2 + N + z + W + S.mainAxis : q + z + W + S.mainAxis,
2044							Q = t.elements.arrow && It(t.elements.arrow),
2045							K = Q ? "y" === y ? Q.clientTop || 0 : Q.clientLeft || 0 : 0,
2046							Y = null != (L = null == x ? void 0 : x[y]) ? L : 0,
2047							X = M + U - Y,
2048							J = $t(f ? yt($, M + V - Y - K) : $, M, f ? bt(P, X) : P);
2049						E[y] = J, O[y] = J - M
2050					}
2051					if (a) {
2052						var G, Z = "x" === y ? Be : Ve,
2053							ee = "x" === y ? We : ze,
2054							te = E[w],
2055							ne = "y" === w ? "height" : "width",
2056							ie = te + g[Z],
2057							se = te - g[ee],
2058							oe = -1 !== [Be, Ve].indexOf(_),
2059							re = null != (G = null == x ? void 0 : x[w]) ? G : 0,
2060							ae = oe ? ie : te - A[ne] - T[ne] - re + S.altAxis,
2061							le = oe ? te + A[ne] + T[ne] - re - S.altAxis : se,
2062							ce = f && oe ? function(e, t, n) {
2063								var i = $t(e, t, n);
2064								return i > n ? n : i
2065							}(ae, te, le) : $t(f ? ae : ie, te, f ? le : se);
2066						E[w] = ce, O[w] = ce - te
2067					}
2068					t.modifiersData[i] = O
2069				}
2070			},
2071			requiresIfExists: ["offset"]
2072		};
2073
2074		function fn(e, t, n) {
2075			void 0 === n && (n = !1);
2076			var i, s, o = mt(t),
2077				r = mt(t) && function(e) {
2078					var t = e.getBoundingClientRect(),
2079						n = wt(t.width) / e.offsetWidth || 1,
2080						i = wt(t.height) / e.offsetHeight || 1;
2081					return 1 !== n || 1 !== i
2082				}(t),
2083				a = Lt(t),
2084				l = Tt(e, r, n),
2085				c = {
2086					scrollLeft: 0,
2087					scrollTop: 0
2088				},
2089				u = {
2090					x: 0,
2091					y: 0
2092				};
2093			return (o || !o && !n) && (("body" !== ht(t) || Xt(a)) && (c = (i = t) !== ft(i) && mt(i) ? {
2094				scrollLeft: (s = i).scrollLeft,
2095				scrollTop: s.scrollTop
2096			} : Kt(i)), mt(t) ? ((u = Tt(t, !0)).x += t.clientLeft, u.y += t.clientTop) : a && (u.x = Yt(a))), {
2097				x: l.left + c.scrollLeft - u.x,
2098				y: l.top + c.scrollTop - u.y,
2099				width: l.width,
2100				height: l.height
2101			}
2102		}
2103
2104		function pn(e) {
2105			var t = new Map,
2106				n = new Set,
2107				i = [];
2108
2109			function s(e) {
2110				n.add(e.name), [].concat(e.requires || [], e.requiresIfExists || []).forEac
vendor: 6,041 bytes, lines 2110-2345
2110h((function(e) {
2111					if (!n.has(e)) {
2112						var i = t.get(e);
2113						i && s(i)
2114					}
2115				})), i.push(e)
2116			}
2117			return e.forEach((function(e) {
2118				t.set(e.name, e)
2119			})), e.forEach((function(e) {
2120				n.has(e.name) || s(e)
2121			})), i
2122		}
2123		var mn = {
2124			placement: "bottom",
2125			modifiers: [],
2126			strategy: "absolute"
2127		};
2128
2129		function gn() {
2130			for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++) t[n] = arguments[n];
2131			return !t.some((function(e) {
2132				return !(e && "function" == typeof e.getBoundingClientRect)
2133			}))
2134		}
2135
2136		function _n(e) {
2137			void 0 === e && (e = {});
2138			var t = e,
2139				n = t.defaultModifiers,
2140				i = void 0 === n ? [] : n,
2141				s = t.defaultOptions,
2142				o = void 0 === s ? mn : s;
2143			return function(e, t, n) {
2144				void 0 === n && (n = o);
2145				var s, r, a = {
2146						placement: "bottom",
2147						orderedModifiers: [],
2148						options: Object.assign({}, mn, o),
2149						modifiersData: {},
2150						elements: {
2151							reference: e,
2152							popper: t
2153						},
2154						attributes: {},
2155						styles: {}
2156					},
2157					l = [],
2158					c = !1,
2159					u = {
2160						state: a,
2161						setOptions: function(n) {
2162							var s = "function" == typeof n ? n(a.options) : n;
2163							d(), a.options = Object.assign({}, o, a.options, s), a.scrollParents = {
2164								reference: pt(e) ? Gt(e) : e.contextElement ? Gt(e.contextElement) : [],
2165								popper: Gt(t)
2166							};
2167							var r, c, h = function(e) {
2168								var t = pn(e);
2169								return dt.reduce((function(e, n) {
2170									return e.concat(t.filter((function(e) {
2171										return e.phase === n
2172									})))
2173								}), [])
2174							}((r = [].concat(i, a.options.modifiers), c = r.reduce((function(e, t) {
2175								var n = e[t.name];
2176								return e[t.name] = n ? Object.assign({}, n, t, {
2177									options: Object.assign({}, n.options, t.options),
2178									data: Object.assign({}, n.data, t.data)
2179								}) : t, e
2180							}), {}), Object.keys(c).map((function(e) {
2181								return c[e]
2182							}))));
2183							return a.orderedModifiers = h.filter((function(e) {
2184								return e.enabled
2185							})), a.orderedModifiers.forEach((function(e) {
2186								var t = e.name,
2187									n = e.options,
2188									i = void 0 === n ? {} : n,
2189									s = e.effect;
2190								if ("function" == typeof s) {
2191									var o = s({
2192											state: a,
2193											name: t,
2194											instance: u,
2195											options: i
2196										}),
2197										r = function() {};
2198									l.push(o || r)
2199								}
2200							})), u.update()
2201						},
2202						forceUpdate: function() {
2203							if (!c) {
2204								var e = a.elements,
2205									t = e.reference,
2206									n = e.popper;
2207								if (gn(t, n)) {
2208									a.rects = {
2209										reference: fn(t, It(n), "fixed" === a.options.strategy),
2210										popper: Ct(n)
2211									}, a.reset = !1, a.placement = a.options.placement, a.orderedModifiers.forEach((function(e) {
2212										return a.modifiersData[e.name] = Object.assign({}, e.data)
2213									}));
2214									for (var i = 0; i < a.orderedModifiers.length; i++)
2215										if (!0 !== a.reset) {
2216											var s = a.orderedModifiers[i],
2217												o = s.fn,
2218												r = s.options,
2219												l = void 0 === r ? {} : r,
2220												d = s.name;
2221											"function" == typeof o && (a = o({
2222												state: a,
2223												options: l,
2224												name: d,
2225												instance: u
2226											}) || a)
2227										} else a.reset = !1, i = -1
2228								}
2229							}
2230						},
2231						update: (s = function() {
2232							return new Promise((function(e) {
2233								u.forceUpdate(), e(a)
2234							}))
2235						}, function() {
2236							return r || (r = new Promise((function(e) {
2237								Promise.resolve().then((function() {
2238									r = void 0, e(s())
2239								}))
2240							}))), r
2241						}),
2242						destroy: function() {
2243							d(), c = !0
2244						}
2245					};
2246				if (!gn(e, t)) return u;
2247
2248				function d() {
2249					l.forEach((function(e) {
2250						return e()
2251					})), l = []
2252				}
2253				return u.setOptions(n).then((function(e) {
2254					!c && n.onFirstUpdate && n.onFirstUpdate(e)
2255				})), u
2256			}
2257		}
2258		var vn = _n(),
2259			bn = _n({
2260				defaultModifiers: [Wt, dn, Rt, _t]
2261			}),
2262			yn = _n({
2263				defaultModifiers: [Wt, dn, Rt, _t, un, rn, hn, jt, cn]
2264			});
2265		const wn = Object.freeze(Object.defineProperty({
2266				__proto__: null,
2267				afterMain: at,
2268				afterRead: st,
2269				afterWrite: ut,
2270				applyStyles: _t,
2271				arrow: jt,
2272				auto: Ue,
2273				basePlacements: Qe,
2274				beforeMain: ot,
2275				beforeRead: nt,
2276				beforeWrite: lt,
2277				bottom: We,
2278				clippingParents: Xe,
2279				computeStyles: Rt,
2280				createPopper: yn,
2281				createPopperBase: vn,
2282				createPopperLite: bn,
2283				detectOverflow: sn,
2284				end: Ye,
2285				eventListeners: Wt,
2286				flip: rn,
2287				hide: cn,
2288				left: Ve,
2289				main: rt,
2290				modifierPhases: dt,
2291				offset: un,
2292				placements: tt,
2293				popper: Ge,
2294				popperGenerator: _n,
2295				popperOffsets: dn,
2296				preventOverflow: hn,
2297				read: it,
2298				reference: Ze,
2299				right: ze,
2300				start: Ke,
2301				top: Be,
2302				variationPlacements: et,
2303				viewport: Je,
2304				write: ct
2305			}, Symbol.toStringTag, {
2306				value: "Module"
2307			})),
2308			En = "dropdown",
2309			An = ".bs.dropdown",
2310			Tn = ".data-api",
2311			Cn = "ArrowUp",
2312			Sn = "ArrowDown",
2313			xn = `hide${An}`,
2314			On = `hidden${An}`,
2315			Ln = `show${An}`,
2316			kn = `shown${An}`,
2317			Dn = `click${An}${Tn}`,
2318			In = `keydown${An}${Tn}`,
2319			Mn = `keyup${An}${Tn}`,
2320			$n = "show",
2321			Pn = '[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',
2322			Nn = `${Pn}.${$n}`,
2323			jn = ".dropdown-menu",
2324			qn = p() ? "top-end" : "top-start",
2325			Fn = p() ? "top-start" : "top-end",
2326			Hn = p() ? "bottom-end" : "bottom-start",
2327			Rn = p() ? "bottom-start" : "bottom-end",
2328			Bn = p() ? "left-start" : "right-start",
2329			Wn = p() ? "right-start" : "left-start",
2330			zn = {
2331				autoClose: !0,
2332				boundary: "clippingParents",
2333				display: "dynamic",
2334				offset: [0, 2],
2335				popperConfig: null,
2336				reference: "toggle"
2337			},
2338			Vn = {
2339				autoClose: "(boolean|string)",
2340				boundary: "(string|element)",
2341				display: "string",
2342				offset: "(array|string|function)",
2343				popperConfig: "(null|object|function)",
2344				reference: "(string|element|object)"
2345			};
vendor: 3,152 bytes, lines 2346-2416
2346		class Un extends H {
2347			constructor(e, t) {
2348				super(e, t), this._popper = null, this._parent = this._element.parentNode, this._menu = B.next(this._element, jn)[0] || B.prev(this._element, jn)[0] || B.findOne(jn, this._parent), this._inNavbar = this._detectNavbar()
2349			}
2350			static get Default() {
2351				return zn
2352			}
2353			static get DefaultType() {
2354				return Vn
2355			}
2356			static get NAME() {
2357				return En
2358			}
2359			toggle() {
2360				return this._isShown() ? this.hide() : this.show()
2361			}
2362			show() {
2363				if (l(this._element) || this._isShown()) return;
2364				const e = {
2365					relatedTarget: this._element
2366				};
2367				if (!$.trigger(this._element, Ln, e).defaultPrevented) {
2368					if (this._createPopper(), "ontouchstart" in document.documentElement && !this._parent.closest(".navbar-nav"))
2369						for (const e of [].concat(...document.body.children)) $.on(e, "mouseover", u);
2370					this._element.focus(), this._element.setAttribute("aria-expanded", !0), this._menu.classList.add($n), this._element.classList.add($n), $.trigger(this._element, kn, e)
2371				}
2372			}
2373			hide() {
2374				if (l(this._element) || !this._isShown()) return;
2375				const e = {
2376					relatedTarget: this._element
2377				};
2378				this._completeHide(e)
2379			}
2380			dispose() {
2381				this._popper && this._popper.destroy(), super.dispose()
2382			}
2383			update() {
2384				this._inNavbar = this._detectNavbar(), this._popper && this._popper.update()
2385			}
2386			_completeHide(e) {
2387				if (!$.trigger(this._element, xn, e).defaultPrevented) {
2388					if ("ontouchstart" in document.documentElement)
2389						for (const e of [].concat(...document.body.children)) $.off(e, "mouseover", u);
2390					this._popper && this._popper.destroy(), this._menu.classList.remove($n), this._element.classList.remove($n), this._element.setAttribute("aria-expanded", "false"), q.removeDataAttribute(this._menu, "popper"), $.trigger(this._element, On, e)
2391				}
2392			}
2393			_getConfig(e) {
2394				if ("object" == typeof(e = super._getConfig(e)).reference && !o(e.reference) && "function" != typeof e.reference.getBoundingClientRect) throw new TypeError(`${En.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);
2395				return e
2396			}
2397			_createPopper() {
2398				if (void 0 === wn) throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");
2399				let e = this._element;
2400				"parent" === this._config.reference ? e = this._parent : o(this._config.reference) ? e = r(this._config.reference) : "object" == typeof this._config.reference && (e = this._config.reference);
2401				const t = this._getPopperConfig();
2402				this._popper = yn(e, this._menu, t)
2403			}
2404			_isShown() {
2405				return this._menu.classList.contains($n)
2406			}
2407			_getPlacement() {
2408				const e = this._parent;
2409				if (e.classList.contains("dropend")) return Bn;
2410				if (e.classList.contains("dropstart")) return Wn;
2411				if (e.classList.contains("dropup-center")) return "top";
2412				if (e.classList.contains("dropdown-center")) return "bottom";
2413				const t = "end" === getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();
2414				return e.classList.contains("dropup") ? t ? Fn : qn : t ? Rn : Hn
2415			}
2416			_detectNavbar() {
vendor: 4,870 bytes, lines 2417-2574
2417				return null !== this._element.closest(".navbar")
2418			}
2419			_getOffset() {
2420				const {
2421					offset: e
2422				} = this._config;
2423				return "string" == typeof e ? e.split(",").map((e => Number.parseInt(e, 10))) : "function" == typeof e ? t => e(t, this._element) : e
2424			}
2425			_getPopperConfig() {
2426				const e = {
2427					placement: this._getPlacement(),
2428					modifiers: [{
2429						name: "preventOverflow",
2430						options: {
2431							boundary: this._config.boundary
2432						}
2433					}, {
2434						name: "offset",
2435						options: {
2436							offset: this._getOffset()
2437						}
2438					}]
2439				};
2440				return (this._inNavbar || "static" === this._config.display) && (q.setDataAttribute(this._menu, "popper", "static"), e.modifiers = [{
2441					name: "applyStyles",
2442					enabled: !1
2443				}]), {
2444					...e,
2445					...g(this._config.popperConfig, [e])
2446				}
2447			}
2448			_selectMenuItem({
2449				key: e,
2450				target: t
2451			}) {
2452				const n = B.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)", this._menu).filter((e => a(e)));
2453				n.length && v(n, t, e === Sn, !n.includes(t)).focus()
2454			}
2455			static jQueryInterface(e) {
2456				return this.each((function() {
2457					const t = Un.getOrCreateInstance(this, e);
2458					if ("string" == typeof e) {
2459						if (void 0 === t[e]) throw new TypeError(`No method named "${e}"`);
2460						t[e]()
2461					}
2462				}))
2463			}
2464			static clearMenus(e) {
2465				if (2 === e.button || "keyup" === e.type && "Tab" !== e.key) return;
2466				const t = B.find(Nn);
2467				for (const n of t) {
2468					const t = Un.getInstance(n);
2469					if (!t || !1 === t._config.autoClose) continue;
2470					const i = e.composedPath(),
2471						s = i.includes(t._menu);
2472					if (i.includes(t._element) || "inside" === t._config.autoClose && !s || "outside" === t._config.autoClose && s) continue;
2473					if (t._menu.contains(e.target) && ("keyup" === e.type && "Tab" === e.key || /input|select|option|textarea|form/i.test(e.target.tagName))) continue;
2474					const o = {
2475						relatedTarget: t._element
2476					};
2477					"click" === e.type && (o.clickEvent = e), t._completeHide(o)
2478				}
2479			}
2480			static dataApiKeydownHandler(e) {
2481				const t = /input|textarea/i.test(e.target.tagName),
2482					n = "Escape" === e.key,
2483					i = [Cn, Sn].includes(e.key);
2484				if (!i && !n) return;
2485				if (t && !n) return;
2486				e.preventDefault();
2487				const s = this.matches(Pn) ? this : B.prev(this, Pn)[0] || B.next(this, Pn)[0] || B.findOne(Pn, e.delegateTarget.parentNode),
2488					o = Un.getOrCreateInstance(s);
2489				if (i) return e.stopPropagation(), o.show(), void o._selectMenuItem(e);
2490				o._isShown() && (e.stopPropagation(), o.hide(), s.focus())
2491			}
2492		}
2493		$.on(document, In, Pn, Un.dataApiKeydownHandler), $.on(document, In, jn, Un.dataApiKeydownHandler), $.on(document, Dn, Un.clearMenus), $.on(document, Mn, Un.clearMenus), $.on(document, Dn, Pn, (function(e) {
2494			e.preventDefault(), Un.getOrCreateInstance(this).toggle()
2495		})), m(Un);
2496		const Qn = "backdrop",
2497			Kn = "show",
2498			Yn = `mousedown.bs.${Qn}`,
2499			Xn = {
2500				className: "modal-backdrop",
2501				clickCallback: null,
2502				isAnimated: !1,
2503				isVisible: !0,
2504				rootElement: "body"
2505			},
2506			Jn = {
2507				className: "string",
2508				clickCallback: "(function|null)",
2509				isAnimated: "boolean",
2510				isVisible: "boolean",
2511				rootElement: "(element|string)"
2512			};
2513		class Gn extends F {
2514			constructor(e) {
2515				super(), this._config = this._getConfig(e), this._isAppended = !1, this._element = null
2516			}
2517			static get Default() {
2518				return Xn
2519			}
2520			static get DefaultType() {
2521				return Jn
2522			}
2523			static get NAME() {
2524				return Qn
2525			}
2526			show(e) {
2527				if (!this._config.isVisible) return void g(e);
2528				this._append();
2529				const t = this._getElement();
2530				this._config.isAnimated && d(t), t.classList.add(Kn), this._emulateAnimation((() => {
2531					g(e)
2532				}))
2533			}
2534			hide(e) {
2535				this._config.isVisible ? (this._getElement().classList.remove(Kn), this._emulateAnimation((() => {
2536					this.dispose(), g(e)
2537				}))) : g(e)
2538			}
2539			dispose() {
2540				this._isAppended && ($.off(this._element, Yn), this._element.remove(), this._isAppended = !1)
2541			}
2542			_getElement() {
2543				if (!this._element) {
2544					const e = document.createElement("div");
2545					e.className = this._config.className, this._config.isAnimated && e.classList.add("fade"), this._element = e
2546				}
2547				return this._element
2548			}
2549			_configAfterMerge(e) {
2550				return e.rootElement = r(e.rootElement), e
2551			}
2552			_append() {
2553				if (this._isAppended) return;
2554				const e = this._getElement();
2555				this._config.rootElement.append(e), $.on(e, Yn, (() => {
2556					g(this._config.clickCallback)
2557				})), this._isAppended = !0
2558			}
2559			_emulateAnimation(e) {
2560				_(e, this._getElement(), this._config.isAnimated)
2561			}
2562		}
2563		const Zn = ".bs.focustrap",
2564			ei = `focusin${Zn}`,
2565			ti = `keydown.tab${Zn}`,
2566			ni = "backward",
2567			ii = {
2568				autofocus: !0,
2569				trapElement: null
2570			},
2571			si = {
2572				autofocus: "boolean",
2573				trapElement: "element"
2574			};
vendor: 7,895 bytes, lines 2575-2781
2575		class oi extends F {
2576			constructor(e) {
2577				super(), this._config = this._getConfig(e), this._isActive = !1, this._lastTabNavDirection = null
2578			}
2579			static get Default() {
2580				return ii
2581			}
2582			static get DefaultType() {
2583				return si
2584			}
2585			static get NAME() {
2586				return "focustrap"
2587			}
2588			activate() {
2589				this._isActive || (this._config.autofocus && this._config.trapElement.focus(), $.off(document, Zn), $.on(document, ei, (e => this._handleFocusin(e))), $.on(document, ti, (e => this._handleKeydown(e))), this._isActive = !0)
2590			}
2591			deactivate() {
2592				this._isActive && (this._isActive = !1, $.off(document, Zn))
2593			}
2594			_handleFocusin(e) {
2595				const {
2596					trapElement: t
2597				} = this._config;
2598				if (e.target === document || e.target === t || t.contains(e.target)) return;
2599				const n = B.focusableChildren(t);
2600				0 === n.length ? t.focus() : this._lastTabNavDirection === ni ? n[n.length - 1].focus() : n[0].focus()
2601			}
2602			_handleKeydown(e) {
2603				"Tab" === e.key && (this._lastTabNavDirection = e.shiftKey ? ni : "forward")
2604			}
2605		}
2606		const ri = ".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",
2607			ai = ".sticky-top",
2608			li = "padding-right",
2609			ci = "margin-right";
2610		class ui {
2611			constructor() {
2612				this._element = document.body
2613			}
2614			getWidth() {
2615				const e = document.documentElement.clientWidth;
2616				return Math.abs(window.innerWidth - e)
2617			}
2618			hide() {
2619				const e = this.getWidth();
2620				this._disableOverFlow(), this._setElementAttributes(this._element, li, (t => t + e)), this._setElementAttributes(ri, li, (t => t + e)), this._setElementAttributes(ai, ci, (t => t - e))
2621			}
2622			reset() {
2623				this._resetElementAttributes(this._element, "overflow"), this._resetElementAttributes(this._element, li), this._resetElementAttributes(ri, li), this._resetElementAttributes(ai, ci)
2624			}
2625			isOverflowing() {
2626				return this.getWidth() > 0
2627			}
2628			_disableOverFlow() {
2629				this._saveInitialAttribute(this._element, "overflow"), this._element.style.overflow = "hidden"
2630			}
2631			_setElementAttributes(e, t, n) {
2632				const i = this.getWidth();
2633				this._applyManipulationCallback(e, (e => {
2634					if (e !== this._element && window.innerWidth > e.clientWidth + i) return;
2635					this._saveInitialAttribute(e, t);
2636					const s = window.getComputedStyle(e).getPropertyValue(t);
2637					e.style.setProperty(t, `${n(Number.parseFloat(s))}px`)
2638				}))
2639			}
2640			_saveInitialAttribute(e, t) {
2641				const n = e.style.getPropertyValue(t);
2642				n && q.setDataAttribute(e, t, n)
2643			}
2644			_resetElementAttributes(e, t) {
2645				this._applyManipulationCallback(e, (e => {
2646					const n = q.getDataAttribute(e, t);
2647					null !== n ? (q.removeDataAttribute(e, t), e.style.setProperty(t, n)) : e.style.removeProperty(t)
2648				}))
2649			}
2650			_applyManipulationCallback(e, t) {
2651				if (o(e)) t(e);
2652				else
2653					for (const n of B.find(e, this._element)) t(n)
2654			}
2655		}
2656		const di = ".bs.modal",
2657			hi = `hide${di}`,
2658			fi = `hidePrevented${di}`,
2659			pi = `hidden${di}`,
2660			mi = `show${di}`,
2661			gi = `shown${di}`,
2662			_i = `resize${di}`,
2663			vi = `click.dismiss${di}`,
2664			bi = `mousedown.dismiss${di}`,
2665			yi = `keydown.dismiss${di}`,
2666			wi = `click${di}.data-api`,
2667			Ei = "modal-open",
2668			Ai = "show",
2669			Ti = "modal-static",
2670			Ci = {
2671				backdrop: !0,
2672				focus: !0,
2673				keyboard: !0
2674			},
2675			Si = {
2676				backdrop: "(boolean|string)",
2677				focus: "boolean",
2678				keyboard: "boolean"
2679			};
2680		class xi extends H {
2681			constructor(e, t) {
2682				super(e, t), this._dialog = B.findOne(".modal-dialog", this._element), this._backdrop = this._initializeBackDrop(), this._focustrap = this._initializeFocusTrap(), this._isShown = !1, this._isTransitioning = !1, this._scrollBar = new ui, this._addEventListeners()
2683			}
2684			static get Default() {
2685				return Ci
2686			}
2687			static get DefaultType() {
2688				return Si
2689			}
2690			static get NAME() {
2691				return "modal"
2692			}
2693			toggle(e) {
2694				return this._isShown ? this.hide() : this.show(e)
2695			}
2696			show(e) {
2697				if (this._isShown || this._isTransitioning) return;
2698				$.trigger(this._element, mi, {
2699					relatedTarget: e
2700				}).defaultPrevented || (this._isShown = !0, this._isTransitioning = !0, this._scrollBar.hide(), document.body.classList.add(Ei), this._adjustDialog(), this._backdrop.show((() => this._showElement(e))))
2701			}
2702			hide() {
2703				if (!this._isShown || this._isTransitioning) return;
2704				$.trigger(this._element, hi).defaultPrevented || (this._isShown = !1, this._isTransitioning = !0, this._focustrap.deactivate(), this._element.classList.remove(Ai), this._queueCallback((() => this._hideModal()), this._element, this._isAnimated()))
2705			}
2706			dispose() {
2707				$.off(window, di), $.off(this._dialog, di), this._backdrop.dispose(), this._focustrap.deactivate(), super.dispose()
2708			}
2709			handleUpdate() {
2710				this._adjustDialog()
2711			}
2712			_initializeBackDrop() {
2713				return new Gn({
2714					isVisible: Boolean(this._config.backdrop),
2715					isAnimated: this._isAnimated()
2716				})
2717			}
2718			_initializeFocusTrap() {
2719				return new oi({
2720					trapElement: this._element
2721				})
2722			}
2723			_showElement(e) {
2724				document.body.contains(this._element) || document.body.append(this._element), this._element.style.display = "block", this._element.removeAttribute("aria-hidden"), this._element.setAttribute("aria-modal", !0), this._element.setAttribute("role", "dialog"), this._element.scrollTop = 0;
2725				const t = B.findOne(".modal-body", this._dialog);
2726				t && (t.scrollTop = 0), d(this._element), this._element.classList.add(Ai);
2727				this._queueCallback((() => {
2728					this._config.focus && this._focustrap.activate(), this._isTransitioning = !1, $.trigger(this._element, gi, {
2729						relatedTarget: e
2730					})
2731				}), this._dialog, this._isAnimated())
2732			}
2733			_addEventListeners() {
2734				$.on(this._element, yi, (e => {
2735					"Escape" === e.key && (this._config.keyboard ? this.hide() : this._triggerBackdropTransition())
2736				})), $.on(window, _i, (() => {
2737					this._isShown && !this._isTransitioning && this._adjustDialog()
2738				})), $.on(this._element, bi, (e => {
2739					$.one(this._element, vi, (t => {
2740						this._element === e.target && this._element === t.target && ("static" !== this._config.backdrop ? this._config.backdrop && this.hide() : this._triggerBackdropTransition())
2741					}))
2742				}))
2743			}
2744			_hideModal() {
2745				this._element.style.display = "none", this._element.setAttribute("aria-hidden", !0), this._element.removeAttribute("aria-modal"), this._element.removeAttribute("role"), this._isTransitioning = !1, this._backdrop.hide((() => {
2746					document.body.classList.remove(Ei), this._resetAdjustments(), this._scrollBar.reset(), $.trigger(this._element, pi)
2747				}))
2748			}
2749			_isAnimated() {
2750				return this._element.classList.contains("fade")
2751			}
2752			_triggerBackdropTransition() {
2753				if ($.trigger(this._element, fi).defaultPrevented) return;
2754				const e = this._element.scrollHeight > document.documentElement.clientHeight,
2755					t = this._element.style.overflowY;
2756				"hidden" === t || this._element.classList.contains(Ti) || (e || (this._element.style.overflowY = "hidden"), this._element.classList.add(Ti), this._queueCallback((() => {
2757					this._element.classList.remove(Ti), this._queueCallback((() => {
2758						this._element.style.overflowY = t
2759					}), this._dialog)
2760				}), this._dialog), this._element.focus())
2761			}
2762			_adjustDialog() {
2763				const e = this._element.scrollHeight > document.documentElement.clientHeight,
2764					t = this._scrollBar.getWidth(),
2765					n = t > 0;
2766				if (n && !e) {
2767					const e = p() ? "paddingLeft" : "paddingRight";
2768					this._element.style[e] = `${t}px`
2769				}
2770				if (!n && e) {
2771					const e = p() ? "paddingRight" : "paddingLeft";
2772					this._element.style[e] = `${t}px`
2773				}
2774			}
2775			_resetAdjustments() {
2776				this._element.style.paddingLeft = "", this._element.style.paddingRight = ""
2777			}
2778			static jQueryInterface(e, t) {
2779				return this.each((function() {
2780					const n = xi.getOrCreateInstance(this, e);
2781					if ("string" == typeof e) {
vendor: 5,212 bytes, lines 2782-2946
2782						if (void 0 === n[e]) throw new TypeError(`No method named "${e}"`);
2783						n[e](t)
2784					}
2785				}))
2786			}
2787		}
2788		$.on(document, wi, '[data-bs-toggle="modal"]', (function(e) {
2789			const t = B.getElementFromSelector(this);
2790			["A", "AREA"].includes(this.tagName) && e.preventDefault(), $.one(t, mi, (e => {
2791				e.defaultPrevented || $.one(t, pi, (() => {
2792					a(this) && this.focus()
2793				}))
2794			}));
2795			const n = B.findOne(".modal.show");
2796			n && xi.getInstance(n).hide();
2797			xi.getOrCreateInstance(t).toggle(this)
2798		})), W(xi), m(xi);
2799		const Oi = ".bs.offcanvas",
2800			Li = ".data-api",
2801			ki = `load${Oi}${Li}`,
2802			Di = "show",
2803			Ii = "showing",
2804			Mi = "hiding",
2805			$i = ".offcanvas.show",
2806			Pi = `show${Oi}`,
2807			Ni = `shown${Oi}`,
2808			ji = `hide${Oi}`,
2809			qi = `hidePrevented${Oi}`,
2810			Fi = `hidden${Oi}`,
2811			Hi = `resize${Oi}`,
2812			Ri = `click${Oi}${Li}`,
2813			Bi = `keydown.dismiss${Oi}`,
2814			Wi = {
2815				backdrop: !0,
2816				keyboard: !0,
2817				scroll: !1
2818			},
2819			zi = {
2820				backdrop: "(boolean|string)",
2821				keyboard: "boolean",
2822				scroll: "boolean"
2823			};
2824		class Vi extends H {
2825			constructor(e, t) {
2826				super(e, t), this._isShown = !1, this._backdrop = this._initializeBackDrop(), this._focustrap = this._initializeFocusTrap(), this._addEventListeners()
2827			}
2828			static get Default() {
2829				return Wi
2830			}
2831			static get DefaultType() {
2832				return zi
2833			}
2834			static get NAME() {
2835				return "offcanvas"
2836			}
2837			toggle(e) {
2838				return this._isShown ? this.hide() : this.show(e)
2839			}
2840			show(e) {
2841				if (this._isShown) return;
2842				if ($.trigger(this._element, Pi, {
2843						relatedTarget: e
2844					}).defaultPrevented) return;
2845				this._isShown = !0, this._backdrop.show(), this._config.scroll || (new ui).hide(), this._element.setAttribute("aria-modal", !0), this._element.setAttribute("role", "dialog"), this._element.classList.add(Ii);
2846				this._queueCallback((() => {
2847					this._config.scroll && !this._config.backdrop || this._focustrap.activate(), this._element.classList.add(Di), this._element.classList.remove(Ii), $.trigger(this._element, Ni, {
2848						relatedTarget: e
2849					})
2850				}), this._element, !0)
2851			}
2852			hide() {
2853				if (!this._isShown) return;
2854				if ($.trigger(this._element, ji).defaultPrevented) return;
2855				this._focustrap.deactivate(), this._element.blur(), this._isShown = !1, this._element.classList.add(Mi), this._backdrop.hide();
2856				this._queueCallback((() => {
2857					this._element.classList.remove(Di, Mi), this._element.removeAttribute("aria-modal"), this._element.removeAttribute("role"), this._config.scroll || (new ui).reset(), $.trigger(this._element, Fi)
2858				}), this._element, !0)
2859			}
2860			dispose() {
2861				this._backdrop.dispose(), this._focustrap.deactivate(), super.dispose()
2862			}
2863			_initializeBackDrop() {
2864				const e = Boolean(this._config.backdrop);
2865				return new Gn({
2866					className: "offcanvas-backdrop",
2867					isVisible: e,
2868					isAnimated: !0,
2869					rootElement: this._element.parentNode,
2870					clickCallback: e ? () => {
2871						"static" !== this._config.backdrop ? this.hide() : $.trigger(this._element, qi)
2872					} : null
2873				})
2874			}
2875			_initializeFocusTrap() {
2876				return new oi({
2877					trapElement: this._element
2878				})
2879			}
2880			_addEventListeners() {
2881				$.on(this._element, Bi, (e => {
2882					"Escape" === e.key && (this._config.keyboard ? this.hide() : $.trigger(this._element, qi))
2883				}))
2884			}
2885			static jQueryInterface(e) {
2886				return this.each((function() {
2887					const t = Vi.getOrCreateInstance(this, e);
2888					if ("string" == typeof e) {
2889						if (void 0 === t[e] || e.startsWith("_") || "constructor" === e) throw new TypeError(`No method named "${e}"`);
2890						t[e](this)
2891					}
2892				}))
2893			}
2894		}
2895		$.on(document, Ri, '[data-bs-toggle="offcanvas"]', (function(e) {
2896			const t = B.getElementFromSelector(this);
2897			if (["A", "AREA"].includes(this.tagName) && e.preventDefault(), l(this)) return;
2898			$.one(t, Fi, (() => {
2899				a(this) && this.focus()
2900			}));
2901			const n = B.findOne($i);
2902			n && n !== t && Vi.getInstance(n).hide();
2903			Vi.getOrCreateInstance(t).toggle(this)
2904		})), $.on(window, ki, (() => {
2905			for (const e of B.find($i)) Vi.getOrCreateInstance(e).show()
2906		})), $.on(window, Hi, (() => {
2907			for (const e of B.find("[aria-modal][class*=show][class*=offcanvas-]")) "fixed" !== getComputedStyle(e).position && Vi.getOrCreateInstance(e).hide()
2908		})), W(Vi), m(Vi);
2909		const Ui = {
2910				"*": ["class", "dir", "id", "lang", "role", /^aria-[\w-]*$/i],
2911				a: ["target", "href", "title", "rel"],
2912				area: [],
2913				b: [],
2914				br: [],
2915				col: [],
2916				code: [],
2917				div: [],
2918				em: [],
2919				hr: [],
2920				h1: [],
2921				h2: [],
2922				h3: [],
2923				h4: [],
2924				h5: [],
2925				h6: [],
2926				i: [],
2927				img: ["src", "srcset", "alt", "title", "width", "height"],
2928				li: [],
2929				ol: [],
2930				p: [],
2931				pre: [],
2932				s: [],
2933				small: [],
2934				span: [],
2935				sub: [],
2936				sup: [],
2937				strong: [],
2938				u: [],
2939				ul: []
2940			},
2941			Qi = new Set(["background", "cite", "href", "itemtype", "longdesc", "poster", "src", "xlink:href"]),
2942			Ki = /^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,
2943			Yi = (e, t) => {
2944				const n = e.nodeName.toLowerCase();
2945				return t.includes(n) ? !Qi.has(n) || Boolean(Ki.test(e.nodeValue)) : t.filter((e => e instanceof RegExp)).some((e => e.test(n)))
2946			};
vendor: 9,495 bytes, lines 2947-3221
2947		const Xi = {
2948				allowList: Ui,
2949				content: {},
2950				extraClass: "",
2951				html: !1,
2952				sanitize: !0,
2953				sanitizeFn: null,
2954				template: "<div></div>"
2955			},
2956			Ji = {
2957				allowList: "object",
2958				content: "object",
2959				extraClass: "(string|function)",
2960				html: "boolean",
2961				sanitize: "boolean",
2962				sanitizeFn: "(null|function)",
2963				template: "string"
2964			},
2965			Gi = {
2966				entry: "(string|element|function|null)",
2967				selector: "(string|element)"
2968			};
2969		class Zi extends F {
2970			constructor(e) {
2971				super(), this._config = this._getConfig(e)
2972			}
2973			static get Default() {
2974				return Xi
2975			}
2976			static get DefaultType() {
2977				return Ji
2978			}
2979			static get NAME() {
2980				return "TemplateFactory"
2981			}
2982			getContent() {
2983				return Object.values(this._config.content).map((e => this._resolvePossibleFunction(e))).filter(Boolean)
2984			}
2985			hasContent() {
2986				return this.getContent().length > 0
2987			}
2988			changeContent(e) {
2989				return this._checkContent(e), this._config.content = {
2990					...this._config.content,
2991					...e
2992				}, this
2993			}
2994			toHtml() {
2995				const e = document.createElement("div");
2996				e.innerHTML = this._maybeSanitize(this._config.template);
2997				for (const [t, n] of Object.entries(this._config.content)) this._setContent(e, n, t);
2998				const t = e.children[0],
2999					n = this._resolvePossibleFunction(this._config.extraClass);
3000				return n && t.classList.add(...n.split(" ")), t
3001			}
3002			_typeCheckConfig(e) {
3003				super._typeCheckConfig(e), this._checkContent(e.content)
3004			}
3005			_checkContent(e) {
3006				for (const [t, n] of Object.entries(e)) super._typeCheckConfig({
3007					selector: t,
3008					entry: n
3009				}, Gi)
3010			}
3011			_setContent(e, t, n) {
3012				const i = B.findOne(n, e);
3013				i && ((t = this._resolvePossibleFunction(t)) ? o(t) ? this._putElementInTemplate(r(t), i) : this._config.html ? i.innerHTML = this._maybeSanitize(t) : i.textContent = t : i.remove())
3014			}
3015			_maybeSanitize(e) {
3016				return this._config.sanitize ? function(e, t, n) {
3017					if (!e.length) return e;
3018					if (n && "function" == typeof n) return n(e);
3019					const i = (new window.DOMParser).parseFromString(e, "text/html"),
3020						s = [].concat(...i.body.querySelectorAll("*"));
3021					for (const e of s) {
3022						const n = e.nodeName.toLowerCase();
3023						if (!Object.keys(t).includes(n)) {
3024							e.remove();
3025							continue
3026						}
3027						const i = [].concat(...e.attributes),
3028							s = [].concat(t["*"] || [], t[n] || []);
3029						for (const t of i) Yi(t, s) || e.removeAttribute(t.nodeName)
3030					}
3031					return i.body.innerHTML
3032				}(e, this._config.allowList, this._config.sanitizeFn) : e
3033			}
3034			_resolvePossibleFunction(e) {
3035				return g(e, [this])
3036			}
3037			_putElementInTemplate(e, t) {
3038				if (this._config.html) return t.innerHTML = "", void t.append(e);
3039				t.textContent = e.textContent
3040			}
3041		}
3042		const es = new Set(["sanitize", "allowList", "sanitizeFn"]),
3043			ts = "fade",
3044			ns = "show",
3045			is = ".modal",
3046			ss = "hide.bs.modal",
3047			os = "hover",
3048			rs = "focus",
3049			as = {
3050				AUTO: "auto",
3051				TOP: "top",
3052				RIGHT: p() ? "left" : "right",
3053				BOTTOM: "bottom",
3054				LEFT: p() ? "right" : "left"
3055			},
3056			ls = {
3057				allowList: Ui,
3058				animation: !0,
3059				boundary: "clippingParents",
3060				container: !1,
3061				customClass: "",
3062				delay: 0,
3063				fallbackPlacements: ["top", "right", "bottom", "left"],
3064				html: !1,
3065				offset: [0, 6],
3066				placement: "top",
3067				popperConfig: null,
3068				sanitize: !0,
3069				sanitizeFn: null,
3070				selector: !1,
3071				template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
3072				title: "",
3073				trigger: "hover focus"
3074			},
3075			cs = {
3076				allowList: "object",
3077				animation: "boolean",
3078				boundary: "(string|element)",
3079				container: "(string|element|boolean)",
3080				customClass: "(string|function)",
3081				delay: "(number|object)",
3082				fallbackPlacements: "array",
3083				html: "boolean",
3084				offset: "(array|string|function)",
3085				placement: "(string|function)",
3086				popperConfig: "(null|object|function)",
3087				sanitize: "boolean",
3088				sanitizeFn: "(null|function)",
3089				selector: "(string|boolean)",
3090				template: "string",
3091				title: "(string|element|function)",
3092				trigger: "string"
3093			};
3094		class us extends H {
3095			constructor(e, t) {
3096				if (void 0 === wn) throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");
3097				super(e, t), this._isEnabled = !0, this._timeout = 0, this._isHovered = null, this._activeTrigger = {}, this._popper = null, this._templateFactory = null, this._newContent = null, this.tip = null, this._setListeners(), this._config.selector || this._fixTitle()
3098			}
3099			static get Default() {
3100				return ls
3101			}
3102			static get DefaultType() {
3103				return cs
3104			}
3105			static get NAME() {
3106				return "tooltip"
3107			}
3108			enable() {
3109				this._isEnabled = !0
3110			}
3111			disable() {
3112				this._isEnabled = !1
3113			}
3114			toggleEnabled() {
3115				this._isEnabled = !this._isEnabled
3116			}
3117			toggle() {
3118				this._isEnabled && (this._activeTrigger.click = !this._activeTrigger.click, this._isShown() ? this._leave() : this._enter())
3119			}
3120			dispose() {
3121				clearTimeout(this._timeout), $.off(this._element.closest(is), ss, this._hideModalHandler), this._element.getAttribute("data-bs-original-title") && this._element.setAttribute("title", this._element.getAttribute("data-bs-original-title")), this._disposePopper(), super.dispose()
3122			}
3123			show() {
3124				if ("none" === this._element.style.display) throw new Error("Please use show on visible elements");
3125				if (!this._isWithContent() || !this._isEnabled) return;
3126				const e = $.trigger(this._element, this.constructor.eventName("show")),
3127					t = (c(this._element) || this._element.ownerDocument.documentElement).contains(this._element);
3128				if (e.defaultPrevented || !t) return;
3129				this._disposePopper();
3130				const n = this._getTipElement();
3131				this._element.setAttribute("aria-describedby", n.getAttribute("id"));
3132				const {
3133					container: i
3134				} = this._config;
3135				if (this._element.ownerDocument.documentElement.contains(this.tip) || (i.append(n), $.trigger(this._element, this.constructor.eventName("inserted"))), this._popper = this._createPopper(n), n.classList.add(ns), "ontouchstart" in document.documentElement)
3136					for (const e of [].concat(...document.body.children)) $.on(e, "mouseover", u);
3137				this._queueCallback((() => {
3138					$.trigger(this._element, this.constructor.eventName("shown")), !1 === this._isHovered && this._leave(), this._isHovered = !1
3139				}), this.tip, this._isAnimated())
3140			}
3141			hide() {
3142				if (!this._isShown()) return;
3143				if ($.trigger(this._element, this.constructor.eventName("hide")).defaultPrevented) return;
3144				if (this._getTipElement().classList.remove(ns), "ontouchstart" in document.documentElement)
3145					for (const e of [].concat(...document.body.children)) $.off(e, "mouseover", u);
3146				this._activeTrigger.click = !1, this._activeTrigger[rs] = !1, this._activeTrigger[os] = !1, this._isHovered = null;
3147				this._queueCallback((() => {
3148					this._isWithActiveTrigger() || (this._isHovered || this._disposePopper(), this._element.removeAttribute("aria-describedby"), $.trigger(this._element, this.constructor.eventName("hidden")))
3149				}), this.tip, this._isAnimated())
3150			}
3151			update() {
3152				this._popper && this._popper.update()
3153			}
3154			_isWithContent() {
3155				return Boolean(this._getTitle())
3156			}
3157			_getTipElement() {
3158				return this.tip || (this.tip = this._createTipElement(this._newContent || this._getContentForTemplate())), this.tip
3159			}
3160			_createTipElement(e) {
3161				const t = this._getTemplateFactory(e).toHtml();
3162				if (!t) return null;
3163				t.classList.remove(ts, ns), t.classList.add(`bs-${this.constructor.NAME}-auto`);
3164				const n = (e => {
3165					do {
3166						e += Math.floor(1e6 * Math.random())
3167					} while (document.getElementById(e));
3168					return e
3169				})(this.constructor.NAME).toString();
3170				return t.setAttribute("id", n), this._isAnimated() && t.classList.add(ts), t
3171			}
3172			setContent(e) {
3173				this._newContent = e, this._isShown() && (this._disposePopper(), this.show())
3174			}
3175			_getTemplateFactory(e) {
3176				return this._templateFactory ? this._templateFactory.changeContent(e) : this._templateFactory = new Zi({
3177					...this._config,
3178					content: e,
3179					extraClass: this._resolvePossibleFunction(this._config.customClass)
3180				}), this._templateFactory
3181			}
3182			_getContentForTemplate() {
3183				return {
3184					".tooltip-inner": this._getTitle()
3185				}
3186			}
3187			_getTitle() {
3188				return this._resolvePossibleFunction(this._config.title) || this._element.getAttribute("data-bs-original-title")
3189			}
3190			_initializeOnDelegatedTarget(e) {
3191				return this.constructor.getOrCreateInstance(e.delegateTarget, this._getDelegateConfig())
3192			}
3193			_isAnimated() {
3194				return this._config.animation || this.tip && this.tip.classList.contains(ts)
3195			}
3196			_isShown() {
3197				return this.tip && this.tip.classList.contains(ns)
3198			}
3199			_createPopper(e) {
3200				const t = g(this._config.placement, [this, e, this._element]),
3201					n = as[t.toUpperCase()];
3202				return yn(this._element, e, this._getPopperConfig(n))
3203			}
3204			_getOffset() {
3205				const {
3206					offset: e
3207				} = this._config;
3208				return "string" == typeof e ? e.split(",").map((e => Number.parseInt(e, 10))) : "function" == typeof e ? t => e(t, this._element) : e
3209			}
3210			_resolvePossibleFunction(e) {
3211				return g(e, [this._element])
3212			}
3213			_getPopperConfig(e) {
3214				const t = {
3215					placement: e,
3216					modifiers: [{
3217						name: "flip",
3218						options: {
3219							fallbackPlacements: this._config.fallbackPlacements
3220						}
3221					}, {
vendor: 12,829 bytes, lines 3222-3587
3222						name: "offset",
3223						options: {
3224							offset: this._getOffset()
3225						}
3226					}, {
3227						name: "preventOverflow",
3228						options: {
3229							boundary: this._config.boundary
3230						}
3231					}, {
3232						name: "arrow",
3233						options: {
3234							element: `.${this.constructor.NAME}-arrow`
3235						}
3236					}, {
3237						name: "preSetPlacement",
3238						enabled: !0,
3239						phase: "beforeMain",
3240						fn: e => {
3241							this._getTipElement().setAttribute("data-popper-placement", e.state.placement)
3242						}
3243					}]
3244				};
3245				return {
3246					...t,
3247					...g(this._config.popperConfig, [t])
3248				}
3249			}
3250			_setListeners() {
3251				const e = this._config.trigger.split(" ");
3252				for (const t of e)
3253					if ("click" === t) $.on(this._element, this.constructor.eventName("click"), this._config.selector, (e => {
3254						this._initializeOnDelegatedTarget(e).toggle()
3255					}));
3256					else if ("manual" !== t) {
3257					const e = t === os ? this.constructor.eventName("mouseenter") : this.constructor.eventName("focusin"),
3258						n = t === os ? this.constructor.eventName("mouseleave") : this.constructor.eventName("focusout");
3259					$.on(this._element, e, this._config.selector, (e => {
3260						const t = this._initializeOnDelegatedTarget(e);
3261						t._activeTrigger["focusin" === e.type ? rs : os] = !0, t._enter()
3262					})), $.on(this._element, n, this._config.selector, (e => {
3263						const t = this._initializeOnDelegatedTarget(e);
3264						t._activeTrigger["focusout" === e.type ? rs : os] = t._element.contains(e.relatedTarget), t._leave()
3265					}))
3266				}
3267				this._hideModalHandler = () => {
3268					this._element && this.hide()
3269				}, $.on(this._element.closest(is), ss, this._hideModalHandler)
3270			}
3271			_fixTitle() {
3272				const e = this._element.getAttribute("title");
3273				e && (this._element.getAttribute("aria-label") || this._element.textContent.trim() || this._element.setAttribute("aria-label", e), this._element.setAttribute("data-bs-original-title", e), this._element.removeAttribute("title"))
3274			}
3275			_enter() {
3276				this._isShown() || this._isHovered ? this._isHovered = !0 : (this._isHovered = !0, this._setTimeout((() => {
3277					this._isHovered && this.show()
3278				}), this._config.delay.show))
3279			}
3280			_leave() {
3281				this._isWithActiveTrigger() || (this._isHovered = !1, this._setTimeout((() => {
3282					this._isHovered || this.hide()
3283				}), this._config.delay.hide))
3284			}
3285			_setTimeout(e, t) {
3286				clearTimeout(this._timeout), this._timeout = setTimeout(e, t)
3287			}
3288			_isWithActiveTrigger() {
3289				return Object.values(this._activeTrigger).includes(!0)
3290			}
3291			_getConfig(e) {
3292				const t = q.getDataAttributes(this._element);
3293				for (const e of Object.keys(t)) es.has(e) && delete t[e];
3294				return e = {
3295					...t,
3296					..."object" == typeof e && e ? e : {}
3297				}, e = this._mergeConfigObj(e), e = this._configAfterMerge(e), this._typeCheckConfig(e), e
3298			}
3299			_configAfterMerge(e) {
3300				return e.container = !1 === e.container ? document.body : r(e.container), "number" == typeof e.delay && (e.delay = {
3301					show: e.delay,
3302					hide: e.delay
3303				}), "number" == typeof e.title && (e.title = e.title.toString()), "number" == typeof e.content && (e.content = e.content.toString()), e
3304			}
3305			_getDelegateConfig() {
3306				const e = {};
3307				for (const [t, n] of Object.entries(this._config)) this.constructor.Default[t] !== n && (e[t] = n);
3308				return e.selector = !1, e.trigger = "manual", e
3309			}
3310			_disposePopper() {
3311				this._popper && (this._popper.destroy(), this._popper = null), this.tip && (this.tip.remove(), this.tip = null)
3312			}
3313			static jQueryInterface(e) {
3314				return this.each((function() {
3315					const t = us.getOrCreateInstance(this, e);
3316					if ("string" == typeof e) {
3317						if (void 0 === t[e]) throw new TypeError(`No method named "${e}"`);
3318						t[e]()
3319					}
3320				}))
3321			}
3322		}
3323		m(us);
3324		const ds = {
3325				...us.Default,
3326				content: "",
3327				offset: [0, 8],
3328				placement: "right",
3329				template: '<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',
3330				trigger: "click"
3331			},
3332			hs = {
3333				...us.DefaultType,
3334				content: "(null|string|element|function)"
3335			};
3336		class fs extends us {
3337			static get Default() {
3338				return ds
3339			}
3340			static get DefaultType() {
3341				return hs
3342			}
3343			static get NAME() {
3344				return "popover"
3345			}
3346			_isWithContent() {
3347				return this._getTitle() || this._getContent()
3348			}
3349			_getContentForTemplate() {
3350				return {
3351					".popover-header": this._getTitle(),
3352					".popover-body": this._getContent()
3353				}
3354			}
3355			_getContent() {
3356				return this._resolvePossibleFunction(this._config.content)
3357			}
3358			static jQueryInterface(e) {
3359				return this.each((function() {
3360					const t = fs.getOrCreateInstance(this, e);
3361					if ("string" == typeof e) {
3362						if (void 0 === t[e]) throw new TypeError(`No method named "${e}"`);
3363						t[e]()
3364					}
3365				}))
3366			}
3367		}
3368		m(fs);
3369		const ps = ".bs.scrollspy",
3370			ms = `activate${ps}`,
3371			gs = `click${ps}`,
3372			_s = `load${ps}.data-api`,
3373			vs = "active",
3374			bs = "[href]",
3375			ys = ".nav-link",
3376			ws = `${ys}, .nav-item > ${ys}, .list-group-item`,
3377			Es = {
3378				offset: null,
3379				rootMargin: "0px 0px -25%",
3380				smoothScroll: !1,
3381				target: null,
3382				threshold: [.1, .5, 1]
3383			},
3384			As = {
3385				offset: "(number|null)",
3386				rootMargin: "string",
3387				smoothScroll: "boolean",
3388				target: "element",
3389				threshold: "array"
3390			};
3391		class Ts extends H {
3392			constructor(e, t) {
3393				super(e, t), this._targetLinks = new Map, this._observableSections = new Map, this._rootElement = "visible" === getComputedStyle(this._element).overflowY ? null : this._element, this._activeTarget = null, this._observer = null, this._previousScrollData = {
3394					visibleEntryTop: 0,
3395					parentScrollTop: 0
3396				}, this.refresh()
3397			}
3398			static get Default() {
3399				return Es
3400			}
3401			static get DefaultType() {
3402				return As
3403			}
3404			static get NAME() {
3405				return "scrollspy"
3406			}
3407			refresh() {
3408				this._initializeTargetsAndObservables(), this._maybeEnableSmoothScroll(), this._observer ? this._observer.disconnect() : this._observer = this._getNewObserver();
3409				for (const e of this._observableSections.values()) this._observer.observe(e)
3410			}
3411			dispose() {
3412				this._observer.disconnect(), super.dispose()
3413			}
3414			_configAfterMerge(e) {
3415				return e.target = r(e.target) || document.body, e.rootMargin = e.offset ? `${e.offset}px 0px -30%` : e.rootMargin, "string" == typeof e.threshold && (e.threshold = e.threshold.split(",").map((e => Number.parseFloat(e)))), e
3416			}
3417			_maybeEnableSmoothScroll() {
3418				this._config.smoothScroll && ($.off(this._config.target, gs), $.on(this._config.target, gs, bs, (e => {
3419					const t = this._observableSections.get(e.target.hash);
3420					if (t) {
3421						e.preventDefault();
3422						const n = this._rootElement || window,
3423							i = t.offsetTop - this._element.offsetTop;
3424						if (n.scrollTo) return void n.scrollTo({
3425							top: i,
3426							behavior: "smooth"
3427						});
3428						n.scrollTop = i
3429					}
3430				})))
3431			}
3432			_getNewObserver() {
3433				const e = {
3434					root: this._rootElement,
3435					threshold: this._config.threshold,
3436					rootMargin: this._config.rootMargin
3437				};
3438				return new IntersectionObserver((e => this._observerCallback(e)), e)
3439			}
3440			_observerCallback(e) {
3441				const t = e => this._targetLinks.get(`#${e.target.id}`),
3442					n = e => {
3443						this._previousScrollData.visibleEntryTop = e.target.offsetTop, this._process(t(e))
3444					},
3445					i = (this._rootElement || document.documentElement).scrollTop,
3446					s = i >= this._previousScrollData.parentScrollTop;
3447				this._previousScrollData.parentScrollTop = i;
3448				for (const o of e) {
3449					if (!o.isIntersecting) {
3450						this._activeTarget = null, this._clearActiveClass(t(o));
3451						continue
3452					}
3453					const e = o.target.offsetTop >= this._previousScrollData.visibleEntryTop;
3454					if (s && e) {
3455						if (n(o), !i) return
3456					} else s || e || n(o)
3457				}
3458			}
3459			_initializeTargetsAndObservables() {
3460				this._targetLinks = new Map, this._observableSections = new Map;
3461				const e = B.find(bs, this._config.target);
3462				for (const t of e) {
3463					if (!t.hash || l(t)) continue;
3464					const e = B.findOne(decodeURI(t.hash), this._element);
3465					a(e) && (this._targetLinks.set(decodeURI(t.hash), t), this._observableSections.set(t.hash, e))
3466				}
3467			}
3468			_process(e) {
3469				this._activeTarget !== e && (this._clearActiveClass(this._config.target), this._activeTarget = e, e.classList.add(vs), this._activateParents(e), $.trigger(this._element, ms, {
3470					relatedTarget: e
3471				}))
3472			}
3473			_activateParents(e) {
3474				if (e.classList.contains("dropdown-item")) B.findOne(".dropdown-toggle", e.closest(".dropdown")).classList.add(vs);
3475				else
3476					for (const t of B.parents(e, ".nav, .list-group"))
3477						for (const e of B.prev(t, ws)) e.classList.add(vs)
3478			}
3479			_clearActiveClass(e) {
3480				e.classList.remove(vs);
3481				const t = B.find(`${bs}.${vs}`, e);
3482				for (const e of t) e.classList.remove(vs)
3483			}
3484			static jQueryInterface(e) {
3485				return this.each((function() {
3486					const t = Ts.getOrCreateInstance(this, e);
3487					if ("string" == typeof e) {
3488						if (void 0 === t[e] || e.startsWith("_") || "constructor" === e) throw new TypeError(`No method named "${e}"`);
3489						t[e]()
3490					}
3491				}))
3492			}
3493		}
3494		$.on(window, _s, (() => {
3495			for (const e of B.find('[data-bs-spy="scroll"]')) Ts.getOrCreateInstance(e)
3496		})), m(Ts);
3497		const Cs = ".bs.tab",
3498			Ss = `hide${Cs}`,
3499			xs = `hidden${Cs}`,
3500			Os = `show${Cs}`,
3501			Ls = `shown${Cs}`,
3502			ks = `click${Cs}`,
3503			Ds = `keydown${Cs}`,
3504			Is = `load${Cs}`,
3505			Ms = "ArrowLeft",
3506			$s = "ArrowRight",
3507			Ps = "ArrowUp",
3508			Ns = "ArrowDown",
3509			js = "Home",
3510			qs = "End",
3511			Fs = "active",
3512			Hs = "fade",
3513			Rs = "show",
3514			Bs = ".dropdown-toggle",
3515			Ws = `:not(${Bs})`,
3516			zs = '[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',
3517			Vs = `${`.nav-link${Ws}, .list-group-item${Ws}, [role="tab"]${Ws}`}, ${zs}`,
3518			Us = `.${Fs}[data-bs-toggle="tab"], .${Fs}[data-bs-toggle="pill"], .${Fs}[data-bs-toggle="list"]`;
3519		class Qs extends H {
3520			constructor(e) {
3521				super(e), this._parent = this._element.closest('.list-group, .nav, [role="tablist"]'), this._parent && (this._setInitialAttributes(this._parent, this._getChildren()), $.on(this._element, Ds, (e => this._keydown(e))))
3522			}
3523			static get NAME() {
3524				return "tab"
3525			}
3526			show() {
3527				const e = this._element;
3528				if (this._elemIsActive(e)) return;
3529				const t = this._getActiveElem(),
3530					n = t ? $.trigger(t, Ss, {
3531						relatedTarget: e
3532					}) : null;
3533				$.trigger(e, Os, {
3534					relatedTarget: t
3535				}).defaultPrevented || n && n.defaultPrevented || (this._deactivate(t, e), this._activate(e, t))
3536			}
3537			_activate(e, t) {
3538				if (!e) return;
3539				e.classList.add(Fs), this._activate(B.getElementFromSelector(e));
3540				this._queueCallback((() => {
3541					"tab" === e.getAttribute("role") ? (e.removeAttribute("tabindex"), e.setAttribute("aria-selected", !0), this._toggleDropDown(e, !0), $.trigger(e, Ls, {
3542						relatedTarget: t
3543					})) : e.classList.add(Rs)
3544				}), e, e.classList.contains(Hs))
3545			}
3546			_deactivate(e, t) {
3547				if (!e) return;
3548				e.classList.remove(Fs), e.blur(), this._deactivate(B.getElementFromSelector(e));
3549				this._queueCallback((() => {
3550					"tab" === e.getAttribute("role") ? (e.setAttribute("aria-selected", !1), e.setAttribute("tabindex", "-1"), this._toggleDropDown(e, !1), $.trigger(e, xs, {
3551						relatedTarget: t
3552					})) : e.classList.remove(Rs)
3553				}), e, e.classList.contains(Hs))
3554			}
3555			_keydown(e) {
3556				if (![Ms, $s, Ps, Ns, js, qs].includes(e.key)) return;
3557				e.stopPropagation(), e.preventDefault();
3558				const t = this._getChildren().filter((e => !l(e)));
3559				let n;
3560				if ([js, qs].includes(e.key)) n = t[e.key === js ? 0 : t.length - 1];
3561				else {
3562					const i = [$s, Ns].includes(e.key);
3563					n = v(t, e.target, i, !0)
3564				}
3565				n && (n.focus({
3566					preventScroll: !0
3567				}), Qs.getOrCreateInstance(n).show())
3568			}
3569			_getChildren() {
3570				return B.find(Vs, this._parent)
3571			}
3572			_getActiveElem() {
3573				return this._getChildren().find((e => this._elemIsActive(e))) || null
3574			}
3575			_setInitialAttributes(e, t) {
3576				this._setAttributeIfNotExists(e, "role", "tablist");
3577				for (const e of t) this._setInitialAttributesOnChild(e)
3578			}
3579			_setInitialAttributesOnChild(e) {
3580				e = this._getInnerElement(e);
3581				const t = this._elemIsActive(e),
3582					n = this._getOuterElement(e);
3583				e.setAttribute("aria-selected", t), n !== e && this._setAttributeIfNotExists(n, "role", "presentation"), t || e.setAttribute("tabindex", "-1"), this._setAttributeIfNotExists(e, "role", "tab"), this._setInitialAttributesOnTargetPanel(e)
3584			}
3585			_setInitialAttributesOnTargetPanel(e) {
3586				const t = B.getElementFromSelector(e);
3587				t && (this._setAttributeIfNotExists(t, "role", "tabpanel"), e.id && this._setAttributeIfNotExists(t, "aria-labelledby", `${e.
3587id}`))
3588			}
3589			_toggleDropDown(e, t) {
3590				const n = this._getOuterElement(e);
3591				if (!n.classList.contains("dropdown")) return;
3592				const i = (e, i) => {
3593					const s = B.findOne(e, n);
3594					s && s.classList.toggle(i, t)
3595				};
3596				i(Bs, Fs), i(".dropdown-menu", Rs), n.setAttribute("aria-expanded", t)
3597			}
3598			_setAttributeIfNotExists(e, t, n) {
3599				e.hasAttribute(t) || e.setAttribute(t, n)
3600			}
3601			_elemIsActive(e) {
3602				return e.classList.contains(Fs)
3603			}
3604			_getInnerElement(e) {
3605				return e.matches(Vs) ? e : B.findOne(Vs, e)
3606			}
3607			_getOuterElement(e) {
3608				return e.closest(".nav-item, .list-group-item") || e
3609			}
3610			static jQueryInterface(e) {
3611				return this.each((function() {
3612					const t = Qs.getOrCreateInstance(this);
3613					if ("string" == typeof e) {
3614						if (void 0 === t[e] || e.startsWith("_") || "constructor" === e) throw new TypeError(`No method named "${e}"`);
3615						t[e]()
3616					}
3617				}))
3618			}
3619		}
3620		$.on(document, ks, zs, (function(e) {
3621			["A", "AREA"].includes(this.tagName) && e.preventDefault(), l(this) || Qs.getOrCreateInstance(this).show()
3622		})), $.on(window, Is, (() => {
3623			for (const e of B.find(Us)) Qs.getOrCreateInstance(e)
3624		})), m(Qs);
3625		const Ks = ".bs.toast",
3626			Ys = `mouseover${Ks}`,
3627			Xs = `mouseout${Ks}`,
3628			Js = `focusin${Ks}`,
3629			Gs = `focusout${Ks}`,
3630			Zs = `hide${Ks}`,
3631			eo = `hidden${Ks}`,
3632			to = `show${Ks}`,
3633			no = `shown${Ks}`,
3634			io = "hide",
3635			so = "show",
3636			oo = "showing",
3637			ro = {
3638				animation: "boolean",
3639				autohide: "boolean",
3640				delay: "number"
3641			},
3642			ao = {
3643				animation: !0,
3644				autohide: !0,
3645				delay: 5e3
3646			};
3647		class lo extends H {
3648			constructor(e, t) {
3649				super(e, t), this._timeout = null, this._hasMouseInteraction = !1, this._hasKeyboardInteraction = !1, this._setListeners()
3650			}
3651			static get Default() {
3652				return ao
3653			}
3654			static get DefaultType() {
3655				return ro
3656			}
3657			static get NAME() {
3658				return "toast"
3659			}
3660			show() {
3661				if ($.trigger(this._element, to).defaultPrevented) return;
3662				this._clearTimeout(), this._config.animation && this._element.classList.add("fade");
3663				this._element.classList.remove(io), d(this._element), this._element.classList.add(so, oo), this._queueCallback((() => {
3664					this._element.classList.remove(oo), $.trigger(this._element, no), this._maybeScheduleHide()
3665				}), this._element, this._config.animation)
3666			}
3667			hide() {
3668				if (!this.isShown()) return;
3669				if ($.trigger(this._element, Zs).defaultPrevented) return;
3670				this._element.classList.add(oo), this._queueCallback((() => {
3671					this._element.classList.add(io), this._element.classList.remove(oo, so), $.trigger(this._element, eo)
3672				}), this._element, this._config.animation)
3673			}
3674			dispose() {
3675				this._clearTimeout(), this.isShown() && this._element.classList.remove(so), super.dispose()
3676			}
3677			isShown() {
3678				return this._element.classList.contains(so)
3679			}
3680			_maybeScheduleHide() {
3681				this._config.autohide && (this._hasMouseInteraction || this._hasKeyboardInteraction || (this._timeout = setTimeout((() => {
3682					this.hide()
3683				}), this._config.delay)))
3684			}
3685			_onInteraction(e, t) {
3686				switch (e.type) {
3687					case "mouseover":
3688					case "mouseout":
3689						this._hasMouseInteraction = t;
3690						break;
3691					case "focusin":
3692					case "focusout":
3693						this._hasKeyboardInteraction = t
3694				}
3695				if (t) return void this._clearTimeout();
3696				const n = e.relatedTarget;
3697				this._element === n || this._element.contains(n) || this._maybeScheduleHide()
3698			}
3699			_setListeners() {
3700				$.on(this._element, Ys, (e => this._onInteraction(e, !0))), $.on(this._element, Xs, (e => this._onInteraction(e, !1))), $.on(this._element, Js, (e => this._onInteraction(e, !0))), $.on(this._element, Gs, (e => this._onInteraction(e, !1)))
3701			}
3702			_clearTimeout() {
3703				clearTimeout(this._timeout), this._timeout = null
3704			}
3705			static jQueryInterface(e) {
3706				return this.each((function() {
3707					const t = lo.getOrCreateInstance(this, e);
3708					if ("string" == typeof e) {
3709						if (void 0 === t[e]) throw new TypeError(`No method named "${e}"`);
3710						t[e](this)
3711					}
3712				}))
3713			}
3714		}
3715		W(lo), m(lo);
3716		return {
3717			Alert: Q,
3718			Button: Y,
3719			Carousel: xe,
3720			Collapse: Re,
3721			Dropdown: Un,
3722			Modal: xi,
3723			Offcanvas: Vi,
3724			Popover: fs,
3725			ScrollSpy: Ts,
3726			Tab: Qs,
3727			Toast: lo,
3728			Tooltip: us
3729		}
3730	})),
3731	/*!
3732	 * smooth-scroll v16.1.3
3733	 * Animate scrolling to anchor links
3734	 * (c) 2020 Chris Ferdinandi
3735	 * MIT License
3736	 * http://github.com/cferdinandi/smooth-scroll
3737	 */
3738	window.Element && !Element.prototype.closest && (Element.prototype.closest = function(e) {
3739			var t, n = (this.document || this.ownerDocument).querySelectorAll(e),
3740				i = this;
3741			do {
3742				for (t = n.length; --t >= 0 && n.item(t) !== i;);
3743			} while (t < 0 && (i = i.parentElement));
3744			return i
3745		}),
3746		function() {
3747			if ("function" == typeof window.CustomEvent) return !1;
3748
3749			function e(e, t) {
3750				t = t || {
3751					bubbles: !1,
3752					cancelable: !1,
3753					detail: void 0
3754				};
3755				var n = document.createEvent("CustomEvent");
3756				return n.initCustomEvent(e, t.bubbles, t.cancelable, t.detail), n
3757			}
3758			e.prototype = window.Event.prototype, window.CustomEvent = e
3759		}(),
3760		function() {
3761			for (var e = 0, t = ["ms", "moz", "webkit", "o"], n = 0; n < t.length && !window.requestAnimationFrame; ++n) window.requestAnimationFrame = window[t[n] + "RequestAnimationFrame"], window.cancelAnimationFrame = window[t[n] + "CancelAnimationFrame"] || window[t[n] + "CancelRequestAnimationFrame"];
3762			window.requestAnimationFrame || (window.requestAnimationFrame = function(t, n) {
3763				var i = (new Date).getTime(),
3764					s = Math.max(0, 16 - (i - e)),
3765					o = window.setTimeout((function() {
3766						t(i + s)
3767					}), s);
3768				return e = i + s, o
3769			}), window.cancelAnimationFrame || (window.cancelAnimationFrame = function(e) {
3770				clearTimeout(e)
3771			})
3772		}(), e = "undefined" != typeof global ? global : "undefined" != typeof window ? window : void 0, t = function(e) {
3773			var t = {
3774					ignore: "[data-scroll-ignore]",
3775					header: null,
3776					topOnEmptyHash: !0,
3777					speed: 500,
3778					speedAsDuration: !1,
3779					durationMax: null,
3780					durationMin: null,
3781					clip: !0,
3782					offset: 0,
3783					easing: "easeInOutCubic",
3784					customEasing: null,
3785					updateURL: !0,
3786					popstate: !0,
3787					emitEvents: !0
3788				},
3789				n = function() {
3790					var e = {};
3791					return Array.prototype.forEach.call(arguments, (function(t) {
3792						for (var n in t) {
3793							if (!t.hasOwnProperty(n)) return;
3794							e[n] = t[n]
3795						}
3796					})), e
3797				},
3798				i = function(e) {
3799					"#" === e.charAt(0) && (e = e.substr(1));
3800					for (var t, n = String(e), i = n.length, s = -1, o = "", r = n.charCodeAt(0); ++s < i;) {
3801						if (0 === (t = n.charCodeAt(s))) throw new InvalidCharacterError("Invalid character: the input contains U+0000.");
3802						o += t >= 1 && t <= 31 || 127 == t || 0 === s && t >= 48 && t <= 57 || 1 === s && t >= 48 && t <= 57 && 45 === r ? "\\" + t.toString(16) + " " : t >= 128 || 45 === t || 95 === t || t >= 48 && t <= 57 || t >= 65 && t <= 90 || t >= 97 && t <= 122 ? n.charAt(s) : "\\" + n.charAt(s)
3803					}
3804					return "#" + o
3805				},
3806				s = function() {
3807					return Math.max(document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight, document.body.clientHeight, document.documentElement.clientHeight)
3808				},
3809				o = function(t) {
3810					return t ? (n = t, parseInt(e.getComputedStyle(n).height, 10) + t.offsetTop) : 0;
3811					var n
3812				},
3813				r = function(t, n, i) {
3814					0 === t && document.body.focus(), i || (t.focus(), document.activeElement !== t && (t.setAttribute("tabindex", "-1"), t.focus(), t.style.outline = "none"), e.scrollTo(0, n))
3815				},
3816				a = function(t, n, i, s) {
3817					if (n.emitEvents && "function" == typeof e.CustomEvent) {
3818						var o = new CustomEvent(t, {
3819							bubbles: !0,
3820							detail: {
3821								anchor: i,
3822								toggle: s
3823							}
3824						});
3825						document.dispatchEvent(o)
3826					}
3827				};
3828			return function(l, c) {
3829				var u, d, h, f, p = {
3830						cancelScroll: function(e) {
3831							cancelAnimationFrame(f), f = null, e || a("scrollCancel", u)
3832						},
3833						animateScroll: function(i, l, c) {
3834							p.cancelScroll();
3835							var d = n(u || t, c || {}),
3836								m = "[object Number]" === Object.prototype.toString.call(i),
3837								g = m || !i.tagName ? null : i;
3838							if (m || g) {
3839								var _ = e.pageYOffset;
3840								d.header && !h && (h = document.querySelector(d.header));
3841								var v, b, y, w = o(h),
3842									E = m ? i : function(t, n, i, o) {
3843										var r = 0;
3844										if (t.offsetParent)
3845											do {
3846												r += t.offsetTop, t = t.offsetParent
3847											} while (t);
3848										return r = Math.max(r - n - i, 0), o && (r = Math.min(r, s() - e.innerHeight)), r
3849									}(g, w, parseInt("function" == typeof d.offset ? d.offset(i, l) : d.offset, 10), d.clip),
3850									A = E - _,
3851									T = s(),
3852									C = 0,
3853									S = function(e, t) {
3854										var n = t.speedAsDuration ? t.speed : Math.abs(e / 1e3 * t.speed);
3855										return t.durationMax && n > t.durationMax ? t.durationMax : t.durationMin && n < t.durationMin ? t.durationMin : parseInt(n, 10)
3856									}(A, d),
3857									x = function(t) {
3858										v || (v = t), C += t - v, y = _ + A * function(e, t) {
3859												var n;
3860												return "easeInQuad" === e.easing && (n = t * t), "easeOutQuad" === e.easing && (n = t * (2 - t)), "easeInOutQuad" === e.easing && (n = t < .5 ? 2 * t * t : (4 - 2 * t) * t - 1), "easeInCubic" === e.easing && (n = t * t * t), "easeOutCubic" === e.easing && (n = --t * t * t + 1), "easeInOutCubic" === e.easing && (n = t < .5 ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1), "easeInQuart" === e.easing && (n = t * t * t * t), "easeOutQuart" === e.easing && (n = 1 - --t * t * t * t), "easeInOutQuart" === e.easing && (n = t < .5 ? 8 * t * t * t * t : 1 - 8 * --t * t * t * t), "easeInQuint" === e.easing && (n = t * t * t * t * t), "easeOutQuint" === e.easing && (n = 1 + --t * t * t * t * t), "easeInOutQuint" === e.easing && (n = t < .5 ? 16 * t * t * t * t * t : 1 + 16 * --t * t * t * t * t), e.customEasing && (n = e.customEasing(t)), n || t
3861											}(d, b = (b = 0 === S ? 0 : C / S) > 1 ? 1 : b), e.scrollTo(0, Math.floor(y)),
3862											function(t, n) {
3863												var s = e.pageYOffset;
3864												if (t == n || s == n || (_ < n && e.innerHeight + s) >= T) return p.cancelScroll(!0), r(i, n, m), a("scrollStop", d, i, l), v = null, f = null, !0
3865											}(y, E) || (f = e.requestAnimationFrame(x), v = t)
3866									};
3867								0 === e.pageYOffset && e.scrollTo(0, 0),
3868									function(e, t, n) {
3869										t || history.pushState && n.updateURL && history.pushState({
3870											smoothScroll: JSON.stringify(n),
3871											anchor: e.id
3872										}, document.title, e === document.documentElement ? "#top" : "#" + e.id)
3873									}(i, m, d), "matchMedia" in e && e.matchMedia("(prefers-reduced-motion)").matches ? r(i, Math.floor(E), !1) : (a("scrollStart", d, i, l), p.cancelScroll(!0), e.requestAnimationFrame(x))
3874							}
3875						}
3876					},
3877					m = function(t) {
3878						if (!t.defaultPrevented && !(0 !== t.button || t.metaKey || t.ctrlKey || t.shiftKey) && "closest" in t.target && (d = t.target.closest(l)) && "a" === d.tagName.toLowerCase() && !t.target.closest(u.ignore) && d.hostname === e.location.hostname && d.pathname === e.location.pathname && /#/.test(d.href)) {
3879							var n, s;
3880							try {
3881								n = i(decodeURIComponent(d.hash))
3882							} catch (e) {
3883								n = i(d.hash)
3884							}
3885							if ("#" === n) {
3886								if (!u.topOnEmptyHash) return;
3887								s = document.documentElement
3888							} else s = document.querySelector(n);
3889							(s = s || "#top" !== n ? s : document.documentElement) && (t.preventDefault(), function(t) {
3890								if (history.replaceState && t.updateURL && !history.state) {
3891									var n = e.location.hash;
3892									n = n || "", history.replaceState({
3893										smoothScroll: JSON.stringify(t),
3894										anchor: n || e.pageYOffset
3895									}, document.title, n || e.location.href)
3896								}
3897							}(u), p.animateScroll(s, d))
3898						}
3899					},
3900					g = function(e) {
3901						if (null !== history.state && history.state.smoothScroll && history.state.smoothScroll === JSON.stringify(u)) {
3902							var t = history.state.anchor;
3903							"string" == typeof t && t && !(t = document.querySelector(i(history.state.anchor))) || p.animateScroll(t, null, {
3904								updateURL: !1
3905							})
3906						}
3907					};
3908				return p.destroy = function() {
3909						u && (document.removeEventListener("click", m, !1), e.removeEventListener("popstate", g, !1), p.cancelScroll(), u = null, d = null, h = null, f = null)
3910					},
3911					function() {
3912						if (!("querySelector" in document && "addEventListener" in e && "requestAnimationFrame" in e && "closest" in e.Element.prototype)) throw "Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs.";
3913						p.destroy(), u = n(t, c || {}), h = u.header ? document.querySelector(u.header) : null, document.addEventListener("click", m, !1), u.updateURL && u.popstate && e.addEventListener("popstate", g, !1)
3914					}(), p
3915			}
3916		}, "function" == typeof define && define.amd ? define([], (function() {
3917			return t(e)
3918		})) : "object" == typeof exports ? module.exports = t(e) : e.SmoothScroll = t(e), (() => {
3919			let e = document.querySelector(".navbar-sticky");
3920			if (null == e) return;
3921			let t = e.classList,
3922				n = e.offsetHeight;
3923			t.contains("position-absolute") ? window.addEventListener("scroll", (t => {
3924				t.currentTarget.pageYOffset > 500 ? e.classList.add("navbar-stuck") : e.classList.remove("navbar-stuck")
3925			})) : window.addEventListener("scroll", (t => {
3926				t.currentTarget.pageYOffset > 500 ? (document.body.style.paddingTop = n + "px", e.classList.add("navbar-stuck")) : (document.body.style.paddingTop = "", e.classList.remove("navbar-stuck"))
3927			}))
3928		})(), new SmoothScroll("[data-scroll]", {
3929			speed: 800,
3930			speedAsDuration: !0,
3931			offset: (e, t) => t.dataset.scrollOffset || 40,
3932			header: "[data-scroll-header]",
3933			updateURL: !1
3934		}), (() => {
3935			const e = document.querySelector(".btn-scroll-top");
3936			if (null == e) return;
3937			let t = parseInt(600, 10);
3938			window.addEventListener("scroll", (n => {
3939				n.currentTarget.pageYOffset > t ? e.classList.add("show") : e.classList.remove("show")
3940			}))
3941		})(), (() => {
3942			let e = document.querySelectorAll(".password-toggle");
3943			for (let t = 0; t < e.length; t++) {
3944				let n = e[t].querySelector(".form-control");
3945				e[t].querySelector(".password-toggle-btn").addEventListener("click", (e => {
3946					"checkbox" === e.target.type && (e.target.checked ? n.type = "text" : n.type = "password")
3947				}), !1)
3948			}
3949		})(), null !== document.querySelector(".rellax") && new Rellax(".rellax", {
3950			horizontal: !0
3951		}), (() => {
3952			const e = document.querySelectorAll(".parallax");
3953			for (let t = 0; t < e.length; t++) new Parallax(e[t])
3954		})(), ((e, t, n) => {
3955			for (let i = 0; i < e.length; i++) t.call(n, i, e[i])
3956		})(document.querySelectorAll(".swiper"), ((e, t) => {
3957			let n, i;
3958			null != t.dataset.swiperOptions && (n = JSON.parse(t.dataset.swiperOptions)), n.pager && (i = {
3959				pagination: {
3960					el: ".pagination .list-unstyled",
3961					clickable: !0,
3962					bulletActiveClass: "active",
3963					bulletClass: "page-item",
3964					renderBullet: function(e, t) {
3965						return '<li class="' + t + '"><a href="#" class="page-link btn-icon btn-sm">' + (e + 1) + "</a></li>"
3966					}
3967				}
3968			});
3969			const s = {
3970					...n,
3971					...i
3972				},
3973				o = new Swiper(t, s);
3974			n.tabs && o.on("activeIndexChange", (e => {
3975				let t = document.querySelector(e.slides[e.activeIndex].dataset.swiperTab);
3976				document.querySelector(e.slides[e.previousIndex].dataset.swiperTab).classList.remove("active"), t.classList.add("active")
3977			}))
3978		})), (() => {
3979			const e = document.querySelectorAll(".gallery");
3980			if (e.length)
3981				for (let t = 0; t < e.length; t++) {
3982					const n = !!e[t].dataset.thumbnails,
3983						i = !!e[t].dataset.video,
3984						s = [...[lgZoom, lgFullscreen], ...i ? [lgVideo] : [], ...n ? [lgThumbnail] : []];
3985					lightGallery(e[t], {
3986						selector: ".gallery-item",
3987						plugins: s,
3988						licenseKey: "D4194FDD-48924833-A54AECA3-D6F8E646",
3989						download: !1,
3990						autoplayVideoOnSlide: !0,
3991						zoomFromOrigin: !1,
3992						youtubePlayerParams: {
3993							modestbranding: 1,
3994							showinfo: 0,
3995							rel: 0
3996						},
3997						vimeoPlayerParams: {
3998							byline: 0,
3999							portrait: 0,
4000							color: "6366f1"
4001						}
4002					})
4003				}
4004		})(), (() => {
4005			let e = document.querySelectorAll(".range-slider");
4006			for (let t = 0; t < e.length; t++) {
4007				let n = e[t].querySelector(".range-slider-ui"),
4008					i = e[t].querySelector(".range-slider-value-min"),
4009					s = e[t].querySelector(".range-slider-value-max"),
4010					o = {
4011						dataStartMin: parseInt(e[t].dataset.startMin, 10),
4012						dataStartMax: parseInt(e[t].dataset.startMax, 10),
4013						dataMin: parseInt(e[t].dataset.min, 10),
4014						dataMax: parseInt(e[t].dataset.max, 10),
4015						dataStep: parseInt(e[t].dataset.step, 10),
4016						dataPips: e[t].dataset.pips,
4017						dataTooltips: !e[t].dataset.tooltips || "true" === e[t].dataset.tooltips,
4018						dataTooltipPrefix: e[t].dataset.tooltipPrefix || "",
4019						dataTooltipSuffix: e[t].dataset.tooltipSuffix || ""
4020					},
4021					r = o.dataStartMax ? [o.dataStartMin, o.dataStartMax] : [o.dataStartMin],
4022					a = !!o.dataStartMax || "lower";
4023				noUiSlider.create(n, {
4024					start: r,
4025					connect: a,
4026					step: o.dataStep,
4027					pips: !!o.dataPips && {
4028						mode: "count",
4029						values: 5
4030					},
4031					tooltips: o.dataTooltips,
4032					range: {
4033						min: o.dataMin,
4034						max: o.dataMax
4035					},
4036					format: {
4037						to: function(e) {
4038							return o.dataTooltipPrefix + parseInt(e, 10) + o.dataTooltipSuffix
4039						},
4040						from: function(e) {
4041							return Number(e)
4042						}
4043					}
4044				}), n.noUiSlider.on("update", ((e, t) => {
4045					let n = e[t];
4046					n = n.replace(/\D/g, ""), t ? s && (s.value = Math.round(n)) : i && (i.value = Math.round(n))
4047				})), i && i.addEventListener("change", (function() {
4048					n.noUiSlider.set([this.value, null])
4049				})), s && s.addEventListener("change", (function() {
4050					n.noUiSlider.set([null, this.value])
4051				}))
4052			}
4053		})(), window.addEventListener("load", (() => {
4054			/*
4055			const e = document.getElementsByClassName("needs-validation");
4056			Array.prototype.filter.call(e, (e => {
4057				e.addEventListener("submit", (t => {
4058					!1 === e.checkValidity() && (t.preventDefault(), t.stopPropagation()), e.classList.add("was-validated")
4059				}), !1)
4060			}))
4061			*/
4062		}), !1), (() => {
4063			const e = document.querySelectorAll("[data-format]");
4064			if (0 !== e.length)
4065				for (let t = 0; t < e.length; t++) {
4066					let n, i = e[t],
4067						s = i.parentNode.querySelector(".credit-card-icon");
4068					null != i.dataset.format && (n = JSON.parse(i.dataset.format)), s ? new Cleave(i, {
4069						...n,
4070						onCreditCardTypeChanged: e => {
4071							s.className = "credit-card-icon " + e
4072						}
4073					}) : new Cleave(i, n)
4074				}
4075		})(), [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]')).map((e => new bootstrap.Tooltip(e, {
4076			trigger: "hover"
4077		}))), [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]')).map((e => new bootstrap.Popover(e))), [].slice.call(document.querySelectorAll(".toast")).map((e => new bootstrap.Toast(e))), (() => {
4078			let e = document.querySelectorAll('[data-bs-toggle="video"]');
4079			if (e.length)
4080				for (let t = 0; t < e.length; t++) lightGallery(e[t], {
4081					selector: "this",
4082					plugins: [lgVideo],
4083					licenseKey: "D4194FDD-48924833-A54AECA3-D6F8E646",
4084					download: !1,
4085					youtubePlayerParams: {
4086						modestbranding: 1,
4087						showinfo: 0,
4088						rel: 0
4089					},
4090					vimeoPlayerParams: {
4091						byline: 0,
4092						portrait: 0,
4093						color: "6366f1"
4094					}
4095				})
4096		})(), (() => {
4097			let e = document.querySelectorAll(".price-switch-wrapper");
4098			if (!(e.length <= 0))
4099				for (let t = 0; t < e.length; t++) {
4100					e[t].querySelector('[data-bs-toggle="price"]').addEventListener("change", (e => {
4101						let t = e.currentTarget.querySelector('input[type="checkbox"]'),
4102							n = e.currentTarget.closest(".price-switch-wrapper").querySelectorAll("[data-monthly-price]"),
4103							i = e.currentTarget.closest(".price-switch-wrapper").querySelectorAll("[data-annual-price]");
4104						for (let e = 0; e < n.length; e++) 1 == t.checked ? n[e].classList.add("d-none") : n[e].classList.remove("d-none");
4105						for (let e = 0; e < n.length; e++) 1 == t.checked ? i[e].classList.remove("d-none") : i[e].classList.add("d-none")
4106					}))
4107				}
4108		})(), (() => {
4109			let e, t = document.querySelectorAll(".masonry-grid");
4110			if (null !== t)
4111				for (let n = 0; n < t.length; n++) {
4112					e = new Shuffle(t[n], {
4113						itemSelector: ".masonry-grid-item",
4114						sizer: ".masonry-grid-item"
4115					}), imagesLoaded(t[n]).on("progress", (() => {
4116						e.layout()
4117					}));
4118					let i = t[n].closest(".masonry-filterable");
4119					if (null === i) return;
4120					let s = i.querySelectorAll(".masonry-filters [data-group]");
4121					for (let t = 0; t < s.length; t++) s[t].addEventListener("click", (function(t) {
4122						let n = i.querySelector(".masonry-filters .active"),
4123							s = this.dataset.group;
4124						null !== n && n.classList.remove("active"), this.classList.add("active"), e.filter(s), t.preventDefault()
4125					}))
4126				}
4127		})(), (() => {
4128			const e = document.querySelectorAll(".subscription-form");
4129			if (null === e) return;
4130			for (let n = 0; n < e.length; n++) {
4131				/*
4132				let i = e[n].querySelector('button[type="submit"]'),
4133					s = i.innerHTML,
4134					o = e[n].querySelector(".form-control"),
4135					r = e[n].querySelector(".subscription-form-antispam"),
4136					a = e[n].querySelector(".subscription-status");
4137				e[n].addEventListener("submit", (function(e) {
4138					e && e.preventDefault(), "" === r.value && t(this, i, o, s, a)
4139				}))
4140				*/
4141			}
4142			
4143				/*
4144			let t = (e, t, n, i, s) => {
4145				t.innerHTML = "Sending...";
4146				let o = e.action.replace("/post?", "/post-json?"),
4147					r = "&" + n.name + "=" + encodeURIComponent(n.value),
4148					a = document.createElement("script");
4149				a.src = o + "&c=callback" + r, document.body.appendChild(a);
4150				let l = "callback";
4151				window[l] = e => {
4152					delete window[l], document.body.removeChild(a), t.innerHTML = i, "success" == e.result ? (n.classList.remove("is-invalid"), n.classList.add("is-valid"), s.classList.remove("status-error"), s.classList.add("status-success"), s.innerHTML = e.msg, setTimeout((() => {
4153						n.classList.remove("is-valid"), s.innerHTML = "", s.classList.remove("status-success")
4154					}), 6e3)) : (n.classList.remove("is-valid"), n.classList.add("is-invalid"), s.classList.remove("status-success"), s.classList.add("status-error"), s.innerHTML = e.msg.substring(4), setTimeout((() => {
4155						n.classList.remove("is-invalid"), s.innerHTML = "", s.classList.remove("status-error")
4156					}), 6e3))
4157				}
4158			}
4159			*/
4160		})(), document.querySelectorAll(".animation-on-hover").forEach((e => {
4161			e.addEventListener("mouseover", (() => {
4162				e.querySelectorAll("lottie-player").forEach((e => {
4163					e.setDirection(1), e.play()
4164				}))
4165			})), e.addEventListener("mouseleave", (() => {
4166				e.querySelectorAll("lottie-player").forEach((e => {
4167					e.setDirection(-1), e.play()
4168				}))
4169			}))
4170		})), (() => {
4171			const e = document.querySelectorAll(".audio-player");
4172			if (0 !== e.length)
4173				for (let t = 0; t < e.length; t++) {
4174					const n = e[t],
4175						i = n.querySelector("audio"),
4176						s = n.querySelector(".ap-play-button"),
4177						o = n.querySelector(".ap-seek-slider"),
4178						r = n.querySelector(".ap-volume-slider"),
4179						a = n.querySelector(".ap-duration"),
4180						l = n.querySelector(".ap-current-time");
4181					let c = "play",
4182						u = null;
4183					s.addEventListener("click", (e => {
4184						"play" === c ? (e.currentTarget.classList.add("ap-pause"), i.play(), requestAnimationFrame(g), c = "pause") : (e.currentTarget.classList.remove("ap-pause"), i.pause(), cancelAnimationFrame(u), c = "play")
4185					}));
4186					const d = e => {
4187						e === o ? n.style.setProperty("--seek-before-width", e.value / e.max * 100 + "%") : n.style.setProperty("--volume-before-width", e.value / e.max * 100 + "%")
4188					};
4189					o.addEventListener("input", (e => {
4190						d(e.target)
4191					})), r.addEventListener("input", (e => {
4192						d(e.target)
4193					}));
4194					const h = e => {
4195							const t = Math.floor(e / 60),
4196								n = Math.floor(e % 60);
4197							return `${t}:${n<10?`0${n}`:`${n}`}`
4198						},
4199						f = () => {
4200							a.textContent = h(i.duration)
4201						},
4202						p = () => {
4203							o.max = Math.floor(i.duration)
4204						},
4205						m = () => {
4206							if (i.buffered.length > 0) {
4207								const e = Math.floor(i.buffered.end(i.buffered.length - 1));
4208								n.style.setProperty("--buffered-width", e / o.max * 100 + "%")
4209							}
4210						},
4211						g = () => {
4212							o.value = Math.floor(i.currentTime), l.textContent = h(o.value), n.style.setProperty("--seek-before-width", o.value / o.max * 100 + "%"), u = requestAnimationFrame(g)
4213						};
4214					i.readyState > 0 ? (f(), p(), m()) : i.addEventListener("loadedmetadata", (() => {
4215						f(), p(), m()
4216					})), i.addEventListener("progress", m), o.addEventListener("input", (() => {
4217						l.textContent = h(o.value), i.paused || cancelAnimationFrame(u)
4218					})), o.addEventListener("change", (() => {
4219						i.currentTime = o.value, i.paused || requestAnimationFrame(g)
4220					})), r.addEventListener("input", (e => {
4221						const t = e.target.value;
4222						i.volume = t / 100
4223					}))
4224				}
4225		})()
4226}();
4227/* End */
4228;
4229; /* Start:"a:4:{s:4:"full";s:81:"/local/templates/CAIMAN_2025/assets/custom/js/jquery-3.5.1.min.js?174823850689476";s:6:"source";s:65:"/local/templates/CAIMAN_2025/assets/custom/js/jquery-3.5.1.min.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
vendor: 15,088 bytes, lines 4230-4231
4230/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */
4231!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(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}S.fn=S.prototype={jquery:f,constructor:S,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=S.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return S.each(this,e)},map:function(n){return this.pushStack(S.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,function(e,t){return(t+1)%2}))},odd:function(){return this.pushStack(S.grep(this,function(e,t){return t%2}))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},S.extend=S.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||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[t]=S.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},S.extend({expando:"jQuery"+(f+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]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=v.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){b(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(p(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},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?S.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.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=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g(a)},guid:1,support:y}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=t[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var d=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,S="sizzle"+1*new Date,p=n.document,k=0,r=0,m=ue(),x=ue(),A=ue(),N=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",I="(?:\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",W="\\["+M+"*("+I+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+I+"))|)"+M+"*\\]",F=":("+I+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+W+")*)|.*)\\)|)",B=new RegExp(M+"+","g"),$=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),_=new RegExp("^"+M+"*,"+M+"*"),z=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),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("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(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 de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){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[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.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},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="<a id='"+S+"'></a><select id='"+S+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.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 l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(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?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!=C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,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(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===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]||se.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]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(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(te,ne).toLowerCase();return"*"===e?function(){return!0}
vendor: 4,356 bytes, line 4231
4231:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace(B," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),x="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[k,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[k,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[S]?a(o):1<a.length?(t=[e,e,"",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace($,"$1"));return s[S]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!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!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.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:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[k,p];
vendor: 10,068 bytes, line 4231
4231if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[S]||(e[S]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===k&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(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 Ce(d,h,g,v,y,e){return v&&!v[S]&&(v=Ce(v)),y&&!y[S]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[" "],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[S]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace($," ")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=A[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[S]?i.push(a):o.push(a);(a=A(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG("*",i),h=k+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t==C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument==C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(k=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(k=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=S.split("").sort(D).join("")===S,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);S.find=d,S.expr=d.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=d.uniqueSort,S.text=d.getText,S.isXMLDoc=d.isXML,S.contains=d.contains,S.escapeSelector=d.escape;var h=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&S(e).is(n))break;r.push(e)}return r},T=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=S.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1<i.call(n,e)!==r}):S.filter(n,e,r)}S.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?S.find.matchesSelector(r,e)?[r]:[]:S.find.matches(e,S.grep(t,function(e){return 1===e.nodeType}))},S.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(S(e).filter(function(){for(t=0;t<r;t++)if(S.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)S.find(e,i[t],n);return 1<r?S.uniqueSort(n):n},filter:function(e){return this.pushStack(D(this,e||[],!1))},not:function(e){return this.pushStack(D(this,e||[],!0))},is:function(e){return!!D(this,"string"==typeof e&&k.test(e)?S(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(S.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&S(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&S.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?S.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(S(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),S.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return h(e,"parentNode")},parentsUntil:function(e,t,n){return h(e,"parentNode",n)},next:function(e){return O(e,"nextSibling")},prev:function(e){return O(e,"previousSibling")},nextAll:function(e){return h(e,"nextSibling")},prevAll:function(e){return h(e,"previousSibling")},nextUntil:function(e,t,n){return h(e,"nextSibling",n)},prevUntil:function(e,t,n){return h(e,"previousSibling",n)},siblings:function(e){return T((e.parentNode||{}).firstChild,e)},children:function(e){return T(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,"template")&&(e=e.content||e),S.merge([],e.childNodes))}},function(r,i){S.fn[r]=function(e,t){var n=S.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=S.filter(t,n)),1<this.length&&(H[r]||S.uniqueSort(n),L.test(r)&&n.reverse()),this.pushStack(n)}});var P=/[^\x20\t\r\n\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}S.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},S.each(e.match(P)||[],function(e,t){n[t]=!0}),n):S.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){S.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return S.each(arguments,function(e,t){var n;while(-1<(n=S.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<S.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},S.extend({Deferred:function(e){var o=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],i="pe
vendor: 8,547 bytes, line 4231
4231nding",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return S.Deferred(function(r){S.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,R,s),l(u,o,M,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,M,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==M&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(S.Deferred.getStackHook&&(t.stackTrace=S.Deferred.getStackHook()),C.setTimeout(t))}}return S.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:R)),o[2][3].add(l(0,e,m(n)?n:M))}).promise()},promise:function(e){return null!=e?S.extend(e,a):a}},s={};return S.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(I(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)I(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&W.test(e.name)&&C.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},S.readyException=function(e){C.setTimeout(function(){throw e})};var F=S.Deferred();function B(){E.removeEventListener("DOMContentLoaded",B),C.removeEventListener("load",B),S.ready()}S.fn.ready=function(e){return F.then(e)["catch"](function(e){S.readyException(e)}),this},S.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--S.readyWait:S.isReady)||(S.isReady=!0)!==e&&0<--S.readyWait||F.resolveWith(E,[S])}}),S.ready.then=F.then,"complete"===E.readyState||"loading"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(S.ready):(E.addEventListener("DOMContentLoaded",B),C.addEventListener("load",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===w(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(S(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},_=/^-ms-/,z=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(z,U)}var V=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function G(){this.expando=S.expando+G.uid++}G.uid=1,G.prototype={cache:function(e){var t=e[this.expando];return t||(t={},V(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[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(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(X):(t=X(t))in r?[t]:t.match(P)||[]).length;while(n--)delete r[t[n]]}(void 0===t||S.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&&!S.isEmptyObject(t)}};var Y=new G,Q=new G,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function Z(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}Q.set(e,t,n)}else n=void 0;return n}S.extend({hasData:function(e){return Q.hasData(e)||Y.hasData(e)},data:function(e,t,n){return Q.access(e,t,n)},removeData:function(e,t){Q.remove(e,t)},_data:function(e,t,n){return Y.access(e,t,n)},_removeData:function(e,t){Y.remove(e,t)}}),S.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=Q.get(o),1===o.nodeType&&!Y.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),Z(o,r,i[r]));Y.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){Q.set(this,n)}):$(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=Q.get(o,n))?t:void 0!==(t=Z(o,n))?t:void 0;this.each(function(){Q.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){Q.remove(this,e)})}}),S.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=S.queue(e,t),r=n.length,i=n.shift(),o=S._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){S.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Y.get(e,n)||Y.access(e,n,{empty:S.Callbacks("once memory").add(function(){Y.remove(e,[t+"queue",n])})})}}),S.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?S.queue(this[0],t):void 0===n?this:this.each(function(){var e=S.queue(this,t,n);S._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&S.dequeue(this,t)})},dequeue:function(e){return this.each(function(){S.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=S.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=Y.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=E.documentElement,ie=function(e){return S.contains(e.ownerDocument,e)},oe={composed:!0};re.getRootNode&&(ie=function(e){return S.contains(e.ownerDocument,e)||e.getRootNode(oe)===e.ownerDocument});var ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&ie(e)&&"none"===S.css(e,"display")};function se(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(e,t,"")},u=s(),l=n&&n[3]||(S.cssNumber[t]?"":"px"),c=e.nodeType&&(S.cssNumber[t]||"px"!==l&&+u)&&te.exec(S.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)S.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,S.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 ue={};function le(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=Y.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&ae(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ue[s])||(o=a.body.appendChild(a.createElement(s)),u=S.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),ue[s]=u)))):"none"!==n&&(l[c]="none",Y.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}S.fn.extend({show:function(){return le(this,!0)},hide:function(){return le(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?S(this).show():S(this).hide()})}});var ce,fe,pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone
vendor: 51,417 bytes, line 4231
4231=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="<textarea>x</textarea>",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="<option></option>",y.option=!!ce.lastChild;var ge={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,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Y.set(e[n],"globalEval",!t||Y.get(t[n],"globalEval"))}ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td,y.option||(ge.optgroup=ge.option=[1,"<select multiple='multiple'>","</select>"]);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"===w(o))S.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]+S.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&-1<S.inArray(o,r))i&&i.push(o);else if(l=ie(o),a=ve(f.appendChild(o),"script"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}var be=/^key/,we=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ce(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(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=Ee;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return S().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),e.each(function(){S.event.add(this,t,i,r,n)})}function Ae(e,i,o){o?(Y.set(e,i,!1),S.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Y.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(S.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Y.set(this,i,r),t=o(this,i),this[i](),r!==(n=Y.get(this,i))||t?Y.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Y.set(this,i,{value:S.event.trigger(S.extend(r[0],S.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,i)&&S.event.add(e,i,Ce)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(t);if(V(t)){n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(re,i),n.guid||(n.guid=S.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(P)||[""]).length;while(l--)d=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=S.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=S.event.special[d]||{},c=S.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),S.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(P)||[""]).length;while(l--)if(d=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=S.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,v.handle)||S.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)S.event.remove(e,d+t[l],n,r,!0);S.isEmptyObject(u)&&Y.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=S.event.fix(e),l=(Y.get(this,"events")||Object.create(null))[u.type]||[],c=S.event.special[u.type]||{};for(s[0]=u,t=1;t<arguments.length;t++)s[t]=arguments[t];if(u.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,u)){a=S.event.handlers.call(this,u,l),t=0;while((i=a[t++])&&!u.isPropagationStopped()){u.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!u.isImmediatePropagationStopped())u.rnamespace&&!1!==o.namespace&&!u.rnamespace.test(o.namespace)||(u.handleObj=o,u.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(u.result=r)&&(u.preventDefault(),u.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,u),u.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&&1<=e.button))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?-1<S(i,this).index(l):S.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(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[S.expando]?e:new S.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click",Ce),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,"input")&&Y.get(t,"click")||A(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},S.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},S.Event=function(e,t){if(!(this instanceof S.Event))return new S.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ce:Ee,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&&S.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Ee,isPropagationStopped:Ee,isImmediatePropagationStopped:Ee,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ce,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ce,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ce,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},S.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,code:!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&&be.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&we.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},function(e,t){S.event.special[e]={setup:function(){return Ae(this,e,Se),!1},trigger:function(){return Ae(this,e),!0},delegateType:t}}),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){S.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||S.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),S.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,S(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=Ee),this.each(function(){S.event.remove(this,e,n,t)})}});var Ne=/<script|<style|<link/i,De=/checked\s*(?:[^=]|=\s*.checked.)/i,je=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(t,i,s[i][n]);Q.hasData(e)&&(o=Q.access(e),a=S.extend({},o),Q.set(t,a))}}function Pe(n,r,i,o){r=g(r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&"string"==typeof d&&!y.checkClone&&De.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Pe(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=S.map(ve(e,"script"),Le)).length;c<f;c++)u=e,c!==p&&(u=S.clone(u,!0,!0),s&&S.merge(a,ve(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,He),c=0;c<s;c++)u=a[c],he.test(u.type||"")&&!Y.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):b(u.textContent.replace(je,""),u,l))}return n}function Re(e,t,n){for(var r,i=t?S.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(ve(r)),r.parentNode&&(n&&ie(r)&&ye(ve(r,"script")),r.parentNode.removeChild(r));return e}S.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=ie(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||S.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Oe(o[r],a[r]);else Oe(e,c);return 0<(a=ve(c,"script")).length&&ye(a,!f&&ve(e,"script")),c},cleanData:function(e){for(var t,n,r,i=S.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,function(e){return void 0===e?S.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 Pe(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return Pe(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=qe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Pe(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&&(S.cleanData(ve(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return S.clone(this,e,t)})},html:function(e){return $(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&&!Ne.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=S.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(S.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Pe(this,arguments,function(e){var t=this.parentNode;S.inArray(this,n)<0&&(S.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){S.fn[e]=function(e){for(var t,n=[],r=S(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),S(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Ie=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},We=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Fe=new RegExp(ne.join("|"),"i");function Be(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ie(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||ie(e)||(a=S.style(e,t)),!y.pixelBoxStyles()&&Me.test(a)&&Fe.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}}}!function(){function e(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",re.appendChild(u).appendChild(l);var e=C.getComputedStyle(l);n="1%"!==e.top,s=12===t(e.marginLeft),l.style.right="60%",o=36===t(e.right),r=36===t(e.width),l.style.position="absolute",i=12===t(l.offsetWidth/3),re.removeChild(u),l=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s,u=E.createElement("div"),l=E.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",y.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),s},scrollboxSize:function(){return e(),i},reliableTrDimensions:function(){var e,t,n,r;return null==a&&(e=E.createElement("table"),t=E.createElement("tr"),n=E.createElement("div"),e.style.cssText="position:absolute;left:-11111px",t.style.height="1px",n.style.height="9px",re.appendChild(e).appendChild(t).appendChild(n),r=C.getComputedStyle(t),a=3<parseInt(r.height),re.removeChild(e)),a}}))}();var _e=["Webkit","Moz","ms"],ze=E.createElement("div").style,Ue={};function Xe(e){var t=S.cssProps[e]||Ue[e];return t||(e in ze?e:Ue[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in ze)return e}(e)||e)}var Ve=/^(none|table(?!-c[ea]).+)/,Ge=/^--/,Ye={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(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+=S.css(e,n+ne[a],!0,i)),r?("content"===n&&(u-=S.css(e,"padding"+ne[a],!0,i)),"margin"!==n&&(u-=S.css(e,"border"+ne[a]+"Width",!0,i))):(u+=S.css(e,"padding"+ne[a],!0,i),"padding"!==n?u+=S.css(e,"border"+ne[a]+"Width",!0,i):s+=S.css(e,"border"+ne[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!y.boxSizingReliable()||n)&&"border-box"===S.css(e,"boxSizing",!1,r),o=i,a=Be(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!y.boxSizingReliable()&&i||!y.reliableTrDimensions()&&A(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===S.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?"border":"content"),o,r,a)+"px"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}S.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!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=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=S.cssHooks[t]||S.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=te.exec(n))&&i[1]&&(n=se(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),y.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=X(t);return Ge.test(t)||(t=Xe(s)),(a=S.cssHooks[t]||S.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),"normal"===i&&t in Qe&&(i=Qe[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],function(e,u){S.cssHooks[u]={get:function(e,t,n){if(t)return!Ve.test(S.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,u,n):We(e,Ye,function(){return Ze(e,u,n)})},set:function(e,t,n){var r,i=Ie(e),o=!y.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===S.css(e,"boxSizing",!1,i),s=n?Ke(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-Ke(e,u,"border",!1,i)-.5)),s&&(r=te.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=S.css(e,u)),Je(0,t,s)}}}),S.cssHooks.marginLeft=$e(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Be(e,"marginLeft"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),S.each({margin:"",padding:"",border:"Width"},function(i,o){S.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+ne[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(S.cssHooks[i+o].set=Je)}),S.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=S.css(e,t[a],!1,r);return o}return void 0!==n?S.style(e,t,n):S.css(e,t)},e,t,1<arguments.length)}}),((S.Tween=et).prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||S.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=S.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):et.propHooks._default.set(this),this}}).init.prototype=et.prototype,(et.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=S.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){S.fx.step[e.prop]?S.fx.step[e.prop](e):1!==e.elem.nodeType||!S.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:S.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},S.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},S.fx=et.prototype.init,S.fx.step={};var tt,nt,rt,it,ot=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function st(){nt&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(st):C.setTimeout(st,S.fx.interval),S.fx.tick())}function ut(){return C.setTimeout(function(){tt=void 0}),tt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=ne[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ft(o,e,t){var n,a,r=0,i=ft.prefilters.length,s=S.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=tt||ut(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},t),originalProperties:e,originalOptions:t,startTime:tt||ut(),duration:t.duration,tweens:[],createTween:function(e,t){var n=S.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=X(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=ft.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(S._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return S.map(c,ct,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),S.fx.timer(S.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}S.Animation=S.extend(ft,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return se(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(P);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ft.tweeners[n]=ft.tweeners[n]||[],ft.tweeners[n].unshift(t)},prefilters:[function(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),v=Y.get(e,"fxshow");for(r in n.queue||(null==(a=S._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--,S.queue(e,"fx").length||a.empty.fire()})})),t)if(i=t[r],ot.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||S.style(e,r)}if((u=!S.isEmptyObject(t))||!S.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Y.get(e,"display")),"none"===(c=S.css(e,"display"))&&(l?c=l:(le([e],!0),l=e.style.display||l,c=S.css(e,"display"),le([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===S.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,d)u||(v?"hidden"in v&&(g=v.hidden):v=Y.access(e,"fxshow",{display:l}),o&&(v.hidden=!g),g&&le([e],!0),p.done(function(){for(r in g||le([e]),Y.remove(e,"fxshow"),d)S.style(e,r,d[r])})),u=ct(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?ft.prefilters.unshift(e):ft.prefilters.push(e)}}),S.speed=function(e,t,n){var r=e&&"object"==typeof e?S.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.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(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=ft(this,S.extend({},t),o);(i||Y.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return"string"!=typeof i&&(o=e,e=i,i=void 0),e&&this.queue(i||"fx",[]),this.each(function(){var e=!0,t=null!=i&&i+"queueHooks",n=S.timers,r=Y.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&at.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||S.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var e,t=Y.get(this),n=t[a+"queue"],r=t[a+"queueHooks"],i=S.timers,o=n?n.length:0;for(t.finish=!0,S.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),S.each(["toggle","show","hide"],function(e,r){var i=S.fn[r];S.fn[r]=function(e,t,n){return null==e||"boolean"==typeof e?i.apply(this,arguments):this.animate(lt(r,!0),e,t,n)}}),S.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,r){S.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),S.timers=[],S.fx.tick=function(){var e,t=0,n=S.timers;for(tt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||S.fx.stop(),tt=void 0},S.fx.timer=function(e){S.timers.push(e),S.fx.start()},S.fx.interval=13,S.fx.start=function(){nt||(nt=!0,st())},S.fx.stop=function(){nt=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(r,e){return r=S.fx&&S.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},rt=E.createElement("input"),it=E.createElement("select").appendChild(E.createElement("option")),rt.type="checkbox",y.checkOn=""!==rt.value,y.optSelected=it.selected,(rt=E.createElement("input")).value="t",rt.type="radio",y.radioValue="t"===rt.value;var pt,dt=S.expr.attrHandle;S.fn.extend({attr:function(e,t){return $(this,S.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){S.removeAttr(this,e)})}}),S.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?S.prop(e,t,n):(1===o&&S.isXMLDoc(e)||(i=S.attrHooks[t.toLowerCase()]||(S.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void S.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=S.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&"radio"===t&&A(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(P);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?S.removeAttr(e,n):e.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),function(e,t){var a=dt[t]||S.find.attr;dt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=dt[o],dt[o]=r,r=null!=a(e,t,n)?o:null,dt[o]=i),r}});var ht=/^(?:input|select|textarea|button)$/i,gt=/^(?:a|area)$/i;function vt(e){return(e.match(P)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(P)||[]}S.fn.extend({prop:function(e,t){return $(this,S.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[S.propFix[e]||e]})}}),S.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(e)||(t=S.propFix[t]||t,i=S.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=S.find.attr(e,"tabindex");return t?parseInt(t,10):ht.test(e.nodeName)||gt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),y.optSelected||(S.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)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){S.propFix[this.toLowerCase()]=this}),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).addClass(t.call(this,e,yt(this)))});if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).removeClass(t.call(this,e,yt(this)))});if(!arguments.length)return this.attr("class","");if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){S(this).toggleClass(i.call(this,e,yt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=S(this),r=mt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=yt(this))&&Y.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":Y.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+vt(yt(n))+" ").indexOf(t))return!0;return!1}});var xt=/\r/g;S.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,S(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=S.map(t,function(e){return null==e?"":e+""})),(r=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=S.valHooks[t.type]||S.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(xt,""):null==e?"":e:void 0}}),S.extend({valHooks:{option:{get:function(e){var t=S.find.attr(e,"value");return null!=t?t:vt(S.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||!A(n.parentNode,"optgroup"))){if(t=S(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=S.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<S.inArray(S.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],function(){S.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<S.inArray(S(e).val(),t)}},y.checkOn||(S.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),y.focusin="onfocusin"in C;var bt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};S.extend(S.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,"type")?e.type:e,h=v.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!bt.test(d+S.event.triggered)&&(-1<d.indexOf(".")&&(d=(h=d.split(".")).shift(),h.sort()),u=d.indexOf(":")<0&&"on"+d,(e=e[S.expando]?e:new S.Event(d,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:S.makeArray(t,[e]),c=S.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,bt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Y.get(o,"events")||Object.create(null))[e.type]&&Y.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&V(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!V(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),S.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,wt),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,wt),S.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=S.extend(new S.Event,n,{type:e,isSimulated:!0});S.event.trigger(r,null,t)}}),S.fn.extend({trigger:function(e,t){return this.each(function(){S.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return S.event.trigger(e,t,n,!0)}}),y.focusin||S.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){S.event.simulate(r,e.target,S.event.fix(e))};S.event.special[r]={setup:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r);t||e.addEventListener(n,i,!0),Y.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r)-1;t?Y.access(e,r,t):(e.removeEventListener(n,i,!0),Y.remove(e,r))}}});var Tt=C.location,Ct={guid:Date.now()},Et=/\?/;S.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,"text/xml")}catch(e){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+e),t};var St=/\[\]$/,kt=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Nt=/^(?:input|select|textarea|keygen)/i;function Dt(n,e,r,i){var t;if(Array.isArray(e))S.each(e,function(e,t){r||St.test(n)?i(n,t):Dt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==w(e))i(n,e);else for(t in e)Dt(n+"["+t+"]",e[t],r,i)}S.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!S.isPlainObject(e))S.each(e,function(){i(this.name,this.value)});else for(n in e)Dt(n,e[n],t,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=S.prop(this,"elements");return e?S.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!S(this).is(":disabled")&&Nt.test(this.nodeName)&&!At.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}});var jt=/%20/g,qt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ot=/^(?:GET|HEAD)$/,Pt=/^\/\//,Rt={},Mt={},It="*/".concat("*"),Wt=E.createElement("a");function Ft(o){return function(e,t){"string"!=typeof e&&(t=e,e="*");var n,r=0,i=e.toLowerCase().match(P)||[];if(m(t))while(n=i[r++])"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function Bt(t,i,o,a){var s={},u=t===Mt;function l(e){var r;return s[e]=!0,S.each(t[e]||[],function(e,t){var n=t(i,o,a);return"string"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s["*"]&&l("*")}function $t(e,t){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&S.extend(!0,e,r),e}Wt.href=Tt.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Tt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Tt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":It,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":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,S.ajaxSettings),t):$t(S.ajaxSettings,e)},ajaxPrefilter:Ft(Rt),ajaxTransport:Ft(Mt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=S.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?S(y):S.event,x=S.Deferred(),b=S.Callbacks("once memory"),w=v.statusCode||{},a={},s={},u="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Ht.exec(p))n[t[1].toLowerCase()+" "]=(n[t[1].toLowerCase()+" "]||[]).concat(t[2])}t=n[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Tt.href)+"").replace(Pt,Tt.protocol+"//"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||"*").toLowerCase().match(P)||[""],null==v.crossDomain){r=E.createElement("a");try{r.href=v.url,r.href=r.href,v.crossDomain=Wt.protocol+"//"+Wt.host!=r.protocol+"//"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&"string"!=typeof v.data&&(v.data=S.param(v.data,v.traditional)),Bt(Rt,v,t,T),h)return T;for(i in(g=S.event&&v.global)&&0==S.active++&&S.event.trigger("ajaxStart"),v.type=v.type.toUpperCase(),v.hasContent=!Ot.test(v.type),f=v.url.replace(qt,""),v.hasContent?v.data&&v.processData&&0===(v.contentType||"").indexOf("application/x-www-form-urlencoded")&&(v.data=v.data.replace(jt,"+")):(o=v.url.slice(f.length),v.data&&(v.processData||"string"==typeof v.data)&&(f+=(Et.test(f)?"&":"?")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Lt,"$1"),o=(Et.test(f)?"&":"?")+"_="+Ct.guid+++o),v.url=f+o),v.ifModified&&(S.lastModified[f]&&T.setRequestHeader("If-Modified-Since",S.lastModified[f]),S.etag[f]&&T.setRequestHeader("If-None-Match",S.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader("Content-Type",v.contentType),T.setRequestHeader("Accept",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+("*"!==v.dataTypes[0]?", "+It+"; q=0.01":""):v.accepts["*"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u="abort",b.add(v.complete),T.done(v.success),T.fail(v.error),c=Bt(Mt,v,t,T)){if(T.readyState=1,g&&m.trigger("ajaxSend",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort("timeout")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,"No Transport");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||"",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(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]}(v,T,n)),!i&&-1<S.inArray("script",v.dataTypes)&&(v.converters["text script"]=function(){}),s=function(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}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader("Last-Modified"))&&(S.lastModified[f]=u),(u=T.getResponseHeader("etag"))&&(S.etag[f]=u)),204===e||"HEAD"===v.type?l="nocontent":304===e?l="notmodified":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l="error",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+"",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?"ajaxSuccess":"ajaxError",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger("ajaxComplete",[T,v]),--S.active||S.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return S.get(e,t,n,"json")},getScript:function(e,t){return S.get(e,void 0,t,"script")}}),S.each(["get","post"],function(e,i){S[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),S.ajax(S.extend({url:e,type:i,dataType:r,data:t,success:n},S.isPlainObject(e)&&e))}}),S.ajaxPrefilter(function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")}),S._evalUrl=function(e,t,n){return S.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){S.globalEval(e,t,n)}})},S.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=S(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(n){return m(n)?this.each(function(e){S(this).wrapInner(n.call(this,e))}):this.each(function(){var e=S(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){S(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){S(this).replaceWith(this.childNodes)}),this}}),S.expr.pseudos.hidden=function(e){return!S.expr.pseudos.visible(e)},S.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var _t={0:200,1223:204},zt=S.ajaxSettings.xhr();y.cors=!!zt&&"withCredentials"in zt,y.ajax=zt=!!zt,S.ajaxTransport(function(i){var o,a;if(y.cors||zt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===e?r.abort():"error"===e?"number"!=typeof r.status?t(0,"error"):t(r.status,r.statusText):t(_t[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o("error"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o("abort");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),S.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),S.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 S.globalEval(e),e}}}),S.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),S.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=S("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1<s&&(r=vt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),0<a.length&&S.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?S("<div>").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.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"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.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)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.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,n){S.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}});var Gt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||S.guid++,i},S.holdReady=function(e){e?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=A,S.isFunction=m,S.isWindow=x,S.camelCase=X,S.type=w,S.now=Date.now,S.isNumeric=function(e){var t=S.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},S.trim=function(e){return null==e?"":(e+"").replace(Gt,"")},"function"==typeof define&&define.amd&&define("jquery",[],function(){return S});var Yt=C.jQuery,Qt=C.$;return S.noConflict=function(e){return C.$===S&&(C.$=Qt),e&&C.jQuery===S&&(C.jQuery=Yt),S},"undefined"==typeof e&&(C.jQuery=C.$=S),S});
4232
4233/* End */
4234;
4235; /* Start:"a:4:{s:4:"full";s:70:"/local/templates/CAIMAN_2025/assets/custom/js/common.js?17876642545854";s:6:"source";s:55:"/local/templates/CAIMAN_2025/assets/custom/js/common.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
4236function setCookie(name,value,days) {
4237	var expires = "";
4238	if (days) {
4239		var date = new Date();
4240		date.setTime(date.getTime() + (days*24*60*60*1000));
4241		expires = "; expires=" + date.toUTCString();
4242	}
4243	document.cookie = name + "=" + (value || "")  + expires + "; path=/";
4244}
4245function getCookie(name) {
4246	var nameEQ = name + "=";
4247	var ca = document.cookie.split(';');
4248	for(var i=0;i < ca.length;i++) {
4249		var c = ca[i];
4250		while (c.charAt(0)==' ') c = c.substring(1,c.length);
4251		if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
4252	}
4253	return null;
4254}
4255function eraseCookie(name) {
4256	document.cookie = name +'=; Path=/; Expires=Thu, 01 Jan 1970 00:00:01 GMT;';
4257}
4258
4259function get_short_link()
4260{
4261	BX.ready(function() {
4262		$.ajax({
4263			url: '/ajax/ajax_short_link.php',
4264			type: 'post',
4265			data: {urlorig: window.location.href},
4266			dataType: 'json',
4267			success: function(obj) {
4268
4269				if(obj['STATUS']=="Y")
4270				{
4271					prompt('короткая ссылка', obj['URL']);
4272				}
4273
4274				console.log(obj['URL']);
4275			},
4276		});
4277	});
4278}
4279
4280
4281
4282
4283$(document).ready(function() {
4284	$('html').on('DOMMouseScroll mousewheel', function (e) {
4285		if(e.originalEvent.detail > 0 || e.originalEvent.wheelDelta < 0) {
4286			$( "#header-nav" ).addClass( "hide-nav-bar" );
4287		} else {
4288			$( "#header-nav" ).removeClass( "hide-nav-bar" );
4289		}
4290	});
4291
4292	$('html').on('DOMMouseScroll mousewheel', function (e) {
4293		if(e.originalEvent.detail > 0 || e.originalEvent.wheelDelta < 0) {
4294			$( "#fix_prod" ).addClass( "hide-nav" );
4295		} else {
4296			$( "#fix_prod" ).removeClass( "hide-nav" );
4297		}
4298	});
4299
4300
4301	$('#offcanvasTel form').submit(function(){
4302		var frm = $(this);
4303		$.post('/ajax/forms.php', frm.serialize()+'&web_form_submit=Y&licenses_popup=Y', function(r){
4304			if (r.status == 'ok') {
4305				frm.html('<div class="alert alert-success">Спасибо! Ваша заявка принята</div>');
4306			} else {
4307				for (var i in r.errors) {
4308					frm.find('.field-' + i).append('<div class="alert alert-danger">Пожалуйста, заполните это поле</div>');
4309					frm.find('.field-'+i+' input').keyup(function(){$(this).parent().find('.alert').remove();});
4310				}
4311			}
4312		}, 'json');
4313		return false;
4314	});
4315	
4316
4317
4318//swiper
4319	var swiper = new Swiper(".swiper .SWprofi", {
4320		slidesPerView: 3,
4321		spaceBetween: 30,
4322		pagination: {
4323			el: ".swiper-pagination",
4324			clickable: true,
4325		},
4326	});
4327
4328	// Инициализация превью слайдера
4329	const sliderThumbs = new Swiper(".slider__thumbs .swiper-container", {
4330		// ищем слайдер превью по селектору
4331		// задаем параметры
4332		direction: "horizontal", // вертикальная прокрутка
4333		slidesPerView: 3, // показывать по 3 превью
4334		spaceBetween: 24, // расстояние между слайдами
4335		navigation: {
4336			// задаем кнопки навигации
4337			nextEl: ".slider__next", // кнопка Next
4338			prevEl: ".slider__prev" // кнопка Prev
4339		},
4340		freeMode: true, // при перетаскивании превью ведет себя как при скролле
4341		breakpoints: {
4342			// условия для разных размеров окна браузера
4343			0: {
4344				// при 0px и выше
4345				direction: "horizontal" // горизонтальная прокрутка
4346			},
4347			768: {
4348				// при 768px и выше
4349				direction: "horizontal" // вертикальная прокрутка
4350			}
4351		}
4352	});
4353// Инициализация слайдера изображений
4354	const sliderImages = new Swiper(".slider__images .swiper-container", {
4355		scrollbar: {
4356			el: ".swiper-scrollbar",
4357			hide: true,
4358		},
4359		// ищем слайдер превью по селектору
4360		// задаем параметры
4361		direction: "horizontal", // вертикальная прокрутка
4362		slidesPerView: 1, // показывать по 1 изображению
4363		spaceBetween: 32, // расстояние между слайдами
4364		mousewheel: true, // можно прокручивать изображения колёсиком мыши
4365		navigation: {
4366			// задаем кнопки навигации
4367			nextEl: ".slider__next", // кнопка Next
4368			prevEl: ".slider__prev" // кнопка Prev
4369		},
4370		grabCursor: true, // менять иконку курсора
4371		thumbs: {
4372			// указываем на превью слайдер
4373			swiper: sliderThumbs // указываем имя превью слайдера
4374		},
4375		breakpoints: {
4376			// условия для разных размеров окна браузера
4377			0: {
4378				// при 0px и выше
4379				direction: "horizontal" // горизонтальная прокрутка
4380			},
4381			768: {
4382				// при 768px и выше
4383				direction: "horizontal" // вертикальная прокрутка
4384			}
4385		}
4386	});
4387
4388//tabs_index_banner_bisness
4389	var tabChange = function(){
4390		var tabs = $('.nav-pills > li');
4391		var active = tabs.find('a').filter('.active');
4392		var next = active.parent().next('li').length ? active.parent().next('li').find('a') : tabs.filter(':first-child').find('a');
4393		next.tab('show')
4394	}
4395
4396	var click = setInterval(tabChange, 12000)
4397
4398});
4399
4400$(".item .swiper-container").each(function () {
4401	var uniq = "swiper--auto-" + new Date().getTime();
4402	$(this).attr("id", uniq);
4403
4404	var swiper = new Swiper("#" + uniq, {
4405		pagination: {
4406			el: ".swiper-pagination"
4407		}
4408	});
4409
4410	var width = $(this).width();
4411	var ln = swiper.slides.length;
4412	var per = width / ln;
4413
4414	$("#" + uniq).on("mousemove", function (e) {
4415		var parentOffset = $(this).parent().offset();
4416		//or $(this).offset(); if you really just want the current element's offset
4417		var relX = e.pageX - parentOffset.left;
4418		var relY = e.pageY - parentOffset.top;
4419
4420		for (i = 0; i < ln; i++) {
4421			var pos = per * i;
4422
4423			if(relX >= pos && pos <= pos) {
4424				swiper.slideTo(i);
4425			}
4426		}
4427	});
4428});
4429
4430
4431/* End */
4432;
4433; /* Start:"a:4:{s:4:"full";s:73:"/local/templates/CAIMAN_2025/assets/custom/js/cart-func.js?17764381777010";s:6:"source";s:58:"/local/templates/CAIMAN_2025/assets/custom/js/cart-func.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
4434
4435window._caiman_cur_cmp_po = false;
4436
4437$(document).ready(function() {
4438	reloadHeaderCart();
4439	$(document).on('click', '.compare', function(e){
4440		e.preventDefault();
4441		var trg = $(this);
4442		if (window._caiman_cur_cmp_po) {
4443			console.log('clear po');
4444			window._caiman_cur_cmp_po.popover('hide');
4445			window._caiman_cur_cmp_po = false;
4446		}
4447		$.get('/ajax/cmp.php?id='+trg.attr('data-id')+'&action='+(trg.hasClass('active') ? 'DELETE_FROM_COMPARE_LIST' : 'ADD_TO_COMPARE_LIST'), function(r){
4448			$('.cmp-cnt').html(r.count);
4449			if (trg.hasClass('active')) {
4450				trg.removeClass('active');
4451				//$('#quantity_compare').html(parseInt($('#quantity_compare').html()) - 1 );
4452			} else {
4453				trg.addClass('active');
4454				//$('#quantity_compare').html(parseInt($('#quantity_compare').html()) + 1 );
4455			}
4456			//$('.cmp-counter').html(r.count);
4457			if (r.count > 1) {
4458			//	window._caiman_cur_cmp_po = (trg.parent()).popover({content:'<a class="black-link" style="color:black;" href="/catalog/compare/" target="_blank">Перейти в сравнение ('+r.count+')</a>', title:'', html:true, placement:'left',  trigger: 'manual'});
4459			//	window._caiman_cur_cmp_po.popover('show');
4460			}
4461
4462		}, 'json');
4463		return false;
4464	});
4465	
4466	$('.fav').click(function(){
4467		var trg=$(this);
4468		$.post('/ajax/fav.php', {sessid:BX.bitrix_sessid(), 'action': $(this).hasClass('active') ? 'delete':'add', id:$(this).attr('data-id')}, function(r){
4469			trg.toggleClass('active');
4470			console.log('got fav', r);
4471			/*$('.fav-counter').html(r.length);
4472			if(r.length > 0) {
4473				$('.fav-counter').show();
4474			} else {
4475				$('.fav-counter').hide();
4476			}*/
4477			if (r.length > 0) {$('.fav-counter').html(r.length).show();} else {$('.fav-counter').hide();}
4478			console.log('json str', r, JSON.stringify(r));
4479			setCookie('caiman_fav', JSON.stringify(r), 30);
4480		}, 'json');
4481	});
4482	try {
4483		var faval = getCookie('caiman_fav');
4484		if (faval && faval.length > 0) {
4485			var favit = JSON.parse(faval);
4486			for (var i in favit) {
4487				$('.fav[data-id="'+favit[i]+'"]').addClass('active');
4488			}
4489			if (favit.length > 0) {$('.fav-counter').html(favit.length).show();} else {$('.fav-counter').hide();}
4490		}
4491	} catch(e) {
4492		console.log('fav whoops', e);
4493		$('.fav-counter').hide();
4494	}
4495	
4496	if ($('.compare').length > 0) {
4497		$.get('/ajax/cmp.php', {'action':'list'}, function(r){
4498			//if (r.length > 0) $('#quantity_compare, .cmp-counter').html(r.length);
4499			$('.compare').each(function(i, a){
4500				var a = $(a);
4501				var id = parseInt(a.attr('data-id'));
4502				a.addClass(r.includes(id) ? 'active' : '');
4503				
4504			});
4505			$('.cmp-cnt').html(r.length);
4506		}, 'json');
4507	}	
4508	
4509});
4510
4511function reloadHeaderCart()
4512{
4513	$.ajax({
4514		method:'POST',
4515		url: '/ajax/add2cart.php',
4516		data: 'action=getCart&id=333',
4517		dataType:'json',
4518		success: function(data){
4519			//console.log(data);
4520			$('#basket_top .offcanvas-body').html(data.BODY);
4521			$('#basket_top .offcanvas-footer ').html(data.FOOTER);
4522			$('header .bx-cart+.badge').html(''+data.QUANTITY_NUMBER);
4523		}
4524	});
4525}
4526
4527function updateCartData() 
4528{
4529	
4530}
4531
4532function reloadCart()
4533{
4534	document.location.reload();
4535}
4536
4537$(document).on('click', '.cart .bx-plus, #basket_top .bx-plus', function(e){
4538	changeOrderCountItem(this);
4539	/*var trg = $(this).closest('tr');
4540	var cv = parseInt(trg.find('input:eq(0)').val());
4541	cv = cv + 1;
4542	trg.find('input.q-value').val(cv);
4543	updateCartData();*/
4544	return false;
4545});
4546
4547$(document).on('click', '.cart .bx-minus, #basket_top .bx-minus', function(e){
4548	changeOrderCountItem(this);
4549	return false;
4550	/*
4551	var trg = $(this).closest('tr');
4552	var cv = parseInt(trg.find('input:eq(0)').val());
4553	if (cv > 1) {
4554		trg.find('input.q-value').val(cv - 1);
4555		updateCartData();
4556	}*/
4557});
4558
4559$(document).on('click', '.cart-delete', function(e){
4560	var trg = $(this).closest('tr');
4561	$.post('/ajax/add2cart.php', {'action':'delete-cart-item', 'id':$(this).attr('data-ci-id')}, function(r){
4562		if (parseInt(r.success) == 1 && location.href.indexOf('/personal/cart/') > -1 ) {
4563			reloadCart();
4564		} else {
4565			reloadHeaderCart();
4566		}
4567	}, 'json');
4568	return false;
4569});
4570
4571$(document).on('click', '.add2cart', function(e){
4572	var src = $(this);
4573	console.log('bbbb');
4574	var action = $(this).hasClass('btn-green') ? 'add' : 'remove';
4575	$.post('/ajax/add2cart.php', {'QUANTITY':1, 'action': action, 'id':$(this).attr('data-prod-id'), 'CML2_ARTICLE':$(this).attr('data-prod-art')}, function(r){
4576		if (r.success = '1') {
4577			if (src.hasClass('non-std')) {
4578				reloadCart();
4579			} else {
4580				reloadHeaderCart();
4581			}
4582			if (action == 'add') {
4583				src.removeClass('btn-green');
4584			} else {
4585				src.addClass('btn-green');
4586			}
4587		}
4588	}, 'json');
4589	
4590	window.dataLayer = window.dataLayer || [];
4591	dataLayer.push({
4592	'ecommerce' : {
4593		'add' : {
4594		  'products' : [
4595			{
4596			  'name' : $(this).attr('data-ecomm-name'), // обязательное
4597			  'id' : $(this).attr('data-prod-id'), // обязательное
4598			  'price' : $(this).attr('data-ecomm-price'),
4599			  'brand' : $(this).attr('data-ecomm-brand'),
4600			  'list' : $(this).attr('data-ecomm-list'),
4601			  'position' : $(this).attr('data-ecomm-position'),
4602			  'category' : $(this).attr('data-ecomm-category'),
4603			  'quantity': 1
4604			}
4605		  ]
4606		}
4607	  }
4608	});
4609	
4610	return false;
4611});
4612
4613function updateCart(data){
4614	if(JSON.parse(data)['QUANTITY'] != null){
4615		var ajax_basket_info = JSON.parse(data);
4616		console.log(ajax_basket_info);
4617		$('.total-cart-sum').html(ajax_basket_info['SUM']);
4618		//$('#sum_quantity').text("В корзине "+ ajax_basket_info['QUANTITY']);
4619		//$('#quantity_basket').text(ajax_basket_info['QUANTITY_NUMBER']);			
4620	}
4621	else {
4622		$('#quantity_basket').text('0');
4623		$('.info_and_paybtn').hide();
4624	}
4625	
4626}
4627
4628function changeOrderCountItem(link) 
4629{
4630	var type = $(link).hasClass('bx-plus') ? 'plus' : 'minus';
4631		
4632	
4633	var input = $(link).closest('.count-input').find('.q-value');
4634	var cartRowId = input.attr('data-ci-id');
4635	if (type == 'minus' || type == 'plus') {
4636		var quan = input.val();
4637		var productId = input.attr('data-prid');
4638		var price = input.attr('data-price');
4639	}
4640
4641	$('#ajax_reload').fadeToggle();
4642	$.ajax({
4643		method:'POST',
4644		url: '/ajax/add2cart.php',
4645		data: 'id=33&action=refreshCart&cartRowId='+cartRowId+'&productId=' + productId + '&type=' + type + '&quan=' + quan,
4646		dataType:'json',
4647		success: function(data){
4648			if(data['PRODUCT_UPDATED'] == 'Y') {
4649				$('#basket_top .offcanvas-body').html(data.HTML);
4650				$('header .bx-cart+.badge').html(''+data.QUANTITY_NUMBER);
4651				$('.total-cart-sum').html(data.SUM);
4652				if(type == 'plus'){
4653					var quan_new = parseInt(quan) + 1;
4654					$(link).closest('.count-input').find('.q-value').val(quan_new);
4655					$(link).closest('tr').find('.price-cell').html((quan_new * price).toLocaleString('ru') + '&nbsp;₽');
4656				}
4657				else {
4658					var quan_new = parseInt(quan) - 1;
4659					if (quan_new > 0) {
4660						$(link).closest('.count-input').find('.q-value').val( quan_new );
4661						$(link).closest('tr').find('.price-cell').html((quan_new * price).toLocaleString('ru') + '&nbsp;₽');
4662					}
4663					else {
4664						//removeItem(th);
4665					}
4666				}							
4667			}
4668
4669			updateCart(data);
4670		}
4671	});
4672}
4673/* End */
4674;
4675; /* Start:"a:4:{s:4:"full";s:80:"/local/templates/CAIMAN_2025/assets/custom/js/forms-validator.js?178238890373167";s:6:"source";s:64:"/local/templates/CAIMAN_2025/assets/custom/js/forms-validator.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
4676/*
4677<form class="send-valid-fio-tel-email" novalidate="" onsubmit="return false">
4678<div id="formBody">
4679
4680		- Отправка без валидации у тега form класс send-valid-none
4681		- Отправка с валидацией только Телефона у тега form класс send-valid-tel
4682		- Отправка с валидацией Телефона и ФИО у тега form класс send-valid-fio-tel
4683		- Отправка с валидацией только Email у тега form класс send-valid-email
4684		- Отправка с валидацией Email и ФИО у тега form класс send-valid-fio-email
4685		- Отправка с валидацией Телефон, Email, ФИО у тега form класс send-valid-fio-tel-email
4686
4687		Обязательный инпут:
4688			<input type="hidden" class="form-label" name="form_type" value="******">
4689
4690		Вариативные инпуты:
4691			<input type="hidden" name="form_title" value="******"/>
4692			<input type="hidden" name="form_recipients" value="******@caiman.ru"/>
4693			<input type="hidden" name="request_uri" value="******"/>
4694
4695			<input type="text" class="form-control form-control-lg" placeholder="ФИО" name="name" required="" onkeyup="formInputkeyup(this);">
4696			<div class="invalid-feedback">Пожалуйста заполните поле!</div>
4697
4698			<input type="tel" name="phone" class="form-control form-control-lg" placeholder="+7 (___) ___-__-__" required="" onkeyup="formInputkeyup(this);">
4699			<div class="invalid-feedback">Пожалуйста заполните поле c телефоном!</div>
4700
4701			<input type="text" class="form-control form-control-lg" placeholder="E-mail" name="email" required="" onkeyup="formInputkeyup(this);">
4702			<div class="invalid-feedback">Пожалуйста заполните поле c email!</div>
4703
4704		<button type="submit" class="btn btn-green fw-normal btn-lg">Отправить</button>
4705</div>
4706<div id="status"></div>
4707</form>
4708*/
4709function formModalReset(e){
4710	var modalid = $(e).attr("data-bs-target");
4711	
4712	$(modalid).find('#formsuccess').addClass("d-none");
4713	$(modalid).find('#status').html("");
4714	$(modalid).find('#formBody').show();
4715	$(modalid).find("form").trigger("reset");
4716	$(modalid).find(".is-valid").removeClass("is-valid");
4717	$(modalid).find('input[type="checkbox"]').removeAttr("style");
4718}
4719
4720function yandexMetrikaTarget(formtype)
4721{
4722	var countid=33105028;
4723	switch (formtype) {
4724	  case 0:
4725		console.log("It's @!");
4726		break;
4727	  case 6:
4728		console.log("It's!");
4729		break;
4730	  default:
4731		ym(countid,'reachGoal','users_form');
4732		break;
4733	}
4734}
4735
4736function formInputkeyup(el){
4737	
4738	if(el.getAttribute('name')=="name")
4739	{
4740		if (el.value.length >= 2) {
4741			formValid(el);
4742		}
4743		else
4744		{
4745			formInValid(el);
4746		}
4747	}
4748	
4749	if(el.getAttribute('name')=="phone")
4750	{
4751		setTimeout(function() {
4752			if ((el.value !="+7 (___) ___-__-__") && (el.value.length != 0) && (el.value.includes('_') === false)) {
4753				formValid(el);
4754			}
4755			else
4756			{
4757				formInValid(el);
4758			}
4759		}, 300);
4760	}
4761	
4762	if(el.getAttribute('name')=="email")
4763	{
4764		var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
4765		if (reg.test(el.value) == true) {
4766			formValid(el);
4767		}
4768		else
4769		{
4770			formInValid(el);
4771		}
4772	}
4773	
4774	if(el.getAttribute('name')=="city")
4775	{
4776		if (el.value.length >= 2) {
4777			formValid(el);
4778		}
4779		else
4780		{
4781			formInValid(el);
4782		}
4783	}
4784	
4785	if(el.getAttribute('name')=="org")
4786	{
4787		if (el.value.length >= 2) {
4788			formValid(el);
4789		}
4790		else
4791		{
4792			formInValid(el);
4793		}
4794	}
4795	
4796	if(el.getAttribute('name')=="message")
4797	{
4798		if (el.value.length >= 2) {
4799			formValid(el);
4800		}
4801		else
4802		{
4803			formInValid(el);
4804		}
4805	}
4806	
4807	if(el.getAttribute('name')=="pos")
4808	{
4809		if (el.value.length >= 2) {
4810			formValid(el);
4811		}
4812		else
4813		{
4814			formInValid(el);
4815		}
4816	}
4817	
4818	if (el.getAttribute('name')=="agree") {
4819		
4820		if (el.checked) {
4821			el.style.boxShadow = 'inset 0px 0px 5px 1px green';
4822			formValid(el);
4823		}
4824		else
4825		{
4826			el.style.boxShadow = 'inset 0px 0px 5px 1px red';
4827			formInValid(el);
4828		}
4829	}
4830}
4831
4832//Проверка всех полей формы которые обязательны через required, тип валидации зависит от атрибута inputmode поля
4833function formInputChek(el){
4834	var result = true;
4835	// Простое текстовое поля (мин 2 символа)
4836	if(el.getAttribute('inputmode')=="text")
4837	{
4838		if (el.value.length >= 2) {
4839			formValid(el);
4840		}
4841		else
4842		{
4843			formInValid(el);
4844			result = false;
4845		}
4846	}
4847	// Поле телефон
4848	if(el.getAttribute('inputmode')=="phone")
4849	{
4850		if ((el.value !="+7 (___) ___-__-__") && (el.value.length != 0) && (el.value.includes('_') === false)) {
4851			formValid(el);
4852		}
4853		else
4854		{
4855			formInValid(el);
4856			result = false;
4857		}
4858	}
4859	//Поле e-mail (по маске формата)
4860	if(el.getAttribute('inputmode')=="email")
4861	{
4862		var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
4863		if (reg.test(el.value) == true) {
4864			formValid(el);
4865		}
4866		else
4867		{
4868			formInValid(el);
4869			result = false;
4870		}
4871	}
4872	//Выбран ли чекбокс
4873	if (el.getAttribute('inputmode')=="checkbox") {
4874		
4875		if (el.checked) {
4876			el.style.boxShadow = 'inset 0px 0px 5px 1px green';
4877			formValid(el);
4878		}
4879		else
4880		{
4881			el.style.boxShadow = 'inset 0px 0px 5px 1px red';
4882			formInValid(el);
4883			result = false;
4884		}
4885	}
4886	//Выбран ли options селекта
4887	if (el.getAttribute('inputmode')=="select") {
4888
4889		if (el.value) {
4890			formValid(el);
4891		}
4892		else
4893		{
4894			formInValid(el);
4895			result = false;
4896		}
4897	}
4898	//Выбран ли хотябы 1 файл
4899	if (el.getAttribute('inputmode')=="file") {
4900
4901		if ($(el).prop('files').length >= 1) {
4902			formValid(el);
4903		}
4904		else
4905		{
4906			formInValid(el);
4907			result = false;
4908		}
4909	}
4910	return result;
4911}
4912// End
4913
4914//Визуальный стиль валидности полей
4915function formValid(el){
4916	$(el).addClass("is-valid");
4917	$(el).removeClass("is-invalid");
4918	$(el).parent().find('.invalid-feedback').hide();
4919}
4920
4921function formInValid(el){
4922	$(el).addClass("is-invalid");
4923	$(el).removeClass("is-valid");
4924	$(el).parent().find('.invalid-feedback').show();
4925}
4926// End
4927$(function(){
4928	
4929	$('form.validater').each(function(){
4930		
4931		//Если обязательное поле изменилось проверяем валидность обязательных данных
4932		$(this).find('[required]').change(function() {
4933			formInputChek(this);
4934		});
4935		// End
4936		
4937		//Или в случаях chekbox был клик проверяем валидность обязательных данных
4938		$(this).find('[required]').keyup(function() {
4939			formInputChek(this);
4940		});
4941		// End
4942		
4943		// Была нажата кнопка отправки формы
4944		$(this).submit(function(event){
4945			event.preventDefault();
4946			let formData = new FormData(this);
4947			let statusvalid = [];
4948			var $f = $(this);
4949			$(this).find('[required]').each(function() {
4950					//Дополнительная проверка каждого обязательного поля, и создание массива ответов функции formInputChek()
4951					statusvalid.push(formInputChek(this));
4952			});
4953			
4954			//В массиве statusvalid все проверочные инпуты не содержат false, тогда отправляем форму
4955			if($.inArray(false, statusvalid)=="-1")
4956			{
4957				$f.find('#formBody').hide();
4958				$f.find('#status').html('<div class="alert alert-warning"><div class="form-loader">Идёт отправка<div class="form-dot"></div><div class="form-dot"></div><div class="form-dot"></div></div></div>');
4959					
4960				$.ajax({
4961						url : "/ajax/ajaxFeedBack.php",
4962						type: 'POST',
4963						dataType: 'json',
4964						data: formData,
4965						cache : false,
4966						processData: false,
4967						contentType: false
4968				}).done(function(response) {
4969					if(response.result === true)
4970					{
4971						if(response.msg)
4972						{
4973							$f.find('#status').html( '<div class="alert alert-success fw-bold fs-5">' + response.msg + '</div>');
4974						}
4975						else
4976						{
4977							$f.find('#status').html( '<div class="alert alert-success">Отправлено</div>');
4978						}
4979						
4980						$f.find('#formsuccess').removeClass("d-none");
4981						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
4982					}
4983					else
4984					{
4985						$f.find('#status').html( '<div class="alert alert-danger">Ошибка отправки '+ response.result +'</div>');
4986					}
4987				});
4988			}
4989			// End
4990		});
4991	});
4992	
4993	
4994	
4995	// Отправка без валидации
4996	$('form.send-valid-none').each(function(){
4997		$(this).submit(function(event){
4998			event.preventDefault();
4999			let formData = new FormData(this);
5000			var $f = $(this);	
5001			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5002			{
5003				$f.find('#formBody').hide();
5004				$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5005				
5006				$.ajax({
5007						url : "/ajax/ajaxFeedBack.php",
5008						type: 'POST',
5009						dataType: 'json',
5010						data: formData,
5011						cache : false,
5012						processData: false,
5013						contentType: false
5014				}).done(function(response) {
5015						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5016						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5017				});
5018			}
5019			else
5020			{
5021				alert("Скрипт валидации ожидает значение name='form_type' поля");
5022			}
5023		});
5024	});
5025	
5026	// Отправка с валидацией только Телефона
5027	$('form.send-valid-tel').each(function(){
5028		$(this).submit(function(event){
5029			event.preventDefault();
5030			let formData = new FormData(this);
5031			var $f = $(this);	
5032			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5033			{				
5034				if ( ($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5035					var telok = false;
5036					$f.find('input[name="phone"]').addClass("is-invalid");
5037					$f.find('input[name="phone"]').removeClass("is-valid");
5038					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5039				}
5040				else
5041				{
5042					var telok = true;
5043				}
5044				
5045				if (telok==true) {
5046					$f.find('#formBody').hide();
5047					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5048					
5049					$.ajax({
5050						url : "/ajax/ajaxFeedBack.php",
5051						type: 'POST',
5052						dataType: 'json',
5053						data: formData,
5054						cache : false,
5055						processData: false,
5056						contentType: false
5057					}).done(function(response) {
5058						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5059						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5060					});
5061				}
5062			}
5063			else
5064			{
5065				alert("Скрипт валидации ожидает значение name='form_type' поля");
5066			}
5067		});
5068	});
5069	
5070	// Отправка с валидацией Телефон, ФИО
5071	$('form.send-valid-fio-tel').each(function(){
5072		$(this).submit(function(event){
5073			event.preventDefault();
5074			let formData = new FormData(this);
5075			var $f = $(this);
5076			
5077			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5078			{
5079				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5080					var nameok = false;
5081					$f.find('input[name="name"]').addClass("is-invalid");
5082					$f.find('input[name="name"]').removeClass("is-valid");
5083					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5084				}
5085				else
5086				{
5087					var nameok = true;
5088				}
5089				
5090				if ( ($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5091					var telok = false;
5092					$f.find('input[name="phone"]').addClass("is-invalid");
5093					$f.find('input[name="phone"]').removeClass("is-valid");
5094					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5095				}
5096				else
5097				{
5098					var telok = true;
5099				}
5100				
5101				if ($f.find('input[name="agree"]').is(':checked')) {
5102					var agree = true;
5103				}
5104				else
5105				{
5106					var agree = false;
5107					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5108					$f.find('input[name="agree"]').addClass("is-invalid");
5109					$f.find('input[name="agree"]').removeClass("is-valid");
5110					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5111				}
5112				
5113				if ((agree==true) && (nameok==true) && (telok==true)) {
5114					$f.find('#formBody').hide();
5115					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5116					
5117					$.ajax({
5118						url : "/ajax/ajaxFeedBack.php",
5119						type: 'POST',
5120						dataType: 'json',
5121						data: formData,
5122						cache : false,
5123						processData: false,
5124						contentType: false
5125					}).done(function(response) {
5126						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5127						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5128					});
5129				}
5130				
5131			}
5132			else
5133			{
5134				alert("Скрипт валидации ожидает значение name='form_type' поля");
5135			}
5136		});
5137	});
5138	
5139	// Отправка с валидацией только Email
5140	$('form.send-valid-email').each(function(){
5141		$(this).submit(function(event){
5142			event.preventDefault();
5143			let formData = new FormData(this);
5144			var $f = $(this);	
5145			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5146			{				
5147				var email = $.trim($f.find('input[name="email"]').val());
5148				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5149		
5150				if (reg.test(email) == false) {
5151					var mailok = false;
5152					$f.find('input[name="email"]').addClass("is-invalid");
5153					$f.find('input[name="email"]').removeClass("is-valid");
5154					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5155				}
5156				else{
5157					var mailok = true;
5158				}
5159
5160				if ($f.find('input[name="agree"]').is(':checked')) {
5161					var agree = true;
5162				}
5163				else
5164				{
5165					var agree = false;
5166					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5167					$f.find('input[name="agree"]').addClass("is-invalid");
5168					$f.find('input[name="agree"]').removeClass("is-valid");
5169					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5170				}
5171
5172				if ((agree==true) && (mailok==true)) {
5173					$f.find('#formBody').hide();
5174					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5175					
5176					$.ajax({
5177						url : "/ajax/ajaxFeedBack.php",
5178						type: 'POST',
5179						dataType: 'json',
5180						data: formData,
5181						cache : false,
5182						processData: false,
5183						contentType: false
5184					}).done(function(response) {
5185						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5186						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5187					});
5188				}
5189			}
5190			else
5191			{
5192				alert("Скрипт валидации ожидает значение name='form_type' поля");
5193			}
5194		});
5195	});
5196	
5197	// Отправка с валидацией Email, ФИО
5198	$('form.send-valid-fio-email').each(function(){
5199		$(this).submit(function(event){
5200			event.preventDefault();
5201			let formData = new FormData(this);
5202			var $f = $(this);	
5203			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5204			{
5205				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5206					var nameok = false;
5207					$f.find('input[name="name"]').addClass("is-invalid");
5208					$f.find('input[name="name"]').removeClass("is-valid");
5209					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5210				}
5211				else
5212				{
5213					var nameok = true;
5214				}
5215				
5216				var email = $.trim($f.find('input[name="email"]').val());
5217				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5218		
5219				if (reg.test(email) == false) {
5220					var mailok = false;
5221					$f.find('input[name="email"]').addClass("is-invalid");
5222					$f.find('input[name="email"]').removeClass("is-valid");
5223					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5224				}
5225				else{
5226					var mailok = true;
5227				}
5228				
5229				if ($f.find('input[name="agree"]').is(':checked')) {
5230					var agree = true;
5231				}
5232				else
5233				{
5234					var agree = false;
5235					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5236					$f.find('input[name="agree"]').addClass("is-invalid");
5237					$f.find('input[name="agree"]').removeClass("is-valid");
5238					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5239				}
5240
5241				if ((agree==true) && (nameok==true) && (mailok==true)) {
5242					$f.find('#formBody').hide();
5243					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5244					
5245					$.ajax({
5246						url : "/ajax/ajaxFeedBack.php",
5247						type: 'POST',
5248						dataType: 'json',
5249						data: formData,
5250						cache : false,
5251						processData: false,
5252						contentType: false
5253					}).done(function(response) {
5254						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5255						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5256					});
5257				}
5258			}
5259			else
5260			{
5261				alert("Скрипт валидации ожидает значение name='form_type' поля");
5262			}
5263		});
5264	});
5265	
5266	// Отправка с валидацией Телефона, Email, ФИО
5267	$('form.send-valid-fio-tel-email').each(function(){
5268		$(this).submit(function(event){
5269			event.preventDefault();
5270			let formData = new FormData(this);
5271			var $f = $(this);	
5272			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5273			{
5274				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5275					var nameok = false;
5276					$f.find('input[name="name"]').addClass("is-invalid");
5277					$f.find('input[name="name"]').removeClass("is-valid");
5278					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5279				}
5280				else
5281				{
5282					var nameok = true;
5283				}
5284				
5285				var email = $.trim($f.find('input[name="email"]').val());
5286				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5287		
5288				if (reg.test(email) == false) {
5289					var mailok = false;
5290					$f.find('input[name="email"]').addClass("is-invalid");
5291					$f.find('input[name="email"]').removeClass("is-valid");
5292					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5293				}
5294				else{
5295					var mailok = true;
5296				}
5297				
5298				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5299					var telok = false;
5300					$f.find('input[name="phone"]').addClass("is-invalid");
5301					$f.find('input[name="phone"]').removeClass("is-valid");
5302					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5303				}
5304				else
5305				{
5306					var telok = true;
5307				}
5308				
5309				if ($f.find('input[name="agree"]').is(':checked')) {
5310					var agree = true;
5311				}
5312				else
5313				{
5314					var agree = false;
5315					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5316					$f.find('input[name="agree"]').addClass("is-invalid");
5317					$f.find('input[name="agree"]').removeClass("is-valid");
5318					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5319				}
5320			
5321				if ((agree==true) && (nameok==true) && (mailok==true) && (telok==true)) {
5322					$f.find('#formBody').hide();
5323					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5324					
5325					$.ajax({
5326						url : "/ajax/ajaxFeedBack.php",
5327						type: 'POST',
5328						dataType: 'json',
5329						data: formData,
5330						cache : false,
5331						processData: false,
5332						contentType: false
5333					}).done(function(response) {
5334						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5335						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5336					});
5337				}
5338			}
5339			else
5340			{
5341				alert("Скрипт валидации ожидает значение name='form_type' поля");
5342			}
5343		});
5344	});
5345	
5346	// Отправка с валидацией Телефона, Email, ФИО, Сообщение
5347	$('form.send-valid-fio-tel-email-message').each(function(){
5348		$(this).submit(function(event){
5349			event.preventDefault();
5350			let formData = new FormData(this);
5351			var $f = $(this);	
5352			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5353			{
5354				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5355					var nameok = false;
5356					$f.find('input[name="name"]').addClass("is-invalid");
5357					$f.find('input[name="name"]').removeClass("is-valid");
5358					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5359				}
5360				else
5361				{
5362					var nameok = true;
5363				}
5364				
5365				var email = $.trim($f.find('input[name="email"]').val());
5366				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5367		
5368				if (reg.test(email) == false) {
5369					var mailok = false;
5370					$f.find('input[name="email"]').addClass("is-invalid");
5371					$f.find('input[name="email"]').removeClass("is-valid");
5372					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5373				}
5374				else{
5375					var mailok = true;
5376				}
5377				
5378				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5379					var telok = false;
5380					$f.find('input[name="phone"]').addClass("is-invalid");
5381					$f.find('input[name="phone"]').removeClass("is-valid");
5382					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5383				}
5384				else
5385				{
5386					var telok = true;
5387				}
5388				
5389				if (($f.find('textarea[name="message"]').val().length == 0) || ($f.find('textarea[name="message"]').val()=="")) {
5390					var messageok = false;
5391					$f.find('textarea[name="message"]').addClass("is-invalid");
5392					$f.find('textarea[name="message"]').removeClass("is-valid");
5393					$f.find('textarea[name="message"]').parent().find('.invalid-feedback').show();
5394				}
5395				else
5396				{
5397					var messageok = true;
5398				}
5399				
5400				if ($f.find('input[name="agree"]').is(':checked')) {
5401					var agree = true;
5402				}
5403				else
5404				{
5405					var agree = false;
5406					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5407					$f.find('input[name="agree"]').addClass("is-invalid");
5408					$f.find('input[name="agree"]').removeClass("is-valid");
5409					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5410				}
5411			
5412				if ((agree==true) && (nameok==true) && (mailok==true) && (telok==true) && (messageok==true)) {
5413					$f.find('#formBody').hide();
5414					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5415					
5416					$.ajax({
5417						url : "/ajax/ajaxFeedBack.php",
5418						type: 'POST',
5419						dataType: 'json',
5420						data: formData,
5421						cache : false,
5422						processData: false,
5423						contentType: false
5424					}).done(function(response) {
5425						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5426						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5427					});
5428				}
5429			}
5430			else
5431			{
5432				alert("Скрипт валидации ожидает значение name='form_type' поля");
5433			}
5434		});
5435	});
5436	
5437	// Отправка с валидацией Телефона, Email, ФИО, Город
5438	$('form.send-valid-fio-tel-email-city').each(function(){
5439		$(this).submit(function(event){
5440			event.preventDefault();
5441			let formData = new FormData(this);
5442			var $f = $(this);	
5443			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5444			{
5445				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5446					var nameok = false;
5447					$f.find('input[name="name"]').addClass("is-invalid");
5448					$f.find('input[name="name"]').removeClass("is-valid");
5449					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5450				}
5451				else
5452				{
5453					var nameok = true;
5454				}
5455				
5456				var email = $.trim($f.find('input[name="email"]').val());
5457				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5458		
5459				if (reg.test(email) == false) {
5460					var mailok = false;
5461					$f.find('input[name="email"]').addClass("is-invalid");
5462					$f.find('input[name="email"]').removeClass("is-valid");
5463					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5464				}
5465				else{
5466					var mailok = true;
5467				}
5468				
5469				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5470					var telok = false;
5471					$f.find('input[name="phone"]').addClass("is-invalid");
5472					$f.find('input[name="phone"]').removeClass("is-valid");
5473					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5474				}
5475				else
5476				{
5477					var telok = true;
5478				}
5479				
5480				if (($f.find('input[name="city"]').val().length == 0) || ($f.find('input[name="city"]').val()=="")) {
5481					var cityok = false;
5482					$f.find('input[name="city"]').addClass("is-invalid");
5483					$f.find('input[name="city"]').removeClass("is-valid");
5484					$f.find('input[name="city"]').parent().find('.invalid-feedback').show();
5485				}
5486				else
5487				{
5488					var cityok = true;
5489				}
5490				
5491				if ($f.find('input[name="agree"]').is(':checked')) {
5492					var agree = true;
5493				}
5494				else
5495				{
5496					var agree = false;
5497					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5498					$f.find('input[name="agree"]').addClass("is-invalid");
5499					$f.find('input[name="agree"]').removeClass("is-valid");
5500					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5501				}
5502			
5503				if ((agree==true) && (cityok==true) && (nameok==true) && (mailok==true) && (telok==true)) {
5504					$f.find('#formBody').hide();
5505					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5506					
5507					$.ajax({
5508						url : "/ajax/ajaxFeedBack.php",
5509						type: 'POST',
5510						dataType: 'json',
5511						data: formData,
5512						cache : false,
5513						processData: false,
5514						contentType: false
5515					}).done(function(response) {
5516						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5517						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5518					});
5519
5520				}
5521			}
5522			else
5523			{
5524				alert("Скрипт валидации ожидает значение name='form_type' поля");
5525			}
5526		});
5527	});
5528	
5529	// Отправка с валидацией Телефона, Email, ФИО, Компания
5530	$('form.send-valid-fio-tel-email-org').each(function(){
5531		$(this).submit(function(event){
5532			event.preventDefault();
5533			let formData = new FormData(this);
5534			var $f = $(this);	
5535			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5536			{
5537				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5538					var nameok = false;
5539					$f.find('input[name="name"]').addClass("is-invalid");
5540					$f.find('input[name="name"]').removeClass("is-valid");
5541					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5542				}
5543				else
5544				{
5545					var nameok = true;
5546				}
5547				
5548				var email = $.trim($f.find('input[name="email"]').val());
5549				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5550		
5551				if (reg.test(email) == false) {
5552					var mailok = false;
5553					$f.find('input[name="email"]').addClass("is-invalid");
5554					$f.find('input[name="email"]').removeClass("is-valid");
5555					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5556				}
5557				else{
5558					var mailok = true;
5559				}
5560				
5561				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5562					var telok = false;
5563					$f.find('input[name="phone"]').addClass("is-invalid");
5564					$f.find('input[name="phone"]').removeClass("is-valid");
5565					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5566				}
5567				else
5568				{
5569					var telok = true;
5570				}
5571				
5572				if (($f.find('input[name="org"]').val().length == 0) || ($f.find('input[name="org"]').val()=="")) {
5573					var orgok = false;
5574					$f.find('input[name="org"]').addClass("is-invalid");
5575					$f.find('input[name="org"]').removeClass("is-valid");
5576					$f.find('input[name="org"]').parent().find('.invalid-feedback').show();
5577				}
5578				else
5579				{
5580					var orgok = true;
5581				}
5582				
5583				if ($f.find('input[name="agree"]').is(':checked')) {
5584					var agree = true;
5585				}
5586				else
5587				{
5588					var agree = false;
5589					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5590					$f.find('input[name="agree"]').addClass("is-invalid");
5591					$f.find('input[name="agree"]').removeClass("is-valid");
5592					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5593				}
5594			
5595				if ((agree==true) && (orgok==true) && (nameok==true) && (mailok==true) && (telok==true)) {
5596					$f.find('#formBody').hide();
5597					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5598					
5599					$.ajax({
5600						url : "/ajax/ajaxFeedBack.php",
5601						type: 'POST',
5602						dataType: 'json',
5603						data: formData,
5604						cache : false,
5605						processData: false,
5606						contentType: false
5607					}).done(function(response) {
5608						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5609						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5610					});
5611
5612				}
5613			}
5614			else
5615			{
5616				alert("Скрипт валидации ожидает значение name='form_type' поля");
5617			}
5618		});
5619	});
5620	
5621	// Отправка с валидацией Телефона, Email, ФИО, Компания, Собщение
5622	$('form.send-valid-fio-tel-email-org-message').each(function(){
5623		$(this).submit(function(event){
5624			event.preventDefault();
5625			let formData = new FormData(this);
5626			var $f = $(this);	
5627			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5628			{
5629				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5630					var nameok = false;
5631					$f.find('input[name="name"]').addClass("is-invalid");
5632					$f.find('input[name="name"]').removeClass("is-valid");
5633					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5634				}
5635				else
5636				{
5637					var nameok = true;
5638				}
5639				
5640				var email = $.trim($f.find('input[name="email"]').val());
5641				var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,15})$/;
5642		
5643				if (reg.test(email) == false) {
5644					var mailok = false;
5645					$f.find('input[name="email"]').addClass("is-invalid");
5646					$f.find('input[name="email"]').removeClass("is-valid");
5647					$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5648				}
5649				else{
5650					var mailok = true;
5651				}
5652				
5653				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5654					var telok = false;
5655					$f.find('input[name="phone"]').addClass("is-invalid");
5656					$f.find('input[name="phone"]').removeClass("is-valid");
5657					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5658				}
5659				else
5660				{
5661					var telok = true;
5662				}
5663				
5664				if (($f.find('input[name="org"]').val().length == 0) || ($f.find('input[name="org"]').val()=="")) {
5665					var orgok = false;
5666					$f.find('input[name="org"]').addClass("is-invalid");
5667					$f.find('input[name="org"]').removeClass("is-valid");
5668					$f.find('input[name="org"]').parent().find('.invalid-feedback').show();
5669				}
5670				else
5671				{
5672					var orgok = true;
5673				}
5674				
5675				if (($f.find('textarea[name="message"]').val().length == 0) || ($f.find('textarea[name="message"]').val()=="")) {
5676					var messageok = false;
5677					$f.find('textarea[name="message"]').addClass("is-invalid");
5678					$f.find('textarea[name="message"]').removeClass("is-valid");
5679					$f.find('textarea[name="message"]').parent().find('.invalid-feedback').show();
5680				}
5681				else
5682				{
5683					var messageok = true;
5684				}
5685				
5686				if ($f.find('input[name="agree"]').is(':checked')) {
5687					var agree = true;
5688				}
5689				else
5690				{
5691					var agree = false;
5692					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5693					$f.find('input[name="agree"]').addClass("is-invalid");
5694					$f.find('input[name="agree"]').removeClass("is-valid");
5695					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5696				}
5697			
5698				if ((agree==true) && (orgok==true) && (nameok==true) && (mailok==true) && (telok==true) && (messageok==true)) {
5699					$f.find('#formBody').hide();
5700					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5701					
5702					$.ajax({
5703						url : "/ajax/ajaxFeedBack.php",
5704						type: 'POST',
5705						dataType: 'json',
5706						data: formData,
5707						cache : false,
5708						processData: false,
5709						contentType: false
5710					}).done(function(response) {
5711						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5712						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5713					});
5714
5715				}
5716			}
5717			else
5718			{
5719				alert("Скрипт валидации ожидает значение name='form_type' поля");
5720			}
5721		});
5722	});
5723	
5724	// Отправка с валидацией ФИО, Телефон, Должность, Компания, Сообщение
5725	$('form.send-valid-fio-tel-pos-org-message').each(function(){
5726		$(this).submit(function(event){
5727			event.preventDefault();
5728			let formData = new FormData(this);
5729			var $f = $(this);	
5730			if(($f.find('input[name="form_type"]').length) && ($f.find('input[name="form_type"]').val().length != 0))
5731			{
5732				if (($f.find('input[name="name"]').val().length == 0) || ($f.find('input[name="name"]').val()=="")) {
5733					var nameok = false;
5734					$f.find('input[name="name"]').addClass("is-invalid");
5735					$f.find('input[name="name"]').removeClass("is-valid");
5736					$f.find('input[name="name"]').parent().find('.invalid-feedback').show();
5737				}
5738				else
5739				{
5740					var nameok = true;
5741				}
5742				
5743				if (($f.find('input[name="phone"]').val()=="+7 (___) ___-__-__") || ($f.find('input[name="phone"]').val()=="")) {
5744					var telok = false;
5745					$f.find('input[name="phone"]').addClass("is-invalid");
5746					$f.find('input[name="phone"]').removeClass("is-valid");
5747					$f.find('input[name="phone"]').parent().find('.invalid-feedback').show();
5748				}
5749				else
5750				{
5751					var telok = true;
5752				}
5753				
5754				if (($f.find('input[name="pos"]').val().length == 0) || ($f.find('input[name="pos"]').val()=="")) {
5755					var nameok = false;
5756					$f.find('input[name="pos"]').addClass("is-invalid");
5757					$f.find('input[name="pos"]').removeClass("is-valid");
5758					$f.find('input[name="pos"]').parent().find('.invalid-feedback').show();
5759				}
5760				else
5761				{
5762					var posok = true;
5763				}
5764				
5765				if (($f.find('input[name="org"]').val().length == 0) || ($f.find('input[name="org"]').val()=="")) {
5766					var orgok = false;
5767					$f.find('input[name="org"]').addClass("is-invalid");
5768					$f.find('input[name="org"]').removeClass("is-valid");
5769					$f.find('input[name="org"]').parent().find('.invalid-feedback').show();
5770				}
5771				else
5772				{
5773					var orgok = true;
5774				}
5775				
5776				if (($f.find('textarea[name="message"]').val().length == 0) || ($f.find('textarea[name="message"]').val()=="")) {
5777					var orgok = false;
5778					$f.find('textarea[name="message"]').addClass("is-invalid");
5779					$f.find('textarea[name="message"]').removeClass("is-valid");
5780					$f.find('textarea[name="message"]').parent().find('.invalid-feedback').show();
5781				}
5782				else
5783				{
5784					var messageok = true;
5785				}
5786				
5787				if ($f.find('input[name="agree"]').is(':checked')) {
5788					var agree = true;
5789				}
5790				else
5791				{
5792					var agree = false;
5793					$f.find('input[name="agree"]').css("box-shadow", "inset 0px 0px 5px 1px red");
5794					$f.find('input[name="agree"]').addClass("is-invalid");
5795					$f.find('input[name="agree"]').removeClass("is-valid");
5796					$f.find('input[name="agree"]').parent().find('.invalid-feedback').show();
5797				}
5798			
5799				if ((agree==true) && (orgok==true) && (nameok==true) && (posok==true) && (telok==true) && (messageok==true)) {
5800					$f.find('#formBody').hide();
5801					$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5802					
5803					$.ajax({
5804						url : "/ajax/ajaxFeedBack.php",
5805						type: 'POST',
5806						dataType: 'json',
5807						data: formData,
5808						cache : false,
5809						processData: false,
5810						contentType: false
5811					}).done(function(response) {
5812						$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5813						yandexMetrikaTarget($f.find('input[name="form_type"]').val());
5814					});
5815
5816				}
5817			}
5818			else
5819			{
5820				alert("Скрипт валидации ожидает значение name='form_type' поля");
5821			}
5822		});
5823	});
5824	
5825	///// ТОДО все что ниже потом переделать под верхние вызовы и стереть
5826	
5827	// Обратный звонок (моб версия)
5828	$('#formMobCallback').submit(function(){
5829		var $f = $(this);	
5830		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
5831			var nameok = false;
5832			$f.find('#name').addClass("is-invalid");
5833			$f.find('#name').removeClass("is-valid");
5834			$f.find('#name').parent().find('.invalid-feedback').show();
5835		}
5836		else
5837		{
5838			var nameok = true;
5839			$f.find('#name').addClass("is-valid");
5840			$f.find('#name').removeClass("is-invalid");
5841			$f.find('#name').parent().find('.invalid-feedback').hide();
5842		}
5843		
5844		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
5845			var telok = false;
5846			$f.find('#tel').addClass("is-invalid");
5847			$f.find('#tel').removeClass("is-valid");
5848			$f.find('#tel').parent().find('.invalid-feedback').show();
5849		}
5850		else
5851		{
5852			var telok = true;
5853			$f.find('#tel').addClass("is-valid");
5854			$f.find('#tel').removeClass("is-invalid");
5855			$f.find('#tel').parent().find('.invalid-feedback').hide();
5856		}
5857		
5858		if ((nameok==true) && (telok==true)) {
5859			$f.find('#formBody').hide();
5860			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5861			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
5862				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5863				ym(33105028,'reachGoal','users_form');
5864			});
5865		}
5866		return false;
5867	});
5868	
5869	// Задать вопрос (моб версия)
5870	$('#formMobAsk').submit(function(){
5871		var $f = $(this);	
5872		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
5873			var nameok = false;
5874			$f.find('#name').addClass("is-invalid");
5875			$f.find('#name').removeClass("is-valid");
5876			$f.find('#name').parent().find('.invalid-feedback').show();
5877		}
5878		else
5879		{
5880			var nameok = true;
5881			$f.find('#name').addClass("is-valid");
5882			$f.find('#name').removeClass("is-invalid");
5883			$f.find('#name').parent().find('.invalid-feedback').hide();
5884		}
5885		
5886		var email = $.trim($f.find('input[name="email"]').val());
5887		if (email.length < 2 || email.indexOf('@') < 1) {
5888			var mailok = false;
5889			$f.find('input[name="email"]').addClass("is-invalid");
5890			$f.find('input[name="email"]').removeClass("is-valid");
5891			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
5892		}
5893		else{
5894			var mailok = true;
5895			$f.find('input[name="email"]').addClass("is-valid");
5896			$f.find('input[name="email"]').removeClass("is-invalid");
5897			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
5898		}
5899		
5900		if ((nameok==true) && (mailok==true)) {
5901			$f.find('#formBody').hide();
5902			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5903			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
5904				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5905				ym(33105028,'reachGoal','users_form');
5906			});
5907		}
5908		return false;
5909	});
5910	
5911	// Видеоконсультация со специалистом (моб версия)
5912	$('#formMobCamera').submit(function(){
5913		var $f = $(this);	
5914		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
5915			var nameok = false;
5916			$f.find('#name').addClass("is-invalid");
5917			$f.find('#name').removeClass("is-valid");
5918			$f.find('#name').parent().find('.invalid-feedback').show();
5919		}
5920		else
5921		{
5922			var nameok = true;
5923			$f.find('#name').addClass("is-valid");
5924			$f.find('#name').removeClass("is-invalid");
5925			$f.find('#name').parent().find('.invalid-feedback').hide();
5926		}
5927		
5928		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
5929			var telok = false;
5930			$f.find('#tel').addClass("is-invalid");
5931			$f.find('#tel').removeClass("is-valid");
5932			$f.find('#tel').parent().find('.invalid-feedback').show();
5933		}
5934		else
5935		{
5936			var telok = true;
5937			$f.find('#tel').addClass("is-valid");
5938			$f.find('#tel').removeClass("is-invalid");
5939			$f.find('#tel').parent().find('.invalid-feedback').hide();
5940		}
5941		
5942		if ((nameok==true) && (telok==true)) {
5943			$f.find('#formBody').hide();
5944			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5945			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
5946				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5947				ym(33105028,'reachGoal','users_form');
5948			});
5949		}
5950		return false;
5951	});
5952
5953	
5954	
5955	// Предзаказ
5956	$('#modalPredzakaz').on('show.bs.modal', function (event) {
5957		var button = event.relatedTarget;
5958		var prod = button.getAttribute('data-bs-product');
5959		$('#modalPredzakaz').find('input[name="form_product"]').val(prod);
5960	});
5961	
5962	$('#formPreorder').submit(function(){
5963		var $f = $(this);	
5964		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
5965			var nameok = false;
5966			$f.find('#name').addClass("is-invalid");
5967			$f.find('#name').removeClass("is-valid");
5968			$f.find('#name').parent().find('.invalid-feedback').show();
5969		}
5970		else
5971		{
5972			var nameok = true;
5973			$f.find('#name').addClass("is-valid");
5974			$f.find('#name').removeClass("is-invalid");
5975			$f.find('#name').parent().find('.invalid-feedback').hide();
5976		}
5977		
5978		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
5979			var telok = false;
5980			$f.find('#tel').addClass("is-invalid");
5981			$f.find('#tel').removeClass("is-valid");
5982			$f.find('#tel').parent().find('.invalid-feedback').show();
5983		}
5984		else
5985		{
5986			var telok = true;
5987			$f.find('#tel').addClass("is-valid");
5988			$f.find('#tel').removeClass("is-invalid");
5989			$f.find('#tel').parent().find('.invalid-feedback').hide();
5990		}
5991		
5992		if ((nameok==true) && (telok==true)) {
5993			$f.find('#formBody').hide();
5994			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
5995			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
5996				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
5997				ym(33105028,'reachGoal','users_form');
5998			});
5999		}
6000		return false;
6001	});
6002
6003	// Витрина дилера: зарезервировать
6004	$('#modalReservDealer').on('show.bs.modal', function (event) {
6005		var button = event.relatedTarget;
6006		var prod = button.getAttribute('data-bs-product');
6007		var price = button.getAttribute('data-bs-price');
6008		var recipients = button.getAttribute('data-bs-recipients');
6009		var shop = button.getAttribute('data-bs-shop');
6010		$('#modalReservDealer').find('input[name="form_product"]').val(prod);
6011		$('#modalReservDealer').find('input[name="form_price"]').val(price);
6012		$('#modalReservDealer').find('input[name="form_recipients"]').val(recipients);
6013		$('#modalReservDealer').find('input[name="form_shop"]').val(shop);
6014	});
6015	
6016	$('#formReservDealer').submit(function(){
6017		var $f = $(this);	
6018		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6019			var nameok = false;
6020			$f.find('#name').addClass("is-invalid");
6021			$f.find('#name').removeClass("is-valid");
6022			$f.find('#name').parent().find('.invalid-feedback').show();
6023		}
6024		else
6025		{
6026			var nameok = true;
6027			$f.find('#name').addClass("is-valid");
6028			$f.find('#name').removeClass("is-invalid");
6029			$f.find('#name').parent().find('.invalid-feedback').hide();
6030		}
6031		
6032		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6033			var telok = false;
6034			$f.find('#tel').addClass("is-invalid");
6035			$f.find('#tel').removeClass("is-valid");
6036			$f.find('#tel').parent().find('.invalid-feedback').show();
6037		}
6038		else
6039		{
6040			var telok = true;
6041			$f.find('#tel').addClass("is-valid");
6042			$f.find('#tel').removeClass("is-invalid");
6043			$f.find('#tel').parent().find('.invalid-feedback').hide();
6044		}
6045		
6046		if ((nameok==true) && (telok==true)) {
6047			$f.find('#formBody').hide();
6048			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6049			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6050				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6051				ym(33105028,'reachGoal','users_form');
6052			});
6053		}
6054		return false;
6055	});
6056
6057	// Сервисы по Роботам Установка
6058	$('#formServiseRobotUst').submit(function(){
6059		
6060		var $f = $(this);
6061		
6062		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6063			var nameok = false;
6064			$f.find('#name').addClass("is-invalid");
6065			$f.find('#name').removeClass("is-valid");
6066			$f.find('#name').parent().find('.invalid-feedback').show();
6067		}
6068		else
6069		{
6070			var nameok = true;
6071			$f.find('#name').addClass("is-valid");
6072			$f.find('#name').removeClass("is-invalid");
6073			$f.find('#name').parent().find('.invalid-feedback').hide();
6074		}
6075		
6076		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6077			var telok = false;
6078			$f.find('#tel').addClass("is-invalid");
6079			$f.find('#tel').removeClass("is-valid");
6080			$f.find('#tel').parent().find('.invalid-feedback').show();
6081		}
6082		else
6083		{
6084			var telok = true;
6085			$f.find('#tel').addClass("is-valid");
6086			$f.find('#tel').removeClass("is-invalid");
6087			$f.find('#tel').parent().find('.invalid-feedback').hide();
6088		}
6089		
6090		var email = $.trim($f.find('input[name="email"]').val());
6091		if (email.length < 2 || email.indexOf('@') < 1) {
6092			var mailok = false;
6093			$f.find('input[name="email"]').addClass("is-invalid");
6094			$f.find('input[name="email"]').removeClass("is-valid");
6095			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6096		}
6097		else{
6098			var mailok = true;
6099			$f.find('input[name="email"]').addClass("is-valid");
6100			$f.find('input[name="email"]').removeClass("is-invalid");
6101			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6102		}
6103		
6104		if ((nameok==true) && (telok==true) && (mailok==true)) {
6105			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6106			$f.find('#formBody').hide();
6107			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6108				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6109				ym(33105028,'reachGoal','users_form');
6110			});
6111		}
6112		return false;
6113	});
6114	
6115	// Сервисы по Роботам Хранение
6116	$('#formServiseRobotHran').submit(function(){
6117		
6118		var $f = $(this);
6119		
6120		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6121			var nameok = false;
6122			$f.find('#name').addClass("is-invalid");
6123			$f.find('#name').removeClass("is-valid");
6124			$f.find('#name').parent().find('.invalid-feedback').show();
6125		}
6126		else
6127		{
6128			var nameok = true;
6129			$f.find('#name').addClass("is-valid");
6130			$f.find('#name').removeClass("is-invalid");
6131			$f.find('#name').parent().find('.invalid-feedback').hide();
6132		}
6133		
6134		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6135			var telok = false;
6136			$f.find('#tel').addClass("is-invalid");
6137			$f.find('#tel').removeClass("is-valid");
6138			$f.find('#tel').parent().find('.invalid-feedback').show();
6139		}
6140		else
6141		{
6142			var telok = true;
6143			$f.find('#tel').addClass("is-valid");
6144			$f.find('#tel').removeClass("is-invalid");
6145			$f.find('#tel').parent().find('.invalid-feedback').hide();
6146		}
6147		
6148		var email = $.trim($f.find('input[name="email"]').val());
6149		if (email.length < 2 || email.indexOf('@') < 1) {
6150			var mailok = false;
6151			$f.find('input[name="email"]').addClass("is-invalid");
6152			$f.find('input[name="email"]').removeClass("is-valid");
6153			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6154		}
6155		else{
6156			var mailok = true;
6157			$f.find('input[name="email"]').addClass("is-valid");
6158			$f.find('input[name="email"]').removeClass("is-invalid");
6159			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6160		}
6161		
6162		if ((nameok==true) && (telok==true) && (mailok==true)) {
6163			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6164			$f.find('#formBody').hide();
6165			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6166				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6167				ym(33105028,'reachGoal','users_form');
6168			});
6169		}
6170		return false;
6171	});
6172
6173	// Закажите услугу «Предпродажная подготовка»
6174	$('#formServisePredprodage').submit(function(){
6175		
6176		var $f = $(this);
6177		
6178		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6179			var nameok = false;
6180			$f.find('#name').addClass("is-invalid");
6181			$f.find('#name').removeClass("is-valid");
6182			$f.find('#name').parent().find('.invalid-feedback').show();
6183		}
6184		else
6185		{
6186			var nameok = true;
6187			$f.find('#name').addClass("is-valid");
6188			$f.find('#name').removeClass("is-invalid");
6189			$f.find('#name').parent().find('.invalid-feedback').hide();
6190		}
6191		
6192		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6193			var telok = false;
6194			$f.find('#tel').addClass("is-invalid");
6195			$f.find('#tel').removeClass("is-valid");
6196			$f.find('#tel').parent().find('.invalid-feedback').show();
6197		}
6198		else
6199		{
6200			var telok = true;
6201			$f.find('#tel').addClass("is-valid");
6202			$f.find('#tel').removeClass("is-invalid");
6203			$f.find('#tel').parent().find('.invalid-feedback').hide();
6204		}
6205		
6206		var email = $.trim($f.find('input[name="email"]').val());
6207		if (email.length < 2 || email.indexOf('@') < 1) {
6208			var mailok = false;
6209			$f.find('input[name="email"]').addClass("is-invalid");
6210			$f.find('input[name="email"]').removeClass("is-valid");
6211			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6212		}
6213		else{
6214			var mailok = true;
6215			$f.find('input[name="email"]').addClass("is-valid");
6216			$f.find('input[name="email"]').removeClass("is-invalid");
6217			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6218		}
6219		
6220		if ((nameok==true) && (telok==true) && (mailok==true)) {
6221			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6222			$f.find('#formBody').hide();
6223			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6224				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6225				ym(33105028,'reachGoal','users_form');
6226			});
6227		}
6228		return false;
6229	});
6230	
6231	// Закажите услугу «Выезд механика»
6232	$('#formServiseMex').submit(function(){
6233		
6234		var $f = $(this);
6235		
6236		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6237			var nameok = false;
6238			$f.find('#name').addClass("is-invalid");
6239			$f.find('#name').removeClass("is-valid");
6240			$f.find('#name').parent().find('.invalid-feedback').show();
6241		}
6242		else
6243		{
6244			var nameok = true;
6245			$f.find('#name').addClass("is-valid");
6246			$f.find('#name').removeClass("is-invalid");
6247			$f.find('#name').parent().find('.invalid-feedback').hide();
6248		}
6249		
6250		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6251			var telok = false;
6252			$f.find('#tel').addClass("is-invalid");
6253			$f.find('#tel').removeClass("is-valid");
6254			$f.find('#tel').parent().find('.invalid-feedback').show();
6255		}
6256		else
6257		{
6258			var telok = true;
6259			$f.find('#tel').addClass("is-valid");
6260			$f.find('#tel').removeClass("is-invalid");
6261			$f.find('#tel').parent().find('.invalid-feedback').hide();
6262		}
6263		
6264		var email = $.trim($f.find('input[name="email"]').val());
6265		if (email.length < 2 || email.indexOf('@') < 1) {
6266			var mailok = false;
6267			$f.find('input[name="email"]').addClass("is-invalid");
6268			$f.find('input[name="email"]').removeClass("is-valid");
6269			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6270		}
6271		else{
6272			var mailok = true;
6273			$f.find('input[name="email"]').addClass("is-valid");
6274			$f.find('input[name="email"]').removeClass("is-invalid");
6275			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6276		}
6277		
6278		if ((nameok==true) && (telok==true) && (mailok==true)) {
6279			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6280			$f.find('#formBody').hide();
6281			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6282				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6283				ym(33105028,'reachGoal','users_form');
6284			});
6285		}
6286		return false;
6287	});
6288
6289	// Подменная техника
6290	$('#formServicePodmen').submit(function(){
6291		
6292		var $f = $(this);
6293		
6294		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6295			var nameok = false;
6296			$f.find('#name').addClass("is-invalid");
6297			$f.find('#name').removeClass("is-valid");
6298			$f.find('#name').parent().find('.invalid-feedback').show();
6299		}
6300		else
6301		{
6302			var nameok = true;
6303			$f.find('#name').addClass("is-valid");
6304			$f.find('#name').removeClass("is-invalid");
6305			$f.find('#name').parent().find('.invalid-feedback').hide();
6306		}
6307		
6308		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6309			var telok = false;
6310			$f.find('#tel').addClass("is-invalid");
6311			$f.find('#tel').removeClass("is-valid");
6312			$f.find('#tel').parent().find('.invalid-feedback').show();
6313		}
6314		else
6315		{
6316			var telok = true;
6317			$f.find('#tel').addClass("is-valid");
6318			$f.find('#tel').removeClass("is-invalid");
6319			$f.find('#tel').parent().find('.invalid-feedback').hide();
6320		}
6321		
6322		var email = $.trim($f.find('input[name="email"]').val());
6323		if (email.length < 2 || email.indexOf('@') < 1) {
6324			var mailok = false;
6325			$f.find('input[name="email"]').addClass("is-invalid");
6326			$f.find('input[name="email"]').removeClass("is-valid");
6327			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6328		}
6329		else{
6330			var mailok = true;
6331			$f.find('input[name="email"]').addClass("is-valid");
6332			$f.find('input[name="email"]').removeClass("is-invalid");
6333			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6334		}
6335		
6336		if ((nameok==true) && (telok==true) && (mailok==true)) {
6337			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6338			$f.find('#formBody').hide();
6339			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6340				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6341				ym(33105028,'reachGoal','users_form');
6342			});
6343		}
6344		return false;
6345	});
6346	
6347	// Тест-драйв
6348	$('#formServiceTestDrive').submit(function(){
6349		
6350		var $f = $(this);
6351		
6352		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6353			var nameok = false;
6354			$f.find('#name').addClass("is-invalid");
6355			$f.find('#name').removeClass("is-valid");
6356			$f.find('#name').parent().find('.invalid-feedback').show();
6357		}
6358		else
6359		{
6360			var nameok = true;
6361			$f.find('#name').addClass("is-valid");
6362			$f.find('#name').removeClass("is-invalid");
6363			$f.find('#name').parent().find('.invalid-feedback').hide();
6364		}
6365		
6366		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6367			var telok = false;
6368			$f.find('#tel').addClass("is-invalid");
6369			$f.find('#tel').removeClass("is-valid");
6370			$f.find('#tel').parent().find('.invalid-feedback').show();
6371		}
6372		else
6373		{
6374			var telok = true;
6375			$f.find('#tel').addClass("is-valid");
6376			$f.find('#tel').removeClass("is-invalid");
6377			$f.find('#tel').parent().find('.invalid-feedback').hide();
6378		}
6379		
6380		var email = $.trim($f.find('input[name="email"]').val());
6381		if (email.length < 2 || email.indexOf('@') < 1) {
6382			var mailok = false;
6383			$f.find('input[name="email"]').addClass("is-invalid");
6384			$f.find('input[name="email"]').removeClass("is-valid");
6385			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6386		}
6387		else{
6388			var mailok = true;
6389			$f.find('input[name="email"]').addClass("is-valid");
6390			$f.find('input[name="email"]').removeClass("is-invalid");
6391			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6392		}
6393		
6394		if ((nameok==true) && (telok==true) && (mailok==true)) {
6395			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6396			$f.find('#formBody').hide();
6397			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6398				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6399				ym(33105028,'reachGoal','users_form');
6400			});
6401		}
6402		return false;
6403	});
6404	
6405	// Стать дилером
6406	$('#formNewDealer').submit(function(){
6407		var $f = $(this);
6408		if ($f.find('#name').val().length == 0) {
6409			
6410			var nameok = false;
6411			$f.find('#name').addClass("is-invalid");
6412			$f.find('#name').removeClass("is-valid");
6413			$f.find('#name').parent().find('.invalid-feedback').show();
6414
6415		}
6416		else
6417		{
6418			var nameok = true;
6419			$f.find('#name').addClass("is-valid");
6420			$f.find('#name').removeClass("is-invalid");
6421			$f.find('#name').parent().find('.invalid-feedback').hide();
6422		}
6423		
6424		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6425			var telok = false;
6426			$f.find('#tel').addClass("is-invalid");
6427			$f.find('#tel').removeClass("is-valid");
6428			$f.find('#tel').parent().find('.invalid-feedback').show();
6429		}
6430		else
6431		{
6432			var telok = true;
6433			$f.find('#tel').addClass("is-valid");
6434			$f.find('#tel').removeClass("is-invalid");
6435			$f.find('#tel').parent().find('.invalid-feedback').hide();
6436		}
6437		
6438		var email = $.trim($f.find('input[name="email"]').val());
6439		if (email.length < 2 || email.indexOf('@') < 1) {
6440			var mailok = false;
6441			$f.find('input[name="email"]').addClass("is-invalid");
6442			$f.find('input[name="email"]').removeClass("is-valid");
6443			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6444		}
6445		else{
6446			var mailok = true;
6447			$f.find('input[name="email"]').addClass("is-valid");
6448			$f.find('input[name="email"]').removeClass("is-invalid");
6449			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6450		}
6451		
6452		if ((nameok==true) && (telok==true) && (mailok==true)) {
6453			$f.find('#formBody').hide();
6454			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6455			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6456				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6457				ym(33105028,'reachGoal','users_form');
6458			});
6459		}		
6460		return false;
6461	});
6462	
6463	// Сервис ТО
6464	$('#formServiseTO').submit(function(){
6465		var $f = $(this);
6466		if ($f.find('#name').val().length == 0) {
6467			
6468			var nameok = false;
6469			$f.find('#name').addClass("is-invalid");
6470			$f.find('#name').removeClass("is-valid");
6471			$f.find('#name').parent().find('.invalid-feedback').show();
6472
6473		}
6474		else
6475		{
6476			var nameok = true;
6477			$f.find('#name').addClass("is-valid");
6478			$f.find('#name').removeClass("is-invalid");
6479			$f.find('#name').parent().find('.invalid-feedback').hide();
6480		}
6481		
6482		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6483			var telok = false;
6484			$f.find('#tel').addClass("is-invalid");
6485			$f.find('#tel').removeClass("is-valid");
6486			$f.find('#tel').parent().find('.invalid-feedback').show();
6487		}
6488		else
6489		{
6490			var telok = true;
6491			$f.find('#tel').addClass("is-valid");
6492			$f.find('#tel').removeClass("is-invalid");
6493			$f.find('#tel').parent().find('.invalid-feedback').hide();
6494		}
6495		
6496		var email = $.trim($f.find('input[name="email"]').val());
6497		if (email.length < 2 || email.indexOf('@') < 1) {
6498			var mailok = false;
6499			$f.find('input[name="email"]').addClass("is-invalid");
6500			$f.find('input[name="email"]').removeClass("is-valid");
6501			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6502		}
6503		else{
6504			var mailok = true;
6505			$f.find('input[name="email"]').addClass("is-valid");
6506			$f.find('input[name="email"]').removeClass("is-invalid");
6507			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6508		}
6509		
6510		if ((nameok==true) && (telok==true) && (mailok==true)) {
6511			$f.find('#formBody').hide();
6512			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6513			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6514				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6515				ym(33105028,'reachGoal','users_form');
6516			});
6517		}		
6518		return false;
6519	});
6520	
6521	// Testdrive
6522	$('#formTI').submit(function(){
6523		var $f = $(this);
6524		if ($f.find('#name').val().length == 0) {
6525			
6526			var nameok = false;
6527			$f.find('#name').addClass("is-invalid");
6528			$f.find('#name').removeClass("is-valid");
6529			$f.find('#name').parent().find('.invalid-feedback').show();
6530
6531		}
6532		else
6533		{
6534			var nameok = true;
6535			$f.find('#name').addClass("is-valid");
6536			$f.find('#name').removeClass("is-invalid");
6537			$f.find('#name').parent().find('.invalid-feedback').hide();
6538		}
6539		
6540		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6541			var telok = false;
6542			$f.find('#tel').addClass("is-invalid");
6543			$f.find('#tel').removeClass("is-valid");
6544			$f.find('#tel').parent().find('.invalid-feedback').show();
6545		}
6546		else
6547		{
6548			var telok = true;
6549			$f.find('#tel').addClass("is-valid");
6550			$f.find('#tel').removeClass("is-invalid");
6551			$f.find('#tel').parent().find('.invalid-feedback').hide();
6552		}
6553		
6554		var email = $.trim($f.find('input[name="email"]').val());
6555		if (email.length < 2 || email.indexOf('@') < 1) {
6556			var mailok = false;
6557			$f.find('input[name="email"]').addClass("is-invalid");
6558			$f.find('input[name="email"]').removeClass("is-valid");
6559			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6560		}
6561		else{
6562			var mailok = true;
6563			$f.find('input[name="email"]').addClass("is-valid");
6564			$f.find('input[name="email"]').removeClass("is-invalid");
6565			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6566		}
6567		
6568		if ((nameok==true) && (telok==true) && (mailok==true)) {
6569			$f.find('#formBody').hide();
6570			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6571			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6572				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6573				ym(33105028,'reachGoal','users_form');
6574			});
6575		}		
6576		return false;
6577	});
6578
6579	// Служба клиентского сервиса
6580	$('#formQualityService').submit(function(){
6581		
6582		var $f = $(this);
6583		
6584		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6585			var nameok = false;
6586			$f.find('#name').addClass("is-invalid");
6587			$f.find('#name').removeClass("is-valid");
6588			$f.find('#name').parent().find('.invalid-feedback').show();
6589		}
6590		else
6591		{
6592			var nameok = true;
6593			$f.find('#name').addClass("is-valid");
6594			$f.find('#name').removeClass("is-invalid");
6595			$f.find('#name').parent().find('.invalid-feedback').hide();
6596		}
6597		
6598		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6599			var telok = false;
6600			$f.find('#tel').addClass("is-invalid");
6601			$f.find('#tel').removeClass("is-valid");
6602			$f.find('#tel').parent().find('.invalid-feedback').show();
6603		}
6604		else
6605		{
6606			var telok = true;
6607			$f.find('#tel').addClass("is-valid");
6608			$f.find('#tel').removeClass("is-invalid");
6609			$f.find('#tel').parent().find('.invalid-feedback').hide();
6610		}
6611		
6612		var email = $.trim($f.find('input[name="email"]').val());
6613		if (email.length < 2 || email.indexOf('@') < 1) {
6614			var mailok = false;
6615			$f.find('input[name="email"]').addClass("is-invalid");
6616			$f.find('input[name="email"]').removeClass("is-valid");
6617			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6618		}
6619		else{
6620			var mailok = true;
6621			$f.find('input[name="email"]').addClass("is-valid");
6622			$f.find('input[name="email"]').removeClass("is-invalid");
6623			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6624		}
6625		
6626		if ((nameok==true) && (telok==true) && (mailok==true)) {
6627			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6628			$f.find('#formBody').hide();
6629			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6630				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6631				ym(33105028,'reachGoal','users_form');
6632			});
6633		}
6634		return false;
6635	});
6636	
6637	
6638	// Лендинг снегоуборщики
6639	$('#formSnow').submit(function(){
6640		var $f = $(this);
6641		
6642		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6643			var nameok = false;
6644			$f.find('#name').addClass("is-invalid");
6645			$f.find('#name').removeClass("is-valid");
6646			$f.find('#name').parent().find('.invalid-feedback').show();
6647		}
6648		else
6649		{
6650			var nameok = true;
6651			$f.find('#name').addClass("is-valid");
6652			$f.find('#name').removeClass("is-invalid");
6653			$f.find('#name').parent().find('.invalid-feedback').hide();
6654		}
6655		
6656		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6657			var telok = false;
6658			$f.find('#tel').addClass("is-invalid");
6659			$f.find('#tel').removeClass("is-valid");
6660			$f.find('#tel').parent().find('.invalid-feedback').show();
6661		}
6662		else
6663		{
6664			var telok = true;
6665			$f.find('#tel').addClass("is-valid");
6666			$f.find('#tel').removeClass("is-invalid");
6667			$f.find('#tel').parent().find('.invalid-feedback').hide();
6668		}
6669		
6670		if ((nameok==true) && (telok==true)) {
6671			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6672			$f.find('#formBody').hide();
6673			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6674				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6675				ym(33105028,'reachGoal','landing_form_snegouborchiki');
6676			});
6677		}
6678		return false;
6679	});
6680	
6681	// раздел: Бизнес - Задать вопросы - модалка
6682	$('#modalBusinessAsk').on('show.bs.modal', function (event) {
6683		var button = event.relatedTarget;
6684		var title = button.getAttribute('data-bs-title');
6685		$('#modalBusinessAsk').find('#header_text').html(title+' - задать вопрос');
6686		$('#modalBusinessAsk').find('input[name="form_title"]').val(title+' - задать вопрос');
6687	});
6688	
6689	$('#formBusinessAsk').submit(function(){
6690		var $f = $(this);	
6691		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6692			var nameok = false;
6693			$f.find('#name').addClass("is-invalid");
6694			$f.find('#name').removeClass("is-valid");
6695			$f.find('#name').parent().find('.invalid-feedback').show();
6696		}
6697		else
6698		{
6699			var nameok = true;
6700			$f.find('#name').addClass("is-valid");
6701			$f.find('#name').removeClass("is-invalid");
6702			$f.find('#name').parent().find('.invalid-feedback').hide();
6703		}
6704		
6705		if ( ($f.find('#tel').val()=="+7 (___) ___-__-__") || ($f.find('#tel').val()=="")) {
6706			var telok = false;
6707			$f.find('#tel').addClass("is-invalid");
6708			$f.find('#tel').removeClass("is-valid");
6709			$f.find('#tel').parent().find('.invalid-feedback').show();
6710		}
6711		else
6712		{
6713			var telok = true;
6714			$f.find('#tel').addClass("is-valid");
6715			$f.find('#tel').removeClass("is-invalid");
6716			$f.find('#tel').parent().find('.invalid-feedback').hide();
6717		}
6718		
6719		var email = $.trim($f.find('input[name="email"]').val());
6720		if (email.length < 2 || email.indexOf('@') < 1) {
6721			var mailok = false;
6722			$f.find('input[name="email"]').addClass("is-invalid");
6723			$f.find('input[name="email"]').removeClass("is-valid");
6724			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6725		}
6726		else{
6727			var mailok = true;
6728			$f.find('input[name="email"]').addClass("is-valid");
6729			$f.find('input[name="email"]').removeClass("is-invalid");
6730			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6731		}
6732		
6733		if ((nameok==true) && (telok==true) && (mailok==true)) {
6734			$f.find('#formBody').hide();
6735			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6736			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6737				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6738				ym(33105028,'reachGoal','users_form');
6739			});
6740		}
6741		return false;
6742	});
6743	
6744
6745	// раздел: Бизнес - Задать вопросы - подвал	
6746	$('#formBusinessAskFoother').submit(function(){
6747		var $f = $(this);	
6748		if (($f.find('#name').val().length == 0) || ($f.find('#name').val()=="")) {
6749			var nameok = false;
6750			$f.find('#name').addClass("is-invalid");
6751			$f.find('#name').removeClass("is-valid");
6752			$f.find('#name').parent().find('.invalid-feedback').show();
6753		}
6754		else
6755		{
6756			var nameok = true;
6757			$f.find('#name').addClass("is-valid");
6758			$f.find('#name').removeClass("is-invalid");
6759			$f.find('#name').parent().find('.invalid-feedback').hide();
6760		}
6761		
6762		var email = $.trim($f.find('input[name="email"]').val());
6763		if (email.length < 2 || email.indexOf('@') < 1) {
6764			var mailok = false;
6765			$f.find('input[name="email"]').addClass("is-invalid");
6766			$f.find('input[name="email"]').removeClass("is-valid");
6767			$f.find('input[name="email"]').parent().find('.invalid-feedback').show();
6768		}
6769		else{
6770			var mailok = true;
6771			$f.find('input[name="email"]').addClass("is-valid");
6772			$f.find('input[name="email"]').removeClass("is-invalid");
6773			$f.find('input[name="email"]').parent().find('.invalid-feedback').hide();
6774		}
6775		
6776		if ((nameok==true) && (mailok==true)) {
6777			$f.find('#formBody').hide();
6778			$f.find('#status').html('<div class="alert alert-warning">Идет отправка</div>');
6779			$.post("/ajax/ajaxFeedBack.php", $f.serialize(), function(r){
6780				$f.find('#status').html( '<div class="alert alert-success">Ваша заявка принята!</div>');
6781				ym(33105028,'reachGoal','users_form');
6782			});
6783		}
6784		return false;
6785	});
6786});
6787/* End */
6788;
6789; /* Start:"a:4:{s:4:"full";s:72:"/local/templates/CAIMAN_2025/assets/custom/js/dropFile.js?17542957422282";s:6:"source";s:57:"/local/templates/CAIMAN_2025/assets/custom/js/dropFile.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
6790document.querySelectorAll(".drop-zone__input").forEach((inputElement) => {
6791    const dropZoneElement = inputElement.closest(".drop-zone");
6792
6793    dropZoneElement.addEventListener("click", (e) => {
6794        inputElement.click();
6795    });
6796
6797    inputElement.addEventListener("change", (e) => {
6798        if (inputElement.files.length) {
6799            updateThumbnail(dropZoneElement, inputElement.files[0]);
6800        }
6801    });
6802
6803    dropZoneElement.addEventListener("dragover", (e) => {
6804        e.preventDefault();
6805        dropZoneElement.classList.add("drop-zone--over");
6806    });
6807
6808    ["dragleave", "dragend"].forEach((type) => {
6809        dropZoneElement.addEventListener(type, (e) => {
6810            dropZoneElement.classList.remove("drop-zone--over");
6811        });
6812    });
6813
6814    dropZoneElement.addEventListener("drop", (e) => {
6815        e.preventDefault();
6816
6817        if (e.dataTransfer.files.length) {
6818            inputElement.files = e.dataTransfer.files;
6819            updateThumbnail(dropZoneElement, e.dataTransfer.files[0]);
6820        }
6821
6822        dropZoneElement.classList.remove("drop-zone--over");
6823    });
6824});
6825
6826/**
6827 * Updates the thumbnail on a drop zone element.
6828 *
6829 * @param {HTMLElement} dropZoneElement
6830 * @param {File} file
6831 */
6832function updateThumbnail(dropZoneElement, file) {
6833    let thumbnailElement = dropZoneElement.querySelector(".drop-zone__thumb");
6834
6835    // First time - remove the prompt
6836    if (dropZoneElement.querySelector(".drop-zone__prompt")) {
6837        dropZoneElement.querySelector(".drop-zone__prompt").remove();
6838    }
6839
6840    // First time - there is no thumbnail element, so lets create it
6841    if (!thumbnailElement) {
6842        thumbnailElement = document.createElement("div");
6843        thumbnailElement.classList.add("drop-zone__thumb");
6844        dropZoneElement.appendChild(thumbnailElement);
6845    }
6846
6847    thumbnailElement.dataset.label = file.name;
6848
6849    // Show thumbnail for image files
6850    if (file.type.startsWith("image/")) {
6851        const reader = new FileReader();
6852
6853        reader.readAsDataURL(file);
6854        reader.onload = () => {
6855            thumbnailElement.style.backgroundImage = `url('${reader.result}')`;
6856        };
6857    } else {
6858        thumbnailElement.style.backgroundImage = null;
6859    }
6860}
6861
6862/* End */
6863;
6864; /* Start:"a:4:{s:4:"full";s:73:"/local/templates/CAIMAN_2025/assets/custom/js/digiLayer.js?17441215512174";s:6:"source";s:58:"/local/templates/CAIMAN_2025/assets/custom/js/digiLayer.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
6865// Создаем объект digiLayer, если его еще нет
6866if (!window.digiLayer) {
6867    window.digiLayer = {};
6868}
6869
6870// Добавляем функцию cartState в объект digiLayer
6871window.digiLayer.cartState = function() {
6872	var res;
6873	BX.ajax({
6874		url: '/ajax/digiajax.php',
6875		data: {'type': 'digiCartState'},
6876		method: 'POST',
6877		dataType: 'json',
6878		timeout: 30,
6879		async: false,
6880		processData: true,
6881		scriptsRunFirst: true,
6882		emulateOnload: true,
6883		start: true,
6884		cache: false,
6885		onsuccess: function(data){
6886		
6887			res = data;
6888
6889		},
6890		onfailure: function(){
6891
6892		}
6893	});
6894	return res;
6895};
6896
6897window.digiLayer.addToCart = function(p,a) {
6898
6899	var isAdded = false;
6900	BX.ajax({
6901		url: '/ajax/digiajax.php',
6902		data: {'type': 'digiAddToCart', 'prodid': p, 'ammount': a},
6903		method: 'POST',
6904		dataType: 'json',
6905		timeout: 30,
6906		async: false,
6907		processData: true,
6908		scriptsRunFirst: true,
6909		emulateOnload: true,
6910		start: true,
6911		cache: false,
6912		onsuccess: function(data){
6913				
6914			if(data['MSG']=="OK")
6915			{
6916				isAdded = true;
6917				reloadHeaderCart();
6918			}
6919			
6920		},
6921		onfailure: function(){
6922			
6923		}
6924	});
6925
6926
6927	// Promise
6928	var statusAddCart = new Promise(
6929		function (resolve, reject) {
6930			if (isAdded) {
6931				resolve(true); // Всё выполнено
6932			}
6933			else{
6934				resolve(false); // ошибка
6935			}
6936		}
6937	);
6938
6939	return statusAddCart;
6940};
6941
6942window.digiLayer.removeFromCart= function(p) {
6943
6944	var isRemoved = false;
6945	BX.ajax({
6946		url: '/ajax/digiajax.php',
6947		data: {'type': 'removeFromCart', 'prodid': p},
6948		method: 'POST',
6949		dataType: 'json',
6950		timeout: 30,
6951		async: false,
6952		processData: true,
6953		scriptsRunFirst: true,
6954		emulateOnload: true,
6955		start: true,
6956		cache: false,
6957		onsuccess: function(data){
6958				
6959			if(data['MSG']=="OK")
6960			{
6961				isRemoved = true;
6962			}
6963			
6964		},
6965		onfailure: function(){
6966			
6967		}
6968	});
6969
6970	// Promise
6971	var statusRemoveProdCart = new Promise(
6972		function (resolve, reject) {
6973			if (isRemoved) {
6974				resolve(true); // Всё выполнено
6975			}
6976			else{
6977				resolve(false); // ошибка
6978			}
6979		}
6980	);
6981
6982	return statusRemoveProdCart;
6983	
6984};
6985/* End */
6986;
6987; /* Start:"a:4:{s:4:"full";s:91:"/local/templates/CAIMAN_2025/assets/js_dadata/jquery.dadata.suggestions.js?1749474313162881";s:6:"source";s:74:"/local/templates/CAIMAN_2025/assets/js_dadata/jquery.dadata.suggestions.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
6988/**
6989 * DaData.ru Suggestions jQuery plugin, version 22.6.0
6990 *
6991 * DaData.ru Suggestions jQuery plugin is freely distributable under the terms of MIT-style license
6992 * Built on DevBridge Autocomplete for jQuery (https://github.com/devbridge/jQuery-Autocomplete)
6993 * For details, see https://github.com/hflabs/suggestions-jquery
6994 */
6995 
vendor: 92,855 bytes, lines 6995-10041
6995
6996(function (global, factory) {
6997	typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) :
6998	typeof define === 'function' && define.amd ? define(['jquery'], factory) :
6999	(factory(global.jQuery));
7000}(this, (function ($) { 'use strict';
7001
7002$ = $ && $.hasOwnProperty('default') ? $['default'] : $;
7003
7004/**
7005 * Утилиты для работы с типами.
7006 */
7007var lang_util = {
7008    /**
7009     * Проверяет, является ли аргумент массивом.
7010     */
7011    isArray: function(array) {
7012        return Array.isArray(array);
7013    },
7014
7015    /**
7016     * Проверяет, является ли аргумент функцией.
7017     */
7018    isFunction: function(it) {
7019        return Object.prototype.toString.call(it) === "[object Function]";
7020    },
7021
7022    /**
7023     * Проверяет, является ли аргумент пустым объектом ({}).
7024     */
7025    isEmptyObject: function(obj) {
7026        return Object.keys(obj).length === 0 && obj.constructor === Object;
7027    },
7028
7029    /**
7030     * Проверяет, является ли аргумент «обычным» объектом
7031     * (не undefiend, не null, не DOM-элемент)
7032     */
7033    isPlainObject: function(obj) {
7034        if (
7035            obj === undefined ||
7036            typeof obj !== "object" ||
7037            obj === null ||
7038            obj.nodeType ||
7039            obj === obj.window
7040        ) {
7041            return false;
7042        }
7043        if (
7044            obj.constructor &&
7045            !Object.prototype.hasOwnProperty.call(
7046                obj.constructor.prototype,
7047                "isPrototypeOf"
7048            )
7049        ) {
7050            return false;
7051        }
7052        return true;
7053    }
7054};
7055
7056/**
7057 * Утилиты для работы с коллекциями.
7058 */
7059var collection_util = {
7060    /**
7061     * Возвращает массив без пустых элементов
7062     */
7063    compact: function(array) {
7064        return array.filter(function(el) {
7065            return !!el;
7066        });
7067    },
7068
7069    /**
7070     * Итерирует по элементам массива или полям объекта.
7071     * Ведёт себя как $.each() - прерывает выполнение, если функция-обработчик возвращает false.
7072     * @param {Object|Array} obj - массив или объект
7073     * @param {eachCallback} callback - функция-обработчик
7074     */
7075    each: function(obj, callback) {
7076        if (Array.isArray(obj)) {
7077            obj.some(function(el, idx) {
7078                return callback(el, idx) === false;
7079            });
7080            return;
7081        }
7082        Object.keys(obj).some(function(key) {
7083            var value = obj[key];
7084            return callback(value, key) === false;
7085        });
7086    },
7087
7088    /**
7089     * Пересечение массивов: ([1,2,3,4], [2,4,5,6]) => [2,4]
7090     * Исходные массивы не меняются.
7091     */
7092    intersect: function(array1, array2) {
7093        var result = [];
7094        if (!Array.isArray(array1) || !Array.isArray(array2)) {
7095            return result;
7096        }
7097        return array1.filter(function(el) {
7098            return array2.indexOf(el) !== -1;
7099        });
7100    },
7101
7102    /**
7103     * Разность массивов: ([1,2,3,4], [2,4,5,6]) => [1,3]
7104     * Исходные массивы не меняются.
7105     */
7106    minus: function(array1, array2) {
7107        if (!array2 || array2.length === 0) {
7108            return array1;
7109        }
7110        return array1.filter(function(el) {
7111            return array2.indexOf(el) === -1;
7112        });
7113    },
7114
7115    /**
7116     * Обрачивает переданный объект в массив.
7117     * Если передан массив, возвращает его копию.
7118     */
7119    makeArray: function(arrayLike) {
7120        if (lang_util.isArray(arrayLike)) {
7121            return Array.prototype.slice.call(arrayLike);
7122        } else {
7123            return [arrayLike];
7124        }
7125    },
7126
7127    /**
7128     * Разность массивов с частичным совпадением элементов.
7129     * Если элемент второго массива включает в себя элемент первого,
7130     * элементы считаются равными.
7131     */
7132    minusWithPartialMatching: function(array1, array2) {
7133        if (!array2 || array2.length === 0) {
7134            return array1;
7135        }
7136        return array1.filter(function(el) {
7137            return !array2.some(function(el2) {
7138                return el2.indexOf(el) === 0;
7139            });
7140        });
7141    },
7142
7143    /**
7144     * Копирует массив, начиная с указанного элемента.
7145     * @param obj - массив
7146     * @param start - индекс, начиная с которого надо скопировать
7147     */
7148    slice: function(obj, start) {
7149        return Array.prototype.slice.call(obj, start);
7150    }
7151};
7152
7153/**
7154 * Утилиты для работы с функциями.
7155 */
7156var func_util = {
7157    /**
7158     * Выполняет функцию с указанной задержкой.
7159     * @param {Function} handler - функция
7160     * @param {number} delay - задержка в миллисекундах
7161     */
7162    delay: function(handler, delay) {
7163        return setTimeout(handler, delay || 0);
7164    }
7165};
7166
7167/**
7168 * Утилиты для работы с объектами.
7169 */
7170var object_util = {
7171    /**
7172     * Сравнивает два объекта по полям, которые присутствуют в обоих
7173     * @returns {boolean} true, если поля совпадают, false в противном случае
7174     */
7175    areSame: function self(a, b) {
7176        var same = true;
7177
7178        if (typeof a != typeof b) {
7179            return false;
7180        }
7181
7182        if (typeof a == "object" && a != null && b != null) {
7183            collection_util.each(a, function(value, i) {
7184                return (same = self(value, b[i]));
7185            });
7186            return same;
7187        }
7188
7189        return a === b;
7190    },
7191
7192    /**
7193     * Копирует свойства и их значения из исходных объектов в целевой
7194     */
7195    assign: function(target, varArgs) {
7196        if (typeof Object.assign === "function") {
7197            return Object.assign.apply(null, arguments);
7198        }
7199        if (target == null) {
7200            // TypeError if undefined or null
7201            throw new TypeError("Cannot convert undefined or null to object");
7202        }
7203
7204        var to = Object(target);
7205
7206        for (var index = 1; index < arguments.length; index++) {
7207            var nextSource = arguments[index];
7208
7209            if (nextSource != null) {
7210                // Skip over if undefined or null
7211                for (var nextKey in nextSource) {
7212                    // Avoid bugs when hasOwnProperty is shadowed
7213                    if (
7214                        Object.prototype.hasOwnProperty.call(
7215                            nextSource,
7216                            nextKey
7217                        )
7218                    ) {
7219                        to[nextKey] = nextSource[nextKey];
7220                    }
7221                }
7222            }
7223        }
7224        return to;
7225    },
7226
7227    /**
7228     * Клонирует объект глубоким копированием
7229     */
7230    clone: function(obj) {
7231        return JSON.parse(JSON.stringify(obj));
7232    },
7233
7234    /**
7235     * Возвращает копию объекта без пустых полей
7236     * (без undefined, null и '')
7237     * @param obj
7238     */
7239    compact: function(obj) {
7240        var copy = object_util.clone(obj);
7241
7242        collection_util.each(copy, function(val, key) {
7243            if (val === null || val === undefined || val === "") {
7244                delete copy[key];
7245            }
7246        });
7247
7248        return copy;
7249    },
7250
7251    /**
7252     * Проверяет, что указанные поля в объекте заполнены.
7253     * @param {Object} obj - проверяемый объект
7254     * @param {Array} fields - список названий полей, которые надо проверить
7255     * @returns {boolean}
7256     */
7257    fieldsAreNotEmpty: function(obj, fields) {
7258        if (!lang_util.isPlainObject(obj)) {
7259            return false;
7260        }
7261        var result = true;
7262        collection_util.each(fields, function(field, i) {
7263            result = !!obj[field];
7264            return result;
7265        });
7266        return result;
7267    },
7268
7269    /**
7270     * Возвращает вложенное значение по указанному пути
7271     * например, 'data.address.value'
7272     */
7273    getDeepValue: function self(obj, name) {
7274        var path = name.split("."),
7275            step = path.shift();
7276
7277        return (
7278            obj && (path.length ? self(obj[step], path.join(".")) : obj[step])
7279        );
7280    },
7281
7282    /**
7283     * Возвращает карту объектов по их идентификаторам.
7284     * Принимает на вход массив объектов и идентифицирующее поле.
7285     * Возвращает карты, ключом в которой является значение идентифицирующего поля,
7286     *   а значением — исходный объект.
7287     * Заодно добавляет объектам поле с порядковым номером.
7288     * @param {Array} objectsArray - массив объектов
7289     * @param {string} idField - название идентифицирующего поля
7290     * @param {string} indexField - название поля с порядковым номером
7291     * @return {Object} карта объектов по их идентификаторам
7292     */
7293    indexObjectsById: function(objectsArray, idField, indexField) {
7294        var result = {};
7295
7296        collection_util.each(objectsArray, function(obj, idx) {
7297            var key = obj[idField];
7298            var val = {};
7299
7300            if (indexField) {
7301                val[indexField] = idx;
7302            }
7303
7304            result[key] = object_util.assign(val, obj);
7305        });
7306
7307        return result;
7308    }
7309};
7310
7311var KEYS = {
7312    ENTER: 13,
7313    ESC: 27,
7314    TAB: 9,
7315    SPACE: 32,
7316    UP: 38,
7317    DOWN: 40
7318};
7319
7320var CLASSES = {
7321    hint: "suggestions-hint",
7322    mobile: "suggestions-mobile",
7323    nowrap: "suggestions-nowrap",
7324    promo: "suggestions-promo",
7325    selected: "suggestions-selected",
7326    suggestion: "suggestions-suggestion",
7327    subtext: "suggestions-subtext",
7328    subtext_inline: "suggestions-subtext suggestions-subtext_inline",
7329    subtext_delimiter: "suggestions-subtext-delimiter",
7330    subtext_label: "suggestions-subtext suggestions-subtext_label",
7331    removeConstraint: "suggestions-remove",
7332    value: "suggestions-value"
7333};
7334
7335var EVENT_NS = ".suggestions";
7336var DATA_ATTR_KEY = "suggestions";
7337var WORD_DELIMITERS = "\\s\"'~\\*\\.,:\\|\\[\\]\\(\\)\\{\\}<>№";
7338var WORD_PARTS_DELIMITERS = "\\-\\+\\\\\\?!@#$%^&";
7339
7340/**
7341 * Утилиты для работы с текстом.
7342 */
7343
7344var WORD_SPLITTER = new RegExp("[" + WORD_DELIMITERS + "]+", "g");
7345var WORD_PARTS_SPLITTER = new RegExp("[" + WORD_PARTS_DELIMITERS + "]+", "g");
7346
7347var text_util = {
7348    /**
7349     * Заменяет амперсанд, угловые скобки и другие подобные символы
7350     * на HTML-коды
7351     */
7352    escapeHtml: function(str) {
7353        var map = {
7354            "&": "&amp;",
7355            "<": "&lt;",
7356            ">": "&gt;",
7357            '"': "&quot;",
7358            "'": "&#x27;",
7359            "/": "&#x2F;"
7360        };
7361
7362        if (str) {
7363            collection_util.each(map, function(html, ch) {
7364                str = str.replace(new RegExp(ch, "g"), html);
7365            });
7366        }
7367        return str;
7368    },
7369
7370    /**
7371     * Эскейпирует символы RegExp-шаблона обратным слешем
7372     * (для передачи в конструктор регулярных выражений)
7373     */
7374    escapeRegExChars: function(value) {
7375        return value.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
7376    },
7377
7378    /**
7379     * Приводит слово к нижнему регистру и заменяет ё → е
7380     */
7381    formatToken: function(token) {
7382        return token && token.toLowerCase().replace(/[ёЁ]/g, "е");
7383    },
7384
7385    /**
7386     * Возвращает регулярное выражение для разбивки строки на слова
7387     */
7388    getWordExtractorRegExp: function() {
7389        return new RegExp(
7390            "([^" + WORD_DELIMITERS + "]*)([" + WORD_DELIMITERS + "]*)",
7391            "g"
7392        );
7393    },
7394
7395    /**
7396     * Вырезает из строки стоп-слова
7397     */
7398    normalize: function(str, stopwords) {
7399        return text_util.split(str, stopwords).join(" ");
7400    },
7401
7402    /**
7403     * Добивает строку указанным символов справа до указанной длины
7404     * @param sourceString  исходная строка
7405     * @param targetLength  до какой длины добивать
7406     * @param padString  каким символом добивать
7407     * @returns строка указанной длины
7408     */
7409    padEnd: function(sourceString, targetLength, padString) {
7410        if (String.prototype.padEnd) {
7411            return sourceString.padEnd(targetLength, padString);
7412        }
7413        targetLength = targetLength >> 0; //floor if number or convert non-number to 0;
7414        padString = String(typeof padString !== "undefined" ? padString : " ");
7415        if (sourceString.length > targetLength) {
7416            return String(sourceString);
7417        } else {
7418            targetLength = targetLength - sourceString.length;
7419            if (targetLength > padString.length) {
7420                padString += padString.repeat(targetLength / padString.length); //append to original to ensure we are longer than needed
7421            }
7422            return String(sourceString) + padString.slice(0, targetLength);
7423        }
7424    },
7425
7426    /**
7427     * Нормализует строку, разбивает на слова,
7428     * отсеивает стоп-слова из списка.
7429     * Расклеивает буквы и цифры, написанные слитно.
7430     */
7431    split: function(str, stopwords) {
7432        var cleanStr = str
7433            .toLowerCase()
7434            .replace("ё", "е")
7435            .replace(/(\d+)([а-я]{2,})/g, "$1 $2")
7436            .replace(/([а-я]+)(\d+)/g, "$1 $2");
7437
7438        var words = collection_util.compact(cleanStr.split(WORD_SPLITTER));
7439        if (!words.length) {
7440            return [];
7441        }
7442        var lastWord = words.pop();
7443        var goodWords = collection_util.minus(words, stopwords);
7444        goodWords.push(lastWord);
7445        return goodWords;
7446    },
7447
7448    /**
7449     * Заменяет слова на составные части.
7450     * В отличие от withSubTokens, не сохраняет исходные слова.
7451     */
7452    splitTokens: function(tokens) {
7453        var result = [];
7454        collection_util.each(tokens, function(token, i) {
7455            var subtokens = token.split(WORD_PARTS_SPLITTER);
7456            result = result.concat(collection_util.compact(subtokens));
7457        });
7458        return result;
7459    },
7460
7461    /**
7462     * Проверяет, включает ли строка 1 строку 2.
7463     * Если строки равны, возвращает false.
7464     */
7465    stringEncloses: function(str1, str2) {
7466        return (
7467            str1.length > str2.length &&
7468            str1.toLowerCase().indexOf(str2.toLowerCase()) !== -1
7469        );
7470    },
7471
7472    /**
7473     * Возвращает список слов из строки.
7474     * При этом первыми по порядку идут «предпочтительные» слова
7475     * (те, что не входят в список «нежелательных»).
7476     * Составные слова тоже разбивает на части.
7477     * @param {string} value - строка
7478     * @param {Array} unformattableTokens - «нежелательные» слова
7479     * @return {Array} Массив атомарных слов
7480     */
7481    tokenize: function(value, unformattableTokens) {
7482        var tokens = collection_util.compact(
7483            text_util.formatToken(value).split(WORD_SPLITTER)
7484        );
7485        // Move unformattableTokens to the end.
7486        // This will help to apply them only if no other tokens match
7487        var preferredTokens = collection_util.minus(
7488            tokens,
7489            unformattableTokens
7490        );
7491        var otherTokens = collection_util.minus(tokens, preferredTokens);
7492        tokens = text_util.withSubTokens(preferredTokens.concat(otherTokens));
7493        return tokens;
7494    },
7495
7496    /**
7497     * Разбивает составные слова на части
7498     * и дописывает их к исходному массиву.
7499     * @param {Array} tokens - слова
7500     * @return {Array} Массив атомарных слов
7501     */
7502    withSubTokens: function(tokens) {
7503        var result = [];
7504        collection_util.each(tokens, function(token, i) {
7505            var subtokens = token.split(WORD_PARTS_SPLITTER);
7506            result.push(token);
7507            if (subtokens.length > 1) {
7508                result = result.concat(collection_util.compact(subtokens));
7509            }
7510        });
7511        return result;
7512    }
7513};
7514
7515/**
7516 * jQuery API.
7517 */
7518var jqapi = {
7519    Deferred: function() {
7520        return $.Deferred();
7521    },
7522
7523    ajax: function(settings) {
7524        return $.ajax(settings);
7525    },
7526
7527    extend: function() {
7528        return $.extend.apply(null, arguments);
7529    },
7530
7531    isJqObject: function(obj) {
7532        return obj instanceof $;
7533    },
7534
7535    param: function(obj) {
7536        return $.param(obj);
7537    },
7538
7539    proxy: function(func, context) {
7540        return $.proxy(func, context);
7541    },
7542
7543    select: function(selector) {
7544        return $(selector);
7545    },
7546
7547    supportsCors: function() {
7548        return $.support.cors;
7549    }
7550};
7551
7552/**
7553 * Утилиты для работы через AJAX
7554 */
7555var ajax = {
7556    /**
7557     * HTTP-метод, который поддерживает браузер
7558     */
7559    getDefaultType: function() {
7560        return jqapi.supportsCors() ? "POST" : "GET";
7561    },
7562
7563    /**
7564     * Content-type, который поддерживает браузер
7565     */
7566    getDefaultContentType: function() {
7567        return jqapi.supportsCors()
7568            ? "application/json"
7569            : "application/x-www-form-urlencoded";
7570    },
7571
7572    /**
7573     * Меняет HTTPS на протокол страницы, если браузер не поддерживает CORS
7574     */
7575    fixURLProtocol: function(url) {
7576        return jqapi.supportsCors()
7577            ? url
7578            : url.replace(/^https?:/, location.protocol);
7579    },
7580
7581    /**
7582     * Записывает параметры в GET-строку
7583     */
7584    addUrlParams: function(url, params) {
7585        return url + (/\?/.test(url) ? "&" : "?") + jqapi.param(params);
7586    },
7587
7588    /**
7589     * Сериализует объект для передачи по сети.
7590     * Либо в JSON-строку (если браузер поддерживает CORS),
7591     *   либо в GET-строку.
7592     */
7593    serialize: function(data) {
7594        if (jqapi.supportsCors()) {
7595            return JSON.stringify(data, function(key, value) {
7596                return value === null ? undefined : value;
7597            });
7598        } else {
7599            data = object_util.compact(data);
7600            return jqapi.param(data, true);
7601        }
7602    }
7603};
7604
7605/**
7606 * Возвращает автоинкрементный идентификатор.
7607 * @param {string} prefix - префикс для идентификатора
7608 */
7609var generateId = (function() {
7610    var counter = 0;
7611    return function(prefix) {
7612        return (prefix || "") + ++counter;
7613    };
7614})();
7615
7616/**
7617 * Утилиты на все случаи жизни.
7618 */
7619var utils = {
7620    escapeRegExChars: text_util.escapeRegExChars,
7621    escapeHtml: text_util.escapeHtml,
7622    formatToken: text_util.formatToken,
7623    normalize: text_util.normalize,
7624    reWordExtractor: text_util.getWordExtractorRegExp,
7625    stringEncloses: text_util.stringEncloses,
7626
7627    addUrlParams: ajax.addUrlParams,
7628    getDefaultContentType: ajax.getDefaultContentType,
7629    getDefaultType: ajax.getDefaultType,
7630    fixURLProtocol: ajax.fixURLProtocol,
7631    serialize: ajax.serialize,
7632
7633    arrayMinus: collection_util.minus,
7634    arrayMinusWithPartialMatching: collection_util.minusWithPartialMatching,
7635    arraysIntersection: collection_util.intersect,
7636    compact: collection_util.compact,
7637    each: collection_util.each,
7638    makeArray: collection_util.makeArray,
7639    slice: collection_util.slice,
7640
7641    delay: func_util.delay,
7642
7643    areSame: object_util.areSame,
7644    compactObject: object_util.compact,
7645    getDeepValue: object_util.getDeepValue,
7646    fieldsNotEmpty: object_util.fieldsAreNotEmpty,
7647    indexBy: object_util.indexObjectsById,
7648
7649    isArray: lang_util.isArray,
7650    isEmptyObject: lang_util.isEmptyObject,
7651    isFunction: lang_util.isFunction,
7652    isPlainObject: lang_util.isPlainObject,
7653
7654    uniqueId: generateId
7655};
7656
7657var DEFAULT_OPTIONS = {
7658    $helpers: null,
7659    autoSelectFirst: false,
7660    containerClass: "suggestions-suggestions",
7661    count: 5,
7662    deferRequestBy: 100,
7663    enrichmentEnabled: true,
7664    formatResult: null,
7665    formatSelected: null,
7666    headers: null,
7667    hint: "Выберите вариант или продолжите ввод",
7668    initializeInterval: 100,
7669    language: null,
7670    minChars: 1,
7671    mobileWidth: 600,
7672    noCache: false,
7673    noSuggestionsHint: null,
7674    onInvalidateSelection: null,
7675    onSearchComplete: $.noop,
7676    onSearchError: $.noop,
7677    onSearchStart: $.noop,
7678    onSelect: null,
7679    onSelectNothing: null,
7680    onSuggestionsFetch: null,
7681    paramName: "query",
7682    params: {},
7683    preventBadQueries: false,
7684    requestMode: "suggest",
7685    scrollOnFocus: false,
7686    // основной url, может быть переопределен
7687    serviceUrl: "https://suggestions.dadata.ru/suggestions/api/4_1/rs",
7688    tabDisabled: false,
7689    timeout: 3000,
7690    triggerSelectOnBlur: true,
7691    triggerSelectOnEnter: true,
7692    triggerSelectOnSpace: false,
7693    type: null,
7694    // url, который заменяет serviceUrl + method + type
7695    // то есть, если он задан, то для всех запросов будет использоваться именно он
7696    // если не поддерживается cors то к url будут добавлены параметры ?token=...&version=...
7697    // и заменен протокол на протокол текущей страницы
7698    url: null
7699};
7700
7701/**
7702 * Factory to create same parent checker function
7703 * @param preprocessFn called on each value before comparison
7704 * @returns {Function} same parent checker function
7705 */
7706function sameParentChecker(preprocessFn) {
7707    return function(suggestions) {
7708        if (suggestions.length === 0) {
7709            return false;
7710        }
7711        if (suggestions.length === 1) {
7712            return true;
7713        }
7714
7715        var parentValue = preprocessFn(suggestions[0].value),
7716            aliens = suggestions.filter(function(suggestion) {
7717                return (
7718                    preprocessFn(suggestion.value).indexOf(parentValue) !== 0
7719                );
7720            });
7721
7722        return aliens.length === 0;
7723    };
7724}
7725
7726/**
7727 * Default same parent checker. Compares raw values.
7728 * @type {Function}
7729 */
7730var haveSameParent = sameParentChecker(function(val) {
7731    return val;
7732});
7733
7734/**
7735 * Сравнивает запрос c подсказками, по словам.
7736 * Срабатывает, только если у всех подсказок общий родитель
7737 * (функция сверки передаётся параметром).
7738 * Игнорирует стоп-слова.
7739 * Возвращает индекс единственной подходящей подсказки
7740 * или -1, если подходящих нет или несколько.
7741 */
7742function _matchByWords(stopwords, parentCheckerFn) {
7743    return function(query, suggestions) {
7744        var queryTokens;
7745        var matches = [];
7746
7747        if (parentCheckerFn(suggestions)) {
7748            queryTokens = text_util.splitTokens(
7749                text_util.split(query, stopwords)
7750            );
7751
7752            collection_util.each(suggestions, function(suggestion, i) {
7753                var suggestedValue = suggestion.value;
7754
7755                if (text_util.stringEncloses(query, suggestedValue)) {
7756                    return false;
7757                }
7758
7759                // check if query words are a subset of suggested words
7760                var suggestionWords = text_util.splitTokens(
7761                    text_util.split(suggestedValue, stopwords)
7762                );
7763
7764                if (
7765                    collection_util.minus(queryTokens, suggestionWords)
7766                        .length === 0
7767                ) {
7768                    matches.push(i);
7769                }
7770            });
7771        }
7772
7773        return matches.length === 1 ? matches[0] : -1;
7774    };
7775}
7776
7777/**
7778 * Matchers return index of suitable suggestion
7779 * Context inside is optionally set in types.js
7780 */
7781var matchers = {
7782    /**
7783     * Matches query against suggestions, removing all the stopwords.
7784     */
7785    matchByNormalizedQuery: function(stopwords) {
7786        return function(query, suggestions) {
7787            var normalizedQuery = text_util.normalize(query, stopwords);
7788            var matches = [];
7789
7790            collection_util.each(suggestions, function(suggestion, i) {
7791                var suggestedValue = suggestion.value.toLowerCase();
7792                // if query encloses suggestion, than it has already been selected
7793                // so we should not select it anymore
7794                if (text_util.stringEncloses(query, suggestedValue)) {
7795                    return false;
7796                }
7797                // if there is suggestion that contains query as its part
7798                // than we should ignore all other matches, even full ones
7799                if (suggestedValue.indexOf(normalizedQuery) > 0) {
7800                    return false;
7801                }
7802                if (
7803                    normalizedQuery ===
7804                    text_util.normalize(suggestedValue, stopwords)
7805                ) {
7806                    matches.push(i);
7807                }
7808            });
7809
7810            return matches.length === 1 ? matches[0] : -1;
7811        };
7812    },
7813
7814    matchByWords: function(stopwords) {
7815        return _matchByWords(stopwords, haveSameParent);
7816    },
7817
7818    matchByWordsAddress: function(stopwords) {
7819        return _matchByWords(stopwords, haveSameParent);
7820    },
7821
7822    /**
7823     * Matches query against values contained in suggestion fields
7824     * for cases, when there is only one suggestion
7825     * only considers fields specified in fields map
7826     * uses partial matching:
7827     *   "0445" vs { value: "ALFA-BANK", data: { "bic": "044525593" }} is a match
7828     */
7829    matchByFields: function(fields) {
7830        return function(query, suggestions) {
7831            var tokens = text_util.splitTokens(text_util.split(query));
7832            var suggestionWords = [];
7833
7834            if (suggestions.length === 1) {
7835                if (fields) {
7836                    collection_util.each(fields, function(stopwords, field) {
7837                        var fieldValue = object_util.getDeepValue(
7838                            suggestions[0],
7839                            field
7840                        );
7841                        var fieldWords =
7842                            fieldValue &&
7843                            text_util.splitTokens(
7844                                text_util.split(fieldValue, stopwords)
7845                            );
7846
7847                        if (fieldWords && fieldWords.length) {
7848                            suggestionWords = suggestionWords.concat(
7849                                fieldWords
7850                            );
7851                        }
7852                    });
7853                }
7854
7855                if (
7856                    collection_util.minusWithPartialMatching(
7857                        tokens,
7858                        suggestionWords
7859                    ).length === 0
7860                ) {
7861                    return 0;
7862                }
7863            }
7864
7865            return -1;
7866        };
7867    }
7868};
7869
7870var ADDRESS_STOPWORDS = [
7871    "ао",
7872    "аобл",
7873    "дом",
7874    "респ",
7875    "а/я",
7876    "аал",
7877    "автодорога",
7878    "аллея",
7879    "арбан",
7880    "аул",
7881    "б-р",
7882    "берег",
7883    "бугор",
7884    "вал",
7885    "вл",
7886    "волость",
7887    "въезд",
7888    "высел",
7889    "г",
7890    "городок",
7891    "гск",
7892    "д",
7893    "двлд",
7894    "днп",
7895    "дор",
7896    "дп",
7897    "ж/д_будка",
7898    "ж/д_казарм",
7899    "ж/д_оп",
7900    "ж/д_платф",
7901    "ж/д_пост",
7902    "ж/д_рзд",
7903    "ж/д_ст",
7904    "жилзона",
7905    "жилрайон",
7906    "жт",
7907    "заезд",
7908    "заимка",
7909    "зона",
7910    "к",
7911    "казарма",
7912    "канал",
7913    "кв",
7914    "кв-л",
7915    "км",
7916    "кольцо",
7917    "комн",
7918    "кордон",
7919    "коса",
7920    "кп",
7921    "край",
7922    "линия",
7923    "лпх",
7924    "м",
7925    "массив",
7926    "местность",
7927    "мкр",
7928    "мост",
7929    "н/п",
7930    "наб",
7931    "нп",
7932    "обл",
7933    "округ",
7934    "остров",
7935    "оф",
7936    "п",
7937    "п/о",
7938    "п/р",
7939    "п/ст",
7940    "парк",
7941    "пгт",
7942    "пер",
7943    "переезд",
7944    "пл",
7945    "пл-ка",
7946    "платф",
7947    "погост",
7948    "полустанок",
7949    "починок",
7950    "пр-кт",
7951    "проезд",
7952    "промзона",
7953    "просек",
7954    "просека",
7955    "проселок",
7956    "проток",
7957    "протока",
7958    "проулок",
7959    "р-н",
7960    "рзд",
7961    "россия",
7962    "рп",
7963    "ряды",
7964    "с",
7965    "с/а",
7966    "с/мо",
7967    "с/о",
7968    "с/п",
7969    "с/с",
7970    "сад",
7971    "сквер",
7972    "сл",
7973    "снт",
7974    "спуск",
7975    "ст",
7976    "ст-ца",
7977    "стр",
7978    "тер",
7979    "тракт",
7980    "туп",
7981    "у",
7982    "ул",
7983    "уч-к",
7984    "ф/х",
7985    "ферма",
7986    "х",
7987    "ш",
7988    "бульвар",
7989    "владение",
7990    "выселки",
7991    "гаражно-строительный",
7992    "город",
7993    "деревня",
7994    "домовладение",
7995    "дорога",
7996    "квартал",
7997    "километр",
7998    "комната",
7999    "корпус",
8000    "литер",
8001    "леспромхоз",
8002    "местечко",
8003    "микрорайон",
8004    "набережная",
8005    "область",
8006    "переулок",
8007    "платформа",
8008    "площадка",
8009    "площадь",
8010    "поселение",
8011    "поселок",
8012    "проспект",
8013    "разъезд",
8014    "район",
8015    "республика",
8016    "село",
8017    "сельсовет",
8018    "слобода",
8019    "сооружение",
8020    "станица",
8021    "станция",
8022    "строение",
8023    "территория",
8024    "тупик",
8025    "улица",
8026    "улус",
8027    "участок",
8028    "хутор",
8029    "шоссе"
8030];
8031
8032/**
8033 * Компоненты адреса
8034 * @type {*[]}
8035 * id {String} Наименование типа
8036 * fields {Array of Strings}
8037 * forBounds {Boolean} может использоваться в ограничениях
8038 * forLocations {Boolean}
8039 * kladrFormat {Object}
8040 * fiasType {String} Наименование соответствующего ФИАС типа
8041 */
8042var ADDRESS_COMPONENTS = [
8043    {
8044        id: "kladr_id",
8045        fields: ["kladr_id"],
8046        forBounds: false,
8047        forLocations: true
8048    },
8049    {
8050        id: "postal_code",
8051        fields: ["postal_code"],
8052        forBounds: false,
8053        forLocations: true
8054    },
8055    {
8056        id: "country_iso_code",
8057        fields: ["country_iso_code"],
8058        forBounds: false,
8059        forLocations: true
8060    },
8061    {
8062        id: "country",
8063        fields: ["country"],
8064        forBounds: true,
8065        forLocations: true,
8066        kladrFormat: { digits: 0, zeros: 13 },
8067        fiasType: "country_iso_code"
8068    },
8069    {
8070        id: "region_iso_code",
8071        fields: ["region_iso_code"],
8072        forBounds: false,
8073        forLocations: true
8074    },
8075    {
8076        id: "region_fias_id",
8077        fields: ["region_fias_id"],
8078        forBounds: false,
8079        forLocations: true
8080    },
8081    {
8082        id: "region_type_full",
8083        fields: ["region_type_full"],
8084        forBounds: false,
8085        forLocations: true,
8086        kladrFormat: { digits: 2, zeros: 11 },
8087        fiasType: "region_fias_id"
8088    },
8089    {
8090        id: "region",
8091        fields: [
8092            "region",
8093            "region_type",
8094            "region_type_full",
8095            "region_with_type"
8096        ],
8097        forBounds: true,
8098        forLocations: true,
8099        kladrFormat: { digits: 2, zeros: 11 },
8100        fiasType: "region_fias_id"
8101    },
8102    {
8103        id: "area_fias_id",
8104        fields: ["area_fias_id"],
8105        forBounds: false,
8106        forLocations: true
8107    },
8108    {
8109        id: "area_type_full",
8110        fields: ["area_type_full"],
8111        forBounds: false,
8112        forLocations: true,
8113        kladrFormat: { digits: 5, zeros: 8 },
8114        fiasType: "area_fias_id"
8115    },
8116    {
8117        id: "area",
8118        fields: ["area", "area_type", "area_type_full", "area_with_type"],
8119        forBounds: true,
8120        forLocations: true,
8121        kladrFormat: { digits: 5, zeros: 8 },
8122        fiasType: "area_fias_id"
8123    },
8124    {
8125        id: "city_fias_id",
8126        fields: ["city_fias_id"],
8127        forBounds: false,
8128        forLocations: true
8129    },
8130    {
8131        id: "city_type_full",
8132        fields: ["city_type_full"],
8133        forBounds: false,
8134        forLocations: true,
8135        kladrFormat: { digits: 8, zeros: 5 },
8136        fiasType: "city_fias_id"
8137    },
8138    {
8139        id: "city",
8140        fields: ["city", "city_type", "city_type_full", "city_with_type"],
8141        forBounds: true,
8142        forLocations: true,
8143        kladrFormat: { digits: 8, zeros: 5 },
8144        fiasType: "city_fias_id"
8145    },
8146    {
8147        id: "city_district_fias_id",
8148        fields: ["city_district_fias_id"],
8149        forBounds: false,
8150        forLocations: true
8151    },
8152    {
8153        id: "city_district_type_full",
8154        fields: ["city_district_type_full"],
8155        forBounds: false,
8156        forLocations: true,
8157        kladrFormat: { digits: 11, zeros: 2 },
8158        fiasType: "city_district_fias_id"
8159    },
8160    {
8161        id: "city_district",
8162        fields: [
8163            "city_district",
8164            "city_district_type",
8165            "city_district_type_full",
8166            "city_district_with_type"
8167        ],
8168        forBounds: true,
8169        forLocations: true,
8170        kladrFormat: { digits: 11, zeros: 2 },
8171        fiasType: "city_district_fias_id"
8172    },
8173    {
8174        id: "settlement_fias_id",
8175        fields: ["settlement_fias_id"],
8176        forBounds: false,
8177        forLocations: true
8178    },
8179    {
8180        id: "settlement_type_full",
8181        fields: ["settlement_type_full"],
8182        forBounds: false,
8183        forLocations: true,
8184        kladrFormat: { digits: 11, zeros: 2 },
8185        fiasType: "settlement_fias_id"
8186    },
8187    {
8188        id: "settlement",
8189        fields: [
8190            "settlement",
8191            "settlement_type",
8192            "settlement_type_full",
8193            "settlement_with_type"
8194        ],
8195        forBounds: true,
8196        forLocations: true,
8197        kladrFormat: { digits: 11, zeros: 2 },
8198        fiasType: "settlement_fias_id"
8199    },
8200    {
8201        id: "street_fias_id",
8202        fields: ["street_fias_id"],
8203        forBounds: false,
8204        forLocations: true
8205    },
8206    {
8207        id: "street_type_full",
8208        fields: ["street_type_full"],
8209        forBounds: false,
8210        forLocations: true,
8211        kladrFormat: { digits: 15, zeros: 2 },
8212        fiasType: "street_fias_id"
8213    },
8214    {
8215        id: "street",
8216        fields: [
8217            "street",
8218            "street_type",
8219            "street_type_full",
8220            "street_with_type"
8221        ],
8222        forBounds: true,
8223        forLocations: true,
8224        kladrFormat: { digits: 15, zeros: 2 },
8225        fiasType: "street_fias_id"
8226    },
8227    {
8228        id: "house",
8229        fields: [
8230            "house",
8231            "house_type",
8232            "house_type_full",
8233            "block",
8234            "block_type"
8235        ],
8236        forBounds: true,
8237        forLocations: true,
8238        kladrFormat: { digits: 19 },
8239        fiasType: "house_fias_id"
8240    },
8241    {
8242        id: "flat",
8243        fields: ["flat", "flat_type", "flat_type_full"],
8244        forBounds: true,
8245        forLocations: false,
8246        kladrFormat: { digits: 19 },
8247        fiasType: "flat_fias_id"
8248    }
8249];
8250
8251var ADDRESS_TYPE = {
8252    urlSuffix: "address",
8253    noSuggestionsHint: "Неизвестный адрес",
8254    matchers: [
8255        matchers.matchByNormalizedQuery(ADDRESS_STOPWORDS),
8256        matchers.matchByWordsAddress(ADDRESS_STOPWORDS)
8257    ],
8258    dataComponents: ADDRESS_COMPONENTS,
8259    dataComponentsById: object_util.indexObjectsById(
8260        ADDRESS_COMPONENTS,
8261        "id",
8262        "index"
8263    ),
8264    unformattableTokens: ADDRESS_STOPWORDS,
8265    enrichmentEnabled: true,
8266    enrichmentMethod: "suggest",
8267    enrichmentParams: {
8268        count: 1,
8269        locations: null,
8270        locations_boost: null,
8271        from_bound: null,
8272        to_bound: null
8273    },
8274    getEnrichmentQuery: function(suggestion) {
8275        return suggestion.unrestricted_value;
8276    },
8277    geoEnabled: true,
8278    isDataComplete: function(suggestion) {
8279        var fields = [this.bounds.to || "flat"],
8280            data = suggestion.data;
8281
8282        return (
8283            !lang_util.isPlainObject(data) ||
8284            object_util.fieldsAreNotEmpty(data, fields)
8285        );
8286    },
8287    composeValue: function(data, options) {
8288        var country = data.country,
8289            region =
8290                data.region_with_type ||
8291                collection_util
8292                    .compact([data.region, data.region_type])
8293                    .join(" ") ||
8294                data.region_type_full,
8295            area =
8296                data.area_with_type ||
8297                collection_util
8298                    .compact([data.area_type, data.area])
8299                    .join(" ") ||
8300                data.area_type_full,
8301            city =
8302                data.city_with_type ||
8303                collection_util
8304                    .compact([data.city_type, data.city])
8305                    .join(" ") ||
8306                data.city_type_full,
8307            settelement =
8308                data.settlement_with_type ||
8309                collection_util
8310                    .compact([data.settlement_type, data.settlement])
8311                    .join(" ") ||
8312                data.settlement_type_full,
8313            cityDistrict =
8314                data.city_district_with_type ||
8315                collection_util
8316                    .compact([data.city_district_type, data.city_district])
8317                    .join(" ") ||
8318                data.city_district_type_full,
8319            street =
8320                data.street_with_type ||
8321                collection_util
8322                    .compact([data.street_type, data.street])
8323                    .join(" ") ||
8324                data.street_type_full,
8325            house = collection_util
8326                .compact([
8327                    data.stead_type,
8328                    data.stead,
8329                    data.house_type,
8330                    data.house,
8331                    data.block_type,
8332                    data.block
8333                ])
8334                .join(" "),
8335            flat = collection_util
8336                .compact([data.flat_type, data.flat])
8337                .join(" "),
8338            postal_box = data.postal_box && "а/я " + data.postal_box,
8339            result;
8340
8341        // если регион совпадает с городом
8342        // например г Москва, г Москва
8343        // то не показываем регион
8344        if (region === city) {
8345            region = "";
8346        }
8347
8348        // иногда не показываем район
8349        if (!(options && options.saveCityDistrict)) {
8350            if (options && options.excludeCityDistrict) {
8351                // если район явно запрещен
8352                cityDistrict = "";
8353            } else if (cityDistrict && !data.city_district_fias_id) {
8354                // если район взят из ОКАТО (у него пустой city_district_fias_id)
8355                cityDistrict = "";
8356            }
8357        }
8358
8359        result = collection_util
8360            .compact([
8361                country,
8362                region,
8363                area,
8364                city,
8365                cityDistrict,
8366                settelement,
8367                street,
8368                house,
8369                flat,
8370                postal_box
8371            ])
8372            .join(", ");
8373
8374        return result;
8375    },
8376    formatResult: (function() {
8377        var componentsUnderCityDistrict = [],
8378            _underCityDistrict = false;
8379
8380        ADDRESS_COMPONENTS.forEach(function(component) {
8381            if (_underCityDistrict)
8382                componentsUnderCityDistrict.push(component.id);
8383            if (component.id === "city_district") _underCityDistrict = true;
8384        });
8385
8386        return function(value, currentValue, suggestion, options) {
8387            var that = this,
8388                district =
8389                    suggestion.data && suggestion.data.city_district_with_type,
8390                unformattableTokens = options && options.unformattableTokens,
8391                historyValues =
8392                    suggestion.data && suggestion.data.history_values,
8393                tokens,
8394                unusedTokens,
8395                formattedHistoryValues;
8396
8397            // добавляем исторические значения
8398            if (historyValues && historyValues.length > 0) {
8399                tokens = text_util.tokenize(currentValue, unformattableTokens);
8400                unusedTokens = this.type.findUnusedTokens(tokens, value);
8401                formattedHistoryValues = this.type.getFormattedHistoryValues(
8402                    unusedTokens,
8403                    historyValues
8404                );
8405                if (formattedHistoryValues) {
8406                    value += formattedHistoryValues;
8407                }
8408            }
8409
8410            value = that.highlightMatches(
8411                value,
8412                currentValue,
8413                suggestion,
8414                options
8415            );
8416            value = that.wrapFormattedValue(value, suggestion);
8417
8418            if (
8419                district &&
8420                (!that.bounds.own.length ||
8421                    that.bounds.own.indexOf("street") >= 0) &&
8422                !lang_util.isEmptyObject(
8423                    that.copyDataComponents(
8424                        suggestion.data,
8425                        componentsUnderCityDistrict
8426                    )
8427                )
8428            ) {
8429                value +=
8430                    '<div class="' +
8431                    that.classes.subtext +
8432                    '">' +
8433                    that.highlightMatches(district, currentValue, suggestion) +
8434                    "</div>";
8435            }
8436
8437            return value;
8438        };
8439    })(),
8440
8441    /**
8442     * Возвращает список слов в запросе,
8443     * которые не встречаются в подсказке
8444     */
8445    findUnusedTokens: function(tokens, value) {
8446        var tokenIndex,
8447            token,
8448            unused = [];
8449
8450        unused = tokens.filter(function(token) {
8451            return value.indexOf(token) === -1;
8452        });
8453
8454        return unused;
8455    },
8456
8457    /**
8458     * Возвращает исторические названия для слов запроса,
8459     * для которых не найдено совпадения в основном значении подсказки
8460     */
8461    getFormattedHistoryValues: function(unusedTokens, historyValues) {
8462        var tokenIndex,
8463            token,
8464            historyValueIndex,
8465            historyValue,
8466            values = [],
8467            formatted = "";
8468
8469        historyValues.forEach(function(historyValue) {
8470            collection_util.each(unusedTokens, function(token) {
8471                if (historyValue.toLowerCase().indexOf(token) >= 0) {
8472                    values.push(historyValue);
8473                    return false;
8474                }
8475            });
8476        });
8477
8478        if (values.length > 0) {
8479            formatted = " (бывш. " + values.join(", ") + ")";
8480        }
8481
8482        return formatted;
8483    },
8484
8485    /**
8486     * @param instance
8487     * @param options
8488     * @param options.suggestion
8489     * @param options.hasSameValues
8490     * @param options.hasBeenEnreached
8491     */
8492    getSuggestionValue: function(instance, options) {
8493        var formattedValue = null;
8494
8495        if (options.hasSameValues) {
8496            if (instance.options.restrict_value) {
8497                // Can not use unrestricted address,
8498                // because some components (from constraints) must be omitted
8499                formattedValue = this.getValueWithinConstraints(
8500                    instance,
8501                    options.suggestion
8502                );
8503            } else if (instance.bounds.own.length) {
8504                // Can not use unrestricted address,
8505                // because only components from bounds must be included
8506                formattedValue = this.getValueWithinBounds(
8507                    instance,
8508                    options.suggestion
8509                );
8510            } else {
8511                // Can use full unrestricted address
8512                formattedValue = options.suggestion.unrestricted_value;
8513            }
8514        } else if (options.hasBeenEnriched) {
8515            if (instance.options.restrict_value) {
8516                formattedValue = this.getValueWithinConstraints(
8517                    instance,
8518                    options.suggestion,
8519                    { excludeCityDistrict: true }
8520                );
8521            }
8522        }
8523
8524        return formattedValue;
8525    },
8526    /*
8527     * Compose suggestion value with respect to constraints
8528     */
8529    getValueWithinConstraints: function(instance, suggestion, options) {
8530        return this.composeValue(
8531            instance.getUnrestrictedData(suggestion.data),
8532            options
8533        );
8534    },
8535    /*
8536     * Compose suggestion value with respect to bounds
8537     */
8538    getValueWithinBounds: function(instance, suggestion, options) {
8539        // для корректного составления адреса нужен city_district_fias_id
8540        var data = instance.copyDataComponents(
8541            suggestion.data,
8542            instance.bounds.own.concat(["city_district_fias_id"])
8543        );
8544
8545        return this.composeValue(data, options);
8546    }
8547};
8548
8549/**
8550 * Компоненты адреса
8551 * @type {*[]}
8552 * id {String} Наименование типа
8553 * fields {Array of Strings}
8554 * forBounds {Boolean} может использоваться в ограничениях
8555 * forLocations {Boolean}
8556 * kladrFormat {Object}
8557 * fiasType {String} Наименование соответствующего ФИАС типа
8558 */
8559var FIAS_COMPONENTS = [
8560    {
8561        id: "kladr_id",
8562        fields: ["kladr_id"],
8563        forBounds: false,
8564        forLocations: true
8565    },
8566    {
8567        id: "region_fias_id",
8568        fields: ["region_fias_id"],
8569        forBounds: false,
8570        forLocations: true
8571    },
8572    {
8573        id: "region_type_full",
8574        fields: ["region_type_full"],
8575        forBounds: false,
8576        forLocations: true,
8577        kladrFormat: { digits: 2, zeros: 11 },
8578        fiasType: "region_fias_id"
8579    },
8580    {
8581        id: "region",
8582        fields: [
8583            "region",
8584            "region_type",
8585            "region_type_full",
8586            "region_with_type"
8587        ],
8588        forBounds: true,
8589        forLocations: true,
8590        kladrFormat: { digits: 2, zeros: 11 },
8591        fiasType: "region_fias_id"
8592    },
8593    {
8594        id: "area_fias_id",
8595        fields: ["area_fias_id"],
8596        forBounds: false,
8597        forLocations: true
8598    },
8599    {
8600        id: "area_type_full",
8601        fields: ["area_type_full"],
8602        forBounds: false,
8603        forLocations: true,
8604        kladrFormat: { digits: 5, zeros: 8 },
8605        fiasType: "area_fias_id"
8606    },
8607    {
8608        id: "area",
8609        fields: ["area", "area_type", "area_type_full", "area_with_type"],
8610        forBounds: true,
8611        forLocations: true,
8612        kladrFormat: { digits: 5, zeros: 8 },
8613        fiasType: "area_fias_id"
8614    },
8615    {
8616        id: "city_fias_id",
8617        fields: ["city_fias_id"],
8618        forBounds: false,
8619        forLocations: true
8620    },
8621    {
8622        id: "city_type_full",
8623        fields: ["city_type_full"],
8624        forBounds: false,
8625        forLocations: true,
8626        kladrFormat: { digits: 8, zeros: 5 },
8627        fiasType: "city_fias_id"
8628    },
8629    {
8630        id: "city",
8631        fields: ["city", "city_type", "city_type_full", "city_with_type"],
8632        forBounds: true,
8633        forLocations: true,
8634        kladrFormat: { digits: 8, zeros: 5 },
8635        fiasType: "city_fias_id"
8636    },
8637    {
8638        id: "city_district_fias_id",
8639        fields: ["city_district_fias_id"],
8640        forBounds: false,
8641        forLocations: true
8642    },
8643    {
8644        id: "city_district_type_full",
8645        fields: ["city_district_type_full"],
8646        forBounds: false,
8647        forLocations: true,
8648        kladrFormat: { digits: 11, zeros: 2 },
8649        fiasType: "city_district_fias_id"
8650    },
8651    {
8652        id: "city_district",
8653        fields: [
8654            "city_district",
8655            "city_district_type",
8656            "city_district_type_full",
8657            "city_district_with_type"
8658        ],
8659        forBounds: true,
8660        forLocations: true,
8661        kladrFormat: { digits: 11, zeros: 2 },
8662        fiasType: "city_district_fias_id"
8663    },
8664    {
8665        id: "settlement_fias_id",
8666        fields: ["settlement_fias_id"],
8667        forBounds: false,
8668        forLocations: true
8669    },
8670    {
8671        id: "settlement_type_full",
8672        fields: ["settlement_type_full"],
8673        forBounds: false,
8674        forLocations: true,
8675        kladrFormat: { digits: 11, zeros: 2 },
8676        fiasType: "settlement_fias_id"
8677    },
8678    {
8679        id: "settlement",
8680        fields: [
8681            "settlement",
8682            "settlement_type",
8683            "settlement_type_full",
8684            "settlement_with_type"
8685        ],
8686        forBounds: true,
8687        forLocations: true,
8688        kladrFormat: { digits: 11, zeros: 2 },
8689        fiasType: "settlement_fias_id"
8690    },
8691    {
8692        id: "planning_structure_fias_id",
8693        fields: ["planning_structure_fias_id"],
8694        forBounds: false,
8695        forLocations: true
8696    },
8697    {
8698        id: "planning_structure_type_full",
8699        fields: ["planning_structure_type_full"],
8700        forBounds: false,
8701        forLocations: true,
8702        kladrFormat: { digits: 15, zeros: 2 },
8703        fiasType: "planning_structure_fias_id"
8704    },
8705    {
8706        id: "planning_structure",
8707        fields: [
8708            "planning_structure",
8709            "planning_structure_type",
8710            "planning_structure_type_full",
8711            "planning_structure_with_type"
8712        ],
8713        forBounds: true,
8714        forLocations: true,
8715        kladrFormat: { digits: 15, zeros: 2 },
8716        fiasType: "planning_structure_fias_id"
8717    },
8718    {
8719        id: "street_fias_id",
8720        fields: ["street_fias_id"],
8721        forBounds: false,
8722        forLocations: true
8723    },
8724    {
8725        id: "street_type_full",
8726        fields: ["street_type_full"],
8727        forBounds: false,
8728        forLocations: true,
8729        kladrFormat: { digits: 15, zeros: 2 },
8730        fiasType: "street_fias_id"
8731    },
8732    {
8733        id: "street",
8734        fields: [
8735            "street",
8736            "street_type",
8737            "street_type_full",
8738            "street_with_type"
8739        ],
8740        forBounds: true,
8741        forLocations: true,
8742        kladrFormat: { digits: 15, zeros: 2 },
8743        fiasType: "street_fias_id"
8744    },
8745    {
8746        id: "house",
8747        fields: ["house", "house_type", "block", "building_type", "building"],
8748        forBounds: true,
8749        forLocations: false,
8750        kladrFormat: { digits: 19 }
8751    }
8752];
8753
8754var FIAS_TYPE = {
8755    urlSuffix: "fias",
8756    noSuggestionsHint: "Неизвестный адрес",
8757    matchers: [
8758        matchers.matchByNormalizedQuery(ADDRESS_STOPWORDS),
8759        matchers.matchByWordsAddress(ADDRESS_STOPWORDS)
8760    ],
8761    dataComponents: FIAS_COMPONENTS,
8762    dataComponentsById: object_util.indexObjectsById(
8763        FIAS_COMPONENTS,
8764        "id",
8765        "index"
8766    ),
8767    unformattableTokens: ADDRESS_STOPWORDS,
8768    isDataComplete: function(suggestion) {
8769        var fields = [this.bounds.to || "house"],
8770            data = suggestion.data;
8771
8772        return (
8773            !lang_util.isPlainObject(data) ||
8774            object_util.fieldsAreNotEmpty(data, fields)
8775        );
8776    },
8777    composeValue: function(data, options) {
8778        var country = data.country,
8779            region =
8780                data.region_with_type ||
8781                collection_util
8782                    .compact([data.region, data.region_type])
8783                    .join(" ") ||
8784                data.region_type_full,
8785            area =
8786                data.area_with_type ||
8787                collection_util
8788                    .compact([data.area_type, data.area])
8789                    .join(" ") ||
8790                data.area_type_full,
8791            city =
8792                data.city_with_type ||
8793                collection_util
8794                    .compact([data.city_type, data.city])
8795                    .join(" ") ||
8796                data.city_type_full,
8797            settelement =
8798                data.settlement_with_type ||
8799                collection_util
8800                    .compact([data.settlement_type, data.settlement])
8801                    .join(" ") ||
8802                data.settlement_type_full,
8803            cityDistrict =
8804                data.city_district_with_type ||
8805                collection_util
8806                    .compact([data.city_district_type, data.city_district])
8807                    .join(" ") ||
8808                data.city_district_type_full,
8809            planning_structure =
8810                data.planning_structure_with_type ||
8811                collection_util
8812                    .compact([
8813                        data.planning_structure_type,
8814                        data.planning_structure
8815                    ])
8816                    .join(" ") ||
8817                data.planning_structure_type_full,
8818            street =
8819                data.street_with_type ||
8820                collection_util
8821                    .compact([data.street_type, data.street])
8822                    .join(" ") ||
8823                data.street_type_full,
8824            house = collection_util
8825                .compact([
8826                    data.house_type,
8827                    data.house,
8828                    data.block_type,
8829                    data.block
8830                ])
8831                .join(" "),
8832            flat = collection_util
8833                .compact([data.flat_type, data.flat])
8834                .join(" "),
8835            postal_box = data.postal_box && "а/я " + data.postal_box,
8836            result;
8837
8838        // если регион совпадает с городом
8839        // например г Москва, г Москва
8840        // то не показываем регион
8841        if (region === city) {
8842            region = "";
8843        }
8844
8845        // иногда не показываем район
8846        if (!(options && options.saveCityDistrict)) {
8847            if (options && options.excludeCityDistrict) {
8848                // если район явно запрещен
8849                cityDistrict = "";
8850            } else if (cityDistrict && !data.city_district_fias_id) {
8851                // если район взят из ОКАТО (у него пустой city_district_fias_id)
8852                cityDistrict = "";
8853            }
8854        }
8855
8856        result = collection_util
8857            .compact([
8858                country,
8859                region,
8860                area,
8861                city,
8862                cityDistrict,
8863                settelement,
8864                planning_structure,
8865                street,
8866                house,
8867                flat,
8868                postal_box
8869            ])
8870            .join(", ");
8871
8872        return result;
8873    },
8874    formatResult: (function() {
8875        return function(value, currentValue, suggestion, options) {
8876            var that = this;
8877
8878            value = that.highlightMatches(
8879                value,
8880                currentValue,
8881                suggestion,
8882                options
8883            );
8884            value = that.wrapFormattedValue(value, suggestion);
8885            return value;
8886        };
8887    })(),
8888
8889    getSuggestionValue: ADDRESS_TYPE.getSuggestionValue,
8890    getValueWithinConstraints: ADDRESS_TYPE.getValueWithinConstraints,
8891    getValueWithinBounds: ADDRESS_TYPE.getValueWithinBounds
8892};
8893
8894function valueStartsWith(suggestion, field) {
8895    var fieldValue = suggestion.data && suggestion.data[field];
8896
8897    return (
8898        fieldValue &&
8899        new RegExp(
8900            "^" +
8901                text_util.escapeRegExChars(fieldValue) +
8902                "([" +
8903                WORD_DELIMITERS +
8904                "]|$)",
8905            "i"
8906        ).test(suggestion.value)
8907    );
8908}
8909
8910var NAME_TYPE = {
8911    urlSuffix: "fio",
8912    noSuggestionsHint: false,
8913    matchers: [matchers.matchByNormalizedQuery(), matchers.matchByWords()],
8914    // names for labels, describing which fields are displayed
8915    fieldNames: {
8916        surname: "фамилия",
8917        name: "имя",
8918        patronymic: "отчество"
8919    },
8920    isDataComplete: function(suggestion) {
8921        var that = this,
8922            params = that.options.params,
8923            data = suggestion.data,
8924            fields;
8925
8926        if (lang_util.isFunction(params)) {
8927            params = params.call(that.element, suggestion.value);
8928        }
8929        if (params && params.parts) {
8930            fields = params.parts.map(function(part) {
8931                return part.toLowerCase();
8932            });
8933        } else {
8934            // when NAME is first, patronymic is mot mandatory
8935            fields = ["surname", "name"];
8936            // when SURNAME is first, it is
8937            if (valueStartsWith(suggestion, "surname")) {
8938                fields.push("patronymic");
8939            }
8940        }
8941        return object_util.fieldsAreNotEmpty(data, fields);
8942    },
8943    composeValue: function(data) {
8944        return collection_util
8945            .compact([data.surname, data.name, data.patronymic])
8946            .join(" ");
8947    }
8948};
8949
8950var innPartsLengths = {
8951    LEGAL: [2, 2, 5, 1],
8952    INDIVIDUAL: [2, 2, 6, 2]
8953};
8954
8955function chooseFormattedField(formattedMain, formattedAlt) {
8956    var rHasMatch = /<strong>/;
8957    return rHasMatch.test(formattedAlt) && !rHasMatch.test(formattedMain)
8958        ? formattedAlt
8959        : formattedMain;
8960}
8961
8962function formattedField(main, alt, currentValue, suggestion, options) {
8963    var that = this,
8964        formattedMain = that.highlightMatches(
8965            main,
8966            currentValue,
8967            suggestion,
8968            options
8969        ),
8970        formattedAlt = that.highlightMatches(
8971            alt,
8972            currentValue,
8973            suggestion,
8974            options
8975        );
8976
8977    return chooseFormattedField(formattedMain, formattedAlt);
8978}
8979
8980var PARTY_TYPE = {
8981    urlSuffix: "party",
8982    noSuggestionsHint: "Неизвестная организация",
8983    matchers: [
8984        matchers.matchByFields(
8985            // These fields of suggestion's `data` used by by-words matcher
8986            {
8987                value: null,
8988                "data.address.value": ADDRESS_STOPWORDS,
8989                "data.inn": null,
8990                "data.ogrn": null
8991            }
8992        )
8993    ],
8994    dataComponents: ADDRESS_COMPONENTS,
8995    enrichmentEnabled: true,
8996    enrichmentMethod: "findById",
8997    enrichmentParams: {
8998        count: 1,
8999        locations_boost: null
9000    },
9001    getEnrichmentQuery: function(suggestion) {
9002        return suggestion.data.hid;
9003    },
9004    geoEnabled: true,
9005    formatResult: function(value, currentValue, suggestion, options) {
9006        var that = this,
9007            formattedInn = that.type.formatResultInn.call(
9008                that,
9009                suggestion,
9010                currentValue
9011            ),
9012            formatterOGRN = that.highlightMatches(
9013                object_util.getDeepValue(suggestion.data, "ogrn"),
9014                currentValue,
9015                suggestion
9016            ),
9017            formattedInnOGRN = chooseFormattedField(
9018                formattedInn,
9019                formatterOGRN
9020            ),
9021            formattedFIO = that.highlightMatches(
9022                object_util.getDeepValue(suggestion.data, "management.name"),
9023                currentValue,
9024                suggestion
9025            ),
9026            address =
9027                object_util.getDeepValue(suggestion.data, "address.value") ||
9028                "";
9029
9030        if (that.isMobile) {
9031            (options || (options = {})).maxLength = 50;
9032        }
9033
9034        value = formattedField.call(
9035            that,
9036            value,
9037            object_util.getDeepValue(suggestion.data, "name.latin"),
9038            currentValue,
9039            suggestion,
9040            options
9041        );
9042        value = that.wrapFormattedValue(value, suggestion);
9043
9044        if (address) {
9045            address = address.replace(/^(\d{6}|Россия),\s+/i, "");
9046            if (that.isMobile) {
9047                // keep only two first words
9048                address = address.replace(
9049                    new RegExp(
9050                        "^([^" +
9051                            WORD_DELIMITERS +
9052                            "]+[" +
9053                            WORD_DELIMITERS +
9054                            "]+[^" +
9055                            WORD_DELIMITERS +
9056                            "]+).*"
9057                    ),
9058                    "$1"
9059                );
9060            } else {
9061                address = that.highlightMatches(
9062                    address,
9063                    currentValue,
9064                    suggestion,
9065                    {
9066                        unformattableTokens: ADDRESS_STOPWORDS
9067                    }
9068                );
9069            }
9070        }
9071
9072        if (formattedInnOGRN || address || formattedFIO) {
9073            value +=
9074                '<div class="' +
9075                that.classes.subtext +
9076                '">' +
9077                '<span class="' +
9078                that.classes.subtext_inline +
9079                '">' +
9080                (formattedInnOGRN || "") +
9081                "</span>" +
9082                (chooseFormattedField(address, formattedFIO) || "") +
9083                "</div>";
9084        }
9085        return value;
9086    },
9087    formatResultInn: function(suggestion, currentValue) {
9088        var that = this,
9089            inn = suggestion.data && suggestion.data.inn,
9090            innPartsLength =
9091                innPartsLengths[suggestion.data && suggestion.data.type],
9092            innParts,
9093            formattedInn,
9094            rDigit = /\d/;
9095
9096        if (inn) {
9097            formattedInn = that.highlightMatches(inn, currentValue, suggestion);
9098            if (innPartsLength) {
9099                formattedInn = formattedInn.split("");
9100                innParts = innPartsLength.map(function(partLength) {
9101                    var formattedPart = "",
9102                        ch;
9103
9104                    while (partLength && (ch = formattedInn.shift())) {
9105                        formattedPart += ch;
9106                        if (rDigit.test(ch)) partLength--;
9107                    }
9108
9109                    return formattedPart;
9110                });
9111                formattedInn =
9112                    innParts.join(
9113                        '<span class="' +
9114                            that.classes.subtext_delimiter +
9115                            '"></span>'
9116                    ) + formattedInn.join("");
9117            }
9118
9119            return formattedInn;
9120        }
9121    }
9122};
9123
9124var EMAIL_TYPE = {
9125    urlSuffix: "email",
9126    noSuggestionsHint: false,
9127    matchers: [matchers.matchByNormalizedQuery()],
9128    isQueryRequestable: function(query) {
9129        return this.options.suggest_local || query.indexOf("@") >= 0;
9130    }
9131};
9132
9133var BANK_TYPE = {
9134    urlSuffix: "bank",
9135    noSuggestionsHint: "Неизвестный банк",
9136    matchers: [
9137        matchers.matchByFields(
9138            // These fields of suggestion's `data` used by by-words matcher
9139            {
9140                value: null,
9141                "data.bic": null,
9142                "data.swift": null,
9143            }
9144        ),
9145    ],
9146    dataComponents: ADDRESS_COMPONENTS,
9147    enrichmentEnabled: true,
9148    enrichmentMethod: "findById",
9149    enrichmentParams: {
9150        count: 1,
9151    },
9152    getEnrichmentQuery: function(suggestion) {
9153        return suggestion.data.bic;
9154    },
9155    geoEnabled: true,
9156    formatResult: function(value, currentValue, suggestion, options) {
9157        var that = this,
9158            formattedBIC = that.highlightMatches(
9159                object_util.getDeepValue(suggestion.data, "bic"),
9160                currentValue,
9161                suggestion
9162            ),
9163            address =
9164                object_util.getDeepValue(suggestion.data, "address.value") ||
9165                "";
9166
9167        value = that.highlightMatches(value, currentValue, suggestion, options);
9168        value = that.wrapFormattedValue(value, suggestion);
9169
9170        if (address) {
9171            address = address.replace(/^\d{6}( РОССИЯ)?, /i, "");
9172            if (that.isMobile) {
9173                // keep only two first words
9174                address = address.replace(
9175                    new RegExp(
9176                        "^([^" +
9177                            WORD_DELIMITERS +
9178                            "]+[" +
9179                            WORD_DELIMITERS +
9180                            "]+[^" +
9181                            WORD_DELIMITERS +
9182                            "]+).*"
9183                    ),
9184                    "$1"
9185                );
9186            } else {
9187                address = that.highlightMatches(
9188                    address,
9189                    currentValue,
9190                    suggestion,
9191                    {
9192                        unformattableTokens: ADDRESS_STOPWORDS,
9193                    }
9194                );
9195            }
9196        }
9197
9198        if (formattedBIC || address) {
9199            value +=
9200                '<div class="' +
9201                that.classes.subtext +
9202                '">' +
9203                '<span class="' +
9204                that.classes.subtext_inline +
9205                '">' +
9206                formattedBIC +
9207                "</span>" +
9208                address +
9209                "</div>";
9210        }
9211        return value;
9212    },
9213    formatSelected: function(suggestion) {
9214        return (
9215            object_util.getDeepValue(suggestion, "data.name.payment") || null
9216        );
9217    },
9218};
9219
9220function Outward(name) {
9221    this.urlSuffix = name.toLowerCase();
9222    this.noSuggestionsHint = "Неизвестное значение";
9223    this.matchers = [
9224        matchers.matchByNormalizedQuery(),
9225        matchers.matchByWords()
9226    ];
9227}
9228
9229/**
9230 * Type is a bundle of properties:
9231 * - urlSuffix Mandatory. String
9232 * - matchers Mandatory. Array of functions (with optional data bound as a context) that find appropriate suggestion to select
9233 * - `fieldNames` Map fields of suggestion.data to their displayable names
9234 * - `unformattableTokens` Array of strings which should not be highlighted
9235 * - `dataComponents` Array of 'bound's can be set as `bounds` option. Order is important.
9236 *
9237 * flags:
9238 * - `alwaysContinueSelecting` Forbids to hide dropdown after selecting
9239 * - `geoEnabled` Makes to detect client's location for passing it to all requests
9240 * - `enrichmentEnabled` Makes to send additional request when a suggestion is selected
9241 *
9242 * and methods:
9243 * - `isDataComplete` Checks if suggestion.data can be operated as full data of it's type
9244 * - `composeValue` returns string value based on suggestion.data
9245 * - `formatResult` returns html of a suggestion. Overrides default method
9246 * - `formatResultInn` returns html of suggestion.data.inn
9247 * - `isQueryRequestable` checks if query is appropriated for requesting server
9248 * - `formatSelected` returns string to be inserted in textbox
9249 */
9250
9251var types = {
9252    NAME: NAME_TYPE,
9253    ADDRESS: ADDRESS_TYPE,
9254    FIAS: FIAS_TYPE,
9255    PARTY: PARTY_TYPE,
9256    EMAIL: EMAIL_TYPE,
9257    BANK: BANK_TYPE
9258};
9259
9260types.get = function(type) {
9261    if (types.hasOwnProperty(type)) {
9262        return types[type];
9263    } else {
9264        return new Outward(type);
9265    }
9266};
9267
9268jqapi.extend(DEFAULT_OPTIONS, {
9269    suggest_local: true
9270});
9271
9272var notificator = {
9273    chains: {},
9274
9275    on: function(name, method) {
9276        this.get(name).push(method);
9277        return this;
9278    },
9279
9280    get: function(name) {
9281        var chains = this.chains;
9282        return chains[name] || (chains[name] = []);
9283    }
9284};
9285
9286var serviceMethods = {
9287    suggest: {
9288        defaultParams: {
9289            type: utils.getDefaultType(),
9290            dataType: "json",
9291            contentType: utils.getDefaultContentType()
9292        },
9293        addTypeInUrl: true
9294    },
9295    "iplocate/address": {
9296        defaultParams: {
9297            type: "GET",
9298            dataType: "json"
9299        },
9300        addTypeInUrl: false
9301    },
9302    status: {
9303        defaultParams: {
9304            type: "GET",
9305            dataType: "json"
9306        },
9307        addTypeInUrl: true
9308    },
9309    findById: {
9310        defaultParams: {
9311            type: utils.getDefaultType(),
9312            dataType: "json",
9313            contentType: utils.getDefaultContentType()
9314        },
9315        addTypeInUrl: true
9316    }
9317};
9318
9319var requestModes = {
9320    suggest: {
9321        method: "suggest",
9322        userSelect: true,
9323        updateValue: true,
9324        enrichmentEnabled: true
9325    },
9326    findById: {
9327        method: "findById",
9328        userSelect: false,
9329        updateValue: false,
9330        enrichmentEnabled: false
9331    }
9332};
9333
9334function Suggestions(el, options) {
9335    var that = this;
9336
9337    // Shared variables:
9338    that.element = el;
9339    that.el = $(el);
9340    that.suggestions = [];
9341    that.badQueries = [];
9342    that.selectedIndex = -1;
9343    that.currentValue = that.element.value;
9344    that.intervalId = 0;
9345    that.cachedResponse = {};
9346    that.enrichmentCache = {};
9347    that.currentRequest = null;
9348    that.inputPhase = $.Deferred();
9349    that.fetchPhase = $.Deferred();
9350    that.enrichPhase = $.Deferred();
9351    that.onChangeTimeout = null;
9352    that.triggering = {};
9353    that.$wrapper = null;
9354    that.options = $.extend({}, DEFAULT_OPTIONS, options);
9355    that.classes = CLASSES;
9356    that.disabled = false;
9357    that.selection = null;
9358    that.$viewport = $(window);
9359    that.$body = $(document.body);
9360    that.type = null;
9361    that.status = {};
9362
9363    that.setupElement();
9364
9365    that.initializer = $.Deferred();
9366
9367    if (that.el.is(":visible")) {
9368        that.initializer.resolve();
9369    } else {
9370        that.deferInitialization();
9371    }
9372
9373    that.initializer.done($.proxy(that.initialize, that));
9374}
9375
9376Suggestions.prototype = {
9377    // Creation and destruction
9378
9379    initialize: function() {
9380        var that = this;
9381        that.uniqueId = utils.uniqueId("i");
9382        that.createWrapper();
9383        that.notify("initialize");
9384        that.bindWindowEvents();
9385        that.setOptions();
9386        that.inferIsMobile();
9387        that.notify("ready");
9388    },
9389
9390    /**
9391     * Initialize when element is firstly interacted
9392     */
9393    deferInitialization: function() {
9394        var that = this,
9395            events = "mouseover focus keydown",
9396            timer,
9397            callback = function() {
9398                that.initializer.resolve();
9399                that.enable();
9400            };
9401
9402        that.initializer.always(function() {
9403            that.el.off(events, callback);
9404            clearInterval(timer);
9405        });
9406
9407        that.disabled = true;
9408        that.el.on(events, callback);
9409        timer = setInterval(function() {
9410            if (that.el.is(":visible")) {
9411                callback();
9412            }
9413        }, that.options.initializeInterval);
9414    },
9415
9416    isInitialized: function() {
9417        return this.initializer.state() === "resolved";
9418    },
9419
9420    dispose: function() {
9421        var that = this;
9422        that.initializer.reject();
9423        that.notify("dispose");
9424        that.el.removeData(DATA_ATTR_KEY).removeClass("suggestions-input");
9425        that.unbindWindowEvents();
9426        that.removeWrapper();
9427        that.el.trigger("suggestions-dispose");
9428    },
9429
9430    notify: function(chainName) {
9431        var that = this,
9432            args = utils.slice(arguments, 1);
9433
9434        return $.map(notificator.get(chainName), function(method) {
9435            return method.apply(that, args);
9436        });
9437    },
9438
9439    createWrapper: function() {
9440        var that = this;
9441
9442        that.$wrapper = $('<div class="suggestions-wrapper"/>');
9443        that.el.after(that.$wrapper);
9444
9445        that.$wrapper.on(
9446            "mousedown" + EVENT_NS,
9447            $.proxy(that.onMousedown, that)
9448        );
9449    },
9450
9451    removeWrapper: function() {
9452        var that = this;
9453
9454        if (that.$wrapper) {
9455            that.$wrapper.remove();
9456        }
9457        $(that.options.$helpers).off(EVENT_NS);
9458    },
9459
9460    /** This whole handler is needed to prevent blur event on textbox
9461     * when suggestion is clicked (blur leads to suggestions hide, so we need to prevent it).
9462     * See https://github.com/jquery/jquery-ui/blob/master/ui/autocomplete.js for details
9463     */
9464    onMousedown: function(e) {
9465        var that = this;
9466
9467        // prevent moving focus out of the text field
9468        e.preventDefault();
9469
9470        // IE doesn't prevent moving focus even with e.preventDefault()
9471        // so we set a flag to know when we should ignore the blur event
9472        that.cancelBlur = true;
9473        utils.delay(function() {
9474            delete that.cancelBlur;
9475        });
9476
9477        // clicking on the scrollbar causes focus to shift to the body
9478        // but we can't detect a mouseup or a click immediately afterward
9479        // so we have to track the next mousedown and close the menu if
9480        // the user clicks somewhere outside of the autocomplete
9481        if ($(e.target).closest(".ui-menu-item").length == 0) {
9482            utils.delay(function() {
9483                $(document).one("mousedown", function(e) {
9484                    var $elements = that.el
9485                        .add(that.$wrapper)
9486                        .add(that.options.$helpers);
9487
9488                    if (that.options.floating) {
9489                        $elements = $elements.add(that.$container);
9490                    }
9491
9492                    $elements = $elements.filter(function() {
9493                        return this === e.target || $.contains(this, e.target);
9494                    });
9495
9496                    if (!$elements.length) {
9497                        that.hide();
9498                    }
9499                });
9500            });
9501        }
9502    },
9503
9504    bindWindowEvents: function() {
9505        var handler = $.proxy(this.inferIsMobile, this);
9506        this.$viewport.on("resize" + EVENT_NS + this.uniqueId, handler);
9507    },
9508
9509    unbindWindowEvents: function() {
9510        this.$viewport.off("resize" + EVENT_NS + this.uniqueId);
9511    },
9512
9513    scrollToTop: function() {
9514        var that = this,
9515            scrollTarget = that.options.scrollOnFocus;
9516
9517        if (scrollTarget === true) {
9518            scrollTarget = that.el;
9519        }
9520        if (scrollTarget instanceof $ && scrollTarget.length > 0) {
9521            $("body,html").animate(
9522                {
9523                    scrollTop: scrollTarget.offset().top
9524                },
9525                "fast"
9526            );
9527        }
9528    },
9529
9530    // Configuration methods
9531
9532    setOptions: function(suppliedOptions) {
9533        var that = this;
9534
9535        $.extend(that.options, suppliedOptions);
9536
9537        that["type"] = types.get(that.options["type"]);
9538
9539        // Check mandatory options
9540        $.each(
9541            {
9542                requestMode: requestModes
9543            },
9544            function(option, available) {
9545                that[option] = available[that.options[option]];
9546                if (!that[option]) {
9547                    that.disable();
9548                    throw "`" +
9549                        option +
9550                        "` option is incorrect! Must be one of: " +
9551                        $.map(available, function(value, name) {
9552                            return '"' + name + '"';
9553                        }).join(", ");
9554                }
9555            }
9556        );
9557
9558        $(that.options.$helpers)
9559            .off(EVENT_NS)
9560            .on("mousedown" + EVENT_NS, $.proxy(that.onMousedown, that));
9561
9562        if (that.isInitialized()) {
9563            that.notify("setOptions");
9564        }
9565    },
9566
9567    // Common public methods
9568
9569    inferIsMobile: function() {
9570        this.isMobile = this.$viewport.width() <= this.options.mobileWidth;
9571    },
9572
9573    clearCache: function() {
9574        this.cachedResponse = {};
9575        this.enrichmentCache = {};
9576        this.badQueries = [];
9577    },
9578
9579    clear: function() {
9580        var that = this,
9581            currentSelection = that.selection;
9582
9583        if (that.isInitialized()) {
9584            that.clearCache();
9585            that.currentValue = "";
9586            that.selection = null;
9587            that.hide();
9588            that.suggestions = [];
9589            that.el.val("");
9590            that.el.trigger("suggestions-clear");
9591            that.notify("clear");
9592            that.trigger("InvalidateSelection", currentSelection);
9593        }
9594    },
9595
9596    disable: function() {
9597        var that = this;
9598
9599        that.disabled = true;
9600        that.abortRequest();
9601        if (that.visible) {
9602            that.hide();
9603        }
9604    },
9605
9606    enable: function() {
9607        this.disabled = false;
9608    },
9609
9610    isUnavailable: function() {
9611        return this.disabled;
9612    },
9613
9614    update: function() {
9615        var that = this,
9616            query = that.el.val();
9617
9618        if (that.isInitialized()) {
9619            that.currentValue = query;
9620            if (that.isQueryRequestable(query)) {
9621                that.updateSuggestions(query);
9622            } else {
9623                that.hide();
9624            }
9625        }
9626    },
9627
9628    setSuggestion: function(suggestion) {
9629        var that = this,
9630            data,
9631            value;
9632
9633        if ($.isPlainObject(suggestion) && $.isPlainObject(suggestion.data)) {
9634            suggestion = $.extend(true, {}, suggestion);
9635
9636            if (
9637                that.isUnavailable() &&
9638                that.initializer &&
9639                that.initializer.state() === "pending"
9640            ) {
9641                that.initializer.resolve();
9642                that.enable();
9643            }
9644
9645            if (that.bounds.own.length) {
9646                that.checkValueBounds(suggestion);
9647                data = that.copyDataComponents(
9648                    suggestion.data,
9649                    that.bounds.all
9650                );
9651                if (suggestion.data.kladr_id) {
9652                    data.kladr_id = that.getBoundedKladrId(
9653                        suggestion.data.kladr_id,
9654                        that.bounds.all
9655                    );
9656                }
9657                suggestion.data = data;
9658            }
9659
9660            that.selection = suggestion;
9661
9662            // `that.suggestions` required by `that.getSuggestionValue` and must be set before
9663            that.suggestions = [suggestion];
9664            value = that.getSuggestionValue(suggestion) || "";
9665            that.currentValue = value;
9666            that.el.val(value);
9667            that.abortRequest();
9668            that.el.trigger("suggestions-set");
9669        }
9670    },
9671
9672    /**
9673     * Fetch full object for current INPUT's value
9674     * if no suitable object found, clean input element
9675     */
9676    fixData: function() {
9677        var that = this,
9678            fullQuery = that.extendedCurrentValue(),
9679            currentValue = that.el.val(),
9680            resolver = $.Deferred();
9681
9682        resolver
9683            .done(function(suggestion) {
9684                that.selectSuggestion(suggestion, 0, currentValue, {
9685                    hasBeenEnriched: true
9686                });
9687                that.el.trigger("suggestions-fixdata", suggestion);
9688            })
9689            .fail(function() {
9690                that.selection = null;
9691                that.el.trigger("suggestions-fixdata");
9692            });
9693
9694        if (that.isQueryRequestable(fullQuery)) {
9695            that.currentValue = fullQuery;
9696            that.getSuggestions(fullQuery, {
9697                count: 1,
9698                from_bound: null,
9699                to_bound: null
9700            })
9701                .done(function(suggestions) {
9702                    // data fetched
9703                    var suggestion = suggestions[0];
9704                    if (suggestion) {
9705                        resolver.resolve(suggestion);
9706                    } else {
9707                        resolver.reject();
9708                    }
9709                })
9710                .fail(function() {
9711                    // no data fetched
9712                    resolver.reject();
9713                });
9714        } else {
9715            resolver.reject();
9716        }
9717    },
9718
9719    // Querying related methods
9720
9721    /**
9722     * Looks up parent instances
9723     * @returns {String} current value prepended by parents' values
9724     */
9725    extendedCurrentValue: function() {
9726        var that = this,
9727            parentInstance = that.getParentInstance(),
9728            parentValue =
9729                parentInstance && parentInstance.extendedCurrentValue(),
9730            currentValue = $.trim(that.el.val());
9731
9732        return utils.compact([parentValue, currentValue]).join(" ");
9733    },
9734
9735    getAjaxParams: function(method, custom) {
9736        var that = this,
9737            token = $.trim(that.options.token),
9738            partner = $.trim(that.options.partner),
9739            serviceUrl = that.options.serviceUrl,
9740            url = that.options.url,
9741            serviceMethod = serviceMethods[method],
9742            params = $.extend(
9743                {
9744                    timeout: that.options.timeout
9745                },
9746                serviceMethod.defaultParams
9747            ),
9748            headers = {};
9749
9750        if (url) {
9751            serviceUrl = url;
9752        } else {
9753            if (!/\/$/.test(serviceUrl)) {
9754                serviceUrl += "/";
9755            }
9756            serviceUrl += method;
9757            if (serviceMethod.addTypeInUrl) {
9758                serviceUrl += "/" + that.type.urlSuffix;
9759            }
9760        }
9761
9762        serviceUrl = utils.fixURLProtocol(serviceUrl);
9763
9764        if ($.support.cors) {
9765            // for XMLHttpRequest put token in header
9766            if (token) {
9767                headers["Authorization"] = "Token " + token;
9768            }
9769            if (partner) {
9770                headers["X-Partner"] = partner;
9771            }
9772            headers["X-Version"] = Suggestions.version;
9773            if (!params.headers) {
9774                params.headers = {};
9775            }
9776            if (!params.xhrFields) {
9777                params.xhrFields = {};
9778            }
9779            $.extend(params.headers, that.options.headers, headers);
9780            // server sets Access-Control-Allow-Origin: *
9781            // which requires no credentials
9782            params.xhrFields.withCredentials = false;
9783        } else {
9784            // for XDomainRequest put token into URL
9785            if (token) {
9786                headers["token"] = token;
9787            }
9788            if (partner) {
9789                headers["partner"] = partner;
9790            }
9791            headers["version"] = Suggestions.version;
9792            serviceUrl = utils.addUrlParams(serviceUrl, headers);
9793        }
9794
9795        params.url = serviceUrl;
9796
9797        return $.extend(params, custom);
9798    },
9799
9800    isQueryRequestable: function(query) {
9801        var that = this,
9802            result;
9803
9804        result = query.length >= that.options.minChars;
9805
9806        if (result && that.type.isQueryRequestable) {
9807            result = that.type.isQueryRequestable.call(that, query);
9808        }
9809
9810        return result;
9811    },
9812
9813    constructRequestParams: function(query, customParams) {
9814        var that = this,
9815            options = that.options,
9816            params = $.isFunction(options.params)
9817                ? options.params.call(that.element, query)
9818                : $.extend({}, options.params);
9819
9820        if (that.type.constructRequestParams) {
9821            $.extend(params, that.type.constructRequestParams.call(that));
9822        }
9823        $.each(that.notify("requestParams"), function(i, hookParams) {
9824            $.extend(params, hookParams);
9825        });
9826        params[options.paramName] = query;
9827        if ($.isNumeric(options.count) && options.count > 0) {
9828            params.count = options.count;
9829        }
9830        if (options.language) {
9831            params.language = options.language;
9832        }
9833
9834        return $.extend(params, customParams);
9835    },
9836
9837    updateSuggestions: function(query) {
9838        var that = this;
9839
9840        that.fetchPhase = that
9841            .getSuggestions(query)
9842            .done(function(suggestions) {
9843                that.assignSuggestions(suggestions, query);
9844            });
9845    },
9846
9847    /**
9848     * Get suggestions from cache or from server
9849     * @param {String} query
9850     * @param {Object} customParams parameters specified here will be passed to request body
9851     * @param {Object} requestOptions
9852     * @param {Boolean} [requestOptions.noCallbacks]  flag, request competence callbacks will not be invoked
9853     * @param {Boolean} [requestOptions.useEnrichmentCache]
9854     * @return {$.Deferred} waiter which is to be resolved with suggestions as argument
9855     */
9856    getSuggestions: function(query, customParams, requestOptions) {
9857        var response,
9858            that = this,
9859            options = that.options,
9860            noCallbacks = requestOptions && requestOptions.noCallbacks,
9861            useEnrichmentCache =
9862                requestOptions && requestOptions.useEnrichmentCache,
9863            method =
9864                (requestOptions && requestOptions.method) ||
9865                that.requestMode.method,
9866            params = that.constructRequestParams(query, customParams),
9867            cacheKey = $.param(params || {}),
9868            resolver = $.Deferred();
9869
9870        response = that.cachedResponse[cacheKey];
9871        if (response && $.isArray(response.suggestions)) {
9872            resolver.resolve(response.suggestions);
9873        } else {
9874            if (that.isBadQuery(query)) {
9875                resolver.reject();
9876            } else {
9877                if (
9878                    !noCallbacks &&
9879                    options.onSearchStart.call(that.element, params) === false
9880                ) {
9881                    resolver.reject();
9882                } else {
9883                    that.doGetSuggestions(params, method)
9884                        .done(function(response) {
9885                            // if response is correct and current value has not been changed
9886                            if (
9887                                that.processResponse(response) &&
9888                                query == that.currentValue
9889                            ) {
9890                                // Cache results if cache is not disabled:
9891                                if (!options.noCache) {
9892                                    if (useEnrichmentCache) {
9893                                        that.enrichmentCache[query] =
9894                                            response.suggestions[0];
9895                                    } else {
9896                                        that.enrichResponse(response, query);
9897                                        that.cachedResponse[
9898                                            cacheKey
9899                                        ] = response;
9900                                        if (
9901                                            options.preventBadQueries &&
9902                                            response.suggestions.length === 0
9903                                        ) {
9904                                            that.badQueries.push(query);
9905                                        }
9906                                    }
9907                                }
9908
9909                                resolver.resolve(response.suggestions);
9910                            } else {
9911                                resolver.reject();
9912                            }
9913                            if (!noCallbacks) {
9914                                options.onSearchComplete.call(
9915                                    that.element,
9916                                    query,
9917                                    response.suggestions
9918                                );
9919                            }
9920                        })
9921                        .fail(function(jqXHR, textStatus, errorThrown) {
9922                            resolver.reject();
9923                            if (!noCallbacks && textStatus !== "abort") {
9924                                options.onSearchError.call(
9925                                    that.element,
9926                                    query,
9927                                    jqXHR,
9928                                    textStatus,
9929                                    errorThrown
9930                                );
9931                            }
9932                        });
9933                }
9934            }
9935        }
9936        return resolver;
9937    },
9938
9939    /**
9940     * Sends an AJAX request to server suggest method.
9941     * @param {Object} params request params
9942     * @returns {$.Deferred} response promise
9943     */
9944    doGetSuggestions: function(params, method) {
9945        var that = this,
9946            request = $.ajax(
9947                that.getAjaxParams(method, { data: utils.serialize(params) })
9948            );
9949
9950        that.abortRequest();
9951        that.currentRequest = request;
9952        that.notify("request");
9953
9954        request.always(function() {
9955            that.currentRequest = null;
9956            that.notify("request");
9957        });
9958
9959        return request;
9960    },
9961
9962    isBadQuery: function(q) {
9963        if (!this.options.preventBadQueries) {
9964            return false;
9965        }
9966
9967        var result = false;
9968        $.each(this.badQueries, function(i, query) {
9969            return !(result = q.indexOf(query) === 0);
9970        });
9971        return result;
9972    },
9973
9974    abortRequest: function() {
9975        var that = this;
9976
9977        if (that.currentRequest) {
9978            that.currentRequest.abort();
9979        }
9980    },
9981
9982    /**
9983     * Checks response format and data
9984     * @return {Boolean} response contains acceptable data
9985     */
9986    processResponse: function(response) {
9987        var that = this,
9988            suggestions;
9989
9990        if (!response || !$.isArray(response.suggestions)) {
9991            return false;
9992        }
9993
9994        that.verifySuggestionsFormat(response.suggestions);
9995        that.setUnrestrictedValues(response.suggestions);
9996
9997        if ($.isFunction(that.options.onSuggestionsFetch)) {
9998            suggestions = that.options.onSuggestionsFetch.call(
9999                that.element,
10000                response.suggestions
10001            );
10002            if ($.isArray(suggestions)) {
10003                response.suggestions = suggestions;
10004            }
10005        }
10006
10007        return true;
10008    },
10009
10010    verifySuggestionsFormat: function(suggestions) {
10011        if (typeof suggestions[0] === "string") {
10012            $.each(suggestions, function(i, value) {
10013                suggestions[i] = { value: value, data: null };
10014            });
10015        }
10016    },
10017
10018    /**
10019     * Gets string to set as input value
10020     *
10021     * @param suggestion
10022     * @param {Object} [selectionOptions]
10023     * @param {boolean} selectionOptions.hasBeenEnriched
10024     * @param {boolean} selectionOptions.hasSameValues
10025     * @return {string}
10026     */
10027    getSuggestionValue: function(suggestion, selectionOptions) {
10028        var that = this,
10029            formatSelected =
10030                that.options.formatSelected || that.type.formatSelected,
10031            hasSameValues = selectionOptions && selectionOptions.hasSameValues,
10032            hasBeenEnriched =
10033                selectionOptions && selectionOptions.hasBeenEnriched,
10034            formattedValue,
10035            typeFormattedValue = null;
10036
10037        if ($.isFunction(formatSelected)) {
10038            formattedValue = formatSelected.call(that, suggestion);
10039        }
10040
10041        if (typeof formattedValue !== "string") {
10042			if (that.bounds.from === null) {
10043				formattedValue = suggestion.unrestricted_value;
10044			}
10045			else
10046			{
10047				formattedValue = suggestion.value;
10048			}
10049////LOG
10050//console.log(that.bounds.from)
vendor: 22,772 bytes, lines 10050-10859
10050;
10051
10052            if (that.type.getSuggestionValue) {
10053                typeFormattedValue = that.type.getSuggestionValue(that, {
10054                    suggestion: suggestion,
10055                    hasSameValues: hasSameValues,
10056                    hasBeenEnriched: hasBeenEnriched
10057                });
10058
10059                if (typeFormattedValue !== null) {
10060                    formattedValue = typeFormattedValue;
10061                }
10062            }
10063        }
10064
10065        return formattedValue;
10066    },
10067
10068    hasSameValues: function(suggestion) {
10069        var hasSame = false;
10070
10071        $.each(this.suggestions, function(i, anotherSuggestion) {
10072            if (
10073                anotherSuggestion.value === suggestion.value &&
10074                anotherSuggestion !== suggestion
10075            ) {
10076                hasSame = true;
10077                return false;
10078            }
10079        });
10080
10081        return hasSame;
10082    },
10083
10084    assignSuggestions: function(suggestions, query) {
10085        var that = this;
10086        that.suggestions = suggestions;
10087        that.notify("assignSuggestions", query);
10088    },
10089
10090    shouldRestrictValues: function() {
10091        var that = this;
10092        // treat suggestions value as restricted only if there is one constraint
10093        // and restrict_value is true
10094        return (
10095            that.options.restrict_value &&
10096            that.constraints &&
10097            Object.keys(that.constraints).length == 1
10098        );
10099    },
10100
10101    /**
10102     * Fills suggestion.unrestricted_value property
10103     */
10104    setUnrestrictedValues: function(suggestions) {
10105        var that = this,
10106            shouldRestrict = that.shouldRestrictValues(),
10107            label = that.getFirstConstraintLabel();
10108
10109        $.each(suggestions, function(i, suggestion) {
10110            if (!suggestion.unrestricted_value) {
10111                suggestion.unrestricted_value = shouldRestrict
10112                    ? label + ", " + suggestion.value
10113                    : suggestion.value;
10114            }
10115        });
10116    },
10117
10118    areSuggestionsSame: function(a, b) {
10119        return a && b && a.value === b.value && utils.areSame(a.data, b.data);
10120    },
10121
10122    getNoSuggestionsHint: function() {
10123        var that = this;
10124        if (that.options.noSuggestionsHint === false) {
10125            return false;
10126        }
10127        return that.options.noSuggestionsHint || that.type.noSuggestionsHint;
10128    }
10129};
10130
10131/**
10132 * Methods related to INPUT's behavior
10133 */
10134
10135var methods = {
10136    setupElement: function() {
10137        // Remove autocomplete attribute to prevent native suggestions:
10138        this.el
10139            // if it stops working, see https://stackoverflow.com/q/15738259
10140            // chrome is constantly changing this logic
10141            .attr("autocomplete", "new-password")
10142            .attr("autocorrect", "off")
10143            .attr("autocapitalize", "off")
10144            .attr("spellcheck", "false")
10145            .addClass("suggestions-input")
10146            .css("box-sizing", "border-box");
10147    },
10148
10149    bindElementEvents: function() {
10150        var that = this;
10151
10152        that.el.on("keydown" + EVENT_NS, $.proxy(that.onElementKeyDown, that));
10153        // IE is buggy, it doesn't trigger `input` on text deletion, so use following events
10154        that.el.on(
10155            [
10156                "keyup" + EVENT_NS,
10157                "cut" + EVENT_NS,
10158                "paste" + EVENT_NS,
10159                "input" + EVENT_NS
10160            ].join(" "),
10161            $.proxy(that.onElementKeyUp, that)
10162        );
10163        that.el.on("blur" + EVENT_NS, $.proxy(that.onElementBlur, that));
10164        that.el.on("focus" + EVENT_NS, $.proxy(that.onElementFocus, that));
10165    },
10166
10167    unbindElementEvents: function() {
10168        this.el.off(EVENT_NS);
10169    },
10170
10171    onElementBlur: function() {
10172        var that = this;
10173
10174        // suggestion was clicked, blur should be ignored
10175        // see container mousedown handler
10176        if (that.cancelBlur) {
10177            that.cancelBlur = false;
10178            return;
10179        }
10180
10181        if (that.options.triggerSelectOnBlur) {
10182            if (!that.isUnavailable()) {
10183                that.selectCurrentValue({ noSpace: true }).always(function() {
10184                    // For NAMEs selecting keeps suggestions list visible, so hide it
10185                    that.hide();
10186                });
10187            }
10188        } else {
10189            that.hide();
10190        }
10191
10192        if (that.fetchPhase.abort) {
10193            that.fetchPhase.abort();
10194        }
10195    },
10196
10197    onElementFocus: function() {
10198        var that = this;
10199
10200        if (!that.cancelFocus) {
10201            // defer methods to allow browser update input's style before
10202            utils.delay($.proxy(that.completeOnFocus, that));
10203        }
10204        that.cancelFocus = false;
10205    },
10206
10207    onElementKeyDown: function(e) {
10208        var that = this;
10209
10210        if (that.isUnavailable()) {
10211            return;
10212        }
10213
10214        if (!that.visible) {
10215            switch (e.which) {
10216                // If suggestions are hidden and user presses arrow down, display suggestions
10217                case KEYS.DOWN:
10218                    that.suggest();
10219                    break;
10220                // if no suggestions available and user pressed Enter
10221                case KEYS.ENTER:
10222                    if (that.options.triggerSelectOnEnter) {
10223                        that.triggerOnSelectNothing();
10224                    }
10225                    break;
10226            }
10227            return;
10228        }
10229
10230        switch (e.which) {
10231            case KEYS.ESC:
10232                that.el.val(that.currentValue);
10233                that.hide();
10234                that.abortRequest();
10235                break;
10236
10237            case KEYS.TAB:
10238                if (that.options.tabDisabled === false) {
10239                    return;
10240                }
10241                break;
10242
10243            case KEYS.ENTER:
10244                if (that.options.triggerSelectOnEnter) {
10245                    that.selectCurrentValue();
10246                }
10247                break;
10248
10249            case KEYS.SPACE:
10250                if (that.options.triggerSelectOnSpace && that.isCursorAtEnd()) {
10251                    e.preventDefault();
10252                    that.selectCurrentValue({
10253                        continueSelecting: true,
10254                        dontEnrich: true
10255                    }).fail(function() {
10256                        // If all data fetched but nothing selected
10257                        that.currentValue += " ";
10258                        that.el.val(that.currentValue);
10259                        that.proceedChangedValue();
10260                    });
10261                }
10262                return;
10263            case KEYS.UP:
10264                that.moveUp();
10265                break;
10266            case KEYS.DOWN:
10267                that.moveDown();
10268                break;
10269            default:
10270                return;
10271        }
10272
10273        // Cancel event if function did not return:
10274        e.stopImmediatePropagation();
10275        e.preventDefault();
10276    },
10277
10278    onElementKeyUp: function(e) {
10279        var that = this;
10280
10281        if (that.isUnavailable()) {
10282            return;
10283        }
10284
10285        switch (e.which) {
10286            case KEYS.UP:
10287            case KEYS.DOWN:
10288            case KEYS.ENTER:
10289                return;
10290        }
10291
10292        // Cancel pending change
10293        clearTimeout(that.onChangeTimeout);
10294        that.inputPhase.reject();
10295
10296        if (that.currentValue !== that.el.val()) {
10297            that.proceedChangedValue();
10298        }
10299    },
10300
10301    proceedChangedValue: function() {
10302        var that = this;
10303
10304        // Cancel fetching, because it became obsolete
10305        that.abortRequest();
10306
10307        that.inputPhase = $.Deferred().done($.proxy(that.onValueChange, that));
10308
10309        if (that.options.deferRequestBy > 0) {
10310            // Defer lookup in case when value changes very quickly:
10311            that.onChangeTimeout = utils.delay(function() {
10312                that.inputPhase.resolve();
10313            }, that.options.deferRequestBy);
10314        } else {
10315            that.inputPhase.resolve();
10316        }
10317    },
10318
10319    onValueChange: function() {
10320        var that = this,
10321            currentSelection;
10322
10323        if (that.selection) {
10324            currentSelection = that.selection;
10325            that.selection = null;
10326            that.trigger("InvalidateSelection", currentSelection);
10327        }
10328
10329        that.selectedIndex = -1;
10330
10331        that.update();
10332        that.notify("valueChange");
10333    },
10334
10335    completeOnFocus: function() {
10336        var that = this;
10337
10338        if (that.isUnavailable()) {
10339            return;
10340        }
10341
10342        if (that.isElementFocused()) {
10343            that.update();
10344            if (that.isMobile) {
10345                that.setCursorAtEnd();
10346                that.scrollToTop();
10347            }
10348        }
10349    },
10350
10351    isElementFocused: function() {
10352        return document.activeElement === this.element;
10353    },
10354
10355    isElementDisabled: function() {
10356        return Boolean(
10357            this.element.getAttribute("disabled") ||
10358                this.element.getAttribute("readonly")
10359        );
10360    },
10361
10362    isCursorAtEnd: function() {
10363        var that = this,
10364            valLength = that.el.val().length,
10365            selectionStart,
10366            range;
10367
10368        // `selectionStart` and `selectionEnd` are not supported by some input types
10369        try {
10370            selectionStart = that.element.selectionStart;
10371            if (typeof selectionStart === "number") {
10372                return selectionStart === valLength;
10373            }
10374        } catch (ex) {}
10375
10376        if (document.selection) {
10377            range = document.selection.createRange();
10378            range.moveStart("character", -valLength);
10379            return valLength === range.text.length;
10380        }
10381        return true;
10382    },
10383
10384    setCursorAtEnd: function() {
10385        var element = this.element;
10386
10387        // `selectionStart` and `selectionEnd` are not supported by some input types
10388        try {
10389            element.selectionEnd = element.selectionStart =
10390                element.value.length;
10391            element.scrollLeft = element.scrollWidth;
10392        } catch (ex) {
10393            element.value = element.value;
10394        }
10395    }
10396};
10397
10398$.extend(Suggestions.prototype, methods);
10399
10400notificator
10401    .on("initialize", methods.bindElementEvents)
10402    .on("dispose", methods.unbindElementEvents);
10403
10404/**
10405 * Methods related to plugin's authorization on server
10406 */
10407
10408// keys are "[type][token]"
10409var statusRequests = {};
10410
10411function resetTokens() {
10412    utils.each(statusRequests, function(req) {
10413        req.abort();
10414    });
10415    statusRequests = {};
10416}
10417
10418resetTokens();
10419
10420var methods$1 = {
10421    checkStatus: function() {
10422        var that = this,
10423            token = (that.options.token && that.options.token.trim()) || "",
10424            requestKey = that.options.type + token,
10425            request = statusRequests[requestKey];
10426
10427        if (!request) {
10428            request = statusRequests[requestKey] = jqapi.ajax(
10429                that.getAjaxParams("status")
10430            );
10431        }
10432
10433        request
10434            .done(function(status, textStatus, request) {
10435                if (status.search) {
10436                    var plan = request.getResponseHeader("X-Plan");
10437                    status.plan = plan;
10438                    jqapi.extend(that.status, status);
10439                } else {
10440                    triggerError("Service Unavailable");
10441                }
10442            })
10443            .fail(function() {
10444                triggerError(request.statusText);
10445            });
10446
10447        function triggerError(errorThrown) {
10448            // If unauthorized
10449            if (utils.isFunction(that.options.onSearchError)) {
10450                that.options.onSearchError.call(
10451                    that.element,
10452                    null,
10453                    request,
10454                    "error",
10455                    errorThrown
10456                );
10457            }
10458        }
10459    }
10460};
10461
10462Suggestions.resetTokens = resetTokens;
10463
10464jqapi.extend(Suggestions.prototype, methods$1);
10465
10466notificator.on("setOptions", methods$1.checkStatus);
10467
10468//export { methods, resetTokens };
10469
10470var locationRequest;
10471var defaultGeoLocation = true;
10472
10473function resetLocation() {
10474    locationRequest = null;
10475    DEFAULT_OPTIONS.geoLocation = defaultGeoLocation;
10476}
10477
10478var methods$2 = {
10479    checkLocation: function() {
10480        var that = this,
10481            providedLocation = that.options.geoLocation;
10482
10483        if (!that.type.geoEnabled || !providedLocation) {
10484            return;
10485        }
10486
10487        that.geoLocation = $.Deferred();
10488        if ($.isPlainObject(providedLocation) || $.isArray(providedLocation)) {
10489            that.geoLocation.resolve(providedLocation);
10490        } else {
10491            if (!locationRequest) {
10492                locationRequest = $.ajax(
10493                    that.getAjaxParams("iplocate/address")
10494                );
10495            }
10496
10497            locationRequest
10498                .done(function(resp) {
10499                    var locationData =
10500                        resp && resp.location && resp.location.data;
10501                    if (locationData && locationData.kladr_id) {
10502                        that.geoLocation.resolve({
10503                            kladr_id: locationData.kladr_id
10504                        });
10505                    } else {
10506                        that.geoLocation.reject();
10507                    }
10508                })
10509                .fail(function() {
10510                    that.geoLocation.reject();
10511                });
10512        }
10513    },
10514
10515    /**
10516     * Public method to get `geoLocation` promise
10517     * @returns {$.Deferred}
10518     */
10519    getGeoLocation: function() {
10520        return this.geoLocation;
10521    },
10522
10523    constructParams: function() {
10524        var that = this,
10525            params = {};
10526
10527        if (
10528            that.geoLocation &&
10529            $.isFunction(that.geoLocation.promise) &&
10530            that.geoLocation.state() == "resolved"
10531        ) {
10532            that.geoLocation.done(function(locationData) {
10533                params["locations_boost"] = $.makeArray(locationData);
10534            });
10535        }
10536
10537        return params;
10538    }
10539};
10540
10541// Disable this feature when GET method used. See SUG-202
10542if (utils.getDefaultType() != "GET") {
10543    $.extend(DEFAULT_OPTIONS, {
10544        geoLocation: defaultGeoLocation
10545    });
10546
10547    $.extend(Suggestions, {
10548        resetLocation: resetLocation
10549    });
10550
10551    $.extend(Suggestions.prototype, {
10552        getGeoLocation: methods$2.getGeoLocation
10553    });
10554
10555    notificator
10556        .on("setOptions", methods$2.checkLocation)
10557        .on("requestParams", methods$2.constructParams);
10558}
10559
10560var methods$3 = {
10561    enrichSuggestion: function(suggestion, selectionOptions) {
10562        var that = this,
10563            resolver = $.Deferred();
10564
10565        if (
10566            !that.options.enrichmentEnabled ||
10567            !that.type.enrichmentEnabled ||
10568            !that.requestMode.enrichmentEnabled ||
10569            (selectionOptions && selectionOptions.dontEnrich)
10570        ) {
10571            return resolver.resolve(suggestion);
10572        }
10573
10574        // if current suggestion is already enriched, use it
10575        if (suggestion.data && suggestion.data.qc != null) {
10576            return resolver.resolve(suggestion);
10577        }
10578
10579        that.disableDropdown();
10580
10581        var query = that.type.getEnrichmentQuery(suggestion);
10582        var customParams = that.type.enrichmentParams;
10583        var requestOptions = {
10584            noCallbacks: true,
10585            useEnrichmentCache: true,
10586            method: that.type.enrichmentMethod
10587        };
10588
10589        // Set `currentValue` to make `processResponse` to consider enrichment response valid
10590        that.currentValue = query;
10591
10592        // prevent request abortion during onBlur
10593        that.enrichPhase = that
10594            .getSuggestions(query, customParams, requestOptions)
10595            .always(function() {
10596                that.enableDropdown();
10597            })
10598            .done(function(suggestions) {
10599                var enrichedSuggestion = suggestions && suggestions[0];
10600
10601                resolver.resolve(
10602                    enrichedSuggestion || suggestion,
10603                    !!enrichedSuggestion
10604                );
10605            })
10606            .fail(function() {
10607                resolver.resolve(suggestion);
10608            });
10609
10610        return resolver;
10611    },
10612
10613    /**
10614     * Injects enriched suggestion into response
10615     * @param response
10616     * @param query
10617     */
10618    enrichResponse: function(response, query) {
10619        var that = this,
10620            enrichedSuggestion = that.enrichmentCache[query];
10621
10622        if (enrichedSuggestion) {
10623            $.each(response.suggestions, function(i, suggestion) {
10624                if (suggestion.value === query) {
10625                    response.suggestions[i] = enrichedSuggestion;
10626                    return false;
10627                }
10628            });
10629        }
10630    }
10631};
10632
10633$.extend(Suggestions.prototype, methods$3);
10634
10635/**
10636 * Methods related to suggestions dropdown list
10637 */
10638
10639function highlightMatches(chunks) {
10640    return $.map(chunks, function(chunk) {
10641        var text = utils.escapeHtml(chunk.text);
10642
10643        if (text && chunk.matched) {
10644            text = "<strong>" + text + "</strong>";
10645        }
10646        return text;
10647    }).join("");
10648}
10649
10650function nowrapLinkedParts(formattedStr, nowrapClass) {
10651    var delimitedParts = formattedStr.split(", ");
10652    // string has no delimiters, should not wrap
10653    if (delimitedParts.length === 1) {
10654        return formattedStr;
10655    }
10656    // disable word-wrap inside delimited parts
10657    return $.map(delimitedParts, function(part) {
10658        return '<span class="' + nowrapClass + '">' + part + "</span>";
10659    }).join(", ");
10660}
10661
10662function hasAnotherSuggestion(suggestions, suggestion) {
10663    var result = false;
10664
10665    $.each(suggestions, function(i, s) {
10666        result = s.value == suggestion.value && s != suggestion;
10667        if (result) {
10668            return false;
10669        }
10670    });
10671
10672    return result;
10673}
10674
10675var optionsUsed = {
10676    width: "auto",
10677    floating: false
10678};
10679
10680var methods$4 = {
10681    createContainer: function() {
10682        var that = this,
10683            suggestionSelector = "." + that.classes.suggestion,
10684            options = that.options,
10685            $container = $("<div/>")
10686                .addClass(options.containerClass)
10687                .css({
10688                    display: "none"
10689                });
10690
10691        that.$container = $container;
10692
10693        $container.on(
10694            "click" + EVENT_NS,
10695            suggestionSelector,
10696            $.proxy(that.onSuggestionClick, that)
10697        );
10698    },
10699
10700    showContainer: function() {
10701        this.$container.appendTo(
10702            this.options.floating ? this.$body : this.$wrapper
10703        );
10704    },
10705
10706    getContainer: function() {
10707        return this.$container.get(0);
10708    },
10709
10710    removeContainer: function() {
10711        var that = this;
10712
10713        if (that.options.floating) {
10714            that.$container.remove();
10715        }
10716    },
10717
10718    setContainerOptions: function() {
10719        var that = this,
10720            mousedownEvent = "mousedown" + EVENT_NS;
10721
10722        that.$container.off(mousedownEvent);
10723        if (that.options.floating) {
10724            that.$container.on(mousedownEvent, $.proxy(that.onMousedown, that));
10725        }
10726    },
10727
10728    /**
10729     * Listen for click event on suggestions list:
10730     */
10731    onSuggestionClick: function(e) {
10732        var that = this,
10733            $el = $(e.target),
10734            index;
10735
10736        if (!that.dropdownDisabled) {
10737            that.cancelFocus = true;
10738            that.el.focus();
10739
10740            while ($el.length && !(index = $el.attr("data-index"))) {
10741                $el = $el.closest("." + that.classes.suggestion);
10742            }
10743
10744            if (index && !isNaN(index)) {
10745                that.select(+index);
10746            }
10747        }
10748    },
10749
10750    // Dropdown UI methods
10751
10752    getSuggestionsItems: function() {
10753        return this.$container.children("." + this.classes.suggestion);
10754    },
10755
10756    toggleDropdownEnabling: function(enable) {
10757        this.dropdownDisabled = !enable;
10758        this.$container.attr("disabled", !enable);
10759    },
10760
10761    disableDropdown: function() {
10762        this.toggleDropdownEnabling(false);
10763    },
10764
10765    enableDropdown: function() {
10766        this.toggleDropdownEnabling(true);
10767    },
10768
10769    /**
10770     * Shows if there are any suggestions besides currently selected
10771     * @returns {boolean}
10772     */
10773    hasSuggestionsToChoose: function() {
10774        var that = this;
10775
10776        return (
10777            that.suggestions.length > 1 ||
10778            (that.suggestions.length === 1 &&
10779                (!that.selection ||
10780                    $.trim(that.suggestions[0].value) !==
10781                        $.trim(that.selection.value)))
10782        );
10783    },
10784
10785    suggest: function() {
10786        var that = this,
10787            options = that.options,
10788            formatResult,
10789            html = [];
10790
10791        if (!that.requestMode.userSelect) {
10792            return;
10793        }
10794
10795        // если нечего показывать, то сообщаем об этом
10796        if (!that.hasSuggestionsToChoose()) {
10797            if (that.suggestions.length) {
10798                that.hide();
10799                return;
10800            } else {
10801                var noSuggestionsHint = that.getNoSuggestionsHint();
10802                if (noSuggestionsHint) {
10803                    html.push(
10804                        '<div class="' +
10805                            that.classes.hint +
10806                            '">' +
10807                            noSuggestionsHint +
10808                            "</div>"
10809                    );
10810                } else {
10811                    that.hide();
10812                    return;
10813                }
10814            }
10815        } else {
10816            // Build hint html
10817            if (options.hint && that.suggestions.length) {
10818                html.push(
10819                    '<div class="' +
10820                        that.classes.hint +
10821                        '">' +
10822                        options.hint +
10823                        "</div>"
10824                );
10825            }
10826            that.selectedIndex = -1;
10827            // Build suggestions inner HTML:
10828            that.suggestions.forEach(function(suggestion, i) {
10829                if (suggestion == that.selection) {
10830                    that.selectedIndex = i;
10831                }
10832                that.buildSuggestionHtml(suggestion, i, html);
10833            });
10834        }
10835
10836        html.push('<div class="' + CLASSES.promo + '"></div>');
10837        html.push("</div>");
10838
10839        that.$container.html(html.join(""));
10840
10841        // Select first value by default:
10842        if (options.autoSelectFirst && that.selectedIndex === -1) {
10843            that.selectedIndex = 0;
10844        }
10845        if (that.selectedIndex !== -1) {
10846            that.getSuggestionsItems()
10847                .eq(that.selectedIndex)
10848                .addClass(that.classes.selected);
10849        }
10850
10851        if ($.isFunction(options.beforeRender)) {
10852            options.beforeRender.call(that.element, that.$container);
10853        }
10854
10855        that.$container.show();
10856        that.visible = true;
10857    },
10858
10859    buildSuggestionHtml: function(suggestion, ordinal, html) {
10860		
10861		
10862        html.push(
10863            '<div class="' +
10864                this.classes.suggestion +
10865                '" data-index="' +
10866                ordinal +
10867                '" onclick="$(\'.dadata-fix\').attr(\'data-fix\', 1 );">'
10868        );
10869
10870		// FIX
10871		// console.log(suggestion
vendor: 11,671 bytes, lines 10871-11230
10871);
10872
10873        var formatResult =
10874            this.options.formatResult ||
10875            this.type.formatResult ||
10876            this.formatResult;
10877        html.push(
10878            formatResult.call(
10879                this,
10880                suggestion.value,
10881                this.currentValue,
10882                suggestion,
10883                {
10884                    unformattableTokens: this.type.unformattableTokens
10885                }
10886            )
10887        );
10888
10889        var labels = this.makeSuggestionLabel(this.suggestions, suggestion);
10890        if (labels) {
10891            html.push(
10892                '<span class="' +
10893                    this.classes.subtext_label +
10894                    '">' +
10895                    utils.escapeHtml(labels) +
10896                    "</span>"
10897            );
10898        }
10899        html.push("</div>");
10900    },
10901
10902    wrapFormattedValue: function(value, suggestion) {
10903        var that = this,
10904            status = utils.getDeepValue(suggestion.data, "state.status");
10905
10906        return (
10907            '<span class="' +
10908            that.classes.value +
10909            '"' +
10910            (status ? ' data-suggestion-status="' + status + '"' : "") +
10911            ">" +
10912            value +
10913            "</span>"
10914        );
10915    },
10916
10917    formatResult: function(value, currentValue, suggestion, options) {
10918        var that = this;
10919
10920        value = that.highlightMatches(value, currentValue, suggestion, options);
10921
10922        return that.wrapFormattedValue(value, suggestion);
10923    },
10924
10925    /**
10926     * Makes HTML contents for suggestion item
10927     * @param {String} value string to be displayed as a value
10928     * @param {String} currentValue contents of the textbox
10929     * @param suggestion whole suggestion object with displaying value and other fields
10930     * @param {Object} [options] set of flags:
10931     *          `unformattableTokens` - array of search tokens, that are not to be highlighted
10932     *          `maxLength` - if set, `value` is limited by this length
10933     * @returns {String} HTML to be inserted in the list
10934     */
10935    highlightMatches: function(value, currentValue, suggestion, options) {
10936        var that = this,
10937            chunks = [],
10938            unformattableTokens = options && options.unformattableTokens,
10939            maxLength = options && options.maxLength,
10940            tokens,
10941            tokenMatchers,
10942            preferredTokens,
10943            rWords = utils.reWordExtractor(),
10944            match,
10945            word,
10946            i,
10947            chunk,
10948            formattedStr;
10949
10950        if (!value) return "";
10951
10952        tokens = text_util.tokenize(currentValue, unformattableTokens);
10953
10954        tokenMatchers = $.map(tokens, function(token) {
10955            return new RegExp(
10956                "^((.*)([" +
10957                    WORD_PARTS_DELIMITERS +
10958                    "]+))?" +
10959                    "(" +
10960                    utils.escapeRegExChars(token) +
10961                    ")" +
10962                    "([^" +
10963                    WORD_PARTS_DELIMITERS +
10964                    "]*[" +
10965                    WORD_PARTS_DELIMITERS +
10966                    "]*)",
10967                "i"
10968            );
10969        });
10970
10971        // parse string by words
10972        while ((match = rWords.exec(value)) && match[0]) {
10973            word = match[1];
10974            chunks.push({
10975                text: word,
10976
10977                // upper case means a word is a name and can be highlighted even if presents in unformattableTokens
10978                hasUpperCase: word.toLowerCase() !== word,
10979                formatted: utils.formatToken(word),
10980                matchable: true
10981            });
10982            if (match[2]) {
10983                chunks.push({
10984                    text: match[2]
10985                });
10986            }
10987        }
10988
10989        // use simple loop because length can change
10990        for (i = 0; i < chunks.length; i++) {
10991            chunk = chunks[i];
10992            if (
10993                chunk.matchable &&
10994                !chunk.matched &&
10995                ($.inArray(chunk.formatted, unformattableTokens) === -1 ||
10996                    chunk.hasUpperCase)
10997            ) {
10998                $.each(tokenMatchers, function(j, matcher) {
10999                    var tokenMatch = matcher.exec(chunk.formatted),
11000                        length,
11001                        nextIndex = i + 1;
11002
11003                    if (tokenMatch) {
11004                        tokenMatch = {
11005                            before: tokenMatch[1] || "",
11006                            beforeText: tokenMatch[2] || "",
11007                            beforeDelimiter: tokenMatch[3] || "",
11008                            text: tokenMatch[4] || "",
11009                            after: tokenMatch[5] || ""
11010                        };
11011
11012                        if (tokenMatch.before) {
11013                            // insert chunk before current
11014                            chunks.splice(
11015                                i,
11016                                0,
11017                                {
11018                                    text: chunk.text.substr(
11019                                        0,
11020                                        tokenMatch.beforeText.length
11021                                    ),
11022                                    formatted: tokenMatch.beforeText,
11023                                    matchable: true
11024                                },
11025                                {
11026                                    text: tokenMatch.beforeDelimiter
11027                                }
11028                            );
11029                            nextIndex += 2;
11030
11031                            length = tokenMatch.before.length;
11032                            chunk.text = chunk.text.substr(length);
11033                            chunk.formatted = chunk.formatted.substr(length);
11034                            i--;
11035                        }
11036
11037                        length =
11038                            tokenMatch.text.length + tokenMatch.after.length;
11039                        if (chunk.formatted.length > length) {
11040                            chunks.splice(nextIndex, 0, {
11041                                text: chunk.text.substr(length),
11042                                formatted: chunk.formatted.substr(length),
11043                                matchable: true
11044                            });
11045                            chunk.text = chunk.text.substr(0, length);
11046                            chunk.formatted = chunk.formatted.substr(0, length);
11047                        }
11048
11049                        if (tokenMatch.after) {
11050                            length = tokenMatch.text.length;
11051                            chunks.splice(nextIndex, 0, {
11052                                text: chunk.text.substr(length),
11053                                formatted: chunk.formatted.substr(length)
11054                            });
11055                            chunk.text = chunk.text.substr(0, length);
11056                            chunk.formatted = chunk.formatted.substr(0, length);
11057                        }
11058                        chunk.matched = true;
11059                        return false;
11060                    }
11061                });
11062            }
11063        }
11064
11065        if (maxLength) {
11066            for (i = 0; i < chunks.length && maxLength >= 0; i++) {
11067                chunk = chunks[i];
11068                maxLength -= chunk.text.length;
11069                if (maxLength < 0) {
11070                    chunk.text =
11071                        chunk.text.substr(0, chunk.text.length + maxLength) +
11072                        "...";
11073                }
11074            }
11075            chunks.length = i;
11076        }
11077
11078        formattedStr = highlightMatches(chunks);
11079        return nowrapLinkedParts(formattedStr, that.classes.nowrap);
11080    },
11081
11082    makeSuggestionLabel: function(suggestions, suggestion) {
11083        var that = this,
11084            fieldNames = that.type.fieldNames,
11085            nameData = {},
11086            rWords = utils.reWordExtractor(),
11087            match,
11088            word,
11089            labels = [];
11090
11091        if (
11092            fieldNames &&
11093            hasAnotherSuggestion(suggestions, suggestion) &&
11094            suggestion.data
11095        ) {
11096            $.each(fieldNames, function(field) {
11097                var value = suggestion.data[field];
11098                if (value) {
11099                    nameData[field] = utils.formatToken(value);
11100                }
11101            });
11102
11103            if (!$.isEmptyObject(nameData)) {
11104                while (
11105                    (match = rWords.exec(
11106                        utils.formatToken(suggestion.value)
11107                    )) &&
11108                    (word = match[1])
11109                ) {
11110                    $.each(nameData, function(i, value) {
11111                        if (value == word) {
11112                            labels.push(fieldNames[i]);
11113                            delete nameData[i];
11114                            return false;
11115                        }
11116                    });
11117                }
11118
11119                if (labels.length) {
11120                    return labels.join(", ");
11121                }
11122            }
11123        }
11124    },
11125
11126    hide: function() {
11127        var that = this;
11128        that.visible = false;
11129        that.selectedIndex = -1;
11130        that.$container.hide().empty();
11131    },
11132
11133    activate: function(index) {
11134        var that = this,
11135            $activeItem,
11136            selected = that.classes.selected,
11137            $children;
11138
11139        if (!that.dropdownDisabled) {
11140            $children = that.getSuggestionsItems();
11141
11142            $children.removeClass(selected);
11143
11144            that.selectedIndex = index;
11145
11146            if (
11147                that.selectedIndex !== -1 &&
11148                $children.length > that.selectedIndex
11149            ) {
11150                $activeItem = $children.eq(that.selectedIndex);
11151                $activeItem.addClass(selected);
11152                return $activeItem;
11153            }
11154        }
11155
11156        return null;
11157    },
11158
11159    deactivate: function(restoreValue) {
11160        var that = this;
11161
11162        if (!that.dropdownDisabled) {
11163            that.selectedIndex = -1;
11164            that.getSuggestionsItems().removeClass(that.classes.selected);
11165            if (restoreValue) {
11166                that.el.val(that.currentValue);
11167            }
11168        }
11169    },
11170
11171    moveUp: function() {
11172        var that = this;
11173
11174        if (that.dropdownDisabled) {
11175            return;
11176        }
11177        if (that.selectedIndex === -1) {
11178            if (that.suggestions.length) {
11179                that.adjustScroll(that.suggestions.length - 1);
11180            }
11181            return;
11182        }
11183
11184        if (that.selectedIndex === 0) {
11185            that.deactivate(true);
11186            return;
11187        }
11188
11189        that.adjustScroll(that.selectedIndex - 1);
11190    },
11191
11192    moveDown: function() {
11193        var that = this;
11194
11195        if (that.dropdownDisabled) {
11196            return;
11197        }
11198        if (that.selectedIndex === that.suggestions.length - 1) {
11199            that.deactivate(true);
11200            return;
11201        }
11202
11203        that.adjustScroll(that.selectedIndex + 1);
11204    },
11205
11206    adjustScroll: function(index) {
11207        var that = this,
11208            $activeItem = that.activate(index),
11209            itemTop,
11210            itemBottom,
11211            scrollTop = that.$container.scrollTop(),
11212            containerHeight;
11213
11214        if (!$activeItem || !$activeItem.length) {
11215            return;
11216        }
11217
11218        itemTop = $activeItem.position().top;
11219        if (itemTop < 0) {
11220            that.$container.scrollTop(scrollTop + itemTop);
11221        } else {
11222            itemBottom = itemTop + $activeItem.outerHeight();
11223            containerHeight = that.$container.innerHeight();
11224            if (itemBottom > containerHeight) {
11225                that.$container.scrollTop(
11226                    scrollTop - containerHeight + itemBottom
11227                );
11228            }
11229        }
11230
11231
11232
11233        that.el.val(that.suggestions[index].value);
11234    }
11235};
11236
11237$.extend(DEFAULT_OPTIONS, optionsUsed);
11238
11239$.extend(Suggestions.prototype, methods$4);
11240
11241notificator
11242    .on("initialize", methods$4.createContainer)
11243    .on("dispose", methods$4.removeContainer)
11244    .on("setOptions", methods$4.setContainerOptions)
11245    .on("ready", methods$4.showContainer)
11246    .on("assignSuggestions", methods$4.suggest);
11247
11248/**
11249 * Methods related to CONSTRAINTS component
11250 */
11251var optionsUsed$1 = {
11252    constraints: null,
11253    restrict_value: false
11254};
11255
11256var fiasParamNames = [
11257    "country_iso_code",
11258    "region_iso_code",
11259    "region_fias_id",
11260    "area_fias_id",
11261    "city_fias_id",
11262    "city_district_fias_id",
11263    "settlement_fias_id",
11264    "planning_structure_fias_id",
11265    "street_fias_id"
11266];
11267
11268/**
11269 * Compares two suggestion objects
11270 * @param suggestion
11271 * @param instance other Suggestions instance
11272 */
11273function belongsToArea(suggestion, instance) {
11274    var parentSuggestion = instance.selection,
11275        result = parentSuggestion && parentSuggestion.data && instance.bounds;
11276
11277    if (result) {
11278        collection_util.each(instance.bounds.all, function(bound, i) {
11279            return (result =
11280                parentSuggestion.data[bound] === suggestion.data[bound]);
11281        });
11282    }
11283	
vendor: 20,146 bytes, lines 11283-11939
11283
11284    return result;
11285}
11286
11287/**
11288 * Возвращает КЛАДР-код, обрезанный до последнего непустого уровня
11289 * 50 000 040 000 00 → 50 000 040
11290 * @param kladr_id
11291 * @returns {string}
11292 */
11293function getSignificantKladrId(kladr_id) {
11294    var significantKladrId = kladr_id.replace(/^(\d{2})(\d*?)(0+)$/g, "$1$2");
11295    var length = significantKladrId.length;
11296    var significantLength = -1;
11297    if (length <= 2) {
11298        significantLength = 2;
11299    } else if (length > 2 && length <= 5) {
11300        significantLength = 5;
11301    } else if (length > 5 && length <= 8) {
11302        significantLength = 8;
11303    } else if (length > 8 && length <= 11) {
11304        significantLength = 11;
11305    } else if (length > 11 && length <= 15) {
11306        significantLength = 15;
11307    } else if (length > 15) {
11308        significantLength = 19;
11309    }
11310    return text_util.padEnd(significantKladrId, significantLength, "0");
11311}
11312
11313/**
11314 * @param {Object} data  fields
11315 * @param {Suggestions} instance
11316 * @constructor
11317 */
11318var ConstraintLocation = function(data, instance) {
11319    var that = this,
11320        fieldNames,
11321        fiasFieldNames,
11322        fiasFields = {};
11323
11324    that.instance = instance;
11325    that.fields = {};
11326    that.specificity = -1;
11327
11328    if (lang_util.isPlainObject(data) && instance.type.dataComponents) {
11329        collection_util.each(instance.type.dataComponents, function(
11330            component,
11331            i
11332        ) {
11333            var fieldName = component.id;
11334
11335            if (component.forLocations && data[fieldName]) {
11336                that.fields[fieldName] = data[fieldName];
11337                that.specificity = i;
11338            }
11339        });
11340    }
11341
11342    fieldNames = Object.keys(that.fields);
11343    fiasFieldNames = collection_util.intersect(fieldNames, fiasParamNames);
11344    if (fiasFieldNames.length) {
11345        collection_util.each(fiasFieldNames, function(fieldName, index) {
11346            fiasFields[fieldName] = that.fields[fieldName];
11347        });
11348        that.fields = fiasFields;
11349        that.specificity = that.getFiasSpecificity(fiasFieldNames);
11350    } else if (that.fields.kladr_id) {
11351        that.fields = { kladr_id: that.fields.kladr_id };
11352        that.significantKladr = getSignificantKladrId(that.fields.kladr_id);
11353        that.specificity = that.getKladrSpecificity(that.significantKladr);
11354    }
11355};
11356
11357jqapi.extend(ConstraintLocation.prototype, {
11358    getLabel: function() {
11359        return this.instance.type.composeValue(this.fields, {
11360            saveCityDistrict: true
11361        });
11362    },
11363
11364    getFields: function() {
11365        return this.fields;
11366    },
11367
11368    isValid: function() {
11369        return !lang_util.isEmptyObject(this.fields);
11370    },
11371
11372    /**
11373     * Возвращает specificity для КЛАДР
11374     * Описание ниже, в getFiasSpecificity
11375     * @param kladr_id
11376     * @returns {number}
11377     */
11378    getKladrSpecificity: function(kladr_id) {
11379        var specificity = -1;
11380        var kladrLength = kladr_id.length;
11381
11382        collection_util.each(this.instance.type.dataComponents, function(
11383            component,
11384            i
11385        ) {
11386            if (
11387                component.kladrFormat &&
11388                kladrLength === component.kladrFormat.digits
11389            ) {
11390                specificity = i;
11391            }
11392        });
11393
11394        return specificity;
11395    },
11396
11397    /**
11398     * Возвращает особую величину specificity для ФИАС
11399     * Specificity это индекс для массива this.instance.type.dataComponents
11400     * до которого (включительно) обрежется этот массив при формировании строки адреса.
11401     * Этот параметр нужен для случаев, когда в настройках плагина restrict_value = true
11402     * Например, установлено ограничение (locations) по region_fias_id (Краснодарский край)
11403     * В выпадашке нажимаем на "г. Сочи"
11404     * Если restrict_value отключен, то выведется значение "Краснодарский край, г Сочи"
11405     * Если включен, то просто "г Сочи"
11406     *
11407     * @param fiasFieldNames
11408     * @returns {number}
11409     */
11410    getFiasSpecificity: function(fiasFieldNames) {
11411        var specificity = -1;
11412
11413        collection_util.each(this.instance.type.dataComponents, function(
11414            component,
11415            i
11416        ) {
11417            if (
11418                component.fiasType &&
11419                fiasFieldNames.indexOf(component.fiasType) > -1 &&
11420                specificity < i
11421            ) {
11422                specificity = i;
11423            }
11424        });
11425
11426        return specificity;
11427    },
11428
11429    containsData: function(data) {
11430        var result = true;
11431
11432        if (this.fields.kladr_id) {
11433            return (
11434                !!data.kladr_id &&
11435                data.kladr_id.indexOf(this.significantKladr) === 0
11436            );
11437        } else {
11438            collection_util.each(this.fields, function(value, fieldName) {
11439                return (result =
11440                    !!data[fieldName] &&
11441                    data[fieldName].toLowerCase() === value.toLowerCase());
11442            });
11443
11444            return result;
11445        }
11446    }
11447});
11448
11449Suggestions.ConstraintLocation = ConstraintLocation;
11450
11451/**
11452 * @param {Object} data
11453 * @param {Object|Array} data.locations
11454 * @param {string} [data.label]
11455 * @param {boolean} [data.deletable]
11456 * @param {Suggestions} [instance]
11457 * @constructor
11458 */
11459var Constraint = function(data, instance) {
11460    this.id = generateId("c");
11461    this.deletable = !!data.deletable;
11462    this.instance = instance;
11463
11464    var locationsArray = collection_util.makeArray(
11465        data && (data.locations || data.restrictions)
11466    );
11467    this.locations = locationsArray.map(function(data) {
11468        return new ConstraintLocation(data, instance);
11469    });
11470
11471    this.locations = this.locations.filter(function(location) {
11472        return location.isValid();
11473    });
11474
11475    this.label = data.label;
11476    if (this.label == null && instance.type.composeValue) {
11477        this.label = this.locations
11478            .map(function(location) {
11479                return location.getLabel();
11480            })
11481            .join(", ");
11482    }
11483};
11484
11485jqapi.extend(Constraint.prototype, {
11486    isValid: function() {
11487        return this.locations.length > 0;
11488    },
11489    getFields: function() {
11490        return this.locations.map(function(location) {
11491            return location.getFields();
11492        });
11493    }
11494});
11495
11496var methods$5 = {
11497    createConstraints: function() {
11498        var that = this;
11499        that.constraints = {};
11500    },
11501    setupConstraints: function() {
11502        var that = this,
11503            constraints = that.options.constraints,
11504            $parent;
11505
11506        if (!constraints) {
11507            that.unbindFromParent();
11508            return;
11509        }
11510
11511        if (
11512            jqapi.isJqObject(constraints) ||
11513            typeof constraints === "string" ||
11514            typeof constraints.nodeType === "number"
11515        ) {
11516            $parent = jqapi.select(constraints);
11517            if (!$parent.is(that.constraints)) {
11518                that.unbindFromParent();
11519                if (!$parent.is(that.el)) {
11520                    that.constraints = $parent;
11521                    that.bindToParent();
11522                }
11523            }
11524        } else {
11525            collection_util.each(that.constraints, function(_, id) {
11526                that.removeConstraint(id);
11527            });
11528            collection_util.each(
11529                collection_util.makeArray(constraints),
11530                function(constraint, i) {
11531                    that.addConstraint(constraint);
11532                }
11533            );
11534        }
11535    },
11536
11537    filteredLocation: function(data) {
11538        var locationComponents = [],
11539            location = {};
11540
11541        collection_util.each(this.type.dataComponents, function() {
11542            if (this.forLocations) locationComponents.push(this.id);
11543        });
11544
11545        if (lang_util.isPlainObject(data)) {
11546            // Copy to location only allowed fields
11547            collection_util.each(data, function(value, key) {
11548                if (value && locationComponents.indexOf(key) >= 0) {
11549                    location[key] = value;
11550                }
11551            });
11552        }
11553
11554        if (!lang_util.isEmptyObject(location)) {
11555            return location.kladr_id
11556                ? { kladr_id: location.kladr_id }
11557                : location;
11558        }
11559    },
11560
11561    addConstraint: function(constraint) {
11562        var that = this;
11563
11564        constraint = new Constraint(constraint, that);
11565
11566        if (constraint.isValid()) {
11567            that.constraints[constraint.id] = constraint;
11568        }
11569    },
11570
11571    removeConstraint: function(id) {
11572        var that = this;
11573        delete that.constraints[id];
11574    },
11575
11576    constructConstraintsParams: function() {
11577        var that = this,
11578            locations = [],
11579            constraints = that.constraints,
11580            parentInstance,
11581            parentData,
11582            params = {};
11583
11584        while (
11585            jqapi.isJqObject(constraints) &&
11586            (parentInstance = constraints.suggestions()) &&
11587            !(parentData = object_util.getDeepValue(
11588                parentInstance,
11589                "selection.data"
11590            ))
11591        ) {
11592            constraints = parentInstance.constraints;
11593        }
11594
11595        if (jqapi.isJqObject(constraints)) {
11596            parentData = new ConstraintLocation(
11597                parentData,
11598                parentInstance
11599            ).getFields();
11600
11601            if (parentData) {
11602                // if send city_fias_id for city request
11603                // then no cities will responded
11604                if (that.bounds.own.indexOf("city") > -1) {
11605                    delete parentData.city_fias_id;
11606                }
11607                params.locations = [parentData];
11608                params.restrict_value = true;
11609            }
11610        } else {
11611            if (constraints) {
11612                collection_util.each(constraints, function(constraint, id) {
11613                    locations = locations.concat(constraint.getFields());
11614                });
11615
11616                if (locations.length) {
11617                    params.locations = locations;
11618                    params.restrict_value = that.options.restrict_value;
11619                }
11620            }
11621        }
11622
11623        return params;
11624    },
11625
11626    /**
11627     * Returns label of the first constraint (if any), empty string otherwise
11628     * @returns {String}
11629     */
11630    getFirstConstraintLabel: function() {
11631        var that = this,
11632            constraints_id =
11633                lang_util.isPlainObject(that.constraints) &&
11634                Object.keys(that.constraints)[0];
11635
11636        return constraints_id ? that.constraints[constraints_id].label : "";
11637    },
11638
11639    bindToParent: function() {
11640        var that = this;
11641
11642        that.constraints
11643            .on(
11644                [
11645                    "suggestions-select." + that.uniqueId,
11646                    "suggestions-invalidateselection." + that.uniqueId,
11647                    "suggestions-clear." + that.uniqueId
11648                ].join(" "),
11649                jqapi.proxy(that.onParentSelectionChanged, that)
11650            )
11651            .on(
11652                "suggestions-dispose." + that.uniqueId,
11653                jqapi.proxy(that.onParentDispose, that)
11654            );
11655    },
11656
11657    unbindFromParent: function() {
11658        var that = this,
11659            $parent = that.constraints;
11660
11661        if (jqapi.isJqObject($parent)) {
11662            $parent.off("." + that.uniqueId);
11663        }
11664    },
11665
11666    onParentSelectionChanged: function(e, suggestion, valueChanged) {
11667        // Don't clear if parent has been just enriched
11668        if (e.type !== "suggestions-select" || valueChanged) {
11669            this.clear();
11670        }
11671    },
11672
11673    onParentDispose: function(e) {
11674        this.unbindFromParent();
11675    },
11676
11677    getParentInstance: function() {
11678        return (
11679            jqapi.isJqObject(this.constraints) && this.constraints.suggestions()
11680        );
11681    },
11682
11683    shareWithParent: function(suggestion) {
11684        // that is the parent control's instance
11685        var that = this.getParentInstance();
11686
11687        if (
11688            !that ||
11689            that.type !== this.type ||
11690            belongsToArea(suggestion, that)
11691        ) {
11692            return;
11693        }
11694
11695        that.shareWithParent(suggestion);
11696        that.setSuggestion(suggestion);
11697    },
11698
11699    /**
11700     * Pick only fields that absent in restriction
11701     */
11702    getUnrestrictedData: function(data) {
11703        var that = this,
11704            restrictedKeys = [],
11705            unrestrictedData = {},
11706            maxSpecificity = -1;
11707
11708        // Find most specific location that could restrict current data
11709        collection_util.each(that.constraints, function(constraint, id) {
11710            collection_util.each(constraint.locations, function(location, i) {
11711                if (
11712                    location.containsData(data) &&
11713                    location.specificity > maxSpecificity
11714                ) {
11715                    maxSpecificity = location.specificity;
11716                }
11717            });
11718        });
11719
11720        if (maxSpecificity >= 0) {
11721            // Для городов-регионов нужно также отсечь и город
11722            if (
11723                data.region_kladr_id &&
11724                data.region_kladr_id === data.city_kladr_id
11725            ) {
11726                restrictedKeys.push.apply(
11727                    restrictedKeys,
11728                    that.type.dataComponentsById["city"].fields
11729                );
11730            }
11731
11732            // Collect all fieldnames from all restricted components
11733            collection_util.each(
11734                that.type.dataComponents.slice(0, maxSpecificity + 1),
11735                function(component, i) {
11736                    restrictedKeys.push.apply(restrictedKeys, component.fields);
11737                }
11738            );
11739
11740            // Copy skipping restricted fields
11741            collection_util.each(data, function(value, key) {
11742                if (restrictedKeys.indexOf(key) === -1) {
11743                    unrestrictedData[key] = value;
11744                }
11745            });
11746        } else {
11747            unrestrictedData = data;
11748        }
11749
11750        return unrestrictedData;
11751    }
11752};
11753
11754jqapi.extend(DEFAULT_OPTIONS, optionsUsed$1);
11755
11756jqapi.extend(Suggestions.prototype, methods$5);
11757
11758// Disable this feature when GET method used. See SUG-202
11759if (ajax.getDefaultType() != "GET") {
11760    notificator
11761        .on("initialize", methods$5.createConstraints)
11762        .on("setOptions", methods$5.setupConstraints)
11763        .on("requestParams", methods$5.constructConstraintsParams)
11764        .on("dispose", methods$5.unbindFromParent);
11765}
11766
11767/**
11768 * Methods for selecting a suggestion
11769 */
11770
11771var methods$6 = {
11772    proceedQuery: function(query) {
11773        var that = this;
11774
11775        if (query.length >= that.options.minChars) {
11776            that.updateSuggestions(query);
11777        } else {
11778            that.hide();
11779        }
11780    },
11781
11782    /**
11783     * Selects current or first matched suggestion, but firstly waits for data ready
11784     * @param selectionOptions
11785     * @returns {$.Deferred} promise, resolved with index of selected suggestion or rejected if nothing matched
11786     */
11787    selectCurrentValue: function(selectionOptions) {
11788        var that = this,
11789            result = jqapi.Deferred();
11790
11791        // force onValueChange to be executed if it has been deferred
11792        that.inputPhase.resolve();
11793
11794        that.fetchPhase
11795            .done(function() {
11796                var index;
11797
11798                // When suggestion has already been selected and not modified
11799                if (that.selection && !that.visible) {
11800                    result.reject();
11801                } else {
11802                    index = that.findSuggestionIndex();
11803
11804                    that.select(index, selectionOptions);
11805
11806                    if (index === -1) {
11807                        result.reject();
11808                    } else {
11809                        result.resolve(index);
11810                    }
11811                }
11812            })
11813            .fail(function() {
11814                result.reject();
11815            });
11816
11817        return result;
11818    },
11819
11820    /**
11821     * Selects first when user interaction is not supposed
11822     */
11823    selectFoundSuggestion: function() {
11824        var that = this;
11825
11826        if (!that.requestMode.userSelect) {
11827            that.select(0);
11828        }
11829    },
11830
11831    /**
11832     * Selects current or first matched suggestion
11833     * @returns {number} index of found suggestion
11834     */
11835    findSuggestionIndex: function() {
11836        var that = this,
11837            index = that.selectedIndex,
11838            value;
11839
11840        if (index === -1) {
11841            // matchers always operate with trimmed strings
11842            value = that.el.val().trim();
11843            if (value) {
11844                that.type.matchers.some(function(matcher) {
11845                    index = matcher(value, that.suggestions);
11846                    return index !== -1;
11847                });
11848            }
11849        }
11850
11851        return index;
11852    },
11853
11854    /**
11855     * Selects a suggestion at specified index
11856     * @param index index of suggestion to select. Can be -1
11857     * @param {Object} selectionOptions
11858     * @param {boolean} [selectionOptions.continueSelecting]  prevents hiding after selection
11859     * @param {boolean} [selectionOptions.noSpace]  prevents adding space at the end of current value
11860     */
11861    select: function(index, selectionOptions) {
11862        var that = this,
11863            suggestion = that.suggestions[index],
11864            continueSelecting =
11865                selectionOptions && selectionOptions.continueSelecting,
11866            currentValue = that.currentValue,
11867            hasSameValues;
11868
11869        // Prevent recursive execution
11870        if (that.triggering["Select"]) return;
11871
11872        // if no suggestion to select
11873        if (!suggestion) {
11874            if (!continueSelecting && !that.selection) {
11875                that.triggerOnSelectNothing();
11876            }
11877            that.onSelectComplete(continueSelecting);
11878            return;
11879        }
11880
11881        hasSameValues = that.hasSameValues(suggestion);
11882
11883        that.enrichSuggestion(suggestion, selectionOptions).done(function(
11884            enrichedSuggestion,
11885            hasBeenEnriched
11886        ) {
11887            var newSelectionOptions = jqapi.extend(
11888                {
11889                    hasBeenEnriched: hasBeenEnriched,
11890                    hasSameValues: hasSameValues
11891                },
11892                selectionOptions
11893            );
11894            that.selectSuggestion(
11895                enrichedSuggestion,
11896                index,
11897                currentValue,
11898                newSelectionOptions
11899            );
11900        });
11901    },
11902
11903    /**
11904     * Formats and selects final (enriched) suggestion
11905     * @param suggestion
11906     * @param index
11907     * @param lastValue
11908     * @param {Object} selectionOptions
11909     * @param {boolean} [selectionOptions.continueSelecting]  prevents hiding after selection
11910     * @param {boolean} [selectionOptions.noSpace]  prevents adding space at the end of current value
11911     * @param {boolean} selectionOptions.hasBeenEnriched
11912     * @param {boolean} selectionOptions.hasSameValues
11913     */
11914    selectSuggestion: function(suggestion, index, lastValue, selectionOptions) {
11915        var that = this,
11916            continueSelecting = selectionOptions.continueSelecting,
11917            assumeDataComplete =
11918                !that.type.isDataComplete ||
11919                that.type.isDataComplete.call(that, suggestion),
11920            currentSelection = that.selection;
11921
11922        // Prevent recursive execution
11923        if (that.triggering["Select"]) return;
11924
11925        if (that.type.alwaysContinueSelecting) {
11926            continueSelecting = true;
11927        }
11928
11929        if (assumeDataComplete) {
11930            continueSelecting = false;
11931        }
11932
11933        // `suggestions` cat be empty, e.g. during `fixData`
11934        if (selectionOptions.hasBeenEnriched && that.suggestions[index]) {
11935            that.suggestions[index].data = suggestion.data;
11936        }
11937
11938        if (that.requestMode.updateValue) {
11939            that.checkValueBounds(suggestion);
11940			
11941            that.currentValue = that.getSuggestionValue(
11942                suggestion,
11943                selectionOptions
11944            );
11945
11946            if (
11947                that.currentValue &&
11948                !selectionOptions.noSpace &&
11949                !assumeDataComplete
11950            ) {
11951                that.currentValue += " ";
11952            }
11953            that.el.val(that.currentValue);
11954			
11955			
vendor: 12,974 bytes, lines 11955-12321
11955
11956        }
11957
11958        if (that.currentValue) {
11959            that.selection = suggestion;
11960            if (!that.areSuggestionsSame(suggestion, currentSelection)) {
11961                that.trigger(
11962                    "Select",
11963                    suggestion,
11964                    that.currentValue != lastValue
11965                );
11966            }
11967            if (that.requestMode.userSelect) {
11968                that.onSelectComplete(continueSelecting);
11969            }
11970        } else {
11971            that.selection = null;
11972            that.triggerOnSelectNothing();
11973        }
11974
11975        that.shareWithParent(suggestion);
11976    },
11977
11978    onSelectComplete: function(continueSelecting) {
11979        var that = this;
11980
11981        if (continueSelecting) {
11982            that.selectedIndex = -1;
11983            that.updateSuggestions(that.currentValue);
11984        } else {
11985            that.hide();
11986        }
11987    },
11988
11989    triggerOnSelectNothing: function() {
11990        var that = this;
11991
11992        if (!that.triggering["SelectNothing"]) {
11993            that.trigger("SelectNothing", that.currentValue);
11994        }
11995    },
11996
11997    trigger: function(event) {
11998        var that = this,
11999            args = utils.slice(arguments, 1),
12000            callback = that.options["on" + event];
12001
12002        that.triggering[event] = true;
12003        if (utils.isFunction(callback)) {
12004            callback.apply(that.element, args);
12005        }
12006        that.el.trigger.call(
12007            that.el,
12008            "suggestions-" + event.toLowerCase(),
12009            args
12010        );
12011        that.triggering[event] = false;
12012    }
12013};
12014
12015jqapi.extend(Suggestions.prototype, methods$6);
12016
12017notificator.on("assignSuggestions", methods$6.selectFoundSuggestion);
12018
12019/**
12020 * features for connected instances
12021 */
12022
12023var optionsUsed$2 = {
12024    bounds: null,
12025};
12026
12027var methods$7 = {
12028    setupBounds: function() {
12029        this.bounds = {
12030            from: null,
12031            to: null,
12032        };
12033    },
12034
12035    setBoundsOptions: function() {
12036        var that = this,
12037            boundsAvailable = [],
12038            newBounds = $.trim(that.options.bounds).split("-"),
12039            boundFrom = newBounds[0],
12040            boundTo = newBounds[newBounds.length - 1],
12041            boundsOwn = [],
12042            boundIsOwn,
12043            boundsAll = [];
12044
12045        if (that.type.dataComponents) {
12046            $.each(that.type.dataComponents, function() {
12047                if (this.forBounds) {
12048                    boundsAvailable.push(this.id);
12049                }
12050            });
12051        }
12052
12053        if (boundsAvailable.indexOf(boundFrom) === -1) {
12054            boundFrom = null;
12055        }
12056
12057        if (boundsAvailable.indexOf(boundTo) === -1) {
12058            boundTo = null;
12059        }
12060
12061        if (boundFrom || boundTo) {
12062            boundIsOwn = !boundFrom;
12063            $.each(boundsAvailable, function(i, bound) {
12064                if (bound == boundFrom) {
12065                    boundIsOwn = true;
12066                }
12067                boundsAll.push(bound);
12068                if (boundIsOwn) {
12069                    boundsOwn.push(bound);
12070                }
12071                if (bound == boundTo) {
12072                    return false;
12073                }
12074            });
12075        }
12076
12077        that.bounds.from = boundFrom;
12078        that.bounds.to = boundTo;
12079        that.bounds.all = boundsAll;
12080        that.bounds.own = boundsOwn;
12081    },
12082
12083    constructBoundsParams: function() {
12084        var that = this,
12085            params = {};
12086
12087        if (that.bounds.from) {
12088            params["from_bound"] = { value: that.bounds.from };
12089        }
12090        if (that.bounds.to) {
12091            params["to_bound"] = { value: that.bounds.to };
12092        }
12093
12094        return params;
12095    },
12096
12097    /**
12098     * Подстраивает suggestion.value под that.bounds.own
12099     * Ничего не возвращает, меняет в самом suggestion
12100     * @param suggestion
12101     */
12102    checkValueBounds: function(suggestion) {
12103        var that = this,
12104            valueData;
12105
12106        // If any bounds set up
12107        if (that.bounds.own.length && that.type.composeValue) {
12108            // делаем копию
12109            var bounds = that.bounds.own.slice(0);
12110            // если роль текущего инстанса плагина показывать только район города
12111            // то для корректного формировния нужен city_district_fias_id
12112            if (bounds.length === 1 && bounds[0] === "city_district") {
12113                bounds.push("city_district_fias_id");
12114            }
12115            valueData = that.copyDataComponents(suggestion.data, bounds);
12116            suggestion.value = that.type.composeValue(valueData);
12117        }
12118    },
12119
12120    copyDataComponents: function(data, components) {
12121        var result = {},
12122            dataComponentsById = this.type.dataComponentsById;
12123
12124        if (dataComponentsById) {
12125            $.each(components, function(i, component) {
12126                $.each(dataComponentsById[component].fields, function(
12127                    i,
12128                    field
12129                ) {
12130                    if (data[field] != null) {
12131                        result[field] = data[field];
12132                    }
12133                });
12134            });
12135        }
12136
12137        return result;
12138    },
12139
12140    getBoundedKladrId: function(kladr_id, boundsRange) {
12141        var boundTo = boundsRange[boundsRange.length - 1],
12142            kladrFormat;
12143
12144        $.each(this.type.dataComponents, function(i, component) {
12145            if (component.id === boundTo) {
12146                kladrFormat = component.kladrFormat;
12147                return false;
12148            }
12149        });
12150
12151        return (
12152            kladr_id.substr(0, kladrFormat.digits) +
12153            new Array((kladrFormat.zeros || 0) + 1).join("0")
12154        );
12155    },
12156};
12157
12158$.extend(DEFAULT_OPTIONS, optionsUsed$2);
12159
12160$.extend(Suggestions.prototype, methods$7);
12161
12162notificator
12163    .on("initialize", methods$7.setupBounds)
12164    .on("setOptions", methods$7.setBoundsOptions)
12165    .on("requestParams", methods$7.constructBoundsParams);
12166
12167/**
12168 * Утилиты для работы с DOM.
12169 */
12170var dom = {
12171    /**
12172     * Выбрать первый элемент с указанным классом.
12173     */
12174    selectByClass: function(classname, parent) {
12175        var selector = "." + classname;
12176        if (parent) {
12177            return parent.querySelector(selector);
12178        } else {
12179            return document.querySelector(selector);
12180        }
12181    },
12182
12183    /**
12184     * Добавить элементу класс.
12185     */
12186    addClass: function(element, className) {
12187        var list = element.className.split(" ");
12188        if (list.indexOf(className) === -1) {
12189            list.push(className);
12190        }
12191        element.className = list.join(" ");
12192    },
12193
12194    /**
12195     * Добавить элементу стиль.
12196     */
12197    setStyle: function(element, name, value) {
12198        element.style[name] = value;
12199    },
12200
12201    /**
12202     * Подписаться на событие на элементе.
12203     * @param {Element} element - элемент
12204     * @param {string} eventName - название события
12205     * @param {string} namespace - пространство имён события
12206     * @param {Function} callback - функция-обработчик события
12207     */
12208    listenTo: function(element, eventName, namespace, callback) {
12209        element.addEventListener(eventName, callback, false);
12210        if (namespace) {
12211            if (!eventsByNamespace[namespace]) {
12212                eventsByNamespace[namespace] = [];
12213            }
12214            eventsByNamespace[namespace].push({
12215                eventName: eventName,
12216                element: element,
12217                callback: callback
12218            });
12219        }
12220    },
12221
12222    /**
12223     * Отписаться от всех событий с указанным пространством имён.
12224     */
12225    stopListeningNamespace: function(namespace) {
12226        var events = eventsByNamespace[namespace];
12227        if (events) {
12228            events.forEach(function(event) {
12229                event.element.removeEventListener(
12230                    event.eventName,
12231                    event.callback,
12232                    false
12233                );
12234            });
12235        }
12236    }
12237};
12238
12239/**
12240 * Промо-ссылка в списке подсказок.
12241 */
12242var FREE_PLAN = "FREE";
12243var LINK =
12244    "https://dadata.ru/suggestions/?utm_source=dadata&utm_medium=module&utm_campaign=suggestions-jquery";
12245var PREFIX = "";
12246var SUFFIX = "";
12247var IMAGE =
12248    '<svg version="1.1" viewBox="0 0 128 38" xmlns="http://www.w3.org/2000/svg"><path d="m128 19v16.077c0 1.614-1.302 2.923-2.909 2.923h-122.18c-1.607 0-2.909-1.309-2.909-2.923v-32.154c-0-1.614 1.302-2.923 2.909-2.923h122.18c1.607 0 2.909 1.309 2.909 2.923z" fill="#ef4741"/><path d="m59.52 7.912h-8.902v22.098h9.92c3.724 0 9.872-0.341 9.872-6.703v-8.682c-0.01-6.372-7.166-6.713-10.89-6.713zm5.595 14.81c0 3.186-2.308 3.508-4.936 3.508h-4.276v-14.538h3.287c2.628 0 5.954 0.322 5.954 3.508zm-46.545-14.81h-8.834v22.098h9.871c3.724 0 9.872-0.341 9.872-6.703v-8.682c0-6.372-7.137-6.713-10.88-6.713zm5.595 14.81c0 3.186-2.308 3.508-4.936 3.508h-4.247v-14.538h3.258c2.628 0 5.954 0.322 5.954 3.508zm71.757-13.953h-4.945v16.301c-0.018 0.785 0.113 1.565 0.388 2.3 0.203 0.569 0.535 1.082 0.97 1.5 0.446 0.385 0.962 0.677 1.522 0.858 0.58 0.205 1.182 0.343 1.794 0.409 0.575 0.052 1.248 0.081 2.017 0.088 0.917-1e-3 1.834-0.057 2.744-0.166v-2.796h-1.765c-0.393 0.055-0.795 0.032-1.18-0.071-0.385-0.102-0.745-0.28-1.06-0.524-0.413-0.691-0.59-1.498-0.504-2.299v-8.068h4.509v-3.06h-4.509zm20.364 5.535c-1.176-0.741-3.278-1.108-6.303-1.101h-5.741v0.243l0.708 2.826h5.033c0.837-0.051 1.672 0.117 2.424 0.487 0.259 0.248 0.458 0.553 0.579 0.891 0.121 0.339 0.162 0.701 0.119 1.058v1.12h-5.527c-1.939 0-3.271 0.38-3.995 1.14-0.725 0.76-1.099 2.127-1.125 4.102 0 2.154 0.359 3.06 1.086 3.742 0.728 0.682 2.134 1.188 4.344 1.188h6.847c1.706 0 3.345-0.808 3.345-2.747v-8.584c0-2.176-0.589-3.635-1.765-4.375zm-3.19 12.959h-3.249c-0.735 0.081-1.478-0.036-2.152-0.342-0.285-0.227-0.427-0.876-0.427-1.948s0.136-1.741 0.407-2.007c0.625-0.331 1.336-0.46 2.037-0.371h3.384zm-26.667-12.959c-1.176-0.741-3.277-1.108-6.303-1.101h-5.741v0.243l0.708 2.826h5.033c0.836-0.051 1.672 0.117 2.424 0.487 0.259 0.248 0.457 0.553 0.578 0.891 0.121 0.339 0.162 0.701 0.12 1.058v1.12h-5.556c-1.939 0-3.271 0.38-3.995 1.14s-1.086 2.127-1.086 4.102c0 2.154 0.359 3.06 1.086 3.742s2.133 1.188 4.344 1.188h6.846c1.717 0 3.346-0.808 3.346-2.747v-8.584c-7e-3 -2.176-0.595-3.635-1.765-4.375zm-3.181 12.959h-3.248c-0.735 0.081-1.478-0.037-2.153-0.342-0.284-0.227-0.426-0.876-0.426-1.948s0.135-1.741 0.407-2.007c0.624-0.331 1.336-0.46 2.036-0.371h3.384zm-37.74-12.959c-1.176-0.741-3.278-1.108-6.303-1.101h-5.712v0.243l0.708 2.826h5.033c0.837-0.051 1.672 0.117 2.424 0.487 0.259 0.248 0.457 0.553 0.578 0.891 0.121 0.339 0.162 0.701 0.12 1.058v1.12h-5.556c-1.939 0-3.271 0.38-3.995 1.14s-1.099 2.127-1.125 4.102c0 2.154 0.359 3.06 1.086 3.742s2.133 1.188 4.344 1.188h6.846c1.717 0 3.346-0.808 3.346-2.747v-8.584c0-2.176-0.589-3.635-1.765-4.375zm-3.181 12.959h-3.219c-0.735 0.081-1.478-0.037-2.153-0.342-0.284-0.227-0.427-0.876-0.427-1.948s0.136-1.741 0.408-2.007c0.624-0.331 1.336-0.46 2.036-0.371h3.384z" fill="#fff"/></svg>';
12249
12250function Promo(plugin) {
12251    this.plan = plugin.status.plan;
12252    var container = plugin.getContainer();
12253    this.element = dom.selectByClass(CLASSES.promo, container);
12254}
12255
12256Promo.prototype.show = function() {
12257    if (this.plan !== FREE_PLAN) {
12258        return;
12259    }
12260    if (!this.element) {
12261        return;
12262    }
12263    this.setStyles();
12264    this.setHtml();
12265};
12266
12267Promo.prototype.setStyles = function() {
12268    this.element.style.display = "block";
12269};
12270
12271Promo.prototype.setHtml = function() {
12272    this.element.innerHTML =
12273        '<a target="_blank" tabindex="-1" href="' +
12274        LINK +
12275        '">' +
12276        PREFIX +
12277        IMAGE +
12278        SUFFIX +
12279        "</a>";
12280};
12281
12282function show() {
12283    new Promo(this).show();
12284}
12285
12286notificator.on("assignSuggestions", show);
12287
12288Suggestions.defaultOptions = DEFAULT_OPTIONS;
12289
12290Suggestions.version = "22.6.0";
12291
12292$.Suggestions = Suggestions;
12293
12294// Create chainable jQuery plugin:
12295$.fn.suggestions = function(options, args) {
12296    // If function invoked without argument return
12297    // instance of the first matched element:
12298    if (arguments.length === 0) {
12299        return this.first().data(DATA_ATTR_KEY);
12300    }
12301
12302    return this.each(function() {
12303        var inputElement = $(this),
12304            instance = inputElement.data(DATA_ATTR_KEY);
12305
12306        if (typeof options === "string") {
12307            if (instance && typeof instance[options] === "function") {
12308                instance[options](args);
12309            }
12310        } else {
12311            // If instance already exists, destroy it:
12312            if (instance && instance.dispose) {
12313                instance.dispose();
12314            }
12315            instance = new Suggestions(this, options);
12316            inputElement.data(DATA_ATTR_KEY, instance);
12317        }
12318    });
12319};
12320
12321})));
12322
12323/* End */
12324;
12325; /* Start:"a:4:{s:4:"full";s:75:"/local/templates/CAIMAN_2025/assets/js_dadata/dadata.code.js?17494746935243";s:6:"source";s:60:"/local/templates/CAIMAN_2025/assets/js_dadata/dadata.code.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
12326(function() {
12327	//dadatascrypt('form');
12328})();
12329
12330function dadatascrypt(p)
12331{
12332	
12333}
12334
12335function dadatascrypt(p)
12336{
12337	//console.log(p['ID']);
12338	
12339    $(function() {
12340	
12341	var token = '7647a60262e4d146cee1ca7bdaf21abd4142f04c';
12342	
12343	// Оформление заказа Физ Лицо
12344	if(p == 'orderpage' || p == 20)
12345	{
12346        var addrtype = "ADDRESS",
12347            $suggestions = $("#soa-property-59"),
12348            //$suggestions = $("#soa-property-304"),
12349			$name = $("#soa-property-298"),
12350            $email = $("#soa-property-299"),
12351            $party = $("#soa-property-237"),
12352            $outward = $("#outward"),
12353            $fixDataButton = $("#fixData"),
12354            $region = $("#region"),
12355            $city = $("#soa-property-302"),
12356            $street = $("#street"),
12357            $house = $("#house");
12358			
12359			//$suggestions.attr('Placeholder', 'начинайте вводить адрес и по окончании ввода обязательно выберите его из списка' );
12360	}
12361	else if(p == 19)// Оформление заказа Юр Лицо
12362	{
12363		var addrtype = "ADDRESS",
12364            $suggestions = $("#soa-property-59"),
12365			$name = $("#name"),
12366            $email = $("#email"),
12367            $party = $("#soa-property-237"),
12368            $outward = $("#outward"),
12369            $fixDataButton = $("#fixData"),
12370            $region = $("#region"),
12371            $city = $("#city"),
12372            $street = $("#street"),
12373            $house = $("#house");
12374			
12375			//$suggestions.attr('Placeholder', 'начинайте вводить адрес и по окончании ввода обязательно выберите его из списка' );
12376
12377	}
12378	else // Прочие формы
12379	{
12380		var addrtype = "ADDRESS",
12381            $suggestions = $("#suggestions"),
12382            $name = $("#name"),
12383            $email = $("#email"),
12384            $party = $("#party"),
12385            $outward = $("#outward"),
12386            $fixDataButton = $("#fixData"),
12387            $region = $("#region"),
12388            $city = $("#city"),
12389            $street = $("#street"),
12390            $house = $("#house");
12391			
12392			$suggestions.attr('Placeholder', 'начинайте вводить адрес и по окончании ввода обязательно выберите его из списка' );
12393
12394	}
12395	
12396	
12397	
12398		$suggestions.addClass("dadata-fix");
12399		
12400
12401        // просто подсказки
12402        var suggestionsInstance = $suggestions.suggestions({
12403            token: token,
12404            type: addrtype,
12405            hint: 'Выберите вариант или продолжите ввод',
12406            addon: "clear",
12407            noSuggestionsHint: false,
12408            onInvalidateSelection: function() {
12409                console.log("ON INVALIDATE SELECTION");
12410            }
12411        });
12412
12413		$suggestions.on("keypress",function() {
12414			
12415		
12416			$suggestions.attr('data-fix', 0 );
12417			
12418			$suggestions.on("blur",function() {
12419				
12420				if($suggestions.attr('data-fix')!='1')
12421				{
12422					$suggestions.val('');
12423					console.log("clear suggest");
12424				}
12425				
12426				//$suggestions.attr('data-fix', 0 );
12427				
12428			});
12429
12430		});
12431		
12432        $fixDataButton.on("click", function() {
12433            $suggestions.suggestions().fixData();
12434        });
12435
12436        $name.suggestions({
12437            token: token,
12438            type: "NAME"
12439        });
12440
12441        $email.suggestions({
12442            token: token,
12443            type: "EMAIL"
12444        });
12445
12446        $outward.suggestions({
12447            token: token,
12448            type: "FNS_UNIT"
12449        });
12450
12451        // регион
12452        $region.suggestions({
12453            token: token,
12454            type: addrtype,
12455            hint: false,
12456            bounds: "region-area"
12457        });
12458
12459        // город и населенный пункт
12460        $city.suggestions({
12461            token: token,
12462            type: addrtype,
12463            hint: false,
12464            bounds: "city-settlement",
12465            constraints: $region
12466        });
12467
12468        // улица
12469        $street.suggestions({
12470            token: token,
12471            type: addrtype,
12472            hint: false,
12473            bounds: "street",
12474            constraints: $city
12475        });
12476
12477        // дом
12478        $house.suggestions({
12479            token: token,
12480            type: addrtype,
12481            hint: false,
12482            bounds: "house",
12483            noSuggestionsHint: false,
12484            constraints: $street
12485        });
12486
12487        $("#url").suggestions({
12488            token: token,
12489            url:
12490                "https://suggestions.dadata.ru/suggestions/api/4_1/rs/suggest/address1",
12491            type: addrtype,
12492            hint: false,
12493            bounds: "city"
12494        });
12495
12496        $("#city-729").suggestions({
12497            token: token,
12498            type: addrtype,
12499            hint: false,
12500            bounds: "city"
12501        });
12502
12503        // sug-798
12504		/*
12505        var $sug798 = $("#sug-798");
12506        $sug798.suggestions({
12507            type: addrtype
12508        });
12509        $sug798.suggestions().setSuggestion({
12510            value: $sug798.val(),
12511            data: {}
12512        });
12513		*/
12514		
12515        $party.suggestions({
12516            token: token,
12517            type: "PARTY",
12518            onSelect: function(suggestion) {
12519                console.log(suggestion);
12520            }
12521        });
12522    });
12523};
12524
12525/* End */
12526;; /* /local/templates/CAIMAN_2025/assets/vendor/parallax/rellax.min.js?17126615677634*/
12527; /* /local/templates/CAIMAN_2025/assets/vendor/parallax/jarallax.min.js?171255500810514*/
12528; /* /local/templates/CAIMAN_2025/assets/vendor/parallax/parallax.min.js?171255502917313*/
12529; /* /local/templates/CAIMAN_2025/assets/vendor/swiper/swiper-bundle.min.js?1753855596143706*/
12530; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/lightgallery.min.js?173495635047108*/
12531; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-fullscreen.min.js?17319318082773*/
12532; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-zoom.min.js?173193187516518*/
12533; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-video.min.js?17349563508341*/
12534; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/lg-thumbnail.min.js?17349563509270*/
12535; /* /local/templates/CAIMAN_2025/assets/vendor/lightgallery/prism-toolbar.min.js?17319319811757*/
12536; /* /local/templates/CAIMAN_2025/assets/jquery.inputmask/jquery.inputmask.js?17437605239265*/
12537; /* /local/templates/CAIMAN_2025/assets/vendor/shuffle/shuffle.min.js?175749375316987*/
12538; /* /local/templates/CAIMAN_2025/assets/vendor/comparison_slider/img-comparison-slider.js?178584953911452*/
12539; /* /local/templates/CAIMAN_2025/assets/custom/js/videoreview.js?1761730821183*/
12540; /* /local/templates/CAIMAN_2025/assets/custom/js/theme.min.js?1743777573127571*/
12541; /* /local/templates/CAIMAN_2025/assets/custom/js/jquery-3.5.1.min.js?174823850689476*/
12542; /* /local/templates/CAIMAN_2025/assets/custom/js/common.js?17876642545854*/
12543; /* /local/templates/CAIMAN_2025/assets/custom/js/cart-func.js?17764381777010*/
12544; /* /local/templates/CAIMAN_2025/assets/custom/js/forms-validator.js?178238890373167*/
12545; /* /local/templates/CAIMAN_2025/assets/custom/js/dropFile.js?17542957422282*/
12546; /* /local/templates/CAIMAN_2025/assets/custom/js/digiLayer.js?17441215512174*/
12547; /* /local/templates/CAIMAN_2025/assets/js_dadata/jquery.dadata.suggestions.js?1749474313162881*/
12548; /* /local/templates/CAIMAN_2025/assets/js_dadata/dadata.code.js?17494746935243*/
12549
12550//# sourceMappingURL=template_05723b393d587e159d80c149bc984b34.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.