I've been looking for software that does this myself, but I don't think it exists.
There used to be a project, https://bazil.org/, that promised to do it. The website is still up, but it has not been updated in years.
The existing tool closest to what I envision is git-annex. It tracks what files live where, and you can sync single files or as much content as will fit on the local harddrive with a few commands. There is also git-annex-assistant for a more dropbox-like experience, although I haven't used it myself.
After some research it looks like seafile [1] and nextcloud virtual file mode [2] are viable candidates.
[1] https://www.seafile.com/en/home/ [2] https://nextcloud.com/blog/nextcloud-desktop-client-3-2-with...
I think you're looking for this: https://syncthing.net/
I used to use dropbox...I then spent years using raspberry pi's as storage devices, rclone, gdrive, s3 storage, syncthing and other solutions...I am now using dropbox again :-) (with rclone thrown in where needed)
You're describing a "distributed filesystem with client-side whole-file caching". The Andrew File System (AFSv2) did this back in the 1990s.
https://pages.cs.wisc.edu/~remzi/OSTEP/dist-afs.pdf
FWIW, complexity is introduced when the server is unavailable and the client-side caches need to be synced with the remote.
Sshfs, NFS, and SMB are substantially easier to set up and live with, so you're not fighting conflict resolutions inherent in multi-primary repositories.