window.wp=window.wp||{},window.bp=window.bp||{},function(e,t){"undefined"!=typeof BP_Nouveau&&(bp.Nouveau={start:function(){this.setupGlobals(),this.prepareDocument(),this.initObjects(),this.setHeartBeat(),this.addListeners()},setupGlobals:function(){this.ajax_request=null,this.objects=t.map(BP_Nouveau.objects,function(e){return e}),this.objectNavParent=BP_Nouveau.object_nav_parent,this.heartbeat=wp.heartbeat||{},this.querystring=this.getLinkParams()},prepareDocument:function(){if(t("body").hasClass("no-js")&&t("body").removeClass("no-js").addClass("js"),BP_Nouveau.warnings&&"undefined"!=typeof console&&console.warn&&t.each(BP_Nouveau.warnings,function(e,t){console.warn(t)}),t(".buddypress_object_nav .widget-title").length){var e=t(".buddypress_object_nav .widget-title").html();t("body").find('*:contains("'+e+'")').each(function(a,s){t(s).hasClass("widget-title")||e!==t(s).html()||t(s).is("a")||t(s).remove()})}},getStorage:function(e,t){var a=sessionStorage.getItem(e);return a=a?JSON.parse(a):{},void 0!==t?a[t]||!1:a},setStorage:function(e,t,a){var s=this.getStorage(e);return void 0===a&&void 0!==s[t]?delete s[t]:s[t]=a,sessionStorage.setItem(e,JSON.stringify(s)),null!==sessionStorage.getItem(e)},getLinkParams:function(e,t){var a;if(!(a=e?-1!==e.indexOf("?")?"?"+e.split("?")[1]:"":document.location.search))return null;var s=a.replace(/(^\?)/,"").split("&").map(function(e){return e=e.split("="),this[e[0]]=e[1],this}.bind({}))[0];return t?s[t]:s},urlDecode:function(e,t){var a=t||{amp:"&",lt:"<",gt:">",quot:'"',"#039":"'"};return decodeURIComponent(e.replace(/\+/g," ")).replace(/&([^;]+);/g,function(e,t){return a[t]||""})},ajax:function(e,a){this.ajax_request&&this.ajax_request.abort();var s=t.extend({},bp.Nouveau.getStorage("bp-"+a),{nonce:BP_Nouveau.nonces[a]},e);return void 0!==BP_Nouveau.customizer_settings&&(s.customized=BP_Nouveau.customizer_settings),this.ajax_request=t.post(BP_Nouveau.ajaxurl,s,"json"),this.ajax_request},inject:function(e,a,s){t(e).length&&a&&("append"===(s=s||"reset")?t(e).append(a):"prepend"===s?t(e).prepend(a):t(e).html(a),"undefined"==typeof bp_mentions&&void 0===bp.mentions||t(".bp-suggestions").bp_mentions(bp.mentions.users))},objectRequest:function(e){var a={},s=this;if((e=t.extend({object:"",scope:null,filter:null,target:"#buddypress [data-bp-list]",search_terms:"",page:1,extras:null,caller:null,template:null,method:"reset"},e)).object&&e.target)return e.search_terms&&(e.search_terms=e.search_terms.replace(//g,">")),null!==e.scope&&this.setStorage("bp-"+e.object,"scope",e.scope),null!==e.filter&&this.setStorage("bp-"+e.object,"filter",e.filter),null!==e.extras&&this.setStorage("bp-"+e.object,"extras",e.extras),t(this.objectNavParent+" [data-bp-object]").each(function(){t(this).removeClass("selected loading")}),t(this.objectNavParent+' [data-bp-scope="'+e.scope+'"], #object-nav li.current').addClass("selected loading"),t('#buddypress [data-bp-filter="'+e.object+'"] option[value="'+e.filter+'"]').prop("selected",!0),"friends"===e.object||"friend_requests"===e.object||"group_members"===e.object?(e.template=e.object,e.object="members"):"group_requests"===e.object?(e.object="groups",e.template="group_requests"):"notifications"===e.object&&(e.object="members",e.template="member_notifications"),a=t.extend({action:e.object+"_filter"},e),this.ajax(a,e.object).done(function(a){if(!1!==a.success)if(t(s.objectNavParent+' [data-bp-scope="'+e.scope+'"]').removeClass("loading"),"reset"!==e.method)s.inject(e.target,a.data.contents,e.method),t(e.target).trigger("bp_ajax_"+e.method,t.extend(e,{response:a.data}));else if("pag-bottom"===e.caller&&t("#subnav").length){var r=t("#subnav").parent();t("html,body").animate({scrollTop:r.offset().top},"slow",function(){t(e.target).fadeOut(100,function(){s.inject(this,a.data.contents,e.method),t(this).fadeIn(100,"swing",function(){t(e.target).trigger("bp_ajax_request",t.extend(e,{response:a.data}))})})})}else t(e.target).fadeOut(100,function(){s.inject(this,a.data.contents,e.method),t(this).fadeIn(100,"swing",function(){t(e.target).trigger("bp_ajax_request",t.extend(e,{response:a.data}))})})})},initObjects:function(){var e=this,a={},s={},r="all",n="",i=null,o=null;t.each(this.objects,function(d,p){void 0!==(a=e.getStorage("bp-"+p)).scope&&(r=a.scope),void 0!==a.extras&&"notifications"!==p&&(i=a.extras),t('#buddypress [data-bp-filter="'+p+'"]').length&&("-1"!==t('#buddypress [data-bp-filter="'+p+'"]').val()&&"0"!==t('#buddypress [data-bp-filter="'+p+'"]').val()?o=t('#buddypress [data-bp-filter="'+p+'"]').val():void 0!==a.filter&&(o=a.filter,t('#buddypress [data-bp-filter="'+p+'"] option[value="'+o+'"]').prop("selected",!0))),t(this.objectNavParent+' [data-bp-object="'+p+'"]').length&&(t(this.objectNavParent+' [data-bp-object="'+p+'"]').each(function(){t(this).removeClass("selected")}),t(this.objectNavParent+' [data-bp-scope="'+p+'"], #object-nav li.current').addClass("selected")),null!==e.querystring&&(void 0!==e.querystring[p+"_search"]?n=e.querystring[p+"_search"]:void 0!==e.querystring.s&&(n=e.querystring.s),n&&(n=e.urlDecode(n),t('#buddypress [data-bp-search="'+p+'"] input[type=search]').val(n))),t('#buddypress [data-bp-list="'+p+'"]').length&&(s={object:p,scope:r,filter:o,search_terms:n,extras:i},e.objectRequest(s))})},setHeartBeat:function(){void 0!==BP_Nouveau.pulse&&this.heartbeat&&(this.heartbeat.interval(Number(BP_Nouveau.pulse)),t.fn.extend({"heartbeat-send":function(){return this.bind("heartbeat-send.buddypress")}}),t.fn.extend({"heartbeat-tick":function(){return this.bind("heartbeat-tick.buddypress")}}))},addListeners:function(){t("[data-bp-disable-input]").on("change",this.toggleDisabledInput),t(document).on("heartbeat-send.buddypress",this.heartbeatSend),t(document).on("heartbeat-tick.buddypress",this.heartbeatTick),t(this.objectNavParent+" .bp-navs").on("click","a",this,this.scopeQuery),t("#buddypress [data-bp-filter]").on("change",this,this.filterQuery),t("#buddypress [data-bp-search]").on("submit","form",this,this.searchQuery),t("#buddypress [data-bp-search] form").on("search","input[type=search]",this.resetSearch),t("#buddypress [data-bp-list], #buddypress #item-header").on("click","[data-bp-btn-action]",this,this.buttonAction),t("#buddypress [data-bp-close]").on("click",this,this.closeNotice),t("#buddypress [data-bp-list]").on("click","[data-bp-pagination] a",this,this.paginateAction)},toggleDisabledInput:function(){var e=t(this).attr("data-bp-disable-input");t(e).prop("disabled",!0)&&!t(this).hasClass("enabled")?(t(this).addClass("enabled").removeClass("disabled"),t(e).removeProp("disabled")):t(e).prop("disabled",!1)&&t(this).hasClass("enabled")&&(t(this).removeClass("enabled").addClass("disabled"),t(e).attr("disabled","disabled"))},heartbeatSend:function(e,a){t("#buddypress").trigger("bp_heartbeat_send",a)},heartbeatTick:function(e,a){t("#buddypress").trigger("bp_heartbeat_tick",a)},scopeQuery:function(e){var a,s=e.data,r=t(e.currentTarget).parent(),n="all",i=null,o="";return r.hasClass("no-ajax")||t(e.currentTarget).hasClass("no-ajax")||!r.attr("data-bp-scope")?e:(n=r.data("bp-scope"),a=r.data("bp-object"),n&&a?(e.preventDefault(),i=t("#buddypress").find('[data-bp-filter="'+a+'"]').first().val(),t('#buddypress [data-bp-search="'+a+'"] input[type=search]').length&&(o=t('#buddypress [data-bp-search="'+a+'"] input[type=search]').val()),r.hasClass("dynamic")&&r.find("a span").html(""),void s.objectRequest({object:a,scope:n,filter:i,search_terms:o,page:1})):e)},filterQuery:function(e){var a=e.data,s=t(e.target).data("bp-filter"),r="all",n=t(e.target).val(),i="";if(!s)return e;t(a.objectNavParent+" [data-bp-object].selected").length&&(r=t(a.objectNavParent+" [data-bp-object].selected").data("bp-scope")),t('#buddypress [data-bp-search="'+s+'"] input[type=search]').length&&(i=t('#buddypress [data-bp-search="'+s+'"] input[type=search]').val()),a.objectRequest({object:s,scope:r,filter:n,search_terms:i,page:1,template:null})},searchQuery:function(e){var a,s=e.data,r="all",n=null,i="";if(t(e.delegateTarget).hasClass("no-ajax")||void 0===t(e.delegateTarget).data("bp-search"))return e;e.preventDefault(),a=t(e.delegateTarget).data("bp-search"),n=t("#buddypress").find('[data-bp-filter="'+a+'"]').first().val(),i=t(e.delegateTarget).find("input[type=search]").first().val(),t(s.objectNavParent+" [data-bp-object]").length&&(r=t(s.objectNavParent+' [data-bp-object="'+a+'"].selected').data("bp-scope")),s.objectRequest({object:a,scope:r,filter:n,search_terms:i,page:1,template:null})},showSearchSubmit:function(e){t(e.delegateTarget).find("[type=submit]").addClass("bp-show"),t("[type=submit]").hasClass("bp-hide")&&t("[type=submit]").removeClass("bp-hide")},resetSearch:function(e){t(e.target).val()?t(e.delegateTarget).find("[type=submit]").show():t(e.delegateTarget).submit()},buttonAction:function(e){var a=e.data,s=t(e.currentTarget),r=s.data("bp-btn-action"),n=s.data("bp-nonce"),i=s.closest("[data-bp-item-id]"),o=i.data("bp-item-id"),d=s.closest(".list-wrap"),p=i.data("bp-item-component"),c="";if(!r||!o||!p)return e;if(e.preventDefault(),void 0!==BP_Nouveau[r+"_confirm"]&&!1===window.confirm(BP_Nouveau[r+"_confirm"])||s.hasClass("pending"))return!1;c=n?(c=n.split("?_wpnonce="))[1]:a.getLinkParams(s.prop("href"),"_wpnonce");var l={is_friend:"remove_friend",not_friends:"add_friend",pending:"withdraw_friendship",accept_friendship:"accept_friendship",reject_friendship:"reject_friendship"};"members"===p&&void 0!==l[r]&&(r=l[r],p="friends"),s.addClass("pending loading"),a.ajax({action:p+"_"+r,item_id:o,_wpnonce:c},p).done(function(e){if(!1===e.success)d.prepend(e.data.feedback),s.removeClass("pending loading"),i.find(".bp-feedback").fadeOut(6e3);else{if("groups"===p&&void 0!==e.data.is_group&&e.data.is_group)return window.location.reload();if(void 0!==e.data.is_user&&e.data.is_user)return s.parent().html(e.data.feedback),void i.fadeOut(1500);if(t(a.objectNavParent+' [data-bp-scope="personal"]').length){var n=Number(t(a.objectNavParent+' [data-bp-scope="personal"] span').html())||0;-1!==t.inArray(r,["leave_group","remove_friend"])?n-=1:-1!==t.inArray(r,["join_group"])&&(n+=1),n<0&&(n=0),t(a.objectNavParent+' [data-bp-scope="personal"] span').html(n)}s.parent().replaceWith(e.data.contents)}})},closeNotice:function(e){var a=t(e.currentTarget);e.preventDefault(),"clear"===a.data("bp-close")&&(void 0!==t.cookie("bp-message")&&t.removeCookie("bp-message"),void 0!==t.cookie("bp-message-type")&&t.removeCookie("bp-message-type")),a.closest(".bp-feedback").hasClass("bp-sitewide-notice")&&bp.Nouveau.ajax({action:"messages_dismiss_sitewide_notice"},"messages"),a.closest(".bp-feedback").remove()},paginateAction:function(e){var a,s,r,n=e.data,i=t(e.currentTarget),o=null,d=null,p=null,c=null;if(null===(a=i.closest("[data-bp-pagination]").data("bp-pagination")||null))return e;e.preventDefault(),null!==(s=t(e.delegateTarget).data("bp-list")||null)&&(void 0!==(r=n.getStorage("bp-"+s)).scope&&(o=r.scope),void 0!==r.filter&&(d=r.filter),void 0!==r.extras&&(c=r.extras)),t('#buddypress [data-bp-search="'+s+'"] input[type=search]').length&&(p=t('#buddypress [data-bp-search="'+s+'"] input[type=search]').val());var l={object:s,scope:o,filter:d,search_terms:p,extras:c,page:n.getLinkParams(i.prop("href"),a)||1};n.objectRequest(l)}},bp.Nouveau.start())}(bp,jQuery); (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(e){"function"==typeof define&&define.amd?define(["jquery"],e):e(jQuery)}(function(a){var e,t,n,i;function r(e,t){var n,i,r,o=e.nodeName.toLowerCase();return"area"===o?(i=(n=e.parentNode).name,!(!e.href||!i||"map"!==n.nodeName.toLowerCase())&&(!!(r=a("img[usemap='#"+i+"']")[0])&&s(r))):(/^(input|select|textarea|button|object)$/.test(o)?!e.disabled:"a"===o&&e.href||t)&&s(e)}function s(e){return a.expr.filters.visible(e)&&!a(e).parents().addBack().filter(function(){return"hidden"===a.css(this,"visibility")}).length}a.ui=a.ui||{},a.extend(a.ui,{version:"1.11.4",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),a.fn.extend({scrollParent:function(e){var t=this.css("position"),n="absolute"===t,i=e?/(auto|scroll|hidden)/:/(auto|scroll)/,r=this.parents().filter(function(){var e=a(this);return(!n||"static"!==e.css("position"))&&i.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==t&&r.length?r:a(this[0].ownerDocument||document)},uniqueId:(e=0,function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++e)})}),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&a(this).removeAttr("id")})}}),a.extend(a.expr[":"],{data:a.expr.createPseudo?a.expr.createPseudo(function(t){return function(e){return!!a.data(e,t)}}):function(e,t,n){return!!a.data(e,n[3])},focusable:function(e){return r(e,!isNaN(a.attr(e,"tabindex")))},tabbable:function(e){var t=a.attr(e,"tabindex"),n=isNaN(t);return(n||0<=t)&&r(e,!n)}}),a("").outerWidth(1).jquery||a.each(["Width","Height"],function(e,n){var r="Width"===n?["Left","Right"]:["Top","Bottom"],i=n.toLowerCase(),o={innerWidth:a.fn.innerWidth,innerHeight:a.fn.innerHeight,outerWidth:a.fn.outerWidth,outerHeight:a.fn.outerHeight};function s(e,t,n,i){return a.each(r,function(){t-=parseFloat(a.css(e,"padding"+this))||0,n&&(t-=parseFloat(a.css(e,"border"+this+"Width"))||0),i&&(t-=parseFloat(a.css(e,"margin"+this))||0)}),t}a.fn["inner"+n]=function(e){return void 0===e?o["inner"+n].call(this):this.each(function(){a(this).css(i,s(this,e)+"px")})},a.fn["outer"+n]=function(e,t){return"number"!=typeof e?o["outer"+n].call(this,e):this.each(function(){a(this).css(i,s(this,e,!0,t)+"px")})}}),a.fn.addBack||(a.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),a("").data("a-b","a").removeData("a-b").data("a-b")&&(a.fn.removeData=(t=a.fn.removeData,function(e){return arguments.length?t.call(this,a.camelCase(e)):t.call(this)})),a.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),a.fn.extend({focus:(i=a.fn.focus,function(t,n){return"number"==typeof t?this.each(function(){var e=this;setTimeout(function(){a(e).focus(),n&&n.call(e)},t)}):i.apply(this,arguments)}),disableSelection:(n="onselectstart"in document.createElement("div")?"selectstart":"mousedown",function(){return this.bind(n+".ui-disableSelection",function(e){e.preventDefault()})}),enableSelection:function(){return this.unbind(".ui-disableSelection")},zIndex:function(e){if(void 0!==e)return this.css("zIndex",e);if(this.length)for(var t,n,i=a(this[0]);i.length&&i[0]!==document;){if(("absolute"===(t=i.css("position"))||"relative"===t||"fixed"===t)&&(n=parseInt(i.css("zIndex"),10),!isNaN(n)&&0!==n))return n;i=i.parent()}return 0}}),a.ui.plugin={add:function(e,t,n){var i,r=a.ui[e].prototype;for(i in n)r.plugins[i]=r.plugins[i]||[],r.plugins[i].push([t,n[i]])},call:function(e,t,n,i){var r,o=e.plugins[t];if(o&&(i||e.element[0].parentNode&&11!==e.element[0].parentNode.nodeType))for(r=0;r"))}function a(e){var t="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.delegate(t,"mouseout",function(){b(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&b(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&b(this).removeClass("ui-datepicker-next-hover")}).delegate(t,"mouseover",n)}function n(){b.datepicker._isDisabledDatepicker(r.inline?r.dpDiv.parent()[0]:r.input[0])||(b(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),b(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&b(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&b(this).addClass("ui-datepicker-next-hover"))}function h(e,t){for(var a in b.extend(e,t),t)null==t[a]&&(e[a]=t[a]);return e}return b.extend(b.ui,{datepicker:{version:"1.11.4"}}),b.extend(e.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(e){return h(this._defaults,e||{}),this},_attachDatepicker:function(e,t){var a,i,s;i="div"===(a=e.nodeName.toLowerCase())||"span"===a,e.id||(this.uuid+=1,e.id="dp"+this.uuid),(s=this._newInst(b(e),i)).settings=b.extend({},t||{}),"input"===a?this._connectDatepicker(e,s):i&&this._inlineDatepicker(e,s)},_newInst:function(e,t){return{id:e[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1"),input:e,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:t,dpDiv:t?a(b("
    ")):this.dpDiv}},_connectDatepicker:function(e,t){var a=b(e);t.append=b([]),t.trigger=b([]),a.hasClass(this.markerClassName)||(this._attachments(a,t),a.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).keyup(this._doKeyUp),this._autoSize(t),b.data(e,"datepicker",t),t.settings.disabled&&this._disableDatepicker(e))},_attachments:function(e,t){var a,i,s,r=this._get(t,"appendText"),n=this._get(t,"isRTL");t.append&&t.append.remove(),r&&(t.append=b(""+r+""),e[n?"before":"after"](t.append)),e.unbind("focus",this._showDatepicker),t.trigger&&t.trigger.remove(),"focus"!==(a=this._get(t,"showOn"))&&"both"!==a||e.focus(this._showDatepicker),"button"!==a&&"both"!==a||(i=this._get(t,"buttonText"),s=this._get(t,"buttonImage"),t.trigger=b(this._get(t,"buttonImageOnly")?b("").addClass(this._triggerClass).attr({src:s,alt:i,title:i}):b("").addClass(this._triggerClass).html(s?b("").attr({src:s,alt:i,title:i}):i)),e[n?"before":"after"](t.trigger),t.trigger.click(function(){return b.datepicker._datepickerShowing&&b.datepicker._lastInput===e[0]?b.datepicker._hideDatepicker():(b.datepicker._datepickerShowing&&b.datepicker._lastInput!==e[0]&&b.datepicker._hideDatepicker(),b.datepicker._showDatepicker(e[0])),!1}))},_autoSize:function(e){if(this._get(e,"autoSize")&&!e.inline){var t,a,i,s,r=new Date(2009,11,20),n=this._get(e,"dateFormat");n.match(/[DM]/)&&(t=function(e){for(s=i=a=0;sa&&(a=e[s].length,i=s);return i},r.setMonth(t(this._get(e,n.match(/MM/)?"monthNames":"monthNamesShort"))),r.setDate(t(this._get(e,n.match(/DD/)?"dayNames":"dayNamesShort"))+20-r.getDay())),e.input.attr("size",this._formatDate(e,r).length)}},_inlineDatepicker:function(e,t){var a=b(e);a.hasClass(this.markerClassName)||(a.addClass(this.markerClassName).append(t.dpDiv),b.data(e,"datepicker",t),this._setDate(t,this._getDefaultDate(t),!0),this._updateDatepicker(t),this._updateAlternate(t),t.settings.disabled&&this._disableDatepicker(e),t.dpDiv.css("display","block"))},_dialogDatepicker:function(e,t,a,i,s){var r,n,d,c,o,l=this._dialogInst;return l||(this.uuid+=1,r="dp"+this.uuid,this._dialogInput=b(""),this._dialogInput.keydown(this._doKeyDown),b("body").append(this._dialogInput),(l=this._dialogInst=this._newInst(this._dialogInput,!1)).settings={},b.data(this._dialogInput[0],"datepicker",l)),h(l.settings,i||{}),t=t&&t.constructor===Date?this._formatDate(l,t):t,this._dialogInput.val(t),this._pos=s?s.length?s:[s.pageX,s.pageY]:null,this._pos||(n=document.documentElement.clientWidth,d=document.documentElement.clientHeight,c=document.documentElement.scrollLeft||document.body.scrollLeft,o=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[n/2-100+c,d/2-150+o]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),l.settings.onSelect=a,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),b.blockUI&&b.blockUI(this.dpDiv),b.data(this._dialogInput[0],"datepicker",l),this},_destroyDatepicker:function(e){var t,a=b(e),i=b.data(e,"datepicker");a.hasClass(this.markerClassName)&&(t=e.nodeName.toLowerCase(),b.removeData(e,"datepicker"),"input"===t?(i.append.remove(),i.trigger.remove(),a.removeClass(this.markerClassName).unbind("focus",this._showDatepicker).unbind("keydown",this._doKeyDown).unbind("keypress",this._doKeyPress).unbind("keyup",this._doKeyUp)):"div"!==t&&"span"!==t||a.removeClass(this.markerClassName).empty(),r===i&&(r=null))},_enableDatepicker:function(t){var e,a,i=b(t),s=b.data(t,"datepicker");i.hasClass(this.markerClassName)&&("input"===(e=t.nodeName.toLowerCase())?(t.disabled=!1,s.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):"div"!==e&&"span"!==e||((a=i.children("."+this._inlineClass)).children().removeClass("ui-state-disabled"),a.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=b.map(this._disabledInputs,function(e){return e===t?null:e}))},_disableDatepicker:function(t){var e,a,i=b(t),s=b.data(t,"datepicker");i.hasClass(this.markerClassName)&&("input"===(e=t.nodeName.toLowerCase())?(t.disabled=!0,s.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):"div"!==e&&"span"!==e||((a=i.children("."+this._inlineClass)).children().addClass("ui-state-disabled"),a.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=b.map(this._disabledInputs,function(e){return e===t?null:e}),this._disabledInputs[this._disabledInputs.length]=t)},_isDisabledDatepicker:function(e){if(!e)return!1;for(var t=0;td&&ic&&st;)--G<0&&(G=11,ee--);for(e.drawMonth=G,e.drawYear=ee,a=this._get(e,"prevText"),a=B?this.formatDate(a,this._daylightSavingAdjust(new Date(ee,G-q,1)),this._getFormatConfig(e)):a,i=this._canAdjustMonth(e,-1,ee,G)?"
    "+a+"":z?"":""+a+"",s=this._get(e,"nextText"),s=B?this.formatDate(s,this._daylightSavingAdjust(new Date(ee,G+q,1)),this._getFormatConfig(e)):s,r=this._canAdjustMonth(e,1,ee,G)?""+s+"":z?"":""+s+"",n=this._get(e,"currentText"),d=this._get(e,"gotoCurrent")&&e.currentDay?X:H,n=B?this.formatDate(n,d,this._getFormatConfig(e)):n,c=e.inline?"":"",o=U?"
    "+(P?c:"")+(this._isInRange(e,d)?"":"")+(P?"":c)+"
    ":"",l=parseInt(this._get(e,"firstDay"),10),l=isNaN(l)?0:l,h=this._get(e,"showWeek"),u=this._get(e,"dayNames"),p=this._get(e,"dayNamesMin"),g=this._get(e,"monthNames"),_=this._get(e,"monthNamesShort"),f=this._get(e,"beforeShowDay"),k=this._get(e,"showOtherMonths"),D=this._get(e,"selectOtherMonths"),m=this._getDefaultDate(e),y="",M=0;M"+(/all|left/.test(I)&&0===M?P?r:i:"")+(/all|right/.test(I)&&0===M?P?i:r:"")+this._generateMonthYearHeader(e,G,ee,Z,$,0",Y=h?"":"",v=0;v<7;v++)Y+="";for(x+=Y+"",N=this._getDaysInMonth(ee,G),ee===e.selectedYear&&G===e.selectedMonth&&(e.selectedDay=Math.min(e.selectedDay,N)),F=(this._getFirstDayOfMonth(ee,G)-l+7)%7,T=Math.ceil((F+N)/7),A=Q&&this.maxRows>T?this.maxRows:T,this.maxRows=A,K=this._daylightSavingAdjust(new Date(ee,G,1-F)),j=0;j",O=h?"":"",v=0;v<7;v++)R=f?f.apply(e.input?e.input[0]:null,[K]):[!0,""],W=(L=K.getMonth()!==G)&&!D||!R[0]||Z&&K"+(L&&!k?" ":W?""+K.getDate()+"":""+K.getDate()+"")+"",K.setDate(K.getDate()+1),K=this._daylightSavingAdjust(K);x+=O+""}11<++G&&(G=0,ee++),b+=x+="
    "+this._get(e,"weekHeader")+""+p[S]+"
    "+this._get(e,"calculateWeek")(K)+"
    "+(Q?""+(0":""):"")}y+=b}return y+=o,e._keyEvent=!1,y},_generateMonthYearHeader:function(e,t,a,i,s,r,n,d){var c,o,l,h,u,p,g,_,f=this._get(e,"changeMonth"),k=this._get(e,"changeYear"),D=this._get(e,"showMonthAfterYear"),m="
    ",y="";if(r||!f)y+=""+n[t]+"";else{for(c=i&&i.getFullYear()===a,o=s&&s.getFullYear()===a,y+=""}if(D||(m+=y+(!r&&f&&k?"":" ")),!e.yearshtml)if(e.yearshtml="",r||!k)m+=""+a+"";else{for(h=this._get(e,"yearRange").split(":"),u=(new Date).getFullYear(),g=(p=function(e){var t=e.match(/c[+\-].*/)?a+parseInt(e.substring(1),10):e.match(/[+\-].*/)?u+parseInt(e,10):parseInt(e,10);return isNaN(t)?u:t})(h[0]),_=Math.max(g,p(h[1]||"")),g=i?Math.max(g,i.getFullYear()):g,_=s?Math.min(_,s.getFullYear()):_,e.yearshtml+="",m+=e.yearshtml,e.yearshtml=null}return m+=this._get(e,"yearSuffix"),D&&(m+=(!r&&f&&k?"":" ")+y),m+="
    "},_adjustInstDate:function(e,t,a){var i=e.drawYear+("Y"===a?t:0),s=e.drawMonth+("M"===a?t:0),r=Math.min(e.selectedDay,this._getDaysInMonth(i,s))+("D"===a?t:0),n=this._restrictMinMax(e,this._daylightSavingAdjust(new Date(i,s,r)));e.selectedDay=n.getDate(),e.drawMonth=e.selectedMonth=n.getMonth(),e.drawYear=e.selectedYear=n.getFullYear(),"M"!==a&&"Y"!==a||this._notifyChange(e)},_restrictMinMax:function(e,t){var a=this._getMinMaxDate(e,"min"),i=this._getMinMaxDate(e,"max"),s=a&&t=s.getTime())&&(!r||t.getTime()<=r.getTime())&&(!n||t.getFullYear()>=n)&&(!d||t.getFullYear()<=d)},_getFormatConfig:function(e){var t=this._get(e,"shortYearCutoff");return{shortYearCutoff:t="string"!=typeof t?t:(new Date).getFullYear()%100+parseInt(t,10),dayNamesShort:this._get(e,"dayNamesShort"),dayNames:this._get(e,"dayNames"),monthNamesShort:this._get(e,"monthNamesShort"),monthNames:this._get(e,"monthNames")}},_formatDate:function(e,t,a,i){t||(e.currentDay=e.selectedDay,e.currentMonth=e.selectedMonth,e.currentYear=e.selectedYear);var s=t?"object"==typeof t?t:this._daylightSavingAdjust(new Date(i,a,t)):this._daylightSavingAdjust(new Date(e.currentYear,e.currentMonth,e.currentDay));return this.formatDate(this._get(e,"dateFormat"),s,this._getFormatConfig(e))}}),b.fn.datepicker=function(e){if(!this.length)return this;b.datepicker.initialized||(b(document).mousedown(b.datepicker._checkExternalClick),b.datepicker.initialized=!0),0===b("#"+b.datepicker._mainDivId).length&&b("body").append(b.datepicker.dpDiv);var t=Array.prototype.slice.call(arguments,1);return"string"!=typeof e||"isDisabled"!==e&&"getDate"!==e&&"widget"!==e?"option"===e&&2===arguments.length&&"string"==typeof arguments[1]?b.datepicker["_"+e+"Datepicker"].apply(b.datepicker,[this[0]].concat(t)):this.each(function(){"string"==typeof e?b.datepicker["_"+e+"Datepicker"].apply(b.datepicker,[this].concat(t)):b.datepicker._attachDatepicker(this,e)}):b.datepicker["_"+e+"Datepicker"].apply(b.datepicker,[this[0]].concat(t))},b.datepicker=new e,b.datepicker.initialized=!1,b.datepicker.uuid=(new Date).getTime(),b.datepicker.version="1.11.4",b.datepicker}); jQuery(document).ready(function(){ if(typeof user_action=='undefined'&&(jQuery('[class^="userpro"]').length > 0||jQuery('[class^="popup-"]').length)){ var up_link=document.createElement('link'); up_link.id='userpro_min'; up_link.rel='stylesheet'; up_link.type='text/css'; up_link.href=up_values.up_url+'css/userpro.min.css'; up_link.media='all'; document.getElementsByTagName("head")[0].appendChild(up_link); jQuery.getScript(up_values.up_url+"scripts/scripts.min.js"); }}); (function(){ 'use strict'; var items=document.querySelectorAll(".timeline li"); function isElementInViewport(el){ var rect=el.getBoundingClientRect(); var element=jQuery('#timeline'); return ( rect.top >=0 && rect.left >=0 && rect.bottom <=(window.innerHeight||document.documentElement.clientHeight) && rect.right <=(window.innerWidth||document.documentElement.clientWidth) ); } function callbackFunc(){ for (var i=0; i < items.length; i++){ if(isElementInViewport(items[i])){ items[i].classList.add("in-view"); }} } window.addEventListener("load", callbackFunc); window.addEventListener("scroll", callbackFunc); jQuery('#timeline').on('load',function(){ callbackFunc(); }); jQuery('#timeline').on('scroll',function(){ callbackFunc(); }); })(); !function(){"use strict";function e(e){function t(t,n){var s,h,k=t==window,y=n&&n.message!==undefined?n.message:undefined;if(!(n=e.extend({},e.blockUI.defaults,n||{})).ignoreIfBlocked||!e(t).data("blockUI.isBlocked")){if(n.overlayCSS=e.extend({},e.blockUI.defaults.overlayCSS,n.overlayCSS||{}),s=e.extend({},e.blockUI.defaults.css,n.css||{}),n.onOverlayClick&&(n.overlayCSS.cursor="pointer"),h=e.extend({},e.blockUI.defaults.themedCSS,n.themedCSS||{}),y=y===undefined?n.message:y,k&&p&&o(window,{fadeOut:0}),y&&"string"!=typeof y&&(y.parentNode||y.jquery)){var m=y.jquery?y[0]:y,g={};e(t).data("blockUI.history",g),g.el=m,g.parent=m.parentNode,g.display=m.style.display,g.position=m.style.position,g.parent&&g.parent.removeChild(m)}e(t).data("blockUI.onUnblock",n.onUnblock);var v,I,w,U,x=n.baseZ;v=e(r||n.forceIframe?'':''),I=e(n.theme?'':''),n.theme&&k?(U='"):n.theme?(U='"):U=k?'':'',w=e(U),y&&(n.theme?(w.css(h),w.addClass("ui-widget-content")):w.css(s)),n.theme||I.css(n.overlayCSS),I.css("position",k?"fixed":"absolute"),(r||n.forceIframe)&&v.css("opacity",0);var C=[v,I,w],S=e(k?"body":t);e.each(C,function(){this.appendTo(S)}),n.theme&&n.draggable&&e.fn.draggable&&w.draggable({handle:".ui-dialog-titlebar",cancel:"li"});var O=f&&(!e.support.boxModel||e("object,embed",k?null:t).length>0);if(u||O){if(k&&n.allowBodyStretch&&e.support.boxModel&&e("html,body").css("height","100%"),(u||!e.support.boxModel)&&!k)var E=a(t,"borderTopWidth"),T=a(t,"borderLeftWidth"),M=E?"(0 - "+E+")":0,B=T?"(0 - "+T+")":0;e.each(C,function(e,t){var o=t[0].style;if(o.position="absolute",e<2)k?o.setExpression("height","Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.support.boxModel?0:"+n.quirksmodeOffsetHack+') + "px"'):o.setExpression("height",'this.parentNode.offsetHeight + "px"'),k?o.setExpression("width",'jQuery.support.boxModel&&document.documentElement.clientWidth||document.body.clientWidth + "px"'):o.setExpression("width",'this.parentNode.offsetWidth + "px"'),B&&o.setExpression("left",B),M&&o.setExpression("top",M);else if(n.centerY)k&&o.setExpression("top",'(document.documentElement.clientHeight||document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah=document.documentElement.scrollTop ? document.documentElement.scrollTop:document.body.scrollTop) + "px"'),o.marginTop=0;else if(!n.centerY&&k){var i="((document.documentElement.scrollTop ? document.documentElement.scrollTop:document.body.scrollTop) + "+(n.css&&n.css.top?parseInt(n.css.top,10):0)+') + "px"';o.setExpression("top",i)}})}if(y&&(n.theme?w.find(".ui-widget-content").append(y):w.append(y),(y.jquery||y.nodeType)&&e(y).show()),(r||n.forceIframe)&&n.showOverlay&&v.show(),n.fadeIn){var j=n.onBlock?n.onBlock:c,H=n.showOverlay&&!y?j:c,z=y?j:c;n.showOverlay&&I._fadeIn(n.fadeIn,H),y&&w._fadeIn(n.fadeIn,z)}else n.showOverlay&&I.show(),y&&w.show(),n.onBlock&&n.onBlock.bind(w)();if(i(1,t,n),k?(p=w[0],b=e(n.focusableElements,p),n.focusInput&&setTimeout(l,20)):d(w[0],n.centerX,n.centerY),n.timeout){var W=setTimeout(function(){k?e.unblockUI(n):e(t).unblock(n)},n.timeout);e(t).data("blockUI.timeout",W)}}}function o(t,o){var s,l=t==window,d=e(t),a=d.data("blockUI.history"),c=d.data("blockUI.timeout");c&&(clearTimeout(c),d.removeData("blockUI.timeout")),o=e.extend({},e.blockUI.defaults,o||{}),i(0,t,o),null===o.onUnblock&&(o.onUnblock=d.data("blockUI.onUnblock"),d.removeData("blockUI.onUnblock"));var r;r=l?e(document.body).children().filter(".blockUI").add("body > .blockUI"):d.find(">.blockUI"),o.cursorReset&&(r.length>1&&(r[1].style.cursor=o.cursorReset),r.length>2&&(r[2].style.cursor=o.cursorReset)),l&&(p=b=null),o.fadeOut?(s=r.length,r.stop().fadeOut(o.fadeOut,function(){0==--s&&n(r,a,o,t)})):n(r,a,o,t)}function n(t,o,n,i){var s=e(i);if(!s.data("blockUI.isBlocked")){t.each(function(e,t){this.parentNode&&this.parentNode.removeChild(this)}),o&&o.el&&(o.el.style.display=o.display,o.el.style.position=o.position,o.el.style.cursor="default",o.parent&&o.parent.appendChild(o.el),s.removeData("blockUI.history")),s.data("blockUI.static")&&s.css("position","static"),"function"==typeof n.onUnblock&&n.onUnblock(i,n);var l=e(document.body),d=l.width(),a=l[0].style.width;l.width(d-1).width(d),l[0].style.width=a}}function i(t,o,n){var i=o==window,l=e(o);if((t||(!i||p)&&(i||l.data("blockUI.isBlocked")))&&(l.data("blockUI.isBlocked",t),i&&n.bindEvents&&(!t||n.showOverlay))){var d="mousedown mouseup keydown keypress keyup touchstart touchend touchmove";t?e(document).bind(d,n,s):e(document).unbind(d,s)}}function s(t){if("keydown"===t.type&&t.keyCode&&9==t.keyCode&&p&&t.data.constrainTabKey){var o=b,n=!t.shiftKey&&t.target===o[o.length-1],i=t.shiftKey&&t.target===o[0];if(n||i)return setTimeout(function(){l(i)},10),!1}var s=t.data,d=e(t.target);return d.hasClass("blockOverlay")&&s.onOverlayClick&&s.onOverlayClick(t),d.parents("div."+s.blockMsgClass).length>0||0===d.parents().children().filter("div.blockUI").length}function l(e){if(b){var t=b[!0===e?b.length-1:0];t&&t.focus()}}function d(e,t,o){var n=e.parentNode,i=e.style,s=(n.offsetWidth-e.offsetWidth)/2-a(n,"borderLeftWidth"),l=(n.offsetHeight-e.offsetHeight)/2-a(n,"borderTopWidth");t&&(i.left=s>0?s+"px":"0"),o&&(i.top=l>0?l+"px":"0")}function a(t,o){return parseInt(e.css(t,o),10)||0}e.fn._fadeIn=e.fn.fadeIn;var c=e.noop||function(){},r=/MSIE/.test(navigator.userAgent),u=/MSIE 6.0/.test(navigator.userAgent)&&!/MSIE 8.0/.test(navigator.userAgent),f=(document.documentMode,e.isFunction(document.createElement("div").style.setExpression));e.blockUI=function(e){t(window,e)},e.unblockUI=function(e){o(window,e)},e.growlUI=function(t,o,n,i){var s=e('
    ');t&&s.append("

    "+t+"

    "),o&&s.append("

    "+o+"

    "),n===undefined&&(n=3e3);var l=function(t){t=t||{},e.blockUI({message:s,fadeIn:"undefined"!=typeof t.fadeIn?t.fadeIn:700,fadeOut:"undefined"!=typeof t.fadeOut?t.fadeOut:1e3,timeout:"undefined"!=typeof t.timeout?t.timeout:n,centerY:!1,showOverlay:!1,onUnblock:i,css:e.blockUI.defaults.growlCSS})};l();s.css("opacity");s.mouseover(function(){l({fadeIn:0,timeout:3e4});var t=e(".blockMsg");t.stop(),t.fadeTo(300,1)}).mouseout(function(){e(".blockMsg").fadeOut(1e3)})},e.fn.block=function(o){if(this[0]===window)return e.blockUI(o),this;var n=e.extend({},e.blockUI.defaults,o||{});return this.each(function(){var t=e(this);n.ignoreIfBlocked&&t.data("blockUI.isBlocked")||t.unblock({fadeOut:0})}),this.each(function(){"static"==e.css(this,"position")&&(this.style.position="relative",e(this).data("blockUI.static",!0)),this.style.zoom=1,t(this,o)})},e.fn.unblock=function(t){return this[0]===window?(e.unblockUI(t),this):this.each(function(){o(this,t)})},e.blockUI.version=2.7,e.blockUI.defaults={message:"

    Please wait...

    ",title:null,draggable:!0,theme:!1,css:{padding:0,margin:0,width:"30%",top:"40%",left:"35%",textAlign:"center",color:"#000",border:"3px solid #aaa",backgroundColor:"#fff",cursor:"wait"},themedCSS:{width:"30%",top:"40%",left:"35%"},overlayCSS:{backgroundColor:"#000",opacity:.6,cursor:"wait"},cursorReset:"default",growlCSS:{width:"350px",top:"10px",left:"",right:"10px",border:"none",padding:"5px",opacity:.6,cursor:"default",color:"#fff",backgroundColor:"#000","-webkit-border-radius":"10px","-moz-border-radius":"10px","border-radius":"10px"},iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank",forceIframe:!1,baseZ:1e3,centerX:!0,centerY:!0,allowBodyStretch:!0,bindEvents:!0,constrainTabKey:!0,fadeIn:200,fadeOut:400,timeout:0,showOverlay:!0,focusInput:!0,focusableElements:":input:enabled:visible",onBlock:null,onUnblock:null,onOverlayClick:null,quirksmodeOffsetHack:4,blockMsgClass:"blockMsg",ignoreIfBlocked:!1};var p=null,b=[]}"function"==typeof define&&define.amd&&define.amd.jQuery?define(["jquery"],e):e(jQuery)}(); jQuery(function(o){if("undefined"==typeof wc_add_to_cart_params)return!1;function t(){this.requests=[],this.addRequest=this.addRequest.bind(this),this.run=this.run.bind(this),o(document.body).on("click",".add_to_cart_button",{addToCartHandler:this},this.onAddToCart).on("click",".remove_from_cart_button",{addToCartHandler:this},this.onRemoveFromCart).on("added_to_cart",this.updateButton).on("added_to_cart removed_from_cart",{addToCartHandler:this},this.updateFragments)}t.prototype.addRequest=function(t){this.requests.push(t),1===this.requests.length&&this.run()},t.prototype.run=function(){var t=this,a=t.requests[0].complete;t.requests[0].complete=function(){"function"==typeof a&&a(),t.requests.shift(),0'+wc_add_to_cart_params.i18n_view_cart+""),o(document.body).trigger("wc_cart_button_updated",[e]))},t.prototype.updateFragments=function(t,a){a&&(o.each(a,function(t){o(t).addClass("updating").fadeTo("400","0.6").block({message:null,overlayCSS:{opacity:.6}})}),o.each(a,function(t,a){o(t).replaceWith(a),o(t).stop(!0).css("opacity","1").unblock()}),o(document.body).trigger("wc_fragments_loaded"))},new t}); !function(e){var n=!1;if("function"==typeof define&&define.amd&&(define(e),n=!0),"object"==typeof exports&&(module.exports=e(),n=!0),!n){var o=window.Cookies,t=window.Cookies=e();t.noConflict=function(){return window.Cookies=o,t}}}(function(){function e(){for(var e=0,n={};e1){if("number"==typeof(i=e({path:"/"},t.defaults,i)).expires){var a=new Date;a.setMilliseconds(a.getMilliseconds()+864e5*i.expires),i.expires=a}i.expires=i.expires?i.expires.toUTCString():"";try{c=JSON.stringify(r),/^[\{\[]/.test(c)&&(r=c)}catch(m){}r=o.write?o.write(r,n):encodeURIComponent(String(r)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),n=(n=(n=encodeURIComponent(String(n))).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent)).replace(/[\(\)]/g,escape);var f="";for(var s in i)i[s]&&(f+="; "+s,!0!==i[s]&&(f+="="+i[s]));return document.cookie=n+"="+r+f}n||(c={});for(var p=document.cookie?document.cookie.split("; "):[],d=/(%[0-9A-Z]{2})+/g,u=0;u'),i(".password-input").append(''),i(".show-password-input").click(function(){i(this).toggleClass("display-password"),i(this).hasClass("display-password")?i(this).siblings(['input[name="password"]','input[type="password"]']).prop("type","text"):i(this).siblings('input[name="password"]').prop("type","password")})}); jQuery(function(r){if("undefined"==typeof wc_cart_fragments_params)return!1;var t=!0,o=wc_cart_fragments_params.cart_hash_key;try{t="sessionStorage"in window&&null!==window.sessionStorage,window.sessionStorage.setItem("wc","test"),window.sessionStorage.removeItem("wc"),window.localStorage.setItem("wc","test"),window.localStorage.removeItem("wc")}catch(f){t=!1}function a(){t&&sessionStorage.setItem("wc_cart_created",(new Date).getTime())}function s(e){t&&(localStorage.setItem(o,e),sessionStorage.setItem(o,e))}var e={url:wc_cart_fragments_params.wc_ajax_url.toString().replace("%%endpoint%%","get_refreshed_fragments"),type:"POST",data:{time:(new Date).getTime()},timeout:wc_cart_fragments_params.request_timeout,success:function(e){e&&e.fragments&&(r.each(e.fragments,function(e,t){r(e).replaceWith(t)}),t&&(sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(e.fragments)),s(e.cart_hash),e.cart_hash&&a()),r(document.body).trigger("wc_fragments_refreshed"))},error:function(){r(document.body).trigger("wc_fragments_ajax_error")}};function n(){r.ajax(e)}if(t){var i=null;r(document.body).on("wc_fragment_refresh updated_wc_div",function(){n()}),r(document.body).on("added_to_cart removed_from_cart",function(e,t,r){var n=sessionStorage.getItem(o);null!==n&&n!==undefined&&""!==n||a(),sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(t)),s(r)}),r(document.body).on("wc_fragments_refreshed",function(){clearTimeout(i),i=setTimeout(n,864e5)}),r(window).on("storage onstorage",function(e){o===e.originalEvent.key&&localStorage.getItem(o)!==sessionStorage.getItem(o)&&n()}),r(window).on("pageshow",function(e){e.originalEvent.persisted&&(r(".widget_shopping_cart_content").empty(),r(document.body).trigger("wc_fragment_refresh"))});try{var c=r.parseJSON(sessionStorage.getItem(wc_cart_fragments_params.fragment_name)),_=sessionStorage.getItem(o),g=Cookies.get("woocommerce_cart_hash"),m=sessionStorage.getItem("wc_cart_created");if(null!==_&&_!==undefined&&""!==_||(_=""),null!==g&&g!==undefined&&""!==g||(g=""),_&&(null===m||m===undefined||""===m))throw"No cart_created";if(m){var d=1*m+864e5,w=(new Date).getTime();if(d0)&&"visible"!=A(a,"overflow")&&(i=a.getBoundingClientRect(),o=I>i.left&&Di.top-1&&H500&&r.clientWidth>500?500:370:a.expand,i._defEx=v,g=v*a.expFactor,m=a.hFac,U=null,K2&&B>2&&!t.hidden?(K=g,V=0):K=B>1&&V>1&&Q<6?v:0),f!==u&&(k=innerWidth+u*m,R=innerHeight+u,d=-1*u,f=u),o=y[n].getBoundingClientRect(),($=o.bottom)>=d&&(H=o.top)<=R&&(I=o.right)>=d*m&&(D=o.left)<=k&&($||I||D||H)&&(a.loadHidden||Y(y[n]))&&(P&&Q<3&&!c&&(B<3||V<4)||Z(y[n],u))){if(se(y[n]),l=!0,Q>9)break}else!l&&P&&!s&&Q<4&&V<4&&B>2&&(W[0]||a.preloadAfterLoad)&&(W[0]||!c&&($||I||D||H||"auto"!=y[n].getAttribute(a.sizesAttr)))&&(s=W[0]||y[n]);s&&!l&&se(s)}},te=function(e){var t,i=0,r=a.throttleDelay,o=a.ricTimeout,s=function(){t=!1,i=n.now(),e()},u=d&&o>49?function(){d(s,{timeout:o}),o!==a.ricTimeout&&(o=a.ricTimeout)}:C((function(){l(s)}),!0);return function(e){var a;(e=!0===e)&&(o=33),t||(t=!0,(a=r-(n.now()-i))<0&&(a=0),e||a<9?u():l(u,a))}}(ee),ne=function(e){var t=e.target;t._lazyCache?delete t._lazyCache:(X(e),y(t,a.loadedClass),b(t,a.loadingClass),p(t,ae),z(t,"lazyloaded"))},ie=C(ne),ae=function(e){ie({target:e.target})},re=function(e){var t,n=e.getAttribute(a.srcsetAttr);(t=a.customMedia[e.getAttribute("data-media")||e.getAttribute("media")])&&e.setAttribute("media",t),n&&e.setAttribute("srcset",n)},oe=C((function(e,t,n,i,r){var o,s,u,d,f,v;(f=z(e,"lazybeforeunveil",t)).defaultPrevented||(i&&(n?y(e,a.autosizesClass):e.setAttribute("sizes",i)),s=e.getAttribute(a.srcsetAttr),o=e.getAttribute(a.srcAttr),r&&(d=(u=e.parentNode)&&c.test(u.nodeName||"")),v=t.firesLoad||"src"in e&&(s||o||d),f={target:e},y(e,a.loadingClass),v&&(clearTimeout(j),j=l(X,2500),p(e,ae,!0)),d&&g.call(u.getElementsByTagName("source"),re),s?e.setAttribute("srcset",s):o&&!d&&(G.test(e.nodeName)?function(e,t){try{e.contentWindow.location.replace(t)}catch(n){e.src=t}}(e,o):e.src=o),r&&(s||d)&&h(e,{src:o})),e._lazyRace&&delete e._lazyRace,b(e,a.lazyClass),E((function(){var t=e.complete&&e.naturalWidth>1;v&&!t||(t&&y(e,"ls-is-cached"),ne(f),e._lazyCache=!0,l((function(){"_lazyCache"in e&&delete e._lazyCache}),9)),"lazy"==e.loading&&Q--}),!0)})),se=function(e){if(!e._lazyRace){var t,n=q.test(e.nodeName),i=n&&(e.getAttribute(a.sizesAttr)||e.getAttribute("sizes")),r="auto"==i;(!r&&P||!n||!e.getAttribute("src")&&!e.srcset||e.complete||m(e,a.errorClass)||!m(e,a.lazyClass))&&(t=z(e,"lazyunveilread").detail,r&&w.updateElem(e,!0,e.offsetWidth),e._lazyRace=!0,Q++,oe(e,t,r,i,n))}},le=_((function(){a.loadMode=3,te()})),ue=function(){3==a.loadMode&&(a.loadMode=2),le()},de=function(){P||(n.now()-F<999?l(de,999):(P=!0,a.loadMode=3,te(),s("scroll",ue,!0)))},{_:function(){F=n.now(),i.elements=t.getElementsByClassName(a.lazyClass),W=t.getElementsByClassName(a.lazyClass+" "+a.preloadClass),s("scroll",te,!0),s("resize",te,!0),s("pageshow",(function(e){if(e.persisted){var n=t.querySelectorAll("."+a.loadingClass);n.length&&n.forEach&&u((function(){n.forEach((function(e){e.complete&&se(e)}))}))}})),e.MutationObserver?new MutationObserver(te).observe(r,{childList:!0,subtree:!0,attributes:!0}):(r.addEventListener("DOMNodeInserted",te,!0),r.addEventListener("DOMAttrModified",te,!0),setInterval(te,999)),s("hashchange",te,!0),["focus","mouseover","click","load","transitionend","animationend"].forEach((function(e){t.addEventListener(e,te,!0)})),/d$|^c/.test(t.readyState)?de():(s("load",de),t.addEventListener("DOMContentLoaded",te),l(de,2e4)),i.elements.length?(ee(),E._lsFlush()):te()},checkElems:te,unveil:se,_aLSL:ue}),w=(N=C((function(e,t,n,i){var a,r,o;if(e._lazysizesWidth=i,i+="px",e.setAttribute("sizes",i),c.test(t.nodeName||""))for(r=0,o=(a=t.getElementsByTagName("source")).length;r=0?n.splice(i,1):n.push(this),this.each(function(){function t(e){return Math.ceil(e.offset().top)>=h+m}var i=e(this),n=i.find("> li"),o=n.length;if(o){var s,r,l,d,c,u,f=n.first(),p=n.last(),h=Math.floor(f.offset().top),m=Math.floor(f.outerHeight(!0)),v=!1;if(t(p)&&o>a.threshold&&!a.undo&&i.is(":visible")&&a.shouldApply()){var y=e('');for(y.addClass(a.popupClass),u=o;u>1;u--){if(r=t(s=i.find("> li:last-child")),u-1<=a.cutoff){e(i.children().get().reverse()).appendTo(y),v=!0;break}if(!r)break;s.appendTo(y)}v?i.append('
  • '+a.linkTextAll+"
  • "):i.append('
  • '+a.linkText+"
  • "),t(l=i.find("> li.flexMenu-viewMore"))&&i.find("> li:nth-last-child(2)").appendTo(y),y.children().each(function(e,t){y.prepend(t)}),l.append(y),i.find("> li.flexMenu-viewMore > a").click(function(t){var i;i=l,e("li.flexMenu-viewMore.active").not(i).find("> ul").hide(),y.toggle(),t.preventDefault()}),a.showOnHover&&"undefined"!=typeof Modernizr&&!Modernizr.touch&&l.hover(function(){y.show()},function(){y.hide()})}else if(a.undo&&i.find("ul.flexMenu-popup")){for(d=(c=i.find("ul.flexMenu-popup")).find("li").length,u=1;d>=u;u++)c.find("> li:first-child").appendTo(i);c.remove(),i.find("> li.flexMenu-viewMore").remove()}}})}}),!function(e,t){"function"==typeof define&&define.amd?define(function(){return t(e)}):"object"==typeof exports?module.exports=t:e.emergence=t(e)}(this,function(){"use strict";var e,t,i,n,a,o,s,r={},l=function(){},d=function(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini|playbook|silk/i.test(navigator.userAgent)},c=function(e){var t=e.offsetWidth,i=e.offsetHeight,n=0,a=0;do isNaN(e.offsetTop)||(n+=e.offsetTop),isNaN(e.offsetLeft)||(a+=e.offsetLeft);while(null!==(e=e.offsetParent));return{width:t,height:i,top:n,left:a}},u=function(e){if(function(e){return null===e.offsetParent}(e))return!1;var i,n,r,l=c(e),d=function(e){var t,i;return e!==window?(t=e.clientWidth,i=e.clientHeight):(t=window.innerWidth||document.documentElement.clientWidth,i=window.innerHeight||document.documentElement.clientHeight),{width:t,height:i}}(t),u=function(e){return e!==window?{x:e.scrollLeft+c(e).left,y:e.scrollTop+c(e).top}:{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}}(t),f=(l.width,l.height),p=l.top;return l.left,i=p+f*a,n=p+f-f*a,r=u.y+o,ir},f=function(){e||(clearTimeout(e),e=setTimeout(function(){r.engage(),e=null},i))};return r.init=function(e){var r,c,u=function(e,t){return parseInt(e||t,10)};t=(e=e||{}).container||window,n=void 0===e.handheld||e.handheld,i=u(e.throttle,250),r=e.elemCushion,c=.1,a=parseFloat(r||c),o=u(e.offsetTop,0),u(e.offsetRight,0),s=u(e.offsetBottom,0),u(e.offsetLeft,0),l=e.callback||l,"querySelectorAll"in document?(d()&&n||!d())&&(window.addEventListener?(window.addEventListener("load",f,!1),t.addEventListener("scroll",f,!1),t.addEventListener("resize",f,!1)):(document.attachEvent("onreadystatechange",function(){"complete"===document.readyState&&f()}),t.attachEvent("onscroll",f),t.attachEvent("onresize",f))):console.log("Emergence.js is not supported in this browser.")},r.engage=function(){if(tie.lazyload){for(var e=(d=document.querySelectorAll("[data-src]")).length,t=0;e>t;t++)c=d[t],u(c)&&(c.setAttribute("src",c.getAttribute("data-src")),c.removeAttribute("data-src"),c.className+=" lazy-done",l(c,"tie_img_visible"),jQuery.fn.masonry&&jQuery("#masonry-grid").masonry("layout"));var i=(d=document.querySelectorAll("[data-lazy-bg]")).length;for(t=0;i>t;t++)c=d[t],u(c)&&(c.setAttribute("style","background-image:url("+c.getAttribute("data-lazy-bg")+")"),c.removeAttribute("data-lazy-bg"),c.className=c.className,l(c,"tie_bg_visible"))}if(tie.is_taqyeem_active){var n=(d=document.querySelectorAll("[data-lazy-pie]")).length;for(t=0;n>t;t++)if(c=d[t],u(c)){var a=parseInt(c.getAttribute("data-pct")),o=c.getElementsByClassName("circle_bar")[0],s=(100-a)/100*Math.PI*38;o.setAttribute("style","stroke-dashoffset:"+s+"px"),c.removeAttribute("data-lazy-pie"),c.className=c.className,l(c,"tie_pie_visible")}var d,c,f=(d=document.querySelectorAll("[data-lazy-percent]")).length;for(t=0;f>t;t++)c=d[t],u(c)&&(c.setAttribute("style","width:"+c.getAttribute("data-rate-val")),c.removeAttribute("data-lazy-percent"),c.className=c.className,l(c,"tie_rate_visible"))}e||n||f||i||r.disengage()},r.disengage=function(){window.removeEventListener?(t.removeEventListener("scroll",f,!1),t.removeEventListener("resize",f,!1)):(t.detachEvent("onscroll",f),t.detachEvent("onresize",f)),clearTimeout(e)},r}),!function(e){"use strict";e.fn.tieFitVids=function(t){var i={customSelector:null,ignore:null};t&&e.extend(i,t);var n=['iframe[src*="player.vimeo.com"]','iframe[src*="player.twitch.tv"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="maps.google.com"]','iframe[src*="google.com/maps"]','iframe[src*="dailymotion.com"]','iframe[src*="twitter.com/i/videos"]',"object","embed"];if(n=n.join(","),i.customSelector&&n.push(i.customSelector),document.querySelectorAll(n).length){var a=".tie-ignore-fitvid, #buddypress";return i.ignore&&(a=a+", "+i.ignore),this.each(function(){e(this).find(n).each(function(){var t=e(this);if(!(t.parents(a).length>0||("embed"===this.tagName.toLowerCase()||"object"===this.tagName.toLowerCase())&&t.parent("object").length||t.parent(".tie-fluid-width-video-wrapper").length)){t.css("height")||t.css("width")||!isNaN(t.attr("height"))&&!isNaN(t.attr("width"))||(t.attr("height",9),t.attr("width",16));var i=("object"===this.tagName.toLowerCase()||t.attr("height")&&!isNaN(parseInt(t.attr("height"),10))?parseInt(t.attr("height"),10):t.height())/(isNaN(parseInt(t.attr("width"),10))?t.width():parseInt(t.attr("width"),10));t.removeAttr("height").removeAttr("width"),t.wrap('
    ').parent(".tie-fluid-width-video-wrapper").css("padding-top",100*i+"%")}})})}}}(window.jQuery),$doc.ready(function(){"use strict";function e(e){var t=!0,i=0,n=0,a=0,o=0,s=!1,r="upwards"==tie.sticky_mobile_behavior?!0:!1,l="auto",d=0,c=0,u=window.innerWidth;if(!(u>991)){if("size"!==l){var f=0,p=0;if($body.hasClass("admin-bar")){var h=jQuery("#wpadminbar");h.length>0&&(f=h.outerHeight(),p=f,"resize"!==e.type&&(s=p),"absolute"===h.css("position")&&(p=0,"resize"!==e.type&&(s=0)))}var m=$themeHeader.hasClass("header-layout-1")?$mainNav:jQuery(".logo-container"),v=m.parent(),y=m.not(".fixed-nav").offset();c=v.outerHeight()+y.top,y&&!m.hasClass(".fixed-nav")?(d=y.top,o=y.top):d=o,32===s?46===f?d=d-p+14:d-=p:(46===s||0===s)&&(32===f?d=d-p-14:d-=p)}var g=jQuery(m).outerHeight();v.data("min-height",c-g),v.height(g),"resize"!==e.type&&(r&&v.addClass("sticky-type-slide"),jQuery(window).scroll(function(e){if(e.originalEvent){var o=jQuery(window).scrollTop();r?(o>c&&m.addClass("fixed-nav"),d>=o&&m.removeClass("fixed-nav"),o>n?(i=0,a="down",m.addClass("sticky-down").removeClass("sticky-up")):(i+=n-o,a="up",m.addClass("sticky-up").removeClass("sticky-down")),i>150&&"up"===a?(m.addClass("sticky-nav-slide-visible"),jQuery(document).trigger("sticky-nav-visible")):(m.removeClass("sticky-nav-slide-visible"),jQuery(document).trigger("sticky-nav-hide")),o>c+150?m.addClass("sticky-nav-slide"):m.removeClass("sticky-nav-slide"),t&&o>c+150&&(m.addClass("sticky-nav-slide sticky-nav-slide-visible sticky-up"),jQuery(document).trigger("sticky-nav-visible"),i=151,a="up",t=!1)):o>d?(m.addClass("fixed-nav default-behavior-mode"),jQuery(document).trigger("sticky-nav-visible")):(m.removeClass("fixed-nav"),jQuery(document).trigger("sticky-nav-hide")),n=o}}))}}function t(e){jQuery(e).show(),"#tie-popup-search-wrap"==e&&f.find('form input[type="text"]').focus(),tie_animate_element(jQuery(e)),scrollBarWidth||(scrollBarWidth=100-document.getElementById("is-scroller").offsetWidth),setTimeout(function(){$body.addClass("tie-popup-is-opend")},10),jQuery("html").css({marginRight:scrollBarWidth,overflow:"hidden"})}function i(){jQuery.when(f.fadeOut(500)).done(function(){jQuery("html").removeAttr("style")}),jQuery("#autocomplete-suggestions").fadeOut(),$body.removeClass("tie-popup-is-opend"),jQuery("#tie-popup-search-input").val("")}function n(){if(!tie.mobile_menu_active||mobileMenu)return!1;var e=jQuery("#mobile-menu"),t="";if(e.hasClass("has-custom-menu")){var i=jQuery("#mobile-custom-menu");i.find("div.mega-menu-content").remove(),i.find("li.menu-item-has-children:not(.hide-mega-headings)").append('')}else{var n=$mainNav.find("div.main-menu > ul");if(n.length){var t=n.clone();t.find(".mega-menu-content").remove(),t.removeAttr("id").find("li").removeAttr("id"),t.find("li.menu-item-has-children:not(.hide-mega-headings)").append(''),e.append(t);var a=t.find("> li");1==a.length&&(a.find("> .mobile-arrows").toggleClass("is-open"),a.find("> ul").show())}if(tie.mobile_menu_top){var o=jQuery("#top-nav div.top-menu > ul");if(o.length){var s=o.clone();s.removeAttr("id").find("li").removeAttr("id"),s.find("li.menu-item-has-children").append(''),e.append(s)}}}tie.mobile_menu_parent?jQuery("li.menu-item-has-children .mobile-arrows","#mobile-menu").click(function(){return jQuery(this).toggleClass("is-open").closest(".menu-item").find("ul").first().slideToggle(300),!1}):jQuery("li.menu-item-has-children > a, li.menu-item-has-children > .mobile-arrows","#mobile-menu").click(function(){return jQuery(this).parent().find("ul").first().slideToggle(300),jQuery(this).parent().find("> .mobile-arrows").toggleClass("is-open"),!1}),mobileMenu=!0}if(performance.mark("TieStart"),emergence.init(),tie.ad_blocker_detector&&"undefined"==typeof $tieE3&&(adBlock=!0,t("#tie-popup-adblock")),$doc.on("click","h3.toggle-head",function(){var e=jQuery(this).parent();e.find("div.toggle-content").slideToggle(),e.toggleClass("tie-sc-open tie-sc-close")}),$doc.on("click",".profile-btn",function(){return!1}),$container.tieFitVids(),jQuery.fn.masonry){var a=jQuery("#masonry-grid");if(a.length){var o=jQuery("#media-page-layout");a.masonry({columnWidth:".grid-sizer",gutter:".gutter-sizer",itemSelector:".post-element",percentPosition:!0,isInitLayout:!1,initLayout:!1,originLeft:!is_RTL,isOriginLeft:!is_RTL}).addClass("masonry-loaded"),a.masonry("on","layoutComplete",function(){isDuringAjax=!1}),a.masonry(),a.imagesLoaded().progress(function(){a.masonry("layout")}),o.find(".loader-overlay").fadeOut().remove(),o.find(".post-element").addClass("tie-animate-slideInUp tie-animate-delay")}}for(var s=jQuery(".tabs-wrapper").get(),r=null,l=0,d=s.length;d>l;l++){if(r=jQuery(s[l]),r.find(".tabs li").first().addClass("active"),r.hasClass("tabs-vertical")){var c=r.find(".tabs").outerHeight();r.find(".tab-content").css({minHeight:c})}r.find(".tabs li").on("click",function(){var e=jQuery(this);if(!e.hasClass("active")){e.parents(".tabs").find("li").removeClass("active"),e.addClass("active"),e.parents(".tabs-wrapper").find(".tab-content").hide().addClass("is-not-active");var t=e.find("a").attr("href"),i=jQuery(t).show();i.find(".tab-content-elements li").addClass("tie-animate-slideInUp tie-animate-delay"),i.find(".tab-content-wrap").addClass("tie-animate-slideInUp"),tie_animate_element(i)}return!1})}var u=jQuery(".is-flex-tabs, .is-flex-tabs-shortcodes .tabs");u.length&&(u.flexMenu({threshold:0,cutoff:0,linkText:'More',linkTextAll:'More',linkTitle:"",linkTitleAll:"",showOnHover:intialWidth>991?!0:!1}),u.css({opacity:1})),tie.sticky_mobile&&($window.on("load",e),$window.resize(e));var f=jQuery(".tie-popup");$doc.on("click",".tie-popup-trigger",function(e){e.preventDefault(),t("#tie-popup-login")}),jQuery(".tie-search-trigger").length&&(tie.type_to_search&&window.self===window.top&&$doc.bind("keydown",function(e){!jQuery("input, textarea").is(":focus")&&!jQuery("#tie-popup-login").is(":visible")&&!e.ctrlKey&&!e.metaKey&&e.keyCode>=65&&e.keyCode<=90&&($container.removeClass("side-aside-open"),t("#tie-popup-search-wrap"))}),jQuery(".tie-search-trigger").on("click",function(){return t("#tie-popup-search-wrap"),!1})),f.length&&!adBlock&&$doc.keyup(function(e){"27"==e.which&&$body.hasClass("tie-popup-is-opend")&&i()}),f.on("click",function(e){return jQuery(e.target).is(".tie-popup:not(.is-fixed-popup)")?(i(),!1):void 0}),jQuery(".tie-btn-close").on("click",function(){return i(),!1});var p=function(){$container.removeClass("side-aside-open"),$container.off("touchstart click",h)},h=function(e){return $container.hasClass("side-aside-open")?void(jQuery(e.target).parents(".side-aside").length||p()):!1},m=jQuery(".side-aside-nav-icon, #mobile-menu-icon");m.on("touchstart click",function(){return n(),$container.addClass("side-aside-open"),$container.on("touchstart click",h),jQuery("#autocomplete-suggestions").hide(),!1}),$doc.on("keydown",function(e){27==e.which&&p()}),jQuery(".close-side-aside").on("click",function(){return p(),!1}),$window.resize(function(){intialWidth=window.innerWidth,991==intialWidth&&p()}),jQuery('a[href^="#go-to-"]').on("click",function(){var e=jQuery(this).attr("href"),t="#"+e.slice(7),i=tie.sticky_desktop?100:40,n=jQuery(t).offset().top-i;return jQuery("html, body").animate({scrollTop:n},"slow"),!1});var v=jQuery("#go-to-top"),y=!1,g=!1;v.length&&(y=!0),$window.scroll(function(){y&&(g&&window.clearTimeout(g),g=window.setTimeout(function(){$window.scrollTop()>100?v.addClass("show-top-button"):v.removeClass("show-top-button")},100))}),$doc.on("click",".block-pagination",function(){var e=jQuery(this),t=e.closest(".mag-box"),i=t.get(0).id,n=t.closest(".section-item"),a=t.attr("data-term"),o=t.attr("data-current"),s=t.find(".posts-list-container"),r=t.find(".mag-box-container"),l=jQuery.extend({},window["js_"+i.replace("tie-","tie_")]),d="posts-items",c=!1,u="single";if(o&&l){if(a&&(l.tags?l.tags=a:l.id=a),l.ajax_class&&(d=l.ajax_class),e.hasClass("pagination-disabled"))return!1;e.hasClass("load-more-button")?(o++,c=!0):e.hasClass("next-posts")?(o++,t.find(".prev-posts").removeClass("pagination-disabled")):e.hasClass("prev-posts")&&(o--,t.find(".next-posts").removeClass("pagination-disabled")),n.hasClass("full-width")&&(u="full"),jQuery.ajax({url:tie.ajaxurl,type:"post",data:{action:"tie_blocks_load_more",block:l,page:o,width:u},beforeSend:function(){if(c)e.html(tie.ajax_loader);else{var t=r.height();r.append(tie.ajax_loader).attr("style","min-height:"+t+"px"),s.addClass("is-loading")}},success:function(i){if(i=jQuery.parseJSON(i),i.hide_next?(t.find(".next-posts").addClass("pagination-disabled"),(e.hasClass("show-more-button")||c)&&e.html(i.button)):c&&e.html(e.attr("data-text")),i.hide_prev&&t.find(".prev-posts").addClass("pagination-disabled"),i=i.code,c){var n='
      '+i+"
    ";n=jQuery(n),r.append(n)}else{var n='
      '+i+"
    ";n=jQuery(n),r.html(n)}var a=t.find(".posts-items-"+o);a.find("li").addClass("tie-animate-slideInUp tie-animate-delay"),tie_animate_element(a),r.attr("style","")}}),t.attr("data-current",o)}return!1}),$doc.on("click",".block-ajax-term",function(){var e=jQuery(this),t=e.closest(".mag-box"),i=e.attr("data-id"),n=t.get(0).id,a=t.find(".posts-list-container"),o=t.find(".mag-box-container"),s=jQuery.extend({},window["js_"+n.replace("tie-","tie_")]),r="posts-items";return s&&(t.attr("data-current",1),i?(s.tags?s.tags=i:s.id=i,t.attr("data-term",i)):t.removeAttr("data-term"),s.ajax_class&&(r=s.ajax_class),jQuery.ajax({url:tie.ajaxurl,type:"post",data:{action:"tie_blocks_load_more",block:s},beforeSend:function(){var e=o.height();o.append(tie.ajax_loader).attr("style","min-height:"+e+"px"),a.addClass("is-loading")},success:function(i){i=jQuery.parseJSON(i),t.find(".block-pagination").removeClass("pagination-disabled");var n=t.find(".show-more-button");n.html(n.attr("data-text")),t.find(".block-ajax-term").removeClass("active"),e.addClass("active"),i.hide_next&&(t.find(".next-posts").addClass("pagination-disabled"),t.find(".show-more-button").html(i.button)),i.hide_prev&&t.find(".prev-posts").addClass("pagination-disabled"),i=i.code;var a='
      '+i+"
    ";a=jQuery(a),o.html(a),o.find("li").addClass("tie-animate-slideInUp tie-animate-delay"),tie_animate_element(o),o.attr("style","")}})),!1}),performance.mark("TieEnd"),performance.measure("TieLabs Custom JS","TieStart","TieEnd")}); (function(g,p,Q){function F(a,b){return parseInt(a.css(b),10)||0}function J(){var a=p,b="inner";"innerWidth"in p||(b="client",a=document.documentElement||document.body);return{width:a[b+"Width"],height:a[b+"Height"]}}function ia(){var a=L();p.location.hash="";p.scrollTo(a.x,a.y)}function ja(a,b){a="//ilightbox.net/getSource/jsonp.php?url="+encodeURIComponent(a).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A");g.ajax({url:a,dataType:"jsonp"});iLCallback= function(a){b.call(this,a)}}function R(a){var b=[];g("*",a).each(function(){var a="";"none"!=g(this).css("background-image")?a=g(this).css("background-image"):"undefined"!=typeof g(this).attr("src")&&"img"==this.nodeName.toLowerCase()&&(a=g(this).attr("src"));if(-1==a.indexOf("gradient")){a=a.replace(/url\(\"/g,"");a=a.replace(/url\(/g,"");a=a.replace(/\"\)/g,"");a=a.replace(/\)/g,"");a=a.split(",");for(var d=0;dD.version&& (e="?"+M(3E3*S()));b.push(a[d]+e)}}});return b}function Z(a){if(a.indexOf(".jpg")&&a.indexOf("?")&&a.indexOf("instagram.com")){return 'jpg';} a=a.split(".").pop().toLowerCase();var b=-1!==a.indexOf("?")?a.split("?").pop():"";return a.replace(b,"")}function aa(a){a=Z(a);return-1!==T.image.indexOf(a)?"image":-1!==T.flash.indexOf(a)?"flash":-1!==T.video.indexOf(a)?"video":"iframe"}function ba(a,b){return parseInt(b/100*a)}function U(a){return(a=String(a).replace(/^\s+|\s+$/g,"").match(/^([^:\/?#]+:)?(\/\/(?:[^:@]*(?::[^:@]*)?@)?(([^:\/?#]*)(?::(\d*))?))?([^?#]*)(\?[^#]*)?(#[\s\S]*)?/))? {href:a[0]||"",protocol:a[1]||"",authority:a[2]||"",host:a[3]||"",hostname:a[4]||"",port:a[5]||"",pathname:a[6]||"",search:a[7]||"",hash:a[8]||""}:null}function N(a,b){function c(a){var b=[];a.replace(/^(\.\.?(\/|$))+/,"").replace(/\/(\.(\/|$))+/g,"/").replace(/\/\.\.$/,"/../").replace(/\/?[^\/]*/g,function(a){"/.."===a?b.pop():b.push(a)});return b.join("").replace(/^\//,"/"===a.charAt(0)?"/":"")}b=U(b||"");a=U(a||"");return b&&a?(b.protocol||a.protocol)+(b.protocol||b.authority?b.authority:a.authority)+ c(b.protocol||b.authority||"/"===b.pathname.charAt(0)?b.pathname:b.pathname?(a.authority&&!a.pathname?"/":"")+a.pathname.slice(0,a.pathname.lastIndexOf("/")+1)+b.pathname:a.pathname)+(b.protocol||b.authority||b.pathname?b.search:b.search||a.search)+b.hash:null}function ka(a,b,c){this.php_js=this.php_js||{};this.php_js.ENV=this.php_js.ENV||{};var d=0,e=0,f=0,h={dev:-6,alpha:-5,a:-5,beta:-4,b:-4,RC:-3,rc:-3,"#":-2,p:1,pl:1};d=function(a){a=(""+a).replace(/[_\-+]/g,".");a=a.replace(/([^.\d]+)/g,".$1.").replace(/\.{2,}/g, ".");return a.length?a.split("."):[-8]};var g=function(a){return a?isNaN(a)?h[a]||-7:parseInt(a,10):0};a=d(a);b=d(b);e=ca(a.length,b.length);for(d=0;db[d]){f=1;break}if(!c)return f;switch(c){case ">":case "gt":return 0=":case "ge":return 0<=f;case "<=":case "le":return 0>=f;case "==":case "=":case "eq":return 0===f;case "<>":case "!=":case "ne":return 0!==f;case "":case "<":case "lt":return 0>f;default:return null}} function L(){var a=0,b=0;"number"==typeof p.pageYOffset?(b=p.pageYOffset,a=p.pageXOffset):document.body&&(document.body.scrollLeft||document.body.scrollTop)?(b=document.body.scrollTop,a=document.body.scrollLeft):document.documentElement&&(document.documentElement.scrollLeft||document.documentElement.scrollTop)&&(b=document.documentElement.scrollTop,a=document.documentElement.scrollLeft);return{x:a,y:b}}function da(a,b,c){var d=r[a+b];null==d&&(d=r[b]);return null!=d?(0==b.indexOf(a)&&null==c&&(c= b.substring(a.length)),null==c&&(c=b),c+'="'+d+'" '):""}function A(a,b){if(0==a.indexOf("emb#"))return"";0==a.indexOf("obj#")&&null==b&&(b=a.substring(4));return da("obj#",a,b)}function G(a,b){if(0==a.indexOf("obj#"))return"";0==a.indexOf("emb#")&&null==b&&(b=a.substring(4));return da("emb#",a,b)}function ea(a,b){var c,d="",e=b?" />":">";-1==a.indexOf("emb#")&&(c=r["obj#"+a],null==c&&(c=r[a]),0==a.indexOf("obj#")&&(a=a.substring(4)),null!=c&&(d=' b.length||0!=b.length%2)b=na,b=b.replace("%%",a),alert(b),a="";else{r=[];r.src=b[0];r.width=b[1];r.height=b[2];r.classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B";r.pluginspage="http://www.apple.com/quicktime/download/";a=b[3];if(null==a||""==a)a="6,0,2,0";r.codebase="http://www.apple.com/qtactivex/qtplugin.cab#version="+ a;for(var c,d=4;d\n"+ea("src",!1);d=" \n"}return a}var T={flash:["swf"],image:"bmp gif jpeg jpg png tiff tif jfif jpe".split(" "),iframe:"asp aspx cgi cfm htm html jsp php pl php3 php4 php5 phtml rb rhtml shtml txt".split(" "),video:"avi mov mpg mpeg movie mp4 webm ogv ogg 3gp m4v".split(" ")},O=g(p),E=g(document),D,B,H,t="",V=navigator.userAgent||navigator.vendor||p.opera,z=!!("ontouchstart"in p)&& /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(V),oa=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm(os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(V)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s)|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp(i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac(|\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt(|\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg(g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v)|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v)|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-|)|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(V.substr(0, 4)),K=z?"itap.iLightBox":"click.iLightBox",pa=z?"touchstart.iLightBox":"mousedown.iLightBox",qa=z?"touchend.iLightBox":"mouseup.iLightBox",W=z?"touchmove.iLightBox":"mousemove.iLightBox",I=Math.abs,P=Math.sqrt,X=Math.round,ca=Math.max,Y=Math.min,M=Math.floor,S=Math.random,fa=function(a,b,c,d){var e=this;e.options=b;e.selector=a.selector||a;e.context=a.context;e.instant=d;1>c.length?e.attachItems():e.items=c;e.vars={total:e.items.length,start:0,current:null,next:null,prev:null,BODY:g("body"),loadRequests:0, overlay:g('
    '),loader:g('
    '),toolbar:g('
    '),innerToolbar:g('
    '),title:g('
    '),closeButton:g(''),fullScreenButton:g(''),innerPlayButton:g(''),innerNextButton:g(''),innerPrevButton:g(''),holder:g('
    '),nextPhoto:g('
    '), prevPhoto:g('
    '),nextButton:g(''),prevButton:g(''),thumbnails:g('
    '), thumbs:!1,nextLock:!1,prevLock:!1,hashLock:!1,isMobile:!1,mobileMaxWidth:980,isInFullScreen:!1,isSwipe:!1,mouseID:0,cycleID:0,isPaused:0};e.vars.hideableElements=e.vars.nextButton.add(e.vars.prevButton);e.normalizeItems();e.availPlugins();e.options.startFrom=0=e.vars.total?e.vars.total-1:e.options.startFrom;e.options.startFrom=e.options.randomStart?M(S()*e.vars.total):e.options.startFrom;e.vars.start=e.options.startFrom;d?e.instantCall():e.patchItemsEvents(); e.options.linkId&&(e.hashChangeHandler(),O.iLightBoxHashChange(function(){e.hashChangeHandler()}));z&&(a=/(click|mouseenter|mouseleave|mouseover|mouseout)/ig,e.options.caption.show=e.options.caption.show.replace(a,"itap"),e.options.caption.hide=e.options.caption.hide.replace(a,"itap"),e.options.social.show=e.options.social.show.replace(a,"itap"),e.options.social.hide=e.options.social.hide.replace(a,"itap"));e.options.controls.arrows&&g.extend(e.options.styles,{nextOffsetX:0,prevOffsetX:0,nextOpacity:0, prevOpacity:0})};fa.prototype={showLoader:function(){this.vars.loadRequests+=1;"horizontal"==this.options.path.toLowerCase()?this.vars.loader.addClass("ilightbox-show").stop().animate({top:"-30px"},this.options.show.speed,"easeOutCirc"):this.vars.loader.addClass("ilightbox-show").stop().animate({left:"-30px"},this.options.show.speed,"easeOutCirc")},hideLoader:function(){--this.vars.loadRequests;this.vars.loadRequests=0>this.vars.loadRequests?0:this.vars.loadRequests;"horizontal"==this.options.path.toLowerCase()? 0>=this.vars.loadRequests&&this.vars.loader.removeClass("ilightbox-show").stop().animate({top:"-192px"},this.options.show.speed,"easeInCirc"):0>=this.vars.loadRequests&&this.vars.loader.removeClass("ilightbox-show").stop().animate({left:"-192px"},this.options.show.speed,"easeInCirc")},createUI:function(){var a=this;a.ui={currentElement:a.vars.holder,nextElement:a.vars.nextPhoto,prevElement:a.vars.prevPhoto,currentItem:a.vars.current,nextItem:a.vars.next,prevItem:a.vars.prev,hide:function(){a.closeAction()}, refresh:function(){0=b.total-1&&b.nextButton.add(b.innerNextButton).addClass("disabled"));c.show.effect?(b.overlay.stop().fadeIn(c.show.speed),b.toolbar.stop().fadeIn(c.show.speed)):(b.overlay.show(),b.toolbar.show());var l=f.length;h?(a.showLoader(),g.each(f,function(d,e){a.ogpRecognition(this,function(d){console.log(d);var e=-1;a.items.filter(function(a,b,c){a.URL==d.url&&(e=b);return a.URL==d.url});var f=a.items[e];d&&g.extend(!0,f,{URL:d.source,type:d.type, recognized:!0,options:{html5video:d.html5video,width:"image"==d.type?0:d.width||f.width,height:"image"==d.type?0:d.height||f.height,thumbnail:f.options.thumbnail||d.thumbnail}});l--;0==l&&(a.hideLoader(),b.dontGenerateThumbs=!1,a.generateThumbnails(),c.show.effect?setTimeout(function(){a.generateBoxes()},c.show.speed):a.generateBoxes())})})):c.show.effect?setTimeout(function(){a.generateBoxes()},c.show.speed):a.generateBoxes();a.createUI();p.iLightBox={close:function(){a.closeAction()},fullscreen:function(){a.fullScreenAction()}, moveNext:function(){a.moveTo("next")},movePrev:function(){a.moveTo("prev")},goTo:function(b){a.goTo(b)},refresh:function(){a.refresh()},reposition:function(){0':''+f.errors.loadImage+"");"function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&&a.options.onRender.call(e,h);e.configureHolder(a,d,b)});break;case "video":b.data({naturalWidth:a.options.width,naturalHeight:a.options.height});"current"===d?(e.addContent(b,a),"function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c),"function"==typeof a.options.onRender&& a.options.onRender.call(e,h)):g("div.ilightbox-container",b).empty();e.configureHolder(a,d,b);break;case "iframe":b.data({naturalWidth:a.options.width,naturalHeight:a.options.height});e.configureHolder(a,d,b);if("current"===d){var l=e.addContent(b,a);"function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&&a.options.onRender.call(e,h);"function"==typeof f.callback.onBeforeLoad&&f.callback.onBeforeLoad.call(e,e.ui,c);"function"==typeof a.options.onBeforeLoad&& a.options.onBeforeLoad.call(e,h);l.bind("load",function(){"function"==typeof f.callback.onAfterLoad&&f.callback.onAfterLoad.call(e,e.ui,c);"function"==typeof a.options.onAfterLoad&&a.options.onAfterLoad.call(e,h);l.unbind("load")})}else g("div.ilightbox-container",b).empty();break;case "inline":l=g(a.URL);var k=e.addContent(b,a),n=R(b);b.data({naturalWidth:e.items[c].options.width||l.outerWidth(),naturalHeight:e.items[c].options.height||l.outerHeight()});k.children().eq(0).show();"function"==typeof f.callback.onRender&& f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&&a.options.onRender.call(e,h);"function"==typeof f.callback.onBeforeLoad&&f.callback.onBeforeLoad.call(e,e.ui,c);"function"==typeof a.options.onBeforeLoad&&a.options.onBeforeLoad.call(e,h);e.loadImage(n,function(){"function"==typeof f.callback.onAfterLoad&&f.callback.onAfterLoad.call(e,e.ui,c);"function"==typeof a.options.onAfterLoad&&a.options.onAfterLoad.call(e,h);e.configureHolder(a,d,b)});break;case "flash":l=e.addContent(b, a);b.data({naturalWidth:e.items[c].options.width||l.outerWidth(),naturalHeight:e.items[c].options.height||l.outerHeight()});"function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&&a.options.onRender.call(e,h);e.configureHolder(a,d,b);break;case "ajax":var m=a.options.ajax||{};"function"==typeof f.callback.onBeforeLoad&&f.callback.onBeforeLoad.call(e,e.ui,c);"function"==typeof a.options.onBeforeLoad&&a.options.onBeforeLoad.call(e,h);e.showLoader(); g.ajax({url:a.URL||f.ajaxSetup.url,data:m.data||null,dataType:m.dataType||"html",type:m.type||f.ajaxSetup.type,cache:m.cache||f.ajaxSetup.cache,crossDomain:m.crossDomain||f.ajaxSetup.crossDomain,global:m.global||f.ajaxSetup.global,ifModified:m.ifModified||f.ajaxSetup.ifModified,username:m.username||f.ajaxSetup.username,password:m.password||f.ajaxSetup.password,beforeSend:m.beforeSend||f.ajaxSetup.beforeSend,complete:m.complete||f.ajaxSetup.complete,success:function(k,l,n){e.hideLoader();var q=g(k), u=g("div.ilightbox-container",b),C=e.items[c].options.width||parseInt(q[0].getAttribute("width")),v=e.items[c].options.height||parseInt(q[0].getAttribute("height")),y=q[0].getAttribute("width")&&q[0].getAttribute("height")?{overflow:"hidden"}:{};u.empty().append(g('
    ').css(y).html(q));b.show().data({naturalWidth:C||u.outerWidth(),naturalHeight:v||u.outerHeight()}).hide();"function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&& a.options.onRender.call(e,h);q=R(b);e.loadImage(q,function(){"function"==typeof f.callback.onAfterLoad&&f.callback.onAfterLoad.call(e,e.ui,c);"function"==typeof a.options.onAfterLoad&&a.options.onAfterLoad.call(e,h);e.configureHolder(a,d,b)});f.ajaxSetup.success(k,l,n);"function"==typeof m.success&&m.success(k,l,n)},error:function(k,l,n){"function"==typeof f.callback.onAfterLoad&&f.callback.onAfterLoad.call(e,e.ui,c);"function"==typeof a.options.onAfterLoad&&a.options.onAfterLoad.call(e,h);e.hideLoader(); g("div.ilightbox-container",b).empty().append(''+f.errors.loadContents+"");e.configureHolder(a,d,b);f.ajaxSetup.error(k,l,n);"function"==typeof m.error&&m.error(k,l,n)}});break;case "html":k=a.URL;container=g("div.ilightbox-container",b);k[0].nodeName?l=k.clone():(k=g(k),l=k.selector?g("
    "+k+"
    "):k);var C=e.items[c].options.width||parseInt(l.attr("width")),y=e.items[c].options.height||parseInt(l.attr("height"));e.addContent(b,a);l.appendTo(document.documentElement).hide(); "function"==typeof f.callback.onRender&&f.callback.onRender.call(e,e.ui,c);"function"==typeof a.options.onRender&&a.options.onRender.call(e,h);n=R(b);"function"==typeof f.callback.onBeforeLoad&&f.callback.onBeforeLoad.call(e,e.ui,c);"function"==typeof a.options.onBeforeLoad&&a.options.onBeforeLoad.call(e,h);e.loadImage(n,function(){"function"==typeof f.callback.onAfterLoad&&f.callback.onAfterLoad.call(e,e.ui,c);"function"==typeof a.options.onAfterLoad&&a.options.onAfterLoad.call(e,h);b.show().data({naturalWidth:C|| container.outerWidth(),naturalHeight:y||container.outerHeight()}).hide();l.remove();e.configureHolder(a,d,b)})}},configureHolder:function(a,b,c){var d=this,e=d.vars,f=d.options;"current"!=b&&("next"==b?c.addClass("ilightbox-next"):c.addClass("ilightbox-prev"));if("current"==b)var h=e.current;else if("next"==b){var l=f.styles.nextOpacity;h=e.next}else l=f.styles.prevOpacity,h=e.prev;var k={element:c,position:h};d.items[h].options.width=d.items[h].options.width||0;d.items[h].options.height=d.items[h].options.height|| 0;"current"==b?f.show.effect?c.css(B,H).fadeIn(a.speed,function(){c.css(B,"");if(a.caption){d.setCaption(a,c);var b=g("div.ilightbox-caption",c),e=parseInt(b.outerHeight()/c.outerHeight()*100);f.caption.start&50>=e&&b.fadeIn(f.effects.fadeSpeed)}if(b=a.options.social)d.setSocial(b,a.URL,c),f.social.start&&g("div.ilightbox-social",c).fadeIn(f.effects.fadeSpeed);d.generateThumbnails();"function"==typeof f.callback.onShow&&f.callback.onShow.call(d,d.ui,h);"function"==typeof a.options.onShow&&a.options.onShow.call(d, k)}):(c.show(),d.generateThumbnails(),"function"==typeof f.callback.onShow&&f.callback.onShow.call(d,d.ui,h),"function"==typeof a.options.onShow&&a.options.onShow.call(d,k)):f.show.effect?c.fadeTo(a.speed,l,function(){"next"==b?e.nextLock=!1:e.prevLock=!1;d.generateThumbnails();"function"==typeof f.callback.onShow&&f.callback.onShow.call(d,d.ui,h);"function"==typeof a.options.onShow&&a.options.onShow.call(d,k)}):(c.css({opacity:l}).show(),"next"==b?e.nextLock=!1:e.prevLock=!1,d.generateThumbnails(), "function"==typeof f.callback.onShow&&f.callback.onShow.call(d,d.ui,h),"function"==typeof a.options.onShow&&a.options.onShow.call(d,k));setTimeout(function(){d.repositionPhoto()},0)},generateBoxes:function(){var a=this.vars,b=this.options;b.infinite&&3<=a.total?(a.current==a.total-1&&(a.next=0),0==a.current&&(a.prev=a.total-1)):b.infinite=!1;this.loadContent(this.items[a.current],"current",b.show.speed);this.items[a.next]&&this.loadContent(this.items[a.next],"next",b.show.speed);this.items[a.prev]&& this.loadContent(this.items[a.prev],"prev",b.show.speed)},generateThumbnails:function(){var a=this,b=a.vars,c=a.options,d=null;if(b.thumbs&&!a.vars.dontGenerateThumbs){var e=b.thumbnails,f=g("div.ilightbox-thumbnails-container",e),h=g("div.ilightbox-thumbnails-grid",f),l=0;h.removeAttr("style").empty();g.each(a.items,function(k,n){var m=b.current==k?"ilightbox-active":"",C=b.current==k?c.thumbnails.activeOpacity:c.thumbnails.normalOpacity,y=n.options.thumbnail,q=g('
    '), u=g('
    ');q.css({opacity:0}).addClass(m);"video"!=n.type&&"flash"!=n.type||"undefined"!=typeof n.options.icon?n.options.icon&&(u.addClass("ilightbox-thumbnail-"+n.options.icon),q.append(u)):(u.addClass("ilightbox-thumbnail-video"),q.append(u));y&&a.loadImage(y,function(b){l++;b?q.data({naturalWidth:b.width,naturalHeight:b.height}).append(''):q.data({naturalWidth:c.thumbnails.maxWidth,naturalHeight:c.thumbnails.maxHeight});clearTimeout(d); d=setTimeout(function(){a.positionThumbnails(e,f,h)},20);setTimeout(function(){q.fadeTo(c.effects.loadedFadeSpeed,C)},20*l)});h.append(q)});a.vars.dontGenerateThumbs=!0}},positionThumbnails:function(a,b,c){var d=this,e=d.vars,f=d.options,h=J(),l=f.path.toLowerCase();a||(a=e.thumbnails);b||(b=g("div.ilightbox-thumbnails-container",a));c||(c=g("div.ilightbox-thumbnails-grid",b));var k=g(".ilightbox-thumbnail",c);e="horizontal"==l?h.width-f.styles.pageOffsetX:k.eq(0).outerWidth()-f.styles.pageOffsetX; h="horizontal"==l?k.eq(0).outerHeight()-f.styles.pageOffsetY:h.height-f.styles.pageOffsetY;var n="horizontal"==l?0:e,m="horizontal"==l?h:0,C=g(".ilightbox-active",c),y={};3>arguments.length&&(k.css({opacity:f.thumbnails.normalOpacity}),C.css({opacity:f.thumbnails.activeOpacity}));k.each(function(a){a=g(this);var b=a.data(),c="horizontal"==l?0:f.thumbnails.maxWidth;height="horizontal"==l?f.thumbnails.maxHeight:0;dims=d.getNewDimenstions(c,height,b.naturalWidth,b.naturalHeight,!0);a.css({width:dims.width, height:dims.height});"horizontal"==l&&a.css({"float":"left"});"horizontal"==l?n+=a.outerWidth():m+=a.outerHeight()});y={width:n,height:m};c.css(y);y={};k=c.offset();var q=C.length?C.offset():{top:parseInt(h/2),left:parseInt(e/2)};k.top-=E.scrollTop();k.left-=E.scrollLeft();q.top=q.top-k.top-E.scrollTop();q.left=q.left-k.left-E.scrollLeft();"horizontal"==l?(y.top=0,y.left=parseInt(e/2-q.left-C.outerWidth()/2)):(y.top=parseInt(h/2-q.top-C.outerHeight()/2),y.left=0);3>arguments.length?c.stop().animate(y, f.effects.repositionSpeed,"easeOutCirc"):c.css(y)},loadImage:function(a,b){g.isArray(a)||(a=[a]);var c=this,d=a.length;0d?b.moveTo("next"):0x.time-w.time&&I(w.coords[0]-x.coords[0])>l&&I(w.coords[1]-x.coords[1])x.coords[0]?c.current!=c.total-1||d.infinite?(c.isSwipe=!0,b.moveTo("next")): q():0!=c.current||d.infinite?(c.isSwipe=!0,b.moveTo("prev")):q():"vertical"==e&&1E3>x.time-w.time&&I(w.coords[1]-x.coords[1])>l&&I(w.coords[0]-x.coords[0])x.coords[1]?c.current!=c.total-1||d.infinite?(c.isSwipe=!0,b.moveTo("next")):q():0!=c.current||d.infinite?(c.isSwipe=!0,b.moveTo("prev")):q():q());w=x=Q})}})},goTo:function(a){var b=this,c=b.vars,d=b.options,e=a-c.current;d.infinite&&(a==c.total-1&&0==c.current&&(e=-1),c.current==c.total-1&&0==a&&(e=1));if(1==e)b.moveTo("next");else if(-1==e)b.moveTo("prev");else{if(c.nextLock||c.prevLock)return!1;"function"==typeof d.callback.onBeforeChange&&d.callback.onBeforeChange.call(b,b.ui);d.linkId&&(c.hashLock=!0,p.location.hash=d.linkId+"/"+a);b.items[a]&&(b.items[a].options.mousewheel?b.vars.lockWheel=!1:c.lockWheel=!0,c.lockSwipe=b.items[a].options.swipe?!1:!0);g.each([c.holder,c.nextPhoto,c.prevPhoto],function(a,b){b.css(B,H).fadeOut(d.effects.loadedFadeSpeed)});c.current=a;c.next=a+1;c.prev=a-1;b.createUI(); setTimeout(function(){b.generateBoxes()},d.effects.loadedFadeSpeed+50);g(".ilightbox-thumbnail",c.thumbnails).removeClass("ilightbox-active").eq(a).addClass("ilightbox-active");b.positionThumbnails();d.linkId&&setTimeout(function(){c.hashLock=!1},55);d.infinite||(c.nextButton.add(c.prevButton).add(c.innerPrevButton).add(c.innerNextButton).removeClass("disabled"),0==c.current&&c.prevButton.add(c.innerPrevButton).addClass("disabled"),c.current>=c.total-1&&c.nextButton.add(c.innerNextButton).addClass("disabled")); b.resetCycle();"function"==typeof d.callback.onAfterChange&&d.callback.onAfterChange.call(b,b.ui)}},moveTo:function(a){var b=this,c=b.vars,d=b.options,e=d.path.toLowerCase(),f=J(),h=d.effects.switchSpeed;if(c.nextLock||c.prevLock)return!1;var l="next"==a?c.next:c.prev;d.linkId&&(c.hashLock=!0,p.location.hash=d.linkId+"/"+l);if("next"==a){if(!b.items[l])return!1;var k=c.nextPhoto,n=c.holder,m=c.prevPhoto,C="ilightbox-prev",y="ilightbox-next"}else if("prev"==a){if(!b.items[l])return!1;k=c.prevPhoto; n=c.holder;m=c.nextPhoto;C="ilightbox-next";y="ilightbox-prev"}"function"==typeof d.callback.onBeforeChange&&d.callback.onBeforeChange.call(b,b.ui);"next"==a?c.nextLock=!0:c.prevLock=!0;var q=g("div.ilightbox-caption",n),u=g("div.ilightbox-social",n);q.length&&q.stop().fadeOut(h,function(){g(this).remove()});u.length&&u.stop().fadeOut(h,function(){g(this).remove()});b.items[l].caption&&(b.setCaption(b.items[l],k),q=g("div.ilightbox-caption",k),u=parseInt(q.outerHeight()/k.outerHeight()*100),d.caption.start&& 50>=u&&q.fadeIn(h));if(q=b.items[l].options.social)b.setSocial(q,b.items[l].URL,k),d.social.start&&g("div.ilightbox-social",k).fadeIn(d.effects.fadeSpeed);g.each([k,n,m],function(a,b){b.removeClass("ilightbox-next ilightbox-prev")});var v=k.data("offset");q=f.width-d.styles.pageOffsetX;f=f.height-d.styles.pageOffsetY;u=v.newDims.width;var r=v.newDims.height,t=v.thumbsOffset;v=v.diff;var w=parseInt(f/2-r/2-v.H-t.H/2);v=parseInt(q/2-u/2-v.W-t.W/2);k.css(B,H).animate({top:w,left:v,opacity:1},h,c.isSwipe? "easeOutCirc":"easeInOutCirc",function(){k.css(B,"")});g("div.ilightbox-container",k).animate({width:u,height:r},h,c.isSwipe?"easeOutCirc":"easeInOutCirc");r=n.data("offset");var x=r.object;v=r.diff;u=r.newDims.width;r=r.newDims.height;u=parseInt(u*d.styles["next"==a?"prevScale":"nextScale"]);r=parseInt(r*d.styles["next"==a?"prevScale":"nextScale"]);w="horizontal"==e?parseInt(f/2-x.offsetY-r/2-v.H-t.H/2):parseInt(f-x.offsetX-v.H-t.H/2);"prev"==a?v="horizontal"==e?parseInt(q-x.offsetX-v.W-t.W/2):parseInt(q/ 2-u/2-v.W-x.offsetY-t.W/2):(w="horizontal"==e?w:parseInt(x.offsetX-v.H-r-t.H/2),v="horizontal"==e?parseInt(x.offsetX-v.W-u-t.W/2):parseInt(q/2-x.offsetY-u/2-v.W-t.W/2));g("div.ilightbox-container",n).animate({width:u,height:r},h,c.isSwipe?"easeOutCirc":"easeInOutCirc");n.addClass(C).css(B,H).animate({top:w,left:v,opacity:d.styles.prevOpacity},h,c.isSwipe?"easeOutCirc":"easeInOutCirc",function(){n.css(B,"");g(".ilightbox-thumbnail",c.thumbnails).removeClass("ilightbox-active").eq(l).addClass("ilightbox-active"); b.positionThumbnails();b.items[l]&&(c.lockWheel=b.items[l].options.mousewheel?!1:!0,c.lockSwipe=b.items[l].options.swipe?!1:!0);c.isSwipe=!1;-1!==["iframe","video"].indexOf(b.items[c.current].type)&&g("div.ilightbox-container",n).empty();"next"==a?(c.nextPhoto=m,c.prevPhoto=n,c.holder=k,c.nextPhoto.hide(),c.next+=1,c.prev=c.current,c.current+=1,d.infinite&&(c.current>c.total-1&&(c.current=0),c.current==c.total-1&&(c.next=0),0==c.current&&(c.prev=c.total-1)),b.createUI(),b.items[c.next]?b.loadContent(b.items[c.next], "next"):c.nextLock=!1):(c.prevPhoto=m,c.nextPhoto=n,c.holder=k,c.prevPhoto.hide(),c.next=c.current,c.current=c.prev,c.prev=c.current-1,d.infinite&&(c.current==c.total-1&&(c.next=0),0==c.current&&(c.prev=c.total-1)),b.createUI(),b.items[c.prev]?b.loadContent(b.items[c.prev],"prev"):c.prevLock=!1);-1!==["iframe","video"].indexOf(b.items[c.current].type)&&b.loadContent(b.items[c.current],"current");d.linkId&&setTimeout(function(){c.hashLock=!1},55);d.infinite||(c.nextButton.add(c.prevButton).add(c.innerPrevButton).add(c.innerNextButton).removeClass("disabled"), 0==c.current&&c.prevButton.add(c.innerPrevButton).addClass("disabled"),c.current>=c.total-1&&c.nextButton.add(c.innerNextButton).addClass("disabled"));b.repositionPhoto();b.resetCycle();"function"==typeof d.callback.onAfterChange&&d.callback.onAfterChange.call(b,b.ui)});w="horizontal"==e?F(m,"top"):"next"==a?parseInt(-(f/2)-m.outerHeight()):parseInt(2*w);v="horizontal"==e?"next"==a?parseInt(-(q/2)-m.outerWidth()):parseInt(2*v):F(m,"left");m.css(B,H).animate({top:w,left:v,opacity:d.styles.nextOpacity}, h,c.isSwipe?"easeOutCirc":"easeInOutCirc",function(){m.css(B,"")}).addClass(y)},setCaption:function(a,b){var c=g('
    ');a.caption&&(c.html(a.caption),g("div.ilightbox-container",b).append(c))},normalizeSocial:function(a,b){var c=this.options,d=p.location.href;g.each(a,function(e,f){if(!f)return!0;switch(e.toLowerCase()){case "facebook":var h="http://www.facebook.com/share.php?v=4&src=bm&u={URL}";var g="Share on Facebook";break;case "twitter":h="http://twitter.com/home?status={URL}"; g="Share on Twitter";break;case "googleplus":h="https://plus.google.com/share?url={URL}";g="Share on Google+";break;case "delicious":h="http://delicious.com/post?url={URL}";g="Share on Delicious";break;case "digg":h="http://digg.com/submit?phase=2&url={URL}";g="Share on Digg";break;case "reddit":h="http://reddit.com/submit?url={URL}",g="Share on reddit"}a[e]={URL:f.URL&&N(d,f.URL)||c.linkId&&p.location.href||"string"!==typeof b&&d||b&&N(d,b)||d,source:f.source||h||f.URL&&N(d,f.URL)||b&&N(d,b),text:f.text|| g||"Share on "+e,width:"undefined"==typeof f.width||isNaN(f.width)?640:parseInt(f.width),height:f.height||360}});return a},setSocial:function(a,b,c){var d=g('
    '),e="
      ";a=this.normalizeSocial(a,b);g.each(a,function(a,b){a.toLowerCase();var c=b.source.replace(/\{URL\}/g,encodeURIComponent(b.URL).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A").replace(/%20/g,"+"));e+='
    • '});e+="
    ";d.html(e);g("div.ilightbox-container",c).append(d)},fullScreenAction:function(){t.supportsFullScreen?t.isFullScreen()?t.cancelFullScreen(document.documentElement):t.requestFullScreen(document.documentElement):this.doFullscreen()},doFullscreen:function(){var a=this.vars,b=J(),c=this.options; if(c.fullAlone){var d=a.holder,e=this.items[a.current],f=b.width,h=b.height,l=[d,a.nextPhoto,a.prevPhoto,a.nextButton,a.prevButton,a.overlay,a.toolbar,a.thumbnails,a.loader];b=[a.nextPhoto,a.prevPhoto,a.nextButton,a.prevButton,a.loader,a.thumbnails];if(a.isInFullScreen)a.isInFullScreen=a.lockKey=a.lockWheel=a.lockSwipe=!1,a.overlay.css({opacity:this.options.overlay.opacity}),g.each(b,function(a,b){b.show()}),a.fullScreenButton.attr("title",c.text.enterFullscreen),d.data({naturalWidth:d.data("naturalWidthOld"), naturalHeight:d.data("naturalHeightOld"),naturalWidthOld:null,naturalHeightOld:null}),g.each(l,function(a,b){b.removeClass("ilightbox-fullscreen")}),"function"==typeof c.callback.onExitFullScreen&&c.callback.onExitFullScreen.call(this,this.ui);else{a.isInFullScreen=a.lockKey=a.lockWheel=a.lockSwipe=!0;a.overlay.css({opacity:1});g.each(b,function(a,b){b.hide()});a.fullScreenButton.attr("title",c.text.exitFullscreen);if(-1!=c.fullStretchTypes.indexOf(e.type))d.data({naturalWidthOld:d.data("naturalWidth"), naturalHeightOld:d.data("naturalHeight"),naturalWidth:f,naturalHeight:h});else{b=e.options.fullViewPort||c.fullViewPort||"";a=f;e=h;f=d.data("naturalWidth");var k=d.data("naturalHeight");"fill"==b.toLowerCase()?(e=a/f*k,ea||k>e?!0:!1),a=h.width,e=h.height);d.data({naturalWidthOld:d.data("naturalWidth"),naturalHeightOld:d.data("naturalHeight"), naturalWidth:a,naturalHeight:e})}g.each(l,function(a,b){b.addClass("ilightbox-fullscreen")});"function"==typeof c.callback.onEnterFullScreen&&c.callback.onEnterFullScreen.call(this,this.ui)}}else a.isInFullScreen=a.isInFullScreen?!1:!0;this.repositionPhoto(!0)},closeAction:function(){var a=this.vars,b=this.options;O.unbind(".iLightBox");E.off(".iLightBox");a.isInFullScreen&&t.cancelFullScreen(document.documentElement);g(".ilightbox-overlay, .ilightbox-holder, .ilightbox-thumbnails").off(".iLightBox"); b.hide.effect?a.overlay.stop().fadeOut(b.hide.speed,function(){a.overlay.remove();a.BODY.removeClass("ilightbox-noscroll").off(".iLightBox")}):(a.overlay.remove(),a.BODY.removeClass("ilightbox-noscroll").off(".iLightBox"));g.each([a.toolbar,a.holder,a.nextPhoto,a.prevPhoto,a.nextButton,a.prevButton,a.loader,a.thumbnails],function(a,b){b.removeAttr("style").remove()});a.dontGenerateThumbs=a.isInFullScreen=!1;p.iLightBox=null;b.linkId&&(a.hashLock=!0,ia(),setTimeout(function(){a.hashLock=!1},55));"function"==typeof b.callback.onHide&&b.callback.onHide.call(this,this.ui)},repositionPhoto:function(){var a=this.vars,b=this.options,c=b.path.toLowerCase(),d=J(),e=d.width,f=d.height;d=a.isInFullScreen&&b.fullAlone||a.isMobile?0:"horizontal"==c?0:a.thumbnails.outerWidth();var h=a.isMobile?a.toolbar.outerHeight():a.isInFullScreen&&b.fullAlone?0:"horizontal"==c?a.thumbnails.outerHeight():0;e=a.isInFullScreen&&b.fullAlone?e:e-b.styles.pageOffsetX;f=a.isInFullScreen&&b.fullAlone?f:f-b.styles.pageOffsetY;var l="horizontal"==c?parseInt(this.items[a.next]||this.items[a.prev]?2*(b.styles.nextOffsetX+b.styles.prevOffsetX):30>=e/10?30:e/10):parseInt(30>=e/10?30:e/10)+d,k="horizontal"==c?parseInt(30>=f/10?30:f/10)+h:parseInt(this.items[a.next]||this.items[a.prev]?2*(b.styles.nextOffsetX+b.styles.prevOffsetX):30>=f/10?30:f/10);d={type:"current",width:e,height:f,item:this.items[a.current],offsetW:l,offsetH:k,thumbsOffsetW:d,thumbsOffsetH:h,animate:arguments.length,holder:a.holder};this.repositionEl(d);this.items[a.next]&&(d= g.extend(d,{type:"next",item:this.items[a.next],offsetX:b.styles.nextOffsetX,offsetY:b.styles.nextOffsetY,holder:a.nextPhoto}),this.repositionEl(d));this.items[a.prev]&&(d=g.extend(d,{type:"prev",item:this.items[a.prev],offsetX:b.styles.prevOffsetX,offsetY:b.styles.prevOffsetY,holder:a.prevPhoto}),this.repositionEl(d));b="horizontal"==c?{left:parseInt(e/2-a.loader.outerWidth()/2)}:{top:parseInt(f/2-a.loader.outerHeight()/2)};a.loader.css(b)},repositionEl:function(a){var b=this.vars,c=this.options, d=c.path.toLowerCase(),e="current"==a.type?b.isInFullScreen&&c.fullAlone?a.width:a.width-a.offsetW:a.width-a.offsetW,f="current"==a.type?b.isInFullScreen&&c.fullAlone?a.height:a.height-a.offsetH:a.height-a.offsetH,h=a.item,l=a.item.options,k=a.holder,n=a.offsetX||0,m=a.offsetY||0,p=a.thumbsOffsetW,r=a.thumbsOffsetH;"current"==a.type?("number"==typeof l.width&&l.width&&(e=b.isInFullScreen&&c.fullAlone&&(-1!=c.fullStretchTypes.indexOf(h.type)||l.fullViewPort||c.fullViewPort)?e:l.width>e?e:l.width), "number"==typeof l.height&&l.height&&(f=b.isInFullScreen&&c.fullAlone&&(-1!=c.fullStretchTypes.indexOf(h.type)||l.fullViewPort||c.fullViewPort)?f:l.height>f?f:l.height)):("number"==typeof l.width&&l.width&&(e=l.width>e?e:l.width),"number"==typeof l.height&&l.height&&(f=l.height>f?f:l.height));c.innerToolbar&&(f=parseInt(f-g(".ilightbox-inner-toolbar",k).outerHeight()));b="string"==typeof l.width&&-1!=l.width.indexOf("%")?ba(parseInt(l.width.replace("%","")),a.width):k.data("naturalWidth");h="string"==typeof l.height&&-1!=l.height.indexOf("%")?ba(parseInt(l.height.replace("%","")),a.height):k.data("naturalHeight");h="string"==typeof l.width&&-1!=l.width.indexOf("%")||"string"==typeof l.height&&-1!=l.height.indexOf("%")?{width:b,height:h}:this.getNewDimenstions(e,f,b,h);e=g.extend({},h,{});"prev"==a.type||"next"==a.type?(b=parseInt(h.width*("next"==a.type?c.styles.nextScale:c.styles.prevScale)),h=parseInt(h.height*("next"==a.type?c.styles.nextScale:c.styles.prevScale))):(b=h.width,h=h.height);f= parseInt((F(k,"padding-left")+F(k,"padding-right")+F(k,"border-left-width")+F(k,"border-right-width"))/2);l=parseInt((F(k,"padding-top")+F(k,"padding-bottom")+F(k,"border-top-width")+F(k,"border-bottom-width")+(g(".ilightbox-inner-toolbar",k).outerHeight()||0))/2);switch(a.type){case "current":var q=parseInt(a.height/2-h/2-l-r/2),u=parseInt(a.width/2-b/2-f-p/2);break;case "next":q="horizontal"==d?parseInt(a.height/2-m-h/2-l-r/2):parseInt(a.height-n-l-r/2);u="horizontal"==d?parseInt(a.width-n-f-p/ 2):parseInt(a.width/2-b/2-f-m-p/2);break;case "prev":q="horizontal"==d?parseInt(a.height/2-m-h/2-l-r/2):parseInt(n-l-h-r/2),u="horizontal"==d?parseInt(n-f-b-p/2):parseInt(a.width/2-m-b/2-f-p/2)}k.data("offset",{top:q,left:u,newDims:e,diff:{W:f,H:l},thumbsOffset:{W:p,H:r},object:a});0=c.total||athis.options.maxScale?factor=this.options.maxScale:factor",{width:"100%",height:"100%",preload:e.preload,autoplay:e.autoplay,poster:e.poster,controls:e.controls}).append(g("",{src:b.URL,type:d}));else this.plugins.quicktime? (f=g("",{type:"video/quicktime",pluginspage:"http://www.apple.com/quicktime/download"}).attr({data:b.URL,width:"100%",height:"100%"}).append(g("",{name:"src",value:b.URL})).append(g("",{name:"autoplay",value:"false"})).append(g("",{name:"loop",value:"false"})).append(g("",{name:"scale",value:"tofit"})),D.msie&&(f=ma(b.URL,"100%","100%","","SCALE","tofit","AUTOPLAY","false","LOOP","false"))):f=g("",{"class":"ilightbox-alert",html:this.options.errors.missingPlugin.replace("{pluginspage}", "http://www.apple.com/quicktime/download").replace("{type}","QuickTime")});break;case "flash":if(this.plugins.flash){var h="",l=0;b.options.flashvars?g.each(b.options.flashvars,function(a,b){0!=l&&(h+="&");h+=a+"="+encodeURIComponent(b);l++}):h=null;f=g("").attr({type:"application/x-shockwave-flash",src:b.URL,width:"number"==typeof b.options.width&&b.options.width&&"1"==this.options.minScale&&"1"==this.options.maxScale?b.options.width:"100%",height:"number"==typeof b.options.height&&b.options.height&& "1"==this.options.minScale&&"1"==this.options.maxScale?b.options.height:"100%",quality:"high",bgcolor:"#000000",play:"true",loop:"true",menu:"true",wmode:"transparent",scale:"showall",allowScriptAccess:"always",allowFullScreen:"true",flashvars:h,fullscreen:"yes"})}else f=g("",{"class":"ilightbox-alert",html:this.options.errors.missingPlugin.replace("{pluginspage}","http://www.adobe.com/go/getflash").replace("{type}","Adobe Flash player")});break;case "iframe":f=g("