I think categories as a class is cool.
Ultinately, Classes should be usergroups (I think) ...
Either way, a field (i.e. select dynamic set to multiple, with storage as varchar50) that stores multiple category id’s would work, and then you can filter this entry using the correct match settings in search form (any words exact, with it configured to “,”).
What about access to class ie blocked, absent etc?