The sun can damage your hair—unless you take these steps