Changes css accordingly to jpegs