function sortTable(n){var c,i,e,r,t,o,s,h,f,u,l=0;for(c=document.getElementById("table-enti"),r=!0,u="asc";r;){for(r=!1,i=c.rows,e=i[0].getElementsByTagName("th"),t=0;ts.innerHTML.toLowerCase()){f=!0;break}}else if(u=="desc"&&(h.classList.add("dir-desc"),o.innerHTML.toLowerCase()=992&&!n?(u.isotope(y),n=!0):$(window).width()<992&&n&&(u.isotope("destroy"),n=!1))}function v(){var t=$("html, body"),n=0;n=$("header").height();t.animate({scrollTop:$("[id='prenota_form']").offset().top-n},800)}var i,s,h,c,r,e,l,a;o();$(window).resize(function(){o()});$("#menu-toggle").click(function(){$("#search-toggle").hasClass("open")&&($("#search-toggle").removeClass("open"),$("body").toggleClass("menu-open"),$("#main-search").slideToggle(150));$(this).toggleClass("open");$("body").toggleClass("menu-open");$("#main-menu").slideToggle(150)});$("#search-toggle").click(function(){$("#menu-toggle").hasClass("open")&&($("#menu-toggle").removeClass("open"),$("body").toggleClass("menu-open"),$("#main-menu").slideToggle(150));$(this).toggleClass("open");$("body").toggleClass("menu-open");$("#main-search").slideToggle(150)});$(".headerbar .toolbar").hcSticky({stickTo:"body",followScroll:!1,onStart:function(){$(".menu-wrapper").css({top:$(".headerbar .toolbar.sticky").outerHeight()})},onStop:function(){$(".menu-wrapper").css({top:$(".headerbar").outerHeight()})},mobileFirst:!0,responsive:{992:{disable:!0}}});$(".survey-btn").tooltip({delay:{show:100,hide:0}});$('a[href*="#"]').not('[href="#"]').not('[data-toggle="collapse"]').not('[data-toggle="pill"]').not('[data-toggle="modal"]').not("[data-fancybox]").not('[href="#prenota_form"]').click(function(n){var t,i;location.pathname.replace(/^\//,"")===this.pathname.replace(/^\//,"")&&location.hostname===this.hostname&&(t=$(this.hash),t=t.length?t:$("[name="+this.hash.slice(1)+"]"),t.length&&(n.preventDefault(),i=$(window).width()>=992?$("header").outerHeight():0,$("html, body").animate({scrollTop:t.offset().top-i},800,function(){var n=$(t);if(n.focus(),n.is(":focus"))return!1;n.hasClass("collapse-paragraph")||n.attr("tabindex","-1");n.focus()})))});$('[class*="CMSListMenuLink"]').each(function(){$(this).attr("href").toString().toLowerCase().indexOf("http")>=0&&$(this).attr("target","_blank")});$(".label-placeholder .form-control").each(function(){if($(this).parent().prev(".sr-only").length){var n=$(this).parent().prev(".sr-only").text();$(this).attr("placeholder",n)}});$("#facility-badge-gallery").on("click",function(){$.fancybox.open(facility_gallery,{loop:!0,lazyLoad:"ondemand"})});$(".facility-badge.media-badge").children().length<=0&&$(".facility-badge.media-badge").css({opacity:0});$(".btn-quick-access[data-fancybox]").fancybox({parentEl:"form",baseClass:"quick-access-modal-wrapper",touch:!1,btnTpl:{smallBtn:'