more changes and added dynamic bg sizing