This sounds like perfect use case for notmuch. With notmuch You can use virtual mailboxes in mutt (kz patch, but I'm not able to find it on the project site) or natively with neomutt. I would say neomutt has better notmuch support.
Mailboxes must be synced localy. So You need other tool for syncing e-mails like offlineimap, isync or similar tools. You will probably want to set up post-sync hook for tagging messages (because tags are good for querying). I would recommend to sync only
All mails and let notmuch to take care of everything else using tags and queries.
Notmuch creates a xapian database. You define Your mailboxes using notmuch queries.
To "separate" Your accounts You can bind keys f.e.:
F1 - personal
F2 - work,
F3 - school,
F4 - … to source different config files.
# so Your directory structure will look like this:
exclude_tags=deleted;spam;trash #if You want to exclude some tags from query results
junk=tag:trash OR tag:spam OR tag:drafts OR from:@linkedin.com
lists=tag:Newsletters OR tag:Maillists
personal=NOT (tag:Work OR query:lists OR query:junk)
I use it that way.
in each of those files I have per-account settings (signratures, PGP, S/MIME keys or even colors) + at the end of per-account config files there's
source ~/.neomutt/neomuttrc.account-common with
status_format and other common configuration.
- offlineimap / isync / other tool - for e-mail synchronization
- offlineimap post-sync hook - to tag messages after synchronization
- notmuch - for tagging and querying and virtual mailboxes
- mutt / neomutt bindings for switching accounts or changing per account configuration
PS: It's easy to use once You get used to it. You need to change Your mindset. It requires some time to configure everything exactly as You want to. Don't give up, it's worth the time invested :)