Imbibition-induced selective wetting of liquid metal