Why does it take energy to separate positive and negative charges in a cell?

opposite charges attract each other

it takes work (energy) to separate them