Find the value of $\left(1+\cos \frac{\pi}{5}\right)\left(1+\cos \frac{3 \pi}{5}\right)$. The original answer is in the form of \frac{k}{m}, please provide the value of k + m.

Let's think step by step and output the final answer within \boxed{}.
user