added conditions to screen sizes