Dynamic uplift during slab flattening