!function(a){"use strict";a.fn.fitVids=function(b){var c={customSelector:null,ignore:null};if(!document.getElementById("fit-vids-style")){var d=document.head||document.getElementsByTagName("head")[0],e=".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%;}",f=document.createElement("div");f.innerHTML='
x
",d.appendChild(f.childNodes[1])}return b&&a.extend(c,b),this.each(function(){var b=['iframe[src*="player.vimeo.com"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="kickstarter.com"][src*="video.html"]',"object","embed"];c.customSelector&&b.push(c.customSelector);var d=".fitvidsignore";c.ignore&&(d=d+", "+c.ignore);var e=a(this).find(b.join(","));e=e.not("object object"),e=e.not(d),e.each(function(){var b=a(this);if(!(b.parents(d).length>0||"embed"===this.tagName.toLowerCase()&&b.parent("object").length||b.parent(".fluid-width-video-wrapper").length)){b.css("height")||b.css("width")||!isNaN(b.attr("height"))&&!isNaN(b.attr("width"))||(b.attr("height",9),b.attr("width",16));var c="object"===this.tagName.toLowerCase()||b.attr("height")&&!isNaN(parseInt(b.attr("height"),10))?parseInt(b.attr("height"),10):b.height(),e=isNaN(parseInt(b.attr("width"),10))?b.width():parseInt(b.attr("width"),10),f=c/e;if(!b.attr("id")){var g="fitvid"+Math.floor(999999*Math.random());b.attr("id",g)}b.wrap('').parent(".fluid-width-video-wrapper").css("padding-top",100*f+"%"),b.removeAttr("height").removeAttr("width")}})})}}(window.jQuery||window.Zepto),jQuery(document).ready(function(a){function b(){if(q.hasClass("open"))q.trigger("close"),q.removeClass("open"),a(this).children("span").text(objectL10n.openPrimaryMenu),a(this).attr("aria-expanded","false"),a("#menu-primary-items ul, .menu-unset ul").removeAttr("style"),a(".menu-item-has-children").each(function(){a(this).hasClass("open")&&a(this).removeClass("open")}),g(),d(),a(window).unbind("scroll",k);else{q.addClass("open"),q.trigger("open"),a(this).children("span").text(objectL10n.closePrimaryMenu),a(this).attr("aria-expanded","true");var b=window.innerWidth;if(b>549&&950>b){var c=0;r.find(".social-media-icons").length&&(c=r.find(".social-media-icons").find("ul").outerHeight());var e=w.outerHeight(),f=q.outerHeight(),h=t.height(),i=h+f+c+e;i>window.innerHeight&&s.css("min-height",i+"px"),a(window).scroll(k)}}}function c(){var b=a(this).parent();b.hasClass("open")?(b.removeClass("open"),a(this).children("span").text(objectL10n.openChildMenu),a(this).attr("aria-expanded","false")):(b.addClass("open"),a(this).children("span").text(objectL10n.closeChildMenu),a(this).attr("aria-expanded","true"),y=!1),g()}function d(){var b=window.innerWidth;if(b>549&&950>b){var c=0;r.find(".social-media-icons").length&&(c=r.find(".social-media-icons").find("ul").outerHeight());var d=w.outerHeight(),e=q.outerHeight();a("#menu-primary").css("top",e+c+24+"px"),t.css("top",e+c+d+48+"px")}else a("#sidebar-primary, #menu-primary").css("top","")}function e(){var b=window.innerWidth;if(b>549&&950>b){var c=a(this).next(),d=0;c.children().each(function(){d+=a(this).height()});var e=t.css("top"),f=s.css("min-height");e=parseInt(e),f=parseInt(f);var g=a(this).parent();g.hasClass("open")?(t.css("top",e+d+"px"),s.css("min-height",f+d+"px")):(t.css("top",e-d+"px"),s.css("min-height",f-d+"px"))}}function f(){window.innerWidth>949&&q.hasClass("open")&&b()}function g(){s.css("min-height","");var a=u.height();v.length>0&&(a-=v.children("a").height()),a>window.innerHeight&&s.css("min-height",a+"px")}function h(){if(window.innerWidth<950){q.removeAttr("style")}}function i(){var b=a("#overflow-container"),c=window.innerWidth,d=a(window).height(),e=b.height(),f=q.outerHeight(),g=a(window).scrollTop(),h=a("body").hasClass("admin-bar")?a("#wpadminbar").height():0;950>c||(f+h>d&&1!=y?g>x?m?(m=!1,z=q.offset().top>0?q.offset().top-h:0,q.attr("style","top: "+z+"px;")):!n&&g+d>f+q.offset().top&&e>f+h?(n=!0,q.attr("style","position: fixed; bottom: 0;")):f+h>d&&!n&&(z=q.offset().top>0?q.offset().top-h:0,q.attr("style","top: "+z+"px;")):x>g?n?(n=!1,z=q.offset().top>0?q.offset().top-h:0,q.attr("style","top: "+z+"px;")):!m&&g>0&&g+h