function copyToClipboard(textToCopy){const $temp=$('<input>')
$('body').append($temp)
$temp.val(textToCopy).select()
document.execCommand('copy')
$temp.remove()};;
+function($){'use strict';var Tab=function(element){this.element=$(element)}
Tab.VERSION='3.3.1'
Tab.TRANSITION_DURATION=150
Tab.prototype.show=function(){var $this=this.element
var $ul=$this.closest('ul:not(.dropdown-menu)')
var selector=$this.data('target')
if(!selector){selector=$this.attr('href')
selector=selector&&selector.replace(/.*(?=#[^\s]*$)/,'')}
if($this.parent('li').hasClass('active'))return
var $previous=$ul.find('.active:last a')
var hideEvent=$.Event('hide.bs.tab',{relatedTarget:$this[0]})
var showEvent=$.Event('show.bs.tab',{relatedTarget:$previous[0]})
$previous.trigger(hideEvent)
$this.trigger(showEvent)
if(showEvent.isDefaultPrevented()||hideEvent.isDefaultPrevented())return
var $target=$(selector)
this.activate($this.closest('li'),$ul)
this.activate($target,$target.parent(),function(){$previous.trigger({type:'hidden.bs.tab',relatedTarget:$this[0]})
$this.trigger({type:'shown.bs.tab',relatedTarget:$previous[0]})})}
Tab.prototype.activate=function(element,container,callback){var $active=container.find('> .active')
var transition=callback&&$.support.transition&&(($active.length&&$active.hasClass('fade'))||!!container.find('> .fade').length)
function next(){$active.removeClass('active').find('> .dropdown-menu > .active').removeClass('active').end().find('[data-toggle="tab"]').attr('aria-selected',false)
element.addClass('active').find('[data-toggle="tab"]').attr('aria-selected',true)
if(transition){element[0].offsetWidth
element.addClass('in')}else{element.removeClass('fade')}
if(element.parent('.dropdown-menu')){element.closest('li.dropdown').addClass('active').end().find('[data-toggle="tab"]').attr('aria-selected',true)}
callback&&callback()}
$active.length&&transition?$active.one('bsTransitionEnd',next).emulateTransitionEnd(Tab.TRANSITION_DURATION):next()
$active.removeClass('in')}
function Plugin(option){return this.each(function(){var $this=$(this)
var data=$this.data('bs.tab')
if(!data)$this.data('bs.tab',(data=new Tab(this)))
if(typeof option=='string')data[option]()})}
var old=$.fn.tab
$.fn.tab=Plugin
$.fn.tab.Constructor=Tab
$.fn.tab.noConflict=function(){$.fn.tab=old
return this}
var clickHandler=function(e){e.preventDefault()
Plugin.call($(this),'show')}
$(document).on('click.bs.tab.data-api','[data-toggle="tab"]',clickHandler).on('click.bs.tab.data-api','[data-toggle="pill"]',clickHandler)}(jQuery);;;
(function($,window,document){function init(){$('.dropdown .top').on('click',function(){if($(this).hasClass('open')){$(this).siblings('ul').slideUp();$(this).removeClass('open');}else{$('.dropdown .top').removeClass('open')
$('.dropdown ul').slideUp();$(this).siblings('ul').slideDown();$(this).addClass('open');}
var clickedItem=$(this);var inputChildren=clickedItem.siblings('ul').children()
if(inputChildren.children().children('input:checkbox:checked').length>0){clickedItem.parent().addClass('active');$('.dropdown-mobile .top-toggle').addClass('active')}else{clickedItem.parent().removeClass('active');$('.dropdown-mobile .top-toggle').removeClass('active')}
$('.m-filters .active-filters .clear').on('click',function(){$('.dropdown').removeClass('active');$('.dropdown-mobile .top-toggle').removeClass('active')})});$('.dropdown').each(function(){if($(this).children('ul').children().children().children('input:checkbox:checked').length>0){$(this).addClass('active');}});$('.dropdown-mobile .top-toggle').on('click',function(){$(this).toggleClass('open');$(this).parent().toggleClass('open');$(this).siblings('.filters').show();$('.m-maptop').addClass('filter-active');$('body').addClass('filter-open');$('.dropdown-mobile .e-close').on('click',function(){$('.dropdown-mobile, .dropdown-mobile .top').removeClass('open');$('.m-maptop').removeClass('filter-active');$('.dropdown-mobile .filters').hide();$('body').removeClass('filter-open');});$('.dropdown-mobile .fa-search').on('click',function(){$('.dropdown-mobile, .dropdown-mobile .top').removeClass('open');$('.m-maptop').removeClass('filter-active');$('.dropdown-mobile .filters').hide();$('body').removeClass('filter-open');});$('.keyword input').on('keyup',function(e){if(e.keyCode===13){$('.dropdown-mobile, .dropdown-mobile .top').removeClass('open');$('.m-maptop').removeClass('filter-active');$('.dropdown-mobile .filters').hide();$('body').removeClass('filter-open');}});});}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){function closeProfilePopup(){$(document).on('click','.popup.save-notice .btn-outline',function(e){e.preventDefault();$('.popup.save-notice').remove();});}
function profileFilters(){$('.e-profilefilters li a').on('click',function(e){e.preventDefault();var selectedSection=$(this).attr('data-section');$(this).toggleClass('active');$(selectedSection).toggle('fade');});}
function myHIEDropdown(){var $allDropdowns=$(".e-dropdown .e-top");$(document).on('click',".e-dropdown .e-top",function(){$allDropdowns.not(this).removeClass('open');$allDropdowns.not(this).siblings('.e-more').hide();$(this).toggleClass('open');$(this).siblings('.e-more').slideToggle();});$(document).on('click',".e-dropdown .e-more .btn.btn-outline.green",function(e){e.preventDefault();$(this).parent().hide();});}
function generalFormDropdown(){$(document).on('click',".form-row.inline .dropdown-checkbox",function(){var clickedCheck=$(this);var clickedCheckParent=clickedCheck.parent();var clickedCheckText=$(this).text();var clickedCheckId=$(this).attr('data-id');var checkbox=$('#'+clickedCheckId);var clickedItemTop=clickedCheckParent.siblings('.e-top');$(this).toggleClass('checked');checkbox.prop('checked',!checkbox.prop('checked'));if(clickedCheck.hasClass('checked')){$('.e-dropdown .e-top').removeClass('open');clickedItemTop.removeClass('open').children().children('.e-placeholder').hide();$('<span data-selected="'+clickedCheckId+'">'+clickedCheckText+'</span>').appendTo(clickedItemTop.children('.inner'));}else if(!clickedCheck.hasClass('checked')){clickedItemTop.children('.inner').children('span[data-selected="'+clickedCheckId+'"]').remove();}
if(!clickedItemTop.children('.inner').children('span').length>0){clickedItemTop.children('.inner').children('.e-placeholder').show();}});}
$(function(){profileFilters();myHIEDropdown();generalFormDropdown();closeProfilePopup();});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){var breakingNewsActive=getCookie('BreakingNews');if(breakingNewsActive=='disabled'){$('.m-myhiebreaking').hide();}else{$('.m-myhiebreaking').show();}
$('.m-myhiebreaking .e-close a').on('click',function(e){e.preventDefault();setCookie('BreakingNews','disabled',1);$('.m-myhiebreaking').hide();});$('.m-myhiebreaking .e-slider').slick({rows:0,slide:'.e-item',prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>'});$('.m-dashboardlist .items').each(function(){$(this).on('init',function(event,slick){$(this).siblings('.e-slickcount').children('.e-total').text(slick.slideCount);});var $status=$(this).next('.pagingInfo');$(this).on('init reInit afterChange',function(event,slick,currentSlide,nextSlide){var i=(currentSlide?currentSlide:0)+1;$status.text(i+' of '+slick.slideCount);});$(this).slick({rows:0,arrows:false,mobileFirst:true,infinite:false,responsive:[{breakpoint:991,settings:"unslick",}]});});function getCookie(name){var nameEQ=name+"=";var ca=document.cookie.split(';');for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==' ')c=c.substring(1,c.length);if(c.indexOf(nameEQ)==0)return c.substring(nameEQ.length,c.length);}
return null;}});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){const notificationBanner=document.getElementById('notificationBanner');if(!notificationBanner)return
const closeNotificationBtn=notificationBanner.querySelector('.h-notificationbanner__btn');let bannerActive=getCookie('bannerState');if(bannerActive==='disabled'){document.body.classList.remove('notification');}else{notificationBanner.classList.remove('h-notificationbanner--hidden');}
closeNotificationBtn.addEventListener('click',(event)=>{event.preventDefault();setCookie('bannerState','disabled',1);notificationBanner.classList.add('h-notificationbanner--hidden');document.body.classList.remove('notification');var headerHeight=$('header').outerHeight();var browserHeight=$(window).outerHeight();enquire.register('screen and (max-width:1280px)',{unmatch:function(){$('.n-main').css({'top':'auto','height':' auto'});$('.n-main .e-sub').css({'top':'auto','height':' auto'});},match:function(){$('.n-main').css({'top':headerHeight+'px','height':browserHeight-headerHeight+'px'});$('.n-main .e-sub').css({'top':headerHeight+'px','height':browserHeight-headerHeight+'px'});}});})
function setCookie(name,value,days){var expires="";if(days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));expires="; expires="+date.toUTCString();}
document.cookie=name+"="+(value||"")+expires+"; path=/";}
function getCookie(name){var nameEQ=name+"=";var ca=document.cookie.split(';');for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==' ')c=c.substring(1,c.length);if(c.indexOf(nameEQ)==0)return c.substring(nameEQ.length,c.length);}
return null;}});})(window.jQuery,window,document);;;
var config={apiKey:'48b67fd15791729dc3b1398dcbe8ad5a27dac9e6',product:'PRO_MULTISITE',subDomains:false,encodeCookie:true,acceptBehaviour:'all',text:{title:'HOW WE USE COOKIES',intro:'We use cookies on this website. Some of them are necessary to make it work. Others are optional unless you enable them. '+CivicComputingOptions.cookiePolicyUrl,necessaryTitle:'Necessary cookies',necessaryDescription:'Necessary cookies are used to enable functionality, including security and preference setting throughout the site. Without them, you would not be able to use the site properly. These cookies can only be disabled through your own browser settings.',notifyTitle:"",notifyDescription:"This website uses cookies to ensure you get the best experience on our website.",accept:"Accept all cookies",settings:"Customise cookie settings",acceptRecommended:"Accept recommended settings",acceptSettings:"Accept recommended settings and close",closeLabel:"Close",},necessaryCookies:['UMB-XSRF-TOKEN','UMB-XSRF-V','UMB_UCONTEXT','UMB_UCONTEXT_C','XSRF-TOKEN','XSRF-V','UMB_UCONTEXT','UMB_UPDCHK','__RequestVerificationToken','ASP.NET_SessionId','bannerState','BreakingNews','hl_default','hs_default'],optionalCookies:[{name:'non-essential',label:'Non-essential cookies',description:'Non-essential cookies allow us to gather insights through analytics. They help us understand how people are using the site and how we can improve it.',cookies:['_ga',CivicComputingOptions.gatCookie,'_gid','_gat','__utma','__utmt','__utmb','__utmc','__utmz','__utmv','DSID','IDE','_fbp','1P_JAR','APISID','HSID','IDE','NID','SAPISID','SID','SIDCC','SSID'],onAccept:function(){window.dataLayer=window.dataLayer||[];dataLayer.push({'event':'analytics_consent_given'});},onRevoke:function(){if(isGoogleAnalyticsKey&&typeof ga==="function"){window[CivicComputingOptions.gaDisabled]=true;}
window.dataLayer=window.dataLayer||[];dataLayer.push({'event':'analytics_consent_removed'});if(typeof fbq==="function"){fbq('consent','revoke');}},recommendedState:true,lawfulBasis:"consent"}],position:'RIGHT',theme:'LIGHT',layout:"slideout",toggleType:'checkbox',closeStyle:'button',initialState:'open',rejectButton:false,setInnerHTML:true,branding:{fontFamily:"Roboto, arial, sans-serif",fontColor:"#1f1e1e",backgroundColor:"#fff",fontSizeTitle:"1.6em",fontSizeIntro:"1em",fontSizeHeaders:"1.25em",fontSize:"1em",toggleText:CivicComputingOptions.branding.toggleText,toggleColor:CivicComputingOptions.branding.toggleColor,toggleBackground:"#fff",alertBackground:CivicComputingOptions.branding.alertBackground,closeText:CivicComputingOptions.branding.closeText,closeBackground:"#fff",buttonIcon:null,buttonIconWidth:"64px",buttonIconHeight:"64px",removeIcon:false,removeAbout:true}};CookieControl.load(config);;;
(function($,window,document){function init(){$('.m-propertyhomepagebanner .e-navigation .inner').slick({fade:false,dots:false,arrows:false,rows:0,slide:'.e-item',slidesToShow:4,slidesToScroll:4,asNavFor:'.m-propertyhomepagebanner .e-carousel',autoplay:true,autoplaySpeed:10000,pauseOnHover:false,pauseOnFocus:false,accessibility:false});$('.m-propertyhomepagebanner .e-carousel').slick({fade:true,dots:false,arrows:false,rows:0,slide:'.e-item',asNavFor:'.m-propertyhomepagebanner .e-navigation .inner',autoplay:true,autoplaySpeed:10000,pauseOnHover:false,pauseOnFocus:false});$('.m-propertyhomepagebanner .e-navigation .inner .e-item').attr('tabindex','0')
$('.m-propertyhomepagebanner .e-navigation .inner .e-item').on('click',function(){$('.m-propertyhomepagebanner .e-carousel').slick('slickGoTo',jQuery(this).data('slickIndex'));});$('.m-propertyhomepagebanner .e-navigation .inner .e-item').keyup(function(e){if(e.keyCode===13){$('.m-propertyhomepagebanner .e-carousel').slick('slickGoTo',jQuery(this).data('slickIndex'));}});}
$(function(){setTimeout(function(){init();},800);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){function formValidation(){$('.m-form form').each(function(){$(this).validate({focusInvalid:false,invalidHandler:function(form,validator){if(!validator.numberOfInvalids())
return;$('html, body').animate({scrollTop:$(validator.errorList[0].element).offset().top-250},800);},errorPlacement:function(error,element){error.appendTo($(element).parent());}});$('.m-form form button').on('click',function(e){if(!$('.m-form form').valid()){e.preventDefault();}});});$('.e-reveal').on('click',function(){if($(this).hasClass('active')){$(this).removeClass('active');$(this).siblings('input').attr('type','password');}else{$(this).addClass('active');$(this).siblings('input').attr('type','text');}});}
function myHieProfileForm(){supportSelections=[];if($('input:checkbox[name="OrganisationTypeSelections"]:checked').val()!==''){supportSelections.push($('#currentSupportSelections').val());getSupportOptions(supportSelections);}
if($('input:checkbox[name="OrganisationTypeSelections"]:checked').val()!==''&&$('input:checkbox[name="OrganisationTypeSelections"]:checked').val()=='16420'){$('#OrganisationSizeOptions').show();$('#OrganisationName').show();}
$('input:checkbox[name="OrganisationTypeSelections"]').change(function(){if($('input:checkbox[name="OrganisationTypeSelections"]:checked').val()=='16420'){$('#OrganisationSizeOptions').show();$('#OrganisationName').show();}
else{$('#OrganisationSizeOptions').hide();$('#OrganisationName').hide();}
getSupportOptions(supportSelections);});}
function umbracoFormLoadCushion(){var fileUploads=[].slice.call(document.querySelectorAll("input[type='file']"));if(document.querySelector('input[data-form-upload-total-upload-restriction]')===null){return;}
if(!window.FileReader||fileUploads==undefined||fileUploads.length<1){return;}
var maxUploadBytes=(document.querySelector('input[data-form-upload-total-upload-restriction]').dataset.formUploadTotalUploadRestriction)*1024*1024;var numberOfFiles=(document.querySelector('input[data-form-upload-max-file-count]').dataset.formUploadMaxFileCount);maxUploadBytes=parseInt(maxUploadBytes);numberOfFiles=parseInt(numberOfFiles);console.log(maxUploadBytes,numberOfFiles);fileUploads.forEach(function(fu){var maxUploadSizePerInput=maxUploadBytes/numberOfFiles;var alertDiv=fu.parentNode.getElementsByClassName('alert-warning')[0];var preUploadText="File upload limit is "+formatBytes(maxUploadSizePerInput);var tickImage="<img src='/images/tick.png' style='width:16px;height:12px' />"
alertDiv.innerHTML=preUploadText;fu.onchange=function(){alertDiv.innerHTML=preUploadText;var failedUploadText="File upload limit is "+formatBytes(maxUploadSizePerInput)+". Your file was "+
formatBytes(fu.files[0].size)+". Please try again with a smaller version.";if(!fu.files){console.log("This browser doesn't seem to support the `files` property of file inputs.");}
else if(fu.files[0].size>maxUploadSizePerInput){alertDiv.innerHTML=failedUploadText;alertDiv.className="";alertDiv.classList.add('alert','alert-danger');fu.value=null;fu.files=null;}
else{alertDiv.className="";alertDiv.classList.add('alert','alert-success');alertDiv.innerHTML=tickImage+" Your file meets the size requirements";}}})}
function umbracoFormSubmitLoader(){if(document.querySelector('input[data-form-submit-loader]')!==null){var form=$('input[data-form-submit-loader]').closest('form');$(form).on('submit',function(e){window.onbeforeunload=function(){document.body.style.overflow='hidden';document.getElementById('animated-loading').style.display='flex';}});}}
function getSupportOptions(supportSelections){orgTypeSelections=[];$('input[name="OrganisationTypeSelections"]:checked').each(function(){orgTypeSelections.push($(this).val());});$.ajax({url:'/umbraco/api/SupportFinderApi/GetSupportOptions',type:'GET',data:{currentPageId:currentPageId,orgTypeSelections:orgTypeSelections.join(","),supportSelections:supportSelections},success:function(response){$(".supportOptions_ddl").empty();$(".supportOptions_cbx").empty();var len=response.length;for(var i=0;i<len;i++){var value=response[i]['Value'];var text=response[i]['Text'];var checked=response[i]['Selected']?"checked":"notchecked";$(".e-more.supportOptions_ddl").append("<div data-id="+'SupportSelection-'+value+" class='dropdown-checkbox "+checked+"'>"+text+"</div>");$(".e-checkboxes.supportOptions_cbx").append("<div class='checkbox'>"+"<input type='checkbox' name='SupportSelections' id="+'SupportSelection-'+value+" value='"+value+"' "+checked+">"+"<label for="+'SupportSelection-'+value+">"+text+"</label>"+"</div>");}
$('<a href="#" class="btn btn-outline green">Close</a>').appendTo('.e-more.supportOptions_ddl');},error:function(response){console.log(response);}});}
function formatBytes(a,b){if(b===undefined){b=2}
if(0===a)return"0 Bytes";const c=0>b?0:b,d=Math.floor(Math.log(a)/Math.log(1024));return parseFloat((a/Math.pow(1024,d)).toFixed(c))+" "+["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][d]}
myHieProfileForm();umbracoFormLoadCushion();umbracoFormSubmitLoader();setTimeout(function(){formValidation();},500);});(function($){$.validator.unobtrusive.adapters.addBool("checkboxrequired","required");}(jQuery));$.validator.addMethod('strongpassword',function(value,element){const rules=[/[A-Z]{1}/g,/[a-z]{1}/g,/[0-9]{1}/g,/[^a-zA-Z\d]{1}/g,/.{8,}/g];let isValid=true;for(let i=0;i<rules.length;i++){if(!value.match(rules[i])){isValid=false;break;}}
return this.optional(element)||isValid;},'Password must contain 1 uppercase letter, 1 lowercase letter, 1 number, 1 special character, and be at least 8 characters long');})(window.jQuery,window,document);;;
function toggleLink(){const toggleLinks=document.querySelectorAll('.js-toggle-link');if(!toggleLinks)return;const handleToggleClick=(link,content)=>{const state=link.getAttribute('aria-expanded');if(state==='false'){link.setAttribute('aria-expanded',true);content.classList.add('js-expanded');content.addEventListener("focusout",(event)=>handleFocusOut(event,link,content));}else{link.setAttribute('aria-expanded',false);content.classList.remove('js-expanded');content.removeEventListener("focusout",(event)=>handleFocusOut(event,link,content))}}
toggleLinks.forEach((link)=>{const toggleLink=link;const toggleTarget=document.getElementById(toggleLink.getAttribute('aria-controls'));toggleLink.addEventListener('click',(event)=>{event.preventDefault();handleToggleClick(toggleLink,toggleTarget);});})}
function handleFocusOut(event,link,content){if(event.relatedTarget!=null&&!content.contains(event.relatedTarget)){console.log('focus outside content area')
link.setAttribute('aria-expanded',false);content.classList.remove('js-expanded');}}
function handleOutsideClick(el){document.addEventListener('click',(e)=>{if(!el.contains(e.target.parentElement)&&!el.contains(e.target)){console.log('close everything down')}})}
toggleLink();;;
(function($,window,document){$(function(){$('.m-accordion .accordion-item .top').on('click',function(){$(this).parent().toggleClass('open');$(this).closest('.accordion-item').siblings().removeClass('open');$(this).closest('.accordion-item').siblings().children('.more').slideUp();$(this).siblings('.more').slideToggle();});$('.m-accordion .accordion-item .top').on('keyup',function(e){if(e.keyCode===13){$(this).parent().toggleClass('open');$(this).closest('.accordion-item').siblings().removeClass('open');$(this).closest('.accordion-item').siblings().children('.more').slideUp();$(this).siblings('.more').slideToggle();}});});})(window.jQuery,window,document);;;
(function($,window,document){function init(){$('.m-casestudypanel--carousel .inner').slick({dots:true,arrows:true,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>',responsive:[{breakpoint:991,settings:{arrows:false}}]});}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){function initCaseStudiesCarousel(){var $caseStudyCarousel=$('.m-factsheet-group--carousel');if(!$caseStudyCarousel)return;$caseStudyCarousel.each(function(){var $slickElement=$(this);$slickElement.slick({dots:true,arrows:false,infinite:false,speed:300,slidesToShow:2,slidesToScroll:2,adaptiveHeight:true,responsive:[{breakpoint:767,settings:{slidesToShow:1,slidesToScroll:1}}]});})}
$(function(){setTimeout(function(){initCaseStudiesCarousel();},1000);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){$('.m-companydetailsquote .e-mobtitle').each(function(){$(this).on('click',function(){$(this).siblings('.e-inner').slideToggle();$(this).toggleClass('open');});});});})(window.jQuery,window,document);;;
(function($,window,document){function init(){var originalHeight=$('.m-contactprofiles .e-more').outerHeight();var originalText=$('.m-contactprofiles .e-toggle span').text();if($('.m-contactprofiles .e-more').children().length>0){$('.m-contactprofiles .e-more').css({'height':'100px'});$('.m-contactprofiles .e-toggle span').on('click',function(){if(!$('.m-contactprofiles .e-more').hasClass('open')){$('.m-contactprofiles .e-more').animate({'height':originalHeight+'px'},300).addClass('open');$(this).text('Show less -');}else{$(this).text(originalText);$('.m-contactprofiles .e-more').animate({'height':'100px'},500).removeClass('open');}});}else{$('.m-contactprofiles .e-more, .m-contactprofiles .e-toggle').remove('.m-contactprofiles .e-more, .m-contactprofiles .e-toggle');}}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){setTimeout(function(){$('.m-fullwidthtext .truncated, .m-podcast .truncated').each(function(){var truncated=$(this);if(truncated.height()<350){truncated.children('.inner').contents().unwrap();truncated.children('.e-readmore').remove();}});},350);$('.m-fullwidthtext .e-readmore, .m-podcast .e-readmore').on('click',function(){if(!$(this).siblings().hasClass('open')){$(this).siblings('.inner').addClass('open');var totalHeight;totalHeight=0
$(this).siblings('.inner').children().each(function(){totalHeight+=$(this).outerHeight()+20;});$(this).siblings('.inner').css({"height":$(this).siblings('.inner'),"max-height":20000}).animate({"height":totalHeight});$(this).html('Read less -');return false;}else{$(this).html('Read more +');$(this).siblings('.inner').removeClass('open').css({"height":'auto',"max-height":350}).animate({"height":350});}});});})(window.jQuery,window,document);;;
(function($,window,document){$(window).on('load',function(){$('.m-campusmap .popup-slider').slick({dots:false,arrows:false,fade:true,rows:0,slide:'.e-item',draggable:false,});$('.m-campusmap .popup-slider').on('init',function(){$('.m-campusmap .popup').hide();$('.m-campusmap .e-iteminfo').hide();})
setTimeout(function(){$('.m-campusmap .popup-slider .item-slider').each(function(){$(this).slick({dots:true,arrows:false,rows:0,slide:'span'});});$('.m-campusmap .e-iteminfo .slider').slick({dots:false,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>',asNavFor:'.m-campusmap .popup-slider'});},10);$('.m-campusmap .e-pin').on('click',function(){console.log('clicked pin');var slideno=$(this).data('location');$('.m-campusmap .e-iteminfo, .m-campusmap .popup').show();$('.e-pin').hide();$('.m-campusmap .e-iteminfo .slider').slick('slickGoTo',slideno-1);$('.m-campusmap .popup-slider').slick('slickGoTo',slideno-1);$('.m-campusmap .e-iteminfo .slider').slick('resize');$('.m-campusmap .popup-slider').slick('resize');$('.m-campusmap .popup-slider .item-slider').slick('resize');});$('.m-campusmap .popup .e-close').on('click',function(){$('.m-campusmap .popup').fadeOut();$('.m-campusmap .e-iteminfo').fadeOut("fast",function(){$('.e-pin').show();});});});$(window).resize(function(){$('.m-campusmap .e-iteminfo .slider').slick('resize');$('.m-campusmap .popup-slider').slick('resize');$('.m-campusmap .popup-slider .item-slider').slick('resize');});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){setTimeout(function(){$(".m-imagetext .truncated").each(function(i,v){var truncated=$(v);if(truncated.prop("scrollHeight")<350){console.log(truncated,truncated.prop("scrollHeight"),"expanding scr");truncated.children(".inner").contents().unwrap();truncated.children(".e-readmore").remove();}});},350);$(".m-imagetext .e-readmore, .m-headerintro .e-readmore").on("click",function(){if(!$(this).siblings().hasClass("open")){$(this).siblings(".inner").addClass("open");var totalHeight;totalHeight=0;$(this).siblings(".inner").children().each(function(){totalHeight+=$(this).outerHeight()+20;});$(this).siblings(".inner").css({height:$(this).siblings(".inner"),"max-height":9999,}).animate({height:totalHeight,});$(this).html("Read less -");return false;}else{$(this).html("Read more +");$(this).siblings(".inner").removeClass("open").css({height:"auto","max-height":350,}).animate({height:350,});}});});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){var $ppc=$('.progress-pie-chart'),percent=parseInt($ppc.data('percent')),deg=360*percent/100;if(percent>50){$ppc.addClass('gt-50');}else if(percent===0){$ppc.addClass('gt-0');}
$('.ppc-progress-fill').css('transform','rotate('+deg+'deg)');var $smallppc=$('.small-progress-pie-chart'),smallpercent=parseInt($smallppc.data('percent')),smalldeg=360*smallpercent/100;if(smallpercent>50){$smallppc.addClass('gt-50');}else if(smallpercent===0){$smallppc.addClass('gt-0');}
$('.small-ppc-progress-fill').css('transform','rotate('+smalldeg+'deg)');});})(window.jQuery,window,document);;;
(function($,window,document){function init(){$('.m-imagetextoverlay .image-slider').slick({arrows:false,fade:true,draggable:false,asNavFor:'.m-imagetextoverlay .text .slider'});$('.m-imagetextoverlay .text .slider').slick({arrows:true,dots:false,asNavFor:'.m-imagetextoverlay .image-slider',arrows:true,adaptiveHeight:true,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>'});}
$(function(){setTimeout(function(){init();},800);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){setTimeout(function(){$('.m-infographic img').magnify({touchBottomOffset:90});},500);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){$('.m-latesttweets .e-carousel').each(function(){$(this).slick({dots:true,rows:0,slide:'.e-item',slidesToShow:4,slidesToScroll:4,arrows:false,autoplay:false,responsive:[{breakpoint:991,settings:{slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,arrows:false}},{breakpoint:767,settings:{slidesToShow:2,slidesToScroll:2,infinite:true,dots:true,arrows:false}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});});});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){if($('body').hasClass('osw')){$('.m-iconcarousel .e-carousel').each(function(){$(this).slick({dots:true,rows:0,slide:'.e-item',slidesToShow:4,slidesToScroll:4,arrows:true,autoplay:false,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>',responsive:[{breakpoint:767,settings:{slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,arrows:false}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});});}else{$('.m-iconcarousel .e-carousel').each(function(){$(this).slick({dots:true,rows:0,slide:'.e-item',slidesToShow:5,slidesToScroll:5,arrows:true,autoplay:false,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>',responsive:[{breakpoint:1500,settings:{slidesToShow:4,slidesToScroll:4,infinite:true,dots:true,arrows:false}},{breakpoint:767,settings:{slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,arrows:false}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});});}});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){function authors(){$('.authors .e-carousel').each(function(){$(this).slick({dots:true,rows:0,slide:'.slide',slidesToShow:1,slidesToScroll:1,arrows:false,autoplay:false});});}
function highlightsIcons(){$('.m-highlightsicons .e-carousel').each(function(){var $carousel=$(this);if($(window).width()>991){if($carousel.hasClass('slick-initialized')){$carousel.slick('unslick');}}else{if(!$carousel.hasClass('slick-initialized')){$carousel.slick({slidesToShow:4,slidesToScroll:4,infinite:true,dots:true,arrows:false,responsive:[{breakpoint:767,settings:{slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,arrows:false}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});}}
$(window).resize(function(){if($(window).width()>991){if($carousel.hasClass('slick-initialized')){$carousel.slick('unslick');}}else{if(!$carousel.hasClass('slick-initialized')){$carousel.slick({slidesToShow:4,slidesToScroll:4,infinite:true,dots:true,arrows:false,responsive:[{breakpoint:767,settings:{slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,arrows:false}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});}}});});}
authors();highlightsIcons();});})(window.jQuery,window,document);;;
(function($){$(function(){$(".m-newslettersignup").each(function(){const $root=$(this);const btn=$root.find("button[type=submit]");$(btn).on("click",function(e){e.preventDefault();$root.find("[js-emailaddress-error]").hide();$root.find("[js-newsletter-error]").hide();$root.find("[js-subscribed]").hide();let acceptPrivacyPolicy=$root.find("[js-accept-privacy-policy]").prop("checked");if(!acceptPrivacyPolicy){$root.find("[js-checkbox-error]").show();return;}else{$root.find("[js-checkbox-error]").hide();}
let emailAddress=$root.find("[js-email-address]").val();if(emailAddress===""){$root.find("[js-emailaddress-error]").show();return;}
if(emailAddress!==""&&acceptPrivacyPolicy){let listId=$root.data("list-id");$.post("/umbraco/api/NewsletterApi/Add",{emailAddress:emailAddress,acceptPrivacyPolicy:acceptPrivacyPolicy,currentPageId:currentPageId,listId:listId},function(){$root.find("[js-subscribed]").show();$root.find("form").hide();}).fail(function(){$root.find("[js-newsletter-error]").show();});}});});});})(window.jQuery);;;
(function($,window,document){function init(){const statsPanelSlick=document.querySelectorAll('.m-statspanel');var timeOutFunction;function resizeCompleteCheck(){let widthOutput=window.innerWidth;const slickWrappers=document.querySelectorAll('.m-statspanel .slick-initialized');if(widthOutput<1200&&slickWrappers.length===0){statsPanelSlick.forEach((el)=>initSlick(el));}
if(widthOutput>1200&&slickWrappers.length){$('.m-statspanel .row').slick('unslick');}}
window.addEventListener("resize",()=>{clearTimeout(timeOutFunction);timeOutFunction=setTimeout(resizeCompleteCheck,500);});function initSlick(el){const number=el.querySelector('.number');const slider=el.querySelector('.row');var $sliderVar=$(slider);for(const child of slider.children){const index=Array.prototype.indexOf.call(slider.children,child);const delayNumber=index*200;child.setAttribute('data-aos-delay',delayNumber);}
$sliderVar.slick({arrows:false,slidesToShow:3,slidesToScroll:3,infinite:true,dots:true,responsive:[{breakpoint:767,settings:{slidesToShow:2,slidesToScroll:2,infinite:true,dots:true}},{breakpoint:650,settings:{slidesToShow:1,slidesToScroll:1,infinite:true,dots:true}}]});}
if(window.matchMedia("(max-width: 1200px)").matches){statsPanelSlick.forEach((el)=>initSlick(el));}}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){setTimeout(function(){if($('.m-propertydetails-bottom .e-text .inner').height()<150){$('.m-propertydetails-bottom .e-text .inner').contents().unwrap();$('.m-propertydetails-bottom .e-text .more').remove();}},600);$('.m-propertydetails-top .more, .m-propertydetails-bottom .more').on('click',function(){if(!$(this).siblings().hasClass('open')){$(this).siblings('.inner').addClass('open');var totalHeight;totalHeight=0
$(this).siblings('.inner').children('p').each(function(){totalHeight+=$(this).outerHeight()+20;});$(this).siblings('.inner').css({"height":$(this).siblings('.inner'),"max-height":9999}).animate({"height":totalHeight});$(this).html('Read less -');return false;}else{$(this).html('Read more +');$(this).siblings('.inner').removeClass('open').css({"height":'auto',"max-height":140}).animate({"height":140});}});$('.m-propertydetails-top .e-gallery .main-carousel').on('init reInit afterChange',function(event,slick,currentSlide,nextSlide){var i=(currentSlide?currentSlide:0)+1;$('.m-propertydetails-top .e-gallery .total-carousel').text(i+' of '+slick.slideCount);});$('.m-propertydetails-top .e-gallery .main-carousel').slick({slidesToShow:1,slidesToScroll:1,arrows:true,fade:true,dots:false,adaptiveHeight:true,asNavFor:'.m-propertydetails-top .e-gallery .nav-carousel',prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>'});var centerModeChildren;if($('.m-propertydetails-top .e-gallery .nav-carousel img').length>3){centerModeChildren=true;}else{centerModeChildren=false;}
$('.m-propertydetails-top .e-gallery .nav-carousel').slick({slidesToShow:3,slidesToScroll:1,asNavFor:'.m-propertydetails-top .e-gallery .main-carousel',dots:false,centerMode:centerModeChildren,focusOnSelect:true,arrows:false});$('.m-propertydetails-top .e-close').on('click',function(){$('.m-propertydetails-top .e-text .m-tabs .nav-tabs li, .m-propertydetails-top .e-text .m-tabs .nav-tabs li a').removeClass('active');$('.m-propertydetails-top .e-text .m-tabs .tab-pane').removeClass('active');$(this).hide();});$('.m-propertydetails-top .e-text .m-tabs .nav-tabs li').on('click',function(){$('.m-propertydetails-top .e-close').show();});});})(window.jQuery,window,document);;;
(function($,window,document){function init(){console.log('init homepage carousel slick');$('.m-homepagebanner .e-cta').slick({arrows:false,slidesToShow:4,slidesToScroll:4,rows:0,slide:'a',responsive:[{breakpoint:767,settings:{slidesToShow:2,slidesToScroll:2,infinite:true,dots:true}}]});var firstVideo=$('#videoItem-1 iframe').attr('src');var secondVideo=$('#videoItem-2 iframe').attr('src');var thirdVideo=$('#videoItem-3 iframe').attr('src');var fourthVideo=$('#videoItem-4 iframe').attr('src');$('.m-homepagebanner .e-play').on('click',function(e){e.preventDefault();var activeVideo=$('.m-homepagebanner .e-videooverlay .tab-pane.active iframe').attr('src');$('.m-homepagebanner .e-videooverlay .tab-pane.active iframe').attr('src',activeVideo+'?autoplay=1');$('body').addClass('fixed');$('.m-homepagebanner .e-videooverlay').slideDown(function(){$('.m-homepagebanner .e-videooverlay .wrapper').fadeIn();});});$('.m-homepagebanner .e-close').on('click',function(){$('.m-homepagebanner .e-videooverlay .wrapper').fadeOut(function(){$('.m-homepagebanner .e-videooverlay').slideUp(function(){$('body').removeClass('fixed');});$('#videoItem-1 iframe').attr('src',firstVideo);$('#videoItem-2 iframe').attr('src',secondVideo);$('#videoItem-3 iframe').attr('src',thirdVideo);$('#videoItem-4 iframe').attr('src',fourthVideo);});});$('.m-homepagebanner .e-videooverlay .wrapper .inner .nav-tabs li a').on('click',function(){$('#videoItem-1 iframe').attr('src',firstVideo);$('#videoItem-2 iframe').attr('src',secondVideo);$('#videoItem-3 iframe').attr('src',thirdVideo);$('#videoItem-4 iframe').attr('src',fourthVideo);setTimeout(function(){var activeVideo=$('.m-homepagebanner .e-videooverlay .tab-pane.active iframe').attr('src');$('.m-homepagebanner .e-videooverlay .tab-pane.active iframe').attr('src',activeVideo+'?autoplay=1');},500);});}
$(function(){setTimeout(function(){init();},1000);});})(window.jQuery,window,document);;;
(function($,window,document){function init(){$('.m-carouselcomponent .description-slider').slick({arrows:false,dots:false,draggable:false,asNavFor:'.m-carouselcomponent .media-slider'});$('.m-carouselcomponent .media-slider').on('init reInit afterChange',function(event,slick,currentSlide,nextSlide){console.log('Count',slick.slideCount)
var i=(currentSlide?currentSlide:0)+1;$('.m-carouselcomponent .e-count').text(i+' / '+slick.slideCount);});$('.m-carouselcomponent .media-slider').slick({arrows:true,dots:false,asNavFor:'.m-carouselcomponent .description-slider',prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>'});}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){function init(){$('.m-threecardcarousel .carousel').slick({arrows:true,dots:true,slidesToShow:3,slidesToScroll:3,prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>',responsive:[{breakpoint:991,settings:{slidesToShow:2,slidesToScroll:2,arrows:false}},{breakpoint:500,settings:{slidesToShow:1,slidesToScroll:1,arrows:false}}]});}
$(function(){setTimeout(function(){init();},500);});})(window.jQuery,window,document);;;
(function($,window,document){$(function(){$('.m-venue .e-gallery .main-carousel').on('init reInit afterChange',function(event,slick,currentSlide,nextSlide){var i=(currentSlide?currentSlide:0)+1;$('.m-venue .e-gallery .total-carousel').text(i+' of '+slick.slideCount);});$('.m-venue .e-gallery .main-carousel').slick({slidesToShow:1,slidesToScroll:1,arrows:true,fade:true,dots:false,adaptiveHeight:true,asNavFor:'.m-venue .e-gallery .nav-carousel',prevArrow:'<button class="nav prev" aria-label="Previous slide"><i class="fa fa-angle-left" aria-hidden="true"></i></button>',nextArrow:'<button class="nav next" aria-label="Next slide"><i class="fa fa-angle-right" aria-hidden="true"></i></button>'});var centerModeChildren;if($('.m-venue.e-gallery .nav-carousel img').length>3){centerModeChildren=true;}else{centerModeChildren=false;}
$('.m-venue .e-gallery .nav-carousel').slick({slidesToShow:3,slidesToScroll:1,asNavFor:'.m-venue .e-gallery .main-carousel',dots:false,centerMode:centerModeChildren,focusOnSelect:true,arrows:false});});})(window.jQuery,window,document);;;
(function($,window,document){const documentBody=document.body;const navTriggerBtn=document.getElementById('nav-toggle-btn');function fixRTEButtonClasses(){const getAllNestedSpanLinks=document.querySelectorAll('a > span.btn');const getAllParentSpanLinks=document.querySelectorAll('p > span.btn');if(getAllNestedSpanLinks.length>=1){getAllNestedSpanLinks.forEach(y=>{y.parentNode.classList.add('btn');y.classList.remove('btn');})}
if(getAllParentSpanLinks.length>=1){getAllParentSpanLinks.forEach(els=>{if(els.firstChild.tagName==='A'){els.firstChild.classList.add('btn');els.classList.remove('btn');}})}}
function lazyLoadImage(){const observer=lozad('.lozad',{loaded:function(el){fitVidsTarget();}});observer.observe();}
function umbracoFormsCheckboxing(){var checkboxes=document.querySelectorAll('.umbraco-forms-container input[type="checkbox"][id]:not(span.checkboxlist input[type="checkbox"][id])');checkboxes.forEach((checkbox)=>{var checked=checkbox.checked;var checkedValue=checked;var checkboxesWithSameName=document.querySelectorAll(`.umbraco-forms-container *[name="${checkbox.name}"]`);checkboxesWithSameName.forEach((cb)=>{cb.checked=checked;cb.value=checkedValue;});});checkboxes.forEach((checkbox)=>{checkbox.addEventListener('input',(event)=>{var checked=checkbox.checked;var checkedValue=checked;var checkboxesWithSameName=document.querySelectorAll(`.umbraco-forms-container *[name="${checkbox.name}"]`);checkboxesWithSameName.forEach((cb)=>{cb.checked=checked;cb.value=checkedValue;});});});}
function AOSfix(){var scrolled=false;function refreshAOS(){if(!scrolled){AOS.refresh();scrolled=true;}else{window.removeEventListener('scroll',refreshAOS);}}
window.addEventListener('load',function(){window.addEventListener('scroll',refreshAOS);});}
function toggleNavReset(){Array.from(document.querySelectorAll('.nav-primary__link--btn')).forEach(function(el){const elTarget=document.getElementById(el.getAttribute('aria-controls'))
el.setAttribute("aria-expanded","false");elTarget.classList.remove('js-expanded');});}
function ariaExpandedToggle(link,target){let state=link.getAttribute("aria-expanded");if(state==='false'){link.setAttribute("aria-expanded","true");target.classList.add('js-expanded');target.addEventListener('focusout',(event)=>handleFocusOut(event,link,target));}else{link.setAttribute("aria-expanded","false");target.classList.remove('js-expanded');target.removeEventListener('focusout',(event)=>handleFocusOut(event,link,target));}}
function handleFocusOut(event,link,content){if(!content.contains(event.relatedTarget)){console.log('close everything')
link.setAttribute('aria-expanded',false);content.classList.remove('js-expanded');}}
function globalNavToggles(link,content){const state=link.getAttribute('aria-expanded');if(state==='false'){toggleNavReset();link.setAttribute('aria-expanded',true);content.classList.add('js-expanded');content.addEventListener('focusout',(event)=>handleFocusOut(event,link,content));documentBody.classList.add('takeover');}else{link.setAttribute('aria-expanded',false);content.classList.remove('js-expanded');content.removeEventListener('focusout',(event)=>handleFocusOut(event,link,content));documentBody.classList.remove('takeover');}}
function navToggle(){if(!navTriggerBtn)return;const navWrapper=document.getElementById(navTriggerBtn.getAttribute('aria-controls'));navTriggerBtn.addEventListener('click',(event)=>{event.preventDefault();ariaExpandedToggle(navTriggerBtn,navWrapper);toggleNavReset();searchCheck();})
documentBody.classList.remove('takeover');}
function navToggleLinks(){const toggleLinks=document.querySelectorAll('.nav-primary__link--btn');if(!toggleLinks)return;toggleLinks.forEach((link)=>{const toggleLink=link;const toggleTarget=document.getElementById(toggleLink.getAttribute('aria-controls'));toggleLink.addEventListener('click',(event)=>{event.preventDefault();globalNavToggles(toggleLink,toggleTarget);searchCheck();});})}
function searchToggle(){const searchTriggerBtn=document.getElementById('search-toggle-btn');if(!searchTriggerBtn)return;searchTriggerBtn.addEventListener('click',()=>{navTriggerBtn.setAttribute("aria-expanded","false");navWrapper.classList.remove('js-expanded');documentBody.classList.remove('takeover');toggleNavReset();});}
function searchCheck(){const searchTriggerBtn=document.getElementById('search-toggle-btn');if(!searchTriggerBtn)return
const searchWrapper=document.getElementById(searchTriggerBtn.getAttribute('aria-controls'));let searchState=searchTriggerBtn.getAttribute("aria-expanded");if(searchState==='true'){searchTriggerBtn.setAttribute("aria-expanded","false");searchWrapper.classList.remove('js-expanded');}}
function headerToggles(){$('.e-myhielink.dropdownlink').on('click',function(e){e.preventDefault();$('.h-myhiedropdown').slideToggle();$(document).keyup(function(e){if(e.key==="Escape"){$('.h-myhiedropdown').slideUp();}});});}
function headerScroll(){if(!document.body.classList.contains('hie')){$(window).on('load, scroll',function(){if($(window).scrollTop()>$('header').outerHeight()){$('header').addClass('slim');}else{$('header').removeClass('slim');}});}}
function fitVidsTarget(){if($('iframe[src*="youtube"]').length>0){$('iframe[src*="youtube"]').parent().fitVids();}
if($('iframe[src*="vimeo"]').length>0){$('iframe[src*="vimeo"]').parent().fitVids();}}
function cardListLoad(){$('.m-cardlist .row').each(function(){var cardItems=$(this).children();cardItems.each(function(index){var delayNumber=index*100;$(this).attr('data-aos-delay',delayNumber);});});}
function videoPopup(){$('a.play').magnificPopup({disableOn:0,type:'iframe',mainClass:'mfp-fade',removalDelay:160,preloader:false,fixedContentPos:false});$('span.play').magnificPopup({delegate:'a',disableOn:0,type:'iframe',mainClass:'mfp-fade',removalDelay:160,preloader:false,fixedContentPos:false});}
function copyToClipboard(){$('.share-link').on('click',function(){var clickedItem=$(this);var dummy=document.createElement('input'),text=window.location.href;document.body.appendChild(dummy);dummy.value=text;dummy.select();document.execCommand('copy');document.body.removeChild(dummy);clickedItem.children('.note').addClass('active')
setTimeout(function(){clickedItem.children('.note').removeClass('active');},1000)});}
function oswButtons(){$('.osw span.btn').each(function(){$(this).parent().addClass('no-style');});}
function anchorTags(){$("a").on('click',function(event){if(this.hash!==""&&!this.parent().hasClass('.nav-item')||!this.classList.contains('play')){event.preventDefault();var hash=this.hash;$('html, body').animate({scrollTop:$(hash).offset().top+230},800,function(){window.location.hash=hash;});}});}
function mapInfoClose(){$('.m-mapview .e-iteminfo .close').on('click',function(){$(this).closest('.e-iteminfo').attr('data-status','closed');});}
function propertyListing(){var cardItem=$('.l-propertylisting #locationsTab .row .m-cardcomponent a');cardItem.on('click',function(){$('.m-tabs ul.nav-tabs li').removeClass('active');$('#list-tab').parent().addClass('active');$('html, body').animate({scrollTop:$('#list-tab').offset().top-150},1000);});}
function propertyAlerts(){$('.property-alerts').on('click',function(e){e.preventDefault();$('body').addClass('fixed');$('.m-propertyalerts').slideDown({start:function(){$(this).css({display:'flex'})},done:function(){$('.m-propertyalerts .popup').fadeIn();}});});$('.m-propertyalerts .e-close').on('click',function(){$('.m-propertyalerts .popup').fadeOut(function(){$('.m-propertyalerts').slideUp(function(){$('body').removeClass('fixed');});});});}
$(function(){lazyLoadImage();umbracoFormsCheckboxing();navToggle();navToggleLinks();searchToggle();headerToggles();headerScroll();fitVidsTarget();videoPopup();oswButtons();copyToClipboard();fixRTEButtonClasses();mapInfoClose();propertyListing();propertyAlerts();setTimeout(function(){AOSfix();},800);});$.extend(true,$.magnificPopup.defaults,{iframe:{patterns:{youtube:{index:'youtube.com',id:function(src){var mt=src.match(/v=([^&]+)(&(.*))?/);if(mt)
return mt[1]+'?'+mt[3];mt=src.match(/embed\/([^\?\/]+)(\?(.*))?/);if(mt)
return mt[1]+'?'+mt[3];},src:'//www.youtube.com/embed/%id%&autoplay=1&rel=0'}}},callbacks:{beforeOpen:function(){if($(window).width()<700)
this.st.focus=false;}}});})(window.jQuery,window,document);;;
