I started ridding a road bike about a month ago after being on a mountain bike my whole life. The different posture gave me neck pain for a couple weeks. But after fighting through it and commuting every day to work (only about 10km) I now have no neck pain. I would suggest just to push through the pain unless its excruciating, in which case go see a doctor.