So half of the gift (assuming it comes from a joint account, so half from each parent) will be counted within the estate if a parent dies within 7 years. There is taper relief and an amount of 3k that can be passed on each year tax free, so not all of the 25k from that parent would be counted within their estate. Let’s assume the figure included in that parents estate is 15k.
Each parent get an IHT allowance of 325k (plus 175k if the main residence is being left to certain family members) but anything passing between spouses is exempt, so if everything else goes to the spouse, then the 15k is less than 325k and free of IHT on first death.
However, on the second parent dying, any left over allowance from first death can be added to second allowance.
If everything from first parent went to spouse, with no gifts, then this would be 325k, (plus 175k housing allowance), making 500k per parent, 1 million in total.
However in your case, 15k would have been used up on first death, so I think that would leave 310k + 175k from first death, plus 500k from second death, ie 985k in total.
You say that the house is worth 800k, how much money do they have on top of that? Are they likely to be near the 1 million joint allowance?
Bear in mind that one of them may go into a home, reducing the total amount left on second death considerably.
It is a minefield, and one reason we are passing money on to ours monthly via their ISAs whilst we in late 50s/early 60s. Yes one of us may die young, but less likely than when in our 80s.