lucais commited on
Commit
7686850
·
verified ·
1 Parent(s): 621dab2

Add smooth scrolling and working anchor links to the entire page. Make sure there are invisible divs with id="leadform", id="pricingSection", and id="successStories" directly above the correct sections. Then, make sure all buttons or nav links labeled "Book a Call", "Pricing", and "Success Stories" point to those IDs and scroll to them smoothly. Do not add any new sections or visual content — just restore scroll behavior. - Follow Up Deployment

Browse files
Files changed (1) hide show
  1. index.html +27 -0
index.html CHANGED
@@ -624,6 +624,33 @@
624
  icon.classList.add('fa-plus');
625
  }
626
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
627
  </script>
628
 
629
  <!-- Video Modal -->
 
624
  icon.classList.add('fa-plus');
625
  }
626
  }
627
+
628
+ // Smooth scrolling for anchor links
629
+ document.querySelectorAll('a[href^="#"]').forEach(anchor => {
630
+ anchor.addEventListener('click', function (e) {
631
+ e.preventDefault();
632
+ const targetId = this.getAttribute('href');
633
+ if (targetId === '#') return;
634
+
635
+ const targetElement = document.querySelector(targetId);
636
+ if (targetElement) {
637
+ targetElement.scrollIntoView({
638
+ behavior: 'smooth',
639
+ block: 'start'
640
+ });
641
+ }
642
+ });
643
+ });
644
+
645
+ // Handle programmatic scrolls to anchors
646
+ if (window.location.hash) {
647
+ const target = document.querySelector(window.location.hash);
648
+ if (target) {
649
+ setTimeout(() => {
650
+ target.scrollIntoView({ behavior: 'smooth' });
651
+ }, 100);
652
+ }
653
+ }
654
  </script>
655
 
656
  <!-- Video Modal -->