Equilibrium differential capacitance and electrocapillary curves within the framework of a generalized model of the surface layer