If I’m understanding correctly, what is wanted is accordion view triggered by hover.
I want to think this requires JavaScript.
But dropdown menus can reveal sub-menus on hover so there just might be a way to do this without JavaScript. I’ve been surprised at how much CSS can do more than once.