Rename internal::Type -> Category and some assorted things.

This is in preparation for a big Type/Category refactor coming up.