added more validation to satisfy css2 requirements