if you do... negative result
Describes an irreversible negative outcome once a certain action is taken.
This pattern expresses that once a particular action is done, a negative result is unavoidable and there is no going back. It carries a sense of doom or inevitability. The verb in the た-form often describes a decisive or careless action, like revealing a secret, making a mistake, or starting something risky.
It is used in both written and spoken Japanese, but it is fairly strong and dramatic. You wouldn't use it for trivial matters; rather, it fits situations where the speaker warns about dire consequences. The second part of the sentence usually describes the bad outcome, which can be in the present or future tense.
Note that たが最後 is a more literary and emphatic variant of たら最後. In conversation, たら最後 is more common, but both are acceptable at N1 level.