function getCookie(n){for(var t,r=n+"=",f=decodeURIComponent(document.cookie),u=f.split(";"),i=0;i<u.length;i++){for(t=u[i];t.charAt(0)==" ";)t=t.substring(1);if(t.indexOf(r)==0)return t.substring(r.length,t.length)}return""}function adjustCarouselFeaturesHeight(n){var t=$(".owl-carousel.carousel-features .owl-item").eq(n).height();$(".owl-carousel.carousel-features").height(t);$(".owl-carousel.carousel-features .owl-stage-outer").height(t);$(".owl-carousel.carousel-features .owl-stage-outer .owl-stage").height(t)}function adjustTopMenu(){var u=/*@cc_on!@*/!1||!!document.documentMode;if(u){var i=$("#top-navbar").css("width"),r=$("#top-navbar").offset(),n=$("#navbar-solution").offset(),t=r.left-n.left;$("#dropdown-solution").css("width",i);$("#dropdown-solution").css("left",t+"px");n=$("#navbar-services").offset();t=r.left-n.left;$("#dropdown-services").css("width",i);$("#dropdown-services").css("left",t+"px");n=$("#navbar-about").offset();t=r.left-n.left;$("#dropdown-about").css("width",i);$("#dropdown-about").css("left",t+"px")}}function CloseFeatherlight(){$(".featherlight-close").click()}function isValidDate(n){return/^(?=\d)(?:(?:31(?!.(?:0?[2469]|11))|(?:30|29)(?!.0?2)|29(?=.0?2.(?:(?:(?:1[6-9]|[2-9]\d)?(?:0[48]|[2468][048]|[13579][26])|(?:(?:16|[2468][048]|[3579][26])00)))(?:\x20|$))|(?:2[0-8]|1\d|0?[1-9]))([-.\/])(?:1[012]|0?[1-9])\1(?:1[6-9]|[2-9]\d)?\d\d(?:(?=\x20\d)\x20|$))?(((0?[1-9]|1[012])(:[0-5]\d){0,2}(\x20[AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2})?$/.test(n)}function isValidTime(n){var i=!0,t=n.split(":");return t.length!=2?i=!1:((isNaN(t[0])||isNaN(t[1]))&&(i=!1),t[0]<24&&t[1]<60||(i=!1)),i}function openServiceForm(n){lightbox?lightbox.open():lightbox=$.featherlight("#"+n,{persist:!0})}function openTrainingForm(n){lightbox?lightbox.open():lightbox=$.featherlight("#"+n,{persist:!0})}var offset,lightbox;(function(){const n=document.getElementById("Form_CustomFields[1]_UserInputValue");n!=null&&n.addEventListener("change",function(n){var t=new Date(this.value).getUTCDay();console.log(this);[6,0].includes(t)?n.target.setCustomValidity("Please consider that during weekend Sidel experts are not available. Make sure to select a business day."):n.target.setCustomValidity("")});$(window).width()<576&&$(".title-filter").click(function(){var n=$(this).attr("labelfor");$(this).hasClass("active")?($(this).removeClass("active"),$("."+n).removeClass("active")):($(this).addClass("active"),$("."+n).addClass("active"))});$("#refs-filter-mobile").click(function(){$("#gr-filters").hasClass("active")?$("#gr-filters").removeClass("active"):$("#gr-filters").addClass("active")});$("#refs-loadmore").click(function(){$("#global-references-list").removeClass("reduced");$(this).hide()});$("#open-filters").click(function(){$(this).removeClass("active");$("#close-filters").addClass("active");$("#liquid_area_filter").addClass("active")});$("#close-filters").click(function(){$(this).removeClass("active");$("#open-filters").addClass("active");$("#liquid_area_filter").removeClass("active")});$(".nav-link").click(function(){});$("#navbarSupportedContent .nav-item > a").click(function(){$("#navbarSupportedContent .nav-item > a").removeClass("active");$("#search-form").removeClass("active");$("#search").removeClass("active");$(this).closest("li").children("div").css("display")==="none"?$(this).addClass("active"):$(this).removeClass("active")});$("#search").click(function(){$("#navbarSupportedContent .nav-item > a").removeClass("active");$("#search").removeClass("active");$("#search-form").css("display")==="none"?($("#search-form").addClass("active"),$("#search").addClass("active")):($("#search-form").removeClass("active"),$("#search").removeClass("active"))})}).call(this),function(){function n(n){classie.add(n.target.parentNode,"input--filled")}function t(n){n.target.value.trim()===""&&classie.remove(n.target.parentNode,"input--filled")}String.prototype.trim||function(){var n=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;String.prototype.trim=function(){return this.replace(n,"")}}();[].slice.call(document.querySelectorAll("input.input__field")).forEach(function(i){i.value.trim()!==""&&classie.add(i.parentNode,"input--filled");i.addEventListener("focus",n);i.addEventListener("blur",t)})}(),function(n){"use strict";function f(n){return new RegExp("(^|\\s+)"+n+"(\\s+|$)")}function e(n,u){var f=t(n,u)?r:i;f(n,u)}var t,i,r,u;"classList"in document.documentElement?(t=function(n,t){return n.classList.contains(t)},i=function(n,t){n.classList.add(t)},r=function(n,t){n.classList.remove(t)}):(t=function(n,t){return f(t).test(n.className)},i=function(n,i){t(n,i)||(n.className=n.className+" "+i)},r=function(n,t){n.className=n.className.replace(f(t)," ")});u={hasClass:t,addClass:i,removeClass:r,toggleClass:e,has:t,add:i,remove:r,toggle:e};typeof define=="function"&&define.amd?define(u):n.classie=u}(window),function(n){"use strict";function r(n,t){if(!n)return!1;for(var i=n.target||n.srcElement||n||!1;i&&i!==t;)i=i.parentNode||!1;return i!==!1}function i(n,t){for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);return n}function t(n,t){this.el=n;this.options=i({},this.options);i(this.options,t);this._init()}t.prototype.options={newTab:!1,stickyPlaceholder:!0,onChange:function(){return!1}};t.prototype._init=function(){var n=this.el.querySelector("option[selected]");this.hasDefaultPlaceholder=n&&n.disabled;this.selectedOpt=n||this.el.querySelector("option");this._createSelectEl();this.selOpts=[].slice.call(this.selEl.querySelectorAll("li[data-option]"));this.selOptsCount=this.selOpts.length;this.current=this.selOpts.indexOf(this.selEl.querySelector("li.cs-selected"))||-1;this.selPlaceholder=this.selEl.querySelector("span.cs-placeholder");this._initEvents()};t.prototype._createSelectEl=function(){var r=this,n="",t=function(n){var i="",t="",r="";return!n.selectedOpt||this.foundSelected||this.hasDefaultPlaceholder||(t+="cs-selected ",this.foundSelected=!0),n.getAttribute("data-class")&&(t+=n.getAttribute("data-class")),n.getAttribute("data-link")&&(r="data-link="+n.getAttribute("data-link")),t!==""&&(i='class="'+t+'" '),"<li "+i+r+' data-option data-value="'+n.value+'"><span>'+n.textContent+"<\/span><\/li>"},i;[].slice.call(this.el.children).forEach(function(i){if(!i.disabled){var r=i.tagName.toLowerCase();r==="option"?n+=t(i):r==="optgroup"&&(n+='<li class="cs-optgroup"><span>'+i.label+"<\/span><ul>",[].slice.call(i.children).forEach(function(i){n+=t(i)}),n+="<\/ul><\/li>")}});i='<div class="cs-options"><ul>'+n+"<\/ul><\/div>";this.selEl=document.createElement("div");this.selEl.className=this.el.className;this.selEl.tabIndex=this.el.tabIndex;this.selEl.innerHTML='<span class="cs-placeholder">'+this.selectedOpt.textContent+"<\/span>"+i;this.el.parentNode.appendChild(this.selEl);this.selEl.appendChild(this.el)};t.prototype._initEvents=function(){var n=this;this.selPlaceholder.addEventListener("click",function(){n._toggleSelect()});this.selOpts.forEach(function(t,i){t.addEventListener("click",function(){n.current=i;n._changeOption();n._toggleSelect()})});document.addEventListener("click",function(t){var i=t.target;n._isOpen()&&i!==n.selEl&&!r(i,n.selEl)&&n._toggleSelect()});this.selEl.addEventListener("keydown",function(t){var i=t.keyCode||t.which;switch(i){case 38:t.preventDefault();n._navigateOpts("prev");break;case 40:t.preventDefault();n._navigateOpts("next");break;case 32:t.preventDefault();n._isOpen()&&typeof n.preSelCurrent!="undefined"&&n.preSelCurrent!==-1&&n._changeOption();n._toggleSelect();break;case 13:t.preventDefault();n._isOpen()&&typeof n.preSelCurrent!="undefined"&&n.preSelCurrent!==-1&&(n._changeOption(),n._toggleSelect());break;case 27:t.preventDefault();n._isOpen()&&n._toggleSelect()}})};t.prototype._navigateOpts=function(n){this._isOpen()||this._toggleSelect();var t=typeof this.preSelCurrent!="undefined"&&this.preSelCurrent!==-1?this.preSelCurrent:this.current;(n==="prev"&&t>0||n==="next"&&t<this.selOptsCount-1)&&(this.preSelCurrent=n==="next"?t+1:t-1,this._removeFocus(),classie.add(this.selOpts[this.preSelCurrent],"cs-focus"))};t.prototype._toggleSelect=function(){this._removeFocus();this._isOpen()?(this.current!==-1&&(this.selPlaceholder.textContent=this.selOpts[this.current].textContent),classie.remove(this.selEl,"cs-active")):(this.hasDefaultPlaceholder&&this.options.stickyPlaceholder&&(this.selPlaceholder.textContent=this.selectedOpt.textContent),classie.add(this.selEl,"cs-active"))};t.prototype._changeOption=function(){var t,i;typeof this.preSelCurrent!="undefined"&&this.preSelCurrent!==-1&&(this.current=this.preSelCurrent,this.preSelCurrent=-1);t=this.selOpts[this.current];this.selPlaceholder.textContent=t.textContent;this.el.value=t.getAttribute("data-value");i=this.selEl.querySelector("li.cs-selected");i&&classie.remove(i,"cs-selected");classie.add(t,"cs-selected");t.getAttribute("data-link")&&(this.options.newTab?n.open(t.getAttribute("data-link"),"_blank"):n.location=t.getAttribute("data-link"));this.options.onChange(this.el.value)};t.prototype._isOpen=function(){return classie.has(this.selEl,"cs-active")};t.prototype._removeFocus=function(){var n=this.selEl.querySelector("li.cs-focus");n&&classie.remove(n,"cs-focus")};n.SelectFx=t}(window),function(){[].slice.call(document.querySelectorAll("select.cs-select:not(.ignore-initialization)")).forEach(function(n){new SelectFx(n)})}();$(window).scroll(function(){$(this).scrollTop()>50?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()});$("#back-to-top").click(function(){var r=$(".button.sales.ccontact"),t,i,n;if(r[0]&&(t=r.find("a"),t[0])){t[0].click();return}i=getCookie("sidel_user_lang");n="/"+i;switch(i){case"en":default:n+="/contact-pa-63";break;case"de":n+="/kontakt-pa-63";break;case"es":n+="/contacto-pa-63";break;case"cn":n+="/%E8%81%94%E7%B3%BB%E6%88%91%E4%BB%AC-pa-63";break;case"pt":n+="/contato-pa-63";break;case"fr":n+="/contact-pa-63"}location.href=n;return});$(".navbar.anchors").length&&(offset=$(".navbar.anchors").offset().top,$(".navbar.anchors a").click(function(){$($.attr(this,"href")).animatescroll({scrollSpeed:1e3,easing:"easeOutCubic"})}),$(".navbar.anchors .cs-options li").click(function(){var n="#anchor-"+$(this).attr("data-value");$(n).trigger("click")}),$(window).scroll(function(){$(document).scrollTop()>offset?($(".container-fluid.prod-detail ").addClass("affix-on"),$(".parallax.first").addClass("affix-on"),$(".navbar.anchors").addClass("affix")):($(".container-fluid.prod-detail ").removeClass("affix-on"),$(".navbar.anchors").removeClass("affix"),$(".parallax.first").removeClass("affix-on"))}));$(document).ready(function(){function r(){var t="#"+$(".carousel-features .owl-item.active .item").attr("data-hash"),n;$(".nav-features > li > a").removeClass("active");$(".nav-solutionsteps > li > a").removeClass("active");$('li a[href="'+t+'"]').addClass("active");n=$(location).attr("hash");n!=""&&$("html").animate({scrollTop:$("#features").offset().top-100},"slow")}function u(){var n="#"+$(".solutionbeverages .owl-item.active .item").attr("data-hash");$(".nav-explore > li > a").removeClass("active");$('.nav-explore li a[href="'+n+'"]').addClass("active")}var t,i,n;if($(".home-news .owl-carousel").owlCarousel({loop:!1,center:!1,dots:!0,nav:!1,margin:30,responsiveClass:!0,responsive:{0:{items:1,dots:!0},500:{items:2,dots:!0},668:{items:3,dots:!0},1e3:{items:4,dots:!0},1878:{items:4,dots:!0}}}),$("#home-carousel.owl-carousel").owlCarousel({items:1,nav:!1,dots:!0,loop:!0,center:!0,autoplay:!0,autoplayTimeout:9e3,autoplayHoverPause:!0}),$("#pages-carousel.owl-carousel").owlCarousel({items:1,nav:!1,dots:!0,loop:!1,autoplay:!1}),$("span[data-toggle=popover]").popover({html:!0,content:function(){var n=$(this).attr("id");return $("#popover-content-"+n).html()}}),$(".owl-carousel.carousel-explore").owlCarousel({items:1,loop:!1,center:!0,nav:!0,margin:10,callbacks:!0,onDragged:u,onTranslated:u,URLhashListener:!0,startPosition:"URLHash"}),t=$(".solutionsteps .owl-carousel.carousel-explore"),t!=null&&t!=undefined)t.on("changed.owl.carousel",function(){var n=$(".popover.show");n!=null&&n!=undefined&&(n.each(function(n,t){$(t).popover("hide")}),resetImage())});i=$(".owl-carousel.carousel-features");i.on("initialized.owl.carousel",function(n){r(n)});i.owlCarousel({items:1,loop:!1,center:!0,nav:!1,margin:10,callbacks:!0,onDragged:r,URLhashListener:!0,autoHeight:!1,startPosition:"URLHash"});adjustCarouselFeaturesHeight(0);i.on("translated.owl.carousel",function(n){adjustCarouselFeaturesHeight(0);r(n)});$(".gallery .owl-carousel").owlCarousel({loop:!1,center:!1,nav:!1,dots:!0,margin:0,responsiveClass:!0,responsive:{0:{items:2,nav:!1,center:!0},668:{items:2},1e3:{items:3},1878:{items:3}}});$("#speakers .owl-carousel").owlCarousel({loop:!1,center:!1,nav:!1,dots:!0,margin:30,responsiveClass:!0,responsive:{0:{items:1,nav:!1},668:{items:2},1e3:{items:3},1878:{items:4}}});n=$(".eco_ou_gallery .owl-carousel").children();$(".eco_ou_gallery .owl-carousel").owlCarousel({loop:!1,center:!1,nav:!1,dots:!0,margin:0,responsiveClass:!0,responsive:{0:{items:1},576:{items:2},1e3:{items:n!==undefined&&n.length>0&&n.length<3?n.length:3}}});$(".nav-features a").click(function(){$(".nav-features a").removeClass("active");$(this).addClass("active")});$(".nav-solutionsteps a").click(function(){$(".nav-solutionsteps a").removeClass("active");$(this).addClass("active")});$(".nav-explore a").click(function(){$(".nav-explore a").removeClass("active");$(this).addClass("active")});$(".nav-explore a").click(function(){$(".nav-explore a").removeClass("active");$(this).addClass("active")})});$(function(){adjustTopMenu()});$(window).resize(function(){adjustTopMenu();$(window).width()<576&&$(".title-filter").click(function(){var n=$(this).attr("labelfor");$(this).hasClass("active")?($(this).removeClass("active"),$("."+n).removeClass("active")):($(this).addClass("active"),$("."+n).addClass("active"))})});lightbox=null