Thank you for your reply, Dennis.
Unfortunately, the general rule in Virginia is that employment is "at will" absent an express agreement to the contrary. At will employment can be terminated for any reason not amounting to discrimination on the basis of a legally protected trait (race, religion, gender, etc.) or retaliation for engaging in certain forms of legally protected conduct (filing a wage claim, taking FMLA leave, etc.). It doesn't matter whether the basis for termination is fair, reasonable or even true.
So, while it was certainly unfair not to inform you that working from home was going to cause you to be laid off despite your excellent performance reviews, it is not illegal to be unfair in this respect. "Working from home" is not a "legally protected trait" or "legally protected activity," and so can be used as a basis for personnel decisions, fair or unfair. The only exception would be if you were working from home due to a physical disability of some sort, in which case this might be viewed as a form of disability discrimination. But the reasons you cite as the reasons for why you worked from home would not allow for this argument.
Therefore, I'm afraid that nothing about being laid off under the circumstances you describe would appear to violate any law, despite it being understandably frustrating.
I hope that you find this information helpful and am genuinely sorry if it is not what you were hoping to hear. Please do not hesitate to let me know if you have any questions or concerns regarding the above and I will be more than happy to assist you further.
If you do not require any further assistance, please be so kind as to provide a positive rating of my service so that I may receive credit for assisting you. Very best wishes moving forward.