Hi,
A few points:
1) The orbitals energies, the Fermi energy and the vacuum level have themselves no physical meaning. Only a difference between these quantities has a physical interpretation (e.g., work function or band gap). Comparing the work function with the vacuum level makes no sense. The only physical requirement is to have a vacuum level that is higher than the valence band maximum (VBM), i.e. a positive work function.
2) As explained at Computing the work function, the work function is calculated using the Fermi energy. However, in the case of a semiconductor/insulator, the Fermi energy can be defined arbitrarily within the band gap (e.g., EFERMI=MIDGAP chooses the middle of the band gap, which is really inappropriate for calculating the work function). The quantity to consider is the VBM, and in your case it is quite simple to extract it from your OUTCAR since you use only one k-point (VBM is -1.3871 eV, while the Fermi energy is at -0.1136 eV). Note that even with EFERMI=LEGACY, the Fermi energy may be noticeably higher than the VBM because of the smearing SIGMA.
3) I did not repeat your calculation using VASPKIT. Instead, I used a version of VASP that is more recent than VASP.6.4.2 that you used, and has a feature (LVACPOTAV) that conveniently calculates the vacuum level. I obtained 5.130 eV for the vacuum level and -1.3871 eV for the VBM, which leads to 5.130-(-1.3871)=6.5171 eV for the work function (OUTCAR is attached). Which value did you obtain for the vacuum level with VASPKIT? Also note that the average potential can be plotted with py4vasp.
4) Quality of your calculation: Your are using only one k-point. One k-point is appropriate in the direction of the vacuum, but certainly not enough for the directions parallel to the slab.
5) Your system is non-magnetic, therefore you could have used ISPIN=1, which makes the calculation faster.
You do not have the required permissions to view the files attached to this post.