Sorting of top-level categories.