tn = document.getElementById("BacktoTop");
    window.onscroll = function () {
      scrollFunction();
    };

    function scrollFunction() {
      if (
        document.body.scrollTop > 50 ||
        document.documentElement.scrollTop > 50
      ) {
        scrollToTopBtn.style.visibility = "visible";
        scrollToTopBtn.style.opacity = "1";
      } else {
        scrollToTopBtn.style.visibility = "hidden";
        scrollToTopBtn.style.opacity = "0";
      }
    }

    scrollToTopBtn.addEventListener("