Hong Kong lawmakers have unanimously passed a new tough national security bill that critics believe will curtail civil liberties.