As an alternative solution if this is too difficult to implement to Star Menu I could see a new building Bank. Bank would either automatically or with one button collect all the resources from Star Menu to its infinite (2⁶⁴-1) storage from where they could be transferred to mayor's house/storage. Resources could be transferred to Bank only through Star Menu, so it wouldn't enable any new ways to increase storage capacity, and resources in Bank can only be transferred to mayor's house/storage.
This isn't solution for buffs or adventures until those can be stacked in the same way as the resources.