What country is the Chinese legal system based on