Studies of hot B subdwarfs. III - Carbon, nitrogen, and silicon abundances in three sdB stars