The GTC exoplanet transit spectroscopy survey IX. Detection of haze, Na, K, and Li in the super-Neptune WASP-127b