Added screen resize functionality for States