From the bank:
\(\tan(60°) = \frac{h}{d} \quad \Rightarrow \quad h = \sqrt{3}d\)
After moving 40 m:
\(\tan(30°) = \frac{h}{d + 40} \quad \Rightarrow \quad \frac{1}{\sqrt{3}} = \frac{\sqrt{3}d}{d + 40}\)
\(\therefore\) d is equal to,
\(d + 40 = 3d \\ \Rightarrow d = 20 \, \text{meters}\)
The breadth of the river is 20 meters.