(function($){ 'use strict'; if(typeof wpcf7==='undefined'||wpcf7===null){ return; } wpcf7=$.extend({ cached: 0, inputs: [] }, wpcf7); $(function(){ wpcf7.supportHtml5=(function(){ var features={}; var input=document.createElement('input'); features.placeholder='placeholder' in input; var inputTypes=[ 'email', 'url', 'tel', 'number', 'range', 'date' ]; $.each(inputTypes, function(index, value){ input.setAttribute('type', value); features[ value ]=input.type!=='text'; }); return features; })(); $('div.wpcf7 > form').each(function(){ var $form=$(this); wpcf7.initForm($form); if(wpcf7.cached){ wpcf7.refill($form); }}); }); wpcf7.getId=function(form){ return parseInt($('input[name="_wpcf7"]', form).val(), 10); }; wpcf7.initForm=function(form){ var $form=$(form); $form.submit(function(event){ if(! wpcf7.supportHtml5.placeholder){ $('[placeholder].placeheld', $form).each(function(i, n){ $(n).val('').removeClass('placeheld'); }); } if(typeof window.FormData==='function'){ wpcf7.submit($form); event.preventDefault(); }}); $('.wpcf7-submit', $form).after(''); wpcf7.toggleSubmit($form); $form.on('click', '.wpcf7-acceptance', function(){ wpcf7.toggleSubmit($form); }); $('.wpcf7-exclusive-checkbox', $form).on('click', 'input:checkbox', function(){ var name=$(this).attr('name'); $form.find('input:checkbox[name="' + name + '"]').not(this).prop('checked', false); }); $('.wpcf7-list-item.has-free-text', $form).each(function(){ var $freetext=$(':input.wpcf7-free-text', this); var $wrap=$(this).closest('.wpcf7-form-control'); if($(':checkbox, :radio', this).is(':checked')){ $freetext.prop('disabled', false); }else{ $freetext.prop('disabled', true); } $wrap.on('change', ':checkbox, :radio', function(){ var $cb=$('.has-free-text', $wrap).find(':checkbox, :radio'); if($cb.is(':checked')){ $freetext.prop('disabled', false).focus(); }else{ $freetext.prop('disabled', true); }}); }); if(! wpcf7.supportHtml5.placeholder){ $('[placeholder]', $form).each(function(){ $(this).val($(this).attr('placeholder')); $(this).addClass('placeheld'); $(this).focus(function(){ if($(this).hasClass('placeheld')){ $(this).val('').removeClass('placeheld'); }}); $(this).blur(function(){ if(''===$(this).val()){ $(this).val($(this).attr('placeholder')); $(this).addClass('placeheld'); }}); }); } if(wpcf7.jqueryUi&&! wpcf7.supportHtml5.date){ $form.find('input.wpcf7-date[type="date"]').each(function(){ $(this).datepicker({ dateFormat: 'yy-mm-dd', minDate: new Date($(this).attr('min')), maxDate: new Date($(this).attr('max')) }); }); } if(wpcf7.jqueryUi&&! wpcf7.supportHtml5.number){ $form.find('input.wpcf7-number[type="number"]').each(function(){ $(this).spinner({ min: $(this).attr('min'), max: $(this).attr('max'), step: $(this).attr('step') }); }); } $('.wpcf7-character-count', $form).each(function(){ var $count=$(this); var name=$count.attr('data-target-name'); var down=$count.hasClass('down'); var starting=parseInt($count.attr('data-starting-value'), 10); var maximum=parseInt($count.attr('data-maximum-value'), 10); var minimum=parseInt($count.attr('data-minimum-value'), 10); var updateCount=function(target){ var $target=$(target); var length=$target.val().length; var count=down ? starting - length:length; $count.attr('data-current-value', count); $count.text(count); if(maximum&&maximum < length){ $count.addClass('too-long'); }else{ $count.removeClass('too-long'); } if(minimum&&length < minimum){ $count.addClass('too-short'); }else{ $count.removeClass('too-short'); }}; $(':input[name="' + name + '"]', $form).each(function(){ updateCount(this); $(this).keyup(function(){ updateCount(this); }); }); }); $form.on('change', '.wpcf7-validates-as-url', function(){ var val=$.trim($(this).val()); if(val && ! val.match(/^[a-z][a-z0-9.+-]*:/i) && -1!==val.indexOf('.')){ val=val.replace(/^\/+/, ''); val='http://' + val; } $(this).val(val); }); }; wpcf7.submit=function(form){ if(typeof window.FormData!=='function'){ return; } var $form=$(form); $('.ajax-loader', $form).addClass('is-active'); wpcf7.clearResponse($form); var formData=new FormData($form.get(0)); var detail={ id: $form.closest('div.wpcf7').attr('id'), status: 'init', inputs: [], formData: formData }; $.each($form.serializeArray(), function(i, field){ if('_wpcf7'==field.name){ detail.contactFormId=field.value; }else if('_wpcf7_version'==field.name){ detail.pluginVersion=field.value; }else if('_wpcf7_locale'==field.name){ detail.contactFormLocale=field.value; }else if('_wpcf7_unit_tag'==field.name){ detail.unitTag=field.value; }else if('_wpcf7_container_post'==field.name){ detail.containerPostId=field.value; }else if(field.name.match(/^_wpcf7_\w+_free_text_/)){ var owner=field.name.replace(/^_wpcf7_\w+_free_text_/, ''); detail.inputs.push({ name: owner + '-free-text', value: field.value }); }else if(field.name.match(/^_/)){ }else{ detail.inputs.push(field); }}); wpcf7.triggerEvent($form.closest('div.wpcf7'), 'beforesubmit', detail); var ajaxSuccess=function(data, status, xhr, $form){ detail.id=$(data.into).attr('id'); detail.status=data.status; detail.apiResponse=data; var $message=$('.wpcf7-response-output', $form); switch(data.status){ case 'validation_failed': $.each(data.invalidFields, function(i, n){ $(n.into, $form).each(function(){ wpcf7.notValidTip(this, n.message); $('.wpcf7-form-control', this).addClass('wpcf7-not-valid'); $('[aria-invalid]', this).attr('aria-invalid', 'true'); }); }); $message.addClass('wpcf7-validation-errors'); $form.addClass('invalid'); wpcf7.triggerEvent(data.into, 'invalid', detail); break; case 'acceptance_missing': $message.addClass('wpcf7-acceptance-missing'); $form.addClass('unaccepted'); wpcf7.triggerEvent(data.into, 'unaccepted', detail); break; case 'spam': $message.addClass('wpcf7-spam-blocked'); $form.addClass('spam'); wpcf7.triggerEvent(data.into, 'spam', detail); break; case 'aborted': $message.addClass('wpcf7-aborted'); $form.addClass('aborted'); wpcf7.triggerEvent(data.into, 'aborted', detail); break; case 'mail_sent': $message.addClass('wpcf7-mail-sent-ok'); $form.addClass('sent'); wpcf7.triggerEvent(data.into, 'mailsent', detail); break; case 'mail_failed': $message.addClass('wpcf7-mail-sent-ng'); $form.addClass('failed'); wpcf7.triggerEvent(data.into, 'mailfailed', detail); break; default: var customStatusClass='custom-' + data.status.replace(/[^0-9a-z]+/i, '-'); $message.addClass('wpcf7-' + customStatusClass); $form.addClass(customStatusClass); } wpcf7.refill($form, data); wpcf7.triggerEvent(data.into, 'submit', detail); if('mail_sent'==data.status){ $form.each(function(){ this.reset(); }); wpcf7.toggleSubmit($form); } if(! wpcf7.supportHtml5.placeholder){ $form.find('[placeholder].placeheld').each(function(i, n){ $(n).val($(n).attr('placeholder')); }); } $message.html('').append(data.message).slideDown('fast'); $message.attr('role', 'alert'); $('.screen-reader-response', $form.closest('.wpcf7')).each(function(){ var $response=$(this); $response.html('').attr('role', '').append(data.message); if(data.invalidFields){ var $invalids=$(''); $.each(data.invalidFields, function(i, n){ if(n.idref){ var $li=$('
  • ').append($('').attr('href', '#' + n.idref).append(n.message)); }else{ var $li=$('
  • ').append(n.message); } $invalids.append($li); }); $response.append($invalids); } $response.attr('role', 'alert').focus(); }); }; $.ajax({ type: 'POST', url: wpcf7.apiSettings.getRoute('/contact-forms/' + wpcf7.getId($form) + '/feedback'), data: formData, dataType: 'json', processData: false, contentType: false }).done(function(data, status, xhr){ ajaxSuccess(data, status, xhr, $form); $('.ajax-loader', $form).removeClass('is-active'); }).fail(function(xhr, status, error){ var $e=$('
    ').text(error.message); $form.after($e); }); }; wpcf7.triggerEvent=function(target, name, detail){ var $target=$(target); var event=new CustomEvent('wpcf7' + name, { bubbles: true, detail: detail }); $target.get(0).dispatchEvent(event); $target.trigger('wpcf7:' + name, detail); $target.trigger(name + '.wpcf7', detail); }; wpcf7.toggleSubmit=function(form, state){ var $form=$(form); var $submit=$('input:submit', $form); if(typeof state!=='undefined'){ $submit.prop('disabled', ! state); return; } if($form.hasClass('wpcf7-acceptance-as-validation')){ return; } $submit.prop('disabled', false); $('.wpcf7-acceptance', $form).each(function(){ var $span=$(this); var $input=$('input:checkbox', $span); if(! $span.hasClass('optional')){ if($span.hasClass('invert')&&$input.is(':checked') || ! $span.hasClass('invert')&&! $input.is(':checked')){ $submit.prop('disabled', true); return false; }} }); }; wpcf7.notValidTip=function(target, message){ var $target=$(target); $('.wpcf7-not-valid-tip', $target).remove(); $('') .text(message).appendTo($target); if($target.is('.use-floating-validation-tip *')){ var fadeOut=function(target){ $(target).not(':hidden').animate({ opacity: 0 }, 'fast', function(){ $(this).css({ 'z-index': -100 }); }); }; $target.on('mouseover', '.wpcf7-not-valid-tip', function(){ fadeOut(this); }); $target.on('focus', ':input', function(){ fadeOut($('.wpcf7-not-valid-tip', $target)); }); }}; wpcf7.refill=function(form, data){ var $form=$(form); var refillCaptcha=function($form, items){ $.each(items, function(i, n){ $form.find(':input[name="' + i + '"]').val(''); $form.find('img.wpcf7-captcha-' + i).attr('src', n); var match=/([0-9]+)\.(png|gif|jpeg)$/.exec(n); $form.find('input:hidden[name="_wpcf7_captcha_challenge_' + i + '"]').attr('value', match[ 1 ]); }); }; var refillQuiz=function($form, items){ $.each(items, function(i, n){ $form.find(':input[name="' + i + '"]').val(''); $form.find(':input[name="' + i + '"]').siblings('span.wpcf7-quiz-label').text(n[ 0 ]); $form.find('input:hidden[name="_wpcf7_quiz_answer_' + i + '"]').attr('value', n[ 1 ]); }); }; if(typeof data==='undefined'){ $.ajax({ type: 'GET', url: wpcf7.apiSettings.getRoute('/contact-forms/' + wpcf7.getId($form) + '/refill'), beforeSend: function(xhr){ var nonce=$form.find(':input[name="_wpnonce"]').val(); if(nonce){ xhr.setRequestHeader('X-WP-Nonce', nonce); }}, dataType: 'json' }).done(function(data, status, xhr){ if(data.captcha){ refillCaptcha($form, data.captcha); } if(data.quiz){ refillQuiz($form, data.quiz); }}); }else{ if(data.captcha){ refillCaptcha($form, data.captcha); } if(data.quiz){ refillQuiz($form, data.quiz); }} }; wpcf7.clearResponse=function(form){ var $form=$(form); $form.removeClass('invalid spam sent failed'); $form.siblings('.screen-reader-response').html('').attr('role', ''); $('.wpcf7-not-valid-tip', $form).remove(); $('[aria-invalid]', $form).attr('aria-invalid', 'false'); $('.wpcf7-form-control', $form).removeClass('wpcf7-not-valid'); $('.wpcf7-response-output', $form) .hide().empty().removeAttr('role') .removeClass('wpcf7-mail-sent-ok wpcf7-mail-sent-ng wpcf7-validation-errors wpcf7-spam-blocked'); }; wpcf7.apiSettings.getRoute=function(path){ var url=wpcf7.apiSettings.root; url=url.replace(wpcf7.apiSettings.namespace, wpcf7.apiSettings.namespace + path); return url; };})(jQuery); (function (){ if(typeof window.CustomEvent==="function") return false; function CustomEvent(event, params){ params=params||{ bubbles: false, cancelable: false, detail: undefined }; var evt=document.createEvent('CustomEvent'); evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail); return evt; } CustomEvent.prototype=window.Event.prototype; window.CustomEvent=CustomEvent; })(); (function(t){'use strict';t(document).ready(function(){var e=o('html');t.avia_utilities=t.avia_utilities||{};if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)&&'ontouchstart' in document.documentElement){t.avia_utilities.isMobile=!0}else{t.avia_utilities.isMobile=!1};c();l();i();new t.AviaTooltip({'class':'avia-search-tooltip',data:'avia-search-tooltip',event:'click',position:'bottom',scope:'body',attach:'element',within_screen:!0});new t.AviaTooltip({'class':'avia-related-tooltip',data:'avia-related-tooltip',scope:'.related_posts, .av-share-box',attach:'element',delay:0});new t.AviaAjaxSearch({scope:'#header, .avia_search_element'});if(t.fn.avia_iso_sort)t('.grid-sort-container').avia_iso_sort();a();t.avia_utilities.avia_ajax_call()});t.avia_utilities=t.avia_utilities||{};t.avia_utilities.avia_ajax_call=function(e){if(typeof e=='undefined'){e='body'};t('a.avianolink').on('click',function(t){t.preventDefault()});t('a.aviablank').attr('target','_blank');if(t.fn.avia_activate_lightbox){t(e).avia_activate_lightbox()};if(t.fn.avia_scrollspy){if(e=='body'){t('body').avia_scrollspy({target:'.main_menu .menu li > a'})}else{t('body').avia_scrollspy('refresh')}};if(t.fn.avia_smoothscroll)t('a[href*="#"]',e).avia_smoothscroll(e);r(e);n(e);s(e);if(t.fn.avia_html5_activation&&t.fn.mediaelementplayer)t('.avia_video, .avia_audio',e).avia_html5_activation({ratio:'16:9'})};t.avia_utilities.log=function(t,e,i){if(typeof console=='undefined'){return};if(typeof e=='undefined'){e='log'};e='AVIA-'+e.toUpperCase();console.log('['+e+'] '+t);if(typeof i!='undefined')console.log(i)};function i(){var n=t(window),i=t('html').is('.html_header_sidebar')?'#main':'#header',a=t(i),s=a.parents('div:eq(0)'),r=t(i+' .container:first'),e='',o=function(){var i='',o=Math.round(r.width()),n=Math.round(a.width()),l=Math.round(s.width());i+=' #header .three.units{width:'+(o*0.25)+'px;}';i+=' #header .six.units{width:'+(o*0.50)+'px;}';i+=' #header .nine.units{width:'+(o*0.75)+'px;}';i+=' #header .twelve.units{width:'+(o)+'px;}';i+=' .av-framed-box .av-layout-tab-inner .container{width:'+(l)+'px;}';i+=' .html_header_sidebar .av-layout-tab-inner .container{width:'+(n)+'px;}';i+=' .boxed .av-layout-tab-inner .container{width:'+(n)+'px;}';i+=' .av-framed-box#top .av-submenu-container{width:'+(l)+'px;}';try{e.text(i)}catch(c){e.remove();e=t('').appendTo('head:first')}};if(t('.avia_mega_div').length>0||t('.av-layout-tab-inner').length>0||t('.av-submenu-container').length>0){e=t('').appendTo('head:first');n.on('debouncedresize',o);o()}};function a(){var e=t('.sidebar_shadow#top #main .sidebar'),i=t('.sidebar_shadow .content');if(e.height()>=i.height()){e.addClass('av-enable-shadow')}else{i.addClass('av-enable-shadow')}};function e(e,a){var i=this,s=t.proxy(i.process,i),o=t.proxy(i.refresh,i),r=t(e).is('body')?t(window):t(e),n;i.$body=t('body');i.$win=t(window);i.options=t.extend({},t.fn.avia_scrollspy.defaults,a);i.selector=(i.options.target||((n=t(e).attr('href'))&&n.replace(/.*(?=#[^\s]+$)/,''))||'');i.activation_true=!1;if(i.$body.find(i.selector+'[href*=\'#\']').length){i.$scrollElement=r.on('scroll.scroll-spy.data-api',s);i.$win.on('av-height-change',o);i.$body.on('av_resize_finished',o);i.activation_true=!0;i.checkFirst();setTimeout(function(){i.refresh();i.process()},100)}};e.prototype={constructor:e,checkFirst:function(){var t=window.location.href.split('#')[0],e=this.$body.find(this.selector+'[href=\''+t+'\']').attr('href',t+'#top')},refresh:function(){if(!this.activation_true)return;var e=this,i;this.offsets=t([]);this.targets=t([]);i=this.$body.find(this.selector).map(function(){var o=t(this),n=o.data('target')||o.attr('href'),i=this.hash,i=i.replace(/\//g,''),a=/^#\w/.test(i)&&t(i);return(a&&a.length&&[[a.position().top+(!t.isWindow(e.$scrollElement.get(0))&&e.$scrollElement.scrollTop()),n]])||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){e.offsets.push(this[0]);e.targets.push(this[1])})},process:function(){if(!this.offsets)return;if(isNaN(this.options.offset))this.options.offset=0;var i=this.$scrollElement.scrollTop()+this.options.offset,n=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,s=n-this.$scrollElement.height(),e=this.offsets,a=this.targets,o=this.activeTarget,t;if(i>=s){return o!=(t=a.last()[0])&&this.activate(t)};for(t=e.length;t--;){o!=a[t]&&i>=e[t]&&(!e[t+1]||i<=e[t+1])&&this.activate(a[t])}},activate:function(e){var i,a;this.activeTarget=e;t(this.selector).parent('.'+this.options.applyClass).removeClass(this.options.applyClass);a=this.selector+'[data-target="'+e+'"],'+this.selector+'[href="'+e+'"]';i=t(a).parent('li').addClass(this.options.applyClass);if(i.parent('.sub-menu').length){i=i.closest('li.dropdown_ul_available').addClass(this.options.applyClass)};i.trigger('activate')}};t.fn.avia_scrollspy=function(i){return this.each(function(){var o=t(this),a=o.data('scrollspy'),n=typeof i=='object'&&i;if(!a)o.data('scrollspy',(a=new e(this,n)));if(typeof i=='string')a[i]()})};t.fn.avia_scrollspy.Constructor=e;t.fn.avia_scrollspy.calc_offset=function(){var e=(parseInt(t('.html_header_sticky #main').data('scroll-offset'),10))||0,i=(t('.html_header_sticky:not(.html_top_nav_header) #header_main_alternate').outerHeight())||0,a=(t('.html_header_sticky.html_header_unstick_top_disabled #header_meta').outerHeight())||0,o=1,n=parseInt(t('html').css('margin-top'),10)||0,s=parseInt(t('.av-frame-top ').outerHeight(),10)||0;return e+i+a+o+n+s};t.fn.avia_scrollspy.defaults={offset:t.fn.avia_scrollspy.calc_offset(),applyClass:'current-menu-item'};function o(e){var i={},s=function(t){t=t.toLowerCase();var e=/(edge)\/([\w.]+)/.exec(t)||/(opr)[\/]([\w.]+)/.exec(t)||/(chrome)[ \/]([\w.]+)/.exec(t)||/(iemobile)[\/]([\w.]+)/.exec(t)||/(version)(applewebkit)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+).*(version)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+)/.exec(t)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(t)||/(msie) ([\w.]+)/.exec(t)||t.indexOf('trident')>=0&&/(rv)(?::|)([\w.]+)/.exec(t)||t.indexOf('compatible')<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(t)||[];return{browser:e[5]||e[3]||e[1]||'',version:e[2]||e[4]||'0',versionNumber:e[4]||e[2]||'0'}};var o=s(navigator.userAgent);if(o.browser){i.browser=o.browser;i[o.browser]=!0;i.version=o.version};if(i.chrome){i.webkit=!0} else if(i.webkit){i.safari=!0};if(typeof(i)!=='undefined'){var a='',n=i.version?parseInt(i.version):'';if(i.msie||i.rv||i.iemobile){a+='avia-msie'} else if(i.webkit){a+='avia-webkit'} else if(i.mozilla){a+='avia-mozilla'};if(i.version)a+=' '+a+'-'+n+' ';if(i.browser)a+=' avia-'+i.browser+' avia-'+i.browser+'-'+n+' '};if(e)t(e).addClass(a);return a};t.fn.avia_html5_activation=function(e){var i={ratio:'16:9'};var e=t.extend(i,e),a=t.avia_utilities.isMobile;this.each(function(){var e=t(this),a='#'+e.attr('id'),i=e.attr('poster');e.mediaelementplayer({defaultVideoWidth:480,defaultVideoHeight:270,videoWidth:-1,videoHeight:-1,audioWidth:400,audioHeight:30,startVolume:0.8,loop:!1,enableAutosize:!1,features:['playpause','progress','current','duration','tracks','volume'],alwaysShowControls:!1,iPadUseNativeControls:!1,iPhoneUseNativeControls:!1,AndroidUseNativeControls:!1,alwaysShowHours:!1,showTimecodeFrameCount:!1,framesPerSecond:25,enableKeyboard:!0,pauseOtherPlayers:!1,poster:i,success:function(i,a,o){t.AviaVideoAPI.players[e.attr('id').replace(/_html5/,'')]=o;setTimeout(function(){if(i.pluginType=='flash'){i.addEventListener('canplay',function(){e.trigger('av-mediajs-loaded')},!1)}else{e.trigger('av-mediajs-loaded').addClass('av-mediajs-loaded')};i.addEventListener('ended',function(){e.trigger('av-mediajs-ended')},!1)},10)},error:function(){},keyActions:[]})})};function n(e){if(t.avia_utilities.isMobile)return;if(t('body').hasClass('av-disable-avia-hover-effect')){return};var o='',a=t.avia_utilities.supports('transition');if(e=='body'){var i=t('#main a img').parents('a').not('.noLightbox, .noLightbox a, .avia-gallery-thumb a, .ls-wp-container a, .noHover, .noHover a, .av-logo-container .logo a').add('#main .avia-hover-fx')}else{var i=t('a img',e).parents('a').not('.noLightbox, .noLightbox a, .avia-gallery-thumb a, .ls-wp-container a, .noHover, .noHover a, .av-logo-container .logo a').add('.avia-hover-fx',e)};i.each(function(e){var o=t(this),r=o.find('img:first');if(r.hasClass('alignleft'))o.addClass('alignleft').css({float:'left',margin:0,padding:0});if(r.hasClass('alignright'))o.addClass('alignright').css({float:'right',margin:0,padding:0});if(r.hasClass('aligncenter'))o.addClass('aligncenter').css({float:'none','text-align':'center',margin:0,padding:0});if(r.hasClass('alignnone')){o.addClass('alignnone').css({margin:0,padding:0});if(!o.css('display')||o.css('display')=='inline'){o.css({display:'inline-block'})}};if(!o.css('position')||o.css('position')=='static'){o.css({position:'relative',overflow:'hidden'})};var l=o.attr('href'),n='overlay-type-video',h=o.data('opacity')||0.7,c=5,s=o.find('.image-overlay');if(l){if(l.match(/(jpg|gif|jpeg|png|tif)/))n='overlay-type-image';if(!l.match(/(jpg|gif|jpeg|png|\.tif|\.mov|\.swf|vimeo\.com|youtube\.com)/))n='overlay-type-extern'};if(!s.length){s=t('').appendTo(o)};o.on('mouseenter',function(e){var i=o.find('img:first'),r=i.get(0),l=i.outerHeight(),f=i.outerWidth(),d=i.position(),p=o.css('display'),s=o.find('.image-overlay');if(l>100){if(!s.length){s=t('').appendTo(o)};if(o.height()==0){o.addClass(r.className);r.className=''};if(!p||p=='inline'){o.css({display:'block'})};s.css({left:(d.left-c)+parseInt(i.css('margin-left'),10),top:d.top+parseInt(i.css('margin-top'),10)}).css({overflow:'hidden',display:'block','height':l,'width':(f+(2*c))});if(a===!1)s.stop().animate({opacity:h},400)}else{s.css({display:'none'})}}).on('mouseleave',i,function(){if(s.length){if(a===!1)s.stop().animate({opacity:0},400)}})})}(function(t){t.fn.avia_smoothscroll=function(e){if(!this.length)return;var o=t(window),p=t('#header'),f=t('.html_header_top.html_header_sticky #main').not('.page-template-template-blank-php #main'),u=t('.html_header_top.html_header_unstick_top_disabled #header_meta'),v=t('.html_header_top:not(.html_top_nav_header) #header_main_alternate'),m=t('.html_header_top.html_top_nav_header'),l=t('.html_header_top.html_header_shrinking').length,c=t('.av-frame-top'),i=0,h=t.avia_utilities.isMobile,a=t('.sticky_placeholder:first'),d=function(){if(p.css('position')=='fixed'){var e=parseInt(f.data('scroll-offset'),10)||0,a=parseInt(u.outerHeight(),10)||0,o=parseInt(v.outerHeight(),10)||0;if(e>0&&l){e=(e/2)+a+o}else{e=e+a+o};e+=parseInt(t('html').css('margin-top'),10);i=e}else{i=parseInt(t('html').css('margin-top'),10)};if(c.length){i+=c.height()};if(m.length){i=t('.html_header_sticky #header_main_alternate').height()+parseInt(t('html').css('margin-top'),10)};if(h){i=0}};if(h)l=!1;d();o.on('debouncedresize av-height-change',d);var n=window.location.hash.replace(/\//g,'');if(i>0&&n&&e=='body'&&n.charAt(1)!='!'&&n.indexOf('=')===-1){var s=t(n),r=0;if(s.length){o.on('scroll.avia_first_scroll',function(){setTimeout(function(){if(a.length&&s.offset().top>a.offset().top){r=a.outerHeight()-3};o.off('scroll.avia_first_scroll').scrollTop(s.offset().top-i-r)},10)})}};return this.each(function(){t(this).click(function(e){var n=this.hash.replace(/\//g,''),c=t(this),f=c.data();if(n!=''&&n!='#'&&n!='#prev'&&n!='#next'&&!c.is('.comment-reply-link, #cancel-comment-reply-link, .no-scroll')){var s='',p='';if('#next-section'==n){p=n;s=c.parents('.container_wrap:eq(0)').nextAll('.container_wrap:eq(0)');n='#'+s.attr('id')}else{s=t(this.hash.replace(/\//g,''))};if(s.length){var h=o.scrollTop(),d=s.offset().top,r=d-i,l=window.location.hash,l=l.replace(/\//g,''),u=window.location.href.replace(l,''),v=this,m=f.duration||1200,g=f.easing||'easeInOutQuint';if(a.length&&d>a.offset().top){r-=a.outerHeight()-3};if(u+n==v||p){if(h!=r){if(!(h==0&&r<=0)){o.trigger('avia_smooth_scroll_start');t('html:not(:animated),body:not(:animated)').animate({scrollTop:r},m,g,function(){if(window.history.replaceState)window.history.replaceState('','',n)})}};e.preventDefault()}}}})})}})(jQuery);function s(t){var e=jQuery('iframe[src*="youtube.com"]:not(.av_youtube_frame)',t),i=jQuery('iframe[src*="youtube.com"]:not(.av_youtube_frame) object, iframe[src*="youtube.com"]:not(.av_youtube_frame) embed',t).attr('wmode','opaque');e.each(function(){var e=jQuery(this),t=e.attr('src');if(t){if(t.indexOf('?')!==-1){t+='&wmode=opaque&rel=0'}else{t+='?wmode=opaque&rel=0'};e.attr('src',t)}})};function r(t){if(!t)t=document;var a=jQuery(window),e=jQuery('.avia-iframe-wrap iframe:not(.avia-slideshow iframe):not(iframe.no_resize):not(.avia-video iframe)',t),i=function(){e.each(function(){var e=jQuery(this),i=e.parent(),t=56.25;if(this.width&&this.height){t=(100/this.width)*this.height;i.css({'padding-bottom':t+'%'})}})};i()};function l(){var i=t(window),o=!1,e=t('#scroll-top-link'),a=function(){var t=i.scrollTop();if(t<500){e.removeClass('avia_pop_class')} else if(!e.is('.avia_pop_class')){e.addClass('avia_pop_class')}};i.on('scroll',function(){window.requestAnimationFrame(a)});a()};function c(){var u=t('#header'),c=t('#main .av-logo-container'),v=t('#avia-menu'),s=t('.av-burger-menu-main a'),n=t('html').eq(0),i=t('
    '),m=t('
    ').appendTo(i),g=t('
    ').appendTo(m),T=t('
    ').appendTo(i),r=!1,h={},y=t('.av-logo-container .inner-container'),x=y.find('.main_menu'),d=n.is('.html_av-submenu-display-click.html_av-submenu-clone, .html_av-submenu-display-hover.html_av-submenu-clone'),w=!1;var f=t('#avia_alternate_menu');if(f.length>0){v=f};var p=function(){if(t.avia_utilities.isMobile){m.outerHeight(window.innerHeight)}},l=function(e,a){if(!e)return;var p,r,n,c,h,f,u,i,o;e.each(function(){n=t(this);c=n.find(' > .sub-menu > li');if(c.length==0){c=n.find(' > .children > li')};h=n.find('.avia_mega_div > .sub-menu > li.menu-item');var e=n.find('>a'),p=!0;if(e.length){if(e.get(0).hash=='#'||'undefined'==typeof e.attr('href')||e.attr('href')=='#'){if(c.length>0||h.length>0){p=!1}}};r=e.clone(p).attr('style','');if('undefined'==typeof e.attr('href')){r.attr('href','#')};i=t('
  • ').append(r);var s=[];if('undefined'!=typeof n.attr('class')){s=n.attr('class').split(/\s+/);t.each(s,function(t,e){if((e.indexOf('menu-item')!=0)&&(e.indexOf('page-item')<0)&&(e.indexOf('page_item')!=0)&&(e.indexOf('dropdown_ul')<0)){i.addClass(e)};return!0})};if('undefined'!=typeof n.attr('id')&&''!=n.attr('id')){i.addClass(n.attr('id'))}else{t.each(s,function(t,e){if(e.indexOf('page-item-')>=0){i.addClass(e);return!1}})};a.append(i);if(c.length){o=t('