Structural, optical and NO2 gas sensing properties of ZnMgO thin films prepared by the sol gel method