Tax residency is a different question altogether. Owning property does not automatically make you taxable on worldwide income, and spending enough time in the country often does.
The preliminary agreement usually comes first: a modest payment freezes the price for an agreed window. Pay attention to the terms of the deposit if the legal review uncovers an issue.