handleScrollFocus now finds the task closest to scrollTop (offset) instead of closest to the vertical center of the viewport. This ensures that the saved task matches the user's scroll target.
handleScrollFocus now finds the task closest to scrollTop (offset) instead of closest to the vertical center of the viewport. This ensures that the saved task matches the user's scroll target.