How a pro-democracy activist in Hong Kong went from legislator to inmate