!function(n){var l={common:{init:function(){this.expandNavbarOnClickSearch(),this.add_pretty_photo_gallery(),this.scrollToElement(),this.scrollDown(),this.scrollToTop(),this.mobileMenuToggle(),this.infiniteScroll()},expandNavbarOnClickSearch:function(){var t=n(".js-search-box-to-expand");n(".js-expand-search").on("click",function(e){t.removeClass("u-hidden"),n(".rocksite-o-search-navbar .rocksite-c-search-field__input").focus(),e.preventDefault()}),n(".js-close-search").on("click",function(e){t.addClass("u-hidden"),n(".js-expand-search").focus(),e.preventDefault()})},infiniteScroll:function(){n(".js-infinite-scroll").infiniteScroll({path:".next.page-numbers",append:".rocksite-c-article-box",status:".scroller-status",hideNav:".nav-links"})},add_pretty_photo_gallery:function(){0 a, .-js-menu-toggle").on("click",function(e){"#"==n(this).attr("href")&&e.preventDefault(),n(this).parent().toggleClass("--open")})},scrollToElement:function(){n(".js-scroll-to-menu a").on("click",function(){var e=n(this),t=e.parents(".js-scroll-to-menu"),e=e.attr("href"),t=+t.data("scroll-offset");n("html, body").animate({scrollTop:n(e).offset().top-t},2e3)})},scrollDown:function(){n(".js-scroll-down").on("click",function(e){var t=n(this).attr("href");e.preventDefault(),n("html, body").animate({scrollTop:n(t).offset().top},500,"linear")})},scrollToTop:function(){$btnTop=n("#scroll-top-top"),n(window).scroll(function(){100