Especially for casting spells, a good way would be to have a "cast spell" button which then expands a context menu with all your cantrips + prepared spells, sorted by level.
Neverwinter Nights 2 had a nice quickcast feature like that, and so does Solasta.

Same could be done for any actions that work on "per rest" resource and are not coming from gear.

That way, hotbar would remain for anything you decide you use so often you really want it there instead of having to rely on it for basically everything.