Given an array `stones` of positive weights, repeatedly take the two heaviest stones and smash them: if they differ, the difference returns as a new stone; if equal, both are destroyed. Return the weight of the last remaining stone, or 0 if none remain.