text: /*! ET custom.js */
  (function($){window.et_calculating_scroll_position=false;window.et_side_nav_links_initialized=false;var $et_pb_post_fullwidth=$('.single.et_pb_pagebuilder_layout.et_full_width_page'),et_is_mobile_device=navigator.userAgent.match(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/),et_is_ipad=navigator.userAgent.match(/iPad/),$et_container=$('.container'),et_container_width=$et_container.width(),et_is_fixed_nav=$('body').hasClass('et_fixed_nav')||$('body').hasClass('et_vertical_fixed'),et_is_vertical_fixed_nav=$('body').hasClass('et_vertical_fixed'),et_is_rtl=$('body').hasClass('rtl'),et_hide_nav=$('body').hasClass('et_hide_nav'),et_header_style_left=$('body').hasClass('et_header_style_left'),$top_header=$('#top-header'),$main_header=$('#main-header'),$main_container_wrapper=$('#page-container'),$et_main_content_first_row=$('#main-content .container:first-child'),$et_main_content_first_row_meta_wrapper=$et_main_content_first_row.find('.et_post_meta_wrapper:first'),$et_main_content_first_row_meta_wrapper_title=$et_main_content_first_row_meta_wrapper.find('h1.entry-title'),$et_main_content_first_row_content=$et_main_content_first_row.find('.entry-content:first'),$et_single_post=$('body.single'),$et_window=$(window),etRecalculateOffset=false,et_header_height,et_header_modifier,et_header_offset,et_primary_header_top,$et_header_style_split=$('.et_header_style_split'),$et_top_navigation=$('#et-top-navigation'),$logo=$('#logo'),$et_pb_first_row=$('body.et_pb_pagebuilder_layout .et_pb_section:visible:first'),et_is_touch_device='ontouchstart'in window||navigator.maxTouchPoints,$et_top_cart=$('#et-secondary-menu a.et-cart-info');function et_preload_image(src,callback){var img=new Image();img.onLoad=callback;img.onload=callback;img.src=src;}
  if($(".woocommerce .woocommerce-product-gallery").length>0){var gal=$(".woocommerce-product-gallery")[0];var newstr=gal.outerHTML.replace('data-columns','data-cols');gal.outerHTML=newstr;}
  if($et_top_cart.length>0&&$('.shop_table.cart').length>0){$(document.body).on('updated_wc_div',function(){var new_total=0;var new_text;$('.shop_table.cart').find('.product-quantity input').each(function(){new_total=new_total+parseInt($(this).val());});if(new_total===1){new_text=DIVI.item_count;}else{new_text=DIVI.items_count;}
  new_text=new_text.replace('%d',new_total);$et_top_cart.find('span').text(new_text);});}
  $(document).ready(function(){var $et_top_menu=$('ul.nav, ul.menu'),$et_search_icon=$('#et_search_icon'),et_parent_menu_longpress_limit=300,et_parent_menu_longpress_start,et_parent_menu_click=true,is_customize_preview=$('body').hasClass('et_is_customize_preview');window.et_pb_init_nav_menu($et_top_menu);function et_header_menu_split(){var $logo_container=$('#main-header > .container > .logo_container'),$logo_container_splitted=$('.centered-inline-logo-wrap > .logo_container'),et_top_navigation_li_size=$et_top_navigation.children('nav').children('ul').children('li').size(),et_top_navigation_li_break_index=Math.round(et_top_navigation_li_size/2)-1,window_width=window.innerWidth||$et_window.width();if(window_width>980&&$logo_container.length&&$('body').hasClass('et_header_style_split')){$('<li class="centered-inline-logo-wrap"></li>').insertAfter($et_top_navigation.find('nav > ul >li:nth('+et_top_navigation_li_break_index+')'));$logo_container.appendTo($et_top_navigation.find('.centered-inline-logo-wrap'));}
  if(window_width<=980&&$logo_container_splitted.length){$logo_container_splitted.prependTo('#main-header > .container');$('#main-header .centered-inline-logo-wrap').remove();}}
  function et_set_right_vertical_menu(){var $body=$('body');if($body.hasClass('et_boxed_layout')&&$body.hasClass('et_vertical_fixed')&&$body.hasClass('et_vertical_right')){var header_offset=parseFloat($('#page-container').css('margin-right'));header_offset+=(parseFloat($('#et-main-area').css('margin-right'))-225);header_offset=0>header_offset?0:header_offset;$('#main-header').addClass('et_vertical_menu_set').css({'left':'','right':header_offset});}}
  if(($et_header_style_split.length&&!window.et_is_vertical_nav)||is_customize_preview){et_header_menu_split();$(window).resize(function(){et_header_menu_split();});}
  if($('ul.et_disable_top_tier').length){$("ul.et_disable_top_tier > li > ul").prev('a').attr('href','#');}
  if(window.et_is_vertical_nav){if($('#main-header').height()<$('#et-top-navigation').height()){$('#main-header').height($('#et-top-navigation').height()+$('#logo').height()+100);}
  et_set_right_vertical_menu();}
  window.et_calculate_header_values=function(){var $top_header=$('#top-header'),secondary_nav_height=$top_header.length&&$top_header.is(':visible')?parseInt($top_header.innerHeight()):0,admin_bar_height=$('#wpadminbar').length?parseInt($('#wpadminbar').innerHeight()):0,$slide_menu_container=$('.et_header_style_slide .et_slide_in_menu_container');et_header_height=parseInt($('#main-header').innerHeight())+secondary_nav_height;et_header_modifier=et_header_height<=90?et_header_height-29:et_header_height-56;et_header_offset=et_header_modifier+admin_bar_height;et_primary_header_top=secondary_nav_height+admin_bar_height;if($slide_menu_container.length&&!$('body').hasClass('et_pb_slide_menu_active')){$slide_menu_container.css({right:'-'+parseInt($slide_menu_container.innerWidth())+'px','display':'none'});if($('body').hasClass('et_boxed_layout')){var page_container_margin=$main_container_wrapper.css('margin-left');$main_header.css({left:page_container_margin});}}};var $comment_form=$('#commentform');et_pb_form_placeholders_init($comment_form);$comment_form.submit(function(){et_pb_remove_placeholder_text($comment_form);});et_duplicate_menu($('#et-top-navigation ul.nav'),$('#et-top-navigation .mobile_nav'),'mobile_menu','et_mobile_menu');et_duplicate_menu('',$('.et_pb_fullscreen_nav_container'),'mobile_menu_slide','et_mobile_menu','no_click_event');if($('#et-secondary-nav').length){$('#et-top-navigation #mobile_menu').append($('#et-secondary-nav').clone().html());}
  if($('.et_slide_in_menu_container').length){var $item_with_sub=$('.et_slide_in_menu_container').find('.menu-item-has-children > a');if($item_with_sub.length){$item_with_sub.append('<span class="et_mobile_menu_arrow"></span>');}}
  function et_change_primary_nav_position(delay){setTimeout(function(){var $body=$('body'),$wpadminbar=$('#wpadminbar'),$top_header=$('#top-header'),et_primary_header_top=0;if($wpadminbar.length){et_primary_header_top+=$wpadminbar.innerHeight();}
  if($top_header.length&&$top_header.is(':visible')){et_primary_header_top+=$top_header.innerHeight();}
  if(!window.et_is_vertical_nav&&($body.hasClass('et_fixed_nav'))){$('#main-header').css('top',et_primary_header_top);}},delay);}
  function et_hide_nav_transform(){var $body=$('body'),$body_height=$(document).height(),$viewport_height=$(window).height()+et_header_height+200;if($body.hasClass('et_hide_nav')||$body.hasClass('et_hide_nav_disabled')&&($body.hasClass('et_fixed_nav'))){if($body_height>$viewport_height){if($body.hasClass('et_hide_nav_disabled')){$body.addClass('et_hide_nav');$body.removeClass('et_hide_nav_disabled');}
  $('#main-header').css('transform','translateY(-'+et_header_height+'px)');$('#top-header').css('transform','translateY(-'+et_header_height+'px)');}else{$('#main-header').css({'transform':'translateY(0)','opacity':'1'});$('#top-header').css({'transform':'translateY(0)','opacity':'1'});$body.removeClass('et_hide_nav');$body.addClass('et_hide_nav_disabled');}
  et_fix_page_container_position();}}
  function et_save_initial_page_container_style($selector,property){var styling={};styling[property]=$selector.css(property);$selector.attr({'data-fix-page-container':'on'}).data({'fix_page_container_style':styling});}
  function et_page_load_scroll_to_anchor(){if($(window.et_location_hash).length===0){return;}
  var $map_container=$(window.et_location_hash+' .et_pb_map_container'),$map=$map_container.children('.et_pb_map'),$target=$(window.et_location_hash);$target.css('display',window.et_location_hash_style);var distance=('undefined'!==typeof($target.offset().top))?$target.offset().top:0,speed=(distance>4000)?1600:800;if($map_container.length){google.maps.event.trigger($map[0],'resize');}
  setTimeout(function(){et_pb_smooth_scroll($target,false,speed,'swing');setTimeout(function(){et_pb_smooth_scroll($target,false,150,'linear');},speed+25);},700);}
  function et_get_saved_padding_margin_value(saved_value,order){if(typeof saved_value==='undefined'){return false;}
  var values=saved_value.split('|');return typeof values[order]!=='undefined'?values[order]:false;}
  function et_fix_page_container_position(){var et_window_width=parseInt($et_window.width()),$top_header=$('#top-header'),$et_pb_first_row=$('body.et_pb_pagebuilder_layout .et_pb_section:visible:first'),secondary_nav_height=$top_header.length&&$top_header.is(':visible')?parseInt($top_header.innerHeight()):0,main_header_fixed_height=0,header_height,et_pb_first_row_padding_top;$('*[data-fix-page-container="on"]').each(function(){var $adjusted_element=$(this),styling=$adjusted_element.data();$adjusted_element.css(styling.fix_page_container_style);});if(et_window_width>980&&!$main_header.attr('data-height-loaded')){$main_header.attr({'data-height-onload':parseInt($main_header.height()),'data-height-loaded':true});}
  if(et_window_width<=980){header_height=parseInt($main_header.innerHeight())+secondary_nav_height-1;if(window.et_is_transparent_nav&&!$et_pb_first_row.length){header_height+=58;}}else{header_height=parseInt($main_header.attr('data-height-onload'))+secondary_nav_height;if(window.et_is_transparent_nav&&!window.et_is_vertical_nav&&$et_main_content_first_row.length){header_height+=58;}
  $main_header.clone().addClass('main-header-clone et-fixed-header').css({opacity:0,position:'fixed',top:'auto',right:0,bottom:0,left:0}).appendTo($('body'));main_header_fixed_height=$('.main-header-clone').height();$('.main-header-clone').remove();}
  $main_header.attr({'data-fixed-height-onload':main_header_fixed_height});if(window.et_is_transparent_nav&&!window.et_is_vertical_nav){$et_pb_first_row.addClass('et_pb_section_first');var is_pb=$et_pb_first_row.length,is_post_pb=is_pb&&$et_single_post.length,is_post_pb_full_layout_has_title=$et_pb_post_fullwidth.length&&$et_main_content_first_row_meta_wrapper_title.length,is_post_pb_full_layout_no_title=$et_pb_post_fullwidth.length&&0===$et_main_content_first_row_meta_wrapper_title.length,is_pb_fullwidth_section_first=$et_pb_first_row.is('.et_pb_fullwidth_section'),is_no_pb_mobile=et_window_width<=980&&$et_main_content_first_row.length;if(is_post_pb&&!(is_post_pb_full_layout_no_title&&is_pb_fullwidth_section_first)){$et_main_content_first_row.css({'paddingTop':''});if(et_window_width<980){header_height+=40;}
  if(is_pb_fullwidth_section_first){$et_pb_first_row.css({'paddingTop':'0'});}
  if(is_post_pb_full_layout_has_title){$et_main_content_first_row_meta_wrapper.css({'paddingTop':header_height});}else if(is_post_pb_full_layout_no_title){et_save_initial_page_container_style($et_pb_first_row,'paddingTop');$et_pb_first_row.css({'paddingTop':header_height});}else{et_save_initial_page_container_style($et_main_content_first_row,'paddingTop');$et_main_content_first_row.css({'paddingTop':header_height});}}else if(is_pb_fullwidth_section_first){var $et_pb_first_row_first_module=$et_pb_first_row.children('.et_pb_module:visible:first');if(is_post_pb_full_layout_no_title&&is_pb_fullwidth_section_first&&et_window_width>980){header_height=header_height-58;}
  if($et_pb_first_row_first_module.is('.et_pb_slider')){var $et_pb_first_row_first_module_slide_image=$et_pb_first_row_first_module.find('.et_pb_slide_image'),$et_pb_first_row_first_module_slide=$et_pb_first_row_first_module.find('.et_pb_slide'),$et_pb_first_row_first_module_slide_container=$et_pb_first_row_first_module.find('.et_pb_slide .et_pb_container'),et_pb_slide_image_margin_top=0-(parseInt($et_pb_first_row_first_module_slide_image.height())/2),et_pb_slide_container_height=0,$et_pb_first_row_first_module_slider_arrow=$et_pb_first_row_first_module.find('.et-pb-slider-arrows a'),et_pb_first_row_slider_arrow_height=$et_pb_first_row_first_module_slider_arrow.height();et_save_initial_page_container_style($et_pb_first_row_first_module_slide,'paddingTop');$et_pb_first_row_first_module_slide.css({'paddingTop':header_height});$et_pb_first_row_first_module_slide_container.css({'min-height':''});et_save_initial_page_container_style($et_pb_first_row_first_module_slide_image,'marginTop');$et_pb_first_row_first_module_slide_image.css({'marginTop':et_pb_slide_image_margin_top});et_save_initial_page_container_style($et_pb_first_row_first_module_slider_arrow,'marginTop');$et_pb_first_row_first_module_slider_arrow.css({'marginTop':((header_height/2)-(et_pb_first_row_slider_arrow_height/2))});var et_pb_first_row_slide_container_height_new=0;$et_pb_first_row_first_module.find('.et_pb_slide').each(function(){var $et_pb_first_row_first_module_slide_item=$(this),$et_pb_first_row_first_module_slide_container=$et_pb_first_row_first_module_slide_item.find('.et_pb_container');$et_pb_first_row_first_module_slide_item.show();$et_pb_first_row_first_module_slide_container.css({'min-height':''});var et_pb_first_row_slide_container_height=$et_pb_first_row_first_module_slide_container.innerHeight();if(et_pb_first_row_slide_container_height_new<et_pb_first_row_slide_container_height){et_pb_first_row_slide_container_height_new=et_pb_first_row_slide_container_height;}
  if($et_pb_first_row_first_module_slide_item.is(':not(".et-pb-active-slide")')){$et_pb_first_row_first_module_slide_item.hide();}});et_save_initial_page_container_style($et_pb_first_row_first_module_slide_container,'min-height');$et_pb_first_row_first_module_slide_container.css({'min-height':et_pb_first_row_slide_container_height_new});}else if($et_pb_first_row_first_module.is('.et_pb_fullwidth_header')){$et_pb_first_row_first_module.removeAttr('style');var et_pb_first_row_first_module_fullwidth_header_padding_top=parseInt($et_pb_first_row_first_module.css('paddingTop'));et_save_initial_page_container_style($et_pb_first_row_first_module,'paddingTop');$et_pb_first_row_first_module.css({'paddingTop':(header_height+et_pb_first_row_first_module_fullwidth_header_padding_top)});}else if($et_pb_first_row_first_module.is('.et_pb_fullwidth_portfolio')){et_save_initial_page_container_style($et_pb_first_row_first_module,'paddingTop');$et_pb_first_row_first_module.css({'paddingTop':header_height});}else if($et_pb_first_row_first_module.is('.et_pb_map_container')){var $et_pb_first_row_map=$et_pb_first_row_first_module.find('.et_pb_map');$et_pb_first_row_map.css({'height':''});$et_pb_first_row_first_module.find('.et_pb_map').css({'height':header_height+parseInt($et_pb_first_row_map.css('height'))});$et_pb_first_row_first_module.addClass('et_beneath_transparent_nav');}else if($et_pb_first_row_first_module.is('.et_pb_fullwidth_menu')){et_save_initial_page_container_style($et_pb_first_row_first_module,'marginTop');$et_pb_first_row_first_module.css({'marginTop':header_height});}else if($et_pb_first_row_first_module.is('.et_pb_fullwidth_code')){var $et_pb_first_row_first_module_code=$et_pb_first_row_first_module;$et_pb_first_row_first_module_code.css({'paddingTop':''});var et_pb_first_row_first_module_code_padding_top=parseInt($et_pb_first_row_first_module_code.css('paddingTop'));et_save_initial_page_container_style($et_pb_first_row_first_module_code,'paddingTop');$et_pb_first_row_first_module_code.css({'paddingTop':header_height+et_pb_first_row_first_module_code_padding_top});}else if($et_pb_first_row_first_module.is('.et_pb_post_title')){var $et_pb_first_row_first_module_title=$et_pb_first_row_first_module;et_save_initial_page_container_style($et_pb_first_row_first_module_title,'paddingTop');$et_pb_first_row_first_module.css({'paddingTop':header_height+50});}else if(!$et_pb_first_row_first_module.length){et_pb_first_row_padding_top=parseFloat($et_pb_first_row.css('paddingTop'));et_save_initial_page_container_style($et_pb_first_row,'paddingTop');if(!$et_pb_first_row.data('is_hide_nav')){$et_pb_first_row.css({'paddingTop':et_pb_first_row_padding_top+header_height});}
  clearTimeout(window.et_fallback_transparent_adjustment_timeout);window.et_fallback_transparent_adjustment_timeout=setTimeout(function(){var is_hide_nav=$('body').hasClass('et_hide_nav')&&$('#main-header').css('transform')!=='matrix(1, 0, 0, 1, 0, 0)';if(is_hide_nav){$et_pb_first_row.css({'paddingTop':''});}else{$et_pb_first_row.css({'paddingTop':et_pb_first_row_padding_top+header_height});}
  $et_pb_first_row.data('is_hide_nav',is_hide_nav);},300)}}else if(is_pb){$et_pb_first_row.css({'paddingTop':''});var saved_custom_padding=$et_pb_first_row.attr('data-padding'),saved_custom_padding_top=et_get_saved_padding_margin_value(saved_custom_padding,0),saved_custom_padding_tablet=$et_pb_first_row.attr('data-padding-tablet'),saved_custom_padding_tablet_top=et_get_saved_padding_margin_value(saved_custom_padding_tablet,0),saved_custom_padding_phone=$et_pb_first_row.attr('data-padding-phone'),saved_custom_padding_phone_top=et_get_saved_padding_margin_value(saved_custom_padding_phone,0),applied_saved_custom_padding;if(saved_custom_padding_top||saved_custom_padding_tablet_top||saved_custom_padding_phone_top){if(et_window_width>980&&saved_custom_padding_top){$et_pb_first_row.css({paddingTop:saved_custom_padding_top});}else if(et_window_width>767&&saved_custom_padding_tablet_top){$et_pb_first_row.css({paddingTop:saved_custom_padding_tablet_top});}else if(saved_custom_padding_phone_top){$et_pb_first_row.css({paddingTop:saved_custom_padding_phone_top});}
  applied_saved_custom_padding=parseInt($et_pb_first_row.css('paddingTop'));$et_pb_first_row.css({paddingTop:(header_height+applied_saved_custom_padding)});}else{et_pb_first_row_padding_top=header_height+parseInt($et_pb_first_row.css('paddingBottom'));et_save_initial_page_container_style($et_pb_first_row,'paddingTop');$et_pb_first_row.css({'paddingTop':et_pb_first_row_padding_top});}}else if(is_no_pb_mobile){$et_main_content_first_row.css({'paddingTop':header_height});}else{$('#main-content .container:first-child').css({'paddingTop':header_height});}
  if(!$('#et_fix_page_container_position').length){$('<style />',{'id':'et_fix_page_container_position','text':'#page-container{ padding-top: 0 !important;}'}).appendTo('head');}}else if(et_is_fixed_nav){$main_container_wrapper.css('paddingTop',header_height);}
  et_change_primary_nav_position(0);}
  $et_container.data('previous-width',$et_container.width());$(window).resize(function(){var window_width=parseInt($et_window.width()),et_container_previous_width=parseInt($et_container.data('previous-width')),et_container_css_width=$et_container.css('width'),et_container_width_in_pixel=(typeof et_container_css_width!=='undefined')?et_container_css_width.substr(-1,1)!=='%':'',et_container_actual_width=(et_container_width_in_pixel)?parseInt($et_container.width()):((parseInt($et_container.width())/100)*window_width),containerWidthChanged=et_container_previous_width!==et_container_actual_width,$slide_menu_container=$('.et_slide_in_menu_container'),page_container_margin;if(et_is_fixed_nav&&containerWidthChanged){if(typeof update_page_container_position!='undefined'){clearTimeout(update_page_container_position);}
  var update_page_container_position=setTimeout(function(){et_fix_page_container_position();if(typeof et_fix_fullscreen_section==='function'){et_fix_fullscreen_section();}},200);$et_container.data('previous-width',et_container_actual_width);}
  if(et_hide_nav){et_hide_nav_transform();}
  if($('#wpadminbar').length&&et_is_fixed_nav&&window_width>=740&&window_width<=782){et_calculate_header_values();et_change_primary_nav_position(0);}
  et_set_search_form_css();if($slide_menu_container.length&&!$('body').hasClass('et_pb_slide_menu_active')){$slide_menu_container.css({right:'-'+parseInt($slide_menu_container.innerWidth())+'px'});if($('body').hasClass('et_boxed_layout')&&et_is_fixed_nav){page_container_margin=$main_container_wrapper.css('margin-left');$main_header.css({left:page_container_margin});}}
  if($slide_menu_container.length&&$('body').hasClass('et_pb_slide_menu_active')){if($('body').hasClass('et_boxed_layout')){var left_position;page_container_margin=parseFloat($main_container_wrapper.css('margin-left'));$main_container_wrapper.css({left:'-'+(parseInt($slide_menu_container.innerWidth())-page_container_margin)+'px'});if(et_is_fixed_nav){left_position=0>parseInt($slide_menu_container.innerWidth())-(page_container_margin*2)?Math.abs($slide_menu_container.innerWidth()-(page_container_margin*2)):'-'+($slide_menu_container.innerWidth()-(page_container_margin*2));if(left_position<parseInt($slide_menu_container.innerWidth())){$main_header.css({left:left_position+'px'});}}}else{$('#page-container, .et_fixed_nav #main-header').css({left:'-'+parseInt($slide_menu_container.innerWidth())+'px'});}}
  if($slide_menu_container.length&&$('body').hasClass('et_header_style_fullscreen')){var top_bar_height=parseInt($slide_menu_container.find('.et_slide_menu_top').innerHeight());$slide_menu_container.css({'padding-top':top_bar_height+20});}
  et_set_right_vertical_menu();});$(window).ready(function(){if($.fn.fitVids){$('#main-content').fitVids({customSelector:"iframe[src^='http://www.hulu.com'], iframe[src^='http://www.dailymotion.com'], iframe[src^='http://www.funnyordie.com'], iframe[src^='https://embed-ssl.ted.com'], iframe[src^='http://embed.revision3.com'], iframe[src^='https://flickr.com'], iframe[src^='http://blip.tv'], iframe[src^='http://www.collegehumor.com']"});}});function et_all_elements_loaded(){if(et_is_fixed_nav){et_calculate_header_values();}
  et_fix_page_container_position();if(window.et_is_minified_js&&window.et_is_transparent_nav&&!window.et_is_vertical_nav){$(window).trigger('resize');}
  if(window.hasOwnProperty('et_location_hash')&&''!==window.et_location_hash){et_page_load_scroll_to_anchor();}
  if(et_header_style_left&&!window.et_is_vertical_nav){$logo_width=parseInt($('#logo').width());if(et_is_rtl){$et_top_navigation.css('padding-right',$logo_width+30);}else{$et_top_navigation.css('padding-left',$logo_width+30);}}
  if($('p.demo_store').length){$('#footer-bottom').css('margin-bottom',$('p.demo_store').innerHeight());}
  if($.fn.waypoint){var $waypoint_selector;if(et_is_vertical_fixed_nav){$waypoint_selector=$('#main-content');$waypoint_selector.waypoint({handler:function(direction){et_fix_logo_transition();if(direction==='down'){$('#main-header').addClass('et-fixed-header');}else{$('#main-header').removeClass('et-fixed-header');}}});}
  if(et_is_fixed_nav){if(window.et_is_transparent_nav&&!window.et_is_vertical_nav&&$et_pb_first_row.length){if($et_pb_first_row.is('.et_pb_fullwidth_section')){$waypoint_selector=$et_pb_first_row.children('.et_pb_module:visible:first');}else{$waypoint_selector=$et_pb_first_row.find('.et_pb_row:visible:first');}
  if(!$waypoint_selector.length){$waypoint_selector=$('body.et_pb_pagebuilder_layout .et_pb_module:visible:first');}}else if(window.et_is_transparent_nav&&!window.et_is_vertical_nav&&$et_main_content_first_row.length){$waypoint_selector=$('#content-area');}else{$waypoint_selector=$('#main-content');}
  var checkIfScrolled=true;setTimeout(function(){checkIfScrolled=false;},0);$waypoint_selector.waypoint({offset:function(){if(etRecalculateOffset){setTimeout(function(){et_calculate_header_values();},200);etRecalculateOffset=false;}
  if(et_hide_nav){return et_header_offset-et_header_height-200;}else{var waypoint_selector_offset=$waypoint_selector.offset();if(waypoint_selector_offset.top<et_header_offset){et_header_offset=0-(et_header_offset-waypoint_selector_offset.top);}
  return et_header_offset;}},handler:function(direction){et_fix_logo_transition();if(direction==='down'){if(checkIfScrolled&&$et_window.scrollTop()===0){return;}
  $main_header.addClass('et-fixed-header');$main_container_wrapper.addClass('et-animated-content');$top_header.addClass('et-fixed-header');if(!et_hide_nav&&!window.et_is_transparent_nav&&!$('.mobile_menu_bar_toggle').is(':visible')){var secondary_nav_height=$top_header.length?parseInt($top_header.height()):0,$clone_header,clone_header_height,fix_padding;$clone_header=$main_header.clone().addClass('et-fixed-header, et_header_clone').css({'transition':'none','display':'none'});clone_header_height=parseInt($clone_header.prependTo('body').height());if(!window.et_is_vertical_nav){fix_padding=parseInt($main_container_wrapper.css('padding-top'))-clone_header_height-secondary_nav_height+1;$main_container_wrapper.css('margin-top',-fix_padding);}
  $('.et_header_clone').remove();}}else{$main_header.removeClass('et-fixed-header');$top_header.removeClass('et-fixed-header');$main_container_wrapper.css('margin-top','-1px');}
  setTimeout(function(){et_set_search_form_css();},400);}});}
  if(et_hide_nav){et_hide_nav_transform();}}}
  $('a[href*="#"]:not([href="#"])').click(function(){var $this_link=$(this),has_closest_smooth_scroll_disabled=$this_link.closest('.et_smooth_scroll_disabled').length,has_closest_woocommerce_tabs=($this_link.closest('.woocommerce-tabs').length&&$this_link.closest('.tabs').length),has_closest_timetable_tab=$this_link.closest('.tt_tabs_navigation').length,has_closest_eab_cal_link=$this_link.closest('.eab-shortcode_calendar-navigation-link').length,has_closest_ee_cart_link=$this_link.closest('.view-cart-lnk').length,has_acomment_reply=$this_link.hasClass('acomment-reply'),is_woocommerce_review_link=$this_link.hasClass('woocommerce-review-link'),disable_scroll=has_closest_smooth_scroll_disabled||has_closest_ee_cart_link||has_closest_woocommerce_tabs||has_closest_eab_cal_link||has_acomment_reply||is_woocommerce_review_link||has_closest_timetable_tab;if((location.pathname.replace(/^\//,'')==this.pathname.replace(/^\//,'')&&location.hostname==this.hostname)&&!disable_scroll){var target=$(this.hash);target=target.length?target:$('[name='+this.hash.slice(1)+']');if(target.length){if($this_link.closest('.et_pb_fullscreen_menu_opened').length>0){et_pb_toggle_fullscreen_menu();}
  et_pb_smooth_scroll(target,false,800);if(!$('#main-header').hasClass('et-fixed-header')&&$('body').hasClass('et_fixed_nav')&&$(window).width()>980){setTimeout(function(){et_pb_smooth_scroll(target,false,40,'linear');},780);}
  return false;}}});window.et_pb_window_side_nav_scroll_init=function(){if(true===window.et_calculating_scroll_position||false===window.et_side_nav_links_initialized){return;}
  window.et_calculating_scroll_position=true;var add_offset=$('body').hasClass('et_fixed_nav')?20:-90;var top_header_height=$('#top-header').length>0?parseInt($('#top-header').height()):0;var main_header_height=$('#main-header').length>0?parseInt($('#main-header').height()):0;var side_offset;if($('#wpadminbar').length>0&&parseInt($(window).width())>600){add_offset+=parseInt($('#wpadminbar').outerHeight());}
  if(window.et_is_vertical_nav){side_offset=top_header_height+add_offset+60;}else{side_offset=top_header_height+main_header_height+add_offset;}
  var window_height=parseInt($(window).height());var scroll_position=parseInt($(window).scrollTop());var document_height=parseInt($(document).height());var at_bottom_of_page=(window_height+scroll_position)===document_height;var total_links=$('.side_nav_item a').length-1;for(var link=0;link<=total_links;link++){var $target_section=$('.et_pb_section:visible:not(.et_pb_section div)').eq(link);var at_top_of_page='undefined'===typeof $target_section.offset();var current_active=$('.side_nav_item a.active').parent().index();var next_active=null;var target_offset=(false===at_top_of_page)?$target_section.offset().top-side_offset:0;if(at_top_of_page){next_active=0;}else if(at_bottom_of_page){next_active=total_links;}else if(scroll_position>=target_offset){next_active=link;}
  if(null!==next_active&&next_active!==current_active){$('.side_nav_item a').removeClass('active');$('a#side_nav_item_id_'+next_active).addClass('active');}}
  window.et_calculating_scroll_position=false;};window.et_pb_side_nav_page_init=function(){var $sections=$('.et_pb_section:visible:not(.et_pb_section div)');var total_sections=$sections.length;var side_nav_offset=parseInt((total_sections*20+40)/2);window.et_side_nav_links_initialized=false;window.et_calculating_scroll_position=false;if(total_sections>1&&$('.et_pb_side_nav_page').length){$('#main-content').append('<ul class="et_pb_side_nav"></ul>');$sections.each(function(index,element){var active_class=(0===index)?'active':'';$('.et_pb_side_nav').append('<li class="side_nav_item"><a href="#" id="side_nav_item_id_'+index+'" class= "'+active_class+'">'+index+'</a></li>');if(total_sections-1===index){window.et_side_nav_links_initialized=true;}});$('ul.et_pb_side_nav').css('marginTop','-'+side_nav_offset+'px');$('.et_pb_side_nav').addClass('et-visible');$('.et_pb_side_nav a').click(function(){var index=parseInt($(this).text());var $target=$('.et_pb_section:visible:not(.et_pb_section div)').eq(index);var top_section=$(this).text()=="0";et_pb_smooth_scroll($target,top_section,800);if(!$('#main-header').hasClass('et-fixed-header')&&$('body').hasClass('et_fixed_nav')&&parseInt($(window).width())>980){setTimeout(function(){et_pb_smooth_scroll($target,top_section,200);},500);}
  return false;});$(window).on('scroll',et_pb_window_side_nav_scroll_init);}};et_pb_side_nav_page_init();if($('.et_pb_scroll_top').length){$(window).scroll(function(){if($(this).scrollTop()>800){$('.et_pb_scroll_top').show().removeClass('et-hidden').addClass('et-visible');}else{$('.et_pb_scroll_top').removeClass('et-visible').addClass('et-hidden');}});$('.et_pb_scroll_top').click(function(){$('html, body').animate({scrollTop:0},800);});}
  if($('.comment-reply-link').length){$('.comment-reply-link').addClass('et_pb_button');}
  $('#et_top_search').click(function(){var $search_container=$('.et_search_form_container');if($search_container.hasClass('et_pb_is_animating')){return;}
  $('.et_menu_container').removeClass('et_pb_menu_visible et_pb_no_animation').addClass('et_pb_menu_hidden');$search_container.removeClass('et_pb_search_form_hidden et_pb_no_animation').addClass('et_pb_search_visible et_pb_is_animating');setTimeout(function(){$('.et_menu_container').addClass('et_pb_no_animation');$search_container.addClass('et_pb_no_animation').removeClass('et_pb_is_animating');},1000);$search_container.find('input').focus();et_set_search_form_css();});function et_hide_search(){if($('.et_search_form_container').hasClass('et_pb_is_animating')){return;}
  $('.et_menu_container').removeClass('et_pb_menu_hidden et_pb_no_animation').addClass('et_pb_menu_visible');$('.et_search_form_container').removeClass('et_pb_search_visible et_pb_no_animation').addClass('et_pb_search_form_hidden et_pb_is_animating');setTimeout(function(){$('.et_menu_container').addClass('et_pb_no_animation');$('.et_search_form_container').addClass('et_pb_no_animation').removeClass('et_pb_is_animating');},1000);}
  function et_set_search_form_css(){var $search_container=$('.et_search_form_container');var $body=$('body');if($search_container.hasClass('et_pb_search_visible')){var header_height=$('#main-header').innerHeight(),menu_width=$('#top-menu').width(),font_size=$('#top-menu li a').css('font-size');$search_container.css({'height':header_height+'px'});$search_container.find('input').css('font-size',font_size);if(!$body.hasClass('et_header_style_left')){$search_container.css('max-width',menu_width+60);}else{$search_container.find('form').css('max-width',menu_width+60);}}}
  $('.et_close_search_field').click(function(){et_hide_search();});$(document).mouseup(function(e){var $header=$('#main-header');if($('.et_menu_container').hasClass('et_pb_menu_hidden')){if(!$header.is(e.target)&&$header.has(e.target).length===0){et_hide_search();}}});function et_define_logo_dimension(){var $logo=$('#logo'),logo_src=$logo.attr('src'),is_svg=logo_src.substr(-3,3)==='svg'?true:false,$logo_wrap,logo_width,logo_height;$('body').append($('<div />',{'id':'et-define-logo-wrap','style':'position: fixed; bottom: 0; opacity: 0;'}));$logo_wrap=$('#et-define-logo-wrap');if(is_svg){$logo_wrap.addClass('svg-logo');}
  $logo_wrap.html($logo.clone().css({'display':'block'}).removeAttr('id'));logo_width=$logo_wrap.find('img').width();logo_height=$logo_wrap.find('img').height();$logo.attr({'data-actual-width':logo_width,'data-actual-height':logo_height});$logo_wrap.remove();et_fix_logo_transition(true);}
  if($('#logo').length){et_preload_image($('#logo').attr('src'),et_define_logo_dimension);}
  $('.footer-widget').each(function(){var $footer_widget=$(this),footer_widget_width=$footer_widget.width(),$adsense_ins=$footer_widget.find('.widget_adsensewidget ins');if($adsense_ins.length){$adsense_ins.width(footer_widget_width);}});function et_fb_side_nav_page_init(){$(window).off('scroll',window.et_pb_window_side_nav_scroll_init);$('#main-content .et_pb_side_nav').off('click','.et_pb_side_nav a');$('#main-content .et_pb_side_nav').remove();et_pb_side_nav_page_init();}
  if($('body').is('.et-fb')){$(window).on('et_fb_root_did_mount',function(){et_fb_side_nav_page_init();et_all_elements_loaded();});$(window).on('et_fb_section_content_change',et_fb_side_nav_page_init);}else{$(window).load(et_all_elements_loaded);}});function et_fix_logo_transition(is_onload){var $body=$('body'),$logo=$('#logo'),logo_actual_width=parseInt($logo.attr('data-actual-width')),logo_actual_height=parseInt($logo.attr('data-actual-height')),logo_height_percentage=parseInt($logo.attr('data-height-percentage')),$top_nav=$('#et-top-navigation'),top_nav_height=parseInt($top_nav.attr('data-height')),top_nav_fixed_height=parseInt($top_nav.attr('data-fixed-height')),$main_header=$('#main-header'),is_header_split=$body.hasClass('et_header_style_split'),is_fixed_nav=$main_header.hasClass('et-fixed-header'),is_hide_primary_logo=$body.hasClass('et_hide_primary_logo'),is_hide_fixed_logo=$body.hasClass('et_hide_fixed_logo'),logo_height_base=is_fixed_nav?top_nav_height:top_nav_fixed_height,logo_wrapper_width,logo_wrapper_height;is_onload=typeof is_onload==='undefined'?false:is_onload;if(is_header_split&&!window.et_is_vertical_nav){if(is_onload){logo_height_base=top_nav_height;}
  logo_wrapper_height=(logo_height_base*(logo_height_percentage/100)+22);logo_wrapper_width=logo_actual_width*(logo_wrapper_height/logo_actual_height);if(is_hide_primary_logo&&(is_fixed_nav||is_onload)){logo_wrapper_width=0;}
  if(is_hide_fixed_logo&&!is_fixed_nav&&!is_onload){logo_wrapper_width=0;}
  $('.et_header_style_split .centered-inline-logo-wrap').css({'width':logo_wrapper_width});}}
  function et_toggle_slide_menu(force_state){var $slide_menu_container=$('.et_header_style_slide .et_slide_in_menu_container'),$page_container=$('.et_header_style_slide #page-container, .et_header_style_slide.et_fixed_nav #main-header'),$header_container=$('.et_header_style_slide #main-header'),is_menu_opened=$slide_menu_container.hasClass('et_pb_slide_menu_opened'),set_to=typeof force_state!=='undefined'?force_state:'auto',is_boxed_layout=$('body').hasClass('et_boxed_layout'),page_container_margin=is_boxed_layout?parseFloat($('#page-container').css('margin-left')):0,slide_container_width=$slide_menu_container.innerWidth();if('auto'!==set_to&&((is_menu_opened&&'open'===set_to)||(!is_menu_opened&&'close'===set_to))){return;}
  if(is_menu_opened){$slide_menu_container.css({right:'-'+slide_container_width+'px'});$page_container.css({left:'0'});if(is_boxed_layout&&et_is_fixed_nav){$header_container.css({left:page_container_margin+'px'});}
  setTimeout(function(){$slide_menu_container.css({'display':'none'});},700);}else{$slide_menu_container.css({'display':'block'});setTimeout(function(){$slide_menu_container.css({right:'0'});$page_container.css({left:'-'+(slide_container_width-page_container_margin)+'px'});if(is_boxed_layout&&et_is_fixed_nav){var left_position=0>slide_container_width-(page_container_margin*2)?Math.abs(slide_container_width-(page_container_margin*2)):'-'+(slide_container_width-(page_container_margin*2));if(left_position<slide_container_width){$header_container.css({left:left_position+'px'});}}},50);}
  $('body').toggleClass('et_pb_slide_menu_active');$slide_menu_container.toggleClass('et_pb_slide_menu_opened');}
  function et_adjust_woocommerce_checkout_scroll(){if(!et_is_fixed_nav){return;}
  var window_width=parseInt($et_window.width());if(980>=window_width){return;}
  var headerHeight=parseInt($('#main-header').innerHeight());$('html, body').animate({scrollTop:($('form.checkout').offset().top-100-headerHeight)},1000);}
  $('#main-header').on('click','.et_toggle_slide_menu',function(){et_toggle_slide_menu();});if(et_is_touch_device){$et_window.on('swipeleft',function(event){var window_width=parseInt($et_window.width()),swipe_start=parseInt(event.swipestart.coords[0]);if(30>=window_width-swipe_start){et_toggle_slide_menu('open');}});$et_window.on('swiperight',function(event){if($('body').hasClass('et_pb_slide_menu_active')){et_toggle_slide_menu('close');}});}
  $('#page-container').on('click','.et_toggle_fullscreen_menu',function(){et_pb_toggle_fullscreen_menu();});function et_pb_toggle_fullscreen_menu(){var $menu_container=$('.et_header_style_fullscreen .et_slide_in_menu_container'),top_bar_height=$menu_container.find('.et_slide_menu_top').innerHeight();$menu_container.toggleClass('et_pb_fullscreen_menu_opened');$('body').toggleClass('et_pb_fullscreen_menu_active');if($menu_container.hasClass('et_pb_fullscreen_menu_opened')){$menu_container.addClass('et_pb_fullscreen_menu_animated');$menu_container.css({'padding-top':top_bar_height+20});}else{setTimeout(function(){$menu_container.removeClass('et_pb_fullscreen_menu_animated');},1000);}}
  $(window).unload(function(){if($('body').hasClass('et_pb_fullscreen_menu_active')){$('.et_toggle_fullscreen_menu').trigger('click');}});$('.et_pb_fullscreen_nav_container').on('click','li.menu-item-has-children > a',function(){var $this_parent=$(this).closest('li'),$this_arrow=$this_parent.find('>a .et_mobile_menu_arrow'),$closest_submenu=$this_parent.find('>ul'),is_opened_submenu=$this_arrow.hasClass('et_pb_submenu_opened'),sub_menu_max_height;$this_arrow.toggleClass('et_pb_submenu_opened');if(is_opened_submenu){$closest_submenu.removeClass('et_pb_slide_dropdown_opened');$closest_submenu.slideToggle(700,'easeInOutCubic');}else{$closest_submenu.slideToggle(700,'easeInOutCubic');$closest_submenu.addClass('et_pb_slide_dropdown_opened');}
  return false;});if($('body').hasClass('et_header_style_fullscreen')){var $menu_container=$('.et_header_style_fullscreen .et_slide_in_menu_container');if($menu_container.length){var top_bar_height=$menu_container.find('.et_slide_menu_top').innerHeight();$menu_container.css({'padding-top':top_bar_height+20});}}
  $(document.body).on('checkout_error',function(){et_adjust_woocommerce_checkout_scroll();});$(document.body).on('updated_checkout',function(data){if('failure'!==data.result){return;}
  et_adjust_woocommerce_checkout_scroll();});})(jQuery);;
  /*!
  * FitVids 1.1
  *
  * Copyright 2013, Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com
  * Credit to Thierry Koblentz - http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/
  * Released under the WTFPL license - http://sam.zoy.org/wtfpl/
  *
  */
  (function($){'use strict';$.fn.fitVids=function(options){var settings={customSelector:null,ignore:null};if(!document.getElementById('fit-vids-style')){var head=document.head||document.getElementsByTagName('head')[0];var css='.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}';var div=document.createElement("div");div.innerHTML='<p>x</p><style id="fit-vids-style">'+css+'</style>';head.appendChild(div.childNodes[1]);}
  if(options){$.extend(settings,options);}
  return this.each(function(){var selectors=['iframe[src*="player.vimeo.com"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="kickstarter.com"][src*="video.html"]','object','embed'];if(settings.customSelector){selectors.push(settings.customSelector);}
  var ignoreList='.fitvidsignore';if(settings.ignore){ignoreList=ignoreList+', '+settings.ignore;}
  var $allVideos=$(this).find(selectors.join(','));$allVideos=$allVideos.not('object object');$allVideos=$allVideos.not(ignoreList);$allVideos.each(function(count){var $this=$(this);if($this.parents(ignoreList).length>0){return;}
  if(this.tagName.toLowerCase()==='embed'&&$this.parent('object').length||$this.parent('.fluid-width-video-wrapper').length){return;}
  if((!$this.css('height')&&!$this.css('width'))&&(isNaN($this.attr('height'))||isNaN($this.attr('width'))))
  {$this.attr('height',9);$this.attr('width',16);}
  var height=(this.tagName.toLowerCase()==='object'||($this.attr('height')&&!isNaN(parseInt($this.attr('height'),10))))?parseInt($this.attr('height'),10):$this.height(),width=!isNaN(parseInt($this.attr('width'),10))?parseInt($this.attr('width'),10):$this.width(),aspectRatio=height/width;if(!$this.attr('id')){var videoID='fitvid'+count;$this.attr('id',videoID);}
  $this.wrap('<div class="fluid-width-video-wrapper"></div>').parent('.fluid-width-video-wrapper').css('padding-top',(aspectRatio*100)+'%');$this.removeAttr('height').removeAttr('width');});});};})(window.jQuery||window.Zepto);
  ;/*!
  * Waypoints - 4.0.0
  * Copyright © 2011-2015 Caleb Troughton
  * Licensed under the MIT license.
  * https://github.com/imakewebthings/waypoints/blog/master/licenses.txt
  */
  !function(){"use strict";function t(o){if(!o)throw new Error("No options passed to Waypoint constructor");if(!o.element)throw new Error("No element option passed to Waypoint constructor");if(!o.handler)throw new Error("No handler option passed to Waypoint constructor");this.key="waypoint-"+e,this.options=t.Adapter.extend({},t.defaults,o),this.element=this.options.element,this.adapter=new t.Adapter(this.element),this.callback=o.handler,this.axis=this.options.horizontal?"horizontal":"vertical",this.enabled=this.options.enabled,this.triggerPoint=null,this.group=t.Group.findOrCreate({name:this.options.group,axis:this.axis}),this.context=t.Context.findOrCreateByElement(this.options.context),t.offsetAliases[this.options.offset]&&(this.options.offset=t.offsetAliases[this.options.offset]),this.group.add(this),this.context.add(this),i[this.key]=this,e+=1}var e=0,i={};t.prototype.queueTrigger=function(t){this.group.queueTrigger(this,t)},t.prototype.trigger=function(t){this.enabled&&this.callback&&this.callback.apply(this,t)},t.prototype.destroy=function(){this.context.remove(this),this.group.remove(this),delete i[this.key]},t.prototype.disable=function(){return this.enabled=!1,this},t.prototype.enable=function(){return this.context.refresh(),this.enabled=!0,this},t.prototype.next=function(){return this.group.next(this)},t.prototype.previous=function(){return this.group.previous(this)},t.invokeAll=function(t){var e=[];for(var o in i)e.push(i[o]);for(var n=0,r=e.length;r>n;n++)e[n][t]()},t.destroyAll=function(){t.invokeAll("destroy")},t.disableAll=function(){t.invokeAll("disable")},t.enableAll=function(){t.invokeAll("enable")},t.refreshAll=function(){t.Context.refreshAll()},t.viewportHeight=function(){return window.innerHeight||document.documentElement.clientHeight},t.viewportWidth=function(){return document.documentElement.clientWidth},t.adapters=[],t.defaults={context:window,continuous:!0,enabled:!0,group:"default",horizontal:!1,offset:0},t.offsetAliases={"bottom-in-view":function(){return this.context.innerHeight()-this.adapter.outerHeight()},"right-in-view":function(){return this.context.innerWidth()-this.adapter.outerWidth()}},window.Waypoint=t}(),function(){"use strict";function t(t){window.setTimeout(t,1e3/60)}function e(t){this.element=t,this.Adapter=n.Adapter,this.adapter=new this.Adapter(t),this.key="waypoint-context-"+i,this.didScroll=!1,this.didResize=!1,this.oldScroll={x:this.adapter.scrollLeft(),y:this.adapter.scrollTop()},this.waypoints={vertical:{},horizontal:{}},t.waypointContextKey=this.key,o[t.waypointContextKey]=this,i+=1,this.createThrottledScrollHandler(),this.createThrottledResizeHandler()}var i=0,o={},n=window.Waypoint,r=window.onload;e.prototype.add=function(t){var e=t.options.horizontal?"horizontal":"vertical";this.waypoints[e][t.key]=t,this.refresh()},e.prototype.checkEmpty=function(){var t=this.Adapter.isEmptyObject(this.waypoints.horizontal),e=this.Adapter.isEmptyObject(this.waypoints.vertical);t&&e&&(this.adapter.off(".waypoints"),delete o[this.key])},e.prototype.createThrottledResizeHandler=function(){function t(){e.handleResize(),e.didResize=!1}var e=this;this.adapter.on("resize.waypoints",function(){e.didResize||(e.didResize=!0,n.requestAnimationFrame(t))})},e.prototype.createThrottledScrollHandler=function(){function t(){e.handleScroll(),e.didScroll=!1}var e=this;this.adapter.on("scroll.waypoints",function(){(!e.didScroll||n.isTouch)&&(e.didScroll=!0,n.requestAnimationFrame(t))})},e.prototype.handleResize=function(){n.Context.refreshAll()},e.prototype.handleScroll=function(){var t={},e={horizontal:{newScroll:this.adapter.scrollLeft(),oldScroll:this.oldScroll.x,forward:"right",backward:"left"},vertical:{newScroll:this.adapter.scrollTop(),oldScroll:this.oldScroll.y,forward:"down",backward:"up"}};for(var i in e){var o=e[i],n=o.newScroll>o.oldScroll,r=n?o.forward:o.backward;for(var s in this.waypoints[i]){var a=this.waypoints[i][s],l=o.oldScroll<a.triggerPoint,h=o.newScroll>=a.triggerPoint,p=l&&h,u=!l&&!h;(p||u)&&(a.queueTrigger(r),t[a.group.id]=a.group)}}for(var c in t)t[c].flushTriggers();this.oldScroll={x:e.horizontal.newScroll,y:e.vertical.newScroll}},e.prototype.innerHeight=function(){return this.element==this.element.window?n.viewportHeight():this.adapter.innerHeight()},e.prototype.remove=function(t){delete this.waypoints[t.axis][t.key],this.checkEmpty()},e.prototype.innerWidth=function(){return this.element==this.element.window?n.viewportWidth():this.adapter.innerWidth()},e.prototype.destroy=function(){var t=[];for(var e in this.waypoints)for(var i in this.waypoints[e])t.push(this.waypoints[e][i]);for(var o=0,n=t.length;n>o;o++)t[o].destroy()},e.prototype.refresh=function(){var t,e=this.element==this.element.window,i=e?void 0:this.adapter.offset(),o={};this.handleScroll(),t={horizontal:{contextOffset:e?0:i.left,contextScroll:e?0:this.oldScroll.x,contextDimension:this.innerWidth(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:e?0:i.top,contextScroll:e?0:this.oldScroll.y,contextDimension:this.innerHeight(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}};for(var r in t){var s=t[r];for(var a in this.waypoints[r]){var l,h,p,u,c,d=this.waypoints[r][a],f=d.options.offset,w=d.triggerPoint,y=0,g=null==w;d.element!==d.element.window&&(y=d.adapter.offset()[s.offsetProp]),"function"==typeof f?f=f.apply(d):"string"==typeof f&&(f=parseFloat(f),d.options.offset.indexOf("%")>-1&&(f=Math.ceil(s.contextDimension*f/100))),l=s.contextScroll-s.contextOffset,d.triggerPoint=y+l-f,h=w<s.oldScroll,p=d.triggerPoint>=s.oldScroll,u=h&&p,c=!h&&!p,!g&&u?(d.queueTrigger(s.backward),o[d.group.id]=d.group):!g&&c?(d.queueTrigger(s.forward),o[d.group.id]=d.group):g&&s.oldScroll>=d.triggerPoint&&(d.queueTrigger(s.forward),o[d.group.id]=d.group)}}return n.requestAnimationFrame(function(){for(var t in o)o[t].flushTriggers()}),this},e.findOrCreateByElement=function(t){return e.findByElement(t)||new e(t)},e.refreshAll=function(){for(var t in o)o[t].refresh()},e.findByElement=function(t){return o[t.waypointContextKey]},window.onload=function(){r&&r(),e.refreshAll()},n.requestAnimationFrame=function(e){var i=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||t;i.call(window,e)},n.Context=e}(),function(){"use strict";function t(t,e){return t.triggerPoint-e.triggerPoint}function e(t,e){return e.triggerPoint-t.triggerPoint}function i(t){this.name=t.name,this.axis=t.axis,this.id=this.name+"-"+this.axis,this.waypoints=[],this.clearTriggerQueues(),o[this.axis][this.name]=this}var o={vertical:{},horizontal:{}},n=window.Waypoint;i.prototype.add=function(t){this.waypoints.push(t)},i.prototype.clearTriggerQueues=function(){this.triggerQueues={up:[],down:[],left:[],right:[]}},i.prototype.flushTriggers=function(){for(var i in this.triggerQueues){var o=this.triggerQueues[i],n="up"===i||"left"===i;o.sort(n?e:t);for(var r=0,s=o.length;s>r;r+=1){var a=o[r];(a.options.continuous||r===o.length-1)&&a.trigger([i])}}this.clearTriggerQueues()},i.prototype.next=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints),o=i===this.waypoints.length-1;return o?null:this.waypoints[i+1]},i.prototype.previous=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints);return i?this.waypoints[i-1]:null},i.prototype.queueTrigger=function(t,e){this.triggerQueues[e].push(t)},i.prototype.remove=function(t){var e=n.Adapter.inArray(t,this.waypoints);e>-1&&this.waypoints.splice(e,1)},i.prototype.first=function(){return this.waypoints[0]},i.prototype.last=function(){return this.waypoints[this.waypoints.length-1]},i.findOrCreate=function(t){return o[t.axis][t.name]||new i(t)},n.Group=i}(),function(){"use strict";function t(t){this.$element=e(t)}var e=window.jQuery,i=window.Waypoint;e.each(["innerHeight","innerWidth","off","offset","on","outerHeight","outerWidth","scrollLeft","scrollTop"],function(e,i){t.prototype[i]=function(){var t=Array.prototype.slice.call(arguments);return this.$element[i].apply(this.$element,t)}}),e.each(["extend","inArray","isEmptyObject"],function(i,o){t[o]=e[o]}),i.adapters.push({name:"jquery",Adapter:t}),i.Adapter=t}(),function(){"use strict";function t(t){return function(){var i=[],o=arguments[0];return t.isFunction(arguments[0])&&(o=t.extend({},arguments[1]),o.handler=arguments[0]),this.each(function(){var n=t.extend({},o,{element:this});"string"==typeof n.context&&(n.context=t(this).closest(n.context)[0]),i.push(new e(n))}),i}}var e=window.Waypoint;window.jQuery&&(window.jQuery.fn.waypoint=t(window.jQuery)),window.Zepto&&(window.Zepto.fn.waypoint=t(window.Zepto))}();
  ;/*!
  * Magnific Popup v1.0.1 by Dmitry Semenov
  * The MIT License (MIT)
  * Copyright (c) 2014-2015 Dmitry Semenov, http://dimsemenov.com
  * http://bit.ly/magnific-popup#build=inline+image+ajax+iframe+gallery+retina+imagezoom+fastclick
  */
  !function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):window.jQuery||window.Zepto)}(function(a){var b,c,d,e,f,g,h="Close",i="BeforeClose",j="AfterClose",k="BeforeAppend",l="MarkupParse",m="Open",n="Change",o="mfp",p="."+o,q="mfp-ready",r="mfp-removing",s="mfp-prevent-close",t=function(){},u=!!window.jQuery,v=a(window),w=function(a,c){b.ev.on(o+a+p,c)},x=function(b,c,d,e){var f=document.createElement("div");return f.className="mfp-"+b,d&&(f.innerHTML=d),e?c&&c.appendChild(f):(f=a(f),c&&f.appendTo(c)),f},y=function(c,d){b.ev.triggerHandler(o+c,d),b.st.callbacks&&(c=c.charAt(0).toLowerCase()+c.slice(1),b.st.callbacks[c]&&b.st.callbacks[c].apply(b,a.isArray(d)?d:[d]))},z=function(c){return c===g&&b.currTemplate.closeBtn||(b.currTemplate.closeBtn=a(b.st.closeMarkup.replace("%title%",b.st.tClose)),g=c),b.currTemplate.closeBtn},A=function(){a.magnificPopup.instance||(b=new t,b.init(),a.magnificPopup.instance=b)},B=function(){var a=document.createElement("p").style,b=["ms","O","Moz","Webkit"];if(void 0!==a.transition)return!0;for(;b.length;)if(b.pop()+"Transition"in a)return!0;return!1};t.prototype={constructor:t,init:function(){var c=navigator.appVersion;b.isIE7=-1!==c.indexOf("MSIE 7."),b.isIE8=-1!==c.indexOf("MSIE 8."),b.isLowIE=b.isIE7||b.isIE8,b.isAndroid=/android/gi.test(c),b.isIOS=/iphone|ipad|ipod/gi.test(c),b.supportsTransition=B(),b.probablyMobile=b.isAndroid||b.isIOS||/(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent),d=a(document),b.popupsCache={}},open:function(c){var e;if(c.isObj===!1){b.items=c.items.toArray(),b.index=0;var g,h=c.items;for(e=0;e<h.length;e++)if(g=h[e],g.parsed&&(g=g.el[0]),g===c.el[0]){b.index=e;break}}else b.items=a.isArray(c.items)?c.items:[c.items],b.index=c.index||0;if(b.isOpen)return void b.updateItemHTML();b.types=[],f="",c.mainEl&&c.mainEl.length?b.ev=c.mainEl.eq(0):b.ev=d,c.key?(b.popupsCache[c.key]||(b.popupsCache[c.key]={}),b.currTemplate=b.popupsCache[c.key]):b.currTemplate={},b.st=a.extend(!0,{},a.magnificPopup.defaults,c),b.fixedContentPos="auto"===b.st.fixedContentPos?!b.probablyMobile:b.st.fixedContentPos,b.st.modal&&(b.st.closeOnContentClick=!1,b.st.closeOnBgClick=!1,b.st.showCloseBtn=!1,b.st.enableEscapeKey=!1),b.bgOverlay||(b.bgOverlay=x("bg").on("click"+p,function(){b.close()}),b.wrap=x("wrap").attr("tabindex",-1).on("click"+p,function(a){b._checkIfClose(a.target)&&b.close()}),b.container=x("container",b.wrap)),b.contentContainer=x("content"),b.st.preloader&&(b.preloader=x("preloader",b.container,b.st.tLoading));var i=a.magnificPopup.modules;for(e=0;e<i.length;e++){var j=i[e];j=j.charAt(0).toUpperCase()+j.slice(1),b["init"+j].call(b)}y("BeforeOpen"),b.st.showCloseBtn&&(b.st.closeBtnInside?(w(l,function(a,b,c,d){c.close_replaceWith=z(d.type)}),f+=" mfp-close-btn-in"):b.wrap.append(z())),b.st.alignTop&&(f+=" mfp-align-top"),b.fixedContentPos?b.wrap.css({overflow:b.st.overflowY,overflowX:"hidden",overflowY:b.st.overflowY}):b.wrap.css({top:v.scrollTop(),position:"absolute"}),(b.st.fixedBgPos===!1||"auto"===b.st.fixedBgPos&&!b.fixedContentPos)&&b.bgOverlay.css({height:d.height(),position:"absolute"}),b.st.enableEscapeKey&&d.on("keyup"+p,function(a){27===a.keyCode&&b.close()}),v.on("resize"+p,function(){b.updateSize()}),b.st.closeOnContentClick||(f+=" mfp-auto-cursor"),f&&b.wrap.addClass(f);var k=b.wH=v.height(),n={};if(b.fixedContentPos&&b._hasScrollBar(k)){var o=b._getScrollbarSize();o&&(n.marginRight=o)}b.fixedContentPos&&(b.isIE7?a("body, html").css("overflow","hidden"):n.overflow="hidden");var r=b.st.mainClass;return b.isIE7&&(r+=" mfp-ie7"),r&&b._addClassToMFP(r),b.updateItemHTML(),y("BuildControls"),a("html").css(n),b.bgOverlay.add(b.wrap).prependTo(b.st.prependTo||a(document.body)),b._lastFocusedEl=document.activeElement,setTimeout(function(){b.content?(b._addClassToMFP(q),b._setFocus()):b.bgOverlay.addClass(q),d.on("focusin"+p,b._onFocusIn)},16),b.isOpen=!0,b.updateSize(k),y(m),c},close:function(){b.isOpen&&(y(i),b.isOpen=!1,b.st.removalDelay&&!b.isLowIE&&b.supportsTransition?(b._addClassToMFP(r),setTimeout(function(){b._close()},b.st.removalDelay)):b._close())},_close:function(){y(h);var c=r+" "+q+" ";if(b.bgOverlay.detach(),b.wrap.detach(),b.container.empty(),b.st.mainClass&&(c+=b.st.mainClass+" "),b._removeClassFromMFP(c),b.fixedContentPos){var e={marginRight:""};b.isIE7?a("body, html").css("overflow",""):e.overflow="",a("html").css(e)}d.off("keyup"+p+" focusin"+p),b.ev.off(p),b.wrap.attr("class","mfp-wrap").removeAttr("style"),b.bgOverlay.attr("class","mfp-bg"),b.container.attr("class","mfp-container"),!b.st.showCloseBtn||b.st.closeBtnInside&&b.currTemplate[b.currItem.type]!==!0||b.currTemplate.closeBtn&&b.currTemplate.closeBtn.detach(),b.st.autoFocusLast&&b._lastFocusedEl&&a(b._lastFocusedEl).focus(),b.currItem=null,b.content=null,b.currTemplate=null,b.prevHeight=0,y(j)},updateSize:function(a){if(b.isIOS){var c=document.documentElement.clientWidth/window.innerWidth,d=window.innerHeight*c;b.wrap.css("height",d),b.wH=d}else b.wH=a||v.height();b.fixedContentPos||b.wrap.css("height",b.wH),y("Resize")},updateItemHTML:function(){var c=b.items[b.index];b.contentContainer.detach(),b.content&&b.content.detach(),c.parsed||(c=b.parseEl(b.index));var d=c.type;if(y("BeforeChange",[b.currItem?b.currItem.type:"",d]),b.currItem=c,!b.currTemplate[d]){var f=b.st[d]?b.st[d].markup:!1;y("FirstMarkupParse",f),f?b.currTemplate[d]=a(f):b.currTemplate[d]=!0}e&&e!==c.type&&b.container.removeClass("mfp-"+e+"-holder");var g=b["get"+d.charAt(0).toUpperCase()+d.slice(1)](c,b.currTemplate[d]);b.appendContent(g,d),c.preloaded=!0,y(n,c),e=c.type,b.container.prepend(b.contentContainer),y("AfterChange")},appendContent:function(a,c){b.content=a,a?b.st.showCloseBtn&&b.st.closeBtnInside&&b.currTemplate[c]===!0?b.content.find(".mfp-close").length||b.content.append(z()):b.content=a:b.content="",y(k),b.container.addClass("mfp-"+c+"-holder"),b.contentContainer.append(b.content)},parseEl:function(c){var d,e=b.items[c];if(e.tagName?e={el:a(e)}:(d=e.type,e={data:e,src:e.src}),e.el){for(var f=b.types,g=0;g<f.length;g++)if(e.el.hasClass("mfp-"+f[g])){d=f[g];break}e.src=e.el.attr("data-mfp-src"),e.src||(e.src=e.el.attr("href"))}return e.type=d||b.st.type||"inline",e.index=c,e.parsed=!0,b.items[c]=e,y("ElementParse",e),b.items[c]},addGroup:function(a,c){var d=function(d){d.mfpEl=this,b._openClick(d,a,c)};c||(c={});var e="click.magnificPopup";c.mainEl=a,c.items?(c.isObj=!0,a.off(e).on(e,d)):(c.isObj=!1,c.delegate?a.off(e).on(e,c.delegate,d):(c.items=a,a.off(e).on(e,d)))},_openClick:function(c,d,e){var f=void 0!==e.midClick?e.midClick:a.magnificPopup.defaults.midClick;if(f||!(2===c.which||c.ctrlKey||c.metaKey||c.altKey||c.shiftKey)){var g=void 0!==e.disableOn?e.disableOn:a.magnificPopup.defaults.disableOn;if(g)if(a.isFunction(g)){if(!g.call(b))return!0}else if(v.width()<g)return!0;c.type&&(c.preventDefault(),b.isOpen&&c.stopPropagation()),e.el=a(c.mfpEl),e.delegate&&(e.items=d.find(e.delegate)),b.open(e)}},updateStatus:function(a,d){if(b.preloader){c!==a&&b.container.removeClass("mfp-s-"+c),d||"loading"!==a||(d=b.st.tLoading);var e={status:a,text:d};y("UpdateStatus",e),a=e.status,d=e.text,b.preloader.html(d),b.preloader.find("a").on("click",function(a){a.stopImmediatePropagation()}),b.container.addClass("mfp-s-"+a),c=a}},_checkIfClose:function(c){if(!a(c).hasClass(s)){var d=b.st.closeOnContentClick,e=b.st.closeOnBgClick;if(d&&e)return!0;if(!b.content||a(c).hasClass("mfp-close")||b.preloader&&c===b.preloader[0])return!0;if(c===b.content[0]||a.contains(b.content[0],c)){if(d)return!0}else if(e&&a.contains(document,c))return!0;return!1}},_addClassToMFP:function(a){b.bgOverlay.addClass(a),b.wrap.addClass(a)},_removeClassFromMFP:function(a){this.bgOverlay.removeClass(a),b.wrap.removeClass(a)},_hasScrollBar:function(a){return(b.isIE7?d.height():document.body.scrollHeight)>(a||v.height())},_setFocus:function(){(b.st.focus?b.content.find(b.st.focus).eq(0):b.wrap).focus()},_onFocusIn:function(c){return c.target===b.wrap[0]||a.contains(b.wrap[0],c.target)?void 0:(b._setFocus(),!1)},_parseMarkup:function(b,c,d){var e;d.data&&(c=a.extend(d.data,c)),y(l,[b,c,d]),a.each(c,function(a,c){if(void 0===c||c===!1)return!0;if(e=a.split("_"),e.length>1){var d=b.find(p+"-"+e[0]);if(d.length>0){var f=e[1];"replaceWith"===f?d[0]!==c[0]&&d.replaceWith(c):"img"===f?d.is("img")?d.attr("src",c):d.replaceWith('<img src="'+c+'" class="'+d.attr("class")+'" />'):d.attr(e[1],c)}}else b.find(p+"-"+a).html(c)})},_getScrollbarSize:function(){if(void 0===b.scrollbarSize){var a=document.createElement("div");a.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(a),b.scrollbarSize=a.offsetWidth-a.clientWidth,document.body.removeChild(a)}return b.scrollbarSize}},a.magnificPopup={instance:null,proto:t.prototype,modules:[],open:function(b,c){return A(),b=b?a.extend(!0,{},b):{},b.isObj=!0,b.index=c||0,this.instance.open(b)},close:function(){return a.magnificPopup.instance&&a.magnificPopup.instance.close()},registerModule:function(b,c){c.options&&(a.magnificPopup.defaults[b]=c.options),a.extend(this.proto,c.proto),this.modules.push(b)},defaults:{disableOn:0,key:null,midClick:!1,mainClass:"",preloader:!0,focus:"",closeOnContentClick:!1,closeOnBgClick:!0,closeBtnInside:!0,showCloseBtn:!0,enableEscapeKey:!0,modal:!1,alignTop:!1,removalDelay:0,prependTo:null,fixedContentPos:"auto",fixedBgPos:"auto",overflowY:"auto",closeMarkup:'<button title="%title%" type="button" class="mfp-close">&#215;</button>',tClose:"Close (Esc)",tLoading:"Loading...",autoFocusLast:!0}},a.fn.magnificPopup=function(c){A();var d=a(this);if("string"==typeof c)if("open"===c){var e,f=u?d.data("magnificPopup"):d[0].magnificPopup,g=parseInt(arguments[1],10)||0;f.items?e=f.items[g]:(e=d,f.delegate&&(e=e.find(f.delegate)),e=e.eq(g)),b._openClick({mfpEl:e},d,f)}else b.isOpen&&b[c].apply(b,Array.prototype.slice.call(arguments,1));else c=a.extend(!0,{},c),u?d.data("magnificPopup",c):d[0].magnificPopup=c,b.addGroup(d,c);return d};var C,D,E,F="inline",G=function(){E&&(D.after(E.addClass(C)).detach(),E=null)};a.magnificPopup.registerModule(F,{options:{hiddenClass:"hide",markup:"",tNotFound:"Content not found"},proto:{initInline:function(){b.types.push(F),w(h+"."+F,function(){G()})},getInline:function(c,d){if(G(),c.src){var e=b.st.inline,f=a(c.src);if(f.length){var g=f[0].parentNode;g&&g.tagName&&(D||(C=e.hiddenClass,D=x(C),C="mfp-"+C),E=f.after(D).detach().removeClass(C)),b.updateStatus("ready")}else b.updateStatus("error",e.tNotFound),f=a("<div>");return c.inlineElement=f,f}return b.updateStatus("ready"),b._parseMarkup(d,{},c),d}}});var H,I="ajax",J=function(){H&&a(document.body).removeClass(H)},K=function(){J(),b.req&&b.req.abort()};a.magnificPopup.registerModule(I,{options:{settings:null,cursor:"mfp-ajax-cur",tError:'<a href="%url%">The content</a> could not be loaded.'},proto:{initAjax:function(){b.types.push(I),H=b.st.ajax.cursor,w(h+"."+I,K),w("BeforeChange."+I,K)},getAjax:function(c){H&&a(document.body).addClass(H),b.updateStatus("loading");var d=a.extend({url:c.src,success:function(d,e,f){var g={data:d,xhr:f};y("ParseAjax",g),b.appendContent(a(g.data),I),c.finished=!0,J(),b._setFocus(),setTimeout(function(){b.wrap.addClass(q)},16),b.updateStatus("ready"),y("AjaxContentAdded")},error:function(){J(),c.finished=c.loadError=!0,b.updateStatus("error",b.st.ajax.tError.replace("%url%",c.src))}},b.st.ajax.settings);return b.req=a.ajax(d),""}}});var L,M=function(c){if(c.data&&void 0!==c.data.title)return c.data.title;var d=b.st.image.titleSrc;if(d){if(a.isFunction(d))return d.call(b,c);if(c.el)return c.el.attr(d)||""}return""};a.magnificPopup.registerModule("image",{options:{markup:'<div class="mfp-figure"><div class="mfp-close"></div><figure><div class="mfp-img"></div><figcaption><div class="mfp-bottom-bar"><div class="mfp-title"></div><div class="mfp-counter"></div></div></figcaption></figure></div>',cursor:"mfp-zoom-out-cur",titleSrc:"title",verticalFit:!0,tError:'<a href="%url%">The image</a> could not be loaded.'},proto:{initImage:function(){var c=b.st.image,d=".image";b.types.push("image"),w(m+d,function(){"image"===b.currItem.type&&c.cursor&&a(document.body).addClass(c.cursor)}),w(h+d,function(){c.cursor&&a(document.body).removeClass(c.cursor),v.off("resize"+p)}),w("Resize"+d,b.resizeImage),b.isLowIE&&w("AfterChange",b.resizeImage)},resizeImage:function(){var a=b.currItem;if(a&&a.img&&b.st.image.verticalFit){var c=0;b.isLowIE&&(c=parseInt(a.img.css("padding-top"),10)+parseInt(a.img.css("padding-bottom"),10)),a.img.css("max-height",b.wH-c)}},_onImageHasSize:function(a){a.img&&(a.hasSize=!0,L&&clearInterval(L),a.isCheckingImgSize=!1,y("ImageHasSize",a),a.imgHidden&&(b.content&&b.content.removeClass("mfp-loading"),a.imgHidden=!1))},findImageSize:function(a){var c=0,d=a.img[0],e=function(f){L&&clearInterval(L),L=setInterval(function(){return d.naturalWidth>0?void b._onImageHasSize(a):(c>200&&clearInterval(L),c++,void(3===c?e(10):40===c?e(50):100===c&&e(500)))},f)};e(1)},getImage:function(c,d){var e=0,f=function(){c&&(c.img[0].complete?(c.img.off(".mfploader"),c===b.currItem&&(b._onImageHasSize(c),b.updateStatus("ready")),c.hasSize=!0,c.loaded=!0,y("ImageLoadComplete")):(e++,200>e?setTimeout(f,100):g()))},g=function(){c&&(c.img.off(".mfploader"),c===b.currItem&&(b._onImageHasSize(c),b.updateStatus("error",h.tError.replace("%url%",c.src))),c.hasSize=!0,c.loaded=!0,c.loadError=!0)},h=b.st.image,i=d.find(".mfp-img");if(i.length){var j=document.createElement("img");j.className="mfp-img",c.el&&c.el.find("img").length&&(j.alt=c.el.find("img").attr("alt")),c.img=a(j).on("load.mfploader",f).on("error.mfploader",g),j.src=c.src,i.is("img")&&(c.img=c.img.clone()),j=c.img[0],j.naturalWidth>0?c.hasSize=!0:j.width||(c.hasSize=!1)}return b._parseMarkup(d,{title:M(c),img_replaceWith:c.img},c),b.resizeImage(),c.hasSize?(L&&clearInterval(L),c.loadError?(d.addClass("mfp-loading"),b.updateStatus("error",h.tError.replace("%url%",c.src))):(d.removeClass("mfp-loading"),b.updateStatus("ready")),d):(b.updateStatus("loading"),c.loading=!0,c.hasSize||(c.imgHidden=!0,d.addClass("mfp-loading"),b.findImageSize(c)),d)}}});var N,O=function(){return void 0===N&&(N=void 0!==document.createElement("p").style.MozTransform),N};a.magnificPopup.registerModule("zoom",{options:{enabled:!1,easing:"ease-in-out",duration:300,opener:function(a){return a.is("img")?a:a.find("img")}},proto:{initZoom:function(){var a,c=b.st.zoom,d=".zoom";if(c.enabled&&b.supportsTransition){var e,f,g=c.duration,j=function(a){var b=a.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"),d="all "+c.duration/1e3+"s "+c.easing,e={position:"fixed",zIndex:9999,left:0,top:0,"-webkit-backface-visibility":"hidden"},f="transition";return e["-webkit-"+f]=e["-moz-"+f]=e["-o-"+f]=e[f]=d,b.css(e),b},k=function(){b.content.css("visibility","visible")};w("BuildControls"+d,function(){if(b._allowZoom()){if(clearTimeout(e),b.content.css("visibility","hidden"),a=b._getItemToZoom(),!a)return void k();f=j(a),f.css(b._getOffset()),b.wrap.append(f),e=setTimeout(function(){f.css(b._getOffset(!0)),e=setTimeout(function(){k(),setTimeout(function(){f.remove(),a=f=null,y("ZoomAnimationEnded")},16)},g)},16)}}),w(i+d,function(){if(b._allowZoom()){if(clearTimeout(e),b.st.removalDelay=g,!a){if(a=b._getItemToZoom(),!a)return;f=j(a)}f.css(b._getOffset(!0)),b.wrap.append(f),b.content.css("visibility","hidden"),setTimeout(function(){f.css(b._getOffset())},16)}}),w(h+d,function(){b._allowZoom()&&(k(),f&&f.remove(),a=null)})}},_allowZoom:function(){return"image"===b.currItem.type},_getItemToZoom:function(){return b.currItem.hasSize?b.currItem.img:!1},_getOffset:function(c){var d;d=c?b.currItem.img:b.st.zoom.opener(b.currItem.el||b.currItem);var e=d.offset(),f=parseInt(d.css("padding-top"),10),g=parseInt(d.css("padding-bottom"),10);e.top-=a(window).scrollTop()-f;var h={width:d.width(),height:(u?d.innerHeight():d[0].offsetHeight)-g-f};return O()?h["-moz-transform"]=h.transform="translate("+e.left+"px,"+e.top+"px)":(h.left=e.left,h.top=e.top),h}}});var P="iframe",Q="//about:blank",R=function(a){if(b.currTemplate[P]){var c=b.currTemplate[P].find("iframe");c.length&&(a||(c[0].src=Q),b.isIE8&&c.css("display",a?"block":"none"))}};a.magnificPopup.registerModule(P,{options:{markup:'<div class="mfp-iframe-scaler"><div class="mfp-close"></div><iframe class="mfp-iframe" src="//about:blank" frameborder="0" allowfullscreen></iframe></div>',srcAction:"iframe_src",patterns:{youtube:{index:"youtube.com",id:"v=",src:"//www.youtube.com/embed/%id%?autoplay=1"},vimeo:{index:"vimeo.com/",id:"/",src:"//player.vimeo.com/video/%id%?autoplay=1"},gmaps:{index:"//maps.google.",src:"%id%&output=embed"}}},proto:{initIframe:function(){b.types.push(P),w("BeforeChange",function(a,b,c){b!==c&&(b===P?R():c===P&&R(!0))}),w(h+"."+P,function(){R()})},getIframe:function(c,d){var e=c.src,f=b.st.iframe;a.each(f.patterns,function(){return e.indexOf(this.index)>-1?(this.id&&(e="string"==typeof this.id?e.substr(e.lastIndexOf(this.id)+this.id.length,e.length):this.id.call(this,e)),e=this.src.replace("%id%",e),!1):void 0});var g={};return f.srcAction&&(g[f.srcAction]=e),b._parseMarkup(d,g,c),b.updateStatus("ready"),d}}});var S=function(a){var c=b.items.length;return a>c-1?a-c:0>a?c+a:a},T=function(a,b,c){return a.replace(/%curr%/gi,b+1).replace(/%total%/gi,c)};a.magnificPopup.registerModule("gallery",{options:{enabled:!1,arrowMarkup:'<button title="%title%" type="button" class="mfp-arrow mfp-arrow-%dir%"></button>',preload:[0,2],navigateByImgClick:!0,arrows:!0,tPrev:"Previous (Left arrow key)",tNext:"Next (Right arrow key)",tCounter:"%curr% of %total%"},proto:{initGallery:function(){var c=b.st.gallery,e=".mfp-gallery",g=Boolean(a.fn.mfpFastClick);return b.direction=!0,c&&c.enabled?(f+=" mfp-gallery",w(m+e,function(){c.navigateByImgClick&&b.wrap.on("click"+e,".mfp-img",function(){return b.items.length>1?(b.next(),!1):void 0}),d.on("keydown"+e,function(a){37===a.keyCode?b.prev():39===a.keyCode&&b.next()})}),w("UpdateStatus"+e,function(a,c){c.text&&(c.text=T(c.text,b.currItem.index,b.items.length))}),w(l+e,function(a,d,e,f){var g=b.items.length;e.counter=g>1?T(c.tCounter,f.index,g):""}),w("BuildControls"+e,function(){if(b.items.length>1&&c.arrows&&!b.arrowLeft){var d=c.arrowMarkup,e=b.arrowLeft=a(d.replace(/%title%/gi,c.tPrev).replace(/%dir%/gi,"left")).addClass(s),f=b.arrowRight=a(d.replace(/%title%/gi,c.tNext).replace(/%dir%/gi,"right")).addClass(s),h=g?"mfpFastClick":"click";e[h](function(){b.prev()}),f[h](function(){b.next()}),b.isIE7&&(x("b",e[0],!1,!0),x("a",e[0],!1,!0),x("b",f[0],!1,!0),x("a",f[0],!1,!0)),b.container.append(e.add(f))}}),w(n+e,function(){b._preloadTimeout&&clearTimeout(b._preloadTimeout),b._preloadTimeout=setTimeout(function(){b.preloadNearbyImages(),b._preloadTimeout=null},16)}),void w(h+e,function(){d.off(e),b.wrap.off("click"+e),b.arrowLeft&&g&&b.arrowLeft.add(b.arrowRight).destroyMfpFastClick(),b.arrowRight=b.arrowLeft=null})):!1},next:function(){b.direction=!0,b.index=S(b.index+1),b.updateItemHTML()},prev:function(){b.direction=!1,b.index=S(b.index-1),b.updateItemHTML()},goTo:function(a){b.direction=a>=b.index,b.index=a,b.updateItemHTML()},preloadNearbyImages:function(){var a,c=b.st.gallery.preload,d=Math.min(c[0],b.items.length),e=Math.min(c[1],b.items.length);for(a=1;a<=(b.direction?e:d);a++)b._preloadItem(b.index+a);for(a=1;a<=(b.direction?d:e);a++)b._preloadItem(b.index-a)},_preloadItem:function(c){if(c=S(c),!b.items[c].preloaded){var d=b.items[c];d.parsed||(d=b.parseEl(c)),y("LazyLoad",d),"image"===d.type&&(d.img=a('<img class="mfp-img" />').on("load.mfploader",function(){d.hasSize=!0}).on("error.mfploader",function(){d.hasSize=!0,d.loadError=!0,y("LazyLoadError",d)}).attr("src",d.src)),d.preloaded=!0}}}});var U="retina";a.magnificPopup.registerModule(U,{options:{replaceSrc:function(a){return a.src.replace(/\.\w+$/,function(a){return"@2x"+a})},ratio:1},proto:{initRetina:function(){if(window.devicePixelRatio>1){var a=b.st.retina,c=a.ratio;c=isNaN(c)?c():c,c>1&&(w("ImageHasSize."+U,function(a,b){b.img.css({"max-width":b.img[0].naturalWidth/c,width:"100%"})}),w("ElementParse."+U,function(b,d){d.src=a.replaceSrc(d,c)}))}}}}),function(){var b=1e3,c="ontouchstart"in window,d=function(){v.off("touchmove"+f+" touchend"+f)},e="mfpFastClick",f="."+e;a.fn.mfpFastClick=function(e){return a(this).each(function(){var g,h=a(this);if(c){var i,j,k,l,m,n;h.on("touchstart"+f,function(a){l=!1,n=1,m=a.originalEvent?a.originalEvent.touches[0]:a.touches[0],j=m.clientX,k=m.clientY,v.on("touchmove"+f,function(a){m=a.originalEvent?a.originalEvent.touches:a.touches,n=m.length,m=m[0],(Math.abs(m.clientX-j)>10||Math.abs(m.clientY-k)>10)&&(l=!0,d())}).on("touchend"+f,function(a){d(),l||n>1||(g=!0,a.preventDefault(),clearTimeout(i),i=setTimeout(function(){g=!1},b),e())})})}h.on("click"+f,function(){g||e()})})},a.fn.destroyMfpFastClick=function(){a(this).off("touchstart"+f+" click"+f),c&&v.off("touchmove"+f+" touchend"+f)}}(),A()});