jQuery(document).ready(function (){// alert(jQuery(window).width());jQuery(".mobile-nav-toggle").click(function(){jQuery(".header-footer-group").slideToggle("slide")});jQuery(".menu-txt").click(function(){jQuery(".header-footer-group").slideToggle("slide")});jQuery(".close-nav-toggle").click(function(){jQuery(".header-footer-group").slideToggle("slide")});if (jQuery('select[name="plans"]').length){jQuery('select[name="plans"] option:first-child').attr("disabled","disabled")}jQuery('.menu-item-has-children').click(function (){var $this=jQuery(this);$this.toggleClass('active-drop');// alert('hello')});//Animation if (jQuery(window).width()>768){AOS.init({duration:1000,once:true})}else{AOS.init({duration:0,once:true})}//Tooltips jQuery(function (){jQuery('[data-toggle="tooltip"]').tooltip()});//Plan if (jQuery(window).width()>768){jQuery('.plan-item').each(function (){var plan_color=jQuery(this).data('color');jQuery(this).find('.price,sup').css('color',plan_color);jQuery(this).find('.plan-arrow').css('border-top-color',plan_color);if (jQuery(this).hasClass('active')){jQuery(this).find('.plan-item-inner').css('border-color',plan_color)}})}else{jQuery('.plan-item').each(function (){var plan_color=jQuery(this).data('color');jQuery(this).find('.price,sup').css('color',plan_color);jQuery(this).find('.plan-arrow').css('border-top-color',plan_color);jQuery(this).addClass('active')})}jQuery('.plan-details').each(function (){var plan_color=jQuery(this).data('color');jQuery(this).find('.plan-detail-inner').css('background-color',plan_color)});if (jQuery(window).width()>768){jQuery('.plan-item').hover(function (){var plan_color=jQuery(this).data('color');jQuery('.plan-item').removeClass('active');jQuery(this).addClass('active');jQuery('.plan-item').find('.plan-item-inner').css('border-color','');jQuery(this).find('.plan-item-inner').css('border-color',plan_color)})}//Faq Accordion jQuery(".collapse.show").each(function (){jQuery(this).prev(".card-header").parent('.card').addClass("active")});jQuery(".collapse").on('show.bs.collapse',function (){jQuery(this).prev(".card-header").parent('.card').addClass("active")}).on('hide.bs.collapse',function (){jQuery(this).prev(".card-header").parent('.card').removeClass("active")});//Checkbox toggle var checkbox_item=jQuery('.wpcf7-checkbox').find(".wpcf7-list-item");checkbox_item.click(function (){var checkbox=jQuery(this).find('input[type="checkbox"]');checkbox.prop("checked",!checkbox.prop("checked"));jQuery(this).toggleClass("checked")});//Smooth Scroll var scroll=new SmoothScroll('a[href*="#"]',{speed:2000,offset:120,});//Web Font WebFont.load({google:{families:['Poppins:300,400,500,600,700,800']}});//Slide Animation var slide=jQuery(".ac-slide.active");slide.find('.slide-content').addClass('fadeIn animated');slide.find('.slide-mascot').addClass('fadeIn animated');//Databg attribute as background image var dataBgEle=jQuery('[data-bg]');dataBgEle.each(function (){var dataBg=jQuery(this).attr("data-bg");//alert(dataBg.length);if (dataBg.length>0){jQuery(this).css('background-image','url(https://www.hecklerlaw.com/wp-content/themes/hecklerlawgrop/js/+ dataBg +)')}});//Sticky Header Behavior var header=jQuery("header");var position=header.position();jQuery(window).scroll(function (){var windowPos=jQuery(window).scrollTop();if (windowPos>=position.top & windowPos>50){header.addClass("scroll")}else{header.removeClass("scroll")}});jQuery(".about-goal").on('click mouseover',function (){jQuery(".about-goal").removeClass('active');jQuery(this).addClass('active')});//partner-logos-carousel jQuery(document).ready(function (){jQuery('#know-expert').owlCarousel({loop:true,margin:0,nav:true,responsiveClass:true,navText:["<img src='https://hecklerlawgrop.wpengine.com/wp-content/uploads/2023/01/arrow-left.png' alt='arrow'>","<img src='https://hecklerlawgrop.wpengine.com/wp-content/uploads/2023/01/arrow-right.png' alt='arrow'>"],dots:false,responsive:{0:{items:1},600:{items:1},1000:{items:1}}});jQuery('#client-reviews').owlCarousel({loop:true,margin:20,slideSpeed:3000,nav:false,dots:true,autoplay:true,responsiveClass:true,responsive:{0:{items:1},600:{items:1},1000:{items:1},1024:{items:1}}})});jQuery(document).ready(function (){jQuery('#testimonial-slider').owlCarousel({loop:true,margin:20,slideSpeed:4000,nav:true,autoplay:false,dots:false,autoplayTimeout:40000,responsiveClass:true,responsiveClass:true,navText:["<img class='left-rotate arrow-icon' src='/wp-content/themes/hecklerlawgrop/images/arrow-white.png'>","<img class='right-rotate arrow-icon' src='/wp-content/themes/hecklerlawgrop/images/arrow-white.png'>"],responsive:{0:{items:1,},600:{items:2,},1000:{items:2},1024:{items:2},1280:{items:2},// breakpoint from 1024 up 1366:{items:2},// breakpoint from 1980 up 1980:{items:2,}}})});jQuery(document).ready(function (){jQuery('#post-slider').owlCarousel({loop:true,margin:15,slideSpeed:4000,nav:true,dots:false,autoplay:true,autoplayTimeout:4000,responsiveClass:true,responsiveClass:true,navText:["<img class='left-rotate arrow-icon' src='/wp-content/themes/hecklerlawgrop/images/blog-arrow.png'>","<img class='right-rotate arrow-icon' src='/wp-content/themes/hecklerlawgrop/images/blog-arrow.png'>"],responsive:{0:{items:1,},600:{items:2,},1000:{items:2},1024:{items:2},1280:{items:2.5},// breakpoint from 1024 up 1366:{items:2.5,},// breakpoint from 1980 up 1600:{items:3.5,}}})});//testimonial-carousel jQuery(document).ready(function (){var tCarousel=jQuery("#testimonial_carousel");var tLogo=jQuery("#testimonial_logo");var slidesPerPage=6;//globaly define number of elements per page var syncedSecondary=true;tCarousel.owlCarousel({items:1,slideSpeed:2000,nav:true,dots:false,autoplay:false,loop:true,responsiveRefreshRate:200,autoplayHoverPause:false,responsive:{// breakpoint from 0 up 0:{items:1,autoplay:false,},// breakpoint from 480 up 480:{items:1,autoplay:false,},// breakpoint from 768 up 768:{items:1,},// breakpoint from 1024 up 1024:{items:1,},// breakpoint from 1024 up 1366:{items:1,},// breakpoint from 1980 up 1980:{items:1,}}}).on('changed.owl.carousel',syncPosition);tLogo.on('initialized.owl.carousel',function (){tLogo.find(".owl-item").eq(0).addClass("current")}).owlCarousel({items:6,dots:false,infinite:true,margin:1,nav:false,autoplay:false,smartSpeed:2500,slideSpeed:4000,slideBy:slidesPerPage,//alternatively you can slide by 1,this way the active slide will stick to the first item in the second carousel responsiveRefreshRate:100,autoplayHoverPause:true,responsive:{// breakpoint from 0 up 0:{items:1,},// breakpoint from 480 up 480:{items:6,},// breakpoint from 768 up 768:{items:6,},// breakpoint from 1024 up 1024:{items:6,},1280:{items:6},// breakpoint from 1024 up 1366:{items:6,},// breakpoint from 1980 up 1980:{items:6,}}}).on('changed.owl.carousel',syncPosition2);function syncPosition(el){//if you set loop to false,you have to restore this next line //var current=el.item.index;//if you disable loop you have to comment this block var count=el.item.count - 1;var current=Math.round(el.item.index - (el.item.count / 2) - .5);if (current < 0){current=count}if (current>count){current=0}//end block tLogo .find(".owl-item") .removeClass("current") .eq(current) .addClass("current");var onscreen=tLogo.find('.owl-item.active').length - 1;var start=tLogo.find('.owl-item.active').first().index();var end=tLogo.find('.owl-item.active').last().index();if (current>end){tLogo.data('owl.carousel').to(current,100,true)}if (current < start){tLogo.data('owl.carousel').to(current - onscreen,100,true)}}function syncPosition2(el){if (syncedSecondary){var number=el.item.index;tCarousel.data('owl.carousel').to(number,100,true)}}tLogo.on("click",".owl-item",function (e){e.preventDefault();var number=$(this).index();tCarousel.data('owl.carousel').to(number,300,true)})})});