Unsigned magnetic flux proxy from solar optical intensity spectra