A variational approach for modelling surface tension effects in inviscid fluids