Tree shadow flickering issue

Hi everyone. I have st9 speed trees in my Unreal engine 5.7 game scene whose shadows are flickering when the LODs switches for the tree. I have figured out this issue persists when the nanite is enabled.After disabling the nanite there is no such flickering issue. Apart from that when viewing the tree from very large distance in the top view and changing the FOV of the camera the shadows are pixelated. I am using virtual shadow maps in project settings. when using shadow maps in project settings, the flickering stops but the shadow becomes invisible from very large distance above from the tree. Is there any way to resolve this? any help would be appreciated.