Structural and optoelectronic properties, and infrared spectrum of cubic BaSnO3 from first principles calculations