Morphology-controlled synthesis, growth mechanism and optical properties of ZnO nanonails