I'm in the process of creating a website similar to THIS. However, I am facing some issues with my background slider. It seems to be adding an extra slide to the right of the active slide, causing it to exceed the width limit. Additionally, the top div containing the slides does not transition to another div. As someone new to JavaScript, I find it challenging to troubleshoot these problems.
Below is the complete code:
// JavaScript code here
// CSS code here
// HTML markup here