(function(n){RL.fancyboxvideo={init:function(){n(".fancybox").fancybox({fitToView:!0,autoSize:!0,closeClick:!1,openEffect:"none",closeEffect:"none",type:"iframe",margin:[15,30,15,15]});RL.fancyboxvideo.richContentVideoMod()},richContentVideoMod:function(){var i=n("section.rich-text-component"),r,u,t;i.find("iframe").length>0&&i.find("iframe").each(function(){if(r=n(this).attr("src"),u=r.search("youtube.com"),t=n(this),n(this).attr("data-width",n(this).attr("width")),u>0)n(window).on("resize",function(){n(window).width()<=RL.breakpoint_sm+238?t.attr("width","100%"):t.attr("width",t.attr("data-width"))})})},autoplay:function(){var f=n(".autoplay-video"),t,r,u,i;f.each(function(){(t=n(this).attr("href"),i="href",t||(t=n(this).attr("data-src-url"),i="data-src-url",t))&&(r=t.search("youtube.com"),u=t.search("autoplay=1"),r>=0&&u<0&&n(this).attr(i,t+"?autoplay=1"))})},desktop2mobileSwitch:function(){mobileVideoThumbObj=n(".mobile-play");mobileVideoThumbObj.on("click",function(){n(this).next(".mobile-play-container").hasClass("hidden")&&(n(this).addClass("hidden").next(".mobile-play-container").removeClass("hidden"),n(this).next(".mobile-play-container").attr("src",n(this).next(".mobile-play-container").attr("data-src-url")))})}};n(document).ready(function(){RL.fancyboxvideo.init();RL.fancyboxvideo.autoplay();RL.fancyboxvideo.desktop2mobileSwitch()})})(jQuery),function(n){RL.faq={init:function(){var t=n("section.faq"),i;t.length&&(i=n(".question .reveal, .answer .reveal").click(RL.faq.showHideFAQ),n("section.faq .rich-text-limited").css("height","260px"),RL.faq.ellipsis(n(".rich-text-limited")),RL.faq.scanRichTextLinks(),n("section.faq .rich-text-limited").css("height","auto"))},showHideFAQ:function(t){t.stopPropagation();var u=n(this),i=u.parent().parent(),r=i.siblings();return i.hasClass("moved")?(i.removeClass("moved"),r.removeClass("moved")):(i.addClass("moved"),r.addClass("moved")),!1},scanRichTextLinks:function(){var t=n("section.faq .rich-text-limited a");t.each(function(){n(this).hasClass("theme-text")||n(this).addClass("theme-text")})},ellipsis:function(t){return t.each(function(){var t=n(this),r=t.html(),i=n(this.cloneNode(!0)).hide().css("position","absolute").css("overflow","visible").width(t.width()).height("auto");if(t.after(i),i.height()>t.height()){while(r.length>0&&i.height()>t.height())r=r.substr(0,r.length-1),i.html(r+"...");t.html(i.html())}else t.css("height:","auto;");i.remove()})}};n(document).ready(function(){RL.faq.init()})}(jQuery),function(n){RL.newsGrid={init:function(){var t=n("section.news-grid, section.blog-grid");t.length&&n(window).resize(function(){var t=n(".mobile-slick-carousel-news-grid");n.each(t,function(){window.innerWidth>RL.breakpoint_md?n(this).hasClass("slick-initialized")&&n(this).slick("unslick"):n(this).hasClass("slick-initialized")||n(this).slick({slidesToShow:1,arrows:!1,appendDots:n(this).parent().find(".slick-mobile-pagination-news-grid"),dots:!0})})}).trigger("resize")}};n(document).ready(function(){RL.newsGrid.init()})}(jQuery),function(n){RL.newsCarousel={init:function(){var t=n("section.news-carousel");t.length&&(n(window).resize(function(){var t=n(".mobile-slick-carousel-news-carousel");n.each(t,function(){window.innerWidth>=RL.breakpoint_md?n(this).hasClass("slick-initialized")&&n(this).slick("unslick"):n(this).hasClass("slick-initialized")||n(this).slick({slidesToShow:1,arrows:!1,appendDots:n(this).parent().find(".slick-mobile-pagination-news-carousel"),dots:!0})})}).trigger("resize"),RL.newsCarousel.desktopInteractions())},desktopInteractions:function(){var i=n(".news-carousel .desktop .controls > div"),t=n(".news-carousel .desktop .desktop-slide-container > .img");t.css({width:t.first().width()+100});i.first().addClass("active");t.first().addClass("animate");i.on("click",function(){if(n(this).hasClass("active"))return!1;i.removeClass("active");n(this).addClass("active");t.each(function(){n(this).hasClass("animate")&&(n(this).removeClass("animate").addClass("more"),setTimeout(function(){t.removeClass("more")},500))});t.eq(n(this).index()).addClass("animate")})}};n(document).ready(function(){RL.newsCarousel.init()})}(jQuery),function(n){RL.contentswitch={init:function(){var u=n("section.content-switch");if(u.length){var t=n("#contentSwitchController"),i=n("#contentSwitchControllerMobile"),r=n("#contentSwitchSlides");RL.contentswitch.interaction(t,i,r);RL.contentswitch.firstLoad(t,i,r)}},firstLoad:function(t,i,r){t.children("li").eq(0).addClass("active");r.children("div.slide-container").eq(0).addClass("selected");n(".navigation-mobile-selection").html(t.find(".active").children("div").text()+'<span class="glyphicon glyphicon-chevron-down"><!-- --><\/span>');n(window).resize(function(){n(window).width()<=750?r.find("div.slide-container").each(function(){n(this).hasClass("selected")?(r.css({height:r.children("div.slide-container.selected").outerHeight(),overflow:"hidden"}),n(this).css({display:"block"})):n(this).css({display:"none"})}):r.attr("style","")})},interaction:function(t,i,r){t.children("li").on("click",function(i){if(i.preventDefault(),n(this).hasClass("active"))return!1;n(this).hasClass("active")||(t.children("li").removeClass("active"),n(this).addClass("active"),r.children("div.slide-container").removeClass("selected"),r.children("div.slide-container").eq(n(this).index()).addClass("selected"));n(".navigation-mobile-selection").html(t.find(".active").children("div").text()+'<span class="glyphicon glyphicon-chevron-down"><!-- --><\/span>')});n("ul.navigation-mobile").children("li").on("click",function(){n("ul.navigation-mobile").is(":visible")&&n("ul.navigation-mobile").slideUp(100);n(this).hasClass("active")||(n("ul.navigation-mobile").children("li").removeClass("active"),t.children("li").removeClass("active"),t.children("li").eq(n(this).index()).addClass("active"),n(this).addClass("active"),r.children("div.slide-container").removeClass("selected").hide(0),r.children("div.slide-container").eq(n(this).index()).show(0).addClass("selected"),r.height(r.children("div.slide-container").eq(n(this).index()).outerHeight()),n(".navigation-mobile-selection").html(n("ul.navigation-mobile").find(".active").children("div").text()+'<span class="glyphicon glyphicon-chevron-down"><!-- --><\/span>'))});i.on("click",function(t){t.preventDefault();n("ul.navigation-mobile").is(":hidden")?n("ul.navigation-mobile").slideDown(100):n("ul.navigation-mobile").slideUp(100)})}}}(jQuery),function(n){RL.pagehero={init:function(){var t=n("section.page-hero");t.length&&(n(window).width()<=750?(n(".page-hero .ll-carousel-item").first().addClass("animate-fade").css({width:"100%"}),n(".page-hero .ll-carousel").css({height:n(".page-hero .ll-carousel-item").first().outerHeight()}).addClass("animate-mobile-height")):n(".page-hero .ll-carousel-item").addClass("desktop-slide").first().addClass("animate-slide").css({width:n(window).width()+200}),n(".ll-carousel-control-btn").first().addClass("active"),RL.carouselSettings.pageHero.refreshTimer=n(".page-hero").find("[data-autoplay-timer]").attr("data-autoplay-timer"),RL.pagehero.controls(),RL.pagehero.resize(),RL.pagehero.autoPlayInit())},sideControls:function(){var i=n(".page-hero").children(),t=n(".ll-carousel-controls-bg");i.mouseenter(function(){t.addClass("expand-controls")}).mouseleave(function(){t.removeClass("expand-controls")})},autoPlayInit:function(){var i=n(".page-hero .ll-carousel-item"),t;i.length<=1||RL.carouselSettings.pageHero.refreshTimer!=="0"&&(t=n(".page-hero").children(),RL.carouselSettings.pageHero.timeOut=setTimeout(function(){RL.pagehero.autoPlayChangeSlide()},RL.carouselSettings.pageHero.refreshTimer),t.mouseenter(function(){clearTimeout(RL.carouselSettings.pageHero.timeOut);RL.carouselSettings.pageHero.timeOut=null}).mouseleave(function(){RL.carouselSettings.pageHero.timeOut=setTimeout(function(){RL.pagehero.autoPlayChangeSlide()},RL.carouselSettings.pageHero.refreshTimer)}))},autoPlayRestart:function(){RL.carouselSettings.pageHero.refreshTimer!=="0"&&Modernizr.mq("(min-width: 768px)")&&(clearTimeout(RL.carouselSettings.pageHero.timeOut),RL.carouselSettings.pageHero.timeOut=null,RL.carouselSettings.pageHero.timeOut=setTimeout(function(){RL.pagehero.autoPlayChangeSlide()},RL.carouselSettings.pageHero.refreshTimer))},autoPlayChangeSlide:function(){var r=n(".page-hero .ll-carousel-controls .controls li"),t=n(".page-hero .ll-carousel .ll-carousel-item"),i=n(".page-hero .ll-carousel-items");t.last().hasClass("animate-slide")||t.last().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade"),n(".page-hero .ll-carousel-item:first").addClass("animate-fade")):(t.last().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.last().removeClass("animate-more")},300),n(".page-hero .ll-carousel-item:first").addClass("animate-slide")):n(window).width()<RL.breakpoint_sm?i.find(".animate-fade").removeClass("animate-fade").next(".ll-carousel-item").addClass("animate-fade"):(currentSlide=i.find(".animate-slide").index(),i.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300),t.eq(currentSlide+1).addClass("animate-slide"));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".page-hero .ll-carousel-item.animate-slide, .page-hero .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.pagehero.adjustContentHeight();RL.pagehero.autoPlayRestart()},resize:function(){var t=n(".page-hero .ll-carousel-item"),i=n(".page-hero .ll-carousel");n(window).on("resize",function(){t.each(function(){n(this).css({width:n(window).width()<=750?"100%":n(window).width()+200});n.trim(n(this).find("div.inner-content-wrapper").text()).length<=0&&n(this).find("div.inner-bg-wrapper").css("display","none")});n(window).width()<=750?(i.hasClass("animate-mobile-height")||i.addClass("animate-mobile-height"),i.css({height:n(".page-hero .animate-fade").outerHeight()}),t.removeClass("desktop-slide"),t.each(function(){n(this).hasClass("animate-slide")&&n(this).removeClass("animate-slide").addClass("animate-fade")})):(i.hasClass("animate-mobile-height")&&i.removeClass("animate-mobile-height").attr("style",""),t.addClass("desktop-slide"),t.each(function(){n(this).hasClass("animate-fade")&&n(this).removeClass("animate-fade").addClass("animate-slide")}))})},controls:function(){var r=n(".page-hero .ll-carousel-controls .controls li"),t=n(".page-hero .ll-carousel .ll-carousel-item"),i=n(".page-hero .ll-carousel-items");if(t.size()<=1){r.hide(0);return}t.swipe({swipeRight:function(u,f){f==="right"&&(t.first().hasClass("animate-slide")||t.first().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade"),n(".page-hero .ll-carousel-item:last").addClass("animate-fade")):(t.first().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.first().removeClass("animate-more")},300),n(".page-hero .ll-carousel-item:last").addClass("animate-slide")):n(window).width()<RL.breakpoint_sm?i.find(".animate-fade").removeClass("animate-fade").prev(".ll-carousel-item").addClass("animate-fade"):(currentSlide=i.find(".animate-slide").index(),i.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300),t.eq(currentSlide-1).addClass("animate-slide")));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".page-hero .ll-carousel-item.animate-slide, .page-hero .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.pagehero.adjustContentHeight();RL.pagehero.autoPlayRestart()},swipeLeft:function(u,f){f==="left"&&(t.last().hasClass("animate-slide")||t.last().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade"),n(".page-hero .ll-carousel-item:first").addClass("animate-fade")):(t.last().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.last().removeClass("animate-more")},300),n(".page-hero .ll-carousel-item:first").addClass("animate-slide")):n(window).width()<RL.breakpoint_sm?i.find(".animate-fade").removeClass("animate-fade").next(".ll-carousel-item").addClass("animate-fade"):(currentSlide=i.find(".animate-slide").index(),i.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300),t.eq(currentSlide+1).addClass("animate-slide")));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".page-hero .ll-carousel-item.animate-slide, .page-hero .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.pagehero.adjustContentHeight();RL.pagehero.autoPlayRestart()},threshold:120});r.on("click",function(){t.eq(n(this).index()).hasClass("animate-slide")||t.eq(n(this).index()).hasClass("animate-fade")||(r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")}),n(this).children(".ll-carousel-control-btn").addClass("active"),t.each(function(){(n(this).hasClass("animate-more")||n(this).hasClass("animate-slide")||n(this).hasClass("animate-fade"))&&(n(window).width()<RL.breakpoint_sm?n(this).removeClass("animate-fade"):(n(this).removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300)))}),t.eq(n(this).index()).hasClass("animate-slide")&&t.eq(n(this).index()).hasClass("animate-fade")||(n(window).width()<RL.breakpoint_sm?t.eq(n(this).index()).addClass("animate-fade"):t.eq(n(this).index()).addClass("animate-slide"),RL.pagehero.adjustContentHeight(),RL.pagehero.autoPlayRestart()))})},adjustContentHeight:function(){var t=n(".page-hero .ll-carousel");n(window).width()<RL.breakpoint_sm?t.css({height:n(".page-hero .ll-carousel-item.animate-fade").outerHeight()+20}).addClass("animate-mobile-height"):t.removeClass("animate-mobile-height").attr("style","")}};n(document).ready(function(){RL.pagehero.init()})}(jQuery),function(n){n.widget("ll.pageheroVideo",{_create:function(){var t=this,i=this.element.find("#videoHeroController"),r=i.html();if(t.videohasplayed=!1,t.minwidth=1007,i.length){n(i).find("video").on("playing",function(){n(window).width()>=t.minwidth&&t.element.find(".img-container").hide();t.videohasplayed=!0});n(window).on("resize.video",function(){n(window).width()<t.minwidth?(t.element.find(".img-container").show(),i.hide()):t.videohasplayed&&(t.element.find(".img-container").hide(),i.show())})}},_destroy:function(){n(widow).off("resize.video")}});n(document).ready(function(){n(".page-hero-video").pageheroVideo()})}(jQuery),function(n){RL.propertyListing={selectedOptions:{},controller:n("section.property-filter"),filterInit:function(){var t,i,r;n(".property-list .toggle-bar").on("click",".btn",function(t){t.preventDefault();t.stopPropagation();n(t.currentTarget).hasClass("active")||n(".property-list .toggle-bar .btn").toggleClass("active");n(t.currentTarget).is(".toggle-map")?n(".property-grid").fadeOut(function(){n.event.trigger({type:"propertymapfadein"});n(".property-map").fadeIn(function(){})}):n(".property-map").fadeOut(function(){n(".property-grid").fadeIn()})});if(n(".property-map").hide(),t=RL.propertyListing.controller,t.length){i=n(".menu-more");r=t.find(".option-btn");t.find('ul[data-default != ""]').each(function(){var t=n(this).parents(".select").attr("data-name");RL.propertyListing.selectedOptions[t]=n(this).attr("data-default")});r.on("click",function(){i.toggleClass("hideme")});t.on("click",".selection",function(){n(this).parent().hasClass("active")?n(this).parent().removeClass("active"):(t.find(".select").hasClass("active")&&t.find(".select").removeClass("active"),n(this).parent().addClass("active"))});t.find(".select ul").on("click","li",function(){var t=n(this),i=t.parents(".select"),r;t.index()!==0&&(i.removeClass("active"),i.children(".selection").text(n(this).text()),r=i.attr("data-name"),RL.propertyListing.selectedOptions[r]=t.attr("data-value"),RL.propertyListing.triggerUpdate(!0))});window.onpopstate=function(t){var i,r,u;if(t.state){RL.propertyListing.selectedOptions=t.state;n(RL.propertyListing.controller).find(".select").each(function(){n(this).find(".selection").text(n(this).find(".field-name .theme-text").text())});for(i in RL.propertyListing.selectedOptions)RL.propertyListing.selectedOptions.hasOwnProperty(i)&&(r=n(RL.propertyListing.controller).find(".select[data-name='"+i+"']"),r.length===1&&(u=n(r).find("li[data-value='"+RL.propertyListing.selectedOptions[i]+"']"),u.length>0&&n(r).find(".selection").text(n(u).text())));RL.propertyListing.triggerUpdate()}}}},triggerUpdate:function(t){var i,o,u,f;if(t){var s=RL.propertyListing.controller.attr("data-baseurl")+"/",r=[],e=[];for(i in RL.propertyListing.selectedOptions)if(RL.propertyListing.selectedOptions.hasOwnProperty(i))if(i=="MSLINK")r.push("type-"+RL.propertyListing.selectedOptions.MSLINK);else if(i=="MinBeds")r.push("bedrooms-"+RL.propertyListing.selectedOptions.MinBeds);else if(i=="Stories")r.push("storeys-"+RL.propertyListing.selectedOptions.Stories);else if(i=="MinPrice"||i=="MaxPrice")continue;else i!="pagesize"&&e.push(i+"="+RL.propertyListing.selectedOptions[i]);(RL.propertyListing.selectedOptions.MinPrice||RL.propertyListing.selectedOptions.MaxPrice)&&(o="",u="between",o=RL.propertyListing.selectedOptions.MaxPrice?"-"+RL.propertyListing.selectedOptions.MaxPrice:"-any",RL.propertyListing.selectedOptions.MinPrice?u+="-"+RL.propertyListing.selectedOptions.MinPrice:u="-any",r.push(u+o));f=s.replace(/(:\/\/)|(\/)+/g,"$1$2");r.length>0&&(f+=r.join("-and-"));e.length>0&&(f+="?"+e.join("&"));history.pushState(RL.propertyListing.selectedOptions,"",f)}else history.replaceState(RL.propertyListing.selectedOptions,"");n.event.trigger({type:"propertyFilterChange",filterData:RL.propertyListing.selectedOptions,time:new Date})}}}(jQuery),function(n){RL.share={init:function(){var t=n("section.share-this");t.length&&(RL.share.shareInteraction(),RL.share.favInteraction(),RL.share.cookieCheck())},shareInteraction:function(){var t=n(".share-button"),i=n(".property-details .social-links");t.on("click",function(t){t.preventDefault();var i=n(t.delegateTarget).parents(".share");n(t.delegateTarget).toggleClass("active");i.next(".social-links").toggleClass("collapsed")})},favInteraction:function(){var i=n(".fav-button"),t=[],r;n(".share .text-center h1").on("click",function(){n.removeCookie("RLFav")});i.on("click",function(){r=RL.share.cookieCheck();t=n.parseJSON(RL.share.cookieGet("RLFav"));r===!1&&(t.push({guid:n(this).attr("data-share-id")}),RL.share.cookieWrite("RLFav",JSON.stringify(t)));r===!0&&(n.each(t,function(n){if(t[n].guid==i.attr("data-share-id"))return t.splice(n,1),!1}),i.find("span.icon").hasClass("favourites-filled")&&i.find("span.icon").removeClass("favourites-filled").removeClass("theme-text").addClass("favourites"),RL.share.cookieWrite("RLFav",JSON.stringify(t)))})},links:function(){var i=n("a[data-share-link]"),t;i.length&&(t=function(n,t){t.attr("href",n+window.location.href)},i.each(function(){switch(n(this).attr("data-share-link")){case"facebook":t(RL.sharingURL.facebook,n(this));break;case"pinterest":t(RL.sharingURL.pinterest,n(this));break;case"twitter":t(RL.sharingURL.twitter,n(this));break;case"googleplus":t(RL.sharingURL.googleplus,n(this));break;case"linkedin":t(RL.sharingURL.linkedin,n(this))}}))},cookieCheck:function(){var t=[],r=!1,u=n(".fav-button").find("span.icon"),i;if(RL.share.cookieGet("RLFav")&&RL.share.cookieGet("RLFav")!="undefined"||RL.share.cookieWrite("RLFav",JSON.stringify(t)),t=n.parseJSON(RL.share.cookieGet("RLFav")),t.length<=0)return r;for(i=0;i<t.length;i++)t[i].guid==n(".fav-button").attr("data-share-id")&&(u.hasClass("favourites")&&u.removeClass("favourites").addClass("favourites-filled").addClass("theme-text"),r=!0);return r},cookieWrite:function(t,i){n.cookie(t,i,{expires:365,path:"/"});RL.share.cookieCheck()},cookieGet:function(t){return t?n.cookie(t):n.cookie()}};n(document).ready(function(){RL.share.init()})}(jQuery),function(n){RL.contentbreakout={init:function(){var t=n("section.content-breakout");t.length&&(n(window).width()<=750?(n(".content-breakout .ll-carousel-item").first().addClass("animate-fade").css({width:"100%"}),n(".content-breakout .ll-carousel").css({height:n(".content-breakout .ll-carousel-item").first().outerHeight()}).addClass("animate-mobile-height")):n(".content-breakout .ll-carousel-item").addClass("desktop-slide").first().addClass("animate-slide").css({width:n(window).width()+200}),slideContent=n(".content-breakout .ll-carousel-item").first().find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent),n(".content-breakout .ll-carousel-control-btn").first().addClass("active"),RL.carouselSettings.contentBreakout.refreshTimer=n(".content-breakout").find("[data-autoplay-timer]").attr("data-autoplay-timer"),RL.contentbreakout.controls(),RL.contentbreakout.resize(),RL.contentbreakout.autoPlayInit())},autoPlayInit:function(){var i=n(".content-breakout .ll-carousel-item"),t;i.length<=1||RL.carouselSettings.contentBreakout.refreshTimer!=="0"&&(t=n(".content-breakout").children(),RL.carouselSettings.contentBreakout.timeOut=setTimeout(function(){RL.contentbreakout.autoPlayChangeSlide()},RL.carouselSettings.contentBreakout.refreshTimer),t.mouseenter(function(){clearTimeout(RL.carouselSettings.contentBreakout.timeOut);RL.carouselSettings.contentBreakout.timeOut=null}).mouseleave(function(){RL.carouselSettings.contentBreakout.timeOut=setTimeout(function(){RL.contentbreakout.autoPlayChangeSlide()},RL.carouselSettings.contentBreakout.refreshTimer)}))},autoPlayRestart:function(){RL.carouselSettings.contentBreakout.refreshTimer!=="0"&&(clearTimeout(RL.carouselSettings.contentBreakout.timeOut),RL.carouselSettings.contentBreakout.timeOut=null,RL.carouselSettings.contentBreakout.timeOut=setTimeout(function(){RL.contentbreakout.autoPlayChangeSlide()},RL.carouselSettings.contentBreakout.refreshTimer))},autoPlayChangeSlide:function(){var r=n(".content-breakout .ll-carousel-controls .controls li"),i=n(".content-breakout .ll-carousel .ll-carousel-item"),t=n(".content-breakout .ll-carousel-items");i.last().hasClass("animate-slide")||i.last().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(t.find(".animate-fade").removeClass("animate-fade"),n(".content-breakout .ll-carousel-item:first").addClass("animate-fade"),slideContent=t.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(i.last().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.last().removeClass("animate-more")},300),n(".content-breakout .ll-carousel-item:first").addClass("animate-slide"),slideContent=t.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):n(window).width()<RL.breakpoint_sm?(t.find(".animate-fade").removeClass("animate-fade").next(".ll-carousel-item").addClass("animate-fade"),slideContent=t.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(currentSlide=t.find(".animate-slide").index(),t.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.find(".animate-more").removeClass("animate-more")},300),i.eq(currentSlide+1).addClass("animate-slide"),slideContent=t.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".content-breakout .ll-carousel-item.animate-slide, .content-breakout .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.contentbreakout.adjustContentHeight();RL.contentbreakout.autoPlayRestart()},resize:function(){var t=n(".content-breakout .ll-carousel-item"),i=n(".content-breakout .ll-carousel");n(window).on("resize",function(){t.each(function(){n(this).css({width:n(window).width()<=750?"100%":n(window).width()+200})});RL.contentbreakout.adjustContentHeight();n(window).width()<=750?(i.hasClass("animate-mobile-height")||i.addClass("animate-mobile-height"),n(".content-breakout .animate-fade").outerHeight()>0&&i.css({height:n(".content-breakout .animate-fade").outerHeight()}),t.removeClass("desktop-slide"),t.each(function(){n(this).hasClass("animate-slide")&&n(this).removeClass("animate-slide").addClass("animate-fade")})):(i.hasClass("animate-mobile-height")&&i.removeClass("animate-mobile-height").attr("style",""),t.addClass("desktop-slide"),t.each(function(){n(this).hasClass("animate-fade")&&n(this).removeClass("animate-fade").addClass("animate-slide")}))})},changeFloatedContent:function(t){var i=n(".fixed-floated .floated-content .content-insert");i.removeClass("animate-fade");setTimeout(function(){i.empty().html(t);i.addClass("animate-fade")},300)},controls:function(){var r=n(".content-breakout .ll-carousel-controls .controls li"),t=n(".content-breakout .ll-carousel .ll-carousel-item"),u=n(".content-breakout .ll-carousel .ll-carousel-item, .fixed-floated"),i=n(".content-breakout .ll-carousel-items");if(t.size()<=1){r.hide(0);return}u.swipe({swipeRight:function(u,f){f==="right"&&(t.first().hasClass("animate-slide")||t.first().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade"),n(".content-breakout .ll-carousel-item:last").addClass("animate-fade"),slideContent=i.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(t.first().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.first().removeClass("animate-more")},300),n(".content-breakout .ll-carousel-item:last").addClass("animate-slide"),slideContent=i.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade").prev(".ll-carousel-item").addClass("animate-fade"),slideContent=i.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(currentSlide=i.find(".animate-slide").index(),i.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300),t.eq(currentSlide-1).addClass("animate-slide"),slideContent=i.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".content-breakout .ll-carousel-item.animate-slide, .content-breakout .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.contentbreakout.adjustContentHeight();RL.contentbreakout.autoPlayRestart()},swipeLeft:function(u,f){f==="left"&&(t.last().hasClass("animate-slide")||t.last().hasClass("animate-fade")?n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade"),n(".content-breakout .ll-carousel-item:first").addClass("animate-fade"),slideContent=i.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(t.last().removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){t.last().removeClass("animate-more")},300),n(".content-breakout .ll-carousel-item:first").addClass("animate-slide"),slideContent=i.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):n(window).width()<RL.breakpoint_sm?(i.find(".animate-fade").removeClass("animate-fade").next(".ll-carousel-item").addClass("animate-fade"),slideContent=i.find(".animate-fade").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(currentSlide=i.find(".animate-slide").index(),i.find(".animate-slide").removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300),t.eq(currentSlide+1).addClass("animate-slide"),slideContent=i.find(".animate-slide").find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)));r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")});r.eq(n(".content-breakout .ll-carousel-item.animate-slide, .content-breakout .ll-carousel-item.animate-fade").index()).children(".ll-carousel-control-btn").addClass("active");RL.contentbreakout.adjustContentHeight();RL.contentbreakout.autoPlayRestart()},threshold:120});r.on("click",function(){t.eq(n(this).index()).hasClass("animate-slide")||t.eq(n(this).index()).hasClass("animate-fade")||(r.find(".ll-carousel-control-btn").each(function(){n(this).hasClass("active")&&n(this).removeClass("active")}),n(this).children(".ll-carousel-control-btn").addClass("active"),t.each(function(){(n(this).hasClass("animate-more")||n(this).hasClass("animate-slide")||n(this).hasClass("animate-fade"))&&(n(window).width()<RL.breakpoint_sm?n(this).removeClass("animate-fade"):(n(this).removeClass("animate-slide").addClass("animate-more"),setTimeout(function(){i.find(".animate-more").removeClass("animate-more")},300)))}),t.eq(n(this).index()).hasClass("animate-slide")&&t.eq(n(this).index()).hasClass("animate-fade")||(n(window).width()<RL.breakpoint_sm?(t.eq(n(this).index()).addClass("animate-fade"),slideContent=t.eq(n(this).index()).find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)):(t.eq(n(this).index()).addClass("animate-slide"),slideContent=t.eq(n(this).index()).find(".floated-content").html(),RL.contentbreakout.changeFloatedContent(slideContent)),RL.contentbreakout.adjustContentHeight(),RL.contentbreakout.autoPlayRestart()))})},adjustContentHeight:function(){var t=n(".content-breakout .ll-carousel");n(window).width()<=750?(t.css({height:n(".content-breakout .ll-carousel-item.animate-fade").outerHeight()}),t.hasClass("animate-mobile-height")||t.addClass("animate-mobile-height")):t.removeClass("animate-mobile-height").attr("style","")}};n(document).ready(function(){RL.contentbreakout.init()})}(jQuery),function(n){RL.mobilecarousel={init:function(){n(window).resize(function(){var t=n(".mobile-slick-carousel");n.each(t,function(){window.innerWidth>=RL.breakpoint_sm?n(this).hasClass("slick-initialized")&&n(this).slick("unslick"):n(this).hasClass("slick-initialized")||n(this).slick({slidesToShow:1,arrows:!1,appendDots:n(this).siblings(".carousel-pagination").find(".slick-mobile-pagination"),dots:!0})})}).trigger("resize")}};n(document).ready(function(){RL.mobilecarousel.init()})}(jQuery),function(n){RL.contentGrid={init:function(){var t=n(".content-grid");t.length&&(n(window).resize(function(){n.each(t.find(".container:eq(0)"),function(){window.innerWidth>=RL.breakpoint_xs?n._data(t.find(".reveal-content")[0],"events")||RL.contentGrid.interaction(t):t.find(".reveal-content").off("click")})}).trigger("resize"),RL.contentGrid.interaction(t))},interaction:function(t){var i=t.find(".grid-item.reveal");if(window.innerWidth>=RL.breakpoint_xs)t.find(".grid-item.reveal").on("mouseover",function(t){t.preventDefault();i.addClass("collapsing").removeClass("expanded");n(this).addClass("expanded").removeClass("collapsing")})}};n(document).ready(function(){RL.contentGrid.init()})}(jQuery),function(n){RL.localStorage={init:function(){},addItem:function(t,i){var u=n(t),r=JSON.parse(localStorage.getItem(i.name)),f;if(r){if(Array.isArray(r)&&r.length===i.maxnumber)return!1;f=RL.localStorage.checkforItem(u.attr("data-property-id"),i.name);f||r.push({id:parseInt(u.attr("data-property-id")),url:u.attr("data-property-url")})}else r=[],r.push({id:parseInt(u.attr("data-property-id")),url:u.attr("data-property-url")});return localStorage.setItem(i.name,JSON.stringify(r)),!0},getItem:function(n){return JSON.parse(localStorage.getItem(n.name))},removeItem:function(t,i){var r=JSON.parse(localStorage.getItem(i.name));r=n.grep(r,function(n){return n.id!=t});localStorage.setItem(i.name,JSON.stringify(r))},checkforItem:function(n,t){var i=JSON.parse(localStorage.getItem(t.name));if(!i)return!1;for(h=0;i.length>h;h++)if(parseInt(n)===parseInt(i[h].id))return!0;return!1}};n(document).ready(function(){RL.localStorage.init()})}(jQuery),function(n){RL.colCalculator={detachedVillageOptions:{},formSubmitted:!1,redirectQuerystring:"",controller:n(".costofliving-wrapper"),init:function(){RL.colCalculator.initControls();RL.colCalculator.initPopup();RL.colCalculator.loadVillages(n("#ddl_state").val());n("#calculateCosts").show();n(".costofliving-wrapper .costofliving-cost-table.main table").clone(!0).appendTo(".costofliving-wrapper .costofliving-cost-table.main").addClass("clone");n(".costofliving-wrapper .costofliving-cost-table.main table tbody")},initControls:function(){n("#ddl_village").on("change",function(){location.href="?village="+this.value+"#costofliving-top"});n("#ddl_state").on("change",function(){RL.colCalculator.loadVillages(this.value)});n("#popup-trigger").hide();n(".icon-Personwho_does_know_costs_white").hide();n("#calculateCosts").click(function(){var r,t,i;jsonData=[];r=25;t=0;n(".calculateExpense").each(function(){var i={};i.id=r;i.value=n(this).val();jsonData.push(i);t+=Number(n(this).val());r++});n(".costSum").empty();n(".costSum").append("$"+t);n(".threeSisterSummaryBlockPrice").empty();n(".threeSisterSummaryBlockPrice").append("$"+t+" "+n(".threeSisterSummaryBlockPrice").data("perweeksymbol"));n(".icon-Personwho_doesnt_know_costs_white").hide();n(".icon-Personwho_does_know_costs_white").show();console.log("data: "+jsonData);i=JSON.stringify(jsonData);console.log("obj"+i);RL.colCalculator.setRedirectQuerystring("fd="+i);var u=n("#popup-trigger").attr("href"),f=n("#popup-trigger").data("download-url"),o=n("#ddl_village").val(),e=f+(f.indexOf("?")>=0?"&":"?")+"fd="+i,s=u+(u.indexOf("?")>=0?"&":"?")+"village="+o+"&_redirectqs="+encodeURIComponent(e);setCOLCookie("RLCOL",s,1);setCOLCookie("RLCOLQS",e,1);n("#popup-trigger").show()});n('input[type="number"]').on("input",function(){this.validity.valid||(this.value=1);n.isNumeric(this.value)||(this.value=0)})},initPopup:function(){var t=RL.colCalculator.controller.find("#popup-trigger");t.fancybox({fitToView:!0,autoSize:!0,autoResize:!0,preload:!0,modal:!1,openEffect:"fade",closeEffect:"fade",padding:0,type:"iframe",iframe:{scrolling:"auto"},beforeLoad:function(){console.log("not doing beforeLoad");this.href=RL.colCalculator.formSubmitted?getCOLCookie("RLCOL")+"&mode=download":getCOLCookie("RLCOL");console.log("RLCOL: "+getCOLCookie("RLCOL"))},afterClose:function(){RL.colCalculator.formSubmitted&&n("html, body").animate({scrollTop:"0px"},300)},helpers:{overlay:{closeClick:!1}}})},setFormSubmission:function(n){RL.colCalculator.formSubmitted=n},setRedirectQuerystring:function(n){RL.colCalculator.redirectQuerystring=n},loadVillages:function(t){t==""?RL.colCalculator.detachedVillageOptions=n("#ddl_village > option").slice(1).detach():(n("#ddl_village").append(RL.colCalculator.detachedVillageOptions),RL.colCalculator.detachedVillageOptions=n('#ddl_village > option[data-state!="'+t+'"]').slice(1).detach())}};n(document).ready(function(){RL.colCalculator.init()})}(jQuery)