Can't your daughter just turn that option off? You may recall that I wrote a thread about accidentally turning Optimise Storage on myself. After trying it for a while I eventually turned it off. All my files were restored but I never had any permission issues. It sounds like your daughter's case is more complicated. Was she short of storage or did it happen "accidentally" at setup?
According to all I can find, turning it off isn't a solution. Basically, if it's on, and your stuff has been evicted, when you turn it off, the system re-creates new, empty Desktop and Documents folders where they were, but then the downloaded files are NOT put there, but in some Archive folders. And a lot of folks are finding that those Archive folders look empty to Finder because of the issue it has with that happening for all evicted files. Apple has been silent.
What she plans to do is to use the Terminal commands after retrieving all of the evicted files, then disconnect from the Internet before they can be evicted again and then move them to an external drive that she bought just for the purpose. These are files for her home business, so what she will do is keep all of the business-related stuff on that external and connect to it when in her home office. Once she knows it's all safely offline, she will reconnect to the Internet and see what happens when she turns off Optimize. If it screws up as it has for a lot of folks, she'll still have the offline copies. If it works and Desktop/Documents is properly restored, that will be fine. If it retrieves the files as hidden in the archive folders, she'll delete the archive folders and move on.
She had deliberately chosen the Optimize option. Her MBA only has a 256GB drive, and her business has a lot of photos for the products she sells online, so that space disappeared pretty quickly. Keeping it on an external will be a small PITA as she takes the pictures on her iPhone and syncs through iCloud to the MBA, but now that she's aware of the issue, she can do a workaround to make it work.
I think she also plans to contact Apple support about it, but from other folks with the same issue Apple hasn't been much help. I tried to contact Apple support for her, but the Apple rep could only suggest reinstalling the OS, I pointed out that it was an Apple Silicon Mac, which technically checks for any OS issues at boot, so reinstallation isn't needed and the tech was surprised at that and had no other suggestions.
Turns out the folks who say Apple ain't what it used to be were right, I guess.
CLARIFICATION: In Sonoma, the option is now under Storage Settings and is labelled "Store in iCloud..." That option then leads to a panel where there are options to Store in iCloud Desktop and Documents and/or Photos. My research says that if you turn on those options, what happens is that everything in Desktop/Documents is evicted to iCloud, or all files in Photos is evicted, or both. And by "evicted" I mean it is no longer on the Mac, but ONLY in the cloud until you retreive it, which is when the visibility problems begin. But at least the labelling is more accurate than the previous "Optimize Mac Storage."