I am designing a UI for a popup that would allow the user to share a post with one class at a time and select which class. They should also be able to drill into each class and select all or certain students within each class to post to. (The default would be share to all students in the class). I am currently using an accordion list of all classes that expands to then select or unselect students, but each list item is also selectable with a radio button. (see attached). This just seems wrong to me and overly complex interaction specially the fact that with the presence of radio button, I wouldn't have the ability to unselect all students once expanded if I just wanted to post to one student.
Are there any better approaches or standards to this problem anyone can think of?