I have had similar opportunities. In the one I am working through now MassHealth has a lien on the property which is more complicated as the house is being purchased at a deep discount due to the distressed nature of the home.
I don’t think this instance need be overly complicated if there are no liens. If you purchase the house for more than what is owed on the mortgage, than the foreclosure issue is taken care of.
In my experience with Medicaid the seller would not be eligible for Medicaid until after the house was sold. Once the house is sold, the seller will have to spend the proceeds on their medical care and other normal expenses. Once they have spent all their money (I believe you can have no more than $2,500 in your bank account), Medicaid kicks in. The proceeds from the sale would also be used to pay off any unpaid medical bills etc.
So if they already are receiving support, make sure their is no MassHealth coverage currently, which could lead to liens and more complication. The patients can often be confused by the difference between Medicaid and MassHealth, using the names interchangeably.
I have had Medicaid question the sale of a house retrospectively, questioning the sale price because we bought below FMV, however, a letter explaining the price based on the "as is" condition of the house and the expenses required for renovate to get the house to FMV was sufficient. Doesn't sound like this will n ecessarily be the case here, but to help the seller in such a case, as an agent you should be able to prepare a BPO of the property "as is" that they can use for this purpose should it be required.