PageSourceSearch

https://apzrotor.ru/bitrix/cache/js/s1/rotor/template_ee7e0cdfbefa…259abe83b5a7a88bd364_v1.js?1789376499287651

js apzrotor.ru collected 2026-09-30 19:18:20 UTC 287,651 bytes, 223 lines download raw bytes

1
2; /* Start:"a:4:{s:4:"full";s:50:"/local/templates/rotor/js/main.js?1754488015281676";s:6:"source";s:33:"/local/templates/rotor/js/main.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
3/*! For license information please see main.js.LICENSE.txt */
4!function(){var t={349:function(){document.querySelectorAll(".accordion-item-multiple").forEach((t=>{t.querySelector(".accordion-item-header").addEventListener("click",(function(){const e="true"===t.getAttribute("aria-expanded");t.setAttribute("aria-expanded",e?"false":"true")}))}))},742:function(){const t=document.querySelectorAll(".accordion-item-single");t.forEach((e=>{e.querySelector(".accordion-item-header").addEventListener("click",(function(){const i="true"===e.getAttribute("aria-expanded");t.forEach((t=>t.setAttribute("aria-expanded","false"))),i||e.setAttribute("aria-expanded","true")}))}))},961:function(){document.addEventListener("DOMContentLoaded",(function(){const t=document.getElementById("event-calendar");if(!t)return;const e=jsCalendar.new({target:t,navigator:!0,monthFormat:"month YYYY",language:"ru",dayFormat:"DD",firstDayOfTheWeek:1});let i=null;function n(t){const e=jsCalendar.tools.dateToString(t,"YYYY-MM-DD"),i=document.getElementById("eventDate"),n=document.getElementById("eventTitle"),s=document.getElementById("eventDescription"),r=document.getElementById("eventInfoForm");events&&events[e]?(i.innerHTML=e,n.innerHTML=events[e].title,s.innerHTML=events[e].description,r.value=events[e].title+" ("+e+")"):(i.innerHTML=e,n.textContent="Событий не найдено",s.innerHTML="",r.value="")}e.onDateRender((function(t,e){const n=jsCalendar.tools.dateToString(t,"YYYY-MM-DD");events&&events[n]&&e.classList.add("has-event"),n===i&&e.classList.add("selected-date")})),e.onDateClick((function(t,s){i=jsCalendar.tools.dateToString(s,"YYYY-MM-DD"),e.refresh(),n(s)}));const s=new Date;i=jsCalendar.tools.dateToString(s,"YYYY-MM-DD"),e.set(s),n(s),e.refresh()}))},257:function(){!function(){var t=window.jsCalendar;void 0===t&&(void 0===window.jsCalendar_language2load&&(window.jsCalendar_language2load=[]),t={addLanguage:function(t){window.jsCalendar_language2load.push(t)}}),t.addLanguage({code:"ru",months:["январь","февраль","март","апрель","май","июнь","июль","август","сентябрь","октябрь","ноябрь","декабрь"],days:["Вс","Пн","Вт","Ср","Чт","Пт","Сб"]})}()},812:function(){function t(){!function(t,e,i){let n="";{const t=new Date;t.setTime(t.getTime()+31536e6),n="; expires="+t.toUTCString()}document.cookie="cookieConsent=accepted"+n+"; path=/"}();const t=document.getElementById("cookieConsent");t&&(t.style.display="none")}document.addEventListener("DOMContentLoaded",(function(){if(!function(t){const e="cookieConsent=",i=document.cookie.split(";");for(let t=0;t<i.length;t++){let n=i[t];for(;" "===n.charAt(0);)n=n.substring(1,n.length);if(0===n.indexOf(e))return n.substring(e.length,n.length)}return null}()){const e=document.getElementById("cookieConsent");if(e){e.style.display="flex";const i=document.getElementById("acceptCookiesButton");i&&i.addEventListener("click",t)}}}))},805:function(){document.querySelectorAll(".form").forEach((t=>{const e=t.querySelectorAll(".form-radio-input"),i=t.querySelector(".form-group--company");e.forEach((t=>{t.addEventListener("change",(()=>{t.classList.contains("form-radio-input--company")&&t.checked?i.classList.add("is-active"):i.classList.remove("is-active")}))}))})),document.querySelectorAll(".form-input, .form-textarea").forEach((t=>{t.value.trim()&&t.classList.add("filled"),t.addEventListener("input",(()=>{t.value.trim()?t.classList.add("filled"):t.classList.remove("filled")}))})),document.addEventListener("DOMContentLoaded",(function(){document.querySelectorAll("form").forEach((t=>{const e=t.querySelector('input[name="agreement"]'),i=t.querySelectorAll('button[type="submit"], input[type="submit"]');if(e&&i.length>0){function n(){i.forEach((t=>{t.disabled=!e.checked}))}n(),e.addEventListener("change",n)}}))}))},789:function(){document.addEventListener("DOMContentLoaded",(function(){const t=document.querySelectorAll(".gallery-years__item"),e=document.querySelectorAll(".gallery-item");t.forEach((i=>{i.addEventListener("click",(function(){t.forEach((t=>t.classList.remove("is-active"))),this.classList.add("is-active");const i=this.dataset.year;e.forEach((t=>{t.dataset.year===i?(t.style.display="block",setTimeout((()=>{t.classList.add("is-active")}),100)):(t.classList.remove("is-active"),t.style.display="none")}))}))}));const i=document.querySelector(".gallery-years__item.is-active"),n=i?i.dataset.year:null;e.forEach((t=>{t.dataset.year===n&&(t.style.display="block",setTimeout((()=>{t.classList.add("is-active")}),50))}))})),document.addEventListener("DOMContentLoaded",(function(){const t=document.querySelector(".gallery-years");let e,i,n=!1;t&&(t.addEventListener("mousedown",(s=>{n=!0,t.classList.add("active"),e=s.pageX-t.offsetLeft,i=t.scrollLeft})),t.addEventListener("mouseleave",(()=>{n=!1,t.classList.remove("active")})),t.addEventListener("mouseup",(()=>{n=!1,t.classList.remove("active")})),t.addEventListener("mousemove",(s=>{if(!n)return;s.preventDefault();const r=10*(s.pageX-t.offsetLeft-e);t.scrollLeft=i-r})))}))},840:function(){var t;document.getElementById("contacts-map")&&ymaps.ready((function(){(t=new ymaps.Map("contacts-map",{center:[53.282138,83.674125],zoom:14})).controls.add(new ymaps.control.ZoomControl),myPlacemark=new ymaps.Placemark([53.282138,83.674125],{balloonContent:"<strong>г. Барнаул, 656906 , Лесной тракт, 63</strong>"}
4,{preset:"islands#blueFactoryIcon",iconColor:"#173B6D"}),t.geoObjects.add(myPlacemark)}))},610:function(){document.addEventListener("DOMContentLoaded",(function(){const t=document.getElementById("mobile-menu-toggle"),e=document.getElementById("mobile-menu");t&&e&&t.addEventListener("click",(function(){t.classList.toggle("is-active"),e.classList.toggle("is-active")}))})),document.addEventListener("DOMContentLoaded",(()=>{const t=document.querySelectorAll(".mobile-menu-wrapper__item");let e=null;t.forEach((t=>{if(t.classList.contains("has-submenu")){const i=t.querySelector(".mobile-menu-wrapper__item-text"),n=t.querySelector(".mobile-menu-wrapper__submenu");i.addEventListener("click",(i=>{i.preventDefault(),t!==e&&(e&&(e.classList.remove("is-active"),e.querySelector(".mobile-menu-wrapper__submenu").classList.remove("is-active"),e.querySelector(".mobile-menu-wrapper__submenu").style.maxHeight="0"),t.classList.add("is-active"),n.classList.add("is-active"),n.style.maxHeight=n.scrollHeight+"px",e=t)}))}}))}))},729:function(){document.addEventListener("DOMContentLoaded",(()=>{document.querySelectorAll("[data-target]").forEach((t=>{t.addEventListener("click",(()=>{const e=t.dataset.target,i=document.querySelector(`[data-id='${e}']`);if(!i)return;const n=document.querySelector("[data-target].is-active"),s=document.querySelector("[data-id].is-active");n&&n.classList.remove("is-active"),s&&(s.style.display="none",setTimeout((()=>{s.classList.remove("is-active")}),100)),t.classList.add("is-active"),i.style.display="grid",setTimeout((()=>{i.classList.add("is-active")}),100)}))}))}))},680:function(){window.addEventListener("DOMContentLoaded",(function(){[].forEach.call(document.querySelectorAll('[data-format="phone"]'),(function(t){var e;function i(t){t.keyCode&&(e=t.keyCode),this.selectionStart<3&&t.preventDefault();var i="+7 (___) ___ ____",n=0,s=i.replace(/\D/g,""),r=this.value.replace(/\D/g,""),o=i.replace(/[_\d]/g,(function(t){return n<r.length?r.charAt(n++)||s.charAt(n):t}));-1!=(n=o.indexOf("_"))&&(n<5&&(n=3),o=o.slice(0,n));var a=i.substr(0,this.value.length).replace(/_+/g,(function(t){return"\\d{1,"+t.length+"}"})).replace(/[+()]/g,"\\$&");(!(a=new RegExp("^"+a+"$")).test(this.value)||this.value.length<5||e>47&&e<58)&&(this.value=o),"blur"==t.type&&this.value.length<5&&(this.value="")}t.addEventListener("input",i,!1),t.addEventListener("focus",i,!1),t.addEventListener("blur",i,!1),t.addEventListener("keydown",i,!1)}))}))},850:function(){try{new Swiper(".news-item-slider__swiper",{slidesPerView:2,spaceBetween:4,navigation:{nextEl:".news-item-next",prevEl:".news-item-prev"},breakpoints:{576:{slidesPerView:2,spaceBetween:7},768:{slidesPerView:3,spaceBetween:14}}})}catch(t){}try{new Swiper(".product-related__swiper",{slidesPerView:1,spaceBetween:16,loop:!0,navigation:{nextEl:".product-related-next",prevEl:".product-related-prev"},breakpoints:{576:{slidesPerView:2,spaceBetween:7},768:{slidesPerView:3,spaceBetween:7},992:{slidesPerView:2,spaceBetween:7},1300:{slidesPerView:3,spaceBetween:16}}})}catch(t){}try{new Swiper(".main-news__mobile",{slidesPerView:2,spaceBetween:16,loop:!0,breakpoints:{768:{enabled:!1}}})}catch(t){}}},e={};function i(n){var s=e[n];if(void 0!==s)return s.exports;var r=e[n]={exports:{}};return t[n](r,r.exports,i),r.exports}!function(){"use strict";i(850);const t=(t,e=1e4)=>(t=parseFloat(t+"")||0,Math.round((t+Number.EPSILON)*e)/e),e=function(t){if(!(t&&t instanceof Element&&t.offsetParent))return!1;const e=t.scrollHeight>t.clientHeight,i=window.getComputedStyle(t).overflowY,n=-1!==i.indexOf("hidden"),s=-1!==i.indexOf("visible");return e&&!n&&!s},n=function(t,i){return!(!t||t===document.body||i&&t===i)&&(e(t)?t:n(t.parentElement,i))},s=function(t){var e=(new DOMParser).parseFromString(t,"text/html").body;if(e.childElementCount>1){for(var i=document.createElement("div");e.firstChild;)i.appendChild(e.firstChild);return i}return e.firstChild},r=t=>`${t||""}`.split(" ").filter((t=>!!t)),o=(t,e,i)=>{t&&r(e).forEach((e=>{t.classList.toggle(e,i||!1)}))};class a{constructor(t){Object.defineProperty(this,"pageX",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"pageY",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"clientX",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"clientY",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"id",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"time",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"nativePointer",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.nativePointer=t,this.pageX=t.pageX,this.pageY=t.pageY,this.clientX=t.clientX,this.clientY=t.clientY,this.id=self.Touch&&t instanceof Touch?t.identifier:-1,this.time=Date.now()}}const l={passive:!1};class c{constructor(t,{start:e=(()=>!0),move:i=(()=>{}),end:n=(()=>{})}){Object.defineProperty(this,"element",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"startCallback",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"moveCallback",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"endCallback",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"currentPointers",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"startPointers",{enumerable:!0,configurable:!0,writable:!0,value:[]}),this.element=t,this.startCallback=e,this.moveCallback=i,this.endCallback=n;for(const t of["onPointerStart","onTouchStart","onMove","onTouchEnd","onPointerEnd","onWindowBlur"])this[t]=this[t].bind(this);this.element.addEventListener("mousedown",this.onPointerStart,l),this.element.addEventListener("touchstart",this.onTouchStart,l),this.element.addEventListener("touchmove",this.onMove,l),this.element.addEventListener("touchend",this.onTouchEnd),this.element.addEventListener("touchcancel",this.onTouchEnd)}onPointerStart(t){if(!t.buttons||0!==t.button)return;const e=new a(t);this.currentPointers.some((t=>
vendor: 22,628 bytes, line 4
4t.id===e.id))||this.triggerPointerStart(e,t)&&(window.addEventListener("mousemove",this.onMove),window.addEventListener("mouseup",this.onPointerEnd),window.addEventListener("blur",this.onWindowBlur))}onTouchStart(t){for(const e of Array.from(t.changedTouches||[]))this.triggerPointerStart(new a(e),t);window.addEventListener("blur",this.onWindowBlur)}onMove(t){const e=this.currentPointers.slice(),i="changedTouches"in t?Array.from(t.changedTouches||[]).map((t=>new a(t))):[new a(t)],n=[];for(const t of i){const e=this.currentPointers.findIndex((e=>e.id===t.id));e<0||(n.push(t),this.currentPointers[e]=t)}n.length&&this.moveCallback(t,this.currentPointers.slice(),e)}onPointerEnd(t){t.buttons>0&&0!==t.button||(this.triggerPointerEnd(t,new a(t)),window.removeEventListener("mousemove",this.onMove),window.removeEventListener("mouseup",this.onPointerEnd),window.removeEventListener("blur",this.onWindowBlur))}onTouchEnd(t){for(const e of Array.from(t.changedTouches||[]))this.triggerPointerEnd(t,new a(e))}triggerPointerStart(t,e){return!!this.startCallback(e,t,this.currentPointers.slice())&&(this.currentPointers.push(t),this.startPointers.push(t),!0)}triggerPointerEnd(t,e){const i=this.currentPointers.findIndex((t=>t.id===e.id));i<0||(this.currentPointers.splice(i,1),this.startPointers.splice(i,1),this.endCallback(t,e,this.currentPointers.slice()))}onWindowBlur(){this.clear()}clear(){for(;this.currentPointers.length;){const t=this.currentPointers[this.currentPointers.length-1];this.currentPointers.splice(this.currentPointers.length-1,1),this.startPointers.splice(this.currentPointers.length-1,1),this.endCallback(new Event("touchend",{bubbles:!0,cancelable:!0,clientX:t.clientX,clientY:t.clientY}),t,this.currentPointers.slice())}}stop(){this.element.removeEventListener("mousedown",this.onPointerStart,l),this.element.removeEventListener("touchstart",this.onTouchStart,l),this.element.removeEventListener("touchmove",this.onMove,l),this.element.removeEventListener("touchend",this.onTouchEnd),this.element.removeEventListener("touchcancel",this.onTouchEnd),window.removeEventListener("mousemove",this.onMove),window.removeEventListener("mouseup",this.onPointerEnd),window.removeEventListener("blur",this.onWindowBlur)}}function h(t,e){return e?Math.sqrt(Math.pow(e.clientX-t.clientX,2)+Math.pow(e.clientY-t.clientY,2)):0}function u(t,e){return e?{clientX:(t.clientX+e.clientX)/2,clientY:(t.clientY+e.clientY)/2}:t}const d=t=>"object"==typeof t&&null!==t&&t.constructor===Object&&"[object Object]"===Object.prototype.toString.call(t),f=(t,...e)=>{const i=e.length;for(let n=0;n<i;n++){const i=e[n]||{};Object.entries(i).forEach((([e,i])=>{const n=Array.isArray(i)?[]:{};t[e]||Object.assign(t,{[e]:n}),d(i)?Object.assign(t[e],f(n,i)):Array.isArray(i)?Object.assign(t,{[e]:[...i]}):Object.assign(t,{[e]:i})}))}return t},p=function(t,e){return t.split(".").reduce(((t,e)=>"object"==typeof t?t[e]:void 0),e)};class g{constructor(t={}){Object.defineProperty(this,"options",{enumerable:!0,configurable:!0,writable:!0,value:t}),Object.defineProperty(this,"events",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),this.setOptions(t);for(const t of Object.getOwnPropertyNames(Object.getPrototypeOf(this)))t.startsWith("on")&&"function"==typeof this[t]&&(this[t]=this[t].bind(this))}setOptions(t){this.options=t?f({},this.constructor.defaults,t):{};for(const[t,e]of Object.entries(this.option("on")||{}))this.on(t,e)}option(t,...e){let i=p(t,this.options);return i&&"function"==typeof i&&(i=i.call(this,this,...e)),i}optionFor(t,e,i,...n){let s=p(e,t);var r;"string"!=typeof(r=s)||isNaN(r)||isNaN(parseFloat(r))||(s=parseFloat(s)),"true"===s&&(s=!0),"false"===s&&(s=!1),s&&"function"==typeof s&&(s=s.call(this,this,t,...n));let o=p(e,this.options);return o&&"function"==typeof o?s=o.call(this,this,t,...n,s):void 0===s&&(s=o),void 0===s?i:s}cn(t){const e=this.options.classes;return e&&e[t]||""}localize(t,e=[]){t=String(t).replace(/\{\{(\w+).?(\w+)?\}\}/g,((t,e,i)=>{let n="";return i?n=this.option(`${e[0]+e.toLowerCase().substring(1)}.l10n.${i}`):e&&(n=this.option(`l10n.${e}`)),n||(n=t),n}));for(let i=0;i<e.length;i++)t=t.split(e[i][0]).join(e[i][1]);return t.replace(/\{\{(.*?)\}\}/g,((t,e)=>e))}on(t,e){let i=[];"string"==typeof t?i=t.split(" "):Array.isArray(t)&&(i=t),this.events||(this.events=new Map),i.forEach((t=>{let i=this.events.get(t);i||(this.events.set(t,[]),i=[]),i.includes(e)||i.push(e),this.events.set(t,i)}))}off(t,e){let i=[];"string"==typeof t?i=t.split(" "):Array.isArray(t)&&(i=t),i.forEach((t=>{const i=this.events.get(t);if(Array.isArray(i)){const t=i.indexOf(e);t>-1&&i.splice(t,1)}}))}emit(t,...e){[...this.events.get(t)||[]].forEach((t=>t(this,...e))),"*"!==t&&this.emit("*",t,...e)}}Object.defineProperty(g,"version",{enumerable:!0,configurable:!0,writable:!0,value:"5.0.36"}),Object.defineProperty(g,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{}});class m extends g{constructor(t={}){super(t),Object.defineProperty(this,"plugins",{enumerable:!0,configurable:!0,writable:!0,value:{}})}attachPlugins(t={}){const e=new Map;for(const[i,n]of Object.entries(t)){const t=this.option(i),s=this.plugins[i];s||!1===t?s&&!1===t&&(s.detach(),delete this.plugins[i]):e.set(i,new n(this,t||{}))}for(const[t,i]of e)this.plugins[t]=i,i.attach()}detachPlugins(t){t=t||Object.keys(this.plugins);for(const e of t){const t=this.plugins[e];t&&t.detach(),delete this.plugins[e]}return this.emit("detachPlugins"),this}}var v;!function(t){t[t.Init=0]="Init",t[t.Error=1]="Error",t[t.Ready=2]="Ready",t[t.Panning=3]="Panning",t[t.Mousemove=4]="Mousemove",t[t.Destroy=5]="Destroy"}(v||(v={}));const b=["a","b","c","d","e","f"],y={PANUP:"Move up",PANDOWN:"Move down",PANLEFT:"Move left",PANRIGHT:"Move right",ZOOMIN:"Zoom in",ZOOMOUT:"Zoom out",TOGGLEZOOM:"Toggle zoom level",TOGGLE1TO1:"Toggle zoom level",ITERATEZOOM:"Toggle zoom level",ROTATECCW:"Rotate counterclockwise",ROTATECW:"Rotate clockwise",FLIPX:"Flip horizontally",FLIPY:"Flip vertically",FITX:"Fit horizontally",FITY:"Fit vertically",RESET:"Reset",TOGGLEFS:"Toggle fullscreen"},_={content:null,width:"auto",height:"auto",panMode:"drag",touch:!0,dragMinThreshold:3,lockAxis:!1,mouseMoveFactor:1,mouseMoveFriction:.12,zoom:!0,pinchToZoom:!0,panOnlyZoomed:"auto",minScale:1,maxScale:2,friction:.25,dragFriction:.35,decelFriction:.05,click:"toggleZoom",dblClick:!1,wheel:"zoom",wheelLimit:7,spinner:!0,bounds:"auto",infinite:!1,rubberband:!0,bounce:!0,maxVelocity:75,transformParent:!1,classes:{content:"f-panzoom__content",isLoading:"is-loading",canZoomIn:"can-zoom_in",canZoomOut:"can-zoom_out",isDraggable:"is-draggable",isDragging:"is-dragging",inFullscreen:"in-fullscreen",htmlHasFullscreen:"with-panzoom-in-fullscreen"},l10n:y},w='<circle cx="25" cy="25" r="20"></circle>',x='<div class="f-spinner"><svg viewBox="0 0 50 50">'+w+w+"</svg></div>",S=t=>t&&null!==t&&t instanceof Element&&"nodeType"in t,T=(t,e)=>{t&&r(e).forEach((e=>{t.classList.remove(e)}))},E=(t,e)=>{t&&r(e).forEach((e=>{t.classList.add(e)}))},M={a:1,b:0,c:0,d:1,e:0,f:0},C=1e4,P="mousemove",O="drag",k="content",A="auto";let L=null,R=null;class z extends m{get fits(){return this.contentRect.width-this.contentRect.fitWidth<1&&this.contentRect.height-this.contentRect.fitHeight<1}get isTouchDevice(){return null===R&&(R=window.matchMedia("(hover: none)").matches),R}get isMobile(){return null===L&&(L=/iPhone|iPad|iPod|Android/i.test(navigator.userAgent)),L}get panMode(){return this.options.panMode!==P||this.isTouchDevice?O:P}get panOnlyZoomed(){const t=this.options.panOnlyZoomed;return t===A?this.isTouchDevice:t}get isInfinite(){return this.option("infinite")}get angle(){return 180*Math.atan2(this.current.b,this.current.a)/Math.PI||0}get targetAngle(){return 180*Math.atan2(this.target.b,this.target.a)/Math.PI||0}get scale(){const{a:t,b:e}=this.current;return Math.sqrt(t*t+e*e)||1}get targetScale(){const{a:t,b:e}=this.target;return Math.sqrt(t*t+e*e)||1}get minScale(){return this.option("minScale")||1}get fullScale(){const{contentRect:t}=this;return t.fullWidth/t.fitWidth||1}get maxScale(){return this.fullScale*(this.option("maxScale")||1)||1}get coverScale(){const{containerRect:t,contentRect:e}=this,i=Math.max(t.height/e.fitHeight,t.width/e.fitWidth)||1;return Math.min(this.fullScale,i)}get isScaling(){return Math.abs(this.targetScale-this.scale)>1e-5&&!this.isResting}get isContentLoading(){const t=this.content;return!!(t&&t instanceof HTMLImageElement)&&!t.complete}get isResting(){if(this.isBouncingX||this.isBouncingY)return!1;for(const t of b){const e="e"==t||"f"===t?1e-4:1e-5;if(Math.abs(this.target[t]-this.current[t])>e)return!1}return!(!this.ignoreBounds&&!this.checkBounds().inBounds)}constructor(t,e={},i={}){var n;if(super(e),Object.defineProperty(this,"pointerTracker",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"resizeObserver",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"updateTimer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"clickTimer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"rAF",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"isTicking",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"ignoreBounds",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"isBouncingX",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"isBouncingY",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"clicks",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"trackingPoints",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"pwt",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"cwd",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"pmme",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"friction",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:v.Init}),Object.defineProperty(this,"isDragging",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"content",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"spinner",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"containerRect",{enumerable:!0,configurable:!0,writable:!0,value:{width:0,height:0,innerWidth:0,innerHeight:0}}),Object.defineProperty(this,"contentRect",{enumerable:!0,configurable:!0,writable:!0,value:{top:0,right:0,bottom:0,left:0,fullWidth:0,fullHeight:0,fitWidth:0,fitHeight:0,width:0,height:0}}),Object.defineProperty(this,"dragStart",{enumerable:!0,configurable:!0,writable:!0,value:{x:0,y:0,top:0,left:0,time:0}}),Object.defineProperty(this,"dragOffset",{enumerable:!0,configurable:!0,writable:!0,value:{x:0,y:0,time:0}}),Object.defineProperty(this,"current",{enumerable:!0,configurable:!0,writable:!0,value:Object.assign({},M)}),Object.defineProperty(this,"target",{enumerable:!0,configurable:!0,writable:!0,value:Object.assign({},M)}),Object.defineProperty(this,"velocity",{enumerable:!0,configurable:!0,writable:!0,value:{a:0,b:0,c:0,d:0,e:0,f:0}}),Object.defineProperty(this,"lockedAxis",{enumerable:!0,configurable:!0,writable:!0,value:!1}),!t)throw new Error("Container Element Not Found");this.container=t,this.initContent(),this.attachPlugins(Object.assign(Object.assign({},z.Plugins),i)),this.emit("attachPlugins"),this.emit("init");const r=this.content;if(r.addEventListener("load",this.onLoad),r.addEventListener("error",this.onError),this.isContentLoading){if(this.option("spinner")){t.classList.add(this.cn("isLoading"));const e=s(x);!t.contains(r)||r.parentElement instanceof HTMLPictureElement?this.spinner=t.appendChild(e):this.spinner=(null===(n=r.parentElement)||void 0===n?void 0:n.insertBefore(e,r))||null}this.emit("beforeLoad")}else queueMicrotask((()=>{this.enable()}))}initContent(){const{container:t}=this,e=this.cn(k);let i=this.option(k)||t.querySelector(`.${e}`);if(i||(i=t.querySelector("img,picture")||t.firstElementChild,i&&E(i,e)),i instanceof HTMLPictureElement&&(i=i.querySelector("img")),!i)throw new Error("No content found");this.content=i}onLoad(){const{spinner:t,container:e,state:i}=this;t&&(t.remove(),this.spinner=null),this.option("spinner")&&e.classList.remove(this.cn("isLoading")),this.emit("afterLoad"),i===v.Init?this.enable():this.updateMetrics()}onError(){this.state!==v.Destroy&&(this.spinner&&(this.spinner.remove(),this.spinner=null),this.stop(),this.detachEvents(),this.state=v.Error,this.emit("error"))}getNextScale(t){const{fullScale:e,targetScale:i,coverScale:n,maxScale:s,minScale:r}=this;let o=r;switch(t){case"toggleMax":o=i-r<.5*(s-r)?s:r;break;case"toggleCover":o=i-r<.5*(n-r)?n:r;break;case"toggleZoom":o=i-r<.5*(e-r)?e:r;break;case"iterateZoom":let t=[1,e,s].sort(((t,e)=>t-e)),a=t.findIndex((t=>t>i+1e-5));o=t[a]||1}return o}attachObserver(){var t;const e=()=>{const{container:t,containerRect:e}=this;return Math.abs(e.width-t.getBoundingClientRect().width)>.1||Math.abs(e.height-t.getBoundingClientRect().height)>.1};this.resizeObserver||void 0===window.ResizeObserver||(this.resizeObserver=new ResizeObserver((()=>{this.updateTimer||(e()?(this.onResize(),this.isMobile&&(this.updateTimer=setTimeout((()=>{e()&&this.onResize(),this.updateTimer=null}),500))):this.updateTimer&&(clearTimeout(this.updateTimer),this.updateTimer=null))}))),null===(t=this.resizeObserver)||void 0===t||t.observe(this.container)}detachObserver(){var t;null===(t=this.resizeObserver)||void 0===t||t.disconnect()}attachEvents(){const{container:t}=this;t.addEventListener("click",this.onClick,{passive:!1,capture:!1}),t.addEventListener("wheel",this.onWheel,{passive:!1}),this.pointerTracker=new c(t,{start:this.onPointerDown,move:this.onPointerMove,end:this.onPointerUp}),document.addEventListener(P,this.onMouseMove)}detachEvents(){var t;const{container:e}=this;e.removeEventListener("click",this.onClick,{passive:!1,capture:!1}),e.removeEventListener("wheel",this.onWheel,{passive:!1}),null===(t=this.pointerTracker)||void 0===t||t.stop(),this.pointerTracker=null,document.removeEventListener(P,this.onMouseMove),document.removeEventListener("keydown",this.onKeydown,!0),this.clickTimer&&(clearTimeout(this.clickTimer),this.clickTimer=null),this.updateTimer&&(clearTimeout(this.updateTimer),this.updateTimer=null)}animate(){this.setTargetForce();const t=this.friction,e=this.option("maxVelocity");for(const i of b)t?(this.velocity[i]*=1-t,e&&!this.isScaling&&(this.velocity[i]=Math.max(Math.min(this.velocity[i],e),-1*e)),this.current[i]+=this.velocity[i]):this.current[i]=this.target[i];this.setTransform(),this.setEdgeForce(),!this.isResting||this.isDragging?this.rAF=requestAnimationFrame((()=>this.animate())):this.stop("current")}setTargetForce(){for(const t of b)"e"===t&&this.isBouncingX||"f"===t&&this.isBouncingY||(this.velocity[t]=(1/(1-this.friction)-1)*(this.target[t]-this.current[t]))}checkBounds(t=0,e=0){const{current:i}=this,n=i.e+t,s=i.f+e,r=this.getBounds(),{x:o,y:a}=r,l=o.min,c=o.max,h=a.min,u=a.max;let d=0,f=0;return l!==1/0&&n<l?d=l-n:c!==1/0&&n>c&&(d=c-n),h!==1/0&&s<h?f=h-s:u!==1/0&&s>u&&(f=u-s),Math.abs(d)<1e-4&&(d=0),Math.abs(f)<1e-4&&(f=0),Object.assign(Object.assign({},r),{xDiff:d,yDiff:f,inBounds:!d&&!f})}clampTargetBounds(){const{target:t}=this,{x:e,y:i}=this.getBounds();e.min!==1/0&&(t.e=Math.max(t.e,e.min)),e.max!==1/0&&(t.e=Math.min(t.e,e.max)),i.min!==1/0&&(t.f=Math.max(t.f,i.min)),i.max!==1/0&&(t.f=Math.min(t.f,i.max))}calculateContentDim(t=this.current){const{content:e,contentRect:i}=this,{fitWidth:n,fitHeight:s,fullWidth:r,fullHeight:o}=i;let a=r,l=o;if(this.option("zoom")||0!==this.angle){const i=!(e instanceof HTMLImageElement||"none"!==window.getComputedStyle(e).maxWidth&&"none"!==window.getComputedStyle(e).maxHeight),c=i?r:n,h=i?o:s,u=this.getMatrix(t),d=new DOMPoint(0,0).matrixTransform(u),f=new DOMPoint(0+c,0).matrixTransform(u),p=new DOMPoint(0+c,0+h).matrixTransform(u),g=new DOMPoint(0,0+h).matrixTransform(u),m=Math.abs(p.x-d.x),v=Math.abs(p.y-d.y),b=Math.abs(g.x-f.x),y=Math.abs(g.y-f.y);a=Math.max(m,b),l=Math.max(v,y)}return{contentWidth:a,contentHeight:l}}setEdgeForce(){if(this.ignoreBounds||this.isDragging||this.panMode===P||this.targetScale<this.scale)return this.isBouncingX=!1,void(this.isBouncingY=!1);const{target:t}=this,{x:e,y:i,xDiff:n,yDiff:s}=this.checkBounds(),r=this.option("maxVelocity");let o=this.velocity.e,a=this.velocity.f;0!==n?(this.isBouncingX=!0,n*o<=0?o+=.14*n:(o=.14*n,e.min!==1/0&&(this.target.e=Math.max(t.e,e.min)),e.max!==1/0&&(this.target.e=Math.min(t.e,e.max))),r&&(o=Math.max(Math.min(o,r),-1*r))):this.isBouncingX=!1,0!==s?(this.isBouncingY=!0,s*a<=0?a+=.14*s:(a=.14*s,i.min!==1/0&&(this.target.f=Math.max(t.f,i.min)),i.max!==1/0&&(this.target.f=Math.min(t.f,i.max))),r&&(a=Math.max(Math.min(a,r),-1*r))):this.isBouncingY=!1,this.isBouncingX&&(this.velocity.e=o),this.isBouncingY&&(this.velocity.f=a)}enable(){const{content:t}=this,e=new DOMMatrixReadOnly(window.getComputedStyle(t).transform);for(const t of b)this.current[t]=this.target[t]=e[t];this.updateMetrics(),this.attachObserver(),this.attachEvents(),this.state=v.Ready,this.emit("ready")}onClick(t){var e;"click"===t.type&&0===t.detail&&(this.dragOffset.x=0,this.dragOffset.y=0),this.isDragging&&(null===(e=this.pointerTracker)||void 0===e||e.clear(),this.trackingPoints=[],this.startDecelAnim());const i=t.target;if(!i||t.defaultPrevented)return;if(i.hasAttribute("disabled"))return t.preventDefault(),void t.stopPropagation();if((()=>{const t=window.getSelection();return t&&"Range"===t.type})()&&!i.closest("button"))return;const n=i.closest("[data-panzoom-action]"),s=i.closest("[data-panzoom-change]"),r=n||s,o=r&&S(r)?r.dataset:null;if(o){const e=o.panzoomChange,i=o.panzoomAction;if((e||i)&&t.preventDefault(),e){let i={};try{i=JSON.parse(e)}catch(t){console&&console.warn("The given data was not valid JSON")}return void this.applyChange(i)}if(i)return void(this[i]&&this[i]())}if(Math.abs(this.dragOffset.x)>3||Math.abs(this.dragOffset.y)>3)return t.preventDefault(),void t.stopPropagation();if(i.closest("[data-fancybox]"))return;const a=this.content.getBoundingClientRect(),l=this.dragStart;if(l.time&&!this.canZoomOut()&&(Math.abs(a.x-l.x)>2||Math.abs(a.y-l.y)>2))return;this.dragStart.time=0;const c=e=>{this.option("zoom",t)&&e&&"string"==typeof e&&/(iterateZoom)|(toggle(Zoom|Full|Cover|Max)|(zoomTo(Fit|Cover|Max)))/.test(e)&&"function"==typeof this[e]&&(t.preventDefault(),this[e]({event:t}))},h=this.option("click",t),u=this.option("dblClick",t);u?(this.clicks++,1==this.clicks&&(this.clickTimer=setTimeout((()=>{1===this.clicks?(this.emit("click",t),!t.defaultPrevented&&h&&c(h)):(this.emit("dblClick",t),t.defaultPrevented||c(u)),this.clicks=0,this.clickTimer=null}),350))):(this.emit("click",t),!t.defaultPrevented&&h&&c(h))}addTrackingPoint(t){const e=this.trackingPoints.filter((t=>t.time>Date.now()-100));e.push(t),this.trackingPoints=e}onPointerDown(t,e,i){var n;if(!1===this.option("touch",t))return!1;this.pwt=0,this.dragOffset={x:0,y:0,time:0},this.trackingPoints=[];const s=this.content.getBoundingClientRect();if(this.dragStart={x:s.x,y:s.y,top:s.top,left:s.left,time:Date.now()},this.clickTimer)return!1;if(this.panMode===P&&this.targetScale>1)return t.preventDefault(),t.stopPropagation(),!1;const r=t.composedPath()[0];if(!i.length){if(["TEXTAREA","OPTION","INPUT","SELECT","VIDEO","IFRAME"].includes(r.nodeName)||r.closest("[contenteditable],[data-selectable],[data-draggable],[data-clickable],[data-panzoom-change],[data-panzoom-action]"))return!1;null===(n=window.getSelection())||void 0===n||n.removeAllRanges()}if("mousedown"===t.type)["A","BUTTON"].includes(r.nodeName)||t.preventDefault();else if(Math.abs(this.velocity.a)>.3)return!1;return this.target.e=this.current.e,this.target.f=this.current.f,this.stop(),this.isDragging||(this.isDragging=!0,this.addTrackingPoint(e),this.emit("touchStart",t)),!0}onPointerMove(e,i,s){if(!1===this.option("touch",e))return;if(!this.isDragging)return;if(i.length<2&&this.panOnlyZoomed&&t(this.targetScale)<=t(this.minScale))return;if(this.emit("touchMove",e),e.defaultPrevented)return;this.addTrackingPoint(i[0]);const{content:r}=this,o=u(s[0],s[1]),a=u(i[0],i[1]);let l=0,c=0;if(i.length>1){const t=r.getBoundingClientRect();l=o.clientX-t.left-.5*t.width,c=o.clientY-t.top-.5*t.height}const d=h(s[0],s[1]),f=h(i[0],i[1]);let p=d?f/d:1,g=a.clientX-o.clientX,m=a.clientY-o.clientY;this.dragOffset.x+=g,this.dragOffset.y+=m,this.dragOffset.time=Date.now()-this.dragStart.time;let v=t(this.targetScale)===t(this.minScale)&&this.option("lockAxis");if(v&&!this.lockedAxis)if("xy"===v||"y"===v||"touchmove"===e.type){if(Math.abs(this.dragOffset.x)<6&&Math.abs(this.dragOffset.y)<6)return void e.preventDefault();const t=Math.abs(180*Math.atan2(this.dragOffset.y,this.dragOffset.x)/Math.PI);this.lockedAxis=t>45&&t<135?"y":"x",this.dragOffset.x=0,this.dragOffset.y=0,g=0,m=0}else this.lockedAxis=v;if(n(e.target,this.content)&&(v="x",this.dragOffset.y=0),v&&"xy"!==v&&this.lockedAxis!==v&&t(this.targetScale)===t(this.minScale))return;e.cancelable&&e.preventDefault(),this.container.classList.add(this.cn("isDragging"));const b=this.checkBounds(g,m);this.option("rubberband")?("x"!==this.isInfinite&&(b.xDiff>0&&g<0||b.xDiff<0&&g>0)&&(g*=Math.max(0,.5-Math.abs(.75/this.contentRect.fitWidth*b.xDiff))),"y"!==this.isInfinite&&(b.yDiff>0&&m<0||b.yDiff<0&&m>0)&&(m*=Math.max(0,.5-Math.abs(.75/this.contentRect.fitHeight*b.yDiff)))):(b.xDiff&&(g=0),b.yDiff&&(m=0));const y=this.targetScale,_=this.minScale,w=this.maxScale;y<.5*_&&(p=Math.max(p,_)),y>1.5*w&&(p=Math.min(p,w)),"y"===this.lockedAxis&&t(y)===t(_)&&(g=0),"x"===this.lockedAxis&&t(y)===t(_)&&(m=0),this.applyChange({originX:l,originY:c,panX:g,panY:m,scale:p,friction:this.option("dragFriction"),ignoreBounds:!0})}onPointerUp(t,e,i){if(i.length)return this.dragOffset.x=0,this.dragOffset.y=0,void(this.trackingPoints=[]);this.container.classList.remove(this.cn("isDragging")),this.isDragging&&(this.addTrackingPoint(e),this.panOnlyZoomed&&this.contentRect.width-this.contentRect.fitWidth<1&&this.contentRect.height-this.contentRect.fitHeight<1&&(this.trackingPoints=[]),n(t.target,this.content)&&"y"===this.lockedAxis&&(this.trackingPoints=[]),this.emit
vendor: 12,913 bytes, line 4
4("touchEnd",t),this.isDragging=!1,this.lockedAxis=!1,this.state!==v.Destroy&&(t.defaultPrevented||this.startDecelAnim()))}startDecelAnim(){var e;const i=this.isScaling;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.isBouncingX=!1,this.isBouncingY=!1;for(const t of b)this.velocity[t]=0;this.target.e=this.current.e,this.target.f=this.current.f,T(this.container,"is-scaling"),T(this.container,"is-animating"),this.isTicking=!1;const{trackingPoints:n}=this,s=n[0],r=n[n.length-1];let o=0,a=0,l=0;r&&s&&(o=r.clientX-s.clientX,a=r.clientY-s.clientY,l=r.time-s.time);const c=(null===(e=window.visualViewport)||void 0===e?void 0:e.scale)||1;1!==c&&(o*=c,a*=c);let h=0,u=0,d=0,f=0,p=this.option("decelFriction");const g=this.targetScale;if(l>0){d=Math.abs(o)>3?o/(l/30):0,f=Math.abs(a)>3?a/(l/30):0;const t=this.option("maxVelocity");t&&(d=Math.max(Math.min(d,t),-1*t),f=Math.max(Math.min(f,t),-1*t))}d&&(h=d/(1/(1-p)-1)),f&&(u=f/(1/(1-p)-1)),("y"===this.option("lockAxis")||"xy"===this.option("lockAxis")&&"y"===this.lockedAxis&&t(g)===this.minScale)&&(h=d=0),("x"===this.option("lockAxis")||"xy"===this.option("lockAxis")&&"x"===this.lockedAxis&&t(g)===this.minScale)&&(u=f=0);const m=this.dragOffset.x,v=this.dragOffset.y,y=this.option("dragMinThreshold")||0;Math.abs(m)<y&&Math.abs(v)<y&&(h=u=0,d=f=0),(this.option("zoom")&&(g<this.minScale-1e-5||g>this.maxScale+1e-5)||i&&!h&&!u)&&(p=.35),this.applyChange({panX:h,panY:u,friction:p}),this.emit("decel",d,f,m,v)}onWheel(t){var e=[-t.deltaX||0,-t.deltaY||0,-t.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t}));const i=Math.max(-1,Math.min(1,e));if(this.emit("wheel",t,i),this.panMode===P)return;if(t.defaultPrevented)return;const n=this.option("wheel");"pan"===n?(t.preventDefault(),this.panOnlyZoomed&&!this.canZoomOut()||this.applyChange({panX:2*-t.deltaX,panY:2*-t.deltaY,bounce:!1})):"zoom"===n&&!1!==this.option("zoom")&&this.zoomWithWheel(t)}onMouseMove(t){this.panWithMouse(t)}onKeydown(t){"Escape"===t.key&&this.toggleFS()}onResize(){this.updateMetrics(),this.checkBounds().inBounds||this.requestTick()}setTransform(){this.emit("beforeTransform");const{current:e,target:i,content:n,contentRect:s}=this,r=Object.assign({},M);for(const n of b){const s="e"==n||"f"===n?C:1e5;r[n]=t(e[n],s),Math.abs(i[n]-e[n])<("e"==n||"f"===n?.51:.001)&&(e[n]=i[n])}let{a:o,b:a,c:l,d:c,e:h,f:u}=r,d=`matrix(${o}, ${a}, ${l}, ${c}, ${h}, ${u})`,f=n.parentElement instanceof HTMLPictureElement?n.parentElement:n;if(this.option("transformParent")&&(f=f.parentElement||f),f.style.transform===d)return;f.style.transform=d;const{contentWidth:p,contentHeight:g}=this.calculateContentDim();s.width=p,s.height=g,this.emit("afterTransform")}updateMetrics(e=!1){var i;if(!this||this.state===v.Destroy)return;if(this.isContentLoading)return;const n=Math.max(1,(null===(i=window.visualViewport)||void 0===i?void 0:i.scale)||1),{container:s,content:r}=this,o=r instanceof HTMLImageElement,a=s.getBoundingClientRect(),l=getComputedStyle(this.container);let c=a.width*n,h=a.height*n;const u=parseFloat(l.paddingTop)+parseFloat(l.paddingBottom),d=c-(parseFloat(l.paddingLeft)+parseFloat(l.paddingRight)),f=h-u;this.containerRect={width:c,height:h,innerWidth:d,innerHeight:f};const p=parseFloat(r.dataset.width||"")||(t=>{let e=0;return e=t instanceof HTMLImageElement?t.naturalWidth:t instanceof SVGElement?t.width.baseVal.value:Math.max(t.offsetWidth,t.scrollWidth),e||0})(r),g=parseFloat(r.dataset.height||"")||(t=>{let e=0;return e=t instanceof HTMLImageElement?t.naturalHeight:t instanceof SVGElement?t.height.baseVal.value:Math.max(t.offsetHeight,t.scrollHeight),e||0})(r);let m=this.option("width",p)||A,b=this.option("height",g)||A;const y=m===A,_=b===A;"number"!=typeof m&&(m=p),"number"!=typeof b&&(b=g),y&&(m=p*(b/g)),_&&(b=g/(p/m));let w=r.parentElement instanceof HTMLPictureElement?r.parentElement:r;this.option("transformParent")&&(w=w.parentElement||w);const x=w.getAttribute("style")||"";w.style.setProperty("transform","none","important"),o&&(w.style.width="",w.style.height=""),w.offsetHeight;const S=r.getBoundingClientRect();let T=S.width*n,E=S.height*n,M=T,C=E;T=Math.min(T,m),E=Math.min(E,b),o?({width:T,height:E}=((t,e,i,n)=>{const s=i/t,r=n/e,o=Math.min(s,r);return{width:t*=o,height:e*=o}})(m,b,T,E)):(T=Math.min(T,m),E=Math.min(E,b));let P=.5*(C-E),O=.5*(M-T);this.contentRect=Object.assign(Object.assign({},this.contentRect),{top:S.top-a.top+P,bottom:a.bottom-S.bottom+P,left:S.left-a.left+O,right:a.right-S.right+O,fitWidth:T,fitHeight:E,width:T,height:E,fullWidth:m,fullHeight:b}),w.style.cssText=x,o&&(w.style.width=`${T}px`,w.style.height=`${E}px`),this.setTransform(),!0!==e&&this.emit("refresh"),this.ignoreBounds||(t(this.targetScale)<t(this.minScale)?this.zoomTo(this.minScale,{friction:0}):this.targetScale>this.maxScale?this.zoomTo(this.maxScale,{friction:0}):this.state===v.Init||this.checkBounds().inBounds||this.requestTick()),this.updateControls()}calculateBounds(){const{contentWidth:e,contentHeight:i}=this.calculateContentDim(this.target),{targetScale:n,lockedAxis:s}=this,{fitWidth:r,fitHeight:o}=this.contentRect;let a=0,l=0,c=0,h=0;const u=this.option("infinite");if(!0===u||s&&u===s)a=-1/0,c=1/0,l=-1/0,h=1/0;else{let{containerRect:s,contentRect:u}=this,d=t(r*n,C),f=t(o*n,C),{innerWidth:p,innerHeight:g}=s;if(s.width===d&&(p=s.width),s.width===f&&(g=s.height),e>p){c=.5*(e-p),a=-1*c;let t=.5*(u.right-u.left);a+=t,c+=t}if(r>p&&e<p&&(a-=.5*(r-p),c-=.5*(r-p)),i>g){h=.5*(i-g),l=-1*h;let t=.5*(u.bottom-u.top);l+=t,h+=t}o>g&&i<g&&(a-=.5*(o-g),c-=.5*(o-g))}return{x:{min:a,max:c},y:{min:l,max:h}}}getBounds(){const t=this.option("bounds");return t!==A?t:this.calculateBounds()}updateControls(){const e=this,i=e.container,{panMode:n,contentRect:s,targetScale:r,minScale:a}=e;let l=a,c=e.option("click")||!1;c&&(l=e.getNextScale(c));let h=e.canZoomIn(),u=e.canZoomOut(),d=n===O&&!!this.option("touch"),f=u&&d;if(d&&(t(r)<t(a)&&!this.panOnlyZoomed&&(f=!0),(t(s.width,1)>t(s.fitWidth,1)||t(s.height,1)>t(s.fitHeight,1))&&(f=!0)),t(s.width*r,1)<t(s.fitWidth,1)&&(f=!1),n===P&&(f=!1),o(i,this.cn("isDraggable"),f),!this.option("zoom"))return;let p=h&&t(l)>t(r),g=!p&&!f&&u&&t(l)<t(r);o(i,this.cn("canZoomIn"),p),o(i,this.cn("canZoomOut"),g);for(const t of i.querySelectorAll("[data-panzoom-action]")){let e=!1,i=!1;switch(t.dataset.panzoomAction){case"zoomIn":h?e=!0:i=!0;break;case"zoomOut":u?e=!0:i=!0;break;case"toggleZoom":case"iterateZoom":h||u?e=!0:i=!0;const n=t.querySelector("g");n&&(n.style.display=h?"":"none")}e?(t.removeAttribute("disabled"),t.removeAttribute("tabindex")):i&&(t.setAttribute("disabled",""),t.setAttribute("tabindex","-1"))}}panTo({x:t=this.target.e,y:e=this.target.f,scale:i=this.targetScale,friction:n=this.option("friction"),angle:s=0,originX:r=0,originY:o=0,flipX:a=!1,flipY:l=!1,ignoreBounds:c=!1}){this.state!==v.Destroy&&this.applyChange({panX:t-this.target.e,panY:e-this.target.f,scale:i/this.targetScale,angle:s,originX:r,originY:o,friction:n,flipX:a,flipY:l,ignoreBounds:c})}applyChange({panX:e=0,panY:i=0,scale:n=1,angle:s=0,originX:r=-this.current.e,originY:o=-this.current.f,friction:a=this.option("friction"),flipX:l=!1,flipY:c=!1,ignoreBounds:h=!1,bounce:u=this.option("bounce")}){const d=this.state;if(d===v.Destroy)return;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.friction=a||0,this.ignoreBounds=h;const{current:f}=this,p=f.e,g=f.f,m=this.getMatrix(this.target);let y=(new DOMMatrix).translate(p,g).translate(r,o).translate(e,i);if(this.option("zoom")){if(!h){const t=this.targetScale,e=this.minScale,i=this.maxScale;t*n<e&&(n=e/t),t*n>i&&(n=i/t)}y=y.scale(n)}y=y.translate(-r,-o).translate(-p,-g).multiply(m),s&&(y=y.rotate(s)),l&&(y=y.scale(-1,1)),c&&(y=y.scale(1,-1));for(const e of b)"e"!==e&&"f"!==e&&(y[e]>this.minScale+1e-5||y[e]<this.minScale-1e-5)?this.target[e]=y[e]:this.target[e]=t(y[e],C);(this.targetScale<this.scale||Math.abs(n-1)>.1||this.panMode===P||!1===u)&&!h&&this.clampTargetBounds(),d===v.Init?this.animate():this.isResting||(this.state=v.Panning,this.requestTick())}stop(t=!1){if(this.state===v.Init||this.state===v.Destroy)return;const e=this.isTicking;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.isBouncingX=!1,this.isBouncingY=!1;for(const e of b)this.velocity[e]=0,"current"===t?this.current[e]=this.target[e]:"target"===t&&(this.target[e]=this.current[e]);this.setTransform(),T(this.container,"is-scaling"),T(this.container,"is-animating"),this.isTicking=!1,this.state=v.Ready,e&&(this.emit("endAnimation"),this.updateControls())}requestTick(){this.isTicking||(this.emit("startAnimation"),this.updateControls(),E(this.container,"is-animating"),this.isScaling&&E(this.container,"is-scaling")),this.isTicking=!0,this.rAF||(this.rAF=requestAnimationFrame((()=>this.animate())))}panWithMouse(e,i=this.option("mouseMoveFriction")){if(this.pmme=e,this.panMode!==P||!e)return;if(t(this.targetScale)<=t(this.minScale))return;this.emit("mouseMove",e);const{container:n,containerRect:s,contentRect:r}=this,o=s.width,a=s.height,l=n.getBoundingClientRect(),c=(e.clientX||0)-l.left,h=(e.clientY||0)-l.top;let{contentWidth:u,contentHeight:d}=this.calculateContentDim(this.target);const f=this.option("mouseMoveFactor");f>1&&(u!==o&&(u*=f),d!==a&&(d*=f));let p=.5*(u-o)-c/o*100/100*(u-o);p+=.5*(r.right-r.left);let g=.5*(d-a)-h/a*100/100*(d-a);g+=.5*(r.bottom-r.top),this.applyChange({panX:p-this.target.e,panY:g-this.target.f,friction:i})}zoomWithWheel(e){if(this.state===v.Destroy||this.state===v.Init)return;const i=Date.now();if(i-this.pwt<45)return void e.preventDefault();this.pwt=i;var n=[-e.deltaX||0,-e.deltaY||0,-e.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t}));const s=Math.max(-1,Math.min(1,n)),{targetScale:r,maxScale:o,minScale:a}=this;let l=r*(100+45*s)/100;t(l)<t(a)&&t(r)<=t(a)?(this.cwd+=Math.abs(s),l=a):t(l)>t(o)&&t(r)>=t(o)?(this.cwd+=Math.abs(s),l=o):(this.cwd=0,l=Math.max(Math.min(l,o),a)),this.cwd>this.option("wheelLimit")||(e.preventDefault(),t(l)!==t(r)&&this.zoomTo(l,{event:e}))}canZoomIn(){return this.option("zoom")&&(t(this.contentRect.width,1)<t(this.contentRect.fitWidth,1)||t(this.targetScale)<t(this.maxScale))}canZoomOut(){return this.option("zoom")&&t(this.targetScale)>t(this.minScale)}zoomIn(t=1.25,e){this.zoomTo(this.targetScale*t,e)}zoomOut(t=.8,e){this.zoomTo(this.targetScale*t,e)}zoomToFit(t){this.zoomTo("fit",t)}zoomToCover(t){this.zoomTo("cover",t)}zoomToFull(t){this.zoomTo("full",t)}zoomToMax(t){this.zoomTo("max",t)}toggleZoom(t){this.zoomTo(this.getNextScale("toggleZoom"),t)}toggleMax(t){this.zoomTo(this.getNextScale("toggleMax"),t)}toggleCover(t){this.zoomTo(this.getNextScale("toggleCover"),t)}iterateZoom(t){this.zoomTo("next",t)}zoomTo(t=1,{friction:e=A,originX:i=A,originY:n=A,event:s}={}){if(this.isContentLoading||this.state===v.Destroy)return;const{targetScale:r,fullScale:o,maxScale:a,coverScale:l}=this;if(this.stop(),this.panMode===P&&(s=this.pmme||s),s||i===A||n===A){const t=this.content.getBoundingClientRect(),e=this.container.getBoundingClientRect(),r=s?s.clientX:e.left+.5*e.width,o=s?s.clientY:e.top+.5*e.height;i=r-t.left-.5*t.width,n=o-t.top-.5*t.height}let c=1;"number"==typeof t?c=t:"full"===t?c=o:"cover"===t?c=l:"max"===t?c=a:"fit"===t?c=1:"next"===t&&(c=this.getNextScale("iterateZoom")),c=c/r||1,e=e===A?c>1?.15:.25:e,this.applyChange({scale:c,originX:i,originY:n,friction:e}),s&&this.panMode===P&&this.panWithMouse(s,e)}rotateCCW(){this.applyChange({angle:-90})}rotateCW(){this.applyChange({angle:90})}flipX(){this.applyChange({flipX:!0})}flipY(){this.applyChange({flipY:!0})}fitX(){this.stop("target");const{containerRect:t,contentRect:e,target:i}=this;this.applyChange({panX:.5*t.width-(e.left+.5*e.fitWidth)-i.e,panY:.5*t.height-(e.top+.5*e.fitHeight)-i.f,scale:t.width/e.fitWidth/this.targetScale,originX:0,originY:0,ignoreBounds:!0})}fitY(){this.stop("target");const{containerRect:t,contentRect:e,target:i}=this;this.applyChange({panX:.5*t.width-(e.left+.5*e.fitWidth)-i.e,panY:.5*t.innerHeight-(e.top+.5*e.fitHeight)-i.f,scale:t.height/e.fitHeight/this.targetScale,originX:0,originY:0,ignoreBounds:!0})}toggleFS(){const{container:t}=this,e=this.cn("inFullscreen"),i=this.cn("htmlHasFullscreen");t.classList.toggle(e);const n=t.classList.contains(e);n?(document.documentElement.classList.add(i),document.addEventListener("keydown",this.onKeydown,!0)):(document.documentElement.classList.remove(i),document.removeEventListener("keydown",this.onKeydown,!0)),this.updateMetrics(),this.emit(n?"enterFS":"exitFS")}getMatrix(t=this.current){const{a:e,b:i,c:n,d:s,e:r,f:o}=t;return new DOMMatrix([e,i,n,s,r,o])}reset(t){if(this.state!==v.Init&&this.state!==v.Destroy){this.stop("current");for(const t of b)this.target[t]=M[t];this.target.a=this.minScale,this.target.d=this.minScale,this.clampTargetBounds(),this.isResting||(this.friction=void 0===t?this.option("friction"):t,this.state=v.Panning,this.requestTick())}}
vendor: 6,023 bytes, line 4
4destroy(){this.stop(),this.state=v.Destroy,this.detachEvents(),this.detachObserver();const{container:t,content:e}=this,i=this.option("classes")||{};for(const e of Object.values(i))t.classList.remove(e+"");e&&(e.removeEventListener("load",this.onLoad),e.removeEventListener("error",this.onError)),this.detachPlugins()}}Object.defineProperty(z,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:_}),Object.defineProperty(z,"Plugins",{enumerable:!0,configurable:!0,writable:!0,value:{}});const D=function(t,e){let i=!0;return(...n)=>{i&&(i=!1,t(...n),setTimeout((()=>{i=!0}),e))}},I=(t,e)=>{let i=[];return t.childNodes.forEach((t=>{t.nodeType!==Node.ELEMENT_NODE||e&&!t.matches(e)||i.push(t)})),i};var F;!function(t){t[t.Init=0]="Init",t[t.Ready=1]="Ready",t[t.Destroy=2]="Destroy"}(F||(F={}));const B=t=>{if("string"==typeof t||t instanceof HTMLElement)t={html:t};else{const e=t.thumb;void 0!==e&&("string"==typeof e&&(t.thumbSrc=e),e instanceof HTMLImageElement&&(t.thumbEl=e,t.thumbElSrc=e.src,t.thumbSrc=e.src),delete t.thumb)}return Object.assign({html:"",el:null,isDom:!1,class:"",customClass:"",index:-1,dim:0,gap:0,pos:0,transition:!1},t)},N=(t={})=>Object.assign({index:-1,slides:[],dim:0,pos:-1},t);class j extends g{constructor(t,e){super(e),Object.defineProperty(this,"instance",{enumerable:!0,configurable:!0,writable:!0,value:t})}attach(){}detach(){}}class H extends j{constructor(){super(...arguments),Object.defineProperty(this,"isDynamic",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"list",{enumerable:!0,configurable:!0,writable:!0,value:null})}onRefresh(){this.refresh()}build(){let t=this.list;if(!t){t=document.createElement("ul"),E(t,this.cn("list")),t.setAttribute("role","tablist");const e=this.instance.container;e.appendChild(t),E(e,this.cn("hasDots")),this.list=t}return t}refresh(){var t;const e=this.instance.pages.length,i=Math.min(2,this.option("minCount")),n=Math.max(2e3,this.option("maxCount")),s=this.option("dynamicFrom");if(e<i||e>n)return void this.cleanup();const r="number"==typeof s&&e>5&&e>=s,a=!this.list||this.isDynamic!==r||this.list.children.length!==e;a&&this.cleanup();const l=this.build();if(o(l,this.cn("isDynamic"),!!r),a)for(let t=0;t<e;t++)l.append(this.createItem(t));let c,h=0;for(const e of[...l.children]){const i=h===this.instance.page;i&&(c=e),o(e,this.cn("isCurrent"),i),null===(t=e.children[0])||void 0===t||t.setAttribute("aria-selected",i?"true":"false");for(const t of["isBeforePrev","isPrev","isNext","isAfterNext"])T(e,this.cn(t));h++}if(c=c||l.firstChild,r&&c){const t=c.previousElementSibling,e=t&&t.previousElementSibling;E(t,this.cn("isPrev")),E(e,this.cn("isBeforePrev"));const i=c.nextElementSibling,n=i&&i.nextElementSibling;E(i,this.cn("isNext")),E(n,this.cn("isAfterNext"))}this.isDynamic=r}createItem(t=0){var e;const i=document.createElement("li");i.setAttribute("role","presentation");const n=s(this.instance.localize(this.option("dotTpl"),[["%d",t+1]]).replace(/\%i/g,t+""));return i.appendChild(n),null===(e=i.children[0])||void 0===e||e.setAttribute("role","tab"),i}cleanup(){this.list&&(this.list.remove(),this.list=null),this.isDynamic=!1,T(this.instance.container,this.cn("hasDots"))}attach(){this.instance.on(["refresh","change"],this.onRefresh)}detach(){this.instance.off(["refresh","change"],this.onRefresh),this.cleanup()}}Object.defineProperty(H,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{classes:{list:"f-carousel__dots",isDynamic:"is-dynamic",hasDots:"has-dots",dot:"f-carousel__dot",isBeforePrev:"is-before-prev",isPrev:"is-prev",isCurrent:"is-current",isNext:"is-next",isAfterNext:"is-after-next"},dotTpl:'<button type="button" data-carousel-page="%i" aria-label="{{GOTO}}"><span class="f-carousel__dot" aria-hidden="true"></span></button>',dynamicFrom:11,maxCount:1/0,minCount:2}});const Y="disabled",q="next",X="prev";class W extends j{constructor(){super(...arguments),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"prev",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"next",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"isDom",{enumerable:!0,configurable:!0,writable:!0,value:!1})}onRefresh(){const t=this.instance,e=t.pages.length,i=t.page;if(e<2)return void this.cleanup();this.build();let n=this.prev,s=this.next;n&&s&&(n.removeAttribute(Y),s.removeAttribute(Y),t.isInfinite||(i<=0&&n.setAttribute(Y,""),i>=e-1&&s.setAttribute(Y,"")))}addBtn(t){var e;const i=this.instance,n=document.createElement("button");n.setAttribute("tabindex","0"),n.setAttribute("title",i.localize(`{{${t.toUpperCase()}}}`)),E(n,this.cn("button")+" "+this.cn(t===q?"isNext":"isPrev"));const s=i.isRTL?t===q?X:q:t;var r;return n.innerHTML=i.localize(this.option(`${s}Tpl`)),n.dataset[`carousel${r=t,r?r.match("^[a-z]")?r.charAt(0).toUpperCase()+r.substring(1):r:""}`]="true",null===(e=this.container)||void 0===e||e.appendChild(n),n}build(){const t=this.instance.container,e=this.cn("container");let{container:i,prev:n,next:s}=this;i||(i=t.querySelector("."+e),this.isDom=!!i),i||(i=document.createElement("div"),E(i,e),t.appendChild(i)),this.container=i,s||(s=i.querySelector("[data-carousel-next]")),s||(s=this.addBtn(q)),this.next=s,n||(n=i.querySelector("[data-carousel-prev]")),n||(n=this.addBtn(X)),this.prev=n}cleanup(){this.isDom||(this.prev&&this.prev.remove(),this.next&&this.next.remove(),this.container&&this.container.remove()),this.prev=null,this.next=null,this.container=null,this.isDom=!1}attach(){this.instance.on(["refresh","change"],this.onRefresh)}detach(){this.instance.off(["refresh","change"],this.onRefresh),this.cleanup()}}Object.defineProperty(W,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{classes:{container:"f-carousel__nav",button:"f-button",isNext:"is-next",isPrev:"is-prev"},nextTpl:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" tabindex="-1"><path d="M9 3l9 9-9 9"/></svg>
4',prevTpl:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" tabindex="-1"><path d="M15 3l-9 9 9 9"/></svg>'}});class $ extends j{constructor(){super(...arguments),Object.defineProperty(this,"selectedIndex",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"target",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"nav",{enumerable:!0,configurable:!0,writable:!0,value:null})}addAsTargetFor(t){this.target=this.instance,this.nav=t,this.attachEvents()}addAsNavFor(t){this.nav=this.instance,this.target=t,this.attachEvents()}attachEvents(){const{nav:t,target:e}=this;t&&e&&(t.options.initialSlide=e.options.initialPage,t.state===F.Ready?this.onNavReady(t):t.on("ready",this.onNavReady),e.state===F.Ready?this.onTargetReady(e):e.on("ready",this.onTargetReady))}onNavReady(t){t.on("createSlide",this.onNavCreateSlide),t.on("Panzoom.click",this.onNavClick),t.on("Panzoom.touchEnd",this.onNavTouch),this.onTargetChange()}onTargetReady(t){t.on("change",this.onTargetChange),t.on("Panzoom.refresh",this.onTargetChange),this.onTargetChange()}onNavClick(t,e,i){this.onNavTouch(t,t.panzoom,i)}onNavTouch(t,e,i){var n,s;if(Math.abs(e.dragOffset.x)>3||Math.abs(e.dragOffset.y)>3)return;const r=i.target,{nav:o,target:a}=this;if(!o||!a||!r)return;const l=r.closest("[data-index]");if(i.stopPropagation(),i.preventDefault(),!l)return;const c=parseInt(l.dataset.index||"",10)||0,h=a.getPageForSlide(c),u=o.getPageForSlide(c);o.slideTo(u),a.slideTo(h,{friction:(null===(s=null===(n=this.nav)||void 0===n?void 0:n.plugins)||void 0===s?void 0:s.Sync.option("friction"))||0}),this.markSelectedSlide(c)}onNavCreateSlide(t,e){e.index===this.selectedIndex&&this.markSelectedSlide(e.index)}onTargetChange(){var t,e;const{target:i,nav:n}=this;if(!i||!n)return;if(n.state!==F.Ready||i.state!==F.Ready)return;const s=null===(e=null===(t=i.pages[i.page])||void 0===t?void 0:t.slides[0])||void 0===e?void 0:e.index,r=n.getPageForSlide(s);this.markSelectedSlide(s),n.slideTo(r,null===n.prevPage&&null===i.prevPage?{friction:0}:void 0)}markSelectedSlide(t){const e=this.nav;e&&e.state===F.Ready&&(this.selectedIndex=t,[...e.slides].map((e=>{e.el&&e.el.classList[e.index===t?"add":"remove"]("is-nav-selected")})))}attach(){const t=this;let e=t.options.target,i=t.options.nav;e?t.addAsNavFor(e):i&&t.addAsTargetFor(i)}detach(){const t=this,e=t.nav,i=t.target;e&&(e.off("ready",t.onNavReady),e.off("createSlide",t.onNavCreateSlide),e.off("Panzoom.click",t.onNavClick),e.off("Panzoom.touchEnd",t.onNavTouch)),t.nav=null,i&&(i.off("ready",t.onTargetReady),i.off("refresh",t.onTargetChange),i.off("change",t.onTargetChange)),t.target=null}}Object.defineProperty($,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{friction:.35}});const V={Navigation:W,Dots:H,Sync:$},U="animationend",Z="isSelected",G="slide";class K extends m{get axis(){return this.isHorizontal?"e":"f"}get isEnabled(){return this.state===F.Ready}get isInfinite(){let t=!1;const{contentDim:e,viewportDim:i,pages:n,slides:s}=this,r=s[0];return n.length>=2&&r&&e+r.dim>=i&&(t=this.option("infinite")),t}get isRTL(){return"rtl"===this.option("direction")}get isHorizontal(){return"x"===this.option("axis")}constructor(t,e={},i={}){if(super(),Object.defineProperty(this,"bp",{enumerable:!0,configurable:!0,writable:!0,value:""}),Object.defineProperty(this,"lp",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"userOptions",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,"userPlugins",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:F.Init}),Object.defineProperty(this,"page",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"prevPage",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"viewport",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"track",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"slides",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"pages",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"panzoom",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"inTransition",{enumerable:!0,configurable:!0,writable:!0,value:new Set}),Object.defineProperty(this,"contentDim",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"viewportDim",{enumerable:!0,configurable:!0,writable:!0,value:0}),"string"==typeof t&&(t=document.querySelector(t)),!t||!S(t))throw new Error("No Element found");this.container=t,this.slideNext=D(this.slideNext.bind(this),150),this.slidePrev=D(this.slidePrev.bind(this),150),this.userOptions=e,this.userPlugins=i,queueMicrotask((()=>{this.processOptions()}))}processOptions(){var t,e;const i=f({},K.defaults,this.userOptions);let n="";const s=i.breakpoints;if(s&&d(s))for(const[t,e]of Object.entries(s))window.matchMedia(t).matches&&d(e)&&(n+=t,f(i,e));n===this.bp&&this.state!==F.Init||(this.bp=n,this.state===F.Ready&&(i.initialSlide=(null===(e=null===(t=this.pages[this.page])||void 0===t?void 0:t.slides[0])||void 0===e?void 0:e.index)||0),this.state!==F.Init&&this.destroy(),super.setOptions(i),!1===this.option("enabled")?this.attachEvents():setTimeout((()=>{this.init()}),0))}
vendor: 19,795 bytes, line 4
4init(){this.state=F.Init,this.emit("init"),this.attachPlugins(Object.assign(Object.assign({},K.Plugins),this.userPlugins)),this.emit("attachPlugins"),this.initLayout(),this.initSlides(),this.updateMetrics(),this.setInitialPosition(),this.initPanzoom(),this.attachEvents(),this.state=F.Ready,this.emit("ready")}initLayout(){const{container:t}=this,e=this.option("classes");E(t,this.cn("container")),o(t,e.isLTR,!this.isRTL),o(t,e.isRTL,this.isRTL),o(t,e.isVertical,!this.isHorizontal),o(t,e.isHorizontal,this.isHorizontal);let i=this.option("viewport")||t.querySelector(`.${e.viewport}`);i||(i=document.createElement("div"),E(i,e.viewport),i.append(...I(t,`.${e.slide}`)),t.prepend(i)),i.addEventListener("scroll",this.onScroll);let n=this.option("track")||t.querySelector(`.${e.track}`);n||(n=document.createElement("div"),E(n,e.track),n.append(...Array.from(i.childNodes))),n.setAttribute("aria-live","polite"),i.contains(n)||i.prepend(n),this.viewport=i,this.track=n,this.emit("initLayout")}initSlides(){const{track:t}=this;if(!t)return;const e=[...this.slides],i=[];[...I(t,`.${this.cn(G)}`)].forEach((t=>{if(S(t)){const e=B({el:t,isDom:!0,index:this.slides.length});i.push(e)}}));for(let t of[...this.option("slides",[])||[],...e])i.push(B(t));this.slides=i;for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;for(const t of i)this.emit("beforeInitSlide",t,t.index),this.emit("initSlide",t,t.index);this.emit("initSlides")}setInitialPage(){const t=this.option("initialSlide");this.page="number"==typeof t?this.getPageForSlide(t):parseInt(this.option("initialPage",0)+"",10)||0}setInitialPosition(){const{track:t,pages:e,isHorizontal:i}=this;if(!t||!e.length)return;let n=this.page;e[n]||(this.page=n=0);const s=(e[n].pos||0)*(this.isRTL&&i?1:-1),r=i?`${s}px`:"0",o=i?"0":`${s}px`;t.style.transform=`translate3d(${r}, ${o}, 0) scale(1)`,this.option("adaptiveHeight")&&this.setViewportHeight()}initPanzoom(){this.panzoom&&(this.panzoom.destroy(),this.panzoom=null);const t=this.option("Panzoom")||{};this.panzoom=new z(this.viewport,f({},{content:this.track,zoom:!1,panOnlyZoomed:!1,lockAxis:this.isHorizontal?"x":"y",infinite:this.isInfinite,click:!1,dblClick:!1,touch:t=>!(this.pages.length<2&&!t.options.infinite),bounds:()=>this.getBounds(),maxVelocity:t=>Math.abs(t.target[this.axis]-t.current[this.axis])<2*this.viewportDim?100:0},t)),this.panzoom.on("*",((t,e,...i)=>{this.emit(`Panzoom.${e}`,t,...i)})),this.panzoom.on("decel",this.onDecel),this.panzoom.on("refresh",this.onRefresh),this.panzoom.on("beforeTransform",this.onBeforeTransform),this.panzoom.on("endAnimation",this.onEndAnimation)}attachEvents(){const t=this.container;t&&(t.addEventListener("click",this.onClick,{passive:!1,capture:!1}),t.addEventListener("slideTo",this.onSlideTo)),window.addEventListener("resize",this.onResize)}createPages(){let t=[];const{contentDim:e,viewportDim:i}=this;let n=this.option("slidesPerPage");n=("auto"===n||e<=i)&&!1!==this.option("fill")?1/0:parseFloat(n+"");let s=0,r=0,o=0;for(const e of this.slides)(!t.length||r+e.dim-i>.05||o>=n)&&(t.push(N()),s=t.length-1,r=0,o=0),t[s].slides.push(e),r+=e.dim+e.gap,o++;return t}processPages(){const e=this.pages,{contentDim:i,viewportDim:n,isInfinite:s}=this,r=this.option("center"),o=this.option("fill"),a=o&&r&&i>n&&!s;if(e.forEach(((t,e)=>{var s;t.index=e,t.pos=(null===(s=t.slides[0])||void 0===s?void 0:s.pos)||0,t.dim=0;for(const[e,i]of t.slides.entries())t.dim+=i.dim,e<t.slides.length-1&&(t.dim+=i.gap);a&&t.pos+.5*t.dim<.5*n?t.pos=0:a&&t.pos+.5*t.dim>=i-.5*n?t.pos=i-n:r&&(t.pos+=-.5*(n-t.dim))})),e.forEach((e=>{o&&!s&&i>n&&(e.pos=Math.max(e.pos,0),e.pos=Math.min(e.pos,i-n)),e.pos=t(e.pos,1e3),e.dim=t(e.dim,1e3),Math.abs(e.pos)<=.1&&(e.pos=0)})),s)return e;const l=[];let c;return e.forEach((t=>{const e=Object.assign({},t);c&&e.pos===c.pos?(c.dim+=e.dim,c.slides=[...c.slides,...e.slides]):(e.index=l.length,c=e,l.push(e))})),l}getPageFromIndex(t=0){const e=this.pages.length;let i;return t=parseInt((t||0).toString())||0,i=this.isInfinite?(t%e+e)%e:Math.max(Math.min(t,e-1),0),i}getSlideMetrics(e){var i,n;const s=this.isHorizontal?"width":"height";let r=0,o=0,a=e.el;const l=!(!a||a.parentNode);if(a?r=parseFloat(a.dataset[s]||"")||0:(a=document.createElement("div"),a.style.visibility="hidden",(this.track||document.body).prepend(a)),E(a,this.cn(G)+" "+e.class+" "+e.customClass),r)a.style[s]=`${r}px`,a.style["width"===s?"height":"width"]="";else{l&&(this.track||document.body).prepend(a),r=a.getBoundingClientRect()[s]*Math.max(1,(null===(i=window.visualViewport)||void 0===i?void 0:i.scale)||1);let t=a[this.isHorizontal?"offsetWidth":"offsetHeight"];t-1>r&&(r=t)}const c=getComputedStyle(a);return"content-box"===c.boxSizing&&(this.isHorizontal?(r+=parseFloat(c.paddingLeft)||0,r+=parseFloat(c.paddingRight)||0):(r+=parseFloat(c.paddingTop)||0,r+=parseFloat(c.paddingBottom)||0)),o=parseFloat(c[this.isHorizontal?"marginRight":"marginBottom"])||0,l?null===(n=a.parentElement)||void 0===n||n.removeChild(a):e.el||a.remove(),{dim:t(r,1e3),gap:t(o,1e3)}}getBounds(){const{isInfinite:t,isRTL:e,isHorizontal:i,pages:n}=this;let s={min:0,max:0};if(t)s={min:-1/0,max:1/0};else if(n.length){const t=n[0].pos,r=n[n.length-1].pos;s=e&&i?{min:t,max:r}:{min:-1*r,max:-1*t}}return{x:i?s:{min:0,max:0},y:i?{min:0,max:0}:s}}repositionSlides(){let e,{isHorizontal:i,isRTL:n,isInfinite:s,viewport:r,viewportDim:o,contentDim:a,page:l,pages:c,slides:h,panzoom:u}=this,d=0,f=0,p=0,g=0;u?g=-1*u.current[this.axis]:c[l]&&(g=c[l].pos||0),e=i?n?"right":"left":"top",n&&i&&(g*=-1);for(const i of h){const n=i.el;n?("top"===e?(n.style.right="",n.style.left=""):n.style.top="",i.index!==d?n.style[e]=0===f?"":`${t(f,1e3)}px`:n.style[e]="",p+=i.dim+i.gap,d++):f+=i.dim+i.gap}if(s&&p&&r){let n=getComputedStyle(r),s="padding",l=i?"Right":"Bottom",c=parseFloat(n[s+(i?"Left":"Top")]);g-=c,o+=c,o+=parseFloat(n[s+l]);for(const i of h)i.el&&(t(i.pos)<t(o)&&t(i.pos+i.dim+i.gap)<t(g)&&t(g)>t(a-o)&&(i.el.style[e]=`${t(f+p,1e3)}px`),t(i.pos+i.gap)>=t(a-o)&&t(i.pos)>t(g+o)&&t(g)<t(o)&&(i.el.style[e]=`-${t(p,1e3)}px`))}let m,v,b=[...this.inTransition];if(b.length>1&&(m=c[b[0]],v=c[b[1]]),m&&v){let i=0;for(const n of h)n.el?this.inTransition.has(n.index)&&m.slides.indexOf(n)<0&&(n.el.style[e]=`${t(i+(m.pos-v.pos),1e3)}px`):i+=n.dim+n.gap}}createSlideEl(t){const{track:e,slides:i}=this;if(!e||!t)return;if(t.el&&t.el.parentNode)return;const n=t.el||document.createElement("div");E(n,this.cn(G)),E(n,t.class),E(n,t.customClass);const s=t.html;s&&(s instanceof HTMLElement?n.appendChild(s):n.innerHTML=t.html+"");const r=[];i.forEach(((t,e)=>{t.el&&r.push(e)}));const o=t.index;let a=null;r.length&&(a=i[r.reduce(((t,e)=>Math.abs(e-o)<Math.abs(t-o)?e:t))]);const l=a&&a.el&&a.el.parentNode?a.index<t.index?a.el.nextSibling:a.el:null;e.insertBefore(n,e.contains(l)?l:null),t.el=n,this.emit("createSlide",t)}removeSlideEl(t,e=!1){const i=null==t?void 0:t.el;if(!i||!i.parentNode)return;const n=this.cn(Z);if(i.classList.contains(n)&&(T(i,n),this.emit("unselectSlide",t)),t.isDom&&!e)return i.removeAttribute("aria-hidden"),i.removeAttribute("data-index"),void(i.style.left="");this.emit("removeSlide",t);const s=new CustomEvent(U);i.dispatchEvent(s),t.el&&(t.el.remove(),t.el=null)}transitionTo(t=0,e=this.option("transition")){var i,n,s,r;if(!e)return!1;const o=this.page,{pages:a,panzoom:l}=this;t=parseInt((t||0).toString())||0;const c=this.getPageFromIndex(t);if(!l||!a[c]||a.length<2||Math.abs(((null===(n=null===(i=a[o])||void 0===i?void 0:i.slides[0])||void 0===n?void 0:n.dim)||0)-this.viewportDim)>1)return!1;let h=t>o?1:-1;this.isInfinite&&(0===o&&t===a.length-1&&(h=-1),o===a.length-1&&0===t&&(h=1));const u=a[c].pos*(this.isRTL?1:-1);if(o===c&&Math.abs(u-l.target[this.axis])<1)return!1;this.clearTransitions();const d=l.isResting;E(this.container,this.cn("inTransition"));const f=(null===(s=a[o])||void 0===s?void 0:s.slides[0])||null,p=(null===(r=a[c])||void 0===r?void 0:r.slides[0])||null;this.inTransition.add(p.index),this.createSlideEl(p);let g=f.el,m=p.el;d||e===G||(e="fadeFast",g=null);const v=this.isRTL?"next":"prev",b=this.isRTL?"prev":"next";return g&&(this.inTransition.add(f.index),f.transition=e,g.addEventListener(U,this.onAnimationEnd),g.classList.add(`f-${e}Out`,`to-${h>0?b:v}`)),m&&(p.transition=e,m.addEventListener(U,this.onAnimationEnd),m.classList.add(`f-${e}In`,`from-${h>0?v:b}`)),l.current[this.axis]=u,l.target[this.axis]=u,l.requestTick(),this.onChange(c),!0}manageSlideVisiblity(){const t=new Set,e=new Set,i=this.getVisibleSlides(parseFloat(this.option("preload",0)+"")||0);for(const n of this.slides)i.has(n)?t.add(n):e.add(n);for(const e of this.inTransition)t.add(this.slides[e]);for(const e of t)this.createSlideEl(e),this.lazyLoadSlide(e);for(const i of e)t.has(i)||this.removeSlideEl(i);this.markSelectedSlides(),this.repositionSlides()}markSelectedSlides(){if(!this.pages[this.page]||!this.pages[this.page].slides)return;const t="aria-hidden";let e=this.cn(Z);if(e)for(const i of this.slides){const n=i.el;n&&(n.dataset.index=`${i.index}`,n.classList.contains("f-thumbs__slide")?this.getVisibleSlides(0).has(i)?n.removeAttribute(t):n.setAttribute(t,"true"):this.pages[this.page].slides.includes(i)?(n.classList.contains(e)||(E(n,e),this.emit("selectSlide",i)),n.removeAttribute(t)):(n.classList.contains(e)&&(T(n,e),this.emit("unselectSlide",i)),n.setAttribute(t,"true")))}}flipInfiniteTrack(){const{axis:t,isHorizontal:e,isInfinite:i,isRTL:n,viewportDim:s,contentDim:r}=this,o=this.panzoom;if(!o||!i)return;let a=o.current[t],l=o.target[t]-a,c=0,h=.5*s;n&&e?(a<-h&&(c=-1,a+=r),a>r-h&&(c=1,a-=r)):(a>h&&(c=1,a-=r),a<-r+h&&(c=-1,a+=r)),c&&(o.current[t]=a,o.target[t]=a+l)}lazyLoadImg(t,e){const i=this,n="f-fadeIn",r="is-preloading";let o=!1,a=null;const l=()=>{o||(o=!0,a&&(a.remove(),a=null),T(e,r),e.complete&&(E(e,n),setTimeout((()=>{T(e,n)}),350)),this.option("adaptiveHeight")&&t.el&&this.pages[this.page].slides.indexOf(t)>-1&&(i.updateMetrics(),i.setViewportHeight()),this.emit("load",t))};E(e,r),e.src=e.dataset.lazySrcset||e.dataset.lazySrc||"",delete e.dataset.lazySrc,delete e.dataset.lazySrcset,e.addEventListener("error",(()=>{l()})),e.addEventListener("load",(()=>{l()})),setTimeout((()=>{const i=e.parentNode;i&&t.el&&(e.complete?l():o||(a=s(x),i.insertBefore(a,e)))}),300)}lazyLoadSlide(t){const e=t&&t.el;if(!e)return;const i=new Set;let n=Array.from(e.querySelectorAll("[data-lazy-src],[data-lazy-srcset]"));e.dataset.lazySrc&&n.push(e),n.map((t=>{t instanceof HTMLImageElement?i.add(t):t instanceof HTMLElement&&t.dataset.lazySrc&&(t.style.backgroundImage=`url('${t.dataset.lazySrc}')`,delete t.dataset.lazySrc)}));for(const e of i)this.lazyLoadImg(t,e)}onAnimationEnd(t){var e;const i=t.target,n=i?parseInt(i.dataset.index||"",10)||0:-1,s=this.slides[n],r=t.animationName;if(!i||!s||!r)return;const o=!!this.inTransition.has(n)&&s.transition;o&&r.substring(0,o.length+2)===`f-${o}`&&this.inTransition.delete(n),this.inTransition.size||this.clearTransitions(),n===this.page&&(null===(e=this.panzoom)||void 0===e?void 0:e.isResting)&&this.emit("settle")}onDecel(t,e=0,i=0,n=0,s=0){if(this.option("dragFree"))return void this.setPageFromPosition();const{isRTL:r,isHorizontal:o,axis:a,pages:l}=this,c=l.length,h=Math.abs(Math.atan2(i,e)/(Math.PI/180));let u=0;if(u=h>45&&h<135?o?0:i:o?e:0,!c)return;let d=this.page,f=r&&o?1:-1;const p=t.current[a]*f;let{pageIndex:g}=this.getPageFromPosition(p);Math.abs(u)>5?(l[d].dim<document.documentElement["client"+(this.isHorizontal?"Width":"Height")]-1&&(d=g),d=r&&o?u<0?d-1:d+1:u<0?d+1:d-1):d=0===n&&0===s?d:g,this.slideTo(d,{transition:!1,friction:t.option("decelFriction")})}onClick(t){const e=t.target,i=e&&S(e)?e.dataset:null;let n,s;i&&(void 0!==i.carouselPage?(s="slideTo",n=i.carouselPage):void 0!==i.carouselNext?s="slideNext":void 0!==i.carouselPrev&&(s="slidePrev")),s?(t.preventDefault(),t.stopPropagation(),e&&!e.hasAttribute("disabled")&&this[s](n)):this.emit("click",t)}onSlideTo(t){const e=t.detail||0;this.slideTo(this.getPageForSlide(e),{friction:0})}onChange(t,e=0){const i=this.page;this.prevPage=i,this.page=t,this.option("adaptiveHeight")&&this.setViewportHeight(),t!==i&&(this.markSelectedSlides(),this.emit("change",t,i,e))}onRefresh(){let t=this.contentDim,e=this.viewportDim;this.updateMetrics(),this.contentDim===t&&this.viewportDim===e||this.slideTo(this.page,{friction:0,transition:!1})}onScroll(){var t;null===(t=this.viewport)||void 0===t||t.scroll(0,0)}onResize(){this.option("breakpoints")&&this.processOptions()}onBeforeTransform(t){this.lp!==t.current[this.axis]&&(this.flipInfiniteTrack(),this.manageSlideVisiblity()),this.lp=t.current.e}onEndAnimation(){this.inTransition.size||this.emit("settle")}reInit(t=null,e=null){this.destroy(),this.state=F.Init,this.prevPage=null,this.userOptions=t||this.userOptions,this.userPlugins=e||this.userPlugins,this.processOptions()}slideTo(t=0,{friction:e=this.option("friction"),transition:i=this.option("transition")}={}){if(this.state===F.Destroy)return;t=parseInt((t||0).toString())||0;const n=this.getPageFromIndex(t),{axis:s,isHorizontal:r,isRTL:o,pages:a,panzoom:l}=this,c=a.length,h=o&&r?1:-1;if(!l||!c)return;if(this.page!==n){const e=new Event("beforeChange",{bubbles:!0,cancelable:!0});if(this.emit("beforeChange",e,t),e.defaultPrevented)return}if(this.transitionTo(t,i))return;let u=a[n].pos;if(this.isInfinite){const e=this.contentDim,i=l.target[s]*h;2===c?u+=e*Math.floor(parseFloat(t+"")/2):u=[u,u-e,u+e].reduce((function(t,e){return Math.abs(e-i)<Math.abs(t-i)?e:t}))}u*=h,Math.abs(l.target[s]-u)<1||(l.panTo({x:r?u:0,y:r?0:u,friction:e}),this.onChange(n))}slideToClosest(t){if(this.panzoom){const{pageIndex:e}=this.getPageFromPosition();this.slideTo(e,t)}}slideNext(){this.slideTo(this.page+1)}slidePrev(){this.slideTo(this.page-1)}clearTransitions(){this.inTransition.clear(),T(this.container,this.cn("inTransition"));const t=["to-prev","to-next","from-prev","from-next"];for(const e of this.slides){const i=e.el;if(i){i.removeEventListener(U,this.onAnimationEnd),i.classList.remove(...t);const n=e.transition;n&&i.classList.remove(`f-${n}Out`,`f-${n}In`)}}this.manageSlideVisiblity()}addSlide(t,e){var i,n,s,r;const o=this.panzoom,a=(null===(i=this.pages[this.page])||void 0===i?void 0:i.pos)||0,l=(null===(n=this.pages[this.page])||void 0===n?void 0:n.dim)||0,c=this.contentDim<this.viewportDim;let h=Array.isArray(e)?e:[e];const u=[];for(const t of h)u.push(B(t));this.slides.splice(t,0,...u);for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;for(const t of u)this.emit("beforeInitSlide",t,t.index);if(this.page>=t&&(this.page+=u.length),this.updateMetrics(),o){const e=(null===(s=this.pages[this.page])||void 0===s?void 0:s.pos)||0,i=(null===(r=this.pages[this.page])||void 0===r?void 0:r.dim)||0,n=this.pages.length||1,h=this.isRTL?l-i:i-l,u=this.isRTL?a-e:e-a;c&&1===n?(t<=this.page&&(o.current[this.axis]-=h,o.target[this.axis]-=h),o.panTo({[this.isHorizontal?"x":"y"]:-1*e})):u&&t<=this.page&&(o.target[this.axis]-=u,o.current[this.axis]-=u,o.requestTick())}for(const t of u)this.emit("initSlide",t,t.index)}prependSlide(t){this.addSlide(0,t)}appendSlide(t){this.addSlide(this.slides.length,t)}removeSlide(t){const e=this.slides.length;t=(t%e+e)%e;const i=this.slides[t];if(i){this.removeSlideEl(i,!0),this.slides.splice(t,1);for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;this.updateMetrics(),this.slideTo(this.page,{friction:0,transition:!1}),this.emit("destroySlide",i)}}updateMetrics(){const{panzoom:e,viewport:i,track:n,slides:s,isHorizontal:r,isInfinite:o}=this;if(!n)return;const a=r?"width":"height",l=r?"offsetWidth":"offsetHeight";if(i){let e=Math.max(i[l],t(i.getBoundingClientRect()[a],1e3)),n=getComputedStyle(i),s="padding",o=r?"Right":"Bottom";e-=parseFloat(n[s+(r?"Left":"Top")])+parseFloat(n[s+o]),this.viewportDim=e}let c,h=0;for(const[e,i]of s.entries()){let n=0,r=0;!i.el&&c?(n=c.dim,r=c.gap):(({dim:n,gap:r}=this.getSlideMetrics(i)),c=i),n=t(n,1e3),r=t(r,1e3),i.dim=n,i.gap=r,i.pos=h,h+=n,(o||e<s.length-1)&&(h+=r)}h=t(h,1e3),this.contentDim=h,e&&(e.contentRect[a]=h,e.contentRect[r?"fullWidth":"fullHeight"]=h),this.pages=this.createPages(),this.pages=this.processPages(),this.state===F.Init&&this.setInitialPage(),this.page=Math.max(0,Math.min(this.page,this.pages.length-1)),this.manageSlideVisiblity(),this.emit("refresh")}getProgress(e,i=!1,n=!1){void 0===e&&(e=this.page);const s=this,r=s.panzoom,o=s.contentDim,a=s.pages[e]||0;if(!a||!r)return e>this.page?-1:1;let l=-1*r.current.e,c=t((l-a.pos)/(1*a.dim),1e3),h=c,u=c;this.isInfinite&&!0!==n&&(h=t((l-a.pos+o)/(1*a.dim),1e3),u=t((l-a.pos-o)/(1*a.dim),1e3));let d=[c,h,u].reduce((function(t,e){return Math.abs(e)<Math.abs(t)?e:t}));return i?d:d>1?1:d<-1?-1:d}setViewportHeight(){const{page:t,pages:e,viewport:i,isHorizontal:n}=this;if(!i||!e[t])return;let s=0;n&&this.track&&(this.track.style.height="auto",e[t].slides.forEach((t=>{t.el&&(s=Math.max(s,t.el.offsetHeight))}))),i.style.height=s?`${s}px`:""}getPageForSlide(t){for(const e of this.pages)for(const i of e.slides)if(i.index===t)return e.index;return-1}getVisibleSlides(t=0){var e;const i=new Set;let{panzoom:n,contentDim:s,viewportDim:r,pages:o,page:a}=this;if(r){s=s+(null===(e=this.slides[this.slides.length-1])||void 0===e?void 0:e.gap)||0;let l=0;l=n&&n.state!==v.Init&&n.state!==v.Destroy?-1*n.current[this.axis]:o[a]&&o[a].pos||0,this.isInfinite&&(l-=Math.floor(l/s)*s),this.isRTL&&this.isHorizontal&&(l*=-1);const c=l-r*t,h=l+r*(t+1),u=this.isInfinite?[-1,0,1]:[0];for(const t of this.slides)for(const e of u){const n=t.pos+e*s,r=n+t.dim+t.gap;n<h&&r>c&&i.add(t)}}return i}getPageFromPosition(t){const{viewportDim:e,contentDim:i,slides:n,pages:s,panzoom:r}=this,o=s.length,a=n.length,l=n[0],c=n[a-1],h=this.option("center");let u=0,d=0,f=0,p=void 0===t?-1*((null==r?void 0:r.target[this.axis])||0):t;h&&(p+=.5*e),this.isInfinite?(p<l.pos-.5*c.gap&&(p-=i,f=-1),p>c.pos+c.dim+.5*c.gap&&(p-=i,f=1)):p=Math.max(l.pos||0,Math.min(p,c.pos));let g=c,m=n.find((t=>{const e=t.pos-.5*g.gap,i=t.pos+t.dim+.5*t.gap;return g=t,p>=e&&p<i}));return m||(m=c),d=this.getPageForSlide(m.index),u=d+f*o,{page:u,pageIndex:d}}setPageFromPosition(){const{pageIndex:t}=this.getPageFromPosition();this.onChange(t)}destroy(){if([F.Destroy].includes(this.state))return;this.state=F.Destroy;const{container:t,viewport:e,track:i,slides:n,panzoom:s}=this,r=this.option("classes");t.removeEventListener("click",this.onClick,{passive:!1,capture:!1}),t.removeEventListener("slideTo",this.onSlideTo),window.removeEventListener("resize",this.onResize),s&&(s.destroy(),this.panzoom=null),n&&n.forEach((t=>{this.removeSlideEl(t)})),this.detachPlugins(),e&&(e.removeEventListener("scroll",this.onScroll),e.offsetParent&&i&&i.offsetParent&&e.replaceWith(...i.childNodes));for(const[e,i]of Object.entries(r))"container"!==e&&i&&t.classList.remove(i);this.track=null,this.viewport=null,this.page=0,this.slides=[];const o=this.events.get("ready");this.events=new Map,o&&this.events.set("ready",o)}}Object.defineProperty(K,"Panzoom",{enumerable:!0,configurable:!0,writable:!0,value:z}),Object.defineProperty(K,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{viewport:null,track:null,enabled:!0,slides:[],axis:"x",transition:"fade",preload:1,slidesPerPage:"auto",initialPage:0,friction:.12,Panzoom:{decelFriction:.12},center:!0,infinite:!0,fill:!0,dragFree:!1,adaptiveHeight:!1,direction:"ltr",classes:{container:"f-carousel",viewport:"f-carousel__viewport",track:"f-carousel__track",slide:"f-carousel__slide",isLTR:"is-ltr",isRTL:"is-rtl",isHorizontal:"is-horizontal",isVertical:"is-vertical",inTransition:"in-transition",isSelected:"is-selected"},l10n:{NEXT:"Next slide",PREV:"Previous slide",GOTO:"Go to slide #%d"}}}),Object.defineProperty(K,"Plugins",{enumerable:!0,configurable:!0,writable:!0,value:V}
vendor: 4,164 bytes, line 4
4);const J=function(t){if(!S(t))return 0;const e=window.scrollY,i=window.innerHeight,n=e+i,s=t.getBoundingClientRect(),r=s.y+e,o=s.height,a=r+o;if(e>a||n<r)return 0;if(e<r&&n>a)return 100;if(r<e&&a>n)return 100;let l=o;r<e&&(l-=e-r),a>n&&(l-=a-n);const c=l/i*100;return Math.round(c)},Q=!("undefined"==typeof window||!window.document||!window.document.createElement);let tt;const et=["a[href]","area[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden]):not(.fancybox-focus-guard)","iframe","object","embed","video","audio","[contenteditable]",'[tabindex]:not([tabindex^="-"]):not([disabled]):not([aria-hidden])'].join(","),it=t=>{if(t&&Q){void 0===tt&&document.createElement("div").focus({get preventScroll(){return tt=!0,!1}});try{if(tt)t.focus({preventScroll:!0});else{const e=window.scrollY||document.body.scrollTop,i=window.scrollX||document.body.scrollLeft;t.focus(),document.body.scrollTo({top:e,left:i,behavior:"auto"})}}catch(t){}}},nt=()=>{const t=document;let e,i="",n="",s="";return t.fullscreenEnabled?(i="requestFullscreen",n="exitFullscreen",s="fullscreenElement"):t.webkitFullscreenEnabled&&(i="webkitRequestFullscreen",n="webkitExitFullscreen",s="webkitFullscreenElement"),i&&(e={request:function(e=t.documentElement){return"webkitRequestFullscreen"===i?e[i](Element.ALLOW_KEYBOARD_INPUT):e[i]()},exit:function(){return t[s]&&t[n]()},isFullscreen:function(){return t[s]}}),e},st={animated:!0,autoFocus:!0,backdropClick:"close",Carousel:{classes:{container:"fancybox__carousel",viewport:"fancybox__viewport",track:"fancybox__track",slide:"fancybox__slide"}},closeButton:"auto",closeExisting:!1,commonCaption:!1,compact:()=>window.matchMedia("(max-width: 578px), (max-height: 578px)").matches,contentClick:"toggleZoom",contentDblClick:!1,defaultType:"image",defaultDisplay:"flex",dragToClose:!0,Fullscreen:{autoStart:!1},groupAll:!1,groupAttr:"data-fancybox",hideClass:"f-fadeOut",hideScrollbar:!0,idle:3500,keyboard:{Escape:"close",Delete:"close",Backspace:"close",PageUp:"next",PageDown:"prev",ArrowUp:"prev",ArrowDown:"next",ArrowRight:"next",ArrowLeft:"prev"},l10n:Object.assign(Object.assign({},y),{CLOSE:"Close",NEXT:"Next",PREV:"Previous",MODAL:"You can close this modal content with the ESC key",ERROR:"Something Went Wrong, Please Try Again Later",IMAGE_ERROR:"Image Not Found",ELEMENT_NOT_FOUND:"HTML Element Not Found",AJAX_NOT_FOUND:"Error Loading AJAX : Not Found",AJAX_FORBIDDEN:"Error Loading AJAX : Forbidden",IFRAME_ERROR:"Error Loading Page",TOGGLE_ZOOM:"Toggle zoom level",TOGGLE_THUMBS:"Toggle thumbnails",TOGGLE_SLIDESHOW:"Toggle slideshow",TOGGLE_FULLSCREEN:"Toggle full-screen mode",DOWNLOAD:"Download"}),parentEl:null,placeFocusBack:!0,showClass:"f-zoomInUp",startIndex:0,tpl:{closeButton:'<button data-fancybox-close class="f-button is-close-btn" title="{{CLOSE}}"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" tabindex="-1"><path d="M20 20L4 4m16 0L4 20"/></svg></button>',main:'<div class="fancybox__container" role="dialog" aria-modal="true" aria-label="{{MODAL}}" tabindex="-1">\n    <div class="fancybox__backdrop"></div>\n    <div class="fancybox__carousel"></div>\n    <div class="fancybox__footer"></div>\n  </div>'},trapFocus:!0,wheel:"zoom"};var rt,ot;!function(t){t[t.Init=0]="Init",t[t.Ready=1]="Ready",t[t.Closing=2]="Closing",t[t.CustomClosing=3]="CustomClosing",t[t.Destroy=4]="Destroy"}(rt||(rt={})),function(t){t[t.Loading=0]="Loading",t[t.Opening=1]="Opening",t[t.Ready=2]="Ready",t[t.Closing=3]="Closing"}(ot||(ot={}));let at="",lt=!1,ct=!1,ht=null;const ut=()=>{let t="",e="";const i=Se.getInstance();if(i){const n=i.carousel,s=i.getSlide();if(n&&s){let r=s.slug||void 0,o=s.triggerEl||void 0;e=r||i.option("slug")||"",!e&&o&&o.dataset&&(e=o.dataset.fancybox||""),e&&"true"!==e&&(t="#"+e+(!r&&n.slides.length>1?"-"+(s.index+1):""))}}return{hash:t,slug:e,index:1}},dt=()=>{const t=new URL(document.URL).hash,e=t.slice(1).split("-"),i=e[e.length-1],n=i&&/^\+?\d+$/.test(i)&&parseInt(e.pop()||"1",10)||1;return{hash:t,slug:e.join("-"),index:n}}
vendor: 11,435 bytes, line 4
4,ft=()=>{const{slug:t,index:e}=dt();if(!t)return;let i=document.querySelector(`[data-slug="${t}"]`);if(i&&i.dispatchEvent(new CustomEvent("click",{bubbles:!0,cancelable:!0})),Se.getInstance())return;const n=document.querySelectorAll(`[data-fancybox="${t}"]`);n.length&&(i=n[e-1],i&&i.dispatchEvent(new CustomEvent("click",{bubbles:!0,cancelable:!0})))},pt=()=>{if(!1===Se.defaults.Hash)return;const t=Se.getInstance();if(!1===(null==t?void 0:t.options.Hash))return;const{slug:e,index:i}=dt(),{slug:n}=ut();t&&(e===n?t.jumpTo(i-1):(lt=!0,t.close())),ft()},gt=()=>{ht&&clearTimeout(ht),queueMicrotask((()=>{pt()}))},mt=()=>{window.addEventListener("hashchange",gt,!1),setTimeout((()=>{pt()}),500)};Q&&(/complete|interactive|loaded/.test(document.readyState)?mt():document.addEventListener("DOMContentLoaded",mt));const vt="is-zooming-in";class bt extends j{onCreateSlide(t,e,i){const n=this.instance.optionFor(i,"src")||"";i.el&&"image"===i.type&&"string"==typeof n&&this.setImage(i,n)}onRemoveSlide(t,e,i){i.panzoom&&i.panzoom.destroy(),i.panzoom=void 0,i.imageEl=void 0}onChange(t,e,i,n){T(this.instance.container,vt);for(const t of e.slides){const e=t.panzoom;e&&t.index!==i&&e.reset(.35)}}onClose(){var t;const e=this.instance,i=e.container,n=e.getSlide();if(!i||!i.parentElement||!n)return;const{el:s,contentEl:r,panzoom:o,thumbElSrc:a}=n;if(!s||!a||!r||!o||o.isContentLoading||o.state===v.Init||o.state===v.Destroy)return;o.updateMetrics();let l=this.getZoomInfo(n);if(!l)return;this.instance.state=rt.CustomClosing,i.classList.remove(vt),i.classList.add("is-zooming-out"),r.style.backgroundImage=`url('${a}')`;const c=i.getBoundingClientRect();1===((null===(t=window.visualViewport)||void 0===t?void 0:t.scale)||1)&&Object.assign(i.style,{position:"absolute",top:`${i.offsetTop+window.scrollY}px`,left:`${i.offsetLeft+window.scrollX}px`,bottom:"auto",right:"auto",width:`${c.width}px`,height:`${c.height}px`,overflow:"hidden"});const{x:h,y:u,scale:d,opacity:f}=l;if(f){const t=((t,e,i,n)=>{const s=e-t;return e=>1+((e-t)/s*-1||0)})(o.scale,d);o.on("afterTransform",(()=>{r.style.opacity=t(o.scale)+""}))}o.on("endAnimation",(()=>{e.destroy()})),o.target.a=d,o.target.b=0,o.target.c=0,o.target.d=d,o.panTo({x:h,y:u,scale:d,friction:f?.2:.33,ignoreBounds:!0}),o.isResting&&e.destroy()}setImage(t,e){const i=this.instance;t.src=e,this.process(t,e).then((e=>{const{contentEl:n,imageEl:s,thumbElSrc:r,el:o}=t;if(i.isClosing()||!n||!s)return;n.offsetHeight;const a=!!i.isOpeningSlide(t)&&this.getZoomInfo(t);if(this.option("protected")&&o){o.addEventListener("contextmenu",(t=>{t.preventDefault()}));const t=document.createElement("div");E(t,"fancybox-protected"),n.appendChild(t)}if(r&&a){const s=e.contentRect,o=Math.max(s.fullWidth,s.fullHeight);let c=null;!a.opacity&&o>1200&&(c=document.createElement("img"),E(c,"fancybox-ghost"),c.src=r,n.appendChild(c));const h=()=>{c&&(E(c,"f-fadeFastOut"),setTimeout((()=>{c&&(c.remove(),c=null)}),200))};(l=r,new Promise(((t,e)=>{const i=new Image;i.onload=t,i.onerror=e,i.src=l}))).then((()=>{i.hideLoading(t),t.state=ot.Opening,this.instance.emit("reveal",t),this.zoomIn(t).then((()=>{h(),this.instance.done(t)}),(()=>{})),c&&setTimeout((()=>{h()}),o>2500?800:200)}),(()=>{i.hideLoading(t),i.revealContent(t)}))}else{const n=this.optionFor(t,"initialSize"),s=this.optionFor(t,"zoom"),r={event:i.prevMouseMoveEvent||i.options.event,friction:s?.12:0};let o=i.optionFor(t,"showClass")||void 0,a=!0;i.isOpeningSlide(t)&&("full"===n?e.zoomToFull(r):"cover"===n?e.zoomToCover(r):"max"===n?e.zoomToMax(r):a=!1,e.stop("current")),a&&o&&(o=e.isDragging?"f-fadeIn":""),i.hideLoading(t),i.revealContent(t,o)}var l}),(()=>{i.setError(t,"{{IMAGE_ERROR}}")}))}process(t,e){return new Promise(((i,n)=>{var r;const o=this.instance,a=t.el;o.clearContent(t),o.showLoading(t);let l=this.optionFor(t,"content");if("string"==typeof l&&(l=s(l)),!l||!S(l)){if(l=document.createElement("img"),l instanceof HTMLImageElement){let i="",n=t.caption;i="string"==typeof n&&n?n.replace(/<[^>]+>/gi,"").substring(0,1e3):`Image ${t.index+1} of ${(null===(r=o.carousel)||void 0===r?void 0:r.pages.length)||1}`,l.src=e||"",l.alt=i,l.draggable=!1,t.srcset&&l.setAttribute("srcset",t.srcset),this.instance.isOpeningSlide(t)&&(l.fetchPriority="high")}t.sizes&&l.setAttribute("sizes",t.sizes)}E(l,"fancybox-image"),t.imageEl=l,o.setContent(t,l,!1),t.panzoom=new z(a,f({transformParent:!0},this.option("Panzoom")||{},{content:l,width:(e,i)=>o.optionFor(t,"width","auto",i)||"auto",height:(e,i)=>o.optionFor(t,"height","auto",i)||"auto",wheel:()=>{const t=o.option("wheel");return("zoom"===t||"pan"==t)&&t},click:(e,i)=>{var n,s;if(o.isCompact||o.isClosing())return!1;if(t.index!==(null===(n=o.getSlide())||void 0===n?void 0:n.index))return!1;if(i){const t=i.composedPath()[0];if(["A","BUTTON","TEXTAREA","OPTION","INPUT","SELECT","VIDEO"].includes(t.nodeName))return!1}let r=!i||i.target&&(null===(s=t.contentEl)||void 0===s?void 0:s.contains(i.target));return o.option(r?"contentClick":"backdropClick")||!1},dblClick:()=>o.isCompact?"toggleZoom":o.option("contentDblClick")||!1,spinner:!1,panOnlyZoomed:!0,wheelLimit:1/0,on:{ready:t=>{i(t)},error:()=>{n()},destroy:()=>{n()}}}))}))}zoomIn(t){return new Promise(((e,i)=>{const n=this.instance,s=n.container,{panzoom:r,contentEl:o,el:a}=t;r&&r.updateMetrics();const l=this.getZoomInfo(t);if(!(l&&a&&o&&r&&s))return void i();const{x:c,y:h,scale:u,opacity:d}=l,f=()=>{t.state!==ot.Closing&&(d&&(o.style.opacity=Math.max(Math.min(1,1-(1-r.scale)/(1-u)),0)+""),r.scale>=1&&r.scale>r.targetScale-.1&&e(r))},p=t=>{(t.scale<.99||t.scale>1.01)&&!t.isDragging||(T(s,vt),o.style.opacity="",t.off("endAnimation",p),t.off("touchStart",p),t.off("afterTransform",f),e(t))};r.on("endAnimation",p),r.on("touchStart",p),r.on("afterTransform",f),r.on(["error","destroy"],(()=>{i()})),r.panTo({x:c,y:h,scale:u,friction:0,ignoreBounds:!0}),r.stop("current");const g={event:"mousemove"===r.panMode?n.prevMouseMoveEvent||n.options.event:void 0},m=this.optionFor(t,"initialSize");E(s,vt),n.hideLoading(t),"full"===m?r.zoomToFull(g):"cover"===m?r.zoomToCover(g):"max"===m?r.zoomToMax(g):r.reset(.172)}))}getZoomInfo(t){const{el:e,imageEl:i,thumbEl:n,panzoom:s}=t,r=this.instance,o=r.container;if(!e||!i||!n||!s||J(n)<3||!this.optionFor(t,"zoom")||!o||r.state===rt.Destroy)return!1;if("0"===getComputedStyle(o).getPropertyValue("--f-images-zoom"))return!1;const a=window.visualViewport||null;if(1!==(a?a.scale:1))return!1;let{top:l,left:c,width:h,height:u}=n.getBoundingClientRect(),{top:d,left:f,fitWidth:p,fitHeight:g}=s.contentRect;if(!(h&&u&&p&&g))return!1;const m=s.container.getBoundingClientRect();f+=m.left,d+=m.top;const v=-1*(f+.5*p-(c+.5*h)),b=-1*(d+.5*g-(l+.5*u)),y=h/p;let _=this.option("zoomOpacity")||!1;return"auto"===_&&(_=Math.abs(h/u-p/g)>.1),{x:v,y:b,scale:y,opacity:_}}attach(){const t=this,e=t.instance;e.on("Carousel.change",t.onChange),e.on("Carousel.createSlide",t.onCreateSlide),e.on("Carousel.removeSlide",t.onRemoveSlide),e.on("close",t.onClose)}detach(){const t=this,e=t.instance;e.off("Carousel.change",t.onChange),e.off("Carousel.createSlide",t.onCreateSlide),e.off("Carousel.removeSlide",t.onRemoveSlide),e.off("close",t.onClose)}}Object.defineProperty(bt,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{initialSize:"fit",Panzoom:{maxScale:1},protected:!1,zoom:!0,zoomOpacity:"auto"}}),"function"==typeof SuppressedError&&SuppressedError;const yt="html",_t="image",wt="map",xt="youtube",St="vimeo",Tt="html5video",Et=(t,e={})=>{const i=new URL(t),n=new URLSearchParams(i.search),s=new URLSearchParams;for(const[t,i]of[...n,...Object.entries(e)]){let e=i+"";if("t"===t){let t=e.match(/((\d*)m)?(\d*)s?/);t&&s.set("start",60*parseInt(t[2]||"0")+parseInt(t[3]||"0")+"")}else s.set(t,e)}let r=s+"",o=t.match(/#t=((.*)?\d+s)/);return o&&(r+=`#t=${o[1]}`),r},Mt=["image","html","ajax","inline","clone","iframe","map","pdf","html5video","youtube","vimeo"];class Ct extends j{onBeforeInitSlide(t,e,i){this.processType(i)}onCreateSlide(t,e,i){this.setContent(i)}onClearContent(t,e){e.xhr&&(e.xhr.abort(),e.xhr=null);const i=e.iframeEl;i&&(i.onload=i.onerror=null,i.src="//about:blank",e.iframeEl=null);const n=e.contentEl,s=e.placeholderEl;if("inline"===e.type&&n&&s)n.classList.remove("fancybox__content"),"none"!==getComputedStyle(n).getPropertyValue("display")&&(n.style.display="none"),setTimeout((()=>{s&&(n&&s.parentNode&&s.parentNode.insertBefore(n,s),s.remove())}),0),e.contentEl=void 0,e.placeholderEl=void 0;else for(;e.el&&e.el.firstChild;)e.el.removeChild(e.el.firstChild)}onSelectSlide(t,e,i){i.state===ot.Ready&&this.playVideo()}onUnselectSlide(t,e,i){var n,s;if(i.type===Tt){try{null===(s=null===(n=i.el)||void 0===n?void 0:n.querySelector("video"))||void 0===s||s.pause()}catch(t){}return}let r;i.type===St?r={method:"pause",value:"true"}:i.type===xt&&(r={event:"command",func:"pauseVideo"}),r&&i.iframeEl&&i.iframeEl.contentWindow&&i.iframeEl.contentWindow.postMessage(JSON.stringify(r),"*"),i.poller&&clearTimeout(i.poller)}onDone(t,e){t.isCurrentSlide(e)&&!t.isClosing()&&this.playVideo()}onRefresh(t,e){e.slides.forEach((t=>{t.el&&(this.resizeIframe(t),this.setAspectRatio(t))}))}onMessage(t){try{let e=JSON.parse(t.data);if("https://player.vimeo.com"===t.origin){if("ready"===e.event)for(let e of Array.from(document.getElementsByClassName("fancybox__iframe")))e instanceof HTMLIFrameElement&&e.contentWindow===t.source&&(e.dataset.ready="true")}else if(t.origin.match(/^https:\/\/(www.)?youtube(-nocookie)?.com$/)&&"onReady"===e.event){const t=document.getElementById(e.id);t&&(t.dataset.ready="true")}}catch(t){}}loadAjaxContent(t){const e=this.instance.optionFor(t,"src")||"";this.instance.showLoading(t);const i=this.instance,n=new XMLHttpRequest;i.showLoading(t),n.onreadystatechange=function(){n.readyState===XMLHttpRequest.DONE&&i.state===rt.Ready&&(i.hideLoading(t),200===n.status?i.setContent(t,n.responseText):i.setError(t,404===n.status?"{{AJAX_NOT_FOUND}}":"{{AJAX_FORBIDDEN}}"))};const s=t.ajax||null;n.open(s?"POST":"GET",e+""),n.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),n.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.send(s),t.xhr=n}setInlineContent(t){let e=null;if(S(t.src))e=t.src;else if("string"==typeof t.src){const i=t.src.split("#",2).pop();e=i?document.getElementById(i):null}if(e){if("clone"===t.type||e.closest(".fancybox__slide")){e=e.cloneNode(!0);const i=e.dataset.animationName;i&&(e.classList.remove(i),delete e.dataset.animationName);let n=e.getAttribute("id");n=n?`${n}--clone`:`clone-${this.instance.id}-${t.index}`,e.setAttribute("id",n)}else if(e.parentNode){const i=document.createElement("div");i.classList.add("fancybox-placeholder"),e.parentNode.insertBefore(i,e),t.placeholderEl=i}this.instance.setContent(t,e)}else this.instance.setError(t,"{{ELEMENT_NOT_FOUND}}")}setIframeContent(t){const{src:e,el:i}=t;if(!e||"string"!=typeof e||!i)return;i.classList.add("is-loading");const n=this.instance,s=document.createElement("iframe");s.className="fancybox__iframe",s.setAttribute("id",`fancybox__iframe_${n.id}_${t.index}`);for(const[e,i]of Object.entries(this.optionFor(t,"iframeAttr")||{}))s.setAttribute(e,i);s.onerror=()=>{n.setError(t,"{{IFRAME_ERROR}}")},t.iframeEl=s;const r=this.optionFor(t,"preload");if("iframe"!==t.type||!1===r)return s.setAttribute("src",t.src+""),n.setContent(t,s,!1),this.resizeIframe(t),void n.revealContent(t);n.showLoading(t),s.onload=()=>
vendor: 9,511 bytes, line 4
4{if(!s.src.length)return;const e="true"!==s.dataset.ready;s.dataset.ready="true",this.resizeIframe(t),e?n.revealContent(t):n.hideLoading(t)},s.setAttribute("src",e),n.setContent(t,s,!1)}resizeIframe(t){const{type:e,iframeEl:i}=t;if(e===xt||e===St)return;const n=null==i?void 0:i.parentElement;if(!i||!n)return;let s=t.autoSize;void 0===s&&(s=this.optionFor(t,"autoSize"));let r=t.width||0,o=t.height||0;r&&o&&(s=!1);const a=n&&n.style;if(!1!==t.preload&&!1!==s&&a)try{const t=window.getComputedStyle(n),e=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),s=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),l=i.contentWindow;if(l){const t=l.document,i=t.getElementsByTagName(yt)[0],n=t.body;a.width="",n.style.overflow="hidden",r=r||i.scrollWidth+e,a.width=`${r}px`,n.style.overflow="",a.flex="0 0 auto",a.height=`${n.scrollHeight}px`,o=i.scrollHeight+s}}catch(t){}if(r||o){const t={flex:"0 1 auto",width:"",height:""};r&&"auto"!==r&&(t.width=`${r}px`),o&&"auto"!==o&&(t.height=`${o}px`),Object.assign(a,t)}}playVideo(){const t=this.instance.getSlide();if(!t)return;const{el:e}=t;if(!e||!e.offsetParent)return;if(!this.optionFor(t,"videoAutoplay"))return;if(t.type===Tt)try{const t=e.querySelector("video");if(t){const e=t.play();void 0!==e&&e.then((()=>{})).catch((e=>{t.muted=!0,t.play()}))}}catch(t){}if(t.type!==xt&&t.type!==St)return;const i=()=>{if(t.iframeEl&&t.iframeEl.contentWindow){let e;if("true"===t.iframeEl.dataset.ready)return e=t.type===xt?{event:"command",func:"playVideo"}:{method:"play",value:"true"},e&&t.iframeEl.contentWindow.postMessage(JSON.stringify(e),"*"),void(t.poller=void 0);t.type===xt&&(e={event:"listening",id:t.iframeEl.getAttribute("id")},t.iframeEl.contentWindow.postMessage(JSON.stringify(e),"*"))}t.poller=setTimeout(i,250)};i()}processType(t){if(t.html)return t.type=yt,t.src=t.html,void(t.html="");const e=this.instance.optionFor(t,"src","");if(!e||"string"!=typeof e)return;let i=t.type,n=null;if(n=e.match(/(youtube\.com|youtu\.be|youtube\-nocookie\.com)\/(?:watch\?(?:.*&)?v=|v\/|u\/|shorts\/|embed\/?)?(videoseries\?list=(?:.*)|[\w-]{11}|\?listType=(?:.*)&list=(?:.*))(?:.*)/i)){const s=this.optionFor(t,xt),{nocookie:r}=s,o=function(t,e){var i={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(i[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var s=0;for(n=Object.getOwnPropertySymbols(t);s<n.length;s++)e.indexOf(n[s])<0&&Object.prototype.propertyIsEnumerable.call(t,n[s])&&(i[n[s]]=t[n[s]])}return i}(s,["nocookie"]),a=`www.youtube${r?"-nocookie":""}.com`,l=Et(e,o),c=encodeURIComponent(n[2]);t.videoId=c,t.src=`https://${a}/embed/${c}?${l}`,t.thumbSrc=t.thumbSrc||`https://i.ytimg.com/vi/${c}/mqdefault.jpg`,i=xt}else if(n=e.match(/^.+vimeo.com\/(?:\/)?([\d]+)((\/|\?h=)([a-z0-9]+))?(.*)?/)){const s=Et(e,this.optionFor(t,St)),r=encodeURIComponent(n[1]),o=n[4]||"";t.videoId=r,t.src=`https://player.vimeo.com/video/${r}?${o?`h=${o}${s?"&":""}`:""}${s}`,i=St}if(!i&&t.triggerEl){const e=t.triggerEl.dataset.type;Mt.includes(e)&&(i=e)}i||"string"==typeof e&&("#"===e.charAt(0)?i="inline":(n=e.match(/\.(mp4|mov|ogv|webm)((\?|#).*)?$/i))?(i=Tt,t.videoFormat=t.videoFormat||"video/"+("ogv"===n[1]?"ogg":n[1])):e.match(/(^data:image\/[a-z0-9+\/=]*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg|ico)((\?|#).*)?$)/i)?i=_t:e.match(/\.(pdf)((\?|#).*)?$/i)&&(i="pdf")),(n=e.match(/(?:maps\.)?google\.([a-z]{2,3}(?:\.[a-z]{2})?)\/(?:(?:(?:maps\/(?:place\/(?:.*)\/)?\@(.*),(\d+.?\d+?)z))|(?:\?ll=))(.*)?/i))?(t.src=`https://maps.google.${n[1]}/?ll=${(n[2]?n[2]+"&z="+Math.floor(parseFloat(n[3]))+(n[4]?n[4].replace(/^\//,"&"):""):n[4]+"").replace(/\?/,"&")}&output=${n[4]&&n[4].indexOf("layer=c")>0?"svembed":"embed"}`,i=wt):(n=e.match(/(?:maps\.)?google\.([a-z]{2,3}(?:\.[a-z]{2})?)\/(?:maps\/search\/)(.*)/i))&&(t.src=`https://maps.google.${n[1]}/maps?q=${n[2].replace("query=","q=").replace("api=1","")}&output=embed`,i=wt),i=i||this.instance.option("defaultType"),t.type=i,i===_t&&(t.thumbSrc=t.thumbSrc||t.src)}setContent(t){const e=this.instance.optionFor(t,"src")||"";if(t&&t.type&&e){switch(t.type){case yt:this.instance.setContent(t,e);break;case Tt:const i=this.option("videoTpl");i&&this.instance.setContent(t,i.replace(/\{\{src\}\}/gi,e+"").replace(/\{\{format\}\}/gi,this.optionFor(t,"videoFormat")||"").replace(/\{\{poster\}\}/gi,t.poster||t.thumbSrc||""));break;case"inline":case"clone":this.setInlineContent(t);break;case"ajax":this.loadAjaxContent(t);break;case"pdf":case wt:case xt:case St:t.preload=!1;case"iframe":this.setIframeContent(t)}this.setAspectRatio(t)}}setAspectRatio(t){const e=t.contentEl;if(!(t.el&&e&&t.type&&[xt,St,Tt].includes(t.type)))return;let i,n=t.width||"auto",s=t.height||"auto";if("auto"===n||"auto"===s){i=this.optionFor(t,"videoRatio");const e=(i+"").match(/(\d+)\s*\/\s?(\d+)/);i=e&&e.length>2?parseFloat(e[1])/parseFloat(e[2]):parseFloat(i+"")}else n&&s&&(i=n/s);if(!i)return;e.style.aspectRatio="",e.style.width="",e.style.height="",e.offsetHeight;const r=e.getBoundingClientRect(),o=r.width||1,a=r.height||1;e.style.aspectRatio=i+"",i<o/a?(s="auto"===s?a:Math.min(a,s),e.style.width="auto",e.style.height=`${s}px`):(n="auto"===n?o:Math.min(o,n),e.style.width=`${n}px`,e.style.height="auto")}attach(){const t=this,e=t.instance;e.on("Carousel.beforeInitSlide",t.onBeforeInitSlide),e.on("Carousel.createSlide",t.onCreateSlide),e.on("Carousel.selectSlide",t.onSelectSlide),e.on("Carousel.unselectSlide",t.onUnselectSlide),e.on("Carousel.Panzoom.refresh",t.onRefresh),e.on("done",t.onDone),e.on("clearContent",t.onClearContent),window.addEventListener("message",t.onMessage)}detach(){const t=this,e=t.instance;e.off("Carousel.beforeInitSlide",t.onBeforeInitSlide),e.off("Carousel.createSlide",t.onCreateSlide),e.off("Carousel.selectSlide",t.onSelectSlide),e.off("Carousel.unselectSlide",t.onUnselectSlide),e.off("Carousel.Panzoom.refresh",t.onRefresh),e.off("done",t.onDone),e.off("clearContent",t.onClearContent),window.removeEventListener("message",t.onMessage)}}Object.defineProperty(Ct,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{ajax:null,autoSize:!0,iframeAttr:{allow:"autoplay; fullscreen",scrolling:"auto"},preload:!0,videoAutoplay:!0,videoRatio:16/9,videoTpl:'<video class="fancybox__html5video" playsinline controls controlsList="nodownload" poster="{{poster}}">\n  <source src="{{src}}" type="{{format}}" />Sorry, your browser doesn\'t support embedded videos.</video>',videoFormat:"",vimeo:{byline:1,color:"00adef",controls:1,dnt:1,muted:0},youtube:{controls:1,enablejsapi:1,nocookie:1,rel:0,fs:1}}});const Pt="play",Ot="pause",kt="ready";class At extends j{constructor(){super(...arguments),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:kt}),Object.defineProperty(this,"inHover",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"timer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"progressBar",{enumerable:!0,configurable:!0,writable:!0,value:null})}get isActive(){return this.state!==kt}onReady(t){this.option("autoStart")&&(t.isInfinite||t.page<t.pages.length-1)&&this.start()}onChange(){this.removeProgressBar(),this.pause()}onSettle(){this.resume()}onVisibilityChange(){"visible"===document.visibilityState?this.resume():this.pause()}onMouseEnter(){this.inHover=!0,this.pause()}onMouseLeave(){var t;this.inHover=!1,(null===(t=this.instance.panzoom)||void 0===t?void 0:t.isResting)&&this.resume()}onTimerEnd(){const t=this.instance;"play"===this.state&&(t.isInfinite||t.page!==t.pages.length-1?t.slideNext():t.slideTo(0))}removeProgressBar(){this.progressBar&&(this.progressBar.remove(),this.progressBar=null)}createProgressBar(){var t;if(!this.option("showProgress"))return null;this.removeProgressBar();const e=this.instance,i=(null===(t=e.pages[e.page])||void 0===t?void 0:t.slides)||[];let n=this.option("progressParentEl");if(n||(n=(1===i.length?i[0].el:null)||e.viewport),!n)return null;const s=document.createElement("div");return E(s,"f-progress"),n.prepend(s),this.progressBar=s,s.offsetHeight,s}set(){const t=this,e=t.instance;if(e.pages.length<2)return;if(t.timer)return;const i=t.option("timeout");t.state=Pt,E(e.container,"has-autoplay");let n=t.createProgressBar();n&&(n.style.transitionDuration=`${i}ms`,n.style.transform="scaleX(1)"),t.timer=setTimeout((()=>{t.timer=null,t.inHover||t.onTimerEnd()}),i),t.emit("set")}clear(){const t=this;t.timer&&(clearTimeout(t.timer),t.timer=null),t.removeProgressBar()}start(){const t=this;if(t.set(),t.state!==kt){if(t.option("pauseOnHover")){const e=t.instance.container;e.addEventListener("mouseenter",t.onMouseEnter,!1),e.addEventListener("mouseleave",t.onMouseLeave,!1)}document.addEventListener("visibilitychange",t.onVisibilityChange,!1),t.emit("start")}}stop(){const t=this,e=t.state,i=t.instance.container;t.clear(),t.state=kt,i.removeEventListener("mouseenter",t.onMouseEnter,!1),i.removeEventListener("mouseleave",t.onMouseLeave,!1),document.removeEventListener("visibilitychange",t.onVisibilityChange,!1),T(i,"has-autoplay"),e!==kt&&t.emit("stop")}pause(){const t=this;t.state===Pt&&(t.state=Ot,t.clear(),t.emit(Ot))}resume(){const t=this,e=t.instance;if(e.isInfinite||e.page!==e.pages.length-1)if(t.state!==Pt){if(t.state===Ot&&!t.inHover){const e=new Event("resume",{bubbles:!0,cancelable:!0});t.emit("resume",e),e.defaultPrevented||t.set()}}else t.set();else t.stop()}toggle(){this.state===Pt||this.state===Ot?this.stop():this.start()}attach(){const t=this,e=t.instance;
vendor: 11,833 bytes, line 4
4e.on("ready",t.onReady),e.on("Panzoom.startAnimation",t.onChange),e.on("Panzoom.endAnimation",t.onSettle),e.on("Panzoom.touchMove",t.onChange)}detach(){const t=this,e=t.instance;e.off("ready",t.onReady),e.off("Panzoom.startAnimation",t.onChange),e.off("Panzoom.endAnimation",t.onSettle),e.off("Panzoom.touchMove",t.onChange),t.stop()}}Object.defineProperty(At,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{autoStart:!0,pauseOnHover:!0,progressParentEl:null,showProgress:!0,timeout:3e3}});class Lt extends j{constructor(){super(...arguments),Object.defineProperty(this,"ref",{enumerable:!0,configurable:!0,writable:!0,value:null})}onPrepare(t){const e=t.carousel;if(!e)return;const i=t.container;i&&(e.options.Autoplay=f({autoStart:!1},this.option("Autoplay")||{},{pauseOnHover:!1,timeout:this.option("timeout"),progressParentEl:()=>this.option("progressParentEl")||null,on:{start:()=>{t.emit("startSlideshow")},set:e=>{var n;i.classList.add("has-slideshow"),(null===(n=t.getSlide())||void 0===n?void 0:n.state)!==ot.Ready&&e.pause()},stop:()=>{i.classList.remove("has-slideshow"),t.isCompact||t.endIdle(),t.emit("endSlideshow")},resume:(e,i)=>{var n,s,r;!i||!i.cancelable||(null===(n=t.getSlide())||void 0===n?void 0:n.state)===ot.Ready&&(null===(r=null===(s=t.carousel)||void 0===s?void 0:s.panzoom)||void 0===r?void 0:r.isResting)||i.preventDefault()}}}),e.attachPlugins({Autoplay:At}),this.ref=e.plugins.Autoplay)}onReady(t){const e=t.carousel,i=this.ref;i&&e&&this.option("playOnStart")&&(e.isInfinite||e.page<e.pages.length-1)&&i.start()}onDone(t,e){const i=this.ref,n=t.carousel;if(!i||!n)return;const s=e.panzoom;s&&s.on("startAnimation",(()=>{t.isCurrentSlide(e)&&i.stop()})),t.isCurrentSlide(e)&&i.resume()}onKeydown(t,e){var i;const n=this.ref;n&&e===this.option("key")&&"BUTTON"!==(null===(i=document.activeElement)||void 0===i?void 0:i.nodeName)&&n.toggle()}attach(){const t=this,e=t.instance;e.on("Carousel.init",t.onPrepare),e.on("Carousel.ready",t.onReady),e.on("done",t.onDone),e.on("keydown",t.onKeydown)}detach(){const t=this,e=t.instance;e.off("Carousel.init",t.onPrepare),e.off("Carousel.ready",t.onReady),e.off("done",t.onDone),e.off("keydown",t.onKeydown)}}Object.defineProperty(Lt,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{key:" ",playOnStart:!1,progressParentEl:t=>{var e;return(null===(e=t.instance.container)||void 0===e?void 0:e.querySelector(".fancybox__toolbar [data-fancybox-toggle-slideshow]"))||t.instance.container},timeout:3e3}});const Rt={classes:{container:"f-thumbs f-carousel__thumbs",viewport:"f-thumbs__viewport",track:"f-thumbs__track",slide:"f-thumbs__slide",isResting:"is-resting",isSelected:"is-selected",isLoading:"is-loading",hasThumbs:"has-thumbs"},minCount:2,parentEl:null,thumbTpl:'<button class="f-thumbs__slide__button" tabindex="0" type="button" aria-label="{{GOTO}}" data-carousel-index="%i"><img class="f-thumbs__slide__img" data-lazy-src="{{%s}}" alt="" /></button>',type:"modern"};var zt;!function(t){t[t.Init=0]="Init",t[t.Ready=1]="Ready",t[t.Hidden=2]="Hidden"}(zt||(zt={}));const Dt="isResting",It="thumbWidth",Ft="thumbHeight",Bt="thumbClipWidth";let Nt=class extends j{constructor(){super(...arguments),Object.defineProperty(this,"type",{enumerable:!0,configurable:!0,writable:!0,value:"modern"}),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"track",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"carousel",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"thumbWidth",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"thumbClipWidth",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"thumbHeight",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"thumbGap",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"thumbExtraGap",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:zt.Init})}get isModern(){return"modern"===this.type}onInitSlide(t,e){const i=e.el?e.el.dataset:void 0;i&&(e.thumbSrc=i.thumbSrc||e.thumbSrc||"",e[Bt]=parseFloat(i[Bt]||"")||e[Bt]||0,e[Ft]=parseFloat(i.thumbHeight||"")||e[Ft]||0),this.addSlide(e)}onInitSlides(){this.build()}onChange(){var t;if(!this.isModern)return;const e=this.container,i=this.instance,n=i.panzoom,s=this.carousel,r=s?s.panzoom:null,a=i.page;if(n&&s&&r){if(n.isDragging){T(e,this.cn(Dt));let n=(null===(t=s.pages[a])||void 0===t?void 0:t.pos)||0;n+=i.getProgress(a)*(this[Bt]+this.thumbGap);let o=r.getBounds();-1*n>o.x.min&&-1*n<o.x.max&&r.panTo({x:-1*n,friction:.12})}else o(e,this.cn(Dt),n.isResting);this.shiftModern()}}onRefresh(){this.updateProps();for(const t of this.instance.slides||[])this.resizeModernSlide(t);this.shiftModern()}isDisabled(){const t=this.option("minCount")||0;if(t){const e=this.instance;let i=0;for(const t of e.slides||[])t.thumbSrc&&i++;if(i<t)return!0}const e=this.option("type");return["modern","classic"].indexOf(e)<0}getThumb(t){const e=this.option("thumbTpl")||"";return{html:this.instance.localize(e,[["%i",t.index],["%d",t.index+1],["%s",t.thumbSrc||"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"]])}}addSlide(t){const e=this.carousel;e&&e.addSlide(t.index,this.getThumb(t))}getSlides(){const t=[];for(const e of this.instance.slides||[])t.push(this.getThumb(e));return t}resizeModernSlide(t){this.isModern&&(t[It]=t[Bt]&&t[Ft]?Math.round(this[Ft]*(t[Bt]/t[Ft])):this[It])}updateProps(){const t=this.container;if(!t)return;const e=e=>parseFloat(getComputedStyle(t).getPropertyValue("--f-thumb-"+e))||0;this.thumbGap=e("gap"),this.thumbExtraGap=e("extra-gap"),this[It]=e("width")||40,this[Bt]=e("clip-width")||40,this[Ft]=e("height")||40}build(){const t=this;if(t.state!==zt.Init)return;if(t.isDisabled())return void t.emit("disabled");const e=t.instance,i=e.container,n=t.getSlides(),s=t.option("type");t.type=s;const r=t.option("parentEl"),o=t.cn("container"),a=t.cn("track");let l=null==r?void 0:r.querySelector("."+o);l||(l=document.createElement("div"),E(l,o),r?r.appendChild(l):i.after(l)),E(l,`is-${s}`),E(i,t.cn("hasThumbs")),t.container=l,t.updateProps();let c=l.querySelector("."+a);c||(c=document.createElement("div"),E(c,t.cn("track")),l.appendChild(c)),t.track=c;const h=f({},{track:c,infinite:!1,center:!0,fill:"classic"===s,dragFree:!0,slidesPerPage:1,transition:!1,preload:.25,friction:.12,Panzoom:{maxVelocity:0},Dots:!1,Navigation:!1,classes:{container:"f-thumbs",viewport:"f-thumbs__viewport",track:"f-thumbs__track",slide:"f-thumbs__slide"}},t.option("Carousel")||{},{Sync:{target:e},slides:n}),u=new e.constructor(l,h);u.on("createSlide",((e,i)=>{t.setProps(i.index),t.emit("createSlide",i,i.el)})),u.on("ready",(()=>{t.shiftModern(),t.emit("ready")})),u.on("refresh",(()=>{t.shiftModern()})),u.on("Panzoom.click",((e,i,n)=>{t.onClick(n)})),t.carousel=u,t.state=zt.Ready}onClick(t){t.preventDefault(),t.stopPropagation();const e=this.instance,{pages:i,page:n}=e,s=t=>{if(t){const e=t.closest("[data-carousel-index]");if(e)return[parseInt(e.dataset.carouselIndex||"",10)||0,e]}return[-1,void 0]},r=(t,e)=>{const i=document.elementFromPoint(t,e);return i?s(i):[-1,void 0]};let[o,a]=s(t.target);if(o>-1)return;const l=this[Bt],c=t.clientX,h=t.clientY;let[u,d]=r(c-l,h),[f,p]=r(c+l,h);d&&p?(o=Math.abs(c-d.getBoundingClientRect().right)<Math.abs(c-p.getBoundingClientRect().left)?u:f,o===n&&(o=o===u?f:u)):d?o=u:p&&(o=f),o>-1&&i[o]&&e.slideTo(o)}getShift(t){var e;const i=this,{instance:n}=i,s=i.carousel;if(!n||!s)return 0;const r=i[It],o=i[Bt],a=i.thumbGap,l=i.thumbExtraGap;if(!(null===(e=s.slides[t])||void 0===e?void 0:e.el))return 0;const c=.5*(r-o),h=n.pages.length-1;let u=n.getProgress(0),d=n.getProgress(h),f=n.getProgress(t,!1,!0),p=0,g=c+l+a;const m=u<0&&u>-1,v=d>0&&d<1;return 0===t?(p=g*Math.abs(u),v&&1===u&&(p-=g*Math.abs(d))):t===h?(p=g*Math.abs(d)*-1,m&&-1===d&&(p+=g*Math.abs(u))):m||v?(p=-1*g,p+=g*Math.abs(u),p+=g*(1-Math.abs(d))):p=g*f,p}setProps(e){var i;const n=this;if(!n.isModern)return;const{instance:s}=n,r=n.carousel;if(s&&r){const o=null===(i=r.slides[e])||void 0===i?void 0:i.el;if(o&&o.childNodes.length){let i=t(1-Math.abs(s.getProgress(e))),r=t(n.getShift(e));o.style.setProperty("--progress",i?i+"":""),o.style.setProperty("--shift",r+"")}}}shiftModern(){const t=this;if(!t.isModern)return;const{instance:e,track:i}=t,n=e.panzoom,s=t.carousel;if(!(e&&i&&n&&s))return;if(n.state===v.Init||n.state===v.Destroy)return;for(const i of e.slides)t.setProps(i.index);let r=(t[Bt]+t.thumbGap)*(s.slides.length||0);i.style.setProperty("--width",r+"")}cleanup(){const t=this;t.carousel&&t.carousel.destroy(),t.carousel=null,t.container&&t.container.remove(),t.container=null,t.track&&t.track.remove(),t.track=null,t.state=zt.Init,T(t.instance.container,t.cn("hasThumbs"))}attach(){const t=this,e=t.instance;e.on("initSlide",t.onInitSlide),e.state===F.Init?e.on("initSlides",t.onInitSlides):t.onInitSlides(),e.on(["change","Panzoom.afterTransform"],t.onChange),e.on("Panzoom.refresh",t.onRefresh)}detach(){const t=this,e=t.instance;e.off("initSlide",t.onInitSlide),e.off("initSlides",t.onInitSlides),e.off(["change","Panzoom.afterTransform"],t.onChange),e.off("Panzoom.refresh",t.onRefresh),t.cleanup()}};Object.defineProperty(Nt,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:Rt});const jt=Object.assign(Object.assign({},Rt),{key:"t",showOnStart:!0,parentEl:null}),Ht="is-masked",Yt="aria-hidden";class qt extends j{constructor(){super(...arguments),Object.defineProperty(this,"ref",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"hidden",{enumerable:!0,configurable:!0,writable:!0,value:!1})}get isEnabled(){const t=this.ref;return t&&!t.isDisabled()}get isHidden(){return this.hidden}onClick(t,e){e.stopPropagation()}onCreateSlide(t,e){var i,n,s;const r=(null===(s=null===(n=null===(i=this.instance)||void 0===i?void 0:i.carousel)||void 0===n?void 0:n.slides[e.index])||void 0===s?void 0:s.type)||"",o=e.el;if(o&&r){let t=`for-${r}`;["video","youtube","vimeo","html5video"].includes(r)&&(t+=" for-video"),E(o,t)}}onInit(){var t;const e=this,i=e.instance,n=i.carousel;if(e.ref||!n)return;const s=e.option("parentEl")||i.footer||i.container;if(!s)return;const r=f({},e.options,{parentEl:s,classes:{container:"f-thumbs fancybox__thumbs"},Carousel:{Sync:{friction:i.option("Carousel.friction")||0}},on:{ready:t=>{const i=t.container;i&&this.hidden&&(e.refresh(),i.style.transition="none",e.hide(),i.offsetHeight,queueMicrotask((()=>{i.style.transition="",e.show()})))}}});r.Carousel=r.Carousel||{},r.Carousel.on=f((null===(t=e.options.Carousel)||void 0===t?void 0:t.on)||{},{click:this.onClick,createSlide:this.onCreateSlide}),n.options.Thumbs=r,n.attachPlugins({Thumbs:Nt}),e.ref=n.plugins.Thumbs,e.option("showOnStart")||(e.ref.state=zt.Hidden,e.hidden=!0)}onResize(){var t;const e=null===(t=this.ref)||void 0===t?void 0:t.container;e&&(e.style.maxHeight="")}onKeydown(t,e){const i=this.option("key");i&&i===e&&this.toggle()}toggle(){const t=this.ref;if(t&&!t.isDisabled())return t.state===zt.Hidden?(t.state=zt.Init,void t.build()):void(this.hidden?this.show():this.hide())}show(){const t=this.ref;if(!t||t.isDisabled())return;const e=t.container;e&&(this.refresh(),e.offsetHeight,e.removeAttribute(Yt),e.classList.remove(Ht),this.hidden=!1)}hide(){const t=this.ref,e=t&&t.container;e&&(this.refresh(),e.offsetHeight,e.classList.add(Ht),e.setAttribute(Yt,"true")),this.hidden=!0}refresh(){const t=this.ref;if(!t||!t.state)return;const e=t.container,i=(null==e?void 0:e.firstChild)||null;e&&i&&i.childNodes.length&&(e.style.maxHeight=`${i.getBoundingClientRect().height}px`)}
vendor: 4,390 bytes, line 4
4attach(){const t=this,e=t.instance;e.state===rt.Init?e.on("Carousel.init",t.onInit):t.onInit(),e.on("resize",t.onResize),e.on("keydown",t.onKeydown)}detach(){var t;const e=this,i=e.instance;i.off("Carousel.init",e.onInit),i.off("resize",e.onResize),i.off("keydown",e.onKeydown),null===(t=i.carousel)||void 0===t||t.detachPlugins(["Thumbs"]),e.ref=null}}Object.defineProperty(qt,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:jt});const Xt={panLeft:{icon:'<svg><path d="M5 12h14M5 12l6 6M5 12l6-6"/></svg>',change:{panX:-100}},panRight:{icon:'<svg><path d="M5 12h14M13 18l6-6M13 6l6 6"/></svg>',change:{panX:100}},panUp:{icon:'<svg><path d="M12 5v14M18 11l-6-6M6 11l6-6"/></svg>',change:{panY:-100}},panDown:{icon:'<svg><path d="M12 5v14M18 13l-6 6M6 13l6 6"/></svg>',change:{panY:100}},zoomIn:{icon:'<svg><circle cx="11" cy="11" r="7.5"/><path d="m21 21-4.35-4.35M11 8v6M8 11h6"/></svg>',action:"zoomIn"},zoomOut:{icon:'<svg><circle cx="11" cy="11" r="7.5"/><path d="m21 21-4.35-4.35M8 11h6"/></svg>',action:"zoomOut"},toggle1to1:{icon:'<svg><path d="M3.51 3.07c5.74.02 11.48-.02 17.22.02 1.37.1 2.34 1.64 2.18 3.13 0 4.08.02 8.16 0 12.23-.1 1.54-1.47 2.64-2.79 2.46-5.61-.01-11.24.02-16.86-.01-1.36-.12-2.33-1.65-2.17-3.14 0-4.07-.02-8.16 0-12.23.1-1.36 1.22-2.48 2.42-2.46Z"/><path d="M5.65 8.54h1.49v6.92m8.94-6.92h1.49v6.92M11.5 9.4v.02m0 5.18v0"/></svg>',action:"toggleZoom"},toggleZoom:{icon:'<svg><g><line x1="11" y1="8" x2="11" y2="14"></line></g><circle cx="11" cy="11" r="7.5"/><path d="m21 21-4.35-4.35M8 11h6"/></svg>',action:"toggleZoom"},iterateZoom:{icon:'<svg><g><line x1="11" y1="8" x2="11" y2="14"></line></g><circle cx="11" cy="11" r="7.5"/><path d="m21 21-4.35-4.35M8 11h6"/></svg>',action:"iterateZoom"},rotateCCW:{icon:'<svg><path d="M15 4.55a8 8 0 0 0-6 14.9M9 15v5H4M18.37 7.16v.01M13 19.94v.01M16.84 18.37v.01M19.37 15.1v.01M19.94 11v.01"/></svg>',action:"rotateCCW"},rotateCW:{icon:'<svg><path d="M9 4.55a8 8 0 0 1 6 14.9M15 15v5h5M5.63 7.16v.01M4.06 11v.01M4.63 15.1v.01M7.16 18.37v.01M11 19.94v.01"/></svg>',action:"rotateCW"},flipX:{icon:'<svg style="stroke-width: 1.3"><path d="M12 3v18M16 7v10h5L16 7M8 7v10H3L8 7"/></svg>',action:"flipX"},flipY:{icon:'<svg style="stroke-width: 1.3"><path d="M3 12h18M7 16h10L7 21v-5M7 8h10L7 3v5"/></svg>',action:"flipY"},fitX:{icon:'<svg><path d="M4 12V6a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v6M10 18H3M21 18h-7M6 15l-3 3 3 3M18 15l3 3-3 3"/></svg>',action:"fitX"},fitY:{icon:'<svg><path d="M12 20H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h6M18 14v7M18 3v7M15 18l3 3 3-3M15 6l3-3 3 3"/></svg>',action:"fitY"},reset:{icon:'<svg><path d="M20 11A8.1 8.1 0 0 0 4.5 9M4 5v4h4M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4"/></svg>',action:"reset"},toggleFS:{icon:'<svg><g><path d="M14.5 9.5 21 3m0 0h-6m6 0v6M3 21l6.5-6.5M3 21v-6m0 6h6"/></g><g><path d="m14 10 7-7m-7 7h6m-6 0V4M3 21l7-7m0 0v6m0-6H4"/></g></svg>',action:"toggleFS"}};var Wt;!function(t){t[t.Init=0]="Init",t[t.Ready=1]="Ready",t[t.Disabled=2]="Disabled"}(Wt||(Wt={}));const $t={tabindex:"-1",width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Vt="has-toolbar",Ut="fancybox__toolbar";class Zt extends j{constructor(){super(...arguments),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:Wt.Init}),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:null})}onReady(t){var e;if(!t.carousel)return;let i=this.option("display"),n=this.option("absolute"),s=this.option("enabled");if("auto"===s){const t=this.instance.carousel;let e=0;if(t)for(const i of t.slides)(i.panzoom||"image"===i.type)&&e++;e||(s=!1)}s||(i=void 0);let r=0;const o={left:[],middle:[],right:[]};if(i)for(const t of["left","middle","right"])for(const n of i[t]){const i=this.createEl(n);i&&(null===(e=o[t])||void 0===e||e.push(i),r++)}let a=null;if(r&&(a=this.createContainer()),a){for(const[t,e]of Object.entries(o)){const i=document.createElement("div");E(i,Ut+"__column is-"+t);for(const t of e)i.appendChild(t);"auto"!==n||"middle"!==t||e.length||(n=!0),a.appendChild(i)}!0===n&&E(a,"is-absolute"),this.state=Wt.Ready,this.onRefresh()}else this.state=Wt.Disabled}onClick(t){var e,i;const n=this.instance,s=n.getSlide(),r=null==s?void 0:s.panzoom,o=t.target,a=o&&S(o)?o.dataset:null;if(!a)return;if(void 0!==a.fancyboxToggleThumbs)return t.preventDefault(),t.stopPropagation(),void(null===(e=n.plugins.Thumbs
vendor: 4,826 bytes, line 4
4)||void 0===e||e.toggle());if(void 0!==a.fancyboxToggleFullscreen)return t.preventDefault(),t.stopPropagation(),void this.instance.toggleFullscreen();if(void 0!==a.fancyboxToggleSlideshow){t.preventDefault(),t.stopPropagation();const e=null===(i=n.carousel)||void 0===i?void 0:i.plugins.Autoplay;let s=e.isActive;return r&&"mousemove"===r.panMode&&!s&&r.reset(),void(s?e.stop():e.start())}const l=a.panzoomAction,c=a.panzoomChange;if((c||l)&&(t.preventDefault(),t.stopPropagation()),c){let e={};try{e=JSON.parse(c)}catch(t){}r&&r.applyChange(e)}else l&&r&&r[l]&&r[l]()}onChange(){this.onRefresh()}onRefresh(){if(this.instance.isClosing())return;const t=this.container;if(!t)return;const e=this.instance.getSlide();if(!e||e.state!==ot.Ready)return;const i=e&&!e.error&&e.panzoom;for(const e of t.querySelectorAll("[data-panzoom-action]"))i?(e.removeAttribute("disabled"),e.removeAttribute("tabindex")):(e.setAttribute("disabled",""),e.setAttribute("tabindex","-1"));let n=i&&i.canZoomIn(),s=i&&i.canZoomOut();for(const e of t.querySelectorAll('[data-panzoom-action="zoomIn"]'))n?(e.removeAttribute("disabled"),e.removeAttribute("tabindex")):(e.setAttribute("disabled",""),e.setAttribute("tabindex","-1"));for(const e of t.querySelectorAll('[data-panzoom-action="zoomOut"]'))s?(e.removeAttribute("disabled"),e.removeAttribute("tabindex")):(e.setAttribute("disabled",""),e.setAttribute("tabindex","-1"));for(const e of t.querySelectorAll('[data-panzoom-action="toggleZoom"],[data-panzoom-action="iterateZoom"]')){s||n?(e.removeAttribute("disabled"),e.removeAttribute("tabindex")):(e.setAttribute("disabled",""),e.setAttribute("tabindex","-1"));const t=e.querySelector("g");t&&(t.style.display=n?"":"none")}}onDone(t,e){var i;null===(i=e.panzoom)||void 0===i||i.on("afterTransform",(()=>{this.instance.isCurrentSlide(e)&&this.onRefresh()})),this.instance.isCurrentSlide(e)&&this.onRefresh()}createContainer(){const t=this.instance.container;if(!t)return null;const e=this.option("parentEl")||t;let i=e.querySelector("."+Ut);return i||(i=document.createElement("div"),E(i,Ut),e.prepend(i)),i.addEventListener("click",this.onClick,{passive:!1,capture:!0}),t&&E(t,Vt),this.container=i,i}createEl(t){const e=this.instance,i=e.carousel;if(!i)return null;if("toggleFS"===t)return null;if("fullscreen"===t&&!nt())return null;let n=null;const r=i.slides.length||0;let o=0,a=0;for(const t of i.slides)(t.panzoom||"image"===t.type)&&o++,("image"===t.type||t.downloadSrc)&&a++;if(r<2&&["infobar","prev","next"].includes(t))return n;if(void 0!==Xt[t]&&!o)return null;if("download"===t&&!a)return null;if("thumbs"===t){const t=e.plugins.Thumbs;if(!t||!t.isEnabled)return null}if("slideshow"===t&&(!i.plugins.Autoplay||r<2))return null;if(void 0!==Xt[t]){const e=Xt[t];n=document.createElement("button"),n.setAttribute("title",this.instance.localize(`{{${t.toUpperCase()}}}`)),E(n,"f-button"),e.action&&(n.dataset.panzoomAction=e.action),e.change&&(n.dataset.panzoomChange=JSON.stringify(e.change)),n.appendChild(s(this.instance.localize(e.icon)))}else{const e=(this.option("items")||[])[t];e&&(n=s(this.instance.localize(e.tpl)),"function"==typeof e.click&&n.addEventListener("click",(t=>{t.preventDefault(),t.stopPropagation(),"function"==typeof e.click&&e.click.call(this,this,t)})))}const l=null==n?void 0:n.querySelector("svg");if(l)for(const[t,e]of Object.entries($t))l.getAttribute(t)||l.setAttribute(t,String(e));return n}removeContainer(){const t=this.container;t&&t.remove(),this.container=null,this.state=Wt.Disabled;const e=this.instance.container;e&&T(e,Vt)}attach(){const t=this,e=t.instance;e.on("Carousel.initSlides",t.onReady),e.on("done",t.onDone),e.on(["reveal","Carousel.change"],t.onChange),t.onReady(t.instance)}detach(){const t=this,e=t.instance;e.off("Carousel.initSlides",t.onReady),e.off("done",t.onDone),e.off(["reveal","Carousel.change"],t.onChange),t.removeContainer()}}Object.defineProperty(Zt,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:{absolute:"auto",display:{left:["infobar"],middle:[],right:["iterateZoom","slideshow","fullscreen","thumbs","close"]},enabled:"auto",items:{infobar:{tpl:'<div class="fancybox__infobar" tabindex="-1"><span data-fancybox-current-index></span>/<span data-fancybox-count></span></div>'},download:{tpl:'<a class="f-button" title="{{DOWNLOAD}}" data-fancybox-download href="javasript:;"><svg><path d="M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2M7 11l5 5 5-5M12 4v12"/></svg></a>'},prev:{tpl:'<button class="f-button" title="{{PREV}}" data-fancybox-prev><svg><path d="m15 6-6 6 6 6"/></svg></button>'},next:{tpl:'<button class="f-button" title="{{NEXT}}" data-fancybox-next><svg><path d="m9 6 6 6-6 6"/></svg></button>'},slideshow:{tpl:'<button class="f-button" title="{{TOGGLE_SLIDESHOW}}" data-fancybox-toggle-slideshow><svg><g><path d="M8 4v16l13 -8z"></path></g><g>
4<path d="M8 4v15M17 4v15"/></g></svg></button>'},fullscreen:{tpl:'<button class="f-button" title="{{TOGGLE_FULLSCREEN}}" data-fancybox-toggle-fullscreen><svg><g><path d="M4 8V6a2 2 0 0 1 2-2h2M4 16v2a2 2 0 0 0 2 2h2M16 4h2a2 2 0 0 1 2 2v2M16 20h2a2 2 0 0 0 2-2v-2"/></g><g><path d="M15 19v-2a2 2 0 0 1 2-2h2M15 5v2a2 2 0 0 0 2 2h2M5 15h2a2 2 0 0 1 2 2v2M5 9h2a2 2 0 0 0 2-2V5"/></g></svg></button>'},thumbs:{tpl:'<button class="f-button" title="{{TOGGLE_THUMBS}}" data-fancybox-toggle-thumbs><svg><circle cx="5.5" cy="5.5" r="1"/><circle cx="12" cy="5.5" r="1"/><circle cx="18.5" cy="5.5" r="1"/><circle cx="5.5" cy="12" r="1"/><circle cx="12" cy="12" r="1"/><circle cx="18.5" cy="12" r="1"/><circle cx="5.5" cy="18.5" r="1"/><circle cx="12" cy="18.5" r="1"/><circle cx="18.5" cy="18.5" r="1"/></svg></button>'},close:{tpl:'<button class="f-button" title="{{CLOSE}}" data-fancybox-close><svg><path d="m19.5 4.5-15 15M4.5 4.5l15 15"/></svg></button>'}},parentEl:null}});const Gt={Hash:class extends j{onReady(){lt=!1}onChange(t){ht&&clearTimeout(ht);const{hash:e}=ut(),{hash:i}=dt(),n=t.isOpeningSlide(t.getSlide());n&&(at=i===e?"":i),e&&e!==i&&(ht=setTimeout((()=>{try{if(t.state===rt.Ready){let t="replaceState";n&&!ct&&(t="pushState",ct=!0),window.history[t]({},document.title,window.location.pathname+window.location.search+e)}}catch(t){}}),300))}onClose(t){if(ht&&clearTimeout(ht),!lt&&ct)return ct=!1,lt=!1,void window.history.back();if(!lt)try{window.history.replaceState({},document.title,window.location.pathname+window.location.search+(at||""))}catch(t){}}attach(){const t=this.instance;t.on("ready",this.onReady),t.on(["Carousel.ready","Carousel.change"],this.onChange),t.on("close",this.onClose)}detach(){const t=this.instance;t.off("ready",this.onReady),t.off(["Carousel.ready","Carousel.change"],this.onChange),t.off("close",this.onClose)}static parseURL(){return dt()}static startFromUrl(){ft()}static destroy(){window.removeEventListener("hashchange",gt,!1)}},Html:Ct,Images:bt,Slideshow:Lt,Thumbs:qt,Toolbar:Zt},Kt="with-fancybox",Jt="hide-scrollbar",Qt="--fancybox-scrollbar-compensate",te="--fancybox-body-margin",ee="aria-hidden",ie="is-using-tab",ne="is-animated",se="is-compact",re="is-loading",oe="is-opening",ae="has-caption",le="disabled",ce="tabindex",he="download",ue="href",de=t=>"string"==typeof t,fe=function(){var t=window.getSelection();return!!t&&"Range"===t.type};let pe,ge=null,me=null,ve=0,be=0,ye=0,_e=0;const we=new Map;let xe=0;class Se extends m{get isIdle(){return this.idle}get isCompact(){return this.option("compact")}constructor(t=[],e={},i={}){super(e),Object.defineProperty(this,"userSlides",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"userPlugins",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,"idle",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"idleTimer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"clickTimer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"pwt",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"ignoreFocusChange",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"startedFs",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"state",{enumerable:!0,configurable:!0,writable:!0,value:rt.Init}),Object.defineProperty(this,"id",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,"container",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"caption",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"footer",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"carousel",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"lastFocus",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,"prevMouseMoveEvent",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),pe||(pe=nt()),this.id=e.id||++xe,we.set(this.id,this),this.userSlides=t,this.userPlugins=i,queueMicrotask((()=>{this.init()}))}init(){if(this.state===rt.Destroy)return;this.state=rt.Init,this.attachPlugins(Object.assign(Object.assign({}
vendor: 8,970 bytes, line 4
4,Se.Plugins),this.userPlugins)),this.emit("init"),this.emit("attachPlugins"),!0===this.option("hideScrollbar")&&(()=>{if(!Q)return;const t=document,e=t.body,i=t.documentElement;if(e.classList.contains(Jt))return;let n=window.innerWidth-i.getBoundingClientRect().width;const s=parseFloat(window.getComputedStyle(e).marginRight);n<0&&(n=0),i.style.setProperty(Qt,`${n}px`),s&&e.style.setProperty(te,`${s}px`),e.classList.add(Jt)})(),this.initLayout(),this.scale();const t=()=>{this.initCarousel(this.userSlides),this.state=rt.Ready,this.attachEvents(),this.emit("ready"),setTimeout((()=>{this.container&&this.container.setAttribute(ee,"false")}),16)};this.option("Fullscreen.autoStart")&&pe&&!pe.isFullscreen()?pe.request().then((()=>{this.startedFs=!0,t()})).catch((()=>t())):t()}initLayout(){var t,e;const i=this.option("parentEl")||document.body,n=s(this.localize(this.option("tpl.main")||""));if(n){if(n.setAttribute("id",`fancybox-${this.id}`),n.setAttribute("aria-label",this.localize("{{MODAL}}")),n.classList.toggle(se,this.isCompact),E(n,this.option("mainClass")||""),E(n,oe),this.container=n,this.footer=n.querySelector(".fancybox__footer"),i.appendChild(n),E(document.documentElement,Kt),ge&&me||(ge=document.createElement("span"),E(ge,"fancybox-focus-guard"),ge.setAttribute(ce,"0"),ge.setAttribute(ee,"true"),ge.setAttribute("aria-label","Focus guard"),me=ge.cloneNode(),null===(t=n.parentElement)||void 0===t||t.insertBefore(ge,n),null===(e=n.parentElement)||void 0===e||e.append(me)),n.addEventListener("mousedown",(t=>{ve=t.pageX,be=t.pageY,T(n,ie)})),this.option("closeExisting"))for(const t of we.values())t.id!==this.id&&t.close();else this.option("animated")&&(E(n,ne),setTimeout((()=>{this.isClosing()||T(n,ne)}),350));this.emit("initLayout")}}initCarousel(t){const i=this.container;if(!i)return;const n=i.querySelector(".fancybox__carousel");if(!n)return;const s=this.carousel=new K(n,f({},{slides:t,transition:"fade",Panzoom:{lockAxis:this.option("dragToClose")?"xy":"x",infinite:!!this.option("dragToClose")&&"y"},Dots:!1,Navigation:{classes:{container:"fancybox__nav",button:"f-button",isNext:"is-next",isPrev:"is-prev"}},initialPage:this.option("startIndex"),l10n:this.option("l10n")},this.option("Carousel")||{}));s.on("*",((t,e,...i)=>{this.emit(`Carousel.${e}`,t,...i)})),s.on(["ready","change"],(()=>{this.manageCaption()})),this.on("Carousel.removeSlide",((t,e,i)=>{this.clearContent(i),i.state=void 0})),s.on("Panzoom.touchStart",(()=>{var t,e;this.isCompact||this.endIdle(),(null===(t=document.activeElement)||void 0===t?void 0:t.closest(".f-thumbs"))&&(null===(e=this.container)||void 0===e||e.focus())})),s.on("settle",(()=>{this.idleTimer||this.isCompact||!this.option("idle")||this.setIdle(),this.option("autoFocus")&&!this.isClosing&&this.checkFocus()})),this.option("dragToClose")&&(s.on("Panzoom.afterTransform",((t,i)=>{const n=this.getSlide();if(n&&e(n.el))return;const s=this.container;if(s){const t=Math.abs(i.current.f),e=t<1?"":Math.max(.5,Math.min(1,1-t/i.contentRect.fitHeight*1.5));s.style.setProperty("--fancybox-ts",e?"0s":""),s.style.setProperty("--fancybox-opacity",e+"")}})),s.on("Panzoom.touchEnd",((t,i,n)=>{var s;const r=this.getSlide();if(r&&e(r.el))return;if(i.isMobile&&document.activeElement&&-1!==["TEXTAREA","INPUT"].indexOf(null===(s=document.activeElement)||void 0===s?void 0:s.nodeName))return;const o=Math.abs(i.dragOffset.y);"y"===i.lockedAxis&&(o>=200||o>=50&&i.dragOffset.time<300)&&(n&&n.cancelable&&n.preventDefault(),this.close(n,"f-throwOut"+(i.current.f<0?"Up":"Down")))}))),s.on("change",(t=>{var e;let i=null===(e=this.getSlide())||void 0===e?void 0:e.triggerEl;if(i){const e=new CustomEvent("slideTo",{bubbles:!0,cancelable:!0,detail:t.page});i.dispatchEvent(e)}})),s.on(["refresh","change"],(t=>{const e=this.container;if(!e)return;for(const i of e.querySelectorAll("[data-fancybox-current-index]"))i.innerHTML=t.page+1;for(const i of e.querySelectorAll("[data-fancybox-count]"))i.innerHTML=t.pages.length;if(!t.isInfinite){for(const i of e.querySelectorAll("[data-fancybox-next]"))t.page<t.pages.length-1?(i.removeAttribute(le),i.removeAttribute(ce)):(i.setAttribute(le,""),i.setAttribute(ce,"-1"));for(const i of e.querySelectorAll("[data-fancybox-prev]"))t.page>0?(i.removeAttribute(le),i.removeAttribute(ce)):(i.setAttribute(le,""),i.setAttribute(ce,"-1"))}const i=this.getSlide();if(!i)return;let n=i.downloadSrc||"";n||"image"!==i.type||i.error||!de(i.src)||(n=i.src);for(const t of e.querySelectorAll("[data-fancybox-download]")){const e=i.downloadFilename;n?(t.removeAttribute(le),t.removeAttribute(ce),t.setAttribute(ue,n),t.setAttribute(he,e||n),t.setAttribute("target","_blank")):(t.setAttribute(le,""),t.setAttribute(ce,"-1"),t.removeAttribute(ue),t.removeAttribute(he))}})),this.emit("initCarousel")}attachEvents(){const t=this,e=t.container;if(!e)return;e.addEventListener("click",t.onClick,{passive:!1,capture:!1}),e.addEventListener("wheel",t.onWheel,{passive:!1,capture:!1}),document.addEventListener("keydown",t.onKeydown,{passive:!1,capture:!0}),document.addEventListener("visibilitychange",t.onVisibilityChange,!1),document.addEventListener("mousemove",t.onMousemove),t.option("trapFocus")&&document.addEventListener("focus",t.onFocus,!0),window.addEventListener("resize",t.onResize);const i=window.visualViewport;i&&(i.addEventListener("scroll",t.onResize),i.addEventListener("resize",t.onResize))}detachEvents(){const t=this,e=t.container;if(!e)return;document.removeEventListener("keydown",t.onKeydown,{passive:!1,capture:!0}),e.removeEventListener("wheel",t.onWheel,{passive:!1,capture:!1}),e.removeEventListener("click",t.onClick,{passive:!1,capture:!1}),document.removeEventListener("mousemove",t.onMousemove),window.removeEventListener("resize",t.onResize);const i=window.visualViewport;i&&(i.removeEventListener("resize",t.onResize),i.removeEventListener("scroll",t.onResize)),document.removeEventListener("visibilitychange",t.onVisibilityChange,!1),document.removeEventListener("focus",t.onFocus,!0)}scale(){const t=this.container;if(!t)return;const e=window.visualViewport,i=Math.max(1,(null==e?void 0:e.scale)||1);let n="",s="",r="";if(e&&i>1){let t=`${e.offsetLeft}px`,o=`${e.offsetTop}px`;n=e.width*i+"px",s=e.height*i+"px",r=`translate3d(${t}, ${o}, 0) scale(${1/i})`}t.style.transform=r,t.style.width=n,t.style.height=s}onClick(t){var e;const{container:i,isCompact:n}=this;if(!i||this.isClosing())return;!n&&this.option("idle")&&this.resetIdle();const s=t.composedPath()[0];if(s.closest(".fancybox-spinner")||s.closest("[data-fancybox-close]"))return t.preventDefault(),void this.close(t);if(s.closest("[data-fancybox-prev]"))return t.preventDefault(),void this.prev();if(s.closest("[data-fancybox-next]"))return t.preventDefault(),void this.next();if("click"===t.type&&0===t.detail)return;if(Math.abs(t.pageX-ve)>30||Math.abs(t.pageY-be)>30)return;const r=document.activeElement;if(fe()&&r&&i.contains(r))return;if(n&&"image"===(null===(e=this.getSlide())||void 0===e?void 0:e.type))return void(this.clickTimer?(clearTimeout(this.clickTimer),this.clickTimer=null):this.clickTimer=setTimeout((()=>{this.toggleIdle(),this.clickTimer=null}),350));if(this.emit("click",t),t.defaultPrevented)return;let o=!1;if(s.closest(".fancybox__content")){if(r){if(r.closest("[contenteditable]"))return;s.matches(et)||r.blur()}if(fe())return;o=this.option("contentClick")}else s.closest(".fancybox__carousel")&&!s.matches(et)&&(o=this.option("backdropClick"));"close"===o?(t.preventDefault(),this.close(t)):"next"===o?(t.preventDefault(),this.next()):"prev"===o&&(t.preventDefault(),this.prev())}onWheel(t){const e=t.target;let i=this.option("wheel",t);e.closest(".fancybox__thumbs")&&(i="slide");const s="slide"===i,r=[-t.deltaX||0,-t.deltaY||0,-t.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t})),o=Math.max(-1,Math.min(1,r)),a=Date.now();this.pwt&&a-this.pwt<300?s&&t.preventDefault():(this.pwt=a,this.emit("wheel",t,o),t.defaultPrevented||("close"===i?(t.preventDefault(),this.close(t)):"slide"===i&&(n(e)||(t.preventDefault(),this[o>0?"prev":"next"]()))))}onScroll(){window.scrollTo(ye,_e)}onKeydown(t){if(!this.isTopmost())return;this.isCompact||!this.option("idle")||this.isClosing()||this.resetIdle();const e=t.key,i=this.option("keyboard");if(!i)return;const n=t.composedPath()[0],s=document.activeElement&&document.activeElement.classList,r=s&&s.contains("f-button")||n.dataset.carouselPage||n.dataset.carouselIndex;if("Escape"!==e&&!r&&S(n)&&(n.isContentEditable||-1!==["TEXTAREA","OPTION","INPUT","SELECT","VIDEO"].indexOf(n.nodeName)))return;if("Tab"===t.key?E(this.container,ie):T(this.container,ie),t.ctrlKey||t.altKey||t.shiftKey)return;this.emit("keydown",e,t);const o=i[e];o&&"function"==typeof this[o]&&(t.preventDefault(),this[o]())}onResize(){const t=this.container;if(!t)return;const e=this.isCompact;t.classList.toggle(se,e),this.manageCaption(this.getSlide()),this.isCompact?this.clearIdle():this.endIdle(),this.scale(),this.emit
vendor: 4,438 bytes, line 4
4("resize")}onFocus(t){this.isTopmost()&&this.checkFocus(t)}onMousemove(t){this.prevMouseMoveEvent=t,!this.isCompact&&this.option("idle")&&this.resetIdle()}onVisibilityChange(){"visible"===document.visibilityState?this.checkFocus():this.endIdle()}manageCloseBtn(t){const e=this.optionFor(t,"closeButton")||!1;if("auto"===e){const t=this.plugins.Toolbar;if(t&&t.state===Wt.Ready)return}if(!e)return;if(!t.contentEl||t.closeBtnEl)return;const i=this.option("tpl.closeButton");if(i){const e=s(this.localize(i));t.closeBtnEl=t.contentEl.appendChild(e),t.el&&E(t.el,"has-close-btn")}}manageCaption(t){var e,i;const n="fancybox__caption",s=this.container;if(!s)return;T(s,ae);const r=this.isCompact||this.option("commonCaption"),o=!r;if(this.caption&&this.stop(this.caption),o&&this.caption&&(this.caption.remove(),this.caption=null),r&&!this.caption)for(const t of(null===(e=this.carousel)||void 0===e?void 0:e.slides)||[])t.captionEl&&(t.captionEl.remove(),t.captionEl=void 0,T(t.el,ae),null===(i=t.el)||void 0===i||i.removeAttribute("aria-labelledby"));if(t||(t=this.getSlide()),!t||r&&!this.isCurrentSlide(t))return;const a=t.el;let l=this.optionFor(t,"caption","");if(!l)return void(r&&this.caption&&this.animate(this.caption,"f-fadeOut",(()=>{this.caption&&(this.caption.innerHTML="")})));let c=null;if(o){if(c=t.captionEl||null,a&&!c){const e=`fancybox__caption_${this.id}_${t.index}`;c=document.createElement("div"),E(c,n),c.setAttribute("id",e),t.captionEl=a.appendChild(c),E(a,ae),a.setAttribute("aria-labelledby",e)}}else c=this.caption,c||(c=s.querySelector("."+n)),c||(c=document.createElement("div"),c.dataset.fancyboxCaption="",E(c,n),(this.footer||s).prepend(c)),E(s,ae),this.caption=c;c&&(c.innerHTML="",de(l)||"number"==typeof l?c.innerHTML=l+"":l instanceof HTMLElement&&c.appendChild(l))}checkFocus(t){this.focus(t)}focus(t){var e;if(this.ignoreFocusChange)return;const i=document.activeElement||null,n=(null==t?void 0:t.target)||null,s=this.container,r=null===(e=this.carousel)||void 0===e?void 0:e.viewport;if(!s||!r)return;if(!t&&i&&s.contains(i))return;const o=this.getSlide(),a=o&&o.state===ot.Ready?o.el:null;if(!a||a.contains(i)||s===i)return;t&&t.cancelable&&t.preventDefault(),this.ignoreFocusChange=!0;const l=Array.from(s.querySelectorAll(et));let c=[],h=null;for(let t of l){const e=!t.offsetParent||!!t.closest('[aria-hidden="true"]'),i=a&&a.contains(t),n=!r.contains(t);if(t===s||(i||n)&&!e){c.push(t);const e=t.dataset.origTabindex;void 0!==e&&e&&(t.tabIndex=parseFloat(e)),t.removeAttribute("data-orig-tabindex"),!t.hasAttribute("autoFocus")&&h||(h=t)}else{const e=void 0===t.dataset.origTabindex?t.getAttribute("tabindex")||"":t.dataset.origTabindex;e&&(t.dataset.origTabindex=e),t.tabIndex=-1}}let u=null;t?(!n||c.indexOf(n)<0)&&(u=h||s,c.length&&(i===me?u=c[0]:this.lastFocus!==s&&i!==ge||(u=c[c.length-1]))):u=o&&"image"===o.type?s:h||s,u&&it(u),this.lastFocus=document.activeElement,this.ignoreFocusChange=!1}next(){const t=this.carousel;t&&t.pages.length>1&&t.slideNext()}prev(){const t=this.carousel;t&&t.pages.length>1&&t.slidePrev()}jumpTo(...t){this.carousel&&this.carousel.slideTo(...t)}isTopmost(){var t;return(null===(t=Se.getInstance())||void 0===t?void 0:t.id)==this.id}animate(t=null,e="",i){if(!t||!e)return void(i&&i());this.stop(t);const n=s=>{s.target===t&&t.dataset.animationName&&(t.removeEventListener("animationend",n),delete t.dataset.animationName,i&&i(),T(t,e))};t.dataset.animationName=e,t.addEventListener("animationend",n),E(t,e)}stop(t){t&&t.dispatchEvent(new CustomEvent("animationend",{bubbles:!1,cancelable:!0,currentTarget:t}))}setContent(t,e="",i=!0){if(this.isClosing())return;const n=t.el;if(!n)return;let r=null;if(S(e)?r=e:(r=s(e+""),S(r)||(r=document.createElement("div"),r.innerHTML=e+"")),["img","picture","iframe","video","audio"].includes(r.nodeName.toLowerCase())){const t=document.createElement("div");t.appendChild(r),r=t}S(r)&&t.filter&&!t.error&&(r=r.querySelector(t.filter)),r&&S(r)?(E(r,"fancybox__content"),t.id&&r.setAttribute("id",t.id),n.classList.add(`has-${t.error?"error":t.type||"unknown"}`),n.prepend(r),"none"===r.style.display&&(r.style.display=""),"none"===getComputedStyle(r).getPropertyValue("display")&&(r.style.display=t.display||this.option("defaultDisplay")||"flex"),t.contentEl=r,i&&this.revealContent(t),this.manageCloseBtn(t),this.manageCaption(t)):this.setError(t,"{{ELEMENT_NOT_FOUND}}")}revealContent(t,e){const i=t.el,n=t.contentEl;
vendor: 5,875 bytes, line 4
4i&&n&&(this.emit("reveal",t),this.hideLoading(t),t.state=ot.Opening,(e=this.isOpeningSlide(t)?void 0===e?this.optionFor(t,"showClass"):e:"f-fadeIn")?this.animate(n,e,(()=>{this.done(t)})):this.done(t))}done(t){this.isClosing()||(t.state=ot.Ready,this.emit("done",t),E(t.el,"is-done"),this.isCurrentSlide(t)&&this.option("autoFocus")&&queueMicrotask((()=>{var e;null===(e=t.panzoom)||void 0===e||e.updateControls(),this.option("autoFocus")&&this.focus()})),this.isOpeningSlide(t)&&(T(this.container,oe),!this.isCompact&&this.option("idle")&&this.setIdle()))}isCurrentSlide(t){const e=this.getSlide();return!(!t||!e)&&e.index===t.index}isOpeningSlide(t){var e,i;return null===(null===(e=this.carousel)||void 0===e?void 0:e.prevPage)&&t&&t.index===(null===(i=this.getSlide())||void 0===i?void 0:i.index)}showLoading(t){t.state=ot.Loading;const e=t.el;e&&(E(e,re),this.emit("loading",t),t.spinnerEl||setTimeout((()=>{if(!this.isClosing()&&!t.spinnerEl&&t.state===ot.Loading){let i=s(x);E(i,"fancybox-spinner"),t.spinnerEl=i,e.prepend(i),this.animate(i,"f-fadeIn")}}),250))}hideLoading(t){const e=t.el;if(!e)return;const i=t.spinnerEl;this.isClosing()?null==i||i.remove():(T(e,re),i&&this.animate(i,"f-fadeOut",(()=>{i.remove()})),t.state===ot.Loading&&(this.emit("loaded",t),t.state=ot.Ready))}setError(t,e){if(this.isClosing())return;const i=new Event("error",{bubbles:!0,cancelable:!0});if(this.emit("error",i,t),i.defaultPrevented)return;t.error=e,this.hideLoading(t),this.clearContent(t);const n=document.createElement("div");n.classList.add("fancybox-error"),n.innerHTML=this.localize(e||"<p>{{ERROR}}</p>"),this.setContent(t,n)}clearContent(t){if(void 0===t.state)return;this.emit("clearContent",t),t.contentEl&&(t.contentEl.remove(),t.contentEl=void 0);const e=t.el;e&&(T(e,"has-error"),T(e,"has-unknown"),T(e,`has-${t.type||"unknown"}`)),t.closeBtnEl&&t.closeBtnEl.remove(),t.closeBtnEl=void 0,t.captionEl&&t.captionEl.remove(),t.captionEl=void 0,t.spinnerEl&&t.spinnerEl.remove(),t.spinnerEl=void 0}getSlide(){var t;const e=this.carousel;return(null===(t=null==e?void 0:e.pages[null==e?void 0:e.page])||void 0===t?void 0:t.slides[0])||void 0}close(t,e){if(this.isClosing())return;const i=new Event("shouldClose",{bubbles:!0,cancelable:!0});if(this.emit("shouldClose",i,t),i.defaultPrevented)return;t&&t.cancelable&&(t.preventDefault(),t.stopPropagation());const n=()=>{this.proceedClose(t,e)};this.startedFs&&pe&&pe.isFullscreen()?Promise.resolve(pe.exit()).then((()=>n())):n()}clearIdle(){this.idleTimer&&clearTimeout(this.idleTimer),this.idleTimer=null}setIdle(t=!1){const e=()=>{this.clearIdle(),this.idle=!0,E(this.container,"is-idle"),this.emit("setIdle")};if(this.clearIdle(),!this.isClosing())if(t)e();else{const t=this.option("idle");t&&(this.idleTimer=setTimeout(e,t))}}endIdle(){this.clearIdle(),this.idle&&!this.isClosing()&&(this.idle=!1,T(this.container,"is-idle"),this.emit("endIdle"))}resetIdle(){this.endIdle(),this.setIdle()}toggleIdle(){this.idle?this.endIdle():this.setIdle(!0)}toggleFullscreen(){pe&&(pe.isFullscreen()?pe.exit():pe.request().then((()=>{this.startedFs=!0})))}isClosing(){return[rt.Closing,rt.CustomClosing,rt.Destroy].includes(this.state)}proceedClose(t,e){var i,n;this.state=rt.Closing,this.clearIdle(),this.detachEvents();const s=this.container,r=this.carousel,o=this.getSlide(),a=o&&this.option("placeFocusBack")?o.triggerEl||this.option("triggerEl"):null;if(a&&(J(a)?it(a):a.focus()),s&&(T(s,oe),E(s,"is-closing"),s.setAttribute(ee,"true"),this.option("animated")&&E(s,ne),s.style.pointerEvents="none"),r){r.clearTransitions(),null===(i=r.panzoom)||void 0===i||i.destroy(),null===(n=r.plugins.Navigation)||void 0===n||n.detach();for(const t of r.slides){t.state=ot.Closing,this.hideLoading(t);const e=t.contentEl;e&&this.stop(e);const i=null==t?void 0:t.panzoom;i&&(i.stop(),i.detachEvents(),i.detachObserver()),this.isCurrentSlide(t)||r.emit("removeSlide",t)}}ye=window.scrollX,_e=window.scrollY,window.addEventListener("scroll",this.onScroll),this.emit("close",t),this.state!==rt.CustomClosing?(void 0===e&&o&&(e=this.optionFor(o,"hideClass")),e&&o?(this.animate(o.contentEl,e,(()=>{r&&r.emit("removeSlide",o)})),setTimeout((()=>{this.destroy()}),500)):this.destroy()):setTimeout((()=>{this.destroy()}),500)}destroy(){var t;if(this.state===rt.Destroy)return;window.removeEventListener("scroll",this.onScroll),this.state=rt.Destroy,null===(t=this.carousel)||void 0===t||t.destroy();const e=this.container;e&&e.remove(),we.delete(this.id);const i=Se.getInstance();i?i.focus():(ge&&(ge.remove(),ge=null),me&&(me.remove(),me=null),T(document.documentElement,Kt),(()=>{if(!Q)return;const t=document,e=t.body;e.classList.remove(Jt),e.style.setProperty(te,""),t.documentElement.style.setProperty(Qt,"")})(),this.emit("destroy"))}static bind(t,e,i){if(!Q)return;let n,s="",r={};if(void 0===t?n=document.body:de(t)?(n=document.body,s=t,"object"==typeof e&&(r=e||{})):(n=t,de(e)&&(s=e),"object"==typeof i&&(r=i||{})),!n||!S(n))return;s=s||"[data-fancybox]";const o=Se.openers.get(n)||new Map;o.set(s,r),Se.openers.set(n,o),1===o.size&&n.addEventListener("click",Se.fromEvent)}static unbind(t,e){let i,n="";if(de(t)?(i=document.body,n=t):(i=t,de(e)&&(n=e)),!i)return;const s=Se.openers.get(i);s&&n&&s.delete(n),n&&s||(Se.openers.delete(i),i.removeEventListener("click",Se.fromEvent))}static destroy(){let t;for(;t=Se.getInstance();)t.destroy();for(const t of Se.openers.keys())t.removeEventListener("click",Se.fromEvent);Se.openers=new Map}static fromEvent(t){if(t.defaultPrevented)return;if(t.button&&0!==t.button)return;if(t.ctrlKey||t.metaKey||t.shiftKey)return;let e=t.composedPath()[0];const i=e.closest("[data-fancybox-trigger]");if(i){const t=i.dataset.fancyboxTrigger||"",n=document.querySelectorAll(`[data-fancybox="${t}"]`),s=parseInt(i.dataset.fancyboxIndex||"",10)||0;e=n[s]||e}if(!(e&&e instanceof Element))return;let n,s,r,o;
4if([...Se.openers].reverse().find((([t,i])=>!(!t.contains(e)||![...i].reverse().find((([i,a])=>{let l=e.closest(i);return!!l&&(n=t,s=i,r=l,o=a,!0)}))))),!n||!s||!r)return;o=o||{},t.preventDefault(),e=r;let a=[],l=f({},st,o);l.event=t,l.triggerEl=e,l.delegate=i;const c=l.groupAll,h=l.groupAttr,u=h&&e?e.getAttribute(`${h}`):"";if((!e||u||c)&&(a=[].slice.call(n.querySelectorAll(s))),e&&!c&&(a=u?a.filter((t=>t.getAttribute(`${h}`)===u)):[e]),!a.length)return;const d=Se.getInstance();return d&&d.options.triggerEl&&a.indexOf(d.options.triggerEl)>-1?void 0:(e&&(l.startIndex=a.indexOf(e)),Se.fromNodes(a,l))}static fromSelector(t,e,i){let n=null,s="",r={};if(de(t)?(n=document.body,s=t,"object"==typeof e&&(r=e||{})):t instanceof HTMLElement&&de(e)&&(n=t,s=e,"object"==typeof i&&(r=i||{})),!n||!s)return!1;const o=Se.openers.get(n);return!!o&&(r=f({},o.get(s)||{},r),!!r&&Se.fromNodes(Array.from(n.querySelectorAll(s)),r))}static fromNodes(t,e){e=f({},st,e||{});const i=[];for(const n of t){const t=n.dataset||{},s=t.src||n.getAttribute(ue)||n.getAttribute("currentSrc")||n.getAttribute("src")||void 0;let r;const o=e.delegate;let a;o&&i.length===e.startIndex&&(r=o instanceof HTMLImageElement?o:o.querySelector("img:not([aria-hidden])")),r||(r=n instanceof HTMLImageElement?n:n.querySelector("img:not([aria-hidden])")),r&&(a=r.currentSrc||r.src||void 0,!a&&r.dataset&&(a=r.dataset.lazySrc||r.dataset.src||void 0));const l={src:s,triggerEl:n,thumbEl:r,thumbElSrc:a,thumbSrc:a};for(const e in t){let i=t[e]+"";i="false"!==i&&("true"===i||i),l[e]=i}i.push(l)}return new Se(i,e)}static getInstance(t){return t?we.get(t):Array.from(we.values()).reverse().find((t=>!t.isClosing()&&t))||null}static getSlide(){var t;return(null===(t=Se.getInstance())||void 0===t?void 0:t.getSlide())||null}static show(t=[],e={}){return new Se(t,e)}static next(){const t=Se.getInstance();t&&t.next()}static prev(){const t=Se.getInstance();t&&t.prev()}static close(t=!0,...e){if(t)for(const t of we.values())t.close(...e);else{const t=Se.getInstance();t&&t.close(...e)}}}function Te(t,e,i){return Math.max(t,Math.min(e,i))}Object.defineProperty(Se,"version",{enumerable:!0,configurable:!0,writable:!0,value:"5.0.36"}),Object.defineProperty(Se,"defaults",{enumerable:!0,configurable:!0,writable:!0,value:st}),Object.defineProperty(Se,"Plugins",{enumerable:!0,configurable:!0,writable:!0,value:Gt}),Object.defineProperty(Se,"openers",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),Se.bind("[data-fancybox]",{closeButton:!1,autoFocus:!1,dragToClose:!1,groupAll:!1}),document.addEventListener("click",(t=>{t.target.classList.contains("popup__close")&&Se.close()})),i(805);var Ee=class{events={};emit(t,...e){let i=this.events[t]||[];for(let t=0,n=i.length;t<n;t++)i[t]?.(...e)}on(t,e){return this.events[t]?.push(e)||(this.events[t]=[e]),()=>{this.events[t]=this.events[t]?.filter((t=>e!==t))}}off(t,e){this.events[t]=this.events[t]?.filter((t=>e!==t))}destroy(){this.events={}}},Me=100/6,Ce={passive:!1};function Pe(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Oe(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}new class{_isScrolling=!1;_isStopped=!1;_isLocked=!1;_preventNextNativeScrollEvent=!1;_resetVelocityTimeout=null;__rafID=null;isTouching;time=0;userData={};lastVelocity=0;velocity=0;direction=0;options;targetScroll;animatedScroll;animate=new class{isRunning=!1;value=0;from=0;to=0;currentTime=0;lerp;duration;easing;onUpdate;advance(t){if(!this.isRunning)return;let e=!1;if(this.duration&&this.easing){this.currentTime+=t;const i=Te(0,this.currentTime/this.duration,1);e=i>=1;const n=e?1:this.easing(i);this.value=this.from+(this.to-this.from)*n}else this.lerp?(this.value=function(t,e,i,n){return function(t,e,i){return(1-i)*t+i*e}(t,e,1-Math.exp(-i*n))}(this.value,this.to,60*this.lerp,t),Math.round(this.value)===this.to&&(this.value=this.to,e=!0)):(this.value=this.to,e=!0);e&&this.stop(),this.onUpdate?.(this.value,e)}stop(){this.isRunning=!1}fromTo(t,e,{lerp:i,duration:n,easing:s,onStart:r,onUpdate:o}){this.from=this.value=t,this.to=e,this.lerp=i,this.duration=n,this.easing=s,this.currentTime=0,this.isRunning=!0,r?.(),this.onUpdate=o}};emitter=new Ee;dimensions;virtualScroll;constructor({wrapper:t=window,content:e=document.documentElement,eventsTarget:i=t,smoothWheel:n=!0,syncTouch:s=!1,syncTouchLerp:r=.075,touchInertiaMultiplier:o=35,duration:a,easing:l=(t=>
4Math.min(1,1.001-Math.pow(2,-10*t))),lerp:c=.1,infinite:h=!1,orientation:u="vertical",gestureOrientation:d="vertical",touchMultiplier:f=1,wheelMultiplier:p=1,autoResize:g=!0,prevent:m,virtualScroll:v,overscroll:b=!0,autoRaf:y=!1,anchors:_=!1,__experimental__naiveDimensions:w=!1}={}){window.lenisVersion="1.1.22",t&&t!==document.documentElement||(t=window),this.options={wrapper:t,content:e,eventsTarget:i,smoothWheel:n,syncTouch:s,syncTouchLerp:r,touchInertiaMultiplier:o,duration:a,easing:l,lerp:c,infinite:h,gestureOrientation:d,orientation:u,touchMultiplier:f,wheelMultiplier:p,autoResize:g,prevent:m,virtualScroll:v,overscroll:b,autoRaf:y,anchors:_,__experimental__naiveDimensions:w},this.dimensions=new class{constructor(t,e,{autoResize:i=!0,debounce:n=250}={}){this.wrapper=t,this.content=e,i&&(this.debouncedResize=function(t,e){let i;return function(...n){let s=this;clearTimeout(i),i=setTimeout((()=>{i=void 0,t.apply(s,n)}),e)}}(this.resize,n),this.wrapper instanceof Window?window.addEventListener("resize",this.debouncedResize,!1):(this.wrapperResizeObserver=new ResizeObserver(this.debouncedResize),this.wrapperResizeObserver.observe(this.wrapper)),this.contentResizeObserver=new ResizeObserver(this.debouncedResize),this.contentResizeObserver.observe(this.content)),this.resize()}width=0;height=0;scrollHeight=0;scrollWidth=0;debouncedResize;wrapperResizeObserver;contentResizeObserver;destroy(){this.wrapperResizeObserver?.disconnect(),this.contentResizeObserver?.disconnect(),this.wrapper===window&&this.debouncedResize&&window.removeEventListener("resize",this.debouncedResize,!1)}resize=()=>{this.onWrapperResize(),this.onContentResize()};onWrapperResize=()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)};onContentResize=()=>{this.wrapper instanceof Window?(this.scrollHeight=this.content.scrollHeight,this.scrollWidth=this.content.scrollWidth):(this.scrollHeight=this.wrapper.scrollHeight,this.scrollWidth=this.wrapper.scrollWidth)};get limit(){return{x:this.scrollWidth-this.width,y:this.scrollHeight-this.height}}}(t,e,{autoResize:g}),this.updateClassName(),this.targetScroll=this.animatedScroll=this.actualScroll,this.options.wrapper.addEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.addEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.anchors&&this.options.wrapper===window&&this.options.wrapper.addEventListener("click",this.onClick,!1),this.options.wrapper.addEventListener("pointerdown",this.onPointerDown,!1),this.virtualScroll=new class{constructor(t,e={wheelMultiplier:1,touchMultiplier:1}){this.element=t,this.options=e,window.addEventListener("resize",this.onWindowResize,!1),this.onWindowResize(),this.element.addEventListener("wheel",this.onWheel,Ce),this.element.addEventListener("touchstart",this.onTouchStart,Ce),this.element.addEventListener("touchmove",this.onTouchMove,Ce),this.element.addEventListener("touchend",this.onTouchEnd,Ce)}touchStart={x:0,y:0};lastDelta={x:0,y:0};window={width:0,height:0};emitter=new Ee;on(t,e){return this.emitter.on(t,e)}destroy(){this.emitter.destroy(),window.removeEventListener("resize",this.onWindowResize,!1),this.element.removeEventListener("wheel",this.onWheel,Ce),this.element.removeEventListener("touchstart",this.onTouchStart,Ce),this.element.removeEventListener("touchmove",this.onTouchMove,Ce),this.element.removeEventListener("touchend",this.onTouchEnd,Ce)}onTouchStart=t=>{const{clientX:e,clientY:i}=t.targetTouches?t.targetTouches[0]:t;this.touchStart.x=e,this.touchStart.y=i,this.lastDelta={x:0,y:0},this.emitter.emit("scroll",{deltaX:0,deltaY:0,event:t})};onTouchMove=t=>{const{clientX:e,clientY:i}=t.targetTouches?t.targetTouches[0]:t,n=-(e-this.touchStart.x)*this.options.touchMultiplier,s=-(i-this.touchStart.y)*this.options.touchMultiplier;this.touchStart.x=e,this.touchStart.y=i,this.lastDelta={x:n,y:s},this.emitter.emit("scroll",{deltaX:n,deltaY:s,event:t})};onTouchEnd=t=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:t})};onWheel=t=>{let{deltaX:e,deltaY:i,deltaMode:n}=t;e*=1===n?Me:2===n?this.window.width:1,i*=1===n?Me:2===n?this.window.height:1,e*=this.options.wheelMultiplier,i*=this.options.wheelMultiplier,this.emitter.emit("scroll",{deltaX:e,deltaY:i,event:t})};onWindowResize=()=>{this.window={width:window.innerWidth,height:window.innerHeight}}}
vendor: 4,178 bytes, line 4
4(i,{touchMultiplier:f,wheelMultiplier:p}),this.virtualScroll.on("scroll",this.onVirtualScroll),this.options.autoRaf&&(this.__rafID=requestAnimationFrame(this.raf))}destroy(){this.emitter.destroy(),this.options.wrapper.removeEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.removeEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.wrapper.removeEventListener("pointerdown",this.onPointerDown,!1),this.options.anchors&&this.options.wrapper===window&&this.options.wrapper.removeEventListener("click",this.onClick,!1),this.virtualScroll.destroy(),this.dimensions.destroy(),this.cleanUpClassName(),this.__rafID&&cancelAnimationFrame(this.__rafID)}on(t,e){return this.emitter.on(t,e)}off(t,e){return this.emitter.off(t,e)}onScrollEnd=t=>{t instanceof CustomEvent||"smooth"!==this.isScrolling&&!1!==this.isScrolling||t.stopPropagation()};dispatchScrollendEvent=()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))};setScroll(t){this.isHorizontal?this.options.wrapper.scrollTo({left:t,behavior:"instant"}):this.options.wrapper.scrollTo({top:t,behavior:"instant"})}onClick=t=>{const e=t.composedPath().find((t=>t instanceof HTMLAnchorElement&&t.getAttribute("href")?.startsWith("#")));if(e){const t=e.getAttribute("href");if(t){const e="object"==typeof this.options.anchors&&this.options.anchors?this.options.anchors:void 0;this.scrollTo(t,e)}}};onPointerDown=t=>{1===t.button&&this.reset()};onVirtualScroll=t=>{if("function"==typeof this.options.virtualScroll&&!1===this.options.virtualScroll(t))return;const{deltaX:e,deltaY:i,event:n}=t;if(this.emitter.emit("virtual-scroll",{deltaX:e,deltaY:i,event:n}),n.ctrlKey)return;if(n.lenisStopPropagation)return;const s=n.type.includes("touch"),r=n.type.includes("wheel");this.isTouching="touchstart"===n.type||"touchmove"===n.type;const o=0===e&&0===i;if(this.options.syncTouch&&s&&"touchstart"===n.type&&o&&!this.isStopped&&!this.isLocked)return void this.reset();const a="vertical"===this.options.gestureOrientation&&0===i||"horizontal"===this.options.gestureOrientation&&0===e;if(o||a)return;let l=n.composedPath();l=l.slice(0,l.indexOf(this.rootElement));const c=this.options.prevent;if(l.find((t=>t instanceof HTMLElement&&("function"==typeof c&&c?.(t)||t.hasAttribute?.("data-lenis-prevent")||s&&t.hasAttribute?.("data-lenis-prevent-touch")||r&&t.hasAttribute?.("data-lenis-prevent-wheel")))))return;if(this.isStopped||this.isLocked)return void n.preventDefault();if(!(this.options.syncTouch&&s||this.options.smoothWheel&&r))return this.isScrolling="native",this.animate.stop(),void(n.lenisStopPropagation=!0);let h=i;"both"===this.options.gestureOrientation?h=Math.abs(i)>Math.abs(e)?i:e:"horizontal"===this.options.gestureOrientation&&(h=e),(!this.options.overscroll||this.options.infinite||this.options.wrapper!==window&&(this.animatedScroll>0&&this.animatedScroll<this.limit||0===this.animatedScroll&&i>0||this.animatedScroll===this.limit&&i<0))&&(n.lenisStopPropagation=!0),n.preventDefault();const u=s&&this.options.syncTouch,d=s&&"touchend"===n.type&&Math.abs(h)>5;d&&(h=this.velocity*this.options.touchInertiaMultiplier),this.scrollTo(this.targetScroll+h,{programmatic:!1,...u?{lerp:d?this.options.syncTouchLerp:1}:{lerp:this.options.lerp,duration:this.options.duration,easing:this.options.easing}})};resize(){this.dimensions.resize(),this.animatedScroll=this.targetScroll=this.actualScroll,this.emit()}emit(){this.emitter.emit("scroll",this)}onNativeScroll=()=>{if(null!==this._resetVelocityTimeout&&(clearTimeout(this._resetVelocityTimeout),this._resetVelocityTimeout=null),this._preventNextNativeScrollEvent)this._preventNextNativeScrollEvent=!1;else if(!1===this.isScrolling||"native"===this.isScrolling){const t=this.animatedScroll;this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity,this.velocity=this.animatedScroll-t,this.direction=Math.sign(this.animatedScroll-t),this.isStopped||(this.isScrolling="native"),this.emit(),0!==this.velocity&&(this._resetVelocityTimeout=setTimeout((()=>{this.lastVelocity=this.velocity,this.velocity=0,this.isScrolling=!1,this.emit
4()}),400))}};reset(){this.isLocked=!1,this.isScrolling=!1,this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity=0,this.animate.stop()}start(){this.isStopped&&(this.reset(),this.isStopped=!1)}stop(){this.isStopped||(this.reset(),this.isStopped=!0)}raf=t=>{const e=t-(this.time||t);this.time=t,this.animate.advance(.001*e),this.options.autoRaf&&(this.__rafID=requestAnimationFrame(this.raf))};scrollTo(t,{offset:e=0,immediate:i=!1,lock:n=!1,duration:s=this.options.duration,easing:r=this.options.easing,lerp:o=this.options.lerp,onStart:a,onComplete:l,force:c=!1,programmatic:h=!0,userData:u}={}){if(!this.isStopped&&!this.isLocked||c){if("string"==typeof t&&["top","left","start"].includes(t))t=0;else if("string"==typeof t&&["bottom","right","end"].includes(t))t=this.limit;else{let i;if("string"==typeof t?i=document.querySelector(t):t instanceof HTMLElement&&t?.nodeType&&(i=t),i){if(this.options.wrapper!==window){const t=this.rootElement.getBoundingClientRect();e-=this.isHorizontal?t.left:t.top}const n=i.getBoundingClientRect();t=(this.isHorizontal?n.left:n.top)+this.animatedScroll}}if("number"==typeof t){if(t+=e,t=Math.round(t),this.options.infinite?h&&(this.targetScroll=this.animatedScroll=this.scroll):t=Te(0,t,this.limit),t===this.targetScroll)return a?.(this),void l?.(this);if(this.userData=u??{},i)return this.animatedScroll=this.targetScroll=t,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),l?.(this),this.userData={},void requestAnimationFrame((()=>{this.dispatchScrollendEvent()}));h||(this.targetScroll=t),this.animate.fromTo(this.animatedScroll,t,{duration:s,easing:r,lerp:o,onStart:()=>{n&&(this.isLocked=!0),this.isScrolling="smooth",a?.(this)},onUpdate:(t,e)=>{this.isScrolling="smooth",this.lastVelocity=this.velocity,this.velocity=t-this.animatedScroll,this.direction=Math.sign(this.velocity),this.animatedScroll=t,this.setScroll(this.scroll),h&&(this.targetScroll=t),e||this.emit(),e&&(this.reset(),this.emit(),l?.(this),this.userData={},requestAnimationFrame((()=>{this.dispatchScrollendEvent()})),this.preventNextNativeScrollEvent())}})}}}preventNextNativeScrollEvent(){this._preventNextNativeScrollEvent=!0,requestAnimationFrame((()=>{this._preventNextNativeScrollEvent=!1}))}get rootElement(){return this.options.wrapper===window?document.documentElement:this.options.wrapper}get limit(){return this.options.__experimental__naiveDimensions?this.isHorizontal?this.rootElement.scrollWidth-this.rootElement.clientWidth:this.rootElement.scrollHeight-this.rootElement.clientHeight:this.dimensions.limit[this.isHorizontal?"x":"y"]}get isHorizontal(){return"horizontal"===this.options.orientation}get actualScroll(){const t=this.options.wrapper;return this.isHorizontal?t.scrollX??t.scrollLeft:t.scrollY??t.scrollTop}get scroll(){return this.options.infinite?function(t,e){return(t%e+e)%e}(this.animatedScroll,this.limit):this.animatedScroll}get progress(){return 0===this.limit?1:this.scroll/this.limit}get isScrolling(){return this._isScrolling}set isScrolling(t){this._isScrolling!==t&&(this._isScrolling=t,this.updateClassName())}get isStopped(){return this._isStopped}set isStopped(t){this._isStopped!==t&&(this._isStopped=t,this.updateClassName())}get isLocked(){return this._isLocked}set isLocked(t){this._isLocked!==t&&(this._isLocked=t,this.updateClassName())}get isSmooth(){return"smooth"===this.isScrolling}get className(){let t="lenis";return this.isStopped&&(t+=" lenis-stopped"),this.isLocked&&(t+=" lenis-locked"),this.isScrolling&&(t+=" lenis-scrolling"),"smooth"===this.isScrolling&&(t+=" lenis-smooth"),t}updateClassName(){this.cleanUpClassName(),this.rootElement.className=`${this.rootElement.className} ${this.className}`.trim()}cleanUpClassName(){this.rootElement.className=this.rootElement.className.replace(/lenis(-\w+)?/g,"").trim()}}({autoRaf:!0}),i(680);var ke,Ae,Le,Re,ze,De,Ie,Fe,Be,Ne,je,He={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},Ye={duration:.5,overwrite:!1,delay:0},qe=1e8,Xe=1e-8,We=2*Math.PI,$e=We/4,Ve=0,Ue=Math.sqrt,Ze=Math.cos,Ge=Math.sin,Ke=function(t){return"string"==typeof t},Je=function(t){return"function"==typeof t},Qe=function(t){return"number"==typeof t},ti=function(t){return void 0===t},ei=function(t){return"object"==typeof t},ii=function(t){return!1!==t},ni=function(){return"undefined"!=typeof window},si=function(t){return Je(t)||Ke(t)},ri="function"==typeof ArrayBuffer&&ArrayBuffer.isView||function(){},oi=Array.isArray,ai=/(?:-?\.?\d|\.)+/gi,li=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,ci=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,hi=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,ui=/[+-]=-?[.\d]+/,di=/[^,'"\[\]\s]+/gi,fi=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,pi={},gi={},mi=function(t){return(gi=Wi(t,pi))&&Vs},vi=function(t,e){return console.warn("Invalid property",t,"set to",e,"Missing plugin? gsap.registerPlugin()")},bi=function(t,e){return!e&&console.warn(t)},yi=function(t,e){return t&&(pi[t]=e)&&gi&&(gi[t]=e)||pi},_i=function(){return 0},wi={suppressEvents:!0,isStart:!0,kill:!1},xi={suppressEvents:!0,kill:!1},Si={suppressEvents:!0},Ti={},Ei=[],Mi={},Ci={},Pi={}
vendor: 4,139 bytes, line 4
4,Oi=30,ki=[],Ai="",Li=function(t){var e,i,n=t[0];if(ei(n)||Je(n)||(t=[t]),!(e=(n._gsap||{}).harness)){for(i=ki.length;i--&&!ki[i].targetTest(n););e=ki[i]}for(i=t.length;i--;)t[i]&&(t[i]._gsap||(t[i]._gsap=new as(t[i],e)))||t.splice(i,1);return t},Ri=function(t){return t._gsap||Li(Tn(t))[0]._gsap},zi=function(t,e,i){return(i=t[e])&&Je(i)?t[e]():ti(i)&&t.getAttribute&&t.getAttribute(e)||i},Di=function(t,e){return(t=t.split(",")).forEach(e)||t},Ii=function(t){return Math.round(1e5*t)/1e5||0},Fi=function(t){return Math.round(1e7*t)/1e7||0},Bi=function(t,e){var i=e.charAt(0),n=parseFloat(e.substr(2));return t=parseFloat(t),"+"===i?t+n:"-"===i?t-n:"*"===i?t*n:t/n},Ni=function(t,e){for(var i=e.length,n=0;t.indexOf(e[n])<0&&++n<i;);return n<i},ji=function(){var t,e,i=Ei.length,n=Ei.slice(0);for(Mi={},Ei.length=0,t=0;t<i;t++)(e=n[t])&&e._lazy&&(e.render(e._lazy[0],e._lazy[1],!0)._lazy=0)},Hi=function(t,e,i,n){Ei.length&&!Ae&&ji(),t.render(e,i,n||Ae&&e<0&&(t._initted||t._startAt)),Ei.length&&!Ae&&ji()},Yi=function(t){var e=parseFloat(t);return(e||0===e)&&(t+"").match(di).length<2?e:Ke(t)?t.trim():t},qi=function(t){return t},Xi=function(t,e){for(var i in e)i in t||(t[i]=e[i]);return t},Wi=function(t,e){for(var i in e)t[i]=e[i];return t},$i=function t(e,i){for(var n in i)"__proto__"!==n&&"constructor"!==n&&"prototype"!==n&&(e[n]=ei(i[n])?t(e[n]||(e[n]={}),i[n]):i[n]);return e},Vi=function(t,e){var i,n={};for(i in t)i in e||(n[i]=t[i]);return n},Ui=function(t){var e,i=t.parent||Re,n=t.keyframes?(e=oi(t.keyframes),function(t,i){for(var n in i)n in t||"duration"===n&&e||"ease"===n||(t[n]=i[n])}):Xi;if(ii(t.inherit))for(;i;)n(t,i.vars.defaults),i=i.parent||i._dp;return t},Zi=function(t,e,i,n,s){void 0===i&&(i="_first"),void 0===n&&(n="_last");var r,o=t[n];if(s)for(r=e[s];o&&o[s]>r;)o=o._prev;return o?(e._next=o._next,o._next=e):(e._next=t[i],t[i]=e),e._next?e._next._prev=e:t[n]=e,e._prev=o,e.parent=e._dp=t,e},Gi=function(t,e,i,n){void 0===i&&(i="_first"),void 0===n&&(n="_last");var s=e._prev,r=e._next;s?s._next=r:t[i]===e&&(t[i]=r),r?r._prev=s:t[n]===e&&(t[n]=s),e._next=e._prev=e.parent=null},Ki=function(t,e){t.parent&&(!e||t.parent.autoRemoveChildren)&&t.parent.remove&&t.parent.remove(t),t._act=0},Ji=function(t,e){if(t&&(!e||e._end>t._dur||e._start<0))for(var i=t;i;)i._dirty=1,i=i.parent;return t},Qi=function(t){for(var e=t.parent;e&&e.parent;)e._dirty=1,e.totalDuration(),e=e.parent;return t},tn=function(t,e,i,n){return t._startAt&&(Ae?t._startAt.revert(xi):t.vars.immediateRender&&!t.vars.autoRevert||t._startAt.render(e,!0,n))},en=function t(e){return!e||e._ts&&t(e.parent)},nn=function(t){return t._repeat?sn(t._tTime,t=t.duration()+t._rDelay)*t:0},sn=function(t,e){var i=Math.floor(t=Fi(t/e));return t&&i===t?i-1:i},rn=function(t,e){return(t-e._start)*e._ts+(e._ts>=0?0:e._dirty?e.totalDuration():e._tDur)},on=function(t){return t._end=Fi(t._start+(t._tDur/Math.abs(t._ts||t._rts||Xe)||0))},an=function(t,e){var i=t._dp;return i&&i.smoothChildTiming&&t._ts&&(t._start=Fi(i._time-(t._ts>0?e/t._ts:((t._dirty?t.totalDuration():t._tDur)-e)/-t._ts)),on(t),i._dirty||Ji(i,t)),t},ln=function(t,e){var i;if((e._time||!e._dur&&e._initted||e._start<t._time&&(e._dur||!e.add))&&(i=rn(t.rawTime(),e),(!e._dur||_n(0,e.totalDuration(),i)-e._tTime>Xe)&&e.render(i,!0)),Ji(t,e)._dp&&t._initted&&t._time>=t._dur&&t._ts){if(t._dur<t.duration())for(i=t;i._dp;)i.rawTime()>=0&&i.totalTime(i._tTime),i=i._dp;t._zTime=-1e-8}},cn=function(t,e,i,n){return e.parent&&Ki(e),e._start=Fi((Qe(i)?i:i||t!==Re?vn(t,i,e):t._time)+e._delay),e._end=Fi(e._start+(e.totalDuration()/Math.abs(e.timeScale())||0)),Zi(t,e,"_first","_last",t._sort?"_start":0),fn(e)||(t._recent=e),n||ln(t,e),t._ts<0&&an(t,t._tTime),t},hn=function(t,e){return(pi.ScrollTrigger||vi("scrollTrigger",e))&&pi.ScrollTrigger.create(e,t)},un=function(t,e,i,n,s){return gs(t,e,s),t._initted?!i&&t._pt&&!Ae&&(t._dur&&!1!==t.vars.lazy||!t._dur&&t.vars.lazy)&&Be!==Un.frame?(Ei.push(t),t._lazy=[s,n],1):void 0:1},dn=function t(e){var i=e.parent;return i&&i._ts&&i._initted&&!i._lock&&(i.rawTime()<0||t(i))},fn=function(t){var e=t.data;return"isFromStart"===e||"isStart"===e}
vendor: 20,171 bytes, line 4
4,pn=function(t,e,i,n){var s=t._repeat,r=Fi(e)||0,o=t._tTime/t._tDur;return o&&!n&&(t._time*=r/t._dur),t._dur=r,t._tDur=s?s<0?1e10:Fi(r*(s+1)+t._rDelay*s):r,o>0&&!n&&an(t,t._tTime=t._tDur*o),t.parent&&on(t),i||Ji(t.parent,t),t},gn=function(t){return t instanceof cs?Ji(t):pn(t,t._dur)},mn={_start:0,endTime:_i,totalDuration:_i},vn=function t(e,i,n){var s,r,o,a=e.labels,l=e._recent||mn,c=e.duration()>=qe?l.endTime(!1):e._dur;return Ke(i)&&(isNaN(i)||i in a)?(r=i.charAt(0),o="%"===i.substr(-1),s=i.indexOf("="),"<"===r||">"===r?(s>=0&&(i=i.replace(/=/,"")),("<"===r?l._start:l.endTime(l._repeat>=0))+(parseFloat(i.substr(1))||0)*(o?(s<0?l:n).totalDuration()/100:1)):s<0?(i in a||(a[i]=c),a[i]):(r=parseFloat(i.charAt(s-1)+i.substr(s+1)),o&&n&&(r=r/100*(oi(n)?n[0]:n).totalDuration()),s>1?t(e,i.substr(0,s-1),n)+r:c+r)):null==i?c:+i},bn=function(t,e,i){var n,s,r=Qe(e[1]),o=(r?2:1)+(t<2?0:1),a=e[o];if(r&&(a.duration=e[1]),a.parent=i,t){for(n=a,s=i;s&&!("immediateRender"in n);)n=s.vars.defaults||{},s=ii(s.vars.inherit)&&s.parent;a.immediateRender=ii(n.immediateRender),t<2?a.runBackwards=1:a.startAt=e[o-1]}return new _s(e[0],a,e[o+1])},yn=function(t,e){return t||0===t?e(t):e},_n=function(t,e,i){return i<t?t:i>e?e:i},wn=function(t,e){return Ke(t)&&(e=fi.exec(t))?e[1]:""},xn=[].slice,Sn=function(t,e){return t&&ei(t)&&"length"in t&&(!e&&!t.length||t.length-1 in t&&ei(t[0]))&&!t.nodeType&&t!==ze},Tn=function(t,e,i){return Le&&!e&&Le.selector?Le.selector(t):!Ke(t)||i||!De&&Zn()?oi(t)?function(t,e,i){return void 0===i&&(i=[]),t.forEach((function(t){var n;return Ke(t)&&!e||Sn(t,1)?(n=i).push.apply(n,Tn(t)):i.push(t)}))||i}(t,i):Sn(t)?xn.call(t,0):t?[t]:[]:xn.call((e||Ie).querySelectorAll(t),0)},En=function(t){return t=Tn(t)[0]||bi("Invalid scope")||{},function(e){var i=t.current||t.nativeElement||t;return Tn(e,i.querySelectorAll?i:i===t?bi("Invalid scope")||Ie.createElement("div"):t)}},Mn=function(t){return t.sort((function(){return.5-Math.random()}))},Cn=function(t){if(Je(t))return t;var e=ei(t)?t:{each:t},i=is(e.ease),n=e.from||0,s=parseFloat(e.base)||0,r={},o=n>0&&n<1,a=isNaN(n)||o,l=e.axis,c=n,h=n;return Ke(n)?c=h={center:.5,edges:.5,end:1}[n]||0:!o&&a&&(c=n[0],h=n[1]),function(t,o,u){var d,f,p,g,m,v,b,y,_,w=(u||e).length,x=r[w];if(!x){if(!(_="auto"===e.grid?0:(e.grid||[1,qe])[1])){for(b=-qe;b<(b=u[_++].getBoundingClientRect().left)&&_<w;);_<w&&_--}for(x=r[w]=[],d=a?Math.min(_,w)*c-.5:n%_,f=_===qe?0:a?w*h/_-.5:n/_|0,b=0,y=qe,v=0;v<w;v++)p=v%_-d,g=f-(v/_|0),x[v]=m=l?Math.abs("y"===l?g:p):Ue(p*p+g*g),m>b&&(b=m),m<y&&(y=m);"random"===n&&Mn(x),x.max=b-y,x.min=y,x.v=w=(parseFloat(e.amount)||parseFloat(e.each)*(_>w?w-1:l?"y"===l?w/_:_:Math.max(_,w/_))||0)*("edges"===n?-1:1),x.b=w<0?s-w:s,x.u=wn(e.amount||e.each)||0,i=i&&w<0?ts(i):i}return w=(x[t]-x.min)/x.max||0,Fi(x.b+(i?i(w):w)*x.v)+x.u}},Pn=function(t){var e=Math.pow(10,((t+"").split(".")[1]||"").length);return function(i){var n=Fi(Math.round(parseFloat(i)/t)*t*e);return(n-n%1)/e+(Qe(i)?0:wn(i))}},On=function(t,e){var i,n,s=oi(t);return!s&&ei(t)&&(i=s=t.radius||qe,t.values?(t=Tn(t.values),(n=!Qe(t[0]))&&(i*=i)):t=Pn(t.increment)),yn(e,s?Je(t)?function(e){return n=t(e),Math.abs(n-e)<=i?n:e}:function(e){for(var s,r,o=parseFloat(n?e.x:e),a=parseFloat(n?e.y:0),l=qe,c=0,h=t.length;h--;)(s=n?(s=t[h].x-o)*s+(r=t[h].y-a)*r:Math.abs(t[h]-o))<l&&(l=s,c=h);return c=!i||l<=i?t[c]:e,n||c===e||Qe(e)?c:c+wn(e)}:Pn(t))},kn=function(t,e,i,n){return yn(oi(t)?!e:!0===i?!!(i=0):!n,(function(){return oi(t)?t[~~(Math.random()*t.length)]:(i=i||1e-5)&&(n=i<1?Math.pow(10,(i+"").length-2):1)&&Math.floor(Math.round((t-i/2+Math.random()*(e-t+.99*i))/i)*i*n)/n}))},An=function(t,e,i){return yn(i,(function(i){return t[~~e(i)]}))},Ln=function(t){for(var e,i,n,s,r=0,o="";~(e=t.indexOf("random(",r));)n=t.indexOf(")",e),s="["===t.charAt(e+7),i=t.substr(e+7,n-e-7).match(s?di:ai),o+=t.substr(r,e-r)+kn(s?i:+i[0],s?0:+i[1],+i[2]||1e-5),r=n+1;return o+t.substr(r,t.length-r)},Rn=function(t,e,i,n,s){var r=e-t,o=n-i;return yn(s,(function(e){return i+((e-t)/r*o||0)}))},zn=function(t,e,i){var n,s,r,o=t.labels,a=qe;for(n in o)(s=o[n]-e)<0==!!i&&s&&a>(s=Math.abs(s))&&(r=n,a=s);return r},Dn=function(t,e,i){var n,s,r,o=t.vars,a=o[e],l=Le,c=t._ctx;if(a)return n=o[e+"Params"],s=o.callbackScope||t,i&&Ei.length&&ji(),c&&(Le=c),r=n?a.apply(s,n):a.call(s),Le=l,r},In=function(t){return Ki(t),t.scrollTrigger&&t.scrollTrigger.kill(!!Ae),t.progress()<1&&Dn(t,"onInterrupt"),t},Fn=[],Bn=function(t){if(t)if(t=!t.name&&t.default||t,ni()||t.headless){var e=t.name,i=Je(t),n=e&&!i&&t.init?function(){this._props=[]}:t,s={init:_i,render:Os,add:fs,kill:As,modifier:ks,rawVars:0},r={targetTest:0,get:0,getSetter:Es,aliases:{},register:0};if(Zn(),t!==n){if(Ci[e])return;Xi(n,Xi(Vi(t,s),r)),Wi(n.prototype,Wi(s,Vi(t,r))),Ci[n.prop=e]=n,t.targetTest&&(ki.push(n),Ti[e]=1),e=("css"===e?"CSS":e.charAt(0).toUpperCase()+e.substr(1))+"Plugin"}yi(e,n),t.register&&t.register(Vs,n,zs)}else Fn.push(t)},Nn=255,jn={aqua:[0,Nn,Nn],lime:[0,Nn,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,Nn],navy:[0,0,128],white:[Nn,Nn,Nn],olive:[128,128,0],yellow:[Nn,Nn,0],orange:[Nn,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[Nn,0,0],pink:[Nn,192,203],cyan:[0,Nn,Nn],transparent:[Nn,Nn,Nn,0]},Hn=function(t,e,i){return(6*(t+=t<0?1:t>1?-1:0)<1?e+(i-e)*t*6:t<.5?i:3*t<2?e+(i-e)*(2/3-t)*6:e)*Nn+.5|0},Yn=function(t,e,i){var n,s,r,o,a,l,c,h,u,d,f=t?Qe(t)?[t>>16,t>>8&Nn,t&Nn]:0:jn.black;if(!f){if(","===t.substr(-1)&&(t=t.substr(0,t.length-1)),jn[t])f=jn[t];else if("#"===t.charAt(0)){if(t.length<6&&(n=t.charAt(1),s=t.charAt(2),r=t.charAt(3),t="#"+n+n+s+s+r+r+(5===t.length?t.charAt(4)+t.charAt(4):"")),9===t.length)return[(f=parseInt(t.substr(1,6),16))>>16,f>>8&Nn,f&Nn,parseInt(t.substr(7),16)/255];f=[(t=parseInt(t.substr(1),16))>>16,t>>8&Nn,t&Nn]}else if("hsl"===t.substr(0,3))if(f=d=t.match(ai),e){if(~t.indexOf("="))return f=t.match(li),i&&f.length<4&&(f[3]=1),f}else o=+f[0]%360/360,a=+f[1]/100,n=2*(l=+f[2]/100)-(s=l<=.5?l*(a+1):l+a-l*a),f.length>3&&(f[3]*=1),f[0]=Hn(o+1/3,n,s),f[1]=Hn(o,n,s),f[2]=Hn(o-1/3,n,s);else f=t.match(ai)||jn.transparent;f=f.map(Number)}return e&&!d&&(n=f[0]/Nn,s=f[1]/Nn,r=f[2]/Nn,l=((c=Math.max(n,s,r))+(h=Math.min(n,s,r)))/2,c===h?o=a=0:(u=c-h,a=l>.5?u/(2-c-h):u/(c+h),o=c===n?(s-r)/u+(s<r?6:0):c===s?(r-n)/u+2:(n-s)/u+4,o*=60),f[0]=~~(o+.5),f[1]=~~(100*a+.5),f[2]=~~(100*l+.5)),i&&f.length<4&&(f[3]=1),f},qn=function(t){var e=[],i=[],n=-1;return t.split(Wn).forEach((function(t){var s=t.match(ci)||[];e.push.apply(e,s),i.push(n+=s.length+1)})),e.c=i,e},Xn=function(t,e,i){var n,s,r,o,a="",l=(t+a).match(Wn),c=e?"hsla(":"rgba(",h=0;if(!l)return t;if(l=l.map((function(t){return(t=Yn(t,e,1))&&c+(e?t[0]+","+t[1]+"%,"+t[2]+"%,"+t[3]:t.join(","))+")"})),i&&(r=qn(t),(n=i.c).join(a)!==r.c.join(a)))for(o=(s=t.replace(Wn,"1").split(ci)).length-1;h<o;h++)a+=s[h]+(~n.indexOf(h)?l.shift()||c+"0,0,0,0)":(r.length?r:l.length?l:i).shift());if(!s)for(o=(s=t.split(Wn)).length-1;h<o;h++)a+=s[h]+l[h];return a+s[o]},Wn=function(){var t,e="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b";for(t in jn)e+="|"+t+"\\b";return new RegExp(e+")","gi")}(),$n=/hsl[a]?\(/,Vn=function(t){var e,i=t.join(" ");if(Wn.lastIndex=0,Wn.test(i))return e=$n.test(i),t[1]=Xn(t[1],e),t[0]=Xn(t[0],e,qn(t[1])),!0},Un=function(){var t,e,i,n,s,r,o=Date.now,a=500,l=33,c=o(),h=c,u=1e3/240,d=u,f=[],p=function i(p){var g,m,v,b,y=o()-h,_=!0===p;if((y>a||y<0)&&(c+=y-l),((g=(v=(h+=y)-c)-d)>0||_)&&(b=++n.frame,s=v-1e3*n.time,n.time=v/=1e3,d+=g+(g>=u?4:u-g),m=1),_||(t=e(i)),m)for(r=0;r<f.length;r++)f[r](v,s,b,p)};return n={time:0,frame:0,tick:function(){p(!0)},deltaRatio:function(t){return s/(1e3/(t||60))},wake:function(){Fe&&(!De&&ni()&&(ze=De=window,Ie=ze.document||{},pi.gsap=Vs,(ze.gsapVersions||(ze.gsapVersions=[])).push(Vs.version),mi(gi||ze.GreenSockGlobals||!ze.gsap&&ze||{}),Fn.forEach(Bn)),i="undefined"!=typeof requestAnimationFrame&&requestAnimationFrame,t&&n.sleep(),e=i||function(t){return setTimeout(t,d-1e3*n.time+1|0)},je=1,p(2))},sleep:function(){(i?cancelAnimationFrame:clearTimeout)(t),je=0,e=_i},lagSmoothing:function(t,e){a=t||1/0,l=Math.min(e||33,a)},fps:function(t){u=1e3/(t||240),d=1e3*n.time+u},add:function(t,e,i){var s=e?function(e,i,r,o){t(e,i,r,o),n.remove(s)}:t;return n.remove(t),f[i?"unshift":"push"](s),Zn(),s},remove:function(t,e){~(e=f.indexOf(t))&&f.splice(e,1)&&r>=e&&r--},_listeners:f},n}(),Zn=function(){return!je&&Un.wake()},Gn={},Kn=/^[\d.\-M][\d.\-,\s]/,Jn=/["']/g,Qn=function(t){for(var e,i,n,s={},r=t.substr(1,t.length-3).split(":"),o=r[0],a=1,l=r.length;a<l;a++)i=r[a],e=a!==l-1?i.lastIndexOf(","):i.length,n=i.substr(0,e),s[o]=isNaN(n)?n.replace(Jn,"").trim():+n,o=i.substr(e+1).trim();return s},ts=function(t){return function(e){return 1-t(1-e)}},es=function t(e,i){for(var n,s=e._first;s;)s instanceof cs?t(s,i):!s.vars.yoyoEase||s._yoyo&&s._repeat||s._yoyo===i||(s.timeline?t(s.timeline,i):(n=s._ease,s._ease=s._yEase,s._yEase=n,s._yoyo=i)),s=s._next},is=function(t,e){return t&&(Je(t)?t:Gn[t]||function(t){var e,i,n,s,r=(t+"").split("("),o=Gn[r[0]];return o&&r.length>1&&o.config?o.config.apply(null,~t.indexOf("{")?[Qn(r[1])]:(e=t,i=e.indexOf("(")+1,n=e.indexOf(")"),s=e.indexOf("(",i),e.substring(i,~s&&s<n?e.indexOf(")",n+1):n)).split(",").map(Yi)):Gn._CE&&Kn.test(t)?Gn._CE("",t):o}(t))||e},ns=function(t,e,i,n){void 0===i&&(i=function(t){return 1-e(1-t)}),void 0===n&&(n=function(t){return t<.5?e(2*t)/2:1-e(2*(1-t))/2});var s,r={easeIn:e,easeOut:i,easeInOut:n};return Di(t,(function(t){for(var e in Gn[t]=pi[t]=r,Gn[s=t.toLowerCase()]=i,r)Gn[s+("easeIn"===e?".in":"easeOut"===e?".out":".inOut")]=Gn[t+"."+e]=r[e]})),r},ss=function(t){return function(e){return e<.5?(1-t(1-2*e))/2:.5+t(2*(e-.5))/2}},rs=function t(e,i,n){var s=i>=1?i:1,r=(n||(e?.3:.45))/(i<1?i:1),o=r/We*(Math.asin(1/s)||0),a=function(t){return 1===t?1:s*Math.pow(2,-10*t)*Ge((t-o)*r)+1},l="out"===e?a:"in"===e?function(t){return 1-a(1-t)}:ss(a);return r=We/r,l.config=function(i,n){return t(e,i,n)},l},os=function t(e,i){void 0===i&&(i=1.70158);var n=function(t){return t?--t*t*((i+1)*t+i)+1:0},s="out"===e?n:"in"===e?function(t){return 1-n(1-t)}:ss(n);return s.config=function(i){return t(e,i)},s};Di("Linear,Quad,Cubic,Quart,Quint,Strong",(function(t,e){var i=e<5?e+1:e;ns(t+",Power"+(i-1),e?function(t){return Math.pow(t,i)}:function(t){return t},(function(t){return 1-Math.pow(1-t,i)}),(function(t){return t<.5?Math.pow(2*t,i)/2:1-Math.pow(2*(1-t),i)/2}))})),Gn.Linear.easeNone=Gn.none=Gn.Linear.easeIn,ns("Elastic",rs("in"),rs("out"),rs()),function(t,e){var i=function(i){return i<.36363636363636365?t*i*i:i<.7272727272727273?t*Math.pow(i-1.5/e,2)+.75:i<.9090909090909092?t*(i-=2.25/e)*i+.9375:t*Math.pow(i-2.625/e,2)+.984375};ns("Bounce",(function(t){return 1-i(1-t)}),i)}(7.5625,2.75),ns("Expo",(function(t){return Math.pow(2,10*(t-1))*t+t*t*t*t*t*t*(1-t)})),ns("Circ",(function(t){return-(Ue(1-t*t)-1)})),ns("Sine",(function(t){return 1===t?1:1-Ze(t*$e)})),ns("Back",os("in"),os("out"),os()),Gn.SteppedEase=Gn.steps=pi.SteppedEase={config:function(t,e){void 0===t&&(t=1);var i=1/t,n=t+(e?0:1),s=e?1:0;return function(t){return((n*_n(0,.99999999,t)|0)+s)*i}}},Ye.ease=Gn["quad.out"],Di("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",(function(t){return Ai+=t+","+t+"Params,"}));var as=function(t,e){this.id=Ve++,t._gsap=this,this.target=t,this.harness=e,this.get=e?e.get:zi,this.set=e?e.getSetter:Es},ls=function(){function t(t){this.vars=t,this._delay=+t.delay||0,(this._repeat=t.repeat===1/0?-2:t.repeat||0)&&(this._rDelay=t.repeatDelay||0,this._yoyo=!!t.yoyo||!!t.yoyoEase),this._ts=1,pn(this,+t.duration,1,1),this.data=t.data,Le&&(this._ctx=Le,Le.data.push(this)),je||Un.wake()}var e=t.prototype;return e.delay=function(t){return t||0===t?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+t-this._delay),this._delay=t,this):this._delay},e.duration=function(t){return arguments.length?this.totalDuration(this._repeat>0?t+(t+this._rDelay)*this._repeat:t):this.totalDuration()&&this._dur},e.totalDuration=function(t){return arguments.length?(this._dirty=0,pn(this,this._repeat<0?t:(t-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},e.totalTime=function(t,e){if(Zn(),!arguments.length)return this._tTime;var i=this._dp;if(i&&i.smoothChildTiming&&this._ts){for(an(this,t),!i._dp||i.parent||ln(i,this);i&&i.parent;)i.parent._time!==i._start+(i._ts>=0?i._tTime/i._ts:(i.totalDuration()-i._tTime)/-i._ts)&&i.totalTime(i._tTime,!0),i=i.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&t<this._tDur||this._ts<0&&t>0||!this._tDur&&!t)&&cn(this._dp,this,this._start-this._delay)}return(this._tTime!==t||!this._dur&&!e||this._initted&&Math.abs(this._zTime)===Xe||!t&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=t),Hi(this,t,e)),this},e.time=function(t,e){return arguments.length?this.totalTime(Math.min(this.totalDuration(),t+nn(this))%(this._dur+this._rDelay)||(t?this._dur:0),e):this._time},e.totalProgress=function(t,e){return arguments.length?this.totalTime(this.totalDuration()*t,e):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>=0&&this._initted?1:0},e.progress=function(t,e){return arguments.length?this.totalTime(this.duration()*(!this._yoyo||1&this.iteration()?t:1-t)+nn(this),e):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},e.iteration=function(t,e){var i=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(t-1)*i,e):this._repeat?sn(this._tTime,i)+1:1},e.timeScale=function(t,e){if(!arguments.length)return-1e-8===this._rts?0:this._rts;if(this._rts===t)return this;var i=this.parent&&this._ts?rn(this.parent._time,this):this._tTime;return this._rts=+t||0,this._ts=this._ps||-1e-8===t?0:this._rts,this.totalTime(_n(-Math.abs(this._delay),this._tDur,i),!1!==e),on(this),Qi(this)},e.paused=function(t){return arguments.length?(this._ps!==t&&(this._ps=t,t?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(Zn(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,1===this.progress()&&Math.abs(this._zTime)!==Xe&&(this._tTime-=Xe)))),this):this._ps},e.startTime=function(t){if(arguments.length){this._start=t;var e=this.parent||this._dp;return e&&(e._sort||!this.parent)&&cn(e,this,t-this._delay),this}return this._start},e.endTime=function(t){return this._start+(ii(t)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},e.rawTime=function(t){var e=this.parent||this._dp;return e?t&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?rn(e.rawTime(t),this):this._tTime:this._tTime},e.revert=function(t){void 0===t&&(t=Si);var e=Ae;return Ae=t,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(t),this.totalTime(-.01,t.suppressEvents)),"nested"!==this.data&&!1!==t.kill&&this.kill(),Ae=e,this},e.globalTime=function(t){for(var e=this,i=arguments.length?t:e.rawTime();e;)i=e._start+i/(Math.abs(e._ts)||1),e=e._dp;return!this.parent&&this._sat?this._sat.globalTime(t):i},e.repeat=function(t){return arguments.length?(this._repeat=t===1/0?-2:t,gn(this)):-2===this._repeat?1/0:this._repeat},e.repeatDelay=function(t){if(arguments.length){var e=this._time;return this._rDelay=t,gn(this),e?this.time(e):this}return this._rDelay},e.yoyo=function(t){return arguments.length?(this._yoyo=t,this):this._yoyo},e.seek=function(t,e){return this.totalTime(vn(this,t),ii(e))},e.restart=function(t,e){return this.play().totalTime(t?-this._delay:0,ii(e)),this._dur||(this._zTime=-1e-8),this},e.play=function(t,e){return null!=t&&this.seek(t,e),this.reversed(!1).paused(!1)},e.reverse=function(t,e){return null!=t&&this.seek(t||this.totalDuration(),e),this.reversed(!0).paused(!1)},e.pause=function(t,e){return null!=t&&this.seek(t,e),this.paused(!0)},e.resume=function(){return this.paused(!1)},e.reversed=function(t){return arguments.length?(!!t!==this.reversed()&&this.timeScale(-this._rts||(t?-1e-8:0)),this):this._rts<0},e.invalidate=function(){return this._initted=this._act=0,this._zTime=-1e-8,this},e.isActive=function(){var t,e=this.parent||this._dp,i=this._start;return!(e&&!(this._ts&&this._initted&&e.isActive()&&(t=e.rawTime(!0))>=i&&t<this.endTime(!0)-Xe))},e.eventCallback=function(t,e,i){var n=this.vars;return arguments.length>1?(e?(n[t]=e,i&&(n[t+"Params"]=i),"onUpdate"===t&&(this._onUpdate=e)):delete n[t],this):n[t]},e.then=function(t){var e=this;return new Promise((function(i){var n=Je(t)?t:qi,s=function(){var t=e.then;e.then=null,Je(n)&&(n=n(e))&&(n.then||n===e)&&(e.then=t),i(n),e.then=t};e._initted&&1===e.totalProgress()&&e._ts>=0||!e._tTime&&e._ts<0?s():e._prom=s}))},e.kill=function(){In(this)},t}();Xi(ls.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-1e-8,_prom:0,_ps:!1,_rts:1});var cs=function(t){function e(e,i){var n;return void 0===e&&(e={}),(n=t.call(this,e)||this).labels={},n.smoothChildTiming=!!e.smoothChildTiming,n.autoRemoveChildren=!!e.autoRemoveChildren,n._sort=ii(e.sortChildren),Re&&cn(e.parent||Re,Pe(n),i),e.reversed&&n.reverse(),e.paused&&n.paused(!0),e.scrollTrigger&&hn(Pe(n),e.scrollTrigger),n}Oe(e,t);var i=e.prototype;return i.to=function(t,e,i){return bn(0,arguments,this),this},i.from=function(t,e,i){return bn(1,arguments,this),this},i.fromTo=function(t,e,i,n){return bn(2,arguments,this),this},i.set=function(t,e,i){return e.duration=0,e.parent=this,Ui(e).repeatDelay||(e.repeat=0),e.immediateRender=!!e.immediateRender,new _s(t,e,vn(this,i),1),this},i.call=function(t,e,i){return cn(this,_s.delayedCall(0,t,e),i)},i.staggerTo=function(t,e,i,n,s,r,o){return i.duration=e,i.stagger=i.stagger||n,i.onComplete=r,i.onCompleteParams=o,i.parent=this,new _s(t,i,vn(this,s)),this},i.staggerFrom=function(t,e,i,n,s,r,o){return i.runBackwards=1,Ui(i).immediateRender=ii(i.immediateRender),this.staggerTo(t,e,i,n,s,r,o)},i.staggerFromTo=function(t,e,i,n,s,r,o,a){return n.startAt=i,Ui(n).immediateRender=ii(n.immediateRender),this.staggerTo(t,e,n,s,r,o,a)},i.render=function(t,e,i){var n,s,r,o,a,l,c,h,u,d,f,p,g=this._time,m=this._dirty?this.totalDuration():this._tDur,v=this._dur,b=t<=0?0:Fi(t),y=this._zTime<0!=t<0&&(this._initted||!v);if(this!==Re&&b>m&&t>=0&&(b=m),b!==this._tTime||i||y){if(g!==this._time&&v&&(b+=this._time-g,t+=this._time-g),n=b,u=this._start,l=!(h=this._ts),y&&(v||(g=this._zTime),(t||!e)&&(this._zTime=t)),this._repeat){if(f=this._yoyo,a=v+this._rDelay,this._repeat<-1&&t<0)return this.totalTime(100*a+t,e,i);if(n=Fi(b%a),b===m?(o=this._repeat,n=v):((o=~~(d=Fi(b/a)))&&o===d&&(n=v,o--),n>v&&(n=v)),d=sn(this._tTime,a),!g&&this._tTime&&d!==o&&this._tTime-d*a-this._dur<=0&&(d=o),f&&1&o&&(n=v-n,p=1),o!==d&&!this._lock){var _=f&&1&d,w=_===(f&&1&o);if(o<d&&(_=!_),g=_?0:b%v?v:b,this._lock=1,this.render(g||(p?0:Fi(o*a)),e,!v)._lock=0,this._tTime=b,!e&&this.parent&&Dn(this,"onRepeat"),this.vars.repeatRefresh&&!p&&(this.invalidate()._lock=1),g&&g!==this._time||l!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(v=this._dur,m=this._tDur,w&&(this._lock=2,g=_?v:-1e-4,this.render(g,!0),this.vars.repeatRefresh&&!p&&this.invalidate()),this._lock=0,!this._ts&&!l)return this;es(this,p)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(c=function(t,e,i){var n;if(i>e)for(n=t._first;n&&n._start<=i;){if("isPause"===n.data&&n._start>e)return n;n=n._next}else for(n=t._last;n&&n._start>=i;){if("isPause"===n.data&&n._start<e)return n;n=n._prev}}(this,Fi(g),Fi(n)),c&&(b-=n-(n=c._start))),this._tTime=b,this._time=n,this._act=!h,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=t,g=0),!g&&n&&!e&&!o&&(Dn(this,"onStart"),this._tTime!==b))return this;if(n>=g&&t>=0)for(s=this._first;s;){if(r=s._next,(s._act||n>=s._start)&&s._ts&&c!==s){if(s.parent!==this)return this.render(t,e,i);if(s.render(s._ts>0?(n-s._start)*s._ts:(s._dirty?s.totalDuration():s._tDur)+(n-s._start)*s._ts,e,i),n!==this._time||!this._ts&&!l){c=0,r&&(b+=this._zTime=-1e-8);break}}s=r}else{s=this._last;for(var x=t<0?t:n;s;
vendor: 4,248 bytes, line 4
4){if(r=s._prev,(s._act||x<=s._end)&&s._ts&&c!==s){if(s.parent!==this)return this.render(t,e,i);if(s.render(s._ts>0?(x-s._start)*s._ts:(s._dirty?s.totalDuration():s._tDur)+(x-s._start)*s._ts,e,i||Ae&&(s._initted||s._startAt)),n!==this._time||!this._ts&&!l){c=0,r&&(b+=this._zTime=x?-1e-8:Xe);break}}s=r}}if(c&&!e&&(this.pause(),c.render(n>=g?0:-1e-8)._zTime=n>=g?1:-1,this._ts))return this._start=u,on(this),this.render(t,e,i);this._onUpdate&&!e&&Dn(this,"onUpdate",!0),(b===m&&this._tTime>=this.totalDuration()||!b&&g)&&(u!==this._start&&Math.abs(h)===Math.abs(this._ts)||this._lock||((t||!v)&&(b===m&&this._ts>0||!b&&this._ts<0)&&Ki(this,1),e||t<0&&!g||!b&&!g&&m||(Dn(this,b===m&&t>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(b<m&&this.timeScale()>0)&&this._prom())))}return this},i.add=function(t,e){var i=this;if(Qe(e)||(e=vn(this,e,t)),!(t instanceof ls)){if(oi(t))return t.forEach((function(t){return i.add(t,e)})),this;if(Ke(t))return this.addLabel(t,e);if(!Je(t))return this;t=_s.delayedCall(0,t)}return this!==t?cn(this,t,e):this},i.getChildren=function(t,e,i,n){void 0===t&&(t=!0),void 0===e&&(e=!0),void 0===i&&(i=!0),void 0===n&&(n=-qe);for(var s=[],r=this._first;r;)r._start>=n&&(r instanceof _s?e&&s.push(r):(i&&s.push(r),t&&s.push.apply(s,r.getChildren(!0,e,i)))),r=r._next;return s},i.getById=function(t){for(var e=this.getChildren(1,1,1),i=e.length;i--;)if(e[i].vars.id===t)return e[i]},i.remove=function(t){return Ke(t)?this.removeLabel(t):Je(t)?this.killTweensOf(t):(t.parent===this&&Gi(this,t),t===this._recent&&(this._recent=this._last),Ji(this))},i.totalTime=function(e,i){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=Fi(Un.time-(this._ts>0?e/this._ts:(this.totalDuration()-e)/-this._ts))),t.prototype.totalTime.call(this,e,i),this._forcing=0,this):this._tTime},i.addLabel=function(t,e){return this.labels[t]=vn(this,e),this},i.removeLabel=function(t){return delete this.labels[t],this},i.addPause=function(t,e,i){var n=_s.delayedCall(0,e||_i,i);return n.data="isPause",this._hasPause=1,cn(this,n,vn(this,t))},i.removePause=function(t){var e=this._first;for(t=vn(this,t);e;)e._start===t&&"isPause"===e.data&&Ki(e),e=e._next},i.killTweensOf=function(t,e,i){for(var n=this.getTweensOf(t,i),s=n.length;s--;)hs!==n[s]&&n[s].kill(t,e);return this},i.getTweensOf=function(t,e){for(var i,n=[],s=Tn(t),r=this._first,o=Qe(e);r;)r instanceof _s?Ni(r._targets,s)&&(o?(!hs||r._initted&&r._ts)&&r.globalTime(0)<=e&&r.globalTime(r.totalDuration())>e:!e||r.isActive())&&n.push(r):(i=r.getTweensOf(s,e)).length&&n.push.apply(n,i),r=r._next;return n},i.tweenTo=function(t,e){e=e||{};var i,n=this,s=vn(n,t),r=e,o=r.startAt,a=r.onStart,l=r.onStartParams,c=r.immediateRender,h=_s.to(n,Xi({ease:e.ease||"none",lazy:!1,immediateRender:!1,time:s,overwrite:"auto",duration:e.duration||Math.abs((s-(o&&"time"in o?o.time:n._time))/n.timeScale())||Xe,onStart:function(){if(n.pause(),!i){var t=e.duration||Math.abs((s-(o&&"time"in o?o.time:n._time))/n.timeScale());h._dur!==t&&pn(h,t,0,1).render(h._time,!0,!0),i=1}a&&a.apply(h,l||[])}},e));return c?h.render(0):h},i.tweenFromTo=function(t,e,i){return this.tweenTo(e,Xi({startAt:{time:vn(this,t)}},i))},i.recent=function(){return this._recent},i.nextLabel=function(t){return void 0===t&&(t=this._time),zn(this,vn(this,t))},i.previousLabel=function(t){return void 0===t&&(t=this._time),zn(this,vn(this,t),1)},i.currentLabel=function(t){return arguments.length?this.seek(t,!0):this.previousLabel(this._time+Xe)},i.shiftChildren=function(t,e,i){void 0===i&&(i=0);for(var n,s=this._first,r=this.labels;s;)s._start>=i&&(s._start+=t,s._end+=t),s=s._next;if(e)for(n in r)r[n]>=i&&(r[n]+=t);return Ji(this)},i.invalidate=function(e){var i=this._first;for(this._lock=0;i;)i.invalidate(e),i=i._next;return t.prototype.invalidate.call(this,e)},i.clear=function(t){void 0===t&&(t=!0);for(var e,i=this._first;i;)e=i._next,this.remove(i),i=e;return this._dp&&(this._time=this._tTime=this._pTime=0),t&&(this.labels={}),Ji(this)},i.totalDuration=function(t){var e,i,n,s=0,r=this,o=r._last,a=qe;if(arguments.length)return r.timeScale((r._repeat<0?r.duration():r.totalDuration())/(r.reversed()?-t:t));if(r._dirty){for(n=r.parent;o;)e=o._prev,o._dirty&&o.totalDuration(),(i=o._start)>
vendor: 9,037 bytes, line 4
4a&&r._sort&&o._ts&&!r._lock?(r._lock=1,cn(r,o,i-o._delay,1)._lock=0):a=i,i<0&&o._ts&&(s-=i,(!n&&!r._dp||n&&n.smoothChildTiming)&&(r._start+=i/r._ts,r._time-=i,r._tTime-=i),r.shiftChildren(-i,!1,-Infinity),a=0),o._end>s&&o._ts&&(s=o._end),o=e;pn(r,r===Re&&r._time>s?r._time:s,1,1),r._dirty=0}return r._tDur},e.updateRoot=function(t){if(Re._ts&&(Hi(Re,rn(t,Re)),Be=Un.frame),Un.frame>=Oi){Oi+=He.autoSleep||120;var e=Re._first;if((!e||!e._ts)&&He.autoSleep&&Un._listeners.length<2){for(;e&&!e._ts;)e=e._next;e||Un.sleep()}}},e}(ls);Xi(cs.prototype,{_lock:0,_hasPause:0,_forcing:0});var hs,us,ds=function(t,e,i,n,s,r,o){var a,l,c,h,u,d,f,p,g=new zs(this._pt,t,e,0,1,Ps,null,s),m=0,v=0;for(g.b=i,g.e=n,i+="",(f=~(n+="").indexOf("random("))&&(n=Ln(n)),r&&(r(p=[i,n],t,e),i=p[0],n=p[1]),l=i.match(hi)||[];a=hi.exec(n);)h=a[0],u=n.substring(m,a.index),c?c=(c+1)%5:"rgba("===u.substr(-5)&&(c=1),h!==l[v++]&&(d=parseFloat(l[v-1])||0,g._pt={_next:g._pt,p:u||1===v?u:",",s:d,c:"="===h.charAt(1)?Bi(d,h)-d:parseFloat(h)-d,m:c&&c<4?Math.round:0},m=hi.lastIndex);return g.c=m<n.length?n.substring(m,n.length):"",g.fp=o,(ui.test(n)||f)&&(g.e=0),this._pt=g,g},fs=function(t,e,i,n,s,r,o,a,l,c){Je(n)&&(n=n(s||0,t,r));var h,u=t[e],d="get"!==i?i:Je(u)?l?t[e.indexOf("set")||!Je(t["get"+e.substr(3)])?e:"get"+e.substr(3)](l):t[e]():u,f=Je(u)?l?Ss:xs:ws;if(Ke(n)&&(~n.indexOf("random(")&&(n=Ln(n)),"="===n.charAt(1)&&((h=Bi(d,n)+(wn(d)||0))||0===h)&&(n=h)),!c||d!==n||us)return isNaN(d*n)||""===n?(!u&&!(e in t)&&vi(e,n),ds.call(this,t,e,d,n,f,a||He.stringFilter,l)):(h=new zs(this._pt,t,e,+d||0,n-(d||0),"boolean"==typeof u?Cs:Ms,0,f),l&&(h.fp=l),o&&h.modifier(o,this,t),this._pt=h)},ps=function(t,e,i,n,s,r){var o,a,l,c;if(Ci[t]&&!1!==(o=new Ci[t]).init(s,o.rawVars?e[t]:function(t,e,i,n,s){if(Je(t)&&(t=vs(t,s,e,i,n)),!ei(t)||t.style&&t.nodeType||oi(t)||ri(t))return Ke(t)?vs(t,s,e,i,n):t;var r,o={};for(r in t)o[r]=vs(t[r],s,e,i,n);return o}(e[t],n,s,r,i),i,n,r)&&(i._pt=a=new zs(i._pt,s,t,0,1,o.render,o,0,o.priority),i!==Ne))for(l=i._ptLookup[i._targets.indexOf(s)],c=o._props.length;c--;)l[o._props[c]]=a;return o},gs=function t(e,i,n){var s,r,o,a,l,c,h,u,d,f,p,g,m,v=e.vars,b=v.ease,y=v.startAt,_=v.immediateRender,w=v.lazy,x=v.onUpdate,S=v.runBackwards,T=v.yoyoEase,E=v.keyframes,M=v.autoRevert,C=e._dur,P=e._startAt,O=e._targets,k=e.parent,A=k&&"nested"===k.data?k.vars.targets:O,L="auto"===e._overwrite&&!ke,R=e.timeline;if(R&&(!E||!b)&&(b="none"),e._ease=is(b,Ye.ease),e._yEase=T?ts(is(!0===T?b:T,Ye.ease)):0,T&&e._yoyo&&!e._repeat&&(T=e._yEase,e._yEase=e._ease,e._ease=T),e._from=!R&&!!v.runBackwards,!R||E&&!v.stagger){if(g=(u=O[0]?Ri(O[0]).harness:0)&&v[u.prop],s=Vi(v,Ti),P&&(P._zTime<0&&P.progress(1),i<0&&S&&_&&!M?P.render(-1,!0):P.revert(S&&C?xi:wi),P._lazy=0),y){if(Ki(e._startAt=_s.set(O,Xi({data:"isStart",overwrite:!1,parent:k,immediateRender:!0,lazy:!P&&ii(w),startAt:null,delay:0,onUpdate:x&&function(){return Dn(e,"onUpdate")},stagger:0},y))),e._startAt._dp=0,e._startAt._sat=e,i<0&&(Ae||!_&&!M)&&e._startAt.revert(xi),_&&C&&i<=0&&n<=0)return void(i&&(e._zTime=i))}else if(S&&C&&!P)if(i&&(_=!1),o=Xi({overwrite:!1,data:"isFromStart",lazy:_&&!P&&ii(w),immediateRender:_,stagger:0,parent:k},s),g&&(o[u.prop]=g),Ki(e._startAt=_s.set(O,o)),e._startAt._dp=0,e._startAt._sat=e,i<0&&(Ae?e._startAt.revert(xi):e._startAt.render(-1,!0)),e._zTime=i,_){if(!i)return}else t(e._startAt,Xe,Xe);for(e._pt=e._ptCache=0,w=C&&ii(w)||w&&!C,r=0;r<O.length;r++){if(h=(l=O[r])._gsap||Li(O)[r]._gsap,e._ptLookup[r]=f={},Mi[h.id]&&Ei.length&&ji(),p=A===O?r:A.indexOf(l),u&&!1!==(d=new u).init(l,g||s,e,p,A)&&(e._pt=a=new zs(e._pt,l,d.name,0,1,d.render,d,0,d.priority),d._props.forEach((function(t){f[t]=a})),d.priority&&(c=1)),!u||g)for(o in s)Ci[o]&&(d=ps(o,s,e,p,l,A))?d.priority&&(c=1):f[o]=a=fs.call(e,l,o,"get",s[o],p,A,0,v.stringFilter);e._op&&e._op[r]&&e.kill(l,e._op[r]),L&&e._pt&&(hs=e,Re.killTweensOf(l,f,e.globalTime(i)),m=!e.parent,hs=0),e._pt&&w&&(Mi[h.id]=1)}c&&Rs(e),e._onInit&&e._onInit(e)}e._onUpdate=x,e._initted=(!e._op||e._pt)&&!m,E&&i<=0&&R.render(qe,!0,!0)},ms=function(t,e,i,n){var s,r,o=e.ease||n||"power1.inOut";if(oi(e))r=i[t]||(i[t]=[]),e.forEach((function(t,i){return r.push({t:i/(e.length-1)*100,v:t,e:o})}));else for(s in e)r=i[s]||(i[s]=[]),"ease"===s||r.push({t:parseFloat(t),v:e[s],e:o})},vs=function(t,e,i,n,s){return Je(t)?t.call(e,i,n,s):Ke(t)&&~t.indexOf("random(")?Ln(t):t},bs=Ai+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",ys={};Di(bs+",id,stagger,delay,duration,paused,scrollTrigger",(function(t){return ys[t]=1}));var _s=function(t){function e(e,i,n,s){var r;"number"==typeof i&&(n.duration=i,i=n,n=null);var o,a,l,c,h,u,d,f,p=(r=t.call(this,s?i:Ui(i))||this).vars,g=p.duration,m=p.delay,v=p.immediateRender,b=p.stagger,y=p.overwrite,_=p.keyframes,w=p.defaults,x=p.scrollTrigger,S=p.yoyoEase,T=i.parent||Re,E=(oi(e)||ri(e)?Qe(e[0]):"length"in i)?[e]:Tn(e);if(r._targets=E.length?Li(E):bi("GSAP target "+e+" not found. https://gsap.com",!He.nullTargetWarn)||[],r._ptLookup=[],r._overwrite=y,_||b||si(g)||si(m)){if(i=r.vars,(o=r.timeline=new cs({data:"nested",defaults:w||{},targets:T&&"nested"===T.data?T.vars.targets:E})).kill(),o.parent=o._dp=Pe(r),o._start=0,b||si(g)||si(m)){if(c=E.length,d=b&&Cn(b),ei(b))for(h in b)~bs.indexOf(h)&&(f||(f={}),f[h]=b[h]);for(a=0;a<c;a++)(l=Vi(i,ys)).stagger=0,S&&(l.yoyoEase=S),f&&Wi(l,f),u=E[a],l.duration=+vs(g,Pe(r),a,u,E),l.delay=(+vs(m,Pe(r),a,u,E)||0)-r._delay,!b&&1===c&&l.delay&&(r._delay=m=l.delay,r._start+=m,l.delay=0),o.to(u,l,d?d(a,u,E):0),o._ease=Gn.none;o.duration()?g=m=0:r.timeline=0}else if(_){Ui(Xi(o.vars.defaults,{ease:"none"})),o._ease=is(_.ease||i.ease||"none");var M,C,P,O=0;if(oi(_))_.forEach((function(t){return o.to(E,t,">")})),o.duration();else{for(h in l={},_)"ease"===h||"easeEach"===h||ms(h,_[h],l,_.easeEach);for(h in l)for(M=l[h].sort((function(t,e){return t.t-e.t})),O=0,a=0;a<M.length;a++)(P={ease:(C=M[a]).e,duration:(C.t-(a?M[a-1].t:0))/100*g})[h]=C.v,o.to(E,P,O),O+=P.duration;o.duration()<g&&o.to({},{duration:g-o.duration()})}}g||r.duration(g=o.duration())}else r.timeline=0;return!0!==y||ke||(hs=Pe(r),Re.killTweensOf(E),hs=0),cn(T,Pe(r),n),i.reversed&&r.reverse(),i.paused&&r.paused(!0),(v||!g&&!_&&r._start===Fi(T._time)&&ii(v)&&en(Pe(r))&&"nested"!==T.data)&&(r._tTime=-1e-8,r.render(Math.max(0,-m)||0)),x&&hn(Pe(r),x),r}Oe(e,t);var i=e.prototype;return i.render=function(t,e,i){var n,s,r,o,a,l,c,h,u,d=this._time,f=this._tDur,p=this._dur,g=t<0,m=t>f-Xe&&!g?f:t<Xe?0:t;if(p){if(m!==this._tTime||!t||i||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==g||this._lazy){if(n=m,h=this.timeline,this._repeat){if(o=p+this._rDelay,this._repeat<-1&&g)return this.totalTime(100*o+t,e,i);if(n=Fi(m%o),m===f?(r=this._repeat,n=p):(r=~~(a=Fi(m/o)))&&r===a?(n=p,r--):n>p&&(n=p),(l=this._yoyo&&1&r)&&(u=this._yEase,n=p-n),a=sn(this._tTime,o),n===d&&!i&&this._initted&&r===a)return this._tTime=m,this;r!==a&&(h&&this._yEase&&es(h,l),this.vars.repeatRefresh&&!l&&!this._lock&&n!==o&&this._initted&&(this._lock=i=1,this.render(Fi(o*r),!0).invalidate()._lock=0))}if(!this._initted){if(un(this,g?t:n,i,e,m))return this._tTime=0,this;if(!(d===this._time||i&&this.vars.repeatRefresh&&r!==a))return this;if(p!==this._dur)return this.render(t,e,i)}if(this._tTime=m,this._time=n,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=c=(u||this._ease)(n/p),this._from&&(this.ratio=c=1-c),n&&!d&&!e&&!r&&(Dn(this,"onStart"),this._tTime!==m))return this;for(s=this._pt;s;)s.r(c,s.d),s=s._next;h&&h.render(t<0?t:h._dur*h._ease(n/this._dur),e,i)||this._startAt&&(this._zTime=t),this._onUpdate&&!e&&(g&&tn(this,t,0,i),Dn(this,"onUpdate")),this._repeat&&r!==a&&this.vars.onRepeat&&!e&&this.parent&&Dn(this,"onRepeat"),m!==this._tDur&&m||this._tTime!==m||(g&&!this._onUpdate&&tn(this,t,0,!0),(t||!p)&&(m===this._tDur&&this._ts>0||!m&&this._ts<0)&&Ki(this,1),e||g&&!d||!(m||d||l)||(Dn(this,m===f?"onComplete":"onReverseComplete",!0),this._prom&&!(m<f&&this.timeScale()>0)&&this._prom()))}}else!function(t,e,i,n){var s,r,o,a=t.ratio,l=e<0||!e&&(!t._start&&dn(t)&&(t._initted||!fn(t))||(t._ts<0||t._dp._ts<0)&&!fn(t))?0:1,c=t._rDelay,h=0;if(c&&t._repeat&&(h=_n(0,t._tDur,e),r=sn(h,c),t._yoyo&&1&r&&(l=1-l),r!==sn(t._tTime,c)&&(a=1-l,t.vars.repeatRefresh&&t._initted&&t.invalidate())),l!==a||Ae||n||t._zTime===Xe||!e&&t._zTime){if(!t._initted&&un(t,e,n,i,h))return;for(o=t._zTime,t._zTime=e||(i?Xe:0),i||(i=e&&!o),t.ratio=l,t._from&&(l=1-l),t._time=0,t._tTime=h,s=t._pt;s;)s.r(l,s.d),s=s._next;e<0&&tn(t,e,0,!0),t._onUpdate&&!i&&Dn(t,"onUpdate"),h&&t._repeat&&!i&&t.parent&&Dn(t,"onRepeat"),(e>=t._tDur||e<0)&&t.ratio===l&&(l&&Ki(t,1),i||Ae||(Dn(t,l?"onComplete":"onReverseComplete",!0),t._prom&&t._prom()))}else t._zTime||(t._zTime=e)}(this,t,e,i);return this},i.targets=function(){return this._targets},i.invalidate=function(e){return(!e||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(e),t.prototype.invalidate.call(this,e)}
vendor: 1,066 bytes, line 4
4,i.resetTo=function(t,e,i,n,s){je||Un.wake(),this._ts||this.play();var r=Math.min(this._dur,(this._dp._time-this._start)*this._ts);return this._initted||gs(this,r),function(t,e,i,n,s,r,o,a){var l,c,h,u,d=(t._pt&&t._ptCache||(t._ptCache={}))[e];if(!d)for(d=t._ptCache[e]=[],h=t._ptLookup,u=t._targets.length;u--;){if((l=h[u][e])&&l.d&&l.d._pt)for(l=l.d._pt;l&&l.p!==e&&l.fp!==e;)l=l._next;if(!l)return us=1,t.vars[e]="+=0",gs(t,o),us=0,a?bi(e+" not eligible for reset"):1;d.push(l)}for(u=d.length;u--;)(l=(c=d[u])._pt||c).s=!n&&0!==n||s?l.s+(n||0)+r*l.c:n,l.c=i-l.s,c.e&&(c.e=Ii(i)+wn(c.e)),c.b&&(c.b=l.s+wn(c.b))}(this,t,e,i,n,this._ease(r/this._dur),r,s)?this.resetTo(t,e,i,n,1):(an(this,0),this.parent||Zi(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},i.kill=function(t,e){if(void 0===e&&(e="all"),!(t||e&&"all"!==e))return this._lazy=this._pt=0,this.parent?In(this):this.scrollTrigger&&this.scrollTrigger.kill(!!Ae),this;if(this.timeline){var i=this.timeline.totalDuration();return this.timeline.killTweensOf(t,e,hs&&!0!==hs.vars.over
vendor: 5,975 bytes, line 4
4write)._first||In(this),this.parent&&i!==this.timeline.totalDuration()&&pn(this,this._dur*this.timeline._tDur/i,0,1),this}var n,s,r,o,a,l,c,h=this._targets,u=t?Tn(t):h,d=this._ptLookup,f=this._pt;if((!e||"all"===e)&&function(t,e){for(var i=t.length,n=i===e.length;n&&i--&&t[i]===e[i];);return i<0}(h,u))return"all"===e&&(this._pt=0),In(this);for(n=this._op=this._op||[],"all"!==e&&(Ke(e)&&(a={},Di(e,(function(t){return a[t]=1})),e=a),e=function(t,e){var i,n,s,r,o=t[0]?Ri(t[0]).harness:0,a=o&&o.aliases;if(!a)return e;for(n in i=Wi({},e),a)if(n in i)for(s=(r=a[n].split(",")).length;s--;)i[r[s]]=i[n];return i}(h,e)),c=h.length;c--;)if(~u.indexOf(h[c]))for(a in s=d[c],"all"===e?(n[c]=e,o=s,r={}):(r=n[c]=n[c]||{},o=e),o)(l=s&&s[a])&&("kill"in l.d&&!0!==l.d.kill(a)||Gi(this,l,"_pt"),delete s[a]),"all"!==r&&(r[a]=1);return this._initted&&!this._pt&&f&&In(this),this},e.to=function(t,i){return new e(t,i,arguments[2])},e.from=function(t,e){return bn(1,arguments)},e.delayedCall=function(t,i,n,s){return new e(i,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:t,onComplete:i,onReverseComplete:i,onCompleteParams:n,onReverseCompleteParams:n,callbackScope:s})},e.fromTo=function(t,e,i){return bn(2,arguments)},e.set=function(t,i){return i.duration=0,i.repeatDelay||(i.repeat=0),new e(t,i)},e.killTweensOf=function(t,e,i){return Re.killTweensOf(t,e,i)},e}(ls);Xi(_s.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0}),Di("staggerTo,staggerFrom,staggerFromTo",(function(t){_s[t]=function(){var e=new cs,i=xn.call(arguments,0);return i.splice("staggerFromTo"===t?5:4,0,0),e[t].apply(e,i)}}));var ws=function(t,e,i){return t[e]=i},xs=function(t,e,i){return t[e](i)},Ss=function(t,e,i,n){return t[e](n.fp,i)},Ts=function(t,e,i){return t.setAttribute(e,i)},Es=function(t,e){return Je(t[e])?xs:ti(t[e])&&t.setAttribute?Ts:ws},Ms=function(t,e){return e.set(e.t,e.p,Math.round(1e6*(e.s+e.c*t))/1e6,e)},Cs=function(t,e){return e.set(e.t,e.p,!!(e.s+e.c*t),e)},Ps=function(t,e){var i=e._pt,n="";if(!t&&e.b)n=e.b;else if(1===t&&e.e)n=e.e;else{for(;i;)n=i.p+(i.m?i.m(i.s+i.c*t):Math.round(1e4*(i.s+i.c*t))/1e4)+n,i=i._next;n+=e.c}e.set(e.t,e.p,n,e)},Os=function(t,e){for(var i=e._pt;i;)i.r(t,i.d),i=i._next},ks=function(t,e,i,n){for(var s,r=this._pt;r;)s=r._next,r.p===n&&r.modifier(t,e,i),r=s},As=function(t){for(var e,i,n=this._pt;n;)i=n._next,n.p===t&&!n.op||n.op===t?Gi(this,n,"_pt"):n.dep||(e=1),n=i;return!e},Ls=function(t,e,i,n){n.mSet(t,e,n.m.call(n.tween,i,n.mt),n)},Rs=function(t){for(var e,i,n,s,r=t._pt;r;){for(e=r._next,i=n;i&&i.pr>r.pr;)i=i._next;(r._prev=i?i._prev:s)?r._prev._next=r:n=r,(r._next=i)?i._prev=r:s=r,r=e}t._pt=n},zs=function(){function t(t,e,i,n,s,r,o,a,l){this.t=e,this.s=n,this.c=s,this.p=i,this.r=r||Ms,this.d=o||this,this.set=a||ws,this.pr=l||0,this._next=t,t&&(t._prev=this)}return t.prototype.modifier=function(t,e,i){this.mSet=this.mSet||this.set,this.set=Ls,this.m=t,this.mt=i,this.tween=e},t}();Di(Ai+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",(function(t){return Ti[t]=1})),pi.TweenMax=pi.TweenLite=_s,pi.TimelineLite=pi.TimelineMax=cs,Re=new cs({sortChildren:!1,defaults:Ye,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0}),He.stringFilter=Vn;var Ds=[],Is={},Fs=[],Bs=0,Ns=0,js=function(t){return(Is[t]||Fs).map((function(t){return t()}))},Hs=function(){var t=Date.now(),e=[];t-Bs>2&&(js("matchMediaInit"),Ds.forEach((function(t){var i,n,s,r,o=t.queries,a=t.conditions;for(n in o)(i=ze.matchMedia(o[n]).matches)&&(s=1),i!==a[n]&&(a[n]=i,r=1);r&&(t.revert(),s&&e.push(t))})),js("matchMediaRevert"),e.forEach((function(t){return t.onMatch(t,(function(e){return t.add(null,e)}))})),Bs=t,js("matchMedia"))},Ys=function(){function t(t,e){this.selector=e&&En(e),this.data=[],this._r=[],this.isReverted=!1,this.id=Ns++,t&&this.add(t)}var e=t.prototype;return e.add=function(t,e,i){Je(t)&&(i=e,e=t,t=Je);var n=this,s=function(){var t,s=Le,r=n.selector;return s&&s!==n&&s.data.push(n),i&&(n.selector=En(i)),Le=n,t=e.apply(n,arguments),Je(t)&&n._r.push(t),Le=s,n.selector=r,n.isReverted=!1,t};return n.last=s,t===Je?s(n,(function(t){return n.add(null,t)})):t?n[t]=s:s},e.ignore=function(t){var e=Le;Le=null,t(this),Le=e},e.getTweens=function(){var e=[];return this.data.forEach((function(i){return i instanceof t?e.push.apply(e,i.getTweens()):i instanceof _s&&!(i.parent&&"nested"===i.parent.data)&&e.push(i)})),e},e.clear=function(){this._r.length=this.data.length=0},e.kill=function(t,e){var i=this;if(t?function(){for(var e,n=i.getTweens(),s=i.data.length;s--;)"isFlip"===(e=i.data[s]).data&&(e.revert(),e.getChildren(!0,!0,!1).forEach((function(t){return n.splice(n.indexOf(t),1)})));for(n.map((function(t){return{g:t._dur||t._delay||t._sat&&!t._sat.vars.immediateRender?t.globalTime(0):-1/0,t:t}})).sort((function(t,e){return e.g-t.g||-1/0})).forEach((function(e){return e.t.revert(t)})),s=i.data.length;s--;)(e=i.data[s])instanceof cs?"nested"!==e.data&&(e.scrollTrigger&&e.scrollTrigger.revert(),e.kill()):!(e instanceof _s)&&e.revert&&e.revert(t);i._r.forEach((function(e){return e(t,i)})),i.isReverted=!0}():this.data.forEach((function(t){return t.kill&&t.kill()})),this.clear(),e)for(var n=Ds.length;n--;)Ds[n].id===this.id&&Ds.splice(n,1)},e.revert=function(t){this.kill(t||{})},t}(),qs=function(){function t(t){this.contexts=[],this.scope=t,Le&&Le.data.push(this)}var e=t.prototype;return e.add=function(t,e,i){ei(t)||(t={matches:t});var n,s,r,o=new Ys(0,i||this.scope),a=o.conditions={};for(s in Le&&!o.selector&&(o.selector=Le.selector),this.contexts.push(o),e=o.add("onMatch",e),o.queries=t,t)"all"===s?r=1:(n=ze.matchMedia(t[s]))&&(Ds.indexOf(o)<0&&Ds.push(o),(a[s]=n.matches)&&(r=1),n.addListener?n.addListener(Hs):n.addEventListener("change",Hs));return r&&e(o,(function(t){return o.add(null,t)})),this},e.revert=function(t){this.kill(t||{})}
vendor: 4,513 bytes, line 4
4,e.kill=function(t){this.contexts.forEach((function(e){return e.kill(t,!0)}))},t}(),Xs={registerPlugin:function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];e.forEach((function(t){return Bn(t)}))},timeline:function(t){return new cs(t)},getTweensOf:function(t,e){return Re.getTweensOf(t,e)},getProperty:function(t,e,i,n){Ke(t)&&(t=Tn(t)[0]);var s=Ri(t||{}).get,r=i?qi:Yi;return"native"===i&&(i=""),t?e?r((Ci[e]&&Ci[e].get||s)(t,e,i,n)):function(e,i,n){return r((Ci[e]&&Ci[e].get||s)(t,e,i,n))}:t},quickSetter:function(t,e,i){if((t=Tn(t)).length>1){var n=t.map((function(t){return Vs.quickSetter(t,e,i)})),s=n.length;return function(t){for(var e=s;e--;)n[e](t)}}t=t[0]||{};var r=Ci[e],o=Ri(t),a=o.harness&&(o.harness.aliases||{})[e]||e,l=r?function(e){var n=new r;Ne._pt=0,n.init(t,i?e+i:e,Ne,0,[t]),n.render(1,n),Ne._pt&&Os(1,Ne)}:o.set(t,a);return r?l:function(e){return l(t,a,i?e+i:e,o,1)}},quickTo:function(t,e,i){var n,s=Vs.to(t,Xi(((n={})[e]="+=0.1",n.paused=!0,n.stagger=0,n),i||{})),r=function(t,i,n){return s.resetTo(e,t,i,n)};return r.tween=s,r},isTweening:function(t){return Re.getTweensOf(t,!0).length>0},defaults:function(t){return t&&t.ease&&(t.ease=is(t.ease,Ye.ease)),$i(Ye,t||{})},config:function(t){return $i(He,t||{})},registerEffect:function(t){var e=t.name,i=t.effect,n=t.plugins,s=t.defaults,r=t.extendTimeline;(n||"").split(",").forEach((function(t){return t&&!Ci[t]&&!pi[t]&&bi(e+" effect requires "+t+" plugin.")})),Pi[e]=function(t,e,n){return i(Tn(t),Xi(e||{},s),n)},r&&(cs.prototype[e]=function(t,i,n){return this.add(Pi[e](t,ei(i)?i:(n=i)&&{},this),n)})},registerEase:function(t,e){Gn[t]=is(e)},parseEase:function(t,e){return arguments.length?is(t,e):Gn},getById:function(t){return Re.getById(t)},exportRoot:function(t,e){void 0===t&&(t={});var i,n,s=new cs(t);for(s.smoothChildTiming=ii(t.smoothChildTiming),Re.remove(s),s._dp=0,s._time=s._tTime=Re._time,i=Re._first;i;)n=i._next,!e&&!i._dur&&i instanceof _s&&i.vars.onComplete===i._targets[0]||cn(s,i,i._start-i._delay),i=n;return cn(Re,s,0),s},context:function(t,e){return t?new Ys(t,e):Le},matchMedia:function(t){return new qs(t)},matchMediaRefresh:function(){return Ds.forEach((function(t){var e,i,n=t.conditions;for(i in n)n[i]&&(n[i]=!1,e=1);e&&t.revert()}))||Hs()},addEventListener:function(t,e){var i=Is[t]||(Is[t]=[]);~i.indexOf(e)||i.push(e)},removeEventListener:function(t,e){var i=Is[t],n=i&&i.indexOf(e);n>=0&&i.splice(n,1)},utils:{wrap:function t(e,i,n){var s=i-e;return oi(e)?An(e,t(0,e.length),i):yn(n,(function(t){return(s+(t-e)%s)%s+e}))},wrapYoyo:function t(e,i,n){var s=i-e,r=2*s;return oi(e)?An(e,t(0,e.length-1),i):yn(n,(function(t){return e+((t=(r+(t-e)%r)%r||0)>s?r-t:t)}))},distribute:Cn,random:kn,snap:On,normalize:function(t,e,i){return Rn(t,e,0,1,i)},getUnit:wn,clamp:function(t,e,i){return yn(i,(function(i){return _n(t,e,i)}))},splitColor:Yn,toArray:Tn,selector:En,mapRange:Rn,pipe:function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return function(t){return e.reduce((function(t,e){return e(t)}),t)}},unitize:function(t,e){return function(i){return t(parseFloat(i))+(e||wn(i))}},interpolate:function t(e,i,n,s){var r=isNaN(e+i)?0:function(t){return(1-t)*e+t*i};if(!r){var o,a,l,c,h,u=Ke(e),d={};if(!0===n&&(s=1)&&(n=null),u)e={p:e},i={p:i};else if(oi(e)&&!oi(i)){for(l=[],c=e.length,h=c-2,a=1;a<c;a++)l.push(t(e[a-1],e[a]));c--,r=function(t){t*=c;var e=Math.min(h,~~t);return l[e](t-e)},n=i}else s||(e=Wi(oi(e)?[]:{},e));if(!l){for(o in i)fs.call(d,e,o,"get",i[o]);r=function(t){return Os(t,d)||(u?e.p:e)}}}return yn(n,r)},shuffle:Mn},install:mi,effects:Pi,ticker:Un,updateRoot:cs.updateRoot,plugins:Ci,globalTimeline:Re,core:{PropTween:zs,globals:yi,Tween:_s,Timeline:cs,Animation:ls,getCache:Ri,_removeLinkedListItem:Gi,reverting:function(){return Ae},context:function(t){return t&&Le&&(Le.data.push(t),t._ctx=Le),Le},suppressOverwrites:function(t){return ke=t}}};Di("to,from,fromTo,delayedCall,set,killTweensOf",(function(t){return Xs[t]=_s[t]})),Un.add(cs.updateRoot),Ne=Xs.to({},{duration:0});var Ws=function(t,e){for(var i=t._pt;i&&i.p!==e&&i.op!==e&&i.fp!==e;)i=i._next;return i},$s=function(t,e){return{name:t,rawVars:1,init:function(t,i,n){n._onInit=function(t){var n,s;if(Ke(i)&&(n={},Di(i,(function(t){return n[t]=1})),i=n),e){for(s in n={},i)n[s]=e(i[s]);i=n}!function(t,e){var i,n,s,r=t._targets;for(i in e)for(n=r.length;n--;)(s=t._ptLookup[n][i])&&(s=s.d)&&(s._pt&&(s=Ws(s,i)),s&&s.modifier&&s.modifier(e[i],t,r[n],i))}(t,i)}}}}
vendor: 4,725 bytes, line 4
4,Vs=Xs.registerPlugin({name:"attr",init:function(t,e,i,n,s){var r,o,a;for(r in this.tween=i,e)a=t.getAttribute(r)||"",(o=this.add(t,"setAttribute",(a||0)+"",e[r],n,s,0,0,r)).op=r,o.b=a,this._props.push(r)},render:function(t,e){for(var i=e._pt;i;)Ae?i.set(i.t,i.p,i.b,i):i.r(t,i.d),i=i._next}},{name:"endArray",init:function(t,e){for(var i=e.length;i--;)this.add(t,i,t[i]||0,e[i],0,0,0,0,0,1)}},$s("roundProps",Pn),$s("modifiers"),$s("snap",On))||Xs;_s.version=cs.version=Vs.version="3.12.7",Fe=1,ni()&&Zn(),Gn.Power0,Gn.Power1,Gn.Power2,Gn.Power3,Gn.Power4,Gn.Linear,Gn.Quad,Gn.Cubic,Gn.Quart,Gn.Quint,Gn.Strong,Gn.Elastic,Gn.Back,Gn.SteppedEase,Gn.Bounce,Gn.Sine,Gn.Expo,Gn.Circ;var Us,Zs,Gs,Ks,Js,Qs,tr,er,ir={},nr=180/Math.PI,sr=Math.PI/180,rr=Math.atan2,or=/([A-Z])/g,ar=/(left|right|width|margin|padding|x)/i,lr=/[\s,\(]\S/,cr={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},hr=function(t,e){return e.set(e.t,e.p,Math.round(1e4*(e.s+e.c*t))/1e4+e.u,e)},ur=function(t,e){return e.set(e.t,e.p,1===t?e.e:Math.round(1e4*(e.s+e.c*t))/1e4+e.u,e)},dr=function(t,e){return e.set(e.t,e.p,t?Math.round(1e4*(e.s+e.c*t))/1e4+e.u:e.b,e)},fr=function(t,e){var i=e.s+e.c*t;e.set(e.t,e.p,~~(i+(i<0?-.5:.5))+e.u,e)},pr=function(t,e){return e.set(e.t,e.p,t?e.e:e.b,e)},gr=function(t,e){return e.set(e.t,e.p,1!==t?e.b:e.e,e)},mr=function(t,e,i){return t.style[e]=i},vr=function(t,e,i){return t.style.setProperty(e,i)},br=function(t,e,i){return t._gsap[e]=i},yr=function(t,e,i){return t._gsap.scaleX=t._gsap.scaleY=i},_r=function(t,e,i,n,s){var r=t._gsap;r.scaleX=r.scaleY=i,r.renderTransform(s,r)},wr=function(t,e,i,n,s){var r=t._gsap;r[e]=i,r.renderTransform(s,r)},xr="transform",Sr=xr+"Origin",Tr=function t(e,i){var n=this,s=this.target,r=s.style,o=s._gsap;if(e in ir&&r){if(this.tfm=this.tfm||{},"transform"===e)return cr.transform.split(",").forEach((function(e){return t.call(n,e,i)}));if(~(e=cr[e]||e).indexOf(",")?e.split(",").forEach((function(t){return n.tfm[t]=Yr(s,t)})):this.tfm[e]=o.x?o[e]:Yr(s,e),e===Sr&&(this.tfm.zOrigin=o.zOrigin),this.props.indexOf(xr)>=0)return;o.svg&&(this.svgo=s.getAttribute("data-svg-origin"),this.props.push(Sr,i,"")),e=xr}(r||i)&&this.props.push(e,i,r[e])},Er=function(t){t.translate&&(t.removeProperty("translate"),t.removeProperty("scale"),t.removeProperty("rotate"))},Mr=function(){var t,e,i=this.props,n=this.target,s=n.style,r=n._gsap;for(t=0;t<i.length;t+=3)i[t+1]?2===i[t+1]?n[i[t]](i[t+2]):n[i[t]]=i[t+2]:i[t+2]?s[i[t]]=i[t+2]:s.removeProperty("--"===i[t].substr(0,2)?i[t]:i[t].replace(or,"-$1").toLowerCase());if(this.tfm){for(e in this.tfm)r[e]=this.tfm[e];r.svg&&(r.renderTransform(),n.setAttribute("data-svg-origin",this.svgo||"")),(t=tr())&&t.isStart||s[xr]||(Er(s),r.zOrigin&&s[Sr]&&(s[Sr]+=" "+r.zOrigin+"px",r.zOrigin=0,r.renderTransform()),r.uncache=1)}},Cr=function(t,e){var i={target:t,props:[],revert:Mr,save:Tr};return t._gsap||Vs.core.getCache(t),e&&t.style&&t.nodeType&&e.split(",").forEach((function(t){return i.save(t)})),i},Pr=function(t,e){var i=Zs.createElementNS?Zs.createElementNS((e||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),t):Zs.createElement(t);return i&&i.style?i:Zs.createElement(t)},Or=function t(e,i,n){var s=getComputedStyle(e);return s[i]||s.getPropertyValue(i.replace(or,"-$1").toLowerCase())||s.getPropertyValue(i)||!n&&t(e,Ar(i)||i,1)||""},kr="O,Moz,ms,Ms,Webkit".split(","),Ar=function(t,e,i){var n=(e||Js).style,s=5;if(t in n&&!i)return t;for(t=t.charAt(0).toUpperCase()+t.substr(1);s--&&!(kr[s]+t in n););return s<0?null:(3===s?"ms":s>=0?kr[s]:"")+t},Lr=function(){"undefined"!=typeof window&&window.document&&(Us=window,Zs=Us.document,Gs=Zs.documentElement,Js=Pr("div")||{style:{}},Pr("div"),xr=Ar(xr),Sr=xr+"Origin",Js.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",er=!!Ar("perspective"),tr=Vs.core.reverting,Ks=1)},Rr=function(t){var e,i=t.ownerSVGElement,n=Pr("svg",i&&i.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),s=t.cloneNode(!0);s.style.display="block",n.appendChild(s),Gs.appendChild(n);try{e=s.getBBox()}catch(t){}return n.removeChild(s),Gs.removeChild(n),e},zr=function(t,e){for(var i=e.length;i--;)if(t.hasAttribute(e[i]))return t.getAttribute(e[i])},Dr=function(t){var e,i;try{e=t.getBBox()}catch(n){e=Rr(t),i=1}return e&&(e.width||e.height)||i||(e=Rr(t)),!e||e.width||e.x||e.y?e:{x:+zr(t,["x","cx","x1"])||0,y:+zr(t,["y","cy","y1"])||0,width:0,height:0}},Ir=function(t){return!(!t.getCTM||t.parentNode&&!t.ownerSVGElement||!Dr(t))},Fr=function(t,e){if(e){var i,n=t.style;e in ir&&e!==Sr&&(e=xr),n.removeProperty?("ms"!==(i=e.substr(0,2))&&"webkit"!==e.substr(0,6)||(e="-"+e),n.removeProperty("--"===i?e:e.replace(or,"-$1").toLowerCase())):n.removeAttribute(e)}}
vendor: 9,159 bytes, line 4
4,Br=function(t,e,i,n,s,r){var o=new zs(t._pt,e,i,0,1,r?gr:pr);return t._pt=o,o.b=n,o.e=s,t._props.push(i),o},Nr={deg:1,rad:1,turn:1},jr={grid:1,flex:1},Hr=function t(e,i,n,s){var r,o,a,l,c=parseFloat(n)||0,h=(n+"").trim().substr((c+"").length)||"px",u=Js.style,d=ar.test(i),f="svg"===e.tagName.toLowerCase(),p=(f?"client":"offset")+(d?"Width":"Height"),g=100,m="px"===s,v="%"===s;if(s===h||!c||Nr[s]||Nr[h])return c;if("px"!==h&&!m&&(c=t(e,i,n,"px")),l=e.getCTM&&Ir(e),(v||"%"===h)&&(ir[i]||~i.indexOf("adius")))return r=l?e.getBBox()[d?"width":"height"]:e[p],Ii(v?c/r*g:c/100*r);if(u[d?"width":"height"]=g+(m?h:s),o="rem"!==s&&~i.indexOf("adius")||"em"===s&&e.appendChild&&!f?e:e.parentNode,l&&(o=(e.ownerSVGElement||{}).parentNode),o&&o!==Zs&&o.appendChild||(o=Zs.body),(a=o._gsap)&&v&&a.width&&d&&a.time===Un.time&&!a.uncache)return Ii(c/a.width*g);if(!v||"height"!==i&&"width"!==i)(v||"%"===h)&&!jr[Or(o,"display")]&&(u.position=Or(e,"position")),o===e&&(u.position="static"),o.appendChild(Js),r=Js[p],o.removeChild(Js),u.position="absolute";else{var b=e.style[i];e.style[i]=g+s,r=e[p],b?e.style[i]=b:Fr(e,i)}return d&&v&&((a=Ri(o)).time=Un.time,a.width=o[p]),Ii(m?r*c/g:r&&c?g/r*c:0)},Yr=function(t,e,i,n){var s;return Ks||Lr(),e in cr&&"transform"!==e&&~(e=cr[e]).indexOf(",")&&(e=e.split(",")[0]),ir[e]&&"transform"!==e?(s=to(t,n),s="transformOrigin"!==e?s[e]:s.svg?s.origin:eo(Or(t,Sr))+" "+s.zOrigin+"px"):(!(s=t.style[e])||"auto"===s||n||~(s+"").indexOf("calc("))&&(s=Vr[e]&&Vr[e](t,e,i)||Or(t,e)||zi(t,e)||("opacity"===e?1:0)),i&&!~(s+"").trim().indexOf(" ")?Hr(t,e,s,i)+i:s},qr=function(t,e,i,n){if(!i||"none"===i){var s=Ar(e,t,1),r=s&&Or(t,s,1);r&&r!==i?(e=s,i=r):"borderColor"===e&&(i=Or(t,"borderTopColor"))}var o,a,l,c,h,u,d,f,p,g,m,v=new zs(this._pt,t.style,e,0,1,Ps),b=0,y=0;if(v.b=i,v.e=n,i+="","auto"==(n+="")&&(u=t.style[e],t.style[e]=n,n=Or(t,e)||n,u?t.style[e]=u:Fr(t,e)),Vn(o=[i,n]),n=o[1],l=(i=o[0]).match(ci)||[],(n.match(ci)||[]).length){for(;a=ci.exec(n);)d=a[0],p=n.substring(b,a.index),h?h=(h+1)%5:"rgba("!==p.substr(-5)&&"hsla("!==p.substr(-5)||(h=1),d!==(u=l[y++]||"")&&(c=parseFloat(u)||0,m=u.substr((c+"").length),"="===d.charAt(1)&&(d=Bi(c,d)+m),f=parseFloat(d),g=d.substr((f+"").length),b=ci.lastIndex-g.length,g||(g=g||He.units[e]||m,b===n.length&&(n+=g,v.e+=g)),m!==g&&(c=Hr(t,e,u,g)||0),v._pt={_next:v._pt,p:p||1===y?p:",",s:c,c:f-c,m:h&&h<4||"zIndex"===e?Math.round:0});v.c=b<n.length?n.substring(b,n.length):""}else v.r="display"===e&&"none"===n?gr:pr;return ui.test(n)&&(v.e=0),this._pt=v,v},Xr={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},Wr=function(t){var e=t.split(" "),i=e[0],n=e[1]||"50%";return"top"!==i&&"bottom"!==i&&"left"!==n&&"right"!==n||(t=i,i=n,n=t),e[0]=Xr[i]||i,e[1]=Xr[n]||n,e.join(" ")},$r=function(t,e){if(e.tween&&e.tween._time===e.tween._dur){var i,n,s,r=e.t,o=r.style,a=e.u,l=r._gsap;if("all"===a||!0===a)o.cssText="",n=1;else for(s=(a=a.split(",")).length;--s>-1;)i=a[s],ir[i]&&(n=1,i="transformOrigin"===i?Sr:xr),Fr(r,i);n&&(Fr(r,xr),l&&(l.svg&&r.removeAttribute("transform"),o.scale=o.rotate=o.translate="none",to(r,1),l.uncache=1,Er(o)))}},Vr={clearProps:function(t,e,i,n,s){if("isFromStart"!==s.data){var r=t._pt=new zs(t._pt,e,i,0,0,$r);return r.u=n,r.pr=-10,r.tween=s,t._props.push(i),1}}},Ur=[1,0,0,1,0,0],Zr={},Gr=function(t){return"matrix(1, 0, 0, 1, 0, 0)"===t||"none"===t||!t},Kr=function(t){var e=Or(t,xr);return Gr(e)?Ur:e.substr(7).match(li).map(Ii)},Jr=function(t,e){var i,n,s,r,o=t._gsap||Ri(t),a=t.style,l=Kr(t);return o.svg&&t.getAttribute("transform")?"1,0,0,1,0,0"===(l=[(s=t.transform.baseVal.consolidate().matrix).a,s.b,s.c,s.d,s.e,s.f]).join(",")?Ur:l:(l!==Ur||t.offsetParent||t===Gs||o.svg||(s=a.display,a.display="block",(i=t.parentNode)&&(t.offsetParent||t.getBoundingClientRect().width)||(r=1,n=t.nextElementSibling,Gs.appendChild(t)),l=Kr(t),s?a.display=s:Fr(t,"display"),r&&(n?i.insertBefore(t,n):i?i.appendChild(t):Gs.removeChild(t))),e&&l.length>6?[l[0],l[1],l[4],l[5],l[12],l[13]]:l)},Qr=function(t,e,i,n,s,r){var o,a,l,c=t._gsap,h=s||Jr(t,!0),u=c.xOrigin||0,d=c.yOrigin||0,f=c.xOffset||0,p=c.yOffset||0,g=h[0],m=h[1],v=h[2],b=h[3],y=h[4],_=h[5],w=e.split(" "),x=parseFloat(w[0])||0,S=parseFloat(w[1])||0;i?h!==Ur&&(a=g*b-m*v)&&(l=x*(-m/a)+S*(g/a)-(g*_-m*y)/a,x=x*(b/a)+S*(-v/a)+(v*_-b*y)/a,S=l):(x=(o=Dr(t)).x+(~w[0].indexOf("%")?x/100*o.width:x),S=o.y+(~(w[1]||w[0]).indexOf("%")?S/100*o.height:S)),n||!1!==n&&c.smooth?(y=x-u,_=S-d,c.xOffset=f+(y*g+_*v)-y,c.yOffset=p+(y*m+_*b)-_):c.xOffset=c.yOffset=0,c.xOrigin=x,c.yOrigin=S,c.smooth=!!n,c.origin=e,c.originIsAbsolute=!!i,t.style[Sr]="0px 0px",r&&(Br(r,c,"xOrigin",u,x),Br(r,c,"yOrigin",d,S),Br(r,c,"xOffset",f,c.xOffset),Br(r,c,"yOffset",p,c.yOffset)),t.setAttribute("data-svg-origin",x+" "+S)},to=function(t,e){var i=t._gsap||new as(t);if("x"in i&&!e&&!i.uncache)return i;var n,s,r,o,a,l,c,h,u,d,f,p,g,m,v,b,y,_,w,x,S,T,E,M,C,P,O,k,A,L,R,z,D=t.style,I=i.scaleX<0,F="px",B="deg",N=getComputedStyle(t),j=Or(t,Sr)||"0";return n=s=r=l=c=h=u=d=f=0,o=a=1,i.svg=!(!t.getCTM||!Ir(t)),N.translate&&("none"===N.translate&&"none"===N.scale&&"none"===N.rotate||(D[xr]=("none"!==N.translate?"translate3d("+(N.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+("none"!==N.rotate?"rotate("+N.rotate+") ":"")+("none"!==N.scale?"scale("+N.scale.split(" ").join(",")+") ":"")+("none"!==N[xr]?N[xr]:"")),D.scale=D.rotate=D.translate="none"),m=Jr(t,i.svg),i.svg&&(i.uncache?(C=t.getBBox(),j=i.xOrigin-C.x+"px "+(i.yOrigin-C.y)+"px",M=""):M=!e&&t.getAttribute("data-svg-origin"),Qr(t,M||j,!!M||i.originIsAbsolute,!1!==i.smooth,m)),p=i.xOrigin||0,g=i.yOrigin||0,m!==Ur&&(_=m[0],w=m[1],x=m[2],S=m[3],n=T=m[4],s=E=m[5],6===m.length?(o=Math.sqrt(_*_+w*w),a=Math.sqrt(S*S+x*x),l=_||w?rr(w,_)*nr:0,(u=x||S?rr(x,S)*nr+l:0)&&(a*=Math.abs(Math.cos(u*sr))),i.svg&&(n-=p-(p*_+g*x),s-=g-(p*w+g*S))):(z=m[6],L=m[7],O=m[8],k=m[9],A=m[10],R=m[11],n=m[12],s=m[13],r=m[14],c=(v=rr(z,A))*nr,v&&(M=T*(b=Math.cos(-v))+O*(y=Math.sin(-v)),C=E*b+k*y,P=z*b+A*y,O=T*-y+O*b,k=E*-y+k*b,A=z*-y+A*b,R=L*-y+R*b,T=M,E=C,z=P),h=(v=rr(-x,A))*nr,v&&(b=Math.cos(-v),R=S*(y=Math.sin(-v))+R*b,_=M=_*b-O*y,w=C=w*b-k*y,x=P=x*b-A*y),l=(v=rr(w,_))*nr,v&&(M=_*(b=Math.cos(v))+w*(y=Math.sin(v)),C=T*b+E*y,w=w*b-_*y,E=E*b-T*y,_=M,T=C),c&&Math.abs(c)+Math.abs(l)>359.9&&(c=l=0,h=180-h),o=Ii(Math.sqrt(_*_+w*w+x*x)),a=Ii(Math.sqrt(E*E+z*z)),v=rr(T,E),u=Math.abs(v)>2e-4?v*nr:0,f=R?1/(R<0?-R:R):0),i.svg&&(M=t.getAttribute("transform"),i.forceCSS=t.setAttribute("transform","")||!Gr(Or(t,xr)),M&&t.setAttribute("transform",M))),Math.abs(u)>90&&Math.abs(u)<270&&(I?(o*=-1,u+=l<=0?180:-180,l+=l<=0?180:-180):(a*=-1,u+=u<=0?180:-180)),e=e||i.uncache,i.x=n-((i.xPercent=n&&(!e&&i.xPercent||(Math.round(t.offsetWidth/2)===Math.round(-n)?-50:0)))?t.offsetWidth*i.xPercent/100:0)+F,i.y=s-((i.yPercent=s&&(!e&&i.yPercent||(Math.round(t.offsetHeight/2)===Math.round(-s)?-50:0)))?t.offsetHeight*i.yPercent/100:0)+F,i.z=r+F,i.scaleX=Ii(o),i.scaleY=Ii(a),i.rotation=Ii(l)+B,i.rotationX=Ii(c)+B,i.rotationY=Ii(h)+B,i.skewX=u+B,i.skewY=d+B,i.transformPerspective=f+F,(i.zOrigin=parseFloat(j.split(" ")[2])||!e&&i.zOrigin||0)&&(D[Sr]=eo(j)),i.xOffset=i.yOffset=0,i.force3D=He.force3D,i.renderTransform=i.svg?lo:er?ao:no,i.uncache=0,i},eo=function(t){return(t=t.split(" "))[0]+" "+t[1]},io=function(t,e,i){var n=wn(e);return Ii(parseFloat(e)+parseFloat(Hr(t,"x",i+"px",n)))+n},no=function(t,e){e.z="0px",e.rotationY=e.rotationX="0deg",e.force3D=0,ao(t,e)},so="0deg",ro="0px",oo=") ",ao=function(t,e){var i=e||this,n=i.xPercent,s=i.yPercent,r=i.x,o=i.y,a=i.z,l=i.rotation,c=i.rotationY,h=i.rotationX,u=i.skewX,d=i.skewY,f=i.scaleX,p=i.scaleY,g=i.transformPerspective,m=i.force3D,v=i.target,b=i.zOrigin,y="",_="auto"===m&&t&&1!==t||!0===m;if(b&&(h!==so||c!==so)){var w,x=parseFloat(c)*sr,S=Math.sin(x),T=Math.cos(x);x=parseFloat(h)*sr,w=Math.cos(x),r=io(v,r,S*w*-b),o=io(v,o,-Math.sin(x)*-b),a=io(v,a,T*w*-b+b)}g!==ro&&(y+="perspective("+g+oo),(n||s)&&(y+="translate("+n+"%, "+s+"%) "),(_||r!==ro||o!==ro||a!==ro)&&(y+=a!==ro||_?"translate3d("+r+", "+o+", "+a+") ":"translate("+r+", "+o+oo),l!==so&&(y+="rotate("+l+oo),c!==so&&(y+="rotateY("+c+oo),h!==so&&(y+="rotateX("+h+oo),u===so&&d===so||(y+="skew("+u+", "+d+oo),1===f&&1===p||(y+="scale("+f+", "+p+oo),v.style[xr]=y||"translate(0, 0)"},lo=function(t,e){var i,n,s,r,o,a=e||this,l=a.xPercent,c=a.yPercent,h=a.x,u=a.y,d=a.rotation,f=a.skewX,p=a.skewY,g=a.scaleX,m=a.scaleY,v=a.target,b=a.xOrigin,y=a.yOrigin,_=a.xOffset,w=a.yOffset,x=a.forceCSS,S=parseFloat(h),T=parseFloat(u);d=parseFloat(d),f=parseFloat(f),(p=parseFloat(p))&&(f+=p=parseFloat(p),d+=p),d||f?(d*=sr,f*=sr,i=Math.cos(d)*g,n=Math.sin(d)*g,s=Math.sin(d-f)*-m,r=Math.cos(d-f)*m,f&&(p*=sr,o=Math.tan(f-p),s*=o=Math.sqrt(1+o*o),r*=o,p&&(o=Math.tan(p),i*=o=Math.sqrt(1+o*o),n*=o)),i=Ii(i),n=Ii(n),s=Ii(s),r=Ii(r)):(i=g,r=m,n=s=0),(S&&!~(h+"").indexOf("px")||T&&!~(u+"").indexOf("px"))&&(S=Hr(v,"x",h,"px"),T=Hr(v,"y",u,"px")),(b||y||_||w)&&(S=Ii(S+b-(b*i+y*s)+_),T=Ii(T+y-(b*n+y*r)+w)),(l||c)&&(o=v.getBBox(),S=Ii(S+l/100*o.width),T=Ii(T+c/100*o.height)),o="matrix("+i+","+n+","+s+","+r+","+S+","+T+")",v.setAttribute("transform",o),x&&(v.style[xr]=o)}
vendor: 43,963 bytes, line 4
4,co=function(t,e,i,n,s){var r,o,a=360,l=Ke(s),c=parseFloat(s)*(l&&~s.indexOf("rad")?nr:1)-n,h=n+c+"deg";return l&&("short"===(r=s.split("_")[1])&&(c%=a)!=c%180&&(c+=c<0?a:-360),"cw"===r&&c<0?c=(c+36e9)%a-~~(c/a)*a:"ccw"===r&&c>0&&(c=(c-36e9)%a-~~(c/a)*a)),t._pt=o=new zs(t._pt,e,i,n,c,ur),o.e=h,o.u="deg",t._props.push(i),o},ho=function(t,e){for(var i in e)t[i]=e[i];return t},uo=function(t,e,i){var n,s,r,o,a,l,c,h=ho({},i._gsap),u=i.style;for(s in h.svg?(r=i.getAttribute("transform"),i.setAttribute("transform",""),u[xr]=e,n=to(i,1),Fr(i,xr),i.setAttribute("transform",r)):(r=getComputedStyle(i)[xr],u[xr]=e,n=to(i,1),u[xr]=r),ir)(r=h[s])!==(o=n[s])&&"perspective,force3D,transformOrigin,svgOrigin".indexOf(s)<0&&(a=wn(r)!==(c=wn(o))?Hr(i,s,r,c):parseFloat(r),l=parseFloat(o),t._pt=new zs(t._pt,n,s,a,l-a,hr),t._pt.u=c||0,t._props.push(s));ho(n,h)};Di("padding,margin,Width,Radius",(function(t,e){var i="Top",n="Right",s="Bottom",r="Left",o=(e<3?[i,n,s,r]:[i+r,i+n,s+n,s+r]).map((function(i){return e<2?t+i:"border"+i+t}));Vr[e>1?"border"+t:t]=function(t,e,i,n,s){var r,a;if(arguments.length<4)return r=o.map((function(e){return Yr(t,e,i)})),5===(a=r.join(" ")).split(r[0]).length?r[0]:a;r=(n+"").split(" "),a={},o.forEach((function(t,e){return a[t]=r[e]=r[e]||r[(e-1)/2|0]})),t.init(e,a,s)}}));var fo,po,go={name:"css",register:Lr,targetTest:function(t){return t.style&&t.nodeType},init:function(t,e,i,n,s){var r,o,a,l,c,h,u,d,f,p,g,m,v,b,y,_,w=this._props,x=t.style,S=i.vars.startAt;for(u in Ks||Lr(),this.styles=this.styles||Cr(t),_=this.styles.props,this.tween=i,e)if("autoRound"!==u&&(o=e[u],!Ci[u]||!ps(u,e,i,n,t,s)))if(c=typeof o,h=Vr[u],"function"===c&&(c=typeof(o=o.call(i,n,t,s))),"string"===c&&~o.indexOf("random(")&&(o=Ln(o)),h)h(this,t,u,o,i)&&(y=1);else if("--"===u.substr(0,2))r=(getComputedStyle(t).getPropertyValue(u)+"").trim(),o+="",Wn.lastIndex=0,Wn.test(r)||(d=wn(r),f=wn(o)),f?d!==f&&(r=Hr(t,u,r,f)+f):d&&(o+=d),this.add(x,"setProperty",r,o,n,s,0,0,u),w.push(u),_.push(u,0,x[u]);else if("undefined"!==c){if(S&&u in S?(r="function"==typeof S[u]?S[u].call(i,n,t,s):S[u],Ke(r)&&~r.indexOf("random(")&&(r=Ln(r)),wn(r+"")||"auto"===r||(r+=He.units[u]||wn(Yr(t,u))||""),"="===(r+"").charAt(1)&&(r=Yr(t,u))):r=Yr(t,u),l=parseFloat(r),(p="string"===c&&"="===o.charAt(1)&&o.substr(0,2))&&(o=o.substr(2)),a=parseFloat(o),u in cr&&("autoAlpha"===u&&(1===l&&"hidden"===Yr(t,"visibility")&&a&&(l=0),_.push("visibility",0,x.visibility),Br(this,x,"visibility",l?"inherit":"hidden",a?"inherit":"hidden",!a)),"scale"!==u&&"transform"!==u&&~(u=cr[u]).indexOf(",")&&(u=u.split(",")[0])),g=u in ir)if(this.styles.save(u),m||((v=t._gsap).renderTransform&&!e.parseTransform||to(t,e.parseTransform),b=!1!==e.smoothOrigin&&v.smooth,(m=this._pt=new zs(this._pt,x,xr,0,1,v.renderTransform,v,0,-1)).dep=1),"scale"===u)this._pt=new zs(this._pt,v,"scaleY",v.scaleY,(p?Bi(v.scaleY,p+a):a)-v.scaleY||0,hr),this._pt.u=0,w.push("scaleY",u),u+="X";else{if("transformOrigin"===u){_.push(Sr,0,x[Sr]),o=Wr(o),v.svg?Qr(t,o,0,b,0,this):((f=parseFloat(o.split(" ")[2])||0)!==v.zOrigin&&Br(this,v,"zOrigin",v.zOrigin,f),Br(this,x,u,eo(r),eo(o)));continue}if("svgOrigin"===u){Qr(t,o,1,b,0,this);continue}if(u in Zr){co(this,v,u,l,p?Bi(l,p+o):o);continue}if("smoothOrigin"===u){Br(this,v,"smooth",v.smooth,o);continue}if("force3D"===u){v[u]=o;continue}if("transform"===u){uo(this,o,t);continue}}else u in x||(u=Ar(u)||u);if(g||(a||0===a)&&(l||0===l)&&!lr.test(o)&&u in x)a||(a=0),(d=(r+"").substr((l+"").length))!==(f=wn(o)||(u in He.units?He.units[u]:d))&&(l=Hr(t,u,r,f)),this._pt=new zs(this._pt,g?v:x,u,l,(p?Bi(l,p+a):a)-l,g||"px"!==f&&"zIndex"!==u||!1===e.autoRound?hr:fr),this._pt.u=f||0,d!==f&&"%"!==f&&(this._pt.b=r,this._pt.r=dr);else if(u in x)qr.call(this,t,u,r,p?p+o:o);else if(u in t)this.add(t,u,r||t[u],p?p+o:o,n,s);else if("parseTransform"!==u){vi(u,o);continue}g||(u in x?_.push(u,0,x[u]):"function"==typeof t[u]?_.push(u,2,t[u]()):_.push(u,1,r||t[u])),w.push(u)}y&&Rs(this)},render:function(t,e){if(e.tween._time||!tr())for(var i=e._pt;i;)i.r(t,i.d),i=i._next;else e.styles.revert()},get:Yr,aliases:cr,getSetter:function(t,e,i){var n=cr[e];return n&&n.indexOf(",")<0&&(e=n),e in ir&&e!==Sr&&(t._gsap.x||Yr(t,"x"))?i&&Qs===i?"scale"===e?yr:br:(Qs=i||{})&&("scale"===e?_r:wr):t.style&&!ti(t.style[e])?mr:~e.indexOf("-")?vr:Es(t,e)},core:{_removeProperty:Fr,_getMatrix:Jr}};Vs.utils.checkPrefix=Ar,Vs.core.getStyleSaver=Cr,po=Di("x,y,z,scale,scaleX,scaleY,xPercent,yPercent"+","+(fo="rotation,rotationX,rotationY,skewX,skewY")+",transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective",(function(t){ir[t]=1})),Di(fo,(function(t){He.units[t]="deg",Zr[t]=1})),cr[po[13]]="x,y,z,scale,scaleX,scaleY,xPercent,yPercent,"+fo,Di("0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY",(function(t){var e=t.split(":");cr[e[1]]=po[e[0]]})),Di("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",(function(t){He.units[t]="px"})),Vs.registerPlugin(go);var mo=Vs.registerPlugin(go)||Vs;function vo(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)}}mo.core.Tween;var bo,yo,_o,wo,xo,So,To,Eo,Mo,Co,Po,Oo,ko,Ao=function(){return bo||"undefined"!=typeof window&&(bo=window.gsap)&&bo.registerPlugin&&bo},Lo=1,Ro=[],zo=[],Do=[],Io=Date.now,Fo=function(t,e){return e},Bo=function(t,e){return~Do.indexOf(t)&&Do[Do.indexOf(t)+1][e]},No=function(t){return!!~Co.indexOf(t)},jo=function(t,e,i,n,s){return t.addEventListener(e,i,{passive:!1!==n,capture:!!s})},Ho=function(t,e,i,n){return t.removeEventListener(e,i,!!n)},Yo=function(){return Po&&Po.isPressed||zo.cache++},qo=function(t,e){var i=function i(n){if(n||0===n){Lo&&(_o.history.scrollRestoration="manual");var s=Po&&Po.isPressed;n=i.v=Math.round(n)||(Po&&Po.iOS?1:0),t(n),i.cacheID=zo.cache,s&&Fo("ss",n)}else(e||zo.cache!==i.cacheID||Fo("ref"))&&(i.cacheID=zo.cache,i.v=t());return i.v+i.offset};return i.offset=0,t&&i},Xo={s:"scrollLeft",p:"left",p2:"Left",os:"right",os2:"Right",d:"width",d2:"Width",a:"x",sc:qo((function(t){return arguments.length?_o.scrollTo(t,Wo.sc()):_o.pageXOffset||wo.scrollLeft||xo.scrollLeft||So.scrollLeft||0}))},Wo={s:"scrollTop",p:"top",p2:"Top",os:"bottom",os2:"Bottom",d:"height",d2:"Height",a:"y",op:Xo,sc:qo((function(t){return arguments.length?_o.scrollTo(Xo.sc(),t):_o.pageYOffset||wo.scrollTop||xo.scrollTop||So.scrollTop||0}))},$o=function(t,e){return(e&&e._ctx&&e._ctx.selector||bo.utils.toArray)(t)[0]||("string"==typeof t&&!1!==bo.config().nullTargetWarn?console.warn("Element not found:",t):null)},Vo=function(t,e){var i=e.s,n=e.sc;No(t)&&(t=wo.scrollingElement||xo);var s=zo.indexOf(t),r=n===Wo.sc?1:2;!~s&&(s=zo.push(t)-1),zo[s+r]||jo(t,"scroll",Yo);var o=zo[s+r],a=o||(zo[s+r]=qo(Bo(t,i),!0)||(No(t)?n:qo((function(e){return arguments.length?t[i]=e:t[i]}))));return a.target=t,o||(a.smooth="smooth"===bo.getProperty(t,"scrollBehavior")),a},Uo=function(t,e,i){var n=t,s=t,r=Io(),o=r,a=e||50,l=Math.max(500,3*a),c=function(t,e){var l=Io();e||l-r>a?(s=n,n=t,o=r,r=l):i?n+=t:n=s+(t-s)/(l-o)*(r-o)};return{update:c,reset:function(){s=n=i?0:n,o=r=0},getVelocity:function(t){var e=o,a=s,h=Io();return(t||0===t)&&t!==n&&c(t),r===o||h-o>l?0:(n+(i?a:-a))/((i?h:r)-e)*1e3}}},Zo=function(t,e){return e&&!t._gsapAllow&&t.preventDefault(),t.changedTouches?t.changedTouches[0]:t},Go=function(t){var e=Math.max.apply(Math,t),i=Math.min.apply(Math,t);return Math.abs(e)>=Math.abs(i)?e:i},Ko=function(){var t,e,i,n;(Mo=bo.core.globals().ScrollTrigger)&&Mo.core&&(t=Mo.core,e=t.bridge||{},i=t._scrollers,n=t._proxies,i.push.apply(i,zo),n.push.apply(n,Do),zo=i,Do=n,Fo=function(t,i){return e[t](i)})},Jo=function(t){return bo=t||Ao(),!yo&&bo&&"undefined"!=typeof document&&document.body&&(_o=window,wo=document,xo=wo.documentElement,So=wo.body,Co=[_o,wo,xo,So],bo.utils.clamp,ko=bo.core.context||function(){},Eo="onpointerenter"in So?"pointer":"mouse",To=Qo.isTouch=_o.matchMedia&&_o.matchMedia("(hover: none), (pointer: coarse)").matches?1:"ontouchstart"in _o||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0?2:0,Oo=Qo.eventTypes=("ontouchstart"in xo?"touchstart,touchmove,touchcancel,touchend":"onpointerdown"in xo?"pointerdown,pointermove,pointercancel,pointerup":"mousedown,mousemove,mouseup,mouseup").split(","),setTimeout((function(){return Lo=0}),500),Ko(),yo=1),yo};Xo.op=Wo,zo.cache=0;var Qo=function(){function t(t){this.init(t)}var e,i;return t.prototype.init=function(t){yo||Jo(bo)||console.warn("Please gsap.registerPlugin(Observer)"),Mo||Ko();var e=t.tolerance,i=t.dragMinimum,n=t.type,s=t.target,r=t.lineHeight,o=t.debounce,a=t.preventDefault,l=t.onStop,c=t.onStopDelay,h=t.ignore,u=t.wheelSpeed,d=t.event,f=t.onDragStart,p=t.onDragEnd,g=t.onDrag,m=t.onPress,v=t.onRelease,b=t.onRight,y=t.onLeft,_=t.onUp,w=t.onDown,x=t.onChangeX,S=t.onChangeY,T=t.onChange,E=t.onToggleX,M=t.onToggleY,C=t.onHover,P=t.onHoverEnd,O=t.onMove,k=t.ignoreCheck,A=t.isNormalizer,L=t.onGestureStart,R=t.onGestureEnd,z=t.onWheel,D=t.onEnable,I=t.onDisable,F=t.onClick,B=t.scrollSpeed,N=t.capture,j=t.allowClicks,H=t.lockAxis,Y=t.onLockAxis;this.target=s=$o(s)||xo,this.vars=t,h&&(h=bo.utils.toArray(h)),e=e||1e-9,i=i||0,u=u||1,B=B||1,n=n||"wheel,touch,pointer",o=!1!==o,r||(r=parseFloat(_o.getComputedStyle(So).lineHeight)||22);var q,X,W,$,V,U,Z,G=this,K=0,J=0,Q=t.passive||!a&&!1!==t.passive,tt=Vo(s,Xo),et=Vo(s,Wo),it=tt(),nt=et(),st=~n.indexOf("touch")&&!~n.indexOf("pointer")&&"pointerdown"===Oo[0],rt=No(s),ot=s.ownerDocument||wo,at=[0,0,0],lt=[0,0,0],ct=0,ht=function(){return ct=Io()},ut=function(t,e){return(G.event=t)&&h&&~h.indexOf(t.target)||e&&st&&"touch"!==t.pointerType||k&&k(t,e)},dt=function(){var t=G.deltaX=Go(at),i=G.deltaY=Go(lt),n=Math.abs(t)>=e,s=Math.abs(i)>=e;T&&(n||s)&&T(G,t,i,at,lt),n&&(b&&G.deltaX>0&&b(G),y&&G.deltaX<0&&y(G),x&&x(G),E&&G.deltaX<0!=K<0&&E(G),K=G.deltaX,at[0]=at[1]=at[2]=0),s&&(w&&G.deltaY>0&&w(G),_&&G.deltaY<0&&_(G),S&&S(G),M&&G.deltaY<0!=J<0&&M(G),J=G.deltaY,lt[0]=lt[1]=lt[2]=0),($||W)&&(O&&O(G),W&&(f&&1===W&&f(G),g&&g(G),W=0),$=!1),U&&!(U=!1)&&Y&&Y(G),V&&(z(G),V=!1),q=0},ft=function(t,e,i){at[i]+=t,lt[i]+=e,G._vx.update(t),G._vy.update(e),o?q||(q=requestAnimationFrame(dt)):dt()},pt=function(t,e){H&&!Z&&(G.axis=Z=Math.abs(t)>Math.abs(e)?"x":"y",U=!0),"y"!==Z&&(at[2]+=t,G._vx.update(t,!0)),"x"!==Z&&(lt[2]+=e,G._vy.update(e,!0)),o?q||(q=requestAnimationFrame(dt)):dt()},gt=function(t){if(!ut(t,1)){var e=(t=Zo(t,a)).clientX,n=t.clientY,s=e-G.x,r=n-G.y,o=G.isDragging;G.x=e,G.y=n,(o||(s||r)&&(Math.abs(G.startX-e)>=i||Math.abs(G.startY-n)>=i))&&(W=o?2:1,o||(G.isDragging=!0),pt(s,r))}},mt=G.onPress=function(t){ut(t,1)||t&&t.button||(G.axis=Z=null,X.pause(),G.isPressed=!0,t=Zo(t),K=J=0,G.startX=G.x=t.clientX,G.startY=G.y=t.clientY,G._vx.reset(),G._vy.reset(),jo(A?s:ot,Oo[1],gt,Q,!0),G.deltaX=G.deltaY=0,m&&m(G))},vt=G.onRelease=function(t){if(!ut(t,1)){Ho(A?s:ot,Oo[1],gt,!0);var e=!isNaN(G.y-G.startY),i=G.isDragging,n=i&&(Math.abs(G.x-G.startX)>3||Math.abs(G.y-G.startY)>3),r=Zo(t);!n&&e&&(G._vx.reset(),G._vy.reset(),a&&j&&bo.delayedCall(.08,(function(){if(Io()-ct>300&&!t.defaultPrevented)if(t.target.click)t.target.click();else if(ot.createEvent){var e=ot.createEvent("MouseEvents");e.initMouseEvent("click",!0,!0,_o,1,r.screenX,r.screenY,r.clientX,r.clientY,!1,!1,!1,!1,0,null),t.target.dispatchEvent(e)}}))),G.isDragging=G.isGesturing=G.isPressed=!1,l&&i&&!A&&X.restart(!0),W&&dt(),p&&i&&p(G),v&&v(G,n)}},bt=function(t){return t.touches&&t.touches.length>1&&(G.isGesturing=!0)&&L(t,G.isDragging)},yt=function(){return(G.isGesturing=!1)||R(G)},_t=function(t){if(!ut(t)){var e=tt(),i=et();ft((e-it)*B,(i-nt)*B,1),it=e,nt=i,l&&X.restart(!0)}},wt=function(t){if(!ut(t)){t=Zo(t,a),z&&(V=!0);var e=(1===t.deltaMode?r:2===t.deltaMode?_o.innerHeight:1)*u;ft(t.deltaX*e,t.deltaY*e,0),l&&!A&&X.restart(!0)}},xt=function(t){if(!ut(t)){var e=t.clientX,i=t.clientY,n=e-G.x,s=i-G.y;G.x=e,G.y=i,$=!0,l&&X.restart(!0),(n||s)&&pt(n,s)}},St=function(t){G.event=t,C(G)},Tt=function(t){G.event=t,P(G)},Et=function(t){return ut(t)||Zo(t,a)&&F(G)};X=G._dc=bo.delayedCall(c||.25,(function(){G._vx.reset(),G._vy.reset(),X.pause(),l&&l(G)})).pause(),G.deltaX=G.deltaY=0,G._vx=Uo(0,50,!0),G._vy=Uo(0,50,!0),G.scrollX=tt,G.scrollY=et,G.isDragging=G.isGesturing=G.isPressed=!1,ko(this),G.enable=function(t){return G.isEnabled||(jo(rt?ot:s,"scroll",Yo),n.indexOf("scroll")>=0&&jo(rt?ot:s,"scroll",_t,Q,N),n.indexOf("wheel")>=0&&jo(s,"wheel",wt,Q,N),(n.indexOf("touch")>=0&&To||n.indexOf("pointer")>=0)&&(jo(s,Oo[0],mt,Q,N),jo(ot,Oo[2],vt),jo(ot,Oo[3],vt),j&&jo(s,"click",ht,!0,!0),F&&jo(s,"click",Et),L&&jo(ot,"gesturestart",bt),R&&jo(ot,"gestureend",yt),C&&jo(s,Eo+"enter",St),P&&jo(s,Eo+"leave",Tt),O&&jo(s,Eo+"move",xt)),G.isEnabled=!0,G.isDragging=G.isGesturing=G.isPressed=$=W=!1,G._vx.reset(),G._vy.reset(),it=tt(),nt=et(),t&&t.type&&mt(t),D&&D(G)),G},G.disable=function(){G.isEnabled&&(Ro.filter((function(t){return t!==G&&No(t.target)})).length||Ho(rt?ot:s,"scroll",Yo),G.isPressed&&(G._vx.reset(),G._vy.reset(),Ho(A?s:ot,Oo[1],gt,!0)),Ho(rt?ot:s,"scroll",_t,N),Ho(s,"wheel",wt,N),Ho(s,Oo[0],mt,N),Ho(ot,Oo[2],vt),Ho(ot,Oo[3],vt),Ho(s,"click",ht,!0),Ho(s,"click",Et),Ho(ot,"gesturestart",bt),Ho(ot,"gestureend",yt),Ho(s,Eo+"enter",St),Ho(s,Eo+"leave",Tt),Ho(s,Eo+"move",xt),G.isEnabled=G.isPressed=G.isDragging=!1,I&&I(G))},G.kill=G.revert=function(){G.disable();var t=Ro.indexOf(G);t>=0&&Ro.splice(t,1),Po===G&&(Po=0)},Ro.push(G),A&&No(s)&&(Po=G),G.enable(d)},e=t,(i=[{key:"velocityX",get:function(){return this._vx.getVelocity()}},{key:"velocityY",get:function(){return this._vy.getVelocity()}}])&&vo(e.prototype,i),t}();Qo.version="3.12.7",Qo.create=function(t){return new Qo(t)},Qo.register=Jo,Qo.getAll=function(){return Ro.slice()},Qo.getById=function(t){return Ro.filter((function(e){return e.vars.id===t}))[0]},Ao()&&bo.registerPlugin(Qo);var ta,ea,ia,na,sa,ra,oa,aa,la,ca,ha,ua,da,fa,pa,ga,ma,va,ba,ya,_a,wa,xa,Sa,Ta,Ea,Ma,Ca,Pa,Oa,ka,Aa,La,Ra,za,Da,Ia,Fa,Ba=1,Na=Date.now,ja=Na(),Ha=0,Ya=0,qa=function(t,e,i){var n=nl(t)&&("clamp("===t.substr(0,6)||t.indexOf("max")>-1);return i["_"+e+"Clamp"]=n,n?t.substr(6,t.length-7):t},Xa=function(t,e){return!e||nl(t)&&"clamp("===t.substr(0,6)?t:"clamp("+t+")"},Wa=function t(){return Ya&&requestAnimationFrame(t)},$a=function(){return fa=1},Va=function(){return fa=0},Ua=function(t){return t},Za=function(t){return Math.round(1e5*t)/1e5||0},Ga=function(){return"undefined"!=typeof window},Ka=function(){return ta||Ga()&&(ta=window.gsap)&&ta.registerPlugin&&ta},Ja=function(t){return!!~oa.indexOf(t)},Qa=function(t){return("Height"===t?ka:ia["inner"+t])||sa["client"+t]||ra["client"+t]},tl=function(t){return Bo(t,"getBoundingClientRect")||(Ja(t)?function(){return ac.width=ia.innerWidth,ac.height=ka,ac}:function(){return _l(t)})},el=function(t,e){var i=e.s,n=e.d2,s=e.d,r=e.a;return Math.max(0,(i="scroll"+n)&&(r=Bo(t,i))?r()-tl(t)()[s]:Ja(t)?(sa[i]||ra[i])-Qa(n):t[i]-t["offset"+n])},il=function(t,e){for(var i=0;i<ba.length;i+=3)(!e||~e.indexOf(ba[i+1]))&&t(ba[i],ba[i+1],ba[i+2])},nl=function(t){return"string"==typeof t},sl=function(t){return"function"==typeof t},rl=function(t){return"number"==typeof t},ol=function(t){return"object"==typeof t},al=function(t,e,i){return t&&t.progress(e?0:1)&&i&&t.pause()},ll=function(t,e){if(t.enabled){var i=t._ctx?t._ctx.add((function(){return e(t)})):e(t);i&&i.totalTime&&(t.callbackAnimation=i)}},cl=Math.abs,hl="right",ul="bottom",dl="width",fl="height",pl="padding",gl="margin",ml="Width",vl="px",bl=function(t){return ia.getComputedStyle(t)},yl=function(t,e){for(var i in e)i in t||(t[i]=e[i]);return t},_l=function(t,e){var i=e&&"matrix(1, 0, 0, 1, 0, 0)"!==bl(t)[pa]&&ta.to(t,{x:0,y:0,xPercent:0,yPercent:0,rotation:0,rotationX:0,rotationY:0,scale:1,skewX:0,skewY:0}).progress(1),n=t.getBoundingClientRect();return i&&i.progress(0).kill(),n},wl=function(t,e){var i=e.d2;return t["offset"+i]||t["client"+i]||0},xl=function(t){var e,i=[],n=t.labels,s=t.duration();for(e in n)i.push(n[e]/s);return i},Sl=function(t){var e=ta.utils.snap(t),i=Array.isArray(t)&&t.slice(0).sort((function(t,e){return t-e}));return i?function(t,n,s){var r;if(void 0===s&&(s=.001),!n)return e(t);if(n>0){for(t-=s,r=0;r<i.length;r++)if(i[r]>=t)return i[r];return i[r-1]}for(r=i.length,t+=s;r--;)if(i[r]<=t)return i[r];return i[0]}:function(i,n,s){void 0===s&&(s=.001);var r=e(i);return!n||Math.abs(r-i)<s||r-i<0==n<0?r:e(n<0?i-t:i+t)}},Tl=function(t,e,i,n){return i.split(",").forEach((function(i){return t(e,i,n)}))},El=function(t,e,i,n,s){return t.addEventListener(e,i,{passive:!n,capture:!!s})},Ml=function(t,e,i,n){return t.removeEventListener(e,i,!!n)},Cl=function(t,e,i){(i=i&&i.wheelHandler)&&(t(e,"wheel",i),t(e,"touchmove",i))},Pl={startColor:"green",endColor:"red",indent:0,fontSize:"16px",fontWeight:"normal"},Ol={toggleActions:"play",anticipatePin:0},kl={top:0,left:0,center:.5,bottom:1,right:1},Al=function(t,e){if(nl(t)){var i=t.indexOf("="),n=~i?+(t.charAt(i-1)+1)*parseFloat(t.substr(i+1)):0;~i&&(t.indexOf("%")>i&&(n*=e/100),t=t.substr(0,i-1)),t=n+(t in kl?kl[t]*e:~t.indexOf("%")?parseFloat(t)*e/100:parseFloat(t)||0)}return t},Ll=function(t,e,i,n,s,r,o,a){var l=s.startColor,c=s.endColor,h=s.fontSize,u=s.indent,d=s.fontWeight,f=na.createElement("div"),p=Ja(i)||"fixed"===Bo(i,"pinType"),g=-1!==t.indexOf("scroller"),m=p?ra:i,v=-1!==t.indexOf("start"),b=v?l:c,y="border-color:"+b+";font-size:"+h+";color:"+b+";font-weight:"+d+";pointer-events:none;white-space:nowrap;font-family:sans-serif,Arial;z-index:1000;padding:4px 8px;border-width:0;border-style:solid;";return y+="position:"+((g||a)&&p?"fixed;":"absolute;"),(g||a||!p)&&(y+=(n===Wo?hl:ul)+":"+(r+parseFloat(u))+"px;"),o&&(y+="box-sizing:border-box;text-align:left;width:"+o.offsetWidth+"px;"),f._isStart=v,f.setAttribute("class","gsap-marker-"+t+(e?" marker-"+e:"")),f.style.cssText=y,f.innerText=e||0===e?t+"-"+e:t,m.children[0]?m.insertBefore(f,m.children[0]):m.appendChild(f),f._offset=f["offset"+n.op.d2],Rl(f,0,n,v),f},Rl=function(t,e,i,n){var s={display:"block"},r=i[n?"os2":"p2"],o=i[n?"p2":"os2"];t._isFlipped=n,s[i.a+"Percent"]=n?-100:0,s[i.a]=n?"1px":0,s["border"+r+ml]=1,s["border"+o+ml]=0,s[i.p]=e+"px",ta.set(t,s)},zl=[],Dl={},Il=function(){return Na()-Ha>34&&(za||(za=requestAnimationFrame(tc)))},Fl=function(){(!xa||!xa.isPressed||xa.startX>ra.clientWidth)&&(zo.cache++,xa?za||(za=requestAnimationFrame(tc)):tc(),Ha||ql("scrollStart"),Ha=Na())},Bl=function(){Ea=ia.innerWidth,Ta=ia.innerHeight},Nl=function(t){zo.cache++,(!0===t||!da&&!wa&&!na.fullscreenElement&&!na.webkitFullscreenElement&&(!Sa||Ea!==ia.innerWidth||Math.abs(ia.innerHeight-Ta)>.25*ia.innerHeight))&&aa.restart(!0)},jl={},Hl=[],Yl=function t(){return Ml(pc,"scrollEnd",t)||Kl(!0)},ql=function(t){return jl[t]&&jl[t].map((function(t){return t()}))||Hl},Xl=[],Wl=function(t){for(var e=0;e<Xl.length;e+=5)(!t||Xl[e+4]&&Xl[e+4].query===t)&&(Xl[e].style.cssText=Xl[e+1],Xl[e].getBBox&&Xl[e].setAttribute("transform",Xl[e+2]||""),Xl[e+3].uncache=1)},$l=function(t,e){var i;for(ga=0;ga<zl.length;ga++)!(i=zl[ga])||e&&i._ctx!==e||(t?i.kill(1):i.revert(!0,!0));Aa=!0,e&&Wl(e),e||ql("revert")},Vl=function(t,e){zo.cache++,(e||!Da)&&zo.forEach((function(t){return sl(t)&&t.cacheID++&&(t.rec=0)})),nl(t)&&(ia.history.scrollRestoration=Pa=t)},Ul=0,Zl=function(){ra.appendChild(Oa),ka=!xa&&Oa.offsetHeight||ia.innerHeight,ra.removeChild(Oa)},Gl=function(t){return la(".gsap-marker-start, .gsap-marker-end, .gsap-marker-scroller-start, .gsap-marker-scroller-end").forEach((function(e){return e.style.display=t?"none":"block"}))},Kl=function(t,e){if(sa=na.documentElement,ra=na.body,oa=[ia,na,sa,ra],!Ha||t||Aa){Zl(),Da=pc.isRefreshing=!0,zo.forEach((function(t){return sl(t)&&++t.cacheID&&(t.rec=t())}));var i=ql("refreshInit");ya&&pc.sort(),e||$l(),zo.forEach((function(t){sl(t)&&(t.smooth&&(t.target.style.scrollBehavior="auto"),t(0))})),zl.slice(0).forEach((function(t){return t.refresh()})),Aa=!1,zl.forEach((function(t){if(t._subPinOffset&&t.pin){var e=t.vars.horizontal?"offsetWidth":"offsetHeight",i=t.pin[e];t.revert(!0,1),t.adjustPinSpacing(t.pin[e]-i),t.refresh()}})),La=1,Gl(!0),zl.forEach((function(t){var e=el(t.scroller,t._dir),i="max"===t.vars.end||t._endClamp&&t.end>e,n=t._startClamp&&t.start>=e;(i||n)&&t.setPositions(n?e-1:t.start,i?Math.max(n?e:t.start+1,e):t.end,!0)})),Gl(!1),La=0,i.forEach((function(t){return t&&t.render&&t.render(-1)})),zo.forEach((function(t){sl(t)&&(t.smooth&&requestAnimationFrame((function(){return t.target.style.scrollBehavior="smooth"})),t.rec&&t(t.rec))})),Vl(Pa,1),aa.pause(),Ul++,Da=2,tc(2),zl.forEach((function(t){return sl(t.vars.onRefresh)&&t.vars.onRefresh(t)})),Da=pc.isRefreshing=!1,ql("refresh")}else El(pc,"scrollEnd",Yl)},Jl=0,Ql=1,tc=function(t){if(2===t||!Da&&!Aa){pc.isUpdating=!0,Fa&&Fa.update(0);var e=zl.length,i=Na(),n=i-ja>=50,s=e&&zl[0].scroll();if(Ql=Jl>s?-1:1,Da||(Jl=s),n&&(Ha&&!fa&&i-Ha>200&&(Ha=0,ql("scrollEnd")),ha=ja,ja=i),Ql<0){for(ga=e;ga-- >0;)zl[ga]&&zl[ga].update(0,n);Ql=1}else for(ga=0;ga<e;ga++)zl[ga]&&zl[ga].update(0,n);pc.isUpdating=!1}za=0},ec=["left","top",ul,hl,"marginBottom","marginRight","marginTop","marginLeft","display","flexShrink","float","zIndex","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","gridArea","justifySelf","alignSelf","placeSelf","order"],ic=ec.concat([dl,fl,"boxSizing","maxWidth","maxHeight","position",gl,pl,"paddingTop","paddingRight","paddingBottom","paddingLeft"]),nc=function(t,e,i,n){if(!t._gsap.swappedIn){for(var s,r=ec.length,o=e.style,a=t.style;r--;)o[s=ec[r]]=i[s];o.position="absolute"===i.position?"absolute":"relative","inline"===i.display&&(o.display="inline-block"),a.bottom=a.right="auto",o.flexBasis=i.flexBasis||"auto",o.overflow="visible",o.boxSizing="border-box",o.width=wl(t,Xo)+vl,o.height=wl(t,Wo)+vl,o.padding=a.margin=a.top=a.left="0",rc(n),a.width=a.maxWidth=i.width,a.height=a.maxHeight=i.height,a.padding=i.padding,t.parentNode!==e&&(t.parentNode.insertBefore(e,t),e.appendChild(t)),t._gsap.swappedIn=!0}},sc=/([A-Z])/g,rc=function(t){if(t){var e,i,n=t.t.style,s=t.length,r=0;for((t.t._gsap||ta.core.getCache(t.t)).uncache=1;r<s;r+=2)i=t[r+1],e=t[r],i?n[e]=i:n[e]&&n.removeProperty(e.replace(sc,"-$1").toLowerCase())}},oc=function(t){for(var e=ic.length,i=t.style,n=[],s=0;s<e;s++)n.push(ic[s],i[ic[s]]);return n.t=t,n},ac={left:0,top:0},lc=function(t,e,i,n,s,r,o,a,l,c,h,u,d,f){sl(t)&&(t=t(a)),nl(t)&&"max"===t.substr(0,3)&&(t=u+("="===t.charAt(4)?Al("0"+t.substr(3),i):0));var p,g,m,v=d?d.time():0;if(d&&d.seek(0),isNaN(t)||(t=+t),rl(t))d&&(t=ta.utils.mapRange(d.scrollTrigger.start,d.scrollTrigger.end,0,u,t)),o&&Rl(o,i,n,!0);else{sl(e)&&(e=e(a));var b,y,_,w,x=(t||"0").split(" ");m=$o(e,a)||ra,(b=_l(m)||{})&&(b.left||b.top)||"none"!==bl(m).display||(w=m.style.display,m.style.display="block",b=_l(m),w?m.style.display=w:m.style.removeProperty("display")),y=Al(x[0],b[n.d]),_=Al(x[1]||"0",i),t=b[n.p]-l[n.p]-c+y+s-_,o&&Rl(o,_,n,i-_<20||o._isStart&&_>20),i-=i-_}if(f&&(a[f]=t||-.001,t<0&&(t=0)),r){var S=t+i,T=r._isStart;p="scroll"+n.d2,Rl(r,S,n,T&&S>20||!T&&(h?Math.max(ra[p],sa[p]):r.parentNode[p])<=S+1),h&&(l=_l(o),h&&(r.style[n.op.p]=l[n.op.p]-n.op.m-r._offset+vl))}return d&&m&&(p=_l(m),d.seek(u),g=_l(m),d._caScrollDist=p[n.p]-g[n.p],t=t/d._caScrollDist*u),d&&d.seek(v),d?t:Math.round(t)},cc=/(webkit|moz|length|cssText|inset)/i,hc=function(t,e,i,n){if(t.parentNode!==e){var s,r,o=t.style;if(e===ra){for(s in t._stOrig=o.cssText,r=bl(t))+s||cc.test(s)||!r[s]||"string"!=typeof o[s]||"0"===s||(o[s]=r[s]);o.top=i,o.left=n}else o.cssText=t._stOrig;ta.core.getCache(t).uncache=1,e.appendChild(t)}},uc=function(t,e,i){var n=e,s=n;return function(e){var r=Math.round(t());return r!==n&&r!==s&&Math.abs(r-n)>3&&Math.abs(r-s)>3&&(e=r,i&&i()),s=n,n=Math.round(e)}},dc=function(t,e,i){var n={};n[e.p]="+="+i,ta.set(t,n)},fc=function(t,e){var i=Vo(t,e),n="_scroll"+e.p2,s=function e(s,r,o,a,l){var c=e.tween,h=r.onComplete,u={};o=o||i();var d=uc(i,o,(function(){c.kill(),e.tween=0}));return l=a&&l||0,a=a||s-o,c&&c.kill(),r[n]=s,r.inherit=!1,r.modifiers=u,u[n]=function(){return d(o+a*c.ratio+l*c.ratio*c.ratio)},r.onUpdate=function(){zo.cache++,e.tween&&tc()},r.onComplete=function(){e.tween=0,h&&h.call(c)},c=e.tween=ta.to(t,r)};return t[n]=i,i.wheelHandler=function(){return s.tween&&s.tween.kill()&&(s.tween=0)},El(t,"wheel",i.wheelHandler),pc.isTouch&&El(t,"touchmove",i.wheelHandler),s},pc=function(){function t(e,i){ea||t.register(ta)||console.warn("Please gsap.registerPlugin(ScrollTrigger)"),Ca(this),this.init(e,i)}return t.prototype.init=function(e,i){if(this.progress=this.start=0,this.vars&&this.kill(!0,!0),Ya){var n,s,r,o,a,l,c,h,u,d,f,p,g,m,v,b,y,_,w,x,S,T,E,M,C,P,O,k,A,L,R,z,D,I,F,B,N,j,H,Y,q,X,W=e=yl(nl(e)||rl(e)||e.nodeType?{trigger:e}:e,Ol),$=W.onUpdate,V=W.toggleClass,U=W.id,Z=W.onToggle,G=W.onRefresh,K=W.scrub,J=W.trigger,Q=W.pin,tt=W.pinSpacing,et=W.invalidateOnRefresh,it=W.anticipatePin,nt=W.onScrubComplete,st=W.onSnapComplete,rt=W.once,ot=W.snap,at=W.pinReparent,lt=W.pinSpacer,ct=W.containerAnimation,ht=W.fastScrollEnd,ut=W.preventOverlaps,dt=e.horizontal||e.containerAnimation&&!1!==e.horizontal?Xo:Wo,ft=!K&&0!==K,pt=$o(e.scroller||ia),gt=ta.core.getCache(pt),mt=Ja(pt),vt="fixed"===("pinType"in e?e.pinType:Bo(pt,"pinType")||mt&&"fixed"),bt=[e.onEnter,e.onLeave,e.onEnterBack,e.onLeaveBack],yt=ft&&e.toggleActions.split(" "),_t="markers"in e?e.markers:Ol.markers,wt=mt?0:parseFloat(bl(pt)["border"+dt.p2+ml])||0,xt=this,St=e.onRefreshInit&&function(){return e.onRefreshInit(xt)},Tt=function(t,e,i){var n=i.d,s=i.d2,r=i.a;return(r=Bo(t,"getBoundingClientRect"))?function(){return r()[n]}:function(){return(e?Qa(s):t["client"+s])||0}}(pt,mt,dt),Et=function(t,e){return!e||~Do.indexOf(t)?tl(t):function(){return ac}}(pt,mt),Mt=0,Ct=0,Pt=0,Ot=Vo(pt,dt);if(xt._startClamp=xt._endClamp=!1,xt._dir=dt,it*=45,xt.scroller=pt,xt.scroll=ct?ct.time.bind(ct):Ot,o=Ot(),xt.vars=e,i=i||e.animation,"refreshPriority"in e&&(ya=1,-9999===e.refreshPriority&&(Fa=xt)),gt.tweenScroll=gt.tweenScroll||{top:fc(pt,Wo),left:fc(pt,Xo)},xt.tweenTo=n=gt.tweenScroll[dt.p],xt.scrubDuration=function(t){(D=rl(t)&&t)?z?z.duration(t):z=ta.to(i,{ease:"expo",totalProgress:"+=0",inherit:!1,duration:D,paused:!0,onComplete:function(){return nt&&nt(xt)}}):(z&&z.progress(1).kill(),z=0)},i&&(i.vars.lazy=!1,i._initted&&!xt.isReverted||!1!==i.vars.immediateRender&&!1!==e.immediateRender&&i.duration()&&i.render(0,!0,!0),xt.animation=i.pause(),i.scrollTrigger=xt,xt.scrubDuration(K),L=0,U||(U=i.vars.id)),ot&&(ol(ot)&&!ot.push||(ot={snapTo:ot}),"scrollBehavior"in ra.style&&ta.set(mt?[ra,sa]:pt,{scrollBehavior:"auto"}),zo.forEach((function(t){return sl(t)&&t.target===(mt?na.scrollingElement||sa:pt)&&(t.smooth=!1)})),r=sl(ot.snapTo)?ot.snapTo:"labels"===ot.snapTo?function(t){return function(e){return ta.utils.snap(xl(t),e)}}(i):"labelsDirectional"===ot.snapTo?(Y=i,function(t,e){return Sl(xl(Y))(t,e.direction)}):!1!==ot.directional?function(t,e){return Sl(ot.snapTo)(t,Na()-Ct<500?0:e.direction)}:ta.utils.snap(ot.snapTo),I=ot.duration||{min:.1,max:2},I=ol(I)?ca(I.min,I.max):ca(I,I),F=ta.delayedCall(ot.delay||D/2||.1,(function(){var t=Ot(),e=Na()-Ct<500,s=n.tween;if(!(e||Math.abs(xt.getVelocity())<10)||s||fa||Mt===t)xt.isActive&&Mt!==t&&F.restart(!0);else{var o,a,h=(t-l)/m,u=i&&!ft?i.totalProgress():h,d=e?0:(u-R)/(Na()-ha)*1e3||0,f=ta.utils.clamp(-h,1-h,cl(d/2)*d/.185),p=h+(!1===ot.inertia?0:f),g=ot,v=g.onStart,b=g.onInterrupt,y=g.onComplete;if(o=r(p,xt),rl(o)||(o=p),a=Math.max(0,Math.round(l+o*m)),t<=c&&t>=l&&a!==t){if(s&&!s._initted&&s.data<=cl(a-t))return;!1===ot.inertia&&(f=o-h),n(a,{duration:I(cl(.185*Math.max(cl(p-u),cl(o-u))/d/.05||0)),ease:ot.ease||"power3",data:cl(a-t),onInterrupt:function(){return F.restart(!0)&&b&&b(xt)},onComplete:function(){xt.update(),Mt=Ot(),i&&!ft&&(z?z.resetTo("totalProgress",o,i._tTime/i._tDur):i.progress(o)),L=R=i&&!ft?i.totalProgress():xt.progress,st&&st(xt),y&&y(xt)}},t,f*m,a-t-f*m),v&&v(xt,n.tween)}}})).pause()),U&&(Dl[U]=xt),(H=(J=xt.trigger=$o(J||!0!==Q&&Q))&&J._gsap&&J._gsap.stRevert)&&(H=H(xt)),Q=!0===Q?J:$o(Q),nl(V)&&(V={targets:J,className:V}),Q&&(!1===tt||tt===gl||(tt=!(!tt&&Q.parentNode&&Q.parentNode.style&&"flex"===bl(Q.parentNode).display)&&pl),xt.pin=Q,(s=ta.core.getCache(Q)).spacer?v=s.pinState:(lt&&((lt=$o(lt))&&!lt.nodeType&&(lt=lt.current||lt.nativeElement),s.spacerIsNative=!!lt,lt&&(s.spacerState=oc(lt))),s.spacer=_=lt||na.createElement("div"),_.classList.add("pin-spacer"),U&&_.classList.add("pin-spacer-"+U),s.pinState=v=oc(Q)),!1!==e.force3D&&ta.set(Q,{force3D:!0}),xt.spacer=_=s.spacer,A=bl(Q),M=A[tt+dt.os2],x=ta.getProperty(Q),S=ta.quickSetter(Q,dt.a,vl),nc(Q,_,A),y=oc(Q)),_t){p=ol(_t)?yl(_t,Pl):Pl,d=Ll("scroller-start",U,pt,dt,p,0),f=Ll("scroller-end",U,pt,dt,p,0,d),w=d["offset"+dt.op.d2];var kt=$o(Bo(pt,"content")||pt);h=this.markerStart=Ll("start",U,kt,dt,p,w,0,ct),u=this.markerEnd=Ll("end",U,kt,dt,p,w,0,ct),ct&&(j=ta.quickSetter([h,u],dt.a,vl)),vt||Do.length&&!0===Bo(pt,"fixedMarkers")||(X=bl(q=mt?ra:pt).position,q.style.position="absolute"===X||"fixed"===X?X:"relative",ta.set([d,f],{force3D:!0}),P=ta.quickSetter(d,dt.a,vl),k=ta.quickSetter(f,dt.a,vl))}if(ct){var At=ct.vars.onUpdate,Lt=ct.vars.onUpdateParams;ct.eventCallback("onUpdate",(function(){xt.update(0,0,1),At&&At.apply(ct,Lt||[])}))}if(xt.previous=function(){return zl[zl.indexOf(xt)-1]},xt.next=function(){return zl[zl.indexOf(xt)+1]},xt.revert=function(t,e){if(!e)return xt.kill(!0);var n=!1!==t||!xt.enabled,s=da;n!==xt.isReverted&&(n&&(B=Math.max(Ot(),xt.scroll.rec||0),Pt=xt.progress,N=i&&i.progress()),h&&[h,u,d,f].forEach((function(t){return t.style.display=n?"none":"block"})),n&&(da=xt,xt.update(n)),!Q||at&&xt.isActive||(n?function(t,e,i){rc(i);var n=t._gsap;if(n.spacerIsNative)rc(n.spacerState);else if(t._gsap.swappedIn){var s=e.parentNode;s&&(s.insertBefore(t,e),s.removeChild(e))}t._gsap.swappedIn=!1}(Q,_,v):nc(Q,_,bl(Q),C)),n||xt.update(n),da=s,xt.isReverted=n)},xt.refresh=function(s,r,p,w){if(!da&&xt.enabled||r)if(Q&&s&&Ha)El(t,"scrollEnd",Yl);else{!Da&&St&&St(xt),da=xt,n.tween&&!p&&(n.tween.kill(),n.tween=0),z&&z.pause(),et&&i&&i.revert({kill:!1}).invalidate(),xt.isReverted||xt.revert(!0,!0),xt._subPinOffset=!1;var S,M,P,k,A,L,R,D,I,j,H,Y,q,X=Tt(),W=Et(),$=ct?ct.duration():el(pt,dt),V=m<=.01,U=0,Z=w||0,K=ol(p)?p.end:e.end,it=e.endTrigger||J,nt=ol(p)?p.start:e.start||(0!==e.start&&J?Q?"0 0":"0 100%":0),st=xt.pinnedContainer=e.pinnedContainer&&$o(e.pinnedContainer,xt),rt=J&&Math.max(0,zl.indexOf(xt))||0,ot=rt;for(_t&&ol(p)&&(Y=ta.getProperty(d,dt.p),q=ta.getProperty(f,dt.p));ot-- >0;)(L=zl[ot]).end||L.refresh(0,1)||(da=xt),!(R=L.pin)||R!==J&&R!==Q&&R!==st||L.isReverted||(j||(j=[]),j.unshift(L),L.revert(!0,!0)),L!==zl[ot]&&(rt--,ot--);for(sl(nt)&&(nt=nt(xt)),nt=qa(nt,"start",xt),l=lc(nt,J,X,dt,Ot(),h,d,xt,W,wt,vt,$,ct,xt._startClamp&&"_startClamp")||(Q?-.001:0),sl(K)&&(K=K(xt)),nl(K)&&!K.indexOf("+=")&&(~K.indexOf(" ")?K=(nl(nt)?nt.split(" ")[0]:"")+K:(U=Al(K.substr(2),X),K=nl(nt)?nt:(ct?ta.utils.mapRange(0,ct.duration(),ct.scrollTrigger.start,ct.scrollTrigger.end,l):l)+U,it=J)),K=qa(K,"end",xt),c=Math.max(l,lc(K||(it?"100% 0":$),it,X,dt,Ot()+U,u,f,xt,W,wt,vt,$,ct,xt._endClamp&&"_endClamp"))||-.001,U=0,ot=rt;ot--;)(R=(L=zl[ot]).pin)&&L.start-L._pinPush<=l&&!ct&&L.end>0&&(S=L.end-(xt._startClamp?Math.max(0,L.start):L.start),(R===J&&L.start-L._pinPush<l||R===st)&&isNaN(nt)&&(U+=S*(1-L.progress)),R===Q&&(Z+=S));if(l+=U,c+=U,xt._startClamp&&(xt._startClamp+=U),xt._endClamp&&!Da&&(xt._endClamp=c||-.001,c=Math.min(c,el(pt,dt))),m=c-l||(l-=.01)&&.001,V&&(Pt=ta.utils.clamp(0,1,ta.utils.normalize(l,c,B))),xt._pinPush=Z,h&&U&&((S={})[dt.a]="+="+U,st&&(S[dt.p]="-="+Ot()),ta.set([h,u],S)),!Q||La&&xt.end>=el(pt,dt)){if(J&&Ot()&&!ct)for(M=J.parentNode;M&&M!==ra;)M._pinOffset&&(l-=M._pinOffset,c-=M._pinOffset),M=M.parentNode}else S=bl(Q),k=dt===Wo,P=Ot(),T=parseFloat(x(dt.a))+Z,!$&&c>1&&(H={style:H=(mt?na.scrollingElement||sa:pt).style,value:H["overflow"+dt.a.toUpperCase()]},mt&&"scroll"!==bl(ra)["overflow"+dt.a.toUpperCase()]&&(H.style["overflow"+dt.a.toUpperCase()]="scroll")),nc(Q,_,S),y=oc(Q),M=_l(Q,!0),D=vt&&Vo(pt,k?Xo:Wo)(),tt?((C=[tt+dt.os2,m+Z+vl]).t=_,(ot=tt===pl?wl(Q,dt)+m+Z:0)&&(C.push(dt.d,ot+vl),"auto"!==_.style.flexBasis&&(_.style.flexBasis=ot+vl)),rc(C),st&&zl.forEach((function(t){t.pin===st&&!1!==t.vars.pinSpacing&&(t._subPinOffset=!0)})),vt&&Ot(B)):(ot=wl(Q,dt))&&"auto"!==_.style.flexBasis&&(_.style.flexBasis=ot+vl),vt&&((A={top:M.top+(k?P-l:D)+vl,left:M.left+(k?D:P-l)+vl,boxSizing:"border-box",position:"fixed"}).width=A.maxWidth=Math.ceil(M.width)+vl,A.height=A.maxHeight=Math.ceil(M.height)+vl,A.margin=A.marginTop=A.marginRight=A.marginBottom=A.marginLeft="0",A.padding=S.padding,A.paddingTop=S.paddingTop,A.paddingRight=S.paddingRight,A.paddingBottom=S.paddingBottom,A.paddingLeft=S.paddingLeft,b=function(t,e,i){for(var n,s=[],r=t.length,o=i?8:0;o<r;o+=2)n=t[o],s.push(n,n in e?e[n]:t[o+1]);return s.t=t.t,s}(v,A,at),Da&&Ot(0)),i?(I=i._initted,_a(1),i.render(i.duration(),!0,!0),E=x(dt.a)-T+m+Z,O=Math.abs(m-E)>1,vt&&O&&b.splice(b.length-2,2),i.render(0,!0,!0),I||i.invalidate(!0),i.parent||i.totalTime(i.totalTime()),_a(0)):E=m,H&&(H.value?H.style["overflow"+dt.a.toUpperCase()]=H.value:H.style.removeProperty("overflow-"+dt.a));j&&j.forEach((function(t){return t.revert(!1,!0)})),xt.start=l,xt.end=c,o=a=Da?B:Ot(),ct||Da||(o<B&&Ot(B),xt.scroll.rec=0),xt.revert(!1,!0),Ct=Na(),F&&(Mt=-1,F.restart(!0)),da=0,i&&ft&&(i._initted||N)&&i.progress()!==N&&i.progress(N||0,!0).render(i.time(),!0,!0),(V||Pt!==xt.progress||ct||et||i&&!i._initted)&&(i&&!ft&&i.totalProgress(ct&&l<-.001&&!Pt?ta.utils.normalize(l,c,0):Pt,!0),xt.progress=V||(o-l)/m===Pt?0:Pt),Q&&tt&&(_._pinOffset=Math.round(xt.progress*E)),z&&z.invalidate(),isNaN(Y)||(Y-=ta.getProperty(d,dt.p),q-=ta.getProperty(f,dt.p),dc(d,dt,Y),dc(h,dt,Y-(w||0)),dc(f,dt,q),dc(u,dt,q-(w||0))),V&&!Da&&xt.update(),!G||Da||g||(g=!0,G(xt),g=!1)}},xt.getVelocity=function(){return(Ot()-a)/(Na()-ha)*1e3||0},xt.endAnimation=function(){al(xt.callbackAnimation),i&&(z?z.progress(1):i.paused()?ft||al(i,xt.direction<0,1):al(i,i.reversed()))},xt.labelToScroll=function(t){return i&&i.labels&&(l||xt.refresh()||l)+i.labels[t]/i.duration()*m||0},xt.getTrailing=function(t){var e=zl.indexOf(xt),i=xt.direction>0?zl.slice(0,e).reverse():zl.slice(e+1);return(nl(t)?i.filter((function(e){return e.vars.preventOverlaps===t})):i).filter((function(t){return xt.direction>0?t.end<=l:t.start>=c}))},xt.update=function(t,e,s){if(!ct||s||t){var r,h,u,f,p,g,v,w=!0===Da?B:xt.scroll(),x=t?0:(w-l)/m,C=x<0?0:x>1?1:x||0,A=xt.progress;if(e&&(a=o,o=ct?Ot():w,ot&&(R=L,L=i&&!ft?i.totalProgress():C)),it&&Q&&!da&&!Ba&&Ha&&(!C&&l<w+(w-a)/(Na()-ha)*it?C=1e-4:1===C&&c>w+(w-a)/(Na()-ha)*it&&(C=.9999)),C!==A&&xt.enabled){if(f=(p=(r=xt.isActive=!!C&&C<1)!=(!!A&&A<1))||!!C!=!!A,xt.direction=C>A?1:-1,xt.progress=C,f&&!da&&(h=C&&!A?0:1===C?1:1===A?2:3,ft&&(u=!p&&"none"!==yt[h+1]&&yt[h+1]||yt[h],v=i&&("complete"===u||"reset"===u||u in i))),ut&&(p||v)&&(v||K||!i)&&(sl(ut)?ut(xt):xt.getTrailing(ut).forEach((function(t){return t.endAnimation()}))),ft||(!z||da||Ba?i&&i.totalProgress(C,!(!da||!Ct&&!t)):(z._dp._time-z._start!==z._time&&z.render(z._dp._time-z._start),z.resetTo?z.resetTo("totalProgress",C,i._tTime/i._tDur):(z.vars.totalProgress=C,z.invalidate().restart()))),Q)if(t&&tt&&(_.style[tt+dt.os2]=M),vt){if(f){if(g=!t&&C>A&&c+1>w&&w+1>=el(pt,dt),at)if(t||!r&&!g)hc(Q,_);else{var D=_l(Q,!0),I=w-l;hc(Q,ra,D.top+(dt===Wo?I:0)+vl,D.left+(dt===Wo?0:I)+vl)}rc(r||g?b:y),O&&C<1&&r||S(T+(1!==C||g?0:E))}}else S(Za(T+E*C));ot&&!n.tween&&!da&&!Ba&&F.restart(!0),V&&(p||rt&&C&&(C<1||!Ra))&&la(V.targets).forEach((function(t){return t.classList[r||rt?"add":"remove"](V.className)})),$&&!ft&&!t&&$(xt),f&&!da?(ft&&(v&&("complete"===u?i.pause().totalProgress(1):"reset"===u?i.restart(!0).pause():"restart"===u?i.restart(!0):i[u]()),$&&$(xt)),!p&&Ra||(Z&&p&&ll(xt,Z),bt[h]&&ll(xt,bt[h]),rt&&(1===C?xt.kill(!1,1):bt[h]=0),p||bt[h=1===C?1:3]&&ll(xt,bt[h])),ht&&!r&&Math.abs(xt.getVelocity())>(rl(ht)?ht:2500)&&(al(xt.callbackAnimation),z?z.progress(1):al(i,"reverse"===u?1:!C,1))):ft&&$&&!da&&$(xt)}if(k){var N=ct?w/ct.duration()*(ct._caScrollDist||0):w;P(N+(d._isFlipped?1:0)),k(N)}j&&j(-w/ct.duration()*(ct._caScrollDist||0))}},xt.enable=function(e,i){xt.enabled||(xt.enabled=!0,El(pt,"resize",Nl),mt||El(pt,"scroll",Fl),St&&El(t,"refreshInit",St),!1!==e&&(xt.progress=Pt=0,o=a=Mt=Ot()),!1!==i&&xt.refresh())},xt.getTween=function(t){return t&&n?n.tween:z},xt.setPositions=function(t,e,i,n){if(ct){var s=ct.scrollTrigger,r=ct.duration(),o=s.end-s.start;t=s.start+o*t/r,e=s.start+o*e/r}xt.refresh(!1,!1,{start:Xa(t,i&&!!xt._startClamp),end:Xa(e,i&&!!xt._endClamp)},n),xt.update()},xt.adjustPinSpacing=function(t){if(C&&t){var e=C.indexOf(dt.d)+1;C[e]=parseFloat(C[e])+t+vl,C[1]=parseFloat(C[1])+t+vl,rc(C)}},xt.disable=function(e,i){if(xt.enabled&&(!1!==e&&xt.revert(!0,!0),xt.enabled=xt.isActive=!1,i||z&&z.pause(),B=0,s&&(s.uncache=1),St&&Ml(t,"refreshInit",St),F&&(F.pause(),n.tween&&n.tween.kill()&&(n.tween=0)),!mt)){for(var r=zl.length;r--;)if(zl[r].scroller===pt&&zl[r]!==xt)return;Ml(pt,"resize",Nl),mt||Ml(pt,"scroll",Fl)}},xt.kill=function(t,n){xt.disable(t,n),z&&!n&&z.kill(),U&&delete Dl[U];var r=zl.indexOf(xt);r>=0&&zl.splice(r,1),r===ga&&Ql>0&&ga--,r=0,zl.forEach((function(t){return t.scroller===xt.scroller&&(r=1)})),r||Da||(xt.scroll.rec=0),i&&(i.scrollTrigger=null,t&&i.revert({kill:!1}),n||i.kill()),h&&[h,u,d,f].forEach((function(t){return t.parentNode&&t.parentNode.removeChild(t)})),Fa===xt&&(Fa=0),Q&&(s&&(s.uncache=1),r=0,zl.forEach((function(t){return t.pin===Q&&r++})),r||(s.spacer=0)),e.onKill&&e.onKill(xt)},zl.push(xt),xt.enable(!1,!1),H&&H(xt),i&&i.add&&!m){var Rt=xt.update;xt.update=function(){xt.update=Rt,zo.cache++,l||c||xt.refresh()},ta.delayedCall(.01,xt.update),m=.01,l=c=0}else xt.refresh();Q&&function(){if(Ia!==Ul){var t=Ia=Ul;requestAnimationFrame((function(){return t===Ul&&Kl(!0)}))}}()}else this.update=this.refresh=this.kill=Ua},t.register=function(e){return ea||(ta=e||Ka(),Ga()&&window.document&&t.enable(),ea=Ya),ea},t.defaults=function(t){if(t)for(var e in t)Ol[e]=t[e];return Ol},t.disable=function(t,e){Ya=0,zl.forEach((function(i){return i[e?"kill":"disable"](t)})),Ml(ia,"wheel",Fl),Ml(na,"scroll",Fl),clearInterval(ua),Ml(na,"touchcancel",Ua),Ml(ra,"touchstart",Ua),Tl(Ml,na,"pointerdown,touchstart,mousedown",$a),Tl(Ml,na,"pointerup,touchend,mouseup",Va),aa.kill(),il(Ml);for(var i=0;i<zo.length;i+=3)Cl(Ml,zo[i],zo[i+1]),Cl(Ml,zo[i],zo[i+2])},t.enable=function(){if(ia=window,na=document,sa=na.documentElement,ra=na.body,ta&&(la=ta.utils.toArray,ca=ta.utils.clamp,Ca=ta.core.context||Ua,_a=ta.core.suppressOverwrites||Ua,Pa=ia.history.scrollRestoration||"auto",Jl=ia.pageYOffset||0,ta.core.globals("ScrollTrigger",t),ra)){Ya=1,(Oa=document.createElement("div")).style.height="100vh",Oa.style.position="absolute",Zl(),Wa(),Qo.register(ta),t.isTouch=Qo.isTouch,Ma=Qo.isTouch&&/(iPad|iPhone|iPod|Mac)/g.test(navigator.userAgent),Sa=1===Qo.isTouch,El(ia,"wheel",Fl),oa=[ia,na,sa,ra],ta.matchMedia?(t.matchMedia=function(t){var e,i=ta.matchMedia();for(e in t)i.add(e,t[e]);return i},ta.addEventListener("matchMediaInit",(function(){return $l()})),ta.addEventListener("matchMediaRevert",(function(){return Wl()})),ta.addEventListener("matchMedia",(function(){Kl(0,1),ql("matchMedia")})),ta.matchMedia().add("(orientation: portrait)",(function(){return Bl(),Bl}))):console.warn("Requires GSAP 3.11.0 or later"),Bl(),El(na,"scroll",Fl);var e,i,n=ra.hasAttribute("style"),s=ra.style,r=s.borderTopStyle,o=ta.core.Animation.prototype;for(o.revert||Object.defineProperty(o,"revert",{value:function(){return this.time(-.01,!0)}}),s.borderTopStyle="solid",e=_l(ra),Wo.m=Math.round(e.top+Wo.sc())||0,Xo.m=Math.round(e.left+Xo.sc())||0,r?s.borderTopStyle=r:s.removeProperty("border-top-style"),n||(ra.setAttribute("style",""),ra.removeAttribute("style")),ua=setInterval(Il,250),ta.delayedCall(.5,(function(){return Ba=0})),El(na,"touchcancel",Ua),El(ra,"touchstart",Ua),Tl(El,na,"pointerdown,touchstart,mousedown",$a),Tl(El,na,"pointerup,touchend,mouseup",Va),pa=ta.utils.checkPrefix("transform"),ic.push(pa),ea=Na(),aa=ta.delayedCall(.2,Kl).pause(),ba=[na,"visibilitychange",function(){var t=ia.innerWidth,e=ia.innerHeight;na.hidden?(ma=t,va=e):ma===t&&va===e||Nl()},na,"DOMContentLoaded",Kl,ia,"load",Kl,ia,"resize",Nl],il(El),zl.forEach((function(t){return t.enable(0,1)})),i=0;i<zo.length;i+=3)Cl(Ml,zo[i],zo[i+1]),Cl(Ml,zo[i],zo[i+2])}},t.config=function(e){"limitCallbacks"in e&&(Ra=!!e.limitCallbacks);var i=e.syncInterval;i&&clearInterval(ua)||(ua=i)&&setInterval(Il,i),"ignoreMobileResize"in e&&(Sa=1===t.isTouch&&e.ignoreMobileResize),"autoRefreshEvents"in e&&(il(Ml)||il(El,e.autoRefreshEvents||"none"),wa=-1===(e.autoRefreshEvents+"").indexOf("resize"))},t.scrollerProxy=function(t,e){var i=$o(t),n=zo.indexOf(i),s=Ja(i);~n&&zo.splice(n,s?6:2),e&&(s?Do.unshift(ia,e,ra,e,sa,e):Do.unshift(i,e))},t.clearMatchMedia=function(t){zl.forEach((function(e){return e._ctx&&e._ctx.query===t&&e._ctx.kill(!0,!0)}))},t.isInViewport=function(t,e,i){var n=(nl(t)?$o(t):t).getBoundingClientRect(),s=n[i?dl:fl]*e||0;return i?n.right-s>0&&n.left+s<ia.innerWidth:n.bottom-s>0&&n.top+s<ia.innerHeight},t.positionInViewport=function(t,e,i){nl(t)&&(t=$o(t));var n=t.getBoundingClientRect(),s=n[i?dl:fl],r=null==e?s/2:e in kl?kl[e]*s:~e.indexOf("%")?parseFloat(e)*s/100:parseFloat(e)||0;return i?(n.left+r)/ia.innerWidth:(n.top+r)/ia.innerHeight},t.killAll=function(t){if(zl.slice(0).forEach((function(t){return"ScrollSmoother"!==t.vars.id&&t.kill()})),!0!==t){var e=jl.killAll||[];jl={},e.forEach((function(t){return t()}))}},t}();pc.version="3.12.7",pc.saveStyles=function(t){return t?la(t).forEach((function(t){if(t&&t.style){var e=Xl.indexOf(t);e>=0&&Xl.splice(e,5),Xl.push(t,t.style.cssText,t.getBBox&&t.getAttribute("transform"),ta.core.getCache(t),Ca())}})):Xl},pc.revert=function(t,e){return $l(!t,e)},pc.create=function(t,e){return new pc(t,e)},pc.refresh=function(t){return t?Nl(!0):(ea||pc.register())&&Kl(!0)},pc.update=function(t){return++zo.cache&&tc(!0===t?2:0)},pc.clearScrollMemory=Vl,pc.maxScroll=function(t,e){return el(t,e?Xo:Wo)},pc.getScrollFunc=function(t,e){return Vo($o(t),e?Xo:Wo)},pc.getById=function(t){return Dl[t]},pc.getAll=function(){return zl.filter((function(t){return"ScrollSmoother"!==t.vars.id}))},pc.isScrolling=function(){return!!Ha},pc.snapDirectional=Sl,pc.addEventListener=function(t,e){var i=jl[t]||(jl[t]=[]);~i.indexOf(e)||i.push(e)},pc.removeEventListener=function(t,e){var i=jl[t],n=i&&i.indexOf(e);n>=0&&i.splice(n,1)},pc.batch=function(t,e){var i,n=[],s={},r=e.interval||.016,o=e.batchMax||1e9,a=function(t,e){var i=[],n=[],s=ta.delayedCall(r,(function(){e(i,n),i=[],n=[]})).pause();return function(t){i.length||s.restart(!0),i.push(t.trigger),n.push(t),o<=i.length&&s.progress(1)}};for(i in e)s[i]="on"===i.substr(0,2)&&sl(e[i])&&"onRefreshInit"!==i?a(0,e[i]):e[i];return sl(o)&&(o=o(),El(pc,"refresh",(function(){return o=e.batchMax()}))),la(t).forEach((function(t){var e={};for(i in s)e[i]=s[i];e.trigger=t,n.push(pc.create(e))})),n};var gc,mc=function(t,e,i,n){return e>n?t(n):e<0&&t(0),i>n?(n-e)/(i-e):i<0?e/(e-i):1},vc=function t(e,i){!0===i?e.style.removeProperty("touch-action"):e.style.touchAction=!0===i?"auto":i?"pan-"+i+(Qo.isTouch?" pinch-zoom":""):"none",e===sa&&t(ra,i)},bc={auto:1,scroll:1},yc=function(t){var e,i=t.event,n=t.target,s=t.axis,r=(i.changedTouches?i.changedTouches[0]:i).target,o=r._gsap||ta.core.getCache(r),a=Na();if(!o._isScrollT||a-o._isScrollT>2e3){for(;r&&r!==ra&&(r.scrollHeight<=r.clientHeight&&r.scrollWidth<=r.clientWidth||!bc[(e=bl(r)).overflowY]&&!bc[e.overflowX]);)r=r.parentNode;o._isScroll=r&&r!==n&&!Ja(r)&&(bc[(e=bl(r)).overflowY]||bc[e.overflowX]),o._isScrollT=a}(o._isScroll||"x"===s)&&(i.stopPropagation(),i._gsapAllow=!0)}
4,_c=function(t,e,i,n){return Qo.create({target:t,capture:!0,debounce:!1,lockAxis:!0,type:e,onWheel:n=n&&yc,onPress:n,onDrag:n,onScroll:n,onEnable:function(){return i&&El(na,Qo.eventTypes[0],xc,!1,!0)},onDisable:function(){return Ml(na,Qo.eventTypes[0],xc,!0)}})},wc=/(input|label|select|textarea)/i,xc=function(t){var e=wc.test(t.target.tagName);(e||gc)&&(t._gsapAllow=!0,gc=e)};function Sc(){const t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}function Tc(t,e,i="webp"){for(let s=1;s<=e;s++)(new Image).src=`${t}/${n=s,String(n).padStart(4,"0")}.${i}`;var n}if(pc.sort=function(t){if(sl(t))return zl.sort(t);var e=ia.pageYOffset||0;return pc.getAll().forEach((function(t){return t._sortY=t.trigger?e+t.trigger.getBoundingClientRect().top:t.start+ia.innerHeight})),zl.sort(t||function(t,e){return-1e6*(t.vars.refreshPriority||0)+(t.vars.containerAnimation?1e6:t._sortY)-((e.vars.containerAnimation?1e6:e._sortY)+-1e6*(e.vars.refreshPriority||0))})},pc.observe=function(t){return new Qo(t)},pc.normalizeScroll=function(t){if(void 0===t)return xa;if(!0===t&&xa)return xa.enable();if(!1===t)return xa&&xa.kill(),void(xa=t);var e=t instanceof Qo?t:function(t){ol(t)||(t={}),t.preventDefault=t.isNormalizer=t.allowClicks=!0,t.type||(t.type="wheel,touch"),t.debounce=!!t.debounce,t.id=t.id||"normalizer";var e,i,n,s,r,o,a,l,c=t,h=c.normalizeScrollX,u=c.momentum,d=c.allowNestedScroll,f=c.onRelease,p=$o(t.target)||sa,g=ta.core.globals().ScrollSmoother,m=g&&g.get(),v=Ma&&(t.content&&$o(t.content)||m&&!1!==t.content&&!m.smooth()&&m.content()),b=Vo(p,Wo),y=Vo(p,Xo),_=1,w=(Qo.isTouch&&ia.visualViewport?ia.visualViewport.scale*ia.visualViewport.width:ia.outerWidth)/ia.innerWidth,x=0,S=sl(u)?function(){return u(e)}:function(){return u||2.8},T=_c(p,t.type,!0,d),E=function(){return s=!1},M=Ua,C=Ua,P=function(){i=el(p,Wo),C=ca(Ma?1:0,i),h&&(M=ca(0,el(p,Xo))),n=Ul},O=function(){v._gsap.y=Za(parseFloat(v._gsap.y)+b.offset)+"px",v.style.transform="matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, "+parseFloat(v._gsap.y)+", 0, 1)",b.offset=b.cacheID=0},k=function(){P(),r.isActive()&&r.vars.scrollY>i&&(b()>i?r.progress(1)&&b(i):r.resetTo("scrollY",i))};return v&&ta.set(v,{y:"+=0"}),t.ignoreCheck=function(t){return Ma&&"touchmove"===t.type&&function(){if(s){requestAnimationFrame(E);var t=Za(e.deltaY/2),i=C(b.v-t);if(v&&i!==b.v+b.offset){b.offset=i-b.v;var n=Za((parseFloat(v&&v._gsap.y)||0)-b.offset);v.style.transform="matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, "+n+", 0, 1)",v._gsap.y=n+"px",b.cacheID=zo.cache,tc()}return!0}b.offset&&O(),s=!0}()||_>1.05&&"touchstart"!==t.type||e.isGesturing||t.touches&&t.touches.length>1},t.onPress=function(){s=!1;var t=_;_=Za((ia.visualViewport&&ia.visualViewport.scale||1)/w),r.pause(),t!==_&&vc(p,_>1.01||!h&&"x"),o=y(),a=b(),P(),n=Ul},t.onRelease=t.onGestureStart=function(t,e){if(b.offset&&O(),e){zo.cache++;var n,s,o=S();h&&(s=(n=y())+.05*o*-t.velocityX/.227,o*=mc(y,n,s,el(p,Xo)),r.vars.scrollX=M(s)),s=(n=b())+.05*o*-t.velocityY/.227,o*=mc(b,n,s,el(p,Wo)),r.vars.scrollY=C(s),r.invalidate().duration(o).play(.01),(Ma&&r.vars.scrollY>=i||n>=i-1)&&ta.to({},{onUpdate:k,duration:o})}else l.restart(!0);f&&f(t)},t.onWheel=function(){r._ts&&r.pause(),Na()-x>1e3&&(n=0,x=Na())},t.onChange=function(t,e,i,s,r){if(Ul!==n&&P(),e&&h&&y(M(s[2]===e?o+(t.startX-t.x):y()+e-s[1])),i){b.offset&&O();var l=r[2]===i,c=l?a+t.startY-t.y:b()+i-r[1],u=C(c);l&&c!==u&&(a+=u-c),b(u)}(i||e)&&tc()},t.onEnable=function(){vc(p,!h&&"x"),pc.addEventListener("refresh",k),El(ia,"resize",k),b.smooth&&(b.target.style.scrollBehavior="auto",b.smooth=y.smooth=!1),T.enable()},t.onDisable=function(){vc(p,!0),Ml(ia,"resize",k),pc.removeEventListener("refresh",k),T.kill()},t.lockAxis=!1!==t.lockAxis,(e=new Qo(t)).iOS=Ma,Ma&&!b()&&b(1),Ma&&ta.ticker.add(Ua),l=e._dc,r=ta.to(e,{ease:"power4",paused:!0,inherit:!1,scrollX:h?"+=0.1":"+=0",scrollY:"+=0.1",modifiers:{scrollY:uc(b,b(),(function(){return r.pause()}))},onUpdate:tc,onComplete:l.vars.onComplete}),e}(t);return xa&&xa.target===e.target&&xa.kill(),Ja(e.target)&&(xa=e),e},pc.core={_getVelocityProp:Uo,_inputObserver:_c,_scrollers:zo,_proxies:Do,bridge:{ss:function(){Ha||ql("scrollStart"),Ha=Na()},ref:function(){return da}}},Ka()&&ta.registerPlugin(pc),window.innerWidth>=992){mo.registerPlugin(pc);const t=[78,81,81,67,95],e=(t,e)=>String(t).padStart(4,"0");document.querySelectorAll(".advantage").forEach(((i,n)=>{const s=i.querySelector("picture.desktop-only"),r=s?.querySelector("img.advantage-model__img"),o=s?.querySelector('source[type="image/webp"]'),a=i.querySelector(".advantage__title"),l=i.querySelector(".advantage__description");if(!r||!a||!l)return;const c=t[n],h=r.getAttribute("src").replace(/\/\d+\.png$/,""),u=o?.getAttribute("srcset")?.replace(/\/\d+\.webp$/,"")||h,d={current:1};function f(){mo.killTweensOf([a,l]),mo.to(a,{opacity:1,y:0,duration:1,ease:"power2.out"}),mo.to(l,{opacity:1,y:0,duration:1,delay:.2,ease:"power2.out"})}function p(){mo.killTweensOf([a,l]),mo.to(a,{opacity:0,y:-40,duration:.8,ease:"power2.in"}),mo.to(l,{opacity:0,y:-40,duration:.8,delay:.1,ease:"power2.in"})}Sc()?Tc(u,c,"webp"):Tc(h,c,"png"),mo.to(d,{current:c,ease:"none",scrollTrigger:{trigger:i,start:"top top",end:"+="+4*window.innerHeight,scrub:!0,pin:!0,anticipatePin:1,onEnter:f,onEnterBack:f,onLeave:p,onLeaveBack:p},onUpdate:()=>{const t=Math.round(d.current),i=e(t,4);o&&Sc()?o.srcset=`${u}/${i}.webp`:r.src=`${h}/${i}.png`}}
4)}))}mo.registerPlugin(pc),function(t,e){let i,n={},s=e.interval||.1,r=(t,i)=>{let n=[],r=mo.delayedCall(s,(()=>{i(n),n.length=0})).pause();return t=>{n.length||r.restart(!0),n.push(t.trigger),e.batchMax&&e.batchMax<=n.length&&r.progress(1)}};for(i in e)n[i]=~i.indexOf("Enter")||~i.indexOf("Leave")?r(0,e[i]):e[i];mo.utils.toArray(".card").forEach((t=>{let e={};for(i in n)e[i]=n[i];e.trigger=t,pc.create(e)}))}(0,{interval:.1,batchMax:3,onEnter:t=>mo.to(t,{autoAlpha:1,stagger:.15,overwrite:!0}),onLeave:t=>mo.set(t,{autoAlpha:0,overwrite:!0}),onEnterBack:t=>mo.to(t,{autoAlpha:1,stagger:.15,overwrite:!0}),onLeaveBack:t=>mo.set(t,{autoAlpha:0,overwrite:!0})}),i(742),i(349),i(789),i(729),mo.registerPlugin(pc),window.addEventListener("resize",(()=>{pc.refresh()})),mo.utils.toArray(".history-event").forEach((t=>{const e=t.querySelector(".history-event__marker"),i=t.querySelectorAll(".history-event__description p"),n=t.querySelector(".history-event__date"),s=t.querySelector(".history-timeline"),r=t.querySelector(".history-timeline__marker"),o=s.querySelector(".history-timeline__fill");i.forEach((t=>{mo.to(t,{color:"black",scrollTrigger:{trigger:t,start:"top 90%",end:"top 30%",scrub:!0}})})),n&&mo.to(n,{color:"#173B6D",scrollTrigger:{trigger:t,start:"top 80%",end:"top 20%",scrub:!0}}),r&&s&&mo.to(r,{y:()=>s.offsetHeight-r.offsetHeight+10,ease:"none",scrollTrigger:{trigger:t,start:"top center",end:"bottom center",scrub:!0,invalidateOnRefresh:!0}}),o&&mo.to(o,{height:()=>s.offsetHeight,ease:"none",scrollTrigger:{trigger:t,start:"top center",end:"bottom center",scrub:!0,invalidateOnRefresh:!0}}),mo.to(e,{background:"#173B6D",scrollTrigger:{trigger:t,start:"top 80%",end:"top 20%",scrub:!0}})})),i(961),i(257),i(610),mo.registerPlugin(pc),document.addEventListener("DOMContentLoaded",(function(){mo.utils.toArray(".reveal").forEach((function(t){!function(t){mo.set(t,{autoAlpha:0})}(t),pc.create({trigger:t,start:"top 80%",once:!0,onEnter:function(){!function(t,e){var i=0,n=10*(e=e||1);t.classList.contains("l4r")?(i=-20,n=0):t.classList.contains("r4l")&&(i=20,n=0),t.style.transform="translate("+i+"px, "+n+"px)",t.style.opacity="0",mo.fromTo(t,{x:i,y:n,autoAlpha:0},{duration:.48,x:0,y:0,autoAlpha:1,ease:"power2.inOut"})}(t)}})}))})),document.querySelectorAll(".about-stat__header-value").forEach((t=>{const e=parseInt(t.textContent);mo.set(t,{textContent:0}),mo.to(t,{textContent:e,duration:2,ease:"power1.out",snap:{textContent:1},onUpdate:function(){t.textContent=Math.ceil(t.textContent)},scrollTrigger:{trigger:t,start:"top 80%",toggleActions:"play none none none"}})})),i(840),i(812)}()}();
5/* End */
6;
7; /* Start:"a:4:{s:4:"full";s:96:"/local/templates/rotor/components/bitrix/sale.basket.basket.line/header/script.js?17544880155335";s:6:"source";s:81:"/local/templates/rotor/components/bitrix/sale.basket.basket.line/header/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/
8'use strict';
9
10function BitrixSmallCart(){}
11
12BitrixSmallCart.prototype = {
13
14	activate: function ()
15	{
16		this.cartElement = BX(this.cartId);
17		this.fixedPosition = this.arParams.POSITION_FIXED == 'Y';
18		if (this.fixedPosition)
19		{
20			this.cartClosed = true;
21			this.maxHeight = false;
22			this.itemRemoved = false;
23			this.verticalPosition = this.arParams.POSITION_VERTICAL;
24			this.horizontalPosition = this.arParams.POSITION_HORIZONTAL;
25			this.topPanelElement = BX("bx-panel");
26
27			this.fixAfterRender(); // TODO onready
28			this.fixAfterRenderClosure = this.closure('fixAfterRender');
29
30			var fixCartClosure = this.closure('fixCart');
31			this.fixCartClosure = fixCartClosure;
32
33			if (this.topPanelElement && this.verticalPosition == 'top')
34				BX.addCustomEvent(window, 'onTopPanelCollapse', fixCartClosure);
35
36			var resizeTimer = null;
37			BX.bind(window, 'resize', function() {
38				clearTimeout(resizeTimer);
39				resizeTimer = setTimeout(fixCartClosure, 200);
40			});
41		}
42		this.setCartBodyClosure = this.closure('setCartBody');
43		BX.addCustomEvent(window, 'OnBasketChange', this.closure('refreshCart', {}));
44	},
45
46	fixAfterRender: function ()
47	{
48		this.statusElement = BX(this.cartId + 'status');
49		if (this.statusElement)
50		{
51			if (this.cartClosed)
52				this.statusElement.innerHTML = this.openMessage;
53			else
54				this.statusElement.innerHTML = this.closeMessage;
55		}
56		this.productsElement = BX(this.cartId + 'products');
57		this.fixCart();
58	},
59
60	closure: function (fname, data)
61	{
62		var obj = this;
63		return data
64			? function(){obj[fname](data)}
65			: function(arg1){obj[fname](arg1)};
66	},
67
68	toggleOpenCloseCart: function ()
69	{
70		if (this.cartClosed)
71		{
72			BX.removeClass(this.cartElement, 'bx-closed');
73			BX.addClass(this.cartElement, 'bx-opener');
74			this.statusElement.innerHTML = this.closeMessage;
75			this.cartClosed = false;
76			this.fixCart();
77		}
78		else // Opened
79		{
80			BX.addClass(this.cartElement, 'bx-closed');
81			BX.removeClass(this.cartElement, 'bx-opener');
82			BX.removeClass(this.cartElement, 'bx-max-height');
83			this.statusElement.innerHTML = this.openMessage;
84			this.cartClosed = true;
85			var itemList = this.cartElement.querySelector("[data-role='basket-item-list']");
86			if (itemList)
87				itemList.style.top = "auto";
88		}
89		setTimeout(this.fixCartClosure, 100);
90	},
91
92	setVerticalCenter: function(windowHeight)
93	{
94		var top = windowHeight/2 - (this.cartElement.offsetHeight/2);
95		if (top < 5)
96			top = 5;
97		this.cartElement.style.top = top + 'px';
98	},
99
100	fixCart: function()
101	{
102		// set horizontal center
103		if (this.horizontalPosition == 'hcenter')
104		{
105			var windowWidth = 'innerWidth' in window
106				? window.innerWidth
107				: document.documentElement.offsetWidth;
108			var left = windowWidth/2 - (this.cartElement.offsetWidth/2);
109			if (left < 5)
110				left = 5;
111			this.cartElement.style.left = left + 'px';
112		}
113
114		var windowHeight = 'innerHeight' in window
115			? window.innerHeight
116			: document.documentElement.offsetHeight;
117
118		// set vertical position
119		switch (this.verticalPosition) {
120			case 'top':
121				if (this.topPanelElement)
122					this.cartElement.style.top = this.topPanelElement.offsetHeight + 5 + 'px';
123				break;
124			case 'vcenter':
125				this.setVerticalCenter(windowHeight);
126				break;
127		}
128
129		// toggle max height
130		if (this.productsElement)
131		{
132			var itemList = this.cartElement.querySelector("[data-role='basket-item-list']");
133			if (this.cartClosed)
134			{
135				if (this.maxHeight)
136				{
137					BX.removeClass(this.cartElement, 'bx-max-height');
138					if (itemList)
139						itemList.style.top = "auto";
140					this.maxHeight = false;
141				}
142			}
143			else // Opened
144			{
145				if (this.maxHeight)
146				{
147					if (this.productsElement.scrollHeight == this.productsElement.clientHeight)
148					{
149						BX.removeClass(this.cartElement, 'bx-max-height');
150						if (itemList)
151							itemList.style.top = "auto";
152						this.maxHeight = false;
153					}
154				}
155				else
156				{
157					if (this.verticalPosition == 'top' || this.verticalPosition == 'vcenter')
158					{
159						if (this.cartElement.offsetTop + this.cartElement.offsetHeight >= windowHeight)
160						{
161							BX.addClass(this.cartElement, 'bx-max-height');
162							if (itemList)
163								itemList.style.top = 82+"px";
164							this.maxHeight = true;
165						}
166					}
167					else
168					{
169						if (this.cartElement.offsetHeight >= windowHeight)
170						{
171							BX.addClass(this.cartElement, 'bx-max-height');
172							if (itemList)
173								itemList.style.top = 82+"px";
174							this.maxHeight = true;
175						}
176					}
177				}
178			}
179
180			if (this.verticalPosition == 'vcenter')
181				this.setVerticalCenter(windowHeight);
182		}
183	},
184
185	refreshCart: function (data)
186	{
187		if (this.itemRemoved)
188		{
189			this.itemRemoved = false;
190			return;
191		}
192		data.sessid = BX.bitrix_sessid();
193		data.siteId = this.siteId;
194		data.templateName = this.templateName;
195		data.arParams = this.arParams;
196		BX.ajax({
197			url: this.ajaxPath,
198			method: 'POST',
199			dataType: 'html',
200			data: data,
201			onsuccess: this.setCartBodyClosure
202		});
203	},
204
205	setCartBody: function (result)
206	{
207		if (this.cartElement)
208			this.cartElement.innerHTML = result.replace(/#CURRENT_URL#/g, this.currentUrl);
209		if (this.fixedPosition)
210			setTimeout(this.fixAfterRenderClosure, 100);
211	},
212
213	removeItemFromCart: function (id)
214	{
215		this.refreshCart ({sbblRemoveItemFromCart: id});
216		this.itemRemoved = true;
217		BX.onCustomEvent('OnBasketChange');
218	}
219};
220
221/* End */
222;; /* /local/templates/rotor/js/main.js?1754488015281676*/
223; /* /local/templates/rotor/components/bitrix/sale.basket.basket.line/header/script.js?17544880155335*/

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.