You are committing a common mistake for this problem. Adding up the minimum distances from individual paths will not be the minimum distance for the overall path.
Here is my explanation on another solution with an approach similar to yours.
https://discuss.codechef.com/t/wa-in-the-problem-phcul/44226/4?u=shridharravi97