Equidistribution of the Fourier coefficients of Hecke cusp forms and applications