Yes that is a more complex thing to do to have it seperate all variants on the collection page. You may need to hire and expert to help you customize your collections.liquid template to output your products in that manner.
One other solution is to use the app Findify which does this, however if only in the search results unless you sign up for their enterprise package. This app is the only app I have seen that does this correctly.
If there are other ways that I am not seeing please someone chime in :)