According to Fraser the association between girls and pink goes back at least to the proto roman mythos. Rosey fingered dawn was a goddess not a god. This is probably deeply Freudian. Same as red lipstick.
Blue for boys is more tricky. The roman boys cloak had a purple stripe...or blue if you could not afford purple. It might derive from here but its a bit dubious....