As you can see if you look at the data model, it's very simple and allows you to create topics that contain pages or other topics. The mapping between topics and pages is many-to-many; i.e. the same page can be referenced by more than one topic. So it seems very likely to me that you can use this topics system instead of your existing categories table.
The data model allows as many levels of nesting as you want; however, the registered procedure that serves /topics/* only handles two levels (topic/subtopic/page), since that's all the client needed. It would be easy enough to rewrite that part to remove that limitation.