PageSourceSearch

https://telemach.hr/js/script.js?cb=1.0.0.2134&v=sTEcrl_sW-PG2PDxg3o-Lf33FaKt7TjTUZw1-ZqZSL8

js telemach.hr collected 2026-09-24 19:40:05 UTC 582,205 bytes, 8,114 lines download raw bytes

1// usage: log('inside coolFunc', this, arguments);
2// paulirish.com/2009/log-a-lightweight-wrapper-for-consolelog/
3window.log = function(){
4  log.history = log.history || [];   // store logs to an array for reference
5  log.history.push(arguments);
6  if(this.console) {
7    arguments.callee = arguments.callee.caller;
8    var newarr = [].slice.call(arguments);
9    (typeof console.log === 'object' ? log.apply.call(console.log, console, newarr) : console.log.apply(console, newarr));
10  }
11};
12
13// make it safe to use console.log always
14(function(b){function c(){}for(var d="assert,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,timeStamp,profile,profileEnd,time,timeEnd,trace,warn".split(","),a;a=d.pop();){b[a]=b[a]||c}})((function(){try
15{console.log();return window.console;}catch(err){return window.console={};}})());
16
17
18var EA = window.EA || {};
19EA.Methods = {};
20EA.LoadMethod = function(context){
21	if( context === undefined ) {
22		context = $(document);
23	}
24
25	context.find( '*[data-method]' ).each(function(){
26		var that 		= $(this),
27		    methods 	= that.attr('data-method');
28
29		$.each(methods.split(" "), function(index, methodName){
30			try {
31				var MethodClass 	  = EA.Methods[methodName],
32				    initializedMethod = new MethodClass(that);
33			}
34			catch(e) {
35				// blank
36			}
37		});
38	});
39};
40EA.onReady = function(){
41	EA.LoadMethod();
42	$('html').removeClass('no-js').addClass('js');
43};
44
45$(document).ready(function(){
46	EA.onReady();
47});
48
49/**
50 * Bootstrap Multiselect (http://davidstutz.de/bootstrap-multiselect/)
51 *
52 * Apache License, Version 2.0:
53 * Copyright (c) 2012 - 2022 David Stutz
54 *
55 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
56 * use this file except in compliance with the License. You may obtain a
57 * copy of the License at http://www.apache.org/licenses/LICENSE-2.0
58 *
59 * Unless required by applicable law or agreed to in writing, software
60 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
61 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
62 * License for the specific language governing permissions and limitations
63 * under the License.
64 *
65 * BSD 3-Clause License:
66 * Copyright (c) 2012 - 2022 David Stutz
67 * All rights reserved.
68 *
69 * Redistribution and use in source and binary forms, with or without
70 * modification, are permitted provided that the following conditions are met:
71 *    - Redistributions of source code must retain the above copyright notice,
72 *      this list of conditions and the following disclaimer.
73 *    - Redistributions in binary form must reproduce the above copyright notice,
74 *      this list of conditions and the following disclaimer in the documentation
75 *      and/or other materials provided with the distribution.
76 *    - Neither the name of David Stutz nor the names of its contributors may be
77 *      used to endorse or promote products derived from this software without
78 *      specific prior written permission.
79 *
80 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
81 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
82 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
83 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
84 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
85 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
86 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
87 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
88 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
89 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
90 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
91 */
92(function (root, factory) {
93    // check to see if 'knockout' AMD module is specified if using requirejs
94    if (typeof define === 'function' && define.amd &&
95        typeof require === 'function' && typeof require.specified === 'function' && require.specified('knockout')) {
96
97        // AMD. Register as an anonymous module.
98        define(['jquery', 'knockout'], factory);
99    } else {
100        // Browser globals
101        factory(root.jQuery, root.ko);
102    }
103})(this, function ($, ko) {
104    "use strict";// jshint ;_;
105
106    if (typeof ko !== 'undefined' && ko.bindingHandlers && !ko.bindingHandlers.multiselect) {
107        ko.bindingHandlers.multiselect = {
108            after: ['options', 'value', 'selectedOptions', 'enable', 'disable'],
109
110            init: function (element, valueAccessor, allBindings, viewModel, bindingContext) {
111                var $element = $(element);
112                var config = ko.toJS(valueAccessor());
113
114                $element.multiselect(config);
115
116                if (allBindings.has('options')) {
117                    var options = allBindings.get('options');
vendor: 13,293 bytes, lines 118-459
118                    if (ko.isObservable(options)) {
119                        ko.computed({
120                            read: function () {
121                                options();
122                                setTimeout(function () {
123                                    var ms = $element.data('multiselect');
124                                    if (ms)
125                                        ms.updateOriginalOptions();//Not sure how beneficial this is.
126                                    $element.multiselect('rebuild');
127                                }, 1);
128                            },
129                            disposeWhenNodeIsRemoved: element
130                        });
131                    }
132                }
133
134                //value and selectedOptions are two-way, so these will be triggered even by our own actions.
135                //It needs some way to tell if they are triggered because of us or because of outside change.
136                //It doesn't loop but it's a waste of processing.
137                if (allBindings.has('value')) {
138                    var value = allBindings.get('value');
139                    if (ko.isObservable(value)) {
140                        ko.computed({
141                            read: function () {
142                                value();
143                                setTimeout(function () {
144                                    $element.multiselect('refresh');
145                                }, 1);
146                            },
147                            disposeWhenNodeIsRemoved: element
148                        }).extend({ rateLimit: 100, notifyWhenChangesStop: true });
149                    }
150                }
151
152                //Switched from arrayChange subscription to general subscription using 'refresh'.
153                //Not sure performance is any better using 'select' and 'deselect'.
154                if (allBindings.has('selectedOptions')) {
155                    var selectedOptions = allBindings.get('selectedOptions');
156                    if (ko.isObservable(selectedOptions)) {
157                        ko.computed({
158                            read: function () {
159                                selectedOptions();
160                                setTimeout(function () {
161                                    $element.multiselect('refresh');
162                                }, 1);
163                            },
164                            disposeWhenNodeIsRemoved: element
165                        }).extend({ rateLimit: 100, notifyWhenChangesStop: true });
166                    }
167                }
168
169                var setEnabled = function (enable) {
170                    setTimeout(function () {
171                        if (enable)
172                            $element.multiselect('enable');
173                        else
174                            $element.multiselect('disable');
175                    });
176                };
177
178                if (allBindings.has('enable')) {
179                    var enable = allBindings.get('enable');
180                    if (ko.isObservable(enable)) {
181                        ko.computed({
182                            read: function () {
183                                setEnabled(enable());
184                            },
185                            disposeWhenNodeIsRemoved: element
186                        }).extend({ rateLimit: 100, notifyWhenChangesStop: true });
187                    } else {
188                        setEnabled(enable);
189                    }
190                }
191
192                if (allBindings.has('disable')) {
193                    var disable = allBindings.get('disable');
194                    if (ko.isObservable(disable)) {
195                        ko.computed({
196                            read: function () {
197                                setEnabled(!disable());
198                            },
199                            disposeWhenNodeIsRemoved: element
200                        }).extend({ rateLimit: 100, notifyWhenChangesStop: true });
201                    } else {
202                        setEnabled(!disable);
203                    }
204                }
205
206                ko.utils.domNodeDisposal.addDisposeCallback(element, function () {
207                    $element.multiselect('destroy');
208                });
209            },
210
211            update: function (element, valueAccessor, allBindings, viewModel, bindingContext) {
212                var $element = $(element);
213                var config = ko.toJS(valueAccessor());
214
215                $element.multiselect('setOptions', config);
216                $element.multiselect('rebuild');
217            }
218        };
219    }
220
221    function forEach(array, callback) {
222        for (var index = 0; index < array.length; ++index) {
223            callback(array[index], index);
224        }
225    }
226
227    var multiselectCount = 0;
228
229    /**
230     * Constructor to create a new multiselect using the given select.
231     *
232     * @param {jQuery} select
233     * @param {Object} options
234     * @returns {Multiselect}
235     */
236    function Multiselect(select, options) {
237
238        this.$select = $(select);
239        this.options = this.mergeOptions($.extend({}, options, this.$select.data()));
240
241        // Placeholder via data attributes
242        if (this.$select.attr("data-placeholder")) {
243            this.options.nonSelectedText = this.$select.data("placeholder");
244        }
245
246        // Initialization.
247        // We have to clone to create a new reference.
248        this.originalOptions = this.$select.clone()[0].options;
249        this.query = '';
250        this.searchTimeout = null;
251        this.lastToggledInput = null;
252        this.multiselectId = this.generateUniqueId() + '_' + multiselectCount;
253        this.internalIdCount = 0;
254
255        this.options.multiple = this.$select.attr('multiple') === "multiple";
256        this.options.onChange = $.proxy(this.options.onChange, this);
257        this.options.onSelectAll = $.proxy(this.options.onSelectAll, this);
258        this.options.onDeselectAll = $.proxy(this.options.onDeselectAll, this);
259        this.options.onDropdownShow = $.proxy(this.options.onDropdownShow, this);
260        this.options.onDropdownHide = $.proxy(this.options.onDropdownHide, this);
261        this.options.onDropdownShown = $.proxy(this.options.onDropdownShown, this);
262        this.options.onDropdownHidden = $.proxy(this.options.onDropdownHidden, this);
263        this.options.onInitialized = $.proxy(this.options.onInitialized, this);
264        this.options.onFiltering = $.proxy(this.options.onFiltering, this);
265
266        // Build select all if enabled.
267        this.buildContainer();
268        this.buildButton();
269        this.buildDropdown();
270        this.buildReset();
271        this.buildSelectAll();
272        this.buildDropdownOptions();
273        this.buildFilter();
274        this.buildButtons();
275
276        this.updateButtonText();
277        this.updateSelectAll(true);
278
279        if (this.options.enableClickableOptGroups && this.options.multiple) {
280            this.updateOptGroups();
281        }
282
283        this.options.wasDisabled = this.$select.prop('disabled');
284        if (this.options.disableIfEmpty && $('option', this.$select).length <= 0 && !this.options.wasDisabled) {
285            this.disable(true);
286        }
287
288        this.$select.wrap('<span class="multiselect-native-select" />').after(this.$container);
289        this.$select.prop('tabindex', '-1');
290
291        if (this.options.widthSynchronizationMode !== 'never') {
292            this.synchronizeButtonAndPopupWidth();
293        }
294
295        this.$select.data('multiselect', this);
296        this.options.onInitialized(this.$select, this.$container);
297    }
298
299    Multiselect.prototype = {
300
301        defaults: {
302            /**
303             * Default text function will either print 'None selected' in case no
304             * option is selected or a list of the selected options up to a length
305             * of 3 selected options.
306             *
307             * @param {jQuery} options
308             * @param {jQuery} select
309             * @returns {String}
310             */
311            buttonText: function (selectedOptions, select) {
312                if (this.disabledText.length > 0 && select.prop('disabled')) {
313                    return this.disabledText;
314                }
315                else if (selectedOptions.length === 0) {
316                    return this.nonSelectedText;
317                }
318                else if (this.allSelectedText
319                    && selectedOptions.length === $('option', $(select)).length
320                    && $('option', $(select)).length !== 1
321                    && this.multiple) {
322
323                    if (this.selectAllNumber) {
324                        return this.allSelectedText + ' (' + selectedOptions.length + ')';
325                    }
326                    else {
327                        return this.allSelectedText;
328                    }
329                }
330                else if (this.numberDisplayed != 0 && selectedOptions.length > this.numberDisplayed) {
331                    return selectedOptions.length + ' ' + this.nSelectedText;
332                }
333                else {
334                    var selected = '';
335                    var delimiter = this.delimiterText;
336
337                    selectedOptions.each(function () {
338                        var label = ($(this).attr('label') !== undefined) ? $(this).attr('label') : $(this).text();
339                        selected += label + delimiter;
340                    });
341
342                    return selected.substr(0, selected.length - this.delimiterText.length);
343                }
344            },
345            /**
346             * Updates the title of the button similar to the buttonText function.
347             *
348             * @param {jQuery} options
349             * @param {jQuery} select
350             * @returns {@exp;selected@call;substr}
351             */
352            buttonTitle: function (options, select) {
353                if (options.length === 0) {
354                    return this.nonSelectedText;
355                }
356                else {
357                    var selected = '';
358                    var delimiter = this.delimiterText;
359
360                    options.each(function () {
361                        var label = ($(this).attr('label') !== undefined) ? $(this).attr('label') : $(this).text();
362                        selected += label + delimiter;
363                    });
364                    return selected.substr(0, selected.length - this.delimiterText.length);
365                }
366            },
367            checkboxName: function (option) {
368                return false; // no checkbox name
369            },
370            /**
371             * Create a label.
372             *
373             * @param {jQuery} element
374             * @returns {String}
375             */
376            optionLabel: function (element) {
377                return $(element).attr('label') || $(element).text();
378            },
379            /**
380             * Create a class.
381             *
382             * @param {jQuery} element
383             * @returns {String}
384             */
385            optionClass: function (element) {
386                return $(element).attr('class') || '';
387            },
388            /**
389             * Triggered on change of the multiselect.
390             *
391             * Not triggered when selecting/deselecting options manually.
392             *
393             * @param {jQuery} option
394             * @param {Boolean} checked
395             */
396            onChange: function (option, checked) {
397
398            },
399            /**
400             * Triggered when the dropdown is shown.
401             *
402             * @param {jQuery} event
403             */
404            onDropdownShow: function (event) {
405
406            },
407            /**
408             * Triggered when the dropdown is hidden.
409             *
410             * @param {jQuery} event
411             */
412            onDropdownHide: function (event) {
413
414            },
415            /**
416             * Triggered after the dropdown is shown.
417             *
418             * @param {jQuery} event
419             */
420            onDropdownShown: function (event) {
421
422            },
423            /**
424             * Triggered after the dropdown is hidden.
425             *
426             * @param {jQuery} event
427             */
428            onDropdownHidden: function (event) {
429
430            },
431            /**
432             * Triggered on select all.
433             */
434            onSelectAll: function (selectedOptions) {
435
436            },
437            /**
438             * Triggered on deselect all.
439             */
440            onDeselectAll: function (deselectedOptions) {
441
442            },
443            /**
444             * Triggered after initializing.
445             *
446             * @param {jQuery} $select
447             * @param {jQuery} $container
448             */
449            onInitialized: function ($select, $container) {
450
451            },
452            /**
453             * Triggered on filtering.
454             *
455             * @param {jQuery} $filter
456             */
457            onFiltering: function ($filter) {
458
459            },
460            enableHTML: false,
461            buttonClass: 'custom-select',
462            inheritClass: false,
463            buttonWidth: 'auto',
464            buttonContainer: '<div class="btn-group" />',
465            dropRight: false,
466            dropUp: false,
467            selectedClass: 'active',
468            // Maximum height of the dropdown menu.
469            // If maximum height is exceeded a scrollbar will be displayed.
470            maxHeight: null,
471            includeSelectAllOption: false,
472            includeSelectAllIfMoreThan: 0,
473            selectAllText: ' Select all',
474            selectAllValue: 'multiselect-all',
475            selectAllName: false,
476            selectAllNumber: true,
477            selectAllJustVisible: true,
478            enableFiltering: false,
479            enableCaseInsensitiveFiltering: false,
480            enableFullValueFiltering: false,
481            enableClickableOptGroups: false,
482            enableCollapsibleOptGroups: false,
483            collapseOptGroupsByDefault: false,
484            filterPlaceholder: 'Search',
485            // possible options: 'text', 'value', 'both'
486            filterBehavior: 'text',
487            includeFilterClearBtn: true,
488            preventInputChangeEvent: false,
489            nonSelectedText: window.localization && window.localization['section.multiselect.nonSelectedText'] ? window.localization['section.multiselect.nonSelectedText'] : 'None selected',
490            nSelectedText: window.localization && window.localization['section.multiselect.nSelectedText'] ? window.localization['section.multiselect.nSelectedText'] : 'selected',
491            allSelectedText: window.localization && window.localization['section.multiselect.allSelectedText'] ? window.localization['section.multiselect.allSelectedText'] : 'All selected',
492            resetButtonText: 'Reset',
493            numberDisplayed: 3,
494            disableIfEmpty: false,
495            disabledText: '',
496            delimiterText: ', ',
497            includeResetOption: false,
498            includeResetDivider: false,
vendor: 67,441 bytes, lines 499-2114
499            resetText: 'Reset',
500            indentGroupOptions: true,
501            // possible options: 'never', 'always', 'ifPopupIsSmaller', 'ifPopupIsWider'
502            widthSynchronizationMode: 'never',
503            // possible options: 'left', 'center', 'right'
504            buttonTextAlignment: 'center',
505            enableResetButton: false,
506            templates: {
507                button: '<button type="button" class="multiselect dropdown-toggle" data-toggle="dropdown"><span class="multiselect-selected-text"></span></button>',
508                popupContainer: '<div class="multiselect-container dropdown-menu"></div>',
509                filter: '<div class="multiselect-filter d-flex align-items-center"><i class="fas fa-sm fa-search text-muted"></i><input type="search" class="multiselect-search form-control" /></div>',
510                buttonGroup: '<div class="multiselect-buttons btn-group" style="display:flex;"></div>',
511                buttonGroupReset: '<button type="button" class="multiselect-reset btn btn-secondary btn-block"></button>',
512                option: '<button type="button" class="multiselect-option dropdown-item"></button>',
513                divider: '<div class="dropdown-divider"></div>',
514                optionGroup: '<button type="button" class="multiselect-group dropdown-item"></button>',
515                resetButton: '<div class="multiselect-reset text-center p-2"><button type="button" class="btn btn-sm btn-block btn-outline-secondary"></button></div>'
516            }
517        },
518
519        constructor: Multiselect,
520
521        /**
522         * Builds the container of the multiselect.
523         */
524        buildContainer: function () {
525            this.$container = $(this.options.buttonContainer);
526            if (this.options.widthSynchronizationMode !== 'never') {
527                this.$container.on('show.bs.dropdown', $.proxy(function () {
528                    // the width needs to be synchronized again in case the width of the button changed in between
529                    this.synchronizeButtonAndPopupWidth();
530                    this.options.onDropdownShow();
531                }, this));
532            }
533            else {
534                this.$container.on('show.bs.dropdown', this.options.onDropdownShow);
535            }
536            this.$container.on('hide.bs.dropdown', this.options.onDropdownHide);
537            this.$container.on('shown.bs.dropdown', this.options.onDropdownShown);
538            this.$container.on('hidden.bs.dropdown', this.options.onDropdownHidden);
539        },
540
541        /**
542         * Builds the button of the multiselect.
543         */
544        buildButton: function () {
545            this.$button = $(this.options.templates.button).addClass(this.options.buttonClass);
546            if (this.$select.attr('class') && this.options.inheritClass) {
547                this.$button.addClass(this.$select.attr('class'));
548            }
549            // Adopt active state.
550            if (this.$select.prop('disabled')) {
551                this.disable();
552            }
553            else {
554                this.enable();
555            }
556
557            // Manually add button width if set.
558            if (this.options.buttonWidth && this.options.buttonWidth !== 'auto') {
559                this.$button.css({
560                    'width': '100%' //this.options.buttonWidth,
561                });
562                this.$container.css({
563                    'width': this.options.buttonWidth
564                });
565            }
566
567            if (this.options.buttonTextAlignment) {
568                switch (this.options.buttonTextAlignment) {
569                    case 'left':
570                        this.$button.addClass('text-left');
571                        break;
572                    case 'center':
573                        this.$button.addClass('text-center');
574                        break;
575                    case 'right':
576                        this.$button.addClass('text-right');
577                        break;
578                }
579            }
580
581            // Keep the tab index from the select.
582            var tabindex = this.$select.attr('tabindex');
583            if (tabindex) {
584                this.$button.attr('tabindex', tabindex);
585            }
586
587            this.$container.prepend(this.$button);
588        },
589
590        /**
591         * Builds the popup container representing the dropdown menu.
592         */
593        buildDropdown: function () {
594
595            // Build popup container.
596            this.$popupContainer = $(this.options.templates.popupContainer);
597
598            if (this.options.dropRight) {
599                this.$container.addClass('dropright');
600            }
601            else if (this.options.dropUp) {
602                this.$container.addClass("dropup");
603            }
604
605            // Set max height of dropdown menu to activate auto scrollbar.
606            if (this.options.maxHeight) {
607                // TODO: Add a class for this option to move the css declarations.
608                this.$popupContainer.css({
609                    'max-height': this.options.maxHeight + 'px',
610                    'overflow-y': 'auto',
611                    'overflow-x': 'hidden'
612                });
613            }
614
615            if (this.options.widthSynchronizationMode !== 'never') {
616                this.$popupContainer.css('overflow-x', 'hidden');
617            }
618
619            this.$popupContainer.on("touchstart click", function (e) {
620                e.stopPropagation();
621            });
622
623            this.$container.append(this.$popupContainer);
624        },
625
626        synchronizeButtonAndPopupWidth: function () {
627            if (!this.$popupContainer || this.options.widthSynchronizationMode === 'never') {
628                return;
629            }
630
631            var buttonWidth = this.$button.outerWidth();
632            switch (this.options.widthSynchronizationMode) {
633                case 'always':
634                    this.$popupContainer.css('min-width', buttonWidth);
635                    this.$popupContainer.css('max-width', buttonWidth);
636                    break;
637                case 'ifPopupIsSmaller':
638                    this.$popupContainer.css('min-width', buttonWidth);
639                    break;
640                case 'ifPopupIsWider':
641                    this.$popupContainer.css('max-width', buttonWidth);
642                    break;
643            }
644        },
645
646        /**
647         * Build the dropdown options and binds all necessary events.
648         *
649         * Uses createDivider and createOptionValue to create the necessary options.
650         */
651        buildDropdownOptions: function () {
652
653            this.$select.children().each($.proxy(function (index, element) {
654
655                var $element = $(element);
656                // Support optgroups and options without a group simultaneously.
657                var tag = $element.prop('tagName')
658                    .toLowerCase();
659
660                if ($element.prop('value') === this.options.selectAllValue) {
661                    return;
662                }
663
664                if (tag === 'optgroup') {
665                    this.createOptgroup(element);
666                }
667                else if (tag === 'option') {
668
669                    if ($element.data('role') === 'divider') {
670                        this.createDivider();
671                    }
672                    else {
673                        this.createOptionValue(element, false);
674                    }
675
676                }
677
678                // Other illegal tags will be ignored.
679            }, this));
680
681            // Bind the change event on the dropdown elements.
682            $(this.$popupContainer).off('change', '> *:not(.multiselect-group) input[type="checkbox"], > *:not(.multiselect-group) input[type="radio"]');
683            $(this.$popupContainer).on('change', '> *:not(.multiselect-group) input[type="checkbox"], > *:not(.multiselect-group) input[type="radio"]', $.proxy(function (event) {
684                var $target = $(event.target);
685
686                var checked = $target.prop('checked') || false;
687                var isSelectAllOption = $target.val() === this.options.selectAllValue;
688
689                // Apply or unapply the configured selected class.
690                if (this.options.selectedClass) {
691                    if (checked) {
692                        $target.closest('.multiselect-option')
693                            .addClass(this.options.selectedClass);
694                    }
695                    else {
696                        $target.closest('.multiselect-option')
697                            .removeClass(this.options.selectedClass);
698                    }
699                }
700
701                // Get the corresponding option.
702                var id = $target.attr('id');
703                var $option = this.getOptionById(id);
704
705                var $optionsNotThis = $('option', this.$select).not($option);
706                var $checkboxesNotThis = $('input', this.$container).not($target);
707
708                if (isSelectAllOption) {
709
710                    if (checked) {
711                        this.selectAll(this.options.selectAllJustVisible, true);
712                    }
713                    else {
714                        this.deselectAll(this.options.selectAllJustVisible, true);
715                    }
716                }
717                else {
718                    if (checked) {
719                        $option.prop('selected', true);
720
721                        if (this.options.multiple) {
722                            // Simply select additional option.
723                            $option.prop('selected', true);
724                        }
725                        else {
726                            // Unselect all other options and corresponding checkboxes.
727                            if (this.options.selectedClass) {
728                                $($checkboxesNotThis).closest('.dropdown-item').removeClass(this.options.selectedClass);
729                            }
730
731                            $($checkboxesNotThis).prop('checked', false);
732                            $optionsNotThis.prop('selected', false);
733
734                            // It's a single selection, so close.
735                            this.$button.click();
736                        }
737
738                        if (this.options.selectedClass === "active") {
739                            $optionsNotThis.closest(".dropdown-item").css("outline", "");
740                        }
741                    }
742                    else {
743                        // Unselect option.
744                        $option.prop('selected', false);
745                    }
746
747                    // To prevent select all from firing onChange: #575
748                    this.options.onChange($option, checked);
749
750                    // Do not update select all or optgroups on select all change!
751                    this.updateSelectAll();
752
753                    if (this.options.enableClickableOptGroups && this.options.multiple) {
754                        this.updateOptGroups();
755                    }
756                }
757
758                this.$select.change();
759                this.updateButtonText();
760
761                if (this.options.preventInputChangeEvent) {
762                    return false;
763                }
764            }, this));
765
766            $('.multiselect-option', this.$popupContainer).off('mousedown');
767            $('.multiselect-option', this.$popupContainer).on('mousedown', function (e) {
768                if (e.shiftKey) {
769                    // Prevent selecting text by Shift+click
770                    return false;
771                }
772            });
773
774            $(this.$popupContainer).off('touchstart click', '.multiselect-option, .multiselect-all, .multiselect-group');
775            $(this.$popupContainer).on('touchstart click', '.multiselect-option, .multiselect-all, .multiselect-group', $.proxy(function (event) {
776                event.stopPropagation();
777
778                var $target = $(event.target);
779
780                if (event.shiftKey && this.options.multiple) {
781                    if (!$target.is("input")) { // Handles checkbox selection manually (see https://github.com/davidstutz/bootstrap-multiselect/issues/431)
782                        event.preventDefault();
783                        $target = $target.closest(".multiselect-option").find("input");
784                        $target.prop("checked", !$target.prop("checked"));
785                    }
786                    var checked = $target.prop('checked') || false;
787
788                    if (this.lastToggledInput !== null && this.lastToggledInput !== $target) { // Make sure we actually have a range
789                        var from = this.$popupContainer.find(".multiselect-option:visible").index($target.closest(".multiselect-option"));
790                        var to = this.$popupContainer.find(".multiselect-option:visible").index(this.lastToggledInput.closest(".multiselect-option"));
791
792                        if (from > to) { // Swap the indices
793                            var tmp = to;
794                            to = from;
795                            from = tmp;
796                        }
797
798                        // Make sure we grab all elements since slice excludes the last index
799                        ++to;
800
801                        // Change the checkboxes and underlying options
802                        var range = this.$popupContainer.find(".multiselect-option:not(.multiselect-filter-hidden)").slice(from, to).find("input");
803
804                        range.prop('checked', checked);
805
806                        if (this.options.selectedClass) {
807                            range.closest('.multiselect-option')
808                                .toggleClass(this.options.selectedClass, checked);
809                        }
810
811                        for (var i = 0, j = range.length; i < j; i++) {
812                            var $checkbox = $(range[i]);
813
814                            var $option = this.getOptionById($checkbox.attr('id'));
815
816                            $option.prop('selected', checked);
817                        }
818                    }
819
820                    // Trigger the select "change" event
821                    $target.trigger("change");
822                }
823                else if (!$target.is('input')) {
824                    var $checkbox = $target.closest('.multiselect-option, .multiselect-all').find('.form-check-input');
825                    if ($checkbox.length > 0) {
826                        if (this.options.multiple || !$checkbox.prop('checked')) {
827                            $checkbox.prop('checked', !$checkbox.prop('checked'));
828                            $checkbox.change();
829                        }
830                    }
831                    else if (this.options.enableClickableOptGroups && this.options.multiple && !$target.hasClass("caret-container")) {
832                        var groupItem = $target;
833                        if (!groupItem.hasClass("multiselect-group")) {
834                            groupItem = $target.closest('.multiselect-group');
835                        }
836                        $checkbox = groupItem.find(".form-check-input");
837                        if ($checkbox.length > 0) {
838                            $checkbox.prop('checked', !$checkbox.prop('checked'));
839                            $checkbox.change();
840                        }
841                    }
842
843                    event.preventDefault();
844                }
845
846                // Remembers last clicked option
847                var $input = $target.closest(".multiselect-option").find("input[type='checkbox'], input[type='radio']");
848                if ($input.length > 0) {
849                    this.lastToggledInput = $target;
850                }
851                else {
852                    this.lastToggledInput = null;
853                }
854
855                $target.blur();
856            }, this));
857
858            //Keyboard support.
859            this.$container.off('keydown.multiselect').on('keydown.multiselect', $.proxy(function (event) {
860                var $items = $(this.$container).find(".multiselect-option:not(.disabled), .multiselect-group:not(.disabled), .multiselect-all").filter(":visible");
861                var index = $items.index($items.filter(':focus'));
862                var $search = $('.multiselect-search', this.$container);
863
864                // keyCode 9 == Tab
865                if (event.keyCode === 9 && this.$container.hasClass('show')) {
866                    this.$button.click();
867                }
868                // keyCode 13 = Enter
869                else if (event.keyCode == 13) {
870                    var $current = $items.eq(index);
871                    setTimeout(function () {
872                        $current.focus();
873                    }, 1);
874                }
875                // keyCode 38 = Arrow Up
876                else if (event.keyCode == 38) {
877                    if (index == 0 && !$search.is(':focus')) {
878                        setTimeout(function () {
879                            $search.focus();
880                        }, 1);
881                    }
882                }
883                // keyCode 40 = Arrow Down
884                else if (event.keyCode == 40) {
885                    if ($search.is(':focus')) {
886                        var $first = $items.eq(0);
887                        setTimeout(function () {
888                            $search.blur();
889                            $first.focus();
890                        }, 1);
891                    }
892                    else if (index == -1) {
893                        setTimeout(function () {
894                            $search.focus();
895                        }, 1);
896                    }
897                }
898            }, this));
899
900            if (this.options.enableClickableOptGroups && this.options.multiple) {
901                $(".multiselect-group input", this.$popupContainer).off("change");
902                $(".multiselect-group input", this.$popupContainer).on("change", $.proxy(function (event) {
903                    event.stopPropagation();
904
905                    var $target = $(event.target);
906                    var checked = $target.prop('checked') || false;
907
908                    var $item = $(event.target).closest('.dropdown-item');
909                    var $group = $item.nextUntil(".multiselect-group")
910                        .not('.multiselect-filter-hidden')
911                        .not('.disabled');
912
913                    var $inputs = $group.find("input");
914
915                    var $options = [];
916
917                    if (this.options.selectedClass) {
918                        if (checked) {
919                            $item.addClass(this.options.selectedClass);
920                        }
921                        else {
922                            $item.removeClass(this.options.selectedClass);
923                        }
924                    }
925
926                    $.each($inputs, $.proxy(function (index, input) {
927                        var $input = $(input);
928                        var id = $input.attr('id');
929                        var $option = this.getOptionById(id);
930
931                        if (checked) {
932                            $input.prop('checked', true);
933                            $input.closest('.dropdown-item')
934                                .addClass(this.options.selectedClass);
935
936                            $option.prop('selected', true);
937                        }
938                        else {
939                            $input.prop('checked', false);
940                            $input.closest('.dropdown-item')
941                                .removeClass(this.options.selectedClass);
942
943                            $option.prop('selected', false);
944                        }
945
946                        $options.push($option);
947                    }, this))
948
949                    // Cannot use select or deselect here because it would call updateOptGroups again.
950
951                    this.options.onChange($options, checked);
952
953                    this.$select.change();
954                    this.updateButtonText();
955                    this.updateSelectAll();
956                }, this));
957            }
958
959            if (this.options.enableCollapsibleOptGroups) {
960                let clickableSelector = this.options.enableClickableOptGroups 
961                    ? ".multiselect-group .caret-container"
962                    : ".multiselect-group";
963
964                $(clickableSelector, this.$popupContainer).off("click");
965                $(clickableSelector, this.$popupContainer).on("click", $.proxy(function (event) {
966                    var $group = $(event.target).closest('.multiselect-group');
967                    var $inputs = $group.nextUntil(".multiselect-group").not('.multiselect-filter-hidden');
968
969                    var visible = true;
970                    $inputs.each(function () {
971                        visible = visible && !$(this).hasClass('multiselect-collapsible-hidden');
972                    });
973
974                    if (visible) {
975                        $inputs.hide().addClass('multiselect-collapsible-hidden');
976                        $group.get(0).classList.add("closed");
977                    } else {
978                        $inputs.show().removeClass('multiselect-collapsible-hidden');
979                        $group.get(0).classList.remove("closed");
980                    }
981                }, this));
982            }
983        },
984
985        /**
986         * Create a checkbox container with input and label based on given values
987         * @param {JQuery} $item 
988         * @param {String} label 
989         * @param {String} name 
990         * @param {String} value 
991         * @param {String} inputType 
992         * @returns {JQuery}
993         */
994        createCheckbox: function ($item, labelContent, name, value, title, inputType, internalId) {
995            var $wrapper = $('<span />');
996            $wrapper.addClass("form-check");
997
998            var $checkboxLabel = $('<label class="form-check-label" />');
999            if (this.options.enableHTML && $(labelContent).length > 0) {
1000                $checkboxLabel.html(labelContent);
1001            }
1002            else {
1003                $checkboxLabel.text(labelContent);
1004            }
1005            $wrapper.append($checkboxLabel);
1006
1007            var $checkbox = $('<input class="form-check-input"/>').attr('type', inputType);
1008            $checkbox.val(value);
1009            $wrapper.prepend($checkbox);
1010
1011            if (internalId) {
1012                $checkbox.attr('id', internalId);
1013                $checkboxLabel.attr('for', internalId);
1014            }
1015
1016            if (name) {
1017                $checkbox.attr('name', name);
1018            }
1019
1020            $item.prepend($wrapper);
1021            $item.attr("title", title || labelContent);
1022
1023            return $checkbox;
1024        },
1025
1026        /**
1027         * Create an option using the given select option.
1028         *
1029         * @param {jQuery} element
1030         */
1031        createOptionValue: function (element, isGroupOption) {
1032            var $element = $(element);
1033            if ($element.is(':selected')) {
1034                $element.prop('selected', true);
1035            }
1036
1037            // Support the label attribute on options.
1038            var label = this.options.optionLabel(element);
1039            var classes = this.options.optionClass(element);
1040            var value = $element.val();
1041            var inputType = this.options.multiple ? "checkbox" : "radio";
1042            var title = $element.attr('title');
1043
1044            var $option = $(this.options.templates.option);
1045            $option.addClass(classes);
1046
1047            if (isGroupOption && this.options.indentGroupOptions) {
1048                if (this.options.enableCollapsibleOptGroups) {
1049                    $option.addClass("multiselect-group-option-indented-full")
1050                } 
1051                else {
1052                    $option.addClass("multiselect-group-option-indented");
1053                }
1054            }
1055
1056            // Hide all children items when collapseOptGroupsByDefault is true
1057            if (this.options.collapseOptGroupsByDefault && $(element).parent().prop("tagName").toLowerCase() === "optgroup") {
1058                $option.addClass("multiselect-collapsible-hidden");
1059                $option.hide();
1060            }
1061
1062            var name = this.options.checkboxName($element);
1063
1064            var checkboxId = this.createAndApplyUniqueId($element);
1065            var $checkbox = this.createCheckbox($option, label, name, value, title, inputType, checkboxId);
1066
1067            var selected = $element.prop('selected') || false;
1068
1069            if (value === this.options.selectAllValue) {
1070                $option.addClass("multiselect-all");
1071                $option.removeClass("multiselect-option");
1072                $checkbox.parent().parent()
1073                    .addClass('multiselect-all');
1074            }
1075
1076            this.$popupContainer.append($option);
1077
1078            if ($element.is(':disabled')) {
1079                $checkbox.attr('disabled', 'disabled')
1080                    .prop('disabled', true)
1081                    .closest('.dropdown-item')
1082                    .addClass('disabled');
1083            }
1084
1085            $checkbox.prop('checked', selected);
1086
1087            if (selected && this.options.selectedClass) {
1088                $checkbox.closest('.dropdown-item')
1089                    .addClass(this.options.selectedClass);
1090            }
1091        },
1092
1093        /**
1094         * Creates a divider using the given select option.
1095         *
1096         * @param {jQuery} element
1097         */
1098        createDivider: function (element) {
1099            var $divider = $(this.options.templates.divider);
1100            this.$popupContainer.append($divider);
1101        },
1102
1103        /**
1104         * Creates an optgroup.
1105         *
1106         * @param {jQuery} group
1107         */
1108        createOptgroup: function (group) {
1109            var $group = $(group);
1110            var label = $group.attr("label");
1111            var value = $group.attr("value");
1112            var title = $group.attr('title');
1113
1114            var $groupOption = $("<span class='multiselect-group dropdown-item-text'></span>");
1115
1116            if (this.options.enableClickableOptGroups && this.options.multiple) {
1117                $groupOption = $(this.options.templates.optionGroup);
1118                var checkboxId = this.createAndApplyUniqueId($group);
1119                var $checkbox = this.createCheckbox($groupOption, label, null, value, title, "checkbox", checkboxId);
1120            }
1121            else {
1122                if (this.options.enableHTML) {
1123                    $groupOption.html(" " + label);
1124                }
1125                else {
1126                    $groupOption.text(" " + label);
1127                }
1128            }
1129
1130            var classes = this.options.optionClass(group);
1131            $groupOption.addClass(classes);
1132
1133            if (this.options.enableCollapsibleOptGroups) {
1134                $groupOption.find('.form-check').addClass('d-inline-block');
1135                $groupOption.get(0).insertAdjacentHTML("afterbegin", '<span class="caret-container dropdown-toggle"></span>');
1136            }
1137
1138            if ($group.is(':disabled')) {
1139                $groupOption.addClass('disabled');
1140            }
1141
1142            this.$popupContainer.append($groupOption);
1143
1144            $("option", group).each($.proxy(function ($, group) {
1145                this.createOptionValue(group, true);
1146            }, this));
1147        },
1148
1149        /**
1150         * Build the reset.
1151         *
1152         */
1153        buildReset: function () {
1154            if (this.options.includeResetOption) {
1155
1156                // Check whether to add a divider after the reset.
1157                if (this.options.includeResetDivider) {
1158                    var divider = $(this.options.templates.divider);
1159                    divider.addClass("mt-0");
1160                    this.$popupContainer.prepend(divider);
1161                }
1162
1163                var $resetButton = $(this.options.templates.resetButton);
1164
1165                if (this.options.enableHTML) {
1166                    $('button', $resetButton).html(this.options.resetText);
1167                }
1168                else {
1169                    $('button', $resetButton).text(this.options.resetText);
1170                }
1171
1172                $('button', $resetButton).click($.proxy(function () {
1173                    this.clearSelection();
1174                }, this));
1175
1176                this.$popupContainer.prepend($resetButton);
1177            }
1178        },
1179
1180        /**
1181         * Build the select all.
1182         *
1183         * Checks if a select all has already been created.
1184         */
1185        buildSelectAll: function () {
1186            if (typeof this.options.selectAllValue === 'number') {
1187                this.options.selectAllValue = this.options.selectAllValue.toString();
1188            }
1189
1190            var alreadyHasSelectAll = this.hasSelectAll();
1191
1192            if (!alreadyHasSelectAll && this.options.includeSelectAllOption && this.options.multiple
1193                && $('option', this.$select).length > this.options.includeSelectAllIfMoreThan) {
1194
1195                // Check whether to add a divider after the select all.
1196                if (this.options.includeSelectAllDivider) {
1197                    this.$popupContainer.prepend($(this.options.templates.divider));
1198                }
1199
1200                var $option = $(this.options.templates.li || this.options.templates.option);
1201                var $checkbox = this.createCheckbox($option, this.options.selectAllText, this.options.selectAllName,
1202                    this.options.selectAllValue, this.options.selectAllText, "checkbox", this.createAndApplyUniqueId(null));
1203
1204                $option.addClass("multiselect-all");
1205                $option.removeClass("multiselect-option");
1206                $option.find(".form-check-label").addClass("font-weight-bold");
1207
1208                this.$popupContainer.prepend($option);
1209
1210                $checkbox.prop('checked', false);
1211            }
1212        },
1213
1214        /**
1215         * Builds the filter.
1216         */
1217        buildFilter: function () {
1218
1219            // Build filter if filtering OR case insensitive filtering is enabled and the number of options exceeds (or equals) enableFilterLength.
1220            if (this.options.enableFiltering || this.options.enableCaseInsensitiveFiltering) {
1221                var enableFilterLength = Math.max(this.options.enableFiltering, this.options.enableCaseInsensitiveFiltering);
1222
1223                if (this.$select.find('option').length >= enableFilterLength) {
1224
1225                    this.$filter = $(this.options.templates.filter);
1226                    $('input', this.$filter).attr('placeholder', this.options.filterPlaceholder);
1227
1228                    // Handles optional filter clear button                        
1229                    if (!this.options.includeFilterClearBtn) {
1230                        this.$filter.find(".multiselect-search").attr("type", "text");
1231
1232                        // Remove clear button if the old design of the filter with input groups and separated clear button is used
1233                        this.$filter.find(".multiselect-clear-filter").remove();
1234                    }
1235                    else {
1236                        // Firefox does not support a clear button in search inputs right now therefore it must be added manually
1237                        if (this.isFirefox() && this.$filter.find(".multiselect-clear-filter").length === 0) {
1238                            this.$filter.append("<i class='fas fa-times text-muted multiselect-clear-filter multiselect-moz-clear-filter'></i>");
1239                        }
1240
1241                        this.$filter.find(".multiselect-clear-filter").on('click', $.proxy(function (event) {
1242                            clearTimeout(this.searchTimeout);
1243
1244                            this.query = '';
1245                            this.$filter.find('.multiselect-search').val('');
1246                            $('.dropdown-item', this.$popupContainer).show().removeClass('multiselect-filter-hidden');
1247
1248                            this.updateSelectAll();
1249
1250                            if (this.options.enableClickableOptGroups && this.options.multiple) {
1251                                this.updateOptGroups();
1252                            }
1253
1254                        }, this));
1255                    }
1256
1257                    this.$popupContainer.prepend(this.$filter);
1258
1259                    this.$filter.val(this.query).on('click', function (event) {
1260                        event.stopPropagation();
1261                    }).on('input keydown', $.proxy(function (event) {
1262                        // Cancel enter key default behaviour
1263                        if (event.which === 13) {
1264                            event.preventDefault();
1265                        }
1266
1267                        if (this.isFirefox() && this.options.includeFilterClearBtn) {
1268                            if (event.target.value) {
1269                                this.$filter.find(".multiselect-moz-clear-filter").show();
1270                            }
1271                            else {
1272                                this.$filter.find(".multiselect-moz-clear-filter").hide();
1273                            }
1274                        }
1275
1276                        // This is useful to catch "keydown" events after the browser has updated the control.
1277                        clearTimeout(this.searchTimeout);
1278
1279                        this.searchTimeout = this.asyncFunction($.proxy(function () {
1280
1281                            if (this.query !== event.target.value) {
1282                                this.query = event.target.value;
1283
1284                                var currentGroup, currentGroupVisible;
1285                                $.each($('.multiselect-option, .multiselect-group', this.$popupContainer), $.proxy(function (index, element) {
1286                                    var value = $('input', element).length > 0 ? $('input', element).val() : "";
1287                                    var text = $('.form-check-label', element).text();
1288
1289                                    var filterCandidate = '';
1290                                    if ((this.options.filterBehavior === 'text')) {
1291                                        filterCandidate = text;
1292                                    }
1293                                    else if ((this.options.filterBehavior === 'value')) {
1294                                        filterCandidate = value;
1295                                    }
1296                                    else if (this.options.filterBehavior === 'both') {
1297                                        filterCandidate = text + '\n' + value;
1298                                    }
1299
1300                                    if (value !== this.options.selectAllValue && text) {
1301
1302                                        // By default lets assume that element is not
1303                                        // interesting for this search.
1304                                        var showElement = false;
1305
1306                                        if (this.options.enableCaseInsensitiveFiltering) {
1307                                            filterCandidate = filterCandidate.toLowerCase();
1308                                            this.query = this.query.toLowerCase();
1309                                        }
1310
1311                                        if (this.options.enableFullValueFiltering && this.options.filterBehavior !== 'both') {
1312                                            var valueToMatch = filterCandidate.trim().substring(0, this.query.length);
1313                                            if (this.query.indexOf(valueToMatch) > -1) {
1314                                                showElement = true;
1315                                            }
1316                                        }
1317                                        else if (filterCandidate.indexOf(this.query) > -1) {
1318                                            showElement = true;
1319                                        }
1320
1321                                        // Toggle current element (group or group item) according to showElement boolean.
1322                                        if (!showElement) {
1323                                            $(element).css('display', 'none');
1324                                            $(element).addClass('multiselect-filter-hidden');
1325                                        }
1326                                        if (showElement) {
1327                                            $(element).css('display', 'block');
1328                                            $(element).removeClass('multiselect-filter-hidden');
1329                                        }
1330
1331                                        // Differentiate groups and group items.
1332                                        if ($(element).hasClass('multiselect-group')) {
1333                                            // Remember group status.
1334                                            currentGroup = element;
1335                                            currentGroupVisible = showElement;
1336                                        }
1337                                        else {
1338                                            // Show group name when at least one of its items is visible.
1339                                            if (showElement) {
1340                                                $(currentGroup).show()
1341                                                    .removeClass('multiselect-filter-hidden');
1342                                            }
1343
1344                                            // Show all group items when group name satisfies filter.
1345                                            if (!showElement && currentGroupVisible) {
1346                                                $(element).show()
1347                                                    .removeClass('multiselect-filter-hidden');
1348                                            }
1349                                        }
1350                                    }
1351                                }, this));
1352                            }
1353
1354                            this.updateSelectAll();
1355
1356                            if (this.options.enableClickableOptGroups && this.options.multiple) {
1357                                this.updateOptGroups();
1358                            }
1359
1360                            this.updatePopupPosition();
1361
1362                            this.options.onFiltering(event.target);
1363
1364                        }, this), 300, this);
1365                    }, this));
1366                }
1367            }
1368        },
1369
1370        /**
1371         * Builds the filter.
1372         */
1373        buildButtons: function () {
1374            if (this.options.enableResetButton) {
1375                var $buttonGroup = $(this.options.templates.buttonGroup);
1376                this.$buttonGroupReset = $(this.options.templates.buttonGroupReset).text(this.options.resetButtonText);
1377                $buttonGroup.append(this.$buttonGroupReset);
1378                this.$popupContainer.prepend($buttonGroup);
1379
1380                // We save all options that were previously selected.
1381                this.defaultSelection = {};
1382                $('option', this.$select).each($.proxy(function (index, element) {
1383                    var $option = $(element);
1384                    this.defaultSelection[$option.val()] = $option.prop('selected');
1385                }, this));
1386
1387                this.$buttonGroupReset.on('click', $.proxy(function (event) {
1388                    $('option', this.$select).each($.proxy(function (index, element) {
1389                        var $option = $(element);
1390                        $option.prop('selected', this.defaultSelection[$option.val()]);
1391                    }, this));
1392                    this.refresh();
1393
1394                    if (this.options.enableFiltering) {
1395                        this.$filter.trigger('keydown');
1396                        $('input', this.$filter).val('');
1397                    }
1398                }, this));
1399            }
1400        },
1401
1402        updatePopupPosition: function () {
1403            // prevent gaps between popup and select when filter is used (#1199)
1404            var transformMatrix = this.$popupContainer.css("transform");
1405            var matrixType = transformMatrix.substring(0, transformMatrix.indexOf('('));
1406            var values = transformMatrix.substring(transformMatrix.indexOf('(') + 1, transformMatrix.length - 1);
1407            var valuesArray = values.split(',');
1408
1409            var valueIndex = 5;
1410            if (matrixType === "matrix3d") {
1411                valueIndex = 13;
1412            }
1413
1414            if (valuesArray.length < valueIndex) {
1415                return;
1416            }
1417
1418            var yTransformation = valuesArray[valueIndex];
1419            // Need to check to avoid errors when testing and in some other situations.
1420            yTransformation = typeof yTransformation === 'undefined' ? 0 : yTransformation.trim();
1421            if (yTransformation < 0) {
1422                yTransformation = this.$popupContainer.css("height").replace('px', '') * -1;
1423                valuesArray[valueIndex] = yTransformation;
1424                transformMatrix = matrixType + '(' + valuesArray.join(',') + ')';
1425                this.$popupContainer.css("transform", transformMatrix);
1426            }
1427        },
1428
1429        /**
1430         * Unbinds the whole plugin.
1431         */
1432        destroy: function () {
1433            this.$container.remove();
1434            this.$select.unwrap();
1435            this.$select.show();
1436
1437            // reset original state
1438            this.$select.prop('disabled', this.options.wasDisabled);
1439            this.$select.find('option, optgroup').removeAttr('data-multiselectid');
1440            this.$select.data('multiselect', null);
1441        },
1442
1443        /**
1444         * Refreshs the multiselect based on the selected options of the select.
1445         */
1446        refresh: function () {
1447            var inputs = {};
1448            $('.multiselect-option input', this.$popupContainer).each(function () {
1449                inputs[$(this).val()] = $(this);
1450            });
1451
1452            $('option', this.$select).each($.proxy(function (index, element) {
1453                var $elem = $(element);
1454                var $input = inputs[$(element).val()];
1455
1456                if ($elem.is(':selected')) {
1457                    $input.prop('checked', true);
1458
1459                    if (this.options.selectedClass) {
1460                        $input.closest('.multiselect-option')
1461                            .addClass(this.options.selectedClass);
1462                    }
1463                }
1464                else {
1465                    $input.prop('checked', false);
1466
1467                    if (this.options.selectedClass) {
1468                        $input.closest('.multiselect-option')
1469                            .removeClass(this.options.selectedClass);
1470                    }
1471                }
1472
1473                if ($elem.is(":disabled")) {
1474                    $input.attr('disabled', 'disabled')
1475                        .prop('disabled', true)
1476                        .closest('.multiselect-option')
1477                        .addClass('disabled');
1478                }
1479                else {
1480                    $input.prop('disabled', false)
1481                        .closest('.multiselect-option')
1482                        .removeClass('disabled');
1483                }
1484            }, this));
1485
1486            this.updateButtonText();
1487            this.updateSelectAll();
1488
1489            if (this.options.enableClickableOptGroups && this.options.multiple) {
1490                this.updateOptGroups();
1491            }
1492        },
1493
1494        /**
1495         * Select all options of the given values.
1496         *
1497         * If triggerOnChange is set to true, the on change event is triggered if
1498         * and only if one value is passed.
1499         *
1500         * @param {Array} selectValues
1501         * @param {Boolean} triggerOnChange
1502         */
1503        select: function (selectValues, triggerOnChange) {
1504            if (!$.isArray(selectValues)) {
1505                selectValues = [selectValues];
1506            }
1507
1508            for (var i = 0; i < selectValues.length; i++) {
1509                var value = selectValues[i];
1510
1511                if (value === null || value === undefined) {
1512                    continue;
1513                }
1514
1515                var $checkboxes = this.getInputsByValue(value);
1516                if (!$checkboxes || $checkboxes.length === 0) {
1517                    continue;
1518                }
1519
1520                for (var checkboxIndex = 0; checkboxIndex < $checkboxes.length; ++checkboxIndex) {
1521                    var $checkbox = $checkboxes[checkboxIndex];
1522
1523                    var $option = this.getOptionById($checkbox.attr('id'));
1524                    if ($option === undefined) {
1525                        continue;
1526                    }
1527
1528                    if (this.options.selectedClass) {
1529                        $checkbox.closest('.dropdown-item')
1530                            .addClass(this.options.selectedClass);
1531                    }
1532
1533                    $checkbox.prop('checked', true);
1534                    $option.prop('selected', true);
1535
1536                    if (!this.options.multiple) {
1537                        var $checkboxesNotThis = $('input', this.$container).not($checkbox);
1538                        $($checkboxesNotThis).prop('checked', false);
1539                        $($checkboxesNotThis).closest('.multiselect-option').removeClass("active")
1540
1541                        var $optionsNotThis = $('option', this.$select).not($option);
1542                        $optionsNotThis.prop('selected', false);
1543                    }
1544
1545                    if (triggerOnChange) {
1546                        this.options.onChange($option, true);
1547                    }
1548                }
1549            }
1550
1551            this.updateButtonText();
1552            this.updateSelectAll();
1553
1554            if (this.options.enableClickableOptGroups && this.options.multiple) {
1555                this.updateOptGroups();
1556            }
1557        },
1558
1559        /**
1560         * Clears all selected items.
1561         */
1562        clearSelection: function () {
1563            this.deselectAll(false);
1564            this.updateButtonText();
1565            this.updateSelectAll();
1566
1567            if (this.options.enableClickableOptGroups && this.options.multiple) {
1568                this.updateOptGroups();
1569            }
1570        },
1571
1572        /**
1573         * Deselects all options of the given values.
1574         *
1575         * If triggerOnChange is set to true, the on change event is triggered, if
1576         * and only if one value is passed.
1577         *
1578         * @param {Array} deselectValues
1579         * @param {Boolean} triggerOnChange
1580         */
1581        deselect: function (deselectValues, triggerOnChange) {
1582            if (!this.options.multiple) {
1583                // In single selection mode at least on option needs to be selected
1584                return;
1585            }
1586
1587            if (!$.isArray(deselectValues)) {
1588                deselectValues = [deselectValues];
1589            }
1590
1591            for (var i = 0; i < deselectValues.length; i++) {
1592                var value = deselectValues[i];
1593
1594                if (value === null || value === undefined) {
1595                    continue;
1596                }
1597
1598                var $checkboxes = this.getInputsByValue(value);
1599                if (!$checkboxes || $checkboxes.length === 0) {
1600                    continue;
1601                }
1602
1603                for (var checkboxIndex = 0; checkboxIndex < $checkboxes.length; ++checkboxIndex) {
1604                    var $checkbox = $checkboxes[checkboxIndex];
1605
1606                    var $option = this.getOptionById($checkbox.attr('id'));
1607                    if (!$option) {
1608                        continue;
1609                    }
1610
1611                    if (this.options.selectedClass) {
1612                        $checkbox.closest('.dropdown-item')
1613                            .removeClass(this.options.selectedClass);
1614                    }
1615
1616                    $checkbox.prop('checked', false);
1617                    $option.prop('selected', false);
1618
1619                    if (triggerOnChange) {
1620                        this.options.onChange($option, false);
1621                    }
1622                }
1623            }
1624
1625            this.updateButtonText();
1626            this.updateSelectAll();
1627
1628            if (this.options.enableClickableOptGroups && this.options.multiple) {
1629                this.updateOptGroups();
1630            }
1631        },
1632
1633        /**
1634         * Selects all enabled & visible options.
1635         *
1636         * If justVisible is true or not specified, only visible options are selected.
1637         *
1638         * @param {Boolean} justVisible
1639         * @param {Boolean} triggerOnSelectAll
1640         */
1641        selectAll: function (justVisible, triggerOnSelectAll) {
1642            if (!this.options.multiple) {
1643                // In single selection mode only one option can be selected at a time
1644                return;
1645            }
1646
1647            // Record all changes, i.e., options selected that were not selected before.
1648            var selected = [];
1649            var justVisible = typeof justVisible === 'undefined' ? true : justVisible;
1650
1651            if (justVisible) {
1652                var visibleOptions = $(".multiselect-option:not(.disabled):not(.multiselect-filter-hidden)", this.$popupContainer);
1653                $('input:enabled', visibleOptions).prop('checked', true);
1654                visibleOptions.addClass(this.options.selectedClass);
1655
1656                $('input:enabled', visibleOptions).each($.proxy(function (index, element) {
1657                    var id = $(element).attr('id');
1658                    var option = this.getOptionById(id);
1659                    if (!$(option).prop('selected')) {
1660                        selected.push(option);
1661                    }
1662                    $(option).prop('selected', true);
1663                }, this));
1664            }
1665            else {
1666                var allOptions = $(".multiselect-option:not(.disabled)", this.$popupContainer);
1667                $('input:enabled', allOptions).prop('checked', true);
1668                allOptions.addClass(this.options.selectedClass);
1669
1670                $('input:enabled', allOptions).each($.proxy(function (index, element) {
1671                    var id = $(element).attr('id');
1672                    var option = this.getOptionById(id);
1673                    if (!$(option).prop('selected')) {
1674                        selected.push(option);
1675                    }
1676                    $(option).prop('selected', true);
1677                }, this));
1678            }
1679
1680            $('.multiselect-option input[value="' + this.options.selectAllValue + '"]', this.$popupContainer).prop('checked', true);
1681
1682            if (this.options.enableClickableOptGroups && this.options.multiple) {
1683                this.updateOptGroups();
1684            }
1685
1686            this.updateButtonText();
1687            this.updateSelectAll();
1688
1689            if (triggerOnSelectAll) {
1690                this.options.onSelectAll(selected);
1691            }
1692        },
1693
1694        /**
1695         * Deselects all options.
1696         *
1697         * If justVisible is true or not specified, only visible options are deselected.
1698         *
1699         * @param {Boolean} justVisible
1700         */
1701        deselectAll: function (justVisible, triggerOnDeselectAll) {
1702            if (!this.options.multiple) {
1703                // In single selection mode at least on option needs to be selected
1704                return;
1705            }
1706
1707            // Record changes, i.e., those options that are deselected but were not deselected before.
1708            var deselected = [];
1709            var justVisible = typeof justVisible === 'undefined' ? true : justVisible;
1710
1711            if (justVisible) {
1712                var visibleOptions = $(".multiselect-option:not(.disabled):not(.multiselect-filter-hidden)", this.$popupContainer);
1713                $('input[type="checkbox"]:enabled', visibleOptions).prop('checked', false);
1714                visibleOptions.removeClass(this.options.selectedClass);
1715
1716                $('input[type="checkbox"]:enabled', visibleOptions).each($.proxy(function (index, element) {
1717                    var id = $(element).attr('id');
1718                    var option = this.getOptionById(id);
1719                    if ($(option).prop('selected')) {
1720                        deselected.push(option);
1721                    }
1722                    $(option).prop('selected', false);
1723                }, this));
1724            }
1725            else {
1726                var allOptions = $(".multiselect-option:not(.disabled):not(.multiselect-group)", this.$popupContainer);
1727                $('input[type="checkbox"]:enabled', allOptions).prop('checked', false);
1728                allOptions.removeClass(this.options.selectedClass);
1729
1730                $('input[type="checkbox"]:enabled', allOptions).each($.proxy(function (index, element) {
1731                    var id = $(element).attr('id');
1732                    var option = this.getOptionById(id);
1733                    if ($(option).prop('selected')) {
1734                        deselected.push(option);
1735                    }
1736                    $(option).prop('selected', false);
1737                }, this));
1738            }
1739
1740            $('.multiselect-all input[value="' + this.options.selectAllValue + '"]', this.$popupContainer).prop('checked', false);
1741
1742            if (this.options.enableClickableOptGroups && this.options.multiple) {
1743                this.updateOptGroups();
1744            }
1745
1746            this.updateButtonText();
1747            this.updateSelectAll();
1748
1749            if (triggerOnDeselectAll) {
1750                this.options.onDeselectAll(deselected);
1751            }
1752        },
1753
1754        /**
1755         * Rebuild the plugin.
1756         *
1757         * Rebuilds the dropdown, the filter and the select all option.
1758         */
1759        rebuild: function () {
1760            this.internalIdCount = 0;
1761
1762            this.$popupContainer.html('');
1763            this.$select.find('option, optgroup').removeAttr('data-multiselectid');
1764
1765            // Important to distinguish between radios and checkboxes.
1766            this.options.multiple = this.$select.attr('multiple') === "multiple";
1767
1768            this.buildSelectAll();
1769            this.buildDropdownOptions();
1770            this.buildFilter();
1771            this.buildButtons();
1772
1773            this.updateButtonText();
1774            this.updateSelectAll(true);
1775
1776            if (this.options.enableClickableOptGroups && this.options.multiple) {
1777                this.updateOptGroups();
1778            }
1779
1780            if (this.options.disableIfEmpty) {
1781                if ($('option', this.$select).length <= 0) {
1782                    if (!this.$select.prop('disabled')) {
1783                        this.disable(true);
1784                    }
1785                }
1786                else if (this.$select.data("disabled-by-option")) {
1787                    this.enable();
1788                }
1789            }
1790
1791            if (this.options.dropRight) {
1792                this.$container.addClass('dropright');
1793            }
1794            else if (this.options.dropUp) {
1795                this.$container.addClass('dropup');
1796            }
1797
1798            if (this.options.widthSynchronizationMode !== 'never') {
1799                this.synchronizeButtonAndPopupWidth();
1800            }
1801        },
1802
1803        /**
1804         * The provided data will be used to build the dropdown.
1805         */
1806        dataprovider: function (dataprovider) {
1807
1808            var groupCounter = 0;
1809            var $select = this.$select.empty();
1810
1811            $.each(dataprovider, function (index, option) {
1812                var $tag;
1813
1814                if ($.isArray(option.children)) { // create optiongroup tag
1815                    groupCounter++;
1816
1817                    $tag = $('<optgroup/>').attr({
1818                        label: option.label || 'Group ' + groupCounter,
1819                        disabled: !!option.disabled,
1820                        value: option.value
1821                    });
1822
1823                    forEach(option.children, function (subOption) { // add children option tags
1824                        var attributes = {
1825                            value: subOption.value,
1826                            label: subOption.label !== undefined && subOption.label !== null ? subOption.label : subOption.value,
1827                            title: subOption.title,
1828                            class: subOption.class,
1829                            selected: !!subOption.selected,
1830                            disabled: !!subOption.disabled
1831                        };
1832
1833                        //Loop through attributes object and add key-value for each attribute
1834                        for (var key in subOption.attributes) {
1835                            attributes['data-' + key] = subOption.attributes[key];
1836                        }
1837                        //Append original attributes + new data attributes to option
1838                        $tag.append($('<option/>').attr(attributes));
1839                    });
1840                }
1841                else {
1842                    var attributes = {
1843                        'value': option.value,
1844                        'label': option.label !== undefined && option.label !== null ? option.label : option.value,
1845                        'title': option.title,
1846                        'class': option['class'],
1847                        'selected': !!option['selected'],
1848                        'disabled': !!option['disabled']
1849                    };
1850                    //Loop through attributes object and add key-value for each attribute
1851                    for (var key in option.attributes) {
1852                        attributes['data-' + key] = option.attributes[key];
1853                    }
1854                    //Append original attributes + new data attributes to option
1855                    $tag = $('<option/>').attr(attributes);
1856
1857                    $tag.text(option.label !== undefined && option.label !== null ? option.label : option.value);
1858                }
1859
1860                $select.append($tag);
1861            });
1862
1863            this.rebuild();
1864        },
1865
1866        /**
1867         * Enable the multiselect.
1868         */
1869        enable: function () {
1870            this.$select.prop('disabled', false);
1871            this.$button.prop('disabled', false)
1872                .removeClass('disabled');
1873
1874            this.updateButtonText();
1875        },
1876
1877        /**
1878         * Disable the multiselect.
1879         */
1880        disable: function (disableByOption) {
1881            this.$select.prop('disabled', true);
1882            this.$button.prop('disabled', true)
1883                .addClass('disabled');
1884
1885            if (disableByOption) {
1886                this.$select.data("disabled-by-option", true);
1887            }
1888            else {
1889                this.$select.data("disabled-by-option", null);
1890            }
1891
1892            this.updateButtonText();
1893        },
1894
1895        /**
1896         * Set the options.
1897         *
1898         * @param {Array} options
1899         */
1900        setOptions: function (options) {
1901            this.options = this.mergeOptions(options);
1902        },
1903
1904        /**
1905         * Merges the given options with the default options.
1906         *
1907         * @param {Array} options
1908         * @returns {Array}
1909         */
1910        mergeOptions: function (options) {
1911            return $.extend(true, {}, this.defaults, this.options, options);
1912        },
1913
1914        /**
1915         * Checks whether a select all checkbox is present.
1916         *
1917         * @returns {Boolean}
1918         */
1919        hasSelectAll: function () {
1920            return $('.multiselect-all', this.$popupContainer).length > 0;
1921        },
1922
1923        /**
1924         * Update opt groups.
1925         */
1926        updateOptGroups: function () {
1927            var $groups = $('.multiselect-group', this.$popupContainer)
1928            var selectedClass = this.options.selectedClass;
1929
1930            $groups.each(function () {
1931                var $options = $(this).nextUntil('.multiselect-group')
1932                    .not('.multiselect-filter-hidden')
1933                    .not('.disabled');
1934
1935                var checked = true;
1936                $options.each(function () {
1937                    var $input = $('input', this);
1938
1939                    if (!$input.prop('checked')) {
1940                        checked = false;
1941                    }
1942                });
1943
1944                if (selectedClass) {
1945                    if (checked) {
1946                        $(this).addClass(selectedClass);
1947                    }
1948                    else {
1949                        $(this).removeClass(selectedClass);
1950                    }
1951                }
1952
1953                $('input', this).prop('checked', checked);
1954            });
1955        },
1956
1957        /**
1958         * Updates the select all checkbox based on the currently displayed and selected checkboxes.
1959         */
1960        updateSelectAll: function (notTriggerOnSelectAll) {
1961            if (this.hasSelectAll()) {
1962                var allBoxes = $(".multiselect-option:not(.multiselect-filter-hidden):not(.multiselect-group):not(.disabled) input:enabled", this.$popupContainer);
1963                var allBoxesLength = allBoxes.length;
1964                var checkedBoxesLength = allBoxes.filter(":checked").length;
1965                var selectAllItem = $(".multiselect-all", this.$popupContainer);
1966                var selectAllInput = selectAllItem.find("input");
1967
1968                if (checkedBoxesLength > 0 && checkedBoxesLength === allBoxesLength) {
1969                    selectAllInput.prop("checked", true);
1970                    selectAllItem.addClass(this.options.selectedClass);
1971                }
1972                else {
1973                    selectAllInput.prop("checked", false);
1974                    selectAllItem.removeClass(this.options.selectedClass);
1975                }
1976            }
1977        },
1978
1979        /**
1980         * Update the button text and its title based on the currently selected options.
1981         */
1982        updateButtonText: function () {
1983            var options = this.getSelected();
1984
1985            // First update the displayed button text.
1986            if (this.options.enableHTML) {
1987                $('.multiselect .multiselect-selected-text', this.$container).html(this.options.buttonText(options, this.$select));
1988            }
1989            else {
1990                $('.multiselect .multiselect-selected-text', this.$container).text(this.options.buttonText(options, this.$select));
1991            }
1992
1993            // Now update the title attribute of the button.
1994            $('.multiselect', this.$container).attr('title', this.options.buttonTitle(options, this.$select));
1995            this.$button.trigger('change');
1996        },
1997
1998        /**
1999         * Get all selected options.
2000         *
2001         * @returns {jQUery}
2002         */
2003        getSelected: function () {
2004            return $('option', this.$select).filter(":selected");
2005        },
2006
2007        /**
2008         * Gets a select option by its id
2009         * @param {String} id 
2010         * @returns {JQuery}
2011         */
2012        getOptionById: function (id) {
2013            if (!id) {
2014                return null;
2015            }
2016
2017            return this.$select.find('option[data-multiselectid=' + id + '], optgroup[data-multiselectid=' + id + ']');
2018        },
2019
2020        /**
2021         * Get the input (radio/checkbox) by its value.
2022         *
2023         * @param {String} value
2024         * @returns {jQuery}
2025         */
2026        getInputsByValue: function (value) {
2027            var checkboxes = $('.multiselect-option input:not(.multiselect-search)', this.$popupContainer);
2028            var valueToCompare = value.toString();
2029
2030            var matchingCheckboxes = [];
2031            for (var i = 0; i < checkboxes.length; i = i + 1) {
2032                var checkbox = checkboxes[i];
2033                if (checkbox.value === valueToCompare) {
2034                    matchingCheckboxes.push($(checkbox));
2035                }
2036            }
2037
2038            return matchingCheckboxes;
2039        },
2040
2041        /**
2042         * Used for knockout integration.
2043         */
2044        updateOriginalOptions: function () {
2045            this.originalOptions = this.$select.clone()[0].options;
2046        },
2047
2048        asyncFunction: function (callback, timeout, self) {
2049            var args = Array.prototype.slice.call(arguments, 3);
2050            return setTimeout(function () {
2051                callback.apply(self || window, args);
2052            }, timeout);
2053        },
2054
2055        setAllSelectedText: function (allSelectedText) {
2056            this.options.allSelectedText = allSelectedText;
2057            this.updateButtonText();
2058        },
2059
2060        isFirefox: function () {
2061            var firefoxIdentifier = 'firefox';
2062            var valueNotFoundIndex = -1;
2063
2064            if (navigator && navigator.userAgent) {
2065                return navigator.userAgent.toLocaleLowerCase().indexOf(firefoxIdentifier) > valueNotFoundIndex;
2066            }
2067
2068            return false;
2069        },
2070
2071        /**
2072         * Generate a unique identifier inside the multiselect namespace and adds it as an data attribute to the related element
2073         * @param {JQuery} $relatedElement 
2074         * @returns unique id
2075         */
2076        createAndApplyUniqueId: function ($relatedElement) {
2077            var id = 'multiselect_' + this.multiselectId + '_' + this.internalIdCount++;
2078            if (!!$relatedElement) {
2079                $relatedElement[0].dataset.multiselectid = id;
2080            }
2081            return id;
2082        },
2083
2084        /**
2085         * Generate a unique identifier
2086         * @returns unique id
2087         */
2088        generateUniqueId: function() {
2089            return Math.random().toString(36).substr(2);
2090        }
2091    };
2092
2093    $.fn.multiselect = function (option, parameter, extraOptions) {
2094        return this.each(function () {
2095            var data = $(this).data('multiselect');
2096            var options = typeof option === 'object' && option;
2097
2098            // Initialize the multiselect.
2099            if (!data) {
2100                data = new Multiselect(this, options);
2101            }
2102
2103            // Call multiselect method.
2104            if (typeof option === 'string') {
2105                data[option](parameter, extraOptions);
2106            }
2107        });
2108    };
2109
2110    $.fn.multiselect.Constructor = Multiselect;
2111
2112    $(function () {
2113        $("select[data-role=multiselect]").multiselect();
2114    });
2115
2116});
2117
2118!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.dropkickjs=t():e.dropkickjs=t()}(this,function(){return function(e){function t(s){if(i[s])return i[s].exports;var a=i[s]={i:s,l:!1,exports:{}};return e[s].call(a.exports,a,a.exports,t),a.l=!0,a.exports}var i={};return t.m=e,t.c=i,t.d=function(e,i,s){t.o(e,i)||Object.defineProperty(e,i,{configurable:!1,enumerable:!0,get:s})},t.n=function(e){var i=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(i,"a",i),i},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=0)}([function(e,t,i){"use strict";function s(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=function(){function e(e,t){for(var i=0;i<t.length;i++){var s=t[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(e,s.key,s)}}return function(t,i,s){return i&&e(t.prototype,i),s&&e(t,s),t}}(),o=i(1),d=s(o),r=i(2),c=s(r),h=i(3),u=s(h),f=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),p=window.parent!==window.self,b=void 0,m=function(){function e(t,i){a(this,e),this.sel=t;var s=void 0,n=void 0,l=window.Dropkick;for("string"==typeof this.sel&&"#"===this.sel[0]&&(this.sel=document.getElementById(t.substr(1))),s=0;s<l.uid;s++)if((n=l.cache[s])instanceof e&&n.data.select===this.sel)return d.default.extend(n.data.settings,i),n;if(!this.sel)throw"You must pass a select to DropKick";if(this.sel.length<1)throw"You must have options inside your <select>: "+t;if("SELECT"===this.sel.nodeName)return this.init(this.sel,i)}return l(e,[{key:"init",value:function(t,i){var s,a=window.Dropkick,n=e.build(t,"dk"+a.uid);if(this.data={},this.data.select=t,this.data.elem=n.elem,this.data.settings=d.default.extend({},c.default,i),this.disabled=t.disabled,this.form=t.form,this.length=t.length,this.multiple=t.multiple,this.options=n.options.slice(0),this.selectedIndex=t.selectedIndex,this.selectedOptions=n.selected.slice(0),this.value=t.value,this.data.cacheID=a.uid,a.cache[this.data.cacheID]=this,this.data.settings.initialize.call(this),a.uid+=1,this._changeListener||(t.addEventListener("change",this),this._changeListener=!0),!f||this.data.settings.mobile){if(t.parentNode.insertBefore(this.data.elem,t),t.setAttribute("data-dkCacheId",this.data.cacheID),this.data.elem.addEventListener("click",this),this.data.elem.addEventListener("keydown",this),this.data.elem.addEventListener("keypress",this),this.form&&this.form.addEventListener("reset",this),!this.multiple)for(s=0;s<this.options.length;s++)this.options[s].addEventListener("mouseover",this);b||(document.addEventListener("click",e.onDocClick),p&&parent.document.addEventListener("click",e.onDocClick),b=!0)}return this}},{key:"add",value:function(e,t){var i,s,a;"string"==typeof e&&(i=e,e=document.createElement("option"),e.text=i),"OPTION"===e.nodeName&&(s=d.default.create("li",{class:"dk-option","data-value":e.value,text:e.text,innerHTML:e.innerHTML,role:"option","aria-selected":"false",id:"dk"+this.data.cacheID+"-"+(e.id||e.value.replace(" ","-"))}),d.default.addClass(s,e.className),this.length+=1,e.disabled&&(d.default.addClass(s,"dk-option-disabled"),s.setAttribute("aria-disabled","true")),e.hidden&&(d.default.addClass(s,"dk-option-hidden"),s.setAttribute("aria-hidden","true")),this.data.select.add(e,t),"number"==typeof t&&(t=this.item(t)),a=this.options.indexOf(t),a>-1?(t.parentNode.insertBefore(s,t),this.options.splice(a,0,s)):(this.data.elem.lastChild.appendChild(s),this.options.push(s)),s.addEventListener("mouseover",this),e.selected&&this.select(a))}},{key:"item",value:function(e){return e=e<0?this.options.length+e:e,this.options[e]||null}},{key:"remove",value:function(e){var t=this.item(e);t.parentNode.removeChild(t),this.options.splice(e,1),this.data.select.remove(e),this.select(this.data.select.selectedIndex),this.length-=1}},{key:"close",value:function(){var e,t=this.data.elem;if(!this.isOpen||this.multiple)return!1;for(e=0;e<this.options.length;e++)d.default.removeClass(this.options[e],"dk-option-highlight");
2118t.lastChild.setAttribute("aria-expanded","false"),d.default.removeClass(t.lastChild,"dk-select-options-highlight"),d.default.removeClass(t,"dk-select-open-(up|down)"),this.isOpen=!1,this.data.settings.close.call(this)}},{key:"open",value:function(){var e=void 0,t=void 0,i=void 0,s=void 0,a=void 0,n=void 0,l=this.data.elem,o=l.lastChild,r=void 0!==window.pageXOffset,c="CSS1Compat"===(document.compatMode||""),h=r?window.pageYOffset:c?document.documentElement.scrollTop:document.body.scrollTop;if(a=d.default.offset(l).top-h,n=window.innerHeight-(a+l.offsetHeight),this.isOpen||this.multiple)return!1;o.style.display="block",e=o.offsetHeight,o.style.display="",t=a>e,i=n>e,s=t&&!i?"-up":"-down",this.isOpen=!0,d.default.addClass(l,"dk-select-open"+s),o.setAttribute("aria-expanded","true"),this._scrollTo(this.options.length-1),this._scrollTo(this.selectedIndex),this.data.settings.open.call(this)}},{key:"disable",value:function(e,t){var i="dk-option-disabled";0!==arguments.length&&"boolean"!=typeof e||(t=void 0===e,e=this.data.elem,i="dk-select-disabled",this.disabled=t),void 0===t&&(t=!0),"number"==typeof e&&(e=this.item(e)),t?(e.setAttribute("aria-disabled",!0),d.default.addClass(e,i)):(e.setAttribute("aria-disabled",!1),d.default.removeClass(e,i))}},{key:"hide",value:function(e,t){void 0===t&&(t=!0),e=this.item(e),t?(e.setAttribute("aria-hidden",!0),d.default.addClass(e,"dk-option-hidden")):(e.setAttribute("aria-hidden",!1),d.default.removeClass(e,"dk-option-hidden"))}},{key:"select",value:function(e,t){var i,s,a,n,l=this.data.select;if("number"==typeof e&&(e=this.item(e)),"string"==typeof e)for(i=0;i<this.length;i++)this.options[i].getAttribute("data-value")===e&&(e=this.options[i]);return!(!e||"string"==typeof e||!t&&d.default.hasClass(e,"dk-option-disabled"))&&(d.default.hasClass(e,"dk-option")?(s=this.options.indexOf(e),a=l.options[s],this.multiple?(d.default.toggleClass(e,"dk-option-selected"),a.selected=!a.selected,d.default.hasClass(e,"dk-option-selected")?(e.setAttribute("aria-selected","true"),this.selectedOptions.push(e)):(e.setAttribute("aria-selected","false"),s=this.selectedOptions.indexOf(e),this.selectedOptions.splice(s,1))):(n=this.data.elem.firstChild,this.selectedOptions.length&&(d.default.removeClass(this.selectedOptions[0],"dk-option-selected"),this.selectedOptions[0].setAttribute("aria-selected","false")),d.default.addClass(e,"dk-option-selected"),e.setAttribute("aria-selected","true"),n.setAttribute("aria-activedescendant",e.id),n.className="dk-selected "+a.className,n.innerHTML=a.innerHTML,this.selectedOptions[0]=e,a.selected=!0),this.selectedIndex=l.selectedIndex,this.value=l.value,t||this.data.select.dispatchEvent(new u.default("change",{bubbles:this.data.settings.bubble})),e):void 0)}},{key:"selectOne",value:function(e,t){return this.reset(!0),this._scrollTo(e),this.select(e,t)}},{key:"search",value:function(e,t){var i,s,a,n,l,o,d,r,c=this.data.select.options,h=[];if(!e)return this.options;for(t=t?t.toLowerCase():"strict",t="fuzzy"===t?2:"partial"===t?1:0,r=new RegExp((t?"":"^")+e,"i"),i=0;i<c.length;i++)if(a=c[i].text.toLowerCase(),2==t){for(s=e.toLowerCase().split(""),n=l=o=d=0;l<a.length;)a[l]===s[n]?(o+=1+o,n++):o=0,d+=o,l++;n===s.length&&h.push({e:this.options[i],s:d,i:i})}else r.test(a)&&h.push(this.options[i]);return 2===t&&(h=h.sort(function(e,t){return t.s-e.s||e.i-t.i}).reduce(function(e,t){return e[e.length]=t.e,e},[])),h}},{key:"focus",value:function(){this.disabled||(this.multiple?this.data.elem:this.data.elem.children[0]).focus()}},{key:"reset",value:function(e){var t,i=this.data.select;for(this.selectedOptions.length=0,t=0;t<i.options.length;t++)i.options[t].selected=!1,d.default.removeClass(this.options[t],"dk-option-selected"),this.options[t].setAttribute("aria-selected","false"),!e&&i.options[t].defaultSelected&&this.select(t,!0);this.selectedOptions.length||this.multiple||this.select(0,!0)}},{key:"refresh",value:function(){Object.keys(this).length>0&&(!f||this.data.settings.mobile)&&this.dispose().init(this.data.select,this.data.settings)}},{key:"dispose",value:function(){var e=window.Dropkick;return Object.keys(this).length>0&&(!f||this.data.settings.mobile)&&(delete e.cache[this.data.cacheID],this.data.elem.parentNode.removeChild(this.data.elem),this.data.select.removeAttribute("data-dkCacheId")),this}},{key:"handleEvent",value:function(e){if(!this.disabled)switch(e.type){case"click":this._delegate(e);break;case"keydown":this._keyHandler(e);break;case"keypress":this._searchOptions(e);break;case"mouseover":this._highlight(e);break;case"reset":this.reset();break;case"change":this.data.settings.change.call(this)}}},{key:"_delegate",value:function(e){var t,i,s,a,n=e.target;if(d.default.hasClass(n,"dk-option-disabled"))return!1;if(this.multiple){if(d.default.hasClass(n,"dk-option"))if(t=window.getSelection(),"Range"===t.type&&t.collapseToStart(),e.shiftKey)if(s=this.options.indexOf(this.selectedOptions[0]),a=this.options.indexOf(this.selectedOptions[this.selectedOptions.length-1]),i=this.options.indexOf(n),i>s&&i<a&&(i=s),i>a&&a>s&&(a=s),this.reset(!0),a>i)for(;i<a+1;)this.select(i++);else for(;i>a-1;)this.select(i--);else e.ctrlKey||e.metaKey?this.select(n):(this.reset(!0),this.select(n))}
2118else this[this.isOpen?"close":"open"](),d.default.hasClass(n,"dk-option")&&this.select(n)}},{key:"_highlight",value:function(e){var t,i=e.target;if(!this.multiple){for(t=0;t<this.options.length;t++)d.default.removeClass(this.options[t],"dk-option-highlight");d.default.addClass(this.data.elem.lastChild,"dk-select-options-highlight"),d.default.addClass(i,"dk-option-highlight")}}},{key:"_keyHandler",value:function(e){var t,i,s=this.selectedOptions,a=this.options,n=1,l={tab:9,enter:13,esc:27,space:32,up:38,down:40};switch(e.keyCode){case l.up:n=-1;case l.down:if(e.preventDefault(),t=s[s.length-1],d.default.hasClass(this.data.elem.lastChild,"dk-select-options-highlight"))for(d.default.removeClass(this.data.elem.lastChild,"dk-select-options-highlight"),i=0;i<a.length;i++)d.default.hasClass(a[i],"dk-option-highlight")&&(d.default.removeClass(a[i],"dk-option-highlight"),t=a[i]);n=a.indexOf(t)+n,n>a.length-1?n=a.length-1:n<0&&(n=0),this.data.select.options[n].disabled||(this.reset(!0),this.select(n),this._scrollTo(n));break;case l.space:if(!this.isOpen){e.preventDefault(),this.open();break}case l.tab:case l.enter:for(n=0;n<a.length;n++)d.default.hasClass(a[n],"dk-option-highlight")&&this.select(n);case l.esc:this.isOpen&&(e.preventDefault(),this.close())}}},{key:"_searchOptions",value:function(e){var t,i=this,s=String.fromCharCode(e.keyCode||e.which);void 0===this.data.searchString&&(this.data.searchString=""),function(){i.data.searchTimeout&&clearTimeout(i.data.searchTimeout),i.data.searchTimeout=setTimeout(function(){i.data.searchString=""},1e3)}(),this.data.searchString+=s,t=this.search(this.data.searchString,this.data.settings.search),t.length&&(d.default.hasClass(t[0],"dk-option-disabled")||this.selectOne(t[0]))}},{key:"_scrollTo",value:function(e){var t,i,s,a=this.data.elem.lastChild;if(-1===e||"number"!=typeof e&&!e||!this.isOpen&&!this.multiple)return!1;"number"==typeof e&&(e=this.item(e)),t=d.default.position(e,a).top,i=t-a.scrollTop,s=i+e.offsetHeight,s>a.offsetHeight?(t+=e.offsetHeight,a.scrollTop=t-a.offsetHeight):i<0&&(a.scrollTop=t)}}]),e}();window.Dropkick=m,window.Dropkick.cache={},window.Dropkick.uid=0,m.build=function(e,t){var i,s,a,n=[],l={elem:null,options:[],selected:[]},o=function e(i){var s,a,n,o,r=[];switch(i.nodeName){case"OPTION":s=d.default.create("li",{class:"dk-option ","data-value":i.value,text:i.text,innerHTML:i.innerHTML,role:"option","aria-selected":"false",id:t+"-"+(i.id||i.value.replace(" ","-"))}),d.default.addClass(s,i.className),i.disabled&&(d.default.addClass(s,"dk-option-disabled"),s.setAttribute("aria-disabled","true")),i.hidden&&(d.default.addClass(s,"dk-option-hidden"),s.setAttribute("aria-hidden","true")),i.selected&&(d.default.addClass(s,"dk-option-selected"),s.setAttribute("aria-selected","true"),l.selected.push(s)),l.options.push(this.appendChild(s));break;case"OPTGROUP":for(a=d.default.create("li",{class:"dk-optgroup"}),i.label&&a.appendChild(d.default.create("div",{class:"dk-optgroup-label",innerHTML:i.label})),n=d.default.create("ul",{class:"dk-optgroup-options"}),o=i.children.length;o--;r.unshift(i.children[o]));i.disabled&&(a.classList.add("dk-optgroup-disabled"),r.forEach(function(e){e.disabled=i.disabled})),r.forEach(e,n),this.appendChild(a).appendChild(n)}};for(l.elem=d.default.create("div",{class:"dk-select"+(e.multiple?"-multi":"")}),s=d.default.create("ul",{class:"dk-select-options",id:t+"-listbox",role:"listbox"}),e.disabled&&(d.default.addClass(l.elem,"dk-select-disabled"),l.elem.setAttribute("aria-disabled",!0)),l.elem.id=t+(e.id?"-"+e.id:""),d.default.addClass(l.elem,e.className),e.multiple?(l.elem.setAttribute("tabindex",e.getAttribute("tabindex")||"0"),s.setAttribute("aria-multiselectable","true")):(i=e.options[e.selectedIndex],l.elem.appendChild(d.default.create("div",{class:"dk-selected "+(i?i.className:""),tabindex:e.tabindex||0,innerHTML:i?i.text:"&nbsp;",id:t+"-combobox","aria-live":"assertive","aria-owns":s.id,role:"combobox"})),s.setAttribute("aria-expanded","false")),a=e.children.length;a--;n.unshift(e.children[a]));return n.forEach(o,l.elem.appendChild(s)),l},m.onDocClick=function(e){var t,i,s=window.Dropkick;if(1!==e.target.nodeType)return!1;null!==(t=e.target.getAttribute("data-dkcacheid"))&&s.cache[t].focus();for(i in s.cache)d.default.closest(e.target,s.cache[i].data.elem)||i===t||s.cache[i].disabled||s.cache[i].close()},void 0!==window.jQuery&&(window.jQuery.fn.dropkick=function(){var e=Array.prototype.slice.call(arguments);return jQuery(this).each(function(){e[0]&&"object"!==n(e[0])?"string"==typeof e[0]&&m.prototype[e[0]].apply(new m(this),e.slice(1)):new m(this,e[0]||{})})}),t.default=m},function(e,t,i){"use strict";
2118Object.defineProperty(t,"__esModule",{value:!0});var s=-1!==navigator.appVersion.indexOf("MSIE"),a={hasClass:function(e,t){var i=new RegExp("(^|\\s+)"+t+"(\\s+|$)");return e&&i.test(e.className)},addClass:function(e,t){e&&!this.hasClass(e,t)&&(e.className+=" "+t)},removeClass:function(e,t){var i=new RegExp("(^|\\s+)"+t+"(\\s+|$)");e&&(e.className=e.className.replace(i," "))},toggleClass:function(e,t){this[(this.hasClass(e,t)?"remove":"add")+"Class"](e,t)},extend:function(e){return Array.prototype.slice.call(arguments,1).forEach(function(t){if(t)for(var i in t)e[i]=t[i]}),e},offset:function(e){var t=e.getBoundingClientRect()||{top:0,left:0},i=document.documentElement,a=s?i.scrollTop:window.pageYOffset,n=s?i.scrollLeft:window.pageXOffset;return{top:t.top+a-i.clientTop,left:t.left+n-i.clientLeft}},position:function(e,t){for(var i={top:0,left:0};e&&e!==t;)i.top+=e.offsetTop,i.left+=e.offsetLeft,e=e.parentNode;return i},closest:function(e,t){for(;e;){if(e===t)return e;e=e.parentNode}return!1},create:function(e,t){var i=void 0,s=document.createElement(e);t||(t={});for(i in t)t.hasOwnProperty(i)&&("innerHTML"===i?s.innerHTML=t[i]:s.setAttribute(i,t[i]));return s},deferred:function(e){return function(){var t=this,i=arguments;window.setTimeout(function(){e.apply(t,i)},1)}}};t.default=a},function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s={initialize:function(){},mobile:!0,change:function(){},open:function(){},close:function(){},search:"strict",bubble:!0};t.default=s},function(e,t,i){(function(t){var i=t.CustomEvent;e.exports=function(){try{var e=new i("cat",{detail:{foo:"bar"}});return"cat"===e.type&&"bar"===e.detail.foo}catch(e){}return!1}()?i:"undefined"!=typeof document&&"function"==typeof document.createEvent?function(e,t){var i=document.createEvent("CustomEvent");return t?i.initCustomEvent(e,t.bubbles,t.cancelable,t.detail):i.initCustomEvent(e,!1,!1,void 0),i}:function(e,t){var i=document.createEventObject();return i.type=e,t?(i.bubbles=Boolean(t.bubbles),i.cancelable=Boolean(t.cancelable),i.detail=t.detail):(i.bubbles=!1,i.cancelable=!1,i.detail=void 0),i}}).call(t,i(4))},function(e,t){var i;i=function(){return this}();try{i=i||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(i=window)}e.exports=i}])});
2119"use strict";function _typeof(a){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,c.key,c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),a}var FlipDown=function(){var b=Math.floor;function a(b){var c=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"flipdown",d=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};if(_classCallCheck(this,a),"number"!=typeof b)throw new Error("FlipDown: Constructor expected unix timestamp, got ".concat(_typeof(b)," instead."));"object"===_typeof(c)&&(d=c,c="flipdown"),this.version="0.3.2",this.initialised=!1,this.now=this._getTime(),this.epoch=b,this.countdownEnded=!1,this.hasEndedCallback=null,this.element=document.getElementById(c),this.rotors=[],this.rotorLeafFront=[],this.rotorLeafRear=[],this.rotorTops=[],this.rotorBottoms=[],this.countdown=null,this.daysRemaining=0,this.clockValues={},this.clockStrings={},this.clockValuesAsString=[],this.prevClockValuesAsString=[],this.opts=this._parseOptions(d),this._setOptions(),console.log("FlipDown ".concat(this.version," (Theme: ").concat(this.opts.theme,")"))}return _createClass(a,[{key:"start",value:function a(){return this.initialised||this._init(),this.countdown=setInterval(this._tick.bind(this),1e3),this}},{key:"ifEnded",value:function b(a){return this.hasEndedCallback=function(){a(),this.hasEndedCallback=null},this}},{key:"_getTime",value:function a(){return new Date().getTime()/1e3}},{key:"_hasCountdownEnded",value:function a(){return 0>this.epoch-this.now?(this.countdownEnded=!0,null!=this.hasEndedCallback&&(this.hasEndedCallback(),this.hasEndedCallback=null),!0):(this.countdownEnded=!1,!1)}},{key:"_parseOptions",value:function c(a){var b=["Days","Hours","Minutes","Seconds"];return a.headings&&4===a.headings.length&&(b=a.headings),{theme:a.hasOwnProperty("theme")?a.theme:"dark",headings:b}}},{key:"_setOptions",value:function a(){this.element.classList.add("flipdown__theme-".concat(this.opts.theme))}},{key:"_init",value:function h(){this.initialised=!0,this.daysremaining=this._hasCountdownEnded()?0:b((this.epoch-this.now)/86400).toString().length;for(var a=2>=this.daysremaining?2:this.daysremaining,c=0;c<a+6;c++)this.rotors.push(this._createRotor(0));for(var d=[],c=0;c<a;c++)d.push(this.rotors[c]);this.element.appendChild(this._createRotorGroup(d,0));for(var e,f=a,c=0;3>c;c++){e=[];for(var g=0;2>g;g++)e.push(this.rotors[f]),f++;this.element.appendChild(this._createRotorGroup(e,c+1))}return this.rotorLeafFront=Array.prototype.slice.call(this.element.getElementsByClassName("rotor-leaf-front")),this.rotorLeafRear=Array.prototype.slice.call(this.element.getElementsByClassName("rotor-leaf-rear")),this.rotorTop=Array.prototype.slice.call(this.element.getElementsByClassName("rotor-top")),this.rotorBottom=Array.prototype.slice.call(this.element.getElementsByClassName("rotor-bottom")),this._tick(),this._updateClockValues(!0),this}},{key:"_createRotorGroup",value:function e(a,b){var c=document.createElement("div");c.className="rotor-group";var d=document.createElement("div");return d.className="rotor-group-heading",d.setAttribute("data-before",this.opts.headings[b]),c.appendChild(d),appendChildren(c,a),c}},{key:"_createRotor",value:function h(){var a=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,b=document.createElement("div"),c=document.createElement("div"),d=document.createElement("figure"),e=document.createElement("figure"),f=document.createElement("div"),g=document.createElement("div");return b.className="rotor",c.className="rotor-leaf",d.className="rotor-leaf-rear",e.className="rotor-leaf-front",f.className="rotor-top",g.className="rotor-bottom",d.textContent=a,f.textContent=a,g.textContent=a,appendChildren(b,[c,f,g]),appendChildren(c,[d,e]),b}},{key:"_tick",value:function c(){this.now=this._getTime();var a=0>=this.epoch-this.now?0:this.epoch-this.now;this.clockValues.d=b(a/86400),a-=86400*this.clockValues.d,this.clockValues.h=b(a/3600),a-=3600*this.clockValues.h,this.clockValues.m=b(a/60),a-=60*this.clockValues.m,this.clockValues.s=b(a),this._updateClockValues(),this._hasCountdownEnded()}},{key:"_updateClockValues",value:function e(){function a(){var a=this;
2119this.rotorTop.forEach(function(b,c){b.textContent!=a.clockValuesAsString[c]&&(b.textContent=a.clockValuesAsString[c])})}function b(){var a=this;this.rotorLeafRear.forEach(function(b,c){if(b.textContent!=a.clockValuesAsString[c]){b.textContent=a.clockValuesAsString[c],b.parentElement.classList.add("flipped");var d=setInterval(function(){b.parentElement.classList.remove("flipped"),clearInterval(d)}.bind(a),500)}})}var c=this,d=!!(0<arguments.length&&void 0!==arguments[0])&&arguments[0];this.clockStrings.d=pad(this.clockValues.d,2),this.clockStrings.h=pad(this.clockValues.h,2),this.clockStrings.m=pad(this.clockValues.m,2),this.clockStrings.s=pad(this.clockValues.s,2),this.clockValuesAsString=(this.clockStrings.d+this.clockStrings.h+this.clockStrings.m+this.clockStrings.s).split(""),this.rotorLeafFront.forEach(function(a,b){a.textContent=c.prevClockValuesAsString[b]}),this.rotorBottom.forEach(function(a,b){a.textContent=c.prevClockValuesAsString[b]}),d?(a.call(this),b.call(this)):(setTimeout(a.bind(this),500),setTimeout(b.bind(this),500)),this.prevClockValuesAsString=this.clockValuesAsString}}]),a}();function pad(a,b){return a=a.toString(),a.length<b?pad("0"+a,b):a}function appendChildren(a,b){b.forEach(function(b){a.appendChild(b)})}
2120/*!
2121 * GSAP 3.5.1
2122 * https://greensock.com
2123 *
2124 * @license Copyright 2020, GreenSock. All rights reserved.
2125 * Subject to the terms at https://greensock.com/standard-license or for Club GreenSock members, the agreement issued with that membership.
2126 * @author: Jack Doyle, [email protected]
2127 */
2128
2129!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).window=t.window||{})}(this,function(e){"use strict";function _inheritsLoose(t,e){t.prototype=Object.create(e.prototype),(t.prototype.constructor=t).__proto__=e}function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function n(t){return"string"==typeof t}function o(t){return"function"==typeof t}function p(t){return"number"==typeof t}function q(t){return void 0===t}function r(t){return"object"==typeof t}function s(t){return!1!==t}function t(){return"undefined"!=typeof window}function u(t){return o(t)||n(t)}function K(t){return(l=mt(t,ot))&&ae}function L(t,e){return console.warn("Invalid property",t,"set to",e,"Missing plugin? gsap.registerPlugin()")}function M(t,e){return!e&&console.warn(t)}function N(t,e){return t&&(ot[t]=e)&&l&&(l[t]=e)||ot}function O(){return 0}function Y(t){var e,i,n=t[0];if(r(n)||o(n)||(t=[t]),!(e=(n._gsap||{}).harness)){for(i=_t.length;i--&&!_t[i].targetTest(n););e=_t[i]}for(i=t.length;i--;)t[i]&&(t[i]._gsap||(t[i]._gsap=new It(t[i],e)))||t.splice(i,1);return t}function Z(t){return t._gsap||Y(bt(t))[0]._gsap}function $(t,e,r){return(r=t[e])&&o(r)?t[e]():q(r)&&t.getAttribute&&t.getAttribute(e)||r}function _(t,e){return(t=t.split(",")).forEach(e)||t}function aa(t){return Math.round(1e5*t)/1e5||0}function ba(t,e){for(var r=e.length,i=0;t.indexOf(e[i])<0&&++i<r;);return i<r}function ca(t,e,r){var i,n=p(t[1]),a=(n?2:1)+(e<2?0:1),o=t[a];if(n&&(o.duration=t[1]),o.parent=r,e){for(i=o;r&&!("immediateRender"in i);)i=r.vars.defaults||{},r=s(r.vars.inherit)&&r.parent;o.immediateRender=s(i.immediateRender),e<2?o.runBackwards=1:o.startAt=t[a-1]}return o}function da(){var t,e,r=ht.length,i=ht.slice(0);for(lt={},t=ht.length=0;t<r;t++)(e=i[t])&&e._lazy&&(e.render(e._lazy[0],e._lazy[1],!0)._lazy=0)}function ea(t,e,r,i){ht.length&&da(),t.render(e,r,i),ht.length&&da()}function fa(t){var e=parseFloat(t);return(e||0===e)&&(t+"").match(st).length<2?e:n(t)?t.trim():t}function ga(t){return t}function ha(t,e){for(var r in e)r in t||(t[r]=e[r]);return t}function ia(t,e){for(var r in e)r in t||"duration"===r||"ease"===r||(t[r]=e[r])}function ka(t,e){for(var i in e)t[i]=r(e[i])?ka(t[i]||(t[i]={}),e[i]):e[i];return t}function la(t,e){var r,i={};for(r in t)r in e||(i[r]=t[r]);return i}function ma(t){var e=t.parent||E,r=t.keyframes?ia:ha;if(s(t.inherit))for(;e;)r(t,e.vars.defaults),e=e.parent||e._dp;return t}function pa(t,e,r,i){void 0===r&&(r="_first"),void 0===i&&(i="_last");var n=e._prev,a=e._next;n?n._next=a:t[r]===e&&(t[r]=a),a?a._prev=n:t[i]===e&&(t[i]=n),e._next=e._prev=e.parent=null}function qa(t,e){!t.parent||e&&!t.parent.autoRemoveChildren||t.parent.remove(t),t._act=0}function ra(t,e){if(t&&(!e||e._end>t._dur||e._start<0))for(var r=t;r;)r._dirty=1,r=r.parent;return t}function ua(t){return t._repeat?gt(t._tTime,t=t.duration()+t._rDelay)*t:0}function wa(t,e){return(t-e._start)*e._ts+(0<=e._ts?0:e._dirty?e.totalDuration():e._tDur)}function xa(t){return t._end=aa(t._start+(t._tDur/Math.abs(t._ts||t._rts||U)||0))}function ya(t,e){var r=t._dp;return r&&r.smoothChildTiming&&t._ts&&(t._start=aa(t._dp._time-(0<t._ts?e/t._ts:((t._dirty?t.totalDuration():t._tDur)-e)/-t._ts)),xa(t),r._dirty||ra(r,t)),t}function za(t,e){var r;if((e._time||e._initted&&!e._dur)&&(r=wa(t.rawTime(),e),(!e._dur||yt(0,e.totalDuration(),r)-e._tTime>U)&&e.render(r,!0)),ra(t,e)._dp&&t._initted&&t._time>=t._dur&&t._ts){if(t._dur<t.duration())for(r=t;r._dp;)0<=r.rawTime()&&r.totalTime(r._tTime),r=r._dp;t._zTime=-U}}function Aa(t,e,r,i){return e.parent&&qa(e),e._start=aa(r+e._delay),e._end=aa(e._start+(e.totalDuration()/Math.abs(e.timeScale())||0)),function _addLinkedListItem(t,e,r,i,n){void 0===r&&(r="_first"),void 0===i&&(i="_last");var a,s=t[i];if(n)for(a=e[n];s&&s[n]>a;)s=s._prev;s?(e._next=s._next,s._next=e):(e._next=t[r],t[r]=e),e._next?e._next._prev=e:t[i]=e,e._prev=s,e.parent=e._dp=t}(t,e,"_first","_last",t._sort?"_start":0),t._recent=e,i||za(t,e),t}function Ba(t,e){return(ot.ScrollTrigger||L("scrollTrigger",e))&&ot.ScrollTrigger.create(e,t)}function Ca(t,e,r,i){return Nt(t,e),t._initted?!r&&t._pt&&(t._dur&&!1!==t.vars.lazy||!t._dur&&t.vars.lazy)&&d!==At.frame?(ht.push(t),t._lazy=[e,i],1):void 0:1}function Fa(t,e,r,i){var n=t._repeat,a=aa(e)||0,s=t._tTime/t._tDur;return s&&!i&&(t._time*=a/t._dur),t._dur=a,t._tDur=n?n<0?1e10:aa(a*(n+1)+t._rDelay*n):a,s&&!i?ya(t,t._tTime=t._tDur*s):t.parent&&xa(t),r||ra(t.parent,t),t}function Ga(t){return t instanceof Bt?ra(t):Fa(t,t._dur)}function Ia(t,e){var r,i,a=t.labels,s=t._recent||vt,o=t.duration()>=B?s.endTime(!1):t._dur;return n(e)&&(isNaN(e)||e in a)?"<"===(r=e.charAt(0))||">"===r?("<"===r?s._start:s.endTime(0<=s._repeat))+(parseFloat(e.substr(1))||0):(r=e.indexOf("="))<0?(e in a||(a[e]=o),a[e]):(i=+(e.charAt(r-1)+e.substr(r+1)),1<r?Ia(t,e.substr(0,r-1))+i:o+i):null==e?o:+e}function Ja(t,e){return t||0===t?e(t):e}function La(t){return(t=(t+"").substr((parseFloat(t)+"").length))&&isNaN(t)?t:""}function Oa(t,e){return t&&r(t)&&"length"in t&&(!e&&!t.length||t.length-1 
vendor: 12,314 bytes, line 2129
2129in t&&r(t[0]))&&!t.nodeType&&t!==i}function Ra(t){return t.sort(function(){return.5-Math.random()})}function Sa(t){if(o(t))return t;var _=r(t)?t:{each:t},c=Rt(_.ease),m=_.from||0,g=parseFloat(_.base)||0,v={},e=0<m&&m<1,y=isNaN(m)||e,T=_.axis,b=m,w=m;return n(m)?b=w={center:.5,edges:.5,end:1}[m]||0:!e&&y&&(b=m[0],w=m[1]),function(t,e,r){var i,n,a,s,o,u,h,l,f,d=(r||_).length,p=v[d];if(!p){if(!(f="auto"===_.grid?0:(_.grid||[1,B])[1])){for(h=-B;h<(h=r[f++].getBoundingClientRect().left)&&f<d;);f--}for(p=v[d]=[],i=y?Math.min(f,d)*b-.5:m%f,n=y?d*w/f-.5:m/f|0,l=B,u=h=0;u<d;u++)a=u%f-i,s=n-(u/f|0),p[u]=o=T?Math.abs("y"===T?s:a):J(a*a+s*s),h<o&&(h=o),o<l&&(l=o);"random"===m&&Ra(p),p.max=h-l,p.min=l,p.v=d=(parseFloat(_.amount)||parseFloat(_.each)*(d<f?d-1:T?"y"===T?d/f:f:Math.max(f,d/f))||0)*("edges"===m?-1:1),p.b=d<0?g-d:g,p.u=La(_.amount||_.each)||0,c=c&&d<0?Ft(c):c}return d=(p[t]-p.min)/p.max||0,aa(p.b+(c?c(d):d)*p.v)+p.u}}function Ta(e){var r=e<1?Math.pow(10,(e+"").length-2):1;return function(t){return Math.floor(Math.round(parseFloat(t)/e)*e*r)/r+(p(t)?0:La(t))}}function Ua(u,t){var h,l,e=tt(u);return!e&&r(u)&&(h=e=u.radius||B,u.values?(u=bt(u.values),(l=!p(u[0]))&&(h*=h)):u=Ta(u.increment)),Ja(t,e?o(u)?function(t){return l=u(t),Math.abs(l-t)<=h?l:t}:function(t){for(var e,r,i=parseFloat(l?t.x:t),n=parseFloat(l?t.y:0),a=B,s=0,o=u.length;o--;)(e=l?(e=u[o].x-i)*e+(r=u[o].y-n)*r:Math.abs(u[o]-i))<a&&(a=e,s=o);return s=!h||a<=h?u[s]:t,l||s===t||p(t)?s:s+La(t)}:Ta(u))}function Va(t,e,r,i){return Ja(tt(t)?!e:!0===r?!!(r=0):!i,function(){return tt(t)?t[~~(Math.random()*t.length)]:(r=r||1e-5)&&(i=r<1?Math.pow(10,(r+"").length-2):1)&&Math.floor(Math.round((t+Math.random()*(e-t))/r)*r*i)/i})}function Za(e,r,t){return Ja(t,function(t){return e[~~r(t)]})}function ab(t){for(var e,r,i,n,a=0,s="";~(e=t.indexOf("random(",a));)i=t.indexOf(")",e),n="["===t.charAt(e+7),r=t.substr(e+7,i-e-7).match(n?st:et),s+=t.substr(a,e-a)+Va(n?r:+r[0],n?0:+r[1],+r[2]||1e-5),a=i+1;return s+t.substr(a,t.length-a)}function db(t,e,r){var i,n,a,s=t.labels,o=B;for(i in s)(n=s[i]-e)<0==!!r&&n&&o>(n=Math.abs(n))&&(a=i,o=n);return a}function fb(t){return qa(t),t.progress()<1&&xt(t,"onInterrupt"),t}function kb(t,e,r){return(6*(t=t<0?t+1:1<t?t-1:t)<1?e+(r-e)*t*6:t<.5?r:3*t<2?e+(r-e)*(2/3-t)*6:e)*kt+.5|0}function lb(t,e,r){var i,n,a,s,o,u,h,l,f,d,_=t?p(t)?[t>>16,t>>8&kt,t&kt]:0:Ot.black;if(!_){if(","===t.substr(-1)&&(t=t.substr(0,t.length-1)),Ot[t])_=Ot[t];else if("#"===t.charAt(0))4===t.length&&(t="#"+(i=t.charAt(1))+i+(n=t.charAt(2))+n+(a=t.charAt(3))+a),_=[(t=parseInt(t.substr(1),16))>>16,t>>8&kt,t&kt];else if("hsl"===t.substr(0,3))if(_=d=t.match(et),e){if(~t.indexOf("="))return _=t.match(rt),r&&_.length<4&&(_[3]=1),_}else s=+_[0]%360/360,o=_[1]/100,i=2*(u=_[2]/100)-(n=u<=.5?u*(o+1):u+o-u*o),3<_.length&&(_[3]*=1),_[0]=kb(s+1/3,i,n),_[1]=kb(s,i,n),_[2]=kb(s-1/3,i,n);else _=t.match(et)||Ot.transparent;_=_.map(Number)}return e&&!d&&(i=_[0]/kt,n=_[1]/kt,a=_[2]/kt,u=((h=Math.max(i,n,a))+(l=Math.min(i,n,a)))/2,h===l?s=o=0:(f=h-l,o=.5<u?f/(2-h-l):f/(h+l),s=h===i?(n-a)/f+(n<a?6:0):h===n?(a-i)/f+2:(i-n)/f+4,s*=60),_[0]=~~(s+.5),_[1]=~~(100*o+.5),_[2]=~~(100*u+.5)),r&&_.length<4&&(_[3]=1),_}function mb(t){var r=[],i=[],n=-1;return t.split(Mt).forEach(function(t){var e=t.match(it)||[];r.push.apply(r,e),i.push(n+=e.length+1)}),r.c=i,r}function nb(t,e,r){var i,n,a,s,o="",u=(t+o).match(Mt),h=e?"hsla(":"rgba(",l=0;if(!u)return t;if(u=u.map(function(t){return(t=lb(t,e,1))&&h+(e?t[0]+","+t[1]+"%,"+t[2]+"%,"+t[3]:t.join(","))+")"}),r&&(a=mb(t),(i=r.c).join(o)!==a.c.join(o)))for(s=(n=t.replace(Mt,"1").split(it)).length-1;l<s;l++)o+=n[l]+(~i.indexOf(l)?u.shift()||h+"0,0,0,0)":(a.length?a:u.length?u:r).shift());if(!n)for(s=(n=t.split(Mt)).length-1;l<s;l++)o+=n[l]+u[l];return o+n[s]}function qb(t){var e,r=t.join(" ");if(Mt.lastIndex=0,Mt.test(r))return e=Ct.test(r),t[1]=nb(t[1],e),t[0]=nb(t[0],e,mb(t[1])),!0}function zb(t){var e=(t+"").split("("),r=Dt[e[0]];return r&&1<e.length&&r.config?r.config.apply(null,~t.indexOf("{")?[function _parseObjectInString(t){for(var e,r,i,n={},a=t.substr(1,t.length-3).split(":"),s=a[0],o=1,u=a.length;o<u;o++)r=a[o],e=o!==u-1?r.lastIndexOf(","):r.length,i=r.substr(0,e),n[s]=isNaN(i)?i.replace(zt,"").trim():+i,s=r.substr(e+1).trim();return n}(e[1])]:function _valueInParentheses(t){var e=t.indexOf("(")+1,r=t.indexOf(")"),i=t.indexOf("(",e);return t.substring(e,~i&&i<r?t.indexOf(")",r+1):r)}(t).split(",").map(fa)):Dt._CE&&St.test(t)?Dt._CE("",t):r}function Bb(t,e){for(var r,i=t._first;i;)i instanceof Bt?Bb(i,e):!i.vars.yoyoEase||i._yoyo&&i._repeat||i._yoyo===e||(i.timeline?Bb(i.timeline,e):(r=i._ease,i._ease=i._yEase,i._yEase=r,i._yoyo=e)),i=i._next}function Db(t,e,r,i){void 0===r&&(r=function easeOut(t){return 1-e(1-t)}),void 0===i&&(i=function easeInOut(t){return t<.5?e(2*t)/2:1-e(2*(1-t))/2});var n,a={easeIn:e,easeOut:r,easeInOut:i};return _(t,function(t){for(var e in Dt[t]=ot[t]=a,Dt[n=t.toLowerCase()]=r,a)Dt[n+("easeIn"===e?".in":"easeOut"===e?".out":".inOut")]=Dt[t+"."+e]=a[e]}),a}function Eb(e){return function(t){return t<.5?(1-e(1-2*t))/2:.5+e(2*(t-.5))/2}}function Fb(r,t,e){function ul(t){return 1===t?1:i*Math.pow(2,-10*t)*W((t-a)*n)+1}var i=1<=t?t:1,n=(e||(r?.3:.45))/(t<1?t:1),a=n/V*(Math.asin(1/i)||0),s="out"===r?ul:"in"===r?function(t){return 1-ul(1-t)}:Eb(ul);return n=V/n,s.config=function(t,e){return Fb(r,t,e)},s}function Gb(e,r){function Cl(t){return t?--t*t*((r+1)*t+r)+1:0}void 0===r&&(r=1.70158);var t="out"===e?Cl:"in"===e?function(t){return 1-Cl(1-t)}:Eb(Cl);return t.config=function(t){return Gb(e,t)},t}var E,i,a,h,l,f,d,c,m,g,v,y,T,b,w,x,k,C,A,P,D,S,z,F,R,j={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},I={duration:.5,overwrite:!1,delay:0},B=1e8,U=1/B,V=2*Math.PI,X=V/4,G=0,J=Math.sqrt,Q=Math.cos,W=Math.sin,H="function"==typeof ArrayBuffer&&ArrayBuffer.isView||function(){},tt=Array.isArray,et=/(?:-?\.?\d|\.)+/gi,rt=/[-+=.]*\d+[.e\-+]*\d*[e\-\+]*\d*/g,it=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,nt=/[-+=.]*\d+(?:\.|e-|e)*\d*/gi,at=/[+-]=-?[\.\d]+/,st=/[#\-+.]*\b[a-z\d-=+%.]+/gi,ot={},ut={},ht=[],lt={},ft={},dt={},pt=30,_t=[],ct="",mt=function _merge(t,e){for(var r in e)t[r]=e[r];return t},gt=function _animationCycle(t,e){return(t/=e)&&~~t===t?~~t-1:~~t},vt={_start:0,endTime:O},yt=function _clamp(t,e,r){return r<t?t:e<r?e:r},Tt=[].slice,bt=function toArray(t,e){return!n(t)||e||!a&&Pt()?tt(t)?function _flatten(t,e,r){return void 0===r&&(r=[]),t.forEach(function(t){return n(t)&&!e||Oa(t,1)?r.push.apply(r,bt(t)):r.push(t)})||r}(t,e):Oa(t)?Tt.call(t,0):t?[t]:[]:Tt.call(h.querySelectorAll(t),0)},wt=function mapRange(e,t,r,i,n){var a=t-e,s=i-r;return Ja(n,function(t){return r+((t-e)/a*s||0)})},xt=function _callback(t,e,r){var i,n,a=t.vars,s=a[e];if(s)return i=a[e+"Params"],n=a.callbackScope||t,r&&ht.length&&da(),i?s.apply(n,i):s.call(n)},kt=255,Ot={aqua:[0,kt,kt],lime:[0,kt,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,kt],navy:[0,0,128],white:[kt,kt,kt],olive:[128,128,0],yellow:[kt,kt,0],orange:[kt,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[kt,0,0],pink:[kt,192,203],cyan:[0,kt,kt],transparent:[kt,kt,kt,0]},Mt=function(){var t,e="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3}){1,2}\\b";for(t in Ot)e+="|"+t+"\\b";return new RegExp(e+")","gi")}(),Ct=/hsl[a]?\(/,At=(x=Date.now,k=500,C=33,A=x(),P=A,S=D=1e3/240,T={time:0,frame:0,tick:function tick(){qk(!0)},deltaRatio:function deltaRatio(t){return b/(1e3/(t||60))},wake:function wake(){f&&(!a&&t()&&(i=a=window,h=i.document||{},ot.gsap=ae,(i.gsapVersions||(i.gsapVersions=[])).push(ae.version),K(l||i.GreenSockGlobals||!i.gsap&&i||{}),y=i.requestAnimationFrame),g&&T.sleep(),v=y||function(t){return setTimeout(t,S-1e3*T.time+1|0)},m=1,qk(2))},sleep:function sleep(){(y?i.cancelAnimationFrame:clearTimeout)(g),m=0,v=O},lagSmoothing:function lagSmoothing(t,e){k=t||1e8,C=Math.min(e,k,0)},fps:function fps(t){D=1e3/(t||240),S=1e3*T.time+D},add:function add(t){z.indexOf(t)<0&&z.push(t),Pt()},remove:function remove(t){var e;~(e=z.indexOf(t))&&z.splice(e,1)&&e<=w&&w--},_listeners:z=[]}),Pt=function _wake(){return!m&&At.wake()},Dt={},St=/^[\d.\-M][\d.\-,\s]/,zt=/["']/g,Ft=function _invertEase(e){return function(t){return 1-e(1-t)}},Rt=function _parseEase(t,e){return t&&(o(t)?t:Dt[t]||zb(t))||e};function qk(t){var e,r,i,n,a=x()-P,s=!0===t;if(k<a&&(A+=a-C),(0<(e=(i=(P+=a)-A)-S)||s)&&(n=++T.frame,b=i-1e3*T.time,T.time=i/=1e3,S+=e+(D<=e?4:D-e),r=1),s||(g=v(qk)),r)for(w=0;w<z.length;w++)z[w](i,b,n,t)}function Tl(t){return t<R?F*t*t:t<.7272727272727273?F*Math.pow(t-1.5/2.75,2)+.75:t<.9090909090909092?F*(t-=2.25/2.75)*t+.9375:F*Math.pow(t-2.625/2.75,2)+.984375}_("Linear,Quad,Cubic,Quart,Quint,Strong",function(t,e){var r=e<5?e+1:e;Db(t+",Power"+(r-1),e?function(t){return Math.pow(t,r)}:function(t){return t},function(t){return 1-Math.pow(1-t,r)},function(t){return t<.5?Math.pow(2*t,r)/2:1-Math.pow(2*(1-t),r)/2})}),Dt.Linear.easeNone=Dt.none=Dt.Linear.easeIn,Db("Elastic",Fb("in"),Fb("out"),Fb()),F=7.5625,R=1/2.75,Db("Bounce",function(t){return 1-Tl(1-t)},Tl),Db("Expo",function(t){return t?Math.pow(2,10*(t-1)):0}),Db("Circ",function(t){return-(J(1-t*t)-1)}),Db("Sine",function(t){return 1===t?1:1-Q(t*X)}),Db("Back",Gb("in"),Gb("out"),Gb()),Dt.SteppedEase=Dt.steps=ot.SteppedEase={config:function config(t,e){void 0===t&&(t=1);var r=1/t,i=t+(e?0:1),n=e?1:0;return function(t){return((i*yt(0,.99999999,t)|0)+n)*r}}},I.ease=Dt["quad.out"],_("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(t){return ct+=t+","+t+"Params,"});var Et,It=function GSCache(t,e){this.id=G++,(t._gsap=this).target=t,this.harness=e,this.get=e?e.get:$,this.set=e?e.getSetter:Qt},Lt=((Et=Animation.prototype).delay=function delay(t){return t||0===t?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+t-this._delay),this._delay=t,this):this._delay},Et.duration=function duration(t){return arguments.length?this.totalDuration(0<this._repeat?t+(t+this._rDelay)*this._repeat:t):this.totalDuration()&&this._dur},Et.totalDuration=function totalDuration(t){return arguments.length?(this._dirty=0,Fa(this,this._repeat<0?t:(t-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},Et.totalTime=function totalTime(t,e){if(Pt(),!arguments.length)return this._tTime;var r=this._dp;if(r&&r.smoothChildTiming&&this._ts){for(ya(this,t);r.parent;)r.parent._time!==r._start+(0<=r._ts?r._tTime/r._ts:(r.totalDuration()-r._tTime)/-r._ts)&&r.totalTime(r._tTime,!0),r=r.parent;!this.parent&&this._dp.autoRemoveChildren&&(0<this._ts&&t<this._tDur||this._ts<0&&0<t||!this._tDur&&!t)&&Aa(this._dp,this,this._start-this._delay)}return(this._tTime!==t||!this._dur&&!e||this._initted&&Math.abs(this._zTime)===U||!t&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=t),ea(this,t,e)),this},Et.time=function time(t,e){return arguments.length?this.totalTime(Math.min(this.totalDuration(),t+ua(this))%this._dur||(t?this._dur:0),e):this._time},Et.totalProgress=function totalProgress(t,e){return arguments.length?this.totalTime(this.totalDuration()*t,e):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.ratio},Et.progress=function progress(t,e){return arguments.length?this.totalTime(this.duration()*(!this._yoyo||1&this.iteration()?t:1-t)+ua(this),e):this.duration()?Math.min(1,this._time/this._dur):this.ratio},Et.iteration=function iteration(t,e){var r=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(t-1)*r,e):this._repeat?gt(this._tTime,r)+1:1},Et.timeScale=function timeScale(t){if(!arguments.length)return this._rts===-U?0:this._rts;if(this._rts===t)return this;var e=this.parent&&this._ts?wa(this.parent._time,this):this._tTime;return this._rts=+t||0,this._ts=this._ps||t===-U?0:this._rts,function _recacheAncestors(t){for(var e=t.parent;e&&e.parent;)e._dirty=1,e.totalDuration(),e=e.parent;return t}(this.totalTime(yt(-this._delay,this._tDur,e),!0))},Et.paused=function paused(t){return arguments.length?(this._ps!==t&&((this._ps=t)?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(Pt(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,1===this.progress()&&(this._tTime-=U)&&Math.abs(this._zTime)!==U))
2129),this):this._ps},Et.startTime=function startTime(t){if(arguments.length){this._start=t;var e=this.parent||this._dp;return!e||!e._sort&&this.parent||Aa(e,this,t-this._delay),this}return this._start},Et.endTime=function endTime(t){return this._start+(s(t)?this.totalDuration():this.duration())/Math.abs(this._ts)},Et.rawTime=function rawTime(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?wa(e.rawTime(t),this):this._tTime:this._tTime},Et.globalTime=function globalTime(t){for(var e=this,r=arguments.length?t:e.rawTime();e;)r=e._start+r/(e._ts||1),e=e._dp;return r},Et.repeat=function repeat(t){return arguments.length?(this._repeat=t,Ga(this)):this._repeat},Et.repeatDelay=function repeatDelay(t){return arguments.length?(this._rDelay=t,Ga(this)):this._rDelay},Et.yoyo=function yoyo(t){return arguments.length?(this._yoyo=t,this):this._yoyo},Et.seek=function seek(t,e){return this.totalTime(Ia(this,t),s(e))},Et.restart=function restart(t,e){return this.play().totalTime(t?-this._delay:0,s(e))},Et.play=function play(t,e){return null!=t&&this.seek(t,e),this.reversed(!1).paused(!1)},Et.reverse=function reverse(t,e){return null!=t&&this.seek(t||this.totalDuration(),e),this.reversed(!0).paused(!1)},Et.pause=function pause(t,e){return null!=t&&this.seek(t,e),this.paused(!0)},Et.resume=function resume(){return this.paused(!1)},Et.reversed=function reversed(t){return arguments.length?(!!t!==this.reversed()&&this.timeScale(-this._rts||(t?-U:0)),this):this._rts<0}
2129,Et.invalidate=function invalidate(){return this._initted=0,this._zTime=-U,this},Et.isActive=function isActive(){var t,e=this.parent||this._dp,r=this._start;return!(e&&!(this._ts&&this._initted&&e.isActive()&&(t=e.rawTime(!0))>=r&&t<this.endTime(!0)-U))},Et.eventCallback=function eventCallback(t,e,r){var i=this.vars;return 1<arguments.length?(e?(i[t]=e,r&&(i[t+"Params"]=r),"onUpdate"===t&&(this._onUpdate=e)):delete i[t],this):i[t]},Et.then=function then(t){var i=this;return new Promise(function(e){function jn(){var t=i.then;i.then=null,o(r)&&(r=r(i))&&(r.then||r===i)&&(i.then=t),e(r),i.then=t}var r=o(t)?t:ga;i._initted&&1===i.totalProgress()&&0<=i._ts||!i._tTime&&i._ts<0?jn():i._prom=jn})},Et.kill=function kill(){fb(this)},Animation);function Animation(t,e){var r=t.parent||E;this.vars=t,this._delay=+t.delay||0,(this._repeat=t.repeat||0)&&(this._rDelay=t.repeatDelay||0,this._yoyo=!!t.yoyo||!!t.yoyoEase),this._ts=1,Fa(this,+t.duration,1,1),this.data=t.data,m||At.wake(),r&&Aa(r,this,e||0===e?e:r._time,1),t.reversed&&this.reverse(),t.paused&&this.paused(!0)}ha(Lt.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:-U,_prom:0,_ps:!1,_rts:1});var Bt=function(i){function Timeline(t,e){var r;return void 0===t&&(t={}),(r=i.call(this,t,e)||this).labels={},r.smoothChildTiming=!!t.smoothChildTiming,r.autoRemoveChildren=!!t.autoRemoveChildren,r._sort=s(t.sortChildren),r.parent&&za(r.parent,_assertThisInitialized(r)),t.scrollTrigger&&Ba(_assertThisInitialized(r),t.scrollTrigger),r}_inheritsLoose(Timeline,i);var t=Timeline.prototype;return t.to=function to(t,e,r,i){return new Xt(t,ca(arguments,0,this),Ia(this,p(e)?i:r)),this},t.from=function from(t,e,r,i){return new Xt(t,ca(arguments,1,this),Ia(this,p(e)?i:r)),this},t.fromTo=function fromTo(t,e,r,i,n){return new Xt(t,ca(arguments,2,this),Ia(this,p(e)?n:i)),this},t.set=function set(t,e,r){return e.duration=0,e.parent=this,ma(e).repeatDelay||(e.repeat=0),e.immediateRender=!!e.immediateRender,new Xt(t,e,Ia(this,r),1),this},t.call=function call(t,e,r){return Aa(this,Xt.delayedCall(0,t,e),Ia(this,r))},t.staggerTo=function staggerTo(t,e,r,i,n,a,s){return r.duration=e,r.stagger=r.stagger||i,r.onComplete=a,r.onCompleteParams=s,r.parent=this,new Xt(t,r,Ia(this,n)),this},t.staggerFrom=function staggerFrom(t,e,r,i,n,a,o){return r.runBackwards=1,ma(r).immediateRender=s(r.immediateRender),this.staggerTo(t,e,r,i,n,a,o)},t.staggerFromTo=function staggerFromTo(t,e,r,i,n,a,o,u){return i.startAt=r,ma(i).immediateRender=s(i.immediateRender),this.staggerTo(t,e,i,n,a,o,u)},t.render=function render(t,e,r){var i,n,a,s,o,u,h,l,f,d,p,_,c=this._time,m=this._dirty?this.totalDuration():this._tDur,g=this._dur,v=this!==E&&m-U<t&&0<=t?m:t<U?0:t,y=this._zTime<0!=t<0&&(this._initted||!g);if(v!==this._tTime||r||y){if(c!==this._time&&g&&(v+=this._time-c,t+=this._time-c),i=v,f=this._start,u=!(l=this._ts),y&&(g||(c=this._zTime),!t&&e||(this._zTime=t)),this._repeat&&(p=this._yoyo,o=g+this._rDelay,i=aa(v%o),v===m?(s=this._repeat,i=g):((s=~~(v/o))&&s===v/o&&(i=g,s--),g<i&&(i=g)),d=gt(this._tTime,o),!c&&this._tTime&&d!==s&&(d=s),p&&1&s&&(i=g-i,_=1),s!==d&&!this._lock)){var T=p&&1&d,b=T===(p&&1&s);if(s<d&&(T=!T),c=T?0:g,this._lock=1,this.render(c||(_?0:aa(s*o)),e,!g)._lock=0,!e&&this.parent&&xt(this,"onRepeat"),this.vars.repeatRefresh&&!_&&(this.invalidate()._lock=1),c!==this._time||u!=!this._ts)return this;if(g=this._dur,m=this._tDur,b&&(this._lock=2,c=T?g:-1e-4,this.render(c,!0),this.vars.repeatRefresh&&!_&&this.invalidate()),this._lock=0,!this._ts&&!u)return this;Bb(this,_)}if(this._hasPause&&!this._forcing&&this._lock<2&&(h=function _findNextPauseTween(t,e,r){var i;if(e<r)for(i=t._first;i&&i._start<=r;){if(!i._dur&&"isPause"===i.data&&i._start>e)return i;i=i._next}else for(i=t._last;i&&i._start>=r;){if(!i._dur&&"isPause"===i.data&&i._start<e)return i;i=i._prev}}(this,aa(c),aa(i)))&&(v-=i-(i=h._start)),this._tTime=v,this._time=i,this._act=!l,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=t),c||!i||e||xt(this,"onStart"),c<=i&&0<=t)for(n=this._first;n;){if(a=n._next,(n._act||i>=n._start)&&n._ts&&h!==n){if(n.parent!==this)return this.render(t,e,r);
vendor: 3,892 bytes, line 2129
2129if(n.render(0<n._ts?(i-n._start)*n._ts:(n._dirty?n.totalDuration():n._tDur)+(i-n._start)*n._ts,e,r),i!==this._time||!this._ts&&!u){h=0,a&&(v+=this._zTime=-U);break}}n=a}else{n=this._last;for(var w=t<0?t:i;n;){if(a=n._prev,(n._act||w<=n._end)&&n._ts&&h!==n){if(n.parent!==this)return this.render(t,e,r);if(n.render(0<n._ts?(w-n._start)*n._ts:(n._dirty?n.totalDuration():n._tDur)+(w-n._start)*n._ts,e,r),i!==this._time||!this._ts&&!u){h=0,a&&(v+=this._zTime=w?-U:U);break}}n=a}}if(h&&!e&&(this.pause(),h.render(c<=i?0:-U)._zTime=c<=i?1:-1,this._ts))return this._start=f,xa(this),this.render(t,e,r);this._onUpdate&&!e&&xt(this,"onUpdate",!0),(v===m&&m>=this.totalDuration()||!v&&c)&&(f!==this._start&&Math.abs(l)===Math.abs(this._ts)||this._lock||(!t&&g||!(v===m&&0<this._ts||!v&&this._ts<0)||qa(this,1),e||t<0&&!c||!v&&!c||(xt(this,v===m?"onComplete":"onReverseComplete",!0),!this._prom||v<m&&0<this.timeScale()||this._prom())))}return this},t.add=function add(t,e){var r=this;if(p(e)||(e=Ia(this,e)),!(t instanceof Lt)){if(tt(t))return t.forEach(function(t){return r.add(t,e)}),this;if(n(t))return this.addLabel(t,e);if(!o(t))return this;t=Xt.delayedCall(0,t)}return this!==t?Aa(this,t,e):this},t.getChildren=function getChildren(t,e,r,i){void 0===t&&(t=!0),void 0===e&&(e=!0),void 0===r&&(r=!0),void 0===i&&(i=-B);for(var n=[],a=this._first;a;)a._start>=i&&(a instanceof Xt?e&&n.push(a):(r&&n.push(a),t&&n.push.apply(n,a.getChildren(!0,e,r)))),a=a._next;return n},t.getById=function getById(t){for(var e=this.getChildren(1,1,1),r=e.length;r--;)if(e[r].vars.id===t)return e[r]},t.remove=function remove(t){return n(t)?this.removeLabel(t):o(t)?this.killTweensOf(t):(pa(this,t),t===this._recent&&(this._recent=this._last),ra(this))},t.totalTime=function totalTime(t,e){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=aa(At.time-(0<this._ts?t/this._ts:(this.totalDuration()-t)/-this._ts))),i.prototype.totalTime.call(this,t,e),this._forcing=0,this):this._tTime},t.addLabel=function addLabel(t,e){return this.labels[t]=Ia(this,e),this},t.removeLabel=function removeLabel(t){return delete this.labels[t],this},t.addPause=function addPause(t,e,r){var i=Xt.delayedCall(0,e||O,r);return i.data="isPause",this._hasPause=1,Aa(this,i,Ia(this,t))},t.removePause=function removePause(t){var e=this._first;for(t=Ia(this,t);e;)e._start===t&&"isPause"===e.data&&qa(e),e=e._next},t.killTweensOf=function killTweensOf(t,e,r){for(var i=this.getTweensOf(t,r),n=i.length;n--;)qt!==i[n]&&i[n].kill(t,e);return this},t.getTweensOf=function getTweensOf(t,e){for(var r,i=[],n=bt(t),a=this._first,s=p(e);a;)a instanceof Xt?ba(a._targets,n)&&(s?(!qt||a._initted&&a._ts)&&a.globalTime(0)<=e&&a.globalTime(a.totalDuration())>e:!e||a.isActive())&&i.push(a):(r=a.getTweensOf(n,e)).length&&i.push.apply(i,r),a=a._next;return i},t.tweenTo=function tweenTo(t,e){e=e||{};var r=this,i=Ia(r,t),n=e.startAt,a=e.onStart,s=e.onStartParams,o=Xt.to(r,ha(e,{ease:"none",lazy:!1,time:i,overwrite:"auto",duration:e.duration||Math.abs((i-(n&&"time"in n?n.time:r._time))/r.timeScale())||U,onStart:function onStart(){r.pause();var t=e.duration||Math.abs((i-r._time)/r.timeScale());o._dur!==t&&Fa(o,t,0,1).render(o._time,!0,!0),a&&a.apply(o,s||[])}}));return o},t.tweenFromTo=function tweenFromTo(t,e,r){return this.tweenTo(e,ha({startAt:{time:Ia(this,t)}},r))},t.recent=function recent(){return this._recent},t.nextLabel=function nextLabel(t){return void 0===t&&(t=this._time),db(this,Ia(this,t))},t.previousLabel=function previousLabel(t){return void 0===t&&(t=this._time),db(this,Ia(this,t),1)},t.currentLabel=function currentLabel(t){return arguments.length?this.seek(t,!0):this.previousLabel(this._time+U)},t.shiftChildren=function shiftChildren(t,e,r){void 0===r&&(r=0);for(var i,n=this._first,a=this.labels;n;)n._start>=r&&(n._start+=t,n._end+=t),n=n._next;if(e)for(i in a)a[i]>=r&&(a[i]+=t);return ra(this)}
2129,t.invalidate=function invalidate(){var t=this._first;for(this._lock=0;t;)t.invalidate(),t=t._next;return i.prototype.invalidate.call(this)},t.clear=function clear(t){void 0===t&&(t=!0);for(var e,r=this._first;r;)e=r._next,this.remove(r),r=e;return this._time=this._tTime=this._pTime=0,t&&(this.labels={}),ra(this)},t.totalDuration=function totalDuration(t){var e,r,i,n=0,a=this,s=a._last,o=B;if(arguments.length)return a.timeScale((a._repeat<0?a.duration():a.totalDuration())/(a.reversed()?-t:t));if(a._dirty){for(i=a.parent;s;)e=s._prev,s._dirty&&s.totalDuration(),o<(r=s._start)&&a._sort&&s._ts&&!a._lock?(a._lock=1,Aa(a,s,r-s._delay,1)._lock=0):o=r,r<0&&s._ts&&(n-=r,(!i&&!a._dp||i&&i.smoothChildTiming)&&(a._start+=r/a._ts,a._time-=r,a._tTime-=r),a.shiftChildren(-r,!1,-Infinity),o=0),s._end>n&&s._ts&&(n=s._end),s=e;Fa(a,a===E&&a._time>n?a._time:n,1,1),a._dirty=0}return a._tDur},Timeline.updateRoot=function updateRoot(t){if(E._ts&&(ea(E,wa(t,E)),d=At.frame),At.frame>=pt){pt+=j.autoSleep||120;var e=E._first;if((!e||!e._ts)&&j.autoSleep&&At._listeners.length<2){for(;e&&!e._ts;)e=e._next;e||At.sleep()}}},Timeline}(Lt);ha(Bt.prototype,{_lock:0,_hasPause:0,_forcing:0});function Nb(t,e,i,a,s,u){var h,l,f,d;if(ft[t]&&!1!==(h=new ft[t]).init(s,h.rawVars?e[t]:function _processVars(t,e,i,a,s){if(o(t)&&(t=jt(t,s,e,i,a)),!r(t)||t.style&&t.nodeType||tt(t)||H(t))return n(t)?jt(t,s,e,i,a):t;var u,h={};for(u in t)h[u]=jt(t[u],s,e,i,a);return h}(e[t],a,s,u,i),i,a,u)&&(i._pt=l=new ie(i._pt,s,t,0,1,h.render,h,0,h.priority),i!==c))for(f=i._ptLookup[i._targets.indexOf(s)],d=h._props.length;d--;)f[h._props[d]]=l;return h}var qt,Yt=function _addPropTween(t,e,r,i,a,s,u,h,l){o(i)&&(i=i(a||0,t,s));var f,d=t[e],p="get"!==r?r:o(d)?l?t[e.indexOf("set")||!o(t["get"+e.substr(3)])?e:"get"+e.substr(3)](l):t[e]():d,_=o(d)?l?Jt:Zt:Gt;if(n(i)&&(~i.indexOf("random(")&&(i=ab(i)),"="===i.charAt(1)&&(i=parseFloat(p)+parseFloat(i.substr(2))*("-"===i.charAt(0)?-1:1)+(La(p)||0))),p!==i)return isNaN(p*i)?(d||e in t||L(e,i),function _addComplexStringPropTween(t,e,r,i,n,a,s){var o,u,h,l,f,d,p,_,c=new ie(this._pt,t,e,0,1,Ht,null,n),m=0,g=0;for(c.b=r,c.e=i,r+="",(p=~(i+="").indexOf("random("))&&(i=ab(i)),a&&(a(_=[r,i],t,e),r=_[0],i=_[1]),u=r.match(nt)||[];o=nt.exec(i);)l=o[0],f=i.substring(m,o.index),h?h=(h+1)%5:"rgba("===f.substr(-5)&&(h=1),l!==u[g++]&&(d=parseFloat(u[g-1])||0,c._pt={_next:c._pt,p:f||1===g?f:",",s:d,c:"="===l.charAt(1)?parseFloat(l.substr(2))*("-"===l.charAt(0)?-1:1):parseFloat(l)-d,m:h&&h<4?Math.round:0},m=nt.lastIndex);return c.c=m<i.length?i.substring(m,i.length):"",c.fp=s,(at.test(i)||p)&&(c.e=0),this._pt=c}.call(this,t,e,p,i,_,h||j.stringFilter,l)):(f=new ie(this._pt,t,e,+p||0,i-(p||0),"boolean"==typeof d?$t:Wt,0,_),l&&(f.fp=l),u&&f.modifier(u,this,t),this._pt=f)},Nt=function _initTween(t,e){var r,i,n,a,o,u,h,l,f,d,p,_,c,m=t.vars,g=m.ease,v=m.startAt,y=m.immediateRender,T=m.lazy,b=m.onUpdate,w=m.onUpdateParams,x=m.callbackScope,k=m.runBackwards,O=m.yoyoEase,M=m.keyframes,C=m.autoRevert,A=t._dur,P=t._startAt,D=t._targets,S=t.parent,z=S&&"nested"===S.data?S.parent._targets:D,F="auto"===t._overwrite,R=t.timeline;if(!R||M&&g||(g="none"),t._ease=Rt(g,I.ease),t._yEase=O?Ft(Rt(!0===O?g:O,I.ease)):0,O&&t._yoyo&&!t._repeat&&(O=t._yEase,t._yEase=t._ease,t._ease=O),!R){if(_=(l=D[0]?Z(D[0]).harness:0)&&m[l.prop],r=la(m,ut),P&&P.render(-1,!0).kill(),v){if(qa(t._startAt=Xt.set(D,ha({data:"isStart",overwrite:!1,parent:S,immediateRender:!0,lazy:s(T),startAt:null,delay:0,onUpdate:b,onUpdateParams:w,callbackScope:x,stagger:0},v))),y)if(0<e)C||(t._startAt=0);else if(A&&!(e<0&&P))return void(e&&(t._zTime=e))}else if(k&&A)if(P)C||(t._startAt=0);else if(e&&(y=!1),n=ha({overwrite:!1,data:"isFromStart",lazy:y&&s(T),immediateRender:y,stagger:0,parent:S},r),_&&(n[l.prop]=_),qa(t._startAt=Xt.set(D,n)),y){if(!e)return}else _initTween(t._startAt,U);for(t._pt=0,T=A&&s(T)||T&&!A,i=0;i<D.length;i++){if(h=(o=D[i])._gsap||Y(D)[i]._gsap,t._ptLookup[i]=d={},lt[h.id]&&ht.length&&da(),p=z===D?i:z.indexOf(o),l&&!1!==(f=new l).init(o,_||r,t,p,z)&&(t._pt=a=new ie(t._pt,o,f.name,0,1,f.render,f,0,f.priority),f._props.forEach(function(t){d[t]=a}),f.priority&&(u=1)),!l||_)for(n in r)ft[n]&&(f=Nb(n,r,t,p,o,z))?f.priority&&(u=1):d[n]=a=Yt.call(t,o,n,"get",r[n],p,z,0,m.stringFilter);t._op&&t._op[i]&&t.kill(o,t._op[i]),F&&t._pt&&(qt=t,E.killTweensOf(o,d,t.globalTime(0)),c=!t.parent,qt=0),t._pt&&T&&(lt[h.id]=1)}u&&re(t),t._onInit&&t._onInit(t)}t._from=!R&&!!m.runBackwards,t._onUpdate=b,t._initted=(!t._op||t._pt)&&!c},jt=function _parseFuncOrString(t,e,r,i,a){return o(t)?t.call(e,r,i,a):n(t)&&~t.indexOf("random(")?ab(t):t},Ut=ct+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase",Vt=(Ut+",id,stagger,delay,duration,paused,scrollTrigger").split(","),Xt=function(S){function Tween(t,e,i,n){var a;"number"==typeof e&&(i.duration=e,e=i,i=null);var o,h,l,f,d,_,c,m,g=(a=S.call(this,n?e:ma(e),i)||this).vars,v=g.duration,y=g.delay,T=g.immediateRender,b=g.stagger,w=g.overwrite,x=g.keyframes,k=g.defaults,C=g.scrollTrigger,A=g.yoyoEase,P=a.parent,D=(tt(t)||H(t)?p(t[0]):"length"in e)?[t]:bt(t);
2129if(a._targets=D.length?Y(D):M("GSAP target "+t+" not found. https://greensock.com",!j.nullTargetWarn)||[],a._ptLookup=[],a._overwrite=w,x||b||u(v)||u(y)){if(e=a.vars,(o=a.timeline=new Bt({data:"nested",defaults:k||{}})).kill(),o.parent=_assertThisInitialized(a),x)ha(o.vars.defaults,{ease:"none"}),x.forEach(function(t){return o.to(D,t,">")});else{if(f=D.length,c=b?Sa(b):O,r(b))for(d in b)~Ut.indexOf(d)&&((m=m||{})[d]=b[d]);for(h=0;h<f;h++){for(d in l={},e)Vt.indexOf(d)<0&&(l[d]=e[d]);l.stagger=0,A&&(l.yoyoEase=A),m&&mt(l,m),_=D[h],l.duration=+jt(v,_assertThisInitialized(a),h,_,D),l.delay=(+jt(y,_assertThisInitialized(a),h,_,D)||0)-a._delay,!b&&1===f&&l.delay&&(a._delay=y=l.delay,a._start+=y,l.delay=0),o.to(_,l,c(h,_,D))}o.duration()?v=y=0:a.timeline=0}v||a.duration(v=o.duration())}else a.timeline=0;return!0===w&&(qt=_assertThisInitialized(a),E.killTweensOf(D),qt=0),P&&za(P,_assertThisInitialized(a)),(T||!v&&!x&&a._start===aa(P._time)&&s(T)&&function _hasNoPausedAncestors(t){return!t||t._ts&&_hasNoPausedAncestors(t.parent)}(_assertThisInitialized(a))&&"nested"!==P.data)&&(a._tTime=-U,a.render(Math.max(0,-y))),C&&Ba(_assertThisInitialized(a),C),a}_inheritsLoose(Tween,S);var t=Tween.prototype;return t.render=function render(t,e,r){var i,n,a,s,o,u,h,l,f,d=this._time,p=this._tDur,_=this._dur,c=p-U<t&&0<=t?p:t<U?0:t;if(_){if(c!==this._tTime||!t||r||this._startAt&&this._zTime<0!=t<0){if(i=c,l=this.timeline,this._repeat){if(s=_+this._rDelay,i=aa(c%s),c===p?(a=this._repeat,i=_):((a=~~(c/s))&&a===c/s&&(i=_,a--),_<i&&(i=_)),(u=this._yoyo&&1&a)&&(f=this._yEase,i=_-i),o=gt(this._tTime,s),i===d&&!r&&this._initted)return this;a!==o&&(l&&this._yEase&&Bb(l,u),!this.vars.repeatRefresh||u||this._lock||(this._lock=r=1,this.render(aa(s*a),!0).invalidate()._lock=0))}if(!this._initted){if(Ca(this,t<0?t:i,r,e))return this._tTime=0,this;if(_!==this._dur)return this.render(t,e,r)}for(this._tTime=c,this._time=i,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=h=(f||this._ease)(i/_),this._from&&(this.ratio=h=1-h),!i||d||e||xt(this,"onStart"),n=this._pt;n;)n.r(h,n.d),n=n._next;l&&l.render(t<0?t:!i&&u?-U:l._dur*h,e,r)||this._startAt&&(this._zTime=t),this._onUpdate&&!e&&(t<0&&this._startAt&&this._startAt.render(t,!0,r),xt(this,"onUpdate")),this._repeat&&a!==o&&this.vars.onRepeat&&!e&&this.parent&&xt(this,"onRepeat"),c!==this._tDur&&c||this._tTime!==c||(t<0&&this._startAt&&!this._onUpdate&&this._startAt.render(t,!0,!0),!t&&_||!(c===this._tDur&&0<this._ts||!c&&this._ts<0)||qa(this,1),e||t<0&&!d||!c&&!d||(xt(this,c===p?"onComplete":"onReverseComplete",!0),!this._prom||c<p&&0<this.timeScale()||this._prom()))}}else!function _renderZeroDurationTween(t,e,r,i){var n,a,s=t.ratio,o=e<0||!e&&s&&!t._start&&t._zTime>U&&!t._dp._lock||(t._ts<0||t._dp._ts<0)&&"isFromStart"!==t.data&&"isStart"!==t.data?0:1,u=t._rDelay,h=0;if(u&&t._repeat&&(h=yt(0,t._tDur,e),gt(h,u)!==(a=gt(t._tTime,u))&&(s=1-o,t.vars.repeatRefresh&&t._initted&&t.invalidate())),o!==s||i||t._zTime===U||!e&&t._zTime){if(!t._initted&&Ca(t,e,i,r))return;for(a=t._zTime,t._zTime=e||(r?U:0),r=r||e&&!a,t.ratio=o,t._from&&(o=1-o),t._time=0,t._tTime=h,r||xt(t,"onStart"),n=t._pt;n;)n.r(o,n.d),n=n._next;t._startAt&&e<0&&t._startAt.render(e,!0,!0),t._onUpdate&&!r&&xt(t,"onUpdate"),h&&t._repeat&&!r&&t.parent&&xt(t,"onRepeat"),(e>=t._tDur||e<0)&&t.ratio===o&&(o&&qa(t,1),r||(xt(t,o?"onComplete":"onReverseComplete",!0),t._prom&&t._prom()))}else t._zTime||(t._zTime=e)}(this,t,e,r);return this},t.targets=function targets(){return this._targets}
vendor: 9,835 bytes, line 2129
2129,t.invalidate=function invalidate(){return this._pt=this._op=this._startAt=this._onUpdate=this._act=this._lazy=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(),S.prototype.invalidate.call(this)},t.kill=function kill(t,e){if(void 0===e&&(e="all"),!(t||e&&"all"!==e)&&(this._lazy=0,this.parent))return fb(this);if(this.timeline){var r=this.timeline.totalDuration();return this.timeline.killTweensOf(t,e,qt&&!0!==qt.vars.overwrite)._first||fb(this),this.parent&&r!==this.timeline.totalDuration()&&Fa(this,this._dur*this.timeline._tDur/r,0,1),this}var i,a,s,o,u,h,l,f=this._targets,d=t?bt(t):f,p=this._ptLookup,c=this._pt;if((!e||"all"===e)&&function _arraysMatch(t,e){for(var r=t.length,i=r===e.length;i&&r--&&t[r]===e[r];);return r<0}(f,d))return"all"===e&&(this._pt=0),fb(this);for(i=this._op=this._op||[],"all"!==e&&(n(e)&&(u={},_(e,function(t){return u[t]=1}),e=u),e=function _addAliasesToVars(t,e){var r,i,n,a,s=t[0]?Z(t[0]).harness:0,o=s&&s.aliases;if(!o)return e;for(i in r=mt({},e),o)if(i in r)for(n=(a=o[i].split(",")).length;n--;)r[a[n]]=r[i];return r}(f,e)),l=f.length;l--;)if(~d.indexOf(f[l]))for(u in a=p[l],"all"===e?(i[l]=e,o=a,s={}):(s=i[l]=i[l]||{},o=e),o)(h=a&&a[u])&&("kill"in h.d&&!0!==h.d.kill(u)||pa(this,h,"_pt"),delete a[u]),"all"!==s&&(s[u]=1);return this._initted&&!this._pt&&c&&fb(this),this},Tween.to=function to(t,e,r){return new Tween(t,e,r)},Tween.from=function from(t,e){return new Tween(t,ca(arguments,1))},Tween.delayedCall=function delayedCall(t,e,r,i){return new Tween(e,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:t,onComplete:e,onReverseComplete:e,onCompleteParams:r,onReverseCompleteParams:r,callbackScope:i})},Tween.fromTo=function fromTo(t,e,r){return new Tween(t,ca(arguments,2))},Tween.set=function set(t,e){return e.duration=0,e.repeatDelay||(e.repeat=0),new Tween(t,e)},Tween.killTweensOf=function killTweensOf(t,e,r){return E.killTweensOf(t,e,r)},Tween}(Lt);ha(Xt.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0}),_("staggerTo,staggerFrom,staggerFromTo",function(r){Xt[r]=function(){var t=new Bt,e=Tt.call(arguments,0);return e.splice("staggerFromTo"===r?5:4,0,0),t[r].apply(t,e)}});function Yb(t,e,r){return t.setAttribute(e,r)}function ec(t,e,r,i){i.mSet(t,e,i.m.call(i.tween,r,i.mt),i)}var Gt=function _setterPlain(t,e,r){return t[e]=r},Zt=function _setterFunc(t,e,r){return t[e](r)},Jt=function _setterFuncWithParam(t,e,r,i){return t[e](i.fp,r)},Qt=function _getSetter(t,e){return o(t[e])?Zt:q(t[e])&&t.setAttribute?Yb:Gt},Wt=function _renderPlain(t,e){return e.set(e.t,e.p,Math.round(1e4*(e.s+e.c*t))/1e4,e)},$t=function _renderBoolean(t,e){return e.set(e.t,e.p,!!(e.s+e.c*t),e)},Ht=function _renderComplexString(t,e){var r=e._pt,i="";if(!t&&e.b)i=e.b;else if(1===t&&e.e)i=e.e;else{for(;r;)i=r.p+(r.m?r.m(r.s+r.c*t):Math.round(1e4*(r.s+r.c*t))/1e4)+i,r=r._next;i+=e.c}e.set(e.t,e.p,i,e)},Kt=function _renderPropTweens(t,e){for(var r=e._pt;r;)r.r(t,r.d),r=r._next},te=function _addPluginModifier(t,e,r,i){for(var n,a=this._pt;a;)n=a._next,a.p===i&&a.modifier(t,e,r),a=n},ee=function _killPropTweensOf(t){for(var e,r,i=this._pt;i;)r=i._next,i.p===t&&!i.op||i.op===t?pa(this,i,"_pt"):i.dep||(e=1),i=r;return!e},re=function _sortPropTweensByPriority(t){for(var e,r,i,n,a=t._pt;a;){for(e=a._next,r=i;r&&r.pr>a.pr;)r=r._next;(a._prev=r?r._prev:n)?a._prev._next=a:i=a,(a._next=r)?r._prev=a:n=a,a=e}t._pt=i},ie=(PropTween.prototype.modifier=function modifier(t,e,r){this.mSet=this.mSet||this.set,this.set=ec,this.m=t,this.mt=r,this.tween=e},PropTween);function PropTween(t,e,r,i,n,a,s,o,u){this.t=e,this.s=i,this.c=n,this.p=r,this.r=a||Wt,this.d=s||this,this.set=o||Gt,this.pr=u||0,(this._next=t)&&(t._prev=this)}_(ct+"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 ut[t]=1}),ot.TweenMax=ot.TweenLite=Xt,ot.TimelineLite=ot.TimelineMax=Bt,E=new Bt({sortChildren:!1,defaults:I,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0}),j.stringFilter=qb;var ne={registerPlugin:function registerPlugin(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];e.forEach(function(t){return function _createPlugin(t){var e=(t=!t.name&&t.default||t).name,r=o(t),i=e&&!r&&t.init?function(){this._props=[]}:t,n={init:O,render:Kt,add:Yt,kill:ee,modifier:te,rawVars:0},a={targetTest:0,get:0,getSetter:Qt,aliases:{},register:0};if(Pt(),t!==i){if(ft[e])return;ha(i,ha(la(t,n),a)),mt(i.prototype,mt(n,la(t,a))),ft[i.prop=e]=i,t.targetTest&&(_t.push(i),ut[e]=1),e=("css"===e?"CSS":e.charAt(0).toUpperCase()+e.substr(1))+"Plugin"}N(e,i),t.register&&t.register(ae,i,ie)}(t)})},timeline:function timeline(t){return new Bt(t)},getTweensOf:function getTweensOf(t,e){return E.getTweensOf(t,e)},getProperty:function getProperty(i,t,e,r){n(i)&&(i=bt(i)[0]);var a=Z(i||{}).get,s=e?ga:fa;return"native"===e&&(e=""),i?t?s((ft[t]&&ft[t].get||a)(i,t,e,r)):function(t,e,r){return s((ft[t]&&ft[t].get||a)(i,t,e,r))}:i},quickSetter:function quickSetter(r,e,i){if(1<(r=bt(r)).length){var n=r.map(function(t){return ae.quickSetter(t,e,i)}),a=n.length;return function(t){for(var e=a;e--;)n[e](t)}}r=r[0]||{};var s=ft[e],o=Z(r),u=o.harness&&(o.harness.aliases||{})[e]||e,h=s?function(t){var e=new s;c._pt=0,e.init(r,i?t+i:t,c,0,[r]),e.render(1,e),c._pt&&Kt(1,c)}:o.set(r,u);return s?h:function(t){return h(r,u,i?t+i:t,o,1)}},isTweening:function isTweening(t){return 0<E.getTweensOf(t,!0).length},defaults:function defaults(t){return t&&t.ease&&(t.ease=Rt(t.ease,I.ease)),ka(I,t||{})},config:function config(t){return ka(j,t||{})},registerEffect:function registerEffect(t){var n=t.name,i=t.effect,e=t.plugins,a=t.defaults,s=t.extendTimeline;(e||"").split(",").forEach(function(t){return t&&!ft[t]&&!ot[t]&&M(n+" effect requires "+t+" plugin.")}),dt[n]=function(t,e,r){return i(bt(t),ha(e||{},a),r)},s&&(Bt.prototype[n]=function(t,e,i){return this.add(dt[n](t,r(e)?e:(i=e)&&{},this),i)})},registerEase:function registerEase(t,e){Dt[t]=Rt(e)},parseEase:function parseEase(t,e){return arguments.length?Rt(t,e):Dt},getById:function getById(t){return E.getById(t)},exportRoot:function exportRoot(t,e){void 0===t&&(t={});var r,i,n=new Bt(t);for(n.smoothChildTiming=s(t.smoothChildTiming),E.remove(n),n._dp=0,n._time=n._tTime=E._time,r=E._first;r;)i=r._next,!e&&!r._dur&&r instanceof Xt&&r.vars.onComplete===r._targets[0]||Aa(n,r,r._start-r._delay),r=i;return Aa(E,n,0),n},utils:{wrap:function wrap(e,t,r){var i=t-e;return tt(e)?Za(e,wrap(0,e.length),t):Ja(r,function(t){return(i+(t-e)%i)%i+e})},wrapYoyo:function wrapYoyo(e,t,r){var i=t-e,n=2*i;return tt(e)?Za(e,wrapYoyo(0,e.length-1),t):Ja(r,function(t){return e+(i<(t=(n+(t-e)%n)%n||0)?n-t:t)})},distribute:Sa,random:Va,snap:Ua,normalize:function normalize(t,e,r){return wt(t,e,0,1,r)},getUnit:La,clamp:function clamp(e,r,t){return Ja(t,function(t){return yt(e,r,t)})},splitColor:lb,toArray:bt,mapRange:wt,pipe:function pipe(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(t){return e.reduce(function(t,e){return e(t)},t)}},unitize:function unitize(e,r){return function(t){return e(parseFloat(t))+(r||La(t))}},interpolate:function interpolate(e,r,t,i){var a=isNaN(e+r)?0:function(t){return(1-t)*e+t*r};if(!a){var s,o,u,h,l,f=n(e),d={};if(!0===t&&(i=1)&&(t=null),f)e={p:e},r={p:r};else if(tt(e)&&!tt(r)){for(u=[],h=e.length,l=h-2,o=1;o<h;o++)u.push(interpolate(e[o-1],e[o]));h--,a=function func(t){t*=h;var e=Math.min(l,~~t);return u[e](t-e)},t=r}else i||(e=mt(tt(e)?[]:{},e));if(!u){for(s in r)Yt.call(d,e,s,"get",r[s]);a=function func(t){return Kt(t,d)||(f?e.p:e)}}}return Ja(t,a)},shuffle:Ra},install:K,effects:dt,ticker:At,updateRoot:Bt.updateRoot,plugins:ft,globalTimeline:E,core:{PropTween:ie,globals:N,Tween:Xt,Timeline:Bt,Animation:Lt,getCache:Z,_removeLinkedListItem:pa}};_("to,from,fromTo,delayedCall,set,killTweensOf",function(t){return ne[t]=Xt[t]}),At.add(Bt.updateRoot),c=ne.to({},{duration:0});function ic(t,e){for(var r=t._pt;r&&r.p!==e&&r.op!==e&&r.fp!==e;)r=r._next;return r}function kc(t,a){return{name:t,rawVars:1,init:function init(t,i,e){e._onInit=function(t){var e,r;if(n(i)&&(e={},_(i,function(t){return e[t]=1}),i=e),a){for(r in e={},i)e[r]=a(i[r]);i=e}!function _addModifiers(t,e){var r,i,n,a=t._targets;for(r in e)for(i=a.length;i--;)(n=(n=t._ptLookup[i][r])&&n.d)&&(n._pt&&(n=ic(n,r)),n&&n.modifier&&n.modifier(e[r],t,a[i],r))}(t,i)}}}}var ae=ne.registerPlugin({name:"attr",init:function init(t,e,r,i,n){var a,s;for(a in e)(s=this.add(t,"setAttribute",(t.getAttribute(a)||0)+"",e[a],i,n,0,0,a))&&(s.op=a),this._props.push(a)}},{name:"endArray",init:function init(t,e){for(var r=e.length;r--;)this.add(t,r,t[r]||0,e[r])}},kc("roundProps",Ta),kc("modifiers"),kc("snap",Ua))||ne;Xt.version=Bt.version=ae.version="3.5.1",f=1,t()&&Pt();function Vc(t,e){return e.set(e.t,e.p,Math.round(1e4*(e.s+e.c*t))/1e4+e.u,e)}function Wc(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)}function Xc(t,e){return e.set(e.t,e.p,t?Math.round(1e4*(e.s+e.c*t))/1e4+e.u:e.b,e)}function Yc(t,e){var r=e.s+e.c*t;e.set(e.t,e.p,~~(r+(r<0?-.5:.5))+e.u,e)}function Zc(t,e){return e.set(e.t,e.p,t?e.e:e.b,e)}function $c(t,e){return e.set(e.t,e.p,1!==t?e.b:e.e,e)}function _c(t,e,r){return t.style[e]=r}function ad(t,e,r){return t.style.setProperty(e,r)}function bd(t,e,r){return t._gsap[e]=r}function cd(t,e,r){return t._gsap.scaleX=t._gsap.scaleY=r}function dd(t,e,r,i,n){var a=t._gsap;a.scaleX=a.scaleY=r,a.renderTransform(n,a)}function ed(t,e,r,i,n){var a=t._gsap;a[e]=r,a.renderTransform(n,a)}function id(t,e){var r=oe.createElementNS?oe.createElementNS((e||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),t):oe.createElement(t);return r.style?r:oe.createElement(t)}
2129function jd(t,e,r){var i=getComputedStyle(t);return i[e]||i.getPropertyValue(e.replace(Ie,"-$1").toLowerCase())||i.getPropertyValue(e)||!r&&jd(t,Ue(e)||e,1)||""}function md(){(function _windowExists(){return"undefined"!=typeof window})()&&window.document&&(se=window,oe=se.document,ue=oe.documentElement,le=id("div")||{style:{}},fe=id("div"),Ye=Ue(Ye),Ne=Ye+"Origin",le.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",pe=!!Ue("perspective"),he=1)}function nd(t){var e,r=id("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),i=this.parentNode,n=this.nextSibling,a=this.style.cssText;if(ue.appendChild(r),r.appendChild(this),this.style.display="block",t)try{e=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=nd}catch(t){}else this._gsapBBox&&(e=this._gsapBBox());return i&&(n?i.insertBefore(this,n):i.appendChild(this)),ue.removeChild(r),this.style.cssText=a,e}function od(t,e){for(var r=e.length;r--;)if(t.hasAttribute(e[r]))return t.getAttribute(e[r])}function pd(e){var r;try{r=e.getBBox()}catch(t){r=nd.call(e,!0)}return r&&(r.width||r.height)||e.getBBox===nd||(r=nd.call(e,!0)),!r||r.width||r.x||r.y?r:{x:+od(e,["x","cx","x1"])||0,y:+od(e,["y","cy","y1"])||0,width:0,height:0}}function qd(t){return!(!t.getCTM||t.parentNode&&!t.ownerSVGElement||!pd(t))}function rd(t,e){if(e){var r=t.style;e in ze&&e!==Ne&&(e=Ye),r.removeProperty?("ms"!==e.substr(0,2)&&"webkit"!==e.substr(0,6)||(e="-"+e),r.removeProperty(e.replace(Ie,"-$1").toLowerCase())):r.removeAttribute(e)}}function sd(t,e,r,i,n,a){var s=new ie(t._pt,e,r,0,1,a?$c:Zc);return(t._pt=s).b=i,s.e=n,t._props.push(r),s}function ud(t,e,r,i){var n,a,s,o,u=parseFloat(r)||0,h=(r+"").trim().substr((u+"").length)||"px",l=le.style,f=Le.test(e),d="svg"===t.tagName.toLowerCase(),p=(d?"client":"offset")+(f?"Width":"Height"),_="px"===i,c="%"===i;return i===h||!u||Ve[i]||Ve[h]?u:("px"===h||_||(u=ud(t,e,r,"px")),o=t.getCTM&&qd(t),c&&(ze[e]||~e.indexOf("adius"))?aa(u/(o?t.getBBox()[f?"width":"height"]:t[p])*100):(l[f?"width":"height"]=100+(_?h:i),a=~e.indexOf("adius")||"em"===i&&t.appendChild&&!d?t:t.parentNode,o&&(a=(t.ownerSVGElement||{}).parentNode),a&&a!==oe&&a.appendChild||(a=oe.body),(s=a._gsap)&&c&&s.width&&f&&s.time===At.time?aa(u/s.width*100):(!c&&"%"!==h||(l.position=jd(t,"position")),a===t&&(l.position="static"),a.appendChild(le),n=le[p],a.removeChild(le),l.position="absolute",f&&c&&((s=Z(a)).time=At.time,s.width=a[p]),aa(_?n*u/100:n&&u?100/n*u:0))))}function vd(t,e,r,i){var n;return he||md(),e in qe&&"transform"!==e&&~(e=qe[e]).indexOf(",")&&(e=e.split(",")[0]),ze[e]&&"transform"!==e?(n=Qe(t,i),n="transformOrigin"!==e?n[e]:We(jd(t,Ne))+" "+n.zOrigin+"px"):(n=t.style[e])&&"auto"!==n&&!i&&!~(n+"").indexOf("calc(")||(n=Ge[e]&&Ge[e](t,e,r)||jd(t,e)||$(t,e)||("opacity"===e?1:0)),r&&!~(n+"").indexOf(" ")?ud(t,e,n,r)+r:n}function wd(t,e,r,i){if(!r||"none"===r){var n=Ue(e,t,1),a=n&&jd(t,n,1);a&&a!==r?(e=n,r=a):"borderColor"===e&&(r=jd(t,"borderTopColor"))}var s,o,u,h,l,f,d,p,_,c,m,g,v=new ie(this._pt,t.style,e,0,1,Ht),y=0,T=0;if(v.b=r,v.e=i,r+="","auto"===(i+="")&&(t.style[e]=i,i=jd(t,e)||i,t.style[e]=r),qb(s=[r,i]),i=s[1],u=(r=s[0]).match(it)||[],(i.match(it)||[]).length){for(;o=it.exec(i);)d=o[0],_=i.substring(y,o.index),l?l=(l+1)%5:"rgba("!==_.substr(-5)&&"hsla("!==_.substr(-5)||(l=1),d!==(f=u[T++]||"")&&(h=parseFloat(f)||0,m=f.substr((h+"").length),(g="="===d.charAt(1)?+(d.charAt(0)+"1"):0)&&(d=d.substr(2)),p=parseFloat(d),c=d.substr((p+"").length),y=it.lastIndex-c.length,c||(c=c||j.units[e]||m,y===i.length&&(i+=c,v.e+=c)),m!==c&&(h=ud(t,e,f,c)||0),v._pt={_next:v._pt,p:_||1===T?_:",",s:h,c:g?g*p:p-h,m:l&&l<4?Math.round:0});v.c=y<i.length?i.substring(y,i.length):""}else v.r="display"===e&&"none"===i?$c:Zc;return at.test(i)&&(v.e=0),this._pt=v}function yd(t){var e=t.split(" "),r=e[0],i=e[1]||"50%";return"top"!==r&&"bottom"!==r&&"left"!==i&&"right"!==i||(t=r,r=i,i=t),e[0]=Xe[r]||r,e[1]=Xe[i]||i,e.join(" ")}function zd(t,e){if(e.tween&&e.tween._time===e.tween._dur){var r,i,n,a=e.t,s=a.style,o=e.u,u=a._gsap;
vendor: 11,014 bytes, line 2129
2129if("all"===o||!0===o)s.cssText="",i=1;else for(n=(o=o.split(",")).length;-1<--n;)r=o[n],ze[r]&&(i=1,r="transformOrigin"===r?Ne:Ye),rd(a,r);i&&(rd(a,Ye),u&&(u.svg&&a.removeAttribute("transform"),Qe(a,1),u.uncache=1))}}function Dd(t){return"matrix(1, 0, 0, 1, 0, 0)"===t||"none"===t||!t}function Ed(t){var e=jd(t,Ye);return Dd(e)?Ze:e.substr(7).match(rt).map(aa)}function Fd(t,e){var r,i,n,a,s=t._gsap||Z(t),o=t.style,u=Ed(t);return s.svg&&t.getAttribute("transform")?"1,0,0,1,0,0"===(u=[(n=t.transform.baseVal.consolidate().matrix).a,n.b,n.c,n.d,n.e,n.f]).join(",")?Ze:u:(u!==Ze||t.offsetParent||t===ue||s.svg||(n=o.display,o.display="block",(r=t.parentNode)&&t.offsetParent||(a=1,i=t.nextSibling,ue.appendChild(t)),u=Ed(t),n?o.display=n:rd(t,"display"),a&&(i?r.insertBefore(t,i):r?r.appendChild(t):ue.removeChild(t))),e&&6<u.length?[u[0],u[1],u[4],u[5],u[12],u[13]]:u)}function Gd(t,e,r,i,n,a){var s,o,u,h=t._gsap,l=n||Fd(t,!0),f=h.xOrigin||0,d=h.yOrigin||0,p=h.xOffset||0,_=h.yOffset||0,c=l[0],m=l[1],g=l[2],v=l[3],y=l[4],T=l[5],b=e.split(" "),w=parseFloat(b[0])||0,x=parseFloat(b[1])||0;r?l!==Ze&&(o=c*v-m*g)&&(u=w*(-m/o)+x*(c/o)-(c*T-m*y)/o,w=w*(v/o)+x*(-g/o)+(g*T-v*y)/o,x=u):(w=(s=pd(t)).x+(~b[0].indexOf("%")?w/100*s.width:w),x=s.y+(~(b[1]||b[0]).indexOf("%")?x/100*s.height:x)),i||!1!==i&&h.smooth?(y=w-f,T=x-d,h.xOffset=p+(y*c+T*g)-y,h.yOffset=_+(y*m+T*v)-T):h.xOffset=h.yOffset=0,h.xOrigin=w,h.yOrigin=x,h.smooth=!!i,h.origin=e,h.originIsAbsolute=!!r,t.style[Ne]="0px 0px",a&&(sd(a,h,"xOrigin",f,w),sd(a,h,"yOrigin",d,x),sd(a,h,"xOffset",p,h.xOffset),sd(a,h,"yOffset",_,h.yOffset)),t.setAttribute("data-svg-origin",w+" "+x)}function Jd(t,e,r){var i=La(e);return aa(parseFloat(e)+parseFloat(ud(t,"x",r+"px",i)))+i}function Qd(t,e,r,i,a,s){var o,u,h=360,l=n(a),f=parseFloat(a)*(l&&~a.indexOf("rad")?Fe:1),d=s?f*s:f-i,p=i+d+"deg";return l&&("short"===(o=a.split("_")[1])&&(d%=h)!==d%180&&(d+=d<0?h:-h),"cw"===o&&d<0?d=(d+36e9)%h-~~(d/h)*h:"ccw"===o&&0<d&&(d=(d-36e9)%h-~~(d/h)*h)),t._pt=u=new ie(t._pt,e,r,i,d,Wc),u.e=p,u.u="deg",t._props.push(r),u}function Rd(t,e,r){var i,n,a,s,o,u,h,l=fe.style,f=r._gsap;for(n in l.cssText=getComputedStyle(r).cssText+";position:absolute;display:block;",l[Ye]=e,oe.body.appendChild(fe),i=Qe(fe,1),ze)(a=f[n])!==(s=i[n])&&"perspective,force3D,transformOrigin,svgOrigin".indexOf(n)<0&&(o=La(a)!==(h=La(s))?ud(r,n,a,h):parseFloat(a),u=parseFloat(s),t._pt=new ie(t._pt,f,n,o,u-o,Vc),t._pt.u=h||0,t._props.push(n));oe.body.removeChild(fe)}var se,oe,ue,he,le,fe,de,pe,_e=Dt.Power0,ce=Dt.Power1,me=Dt.Power2,ge=Dt.Power3,ve=Dt.Power4,ye=Dt.Linear,Te=Dt.Quad,be=Dt.Cubic,we=Dt.Quart,xe=Dt.Quint,ke=Dt.Strong,Oe=Dt.Elastic,Me=Dt.Back,Ce=Dt.SteppedEase,Ae=Dt.Bounce,Pe=Dt.Sine,De=Dt.Expo,Se=Dt.Circ,ze={},Fe=180/Math.PI,Re=Math.PI/180,Ee=Math.atan2,Ie=/([A-Z])/g,Le=/(?:left|right|width|margin|padding|x)/i,Be=/[\s,\(]\S/,qe={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},Ye="transform",Ne=Ye+"Origin",je="O,Moz,ms,Ms,Webkit".split(","),Ue=function _checkPropPrefix(t,e,r){var i=(e||le).style,n=5;if(t in i&&!r)return t;for(t=t.charAt(0).toUpperCase()+t.substr(1);n--&&!(je[n]+t in i););return n<0?null:(3===n?"ms":0<=n?je[n]:"")+t},Ve={deg:1,rad:1,turn:1},Xe={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},Ge={clearProps:function clearProps(t,e,r,i,n){if("isFromStart"!==n.data){var a=t._pt=new ie(t._pt,e,r,0,0,zd);return a.u=i,a.pr=-10,a.tween=n,t._props.push(r),1}}},Ze=[1,0,0,1,0,0],Je={},Qe=function _parseTransform(t,e){var r=t._gsap||new It(t);if("x"in r&&!e&&!r.uncache)return r;var i,n,a,s,o,u,h,l,f,d,p,_,c,m,g,v,y,T,b,w,x,k,O,M,C,A,P,D,S,z,F,R,E=t.style,I=r.scaleX<0,L="deg",B=jd(t,Ne)||"0";return i=n=a=u=h=l=f=d=p=0,s=o=1,r.svg=!(!t.getCTM||!qd(t)),m=Fd(t,r.svg),r.svg&&(M=!r.uncache&&t.getAttribute("data-svg-origin"),Gd(t,M||B,!!M||r.originIsAbsolute,!1!==r.smooth,m)),_=r.xOrigin||0,c=r.yOrigin||0,m!==Ze&&(T=m[0],b=m[1],w=m[2],x=m[3],i=k=m[4],n=O=m[5],6===m.length?(s=Math.sqrt(T*T+b*b),o=Math.sqrt(x*x+w*w),u=T||b?Ee(b,T)*Fe:0,(f=w||x?Ee(w,x)*Fe+u:0)&&(o*=Math.cos(f*Re)),r.svg&&(i-=_-(_*T+c*w),n-=c-(_*b+c*x))):(R=m[6],z=m[7],P=m[8],D=m[9],S=m[10],F=m[11],i=m[12],n=m[13],a=m[14],h=(g=Ee(R,S))*Fe,g&&(M=k*(v=Math.cos(-g))+P*(y=Math.sin(-g)),C=O*v+D*y,A=R*v+S*y,P=k*-y+P*v,D=O*-y+D*v,S=R*-y+S*v,F=z*-y+F*v,k=M,O=C,R=A),l=(g=Ee(-w,S))*Fe,g&&(v=Math.cos(-g),F=x*(y=Math.sin(-g))+F*v,T=M=T*v-P*y,b=C=b*v-D*y,w=A=w*v-S*y),u=(g=Ee(b,T))*Fe,g&&(M=T*(v=Math.cos(g))+b*(y=Math.sin(g)),C=k*v+O*y,b=b*v-T*y,O=O*v-k*y,T=M,k=C),h&&359.9<Math.abs(h)+Math.abs(u)&&(h=u=0,l=180-l),s=aa(Math.sqrt(T*T+b*b+w*w)),o=aa(Math.sqrt(O*O+R*R)),g=Ee(k,O),f=2e-4<Math.abs(g)?g*Fe:0,p=F?1/(F<0?-F:F):0),r.svg&&(M=t.getAttribute("transform"),r.forceCSS=t.setAttribute("transform","")||!Dd(jd(t,Ye)),M&&t.setAttribute("transform",M))),90<Math.abs(f)&&Math.abs(f)<270&&(I?(s*=-1,f+=u<=0?180:-180,u+=u<=0?180:-180):(o*=-1,f+=f<=0?180:-180)),r.x=((r.xPercent=i&&Math.round(t.offsetWidth/2)===Math.round(-i)?-50:0)?0:i)+"px",r.y=((r.yPercent=n&&Math.round(t.offsetHeight/2)===Math.round(-n)?-50:0)?0:n)+"px",r.z=a+"px",r.scaleX=aa(s),r.scaleY=aa(o),r.rotation=aa(u)+L,r.rotationX=aa(h)+L,r.rotationY=aa(l)+L,r.skewX=f+L,r.skewY=d+L,r.transformPerspective=p+"px",(r.zOrigin=parseFloat(B.split(" ")[2])||0)&&(E[Ne]=We(B)),r.xOffset=r.yOffset=0,r.force3D=j.force3D,r.renderTransform=r.svg?rr:pe?er:$e,r.uncache=0,r},We=function _firstTwoOnly(t){return(t=t.split(" "))[0]+" "+t[1]},$e=function _renderNon3DTransforms(t,e){e.z="0px",e.rotationY=e.rotationX="0deg",e.force3D=0,er(t,e)},He="0deg",Ke="0px",tr=") ",er=function _renderCSSTransforms(t,e){var r=e||this,i=r.xPercent,n=r.yPercent,a=r.x,s=r.y,o=r.z,u=r.rotation,h=r.rotationY,l=r.rotationX,f=r.skewX,d=r.skewY,p=r.scaleX,_=r.scaleY,c=r.transformPerspective,m=r.force3D,g=r.target,v=r.zOrigin,y="",T="auto"===m&&t&&1!==t||!0===m;if(v&&(l!==He||h!==He)){var b,w=parseFloat(h)*Re,x=Math.sin(w),k=Math.cos(w);w=parseFloat(l)*Re,b=Math.cos(w),a=Jd(g,a,x*b*-v),s=Jd(g,s,-Math.sin(w)*-v),o=Jd(g,o,k*b*-v+v)}c!==Ke&&(y+="perspective("+c+tr),(i||n)&&(y+="translate("+i+"%, "+n+"%) "),!T&&a===Ke&&s===Ke&&o===Ke||(y+=o!==Ke||T?"translate3d("+a+", "+s+", "+o+") ":"translate("+a+", "+s+tr),u!==He&&(y+="rotate("+u+tr),h!==He&&(y+="rotateY("+h+tr),l!==He&&(y+="rotateX("+l+tr),f===He&&d===He||(y+="skew("+f+", "+d+tr),1===p&&1===_||(y+="scale("+p+", "+_+tr),g.style[Ye]=y||"translate(0, 0)"},rr=function _renderSVGTransforms(t,e){var r,i,n,a,s,o=e||this,u=o.xPercent,h=o.yPercent,l=o.x,f=o.y,d=o.rotation,p=o.skewX,_=o.skewY,c=o.scaleX,m=o.scaleY,g=o.target,v=o.xOrigin,y=o.yOrigin,T=o.xOffset,b=o.yOffset,w=o.forceCSS,x=parseFloat(l),k=parseFloat(f);d=parseFloat(d),p=parseFloat(p),(_=parseFloat(_))&&(p+=_=parseFloat(_),d+=_),d||p?(d*=Re,p*=Re,r=Math.cos(d)*c,i=Math.sin(d)*c,n=Math.sin(d-p)*-m,a=Math.cos(d-p)*m,p&&(_*=Re,s=Math.tan(p-_),n*=s=Math.sqrt(1+s*s),a*=s,_&&(s=Math.tan(_),r*=s=Math.sqrt(1+s*s),i*=s)),r=aa(r),i=aa(i),n=aa(n),a=aa(a)):(r=c,a=m,i=n=0),(x&&!~(l+"").indexOf("px")||k&&!~(f+"").indexOf("px"))&&(x=ud(g,"x",l,"px"),k=ud(g,"y",f,"px")),(v||y||T||b)&&(x=aa(x+v-(v*r+y*n)+T),k=aa(k+y-(v*i+y*a)+b)),(u||h)&&(s=g.getBBox(),x=aa(x+u/100*s.width),k=aa(k+h/100*s.height)),s="matrix("+r+","+i+","+n+","+a+","+x+","+k+")",g.setAttribute("transform",s),w&&(g.style[Ye]=s)};_("padding,margin,Width,Radius",function(e,r){var t="Right",i="Bottom",n="Left",o=(r<3?["Top",t,i,n]:["Top"+n,"Top"+t,i+t,i+n]).map(function(t){return r<2?e+t:"border"+t+e});Ge[1<r?"border"+e:e]=function(e,t,r,i,n){var a,s;if(arguments.length<4)return a=o.map(function(t){return vd(e,t,r)}),5===(s=a.join(" ")).split(a[0]).length?a[0]:s;a=(i+"").split(" "),s={},o.forEach(function(t,e){return s[t]=a[e]=a[e]||a[(e-1)/2|0]}),e.init(t,s,n)}});var ir,nr,ar,sr={name:"css",register:md,targetTest:function targetTest(t){return t.style&&t.nodeType},init:function init(t,e,r,i,n){var a,s,o,u,h,l,f,d,p,_,c,m,g,v,y,T=this._props,b=t.style;for(f in he||md(),e)if("autoRound"!==f&&(s=e[f],!ft[f]||!Nb(f,e,r,i,t,n)))if(h=typeof s,l=Ge[f],"function"===h&&(h=typeof(s=s.call(r,i,t,n))),"string"===h&&~s.indexOf("random(")&&(s=ab(s)),l)l(this,t,f,s,r)&&(y=1);else if("--"===f.substr(0,2))this.add(b,"setProperty",getComputedStyle(t).getPropertyValue(f)+"",s+"",i,n,0,0,f);else if("undefined"!==h){if(a=vd(t,f),u=parseFloat(a),(_="string"===h&&"="===s.charAt(1)?+(s.charAt(0)+"1"):0)&&(s=s.substr(2)),o=parseFloat(s),f in qe&&("autoAlpha"===f&&(1===u&&"hidden"===vd(t,"visibility")&&o&&(u=0),sd(this,b,"visibility",u?"inherit":"hidden",o?"inherit":"hidden",!o)),"scale"!==f&&"transform"!==f&&~(f=qe[f]).indexOf(",")&&(f=f.split(",")[0])),c=f in ze)if(m||((g=t._gsap).renderTransform||Qe(t),v=!1!==e.smoothOrigin&&g.smooth,(m=this._pt=new ie(this._pt,b,Ye,0,1,g.renderTransform,g,0,-1)).dep=1),"scale"===f)this._pt=new ie(this._pt,g,"scaleY",g.scaleY,_?_*o:o-g.scaleY),T.push("scaleY",f),f+="X";else{if("transformOrigin"===f){s=yd(s),g.svg?Gd(t,s,0,v,0,this):((p=parseFloat(s.split(" ")[2])||0)!==g.zOrigin&&sd(this,g,"zOrigin",g.zOrigin,p),sd(this,b,f,We(a),We(s)));continue}if("svgOrigin"===f){Gd(t,s,1,v,0,this);continue}if(f in Je){Qd(this,g,f,u,s,_);continue}if("smoothOrigin"===f){sd(this,g,"smooth",g.smooth,s);continue}if("force3D"===f){g[f]=s;continue}if("transform"===f){Rd(this,s,t);continue}}else f in b||(f=Ue(f)||f);if(c||(o||0===o)&&(u||0===u)&&!Be.test(s)&&f in b)o=o||0,(d=(a+"").substr((u+"").length))!==(p=La(s)||(f in j.units?j.units[f]:d))&&(u=ud(t,f,a,p)),this._pt=new ie(this._pt,c?g:b,f,u,_?_*o:o-u,"px"!==p||!1===e.autoRound||c?Vc:Yc),this._pt.u=p||0,d!==p&&(this._pt.b=a,this._pt.r=Xc);else if(f in b)wd.call(this,t,f,a,s);else{if(!(f in t)){L(f,s);continue}this.add(t,f,t[f],s,i,n)}T.push(f)}y&&re(this)},get:vd,aliases:qe,getSetter:function getSetter(t,e,r){var i=qe[e];return i&&i.indexOf(",")<0&&(e=i),e in ze&&e!==Ne&&(t._gsap.x||vd(t,"x"))?r&&de===r?"scale"===e?cd:bd:(de=r||{})&&("scale"===e?dd:ed):t.style&&!q(t.style[e])?_c:~e.indexOf("-")?ad:Qt(t,e)},core:{_removeProperty:rd,_getMatrix:Fd}};ae.utils.checkPrefix=Ue,ar=_((ir="x,y,z,scale,scaleX,scaleY,xPercent,yPercent")+","+(nr="rotation,rotationX,rotationY,skewX,skewY")+",transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective",function(t){ze[t]=1}),_(nr,function(t){j.units[t]="deg",Je[t]=1}),qe[ar[13]]=ir+","+nr,_("0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY",function(t){var e=t.split(":");qe[e[1]]=ar[e[0]]}),_("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(t){j.units[t]="px"}),ae.registerPlugin(sr);var or=ae.registerPlugin(sr)||ae,ur=or.core.Tween;e.Back=Me,e.Bounce=Ae,e.CSSPlugin=sr,e.Circ=Se,e.Cubic=be,e.Elastic=Oe,e.Expo=De,e.Linear=ye,e.Power0=_e,e.Power1=ce,e.Power2=me,e.Power3=ge,e.Power4=ve,e.Quad=Te,e.Quart=we,e.Quint=xe,e.Sine=Pe,e.SteppedEase=Ce,e.Strong=ke,e.TimelineLite=Bt,e.TimelineMax=Bt,e.TweenLite=Xt,e.TweenMax=ur,e.default=or,e.gsap=or;if (typeof(window)==="undefined"||window!==e){Object.defineProperty(e,"__esMo
2129dule",{value:!0})} else {delete e.default}});
2130
2131
2132!function(E,y,C,o){"use strict";var i=function t(e,i){return new t.Instance(e,i||{})},c=i.globalSettings={scrollMinUpdateInterval:25,checkFrequency:1e3,pauseCheck:!1};i.defaults={preventParentScroll:!1,forceScrollbars:!1,scrollStopDelay:300,maxTrackSize:95,minTrackSize:5,draggableTracks:!0,autoUpdate:!0,classPrefix:"optiscroll-",wrapContent:!0,rtl:!1},(i.Instance=function(t,e){this.element=t,this.settings=S(S({},i.defaults),e||{}),"boolean"!=typeof e.rtl&&(this.settings.rtl="rtl"===E.getComputedStyle(t).direction),this.cache={},this.init()}).prototype={init:function(){var t=this.element,e=this.settings,i=!1,l=this.scrollEl=e.wrapContent?u.createWrapper(t):t.firstElementChild;T(l,e.classPrefix+"content",!0),T(t,"is-enabled"+(e.rtl?" is-rtl":""),!0),this.scrollbars={v:s("v",this),h:s("h",this)},(w.scrollbarSpec.width||e.forceScrollbars)&&(i=u.hideNativeScrollbars(l,e.rtl)),i&&h(this.scrollbars,"create"),w.isTouch&&e.preventParentScroll&&T(t,e.classPrefix+"prevent",!0),this.update(),this.bind(),e.autoUpdate&&w.instances.push(this),e.autoUpdate&&!w.checkTimer&&u.checkLoop()},bind:function(){var l,s,r,n,t=this.listeners={},e=this.scrollEl;for(var i in t.scroll=(l=a.scroll.bind(this),s=c.scrollMinUpdateInterval,function(){var t=this,e=Date.now(),i=arguments;r&&e<r+s?(clearTimeout(n),n=setTimeout(function(){r=e,l.apply(t,i)},s)):(r=e,l.apply(t,i))}),w.isTouch&&(t.touchstart=a.touchstart.bind(this),t.touchend=a.touchend.bind(this)),t.mousewheel=t.wheel=a.wheel.bind(this),t)e.addEventListener(i,t[i],w.passiveEvent)},update:function(){var t=this.scrollEl,e=this.cache,i=e.clientH,l=t.scrollHeight,s=t.clientHeight,r=t.scrollWidth,n=t.clientWidth;if(l!==e.scrollH||s!==e.clientH||r!==e.scrollW||n!==e.clientW){if(e.scrollH=l,e.clientH=s,e.scrollW=r,e.clientW=n,i!==o){if(0===l&&0===s&&!y.body.contains(this.element))return this.destroy(),!1;this.fireCustomEvent("sizechange")}h(this.scrollbars,"update")}},scrollTo:function(t,e,i){var l,s,r,n,o=this.cache;w.pauseCheck=!0,this.update(),l=this.scrollEl.scrollLeft,s=this.scrollEl.scrollTop,r=+t,"left"===t&&(r=0),"right"===t&&(r=o.scrollW-o.clientW),!1===t&&(r=l),n=+e,"top"===e&&(n=0),"bottom"===e&&(n=o.scrollH-o.clientH),!1===e&&(n=s),this.animateScroll(l,r,s,n,+i)},scrollIntoView:function(t,e,i){var l,s,r,n,o,c,a,h,u,p,d,f,v=this.scrollEl;w.pauseCheck=!0,this.update(),"string"==typeof t?t=v.querySelector(t):t.length&&t.jquery&&(t=t[0]),"number"==typeof i&&(i={top:i,right:i,bottom:i,left:i}),i=i||{},l=t.getBoundingClientRect(),s=v.getBoundingClientRect(),u=d=v.scrollLeft,p=f=v.scrollTop,a=u+l.left-s.left,h=p+l.top-s.top,r=a-(i.left||0),n=h-(i.top||0),r<u&&(d=r),u<(o=a+l.width-this.cache.clientW+(i.right||0))&&(d=o),n<p&&(f=n),p<(c=h+l.height-this.cache.clientH+(i.bottom||0))&&(f=c),this.animateScroll(u,d,p,f,+e)},animateScroll:function(l,s,r,n,o){var c=this,a=this.scrollEl,h=Date.now();if(s!==l||n!==r){if(0===o)return a.scrollLeft=s,void(a.scrollTop=n);isNaN(o)&&(o=15*C.pow(C.max(C.abs(s-l),C.abs(n-r)),.54)),function t(){var e=C.min(1,(Date.now()-h)/o),i=u.easingFunction(e);n!==r&&(a.scrollTop=~~(i*(n-r))+r),s!==l&&(a.scrollLeft=~~(i*(s-l))+l),c.scrollAnimation=e<1?E.requestAnimationFrame(t):null}()}},destroy:function(){var t,e=this,i=this.element,l=this.scrollEl,s=this.listeners;if(this.scrollEl){for(var r in s)l.removeEventListener(r,s[r]);if(h(this.scrollbars,"remove"),this.settings.wrapContent){for(;t=l.childNodes[0];)i.insertBefore(t,l);i.removeChild(l),this.scrollEl=null}T(i,this.settings.classPrefix+"prevent",!1),T(i,"is-enabled",!1),E.requestAnimationFrame(function(){var t=w.instances.indexOf(e);-1<t&&w.instances.splice(t,1)})}},fireCustomEvent:function(t){var e,i,l=this.cache,s=l.scrollH,r=l.scrollW;e={scrollbarV:S({},l.v),scrollbarH:S({},l.h),scrollTop:l.v.position*s,scrollLeft:l.h.position*r,scrollBottom:(1-l.v.position-l.v.size)*s,scrollRight:(1-l.h.position-l.h.size)*r,scrollWidth:r,scrollHeight:s,clientWidth:l.clientW,clientHeight:l.clientH},"function"==typeof CustomEvent?i=new CustomEvent(t,{detail:e}):(i=y.createEvent("CustomEvent")).initCustomEvent(t,!1,!1,e),this.element.dispatchEvent(i)}};var t,e,a={scroll:function(t){w.pauseCheck||this.fireCustomEvent("scrollstart"),w.pauseCheck=!0,this.scrollbars.v.update(
2132),this.scrollbars.h.update(),this.fireCustomEvent("scroll"),clearTimeout(this.cache.timerStop),this.cache.timerStop=setTimeout(a.scrollStop.bind(this),this.settings.scrollStopDelay)},touchstart:function(t){w.pauseCheck=!1,this.scrollbars.v.update(),this.scrollbars.h.update(),a.wheel.call(this,t)},touchend:function(t){clearTimeout(this.cache.timerStop)},scrollStop:function(){this.fireCustomEvent("scrollstop"),w.pauseCheck=!1},wheel:function(t){var e=this.cache,i=e.v,l=e.h,s=this.settings.preventParentScroll&&w.isTouch;E.cancelAnimationFrame(this.scrollAnimation),s&&i.enabled&&i.percent%100==0&&(this.scrollEl.scrollTop=i.percent?e.scrollH-e.clientH-1:1),s&&l.enabled&&l.percent%100==0&&(this.scrollEl.scrollLeft=l.percent?e.scrollW-e.clientW-1:1)}},s=function(e,i){var n="v"===e,l=i.element,o=i.scrollEl,c=i.settings,a=i.cache,r=a[e]={},t=n?"H":"W",h="client"+t,u="scroll"+t,p=n?"scrollTop":"scrollLeft",s=n?["top","bottom"]:["left","right"],d=/^(mouse|touch|pointer)/,f=w.scrollbarSpec.rtl,v=!1,m=null,g=null,b={dragData:null,dragStart:function(t){t.preventDefault();var e=t.touches?t.touches[0]:t;b.dragData={x:e.pageX,y:e.pageY,scroll:o[p]},b.bind(!0,t.type.match(d)[1])},dragMove:function(t){var e,i=t.touches?t.touches[0]:t,l=c.rtl&&1===f&&!n?-1:1;t.preventDefault(),e=(n?i.pageY-b.dragData.y:i.pageX-b.dragData.x)/a[h],o[p]=b.dragData.scroll+e*a[u]*l},dragEnd:function(t){b.dragData=null,b.bind(!1,t.type.match(d)[1])},bind:function(t,e){var i=(t?"add":"remove")+"EventListener",l=e+"move",s=e+("touch"===e?"end":"up");y[i](l,b.dragMove),y[i](s,b.dragEnd),y[i](e+"cancel",b.dragEnd)}};return{toggle:function(t){v=t,g&&T(l,"has-"+e+"track",v),r.enabled=v},create:function(){(m=y.createElement("div"),g=y.createElement("b"),m.className=c.classPrefix+e,g.className=c.classPrefix+e+"track",m.appendChild(g),l.appendChild(m),c.draggableTracks)&&(E.PointerEvent?["pointerdown"]:["touchstart","mousedown"]).forEach(function(t){g.addEventListener(t,b.dragStart)})},update:function(){var t,e,i,l,s;(v||a[h]!==a[u])&&(t=(i=this.calc()).size,e=r.size,l=1/t*i.position*100,s=C.abs(i.position-(r.position||0))*a[h],1===t&&v&&this.toggle(!1),t<1&&!v&&this.toggle(!0),g&&v&&this.style(l,s,t,e),r=S(r,i),v&&this.fireEdgeEv())},style:function(t,e,i,l){i!==l&&(g.style[n?"height":"width"]=100*i+"%",c.rtl&&!n&&(g.style.marginRight=100*(1-i)+"%")),g.style[w.cssTransform]="translate("+(n?"0%,"+t+"%":t+"%,0%")+")"},calc:function(){var t,e=o[p],i=a[h],l=a[u],s=i/l,r=l-i;return 1<=s||!l?{position:0,size:1,percent:0}:(!n&&c.rtl&&f&&(e=r-e*f),t=100*e/r,e<=1&&(t=0),r-1<=e&&(t=100),s=C.max(s,c.minTrackSize/100),{position:t/100*(1-(s=C.min(s,c.maxTrackSize/100))),size:s,percent:t})},fireEdgeEv:function(){var t=r.percent;r.was!==t&&t%100==0&&(i.fireCustomEvent("scrollreachedge"),i.fireCustomEvent("scrollreach"+s[t/100])),r.was=t},remove:function(){this.toggle(!1),m&&(m.parentNode.removeChild(m),m=null)}}},u={hideNativeScrollbars:function(t,e){var i=w.scrollbarSpec.width,l=t.style;if(0===i){var s=Date.now();return t.setAttribute("data-scroll",s),u.addCssRule('[data-scroll="'+s+'"]::-webkit-scrollbar',"display:none;width:0;height:0;")}return l[e?"left":"right"]=-i+"px",l.bottom=-i+"px",!0},addCssRule:function(t,e){var i=y.getElementById("scroll-sheet");i||((i=y.createElement("style")).id="scroll-sheet",i.appendChild(y.createTextNode("")),y.head.appendChild(i));try{return i.sheet.insertRule(t+" {"+e+"}",0),!0}catch(t){return}},createWrapper:function(t,e){for(var i,l=y.createElement("div");i=t.childNodes[0];)l.appendChild(i);return t.appendChild(l)},checkLoop:function(){w.instances.length?(w.pauseCheck||h(w.instances,"update"),c.checkFrequency&&(w.checkTimer=setTimeout(function(){u.checkLoop()},c.checkFrequency))):w.checkTimer=null},easingFunction:function(t){return--t*t*t+1}},w=i.G={isTouch:"ontouchstart"in E,cssTransition:l("transition"),cssTransform:l("transform"),scrollbarSpec:function(){var t,e,i=y.documentElement,l=0,s=1;(t=y.createElement("div")).style.cssText="overflow:scroll;width:50px;height:50px;position:absolute;left:-100px;direction:rtl",(e=y.createElement("div")).style.cssText="width:100px;height:100px",t.appendChild(e),i.appendChild(t),l=t.offsetWidth-t.clientWidth,0<t.scrollLeft?s=0:(t.scrollLeft=1,0===t.scrollLeft&&(s=-1));return i.removeChild(t),{width:l,rtl:s}}(),passiveEvent:(t=!1,e=Object.defineProperty({},"passive",{get:function(){t=!0}}),E.addEventListener("test",null,e),!!t&&{capture:!1,passive:!0}),instances:[],checkTimer:null,pauseCheck:!1};function l(t){var e=t.charAt(0).toUpperCase()+t.slice(1),i=y.createElement("test"),l=[t,"Webkit"+e];for(var s in l)if(i.style[l[s]]!==o)return l[s];return""}function T(t,e,i){var l=t.className.split(/\s+/),s=l.indexOf(e);i?~s||l.push(e):~s&&l.splice(s,1),t.className=l.join(" ")}function S(t,e,i){for(var l in e)!e.hasOwnProperty(l)||t[l]!==o&&i||(t[l]=e[l]);return t}
2132function h(t,e,i){var l,s;if(t.length)for(l=0,s=t.length;l<s;l++)t[l][e].apply(t[l],i);else for(l in t)t[l][e].apply(t[l],i)}"function"==typeof define&&define.amd&&define(function(){return i}),"undefined"!=typeof module&&module.exports&&(module.exports=i),E.Optiscroll=i}(window,document,Math),function(r){var n="optiscroll";r.fn[n]=function(i){var l,s;return"string"==typeof i&&(s=Array.prototype.slice.call(arguments),l=s.shift()),this.each(function(){var t=r(this),e=t.data(n);e?e&&"string"==typeof l&&(e[l].apply(e,s),"destroy"===l&&t.removeData(n)):(e=new window.Optiscroll(this,i||{}),t.data(n,e))})}}(jQuery||Zepto);
2133/*! lightgallery - v1.6.0 - 2017-08-08
2134* http://sachinchoolur.github.io/lightGallery/
2135* Copyright (c) 2017 Sachin N; Licensed GPLv3 */
2136(function (root, factory) {
2137    if (typeof define === 'function' && define.amd) {
2138      // AMD. Register as an anonymous module unless amdModuleId is set
2139      define(['jquery'], function (a0) {
2140        return (factory(a0));
2141      });
2142    } else if (typeof exports === 'object') {
2143      // Node. Does not work with strict CommonJS, but
2144      // only CommonJS-like environments that support module.exports,
2145      // like Node.
2146      module.exports = factory(require('jquery'));
2147    } else {
2148      factory(root["jQuery"]);
2149    }
2150  }(this, function ($) {
2151  
2152  (function() {
2153      'use strict';
2154  
2155      var defaults = {
2156  
2157          mode: 'lg-slide',
2158  
2159          // Ex : 'ease'
2160          cssEasing: 'ease',
2161  
2162          //'for jquery animation'
2163          easing: 'linear',
2164          speed: 600,
2165          height: '100%',
2166          width: '100%',
2167          addClass: '',
2168          startClass: 'lg-start-zoom',
2169          backdropDuration: 150,
2170          hideBarsDelay: 6000,
2171  
2172          useLeft: false,
2173  
2174          closable: true,
2175          loop: true,
2176          escKey: true,
2177          keyPress: true,
2178          controls: true,
2179          slideEndAnimatoin: true,
2180          hideControlOnEnd: false,
2181          mousewheel: true,
2182  
2183          getCaptionFromTitleOrAlt: true,
2184  
2185          // .lg-item || '.lg-sub-html'
2186          appendSubHtmlTo: '.lg-sub-html',
2187  
2188          subHtmlSelectorRelative: false,
2189  
2190          /**
2191           * @desc number of preload slides
2192           * will exicute only after the current slide is fully loaded.
2193           *
2194           * @ex you clicked on 4th image and if preload = 1 then 3rd slide and 5th
2195           * slide will be loaded in the background after the 4th slide is fully loaded..
2196           * if preload is 2 then 2nd 3rd 5th 6th slides will be preloaded.. ... ...
2197           *
2198           */
2199          preload: 1,
2200          showAfterLoad: true,
2201          selector: '',
2202          selectWithin: '',
2203          nextHtml: '',
2204          prevHtml: '',
2205  
2206          // 0, 1
2207          index: false,
2208  
2209          iframeMaxWidth: '100%',
2210  
2211          download: true,
2212          counter: true,
2213          appendCounterTo: '.lg-toolbar',
2214  
2215          swipeThreshold: 50,
2216          enableSwipe: true,
2217          enableDrag: true,
2218  
2219          dynamic: false,
2220          dynamicEl: [],
2221          galleryId: 1
2222      };
2223  
2224      function Plugin(element, options) {
2225  
2226          // Current lightGallery element
2227          this.el = element;
2228  
2229          // Current jquery element
2230          this.$el = $(element);
2231  
2232          // lightGallery settings
2233          this.s = $.extend({}, defaults, options);
2234  
2235          // When using dynamic mode, ensure dynamicEl is an array
2236          if (this.s.dynamic && this.s.dynamicEl !== 'undefined' && this.s.dynamicEl.constructor === Array && !this.s.dynamicEl.length) {
2237              throw ('When using dynamic mode, you must also define dynamicEl as an Array.');
2238          }
2239  
2240          // lightGallery modules
2241          this.modules = {};
2242  
2243          // false when lightgallery complete first slide;
2244          this.lGalleryOn = false;
2245  
2246          this.lgBusy = false;
2247  
2248          // Timeout function for hiding controls;
2249          this.hideBartimeout = false;
2250  
2251          // To determine browser supports for touch events;
2252          this.isTouch = ('ontouchstart' in document.documentElement);
2253  
2254          // Disable hideControlOnEnd if sildeEndAnimation is true
2255          if (this.s.slideEndAnimatoin) {
2256              this.s.hideControlOnEnd = false;
2257          }
2258  
2259          // Gallery items
2260          if (this.s.dynamic) {
2261              this.$items = this.s.dynamicEl;
2262          } else {
2263              if (this.s.selector === 'this') {
2264                  this.$items = this.$el;
2265              } else if (this.s.selector !== '') {
2266                  if (this.s.selectWithin) {
2267                      this.$items = $(this.s.selectWithin).find(this.s.selector);
2268                  } else {
2269                      this.$items = this.$el.find($(this.s.selector));
2270                  }
2271              } else {
2272                  this.$items = this.$el.children();
2273              }
2274          }
2275  
2276          // .lg-item
2277          this.$slide = '';
2278  
2279          // .lg-outer
2280          this.$outer = '';
2281  
2282          this.init();
2283  
2284          return this;
2285      }
2286  
2287      Plugin.prototype.init = function() {
2288  
2289          var _this = this;
2290  
2291          // s.preload should not be more than $item.length
2292          if (_this.s.preload > _this.$items.length) {
2293              _this.s.preload = _this.$items.length;
2294          }
2295  
2296          // if dynamic option is enabled execute immediately
2297          var _hash = window.location.hash;
2298          if (_hash.indexOf('lg=' + this.s.galleryId) > 0) {
2299  
2300              _this.index = parseInt(_hash.split('&slide=')[1], 10);
2301  
2302              $('body').addClass('lg-from-hash');
2303              if (!$('body').hasClass('lg-on')) {
2304                  setTimeout(function() {
2305                      _this.build(_this.index);
2306                  });
2307  
2308                  $('body').addClass('lg-on');
2309              }
2310          }
2311  
2312          if (_this.s.dynamic) {
2313  
2314              _this.$el.trigger('onBeforeOpen.lg');
2315  
2316              _this.index = _this.s.index || 0;
2317  
2318              // prevent accidental double execution
2319              if (!$('body').hasClass('lg-on')) {
2320                  setTimeout(function() {
2321                      _this.build(_this.index);
2322                      $('body').addClass('lg-on');
2323                  });
2324              }
2325          } else {
2326  
2327              // Using different namespace for click because click event should not unbind if selector is same object('this')
2328              _this.$items.on('click.lgcustom', function(event) {
2329  
2330                  // For IE8
2331                  try {
2332                      event.preventDefault();
2333                      event.preventDefault();
2334                  } catch (er) {
2335                      event.returnValue = false;
2336                  }
2337  
2338                  _this.$el.trigger('onBeforeOpen.lg');
2339  
2340                  _this.index = _this.s.index || _this.$items.index(this);
2341  
2342                  // prevent accidental double execution
2343                  if (!$('body').hasClass('lg-on')) {
2344                      _this.build(_this.index);
2345                      $('body').addClass('lg-on');
2346                  }
2347              });
2348          }
2349  
2350      };
2351  
2352      Plugin.prototype.build = function(index) {
2353  
2354          var _this = this;
2355  
2356          _this.structure();
2357  
2358          // module constructor
2359          $.each($.fn.lightGallery.modules, function(key) {
2360              _this.modules[key] = new $.fn.lightGallery.modules[key](_this.el);
2361          });
2362  
2363          // initiate slide function
2364          _this.slide(index, false, false, false);
2365  
2366          if (_this.s.keyPress) {
2367              _this.keyPress();
2368          }
2369  
2370          if (_this.$items.length > 1) {
2371  
2372              _this.arrow();
2373  
2374              setTimeout(function() {
2375                  _this.enableDrag();
2376                  _this.enableSwipe();
2377              }, 50);
2378  
2379              if (_this.s.mousewheel) {
2380                  _this.mousewheel();
2381              }
2382          } else {
2383              _this.$slide.on('click.lg', function() {
2384                  _this.$el.trigger('onSlideClick.lg');
2385              });
2386          }
2387  
2388          _this.counter();
2389  
2390          _this.closeGallery();
2391  
2392          _this.$el.trigger('onAfterOpen.lg');
2393  
2394          // Hide controllers if mouse doesn't move for some period
2395          _this.$outer.on('mousemove.lg click.lg touchstart.lg', function() {
2396  
2397              _this.$outer.removeClass('lg-hide-items');
2398  
2399              clearTimeout(_this.hideBartimeout);
2400  
2401              // Timeout will be cleared on each slide movement also
2402              _this.hideBartimeout = setTimeout(function() {
2403                  _this.$outer.addClass('lg-hide-items');
2404              }, _this.s.hideBarsDelay);
2405  
2406          });
2407  
2408          _this.$outer.trigger('mousemove.lg');
2409  
2410      };
2411  
2412      Plugin.prototype.structure = function() {
2413          var list = '';
2414          var controls = '';
2415          var i = 0;
2416          var subHtmlCont = '';
2417          var template;
2418          var _this = this;
2419  
2420          $('body').append('<div class="lg-backdrop"></div>');
2421          $('.lg-backdrop').css('transition-duration', this.s.backdropDuration + 'ms');
2422  
2423          // Create gallery items
2424          for (i = 0; i < this.$items.length; i++) {
2425              list += '<div class="lg-item"></div>';
2426          }
2427  
2428          // Create controlls
2429          if (this.s.controls && this.$items.length > 1) {
2430              controls = '<div class="lg-actions">' +
2431                  '<button class="lg-prev lg-icon">' + this.s.prevHtml + '</button>' +
2432                  '<button class="lg-next lg-icon">' + this.s.nextHtml + '</button>' +
2433                  '</div>';
2434          }
2435  
2436          if (this.s.appendSubHtmlTo === '.lg-sub-html') {
2437              subHtmlCont = '<div class="lg-sub-html"></div>';
2438          }
2439  
2440          template = '<div class="lg-outer ' + this.s.addClass + ' ' + this.s.startClass + '">' +
2441              '<div class="lg" style="width:' + this.s.width + '; height:' + this.s.height + '">' +
2442              '<div class="lg-inner">
2442' + list + '</div>' +
2443              '<div class="lg-toolbar lg-group">' +
2444              '<span class="lg-close lg-icon"></span>' +
2445              '</div>' +
2446              controls +
2447              subHtmlCont +
2448              '</div>' +
2449              '</div>';
2450  
2451          $('body').append(template);
2452          this.$outer = $('.lg-outer');
2453          this.$slide = this.$outer.find('.lg-item');
2454  
2455          if (this.s.useLeft) {
2456              this.$outer.addClass('lg-use-left');
2457  
2458              // Set mode lg-slide if use left is true;
2459              this.s.mode = 'lg-slide';
2460          } else {
2461              this.$outer.addClass('lg-use-css3');
2462          }
2463  
2464          // For fixed height gallery
2465          _this.setTop();
2466          $(window).on('resize.lg orientationchange.lg', function() {
2467              setTimeout(function() {
2468                  _this.setTop();
2469              }, 100);
2470          });
2471  
2472          // add class lg-current to remove initial transition
2473          this.$slide.eq(this.index).addClass('lg-current');
2474  
2475          // add Class for css support and transition mode
2476          if (this.doCss()) {
2477              this.$outer.addClass('lg-css3');
2478          } else {
2479              this.$outer.addClass('lg-css');
2480  
2481              // Set speed 0 because no animation will happen if browser doesn't support css3
2482              this.s.speed = 0;
2483          }
2484  
2485          this.$outer.addClass(this.s.mode);
2486  
2487          if (this.s.enableDrag && this.$items.length > 1) {
2488              this.$outer.addClass('lg-grab');
2489          }
2490  
2491          if (this.s.showAfterLoad) {
2492              this.$outer.addClass('lg-show-after-load');
2493          }
2494  
2495          if (this.doCss()) {
2496              var $inner = this.$outer.find('.lg-inner');
2497              $inner.css('transition-timing-function', this.s.cssEasing);
2498              $inner.css('transition-duration', this.s.speed + 'ms');
2499          }
2500  
2501          setTimeout(function() {
2502              $('.lg-backdrop').addClass('in');
2503          });
2504  
2505          setTimeout(function() {
2506              _this.$outer.addClass('lg-visible');
2507          }, this.s.backdropDuration);
2508  
2509          if (this.s.download) {
2510              this.$outer.find('.lg-toolbar').append('<a id="lg-download" target="_blank" download class="lg-download lg-icon"></a>');
2511          }
2512  
2513          // Store the current scroll top value to scroll back after closing the gallery..
2514          this.prevScrollTop = $(window).scrollTop();
2515  
2516      };
2517  
2518      // For fixed height gallery
2519      Plugin.prototype.setTop = function() {
2520          if (this.s.height !== '100%') {
2521              var wH = $(window).height();
2522              var top = (wH - parseInt(this.s.height, 10)) / 2;
2523              var $lGallery = this.$outer.find('.lg');
2524              if (wH >= parseInt(this.s.height, 10)) {
2525                  $lGallery.css('top', top + 'px');
2526              } else {
2527                  $lGallery.css('top', '0px');
2528              }
2529          }
2530      };
2531  
2532      // Find css3 support
2533      Plugin.prototype.doCss = function() {
2534          // check for css animation support
2535          var support = function() {
2536              var transition = ['transition', 'MozTransition', 'WebkitTransition', 'OTransition', 'msTransition', 'KhtmlTransition'];
2537              var root = document.documentElement;
2538              var i = 0;
2539              for (i = 0; i < transition.length; i++) {
2540                  if (transition[i] in root.style) {
2541                      return true;
2542                  }
2543              }
2544          };
2545  
2546          if (support()) {
2547              return true;
2548          }
2549  
2550          return false;
2551      };
2552  
2553      /**
2554       *  @desc Check the given src is video
2555       *  @param {String} src
2556       *  @return {Object} video type
2557       *  Ex:{ youtube  :  ["//www.youtube.com/watch?v=c0asJgSyxcY", "c0asJgSyxcY"] }
2558       */
2559      Plugin.prototype.isVideo = function(src, index) {
2560  
2561          var html;
2562          if (this.s.dynamic) {
2563              html = this.s.dynamicEl[index].html;
2564          } else {
2565              html = this.$items.eq(index).attr('data-html');
2566          }
2567  
2568          if (!src) {
2569              if(html) {
2570                  return {
2571                      html5: true
2572                  };
2573              } else {
2574                  console.error('lightGallery :- data-src is not pvovided on slide item ' + (index + 1) + '. Please make sure the selector property is properly configured. More info - http://sachinchoolur.github.io/lightGallery/demos/html-markup.html');
2575                  return false;
2576              }
2577          }
2578  
2579          var youtube = src.match(/\/\/(?:www\.)?youtu(?:\.be|be\.com)\/(?:watch\?v=|embed\/)?([a-z0-9\-\_\%]+)/i);
2580          var vimeo = src.match(/\/\/(?:www\.)?vimeo.com\/([0-9a-z\-_]+)/i);
2581          var dailymotion = src.match(/\/\/(?:www\.)?dai.ly\/([0-9a-z\-_]+)/i);
2582          var vk = src.match(/\/\/(?:www\.)?(?:vk\.com|vkontakte\.ru)\/(?:video_ext\.php\?)(.*)/i);
2583  
2584          if (youtube) {
2585              return {
2586                  youtube: youtube
2587              };
2588          } else if (vimeo) {
2589              return {
2590                  vimeo: vimeo
2591              };
2592          } else if (dailymotion) {
2593              return {
2594                  dailymotion: dailymotion
2595              };
2596          } else if (vk) {
2597              return {
2598                  vk: vk
2599              };
2600          }
2601      };
2602  
2603      /**
2604       *  @desc Create image counter
2605       *  Ex: 1/10
2606       */
2607      Plugin.prototype.counter = function() {
2608          if (this.s.counter) {
2609              $(this.s.appendCounterTo).append('<div id="lg-counter"><span id="lg-counter-current">' + (parseInt(this.index, 10) + 1) + '</span> / <span id="lg-counter-all">' + this.$items.length + '</span></div>');
2610          }
2611      };
2612  
2613      /**
2614       *  @desc add sub-html into the slide
2615       *  @param {Number} index - index of the slide
2616       */
2617      Plugin.prototype.addHtml = function(index) {
2618          var subHtml = null;
2619          var subHtmlUrl;
2620          var $currentEle;
2621          if (this.s.dynamic) {
2622              if (this.s.dynamicEl[index].subHtmlUrl) {
2623                  subHtmlUrl = this.s.dynamicEl[index].subHtmlUrl;
2624              } else {
2625                  subHtml = this.s.dynamicEl[index].subHtml;
2626              }
2627          } else {
2628              $currentEle = this.$items.eq(index);
2629              if ($currentEle.attr('data-sub-html-url')) {
2630                  subHtmlUrl = $currentEle.attr('data-sub-html-url');
2631              } else {
2632                  subHtml = $currentEle.attr('data-sub-html');
2633                  if (this.s.getCaptionFromTitleOrAlt && !subHtml) {
2634                      subHtml = $currentEle.attr('title') || $currentEle.find('img').first().attr('alt');
2635                  }
2636              }
2637          }
2638  
2639          if (!subHtmlUrl) {
2640              if (typeof subHtml !== 'undefined' && subHtml !== null) {
2641  
2642                  // get first letter of subhtml
2643                  // if first letter starts with . or # get the html form the jQuery object
2644                  var fL = subHtml.substring(0, 1);
2645                  if (fL === '.' || fL === '#') {
2646                      if (this.s.subHtmlSelectorRelative && !this.s.dynamic) {
2647                          subHtml = $currentEle.find(subHtml).html();
2648                      } else {
2649                          subHtml = $(subHtml).html();
2650                      }
2651                  }
2652              } else {
2653                  subHtml = '';
2654              }
2655          }
2656  
2657          if (this.s.appendSubHtmlTo === '.lg-sub-html') {
2658  
2659              if (subHtmlUrl) {
2660                  this.$outer.find(this.s.appendSubHtmlTo).load(subHtmlUrl);
2661              } else {
2662                  this.$outer.find(this.s.appendSubHtmlTo).html(subHtml);
2663              }
2664  
2665          } else {
2666  
2667              if (subHtmlUrl) {
2668                  this.$slide.eq(index).load(subHtmlUrl);
2669              } else {
2670                  this.$slide.eq(index).append(subHtml);
2671              }
2672          }
2673  
2674          // Add lg-empty-html class if title doesn't exist
2675          if (typeof subHtml !== 'undefined' && subHtml !== null) {
2676              if (subHtml === '') {
2677                  this.$outer.find(this.s.appendSubHtmlTo).addClass('lg-empty-html');
2678              } else {
2679                  this.$outer.find(this.s.appendSubHtmlTo).removeClass('lg-empty-html');
2680              }
2681          }
2682  
2683          this.$el.trigger('onAfterAppendSubHtml.lg', [index]);
2684      };
2685  
2686      /**
2687       *  @desc Preload slides
2688       *  @param {Number} index - index of the slide
2689       */
2690      Plugin.prototype.preload = function(index) {
2691          var i = 1;
2692          var j = 1;
2693          for (i = 1; i <= this.s.preload; i++) {
2694              if (i >= this.$items.length - index) {
2695                  break;
2696              }
2697  
2698              this.loadContent(index + i, false, 0);
2699          }
2700  
2701          for (j = 1; j <= this.s.preload; j++) {
2702              if (index - j < 0) {
2703                  break;
2704              }
2705  
2706              this.loadContent(index - j, false, 0);
2707          }
2708      };
2709  
2710      /**
2711       *  @desc Load slide content into slide.
2712       *  @param {Number} index - index of the slide.
2713       *  @param {Boolean} rec - if true call loadcontent() function again.
2714       *  @param {Boolean} delay - delay for adding complete class. it is 0 except first time.
2715       */
2716      Plugin.prototype.loadContent = function(index, rec, delay) {
2717  
2718          var _this = this;
2719          var _hasPoster = false;
2720          var _$img;
2721          var _src;
2722          var _poster;
2723          var _srcset;
2724          var _sizes;
2725          var _html;
2726          var getResponsiveSrc = function(srcItms) {
2727              var rsWidth = [];
2728              var rsSrc = [];
2729              for (var i = 0; i < srcItms.length; i++) {
2730                  var __src = srcItms[i].split(' ');
2731  
2732                  // Manage empty space
2733                  if (__src[0] === '') {
2734                      __src.splice(0, 1);
2735                  }
2736  
2737                  rsSrc.push(__src[0]);
2738                  rsWidth.push(__src[1]);
2739              }
2740  
2741              var wWidth = $(window).width();
2742              for (var j = 0; j < rsWidth.length; j++) {
2743                  if (parseInt(rsWidth[j], 10) > wWidth) {
2744                      _src = rsSrc[j];
2745                      break;
2746                  }
2747              }
2748          };
2749  
2750          if (_this.s.dynamic) {
2751  
2752              if (_this.s.dynamicEl[index].poster) {
2753                  _hasPoster = true;
2754                  _poster = _this.s.dynamicEl[index].poster;
2755              }
2756  
2757              _html = _this.s.dynamicEl[index].html;
2758              _src = _this.s.dynamicEl[index].src;
2759  
2760              if (_this.s.dynamicEl[index].responsive) {
2761                  var srcDyItms = _this.s.dynamicEl[index].responsive.split(',');
2762                  getResponsiveSrc(srcDyItms);
2763              }
2764  
2765              _srcset = _this.s.dynamicEl[index].srcset;
2766              _sizes = _this.s.dynamicEl[index].sizes;
2767  
2768          } else {
2769  
2770              if (_this.$items.eq(index).attr('data-poster')) {
2771                  _hasPoster = true;
2772                  _poster = _this.$items.eq(index).attr('data-poster');
2773              }
2774  
2775              _html = _this.$items.eq(index).attr('data-html');
2776              _src = _this.$items.eq(index).attr('href') || _this.$items.eq(index).attr('data-src');
2777  
2778              if (_this.$items.eq(index).attr('data-responsive')) {
2779                  var srcItms = _this.$items.eq(index).attr('data-responsive').split(',');
2780                  getResponsiveSrc(srcItms);
2781              }
2782  
2783              _srcset = _this.$items.eq(index).attr('data-srcset');
2784              _sizes = _this.$items.eq(index).attr('data-sizes');
2785  
2786          }
2787  
2788          //if (_src || _srcset || _sizes || _poster) {
2789  
2790          var iframe = false;
2791          if (_this.s.dynamic) {
2792              if (_this.s.dynamicEl[index].iframe) {
2793                  iframe = true;
2794              }
2795          } else {
2796              if (_this.$items.eq(index).attr('data-iframe') === 'true') {
2797                  iframe = true;
2798              }
2799          }
2800  
2801          var _isVideo = _this.isVideo(_src, index);
2802          if (!_this.$slide.eq(index).hasClass('lg-loaded')) {
2803              if (iframe) {
2804                  _this.$slide.eq(index).prepend('<div class="lg-video-cont lg-has-iframe" style="max-width:' + _this.s.iframeMaxWidth + '"><div class="lg-video"><iframe class="lg-object" frameborder="0" src="' + _src + '"  allowfullscreen="true"></iframe></div></div>');
2805              } else if (_hasPoster) {
2806                  var videoClass = '';
2807                  if (_isVideo && _isVideo.youtube) {
2808                      videoClass = 'lg-has-youtube';
2809                  } else if (_isVideo && _isVideo.vimeo) {
2810                      videoClass = 'lg-has-vimeo';
2811                  } else {
2812                      videoClass = 'lg-has-html5';
2813                  }
2814  
2815                  _this.$slide.eq(index).prepend('<div class="lg-video-cont ' + videoClass + ' "><div class="lg-video"><span class="lg-video-play"></span><img class="lg-object lg-has-poster" src="' + _poster + '" /></div></div>');
2816  
2817              } else if (_isVideo) {
2818                  _this.$slide.eq(index).prepend('<div class="lg-video-cont "><div class="lg-video"></div></div>');
2819                  _this.$el.trigger('hasVideo.lg', [index, _src, _html]);
2820              } else {
2821                  _this.$slide.eq(index).prepend('<div class="lg-img-wrap"><img class="lg-object lg-image" src="' + _src + '" /></div>');
2822              }
2823  
2824              _this.$el.trigger('onAferAppendSlide.lg', [index]);
2825  
2826              _$img = _this.$slide.eq(index).find('.lg-object');
2827              if (_sizes) {
2828                  _$img.attr('sizes', _sizes);
2829              }
2830  
2831              if (_srcset) {
2832                  _$img.attr('srcset', _srcset);
2833                  try {
2834                      picturefill({
2835                          elements: [_$img[0]]
2836                      });
2837                  } catch (e) {
2838                      console.warn('lightGallery :- If you want srcset to be supported for older browser please include picturefil version 2 javascript library in your document.');
2839                  }
2840              }
2841  
2842              if (this.s.appendSubHtmlTo !== '.lg-sub-html') {
2843                  _this.addHtml(index);
2844              }
2845  
2846              _this.$slide.eq(index).addClass('lg-loaded');
2847          }
2848  
2849          _this.$slide.eq(index).find('.lg-object').on('load.lg error.lg', function() {
2850  
2851              // For first time add some delay for displaying the start animation.
2852              var _speed = 0;
2853  
2854              // Do not change the delay value because it is required for zoom plugin.
2855              // If gallery opened from direct url (hash) speed value should be 0
2856              if (delay && !$('body').hasClass('lg-from-hash')) {
2857                  _speed = delay;
2858              }
2859  
2860              setTimeout(function() {
2861                  _this.$slide.eq(index).addClass('lg-complete');
2862                  _this.$el.trigger('onSlideItemLoad.lg', [index, delay || 0]);
2863              }, _speed);
2864  
2865          });
2866  
2867          // @todo check load state for html5 videos
2868          if (_isVideo && _isVideo.html5 && !_hasPoster) {
2869              _this.$slide.eq(index).addClass('lg-complete');
2870          }
2871  
2872          if (rec === true) {
2873              if (!_this.$slide.eq(index).hasClass('lg-complete')) {
2874                  _this.$slide.eq(index).find('.lg-object').on('load.lg error.lg', function() {
2875                      _this.preload(index);
2876                  });
2877              } else {
2878                  _this.preload(index);
2879              }
2880          }
2881  
2882          //}
2883      };
2884  
2885      /**
2886      *   @desc slide function for lightgallery
2887          ** Slide() gets call on start
2888          ** ** Set lg.on true once slide() function gets called.
2889          ** Call loadContent() on slide() function inside setTimeout
2890          ** ** On first slide we do not want any animation like slide of fade
2891          ** ** So on first slide( if lg.on if false that is first slide) loadContent() should start loading immediately
2892          ** ** Else loadContent() should wait for the transition to complete.
2893          ** ** So set timeout s.speed + 50
2894      <=> ** loadContent() will load slide content in to the particular slide
2895          ** ** It has recursion (rec) parameter. if rec === true loadContent() will call preload() function.
2896          ** ** preload will execute only when the previous slide is fully loaded (images iframe)
2897          ** ** avoid simultaneous image load
2898      <=> ** Preload() will check for s.preload value and call loadContent() again accoring to preload value
2899          ** loadContent()  <====> Preload();
2900  
2901      *   @param {Number} index - index of the slide
2902      *   @param {Boolean} fromTouch - true if slide function called via touch event or mouse drag
2903      *   @param {Boolean} fromThumb - true if slide function called via thumbnail click
2904      *   @param {String} direction - Direction of the slide(next/prev)
2905      */
2906      Plugin.prototype.slide = function(index, fromTouch, fromThumb, direction) {
2907  
2908          var _prevIndex = this.$outer.find('.lg-current').index();
2909          var _this = this;
2910  
2911          // Prevent if multiple call
2912          // Required for hsh plugin
2913          if (_this.lGalleryOn && (_prevIndex === index)) {
2914              return;
2915          }
2916  
2917          var _length = this.$slide.length;
2918          var _time = _this.lGalleryOn ? this.s.speed : 0;
2919  
2920          if (!_this.lgBusy) {
2921  
2922              if (this.s.download) {
2923                  var _src;
2924                  if (_this.s.dynamic) {
2925                      _src = _this.s.dynamicEl[index].downloadUrl !== false && (_this.s.dynamicEl[index].downloadUrl || _this.s.dynamicEl[index].src);
2926                  } else {
2927                      _src = _this.$items.eq(index).attr('data-download-url') !== 'false' && (_this.$items.eq(index).attr('data-download-url') || _this.$items.eq(index).attr('href') || _this.$items.eq(index).attr('data-src'));
2928  
2929                  }
2930  
2931                  if (_src) {
2932                      $('#lg-download').attr('href', _src);
2933                      _this.$outer.removeClass('lg-hide-download');
2934                  } else {
2935                      _this.$outer.addClass('lg-hide-download');
2936                  }
2937              }
2938  
2939              this.$el.trigger('onBeforeSlide.lg', [_prevIndex, index, fromTouch, fromThumb]);
2940  
2941              _this.lgBusy = true;
2942  
2943              clearTimeout(_this.hideBartimeout);
2944  
2945              // Add title if this.s.appendSubHtmlTo === lg-sub-html
2946              if (this.s.appendSubHtmlTo === '.lg-sub-html') {
2947  
2948                  // wait for slide animation to complete
2949                  setTimeout(function() {
2950                      _this.addHtml(index);
2951                  }, _time);
2952              }
2953  
2954              this.arrowDisable(index);
2955  
2956              if (!direction) {
2957                  if (index < _prevIndex) {
2958                      direction = 'prev';
2959                  } else if (index > _prevIndex) {
2960                      direction = 'next';
2961                  }
2962              }
2963  
2964              if (!fromTouch) {
2965  
2966                  // remove all transitions
2967                  _this.$outer.addClass('lg-no-trans');
2968  
2969                  this.$slide.removeClass('lg-prev-slide lg-next-slide');
2970  
2971                  if (direction === 'prev') {
2972  
2973                      //prevslide
2974                      this.$slide.eq(index).addClass('lg-prev-slide');
2975                      this.$slide.eq(_prevIndex).addClass('lg-next-slide');
2976                  } else {
2977  
2978                      // next slide
2979                      this.$slide.eq(index).addClass('lg-next-slide');
2980                      this.$slide.eq(_prevIndex).addClass('lg-prev-slide');
2981                  }
2982  
2983                  // give 50 ms for browser to add/remove class
2984                  setTimeout(function() {
2985                      _this.$slide.removeClass('lg-current');
2986  
2987                      //_this.$slide.eq(_prevIndex).removeClass('lg-current');
2988                      _this.$slide.eq(index).addClass('lg-current');
2989  
2990                      // reset all transitions
2991                      _this.$outer.removeClass('lg-no-trans');
2992                  }, 50);
2993              } else {
2994  
2995                  this.$slide.removeClass('lg-prev-slide lg-current lg-next-slide');
2996                  var touchPrev;
2997                  var touchNext;
2998                  if (_length > 2) {
2999                      touchPrev = index - 1;
3000                      touchNext = index + 1;
3001  
3002                      if ((index === 0) && (_prevIndex === _length - 1)) {
3003  
3004                          // next slide
3005                          touchNext = 0;
3006                          touchPrev = _length - 1;
3007                      } else if ((index === _length - 1) && (_prevIndex === 0)) {
3008  
3009                          // prev slide
3010                          touchNext = 0;
3011                          touchPrev = _length - 1;
3012                      }
3013  
3014                  } else {
3015                      touchPrev = 0;
3016                      touchNext = 1;
3017                  }
3018  
3019                  if (direction === 'prev') {
3020                      _this.$slide.eq(touchNext).addClass('lg-next-slide');
3021                  } else {
3022                      _this.$slide.eq(touchPrev).addClass('lg-prev-slide');
3023                  }
3024  
3025                  _this.$slide.eq(index).addClass('lg-current');
3026              }
3027  
3028              if (_this.lGalleryOn) {
3029                  setTimeout(function() {
3030                      _this.loadContent(index, true, 0);
3031                  }, this.s.speed + 50);
3032  
3033                  setTimeout(function() {
3034                      _this.lgBusy = false;
3035                      _this.$el.trigger('onAfterSlide.lg', [_prevIndex, index, fromTouch, fromThumb]);
3036                  }, this.s.speed);
3037  
3038              } else {
3039                  _this.loadContent(index, true, _this.s.backdropDuration);
3040  
3041                  _this.lgBusy = false;
3042                  _this.$el.trigger('onAfterSlide.lg', [_prevIndex, index, fromTouch, fromThumb]);
3043              }
3044  
3045              _this.lGalleryOn = true;
3046  
3047              if (this.s.counter) {
3048                  $('#lg-counter-current').text(index + 1);
3049              }
3050  
3051          }
3052  
3053      };
3054  
3055      /**
3056       *  @desc Go to next slide
3057       *  @param {Boolean} fromTouch - true if slide function called via touch event
3058       */
3059      Plugin.prototype.goToNextSlide = function(fromTouch) {
3060          var _this = this;
3061          var _loop = _this.s.loop;
3062          if (fromTouch && _this.$slide.length < 3) {
3063              _loop = false;
3064          }
3065  
3066          if (!_this.lgBusy) {
3067              if ((_this.index + 1) < _this.$slide.length) {
3068                  _this.index++;
3069                  _this.$el.trigger('onBeforeNextSlide.lg', [_this.index]);
3070                  _this.slide(_this.index, fromTouch, false, 'next');
3071              } else {
3072                  if (_loop) {
3073                      _this.index = 0;
3074                      _this.$el.trigger('onBeforeNextSlide.lg', [_this.index]);
3075                      _this.slide(_this.index, fromTouch, false, 'next');
3076                  } else if (_this.s.slideEndAnimatoin && !fromTouch) {
3077                      _this.$outer.addClass('lg-right-end');
3078                      setTimeout(function() {
3079                          _this.$outer.removeClass('lg-right-end');
3080                      }, 400);
3081                  }
3082              }
3083          }
3084      };
3085  
3086      /**
3087       *  @desc Go to previous slide
3088       *  @param {Boolean} fromTouch - true if slide function called via touch event
3089       */
3090      Plugin.prototype.goToPrevSlide = function(fromTouch) {
3091          var _this = this;
3092          var _loop = _this.s.loop;
3093          if (fromTouch && _this.$slide.length < 3) {
3094              _loop = false;
3095          }
3096  
3097          if (!_this.lgBusy) {
3098              if (_this.index > 0) {
3099                  _this.index--;
3100                  _this.$el.trigger('onBeforePrevSlide.lg', [_this.index, fromTouch]);
3101                  _this.slide(_this.index, fromTouch, false, 'prev');
3102              } else {
3103                  if (_loop) {
3104                      _this.index = _this.$items.length - 1;
3105                      _this.$el.trigger('onBeforePrevSlide.lg', [_this.index, fromTouch]);
3106                      _this.slide(_this.index, fromTouch, false, 'prev');
3107                  } else if (_this.s.slideEndAnimatoin && !fromTouch) {
3108                      _this.$outer.addClass('lg-left-end');
3109                      setTimeout(function() {
3110                          _this.$outer.removeClass('lg-left-end');
3111                      }, 400);
3112                  }
3113              }
3114          }
3115      };
3116  
3117      Plugin.prototype.keyPress = function() {
3118          var _this = this;
3119          if (this.$items.length > 1) {
3120              $(window).on('keyup.lg', function(e) {
3121                  if (_this.$items.length > 1) {
3122                      if (e.keyCode === 37) {
3123                          e.preventDefault();
3124                          _this.goToPrevSlide();
3125                      }
3126  
3127                      if (e.keyCode === 39) {
3128                          e.preventDefault();
3129                          _this.goToNextSlide();
3130                      }
3131                  }
3132              });
3133          }
3134  
3135          $(window).on('keydown.lg', function(e) {
3136              if (_this.s.escKey === true && e.keyCode === 27) {
3137                  e.preventDefault();
3138                  if (!_this.$outer.hasClass('lg-thumb-open')) {
3139                      _this.destroy();
3140                  } else {
3141                      _this.$outer.removeClass('lg-thumb-open');
3142                  }
3143              }
3144          });
3145      };
3146  
3147      Plugin.prototype.arrow = function() {
3148          var _this = this;
3149          this.$outer.find('.lg-prev').on('click.lg', function() {
3150              _this.goToPrevSlide();
3151          });
3152  
3153          this.$outer.find('.lg-next').on('click.lg', function() {
3154              _this.goToNextSlide();
3155          });
3156      };
3157  
3158      Plugin.prototype.arrowDisable = function(index) {
3159  
3160          // Disable arrows if s.hideControlOnEnd is true
3161          if (!this.s.loop && this.s.hideControlOnEnd) {
3162              if ((index + 1) < this.$slide.length) {
3163                  this.$outer.find('.lg-next').removeAttr('disabled').removeClass('disabled');
3164              } else {
3165                  this.$outer.find('.lg-next').attr('disabled', 'disabled').addClass('disabled');
3166              }
3167  
3168              if (index > 0) {
3169                  this.$outer.find('.lg-prev').removeAttr('disabled').removeClass('disabled');
3170              } else {
3171                  this.$outer.find('.lg-prev').attr('disabled', 'disabled').addClass('disabled');
3172              }
3173          }
3174      };
3175  
3176      Plugin.prototype.setTranslate = function($el, xValue, yValue) {
3177          // jQuery supports Automatic CSS prefixing since jQuery 1.8.0
3178          if (this.s.useLeft) {
3179              $el.css('left', xValue);
3180          } else {
3181              $el.css({
3182                  transform: 'translate3d(' + (xValue) + 'px, ' + yValue + 'px, 0px)'
3183              });
3184          }
3185      };
3186  
3187      Plugin.prototype.touchMove = function(startCoords, endCoords) {
3188  
3189          var distance = endCoords - startCoords;
3190  
3191          if (Math.abs(distance) > 15) {
3192              // reset opacity and transition duration
3193              this.$outer.addClass('lg-dragging');
3194  
3195              // move current slide
3196              this.setTranslate(this.$slide.eq(this.index), distance, 0);
3197  
3198              // move next and prev slide with current slide
3199              this.setTranslate($('.lg-prev-slide'), -this.$slide.eq(this.index).width() + distance, 0);
3200              this.setTranslate($('.lg-next-slide'), this.$slide.eq(this.index).width() + distance, 0);
3201          }
3202      };
3203  
3204      Plugin.prototype.touchEnd = function(distance) {
3205          var _this = this;
3206  
3207          // keep slide animation for any mode while dragg/swipe
3208          if (_this.s.mode !== 'lg-slide') {
3209              _this.$outer.addClass('lg-slide');
3210          }
3211  
3212          this.$slide.not('.lg-current, .lg-prev-slide, .lg-next-slide').css('opacity', '0');
3213  
3214          // set transition duration
3215          setTimeout(function() {
3216              _this.$outer.removeClass('lg-dragging');
3217              if ((distance < 0) && (Math.abs(distance) > _this.s.swipeThreshold)) {
3218                  _this.goToNextSlide(true);
3219              } else if ((distance > 0) && (Math.abs(distance) > _this.s.swipeThreshold)) {
3220                  _this.goToPrevSlide(true);
3221              } else if (Math.abs(distance) < 5) {
3222  
3223                  // Trigger click if distance is less than 5 pix
3224                  _this.$el.trigger('onSlideClick.lg');
3225              }
3226  
3227              _this.$slide.removeAttr('style');
3228          });
3229  
3230          // remove slide class once drag/swipe is completed if mode is not slide
3231          setTimeout(function() {
3232              if (!_this.$outer.hasClass('lg-dragging') && _this.s.mode !== 'lg-slide') {
3233                  _this.$outer.removeClass('lg-slide');
3234              }
3235          }, _this.s.speed + 100);
3236  
3237      };
3238  
3239      Plugin.prototype.enableSwipe = function() {
3240          var _this = this;
3241          var startCoords = 0;
3242          var endCoords = 0;
3243          var isMoved = false;
3244  
3245          if (_this.s.enableSwipe && _this.doCss()) {
3246  
3247              _this.$slide.on('touchstart.lg', function(e) {
3248                  if (!_this.$outer.hasClass('lg-zoomed') && !_this.lgBusy) {
3249                      e.preventDefault();
3250                      _this.manageSwipeClass();
3251                      startCoords = e.originalEvent.targetTouches[0].pageX;
3252                  }
3253              });
3254  
3255              _this.$slide.on('touchmove.lg', function(e) {
3256                  if (!_this.$outer.hasClass('lg-zoomed')) {
3257                      e.preventDefault();
3258                      endCoords = e.originalEvent.targetTouches[0].pageX;
3259                      _this.touchMove(startCoords, endCoords);
3260                      isMoved = true;
3261                  }
3262              });
3263  
3264              _this.$slide.on('touchend.lg', function() {
3265                  if (!_this.$outer.hasClass('lg-zoomed')) {
3266                      if (isMoved) {
3267                          isMoved = false;
3268                          _this.touchEnd(endCoords - startCoords);
3269                      } else {
3270                          _this.$el.trigger('onSlideClick.lg');
3271                      }
3272                  }
3273              });
3274          }
3275  
3276      };
3277  
3278      Plugin.prototype.enableDrag = function() {
3279          var _this = this;
3280          var startCoords = 0;
3281          var endCoords = 0;
3282          var isDraging = false;
3283          var isMoved = false;
3284          if (_this.s.enableDrag && _this.doCss()) {
3285              _this.$slide.on('mousedown.lg', function(e) {
3286                  // execute only on .lg-object
3287                  if (!_this.$outer.hasClass('lg-zoomed')) {
3288                      if ($(e.target).hasClass('lg-object') || $(e.target).hasClass('lg-video-play')) {
3289                          e.preventDefault();
3290  
3291                          if (!_this.lgBusy) {
3292                              _this.manageSwipeClass();
3293                              startCoords = e.pageX;
3294                              isDraging = true;
3295  
3296                              // ** Fix for webkit cursor issue https://code.google.com/p/chromium/issues/detail?id=26723
3297                              _this.$outer.scrollLeft += 1;
3298                              _this.$outer.scrollLeft -= 1;
3299  
3300                              // *
3301  
3302                              _this.$outer.removeClass('lg-grab').addClass('lg-grabbing');
3303  
3304                              _this.$el.trigger('onDragstart.lg');
3305                          }
3306  
3307                      }
3308                  }
3309              });
3310  
3311              $(window).on('mousemove.lg', function(e) {
3312                  if (isDraging) {
3313                      isMoved = true;
3314                      endCoords = e.pageX;
3315                      _this.touchMove(startCoords, endCoords);
3316                      _this.$el.trigger('onDragmove.lg');
3317                  }
3318              });
3319  
3320              $(window).on('mouseup.lg', function(e) {
3321                  if (isMoved) {
3322                      isMoved = false;
3323                      _this.touchEnd(endCoords - startCoords);
3324                      _this.$el.trigger('onDragend.lg');
3325                  } else if ($(e.target).hasClass('lg-object') || $(e.target).hasClass('lg-video-play')) {
3326                      _this.$el.trigger('onSlideClick.lg');
3327                  }
3328  
3329                  // Prevent execution on click
3330                  if (isDraging) {
3331                      isDraging = false;
3332                      _this.$outer.removeClass('lg-grabbing').addClass('lg-grab');
3333                  }
3334              });
3335  
3336          }
3337      };
3338  
3339      Plugin.prototype.manageSwipeClass = function() {
3340          var _touchNext = this.index + 1;
3341          var _touchPrev = this.index - 1;
3342          if (this.s.loop && this.$slide.length > 2) {
3343              if (this.index === 0) {
3344                  _touchPrev = this.$slide.length - 1;
3345              } else if (this.index === this.$slide.length - 1) {
3346                  _touchNext = 0;
3347              }
3348          }
3349  
3350          this.$slide.removeClass('lg-next-slide lg-prev-slide');
3351          if (_touchPrev > -1) {
3352              this.$slide.eq(_touchPrev).addClass('lg-prev-slide');
3353          }
3354  
3355          this.$slide.eq(_touchNext).addClass('lg-next-slide');
3356      };
3357  
3358      Plugin.prototype.mousewheel = function() {
3359          var _this = this;
3360          _this.$outer.on('mousewheel.lg', function(e) {
3361  
3362              if (!e.deltaY) {
3363                  return;
3364              }
3365  
3366              if (e.deltaY > 0) {
3367                  _this.goToPrevSlide();
3368              } else {
3369                  _this.goToNextSlide();
3370              }
3371  
3372              e.preventDefault();
3373          });
3374  
3375      };
3376  
3377      Plugin.prototype.closeGallery = function() {
3378  
3379          var _this = this;
3380          var mousedown = false;
3381          this.$outer.find('.lg-close').on('click.lg', function() {
3382              _this.destroy();
3383          });
3384  
3385          if (_this.s.closable) {
3386  
3387              // If you drag the slide and release outside gallery gets close on chrome
3388              // for preventing this check mousedown and mouseup happened on .lg-item or lg-outer
3389              _this.$outer.on('mousedown.lg', function(e) {
3390  
3391                  if ($(e.target).is('.lg-outer') || $(e.target).is('.lg-item ') || $(e.target).is('.lg-img-wrap')) {
3392                      mousedown = true;
3393                  } else {
3394                      mousedown = false;
3395                  }
3396  
3397              });
3398  
3399              _this.$outer.on('mouseup.lg', function(e) {
3400  
3401                  if ($(e.target).is('.lg-outer') || $(e.target).is('.lg-item ') || $(e.target).is('.lg-img-wrap') && mousedown) {
3402                      if (!_this.$outer.hasClass('lg-dragging')) {
3403                          _this.destroy();
3404                      }
3405                  }
3406  
3407              });
3408  
3409          }
3410  
3411      };
3412  
3413      Plugin.prototype.destroy = function(d) {
3414  
3415          var _this = this;
3416  
3417          if (!d) {
3418              _this.$el.trigger('onBeforeClose.lg');
3419              $(window).scrollTop(_this.prevScrollTop);
3420          }
3421  
3422  
3423          /**
3424           * if d is false or undefined destroy will only close the gallery
3425           * plugins instance remains with the element
3426           *
3427           * if d is true destroy will completely remove the plugin
3428           */
3429  
3430          if (d) {
3431              if (!_this.s.dynamic) {
3432                  // only when not using dynamic mode is $items a jquery collection
3433                  this.$items.off('click.lg click.lgcustom');
3434              }
3435  
3436              $.removeData(_this.el, 'lightGallery');
3437          }
3438  
3439          // Unbind all events added by lightGallery
3440          this.$el.off('.lg.tm');
3441  
3442          // Distroy all lightGallery modules
3443          $.each($.fn.lightGallery.modules, function(key) {
3444              if (_this.modules[key]) {
3445                  _this.modules[key].destroy();
3446              }
3447          });
3448  
3449          this.lGalleryOn = false;
3450  
3451          clearTimeout(_this.hideBartimeout);
3452          this.hideBartimeout = false;
3453          $(window).off('.lg');
3454          $('body').removeClass('lg-on lg-from-hash');
3455  
3456          if (_this.$outer) {
3457              _this.$outer.removeClass('lg-visible');
3458          }
3459  
3460          $('.lg-backdrop').removeClass('in');
3461  
3462          setTimeout(function() {
3463              if (_this.$outer) {
3464                  _this.$outer.remove();
3465              }
3466  
3467              $('.lg-backdrop').remove();
3468  
3469              if (!d) {
3470                  _this.$el.trigger('onCloseAfter.lg');
3471              }
3472  
3473          }, _this.s.backdropDuration + 50);
3474      };
3475  
3476      $.fn.lightGallery = function(options) {
3477          return this.each(function() {
3478              if (!$.data(this, 'lightGallery')) {
3479                  $.data(this, 'lightGallery', new Plugin(this, options));
3480              } else {
3481                  try {
3482                      $(this).data('lightGallery').init();
3483                  } catch (err) {
3484                      console.error('lightGallery has not initiated properly');
3485                  }
3486              }
3487          });
3488      };
3489  
3490      $.fn.lightGallery.modules = {};
3491  
3492  })();
3493  
3494  
3495  }));
3496/*! nouislider - 14.6.3 - 11/19/2020 */
3497!function(t){"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?module.exports=t():window.noUiSlider=t()}(function(){"use strict";var lt="14.6.3";function ut(t){t.parentElement.removeChild(t)}function a(t){return null!=t}function ct(t){t.preventDefault()}function o(t){return"number"==typeof t&&!isNaN(t)&&isFinite(t)}function pt(t,e,r){0<r&&(ht(t,e),setTimeout(function(){mt(t,e)},r))}function ft(t){return Math.max(Math.min(t,100),0)}function dt(t){return Array.isArray(t)?t:[t]}function e(t){var e=(t=String(t)).split(".");return 1<e.length?e[1].length:0}function ht(t,e){t.classList&&!/\s/.test(e)?t.classList.add(e):t.className+=" "+e}function mt(t,e){t.classList&&!/\s/.test(e)?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\b)"+e.split(" ").join("|")+"(\\b|$)","gi")," ")}function gt(t){var e=void 0!==window.pageXOffset,r="CSS1Compat"===(t.compatMode||"");return{x:e?window.pageXOffset:r?t.documentElement.scrollLeft:t.body.scrollLeft,y:e?window.pageYOffset:r?t.documentElement.scrollTop:t.body.scrollTop}}function c(t,e){return 100/(e-t)}function p(t,e,r){return 100*e/(t[r+1]-t[r])}function f(t,e){for(var r=1;t>=e[r];)r+=1;return r}function r(t,e,r){if(r>=t.slice(-1)[0])return 100;var n,i,o=f(r,t),s=t[o-1],a=t[o],l=e[o-1],u=e[o];return l+(i=r,p(n=[s,a],n[0]<0?i+Math.abs(n[0]):i-n[0],0)/c(l,u))}function n(t,e,r,n){if(100===n)return n;var i,o,s=f(n,t),a=t[s-1],l=t[s];return r?(l-a)/2<n-a?l:a:e[s-1]?t[s-1]+(i=n-t[s-1],o=e[s-1],Math.round(i/o)*o):n}function s(t,e,r){var n;if("number"==typeof e&&(e=[e]),!Array.isArray(e))throw new Error("noUiSlider ("+lt+"): 'range' contains invalid value.");if(!o(n="min"===t?0:"max"===t?100:parseFloat(t))||!o(e[0]))throw new Error("noUiSlider ("+lt+"): 'range' value isn't numeric.");r.xPct.push(n),r.xVal.push(e[0]),n?r.xSteps.push(!isNaN(e[1])&&e[1]):isNaN(e[1])||(r.xSteps[0]=e[1]),r.xHighestCompleteStep.push(0)}function l(t,e,r){if(e)if(r.xVal[t]!==r.xVal[t+1]){r.xSteps[t]=p([r.xVal[t],r.xVal[t+1]],e,0)/c(r.xPct[t],r.xPct[t+1]);var n=(r.xVal[t+1]-r.xVal[t])/r.xNumSteps[t],i=Math.ceil(Number(n.toFixed(3))-1),o=r.xVal[t]+r.xNumSteps[t]*i;r.xHighestCompleteStep[t]=o}else r.xSteps[t]=r.xHighestCompleteStep[t]=r.xVal[t]}function i(t,e,r){var n;this.xPct=[],this.xVal=[],this.xSteps=[r||!1],this.xNumSteps=[!1],this.xHighestCompleteStep=[],this.snap=e;var i=[];for(n in t)t.hasOwnProperty(n)&&i.push([t[n],n]);for(i.length&&"object"==typeof i[0][0]?i.sort(function(t,e){return t[0][0]-e[0][0]}):i.sort(function(t,e){return t[0]-e[0]}),n=0;n<i.length;n++)s(i[n][1],i[n][0],this);for(this.xNumSteps=this.xSteps.slice(0),n=0;n<this.xNumSteps.length;n++)l(n,this.xNumSteps[n],this)}i.prototype.getDistance=function(t){var e,r=[];for(e=0;e<this.xNumSteps.length-1;e++){var n=this.xNumSteps[e];if(n&&t/n%1!=0)throw new Error("noUiSlider ("+lt+"): 'limit', 'margin' and 'padding' of "+this.xPct[e]+"% range must be divisible by step.");r[e]=p(this.xVal,t,e)}return r},i.prototype.getAbsoluteDistance=function(t,e,r){var n,i=0;if(t<this.xPct[this.xPct.length-1])for(;t>this.xPct[i+1];)i++;else t===this.xPct[this.xPct.length-1]&&(i=this.xPct.length-2);r||t!==this.xPct[i+1]||i++;var o=1,s=e[i],a=0,l=0,u=0,c=0;for(n=r?(t-this.xPct[i])/(this.xPct[i+1]-this.xPct[i]):(this.xPct[i+1]-t)/(this.xPct[i+1]-this.xPct[i]);0<s;)a=this.xPct[i+1+c]-this.xPct[i+c],100<e[i+c]*o+100-100*n?(l=a*n,o=(s-100*n)/e[i+c],n=1):(l=e[i+c]*a/100*o,o=0),r?(u-=l,1<=this.xPct.length+c&&c--):(u+=l,1<=this.xPct.length-c&&c++),s=e[i+c]*o;return t+u},i.prototype.toStepping=function(t){return t=r(this.xVal,this.xPct,t)},i.prototype.fromStepping=function(t){return function(t,e,r){if(100<=r)return t.slice(-1)[0];var n,i=f(r,e),o=t[i-1],s=t[i],a=e[i-1],l=e[i];return n=[o,s],(r-a)*c(a,l)*(n[1]-n[0])/100+n[0]}(this.xVal,this.xPct,t)},i.prototype.getStep=function(t){return t=n(this.xPct,this.xSteps,this.snap,t)},i.prototype.getDefaultStep=function(t,e,r){var n=f(t,this.xPct);return(100===t||e&&t===this.xPct[n-1])&&(n=Math.max(n-1,1)),(this.xVal[n]-this.xVal[n-1])/r},i.prototype.getNearbySteps=function(t){var e=f(t,this.xPct);return{stepBefore:{startValue:this.xVal[e-2],step:this.xNumSteps[e-2],highestStep:this.xHighestCompleteStep[e-2]},thisStep:{startValue:this.xVal[e-1],step:this.xNumSteps[e-1],highestStep:this.xHighestCompleteStep[e-1]},stepAfter:{startValue:this.xVal[e],step:this.xNumSteps[e],highestStep:this.xHighestCompleteStep[e]}}},i.prototype.countStepDecimals=function(){var t=this.xNumSteps.map(e);return Math.max.apply(null,t)}
3497,i.prototype.convert=function(t){return this.getStep(this.toStepping(t))};var u={to:function(t){return void 0!==t&&t.toFixed(2)},from:Number},d={target:"target",base:"base",origin:"origin",handle:"handle",handleLower:"handle-lower",handleUpper:"handle-upper",touchArea:"touch-area",horizontal:"horizontal",vertical:"vertical",background:"background",connect:"connect",connects:"connects",ltr:"ltr",rtl:"rtl",textDirectionLtr:"txt-dir-ltr",textDirectionRtl:"txt-dir-rtl",draggable:"draggable",drag:"state-drag",tap:"state-tap",active:"active",tooltip:"tooltip",pips:"pips",pipsHorizontal:"pips-horizontal",pipsVertical:"pips-vertical",marker:"marker",markerHorizontal:"marker-horizontal",markerVertical:"marker-vertical",markerNormal:"marker-normal",markerLarge:"marker-large",markerSub:"marker-sub",value:"value",valueHorizontal:"value-horizontal",valueVertical:"value-vertical",valueNormal:"value-normal",valueLarge:"value-large",valueSub:"value-sub"},vt={tooltips:".__tooltips",aria:".__aria"};function h(t){if("object"==typeof(e=t)&&"function"==typeof e.to&&"function"==typeof e.from)return!0;var e;throw new Error("noUiSlider ("+lt+"): 'format' requires 'to' and 'from' methods.")}function m(t,e){if(!o(e))throw new Error("noUiSlider ("+lt+"): 'step' is not numeric.");t.singleStep=e}function g(t,e){if(!o(e))throw new Error("noUiSlider ("+lt+"): 'keyboardPageMultiplier' is not numeric.");t.keyboardPageMultiplier=e}function v(t,e){if(!o(e))throw new Error("noUiSlider ("+lt+"): 'keyboardDefaultStep' is not numeric.");t.keyboardDefaultStep=e}function b(t,e){if("object"!=typeof e||Array.isArray(e))throw new Error("noUiSlider ("+lt+"): 'range' is not an object.");if(void 0===e.min||void 0===e.max)throw new Error("noUiSlider ("+lt+"): Missing 'min' or 'max' in 'range'.");if(e.min===e.max)throw new Error("noUiSlider ("+lt+"): 'range' 'min' and 'max' cannot be equal.");t.spectrum=new i(e,t.snap,t.singleStep)}function x(t,e){if(e=dt(e),!Array.isArray(e)||!e.length)throw new Error("noUiSlider ("+lt+"): 'start' option is incorrect.");t.handles=e.length,t.start=e}function S(t,e){if("boolean"!=typeof(t.snap=e))throw new Error("noUiSlider ("+lt+"): 'snap' option must be a boolean.")}function w(t,e){if("boolean"!=typeof(t.animate=e))throw new Error("noUiSlider ("+lt+"): 'animate' option must be a boolean.")}function y(t,e){if("number"!=typeof(t.animationDuration=e))throw new Error("noUiSlider ("+lt+"): 'animationDuration' option must be a number.")}function E(t,e){var r,n=[!1];if("lower"===e?e=[!0,!1]:"upper"===e&&(e=[!1,!0]),!0===e||!1===e){for(r=1;r<t.handles;r++)n.push(e);n.push(!1)}else{if(!Array.isArray(e)||!e.length||e.length!==t.handles+1)throw new Error("noUiSlider ("+lt+"): 'connect' option doesn't match handle count.");n=e}t.connect=n}function C(t,e){switch(e){case"horizontal":t.ort=0;break;case"vertical":t.ort=1;break;default:throw new Error("noUiSlider ("+lt+"): 'orientation' option is invalid.")}}function P(t,e){if(!o(e))throw new Error("noUiSlider ("+lt+"): 'margin' option must be numeric.");0!==e&&(t.margin=t.spectrum.getDistance(e))}function N(t,e){if(!o(e))throw new Error("noUiSlider ("+lt+"): 'limit' option must be numeric.");if(t.limit=t.spectrum.getDistance(e),!t.limit||t.handles<2)throw new Error("noUiSlider ("+lt+"): 'limit' option is only supported on linear sliders with 2 or more handles.")}function k(t,e){var r;if(!o(e)&&!Array.isArray(e))throw new Error("noUiSlider ("+lt+"): 'padding' option must be numeric or array of exactly 2 numbers.");if(Array.isArray(e)&&2!==e.length&&!o(e[0])&&!o(e[1]))throw new Error("noUiSlider ("+lt+"): 'padding' option must be numeric or array of exactly 2 numbers.");if(0!==e){for(Array.isArray(e)||(e=[e,e]),t.padding=[t.spectrum.getDistance(e[0]),t.spectrum.getDistance(e[1])],r=0;r<t.spectrum.xNumSteps.length-1;r++)if(t.padding[0][r]<0||t.padding[1][r]<0)throw new Error("noUiSlider ("+lt+"): 'padding' option must be a positive number(s).");var n=e[0]+e[1],i=t.spectrum.xVal[0];if(1<n/(t.spectrum.xVal[t.spectrum.xVal.length-1]-i))throw new Error("noUiSlider ("+lt+"): 'padding' option must not exceed 100% of the range.")}}function U(t,e){switch(e){case"ltr":t.dir=0;break;case"rtl":t.dir=1;break;default:throw new Error("noUiSlider ("+lt+"): 'direction' option was not recognized.")}}function A(t,e){if("string"!=typeof e)throw new Error("noUiSlider ("+lt+"): 'behaviour' must be a string containing options.");var r=0<=e.indexOf("tap"),n=0<=e.indexOf("drag"),i=0<=e.indexOf("fixed"),o=0<=e.indexOf("snap"),s=0<=e.indexOf("hover"),a=0<=e.indexOf("unconstrained");if(i){if(2!==t.handles)throw new Error("noUiSlider ("+lt+"): 'fixed' behaviour must be used with 2 handles");P(t,t.start[1]-t.start[0])}if(a&&(t.margin||t.limit))throw new Error("noUiSlider ("+lt+"): 'unconstrained' behaviour cannot be used with margin or limit");t.events={tap:r||o,drag:n,fixed:i,snap:o,hover:s,unconstrained:a}}function V(t,e){if(!1!==e)if(!0===e){t.tooltips=[];for(var r=0;r<t.handles;r++)t.tooltips.push(!0)}else{if(t.tooltips=dt(e),t.tooltips.length!==t.handles)throw new Error("noUiSlider ("+lt+"): must pass a formatter for all handles.");t.tooltips.forEach(function(t){if("boolean"!=typeof t&&("object"!=typeof t||"function"!=typeof t.to))throw new Error("noUiSlider ("+lt+"): 'tooltips' must be passed a formatter or 'false'.")})}}function D(t,e){h(t.ariaFormat=e)}function M(t,e){h(t.format=e)}function O(t,e){if("boolean"!=typeof(t.keyboardSupport=e))throw new Error("noUiSlider ("+lt+"): 'keyboardSupport' option must be a boolean.")}function L(t,e){t.documentElement=e}function z(t,e){if("string"!=typeof e&&!1!==e)throw new Error("noUiSlider ("+lt+"): 'cssPrefix' must be a string or `false`.");t.cssPrefix=e}function H(t,e){if("object"!=typeof e)throw new Error("noUiSlider ("+lt+"): 'cssClasse
3497s' must be an object.");if("string"==typeof t.cssPrefix)for(var r in t.cssClasses={},e)e.hasOwnProperty(r)&&(t.cssClasses[r]=t.cssPrefix+e[r]);else t.cssClasses=e}function bt(e){var r={margin:0,limit:0,padding:0,animate:!0,animationDuration:300,ariaFormat:u,format:u},n={step:{r:!1,t:m},keyboardPageMultiplier:{r:!1,t:g},keyboardDefaultStep:{r:!1,t:v},start:{r:!0,t:x},connect:{r:!0,t:E},direction:{r:!0,t:U},snap:{r:!1,t:S},animate:{r:!1,t:w},animationDuration:{r:!1,t:y},range:{r:!0,t:b},orientation:{r:!1,t:C},margin:{r:!1,t:P},limit:{r:!1,t:N},padding:{r:!1,t:k},behaviour:{r:!0,t:A},ariaFormat:{r:!1,t:D},format:{r:!1,t:M},tooltips:{r:!1,t:V},keyboardSupport:{r:!0,t:O},documentElement:{r:!1,t:L},cssPrefix:{r:!0,t:z},cssClasses:{r:!0,t:H}},i={connect:!1,direction:"ltr",behaviour:"tap",orientation:"horizontal",keyboardSupport:!0,cssPrefix:"noUi-",cssClasses:d,keyboardPageMultiplier:5,keyboardDefaultStep:10};e.format&&!e.ariaFormat&&(e.ariaFormat=e.format),Object.keys(n).forEach(function(t){if(!a(e[t])&&void 0===i[t]){if(n[t].r)throw new Error("noUiSlider ("+lt+"): '"+t+"' is required.");return!0}n[t].t(r,a(e[t])?e[t]:i[t])}),r.pips=e.pips;var t=document.createElement("div"),o=void 0!==t.style.msTransform,s=void 0!==t.style.transform;r.transformRule=s?"transform":o?"msTransform":"webkitTransform";return r.style=[["left","top"],["right","bottom"]][r.dir][r.ort],r}function j(t,b,o){var l,u,s,c,i,a,e,p,f=window.navigator.pointerEnabled?{start:"pointerdown",move:"pointermove",end:"pointerup"}:window.navigator.msPointerEnabled?{start:"MSPointerDown",move:"MSPointerMove",end:"MSPointerUp"}:{start:"mousedown touchstart",move:"mousemove touchmove",end:"mouseup touchend"},d=window.CSS&&CSS.supports&&CSS.supports("touch-action","none")&&function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("test",null,e)}catch(t){}return t}(),h=t,y=b.spectrum,x=[],S=[],m=[],g=0,v={},w=t.ownerDocument,E=b.documentElement||w.documentElement,C=w.body,P=-1,N=0,k=1,U=2,A="rtl"===w.dir||1===b.ort?0:100;function V(t,e){var r=w.createElement("div");return e&&ht(r,e),t.appendChild(r),r}function D(t,e){var r=V(t,b.cssClasses.origin),n=V(r,b.cssClasses.handle);return V(n,b.cssClasses.touchArea),n.setAttribute("data-handle",e),b.keyboardSupport&&(n.setAttribute("tabindex","0"),n.addEventListener("keydown",function(t){return function(t,e){if(O()||L(e))return!1;var r=["Left","Right"],n=["Down","Up"],i=["PageDown","PageUp"],o=["Home","End"];b.dir&&!b.ort?r.reverse():b.ort&&!b.dir&&(n.reverse(),i.reverse());var s,a=t.key.replace("Arrow",""),l=a===i[0],u=a===i[1],c=a===n[0]||a===r[0]||l,p=a===n[1]||a===r[1]||u,f=a===o[0],d=a===o[1];if(!(c||p||f||d))return!0;if(t.preventDefault(),p||c){var h=b.keyboardPageMultiplier,m=c?0:1,g=at(e),v=g[m];if(null===v)return!1;!1===v&&(v=y.getDefaultStep(S[e],c,b.keyboardDefaultStep)),(u||l)&&(v*=h),v=Math.max(v,1e-7),v*=c?-1:1,s=x[e]+v}else s=d?b.spectrum.xVal[b.spectrum.xVal.length-1]:b.spectrum.xVal[0];return rt(e,y.toStepping(s),!0,!0),J("slide",e),J("update",e),J("change",e),J("set",e),!1}(t,e)})),n.setAttribute("role","slider"),n.setAttribute("aria-orientation",b.ort?"vertical":"horizontal"),0===e?ht(n,b.cssClasses.handleLower):e===b.handles-1&&ht(n,b.cssClasses.handleUpper),r}function M(t,e){return!!e&&V(t,b.cssClasses.connect)}function r(t,e){return!!b.tooltips[e]&&V(t.firstChild,b.cssClasses.tooltip)}function O(){return h.hasAttribute("disabled")}function L(t){return u[t].hasAttribute("disabled")}function z(){i&&(G("update"+vt.tooltips),i.forEach(function(t){t&&ut(t)}),i=null)}function H(){z(),i=u.map(r),$("update"+vt.tooltips,function(t,e,r){if(i[e]){var n=t[e];!0!==b.tooltips[e]&&(n=b.tooltips[e].to(r[e])),i[e].innerHTML=n}})}function j(e,i,o){var s=w.createElement("div"),a=[];a[N]=b.cssClasses.valueNormal,a[k]=b.cssClasses.valueLarge,a[U]=b.cssClasses.valueSub;var l=[];l[N]=b.cssClasses.markerNormal,l[k]=b.cssClasses.markerLarge,l[U]=b.cssClasses.markerSub;var u=[b.cssClasses.valueHorizontal,b.cssClasses.valueVertical],c=[b.cssClasses.markerHorizontal,b.cssClasses.markerVertical];
3497function p(t,e){var r=e===b.cssClasses.value,n=r?a:l;return e+" "+(r?u:c)[b.ort]+" "+n[t]}return ht(s,b.cssClasses.pips),ht(s,0===b.ort?b.cssClasses.pipsHorizontal:b.cssClasses.pipsVertical),Object.keys(e).forEach(function(t){!function(t,e,r){if((r=i?i(e,r):r)!==P){var n=V(s,!1);n.className=p(r,b.cssClasses.marker),n.style[b.style]=t+"%",N<r&&((n=V(s,!1)).className=p(r,b.cssClasses.value),n.setAttribute("data-value",e),n.style[b.style]=t+"%",n.innerHTML=o.to(e))}}(t,e[t][0],e[t][1])}),s}function F(){c&&(ut(c),c=null)}function R(t){F();var m,g,v,b,e,r,x,S,w,n=t.mode,i=t.density||1,o=t.filter||!1,s=function(t,e,r){if("range"===t||"steps"===t)return y.xVal;if("count"===t){if(e<2)throw new Error("noUiSlider ("+lt+"): 'values' (>= 2) required for mode 'count'.");var n=e-1,i=100/n;for(e=[];n--;)e[n]=n*i;e.push(100),t="positions"}return"positions"===t?e.map(function(t){return y.fromStepping(r?y.getStep(t):t)}):"values"===t?r?e.map(function(t){return y.fromStepping(y.getStep(y.toStepping(t)))}):e:void 0}(n,t.values||!1,t.stepped||!1),a=(m=i,g=n,v=s,b={},e=y.xVal[0],r=y.xVal[y.xVal.length-1],S=x=!1,w=0,(v=v.slice().sort(function(t,e){return t-e}).filter(function(t){return!this[t]&&(this[t]=!0)},{}))[0]!==e&&(v.unshift(e),x=!0),v[v.length-1]!==r&&(v.push(r),S=!0),v.forEach(function(t,e){var r,n,i,o,s,a,l,u,c,p,f=t,d=v[e+1],h="steps"===g;if(h&&(r=y.xNumSteps[e]),r||(r=d-f),!1!==f)for(void 0===d&&(d=f),r=Math.max(r,1e-7),n=f;n<=d;n=(n+r).toFixed(7)/1){for(u=(s=(o=y.toStepping(n))-w)/m,p=s/(c=Math.round(u)),i=1;i<=c;i+=1)b[(a=w+i*p).toFixed(5)]=[y.fromStepping(a),0];l=-1<v.indexOf(n)?k:h?U:N,!e&&x&&n!==d&&(l=0),n===d&&S||(b[o.toFixed(5)]=[n,l]),w=o}}),b),l=t.format||{to:Math.round};return c=h.appendChild(j(a,o,l))}function T(){var t=l.getBoundingClientRect(),e="offset"+["Width","Height"][b.ort];return 0===b.ort?t.width||l[e]:t.height||l[e]}function _(n,i,o,s){var e=function(t){return!!(t=function(t,e,r){var n,i,o=0===t.type.indexOf("touch"),s=0===t.type.indexOf("mouse"),a=0===t.type.indexOf("pointer");0===t.type.indexOf("MSPointer")&&(a=!0);if("mousedown"===t.type&&!t.buttons&&!t.touches)return!1;if(o){var l=function(t){return t.target===r||r.contains(t.target)||t.target.shadowRoot&&t.target.shadowRoot.contains(r)};if("touchstart"===t.type){var u=Array.prototype.filter.call(t.touches,l);if(1<u.length)return!1;n=u[0].pageX,i=u[0].pageY}else{var c=Array.prototype.find.call(t.changedTouches,l);if(!c)return!1;n=c.pageX,i=c.pageY}}e=e||gt(w),(s||a)&&(n=t.clientX+e.x,i=t.clientY+e.y);return t.pageOffset=e,t.points=[n,i],t.cursor=s||a,t}(t,s.pageOffset,s.target||i))&&(!(O()&&!s.doNotReject)&&(e=h,r=b.cssClasses.tap,!((e.classList?e.classList.contains(r):new RegExp("\\b"+r+"\\b").test(e.className))&&!s.doNotReject)&&(!(n===f.start&&void 0!==t.buttons&&1<t.buttons)&&((!s.hover||!t.buttons)&&(d||t.preventDefault(),t.calcPoint=t.points[b.ort],void o(t,s))))));var e,r},r=[];return n.split(" ").forEach(function(t){i.addEventListener(t,e,!!d&&{passive:!0}),r.push([t,e])}),r}function B(t){var e,r,n,i,o,s,a=100*(t-(e=l,r=b.ort,n=e.getBoundingClientRect(),i=e.ownerDocument,o=i.documentElement,s=gt(i),/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(s.x=0),r?n.top+s.y-o.clientTop:n.left+s.x-o.clientLeft))/T();return a=ft(a),b.dir?100-a:a}function q(t,e){"mouseout"===t.type&&"HTML"===t.target.nodeName&&null===t.relatedTarget&&Y(t,e)}function X(t,e){if(-1===navigator.appVersion.indexOf("MSIE 9")&&0===t.buttons&&0!==e.buttonsProperty)return Y(t,e);var r=(b.dir?-1:1)*(t.calcPoint-e.startCalcPoint);Z(0<r,100*r/e.baseSize,e.locations,e.handleNumbers)}function Y(t,e){e.handle&&(mt(e.handle,b.cssClasses.active),g-=1),e.listeners.forEach(function(t){E.removeEventListener(t[0],t[1])}),0===g&&(mt(h,b.cssClasses.drag),et(),t.cursor&&(C.style.cursor="",C.removeEventListener("selectstart",ct))),e.handleNumbers.forEach(function(t){J("change",t),J("set",t),J("end",t)})}function I(t,e){if(e.handleNumbers.some(L))return!1;var r;1===e.handleNumbers.length&&(r=u[e.handleNumbers[0]].children[0],g+=1,ht(r,b.cssClasses.active));t.stopPropagation();var n=[],i=_(f.move,E,X,{target:t.target,handle:r,listeners:n,startCalcPoint:t.calcPoint,baseSize:T(),pageOffset:t.pageOffset,handleNumbers:e.handleNumbers,buttonsProperty:t.buttons,locations:S.slice()}),o=_(f.end,E,Y,{target:t.target,handle:r,listeners:n,doNotReject:!0,handleNumbers:e.handleNumbers}),s=_("mouseout",E,q,{target:t.target,handle:r,listeners:n,doNotReject:!0,handleNumbers:e.handleNumbers});n.push.apply(n,i.concat(o,s)),t.cursor&&(C.style.cursor=getComputedStyle(t.target).cursor,1<u.length&&ht(h,b.cssClasse
3497s.drag),C.addEventListener("selectstart",ct,!1)),e.handleNumbers.forEach(function(t){J("start",t)})}function n(t){t.stopPropagation();var i,o,s,e=B(t.calcPoint),r=(i=e,s=!(o=100),u.forEach(function(t,e){if(!L(e)){var r=S[e],n=Math.abs(r-i);(n<o||n<=o&&r<i||100===n&&100===o)&&(s=e,o=n)}}),s);if(!1===r)return!1;b.events.snap||pt(h,b.cssClasses.tap,b.animationDuration),rt(r,e,!0,!0),et(),J("slide",r,!0),J("update",r,!0),J("change",r,!0),J("set",r,!0),b.events.snap&&I(t,{handleNumbers:[r]})}function W(t){var e=B(t.calcPoint),r=y.getStep(e),n=y.fromStepping(r);Object.keys(v).forEach(function(t){"hover"===t.split(".")[0]&&v[t].forEach(function(t){t.call(a,n)})})}function $(t,e){v[t]=v[t]||[],v[t].push(e),"update"===t.split(".")[0]&&u.forEach(function(t,e){J("update",e)})}function G(t){var i=t&&t.split(".")[0],o=i?t.substring(i.length):t;Object.keys(v).forEach(function(t){var e,r=t.split(".")[0],n=t.substring(r.length);i&&i!==r||o&&o!==n||((e=n)!==vt.aria&&e!==vt.tooltips||o===n)&&delete v[t]})}function J(r,n,i){Object.keys(v).forEach(function(t){var e=t.split(".")[0];r===e&&v[t].forEach(function(t){t.call(a,x.map(b.format.to),n,x.slice(),i||!1,S.slice(),a)})})}function K(t,e,r,n,i,o){var s;return 1<u.length&&!b.events.unconstrained&&(n&&0<e&&(s=y.getAbsoluteDistance(t[e-1],b.margin,0),r=Math.max(r,s)),i&&e<u.length-1&&(s=y.getAbsoluteDistance(t[e+1],b.margin,1),r=Math.min(r,s))),1<u.length&&b.limit&&(n&&0<e&&(s=y.getAbsoluteDistance(t[e-1],b.limit,0),r=Math.min(r,s)),i&&e<u.length-1&&(s=y.getAbsoluteDistance(t[e+1],b.limit,1),r=Math.max(r,s))),b.padding&&(0===e&&(s=y.getAbsoluteDistance(0,b.padding[0],0),r=Math.max(r,s)),e===u.length-1&&(s=y.getAbsoluteDistance(100,b.padding[1],1),r=Math.min(r,s))),!((r=ft(r=y.getStep(r)))===t[e]&&!o)&&r}function Q(t,e){var r=b.ort;return(r?e:t)+", "+(r?t:e)}function Z(t,n,r,e){var i=r.slice(),o=[!t,t],s=[t,!t];e=e.slice(),t&&e.reverse(),1<e.length?e.forEach(function(t,e){var r=K(i,t,i[t]+n,o[e],s[e],!1);!1===r?n=0:(n=r-i[t],i[t]=r)}):o=s=[!0];var a=!1;e.forEach(function(t,e){a=rt(t,r[t]+n,o[e],s[e])||a}),a&&e.forEach(function(t){J("update",t),J("slide",t)})}function tt(t,e){return b.dir?100-t-e:t}function et(){m.forEach(function(t){var e=50<S[t]?-1:1,r=3+(u.length+e*t);u[t].style.zIndex=r})}function rt(t,e,r,n,i){return i||(e=K(S,t,e,r,n,!1)),!1!==e&&(function(t,e){S[t]=e,x[t]=y.fromStepping(e);var r="translate("+Q(10*(tt(e,0)-A)+"%","0")+")";u[t].style[b.transformRule]=r,nt(t),nt(t+1)}(t,e),!0)}function nt(t){if(s[t]){var e=0,r=100;0!==t&&(e=S[t-1]),t!==s.length-1&&(r=S[t]);var n=r-e,i="translate("+Q(tt(e,n)+"%","0")+")",o="scale("+Q(n/100,"1")+")";s[t].style[b.transformRule]=i+" "+o}}function it(t,e){return null===t||!1===t||void 0===t?S[e]:("number"==typeof t&&(t=String(t)),t=b.format.from(t),!1===(t=y.toStepping(t))||isNaN(t)?S[e]:t)}function ot(t,e,r){var n=dt(t),i=void 0===S[0];e=void 0===e||!!e,b.animate&&!i&&pt(h,b.cssClasses.tap,b.animationDuration),m.forEach(function(t){rt(t,it(n[t],t),!0,!1,r)});for(var o=1===m.length?0:1;o<m.length;++o)m.forEach(function(t){rt(t,S[t],!0,!0,r)});et(),m.forEach(function(t){J("update",t),null!==n[t]&&e&&J("set",t)})}function st(){var t=x.map(b.format.to);return 1===t.length?t[0]:t}function at(t){var e=S[t],r=y.getNearbySteps(e),n=x[t],i=r.thisStep.step,o=null;if(b.snap)return[n-r.stepBefore.startValue||null,r.stepAfter.startValue-n||null];!1!==i&&n+i>r.stepAfter.startValue&&(i=r.stepAfter.startValue-n),o=n>r.thisStep.startValue?r.thisStep.step:!1!==r.stepBefore.step&&n-r.stepBefore.highestStep,100===e?i=null:0===e&&(o=null);var s=y.countStepDecimals();return null!==i&&!1!==i&&(i=Number(i.toFixed(s))),null!==o&&!1!==o&&(o=Number(o.toFixed(s))),[o,i]}return ht(e=h,b.cssClasses.target),0===b.dir?ht(e,b.cssClasses.ltr):ht(e,b.cssClasses.rtl),0===b.ort?ht(e,b.cssClasses.horizontal):ht(e,b.cssClasses.vertical),ht(e,"rtl"===getComputedStyle(e).direction?b.cssClasses.textDirectionRtl:b.cssClasses.textDirectionLtr),l=V(e,b.cssClasses.base),function(t,e){var r=V(e,b.cssClasses.connects);u=[],(s=[]).push(M(r,t[0]));for(var n=0;n<b.handles;n++)u.push(D(e,n)),m[n]=n,s.push(M(r,t[n+1]))}(b.connect,l),(p=b.events).fixed||u.forEach(function(t,e){_(f.start,t.children[0],I,{handleNumbers:[e]})}),p.tap&&_(f.start,l,n,{}),p.hover&&_(f.move,l,W,{hover:!0}
3497),p.drag&&s.forEach(function(t,e){if(!1!==t&&0!==e&&e!==s.length-1){var r=u[e-1],n=u[e],i=[t];ht(t,b.cssClasses.draggable),p.fixed&&(i.push(r.children[0]),i.push(n.children[0])),i.forEach(function(t){_(f.start,t,I,{handles:[r,n],handleNumbers:[e-1,e]})})}}),ot(b.start),b.pips&&R(b.pips),b.tooltips&&H(),G("update"+vt.aria),$("update"+vt.aria,function(t,e,s,r,a){m.forEach(function(t){var e=u[t],r=K(S,t,0,!0,!0,!0),n=K(S,t,100,!0,!0,!0),i=a[t],o=b.ariaFormat.to(s[t]);r=y.fromStepping(r).toFixed(1),n=y.fromStepping(n).toFixed(1),i=y.fromStepping(i).toFixed(1),e.children[0].setAttribute("aria-valuemin",r),e.children[0].setAttribute("aria-valuemax",n),e.children[0].setAttribute("aria-valuenow",i),e.children[0].setAttribute("aria-valuetext",o)})}),a={destroy:function(){for(var t in G(vt.aria),G(vt.tooltips),b.cssClasses)b.cssClasses.hasOwnProperty(t)&&mt(h,b.cssClasses[t]);for(;h.firstChild;)h.removeChild(h.firstChild);delete h.noUiSlider},steps:function(){return m.map(at)},on:$,off:G,get:st,set:ot,setHandle:function(t,e,r,n){if(!(0<=(t=Number(t))&&t<m.length))throw new Error("noUiSlider ("+lt+"): invalid handle number, got: "+t);rt(t,it(e,t),!0,!0,n),J("update",t),r&&J("set",t)},reset:function(t){ot(b.start,t)},__moveHandles:function(t,e,r){Z(t,e,S,r)},options:o,updateOptions:function(e,t){var r=st(),n=["margin","limit","padding","range","animate","snap","step","format","pips","tooltips"];n.forEach(function(t){void 0!==e[t]&&(o[t]=e[t])});var i=bt(o);n.forEach(function(t){void 0!==e[t]&&(b[t]=i[t])}),y=i.spectrum,b.margin=i.margin,b.limit=i.limit,b.padding=i.padding,b.pips?R(b.pips):F(),b.tooltips?H():z(),S=[],ot(e.start||r,t)},target:h,removePips:F,removeTooltips:z,getTooltips:function(){return i},getOrigins:function(){return u},pips:R}}return{__spectrum:i,version:lt,cssClasses:d,create:function(t,e){if(!t||!t.nodeName)throw new Error("noUiSlider ("+lt+"): create requires a single element, got: "+t);if(t.noUiSlider)throw new Error("noUiSlider ("+lt+"): Slider was already initialized.");var r=j(t,bt(e),e);return t.noUiSlider=r}}});
3498function supportsObjectFit () {
3499    const testElem = document.createElement('div').style;
3500    if ('object-fit' in testElem || '-o-object-fit' in testElem) {
3501        return true;
3502    }
3503    return false;
3504}
3505
3506if (!supportsObjectFit()) {
3507    const images = document.getElementsByClassName('object-fit-cover');
3508    const imagesLen = images.length;
3509    let curImg;
3510    let curImgSrc;
3511    let shimWrapper;
3512    let shimImg;
3513    let i = 0;
3514
3515    for (i; i < imagesLen; i++) {
3516        curImg = images[i];
3517        if ('currentSrc' in curImg) {
3518            curImgSrc = curImg.currentSrc;
3519            if (curImgSrc === '') {
3520                curImgSrc = curImg.src;
3521            }
3522        } else {
3523            curImgSrc = curImg.src;
3524        }
3525        shimWrapper = document.createElement('div');
3526        shimImg = document.createElement('img');
3527        shimWrapper.className = curImg.className;
3528        shimWrapper.style.backgroundImage = 'url(' + curImgSrc + ')';
3529        shimImg.src = curImgSrc;
3530        shimWrapper.appendChild(shimImg);
3531        curImg.parentNode.replaceChild(shimWrapper, curImg);
3532    }
3533}
3534
3535/*!
3536 * ScrollTrigger 3.5.1
3537 * https://greensock.com
3538 * 
3539 * @license Copyright 2020, GreenSock. All rights reserved.
3540 * Subject to the terms at https://greensock.com/standard-license or for Club GreenSock members, the agreement issued with that membership.
3541 * @author: Jack Doyle, [email protected]
3542 */
3543
3544!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).window=e.window||{})}(this,function(e){"use strict";function H(e){return e}function I(){return"undefined"!=typeof window}function J(){return Me||I()&&(Me=window.gsap)&&Me.registerPlugin&&Me}function K(e){return!!~i.indexOf(e)}function L(e,t){return~Fe.indexOf(e)&&Fe[Fe.indexOf(e)+1][t]}function M(t,e){var r=e.s,n=e.sc,o=h.indexOf(t),i=n===rt.sc?1:2;return~o||(o=h.push(t)-1),h[o+i]||(h[o+i]=L(t,r)||(K(t)?n:function(e){return arguments.length?t[r]=e:t[r]}))}function N(e){return L(e,"getBoundingClientRect")||(K(e)?function(){return ut.width=ke.innerWidth,ut.height=ke.innerHeight,ut}:function(){return nt(e)})}function Q(e,t){var r=t.s,n=t.d2,o=t.d,i=t.a;return(r="scroll"+n)&&(i=L(e,r))?i()-N(e)()[o]:K(e)?Math.max(_e[r],Oe[r])-(ke["inner"+n]||_e["client"+n]||Oe["client"+n]):e[r]-e["offset"+n]}function R(e,t){for(var r=0;r<p.length;r+=3)t&&!~t.indexOf(p[r+1])||e(p[r],p[r+1],p[r+2])}function S(e){return"string"==typeof e}function T(e){return"function"==typeof e}function U(e){return"number"==typeof e}function V(e){return"object"==typeof e}function W(e){return T(e)&&e()}function X(r,n){return function(){var e=W(r),t=W(n);return function(){W(e),W(t)}}}function qa(e){return ke.getComputedStyle(e)}function sa(e,t){for(var r in t)r in e||(e[r]=t[r]);return e}function ua(e,t){var r=t.d2;return e["offset"+r]||e["client"+r]||0}function wa(t,r,e,n){return e.split(",").forEach(function(e){return t(r,e,n)})}function xa(e,t,r){return e.addEventListener(t,r,{passive:!0})}function ya(e,t,r){return e.removeEventListener(t,r)}function Ca(e,t){if(S(e)){var r=e.indexOf("="),n=~r?(e.charAt(r-1)+1)*parseFloat(e.substr(r+1)):0;n&&(e.indexOf("%")>r&&(n*=t/100),e=e.substr(0,r-1)),e=n+(e in m?m[e]*t:~e.indexOf("%")?parseFloat(e)*t/100:parseFloat(e)||0)}return e}function Da(e,t,r,n,o,i,a){var s=o.startColor,l=o.endColor,c=o.fontSize,u=o.indent,f=o.fontWeight,d=Pe.createElement("div"),p=K(r)||"fixed"===L(r,"pinType"),g=-1!==e.indexOf("scroller"),h=p?Oe:r,v=-1!==e.indexOf("start"),b=v?s:l,m="border-color:"+b+";font-size:"+c+";color:"+b+";font-weight:"+f+";pointer-events:none;white-space:nowrap;font-family:sans-serif,Arial;z-index:1000;padding:4px 8px;border-width:0;border-style:solid;";return m+="position:"+(g&&p?"fixed;":"absolute;"),!g&&p||(m+=(n===rt?x:y)+":"+(i+parseFloat(u))+"px;"),a&&(m+="box-sizing:border-box;text-align:left;width:"+a.offsetWidth+"px;"),d._isStart=v,d.setAttribute("class","gsap-marker-"+e),d.style.cssText=m,d.innerText=t||0===t?e+"-"+t:e,h.insertBefore(d,h.children[0]),d._offset=d["offset"+n.op.d2],w(d,0,n,v),d}function Ha(){return l=l||s(B)}function Ia(){l||(l=s(B),De||_("scrollStart"),De=He())}function Ja(){return!Re&&a.restart(!0)}function Pa(e){var t,r=Me.ticker.frame,n=[],o=0;if(g!==r||Be){for(A();o<P.length;o+=4)(t=ke.matchMedia(P[o]).matches)!==P[o+3]&&((P[o+3]=t)?n.push(o):A(1,P[o])||T(P[o+2])&&P[o+2]());for(E(),o=0;o<n.length;o++)t=n[o],We=P[t],P[t+2]=P[t+1](e);
3544z(We=0,1),g=r,_("matchMedia")}}function Qa(){return ya(Z,"scrollEnd",Qa)||z(!0)}function ab(e,t,r,n){if(e.parentNode!==t){for(var o,i=F.length,a=t.style,s=e.style;i--;)a[o=F[i]]=r[o];a.position="absolute"===r.position?"absolute":"relative","inline"===r.display&&(a.display="inline-block"),s[y]=s[x]="auto",a.overflow="visible",a.boxSizing="border-box",a[Ke]=ua(e,tt)+et,a[je]=ua(e,rt)+et,a[Ze]=s[$e]=s.top=s[b]="0",ct(n),s[Ke]=s.maxWidth=r[Ke],s[je]=s.maxHeight=r[je],s[Ze]=r[Ze],e.parentNode.insertBefore(t,e),t.appendChild(e)}}function db(e){for(var t=D.length,r=e.style,n=[],o=0;o<t;o++)n.push(D[o],r[D[o]]);return n.t=e,n}function gb(e,t,r,n,o,i,a,s,l,c,u,f){if(T(e)&&(e=e(s)),S(e)&&"max"===e.substr(0,3)&&(e=f+("="===e.charAt(4)?Ca("0"+e.substr(3),r):0)),U(e))a&&w(a,r,n,!0);else{T(t)&&(t=t(s));var d,p,g,h=Ee(t)[0]||Oe,v=nt(h)||{},b=e.split(" ");v&&(v.left||v.top)||"none"!==qa(h).display||(g=h.style.display,h.style.display="block",v=nt(h),g?h.style.display=g:h.style.removeProperty("display")),d=Ca(b[0],v[n.d]),p=Ca(b[1]||"0",r),e=v[n.p]-l[n.p]-c+d+o-p,a&&w(a,p,n,r-p<20||a._isStart&&20<p),r-=r-p}if(i){var m=e+r,x=i._isStart;f="scroll"+n.d2,w(i,m,n,x&&20<m||!x&&(u?Math.max(Oe[f],_e[f]):i.parentNode[f])<=m+1),u&&(l=nt(a),u&&(i.style[n.op.p]=l[n.op.p]-n.op.m-i._offset+et))}return Math.round(e)}function ib(e,t,r,n){if(e.parentNode!==t){var o,i,a=e.style;if(t===Oe){for(o in e._stOrig=a.cssText,i=qa(e))+o||Y.test(o)||!i[o]||"string"!=typeof a[o]||"0"===o||(a[o]=i[o]);a.top=r,a.left=n}else a.cssText=e._stOrig;Me.core.getCache(e).uncache=1,t.appendChild(e)}}function jb(l,e){var c,u,f=M(l,e),d="_scroll"+e.p2;return l[d]=f,function getTween(e,t,r,n,o){var i=getTween.tween,a=t.onComplete,s={};return i&&i.kill(),c=Math.round(r),t[d]=e,(t.modifiers=s)[d]=function(e){return(e=Math.round(f()))!==c&&e!==u?(i.kill(),getTween.tween=0):e=r+n*i.ratio+o*i.ratio*i.ratio,u=c,c=Math.round(e)},t.onComplete=function(){getTween.tween=0,a&&a.call(i)},i=getTween.tween=Me.to(l,t)}}var Me,o,ke,Pe,_e,Oe,i,a,s,l,Ee,Le,Ie,c,Re,Ae,u,ze,f,d,p,Ne,qe,We,g,Be=1,Fe=[],h=[],He=Date.now,v=He(),De=0,Je=1,Qe=Math.abs,t="scrollLeft",r="scrollTop",b="left",x="right",y="bottom",Ke="width",je="height",Ve="Right",Xe="Left",Ue="Top",Ye="Bottom",Ze="padding",$e="margin",Ge="Width",n="Height",et="px",tt={s:t,p:b,p2:Xe,os:x,os2:Ve,d:Ke,d2:Ge,a:"x",sc:function sc(e){return arguments.length?ke.scrollTo(e,rt.sc()):ke.pageXOffset||Pe[t]||_e[t]||Oe[t]||0}},rt={s:r,p:"top",p2:Ue,os:y,os2:Ye,d:je,d2:n,a:"y",op:tt,sc:function sc(e){return arguments.length?ke.scrollTo(tt.sc(),e):ke.pageYOffset||Pe[r]||_e[r]||Oe[r]||0}},nt=function _getBounds(e,t){var r=t&&"matrix(1, 0, 0, 1, 0, 0)"!==qa(e)[u]&&Me.to(e,{x:0,y:0,xPercent:0,yPercent:0,rotation:0,rotationX:0,rotationY:0,scale:1,skewX:0,skewY:0}).progress(1),n=e.getBoundingClientRect();return r&&r.progress(0).kill(),n},ot={startColor:"green",endColor:"red",indent:0,fontSize:"16px",fontWeight:"normal"},it={toggleActions:"play",anticipatePin:0},m={top:0,left:0,center:.5,bottom:1,right:1},w=function _positionMarker(e,t,r,n){var o={display:"block"},i=r[n?"os2":"p2"],a=r[n?"p2":"os2"];e._isFlipped=n,o[r.a+"Percent"]=n?-100:0,o[r.a]=n?1:0,o["border"+i+Ge]=1,o["border"+a+Ge]=0,o[r.p]=t,Me.set(e,o)},at=[],st={},C={},k=[],P=[],_=function _dispatch(e){return C[e]&&C[e].map(function(e){return e()})||k},O=[],E=function _revertRecorded(e){for(var t=0;t<O.length;t+=4)e&&O[t+3]!==e||(O[t].style.cssText=O[t+1],O[t+2].uncache=1)},A=function _revertAll(e,t){var r;for(ze=0;ze<at.length;ze++)r=at[ze],t&&r.media!==t||(e?r.kill(1):(r.scroll.rec||(r.scroll.rec=r.scroll()),r.revert()));E(t),t||_("revert")},z=function _refreshAll(e,t){if(!De||e){var r=_("refreshInit");for(Ne&&Z.sort(),t||A(),ze=0;ze<at.length;ze++)at[ze].refresh();for(r.forEach(function(e){return e&&e.render&&e.render(-1)}),ze=at.length;ze--;)at[ze].scroll.rec=0;a.pause(),_("refresh")}else xa(Z,"scrollEnd",Qa)},q=0,lt=1,B=function _updateAll(){var e=at.length,t=He(),r=50<=t-v,n=e&&at[0].scroll();if(lt=n<q?-1:1,q=n,r&&(De&&!Ae&&200<t-De&&(De=0,_("scrollEnd")),Ie=v,v=t),lt<0){for(ze=e;ze--;)at[ze]&&at[ze].update(0,r);lt=1}else for(ze=0;ze<e;ze++)at[ze]&&at[ze].update(0,r);l=0},F=[b,"top",y,x,$e+Ye,$e+Ve,$e+Ue,$e+Xe,"display","flexShrink","float"],D=F.concat([Ke,je,"boxSizing","max"+Ge,"max"+n,"position",$e,Ze,Ze+Ue,Ze+Ve,Ze+Ye,Ze+Xe]),j=/([A-Z])/g,ct=function _setState(e){if(e)for(var t,r,n=e.t.style,o=e.length,i=0;i<o;i+=2)r=e[i+1],t=e[i],r?n[t]=r:n[t]&&n.removeProperty(t.replace(j,"-$
35441").toLowerCase())},ut={left:0,top:0},Y=/(?:webkit|moz|length|cssText)/i;tt.op=rt;var Z=(ScrollTrigger.prototype.init=function init(x,y){if(this.progress=0,this.vars&&this.kill(1),Je){var p,n,l,w,C,k,P,_,O,E,I,R,e,A,z,q,W,B,t,F,g,D,J,h,j,v,b,r,m,X,Y,o,c,Z,$,G,ee,te=(x=sa(S(x)||U(x)||x.nodeType?{trigger:x}:x,it)).horizontal?tt:rt,re=x.onUpdate,ne=x.toggleClass,i=x.id,oe=x.onToggle,ie=x.onRefresh,a=x.scrub,ae=x.trigger,se=x.pin,le=x.pinSpacing,ce=x.invalidateOnRefresh,ue=x.anticipatePin,s=x.onScrubComplete,u=x.onSnapComplete,fe=x.once,de=x.snap,pe=x.pinReparent,ge=!a&&0!==a,he=Ee(x.scroller||ke)[0],f=Me.core.getCache(he),ve=K(he),be="pinType"in x?"fixed"===x.pinType:ve||"fixed"===L(he,"pinType"),me=[x.onEnter,x.onLeave,x.onEnterBack,x.onLeaveBack],xe=ge&&x.toggleActions.split(" "),d="markers"in x?x.markers:it.markers,ye=ve?0:parseFloat(qa(he)["border"+te.p2+Ge])||0,Te=this,we=x.onRefreshInit&&function(){return x.onRefreshInit(Te)},Se=function _getSizeFunc(e,t,r){var n=r.d,o=r.d2,i=r.a;return(i=L(e,"getBoundingClientRect"))?function(){return i()[n]}:function(){return(t?ke["inner"+o]:e["client"+o])||0}}(he,ve,te),Ce=function _getOffsetsFunc(e,t){return!t||~Fe.indexOf(e)?N(e):function(){return ut}}(he,ve);Te.media=We,ue*=45,at.push(Te),Te.scroller=he,Te.scroll=M(he,te),C=Te.scroll(),Te.vars=x,y=y||x.animation,"refreshPriority"in x&&(Ne=1),f.tweenScroll=f.tweenScroll||{top:jb(he,rt),left:jb(he,tt)},Te.tweenTo=p=f.tweenScroll[te.p],y&&(y.vars.lazy=!1,y._initted||!1!==y.vars.immediateRender&&!1!==x.immediateRender&&y.render(0,!0,!0),Te.animation=y.pause(),y.scrollTrigger=Te,(o=U(a)&&a)&&(Y=Me.to(y,{ease:"power3",duration:o,onComplete:function onComplete(){return s&&s(Te)}})),m=0,i=i||y.vars.id),de&&(V(de)||(de={snapTo:de}),Me.set(ve?[Oe,_e]:he,{scrollBehavior:"auto"}),l=T(de.snapTo)?de.snapTo:"labels"===de.snapTo?function _getLabels(i){return function(e){var t,r=[],n=i.labels,o=i.duration();for(t in n)r.push(n[t]/o);return Me.utils.snap(r,e)}}(y):Me.utils.snap(de.snapTo),c=de.duration||{min:.1,max:2},c=V(c)?Le(c.min,c.max):Le(c,c),Z=Me.delayedCall(de.delay||o/2||.1,function(){if(Math.abs(Te.getVelocity())<10&&!Ae){var e=y&&!ge?y.totalProgress():Te.progress,t=(e-X)/(He()-Ie)*1e3||0,r=Qe(t/2)*t/.185,n=e+r,o=Le(0,1,l(n,Te)),i=Te.scroll(),a=Math.round(P+o*A),s=p.tween;if(i<=_&&P<=i&&a!==i){if(s&&!s._initted&&s.data<=Math.abs(a-i))return;p(a,{duration:c(Qe(.185*Math.max(Qe(n-e),Qe(o-e))/t/.05||0)),ease:de.ease||"power3",data:Math.abs(a-i),onComplete:function onComplete(){m=X=y&&!ge?y.totalProgress():Te.progress,u&&u(Te)}},i,r*A,a-i-r*A)}}else Te.isActive&&Z.restart(!0)}).pause()),i&&(st[i]=Te),ae=Te.trigger=Ee(ae||se)[0],se=!0===se?ae:Ee(se)[0],S(ne)&&(ne={targets:ae,className:ne}),se&&(!1===le||le===$e||(le=!(!le&&"flex"===qa(se.parentNode).display)&&Ze),Te.pin=se,!1!==x.force3D&&Me.set(se,{force3D:!0}),(n=Me.core.getCache(se)).spacer?z=n.pinState:(n.spacer=B=Pe.createElement("div"),B.setAttribute("class","pin-spacer"+(i?" pin-spacer-"+i:"")),n.pinState=z=db(se)),Te.spacer=B=n.spacer,r=qa(se),h=r[le+te.os2],F=Me.getProperty(se),g=Me.quickSetter(se,te.a,et),ab(se,B,r),W=db(se)),d&&(e=V(d)?sa(d,ot):ot,I=Da("scroller-start",i,he,te,e,0),R=Da("scroller-end",i,he,te,e,0,I),t=I["offset"+te.op.d2],O=Da("start",i,he,te,e,t),E=Da("end",i,he,te,e,t),be||(function _makePositionable(e){e.style.position="absolute"===qa(e).position?"absolute":"relative"}(he),Me.set([I,R],{force3D:!0}),v=Me.quickSetter(I,te.a,et),b=Me.quickSetter(R,te.a,et))),Te.revert=function(e){var t=!1!==e||!Te.enabled,r=Re;t!==w&&(t&&(G=Math.max(Te.scroll(),Te.scroll.rec||0),$=Te.progress,ee=y&&y.progress()),O&&[O,E,I,R].forEach(function(e){return e.style.display=t?"none":"block"}),t&&(Re=1),Te.update(t),Re=r,se&&(t?function _swapPinOut(e,t,r){if(ct(r),e.parentNode===t){var n=t.parentNode;n&&(n.insertBefore(e,t),n.removeChild(t))}}(se,B,z):pe&&Te.isActive||ab(se,B,qa(se),j)),w=t)},Te.refresh=function(e){if(!Re&&Te.enabled)if(se&&e&&De)xa(ScrollTrigger,"scrollEnd",Qa);else{Re=1,Y&&Y.kill(),ce&&y&&y.progress(0).invalidate(),w||Te.revert();for(var t,r,n,o,i,a,s,l,c=Se(),u=Ce(),f=Q(he,te),d=0,p=0,g=x.end,h=x.endTrigger||ae,v=x.start||(0===x.start?0:se||!ae?"0 0":"0 100%"),b=ae&&Math.max(0,at.indexOf(Te))||0,m=b;m--;)!(s=at[m].pin)||s!==ae&&s!==se||at[m].revert();for(P=gb(v,ae,c,te,Te.scroll(),O,I,Te,u,ye,be,f)||(se?-.001:0),T(g)&&(g=g(Te)),S(g)&&!g.indexOf("+=")&&(~g.indexOf(" ")?g=(S(v)?v.split(" ")[0]:"")+g:(d=Ca(g.substr(2),c),g=S(v)?v:P+d,h=ae)),_=Math.max(P,gb(g||(h?"100% 0":f),h,c,te,Te.scroll()+d,E,R,Te,u,ye,be,f))||-.001,A=_-P||(P-=.01)&&.001,d=0,m=b;m--;)(s=(a=at[m]).pin)&&a.start-a._pinPush<P&&(t=a.end-a.start,s===ae&&(d+=t),s===se&&(p+=t));if(P+=d,_+=d,Te._pinPush=p,O&&d&&((t={}
3544)[te.a]="+="+d,Me.set([O,E],t)),se)t=qa(se),o=te===rt,n=Te.scroll(),D=parseFloat(F(te.a))+p,!f&&1<_&&((ve?Oe:he).style["overflow-"+te.a]="scroll"),ab(se,B,t),W=db(se),r=nt(se,!0),l=be&&M(he,o?tt:rt)(),le&&((j=[le+te.os2,A+p+et]).t=B,(m=le===Ze?ua(se,te)+A+p:0)&&j.push(te.d,m+et),ct(j),be&&Te.scroll(G)),be&&((i={top:r.top+(o?n-P:l)+et,left:r.left+(o?l:n-P)+et,boxSizing:"border-box",position:"fixed"})[Ke]=i.maxWidth=Math.ceil(r.width)+et,i[je]=i.maxHeight=Math.ceil(r.height)+et,i[$e]=i[$e+Ue]=i[$e+Ve]=i[$e+Ye]=i[$e+Xe]="0",i[Ze]=t[Ze],i[Ze+Ue]=t[Ze+Ue],i[Ze+Ve]=t[Ze+Ve],i[Ze+Ye]=t[Ze+Ye],i[Ze+Xe]=t[Ze+Xe],q=function _copyState(e,t,r){for(var n,o=[],i=e.length,a=r?8:0;a<i;a+=2)n=e[a],o.push(n,n in t?t[n]:e[a+1]);return o.t=e.t,o}(z,i,pe)),y?(y.progress(1,!0),J=F(te.a)-D+A+p,A!==J&&q.splice(q.length-2,2),y.progress(0,!0)):J=A;else if(ae&&Te.scroll())for(r=ae.parentNode;r&&r!==Oe;)r._pinOffset&&(P-=r._pinOffset,_-=r._pinOffset),r=r.parentNode;for(m=0;m<b;m++)!(a=at[m].pin)||a!==ae&&a!==se||at[m].revert(!1);Te.start=P,Te.end=_,(C=k=Te.scroll())<G&&Te.scroll(G),Te.revert(!1),Re=0,ee&&ge&&y.progress(ee,!0),$!==Te.progress&&(Y&&y.totalProgress($,!0),Te.progress=$,Te.update()),se&&le&&(B._pinOffset=Math.round(Te.progress*J)),ie&&ie(Te)}},Te.getVelocity=function(){return(Te.scroll()-k)/(He()-Ie)*1e3||0},Te.update=function(e,t){var r,n,o,i,a,s=Te.scroll(),l=e?0:(s-P)/A,c=l<0?0:1<l?1:l||0,u=Te.progress;if(t&&(k=C,C=s,de&&(X=m,m=y&&!ge?y.totalProgress():c)),ue&&!c&&se&&!Re&&!Be&&De&&P<s+(s-k)/(He()-Ie)*ue&&(c=1e-4),c!==u&&Te.enabled){if(i=(a=(r=Te.isActive=!!c&&c<1)!=(!!u&&u<1))||!!c!=!!u,Te.direction=u<c?1:-1,Te.progress=c,ge||(!Y||Re||Be?y&&y.totalProgress(c,!!Re):(Y.vars.totalProgress=c,Y.invalidate().restart())),se)if(e&&le&&(B.style[le+te.os2]=h),be){if(i){if(o=!e&&u<c&&s<_+1&&s+1>=Q(he,te),pe)if(e||!r&&!o)ib(se,B);else{var f=nt(se,!0),d=s-P;ib(se,Oe,f.top+(te===rt?d:0)+et,f.left+(te===rt?0:d)+et)}ct(r||o?q:W),J!==A&&c<1&&r||g(D+(1!==c||o?0:J))}}else g(D+J*c);!de||p.tween||Re||Be||Z.restart(!0),ne&&(a||fe&&c&&(c<1||!qe))&&Ee(ne.targets).forEach(function(e){return e.classList[r||fe?"add":"remove"](ne.className)}),!re||ge||e||re(Te),i&&!Re?(n=c&&!u?0:1===c?1:1===u?2:3,ge&&(o=!a&&"none"!==xe[n+1]&&xe[n+1]||xe[n],y&&("complete"===o||"reset"===o||o in y)&&("complete"===o?y.pause().totalProgress(1):"reset"===o?y.restart(!0).pause():y[o]()),re&&re(Te)),!a&&qe||(oe&&a&&oe(Te),me[n]&&me[n](Te),fe&&(1===c?Te.kill(!1,1):me[n]=0),a||me[n=1===c?1:3]&&me[n](Te))):ge&&re&&!Re&&re(Te)}b&&(v(s+(I._isFlipped?1:0)),b(s))},Te.enable=function(){Te.enabled||(Te.enabled=!0,xa(he,"resize",Ja),xa(he,"scroll",Ia),we&&xa(ScrollTrigger,"refreshInit",we),y&&y.add?Me.delayedCall(.01,function(){return P||_||Te.refresh()})&&(A=.01)&&(P=_=0):Te.refresh())},Te.disable=function(e,t){if(Te.enabled&&(!1!==e&&Te.revert(),Te.enabled=Te.isActive=!1,t||Y&&Y.pause(),G=0,n&&(n.uncache=1),we&&ya(ScrollTrigger,"refreshInit",we),Z&&(Z.pause(),p.tween&&p.tween.kill()&&(p.tween=0)),!ve)){for(var r=at.length;r--;)if(at[r].scroller===he&&at[r]!==Te)return;ya(he,"resize",Ja),ya(he,"scroll",Ia)}},Te.kill=function(e,t){Te.disable(e,t),i&&delete st[i];var r=at.indexOf(Te);at.splice(r,1),r===ze&&0<lt&&ze--,y&&(y.scrollTrigger=null,e&&y.render(-1),t||y.kill()),O&&[O,E,I,R].forEach(function(e){return e.parentNode.removeChild(e)}),n&&(n.uncache=1)},Te.enable()}else this.update=this.refresh=this.kill=H},ScrollTrigger.register=function register(e){if(!o&&(Me=e||J(),I()&&window.document&&(ke=window,Pe=document,_e=Pe.documentElement,Oe=Pe.body),Me&&(Ee=Me.utils.toArray,Le=Me.utils.clamp,Me.core.globals("ScrollTrigger",ScrollTrigger),Oe))){s=ke.requestAnimationFrame||function(e){return setTimeout(e,16)},xa(ke,"mousewheel",Ia),i=[ke,Pe,_e,Oe],xa(Pe,"scroll",Ia);var t,r=Oe.style,n=r.borderTop;r.borderTop="1px solid #000",t=nt(Oe),rt.m=Math.round(t.top+rt.sc())||0,tt.m=Math.round(t.left+tt.sc())||0,n?r.borderTop=n:r.removeProperty("border-top"),c=setInterval(Ha,200),Me.delayedCall(.5,function(){return Be=0}),xa(Pe,"touchcancel",H),xa(Oe,"touchstart",H),wa(xa,Pe,"pointerdown,touchstart,mousedown",function(){return Ae=1}),wa(xa,Pe,"pointerup,touchend,mouseup",function(){return Ae=0}),u=Me.utils.checkPrefix("transform"),D.push(u),o=He(),a=Me.delayedCall(.2,z).pause(),p=[Pe,"visibilitychange",function(){var e=ke.innerWidth,t=ke.innerHe
3544ight;Pe.hidden?(f=e,d=t):f===e&&d===t||Ja()},Pe,"DOMContentLoaded",z,ke,"load",function(){return De||z()},ke,"resize",Ja],R(xa)}return o},ScrollTrigger.defaults=function defaults(e){for(var t in e)it[t]=e[t]},ScrollTrigger.kill=function kill(){Je=0,at.slice(0).forEach(function(e){return e.kill(1)})},ScrollTrigger.config=function config(e){"limitCallbacks"in e&&(qe=!!e.limitCallbacks);var t=e.syncInterval;t&&clearInterval(c)||(c=t)&&setInterval(Ha,t),"autoRefreshEvents"in e&&(R(ya)||R(xa,e.autoRefreshEvents||"none"))},ScrollTrigger.scrollerProxy=function scrollerProxy(e,t){var r=Ee(e)[0];K(r)?Fe.unshift(ke,t,Oe,t,_e,t):Fe.unshift(r,t)},ScrollTrigger.matchMedia=function matchMedia(e){var t,r,n,o,i;for(r in e)n=P.indexOf(r),o=e[r],"all"===(We=r)?o():(t=ke.matchMedia(r))&&(t.matches&&(i=o()),~n?(P[n+1]=X(P[n+1],o),P[n+2]=X(P[n+2],i)):(n=P.length,P.push(r,o,i),t.addListener?t.addListener(Pa):t.addEventListener("change",Pa)),P[n+3]=t.matches),We=0;return P},ScrollTrigger.clearMatchMedia=function clearMatchMedia(e){e||(P.length=0),0<=(e=P.indexOf(e))&&P.splice(e,4)},ScrollTrigger);function ScrollTrigger(e,t){o||ScrollTrigger.register(Me)||console.warn("Please gsap.registerPlugin(ScrollTrigger)"),this.init(e,t)}Z.version="3.5.1",Z.saveStyles=function(e){return e?Ee(e).forEach(function(e){var t=O.indexOf(e);0<=t&&O.splice(t,4),O.push(e,e.style.cssText,Me.core.getCache(e),We)}):O},Z.revert=function(e,t){return A(!e,t)},Z.create=function(e,t){return new Z(e,t)},Z.refresh=function(e){return e?Ja():z(!0)},Z.update=B,Z.maxScroll=function(e,t){return Q(e,t?tt:rt)},Z.getScrollFunc=function(e,t){return M(Ee(e)[0],t?tt:rt)},Z.getById=function(e){return st[e]},Z.getAll=function(){return at.slice(0)},Z.isScrolling=function(){return!!De},Z.addEventListener=function(e,t){var r=C[e]||(C[e]=[]);~r.indexOf(t)||r.push(t)},Z.removeEventListener=function(e,t){var r=C[e],n=r&&r.indexOf(t);0<=n&&r.splice(n,1)},Z.batch=function(e,t){function bi(e,t){var r=[],n=[],o=Me.delayedCall(i,function(){t(r,n),r=[],n=[]}).pause();return function(e){r.length||o.restart(!0),r.push(e.trigger),n.push(e),a<=r.length&&o.progress(1)}}var r,n=[],o={},i=t.interval||.016,a=t.batchMax||1e9;for(r in t)o[r]="on"===r.substr(0,2)&&T(t[r])&&"onRefreshInit"!==r?bi(0,t[r]):t[r];return T(a)&&(a=a(),xa(Z,"refresh",function(){return a=t.batchMax()})),Ee(e).forEach(function(e){var t={};for(r in o)t[r]=o[r];t.trigger=e,n.push(Z.create(t))}),n},Z.sort=function(e){return at.sort(e||function(e,t){return-1e6*(e.vars.refreshPriority||0)+e.start-(t.start+-1e6*(t.vars.refreshPriority||0))})},J()&&Me.registerPlugin(Z),e.ScrollTrigger=Z,e.default=Z;if (typeof(window)==="undefined"||window!==e){Object.defineProperty(e,"__esModule",{value:!0})} else {delete e.default}});
3545
3546
3547/**
3548 * Swiper 5.1.0
3549 * Most modern mobile touch slider and framework with hardware accelerated transitions
3550 * http://swiperjs.com
3551 *
3552 * Copyright 2014-2019 Vladimir Kharlampidi
3553 *
3554 * Released under the MIT License
3555 *
3556 * Released on: October 16, 2019
3557 */
3558
3559 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).Swiper=t()}(this,(function(){"use strict";var e="undefined"==typeof document?{body:{},addEventListener:function(){},removeEventListener:function(){},activeElement:{blur:function(){},nodeName:""},querySelector:function(){return null},querySelectorAll:function(){return[]},getElementById:function(){return null},createEvent:function(){return{initEvent:function(){}}},createElement:function(){return{children:[],childNodes:[],style:{},setAttribute:function(){},getElementsByTagName:function(){return[]}}},location:{hash:""}}:document,t="undefined"==typeof window?{document:e,navigator:{userAgent:""},location:{},history:{},CustomEvent:function(){return this},addEventListener:function(){},removeEventListener:function(){},getComputedStyle:function(){return{getPropertyValue:function(){return""}}},Image:function(){},Date:function(){},screen:{},setTimeout:function(){},clearTimeout:function(){}}:window,i=function(e){for(var t=0;t<e.length;t+=1)this[t]=e[t];return this.length=e.length,this};function s(s,a){var r=[],n=0;if(s&&!a&&s instanceof i)return s;if(s)if("string"==typeof s){var o,l,d=s.trim();if(d.indexOf("<")>=0&&d.indexOf(">")>=0){var h="div";for(0===d.indexOf("<li")&&(h="ul"),0===d.indexOf("<tr")&&(h="tbody"),0!==d.indexOf("<td")&&0!==d.indexOf("<th")||(h="tr"),0===d.indexOf("<tbody")&&(h="table"),0===d.indexOf("<option")&&(h="select"),(l=e.createElement(h)).innerHTML=d,n=0;n<l.childNodes.length;n+=1)r.push(l.childNodes[n])}else for(o=a||"#"!==s[0]||s.match(/[ .<>:~]/)?(a||e).querySelectorAll(s.trim()):[e.getElementById(s.trim().split("#")[1])],n=0;n<o.length;n+=1)o[n]&&r.push(o[n])}else if(s.nodeType||s===t||s===e)r.push(s);else if(s.length>0&&s[0].nodeType)for(n=0;n<s.length;n+=1)r.push(s[n]);return new i(r)}function a(e){for(var t=[],i=0;i<e.length;
vendor: 4,245 bytes, line 3559
3559i+=1)-1===t.indexOf(e[i])&&t.push(e[i]);return t}s.fn=i.prototype,s.Class=i,s.Dom7=i;var r={addClass:function(e){if(void 0===e)return this;for(var t=e.split(" "),i=0;i<t.length;i+=1)for(var s=0;s<this.length;s+=1)void 0!==this[s]&&void 0!==this[s].classList&&this[s].classList.add(t[i]);return this},removeClass:function(e){for(var t=e.split(" "),i=0;i<t.length;i+=1)for(var s=0;s<this.length;s+=1)void 0!==this[s]&&void 0!==this[s].classList&&this[s].classList.remove(t[i]);return this},hasClass:function(e){return!!this[0]&&this[0].classList.contains(e)},toggleClass:function(e){for(var t=e.split(" "),i=0;i<t.length;i+=1)for(var s=0;s<this.length;s+=1)void 0!==this[s]&&void 0!==this[s].classList&&this[s].classList.toggle(t[i]);return this},attr:function(e,t){var i=arguments;if(1===arguments.length&&"string"==typeof e)return this[0]?this[0].getAttribute(e):void 0;for(var s=0;s<this.length;s+=1)if(2===i.length)this[s].setAttribute(e,t);else for(var a in e)this[s][a]=e[a],this[s].setAttribute(a,e[a]);return this},removeAttr:function(e){for(var t=0;t<this.length;t+=1)this[t].removeAttribute(e);return this},data:function(e,t){var i;if(void 0!==t){for(var s=0;s<this.length;s+=1)(i=this[s]).dom7ElementDataStorage||(i.dom7ElementDataStorage={}),i.dom7ElementDataStorage[e]=t;return this}if(i=this[0]){if(i.dom7ElementDataStorage&&e in i.dom7ElementDataStorage)return i.dom7ElementDataStorage[e];var a=i.getAttribute("data-"+e);return a||void 0}},transform:function(e){for(var t=0;t<this.length;t+=1){var i=this[t].style;i.webkitTransform=e,i.transform=e}return this},transition:function(e){"string"!=typeof e&&(e+="ms");for(var t=0;t<this.length;t+=1){var i=this[t].style;i.webkitTransitionDuration=e,i.transitionDuration=e}return this},on:function(){for(var e,t=[],i=arguments.length;i--;)t[i]=arguments[i];var a=t[0],r=t[1],n=t[2],o=t[3];function l(e){var t=e.target;if(t){var i=e.target.dom7EventData||[];if(i.indexOf(e)<0&&i.unshift(e),s(t).is(r))n.apply(t,i);else for(var a=s(t).parents(),o=0;o<a.length;o+=1)s(a[o]).is(r)&&n.apply(a[o],i)}}function d(e){var t=e&&e.target&&e.target.dom7EventData||[];t.indexOf(e)<0&&t.unshift(e),n.apply(this,t)}"function"==typeof t[1]&&(a=(e=t)[0],n=e[1],o=e[2],r=void 0),o||(o=!1);for(var h,p=a.split(" "),c=0;c<this.length;c+=1){var u=this[c];if(r)for(h=0;h<p.length;h+=1){var v=p[h];u.dom7LiveListeners||(u.dom7LiveListeners={}),u.dom7LiveListeners[v]||(u.dom7LiveListeners[v]=[]),u.dom7LiveListeners[v].push({listener:n,proxyListener:l}),u.addEventListener(v,l,o)}else for(h=0;h<p.length;h+=1){var f=p[h];u.dom7Listeners||(u.dom7Listeners={}),u.dom7Listeners[f]||(u.dom7Listeners[f]=[]),u.dom7Listeners[f].push({listener:n,proxyListener:d}),u.addEventListener(f,d,o)}}return this},off:function(){for(var e,t=[],i=arguments.length;i--;)t[i]=arguments[i];var s=t[0],a=t[1],r=t[2],n=t[3];"function"==typeof t[1]&&(s=(e=t)[0],r=e[1],n=e[2],a=void 0),n||(n=!1);for(var o=s.split(" "),l=0;l<o.length;l+=1)for(var d=o[l],h=0;h<this.length;h+=1){var p=this[h],c=void 0;if(!a&&p.dom7Listeners?c=p.dom7Listeners[d]:a&&p.dom7LiveListeners&&(c=p.dom7LiveListeners[d]),c&&c.length)for(var u=c.length-1;u>=0;u-=1){var v=c[u];r&&v.listener===r?(p.removeEventListener(d,v.proxyListener,n),c.splice(u,1)):r&&v.listener&&v.listener.dom7proxy&&v.listener.dom7proxy===r?(p.removeEventListener(d,v.proxyListener,n),c.splice(u,1)):r||(p.removeEventListener(d,v.proxyListener,n),c.splice(u,1))}}return this},trigger:function(){for(var i=[],s=arguments.length;s--;)i[s]=arguments[s];for(var a=i[0].split(" "),r=i[1],n=0;n<a.length;n+=1)for(var o=a[n],l=0;l<this.length;l+=1){var d=this[l],h=void 0;try{h=new t.CustomEvent(o,{detail:r,bubbles:!0,cancelable:!0})}catch(t){(h=e.createEvent("Event")).initEvent(o,!0,!0),h.detail=r}d.dom7EventData=i.filter((function(e,t){return t>0})),d.dispatchEvent(h),d.dom7EventData=[],delete d.dom7EventData}return this},transitionEnd:function(e){var t,i=["webkitTransitionEnd","transitionend"],s=this;function a(r){if(r.target===this)for(e.call(this,r),t=0;t<i.length;t+=1)s.off(i[t],a)}if(e)for(t=0;t<i.length;t+=1)s.on(i[t],a);return this},outerWidth:function(e){if(this.length>0){if(e){var t=this.styles();return this[0].offsetWidth+parseFloat(t.getPropertyValue("margin-right"))+
vendor: 7,248 bytes, line 3559
3559parseFloat(t.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(e){if(this.length>0){if(e){var t=this.styles();return this[0].offsetHeight+parseFloat(t.getPropertyValue("margin-top"))+parseFloat(t.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},offset:function(){if(this.length>0){var i=this[0],s=i.getBoundingClientRect(),a=e.body,r=i.clientTop||a.clientTop||0,n=i.clientLeft||a.clientLeft||0,o=i===t?t.scrollY:i.scrollTop,l=i===t?t.scrollX:i.scrollLeft;return{top:s.top+o-r,left:s.left+l-n}}return null},css:function(e,i){var s;if(1===arguments.length){if("string"!=typeof e){for(s=0;s<this.length;s+=1)for(var a in e)this[s].style[a]=e[a];return this}if(this[0])return t.getComputedStyle(this[0],null).getPropertyValue(e)}if(2===arguments.length&&"string"==typeof e){for(s=0;s<this.length;s+=1)this[s].style[e]=i;return this}return this},each:function(e){if(!e)return this;for(var t=0;t<this.length;t+=1)if(!1===e.call(this[t],t,this[t]))return this;return this},html:function(e){if(void 0===e)return this[0]?this[0].innerHTML:void 0;for(var t=0;t<this.length;t+=1)this[t].innerHTML=e;return this},text:function(e){if(void 0===e)return this[0]?this[0].textContent.trim():null;for(var t=0;t<this.length;t+=1)this[t].textContent=e;return this},is:function(a){var r,n,o=this[0];if(!o||void 0===a)return!1;if("string"==typeof a){if(o.matches)return o.matches(a);if(o.webkitMatchesSelector)return o.webkitMatchesSelector(a);if(o.msMatchesSelector)return o.msMatchesSelector(a);for(r=s(a),n=0;n<r.length;n+=1)if(r[n]===o)return!0;return!1}if(a===e)return o===e;if(a===t)return o===t;if(a.nodeType||a instanceof i){for(r=a.nodeType?[a]:a,n=0;n<r.length;n+=1)if(r[n]===o)return!0;return!1}return!1},index:function(){var e,t=this[0];if(t){for(e=0;null!==(t=t.previousSibling);)1===t.nodeType&&(e+=1);return e}},eq:function(e){if(void 0===e)return this;var t,s=this.length;return new i(e>s-1?[]:e<0?(t=s+e)<0?[]:[this[t]]:[this[e]])},append:function(){for(var t,s=[],a=arguments.length;a--;)s[a]=arguments[a];for(var r=0;r<s.length;r+=1){t=s[r];for(var n=0;n<this.length;n+=1)if("string"==typeof t){var o=e.createElement("div");for(o.innerHTML=t;o.firstChild;)this[n].appendChild(o.firstChild)}else if(t instanceof i)for(var l=0;l<t.length;l+=1)this[n].appendChild(t[l]);else this[n].appendChild(t)}return this},prepend:function(t){var s,a;for(s=0;s<this.length;s+=1)if("string"==typeof t){var r=e.createElement("div");for(r.innerHTML=t,a=r.childNodes.length-1;a>=0;a-=1)this[s].insertBefore(r.childNodes[a],this[s].childNodes[0])}else if(t instanceof i)for(a=0;a<t.length;a+=1)this[s].insertBefore(t[a],this[s].childNodes[0]);else this[s].insertBefore(t,this[s].childNodes[0]);return this},next:function(e){return this.length>0?e?this[0].nextElementSibling&&s(this[0].nextElementSibling).is(e)?new i([this[0].nextElementSibling]):new i([]):this[0].nextElementSibling?new i([this[0].nextElementSibling]):new i([]):new i([])},nextAll:function(e){var t=[],a=this[0];if(!a)return new i([]);for(;a.nextElementSibling;){var r=a.nextElementSibling;e?s(r).is(e)&&t.push(r):t.push(r),a=r}return new i(t)},prev:function(e){if(this.length>0){var t=this[0];return e?t.previousElementSibling&&s(t.previousElementSibling).is(e)?new i([t.previousElementSibling]):new i([]):t.previousElementSibling?new i([t.previousElementSibling]):new i([])}return new i([])},prevAll:function(e){var t=[],a=this[0];if(!a)return new i([]);for(;a.previousElementSibling;){var r=a.previousElementSibling;e?s(r).is(e)&&t.push(r):t.push(r),a=r}return new i(t)},parent:function(e){for(var t=[],i=0;i<this.length;i+=1)null!==this[i].parentNode&&(e?s(this[i].parentNode).is(e)&&t.push(this[i].parentNode):t.push(this[i].parentNode));return s(a(t))},parents:function(e){for(var t=[],i=0;i<this.length;i+=1)for(var r=this[i].parentNode;r;)e?s(r).is(e)&&t.push(r):t.push(r),r=r.parentNode;return s(a(t))},closest:function(e){var t=this;return void 0===e?new i([]):(t.is(e)||(t=t.parents(e).eq(0)),t)},find:function(e){for(var t=[],s=0;s<this.length;s+=1)for(var a=this[s].querySelectorAll(e),r=0;r<a.length;r+=1)t.push(a[r]);return new i(t)},children:function(e){for(var t=[],r=0;r<this.length;r+=1)for(var n=this[r].childNodes,o=0;o<n.length;o+=1)e?1===n[o].nodeType&&s(n[o]).is(e)&&t.push(n[o]):1===n[o].nodeType&&t.push(n[o]);return new i(a(t))},filter:function(e){for(var t=[],s=0;s<this.length;s+=1)e.call(this[s],s,this[s])&&t.push(this[s]);return new i(t)},remove:function(){for(var e=0;e<this.length;e+=1)this[e].parentNode&&this[e].parentNode.removeChild(this[e]);return this},add:function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var i,a;for(i=0;i<e.length;i+=1){var r=s(e[i]);for(a=0;a<r.length;a+=1)this[this.length]=r[a],this.length+=1}return this},styles:function(){return this[0]?t.getComputedStyle(this[0],null):{}}};Object.keys(r).forEach((function(e){s.fn[e]=s.fn[e]||r[e]}));var n={deleteProps:function(e){var t=e;Object.keys(t).forEach((function(e){try{t[e]=null}catch(e){}try{delete t[e]}catch(e){}}))},nextTick:function(e,t){return void 0===t&&(t=0),setTimeout(e,t)},now:function(){return Date.now()},getTranslate:function(e,i){var s,a,r;void 0===i&&(i="x");var n=t.getComputedStyle(e,null);return t.WebKitCSSMatrix?((a=n.transform||n.webkitTransform).split(",").length>6&&(a=a.split(", ").map((function(e){return e.replace(",",".")})).join(", ")),r=new t.WebKitCSSMatrix("none"===a?"":a)):s=(r=n.MozTransform||n.OTransform||n.MsTransform||n.msTransform||n.transform||n.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,")).toString().split(","),"x"===i&&(a=t.WebKitCSSMatrix?r.m41:16===s.length?parseFloat(s[12]):parseFloat(s[4])),"y"===i&&(a=t.WebKitCSSMatrix?r.m42:16===s.length?parseFloat(s[13]):parseFloat(s[5])),a||0},parseUrlQuery:function(e){var i,s,a,r,n={},o=e||t.location.href;if("string"==typeof o&&o.length)for(r=(s=(o=o.indexOf("?")>-1?o.replace(/\S*\?/,""):"").split("&").filter((function(e){return""!==e}))).length,i=0;i<r;i+=1)a=s[i].replace(/#\S+/g,"").split("="),n[decodeURIComponent(a[0])]=void 0===a[1]?void 0:decodeURIComponent(a[1])||"";return n},isObject:function(e){return"object"==typeof e&&null!==e&&e.constructor&&e.constructor===Object},extend:function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];for(var i=Object(e[0]),s=1;s<e.length;s+=1){var a=e[s];if(null!=a)for(var r=Object.keys(Object(a)),o=0,l=r.length;o<l;o+=1){var d=r[o],h=Object.getOwnPropertyDescriptor(a,d);void 0!==h&&h.enumerable&&(n.isObject(i[d])&&n.isObject(a[d])?n.extend(i[d],a[d]):!n.isObject(i[d])&&n.isObject(a[d])?(i[d]={},n.extend(i[d],a[d])):i[d]=a[d])}}return i}},o={touch:t.Modernizr&&!0===t.Modernizr.touch||!!(t.navigator.maxTouchPoints>0||"ontouchstart"in t||t.DocumentTouch&&e instanceof t.DocumentTouch),pointerEvents:!!t.PointerEvent&&"maxTouchPoints"in t.navigator&&t.navigator.maxTouchPoints>0,observer:"MutationObserver"in t||"WebkitMutationObserver"in t,passiveListener:function(){var e=!1;try{var i=Object.defineProperty({},"passive",{get:function(){e=!0}});t.addEventListener("testPassiveListener",null,i)}catch(e){}return e}(),gestures:"ongesturestart"in t},l=function(e){void 0===e&&(e={});var t=this;t.params=e,t.eventsListeners={}
3559,t.params&&t.params.on&&Object.keys(t.params.on).forEach((function(e){t.on(e,t.params.on[e])}))},d={components:{configurable:!0}};l.prototype.on=function(e,t,i){var s=this;if("function"!=typeof t)return s;var a=i?"unshift":"push";return e.split(" ").forEach((function(e){s.eventsListeners[e]||(s.eventsListeners[e]=[]),s.eventsListeners[e][a](t)})),s},l.prototype.once=function(e,t,i){var s=this;if("function"!=typeof t)return s;function a(){for(var i=[],r=arguments.length;r--;)i[r]=arguments[r];t.apply(s,i),s.off(e,a),a.f7proxy&&delete a.f7proxy}return a.f7proxy=t,s.on(e,a,i)},l.prototype.off=function(e,t){var i=this;return i.eventsListeners?(e.split(" ").forEach((function(e){void 0===t?i.eventsListeners[e]=[]:i.eventsListeners[e]&&i.eventsListeners[e].length&&i.eventsListeners[e].forEach((function(s,a){(s===t||s.f7proxy&&s.f7proxy===t)&&i.eventsListeners[e].splice(a,1)}))})),i):i},l.prototype.emit=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var i,s,a,r=this;if(!r.eventsListeners)return r;"string"==typeof e[0]||Array.isArray(e[0])?(i=e[0],s=e.slice(1,e.length),a=r):(i=e[0].events,s=e[0].data,a=e[0].context||r);var n=Array.isArray(i)?i:i.split(" ");return n.forEach((function(e){if(r.eventsListeners&&r.eventsListeners[e]){var t=[];r.eventsListeners[e].forEach((function(e){t.push(e)})),t.forEach((function(e){e.apply(a,s)}))}})),r},l.prototype.useModulesParams=function(e){var t=this;t.modules&&Object.keys(t.modules).forEach((function(i){var s=t.modules[i];s.params&&n.extend(e,s.params)}))},l.prototype.useModules=function(e){void 0===e&&(e={});var t=this;t.modules&&Object.keys(t.modules).forEach((function(i){var s=t.modules[i],a=e[i]||{};s.instance&&Object.keys(s.instance).forEach((function(e){var i=s.instance[e];t[e]="function"==typeof i?i.bind(t):i})),s.on&&t.on&&Object.keys(s.on).forEach((function(e){t.on(e,s.on[e])})),s.create&&s.create.bind(t)(a)}))},d.components.set=function(e){this.use&&this.use(e)},l.installModule=function(e){for(var t=[],i=arguments.length-1;i-- >0;)t[i]=arguments[i+1];var s=this;s.prototype.modules||(s.prototype.modules={});var a=e.name||Object.keys(s.prototype.modules).length+"_"+n.now();return s.prototype.modules[a]=e,e.proto&&Object.keys(e.proto).forEach((function(t){s.prototype[t]=e.proto[t]})),e.static&&Object.keys(e.static).forEach((function(t){s[t]=e.static[t]})),e.install&&e.install.apply(s,t),s},l.use=function(e){for(var t=[],i=arguments.length-1;i-- >0;)t[i]=arguments[i+1];var s=this;return Array.isArray(e)?(e.forEach((function(e){return s.installModule(e)})),s):s.installModule.apply(s,[e].concat(t))},Object.defineProperties(l,d);var h={updateSize:function(){var e,t,i=this.$el;e=void 0!==this.params.width?this.params.width:i[0].clientWidth,t=void 0!==this.params.height?this.params.height:i[0].clientHeight,0===e&&this.isHorizontal()||0===t&&this.isVertical()||(e=e-parseInt(i.css("padding-left"),10)-parseInt(i.css("padding-right"),10),t=t-parseInt(i.css("padding-top"),10)-parseInt(i.css("padding-bottom"),10),n.extend(this,{width:e,height:t,size:this.isHorizontal()?e:t}))},updateSlides:function(){var e=this.params,i=this.$wrapperEl,s=this.size,a=this.rtlTranslate,r=this.wrongRTL,o=this.virtual&&e.virtual.enabled,l=o?this.virtual.slides.length:this.slides.length,d=i.children("."+this.params.slideClass),h=o?this.virtual.slides.length:d.length,p=[],c=[],u=[];function v(t){return!e.cssMode||t!==d.length-1}var f=e.slidesOffsetBefore;"function"==typeof f&&(f=e.slidesOffsetBefore.call(this));var m=e.slidesOffsetAfter;"function"==typeof m&&(m=e.slidesOffsetAfter.call(this));var g=this.snapGrid.length,b=this.snapGrid.length,w=e.spaceBetween,y=-f,x=0,T=0;if(void 0!==s){var E,C;"string"==typeof w&&w.indexOf("%")>=0&&(w=parseFloat(w.replace("%",""))/100*s),this.virtualSize=-w,a?d.css({marginLeft:"",marginTop:""}):d.css({marginRight:"",marginBottom:""}),e.slidesPerColumn>1&&(E=Math.floor(h/e.slidesPerColumn)===h/this.params.slidesPerColumn?h:Math.ceil(h/e.slidesPerColumn)*e.slidesPerColumn,"auto"!==e.slidesPerView&&"row"===e.slidesPerColumnFill&&(E=Math.max(E,e.slidesPerView*e.slidesPerColumn)));for(var S,M=e.slidesPerColumn,P=E/M,z=Math.floor(h/e.slidesPerColumn),k=0;k<h;k+=1){C=0;var $=d.eq(k);if(e.slidesPerColumn>1){var L=void 0,I=void 0,D=void 0;if("row"===e.slidesPerColumnFill&&e.slidesPerGroup>1){var O=Math.floor(k/(e.slidesPerGroup*e.slidesPerColumn)),A=k-e.slidesPerColumn*e.slidesPerGroup*O;L=(I=A-(D=Math.floor(A/e.slidesPerGroup))*e.slidesPerGroup+O*e.slidesPerGroup)+D*E/M,$.css({"-webkit-box-ordinal-group":L,"-moz-box-ordinal-group":L,"-ms-flex-order":L,"-webkit-order":L,order:L})}else"column"===e.slidesPerColumnFill?(D=k-(I=Math.floor(k/M))*M,(I>z||I===z&&D===M-1)&&(D+=1)>=M&&(D=0,I+=1)):I=k-(D=Math.floor(k/P))*P;$.css("margin-"+(this.isHorizontal()?"top":"left"),0!==D&&e.spaceBetween&&e.spaceBetween+"px")}if("none"!==$.css("display")){if("auto"===e.slidesPerView){var H=t.getComputedStyle($[0],null),G=$[0].style.transform,N=$[0].style.webkitTransform;if(G&&($[0].style.transform="none"),N&&($[0].style.webkitTransform="none"),e.roundLengths)C=this.isHorizontal()?$.outerWidth(!0):$.outerHeight(!0);else if(this.isHorizontal()){var B=parseFloat(H.getPropertyValue("width")),V=parseFloat(H.getPropertyValue("padding-left")),X=p
3559arseFloat(H.getPropertyValue("padding-right")),Y=parseFloat(H.getPropertyValue("margin-left")),F=parseFloat(H.getPropertyValue("margin-right")),R=H.getPropertyValue("box-sizing");C=R&&"border-box"===R?B+Y+F:B+V+X+Y+F}else{var W=parseFloat(H.getPropertyValue("height")),q=parseFloat(H.getPropertyValue("padding-top")),j=parseFloat(H.getPropertyValue("padding-bottom")),K=parseFloat(H.getPropertyValue("margin-top")),U=parseFloat(H.getPropertyValue("margin-bottom")),_=H.getPropertyValue("box-sizing");C=_&&"border-box"===_?W+K+U:W+q+j+K+U}G&&($[0].style.transform=G),N&&($[0].style.webkitTransform=N),e.roundLengths&&(C=Math.floor(C))}else C=(s-(e.slidesPerView-1)*w)/e.slidesPerView,e.roundLengths&&(C=Math.floor(C)),d[k]&&(this.isHorizontal()?d[k].style.width=C+"px":d[k].style.height=C+"px");d[k]&&(d[k].swiperSlideSize=C),u.push(C),e.centeredSlides?(y=y+C/2+x/2+w,0===x&&0!==k&&(y=y-s/2-w),0===k&&(y=y-s/2-w),Math.abs(y)<.001&&(y=0),e.roundLengths&&(y=Math.floor(y)),T%e.slidesPerGroup==0&&p.push(y),c.push(y)):(e.roundLengths&&(y=Math.floor(y)),T%e.slidesPerGroup==0&&p.push(y),c.push(y),y=y+C+w),this.virtualSize+=C+w,x=C,T+=1}}if(this.virtualSize=Math.max(this.virtualSize,s)+m,a&&r&&("slide"===e.effect||"coverflow"===e.effect)&&i.css({width:this.virtualSize+e.spaceBetween+"px"}),e.setWrapperSize&&(this.isHorizontal()?i.css({width:this.virtualSize+e.spaceBetween+"px"}):i.css({height:this.virtualSize+e.spaceBetween+"px"})),e.slidesPerColumn>1&&(this.virtualSize=(C+e.spaceBetween)*E,this.virtualSize=Math.ceil(this.virtualSize/e.slidesPerColumn)-e.spaceBetween,this.isHorizontal()?i.css({width:this.virtualSize+e.spaceBetween+"px"}):i.css({height:this.virtualSize+e.spaceBetween+"px"}),e.centeredSlides)){S=[];for(var Z=0;Z<p.length;Z+=1){var Q=p[Z];e.roundLengths&&(Q=Math.floor(Q)),p[Z]<this.virtualSize+p[0]&&S.push(Q
3559)}p=S}if(!e.centeredSlides){S=[];for(var J=0;J<p.length;J+=1){var ee=p[J];e.roundLengths&&(ee=Math.floor(ee)),p[J]<=this.virtualSize-s&&S.push(ee)}p=S,Math.floor(this.virtualSize-s)-Math.floor(p[p.length-1])>1&&p.push(this.virtualSize-s)}if(0===p.length&&(p=[0]),0!==e.spaceBetween&&(this.isHorizontal()?a?d.filter(v).css({marginLeft:w+"px"}):d.filter(v).css({marginRight:w+"px"}):d.filter(v).css({marginBottom:w+"px"})),e.centerInsufficientSlides){var te=0;if(u.forEach((function(t){te+=t+(e.spaceBetween?e.spaceBetween:0)})),(te-=e.spaceBetween)<s){var ie=(s-te)/2;p.forEach((function(e,t){p[t]=e-ie})),c.forEach((function(e,t){c[t]=e+ie}))}}n.extend(this,{slides:d,snapGrid:p,slidesGrid:c,slidesSizesGrid:u}),h!==l&&this.emit("slidesLengthChange"),p.length!==g&&(this.params.watchOverflow&&this.checkOverflow(),this.emit("snapGridLengthChange")),c.length!==b&&this.emit("slidesGridLengthChange"),(e.watchSlidesProgress||e.watchSlidesVisibility)&&this.updateSlidesOffset()}},updateAutoHeight:function(e){var t,i=[],s=0;if("number"==typeof e?this.setTransition(e):!0===e&&this.setTransition(this.params.speed),"auto"!==this.params.slidesPerView&&this.params.slidesPerView>1)for(t=0;t<Math.ceil(this.params.slidesPerView);t+=1){var a=this.activeIndex+t;if(a>this.slides.length)break;i.push(this.slides.eq(a)[0])}else i.push(this.slides.eq(this.activeIndex)[0]);for(t=0;t<i.length;t+=1)if(void 0!==i[t]){var r=i[t].offsetHeight;s=r>s?r:s}s&&this.$wrapperEl.css("height",s+"px")},updateSlidesOffset:function(){for(var e=this.slides,t=0;t<e.length;t+=1)e[t].swiperSlideOffset=this.isHorizontal()?e[t].offsetLeft:e[t].offsetTop},updateSlidesProgress:function(e){void 0===e&&(e=this&&this.translate||0);var t=this.params,i=this.slides,a=this.rtlTranslate;if(0!==i.length){void 0===i[0].swiperSlideOffset&&this.updateSlidesOffset();var r=-e;a&&(r=e),i.removeClass(t.slideVisibleClass),this.visibleSlidesIndexes=[],this.visibleSlides=[];for(var n=0;n<i.length;n+=1){var o=i[n],l=(r+(t.centeredSlides?this.minTranslate():0)-o.swiperSlideOffset)/(o.swiperSlideSize+t.spaceBetween);if(t.watchSlidesVisibility){var d=-(r-o.swiperSlideOffset),h=d+this.slidesSizesGrid[n];(d>=0&&d<this.size-1||h>1&&h<=this.size||d<=0&&h>=this.size)&&(this.visibleSlides.push(o),this.visibleSlidesIndexes.push(n),i.eq(n).addClass(t.slideVisibleClass))}o.progress=a?-l:l}this.visibleSlides=s(this.visibleSlides)}},updateProgress:function(e){if(void 0===e){var t=this.rtlTranslate?-1:1;e=this&&this.translate&&this.translate*t||0}var i=this.params,s=this.maxTranslate()-this.minTranslate(),a=this.progress,r=this.isBeginning,o=this.isEnd,l=r,d=o;0===s?(a=0,r=!0,o=!0):(r=(a=(e-this.minTranslate())/s)<=0,o=a>=1),n.extend(this,{progress:a,isBeginning:r,isEnd:o}),(i.watchSlidesProgress||i.watchSlidesVisibility)&&this.updateSlidesProgress(e),r&&!l&&this.emit("reachBeginning toEdge"),o&&!d&&this.emit("reachEnd toEdge"),(l&&!r||d&&!o)&&this.emit("fromEdge"),this.emit("progress",a)},updateSlidesClasses:function(){var e,t=this.slides,i=this.params,s=this.$wrapperEl,a=this.activeIndex,r=this.realIndex,n=this.virtual&&i.virtual.enabled;t.removeClass(i.slideActiveClass+" "+i.slideNextClass+" "+i.slidePrevClass+" "+i.slideDuplicateActiveClass+" "+i.slideDuplicateNextClass+" "+i.slideDuplicatePrevClass),(e=n?this.$wrapperEl.find("."+i.slideClass+'[data-swiper-slide-index="'+a+'"]'):t.eq(a)).addClass(i.slideActiveClass),i.loop&&(e.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+r+'"]').addClass(i.slideDuplicateActiveClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+r+'"]').addClass(i.slideDuplicateActiveClass));var o=e.nextAll("."+i.slideClass).eq(0).addClass(i.slideNextClass);i.loop&&0===o.length&&(o=t.eq(0)).addClass(i.slideNextClass);var l=e.prevAll("."+i.slideClass).eq(0).addClass(i.slidePrevClass);
3559i.loop&&0===l.length&&(l=t.eq(-1)).addClass(i.slidePrevClass),i.loop&&(o.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+o.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+o.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass),l.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass))},updateActiveIndex:function(e){var t,i=this.rtlTranslate?this.translate:-this.translate,s=this.slidesGrid,a=this.snapGrid,r=this.params,o=this.activeIndex,l=this.realIndex,d=this.snapIndex,h=e;if(void 0===h){for(var p=0;p<s.length;p+=1)void 0!==s[p+1]?i>=s[p]&&i<s[p+1]-(s[p+1]-s[p])/2?h=p:i>=s[p]&&i<s[p+1]&&(h=p+1):i>=s[p]&&(h=p);r.normalizeSlideIndex&&(h<0||void 0===h)&&(h=0)}if((t=a.indexOf(i)>=0?a.indexOf(i):Math.floor(h/r.slidesPerGroup))>=a.length&&(t=a.length-1),h!==o){var c=parseInt(this.slides.eq(h).attr("data-swiper-slide-index")||h,10);n.extend(this,{snapIndex:t,realIndex:c,previousIndex:o,activeIndex:h}),this.emit("activeIndexChange"),this.emit("snapIndexChange"),l!==c&&this.emit("realIndexChange"),(this.initialized||this.runCallbacksOnInit)&&this.emit("slideChange")}else t!==d&&(this.snapIndex=t,this.emit("snapIndexChange"))},updateClickedSlide:function(e){var t=this.params,i=s(e.target).closest("."+t.slideClass)[0],a=!1;if(i)for(var r=0;r<this.slides.length;r+=1)this.slides[r]===i&&(a=!0);if(!i||!a)return this.clickedSlide=void 0,void(this.clickedIndex=void 0);this.clickedSlide=i,this.virtual&&this.params.virtual.enabled?this.clickedIndex=parseInt(s(i).attr("data-swiper-slide-index"),10):this.clickedIndex=s(i).index(),t.slideToClickedSlide&&void 0!==this.clickedIndex&&this.clickedIndex!==this.activeIndex&&this.slideToClickedSlide()}};var p={getTranslate:function(e){void 0===e&&(e=this.isHorizontal()?"x":"y");var t=this.params,i=this.rtlTranslate,s=this.translate,a=this.$wrapperEl;if(t.virtualTranslate)return i?-s:s;if(t.cssMode)return s;var r=n.getTranslate(a[0],e);return i&&(r=-r),r||0},setTranslate:function(e,t){var i=this.rtlTranslate,s=this.params,a=this.$wrapperEl,r=this.wrapperEl,n=this.progress,o=0,l=0;this.isHorizontal()?o=i?-e:e:l=e,s.roundLengths&&(o=Math.floor(o),l=Math.floor(l)),s.cssMode?r[this.isHorizontal()?"scrollLeft":"scrollTop"]=this.isHorizontal()?-o:-l:s.virtualTranslate||a.transform("translate3d("+o+"px, "+l+"px, 0px)"),this.previousTranslate=this.translate,this.translate=this.isHorizontal()?o:l;var d=this.maxTranslate()-this.minTranslate();(0===d?0:(e-this.minTranslate())/d)!==n&&this.updateProgress(e),this.emit("setTranslate",this.translate,t)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]},translateTo:function(e,t,i,s,a){var r;void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===i&&(i=!0),void 0===s&&(s=!0);var n=this,o=n.params,l=n.wrapperEl;if(n.animating&&o.preventInteractionOnTransition)return!1;var d,h=n.minTranslate(),p=n.maxTranslate();if(d=s&&e>h?h:s&&e<p?p:e,n.updateProgress(d),o.cssMode){var c=n.isHorizontal();return 0===t?l[c?"scrollLeft":"scrollTop"]=-d:l.scrollTo?l.scrollTo(((r={})[c?"left":"top"]=-d,r.behavior="smooth",r)):l[c?"scrollLeft":"scrollTop"]=-d,!0}return 0===t?(n.setTransition(0),n.setTranslate(d),i&&(n.emit("beforeTransitionStart",t,a),n.emit("transitionEnd"))):(n.setTransition(t),n.setTranslate(d),i&&(n.emit("beforeTransitionStart",t,a),n.emit("transitionStart")),n.animating||(n.animating=!0,n.onTranslateToWrapperTransitionEnd||(n.onTranslateToWrapperTransitionEnd=function(e){n&&!n.destroyed&&e.target===this&&(n.$wrapperEl[0].removeEventListener("transitionend",n.onTranslateToWrapperTransitionEnd),n.$wrapperEl[0].removeEventListener("webkitTransitionEnd",n.onTranslateToWrapperTransitionEnd),n.onTranslateToWrapperTransitionEnd=null,delete n.onTranslateToWrapperTransitionEnd,i&&n.emit("transitionEnd"))}),n.$wrapperEl[0].addEventListener("transitionend",n.onTranslateToWrapperTransitionEnd),n.$wrapperEl[0].addEventListener("webkitTransitionEnd",n.onTranslateToWrapperTransitionEnd))),!0}};var c={setTransition:function(e,t){this.params.cssMode||this.$wrapperEl.transition(e),this.emit
3559("setTransition",e,t)},transitionStart:function(e,t){void 0===e&&(e=!0);var i=this.activeIndex,s=this.params,a=this.previousIndex;if(!s.cssMode){s.autoHeight&&this.updateAutoHeight();var r=t;if(r||(r=i>a?"next":i<a?"prev":"reset"),this.emit("transitionStart"),e&&i!==a){if("reset"===r)return void this.emit("slideResetTransitionStart");this.emit("slideChangeTransitionStart"),"next"===r?this.emit("slideNextTransitionStart"):this.emit("slidePrevTransitionStart")}}},transitionEnd:function(e,t){void 0===e&&(e=!0);var i=this.activeIndex,s=this.previousIndex,a=this.params;if(this.animating=!1,!a.cssMode){this.setTransition(0);var r=t;if(r||(r=i>s?"next":i<s?"prev":"reset"),this.emit("transitionEnd"),e&&i!==s){if("reset"===r)return void this.emit("slideResetTransitionEnd");this.emit("slideChangeTransitionEnd"),"next"===r?this.emit("slideNextTransitionEnd"):this.emit("slidePrevTransitionEnd")}}}};var u={slideTo:function(e,t,i,s){var a;void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===i&&(i=!0);var r=this,n=e;n<0&&(n=0);var o=r.params,l=r.snapGrid,d=r.slidesGrid,h=r.previousIndex,p=r.activeIndex,c=r.rtlTranslate,u=r.wrapperEl;if(r.animating&&o.preventInteractionOnTransition)return!1;var v=Math.floor(n/o.slidesPerGroup);v>=l.length&&(v=l.length-1),(p||o.initialSlide||0)===(h||0)&&i&&r.emit("beforeSlideChangeStart");var f,m=-l[v];if(r.updateProgress(m),o.normalizeSlideIndex)for(var g=0;g<d.length;g+=1)-Math.floor(100*m)>=Math.floor(100*d[g])&&(n=g);if(r.initialized&&n!==p){if(!r.allowSlideNext&&m<r.translate&&m<r.minTranslate())return!1;if(!r.allowSlidePrev&&m>r.translate&&m>r.maxTranslate()&&(p||0)!==n)return!1}if(f=n>p?"next":n<p?"prev":"reset",c&&-m===r.translate||!c&&m===r.translate)return r.updateActiveIndex(n),o.autoHeight&&r.updateAutoHeight(),r.updateSlidesClasses(),"slide"!==o.effect&&r.setTranslate(m),"reset"!==f&&(r.transitionStart(i,f),r.transitionEnd(i,f)),!1;if(o.cssMode){var b=r.isHorizontal();return 0===t?u[b?"scrollLeft":"scrollTop"]=-m:u.scrollTo?u.scrollTo(((a={})[b?"left":"top"]=-m,a.behavior="smooth",a)):u[b?"scrollLeft":"scrollTop"]=-m,!0}return 0===t?(r.setTransition(0),r.setTranslate(m),r.updateActiveIndex(n),r.updateSlidesClasses(),r.emit("beforeTransitionStart",t,s),r.transitionStart(i,f),r.transitionEnd(i,f)):(r.setTransition(t),r.setTranslate(m),r.updateActiveIndex(n),r.updateSlidesClasses(),r.emit("beforeTransitionStart",t,s),r.transitionStart(i,f),r.animating||(r.animating=!0,r.onSlideToWrapperTransitionEnd||(r.onSlideToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.$wrapperEl[0].removeEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].removeEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd),r.onSlideToWrapperTransitionEnd=null,delete r.onSlideToWrapperTransitionEnd,r.transitionEnd(i,f))}),r.$wrapperEl[0].addEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].addEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd))),!0},slideToLoop:function(e,t,i,s){void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===i&&(i=!0);var a=e;return this.params.loop&&(a+=this.loopedSlides),this.slideTo(a,t,i,s)},slideNext:function(e,t,i){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);var s=this.params,a=this.animating;return s.loop?!a&&(this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft,this.slideTo(this.activeIndex+s.slidesPerGroup,e,t,i)):this.slideTo(this.activeIndex+s.slidesPerGroup,e,t,i)},slidePrev:function(e,t,i){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);var s=this.params,a=this.animating,r=this.snapGrid,n=this.slidesGrid,o=this.rtlTranslate;if(s.loop){if(a)return!1;this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft}function l(e){return e<0?-Math.floor(Math.abs(e)):Math.floor(e)}var d,h=l(o?this.translate:-this.translate),p=r.map((function(e){return l(e)})),c=(n.map((function(e){return l(e)})),r[p.indexOf(h)],r[p.indexOf(h)-1]);return void 0===c&&s.cssMode&&r.forEach((function(e){!c&&h>=e&&(c=e)})),void 0!==c&&(d=n.indexOf(c))<0&&(d=this.activeIndex-1),this.slideTo(d,e,t,i)},slideReset:function(e,t,i){return void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),this.slideTo(this.activeIndex,e,t,i)},slideToClosest:function(e,t,i){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);var s=this.activeIndex,a=Math.floor(s/this.params.slidesPerGroup);if(a<this.snapGrid.length-1){var r=this.rtlTranslate?this.translate:-this.translate,n=this.snapGrid[a];r-n>(this.snapGrid[a+1]-n)/2&&(s=this.params.slidesPerGroup)}return this.slideTo(s,e,t,i)},slideToClickedSlide:function(){var e,t=this,i=t.params,a=t.$wrapperEl,r="auto"===i.slidesPerView?t.slidesPerViewDynamic():i.slidesPerView,o=t.clickedIndex;if(i.loop){if(t.animating)return;e=parseInt(s(t.clickedSlide).attr("data-swiper-slide-index"),10),i.centeredSlides?o<t.loopedSlides-r/2||o>t.slides.length-t.loopedSlides+r/2?(t.loopFix(),o=a.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),n.nextTick((function(){t.slideTo(o)}))):t.slideTo(o):o>t.slides.length-r?(t.loopFix(),o=a.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),n.nextTick((function(){t.slideTo(o)}))):t.slideTo(o)}else t.slideTo(o)}};var v={loopCreate:function(){var t=this,i=t.params,a=t.$wrapperEl;a.children("."+i.slideClass+"."+i.slideDuplicateClass).remove();var r=a.children("."+i.slideClass);if(i.loopFillGroupWithBlank){var n=i.slidesPerGroup-r.length%i.slidesPerGroup;if(n!==i.slidesPerGroup){for(var o=0;o<n;o+=1){var l=s(e.createElement("div")).addClass(i.slideClass+" "+i.slideBlankClass);a.append(l)}r=a.children("."+i.slideClass)}}"auto"!==i.slidesPerView||i.loopedSlides||(i.loopedSlides=r.length),t.loopedSlides=Math.ceil(parseFloat(i.loopedSlides||i.slidesPerView,10)),t.loopedSlides+=i.loopAdditionalSlides,t.loopedSlides>r.length&&(t.loopedSlides=r.length);var d=[],h=[];r.each((function(e,i){var a=s(i);e<t.loopedSlides&&h.push(i),e<r.length&&e>=r.length-t.loopedSlides&&d.push(i),a.attr("data-swiper-slide-index",e)}));for(var p=0;p<h.length;p+=1)a.append(s(h[p].cloneNode(!0)).addClass(i.slideDuplicateClass));for(var c=d.length-1;c>=0;c-=1)a.prepend(s(d[c].cloneNode(!0)).addClass(i.slideDuplicateClass))},loopFix:function(){var e,t=this.params,i=this.activeIndex,s=this.slides,a=this.loopedSlides,r=this.allowSlidePrev,n=this.allowSlideNext,o=this.snapGrid,l=this.rtlTranslate;this.allowSlidePrev=!0,this.allowSlideNext=!0;var d=-o[i]-this.getTranslate();if(i<a)e=s.length-3*a+i,e+=a,this.slideTo(e,0,!1,!0)&&0!==d&&this.setTranslate((l?-this.translate:this.translate)-d);else if("auto"===t.slidesPerView&&i>=2*a||i>=s.length-a){e=-s.length+i+a,e+=a,this.slideTo(e,0,!1,!0)&&0!==d&&this.setTranslate((l?-this.translate:this.translate)-d)}this.allowSlidePrev=r,this.allowSlideNext=n},loopDestroy:function(){var e=this.$wrapperEl,t=this.params,i=this.slides;e.children("."+t.slideClass+"."+t.slideDuplicateClass+",."+t.slideClass+"."+t.slideBlankClass).remove(),i.removeAttr("data-swiper-slide-index")}};var f={setGrabCursor:function(e){if(!(o.touch||!this.params.simulateTouch||this.params.watchOverflow&&this.isLocked||this.params.cssMode)){var t=this.el;t.style.cursor="move",t.style.cursor=e?"-webkit-grabbing":"-webkit-grab",t.style.cursor=e?"-moz-grabbin":"-moz-grab",t.style.cursor=e?"grabbing":"grab"}},unsetGrabCursor:function(){o.touch||this.params.watchOverflow&&this.isLocked||this.params.cssMode||(this.el.style.cursor="")}};var m,g,b,w,y,x,T,E,C,S,M,P,z,k,$,L={appendSlide:function(e){var t=this.$wrapperEl,i=this.params;if(i.loop&&this.loopDestroy(),"object"==typeof e&&"length"in e)for(var s=0;s<e.length;s+=1)e[s]&&t.append(e[s]);else t.append(e);i.loop&&this.loopCreate(),i.observer&&o.observer||this.update()},prependSlide:function(e){var t=this.params,i=this.$wrapperEl,s=this.activeIndex;t.loop&&this.loopDestroy();var a=s+1;if("object"==typeof e&&"length"in e){for(var r=0;r<e.length;r+=1)e[r]&&i.prepend(e[r]);a=s+e.length}else i.prepend(e);t.loop&&this.loopCreate(),t.observer&&o.observer||this.update(),this.slideTo(a,0,!1)},addSlide:function(e,t){var i=this.$wrapperEl,s=this.params,a=this.activeIndex;s.loop&&(a-=this.loopedSlides,this.loopDestroy(),this.slides=i.children("."+s.slideClass));var r=this.slides.length;if(e<=0)this.prependSlide(t);else if(e>=r)this.appendSlide(t);else{for(var n=a>e?a+1:a,l=[],d=r-1;d>=e;d-=1){var h=this.slides.eq(d);h.remove(),l.unshift(h)}if("object"==typeof t&&"length"in t){for(var p=0;p<t.length;p+=1)t[p]&&i.append(t[p]);n=a>e?a+t.length:a}else i.append(t);for(var c=0;c<l.length;c+=1)i.append(l[c]);s.loop&&this.loopCreate(),s.observer&&o.observer||this.update(),s.loop?this.slideTo(n+this.loopedSlides,0,!1):this.slideTo(n,0,!1)}},removeSlide:function(e){var t=this.params,i=this.$wrapperEl,s=this.activeIndex;t.loop&&(s-=this.loopedSlides,this.loopDestroy(),this.slides=i.children("."+t.slideClass));var a,r=s;if("object"==typeof e&&"length"in e){for(var n=0;n<e.length;n+=1)a=e[n],this.slides[a]&&this.slides.eq(a).remove(),a<r&&(r-=1);r=Math.max(r,0)}else a=e,this.slides[a]&&this.slides.eq(a).remove(),a<r&&(r-=1),r=Math.max(r,0);t.loop&&this.loopCreate(),t.observer&&o.observer||this.update(),t.loop?this.slideTo(r+this.loopedSlides,0,!1):this.slideTo(r,0,!1)},removeAllSlides:function(){for(var e=[],t=0;t<this.slides.length;t+=1)e.push(t);this.removeSlide(e)}},I=(m=t.navigator.platform,g=t.navigator.userAgent,b={ios:!1,android:!1,androidChrome:!1,desktop:!1,iphone:!1,ipod:!1,ipad:!1,edge:!1,ie:!1,firefox:!1,macos:!1,windows:!1,cordova:!(!t.cordova&&!t.phonegap),phonegap:!(!t.cordova&&!t.phonegap),electron:!1},w=t.screen.width,y=t.screen.height,x=g.match(/(Android);?[\s\/]+([\d.]+)?/),T=g.match(/(iPad).*OS\s([\d_]+)/),E=g.match(/(iPod)(.*OS\s([\d_]+))?/),C=!T&&g.match(/(iPhone\sOS|iOS)\s([\d_]+)/),S=g.indexOf("MSIE ")>=0||g.indexOf("Trident/")>=0,M=g.indexOf("Edge/")>=0,P=g.indexOf("Gecko/")>=0&&g.indexOf("Firefox/")>=0,z="Win32"===m,k=g.toLowerCase().indexOf("electron")>=0,$="MacIntel"===m,!T&&$&&o.touch&&(1024===w&&1366===y||834===w&&1194===y||834===w&&1112===y||768===w&&1024===y)&&(T=g.match(/(Version)\/([\d.]+)/),$=!1),b.ie=S,b.edge=M,b.firefox=P,x&&!z&&(b.os="android",b.osVersion=x[2],b.android=!0,b.androidChrome=g.toLowerCase().indexOf("chrome")>=0),(T||C||E)&&(b.os="ios",b.ios=!0),C&&!E&&(b.osVersion=C[2].replace(/_/g,"."),b.iphone=!0),T&&(b.osVersion=T[2].replace(/_/g,"."),b.ipad=!0),E&&(b.osVersion=E[3]?E[3].replace(/_/g,"."):null,b.ipod=!0),b.i
3559os&&b.osVersion&&g.indexOf("Version/")>=0&&"10"===b.osVersion.split(".")[0]&&(b.osVersion=g.toLowerCase().split("version/")[1].split(" ")[0]),b.webView=!(!(C||T||E)||!g.match(/.*AppleWebKit(?!.*Safari)/i)&&!t.navigator.standalone)||t.matchMedia&&t.matchMedia("(display-mode: standalone)").matches,b.webview=b.webView,b.standalone=b.webView,b.desktop=!(b.ios||b.android)||k,b.desktop&&(b.electron=k,b.macos=$,b.windows=z,b.macos&&(b.os="macos"),b.windows&&(b.os="windows")),b.pixelRatio=t.devicePixelRatio||1,b);function D(i){var a=this.touchEventsData,r=this.params,o=this.touches;if(!this.animating||!r.preventInteractionOnTransition){var l=i;l.originalEvent&&(l=l.originalEvent);var d=s(l.target);if(("wrapper"!==r.touchEventsTarget||d.closest(this.wrapperEl).length)&&(a.isTouchEvent="touchstart"===l.type,(a.isTouchEvent||!("which"in l)||3!==l.which)&&!(!a.isTouchEvent&&"button"in l&&l.button>0||a.isTouched&&a.isMoved)))if(r.noSwiping&&d.closest(r.noSwipingSelector?r.noSwipingSelector:"."+r.noSwipingClass)[0])this.allowClick=!0;else if(!r.swipeHandler||d.closest(r.swipeHandler)[0]){o.currentX="touchstart"===l.type?l.targetTouches[0].pageX:l.pageX,o.currentY="touchstart"===l.type?l.targetTouches[0].pageY:l.pageY;var h=o.currentX,p=o.currentY,c=r.edgeSwipeDetection||r.iOSEdgeSwipeDetection,u=r.edgeSwipeThreshold||r.iOSEdgeSwipeThreshold;if(!c||!(h<=u||h>=t.screen.width-u)){if(n.extend(a,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),o.startX=h,o.startY=p,a.touchStartTime=n.now(),this.allowClick=!0,this.updateSize(),this.swipeDirection=void 0,r.threshold>0&&(a.allowThresholdMove=!1),"touchstart"!==l.type){var v=!0;d.is(a.formElements)&&(v=!1),e.activeElement&&s(e.activeElement).is(a.formElements)&&e.activeElement!==d[0]&&e.activeElement.blur();var f=v&&this.allowTouchMove&&r.touchStartPreventDefault;(r.touchStartForcePreventDefault||f)&&l.preventDefault()}this.emit("touchStart",l)}}}}function O(t){var i=this.touchEventsData,a=this.params,r=this.touches,o=this.rtlTranslate,l=t;if(l.originalEvent&&(l=l.originalEvent),i.isTouched){if(!i.isTouchEvent||"mousemove"!==l.type){var d="touchmove"===l.type&&l.targetTouches&&(l.targetTouches[0]||l.changedTouches[0]),h="touchmove"===l.type?d.pageX:l.pageX,p="touchmove"===l.type?d.pageY:l.pageY;if(l.preventedByNestedSwiper)return r.startX=h,void(r.startY=p);if(!this.allowTouchMove)return this.allowClick=!1,void(i.isTouched&&(n.extend(r,{startX:h,startY:p,currentX:h,currentY:p}),i.touchStartTime=n.now()));if(i.isTouchEvent&&a.touchReleaseOnEdges&&!a.loop)if(this.isVertical()){if(p<r.startY&&this.translate<=this.maxTranslate()||p>r.startY&&this.translate>=this.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else if(h<r.startX&&this.translate<=this.maxTranslate()||h>r.startX&&this.translate>=this.minTranslate())return;if(i.isTouchEvent&&e.activeElement&&l.target===e.activeElement&&s(l.target).is(i.formElements))return i.isMoved=!0,void(this.allowClick=!1);if(i.allowTouchCallbacks&&this.emit("touchMove",l),!(l.targetTouches&&l.targetTouches.length>1)){r.currentX=h,r.currentY=p;var c=r.currentX-r.startX,u=r.currentY-r.startY;if(!(this.params.threshold&&Math.sqrt(Math.pow(c,2)+Math.pow(u,2))<this.params.threshold)){var v;if(void 0===i.isScrolling)this.isHorizontal()&&r.currentY===r.startY||this.isVertical()&&r.currentX===r.startX?i.isScrolling=!1:c*c+u*u>=25&&(v=180*Math.atan2(Math.abs(u),Math.abs(c))/Math.PI,i.isScrolling=this.isHorizontal()?v>a.touchAngle:90-v>a.touchAngle);if(i.isScrolling&&this.emit("touchMoveOpposite",l),void 0===i.startMoving&&(r.currentX===r.startX&&r.currentY===r.startY||(i.startMoving=!0)),i.isScrolling)i.isTouched=!1;else if(i.startMoving){this.allowClick=!1,a.cssMode||l.preventDefault(),a.touchMoveStopPropagation&&!a.nested&&l.stopPropagation(),i.isMoved||(a.loop&&this.loopFix(),i.startTranslate=this.getTranslate(),this.setTransition(0),this.animating&&this.$wrapperEl.trigger("webkitTransitionEnd transitionend"),i.allowMomentumBounce=!1,!a.grabCursor||!0!==this.allowSlideNext&&!0!==this.allowSlidePrev||this.setGrabCursor(!0),this.emit
3559("sliderFirstMove",l)),this.emit("sliderMove",l),i.isMoved=!0;var f=this.isHorizontal()?c:u;r.diff=f,f*=a.touchRatio,o&&(f=-f),this.swipeDirection=f>0?"prev":"next",i.currentTranslate=f+i.startTranslate;var m=!0,g=a.resistanceRatio;if(a.touchReleaseOnEdges&&(g=0),f>0&&i.currentTranslate>this.minTranslate()?(m=!1,a.resistance&&(i.currentTranslate=this.minTranslate()-1+Math.pow(-this.minTranslate()+i.startTranslate+f,g))):f<0&&i.currentTranslate<this.maxTranslate()&&(m=!1,a.resistance&&(i.currentTranslate=this.maxTranslate()+1-Math.pow(this.maxTranslate()-i.startTranslate-f,g))),m&&(l.preventedByNestedSwiper=!0),!this.allowSlideNext&&"next"===this.swipeDirection&&i.currentTranslate<i.startTranslate&&(i.currentTranslate=i.startTranslate),!this.allowSlidePrev&&"prev"===this.swipeDirection&&i.currentTranslate>i.startTranslate&&(i.currentTranslate=i.startTranslate),a.threshold>0){if(!(Math.abs(f)>a.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);if(!i.allowThresholdMove)return i.allowThresholdMove=!0,r.startX=r.currentX,r.startY=r.currentY,i.currentTranslate=i.startTranslate,void(r.diff=this.isHorizontal()?r.currentX-r.startX:r.currentY-r.startY)}a.followFinger&&!a.cssMode&&((a.freeMode||a.watchSlidesProgress||a.watchSlidesVisibility)&&(this.updateActiveIndex(),this.updateSlidesClasses()),a.freeMode&&(0===i.velocities.length&&i.velocities.push({position:r[this.isHorizontal()?"startX":"startY"],time:i.touchStartTime}),i.velocities.push({position:r[this.isHorizontal()?"currentX":"currentY"],time:n.now()})),this.updateProgress(i.currentTranslate),this.setTranslate(i.currentTranslate))}}}}}else i.startMoving&&i.isScrolling&&this.emit("touchMoveOpposite",l)}function A(e){var t=this,i=t.touchEventsData,s=t.params,a=t.touches,r=t.rtlTranslate,o=t.$wrapperEl,l=t.slidesGrid,d=t.snapGrid,h=e;if(h.originalEvent&&(h=h.originalEvent),i.allowTouchCallbacks&&t.emit("touchEnd",h),i.allowTouchCallbacks=!1,!i.isTouched)return i.isMoved&&s.grabCursor&&t.setGrabCursor(!1),i.isMoved=!1,void(i.startMoving=!1);s.grabCursor&&i.isMoved&&i.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);var p,c=n.now(),u=c-i.touchStartTime;if(t.allowClick&&(t.updateClickedSlide(h),t.emit("tap click",h),u<300&&c-i.lastClickTime<300&&t.emit("doubleTap doubleClick",h)),i.lastClickTime=n.now(),n.nextTick((function(){t.destroyed||(t.allowClick=!0)})),!i.isTouched||!i.isMoved||!t.swipeDirection||0===a.diff||i.currentTranslate===i.startTranslate)return i.isTouched=!1,i.isMoved=!1,void(i.startMoving=!1);if(i.isTouched=!1,i.isMoved=!1,i.startMoving=!1,p=s.followFinger?r?t.translate:-t.translate:-i.currentTranslate,!s.cssMode)if(s.freeMode){if(p<-t.minTranslate())return void t.slideTo(t.activeIndex);if(p>-t.maxTranslate())return void(t.slides.length<d.length?t.slideTo(d.length-1):t.slideTo(t.slides.length-1));if(s.freeModeMomentum){if(i.velocities.length>1){var v=i.velocities.pop(),f=i.velocities.pop(),m=v.position-f.position,g=v.time-f.time;t.velocity=m/g,t.velocity/=2,Math.abs(t.velocity)<s.freeModeMinimumVelocity&&(t.velocity=0),(g>150||n.now()-v.time>300)&&(t.velocity=0)}else t.velocity=0;t.velocity*=s.freeModeMomentumVelocityRatio,i.velocities.length=0;var b=1e3*s.freeModeMomentumRatio,w=t.velocity*b,y=t.translate+w;r&&(y=-y);var x,T,E=!1,C=20*Math.abs(t.velocity)*s.freeModeMomentumBounceRatio;if(y<t.maxTranslate())s.freeModeMomentumBounce?(y+t.maxTranslate()<-C&&(y=t.maxTranslate()-C),x=t.maxTranslate(),E=!0,i.allowMomentumBounce=!0):y=t.maxTranslate(),s.loop&&s.centeredSlides&&(T=!0);else if(y>t.minTranslate())s.freeModeMomentumBounce?(y-t.minTranslate()>C&&(y=t.minTranslate()+C),x=t.minTranslate(),E=!0,i.allowMomentumBounce=!0):y=t.minTranslate(),s.loop&&s.centeredSlides&&(T=!0);else if(s.freeModeSticky){for(var S,M=0;M<d.length;M+=1)if(d[M]>-y){S=M;break}y=-(y=Math.abs(d[S]-y)<Math.abs(d[S-1]-y)||"next"===t.swipeDirection?d[S]:d[S-1])}if(T&&t.once("transitionEnd",(function(){t.loopFix()})),0!==t.velocity)b=r?Math.abs((-y-t.translate)/t.velocity):Math.abs((y-t.translate)/t.velocity);else if(s.freeModeSticky)return void t.slideToClosest();s.freeModeMomentumBounce&&E?(t.updateProgress(x),t.setTransition(b),t.setTranslate(y),t.transitionStart(!0,t.swipeDirection),t.animating=!0,o.transitionEnd((function(){t&&!t.destroyed&&i.allowMomentumBounce&&(t.emit("momentumBounce"),t.setTransition(s.speed),t.setTranslate(x),o.transitionEnd((function(){t&&!t.destroyed&&t.transitionEnd()})))}))):t.velocity?(t.updateProgress(y),t.setTransition(b),t.setTranslate(y),t.transitionStart(!0,t.swipeDirection),t.animating||(t.animating=!0,o.transitionEnd((function(){t&&!t.destroyed&&t.transitionEnd()})))):t.updateProgress(y),t.updateActiveIndex(),t.updateSlidesClasses()}else if(s.freeModeSticky)return void t.slideToClosest();(!s.freeModeMomentum||u>=s.longSwipesMs)&&(t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}else{for(var P=0,z=t.slidesSizesGrid[0],k=0;k<l.length;k+=s.slidesPerGroup)void 0!==l[k+s.slidesPerGroup]?p>=l[k]&&p<l[k+s.slidesPerGroup]&&(P=k,z=l[k+s.slidesPerGroup]-l[k]):p>=l[k]&&(P=k,z=l[l.length-1]-l[l.length-2]);var $=(p-l[P])/z;if(u>s.longSwipesMs){if(!s.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&($>=s.longSwipesRatio?t.slideTo(P+s.slidesPerGroup):t.slideTo(P)),"prev"===t.swipeDirection&&($>1-s.longSwipesRatio?t.slideTo(P+s.slidesPerGroup):t.slideTo(P))}else{if(!s.shortSwipes)return void t.slideTo(t.activeIndex);t.navigation&&(h.target===t.navigation.nextEl||h.target===t.navigation.prevEl)?h.target===t.navigation.nextEl?t.slideTo(P+s.slidesPerGroup):t.slideTo(P):("next"===t.swipeDirection&&t.slideTo(P+s.slidesPerGroup),"prev"===t.swipeDirection&&t.slideTo(P))}}}function H(){var e=this.params,t=this.el;if(!t||0!==t.offsetWidth){e.breakpoints&&this.setBreakpoint();var i=this.allowSlideNext,s=this.allowSlidePrev,a=this.snapGrid;if(this.allowSlideNext=!0,this.allowSlidePrev=!0,this.updateSize(),this.updateSlides(),e.freeMode){var r=Math.min(Math.max(this.translate,this.maxTranslate()),this.minTranslate());this.setTranslate(r),this.updateActiveIndex(),this.updateSlidesClasses(),e.autoHeight&&this.updateAutoHeight()}else this.updateSlidesClasses(),("auto"===e.slidesPerView||e.slidesPerView>1)&&this.isEnd&&!this.params.centeredSlides?this.slideTo(this.slides.length-1,0,!1,!0):this.slideTo(this.activeIndex,0,!1,!0);this.autoplay&&this.autoplay.running&&this.autoplay.paused&&this.autoplay.run(),this.allowSlidePrev=s,this.allowSlideNext=i,this.params.watchOverflow&&a!==this.snapGrid&&this.checkOverflow()}}function G(e){this.allowClick||(this.params.preventClicks&&e.preventDefault(),this.params.preventClicksPropagation&&this.animating&&(e.stopPropagation(),e.stopImmediatePropagation()))}function N(){var e=this.wrapperEl;this.previousTranslate=this.translate,this.translate=this.isHorizontal()?-e.scrollLeft:-e.scrollTop,-0===this.translate&&(this.translate=0),this.updateActiveIndex(),this.updateSlidesClasses();var t=this.maxTranslate()-this.minTranslate();(0===t?0:(this.translate-this.minTranslate())/t)!==this.progress&&this.updateProgress(this.translate),this.emit
3559("setTranslate",this.translate,!1)}var B=!1;function V(){}var X={init:!0,direction:"horizontal",touchEventsTarget:"container",initialSlide:0,speed:300,cssMode:!1,preventInteractionOnTransition:!1,edgeSwipeDetection:!1,edgeSwipeThreshold:20,freeMode:!1,freeModeMomentum:!0,freeModeMomentumRatio:1,freeModeMomentumBounce:!0,freeModeMomentumBounceRatio:1,freeModeMomentumVelocityRatio:1,freeModeSticky:!1,freeModeMinimumVelocity:.02,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,spaceBetween:0,slidesPerView:1,slidesPerColumn:1,slidesPerColumnFill:"column",slidesPerGroup:1,centeredSlides:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!1,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,watchSlidesVisibility:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopFillGroupWithBlank:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,containerModifierClass:"swiper-container-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0},Y={update:h,translate:p,transition:c,slide:u,loop:v,grabCursor:f,manipulation:L,events:{attachEvents:function(){var t=this.params,i=this.touchEvents,s=this.el,a=this.wrapperEl;this.onTouchStart=D.bind(this),this.onTouchMove=O.bind(this),this.onTouchEnd=A.bind(this),t.cssMode&&(this.onScroll=N.bind(this)),this.onClick=G.bind(this);var r=!!t.nested;if(!o.touch&&o.pointerEvents)s.addEventListener(i.start,this.onTouchStart,!1),e.addEventListener(i.move,this.onTouchMove,r),e.addEventListener(i.end,this.onTouchEnd,!1);else{if(o.touch){var n=!("touchstart"!==i.start||!o.passiveListener||!t.passiveListeners)&&{passive:!0,capture:!1};s.addEventListener(i.start,this.onTouchStart,n),s.addEventListener(i.move,this.onTouchMove,o.passiveListener?{passive:!1,capture:r}:r),s.addEventListener(i.end,this.onTouchEnd,n),i.cancel&&s.addEventListener(i.cancel,this.onTouchEnd,n),B||(e.addEventListener("touchstart",V),B=!0)}(t.simulateTouch&&!I.ios&&!I.android||t.simulateTouch&&!o.touch&&I.ios)&&(s.addEventListener("mousedown",this.onTouchStart,!1),e.addEventListener("mousemove",this.onTouchMove,r),e.addEventListener("mouseup",this.onTouchEnd,!1))}(t.preventClicks||t.preventClicksPropagation)&&s.addEventListener("click",this.onClick,!0),t.cssMode&&a.addEventListener("scroll",this.onScroll),this.on(I.ios||I.android?"resize orientationchange observerUpdate":"resize observerUpdate",H,!0)},detachEvents:function(){var t=this.params,i=this.touchEvents,s=this.el,a=this.wrapperEl,r=!!t.nested;if(!o.touch&&o.pointerEvents)s.removeEventListener(i.start,this.onTouchStart,!1),e.removeEventListener(i.move,this.onTouchMove,r),e.removeEventListener(i.end,this.onTouchEnd,!1);else{if(o.touch){var n=!("onTouchStart"!==i.start||!o.passiveListener||!t.passiveListeners)&&{passive:!0,capture:!1};s.removeEventListener(i.start,this.onTouchStart,n),s.removeEventListener(i.move,this.onTouchMove,r),s.removeEventListener(i.end,this.onTouchEnd,n),i.cancel&&s.removeEventListener(i.cancel,this.onTouchEnd,n)}(t.simulateTouch&&!I.ios&&!I.android||t.simulateTouch&&!o.touch&&I.ios)&&(s.removeEventListener("mousedown",this.onTouchStart,!1),e.removeEventListener("mousemove",this.onTouchMove,r),e.removeEventListener("mouseup",this.onTouchEnd,!1))}(t.preventClicks||t.preventClicksPropagation)&&s.removeEventListener("click",this.onClick,!0),t.cssMode&&a.removeEventListener("scroll",this.onScroll),this.off(I.ios||I.android?"resize orientationchange observerUpdate":"resize observerUpdate",H)}},breakpoints:{setBreakpoint:function(){var e=this.activeIndex,t=this.initialized,i=this.loopedSlides;void 0===i&&(i=0);var s=this.params,a=this.$el,r=s.breakpoints;
3559if(r&&(!r||0!==Object.keys(r).length)){var o=this.getBreakpoint(r);if(o&&this.currentBreakpoint!==o){var l=o in r?r[o]:void 0;l&&["slidesPerView","spaceBetween","slidesPerGroup","slidesPerColumn"].forEach((function(e){var t=l[e];void 0!==t&&(l[e]="slidesPerView"!==e||"AUTO"!==t&&"auto"!==t?"slidesPerView"===e?parseFloat(t):parseInt(t,10):"auto")}));var d=l||this.originalParams,h=s.slidesPerColumn>1,p=d.slidesPerColumn>1;h&&!p?a.removeClass(s.containerModifierClass+"multirow "+s.containerModifierClass+"multirow-column"):!h&&p&&(a.addClass(s.containerModifierClass+"multirow"),"column"===d.slidesPerColumnFill&&a.addClass(s.containerModifierClass+"multirow-column"));var c=d.direction&&d.direction!==s.direction,u=s.loop&&(d.slidesPerView!==s.slidesPerView||c);c&&t&&this.changeDirection(),n.extend(this.params,d),n.extend(this,{allowTouchMove:this.params.allowTouchMove,allowSlideNext:this.params.allowSlideNext,allowSlidePrev:this.params.allowSlidePrev}),this.currentBreakpoint=o,u&&t&&(this.loopDestroy(),this.loopCreate(),this.updateSlides(),this.slideTo(e-i+this.loopedSlides,0,!1)),this.emit("breakpoint",d)}}},getBreakpoint:function(e){if(e){var i=!1,s=[];Object.keys(e).forEach((function(e){s.push(e)})),s.sort((function(e,t){return parseInt(e,10)-parseInt(t,10)}));for(var a=0;a<s.length;a+=1){var r=s[a];r<=t.innerWidth&&(i=r)}return i||"max"}}},checkOverflow:{checkOverflow:function(){var e=this.isLocked;this.isLocked=1===this.snapGrid.length,this.allowSlideNext=!this.isLocked,this.allowSlidePrev=!this.isLocked,e!==this.isLocked&&this.emit(this.isLocked?"lock":"unlock"),e&&e!==this.isLocked&&(this.isEnd=!1,this.navigation.update())}},classes:{addClasses:function(){var e=this.classNames,t=this.params,i=this.rtl,s=this.$el,a=[];a.push("initialized"),a.push(t.direction),t.freeMode&&a.push("free-mode"),t.autoHeight&&a.push("autoheight"),i&&a.push("rtl"),t.slidesPerColumn>1&&(a.push("multirow"),"column"===t.slidesPerColumnFill&&a.push("multirow-column")),I.android&&a.push("android"),I.ios&&a.push("ios"),t.cssMode&&a.push("css-mode"),a.forEach((function(i){e.push(t.containerModifierClass+i)})),s.addClass(e.join(" "))},removeClasses:function(){var e=this.$el,t=this.classNames;e.removeClass(t.join(" "))}},images:{loadImage:function(e,i,s,a,r,n){var o;function l(){n&&n()}e.complete&&r?l():i?((o=new t.Image).onload=l,o.onerror=l,a&&(o.sizes=a),s&&(o.srcset=s),i&&(o.src=i)):l()},preloadImages:function(){var e=this;function t(){null!=e&&e&&!e.destroyed&&(void 0!==e.imagesLoaded&&(e.imagesLoaded+=1),e.imagesLoaded===e.imagesToLoad.length&&(e.params.updateOnImagesReady&&e.update(),e.emit("imagesReady")))}e.imagesToLoad=e.$el.find("img");for(var i=0;i<e.imagesToLoad.length;i+=1){var s=e.imagesToLoad[i];e.loadImage(s,s.currentSrc||s.getAttribute("src"),s.srcset||s.getAttribute("srcset"),s.sizes||s.getAttribute("sizes"),!0,t)}}}},F={},R=function(e){function t(){for(var i,a,r,l=[],d=arguments.length;d--;)l[d]=arguments[d];1===l.length&&l[0].constructor&&l[0].constructor===Object?r=l[0]:(a=(i=l)[0],r=i[1]),r||(r={}),r=n.extend({},r),a&&!r.el&&(r.el=a),e.call(this,r),Object.keys(Y).forEach((function(e){Object.keys(Y[e]).forEac
3559h((function(i){t.prototype[i]||(t.prototype[i]=Y[e][i])}))}));var h=this;void 0===h.modules&&(h.modules={}),Object.keys(h.modules).forEach((function(e){var t=h.modules[e];if(t.params){var i=Object.keys(t.params)[0],s=t.params[i];if("object"!=typeof s||null===s)return;if(!(i in r&&"enabled"in s))return;!0===r[i]&&(r[i]={enabled:!0}),"object"!=typeof r[i]||"enabled"in r[i]||(r[i].enabled=!0),r[i]||(r[i]={enabled:!1})}}));var p=n.extend({},X);h.useModulesParams(p),h.params=n.extend({},p,F,r),h.originalParams=n.extend({},h.params),h.passedParams=n.extend({},r),h.$=s;var c=s(h.params.el);if(a=c[0]){if(c.length>1){var u=[];return c.each((function(e,i){var s=n.extend({},r,{el:i});u.push(new t(s))})),u}var v,f,m;return a.swiper=h,c.data("swiper",h),a&&a.shadowRoot&&a.shadowRoot.querySelector?(v=s(a.shadowRoot.querySelector("."+h.params.wrapperClass))).children=function(e){return c.children(e)}:v=c.children("."+h.params.wrapperClass),n.extend(h,{$el:c,el:a,$wrapperEl:v,wrapperEl:v[0],classNames:[],slides:s(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:function(){return"horizontal"===h.params.direction},isVertical:function(){return"vertical"===h.params.direction},rtl:"rtl"===a.dir.toLowerCase()||"rtl"===c.css("direction"),rtlTranslate:"horizontal"===h.params.direction&&("rtl"===a.dir.toLowerCase()||"rtl"===c.css("direction")),wrongRTL:"-webkit-box"===v.css("display"),activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,allowSlideNext:h.params.allowSlideNext,allowSlidePrev:h.params.allowSlidePrev,touchEvents:(f=["touchstart","touchmove","touchend","touchcancel"],m=["mousedown","mousemove","mouseup"],o.pointerEvents&&(m=["pointerdown","pointermove","pointerup"]),h.touchEventsTouch={start:f[0],move:f[1],end:f[2],cancel:f[3]},h.touchEventsDesktop={start:m[0],move:m[1],end:m[2]},o.touch||!h.params.simulateTouch?h.touchEventsTouch:h.touchEventsDesktop),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,formElements:"input, select, option, textarea, button, video",lastClickTime:n.now(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:h.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),h.useModules(),h.params.init&&h.init(),h}}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var i={extendedDefaults:{configurable:!0},defaults:{configurable:!0},Class:{configurable:!0},$:{configurable:!0}};return t.prototype.slidesPerViewDynamic=function(){var e=this.params,t=this.slides,i=this.slidesGrid,s=this.size,a=this.activeIndex,r=1;if(e.centeredSlides){for(var n,o=t[a].swiperSlideSize,l=a+1;l<t.length;l+=1)t[l]&&!n&&(r+=1,(o+=t[l].swiperSlideSize)>s&&(n=!0));for(var d=a-1;d>=0;d-=1)t[d]&&!n&&(r+=1,(o+=t[d].swiperSlideSize)>s&&(n=!0))}else for(var h=a+1;h<t.length;h+=1)i[h]-i[a]<s&&(r+=1);return r},t.prototype.update=function(){var e=this;if(e&&!e.destroyed){var t=e.snapGrid,i=e.params;i.breakpoints&&e.setBreakpoint(),e.updateSize(),e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),e.params.freeMode?(s(),e.params.autoHeight&&e.updateAutoHeight()):(("auto"===e.params.slidesPerView||e.params.slidesPerView>1)&&e.isEnd&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0))||s(),i.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}function s(){var t=e.rtlTranslate?-1*e.translate:e.translate,i=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(i),e.updateActiveIndex(),e.updateSlidesClasses()}},t.prototype.changeDirection=function(e,t){void 0===t&&(t=!0);var i=this.params.direction;return e||(e="horizontal"===i?"vertical":"horizontal"),e===i||"horizontal"!==e&&"vertical"!==e?this:(this.$el.removeClass(""+this.params.containerModifierClass+i).addClass(""+this.params.containerModifierClass+e),this.params.direction=e,this.slides.each((function(t,i){"vertical"===e?i.style.width="":i.style.height=""}
3559)),this.emit("changeDirection"),t&&this.update(),this)},t.prototype.init=function(){this.initialized||(this.emit("beforeInit"),this.params.breakpoints&&this.setBreakpoint(),this.addClasses(),this.params.loop&&this.loopCreate(),this.updateSize(),this.updateSlides(),this.params.watchOverflow&&this.checkOverflow(),this.params.grabCursor&&this.setGrabCursor(),this.params.preloadImages&&this.preloadImages(),this.params.loop?this.slideTo(this.params.initialSlide+this.loopedSlides,0,this.params.runCallbacksOnInit):this.slideTo(this.params.initialSlide,0,this.params.runCallbacksOnInit),this.attachEvents(),this.initialized=!0,this.emit("init"))},t.prototype.destroy=function(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);var i=this,s=i.params,a=i.$el,r=i.$wrapperEl,o=i.slides;return void 0===i.params||i.destroyed?null:(i.emit("beforeDestroy"),i.initialized=!1,i.detachEvents(),s.loop&&i.loopDestroy(),t&&(i.removeClasses(),a.removeAttr("style"),r.removeAttr("style"),o&&o.length&&o.removeClass([s.slideVisibleClass,s.slideActiveClass,s.slideNextClass,s.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index")),i.emit("destroy"),Object.keys(i.eventsListeners).forEach((function(e){i.off(e)})),!1!==e&&(i.$el[0].swiper=null,i.$el.data("swiper",null),n.deleteProps(i)),i.destroyed=!0,null)},t.extendDefaults=function(e){n.extend(F,e)},i.extendedDefaults.get=function(){return F},i.defaults.get=function(){return X},i.Class.get=function(){return e},i.$.get=function(){return s},Object.defineProperties(t,i),t}(l),W={name:"device",proto:{device:I},static:{device:I}},q={name:"support",proto:{support:o},static:{support:o}},j={isEdge:!!t.navigator.userAgent.match(/Edge/g),isSafari:function(){var e=t.navigator.userAgent.toLowerCase();return e.indexOf("safari")>=0&&e.indexOf("chrome")<0&&e.indexOf("android")<0}(),isUiWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(t.navigator.userAgent)},K={name:"browser",proto:{browser:j},static:{browser:j}},U={name:"resize",create:function(){var e=this;n.extend(e,{resize:{resizeHandler:function(){e&&!e.destroyed&&e.initialized&&(e.emit("beforeResize"),e.emit("resize"))},orientationChangeHandler:function(){e&&!e.destroyed&&e.initialized&&e.emit("orientationchange")}}})},on:{init:function(){t.addEventListener("resize",this.resize.resizeHandler),t.addEventListener("orientationchange",this.resize.orientationChangeHandler)},destroy:function(){t.removeEventListener("resize",this.resize.resizeHandler),t.removeEventListener("orientationchange",this.resize.orientationChangeHandler)}}},_={func:t.MutationObserver||t.WebkitMutationObserver,attach:function(e,i){void 0===i&&(i={});var s=this,a=new(0,_.func)((function(e){if(1!==e.length){var i=function(){s.emit("observerUpdate",e[0])};t.requestAnimationFrame?t.requestAnimationFrame(i):t.setTimeout(i,0)}else s.emit("observerUpdate",e[0])}));a.observe(e,{attributes:void 0===i.attributes||i.attributes,childList:void 0===i.childList||i.childList,characterData:void 0===i.characterData||i.characterData}),s.observer.observers.push(a)},init:function(){if(o.observer&&this.params.observer){if(this.params.observeParents)for(var e=this.$el.parents(),t=0;t<e.length;t+=1)this.observer.attach(e[t]);this.observer.attach(this.$el[0],{childList:this.params.observeSlideChildren}),this.observer.attach(this.$wrapperEl[0],{attributes:!1})}},destroy:function(){this.observer.observers.forEach((function(e){e.disconnect()})),this.observer.observers=[]}},Z={name:"observer",params:{observer:!1,observeParents:!1,observeSlideChildren:!1},create:function(){n.extend(this,{observer:{init:_.init.bind(this),attach:_.attach.bind(this),destroy:_.destroy.bind(this),observers:[]}})},on:{init:function(){this.observer.init()},destroy:function(){this.observer.destroy()}}},Q={update:function(e){var t=this,i=t.params,s=i.slidesPerView,a=i.slidesPerGroup,r=i.centeredSlides,o=t.params.virtual,l=o.addSlidesBefore,d=o.addSlidesAfter,h=t.virtual,p=h.from,c=h.to,u=h.slides,v=h.slidesGrid,f=h.renderSlide,m=h.offset;t.updateActiveIndex();var g,b,w,y=t.activeIndex||0;g=t.rtlTranslate?"right":t.isHorizontal()?"left":"top",r?(b=Math.floor(s/2)+a+l,w=Math.floor(s/2)+a+d):(b=s+(a-1)+l,w=a+d);var x=Math.max((y||0)-w,0),T=Math.min((y||0)+b,u.length-1),E=(t.slidesGrid[x]||0)-(t.slidesGrid[0]||0);function C(){t.updateSlides(),t.updateProgress(),t.updateSlidesClasses(),t.lazy&&t.params.lazy.enabled&&t.lazy.load()}if(n.extend(t.virtual,{from:x,to:T,offset:E,slidesGrid:t.slidesGrid}),p===x&&c===T&&!e)return t.slidesGrid!==v&&E!==m&&t.slides.css(g,E+"px"),void t.updateProgress();if(t.params.virtual.renderExternal)return t.params.virtual.renderExternal.call(t,{offset:E,from:x,to:T,slides:function(){for(var e=[],t=x;t<=T;t+=1)e.push(u[t]);return e}()}),void C();var S=[],M=[];if(e)t.$wrapperEl.find("."+t.params.slideClass).remove();else for(var P=p;P<=c;P+=1)(P<x||P>T)&&t.$wrapperEl.find("."+t.params.slideClass+'[data-swiper-slide-index="'+P+'"]').remove();for(var z=0;z<u.length;z+=1)z>=x&&z<=T&&(void 0===c||e?M.push(z):(z>c&&M.push(z),z<p&&S.push(z)));M.forEach((function(e){t.$wrapperEl.append(f(u[e],e))})),S.sort((function(e,t){return t-e}
3559)).forEach((function(e){t.$wrapperEl.prepend(f(u[e],e))})),t.$wrapperEl.children(".swiper-slide").css(g,E+"px"),C()},renderSlide:function(e,t){var i=this.params.virtual;if(i.cache&&this.virtual.cache[t])return this.virtual.cache[t];var a=i.renderSlide?s(i.renderSlide.call(this,e,t)):s('<div class="'+this.params.slideClass+'" data-swiper-slide-index="'+t+'">'+e+"</div>");return a.attr("data-swiper-slide-index")||a.attr("data-swiper-slide-index",t),i.cache&&(this.virtual.cache[t]=a),a},appendSlide:function(e){if("object"==typeof e&&"length"in e)for(var t=0;t<e.length;t+=1)e[t]&&this.virtual.slides.push(e[t]);else this.virtual.slides.push(e);this.virtual.update(!0)},prependSlide:function(e){var t=this.activeIndex,i=t+1,s=1;if(Array.isArray(e)){for(var a=0;a<e.length;a+=1)e[a]&&this.virtual.slides.unshift(e[a]);i=t+e.length,s=e.length}else this.virtual.slides.unshift(e);if(this.params.virtual.cache){var r=this.virtual.cache,n={};Object.keys(r).forEach((function(e){var t=r[e],i=t.attr("data-swiper-slide-index");i&&t.attr("data-swiper-slide-index",parseInt(i,10)+1),n[parseInt(e,10)+s]=t})),this.virtual.cache=n}this.virtual.update(!0),this.slideTo(i,0)},removeSlide:function(e){if(null!=e){var t=this.activeIndex;if(Array.isArray(e))for(var i=e.length-1;i>=0;i-=1)this.virtual.slides.splice(e[i],1),this.params.virtual.cache&&delete this.virtual.cache[e[i]],e[i]<t&&(t-=1),t=Math.max(t,0);else this.virtual.slides.splice(e,1),this.params.virtual.cache&&delete this.virtual.cache[e],e<t&&(t-=1),t=Math.max(t,0);this.virtual.update(!0),this.slideTo(t,0)}},removeAllSlides:function(){this.virtual.slides=[],this.params.virtual.cache&&(this.virtual.cache={}),this.virtual.update(!0),this.slideTo(0,0)}},J={name:"virtual",params:{virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null,addSlidesBefore:0,addSlidesAfter:0}},create:function(){n.extend(this,{virtual:{update:Q.update.bind(this),appendSlide:Q.appendSlide.bind(this),prependSlide:Q.prependSlide.bind(this),removeSlide:Q.removeSlide.bind(this),removeAllSlides:Q.removeAllSlides.bind(this),renderSlide:Q.renderSlide.bind(this),slides:this.params.virtual.slides,cache:{}}})},on:{beforeInit:function(){if(this.params.virtual.enabled){this.classNames.push(this.params.containerModifierClass+"virtual");var e={watchSlidesProgress:!0};n.extend(this.params,e),n.extend(this.originalParams,e),this.params.initialSlide||this.virtual.update(
3559)}},setTranslate:function(){this.params.virtual.enabled&&this.virtual.update()}}},ee={handle:function(i){var s=this.rtlTranslate,a=i;a.originalEvent&&(a=a.originalEvent);var r=a.keyCode||a.charCode;if(!this.allowSlideNext&&(this.isHorizontal()&&39===r||this.isVertical()&&40===r||34===r))return!1;if(!this.allowSlidePrev&&(this.isHorizontal()&&37===r||this.isVertical()&&38===r||33===r))return!1;if(!(a.shiftKey||a.altKey||a.ctrlKey||a.metaKey||e.activeElement&&e.activeElement.nodeName&&("input"===e.activeElement.nodeName.toLowerCase()||"textarea"===e.activeElement.nodeName.toLowerCase()))){if(this.params.keyboard.onlyInViewport&&(33===r||34===r||37===r||39===r||38===r||40===r)){var n=!1;if(this.$el.parents("."+this.params.slideClass).length>0&&0===this.$el.parents("."+this.params.slideActiveClass).length)return;var o=t.innerWidth,l=t.innerHeight,d=this.$el.offset();s&&(d.left-=this.$el[0].scrollLeft);for(var h=[[d.left,d.top],[d.left+this.width,d.top],[d.left,d.top+this.height],[d.left+this.width,d.top+this.height]],p=0;p<h.length;p+=1){var c=h[p];c[0]>=0&&c[0]<=o&&c[1]>=0&&c[1]<=l&&(n=!0)}if(!n)return}this.isHorizontal()?(33!==r&&34!==r&&37!==r&&39!==r||(a.preventDefault?a.preventDefault():a.returnValue=!1),(34!==r&&39!==r||s)&&(33!==r&&37!==r||!s)||this.slideNext(),(33!==r&&37!==r||s)&&(34!==r&&39!==r||!s)||this.slidePrev()):(33!==r&&34!==r&&38!==r&&40!==r||(a.preventDefault?a.preventDefault():a.returnValue=!1),34!==r&&40!==r||this.slideNext(),33!==r&&38!==r||this.slidePrev()),this.emit("keyPress",r)}},enable:function(){this.keyboard.enabled||(s(e).on("keydown",this.keyboard.handle),this.keyboard.enabled=!0)},disable:function(){this.keyboard.enabled&&(s(e).off("keydown",this.keyboard.handle),this.keyboard.enabled=!1)}},te={name:"keyboard",params:{keyboard:{enabled:!1,onlyInViewport:!0}},create:function(){n.extend(this,{keyboard:{enabled:!1,enable:ee.enable.bind(this),disable:ee.disable.bind(this),handle:ee.handle.bind(this)}})},on:{init:function(){this.params.keyboard.enabled&&this.keyboard.enable()},destroy:function(){this.keyboard.enabled&&this.keyboard.disable()}}};var ie={lastScrollTime:n.now(),event:function(){return t.navigator.userAgent.indexOf("firefox")>-1?"DOMMouseScroll":function(){var t="onwheel"in e;if(!t){var i=e.createElement("div");i.setAttribute("onwheel","return;"),t="function"==typeof i.onwheel}return!t&&e.implementation&&e.implementation.hasFeature&&!0!==e.implementation.hasFeature("","")&&(t=e.implementation.hasFeature("Events.wheel","3.0")),t}()?"wheel":"mousewheel"},normalize:function(e){var t=0,i=0,s=0,a=0;return"detail"in e&&(i=e.detail),"wheelDelta"in e&&(i=-e.wheelDelta/120),"wheelDeltaY"in e&&(i=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=i,i=0),s=10*t,a=10*i,"deltaY"in e&&(a=e.deltaY),"deltaX"in e&&(s=e.deltaX),e.shiftKey&&!s&&(s=a,a=0),(s||a)&&e.deltaMode&&(1===e.deltaMode?(s*=40,a*=40):(s*=800,a*=800)),s&&!t&&(t=s<1?-1:1),a&&!i&&(i=a<1?-1:1),{spinX:t,spinY:i,pixelX:s,pixelY:a}},handleMouseEnter:function(){this.mouseEntered=!0},handleMouseLeave:function(){this.mouseEntered=!1},handle:function(e){var i=e,s=this,a=s.params.mousewheel;if(s.params.cssMode&&i.preventDefault(),!s.mouseEntered&&!a.releaseOnEdges)return!0;i.originalEvent&&(i=i.originalEvent);var r=0,o=s.rtlTranslate?-1:1,l=ie.normalize(i);if(a.forceToAxis)if(s.isHorizontal()){if(!(Math.abs(l.pixelX)>Math.abs(l.pixelY)))return!0;r=l.pixelX*o}else{if(!(Math.abs(l.pixelY)>Math.abs(l.pixelX)))return!0;r=l.pixelY}else r=Math.abs(l.pixelX)>Math.abs(l.pixelY)?-l.pixelX*o:-l.pixelY;if(0===r)return!0;if(a.invert&&(r=-r),s.params.freeMode){s.params.loop&&s.loopFix();var d=s.getTranslate()+r*a.sensitivity,h=s.isBeginning,p=s.isEnd;if(d>=s.minTranslate()&&(d=s.minTranslate()),d<=s.maxTranslate()&&(d=s.maxTranslate()),s.setTransition(0),s.setTranslate(d),s.updateProgress(),s.updateActiveIndex(),s.updateSlidesClasses(),(!h&&s.isBeginning||!p&&s.isEnd)&&s.updateSlidesClasses(),s.params.freeModeSticky&&(clearTimeout(s.mousewheel.timeout),s.mousewheel.timeout=n.nextTick((function(){s.slideToClosest()}),300)),s.emit("scroll",i),s.params.autoplay&&s.params.autoplayDisableOnInteraction&&s.autoplay.stop(),d===s.minTranslate()||d===s.maxTranslate())return!0}else{if(n.now()-s.mousewheel.lastScrollTime>60)if(r<0)if(s.isEnd&&!s.params.loop||s.animating){if(a.releaseOnEdges)return!0}else s.slideNext(),s.emit("scroll",i);else if(s.isBeginning&&!s.params.loop||s.animating){if(a.releaseOnEdges)return!0}else s.slidePrev(),s.emit("scroll",i);s.mousewheel.lastScrollTime=(new t.Date).getTime()}return i.preventDefault?i.preventDefault():i.returnValue=!1,!1}
3559,enable:function(){var e=ie.event();if(this.params.cssMode)return this.wrapperEl.removeEventListener(e,this.mousewheel.handle),!0;if(!e)return!1;if(this.mousewheel.enabled)return!1;var t=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(t=s(this.params.mousewheel.eventsTarged)),t.on("mouseenter",this.mousewheel.handleMouseEnter),t.on("mouseleave",this.mousewheel.handleMouseLeave),t.on(e,this.mousewheel.handle),this.mousewheel.enabled=!0,!0},disable:function(){var e=ie.event();if(this.params.cssMode)return this.wrapperEl.addEventListener(e,this.mousewheel.handle),!0;if(!e)return!1;if(!this.mousewheel.enabled)return!1;var t=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(t=s(this.params.mousewheel.eventsTarged)),t.off(e,this.mousewheel.handle),this.mousewheel.enabled=!1,!0}},se={update:function(){var e=this.params.navigation;if(!this.params.loop){var t=this.navigation,i=t.$nextEl,s=t.$prevEl;s&&s.length>0&&(this.isBeginning?s.addClass(e.disabledClass):s.removeClass(e.disabledClass),s[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass)),i&&i.length>0&&(this.isEnd?i.addClass(e.disabledClass):i.removeClass(e.disabledClass),i[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass))}},onPrevClick:function(e){e.preventDefault(),this.isBeginning&&!this.params.loop||this.slidePrev()},onNextClick:function(e){e.preventDefault(),this.isEnd&&!this.params.loop||this.slideNext()},init:function(){var e,t,i=this.params.navigation;(i.nextEl||i.prevEl)&&(i.nextEl&&(e=s(i.nextEl),this.params.uniqueNavElements&&"string"==typeof i.nextEl&&e.length>1&&1===this.$el.find(i.nextEl).length&&(e=this.$el.find(i.nextEl))),i.prevEl&&(t=s(i.prevEl),this.params.uniqueNavElements&&"string"==typeof i.prevEl&&t.length>1&&1===this.$el.find(i.prevEl).length&&(t=this.$el.find(i.prevEl))),e&&e.length>0&&e.on("click",this.navigation.onNextClick),t&&t.length>0&&t.on("click",this.navigation.onPrevClick),n.extend(this.navigation,{$nextEl:e,nextEl:e&&e[0],$prevEl:t,prevEl:t&&t[0]}))},destroy:function(){var e=this.navigation,t=e.$nextEl,i=e.$prevEl;t&&t.length&&(t.off("click",this.navigation.onNextClick),t.removeClass(this.params.navigation.disabledClass)),i&&i.length&&(i.off("click",this.navigation.onPrevClick),i.removeClass(this.params.navigation.disabledClass))}},ae={update:function(){var e=this.rtl,t=this.params.pagination;if(t.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var i,a=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,r=this.pagination.$el,n=this.params.loop?Math.ceil((a-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length;if(this.params.loop?((i=Math.ceil((this.activeIndex-this.loopedSlides)/this.params.slidesPerGroup))>a-1-2*this.loopedSlides&&(i-=a-2*this.loopedSlides),i>n-1&&(i-=n),i<0&&"bullets"!==this.params.paginationType&&(i=n+i)):i=void 0!==this.snapIndex?this.snapIndex:this.activeIndex||0,"bullets"===t.type&&this.pagination.bullets&&this.pagination.bullets.length>0){var o,l,d,h=this.pagination.bullets;if(t.dynamicBullets&&(this.pagination.bulletSize=h.eq(0)[this.isHorizontal()?"outerWidth":"outerHeight"](!0),r.css(this.isHorizontal()?"width":"height",this.pagination.bulletSize*(t.dynamicMainBullets+4)+"px"),t.dynamicMainBullets>1&&void 0!==this.previousIndex&&(this.pagination.dynamicBulletIndex+=i-this.previousIndex,this.pagination.dynamicBulletIndex>t.dynamicMainBullets-1?this.pagination.dynamicBulletIndex=t.dynamicMainBullets-1:this.pagination.dynamicBulletIndex<0&&(this.pagination.dynamicBulletIndex=0)),o=i-this.pagination.dynamicBulletIndex,d=((l=o+(Math.min(h.length,t.dynamicMainBullets)-1))+o)/2),h.removeClass(t.bulletActiveClass+" "+t.bulletActiveClass+"-next "+t.bulletActiveClass+"-next-next "+t.bulletActiveClass+"-prev "+t.bulletActiveClass+"-prev-prev "+t.bulletActiveClass+"-main"),r.length>1)h.each((function(e,a){var r=s(a),n=r.index();n===i&&r.addClass(t.bulletActiveClass),t.dynamicBullets&&(n>=o&&n<=l&&r.addClass(t.bulletActiveClass+"-main"),n===o&&r.prev().addClass(t.bulletActiveClass+"-prev").prev().addClass(t.bulletActiveClass+"-prev-prev"),n===l&&r.next().addClass(t.bulletActiveClass+"-next").next().addClass(t.bulletActiveClass+"-next-next"))}));
3559else{var p=h.eq(i),c=p.index();if(p.addClass(t.bulletActiveClass),t.dynamicBullets){for(var u=h.eq(o),v=h.eq(l),f=o;f<=l;f+=1)h.eq(f).addClass(t.bulletActiveClass+"-main");if(this.params.loop)if(c>=h.length-t.dynamicMainBullets){for(var m=t.dynamicMainBullets;m>=0;m-=1)h.eq(h.length-m).addClass(t.bulletActiveClass+"-main");h.eq(h.length-t.dynamicMainBullets-1).addClass(t.bulletActiveClass+"-prev")}else u.prev().addClass(t.bulletActiveClass+"-prev").prev().addClass(t.bulletActiveClass+"-prev-prev"),v.next().addClass(t.bulletActiveClass+"-next").next().addClass(t.bulletActiveClass+"-next-next");else u.prev().addClass(t.bulletActiveClass+"-prev").prev().addClass(t.bulletActiveClass+"-prev-prev"),v.next().addClass(t.bulletActiveClass+"-next").next().addClass(t.bulletActiveClass+"-next-next")}}if(t.dynamicBullets){var g=Math.min(h.length,t.dynamicMainBullets+4),b=(this.pagination.bulletSize*g-this.pagination.bulletSize)/2-d*this.pagination.bulletSize,w=e?"right":"left";h.css(this.isHorizontal()?w:"top",b+"px")}}if("fraction"===t.type&&(r.find("."+t.currentClass).text(t.formatFractionCurrent(i+1)),r.find("."+t.totalClass).text(t.formatFractionTotal(n))),"progressbar"===t.type){var y;y=t.progressbarOpposite?this.isHorizontal()?"vertical":"horizontal":this.isHorizontal()?"horizontal":"vertical";var x=(i+1)/n,T=1,E=1;"horizontal"===y?T=x:E=x,r.find("."+t.progressbarFillClass).transform("translate3d(0,0,0) scaleX("+T+") scaleY("+E+")").transition(this.params.speed)}"custom"===t.type&&t.renderCustom?(r.html(t.renderCustom(this,i+1,n)),this.emit("paginationRender",this,r[0])):this.emit("paginationUpdate",this,r[0]),r[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](t.lockClass)}},render:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,i=this.pagination.$el,s="";if("bullets"===e.type){for(var a=this.params.loop?Math.ceil((t-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length,r=0;r<a;r+=1)e.renderBullet?s+=e.renderBullet.call(this,r,e.bulletClass):s+="<"+e.bulletElement+' class="'+e.bulletClass+'"></'+e.bulletElement+">";i.html(s),this.pagination.bullets=i.find("."+e.bulletClass)}"fraction"===e.type&&(s=e.renderFraction?e.renderFraction.call(this,e.currentClass,e.totalClass):'<span class="'+e.currentClass+'"></span> / <span class="'+e.totalClass+'"></span>',i.html(s)),"progressbar"===e.type&&(s=e.renderProgressbar?e.renderProgressbar.call(this,e.progressbarFillClass):'<span class="'+e.progressbarFillClass+'"></span>',i.html(s)),"custom"!==e.type&&this.emit("paginationRender",this.pagination.$el[0])}},init:function(){var e=this,t=e.params.pagination;if(t.el){var i=s(t.el);0!==i.length&&(e.params.uniqueNavElements&&"string"==typeof t.el&&i.length>1&&1===e.$el.find(t.el).length&&(i=e.$el.find(t.el)),"bullets"===t.type&&t.clickable&&i.addClass(t.clickableClass),i.addClass(t.modifierClass+t.type),"bullets"===t.type&&t.dynamicBullets&&(i.addClass(""+t.modifierClass+t.type+"-dynamic"),e.pagination.dynamicBulletIndex=0,t.dynamicMainBullets<1&&(t.dynamicMainBullets=1)),"progressbar"===t.type&&t.progressbarOpposite&&i.addClass(t.progressbarOppositeClass),t.clickable&&i.on("click","."+t.bulletClass,(function(t){t.preventDefault();var i=s(this).index()*e.params.slidesPerGroup;e.params.loop&&(i+=e.loopedSlides),e.slideTo(i)})),n.extend(e.pagination,{$el:i,el:i[0]}))}},destroy:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.pagination.$el;t.removeClass(e.hiddenClass),t.removeClass(e.modifierClass+e.type),this.pagination.bullets&&this.pagination.bullets.removeClass(e.bulletActiveClass),e.clickable&&t.off("click","."+e.bulletClass)}}},re={setTranslate:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=this.rtlTranslate,i=this.progress,s=e.dragSize,a=e.trackSize,r=e.$dragEl,n=e.$el,o=this.params.scrollbar,l=s,d=(a-s)*i;t?(d=-d)>0?(l=s-d,d=0):-d+s>
3559a&&(l=a+d):d<0?(l=s+d,d=0):d+s>a&&(l=a-d),this.isHorizontal()?(r.transform("translate3d("+d+"px, 0, 0)"),r[0].style.width=l+"px"):(r.transform("translate3d(0px, "+d+"px, 0)"),r[0].style.height=l+"px"),o.hide&&(clearTimeout(this.scrollbar.timeout),n[0].style.opacity=1,this.scrollbar.timeout=setTimeout((function(){n[0].style.opacity=0,n.transition(400)}),1e3))}},setTransition:function(e){this.params.scrollbar.el&&this.scrollbar.el&&this.scrollbar.$dragEl.transition(e)},updateSize:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=e.$dragEl,i=e.$el;t[0].style.width="",t[0].style.height="";var s,a=this.isHorizontal()?i[0].offsetWidth:i[0].offsetHeight,r=this.size/this.virtualSize,o=r*(a/this.size);s="auto"===this.params.scrollbar.dragSize?a*r:parseInt(this.params.scrollbar.dragSize,10),this.isHorizontal()?t[0].style.width=s+"px":t[0].style.height=s+"px",i[0].style.display=r>=1?"none":"",this.params.scrollbar.hide&&(i[0].style.opacity=0),n.extend(e,{trackSize:a,divider:r,moveDivider:o,dragSize:s}),e.$el[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](this.params.scrollbar.lockClass)}},getPointerPosition:function(e){return this.isHorizontal()?"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientX:e.clientX:"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientY:e.clientY},setDragPosition:function(e){var t,i=this.scrollbar,s=this.rtlTranslate,a=i.$el,r=i.dragSize,n=i.trackSize,o=i.dragStartPos;t=(i.getPointerPosition(e)-a.offset()[this.isHorizontal()?"left":"top"]-(null!==o?o:r/2))/(n-r),t=Math.max(Math.min(t,1),0),s&&(t=1-t);var l=this.minTranslate()+(this.maxTranslate()-this.minTranslate())*t;this.updateProgress(l),this.setTranslate(l),this.updateActiveIndex(),this.updateSlidesClasses()},onDragStart:function(e){var t=this.params.scrollbar,i=this.scrollbar,s=this.$wrapperEl,a=i.$el,r=i.$dragEl;this.scrollbar.isTouched=!0,this.scrollbar.dragStartPos=e.target===r[0]||e.target===r?i.getPointerPosition(e)-e.target.getBoundingClientRect()[this.isHorizontal()?"left":"top"]:null,e.preventDefault(),e.stopPropagation(),s.transition(100),r.transition(100),i.setDragPosition(e),clearTimeout(this.scrollbar.dragTimeout),a.transition(0),t.hide&&a.css("opacity",1),this.params.cssMode&&this.$wrapperEl.css("scroll-snap-type","none"),this.emit("scrollbarDragStart",e)},onDragMove:function(e){var t=this.scrollbar,i=this.$wrapperEl,s=t.$el,a=t.$dragEl;this.scrollbar.isTouched&&(e.preventDefault?e.preventDefault():e.returnValue=!1,t.setDragPosition(e),i.transition(0),s.transition(0),a.transition(0),this.emit("scrollbarDragMove",e))},onDragEnd:function(e){var t=this.params.scrollbar,i=this.scrollbar,s=this.$wrapperEl,a=i.$el;this.scrollbar.isTouched&&(this.scrollbar.isTouched=!1,this.params.cssMode&&(this.$wrapperEl.css("scroll-snap-type",""),s.transition("")),t.hide&&(clearTimeout(this.scrollbar.dragTimeout),this.scrollbar.dragTimeout=n.nextTick((function(){a.css("opacity",0),a.transition(400)}),1e3)),this.emit("scrollbarDragEnd",e),t.snapOnRelease&&this.slideToClosest())},enableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,i=this.touchEventsTouch,s=this.touchEventsDesktop,a=this.params,r=t.$el[0],n=!(!o.passiveListener||!a.passiveListeners)&&{passive:!1,capture:!1},l=!(!o.passiveListener||!a.passiveListeners)&&{passive:!0,capture:!1};o.touch?(r.addEventListener(i.start,this.scrollbar.onDragStart,n),r.addEventListener(i.move,this.scrollbar.onDragMove,n),r.addEventListener(i.end,this.scrollbar.onDragEnd,l)):(r.addEventListener(s.start,this.scrollbar.onDragStart,n),e.addEventListener(s.move,this.scrollbar.onDragMove,n),e.addEventListener(s.end,this.scrollbar.onDragEnd,l))}},disableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,i=this.touchEventsTouch,s=this.touchEventsDesktop,a=this.params,r=t.$el[0],n=!(!o.passiveListener||!a.passiveListeners)&&{passive:!1,capture:!1},l=!(!o.passiveListener||!a.passiveListeners)&&{passive:!0,capture:!1};o.touch?(r.removeEventListener(i.start,this.scrollbar.onDragStart,n),r.removeEventListener(i.move,this.scrollbar.onDragMove,n),r.removeEventListener(i.end,this.scrollbar.onDragEnd,l)):(r.removeEventListener(s.start,this.scrollbar.onDragStart,n),e.removeEventListener(s.move,this.scrollbar.onDragMove,n),e.removeEventListener(s.end,this.scrollbar.onDragEnd,l))}},init:function(){if(this.params.scrollbar.el){var e=this.scrollbar,t=this.$el,i=this.params.scrollbar,a=s(i.el);this.params.uniqueNavElements&&"string"==typeof i.el&&a.length>1&&1===t.find(i.el).length&&(a=t.find(i.el));var r=a.find("."+this.params.scrollbar.dragClass);0===r.length&&(r=s('<div class="'+this.params.scrollbar.dragClass+'"></div>'),a.append(r)),n.extend(e,{$el:a,el:a[0],$dragEl:r,dragEl:r[0]}),i.draggable&&e.enableDraggable()}},destroy:function(){this.scrollbar.disableDraggable()}},ne={setTransform:function(e,t){var i=this.rtl,a=s(e),r=i?-1:1,n=a.attr("data-swiper-parallax")||"0",o=a.attr("data-swiper-parallax-x"),l=a.attr("data-swiper-parallax-y"),d=a.attr("data-swiper-parallax-scale"),h=a.attr("data-swiper-parallax-opacity");if(o||l?(o=o||"0",l=l||"0"):this.isHorizontal()?(o=n,l="0"):(l=n,o="0"),o=o.indexOf("%")>=0?parseInt(o,10)*t*r+"%":o*t*r+"px",l=l.indexOf("%")>=0?parseInt(l,10)*t+"%":l*t+"px",null!=h){var p=h-(h-1)*(1-Math.abs(t));a[0].style.opacity=p}if(null==d)a.transform("translate3d("+o+", "+l+", 0px)");else{var c=d-(d-1)*(1-Math.abs(t));a.transform("translate3d("+o+", "+l+", 0px) scale("+c+")")}},setTranslate:function(){var e=this,t=e.$el,i=e.slides,a=e.progress,r=e.snapGrid;t.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((function(t,i){e.parallax.setTransform(i,a)})),i.each((function(t,i){var n=i.progress;e.params.slidesPerGroup>1&&"auto"!==e.params.slidesPerView&&(n+=Math.ceil(t/2)-a*(r.length-1)),n=Math.min(Math.max(n,-1),1),s(i).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((function(t,i){e.parallax.setTransform(i,n)}))}))},setTransition:function(e){void 0===e&&(e=this.params.speed);this.$el.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((function(t,i){var a=s(i),r=parseInt(a.attr("data-swiper-parallax-duration"),10)||e;0===e&&(r=0),a.transition(r)}))}},oe={getDistanceBetweenTouches:function(e){if(e.targetTouches.length<2)return 1;var t=e.targetTouches[0].pageX,i=e.targetTouches[0].pageY,s=e.targetTouches[1].pageX,a=e.targetTouches[1].pageY;return Math.sqrt(Math.pow(s-t,2)+Math.pow(a-i,2))},onGestureStart:function(e){var t=this.params.zoom,i=this.zoom,a=i.gesture;if(i.fakeGestureTouched=!1,i.fakeGestureMoved=!1,!o.gestures){if("touchstart"!==e.type||"touchstart"===e.type&&e.targetTouches.length<2)return;i.fakeGestureTouched=!0,a.scaleStart=oe.getDistanceBetweenTouches(e)}a.$slideEl&&a.$slideEl.length||(a.$slideEl=s(e.target).closest(".swiper-slide"),0===a.$slideEl.length&&(a.$slideEl=this.slides.eq(this.activeIndex)),a.$imageEl=a.$slideEl.find("img, svg, canvas"),a.$imageWrapEl=a.$imageEl.parent("."+t.containerClass),a.maxRatio=a.$imageWrapEl.attr("data-swiper-zoom")||t.maxRatio,0!==a.$imageWrapEl.length)?(a.$imageEl.transition(0),this.zoom.isScaling=!0):a.$imageEl=void 0},onGestureChange:function(e){var t=this.params.zoom,i=this.zoom,s=i.gesture;if(!o.gestures){if("touchmove"!==e.type||"touchmove"===e.type&&e.targetTouches.length<2)return;i.fakeGestureMoved=!0,s.scaleMove=oe.getDistanceBetweenTouches(e)}s.$imageEl&&0!==s.$imageEl.length&&(o.gestures?i.scale=e.scale*i.currentScale:i.scale=s.scaleMove/s.scaleStart*i.currentScale,i.scale>s.maxRatio&&(i.scale=s.maxRatio-1+Math.pow(i.scale-s.maxRatio+1,.5)),i.scale<t.minRatio&&(i.scale=t.minRatio+1-Math.pow(t.minRatio-i.scale+1,.5)),s.$imageEl.transform("translate3d(0,
35590,0) scale("+i.scale+")"))},onGestureEnd:function(e){var t=this.params.zoom,i=this.zoom,s=i.gesture;if(!o.gestures){if(!i.fakeGestureTouched||!i.fakeGestureMoved)return;if("touchend"!==e.type||"touchend"===e.type&&e.changedTouches.length<2&&!I.android)return;i.fakeGestureTouched=!1,i.fakeGestureMoved=!1}s.$imageEl&&0!==s.$imageEl.length&&(i.scale=Math.max(Math.min(i.scale,s.maxRatio),t.minRatio),s.$imageEl.transition(this.params.speed).transform("translate3d(0,0,0) scale("+i.scale+")"),i.currentScale=i.scale,i.isScaling=!1,1===i.scale&&(s.$slideEl=void 0))},onTouchStart:function(e){var t=this.zoom,i=t.gesture,s=t.image;i.$imageEl&&0!==i.$imageEl.length&&(s.isTouched||(I.android&&e.preventDefault(),s.isTouched=!0,s.touchesStart.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,s.touchesStart.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY))},onTouchMove:function(e){var t=this.zoom,i=t.gesture,s=t.image,a=t.velocity;if(i.$imageEl&&0!==i.$imageEl.length&&(this.allowClick=!1,s.isTouched&&i.$slideEl)){s.isMoved||(s.width=i.$imageEl[0].offsetWidth,s.height=i.$imageEl[0].offsetHeight,s.startX=n.getTranslate(i.$imageWrapEl[0],"x")||0,s.startY=n.getTranslate(i.$imageWrapEl[0],"y")||0,i.slideWidth=i.$slideEl[0].offsetWidth,i.slideHeight=i.$slideEl[0].offsetHeight,i.$imageWrapEl.transition(0),this.rtl&&(s.startX=-s.startX,s.startY=-s.startY));var r=s.width*t.scale,o=s.height*t.scale;if(!(r<i.slideWidth&&o<i.slideHeight)){if(s.minX=Math.min(i.slideWidth/2-r/2,0),s.maxX=-s.minX,s.minY=Math.min(i.slideHeight/2-o/2,0),s.maxY=-s.minY,s.touchesCurrent.x="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,s.touchesCurrent.y="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,!s.isMoved&&!t.isScaling){if(this.isHorizontal()&&(Math.floor(s.minX)===Math.floor(s.startX)&&s.touchesCurrent.x<s.touchesStart.x||Math.floor(s.maxX)===Math.floor(s.startX)&&s.touchesCurrent.x>s.touchesStart.x))return void(s.isTouched=!1);if(!this.isHorizontal()&&(Math.floor(s.minY)===Math.floor(s.startY)&&s.touchesCurrent.y<s.touchesStart.y||Math.floor(s.maxY)===Math.floor(s.startY)&&s.touchesCurrent.y>s.touchesStart.y))return void(s.isTouched=!1)}e.preventDefault(),e.stopPropagation(),s.isMoved=!0,s.currentX=s.touchesCurrent.x-s.touchesStart.x+s.startX,s.currentY=s.touchesCurrent.y-s.touchesStart.y+s.startY,s.currentX<s.minX&&(s.currentX=s.minX+1-Math.pow(s.minX-s.currentX+1,.8)),s.currentX>s.maxX&&(s.currentX=s.maxX-1+Math.pow(s.currentX-s.maxX+1,.8)),s.currentY<s.minY&&(s.currentY=s.minY+1-Math.pow(s.minY-s.currentY+1,.8)),s.currentY>s.maxY&&(s.currentY=s.maxY-1+Math.pow(s.currentY-s.maxY+1,.8)),a.prevPositionX||(a.prevPositionX=s.touchesCurrent.x),a.prevPositionY||(a.prevPositionY=s.touchesCurrent.y),a.prevTime||(a.prevTime=Date.now()),a.x=(s.touchesCurrent.x-a.prevPositionX)/(Date.now()-a.prevTime)/2,a.y=(s.touchesCurrent.y-a.prevPositionY)/(Date.now()-a.prevTime)/2,Math.abs(s.touchesCurrent.x-a.prevPositionX)<2&&(a.x=0),Math.abs(s.touchesCurrent.y-a.prevPositionY)<2&&(a.y=0),a.prevPositionX=s.touchesCurrent.x,a.prevPositionY=s.touchesCurrent.y,a.prevTime=Date.now(),i.$imageWrapEl.transform("translate3d("+s.currentX+"px, "+s.currentY+"px,0)")}}},onTouchEnd:function(){var e=this.zoom,t=e.gesture,i=e.image,s=e.velocity;if(t.$imageEl&&0!==t.$imageEl.length){if(!i.isTouched||!i.isMoved)return i.isTouched=!1,void(i.isMoved=!1);i.isTouched=!1,i.isMoved=!1;var a=300,r=300,n=s.x*a,o=i.currentX+n,l=s.y*r,d=i.currentY+l;0!==s.x&&(a=Math.abs((o-i.currentX)/s.x)),0!==s.y&&(r=Math.abs((d-i.currentY)/s.y));var h=Math.max(a,r);i.currentX=o,i.currentY=d;var p=i.width*e.scale,c=i.height*e.scale;i.minX=Math.min(t.slideWidth/2-p/2,0),i.maxX=-i.minX,i.minY=Math.min(t.slideHeight/2-c/2,0),i.maxY=-i.minY,i.currentX=Math.max(Math.min(i.currentX,i.maxX),i.minX),i.currentY=Math.max(Math.min(i.currentY,i.maxY),i.minY),t.$imageWrapEl.transition(h).transform("translate3d("+i.currentX+"px, "+i.currentY+"px,0)")}},onTransitionEnd:function(){var e=this.zoom,t=e.gesture;t.$slideEl&&this.previousIndex!==this.activeIndex&&(t.$imageEl.transform("translate3d(0,0,0) scale(1)"),t.$imageWrapEl.transform("translate3d(0,
35590,0)"),e.scale=1,e.currentScale=1,t.$slideEl=void 0,t.$imageEl=void 0,t.$imageWrapEl=void 0)},toggle:function(e){var t=this.zoom;t.scale&&1!==t.scale?t.out():t.in(e)},in:function(e){var t,i,a,r,n,o,l,d,h,p,c,u,v,f,m,g,b=this.zoom,w=this.params.zoom,y=b.gesture,x=b.image;(y.$slideEl||(y.$slideEl=this.clickedSlide?s(this.clickedSlide):this.slides.eq(this.activeIndex),y.$imageEl=y.$slideEl.find("img, svg, canvas"),y.$imageWrapEl=y.$imageEl.parent("."+w.containerClass)),y.$imageEl&&0!==y.$imageEl.length)&&(y.$slideEl.addClass(""+w.zoomedSlideClass),void 0===x.touchesStart.x&&e?(t="touchend"===e.type?e.changedTouches[0].pageX:e.pageX,i="touchend"===e.type?e.changedTouches[0].pageY:e.pageY):(t=x.touchesStart.x,i=x.touchesStart.y),b.scale=y.$imageWrapEl.attr("data-swiper-zoom")||w.maxRatio,b.currentScale=y.$imageWrapEl.attr("data-swiper-zoom")||w.maxRatio,e?(m=y.$slideEl[0].offsetWidth,g=y.$slideEl[0].offsetHeight,a=y.$slideEl.offset().left+m/2-t,r=y.$slideEl.offset().top+g/2-i,l=y.$imageEl[0].offsetWidth,d=y.$imageEl[0].offsetHeight,h=l*b.scale,p=d*b.scale,v=-(c=Math.min(m/2-h/2,0)),f=-(u=Math.min(g/2-p/2,0)),(n=a*b.scale)<c&&(n=c),n>v&&(n=v),(o=r*b.scale)<u&&(o=u),o>f&&(o=f)):(n=0,o=0),y.$imageWrapEl.transition(300).transform("translate3d("+n+"px, "+o+"px,0)"),y.$imageEl.transition(300).transform("translate3d(0,0,0) scale("+b.scale+")"))},out:function(){var e=this.zoom,t=this.params.zoom,i=e.gesture;i.$slideEl||(i.$slideEl=this.clickedSlide?s(this.clickedSlide):this.slides.eq(this.activeIndex),i.$imageEl=i.$slideEl.find("img, svg, canvas"),i.$imageWrapEl=i.$imageEl.parent("."+t.containerClass)),i.$imageEl&&0!==i.$imageEl.length&&(e.scale=1,e.currentScale=1,i.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),i.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),i.$slideEl.removeClass(""+t.zoomedSlideClass),i.$slideEl=void 0)},enable:function(){var e=this.zoom;if(!e.enabled){e.enabled=!0;var t=!("touchstart"!==this.touchEvents.start||!o.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1},i=!o.passiveListener||{passive:!1,capture:!0};o.gestures?(this.$wrapperEl.on("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.on("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.on(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on(this.touchEvents.move,".swiper-slide",e.onGestureChange,i),this.$wrapperEl.on(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t),this.touchEvents.cancel&&this.$wrapperEl.on(this.touchEvents.cancel,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.on(this.touchEvents.move,"."+this.params.zoom.containerClass,e.onTouchMove,i)}},disable:function(){var e=this.zoom;if(e.enabled){this.zoom.enabled=!1;var t=!("touchstart"!==this.touchEvents.start||!o.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1},i=!o.passiveListener||{passive:!1,capture:!0};o.gestures?(this.$wrapperEl.off("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.off("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.off(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off(this.touchEvents.move,".swiper-slide",e.onGestureChange,i),this.$wrapperEl.off(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t),this.touchEvents.cancel&&this.$wrapperEl.off(this.touchEvents.cancel,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.off(this.touchEvents.move,"."+this.params.zoom.containerClass,e.onTouchMove,i)}}},le={loadInSlide:function(e,t){void 0===t&&(t=!0);var i=this,a=i.params.lazy;if(void 0!==e&&0!==i.slides.length){var r=i.virtual&&i.params.virtual.enabled?i.$wrapperEl.children("."+i.params.slideClass+'[data-swiper-slide-index="'+e+'"]'):i.slides.eq(e),n=r.find("."+a.elementClass+":not(."+a.loadedClass+"):not(."+a.loadingClass+")");!r.hasClass(a.elementClass)||r.hasClass(a.loadedClass)||r.hasClass(a.loadingClass)||(n=n.add(r[0])),0!==n.length&&n.each((function(e,n){var o=s(n);o.addClass(a.loadingClass);var l=o.attr("data-background"),d=o.attr("data-src"),h=o.attr("data-srcset"),p=o.attr("data-sizes");i.loadImage(o[0],d||l,h,p,!1,(function(){if(null!=i&&i&&(!i||i.params)&&!i.destroyed){
3559if(l?(o.css("background-image",'url("'+l+'")'),o.removeAttr("data-background")):(h&&(o.attr("srcset",h),o.removeAttr("data-srcset")),p&&(o.attr("sizes",p),o.removeAttr("data-sizes")),d&&(o.attr("src",d),o.removeAttr("data-src"))),o.addClass(a.loadedClass).removeClass(a.loadingClass),r.find("."+a.preloaderClass).remove(),i.params.loop&&t){var e=r.attr("data-swiper-slide-index");if(r.hasClass(i.params.slideDuplicateClass)){var s=i.$wrapperEl.children('[data-swiper-slide-index="'+e+'"]:not(.'+i.params.slideDuplicateClass+")");i.lazy.loadInSlide(s.index(),!1)}else{var n=i.$wrapperEl.children("."+i.params.slideDuplicateClass+'[data-swiper-slide-index="'+e+'"]');i.lazy.loadInSlide(n.index(),!1)}}i.emit("lazyImageReady",r[0],o[0])}})),i.emit("lazyImageLoad",r[0],o[0])}))}},load:function(){var e=this,t=e.$wrapperEl,i=e.params,a=e.slides,r=e.activeIndex,n=e.virtual&&i.virtual.enabled,o=i.lazy,l=i.slidesPerView;function d(e){if(n){if(t.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]').length)return!0}else if(a[e])return!0;return!1}function h(e){return n?s(e).attr("data-swiper-slide-index"):s(e).index()}if("auto"===l&&(l=0),e.lazy.initialImageLoaded||(e.lazy.initialImageLoaded=!0),e.params.watchSlidesVisibility)t.children("."+i.slideVisibleClass).each((function(t,i){var a=n?s(i).attr("data-swiper-slide-index"):s(i).index();e.lazy.loadInSlide(a)}));else if(l>1)for(var p=r;p<r+l;p+=1)d(p)&&e.lazy.loadInSlide(p);else e.lazy.loadInSlide(r);if(o.loadPrevNext)if(l>1||o.loadPrevNextAmount&&o.loadPrevNextAmount>1){for(var c=o.loadPrevNextAmount,u=l,v=Math.min(r+u+Math.max(c,u),a.length),f=Math.max(r-Math.max(u,c),0),m=r+l;m<v;m+=1)d(m)&&e.lazy.loadInSlide(m);for(var g=f;g<r;g+=1)d(g)&&e.lazy.loadInSlide(g)}else{var b=t.children("."+i.slideNextClass);b.length>0&&e.lazy.loadInSlide(h(b));var w=t.children("."+i.slidePrevClass);w.length>0&&e.lazy.loadInSlide(h(w))}}},de={LinearSpline:function(e,t){var i,s,a,r,n,o=function(e,t){for(s=-1,i=e.length;i-s>1;)e[a=i+s>>1]<=t?s=a:i=a;return i};return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(n=o(this.x,e),r=n-1,(e-this.x[r])*(this.y[n]-this.y[r])/(this.x[n]-this.x[r])+this.y[r]):0},this},getInterpolateFunction:function(e){this.controller.spline||(this.controller.spline=this.params.loop?new de.LinearSpline(this.slidesGrid,e.slidesGrid):new de.LinearSpline(this.snapGrid,e.snapGrid))},setTranslate:function(e,t){var i,s,a=this,r=a.controller.control;function n(e){var t=a.rtlTranslate?-a.translate:a.translate;"slide"===a.params.controller.by&&(a.controller.getInterpolateFunction(e),s=-a.controller.spline.interpolate(-t)),s&&"container"!==a.params.controller.by||(i=(e.maxTranslate()-e.minTranslate())/(a.maxTranslate()-a.minTranslate()),s=(t-a.minTranslate())*i+e.minTranslate()),a.params.controller.inverse&&(s=e.maxTranslate()-s),e.updateProgress(s),e.setTranslate(s,a),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(r))for(var o=0;o<r.length;o+=1)r[o]!==t&&r[o]instanceof R&&n(r[o]);else r instanceof R&&t!==r&&n(r)},setTransition:function(e,t){var i,s=this,a=s.controller.control;function r(t){t.setTransition(e,s),0!==e&&(t.transitionStart(),t.params.autoHeight&&n.nextTick((function(){t.updateAutoHeight()})),t.$wrapperEl.transitionEnd((function(){a&&(t.params.loop&&"slide"===s.params.controller.by&&t.loopFix(),t.transitionEnd())})))}if(Array.isArray(a))for(i=0;i<a.length;i+=1)a[i]!==t&&a[i]instanceof R&&r(a[i]);else a instanceof R&&t!==a&&r(a)}},he={makeElFocusable:function(e){return e.attr("tabIndex","0"),e},addElRole:function(e,t){return e.attr("role",t),e},addElLabel:function(e,t){return e.attr("aria-label",t),e},disableEl:function(e){return e.attr("aria-disabled",!0),e},enableEl:function(e){return e.attr("aria-disabled",!1),e},onEnterKey:function(e){var t=this.params.a11y;if(13===e.keyCode){var i=s(e.target);this.navigation&&this.navigation.$nextEl&&i.is(this.navigation.$nextEl)&&(this.isEnd&&!this.params.loop||this.slideNext(),this.isEnd?this.a11y.notify(t.lastSlideMessage):this.a11y.notify(t.nextSlideMessage)),this.navigation&&this.navigation.$prevEl&&i.is(this.navigation.$prevEl)&&(this.isBeg
3559inning&&!this.params.loop||this.slidePrev(),this.isBeginning?this.a11y.notify(t.firstSlideMessage):this.a11y.notify(t.prevSlideMessage)),this.pagination&&i.is("."+this.params.pagination.bulletClass)&&i[0].click()}},notify:function(e){var t=this.a11y.liveRegion;0!==t.length&&(t.html(""),t.html(e))},updateNavigation:function(){if(!this.params.loop){var e=this.navigation,t=e.$nextEl,i=e.$prevEl;i&&i.length>0&&(this.isBeginning?this.a11y.disableEl(i):this.a11y.enableEl(i)),t&&t.length>0&&(this.isEnd?this.a11y.disableEl(t):this.a11y.enableEl(t))}},updatePagination:function(){var e=this,t=e.params.a11y;e.pagination&&e.params.pagination.clickable&&e.pagination.bullets&&e.pagination.bullets.length&&e.pagination.bullets.each((function(i,a){var r=s(a);e.a11y.makeElFocusable(r),e.a11y.addElRole(r,"button"),e.a11y.addElLabel(r,t.paginationBulletMessage.replace(/{{index}}/,r.index()+1))}))},init:function(){this.$el.append(this.a11y.liveRegion);var e,t,i=this.params.a11y;this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&(this.a11y.makeElFocusable(e),this.a11y.addElRole(e,"button"),this.a11y.addElLabel(e,i.nextSlideMessage),e.on("keydown",this.a11y.onEnterKey)),t&&(this.a11y.makeElFocusable(t),this.a11y.addElRole(t,"button"),this.a11y.addElLabel(t,i.prevSlideMessage),t.on("keydown",this.a11y.onEnterKey)),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.on("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)},destroy:function(){var e,t;this.a11y.liveRegion&&this.a11y.liveRegion.length>0&&this.a11y.liveRegion.remove(),this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&e.off("keydown",this.a11y.onEnterKey),t&&t.off("keydown",this.a11y.onEnterKey),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.off("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)}},pe={init:function(){if(this.params.history){if(!t.history||!t.history.pushState)return this.params.history.enabled=!1,void(this.params.hashNavigation.enabled=!0);var e=this.history;e.initialized=!0,e.paths=pe.getPathValues(),(e.paths.key||e.paths.value)&&(e.scrollToSlide(0,e.paths.value,this.params.runCallbacksOnInit),this.params.history.replaceState||t.addEventListener("popstate",this.history.setHistoryPopState))}},destroy:function(){this.params.history.replaceState||t.removeEventListener("popstate",this.history.setHistoryPopState)},setHistoryPopState:function(){this.history.paths=pe.getPathValues(),this.history.scrollToSlide(this.params.speed,this.history.paths.value,!1)},getPathValues:function(){var e=t.location.pathname.slice(1).split("/").filter((function(e){return""!==e})),i=e.length;return{key:e[i-2],value:e[i-1]}},setHistory:function(e,i){if(this.history.initialized&&this.params.history.enabled){var s=this.slides.eq(i),a=pe.slugify(s.attr("data-history"));t.location.pathname.includes(e)||(a=e+"/"+a);var r=t.history.state;r&&r.value===a||(this.params.history.replaceState?t.history.replaceState({value:a},null,a):t.history.pushState({value:a},null,a))}},slugify:function(e){return e.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,"")},scrollToSlide:function(e,t,i){if(t)for(var s=0,a=this.slides.length;s<a;s+=1){var r=this.slides.eq(s);if(pe.slugify(r.attr("data-history"))===t&&!r.hasClass(this.params.slideDuplicateClass)){var n=r.index();this.slideTo(n,e,i)}}else this.slideTo(0,e,i)}},ce={onHashCange:function(){var t=e.location.hash.replace("#","");if(t!==this.slides.eq(this.activeIndex).attr("data-hash")){var i=this.$wrapperEl.children("."+this.params.slideClass+'[data-hash="'+t+'"]').index();if(void 0===i)return;this.slideTo(i)}},setHash:function(){if(this.hashNavigation.initialized&&this.params.hashNavigation.enabled)if(this.params.hashNavigation.replaceState&&t.history&&t.history.replaceState)t.history.replaceState(null,null,"#"+this.slides.eq(this.activeIndex).attr("data-hash")||"");else{var i=this.slides.eq(this.activeIndex),s=i.attr("data-hash")||i.attr("data-history");e.location.hash=s||""}},init:function(){if(!(!this.params.hashNavigation.enabled||this.params.history&&this.params.history.enabled)){this.hashNavigation.initialized=!0;var i=e.location.hash.replace("#","");if(i)for(var a=0,r=this.slides.length;a<r;a+=1){var n=this.slides.eq(a);if((n.attr("data-hash")||n.attr("data-history"))===i&&!n.hasClass(this.params.slideDuplicateClass)){var o=n.index();this.slideTo(o,0,this.params.runCallbacksOnInit,!0)}}this.params.hashNavigation.watchState&&s(t).on("hashchange",this.hashNavigation.onHashCange)}},destroy:function(){this.params.hashNavigation.watchState&&s(t).off("hashchange",this.hashNavigation.onHashCange)}},ue={run:function(){var e=this,t=e.slides.eq(e.activeIndex),i=e.params.autoplay.delay;t.attr("data-swiper-autoplay")&&(i=t.attr("data-swiper-autoplay")||e.params.autoplay.delay),clearTimeout(e.autoplay.timeout),e.autoplay.timeout=n.nextTick((function(){e.params.autoplay.reverseDirection?e.params.loop?(e.loopFix(),e.slidePrev(e.params.speed,!0,
3559!0),e.emit("autoplay")):e.isBeginning?e.params.autoplay.stopOnLastSlide?e.autoplay.stop():(e.slideTo(e.slides.length-1,e.params.speed,!0,!0),e.emit("autoplay")):(e.slidePrev(e.params.speed,!0,!0),e.emit("autoplay")):e.params.loop?(e.loopFix(),e.slideNext(e.params.speed,!0,!0),e.emit("autoplay")):e.isEnd?e.params.autoplay.stopOnLastSlide?e.autoplay.stop():(e.slideTo(0,e.params.speed,!0,!0),e.emit("autoplay")):(e.slideNext(e.params.speed,!0,!0),e.emit("autoplay")),e.params.cssMode&&e.autoplay.running&&e.autoplay.run()}),i)},start:function(){return void 0===this.autoplay.timeout&&(!this.autoplay.running&&(this.autoplay.running=!0,this.emit("autoplayStart"),this.autoplay.run(),!0))},stop:function(){return!!this.autoplay.running&&(void 0!==this.autoplay.timeout&&(this.autoplay.timeout&&(clearTimeout(this.autoplay.timeout),this.autoplay.timeout=void 0),this.autoplay.running=!1,this.emit("autoplayStop"),!0))},pause:function(e){this.autoplay.running&&(this.autoplay.paused||(this.autoplay.timeout&&clearTimeout(this.autoplay.timeout),this.autoplay.paused=!0,0!==e&&this.params.autoplay.waitForTransition?(this.$wrapperEl[0].addEventListener("transitionend",this.autoplay.onTransitionEnd),this.$wrapperEl[0].addEventListener("webkitTransitionEnd",this.autoplay.onTransitionEnd)):(this.autoplay.paused=!1,this.autoplay.run())))}},ve={setTranslate:function(){for(var e=this.slides,t=0;t<e.length;t+=1){var i=this.slides.eq(t),s=-i[0].swiperSlideOffset;this.params.virtualTranslate||(s-=this.translate);var a=0;this.isHorizontal()||(a=s,s=0);var r=this.params.fadeEffect.crossFade?Math.max(1-Math.abs(i[0].progress),0):1+Math.min(Math.max(i[0].progress,-1),0);i.css({opacity:r}).transform("translate3d("+s+"px, "+a+"px, 0px)")}},setTransition:function(e){var t=this,i=t.slides,s=t.$wrapperEl;if(i.transition(e),t.params.virtualTranslate&&0!==e){var a=!1;i.transitionEnd((function(){if(!a&&t&&!t.destroyed){a=!0,t.animating=!1;for(var e=["webkitTransitionEnd","transitionend"],i=0;i<e.length;i+=1)s.trigger(e[i])}}))}}},fe={setTranslate:function(){var e,t=this.$el,i=this.$wrapperEl,a=this.slides,r=this.width,n=this.height,o=this.rtlTranslate,l=this.size,d=this.params.cubeEffect,h=this.isHorizontal(),p=this.virtual&&this.params.virtual.enabled,c=0;d.shadow&&(h?(0===(e=i.find(".swiper-cube-shadow")).length&&(e=s('<div class="swiper-cube-shadow"></div>'),i.append(e)),e.css({height:r+"px"})):0===(e=t.find(".swiper-cube-shadow")).length&&(e=s('<div class="swiper-cube-shadow"></div>'),t.append(e)));for(var u=0;u<a.length;u+=1){var v=a.eq(u),f=u;p&&(f=parseInt(v.attr("data-swiper-slide-index"),10));var m=90*f,g=Math.floor(m/360);o&&(m=-m,g=Math.floor(-m/360));var b=Math.max(Math.min(v[0].progress,1),-1),w=0,y=0,x=0;f%4==0?(w=4*-g*l,x=0):(f-1)%4==0?(w=0,x=4*-g*l):(f-2)%4==0?(w=l+4*g*l,x=l):(f-3)%4==0&&(w=-l,x=3*l+4*l*g),o&&(w=-w),h||(y=w,w=0);var T="rotateX("+(h?0:-m)+"deg) rotateY("+(h?m:0)+"deg) translate3d("+w+"px, "+y+"px, "+x+"px)";if(b<=1&&b>-1&&(c=90*f+90*b,o&&(c=90*-f-90*b)),v.transform(T),d.slideShadows){var E=h?v.find(".swiper-slide-shadow-left"):v.find(".swiper-slide-shadow-top"),C=h?v.find(".swiper-slide-shadow-right"):v.find(".swiper-slide-shadow-bottom");0===E.length&&(E=s('<div class="swiper-slide-shadow-'+(h?"left":"top")+'"></div>'),v.append(E)),0===C.length&&(C=s('<div class="swiper-slide-shadow-'+(h?"right":"bottom")+'"></div>'),v.append(C)),E.length&&(E[0].style.opacity=Math.max(-b,0)),C.length&&(C[0].style.opacity=Math.max(b,0))}}if(i.css({"-webkit-transform-origin":"50% 50% -"+l/2+"px","-moz-transform-origin":"50% 50% -"+l/2+"px","-ms-transform-origin":"50% 50% -"+l/2+"px","transform-origin":"50% 50% -"+l/2+"px"}),d.shadow)if(h)e.transform("translate3d(0px, "+(r/2+d.shadowOffset)+"px, "+-r/2+"px) rotateX(90deg) rotateZ(0deg) scale("+d.shadowScale+")");else{var S=Math.abs(c)-90*Math.floor(Math.abs(c)/90),M=1.5-(Math.sin(2*S*Math.PI/360)/2+Math.cos(2*S*Math.PI/360)/2),P=d.shadowScale,z=d.shadowScale/M,k=d.shadowOffset;e.transform("scale3d("+P+", 1, "+z+") translate3d(0px, "+(n/2+k)+"px, "+-n/2/z+"px) rotateX(-90deg)")}var $=j.isSafari||j.isUiWebView?-l/2:0;i.transform("translate3d(0px,0,"+$+"px) rotateX("+(this.isHorizontal()?0:c)+"deg) rotateY("+(this.isHorizontal()?-c:0)+"deg)")},setTransition:function(e){var t=this.$el;this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),this.params.cubeEffect.shadow&&!this.isHorizontal()&&t.find(".swiper-cube-shadow").transition(e)}},me={setTranslate:function(){for(var e=this.slides,t=this.rtlTranslate,i=0;i<e.length;i+=1){var a=e.eq(i),r=a[0].progress;this.params.flipEffect.limitRotation&&(r=Math.max(Math.min(a[0].progress,
35591),-1));var n=-180*r,o=0,l=-a[0].swiperSlideOffset,d=0;if(this.isHorizontal()?t&&(n=-n):(d=l,l=0,o=-n,n=0),a[0].style.zIndex=-Math.abs(Math.round(r))+e.length,this.params.flipEffect.slideShadows){var h=this.isHorizontal()?a.find(".swiper-slide-shadow-left"):a.find(".swiper-slide-shadow-top"),p=this.isHorizontal()?a.find(".swiper-slide-shadow-right"):a.find(".swiper-slide-shadow-bottom");0===h.length&&(h=s('<div class="swiper-slide-shadow-'+(this.isHorizontal()?"left":"top")+'"></div>'),a.append(h)),0===p.length&&(p=s('<div class="swiper-slide-shadow-'+(this.isHorizontal()?"right":"bottom")+'"></div>'),a.append(p)),h.length&&(h[0].style.opacity=Math.max(-r,0)),p.length&&(p[0].style.opacity=Math.max(r,0))}a.transform("translate3d("+l+"px, "+d+"px, 0px) rotateX("+o+"deg) rotateY("+n+"deg)")}},setTransition:function(e){var t=this,i=t.slides,s=t.activeIndex,a=t.$wrapperEl;if(i.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),t.params.virtualTranslate&&0!==e){var r=!1;i.eq(s).transitionEnd((function(){if(!r&&t&&!t.destroyed){r=!0,t.animating=!1;for(var e=["webkitTransitionEnd","transitionend"],i=0;i<e.length;i+=1)a.trigger(e[i])}}))}}},ge={setTranslate:function(){for(var e=this.width,t=this.height,i=this.slides,a=this.$wrapperEl,r=this.slidesSizesGrid,n=this.params.coverflowEffect,l=this.isHorizontal(),d=this.translate,h=l?e/2-d:t/2-d,p=l?n.rotate:-n.rotate,c=n.depth,u=0,v=i.length;u<v;u+=1){var f=i.eq(u),m=r[u],g=(h-f[0].swiperSlideOffset-m/2)/m*n.modifier,b=l?p*g:0,w=l?0:p*g,y=-c*Math.abs(g),x=l?0:n.stretch*g,T=l?n.stretch*g:0;Math.abs(T)<.001&&(T=0),Math.abs(x)<.001&&(x=0),Math.abs(y)<.001&&(y=0),Math.abs(b)<.001&&(b=0),Math.abs(w)<.001&&(w=0);var E="translate3d("+T+"px,"+x+"px,"+y+"px)  rotateX("+w+"deg) rotateY("+b+"deg)";if(f.transform(E),f[0].style.zIndex=1-Math.abs(Math.round(g)),n.slideShadows){var C=l?f.find(".swiper-slide-shadow-left"):f.find(".swiper-slide-shadow-top"),S=l?f.find(".swiper-slide-shadow-right"):f.find(".swiper-slide-shadow-bottom");
35590===C.length&&(C=s('<div class="swiper-slide-shadow-'+(l?"left":"top")+'"></div>'),f.append(C)),0===S.length&&(S=s('<div class="swiper-slide-shadow-'+(l?"right":"bottom")+'"></div>'),f.append(S)),C.length&&(C[0].style.opacity=g>0?g:0),S.length&&(S[0].style.opacity=-g>0?-g:0)}}(o.pointerEvents||o.prefixedPointerEvents)&&(a[0].style.perspectiveOrigin=h+"px 50%")},setTransition:function(e){this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)}},be={init:function(){var e=this.params.thumbs,t=this.constructor;e.swiper instanceof t?(this.thumbs.swiper=e.swiper,n.extend(this.thumbs.swiper.originalParams,{watchSlidesProgress:!0,slideToClickedSlide:!1}),n.extend(this.thumbs.swiper.params,{watchSlidesProgress:!0,slideToClickedSlide:!1})):n.isObject(e.swiper)&&(this.thumbs.swiper=new t(n.extend({},e.swiper,{watchSlidesVisibility:!0,watchSlidesProgress:!0,slideToClickedSlide:!1})),this.thumbs.swiperCreated=!0),this.thumbs.swiper.$el.addClass(this.params.thumbs.thumbsContainerClass),this.thumbs.swiper.on("tap",this.thumbs.onThumbClick)},onThumbClick:function(){var e=this.thumbs.swiper;if(e){var t=e.clickedIndex,i=e.clickedSlide;if(!(i&&s(i).hasClass(this.params.thumbs.slideThumbActiveClass)||null==t)){var a;if(a=e.params.loop?parseInt(s(e.clickedSlide).attr("data-swiper-slide-index"),10):t,this.params.loop){var r=this.activeIndex;this.slides.eq(r).hasClass(this.params.slideDuplicateClass)&&(this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft,r=this.activeIndex);var n=this.slides.eq(r).prevAll('[data-swiper-slide-index="'+a+'"]').eq(0).index(),o=this.slides.eq(r).nextAll('[data-swiper-slide-index="'+a+'"]').eq(0).index();a=void 0===n?o:void 0===o?n:o-r<r-n?o:n}this.slideTo(a)}}},update:function(e){var t=this.thumbs.swiper;if(t){var i="auto"===t.params.slidesPerView?t.slidesPerViewDynamic():t.params.slidesPerView;if(this.realIndex!==t.realIndex){var s,a=t.activeIndex;if(t.params.loop){t.slides.eq(a).hasClass(t.params.slideDuplicateClass)&&(t.loopFix(),t._clientLeft=t.$wrapperEl[0].clientLeft,a=t.activeIndex);var r=t.slides.eq(a).prevAll('[data-swiper-slide-index="'+this.realIndex+'"]').eq(0).index(),n=t.slides.eq(a).nextAll('[data-swiper-slide-index="'+this.realIndex+'"]').eq(0).index();s=void 0===r?n:void 0===n?r:n-a==a-r?a:n-a<a-r?n:r}else s=this.realIndex;t.visibleSlidesIndexes&&t.visibleSlidesIndexes.indexOf(s)<0&&(t.params.centeredSlides?s=s>a?s-Math.floor(i/2)+1:s+Math.floor(i/2)-1:s>a&&(s=s-i+1),t.slideTo(s,e?0:void 0))}var o=1,l=this.params.thumbs.slideThumbActiveClass;if(this.params.slidesPerView>1&&!this.params.centeredSlides&&(o=this.params.slidesPerView),t.slides.removeClass(l),t.params.loop||t.params.virtual&&t.params.virtual.enabled)for(var d=0;d<o;d+=1)t.$wrapperEl.children('[data-swiper-slide-index="'+(this.realIndex+d)+'"]').addClass(l);else for(var h=0;h<o;h+=1)t.slides.eq(this.realIndex+h).addClass(l)}}},we=[W,q,K,U,Z,J,te,{name:"mousewheel",params:{mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarged:"container"}},create:function(){n.extend(this,{mousewheel:{enabled:!1,enable:ie.enable.bind(this),disable:ie.disable.bind(this),handle:ie.handle.bind(this),handleMouseEnter:ie.handleMouseEnter.bind(this),handleMouseLeave:ie.handleMouseLeave.bind(this),lastScrollTime:n.now()}})},on:{init:function(){!this.params.mousewheel.enabled&&this.params.cssMode&&this.mousewheel.disable(),this.params.mousewheel.enabled&&this.mousewheel.enable()},destroy:function(){this.params.cssMode&&this.mousewheel.enable(),this.mousewheel.enabled&&this.mousewheel.disable()}}},{name:"navigation",params:{navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock"}},create:function(){n.extend(this,{navigation:{init:se.init.bind(this),update:se.update.bind(this),destroy:se.destroy.bind(this),onNextClick:se.onNextClick.bind(this),onPrevClick:se.onPrevClick.bind(this)}})},on:{init:function(){this.navigation.init(),this.navigation.update()},toEdge:function(){this.navigation.update()},fromEdge:function(){this.navigation.update()},destroy:function(){this.navigation.destroy()},click:function(e){var t,i=this.navigation,a=i.$nextEl,r=i.$prevEl;!this.params.navigation.hideOnClick||s(e.target).is(r)||s(e.target).is(a)||(a?t=a.hasClass(this.params.navigation.hiddenClass):r&&(t=r.hasClass(this.params.navigation.hiddenClass)),!0===t?this.emit
vendor: 15,228 bytes, lines 3559-3560
3559("navigationShow",this):this.emit("navigationHide",this),a&&a.toggleClass(this.params.navigation.hiddenClass),r&&r.toggleClass(this.params.navigation.hiddenClass))}}},{name:"pagination",params:{pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:function(e){return e},formatFractionTotal:function(e){return e},bulletClass:"swiper-pagination-bullet",bulletActiveClass:"swiper-pagination-bullet-active",modifierClass:"swiper-pagination-",currentClass:"swiper-pagination-current",totalClass:"swiper-pagination-total",hiddenClass:"swiper-pagination-hidden",progressbarFillClass:"swiper-pagination-progressbar-fill",progressbarOppositeClass:"swiper-pagination-progressbar-opposite",clickableClass:"swiper-pagination-clickable",lockClass:"swiper-pagination-lock"}},create:function(){n.extend(this,{pagination:{init:ae.init.bind(this),render:ae.render.bind(this),update:ae.update.bind(this),destroy:ae.destroy.bind(this),dynamicBulletIndex:0}})},on:{init:function(){this.pagination.init(),this.pagination.render(),this.pagination.update()},activeIndexChange:function(){this.params.loop?this.pagination.update():void 0===this.snapIndex&&this.pagination.update()},snapIndexChange:function(){this.params.loop||this.pagination.update()},slidesLengthChange:function(){this.params.loop&&(this.pagination.render(),this.pagination.update())},snapGridLengthChange:function(){this.params.loop||(this.pagination.render(),this.pagination.update())},destroy:function(){this.pagination.destroy()},click:function(e){this.params.pagination.el&&this.params.pagination.hideOnClick&&this.pagination.$el.length>0&&!s(e.target).hasClass(this.params.pagination.bulletClass)&&(!0===this.pagination.$el.hasClass(this.params.pagination.hiddenClass)?this.emit("paginationShow",this):this.emit("paginationHide",this),this.pagination.$el.toggleClass(this.params.pagination.hiddenClass))}}},{name:"scrollbar",params:{scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag"}},create:function(){n.extend(this,{scrollbar:{init:re.init.bind(this),destroy:re.destroy.bind(this),updateSize:re.updateSize.bind(this),setTranslate:re.setTranslate.bind(this),setTransition:re.setTransition.bind(this),enableDraggable:re.enableDraggable.bind(this),disableDraggable:re.disableDraggable.bind(this),setDragPosition:re.setDragPosition.bind(this),getPointerPosition:re.getPointerPosition.bind(this),onDragStart:re.onDragStart.bind(this),onDragMove:re.onDragMove.bind(this),onDragEnd:re.onDragEnd.bind(this),isTouched:!1,timeout:null,dragTimeout:null}})},on:{init:function(){this.scrollbar.init(),this.scrollbar.updateSize(),this.scrollbar.setTranslate()},update:function(){this.scrollbar.updateSize()},resize:function(){this.scrollbar.updateSize()},observerUpdate:function(){this.scrollbar.updateSize()},setTranslate:function(){this.scrollbar.setTranslate()},setTransition:function(e){this.scrollbar.setTransition(e)},destroy:function(){this.scrollbar.destroy()}}},{name:"parallax",params:{parallax:{enabled:!1}},create:function(){n.extend(this,{parallax:{setTransform:ne.setTransform.bind(this),setTranslate:ne.setTranslate.bind(this),setTransition:ne.setTransition.bind(this)}})},on:{beforeInit:function(){this.params.parallax.enabled&&(this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},init:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTranslate:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTransition:function(e){this.params.parallax.enabled&&this.parallax.setTransition(e)}}},{name:"zoom",params:{zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}},create:function(){var e=this,t={enabled:!1,scale:1,currentScale:1,isScaling:!1,gesture:{$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},image:{isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},velocity:{x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0}};"onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out".split(" ").forEach((function(i){t[i]=oe[i].bind(e)})),n.extend(e,{zoom:t});var i=1;Object.defineProperty(e.zoom,"scale",{get:function(){return i},set:function(t){if(i!==t){var s=e.zoom.gesture.$imageEl?e.zoom.gesture.$imageEl[0]:void 0,a=e.zoom.gesture.$slideEl?e.zoom.gesture.$slideEl[0]:void 0;e.emit("zoomChange",t,s,a)}i=t}})},on:{init:function(){this.params.zoom.enabled&&this.zoom.enable()},destroy:function(){this.zoom.disable()},touchStart:function(e){this.zoom.enabled&&this.zoom.onTouchStart(e)},touchEnd:function(e){this.zoom.enabled&&this.zoom.onTouchEnd(e)},doubleTap:function(e){this.params.zoom.enabled&&this.zoom.enabled&&this.params.zoom.toggle&&this.zoom.toggle(e)},transitionEnd:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.zoom.onTransitionEnd()},slideChange:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.params.cssMode&&this.zoom.onTransitionEnd()}}},{name:"lazy",params:{lazy:{enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}},create:function(){n.extend(this,{lazy:{initialImageLoaded:!1,load:le.load.bind(this),loadInSlide:le.loadInSlide.bind(this)}})},on:{beforeInit:function(){this.params.lazy.enabled&&this.params.preloadImages&&(this.params.preloadImages=!1)},init:function(){this.params.lazy.enabled&&!this.params.loop&&0===this.params.initialSlide&&this.lazy.load()},scroll:function(){this.params.freeMode&&!this.params.freeModeSticky&&this.lazy.load()},resize:function(){this.params.lazy.enabled&&this.lazy.load()},scrollbarDragMove:function(){this.params.lazy.enabled&&this.lazy.load()},transitionStart:function(){this.params.lazy.enabled&&(this.params.lazy.loadOnTransitionStart||!this.params.lazy.loadOnTransitionStart&&!this.lazy.initialImageLoaded)&&this.lazy.load()},transitionEnd:function(){this.params.lazy.enabled&&!this.params.lazy.loadOnTransitionStart&&this.lazy.load()},slideChange:function(){this.params.lazy.enabled&&this.params.cssMode&&this.lazy.load()}}},{name:"controller",params:{controller:{control:void 0,inverse:!1,by:"slide"}},create:function(){n.extend(this,{controller:{control:this.params.controller.control,getInterpolateFunction:de.getInterpolateFunction.bind(this),setTranslate:de.setTranslate.bind(this),setTransition:de.setTransition.bind(this)}})},on:{update:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},resize:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},observerUpdate:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},setTranslate:function(e,t){this.controller.control&&this.controller.setTranslate(e,t)},setTransition:function(e,t){this.controller.control&&this.controller.setTransition(e,t)}}},{name:"a11y",params:{a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}"}},create:function(){var e=this;n.extend(e,{a11y:{liveRegion:s('<span class="'+e.params.a11y.notificationClass+'" aria-live="assertive" aria-atomic="true"></span>')}}),Object.keys(he).forEach((function(t){e.a11y[t]=he[t].bind(e)}))},on:{init:function(){this.params.a11y.enabled&&(this.a11y.init(),this.a11y.updateNavigation())},toEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},fromEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},paginationUpdate:function(){this.params.a11y.enabled&&this.a11y.updatePagination()},destroy:function(){this.params.a11y.enabled&&this.a11y.destroy()}}},{name:"history",params:{history:{enabled:!1,replaceState:!1,key:"slides"}},create:function(){n.extend(this,{history:{init:pe.init.bind(this),setHistory:pe.setHistory.bind(this),setHistoryPopState:pe.setHistoryPopState.bind(this),scrollToSlide:pe.scrollToSlide.bind(this),destroy:pe.destroy.bind(this)}})},on:{init:function(){this.params.history.enabled&&this.history.init()},destroy:function(){this.params.history.enabled&&this.history.destroy()},transitionEnd:function(){this.history.initialized&&this.history.setHistory(this.params.history.key,this.activeIndex)},slideChange:function(){this.history.initialized&&this.params.cssMode&&this.history.setHistory(this.params.history.key,this.activeIndex)}}},{name:"hash-navigation",params:{hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}},create:function(){n.extend(this,{hashNavigation:{initialized:!1,init:ce.init.bind(this),destroy:ce.destroy.bind(this),setHash:ce.setHash.bind(this),onHashCange:ce.onHashCange.bind(this)}})},on:{init:function(){this.params.hashNavigation.enabled&&this.hashNavigation.init()},destroy:function(){this.params.hashNavigation.enabled&&this.hashNavigation.destroy()},transitionEnd:function(){this.hashNavigation.initialized&&this.hashNavigation.setHash()},slideChange:function(){this.hashNavigation.initialized&&this.params.cssMode&&this.hashNavigation.setHash()}}},{name:"autoplay",params:{autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1}},create:function(){var e=this;n.extend(e,{autoplay:{running:!1,paused:!1,run:ue.run.bind(e),start:ue.start.bind(e),stop:ue.stop.bind(e),pause:ue.pause.bind(e),onVisibilityChange:function(){"hidden"===document.visibilityState&&e.autoplay.running&&e.autoplay.pause(),"visible"===document.visibilityState&&e.autoplay.paused&&(e.autoplay.run(),e.autoplay.paused=!1)},onTransitionEnd:function(t){e&&!e.destroyed&&e.$wrapperEl&&t.target===this&&(e.$wrapperEl[0].removeEventListener("transitionend",e.autoplay.onTransitionEnd),e.$wrapperEl[0].removeEventListener("webkitTransitionEnd",e.autoplay.onTransitionEnd),e.autoplay.paused=!1,e.autoplay.running?e.autoplay.run():e.autoplay.stop())}}})},on:{init:function(){this.params.autoplay.enabled&&(this.autoplay.start(),document.addEventListener("visibilitychange",this.autoplay.onVisibilityChange))},beforeTransitionStart:function(e,t){this.autoplay.running&&(t||!this.params.autoplay.disableOnInteraction?this.autoplay.pause(e):this.autoplay.stop())},sliderFirstMove:function(){this.autoplay.running&&(this.params.autoplay.disableOnInteraction?this.autoplay.stop():this.autoplay.pause())},touchEnd:function(){this.params.cssMode&&this.autoplay.paused&&!this.params.autoplay.disableOnInteraction&&this.autoplay.run()},destroy:function(){this.autoplay.running&&this.autoplay.stop(),document.removeEventListener("visibilitychange",this.autoplay.onVisibilityChange)}}},{name:"effect-fade",params:{fadeEffect:{crossFade:!1}},create:function(){n.extend(this,{fadeEffect:{setTranslate:ve.setTranslate.bind(this),setTransition:ve.setTransition.bind(this)}})},on:{beforeInit:function(){if("fade"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"fade");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};n.extend(this.params,e),n.extend(this.originalParams,e)}},setTranslate:function(){"fade"===this.params.effect&&this.fadeEffect.setTranslate()},setTransition:function(e){"fade"===this.params.effect&&this.fadeEffect.setTransition(e)}}},{name:"effect-cube",params:{cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}},create:function(){n.extend(this,{cubeEffect:{setTranslate:fe.setTranslate.bind(this),setTransition:fe.setTransition.bind(this)}})},on:{beforeInit:function(){if("cube"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"cube"),this.classNames.push(this.params.containerModifierClass+"3d");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0};n.extend(this.params,e),n.extend(this.originalParams,e)}},setTranslate:function(){"cube"===this.params.effect&&this.cubeEffect.setTranslate()},setTransition:function(e){"cube"===this.params.effect&&this.cubeEffect.setTransition(e)}}},{name:"effect-flip",params:{flipEffect:{slideShadows:!0,limitRotation:!0}},create:function(){n.extend(this,{flipEffect:{setTranslate:me.setTranslate.bind(this),setTransition:me.setTransition.bind(this)}})},on:{beforeInit:function(){if("flip"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"flip"),this.classNames.push(this.params.containerModifierClass+"3d");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};n.extend(this.params,e),n.extend(this.originalParams,e)}},setTranslate:function(){"flip"===this.params.effect&&this.flipEffect.setTranslate()},setTransition:function(e){"flip"===this.params.effect&&this.flipEffect.setTransition(e)}}},{name:"effect-coverflow",params:{coverflowEffect:{rotate:50,stretch:0,depth:100,modifier:1,slideShadows:!0}},create:function(){n.extend(this,{coverflowEffect:{setTranslate:ge.setTranslate.bind(this),setTransition:ge.setTransition.bind(this)}})},on:{beforeInit:function(){"coverflow"===this.params.effect&&(this.classNames.push(this.params.containerModifierClass+"coverflow"),this.classNames.push(this.params.containerModifierClass+"3d"),this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},setTranslate:function(){"coverflow"===this.params.effect&&this.coverflowEffect.setTranslate()},setTransition:function(e){"coverflow"===this.params.effect&&this.coverflowEffect.setTransition(e)}}},{name:"thumbs",params:{thumbs:{swiper:null,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-container-thumbs"}},create:function(){n.extend(this,{thumbs:{swiper:null,init:be.init.bind(this),update:be.update.bind(this),onThumbClick:be.onThumbClick.bind(this)}})},on:{beforeInit:function(){var e=this.params.thumbs;e&&e.swiper&&(this.thumbs.init(),this.thumbs.update(!0))},slideChange:function(){this.thumbs.swiper&&this.thumbs.update()},update:function(){this.thumbs.swiper&&this.thumbs.update()},resize:function(){this.thumbs.swiper&&this.thumbs.update()},observerUpdate:function(){this.thumbs.swiper&&this.thumbs.update()},setTransition:function(e){var t=this.thumbs.swiper;t&&t.setTransition(e)},beforeDestroy:function(){var e=this.thumbs.swiper;e&&this.thumbs.swiperCreated&&e&&e.destroy()}}}];return void 0===R.use&&(R.use=R.Class.use,R.installModule=R.Class.installModule),R.use(we),R}));
3560 //# sourceMappingURL=swiper.min.js.map
vendor: 6,612 bytes, lines 3561-3736
3561/////////////////////////////////////////////////////////////////////////////////
3562/* UAParser.js v1.0.37
3563   Copyright © 2012-2021 Faisal Salman <[email protected]>
3564   MIT License *//*
3565   Detect Browser, Engine, OS, CPU, and Device type/model from User-Agent data.
3566   Supports browser & node.js environment. 
3567   Demo   : https://faisalman.github.io/ua-parser-js
3568   Source : https://github.com/faisalman/ua-parser-js */
3569/////////////////////////////////////////////////////////////////////////////////
3570
3571(function (window, undefined) {
3572
3573    'use strict';
3574
3575    //////////////
3576    // Constants
3577    /////////////
3578
3579
3580    var LIBVERSION  = '1.0.37',
3581        EMPTY       = '',
3582        UNKNOWN     = '?',
3583        FUNC_TYPE   = 'function',
3584        UNDEF_TYPE  = 'undefined',
3585        OBJ_TYPE    = 'object',
3586        STR_TYPE    = 'string',
3587        MAJOR       = 'major',
3588        MODEL       = 'model',
3589        NAME        = 'name',
3590        TYPE        = 'type',
3591        VENDOR      = 'vendor',
3592        VERSION     = 'version',
3593        ARCHITECTURE= 'architecture',
3594        CONSOLE     = 'console',
3595        MOBILE      = 'mobile',
3596        TABLET      = 'tablet',
3597        SMARTTV     = 'smarttv',
3598        WEARABLE    = 'wearable',
3599        EMBEDDED    = 'embedded',
3600        UA_MAX_LENGTH = 500;
3601
3602    var AMAZON  = 'Amazon',
3603        APPLE   = 'Apple',
3604        ASUS    = 'ASUS',
3605        BLACKBERRY = 'BlackBerry',
3606        BROWSER = 'Browser',
3607        CHROME  = 'Chrome',
3608        EDGE    = 'Edge',
3609        FIREFOX = 'Firefox',
3610        GOOGLE  = 'Google',
3611        HUAWEI  = 'Huawei',
3612        LG      = 'LG',
3613        MICROSOFT = 'Microsoft',
3614        MOTOROLA  = 'Motorola',
3615        OPERA   = 'Opera',
3616        SAMSUNG = 'Samsung',
3617        SHARP   = 'Sharp',
3618        SONY    = 'Sony',
3619        XIAOMI  = 'Xiaomi',
3620        ZEBRA   = 'Zebra',
3621        FACEBOOK    = 'Facebook',
3622        CHROMIUM_OS = 'Chromium OS',
3623        MAC_OS  = 'Mac OS';
3624
3625    ///////////
3626    // Helper
3627    //////////
3628
3629    var extend = function (regexes, extensions) {
3630            var mergedRegexes = {};
3631            for (var i in regexes) {
3632                if (extensions[i] && extensions[i].length % 2 === 0) {
3633                    mergedRegexes[i] = extensions[i].concat(regexes[i]);
3634                } else {
3635                    mergedRegexes[i] = regexes[i];
3636                }
3637            }
3638            return mergedRegexes;
3639        },
3640        enumerize = function (arr) {
3641            var enums = {};
3642            for (var i=0; i<arr.length; i++) {
3643                enums[arr[i].toUpperCase()] = arr[i];
3644            }
3645            return enums;
3646        },
3647        has = function (str1, str2) {
3648            return typeof str1 === STR_TYPE ? lowerize(str2).indexOf(lowerize(str1)) !== -1 : false;
3649        },
3650        lowerize = function (str) {
3651            return str.toLowerCase();
3652        },
3653        majorize = function (version) {
3654            return typeof(version) === STR_TYPE ? version.replace(/[^\d\.]/g, EMPTY).split('.')[0] : undefined;
3655        },
3656        trim = function (str, len) {
3657            if (typeof(str) === STR_TYPE) {
3658                str = str.replace(/^\s\s*/, EMPTY);
3659                return typeof(len) === UNDEF_TYPE ? str : str.substring(0, UA_MAX_LENGTH);
3660            }
3661    };
3662
3663    ///////////////
3664    // Map helper
3665    //////////////
3666
3667    var rgxMapper = function (ua, arrays) {
3668
3669            var i = 0, j, k, p, q, matches, match;
3670
3671            // loop through all regexes maps
3672            while (i < arrays.length && !matches) {
3673
3674                var regex = arrays[i],       // even sequence (0,2,4,..)
3675                    props = arrays[i + 1];   // odd sequence (1,3,5,..)
3676                j = k = 0;
3677
3678                // try matching uastring with regexes
3679                while (j < regex.length && !matches) {
3680
3681                    if (!regex[j]) { break; }
3682                    matches = regex[j++].exec(ua);
3683
3684                    if (!!matches) {
3685                        for (p = 0; p < props.length; p++) {
3686                            match = matches[++k];
3687                            q = props[p];
3688                            // check if given property is actually array
3689                            if (typeof q === OBJ_TYPE && q.length > 0) {
3690                                if (q.length === 2) {
3691                                    if (typeof q[1] == FUNC_TYPE) {
3692                                        // assign modified match
3693                                        this[q[0]] = q[1].call(this, match);
3694                                    } else {
3695                                        // assign given value, ignore regex match
3696                                        this[q[0]] = q[1];
3697                                    }
3698                                } else if (q.length === 3) {
3699                                    // check whether function or regex
3700                                    if (typeof q[1] === FUNC_TYPE && !(q[1].exec && q[1].test)) {
3701                                        // call function (usually string mapper)
3702                                        this[q[0]] = match ? q[1].call(this, match, q[2]) : undefined;
3703                                    } else {
3704                                        // sanitize match using given regex
3705                                        this[q[0]] = match ? match.replace(q[1], q[2]) : undefined;
3706                                    }
3707                                } else if (q.length === 4) {
3708                                        this[q[0]] = match ? q[3].call(this, match.replace(q[1], q[2])) : undefined;
3709                                }
3710                            } else {
3711                                this[q] = match ? match : undefined;
3712                            }
3713                        }
3714                    }
3715                }
3716                i += 2;
3717            }
3718        },
3719
3720        strMapper = function (str, map) {
3721
3722            for (var i in map) {
3723                // check if current value is array
3724                if (typeof map[i] === OBJ_TYPE && map[i].length > 0) {
3725                    for (var j = 0; j < map[i].length; j++) {
3726                        if (has(map[i][j], str)) {
3727                            return (i === UNKNOWN) ? undefined : i;
3728                        }
3729                    }
3730                } else if (has(map[i], str)) {
3731                    return (i === UNKNOWN) ? undefined : i;
3732                }
3733            }
3734            return str;
3735    };
3736
vendor: 4,464 bytes, lines 3737-3819
3737    ///////////////
3738    // String map
3739    //////////////
3740
3741    // Safari < 3.0
3742    var oldSafariMap = {
3743            '1.0'   : '/8',
3744            '1.2'   : '/1',
3745            '1.3'   : '/3',
3746            '2.0'   : '/412',
3747            '2.0.2' : '/416',
3748            '2.0.3' : '/417',
3749            '2.0.4' : '/419',
3750            '?'     : '/'
3751        },
3752        windowsVersionMap = {
3753            'ME'        : '4.90',
3754            'NT 3.11'   : 'NT3.51',
3755            'NT 4.0'    : 'NT4.0',
3756            '2000'      : 'NT 5.0',
3757            'XP'        : ['NT 5.1', 'NT 5.2'],
3758            'Vista'     : 'NT 6.0',
3759            '7'         : 'NT 6.1',
3760            '8'         : 'NT 6.2',
3761            '8.1'       : 'NT 6.3',
3762            '10'        : ['NT 6.4', 'NT 10.0'],
3763            'RT'        : 'ARM'
3764    };
3765
3766    //////////////
3767    // Regex map
3768    /////////////
3769
3770    var regexes = {
3771
3772        browser : [[
3773
3774            /\b(?:crmo|crios)\/([\w\.]+)/i                                      // Chrome for Android/iOS
3775            ], [VERSION, [NAME, 'Chrome']], [
3776            /edg(?:e|ios|a)?\/([\w\.]+)/i                                       // Microsoft Edge
3777            ], [VERSION, [NAME, 'Edge']], [
3778
3779            // Presto based
3780            /(opera mini)\/([-\w\.]+)/i,                                        // Opera Mini
3781            /(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,                 // Opera Mobi/Tablet
3782            /(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i                           // Opera
3783            ], [NAME, VERSION], [
3784            /opios[\/ ]+([\w\.]+)/i                                             // Opera mini on iphone >= 8.0
3785            ], [VERSION, [NAME, OPERA+' Mini']], [
3786            /\bopr\/([\w\.]+)/i                                                 // Opera Webkit
3787            ], [VERSION, [NAME, OPERA]], [
3788
3789            // Mixed
3790            /\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i            // Baidu
3791            ], [VERSION, [NAME, 'Baidu']], [
3792            /(kindle)\/([\w\.]+)/i,                                             // Kindle
3793            /(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,      // Lunascape/Maxthon/Netfront/Jasmine/Blazer
3794            // Trident based
3795            /(avant|iemobile|slim)\s?(?:browser)?[\/ ]?([\w\.]*)/i,             // Avant/IEMobile/SlimBrowser
3796            /(?:ms|\()(ie) ([\w\.]+)/i,                                         // Internet Explorer
3797
3798            // Webkit/KHTML based                                               // Flock/RockMelt/Midori/Epiphany/Silk/Skyfire/Bolt/Iron/Iridium/PhantomJS/Bowser/QupZilla/Falkon
3799            /(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,
3800                                                                                // Rekonq/Puffin/Brave/Whale/QQBrowserLite/QQ, aka ShouQ
3801            /(heytap|ovi)browser\/([\d\.]+)/i,                                  // Heytap/Ovi
3802            /(weibo)__([\d\.]+)/i                                               // Weibo
3803            ], [NAME, VERSION], [
3804            /(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i                 // UCBrowser
3805            ], [VERSION, [NAME, 'UC'+BROWSER]], [
3806            /microm.+\bqbcore\/([\w\.]+)/i,                                     // WeChat Desktop for Windows Built-in Browser
3807            /\bqbcore\/([\w\.]+).+microm/i,
3808            /micromessenger\/([\w\.]+)/i                                        // WeChat
3809            ], [VERSION, [NAME, 'WeChat']], [
3810            /konqueror\/([\w\.]+)/i                                             // Konqueror
3811            ], [VERSION, [NAME, 'Konqueror']], [
3812            /trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i                       // IE11
3813            ], [VERSION, [NAME, 'IE']], [
3814            /ya(?:search)?browser\/([\w\.]+)/i                                  // Yandex
3815            ], [VERSION, [NAME, 'Yandex']], [
3816            /slbrowser\/([\w\.]+)/i                                             // Smart Lenovo Browser
3817            ], [VERSION, [NAME, 'Smart Lenovo '+BROWSER]], [
3818            /(avast|avg)\/([\w\.]+)/i                                           // Avast/AVG Secure Browser
3819            ], [[NAME, /(.+)/, '$1 Secure '+BROWSER], VERSION], [
vendor: 8,431 bytes, lines 3820-3950
3820            /\bfocus\/([\w\.]+)/i                                               // Firefox Focus
3821            ], [VERSION, [NAME, FIREFOX+' Focus']], [
3822            /\bopt\/([\w\.]+)/i                                                 // Opera Touch
3823            ], [VERSION, [NAME, OPERA+' Touch']], [
3824            /coc_coc\w+\/([\w\.]+)/i                                            // Coc Coc Browser
3825            ], [VERSION, [NAME, 'Coc Coc']], [
3826            /dolfin\/([\w\.]+)/i                                                // Dolphin
3827            ], [VERSION, [NAME, 'Dolphin']], [
3828            /coast\/([\w\.]+)/i                                                 // Opera Coast
3829            ], [VERSION, [NAME, OPERA+' Coast']], [
3830            /miuibrowser\/([\w\.]+)/i                                           // MIUI Browser
3831            ], [VERSION, [NAME, 'MIUI '+BROWSER]], [
3832            /fxios\/([-\w\.]+)/i                                                // Firefox for iOS
3833            ], [VERSION, [NAME, FIREFOX]], [
3834            /\bqihu|(qi?ho?o?|360)browser/i                                     // 360
3835            ], [[NAME, '360 ' + BROWSER]], [
3836            /(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i
3837            ], [[NAME, /(.+)/, '$1 ' + BROWSER], VERSION], [                    // Oculus/Sailfish/HuaweiBrowser/VivoBrowser
3838            /samsungbrowser\/([\w\.]+)/i                                        // Samsung Internet
3839            ], [VERSION, [NAME, SAMSUNG + ' Internet']], [
3840            /(comodo_dragon)\/([\w\.]+)/i                                       // Comodo Dragon
3841            ], [[NAME, /_/g, ' '], VERSION], [
3842            /metasr[\/ ]?([\d\.]+)/i                                            // Sogou Explorer
3843            ], [VERSION, [NAME, 'Sogou Explorer']], [
3844            /(sogou)mo\w+\/([\d\.]+)/i                                          // Sogou Mobile
3845            ], [[NAME, 'Sogou Mobile'], VERSION], [
3846            /(electron)\/([\w\.]+) safari/i,                                    // Electron-based App
3847            /(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,                   // Tesla
3848            /m?(qqbrowser|2345Explorer)[\/ ]?([\w\.]+)/i                        // QQBrowser/2345 Browser
3849            ], [NAME, VERSION], [
3850            /(lbbrowser)/i,                                                     // LieBao Browser
3851            /\[(linkedin)app\]/i                                                // LinkedIn App for iOS & Android
3852            ], [NAME], [
3853
3854            // WebView
3855            /((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i       // Facebook App for iOS & Android
3856            ], [[NAME, FACEBOOK], VERSION], [
3857            /(Klarna)\/([\w\.]+)/i,                                             // Klarna Shopping Browser for iOS & Android
3858            /(kakao(?:talk|story))[\/ ]([\w\.]+)/i,                             // Kakao App
3859            /(naver)\(.*?(\d+\.[\w\.]+).*\)/i,                                  // Naver InApp
3860            /safari (line)\/([\w\.]+)/i,                                        // Line App for iOS
3861            /\b(line)\/([\w\.]+)\/iab/i,                                        // Line App for Android
3862            /(alipay)client\/([\w\.]+)/i,                                       // Alipay
3863            /(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i                     // Chromium/Instagram/Snapchat
3864            ], [NAME, VERSION], [
3865            /\bgsa\/([\w\.]+) .*safari\//i                                      // Google Search Appliance on iOS
3866            ], [VERSION, [NAME, 'GSA']], [
3867            /musical_ly(?:.+app_?version\/|_)([\w\.]+)/i                        // TikTok
3868            ], [VERSION, [NAME, 'TikTok']], [
3869
3870            /headlesschrome(?:\/([\w\.]+)| )/i                                  // Chrome Headless
3871            ], [VERSION, [NAME, CHROME+' Headless']], [
3872
3873            / wv\).+(chrome)\/([\w\.]+)/i                                       // Chrome WebView
3874            ], [[NAME, CHROME+' WebView'], VERSION], [
3875
3876            /droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i           // Android Browser
3877            ], [VERSION, [NAME, 'Android '+BROWSER]], [
3878
3879            /(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i       // Chrome/OmniWeb/Arora/Tizen/Nokia
3880            ], [NAME, VERSION], [
3881
3882            /version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i                      // Mobile Safari
3883            ], [VERSION, [NAME, 'Mobile Safari']], [
3884            /version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i                // Safari & Safari Mobile
3885            ], [VERSION, NAME], [
3886            /webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i                      // Safari < 3.0
3887            ], [NAME, [VERSION, strMapper, oldSafariMap]], [
3888
3889            /(webkit|khtml)\/([\w\.]+)/i
3890            ], [NAME, VERSION], [
3891
3892            // Gecko based
3893            /(navigator|netscape\d?)\/([-\w\.]+)/i                              // Netscape
3894            ], [[NAME, 'Netscape'], VERSION], [
3895            /mobile vr; rv:([\w\.]+)\).+firefox/i                               // Firefox Reality
3896            ], [VERSION, [NAME, FIREFOX+' Reality']], [
3897            /ekiohf.+(flow)\/([\w\.]+)/i,                                       // Flow
3898            /(swiftfox)/i,                                                      // Swiftfox
3899            /(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,
3900                                                                                // IceDragon/Iceweasel/Camino/Chimera/Fennec/Maemo/Minimo/Conkeror/Klar
3901            /(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,
3902                                                                                // Firefox/SeaMonkey/K-Meleon/IceCat/IceApe/Firebird/Phoenix
3903            /(firefox)\/([\w\.]+)/i,                                            // Other Firefox-based
3904            /(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,                         // Mozilla
3905
3906            // Other
3907            /(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,
3908                                                                                // Polaris/Lynx/Dillo/iCab/Doris/Amaya/w3m/NetSurf/Sleipnir/Obigo/Mosaic/Go/ICE/UP.Browser
3909            /(links) \(([\w\.]+)/i,                                             // Links
3910            /panasonic;(viera)/i                                                // Panasonic Viera
3911            ], [NAME, VERSION], [
3912            
3913            /(cobalt)\/([\w\.]+)/i                                              // Cobalt
3914            ], [NAME, [VERSION, /master.|lts./, ""]]
3915        ],
3916
3917        cpu : [[
3918
3919            /(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i                     // AMD64 (x64)
3920            ], [[ARCHITECTURE, 'amd64']], [
3921
3922            /(ia32(?=;))/i                                                      // IA32 (quicktime)
3923            ], [[ARCHITECTURE, lowerize]], [
3924
3925            /((?:i[346]|x)86)[;\)]/i                                            // IA32 (x86)
3926            ], [[ARCHITECTURE, 'ia32']], [
3927
3928            /\b(aarch64|arm(v?8e?l?|_?64))\b/i                                 // ARM64
3929            ], [[ARCHITECTURE, 'arm64']], [
3930
3931            /\b(arm(?:v[67])?ht?n?[fl]p?)\b/i                                   // ARMHF
3932            ], [[ARCHITECTURE, 'armhf']], [
3933
3934            // PocketPC mistakenly identified as PowerPC
3935            /windows (ce|mobile); ppc;/i
3936            ], [[ARCHITECTURE, 'arm']], [
3937
3938            /((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i                            // PowerPC
3939            ], [[ARCHITECTURE, /ower/, EMPTY, lowerize]], [
3940
3941            /(sun4\w)[;\)]/i                                                    // SPARC
3942            ], [[ARCHITECTURE, 'sparc']], [
3943
3944            /((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i
3945                                                                                // IA64, 68K, ARM/64, AVR/32, IRIX/64, MIPS/64, SPARC/64, PA-RISC
3946            ], [[ARCHITECTURE, lowerize]]
3947        ],
3948
3949        device : [[
3950
vendor: 15,704 bytes, lines 3951-4209
3951            //////////////////////////
3952            // MOBILES & TABLETS
3953            /////////////////////////
3954
3955            // Samsung
3956            /\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i
3957            ], [MODEL, [VENDOR, SAMSUNG], [TYPE, TABLET]], [
3958            /\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,
3959            /samsung[- ]([-\w]+)/i,
3960            /sec-(sgh\w+)/i
3961            ], [MODEL, [VENDOR, SAMSUNG], [TYPE, MOBILE]], [
3962
3963            // Apple
3964            /(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i                          // iPod/iPhone
3965            ], [MODEL, [VENDOR, APPLE], [TYPE, MOBILE]], [
3966            /\((ipad);[-\w\),; ]+apple/i,                                       // iPad
3967            /applecoremedia\/[\w\.]+ \((ipad)/i,
3968            /\b(ipad)\d\d?,\d\d?[;\]].+ios/i
3969            ], [MODEL, [VENDOR, APPLE], [TYPE, TABLET]], [
3970            /(macintosh);/i
3971            ], [MODEL, [VENDOR, APPLE]], [
3972
3973            // Sharp
3974            /\b(sh-?[altvz]?\d\d[a-ekm]?)/i
3975            ], [MODEL, [VENDOR, SHARP], [TYPE, MOBILE]], [
3976
3977            // Huawei
3978            /\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i
3979            ], [MODEL, [VENDOR, HUAWEI], [TYPE, TABLET]], [
3980            /(?:huawei|honor)([-\w ]+)[;\)]/i,
3981            /\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i
3982            ], [MODEL, [VENDOR, HUAWEI], [TYPE, MOBILE]], [
3983
3984            // Xiaomi
3985            /\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,                  // Xiaomi POCO
3986            /\b; (\w+) build\/hm\1/i,                                           // Xiaomi Hongmi 'numeric' models
3987            /\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,                             // Xiaomi Hongmi
3988            /\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,                   // Xiaomi Redmi
3989            /oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,        // Xiaomi Redmi 'numeric' models
3990            /\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i // Xiaomi Mi
3991            ], [[MODEL, /_/g, ' '], [VENDOR, XIAOMI], [TYPE, MOBILE]], [
3992            /oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,                     // Redmi Pad
3993            /\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i                        // Mi Pad tablets
3994            ],[[MODEL, /_/g, ' '], [VENDOR, XIAOMI], [TYPE, TABLET]], [
3995
3996            // OPPO
3997            /; (\w+) bui.+ oppo/i,
3998            /\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i
3999            ], [MODEL, [VENDOR, 'OPPO'], [TYPE, MOBILE]], [
4000
4001            // Vivo
4002            /vivo (\w+)(?: bui|\))/i,
4003            /\b(v[12]\d{3}\w?[at])(?: bui|;)/i
4004            ], [MODEL, [VENDOR, 'Vivo'], [TYPE, MOBILE]], [
4005
4006            // Realme
4007            /\b(rmx[1-3]\d{3})(?: bui|;|\))/i
4008            ], [MODEL, [VENDOR, 'Realme'], [TYPE, MOBILE]], [
4009
4010            // Motorola
4011            /\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,
4012            /\bmot(?:orola)?[- ](\w*)/i,
4013            /((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i
4014            ], [MODEL, [VENDOR, MOTOROLA], [TYPE, MOBILE]], [
4015            /\b(mz60\d|xoom[2 ]{0,2}) build\//i
4016            ], [MODEL, [VENDOR, MOTOROLA], [TYPE, TABLET]], [
4017
4018            // LG
4019            /((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i
4020            ], [MODEL, [VENDOR, LG], [TYPE, TABLET]], [
4021            /(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,
4022            /\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,
4023            /\blg-?([\d\w]+) bui/i
4024            ], [MODEL, [VENDOR, LG], [TYPE, MOBILE]], [
4025
4026            // Lenovo
4027            /(ideatab[-\w ]+)/i,
4028            /lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i
4029            ], [MODEL, [VENDOR, 'Lenovo'], [TYPE, TABLET]], [
4030
4031            // Nokia
4032            /(?:maemo|nokia).*(n900|lumia \d+)/i,
4033            /nokia[-_ ]?([-\w\.]*)/i
4034            ], [[MODEL, /_/g, ' '], [VENDOR, 'Nokia'], [TYPE, MOBILE]], [
4035
4036            // Google
4037            /(pixel c)\b/i                                                      // Google Pixel C
4038            ], [MODEL, [VENDOR, GOOGLE], [TYPE, TABLET]], [
4039            /droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i                         // Google Pixel
4040            ], [MODEL, [VENDOR, GOOGLE], [TYPE, MOBILE]], [
4041
4042            // Sony
4043            /droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i
4044            ], [MODEL, [VENDOR, SONY], [TYPE, MOBILE]], [
4045            /sony tablet [ps]/i,
4046            /\b(?:sony)?sgp\w+(?: bui|\))/i
4047            ], [[MODEL, 'Xperia Tablet'], [VENDOR, SONY], [TYPE, TABLET]], [
4048
4049            // OnePlus
4050            / (kb2005|in20[12]5|be20[12][59])\b/i,
4051            /(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i
4052            ], [MODEL, [VENDOR, 'OnePlus'], [TYPE, MOBILE]], [
4053
4054            // Amazon
4055            /(alexa)webm/i,
4056            /(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,                             // Kindle Fire without Silk / Echo Show
4057            /(kf[a-z]+)( bui|\)).+silk\//i                                      // Kindle Fire HD
4058            ], [MODEL, [VENDOR, AMAZON], [TYPE, TABLET]], [
4059            /((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i                     // Fire Phone
4060            ], [[MODEL, /(.+)/g, 'Fire Phone $1'], [VENDOR, AMAZON], [TYPE, MOBILE]], [
4061
4062            // BlackBerry
4063            /(playbook);[-\w\),; ]+(rim)/i                                      // BlackBerry PlayBook
4064            ], [MODEL, VENDOR, [TYPE, TABLET]], [
4065            /\b((?:bb[a-f]|st[hv])100-\d)/i,
4066            /\(bb10; (\w+)/i                                                    // BlackBerry 10
4067            ], [MODEL, [VENDOR, BLACKBERRY], [TYPE, MOBILE]], [
4068
4069            // Asus
4070            /(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i
4071            ], [MODEL, [VENDOR, ASUS], [TYPE, TABLET]], [
4072            / (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i
4073            ], [MODEL, [VENDOR, ASUS], [TYPE, MOBILE]], [
4074
4075            // HTC
4076            /(nexus 9)/i                                                        // HTC Nexus 9
4077            ], [MODEL, [VENDOR, 'HTC'], [TYPE, TABLET]], [
4078            /(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,                         // HTC
4079
4080            // ZTE
4081            /(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,
4082            /(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i         // Alcatel/GeeksPhone/Nexian/Panasonic/Sony
4083            ], [VENDOR, [MODEL, /_/g, ' '], [TYPE, MOBILE]], [
4084
4085            // Acer
4086            /droid.+; ([ab][1-7]-?[0178a]\d\d?)/i
4087            ], [MODEL, [VENDOR, 'Acer'], [TYPE, TABLET]], [
4088
4089            // Meizu
4090            /droid.+; (m[1-5] note) bui/i,
4091            /\bmz-([-\w]{2,})/i
4092            ], [MODEL, [VENDOR, 'Meizu'], [TYPE, MOBILE]], [
4093                
4094            // Ulefone
4095            /; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i
4096            ], [MODEL, [VENDOR, 'Ulefone'], [TYPE, MOBILE]], [
4097
4098            // MIXED
4099            /(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,
4100                                                                                // BlackBerry/BenQ/Palm/Sony-Ericsson/Acer/Asus/Dell/Meizu/Motorola/Polytron
4101            /(hp) ([\w ]+\w)/i,                                                 // HP iPAQ
4102            /(asus)-?(\w+)/i,                                                   // Asus
4103            /(microsoft); (lumia[\w ]+)/i,                                      // Microsoft Lumia
4104            /(lenovo)[-_ ]?([-\w]+)/i,                                          // Lenovo
4105            /(jolla)/i,                                                         // Jolla
4106            /(oppo) ?([\w ]+) bui/i                                             // OPPO
4107            ], [VENDOR, MODEL, [TYPE, MOBILE]], [
4108
4109            /(kobo)\s(ereader|touch)/i,                                         // Kobo
4110            /(archos) (gamepad2?)/i,                                            // Archos
4111            /(hp).+(touchpad(?!.+tablet)|tablet)/i,                             // HP TouchPad
4112            /(kindle)\/([\w\.]+)/i,                                             // Kindle
4113            /(nook)[\w ]+build\/(\w+)/i,                                        // Nook
4114            /(dell) (strea[kpr\d ]*[\dko])/i,                                   // Dell Streak
4115            /(le[- ]+pan)[- ]+(\w{1,9}) bui/i,                                  // Le Pan Tablets
4116            /(trinity)[- ]*(t\d{3}) bui/i,                                      // Trinity Tablets
4117            /(gigaset)[- ]+(q\w{1,9}) bui/i,                                    // Gigaset Tablets
4118            /(vodafone) ([\w ]+)(?:\)| bui)/i                                   // Vodafone
4119            ], [VENDOR, MODEL, [TYPE, TABLET]], [
4120
4121            /(surface duo)/i                                                    // Surface Duo
4122            ], [MODEL, [VENDOR, MICROSOFT], [TYPE, TABLET]], [
4123            /droid [\d\.]+; (fp\du?)(?: b|\))/i                                 // Fairphone
4124            ], [MODEL, [VENDOR, 'Fairphone'], [TYPE, MOBILE]], [
4125            /(u304aa)/i                                                         // AT&T
4126            ], [MODEL, [VENDOR, 'AT&T'], [TYPE, MOBILE]], [
4127            /\bsie-(\w*)/i                                                      // Siemens
4128            ], [MODEL, [VENDOR, 'Siemens'], [TYPE, MOBILE]], [
4129            /\b(rct\w+) b/i                                                     // RCA Tablets
4130            ], [MODEL, [VENDOR, 'RCA'], [TYPE, TABLET]], [
4131            /\b(venue[\d ]{2,7}) b/i                                            // Dell Venue Tablets
4132            ], [MODEL, [VENDOR, 'Dell'], [TYPE, TABLET]], [
4133            /\b(q(?:mv|ta)\w+) b/i                                              // Verizon Tablet
4134            ], [MODEL, [VENDOR, 'Verizon'], [TYPE, TABLET]], [
4135            /\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i                       // Barnes & Noble Tablet
4136            ], [MODEL, [VENDOR, 'Barnes & Noble'], [TYPE, TABLET]], [
4137            /\b(tm\d{3}\w+) b/i
4138            ], [MODEL, [VENDOR, 'NuVision'], [TYPE, TABLET]], [
4139            /\b(k88) b/i                                                        // ZTE K Series Tablet
4140            ], [MODEL, [VENDOR, 'ZTE'], [TYPE, TABLET]], [
4141            /\b(nx\d{3}j) b/i                                                   // ZTE Nubia
4142            ], [MODEL, [VENDOR, 'ZTE'], [TYPE, MOBILE]], [
4143            /\b(gen\d{3}) b.+49h/i                                              // Swiss GEN Mobile
4144            ], [MODEL, [VENDOR, 'Swiss'], [TYPE, MOBILE]], [
4145            /\b(zur\d{3}) b/i                                                   // Swiss ZUR Tablet
4146            ], [MODEL, [VENDOR, 'Swiss'], [TYPE, TABLET]], [
4147            /\b((zeki)?tb.*\b) b/i                                              // Zeki Tablets
4148            ], [MODEL, [VENDOR, 'Zeki'], [TYPE, TABLET]], [
4149            /\b([yr]\d{2}) b/i,
4150            /\b(dragon[- ]+touch |dt)(\w{5}) b/i                                // Dragon Touch Tablet
4151            ], [[VENDOR, 'Dragon Touch'], MODEL, [TYPE, TABLET]], [
4152            /\b(ns-?\w{0,9}) b/i                                                // Insignia Tablets
4153            ], [MODEL, [VENDOR, 'Insignia'], [TYPE, TABLET]], [
4154            /\b((nxa|next)-?\w{0,9}) b/i                                        // NextBook Tablets
4155            ], [MODEL, [VENDOR, 'NextBook'], [TYPE, TABLET]], [
4156            /\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i                  // Voice Xtreme Phones
4157            ], [[VENDOR, 'Voice'], MODEL, [TYPE, MOBILE]], [
4158            /\b(lvtel\-)?(v1[12]) b/i                                           // LvTel Phones
4159            ], [[VENDOR, 'LvTel'], MODEL, [TYPE, MOBILE]], [
4160            /\b(ph-1) /i                                                        // Essential PH-1
4161            ], [MODEL, [VENDOR, 'Essential'], [TYPE, MOBILE]], [
4162            /\b(v(100md|700na|7011|917g).*\b) b/i                               // Envizen Tablets
4163            ], [MODEL, [VENDOR, 'Envizen'], [TYPE, TABLET]], [
4164            /\b(trio[-\w\. ]+) b/i                                              // MachSpeed Tablets
4165            ], [MODEL, [VENDOR, 'MachSpeed'], [TYPE, TABLET]], [
4166            /\btu_(1491) b/i                                                    // Rotor Tablets
4167            ], [MODEL, [VENDOR, 'Rotor'], [TYPE, TABLET]], [
4168            /(shield[\w ]+) b/i                                                 // Nvidia Shield Tablets
4169            ], [MODEL, [VENDOR, 'Nvidia'], [TYPE, TABLET]], [
4170            /(sprint) (\w+)/i                                                   // Sprint Phones
4171            ], [VENDOR, MODEL, [TYPE, MOBILE]], [
4172            /(kin\.[onetw]{3})/i                                                // Microsoft Kin
4173            ], [[MODEL, /\./g, ' '], [VENDOR, MICROSOFT], [TYPE, MOBILE]], [
4174            /droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i             // Zebra
4175            ], [MODEL, [VENDOR, ZEBRA], [TYPE, TABLET]], [
4176            /droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i
4177            ], [MODEL, [VENDOR, ZEBRA], [TYPE, MOBILE]], [
4178
4179            ///////////////////
4180            // SMARTTVS
4181            ///////////////////
4182
4183            /smart-tv.+(samsung)/i                                              // Samsung
4184            ], [VENDOR, [TYPE, SMARTTV]], [
4185            /hbbtv.+maple;(\d+)/i
4186            ], [[MODEL, /^/, 'SmartTV'], [VENDOR, SAMSUNG], [TYPE, SMARTTV]], [
4187            /(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i        // LG SmartTV
4188            ], [[VENDOR, LG], [TYPE, SMARTTV]], [
4189            /(apple) ?tv/i                                                      // Apple TV
4190            ], [VENDOR, [MODEL, APPLE+' TV'], [TYPE, SMARTTV]], [
4191            /crkey/i                                                            // Google Chromecast
4192            ], [[MODEL, CHROME+'cast'], [VENDOR, GOOGLE], [TYPE, SMARTTV]], [
4193            /droid.+aft(\w+)( bui|\))/i                                         // Fire TV
4194            ], [MODEL, [VENDOR, AMAZON], [TYPE, SMARTTV]], [
4195            /\(dtv[\);].+(aquos)/i,
4196            /(aquos-tv[\w ]+)\)/i                                               // Sharp
4197            ], [MODEL, [VENDOR, SHARP], [TYPE, SMARTTV]],[
4198            /(bravia[\w ]+)( bui|\))/i                                              // Sony
4199            ], [MODEL, [VENDOR, SONY], [TYPE, SMARTTV]], [
4200            /(mitv-\w{5}) bui/i                                                 // Xiaomi
4201            ], [MODEL, [VENDOR, XIAOMI], [TYPE, SMARTTV]], [
4202            /Hbbtv.*(technisat) (.*);/i                                         // TechniSAT
4203            ], [VENDOR, MODEL, [TYPE, SMARTTV]], [
4204            /\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,                          // Roku
4205            /hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i         // HbbTV devices
4206            ], [[VENDOR, trim], [MODEL, trim], [TYPE, SMARTTV]], [
4207            /\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i                   // SmartTV from Unidentified Vendors
4208            ], [[TYPE, SMARTTV]], [
4209
4210            ///////////////////
4211            // CONSOLES
4212            ///////////////////
4213
4214            /(ouya)/i,                                                          // Ouya
4215            /(nintendo) ([wids3utch]+)/i                                        // Nintendo
4216            ], [VENDOR, MODEL, [TYPE, CONSOLE]], [
4217            /droid.+; (shield) bui/i                                            // Nvidia
4218            ], [MODEL, [VENDOR, 'Nvidia'], [TYPE, CONSOLE]], [
4219            /(playstation [345portablevi]+)/i                                   // Playstation
4220            ], [MODEL, [VENDOR, SONY], [TYPE, CONSOLE]], [
4221            /\b(xbox(?: one)?(?!; xbox))[\); ]/i                                // Microsoft Xbox
4222            ], [MODEL, [VENDOR, MICROSOFT], [TYPE, CONSOLE]], [
4223
4224            ///////////////////
4225            // WEARABLES
4226            ///////////////////
4227
4228            /((pebble))app/i                                                    // Pebble
4229            ], [VENDOR, MODEL, [TYPE, WEARABLE]], [
4230            /(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i                              // Apple Watch
4231            ], [MODEL, [VENDOR, APPLE], [TYPE, WEARABLE]], [
4232            /droid.+; (glass) \d/i                                              // Google Glass
4233            ], [MODEL, [VENDOR, GOOGLE], [TYPE, WEARABLE]], [
4234            /droid.+; (wt63?0{2,3})\)/i
4235            ], [MODEL, [VENDOR, ZEBRA], [TYPE, WEARABLE]], [
4236            /(quest( 2| pro)?)/i                                                // Oculus Quest
4237            ], [MODEL, [VENDOR, FACEBOOK], [TYPE, WEARABLE]], [
4238
vendor: 2,312 bytes, lines 4239-4285
4239            ///////////////////
4240            // EMBEDDED
4241            ///////////////////
4242
4243            /(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i                              // Tesla
4244            ], [VENDOR, [TYPE, EMBEDDED]], [
4245            /(aeobc)\b/i                                                        // Echo Dot
4246            ], [MODEL, [VENDOR, AMAZON], [TYPE, EMBEDDED]], [
4247
4248            ////////////////////
4249            // MIXED (GENERIC)
4250            ///////////////////
4251
4252            /droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i    // Android Phones from Unidentified Vendors
4253            ], [MODEL, [TYPE, MOBILE]], [
4254            /droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i       // Android Tablets from Unidentified Vendors
4255            ], [MODEL, [TYPE, TABLET]], [
4256            /\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i                      // Unidentifiable Tablet
4257            ], [[TYPE, TABLET]], [
4258            /(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i    // Unidentifiable Mobile
4259            ], [[TYPE, MOBILE]], [
4260            /(android[-\w\. ]{0,9});.+buil/i                                    // Generic Android Device
4261            ], [MODEL, [VENDOR, 'Generic']]
4262        ],
4263
4264        engine : [[
4265
4266            /windows.+ edge\/([\w\.]+)/i                                       // EdgeHTML
4267            ], [VERSION, [NAME, EDGE+'HTML']], [
4268
4269            /webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i                         // Blink
4270            ], [VERSION, [NAME, 'Blink']], [
4271
4272            /(presto)\/([\w\.]+)/i,                                             // Presto
4273            /(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i, // WebKit/Trident/NetFront/NetSurf/Amaya/Lynx/w3m/Goanna
4274            /ekioh(flow)\/([\w\.]+)/i,                                          // Flow
4275            /(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,                           // KHTML/Tasman/Links
4276            /(icab)[\/ ]([23]\.[\d\.]+)/i,                                      // iCab
4277            /\b(libweb)/i
4278            ], [NAME, VERSION], [
4279
4280            /rv\:([\w\.]{1,9})\b.+(gecko)/i                                     // Gecko
4281            ], [VERSION, NAME]
4282        ],
4283
4284        os : [[
4285
vendor: 3,266 bytes, lines 4286-4337
4286            // Windows
4287            /microsoft (windows) (vista|xp)/i                                   // Windows (iTunes)
4288            ], [NAME, VERSION], [
4289            /(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i             // Windows Phone
4290            ], [NAME, [VERSION, strMapper, windowsVersionMap]], [
4291            /windows nt 6\.2; (arm)/i,                                        // Windows RT
4292            /windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,
4293            /(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i
4294            ], [[VERSION, strMapper, windowsVersionMap], [NAME, 'Windows']], [
4295
4296            // iOS/macOS
4297            /ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,              // iOS
4298            /(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,
4299            /cfnetwork\/.+darwin/i
4300            ], [[VERSION, /_/g, '.'], [NAME, 'iOS']], [
4301            /(mac os x) ?([\w\. ]*)/i,
4302            /(macintosh|mac_powerpc\b)(?!.+haiku)/i                             // Mac OS
4303            ], [[NAME, MAC_OS], [VERSION, /_/g, '.']], [
4304
4305            // Mobile OSes
4306            /droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i                    // Android-x86/HarmonyOS
4307            ], [VERSION, NAME], [                                               // Android/WebOS/QNX/Bada/RIM/Maemo/MeeGo/Sailfish OS
4308            /(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,
4309            /(blackberry)\w*\/([\w\.]*)/i,                                      // Blackberry
4310            /(tizen|kaios)[\/ ]([\w\.]+)/i,                                     // Tizen/KaiOS
4311            /\((series40);/i                                                    // Series 40
4312            ], [NAME, VERSION], [
4313            /\(bb(10);/i                                                        // BlackBerry 10
4314            ], [VERSION, [NAME, BLACKBERRY]], [
4315            /(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i         // Symbian
4316            ], [VERSION, [NAME, 'Symbian']], [
4317            /mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i // Firefox OS
4318            ], [VERSION, [NAME, FIREFOX+' OS']], [
4319            /web0s;.+rt(tv)/i,
4320            /\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i                              // WebOS
4321            ], [VERSION, [NAME, 'webOS']], [
4322            /watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i                              // watchOS
4323            ], [VERSION, [NAME, 'watchOS']], [
4324
4325            // Google Chromecast
4326            /crkey\/([\d\.]+)/i                                                 // Google Chromecast
4327            ], [VERSION, [NAME, CHROME+'cast']], [
4328            /(cros) [\w]+(?:\)| ([\w\.]+)\b)/i                                  // Chromium OS
4329            ], [[NAME, CHROMIUM_OS], VERSION],[
4330
4331            // Smart TVs
4332            /panasonic;(viera)/i,                                               // Panasonic Viera
4333            /(netrange)mmh/i,                                                   // Netrange
4334            /(nettv)\/(\d+\.[\w\.]+)/i,                                         // NetTV
4335
4336            // Console
4337            /(nintendo|playstation) ([wids345portablevuch]+)/i,                 // Nintendo
4337/Playstation
4338            /(xbox); +xbox ([^\);]+)/i,                                         // Microsoft Xbox (360, One, X, S, Series X, Series S)
4339
4340            // Other
4341            /\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,                            // Joli/Palm
4342            /(mint)[\/\(\) ]?(\w*)/i,                                           // Mint
4343            /(mageia|vectorlinux)[; ]/i,                                        // Mageia/VectorLinux
4344            /([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,
4345                                                                                // Ubuntu/Debian/SUSE/Gentoo/Arch/Slackware/Fedora/Mandriva/CentOS/PCLinuxOS/RedHat/Zenwalk/Linpus/Raspbian/Plan9/Minix/RISCOS/Contiki/Deepin/Manjaro/elementary/Sabayon/Linspire
4346            /(hurd|linux) ?([\w\.]*)/i,                                         // Hurd/Linux
4347            /(gnu) ?([\w\.]*)/i,                                                // GNU
4348            /\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i, // FreeBSD/NetBSD/OpenBSD/PC-BSD/GhostBSD/DragonFly
4349            /(haiku) (\w+)/i                                                    // Haiku
4350            ], [NAME, VERSION], [
4351            /(sunos) ?([\w\.\d]*)/i                                             // Solaris
4352            ], [[NAME, 'Solaris'], VERSION], [
4353            /((?:open)?solaris)[-\/ ]?([\w\.]*)/i,                              // Solaris
4354            /(aix) ((\d)(?=\.|\)| )[\w\.])*/i,                                  // AIX
4355            /\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i, // BeOS/OS2/AmigaOS/MorphOS/OpenVMS/Fuchsia/HP-UX/SerenityOS
4356            /(unix) ?([\w\.]*)/i                                                // UNIX
4357            ], [NAME, VERSION]
4358        ]
4359    };
4360
4361    /////////////////
4362    // Constructor
4363    ////////////////
4364
4365    var UAParser = function (ua, extensions) {
4366
4367        if (typeof ua === OBJ_TYPE) {
4368            extensions = ua;
4369            ua = undefined;
4370        }
4371
4372        if (!(this instanceof UAParser)) {
4373            return new UAParser(ua, extensions).getResult();
4374        }
4375
4376        var _navigator = (typeof window !== UNDEF_TYPE && window.navigator) ? window.navigator : undefined;
4377        var _ua = ua || ((_navigator && _navigator.userAgent) ? _navigator.userAgent : EMPTY);
4378        var _uach = (_navigator && _navigator.userAgentData) ? _navigator.userAgentData : undefined;
4379        var _rgxmap = extensions ? extend(regexes, extensions) : regexes;
4380        var _isSelfNav = _navigator && _navigator.userAgent == _ua;
4381
4382        this.getBrowser = function () {
4383            var _browser = {};
4384            _browser[NAME] = undefined;
4385            _browser[VERSION] = undefined;
4386            rgxMapper.call(_browser, _ua, _rgxmap.browser);
4387            _browser[MAJOR] = majorize(_browser[VERSION]);
4388            // Brave-specific detection
4389            if (_isSelfNav && _navigator && _navigator.brave && typeof _navigator.brave.isBrave == FUNC_TYPE) {
4390                _browser[NAME] = 'Brave';
4391            }
4392            return _browser;
4393        };
4394        this.getCPU = function () {
4395            var _cpu = {};
4396            _cpu[ARCHITECTURE] = undefined;
4397            rgxMapper.call(_cpu, _ua, _rgxmap.cpu);
4398            return _cpu;
4399        };
4400        this.getDevice = function () {
4401            var _device = {};
4402            _device[VENDOR] = undefined;
4403            _device[MODEL] = undefined;
4404            _device[TYPE] = undefined;
4405            rgxMapper.call(_device, _ua, _rgxmap.device);
4406            if (_isSelfNav && !_device[TYPE] && _uach && _uach.mobile) {
4407                _device[TYPE] = MOBILE;
4408            }
4409            // iPadOS-specific detection: identified as Mac, but has some iOS-only properties
4410            if (_isSelfNav && _device[MODEL] == 'Macintosh' && _navigator && typeof _navigator.standalone !== UNDEF_TYPE && _navigator.maxTouchPoints && _navigator.maxTouchPoints > 2) {
4411                _device[MODEL] = 'iPad';
4412                _device[TYPE] = TABLET;
4413            }
4414            return _device;
4415        };
4416        this.getEngine = function () {
4417            var _engine = {};
4418            _engine[NAME] = undefined;
4419            _engine[VERSION] = undefined;
4420            rgxMapper.call(_engine, _ua, _rgxmap.engine);
4421            return _engine;
4422        };
4423        this.getOS = function () {
4424            var _os = {};
4425            _os[NAME] = undefined;
4426            _os[VERSION] = undefined;
4427            rgxMapper.call(_os, _ua, _rgxmap.os);
4428            if (_isSelfNav && !_os[NAME] && _uach && _uach.platform != 'Unknown') {
4429                _os[NAME] = _uach.platform  
4430                                    .replace(/chrome os/i, CHROMIUM_OS)
4431                                    .replace(/macos/i, MAC_OS);           // backward compatibility
4432            }
4433            return _os;
4434        };
4435        this.getResult = function () {
4436            return {
4437                ua      : this.getUA(),
4438                browser : this.getBrowser(),
4439                engine  : this.getEngine(),
4440                os      : this.getOS(),
4441                device  : this.getDevice(),
4442                cpu     : this.getCPU()
4443            };
4444        };
4445        this.getUA = function () {
4446            return _ua;
4447        };
4448        this.setUA = function (ua) {
4449            _ua = (typeof ua === STR_TYPE && ua.length > UA_MAX_LENGTH) ? trim(ua, UA_MAX_LENGTH) : ua;
4450            return this;
4451        };
4452        this.setUA(_ua);
4453        return this;
4454    };
4455
4456    UAParser.VERSION = LIBVERSION;
4457    UAParser.BROWSER =  enumerize([NAME, VERSION, MAJOR]);
4458    UAParser.CPU = enumerize([ARCHITECTURE]);
4459    UAParser.DEVICE = enumerize([MODEL, VENDOR, TYPE, CONSOLE, MOBILE, SMARTTV, TABLET, WEARABLE, EMBEDDED]);
4460    UAParser.ENGINE = UAParser.OS = enumerize([NAME, VERSION]);
4461
4462    ///////////
4463    // Export
4464    //////////
4465
4466    // check js environment
4467    if (typeof(exports) !== UNDEF_TYPE) {
4468        // nodejs env
4469        if (typeof module !== UNDEF_TYPE && module.exports) {
4470            exports = module.exports = UAParser;
4471        }
4472        exports.UAParser = UAParser;
4473    } else {
4474        // requirejs env (optional)
4475        if (typeof(define) === FUNC_TYPE && define.amd) {
4476            define(function () {
4477                return UAParser;
4478            });
4479        } else if (typeof window !== UNDEF_TYPE) {
4480            // browser env
4481            window.UAParser = UAParser;
4482        }
4483    }
4484
4485    // jQuery/Zepto specific (optional)
4486    // Note:
4487    //   In AMD env the global scope should be kept clean, but jQuery is an exception.
4488    //   jQuery always exports to global scope, unless jQuery.noConflict(true) is used,
4489    //   and we should catch that.
4490    var $ = typeof window !== UNDEF_TYPE && (window.jQuery || window.Zepto);
4491    if ($ && !$.ua) {
4492        var parser = new UAParser();
4493        $.ua = parser.getResult();
4494        $.ua.get = function () {
4495            return parser.getUA();
4496        };
4497        $.ua.set = function (ua) {
4498            parser.setUA(ua);
4499            var result = parser.getResult();
4500            for (var prop in result) {
4501                $.ua[prop] = result[prop];
4502            }
4503        };
4504    }
4505
4506})(typeof window === 'object' ? window : this);
4507
4508!function(e){"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?module.exports=e():window.wNumb=e()}(function(){"use strict";var o=["decimals","thousand","mark","prefix","suffix","encoder","decoder","negativeBefore","negative","edit","undo"];function w(e){return e.split("").reverse().join("")}function h(e,t){return e.substring(0,t.length)===t}function f(e,t,n){if((e[t]||e[n])&&e[t]===e[n])throw new Error(t)}function x(e){return"number"==typeof e&&isFinite(e)}function n(e,t,n,r,i,o,f,u,s,c,a,p){var d,l,h,g=p,v="",m="";return o&&(p=o(p)),!!x(p)&&(!1!==e&&0===parseFloat(p.toFixed(e))&&(p=0),p<0&&(d=!0,p=Math.abs(p)),!1!==e&&(p=function(e,t){return e=e.toString().split("e"),(+((e=(e=Math.round(+(e[0]+"e"+(e[1]?+e[1]+t:t)))).toString().split("e"))[0]+"e"+(e[1]?e[1]-t:-t))).toFixed(t)}(p,e)),-1!==(p=p.toString()).indexOf(".")?(h=(l=p.split("."))[0],n&&(v=n+l[1])):h=p,t&&(h=w((h=w(h).match(/.{1,3}/g)).join(w(t)))),d&&u&&(m+=u),r&&(m+=r),d&&s&&(m+=s),m+=h,m+=v,i&&(m+=i),c&&(m=c(m,g)),m)}function r(e,t,n,r,i,o,f,u,s,c,a,p){var d,l="";return a&&(p=a(p)),!(!p||"string"!=typeof p)&&(u&&h(p,u)&&(p=p.replace(u,""),d=!0),r&&h(p,r)&&(p=p.replace(r,"")),s&&h(p,s)&&(p=p.replace(s,""),d=!0),i&&function(e,t){return e.slice(-1*t.length)===t}(p,i)&&(p=p.slice(0,-1*i.length)),t&&(p=p.split(t).join("")),n&&(p=p.replace(n,".")),d&&(l+="-"),""!==(l=(l+=p).replace(/[^0-9\.\-.]/g,""))&&(l=Number(l),f&&(l=f(l)),!!x(l)&&l))}function i(e,t,n){var r,i=[];for(r=0;r<o.length;r+=1)i.push(e[o[r]]);return i.push(n),t.apply("",i)}return function e(t){if(!(this instanceof e))return new e(t);"object"==typeof t&&(t=function(e){var t,n,r,i={};for(void 0===e.suffix&&(e.suffix=e.postfix),t=0;t<o.length;t+=1)if(void 0===(r=e[n=o[t]]))"negative"!==n||i.negativeBefore?"mark"===n&&"."!==i.thousand?i[n]=".":i[n]=!1:i[n]="-";else if("decimals"===n){if(!(0<=r&&r<8))throw new Error(n);i[n]=r}else if("encoder"===n||"decoder"===n||"edit"===n||"undo"===n){if("function"!=typeof r)throw new Error(n);i[n]=r}else{if("string"!=typeof r)throw new Error(n);i[n]=r}return f(i,"mark","thousand"),f(i,"prefix","negative"),f(i,"prefix","negativeBefore"),i}(t),this.to=function(e){return i(t,n,e)},this.from=function(e){return i(t,r,e)})}});
4509$(document).ready(function(){
4510    document.body.classList.add('loaded');
4511});
4512
4513
4514var uaDetect = new UAParser().getResult();
4515
4516console.log(uaDetect);
4517EA.Methods.accessibilityWidget = function($this) {
4518    $this.click(function(e) {
4519        e.preventDefault();
4520        if (typeof UserWay !== 'undefined') {
4521            UserWay.widgetToggle();
4522        }
4523    });
4524}
4525EA.Methods.addActive = function($this) {
4526    const actives = $this.find('.toggle-active');
4527    
4528    actives.on('click', function () {
4529        actives.removeClass('active');
4530        $(this).addClass('active');
4531    });
4532};
4533EA.Methods.addActiveToggleTrigger = function($this) {
4534    const actives = $this.find('.toggle-active');
4535    const radio = $('.form-1-checkbox-wrapper input[type="radio"]');
4536    const radio1 = $(".form-1-checkbox-wrapper input:radio[value='voucher-1']");
4537    const radio2 = $(".form-1-checkbox-wrapper input:radio[value='voucher-2']");
4538
4539    radio.click(function () {
4540        if ($(this).val() === 'voucher-1') {
4541            $('.hidden-1').addClass('hidden');
4542            $('.hidden-2').removeClass('hidden');
4543            $(this).parent().parent().parent().removeClass('active');
4544            actives.siblings().prop('checked', false);
4545        } else if ($(this).val() === 'voucher-2') {
4546            $('.hidden-2').addClass('hidden');
4547            $('.hidden-1').removeClass('hidden');
4548            $(this).parent().parent().parent().addClass('active');
4549            actives.siblings().prop('checked', true);
4550        }
4551    });
4552    
4553    actives.on('click', function () {
4554        $(this).parent().parent().parent().toggleClass('active');
4555        $(this).parent().parent().parent().parent().toggleClass('active');
4556
4557        if($(this).parent().parent().parent().parent().hasClass('active')) {
4558            $(this).parent().parent().parent().parent().find('.euros-wrap').removeClass('hidden');
4559            $(this).parent().parent().parent().parent().find('.mb-wrap').addClass('hidden');
4560            radio2.prop('checked', true);
4561        } else {
4562            $(this).parent().parent().parent().parent().find('.euros-wrap').addClass('hidden');
4563            $(this).parent().parent().parent().parent().find('.mb-wrap').removeClass('hidden');
4564            radio1.prop('checked', true);
4565        }
4566    });
4567};
4568EA.Methods.anim = function($this) {
4569    const animUp = $this.find('.anim-up');
4570    
4571    gsap.fromTo(animUp, {
4572        y: 150,
4573        alpha: 0
4574    },
4575    {
4576        y: 0,
4577        alpha: 1,
4578        stagger: 0.1,
4579        duration: 0.8,
4580        ease: 'power2.inOut',
4581        scrollTrigger: {
4582            trigger: $this,
4583            start: 'top 90%'
4584        },
4585        clearProps: 'all'
4586    });
4587
4588}
4589EA.Methods.availableAddOnSwiper = function ($this) {
4590    const slider = $this.find('.swiper-container');
4591    const pagination = $this.find('.swiper-pagination');
4592    const breakpoint = window.matchMedia('(min-width: 1401px)');
4593    const breakpoint2 = window.matchMedia('(max-width: 1075px)');
4594    let thumbsSwiper;
4595
4596    const slides = $this.find('.swiper-slide');
4597    const sliderWrapper = $this.find('.swiper-wrapper');
4598    
4599    thumbsSwiper = new Swiper(slider, {
4600        speed: 600,
4601        loop: false,
4602        slidesPerView: 1,
4603        spaceBetween: 0,
4604        allowTouchMove: true,
4605        pagination: {
4606            el: pagination, 
4607            clickable: true,
4608        },
4609        breakpoints: {
4610            800: {
4611                slidesPerView: 2.035,
4612                slidesOffsetBefore: 10,
4613                slidesOffsetAfter: 10,
4614                spaceBetween: 20,
4615            },
4616            1200: {
4617                slidesPerView: 3.035,
4618                slidesOffsetBefore: 10,
4619                slidesOffsetAfter: 10,
4620                spaceBetween: 20,
4621            },
4622            1400: {
4623                slidesPerView: 4,
4624                slidesOffsetBefore: 0,
4625                slidesOffsetAfter: 0,
4626                spaceBetween: 20,
4627            }
4628        }
4629    });
4630
4631    function paginationCheck() {
4632        let slidesWidthSum = 0;
4633
4634        if (slides.length > 0) {
4635            for (let i = 0; i < slides.length; i++) {
4636                slidesWidthSum += slides[i].offsetWidth;
4637                
4638            }
4639        }
4640
4641        if (sliderWrapper.width() < slidesWidthSum) {
4642            pagination.removeClass('swiper-pagination-hidden');
4643        } else {
4644            pagination.addClass('swiper-pagination-hidden');
4645        }
4646    }
4647
4648    paginationCheck();
4649
4650    var resizeTimeoutId;
4651
4652    window.addEventListener('resize', function() {
4653        clearTimeout(resizeTimeoutId);
4654        resizeTimeoutId = setTimeout(function() {
4655            paginationCheck();
4656        }, 100);
4657    });
4658};
4659EA.Methods.b2bSwiper = function($this) {
4660    const swiperEl = $this.find('.swiper-container'); 
4661    const navigation = $this.find('.b2b-swiper-navigation-wrapper');
4662    const prevBtn = $this.find('.swiper-button-prev');
4663    const nextBtn = $this.find('.swiper-button-next');
4664
4665    const swiper = new Swiper(swiperEl, {
4666        spaceBetween: 20,
4667        speed: 600,
4668        slidesPerView: 'auto',
4669        navigation: {
4670            nextEl: nextBtn,
4671            prevEl: prevBtn
4672        },
4673    });
4674
4675    function updateSwiperTouch(swiperInstance) {
4676        const slideWidth = swiperInstance.slides[0].offsetWidth || 1;
4677        const visibleSlides = Math.floor(swiperInstance.width / slideWidth);
4678
4679        if (swiperInstance.slides.length <= visibleSlides) {
4680            swiperInstance.allowTouchMove = false;
4681            navigation.addClass('swiper-pagination-disabled');
4682        } else {
4683            swiperInstance.allowTouchMove = true;
4684            navigation.removeClass('swiper-pagination-disabled');
4685        }
4686    }
4687    
4688    updateSwiperTouch(swiper)
4689
4690    window.addEventListener('resize', () => updateSwiperTouch(swiper));
4691    swiper.on('update', () => updateSwiperTouch(swiper));
4692
4693}
4694EA.Methods.beforeAfter = function($this) {
4695    let active = false;
4696    const scroller = $this[0].querySelector('.vod-scroller');
4697    const wrapper = $this[0].querySelector('.vod-slide-wrap');
4698    const after = $this[0].querySelector('.vod-after');
4699    let timerID;
4700    let counter = 0;
4701    let pressHoldDuration = 5;
4702
4703    function pressingDown() {
4704        // Start the timer
4705        requestAnimationFrame(timer);
4706
4707        active = true;
4708        scroller.classList.add('scrolling');
4709    }
4710
4711    function notPressingDown() {
4712        // Stop the timer
4713        cancelAnimationFrame(timerID);
4714        counter = 0;
4715        active = false;
4716        scroller.classList.remove('scrolling');
4717    }
4718
4719    function timer() {
4720
4721        if (counter < pressHoldDuration) {
4722            timerID = requestAnimationFrame(timer);
4723            counter++;
4724        } 
4725    }
4726
4727    function holdTouch(e) {
4728        if (!active) return;
4729        let x = e.changedTouches[0].pageX;
4730        
4731        x -= wrapper.getBoundingClientRect().left;
4732        scrollIt(x);
4733
4734    }
4735
4736    scroller.addEventListener('touchstart', pressingDown);
4737    scroller.addEventListener('touchend', notPressingDown);
4738    scroller.addEventListener('touchmove', holdTouch);
4739
4740
4741    scroller.addEventListener('mousedown', function() {
4742        active = true;
4743        scroller.classList.add('scrolling');
4744    });
4745
4746    document.body.addEventListener('mouseup', function() {
4747        active = false;
4748        scroller.classList.remove('scrolling');
4749    });
4750
4751    document.body.addEventListener('mouseleave',function() {
4752        active = false;
4753        scroller.classList.remove('scrolling');
4754    });
4755
4756    document.body.addEventListener('mousemove', function(e) {
4757        if (!active) return;
4758        let x = e.pageX;
4759        x -= wrapper.getBoundingClientRect().left;
4760        scrollIt(x);
4761    });
4762
4763    function scrollIt(x) {
4764        let transform = Math.max(0, (Math.min(x, wrapper.offsetWidth)));
4765        after.style.width = transform + 'px';
4766        scroller.style.left = transform + 'px';
4767    }
4768
4769    scrollIt(transform / 2);
4770
4771    window.addEventListener('resize', function() {
4772        scrollIt(x);
4773    })
4774
4775    scroller.addEventListener('touchstart', function() {
4776        active = true;
4777        scroller.classList.add('scrolling');
4778    });
4779
4780    document.body.addEventListener('touchend', function() {
4781        active = false;
4782        scroller.classList.remove('scrolling');
4783    });
4784
4785    document.body.addEventListener('touchcancel', function() {
4786        active = false;
4787        scroller.classList.remove('scrolling');
4788    });
4789}
4790EA.Methods.channelSliderEon = function($this){
4791    var slider = $this.find('.swiper-container');
4792    var next = $this.find('.swiper-button-next');
4793    var prev = $this.find('.swiper-button-prev');
4794    var swiper = new Swiper(slider, {
4795        speed: 600,
4796        slidesPerView: 1.3,
4797        spaceBetween: 25,
4798        freeMode: true,
4799        navigation: {
4800            nextEl: next,
4801            prevEl: prev,
4802        },
4803        breakpoints: {
4804            600: {
4805                slidesPerView: 2.2,
4806                spaceBetween: 20,
4807            },
4808            1200: {
4809                slidesPerView: 3,
4810                spaceBetween: 20,
4811            },
4812            1500: {
4813                slidesPerView: 4,
4814                spaceBetween: 30, 
4815            }
4816        }
4817    });
4818    $this.find('.tv-channels-list-item').on('click', function () {
4819        [...swiper].forEach(function (el) {
4820            setTimeout(function () {
4821                el.slideTo(0, 1);
4822            }, 400);
4823        });
4824    })
4825};
4826
4827EA.Methods.chargesDropdown = function($this){
4828    const button = $this[0].querySelector('.charges-header');
4829    const dropdownContent = $this[0].querySelector('.charges-body');
4830    const dropdownContentInner = dropdownContent.querySelector('.charges-body-inner');
4831    let timeoutId;
4832
4833    button.addEventListener('click', function() {
4834        clearTimeout(timeoutId);
4835
4836        button.classList.toggle('active');
4837        dropdownContent.classList.toggle('active');
4838
4839        if(dropdownContent.classList.contains('service')) return;
4840        dropdownContent.classList.contains('active') ? timeoutId = setTimeout(function () {dropdownContentInner.style.overflow = 'visible'}, 600) : dropdownContentInner.style.overflow = '';
4841    });
4842};
4843EA.Methods.checkboxRadioBehaviour = function($this) {
4844    const inputs = $this[0].querySelectorAll('input[type="checkbox"]');
4845    const labels = $this[0].querySelectorAll('.device-plan-label');
4846    
4847    for (let i = 0; i < labels.length; i++) {        
4848        labels[i].addEventListener('click', (e) => {
4849            e.preventDefault();
4850            if(inputs[i].hasAttribute('checked')) {
4851                inputs[i].removeAttribute('checked');
4852            } else {
4853                inputs.forEach(input => {
4854                    input.removeAttribute('checked'); 
4855                })
4856                inputs[i].setAttribute('checked', true);
4857            }
4858        });
4859    }
4860
4861};
4862
4863EA.Methods.closeModal = function($this) {
4864    $this.on('click', (e) => {
4865        $(document.body).css('overflow', '');
4866        e.preventDefault();
4867        $(document).find('.modal').removeClass('active')
4868    });
4869};
4870
4871EA.Methods.countdownBanner = function($this) {
4872	const header = $('header');
4873	const mobileMenu = $('.moible-menu-wrapper');
4874	const flipDownEl = $this.find('.flipdown');
4875	const dataTime = $this.data('time');
4876	const close = $this.find('.banner-close-link');
4877	const main = $(document).find('main');
4878
4879	let flipDownInstance;
4880
4881	const currentTime= new Date().getTime() / 1000;
4882	if(currentTime < dataTime) {
4883		createCountdown();
4884	}
4885
4886	close.on('click', (e) => {
4887		e.preventDefault();
4888		closeCountdown();
4889	});
4890
4891	function createCountdown() {
4892		header.addClass('has-counter');
4893		mobileMenu.addClass('has-counter');
4894		flipDownInstance = new FlipDown(dataTime, {
4895		headings: ["Days", "Hours", "Minutes", "Seconds"],
4896		}, flipDownEl).start();
4897
4898		flipDownInstance.ifEnded(() => {
4899			closeCountdown();
4900		});
4901	}
4902
4903	function closeCountdown() {
4904		if(flipDownInstance) {
4905			header.removeClass('has-counter');
4906			mobileMenu.removeClass('has-counter');
4907			header.css('transform', 'translateY(0)');
4908			var headerHeight = header.outerHeight();
4909			main.css('padding-top', headerHeight + 'px');
4910		}
4911	}
4912}
4913EA.Methods.countrySearchDropdown = function($this){
4914    const input = $this[0].querySelector('input');
4915    const dropdownWrapper = $this[0].querySelector('.dropdown-list-wrapper');
4916    const dropdownItems = dropdownWrapper.querySelectorAll('.dropdown-list-item');
4917    const dropdownItemLabels = [...dropdownItems].map(item => item.children[0].textContent.toUpperCase());
4918    const chargesTables = $this[0].nextElementSibling;
4919
4920    if(input.value != '') {
4921        chargesTables.classList.add('active');
4922    }
4923
4924    input.addEventListener('input', () => {
4925        let filter = input.value.toUpperCase();
4926        let elementCounter = 0;
4927        for (i = 0; i < dropdownItems.length; i++) {
4928            const itemLabel = dropdownItems[i].querySelector('.dropdown-list-item-label');
4929            let txtValue = itemLabel.textContent || itemLabel.innerText;
4930            if (txtValue.toUpperCase().indexOf(filter) > -1) {
4931                dropdownItems[i].style.display = "";
4932            } else {
4933                dropdownItems[i].style.display = "none";
4934                elementCounter++;
4935            }
4936
4937            elementCounter === dropdownItems.length ? 
4938            dropdownWrapper.classList.remove('active') :
4939            dropdownWrapper.classList.add('active');
4940        }
4941
4942        if(dropdownItemLabels.includes(input.value.toUpperCase())) {
4943            chargesTables.classList.add('active');  
4944        } else {
4945            chargesTables.classList.remove('active');
4946        }
4947    });
4948
4949    for (let i = 0; i < dropdownItems.length; i++) {
4950        dropdownItems[i].addEventListener('click', () => {
4951            const dropdownLabel = dropdownItems[i].querySelector('.dropdown-list-item-label');
4952            input.value = dropdownLabel.innerText;
4953            chargesTables.classList.add('active');
4954        })
4955    }
4956        
4957    document.addEventListener('click', () => {
4958        dropdownWrapper.classList.remove('active');
4959    });
4960}; 
4961EA.Methods.customDropdownHandler = function ($this) {
4962    const currentDropdownId = $this.attr('id');
4963
4964    const isTypeSearch = $this.hasClass('type-search');
4965    const selectedOptionEl = $this.find('.custom-dropdown-selected-option');
4966
4967    const customDropdownListWrapper = $this.find('.custom-dropdown-list-wrapper');
4968    const customDropdownList = $this.find('.custom-dropdown-list-inner');
4969
4970    customDropdownList.attr('tabindex', '-1');
4971
4972    const selectEl = $this.find('.custom-select-options');
4973    const currSelectedOption = selectEl.find('option:selected');
4974    console.log(currSelectedOption);
4975    const selectElOptionValues = selectEl.find('option').filter(function() {return !$(this).attr('hidden');}).map(function() {return $(this).val();});
4976
4977    if(currSelectedOption.length && currSelectedOption.attr('hidden') && !isTypeSearch) {
4978        selectedOptionEl.addClass('placeholder');
4979    } else {
4980        selectedOptionEl.removeClass('placeholder');
4981    }
4982
4983    const defaultValue = selectEl.val();
4984    const defaultOption = selectEl.find(`[selected]`);
4985
4986    let isDropdownActive = false;
4987    let focusedOptionIndex = selectEl.find('option:not([hidden])').index(defaultOption);
4988
4989    let typeAheadBuffer = '';
4990    let typeAheadTimeout;
4991
4992    const locationLink = $this.find('.location-tracking a');
4993
4994    // Construct the custom options list from the native select
4995    selectElOptionValues.each(function (i, option) {
4996        const id = `${currentDropdownId}_dropdownOption${i}`;
4997        const newCustomDropdownItem = $(`<li role="option" aria-selected="false" id="${id}" class="custom-dropdown-list-item" data-value="${option}">${option}</li>`);
4998
4999        newCustomDropdownItem.on('click', function () {
5000            if(isTypeSearch) {
5001                selectedOptionEl.val(option);
5002            } else {
5003                selectedOptionEl.text(option);
5004            }
5005            selectEl.val(option).trigger('change');
5006
5007            customDropdownList.find('.selected').attr('aria-selected', 'false');
5008            customDropdownList.find('.selected').removeClass('selected');
5009
5010            focusedOptionIndex = customDropdownList.find('.custom-dropdown-list-item').index($(this));
5011
5012            if(!isTypeSearch) {
5013                selectedOptionEl.removeClass('placeholder')
5014            }
5015
5016            $(this).addClass('selected');
5017            $(this).attr('aria-selected', 'true');
5018
5019            closeDropdown();
5020        });
5021
5022        customDropdownList.append(newCustomDropdownItem);
5023    });
5024
5025
5026    // Pick up the default value from the native select on load
5027    if(!isTypeSearch) {
5028        selectedOptionEl.text(defaultValue);
5029    }
5030
5031    customDropdownList.find(`[data-value="${defaultValue}"]`).attr('aria-selected', 'true');
5032    customDropdownList.find(`[data-value="${defaultValue}"]`).addClass('selected');
5033
5034    // Custom dropdown click handler
5035    selectedOptionEl.on('click', function() {
5036        isDropdownActive = selectedOptionEl.hasClass('active');
5037
5038        if(isDropdownActive) {
5039            closeDropdown();
5040        } else {
5041            openDropdown();
5042        }
5043    });
5044
5045    // Custom dropdown enter rebind
5046    selectedOptionEl.on('keydown', function(e) {
5047        if(e.keyCode === 13) {
5048            e.preventDefault();
5049
5050            if(!selectedOptionEl.hasClass('active')) {
5051                openDropdown();
5052                return;
5053            };
5054
5055            let selectedItem = customDropdownList.find('.custom-dropdown-list-item').eq(focusedOptionIndex);
5056            let selectedValue = selectedItem.data('value');
5057
5058            if(isTypeSearch) {
5059                selectedOptionEl.val(selectedValue);
5060            } else {
5061                selectedOptionEl.text(selectedValue);
5062            }
5063            selectedOptionEl.removeClass('placeholder');
5064            selectEl.val(selectedValue).trigger('change');
5065
5066            customDropdownList.find('.selected').attr('aria-selected', 'false');
5067            customDropdownList.find('.selected').removeClass('selected');
5068
5069            selectedItem.addClass('selected');
5070            selectedItem.attr('aria-selected', 'true');
5071
5072            closeDropdown();
5073        }
5074    });
5075
5076    // Handle blur form the selected option element
5077    $this.on('focusout', function(e) {
5078        if(!e.relatedTarget || !$this[0].contains(e.relatedTarget)) {
5079            closeDropdown();
5080        }
5081    });
5082
5083    customDropdownListWrapper.find('.location-tracking').on('mousedown', function(e) {
5084        e.preventDefault();
5085    });
5086
5087    // Handle start of typing for the search dropdown
5088    if(isTypeSearch) {
5089        selectedOptionEl.on('input', function(e) {
5090            openDropdown(); 
5091        });
5092    }
5093
5094    customDropdownListWrapper.find('.location-tracking a').on('click', function(e) {
5095        closeDropdown();
5096    });
5097    
5098    function openDropdown() {
5099        const previouslyActiveDropdown = $('.custom-dropdown-selected-option.active');
5100
5101        if(previouslyActiveDropdown.length) {
5102            previouslyActiveDropdown.removeClass('active');
5103            previouslyActiveDropdown.attr('aria-expanded', 'false');
5104            previouslyActiveDropdown.parent().find('.custom-dropdown-list-wrapper').removeClass('active');
5105
5106            previouslyActiveDropdown.off('keydown.customDropdown');
5107            $(document).off('click.customDropdown');
5108        }
5109
5110        selectedOptionEl.addClass('active');
5111        selectedOptionEl.attr('aria-expanded', 'true');
5112        customDropdownListWrapper.addClass('active');
5113
5114        if(shouldDropUp()) {
5115            customDropdownListWrapper.addClass('drop-up');
5116        } else {
5117            customDropdownListWrapper.removeClass('drop-up');
5118        }
5119
5120        selectedOptionEl.on('keydown.customDropdown', function(e) {
5121            if (!isTypeSearch &&e.key.length === 1 && /[a-zA-Z0-9]/.test(e.key)) {
5122                typeAheadBuffer += e.key.toLowerCase();
5123
5124                clearTimeout(typeAheadTimeout);
5125                typeAheadTimeout = setTimeout(() => typeAheadBuffer = '', 500);
5126
5127                const items = customDropdownList.find('.custom-dropdown-list-item');
5128                const id = items.toArray().findIndex(li =>
5129                    li.textContent.trim().toLowerCase().startsWith(typeAheadBuffer)
5130                );
5131                
5132                if (id !== -1) {
5133                    focusedOptionIndex = id;
5134                    moveFocus(0);
5135                }
5136            }
5137
5138            if (e.key === "Escape") {
5139                closeDropdown();
5140            }
5141
5142            if (e.key === "ArrowUp") {
5143                e.preventDefault();
5144                moveFocus(-1);
5145            }
5146
5147            if (e.key === "ArrowDown") {
5148                e.preventDefault();
5149                moveFocus(1);
5150            }
5151        });
5152
5153        if(isTypeSearch) {
5154            selectedOptionEl.on('input', function(e) {
5155                const query = e.target.value.trim().toLowerCase();
5156                const items = customDropdownList.find('.custom-dropdown-list-item');
5157
5158                items.each(function() {
5159                    const text = $(this).text().trim();
5160                    const lowerText = text.toLowerCase();
5161
5162                    if (query === '' || lowerText.includes(query)) {
5163                        // Show matching item
5164                        $(this).show();
5165
5166                        // Highlight the matching part
5167                        const startIndex = lowerText.indexOf(query);
5168                        if (query !== '' && startIndex !== -1) {
5169                            const before = text.slice(0, startIndex);
5170                            const match = text.slice(startIndex, startIndex + query.length);
5171                            const after = text.slice(startIndex + query.length);
5172
5173                            $(this).html(`${before}<strong>${match}</strong>${after}`);
5174                        } else {
5175                            // Reset to normal if no query
5176                            $(this).text(text);
5177                        }
5178                    } else {
5179                        // Hide non-matching item
5180                        $(this).hide();
5181                    }
5182                });
5183
5184                // Reset focus to first visible item
5185                const firstVisibleIndex = items.toArray().findIndex(li => $(li).css('display') !== 'none');
5186                if (firstVisibleIndex !== -1) {
5187                    focusedOptionIndex = firstVisibleIndex;
5188                    moveFocus(0);
5189                }
5190            });
5191        }
5192
5193        $(document).on('click.customDropdown', function(e) {
5194            if (e.target.closest('.custom-dropdown-wrapper') === null) {
5195                closeDropdown();
5196            }
5197        });
5198
5199        if(locationLink) {
5200            locationLink.attr('tabindex', '0');
5201        }
5202    }
5203
5204    function closeDropdown() {
5205        selectedOptionEl.removeClass('active');
5206        selectedOptionEl.attr('aria-expanded', 'false');
5207        customDropdownListWrapper.removeClass('active');
5208        customDropdownListWrapper.find('.is-focused').removeClass('is-focused');
5209
5210        selectedOptionEl.off('keydown.customDropdown');
5211        $(document).off('click.customDropdown');
5212
5213        if(locationLink) {
5214            locationLink.attr('tabindex', '-1');
5215        }
5216    }
5217
5218    function moveFocus(direction) {
5219        focusedOptionIndex += direction;
5220
5221        if(focusedOptionIndex < 0) focusedOptionIndex = 0;
5222        if(focusedOptionIndex > customDropdownList.children().length - 1) focusedOptionIndex = customDropdownList.children().length - 1;
5223
5224        const newFocusedItem = $(customDropdownList.find('.custom-dropdown-list-item')[focusedOptionIndex]); 
5225        const newFocusedItemValue = newFocusedItem.data('value');
5226
5227        $(customDropdownList.find('.custom-dropdown-list-item.is-focused').removeClass('is-focused'));
5228        newFocusedItem.addClass('is-focused');
5229
5230        selectEl.val(newFocusedItemValue).trigger('change');
5231
5232        // Scroll into view
5233        const optionTop = newFocusedItem.position().top;
5234        const optionBottom = optionTop + newFocusedItem.outerHeight();
5235        const containerHeight = customDropdownList.height();
5236
5237        if(optionBottom > containerHeight) {
5238            customDropdownList.scrollTop(customDropdownList.scrollTop() + optionBottom - containerHeight);
5239        } else if (optionTop < 0) {
5240            customDropdownList.scrollTop(customDropdownList.scrollTop() + optionTop);
5241        }
5242    }
5243
5244    function shouldDropUp() {
5245        const rect = selectedOptionEl[0].getBoundingClientRect();
5246        const viewportHeight = window.innerHeight;
5247
5248        const spaceBelow = viewportHeight - rect.bottom;
5249        const dropdownHeight = customDropdownListWrapper.outerHeight();
5250
5251        return dropdownHeight > spaceBelow;
5252    }
5253}
5254
5255EA.Methods.customTabSwitch = function($this){
5256    const tabs = $this[0].querySelector('.tab-select');
5257    const tabContents = $this[0].querySelectorAll('.custom-tab-content');
5258    
5259    tabs.addEventListener('click', () => {
5260        tabs.classList.toggle('active');
5261        
5262        if(tabs.classList.contains('active')) {
5263            tabContents[1].classList.add('active');
5264            tabContents[0].classList.remove('active');
5265        } else {
5266            tabContents[0].classList.add('active');
5267            tabContents[1].classList.remove('active');
5268        }
5269    })
5270};
5271EA.Methods.customTabSwitchAlternate = function($this){
5272    const tabs = $this[0].querySelectorAll('.sky-packages-tab');
5273    const tabContents = $this[0].querySelectorAll('.custom-tab-content');
5274
5275    tabs.forEach((tab, index) => {
5276        tab.addEventListener('click', () => {
5277            $this[0].querySelector('.sky-packages-tab.active').classList.remove('active');
5278            tab.classList.add('active');
5279
5280            tabContents.forEach((tabContent, tabIndex) => {
5281                if(tabIndex === index) {
5282                    tabContent.classList.add('active');
5283                } else {
5284                    tabContent.classList.remove('active');
5285                }
5286            });
5287        })
5288    });
5289};
5290EA.Methods.dataListCustom = function($this) {
5291    const input = $this[0].querySelector('.datalist-input');
5292    const dataList = $this[0].querySelector('.data-list');
5293    const suggestionBox = $this[0].querySelector('.autocomplete-suggestions');
5294    const label = $this[0];
5295    
5296
5297    input.addEventListener('input', function() {
5298        showSuggestions(this.value);
5299        suggestionBox.classList.add('active');
5300        label.classList.add('active');
5301    });
5302
5303    input.onfocus = function () {
5304        showSuggestions(this.value);
5305        suggestionBox.classList.add('active');
5306        label.classList.add('active');
5307    };
5308
5309    function showSuggestions(value) {
5310        const dataListOptions = $this[0].querySelector('.data-list').options;
5311        suggestionBox.innerHTML = '';
5312        suggestionBox.classList.add('active');
5313        label.classList.add('active');
5314
5315        if (value) {
5316            for (let i = 0; i < dataListOptions.length; i++) {
5317                if (dataListOptions[i].value.toLowerCase().startsWith(value.toLowerCase())) {
5318                    const suggestionItem = document.createElement('div');
5319                    suggestionItem.classList.add('autocomplete-suggestion');
5320                    suggestionItem.textContent = dataListOptions[i].value;
5321                    suggestionItem.onclick = () => selectSuggestion(dataListOptions[i].value);
5322                    suggestionBox.appendChild(suggestionItem);
5323                }
5324            }
5325        }
5326    }
5327
5328    function selectSuggestion(value) {
5329        input.value = value;
5330        suggestionBox.innerHTML = '';
5331        cancelPopup();
5332    }
5333
5334    // Close the suggestion box when clicking outside
5335    document.addEventListener('click', function(e) {
5336        if (!suggestionBox.contains(e.target) && e.target.id !== 'myInput') {
5337            suggestionBox.innerHTML = '';
5338            cancelPopup();
5339        }
5340    });
5341
5342    document.addEventListener('keydown', (e) => {
5343        const key = e.key;
5344        if(key === 'Escape' && dataList.classList.contains('active')) {
5345            cancelPopup();
5346        }
5347    });
5348
5349    function cancelPopup() {
5350        suggestionBox.classList.remove('active');
5351        label.classList.remove('active');
5352    }
5353
5354
5355};
5356EA.Methods.dateAssist = function($this) {
5357    const inputField = $this[0].querySelector('.age-input');
5358	const minYear = 18;
5359	const maxChars = 8;
5360	let initialAmount = 0;
5361    let amount = 0;
5362    inputField.addEventListener('keydown', (event) => {
5363		// $this[0].classList.remove('input-error-age');
5364		initialAmount = inputField.value;
5365		setTimeout(() => {
5366			amount = inputField.value;
5367			
5368			let cursorPos = event.srcElement.selectionStart;
5369			const reg = /^[0-9]*$/;
5370			
5371			let isOtherValidKey = false;
5372			
5373			//Allows the user to manouver freely in the input field
5374			if(!(event.key != 'ArrowLeft' && event.key != 'ArrowRight' && event.key != 'ArrowUp' && event.key != 'ArrowDown')) {
5375				isOtherValidKey = true;
5376			}
5377			else {
5378				if(event.key != 'Backspace') {
5379					//Input isn't a number, hence not valid
5380					if(!reg.test(event.key)) {
5381						event.preventDefault();
5382						inputField.value = initialAmount;
5383						return;
5384					}
5385				}
5386				else {
5387					//Be able to delete
5388					let amountCopy = amount.split('');
5389
5390					if(amountCopy[5] != '/') {
5391						amountCopy.splice(4, 1);
5392					}
5393
5394					if(amountCopy[2] != '/') {
5395						amountCopy.splice(1, 1);
5396					}
5397
5398					amountCopy = amountCopy.join('');
5399					amount = amountCopy;
5400				}
5401			}
5402
5403			//Isn't just navigating
5404			if(!isOtherValidKey) {
5405				dateFormat();
5406				let amountCopy = amount.split('');
5407				if(amountCopy.length == 2 || amountCopy.length == 5) {
5408					cursorPos+= 1;
5409				}
5410				event.srcElement.selectionStart = cursorPos;
5411				event.srcElement.selectionEnd = cursorPos;
5412			}
5413		});
5414    });
5415
5416	function dateFormat() {
5417		let amountChars = amount.split('/').join('').split('');
5418		if(amountChars.length > maxChars) {
5419			amountChars.pop();
5420		}
5421		let amountCharsCopy = amountChars;
5422
5423		//Check age
5424		// if(amountChars.length == maxChars) {
5425		// 	let age = getAge(amountChars);
5426		// 	if(age < minYear) {
5427		// 		inputField.classList.remove('age-valid');
5428		// 		$this[0].classList.add('input-error-age');
5429		// 	}
5430		// 	else {
5431		// 		inputField.classList.add('age-valid');
5432		// 	}
5433		// }
5434
5435		if(amountChars.length > 3) {
5436			amountCharsCopy.splice(4, 0, '/');
5437			amountCharsCopy.splice(2, 0, '/');
5438		}
5439		else if(amountChars.length > 1) {
5440			amountCharsCopy.splice(2, 0, '/');
5441		}
5442
5443		inputField.value = amountCharsCopy.join('');
5444	}
5445
5446	function getAge(amountChars) {
5447		amountChars = amountChars.join('').toString();
5448		let day = amountChars.substring('0', '2');
5449		let month = amountChars.substring('3', '4');
5450		let year = amountChars.substring('4', '8');
5451
5452		let dateString = year+'/'+month+'/'+day;
5453
5454		var today = new Date();
5455		var birthDate = new Date(dateString);
5456		var age = today.getFullYear() - birthDate.getFullYear();
5457		var m = today.getMonth() - birthDate.getMonth();
5458		if (m < 0 || (m === 0 && today.getDate() < birthDate.getDate())) {
5459			age--;
5460		}
5461		return age;
5462	}
5463}
5464EA.Methods.devicesTab = function($this){ 
5465    const item = $this.find('.tab-toggle');
5466	item.on('click', function(e) {
5467        e.preventDefault();
5468        var thisIndex = $(this).index();
5469        $(this).addClass('active').siblings().removeClass('active');
5470        $this.find('.tab-toggle-content').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
5471        $this.find('.tv-offer-subtext-wrapper').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
5472        $this.find('.tv-offer-right').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
5473    }); 
5474};
5475EA.Methods.dropkick = function($this){
5476
5477    $this.find('.custom-select').dropkick();
5478    $this.find('.dk-select').on('click', (e) => {
5479        e.stopPropagation();
5480        $this.toggleClass('active').find('.dk-select-options').slideToggle()
5481    });
5482
5483    setTimeout(() => {
5484        $($this).find('.dk-option').on('click', () => {
5485            $this.addClass('valid');
5486            $($this).find('.dk-select').addClass('dk-valid-selection');
5487        });
5488    });
5489    
5490    $('body').on('click', () => {
5491        $this.find('.dk-select-options').slideUp();
5492    });
5493};
5494
5495EA.Methods.dropkickCharges = function($this){
5496    const chargesTablesWrapper = $('.charges-tables-outer-wrapper');
5497
5498    setTimeout(() => {
5499        const placeholderText = $this.find('.dk-option')[0].innerHTML;
5500        const initialValue = $this.find('.dk-selected')[0].innerHTML;
5501
5502        if(initialValue !== placeholderText) {
5503            chargesTablesWrapper.addClass('active');
5504        }
5505    });
5506
5507    const dropkick = $this.find('.custom-select').dropkick();
5508    dropkick.change(function() {
5509        if(!chargesTablesWrapper.hasClass('active')) {
5510            chargesTablesWrapper.addClass('active');
5511        }
5512    });
5513
5514
5515    $this.find('.dk-select').on('click', (e) => {
5516        e.stopPropagation();
5517        $this.toggleClass('active').find('.dk-select-options').slideToggle()
5518    });
5519
5520    setTimeout(() => {
5521        $($this).find('.dk-option').on('click', () => {
5522            $this.addClass('valid');
5523            $($this).find('.dk-select').addClass('dk-valid-selection');
5524        });
5525    });
5526    
5527    $('body').on('click', () => {
5528        $this.find('.dk-select-options').slideUp();
5529    });
5530};
5531
5532EA.Methods.enableOverflow = function($this) {
5533    $('#app').css('overflow', 'visible');
5534};
5535EA.Methods.equalHeight = function($this) {
5536    const items = $this[0].querySelectorAll('.equal-height');
5537    let biggest = 0;
5538    const turnOff = $this[0].getAttribute('data-turnoff');
5539
5540    const multiEvent = (element, eventNames, listener) => {
5541        let events = eventNames.split(' ');
5542        for (let i = 0, iLen = events.length; i < iLen; i++) {
5543            element.addEventListener(events[i], listener, false);
5544        }
5545    }
5546
5547    const checkHeight =  () => {
5548        biggest = Math.max( ...[...items].map( item => item.offsetHeight));
5549        if(turnOff) {
5550            if(!window.matchMedia(`(max-width: ${turnOff}px)`).matches) {
5551                Array.from(items, item => item.style.minHeight = `${biggest}px`);
5552            }
5553        }
5554        else {
5555            Array.from(items, item => item.style.minHeight = `${biggest}px`);
5556        }
5557    }
5558
5559    multiEvent(window, 'load resize', () => {
5560        Array.from(items, item => item.style.minHeight = 'unset');
5561        checkHeight();
5562    });
5563
5564
5565    
5566
5567};
5568
5569EA.Methods.expandContent = function($this){
5570    const item = $this.find('.expand-btn');
5571    const content = $this.find('.expand-content');
5572
5573	item.on('click', function (e) {
5574        e.stopPropagation();
5575        $(item).toggleClass('active');
5576        $(content).stop().slideToggle();
5577    });
5578
5579    $('body').on('click', function () {
5580        $(item).removeClass('active');
5581        $(content).stop().slideUp();
5582    });
5583};
5584EA.Methods.extraContentToggle = function($this){
5585    const chargesSections = document.querySelectorAll('.charges');
5586    const availableAddOnsSection = document.querySelector('.available-add-ons-container');
5587    const searchInfoText = document.querySelector('.search-info-text');
5588
5589    contentToggler($this[0], chargesSections, availableAddOnsSection, searchInfoText);
5590
5591    $this.on('input', function (e) {
5592        let activeCountryGroup = document.querySelector('.country-group.active');
5593
5594        if(activeCountryGroup && $this[0].value != activeCountryGroup.children[0].innerText) {
5595            activeCountryGroup.classList.remove('active');
5596        }
5597
5598        contentToggler($this[0], chargesSections, availableAddOnsSection, searchInfoText);
5599    });
5600};
5601
5602function contentToggler(input, chargesSections, availableAddOnsSection, searchInfoText) {
5603    if(input.value != '') {
5604        if(chargesSections.length > 0) {
5605            chargesSections.forEach((section) => {
5606                section.classList.add('active');
5607            });
5608        }
5609
5610        if(availableAddOnsSection) {
5611            availableAddOnsSection.classList.add('active');
5612        }
5613
5614        if(searchInfoText) {
5615            searchInfoText.classList.add('active');
5616        }
5617    } else {
5618        if(chargesSections.length > 0) {
5619            chargesSections.forEach((section) => {
5620                section.classList.remove('active');
5621            });
5622        }
5623
5624        if(availableAddOnsSection) {
5625            availableAddOnsSection.classList.remove('active');
5626        }
5627
5628        if(searchInfoText) {
5629            searchInfoText.classList.remove('active');
5630        }
5631    }
5632
5633    const resizeEvent = new Event('resize');
5634    window.dispatchEvent(resizeEvent);
5635}
5636EA.Methods.faqList = function($this){
5637    var item = $this.find('.quick-step-link');
5638	item.on('click', function (e) {
5639        e.preventDefault();
5640        var thisIndex = $(this).parent('.quick-help-step-item').index();
5641        $(this).parent('.quick-help-step-item').addClass('active').siblings('.quick-help-step-item').removeClass('active');
5642        $('.faq-inner-list').eq(thisIndex).addClass('active').siblings('.faq-inner-list').removeClass('active');
5643    });
5644};
5645EA.Methods.headerScroll = function($this) {
5646    $(window).on('scroll load resize', function() {
5647        const headerInner = $this.find('.header-inner');
5648        const headerInnerHeight = headerInner.outerHeight();
5649        const countdown = $this.find('.countdown-banner');
5650        const countdownHeight = countdown.outerHeight();
5651        const main = $(document).find('main');
5652        const mobileScrollMenu = $this.find('.mobile-scroll-menu-wrapper');
5653        const headerDesktopHeight = countdown.outerHeight() + $this.outerHeight();
5654        const headerMobileHeight = countdown.outerHeight() + $this.outerHeight() + mobileScrollMenu.outerHeight();
5655        
5656        if(window.scrollY > 10) {
5657            $this.addClass('active');
5658            $this.css('transform', 'translateY(-' + headerInnerHeight + 'px)');
5659
5660            if ($this.hasClass('has-counter')) {
5661                var transformValue = countdownHeight - headerInnerHeight;
5662                $this.css('transform', 'translateY(' + transformValue + 'px)');
5663                countdown.css('transform', 'translateY(-' + transformValue + 'px)');
5664            }
5665        } else {
5666            $this.removeClass('active');
5667            $this.css('transform', '');
5668
5669            if ($this.hasClass('has-counter')) {
5670                $this.css('transform', 'translateY(' + countdownHeight + 'px)');
5671                countdown.css('transform', 'translateY(-' + countdownHeight + 'px)');
5672                if(window.innerWidth < 1200) {
5673                    main.css('padding-top', headerMobileHeight + 'px');
5674                } else {
5675                    main.css('padding-top', headerDesktopHeight + 'px');
5676                }
5677            }
5678        }
5679    });
5680};
5681EA.Methods.hiddenCountriesDropdown = function($this) {
5682    // const dropdownWrapper = $this[0].querySelector('.add-on-dropdown-wrapper');
5683    // const showMore = $this[0].querySelector('.show-more-link');
5684    // const originalShowMoreText = showMore.innerHTML;
5685
5686    // showMore.addEventListener('click', () => {
5687    //     if(dropdownWrapper.classList.contains('active')) {
5688    //         showMore.innerText = originalShowMoreText;
5689    //         dropdownWrapper.classList.remove('active');
5690    //     } else {
5691    //         showMore.innerText = 'show less';
5692    //         dropdownWrapper.classList.add('active');
5693    //     }
5694    // });
5695
5696    const showMore = $this[0].querySelectorAll('.show-more-link');
5697    const originalShowMoreText = showMore[0].innerHTML;
5698    const zones = ['zone-1', 'zone-2', 'zone-3'];
5699
5700    for (let i = 0; i < showMore.length; i++) {        
5701        showMore[i].addEventListener('click', () => {
5702            if(zones.some(zone => showMore[i].classList.contains(zone))) {
5703                let currentZone = showMore[i].classList[1];
5704                for (let j = 0; j < showMore.length; j++) {
5705                    if(showMore[j].classList.contains(currentZone)) {
5706                        if(showMore[j].previousElementSibling.classList.contains('active')) {
5707                            showMore[j].innerText = originalShowMoreText;
5708                            showMore[j].previousElementSibling.classList.remove('active');
5709                        } else {
5710                            showMore[j].innerText = 'show less';
5711                            showMore[j].previousElementSibling.classList.add('active');
5712                        }
5713                    }
5714                }
5715            } else {
5716                for (let j = 0; j < showMore.length; j++) {
5717                    if(showMore[j].previousElementSibling.classList.contains('active')) {
5718                        showMore[j].innerText = originalShowMoreText;
5719                        showMore[j].previousElementSibling.classList.remove('active');
5720                    } else {
5721                        showMore[j].innerText = 'show less';
5722                        showMore[j].previousElementSibling.classList.add('active');
5723                    }
5724                }
5725            }
5726        });
5727    }
5728}
5729EA.Methods.iframeHeight = function($this) {
5730    window.addEventListener('message', (event) => {
5731        if (event.origin !== 'IFRAME URL')
5732            if(event.data.height) {
5733                $this[0].style.height = event.data.height + 'px';
5734            }
5735            return;
5736        }, false);
5737};
5738
5739EA.Methods.instructionsSlider = function($this) {
5740    const imageSwiperElement = $this.find('.swiper-image')[0]; 
5741    const textSwiperElement = $this.find('.swiper-text')[0];
5742
5743    const paginationElement = textSwiperElement.querySelector('.swiper-pagination');
5744
5745    const imageSwiper = new Swiper(imageSwiperElement, {
5746        allowTouchMove: false,
5747    });
5748
5749    const textSwiper = new Swiper(textSwiperElement, {
5750        spaceBetween: 30,
5751        slidesPerView: 1,
5752        pagination: {
5753            el: paginationElement,
5754            clickable: true,
5755        },
5756        controller: {
5757            control: imageSwiper,
5758        },
5759    });
5760}
5761EA.Methods.insuranceModalTabs = function($this){
5762    const tabs = $this[0].querySelectorAll('.tab-toggle');
5763    const contents = $this[0].querySelectorAll('.tab-target');
5764
5765    for (let i = 0; i < tabs.length; i++) {
5766        tabs[i].addEventListener('click', (e) => {
5767            e.preventDefault();
5768            e.currentTarget.scrollIntoView({
5769                behavior: "smooth",
5770                inline: "center", 
5771                block: "nearest"
5772            });
5773            for (let j = 0; j < tabs.length; j++) {
5774                tabs[j].classList.remove('active');
5775                contents[j].classList.remove('active');
5776            }
5777
5778            tabs[i].classList.add('active');
5779            contents[i].classList.add('active');
5780        });
5781    }
5782};
5783EA.Methods.internetInfoTabs = function($this){
5784    var btn = $this.find('.info-selector-btn');
5785    var content = $('.internet-info-text');
5786
5787    $('.info-selector-btn:first-child').addClass('active');
5788    $('.internet-info-text:first-child').addClass('active');
5789
5790    btn.click(function(e) {
5791        e.preventDefault();
5792        var btnIndex = $(this).index();
5793        $(this).addClass('active').siblings().removeClass('active');
5794        content.eq(btnIndex).addClass('active').siblings().removeClass('active');
5795    });
5796
5797};
5798EA.Methods.keepDevicesBlockHeights = function($this) {
5799    //Add to package column class "keep-height-column"
5800    //And add to desire blocks in every colum class ('keep-height')
5801    //Thats literally it
5802    const heightColumn = $this.find('.keep-height-column');
5803    const heightColumnContent = $this.find('.package-content');
5804    const items = $this[0].querySelectorAll('.equal-height');
5805    let biggest = 0;
5806    const turnOff = $this[0].getAttribute('data-turnoff');
5807    
5808    let keepHeightBlocks = [];
5809    let tempHeight = 0;
5810    let maxHeights = [];
5811    let columnMinHeight = 0;
5812
5813    const multiEvent = (element, eventNames, listener) => {
5814        let events = eventNames.split(' ');
5815        for (let i = 0, iLen = events.length; i < iLen; i++) {
5816            element.addEventListener(events[i], listener, false);
5817        }
5818    }
5819
5820    const checkHeight =  () => {
5821        biggest = Math.max( ...[...items].map( item => item.offsetHeight));
5822        if(turnOff) {
5823            if(!window.matchMedia(`(max-width: ${turnOff}px)`).matches) {
5824                Array.from(items, item => item.style.minHeight = `${biggest}px`);
5825            }
5826        }
5827        else {
5828            Array.from(items, item => item.style.minHeight = `${biggest}px`);
5829        }
5830    }
5831
5832    multiEvent(window, 'load resize', () => {
5833        Array.from(items, item => item.style.minHeight = 'unset');
5834        checkHeight();
5835        UpdateHeights();
5836    });
5837
5838    let tempHeightBlocksColumn = [];
5839    //Iterate through every column and find all blocks
5840    heightColumn.each((indexColumn, columnEl) => {
5841        tempHeightBlocksColumn.push($(columnEl).find('.keep-height'));
5842
5843        //No elements registered yet, add home many blocks are in a column
5844        if(maxHeights.length == 0) {
5845            $(tempHeightBlocksColumn).each((indexBlocks, blockEls) => {
5846                $(blockEls).each((indexBlock, blockEl) => {
5847                    maxHeights.push($(blockEl).outerHeight());
5848                });
5849            });
5850        }
5851
5852        keepHeightBlocks.push(tempHeightBlocksColumn);
5853        tempHeightBlocksColumn = [];
5854    });
5855
5856    function UpdateHeights() {
5857        //Remove column min-heights
5858        columnMinHeight = 0;
5859        $(heightColumnContent).each((columnIndex, columnEl) => {
5860            $(columnEl).css('min-height', '');
5861        });
5862
5863        //Remove block min-heights
5864        $(keepHeightBlocks).each((indexColumn, columnEl) => {
5865            $(columnEl).each((indexBlock, blockEls) => {
5866                $(blockEls).css('min-height', '');
5867            });
5868        });
5869        for(let i=0; i<maxHeights.length; i++) {
5870            maxHeights[i] = 0;
5871        }
5872
5873        //Calculate heights
5874        $(keepHeightBlocks).each((indexColumn, columnEl) => {
5875            $(columnEl).each((indexBlocks, blockEls) => {
5876                $(blockEls).each((indexBlock, blockEl) => {
5877                    tempHeight = $(blockEl).outerHeight();
5878                    if(tempHeight > maxHeights[indexBlock]) {
5879                        maxHeights[indexBlock] = tempHeight;
5880                    }
5881                    tempHeight = 0;
5882                });
5883            });
5884        });
5885
5886        //Apply height
5887        $(keepHeightBlocks).each((indexColumn, columnEl) => {
5888            $(columnEl).each((indexBlocks, blockEls) => {
5889                $(blockEls).each((indexBlock, blockEl) => {
5890                    $(blockEl).css('min-height', `${maxHeights[indexBlock]}px`);
5891                });
5892            });
5893        });
5894
5895        //Find packages max height
5896        $(heightColumnContent).each((columnIndex, columnEl) => {
5897            let columnHeight = $(columnEl).outerHeight();
5898            if(columnHeight > columnMinHeight) {
5899                columnMinHeight = columnHeight;
5900            }
5901        });
5902
5903        //Apply packages height
5904        $(heightColumnContent).each((columnIndex, columnEl) => {
5905            $(columnEl).css('min-height', `${columnMinHeight}px`);
5906        });
5907    }
5908};
5909
5910EA.Methods.keepPackageBlockHeights = function($this) {
5911    //Add to package column class "keep-height-column"
5912    //And add to desire blocks in every colum class ('keep-height')
5913    //Thats literally it
5914    const heightColumn = $this.find('.keep-height-column');
5915    const heightColumnContent = $this.find('.package-content');
5916    const mql = window.matchMedia("(max-width: 800px)");
5917    const items = $this[0].querySelectorAll('.equal-height');
5918    let biggest = 0;
5919    const turnOff = $this[0].getAttribute('data-turnoff');
5920    
5921    let keepHeightBlocks = [];
5922    let tempHeight = 0;
5923    let maxHeights = [];
5924    let columnMinHeight = 0;
5925
5926    const multiEvent = (element, eventNames, listener) => {
5927        let events = eventNames.split(' ');
5928        for (let i = 0, iLen = events.length; i < iLen; i++) {
5929            element.addEventListener(events[i], listener, false);
5930        }
5931    }
5932
5933    const checkHeight =  () => {
5934        biggest = Math.max( ...[...items].map( item => item.offsetHeight));
5935        if(turnOff) {
5936            if(!window.matchMedia(`(max-width: ${turnOff}px)`).matches) {
5937                Array.from(items, item => item.style.minHeight = `${biggest}px`);
5938            }
5939        }
5940        else {
5941            Array.from(items, item => item.style.minHeight = `${biggest}px`);
5942        }
5943        if(mql.matches) {
5944            Array.from(items, item => item.style.minHeight = `unset`);
5945        }
5946    }
5947
5948    multiEvent(window, 'load resize', () => {
5949        Array.from(items, item => item.style.minHeight = 'unset');
5950        checkHeight();
5951        UpdateHeights();
5952    });
5953
5954    let tempHeightBlocksColumn = [];
5955    //Iterate through every column and find all blocks
5956    heightColumn.each((indexColumn, columnEl) => {
5957        tempHeightBlocksColumn.push($(columnEl).find('.keep-height'));
5958
5959        //No elements registered yet, add home many blocks are in a column
5960        if(maxHeights.length == 0) {
5961            $(tempHeightBlocksColumn).each((indexBlocks, blockEls) => {
5962                $(blockEls).each((indexBlock, blockEl) => {
5963                    maxHeights.push($(blockEl).outerHeight());
5964                });
5965            });
5966        }
5967
5968        keepHeightBlocks.push(tempHeightBlocksColumn);
5969        tempHeightBlocksColumn = [];
5970    });
5971
5972    function UpdateHeights() {
5973        //Remove column min-heights
5974        columnMinHeight = 0;
5975        $(heightColumnContent).each((columnIndex, columnEl) => {
5976            $(columnEl).css('min-height', '');
5977        });
5978
5979        //Remove block min-heights
5980        $(keepHeightBlocks).each((indexColumn, columnEl) => {
5981            $(columnEl).each((indexBlock, blockEls) => {
5982                $(blockEls).css('min-height', '');
5983            });
5984        });
5985        for(let i=0; i<maxHeights.length; i++) {
5986            maxHeights[i] = 0;
5987        }
5988
5989        if(mql.matches) {
5990            return;
5991        }
5992
5993        //Calculate heights
5994        $(keepHeightBlocks).each((indexColumn, columnEl) => {
5995            $(columnEl).each((indexBlocks, blockEls) => {
5996                $(blockEls).each((indexBlock, blockEl) => {
5997                    tempHeight = $(blockEl).outerHeight();
5998                    if(tempHeight > maxHeights[indexBlock]) {
5999                        maxHeights[indexBlock] = tempHeight;
6000                    }
6001                    tempHeight = 0;
6002                });
6003            });
6004        });
6005
6006        //Apply height
6007        $(keepHeightBlocks).each((indexColumn, columnEl) => {
6008            $(columnEl).each((indexBlocks, blockEls) => {
6009                $(blockEls).each((indexBlock, blockEl) => {
6010                    $(blockEl).css('min-height', `${maxHeights[indexBlock]}px`);
6011                });
6012            });
6013        });
6014
6015        //Find packages max height
6016        $(heightColumnContent).each((columnIndex, columnEl) => {
6017            let columnHeight = $(columnEl).outerHeight();
6018            if(columnHeight > columnMinHeight) {
6019                columnMinHeight = columnHeight;
6020            }
6021        });
6022
6023        //Apply packages height
6024        $(heightColumnContent).each((columnIndex, columnEl) => {
6025            $(columnEl).css('min-height', `${columnMinHeight}px`);
6026        });
6027    }
6028};
6029
6030EA.Methods.listScroll = function($this){
6031    let offset = 110;
6032    let hasCounter = document.querySelector('header').classList.contains('has-counter');
6033    if (hasCounter) offset += 78;
6034
6035    ScrollTrigger.matchMedia({
6036        '(min-width: 1000px)': () => {
6037            
6038            const tl = gsap.timeline({
6039                scrollTrigger: {
6040                    trigger: $this,
6041                    pin: true,
6042                    start: `top ${offset}px`,
6043                    end: () => $('.scroll-col').innerHeight(),
6044                    scrub: 1,
6045                    invalidateOnRefresh: true
6046                }
6047            });
6048            tl
6049                .to($this, {
6050                    ease: 'none' 
6051                });
6052        }
6053    });
6054
6055    /* responsive update */
6056    window.addEventListener('resize', () => {
6057        ScrollTrigger.refresh();
6058    });
6059};
6060
6061EA.Methods.mainSearch = function($this){
6062    const btn = $this.find('.search-button');
6063
6064    btn.on('click', function (e) {
6065        e.stopPropagation();
6066        $('.search-inner').toggleClass('active');
6067        $('.main-nav-list').toggleClass('opacity');
6068        $(this).toggleClass('active');
6069        setTimeout(() => {
6070            $('.search-input').focus().val('');
6071        }, 550);
6072    });
6073
6074    $this.on('click', function (e) {
6075        e.stopPropagation();
6076    });
6077    
6078    $('body').on('click', function () {
6079        $('.search-inner').removeClass('active');
6080        $('.main-nav-list').removeClass('opacity');
6081        btn.removeClass('active');
6082    });
6083};
6084EA.Methods.mobileMenu = function($this) {
6085    const tl = gsap.timeline();
6086    const anim = document.querySelectorAll('.mobile-anim');
6087    const nav = document.querySelector('.mobile-menu-wrap');
6088    const header = document.querySelector('header');
6089    const burger = $this[0];
6090    const burgerWrap = $this[0].querySelector('.hamburger-wrapper');
6091    const mq = window.matchMedia( "(max-width: 1200px)" );
6092
6093    tl.reverse();
6094    gsap.set(anim, {
6095        x: 40,
6096        alpha: 0
6097    });
6098
6099    tl
6100        .fromTo(nav, {
6101            x: '100%'
6102        },
6103        {
6104            x: '0%',
6105            duration: 0.6,
6106            ease: 'power2.inOut'
6107        })
6108        .to(anim, {
6109            x: 0,
6110            alpha: 1,
6111            stagger: 0.1,
6112            duration: 0.3,
6113            ease: 'power2.inOut'
6114        }, '-=0.17');
6115
6116    burger.addEventListener('click', () => {
6117        burgerWrap.classList.toggle('active');
6118        header.classList.toggle('active-menu');
6119        document.body.classList.toggle('overflow');
6120        tl.reversed() ? tl.play() : tl.reverse();
6121    });
6122
6123    window.addEventListener('resize', () => {
6124        if(!mq.matches && burgerWrap.classList.contains('active')) {
6125            burgerWrap.classList.remove('active');
6126            header.classList.remove('active-menu');
6127            document.body.classList.remove('overflow');
6128            tl.reverse();
6129        }
6130    });
6131}
6132
6133
6134EA.Methods.mobileMenuDropdowns = function($this){
6135    const item = $this.find('.mobile-menu-main-nav-link');
6136    const burger = $(document).find('.hamburger-outer');
6137
6138    item.on('click', function (e) {
6139        e.preventDefault();
6140        $(this).siblings('.mobile-main-nav-dropdown-wrapper').slideToggle();
6141        $(this).parent('.mobile-menu-main-nav-item').siblings().find('.mobile-main-nav-dropdown-wrapper').slideUp();
6142    });
6143
6144    burger.on('click', function() {
6145        item.each(function() {
6146            $(this).siblings('.mobile-main-nav-dropdown-wrapper').slideUp();
6147        })
6148    })
6149};
6150
6151EA.Methods.multilineCounter = function($this) {
6152    const decrBtn = $this.find('.btn-decr');
6153    const incrBtn = $this.find('.btn-incr');
6154    const counterTxt = $this.find('.counter-text');
6155
6156    const min = $this.data('min');
6157    const max = $this.data('max');
6158
6159    let counter = min;
6160
6161    updateContent();
6162
6163    decrBtn.on('click', (e) => {
6164        e.preventDefault();
6165        counter--;
6166        if(counter <= min) {
6167            counter = min;
6168        }
6169        updateContent();
6170    });
6171
6172    incrBtn.on('click', (e) => {
6173        e.preventDefault();
6174        counter++;
6175        if(counter >= max) {
6176            counter = max;
6177        }
6178        updateContent();
6179    });
6180
6181    function updateContent() {
6182        counterTxt.html(counter);
6183
6184        if(counter <= min) {
6185            decrBtn.addClass('disabled');
6186        }
6187        else {
6188            decrBtn.removeClass('disabled');
6189        }
6190
6191        if(counter >= max) {
6192            incrBtn.addClass('disabled');
6193        }
6194        else {
6195            incrBtn.removeClass('disabled');
6196        }
6197    }
6198};
6199
6200
6201EA.Methods.onlyOnSkyShowtimeAltSlider = function($this) {
6202    const slider = $this[0].querySelector('.swiper-container');
6203    const pagination = $this[0].querySelector('.swiper-pagination');
6204
6205    const swiper = new Swiper(slider, {
6206        speed: 600,
6207        slidesPerView: 'auto',
6208        spaceBetween: 20,
6209        autoplay: {
6210            delay: 5000,
6211            disableOnInteraction: false,
6212        },
6213        pagination: {
6214            el: pagination,
6215            clickable: true,
6216        },
6217        on: {
6218            init: function () {
6219                slider.classList.add('loaded');
6220            }
6221        }
6222    });
6223}
6224
6225EA.Methods.openDropdownList = function($this){
6226    const input = $this[0].querySelector('input');
6227    const dropdownWrapper = $this[0].querySelector('.dropdown-list-wrapper');
6228    const dropdownItems = dropdownWrapper.querySelectorAll('.dropdown-list-item');
6229    const countryGroups = $this[0].querySelectorAll('.country-group');
6230
6231    input.addEventListener('keyup', () => {
6232        let filter = input.value.toUpperCase();
6233        let elementCounter = 0;
6234        for (i = 0; i < dropdownItems.length; i++) {
6235            const itemLabel = dropdownItems[i].querySelector('.dropdown-list-item-label');
6236            let txtValue = itemLabel.textContent || itemLabel.innerText;
6237            if (txtValue.toUpperCase().indexOf(filter) > -1) {
6238                dropdownItems[i].style.display = "";
6239            } else {
6240                dropdownItems[i].style.display = "none";
6241                elementCounter++;
6242            }
6243
6244            elementCounter === dropdownItems.length ? 
6245            dropdownWrapper.classList.remove('active') :
6246            dropdownWrapper.classList.add('active');
6247        }
6248    });
6249
6250    for (let i = 0; i < dropdownItems.length; i++) {
6251        dropdownItems[i].addEventListener('click', () => {
6252            const dropdownLabel = dropdownItems[i].querySelector('.dropdown-list-item-label');
6253            input.value = dropdownLabel.innerText;
6254            $(input).trigger('input');
6255        })
6256    }
6257
6258    for (let i = 0; i < countryGroups.length; i++) {
6259        countryGroups[i].addEventListener('click', (e) => {
6260            e.preventDefault();
6261            const countryGroupLabel = countryGroups[i].querySelector('button');
6262            const previousActiveButton = $this[0].querySelector('.country-group.active');
6263            previousActiveButton && previousActiveButton.classList.remove('active');
6264            countryGroupLabel.parentNode.classList.add('active');
6265            input.value = countryGroupLabel.innerText;
6266            $(input).trigger('input');
6267        })
6268    }
6269        
6270    document.addEventListener('click', () => {
6271        dropdownWrapper.classList.remove('active');
6272    });
6273}; 
6274EA.Methods.openModal = function($this) {
6275    $this.on('click', (e) => {
6276        $(document.body).css('overflow', 'hidden');
6277        e.preventDefault();
6278        $(document).find(`.${$this.data('modal')}`).addClass('active');
6279    });
6280};
6281
6282EA.Methods.packagesTabToggle = function($this) {
6283    let item = $this.find('.tab-toggle');
6284    let mobileItem = $this.find('.tab-toggle-mobile');
6285
6286    item.on('click', function (e) {
6287        e.preventDefault();
6288        let thisIndex = $(this).index();
6289        
6290        $this.find('.tab-toggle-content').find($('.tab-target')).css('display', '');
6291        $(this).addClass('active').siblings().removeClass('active');
6292        $this.find('.tab-toggle-content').find($('.tab-target')).removeClass('active');
6293        $this.find('.tab-toggle-content').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
6294        mobileItem.removeClass('active');
6295    });
6296
6297    mobileItem.on('click', function (e) {
6298        e.preventDefault();
6299        if (!$(this).hasClass('active')) {
6300            let activeItemNumber = $(this).attr('data-number');
6301            
6302            item.removeClass('active');
6303            mobileItem.removeClass('active');
6304            $(this).addClass('active');
6305            $this.find('.tab-target').slideUp(500);
6306            $(this).closest('.program-list-tab-outher-wrapper').find($('.tab-target')).slideDown(500).addClass('active');
6307            $this.find(`.tab-toggle[data-number='${activeItemNumber}']`).addClass('active');
6308            $('html, body').animate({ 
6309                scrollTop: $this.offset().top - 60
6310            }, 200);
6311        };
6312    });
6313};
6314EA.Methods.packageToggle = function($this){
6315    const item = $this.find('.toggle-item');
6316    const content = $this.find('.toggle-hidden-content');
6317
6318	item.on('click', function (e) {
6319        e.stopPropagation();
6320        $($this).toggleClass('active');
6321        item.toggleClass('active');
6322        content.stop().slideToggle();
6323    });
6324    
6325    if(!$this.data('no-offclick')) {
6326        $('body').on('click', function () {
6327            item.removeClass('active');
6328            $($this).removeClass('active');
6329            content.slideUp();
6330        });
6331    }
6332};
6333EA.Methods.pinnedVideo = function($this) {
6334    gsap.registerPlugin(ScrollTrigger);
6335
6336    const pinSection = $this[0];
6337    const videoWrapper = $this.find('.video-wrapper-inner')[0];
6338
6339    gsap.set(videoWrapper, {
6340        width: "110%",
6341    });
6342
6343    ScrollTrigger.matchMedia({
6344        // desktop
6345        "(min-width: 768px)": function() {
6346            gsap.to(videoWrapper, {
6347                width: "60%",
6348                ease: "none",
6349                scrollTrigger: {
6350                    trigger: pinSection,
6351                    start: "top top",
6352                    end: "+=125%",
6353                    scrub: true,
6354                    pin: true,
6355                },
6356                onUpdate: function() {
6357                    let st = this;
6358
6359                    if (st.progress() > 0.1) {
6360                        videoWrapper.classList.add("mask-on");
6361                    } else {
6362                        videoWrapper.classList.remove("mask-on");
6363                    }
6364                }
6365            });
6366        },
6367        // mobile
6368        "(max-width: 767px) and (min-width: 569px)": function() {
6369            gsap.to(videoWrapper, {
6370                width: "40%",
6371                ease: "none",
6372                scrollTrigger: {
6373                    trigger: pinSection,
6374                    start: "top top",
6375                    end: "+=125%",
6376                    scrub: true,
6377                    pin: true,
6378                },
6379                onUpdate: function() {
6380                    let st = this;
6381
6382                    if (st.progress() > 0.1) {
6383                        videoWrapper.classList.add("mask-on");
6384                    } else {
6385                        videoWrapper.classList.remove("mask-on");
6386                    }
6387                }
6388            });
6389        },
6390        // mobile
6391        "(max-width: 568px)": function() {
6392            gsap.to(videoWrapper, {
6393                width: "60%",
6394                ease: "none",
6395                scrollTrigger: {
6396                    trigger: pinSection,
6397                    start: "top top",
6398                    end: "+=125%",
6399                    scrub: true,
6400                    pin: true,
6401                },
6402                onUpdate: function() {
6403                    let st = this;
6404
6405                    if (st.progress() > 0.1) {
6406                        videoWrapper.classList.add("mask-on");
6407                    } else {
6408                        videoWrapper.classList.remove("mask-on");
6409                    }
6410                }
6411            });
6412        }
6413    });
6414};
6415EA.Methods.popupControl = function($this) {
6416    const body = $('body');
6417    const modal = $this.data('modal');
6418    const btns = $this;
6419	const modalContainer = $('.modal-container');
6420    const closeBtn = modalContainer.find('.close-btn');
6421	const modalOverlay = modalContainer.find('.popup-overlay');
6422    const tl = gsap.timeline({ paused: true });
6423
6424    tl
6425        .to($('.modal-anim'), {
6426            y: '0%',
6427            visibility: 'visible',
6428            stagger: 0.1,
6429            duration: 0.5,
6430            ease: 'power3.inOut'
6431        });
6432
6433	btns.click(function (e) {
6434		e.preventDefault();
6435        tl.play();
6436		$('.' + modal).addClass('active');
6437		modalContainer.addClass('active');
6438		$('.popup-box').not($('.' + modal)).removeClass('active');
6439		body.addClass('overflow');
6440	});
6441
6442    modalOverlay.click(function (e) {
6443        tl.reverse();
6444        $('.' + modal).removeClass('active');
6445        modalContainer.removeClass('active');
6446        body.removeClass('overflow');
6447    });
6448
6449	$(document).on('keydown', function(event) {
6450		const key = event.key;
6451		if (key === "Escape" && body.hasClass('overflow')) {
6452            tl.reverse();
6453			body.removeClass('overflow');
6454            $('.' + modal).removeClass('active');
6455            modalContainer.removeClass('active');
6456		}
6457	});
6458
6459    closeBtn.click(function (e) {
6460        e.preventDefault();
6461        tl.reverse();
6462        $('.' + modal).removeClass('active');
6463        modalContainer.removeClass('active');
6464        body.removeClass('overflow');
6465	})
6466};
6467EA.Methods.rangeSlider = function($this){
6468    const eurStart = $($this).data('start');
6469    const eurEnd = $($this).data('end');
6470
6471    const rate = $($this).data('rate');
6472    const slider = $this.find('.range-slider');
6473    const rangeEur = $this.find('.custom-range-slider-val-eur');
6474    const rangeKn = $this.find('.custom-range-slider-val-kn');
6475    
6476    const moneyFormat = wNumb({
6477        decimals: 2,
6478        thousand: '. ',
6479        mark: ','
6480    });
6481
6482    noUiSlider.create(slider[0], {
6483        start: [eurStart, eurEnd],
6484        connect: true,
6485        range: {
6486            min: eurStart,
6487            max: eurEnd
6488        },
6489        format: moneyFormat
6490    });
6491
6492    slider[0].noUiSlider.on('update', function (values, handle) {
6493        rangeEur[0].innerHTML = values[0];
6494        rangeEur[1].innerHTML = values[1];
6495
6496        let minValue = Math.round(values[0].replace('. ', '').replace(',', '.') * rate * 100) / 100;
6497        minValue = minValue.toString().replace('.', ',');
6498        minValue = minValue.replace(/\B(?=(\d{3})+(?!\d))/g, ". ");
6499
6500        let maxValue = Math.round(values[1].replace('. ', '').replace(',', '.') * rate * 100) / 100;
6501        maxValue = maxValue.toString().replace('.', ',');
6502        maxValue = maxValue.replace(/\B(?=(\d{3})+(?!\d))/g, ". ");
6503
6504        (minValue == 0) && (minValue = "0,00");
6505        (maxValue == 0) && (maxValue = "0,00");
6506
6507        rangeKn[0].innerHTML = minValue;
6508        rangeKn[1].innerHTML = maxValue;
6509    });
6510    /* reset values */
6511    $('.price-range-reset-btn').on('click', (e) => {
6512        e.preventDefault();
6513        slider[0].noUiSlider.set([eurStart, eurEnd]);
6514    });
6515};
6516EA.Methods.renewalStepsSwiper = function($this) {
6517    const swiperEl = $this.find('.swiper-container'); 
6518    const pag = $this.find('.swiper-pagination');
6519
6520    const swiper = new Swiper(swiperEl, {
6521        spaceBetween: 12,
6522        slidesPerView: 'auto',
6523        pagination: {
6524            el: pag,
6525            clickable: true,
6526        },
6527    });
6528
6529    function updateSwiperTouch(swiperInstance) {
6530        const slideWidth = swiperInstance.slides[0].offsetWidth || 1;
6531        const visibleSlides = Math.floor(swiperInstance.width / slideWidth);
6532
6533        if (swiperInstance.slides.length <= visibleSlides) {
6534            swiperInstance.allowTouchMove = false;
6535            pag.addClass('swiper-pagination-disabled');
6536        } else {
6537            swiperInstance.allowTouchMove = true;
6538            pag.removeClass('swiper-pagination-disabled');
6539        }
6540    }
6541    
6542    updateSwiperTouch(swiper)
6543
6544    window.addEventListener('resize', () => updateSwiperTouch(swiper));
6545    swiper.on('update', () => updateSwiperTouch(swiper));
6546
6547}
6548EA.Methods.roamingAccordion = function($this){
6549    const accordionButtons = $this[0].querySelectorAll('.roaming-faq-accordion');
6550    const showMoreButton = $this[0].querySelector('.roaming-faq-show-more');
6551    const showMoreWrapper = $this[0].querySelector('.show-more-accordions-wrapper');
6552
6553    let currentIndex;
6554
6555    for(let i = 0; i < accordionButtons.length; i++) {
6556        accordionButtons[i].addEventListener('click', (e) => {
6557            e.preventDefault();
6558
6559            if(currentIndex >= 0 && currentIndex !== i) {
6560                accordionButtons[currentIndex].classList.remove('active');
6561                accordionButtons[currentIndex].nextElementSibling.classList.remove('active');
6562            }
6563
6564            currentIndex = i;
6565            
6566            if(accordionButtons[i].classList.contains('active')) {
6567                accordionButtons[i].classList.remove('active');
6568                accordionButtons[i].nextElementSibling.classList.remove('active');
6569            } else {
6570                accordionButtons[i].classList.add('active');
6571                accordionButtons[i].nextElementSibling.classList.add('active');
6572            }
6573        });
6574    }
6575
6576    showMoreButton.addEventListener('click', (e) => {
6577        e.preventDefault();
6578        showMoreButton.classList.toggle('active');
6579        showMoreWrapper.classList.toggle('active');
6580    });
6581};
6582EA.Methods.roamingCloseModal = function($this) {
6583    $this.on('click', (e) => {
6584        $(document.body).css('overflow', '');
6585        e.preventDefault();
6586        $this.closest('.modal').removeClass('active')
6587        $(document).find('.roaming-modal-container').removeClass('active')
6588    });
6589};
6590
6591EA.Methods.roamingOpenModal = function($this) {
6592    $this.on('click', (e) => {
6593        $(document.body).css('overflow', 'hidden');
6594        e.preventDefault();
6595        $(document).find('.roaming-modal-container').addClass('active');
6596        $(document).find(`.${$this.data('modal')}`).addClass('active');
6597        $(document).click((e) => {
6598            if ($(e.target).hasClass('roaming-modal-container')) {
6599                $(document).find('.roaming-modal-container').removeClass('active');
6600                $(document).find('.modal').removeClass('active');
6601                $(document.body).css('overflow', '');
6602            }
6603        });
6604    });
6605};
6606
6607EA.Methods.roamingTabSwitcher = function($this){
6608    const tabButtons = $this[0].querySelectorAll('.tab');
6609    const tabContents = $this[0].querySelectorAll('.tab-content');
6610
6611    for(let i = 0; i < tabButtons.length; i++){
6612        tabButtons[i].addEventListener('click', function(e){
6613            e.preventDefault();
6614
6615            $this[0].querySelector('.tab.active').classList.remove('active');
6616            $this[0].querySelector('.tab-content.active').classList.remove('active');
6617
6618            this.classList.add('active');
6619            tabContents[i].classList.add('active');
6620        });
6621    }
6622};
6623
6624EA.Methods.roamingTooltip = function($this) {
6625    $this.on('mouseenter.tooltip', function () {
6626        updateTooltipWidth($this);
6627
6628        $this.off('mouseenter.tooltip');
6629    });
6630
6631    let tooltipTimeoutId;
6632
6633    $(window).on('resize', function () {
6634        clearTimeout(tooltipTimeoutId);
6635        tooltipTimeoutId = setTimeout(function () {
6636            updateTooltipWidth($this);
6637        }, 300);
6638    });
6639};
6640
6641function updateTooltipWidth($this) {
6642    const parentWidth = $this.parent().width();
6643    const tooltip = $this.find('.roaming-tooltiptext');
6644    tooltip.css('width', parentWidth + 14);
6645}
6646EA.Methods.scrollAnim = function($this){
6647    /* Resets the style when scrollTrigger is no longer active */
6648    ScrollTrigger.saveStyles($this);
6649    ScrollTrigger.matchMedia({
6650        '(min-width: 1200px)': function () {
6651            ScrollTrigger.create({
6652                trigger: $this,
6653                start: '0% bottom',
6654                end: 'bottom',
6655                onUpdate: self => scrollFunc(self.progress)
6656            });
6657            function scrollFunc (progress) {
6658                var posY = (progress * 80) * -1;
6659                gsap.to($this, {
6660                    y: posY * 2
6661                });
6662            }
6663        }
6664    });
6665};
6666
6667EA.Methods.scrollDiv = function($this) {
6668    gsap.registerPlugin(ScrollTrigger);
6669    const gallerySlideLeft = $this.find('.left-right');
6670    const gallerySlideRight = $this.find('.right-left');
6671    const section = $this;
6672    
6673    gsap.to(gallerySlideLeft, {
6674        scrollTrigger: {
6675            trigger: section,
6676            start: 'top bottom',
6677            end: 'bottom -300%',
6678            scrub: 1
6679        },
6680        x: '-15%'
6681    });
6682
6683    gsap.to(gallerySlideRight, {
6684        scrollTrigger: {
6685            trigger: section,
6686            start: 'top bottom',
6687            end: 'bottom -300%',
6688            scrub: 1
6689        },
6690        x: '15%'
6691    });
6692};
6693
6694EA.Methods.scrollParalax = function($this) {
6695    const parent = $this[0];
6696    const animElement = parent.querySelectorAll('.anim-parallax');
6697
6698    gsap.config({
6699        nullTargetWarn: false
6700    });
6701
6702    animElement.forEach(element => {
6703        const moveDistance = element.getAttribute('data-parallax');
6704
6705        const tl = gsap.timeline({
6706            scrollTrigger: {
6707                trigger: parent,
6708                start: 'top bottom',
6709                end: '50% 20%',
6710                scrub: 1.2,
6711            }
6712        });
6713
6714        tl.from(element, {
6715            yPercent: moveDistance,
6716            duration: 0.2,
6717            ease: 'power3.inOut',
6718        });
6719    
6720    });
6721
6722}
6723EA.Methods.scrollText = function($this){
6724    gsap.registerPlugin(ScrollTrigger);
6725
6726    var text = $this.find('.scroll-text');
6727    gsap.to(text, {
6728        scrollTrigger: {
6729            trigger: $this,
6730            start: 'top bottom',
6731            end: 'bottom -500%',
6732            scrub: 1
6733        },
6734        x: '-30%'
6735    });
6736};
6737EA.Methods.scrollToElement = function($this){
6738    $this.click( function(e) {
6739        e.preventDefault();
6740        const scrollAtribute = $(this).data('scroll');
6741        $('html, body').animate({
6742            scrollTop: $('.' + scrollAtribute).offset().top - $('#page-header').innerHeight()
6743        }, 500);
6744    });
6745};
6746
6747EA.Methods.selectActive = function($this){
6748    $this.find('.toggle-active').on('click', function (e) {
6749        e.preventDefault();
6750        $(this).toggleClass('active').siblings('.toggle-active').removeClass('active');
6751    });
6752};
6753EA.Methods.selectOptionContentReveal = function($this){
6754    var selectOption = $this.find('li');
6755
6756    selectOption.on('click', function () {
6757        var optionValue = $(this).attr('data-value');
6758        var selectedContent = $('body').find(`div[data-option="${optionValue}"]`);
6759        var activeContent = $('body').find('.option-content.active');
6760
6761        activeContent.removeClass('active').slideUp(500);
6762
6763        setTimeout(function () {
6764            activeContent.addClass('hidden-content');
6765            selectedContent.addClass('active');
6766            selectedContent.slideDown(500);
6767            selectedContent.removeClass('hidden-content');
6768        }, 500);
6769    });
6770};
6771EA.Methods.serviceTableSwiper = function($this){
6772    const swiperPagination = $this[0].querySelector('.swiper-pagination');
6773    
6774    const serviceTableSwiper = new Swiper($this[0], {
6775        observer: true,
6776        slidesPerView: 1,
6777        pagination: {
6778            el: swiperPagination,
6779            clickable: true
6780        }
6781    });
6782
6783    const tabContentParent = $this[0].closest('.tab-content');
6784
6785    const mutationObserver = new MutationObserver(mutationsList => {
6786        for (let mutation of mutationsList) {
6787            if (mutation.type === 'attributes' && mutation.attributeName === 'class') {
6788                serviceTableSwiper.update();
6789            }
6790        }
6791    });
6792
6793    mutationObserver.observe(tabContentParent, {
6794        attributes: true,
6795        attributeFilter: ['class'],
6796    });
6797};
6798
6799EA.Methods.setParentHeight = function($this){
6800    var child = $this.find('.set-height');
6801    $(window).on('load resize', function() {
6802        if (window.innerWidth >= 1000) {
6803            var parentHeight = 0;
6804            $(child).each(function(){
6805                var eleHeight = $(this).height();
6806                if (eleHeight > parentHeight) {
6807                    parentHeight = eleHeight + 50;
6808                }
6809            });
6810            $this.css('min-height', parentHeight);
6811        } else {
6812            $this.css('min-height', '');
6813        }
6814    });
6815};
6816EA.Methods.showContentRadio = function($this){
6817    const inputs = $this[0].querySelectorAll('input');
6818    const button = $this[0].querySelector('.show-button');
6819    const deliverConfirmation = $this[0].querySelector('.delivery-confirmation-address');
6820    const deliveryComment = $this[0].querySelector('.delivery-comment');
6821    const courierWrapper = $this[0].querySelector('.free-courier-wrapper');
6822
6823    for (let i = 0; i < inputs.length; i++) {
6824        if(inputs[i].classList.contains('box-now') && inputs[i].checked) {
6825            if(button.classList.contains('active')) {
6826                if(deliverConfirmation && deliveryComment) {    
6827                    deliverConfirmation.classList.add('active');
6828                    deliveryComment.classList.add('active');
6829                }
6830            } else {
6831                if(deliverConfirmation && deliveryComment) {    
6832                    deliverConfirmation.classList.remove('active');
6833                    deliveryComment.classList.remove('active');
6834                }
6835            }
6836        } else if(inputs[i].classList.contains('free-courier')) {
6837            if(inputs[i].checked) {
6838                courierWrapper.classList.add('active');
6839                if(deliverConfirmation && deliveryComment) {    
6840                    deliverConfirmation.classList.remove('active');
6841                    deliveryComment.classList.remove('active');
6842                }
6843            } else {
6844                courierWrapper.classList.remove('active');
6845                if(deliverConfirmation && deliveryComment) {    
6846                    deliverConfirmation.classList.add('active');
6847                    deliveryComment.classList.add('active');
6848                }
6849            }
6850        } 
6851    }
6852
6853    for (let i = 0; i < inputs.length; i++) {
6854        inputs[i].addEventListener('change', () => {
6855            if(inputs[i].classList.contains('box-now')) {
6856                if(button.classList.contains('active')) {
6857                    button.classList.remove('active');
6858                    courierWrapper.classList.remove('active');
6859                    if(deliverConfirmation && deliveryComment) {    
6860                        deliverConfirmation.classList.remove('active');
6861                        deliveryComment.classList.remove('active');
6862                    }
6863                } else {
6864                    button.classList.add('active');
6865                    courierWrapper.classList.remove('active');
6866                    if(deliverConfirmation && deliveryComment) {    
6867                        deliverConfirmation.classList.add('active');
6868                        deliveryComment.classList.add('active');
6869                    }
6870                }
6871            } else if(inputs[i].classList.contains('free-courier')) {
6872                if(inputs[i].checked) {
6873                    button.classList.remove('active');
6874                    courierWrapper.classList.add('active');
6875                    if(deliverConfirmation && deliveryComment) {    
6876                        deliverConfirmation.classList.remove('active');
6877                        deliveryComment.classList.remove('active');
6878                    }
6879                } else {
6880                    button.classList.remove('active');
6881                    courierWrapper.classList.remove('active');
6882                    if(deliverConfirmation && deliveryComment) {    
6883                        deliverConfirmation.classList.add('active');
6884                        deliveryComment.classList.add('active');
6885                    }
6886                }
6887            } 
6888        })
6889    }
6890};
6891EA.Methods.simmetricalSlides = function($this) {
6892    // Get each part
6893    const slidesHeader = $this.find('.package-slider-title-wrapper');    
6894    const slidesContent = $this.find('.package-slide-adjustable-content');
6895
6896    // Get heights for each part
6897    const headerHeights = $.map(slidesHeader, item => item.offsetHeight);
6898    const contentHeights = $.map(slidesContent, item => item.offsetHeight);
6899
6900    // Get max height for each part
6901    const headerMaxHeight = Math.max(...headerHeights);
6902    const contentMaxHeight = Math.max(...contentHeights);
6903
6904    // Set the height to all slidesHeader elements
6905    slidesHeader.each(function() {
6906        $(this).css('height', headerMaxHeight + 'px');
6907    });
6908
6909    // Set the height to all slidesContent elements
6910    slidesContent.each(function() {
6911        $(this).css('height', contentMaxHeight + 'px');
6912    });
6913}; 
6914EA.Methods.singleDeviceSlider = function($this){
6915    var mainSliderEl = $('.single-device-slider .swiper-container');
6916    var thumbSliderEl = $('.single-device-thumbs .swiper-container');
6917    var thumbSlide = thumbSliderEl.find('.swiper-slide');
6918
6919    var mainSlider = new Swiper(mainSliderEl, {
6920        loop: true,
6921        speed: 700,
6922        effect: 'fade',
6923        simulateTouch: false,
6924        fadeEffect: {
6925            crossFade: true
6926        }
6927    });
6928
6929    var thumbsSlider = new Swiper(thumbSliderEl, {
6930        loop: false,
6931        spaceBetween: 0,
6932        slidesPerView: 4,
6933        breakpoints: {
6934            600: {
6935                direction: 'vertical'
6936            }
6937        }
6938    });
6939
6940    // First thumb active
6941    thumbSlide.eq(0).addClass('swiper-slide-thumb-active');
6942
6943    // Slider change on click
6944    thumbSlide.click(function () {
6945        $(this).addClass('swiper-slide-thumb-active').siblings().removeClass('swiper-slide-thumb-active');
6946
6947        var index = thumbSlide.index(this);
6948        var activeIndex = thumbsSlider.activeIndex;
6949        var diff = index - activeIndex;
6950
6951
6952        // Change main slider
6953        mainSlider.slideTo(index + 1);
6954
6955        // Prev slide
6956        if (index === activeIndex && index !== 0) {
6957            thumbsSlider.slidePrev();
6958        }
6959
6960        // Next slide
6961        if (diff > 2) {
6962            thumbsSlider.slideNext();
6963        }
6964    });
6965};
6966
6967EA.Methods.skyBenefitsEqualTitles = function ($this) {
6968    let benefitsSection = $this;
6969
6970    function skyBenefitsHeightMatcher(section) {
6971        const titles = section.find('.skyshowtime-benefits-item-title');
6972        let highestTitleValue = 0;
6973    
6974        titles.css('height', '');
6975    
6976        titles.each(function () {
6977            const titleValue = $(this).outerHeight();
6978    
6979            if (titleValue > highestTitleValue) {
6980                highestTitleValue = titleValue;
6981            }
6982        });
6983    
6984        titles.css('height', highestTitleValue + 'px');
6985    }
6986
6987    skyBenefitsHeightMatcher(benefitsSection);
6988
6989    // Resize handler
6990    let timeoutId;
6991    
6992    window.addEventListener('resize', () => {
6993        if (window.innerWidth <= 800) {
6994            benefitsSection.find('.skyshowtime-benefits-item-title').css('height', '');
6995            return;
6996        }
6997        
6998        clearTimeout(timeoutId);
6999    
7000        timeoutId = setTimeout(() => {
7001            skyBenefitsHeightMatcher(benefitsSection);
7002        }, 100);
7003    });
7004};
7005
7006
7007EA.Methods.skyBenefitsSlider = function($this) {
7008    let slider = null;
7009    const sliderElement = $this.find('.swiper-container')[0];
7010    const pag = $this.find('.swiper-pagination')[0];
7011    
7012    slider = new Swiper(sliderElement, {
7013        speed: 600,
7014        loop: false,
7015        slidesPerView: 1, 
7016        spaceBetween: 0,
7017        pagination: {
7018            el: pag,
7019            clickable: true,
7020        },
7021        on: {
7022            init: function () {
7023                sliderElement.classList.add('loaded');
7024            }
7025        }
7026    });
7027
7028    skyBenefitsSliderResizeHandler();
7029
7030    let timeoutId;
7031    
7032    window.addEventListener('resize', () => {
7033        clearTimeout(timeoutId);
7034        
7035        timeoutId = setTimeout(() => {
7036            skyBenefitsSliderResizeHandler();
7037        }, 100);
7038    });
7039    
7040    function skyBenefitsSliderResizeHandler() {
7041        if(window.innerWidth <= 800) {
7042            slider.allowTouchMove = true;
7043        } else {
7044            slider.slideTo(0,0);
7045            slider.allowTouchMove = false;
7046        }
7047    }
7048}
7049
7050EA.Methods.sliderAbout = function($this) {
7051	const slider = $this.find('.swiper-container');
7052	const next = $this.find('.swiper-button-next');
7053	const prev = $this.find('.swiper-button-prev');
7054	const pagination = $this.find('.swiper-pagination');
7055	
7056	new Swiper(slider, {
7057		speed: 600,
7058		loop: true,
7059		slidesPerView: 1.2,
7060		spaceBetween: 20,
7061		navigation: {
7062			nextEl: next,
7063			prevEl: prev,
7064		},
7065		pagination: {
7066			el: pagination,
7067			clickable: true,
7068		},
7069		breakpoints: {
7070			600: {
7071				slidesPerView: 2.2,
7072				spaceBetween: 20,
7073			},
7074			800: {
7075				slidesPerView: 1.5,
7076				spaceBetween: 20,
7077			},
7078			1000: {
7079				slidesPerView: 2.1,
7080				spaceBetween: 20,
7081			},
7082			1200: {
7083				slidesPerView: 2.5,
7084				spaceBetween: 20,
7085			},
7086			1500: {
7087				slidesPerView: 3.2,
7088				spaceBetween: 28,
7089			}
7090		}
7091	});
7092}
7093
7094EA.Methods.sliderAplication = function ($this) {
7095    const slider = $this.find('.swiper-container');
7096    const pag = $this.find('.swiper-pagination');
7097
7098    new Swiper(slider, {
7099        speed: 600,
7100        loop: false,
7101        slidesPerView: 1.5,
7102        spaceBetween: 0,
7103        pagination: {
7104            el: pag,
7105            clickable: true,
7106        },
7107        breakpoints: {
7108            600: {
7109                slidesPerView: 1.5,
7110                spaceBetween: 0,
7111                centeredSlides: false,
7112            },
7113            800: {
7114                slidesPerView: 2.5,
7115                spaceBetween: 0,
7116                centeredSlides: false,
7117            },
7118            1000: {
7119                slidesPerView: 3.0,
7120                spaceBetween: 0,
7121                centeredSlides: false,
7122            },
7123            1200: {
7124                slidesPerView: 3.5,
7125                spaceBetween: 0,
7126                centeredSlides: true,
7127                allowTouchMove: true
7128            },
7129            1500: {
7130                slidesPerView: 4,
7131                spaceBetween: 0,
7132                centeredSlides: false,
7133                allowTouchMove: false
7134            }
7135        }
7136    });
7137
7138}
7139EA.Methods.sliderBenefits = function ($this) {
7140    const sliderEl = $this.find('.swiper-container');
7141	const pag = $this.find('.swiper-pagination');
7142
7143    const breakpoint = window.matchMedia('(min-width: 1201px)');
7144    let thumbsSwiper;
7145
7146    const breakpointChecker = function() {
7147        if ( breakpoint.matches === true ) {
7148            if ( thumbsSwiper !== undefined ) thumbsSwiper.destroy( true, true );
7149            return;
7150        } else if ( breakpoint.matches === false ) {
7151            return enableSwiper();
7152        }
7153    };
7154
7155    const enableSwiper = function() {
7156        thumbsSwiper = new Swiper(sliderEl, {
7157            speed: 1000,
7158            loop: false,
7159            slidesPerView: 1.2,
7160            allowTouchMove: true,
7161			pagination: {
7162				el: pag,
7163				clickable: true,
7164			},
7165            breakpoints: {
7166				320: {
7167                    slidesPerView: 2,
7168                },
7169				800: {
7170                    slidesPerView: 2.5,
7171                },
7172				1001: {
7173                    slidesPerView: 3,
7174				},
7175            }
7176        });
7177    };
7178
7179    breakpoint.addEventListener('change', breakpointChecker);
7180    breakpointChecker();
7181
7182};
7183EA.Methods.sliderChannel = function($this) {
7184	const slider = $this.find('.swiper-container');
7185	const next = $this.find('.swiper-button-next');
7186	const prev = $this.find('.swiper-button-prev');
7187	
7188	const swiper = new Swiper(slider, {
7189		speed: 600,
7190		slidesPerView: 1.2,
7191		spaceBetween: 25,
7192		freeMode: true,
7193		navigation: {
7194			nextEl: next,
7195			prevEl: prev,
7196		},
7197		breakpoints: {
7198			600: {
7199			slidesPerView: 2.2,
7200			spaceBetween: 20,
7201			},
7202			800: {
7203			slidesPerView: 1.5,
7204			spaceBetween: 20,
7205			},
7206			1000: {
7207			slidesPerView: 2.1,
7208			spaceBetween: 20,
7209			},
7210			1200: {
7211			slidesPerView: 2.5,
7212			spaceBetween: 20,
7213			},
7214			1500: {
7215			slidesPerView: 3.2,
7216			spaceBetween: 30,
7217			}
7218		}
7219	});
7220	
7221	$this.find('.tv-channels-list-item').on('click', function () {
7222		[...swiper].forEach(function (el) {
7223			setTimeout(function () {
7224				el.slideTo(0, 1);
7225			}, 400);
7226		});
7227	})
7228};
7229
7230EA.Methods.sliderDeviceLogo = function ($this) {
7231	const slider = $this.find('.swiper-container');
7232	const pag = $this.find('.swiper-pagination');
7233
7234	new Swiper(slider, {
7235		speed: 600,
7236		loop: false,
7237		slidesPerView: 2,
7238		spaceBetween: 0,
7239		allowTouchMove: true,
7240		pagination: {
7241			el: pag,
7242			clickable: true,
7243		},
7244		breakpoints: {
7245			1000: {
7246				slidesPerView: 3,
7247				paceBetween: 10,
7248			},
7249			1200: {
7250				slidesPerView: 4,
7251				spaceBetween: 20,
7252			},
7253			1500: {
7254				slidesPerView: 5,
7255				spaceBetween: 20,
7256			}
7257		}
7258	});
7259}
7260EA.Methods.sliderDevicePlan = function ($this) {
7261    const sliderEl = $this.find('.swiper-container');
7262	const pag = $this.find('.swiper-pagination');
7263    const breakpoint = window.matchMedia('(min-width: 1601px)');
7264    let thumbsSwiper;
7265
7266    const breakpointChecker = function() {
7267        if ( breakpoint.matches === true ) {
7268            if ( thumbsSwiper !== undefined ) thumbsSwiper.destroy( true, true );
7269            return;
7270        } else if ( breakpoint.matches === false ) {
7271            return enableSwiper();
7272        }
7273    };
7274
7275    const enableSwiper = function() {
7276        thumbsSwiper = new Swiper(sliderEl, {
7277            speed: 1000,
7278            loop: false,
7279            slidesPerView: 1,
7280            spaceBetween: 10,
7281            allowTouchMove: true,
7282			pagination: {
7283				el: pag,
7284				clickable: true,
7285			},
7286            breakpoints: {
7287				601: {
7288                    slidesPerView: 1.5,
7289                    spaceBetween: 20,
7290                },
7291				800: {
7292                    slidesPerView: 2,
7293                    spaceBetween: 20,
7294                },
7295				1201: {
7296                    slidesPerView: 1.8,
7297                    spaceBetween: 20,
7298				},
7299                1501: {
7300                    slidesPerView: 2.5,
7301                    spaceBetween: 20,
7302                }
7303            }
7304        });
7305    };
7306
7307    breakpoint.addEventListener('change', breakpointChecker);
7308    breakpointChecker();
7309
7310};
7311EA.Methods.sliderDeviceReturn = function ($this) {
7312    const sliderEl = $this.find('.swiper-container');
7313	const pag = $this.find('.swiper-pagination');
7314
7315    const breakpoint = window.matchMedia('(min-width: 600px)');
7316    let thumbsSwiper;
7317
7318    const breakpointChecker = function() {
7319        if ( breakpoint.matches === true ) {
7320            if ( thumbsSwiper !== undefined ) thumbsSwiper.destroy( true, true );
7321            return;
7322        } else if ( breakpoint.matches === false ) {
7323            return enableSwiper();
7324        }
7325    };
7326
7327    const enableSwiper = function() {
7328        thumbsSwiper = new Swiper(sliderEl, {
7329            speed: 1000,
7330            loop: false,
7331            slidesPerView: 1,
7332            allowTouchMove: true,
7333			pagination: {
7334				el: pag,
7335				clickable: true,
7336			},
7337        });
7338    };
7339
7340    breakpoint.addEventListener('change', breakpointChecker);
7341    breakpointChecker();
7342
7343};
7344EA.Methods.sliderEcosystem = function ($this) {
7345    const slider = $this.find('.swiper-container');
7346    const pagination = $this.find('.swiper-pagination');
7347    const breakpoint = window.matchMedia('(max-width: 1000px)');
7348    
7349    createImageBitmap
7350
7351    const swiper = new Swiper(slider, {
7352        speed: 600,
7353        loop: false,
7354        slidesPerView: 1.2,
7355        spaceBetween: 20,
7356        allowTouchMove: true,
7357        pagination: {
7358            el: pagination, 
7359            clickable: true,
7360        },
7361        breakpoints: {
7362            360: {
7363                slidesPerView: 2.8,
7364                spaceBetween: 12,
7365            },
7366            801: {
7367                slidesPerView: 3,
7368                spaceBetween: 32,
7369            },
7370        }
7371    });
7372
7373    function toggleDisableSwiper() {
7374        if ( breakpoint.matches === false ) {
7375            slider.addClass('slider-disabled');
7376            swiper.allowTouchMove = false;
7377        } else {
7378            slider.removeClass('slider-disabled');
7379            swiper.allowTouchMove = true;
7380        }
7381    }
7382
7383    toggleDisableSwiper();
7384
7385    window.addEventListener('resize', toggleDisableSwiper);
7386};
7387EA.Methods.sliderGift = function ($this) {
7388    const slider = $this.find('.swiper-container');
7389    const pag = $this.find('.swiper-pagination');
7390    const lengthSlides = $this.find('.swiper-slide').length;
7391    const breakpoint = window.matchMedia('(max-width: 600px)');
7392
7393    new Swiper(slider, {
7394        speed: 600,
7395        loop: false,
7396        slidesPerView: 1.5,
7397        spaceBetween: 20,
7398        pagination: {
7399            el: pag,
7400            clickable: true,
7401        },
7402        breakpoints: {
7403            481: {
7404                slidesPerView: 1.8,
7405                spaceBetween: 20,
7406            },
7407            600: {
7408                slidesPerView: 3.3,
7409                spaceBetween: 20,
7410            },
7411            800: {
7412                slidesPerView: 4,
7413                spaceBetween: 20,
7414            },
7415            1001: {
7416                slidesPerView: 2.8,
7417                spaceBetween: 20,
7418            },
7419            1201: {
7420                slidesPerView: 3.3,
7421                spaceBetween: 20,
7422            }
7423        }
7424    });
7425
7426    pagUpdate();
7427
7428    function pagUpdate() {
7429        if (lengthSlides <= 3 && !breakpoint.matches) {
7430            pag.css('display', 'none');
7431        } else {
7432            pag.css('display', 'flex');
7433        }
7434    }
7435
7436    $(window).on('resize', () => {pagUpdate()});
7437    $(window).on('load', () => {pagUpdate()});
7438
7439}
7440EA.Methods.sliderIntro = function($this){
7441    const slider = $this.find('.intro-slider-wrapper .swiper-container');
7442    const imgSlider = $this.find('.home-img-slider .swiper-container');
7443    const pag = $this.find('.swiper-pagination');
7444
7445    const mySwiper = new Swiper(slider, {
7446        speed: 600,
7447        loop: true,
7448        parallax: true,
7449        effect: 'fade',
7450        autoplay: {
7451            delay: 5000,
7452            disableOnInteraction: false
7453        },
7454        fadeEffect: {
7455            crossFade: true
7456        },
7457        pagination: {
7458            el: pag,
7459            clickable: true
7460        } 
7461    });
7462
7463    const homeImgSlider = new Swiper(imgSlider, {
7464        speed: 1200,
7465        loop: true,
7466        effect: 'fade',
7467        simulateTouch: false,
7468        touchRatio: 0,
7469        fadeEffect: {
7470            crossFade: true
7471        }
7472    });
7473    
7474    mySwiper.on('slideChangeTransitionStart', function () {
7475        homeImgSlider.slideTo(mySwiper.activeIndex);
7476    });
7477};
7478EA.Methods.sliderMobileStep = function ($this) {
7479    const slider = $this.find('.swiper-container');
7480    const pagination = $this.find('.swiper-pagination');
7481    const breakpoint = window.matchMedia('(max-width: 1000px)');
7482    
7483    const swiper = new Swiper(slider, {
7484        speed: 600,
7485        loop: false,
7486        slidesPerView: 1,
7487        slidesPerGroup: 1,
7488        spaceBetween: 20,
7489        allowTouchMove: true,
7490        pagination: {
7491            el: pagination, 
7492            clickable: true,
7493        },
7494        breakpoints: {
7495            360: {
7496                slidesPerView: 1,
7497                spaceBetween: 20,
7498            },
7499            481: {
7500                slidesPerView: 2.8,
7501                spaceBetween: 20,
7502            },
7503            601: {
7504                slidesPerView: 3.8,
7505                spaceBetween: 20,
7506            },
7507            801: {
7508                slidesPerView: 4.8,
7509                spaceBetween: 20,
7510            },
7511            1001: {
7512                slidesPerView: 5,
7513                spaceBetween: 20,
7514            }
7515        }
7516    });
7517
7518    function toggleDisableSwiper() {
7519        if ( breakpoint.matches === false ) {
7520            slider.addClass('slider-disabled');
7521            swiper.allowTouchMove = false;
7522        } else {
7523            slider.removeClass('slider-disabled');
7524            swiper.allowTouchMove = true;
7525        }
7526    }
7527
7528    toggleDisableSwiper();
7529
7530    window.addEventListener('resize', toggleDisableSwiper);
7531};
7532EA.Methods.sliderPackages = function ($this) {
7533    const slider = $this.find('.swiper-container');
7534    const pagination = $this.find('.swiper-pagination');
7535    const next = $this.find('.swiper-button-next');
7536	const prev = $this.find('.swiper-button-prev');
7537    const length = $this.find('.swiper-slide').length;
7538    const breakpoint = window.matchMedia('(min-width: 1760px)');
7539    const breakpoint2 = window.matchMedia('(max-width: 1075px)');
7540    const breakpoint3 = window.matchMedia('(max-width: 1558px)');
7541    let thumbsSwiper;    
7542
7543    const isDesktopSlider = $this.data('desktop-slider');
7544    const isDesktopPagination = $this.data('desktop-pagination');
7545    
7546    if(isDesktopSlider) {
7547        setTimeout(() => {
7548            enableSwiper();
7549            thumbsSwiper.slideTo(0);
7550        });
7551    }
7552
7553    const breakpointChecker = function() {
7554        if(!isDesktopSlider) {
7555            if ( breakpoint.matches === true ) {
7556                if ( thumbsSwiper !== undefined ) thumbsSwiper.destroy( true, true );
7557                slider.addClass('loaded');
7558                return;
7559            } else if ( breakpoint.matches === false ) {
7560                enableSwiper();
7561            }
7562        }
7563    };
7564    
7565    const enableSwiper = function() {
7566            thumbsSwiper = new Swiper(slider, {
7567            speed: 600,
7568            loop: false,
7569            slidesPerView: 'auto',
7570            slidesPerGroup: 1,
7571            spaceBetween: 10,
7572            allowTouchMove: true,
7573            centerInsufficientSlides: true,
7574            centeredSlides: true,
7575            initialSlide : length,
7576            pagination: {
7577                el: pagination, 
7578                clickable: true,
7579            },
7580            navigation: {
7581                nextEl: next,
7582                prevEl: prev,
7583            },
7584            breakpoints: {
7585                360: {
7586                    spaceBetween: 20,
7587                    centeredSlides: false,
7588                },
7589                481: {
7590                    spaceBetween: 20,
7591                    centeredSlides: false,
7592                },
7593            },
7594            on: {
7595                init: function () {
7596                    paginationCheck();
7597                    checkSwiperStatus();
7598
7599                    slider.addClass('loaded');
7600                    next.addClass('loaded');
7601                    prev.addClass('loaded');
7602                },
7603                resize: function () {
7604                    checkSwiperStatus();
7605                }
7606            }
7607        });
7608    };
7609
7610    if(!isDesktopSlider) {
7611        breakpoint.addEventListener('change', breakpointChecker);
7612        breakpointChecker();
7613    }
7614
7615    if(!isDesktopPagination) {
7616        function paginationCheck() {
7617            let paginationBullets = pagination.children().length;
7618            if (paginationBullets > 1 && breakpoint2.matches === true) {
7619                pagination.css('display', 'block');
7620                if(thumbsSwiper !== undefined) {
7621                    thumbsSwiper.allowTouchMove = true;
7622                }
7623            } else if (paginationBullets > 1 && breakpoint3.matches === true && length >= 4) {
7624                pagination.css('display', 'block');
7625                if(thumbsSwiper !== undefined) {
7626                    thumbsSwiper.allowTouchMove = true;
7627                }
7628            } else {
7629                pagination.css('display', 'none');
7630                if(thumbsSwiper !== undefined) {
7631                    thumbsSwiper.allowTouchMove = true;
7632                }
7633            }
7634        }
7635    
7636        window.addEventListener('load', function() {
7637            paginationCheck();
7638            checkSwiperStatus();
7639        });
7640        window.addEventListener('resize', paginationCheck);
7641    }
7642
7643    function checkSwiperStatus() {
7644        requestAnimationFrame(() => {
7645            const swiperWrapperWidth = $this.find('.swiper-wrapper').outerWidth(true);
7646
7647            const slides = $this.find('.swiper-slide');
7648            const slidesWidth = slides.outerWidth(true) * (slides.length - 1) + slides.width();
7649
7650            if(slidesWidth < swiperWrapperWidth) {
7651                if(thumbsSwiper !== undefined) {
7652                    thumbsSwiper.allowTouchMove = false;
7653                }
7654            } else {
7655                if(thumbsSwiper !== undefined) {
7656                    thumbsSwiper.allowTouchMove = true;
7657                }
7658            }
7659        });
7660    }
7661};
7662EA.Methods.sliderSeemore = function ($this) {
7663    const slider = $this.find('.swiper-container');
7664    const pagination = $this.find('.swiper-pagination');
7665    const breakpoint = window.matchMedia('(min-width: 800px)');
7666    const breakpoint2 = window.matchMedia('(max-width: 1075px)');
7667    let thumbsSwiper;
7668
7669    const breakpointChecker = function() {
7670        if ( breakpoint.matches === true ) {
7671            if ( thumbsSwiper !== undefined ) thumbsSwiper.destroy( true, true );
7672            return;
7673        } else if ( breakpoint.matches === false ) {
7674            return enableSwiper();
7675        }
7676    };
7677    
7678    const enableSwiper = function() {
7679            thumbsSwiper = new Swiper(slider, {
7680            speed: 600,
7681            loop: false,
7682            slidesPerView: 'auto',
7683            slidesPerGroup: 1,
7684            spaceBetween: 10,
7685            allowTouchMove: true,
7686            centerInsufficientSlides: true,
7687            pagination: {
7688                el: pagination, 
7689                clickable: true,
7690            },
7691            breakpoints: {
7692                360: {
7693                    slidesPerView: 1.8,
7694                    spaceBetween: 20,
7695                    centerInsufficientSlides: false,
7696                },
7697                481: {
7698                    spaceBetween: 20,
7699                },
7700            }
7701        });
7702    };
7703
7704    breakpoint.addEventListener('change', breakpointChecker);
7705    breakpointChecker();
7706
7707    function paginationCheck() {
7708        let paginationBullets = pagination.children().length;
7709        if (paginationBullets > 1 && breakpoint2.matches === true) {
7710            pagination.css('display', 'block');
7711            if(thumbsSwiper !== undefined) {
7712                thumbsSwiper.allowTouchMove = true;
7713            }
7714        } else {
7715            pagination.css('display', 'none');
7716            if(thumbsSwiper !== undefined) {
7717                thumbsSwiper.allowTouchMove = true;
7718            }
7719        }
7720    }
7721
7722    window.addEventListener('load', paginationCheck);
7723    window.addEventListener('resize', paginationCheck);
7724};
7725EA.Methods.sliderShowcase = function ($this) {
7726    const slider = $this.find('.swiper');
7727    const direction = $this.data('direction') ? $this.data('direction') : 'normal';
7728
7729    const sliderShowcaseInstance = new Swiper(slider, {
7730        speed: 8000,
7731        loop: true,
7732        slidesPerView: 'auto',
7733        spaceBetween: 20,
7734        autoplay: {
7735            delay: 0,
7736            disableOnInteraction: false,
7737            reverseDirection: direction === 'reverse' ? true : false,
7738        },
7739        on: {
7740            init: function () {
7741                slider.addClass('loaded');
7742            },
7743        }
7744    });
7745
7746    window.addEventListener('resize', function() {
7747        sliderShowcaseInstance.slideTo(0, 0, true);
7748    });
7749};
7750EA.Methods.tabToggle = function($this){
7751    const item = $this.find('.tab-toggle');
7752    
7753	item.on('click', function (e) {
7754        e.preventDefault();
7755        var thisIndex = $(this).index();
7756        $(this).addClass('active').siblings().removeClass('active');
7757        $this.find('.tab-toggle-content').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
7758    });
7759};
7760EA.Methods.toggleActiveParent = function($this){
7761    $this.find('.toggle-active').on('click', function (e) {
7762        e.preventDefault();
7763        $this.find('.toggle-active').checked=true;
7764        $(this).parent().toggleClass('active');
7765    });
7766};
7767EA.Methods.toggleDropdown = function($this){
7768    const item = $this.find('.toggle-item');
7769
7770	item.on('click', function (e) {
7771        e.stopPropagation();
7772        $(this).toggleClass('active');
7773        $(this).find('.toggle-hidden-content').stop().slideToggle();
7774        $(this).siblings('.toggle-item').removeClass('active').find('.toggle-hidden-content').slideUp();
7775    });
7776
7777    $('body').on('click', function () {
7778        $this.find('.toggle-item').removeClass('active');
7779        $this.find('.toggle-hidden-content').slideUp();
7780    });
7781};
7782EA.Methods.toggleFaq = function($this){
7783    const item = $this.find('.toggle-item');
7784    const content = $this.find('.toggle-hidden-content');
7785    let hasActive = false;
7786
7787	item.on('click', function (e) {
7788        e.stopPropagation();
7789        if($(this).hasClass('active')) {
7790            hasActive = true;
7791        }
7792        else {
7793            hasActive = false;
7794        }
7795        item.removeClass('active');
7796        content.slideUp();
7797        if(!hasActive) {
7798            $(this).addClass('active');
7799        }
7800        $(this).find('.toggle-hidden-content').stop().slideToggle();
7801    });
7802
7803    $('body').on('click', function () {
7804        item.removeClass('active');
7805        content.slideUp();
7806    });
7807};
7808EA.Methods.toggleFaqActive = function($this){
7809    var item = $this.find('.toggle-popup-item');
7810    
7811    item.each(function() {
7812        if($(this).hasClass('active')) {
7813            item.find('.toggle-popup-hidden-content').slideUp();
7814            $(this).find('.toggle-popup-hidden-content').slideDown();
7815        }
7816    });
7817
7818	item.on('click', function (e) {
7819        e.stopPropagation();
7820        $(this).toggleClass('active');
7821        $(this).find('.toggle-popup-hidden-content').stop().slideToggle();
7822        $(this).siblings('.toggle-popup-item').removeClass('active').find('.toggle-popup-hidden-content').slideUp();
7823    });
7824
7825};
7826EA.Methods.toggleHiddenContent = function($this) {
7827    const item = $this.find('.toggle-trigger'); 
7828    
7829	item.on('click', function (e) {
7830        e.preventDefault();
7831        $this.find('.toggle-content').slideToggle();
7832        $this.toggleClass('active');
7833    });
7834}; 
7835EA.Methods.toggleInputLabel = function($this){
7836    const toggle = $this.find('.toggle-input');
7837    const toggleLabelLeft = $this.find('.toggle-label-left');
7838    const toggleLabelRight = $this.find('.toggle-label-right');
7839
7840    RadioCheck();
7841    $(toggle).on('change', () => {
7842        RadioCheck();
7843    });
7844
7845    function RadioCheck() {
7846        if($(toggle).is(':checked')) {
7847            $(toggleLabelLeft).removeClass('active');
7848            $(toggleLabelRight).addClass('active');
7849        }
7850        else {
7851            $(toggleLabelLeft).addClass('active');
7852            $(toggleLabelRight).removeClass('active');
7853        }
7854    }
7855
7856};
7857EA.Methods.togglePrograms = function($this) {
7858    const item = $this.find('.program-tab-reveal');
7859
7860    item.on('click', function (e) {
7861        e.preventDefault();
7862        e.stopPropagation();
7863        $(this).toggleClass('active').parents('.program-list-tab-content').find('.program-list-links-hidden-content').slideToggle();
7864        $('.program-list-links-hidden-content').not($(this).parents('.program-list-tab-content').find('.program-list-links-hidden-content')).slideUp();
7865    });
7866
7867    $('.program-list-tab-content').on('click', function (e) {
7868        e.stopPropagation();
7869    });
7870
7871    $('body').on('click', function () {
7872        $('.program-list-links-hidden-content').slideUp();
7873        item.removeClass('active')
7874    });
7875}
7876EA.Methods.toggleText = function($this) {
7877    const radio = $('.form-1-checkbox-wrapper input[type="radio"]');
7878
7879    radio.click(function () {
7880        if ($(this).val() === 'voucher-1') {
7881            $('.hidden-1').addClass('hidden');
7882            $('.hidden-2').removeClass('hidden');
7883        } else if ($(this).val() === 'voucher-2') {
7884            $('.hidden-2').addClass('hidden');
7885            $('.hidden-1').removeClass('hidden');
7886        }
7887    });
7888}
7889EA.Methods.toggleVoucher = function($this){
7890    const show = $this.find('.show-text a');
7891    const hide = $this.find('.hide-text a');
7892    const removeIcons = $('.voucher-remove-icon');
7893
7894    show.on('click', function (e) {
7895        e.preventDefault();
7896
7897        const $block = $(this).closest('.inner-voucher-block');
7898
7899        $block.find('.show-text').addClass('hidden');
7900        $block.find('.hide-text').addClass('active');
7901        $block.find('.toggle-hidden-content').stop().slideDown();
7902    });
7903
7904    hide.on('click', function (e) {
7905        e.preventDefault();
7906
7907        const $block = $(this).closest('.inner-voucher-block');
7908
7909        $block.find('.hide-text').removeClass('active');
7910        $block.find('.show-text').removeClass('hidden');
7911        $block.find('.toggle-hidden-content').stop().slideUp();
7912    });
7913
7914    removeIcons.on('click', function (e) {
7915        e.preventDefault();
7916
7917        const $item = $(this).closest('.inner-voucher-entered-wrap'); // the item to remove
7918        const $wrap = $item.closest('.voucher-entered-wrap'); // the container for all vouchers
7919
7920        $item.remove();
7921
7922        if ($wrap.find('.inner-voucher-entered-wrap').length === 0) {
7923            $wrap.addClass('none');
7924        }
7925    });
7926
7927};
7928EA.Methods.triggerActive = function($this) {
7929    let radioButton = $this[0].querySelector('input[id="landline-customer"]');
7930
7931    document.addEventListener('input', (e) => {
7932        if (e.target.getAttribute('name') == 'customer') {
7933
7934            if(e.target.value == 2) {
7935                radioButton.parentNode.parentNode.classList.add('active');
7936            } else {
7937                radioButton.parentNode.parentNode.classList.remove('active');
7938            }
7939        }
7940    })
7941};
7942EA.Methods.tvFeaturesToggle = function($this){
7943    const item = $this.find('.tab-toggle');
7944    
7945	item.on('click', function (e) {
7946        e.preventDefault();
7947        var thisIndex = $(this).index();
7948        $(this).addClass('active').siblings().removeClass('active');
7949        $this.find('.tab-toggle-content').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
7950        $this.find('.tab-toggle-content-2').find($('.tab-target')).eq(thisIndex).addClass('active').siblings().removeClass('active');
7951    });
7952};
7953EA.Methods.tvSlider = function($this) {
7954    const slider = $this.find('.swiper-container');
7955    const next = $this.find('.swiper-button-next');
7956    const prev = $this.find('.swiper-button-prev');
7957    const pag = $this.find('.swiper-pagination');
7958    
7959    new Swiper(slider, {
7960        speed: 600,
7961        loop: false,
7962        slidesPerView: 1.2,
7963        spaceBetween: 20,
7964        navigation: {
7965            nextEl: next,
7966            prevEl: prev,
7967        },
7968        pagination: {
7969            el: pag,
7970            clickable: true,
7971        },
7972        breakpoints: {
7973            800: {
7974                slidesPerView: 1.5,
7975                spaceBetween: 20,
7976            },
7977            1000: {
7978                slidesPerView: 1.8,
7979                spaceBetween: 40,
7980            },
7981            1500: {
7982                slidesPerView: 3,
7983                spaceBetween: 65,
7984            }
7985        }
7986    });
7987}
7988EA.Methods.videoModal = function($this){
7989
7990    const modalTrigger = $('.video-modal-trigger');
7991    const videoModalClose = $('.video-modal-close');
7992    const tl = gsap.timeline({paused: true});
7993    const scrollTimeline = gsap.timeline({repeat: -1, paused: true});
7994    const scrollText = $this.find('.scroll-text');
7995    const scrollSpan = scrollText.find('.scroll-span');
7996
7997    scrollSpan.clone().appendTo(scrollText);
7998    scrollTimeline.to(scrollText, {
7999        x: -scrollSpan.width(),
8000        ease: 'none',
8001        duration: 15
8002    });
8003
8004    tl
8005        .to($this, {
8006            y: 0,
8007            visibility: 'visible',
8008            duration: 0.5,
8009        })
8010        .fromTo($this.find('.anim-ele'), {
8011            y: 150,
8012            alpha: 0
8013        },
8014        {
8015            y: 0,
8016            alpha: 1,
8017            stagger: 0.15,
8018            duration: 0.5,
8019        })
8020
8021    modalTrigger.on('click', function (e) {
8022        e.preventDefault();
8023        var atribute = $(this).data('video');
8024        $this.find('.modal-video source').attr('src', atribute);
8025        $this.find('.modal-video')[0].load();
8026        tl.play();
8027        scrollTimeline.play();
8028    });
8029
8030    videoModalClose.add($this).on('click', function () {
8031        tl.reverse();
8032        scrollTimeline.pause();
8033        $this.find('.modal-video source').attr('src', '');
8034        setTimeout(function () {
8035            $this.find('.modal-video')[0].load();
8036        }, 1800);
8037    });
8038
8039    $this.find('.modal-video').on('click', function (e) {
8040        e.stopPropagation();
8041    });
8042};
8043
8044EA.Methods.videoPlay = function($this){
8045    var video = $this.find('.unlimited-offers-video');
8046    var playBtn = $this.find('.play-btn');
8047    var videoSrc = playBtn.data('video');
8048    var coverImg = $this.find('.unlimited-offers-img-cover');
8049
8050    playBtn.on('click', function (e) {
8051        e.preventDefault();
8052        video.attr('src', videoSrc);
8053        setTimeout(function () {
8054            coverImg.removeClass('active');
8055            playBtn.removeClass('active');
8056            video.addClass('active');
8057        }, 300);
8058    });
8059
8060    video.on('click', function () {
8061        coverImg.addClass('active');
8062        playBtn.addClass('active');
8063        video.removeClass('active');
8064        
8065        setTimeout(function () {
8066            video.attr('src', '');
8067        }, 300);
8068    });
8069};
8070
8071EA.Methods.vodSlider = function($this){
8072    var slider = $this.find('.swiper-container');
8073    var next = $this.find('.swiper-button-next');
8074    var prev = $this.find('.swiper-button-prev');
8075    var swiper = new Swiper(slider, {
8076        speed: 600,
8077        slidesPerView: 1.2,
8078        spaceBetween: 25,
8079        freeMode: true,
8080        navigation: {
8081            nextEl: next,
8082            prevEl: prev,
8083        },
8084        breakpoints: {
8085          600: {
8086            slidesPerView: 2.2,
8087            spaceBetween: 20,
8088          },
8089          1000: {
8090              slidesPerView: 2.3,
8091              spaceBetween: 25,
8092          },
8093          1100: {
8094              slidesPerView: 3,
8095              spaceBetween: 25,
8096          },
8097          1300: {
8098              slidesPerView: 3.8,
8099              spaceBetween: 25,
8100          },
8101          1600: {
8102              slidesPerView: 4.8,
8103              spaceBetween: 25,
8104          }
8105        }
8106    });
8107    $this.find('.tv-channels-list-item').on('click', function () {
8108        [...swiper].forEach(function (el) {
8109            setTimeout(function () {
8110                el.slideTo(0, 1);
8111            }, 400);
8112        });
8113    })
8114};

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.