Because hydrocarbons consist only C-H bonds, which are non-polar. When you look at the table of electronegativity (Pauling scale), you see, that the difference between the electronegativities of carbon and hydrogen is much smaller than that of nitrogen and hydrogen.